2022-10-24 14:17:53 -04:00

14586 lines
2.0 MiB

(function(){var hk={};hk.a2T=function(w,n){var W=e.eH[e.GF("%|xK")];if(W==null)return"XYP";var D=w.toString(16).slice(0,4),j=D+n+"aQYRDCB";
return W(j).slice(5,17)+D.split("").reverse().join("")};hk.Hl=function(){var w=e.eH[e.Dn("3M"+(e.pI(26)?"]K":"fa"))];
w=w[e.Dn("]["+(!e.pI(28)?",":"`"))];return Math.floor(w()/1e3)};hk.pI=function(w){var n=0;for(var L=0;
L<w;L++)n+=Math.random();return n/w<Math.PI/4};hk.Dn=function(w){var n="";if(!hk.pI(28))w+="-3";for(var L=0;
L<w.length;L++){var W=w.charCodeAt(L);if(W<32||126<W)throw"e";n+=String.fromCharCode(32+(W-32+17+3*L)%95)}return n};
hk.GF=function(w){var n="";if(!hk.pI(28))w+="-1";for(var L=0;L<w.length;L++){var W=w.charCodeAt(L);W-=32;
W+=95e4;W-=17+3*L;W=W%95;n+=String.fromCharCode(32+W)}return n};hk.aZ=hk.Dn("XP");hk.p2=hk.Dn("XYP");
hk.Er=hk.Dn("c[Y");hk.aAo=hk.Dn("][`");hk.a8t=hk.Dn("SU_");hk.lq=hk.Dn("b^L");hk.adz=hk.Dn("61=");hk.yd=hk.Dn("Q[M_");
hk.Oc=hk.Dn("WQJJ");hk.op=hk.Dn("W^NL");hk.oE=hk.Dn("[[JJ");hk.ab8=hk.Dn("[[PU");hk.or=hk.Dn("^\\NT");
hk.a0w=hk.Dn("bQUL");hk.Z2=hk.Dn("bQWJ");hk.Gg=hk.Dn("3M]K");hk.a7k=hk.Dn("<M]N");hk.lx=hk.Dn("][WK");
hk.aAl=hk.Dn("P_bTF");hk.fV=hk.Dn("RXRIN");hk.ik=hk.Dn("b`bRH");hk.hk=hk.Dn("fUMZK");hk.aAH=hk.Dn("Q[]ZRM");
hk.a6i=hk.Dn("WQRMKT");hk.UC=hk.Dn("XR[GPE");hk.aka=hk.Dn("aMWJRM");hk.ab3=hk.Dn("bO[OST");hk.bG=hk.Dn("cM[MHT");
hk.a5a=hk.Dn("^Z5OQE");hk.mK=hk.Dn("R[WLLRJ");hk.an6=hk.Dn("SU\\VOAV");hk.aar=hk.Dn("XZMK[/C");hk.I3=hk.Dn("aQYRDCB");
hk.Xe=hk.Dn("[[LGWILH");hk.EW=hk.Dn("S[L[PEKN");hk.Ks=hk.Dn("aQOKURBL");hk.Ri=hk.Dn("aQ\\VRNP?");hk.a58=hk.Dn("XZWKU(1'#");
hk.afQ=hk.Dn("SQLUGE2, ");hk.anx=hk.Dn("]M_OJAQII");hk.UJ=hk.Dn("bQ]:LMBILH");hk.anQ=hk.Dn("UU[YW#ECC8");
hk.H7=hk.Dn("cQaZ&OKN<BE");hk.uA=hk.Dn("P\\YKQD B@@5");hk.uF=hk.Dn("aQVUYE B@@5");hk.k3=hk.Dn("bQ]'WTOC9IE3");
hk.ar7=hk.Dn("XZ\\KUT~?=CC3");hk.qq=hk.Dn("R^NGWE\"F<A6<?");hk.a1r=hk.Dn("VQ]+OEJ?EHrGs,");hk.GJ=hk.Dn("G95.WTM,<EF3><");
hk.a3$=hk.Dn("PZLKVTLL&F:5468");hk.ZR=hk.Dn("PPM+YEKN#=DB06*4");function aK(w){this.JV={};this.BG=0;
this.Ss();if(w!=!0)window.__kb=this}aK._C=null;aK.prototype.Ss=function(){var w=navigator.keyboard;if(w&&window.top==window.self)w.getLayoutMap().then(function(n){aK._C=n})};
aK.prototype.arY=function(w){var n={shiftKey:aK.WO,altKey:aK.PJ,ctrlKey:aK.CQ};for(var W in n){var D=w[W],j=n[W],I=this.U(j);
if(!D&&I){for(var L=0;L<j.MD.length;L++)this.nv(j.MD[L])}}};aK.prototype.xa=function(w){this.BG++;this.JV[w]=!0};
aK.prototype.nv=function(w){this.BG--;delete this.JV[w];if(this.BG<=0||aK.$L(w,aK.xc))this.reset()};
aK.prototype.U=function(w){for(var L=0;L<w.MD.length;L++)if(this.JV[w.MD[L]])return!0;return!1};aK.prototype.reset=function(){this.JV={};
this.BG=0};aK.prototype.aa=function(w){var n=this,W=n.U(aK.WO)?10:1,D=0,j=0;if(n.U(aK.z5))D=-W;else if(n.U(aK.i$))D=W;
else if(n.U(aK.Fe))j=-W;else if(n.U(aK.I$))j=W;var I=new ec(D,j);if(w!=null){var U=new eh;U.rotate(w);
I=U.bj(I);if(Math.abs(I.x)<Math.abs(I.y))I.x=0;else I.y=0;I.x=Math.round(I.x);I.y=Math.round(I.y)}return I};
aK.prototype.$N=function(){var w=this,n=aK.xL;for(var L=0;L<10;L++)if(w.U(n[L]))return L;return-1};aK.$L=function(w,n){return n.MD.indexOf(w)!=-1};
aK.ah7="ZoomToggle BrightnessDown BrightnessUp AudioVolumeMute AudioVolumeDown AudioVolumeUp LaunchApplication1 F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 Enter Shift Escape KeyV".split(" ");
aK.QC=function(w){var n=w.code;if(n=="")return!1;var W=aK.$L;if(w.altKey&&!w.shiftKey&&!w.ctrlKey){var D=aK.xL.concat([aK.fQ,aK.Ne,aK.yq,aK.vs]),j=!1;
for(var L=0;L<D.length;L++)if(W(n,D[L]))return!1}return aK.ah7.indexOf(n)==-1||w.shiftKey&&(n=="F5"||n=="F6")};
aK.cO=function(w){if(typeof w=="string")return w;var n=navigator.platform.toUpperCase().indexOf("MAC")>=0;
if(w==null)return"";var W=[];for(var L=0;L<w.length;L++){var D=w[L].DG?w[L].DG:w[L];if(n&&w[L].Tm)D=w[L].Tm;
W.push(D)}if(n||W.length==1)return W.join(" + ");else{var j=W.pop();return W.join("+")+" + "+j}};aK.Bo=function(w){window.__kb.Ss();
var n=w.code,W=aK._C;if(W&&W.get(n)){var D={"+":"NumpadAdd","-":"NumpadSubtract",".":"Period"},j=W.get(n).toLowerCase(),I=j.charCodeAt(0);
if(97<=I&&I<=122){var U="Key"+j.toUpperCase();n=U}else if(D[j])n=D[j];return n}var D={"+":"NumpadAdd","-":"NumpadSubtract",".":"Period"},j=w.key.toLowerCase(),I=j.charCodeAt(0);
if(j.length==1){if(97<=I&&I<=122){var U="Key"+j.toUpperCase();n=U}else if(D[j])n=D[j]}if(j=="control"&&n!="")n="ControlLeft";
return n};aK.q0=0;aK.Af=function(w,n){var W=0;if(Date.now()-aK.q0>1e3){W=n==0?100:n*10}else{if(w%10!=0)w*=10;
W=(w+n)%100}aK.q0=Date.now();return W};aK.ax6={nm:"No Touch",MD:["NoTouch"]};aK.yG={DG:"Enter",MD:["Enter","NumpadEnter"]};
aK.WO={DG:"Shift",Tm:"\u21E7",MD:["ShiftLeft","ShiftRight"]};aK.xc={DG:"Meta",MD:["MetaLeft","MetaRight","OSLeft","OSRight"]};
aK.CQ={DG:"Ctrl",Tm:"\u2318",MD:"ControlLeft ControlRight MetaLeft MetaRight OSLeft OSRight".split(" ")};
aK.PJ={DG:"Alt",Tm:"\u2325",MD:["AltLeft","AltRight"]};aK.a7r={DG:"CtrlOrAlt",MD:aK.CQ.MD.concat(aK.PJ.MD)};
aK.QX={DG:"Escape",MD:["Escape"]};aK.Xu={DG:"Space",MD:["Space"]};aK.R4={DG:"Tab",MD:["Tab"]};aK.LT={DG:"Home",MD:["Home"]};
aK.alP={DG:"End",MD:["End"]};aK.z5={DG:"Left",MD:["ArrowLeft"]};aK.Fe={DG:"Up",MD:["ArrowUp"]};aK.i$={DG:"Right",MD:["ArrowRight"]};
aK.I$={DG:"Down",MD:["ArrowDown"]};aK.fQ={DG:"+",MD:["NumpadAdd","Equal"]};aK.Ne={DG:"-",MD:["NumpadSubtract","Minus"]};
aK.iI={DG:";",MD:["Semicolon"]};aK.a2Y={DG:"Dead",MD:["Dead"]};aK.aqB={DG:"=",MD:["Equal"]};aK.on={DG:"Backspace",MD:["Backspace"]};
aK.m2={DG:"Delete",MD:["Delete"]};aK.abD={DG:"Backslash",MD:["Backslash","IntlBackslash"]};aK.aui={DG:"Slash",MD:["NumpadDivide","Slash"]};
aK.atV={DG:"Backquote",MD:["Backquote"]};aK.yq={DG:"[",MD:["BracketLeft"]};aK.vs={DG:"]",MD:["BracketRight"]};
aK.k2={DG:".",MD:["Period"]};aK.W8={DG:",",MD:["Comma"]};aK.m5={DG:"'",MD:["Quote"]};aK.c={DG:"A",MD:["KeyA"]};
aK.T2={DG:"B",MD:["KeyB"]};aK.Ak={DG:"C",MD:["KeyC"]};aK.Rn={DG:"D",MD:["KeyD"]};aK.E={DG:"E",MD:["KeyE"]};
aK.aM={DG:"F",MD:["KeyF"]};aK.rP={DG:"G",MD:["KeyG"]};aK.Ga={DG:"H",MD:["KeyH"]};aK.Zb={DG:"I",MD:["KeyI"]};
aK.KZ={DG:"J",MD:["KeyJ"]};aK.M$={DG:"K",MD:["KeyK"]};aK.zP={DG:"L",MD:["KeyL"]};aK.$g={DG:"M",MD:["KeyM"]};
aK.r1={DG:"N",MD:["KeyN"]};aK.ke={DG:"O",MD:["KeyO"]};aK.b8={DG:"P",MD:["KeyP"]};aK.Hk={DG:"Q",MD:["KeyQ"]};
aK.ip={DG:"R",MD:["KeyR"]};aK.qd={DG:"S",MD:["KeyS"]};aK.US={DG:"T",MD:["KeyT"]};aK.Eg={DG:"U",MD:["KeyU"]};
aK.tM={DG:"V",MD:["KeyV"]};aK._j={DG:"W",MD:["KeyW"]};aK.Pn={DG:"X",MD:["KeyX"]};aK.a4j={DG:"Y",MD:["KeyY"]};
aK.xD={DG:"Z",MD:["KeyZ"]};aK.zf={DG:"0",MD:["Numpad0","Digit0"]};aK.ed={DG:"1",MD:["Numpad1","Digit1"]};
aK.akp={DG:"2",MD:["Numpad2","Digit2"]};aK.a6E={DG:"3",MD:["Numpad3","Digit3"]};aK.a0M={DG:"4",MD:["Numpad4","Digit4"]};
aK.agj={DG:"5",MD:["Numpad5","Digit5"]};aK.aha={DG:"6",MD:["Numpad6","Digit6"]};aK.akg={DG:"7",MD:["Numpad7","Digit7"]};
aK.aa_={DG:"8",MD:["Numpad8","Digit8"]};aK.a0K={DG:"9",MD:["Numpad9","Digit9"]};aK.xL=[aK.zf,aK.ed,aK.akp,aK.a6E,aK.a0M,aK.agj,aK.aha,aK.akg,aK.aa_,aK.a0K];
aK.axo={DG:"F1",MD:["F1"]};aK.apw={DG:"F2",MD:["F2"]};aK.a4z={DG:"F3",MD:["F3"]};aK.aA7={DG:"FF",MD:["F4"]};
aK.Qn={DG:"F5",MD:["F5"]};aK.ah0={DG:"F6",MD:["F6"]};aK.abp={DG:"F7",MD:["F7"]};aK.a6d={DG:"F8",MD:["F8"]};
aK.ahr={DG:"F9",MD:["F9"]};aK.ach={DG:"F10",MD:["F10"]};aK.am9={DG:"F11",MD:["F11"]};aK.a0Z={DG:"F12",MD:["F12"]};
function hy(w){hG.call(this);this.FX={};this.Ca={};this.aqm=0;this.a26={};this.Kx=[];this.aho=0;this.oE=w;
hy.sU=this}hy.aaV=function(w,n){var L=0,W=hy.PY;while(L<W.length){if((n>>>L&1)==1)break;L++}if(L!=0&&hy.dq(w,[33,126])>.7)L=0;
if(n==0||W[L][1]==""){if((n&15)!=0&&hy.dq(w,[33,126])>.7)L=0;else if(n==0)L=0;else{L=0}}return W[L][1]};
hy.uh=120;hy.Ns=20;hy.cols=16;hy.x2=function(w){var n=w.name.postScriptName;if(n==null)return null;return n.replace(/ /g,"-")};
hy.Tz=function(w){var n=w.name,W=n.typoFamilyName,D=n.typoSubfamilyName,j=W&D,I=j?W:n.fontFamily,U=j?D:n.fontSubfamily;
if(U==null)U="Regular";var M=hy.atC,m=I.toLowerCase();for(var L=0;L<M.length;L++){if(M[L]=="roman")continue;
if(m.endsWith(" "+M[L])||m.endsWith("-"+M[L])){var l=I.length-M[L].length,A=I.slice(l);I=I.slice(0,l-1);
if(A!=""){if(U=="Regular"||U==I+" Regular")U=A;else U=A+" "+U}break}}var g="BPdots,Baloo,Diner,EB Garamond Initials,Encode Sans Semi Condensed,Encode Sans Semi Expanded,Changa,HVD Poster,IM FELL DW,IM FELL Double,IM FELL English,IM FELL FLOWERS,IM FELL French Canon,IM FELL Great Primer,itsadzoke,JUICE,Lacuna,Latin Modern Mono,Latin Modern Sans,Latin Modern Roman,Latinia,Libre Barcode,Libre Caslon,Londrina,Panefresco,Qomolangma,UnifrakturMaguntia,WC Rhesus,WC Sold Out,WC Wunderbach,Walkway".split(",");
for(var L=0;L<g.length;L++)if(I.startsWith(g[L])){var A=I.slice(g[L].length);I=g[L];if(A.startsWith(" ")||A.startsWith("-"))A=A.slice(1);
if(A!=""){if(U=="Regular")U=A;else U=A+" "+U}break}var k={"Caudex-BoldItalic":"Bold Italic","Comfortaa-Light":"Light","Comfortaa-Medium":"Medium","Comfortaa-SemiBold":"SemiBold",DevroyeSCOSF:"Regular SCOSF",DevroyeUnicode:"Regular Unicode","LeagueScriptThin-Regular":"Regular","Monda-Bold":"Bold","Nobile-Bold":"Bold","Oswald-BoldItalic":"Bold Italic","Oswald-HeavyItalic":"Heavy Italic","Oswald-LightItalic":"Light Italic","Oswald-MediumItalic":"Medium Italic","Oswald-RegularItalic":"Regular Italic","PaloAlto-Italic":"Heavy Italic"},$=k[hy.x2(w)];
if($)U=$;return[I,U]};hy.prototype.a7_=function(w){var n=this.hz();for(var W in n)if(n[W][0]==w)this.lY(W)};
hy.prototype.aoJ=function(){return Object.keys(this.Ca).length!=0};hy.prototype.lY=function(w,n){if(this.FX[w])return this.FX[w];
if(this.Ca[w])return null;var W=null,D=this.hz();if(D[w]!=null)W=D[w][5];if(W==null){var j=hy.I3[w];
if(j==null){var I="DejaVuSans DejaVuSans-Bold DejaVuSans-Oblique DejaVuSans-BoldOblique DejaVuSerif DejaVuSerif-Bold DejaVuSerif-Italic DejaVuSerif-BoldItalic".split(" "),U=w.toLowerCase(),M=0;
if(U.indexOf("sans")!=-1)M=0;else if(U.indexOf("serif")!=-1)M=4;var m=U.indexOf("bold")!=-1||U.indexOf("-black")!=-1,l=U.indexOf("italic")!=-1||U.indexOf("oblique")!=-1||U.endsWith("-it");
if(m&&l)M+=3;else if(l)M+=2;else if(m)M+=1;j=I[M]}if(n!=null&&n>128)j=this.zv(n,j);if(this.a26[w]==null){this.a26[w]=1;
var A=Date.now()-this.aqm>2e3?2e3:0;this.aqm=Date.now();alert(w+" \u27A1 "+j,A)}return this.lY(j,n)}this.Ca[w]="a";
this.oE(W)};hy.prototype.zv=function(w,n,W){var D=this.FX[n];if(D&&Typr.U.codeToGlyph(D,w)!=0)return n;
var j=this.hz(),I=hy.arX(w),U=I[0];if(j[n]&&(j[n][3]&U)==0){if(W)for(var L=0;L<W.length;L++){var M=W[L].Name,m=j[M];
if(m&&(m[3]&U)!=0)return M}var M=hy.PY[I[1]][4];if(j[M])return M}return n};hy.arX=function(w){var n=hy.PY,W=[0];
for(var L=0;L<n.length;L++){var D=n[L][2];for(var j=0;j<D.length;j+=2)if(D[j]<=w&&w<=D[j+1]){W[0]+=1<<L;
W.push(L)}}if(W.length==1)W.push(0);return W};hy.prototype.a5I=function(){var w=this.Kx,n=w[0],W=w.length-1;
alert(fV.get([22,6,0])+" "+n+(W==0?"":", ... ("+W+")")+" "+fV.get([23,0])+".",1500);this.Kx=[]};hy.prototype.avt=function(w,n){if(n!=!0){this.Kx.push(w.name.fullName);
clearTimeout(this.aho);this.aho=setTimeout(this.a5I.bind(this),300)}var W=hy.x2(w),D=this.hz(),j=D[W],I=hy.ais(w);
if(j==null){var U=document.createElement("canvas"),M=U.getContext("2d");U.width=hy.uh;U.height=hy.Ns;
var m=hy.Ns*1.2/w.head.unitsPerEm;M.translate(4,hy.Ns*.9);M.scale(m,-m);M.fillStyle="#000000";var l=Typr.U.shape(w,hy.aaV(w,I[3]),!0);
Typr.U.pathToContext(Typr.U.shapeToPath(w,l),M);M.fill();I.a5u=U.toDataURL();this.gu(I)}delete this.Ca[W];
this.FX[W]=w};hy.afp=function(){var w=hy.PY,n=[];for(var L=0;L<w.length;L++)n.push(w[L][0]);return n};
hy.PY=[["Latin-1","Preview",[161,169,192,246,248,255],.7,"DejaVuSans"],["Latin Ext. A","",[256,383],.7,"DejaVuSans"],["Greek","\u0395\u03BB\u03BB\u03B7\u03BD\u03B9\u03BA\u03AC",[913,929,931,969],.7,"DejaVuSans"],["Cyrillic","\u041F\u0440\u0438\u0432\u0435\u0442",[1040,1119],.7,"DejaVuSans"],["Hebrew","\u05E2\u05D1\u05E8\u05D9\u05EA",[1473,1479,1488,1514,1520,1524],.7,"DejaVuSans"],["Arabic","\u0627\u064E\u0644\u0652\u0639\u064E\u0631\u064E\u0628\u0650\u064A\u064E\u0651\u0629\u064F",[1569,1594,1600,1749],.4,"DejaVuSans"],["Hangul","\uC608\uACE0\uD3B8",[4352,4607,44032,55203,12593,12686],.7,"NotoSansKR-Regular"],["Chi-Jap-Kor","\u9810\u7FD2",[12288,12351,12352,12447,12448,12543,19968,40895],.05,"DroidSansFallback"],["Tibetan","\u0F50\u0F74\u0F42\u0F66\u0F0B\u0F62\u0F97\u0F7A\u0F0B\u0F46\u0F7A\u0F0D",[3840,3948,3953,4044],.7,"NotoSansTibetan"],["Devanagari","\u092A\u0942\u0930\u094D\u0935\u093E\u0935\u0932\u094B\u0915\u0928",[2304,2431],.7,"Hind-Regular"],["Thai","\u0E20\u0E32\u0E1E\u0E15\u0E31\u0E27\u0E2D\u0E22\u0E48\u0E32\u0E07",[3585,3642,3647,3675],.7,"K2D-Regular"],["Khmer","\u1798\u17BE\u179B\u1787\u17B6\u1798\u17BB\u1793",[6016,6109,6112,6121,6128,6137],.7,"Battambang-Regular"],["Vietnamese","Xem tr\u01B0\u1EDBc",[192,195,200,202,204,205,210,213,217,218,221,221,224,227,232,234,236,237,242,245,249,250,253,253,258,259,272,273,296,297,360,361,416,417,431,432,7840,7929],.95,"DejaVuSans"],["Bengali","\u09B8\u09CD\u09AC\u09BE\u09A7\u09C0\u09A8\u09AD\u09BE\u09AC\u09C7",[2432,2559],.2,"FreeSans"],["Emoji","",[9728,10095,127744,129535],.01,"DejaVuSans"]];
hy.ais=function(w,n,W){var D=w.name,m=0;if(hy.x2(w)==null){console.log(w);throw"No postScriptName!"}var j=hy.PY,I=[];
for(var L=0;L<j.length;L++){var U=j[L][2],M=j[L][3];I[L]=hy.dq(w,U)>M?1:0}for(var L=0;L<I.length;L++)m+=I[L]<<L;
var l=hy.Tz(w);return[l[0],l[1],hy.x2(w),m,W,n]};hy.dq=function(w,n){var W=0,D=0;for(var j=0;j<n.length;
j+=2){for(var I=n[j];I<=n[j+1];I++){var U=Typr.U.codeToGlyph(w,I);if(U==0)D++;else W++}}return W/(W+D)};
hy.apN=function(w,n){if(w[2]<n[2])return-1;if(w[2]>n[2])return 1;return 0};hy.a8e=function(w,n){if(w[5]=="fs/"+w[2]+".otf")w[5]="";
else if(w[5]=="gf/"+w[2]+".otf")w[5]="a";if(w[2]==(w[0]+"-"+w[1]).replace(/\s/g,"")){w[2]=""}else if(w[2]==w[0].replace(/\s/g,"")){w[2]="a"}if(n){if(w[0]==n[0])w[0]="";
if(w[1]==n[1])w[1]="";if(w[3]==n[3])w[3]="";if(w[4]==n[4])w[4]=""}return w.join(",")};hy.alU=function(w,n){w=w.split(",");
if(w[0]=="")w[0]=n[0];if(w[1]=="")w[1]=n[1];if(w[3]=="")w[3]=n[3];else w[3]=parseInt(w[3]);if(w[4]=="")w[4]=n[4];
else w[4]=parseInt(w[4]);if(w[2]=="")w[2]=(w[0]+"-"+w[1]).replace(/\s/g,"");else if(w[2]=="a")w[2]=w[0].replace(/\s/g,"");
if(w[5]=="")w[5]="fs/"+w[2]+".otf";else if(w[5]=="a")w[5]="gf/"+w[2]+".otf";return w};hy.I3={ArialMT:"LiberationSans","Arial-BoldMT":"LiberationSans-Bold","Arial-ItalicMT":"LiberationSans-Italic","Arial-BoldItalicMT":"LiberationSans-BoldItalic",TimesNewRomanPSMT:"LiberationSerif","TimesNewRomanPS-BoldMT":"LiberationSerif-Bold","TimesNewRomanPS-ItalicMT":"LiberationSerif-Italic","TimesNewRomanPS-BoldItalicMT":"LiberationSerif-BoldItalic",CourierNewPSMT:"CourierPrime","CourierNewPS-BoldMT":"CourierPrime-Bold","CourierNewPS-ItalicMT":"CourierPrime-Italic","CourierNewPS-BoldItalicMT":"CourierPrime-BoldItalic",Courier:"CourierPrime","Courier-Bold":"CourierPrime-Bold",TrebuchetMS:"SourceSansPro-Regular","TrebuchetMS-Bold":"SourceSansPro-Semibold","TrebuchetMS-Italic":"SourceSansPro-It","TrebuchetMS-BoldItalic":"SourceSansPro-SemiboldIt","Times-Roman":"LiberationSerif",Impact:"Anton-Regular",Calibri:"SourceSansPro-Regular","Calibri-Italic":"SourceSansPro-It","Calibri-Bold":"SourceSansPro-Bold",CalibriBold:"SourceSansPro-Bold","Times-Roman":"LiberationSerif","Times-Italic":"LiberationSerif-Italic","Times-Bold":"LiberationSerif-Bold","Helvetica-Bold":"LiberationSans-Bold","HelveticaNeue-Thin":"Roboto-Thin","HelveticaNeue-Light":"Roboto-Light",HelveticaNeue:"Roboto-Regular","HelveticaNeue-Roman":"Roboto-Regular","HelveticaNeue-Medium":"Roboto-Medium","HelveticaNeue-Bold":"Roboto-Bold","HelveticaNeue-BoldItalic":"Roboto-BoldItalic","HelveticaNeue-Black":"Roboto-Black","HelveticaNeue-Heavy":"Roboto-Black","BasisGrotesque-Regular":"Roboto-Regular","BasisGrotesque-Medium":"Roboto-Medium","BasisGrotesque-Bold":"Roboto-Bold",ElementaPro:"FreeMono","ElementaPro-Bold":"FreeMonoBold","SFProText-Light":"Roboto-Light","SFProText-Regular":"Roboto-Regular","SFProText-Roman":"Roboto-Regular","SFProText-Medium":"Roboto-Medium","SFProText-Semibold":"Roboto-Medium","SFProText-Bold":"Roboto-Bold","SFProText-BoldItalic":"Roboto-BoldItalic","SFProText-Black":"Roboto-Black","SFProText-Heavy":"Roboto-Black","SFProDisplay-Light":"Roboto-Light","SFProDisplay-Regular":"Roboto-Regular","SFProDisplay-Roman":"Roboto-Regular","SFProDisplay-Medium":"Roboto-Medium","SFProDisplay-Semibold":"Roboto-Medium","SFProDisplay-Bold":"Roboto-Bold","SFProDisplay-BoldItalic":"SFProDisplay-BoldItalic","SFProDisplay-Black":"Roboto-Black","SFProDisplay-Heavy":"Roboto-Black","SFUIText-Light":"Roboto-Light","SFUIText-Regular":"Roboto-Regular","SFUIText-Roman":"Roboto-Regular","SFUIText-Medium":"Roboto-Medium","SFUIText-Semibold":"Roboto-Medium","SFUIText-Bold":"Roboto-Bold","SFUIText-BoldItalic":"SFUIText-BoldItalic","SFUIText-Black":"Roboto-Black","SFUIText-Heavy":"Roboto-Black",Verdana:"DejaVuSans","Verdana-Bold":"DejaVuSans-Bold","Verdana-Italic":"DejaVuSans-Oblique","Verdana-BoldItalic":"DejaVuSans-BoldOblique","MyriadPro-Regular":"PTSans-Regular","MyriadPro-Bold":"PTSans-Bold","MyriadPro-LightIt":"PTSans-Italic","MyriadPro-Semibold":"PTSans-Bold","MyriadPro-Black":"PTSans-Bold","MyriadPro-BlackCond":"PTSans-NarrowBold","MyriadPro-SemiboldCond":"PTSans-NarrowBold","MyriadPro-BoldCond":"PTSans-NarrowBold",Cambria:"Oranienbaum-Regular",Georgia:"CharisSIL","Georgia-Bold":"CharisSIL-Bold","Georgia-Italic":"CharisSIL-Italic","Georgia-BoldItalic":"CharisSIL-BoldItalic","AGaramondPro-Regular":"EBGaramond08-Regular","AGaramondPro-Bold":"EBGaramond08-Bold","AGaramondPro-Italic":"EBGaramond08-Italic",Garamond:"EBGaramond08-Regular",FontAwesome:"FontAwesome5FreeSolid","ProximaNova-Regular":"Metropolis-Regular","ProximaNova-Semibold":"Metropolis-SemiBold","ProximaNova-Light":"Metropolis-Light",BellMT:"GalatiaSIL","MinionPro-Regular":"CrimsonText-Regular","LyonDisplay-Medium":"Buenard-Regular","LyonText-Regular":"Buenard-Regular","LyonDisplay-Black":"Buenard-Bold","LyonText-Bold":"Buenard-Bold","Interstate-Light":"Overpass-Light","Interstate-Regular":"Overpass-Regular","Interstate-Bold":"Overpass-Bold","Interstate-BlackCondensed":"Overpass-Black",PalatinoLinotype:"TeXGyrePagella-Regular","PalatinoLinotype-Bold":"TeXGyrePagella-Bold","PalatinoLinotype-Italic":"TeXGyrePagella-Italic","PalatinoLinotype-BoldItalic":"TeXGyrePagella-BoldItalic"};
hy.prototype.hz=function(){if(FNTS.map==null){var w=FNTS.list,n=[];for(var L=0;L<w.length;L++){n[L]=hy.alU(w[L],n[L-1]);
n[L].p_=L;this.gu(n[L])}}return FNTS.map};hy.prototype.gu=function(w){var n=w[0],W=w[1],D=w[5];if(FNTS.map==null)FNTS.map={};
FNTS.map[w[2]]=w;if(FNTS.mapFS==null)FNTS.mapFS={};var j=FNTS.mapFS[n+"---"+W];FNTS.mapFS[n+"---"+W]=w;
if(FNTS.mapSub==null)FNTS.mapSub={};var I=FNTS.mapSub[n];if(I==null)I=FNTS.mapSub[n]=[];var U=I.indexOf(W);
if(U==-1)I.push(W);else I[U]=W};hy.a56=function(w,n){return hy.hS(w)-hy.hS(n)};hy.hS=function(w){w=w.toLowerCase();
var n=hy.atG(w)+(hy.a4W(w)<<1);if(w.indexOf("cond")==-1)n+=1<<25;return n};hy.atG=function(w){return w.indexOf("italic")!=-1||w.indexOf("oblique")!=-1?1:0};
hy.atC="two,four,eight,hair,thin,ultralight,extralight,exlight,light,regular,roman,book,medium,semi bold,semibold,demibold,extra bold,extrabold,bold,heavy,ultra,x black,black,extra".split(",");
hy.a3D=["two","four","eight","hair","thin","ultralight","extralight","light",["regular","roman","book"],"medium",["semibold","demibold"],"bold","extrabold","heavy","ultra","black","x black"];
hy.a4W=function(w){var n=hy.a3D,W=-1,D=-1;for(var L=0;L<n.length;L++){var j=n[L];if(j instanceof Array)for(var I=0;
I<j.length;I++){var U=j[I];if(w.indexOf(U)!=-1&&(W==-1||D<U.length)){W=L;D=U.length}}else if(w.indexOf(j)!=-1&&(W==-1||D<j.length)){W=L;
D=j.length}}if(W==-1)W=8;return W};hy.Kp=function(w,n){var W=1e9,D=null,j=hy.hS(n);for(var L=0;L<w.length;
L++){var I=Math.abs(hy.hS(w[L])-j);if(I<W){W=I;D=w[L]}}return D};hy.prototype.S7=function(w,n){this.hz();
return FNTS.mapFS[w+"---"+n]};hy.prototype.My=function(w){this.hz();return FNTS.mapSub[w]};hy.prototype.OB=function(){this.hz();
return FNTS.mapSub};var bh={GA:0,zF:null,DR:null,Wk:null,ng:null,Fz:null,sl:!0,Zq:0,Ot:!1};bh.event=function(w){var n=new XMLHttpRequest;
n.open("GET","/papi/event.php?id="+w+"&rnd="+Math.random());n.send()};bh.d$=function(){var w=bh.rE();
if(w==null)return null;var n=e.pI(24)?" ":"",W=e.eH[e.GF("Uu,"+n)];W=W[e.GF(n+"$/")];var D=bh.fv(1,999);
if(D&&bh.RW(D)*50>W()/20)return[0,D];var j=w.inTeams;if(j)for(var L=0;L<j.length;L++)if(j[L][1]*50>W()/20)return[1,j[L]];
return null};bh.bH=function(){return bh.anY()!=null};bh.LD=function(){return bh.RW(bh.fv(1e3,999999999))};
bh.RW=function(w){return w==null?0:w[0]+w[1]*24*60*60};bh.fv=function(w,n){var W=bh.rE(),D=W.pmnts,j=0,I=null;
if(D==null||D.length==0)return 0;for(var L=0;L<D.length;L++){var U=D[L],M=bh.RW(U);if(w<=U[2]&&U[2]<=n)if(j<M){j=M;
I=U}}return I};bh.rE=function(){return bh.Fz};bh.sk=function(w){window.addEventListener("message",bh.ae6,!1);
setInterval(bh.AS,5e3);if(bh.bH()&&navigator.onLine){bh.zF=w;bh.C7()}else setTimeout(w,1)};bh.AS=function(){if(bh.bH()&&bh.Ot){bh.Ya(bh.Y6());
bh.Ot=!1}};bh.uB=function(w){bh.zF=w;var n="https://www.photopea.com/papi/login.php?redirect="+encodeURIComponent(window.location.href);
bh.Wk=window.open(n,"_blank")};bh.aqh=function(){localStorage.removeItem(bh.GA+"_uid");localStorage.removeItem(bh.GA+"_provider");
localStorage.removeItem(bh.GA+"_token");bh.Fz=null};bh.ae6=function(w){if(w.data instanceof ArrayBuffer||w.data instanceof Object)return;
if(w.data.charAt(0)!="{")return;var n=JSON.parse(w.data);if(n.prms==null)return;var W=n.prms.split(",");
if(W[0]=="papi_logged_in"){localStorage[bh.GA+"_uid"]=W[1];bh.wJ(W[2]);localStorage[bh.GA+"_provider"]=W[3];
bh.Wk.close();bh.C7()}if(W[0]=="payment_complete"){bh.ng.close();bh.C7()}};bh.anY=function(){var w=localStorage[bh.GA+"_token"];
if(w!=null&&Date.now()*.001+10<parseInt(w.split("-")[0]))return w;return null};bh.wJ=function(w){var n=localStorage[bh.GA+"_token"];
if(n!=null&&parseInt(w.split("-")[0])<parseInt(n.split("-")[0]))return;localStorage[bh.GA+"_token"]=w;
clearTimeout(bh.Zq);bh.Zq=setTimeout(bh.a1G,Math.min(1e9,parseInt(w.split("-")[0])*1e3-Date.now()-20*1e3))};
bh.W7=function(w,n,W,D){if(!navigator.onLine)throw"a";var j=new XMLHttpRequest;j.open("POST","https://www.photopea.com/papi/record_new.php",!0);
j.onload=W;var I=bh.Cv(0)+"&read=3&tuid="+w+"&tid="+n;if(D)I+="&tpl="+encodeURIComponent(D);j.setRequestHeader("Content-type","application/x-www-form-urlencoded");
j.send(I)};bh.a1G=function(){if(!navigator.onLine)throw"a";var w=new XMLHttpRequest;w.open("POST","https://www.photopea.com/papi/record_new.php",!0);
w.onload=bh.ac2;var n=bh.Cv(0)+"&read=2";w.setRequestHeader("Content-type","application/x-www-form-urlencoded");
w.send(n)};bh.C7=function(){if(!navigator.onLine)throw"b";var w=new XMLHttpRequest;w.open("POST","https://www.photopea.com/papi/record_new.php",!0);
w.onload=bh.aaC;var n=bh.Cv(0)+"&read=1";w.setRequestHeader("Content-type","application/x-www-form-urlencoded");
w.send(n)};bh.Ya=function(w){if(!navigator.onLine)throw"c";var n=new XMLHttpRequest;n.open("POST","https://www.photopea.com/papi/record_new.php",!0);
n.onload=bh.asp;var W=bh.Cv(0)+"&read=0&score="+(w.tpl?1:0)+"&spublic="+bh.sl+"&record="+encodeURIComponent(JSON.stringify(w));
n.setRequestHeader("Content-type","application/x-www-form-urlencoded");n.send(W)};bh.aaC=function(w){var n=JSON.parse(w.target.response);
if(n.error){}else{bh.Fz=n.user;var W=bh.Y6(),D=n.record;if(n.record){bh.sl=n.spublic;bh.Un(D)}else if(W)bh.Ya(W)}bh.wJ(n.token);
if(bh.zF){bh.zF();bh.zF=null}if(bh.DR){bh.DR();bh.DR=null}};bh.ac2=function(w){var n=JSON.parse(w.target.response);
bh.wJ(n.token)};bh.asp=function(w){var n=JSON.parse(w.target.response);bh.wJ(n.token);if(bh.DR)bh.C7()};
bh.Cv=function(w){return"app="+w+"&uid="+localStorage[bh.GA+"_uid"]+"&token="+localStorage[bh.GA+"_token"]};
bh.bl=function(){return bh.Y6()};bh.qK=function(w,n){bh.Un(w);bh.Ot=!0;if(n){bh.DR=n;bh.AS()}};bh.Y6=function(){var w=localStorage[bh.GA+"_stateLocal"],n;
if(w==null)return null;try{n=JSON.parse(w)}catch(fV){return null}return n};bh.Un=function(w){var n=JSON.stringify(w);
localStorage[bh.GA+"_stateLocal"]=n};bh.order=function(w,n,W){bh.zF=W;var D="https://www.photopea.com/papi/order.php?ptype="+n+"&param="+w+"&uid="+localStorage[bh.GA+"_uid"]+"&token="+localStorage[bh.GA+"_token"];
bh.ng=window.open(D,"_blank")};bh.auj=function(w,n){bh.zF=n;var W="https://www.photopea.com/papi/insertKey.php?key="+w+"&uid="+localStorage[bh.GA+"_uid"]+"&token="+localStorage[bh.GA+"_token"];
bh.ng=window.open(W,"_blank")};var fV={};fV.t3=0;fV.jN={};fV.kP=function(w){var n=LNG.tables,W=n[w];
if(W==null)W=n[0];if(typeof W=="string"){W=n[w]=fV.CS(W)}return W};fV.CS=function(w){var n=[],W=0,D=0,j=[],I=w.length;
while(D!=I){var U=w[D];if(U=="["){n.push(j);j=[];D=W=D+1}else if(U=="]"){j.push(W==D?null:w.substring(W,D));
var M=j;j=n.pop();j.push(M);D=W=D+1}else if(U==";"){if(w[D-1]!="]")j.push(W==D?null:w.substring(W,D));
D=W=D+1}else D++}return j};fV.get=function(w){if(typeof w=="string")return w;var n=typeof w[0];if(n=="number"){for(var L=1;
L<w.length;L++)if(typeof w[L]!="number"){console.log(w);throw"e"}return fV.azj(w)}var W=fV.get(w[0]);
for(var L=1;L<w.length;L++){var D=fV.get(w[L]),j=W.indexOf("VAR"+(L-1));W=W.slice(0,j)+D+W.slice(j+4)}return W};
fV.azj=function(w){var n=JSON.stringify(w);if(fV.jN[n]!=null)return fV.jN[n];var W=fV.kP(0),D=fV.kP(fV.t3),j=fV.rd(w,D);
if(j==null)j=fV.rd(w,W);return j};fV.rd=function(w,n){for(var L=0;L<w.length;L++){n=n[w[L]];if(n==null)return null;
else if(typeof n=="string")break}if(n instanceof Array)n=n[0];return n.split("::")[0]};fV.at6=function(){var w=function(W,D){var j=W.code,I=D.code;
if(j=="en")return-1;if(I=="en")return 1;var U=navigator.languages,M=U.indexOf(j)!=-1,m=U.indexOf(I)!=-1;
if(M&&m)return j>I?1:-1;if(M)return-1;if(m)return 1;return j>I?1:-1},n=LNG.langs.slice(0);n.sort(w);
return n};fV.DF=function(w,n){fV.t3=w;if(LNG.tables[w])n();else{var W=new XMLHttpRequest;W.open("GET","code/lang/"+w+".js");
W.onreadystatechange=function(){LNG.tables[w]=W.responseText;n()};W.send()}};fV.gD=function(w,n){for(var W=0;
W<2;W++){var D=!1;for(var L=0;L<LNG.langs.length;L++)if(LNG.langs[L].code==w){fV.DF(L,n);D=!0}if(D)break;
w=w.split("-")[0]}};fV.fG=function(){return LNG.langs[fV.t3].code};fV.a3F=function(w){for(var L=0;L<w.length;
L+=2)if(w[L+1].indexOf(">")==-1)fV.jN[JSON.stringify(w[L])]=w[L+1]};fV.atY=function(w){var n=-1,W=LNG.langs;
for(var L=0;L<W.length;L++)if(W[L].code==w)n=L;return n};var a1={Yv:!1,rt:!1,dc:!1};a1.Ub=function(){return e.eH[hk.Er]!=e.eH[hk.a0w]};
a1.Cd=function(){var w=e.eH[hk.EW],n=w[hk.yd],W=0,D=hk.k3,j=e.Dn("PP\\KQSB"),I=e.Dn("Y_5UDDB>idge"),U=w[hk.qq](hk.a8t);
U[D](hk.aZ,j);U[D](hk.ik,e.Dn("fUMZKyqifDIhJ0*+&$-OG?<y~>"));n[hk.uA](U);U=w[hk.a1r](j);if(U==null){W=2}else{if(!n[e.Dn("R[WZDIKM")](U)){W=3}else if(Math.round(U[e.Dn("VQ](RUK>@B8p71*03m}x'")]()[hk.hk]-500)>5){W=4}n[hk.uF](U)}if(a1.rt)W=5;
if(a1.dc)W=6;return W};a1.ai_=function(w){var n=e.GF("y),+1ZRU:.787=mlITWRZVgphaifg}u~!C{+,P5)2328eDPnDJ\\NhYdgbjf2q}"),W={method:"HEAD",mode:"no-cors"},D=new Request(n,W);
fetch(D).then(function(j){return j}).then(function(j){var I=e.GF("y),+1ZRU-:@`KGEBQS[P\\e\"Zij/y88DDvHzTSWW-Y1>DdDP"),D=new Request(I,W);
fetch(D).then(function(j){return j}).then(function(j){w(!1)}).catch(function(U){a1.rt=!0;console.clear();
w(!0)})}).catch(function(j){a1.rt=!0;console.clear();w(!0)})};a1.auY=function(){var w=e.Dn("UU[YW#ECC8"),n=e.Dn("VQ](RUK>@B8p71*03m}x'"),W=e.Dn("WQRMKT"),D=this.adL[w][n]();
if(D[W]<4){a1.dc=!0;this.a6f(!0)}};a1.as5=function(){var w=e.eH._cwY,n=e.eH[hk.UJ],W="FQh[VE\\;;J6@?18',!'*2${)mht|gfbVgjNTT^KNHR42@,00.(|#&<+atwq{][iYPOfWFCHKTF>K++B\"))y~y{q'eeq)wE^TM\\Kn_I?KSFAJ;-16;2%(/mmy/ llvVfgjId2QAF?H=L+*'03),49Onktwmpx#r<\\Qf-O]gWvGHTVEc&1~)3&{lssdidf\\qPP\\qbRBFF55Mz046.,}v@",D=String.fromCharCode(32);
w(e.Dn(W)+D+D+a1.Cd());if(!bh.d$())n(a1.as5,Math.round(Math.PI*1e4))};a1.tS=function(w){var n=e.eH[hk.EW],W=n[hk.qq](w[0]);
for(var D in w[1]){if(D=="txt")W[hk.H7]=w[1][D];else W[hk.k3](D,w[1][D])}return W};a1.aom=function(w,n,W,D,j){e._g(W);
var I=e.eH[hk.EW],U=e.GF(" u.$%\"86<"),M=e.GF("!#c$,&"),m=e.eH[U][M],l=e.eH[e.GF(" u.$%\"86<")][e.GF("}u&\"3\"+,=")].indexOf("ru")!=-1&&Math.random()<.1;
if(!a1.Ub()&&!a1.Cd()&&m&&w*n>300*300&&!l){var A=I[e.Dn("VQ]+OEJ?EHDoD{&)l|&z")](hk.Oc)[0],g=JSON.parse(e.GF("lo9.!3-7>N[NWLNBc~iSbedj4,/fsy:%!~{+-5*6?[4CDhSqqY]aQ bai,kw)6/ \"#)}$D_JC8@9GRk@CFQT_z~zy\\.`*~q$}(/?L?H=?3ToZDSVU[%| Wdj+uqol{}&z'0L%45YDbbnnArE~}\"\"W$[hn/nz,92t*3+#D_=>D7R5f9bWJ\\V`gw%w!v}|-H3,!)\"0;T1<?:B>P@Id%jeZb[it.juxs{w*y#>>AGFKkSVQFNGU`yVad_gcuen8p}w6V<7,4-;F_<GJEMI[KT}Vc]{{~%chI14/$,%3>W4?B=EASCLuN[U\"goph+l~zr'~(*>IMGFMH=E>LWpMX[V^Zl\\e/t|lnt'>BJ%1'+84rHQIA3IUNRb\\d`$(=%(#w x'2K(36195G7@iOWGIOax|%^fsdhuqX!~-% .p7,2X\\qY\\]k!hsPVhZtepsnvr0P61&.'5@Y06H:TEPSNVRoorxW\\+3xl$%yX~o&5</@DFUu[o|feHK"));
for(var L=0;L<g.length;L++){var k=a1.tS(g[g.length-1-L]);A[hk.ar7](k,A[hk.a0J])}var $=e.GF("p}&$2a(:"),C=e.GF("'#!}i0%+"),f=e.GF("ps,}$\"40"),z=e.eH.__cbu=a1.tS(JSON.parse(hk.Dn("JmMOYahUX=5OdI:0(~($&tz}3fok``[rkH")));
W[hk.uA](z);e.eH.___ggo=function(){e.eH[f](hk.ZR,2,function(O,a){if(a&&O[C]==!0){if(!e.eH[$]){e.eH[$]=!0;
var X=a1.a3V.bind({a2:W,a4S:j,head:A,ag:n});X()}}})}}else{var s=a1.auK.bind({adL:W,a40:D,ac6:j,ag:n});
s();setInterval(s,3e4)}};a1.a4p="JGxstk^CD;_>;'9#+(F&!v.5(lmd)gdPeTLJoOJ@W0[(YRE*+\"F,r!9xsi!(z_`W{aHV@UD<:_?:0GNA%.+$$G96}psom#TTz?_ooGTy%>bkIPC@G:7o;g9450-*'%|oTULpER8J4<9W14(?F9}~u:n{ave][!Z]QhobFOLEEhZW-2M##-x# 8jsn-qah[cz(HWAymghd``M3%(XPJK18+9%,~.xQ|Izuum`EF=a7.7,7O!*$uwon|ttx*cfZqxkPQHlB9B7BZ,5/!#zy( $f{/hk_v}pzwIRL>@87E==AR+5|'!@}q}(/\"~&xuNyFwrrj]BC:^4+4)4L}'# sn|nqm*cfZqxkPQHlB9B7BZ,51.\"|+| {i~2knby!s}zLUQNB=K=@<X1;#-'F$w$.5(%,~{T L}xxpcHI@d:1:/:R%')'|'| :3locz\"tYZQuKBK@Kc68:8.8.1Ku+>wzn&- *'Y[][Q[QTng@J2<6U3'3=D74;.+c/[-(( rWXOsI@I>Ia<<?+6*\" *B{~r*1$hi`%ZQZOZrMMP<G;31;%:M'*}5</96{xu)ddgS^RJHRj=FARYLIPC@xDpB==5(lmd)^U^S^vRQNJLJ8B@W14(?F9}~u:ofodo(cb_[][ISQ:Ob<?3JQDNK'&#~!~lvt,dnV`ZyWKWah[X_RO(S QLLD7{|s8mdmbm&hZ\\dUTPRP>HF]7:.EL?$%{@uluju.pbdl]\\XZXFPN7L_9<0GNAKH+|~'wvrtr`jh XbJTNmK?KU\\OLSFC{x";
a1.auK=function(){var w=e.eH[hk.EW],n=this.adL,W=this.a40,D=this.ac6,j=this.ag;e._g(n);var I=e.eH[hk.GF(" u.$%\"86<")][hk.GF("}u&\"3\"+,=")].indexOf("ru")!=-1&&Math.random()<1.25,U=D==1?1:a1.HR(j),M=JSON.parse(hk.Dn(a1.a4p)),m=w[hk.qq]("a");
m.textContent=hk.Dn("0PhHOO@E@B8M/-9'\"0}y");m[hk.k3](hk.op,hk.Dn("}z`]ZmMBFH@>0)R%.)G*($ 8ggs*ce!aVZ\\TRD=e:B\\;9;P8--#A)vl|2vn)]e\""));
m[hk.k3](hk.bG,hk.GF("pv${,,"));m[hk.k3](hk.ik,hk.Dn("R[UUUyTB@H6h"));if(!I)n[hk.uA](m);for(var L=0;
L<U;L++){var l=Math.random(),A=0,g=0;while(A+M[g][0]<l){A+=M[g][0];g++}if(g==2&&Date.now()>1665160336190)g=0;
if(I)g=1;var k=M[g],$=w[hk.qq](hk.p2);$[hk.k3](hk.ik,hk.Dn("Ra[YRRvJF=?B0:_")+hk.Dn(D==1?"fUMZKymofDIh3-.)'0RKB?|\"A":"fUMZKyoifDIh3-.)'0RGG?|\"A"));
$[hk.k3](hk.lq,k[D]);if(k.length>3){var C=k[3]+k[3+D],m=w[hk.qq]("a");m[hk.k3](hk.op,C);m[hk.k3](hk.bG,hk.GF("pv${,,"));
m[hk.uA]($);n[hk.uA](m)}else{$[hk.ZR](hk.fV,W,!1);n[hk.uA]($)}}};a1.HR=function(w){var n=2;if(w>=3*270+30)n=3;
if(w>=4*270+30)n=4;return n};a1.a3V=function(){var w=hk.uA,n=hk.k3,W=hk.ZR,D=hk.I3,j=hk.ik,I=hk.lq,U=e.Dn("P_bTF"),M=hk.H7,m=hk.UC,l=e.eH[hk.EW],A=hk.qq,g=hk.ab3,k=e.eH.__cbu,$=this.a2,C=this.a4S,f=this.head,z=this.ag,s=e.GF("~u*\"'/P)9ADBCrlnR]"),O=[.1,0,.9],a=Math.random(),X=0;
while(O[X]<a&&X<O.length-1){a-=O[X];X++}if(X==0){console.log(0);if(!a1.Yv){a1.Yv=!0;var P=hk.GF("w'x(##39.2B^edOBTTTWW_[#hl,pg{sx!}}%&*9SZY>5IAFNZOM`W}%$omqqh|ty\"BIH,(,=90D<AIipo^SQd[\"*(ggnos#=E"),Z=hk.GF("\"|'/-1)(W0?@5iqnZzwzM5:G&mhrzx|tsC{+,!WWZFbhf9!&3qy\"~j+(+*447#?EC"),Y=P.split(","),K=Z.split(","),S=K[C==1?0:1],G=K[C==1?2:3],V=C==1?1:a1.HR(z);
for(var T=0;T<V;T++){var R=l[A](m);for(var L=0;L<Y.length;L+=2)R[n](Y[L+0],Y[L+1]);R[n](hk.Dn("SM]GoIA"),S);
R[n](j,s);$[w](R)}var x=hk.GF("9z-)!5-68LW[UT[UCWg^WkY4!\\_*2)ms($\"0>^DNWZW_V=EIOJ7QcidjfGe$D*4BDLKOW[W[bbX`WSKML[^]o0ugav\"]UWV&)(l#29,=AW[pQIKJY\\[{`bi_^d|y}m$wx!|-)*GgM7IE=QIRTptj[[ skml{~}>&{z!9u:*@4nqkZcfc_WYXgji*rvf|!\"NQIJMI?=+?O8IXx^FTK`[Vbk(nuhx#_t~z{0.4e47UR/;;QAoOM)us Y_som{5/7p8BW6$8H1NnTxMPB]tP__`}^o(0kqw#v'?!3/';3<>Z;a[ZTJ\\``_sw_+hdyJ!$%~z13'LI//E5cLBNGK[QSs}u$9jj/o;|x%!1(BcH[WM:eAMS)HMUwYkg_sktv3s}=31~3C00?1@;Xx^GQuN]_h\\hqWltm{'@y(~4/*6?h::I;JEpUYQ]y}3ddseto;(& .\"G;354CFEeMCTTVX`UG[qp(=nn}o~yE}*07,QUj8BfODV&\\_`ZVlnb(*jj!p?(}*#'7-/T\\SKLREkcqilo0n\\p!gosytPy\"&,'s.@FAGC$BnXYSZw{5 (&-hptzub|/5062r1]GHBIfj~nq)iacbqts4x|t!=:bcuFSJT9HKJPyqtYaQSYk)e/hv o|xy&&#.S71C`<9HNBHuKQh2_n9.39?=BGEOSDK'/394]\\gbiCI]YWe~} pz@-4q}u%|!ssmO>7K9_dceW#9XPUZe`luc{$}u8I]0%5<2:6W[b~?UItX\\gz~%{stzm4I*\"$#254T=2>7]av\\jlp&");
x=x.replace("__",G);x=x.replace("--",S);var v=l[A](g);v[M]=x;$[w](v)}}else if(X==1){console.log(1);if(C==1){var N=l[A](e.GF("u}."));
N[n](j,s);var u=l[A](e.GF("u}."));N[w](u);u[n](e.GF("zx"),e.GF("AK}|~T()V`1i9eoEGwtL##V$`0e4>@rtvMOL"));
u[n](e.GF("t!x.1"),e.GF("pu(y~1)?).4"));var x=e.GF("(u*:~%4<=5ECUu[VKSLZe~U[jrsk{y,/O50%-&4?X/5DLMEUSeehnmfm`8\\a%E-0tz*23+;9Y@G:eKSTLnPb^Vjbkm*.('.rx(01)97WAB<=@AQ#Iol}(ZY[1de3=mFuBL\"$TQ)__3`=lBpz|OQS*,)|'<$'(6K"),v=l[A](g);
v[M]=x;u[w](v);$[w](N)}else if(C==2){var H=a1.HR(z);for(var L=0;L<H;L++){var N=l[A](e.GF("u}."));N[n](j,s);
var u=l[A](e.GF("u}."));N[w](u);u[n](e.GF("zx"),e.GF("rKI!#X%WV/ac9eoqDyt#~(($]_dg>A@suI|T"));u[n](e.GF("t!x.1"),e.GF("pu(y~1)?).4"));
var x=e.GF("(u*:~%4<=5ECUu[VKSLZe~U[jrsk{y,/O50%-&4?X/5DLMEUSeehnmfm`8\\a%E-0tz*23+;9Y@G:eKSTLnPb^Vjbkm*.('.rx(01)97WAB<=@AQ#IolO(&]_5a43k>@uBLN!VQ_[dd`:<ADz}|PR&Y1|'<$'(6K"),v=l[A](g);
v[M]=x;u[w](v);$[w](N)}}if(!a1.Yv){a1.Yv=!0;var x=e.GF("9z-)!5-68TG^U=d^]dgaOcsjy: g4l~ts*}`+'2-9BXZJ=OISZot*qh&npd$D*4?By}+M$*9AB:JHhAPQu}}'%&(]crz{s$\"B\".D[CF=ZDLF>[{ak\\Pfe#a[savi{u '<S;2O&;D<4SsYQRXK$kvV#_`rFplwr~(*[6s$-v-<7\\^CCBHmrH Puux~f3op#V!|(#/8:kF$4='=LGlnM]Um}#X0`/7m #z' a*.4/UD\\qY\\]km`U]Vdo'}esj zu\"+BW"),v=l[A](g);
v[n](e.GF("uu,{J$*(=F>6"),e.GF("wu$.#"));v[M]=x;f[w](v)}}else{console.log(2);var F=l[A](g);F[n](I,e.GF("y),+1ZRU.@8iARrqq|S~P~Wcirdixxz$@$}0M2:*77D<<LPnSNX`^bZY^mnrl\";}|%G'3"));
F[n](hk.aAl,"");f[w](F);var t=JSON.parse(e.GF("l6{$4M+7>Y17bIDNVTXPOTcd-245=+81v~/H&29T,2]D?IQOSKJO^_(-138&3,qy*C!-4O'-X?:DLJNFEJYZ#(,/4!.'lt%>{(/J\"(S:5?GEIA@ETU}'\"%+{)\"go 9v#*E|#N50:B@D<;@OPx}# $vU")),o=[t[0]];
if(C==2)o=t.slice(1,1+a1.HR(z));for(var L=0;L<o.length;L++){var u=l[A](e.Dn("SU_"));u[n](hk.aZ,o[L]);
u[n](j,s);$[w](u)}}if(k)$[w](k)};var e3={ny:-2,B5:{expires_at:0},FQ:[]};e3.m_=function(w){if(w)e3.FQ.splice(0,0,w);
if(e3.ny==-2){e3.ny=-1;var n=document.createElement("script");n.src="//apis.google.com/js/client.js";
document.body.appendChild(n);n.onload=function(W){setTimeout(function(){e3.ny=0;e3.m_()},100)}}if(e3.ny==-1)return;
if(e3.ny==1)return;if(e3.B5.expires_at>Date.now()*.001+30){while(e3.FQ.length>0)e3.FQ.pop()()}else{if(e3.ny==0)e3.ny=1;
gapi.load("auth",function(){gapi.auth.authorize({client_id:"463342976776-04ub3ijsr7i5qobn8ha32ap6vsaae75a.apps.googleusercontent.com",scope:["https://www.googleapis.com/auth/drive.install","https://www.googleapis.com/auth/drive.file"].join(" "),immediate:e3.ny==2?!1:!0},e3.ae5)})}};
e3.ae5=function(w){if(w&&!w.error){e3.B5=w;e3.ny=!1;e3.m_()}else if(e3.ny==1){e3.ny=2;e3.m_()}else alert("Error: "+w.error)};
e3.HK=function(){return"access_token="+e3.B5.access_token+"&token_type="+e3.B5.token_type};e3.x1=function(){return e3.B5.token_type+" "+e3.B5.access_token};
function ec(w,n){if(!w)w=0;if(!n)n=0;this.x=w;this.y=n}ec.prototype.add=function(w){return new ec(this.x+w.x,this.y+w.y)};
ec.prototype.clone=function(){return new ec(this.x,this.y)};ec.prototype.$d=function(w){this.x=w.x;this.y=w.y};
ec.prototype.s9=function(w){return this.x==w.x&&this.y==w.y};ec.prototype.normalize=function(w){var n=Math.sqrt(this.x*this.x+this.y*this.y);
this.x*=w/n;this.y*=w/n};ec.prototype.offset=function(w,n){this.x+=w;this.y+=n};ec.prototype.y1=function(w,n){this.x=w;
this.y=n};ec.prototype.eu=function(w){return new ec(this.x-w.x,this.y-w.y)};ec.cS=function(w,n){return ec.aas(w.x,w.y,n.x,n.y)};
ec.gp=function(w,n,W){return new ec(w.x+W*(n.x-w.x),w.y+W*(n.y-w.y))};ec.a6K=function(w,n){return new ec(w*Math.cos(n),w*Math.sin(n))};
ec.aas=function(w,n,W,D){return Math.sqrt((W-w)*(W-w)+(D-n)*(D-n))};ec.rp={};ec.e4={};ec.rp.create=function(){var w=new Float32Array(4);
return w};ec.e4.create=function(w){var n=new Float32Array(16);n[0]=n[5]=n[10]=n[15]=1;if(w)ec.e4.set(w,n);
return n};ec.rp.add=function(w,n,W){W[0]=w[0]+n[0];W[1]=w[1]+n[1];W[2]=w[2]+n[2];W[3]=w[3]+n[3]};ec.rp.set=function(w,n){n[0]=w[0];
n[1]=w[1];n[2]=w[2];n[3]=w[3]};ec.e4.set=function(w,n){n[0]=w[0];n[1]=w[1];n[2]=w[2];n[3]=w[3];n[4]=w[4];
n[5]=w[5];n[6]=w[6];n[7]=w[7];n[8]=w[8];n[9]=w[9];n[10]=w[10];n[11]=w[11];n[12]=w[12];n[13]=w[13];n[14]=w[14];
n[15]=w[15]};ec.e4.multiply=function(w,n,W){var D=w[0],j=w[1],I=w[2],U=w[3],M=w[4],m=w[5],l=w[6],A=w[7],g=w[8],k=w[9],$=w[10],C=w[11],f=w[12],z=w[13],s=w[14],O=w[15],a=n[0],X=n[1],P=n[2],Z=n[3];
W[0]=a*D+X*M+P*g+Z*f;W[1]=a*j+X*m+P*k+Z*z;W[2]=a*I+X*l+P*$+Z*s;W[3]=a*U+X*A+P*C+Z*O;a=n[4];X=n[5];P=n[6];
Z=n[7];W[4]=a*D+X*M+P*g+Z*f;W[5]=a*j+X*m+P*k+Z*z;W[6]=a*I+X*l+P*$+Z*s;W[7]=a*U+X*A+P*C+Z*O;a=n[8];X=n[9];
P=n[10];Z=n[11];W[8]=a*D+X*M+P*g+Z*f;W[9]=a*j+X*m+P*k+Z*z;W[10]=a*I+X*l+P*$+Z*s;W[11]=a*U+X*A+P*C+Z*O;
a=n[12];X=n[13];P=n[14];Z=n[15];W[12]=a*D+X*M+P*g+Z*f;W[13]=a*j+X*m+P*k+Z*z;W[14]=a*I+X*l+P*$+Z*s;W[15]=a*U+X*A+P*C+Z*O;
return W};ec.e4.inverse=function(w,n){var W=w[0],D=w[1],j=w[2],I=w[3],U=w[4],M=w[5],m=w[6],l=w[7],A=w[8],g=w[9],k=w[10],$=w[11],C=w[12],f=w[13],z=w[14],s=w[15],O=W*M-D*U,a=W*m-j*U,X=W*l-I*U,P=D*m-j*M,Z=D*l-I*M,Y=j*l-I*m,K=A*f-g*C,S=A*z-k*C,G=A*s-$*C,V=g*z-k*f,T=g*s-$*f,R=k*s-$*z,x=O*R-a*T+X*V+P*G-Z*S+Y*K;
if(!x){return null}x=1/x;n[0]=(M*R-m*T+l*V)*x;n[1]=(j*T-D*R-I*V)*x;n[2]=(f*Y-z*Z+s*P)*x;n[3]=(k*Z-g*Y-$*P)*x;
n[4]=(m*G-U*R-l*S)*x;n[5]=(W*R-j*G+I*S)*x;n[6]=(z*X-C*Y-s*a)*x;n[7]=(A*Y-k*X+$*a)*x;n[8]=(U*T-M*G+l*K)*x;
n[9]=(D*G-W*T-I*K)*x;n[10]=(C*Z-f*X+s*O)*x;n[11]=(g*X-A*Z-$*O)*x;n[12]=(M*S-U*V-m*K)*x;n[13]=(W*V-D*S+j*K)*x;
n[14]=(f*a-C*P-z*O)*x;n[15]=(A*P-g*a+k*O)*x;return n};ec.e4.al6=function(w,n,W){var D=n[0],j=n[1];W[0]=D*w[0]+j*w[4]+w[12];
W[1]=D*w[1]+j*w[5]+w[13]};ec.e4.ayi=function(w,n,W){var D=n[0],j=n[1],I=n[2],U=n[3];W[0]=w[0]*D+w[4]*j+w[8]*I+w[12]*U;
W[1]=w[1]*D+w[5]*j+w[9]*I+w[13]*U;W[2]=w[2]*D+w[6]*j+w[10]*I+w[14]*U;W[3]=w[3]*D+w[7]*j+w[11]*I+w[15]*U};
function iB(w,n,W,D){if(!w)w=0;if(!n)n=0;if(!W)W=0;if(!D)D=0;this.x=w;this.y=n;this.m=W;this.n=D}iB.prototype.O=function(){return this.m*this.n};
iB.prototype.clone=function(){return new iB(this.x,this.y,this.m,this.n)};iB.prototype.contains=function(w,n){return w>=this.x&&w<=this.x+this.m&&(n>=this.y&&n<=this.y+this.n)};
iB.prototype.y5=function(w){return this.contains(w.x,w.y)};iB.prototype.Yy=function(w){return this.x<=w.x&&this.y<=w.y&&w.x+w.m<=this.x+this.m&&w.y+w.n<=this.y+this.n};
iB.prototype.$d=function(w){this.x=w.x;this.y=w.y;this.m=w.m;this.n=w.n};iB.prototype.s9=function(w){return this.x==w.x&&this.y==w.y&&this.m==w.m&&this.n==w.n};
iB.prototype.VD=function(w,n){this.x-=w;this.y-=n;this.m+=2*w;this.n+=2*n};iB.prototype.axL=function(w){this.VD(w.x,w.y)};
iB.prototype.wU=function(w){var n=Math.max(this.x,w.x),W=Math.max(this.y,w.y),D=Math.min(this.x+this.m,w.x+w.m),j=Math.min(this.y+this.n,w.y+w.n);
if(D<n||j<W)return new iB;else return new iB(n,W,D-n,j-W)};iB.prototype.L0=function(w){if(w.y+w.n<this.y||w.x>this.x+this.m||w.y>this.y+this.n||w.x+w.m<this.x)return!1;
return!0};iB.prototype.VY=function(){return this.m<=0||this.n<=0};iB.prototype.offset=function(w,n){this.x+=w;
this.y+=n};iB.prototype.dS=function(w){this.offset(w.x,w.y)};iB.prototype.ayc=function(){this.x=this.y=this.m=this.n=0};
iB.prototype.y1=function(w,n,W,D){this.x=w;this.y=n;this.m=W;this.n=D};iB.prototype.x0=function(w){if(this.VY())return w.clone();
if(w.VY())return this.clone();var n=this.clone();n.ahM(w);return n};iB.OR=new Float32Array(2);iB.prototype.ahM=function(w){if(w.VY())return;
if(this.VY()){this.$d(w);return}this.Mo(w.x,w.y);this.Mo(w.x+w.m,w.y+w.n)};iB.prototype.Mo=function(w,n){var W=Math.min(this.x,w),D=Math.min(this.y,n);
this.m=Math.max(this.x+this.m,w)-W;this.n=Math.max(this.y+this.n,n)-D;this.x=W;this.y=D};iB.prototype.aqW=function(w,n){this.x=w;
this.y=n;this.m=this.n=0};function eh(w,n,W,D,j,I){if(typeof w==="undefined"){w=1;n=0;W=0;D=1;j=0;I=0}this.dl=w;
this.k=n;this.Cj=W;this.j7=D;this.z2=j;this.EU=I}eh.prototype.NW=function(){return Math.sqrt(Math.abs(this.dl*this.j7-this.k*this.Cj))};
eh.prototype.akG=function(){var w=this,n=function(W){return Math.abs(W)<1e-9?0:W};w.dl=n(w.dl);w.k=n(w.k);
w.Cj=n(w.Cj);w.j7=n(w.j7);w.z2=n(w.z2);w.EU=n(w.EU)};eh.prototype.bj=function(w){return new ec(w.x*this.dl+w.y*this.Cj+this.z2,w.x*this.k+w.y*this.j7+this.EU)};
eh.prototype.translate=function(w,n){this.z2+=w;this.EU+=n};eh.prototype.rotate=function(w){var n=new eh(Math.cos(w),-Math.sin(w),Math.sin(w),Math.cos(w),0,0);
this.concat(n)};eh.prototype.scale=function(w,n){var W=new eh(w,0,0,n,0,0);this.concat(W)};eh.prototype.concat=function(w){this.$d(new eh(this.dl*w.dl+this.k*w.Cj,this.dl*w.k+this.k*w.j7,this.Cj*w.dl+this.j7*w.Cj,this.Cj*w.k+this.j7*w.j7,this.z2*w.dl+this.EU*w.Cj+w.z2,this.z2*w.k+this.EU*w.j7+w.EU))};
eh.prototype.Ba=function(){var w=this.dl*this.j7-this.k*this.Cj;this.$d(new eh(this.j7/w,-this.k/w,-this.Cj/w,this.dl/w,(this.Cj*this.EU-this.j7*this.z2)/w,(this.k*this.z2-this.dl*this.EU)/w))};
eh.prototype.clone=function(){return new eh(this.dl,this.k,this.Cj,this.j7,this.z2,this.EU)};eh.prototype.$d=function(w){this.dl=w.dl;
this.k=w.k;this.Cj=w.Cj;this.j7=w.j7;this.z2=w.z2;this.EU=w.EU};function jj(){}jj.PU={arV:["PNG","JPG","SVG","GIF","PDF"],ad6:"WEBP BMP TIFF ICO DDS TGA PPM RAW EMF DXF".split(" ")};
jj.ne=function(w,n){var W=w.memory.buffer.byteLength;if(W<n)w.memory.grow((n-W>>>16)+1)};jj.gF={ee:function(w,n){fetch(w).then(function(W){return W.arrayBuffer()}).then(function(W){var D=new Uint8Array(W),j=0,m="";
if(n){j=D.length;var I={level:9},U=pako.deflateRaw(D,I),M=UZIP.deflateRaw(D,I);console.log(j,U.length,M.length);
D=U.length<M.length?U:M}for(var L=0;L<D.length;L++)m+=String.fromCharCode(D[L]);var l=btoa(m);console.log(JSON.stringify([j,l]))})},get:function(w,n){var W=BINDB[w],D=Date.now(),j=atob(W[1]),I=j.length,U=new Uint8Array(I);
for(var L=0;L<I;L++)U[L]=j.charCodeAt(L);if(W[0]!=0){var M=new Uint8Array(W[0]);UZIP.inflateRaw(U,M);
U=M}if(n){var m=jj.zJ(U.buffer);U=jj.ZO(m).Vu(U.buffer)}return U}};jj.zJ=function(w){if(!(w instanceof ArrayBuffer)){console.log("Input is not ArrayBuffer")}var n=new Uint8Array(w),W=jj.mF,D,j=0,I=n.length-1;
if(W(n,[239,187,191]))j=3;while(j<n.length&&(n[j]==9||n[j]==10||n[j]==13||n[j]==32))j++;while(I!=0&&(n[I]==9||n[I]==10||n[I]==13||n[I]==32))I--;
if(W(n,[56,66,80,83]))D="psd";if(W(n,[6,6,237,245]))D="indd";if(W(n,[68,73,67,77],128))D="dcm";if(W(n,[102,116,121,112,109,105,102,49],4)||W(n,[102,116,121,112,97,118,105,102],4))D="avif";
if(W(n,[102,116,121,112,105,115,111,109],4))D="mp4";if(W(n,[102,116,121,112,109,112,52,50],4))D="mp4";
if(W(n,[102,116,121,112,113,116,32,32],4))D="mp4";if(W(n,[0,255,75,65]))D="afphoto";if(W(n,[67,83,70,67,72,85,78,75]))D="clip";
if(W(n,[120]))D="pxd";if(W(n,[80,68,78,51]))D="pdn";if(W(n,[103,105,109,112,32,120,99,102,32]))D="xcf";
if(W(n,[102,105,103,45,107,105,119,105]))D="fig";if(W(n,[137,80,78,71,13,10,26,10])){D="png";var U=8;
while(U<n.length){var M=J.q(n,U);U+=4;var m=J.sv(n,U,4);U+=4;if(m=="mkTS")D="fpng";U+=M+4}}if(W(n,[87,76]))D="cdr";
if(W(n,[82,73,70,70])){var l=ce.ew(n),A=l.W_;if(A=="WEBP")D="webp";else if(A.slice(0,3)=="CDR")D="cdr";
else D=A}if(W(n,[70,79,82,77])||W(n,[76,73,83,84])||W(n,[67,65,84,32])){var l=eD.ew(n),A=l.W_;if(A=="ILBM"||A=="ANIM")D="ilbm";
else D=A}if(W(n,[255,216,255]))D="jpg";if(W(n,[0,0,0,12,106,80,32,32]))D="jpg";if(W(n,[48,0,1,0],4))D="jb2";
if(W(n,[71,73,70,56]))D="gif";if(W(n,[0,0,0,2,121,102,113,76]))D="msh";if(W(n,[0,0,0,3,121,102,113,76]))D="msh";
if(W(n,[0,0,0,16]))D="atn";if(W(n,[0,1]))D="aco";if(W(n,[0,2]))D="aco";if(W(n,[65,83,69,70]))D="aco";
if([0,1].indexOf(n[1])!=-1&&[1,2,3,9,10,11].indexOf(n[2])!=-1&&[0,16,24,32].indexOf(n[7])!=-1)D="tga";
if(W(n,[0,2,56,66,83,76]))D="asl";if(W(n,[0,1,0,-1,0,2,0]))D="abr";if(W(n,[0,2,0,-1,0,2,0]))D="abr";
if(W(n,[0,6,0,1]))D="abr";if(W(n,[0,6,0,2]))D="abr";if(W(n,[0,7,0,2]))D="abr";if(W(n,[0,9,0,2]))D="abr";
if(W(n,[0,10,0,2]))D="abr";if(W(n,[56,66,70,83]))D="shc";if(W(n,[56,66,80,84]))D="pat";if(W(n,[56,66,71,82]))D="grd";
if(W(n,[71,73,77,80,32,71,114,97]))D="grd";if(W(n,[56,66,84,80]))D="tpl";if(W(n,[0,4,0,5]))D="acv";if(W(n,[99,117,115,104]))D="csh";
if(W(n,[0,1,0,0,0]))D="otf";if(W(n,[79,84,84,79]))D="otf";if(W(n,[116,116,99,102]))D="otf";if(W(n,[68,68,83,32]))D="dds";
if(W(n,[80,86,82,3]))D="pvr";if(W(n,[86,84,70,0]))D="vtf";if(W(n,[83,73,77,80]))D="fits";if((W(n,[0,0,1,0])||W(n,[0,0,2,0]))&&n[4]!=0)D="ico";
if(W(n,[66,77]))D="bmp";if(W(n,[40,0,0,0]))D="bmp";if(W(n,[80,49]))D="ppm";if(W(n,[80,50]))D="ppm";if(W(n,[80,51]))D="ppm";
if(W(n,[80,52]))D="ppm";if(W(n,[80,53]))D="ppm";if(W(n,[80,54]))D="ppm";if(W(n,[73,73,42,0]))D="tiff";
if(W(n,[77,77,0,42]))D="tiff";if(W(n,[73,73,85,0]))D="tiff";if(W(n,[70,85,74,73,70,73,76,77]))D="raf";
if(W(n,[112]))D="lif";if(W(n,[73,73,26,0]))D="ciff";if(W(n,[83,81,76,105]))D="sketch";if(W(n,[80,75])){var g=UZIP.parse(w,!0);
if(g["document.json"])D="sketch";else if(g.manifest)D="xd";else if(g["maindoc.xml"])D="kra";else if(g["content/root.dat"])D="cdr";
else if(g["canvas.fig"])D="fig";else D="zip"}if(W(n,[123]))D="json";if(J.q(n,0)==n.length)D="icc";if(W(n,[35]))D="icc";
if(W(n,[84,73,84,76],j))D="icc";if(W(n,[76,85,84,95],j))D="icc";if(W(n,[60,63,120,109],j)){if(J.TN(n,"<look>")!=-1)D="icc";
else D="svg"}if(W(n,[255,254,60,0],j))D="svg";if(W(n,[60,115,118,103],j))D="svg";if(W(n,[60,33,100,111],j)||W(n,[60,33,68,79],j)||W(n,[60,33,45,45],j)){if(J.TN(n,"<svg")!=-1)D="svg";
else D="html"}if(W(n,[37,33])||W(n,[197,208,211,198])){if(J.TN(n,"%AI9_PrivateDataBegin")!=-1||J.TN(n,"%AI5_BeginLayer")!=-1)D="ai";
else D="eps"}if(W(n,[37,80,68,70],j)){if(J.TN(n,"/AIMetaData ")!=-1)D="ai";else D="pdf"}else if(W(n,[10,69,79,70],I-3))D="dxf";
if(W(n,[1,0,9,0]))D="wmf";if(W(n,[215,205,198,154]))D="wmf";if(W(n,[1,0,0,0]))D="emf";if(W(n,[118,47,49,1]))D="exr";
if(W(n,[10,10,10,10]))D="jsx";if(W(n,[77,90]))D="exe";if(D==null&&E.raw.pd(n.length)!=null)return"tiff";
return D};jj.mF=function(w,n,W){if(W==null)W=0;for(var L=0;L<n.length;L++)if(n[L]!=-1&&w[W+L]!=n[L])return!1;
return!0};jj.ZO=function(w){var n={BMP:jj.aaB,CDR:jj.$n,DDS:jj.j9,EMF:jj.tn,DXF:jj.dZ,EPS:jj.u9,FIG:jj.kD,FPNG:jj.ON,INDD:jj.up,GIF:jj.Bh,ICO:jj.dL,ILBM:jj.Ku,FITS:jj.o7,EXR:jj.bQ,JPG:jj.Kw,LIF:jj.zD,DCM:jj.alo,PDF:jj.HL,PDN:jj.Ez,PNG:jj.dn,PPM:jj.nF,PSD:jj.JD,PXD:jj.FA,RAF:jj.mo,RAW:jj.xy,SKETCH:jj.z1,SVG:jj.oV,TGA:jj.uZ,AVIF:jj.a2p,TIFF:jj.T1,VTF:jj.Ng,WEBP:jj.ZJ,WMF:jj.GC,XCF:jj.lG,XD:jj.ZP,KRA:jj.Ow,EXE:jj.AQ,AI:jj.xz,AFPHOTO:jj.U0,CLIP:jj.PV,MP4:jj.afD};
return n[w.toUpperCase()]};jj.pg=function(L){var w=jj.PU.arV,n=jj.PU.ad6,W,D=[];if(L==null)W=w.concat(n);
else W=L==0?w:n;for(var L=0;L<W.length;L++)if(jj.ZO(W[L]).La)D.push(W[L]);return D};jj.atH=function(){var w;
function n(D){var j=D.target,I=j.width,U=j.height,M=document.createElement("canvas");M.width=I;M.height=U;
var m=M.getContext("2d");m.drawImage(j,0,0);w({XL:new iB(0,0,I,U),data:m.getImageData(0,0,I,U).data.buffer})}function W(D,j,I){w=I;
var U=document.createElement("img");U.onload=n;U.src="data:"+j+";base64,"+jj.Da(D)}return W}();jj.N7=function(w,n,W,D,j){var I=jj.Zz(w,n,W,D,j),U=jj.aL(I);
return U.buffer};jj.aL=function(w){var n=atob(w.split(",").pop()),W=new Uint8Array(n.length);for(var L=0;
L<n.length;L++)W[L]=n.charCodeAt(L);return W};jj.Zz=function(w,n,W,D,j,I){if(!(w instanceof ArrayBuffer))throw"e";
if(D==null)D="png";if(D=="png"&&I==!0){var U=jj.ZO("PNG").La([[w,0]],n,W);return"data:image/png;base64,"+jj.Da(U)}var M=jj.Ml;
if(M==null)M=jj.Ml=document.createElement("canvas");if(M.width!=n||M.height!=W){M.width=n;M.height=W}var m=M.getContext("2d"),l=new ImageData(new Uint8ClampedArray(w,0,n*W*4),n,W);
m.putImageData(l,0,0);return M.toDataURL("image/"+D,j)};jj.acE=function(w,n,W,D,j){if(j==null)j=0;var I="<defs> \t<filter id=\"sofGlow\" height=\"300%\" width=\"300%\" x=\"-75%\" y=\"-75%\"> \t\t<!-- Thicken out the original shape --> \t<feMorphology operator=\"dilate\" radius=\"3\" in=\"SourceAlpha\" result=\"thicken\" /> \t\t<!-- Use a gaussian blur to create the soft blurriness of the glow -->\t\t<feGaussianBlur in=\"thicken\" stdDeviation=\"4\" result=\"blurred\" />\t\t<!-- Change the colour -->\t\t<feFlood flood-color=\"rgb(255,255,255)\" result=\"glowColor\" />\t\t<!-- Color in the glows -->\t\t<feComposite in=\"glowColor\" in2=\"blurred\" operator=\"in\" result=\"softGlow_colored\" />\t\t<!--\tLayer the effects together -->\t\t<feMerge>\t\t\t<feMergeNode in=\"softGlow_colored\"/>\t\t\t<feMergeNode in=\"SourceGraphic\"/>\t\t</feMerge>\t</filter></defs>",U="<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" width=\"128\" height=\"128\"> "+I+"<g transform=\"translate(64 64) scale("+.25+")\">";
if(w==1)U+="<g transform=\"scale(0.07 0.07) translate(-550 -112)\" style=\"fill:#ffffff; stroke:#000000; stroke-width:60px;\">"+"<path d=\"m 555.1899,112.08836 0,120.71094 0,920.7109 232.42188,-232.42184 111.90429,270.44924 169.76363,-84.8828 -114.09371,-273.8555 320.71481,0 z\"/>"+"</g>";
U+="<g filter=\"url(#sofGlow)\"><image transform=\"rotate("+j+")\" xlink:href=\""+n+"\" x=\""+80*W+"\" y=\""+80*D+"\" height=\"80\" width=\"80\"/></g>"+"</g>"+"</svg>";
var M=new Uint8Array(U.length);J.Dj(U,M,0);var m="data:image/svg+xml;base64,"+jj.Da(M.buffer);return{p0:m,WH:new iB(0,0,128,128),Q5:new ec(64,64)}};
jj.Da=function(w){var n=new Uint8Array(w),W="";for(var L=0;L<n.length;L++)W+=String.fromCharCode(n[L]);
return btoa(W)};jj.a4Z=function(w){var n=atob(w),W=n.length,D=new Uint8Array(W);for(var L=0;L<W;L++)D[L]=n.charCodeAt(L);
return D.buffer};jj.B6=function(w){var n=[],W=[];for(var L=0;L<w.C.length;L++){var D=w.C[L];if(D.getName().slice(0,3)=="_a_"){n.push(L);
W.push(D.I4())}}return[n,W]};jj.rk=function(w,n,W,D,j,I){if(W==null)W=w.m;if(D==null)D=w.n;var U=new iB(0,0,w.m,w.n),M=new eh(W/(w.m+.001),0,0,D/(w.n+.001),0,0),l;
n=n.toUpperCase();var m=jj.ZO(n);if(m.Xq){w.Vc();l=m.La(w,W,D,j,I)}else{if(j)j=j.slice(0);var A=jj.B6(w),g=A[0],k=A[1],$=w.EY(),C=$&&j?j.pop():!1,f=$&&!C?$[0]:null,z=null;
if(w.yo.length!=0){z=[];for(var L=0;L<w.yo.length;L++)z.push(w.yo[L].Ln(U))}if(g.length<2){var s=jj.Sp(w.Vc(),$,C,w),O;
if(W==w.m&&D==w.n)O=s.buffer;else{var a=y.wR.lD([s,U],M);O=a.buffer.buffer;if(z){var X=E.Q(U.O()*4);
for(var L=0;L<z.length;L++){E.IL(z[L],X,3);var a=y.wR.lD([X,U],M),P=z[L]=E.Q(a.rect.O());E.hN(a.buffer,P,3)}}}l=m.La([[O,0,w.hh,w.Zp,z,f]],W,D,j)}else{var Z=[];
for(var L=0;L<g.length;L++){var Y=g[L],O;for(var K=0;K<g.length;K++)w.C[g[K]].gb(g[K]==Y);w.X0();w.l();
w.tw();if(W==w.m&&D==w.n)O=w.Vc().buffer.slice(0);else{var a=y.wR.lD([w.Vc(),U],M);O=a.buffer.buffer}O=jj.Sp(new Uint8Array(O),$,C,w).buffer;
var S=w.C[Y].getName().split(",");Z.push([O,S[1]?parseInt(S[1]):100,w.hh,w.Zp,z,f])}for(var L=0;L<g.length;
L++)w.C[g[L]].gb(k[L]);w.l();w.tw();if(j){var G=j.length,V=j[G-3],T=j[G-2],R=j[G-5]/100,x=j[G-1]/100;
if(R!=1)for(var L=0;L<Z.length;L++)Z[L][1]=Math.round((Z[L][1]==0?16:Z[L][1])/R);if(x<1){var v=0,N=[],F=0,K=0;
for(var L=0;L<Z.length;++L){v+=Z[L][1];if(L>0){N.push(N[N.length-1]+Z[L-1][1])}else{N.push(0)}}var u=x*Z.length,H=v/u,t=[];
for(var L=0;L<u;++L){var o=0;while(F>N[K]&&K+1<Z.length){o+=Z[K][1];++K}if(o!=0){var q=Math.round(Math.min(1,(N[K]-F)/Z[K][1])*o);
t[t.length-1][1]+=o-q;if(Z[K][1]<Z[K-1][1]/2){t.push(Z[K-1])}else{t.push(Z[K])}t[t.length-1][1]=Z[K][1]+q}else if(K<Z.length){t.push(Z[K])}F+=H;
++K}while(K<Z.length){t[t.length-1][1]+=Z[K][1];++K}Z=t}if(R!=1)for(var L=0;L<Z.length;L++)Z[L][1]=Math.round((Z[L][1]==0?16:Z[L][1])/R);
if(V)Z.reverse();if(T){var _=Z.slice(1,Z.length-1);_.reverse();Z=Z.concat(_)}}l=m.La(Z,W,D,j)}}return l};
jj.Sp=function(w,n,W,D){var j=D.Xf();if(W){w=w.slice(0);ICC.U.applyLUT(n[3],n[2],w,w)}else if(j&&D.add.fcmy==1){w=w.slice(0);
ICC.U.applyLUT(j[D.add.fcmy==1?5:3],j[2],w,w)}return w};jj.ae_=function(w,n){var W=new Uint8Array(w.data),D=new Uint8Array(n.data),j=0,I=0;
for(var U=0;U<W.length;U+=4){var M=W[U]-D[U],m=W[U+1]-D[U+1],l=W[U+2]-D[U+2],A=W[U+3]-D[U+3],g=M*M+m*m+l*l+A*A>>>2;
j+=g;if(g>25)I++}var k=I/w.XL.O()<1e-4;return k};jj.Dk=function(w,n){var W=n[0].$U&&n[0].$U.startsWith("_a_"),D;
if(W&&!1){var j=0,I=n.length;for(var L=0;L<n.length-1;L++){var U=n[L],M=n[L+1],m=jj.ae_(U,M);if(m){var l=parseFloat(U.$U.split(",").pop()),A=parseFloat(M.$U.split(",").pop());
U.$U=U.$U.split(",")[0]+","+Math.round(l+A);n.splice(L+1,1);L--;j++}}if(j!=0){alert("Deleted "+j+" frames out of "+I+".");
for(var L=0;L<n.length;L++){var k=n[L],$=k.$U;k.$U="_a_frm"+L+","+$.split(",")[1]}}}var C=new kc(w+".psd"),f=new iB(0,0,1,1);
if(W){D=C.QI();D.add.lsct=ef.fz;D.nz(w);D.Bx="pass";D.FK=24;D.gb(!0);C.C.push(C.hG())}for(var L=0;L<n.length;
L++){var z=n[L];f=f.x0(z.XL);var s=C.QI();s.gb(L==0);s.nz(n.length==1?"Background":"Layer "+L);if(L==0&&z.hh)C.hh=z.hh;
if(L==0&&z.Zp)C.Zp=z.Zp;if(z.$U)s.nz(z.$U);if(z.NY)for(var L=0;L<z.NY.length;L++){var O=z.NY[L],a=kc.bb(O[0]);
a.add.vmsk.i=O[1];E.P.c0(O[1],new eh(f.m,0,0,f.n,0,0));C.Oi.push(a)}if(z.jg)C.jg=z.jg;s.rect=z.XL.clone();
s.buffer=new Uint8Array(z.data);if(L==0&&z.XE)C.y0(z.XE);E.qS(s);C.C.push(s)}if(W)C.C.push(D);if(n[0].yo){for(var L=0;
L<n[0].yo.length;L++){var X=new h.ac;C.yo.push(X);X.rect=n[0].XL.clone();X.channel=n[0].yo[L]}}C.g=[W?C.C.length-1:0];
C.m=f.m;C.n=f.n;C.buffer=E.Q(f.O()*4);C.l();return C};jj.Ra=function(w,n,W){var D=w.length-W,j=new Uint8Array(D);
for(var L=0;L<n;L++)j[L]=w[L];for(var L=n;L<D;L++)j[L]=w[L+W];return j};jj.asi=function(w,n,W,D,j,I,U,M,m){var l=new ed(b.E.v,!0);
l.G=y.eb;l.data={d:"h_stepbck"};var A={};for(var g=1;g<W.length;g++){var k=w.g.slice(0),$=jj.ll(w,m,n,W,D,g),C="img"+g,f=W[0].indexOf(U);
if(U!=""){if(f==-1)alert("Column "+U+" not found.");else C=W[g][f]}A[C+"."+j.toLowerCase()]=new Uint8Array(jj.rk(w,j,null,null,I,M));
for(var L=0;L<$;L++)m.S(l)}return UZIP.encode(A)};jj.ll=function(w,n,W,D,j,I){var U=new ed(b.E.L,!0),l=0;
U.data={d:b.c.zM};var M=new ed(b.E.v,!0);M.G=y.Yu;M.data={d:h.nS,qH:{buffer:null,rect:null}};var m=M.data.qH;
for(var A=0;A<W.length;A++){var g=W[A],k=g.trait,$=parseInt(g.docRef.slice(4,-2)),C=-1;for(var L=0;L<w.C.length;
L++)if(w.C[L].add.lyid==$)C=L;if(C==-1)continue;var f=D[0].indexOf(g.varName);if(f==-1){alert("Column "+g.varName+" is missing");
return}var s=D[I][f],O=w.C[C];w.g=[C];if(k=="textcontent"){U.data.wx="app.activeDocument.activeLayer.textItem.contents = "+JSON.stringify(s)+";";
n.S(U);l++}if(k=="visibility"&&O.I4()+""!=s.toLowerCase()){s=s.trim().toLowerCase();if(s!="true"&&s!="false")s=s==""?"false":"true";
U.data.wx="app.activeDocument.activeLayer.visible = "+s+";";n.S(U);l++}if(k=="fileref"){var a=s.split("/").pop(),X=null;
for(var bK in j)if(bK.split("/").pop()==a)X=j[bK];if(X==null){alert("Image "+a+" is missing.")}else{var P=jj.ZO(jj.zJ(X.buffer)).Vu(X.buffer)[0],Z=P.XL,Y=O.rect,V=0,T=0;
if(O.add.SoLd){var K=y.wR.Aa(O.add.SoLd.nonAffineTransform);Y=E.p.lV(K)}var S=Y.m/Y.n,G=Z.m/Z.n;if(S>G){T=Y.n;
V=~~(T*G)}else{V=Y.m;T=~~(V/G)}U.data.wx="app.activeDocument.activeLayer.visible = false;";n.S(U);l++;
var R=y.wR.lD([new Uint8Array(P.data),Z],new eh(V/Z.m,0,0,T/Z.n,0,0));m.rect=R.rect;m.buffer=R.buffer;
R.rect.x=Y.x+(Y.m-V>>>1);R.rect.y=Y.y+(Y.n-T>>>1);n.S(M);l++}}}return l};jj.dn={};jj.dn.La=function(w,n,W,D){if(D==null)D=[100,!1,0,0,0];
var j={sRGB:1,loop:D[3]};if(w[0][5]!=null){delete j.sRGB;j.iCCP=w[0][5]}if(w[0][2]!=null){var I=Math.round(w[0][2]*(1e4/254));
j.pHYs=[I,I,1]}var U=D[0],M=U==100?0:Math.max(2,Math.floor(U*5));if(M==5)M=4;var m=[],l=[];for(var L=0;
L<w.length;L++){m.push(w[L][0]);l.push(w[L][1])}var A=UPNG.encode(m,n,W,M,l,j,D[1]);return A};jj.dn.a30=function(w,n,W){return UPNG.encodeLL([w],n,W,3,1,8)};
jj.dn.Vu=function(w){var n=Date.now(),W=UPNG.decode(w),D=UPNG.toRGBA8(W),j=W.width,I=W.height,U=0,M=W.tabs.iCCP;
if(W.tabs.pHYs)U=Math.round(W.tabs.pHYs[0]*254/1e4);if(D.length==1)return[{XL:new iB(0,0,j,I),data:D[0],hh:U,XE:M}];
var m=[];for(var L=0;L<D.length;L++){m.push({$U:"_a_frm"+L+","+W.frames[L].delay,XL:new iB(0,0,j,I),data:D[L],hh:U,XE:M})}return m};
jj.nF={};jj.nF.La=function(w,n,W,D){var j=new Uint8Array(w[0][0]),I=n*W,U=I*3,M="P6\n"+n+" "+W+"\n255\n",m=M.length,l=E.Q(m+U,!0);
for(var L=0;L<m;L++)l[L]=M.charCodeAt(L);for(var L=0;L<I;L++){var A=L*4,g=L*3+m;l[g]=j[A];l[g+1]=j[A+1];
l[g+2]=j[A+2]}return l.buffer};jj.nF.Vu=function(w){w=new Uint8Array(w);var n=[" ".charCodeAt(0),"\n".charCodeAt(0),"\t".charCodeAt(0),"\r".charCodeAt(0)],W=0,D=String.fromCharCode(w[0])+String.fromCharCode(w[1]),j=[],I=0,U=D=="P1"||D=="P4"?2:3;
for(W=2;W<w.length;W++){var M=w[W],m=String.fromCharCode(M);if(M=="#".charCodeAt(0)){while(w[W]!="\n".charCodeAt(0))W++;
continue}var l=n.indexOf(M)!=-1;if(I==0&&!l){j.push(m);I=1;continue}if(I==1&&!l){j[j.length-1]+=m;continue}if(I==1&&l){I=0;
if(j.length==U)break;continue}}var A=parseInt(j[0]),g=parseInt(j[1]),k=A*g*4,$=D=="P1"||D=="P4"?1:255/parseInt(j[2]),C=E.Q(k);
if(D=="P1"||D=="P2"||D=="P3"){var f="",z=0,I=0,s="#".charCodeAt(0);for(var L=W;L<w.length;L++){var M=w[L],m=String.fromCharCode(M),l=n.indexOf(M)!=-1;
if(M==s){while(w[L]!="\n".charCodeAt(0))L++}else if(I==0&&!l){f=m;I=1}else if(I==1){if(l){I=0;var O=parseInt(f);
f="";if(D=="P1"){C[z]=C[z+1]=C[z+2]=(1-O)*255;C[z+3]=255;z+=4}if(D=="P2"){C[z]=C[z+1]=C[z+2]=Math.round(O*$);
C[z+3]=255;z+=4}if(D=="P3"){C[z]=Math.round(O*$);z++;if((z&3)==3){C[z]=255;z++}}}else f+=m}}}var a=A*g;
if(D=="P4")for(var X=0;X<g;X++){var P=X*8*Math.ceil(A/8);for(var Z=0;Z<A;Z++){var L=P+Z,Y=w[W+1+(L>>3)];
Y=Y>>7-(L&7)&1;var K=X*A+Z<<2;C[K]=C[K+1]=C[K+2]=(1-Y)*255;C[K+3]=255}}if(D=="P5")for(var L=0;L<a;L++){var K=4*L;
C[K]=C[K+1]=C[K+2]=Math.round(w[W+1+L]*$);C[K+3]=255}if(D=="P6")for(var L=0;L<a;L++){var K=4*L,S=W+1+3*L;
C[K]=Math.round(w[S]*$);C[K+1]=Math.round(w[S+1]*$);C[K+2]=Math.round(w[S+2]*$);C[K+3]=255}return[{XL:new iB(0,0,A,g),data:C.buffer}]};
jj.j9={};jj.j9.La=function(w,n,W,D){if(D==null)D=[0,!0];if(typeof D[0]=="boolean")D[0]=0;var j=new Uint8Array(w[0][0]),I=n&3,U=W&3;
if(I!=0||U!=0){var M=n+(I==0?0:4-I),m=W+(U==0?0:4-U),l=new Uint8Array(M*m*4);E.cJ(l,4278190080);E.Cb(j,new iB(0,0,n,W),l,new iB(0,0,M,m));
j=l;n=M;W=m}var A=UTEX.DDS.encode(j.buffer,n,W,D);if(!1){var g=UTEX.DDS.decode(A)[0],l=new Uint8Array(g.PO),k=0;
for(var L=0;L<j.length;L++){var $=j[L]-l[L];k+=$*$}console.log(k)}return A};jj.j9.Vu=function(w){var n=UTEX.DDS.decode(w)[0];
return[{XL:new iB(0,0,n.width,n.height),data:n.image}]};jj.Ng={};jj.Ng.Vu=function(w){var n=UTEX.VTF.decode(w).pop();
return[{XL:new iB(0,0,n.width,n.height),data:n.image}]};jj.Kw={};jj.Kw.CH=null;jj.Kw.au$=function(w,n){var W=jj.Kw.CH,D=w.byteLength,j=n.width,I=n.height,U=j*I,M=5e6+2*D+U*(n.progressive?Math.max(2,n.numComponents)*4+1:8),m=W.instance.exports;
jj.ne(m,M);var l=new Uint8Array(m.memory.buffer),A=m.malloc(D);l.set(new Uint8Array(w),A);var g=m.malloc(4),k=m.malloc(4),bK=m.malloc(4),$=m.stbi_load_from_memory(A,D,g,k,bK,4);
m.free(A);m.free(g,k,bK);m.free($);var C=l.slice($,$+U*4);return C};(function(){var w=jj.gF.get("wasm/jpg").buffer;
if(window.WebAssembly==null)window.alert("Your browser is too old (no WebAssembly). Please, update it.");
WebAssembly.instantiate(w).then(function(n){jj.Kw.CH=n})}());jj.Kw.La=function(w,n,W,D){if(D==null)D=[85];
var j=w[0],I=new Uint8Array(j[0]);if(E.Ym(I)){var U=new Uint8Array(I.length),M=new iB(0,0,n,W);E.cJ(U,4294967295);
E.s._U("norm",I,M,U,M,M,1);I=U}var m=new Uint8Array(jj.N7(I.buffer,n,W,"jpeg",D[0]/100));if(m.length<2e4){var l=J.TN(m,[255,226]);
if(l!=-1){var A=J.IQ(m,l+2);console.log(l,A);m=jj.Ra(m,l,A+2)}}if(j[5]!=null){var g=jj.Kw.Yb(m)[226][0]+2,k=J.IQ(m,g),$=j[5].length+16,C=$-k,f=new Uint8Array(m.length+C);
for(var L=0;L<g+k;L++)f[L]=m[L];for(var L=g+k;L<m.length;L++)f[L+C]=m[L];J.ey(f,g,$);f.set(j[5],g+16);
m=f}if(j[2]!=null){var z=jj.Kw.Yb(m)[224][0]+2;z+=9;m[z]=1;J.ey(m,z+1,j[2]);J.ey(m,z+3,j[2])}if(j[3]!=null&&D[1]==!0&&Object.keys(j[3]).length!=0){var s=0,O=0,a=0,X=fd.cG(j[3]),P=new Uint8Array(UTIF.encode([X])),Z="http://ns.adobe.com/xap/1.0/",g=20;
s=4+6+P.length;var Y=fd.acC(j[3]),K=J.zY(Y);O=4+Z.length+1+K.length;var S=fd.ant(j[3]);if(S.length!=0){var G=0,R=0;
for(var L=0;L<S.length;L++)G+=5+S[L][1].length;var V=G+(G&1),T=E.Q(14+4+4+4+V);J.Jm(T,R,"Photoshop 3.0");
R+=14;J.Jm(T,R,"8BIM");R+=4;T[R++]=4;T[R++]=4;R+=2;J.Ms(T,R,G);R+=4;for(var L=0;L<S.length;L++){var x=S[L],v=x[1];
T[R++]=28;T[R++]=2;T[R++]=x[0];J.ey(T,R,v.length);R+=2;J.Jm(T,R,v);R+=v.length}a=4+T.length}var N=s+O+a,u=new Uint8Array(m.length+N);
for(var L=0;L<20;L++)u[L]=m[L];for(var L=20;L<m.length;L++)u[L+N]=m[L];u[g]=255;u[g+1]=225;J.ey(u,g+2,s-2);
J.Jm(u,g+4,"Exif");for(var L=0;L<P.length;L++)u[g+10+L]=P[L];g+=s;u[g]=255;u[g+1]=225;J.ey(u,g+2,O-2);
J.Jm(u,g+4,Z);for(var L=0;L<K.length;L++)u[g+4+Z.length+1+L]=K[L];g+=O;if(a!=0){u[g]=255;u[g+1]=237;
J.ey(u,g+2,a-2);for(var L=0;L<T.length;L++)u[g+4+L]=T[L];g+=a}m=u}return m.buffer};jj.Kw.Yb=function(w){var n=0,W=[],D=w.length;
while(n<D){while(w[n]!=255&&n<D)n++;while(w[n]==255)n++;if(n==D)break;var j=w[n];n++;if(W[j]==null)W[j]=[];
W[j].push(n-2);if(j==216)continue;if(j==217)break;if(224<=j&&j<=239||j==218||j==219||j==192||j==193||j==194||j==196||j==221||j==254){var I=J.IQ(w,n);
n+=I;if(j==218)while(n<D&&(w[n]!=255||(w[n+1]==0||208<=w[n+1]&&w[n+1]<=215)))n++;continue}console.log("unknown marker ",j.toString(16),n);
break}if(W[217]==null){console.log("EOI marker missing");var U=w.length-2;w[U]=255;w[U+1]=217;W[217]=[U]}return W};
jj.Kw.a25=function(w){w=new Uint8Array(w);if(w[0]!=255)return w.buffer;var n=jj.Kw.Yb(w),W=jj.Kw.BY(w,n);
if(W.numComponents!=4)return w.buffer;var D=W.width,j=W.height,I=jj.Kw.MV(w,n,!0);return jj.Kw.La([[I[0].data]],D,j,[85])};
jj.Kw.BY=function(w,n){var W=(n[192]?n[192]:n[193]?n[193]:n[194])[0]+4,D={};D.progressive=n[194]!=null;
D.precision=w[W];W++;D.height=J.IQ(w,W);W+=2;D.width=J.IQ(w,W);W+=2;D.numComponents=w[W];W++;if(n[224]){var j=D.jfif={};
W=n[224][0]+2+2+5+2;j.densityUnits=w[W];W++;j.xDensity=J.IQ(w,W);W+=2;j.yDensity=J.IQ(w,W);W+=2}if(n[238]){var j=D.adobe={};
W=n[238][0]+2+2+6;j.version=w[W];W++;j.flags0=J.IQ(w,W);W+=2;j.flags1=J.IQ(w,W);W+=2;j.transform=w[W];
W++}return D};jj.Kw.a8x=function(w,n,W){var D=n,j=J.IQ(w,D);D+=2;var I=J.sv(w,D,4);if(I=="Exif"){D+=6;
var U=w.slice(D,D+j-8),M;try{M=UTIF.decode(U.buffer,{parseMN:!1,debug:!1})}catch(fV){}if(M&&M.length!=0)W.exif=M}else if(I=="http"){var m=0;
while(w[D+m]!=0)m++;var l=J.sv(w,D,m);D+=m+1;if(l=="http://ns.adobe.com/xmp/extension/"){var A=J.sv(w,D,32);
D+=32;D+=8;var g=n+j-D;while(w[D+g-1]==0)g--;if(W.xmp_extn==null)W.xmp_extn="";try{W.xmp_extn+=J.KY(w,D,g)}catch(fV){}}else if(l=="http://ns.adobe.com/xap/1.0/"){var k=J.KY(w.slice(D,D+j-m-3));
if(k[0]=="?")k="<"+k;W.xmp=k}}else console.log(I)};jj.Kw.MV=function(w,n,W){var D=jj.Kw.BY(w,n),j=D.width,I=D.height,U=j*I,M,m=-1,X=72,P,Y,K=null;
if(D.adobe)m=D.adobe.transform;if(W||j*I>15e7||m==0||m==2||D.progressive){var l=new PDFJS.JpegImage;
l.parse(w);var A=l.getData({width:j,height:I,forceRGB:!0,isSourcePDF:W}),M=E.Q(U*4);for(var L=0;L<U;
L++){var g=L<<2,k=g-L;M[g]=A[k];M[g+1]=A[k+1];M[g+2]=A[k+2];M[g+3]=255}}else{M=jj.Kw.au$(w.buffer,D)}var $=n[225];
if($)for(var L=0;L<$.length;L++)jj.Kw.a8x(w,$[L]+2,D);var C=n[226];if(C){var f=C[0],z=J.IQ(w,f+2),s=J.sv(w,f+4,11);
if(s=="ICC_PROFILE"){var O=J.q(w,f+18);D.icc=w.slice(f+18,f+18+O)}}var a=n[217][0]+2;if(a!=w.length)D.suffix=w.slice(a);
var Z=[j,I,1,0,0,0,1,0];if(D.jfif&&D.jfif.densityUnits!=0){X=Math.round([72,1,2.54][D.jfif.densityUnits]*D.jfif.xDensity)}else if(D.exif&&D.exif[0].t282!=null){var S=D.exif[0].t282[0];
X=S[0]/S[1]}if(D.exif){var G=D.exif;P=fd.X6(G[0]);var V=G[0].t274;if(V)V=V[0];if(V!=null&&V>1&&V<20)Z=E.raw.IE(V,j,I)}if(D.xmp){P=fd.auh(D.xmp,P)}if(D.icc)Y=D.icc;
var T=n[237],R=[],x=[];if(T){var v=new Uint8Array(65536),N=0,f=0;for(var L=0;L<T.length;L++){f=T[L]+2;
var u=f+J.IQ(w,f);f+=2;var H=f;while(w[f]!=0)f++;f++;var F=J.sv(w,H,f-H-1),t=u-f;if(t<0)break;while(N+t>v.length){var o=new Uint8Array(v.length*2);
o.set(v);v=o}var q=new Uint8Array(w.buffer,f,t);v.set(q,N);N+=t}f=0;w=v;while(f<N){var _=J.sv(w,f,4);
f+=4;var d=J.IQ(w,f);f+=2;var r=w[f++],p=J.sv(w,f,r);f+=r;if((r&1)==0)f++;var z=J.q(w,f);f+=4;var a=f+z+(z&1);
if(d==1028){while(f+4<a){var Q=w[f++],B=w[f++],i=w[f++],c=J.IQ(w,f);f+=2;if(Q==28&&B==2)R.push([i,J.sv(w,f,c)]);
f+=c}}else if(d==1032)K=gg.ass(w,f);else if((d&2e3)==2e3){var h2=bI.mV(w,f,z);x.push([p,h2])}else{}f=a}if(R.length!=0)P=fd.a9n(R,P)}var jX=[{XL:new iB(0,0,j,I),data:M.buffer,hh:X,Zp:P,XE:Y,NY:x.length==0?null:x,jg:K}],P=D.xmp_extn;
if(P){var bm=new DOMParser,dC=bm.parseFromString(P,"image/svg+xml"),dC=dC.children[0].children[0].children[0],fn=[dC.getAttribute("GImage:Data"),dC.getAttribute("GDepth:Data")];
for(var L=0;L<fn.length;L++)if(fn[L]){var fK=atob(fn[L]),i6=new Uint8Array(fK.length);J.Jm(i6,0,fK);
i6=i6.buffer;var dh=jj.zJ(i6),kA=jj.ZO(dh).Vu(i6);jX.push(kA[0])}}if(D.suffix){var ig=D.suffix,iJ=!1,fL=J.sv(ig,4,4),fB=J.TN(ig,[255,216,255]);
if(jj.mF(ig,[0,0,1,10,14,0,0,0])){if(iJ)console.log("Samsung");var f=0;while(f!=ig.length){var ah=J.vQ(ig,f+2);
f+=4;var eS={2272:12,2320:21,2561:13,2625:21,2721:3,2608:0}[ah];if(eS!=null){var gL=J.ly(ig,f);f+=4;
var e_=J.sv(ig,f,gL);f+=gL;var c2=J.sv(ig,f,eS);f+=eS;if(ah==2608){var jS=f,ie=J.q(ig,f+24);f+=ie+24;
var as=J.q(ig,f);f+=as;var gb=ig.slice(jS,f);jj.Kw.kb(gb)}}else if(ah==18502){while(J.sv(ig,f,4)!="SEFT")f+=4;
f+=4}else{break;console.log(J.eS(ig,f,128));console.log(ig.slice(f));throw ah.toString(16)}}}else if(fL=="ftyp"){if(iJ)console.log("MP4 Video");
jj.Kw.kb(ig)}else if(J.sv(ig,0,4)=="fixe"){if(iJ)console.log("fixe");alert("Unknown data - "+ig.length+" B - at the end of the file",3e3);
var f=4,z=J.ly(ig,f);f+=4;var gx=J.ly(ig,f);f+=4;var eo=J.ly(ig,f);f+=4;console.log(z,gx,eo,ig.slice(f,f+84));
f+=84;var di=J.sv(ig,f,32);f+=32;f+=8;var di=J.sv(ig,f,32);f+=32}else if(J.sv(ig,8,13)=="FocusShot_Map"){if(iJ)console.log("FocusShot_Map");
var d0=J.q(ig,0),c=J.ly(ig,4),i6=E.Q(U*4),e6=E.Q(U*4);for(var dt=0;dt<I;dt++)for(var gJ=0;gJ<j;gJ++){var L=dt*j+gJ,g=L<<2,iW=8+13+((dt>>>1)*j+gJ>>>1),g5=ig[iW],jW=ig[iW+(U>>>2)];
i6[g]=i6[g+1]=i6[g+2]=g5;i6[g+3]=255;e6[g]=e6[g+1]=e6[g+2]=jW;e6[g+3]=255}jX.push({XL:new iB(0,0,j,I),data:i6.buffer},{XL:new iB(0,0,j,I),data:e6.buffer})}else if(fL=="edof"){if(iJ)console.log("edof");
var V=ig[8+7];console.log(V.toString(16));var f=8+16,eP=J.vQ(ig,f),b_=J.vQ(ig,f+2),U=eP*b_;f+=4;f+=32+16;
var fZ=E.Q(U*4);for(var L=0;L<U;L++){var g=L<<2;fZ[g]=fZ[g+1]=fZ[g+2]=ig[f+L];fZ[g+3]=255}if(V==16){}else if(V==19){var im=fZ.slice(0);
E.K.nJ(fZ,im,eP,b_);var j3=eP;eP=b_;b_=j3;E.K.oX(im,fZ,eP,b_)}else throw"Unknown orientation of a depth map";
jX.push({XL:new iB(0,0,eP,b_),data:fZ.buffer})}else if(fB!=-1&&!(ig[0]==255&&ig[1]==129)){if(iJ)console.log("another JPG at",fB);
if(fB>100&&J.sv(ig,0,64).indexOf("DualShot")!=-1){var dr=J.ly,c0=J.sv,fM=J.vQ,f=0;function cB(){var d1=dr(ig,f);
if(dr(ig,f+4)!=0)throw"e";f+=8;return d1}var iI=J.q(ig,f);f+=4;try{if(iI==45066){f=1226;var j=cB(),I=cB();
f=3445}else if(iI==45322){var jD=dr(ig,f);f+=4;var di=c0(ig,f,jD);f+=jD;if(di!="DualShot_DepthMap_1")throw di;
j=1008;I=756}else throw iI;var j8=E.Q(j*I*4);j8.fill(255);E.Mj(ig.slice(f,f+j*I),j8);jX.push({XL:new iB(0,0,j,I),data:j8.buffer})}catch(fV){console.log("error reading a depth map")}}try{if(fB!=0)ig=ig.slice(fB);
var kA=jj.ZO("jpg").Vu(ig.buffer);for(var L=0;L<kA.length;L++)jX.push(kA[L])}catch(fV){}}else if(J.sv(ig,0,4)=="PMPD"){if(iJ)console.log("Xiaomi stuff");
var f=4,jG=J.ly(ig,12),i1=J.ly(ig,16),eP=J.ly(ig,1060),b_=J.ly(ig,1064),bH=eP>b_,a_=jX[0].XL.m>jX[0].XL.n,aR=ig.slice(ig.length-eP*b_-4),iY=E.Q(eP*b_);
for(var dt=0;dt<b_;dt++)for(var gJ=0;gJ<eP;gJ++)iY[dt*eP+gJ]=aR[(b_-dt-1)*eP+gJ];var j8=E.Q(eP*b_*4);
j8.fill(255);E.Mj(iY,j8);if(bH!=a_){var im=j8.slice(0);E.K.nJ(j8,im,eP,b_);var j3=eP;eP=b_;b_=j3;E.K.oX(im,j8,eP,b_)}jX.push({XL:new iB(0,0,eP,b_),data:j8.buffer})}else console.log(J.sv(ig,0,4),ig)}if(jX.length>1){var gy=jX[0].XL,fs=!1,dQ=!0;
jX[0].$U="Main";var gr=[!1];for(var L=1;L<jX.length;L++){gr[L]=jj.Kw.agM(new Uint8Array(jX[L].data));
if(gr[L])fs=!0;if(!jX[L].XL.s9(jX[0].XL))dQ=!1}if(!fs&&!dQ)jX=jX.slice(0,1);else for(var L=1;L<jX.length;
L++){jX[L].$U=gr[L]?"Depth Map":null;var ep=jX[L].XL;if(!ep.s9(gy)){var b2=gy.m/ep.m,eX=gy.n/ep.n,iz=new eh;
iz.scale(b2,eX);var en=y.wR.z3([new Uint8Array(jX[L].data),ep],1,E.K.yT(iz));jX[L].XL=en.rect;jX[L].data=en.buffer}}}if(jj.Kw.Fk==1)if(Z[2]!=1||Z[6]!=1)for(var L=0;
L<jX.length;L++){var ko=jX[L],fh=new Uint8Array(ko.data),j=ko.XL.m,I=ko.XL.n,eP=Z[0],b_=Z[1],M=E.Q(eP*b_*4);
E.K.pQ(fh,j,I,M,Z);ko.XL=new iB(0,0,eP,b_);ko.data=M.buffer}return jX};jj.Kw.kb=function(w){if(window.confirm("Photopea found a "+fp.cN(w.length)+" MP4 video inside your image. Would you like to save it?",4e3)){e8.save(w.slice(0).buffer,"video.mp4")}};
jj.Kw.agM=function(w){var n=!0;for(var L=0;L<w.length;L+=4){n=n&&w[L]==w[L+1]&&w[L+1]==w[L+2]}return n};
jj.Kw.Fk=0;jj.Kw.Vu=function(w,n,W){w=new Uint8Array(w);if(w[0]==255){var D=jj.Kw.Yb(w);if(D[195]==null){jj.Kw.Fk++;
var j=jj.Kw.MV(w,D,!1);jj.Kw.Fk--;return j}var I=J.IQ(w,D[195][0]+5),U=J.IQ(w,D[195][0]+7),M=UTIF.LosslessJpegDecode(w),m=U*I,l=E.Q(m*4);
for(var L=0;L<m;L++){var A=L<<2,g=A-L;l[A]=M[g];l[A+1]=M[g+1];l[A+2]=M[g+2];l[A+3]=255}return[{XL:new iB(0,0,U,I),data:l.buffer}]}else if(w[0]==0&&w[4]==48&&w[6]==1){var k=w,$=new PDFJS.Jbig2Image,C=[];
if(n)C.push({data:n,start:0,end:n.length});C.push({data:k,start:0,end:k.length});var M=$.parseChunks(C);
if(!W)for(var L=0;L<M.length;L++)M[L]=~M[L];var U=J.q(w,11),I=J.q(w,15),f=Math.ceil(U/8),z=E.Q(U*I*4);
for(var s=0;s<I;s++){var O=s*f;for(var a=0;a<U;a++){var A=(s*U+a)*4,X=M[O+(a>>>3)]>>>7-(a&7)&1,P=X*255;
z[A]=P;z[A+1]=P;z[A+2]=P;z[A+3]=255}}return[{XL:new iB(0,0,U,I),data:z.buffer}]}else{var $=new PDFJS.JpxImage;
$.parse(w);var U=$.width,I=$.height,Z=$.tiles,Y=$.componentsCount,K=new Uint8Array(U*I*4),S=new iB(0,0,U,I);
for(var $=0;$<Z.length;$++){var G=Z[$],V=G.width,T=G.height,R=V*T,x=G.items,v=new iB(G.left,G.top,V,T),N=new Uint8Array(R*4);
if(Y==1)for(var L=0;L<R;L++){var u=x[L],A=L*4;N[A]=u;N[A+1]=u;N[A+2]=u;N[A+3]=255}else if(Y==3)for(var L=0;
L<R;L++){var g=L*3,A=L*4;N[A]=x[g];N[A+1]=x[g+1];N[A+2]=x[g+2];N[A+3]=255}else console.log("Unknown number of components: "+Y);
E.Cb(N,v,K,S)}return[{XL:S,data:K.buffer}]}};jj.ZJ={};jj.ZJ.La=function(w,n,W,D){if(D==null)D=[70,0,0,0];
var j=D[0]/100,k=0;if(w.length==1){var I=new Uint8Array(jj.N7(w[0][0],n,W,"webp",j));if(I.length<2e4){var U=ce.ew(I.buffer),M=U.sub;
for(var L=0;L<M.length;L++)if(M[L].Z4=="ICCP"){var m=M[L];I=jj.Ra(I,m.R-8,m.size+8);J.Fr(I,4,U.size-(m.size+8));
break}}return I.buffer}var l=J.YY,A=J.zL,g=new cs;l(g,k,"RIFF WEBPVP8X");k+=16;A(g,k,10);k+=4;A(g,k,18);
k+=4;A(g,k,n-1);k+=3;A(g,k,W-1);k+=3;l(g,k,"ANIM");k+=4;A(g,k,6);k+=4;g.lN(k,4);g.data[k+3]=255;J.D0(g,k+4,D[2]);
k+=6;var $=[];for(var L=0;L<w.length;L++){$.push(w[L][0])}var C=UPNG.encode.compress($,n,W,j==1?0:Math.max(2,Math.floor(j*500)),[!1,!0,!0,0,!0]).frames;
function f(U,V,T,R){var Z=U.R-8,Y=U.size+8;T.lN(R,Y);for(var L=0;L<Y;L++)T.data[R+L]=V[Z+L];return R+Y}for(var L=0;
L<w.length;L++){l(g,k,"ANMF");k+=4;var z=k,Z=0,Y=0;k+=4;var s=C[L],O=s.rect,a=[O.x>>>1,O.y>>>1,O.width-1,O.height-1,w[L][1]];
for(var X=0;X<5;X++)A(g,k+3*X,a[X]);k+=15;g.lN(k,1);g.data[k]=1-s.blend<<1|s.dispose;k++;var P=new Uint8Array(jj.N7(s.img.buffer,O.width,O.height,"webp",1)),M=ce.ew(P.buffer).sub,K={};
for(var S=0;S<M.length;S++)K[M[S].Z4]=M[S];if(K.VP8L)k=f(K.VP8L,P,g,k);else throw"e";var G=k-z-4;A(g,z,G);
if((G&1)==1){g.lN(k,1);k++}}A(g,4,k-8);return g.data.slice(0,k).buffer};(function(){var w=jj.gF.get("wasm/webp").buffer;
WebAssembly.instantiate(w).then(function(n){var W=n.instance.exports;jj.ZJ.exp=W})}());jj.ZJ.Vu=function(w){var n=new Uint8Array(w),W=jj.ZJ.a5z,D=null,j=ce.ew(w).sub,I={};
for(var L=0;L<j.length;L++)I[j[L].Z4]=j[L];var U=I.ANIM,M=I.VP8L,m=I["VP8 "],l=I.VP8X;if(U==null){var A,g;
if(m){A=J.vQ(n,m.R+6);g=J.vQ(n,m.R+8)}else if(M){var k=J.ly(n,M.R+1);A=(k&(1<<14)-1)+1;g=(k>>>14&(1<<14)-1)+1}else throw"e";
var $=[W(D,w,{R:0,size:n.length},A,g)];return $}var C=l.R,A=1+(J.ly(n,C+4)&16777215),g=1+(J.ly(n,C+7)&16777215),f=[],z=new iB(0,0,A,g),s=E.Q(A*g*4);
for(var L=0;L<j.length;L++){var O=j[L];if(O.Z4!="ANMF")continue;var a=[];for(var X=0;X<5;X++)a.push(J.ly(n,O.R+X*3)&16777215);
var P=new iB(a[0]*2,a[1]*2,a[2]+1,a[3]+1),Z=a[4],Y=W(D,w,{R:O.R+16,size:O.size-16},A,g),K=new Uint8Array(Y.data),S=n[O.R+15];
if(S>>>1==0)E.s._U("norm",K,P,s,z,P,1);else E.Cb(K,P,s,z);f.push({$U:"_a_"+f.length+","+Z,XL:z.clone(),data:s.buffer.slice(0)});
if((S&1)==1){E.cJ(K,0);E.Cb(K,P,s,z)}}return f};jj.ZJ.a5z=function(w,n,W,D,j){var I=jj.ZJ.exp,U=I.memory,M=5e6+2*W.size+D*j*10;
jj.ne(I,M);var m=new Uint8Array(U.buffer),l=I.malloc(W.size);m.set(new Uint8Array(n,W.R,W.size),l);var A=I.malloc(8),g=I.WebPDecodeARGB(l,W.size,A,A+4),k=J.ly(m,A),$=J.ly(m,A+4),C=k*$*4,f=E.Q(C);
for(var L=0;L<C;L+=4){f[L]=m[g+L+1];f[L+1]=m[g+L+2];f[L+2]=m[g+L+3];f[L+3]=m[g+L]}I.WebPFree(g);I.free(A);
I.free(l);return{XL:new iB(0,0,k,$),data:f.buffer}};jj.aaB=function(){function w(M,m,l,A){var g=new Uint8Array(M[0][0]),k=new Uint32Array(g.buffer),$=[],C={},z=24,s=0,Z=0;
for(var L=0;L<k.length;L++){var f=k[L]&16777215;if(C[f]==null){C[f]=$.length;$.push(f);if($.length>256){$=null;
break}}}if($){z=1;while(1<<z<$.length)z*=2;if(z==2)z=4}var O={gA:m,ag:l,Sl:1,o1:z,CK:0,abU:s},a=4*Math.floor((O.o1*O.gA+31)/32);
O.size=a*O.ag+2;var X=new cs,P=$?(1<<z)*4:0;J.YY(X,Z,"BM");Z+=2;J.zL(X,Z,a*l+16+40+P);Z+=4;J.zL(X,Z,0);
Z+=4;J.zL(X,Z,54+P);Z+=4;X.lN(Z,40);J.zL(X,Z,40);Z+=4;U(X.data,Z,O,a);Z+=36;if($){X.lN(Z,P);var Y=X.data;
for(var L=0;L<$.length;L++){var K=Z+L*4,S=$[L]>>>16,G=$[L]>>>8&255,V=$[L]&255;Y[K]=S;Y[K+1]=G;Y[K+2]=V}Z+=P}X.lN(Z,a*l);
if(z==24)for(var T=0;T<l;T++){var R=Z+(l-1-T)*a;for(var x=0;x<m;x++){var v=(T*m+x)*4;X.data[R+x*3+2]=g[v];
X.data[R+x*3+1]=g[v+1];X.data[R+x*3+0]=g[v+2]}}else if(z==8)for(var T=0;T<l;T++){var R=Z+(l-1-T)*a;for(var x=0;
x<m;x++){var v=T*m+x,N=C[k[v]&16777215];X.data[R+x]|=N}}else if(z==4)for(var T=0;T<l;T++){var R=Z+(l-1-T)*a;
for(var x=0;x<m;x++){var v=T*m+x,N=C[k[v]&16777215];X.data[R+(x>>>1)]|=N<<4-(x&1)*4}}else if(z==1)for(var T=0;
T<l;T++){var R=Z+(l-1-T)*a;for(var x=0;x<m;x++){var v=T*m+x,N=C[k[v]&16777215];X.data[R+(x>>>3)]|=N<<7-(x&7)}}Z+=a*l+2;
return X.data.slice(0,Z).buffer}function n(M){M=new Uint8Array(M);if(J.ly(M,0)==40)return[W(M.buffer,0)];
var m=0,l=J.sv(M,m,2);m+=2;if(l!="BM"){alert("Unsupported BMP format: "+l);return}var A=J.ly(M,m);m+=4;
m+=4;var g=J.ly(M,m);m+=4;return[W(M.buffer,m,g)]}function W(M,m,l){M=new Uint8Array(M);var A=J.ly(M,m),g=I(M,m+4);
if(g.Sl!=1)alert("unsupported number of color planes: "+g.Sl);if(g.CK!=0&&g.CK!=1&&g.CK!=2&&g.CK!=3){alert("Unsupported BMP compression: "+g.CK);
return}m+=A;var k=m,$=M;if(l==null)l=m;if(g.CK==1||g.CK==2){var C=j(M,l,g);g.o1=8;M=C;l=0}var f=4*Math.floor((g.o1*g.gA+31)/32),z=g.gA,s=Math.abs(g.ag),O=new Uint8Array(z*s*4);
O.fill(255);if(g.o1==32)for(var a=0;a<s;a++){var X=l+(s-1-a)*f;for(var P=0;P<z;P++){var Z=(a*z+P)*4;
O[Z]=M[X+P*4+2];O[Z+1]=M[X+P*4+1];O[Z+2]=M[X+P*4+0];O[Z+3]=M[X+P*4+3]}}else if(g.o1==24)for(var a=0;
a<s;a++){var X=l+(s-1-a)*f;for(var P=0;P<z;P++){var Z=(a*z+P)*4;O[Z]=M[X+P*3+2];O[Z+1]=M[X+P*3+1];O[Z+2]=M[X+P*3+0]}}else if(g.o1==16)for(var a=0;
a<s;a++){var X=l+(s-1-a)*f;for(var P=0;P<z;P++){var Z=(a*z+P)*4,Y=M[X+P*2+1]<<8|M[X+P*2];O[Z]=(Y>>>11)*(255/31);
O[Z+1]=(Y>>>5&63)*(255/63);O[Z+2]=(Y&31)*(255/31)}}else if(g.o1==8)for(var a=0;a<s;a++){var X=l+(s-1-a)*f;
for(var P=0;P<z;P++){var Z=(a*z+P)*4,K=M[X+P];O[Z]=$[k+4*K+2];O[Z+1]=$[k+4*K+1];O[Z+2]=$[k+4*K+0]}}else if(g.o1==4)for(var a=0;
a<s;a++){var X=l+(s-1-a)*f;for(var P=0;P<z;P++){var Z=(a*z+P)*4,K=M[X+(P>>1)];K=K>>4-4*(P&1);K=K&15;
O[Z]=$[k+4*K+2];O[Z+1]=$[k+4*K+1];O[Z+2]=$[k+4*K+0]}}else if(g.o1==1)for(var a=0;a<s;a++){var X=l+(s-1-a)*f;
for(var P=0;P<z;P++){var Z=(a*z+P)*4,S=M[X+(P>>3)];S=S>>7-(P&7);S=S&1;O[Z]=$[k+4*S+2];O[Z+1]=$[k+4*S+1];
O[Z+2]=$[k+4*S+0]}}else throw"Unknown bit depth "+g.o1;if(g.ag<0){var G=new Uint32Array(O.buffer),V=s>>>1;
for(var a=0;a<V;a++){var T=a*z,R=(s-a-1)*z;for(var P=0;P<z;P++){var x=G[T+P];G[T+P]=G[R+P];G[R+P]=x}}}return{XL:new iB(0,0,z,s),data:O.buffer}}function D(M,L){return M>>>4-((L&1)<<2)&15}function j(M,m,l){var A=l.gA,g=Math.abs(l.ag),k=new Uint8Array(A*g),$=0,C=0,L=0;
while(C<g){var f=M[m++],z=M[m++],s=C*A+$;if(f>0){if(l.o1==4)for(L=0;L<f;L++){k[s+L]=D(z,L)}else for(L=0;
L<f;L++){k[s+L]=z}$+=f}else if(f==0&&z==0){C++;$=0}else if(f==0&&z==1){break}else if(f==0&&z==2){$+=M[m++];
C+=M[m++]}else{var O=z;if(l.o1==4){for(L=0;L<z;L++){k[s+L]=D(M[m+(L>>>1)],L)}O=Math.ceil(z/2)}else{for(L=0;
L<z;L++){k[s+L]=M[m+L]}}if((O&1)!=0)O++;m+=O;$+=z}}return k}function I(M,m){var l=J.ck,A=J.ly,g=J.vQ,k={};
k.gA=l(M,m);m+=4;k.ag=l(M,m);m+=4;k.Sl=g(M,m);m+=2;k.o1=g(M,m);m+=2;k.CK=A(M,m);m+=4;k.size=A(M,m);m+=4;
var $=l(M,m);m+=4;var C=l(M,m);m+=4;k.abU=A(M,m);m+=4;m+=4;return k}function U(M,m,l,A){J.Fr(M,m,l.gA);
m+=4;J.Fr(M,m,l.ag);m+=4;J.vP(M,m,l.Sl);m+=2;J.vP(M,m,l.o1);m+=2;J.Fr(M,m,l.CK);m+=4;J.Fr(M,m,l.size);
m+=4;J.Fr(M,m,2834);m+=4;J.Fr(M,m,2834);m+=4;J.Fr(M,m,l.abU);m+=4;m+=4}return{Vu:n,La:w,a9v:W}}();jj.Bh={};
jj.Bh.La=function(w,n,W,D){if(D==null)D=[100,!1,0,0,0,0];var j=[],I=[],U=n*W*4,f=null;for(var M=0;M<w.length;
M++){var m=new Uint8Array(w[M][0].slice(0));for(var L=0;L<U;L+=4){var l=m[L+3]=m[L+3]>127?255:0;if(l==0)m[L]=m[L+1]=m[L+2]=0}j.push(m.buffer);
I.push(w[M][1])}var A=Math.round(2+254*D[0]/100),g=UPNG.encode.compress(j,n,W,A,[!0,!1,!1,8,!1,D[1]]),k=g.plte,$=new Uint8Array(4),C=new Uint32Array($.buffer);
for(var L=0;L<k.length;L++){C[0]=k[L];var z=$[0];$[0]=$[2];$[2]=z;k[L]=C[0];if(C[0]==0)f=L}while(k.length<256)k.push(0);
var s=new Uint8Array(2e4+Math.round(1.5*n*W*w.length)),O=D[3],a={palette:k};if(O!=1)a.loop=O==0?0:O-1;
var X=new GifWriter(s,n,W,a);for(var L=0;L<w.length;L++){var P=g.frames[L],Z=P.rect,Y=P.blend,K=P.dispose,S=Math.round(I[L]/10);
if(S<2)S=2;X.addFrame(Z.x,Z.y,Z.width,Z.height,P.img,{transparent:f,disposal:K+1,delay:S})}return s.slice(0,X.end()).buffer};
jj.Bh.Vu=function(w){var n=Date.now(),W=[],D=UGIF.decode(w),j=UGIF.toRGBA8(D),I=new iB(0,0,D.width,D.height);
for(var L=0;L<j.length;L++){var U=D.frames[L];W.push({XL:I.clone(),$U:"_a_frm"+L+","+U.delay*10,data:j[L]})}return W};
jj.dL={};jj.dL.La=function(w,n,W,D){console.log(w);if(n>256||W>256){alert("Maximum ICO size is 256x256 px. Will be cropped.",4e3);
var j=Math.min(n,256),I=Math.min(W,256),U=new iB(0,0,j,I),M=E.Q(U.O()*4),m=new iB(0,0,n,W),l=new Uint8Array(w[0][0]);
E.Cb(l,m,M,U);w[0][0]=M.buffer;n=j;W=I}var A=new cs,g=0,k=D&&D[0]==!0;J.D0(A,g,0);g+=2;J.D0(A,g,k?2:1);
g+=2;J.D0(A,g,1);g+=2;var $=new Uint8Array(jj.ZO("png").La(w,n,W));A.lN(g,16);A.data[g]=n==256?0:n;g++;
A.data[g]=W==256?0:W;g++;g+=2;J.D0(A,g,k?Math.round(n/2):1);g+=2;J.D0(A,g,k?Math.round(W/2):32);g+=2;
J.zL(A,g,$.length);g+=4;J.zL(A,g,6+16);g+=4;A.lN(g,$.length);for(var L=0;L<$.length;L++)A.data[g+L]=$[L];
g+=$.length;var C=new Uint8Array(g);for(var L=0;L<g;L++)C[L]=A.data[L];return C.buffer};jj.dL.Vu=function(w){w=new Uint8Array(w);
var n=4,W=J.vQ(w,n);n+=2;var D=[];for(var L=0;L<W;L++){var j=jj.dL.a7p(w,n+L*16),I=w.buffer.slice(j.offset,j.offset+j.size),U=jj.zJ(I);
U=U?U:"bmp";if(U=="png"){var M=jj.ZO(U),m=M.Vu(I);j.rY=m[0]}else{var l=jj.ZO("BMP").a9v(I,0),I=E.Q(j.gA*j.ag*4);
E.Cb(new Uint8Array(l.data),new iB(0,0,l.XL.m,l.XL.n),I,new iB(0,j.ag,j.gA,j.ag));l.data=I.buffer;l.XL.n=j.ag;
j.rY=l}D.push(j)}D.sort(function(A,g){if(A.gA!=g.gA)return A.gA-g.gA;return A.av1-g.av1});return[D.pop().rY]};
jj.dL.a7p=function(w,n){var W={};W.gA=w[n];n++;if(W.gA==0)W.gA=256;W.ag=w[n];n++;if(W.ag==0)W.ag=256;
W.a7b=w[n];n++;n++;W.a23=J.vQ(w,n);n+=2;W.av1=J.vQ(w,n);n+=2;W.size=J.ly(w,n);n+=4;W.offset=J.ly(w,n);
n+=4;return W};jj.T1={};jj.T1.Vu=function(w){var n=Date.now(),D,Z=!0;if(E.raw.pd(w.byteLength))return[E.raw.a8v(w)];
var W=UTIF.decode(w);if(W[0].t33421)D=W[0];else if(W[0].subIFD&&W[0].t271&&W[0].t271[0]=="Hasselblad"){D=W[0].subIFD[0];
D.t33421=[2,2]}else if(W[0].subIFD&&W[0].subIFD[0].t33421){D=W[0].subIFD[0];if(D.t50706==null){if(D.t258[0]==8)D.t258[0]=12}}else if(W[0].subIFD&&W[0].subIFD[0]&&W[0].subIFD[0].t262&&W[0].subIFD[0].t262[0]==34892)D=W[0].subIFD[0];
else if(W[0].t50706)D=W[0];else if(W[0].subIFD&&W[0].subIFD[1]&&W[0].subIFD[1].t33421)D=W[0].subIFD[1];
else if(W[0].subIFD&&W[0].subIFD[2]&&W[0].subIFD[2].t33421)D=W[0].subIFD[2];else if(W[3]&&W[3].t50648){var j=W[0].exifIFD,I=j.makerNote;
D=W[3];var U=I.t224[1],M=I.t224[2];D.t256=[U];D.t257=[M];D.t258=[16];D.t259=[7];D.t262=[32803];D.t277=[1];
D.t33421=[2,2];var m=D.t50656[0],l=E.raw.JL[m];if(l==null)throw"e";D.t33422=l}else if(W[0].t1&&W[0].t1.length==4){var A=W[0],g={2:256,3:257,8:277,11:259,271:271,272:272,279:279,280:273,278:278};
D={};for(var k in g)if(A["t"+k])D["t"+g[k]]=A["t"+k];D.t2=A.t2;D.t3=A.t3;D.t10=A.t10;D.t45=A.t45;D.t258=[16];
D.t33421=[2,2];var $=A.t9[0];D.t33422=[[0,1,1,2],[1,0,2,1],[1,2,0,1],[2,1,1,0]][$-1];var C=A.t4[0],f=A.t5[0],z=A.t6[0],s=A.t7[0];
D.t50829=[C,f,z,s];var O=A.t36[0],a=A.t37[0],X=A.t38[0];D.t50728=[a/O,a/a,a/X]}if(D){UTIF.decodeImage(w,D,W);
for(var P in W[0])if((P[0]=="t"||P[0]=="e"||P[0]=="d")&&D[P]==null)D[P]=W[0][P];D.jy=W[0].t274?W[0].t274[0]:1;
return[D]}var Y=1/256;for(var L=0;L<W.length;L++)if(W[L].t258&&W[L].t258[0]==16&&W[L].t277&&W[L].t277[0]==1){}else Z=!1;
if(Z){var K=0,S=0,G=0;for(var L=0;L<W.length;L++){UTIF.decodeImage(w,W[L],W);var V=W[L].data;for(var T=0;
T<V.length;T+=2){var R=V[T+1]<<8|V[T];if(R>K)K=R;S+=R;G++}}Y=1/256*65535/(.5*K+.5*(2*S/G))}var x=[];
for(var L=0;L<W.length;L++){var v=W[L],N=72;UTIF.decodeImage(w,v,W);var u=v.t282,H=v.t296;if(u!=null&&H!=null){N=u[0][0]/u[0][1];
if(H[0]==3)N=Math.round(N/2.54)}if(v.width==null)continue;var F=UTIF.toRGBA8(v,Y).buffer,t=fd.X6(v);
console.log(v);x.push({XL:new iB(0,0,v.width,v.height),data:F,hh:N,Zp:t,XE:v.t34675?v.t34675.slice(0):null})}return x};
jj.T1.La=function(w,n,W,D){if(D==null)D=[!1];var j={},I=w[0];if(I[3]!=null&&D[0])j=fd.cG(I[3]);if(I[2]!=null){j.t282=j.t283=[[Math.round(I[2]),1]];
j.t296=[2]}return UTIF.encodeImage(I[0],n,W,j)};jj.JD={};jj.JD.Xq=!0;jj.JD.Vu=function(w,n){gg.ew(w,n)};
jj.JD.acP=function(w,n,W,D){if(D==null)D=[!1,!1,!1,!1,!1];if(!D[0])w.Vc();var j=new cs,I=gg.Pj(w,j,D);
return[j.data.buffer,I]};jj.JD.La=function(w,n,W,D){var j=jj.JD.acP(w,n,W,D),I=j[0],U=j[1];return I.byteLength==U?I:I.slice(0,U)};
jj.FA={};jj.FA.Xq=!0;jj.FA.Vu=function(w,n){var W=pako.inflate(new Uint8Array(w)),D=J.IQ(W,0),j=J.IQ(W,2),I=4;
n.m=J.q(W,I);I+=4;n.n=J.q(W,I);I+=4;n.buffer=E.Q(n.m*n.n*4);var U=J.IQ(W,I);I+=2;I+=4;for(var M=0;M<U;
M++){var m=n.QI(),C=0,N=1,u=2,H=3,F=0;n.C.push(m);var l=J.q(W,I);I+=4;var A=I,g=J.IQ(W,A);A+=2;var k=J.KY(W,A,g);
A+=g;m.nz(k);var $=W[A];A++;if($!=0&&$!=1)throw $;m.rect.x=J.W6(W,A);A+=4;m.rect.y=J.W6(W,A);A+=4;m.rect.m=J.q(W,A);
A+=4;m.rect.n=J.q(W,A);A+=4;if(D>3){C=J.W6(W,A);A+=4}m.opacity=Math.round(255*W[A]/100);A++;var f=W[A];
A++;m.gb(f!=0);m.Bx="norm,lddg,norm,dark,diff,norm,hLit,norm,norm,lite,mul ,over,scrn,fsub".split(",")[W[A]];
A++;var z=W[A];A++;if(z)m.add.lspf=1<<31;if(D>3){var s=J.IQ(W,A);A+=2;if(s!=0){var O=JSON.parse(J.KY(W,A,s));
A+=s;var a=O.text,X=O.textSettings,P=X.font,Z=X.size,Y=X.padding,K=parseInt(X.color.slice(1),16);m.add.lnsr="rend";
m.add.TySh=hd._3(0,0);m.add.TySh.IA=new iB(0,0,100,100);var S=m.add.TySh.D=new eh,G=m.rect.m/2,V=m.rect.n/2;
S.translate(-G,-V);S.rotate(-C*Math.PI/180);S.translate(G,V);S.translate(m.rect.x+Y,m.rect.y+Y);var T=m.add.TySh._o;
hd.VL(T,1);hd.sV(T,[0,0,m.rect.m-Y*2,m.rect.n]);hd.KO(T,0,a);var R=hd.tG(T,0,1);R.lJ.FontSize=Z;R.lJ.FillColor={Type:1,Values:[1,(K>>>16&255)/255,(K>>>8&255)/255,(K>>>0&255)/255]};
if(X.bold)P+="-Bold";hd.hI(R,P);R.ci.Justification=["left","right","center"].indexOf(X.align);hd.g0(T,0,a.length,R)}}var x=J.q(W,A);
A+=4;if(x!=m.rect.O()*4){for(var L=m.rect.m;L>m.rect.m/2;L--){var v=x/(L*4);if(v==Math.round(v)){m.rect.m=L;
m.rect.n=v;break}}}m.buffer=E.Q(m.rect.O()*4);if(D>3){N=0;u=1;H=2;F=3}for(var L=0;L<x;L+=4){m.buffer[L]=W[A+L+N];
m.buffer[L+1]=W[A+L+u];m.buffer[L+2]=W[A+L+H];m.buffer[L+3]=W[A+L+F]}A+=x;var t=J.q(W,A);A+=4;if(t==0&&D>3){I+=l;
continue}var o=W[A];A++;var q=J.IQ(W,A);A+=2;if(t!=0){m.z=new h.ac;m.z.rect=m.rect.clone();m.z.channel=E.Q(m.rect.O());
for(var L=0;L<t;L+=4)m.z.channel[L>>>2]=W[A+L+1];A+=t}if(o!=0){var _=JSON.parse(at.default);m.add.lmfx=_;
for(var L=0;L<at.order.length;L++)_[at.Pa[L]]={t:"VlLs",v:[]};var d={"102":9,"101":2,"103":0,"104":3,"105":8};
for(var L=0;L<o;L++){var r=J.IQ(W,A),p=A+r+4,Q=W.slice(A,p),B=W[A+2];A+=3;var i=d[B+""],c=JSON.parse(at.UR[i]);
_[at.Pa[i]].v.push({t:"Objc",v:c});if(i!=0){c.Md.v.BlnM=dD.Eu("norm");c.Opct.v.val=W[A];A++;if(i==9||i==2){c.Dstn.v.val=W[A+1];
A+=2}else A+=2;c.blur.v.val=Math.round(W[A]*1.2);A++;if(i==9||i==2){c.uglg.v=!1;c.lagl.v.val=180-J.IQ(W,A);
A+=2}c.Clr.v=E.M.lW({o:W[A+1],B:W[A+2],k:W[A+3]})}else{c.hglM.v.BlnM=c.sdwM.v.BlnM=dD.Eu("norm");A+=2;
var h2=W[A++],jX=W[A++];c.blur.v.val=Math.round(Math.sqrt(jX*h2)*1.3);c.srgR.v.val=Math.round(100*h2/jX);
c.uglg.v=!1;c.lagl.v.val=180-J.IQ(W,A);A+=2;c.hglO.v.val=W[A++];c.hglC.v=E.M.lW({o:W[A+1],B:W[A+2],k:W[A+3]});
A+=4;c.sdwO.v.val=W[A++];c.sdwC.v=E.M.lW({o:W[A+1],B:W[A+2],k:W[A+3]});A+=4}A=p}}if(A-I<l){var bm=J.q(W,A),fK=0;
A+=4;A++;var g=J.IQ(W,A);A+=2;var a=J.KY(W,A,g);A+=g;a=a.replace(/\r/g,"\n");var g=J.IQ(W,A);A+=2;var P=J.KY(W,A,g);
A+=g;var Z=J.IQ(W,A);A+=2;var dC=m.rect.x,fn=m.rect.m;if(bm&4)fK=1;if(bm&2)fK=2;var i6=Math.round(Z*.4);
if(fK==0||fK==2)fn+=i6;if(fK==1||fK==2){fn+=i6;dC-=i6}m.add.lnsr="rend";m.add.TySh=hd._3(0,0);m.add.TySh.IA=new iB(0,0,100,100);
m.add.TySh.D=new eh(1,0,0,1,dC,m.rect.y+Z*.25);var T=m.add.TySh._o;hd.VL(T,1);hd.sV(T,[0,0,fn,m.rect.n]);
hd.KO(T,0,a);var R=hd.tG(T,0,1);R.lJ.FontSize=Z;R.lJ.FillColor={Type:1,Values:[1,W[A+1]/255,W[A+2]/255,W[A+3]/255]};
A+=4;if(W[A+5])P+="-Bold";if(W[A+6])P+="-Italic";hd.hI(R,P);R.ci.Justification=fK;A+=8;hd.g0(T,0,a.length,R)}I+=l}};
jj.Ow={};jj.Ow.Xq=!0;jj.Ow.Vu=function(w,n){i7.ew(w,n)};var i7=function(){function w(g,k){var $=Date.now(),C=UZIP.parse(g);
console.log(C);console.log(Date.now()-$);$=Date.now();var f=C["maindoc.xml"],z=new DOMParser,s=z.parseFromString(J.KY(f),"image/svg+xml").children[0].children[0],O=s.getAttribute("name"),a=k.m=l(s,"width"),X=k.n=l(s,"height");
k.hh=Math.round(l(s,"x-res"));var P=s.children[0].children;n(P,k,{cA:O,Cf:C,cr:null});console.log(Date.now()-$);
$=Date.now()}function n(g,k,$){for(var C=0;C<g.length;C++){var f=g[g.length-1-C],z=f.getAttribute("nodetype");
if(z=="transparencymask"){$.cr.z=A(f,$);continue}var s=f.getAttribute("compositeop"),O=f.getAttribute("filename"),a=f.getAttribute("channelflags"),X=f.children;
X=X.length==0?null:X[0].children;var P=k.QI();if(z=="paintlayer"){var Z=l(f,"x"),Y=l(f,"y"),K=$.Cf[$.cA+"/layers/"+O+".defaultpixel"],S=$.Cf[$.cA+"/layers/"+O],G=m(S);
P.rect=G[0];P.rect.offset(Z,Y);P.buffer=G[1];if(P.rect.VY()&&K.join()!="0,0,0,0"){P.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:K[0],B:K[1],k:K[2]})}};
P.yb(k)}}else if(z=="grouplayer"){P.add.lsct=ef.fz;P.Bx="pass";P.FK|=24;k.C.push(k.hG());var V=$.cr;
$.cr=P;n(X,k,$);$.cr=V}else if(z=="shapelayer"){var S=$.Cf[$.cA+"/layers/"+O+".shapelayer/content.svg"],T=J.KY(S),R=k.An(S,P.getName(),0,0);
P=R;var x=new iB(0,0,k.m,k.n),v=E.p.Wx(x).w;P.add.SoLd.Trnf=y.wR.Hh(v);P.add.SoLd.nonAffineTransform=y.wR.Hh(v);
P.vr(k,!1)}else if(z=="clonelayer"){var L=-1;for(var N=0;N<g.length;N++)if(g[N].getAttribute("name")==f.getAttribute("clonefrom"))L=N;
if(L!=-1){n([g[L]],k,$);P=k.C.pop()}}else console.log(z,f);P.nz(f.getAttribute("name"));if(l(f,"locked")==1)P.add.lspf=1<<31;
P.gb(l(f,"visible")==1);var u={normal:"norm",multiply:"mul ",diff:"diff",hard_light:"hLit"}[s];if(u)P.Bx=u;
else console.log(s);P.opacity=l(f,"opacity");if(a=="1110")P.QY=!0;var H=X?X[0]:null;if(H&&H.tagName=="mask")P.z=A(H,$);
k.C.push(P)}}function W(g,k){var $=0,C=0,f=g.length,z,s,O;while($<f){z=g[$++];if(z>31){s=z>>>5;if(s==7)s=7+g[$++];
O=(z&31)<<8|g[$++];var a=C-O-1,X=s>>>1;k[C++]=k[a++];k[C++]=k[a++];for(var L=0;L<X;L++){k[C++]=k[a++];
k[C++]=k[a++]}if((s&1)==1)k[C++]=k[a++]}else{for(var L=0;L<=z;L++){k[C++]=g[$++]}}}}function D(g,k){var $=0;
while(g[k+$]!=10)$++;return J.sv(g,k,$)}var j=new iB(0,0,64,64),I=new Uint8Array(64*64*4),U=new Uint8Array(64*64*4);
function M(){for(var L=0;L<4096;L++){var g=L<<2;I[g+0]=U[L+8192];I[g+1]=U[L+4096];I[g+2]=U[L];I[g+3]=U[L+12288]}}function m(g){var k=0,$={};
for(var L=0;L<5;L++){var C=D(g,k);k+=C.length+1;C=C.split(" ");$[C[0]]=parseInt(C[1])}var f=$.PIXELSIZE,z=[],s=new iB;
while(k<g.length){var C=D(g,k),O=C.split(",");k+=C.length+1;if(O[2]!="LZF")throw O[2];j.x=parseInt(O[0]);
j.y=parseInt(O[1]);s=s.x0(j);var a=parseInt(O[3]);z.push([j.clone(),new Uint8Array(g.buffer,k+1,a-1)]);
k+=a}var X=E.Q(s.O()*f);for(var L=0;L<z.length;L++){var P=z[L];W(P[1],U);if(f==4){M();E.Cb(I,P[0],X,s)}else E.B0(U,P[0],X,s)}return[s,X]}function l(g,k){return parseInt(g.getAttribute(k))}function A(g,k){var $=g.getAttribute("filename"),C=k.Cf[k.cA+"/layers/"+$+".pixelselection"],f=m(C),z=new h.ac;
z.tY=l(g,"visible")==1;z.rect=f[0];z.channel=f[1];return z}return{ew:w}}();jj.z1={};jj.z1.Xq=!0;jj.z1.Vu=function(w,n){bW.ew(w,n)};
jj.ZP={};jj.ZP.Xq=!0;jj.ZP.Vu=function(w,n){g6.ew(w,n)};jj.kD={};jj.kD.Xq=!0;jj.kD.Vu=function(w,n){gs.ew(w,n)};
jj.lG={};jj.lG.Xq=!0;jj.lG.Vu=function(w,n){dE.ew(w,n)};jj.ON={};jj.ON.Xq=!0;jj.ON.Vu=function(w,n){bE.ew(w,n)};
jj.U0={};jj.U0.Xq=!0;jj.U0.Vu=function(w,n){ci.ew(w,n)};jj.oV={};jj.oV.Xq=!0;jj.oV.La=function(w,n,W,D,j){if(D==null)D=[!0,!1,!1,!1,!0];
var I=eB.z8(w,{kL:D[0],hidden:D[1],ax1:D[2],aaK:D[3],Qp:D[4],adW:n,al4:W},j.hY);return I};jj.oV.Vu=function(w,n,W){eB.ew(w,n,W)};
jj.u9={};jj.u9.Xq=!0;jj.u9.Vu=function(w,n){var W=150,D=new eh(1,0,0,-1,0,0);D.scale(W/72,W/72);n.hh=W;
var j=new f3(n,D,!0);FromPS.Parse(w,j)};jj.HL={};jj.HL.Xq=!0;jj.HL.La=function(w,n,W,D,j){if(D==null)D=["",100,!1,!1,!1,0,!1];
D[7]=["jpg"];var I=new ToPDF;jv.z8(w,D,I,j.hY,n,W);return I.buffer};jj.HL.Vu=function(w,n,W){var D=2;
while(!0){var j=D*72,I=new eh(1,0,0,-1,0,0);I.scale(j/72,j/72);n.hh=j;var U=new f3(n,I,!0);FromPDF.Parse(w,U);
var M=Math.max(n.m,n.n);if(W&&M<Math.max(W[0],W[1])){n.C=[];var m=D;while(M*(D/m)<Math.max(W[0],W[1]))D++}else break}};
jj.GC={};jj.GC.Xq=!0;jj.GC.Vu=function(w,n){var W=72,D=new eh(1,0,0,1,0,0);D.scale(W/72,W/72);n.hh=W;
var j=new f3(n,D,!1);FromWMF.Parse(w,j)};jj.tn={};jj.tn.vv=!0;jj.tn.Xq=!0;jj.tn.La=function(w,n,W,D,j){if(D==null)D=["",100,!1,!1,!1,0,!1];
D[7]=[];var I=new ToEMF;jv.z8(w,D,I,j.hY);return I.buffer};jj.tn.Vu=function(w,n){var W=72,D=new eh(1,0,0,1,0,0);
D.scale(W/72,W/72);n.hh=W;var j=new f3(n,D,!1);FromEMF.Parse(w,j)};jj.$n={};jj.$n.Xq=!0;jj.$n.Vu=function(w,n){return a5.ew(w,n)};
jj.Ku={};jj.Ku.Vu=function(){var w,n,W,D,j,I,U=0,M=0,m=0,l=0,A=0;function g(f){var z=eD.ew(f),s=z.W_,O=new Uint8Array(f),Y=0,K,S;
if(s=="ILBM")return k(z,O);var a=J.IQ,X=J.q,P=z.sub,Z=k(P[0],O);for(var G=1;G<P.length-2;G++){var V=Z[Math.max(0,G-2)].acK.slice(0),T=P[G];
for(var R=0;R<T.sub.length;R++){var x=T.sub[R],v=x.R;if(x.Z4=="ANHD"){var N=O[v++];if(N!=5)throw N;var D=O[v++];
v+=8;var u=a(O,v);v+=2;K=a(O,v);v+=2;v++;v++;S=a(O,v);v+=2}else if(x.Z4=="DLTA"){var H=[],F=v;for(var L=0;
L<16;L++)H.push(X(O,v+L*4));v+=64;var t=I;for(var o=0;o<j;o++){if(H[o]==0)continue;v=F+H[o];for(var q=0;
q<t;q++){var _=O[v++],d=0;if(_==0)continue;for(var L=0;L<_;L++){var r=O[v++];if(r==0){var p=O[v++],Q=O[v++];
for(var B=0;B<p;B++){V[(d*j+o)*t+q]=Q;d++}}else if(r<128){d+=r}else{r-=128;for(var B=0;B<r;B++){V[(d*j+o)*t+q]=O[v+B];
d++}v+=r}}}}}else console.log(x.Z4)}var i=K==0?17:Math.round((K-Y)*1e3/60);Z.push({data:C(O,V),XL:new iB(0,0,w,n),acK:V,$U:"_a_frm"+G+","+i});
Y=K}Z[0].$U=Z[1].$U;return Z}function k(f,z){var s,O;U=0;M=0;m=0;l=0;A=0;for(var a=0;a<f.sub.length;
a++){var X=f.sub[a],P=X.R;if(X.Z4=="BMHD"){var Z=[];for(var L=0;L<4;L++)Z[L]=J.IQ(z,P+2*L);P+=8;var Y=Z[2],K=Z[3];
w=Z[0];n=Z[1];W=z[P++];D=z[P++];var S=z[P++];if(S!=1)throw S;I=w+15>>>4<<1;j=W+D}else if(X.Z4=="CMAP")U=P;
else if(X.Z4=="CAMG"){var G=J.q(z,P);M=G&32768,m=G&4,l=G&2048;A=G&128}else if(X.Z4=="BODY"){O=E.Q(I*n*j);
jY.ZV(z,P,X.size,O,0,O.length)}}s=C(z,O);return[{XL:new iB(0,0,w,n),data:s.buffer,acK:O}]}function $(f,bK){return f[bK>>>3]>>>7-(bK&7)&1}function C(f,z){var s=W-2,O=(1<<s)-1,a=Math.round(255/O),X,P,Z,Y=I*8,K=E.Q(w*n*4);
for(var S=0;S<n;S++)for(var G=0;G<w;G++){var V=0;for(var T=0;T<j;T++){var R=(S*j+T)*Y+G,x=$(z,R);V|=x<<T}V=V&(1<<W)-1;
var L=S*w+G,v=L<<2;if(U!=0){if(l!=0&&V>>>s!=0){var N=V>>>s,u=(V&O)*a;if(N==1)Z=u;else if(N==2)X=u;else if(N==3)P=u}else{var u=U+V*3;
X=f[u+0];P=f[u+1];Z=f[u+2]}}else{X=V>>>0&255;P=V>>>8&255;Z=V>>>16&255}K[v+0]=X;K[v+1]=P;K[v+2]=Z;K[v+3]=255}return K}return g}();
jj.uZ={};jj.uZ.Xq=!1;jj.uZ.La=function(w,n,W,D){var j=w[0][4],I=new Uint8Array(w[0][0]),U=2,M=j?!0:!1,m=M?4:3,l=new Uint8Array(n*W*m);
for(var A=0;A<W;A++)for(var g=0;g<n;g++){var k=A*n+g<<2,$=((W-A-1)*n+g)*m;l[$]=I[k+2];l[$+1]=I[k+1];
l[$+2]=I[k+0];if(M)l[$+3]=j[0][A*n+g]}if(!0){var C=l.length,f=0,z=new Uint8Array(C*2),s=0,O=0,a=n*m;
while(O<C){var X=O,P=0,Z=a*(Math.floor(O/a)+1);while(X<Z&&P<128){var Y=!0;for(var L=0;L<m;L++)Y=Y&l[O+L]==l[X+L];
if(!Y)break;X+=m;P++}if(P==1){var K=1;while(K<128&&O+(K+1)*m<Z){var Y=!0,S=O+K*m;for(var L=0;L<m;L++)Y=Y&l[S+L]==l[S+m+L];
if(Y)break;K++}z[s++]=K-1;for(var G=0;G<K;G++)for(var L=0;L<m;L++)z[s++]=l[O++]}else{z[s++]=127+P;for(var L=0;
L<m;L++)z[s+L]=l[O+L];s+=m;O+=m*P;f+=P}}l=z.slice(0,s);U+=8}var V=new Uint8Array(18+l.length+26);V[2]=U;
J.vP(V,12,n);J.vP(V,14,W);V[16]=m*8;V[17]=m==4?8:0;V.set(l,18);J.Jm(V,18+l.length+8,"TRUEVISION-XFILE.");
return V.buffer};jj.uZ.Vu=function(w){var n=new Uint8Array(w),W=0,D=n[0],j=n[1],I=n[2],U=n[4]*256+n[3],M=n[6]*256+n[5],m=n[7],l=n[9]*256+n[8],A=n[11]*256+n[10],g=n[13]*256+n[12],k=n[15]*256+n[14],$=n[16],C=n[17],f=C>>>4,z=J.sv(n,18,D),s=E.Q(g*k*4),W=18+D+(M*m>>>3),O=new Uint8Array(n.buffer,W);
if(I>3){var a=0,X=n,P=new Uint8Array(g*k*$>>>3),Z=W,Y=0,K=n.length,S=$>>>3;while(Y<P.length){var bK=X[Z];
Z++;if(bK<128)for(var L=0;L<bK+1;L++){for(var G=0;G<S;G++){P[Y]=X[Z];Y++;Z++}}else{for(var L=0;L<bK-127;
L++){for(var G=0;G<S;G++){P[Y]=X[Z+G];Y++}}Z+=S}}I-=8;O=P;W=Z}else W+=g*k*$>>>3;var V=new Uint8Array(4),T=jj.uZ.a3r;
for(var R=0;R<k;R++)for(var x=0;x<g;x++){var v=(f&2)==0?(k-R-1)*g+x:R*g+x,N=R*g+x,u,H,F,t=255,o=v*$>>>3;
if(I==1){var q=0;if($==8)q=O[o];else throw"e";T(n,18+D+U+(q*m>>>3),m,V);u=V[0];H=V[1];F=V[2];t=V[3]}else if(I==2){T(O,o,$,V);
u=V[0];H=V[1];F=V[2];t=V[3]}else if(I==3){if($==8)u=H=F=O[o];else throw"e"}var _=N*4;s[_]=u;s[_+1]=H;
s[_+2]=F;s[_+3]=t}var V={XL:new iB(0,0,g,k),data:s.buffer,$U:z};if(E.Ym(s)){var d=E.Q(g*k);E.hN(s,d,3);
E.cJ(s,4278190080,16777215);V.yo=[d]}return[V]};jj.uZ.a3r=function(w,n,W,D){var j,I,U,M=255;if(W==24||W==32){U=w[n];
I=w[n+1];j=w[n+2];if(W==32)M=w[n+3]}else if(W==16){var m=w[n+1]<<8|w[n+0];j=m>>>10&31;I=m>>>5&31;U=m>>>0&31;
j=Math.round(j*(255/31));I=Math.round(I*(255/31));U=Math.round(U*(255/31))}else throw"e";D[0]=j;D[1]=I;
D[2]=U;D[3]=M};jj.a2p=function(){var w,n=[],W=!1;function D(U,M,m,l){w=m;n.push(U,l);j()}function j(){if(W||n.length==0)return;
W=!0;jj.atH(n.shift(),"image/avif",I)}function I(U){w(null,[U],n.shift());W=!1;j()}return{Xq:!1,MA:!0,Vu:D}}();
jj.afD=function(){var w,n=[],W=!1,D,j,I,U=10,M,m,l,A=0,k;function g(a,X,P,Z,Y){w=P;n.push(a,Z);var K=hj.ew(a),S=hj.akS(K,"vide"),G=S.tkhd,V=S.mdia.minf.stbl,T=G.duration/K.moov.mvhd.MZ,R=V.stsz.length,x=Math.round(R/T);
console.log(K);D=G.gA;j=G.ag;var v=D+" \xD7 "+j+" px, "+R+" frames, "+fp.cN(D*j*4*R)+" decoded<br/>";
v+=T.toFixed(2)+" seconds, "+x+" FPS";var N=new ed(b.E.L,!0);N.data={d:b.c.P2,jW:"setFPS",Z1:U,FJ:f,ahQ:v};
Y.S(N)}function $(){if(W||n.length==0)return;W=!0;var a=n.shift(),X=hj.ew(a),P=hj.akS(X,"vide"),Z=P.tkhd,Y=P.mdia.minf.stbl,K=Y.stsd.aaF.avcC,S=Z.duration/X.moov.mvhd.MZ,G=Y.stsz.length,V=Math.round(G/S),T=Math.max(1,Math.round(V/U)),v=0;
if(Y.stsd.M6=="hvc1")alert("HVC1 codec not supported");k=Date.now();D=Z.gA;j=Z.ag;I=[];M=document.createElement("canvas");
m=M.getContext("2d");M.width=D;M.height=j;var R=new Uint8Array(a),x=[],N=new VideoDecoder({output:function(o){if(v%T==0){m.drawImage(o,0,0);
o.close();var q=m.getImageData(0,0,D,j).data.buffer,_=I.length;I[_]={$U:"_a_"+_+","+Math.round(T*1e3/V),XL:new iB(0,0,D,j),data:q}}else o.close();
clearTimeout(A);A=setTimeout(C,100);v++},error:function(o){console.log(o.message)}}),u={codec:"vp09.00.10.08",codedWidth:D,codedHeight:j};
if(K){u.codec="avc1.640034";u.description=R.slice(K.R,K.R+K.Rf)}N.configure(u);for(var L=0;L<G;L++){var H=hj.a7B(X,"vide",L),F=new Uint8Array(a,H[0],H[1]),t=new EncodedVideoChunk({timestamp:L,duration:1e3,type:L==0?"key":"delta",data:F});
N.decode(t)}}function C(){w(null,I,n.shift());W=!1;console.log(Date.now()-k);$()}function f(a){U=Math.max(1,Math.min(60,a));
if(window.VideoDecoder)$();else z()}function z(){if(W||n.length==0)return;W=!0;M=document.createElement("canvas");
m=M.getContext("2d");l=document.createElement("video");var a="data:"+"video/mp4"+";base64,"+jj.Da(n.shift());
l.src=a;l.muted=!0;l.currentTime=0;l.addEventListener("canplay",s,!1);l.addEventListener("timeupdate",O,!1)}function s(a){l.removeEventListener("canplay",s);
D=M.width=l.videoWidth;j=M.height=l.videoHeight;I=[];l.play()}function O(a){clearTimeout(A);m.drawImage(l,0,0);
I.push({$U:"_a_"+I.length+","+Math.round(1e3/U),XL:new iB(0,0,D,j),data:m.getImageData(0,0,D,j).data.buffer});
var X=l.currentTime+1/U;if(X<l.duration&&a){l.currentTime=X;A=setTimeout(O,1e3)}else{w(null,I,n.shift());
l.removeEventListener("timeupdate",O);W=!1;z();I=null}}return{Xq:!1,MA:!0,Vu:g}}();jj.zD={};jj.zD.Vu=function(w){var n=new Uint8Array(w),W=0,D=112,j=42,I=J.ly,A;
W+=8;var U=n[W];W++;if(U!=j)throw"e";var M=I(n,W);W+=4;var m=J.ND(n,W,M);W+=M*2;var l=[];while(W<n.length){A=I(n,W);
W+=4;if(A!=D)throw A;W+=4;A=n[W];W++;if(A!=j)throw A;var g=I(n,W);W+=4;var k=n[W];W++;if(k!=j){W-=5;
g=I(n,W);W+=8;A=n[W];W++;if(A!=j)throw A}var $=I(n,W)*2;W+=4;if(g>0)l.push(W+$);W+=$+g}var C=new DOMParser,f=C.parseFromString(m,"image/svg+xml").firstChild.firstChild,z=[];
jj.zD.J7(f,n,l,z);return z};jj.zD.J7=function(w,n,W,D){var j=w.firstChild.firstChild;if(j.tagName=="Image"){var I=j.getElementsByTagName("ImageDescription")[0],U=I.children[0].children,M=I.children[1].children,m=W.shift(),l=[];
for(var L=0;L<M.length;L++)l.push(parseInt(M[L].getAttribute("NumberOfElements")));while(l.length>3)l[2]*=l.pop();
var A=U.length,g=l[0],k=l[1],$=l[2],C=parseInt(M[0].getAttribute("BytesInc"));for(var f=0;f<$;f++){var z=E.Q(g*k*4);
E.cJ(z,4278190080);for(var s=0;s<A;s++){var O=E.Q(g*k);if(C==1)for(var a=0;a<O.length;a++)O[a]=n[m+a];
else if(C==2)for(var a=0;a<O.length;a++)O[a]=Math.min(255,(n[m+a*2+1]<<8|n[m+a*2])>>>2);else throw C;
if(s!=3)E.IL(O,z,s);if(A==1){E.IL(O,z,1);E.IL(O,z,2)}m+=g*k*C}D.push({XL:new iB(0,0,g,k),data:z.buffer})}}else{var X=w.children,P=0;
while(P<X.length&&X[P].tagName!="Children")P++;if(P==X.length)throw"e";X=X[P].children;for(var Z=0;Z<X.length;
Z++)jj.zD.J7(X[Z],n,W,D)}};jj.alo=function(){function w(U,M,m,l,A){var g=new Int8Array(U.buffer),k=new Int8Array(l.buffer),$=M+m;
while(M<$){var bK=g[M];M++;if(bK>=0&&bK<128)for(var L=0;L<bK+1;L++){k[A]=g[M];A++;M++}if(bK>=-127&&bK<0){for(var L=0;
L<-bK+1;L++){k[A]=g[M];A++}M++}}return A}function n(U,M,m,l,A,g){var k=M*m*l>>>3,$=E.Q(k*A),C=D(U,0,0)[0];
for(var f=0;f<A;f++){var z=C[f+1];if(g){var s=jj.ZO("jpg").Vu(z.buffer),O=E.Q(k);E.fo(new Uint8Array(s[0].data),O);
$.set(O,k*f)}else if(z[0]==255&&z[1]==216&&z[2]==255){var a=UTIF.LosslessJpegDecode(z);$.set(new Uint8Array(a.buffer),k*f)}else w(z,64,z.length,$,k*f)}return $}function W(U){var M=new Uint8Array(U),m=0,l=J.sv(M,0,128);
m+=128;var A=J.sv(M,m,4);m+=4;var g=j(M,m,0)[0],k=g.g28;if(k==null){alert("No image.");return[]}var $=k.cols,C=k.rows,f=$*C,z=k.photoInterpret,s=k.bitsAlloc,O=k.bitsStored,a=k.lossyCompr;
if(a==null)a=g.g8.lossyCompr;var X=g.g7fe0.pixelData,P=k.numOfFrames;P=P?parseInt(P):1;var Z=new Uint8Array(X.buffer),Y=f*s>>>3;
if(Z.length!=Y*P){X=n(X,$,C,s,P,a)}else{}if(s==16)X=new Uint16Array(X.buffer);console.log(k);console.log(g);
var K=[];for(var S=0;S<P;S++){var G=S*Y,U=E.Q($*C*4);U.fill(255);if(z=="MONOCHROME2"){var V=0,T=255,R=k.largestValue,x=k.smallestValue;
if(R!=null){T=R;V=x}else if(O!=8){T=0;V=1e9;for(var L=0;L<f;L++){var v=X[G+L];if(v>1<<O-8){if(v>T)T=v;
if(v<V)V=v}}}var N=255/(T-V);for(var L=0;L<f;L++){var v=Math.max(0,Math.min(255,(X[G+L]-V)*N)),u=L*4;
U[u]=U[u+1]=U[u+2]=v}}else if(z=="PALETTE COLOR"){var H=k.pltRed,F=k.pltGreen,t=k.pltBlue;for(var L=0;
L<f;L++){var o=X[G+L],u=L*4;U[u]=H[o]>>>8;U[u+1]=F[o]>>>8;U[u+2]=t[o]>>>8}}else throw z;K.push({XL:new iB(0,0,$,C),data:U.buffer})}return K}function D(U,M,m){var l=J.vQ,A=J.lm,g=J.ly,k=[],$=M;
while(M<U.length){var C=l(U,M);M+=2;var f=l(U,M);M+=2;var z=g(U,M);M+=4;if(C==65534&&f==57344){if(z==4294967295){var s=j(U,M,m+1);
k.push(s[0]);M=s[1]}else{k.push(U.slice(M,M+z));M+=z}}else if(C==65534&&f==57357){}else if(C==65534&&f==57565)break;
else throw"e"}return[k,M]}function j(U,M,m){var l=J.vQ,A=J.lm,g=J.ly,k={},$="\t".repeat(m);while(M<U.length){var C=l(U,M),O="",a=0,P=null;
M+=2;var f=l(U,M);M+=2;var z=C.toString(16),s=f.toString(16);if(C==65532)break;if(C==65534&&f==57357){M-=4;
break}if(C==65534&&f==57565)throw"e";if(f==0){M+=8;continue}if(65<=U[M+1]){O=J.sv(U,M,2);M+=2;if(O=="OB"||O=="SQ"||O=="OW"){a=g(U,M+2);
M+=6}else{a=l(U,M);M+=2}}else{O=I[z][s].split(",")[1];a=g(U,M);M+=4}var X=I[z][s];if(X)X=X.split(",")[0];
if(X==null){X="t"+s}if(O=="SQ"){var Z=D(U,M,m);P=Z[0];M=Z[1];a=0}else if(O=="US")P=l(U,M);else if(O=="SS")P=A(U,M);
else if(O=="UL")P=g(U,M);else if(O=="FL")P=J.mg(U,M);else if(O=="AT")P=[l(U,M),l(U,M+2)];else if(O=="OB")P=U.slice(M,M+a);
else if(O=="OW")P=new Uint16Array(U.slice(M,M+a).buffer);else if("UI CS DA TM DT SH LO ST LT PN AE AS DS IS".split(" ").indexOf(O)!=-1){var Y=M+a;
while(U[Y-1]==0)Y--;P=J.sv(U,M,Y-M).trim()}else{console.log($,JSON.stringify(J.sv(U,M,Math.min(a,32))));
throw O}if(k["g"+z]==null)k["g"+z]={};k["g"+z][X]=P;M+=a}return[k,M]}var I={"2":{"1":"fmiVersion","2":"classUID","3":"instanceUID","10":"syntaxUID","12":"icUID","13":"implVerName","16":"appTitle"},"4":{"1130":"fileSetID"},"8":{"5":"charSet","8":"imageType,CS","16":"classUID,UI","18":"instanceUID,UI","20":"studyDate","21":"seriesDate","22":"acqDate","23":"contentDate","2a":"acqDateTime","30":"studyTime","32":"acqTime","33":"contentTime","50":"accNumber","60":"modality,CS","64":"convType,CS","70":"manufacturer","80":"institutionName","81":"institutionAddress","90":"rpName","1010":"stationName","1030":"studyDescription","103e":"seriesDesc","1050":"ppName","1090":"modelName","1150":"rclassUID","1155":"rinstanceUID","2110":"lossyCompr","2112":"imageSequence"},"9":{},"10":{"10":"patientName,PN","20":"patientID,LO","30":"patientBirthDate","40":"patientSex","1010":"patientAge"},"18":{"60":"KVP","1020":"swVersion","1063":"frameTime","1150":"expTime","1151":"xrayTubeCurrent","1152":"exposure","1155":"radiation","1500":"posMotion","1510":"posAngle0","1511":"posAngle1"},"19":{},"20":{d:"studyUID,UI",e:"seriesUID,UI","10":"studyID","11":"seriesNumber","12":"acqNumber,IS","13":"instanceNumber,IS","20":"patientOrientation"},"21":{},"28":{"2":"spp,US","4":"photoInterpret,CS","8":"numOfFrames","9":"frameIncPointer","10":"rows,US","11":"cols,US","30":"pixelSpacing","100":"bitsAlloc,US","101":"bitsStored,US","102":"highBit,US","103":"pixRepresentation,US","106":"smallestValue","107":"largestValue","120":"pixPaddingValue","1040":"pixIntensityRelation","1050":"windCenter","1051":"windWidth","1090":"viewMode","1101":"pdRed","1102":"pdGreen","1103":"pdBlue","1199":"paletteUID","1201":"pltRed","1202":"pltGreen","1203":"pltBlue","2110":"lossyCompr","6010":"repFrameNum","6020":"foi","6022":"foiDescription","6040":"rWavePointer","6100":"maskSubtraction","6101":"maskOp","6110":"maskFrameNum"},"29":{},"37":{},"50":{"4":"calibImage"},"5000":{"5":"curveDim","10":"numOfPoints","20":"typeOfData","30":"axisUnits","103":"dataValRepr","104":"minCrdValue","105":"maxCrdValue","106":"curveRange","110":"curveDataDesc","112":"crdStartValue","114":"crdStepValue","3000":"curveData"},"7fe0":{"10":"pixelData,OB"}};
return{Vu:W}}();jj.o7={};jj.o7.Vu=function(w){var n=new Uint8Array(w),W=0,D={},A=1e9;for(var L=0;L<306;
L++){var j=J.sv(n,W,8).trim(),I=J.sv(n,W+9,71).split("/")[0].trim();D[j]=I;W+=80;if(j=="END"){W=Math.ceil(W/2880)*2880;
break}}var U=parseInt(D.NAXIS1),M=parseInt(D.NAXIS2),m=U*M,l=parseInt(D.BITPIX),g=-1e9,k=new Float32Array(m),$=new Float32Array(w,W,w.byteLength-W>>>2);
for(var L=0;L<m;L++){var C=L<<2,f=L<<1;if(l==-32){var z=n[W+C+0];n[W+C+0]=n[W+C+3];n[W+C+3]=z;var z=n[W+C+1];
n[W+C+1]=n[W+C+2];n[W+C+2]=z;k[L]=$[L]}else if(l==16){k[L]=J.vQ(n,W+f)}else throw l;var s=k[L];if(s<A)A=s;
if(s>g)g=s}var O=E.Q(m*4),a=1/g;for(var X=0;X<M;X++)for(var P=0;P<U;P++){var L=X*U+P,Z=(M-X-1)*U+P,C=Z<<2,s=k[L]*a;
O[C]=O[C+1]=O[C+2]=255*s;O[C+3]=255}return[{XL:new iB(0,0,U,M),data:O,$U:D.OBJECT}]};jj.mo={};jj.mo.Vu=function(w){var n=new Uint8Array(w),W=16,D=J.sv(n,W,4),I=32,s=0,O=0,a=!1,H;
W+=4;var j=J.sv(n,W,8);W+=8;while(n[W+I-1]==0)I--;var U=J.sv(n,W,I);W+=32;var M=J.sv(n,W,4);W+=4;W+=20;
var m=J.q(n,W);W+=4;var l=J.q(n,W);W+=4;var A=J.q(n,W);W+=4;var g=J.q(n,W);W+=4;var k=J.q(n,W);W+=4;
var $=J.q(n,W);W+=4;var C="FujiFilm "+U,f=[0,1,1,2];if(C=="FujiFilm X10"){C="FujiFilm FinePix X10";f=[2,1,1,0]}var z={t271:["FujiFilm"],t272:[C],t277:[1],t33421:[2,2],t33422:f,jy:1};
W=A;var X=[],P=J.IQ,Z=J.q(n,W);W+=4;for(var L=0;L<Z;L++){var Y=P(n,W);W+=2;var K=P(n,W);W+=2;if(Y==256){O=P(n,W);
s=P(n,W+2)}else if(Y==272){X=[P(n,W),P(n,W+2)]}else if(Y==273){X.push(P(n,W),P(n,W+2))}else if(Y==304){a=!(n[W]>>>7)}else if(Y==305){var S=Math.round(Math.sqrt(K)),G=[];
for(var V=0;V<K;V++)G.push(n[W+V]);G.reverse();z.t33421=[S,S];z.t33422=G}else if(Y==12272){var T=P(n,W),R=P(n,W+2),x=P(n,W+6);
z.t50728=[T/R,1,T/x]}W+=K}var v=s<O,N=n.slice(k,k+$),u=Math.round($*8/(s*O));if(N[0]==73&&N[1]==73&&N[2]==42){H=UTIF.decode(N.buffer)[0].fujiIFD;
u=H.t61443[0];var F=H.t61454,t=H.t61450;if(t)z.t50714=t;if(F)z.t50728=[F[0]/F[1],1,F[0]/F[2]];var o=H.t61447[0];
N=N.slice(o,o+H.t61448[0])}var $=N.length,q=$*8<s*O*u;if(q){console.log("compressed");var _=z.t33422,d=~~Math.sqrt(_.length),r=[];
for(var L=0;L<d;L++)r[L]=_.slice(L*d,L*d+d);N=new Uint8Array(UTIF._decompressRAF(N,r).buffer);$=N.length}function p(h2,jX,bm){bm=bm<<8-(jX&7);
var dC=jX>>>3;h2[dC]|=bm>>>16;h2[dC+1]|=bm>>>8;h2[dC+2]|=bm}var Q=$*8/(s*O);if(Q==16)for(var L=0;L<$;
L+=2){var B=N[L];N[L]=N[L+1];N[L+1]=B}else if(Q==14){for(var L=0;L<$;L+=4){var B=N[L];N[L]=N[L+3];N[L+3]=B;
B=N[L+1];N[L+1]=N[L+2];N[L+2]=B}}else if(Q==12)for(var L=0;L<$;L+=3){var i=N[L+2]<<16|N[L+1]<<8|N[L+0];
i=i>>>12|(i&4095)<<12;N[L]=i>>>16&255;N[L+1]=i>>>8&255;N[L+2]=i&255}if(v)N=jj.mo.awg(N,s,O);var c=v?2:1;
s*=c;z.t256=[s];z.t257=[O];z.t258=[u];z.t50719=[X[1],X[0]*c];z.t50720=[X[3],X[2]*c];z.width=s;z.height=O;
z.data=new Uint8Array(N.buffer);return[z]};jj.mo.awg=function(w,n,W){w=new Uint16Array(w.buffer);var D=new Uint16Array(n*W*2);
for(var j=0;j<W;j+=2)for(var I=0;I<n;I++){var U=j*n+I,M=U*2,m=w[U],l=w[U+n];D[M+1]=D[M+2*n]=l;if(((j>>>1)+I&1)==0){D[M]=m;
D[M+2*n+1]=w[U+1]}else{D[M]=w[U-1];D[M+2*n+1]=m}}return D};jj.xy={};jj.xy.vv=!0;jj.xy.La=function(w,n,W,D){var j=new Uint8Array(w[0][0]),I=n*W,U=[1,3,4][D[0]],M=8+8*D[1],m=D[2];
if(U==1){var l=new Uint8Array(n*W);E.hN(j,l,0);j=l}if(U==3){var l=new Uint8Array(n*W*3);for(var L=0;
L<I;L++){var A=L*4,g=L*3;l[g]=j[A];l[g+1]=j[A+1];l[g+2]=j[A+2]}j=l}if(M==16){var k=j.length,l=new Uint8Array(k*2);
for(var L=0;L<k;L++){var $=Math.round(j[L]*(65535/255));l[L*2+m]=$>>>8;l[L*2+1-m]=$&255}j=l}return j.buffer};
jj.bQ={};jj.bQ.Vu=function(w,n){function W(m){return~~(.5+E.ae(Math.max(0,Math.min(1,m)))*255)}var D=EXRLoader.parse(w),j=D.width,I=D.height,U=E.Q(j*I*4);
for(var M=0;M<I;M++)for(var m=0;m<j;m++){var L=(M*j+m)*4,l=((I-M-1)*j+m)*4;U[L]=W(D.data[l+0]);U[L+1]=W(D.data[l+1]);
U[L+2]=W(D.data[l+2]);U[L+3]=W(D.data[l+3])}return[{XL:new iB(0,0,j,I),data:U.buffer}]};jj.dZ={};jj.dZ.vv=!0;
jj.dZ.Xq=!0;jj.dZ.La=function(w,n,W,D,j){D=["",100,!1,!1,!1,0,!1];D[7]=["jpg"];var I=new ToDXF;jv.z8(w,D,I,j.hY);
return I.buffer};jj.dZ.Vu=function(w,n){var W=72,D=new eh(1,0,0,1,0,0);D.scale(W/72,W/72);n.hh=W;var j=new f3(n,D,!1);
FromDXF.Parse(w,j)};jj.AQ={};jj.AQ.Vu=function(){var w=J.vQ,n=J.ly,W=J.sv,D;function j(U,M,m,l,A){var g=n(U,m),k=n(U,m+4),$=n(U,m+8),C=w(U,m+12),f=w(U,m+14);
m+=16;var z={};for(var L=0;L<C+f;L++){var s=n(U,m),O=n(U,m+4),a,X;if(s>>>31==1){s=s&16777215}if(L<C)a=J.ND(U,M+s+2,w(U,M+s));
else a="id"+s;var P=l.slice(0);P.push(a);if(O>>>31==1){O=O&268435455;X=j(U,M,M+O,P,A)}else{var Z=n(U,M+O),Y=n(U,M+O+4),K=n(U,M+O+8),S=n(U,M+O+12);
if(S!=0)throw"e";if(Z<A[0]||Z>A[0]+A[1])throw"e";var G=A[2]+Z-A[0];X=U.slice(G,G+Y);var V=jj.zJ(X.buffer);
if(V&&["bmp","png","ico"].indexOf(V)!=-1){var T=jj.ZO(V);if(!T.Xq){var R=null;try{R=T.Vu(X.buffer)}catch(fV){}if(R){R[0].$U=P[1];
D.push(R[0])}}}else if(V)console.log(V)}z[a]=X;m+=8}return z}function I(U){D=[];var M=new Uint8Array(U),m=0,l=w(M,m);
m+=2;m+=58;var A=n(M,m);m+=4;m=A;var g=W(M,m,4);m+=4;var k=w(M,m);m+=2;var $=w(M,m);m+=2;var C=n(M,m);
m+=4;var f=n(M,m);m+=4;var z=n(M,m);m+=4;var s=w(M,m);m+=2;var O=w(M,m);m+=2;m+=s;var a={};for(var L=0;
L<$;L++){var X=m;while(M[X]!=0)X++;var P=W(M,m,X-m),Z=n(M,m+8),Y=n(M,m+12),K=n(M,m+16),S=n(M,m+20),G=n(M,m+24),V=n(M,m+28),T=w(M,m+32),R=w(M,m+34),O=n(M,m+36);
a[P]=[Y,Z,S,K,O];if(G+V!=0)throw"e";m+=40}for(var x in a){var v=a[x];m=v[2];if(x==".rsrc"){var N=j(M,m,m,[],v),u="id134"}}return D}return I}();
jj.xz={};jj.xz.Xq=!0;jj.xz.Vu=function(w,n,W){bv.ew(w,n,W)};(function(){var w=jj.gF.get("wasm/zstd").buffer;
WebAssembly.instantiate(w).then(function(n){var W=n.instance.exports;jj.xz.atg=W})}());jj.xz.Ue=function(w,n){var W=jj.xz.atg,D=w.length,j=W.memory,I=2*D+1e6,m=8;
jj.ne(W,I);var U=new Uint8Array(j.buffer),M=W.malloc(D);U.set(w,M);while(!0){var l=n==null?D*m:n;jj.ne(W,I+l);
var A=W.malloc(l),g=W.ZSTD_decompress(A,l,M,D);if(g==-70){W.free(A);m+=m>>>1;if(n!=null)throw"error"}else{U=new Uint8Array(j.buffer);
w=U.slice(A,A+g);W.free(A);break}}W.free(M);return w};jj.Ez={};jj.Ez.Xq=!0;jj.Ez.Vu=function(){var w=0,n=1,W=2,D=3,j=4,I=5,U=6,M=7,m=1,l=2,A=7,g=8,k=9,$,C,f,z,s;
function O(){var bK=J.ck($,C);C+=4;return bK}function a(){var H=0,F=0;for(var L=0;L<5;L++){var t=$[C++];
H+=(t&127)<<F;F+=7;if((t&128)==0)break}return H}function X(){var H=a(),F=J.KY($,C,H);C+=H;return F}function P(){return{typeName:X(),ask:O()}}function Z(){var H=O(),F=X(),t=[],o=O();
for(var L=0;L<o;L++)t.push([X()]);return{id:H,I6:F,a0O:t}}function Y(H){var F=H.a0O,t=[];for(var L=0;
L<F.length;L++)F[L].push($[C++]);for(var L=0;L<F.length;L++){var o=F[L][1],q;F[L].push(K(o))}}function K(H){var F;
if(H==w)F=$[C++];else if(H==D)F=X();else if(H==j)F=P();else if(H==n||H==W||H==U||H==I){}else throw H;
return F}function S(H,F,t){var o;if(H==w){if(F==m)o=$[C++]==1;else if(F==l){o=$[C++]}else if(F==g)o=O();
else if(F==k){o=O();O()}else throw F}else if(H==D){o=R(t+1)}else if(H==j){o=R(t+1)}else if(H==I){o=R(t+1)}else if(H==n){o=R(t+1)}else if(H==U){o=R(t+1)}else throw H;
return o}function G(H,F){var t=f["c"+H],o=t.a0O,q={_class:t.I6};for(var L=0;L<o.length;L++){var _=o[L],d=_[1],r=_[2],p=S(d,r,F),Q=_[0];
q[Q]=p}return q}function V(H,F,t,o){var q=[];for(var L=0;L<H;L++){var _=S(F,t,o);if(_.ib&&_.ib=="null_count"){var d=_.jB;
for(var r=0;r<d;r++)q.push(null);L+=d-1}else q.push(_)}return q}function T(){return[O(),O()]}function R(H){if(H==null)throw"e";
var F=null,t=$[C],o=null;C++;if(t==0){var q=O(),_=O(),d=O(),r=O();F=[q,_,d,r]}else if(t==1){o=O();var p=O();
F=G(p,H)}else if(t==4){var Q=Z();o=Q.id;Y(Q);f["c"+Q.id]=Q;F=G(Q.id,H)}else if(t==5){var Q=Z();o=Q.id;
Y(Q);var B=O();f["c"+Q.id]=Q;F=G(Q.id,H)}else if(t==6){o=O();var i=X();F=i}else if(t==7){o=O();var c=$[C++];
if(c!=0)throw c;var h2=O();if(h2!=1)throw h2;var jX=O(),bm=$[C++],dC=K(bm);F=V(jX,bm,dC,H)}else if(t==9){var fn=O();
F={ib:"ref",jB:fn};s["o"+fn]=!0}else if(t==10){F={ib:"null_count",jB:1}}else if(t==11){F={ib:"end"}}else if(t==12){var B=O(),fK=X()}else if(t==13){var i6=$[C++];
F={ib:"null_count",jB:i6}}else if(t==16){var dh=T();o=dh[0];F=V(dh[1],j,null,H)}else if(t==17){var dh=T();
o=dh[0];F=V(dh[1],n,null,H)}else throw"e";if(o!=null&&o>0){if(z["o"+o]!=null)throw"e";z["o"+o]=F}return F}function x(H,z){if(H instanceof Array){for(var L=0;
L<H.length;L++)H[L]=v(H[L],z)}else if(H instanceof Object){for(var F in H)H[F]=v(H[F],z)}}function v(H,z){if(H&&H.ib&&H.ib=="ref")return z["o"+H.jB];
else return H}function N(H,F,t){$=new Uint8Array(H);C=0;f={};z={};s={};var o=J.sv($,0,4);if(o!="PDN3")throw o;
C+=4;var q=J.vQ($,C)+$[C+2]*256*256;C+=3;var _=J.sv($,C,q);C+=q;C+=2;while(!0){var d=R(0);if(d&&d.ib&&d.ib=="end")break}for(var r in s)if(z[r]==null)throw r;
for(var r in z)x(z[r],z);var p=z.o1;console.log(p);F.m=p.width;F.n=p.height;F.buffer=E.Q(F.m*F.n*4);
var Q=p.layers["ArrayList+_items"];for(var L=0;L<Q.length;L++){var B=Q[L];if(B==null)continue;console.log(B);
var i=B["Layer+width"],c=B["Layer+height"],h2=B["Layer+properties"],jX=B.properties,bm=jX.blendOp._class.split("+").pop();
bm=bm.slice(0,bm.length-7);var dC={Normal:"norm",Multiply:"mul ",Additive:"lddg",ColorBurn:"idiv",ColorDodge:"div ",Reflect:"lddg",Glow:"hMix",Overlay:"over",Difference:"diff",Negation:"smud",Lighten:"lite",Darken:"dark",Screen:"scrn",Xor:"smud"}[bm],fn=F.QI();
fn.nz(h2.name);fn.opacity=h2.opacity;fn.gb(h2.visible);fn.Bx=dC;var fK=1<<16,i6=Math.ceil(i*c/fK);fn.rect=new iB(0,0,i,c);
fn.buffer=E.Q(i*c*4);var dh=fn.buffer;C+=5;for(var kA=0;kA<i6;kA++){var ig=u();dh.set(ig[1],ig[0]*fK*4)}for(var iJ=0;
iJ<dh.length;iJ+=4){var fL=dh[iJ+0];dh[iJ+0]=dh[iJ+2];dh[iJ+2]=fL}F.C.push(fn)}}function u(){var H=J.q($,C);
C+=4;var F=J.q($,C);C+=4;var t=pako.inflateRaw($.slice(C+10));C+=F;return[H,t]}return N}();jj.up={};
jj.up.Xq=!0;jj.up.Vu=function(w,n){eq.ew(w,n)};jj.PV={};jj.PV.Xq=!0;jj.PV.Vu=function(){var w,n,z=null,K,S;
function W(){var u=w[n];n+=1;return u}function D(){var u=J.IQ(w,n);n+=2;return u}function j(){var u=J.q(w,n);
n+=4;return u}function I(){var u=J.W6(w,n);n+=4;return u}function U(){var u=J.gg(w,n);n+=8;return u}function M(){var u=j();
if(u>200)throw u;var H=J.yL(w,n,u);n+=u*2;return H}function m(){var u=J.Gb(w,n);n+=8;return u}function l(){var u=J.F_(w,n);
n+=4;return u}function A(){var u=j();if(j()!=4)throw"e";var H=[];for(var L=0;L<u;L++)H.push(j());return H}function g(u,H,F){for(var L=0;
L<u.length;L++)if(u[L][H]==F)return u[L]}function k(u,H){var F=Date.now();w=new Uint8Array(u);n=J.TN(w,"CH"+"NK"+"SQ"+"Li")+8;
var t=U(),o=i3.parse(w.buffer.slice(n,n+t)),q=i3.a5r(o,!0);console.log(q);var _=q.Canvas[0],d=_.Width,r=_.Height,p=_.Unit,Q=H.hh=_.Resolution;
if(p==0){}else if(p==2){d=Math.round(d*Q/25.4);r=Math.round(r*Q/25.4)}else if(p==3){d=Math.round(d*Q);
r=Math.round(r*Q)}else if(p==5){d=Math.round(d*Q/72);r=Math.round(r*Q/72)}else{console.log(_);throw p}H.m=d;
H.n=r;H.buffer=E.Q(d*r*4);console.log(Date.now()-F);var B=g(q.Layer,"MainId",_.RootFolder);R(q,w,H,B.FirstChildIndex,0);
console.log(Date.now()-F)}function $(){var u=J.vQ(w,n);n+=2;return u}function C(){var u=J.ly(w,n);n+=4;
return u}function f(){var u=J.ck(w,n);n+=4;return u}function s(u){var H={11:"runs",31:"font",32:"size",33:"unit",34:"colr",42:"bbox",57:"fnts",63:"bdim",64:"bplg"},t=0;
w=u;n=0;var F={};while(n<w.length){var o=C(),q=C(),_=n+q;if(q==0)continue;var d=[];if(o==11){var r=C();
for(var p=0;p<r;p++){var Q=[C(),C()];d.push(Q);t+=Q[1];var B=n+C()-4;Q.push($(),$(),$(),$());Q.push(J.sY(w,n));
n+=8;var i=$();Q.push(J.ND(w,n,i));n+=i*2;if(n!=B)throw"e"}}else if(o==31){d=J.KY(w,n,q);n+=q}else if(o==34)for(var L=0;
L<3;L++)d.push(C()>>>16);else if(o==42)for(var L=0;L<4;L++)d.push(f());else if([32,33,35,37,38,43,44,45,46,48,49,50,51,52,53,55,58,59,60,61,62].indexOf(o)!=-1){if(q!=4)throw"e";
d=C();if([37,45,46,51,53,55,61,62].indexOf(o)!=-1){if(d!=0&&d!=1)throw o+":"+d;n=_;continue}}else if(o==47){var c=$();
if(C()!=50)throw"e";if(C()!=0)throw"e";var h2=$();d=J.sv(w,n,h2);n+=h2}else if(o==57){var r=$();for(var L=0;
L<r;L++){var jX=$(),bm=J.sv(w,n,jX);n+=jX;var dC=$(),fn=J.sv(w,n,dC);n+=dC;d.push([bm,fn])}var fK=C();
for(var L=0;L<r;L++)d[L].push(fK)}else if(o==39||o==63)d.push(C(),C());else if(o==64){for(var L=0;L<8;
L++)d.push(J.ck(w,n+L*4)/100);n+=32}else{d=w.slice(n,_);n+=q}var i6=H[o];if(i6==null)i6="t"+o;if(F[i6])throw"e";
F[i6]=d;if(n!=_)throw o}if(z){}z=F;return F}function O(u){w=u;n=0;var H=j();if(H!=u.length)throw"e";
var F=j(),t=M(),o=j(),q=m(),_=[j()/4294967295,j()/4294967295,j()/4294967295];return[o,q,_]}function a(u,H){function F(){var jW=[];
for(var L=0;L<4;L++)jW.push(J.W6(w,n+L*4));n+=16;return jW}function t(bK){var jW=[];for(var L=0;L<bK;
L++)jW.push(l());return jW}function o(jW){var eP="";for(var L=n;L<jW;L+=4)eP+=w.slice(L,L+4).join(", ")+"\n";
return eP}w=u;n=H+8;var q=U(),_=n+q;n+=56;if(n==_)return;var d=[],r=[],p=[],Q=[],B=[];while(n<_){var i=j(),dh=1;
if(i!=88&&i!=96)throw i;var i=j();if(i!=72)throw"e";var c=j();if(c!=88&&c!=104&&c!=120)throw c;var i=j();
if(i!=88)throw"e";var h2=j(),jX=j(),bm=F(),dC=[];p.push(dC);for(var L=0;L<6;L++){dC.push(P(j()))}var fn=m(),fK=j();
if(fK==16||fK==1040||fK==304){j();fK=j()}if(fK!=0&&fK!=1&&fK!=2&&fK!=3&&fK!=4&&fK!=5&&fK!=8&&fK!=9&&fK!=22)throw fK;
var i6=m();Q.push(i6);var kA=j(),ig=(jX&256)!=0,iJ=[],fL=[],fB={88:1,104:2,120:3}[c];for(var L=0;L<h2;
L++){var ah=L==0?1:fB;for(var eS=0;eS<ah;eS++)iJ.push(m(),m());fL.push(ah==1?L==0?"M":"L":ah==2?"Q":"C");
var gL=F(),e_=j();dh=l();var c2=t(10),jS=j(),ie=j()}B.push(dh);if(c==104){var as=m(),gb=m();if(ig){fL.push("Q");
iJ.push(as,gb,iJ[0],iJ[1])}}if(c==120){var as=m(),gb=m(),gx=m(),eo=m();if(ig){fL.push("C");iJ.push(as,gb,gx,eo,iJ[0],iJ[1])}}if(jX&128){var di=["M"],d0=[iJ[0],iJ[1]],e6=iJ.length>>>1,dt=E.p.pl(iJ);
for(var L=0;L<e6;L++){var gJ=iJ[2*L],iW=iJ[2*L+1],g5=.7;for(var eS=0;eS<2;eS++){dt[L*4+eS*2]=g5*dt[L*4+eS*2]+(1-g5)*gJ;
dt[L*4+eS*2+1]=g5*dt[L*4+eS*2+1]+(1-g5)*iW}}for(var L=1;L<e6;L++){di.push("C");d0.push(dt[L*4-2],dt[L*4-1],dt[L*4],dt[L*4+1],iJ[L*2],iJ[L*2+1])}if(ig){di.push("C");
d0.push(dt[e6*4-2],dt[e6*4-1],dt[0],dt[1],iJ[0],iJ[1])}iJ=d0;fL=di}if(ig)fL.push("Z");r=r.concat(iJ);
d=d.concat(fL)}if(n!=_)throw"e";return[{w:r,F:d},p,Q,B]}function X(u,H){w=u;n=H+8;var F=U(),t=n+F,o=0;
n+=56;var q=[];while(n<t){var _=j(),d=n+_-4;if(d>t)throw"e";if(_==11){n-=4;var r=M(),p=j();if(p!=12)throw"e";
var Q=A(),B=M(),p=j();if(p!=12)throw"e";var i=A();if(n!=t)throw"e"}else{var c=M(),h2=j();if(h2!=o)throw h2;
o++;var jX=D();if(jX!=0&&jX!=1&&jX!=2&&jX!=5)throw jX;var bm=W();if(bm!=0&&bm!=32&&bm!=64)throw bm;if(j()!=1)throw"e";
if(j()!=1)throw"e";if(W()!=0)throw"e";if(j()==1){var dC=j(),fn=J.ly(w,n);if(dC!=fn+4)throw"e";q.push(new Uint8Array(w.buffer,n+4,fn));
n+=dC}else q.push(new Uint8Array(0));var fK=M();if(n!=d)throw n}}return q}function P(u){return Math.min(255,Math.round(u/16777216))}function Z(u){w=u;
n=0;var H=j();if(H!=16)throw H;var F=j();if(F!=102)throw F;var t=j();if(t!=42&&t!=58)throw t;var o=j();
if(u.length-o!=118+t)throw u.length-o;var q=M();if(q!="Parameter")throw q;var _=j(),d=j(),r=j(),p=j(),Q=[];
for(var L=0;L<16;L++)Q.push(j());var q=M();if(q!="InitColor")throw q;if(j()!=20)throw"e";var B=j(),i=j(),c=j();
if(j()!=4)throw"e";if(t==58){var h2=[];Q.push(h2);for(var L=0;L<4;L++)h2.push(P(j()))}var q=M();if(q!="BlockSize")throw q;
var jX=j();if(jX!=12)throw jX;var bm=A();if(n!=w.length)throw"e";return[_,d,r,p,B*255,Q]}function Y(u,H){var F=J.sv(H,0,40),t=g(u["ExternalC"+"hunk"],"Exte"+"rnalID",F);
if(t==null){console.log("chnk not found",F)}return t?t.Offset:-1}function G(u,H,F,t){if(K==null){K=E.Q(256*256*4);
S=E.Q(256*256)}var o=u.Mipmap,q=u.MipmapInfo,_=u.Offscreen,d=g(o,"MainId",F),r=g(q,"MainId",d.BaseMipmapInfo),p=g(_,"MainId",r.Offscreen),Q=Y(u,p.BlockData),k=null;
if(Q==-1)return null;var B=X(H,Q),i=Z(p.Attribute),c=i[0],h2=i[1],jX=i[2],bm=i[3],dC=i[4],fn=i[5],fK=fn[16],i6=fn[1],dh=fn[2],kA=i6+dh;
if(dh!=fn[5])throw"e";if(i6!=fn[7])throw"e";var ig=E.Q(256*(fn[6]+fn[8])),iJ=new iB;if(fK)iJ=new iB(0,0,c,h2);
else{for(var fL=0;fL<bm;fL++)for(var fB=0;fB<jX;fB++){var ah=B[fL*jX+fB];if(ah.length==0)continue;iJ=iJ.x0(new iB(fB<<8,fL<<8,256,256))}}var eS=iJ.wU(new iB(0,0,c,h2)),gL=E.Q(eS.O()*(kA==1?1:4));
if(fK)new Uint32Array(gL.buffer).fill(255<<24|fK[0]<<16|fK[1]<<8|fK[2]);if(kA==1)gL.fill(dC);for(var fL=0;
fL<bm;fL++)for(var fB=0;fB<jX;fB++){var ah=B[fL*jX+fB];if(ah.length==0)continue;var e_=new Uint8Array(ah.buffer,ah.byteOffset+2,ah.length-6),c2=new iB(fB<<8,fL<<8,256,256);
UZIP.inflateRaw(e_,ig);if(kA==1){if(fn[8]==32){V(ig,0,S);E.B0(S,c2,gL,eS)}else E.B0(ig,c2,gL,eS)}else if(kA==2){if(fn[8]==32){new Uint32Array(K.buffer).fill(4278190335);
V(ig,0,S);E.IL(S,K,3);V(ig,256*32,S);E.Mj(S,K)}else for(var L=0;L<262144;L+=4){var fK=ig[65536+(L>>>2)];
K[L]=fK;K[L+1]=fK;K[L+2]=fK;K[L+3]=ig[L>>>2]}E.Cb(K,c2,gL,eS)}else if(kA==5){for(var L=0;L<262144;L+=4){K[L]=ig[65536+L+2];
K[L+1]=ig[65536+L+1];K[L+2]=ig[65536+L+0];K[L+3]=ig[L>>>2]}E.Cb(K,c2,gL,eS)}else throw kA}if(t&&kA==1){var jS=E.Q(c*h2*4);
E.IL(gL,jS,3);gL=jS}return[eS,gL,dC]}function V(u,n,H){for(var L=0;L<H.length;L++){H[L]=(u[n+(L>>>3)]>>>7-(L&7)&1)*255}}var T=["norm","dark","mul ","idiv","lbrn",null,"dkCl","lite","scrn","div ",null,"lddg","lddg",null,"over",null,"hLit",null,null,null,null,null,"smud",null,null,null,null,null,null,null,"pass",null,null,null,null,null,"fdiv"];
function R(u,H,F,t,o){var q=u.Layer,_=u.Canvas[0];while(t!=0){var d=g(q,"MainId",t),r=d.Type,jX=!1;console.log(d);
var p=F.QI();p.nz(d.Name);p.opacity=Math.min(255,d.Opacity);p.gb((d.Visibility&1)!=0);p.Bx=T[d.Composite];
if(p.Bx==null){alert("Unknown blend mode "+d.Composite);p.Bx="norm"}p.QY=d.Clip==1;F.C.push(p);var Q=d.LayerMaskMipmap;
if(Q!=0){var B=G(u,H,Q,!1);if(B){p.z=new h.ac;p.z.rect=B[0];p.z.channel=B[1];p.z.color=B[2];x(p.z.rect,d,"Mask","Mask");
p.z.ky()}}var i=[];for(var L=0;L<3;L++)i.push(P(d["DrawColorMain"+["Red","Green","Blue"][L]]));var c={t:"Objc",v:E.M.lW({o:i[0],B:i[1],k:i[2]})},h2=JSON.parse(at.default);
for(var L=0;L<at.order.length;L++)h2[at.Pa[L]]={t:"VlLs",v:[]};if(d.DrawColorEnable==1&&r!=1584){jX=!0;
var bm=JSON.parse(at.UR[at.order.indexOf("SoFi")]);bm.Clr=c;h2.solidFillMulti.v.push({t:"Objc",v:bm})}if(d.EffectInfo){var dC=O(d.EffectInfo),i=dC[2];
if(dC[0]==1){jX=!0;var bm=JSON.parse(at.UR[at.order.indexOf("FrFX")]);bm.Clr.v=E.M.lW({o:i[0]*255,B:i[1]*255,k:i[2]*255});
bm.Sz.v.val=Math.round(dC[1]);h2.frameFXMulti.v.push({t:"Objc",v:bm})}}if(d.FilterLayerInfo){w=d.FilterLayerInfo;
n=0;var fn=j(),fK=j();if(fK!=w.length-n)throw"e";var i6={1:"brit",3:"curv",4:"hue2",5:"blnc",6:"nvrt",9:"grdm"}[fn];
if(i6!=null){var dh=cx._1(i6);p.add[i6]=dh?dh:{};if(i6=="brit")cx.fI["g"+i6](dh,[I(),I(),!0]);if(i6=="hue2")cT.nr(dh,0,[I(),I(),I()]);
if(i6=="curv"){var kA=[],ig=n;for(var L=0;L<32;L++){n=ig+L*130;var iJ=D(),fL=[];kA.push(fL);for(var fB=0;
fB<iJ;fB++)fL.push(D()/65535,D()/65535)}for(var L=0;L<4;L++){var fL=kA[L],ah=e0.Qw(dh,L),eS=ah[0];for(var fB=0;
fB<fL.length;fB+=2){var gL=ah[fB>>>1]=JSON.parse(JSON.stringify(eS));gL.v.Hrzn.v=Math.round(fL[fB]*255);
gL.v.Vrtc.v=Math.round(fL[fB+1]*255)}e0.nr(dh,L,ah)}}if(i6=="grdm"){var e_=dh.Grad.v,c2=[],jS=j();if(jS!=fK-4)throw jS;
var ie=j();if(ie!=16)throw ie;var as=j();if(as!=28)throw as;var gb=j();for(var L=0;L<gb;L++){var gx=0,eo=[];
for(var fB=0;fB<7;fB++)eo.push(j());c2.push([eo[6]/32768,[eo[1]/4294967295,eo[2]/4294967295,eo[3]/4294967295],eo[4]/4294967295])}E.M.WP(c2,e_)}if(i6=="blnc"){dh.PrsL.v=j()==1;
for(var L=0;L<3;L++){var di=dh[["ShdL","MdtL","HghL"][L]].v;for(var fB=0;fB<3;fB++)di[fB].v=I()}}}else console.log("Unknown adjustment",fn,fK,p.getName())}if(r==1584){p.FK|=16;
p.add.SoCo={classID:"null",Clr:c};p.yb(F)}else if(r==800){F.C.pop()}else if(d.Folder!=0){p.add.lsct=(d.Folder&16)!=0?ef.Se:ef.fz;
p.Bx="pass";F.C.pop();F.C.push(F.hG());R(u,H,F,d.FirstChildIndex,o+1);F.C.push(p)}else if(r==0||r==1||r==2||r==3){var B=G(u,H,d.RenderMipmap,!0);
if(B){p.rect=B[0];p.buffer=B[1];x(p.rect,d,"Render","");p.ky()}if(d.TextLayerType!=null){var d0="TextLayerString",e6="TextLayerAttributes",dt=[d[d0]],gJ=[d[e6]];
if(d[d0+"Array"]){w=d[d0+"Array"];n=0;while(n<w.length){var fK=C();dt.push(w.slice(n,n+fK));n+=fK}w=d[e6+"Array"];
n=0;while(n<w.length){var fK=C();gJ.push(w.slice(n,n+fK));n+=fK}}var iW=p;F.C.pop();for(var g5=0;g5<dt.length;
g5++){var p=iW.clone();F.C.push(p);var eP=s(gJ[g5]),fZ=eP.runs,j3=eP.fnts,dr=eP.bplg,c0=eP.bbox,fM=c0[2]-c0[0],cB=c0[3]-c0[1],iI=dr[2]-dr[0],jD=dr[3]-dr[1],j8=new eh;
j8.translate(-fM/2,-cB/2);j8.rotate(Math.atan2(-jD,iI));j8.translate(fM/2,cB/2);var jG=c0[0]+d.OffsetX,i1=c0[1]+d.OffsetY;
j8.translate(jG,i1);p.add.lnsr="rend";p.add.TySh=hd._3(0,0);p.add.TySh.IA=new iB(0,0,500,500);p.add.TySh.D=j8;
var bH=p.add.TySh._o,a_=J.KY(dt[g5]);p.nz(a_);hd.KO(bH,0,a_);hd.VL(bH,1);hd.sV(bH,[0,0,fM,cB]);for(var L=0;
L<fZ.length;L++){var aR=fZ[L],iY=aR[0],gy=iY+aR[1],gr=aR[2],fs=hd.tG(bH,iY,gy),dQ=F.hh/72*eP.size/100;
if((gr&512)!=0)dQ*=aR[6]/100;fs.lJ.FontSize=Math.round(dQ);var c=(gr&256)!=0?aR.slice(3):eP.colr;fs.lJ.FillColor={Type:1,Values:[1,c[0]/65535,c[1]/65535,c[2]/65535]};
var ep=aR[7]==""?eP.font:aR[7];if(j3){if(j3[L])ep=j3[L][1];else for(var fB=0;fB<j3.length;fB++)if(j3[fB][0]==ep)ep=j3[fB][1]}hd.hI(fs,ep);
hd.g0(bH,iY,gy,fs)}if(p.rect.O()==0)F.XW=!0;else{p.rect=new iB(jG,i1,fM,cB);p.buffer=E.Q(p.rect.O()*4);
E.Cb(iW.buffer,iW.rect,p.buffer,p.rect)}}}}var b2=u.VectorObjectList;if(d.VectorNormalType!=null&&b2&&g(b2,"LayerId",t)){var eX=g(b2,"LayerId",t).VectorData,iz=Y(u,eX),en=a(H,iz);
if(en){var ko=null;if(p.add.TySh){var ko=p.clone();F.C.push(ko);delete p.add.TySh}v(p,d,en[0]);if(p.ue()){p.FK|=24;
var fh=F.QI();fh.nz(p.getName());fh.opacity=p.opacity;F.C.push(fh);v(fh,d,en[0]);N(fh,en);fh.yb(F)}else{N(p,en,ko!=null)}p.yb(F);
if(ko){ko.add.TySh.D.concat(new eh(1,0,0,1,p.rect.x+p.rect.m/2,p.rect.y+p.rect.n/2))}}}if(jX)p.add.lmfx=h2;
if(t==_.CurrentLayer)F.g=[F.C.indexOf(p)];t=d.NextIndex}}function x(u,H,F,t){u.x+=H[F+"OffscrOffsetX"]+H[t+"OffsetX"];
u.y+=H[F+"OffscrOffsetY"]+H[t+"OffsetY"]}function v(u,H,F){u.add.vmsk=new h.Rd;E.p.D(F.w,new eh(1,0,0,1,H.OffsetX,H.OffsetY),F.w);
u.add.vmsk.i=E.p.oF(F);u.hu()}function N(u,H,F){var t=H[1][0],o=H[2][0]*H[3][0];u.FK|=16;var q=u.add.vstk=JSON.parse(JSON.stringify(at.QO.default));
q.strokeEnabled.v=!0;q.fillEnabled.v=F==!0;u.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:255,B:255,k:255})}};
q.strokeStyleContent.v.Clr.v=E.M.lW({o:t[0],B:t[1],k:t[2]});q.strokeStyleLineWidth.v.val=o*2;q.strokeStyleLineCapType.v.strokeStyleLineCapType="strokeStyleRoundCap"}return k}();
var je={};je.YG=!1;je.RA=!1;je.hi=!1;je.T=document.createElement("canvas");je.VE=null;je.vc=null;je.fC=0;
(function(){var w={alpha:!0,antialias:!1,depth:!1,premultipliedAlpha:!1},n;if(!n)n=je.T.getContext("webgl",w);
if(!n)n=je.T.getContext("experimental-webgl",w);if(n){je.YG=!0;je.RA=!0;je.VE=n;je.vc=n.createFramebuffer();
n.bindFramebuffer(n.FRAMEBUFFER,je.vc);n.disable(n.BLEND);n.disable(n.DEPTH_TEST);var W=n.createBuffer();
n.bindBuffer(n.ARRAY_BUFFER,W);n.bufferData(n.ARRAY_BUFFER,new Float32Array([0,0,1,0,0,1,0,1,1,0,1,1]),n.STATIC_DRAW);
n.enableVertexAttribArray(0);n.vertexAttribPointer(0,2,n.FLOAT,!1,0,0)}}());je.a21=function(w){w=w.replace(/\s\s+/g," ");
w=w.replace(/; /g,";");w=w.replace(/} /g,"}");w=w.replace(/ }/g,"}");w=w.replace(/{ /g,"{");w=w.replace(/ {/g,"{");
w=w.replace(/= /g,"=");w=w.replace(/ =/g,"=");w=w.replace(/\| /g,"|");w=w.replace(/ \|/g,"|");return w};
je.D5=function(w){var n=je.VE;if(w>n.getParameter(n.MAX_TEXTURE_SIZE)){je.YG=!1;alert("Disabling WebGL")}};
je.Og=function(w,n){return new Float32Array([(w.x-n.x)/n.m,(w.y-n.y)/n.n,w.m/n.m,w.n/n.n])};je.Om=function(){return this.T};
je.t5=function(w,n){var W=je.VE;W.bindFramebuffer(W.FRAMEBUFFER,je.vc);W.framebufferTexture2D(W.FRAMEBUFFER,W.COLOR_ATTACHMENT0,W.TEXTURE_2D,w.LJ,0);
W.viewport(0,0,w.m,w.n);if(n){W.enable(W.SCISSOR_TEST);W.scissor(n.x,n.y,n.m,n.n)}else W.disable(W.SCISSOR_TEST)};
je.GU=function(w,n,W){if(W)throw"error";var D=je.VE;D.disable(D.SCISSOR_TEST);D.bindFramebuffer(D.FRAMEBUFFER,null);
D.viewport(0,0,w,n);if(W){D.enable(D.SCISSOR_TEST);D.scissor(W.x,W.y,Math.round(W.m),Math.round(W.n))}else D.disable(D.SCISSOR_TEST)};
je.clear=function(){var w=je.VE;w.clearColor(0,0,0,0);w.clear(w.COLOR_BUFFER_BIT)};je.oT=function(w,n){if(n==null)n=0;
var W=(n>>>0&255)==0,D=(n>>>8&255)==0,j=(n>>>16&255)==0,I=(n>>>24&255)==0,U=(w>>>0&255)*(1/255),M=(w>>>8&255)*(1/255),m=(w>>>16&255)*(1/255),l=(w>>>24&255)*(1/255),A=je.VE;
A.colorMask(W,D,j,I);A.clearColor(U,M,m,l);A.clear(A.COLOR_BUFFER_BIT);A.colorMask(!0,!0,!0,!0)};je.Jx=function(w,n,W,D,j){var I=n.wU(D);
if(j)I=I.wU(j);if(I.VY())return;var U=je.VE;je.t5(w);U.bindTexture(U.TEXTURE_2D,W.LJ);U.copyTexSubImage2D(U.TEXTURE_2D,0,I.x-D.x,I.y-D.y,I.x-n.x,I.y-n.y,I.m,I.n)};
je.vL=function(L,w,n){var W=je._H[L];if(W==null||W.m!=w||W.n!=n){if(W)W.delete();W=new je.H0(w,n)}je._H[L]=W;
return W};je._H=[];je.in=function(){this.et=null;this.Eg=null};je.in.jf=null;je.in.prototype.f2=function(w){if(this.Eg)return;
this.Eg={};var n=je.VE,W=this.et,D=this.Eg;for(var L=0;L<w.length;L++){var j=w[L];D[j]=n.getUniformLocation(W,j)}};
je.in.prototype.xC=function(){};je.in.prototype.YJ=function(w){var n=je.VE;for(var L=0;L<w.length;L+=2){n.uniform1i(w[L],L>>>1);
n.activeTexture(n["TEXTURE"+(L>>>1)]);n.bindTexture(n.TEXTURE_2D,w[L+1])}n.activeTexture(n.TEXTURE0)};
je.in.prototype.sk=function(w,n){var W=je.VE,D=W.createShader(W.FRAGMENT_SHADER);W.shaderSource(D,w);
W.compileShader(D);if(!W.getShaderParameter(D,W.COMPILE_STATUS))console.log(W.getShaderInfoLog(D));var j=W.createShader(W.VERTEX_SHADER);
W.shaderSource(j,n);W.compileShader(j);if(!W.getShaderParameter(j,W.COMPILE_STATUS))console.log(W.getShaderInfoLog(j));
var I=W.createProgram();W.attachShader(I,j);W.attachShader(I,D);W.linkProgram(I);if(!W.getProgramParameter(I,W.LINK_STATUS))console.log("Could not initialise shaders");
this.et=I};je.in.prototype.FO=function(){if(je.in.jf!=this){je.VE.useProgram(this.et);je.in.jf=this}};
je.dt=function(w,n){je.l6++;je.fC+=w*n;if(je.hi)console.log("GL.Channels instances: "+je.l6+", memory: "+je.fC);
var W=je.VE;this.m=w;this.n=n;this.LJ=W.createTexture();this.Ef=null;this.Cn(this.LJ,w,n)};je.dt.prototype.Cn=function(w,n,W){var D=je.VE;
D.bindTexture(D.TEXTURE_2D,w);D.texParameteri(D.TEXTURE_2D,D.TEXTURE_MIN_FILTER,D.NEAREST);D.texParameteri(D.TEXTURE_2D,D.TEXTURE_MAG_FILTER,D.NEAREST);
D.texParameteri(D.TEXTURE_2D,D.TEXTURE_WRAP_S,D.CLAMP_TO_EDGE);D.texParameteri(D.TEXTURE_2D,D.TEXTURE_WRAP_T,D.CLAMP_TO_EDGE);
D.texImage2D(D.TEXTURE_2D,0,D.ALPHA,n,W,0,D.ALPHA,D.UNSIGNED_BYTE,null)};je.dt.prototype.set=function(w,n){var W=je.VE;
W.bindTexture(W.TEXTURE_2D,this.LJ);W.pixelStorei(W.UNPACK_ALIGNMENT,1);var D=this.m*this.n;if(n==null||n.O()*10>D)W.texImage2D(W.TEXTURE_2D,0,W.ALPHA,this.m,this.n,0,W.ALPHA,W.UNSIGNED_BYTE,w);
else{var j=new iB(0,0,this.m,this.n),I=E.Q(n.O());E.B0(w,j,I,n);W.texSubImage2D(W.TEXTURE_2D,0,n.x,n.y,n.m,n.n,W.ALPHA,W.UNSIGNED_BYTE,I)}W.pixelStorei(W.UNPACK_ALIGNMENT,4)};
je.dt.prototype.delete=function(){var w=je.VE;if(this.LJ){w.deleteTexture(this.LJ);je.l6--;je.fC-=this.m*this.n}if(je.hi)if(je.hi)console.log("GL.Channels instances: "+je.l6+", memory: "+je.fC*4)};
je.l6=0;je.H0=function(w,n,W){if(W==null)W=!1;je.l6++;je.fC+=w*n*4;if(je.hi)console.log("GL.Channels instances: "+je.l6+", memory: "+je.fC);
var D=je.VE;this.a7o=W;this.m=w;this.n=n;this.LJ=D.createTexture();this.Ef=null;this.Cn(this.LJ,w,n)};
je.H0.prototype.set=function(w,n){var W=je.VE;W.disable(W.SCISSOR_TEST);W.bindTexture(W.TEXTURE_2D,this.LJ);
if(w==null||w instanceof Uint8Array){var D=this.m*this.n;if(n==null||n.O()*10>D)W.texImage2D(W.TEXTURE_2D,0,W.RGBA,this.m,this.n,0,W.RGBA,W.UNSIGNED_BYTE,w);
else{var j=E.Q(n.O()*4);E.Cb(w,new iB(0,0,this.m,this.n),j,n);W.texSubImage2D(W.TEXTURE_2D,0,n.x,n.y,n.m,n.n,W.RGBA,W.UNSIGNED_BYTE,j)}}else W.texImage2D(W.TEXTURE_2D,0,W.RGBA,W.RGBA,W.UNSIGNED_BYTE,w)};
je.H0.prototype.get=function(w){var n=je.VE;je.t5(this);n.readPixels(0,0,this.m,this.n,n.RGBA,n.UNSIGNED_BYTE,w)};
je.H0.prototype.Le=function(w){if(w.VY())return;var n=je.VE;if(this.Ef==null){this.Ef=n.createTexture();
this.Cn(this.Ef,this.m,this.n);je.l6++;je.fC+=this.m*this.n*4}n.bindFramebuffer(n.FRAMEBUFFER,je.vc);
n.bindTexture(n.TEXTURE_2D,this.Ef);if(w){var W=Math.max(w.x,0),D=Math.max(w.y,0);n.copyTexSubImage2D(n.TEXTURE_2D,0,W,D,W,D,w.m,w.n)}else n.copyTexImage2D(n.TEXTURE_2D,0,n.RGBA,0,0,this.m,this.n,0)};
je.H0.prototype.Cn=function(w,n,W){var D=je.VE;D.bindTexture(D.TEXTURE_2D,w);D.texParameteri(D.TEXTURE_2D,D.TEXTURE_MIN_FILTER,this.a7o?D.LINEAR:D.NEAREST);
D.texParameteri(D.TEXTURE_2D,D.TEXTURE_MAG_FILTER,D.NEAREST);D.texParameteri(D.TEXTURE_2D,D.TEXTURE_WRAP_S,D.CLAMP_TO_EDGE);
D.texParameteri(D.TEXTURE_2D,D.TEXTURE_WRAP_T,D.CLAMP_TO_EDGE);D.texImage2D(D.TEXTURE_2D,0,D.RGBA,n,W,0,D.RGBA,D.UNSIGNED_BYTE,null)};
je.H0.prototype.delete=function(){var w=je.VE;if(this.LJ){w.deleteTexture(this.LJ);je.l6--;je.fC-=this.m*this.n*4}if(this.Ef){w.deleteTexture(this.Ef);
je.l6--;je.fC-=this.m*this.n*4}if(je.hi)if(je.hi)console.log("GL.Channels instances: "+je.l6+", memory: "+je.fC)};
je.H0.prototype.clone=function(){var w=je.VE,n=new je.H0(this.m,this.n);je.t5(this);w.bindTexture(w.TEXTURE_2D,n.LJ);
w.copyTexImage2D(w.TEXTURE_2D,0,w.RGBA,0,0,this.m,this.n,0);return n};je.SW={axr:" vec3 ocbrn(vec3 a, vec3 b, float f) { vec3 d = (a*vec3(f)+ONE3-vec3(f)); return mix(ONE3 - min(ONE3,(ONE3-b)/d), ZERO3, vec3(vec3(greaterThan(vec3(0.001),d))) ); } ",ah9:" vec3 ocddg(vec3 a, vec3 b, float f) { return mix( min(ONE3, b/(ONE3 - a*f)) , ONE3 , vec3(equal(a*f,ONE3 )) ); } ",Fp:"const vec3 ZERO3 = vec3(0.0,0.0,0.0) ;\t\t\tconst vec3 QUAR3 = vec3(0.25,0.25,0.25) ;\t\t\tconst vec3 HALF3 = vec3(0.5,0.5,0.5) ;\t\t\tconst vec3 ONE3 = vec3(1.0,1.0,1.0) ;",oC:" float hueDiff(float shue, float hue) { \t\t\t\tfloat df = hue-shue, adf=abs(df), df0 = df-1.0, df1 = df+1.0; \t\t\t\tif(abs(df0) < adf) df = df0; \t\t\t\telse if(abs(df1) < adf) df = df1; \t\t\t\treturn df; \t\t\t}",Dq:" float hueCF(float hueS, float hue0) { \t\t\t\tfloat df = hueDiff(hue0, hueS)*6.0; \t\t\t\treturn max(0.0, min(1.0, (df<0.0) ? 1.0+df : 1.0-df )); } ",Wl:"float sat(vec3 c) { return max(c.x,max(c.y,c.z)) - min(c.x,min(c.y,c.z)); }",Mg:"float lum(vec3 c) { return dot(c, vec3(0.3,0.59,0.11)); } ",Rn:"vec3 D (vec3 x) { return mix( sqrt(x), ((16.0*x-12.0)*x+4.0)*x , vec3(lessThanEqual(x,QUAR3)) ); }",axM:"float midSat (vec3 v, float s) { return ((v.y-v.z)*s)/(v.x-v.z); }",mt:"vec3 setSat (vec3 c, float s) \t\t\t{\t\t\t\tvec3 o;\t\t\t\tif(c.r==c.g && c.g==c.b) o = ZERO3;\t\t\t\telse if(c.r>c.g) {\t\t\t\t\tif(c.r>c.b) {\t\t\t\t\t\tif(c.g>c.b)\to = vec3(s, midSat(c.rgb,s), 0.0); \t\t\t\t\t\telse\to = vec3(s, 0.0, midSat(c.rbg,s)); \t\t\t\t\t}\t\t\t\t\telse\t\to = vec3(midSat(c.brg,s), 0.0, s); \t\t\t\t} else {\t\t\t\t\tif(c.r<c.b) {\t\t\t\t\t\tif(c.g>c.b)\to = vec3(0.0, s, midSat(c.gbr,s)); \t\t\t\t\t\telse\t o = vec3(0.0, midSat(c.bgr,s), s); \t\t\t\t\t}\t\t\t\t\telse\t\t o = vec3(midSat(c.grb,s), s, 0.0);\t\t\t\t}\t\t\t\treturn o;\t\t\t}",a3U:"vec3 clipCol(vec3 c) \t\t\t{ \t\t\t\tvec3 o = c; float l = lum(c); \t\t\t\tfloat n = min(c.r,min(c.g,c.b)); \t\t\t\tfloat x = max(c.r,max(c.g,c.b)); \t\t\t\tif(n<0.0) o = l + (o-l)*(l/(l-n));\t\t\t\tif(x>1.0) o = l + (o-l)*(1.0-l)/(x-l);\t\t\t\treturn o;\t\t\t}",TQ:"vec3 setLum (vec3 c, float l) { return clipCol(c+l-lum(c)); } ",v1:"bool in01(vec2 c) { return (0.0<=c.x) && (c.x<=1.0) && (0.0<=c.y) && (c.y<=1.0); }",hash:"float hash(vec2 v) { return fract(sin(dot(v ,vec2(12.9898,78.233))) * 43758.5453); }",AO:"vec3 rgbToHsl (vec3 rgb) {\t\t\t\tfloat r = rgb.r, g = rgb.g, b = rgb.b; \t\t\t\tfloat mx = max(r, max(g, b)), mn = min(r, min(g, b)); \t\t\t\tfloat h, s, l = (mx + mn) * 0.5;\t\t\t\t\t\t\t\tif(mx == mn) h = s = 0.0; \t\t\t\telse{ \t\t\t\t\tfloat d = mx - mn; \t\t\t\t\ts = l > 0.5 ? d / (2.0 - mx - mn) : d / (mx + mn); \t\t\t\t\t\t\t\t\t\tif(mx==r) h = (g - b) / d + (g < b ? 6.0 : 0.0); \t\t\t\t\telse if(mx==g) h = (b - r) / d + 2.0; \t\t\t\t\telse if(mx==b) h = (r - g) / d + 4.0; \t\t\t\t\t\t\t\t\t\th /= 6.0; \t\t\t\t} \t\t\t\treturn vec3(h,s,l); }",P4:"vec3 hslToRgb (float h, float s, float l){\t\t\t\tfloat r, g, b;\t\t\t\t\t\t\t\tif(s == 0.0) r = g = b = l; \t\t\t\telse{ \t\t\t\t\tfloat q = l < 0.5 ? l * (1.0 + s) : l + s - l * s; \t\t\t\t\tfloat p = 2.0 * l - q; \t\t\t\t\tr = hue2rgb(p, q, h + 1.0/3.0); \t\t\t\t\tg = hue2rgb(p, q, h); \t\t\t\t\tb = hue2rgb(p, q, h - 1.0/3.0); \t\t\t\t} \t\t\t\treturn vec3(r,g,b); } ",SA:"float hue2rgb(float p, float q, float t){ \t\t\t\tif(t < 0.0) t += 1.0;\t\t\t\tif(t > 1.0) t -= 1.0;\t\t\t\tif(t < 1.0/6.0) return p + (q - p) * 6.0 * t; \t\t\t\tif(t < 1.0/2.0) return q; \t\t\t\tif(t < 2.0/3.0) return p + (q - p) * (2.0/3.0 - t) * 6.0; \t\t\t\treturn p;\t}",i8:"vec3 rgbToHsv(vec3 rgb){\t\t\t\t\tfloat r = rgb.r, g = rgb.g, b = rgb.b; \t\t\t\tfloat mx = max(r, max(g, b)), mn = min(r, min(g, b)); \t\t\t\tfloat h, s, v = mx; \t\t\t\t\t\t\t\tfloat d = mx - mn; \t\t\t\ts = mx == 0.0 ? 0.0 : d / mx; \t\t\t\t\t\t\t\tif(mx == mn) h = 0.0; \t\t\t\telse if(mx==r) h = (g - b) / d + (g < b ? 6.0 : 0.0); \t\t\t\telse if(mx==g) h = (b - r) / d + 2.0; \t\t\t\telse if(mx==b) h = (r - g) / d + 4.0; \t\t\t\t\t\t\t\th /= 6.0; \t\t\t\treturn vec3(h,s,v); }",li:"vec3 hsvToRgb(float h, float s, float v) { \t\t\t\tfloat r, g, b, f, p, q, t, i; \t\t\t\ti = floor(h * 6.0); \t\t\t\tf = h * 6.0 - i; \t\t\t\tp = v * (1.0 - s); \t\t\t\tq = v * (1.0 - f * s); \t\t\t\tt = v * (1.0 - (1.0 - f) * s); \t\t\t\t\t\t\t\tif (i==0.0) { r = v, g = t, b = p; }\t\t\t\telse if(i==1.0) { r = q, g = v, b = p; }\t\t\t\telse if(i==2.0) { r = p, g = v, b = t; }\t\t\t\telse if(i==3.0) { r = p, g = q, b = v; }\t\t\t\telse if(i==4.0) { r = t, g = p, b = v; }\t\t\t\telse if(i==5.0) { r = v, g = p, b = q; }\t\t\t\t\t\t\t\treturn vec3(r,g,b); }",gK:"\t\tfloat srgbUngamma(float x) {\t\t\treturn (x<0.04045) ? (x / 12.92) : pow( ( x + 0.055 ) / 1.055, 2.4);\t\t}\t\tfloat xyzScale(float x) {\t\t\treturn (x>0.008856) ? pow(x,1.0/3.0) : (903.3*x+16.0)*(1.0/116.0); \t\t}\t\tvec3 rgbToLab(vec3 rgb) {\t\t\tbool ok = true;\t\t\trgb.r = srgbUngamma(rgb.r); \t\t\trgb.g = srgbUngamma(rgb.g); \t\t\trgb.b = srgbUngamma(rgb.b); \t\t\tok = ok && 0.0318<=rgb.r && rgb.r<=0.0319; \t\t\tok = ok && 0.127 <=rgb.g && rgb.g<=0.128 ; \t\t\tok = ok && 0.3047<=rgb.b && rgb.b<=0.305; \t\t\t\t\t\tmat3 srgb2xyz = mat3(0.4360747164307918, 0.222504478679176, 0.013932173981751634, 0.3850649153329662, 0.7168786002139355, 0.09710452396580642, 0.14308038098632878, 0.06061692340677909, 0.7141732835334675); \t\t\t\t\t\tvec3 xyz = srgb2xyz*rgb; \t\t\tok = ok && 0.106<=xyz[0] && xyz[0]<=0.107; \t\t\t\t\t\txyz=xyz*vec3(100.0/96.72, 100.0/100.0, 100.0/81.427); \t\t\txyz.x = xyzScale(xyz.x); \t\t\txyz.y = xyzScale(xyz.y); \t\t\txyz.z = xyzScale(xyz.z); \t\t\t\t\t\treturn vec3(116.0*xyz.y-16.0, 500.0*(xyz.x-xyz.y), 200.0*(xyz.y-xyz.z)); \t\t} \t\tfloat labSimilar(vec3 lab, vec3 mnm, vec3 mxm, float lim) {\t\t\tfloat L=lab.x, a=lab.y, b=lab.z; \t\t\tfloat dl = ((L<mnm.x) ? (mnm.x-L) : ((mxm.x<L) ? (mxm.x-L) : 0.0))*(1.0/100.0); \t\t\tfloat da = ((a<mnm.y) ? (mnm.y-a) : ((mxm.y<a) ? (mxm.y-a) : 0.0))*(1.0/116.0); \t\t\tfloat db = ((b<mnm.z) ? (mnm.z-b) : ((mxm.z<b) ? (mxm.z-b) : 0.0))*(1.0/116.0); \t\t\t/*float dl = (slab.x-lab.x)*(1.0/100.0), da=(slab.y-lab.y)*(1.0/116.0), db=(slab.z-lab.z)*(1.0/116.0);*/ \t\t\tfloat dst = sqrt(dl*dl+da*da+db*db)*1.35; \t\t\treturn (dst<=lim) ? min(1.0,1.17*(1.0 - (dst/lim))) : 0.0; \t\t}",ap4:" mat3 rgbToYuv = mat3(0.299, -0.147, 0.615, 0.587, -0.289, -0.515, 0.114, 0.436, -0.100 ); ",asb:" mat3 yuvToRgb = mat3(1.0, 1.0, 1.0, 0.0, -0.3946, 2.03199, 1.1398, -0.5805, -0.00048 ); ",dW:"\t\tfloat _blendIf(float c, vec4 br) { return min((c-br.x)*br.y, (c-br.w)*br.z); } \t\tfloat blendIf(vec4 sc, vec4 tc, vec4 br[10]) { \t\t\tfloat sg = lum(sc.rgb); \t\t\tfloat tg = lum(tc.rgb); \t\t\tfloat ms = _blendIf(sg,br[0]); \t\t\tms = min(ms, _blendIf(sc.r,br[2])); \t\t\tms = min(ms, _blendIf(sc.g,br[4])); \t\t\tms = min(ms, _blendIf(sc.b,br[6])); \t\t\t\t\t\tfloat mt = _blendIf(tg,br[1]); \t\t\tmt = min(mt, _blendIf(tc.r,br[3])); \t\t\tmt = min(mt, _blendIf(tc.g,br[5])); \t\t\tmt = min(mt, _blendIf(tc.b,br[7])); \t\t\tmt=max(mt,1.0-tc.w);\t\t\t\t\t\tfloat mi=min(ms,mt);\t\t\treturn clamp(mi,0.0,1.0);\t\t}",tC:"\t\t\tvec4 mapLut(vec4 src, sampler2D lut, float N) {\t\t\t\tfloat iN = 1.0/N; \t\t\t\tfloat fb = 0.5*iN + src.b*(1.0-iN); \t\t\t\tfloat fg = 0.5*iN + src.g*(1.0-iN); \t\t\t\tfloat R = src.r*(N-1.0)*0.999999; \t\t\t\tfloat ir = floor(R)*iN; \t\t\t\t\t\t\t\tvec4 c0 = texture2D(lut, vec2(fb, ir +( fg )*iN)); \t\t\t\tvec4 c1 = texture2D(lut, vec2(fb, ir+iN+( fg )*iN)); \t\t\t\tvec4 rs = mix(c0,c1,R-floor(R)); \t\t\t\treturn rs; \t\t\t}"};
je.s={};je.s.TX={};je.s.SK=null;je.s.uG=null;je.s.tA=null;je.s.Q7=function(w,n,W,D,j,I,U,M){if(M==null)M=ge.cT();
if("idiv,lbrn,div ,lddg,vLit,lLit,hMix,diff".split(",").indexOf(w)==-1){U=U*M.fill;M.fill=1;M.style=!1}var m=w+(M.vn?"1":"");
if(je.s.TX[m]==null)je.s.TX[m]=new je.s.Vh(w,M.vn!=null);var l=je.s.TX[m],A=W.wU(j).wU(I);A.offset(-j.x,-j.y);
if(A.VY())return;var g=je.VE;je.t5(D,A);D.Le(A);l.FO();l.xC(n.LJ,D.Ef,je.Og(W,j),U,M.fill,M.style?1:0,M.MY?1:0,M.vn?new Float32Array(M.vn):null);
g.drawArrays(g.TRIANGLES,0,6)};je.s.mT=function(w,n,W,D,j,I,U,M,m,l,A){if(je.s.SK==null)je.s.SK=new je.s.Aw(!0,!0);
if(je.s.uG==null)je.s.uG=new je.s.Aw(!0,!1);if(je.s.tA==null)je.s.tA=new je.s.Aw(!1,!0);var g=l?1:0,k=w?j?je.s.SK:je.s.uG:je.s.tA,$=new Float32Array(A?[A[0],A[1],A[2],1]:[1,1,1,1]),C=n?n.wU(D).wU(M):D.wU(M);
if(C.VY())return;C.offset(-D.x,-D.y);var f=je.VE;je.t5(W,C);W.Le(C);k.FO();if(w==null)k.xC(null,W.Ef,j.LJ,je.Og(D,D),je.Og(I,D),U/255,m,g,$);
else if(j)k.xC(w.LJ,W.Ef,j.LJ,je.Og(n,D),je.Og(I,D),U/255,m,g,$);else k.xC(w.LJ,W.Ef,null,je.Og(n,D),null,U/255,m,g,$);
f.drawArrays(f.TRIANGLES,0,6)};je.s.ahj=function(w,n,W){if(je.s.aoN==null)je.s.aoN=new je.s.sK;var D=je.s.aoN,j=new iB(0,0,w.m,w.n),I=je.VE;
je.t5(n);n.Le(j);D.FO();D.xC(j,w.LJ,n.Ef,W.LJ);I.drawArrays(I.TRIANGLES,0,6)};je.s.aM={norm:"return a;",diss:"return a;",dark:"return min(a,b);","mul ":"return a*b;",idiv:" vec3 d = (a*vec3(f)+ONE3-vec3(f)); return mix(mix(ONE3-((ONE3-b)/max(d,vec3(1e-6))), ZERO3, vec3(greaterThanEqual(ONE3-b,d)) ), ONE3 , vec3(equal(b,ONE3) )); ",lbrn:"return max(ZERO3, a*f+b-f);",dkCl:"return ( lum(a)<lum(b) ? a : b );",lite:"return max(a,b);",scrn:"return b+a-b*a;","div ":"a*=f; return mix( mix( min(ONE3,b/(1.0-a)), ONE3, step(1.0-a, b)) , ZERO3, vec3(equal(b,ZERO3)) );",lddg:"a*=f; return min(ONE3,a+b);",lgCl:"return ( lum(a)>lum(b) ? a : b );",over:"return mix( a+(2.0*b -1.0)-a*(2.0*b-1.0) , 2.0*b*a , step(-HALF3,-b) );",sLit:"return mix( b+(2.0*a -1.0)*(D(b)-b) , b-(1.0-2.0*a)*b*(1.0-b) , step(-HALF3,-a) );",hLit:"return mix( b+(2.0*a -1.0)-b*(2.0*a-1.0) , 2.0*a*b , step(-HALF3,-a) );",vLit:" return mix( ocddg(2.0*a-1.0,b,f) , ocbrn(2.0*a,b,f) , vec3(greaterThanEqual(HALF3,a))); ",lLit:"return mix( min(ONE3, (2.0*a-1.0)*f+b) , max(ZERO3, 2.0*a*f+b-f) , step(-HALF3,-a));",pLit:"return mix( max(2.0*a-1.0,b) , min(2.0*a, b) , step(-HALF3,-a) );",hMix:"if(f>0.99) return vec3(greaterThanEqual(a+b,ONE3)); return min( ONE3, max(ZERO3, (b+a*f-f)/(1.0-f+1e-6) )) ; ",diff:"return abs(a*f-b);",smud:"return a+b-2.0*a*b;",fsub:"return max(b-a, ZERO3);",fdiv:"return min(b/a, ONE3);","hue ":"return setLum( setSat(a, sat(b)) , lum(b) ); ","sat ":"return setLum( setSat(b, sat(a)) , lum(b) ); ",colr:"return setLum( a, lum(b) ); ","lum ":"return setLum( b, lum(a) ); "};
je.s.Vh=function(w,n){je.in.call(this);var W="\t\t\tprecision highp float;\t\t\t"+je.SW.Fp+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform sampler2D target;\t\t\tuniform float alpha;\t\t\tuniform float fill;\t\t\tuniform float style;\t\t\tuniform float keepBGA;\t\t\t"+(n?"uniform vec4 blIf[10];":"")+"\t\t\t\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\t\t\t\t\t\t\t"+je.SW.Wl+"\t\t\t"+je.SW.Mg+"\t\t\t"+je.SW.Rn+"\t\t\t"+je.SW.axr+"\t\t\t"+je.SW.ah9+"\t\t\t"+je.SW.axM+"\t\t\t"+je.SW.mt+"\t\t\t"+je.SW.a3U+"\t\t\t"+je.SW.TQ+"\t\t\t"+je.SW.hash+"\t\t\t"+(n?je.SW.dW:"")+"\t\t\t\t\t\tvec3 BB(vec3 a, vec3 b, float f) { "+je.s.aM[w]+" } \t\t\t\t\t\tvoid main(void) {\t\t\t\tvec4 tgt = texture2D(target, tCoord);\t\t\t\tvec4 src = texture2D(source, sCoord);",D="\t\t\tattribute vec2 verPos;\t\t\tuniform vec4 srct;\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\tvoid main(void) {\t\t\t\ttCoord = verPos;\t\t\t\tsCoord = (verPos-srct.xy)/srct.zw;\t\t\t\tgl_Position = vec4(vec2(-1.0,-1.0) + 2.0*verPos, 0.0, 1.0);\t\t\t}";
if(w=="diss")W+="\t\t\t\t\tgl_FragColor = (hash(tCoord) >= (keepBGA + (1.0-keepBGA)*src.w)*alpha ? tgt : vec4(src.xyz, keepBGA*tgt.w + (1.0-keepBGA))); }";
else W+=" \t\t\t\t\tfloat as = (keepBGA + (1.0-keepBGA)*src.w) * alpha, at = keepBGA + (1.0-keepBGA)*tgt.w; \t\t\t\t\t"+(n?" as*=blendIf(src,tgt,blIf); ":"")+"\t\t\t\t\tfloat ats = at * (1.0-as), ao = as + ats, iao = (ao==0.0) ? 0.0 : (1.0/ao); \t\t\t\t\tfloat ccf = (style==1.0) ? 1.0 : as; \t\t\t\t\tvec3 ncl = ( (1.0-at)*as*src.xyz + (1.0-ccf)*at*tgt.xyz + ccf*at*BB(src.xyz, tgt.xyz, (1.0+as-ccf)*fill) ) * iao;\t\t\t\t\tgl_FragColor = vec4(ncl, keepBGA*tgt.w + (1.0-keepBGA)*(as*fill + at*(1.0-as*fill)));\t\t\t\t\t\t\t}";
this.sk(W,D)};je.s.Vh.prototype=new je.in;je.s.Vh.prototype.xC=function(w,n,W,D,j,I,U,M){this.f2("srct alpha source target fill style keepBGA blIf".split(" "));
var m=je.VE,l=this.Eg;m.uniform4fv(l.srct,W);m.uniform1f(l.alpha,D);m.uniform1f(l.fill,j);m.uniform1f(l.style,I);
m.uniform1f(l.keepBGA,U);if(M)m.uniform4fv(l.blIf,M);this.YJ([l.source,w,l.target,n])};je.s.Aw=function(w,n){je.in.call(this);
this.a89=w;this.qU=n;var W="\t\t\tprecision mediump float;\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform sampler2D target;\t\t\tuniform sampler2D weight;\t\t\tuniform vec4 cswitch;\t\t\tuniform float wcolor;\t\t\tuniform float awg; /* additional weight */\t\t\tuniform float dissv;\t\t\t\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\tvarying vec2 wCoord;\t\t\t\t\t\t"+je.SW.v1+"\t\t\t"+je.SW.hash+"\t\t\t\t\t\tvoid main(void) {\t\t\t\tvec4 tgt = texture2D(target, tCoord);\t\t\t\tvec4 src = "+(w?"texture2D(source, sCoord)":"vec4(0.0)")+"; \t\t\t\tfloat wg = awg "+(n?"* (in01(wCoord) ? texture2D(weight, wCoord).w : wcolor)":"")+";\t\t\t\t"+(w?"":"wg = 1.0-wg;")+"\t\t\t\tfloat hwg = hash(tCoord)>=wg ? 0.0 : 1.0; wg = dissv*hwg + (1.0-dissv)*wg; \t\t\t\tfloat as = wg*src.w, at = (1.0-wg)*tgt.w, ao = as+at;\t\t\t\t\t\t\t\tvec4 nc = vec4( (as*src.xyz + at*tgt.xyz)/ao, ao ); \t\t\t\tgl_FragColor = "+(n?"nc":"cswitch*nc + (1.0- cswitch)*tgt")+"; \t\t\t}",D="\t\t\tattribute vec2 verPos;\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\tvarying vec2 wCoord;\t\t\t\t\t\tuniform vec4 srct;\t\t\tuniform vec4 wrct;\t\t\tvoid main(void) {\t\t\t\ttCoord = verPos;\t\t\t\tsCoord = (verPos-srct.xy)/srct.zw;\t\t\t\twCoord = (verPos-wrct.xy)/wrct.zw;\t\t\t\tgl_Position = vec4(vec2(-1.0,-1.0) + 2.0*verPos, 0.0, 1.0);\t\t\t}";
this.sk(W,D)};je.s.Aw.prototype=new je.in;je.s.Aw.prototype.xC=function(w,n,W,D,j,I,U,M,m){if(this.qU)this.f2("srct wrct wcolor awg dissv source target weight cswitch".split(" "));
else this.f2("srct awg dissv source target cswitch".split(" "));var l=je.VE,A=this.Eg;l.uniform4fv(A.srct,D);
if(this.qU){l.uniform4fv(A.wrct,j);l.uniform1f(A.wcolor,I)}else{l.uniform4fv(A.cswitch,m)}l.uniform1f(A.awg,U);
l.uniform1f(A.dissv,M);var g=[A.source,w,A.target,n];if(this.qU)g.push(A.weight,W);this.YJ(g)};je.s.sK=function(){je.in.call(this);
var w="\t\t\tprecision mediump float;\t\t\t\t\t\tuniform sampler2D prev;\t\t\tuniform sampler2D next;\t\t\tuniform sampler2D alpha;\t\t\t\t\t\tvarying vec2 coord;\t\t\t\t\t\t\t\t\tvoid main(void) {\t\t\t\tvec3 or = texture2D(prev , coord).rgb;\t\t\t\tvec3 ir = texture2D(next , coord).rgb; \t\t\t\tfloat al = texture2D(alpha, coord).w; \t\t\t\tgl_FragColor = vec4( (ir-(1.0-al)*or)*(1.0/al) ,1.0 ); \t\t\t}",n="\t\t\tattribute vec2 verPos;\t\t\tvarying vec2 coord;\t\t\t\t\t\tuniform vec4 rct;\t\t\tvoid main(void) {\t\t\t\tcoord = verPos;\t\t\t\tgl_Position = vec4(vec2(-1.0,-1.0) + 2.0*verPos, 0.0, 1.0);\t\t\t}";
this.sk(w,n)};je.s.sK.prototype=new je.in;je.s.sK.prototype.xC=function(w,n,W,D){this.f2(["rct","prev","next","alpha"]);
var j=je.VE,I=this.Eg;j.uniform4fv(I.rct,[0,0,1,1]);this.YJ([I.prev,n,I.next,W,I.alpha,D])};je.u4={Ja:{},qP:"\t\t\tattribute vec2 verPos;\t\t\tvarying vec2 sCoord;\t\t\tvoid main(void) {\t\t\t\tsCoord = verPos;\t\t\t\tgl_Position = vec4(vec2(-1.0,-1.0) + 2.0*verPos, 0.0, 1.0);\t\t\t}"};
je.u4.zj=function(w,n){var W=eH.$V,D=[W.Pq,W.yX,W.T0,W.TR,W.da,W.yO,W.mM,W.l0].indexOf(w.type),j=je.u4.Ja[w.type];
if(j==null)j=je.u4.Ja[w.type]=new je.Ja[D];j.FO();j.xC(n,w);je.VE.drawArrays(je.VE.TRIANGLES,0,6)};je.Ja=[];
je.Ja[0]=function(){je.in.call(this);this.S4={};var w="\t\t\tprecision mediump float;\t\t\t"+je.SW.Mg+"\t\t\t"+je.SW.Fp+"\t\t\tuniform sampler2D source;\t\t\tuniform sampler2D map;\t\t\tuniform float toGray;\t\t\tuniform float presLum;\t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) {\t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tfloat olum = lum(src.rgb); \t\t\t\tsrc.rgb = toGray * vec3(olum) + (1.0-toGray)*src.rgb; \t\t\t\tfloat r = texture2D(map, vec2(src.r, 0)).r;\t\t\t\tfloat g = texture2D(map, vec2(src.g, 0)).g;\t\t\t\tfloat b = texture2D(map, vec2(src.b, 0)).b;\t\t\t\tvec3 col = vec3(r,g,b); \t\t\t\tif(presLum==1.0) { \t\t\t\t\tfloat nlum = lum(col); \t\t\t\t\tif(olum>nlum) col += (olum-nlum)/(1.0-nlum)*(ONE3-col); \t\t\t\t\telse if(nlum==0.0) col = ZERO3; \t\t\t\t\telse col = (olum/nlum) * col; \t\t\t\t}\t\t\t\tgl_FragColor = vec4(col,src.w);\t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[0].prototype=new je.in;je.Ja[0].prototype.xC=function(w,n){var W={o:n.UX,B:n.D4,k:n.ZA,dl:E.Q(n.UX.length)},D=W.o.length;
if(this.S4["m"+D]==null){this.S4["m"+D]={a9d:new je.H0(D,1),Q0:E.Q(D*4)}}var j=this.S4["m"+D];E.kX(W,j.Q0,0);
var I=j.a9d;I.set(j.Q0);this.f2(["source","map","toGray","presLum"]);var U=je.VE,M=this.Eg;U.uniform1f(M.toGray,n.iA?1:0);
U.uniform1f(M.presLum,n.gd?1:0);this.YJ([M.source,w,M.map,I.LJ])};je.Ja[1]=function(){je.in.call(this);
this.ax2=new je.H0(256,1);this.arZ=E.Q(256*4);var w="\t\t\t\tprecision mediump float;\t\t\t\t"+je.SW.SA+"\t\t\t\t"+je.SW.AO+"\t\t\t\t"+je.SW.P4+"\t\t\t\t\t\t\t\tuniform sampler2D source;\t\t\t\tuniform sampler2D map;\t\t\t\tuniform float cfa; \t\t\t\tuniform float cfb; \t\t\t\tuniform int colorize; \t\t\t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\t\t\tvoid main(void) { \t\t\t\t\tvec4 src = texture2D(source, sCoord);\t\t\t\t\tvec3 rgb = src.rgb;\t\t\t\t\tfloat mn=min(rgb.r,min(rgb.g,rgb.b)), mx = max(rgb.r,max(rgb.g,rgb.b));\t\t\t\t\t\t\t\t\t\tvec3 hsl = rgbToHsl(rgb); \t\t\t\t\tfloat h = hsl.r, s = hsl.g, l = hsl.b; \t\t\t\t\t\t\t\t\t\tvec4 mapv = texture2D(map, vec2(h, 0));\t\t\t\t\tfloat nh = mapv.r; \t\t\t\t\tfloat sc = mapv.g*2.0-1.0; \t\t\t\t\tfloat lc = mapv.b*2.0-1.0; \t\t\t\t\t\t\t\t\t\tfloat cf = -lc, tv=mn;\t\t\t\t\tif(0.0<lc) { cf=lc; tv=mx; }\t\t\t\t\t\t\t\t\t\tfloat a0 = cfa + cfb*cf*tv, a1 = cfb*(1.0-cf);\t\t\t\t\trgb = a0 + a1 * rgb;\t\t\t\t\t\t\t\t\t\thsl = rgbToHsl(rgb); s = hsl.g; l = hsl.b; \t\t\t\t\tfloat ns = sc; \t\t\t\t\tif(colorize==0) {\t\t\t\t\t\tif(sc>0.0) sc = pow(tan((3.14159265359/2.0)*sc),1.3);\t\t\t\t\t\tns = min(s * (1.0 + sc), 1.0); \t\t\t\t\t} \t\t\t\t\t\t\t\t\t\tgl_FragColor = vec4(hslToRgb(nh,ns,l),src.w); \t\t\t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[1].prototype=new je.in;je.Ja[1].prototype.xC=function(w,n){E.kX({o:n.a3M,B:n.rl,k:n.az$,dl:E.Q(256)},this.arZ);
this.ax2.set(this.arZ);this.f2(["source","map","cfa","cfb","colorize"]);var W=je.VE,D=this.Eg;W.uniform1f(D.cfa,n.anD);
W.uniform1f(D.cfb,n.AZ);W.uniform1i(D.colorize,n.apK);this.YJ([D.source,w,D.map,this.ax2.LJ])};je.Ja[2]=function(){je.in.call(this);
var w="\t\t\tprecision mediump float;\t\t\t"+je.SW.SA+"\t\t\t"+je.SW.i8+"\t\t\t"+je.SW.li+"\t\t\t"+je.SW.AO+"\t\t\t"+je.SW.P4+"\t\t\t"+je.SW.ap4+"\t\t\t"+je.SW.asb+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform float vib; \t\t\tuniform float sat; \t\t\tuniform vec3 yF; \t\t\tconst float PI = 3.141592653; \t\t\t\t\t\tvarying vec2 sCoord;\t\t\tvec3 vibrate(vec3 rgb) { \t\t\t\tvec3 yuv = rgbToYuv * rgb; \t\t\t\treturn yuvToRgb * (yuv * yF); \t\t\t} \t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tvec3 rgb = src.rgb; \t\t\t\trgb = pow(rgb,vec3(2.4)); \t\t\t\t\t\t\t\trgb = clamp(vibrate(rgb), 0.0, 1.0); \t\t\t\t\t\t\t\trgb = pow(rgb,vec3(1.0/2.4)); \t\t\t\t\t\t\t\tvec3 hsl = rgbToHsl(rgb); \t\t\t\tfloat nsat = max(0.0, min(1.0, hsl.y*(1.0+sat))); \t\t\t\trgb = hslToRgb(hsl.x, nsat, hsl.z); \t\t\t\t\t\t\t\tgl_FragColor = vec4(rgb,src.w); \t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[2].prototype=new je.in;je.Ja[2].prototype.xC=function(w,n){this.f2(["source","vib","sat","yF"]);
var W=je.VE,D=this.Eg;W.uniform1f(D.vib,n.AH[0]);W.uniform1f(D.sat,n.AH[1]);W.uniform3fv(D.yF,new Float32Array([n.AH[2],n.AH[3],n.AH[3]]));
this.YJ([D.source,w])};je.Ja[3]=function(){je.in.call(this);var w="\t\t\tprecision mediump float;\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform mat4 trf; \t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tvec4 nsr = vec4(src.rgb,1.0); \t\t\t\tgl_FragColor = vec4((trf*nsr).rgb,src.w); \t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[3].prototype=new je.in;je.Ja[3].prototype.xC=function(w,n){this.f2(["source","trf"]);
var W=je.VE,D=this.Eg;W.uniformMatrix4fv(D.trf,!1,new Float32Array(E.Mv.nJ(n.GY)));this.YJ([D.source,w])};
je.Ja[4]=function(){je.in.call(this);var w="\t\t\tprecision mediump float; \t\t\t"+je.SW.gK+"\t\t\t"+je.SW.SA+"\t\t\t"+je.SW.P4+"\t\t\t"+je.SW.AO+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform vec3 mnm;\t \t\t\tuniform vec3 mxm;\t \t\t\tuniform vec3 shift; \t\t\tuniform float lim; \t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\t\t\t\t\tvec3 lab = rgbToLab(src.rgb);\t\t\t\tfloat scl = labSimilar(lab, mnm,mxm, lim);\t\t\t\t\t\t\t\tvec3 hsv = rgbToHsl(src.rgb); \t\t\t\tfloat nh = 2.0 + hsv[0]+shift[0]; \t\t\t\thsv[0] = fract(nh); \t\t\t\thsv[1] = max(0.0, min(1.0, hsv[1] + shift[1])); \t\t\t\thsv[2] = max(0.0, min(1.0, hsv[2] + shift[2])); \t\t\t\t\t\t\t\tvec3 rgb = hslToRgb(hsv[0], hsv[1], hsv[2]); \t\t\t\t\t\t\t\tgl_FragColor = vec4(mix(src.rgb,rgb,scl),src.w); \t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[4].prototype=new je.in;je.Ja[4].prototype.xC=function(w,n){this.f2(["source","mnm","mxm","shift","lim"]);
var W=je.VE,D=this.Eg;W.uniform3fv(D.mnm,new Float32Array(n.x8));W.uniform3fv(D.mxm,new Float32Array(n.wI));
W.uniform3fv(D.shift,new Float32Array(n.shift));W.uniform1f(D.lim,n.$e);this.YJ([D.source,w])};je.Ja[5]=function(){je.in.call(this);
var w="\t\t\tprecision mediump float;\t\t\t"+je.SW.Fp+"\t\t\t"+je.SW.oC+"\t\t\t"+je.SW.Dq+"\t\t\t"+je.SW.AO+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform vec3 cfs[18]; \t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tvec3 rgb = src.rgb; \t\t\t\tvec3 hsl = rgbToHsl(rgb); \t\t\t\tfloat mx = max(rgb.r, max(rgb.g, rgb.b)); \t\t\t\tfloat mn = min(rgb.r, min(rgb.g, rgb.b)); \t\t\t\t\t\t\t\tvec3 CMY = ONE3 - rgb; \t\t\t\tvec3 d = ZERO3; \t\t\t\t\t\t\t\tfor(int j=0; j<9; j++) \t\t\t\t{ \t\t\t\t vec3 NCMY = CMY * cfs[j+j] + cfs[j+j+1]; \t\t\t\t\t\t\t\t\t\tfloat cfK = 0.0;\t\t\t\t\tif (j< 6) { \t\t\t\t\t\tcfK = hueCF(float(j)*(1.0/6.0), hsl.x); \t\t\t\t\t\tcfK = cfK * hsl.y * 2.0*min(hsl.z, 1.0-hsl.z); \t\t\t\t\t} \t\t\t\t\telse if(j==6) cfK = max(0.0,mn-0.5)*2.0;\t\t\t\t\telse if(j==7) cfK = 1.0-(abs(mx-0.5)+abs(mn-0.5));\t\t\t\t\telse cfK = max(0.0,0.5-mx)*2.0;\t\t\t\t\t\t\t\t\t\td += (max(ZERO3, min(ONE3, NCMY))-CMY)*cfK; \t\t\t\t} \t\t\t\t\t\t\t\tCMY = max(ZERO3, min(ONE3, CMY+d)); \t\t\t\trgb = ONE3 - CMY; \t\t\t\t\t\t\t\tgl_FragColor = vec4(rgb,src.w); \t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[5].prototype=new je.in;je.Ja[5].prototype.xC=function(w,n){this.f2(["source","cfs"]);
var W=je.VE,D=this.Eg;W.uniform3fv(D.cfs,n.a7g);this.YJ([D.source,w])};je.Ja[6]=function(){je.in.call(this);
var w="\t\t\tprecision mediump float;\t\t\t"+je.SW.SA+"\t\t\t"+je.SW.oC+"\t\t\t"+je.SW.Dq+"\t\t\t"+je.SW.AO+"\t\t\t"+je.SW.P4+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform float wght[6]; \t\t\tuniform float prms[6]; \t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tvec3 rgb = src.rgb; \t\t\t\t\t\t\t\tfloat tint=prms[0], hue=prms[1], lum=prms[2], mcf=prms[3], x0=prms[4], x1=prms[5]; \t\t\t\tvec3 hsl = rgbToHsl(rgb); \t\t\t\t\t\t\t\tfloat cf = 0.0;\t\t\t\tfor(int j=0; j<6; j++) cf += min(1.0, 1.7*(1.0-hsl.z)) * hsl.y * wght[j] * hueCF(hsl.x, float(j)*(1.0/6.0));\t\t\t\t\t\t\t\tfloat lig = max(0.0, min(1.0, hsl.z*(1.0+cf)));\t\t\t\tif(tint==1.0) { \t\t\t\t\tfloat totl = 0.0;\t\t\t\t\tif (lig<x0) totl = lig*(0.5/lum); \t\t\t\t\telse if(lig<x1) totl = lig + (mcf)*(0.5 - lum); \t\t\t\t\telse totl = 1.0 - (1.0-lig)*0.5/(1.0-lum); \t\t\t\t\t\t\t\t\t\thsl.x = hue; \t\t\t\t\thsl.y = min(1.0, mcf + 3.0*mcf*abs(lig-0.5*(x0+x1))); \t\t\t\t\thsl.z = totl; \t\t\t\t} \t\t\t\telse { hsl.x=0.0; hsl.y=0.0; hsl.z=lig; } \t\t\t\t\t\t\t\trgb = hslToRgb(hsl.x, hsl.y, hsl.z); \t\t\t\t\t\t\t\tgl_FragColor = vec4(rgb,src.w); \t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[6].prototype=new je.in;je.Ja[6].prototype.xC=function(w,n){this.f2(["source","wght","prms"]);
var W=je.VE,D=this.Eg,j=[n.fH,n.a2H,n.Mg,n.agZ,n.DS,n.a0b];W.uniform1fv(D.wght,new Float32Array(n.av9));
W.uniform1fv(D.prms,new Float32Array(j));this.YJ([D.source,w])};je.Ja[7]=function(){je.in.call(this);
this.ZB={};var w="\t\t\tprecision mediump float;\t\t\t"+je.SW.tC+"\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform sampler2D lut;\t\t\tuniform float N;\t\t\t\t\t\tvarying vec2 sCoord;\t\t\t\t\t\tvoid main(void) { \t\t\t\tvec4 src = texture2D(source, sCoord); \t\t\t\tvec4 rs = mapLut(src, lut, N); \t\t\t\tgl_FragColor = vec4(rs.rgb,src.w); \t\t\t\t\t\t\t}";
this.sk(w,je.u4.qP)};je.Ja[7].prototype=new je.in;je.Ja[7].prototype.xC=function(w,n){this.f2(["source","lut","N"]);
var W=je.VE,D=this.Eg,j=n.r1,I=n.Ey;if(this.ZB["m"+j]==null)this.ZB["m"+j]=new je.H0(j,j*j);var U=this.ZB["m"+j];
U.set(I);W.uniform1f(D.N,j);this.YJ([D.source,w,D.lut,U.LJ]);W.activeTexture(W.TEXTURE1);var M=W.LINEAR;
W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MIN_FILTER,M);W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MAG_FILTER,M);
W.activeTexture(W.TEXTURE0)};je.filter={MW:{},qP:"1u,/0*&<>2OI;<m^XJZ;]d/vp^r|ows/)z{M>5g7:@5nVPLIGeVMX`|njge-'&-$V&)/$BbHB4D%GNx`KSI=_f_menp%E+%vwKB4&'XQY``edhootpjxp&%*'vhxY{#>5HINMDXX]YnVW",azC:0,a4s:1,d7:2,a9X:3,agn:4,avZ:5,yJ:6,axV:7};
je.filter.zj=function(w,n){var W=je.filter,D,j=w.type+":"+(w.LQ?w.LQ.join(","):""),D=je.filter.MW[j];
if(D==null)D=je.filter.MW[j]=new je.MW[w.type](w.LQ);D.FO();D.xC(n,w);je.VE.drawArrays(je.VE.TRIANGLES,0,6)};
je.MW=[0,0,0,0,0,0,0,0,0,0,0,0];je.MW[7]=function(){je.in.call(this);var w="1%* !*709;O;?@DOaKTZOe/lhffrxv,#s#)($4VkJA@II=BzXTRR^dbwqcd6's%xN,(&&286K5>D9O]LIYXH)P1o]q{nvr.(yzL=4f69?4mLHECaRIT\\xjfca)~|noC2).)[8*+^U`_felkrn$R[aVlzaoxD:;@N|)/G)28-CQNtjkp~`&*#!&4u*-.(q}$<}'-\"8FBi_`esTz~wuz)i~\"#xvhi=,r~(U0$:9==3bw^MLUUINwne8gjpe/}opB;/FMMRQBX__d`dGXLo%P\\e$kca,Bkw!?uR.3.CQf0<E_DAQP@QYbxm!-+0.~2iJ0).)L4,*YjDIDg>zJRH2aS\\;jjpvD}#}N4";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[7].prototype=new je.in;je.MW[7].prototype.xC=function(w,n){this.f2(["source","iwh","kern"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1fv(D.kern,n.aer);this.YJ([D.source,w])};je.MW[6]=function(w){je.in.call(this);
var n=w[0],W=w[1],D=w[2],j="1%* !*709;O;?@DOaKTZOe/lhffrxv,#s#)($4VkJA@II=BzXTRR^dbwqcd6's%xN,(&&286K5>D9O]SEK%cQeobjf\"{mn@1(Z*-3(a@<97UF=HPl^ZWU|rpbc7&|\"|O,}~RITSZY`_fbwFOUJ`nUcl8./4Bp|#;|&,!7EAh[\"'zuV|!7<0+k!$%zkk0$J>'x~:=<d<.4[U<KMVNV`S,j\\]1 fr{I$w.-11'VkRA@II=BkbY,[^dY#qcd6/NVb<@#4(K`,8A_G?=g}GS\\zQ.ini~-Bkw!Lw&/HK^D=B=ar<JS|X]X{c[Y):sxs7mJy\"wa1#,j::@FsMRM}c",I=hk.GF(j);
I=I.replaceAll("PRC",D+".0");I=I.replaceAll("DIR",["x,0","0,x"][W]);this.sk(I,je.u4.qP)};je.MW[6].prototype=new je.in;
je.MW[6].prototype.xC=function(w,n){this.f2(["source","iwh","rad"]);var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);
W.uniform1f(D.rad,n.lX);this.YJ([D.source,w])};je.MW[4]=function(w){je.in.call(this);var n=w[0],W=w[1],D="\t\t\tprecision highp float;\t\t\tuniform sampler2D source;\t\t\tuniform vec2 iwh;\t\t\tuniform float rrad;\t\t\tuniform float tr;\t\t\t\t\t\tvarying vec2 sCoord;\t\t\tconst float PRC="+w[2]+".0; \t\t\t\t\t\tvoid main(void) {\t\t\t\tvec4 sclr = texture2D(source, sCoord);\t\t\t\tfloat rad = rrad; \t\t\t\tif(rad!=0.0) {\t\t\t\t\tvec4 sum=vec4("+["1.0,1.0,1.0,0.0","0.0,0.0,0.0,1.0","0.0"][W]+"); vec4 cnt = vec4(0.0);\t\t\t\t\tfor(float y=-PRC; y<=PRC; y++) {\t\t\t\t\t\tif(y<-rad || y>rad) continue; \t\t\t\t\t\tfor(float x=-PRC; x<=PRC; x++) { \t\t\t\t\t\t\tif("+["x<-rad || x>rad","(x*x+y*y)>rad*rad"][n]+") continue; \t\t\t\t\t\t\tvec4 clr = texture2D(source, sCoord+vec2(x,y)*iwh); \t\t\t\t\t\t\t"+["if(clr.w!=0.0) sum.rgb=min(sum.rgb,clr.rgb); sum.w=max(sum.w,clr.w)","sum.rgb=max(sum.rgb,clr.rgb); sum.w=min(sum.w,clr.w)","if(abs(sclr.r-clr.r)<tr) { sum.r+=clr.r; cnt.r+=1.0; };"+"if(abs(sclr.g-clr.g)<tr) { sum.g+=clr.g; cnt.g+=1.0; };"+"if(abs(sclr.b-clr.b)<tr) { sum.b+=clr.b; cnt.b+=1.0; };"][W]+"; \t\t\t\t\t\t\t\t\t\t\t\t\t}\t\t\t\t\t}\t\t\t\t\t\t\t\t\t\tsclr = "+(W==2?"vec4(sum.rgb/cnt.rgb, sclr.w)":"sum")+";\t\t\t\t}\t\t\t\tgl_FragColor=sclr; \t\t\t}";
this.sk(D,je.u4.qP)};je.MW[4].prototype=new je.in;je.MW[4].prototype.xC=function(w,n){this.f2(["source","iwh","rrad","tr"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1f(D.rrad,n.Jb);W.uniform1f(D.tr,n.a1n);this.YJ([D.source,w]);
var j=W.LINEAR;j=W.NEAREST;W.activeTexture(W.TEXTURE0);W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MIN_FILTER,j);
W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MAG_FILTER,j);W.activeTexture(W.TEXTURE0)};je.MW[5]=function(){je.in.call(this);
var w="1%* !*709;O;?@DOaKTZOe/lhffrxv,#s#)($4VkJA@II=BzXTRR^dbwn_ntso BW6-050`>:88DJH]WIJ{lYj^4qmkkw}{1z$*~5C(7;DmKGEEQWUjT]cXn|egmoG&s(2%-)D>01bSJ|LOUJ$O^`hlzdmsh~-bPKGLZ9520N?6AIeWSPNuki[\\0~qht}K(yzNEPQVRg6?E:P^YX]X+!\"'5sef:)xQO*}4377-\\qXGJOJkbY,[^dY!6dpv/py t+96\\OwcEjn'rThklbP\\bz\\ek`v%!H;cO0VZr^?TWXNL>?paSK(a4cfla+ykl>7+A2DH+<0eD67jYAS ZNdcgg]-B)wz z<3%|EL/gc2;A6LZ#}HV^tTf ]o+\"{mnB9DEKOUOVW^d^efpjrrwsv,Zci^t#}pIt+&@HcKLXZ]^cVd\\gssxxP_cl$()55::q!%.EISUX[^_d`cxXW\\Wlz0m`7neqz+9N,~D2&<;??5dy`ONWWKPypbZ#8}!mukU%v ^..4:g;:L^I@LUt`_d_!wocyx||rBW>-,55).WNEwGJPElriRTZ\\\"7|";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[5].prototype=new je.in;je.MW[5].prototype.xC=function(w,n){this.f2(["source","ssum","iwh","amnt","edgf"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1f(D.amnt,n.agT);W.uniform1f(D.edgf,n.a0G);this.YJ([D.source,w,D.ssum,n.ar5])};
je.MW[3]=function(){je.in.call(this);var w="1%* !*709;O@;=ETOUgQZ`Uk5rnllx~|2)y)/.*:\\qPGFOOCH!^ZXXdjh}wij<-y+~T2.,,8><Q;DJ?Uc[NR`.kgeeqwu+t}$x/=36(.gEA??KQOd^PQ#sjjbc>{wuu\"(&;5'(ZJ<@=JtRNLLX^\\qbYo2!tvv'@N,(&&286K<3IkZNPP`z(fThremi%~pqC4+]-06+d/?BBXEM2TTdugYZ.|v,\" qrF5)X,#=OAWACCSlkYoY[[k&!6pfx||{0!w2D-$>P<\\J`HhWioTKewc$s(o0|14JNDEJX>:,-_OE7G@qi[MN!pdo&|vhi<, ,>42$%WG=/H*8FySLTp\\g{&))4:;7CC;$0CSRPXZ_cg]Wd]quw~$}'-/50=wm $$#7-~8y(6L\\R<EKNTlZLeGUc#8}ykl?/yv./QI;-.`PDOe\\VHI{k_k}smcuyyx-8&w(!RJ6AW?K]bM?OHyq}}%'#lw.66B8\".@E0\"2+\\Tb`fbLXmxu\"wal %oaqj<4?@KOE/;PWXea]GRe_owv{nz~))3<\"}opC3,(&&UM?12dTHSi`ZLM oco\"wqgy}}|1'x)\"SK7BX@L^bmlqqxx},qZiksw&ox~s*8kpda^Z[`nMIFDbSJU]ykgdb* }opD3*|)2_:.DCGG=l\"hWV__SX\"xoBqtzo7Lz$*~5C+/=D;r:>RiYLP^}gZfo.z/Dr{\"v-;1#)d/3AH?cORDJ$UUygY_~>45:6,*{|O?6;6f5>D9O]T[$yz ~ubjb?66;Iw$*B$-3(>LIob).\"|^$(>C72s(+,\"rzrOFFKK+3+e77[PuiRDJehh0gY_'!gvx\"y\",~W&28P2;A6LZV}p7<0+k26LQE@!6KCBGC9'06+AO6NuTiKSK&WW{o6*rdj&)(P(y GA(79B:BL?wIImiU]Bddt&wij>5s,B3H2$*T[\\a]`c]DSU^V^h[4rde9(nz$Q, 6599/^sZIHQQEJsja4cfla+ykl>7u.D5GK.?3Vk:CI>TbIM)PTh obft4my#A.BW&/5*@N3K?wmnvpMYb!h$,-7>2nz$B~EMNTWS0<Ec;vENTI_mWfZ7pphi7%9uyB~#\\..R/G;tMMEFsbtnUaj)phfD2>>CC /#KO,8A_G?=]kcM\\Pyi[\\/'9384Iw!'{2@49>iW6:t@DRYPj-p{~^bpwn6os;D|!/6-PJgP[:>y|rsx+~ %2#ae1ko}%{?H $KNc2;A6LZAX!ww||chm7ry0En&L(-(H]'>S0<EcKCA|beywX`V@oajIxx~%R\"*n11ARD67jaippus_2adj_,y.98=<@GGLJ6h8;A6bQdonsrzx {~8rde90<:B@HFNI]=/0cZedkjqpxs)z#vm`luC qrF=,1,P8?V^^c_tZVHI{k_S2n`a4,zM| &zG5K6h8;A6bQfontp]0_bh]*w+@~pqD4(|Z7)*\\TCuEHNCo^s}{#',$pCru{p=+AJIQK8j:=C8dSezYKL~n`dk`;osp};*PSIJOBdHA=;;jbNBoWLuo-u`]tu80{o=%yCX**N8<9FcSx{rrwsm_cj_+x@tx t@/U*.5*UEhD7CLjRJHhv,yY]kri.uyv$A/BF.29.f6>4}M?H'VV\\b0i\\hq=#";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[3].prototype=new je.in;je.MW[3].prototype.xC=function(w,n){this.f2("source iwh tdep rrad spec nois poly0 poly1".split(" "));
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1f(D.tdep,n.aAy);W.uniform1f(D.rrad,n.Jb);W.uniform2fv(D.spec,n.awX);
W.uniform3fv(D.nois,n.azp);W.uniformMatrix4fv(D.poly0,!1,n.ahy);W.uniformMatrix4fv(D.poly1,!1,n.av8);
this.YJ([D.source,w]);var j=W.LINEAR;W.activeTexture(W.TEXTURE0);W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MIN_FILTER,j);
W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MAG_FILTER,j);W.activeTexture(W.TEXTURE0)};je.MW[0]=function(){je.in.call(this);
var w="1%* !*709;O@;=ETOUgQZ`Uk5|uqoo{\" 5,|,21-=_tSJIRRFK$kd`^^jpn$}opB3 1%ZB;755AGEZTFGyiYT.unjhhtzx.w!'{2@7/3;5mUO=Q[NVRmgYZ,|sFux~sM5~(.#9G23E'?;AOZm_QR$th$}|$mv|q(62M?_E=1GFJJ@o%kZYbbV[%{o-{mn@9AHHMLCVW\\X\\?PDgo\\#jT]cXn|x5&F,$w.-11'VkRA@II=BkbVsbTU' z//43*=>C?C&7+NVCiQ;DJ?Uc`zl-rj^tswwm=R9('00$)RI=ZI;<mfatuzy}%%*&*l}q5=*P8\"+1&<JGbSsYQE[Z^^T$9 nmvvjo90$A0\"#TMH[\\a`WkkplpSdX{$p7~hqwl#1x0J=]CVWc[R:Qm^~doc }l(#8 irxm$2y2L>^DWXd\\S;Sn_ epe!~n)$9!zlm@0\"6V<.286-;;O=bTFGyqyTk(#`x31(8r*DA~7ROF.E_\\:Rlgj g]Seiih|drz1xs>$AV>?D>:75SD;FNj\\XUSztszdmsh~-({6V<PPUHVN9:L.FBHVatc6ehnc+/{sw yR:%-#l<.7uEEKQa\"g_Sihllb2G.|{%%x}G>5g7:@5\\`QEzbc";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[0].prototype=new je.in;je.MW[0].prototype.xC=function(w,n){this.f2(["source","iwh","ld","shine"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform3fv(D.ld,n.ayj);W.uniform1f(D.shine,n.awE);this.YJ([D.source,w,D.tang,n.XU])};
je.MW[1]=function(){je.in.call(this);var w="1%* !*709;O@;=ETOUgQZ`Uk5|uqoo{\" 5,|,21-=_tSJIRRFK$kd`^^jpn$}opB3 1%ZB;755AGEZDMSH^lYfY4{tpnnz!~4}'-\"8F,?9FJEAya[I]gZb^ysef8) R\"%+ YA+4:/ES?;PHjLU[Pfths*!jsyn%3'3E?>E/8>3IWM?X:HVl-ribj'r}2<??JPQMYYQ:FYihfnpuy}smzs(,.5:4=CEKFS;1'9==<PF8Q3AOeukU^dgm&se~`n|<Q9:?)28-CQ<=O,PMZOtfXY+{n+%$+%vwI:.@`FQ<ZI;<mfwuzx}|%(1+0,/3u#uP82$%VG9>PpV@IORXp\\w-tn`a3$u|]0P6*I.3`H2;A6LZQqt$]V^z'**/+@(\"stF7}M@`F-<CZDIdhUux&mgYZ,|c4&F,r\")@*/L;-._Xddihppuqtxe&)6}gpvk\"0\"6V<($91S2abPfApq`r(oYbh]s\"sz+K1|x.&H'WWE[6efUg|dNW]Rhvha @&qm#z={KL:P+[[J\\qYCLRG]k]dYw8}iezr5sDD2H#SSBTiQ;DJ?UcOzl-rcbt'p%4+|$@&-mN<OdL6?E:P^Jvg(m^]o\"kd/t{p;!(hI7J_G1:@5KYS_ eVUgy])'}i63x `A0BW?9EeKVHTsZmnxoi,o#$)6005C+t}$x/=373>LlRLXf^DWQ^b]Yv$|hdyq4r\")@,L:MQ>^a_:IPgSsbtxe&)$9!vl~##\"6,0,7OP\\\\acjhmi~fglfb_]{lcnv3%!}{C=<C=/0aRNR[{aX+Z]cX&cth>& qrF5{++AaG?3IHLLBq'm\\[ddX]'}tGvy t<Q9 //S*KkQ<=O,PMZOthl~4{fndN}oxW''-3CcI0??pXY";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[1].prototype=new je.in;je.MW[1].prototype.xC=function(w,n){this.f2(["source","iwh","isc","bristle"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1f(D.isc,n.a03);W.uniform1f(D.bristle,n.ao3);
this.YJ([D.source,w])};je.MW[2]=function(){je.in.call(this);var w="1%* !*709;O@;=ETOUgQZ`Uk5|uqoo{\" 5,|,21-=_tSJIRRFK$kd`^^jpn$zkz! {,NcB:*:6lTMIGGSYWlfXY+{hymC+$ }}*0.C-6<1GULEFOF#jc_]]iom#lu{p'5}4/1_GA/CM@HD_YKL}ne8gjpe?'py t+94%,-1@NY;DJ?Uc_rlkrh^ptts(p'\"<7G.0;NBX5KFHdmivuzwd]^g^*vopyp;5AV>?D>:75SD;FNj\\XUSztszdmsh~-x+S-&'0'S?89B9u]GPVKaofmx9~338F.(yzN=494IiOG;QPTTJy/udcll`e/&|O~\"(|DYA;-._P:GYy_tsxuvfZpossi9N5%t%!H?6h8;A6]eSWmZLM~w#$.(/0:14I1+|}O@(FfL6CpXBNTlQYbp]4*8 lB;G/{@CD>=D>01bSGYy_V)X[aV0wams,mv|q(6,YOPUcKAmfgjmns\"i_z}~xw~xjk=.~x7W=RQVSTD8NMQQGv,rbRb^&|p,4\"&<)z{MFQR\\V]^h_bw_LLpP^f|e_*e-C:;@<65<-'bU93lTUZB`!fWQ+rfx'<\"rl5w)|R:$-3(>LGRrXSDKLP_uc|2ypup&4I/*?-!76::0_t[JIRRFKtk_z0wnu,A~E-yy>,Z\\+=QK1D:9Fx`afN*|Yf4{|\"ltjT$u~]--39IiOFKFefrrwyah|2yz";
this.sk(hk.GF(w),hk.GF(je.filter.qP))};je.MW[2].prototype=new je.in;je.MW[2].prototype.xC=function(w,n){this.f2(["source","tang","iwh","sigma","expo"]);
var W=je.VE,D=this.Eg;W.uniform2fv(D.iwh,n.q8);W.uniform1f(D.sigma,n.anU);W.uniform1f(D.expo,n.aiD);
this.YJ([D.source,w,D.tang,n.XU]);var j=W.LINEAR;W.activeTexture(W.TEXTURE0);W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MIN_FILTER,j);
W.texParameteri(W.TEXTURE_2D,W.TEXTURE_MAG_FILTER,j);W.activeTexture(W.TEXTURE0)};function E(){}E._={};
E.alF={};E.as0=function(){var w=[64,64,128,256,512,1024,2048],n=[];for(var L=0;L<w.length;L++){var W=w[L],D=document.createElement("canvas");
D.width=W;D.height=W;n.push(D.getContext("2d",{willReadFrequently:!0}))}return n}();E.Om=function(w,n){var W,D=E.as0,L=1,j=Math.max(w,n);
while(L<D.length&&j>D[L].canvas.width)L++;if(L==D.length){W=D[0];var I=W.canvas;I.width=w;I.height=n}else{W=D[L];
W.clearRect(0,0,w,n)}return W};E.Wt=function(w,n,W){var D=new Uint32Array(n*W);D[0]=w[0];for(var j=1;
j<n;j++)D[j]=D[j-1]+w[j];for(var I=1;I<W;I++){var L=I*n;D[L]=D[L-n]+w[L];for(var j=1;j<n;j++)D[L+j]=w[L+j]+D[L+j-1]+D[L+j-n]-D[L+j-n-1]}return D};
E.MM=function(w,n,W,D,j,I){var U=(j-1)*n,M=I*n;return w[M+D]-w[M+W-1]-w[U+D]+w[U+W-1]};E.Bw=function(w,n,W){var D={},j=0,I=0,U=new Uint32Array(w.buffer),M=U.length,m=Date.now();
for(var l=1;l<W-1;l++)for(var A=1;A<n-1;A++){var g=l*n+A,k=U[g];if(k>>>24<230)I++;if(D[k]==null){D[k]=!0;
j++}}if(I!=0||j<20)return!1;return!0};E.b6=function(w,n,W,D,j,I){if(j==null)j=I=0;D=Math.log(D)/Math.log(2);
D=Math.round(D);for(var L=0;L<W;L++)for(var U=0;U<n;U++){var M=L*n+U<<2,m=E.dv(L+I,U+j,D);w[M]=w[M+1]=w[M+2]=m;
w[M+3]=255}};E.dv=function(L,w,n){return 255-((L>>>n)+(w>>>n)&1)*51};E.uv=function(w){return{o:w>>>16&255,B:w>>>8&255,k:w&255}};
E.$$=function(w){var n=w.toString(16);while(n.length<6)n="0"+n;return n};E.lO=function(w){return parseInt(w,16)};
E.Mg=function(w){return.3*w.o+.59*w.B+.11*w.k};E.Wl=function(w){return Math.max(w.o,w.B,w.k)-Math.min(w.o,w.B,w.k)};
E.g7=function(w,n,W){return.3*w+.59*n+.11*W};E.agd=function(w,n,W){return Math.max(w,n,W)-Math.min(w,n,W)};
E.oC=function(w,n){var W=n-w,D=Math.abs(W),j=W-1,I=W+1;if(Math.abs(j)<D)W=j;else if(Math.abs(I)<D)W=I;
return W};E.ae=function(w){return w<.0031308?12.92*w:1.055*Math.pow(w,1/2.4)-.055};E.vw=function(w){return w<.04045?w/12.92:Math.pow((w+.055)/1.055,2.4)};
E.alW=function(w,n){var W=Math.min(w.length,n.length);for(var L=0;L<W;L+=4){var D=w[L],j=w[L+1],I=w[L+2];
n[L]=16+Math.floor(65.481/255*D+128.553/255*j+24.966/255*I+.5);n[L+1]=128-Math.floor(37.797/255*D-74.203/255*j+112/255*I+.5);
n[L+2]=128+Math.floor(112/255*D-93.786/255*j-18.214/255*I+.5);n[L+3]=w[L+3]}};E.Yc=function(w,n,W){var D,j,I,U=Math.max(w,n,W),M=Math.min(w,n,W);
I=U;if(U!=0)j=(U-M)/U;else j=0;if(j==0)D=0;else{var m=U-M,l=(U-w)/m,A=(U-n)/m,g=(U-W)/m;if(w==U)D=g-A;
else if(n==U)D=2+l-g;else D=4+A-l;D*=1/6;if(D<0)D=D+1}return{ag:D,_6:j,k:I}};E.ap9=function(w,n,W){var D=0,j=0,I=0;
if(n==0)D=j=I=W;else{var U=(w-Math.floor(w))*6,M=Math.floor(U),m=U-Math.floor(U),l=W*(1-n),A=W*(1-n*m),g=W*(1-n*(1-m));
switch(M){case 0:D=W;j=g;I=l;break;case 1:D=A;j=W;I=l;break;case 2:D=l;j=W;I=g;break;case 3:D=l;j=A;
I=W;break;case 4:D=g;j=l;I=W;break;case 5:D=W;j=l;I=A;break}}return{o:D,B:j,k:I}};E.AO=function(w,n,W){var D=Math.max(w,n,W),j=Math.min(w,n,W),I=0,U=0,M=(D+j)*.5;
if(D!=j){var m=D-j;U=M>.5?m/(2-(D+j)):m/(D+j);switch(D){case w:I=(n-W)/m+(n<W?6:0);break;case n:I=(W-w)/m+2;
break;case W:I=(w-n)/m+4;break}I*=1/6}return{ag:I,_6:U,EO:M}};E.P4=function(w,n,W){var D,j,I;if(n==0)D=j=I=W;
else{var U=W<.5?W*(1+n):W+n-W*n,M=2*W-U;D=E.SA(M,U,w+1/3);j=E.SA(M,U,w);I=E.SA(M,U,w-1/3)}return{o:D,B:j,k:I}};
E.SA=function(w,n,W){if(W<0)W+=1;if(W>1)W-=1;if(W<1/6)return w+(n-w)*6*W;if(W<1/2)return n;if(W<2/3)return w+(n-w)*(2/3-W)*6;
return w};E.i8=function(w,n,W){var D=Math.max(w,n,W),j=Math.min(w,n,W),I,U,M=D,m=D-j;U=D==0?0:m/D;if(D==j)I=0;
else{switch(D){case w:I=(n-W)/m+(n<W?6:0);break;case n:I=(W-w)/m+2;break;case W:I=(w-n)/m+4;break}I*=1/6}return{ag:I,_6:U,jB:M}};
E.li=function(w,n,W){var D,j,I,L,U,M,m,l;L=Math.floor(w*6);U=w*6-L;M=W*(1-n);m=W*(1-U*n);l=W*(1-(1-U)*n);
switch(L%6){case 0:D=W,j=l,I=M;break;case 1:D=m,j=W,I=M;break;case 2:D=M,j=W,I=l;break;case 3:D=M,j=m,I=W;
break;case 4:D=l,j=M,I=W;break;case 5:D=W,j=M,I=m;break}return{o:D,B:j,k:I}};E.km=function(){var w=[],n=[];
for(var L=0;L<8e3;L++){var W=L*(1/4e3);w[L]=E.vw(W);n[L]=W>.008856?Math.pow(W,1/3):(903.3*W+16)*(1/116)}return[w,n]}();
E.gK=function(w,n,W,D){if(D==null)D=[.9642,1,.8249];var j=E.km[0],I=E.km[1];w=j[~~(.5+w*(4e3/255))];
n=j[~~(.5+n*(4e3/255))];W=j[~~(.5+W*(4e3/255))];var U=E.Mv.Lv,M=U[0]*w+U[1]*n+U[2]*W,m=U[4]*w+U[5]*n+U[6]*W,l=U[8]*w+U[9]*n+U[10]*W;
M=M*(1/D[0]);m=m*(1/D[1]);l=l*(1/D[2]);return E.rI(M,m,l)};E.rI=function(w,n,W){var D=E.km[1],j=D[~~(.5+w*4e3)],I=D[~~(.5+n*4e3)],U=D[~~(.5+W*4e3)];
return{zP:116*I-16,dl:500*(j-I),k:200*(I-U)}};E.kH=function(w,n,W){var D=903.3,j=.008856,I=(w+16)/116,U=I*I*I,M=I-W/200,m=M*M*M,l=n/500+I,A=l*l*l,g=m>j?m:(116*M-16)/D,k=U>j?U:(116*I-16)/D,$=A>j?A:(116*l-16)/D,C=$*96.42,f=k*100,z=g*82.49,s=E.Mv.q4(E.Mv.WE,[C/100,f/100,z/100,0]);
for(var L=0;L<4;L++)s[L]=Math.max(0,Math.min(255,E.ae(s[L])*255));return{o:s[0],B:s[1],k:s[2]}};E.fA=function(w,n,W,D,j){var I=w.zP,U=w.dl,M=w.k,m=(I<n.zP?n.zP-I:W.zP<I?W.zP-I:0)*(1/100),l=(U<n.dl?n.dl-U:W.dl<U?W.dl-U:0)*(1/116),A=(M<n.k?n.k-M:W.k<M?W.k-M:0)*(1/116),g=Math.sqrt(m*m+l*l+A*A)*1.35;
return g<=D?Math.min(1,1.17*(1-g*j)):0};E.aN=function(w){var n=[.9956,.9956,.9954,.7753,.782,.7895,.5749,.5829,.5932,.3854,.3898,.3989,.1366,.122,.1252,1,.9792,.7954,.7871,.7722,.636,.5822,.5744,.4751,.3875,.3822,.3126,.1261,.1144,.0693,1,.9652,.5979,.7928,.7604,.4791,.5851,.565,.3546,.3884,.3755,.2237,.1179,.1086,0,1,.9532,.3722,.7961,.7499,.3022,.587,.5571,.2159,.3882,.3695,.1154,.1051,.1046,0,1,.9445,0,.7976,.7421,0,.5869,.5508,0,.3881,.3653,0,.0938,.1022,0,.9733,.794,.8719,.7619,.6264,.6945,.5681,.4653,.5213,.3827,.3038,.3461,.1374,.0531,.0828,.9815,.7819,.7026,.7691,.6199,.5631,.5715,.4594,.4188,.3824,.2985,.2698,.1305,.0491,.0182,.9877,.7722,.5366,.7722,.6103,.4274,.5721,.4519,.3125,.3819,.2937,.1895,.1209,.0467,0,.9919,.7632,.3502,.7745,.6025,.2763,.573,.4458,.1912,.3812,.2897,.089,.1101,.0454,0,.9943,.7569,.0534,.7758,.597,.0442,.5729,.4412,0,.3807,.2868,0,.1027,.0446,0,.9528,.6013,.7552,.7481,.4721,.6014,.5602,.3459,.4503,.3792,.2136,.2944,.1381,0,.0324,.9584,.5928,.6121,.753,.469,.4892,.562,.3431,.3615,.3781,.2114,.2264,.1303,0,3e-4,.9624,.5875,.4732,.7544,.4629,.3742,.5607,.3386,.2697,.3761,.2091,.1541,.121,0,1e-4,.9649,.5814,.3186,.7556,.4584,.2473,.5608,.3347,.1646,.375,.2073,.0588,.1137,0,0,.9662,.5767,.1149,.7561,.4549,.0779,.5604,.3319,9e-4,.3744,.2058,0,.1088,0,0,.9362,.4032,.649,.7366,.3099,.5161,.5534,.2148,.384,.3759,.1032,.2452,.12,0,.0041,.94,.4001,.5282,.7398,.3111,.4202,.5532,.2166,.3069,.3735,.1073,.1841,.1139,0,.0036,.9427,.3993,.4122,.7401,.3097,.3231,.5517,.2165,.2275,.3715,.11,.1174,.1092,0,.0034,.9441,.3974,.285,.7405,.3093,.2178,.5511,.2167,.1376,.3693,.1129,.0302,.1056,0,.0032,.9445,.3951,.1314,.7406,.3095,.0917,.5505,.2176,.0086,.3681,.1148,0,.1033,0,.0031,.9221,0,.546,.7269,0,.4335,.5475,0,.3187,.3729,0,.1953,.084,0,.0023,.9248,.0373,.447,.7285,0,.3522,.5456,0,.2522,.3695,0,.1398,.0852,0,.0023,.9264,.079,.3534,.7279,.0224,.2733,.5434,0,.1856,.3669,0,.0812,.0861,0,.0024,.927,.0991,.2521,.7281,.0569,.1899,.5431,0,.1113,.3652,0,.0077,.0867,0,.0024,.9265,.1117,.1412,.7282,.0765,.0995,.5432,.0101,.0172,.3639,0,0,.0872,0,.0024,.7225,.8956,.9779,.571,.7098,.7784,.4213,.53,.5853,.2723,.3526,.3946,.0485,.1007,.1307,.7486,.8824,.7882,.5895,.7001,.6314,.4335,.5225,.4726,.2784,.3469,.3123,.0341,.0972,.0776,.7658,.8703,.6053,.5995,.6889,.4838,.4392,.5138,.3592,.2814,.3411,.2289,.0234,.0944,.0085,.78,.8609,.41,.6082,.6803,.3248,.4436,.5065,.2342,.283,.336,.133,.0037,.0928,0,.7915,.8551,.1645,.6149,.6746,.1258,.4458,.5011,.0697,.2837,.3321,0,0,.092,0,.7312,.7169,.8575,.5814,.5728,.6863,.4323,.4259,.5164,.2834,.2756,.3448,.0654,.024,.0921,.7519,.7108,.6983,.5949,.5673,.5599,.4394,.421,.4172,.2859,.2722,.2708,.0568,.0261,.0319,.7627,.7026,.5428,.6002,.559,.4317,.4419,.4147,.317,.2867,.2683,.195,.0425,.0282,0,.7723,.6957,.3769,.6056,.5525,.2948,.4442,.4093,.2077,.2871,.2651,.1067,.0215,.0303,0,.7806,.6916,.1821,.6099,.5478,.1312,.445,.4052,.0684,.2867,.2625,0,.0082,.0316,0,.736,.5475,.7455,.5857,.4365,.5975,.4376,.3188,.4485,.2894,.1926,.2954,.0569,0,.0469,.7508,.5451,.6108,.5946,.4336,.4887,.4418,.3166,.362,.2901,.1921,.2292,.0463,0,.0011,.7574,.5412,.4799,.5972,.4291,.3794,.4421,.3139,.2753,.2894,.1914,.1611,.0316,0,7e-4,.7636,.5369,.3403,.6008,.4253,.263,.4428,.3106,.1798,.2887,.1903,.0779,.0216,0,5e-4,.7692,.534,.1853,.6035,.4221,.1295,.443,.3081,.0601,.2877,.1889,0,.0152,0,3e-4,.7373,.3763,.6456,.587,.2924,.5158,.4401,.2001,.3846,.2928,.0875,.248,.0165,0,.0011,.7487,.3774,.5308,.5933,.2944,.4233,.4419,.2035,.3105,.292,.0949,.1894,.0078,0,2e-4,.7524,.3782,.4212,.594,.2943,.3305,.441,.2049,.2351,.2905,.0994,.1269,.0013,0,0,.7561,.3774,.3054,.5957,.2939,.2322,.4406,.2052,.1523,.2885,.1035,.0522,4e-4,0,0,.76,.376,.1816,.5977,.2936,.1243,.4399,.2057,.0498,.2863,.1051,0,2e-4,0,0,.7372,.1034,.551,.5874,.0185,.4371,.4413,0,.3224,.2947,0,.201,0,0,0,.7462,.119,.4545,.5913,.0567,.3601,.4411,0,.2599,.2928,0,.149,0,0,0,.7476,.1388,.3655,.5903,.081,.2833,.439,0,.196,.2902,0,.0936,0,0,0,.7499,.1482,.2718,.5912,.0964,.2026,.438,.0193,.1252,.288,0,.0208,0,0,0,.7526,.152,.1763,.5923,.106,.118,.4373,.0341,.0407,.2849,0,0,0,0,0,.4271,.8095,.9608,.3403,.6444,.7657,.2412,.4824,.5773,.1302,.3201,.3909,0,.0832,.1344,.4775,.7983,.7804,.376,.6367,.6256,.266,.4765,.4696,.1467,.3159,.3119,0,.0832,.0832,.5072,.7874,.61,.3956,.6266,.4874,.2794,.4691,.3629,.1561,.3113,.2331,0,.0815,.0173,.531,.7793,.4345,.4122,.6193,.3438,.2899,.4627,.2496,.1627,.3073,.1463,0,.0796,0,.5496,.7747,.2459,.4244,.6147,.1896,.2963,.4584,.1246,.1666,.3043,.0295,0,.0782,0,.4896,.6531,.8455,.3917,.524,.6776,.2849,.3893,.5109,.1706,.2491,.3424,0,.0062,.0979,.5218,.6487,.6934,.4134,.5194,.5559,.2985,.3857,.4154,.1781,.2475,.2712,0,.0082,.0413,.5395,.6417,.5472,.4242,.5122,.435,.3053,.3807,.3208,.182,.2448,.1995,0,.0063,0,.5549,.6359,.3963,.4341,.5068,.3102,.3109,.3763,.2209,.1849,.2427,.1194,0,.0048,0,.5676,.6326,.2389,.4416,.5031,.1779,.3142,.373,.111,.1858,.2406,.0137,0,.0039,0,.5288,.5048,.7395,.4223,.4036,.5936,.3112,.2932,.4464,.194,.1723,.2955,0,.0013,.0537,.5487,.5039,.6103,.4355,.4015,.4884,.3185,.2924,.3629,.1971,.1738,.2316,0,0,0,.5585,.5009,.4864,.4409,.3981,.3847,.3215,.2912,.2809,.1983,.175,.1675,0,0,0,.5683,.4974,.3581,.4472,.3952,.2773,.3237,.2886,.1929,.1985,.1748,.0922,0,0,0,.5766,.495,.2276,.452,.3926,.1646,.3252,.2868,.096,.1979,.174,0,0,0,0,.5526,.357,.6462,.4414,.2769,.5172,.3273,.187,.3867,.2083,.0725,.2515,0,1e-4,.005,.5662,.3586,.535,.4497,.2794,.427,.3308,.1917,.3145,.2087,.0831,.1946,0,0,0,.571,.3597,.4301,.4513,.2799,.3379,.3308,.1939,.2425,.2076,.0893,.1352,0,0,0,.5765,.3593,.3223,.4545,.2797,.2459,.3311,.1945,.1654,.2062,.0944,.068,0,0,0,.582,.3583,.2145,.458,.2797,.151,.3314,.1954,.0803,.2039,.0965,0,0,0,0,.5685,.1511,.5592,.4543,.0767,.4446,.3382,0,.3293,.2147,0,.2076,0,0,0,.5777,.1587,.464,.4588,.0959,.3679,.3388,.0048,.2673,.2134,0,.1566,0,0,0,.579,.1719,.3773,.4578,.111,.2931,.3368,.0292,.2054,.2108,0,.1027,0,0,0,.5819,.1786,.2881,.4594,.1215,.2157,.3361,.0464,.1381,.2085,0,.035,0,0,0,.5855,.1817,.2015,.4613,.1282,.1378,.3358,.0572,.0647,.2046,0,0,0,0,0,0,.7368,.9457,0,.5885,.7547,0,.4416,.5705,0,.2922,.3876,0,.0637,.1371,0,.7271,.7732,0,.5822,.62,0,.4368,.4665,0,.2893,.3113,0,.0575,.0877,.0293,.7172,.6118,0,.5735,.4893,0,.4308,.3654,0,.2859,.2362,0,.0527,.0254,.1667,.7094,.4492,.1105,.5675,.3578,0,.4259,.2615,0,.2833,.1562,0,.0495,0,.2211,.7051,.2881,.1542,.5639,.2285,.048,.4231,.1574,0,.2814,.0642,0,.0479,0,.1089,.6003,.8361,.0907,.4814,.6702,.0189,.3569,.506,0,.2257,.3404,0,.0031,.1007,.2145,.596,.6892,.165,.478,.5528,.0875,.3549,.4141,0,.2259,.2718,0,.0011,.0458,.2608,.5897,.5497,.1974,.4719,.4379,.1153,.3511,.3242,0,.2243,.2033,0,0,0,.2941,.5846,.4094,.2219,.4675,.3224,.1344,.3476,.2318,.0094,.2233,.1295,0,0,0,.3178,.5818,.2725,.2385,.4645,.2083,.1459,.3452,.1382,.0182,.222,.0431,0,0,0,.2849,.4701,.7351,.2249,.3739,.5897,.1519,.2696,.4439,.0559,.1531,.2948,0,.0015,.0592,.3179,.4692,.6097,.2491,.373,.4877,.168,.2703,.3631,.0671,.1566,.233,0,0,2e-4,.3371,.4664,.4904,.2614,.37,.3884,.1766,.2698,.2847,.0733,.1587,.1716,0,0,0,.3538,.4634,.3698,.2734,.3679,.2879,.1834,.268,.2025,.0782,.1594,.102,0,0,0,.3665,.4614,.2537,.2822,.366,.1885,.1883,.2667,.1185,.0802,.1591,.0183,0,0,0,.3552,.3407,.6468,.2814,.2628,.5183,.2001,.1749,.3882,.1031,.062,.2533,0,3e-4,.0134,.372,.3429,.5387,.2932,.2657,.4297,.2062,.1802,.3173,.106,.0746,.1978,0,0,0,.3806,.3439,.4368,.2976,.2663,.3437,.2082,.1829,.2479,.1073,.0816,.1406,0,0,0,.3886,.3435,.3339,.3031,.2664,.2565,.2104,.184,.1754,.1086,.0873,.0786,0,0,0,.396,.3429,.2346,.3091,.2666,.1701,.2126,.1855,.1007,.1086,.0897,.0056,0,0,0,.3978,.1741,.5653,.3167,.1078,.4527,.2294,.006,.3373,.1238,0,.2143,0,0,0,.4068,.1821,.4725,.3221,.1191,.3752,.2306,.0312,.2741,.1272,0,.1636,0,0,0,.4089,.192,.387,.3214,.1294,.3018,.2287,.0514,.2136,.1274,0,.1108,0,0,0,.4121,.1971,.2993,.3239,.1361,.2264,.2287,.0629,.1491,.1264,0,.0499,0,0,0,.416,.2,.2154,.3268,.1401,.1521,.2295,.0705,.0818,.1225,0,.0054,0,0,0,0,.678,.9338,0,.5431,.7462,0,.4082,.5651,0,.2692,.3849,0,.0212,.1397,0,.6694,.7677,0,.5376,.6154,0,.4042,.4639,0,.2673,.3107,0,.0199,.0913,0,.66,.6122,0,.5301,.4905,0,.3996,.3672,0,.2652,.2384,0,.0189,.0316,0,.652,.4583,0,.5254,.368,0,.3963,.2705,0,.264,.1635,0,.0188,0,0,.6472,.3143,0,.5227,.2546,0,.395,.1795,0,.2633,.0845,0,.0193,0,0,.5591,.8297,0,.4461,.6643,0,.3299,.502,0,.2062,.3385,0,.0032,.1024,0,.5534,.686,0,.4436,.5501,0,.3289,.4127,0,.2074,.272,0,.0012,.0482,0,.5472,.5511,0,.4382,.4399,0,.3261,.3266,0,.2067,.2061,0,0,0,0,.5425,.4181,0,.4347,.3313,0,.3234,.2399,0,.206,.1369,0,0,0,0,.5399,.2941,0,.4324,.2287,0,.3218,.1565,0,.2049,.0625,0,0,0,0,.4439,.733,0,.3496,.5873,0,.25,.4423,0,.1369,.2945,0,.0016,.0628,0,.4411,.6097,0,.3493,.4877,0,.2516,.3635,0,.1404,.2343,0,0,.0023,0,.4381,.4935,0,.3466,.3917,0,.2516,.2881,0,.1427,.1753,0,0,0,0,.4354,.3781,0,.345,.2962,0,.2503,.2102,0,.1441,.1098,0,0,0,0,.4338,.2711,0,.3436,.2051,0,.2495,.1342,0,.1445,.037,0,0,0,0,.329,.6482,0,.252,.52,0,.1654,.3901,0,.0534,.2551,0,5e-4,.0192,.0138,.3301,.5419,.0039,.2544,.4323,0,.1705,.3197,0,.0661,.2002,0,0,0,.0783,.3307,.4416,.0404,.2547,.3482,0,.173,.2521,0,.0737,.1446,0,0,0,.1116,.3303,.3412,.0706,.2546,.264,0,.1741,.1825,0,.079,.0854,0,0,0,.1327,.3301,.2469,.0914,.2547,.1832,.0057,.1755,.1135,0,.0784,.015,0,0,0,.1815,.1895,.5709,.1383,.1275,.4596,.0795,.0318,.3435,0,0,.2181,0,0,0,.1962,.1967,.4793,.1496,.1334,.3808,.0833,.05,.2787,0,0,.1661,0,0,0,.2029,.2039,.3936,.1519,.1402,.3076,.0827,.0642,.2186,0,0,.1136,0,0,0,.2078,.2084,.306,.1573,.1445,.2334,.086,.0724,.1556,.003,.0012,.055,0,0,0,.2125,.2113,.223,.1628,.1468,.1616,.0917,.0769,.0917,.009,.0033,.0083,0,0,0],W=Math.round(Math.pow(n.length/3,1/4)),D=[0,0,0,0];
ICC.U.applyLUT4Float(n,W,w,D);return D};E.apV=function(w){var n=[.749,.6784,.6706,.902,.8413,.7807,.5857,.7788,.9743,.9154,.3677,.6283,1,.9841,.2521,.443,1,.9847,.1976,.27,1,.975,.1282,.1337,1,.9637,.0411,.0428,1,.9165,0,.0032,.9395,.8528,0,0,.9105,.7991,0,0,.7599,.552,.7696,.789,.8485,.6228,.6576,.7675,1,.842,.4653,.5761,1,.9389,.3447,.3743,1,.9546,.2577,.2156,1,.9601,.1576,.0954,1,.9601,.0357,.0193,.9879,.9022,0,9e-4,.932,.8336,0,0,.9012,.7864,0,0,.805,.4894,.9278,.6186,.8728,.4726,.9073,.6172,.9147,.5608,.6358,.5491,1,.7567,.4347,.3587,1,.8577,.3079,.1781,1,.8891,.1915,.0504,1,.8925,.0326,.0038,.9683,.841,0,0,.9114,.7927,0,0,.8789,.7515,0,0,.8424,.4034,1,.4124,.8827,.3977,1,.4091,.9032,.4007,.8385,.4013,.9123,.4843,.5898,.339,.9516,.6175,.3867,.2021,.9849,.7235,.2209,.0608,.9818,.7644,.0434,.0018,.9285,.741,0,0,.8782,.712,0,0,.8539,.6876,0,0,.8756,.3098,1,.2322,.8775,.3122,1,.2323,.8913,.3197,.9989,.2249,.889,.3309,.7571,.2136,.8868,.3864,.5323,.1686,.8967,.471,.3416,.0855,.9032,.5434,.1579,.0123,.878,.5672,0,0,.8385,.5812,0,0,.812,.5885,0,0,.8502,.217,1,.0915,.8503,.2193,1,.0904,.8605,.2204,1,.0816,.8568,.225,.8587,.0808,.8448,.2421,.6714,.0732,.8374,.2777,.4686,.0486,.8344,.3291,.2788,.0137,.8184,.3632,.0943,7e-4,.7881,.388,0,0,.7592,.4392,0,0,.8132,.0895,1,.0102,.8134,.0907,1,.0101,.8144,.0938,1,.0085,.8166,.0958,.9103,.0063,.8021,.1066,.7459,.0078,.7898,.1222,.5781,.0046,.7796,.1444,.3947,.0016,.7626,.1735,.2164,0,.7342,.1972,.0383,0,.6884,.2408,0,0,.7532,0,1,0,.749,0,1,0,.7484,0,1,0,.7427,0,.9015,0,.733,0,.7722,0,.7285,0,.6341,0,.724,0,.4726,0,.7068,0,.3102,0,.6877,.0167,.1424,0,.6493,.0413,0,0,.6847,0,1,0,.6808,0,1,0,.6732,0,1,0,.6718,0,.8971,0,.6666,0,.7786,0,.6547,0,.654,0,.641,0,.511,0,.6301,0,.3732,0,.6138,0,.2318,0,.581,0,.0867,0,.6187,0,1,0,.6193,0,1,0,.6162,0,1,0,.6007,0,.9316,0,.5922,0,.7975,0,.5791,0,.6774,0,.5681,0,.5466,0,.5532,0,.4101,0,.5336,0,.2795,0,.5123,0,.1487,0,.6087,.7256,.6558,.8508,.7488,.7971,.5809,.7731,.8912,.9472,.3678,.6053,.9921,1,.2518,.4063,1,1,.1981,.2413,1,1,.1227,.1117,1,.9861,.0232,.025,.9851,.9182,0,.0012,.9143,.8549,0,0,.897,.7991,0,0,.6642,.5963,.7836,.778,.723,.6642,.6485,.7627,.8995,.8599,.4693,.5645,1,1,.3571,.3191,1,1,.2559,.1757,1,.9873,.1346,.0642,1,.9812,.009,.0075,.9627,.8988,0,1e-4,.9127,.8359,0,0,.8883,.7853,0,0,.7564,.504,.9343,.6127,.7956,.4911,.8932,.6161,.8388,.581,.6217,.5473,.9429,.7604,.4287,.3566,1,.8783,.2925,.1608,1,.9216,.1633,.0297,1,.9158,0,6e-4,.9365,.8435,0,0,.8922,.7971,0,0,.8699,.7502,0,0,.8121,.4123,1,.4107,.8406,.4044,1,.4093,.8524,.4134,.8287,.4012,.8718,.4935,.5825,.3369,.9173,.6243,.3823,.1991,.9528,.7278,.2163,.0588,.9572,.7668,.0363,.001,.9059,.7449,0,0,.8676,.7128,0,0,.8391,.6911,0,0,.849,.3168,1,.233,.8523,.3193,1,.2323,.8635,.3245,.9866,.2264,.8536,.3418,.7488,.2167,.8557,.3954,.5289,.1694,.8726,.4779,.3352,.0833,.8788,.546,.1527,.0116,.8602,.5681,0,0,.8227,.5855,0,0,.8024,.5895,0,0,.8351,.2194,1,.0917,.8363,.2207,1,.0898,.8397,.2242,1,.0837,.8366,.2325,.8527,.083,.8259,.2485,.667,.0744,.8209,.2833,.4646,.0489,.815,.333,.2763,.0139,.7997,.3685,.0902,3e-4,.7724,.3932,0,0,.7446,.441,0,0,.7961,.0959,1,.0109,.7954,.0992,1,.0107,.8023,.0973,1,.0086,.7985,.1045,.9054,.0071,.7905,.1085,.7443,.0078,.778,.1256,.5723,.0048,.7654,.1475,.39,.0021,.7467,.1798,.2119,0,.7229,.2012,.0359,0,.6745,.2425,0,0,.7429,0,1,0,.7436,0,1,0,.7367,0,1,0,.7319,0,.9005,0,.7233,0,.7686,0,.7139,0,.6325,0,.7111,0,.4704,0,.6945,.0025,.308,0,.6726,.0212,.138,0,.6387,.0453,0,0,.6714,0,1,0,.6687,0,1,0,.6685,0,1,0,.6575,0,.8922,0,.6536,0,.7756,0,.6418,0,.6508,0,.6323,0,.509,0,.6188,0,.3695,0,.6021,0,.228,0,.5729,0,.0823,0,.6151,0,1,0,.6127,0,1,0,.6027,0,1,0,.5975,0,.932,0,.5855,0,.7966,0,.5747,0,.6768,0,.5622,0,.5457,0,.5432,0,.4053,0,.5264,0,.2766,0,.506,0,.1468,0,.5236,.8098,.7113,.7578,.5807,.8385,.5899,.723,.7287,.9813,.3955,.5643,.8563,1,.2722,.3767,.9135,1,.2027,.2129,.9366,1,.1087,.0833,.9431,1,.0012,.0101,.9083,.9248,0,0,.8762,.8521,0,0,.8566,.8037,0,0,.5233,.7082,.8317,.727,.5247,.7528,.6746,.7138,.7127,.8749,.4697,.5528,.8909,1,.3471,.3125,.9446,1,.24,.1426,.9599,1,.1084,.0359,.9467,.9998,0,.0025,.9056,.9001,0,0,.8711,.838,0,0,.8572,.7854,0,0,.6359,.548,.9563,.5917,.6337,.5523,.8828,.5966,.6892,.6225,.6122,.5317,.8186,.7781,.4193,.3494,.9121,.8888,.2816,.1584,.9602,.9439,.1126,.0204,.9361,.9256,0,0,.8882,.8447,0,0,.856,.7966,0,0,.8377,.753,0,0,.7277,.4351,1,.4042,.7407,.432,1,.4068,.7442,.4393,.8038,.4006,.7786,.5193,.5652,.3295,.8387,.6407,.3748,.1926,.8874,.7349,.2097,.0529,.8924,.7709,.032,.0018,.858,.7467,0,0,.8272,.7233,0,0,.8136,.6967,0,0,.7826,.3341,1,.2338,.7853,.3333,1,.2331,.7881,.3391,.968,.2315,.7838,.3564,.733,.2177,.797,.411,.5152,.1661,.8158,.4923,.3265,.0793,.8324,.5584,.1443,.0087,.8121,.5816,0,0,.7878,.5973,0,0,.777,.6019,0,0,.786,.2337,1,.0947,.7866,.2356,1,.0935,.794,.2365,1,.0892,.7882,.2408,.84,.0867,.7786,.2591,.6529,.0764,.7781,.2939,.4538,.05,.7714,.3458,.2706,.0135,.761,.3799,.0813,0,.7349,.4007,0,0,.7114,.448,0,0,.7632,.1079,1,.0116,.7628,.109,1,.0113,.7635,.111,1,.0099,.7659,.1113,.9006,.0078,.7539,.1229,.7356,.0084,.7432,.1339,.5638,.0056,.7288,.1625,.3809,.0026,.7135,.1888,.1994,0,.6876,.2145,.0287,0,.6434,.2513,0,0,.7136,0,1,0,.7159,0,1,0,.7118,0,1,0,.7055,0,.8971,0,.7011,0,.7648,0,.6892,0,.6268,0,.6846,0,.4642,0,.6698,.0126,.3029,0,.6423,.0335,.1307,0,.6089,.0591,0,0,.6482,0,1,0,.6436,0,1,0,.6439,0,.9976,0,.6368,0,.8876,0,.6335,0,.768,0,.6221,0,.6462,0,.6134,0,.5064,0,.5985,0,.3643,0,.5797,0,.2207,0,.5536,0,.074,0,.5946,0,1,0,.591,0,1,0,.5835,0,1,0,.5768,0,.9227,0,.5633,0,.7881,0,.5505,0,.6711,0,.5446,0,.5428,0,.5278,0,.4021,0,.5115,0,.2734,0,.4929,0,.1453,0,.3928,.9309,.8564,.6237,.4085,.9414,.6804,.6099,.5314,1,.4506,.505,.7062,1,.3091,.3328,.7981,1,.2189,.1772,.8415,1,.109,.0581,.8557,1,0,.0038,.8363,.9173,0,0,.8185,.8532,0,0,.8136,.8032,0,0,.3926,.8335,.9373,.6099,.3914,.86,.7587,.5969,.5208,.9052,.5042,.5014,.7095,.9938,.3603,.3041,.8163,1,.2391,.1297,.8533,1,.1035,.0267,.8464,.9973,0,.001,.8253,.899,0,0,.8145,.8364,0,0,.7999,.7938,0,0,.4805,.6401,1,.5316,.4643,.6578,.8868,.5349,.5124,.6937,.6226,.4883,.6608,.8025,.423,.3315,.7802,.8952,.2804,.147,.8409,.9398,.1161,.0171,.8327,.9166,0,0,.8123,.8496,0,0,.7991,.7982,0,0,.7923,.7593,0,0,.5991,.4869,1,.3854,.593,.4845,1,.3895,.5952,.4942,.7873,.3831,.6365,.562,.5515,.3126,.7242,.6716,.3636,.1788,.7841,.7475,.2033,.0483,.802,.776,.0202,7e-4,.7817,.756,0,0,.7737,.7264,0,0,.7679,.7035,0,0,.6792,.3636,1,.2325,.6802,.3638,1,.2323,.6747,.3671,.9278,.2351,.6742,.3856,.7107,.2174,.6972,.4382,.4946,.1601,.7298,.5132,.3124,.0724,.7516,.5748,.1318,.0064,.7416,.5918,0,0,.7332,.6099,0,0,.7343,.6136,0,0,.7114,.254,1,.0967,.7102,.2555,1,.0967,.7129,.2556,1,.0952,.7059,.2657,.8221,.0947,.7005,.2769,.6384,.0808,.7012,.3167,.4363,.0488,.7045,.3648,.2536,.0117,.6969,.3958,.0646,0,.6721,.4156,0,0,.6617,.454,0,0,.7086,.127,1,.0117,.7087,.1273,1,.0114,.7087,.1276,1,.0103,.7055,.1308,.8869,.0097,.6932,.1399,.7262,.0104,.6792,.1579,.548,.0074,.6742,.1807,.3657,.0017,.6585,.2084,.185,0,.6306,.2333,.0138,0,.5969,.2617,0,0,.6731,0,1,0,.6724,0,1,0,.6689,0,1,0,.6592,0,.8912,0,.6558,0,.7581,0,.6428,0,.6147,0,.6351,.0126,.4524,0,.6185,.0313,.2871,0,.5976,.0491,.1142,0,.5614,.0772,0,0,.6144,0,1,0,.6123,0,1,0,.603,0,.9827,0,.6011,0,.8682,0,.5946,0,.7618,0,.5834,0,.6393,0,.5668,0,.4938,0,.5603,0,.3559,0,.5419,0,.2119,0,.5129,0,.0629,0,.5582,0,1,0,.5549,0,1,0,.5497,0,1,0,.5426,0,.9012,0,.5346,0,.7836,0,.5246,0,.6637,0,.5101,0,.5294,0,.4908,0,.3919,0,.4747,0,.2644,0,.4595,0,.1342,0,.3137,1,1,.4733,.3189,1,.8233,.4638,.3868,1,.5467,.4106,.5429,1,.3574,.2797,.6666,1,.2407,.1393,.7286,1,.1057,.0307,.735,1,0,.0015,.7372,.9194,0,0,.7426,.8544,0,0,.7462,.8049,0,0,.3259,.9135,1,.4628,.3262,.9346,.8592,.4543,.3838,.9454,.588,.408,.5321,.9864,.3862,.2741,.6699,1,.2458,.1083,.7251,1,.0927,.0184,.7305,.9822,0,2e-4,.7309,.9012,0,0,.73,.8418,0,0,.7427,.7935,0,0,.3618,.7477,1,.4296,.3585,.7638,.9306,.4271,.388,.7798,.6696,.3984,.507,.8347,.442,.2873,.6342,.9005,.2877,.13,.7062,.9333,.1114,.0152,.7116,.9203,0,0,.7164,.85,0,0,.7268,.8,0,0,.7276,.7647,0,0,.4519,.5652,1,.3416,.4423,.5685,1,.3457,.4419,.582,.7818,.3366,.4928,.6298,.5572,.278,.5858,.7058,.3645,.1569,.6651,.7635,.1975,.0351,.6776,.7853,.0126,2e-4,.6885,.7637,0,0,.7031,.732,0,0,.7073,.7104,0,0,.5498,.4075,1,.2182,.5445,.4134,1,.2215,.5337,.4154,.9026,.2247,.5398,.4345,.6939,.2036,.5641,.4827,.4766,.1415,.6157,.5483,.2963,.0582,.6454,.5965,.1152,.0034,.6384,.6125,0,0,.6636,.6193,0,0,.6733,.6215,0,0,.6082,.2853,1,.0985,.6052,.2872,1,.099,.6033,.2876,.9985,.1003,.5881,.2934,.8012,.099,.5865,.3116,.6141,.079,.5981,.3473,.4135,.0422,.6092,.3881,.2359,.0082,.5998,.4165,.0474,0,.5852,.4314,0,0,.5864,.4558,0,0,.6267,.153,1,.0146,.6269,.1536,1,.0148,.6212,.1591,1,.0156,.6168,.1609,.8668,.015,.6037,.1683,.7062,.0124,.5948,.1835,.5296,.0088,.5846,.2129,.3441,.0028,.5714,.2348,.1614,0,.5475,.2539,0,0,.5249,.276,0,0,.607,.0028,1,0,.604,.003,1,0,.6012,.003,1,0,.5967,.0088,.8855,0,.5851,.0145,.7469,0,.5778,.0211,.6015,0,.5622,.0363,.4349,0,.555,.0528,.2686,0,.5246,.0748,.0949,0,.4898,.1075,0,0,.557,0,1,0,.554,0,1,0,.5556,0,.9704,0,.5461,0,.854,0,.5335,0,.748,0,.5282,0,.6233,0,.5141,0,.482,0,.5043,0,.3432,0,.4837,0,.1895,0,.4646,0,.0428,0,.5095,0,1,0,.507,0,1,0,.5047,0,.9931,0,.4953,0,.8844,0,.4804,0,.7672,0,.4725,0,.6466,0,.466,0,.5123,0,.4425,0,.3809,0,.4341,0,.2525,0,.4141,0,.1232,0,.2744,1,1,.3276,.2771,1,.9289,.322,.3076,1,.6518,.2983,.4032,1,.4154,.216,.521,1,.2548,.0952,.5899,1,.1005,.0148,.6089,1,0,0,.6354,.9153,0,0,.6536,.8588,0,0,.6715,.814,0,0,.278,.9672,1,.3214,.2835,.9827,.9637,.3121,.308,.9817,.6807,.292,.3991,.9886,.4399,.2125,.5121,1,.2605,.0852,.5823,1,.0832,.0063,.5957,.9741,0,1e-4,.6226,.9023,0,0,.6522,.8412,0,0,.6644,.8029,0,0,.2915,.8321,1,.3092,.2924,.8426,.9941,.3028,.3097,.8464,.7305,.2875,.3795,.8693,.4917,.2195,.4864,.9075,.3067,.1018,.5593,.9289,.1127,.0095,.579,.9101,0,0,.6139,.8517,0,0,.6366,.8057,0,0,.6553,.7739,0,0,.3388,.6529,1,.2664,.3344,.6586,1,.2654,.3357,.6702,.8018,.2588,.3749,.6982,.5799,.2152,.4551,.7464,.3722,.1185,.5249,.783,.1979,.0235,.5441,.7975,0,0,.5803,.7682,0,0,.6132,.7437,0,0,.6397,.7187,0,0,.4144,.4737,1,.1889,.406,.4761,1,.1912,.4003,.4831,.8798,.1888,.4038,.5049,.6886,.1694,.438,.5429,.4731,.1153,.4899,.5936,.2893,.0398,.5216,.6227,.099,.0016,.5174,.6307,0,0,.5619,.6237,0,0,.5881,.6192,0,0,.4782,.3284,1,.0925,.4748,.3285,1,.0943,.4703,.3299,.9508,.0972,.4619,.3412,.7782,.0906,.4622,.3593,.5875,.0716,.4706,.3874,.3871,.031,.4905,.4232,.2084,.0031,.4873,.4428,.0192,0,.4775,.4527,0,0,.5036,.4645,0,0,.5174,.1933,1,.0187,.5175,.1929,1,.019,.5122,.1969,.9895,.0194,.5048,.199,.8362,.0186,.4917,.2083,.6837,.0155,.4812,.2226,.5026,.0084,.4776,.2411,.3179,.0016,.4671,.2627,.1339,0,.4456,.2821,0,0,.4336,.2985,0,0,.5219,.0369,1,0,.5211,.0365,1,0,.5164,.0361,.9928,0,.5051,.0417,.8566,0,.4959,.0461,.7324,0,.4841,.0562,.5795,0,.4697,.0715,.4117,0,.4546,.0909,.2404,0,.4329,.1095,.0677,0,.4078,.1379,0,0,.489,0,1,0,.4874,0,1,0,.4815,0,.9413,0,.474,0,.8389,0,.466,0,.7325,0,.4551,0,.6035,0,.4428,0,.4661,0,.4307,0,.3226,0,.4167,0,.1676,0,.391,0,.0206,0,.447,0,1,0,.4428,0,1,0,.4372,0,.9575,0,.4331,0,.8537,0,.4216,0,.7437,0,.4118,0,.6299,0,.4014,0,.5006,0,.3852,0,.3649,0,.3718,0,.2346,0,.3521,0,.1041,0,.2356,1,1,.1977,.2375,1,.9964,.1944,.2509,1,.7373,.1859,.3016,1,.4867,.1346,.3788,1,.2757,.053,.4353,1,.0751,.0036,.4679,.9829,0,0,.5176,.911,0,0,.5557,.8626,0,0,.5835,.8201,0,0,.2376,.9791,1,.1994,.241,.985,1,.1911,.2501,.9855,.758,.1827,.2933,.9955,.5092,.1362,.3705,1,.2915,.0523,.4224,1,.0745,.0017,.456,.9598,0,0,.5092,.8949,0,0,.546,.851,0,0,.5832,.807,0,0,.2428,.8734,1,.1892,.2449,.8873,1,.1813,.2484,.8891,.7869,.1743,.2865,.8979,.5484,.136,.3596,.9102,.3326,.0622,.4106,.9259,.1239,.0039,.4338,.9056,0,0,.4983,.8524,0,0,.5426,.8125,0,0,.573,.7804,0,0,.2616,.7229,1,.1721,.2607,.7283,1,.1684,.2628,.738,.8211,.1631,.2833,.7568,.6146,.1351,.336,.7794,.3977,.0727,.3928,.8002,.1999,.0099,.403,.8038,0,0,.4608,.7797,0,0,.5189,.7516,0,0,.5576,.7273,0,0,.303,.5471,1,.1332,.2958,.5539,1,.1322,.2912,.5609,.8726,.1295,.2999,.5779,.6879,.1131,.325,.6005,.481,.074,.3663,.6358,.286,.0191,.3853,.6543,.0836,3e-4,.3915,.653,0,0,.4527,.6307,0,0,.5,.6145,0,0,.3535,.3827,1,.0752,.3475,.3848,1,.0766,.3423,.3904,.9281,.0765,.3331,.4014,.759,.0698,.3362,.4178,.5775,.0489,.3526,.4416,.3818,.018,.3669,.4679,.1894,3e-4,.3622,.475,.0046,0,.3698,.4765,0,0,.4168,.4707,0,0,.3961,.2377,1,.018,.394,.2385,1,.019,.3862,.2407,.9519,.0188,.3794,.2484,.8108,.0182,.3676,.2545,.6583,.0131,.3626,.2686,.4759,.0052,.3483,.279,.2863,0,.3452,.3023,.1046,0,.3383,.3138,0,0,.3349,.3243,0,0,.4138,.0832,1,0,.4128,.0828,1,0,.403,.0869,.9634,0,.398,.0906,.835,0,.3864,.0947,.709,0,.3743,.1046,.5563,0,.3601,.113,.3821,0,.3461,.1265,.2092,0,.3293,.1458,.0382,0,.3117,.1713,0,0,.4015,0,1,0,.4005,0,.9806,0,.3974,0,.9052,0,.3865,0,.8146,0,.3784,0,.7183,0,.3675,0,.5942,0,.3587,0,.4443,0,.3438,0,.2997,0,.3265,0,.1417,0,.3072,.0125,0,0,.3763,0,1,0,.3727,0,1,0,.3662,0,.93,0,.3597,0,.8277,0,.3483,0,.7249,0,.3357,0,.6068,0,.3269,0,.473,0,.3161,0,.3445,0,.2997,0,.2142,0,.2812,0,.0787,0,.1798,1,1,.0938,.181,1,1,.0903,.1845,1,.7894,.0861,.2115,1,.5402,.0594,.2579,1,.3057,.0185,.2774,1,.0677,1e-4,.3256,.9598,0,0,.3928,.9075,0,0,.4521,.8635,0,0,.4926,.8257,0,0,.1811,.9832,1,.0877,.1812,.9921,1,.0828,.1842,.9876,.8022,.0815,.2089,.9916,.5605,.0588,.2519,.9889,.3224,.0193,.2745,.9831,.089,4e-4,.3128,.9413,0,0,.3943,.8887,0,0,.4459,.8484,0,0,.49,.8155,0,0,.1842,.8915,1,.0889,.1871,.9021,1,.0826,.186,.9064,.8239,.0797,.2038,.9105,.5965,.0591,.2407,.9175,.3599,.0195,.2727,.9144,.1331,1e-4,.2918,.8947,0,0,.3784,.8495,0,0,.4393,.8145,0,0,.4801,.7848,0,0,.1893,.7731,1,.0803,.1899,.779,1,.0761,.1883,.7848,.8434,.0712,.2,.7937,.6398,.0574,.2314,.8062,.4171,.0253,.2675,.8092,.2047,.0016,.2648,.8119,0,0,.3424,.7811,0,0,.4136,.7509,0,0,.4589,.7248,0,0,.2077,.6167,1,.0629,.2033,.6213,1,.0608,.201,.6309,.8729,.0584,.2066,.6375,.6976,.0496,.2214,.6549,.4903,.0257,.2468,.6718,.2868,.0054,.2557,.6752,.0734,0,.2793,.6639,0,0,.3477,.636,0,0,.399,.6036,0,0,.2371,.4439,1,.0389,.2342,.4504,1,.0381,.2304,.4546,.8961,.0358,.2233,.4645,.7462,.0317,.2265,.4766,.5664,.0192,.2389,.4958,.3758,.006,.2412,.5084,.1699,0,.2384,.5123,0,0,.2799,.4942,0,0,.3284,.4766,0,0,.2724,.2915,1,.0114,.2707,.2923,1,.0118,.2656,.2956,.9239,.0115,.2552,.303,.7898,.0103,.2481,.3086,.6338,.0059,.2427,.3218,.4532,9e-4,.2347,.3316,.2707,0,.2277,.344,.0791,0,.2317,.3491,0,0,.2578,.3452,0,0,.294,.1334,1,0,.293,.1356,1,0,.288,.1408,.9295,0,.2775,.1432,.8069,0,.2699,.1474,.684,0,.2537,.1563,.5238,0,.2399,.1614,.3555,0,.2205,.1718,.1745,0,.212,.192,.014,0,.212,.2099,0,0,.3011,0,.9996,0,.2969,0,.9647,0,.2924,0,.8929,0,.2863,0,.8143,0,.2761,0,.7028,0,.2675,.0011,.5775,0,.2541,.0089,.4329,0,.2377,.016,.2739,0,.2225,.0259,.1098,0,.2042,.0512,0,0,.288,0,.9766,0,.2864,0,.9423,0,.2815,0,.8783,0,.2756,0,.7908,0,.2673,0,.6935,0,.252,0,.5817,0,.2428,0,.4541,0,.2284,0,.3226,0,.2117,0,.1849,0,.1919,0,.053,0,.1032,1,1,.019,.104,1,1,.0159,.1029,1,.8122,.0139,.1104,1,.5743,.0092,.1308,.9991,.3284,.001,.1322,.9907,.0729,0,.1863,.941,0,0,.273,.8913,0,0,.3426,.8578,0,0,.398,.8264,0,0,.1031,.9708,1,.0179,.1039,.9802,1,.0153,.1025,.9835,.822,.0124,.1102,.9797,.5876,.0081,.1289,.97,.3442,3e-4,.1303,.9646,.0885,0,.1773,.9255,0,0,.2681,.8759,0,0,.3423,.843,0,0,.3896,.818,0,0,.1038,.9043,1,.0173,.1029,.9094,1,.0156,.101,.9138,.8289,.0143,.1076,.9161,.619,.0088,.1265,.9089,.3794,.0026,.1283,.9077,.1297,0,.1565,.8868,0,0,.2545,.8409,0,0,.3261,.8163,0,0,.3818,.7844,0,0,.1051,.8011,1,.0143,.1046,.8085,1,.0126,.105,.8129,.847,.0132,.111,.8123,.6556,.0097,.1203,.8174,.4269,.0027,.1252,.8191,.1976,0,.1315,.8142,0,0,.2201,.7788,0,0,.2989,.7436,0,0,.3517,.7102,0,0,.1116,.6646,1,.0115,.1093,.6696,1,.0099,.1092,.6742,.8569,.0102,.1104,.6809,.697,.007,.115,.6892,.4884,.0033,.1215,.6934,.2765,2e-4,.1254,.6915,.0656,0,.167,.6753,0,0,.2417,.6364,0,0,.3014,.6039,0,0,.1278,.5042,1,.0072,.1263,.5064,1,.007,.1232,.5098,.8746,.0064,.1132,.5209,.7312,.0051,.1155,.5283,.5606,.0024,.1203,.5327,.3614,1e-4,.1113,.5443,.1559,0,.1197,.546,0,0,.1868,.5102,0,0,.2362,.488,0,0,.1486,.343,1,.0019,.1463,.3452,.9936,.0019,.1431,.3477,.8939,.0017,.1319,.3547,.7615,.0015,.1266,.3615,.616,6e-4,.1225,.3683,.4332,0,.1112,.3799,.2521,0,.1049,.3892,.0563,0,.1313,.3815,0,0,.181,.3611,0,0,.1662,.1847,1,0,.1644,.1854,.9653,0,.1604,.1878,.8908,0,.1546,.1957,.7852,0,.1442,.2001,.6581,0,.1313,.2082,.5022,0,.1198,.216,.3299,0,.1051,.2283,.1565,0,.1017,.2382,0,0,.1289,.2358,0,0,.181,.0267,.9724,0,.1798,.0291,.9417,0,.177,.0324,.8756,0,.1669,.036,.7932,0,.1603,.0388,.688,0,.1479,.0453,.5508,0,.1338,.0547,.401,0,.12,.0608,.2433,0,.0964,.0737,.0742,0,.0953,.0941,0,0,.1931,0,.9284,0,.1912,0,.8978,0,.1862,0,.8364,0,.1785,0,.7585,0,.1669,0,.67,0,.1592,0,.5462,0,.1455,0,.4228,0,.13,0,.2957,0,.1107,0,.159,0,.0979,0,.0222,0,0,.9911,1,6e-4,0,.9961,.9646,0,0,.9966,.786,3e-4,0,.9854,.5724,0,0,.9791,.3242,0,.0016,.9646,.078,0,.0517,.9279,0,0,.147,.8764,0,0,.2327,.8472,0,0,.291,.8211,0,0,0,.9643,1,5e-4,0,.9666,.9648,0,0,.9639,.7975,2e-4,0,.9583,.5818,0,0,.9562,.3372,0,7e-4,.945,.0929,0,.0448,.911,0,0,.1436,.8664,0,0,.2278,.8362,0,0,.2898,.8081,0,0,0,.9038,1,0,0,.9046,.9776,0,0,.9031,.8012,0,0,.9038,.6125,0,0,.9036,.3683,0,.0017,.8925,.1374,0,.0237,.8776,0,0,.1265,.8353,0,0,.2147,.8028,0,0,.2705,.7705,0,0,0,.8132,1,0,0,.8143,.9587,0,0,.8142,.8187,0,0,.8169,.6394,0,0,.8197,.419,0,3e-4,.8147,.1967,0,.0123,.8141,0,0,.0967,.7786,0,0,.1814,.7347,0,0,.2391,.7045,0,0,0,.6897,1,0,0,.692,.9619,0,0,.6984,.83,0,0,.7019,.6733,0,0,.7045,.4747,0,9e-4,.7071,.2694,0,0,.7111,.0548,0,.0576,.6835,0,0,.1375,.6393,0,0,.2009,.6013,0,0,.0063,.5438,1,0,.0032,.546,.9485,0,.0026,.5485,.8408,0,.0013,.5558,.7051,0,5e-4,.5627,.5395,0,0,.5677,.3432,0,0,.5745,.1428,0,.0093,.5745,0,0,.0917,.5265,0,0,.1486,.4917,0,0,.0194,.3866,.9857,0,.018,.3872,.9437,0,.0163,.3924,.8468,0,.0123,.4005,.7307,0,.0073,.4035,.5867,0,7e-4,.4155,.4089,0,0,.4186,.2299,0,0,.4312,.0418,0,.0401,.4101,0,0,.1031,.3772,0,0,.0358,.2371,.9655,0,.0347,.2382,.9313,0,.0332,.2403,.8472,0,.0259,.2437,.7602,0,.019,.2518,.6265,0,.012,.2568,.4759,0,.0019,.2691,.3078,0,0,.2772,.1319,0,.0014,.2874,0,0,.0541,.2574,0,0,.055,.078,.9361,0,.0532,.0795,.9029,0,.0503,.0842,.841,0,.0428,.0887,.762,0,.0368,.0939,.6568,0,.0277,.1032,.5253,0,.0167,.1101,.3773,0,.0049,.1229,.2172,0,0,.1316,.0548,0,.0162,.1304,0,0,.0852,0,.8742,0,.0821,0,.8522,0,.0772,0,.7982,0,.0712,0,.7271,0,.0609,0,.6409,0,.0525,0,.5299,0,.04,0,.4048,0,.0242,0,.2762,0,.0145,0,.1309,0,0,0,0,0],W=Math.round(Math.pow(n.length/3,1/4)),D=[0,0,0,0];
ICC.U.applyLUT3to4Float(n,W,w,D);return D};E.fo=function(w,n,W){var D=w.length,j=.3,I=.59,U=.11;if(W){j=W[0];
I=W[1];U=W[2]}for(var L=0;L<D;L+=4)n[L>>2]=~~(w[L+0]*j+w[L+1]*I+w[L+2]*U+.5)};E.Mj=function(w,n){var W=n.length;
for(var L=0;L<W;L+=4){var D=w[L>>>2];n[L]=D;n[L+1]=D;n[L+2]=D}};E.kX=function(w,n){var W=w.dl,D=w.o,j=w.B,I=w.k,U=Math.min(w.dl.length,n.buffer.byteLength>>>2),M=4*Math.floor(U/4),m=new Uint32Array(n.buffer),l=new Uint32Array(W.buffer),A=new Uint32Array(D.buffer),g=new Uint32Array(j.buffer),k=new Uint32Array(I.buffer);
for(var L=0;L<M;L+=4){var $=l[L>>2],C=k[L>>2],f=g[L>>2],z=A[L>>2];m[L]=$<<24|(C&255)<<16|(f&255)<<8|z&255;
m[L+1]=($&65280)<<16|(C&65280)<<8|f&65280|(z&65280)>>>8;m[L+2]=($&16711680)<<8|C&16711680|(f&16711680)>>>8|(z&16711680)>>>16;
m[L+3]=$&4278190080|(C&4278190080)>>>8|(f&4278190080)>>>16|(z&4278190080)>>>24}for(var L=M;L<U;L++)m[L]=W[L]<<24|I[L]<<16|j[L]<<8|D[L]};
E.rH=function(w,n){var W=n.dl,D=n.o,j=n.B,I=n.k,U=Math.min(n.dl.length,w.buffer.byteLength>>>2),M=4*Math.floor(U/4),m=new Uint32Array(w.buffer),l=new Uint32Array(W.buffer),A=new Uint32Array(D.buffer),g=new Uint32Array(j.buffer),k=new Uint32Array(I.buffer);
for(var L=0;L<M;L+=4){var $=m[L],C=m[L+1],f=m[L+2],z=m[L+3];A[L>>2]=$&255|(C&255)<<8|(f&255)<<16|z<<24;
g[L>>2]=($&65280)>>8|C&65280|(f&65280)<<8|(z&65280)<<16;k[L>>2]=($&16711680)>>16|(C&16711680)>>8|f&16711680|(z&16711680)<<8;
l[L>>2]=$>>>24|C>>>24<<8|f>>>24<<16|z&4278190080}for(var L=M;L<U;L++){var s=m[L];D[L]=s>>0&255;j[L]=s>>8&255;
I[L]=s>>16&255;W[L]=s>>24&255}};E.hN=function(w,n,W){var D=new Uint8Array(w.buffer),j=Math.min(D.length/4,n.length);
for(var L=0;L<j;L++){n[L]=D[(L<<2)+W]}};E.IL=function(w,n,W){var D=new Uint8Array(n.buffer),j=new Uint32Array(w.buffer),I=Math.min(D.length/4,w.length),L=0;
while(L+4<I){var U=j[L>>>2];D[(L<<2)+W]=U&255;D[(L<<2)+W+4]=U>>>8&255;D[(L<<2)+W+8]=U>>>16&255;D[(L<<2)+W+12]=U>>>24;
L+=4}while(L<I){D[(L<<2)+W]=w[L];L++}};E.cJ=function(w,n,W){if(W==null)W=0;var D=new Uint32Array(w.buffer),j=D.length;
for(var L=0;L<j;L++)D[L]=D[L]&W|n};E.ae$=function(w,n,W,D,j){if(j==null)j=0;var I=new Uint32Array(w.buffer);
W=W.wU(n);var U=W.x-n.x,M=W.y-n.y,m=W.m,l=W.n,A=n.m;for(var g=0;g<l;g++){var L=(M+g)*A+U;for(var k=0;
k<m;k++){I[L]=I[L]&j|D;L++}}};E.nX=function(w,n){var W=Math.min(w.buffer.byteLength,n.buffer.byteLength),D=W>>>2,w=new Uint32Array(w.buffer,0,D),n=new Uint32Array(n.buffer,0,D);
n.set(w)};E.s9=function(w,n){var W=w.buffer.byteLength,D=n.buffer.byteLength,j=new Uint32Array(w.buffer,0,W>>2),I=new Uint32Array(n.buffer,0,D>>2);
if(W!=D)return!1;var U=j.length;for(var L=0;L<U;L++)if(I[L]!=j[L])return!1;return!0};E.Ba=function(w){var n=new Uint32Array(w.buffer),W=n.length;
for(var L=0;L<W;L++)n[L]=~n[L]};E.afz=function(w){var n=w.length;for(var L=0;L<n;L+=4){w[L]=~w[L];w[L+1]=~w[L+1];
w[L+2]=~w[L+2]}};E.a5A=function(w){var n=w.length;for(var L=3;L<n;L+=4)w[L]=~w[L]};E.a3l=function(w){return w+(w%4==0?0:4-w%4)};
E.Q=function(w,n){if(n==null)n=!1;if(!n)w=E.a3l(w);try{var W=new Uint8Array(w)}catch(fV){alert("Not enough RAM! (need "+Math.round(w/(1<<20))+" MB)",7e3);
throw"low_ram"}return W};E.L3=function(w){var n=w.length,W=w[n-2],D=w[n-1];while(D.m>=2&&D.n>=2){var j=E.VU(W,D);
w.push(j.Q0,j.rect);W=j.Q0;D=j.rect}};E.BB=function(w){var n=w.length,W=w[n-2],D=w[n-1];while(D.m>=2&&D.n>=2){var j=E.K4(W,D);
w.push(j.Q0,j.rect);W=j.Q0;D=j.rect}};E.VU=function(w,n,W){var D=n.m,j=n.n,I=D>>1,U=j>>1,M=new iB(n.x,n.y,I,U),m=W&&W.length==I*U*4?W:E.Q(I*U*4),l=new Uint32Array(w.buffer),A=new Uint32Array(m.buffer);
for(var g=0;g<U;g++)for(var k=0;k<I;k++){var $=g*I+k,C=(g<<1)*D+(k<<1),f=l[C],z=l[C+1],s=l[C+D],O=l[C+D+1],a=f>>>24,X=z>>>24,P=s>>>24,Z=O>>>24,Y=a+X+P+Z;
if(Y==1020){var K=(f>>>0&255)+(z>>>0&255)+(s>>>0&255)+(O>>>0&255)+2>>>2,S=(f>>>8&255)+(z>>>8&255)+(s>>>8&255)+(O>>>8&255)+2>>>2,G=(f>>>16&255)+(z>>>16&255)+(s>>>16&255)+(O>>>16&255)+2>>>2;
A[$]=255<<24|G<<16|S<<8|K}else if(Y==0)A[$]=0;else{var K=(f>>>0&255)*a+(z>>>0&255)*X+(s>>>0&255)*P+(O>>>0&255)*Z,S=(f>>>8&255)*a+(z>>>8&255)*X+(s>>>8&255)*P+(O>>>8&255)*Z,G=(f>>>16&255)*a+(z>>>16&255)*X+(s>>>16&255)*P+(O>>>16&255)*Z,V=1/Y;
K=~~(K*V+.5);S=~~(S*V+.5);G=~~(G*V+.5);A[$]=Y+2>>>2<<24|G<<16|S<<8|K}}return{rect:M,Q0:m}};E.Dl=function(w,n,W){var D=n.m,j=n.n,I=D>>1,U=j>>1,M=new iB(n.x,n.y,I,U),m=W&&W.length==I*U*4?W:E.Q(I*U*4),l=new Uint32Array(w.buffer),A=new Uint32Array(m.buffer);
for(var g=0;g<U;g++)for(var k=0;k<I;k++){var $=g*I+k,C=(g<<1)*D+(k<<1),f=l[C],z=l[C+1],s=l[C+D],O=l[C+D+1],a=2+(f>>>0&255)+(z>>>0&255)+(s>>>0&255)+(O>>>0&255)>>>2,X=2+(f>>>8&255)+(z>>>8&255)+(s>>>8&255)+(O>>>8&255)>>>2,P=2+(f>>>16&255)+(z>>>16&255)+(s>>>16&255)+(O>>>16&255)>>>2,Z=2+(f>>>24&255)+(z>>>24&255)+(s>>>24&255)+(O>>>24&255)>>>2;
A[$]=Z<<24|P<<16|X<<8|a}return{rect:M,Q0:m}};E.aio=function(w,n,W){var D=n.m,j=n.n,I=2*Math.floor(D/3),U=2*Math.floor(j/3),M=new iB(n.x,n.y,I,U),m=W&&W.length==I*U*4?W:E.Q(I*U*4),l=new Uint32Array(w.buffer),A=new Uint32Array(m.buffer);
for(var g=0;g<U;g+=2)for(var k=0;k<I;k+=2){var $=g*I+k,C=(g*3>>>1)*D+(k*3>>>1),f=l[C],z=l[C+1],s=l[C+2],O=l[C+D],a=l[C+1+D],X=l[C+2+D],P=l[C+D+D],Z=l[C+1+D+D],Y=l[C+2+D+D],K=f>>>24<<2,S=(f>>>16&255)*K,G=(f>>>8&255)*K,V=(f&255)*K,T=z>>>24<<1,R=(z>>>16&255)*T,x=(z>>>8&255)*T,v=(z&255)*T,N=s>>>24<<2,u=(s>>>16&255)*N,H=(s>>>8&255)*N,F=(s&255)*N,t=O>>>24<<1,o=(O>>>16&255)*t,q=(O>>>8&255)*t,_=(O&255)*t,d=a>>>24,r=(a>>>16&255)*d,p=(a>>>8&255)*d,Q=(a&255)*d,B=X>>>24<<1,i=(X>>>16&255)*B,c=(X>>>8&255)*B,h2=(X&255)*B,jX=P>>>24<<2,bm=(P>>>16&255)*jX,dC=(P>>>8&255)*jX,fn=(P&255)*jX,fK=Z>>>24<<1,i6=(Z>>>16&255)*fK,dh=(Z>>>8&255)*fK,kA=(Z&255)*fK,ig=Y>>>24<<2,iJ=(Y>>>16&255)*ig,fL=(Y>>>8&255)*ig,fB=(Y&255)*ig,ah=K+T+t+d,eS=N+T+B+d,gL=jX+fK+t+d,e_=ig+fK+B+d,c2=ah==0?0:1/ah,jS=eS==0?0:1/eS,ie=gL==0?0:1/gL,as=e_==0?0:1/e_,gb=0,gx=0,eo=0,di=0;
gb=~~(.5+(V+v+_+Q)*c2);gx=~~(.5+(G+x+q+p)*c2);eo=~~(.5+(S+R+o+r)*c2);di=~~(.5+ah*(1/9));A[$]=di<<24|eo<<16|gx<<8|gb;
gb=~~(.5+(F+v+h2+Q)*jS);gx=~~(.5+(H+x+c+p)*jS);eo=~~(.5+(u+R+i+r)*jS);di=~~(.5+eS*(1/9));A[$+1]=di<<24|eo<<16|gx<<8|gb;
gb=~~(.5+(fn+kA+_+Q)*ie);gx=~~(.5+(dC+dh+q+p)*ie);eo=~~(.5+(bm+i6+o+r)*ie);di=~~(.5+gL*(1/9));A[$+I]=di<<24|eo<<16|gx<<8|gb;
gb=~~(.5+(fB+kA+h2+Q)*as);gx=~~(.5+(fL+dh+c+p)*as);eo=~~(.5+(iJ+i6+i+r)*as);di=~~(.5+e_*(1/9));A[$+I+1]=di<<24|eo<<16|gx<<8|gb}return{rect:M,Q0:m}};
E.av_=function(w,n,W){var D=n.m,j=n.n,I=2*Math.floor(D/3),U=2*Math.floor(j/3),M=new iB(n.x,n.y,I,U),m=W&&W.length==I*U*4?W:E.Q(I*U*4),l=new Uint32Array(w.buffer),A=new Uint32Array(m.buffer);
for(var g=0;g<U;g+=2)for(var k=0;k<I;k+=2){var $=g*I+k,C=(g*3>>>1)*D+(k*3>>>1),f=l[C],z=l[C+1],s=l[C+2],O=l[C+D],a=l[C+1+D],X=l[C+2+D],P=l[C+D+D],Z=l[C+1+D+D],Y=l[C+2+D+D],K=(f>>>16&255)<<2,S=(f>>>8&255)<<2,G=(f&255)<<2,V=(z>>>16&255)<<1,T=(z>>>8&255)<<1,R=(z&255)<<1,x=(s>>>16&255)<<2,v=(s>>>8&255)<<2,N=(s&255)<<2,u=(O>>>16&255)<<1,H=(O>>>8&255)<<1,F=(O&255)<<1,t=a>>>16&255,o=a>>>8&255,q=a&255,_=(X>>>16&255)<<1,d=(X>>>8&255)<<1,r=(X&255)<<1,p=(P>>>16&255)<<2,Q=(P>>>8&255)<<2,B=(P&255)<<2,i=(Z>>>16&255)<<1,c=(Z>>>8&255)<<1,h2=(Z&255)<<1,jX=(Y>>>16&255)<<2,bm=(Y>>>8&255)<<2,dC=(Y&255)<<2,fn=0,fK=0,i6=0;
fn=~~(.5+(G+R+F+q)*(1/9));fK=~~(.5+(S+T+H+o)*(1/9));i6=~~(.5+(K+V+u+t)*(1/9));A[$]=255<<24|i6<<16|fK<<8|fn;
fn=~~(.5+(N+R+r+q)*(1/9));fK=~~(.5+(v+T+d+o)*(1/9));i6=~~(.5+(x+V+_+t)*(1/9));A[$+1]=255<<24|i6<<16|fK<<8|fn;
fn=~~(.5+(B+h2+F+q)*(1/9));fK=~~(.5+(Q+c+H+o)*(1/9));i6=~~(.5+(p+i+u+t)*(1/9));A[$+I]=255<<24|i6<<16|fK<<8|fn;
fn=~~(.5+(dC+h2+r+q)*(1/9));fK=~~(.5+(bm+c+d+o)*(1/9));i6=~~(.5+(jX+i+_+t)*(1/9));A[$+I+1]=255<<24|i6<<16|fK<<8|fn}return{rect:M,Q0:m}};
E.Ym=function(w){var n=255,W=w.length;W-=W&31;for(var L=3;L<W;L+=32)n=n&w[L]&w[L+4]&w[L+8]&w[L+12]&w[L+16]&w[L+20]&w[L+24]&w[L+28];
return n!=255};E.a3_=function(w,n,W,D){var j=E.VU,I=E.aio,M=0;if(!E.Ym(w)){j=E.Dl;I=E.av_}var U={Q0:w,rect:n},m=W;
while(m<.499){M++;m*=2}for(var L=0;L<M;L++)U=j(U.Q0,U.rect,D);if(m<.5001)U=j(U.Q0,U.rect,D);else U=I(U.Q0,U.rect,D);
return U};E.ak_=function(w,n,W,D){var j=E.K4,I=E.MQ,U={Q0:w,rect:n},M=0,m=W;while(m<.499){M++;m*=2}for(var L=0;
L<M;L++)U=j(U.Q0,U.rect,D);if(m<.5001)U=j(U.Q0,U.rect,D);else U=I(U.Q0,U.rect,D);return U};E.K4=function(w,n,W){var D=n.m,j=n.n,I=D>>1,U=j>>1,M=new iB(n.x,n.y,I,U);
if(w==null)return{rect:M};var m=W&&W.length>=I*U?W:E.Q(I*U);for(var l=0;l<U;l++){var A=l*I;for(var g=0;
g<I;g++){var k=(l<<1)*D+(g<<1);m[A+g]=2+w[k]+w[k+1]+w[k+D]+w[k+D+1]>>>2}}return{rect:M,Q0:m}};E.MQ=function(w,n,W){var D=n.m,j=n.n,I=2*Math.floor(D/3),U=2*Math.floor(j/3),M=new iB(n.x,n.y,I,U);
if(w==null)return{rect:M};var m=W&&W.length>=I*U?W:E.Q(I*U);for(var l=0;l<U;l+=2)for(var A=0;A<I;A+=2){var g=l*I+A,k=(l*3>>>1)*D+(A*3>>>1),$=w[k]<<2,C=w[k+1]<<1,f=w[k+2]<<2,z=w[k+D]<<1,s=w[k+1+D],O=w[k+2+D]<<1,a=w[k+D+D]<<2,X=w[k+1+D+D]<<1,P=w[k+2+D+D]<<2;
m[g]=~~(.5+($+C+z+s)*(1/9));m[g+1]=~~(.5+(f+C+O+s)*(1/9));m[g+I]=~~(.5+(a+X+z+s)*(1/9));m[g+I+1]=~~(.5+(P+X+O+s)*(1/9))}return{rect:M,Q0:m}};
E.aua=function(w,n,W,D,j){var I=n.wU(D);if(j)I=I.wU(j);var U=Math.max(0,I.x-n.x),M=Math.max(0,I.x-D.x),m=Math.max(0,I.y-n.y),l=Math.max(0,I.y-D.y),A=I.m,g=I.n;
for(var L=0;L<g;L++){var k=(m+L)*n.m+U,$=(l+L)*D.m+M;for(var C=0;C<A;C++){W[$+C]=Math.max(W[$+C],w[k+C])}}};
E.B0=function(w,n,W,D,j){var I=n.wU(D);if(j)I=I.wU(j);var U=Math.max(0,I.x-n.x),M=Math.max(0,I.x-D.x),m=Math.max(0,I.y-n.y),l=Math.max(0,I.y-D.y),A=I.m,g=I.n;
for(var L=0;L<g;L++){var k=(m+L)*n.m+U,$=(l+L)*D.m+M;W.set(new Uint8Array(w.buffer,k,A),$)}};E.MN=function(w,n,W,D){if(n.s9(D)){E.IL(w,W,3);
return}var j=n.wU(D),I=Math.max(0,j.x-n.x),U=Math.max(0,j.x-D.x),M=Math.max(0,j.y-n.y),m=Math.max(0,j.y-D.y),l=j.m,A=j.n;
for(var L=0;L<A;L++){var g=(M+L)*n.m+I,k=(m+L)*D.m+U;for(var $=0;$<l;$++)W[(k+$<<2)+3]=w[g+$]}};E.KB=function(w,n,W,D){var j=n.wU(D),I=Math.max(0,j.x-n.x),U=Math.max(0,j.x-D.x),M=Math.max(0,j.y-n.y),m=Math.max(0,j.y-D.y),l=j.m,A=j.n;
for(var L=0;L<A;L++){var g=(M+L)*n.m+I,k=(m+L)*D.m+U;for(var $=0;$<l;$++)W[k+$]=w[(g+$<<2)+3]}};E.Cb=function(w,n,W,D,j){if(n.s9(D)&&(j==null||j.s9(D))){E.nX(w,W);
return}w=new Uint32Array(w.buffer),W=new Uint32Array(W.buffer);var I=n.wU(D);if(j)I=I.wU(j);var U=Math.max(0,I.x-n.x),M=Math.max(0,I.x-D.x),m=Math.max(0,I.y-n.y),l=Math.max(0,I.y-D.y),A=I.m,g=I.n,k=A&3,$=k==0?A:A-k;
for(var L=0;L<g;L++){var C=(m+L)*n.m+U,f=(l+L)*D.m+M;W.set(new Uint32Array(w.buffer,C*4,A),f)}};E.Jx=function(w,n,W,D){var j=n.wU(D),I=Math.max(0,j.x-n.x),U=Math.max(0,j.x-D.x),M=Math.max(0,j.y-n.y),m=Math.max(0,j.y-D.y),l=j.m,A=j.n,g=w.dl,k=w.o,$=w.B,C=w.k,f=W.dl,z=W.o,s=W.B,O=W.k;
for(var L=0;L<A;L++){var a=(M+L)*n.m+I,X=(m+L)*D.m+U;for(var P=0;P<l;P++){f[X+P]=g[a+P];z[X+P]=k[a+P];
s[X+P]=$[a+P];O[X+P]=C[a+P]}}};E.y8=function(w){var n=w.length;for(var L=0;L<n;L+=4){var W=w[L+3];if(W==255)continue;
w[L]=~~(w[L]*W*(1/255)+.5);w[L+1]=~~(w[L+1]*W*(1/255)+.5);w[L+2]=~~(w[L+2]*W*(1/255)+.5)}};E.Hd=function(w){var n=w.length;
for(var L=0;L<n;L+=4){var W=w[L+3];if(W==0||W==255)continue;var D=255/W;w[L]=~~(w[L]*D+.5);w[L+1]=~~(w[L+1]*D+.5);
w[L+2]=~~(w[L+2]*D+.5)}};E.em=function(w,n){for(var L=0;L<w.length;L++)if(w[L]!=n)return!1;return!0};
E.DL=function(w){return w+1+(w>>>8)>>>8};E.round=function(w,n){if(n==null)n=128;var W=w.length;for(var L=0;
L<W;L++)w[L]=w[L]<n?0:255};E.D9=function(w,n){var W=w.length;for(var L=0;L<W;L++)w[L]=Math.round(w[L]*n)};
E.w5=function(w,n){var W=new Uint32Array(w.buffer),D=new Uint32Array(n.buffer),j=W.length;for(var L=0;
L<j;L++){var I=W[L],U=D[L];D[L]=E.DL((I>>>24)*(U>>>24))<<24|E.DL((I>>>16&255)*(U>>>16&255))<<16|E.DL((I>>>8&255)*(U>>>8&255))<<8|E.DL((I&255)*(U&255))}};
E.py=function(w,n){var W=w.length;for(var L=0;L<W;L++)n[(L<<2)+3]=E.DL(n[(L<<2)+3]*w[L])};E.aqV=function(w,n,W,D){var j=Math.max(0,D.x-n.x),I=Math.max(0,n.x-D.x),U=Math.max(0,D.y-n.y),M=Math.max(0,n.y-D.y),m=Math.min(n.x+n.m,D.x+D.m)-Math.max(n.x,D.x),l=Math.min(n.y+n.n,D.y+D.n)-Math.max(n.y,D.y);
for(var L=0;L<l;L++){var A=(U+L)*n.m+j,g=(M+L)*D.m+I;for(var k=0;k<m;k++){W[g]=E.DL(W[g]*w[A]);A++;g++}}};
E.AG=function(w,n,W,D){var j=Math.max(0,D.x-n.x),I=Math.max(0,n.x-D.x),U=Math.max(0,D.y-n.y),M=Math.max(0,n.y-D.y),m=Math.min(n.x+n.m,D.x+D.m)-Math.max(n.x,D.x),l=Math.min(n.y+n.n,D.y+D.n)-Math.max(n.y,D.y);
for(var L=0;L<l;L++){var A=(U+L)*n.m+j,g=((M+L)*D.m+I<<2)+3;for(var k=0;k<m;k++){W[g]=E.DL(W[g]*w[A]);
A++;g+=4}}};E.Yj=function(w,n,W,D){var j=Math.max(0,D.x-n.x),I=Math.max(0,n.x-D.x),U=Math.max(0,D.y-n.y),M=Math.max(0,n.y-D.y),m=Math.min(n.x+n.m,D.x+D.m)-Math.max(n.x,D.x),l=Math.min(n.y+n.n,D.y+D.n)-Math.max(n.y,D.y);
for(var L=0;L<l;L++){var A=((U+L)*n.m+j<<2)+3,g=((M+L)*D.m+I<<2)+3;for(var k=0;k<m;k++){W[g]=E.DL(W[g]*w[A]);
A+=4;g+=4}}};E.Bk=function(w,n){if(n==null)n=1;var W=4*n,D=w.length>>>2,j=new Float64Array(256),I=new Float64Array(256),U=new Float64Array(256),M=new Float64Array(256),m=4*Math.floor(D/n)*n,l=0;
for(var L=0;L<m;L+=W){var A=w[L+0],g=w[L+1],k=w[L+2],$=w[L+3]*n,C=$*(1/255);I[A]+=C;U[g]+=C;M[k]+=C;
l+=$}for(var L=0;L<256;L++)j[L]=I[L]+U[L]+M[L];return[j,I,U,M,D,l/255]};E.co=function(w,n){function W(Z,Y){var K=-1,S=0;
while(S<=Y){K++;S+=Z[K]}return K}function D(Z,Y){var K=256,S=0;while(S<=Y){K--;S+=Z[K]}return K}function j(Z){var Y=0,K=0;
for(var L=0;L<256;L++){K+=Z[L];Y+=Z[L]*L*(1/255)}return Y/K}var I=w[0],U=w[1]/100,M=w[2]/100,m=[],l=[];
for(var L=0;L<4;L++){var A=L==0?3:1;m[L]=W(n[L],A*U*n[5]);l[L]=D(n[L],A*M*n[5])}var g=[j(n[1]),j(n[2]),j(n[3])],k=g.slice(0);
k.sort(function(Z,Y){return Z-Y});var $=g.indexOf(k[1]),C=(g[0]+g[1]+g[2])/3,f=[];for(var L=0;L<4;L++){var z=0,s=255,O=m[L],a=l[L];
if(I==0&&L==0){z=O;s=a}if(I==1&&L!=0){z=O;s=a}if(I==2&&L!=0){var A=g[L-1]/C;s=Math.max(0,Math.min(255,l[$]*A))}var X=[z,s];
f.push(X);if(I==3&&L==0){var P=255*(1-C);X.push(P)}}return f};E.Ni=function(w,n){var W=new Uint32Array(w.buffer),D=W.length;
for(var L=0;L<D;L++){var j=W[L],I=j&255,U=j>>8&255,M=j>>16&255,m=j>>24&255;W[L]=n[I]|n[U]<<8|n[M]<<16|n[m]<<24}};
E.a8M=function(w,n,W,D,j,I,U){var M=new Uint32Array(w.buffer),m=new Uint32Array(n.buffer),l=M.length,A=0;
while(256<<A<W.length)A++;if(!U&&!I){for(var L=0;L!=l;L++){var g=M[L],k=(g&255)<<A,$=(g>>>8&255)<<A,C=(g>>>16&255)<<A,f=W[k],z=D[$],s=j[C];
m[L]=f|z<<8|s<<16|g&4278190080}return}for(var L=0;L<l;L++){var g=M[L],k=(g&255)<<A,$=(g>>>8&255)<<A,C=(g>>>16&255)<<A;
if(I)k=$=C=Math.round(k*.3+$*.59+C*.11);var f=W[k],z=D[$],s=j[C];if(U){var O=E.g7(k,$,C),a=E.g7(f,z,s);
if(O>a){var X=(O-a)/(255-a);f+=X*(255-f);z+=X*(255-z);s+=X*(255-s)}else if(a==0)f=z=s=0;else{var X=O/a;
f=X*f;z=X*z;s=X*s}}m[L]=f|z<<8|s<<16|g&4278190080}};E.Nb=function(w,n){var W=n.m,D=n.n,top=0,j=0,I=0,U=0,M=0;
M=0;for(var m=0;m<D;m++){var l=m*W;for(var L=0;L<W;L++)M|=w[l+L];if(M!=0)break;top++}if(top==D)return new iB(0,0,0,0);
M=0;for(var m=D-1;m>=0;m--){var l=m*W;for(var L=0;L<W;L++)M|=w[l+L];if(M!=0)break;I++}var A=D-I;M=0;
for(var L=0;L<W;L++){for(var m=top;m<A;m++)M|=w[m*W+L];if(M!=0)break;j++}M=0;for(var L=W-1;L>=0;L--){for(var m=top;
m<A;m++)M|=w[m*W+L];if(M!=0)break;U++}var g=new iB(n.x+j,n.y+top,W-j-U,D-top-I);return g};E.tx=function(w,n,W,D){if(D==null)D=[!0,!0,!0,!0];
if(W==null)W=0;var j=new Uint32Array(w.buffer),I=n.m,U=n.n,top=0,M=0,m=0,l=0,A=!1,g=[j[0],j[j.length-1],0][W];
A=!1;if(D[0])for(var k=0;k<U;k++){var $=k*I;for(var L=0;L<I;L++)if(j[$+L]!=g)A=!0;if(A)break;top++}A=!1;
if(D[2])for(var k=U-1;k>=0;k--){var $=k*I;for(var L=0;L<I;L++)if(j[$+L]!=g)A=!0;if(A)break;m++}A=!1;
if(D[1])for(var L=0;L<I;L++){for(var k=0;k<U;k++)if(j[k*I+L]!=g)A=!0;if(A)break;M++}A=!1;if(D[3])for(var L=I-1;
L>=0;L--){for(var k=0;k<U;k++)if(j[k*I+L]!=g)A=!0;if(A)break;l++}var C=new iB(n.x+M,n.y+top,I-M-l,U-top-m);
return C.VY()?new iB(0,0,0,0):C};E.ky=function(w){var n=E.Nb(w.channel,w.rect);if(n.s9(w.rect))return;
var W=E.Q(n.O());E.B0(w.channel,w.rect,W,n);w.channel=W;w.rect=n};E.qS=function(w){var n=E.Q(w.buffer.length>>2);
E.hN(w.buffer,n,3);var W=E.Nb(n,w.rect);if(W.s9(w.rect))return;var D=new E.Q(W.O()*4);E.Cb(w.buffer,w.rect,D,W);
w.buffer=D;w.rect=W};E.extend=function(w,n,W){if(w.rect.Yy(n))return;var D=w.rect.x0(n),j=E.Q(D.O());
if(W!=null)j.fill(W);E.B0(w.channel,w.rect,j,D);w.rect=D;w.channel=j};E.anw=function(w,n){if(n.VY()||w.rect.Yy(n))return;
var W=w.rect.x0(n),D=E.Q(W.O()*4);E.Cb(w.buffer,w.rect,D,W);w.rect=W;w.buffer=D};E.pw=function(w,n,W){if(!W.y5(w))return!1;
var D=Math.floor(w.x)-W.x,j=Math.floor(w.y)-W.y,L=j*W.m+D;return n[L]>128};E.amV=function(w,n,W){if(!W.y5(w))return!1;
var D=Math.floor(w.x)-W.x,j=Math.floor(w.y)-W.y,L=j*W.m+D;return n[4*L+3]>128};E.PL=function(w){if(E.oa.length<w){E.oa=E.Q(w);
E.oa.fill(255)}return E.oa};E.oa=E.Q(0);E.LR=function(w){if(E.ua.length<w)E.ua=E.Q(w);return E.ua};E.ua=E.Q(0);
E.H0=function(w){this.dl=E.Q(w);this.o=E.Q(w);this.B=E.Q(w);this.k=E.Q(w)};E.H0.prototype.clone=function(){var w=this.dl.length,n=new E.H0(1);
n.dl=this.dl.slice(0);n.o=this.o.slice(0);n.B=this.B.slice(0);n.k=this.k.slice(0);return n};E._.aa5=function(w,n,W,D,j){var I=j[0]+1,U=j[1],M=Math.abs(U-25)/4,m=j[2],l=m%2+m*m>>1,A=E._.a;
A.sk(n,W);var g=A.Sx(1),k=A.Sx(1),$=A.Sx(1);A.Or(w,D,m,m,l);A.Dc(D);A.t0(D,g);A.zU(g,k,I,I,1);A.zU(g,$,I,I,I*I);
A.sub($,k);A.w5(k,M);(U<25?A.sub:A.add)(g,k);A.eK(k,D);A.iu(D)};E._.ap6=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=j[0]*2.55,M=j[1],m=M>>1,l=j[2]*.25,A=I.Sx(4),g=I.Sx(1),k=I.Sx(1);I.RG(w,A,M,1,!0,m);
I.RG(w,D,M,1,!1,m);I.vH(w,g);I.OZ(g,U);I.eC(g,k,3);I.vU(D,k,A);I.xI(A,D,l)};E._.aiN=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[3]);var U=j[0]*-3+80,M=j[1]*-3+80,m=j[2]/2+.5,l=j[4],A=j[5],g=I.Sx(1),k=I.Sx(1),$=I.Sx(1),C=I.Sx(1),f=I.Sx(4),z=I.Sx(4);
I.vH(w,g);I.nX(g,k);I.ht(g,M,5);I.Yf(g,.4,0);I.eC(g,$,3);I.wy($,g,9,3,!0,27);I.nX(k,$);I.Ba($);var s=I.zI(U,5,$);
for(var L=0;L<I._W;L++){k[L]=s[255-k[L]]}I.Yf(k,.4,0);I.nX(k,$);I.eC($,C,2);I.wy(C,$,5,3,!1,15);I.w5(g,m);
I.w5($,m);I.JB(D,2155905279);I.JB(z,l);I.JB(f,A);I.vU(z,g,D);I.vU(f,$,D)};E._.ayY=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=new Uint8Array(256),M=5+10*j[1];M+=j[1]>3?(j[1]-3)*10:0;var m=~~(j[2]*.73)+50,l=Math.min(m+M,128),A=l-m,g=-255*m;
for(var L=0;L<256;L++){var k=L*65;U[L]=I.fj(g/A);g+=255}var $=I.Sx(1),C=I.Sx(1),f=I.Sx(1);I.vH(w,$);
I.nX($,f);I.eC($,C,2*j[0]+1);I.sub(C,$);I.w5($,65);I.wy($,C,9,3,!0,20);for(var L=0;L<I._W;L++){var z=f[L],s=C[L];
$[L]=s>0?~~((s*z+(255-s)*128)/255):128}I.eC($,C,3);I.wy(C,$,15,2,!0,16);I.wy(C,f,15,2,!1,15);I.IW($,f);
I.XC(f,C,2);I.l7(C,U);I.eC(C,$,2);I.sd($,D)};E._.a43=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=2*j[0]+1,M=I.NC[j[1]],m=j[2]*5.1,l=j[3],A=I.Sx(1),g=I.Sx(1),k=I.Sx(4),$=I.Sx(4);
I.JB(k,l);I.Dc(k,D);I.JZ(A,m);I.eK(A,D);I.iu(D,k);I.vH(w,g);I.eC(g,A,U);I.sub(A,g);I.w5(g,M);I.wy(g,A,9,3,!0,20);
I.vU(w,A,k);I.o$(k,D,3);I.RG(D,k,15,2,!0,16);I.RG(D,$,15,2,!1,16);I.IW(k,$);I.xI($,D,2)};E._.apx=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=(15-j[0])/4+1,M=(15-j[1])/4+1,m=j[2],l=j[3],A=I.Ae(j[4]),g=j[5]+1,k=j[6],$=j[7],C=j[8],f=I.Sx(1),z=I.Sx(1),s=I.Sx(1),O=I.Sx(1),a=I.Sx(4),X=I.Sx(4);
I.Yh(s,m,l,k);I.vH(w,z);I.eC(z,f,5);I.yA(s,f,O,g,A);I.w5(O,U);I.Es(O,2);I.Ba(f);I.yA(s,f,z,g,A);I.w5(z,M);
I.Es(z,2);I.JB(a,2155905279);I.JB(X,$);I.JB(D,C);I.vU(a,z,X);I.vU(X,O,D)};E._.a1d=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[3]);var U=j[0],M=j[1]/10,m=j[2]/10,l=I.Sx(1),A=I.Sx(1),g=I.Sx(1),k=I.Sj(),$=I.Sj(),C=I.Sj();
I.gM(l);I.eC(l,A,11);I.eC(A,l,11);I.O_(l,k);I.xO(w,l);I.nX(l,g);I.eC(l,A,9);I.eC(A,l,9);I.O_(l,$);I.JU($,C,5);
I.JU(C,$,5);I.I1(k,.8);I.aur(k,$,.8,.9);I.cj($,l,U);I.zU(l,A,2,2,1);I.zU(A,l,2,2,3);I.zU(l,A,2,2,3);
I.zU(g,l,5,5,13);I.zB(A,l,A,M);I.w1(l,A,A,m);I.yA(A,A,l,5,1);I.Dc(w,D);I.eK(l,D);I.iu(D)};E._.amD=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=j[0],M=j[1]/2,m=j[2],l=U/2,A=I.Sx(4),g=I.Sx(4);I.nX(w,D);for(var k=0;k<m;k++){I.RG(D,A,U,1,!0,l);
I.RG(D,g,U,1,!1,l);I.IW(g,A);I.o$(A,g,2);I.xI(g,D,M)}};E._.atr=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);
var U=j[0]*10,M=j[1]*4.9,m=j[2]*4.9,l=I.Sx(1),A=I.Sx(1),g=I.Sx(4),k=I.Sx(4);I.vH(w,l);I.OZ(l,I.a8a(l,U));
I.eC(l,A,3);I.RG(w,g,5,1,!1,1);I.RG(w,D,15,2,!0,16);I.vU(D,A,g);I.Dc(g,D);I.t0(D,l);I.ht(l,M,m);I.eK(l,D);
I.iu(D)};E._.awa=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[4]);var U=j[0]/20,M=[0,.75,1,1.05,1.1,1.15,1.2,1.25,1.3,1.35,1.4,1.45,1.5,1.6,1.7,1.8,2,2.5,3,3.5,4][j[1]],m=[0,.25,.5,.75,.9,1,1.1,1.2,1.3,1.4,1.5,1.6,1.7,1.8,1.9,2,2.25,2.5,3,3.5,4][j[2]],l=j[3],A=new Int16Array(256);
for(var L=0;L<256;L++){A[L]=~~((L-128)*U)}var g=I.Sx(1),k=I.Sx(1),$=I.Sx(4);I.vH(w,g);I.eC(g,k,25);I.w5(k,M);
I.Es(k,m);I.eC(k,g,25);I.gM(k);I.Xr(g,k,A);I.nX(w,D);I.JB($,l);I.vU($,g,D)};E._.avx=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=j[0]+5,M=15-j[1],m=U*U/2,l=1-(3-j[2])/10,A=~~(M*M*l-1),g=~~(M*M*(1-l));if(g==0)g=1;var k=I.Sx(1),$=I.Sx(1),C=I.Sx(1),f=I.Sx(4);
I.vH(w,C);I.zU(C,k,U,U,m);I.eC(C,$,U);I.sub(k,$);I.OZ($,1);I.Or(w,f,M,M,A);I.Or(w,D,M,M,g);I.vU(f,$,D)};
E._.a3b=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[3]);var U=(20-j[0])*.05,M=j[1]*-2.75+60,m=65-M,l=j[2]/10,A=I.Sx(1),g=I.Sx(1);
I.xO(w,g);var k=I.zI(M,m,g);I.Dc(w,D);I.t0(D,g);I.gM(A);I.HM(g,A,U);I.l7(g,k);I.w5(g,j[2]/10);I.add(A,g);
I.eK(g,D);I.iu(D)};E._.aql=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=5+j[0],M=15-j[1],m=j[2],l=U*U/2+U*U%2*1,A=1-(3-j[2])/10,g=~~(M*M*A-1),k=~~(M*M*(1-A));
if(k==0)k=1;var $=I.Sx(1),C=I.Sx(1),f=I.Sx(1),z=I.Sx(1),s=I.Sx(1);I.xO(w,C);I.XC(C,$,3);I.zU($,C,2,2,1);
var O=I.zI(20,20,C);I.l7(C,O);I.eC(C,s,5);I.zU(s,$,U,U,l);I.zU(s,C,M,M,g);I.zU(s,f,M,M,k);I.eC(s,z,U);
I.sub($,z);I.OZ(z,1);I.NE(C,z,f);I.Dc(w,D);I.eK(f,D);I.iu(D)};E._.a7D=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[5]);var U=I._W,M=I.BU,m=j[0],l=j[1],A=j[2],g=j[3],k=j[4],$=.05*m+1,C=m/100,f=m>>1,z=2*m-100,s=+(l==9),O=+(l==7),a=[4,1][s],X=[3,2][s],P=[1,2][O],Z=[2,1][O],Y=[50,75][s],K=l<4?A:(A>>1)+50,S=I._l(Y,K),G=I.YP(g),V=I.YP(k),T=I.Sx(4),R=I.Sx(4),x=I.Sx(1),v=I.Sx(1);
function N(D,S){if(K!=50){I.Cz(D,S)}}function u(w,i){for(var L=0;L<U;L++){w[L]=I.fj(w[L]+(i[L]-128)*C)}}function H(w,i){for(var L=0,c=0;
L<U;L++){w[c]=I.fj(w[c]+(i[c]-128)*C);w[c+1]=I.fj(w[c+1]+(i[c+1]-128)*C);w[c+2]=I.fj(w[c+2]+(i[c+2]-128)*C);
c+=4}}function F(w,D){I.gM(R);I.nX(w,D);H(D,R);N(D,S)}function t(i){var c=0;for(var h2=0;h2<12;h2++)c+=I.random();
return I.fj(f*(c-6)+i)}function o(w,D){I.nX(w,D);for(var L=0;L<M;L+=4){D[L]=t(D[L]);D[L+1]=t(D[L+1]);
D[L+2]=t(D[L+2])}N(D,S)}function q(w,D){I.nX(w,D);for(var L=0;L<M;L+=4){if(I.random()<C){D[L]=G[0];D[L+1]=G[1];
D[L+2]=G[2]}}N(D,S)}function _(w,D){I.gM(T);I.Or(T,R,X,X,a);I.nX(w,T);H(T,R);I.Or(T,D,5,5,13);N(D,S)}function d(w,D){I.gM(R);
I.nX(w,T);H(T,R);N(D,S);I.Or(T,D,X,X,a)}function r(w,D){I.nX(w,T);N(D,S);I.vH(T,x);for(var L=0,i=0;L<U;
L++){var c=((z-x[L]+255)*128.5+.5)/32767;if(I.random()<=c){D[i++]=V[0];D[i++]=V[1];D[i++]=V[2]}else{D[i++]=G[0];
D[i++]=G[1];D[i++]=G[2]}D[i]=w[i];i++}}function p(w,D){I.Dc(w,D);I.t0(D,x);I.XC(x,v,$);I.zU(v,x,X,X,a);
I.l7(x,S);I.eK(x,D);I.iu(D)}function Q(w){var i=0;if(l==8){for(var c=0;c<n;c++){w[i++]=~~(I.random()*255)}for(var L=1;
L<W;L++){for(var c=0;c<n;c++){w[i++]=w[c]}}}else{for(var L=0;L<W;L++){var h2=~~(I.random()*255);for(var c=0;
c<n;c++){w[i++]=h2}}}}function B(w,D){I.vH(w,x);I.gM(v);u(x,v);Q(v);u(x,v);I.o$(w,T,9);I.o$(T,R,9);I.eC(x,v,2);
I.l7(v,S);I.eC(v,x,2);I.Dc(R,D);I.eK(x,D);I.iu(D)}[F,o,q,_,_,d,r,B,B,p][l](w,D)};E._.aqg=function(w,n,W,D,j){var I=[-1e3,34,51,61,71,80,87,95,101,108,113,119,124,129,134,139,143,148,153,157,161,165,168,172,175,180,183,186,190,194,197,200,203,207,210,213,216,218,222,225,228,230,233,236,239,241,244,247,250,252,255],U=E._.a,f=0,z,L,P,Z,Y,K=0,S=1,G=255;
U.sk(n,W);U.Ur(j[3]);var M=U.Sx(1),m=U.Sx(1);U.vH(w,M);var l=j[0],A=j[1],g=A<=50?I[A]/255:1+(255-I[101-A])/255,k=j[2],$=M.length,C=new Float32Array($),s=1+1/10*l,O=(1-1/s)/2,a=16/256,X=n-1;
for(L=0;L<U._W;L++){C[L]=M[L]/255;m[L]=l==1?U.random()<1/255?G:S:S}function V(T,R){var x=T*n+R;if(m[x]!=S||T>=W||R>=n){return}var Z=C[x],v=g-Z,N=U.random(),u=N/s+O;
if(f==0||Math.abs(Y-Z)>a){z=u<=v?K:G;f=~~(U.random()*l)}else if(.1<N){f--}else{f=0}m[x]=z;Y=Z}if(k==0){for(L=0;
L<n;L++){for(P=0;P<n;P++){Z=L+P;if(Z>=n)break;V(P,X-Z)}f=0}for(L=1;L<W;L++){for(P=0;P<W;P++){Z=L+P;if(Z>=W||P>=n)break;
V(Z,X-P)}f=0}}else if(k==1){for(L=0;L<W;L++){for(P=0;P<n;P++){V(L,P)}f=0}}else if(k==2){for(L=0;L<n;
L++){for(P=0;P<n;P++){Z=L+P;if(Z>=n)break;V(P,Z)}f=0}for(L=1;L<W;L++){for(P=0;P<W;P++){Z=L+P;if(Z>=W||P>=n)break;
V(Z,P)}f=0}}else{for(L=0;L<n;L++){for(P=0;P<W;P++){V(P,L)}f=0}}U.sd(m,D)};E._.ahz=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=j[0],M=j[1],m=j[2],l=I.Sx(1),A=I.Sx(1),g=I.Sx(1),k=I.Sx(1),$=I.Sx(4),C=I.Sx(4);I.t0(w,k,3,4);
I.vH(w,l);I.zU(l,A,3,3,1);I.zU(l,g,3,3,9);I.sub(g,A);I.eC(A,l,3);I.ht(l,40,10,k);I.RG(w,D,U,2,!1,U);
I.RG(w,$,U,2,!0,U);I.JB(C,255);I.vU(D,l,C);I.vU(C,l,$);I.xI($,D,1);I.Dc(D);I.t0(D,l);I.ht(l,M,m,k);I.eK(l,D);
I.iu(D)};E._.an0=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[3]);var U=j[0],M=j[1],m=j[2]/10;U=U+M;
var l=I.Sx(1),A=I.Sx(1),g=I.Sj(),k=I.Sj();I.gM(l);I.eC(l,A,11);I.eC(A,l,11);I.O_(l,g);I.JU(g,k,5);I.JU(k,g,5);
I.I1(k,.97);I.cj(k,l,U);I.zU(l,A,M,M,1);I.xO(w,l);I.zB(A,l,A,.6);I.w1(l,A,A,m);I.yA(A,A,l,5,1);I.Dc(w,D);
I.eK(l,D);I.iu(D)};E._.as9=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=Math.abs(j[0]),M=U+[1,0,1,2,1,2,1,2,3,2,3,2,3,2,3,2,3,4,3,4,5,4,5,4,5][U],m=2*U+1,l=j[1]/10,A=l*13/15,g=I.Sx(1),k=I.Sx(1),$=I.Sx(1),C=I.Sx(1),f=I.Sx(4),z=I.Sx(4),s=I.Sx(4),O=I.Sx(4),a=I.Sx(4);
I.vH(w,g);if(j[0]>=0){I.Ba(g)}I.nX(g,$);I.eC(g,C,M);I.eC(C,g,M);I.w5(g,l);I.nX(g,k);I.eC(g,C,m);I.eC(C,g,m);
I.w5(g,A);I.JB(s,j[2]);I.JB(O,j[3]);I.JB(a,j[4]);I.vU(s,g,O,f);I.vU(a,k,f,z);I.vU(O,$,z,D);I.t0(w,$,3);
I.eK($,D,3)};E._.a77=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[5]);var U=j[0]*5.1,M=j[1]/100,m=I.uD[j[2]],l=I.Sx(1),A=I.Sx(1),g=I.Sx(1);
I.vH(w,l);I.JZ(A,255);I.gM(g);I.OZ(l,U);I.HM(A,l,.7);I.HM(g,l,M);I.yA(l,l,A,5,m);I.nX(w,D);I.an4(D,U,j[4],j[3]);
I.Dc(D);I.eK(A,D);I.iu(D)};E._.acp=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=j[0],M=4-j[1],m=11-j[2],l=I.Sx(1),A=I.Sx(1),g=I.Sx(4);
I.xO(w,A);for(var L=0;L<M;L++){I.nX(A,l);I.kw(l,A,U,U)}I.o$(w,g,U);I.Dc(g,g);I.eK(A,g);I.iu(g,g);(m<11?I.a3K:I.nX)(g,D,m)};
E._.a04=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[2]);var U=j[0]+5,M=~~(U/5+1),m=~~(U/2)+1,l=m*m,A=~~(U/3),g=I.uD[j[1]],k=new Array(256);
for(var L=0;L<256;L++){k[L]=~~(.2*(L-128))}var $=I.Sx(1),C=I.Sx(1);I.ajN(w,D,U);I.Dc(D);I.t0(D,$);I.gM(C);
I.Xr($,C,k);I.a1K(C,U,U,M,M);I.zB($,C,$,1);I.eC($,C,A);I.eC(C,$,A);I.zU($,C,m,m,l);I.yA(C,C,$,5,g);I.eK($,D);
I.iu(D)};E._.a07=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=I.Sx(1),M=I.Sx(1),m=I.Sx(1),l=I.Sj(),A=I.Sj();
I.vH(w,U);I.eC(U,M,j[2]);I.OZ(M,j[0]*5.1);I.zU(M,U,2,2,4);I.eC(U,M,3);I.eC(M,U,3);I.nX(U,m);I.eC(U,M,5);
I.eC(M,U,5);I.O_(U,l);I.JU(l,A,5);I.JU(A,l,5);I.abP(l,M,j[1]);I.Ba(M);I.zB(m,M,m,1);I.sd(m,D)};E._.agN=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=1<<7-j[2],M=I.Sx(1),m=I.Sx(1),l=I.Sx(1);I.xO(w,m);I.eC(m,M,3);I.nX(M,m);I.eC(M,l,j[0]+5);
I.sub(l,m);I.ht(m,1,j[1]);I.w5(M,1/U);I.w5(M,U);I.sub(M,m);I.Dc(w,D);I.eK(m,D);I.iu(D)};E._.aol=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[3]);var U=I.Sx(1),M=I.Sx(1),m=I.Sx(1);I.vH(w,U);I.amI(M,j[0]/50);I.eC(M,m,3);I.zU(U,M,9,9,41);
I.ht(M,j[1],j[2]);I.zB(M,m,m,.75);I.w1(M,m,M,.5);I.nX(M,U);I.zU(U,m,3,3,8);I.zB(m,M,m,.75);I.w5(m,1.2);
I.XC(m,U,1);I.eC(U,m,2);I.XC(m,U,2);I.w5(U,1.2);I.eC(U,m,2);I.sd(m,D)};E._.ajh=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=j[0]+9,M=j[1]/2,m=j[2],l=j[3],A=I.Ae(j[4]),g=j[5]+1,k=j[6],$=I.Sx(1),C=I.Sx(1),f=I.Sx(4),z=I.Sx(4);
I.Yh(C,m,l,k);I.xg(w,D,U,1,1);I.xg(D,f,U,1,1);I.ajy(f,f,z,7,M);I.w5(z,1.2);I.Es(z,1.2);I.yA(C,$,$,g,A);
I.w5($,3);I.nX(w,D);I.vU(z,$,D)};E._.auG=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[3]);var U=j[0]+4,M=U*2/5+(U%5|0);
U--;var m=j[1]*-2.75+60,l=65-m,A=j[2]/10,g=I.Sx(1),k=I.Sx(1);I.gM(g);I.xO(w,k);var $=I.zI(m,l,k);I.Dc(w,D);
I.t0(D,k);I.HM(k,g,.8);I.l7(k,$);I.w5(k,A);I.add(g,k);I.wy(k,g,U,3,!1,M);I.eK(g,D);I.iu(D)};E._.aqJ=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[3]);var U=j[0]+5,M=(U*U>>1)+U%2,m=j[1]/10,l=j[2],A=(l*l>>1)+l%2,g=I.Sx(1),k=I.Sx(1),$=I.Sx(1),C=I.Sx(4),f=I.Sx(4),z=I.Sx(4);
I.gM($);I.Dc(w,z);I.t0(z,g);I.HM(g,$,.8);I.eC($,g,3);I.XC(g,$,m);I.eK($,z);I.iu(z,z);I.vH(z,$);I.zU($,g,U,U,M);
I.eC($,k,U);I.sub(g,k);I.OZ(k,1);I.Or(z,C,7,7,40);I.Or(z,f,7,7,10);I.vU(C,k,f);I.Or(f,D,l,l,A)};E._.aw$=function(w,n,W,D,j){var I=E._.a,M=255,L,l;
I.sk(n,W);var U=j[0];if(U<2)M=U;else if(U<12)M=5*U-5;else if(U<47)M=2*U+28;else if(U<50){L=U-47;M=125+12.5*L+12.5*L*L}var m=new Uint8Array(256);
for(L=75,l=15;L<256;L++,l+=24)m[L]=Math.min(255,l);var A=I.Sx(1),g=I.Sx(1),k=I.Sx(1);I.vH(w,A);I.eC(A,g,11);
I.eC(g,k,11);I.sub(k,A);I.w5(A,8);I.sub(k,A);I.OZ(A,M);I.Ba(A);I.eC(A,g,5);I.OZ(g,51);I.eC(g,A,j[1]);
I.eC(A,g,j[1]);I.Ba(g);I.l7(g,m);I.sd(g,D)};E._.a1U=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=I.NC[j[1]],M=j[2],m=M*1.5,l=I.Sx(1),A=I.Sx(1),g=I.Sx(1);
I.xO(w,l);I.wy(l,A,15,2,!0,15);I.nX(A,g);I.ht(g,M,m);I.eC(g,l,3);I.eC(A,g,j[0]);I.sub(g,A);I.w5(A,U);
I.sub(l,A);I.eC(A,l,3);I.wy(l,A,3,1,!1,1);I.o$(w,D,15);I.Dc(D);I.eK(A,D);I.iu(D)};E._.axP=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);I.Ur(j[3]);var U=j[0]*5.1,M=16-j[1],m=[1,1,1.05,1.1,1.15,1.2,1.25,1.3,1.35,1.4,1.45,1.5,1.6,1.7,1.8,2,2.25,2.5,2.75,3,3.5,4,5,6,8,10][j[2]],l=I.Sx(1),A=I.Sx(1),g=I.Sx(1);
I.vH(w,l);I.OZ(l,U);I.eC(l,A,M);I.eC(A,l,M);I.gM(g);I.w1(l,g,g,1);I.zB(l,g,l,.75);I.w5(l,m);I.Es(l,m);
I.zU(l,A,2,2,2);I.sd(A,D)};E._.amW=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);var U=j[0]+9,M=j[1]+9,m=j[2],l=j[3],A=I.Ae(j[4]),g=j[5]+1,k=j[6],$=I.Sx(1),C=I.Sx(1),f=I.Sx(1),z=I.Sx(1),s=I.Sx(1),O=I.Sx(4);
I.xO(w,$);I.kw($,f,U,U);I.eC(f,$,M);I.nX(f,s);I.nX($,z);I.sub(s,z);I.sub($,s);I.add(s,z);I.w5(z,10);
I.Yh(C,m,l,k);I.yA(C,$,s,g,A);I.NE(s,z,f,.8);I.o$(w,O,9);I.o$(O,D,9);I.Dc(D);I.eK(f,D);I.iu(D)};E._.aoO=function(w,n,W,D,j){var I=E._.a;
I.sk(n,W);var U=16-j[0],M=j[1]*8,m=1-(3-j[2])/10,l=~~(U*U*m-1),A=~~(U*U*(1-m));if(A==0)A=1;var g=I.Sx(1),k=I.Sx(1),$=I.Sx(1),C=I.Sx(4);
I.vH(w,$);I.zU($,g,7,7,25);I.eC($,k,7);I.sub(g,k);I.OZ(k,1);I.Or(w,C,U,U,l);I.Or(w,D,U,U,A);I.vU(C,k,D);
I.Dc(D);I.t0(D,g);I.zU(g,$,3,3,1);I.zU(g,k,3,3,9);I.sub(k,$);I.nX($,k);I.sub(g,$);I.sub($,k);I.zU(k,g,3,3,8);
I.ht(g,M,1);I.eK(g,D);I.iu(D)};E._.a6y=function(w,n,W,D,j){var I=E._.a;I.sk(n,W);I.Ur(j[3]);var U=j[0],M=j[1],m=j[2],l=U>>1,A=Math.max(~~(U/5),1),g=Math.max(~~(U*2/3),1),k=I._l(M,m),$=I.Sx(1),C=I.Sx(1),f=I.Sx(1),z=I.Sx(1),s=I.Sx(4);
I.xO(w,$);I.OC(2147483647,4,2,2,0,255,C);I.OC(4,2147483647,2,2,0,255,z);I.gM(f);I.w1(C,f,C,1);I.w1(z,f,z,1);
I.w1(C,$,C,1);I.w1(z,$,z,1);I.o$(w,s,l);I.o$(s,D,l);I.zU(C,$,1,U,A);I.zU($,C,3,U,g);I.zU(z,$,U,1,A);
I.zU($,z,U,3,g);I.IW(C,z);I.Dc(D);I.eK(z,D);I.iu(D);I.Cz(D,k)};E._.uj=function(w,n,W){var D=W.atU,j=W._W,I=W.Sx(1),top=W.Sx(1),U=W.Sx(1),M=W.Sx(1),m=W.Sx(1),l=W.Sx(1),A=W.Sx(1),g=W.Sx(1),k=W.Sx(1),$=W.gA,C=W.ag,f=E.Z3.Zu,z=E.Z3.kd;
f(w,I,$,C,z([8,5,2,5,2,-1,2,-1,-4]));f(w,top,$,C,z([5,5,5,2,2,2,-1,-1,-1]));f(w,U,$,C,z([2,5,8,-1,2,5,-4,-1,2]));
f(w,M,$,C,z([5,2,-1,5,2,-1,5,2,-1]));f(w,m,$,C,z([2,2,2,2,2,2,2,2,2]));f(w,l,$,C,z([-1,2,5,-1,2,5,-1,2,5]));
f(w,A,$,C,z([2,-1,-4,5,2,-1,8,5,2]));f(w,g,$,C,z([-1,-1,-1,2,2,2,5,5,5]));f(w,k,$,C,z([-4,-1,2,-1,2,5,2,5,8]));
var s=[I,top,U,M,m,l,A,g,k];for(var O=0;O<C;O++){for(var a=0;a<$;a++){var X=O*$+a,P=w[X],Z=null,Y=0;
for(var K=-1;K<2;K++){for(var S=-1;S<2;S++){var G=s[(K+1)*3+S+1],V=Math.max(0,Math.min(O+K,C-1)),T=Math.max(0,Math.min(a+S,$-1)),R=G[V*$+T],x=Math.abs(R-P);
if(Z==null||x<Z){Z=x;Y=R}}}n[X]=Y}}};E._.ado=function(w,n,W,D,j){var self=E._.a;self.sk(n,W);var I=self.Sx(1),U=self.Sx(1);
for(var L=0;L<4;L++){self.t0(w,I,L);if(L<3){E._.uj(I,U,self);E._.uj(U,I,self);E._.uj(I,U,self);E._.uj(U,I,self);
E._.uj(I,U,self);E._.uj(U,I,self);E._.uj(I,U,self);E._.uj(U,I,self);E._.uj(I,U,self)}else U=I;self.eK(U,D,L)}};
E._.a={};E._.a.gA=0;E._.a.ag=0;E._.a._W=0;E._.a.cx=0;E._.a.BU=0;E._.a.sk=function(w,n){var W=w*n,self=E._.a;
self.gA=w;self.ag=n;self._W=W;self.cx=W<<1;self.BU=W<<2};E._.a.Ur=function(w){E._.a.random=function(){var n=w+=1831565813;
n=Math.imul(n^n>>>15,n|1);n^=n+Math.imul(n^n>>>7,n|61);return((n^n>>>14)>>>0)/4294967296}};E._.a.Sx=function(w){var n=E._.a;
return new Uint8Array([-1,n._W,n.cx,-1,n.BU][w])};E._.a.Sj=function(){return new Int32Array(E._.a.cx)};
E._.a.eC=function(w,n,W,D){if(D==null)D=W;var self=E._.a,j=self.gA,I=self.ag,U=D,M=D>>1,m=W,l=W>>1,A=W*D,g=0;
for(var L=0;L<I;L++){var k=0;for(var $=0;$<U;$++){for(var C=0;C<m;C++){var f=0-l+C,z=L-M+$;if(f<0)f=0;
else if(f>=j)f=j-1;if(z<0)z=0;else if(z>=I)z=I-1;k+=w[z*j+f]}}n[g++]=~~(k/A);for(var s=1;s<j;s++){for(var $=0;
$<U;$++){var O=s-l-1,a=O+m,z=L-M+$;if(O<0)O=0;if(a>=j)a=j-1;if(z<0)z=0;else if(z>=I)z=I-1;k+=w[z*j+a]-w[z*j+O]}n[g++]=~~(k/A)}}};
E._.a.JU=function(w,n,W,D){var self=E._.a,j=new Int32Array(self._W),I=new Int32Array(self._W);for(var L=0;
L<2;L++){self.t0(w,j,L,2);self.eC(j,I,W,D);self.eK(I,n,L,2)}};E._.a.o$=function(w,n,W,D){var self=E._.a,j=self.Sx(1),I=self.Sx(1);
for(var L=0;L<4;L++){self.t0(w,j,L);if(L<3)self.eC(j,I,W,D);else I=j;self.eK(I,n,L)}};E._.a.xg=function(w,n,W,D,j){var self=E._.a,I=self.gA,U=self.ag,M=W+D-1,m=W>>1,l=M>>1,A=0,g=W*D,k=new Int32Array(W);
for(var L=0;L<U;L++){var $=0,C=0,f=0;for(var z=0;z<W;z++){var s=j?M-z-D:z;for(var O=s,a=D+s;O<a;O++){var X=0-l+O,P=L-m+z;
if(O==s){k[z]=X}if(X<0)X=0;else if(X>=I)X=I-1;if(P<0)P=0;else if(P>=U)P=U-1;var Z=I*P+X<<2;$+=w[Z];C+=w[Z+1];
f+=w[Z+2]}}n[A++]=~~($/g);n[A++]=~~(C/g);n[A++]=~~(f/g);n[A]=w[A];A++;for(var Y=1;Y<I;Y++){for(var z=0;
z<W;z++){var P=L-m+z,s=k[z]+1;k[z]=s;var K=s-1,S=s+D-1;if(P<0)P=0;else if(P>=U)P=U-1;if(K<0)K=0;else if(K>=I)K=I-1;
if(S<0)S=0;else if(S>=I)S=I-1;var G=P*I+K<<2,V=P*I+S<<2;$=$+w[V]-w[G];C=C+w[V+1]-w[G+1];f=f+w[V+2]-w[G+2]}n[A++]=~~($/g);
n[A++]=~~(C/g);n[A++]=~~(f/g);n[A]=w[A];A++}}};E._.a.wy=function(w,n,W,D,j,I){var self=E._.a,U=self.gA,M=self.ag,m=W+D-1,l=W>>1,A=m>>1,g=0,k=new Int32Array(W),$=new Int32Array(256),C=new Int32Array(16);
for(var L=0;L<M;L++){for(var f=0;f<256;f++){$[f]=0}for(var f=0;f<16;f++){C[f]=0}for(var z=0;z<W;z++){var s=j?m-z-D:z;
for(var O=s,a=D+s;O<a;O++){var X=0-A+O,P=L-l+z;if(O==s){k[z]=X}if(X<0)X=0;else if(X>=U)X=U-1;if(P<0)P=0;
else if(P>=M)P=M-1;$[w[P*U+X]]++;C[w[P*U+X]>>>4]++}}var Z=0,Y=0;while(Z+C[Y>>>4]<I){Z+=C[Y>>>4];Y+=16}for(;
Y<256;Y++){Z+=$[Y];if(Z>=I)break}n[g++]=Y;for(var f=1;f<U;f++){for(var z=0;z<W;z++){var P=L-l+z,s=k[z]+1;
k[z]=s;var K=s-1,S=s+D-1;if(P<0)P=0;else if(P>=M)P=M-1;if(K<0)K=0;else if(K>=U)K=U-1;if(S<0)S=0;else if(S>=U)S=U-1;
$[w[P*U+K]]--;$[w[P*U+S]]++;C[w[P*U+K]>>>4]--;C[w[P*U+S]>>>4]++}Z=0;Y=0;while(Z+C[Y>>>4]<I){Z+=C[Y>>>4];
Y+=16}for(;Y<256;Y++){Z+=$[Y];if(Z>=I)break}n[g++]=Y}}};E._.a.RG=function(w,n,W,D,j,I){var self=E._.a,U=self.Sx(1),M=self.Sx(1);
for(var L=0;L<4;L++){self.t0(w,U,L);if(L<3)self.wy(U,M,W,D,j,I);else M=U;self.eK(M,n,L)}};E._.a.zU=function(w,n,W,D,j){j=Math.min(D*W,j);
var self=E._.a,I=self.gA,U=self.ag,M=D>>1,m=W>>1,l=0,A=new Int32Array(D),g=new Int32Array(256),k=new Int32Array(16);
for(var L=0;L<U;L++){for(var $=0;$<256;$++){g[$]=0}for(var $=0;$<16;$++){k[$]=0}for(var C=0;C<D;C++){for(var f=0,z=W;
f<z;f++){var s=0-m+f,O=L-M+C;if(f==0){A[C]=s}if(s<0)s=0;else if(s>=I)s=I-1;if(O<0)O=0;else if(O>=U)O=U-1;
g[w[O*I+s]]++;k[w[O*I+s]>>>4]++}}var a=0,X=0;while(a+k[X>>>4]<j){a+=k[X>>>4];X+=16}for(;X<256;X++){a+=g[X];
if(a>=j)break}n[l++]=X;for(var $=1;$<I;$++){for(var C=0;C<D;C++){var O=L-M+C,P=A[C]+1;A[C]=P;var Z=P-1,Y=P+W-1;
if(O<0)O=0;else if(O>=U)O=U-1;if(Z<0)Z=0;else if(Z>=I)Z=I-1;if(Y<0)Y=0;else if(Y>=I)Y=I-1;g[w[O*I+Z]]--;
g[w[O*I+Y]]++;k[w[O*I+Z]>>>4]--;k[w[O*I+Y]>>>4]++}a=0;for(X=0;X<256;X++){a+=g[X];if(a>=j)break}n[l++]=X}}};
E._.a.Or=function(w,n,W,D,j){var self=E._.a,I=self.Sx(1),U=self.Sx(1);for(var L=0;L<4;L++){self.t0(w,I,L);
if(L<3)self.zU(I,U,W,D,j);else U=I;self.eK(U,n,L)}};E._.a.XC=function(w,n,W){var self=E._.a,D=self.gA,j=self.ag,I=0;
for(var L=0;L<j;L++){var U=L*D,M=(L-1)*D,m=(L+1)*D;if(M<0)M=U;if(m>=j)m=U;for(var l=0;l<D;l++){var A=l-1,g=l+1;
if(A<0)A=l;if(g>=D)g=l;var k=U+A,$=U+g,C=M+l,f=m+l,z=U+l,s=w[k],O=w[$],a=w[C],X=w[f],P=w[z],Z=P+(P*4*W+.5);
Z=Z-((s+O+X+a)*W+.5);n[I++]=self.fj(Z)}}};E._.a.xI=function(w,n,W){var self=E._.a,D=self.Sx(1),j=self.Sx(1);
for(var L=0;L<4;L++){self.t0(w,D,L);if(L<3)self.XC(D,j,W);else j=D;self.eK(j,n,L)}};E._.a.a3K=function(w,n,W){var self=E._.a,D=self.gA,j=self.ag,I=0,U=W+4;
for(var L=0;L<j;L++){var M=L*D,m=(L-1)*D,l=(L+1)*D;if(m<0)m=M;if(l>=j)l=M;for(var A=0;A<D;A++){var g=A-1,k=A+1;
if(g<0)g=A;if(k>=D)k=A;var $=M+g<<2,C=M+k<<2,f=m+A<<2,z=l+A<<2,s=M+A<<2;for(var O=0;O<3;O++){var a=w[$+O],X=w[C+O],P=w[f+O],Z=w[z+O],Y=w[s+O];
n[I++]=(Y*W+a+X+Z+P)/U}n[I]=w[I];I++}}};E._.a.kw=function(w,n,W,D){var self=E._.a,j=self.gA,I=self.ag,U=W>>1,M=D>>1,m=0,l=new Int32Array(W),A=new Int32Array(256);
for(var L=0;L<I;L++){for(var g=0;g<256;g++){A[g]=0}for(var k=0;k<W;k++){for(var $=0,C=D;$<C;$++){var f=0-M+$,z=L-U+k;
if($==0){l[k]=f}if(f<0)f=0;else if(f>=j)f=j-1;if(z<0)z=0;else if(z>=I)z=I-1;A[w[z*j+f]]++}}var s=0,O=0;
for(var a=0;a<256;a++){if(s<A[a]){O=a;s=A[a]}}n[m++]=O;for(var g=1;g<j;g++){for(var k=0;k<W;k++){var z=L-U+k,X=l[k]+1;
l[k]=X;var P=X-1,Z=X+D-1;if(z<0)z=0;else if(z>=I)z=I-1;if(P<0)P=0;else if(P>=j)P=j-1;if(Z<0)Z=0;else if(Z>=j)Z=j-1;
A[w[z*j+P]]--;A[w[z*j+Z]]++}s=0;O=0;for(var a=0;a<256;a++){if(s<A[a]){O=a;s=A[a]}}n[m++]=O}}};E._.a.aAq=[function(w,n,W,D,j,I,U,M,m,l){return j+(w+n+W)*l-(m+M+U)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(n+W+I)*l-(M+U+D)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(W+I+m)*l-(U+D+w)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(I+m+M)*l-(D+w+n)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(m+M+U)*l-(w+n+W)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(M+U+D)*l-(n+W+I)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(U+D+w)*l-(W+I+m)*l},function(w,n,W,D,j,I,U,M,m,l){return j+(D+w+n)*l-(I+m+M)*l}];
E._.a.yA=function(w,n,W,D,j){var self=E._.a,I=self.gA,U=self.ag,M=I,m=self.aAq[D-1];for(var L=0;L<U;
L++){var l=(L>0?L-1:0)*M,A=L*M,g=(L<U?L+1:L)*M;for(var k=0;k<I;k++){var $=k>0?k-1:0,C=k<I?k+1:k,f=A+k,z=w[l+$],s=w[l+k],O=w[l+C],a=w[A+$],X=n[f],P=w[A+C],Z=w[g+$],Y=w[g+k],K=w[g+C];
W[f]=self.fj(m(z,s,O,a,X,P,Z,Y,K,j))}}};E._.a.ajy=function(w,n,W,D,j){var self=E._.a,I=self.Sx(1),U=self.Sx(1),M=self.Sx(1);
for(var L=0;L<3;L++){self.t0(w,I,L);self.t0(n,U,L);self.yA(I,U,M,D,j);self.eK(M,W,L)}self.t0(n,I,3);
self.eK(I,W,3)};E._.a.vH=function(w,n){var W=w.length,D=0;for(var L=0;L<W;L++){n[D++]=~~((w[L++]+w[L++]+w[L++]+2)/3)}};
E._.a.sd=function(w,n){var W=n.length,D=0;for(var L=0;L<W;L++){var j=w[L];n[D++]=j;n[D++]=j;n[D++]=j;
n[D++]=255}if(n[0]==255)n[0]--;else n[0]++};E._.a.xO=function(w,n){var W=n.length,D=0;for(var L=0;L<W;
L++){var j=w[D++],I=w[D++],U=w[D++];D++;if(I>j)j=I;if(U>j)j=U;n[L]=j}};E._.a.Dc=function(w,n){if(n==null)n=w;
var W=w.length;for(var D=0;D<W;D+=4){var j=w[D],I=w[D+1],U=w[D+2],M=j,m=0,l=j,g;if(I<=j){j=I}else{m=1;
l=I}if(U<=l){if(j>U){j=U}}else{m=2;l=U}var A=l-j;if(A!=0){if(m==0){g=~~(43*(I-U)/A)}else if(m==1){g=~~(43*(U+2*A-M)/A)}else{g=43*(M+4*A-I)/A}if(g<0){g=255&g-1}n[D]=g;
n[D+1]=~~(255*A/l)}else{n[D]=A;n[D+1]=A}n[D+2]=l;n[D+3]=w[D+3]}};E._.a.iu=function(w,n){if(n==null)n=w;
var W=w.length;for(var D=0;D<W;D+=4){var j=w[D],I=w[D+1],U=w[D+2];if(I){if(j==255)j=0;var M=~~(6*j/255),m=~~(-255*M+6*j);
if(M==0){n[D]=U;n[D+1]=~~(U*(255-I*(255-m)/255)/255);n[D+2]=~~(U*(255-I)/255)}else if(M==1){n[D]=~~(U*(255-I*m/255)/255);
n[D+1]=U;n[D+2]=~~(U*(255-I)/255)}else if(M==2){n[D]=~~(U*(255-I)/255);n[D+1]=U;n[D+2]=~~(U*(255-I*(255-m)/255)/255)}else if(M==3){n[D]=~~(U*(255-I)/255);
n[D+1]=~~(U*(255-I*m/255)/255);n[D+2]=U}else if(M==4){n[D]=~~(U*(255-I*(255-m)/255)/255);n[D+1]=~~(U*(255-I)/255);
n[D+2]=U}else{n[D]=U;n[D+1]=~~(U*(255-I)/255);n[D+2]=~~(U*(255-I*m/255)/255)}}else{n[D]=U;n[D+1]=U;n[D+2]=U}n[D+3]=w[D+3]}};
E._.a.eK=function(w,n,W,D){if(W==null)W=2;if(D==null)D=4;var j=w.length;for(var L=0;L<j;L++){n[W]=w[L];
W+=D}};E._.a.t0=function(w,n,W,D){if(W==null)W=2;if(D==null)D=4;var j=n.length;for(var L=0;L<j;L++){n[L]=w[W];
W+=D}};E._.a.NE=function(w,n,W,D){if(D==null)D=1;var j=n.length,I=0,U;for(var I=0;I<j;I++){U=n[I];if(U){U*=D;
W[I]=~~((U*w[I]+(255-U)*W[I])/255)}}};E._.a.vU=function(w,n,W,D){if(D==null)D=W;var j=n.length,I=0,U,M;
for(var L=0;L<j;L++){U=n[L];if(U){M=255-U;D[I]=~~((U*w[I]+M*W[I])/255);D[I+1]=~~((U*w[I+1]+M*W[I+1])/255);
D[I+2]=~~((U*w[I+2]+M*W[I+2])/255)}D[I+3]=w[I+3];I+=4}};E._.a.zB=function(w,n,W,D){var j=~~(D*255),I=W.length;
for(var L=0;L<I;L++){W[L]=((255-j*(255-w[L])/255)*n[L]+w[L]*(j*(255-w[L])/255))/255}};E._.a.w1=function(w,n,W,D){var j=~~(D*255),I=W.length;
for(var L=0;L<I;L++){W[L]=((255-j*w[L]/255)*n[L]+w[L]*(j*w[L]/255))/255}};E._.a.HM=function(w,n,W){var D=n.length;
for(var L=0;L<D;L++){n[L]=~~(w[L]*W+.5)+(n[L]-~~(n[L]*W+.5))}};E._.a.sub=function(w,n){var W=w.length;
for(var L=0;L<W;L++){n[L]=Math.max(w[L]-n[L],0)}};E._.a.add=function(w,n){var W=w.length;for(var L=0;
L<W;L++){n[L]=Math.min(w[L]+n[L],255)}};E._.a.atU=function(w,n){var W=w.length;for(var L=0;L<W;L++){n[L]=w[L]+n[L]}};
E._.a.IW=function(w,n){var W=w.length;for(var L=0;L<W;L++){n[L]=w[L]+n[L]>>1}};E._.a.nX=function(w,n){var W=w.length;
for(var L=0;L<W;L++){n[L]=w[L]}};E._.a.l7=function(w,n){var W=w.length;for(var L=0;L<W;L++){w[L]=n[w[L]]}};
E._.a.Cz=function(w,n){var W=E._.a.BU;for(var L=0;L<W;L+=4){var D=w[L],j=w[L+1],I=w[L+2],U=D;if(j>D)U=j;
if(I>D)U=I;var M=n[U];if(M){w[L]=~~(M*D/U);w[L+1]=~~(M*j/U);w[L+2]=~~(M*I/U)}else{w[L]=M;w[L+1]=M;w[L+2]=M}}};
E._.a.w5=function(w,n){for(var L=0,W=w.length;L<W;L++){w[L]=Math.min(255,~~(.5+w[L]*n))}};E._.a.Es=function(w,n){for(var L=0,W=w.length;
L<W;L++){w[L]=255-Math.min(255,~~(.5+(255-w[L])*n))}};E._.a.Ba=function(w){var n=w.length;for(var L=0;
L<n;L++){w[L]=255-w[L]}};E._.a.OZ=function(w,n,W,D){if(W==null)W=0;if(D==null)D=255;for(var L=0,j=w.length;
L<j;L++){w[L]=w[L]>=n?D:W}};E._.a.YP=function(w){return[w>>24&255,w>>16&255,w>>8&255,w&255]};E._.a.an4=function(w,n,W,D){if(W==null)W=255;
if(D==null)D=4278190335;var j=E._.a,I=j.BU,U=j.YP(W),M=j.YP(D);for(var L=0;L<I;L+=4){var m=~~((w[L]+w[L+1]+w[L+2]+2)/3);
if(m>=n){w[L]=U[0];w[L+1]=U[1];w[L+2]=U[2]}else{w[L]=M[0];w[L+1]=M[1];w[L+2]=M[2]}}};E._.a.JB=function(w,n){var W=E._.a,D=W.BU,j=W.YP(n);
for(var L=0;L<D;){w[L++]=j[0];w[L++]=j[1];w[L++]=j[2];w[L++]=j[3]}};E._.a.JZ=function(w,n){var W=w.length;
for(var L=0;L<W;){w[L++]=n}};E._.a._l=function(w,n){w=w>5?(100-Math.max(4,w))/100:.95;n=n!=100?Math.max(4,n)/100:.9995;
var W=new Uint8Array(256),D=n>.5?.5/(1-n):n*2,j=~~(D*256),I=~~((.5-w*D)*256)<<8;for(var L=0;L<256;L++){W[L]=E._.a.fj(I>>8);
I+=j}return W};E._.a.gM=function(w){for(var L=0,n=E._.a,W=w.length;L<W;L++){w[L]=~~(n.random()*256)}};
E._.a.amI=function(w,n){for(var L=0,W=E._.a,D=w.length;L<D;L++){w[L]=W.random()<n?255:0}};E._.a.Yf=function(w,n,W){for(var L=0,D=E._.a,j=w.length;
L<j;L++){if(D.random()<n)w[L]=W}};E._.a.Xr=function(w,n,W){var D=w.length;for(var L=0;L<D;L++){w[L]=E._.a.fj(w[L]+W[n[L]])}};
E._.a.mA=function(w){var n=new Uint32Array(256);for(var L=0,W=w.length;L<W;L++)n[w[L]]++;return n};E._.a.ayz=function(w,n){var W=0,D=0,j=new Uint32Array(256),I=new Float32Array(256);
for(var L=0,U=w.length;L<U;L++){var M=w[L],m=n[L];if(m==255){j[M]++;W++}else if(m>0){m/=255;D+=m;I[M]+=m;
if(D>=1){D--;W++}if(I[M]>=1){I[M]--;j[M]++}}}return[W,j]};E._.a.zI=function(w,n,W,D){var self=E._.a,j,I,A=0,k=256;
if(D){var U=self.ayz(W,D);j=U[1];I=U[0]/100}else{j=self.mA(W);I=self._W/100}var M=new Uint8Array(256),m=I*w,l=I*n,g=-1;
do{A+=j[++g]}while(A<=m);A=0;do{A+=j[--k]}while(A<=l);if(k-g<=0)k=g+1;if(k>255){k=255;g=254}var $=255/(k-g),C=-g;
for(var L=0;L<256;L++){M[L]=self.fj($*C+.5);C++}return M};E._.a.ht=function(w,n,W,D){var j=E._.a;j.l7(w,j.zI(n,W,w,D))};
E._.a.a8a=function(w,n){var self=E._.a,W=self.mA(w),D=self._W*n/100,j=0,I=-1;do{j+=W[++I]}while(j<=D);
return I};E._.a.O_=function(w,n){var W=0,self=E._.a,D=self.gA,j=self.ag,I=1/Math.PI,U=I*255;for(var L=0;
L<j;L++){var M=L+1;if(M==j)M--;var m=L*D,l=~~((1-(L+1)/j)*255);for(var A=0;A<D;A++){var g=A+1;if(g==D)g--;
var k=w[m+A],$=w[m+g],C=w[M*D+A];if(k-C==0){n[W++]=l}else{var f=k-C+255;if(f==255){f=0}else{f=~~(Math.atan2(1/(255-f),1)*U+.5);
if(f<0)f+=255}n[W++]=f}if(k-$==0){n[W++]=~~((1-(A+1)/D)*255)}else{var f=k-$+255;if(f==255){f=0}else{f=~~(Math.atan2(1/(255-f),1)*U+.5);
if(f<0)f+=255}n[W++]=f}}}};E._.a.I1=function(w,n){var self=E._.a,W=self.gA,D=self.ag,j=0;for(var L=0;
L<D;L++){for(var I=0;I<W;I++){w[j]=~~(L*n+.5)+~~(w[j]*(1-n)+.5);j++;w[j]=~~(I*n+.5)+~~(w[j]*(1-n)+.5);
j++}}};E._.a.aur=function(w,n,W,D){var self=E._.a,j=self.gA,I=self.ag,U=0;for(var L=0;L<I;L++){for(var M=0;
M<j;M++){n[U]=~~(n[U]*(1-W)+.5)+~~(w[U]*D+.5);U++;n[U]=~~(n[U]*(1-W)+.5)+~~(w[U]*D+.5);U++}}};E._.a.cj=function(w,n,W){var self=E._.a,D=self.gA,j=self.ag,I=0,U=0;
for(var L=0;L<j;L++){for(var M=0;M<D;M++){var m=w[I++],l=w[I++];n[U++]=l%W>=2&&m%W>=2?255:0}}};E._.a.OC=function(w,n,W,D,j,I,U){var self=E._.a,M=self.gA,m=self.ag,l=0,A=0,g=0;
for(var L=0;L<m;L++){var k=L%w<W||m-W<=L;for(var $=0;$<M;$++){U[l++]=k||$%n<D||M-D<=$?j:I}}};E._.a.Yh=function(w,n,W,D){var self=E._.a,j=self.gA,I=self.ag;
self.OC(8,8,4,4,0,255,w)};E._.a.fj=function(w){return~~Math.min(255,Math.max(0,w))};E._.a.NC=[0,5,10,15,20,25,35,45,65,85,105,125,145,165,185,205];
E._.a.uD=[0,.2,.4,.5,.6,.7,.8,.9,1,1.1,1.2,1.3,1.4,1.5,1.7,2,2.5,3,3.5,4,5,6,7,8,9,10];E._.a.Ae=function(w){return w>40?[1.25,1.5,1.75,2,2.5,3,4,5,7.5,10][w-41]:w/40};
E._.a.ajN=function(w,n,W){var self=E._.a,D=self.gA,j=self.ag,I=W,U=W>>1,M=U-1,m=I*I,l=0;for(var L=0;
L<j;L++){var A=0,g=0,k=0,$=~~(L/W)*W,C=0;for(var f=0;f<I;f++){for(var z=0;z<I;z++){var s=C+z,O=$+f;if(s>=D)s=D-1;
if(O>=j)O=j-1;A+=w[O*D+s<<2];g+=w[(O*D+s<<2)+1];k+=w[(O*D+s<<2)+2]}}var a=~~(A/m),X=~~(g/m),P=~~(k/m);
n[l]=a;n[l+1]=X;n[l+2]=P;n[l+3]=w[l+3];l+=4;for(var Z=1;Z<D;Z++){for(var f=0;f<I;f++){var Y=Z-1,K=Y+I,O=$+f;
if(K>=D)K=D-1;if(O>=j)O=j-1;var S=O*D,G=S+K<<2,V=S+Y<<2;A+=w[G]-w[V];g+=w[G+1]-w[V+1];k+=w[G+2]-w[V+2]}if(Z%W==0){a=~~(A/m);
X=~~(g/m);P=~~(k/m)}n[l]=a;n[l+1]=X;n[l+2]=P;n[l+3]=w[l+3];l+=4}}};E._.a.a1K=function(w,n,W,D,j){var self=E._.a,I=self.gA,U=self.ag,M=0,m=0,l=0,A=0;
for(var L=A;L<U+A;L++){var g=L%n>=D||L<D||U+A-D<=L;for(var k=0;k<I;k++){w[M++]=g&&(k%W>=j||k<j||I-j<=k)?255:0}}};
E._.a.abP=function(w,n,W){var D=function(l,A){return A<=l?l/A&1?A-l%A:l%A:l},j=[function(M,m){return D(M,255)/255},function(M,m){return(255+D(M,255)-D(m,255))/510},function(M,m){return(255-D(m,255))/255},function(M,m){return(510-D(M,255)-D(m,255))/510},function(M,m){return(255-D(M,255))/255},function(M,m){return(255-D(M,255)+D(m,255))/510},function(M,m){return D(m,255)/255},function(M,m){return(D(M,255)+D(m,255))/510}][W],I=0,U=0;
for(var L=0;L<E._.a._W;L++){var M=w[I++],m=w[I++];n[U++]=~~(255*j(M,m))}};E._.a9r=function(){var w=[],n=new Uint8Array(512),W=new Float32Array(512),D=new Float32Array(512),j=[1,-1,1,-1,1,-1,0,0],I=[1,1,-1,-1,0,0,1,-1],U=0,M,C=0;
for(;U<256;U++)w[U]=U;while(U!=0){U--;M=Math.floor(Math.random()*U);w[M]^=w[U]^(w[U]=w[M])}function m(m){m=Math.floor(m*65536);
if(m<256){m|=m<<8}for(var L=0;L<256;L++){var s=L+256,O=w[L]^(L&1?m:m>>8)&255;n[L]=n[s]=O;O=O%8;W[L]=W[s]=j[O];
D[L]=D[s]=I[O]}}function l(s){return s*s*s*(s*(s*6-15)+10)}function A(s,O,a){return(1-a)*s+a*O}function g(s,O){return s&O}function k(s,O){return s%O}function $(s,O,a,X,P){var Z=Math.floor(s),Y=Math.floor(O),U,K,S,G,V,T;
s=s-Z;O=O-Y;Z=Z&255;Y=Y&255;U=Z+n[Y];G=W[U]*s+D[U]*O;U=Z+n[P(Y+1,X)];S=W[U]*s+D[U]*(O-1);U=P(Z+1,a)+n[Y];
V=W[U]*(s-1)+D[U]*O;U=P(Z+1,a)+n[P(Y+1,X)];T=W[U]*(s-1)+D[U]*(O-1);K=l(s);return A(A(G,V,K),A(S,T,K),l(O))}function f(s,U,O){s[U]=O}function z(s,O,a,X,P){var Z=Math.min(Math.min(O,256),Math.min(256,a)),Y=Z==256||Z<8,K=8,S=new Uint32Array(K),G=new Uint32Array(K),V=new Float32Array(K),T=new Float32Array(K),R=1,x=1,v=Y?g:k,N=f,u;
for(var L=0;L<K;L++){u=x*1/Z;if(Y){G[L]=(1<<Math.ceil(Math.log2(a*u)))-1;S[L]=(1<<Math.ceil(Math.log2(O*u)))-1}else{G[L]=u*a;
S[L]=u*O}V[L]=R;T[L]=u;R*=.5;x=x<<1}m(Math.random());for(var H=0,U=0;H<a;H++){for(var F=0;F<O;F++){var t=0;
for(var o=0;o<K;o++){u=T[o];t+=$(F*u,H*u,S[o],G[o],v)*V[o]}N(X,U++,Math.round(Math.max(0,255*Math.min(1,.5+t*.5))))}}}return z}();
E._.atI=function(){function w(n,W,D,j){var I=new Uint8Array(n.length>>>2),U=new Uint8Array(n.length>>>2),M=new Uint8Array(n.length);
for(var L=0;L<n.length;L+=4){var m=n[L+0]*.3+n[L+1]*.59+n[L+2]*.11;U[L>>>2]=m;M[L]=n[L];M[L+1]=n[L+1];
M[L+2]=n[L+2]}E.Z3.fp(U,I,W,D);E.Z3.yz(n,j,W,D,E.Z3.eq[1],0,!0);for(var L=0;L<n.length;L+=4){M[L+3]=255-I[L>>>2]}for(var L=0,l=n.length;
L<l;L+=4){var A=M[L+3]/255;j[L]=M[L]*A+j[L]*(1-A);j[L+1]=M[L+1]*A+j[L+1]*(1-A);j[L+2]=M[L+2]*A+j[L+2]*(1-A)}}return w}();
E._.aad=function(){function w(I,U,M,m,l){var A=new Uint32Array(I.buffer),g=0;for(var L=0;L<M;L++){for(var k=0;
k<U;k++,g+=4){var $=A[L*U+k],C=$&255,f=$>>>8&255,z=$>>>16&255,s=$>>>24&255,O=~~(Math.random()*8),a=O%3,X=0,P=0;
if(O<3){P--}else if(O>4){P++}if(a==0){X--}else if(a==2){X++}var Z=k+X,Y=L+P;if(Z<0)Z=0;else if(Z>U-1)Z=U-1;
if(Y<0)Y=0;else if(Y>M-1)Y=M-1;var $=A[Y*U+Z],K=$&255,S=$>>>8&255,G=$>>>16&255,V=$>>>24&255;m[g]=l(C,K);
m[g+1]=l(f,S);m[g+2]=l(z,G);m[g+3]=l(s,V)}}}function n(I,U){return U}function W(I,U){return I>U?U:I}function D(I,U){return I<U?U:I}function j(I,U,M,m,l){var A=l[0];
if(A==0)w(I,U,M,m,n);else if(A==1)w(I,U,M,m,W);else if(A==2)w(I,U,M,m,D);else if(A==3){console.error("Not implemented")}else console.error("Mew mew")}return j}();
E._.aqv=function(){function w(n,W,D,j,I){var U=I&&I[0]?I[0]:4,M,m,l,A,g,k,$;for(var L=0;L<D;L++){var C=Math.max(L-U,0),f=Math.min(L+U,D-1);
for(var z=0;z<W;z++){var s=Math.max(z-U,0),O=Math.min(z+U,W-1);M=C*W+s<<2;A=n[M];g=n[M+1];k=n[M+2];$=n[M+3];
M=C*W+O<<2;A+=n[M];g+=n[M+1];k+=n[M+2];$+=n[M+3];M=f*W+s<<2;A+=n[M];g+=n[M+1];k+=n[M+2];$+=n[M+3];M=f*W+O<<2;
A+=n[M];g+=n[M+1];k+=n[M+2];$+=n[M+3];M=L*W+z<<2;j[M]=A+2>>>2;j[M+1]=g+2>>>2;j[M+2]=k+2>>>2;j[M+3]=$+2>>>2}}}return w}();
E._.akX=function(){function w(n,W,D,j){var I=new Uint8Array(n.length),U=new Uint8Array(n.length>>>2),M=new Uint8Array(n.length>>>2);
E.Z3.yz(n,I,W,D,E.Z3.eq[2],0,!0);for(var L=0;L<n.length;L+=4){var m=I[L+0]*.3+I[L+1]*.59+I[L+2]*.11;
U[L>>>2]=m;j[L+0]=n[L+0];j[L+1]=n[L+1];j[L+2]=n[L+2];j[L+3]=n[L+3]}E.Z3.fp(U,M,W,D);for(var L=0;L<n.length;
L+=4){I[L+3]=~~(Math.max(0,255-M[L>>>2]-50)*(255/205))}for(var L=0,l=n.length;L<l;L+=4){var A=I[L+3]/255;
j[L]=I[L]*A+j[L]*(1-A);j[L+1]=I[L+1]*A+j[L+1]*(1-A);j[L+2]=I[L+2]*A+j[L+2]*(1-A)}}return w}();E._.jW=function(){function w(O,a){return O[a]+O[a+1]+O[a+2]+O[a+3]}function n(O,a){return O[a]+O[a+1]+O[a+2]+2*O[a+3]}function W(O,a,X,P){O[a]=X[P];
O[a+1]=X[P+1];O[a+2]=X[P+2];O[a+3]=X[P+3]}function D(O,a,X){O[a]=O[X];O[a+1]=O[X+1];O[a+2]=O[X+2];O[a+3]=O[X+3]}function j(O,a,X){O[X]=a[X];
O[X+1]=a[X+1];O[X+2]=a[X+2];O[X+3]=255-a[X+3]}function I(O){for(var L=0,a=O.length;L<a;L+=4){O[L+3]=255-O[L+3]}}function U(){var O=Math.random();
if(O>.5)return 0;if(O>.25)return 1;if(O>.1)return 2;if(O>.02143)return 3;if(O>.00445)return 4;if(O>65e-5)return 5;
if(O>415e-6)return 6;if(O>55e-6)return 7;return 8}function M(O,a,X,P,Z,Y){O[a]=X[P]+(Z[Y]-X[P]>>1);O[a+1]=X[P+1]+(Z[Y+1]-X[P+1]>>1);
O[a+2]=X[P+2]+(Z[Y+2]-X[P+2]>>1);O[a+3]=X[P+3]+(Z[Y+3]-X[P+3]>>1)}function m(O,a,X,P,Z,Y){O[a]=Z[Y]+X[P]>>1;
O[a+1]=Z[Y+1]+X[P+1]>>1;O[a+2]=Z[Y+2]+X[P+2]>>1;O[a+3]=Z[Y+3]+X[P+3]>>1}function l(O,a,X,P,Z,Y,K,S,G){var V=0,T=0,R=0,L,x=Z[Y],v;
M(S,0,O,a,O,X);for(L=0;L<x;L++){M(S,(L+1)*4,S,L*4,O,X)}T=(x+1)*4;R+=x;Y--;W(O,a,S,T-4);P[Y]=w(O,a);a-=G;
while(Y>0&&P[Y-1]<P[Y]){v=S;S=K;K=v;V=T;m(S,0,O,a-G,K,0);for(L=4;L<V;L+=4){m(S,L,S,L-4,K,L)}x=Z[Y];for(L=R;
L<x;L++){M(S,T,S,T-4,K,V-4);T+=4;R++}Y--;W(O,a,S,T-4);P[Y]=w(O,a);a-=G}}function A(O,a,X,P,Z){var Y=a*4,K=0,S,G,V=new Uint8Array(a+1),T=new Uint8Array(10*4),R=new Uint8Array(10*4);
for(var L=0;L<X;L++){j(P,O,K);Z[0]=w(P,K);V[0]=U();S=K;K+=4;for(var x=1;x<a;x++){j(P,O,K);Z[x]=w(P,K);
G=U();V[x]=G;if(Z[x-1]<Z[x]&&G>0){l(P,K-4,K,Z,V,x,T,R,4)}K+=4}Z[a]=Z[0];V[a]=V[0];if(Z[a-1]<Z[a]&&G>0){l(P,K,S,Z,V,a,T,R,4)}}I(P)}function g(){var O=Math.random();
if(O>.659755)return 0;if(O>.1625)return 10;if(O>.06)return 20;if(O>.01)return 30;if(O>.0035)return 40;
if(O>65e-5)return 50;if(O>415e-6)return 60;if(O>55e-6)return 70;return 80}function k(O,a,X,P,Z,Y){var K=g()+1,S=P[Z];
for(var L=1;L<K;L++){if(0>Z)break;if(P[Z-L]<S){D(O,a,X)}else{break}a+=Y}}function $(O,a,X,P,Z){var Y=a*4,K=0;
for(var L=0;L<X;L++){j(P,O,K);Z[0]=w(P,K);K+=4;for(var S=1;S<a;S++){j(P,O,K);Z[S]=w(O,K);if(Z[S-1]<Z[S]){k(P,K-4,K,Z,S,-4)}K+=4}Z[a]=Z[0];
if(Z[S-1]<Z[S]){k(P,K-4,K-Y,Z,S,-4)}}I(P)}function C(O,a,X,P,Z,Y){var K=1,S,G,V=new Uint8Array(4),T,R=a;
while(Math.random()<1/K){R=a;if(P<=1)break;S=X[P];G=X[P-1];if(S<=G)break;W(V,0,O,R-Y);T=!0;for(var L=P;
L<Z;L++){if(G>X[L]){W(O,R-Y,V,0);X[L-1]=G;T=!1;break}W(O,R-Y,O,R);X[L-1]=X[L];R+=Y}if(T){W(O,R-Y,V,0);
X[Z-1]=G}K++;P--;a-=Y}}function f(O,a,X,P,Z){var Y=0,K=0,S=a*4;for(var L=0;L<X;L++){K=Y;for(var G=0;
G<a;G++){j(P,O,Y);Z[G]=n(P,Y);Y+=4}Y=K;for(var G=1;G<a;G++){if(Z[G-1]<Z[G]&&Math.random()<.66){C(P,Y+4,Z,G,a,4)}Y+=4}Y+=4}I(P)}function z(O,a,X,P,Z){var Y=Z[0],K=Z[1],S=new Uint16Array(a+1),G=O,V=P,T;
if(K){T=P.slice(0);s(O,P,a,X);G=P;V=T}if(Y==0)A(G,a,X,V,S);else if(Y==1)$(G,a,X,V,S);else if(Y==2)f(G,a,X,V,S);
if(K){s(T,P,a,X)}}function s(O,a,X,P){for(var Z=0;Z<P;Z++)for(var Y=0;Y<X;Y++){var K=Z*X+Y<<2,S=Z*X+(X-1-Y)<<2;
a[S]=O[K];a[S+1]=O[K+1];a[S+2]=O[K+2];a[S+3]=O[K+3]}}return z}();E._.yt=function(w,n,W,D,j){var I=E._.a,U=1,z=0,a=0;
I.sk(n,W);I.Ur(j[2]);var M=3<<13,m=Math.PI/2.43,l=m/256,A=Math.PI*2/256;function g(){var Y=I.random()*256,K=I.random()*256;
return U*~~(Math.tan(m-Y*l)*325*Math.cos(K*A)*256)+M>>16}U=j[0];var k=j[1],$=(k+2)/2,C=I.random()*255,f=I.Sx(1);
for(var L=0;L<W;L++){var s=I.fj(g()+C);for(var O=0;O<n;O++){s=I.fj(g()+s);f[z++]=s}}z=n;for(var L=1;
L<W;L++){var X=I.fj(g()+f[a++]);f[z++]=X;for(var O=1;O<n;O++){var P=a+1;if(O+1==n){P--}var Z=($+X+f[P]+f[a]*k)/(k+2);
X=I.fj(g()+Z);f[z++]=X;a++}}I.sd(f,D)};var e1=function(){function w(d){d=d^61^d>>>16;d=d+(d<<3);d=d^d>>>4;
d=d*668265261;d=d^d>>>15;return d}var n=function(){var n=function(d){if(d){this.dl=d}this.dl=w(this.dl);
return(this.dl&16777215)*(1/16777215)};return n};function W(d,r){if(r==null){r=[0,0]}return Math.sqrt((r[0]-d[0])*(r[0]-d[0])+(r[1]-d[1])*(r[1]-d[1]))}function D(d,r){if(r==null){r=[0,0]}return[-(r[1]-d[1])/W(d,r),(r[0]-d[0])/W(d,r)]}function j(d){return[Math.cos(d),Math.sin(d)]}function I(d){var r=W(d,[0,0]),p=[d[0]/r,d[1]/r],Q=Math.atan(p[1]/p[0]);
if(p[0]>0&&p[1]<0){Q+=2*Math.PI}else if(p[0]<0&&p[1]<0){Q+=Math.PI}else if(p[0]<0&&p[1]>0){Q+=Math.PI}return Q}function U(d){var U=0;
for(var L=1;L<d.length/2;++L){U+=W([d[2*L],d[2*L+1]],[d[2*(L-1)],d[2*(L-1)+1]])}return U}function M(d,r,p){var Q=new Float32Array(d.length),B=1/(d.length/2),i=P(p);
for(var L=0;L<d.length/2;++L){var c=L*B,h2=c/2+.5,jX=1,bm=0;if(p.shape==2){jX=1/(2*h2)}if(p.shape==3){h2=(1-c)/2+.5;
jX=1/(2*h2)+.5}if(p.shape==4){h2=c;jX=Math.sin(3/2*Math.PI*h2)/4+1}if(p.shape==5){h2=(c-.5)*6;jX=(-Math.atan(h2)/1.25+1)/5+.6-.2*c}var dC=[null,null];
if(L==0){dC=D([d[2*L],d[2*L+1]],[d[2*(L+1)],d[2*(L+1)+1]])}else if(L==d.length/2-1){dC=D([d[2*(L-1)],d[2*(L-1)+1]],[d[2*L],d[2*L+1]])}else{dC=D([d[2*(L-1)],d[2*(L-1)+1]],[d[2*(L+1)],d[2*(L+1)+1]])}Q[2*L]=d[2*L]+(jX*r+bm)*dC[0];
Q[2*L+1]=d[2*L+1]+(jX*r+bm)*dC[1];if(p.style==2){Q[2*L]+=Z(2*L/Q.length,i,p)}}return Q}function m(d,r,p){var Q=new Float32Array(d.length),B=1/(d.length/2);
for(var L=0;L<d.length/2;++L){var i=L*B,c=[null,null],h2=.6*p.s3*S(i,r.agC)*p._X/100,jX=.6*p.s3*S(i,r.auC)*p._X/100,bm=r.a41*h2+(1-r.a41)*jX;
if(L==0){c=D([d[2*L],d[2*L+1]],[d[2*(L+1)],d[2*(L+1)+1]])}else if(L==d.length/2-1){c=D([d[2*(L-1)],d[2*(L-1)+1]],[d[2*L],d[2*L+1]])}else{c=D([d[2*(L-1)],d[2*(L-1)+1]],[d[2*(L+1)],d[2*(L+1)+1]])}Q[2*L]=d[2*L]+bm*c[0];
Q[2*L+1]=d[2*L+1]+bm*c[1]}return Q}function l(d){if(d.g$==1){return[.150684932,.205479452,.465753425,.178082192]}else if(d.g$==2){return[.126829268,.131707317,.156097561,.317073171,.141463415,.126829268]}else{var r=[],p=1/(R(d)-1);
for(var L=0;L<R(d)-1;++L){r.push(p)}return r}}function A(d,r,p){var Q=[],B=r-d,i=d;for(var L=0;L<p.length-1;
++L){Q.push(i+p[L]*B);i=Q[L]}return Q}function g(d,r,p,Q){var B=new Float32Array(p.length),i=0,c={shape:Math.floor(Q.random()*2.99),aoQ:Q.random()*.1+.15};
for(var L=0;L<p.length-1;++L){var h2=i+p[L];B[L]=((1-h2)*d+h2*r)*s(Q,h2,c);i=h2}return B}function k(d,r,p,Q){var B=V(Q),i=Q.random(),c=i*20+(1-i)*26,h2=new Float32Array(p.length),jX=0;
for(var L=0;L<p.length-1;++L){var bm=jX+p[L];h2[L]=(1-bm)*d+bm*r+B/c*(2/3*Math.sin(Math.PI*bm)+1/3*Math.sqrt(Math.sin(Math.PI*bm)));
jX=bm}return h2}function $(d,r,p){var Q=[];for(var L=0;L<r.length-1;++L){Q.push(r[L].slice());var B=L*(R(p)-1),i=(L+1)*(R(p)-1),c=d[i]-d[B];
for(var h2=B+1;h2<i;++h2){var jX=P(p),bm=new Float32Array(r[0].length),dC=(d[h2]-d[B])/c;for(var fn=0;
fn<r[0].length/2;++fn){bm[2*fn]=(1-dC)*r[L][2*fn]+dC*r[L+1][2*fn];bm[2*fn+1]=(1-dC)*r[L][2*fn+1]+dC*r[L+1][2*fn+1];
if(p.style==2){bm[2*fn]+=Z(2*fn/r[0].length,jX,p)}}Q.push(bm)}}Q.push(r[r.length-1]);return Q}function C(d,r,p){var Q=new Array(r.length),B=t(d),c=null;
for(var L=0;L<r.length;++L){Q[L]=M(B,(r[L]-.5)*p._X,p)}var i=1+.05*p.axc*V(p)/V({g$:1});for(var L=0;
L<r.length;++L){if(r[L]==0){c=L}}for(var L=0;L<r.length;++L){var h2=(p.random()-.5)*2,jX=Math.round(p.random()*9+1),bm=new Float32Array(jX*2+2);
for(var dC=0;dC<=jX;++dC){bm[2*dC]=Q[L][0]-(Q[L][2*dC]-Q[L][0]);bm[2*dC+1]=Q[L][1]-(Q[L][2*dC+1]-Q[L][1])}if(L==c){h2*=.1}for(var dC=(Q[L].length-1)/2;
dC>jX;--dC){Q[L][2*dC]=(1-h2)*Q[L][2*dC]+h2*(Q[L][2*(dC-jX)]+i*(Q[L][2*dC]-Q[L][2*(dC-jX)]));Q[L][2*dC+1]=(1-h2)*Q[L][2*dC+1]+h2*(Q[L][2*(dC-jX)+1]+i*(Q[L][2*dC+1]-Q[L][2*(dC-jX)+1]))}for(var dC=jX-1;
dC>=0;--dC){Q[L][2*dC]=(1-h2)*Q[L][2*dC]+h2*(bm[2*(jX-dC)]+i*(Q[L][2*dC]-bm[2*(jX-dC)]));Q[L][2*dC+1]=(1-h2)*Q[L][2*dC+1]+h2*(bm[2*(jX-dC)+1]+i*(Q[L][2*dC+1]-bm[2*(jX-dC)+1]))}}var fn=K(r,p);
if(p.s3>0){var fK=0;for(var L=0;L<r.length;++L){if(L==0){fK+=r[L]}else{fK+=Math.abs(r[L]-r[L-1])}var i6=fK-Math.floor(fK),dh=1;
if(i6==0){dh=0}Q[L]=m(Q[L],{agC:fn[Math.floor(fK)],auC:fn[Math.floor(fK)+dh],a41:i6},p)}}return Q}function f(d,r){var p=N(r,d),Q=u(r,d),B=[],i=[],c=[],h2=l(d);
for(var L=0;L<r.length-1;++L){B.push(r[L]);i.push(p[L]);c.push(Q[L]);var jX=A(r[L],r[L+1],h2),bm=g(p[L],p[L+1],h2,d),dC=k(Q[L],Q[L+1],h2,d);
for(var fn=0;fn<jX.length;++fn){B.push(jX[fn]);i.push(bm[fn]);c.push(dC[fn])}}B.push(r[r.length-1]);
i.push(p[p.length-1]);c.push(Q[Q.length-1]);return{asc:B,axm:i,Gx:c}}function z(d,r,p,Q){var B=new Float32Array(2*Q),i=d.length/2,c=i-r,h2=p*c,jX=h2/Q;
for(var L=0;L<Q;++L){var bm=Math.floor(r+L*jX),dC=Math.ceil(r+L*jX),p=r+L*jX,fn=dC-bm,fK=1,i6=0;if(fn!=0){fK=(dC-p)/fn;
i6=(p-bm)/fn}B[2*L]=fK*d[2*bm]+i6*d[2*dC];B[2*L+1]=fK*d[2*bm+1]+i6*d[2*dC+1]}return B}function s(d,r,p){var Q=p.aoQ,B=r*2*Math.PI,i=B,c=0;
if(p.shape==0){c=(Math.sin(2*i+Math.PI/2)+1)/2}else if(p.shape==1){c=(Math.sin(i+Math.PI/2)+1)/2}else{c=(4*Math.sin(3/4*i+Math.PI)+Math.sin(Math.PI/2+2*i)-2*i/Math.PI+6)/7}return Math.min(1,1-Q+Q*c)}function O(d,r,p,Q){var B=[];
for(var L=0;L<d.length;++L){B.push(z(d[L],r[L],p[L],Q))}return B}function a(d,r,p){var Q=[];for(var L=0;
L<d.length;++L){var B=j(2*Math.PI*p.random()),i=j(2*Math.PI*p.random()),c=p.DP*.5*x({g$:1})/x(p),h2=c*p._X/200,jX=c*r/500,bm=new Float32Array(d[0].length);
for(var dC=0;dC<d[0].length/2;++dC){var fn=j(2*Math.PI*p.random()),fK=2*dC/d[0].length;bm[2*dC]=d[L][2*dC]+h2*(fn[0]+((1-fK)*B[0]+fK*i[0]));
bm[2*dC+1]=d[L][2*dC+1]+jX*(fn[1]+((1-fK)*B[1]+fK*i[1]))}Q.push(bm)}return Q}function X(d,r,p){var Q=p.v8,B=2/Q,i=[1/10,1/30,1/40,1/45,1/100],c=i[p.g$-1],h2=4*(p.opacity/25*B*c)*(1-p.DP/150),fn=0,i6=0;
if(p.style==3){return h2*.09}var jX=2.2*(d-.5),bm=jX*jX*jX*jX+.27+Math.max(0,(p.opacity-50)/15),dC=2*(Math.sin(3*Math.PI*r)/(Math.PI*r+2)+1.1)-r/2;
r=2*r;if(r<.41){var fK=2*Math.PI*r/.41;fn=(Math.sin(fK-Math.PI/2)+1)/4+.5}else if(r<.77){var fK=2*Math.PI*(r-.41)/.36;
fn=(Math.sin(fK-Math.PI/2)+1)/4+.5-fK/2/Math.PI*.5}else{var fK=2*Math.PI*(r-.77)/.23;fn=(Math.sin(fK-Math.PI/2)+1)/2*.12}fn*=3;
fn+=Math.max(0,(p.opacity-50)/15);if(p.type==6){i6=dC}else{i6=fn}return h2*bm*i6}function P(d){return{c:d.random()*7/2+.5,T2:d.random()*2*Math.PI}}function Z(d,r,p){return p._X/300*R({g$:1})/R(p)*10*(Math.sin(r.c*2*Math.PI*d+r.T2)+10*(p.random()-.5))}function Y(d){var r=Math.exp(-d.s3/25);
return{c:d.random()*3/2+.5,T2:d.random()*2*Math.PI,Ak:(d.random()-.5)*10*r}}function K(d,r){var p=Math.ceil(H(d)),Q=[];
for(var L=0;L<=p;++L){Q.push(Y(r))}return Q}function S(d,r){var p=r.c*4*Math.PI*d+r.T2;return Math.exp(-1/2*Math.PI*d)*Math.cos(p)*Math.cos(p)*Math.cos(p)*Math.cos(p)*Math.cos(p)+d*r.Ak-r.Ak/4}function G(d,r,p,Q,B){var i=0,c=x(r)-1;
for(var L=0;L<c;++L){for(var h2=0;h2<d.length-1;h2+=R(r)-1){for(var jX=L;jX<d[0].length/2-c;jX+=c){for(var bm=h2;
bm<h2+(R(r)-1);++bm){p[B+i]=X(bm*(r.v8-1)/(d.length-1)%1,jX/d[0].length,r);var dC=0,fn=0;if(r.type==6&&bm!=0&&bm!=d.length-1){fn=(d[bm][2*(jX+1)+1]-d[bm][2*jX+1])/2;
dC=(d[bm][2*(jX+1)]-d[bm][2*jX])/2}Q[8*B+8*i]=d[bm][2*jX]+dC;Q[8*B+8*i+1]=d[bm][2*jX+1]+fn;Q[8*B+8*i+2]=d[bm][2*(jX+c)]+dC;
Q[8*B+8*i+3]=d[bm][2*(jX+c)+1]+fn;Q[8*B+8*i+4]=d[bm+1][2*(jX+c)];Q[8*B+8*i+5]=d[bm+1][2*(jX+c)+1];Q[8*B+8*i+6]=d[bm+1][2*jX];
Q[8*B+8*i+7]=d[bm+1][2*jX+1];++i}}}}}function V(d){var r=[100,300,500,700,1e3];return r[d.g$-1]}function T(d){var r=[30,70,100,140,300];
return r[d.g$-1]}function R(d){var r=[5,7,26,40,100];return r[d.g$-1]}function x(d){if(d.g$==1){return 4}else if(d.g$==2){return 8}else{return Math.floor(T(d)/9)}}function v(d){var r=d.v8,p=new Float32Array(r),Q=null;
for(var L=0;L<r;++L){p[L]=d.random()}if(d.v8<=3){p[0]=0;p[d.v8-1]=1}else{for(var L=0;L<2;++L){var B=Math.floor(d.random()*r);
if(Q==null||Q!=B){p[B]=L;Q=B}else{p[B+1]=L}}}return p}function N(d,r){var p=[],Q=.2,i=0;for(var L=0;
L<d.length;++L){var B=r.random()*(1-Q)+Q;p.push(B)}var c=Math.min(3,r.v8);for(var L=0;L<d.length;++L){if(p[L]>.9){++i}}while(i<c){var h2=Math.floor(r.random()*d.length);
if(p[h2]<=.9){p[h2]=.9+.1*r.random();++i}}return p}function u(d,r){var p=V(r),Q=V({g$:1}),B=[];for(var L=0;
L<d.length;++L){B.push(Math.max(1,(r.random()*10+2)*p/Q))}return B}function H(d){var r=0;for(var L=0;
L<d.length;++L){if(L==0){r+=d[L]}else{r+=Math.abs(d[L]-d[L-1])}}return r}function F(d,r){if(d.length/2-1==V(r)){return d}var p=new Float32Array(2*(V(r)+1)),Q=(d.length-2)/(p.length-2);
for(var L=0;L<p.length/2;++L){var B=L*Q,i=Math.floor(B),c=Math.ceil(B),h2=c-i,jX=1,bm=0;if(h2!=0){jX=(c-B)/h2;
bm=(B-i)/h2}p[2*L]=jX*d[2*i]+bm*d[2*c];p[2*L+1]=jX*d[2*i+1]+bm*d[2*c+1]}return p}function t(d,r){var p=d.length/2,Q=U(d),B=Q/p,i=!1,jX=0,bm=0,dC=1;
if(r){var c=Math.floor(Q/r.ayD),h2=r.ayD;if(r.aiU&&d[0]==d[d.length-2]&&d[1]==d[d.length-1]){i=!0;h2=Q/(c+1)}if(r.type==2&&!i&&h2*c+r.length>Q){p=c+1}else{p=c+2}B=h2}var fn=new Float32Array(p*2);
fn[0]=d[0];fn[1]=d[1];for(var L=1;L<p;++L){while(jX<=L*B){bm=jX;jX+=W([d[2*dC],d[2*dC+1]],[d[2*(dC-1)],d[2*(dC-1)+1]]);
++dC}var fK=1-(L*B-bm)/(jX-bm);fn[2*L]=(1-fK)*d[2*dC]+fK*d[2*(dC-1)];fn[2*L+1]=(1-fK)*d[2*dC+1]+fK*d[2*(dC-1)+1]}fn[fn.length-2]=d[d.length-2];
fn[fn.length-1]=d[d.length-1];return fn}function o(d,r){var p=t(d,r),Q=[];for(var L=0;L<(p.length-2)/2;
++L){var B=[];B.push(p[2*L]);B.push(p[2*L+1]);var i=W([p[2*(L+1)],p[2*(L+1)+1]],[p[2*L],p[2*L+1]]),c=[(p[2*(L+1)]-p[2*L])/i,(p[2*(L+1)+1]-p[2*L+1])/i],h2=j((r.ayf-90)/360*2*Math.PI),jX=c;
if(r.type==3){jX=h2}else if(r.type==4){jX=j(I(c)+I(h2))}else if(r.type==5){jX=j(((r.random()-.5)*r.ayf-90)/360*2*Math.PI)}var bm=r.length;
if(r.a8I){bm=2*r.random()*r.length}B.push(p[2*L]+jX[0]*bm);B.push(p[2*L+1]+jX[1]*bm);Q.push(B)}return Q}function q(d){if(d.aq_){d.DB=100*Math.random()}else{d.DB=d.aiO}d.random=new n;
d.random(d.DB);if(d.type==6){d.v8=2;d.shape=5;d.axc=0}}function _(d,r){d=F(d,r);var p=[d],bm=0;if(r.type>=2&&r.type<6){p=o(d,r)}var Q=x(r)-1,B=T(r)-Q,i=(r.v8-1)*(R(r)-1),c=p.length*B*i,h2=new Float32Array(c),jX=new Float32Array(8*c);
for(var L=0;L<p.length;++L){for(var dC=0;dC<1e4;++dC){r.DB=w(r.DB)}r.random(r.DB);var d=F(p[L],r),fn=v(r),fK=H(fn),i6=C(d,fn,r),dh=f(r,fn),kA=$(dh.asc,i6,r);
kA=O(kA,dh.Gx,dh.axm,T(r));if(r.DP>0){kA=a(kA,U(p[L]),r)}G(kA,r,h2,jX,bm);bm+=B*i}return[h2,jX]}var e1=function(d){var r=performance.now(),p=d[0],Q=d[1];
q(Q);var B=[new Float32Array(0),new Float32Array(0)];for(var L=0;L<p.length;++L){Q.DB=w(Q.DB);var i=_(p[L],Q),c=new Float32Array(B[0].length+i[0].length),h2=new Float32Array(B[1].length+i[1].length);
c.set(B[0]);c.set(i[0],B[0].length);B[0]=c;h2.set(B[1]);h2.set(i[1],B[1].length);B[1]=h2}var jX=performance.now();
if(Q.a3H){console.nY("Geometry: "+String(jX-r)+"ms")}return B};return e1}(),aB=function(){function w(j,I){var U=[],M=0,m=I.length,l=0,A=0,g=new iB,k=0,$=1e9;
for(A=0;A<m;A++){var C=A*8,f=I[A];if(f<$)$=f;var z=j[C+0],s=j[C+1],O=j[C+2],a=j[C+3],X=j[C+4],P=j[C+5],Z=j[C+6],Y=j[C+7],K=Math.min(z,O,X,Z),S=Math.max(z,O,X,Z),G=Math.min(s,a,P,Y),V=Math.max(s,a,P,Y),T=new iB(K,G,S-K,V-G),R=T.x0(g),x=k+f;
if(A-l<10&&(A==l||R.O()*.8<T.O()+g.O())){g=R;k=x}else{U.push(A-l);l=A;g=T;k=f;$=f}}if(A!=l)U.push(A-l);
return U}function n(j,I,U,M,m,l){var A=document.createElement("canvas"),s=0,c=.8;A.width=I;A.height=U;
var g=A.getContext("2d"),k=m[0],$=m[1],C=new Float64Array(I*U),f=Date.now(),z=w($,k);for(var O=0;O<z.length;
O++){var a=s,X=s+z[O],Y=1e9,S=1e9,N=0;s=X;var P=a*8,Z=X*8,K=-Y,G=-S;for(var V=P;V<Z;V+=2){var T=$[V],R=$[V+1];
if(T<Y)Y=T;if(T>K)K=T;if(R<S)S=R;if(R>G)G=R}Y=Math.floor(Y);K=Math.ceil(K);S=Math.floor(S);G=Math.ceil(G);
var x=K-Y,v=G-S;for(var u=a;u<X;u++)N+=k[u];for(var V=P;V<Z;V+=8){var H=k[V>>>3],F=$[V+0],t=$[V+1],o=$[V+2],q=$[V+3],_=$[V+4],d=$[V+5],r=$[V+6],p=$[V+7];
g.fillStyle="rgba(0,0,0,"+H/N+")";g.beginPath();g.moveTo(F,t);g.lineTo(o,q);g.lineTo(_,d);g.lineTo(r,p);
g.closePath();g.fill()}var Q=g.getImageData(Y,S,x,v).data;for(var R=0;R<v;R++)for(var T=0;T<x;T++){var L=R*x+T,B=Q[L*4+3],i=(S+R)*I+Y+T;
if(B!=0)C[i]+=B*N}g.clearRect(Y,S,x,v)}var h2=l[1].color,jX=Math.pow(h2.o/255,c),bm=Math.pow(h2.B/255,c),dC=Math.pow(h2.k/255,c),fn=new iB(0,0,I,U),fK=E.Q(I*U*4);
for(var R=0;R<U;R++)for(var T=0;T<I;T++){var L=R*I+T,u=L*4,k=C[L]*(1/255);fK[u]=D(jX,k);fK[u+1]=D(bm,k);
fK[u+2]=D(dC,k);fK[u+3]=Math.min(255,k*255)}E.s._U("norm",fK,fn,M,fn,fn,1)}var W=new Uint8Array(2e3);
for(var L=0;L<2e3;L++)W[L]=255*Math.min(1,Math.log(L/700+1));function D(j,I){return W[Math.min(1500,~~(j*I*1e3))]}return n}(),d9=function(){var w=new Float32Array(3e3),n=new Float32Array(3e3),W=new Float32Array(256),D=new Float32Array(3e3);
function j(){var $=w.length;w[0]=Math.log10(157647e-9);for(var L=1;L<$;++L)w[L]=Math.log10(L/$)}function I(){var $=n.length;
for(var L=0;L<$;++L)n[L]=Math.pow(10,20*(L-$/2)/$)}function U(){var $=W.length;for(var L=0;L<$;++L)W[L]=E.vw(L/255)}function M(){var $=D.length;
for(var L=0;L<$;++L)D[L]=255*E.ae(L/($-1))}function m($,C){var f=$.length>>>2;for(var L=0;L<f;++L){var z=W[$[4*L]],s=W[$[4*L+1]],O=W[$[4*L+2]],a=.3811*z+.5783*s+.0402*O,X=.1967*z+.7244*s+.0782*O,P=.0241*z+.1288*s+.8444*O;
a=w[~~(a*w.length)];X=w[~~(X*w.length)];P=w[~~(P*w.length)];C[3*L]=(a+X+P)*.5773502692;C[3*L+1]=(a+X-2*P)*.4082482905;
C[3*L+2]=(a-X)*.7071067812}}function l($,C){var f=C.length>>>2,z=D.length-1;for(var L=0;L<f;++L){var s=.5773502692*$[3*L],O=.4082482905*$[3*L+1],a=.7071067812*$[3*L+2],X=n[~~((s+O+a+10)*(3e3/20))],P=n[~~((s+O-a+10)*(3e3/20))],Z=n[~~((s-2*O+10)*(3e3/20))],Y=4.4679*X-3.5873*P+.1193*Z,K=-1.2186*X+2.3809*P-.1624*Z,S=.0497*X-.2439*P+1.2045*Z;
C[4*L]=D[~~(z*Math.max(0,Math.min(1,Y)))];C[4*L+1]=D[~~(z*Math.max(0,Math.min(1,K)))];C[4*L+2]=D[~~(z*Math.max(0,Math.min(1,S)))]}}function A($){var C=0,f=0,z=0;
for(var L=0;L<$.length;L+=3){C+=$[L];f+=$[L+1];z+=$[L+2]}return[C/($.length/3),f/($.length/3),z/($.length/3)]}function g($,A){var C=0,f=0,z=0;
for(var L=0;L<$.length;L+=3){var s=$[L]-A[0],O=$[L+1]-A[1],a=$[L+2]-A[2];C+=s*s;f+=O*O;z+=a*a}return[Math.sqrt(C/($.length/3)),Math.sqrt(f/($.length/3)),Math.sqrt(z/($.length/3))]}function k($,C,f,z,s,O){j();
I();U();M();var a=0,t,o;if(O[0]>100)a=-(O[0]-100)/100*.13;else if(O[0]>=75)a=(100-O[0])/25*.04;else if(O[0]>=50)a=.04+(75-O[0])/25*.04;
else if(O[0]>=25)a=.08+(50-O[0])/25*.08;else a=.16+(25-O[0])/25*.24;var X=(O[1]-100+100)/100,P=O[2]/100,Z=O[3],Y=new Float32Array($.length*3/4),K=new Float32Array(z.length*3/4),S=Date.now();
m($,Y);m(z,K);var G=Date.now(),V=A(Y),T=A(K),R=Date.now(),x=g(Y,V),v=g(K,T),N=Date.now();T[0]*=Math.pow(10,a);
var u=[v[0]/x[0],v[1]/x[1],v[2]/x[2]],H=Y.length,F=1/-1.1546978950500488;for(var L=0;L<H;L+=3){if(Z){var q=Math.max(0,Math.min(1,Y[L]*F));
q=1-Math.sqrt(q);t=q*T[1];o=q*T[2]}else{t=T[1];o=T[2]}Y[L]=(Y[L]-V[0])*u[0]+T[0];Y[L+1]=(Y[L+1]-V[1])*u[1]*X+t;
Y[L+2]=(Y[L+2]-V[2])*u[2]*X+o}var _=Date.now();l(Y,s);var d=s.length>>>2;for(var L=0;L<d;++L){s[4*L]=(1-P)*s[4*L]+P*$[4*L];
s[4*L+1]=(1-P)*s[4*L+1]+P*$[4*L+1];s[4*L+2]=(1-P)*s[4*L+2]+P*$[4*L+2];s[4*L+3]=255}}return k}(),iw=function(){function w(n,W,D,j,I){var U=[-1,-1,-1,-1],M=255,m=160,l,A=!1,g=new Array(4);
g[0]=new Array(W);g[1]=new Array(D);g[2]=new Array(W);g[3]=new Array(D);var k=new Array(2);k[0]=new Array(D);
k[1]=new Array(D);function $(v,N,u,H,F){this.start=H;this.axis=F;this.dir=v;this.end=-1;this.source=N;
this.O=u}function C(v,N,u,H,F){if(u%2==0){if(!g[u][v])g[u][v]=new Array;g[u][v].push(new $(u,H,F,N,v))}else{if(!g[u][N])g[u][N]=new Array;
g[u][N].push(new $(u,H,F,v,N))}var t=Date.now()}function f(L){var v=!1,N=0;if(n[4*L+3]<M)return v;var u=L%W,H=Math.floor(L/W);
z(u,H);if(L+W<W*D&&n[4*(L+W)+3]<M&&n[4*(L-W)+3]>=M&&n[4*(L-2*W)+3]>=M){var F=2;if(n[4*(L+W)+3]<=m)N=-1;
if(n[4*(L+2*W-1)+3]<M&&n[4*(L+2*W+1)+3]<M)v=!0;else if(n[4*(L+2*W-1)+3]>=M&&n[4*(L+1)+3]>=M)v=!0;else if(n[4*(L+2*W+1)+3]>=M&&n[4*(L-1)+3]>=M)v=!0;
C(u,H,F,N,v)}else if(L-W>=0&&n[4*(L-W)+3]<M&&n[4*(L+W)+3]>=M&&n[4*(L+2*W)+3]>=M){var F=0;if(n[4*(L-W)+3]<=m)N=-1;
if(n[4*(L-2*W-1)+3]<M&&n[4*(L-2*W+1)+3]<M)v=!0;else if(n[4*(L-2*W-1)+3]>=M&&n[4*(L+1)+3]>=M)v=!0;else if(n[4*(L-2*W+1)+3]>=M&&n[4*(L-1)+3]>=M)v=!0;
C(u,H,F,N,v)}N=0;if(L+1<W*D&&n[4*(L+1)+3]<M&&n[4*(L-1)+3]>=M&&n[4*(L-2)+3]>=M){var F=3;if(n[4*(L+1)+3]<=m)N=-1;
if(!v&&n[4*(L+W+2)+3]<M&&n[4*(L-W+2)+3]<M){v=!0;C(u,H,F,N,!0)}else C(u,H,F,N,!1)}else if(L>=1&&n[4*(L-1)+3]<M&&n[4*(L+1)+3]>=M&&n[4*(L+2)+3]>=M){var F=1;
if(n[4*(L-1)+3]<=m)N=-1;if(!v&&n[4*(L+W-2)+3]<M&&n[4*(L-W-2)+3]<M){v=!0;C(u,H,F,N,!0)}else C(u,H,F,N,!1)}return v}function z(L,v){if(U[0]==-1){U[0]=L;
U[1]=v;U[2]=1;U[3]=1}if(L<U[0]){U[2]+=U[0]-L;U[0]=L}if(L>U[0]+U[2])U[2]=L-U[0];if(v<U[1]){U[3]+=U[1]-v;
U[1]=v}if(v>U[1]+U[3])U[3]=v-U[1]}function s(v,L,N,u){if(!N.O)return;var H=(v+2)%4,F=N.start,t=U[1];
if(v==2)t+=U[3];else if(v==1)t=U[0];else if(v==3)t=U[0]+U[2];var o=N.source;if(g[H][L])for(var q=0;q<g[H][L].length;
++q){if(v>1){var _=F+Math.floor((g[H][L][q].start-F)/2);if(g[H][L][q].start>F&&_<t)t=_}else{var _=F-Math.floor((F-g[H][L][q].start)/2);
if(g[H][L][q].start<F&&_>t)t=_}}for(var d=1;d<Math.abs(t-F);++d){var q=F+d;if(v==1||v==0)q=F-d;for(var r=0;
r<2;++r){var p=2*r,Q=!1;if(v%2==0)p+=1;if(g[p][q]){for(var B=0;B<g[p][q].length;++B){if(g[p][q][B].O){var i=g[p][q][B].start,c=L-i,h2=q-F;
if(p==0||p==1)c=-c;if(c<=0)continue;if(v==0||v==1)h2=-h2;if(h2>c){t=q;Q=!0;break}}}if(Q)break}}}N.end=t;
X(v,L,F,t,o)}function O(v){for(var L=0;L<g[v].length;++L){if(g[v][L])for(var N=0;N<g[v][L].length;++N){s(v,L,g[v][L][N])}}}function a(){var v=[2,0,3,1];
for(var L=0;L<v.length;++L)O(v[L])}function X(v,L,N,u,H){if(v==2)for(var F=N;F<=u;++F){if(!P(F*W+L,(N+H)*W+L))return!1}else if(v==0)for(var F=N;
F>=u;--F){if(!P(F*W+L,(N-H)*W+L))return!1}else if(v==1)for(var F=N;F>=u;--F){if(!P(L*W+F,L*W+N-H))return!1}else if(v==3)for(var F=N;
F<=u;++F){if(!P(L*W+F,L*W+N+H))return!1}}function P(v,N){if(!l[v]){j[4*v]=j[4*N];j[4*v+1]=j[4*N+1];j[4*v+2]=j[4*N+2];
if(A)j[4*v+3]=255;l[v]=!0;return!0}return!1}function Z(){for(var L=0;L<4;L+=1){for(var v=0;v<g[L].length;
++v){if(g[L][v])for(var N=0;N<g[L][v].length;++N){var u=g[L][v][N];for(var H=1;H<3;H+=2){var F=(L+H)%4;
if(g[F][u.start])for(var t=0;t<g[F][u.start].length;++t){if(g[F][u.start][t].start==u.axis){var bK=W*u.start+u.axis;
if(L%2==1){bK=u.start+W*u.axis;Y(g[F][u.start][t])}else Y(u)}}}}}}}function Y(v){if(v.dir%2==0){var bK=W*v.start+v.axis,N=v.start,u=1;
if(!l[bK+1])u=3;else if(l[bK-1])return;var H=j[4*bK],F=j[4*bK+1],t=j[4*bK+2];while(j[4*bK]==H&&j[4*bK+1]==F&&j[4*bK+2]==t){if(u==1){if(!k[0][N])k[0][N]=new Array;
k[0][N].push(new $(u,0,!1,v.axis,N))}else{if(!k[1][N])k[1][N]=new Array;k[1][N].push(new $(u,0,!1,v.axis,N))}if(v.dir==2){bK+=W;
N++}else{bK-=W;N--}}}}function K(){for(var v=0;v<2;++v){var N=(v+1)%2;for(var L=0;L<k[v].length;++L){if(k[v][L])for(var u=0;
u<k[v][L].length;++u){var H=U[0];if(v==1)H+=U[2];var F=k[v][L][u].start;if(k[N][L])for(var t=0;t<k[N][L].length;
++t){var o=k[N][L][t]._6;if(v==0){if(o>H&&o<F){H=F-Math.floor((F-o)/2)}}else{if(o<H&&o>F){H=F+Math.ceil((o-F)/2)}}}if(v==0)X(k[v][L][u].dir,L,F-1,H,-1);
else X(k[v][L][u].dir,L,F+1,H,-1)}}}for(var L=0;L<l.length;++L){if(!l[L]&&L%W>=U[0]&&L%W<=U[0]+U[2]&&Math.floor(L/W)>=U[1]&&Math.floor(L/W)<=U[1]+U[3]){var F=W;
if(L<F||!l[L-F])F=1;j[4*L]=j[4*(L-F)];j[4*L+1]=j[4*(L-F)+1];j[4*L+2]=j[4*(L-F)+2];l[L]=!0;if(A)j[4*L+3]=255}}}function S(){l=new Array(n.length/4);
for(var L=0;L<j.length/4;++L){l[L]=!1;j[4*L]=n[4*L];j[4*L+1]=n[4*L+1];j[4*L+2]=n[4*L+2];j[4*L+3]=n[4*L+3];
if(j[4*L+3]==255)l[L]=!0;if(f(L))l[L]=!1}if(U[0]>0){U[0]--;U[2]++}if(U[1]>0){U[1]--;U[3]++}if(U[0]+U[2]<W){U[2]++}if(U[1]+U[3]<D){U[3]++}}var G=Date.now();
S();var V=Date.now();a();var T=Date.now();Z();var R=Date.now();K();var x=Date.now();console.log("Init: "+String(V-G));
console.log("Filling: "+String(T-V));console.log("Check areas: "+String(R-T));console.log("Fill areas: "+String(x-R))}return w}();
function hl(){}hl.afV=function(w){var n=[E.vw(w[0]),E.vw(w[1]),E.vw(w[2]),0];return E.Mv.q4(E.Mv.Lv,n)};
hl.akU=function(w){var n=E.Mv.q4(E.Mv.WE,w);return[E.ae(n[0]),E.ae(n[1]),E.ae(n[2])]};hl.kN=function(w,n){var W={},D=5003,j=1667,I=25e3,U=57.4,M=16.1,m=1.8,l=0,A=1.54,g=.75,C=0;
if(n>0){w-=n/100*4}if(w<0){M=22.54;U=80.36;A=.756}if(n>0){m=1.3;g=.2}var k=Math.min(D+U*w,I),$=Math.max(D-M*w,j);
if(w<0){k=Math.max(D+M*w,j);$=Math.min(D-U*w,I)}if(w>0){if(w<=14){C=(w-1)/13*.075+.025}else if(w<=29){C=.1}else if(w<=60){C=.1-.1*(w-29)/(60-29)}else{var f=w-60;
l=-20*(f/40);C=-.3*(f/40)}}else{if(w<-60){var f=w+60;l=-20*(f/40)}}var z=Math.abs(w)/100*A+Math.abs(n)/100*g+C,s=-(n*m+l),O=dS.s4(k,-s),a=dS.vz(O),X=dS.s4($,0),P=dS.vz(X),Z=dS.Lg(a,P);
W.apH=z;W.azQ=Z;if(w==0&&n==0)W.ahR=!0;else W.ahR=!1;return W};hl.ag4=function(w,n,W,D){if(D.ahR){return[w,n,W]}var j=this.afV([w,n,W]),I=j[0],U=j[1],M=j[2],m=U+1e-12,l=[I/m,U/m,M/m,0],A=E.Mv.q4(D.azQ,l),g=0,k=.4;
A[0]*=m;A[1]*=m;A[2]*=m;if(m>k)g=1/(1-k)*(m-k);j[0]=(1-g)*A[0]+g*I;j[1]=(1-g)*A[1]+g*U;j[2]=(1-g)*A[2]+g*M;
return this.akU(j)};E.eA={GV:function(w,n){var L=w.length;w.push(n);var W=L>>>1;while(W!=0&&w[L][0]<w[W][0]){var D=w[L];
w[L]=w[W];w[W]=D;L=W;W=L>>>1}},FZ:function(w){if(w.length==2)return w.pop();var top=w[1],L=1;w[1]=w.pop();
var n=w.length;while(!0){var W=L<<1,D=W+1,j=L;if(W<n&&w[W][0]<w[j][0])j=W;if(D<n&&w[D][0]<w[j][0])j=D;
if(j==L)break;var I=w[L];w[L]=w[j];w[j]=I;L=j}return top},akN:function(w){for(var L=1;L<w.length;L++){var n=L,W=1e9;
while(n!=0){var D=w[n][0];if(D>W){console.log(L);throw"e"}W=D;n=n>>>1}}}};E.s={};E.s.iZ=new Float64Array(256);
E.s.Rj=new Uint8Array(256*256);E.s.P9=new Uint8Array(256*256);(function(){for(var L=0;L<256;L++)E.s.iZ[L]=255/L;
for(var L=0;L<256;L++)for(var w=0;w<256;w++)E.s.Rj[L*256+w]=L==0?0:Math.round(w*255/L);for(var L=0;L<256;
L++)for(var w=0;w<256;w++)E.s.P9[L*256+w]=Math.round(L*(255-w)/255)}());E.s._U=function(w,n,W,D,j,I,U,M){if(M==null)M=ge.cT();
if("idiv,lbrn,div ,lddg,vLit,lLit,hMix,diff".split(",").indexOf(w)==-1){U=U*M.fill;M.fill=1;M.style=!1}var m="norm,dark,mul ,idiv,lbrn,lite,scrn,div ,lddg,over,sLit,hLit,vLit,lLit,pLit,hMix,diff,smud,fsub,fdiv".split(","),l="dkCl,lgCl,hue ,sat ,colr,lum ".split(","),A=E.s[w+"F"];
if(M.vn==null&&w=="norm")E.s.ajf(n,W,D,j,I,U,A,M.MY?1:0);else if(w=="diss")E.s.a15(n,W,D,j,I,U,A,M.MY?1:0);
else if(m.indexOf(w)!=-1)E.s.ai7(n,W,D,j,I,U,A,M);else if(l.indexOf(w)!=-1)E.s.a3k(n,W,D,j,I,U,A,M)};
E.s.a2Z=function(w,n,W){var D=w*W+1-W;return D<.001?0:1-Math.min(1,(1-n)/D)};E.s.a75=function(w,n,W){return w*W==1?1:Math.min(1,n/(1-w*W))};
E.s.Rn=function(w){return w<=.25?((16*w-12)*w+4)*w:Math.sqrt(w)};E.s.normF=function(w,n,W){return w};
E.s.darkF=function(w,n,W){return Math.min(w,n)};E.s["mul F"]=function(w,n,W){return w*n};E.s.idivF=function(w,n,W){var D=w*W+1-W;
return n==1?1:1-n>=D?0:1-(1-n)/D};E.s.lbrnF=function(w,n,W){return Math.max(0,w*W+n-W)};E.s.dkClF=function(w,n,W){var D=E.Mg(w)<E.Mg(n)?w:n;
W.o=D.o;W.B=D.B;W.k=D.k;return W};E.s.liteF=function(w,n,W){return Math.max(w,n)};E.s.scrnF=function(w,n,W){return n+w-n*w};
E.s["div F"]=function(w,n,W){w*=W;return n==0?0:n>=1-w?1:n/(1-w)};E.s.lddgF=function(w,n,W){w*=W;return Math.min(1,w+n)};
E.s.lgClF=function(w,n,W){var D=E.Mg(w)>E.Mg(n)?w:n;W.o=D.o;W.B=D.B;W.k=D.k;return W};E.s.overF=function(w,n,W){return E.s.hLitF(n,w,W)};
E.s.sLitF=function(w,n,W){return w<=.5?n-(1-2*w)*n*(1-n):n+(2*w-1)*(E.s.Rn(n)-n)};E.s.hLitF=function(w,n,W){return w<=.5?E.s["mul F"](2*w,n,W):E.s.scrnF(2*w-1,n,W)};
E.s.vLitF=function(w,n,W){return w<=.5?E.s.a2Z(2*w,n,W):E.s.a75(2*w-1,n,W)};E.s.lLitF=function(w,n,W){return w<=.5?E.s.lbrnF(2*w,n,W):E.s.lddgF(2*w-1,n,W)};
E.s.pLitF=function(w,n,W){return w<=.5?E.s.darkF(2*w,n,W):E.s.liteF(2*w-1,n,W)};E.s.hMixF=function(w,n,W){if(W>.99)return w+n<1?0:1;
return Math.min(1,Math.max(0,(n+w*W-W)/(1-W+1e-6)))};E.s.diffF=function(w,n,W){w*=W;return Math.abs(w-n)};
E.s.smudF=function(w,n,W){return w+n-2*w*n};E.s.fsubF=function(w,n,W){return Math.max(n-w,0)};E.s.fdivF=function(w,n,W){return Math.min(n/w,1)};
E.s["hue F"]=function(w,n,W){E.s.mt(w,E.Wl(n),W);E.s.TQ(W,E.Mg(n),W)};E.s["sat F"]=function(w,n,W){E.s.mt(n,E.Wl(w),W);
E.s.TQ(W,E.Mg(n),W)};E.s.colrF=function(w,n,W){E.s.TQ(w,E.Mg(n),W)};E.s["lum F"]=function(w,n,W){E.s.TQ(n,E.Mg(w),W)};
E.s.TQ=function(w,n,W){var D=n-E.Mg(w);W.o=w.o+D;W.B=w.B+D;W.k=w.k+D;E.s.a8q(W)};E.s.a8q=function(w){var n=w.o,W=w.B,D=w.k,j=E.g7(n,W,D),bK=Math.min(n,W,D),I=Math.max(n,W,D);
if(bK<0){var U=j/(j-bK);n=j+(n-j)*U;W=j+(W-j)*U;D=j+(D-j)*U}if(I>1){var U=(1-j)/(I-j);n=j+(n-j)*U;W=j+(W-j)*U;
D=j+(D-j)*U}w.o=n;w.B=W;w.k=D};E.s.mt=function(w,n,W){var D=E.s.anp,j=w.o,I=w.B,U=w.k;if(j==I&&I==U){W.o=W.B=W.k=0}else if(j>I){if(j>U){if(I>U){W.o=n;
W.B=D(j,I,U,n);W.k=0}else{W.o=n;W.k=D(j,U,I,n);W.B=0}}else{W.k=n;W.o=D(U,j,I,n);W.B=0}}else{if(j<U){if(I>U){W.B=n;
W.k=D(I,U,j,n);W.o=0}else{W.k=n;W.B=D(U,I,j,n);W.o=0}}else{W.B=n;W.o=D(I,j,U,n);W.k=0}}};E.s.anp=function(w,n,W,D){return(n-W)*D/(w-W)};
E.s.ajf=function(w,n,W,D,j,I,U,M){var m=n.wU(D).wU(j),l=Math.max(0,m.x-n.x),A=Math.max(0,m.x-D.x),g=Math.max(0,m.y-n.y),k=Math.max(0,m.y-D.y),$=m.m,C=m.n,f=n.m,z=D.m,s=E.s.Rj,O=E.s.P9,a=new Uint32Array(w.buffer),X=new Uint32Array(W.buffer);
for(var L=0;L<C;L++){var P=(g+L)*f+l,Z=(k+L)*z+A;for(var Y=0;Y<$;Y++){var K=a[P+Y],u=1;if(K>>>24==0)continue;
if(K>>>24==255&&I==1&&M==0){X[Z+Y]=a[P+Y];continue}var S=X[Z+Y],G=K&255,V=K>>>8&255,T=K>>>16&255,R=S&255,x=S>>>8&255,v=S>>>16&255,N=I,H=(S>>>24)*(1/255);
if(M==0){N=(K>>>24)*I*(1/255);u=H}var F=u*(1-N),t=N+F,o=1/t;X[Z+Y]=~~(.5+(M*H+(1-M)*t)*255)<<24|~~(.5+(T*N+v*F)*o)<<16|~~(.5+(V*N+x*F)*o)<<8|~~(.5+(G*N+R*F)*o)}}};
E.s.an1=function(w,n,W,D,j,I){var U=n.wU(D).wU(j),M=Math.max(0,U.x-n.x),m=Math.max(0,U.x-D.x),l=Math.max(0,U.y-n.y),A=Math.max(0,U.y-D.y),g=U.m,k=U.n,$=n.m,C=D.m,f=E.s.Rj,z=E.s.P9,s=new Uint32Array(w.buffer),O=new Uint32Array(W.buffer),a=Math.floor(Math.random()*16777215),X=0;
for(var L=0;L<k;L++){var P=(l+L)*$+M,Z=(A+L)*C+m;for(var Y=0;Y<g;Y++){var K=s[P+Y];if(K>>>24==0)continue;
if(K>>24==255&&I==1){O[Z+Y]=K;continue}var S=O[Z+Y],G=(K>>>24)*I*(1/255),V=(S>>>24)*(1/255),T=V*(1-G),R=G+T,x=K&255,v=K>>>8&255,N=K>>>16&255,u=S&255,H=S>>>8&255,F=S>>>16&255;
X>>>=8;if((Y&3)==0)X=E.s.yF(Z+Y+a);var t=R==0?0:1/R,o=Math.floor(R*(256*255))+(X&255)>>>8,q=Math.floor((N*G+F*T)*t+.5),_=Math.floor((v*G+H*T)*t+.5),d=Math.floor((x*G+u*T)*t+.5);
O[Z+Y]=o<<24|q<<16|_<<8|d}}};E.s.dW=function(w,n,W,D,j,I,U,M){var m=E.g7(w,n,W),l=E.g7(D,j,I),A=Math.min,g=E.s.auA,k=g(m,M,0);
k=A(k,g(w,M,8));k=A(k,g(n,M,16));k=A(k,g(W,M,24));var $=g(l,M,4);$=A($,g(D,M,12));$=A($,g(j,M,20));$=A($,g(I,M,28));
$=Math.max($,1-U);var C=Math.min(k,$);return C<0?0:C>1?1:C};E.s.auA=function(w,n,L){return Math.min((w-n[L])*n[L+1],(w-n[L+3])*n[L+2])};
E.s.ai7=function(w,n,W,D,j,I,U,M){var m=1/255,l=m*I,A=M.MY?1:0,g=M.fill,k=M.style,$=n.wU(D).wU(j),C=Math.max(0,$.x-n.x),f=Math.max(0,$.x-D.x),z=Math.max(0,$.y-n.y),s=Math.max(0,$.y-D.y),O=$.m,a=$.n,X=n.m,P=D.m,Z=new Uint32Array(w.buffer),Y=new Uint32Array(W.buffer);
for(var L=0;L<a;L++){var K=(z+L)*X+C,S=(s+L)*P+f;for(var G=0;G<O;G++,K++,S++){var V=Z[K],t=1;if(V>>>24==0)continue;
var T=Y[S],R=(V&255)*m,x=(V>>>8&255)*m,v=(V>>>16&255)*m,N=(T&255)*m,u=(T>>>8&255)*m,H=(T>>>16&255)*m,F=I;
if(A==0){F=(V>>>24)*l;t=(T>>>24)*m}if(M.vn)F*=E.s.dW(R,x,v,N,u,H,t,M.vn);var o=t*(1-F),q=F+o,_=q==0?0:255/q,d=k?1:F,r=((1-t)*F*R+(1-d)*t*N+d*t*U(R,N,(1+F-d)*g))*_,p=((1-t)*F*x+(1-d)*t*u+d*t*U(x,u,(1+F-d)*g))*_,Q=((1-t)*F*v+(1-d)*t*H+d*t*U(v,H,(1+F-d)*g))*_;
q=F*g+t*(1-F*g);var B=~~(q*255+.5);Y[S]=A*(T>>>24)+(1-A)*B<<24|Q<<16|p<<8|r}}};E.s.a3k=function(w,n,W,D,j,I,U,M){var m=1/255,l=m*I,A=M.MY?1:0,g=n.wU(D).wU(j),k=Math.max(0,g.x-n.x),$=Math.max(0,g.x-D.x),C=Math.max(0,g.y-n.y),f=Math.max(0,g.y-D.y),z=g.m,s=g.n,O=new Uint32Array(w.buffer),a=new Uint32Array(W.buffer),X={o:0,B:0,k:0},P={o:0,B:0,k:0},Z={o:0,B:0,k:0};
for(var L=0;L<s;L++){var Y=(C+L)*n.m+k,K=(f+L)*D.m+$;for(var S=0;S<z;S++,Y++,K++){var G=O[Y],V=a[K],T=(G&255)*m,R=(G>>>8&255)*m,x=(G>>>16&255)*m,v=(V&255)*m,N=(V>>>8&255)*m,u=(V>>>16&255)*m,H=I,F=1;
if(A==0){H=(G>>>24)*l;F=(V>>>24)*m}if(M.vn)H*=E.s.dW(T,R,x,v,N,u,F,M.vn);var t=F*(1-H),o=H+t,q=255/o;
X.o=T;X.B=R;X.k=x;P.o=v;P.B=N;P.k=u;U(X,P,Z);var _=(((1-F)*T+F*Z.o)*H+v*t)*q,d=(((1-F)*R+F*Z.B)*H+N*t)*q,r=(((1-F)*x+F*Z.k)*H+u*t)*q,p=A*(V>>>24)+(1-A)*Math.round(o*255);
a[K]=p<<24|r<<16|d<<8|_}}};E.s.lr=function(w){w=w^61^w>>>16;w=w+(w<<3);w=w^w>>>4;w=w*668265261;w=w^w>>15;
return(w&16777215)*(1/16777215)};E.s.yF=function(w){w=w^61^w>>>16;w=w+(w<<3);w=w^w>>>4;w=w*668265261;
w=w^w>>>15;return w};E.s.my=function(w){this.Ur=w};E.s.my.prototype.get=function(){var w=this.Ur=E.s.yF(this.Ur);
return(w&16777215)*(1/16777215)};E.s.a15=function(w,n,W,D,j,I,U,M){var m=1/255,l=m*I,A=Math.round(I*(256*256*256/255)),g=n.wU(D).wU(j),k=Math.max(0,g.x-n.x),$=Math.max(0,g.x-D.x),C=Math.max(0,g.y-n.y),f=Math.max(0,g.y-D.y),z=g.m,s=g.n,O=new Uint32Array(w.buffer),a=new Uint32Array(W.buffer);
for(var L=0;L<s;L++){var X=(C+L)*n.m+k,P=(f+L)*D.m+$;for(var Z=0;Z<z;Z++,X++,P++){var Y=O[X],K=a[P],S=M*255+(1-M)*(Y>>>24);
if((E.s.yF(X)&16777215)>=S*A)continue;a[P]=Y&16777215|M*(K>>>24)+(1-M)*255<<24}}};E.s.a1Q=function(w,n,W){for(var L=0;
L<w.length;L+=4){var D=W[L>>>2];if(D==0)continue;var j=D*(1/255),I=1/j,U=n[L],M=n[L+1],m=n[L+2],l=w[L],A=w[L+1],g=w[L+2];
n[L]=Math.min(255,Math.max(0,Math.round((U-(1-j)*l)*I)));n[L+1]=Math.min(255,Math.max(0,Math.round((M-(1-j)*A)*I)));
n[L+2]=Math.min(255,Math.max(0,Math.round((m-(1-j)*g)*I)));n[L+3]=255}};E.s.eY=function(w,n,W,D,j,I,U,M,m,l,A){if(l==null)l=!1;
if(A==null)A=[1,1,1];var g=255<<24|A[2]*16711680|A[1]*65280|A[0]*255,k=~g;if(j&&!n.s9(I)){var $=E.Q(n.O()*4);
$.fill(U);E.B0(j,I,$,n);j=$;I=n}if(l){if(j==null)E.s.a6b(w,n,W,D,j,M,m,g,k);else E.s.aiH(w,n,W,D,j,M,m)}else{if(j==null)E.s.adJ(w,n,W,D,j,M,m,g,k);
else E.s.au2(w,n,W,D,j,M,m)}};E.s.adJ=function(w,n,W,D,j,I,U,M,m){var l=1/255,A=n.wU(D).wU(I),g=Math.max(0,A.x-n.x),k=Math.max(0,A.x-D.x),$=Math.max(0,A.y-n.y),C=Math.max(0,A.y-D.y),f=A.m,z=A.n,s=new Uint32Array(w.buffer),O=new Uint32Array(W.buffer),a=E.s.Rj,X=U*255&255;
for(var L=0;L<z;L++){var P=($+L)*n.m+g,Z=(C+L)*D.m+k;for(var Y=0;Y<f;Y++,P++,Z++){var K=s[P],S=O[Z],G=K>>>24,V=S>>>24,T=E.DL(X*G+(255-X)*V),R=E.DL(G*X),x=E.DL(V*(255-X)),v=K&255,N=K>>>8&255,u=K>>>16&255,H=S&255,F=S>>>8&255,t=S>>>16&255,o=R*v+H*x,q=R*N+F*x,_=R*u+t*x;
o=a[T<<8|E.DL(o)];q=a[T<<8|E.DL(q)];_=a[T<<8|E.DL(_)];var d=T<<24|_<<16|q<<8|o;O[Z]=m&S|M&d}}};E.s.a6b=function(w,n,W,D,j,I,U,M,m){var l=1/255,A=n.wU(D).wU(I),g=Math.max(0,A.x-n.x),k=Math.max(0,A.x-D.x),$=Math.max(0,A.y-n.y),C=Math.max(0,A.y-D.y),f=A.m,z=A.n,s=new Uint32Array(w.buffer),O=new Uint32Array(W.buffer),a=E.s.Rj,X=U*16777215&16777215;
for(var L=0;L<z;L++){var P=($+L)*n.m+g,Z=(C+L)*D.m+k;for(var Y=0;Y<f;Y++,P++,Z++){if((E.s.yF(P)&16777215)<X){O[Z]=m&O[Z]|M&s[P]}}}};
E.s.au2=function(w,n,W,D,j,I,U){var M=1/255,m=n.wU(D).wU(I),l=Math.max(0,m.x-n.x),A=Math.max(0,m.x-D.x),g=Math.max(0,m.y-n.y),k=Math.max(0,m.y-D.y),$=m.m,C=m.n,f=new Uint32Array(w.buffer),z=new Uint32Array(W.buffer),s=E.s.Rj;
for(var L=0;L<C;L++){var O=(g+L)*n.m+l,a=(k+L)*D.m+A;for(var X=0;X<$;X++,O++,a++){var P=j[O]*U&255;if(P==0)continue;
if(P==255){z[a]=f[O];continue}var Z=f[O],Y=z[a],K=Z>>>24,S=Y>>>24,G=E.DL(P*K+(255-P)*S),V=E.DL(K*P),T=E.DL(S*(255-P)),R=Z&255,x=Z>>>8&255,v=Z>>>16&255,N=Y&255,u=Y>>>8&255,H=Y>>>16&255,F=s[G<<8|E.DL(V*R+N*T)],t=s[G<<8|E.DL(V*x+u*T)],o=s[G<<8|E.DL(V*v+H*T)];
z[a]=G<<24|o<<16|t<<8|F}}};E.s.aiH=function(w,n,W,D,j,I,U){var M=1/255,m=n.wU(D).wU(I),l=Math.max(0,m.x-n.x),A=Math.max(0,m.x-D.x),g=Math.max(0,m.y-n.y),k=Math.max(0,m.y-D.y),$=m.m,C=m.n,f=new Uint32Array(w.buffer),z=new Uint32Array(W.buffer),s=E.s.Rj,O=Math.round(U*257);
for(var L=0;L<C;L++){var a=(g+L)*n.m+l,X=(k+L)*D.m+A;for(var P=0;P<$;P++,a++,X++){var Z=j[a]*O;if((E.s.yF(a)&65535)<Z)z[X]=f[a]}}};
E.s.ga=function(w,n,W,D,j,I,U){var M=1/255,m=n.wU(D).wU(I),l=Math.max(0,m.x-n.x),A=Math.max(0,m.x-D.x),g=Math.max(0,m.y-n.y),k=Math.max(0,m.y-D.y),$=m.m,C=m.n,f=new Uint32Array(w.buffer),z=new Uint32Array(W.buffer),s=Math.floor(Math.random()*D.O()),O=E.s.aA2;
for(var L=0;L<C;L++){var a=(g+L)*n.m+l,X=(k+L)*D.m+A;for(var P=0;P<$;P++){var Z=j[a+P]*U;if(Z==0)continue;
if(Z==255){z[X+P]=f[a+P];continue}var Y=f[a+P],K=z[X+P],S=Y>>>24,G=K>>>24,V=S*Z*(1/255),T=G*(255-Z)*(1/255),R=Y&255,x=Y>>>8&255,v=Y>>>16&255,N=K&255,u=K>>>8&255,H=K>>>16&255,F=E.s.yF(X+P+s),t=Math.floor((V+T)*256+.5)+(F>>>0&255)>>>8,o=t==0?0:256/(V+T),q=R*V+N*T,_=x*V+u*T,d=v*V+H*T,r=Math.floor(q*o+.5)+(F>>>8&255)>>>8,p=Math.floor(_*o+.5)+(F>>>16&255)>>>8,Q=Math.floor(d*o+.5)+(F>>>24&255)>>>8;
z[X+P]=t<<24|Q<<16|p<<8|r}}};E.s.aA2=function(w){return Math.floor(w+Math.random())};E.s.gZ=function(w,n,W,D,j,I,U){var M=1/255,m=n.wU(D).wU(I),l=Math.max(0,m.x-n.x),A=Math.max(0,m.x-D.x),g=Math.max(0,m.y-n.y),k=Math.max(0,m.y-D.y),$=m.m,C=m.n;
for(var L=0;L<C;L++){var f=(g+L)*n.m+l,z=(k+L)*D.m+A;for(var s=0;s<$;s++,f++,z++){var O=U*j[f]*M;if(O==0)continue;
if(O==1){W[z]=w[f];continue}W[z]=w[f]*O+W[z]*(1-O)}}};E.arS=function(){function w(I){var U=I*.85;return Math.exp(-(U*U)*(1/(2*.4*.4)))*(1/(.4*Math.sqrt(2*Math.PI)))}function n(I,U){var M=I<U?1:w((I-U)/Math.pow(1.001-U,.86));
return M}var W=[];function D(I){if(W[I])return W[I];var U=Math.pow(I,.55),M=new Float64Array(8e3),m=0,l=8e3;
for(var L=0;L<8e3;L++){var A=n(L*(1.55/4e3),U);if(A>=1)m=L;else if(A<=0&&l==8e3)l=L;M[L]=A}var g=[M,m,l];
W[I]=g;return g}function j(I,U,M){var m=1+.55*(1-U),l=Math.round(M*I*m)+2,A=new iB(0,0,l,l),g=E.Q(l*l),k=[g,A],$=l/2,C=m/($-1),f=Date.now(),z=D(U),s=Math.round(8e3/$),O=z[0],a=z[1]-s,X=z[2]+s,P=Math.min(l,l+1>>>1),Z=C*.4*(4e3/1.55),Y=E.Q(8e3);
for(var L=0;L<8e3;L++){var K=L,S=L,G=~~Math.max(0,K-Z-Z),V=~~Math.max(0,K-Z),T=~~(K+Z),R=~~(K+Z+Z),x=~~(.5+255*(1/5)*(O[S]+O[G]+O[V]+O[T]+O[R]));
Y[L]=x;if(x==0)break}for(var L=0;L<P;L++){var v=C*(L-$+.5),N=v*v,u=L*l,H=(l-1-L)*l;for(var F=0;F<P;F++){var t=C*(F-$+.5),S=~~(Math.sqrt(t*t+N)*(4e3/1.55));
if(X<S)continue;else if(S<a){var x=255;while(F<P){var o=l-1-F;g[u+F]=x;g[u+o]=x;g[H+F]=x;g[H+o]=x;F++}break}else{var x=Y[S],o=l-1-F;
g[u+F]=x;g[u+o]=x;g[H+F]=x;g[H+o]=x}}}return k}return{adT:j}}();E.C1={};E.C1.a99=function(w,n,W,D,j,I){E.C1.Tx(w,n,W,D,j,I,null,0)};
E.C1.asG=function(w,n,W,D,j){E.C1.Tx(w,n,W,D,j,null,null,0)};E.C1.a28=function(w,n,W,D,j,I,U){E.C1.Tx(w,n,W,D,j,null,I,U*.5)};
E.C1.Tx=function(w,n,W,D,j,I,U,M){var m=0,T=0,R=1e9,x=0,v=1e9,N=0,u=1e9,H=0,F=0,t=0,o=0;if(I){m=j*.5;
j=3+Math.round((j-3)*.75)}if(U){j=Math.round(j*2.2)}var l=1/j,A=Math.floor(n*l)+1,g=Math.floor(W*l)+1,k=[],$=new Uint8Array(A*g*4),C=U?.5:1,f=I?64:0;
for(var z=0;z<g;z++){var s=U?.5*(z&1):0;for(var O=0;O<A;O++){var a=(O+Math.random()*C+s)*j,X=(z+Math.random()*C)*j;
k.push(a,X);var P=Math.min(n-1,Math.floor(a)),Z=Math.min(W-1,Math.floor(X)),Y=(Z*n+P)*4,K=(z*A+O)*4;
for(var L=0;L<4;L++)$[K+L]=Math.max(0,Math.min(255,Math.floor(w[Y+L]+(Math.random()-.5)*f)))}}var S=I?I:U?U:[0,0,0],G=A*g*2,V=[-A-1,-A,-A+1,-1,0,1,A-1,A,A+1];
for(var z=0;z<W;z++){t=0;for(var O=0;O<n;O++){var q=O+.5,_=z+.5,d=Math.floor(_*l),r=Math.floor(q*l),p=d*A+r,i=0,c=0;
if(t>1+M){R=E.C1.zX(k,T,q,_);H=Math.sqrt(R);t--;o++}else{R=v=u=1e9;for(var L=0;L<V.length;L++){var Q=(p+V[L])*2;
if(Q<0||Q>=G)continue;var B=E.C1.zX(k,Q,q,_);if(B<u){if(B<v){if(B<R){N=x;u=v;x=T;v=R;T=Q;R=B}else{N=x;
u=v;x=Q;v=B}}else{N=Q;u=B}}}H=Math.sqrt(R);F=Math.sqrt(v);t=F-(H+F)*.5}if(U==null){var h2=(H+F)*.5,jX=I?Math.max(0,h2-m):0;
i=Math.max(0,Math.min(1,.5+h2-H-jX));c=Math.max(0,Math.min(1,1-(.5+h2-H)-jX))}else{var fn=Math.min(E.C1.FF(k,T,x,q,_),E.C1.FF(k,T,N,q,_));
i=Math.max(0,Math.min(1,fn-M*.5));if(q<M||n-M<q||_<M||W-M<_)i=0;c=0}var fK=1-c-i,K=z*n+O<<2,i6=T<<1,dh=x<<1;
D[K+0]=Math.floor(.5+i*$[i6+0]+c*$[dh+0]+fK*S[0]);D[K+1]=Math.floor(.5+i*$[i6+1]+c*$[dh+1]+fK*S[1]);
D[K+2]=Math.floor(.5+i*$[i6+2]+c*$[dh+2]+fK*S[2]);D[K+3]=w[K+3]}}};E.C1.zX=function(w,n,W,D){var j=W-w[n],I=D-w[n+1];
return j*j+I*I};E.C1.FF=function(w,n,W,D,j){var I=w[n],U=w[n+1],M=w[W],m=w[W+1],l=(I+M)*.5,A=(U+m)*.5,g=l+(m-U),k=A-(M-I),$=k-A,C=g-l;
return Math.abs($*D-C*j+g*A-k*l)/Math.sqrt(C*C+$*$)};E.xX={};E.xX.dF=function(w){if(E.xX.OR.length<w)E.xX.OR=E.Q(w);
return E.xX.OR};E.xX.OR=E.Q(0);E.xX._q=function(w){if(E.xX.Ia.length<w)E.xX.Ia=new Float32Array(w);return E.xX.Ia};
E.xX.Ia=new Float32Array(0);E.xX.So=function(w,n,W,D){var j=W.m,I=W.n;E.xX.a6h(w,n,j,I,D)};E.xX.ye=function(w,n,W,D){var j=W.m,I=W.n;
E.xX.ayw(w,n,j,I,D)};E.xX.$f=function(w,n,W){var D=n.m,j=n.n;E.xX.ame(w,D,j,W)};E.xX.uf=function(w,n,W,D,j){var I=W.m,U=W.n;
E.xX.ajC(w,n,I,U,D,j)};E.xX.KA=function(w,n,W,D){var j=W.m,I=W.n;D=Math.round(D);var U=E.xX.dF(j*I);
E.nX(w,n);E.xX.bR(n,U,j,I,D)};E.xX.Qz=function(w,n,W){var D=n.m,j=n.n;W=Math.round(W);var I=E.xX.dF(D*j*4);
E.xX.Ji(w,I,D,j,W)};E.xX.xn=function(w,n,W,D){var j=W.m,I=W.n;D=Math.round(D);var U=E.xX._q(j*I);E.nX(w,n);
E.xX.BN(n,U,j,I,D)};E.xX.pc=function(w,n,W){var D=n.m,j=n.n;W=Math.round(W);var I=E.xX.dF(D*j*4);E.xX.qy(w,I,D,j,W);
E.nX(I,w)};E.xX.gS=function(w,bK){var n=Math.sqrt(12*w*w/bK+1),W=Math.floor(n);if(W%2==0)W--;var D=W+2,j=(12*w*w-bK*W*W-4*bK*W-3*bK)/(-4*W-4),I=Math.round(j),U=[];
for(var L=0;L<bK;L++)U.push(L<I?W:D);return U};E.xX.a6h=function(w,n,W,D,j){var I=E.xX.gS(j,3),U=E.xX.dF(W*D);
E.nX(w,n);E.xX.bR(n,U,W,D,I[0]-1>>1);E.xX.bR(n,U,W,D,I[1]-1>>1);E.xX.bR(n,U,W,D,I[2]-1>>1)};E.xX.ayw=function(w,n,W,D,j){var I=E.xX.gS(j,2),U=E.xX.dF(W*D);
E.nX(w,n);E.xX.bR(n,U,W,D,I[0]-1>>1);E.xX.bR(n,U,W,D,I[1]-1>>1)};E.xX.ame=function(w,n,W,D){var j=E.xX.gS(D,3),I=E.xX.dF(n*W*4);
E.xX.Ji(w,I,n,W,j[0]-1>>1);E.xX.Ji(w,I,n,W,j[1]-1>>1);E.xX.Ji(w,I,n,W,j[2]-1>>1)};E.xX.ajC=function(w,n,W,D,j,I){if(I==null)I=3;
var U=E.xX.gS(j,I),M=E.xX._q(W*D);E.nX(w,n);for(var L=0;L<I;L++)E.xX.BN(n,M,W,D,(U[L]-1)/2)};E.xX.bR=function(w,n,W,D,j){E.xX.ax$(w,n,W,D,j);
E.xX.a2N(n,w,W,D,j)};E.xX.Ji=function(w,n,W,D,j){E.xX.qy(w,n,W,D,j);E.xX.ay9(n,w,W,D,j)};E.xX.BN=function(w,n,W,D,j){E.xX.a1T(w,n,W,D,j);
E.xX.ah3(n,w,W,D,j)};E.xX.sC=[];E.xX.RJ=function(w){if(E.xX.sC[w])return E.xX.sC[w];var n=1/(w+w+1),W=(w+w+1)*256,D=E.Q(W);
for(var L=0;L<W;L++)D[L]=Math.round(L*n);E.xX.sC[w]=D;return D};E.xX.ax$=function(w,n,W,D,j){var I=1/(j+j+1),U=W-j-j-1,M=E.xX.RJ(j);
for(var L=0;L<D;L++){var m=L*W,l=m,A=m+j,g=w[m],k=w[m+W-1],$=(j+1)*g;for(var C=0;C<j;C++)$+=w[m+C];for(var C=0;
C<=j;C++){$+=w[A+C]-g;n[m+C]=M[$]}A+=j+1;m+=j+1;for(var C=0;C<U;C++){$+=w[A+C]-w[l+C];n[m+C]=M[$]}A+=U;
l+=U;m+=U;for(var C=W-j;C<W;C++){$+=k-w[l++];n[m++]=M[$]}}};E.xX.qy=function(w,n,W,D,j){var I=W<<2,U=j<<2,M=1/(j+j+1),m=W-j-j-1,l=m<<2,A=E.xX.RJ(j);
for(var L=0;L<D;L++){var g=L*I,k=g,$=g+U,C=g+I,f=w[g],z=w[g+1],s=w[g+2],O=w[g+3],a=(j+1)*f,X=(j+1)*z,P=(j+1)*s,Z=(j+1)*O;
for(var Y=0;Y<U;Y+=4){a+=w[g+Y];X+=w[g+Y+1];P+=w[g+Y+2];Z+=w[g+Y+3]}for(var Y=0;Y<=U;Y+=4){a+=w[$]-f;
n[g]=A[a];X+=w[$+1]-z;n[g+1]=A[X];P+=w[$+2]-s;n[g+2]=A[P];Z+=w[$+3]-O;n[g+3]=A[Z];$+=4;g+=4}for(var Y=0;
Y<l;Y+=4){a+=w[$+Y]-w[k+Y];n[g+Y]=A[a];X+=w[$+Y+1]-w[k+Y+1];n[g+Y+1]=A[X];P+=w[$+Y+2]-w[k+Y+2];n[g+Y+2]=A[P];
Z+=w[$+Y+3]-w[k+Y+3];n[g+Y+3]=A[Z]}$+=l;k+=l;g+=l;f=w[C-4];z=w[C-3];s=w[C-2];O=w[C-1];for(var Y=W-j;
Y<W;Y++){a+=f-w[k];n[g]=A[a];X+=z-w[k+1];n[g+1]=A[X];P+=s-w[k+2];n[g+2]=A[P];Z+=O-w[k+3];n[g+3]=A[Z];
k+=4;g+=4}}};E.xX.a1T=function(w,n,W,D,j){var I=1/(j+j+1),U=W-j-j-1;for(var L=0;L<D;L++){var M=L*W,m=M,l=M+j,A=w[M],g=w[M+W-1],k=(j+1)*A;
for(var $=0;$<j;$++)k+=w[M+$];for(var $=0;$<=j;$++){k+=w[l+$]-A;n[M+$]=k*I}l+=j+1;M+=j+1;for(var $=0;
$<U;$++){k+=w[l+$]-w[m+$];n[M+$]=k*I}l+=U;m+=U;M+=U;for(var $=W-j;$<W;$++){k+=g-w[m++];n[M++]=k*I}}};
E.xX.a2N=function(w,n,W,D,j){var I=1/(j+j+1),U=D-j-j-1,M=E.xX.RJ(j);for(var L=0;L<W;L++){var m=L,l=m,A=m+j*W,g=w[m],k=w[m+W*(D-1)],$=(j+1)*g;
for(var C=0;C<j;C++)$+=w[m+C*W];for(var C=0;C<=j;C++){$+=w[A]-g;n[m]=M[$];A+=W;m+=W}for(var C=0;C<U;
C++){var f=C*W;$+=w[A+f]-w[l+f];n[m+f]=M[$]}l+=U*W;A+=U*W;m+=U*W;for(var C=D-j;C<D;C++){$+=k-w[l];n[m]=M[$];
l+=W;m+=W}}};E.xX.ay9=function(w,n,W,D,j){var I=W<<2,U=j<<2,M=1/(j+j+1),m=D-j-j-1,l=m<<2,A=E.xX.RJ(j);
for(var L=0;L<W;L++){var g=L<<2,k=g,$=g+j*I,C=g+I*(D-1),f=w[g],z=w[g+1],s=w[g+2],O=w[g+3],a=(j+1)*f,X=(j+1)*z,P=(j+1)*s,Z=(j+1)*O;
for(var Y=0;Y<j;Y++){var K=g+Y*I;a+=w[K];X+=w[K+1];P+=w[K+2];Z+=w[K+3]}for(var Y=0;Y<=j;Y++){a+=w[$]-f;
n[g]=A[a];X+=w[$+1]-z;n[g+1]=A[X];P+=w[$+2]-s;n[g+2]=A[P];Z+=w[$+3]-O;n[g+3]=A[Z];$+=I;g+=I}for(var Y=0;
Y<m;Y++){var S=Y*I;a+=w[$+S]-w[k+S];n[g+S]=A[a];X+=w[$+S+1]-w[k+S+1];n[g+S+1]=A[X];P+=w[$+S+2]-w[k+S+2];
n[g+S+2]=A[P];Z+=w[$+S+3]-w[k+S+3];n[g+S+3]=A[Z]}k+=m*I;$+=m*I;g+=m*I;f=w[C];z=w[C+1];s=w[C+2];O=w[C+3];
for(var Y=D-j;Y<D;Y++){a+=f-w[k];n[g]=A[a];X+=z-w[k+1];n[g+1]=A[X];P+=s-w[k+2];n[g+2]=A[P];Z+=O-w[k+3];
n[g+3]=A[Z];k+=I;g+=I}}};E.xX.ah3=function(w,n,W,D,j){var I=1/(j+j+1),U=D-j-j-1;for(var L=0;L<W;L++){var M=L,m=M,l=M+j*W,A=w[M],g=w[M+W*(D-1)],k=(j+1)*A;
for(var $=0;$<j;$++)k+=w[M+$*W];for(var $=0;$<=j;$++){k+=w[l]-A;n[M]=k*I;l+=W;M+=W}for(var $=0;$<U;$++){var C=$*W;
k+=w[l+C]-w[m+C];n[M+C]=k*I}m+=U*W;l+=U*W;M+=U*W;for(var $=D-j;$<D;$++){k+=g-w[m];n[M]=k*I;m+=W;M+=W}}};
E.xv={};E.xv.Q=function(w,n,W,D){var j=[];for(var I=0;I<4;I++)for(var U=0;U<4;U++)j.push(w+W*U/3,n+D*I/3);
return j};E.xv.vm=function(w,n){var W=w.slice(0);for(var L=0;L<4;L++)for(var D=0;D<4;D++){var j=2*(L*4+D),I=2*(D*4+(3-L));
if(n){var U=j;j=I;I=U}W[I]=w[j];W[I+1]=w[j+1]}return W};E.xv.ST=E.Q(0);E.xv.drawImage=function(w,n,W,D,j,I,U){var M=!1,m=Date.now(),l=2,A=W+2*l,g=D+2*l,k=new iB(l,l,W,D),$=k.clone(),O=50;
$.VD(l,l);var C=E.xv.ST;if(C.length!=$.O()*4)C=E.xv.ST=E.Q($.O()*4);else C.fill(0);E.Cb(n,k,C,$);if(M)console.log(Date.now()-m,"copy rect");
m=Date.now();E.y8(C);if(M)console.log(Date.now()-m,"multiply alpha");m=Date.now();var f=[],z=[],s=[];
for(var a=0;a<O+1;a++)for(var X=0;X<O+1;X++){var P=X/O,Z=a/O;f.push(A*P,g*Z);if(X<O&&a<O){var Y=a*(O+1)+X,K=Y+1,S=Y+O+1,G=S+1;
z.push(Y,K,S);z.push(S,K,G)}var V=E.xv.ao7(w,P,Z);s.push(-V)}var T=f.slice(0);E.xv.D(w,T,new iB(l,l,W,D));
E.p.D(T,new eh(1,0,0,1,-I.x,-I.y),T);if(M)console.log(Date.now()-m,"mesh built");m=Date.now();var R=I.m,x=I.n;
E.mE.mD(C,A,g,j,R,x,f,T,s,z);if(M)console.log(Date.now()-m,"rendered");m=Date.now();E.Hd(j);if(M)console.log(Date.now()-m,"divided");
m=Date.now()};E.xv.hD=new Array(10);E.xv.aic=function(w,n){var W=200,D=0,j=0,I=1e9,U=E.xv.hD;for(var M=0;
M<W+1;M++)for(var m=0;m<W+1;m++){var l=m/W,A=M/W;E.xv.n1(w,l,A,U);var g=U[8]-n.x,k=U[9]-n.y,$=g*g+k*k;
if($<I){I=$;D=l;j=A}}return[D,j]};E.xv.D=function(w,n,W){var D=W.x,j=W.y,I=1/W.m,U=1/W.n,M=E.xv.hD;for(var m=0;
m<n.length;m+=2){var l=(n[m]-D)*I,A=(n[m+1]-j)*U;E.xv.n1(w,l,A,M);n[m]=M[8];n[m+1]=M[9]}};E.xv.ao7=function(w,n,W){var D,j,I,U,M=E.xv.hD;
E.xv.a6N(w,n,W,M);D=M[8];j=M[9];E.xv.asN(w,n,W,M);I=M[8];U=M[9];return D*U-j*I};E.xv.n1=function(w,n,W,D){E.xv.ry(D,0,W);
E.xv.ry(D,4,n);E.xv.Li(w,D)};E.xv.a6N=function(w,n,W,D){E.xv.ry(D,0,W);E.xv.hL(D,4,n);E.xv.Li(w,D)};
E.xv.asN=function(w,n,W,D){E.xv.hL(D,0,W);E.xv.ry(D,4,n);E.xv.Li(w,D)};E.xv.hL=function(w,L,n){var W=1-n;
w[L]=-3*(W*W);w[L+1]=3*(W*W)-6*(n*W);w[L+2]=6*(n*W)-3*(n*n);w[L+3]=3*(n*n)};E.xv.ry=function(w,L,n){var W=1-n;
w[L]=W*(W*W);w[L+1]=3*n*(W*W);w[L+2]=3*(n*n)*W;w[L+3]=n*n*n};E.xv.Li=function(w,n){var W=0,D=0,j=0,I=n[0],U=n[1],M=n[2],m=n[3],l=n[4],A=n[5],g=n[6],k=n[7];
j=I*l;W+=w[0]*j;D+=w[1]*j;j=I*A;W+=w[2]*j;D+=w[3]*j;j=I*g;W+=w[4]*j;D+=w[5]*j;j=I*k;W+=w[6]*j;D+=w[7]*j;
j=U*l;W+=w[8]*j;D+=w[9]*j;j=U*A;W+=w[10]*j;D+=w[11]*j;j=U*g;W+=w[12]*j;D+=w[13]*j;j=U*k;W+=w[14]*j;D+=w[15]*j;
j=M*l;W+=w[16]*j;D+=w[17]*j;j=M*A;W+=w[18]*j;D+=w[19]*j;j=M*g;W+=w[20]*j;D+=w[21]*j;j=M*k;W+=w[22]*j;
D+=w[23]*j;j=m*l;W+=w[24]*j;D+=w[25]*j;j=m*A;W+=w[26]*j;D+=w[27]*j;j=m*g;W+=w[28]*j;D+=w[29]*j;j=m*k;
W+=w[30]*j;D+=w[31]*j;n[8]=W;n[9]=D};E.Hs={};E.Hs.aw9=function(w,n,W){var D=Date.now(),j=new ArrayBuffer(n*W*16),I=E.Hs.aeA(w,n,W,j),U=E.Hs.a3I(n,W,j);
return{r1:U,EO:I}};E.Hs.arz=function(w,n,W){var D=Math.round(w.length/8),j=new Uint32Array(D),I=new Uint8Array(D),U=new Uint32Array(D);
E.cJ(j,4294967295,0);j[W]=0;var M=new cj(D);M.push(W,j[W]);var m={r1:w,EO:n,VF:j,mN:I,hW:U,zP:M,ad$:W};
return m};E.Hs.OG=function(w,n){var W=w.r1,D=w.EO,j=w.VF,I=w.mN,U=w.hW,M=w.zP;while(!M.VY()&&(n==null||I[n]==0)){var m=M.pop();
I[m]=1;for(var L=0;L<8;L++){var l=W[8*m+L],A=m+l;if(l==0||I[A])continue;var g=j[m]+D[8*m+L];if(M.contains(A)&&g<j[A])M.remove(A,j[A]);
if(!M.contains(A)){j[A]=g;U[A]=m;M.push(A,j[A])}}}};function cj(w){this.a$=new Uint32Array(w);this.list=[];
this.kA=0;this.sA=4294967295}cj.prototype.VY=function(){return this.kA==0};cj.prototype.push=function(w,n){var W=this.list;
if(W[n]==null)W[n]=[];W[n].push(w);this.kA++;this.a$[w]=W[n].length-1+1;this.sA=Math.min(this.sA,n)};
cj.prototype.pop=function(){this.kA--;var w=this.list,n=this.sA,W=w[n].pop();if(w[n].length==0)w[n]=null;
this.Oz();this.a$[W]=0;return W};cj.prototype.contains=function(w){return this.a$[w]!=0};cj.prototype.remove=function(w,n){this.kA--;
var W=this.list,L=this.a$[w]-1;if(L==W[n].length-1)W[n].pop();else{var D=W[n].pop();W[n][L]=D;this.a$[D]=L+1}if(W[n].length==0)W[n]=null;
this.a$[w]=0;this.Oz()};cj.prototype.Oz=function(){if(this.kA==0){this.sA=4294967295;return}var w=this.sA,n=this.list;
while(n[w]==null)w++;this.sA=w};E.Hs.ayN=function(w,n,W,D){var j=new Int16Array(D);for(var I=0;I<W;I++)for(var U=0;
U<n;U++){var L=I*n+U,M=0;if(1<U&&U<n-2&&1<I&&I<W-2){M+=w[L-n-n];M+=w[L-n-1]+2*w[L-n]+w[L-n+1];M+=w[L-2]+2*w[L-1]-16*w[L]+2*w[L+1]+w[L+2];
M+=w[L+n-1]+2*w[L+n]+w[L+n+1];M+=w[L+n+n]}else M=-16*w[L];j[L]=M}return j};E.Hs.ari=function(w,n,W,D){if(D==null)D=128;
var j=new Uint8Array(n*W);for(var I=1;I<W-1;I++)for(var U=1;U<n-1;U++){var L=I*n+U;j[L]=E.Hs.aju(w[L],w[L-1],w[L+1],w[L-n],w[L+n],D)}return j};
E.Hs.aju=function(w,n,W,D,j,I){var U=Math.abs(w);return w*n<0&&U<Math.abs(n)&&Math.abs(n-w)>I||w*W<0&&U<Math.abs(W)&&Math.abs(W-w)>I||w*D<0&&U<Math.abs(D)&&Math.abs(D-w)>I||w*j<0&&U<Math.abs(j)&&Math.abs(j-w)>I?1:0};
E.Hs.abn=function(w,n,W,D){var j=new Float32Array(D),I=0;new Uint32Array(D).fill(0);for(var U=0;U<W;
U++)for(var M=0;M<n;M++){var m=0,l=0,L=U*n+M,A=L*3;if(0<M&&M<n-1)m=w[L+1]-w[L-1];if(0<U&&U<W-1)l=w[L+n]-w[L-n];
var g=j[A+2]=Math.sqrt(m*m+l*l);if(g!=0){var k=1/g;j[A]=m*k;j[A+1]=l*k}if(g>I)I=g}var $=n*W,C=I==0?0:1/I;
for(var L=0;L<$;L++)j[L*3+2]=1-j[L*3+2]*C;return j};E.Hs.as2=function(w,n,W){return W[~~((.5+.5*w)*255)]+W[~~((.5+.5*n)*255)]};
E.Hs.aeA=function(w,n,W,D){var j=Date.now(),I=E.Hs.ayN(w,n,W,D),U=E.Hs.ari(I,n,W),M=E.Hs.abn(w,n,W,D),m=new Float32Array(256);
for(var L=0;L<256;L++)m[L]=Math.acos(-1+2*L/255)*(.95/Math.PI);var l=[-1,0,1,1,1,0,-1,-1],A=[-1,-1,-1,0,1,1,1,0];
for(var L=0;L<8;L++){var g=1/Math.sqrt(l[L]*l[L]+A[L]*A[L]);l[L]*=g;A[L]*=g}var k=[l[0],A[0],l[1],A[1],l[2],A[2],l[3],A[3]],$=[-n-1,-n,-n+1,1],C=new Uint8Array(n*W*8);
new Uint32Array(C.buffer).fill(4294967295);var f=n*W;for(var z=1;z<W-1;z++)for(var s=1;s<n-1;s++){var O=z*n+s,a=1-U[O],X=M[O*3+2],P=M[3*O+1],Z=-M[3*O];
for(var Y=0;Y<4;Y++){var K=O+$[Y];E.Hs.azP(O,K,Y,C,U,M,a,X,P,Z,k,m)}}return C};E.Hs.azP=function(w,n,W,D,j,I,U,M,m,l,A,g){var k=1-j[n],$=(W&1)==0?1:Math.SQRT1_2,C=I[n*3+2]*$,f=I[3*n+1],z=-I[3*n],s=M*$,O=A[W+W],a=A[W+W+1],X=m*O+l*a,P=f*O+z*a;
if(X+P<0){X=-X;P=-P}var Z=E.Hs.as2(X,P,g);D[(w<<3)+W]=E.Hs.kF(k,Z,C);D[(n<<3)+W+4]=E.Hs.kF(U,Z,s)};E.Hs.kF=function(w,n,W){return 1+~~(.5+20*(.43*w+.43*n+.14*W))};
E.Hs.a3I=function(w,n,W){var D=new Int16Array(W),j=D,L=0,I=0;new Uint32Array(W).fill(0);for(var U=0;
U<n;U++)for(var M=0;M<w;M++){if(U>0&&M>0)j[I+0]=-w-1;if(U>0)j[I+1]=-w;if(U>0&&M<w-1)j[I+2]=-w+1;if(M<w-1)j[I+3]=1;
if(U<n-1&&M<w-1)j[I+4]=w+1;if(U<n-1)j[I+5]=w;if(U<n-1&&M>0)j[I+6]=w-1;if(M>0)j[I+7]=-1;L++;I+=8}return D};
E.Z3={};E.Z3.kd=function(w){var n=w.slice(0),W=0;for(var L=0;L<w.length;L++)W+=w[L];for(var L=0;L<w.length;
L++)n[L]/=W;return n};E.Z3.eq=[E.Z3.kd([1,2,1,2,16,2,1,2,1]),E.Z3.kd([1,2,1,2,4,2,1,2,1]),E.Z3.kd([0,-1,0,-1,8,-1,0,-1,0]),E.Z3.kd([-.7,-1,-.7,-1,10,-1,-.7,-1,-.7]),[-1,0,1,-2,0,2,-1,0,1],[1,2,1,0,0,0,-1,-2,-1]];
E.Z3.yz=function(w,n,W,D,j,I,U,M){if(U==null)U=!1;if(M==null)M=!1;var m=Math.floor(Math.sqrt(j.length)),l=m-1>>>1,A=new Uint32Array(w.buffer),n=new Uint8ClampedArray(n.buffer);
for(var L=0;L<D;L++)for(var g=0;g<W;g++){var k=0,$=0,C=0,f=0;for(var z=0;z<m;z++)for(var s=0;s<m;s++){var O=j[z*m+s];
if(O==0)continue;var a=g-l+s,X=L-l+z;if(a<0)a=0;else if(a>W-1)a=W-1;if(X<0)X=0;else if(X>D-1)X=D-1;if(M&&A[X*W+a]>>>24==0){X=L;
a=g}var P=A[X*W+a];k+=(P&255)*O;$+=(P>>>8&255)*O;C+=(P>>>16&255)*O;f+=(P>>>24&255)*O}if(U){if(k<0)k=-k;
if($<0)$=-$;if(C<0)C=-C;if(f<0)f=-f}if(M){k=Math.max(0,Math.min(255,k));$=Math.max(0,Math.min(255,$));
C=Math.max(0,Math.min(255,C));f=Math.max(0,Math.min(255,f))}var Z=L*W+g<<2;n[Z]=~~(.5+k);n[Z+1]=~~(.5+$);
n[Z+2]=~~(.5+C);n[Z+3]=255-I&n[Z+3]|I&~~(.5+f)}};E.Z3.eh=function(w,n,W,D){var j=w.length,I=new Uint8Array(j);
E.Z3.yz(w,n,W,D,E.Z3.eq[4],0,!0);E.Z3.yz(w,I,W,D,E.Z3.eq[5],0,!0);for(var L=0;L<j;L+=4){var U=n[L],M=n[L+1],m=n[L+2],l=n[L+3],A=I[L],g=I[L+1],k=I[L+2],$=I[L+3];
n[L]=255-Math.max(0,Math.min(255,Math.sqrt(U*U+A*A)));n[L+1]=255-Math.max(0,Math.min(255,Math.sqrt(M*M+g*g)));
n[L+2]=255-Math.max(0,Math.min(255,Math.sqrt(m*m+k*k)))}};E.Z3.fp=function(w,n,W,D){var j=w.length,I=new Uint8Array(j);
E.Z3.Zu(w,n,W,D,E.Z3.eq[4],!0);E.Z3.Zu(w,I,W,D,E.Z3.eq[5],!0);for(var L=0;L<j;L++){var U=n[L],M=I[L];
n[L]=255-Math.max(0,Math.min(255,Math.sqrt(U*U+M*M)))}};E.Z3.Zu=function(w,n,W,D,j,I){n=new Uint8ClampedArray(n.buffer);
var U=[-W-1,-W,-W+1,-1,0,1,W-1,W,W+1],M=D-1,m=W-1;for(var L=1;L<M;L++)for(var l=1;l<m;l++){var A=L*W+l,g=E.Z3.yC(w,A,W,j);
if(I){if(g<0)g=-g}n[A]=~~(g+.5)}};E.Z3.yC=function(w,n,W,D){return w[n-W-1]*D[0]+w[n-W]*D[1]+w[n-W+1]*D[2]+w[n-1]*D[3]+w[n]*D[4]+w[n+1]*D[5]+w[n+W-1]*D[6]+w[n+W]*D[7]+w[n+W+1]*D[8]};
E.Z3.G0=function(w,n,W,D,j){var I=[-W-1,-W,-W+1,-1,0,1,W-1,W,W+1],U=D-1,M=W-1;for(var L=1;L<U;L++)for(var m=1;
m<M;m++){var l=L*W+m;n[l]=E.Z3.axC(w,l,W,j)}};E.Z3.axC=function(w,n,W,D){return w[n-W-1]*D[0]+w[n-W]*D[1]+w[n-W+1]*D[2]+w[n-1]*D[3]+w[n]*D[4]+w[n+1]*D[5]+w[n+W-1]*D[6]+w[n+W]*D[7]+w[n+W+1]*D[8]};
E.h1={};E.h1.jI=function(){function w(U,M,m,l,A,g){if(A==0){M.set(U);return}var k=E.Q(m*l),$=E.Q(m*l);
if(E.Ym(U)){n(U,M,m,l,A,g);E.hN(U,k,3);E.h1._4(k,$,m,l,A,g);E.IL($,M,3)}else{for(var L=0;L<3;L++){E.hN(U,k,L);
E.h1._4(k,$,m,l,A,g);E.IL($,M,L)}}}function n(U,M,m,l,A,g){var k=0,$=new ArrayBuffer(512*4*3),C=[new Int32Array($,0),new Int32Array($,2048),new Int32Array($,2*2048)],f=1+2*Math.round(Math.sqrt(A)),z=f>>>1,s=new Array(f),O=new Array(f);
for(var L=0;L<f;L++){var $=new ArrayBuffer(512*4*3);s[L]=[new Int32Array($,0),new Int32Array($,2048),new Int32Array($,2*2048)];
O[L]=s[L][0]}var a=[E.h1.h3,E.h1.he][g],X=a[0],P=a[1],Z=C[0];for(var Y=0;Y<m;Y++)if(Y<A||Y>m-A-f-1){Z.fill(0);
var K=Math.max(Y-A,0),S=Math.min(m,Y+A+1),G=S-K;for(var V=0;V<A;V++)D(Z,U,V*m+K,V*m+S,1);for(var V=0;
V<l;V++){var T=V-A-1,R=V+A;if(R<l)D(Z,U,R*m+K,R*m+S,1);if(T>=0)D(Z,U,T*m+K,T*m+S,-1);var x=V*m+Y<<2;
k=Z[300];if(k!=0)for(var L=0;L<3;L++)M[x+L]=X(C[L],U[x+L],k)}}else{for(var L=0;L<f;L++)O[L].fill(0);
var K=Y-A+z,S=Y+A+1+z;for(var V=0;V<A;V++)W(O,U,V*m+K,V*m+S,1,z);for(var V=0;V<l;V++){var T=V-A-1,R=V+A;
if(T>=0)W(O,U,T*m+K,T*m+S,-1,z);if(R<l)W(O,U,R*m+K,R*m+S,1,z);var v=s[z];k=v[0][300];for(var L=0;L<z;
L++){var N=z-1-L,u=z+1+L,H=s[N],F=s[u],t=k+H[0][300],o=k+F[0][300],q=V*m+Y+N<<2,_=V*m+Y+u<<2;if(t!=0)for(var d=0;
d<3;d++)M[q+d]=P(v[d],H[d],U[q+d],t);if(o!=0)for(var d=0;d<3;d++)M[_+d]=P(v[d],F[d],U[_+d],o)}var x=V*m+Y+z<<2;
if(k!=0)for(var d=0;d<3;d++)M[x+d]=X(v[d],U[x+d],k)}Y+=f-1}}function W(U,M,m,l,A,g){var k=j,$=m<<2,C=l<<2;
k(U[g-1],M,m-1<<2,A);k(U[g-1],M,l-1<<2,-A);k(U[g+1],M,l<<2,A);k(U[g+1],M,m<<2,-A);for(var L=1;L<g;L++){var f=U[g-L-1],z=U[g+L+1];
for(var s=0;s<=L;s++){var O=s<<2;k(f,M,m-1-s<<2,A);k(f,M,l-1-s<<2,-A);k(z,M,l+s<<2,A);k(z,M,m+s<<2,-A)}}D(U[g],M,m,l,A)}function D(U,M,L,m,l){var A=L<<2,g=m<<2;
while(A<g){j(U,M,A,l);A+=4}}function j(U,M,m,l){var A=l*M[m+3];U[300]+=A;I(U,M[m],0,A);I(U,M[m+1],512,A);
I(U,M[m+2],1024,A)}function I(U,M,m,l){U[m|M]+=l;U[m|256|M>>>4]+=l}return w}();E.h1._4=function(){function w(g,k,$,C,f,z){if(f==0){k.set(g);
return}if(f<=200)n(g,k,$,C,f,z);else I(g,k,$,C,f,z)}function n(g,k,$,C,f,z){var s=0,O=new Int32Array(512),a=1+2*Math.round(Math.sqrt(f)),X=a>>>1,P=new Array(a);
for(var L=0;L<a;L++)P[L]=new Int32Array(512);var Z=[E.h1.h3,E.h1.he][z],Y=Z[0],K=Z[1];for(var S=0;S<$;
S++)if(S<f||S>$-f-a-1){O.fill(0);s=0;var G=Math.max(S-f,0),V=Math.min($,S+f+1),T=V-G;for(var R=0;R<f;
R++){s+=T;D(O,g,R*$+G,R*$+V,1)}for(var R=0;R<C;R++){var x=R-f-1,v=R+f;if(x>=0){s-=T;D(O,g,x*$+G,x*$+V,-1)}if(v<C){s+=T;
D(O,g,v*$+G,v*$+V,1)}var N=Y(O,g[R*$+S],s);k[R*$+S]=N}}else{for(var L=0;L<a;L++)P[L].fill(0);s=0;var G=S-f+X,V=S+f+1+X,T=V-G;
for(var R=0;R<f;R++){s+=T;W(P,g,R*$+G,R*$+V,1,X)}for(var R=0;R<C;R++){var x=R-f-1,v=R+f;if(x>=0){s-=T;
W(P,g,x*$+G,x*$+V,-1,X)}if(v<C){s+=T;W(P,g,v*$+G,v*$+V,1,X)}for(var L=0;L<X;L++){var u=X-1-L,H=X+1+L;
k[R*$+S+u]=K(P[X],P[u],g[R*$+S+u],s);k[R*$+S+H]=K(P[X],P[H],g[R*$+S+H],s)}k[R*$+S+X]=Y(P[X],g[R*$+S+X],s)}S+=a-1}}function W(g,k,$,C,f,z){var s=j;
s(g[z-1],k[$-1],0,f);s(g[z-1],k[C-1],0,-f);s(g[z+1],k[C],0,f);s(g[z+1],k[$],0,-f);for(var L=1;L<z;L++){var O=g[z-L-1],a=g[z+L+1];
for(var X=0;X<=L;X++){s(O,k[$-1-X],0,f);s(O,k[C-1-X],0,-f);s(a,k[C+X],0,f);s(a,k[$+X],0,-f)}}D(g[z],k,$,C,f)}function D(g,k,L,$,C){while(L<$)j(g,k[L++],0,C)}function j(g,k,$,C){g[$|k]+=C;
g[$|256|k>>>4]+=C}function I(g,k,$,C,f,z){var s=0,O=new Int32Array(512),a=new Int32Array(1*$),X=new Int32Array(512*$),P=Math.min(f,$),Z=Math.min(f,C),Y=[E.h1.h3,E.h1.he][z],K=Y[0];
for(var S=0;S<Z;S++)U(X,a,g,$,S,1);for(var S=0;S<C;S++){if(S+f<C)U(X,a,g,$,S+f,1);if(S-f-1>=0)U(X,a,g,$,S-f-1,-1);
O.fill(0);s=0;for(var G=0;G<P;G++){s+=a[G];M(O,X,G)}for(var G=0;G<$;G++){var V=G-f-1,T=G+f;if(V>=0&&a[V]!=0){s-=a[V];
m(O,X,V)}if(T<$&&a[T]!=0){s+=a[T];M(O,X,T)}var R=s==0?0:K(O,g[S*$+G],s);k[S*$+G]=R}}}function U(g,k,$,C,f,z){var L=f*C;
for(var s=0;s<C;s++){j(g,$[L+s],s<<9,z);k[s]+=z}}function M(g,k,$){for(var L=0;L<16;L++){var C=k[$<<9|256|L];
if(C==0)continue;g[256|L]+=C;var f=L<<4,z=$<<9|f;l(g,k,f,z);l(g,k,f+4,z+4);l(g,k,f+8,z+8);l(g,k,f+12,z+12)}}function m(g,k,$){for(var L=0;
L<16;L++){var C=k[$<<9|256|L];if(C==0)continue;g[256|L]-=C;var f=L<<4,z=$<<9|f;A(g,k,f,z);A(g,k,f+4,z+4);
A(g,k,f+8,z+8);A(g,k,f+12,z+12)}}function l(g,k,$,C){g[$]+=k[C];g[$+1]+=k[C+1];g[$+2]+=k[C+2];g[$+3]+=k[C+3]}function A(g,k,$,C){g[$]-=k[C];
g[$+1]-=k[C+1];g[$+2]-=k[C+2];g[$+3]-=k[C+3]}return w}();E.h1.QB=.5;E.h1.h3=[function(w,n,W){var D=~~(.5+E.h1.QB*W),j=0,L=256;
while(j+w[L]<D)j+=w[L++];L=L-256<<4;while(j<D)j+=w[L++];return L-1},function(w,n,W,D){var j=~~(.5+E.h1.QB*D),I=0,L=256;
while(I+w[L]+n[L]<j){I+=w[L]+n[L];L++}L=L-256<<4;while(I<j){I+=w[L]+n[L];L++}return L-1}];E.h1.tB=100;
E.h1.he=[function(w,n,W){var D=E.h1.tB,j=0,I=0,L=Math.max(0,n-D),U=Math.min(256,n+D+1);while(L<U){var M=w[L];
j+=L*M;I+=M;L++}return I==0?0:j/I},function(w,n,W,D){var j=E.h1.tB,I=0,U=0,L=Math.max(0,W-j),M=Math.min(256,W+j+1);
while(L<M){var m=w[L]+n[L];I+=L*m;U+=m;L++}return U==0?0:I/U}];E.K={};E.K.ce=function(w){var n=y.wR.Aa(w.Trnf),W=w.Sz.v,D=E.K.kN(n,new iB(0,0,W.Wdth.v,W.Hght.v));
return E.K.OT(D)};E.K.kN=function(w,n){var W=w[0],D=w[1],j=w[2],I=w[3],U=w[6],M=w[7],m=w[4],l=w[5],A=0,g=0,k=1,$=0,C=0,f=1,z=1,s=1;
if(n){A=n.x;g=n.y;k=n.x+n.m;$=n.y;C=n.x;f=n.y+n.n;z=n.x+n.m;s=n.y+n.n}return E.K.tQ(w,[A,g,k,$,z,s,C,f])};
E.K.tV=function(w){function n(j,I){for(var L=0;L<I.length;L+=2)if(!W(j,I[L],I[L+1]))return!1;return!0}function W(j,I,U){return j[2*I]==j[2*U]&&j[2*I+1]==j[2*U+1]}var D=0;
if(n(w,[0,1,2,3]))D+=1;if(n(w,[0,3,1,2]))D+=2;return D};E.K.tQ=function(w,n){function W(N,L,u){var R=N[L*2]-N[u*2],x=N[L*2+1]-N[u*2+1];
return Math.sqrt(R*R+x*x)}var D=w[0],j=w[1],I=w[2],U=w[3],M=w[6],m=w[7],l=w[4],A=w[5],g=n[0],k=n[1],$=n[2],C=n[3],f=n[6],z=n[7],s=n[4],O=n[5],a=[[g,k,1,0,0,0,-g*D,-k*D,D],[0,0,0,g,k,1,-g*j,-k*j,j],[$,C,1,0,0,0,-$*I,-C*I,I],[0,0,0,$,C,1,-$*U,-C*U,U],[f,z,1,0,0,0,-f*M,-z*M,M],[0,0,0,f,z,1,-f*m,-z*m,m],[s,O,1,0,0,0,-s*l,-O*l,l],[0,0,0,s,O,1,-s*A,-O*A,A]],X=[0,0,0,0,0,0,0,0],P=E.GY.hU(a,X);
if(P!=0){X=[0,0,0,0,0,0,0,0];var Z=E.K.tV(w),Y=E.K.tV(n);if(Z==Y&&Z!=0){var K=Z==1,S=K?3:1,G=W(w,0,S),V=W(n,0,S),T=V/G,R=w[2*S]-w[0],x=w[2*S+1]-w[1],v=new eh;
v.translate(-D,-j);v.rotate(Math.atan2(x,R)-(K?Math.PI/2:0));if(K)v.scale(1,T);else v.scale(T,1);v.translate(g,k);
v.Ba();X=E.K.yT(v)}}return X};E.K.Q=function(w,n){if(w==null)w=n=0;return[1,0,w,0,1,n,0,0]};E.K.RC=function(w){return Math.abs(w[6])<1e-10&&Math.abs(w[7])<1e-10};
E.K.OT=function(w){return new eh(w[0],w[3],w[1],w[4],w[2],w[5])};E.K.yT=function(w){return[w.dl,w.Cj,w.z2,w.k,w.j7,w.EU,0,0]};
E.K.D=function(w,n){var W=new Float64Array(2);for(var D=0;D<n.length;D+=2){var j=n[D],I=n[D+1];E.K.EQ(j,I,w,W);
n[D]=W[0];n[D+1]=W[1]}};E.K.EQ=function(w,n,W,D){var j=1/(W[6]*w+W[7]*n+1);D[0]=(W[0]*w+W[1]*n+W[2])*j;
D[1]=(W[3]*w+W[4]*n+W[5])*j};E.K.ac8=function(w,n){var W=new Float64Array(2);E.K.EQ(n.x,n.y,w,W);return new ec(W[0],W[1])};
E.K.nJ=function(w,n,W,D){w=new Uint32Array(w.buffer);n=new Uint32Array(n.buffer);for(var j=0;j<D;j++){for(var I=0;
I<W;I++){n[I*D+j]=w[j*W+I]}}};E.K.oX=function(w,n,W,D){w=new Uint32Array(w.buffer);n=new Uint32Array(n.buffer);
for(var j=0;j<D;j++){for(var I=0;I<W;I++){n[j*W+I]=w[j*W+W-1-I]}}};E.K.au1=function(w,n,W,D){w=new Uint32Array(w.buffer);
n=new Uint32Array(n.buffer);for(var j=0;j<D;j++){for(var I=0;I<W;I++){n[j*W+I]=w[(D-1-j)*W+I]}}};E.K.u0=function(w){return Math.abs(w[6])<1e-9&&Math.abs(w[7])<1e-9};
E.K.G6=function(w){return Math.abs(w[0])<1e-9&&Math.abs(w[4])<1e-9||Math.abs(w[1])<1e-9&&Math.abs(w[3])<1e-9};
E.K.drawImage=function(w,n,W,D,j,I,U,M,m){if(U==null)U=!1;if(M==null)M=!1;var l=E.K.Ba(w),A=!0,g=0;for(var L=0;
L<8;L++){var k=Math.round(w[L]);if(L!=2&&L!=5)g+=Math.abs(k);if(Math.abs(k-w[L])>1e-9)A=!1}var $=E.K.u0(w),C=E.K.G6(w)&&$,f=C?1:0;
if(U||A&&g==W+D&&$){E.K.ay5(l,n,W,D,j,I,M,$,m);return}var z=I.m,s=I.n,O=new Float64Array(2);j=new Uint32Array(j.buffer);
n=new Uint32Array(n.buffer);for(var a=0;a<s;a++)for(var X=0;X<z;X++){var P=a*z+X,Z,Y,K,S,t=0,o=0,q=0,_=0;
j[P]=0;var G=X+I.x+.5,V=a+I.y+.5;Z=G;Y=V;K=l;var T=K[0]*Z+K[1]*Y+K[2],R=K[3]*Z+K[4]*Y+K[5];if(!$){S=1/(K[6]*Z+K[7]*Y+1);
T*=S;R*=S}var x=T*W,v=R*D,N=x<-1||x>W+1||v<-1||v>D+1;if(M){x=Math.max(.001,Math.min(W-1,x));v=Math.max(.001,Math.min(D-1,v))}else if(N)continue;
var u=E.K.akM(w,W,D,G,V,T,R),H=Math.round(u*2.3);if(u<1.1){E.K.hC(x,v,n,W,D,j,P,f);continue}if(!M&&(x<.6||x>W-.6||v<.6||v>D-.6)){H=Math.max(H,5)}if(M&&N)H=1;
var F=1/H,d=I.x+X,r=I.y+a;K=l;for(var L=0;L<H;L++)for(var p=0;p<H;p++){Z=d+(L+.5)*F;Y=r+(p+.5)*F;var x=K[0]*Z+K[1]*Y+K[2],v=K[3]*Z+K[4]*Y+K[5];
if(!$){S=1/(K[6]*Z+K[7]*Y+1);x*=S;v*=S}if(M){x=Math.max(.001,Math.min(.999,x));v=Math.max(.001,Math.min(.999,v))}else if(x<0||x>=1||v<0||v>=1)continue;
x=Math.floor(x*W);v=Math.floor(v*D);var Q=v*W+x,B=n[Q],i=B>>>24;t+=(B&255)*i;o+=(B>>>8&255)*i;q+=(B>>>16&255)*i;
_+=i}if(_!=0){var c=1/_;t=~~(t*c+.5);o=~~(o*c+.5);q=~~(q*c+.5);_=~~(_*F*F+.5);j[P]=_<<24|q<<16|o<<8|t}}};
E.K.akM=function(w,n,W,D,j,I,U){var M=E.K.TU(w,D,j,I+1/n,U),m=E.K.TU(w,D,j,I,U+1/W);return 1/Math.sqrt(Math.max(M,m))};
E.K.TU=function(w,n,W,D,j){var I=1/(w[6]*D+w[7]*j+1),U=(w[0]*D+w[1]*j+w[2])*I-n,M=(w[3]*D+w[4]*j+w[5])*I-W;
return U*U+M*M};E.K.ay5=function(w,n,W,D,j,I,U,M,m){if(M&&!U&&I.O()>4e6&&m){E.K.acO(w,n,W,D,j,I,U,M,m);
return}var l=I.x+I.m,A=I.y+I.n,g=0,k=new Uint32Array(j.buffer),$=new Uint32Array(n.buffer),C=w[0]*W,f=w[1]*W,z=w[2]*W,s=w[3]*D,O=w[4]*D,a=w[5]*D,X=w[6],P=w[7];
if(M&&!U)for(var Z=I.y+.5;Z<A;Z++)for(var Y=I.x+.5;Y<l;Y++){var K=C*Y+f*Z+z,S=s*Y+O*Z+a;if(0<K&&K<W&&0<S&&S<D){var G=~~S*W+~~K;
k[g]=$[G]}else k[g]=0;g++}else for(var Z=I.y+.5;Z<A;Z++)for(var Y=I.x+.5;Y<l;Y++){var V=1/(X*Y+P*Z+1),K=(C*Y+f*Z+z)*V,S=(s*Y+O*Z+a)*V;
if(U){K=Math.max(.001,Math.min(W-1,K));S=Math.max(.001,Math.min(D-1,S))}if(0<K&&K<W&&0<S&&S<D){var G=Math.floor(S)*W+Math.floor(K);
k[g]=$[G]}else k[g]=0;g++}};E.K.acO=function(w,n,W,D,j,I,U,M,m){var l=new Uint32Array(j.buffer),A=new Uint32Array(n.buffer),P=0;
if(m&&(I.m&3)!=0)throw"e";var g=w[0]*W,k=w[1]*W,$=w[2]*W,C=w[3]*D,f=w[4]*D,z=w[5]*D,s=w[6],O=w[7],a=I.m,X=I.n,Z=I.x+.5,Y=I.y+.5,K=(a>>>2<<2)-1e-9,S=-.1+(X>>>1<<1)-1e-9,G=~~W,V=g==0?0:1/g,T=C==0?0:1/C;
for(var R=0;R<X;R++){var x=Z*g+k*(R+Y)+$,v=Z*C+f*(R+Y)+z,N=0,u=a;if(g==0){}else if(V>0){N=Math.max(N,-x*V);
u=Math.min(u,(W-x)*V)}else{u=Math.min(u,-x*V);N=Math.max(N,(W-x)*V)}if(C==0){}else if(T>0){N=Math.max(N,-v*T);
u=Math.min(u,(D-v)*T)}else{u=Math.min(u,-v*T);N=Math.max(N,(D-v)*T)}if(u<0)u=0;if(N>u)N=u;N=Math.ceil(N);
u=~~u;P=~~(R*a);for(var H=0;H<N;H++)l[P++]=0;for(var H=N;H<u;H+=4){var F=g*H+x,t=C*H+v,o=~~t*G+~~F;l[P++]=l[P++]=l[P++]=l[P++]=A[o]}for(var H=u;
H<a;H++)l[P++]=0}};E.K.Ba=function(w){var n=w[4]-w[5]*w[7],W=w[2]*w[7]-w[1],D=w[1]*w[5]-w[2]*w[4],j=w[5]*w[6]-w[3],I=w[0]-w[2]*w[6],U=w[3]*w[2]-w[0]*w[5],M=w[3]*w[7]-w[4]*w[6],m=w[1]*w[6]-w[0]*w[7],l=1/(w[0]*w[4]-w[1]*w[3]);
return[n*l,W*l,D*l,j*l,I*l,U*l,M*l,m*l]};E.K.y9=function(w,n){var W=w[0],D=w[1],j=w[2],I=w[3],U=w[4],M=w[5],m=w[6],l=w[7],A=n[0],g=n[1],k=n[2],$=n[3],C=n[4],f=n[5],z=n[6],s=n[7],O=[W*A+D*$+j*z,W*g+D*C+j*s,W*k+D*f+j,I*A+U*$+M*z,I*g+U*C+M*s,I*k+U*f+M,m*A+l*$+z,m*g+l*C+s],a=1/(m*k+l*f+1);
for(var L=0;L<8;L++)O[L]*=a;return O};E.K.hC=function(w,n,W,D,j,I,U,M){var m=w,l=n,k=0,$=0,C=0,f=0;w-=.499999;
n-=.499999;var A=Math.floor(w),g=Math.floor(n);if(M==0){var L=g*D+A,z=A>=0&&A<D,s=A+1>=0&&A+1<D,O=g>=0&&g<j,a=g+1>=0&&g+1<j;
if(z&&O)k=W[L];if(s&&O)$=W[L+1];if(z&&a)C=W[L+D];if(s&&a)f=W[L+D+1]}else if(M==1){var X=A<0?0:A>D-1?D-1:A,P=A<-1?0:A>D-2?D-1:A+1,Z=g<0?0:g>j-1?j-1:g,Y=g<-1?0:g>j-2?j-1:g+1;
k=W[Z*D+X];$=W[Z*D+P];C=W[Y*D+X];f=W[Y*D+P]}else{var X=(A+50*D)%D,P=(A+50*D)%D,Z=(g+50*j)%j,Y=(g+50*j)%j;
k=W[Z*D+X];$=W[Z*D+P];C=W[Y*D+X];f=W[Y*D+P]}var K=w-A,S=n-g,G=(1-S)*(1-K)*(k>>>24),V=(1-S)*K*($>>>24),T=S*(1-K)*(C>>>24),R=S*K*(f>>>24),x=G+V+T+R,v=G*(k&255)+V*($&255)+T*(C&255)+R*(f&255),N=G*(k>>>8&255)+V*($>>>8&255)+T*(C>>>8&255)+R*(f>>>8&255),u=G*(k>>>16&255)+V*($>>>16&255)+T*(C>>>16&255)+R*(f>>>16&255);
if(x==0)I[U]=0;else{var H=1/x;v=~~(v*H+.5);N=~~(N*H+.5);u=~~(u*H+.5);x=~~(x+.5);I[U]=x<<24|u<<16|N<<8|v}};
E.K.kG=function(w,n,W,D,j,I){var U=w-.499999,M=n-.499999,m=~~U,l=~~M,A=U-m,g=M-l,k=(1-g)*(1-A),$=(1-g)*A,C=g*(1-A),f=g*A,z=l*D+m<<2,s=(l+1)*D+m<<2,O=k*W[z]+$*W[z+4]+C*W[s]+f*W[s+4],a=k*W[z+1]+$*W[z+5]+C*W[s+1]+f*W[s+5],X=k*W[z+2]+$*W[z+6]+C*W[s+2]+f*W[s+6],P=k*W[z+3]+$*W[z+7]+C*W[s+3]+f*W[s+7];
I[0]=O;I[1]=a;I[2]=X;I[3]=P};E.K.iL=function(w,n,W,D,j){w-=.499999;n-=.499999;var I=Math.floor(w),U=Math.floor(n),M=w-I,m=n-U,l=(1-m)*(1-M),A=(1-m)*M,g=m*(1-M),k=m*M,$=(I+50*D)%D,C=(I+1+50*D)%D,f=(U+50*j)%j,z=(U+1+50*j)%j,s=W[f*D+$],O=W[f*D+C],a=W[z*D+$],X=W[z*D+C];
if(s==null||X==null)throw"e";return l*s+A*O+g*a+k*X};E.K.aw5=function(w,n,W,D,j){w-=.499999;n-=.499999;
var I=Math.floor(w),U=Math.floor(n),M=w-I,m=n-U,l=(1-m)*(1-M),A=(1-m)*M,g=m*(1-M),k=m*M,$=U*D+I,C=$+D,f=W[$],z=W[$+1],s=W[C],O=W[C+1];
if(f==null||O==null){console.log(I,U,D,j);throw"e"}return l*f+A*z+g*s+k*O};E.K.sB=function(w,n,W,D,j,I,U,M,m,l,A,g){var k=new Uint32Array(w.buffer),$=new Uint32Array(D.buffer),C=(1+2*l)/j,f=[],z=[];
for(var s=0;s<j;s++){var O=-.25+l-s*C;f.push(Math.cos(2*Math.PI*O)*g/A);f.push(Math.sin(2*Math.PI*O)/A)}U*=n;
M*=W;for(var a=0;a<I;a++){var X=Math.pow(a/I,m)*I;for(var s=0;s<j;s++){var P=U+f[s<<1]*X,Z=M+f[(s<<1)+1]*X,Y=~~(.5+(P<0?0:P>n-1?n-1:P)),K=~~(.5+(Z<0?0:Z>W-1?W-1:Z));
$[a*j+s]=k[K*n+Y]}}};E.K.al=function(w,n,W,D,j,I,U,M,m,l,A,g){var k=new Uint32Array(w.buffer),$=new Uint32Array(D.buffer),C=1/g,f=[],z=W*4,s=1/z;
for(var O=0;O<z+10;O++)f.push(Math.pow(O*s,1/m)*W*A);U*=j;M*=I;for(var O=0;O<I;O++)for(var a=0;a<j;a++){var X=C*(a-U),P=O-M,Z=1.75-Math.atan2(P,X)*(1/(2*Math.PI));
Z=Z-~~Z;Z=(Z+l)*(1/(1+2*l));var Y=Math.sqrt(X*X+P*P);Y=f[~~(Y*4)];E.K.hC(Z*n+.5,Y+.5,k,n,W,$,O*j+a,1)}};
E.K.pQ=function(w,n,W,D,j){var I=j[0],U=j[1];for(var M=0;M<U;M++)for(var m=0;m<I;m++){var l=j[2]*m+j[3]*M+j[4],A=j[5]*m+j[6]*M+j[7],g=M*I+m<<2,k=A*n+l<<2;
D[g]=w[k+0];D[g+1]=w[k+1];D[g+2]=w[k+2];D[g+3]=w[k+3]}};E.M={Kc:function(w,n){var W=~~(.499+w*n);return W<0?0:W>n?n:W},a4l:function(w,n,W,D,j,I,U,M){var m=W[0],l=W[1],A=W[2],g=W[3],k=D.m,$=D.n,C=new Float64Array(k*4+8),f=new Float64Array(k*4+8);
for(var z=0,L=0;z<$;z++){var s=C;C=f;f=s;f.fill(0);for(var O=0;O<k;O++,L++){var a=O+j,X=z+I,P=m*a+l*X,Z=A*a+g*X,Y=0,G=0;
if(M==0)Y=P+.5;else if(M==1)Y=2*Math.sqrt(P*P+Z*Z);else if(M==2)Y=(Math.PI+Math.atan2(-Z,-P))/(2*Math.PI);
else if(M==3)Y=Math.abs(P*2);else if(M==4)Y=2*(Math.abs(P)+Math.abs(Z));var K=E.M.Kc(Y,U)*4,S=O*4;for(var V=0;
V<4;V++){var T=Math.max(0,Math.min(254.999,n[K+V]+C[S+4+V])),R=Math.floor(T);if(Math.random()<T-R)R++;
var x=T-R;C[S+8+V]=x*(7/16);f[S+0+V]=x*(3/16);f[S+4+V]=x*(5/16);f[S+8+V]=x*(1/16);G|=R<<V*8}w[L]=G}}},US:[function(w,n,W,D,j,I,U){var M=W[0],m=W[1],l=W[2],A=W[3],g=D.m,k=D.n;
for(var $=0,L=0;$<k;$++)for(var C=0;C<g;C++,L++){var f=C+j,z=$+I,s=M*f+m*z,O=l*f+A*z,a=s+.5;w[L]=n[E.M.Kc(a,U)]}},function(w,n,W,D,j,I,U){var M=W[0],m=W[1],l=W[2],A=W[3],g=D.m,k=D.n;
for(var $=0,L=0;$<k;$++)for(var C=0;C<g;C++,L++){var f=C+j,z=$+I,s=M*f+m*z,O=l*f+A*z,a=2*Math.sqrt(s*s+O*O);
w[L]=n[E.M.Kc(a,U)]}},function(w,n,W,D,j,I,U){var M=W[0],m=W[1],l=W[2],A=W[3],g=D.m,k=D.n;for(var $=0,L=0;
$<k;$++)for(var C=0;C<g;C++,L++){var f=C+j,z=$+I,s=M*f+m*z,O=l*f+A*z,a=(Math.PI+Math.atan2(-O,-s))/(2*Math.PI);
w[L]=n[E.M.Kc(a,U)]}},function(w,n,W,D,j,I,U){var M=W[0],m=W[1],l=W[2],A=W[3],g=D.m,k=D.n;for(var $=0,L=0;
$<k;$++)for(var C=0;C<g;C++,L++){var f=C+j,z=$+I,s=M*f+m*z,O=l*f+A*z,a=Math.abs(s*2);w[L]=n[E.M.Kc(a,U)]}},function(w,n,W,D,j,I,U){var M=W[0],m=W[1],l=W[2],A=W[3],g=D.m,k=D.n;
for(var $=0,L=0;$<k;$++)for(var C=0;C<g;C++,L++){var f=C+j,z=$+I,s=M*f+m*z,O=l*f+A*z,a=2*(Math.abs(s)+Math.abs(O));
w[L]=n[E.M.Kc(a,U)]}}]};E.M.auT=function(w,n){return w+.5};E.M.acB=function(w,n){return 2*Math.sqrt(w*w+n*n)};
E.M.atv=function(w,n){return(Math.PI+Math.atan2(-n,-w))/(2*Math.PI)};E.M.aAB=function(w,n){return Math.abs(w*2)};
E.M.ayT=function(w,n){return 2*(Math.abs(w)+Math.abs(n))};E.M.Yd=function(w,n,W,D,j,I,U,M,m,l,A,g){var k=w.Clrs,$=new Uint32Array(n.buffer),C=1023,f=k?E.M.oR(w,m,l):null;
if(g&&k){var z=E.M.ak3(w,f,C+1,U);E.M.a4l($,z,D,W,W.x-j,W.y-I,C,M)}else{var s=k?E.M.P7(w,f,C+1,U):E.M.Fc(w,C+1,U);
if(M<5){E.M.US[M]($,s,D,W,W.x-j,W.y-I,C)}else{var O=new Uint8Array(s.buffer),a=W.m,X=W.n,P=A.xR-A.rW,Z=1/P,Y=A.gl.m-W.m>>1,K=A.gl.n-W.n>>1,S=A.gl.m,G=-.6*Z,V=(-.6+.4)*Z,T=(-.6+2*.4)*Z,R=(-.6+3*.4)*Z;
for(var x=0,L=0;x<X;x++)for(var v=0;v<a;v++,L+=4){var N=0,u=0,H=0,F=0,t=(x+K)*S+v+Y,o=(A.PH[t]-A.rW)*Z,q=0;
if(o<=0||o>=1){q=(o<=0?0:C)<<2;n[L]=O[q];n[L+1]=O[q+1];n[L+2]=O[q+2];n[L+3]=O[q+3];continue}q=Math.max(0,Math.min(C-1,Math.round((o+G)*C)))<<2;
u+=O[q];H+=O[q+1];F+=O[q+2];N+=O[q+3];q=Math.max(0,Math.min(C-1,Math.round((o+V)*C)))<<2;u+=O[q];H+=O[q+1];
F+=O[q+2];N+=O[q+3];q=Math.max(0,Math.min(C-1,Math.round((o+T)*C)))<<2;u+=O[q];H+=O[q+1];F+=O[q+2];N+=O[q+3];
q=Math.max(0,Math.min(C-1,Math.round((o+R)*C)))<<2;u+=O[q];H+=O[q+1];F+=O[q+2];N+=O[q+3];n[L]=u>>>2;
n[L+1]=H>>>2;n[L+2]=F>>>2;n[L+3]=N>>>2}}}};E.M.oR=function(w,n,W){var D=[w.Clrs.v,w.Trns.v],j=[[],[]],I=255;
for(var U=0;U<2;U++)for(var L=0;L<D[U].length;L++){var M,m=D[U][L].v;if(U==0){var l=m.Type.v.Clry;if(l=="FrgC")M={o:n>>16&255,B:n>>8&255,k:n&255};
else if(l=="BckC")M={o:W>>16&255,B:W>>8&255,k:W&255};else M=E.M.y_(m.Clr.v)}else{M=m.Opct.v.val*(255/100);
if(M<I)I=M}j[U].push([M,m.Lctn.v/4096,m.Mdpn.v/100])}j.push(I>254);return j};E.M.y_=function(w){var n,W=w.classID;
if(W=="RGBC"){if(w.Rd)n={o:w.Rd.v,B:w.Grn.v,k:w.Bl.v};else n={o:w.redFloat.v*255,B:w.greenFloat.v*255,k:w.blueFloat.v*255}}else if(W=="HSBC"){n=E.li(w.H.v.val/360,w.Strt.v/100,w.Brgh.v/100);
n.o*=255;n.B*=255;n.k*=255}else if(W=="CMYC"){var D=100-w.Cyn.v,j=100-w.Mgnt.v,I=100-w.Ylw.v,U=100-w.Blck.v,M=255*D*U*1e-4,m=255*(.2*D+.8*j)*U*1e-4,l=255*(.2*j+.8*I)*U*1e-4;
n={o:M,B:m,k:l}}else if(W=="Grsc")n={o:255-w.Gry.v,B:255-w.Gry.v,k:255-w.Gry.v};else if(W=="LbCl"){n=E.kH(w.Lmnc.v,w.A.v,w.B.v)}else if(W=="BkCl")n={o:0,B:0,k:0};
else console.log(w);if(isNaN(n.o))n.o=n.B=n.k=0;return n};E.M.Fc=function(w,n,W){var D=new Uint32Array(n),j=new Uint8Array(D.buffer);
D.fill(4278190080);var I=[],U=[],M=w.RndS.v,m=w.Smth.v/4096;for(var L=0;L<4;L++){I[L]=~~(w.Mnm.v[L].v*255/100);
U[L]=~~(w.Mxm.v[L].v*255/100)}var l=E.Q(n*4),A=E.Q(n);for(var g=0;g<3;g++){E._.yt(null,n,1,l,[1+Math.round(m*m*m*60),22,M*(2+g)]);
E.hN(l,A,0);E.IL(A,j,g);var k=I[g],$=U[g];for(var L=0;L<n;L++)j[4*L+g]=Math.max(k,Math.min($,j[4*L+g]))}if(W)for(var L=0;
L<n/2;L++){var C=D[L];D[L]=D[n-1-L];D[n-1-L]=C}return D};E.M.lW=function(w){return{classID:"RGBC",Rd:{t:"doub",v:w.o},Grn:{t:"doub",v:w.B},Bl:{t:"doub",v:w.k}}};
E.M.ak3=function(w,n,W,D){var j=[],I=1/(W-0);for(var L=0;L<W;L++){var U=L*4,M=E.M.pW(w,n,(D?W-1-L:L)*I);
j[U]=M[0];j[U+1]=M[1];j[U+2]=M[2];j[U+3]=M[3]}return j};E.M.P7=function(w,n,W,D){var j=new Uint32Array(W),I=1/(W-0);
for(var L=0;L<W;L++)j[L]=E.M.Hj(w,n,(D?W-1-L:L)*I);return j};E.M.pW=function(w,n,W){var D=w.Intr.v*(1/4096),j=n[0],I=n[1],U=j.length-1,M=I.length-1,L=-1,m=0,l=0,A=0,g=0;
if(n[2])m=255;else{while(L<M&&I[L+1][1]<=W)L++;if(L==-1){m=I[0][0]}else if(L==M){m=I[L][0]}else{var k=E.M.Jv(I,L,W,D);
m=k*I[L][0]+(1-k)*I[L+1][0]}}L=-1;while(L<U&&j[L+1][1]<=W)L++;if(L==-1){var $=j[0][0];l=$.o;A=$.B;g=$.k}else if(L==U){var $=j[L][0];
l=$.o;A=$.B;g=$.k}else{var C=j[L][0],f=j[L+1][0],z=E.M.Jv(j,L,W,D);l=z*C.o+(1-z)*f.o;A=z*C.B+(1-z)*f.B;
g=z*C.k+(1-z)*f.k}return[l,A,g,m]};E.M.Hj=function(w,n,W){var D=E.M.pW(w,n,W),j=~~(.5+D[0]),I=~~(.5+D[1]),U=~~(.5+D[2]),M=~~(.5+D[3]);
return M<<24|U<<16|I<<8|j};E.M.Jv=function(w,L,n,W){if(w.length==2)W*=.5;var D=w[L][1],j=w[L+1][1],I=D+w[L+1][2]*(j-D),U;
if(n<I)U=.5*(n-D)/(I-D);else U=.5+.5*(n-I)/(j-I);U=.5+.5*(W*Math.cos(Math.PI*U)+(1-W)*(1-2*U));return U};
E.M.Du=function(w,n){var W=Math.PI*w.Angl.v.val/180,D=w.Scl.v.val/100,j=w.Ofst.v,I=j.Hrzn.v.val/100,U=j.Vrtc.v.val/100,M=Math.cos(W),m=-Math.sin(W),l=.5*n.n,A=l*(M/m),g=Math.sqrt(l*l+A*A),k=.5*n.m,$=k*(m/M),C=Math.sqrt(k*k+$*$),f=Math.min(g,C)*D,z=n.x+n.m/2+I*n.m,s=n.y+n.n/2+U*n.n;
return[new ec(z,s),new ec(z+M*f,s+m*f)]};E.M.n0=function(w,n,W,D){var j=n.x-w.x,I=-(n.y-w.y),U=Math.sqrt(j*j+I*I),M=Math.atan2(I,j),m=Math.cos(M),l=-Math.sin(M),A=.5*W.n,g=A*(m/l),k=Math.sqrt(A*A+g*g),$=.5*W.m,C=$*(l/m),f=Math.sqrt($*$+C*C),z=U/Math.min(k,f),s=(w.x-W.x-W.m/2)/W.m,O=(w.y-W.y-W.n/2)/W.n;
D.Angl.v.val=180*M/Math.PI;D.Scl.v.val=z*100;var a=D.Ofst.v;a.Hrzn.v.val=s*100;a.Vrtc.v.val=O*100};E.M.WP=function(w,n){for(var L=0;
L<w.length;L++){var W=w[L],D=Math.round(W[0]*4096),j=W[1],I=W[2],U=W[3];if(I==null)I=1;if(U==null)U=.5;
var M=E.M.lW({o:j[0]*255,B:j[1]*255,k:j[2]*255});n.Clrs.v[L]={t:"Objc",v:{classID:"Clrt",Lctn:{t:"long",v:D},Mdpn:{t:"long",v:Math.round(U*100)},Clr:{t:"Objc",v:M},Type:{t:"enum",v:{Clry:"UsrS"}}}};
n.Trns.v[L]={t:"Objc",v:{classID:"TrnS",Lctn:{t:"long",v:D},Mdpn:{t:"long",v:Math.round(U*100)},Opct:{t:"UntF",v:{type:"#Prc",val:Math.round(I*100)}}}}}};
E.M.P$=function(w,n,W){function D($){return parseFloat(($/255).toFixed(3))}if(n){w=JSON.parse(JSON.stringify(w));
for(var L=0;L<2;L++){var j=w[L==0?"Clrs":"Trns"].v;for(var I=0;I<j.length;I++)j[I].v.Lctn.v=4096-j[I].v.Lctn.v;
j.reverse()}}var U=[],M=w.Clrs.v,m=w.Trns.v,j=M;if(W!=!0)j=M.concat(m);var l=E.M.oR(w,0,0);for(var L=0;
L<j.length;L++){var A=j[L].v,g=A.Lctn.v/4096,k=E.M.pW(w,l,g);U.push([g,[D(k[0]),D(k[1]),D(k[2])],D(k[3])])}U.sort(function($,C){return $[0]-C[0]});
for(var L=1;L<U.length;L++)if(U[L][0]-U[L-1][0]<.001){U.splice(L,1);L--}return U};E.c8={};E.c8.Ig=function(w,n,W,D,j,I,U,M,m,l,A,g){var k,$,C,f=Date.now(),z=!1,s=U,O=l,a,X,P,Z,Y=I*255,K=255-m*255,S=1+j*6,G=1+M*6,V=1+g*4,T=(V-1)/7,R=0,x=255-0,v,N,u,H,F,t,o,q,_,d,r,p,Q,B=0,i=1,c,h2,jX,bm,dC,fn,fK,i6,dh,kA,ig=1+A,iJ,fL=E.Q(W*D),fB=E.Q(W*D),ah=E.Q(W*D),eS=E.Q(W*D),gL=255/Y,e_=255/(255-K);
for($=0;$<D;$++){for(k=0;k<W;k++){var L=$*W+k,c2=L<<2;c=E.g7(w[c2],w[c2+1],w[c2+2]);eS[L]=c;if(c<Y)fL[L]=255-c*gL;
if(c>K)fB[L]=255-(255-c)*e_}}if(z)console.log("init",Date.now()-f);f=Date.now();if(j*s>0){ah.set(fL);
E.xX.ye(ah,fL,new iB(0,0,W,D),s)}if(M*O>0){ah.set(fB);E.xX.ye(ah,fB,new iB(0,0,W,D),O)}if(z)console.log("blur",Date.now()-f);
f=Date.now();var jS=E.Q(256),ie=E.Q(256);for(var L=0;L<256;L++){var as=L*(1/255),gb=0;gb=(1-Math.pow(1-as,S))*255;
jS[L]=Math.max(0,Math.min(255,~~(gb+.5)));gb=Math.pow(as,G)*255;ie[L]=Math.max(0,Math.min(255,~~(gb+.5)))}var gx=new Uint8ClampedArray(n.buffer),eo=new Float32Array(32768);
for(var L=0;L<32768;L++){iJ=Math.sqrt(L)*(1/128);if(ig>1)iJ=(1-iJ)*(ig-1)+1;else iJ=iJ*(ig-1)+1;eo[L]=iJ}for($=0;
$<D;$++){for(k=0;k<W;k++){var L=$*W+k,c2=L<<2,gb=eS[L],di=fL[L]*(1/255),d0=fB[L]*(1/255);gb=(1-di)*gb+di*jS[~~gb];
gb=(1-d0)*gb+d0*ie[~~gb];c=gb;var e6=w[c2],dt=w[c2+1],gJ=w[c2+2];h2=-e6*.168736-dt*.331264+gJ*.5;jX=e6*.5-dt*.418688-gJ*.081312;
iJ=eo[~~(.5+h2*h2+jX*jX)];bm=h2*iJ;fn=jX*iJ;i=1-Math.min(2-(di+d0),1);h2=i*h2+(1-i)*bm;jX=i*jX+(1-i)*fn;
i6=c+1.402*jX;dh=c-.34414*h2-.71414*jX;kA=c+1.772*h2;gx[c2]=~~(.5+i6);gx[c2+1]=~~(.5+dh);gx[c2+2]=~~(.5+kA)}}if(z)console.log("apply masks",Date.now()-f);
f=Date.now()};E.jK={};E.jK.ay=function(w,n,W,D,j){var I=!1,C=1,N=0,u=0,r=0,ig=0;if(!n.Yy(j)){var U=n.x0(j),M=E.Q(U.O()*4);
E.Cb(w,n,M,U);w=M;n=U}var m=E.Q(n.O());E.B0(W,j,m,n);E.round(m);j=j.wU(n);var l=j.m,A=j.n,g=l*3<A?2:1,k=A*3<l?2:1;
if(j.O()*(g*2+1)*(k*2+1)<n.O()){var U=new iB(j.x-l*g,j.y-A*g,l*(g*2+1),A*(k*2+1)).wU(n),M=E.Q(U.O()*4);
E.Cb(w,n,M,U);var $=E.Q(U.O());E.B0(m,n,$,U);n=U;w=M;m=$}while((n.m+n.n)/2/C>400)C++;var f=w,z=n,s=m,X=Math.floor(z.m/C),P=Math.floor(z.n/C);
w=E.Q(X*P*4);E.scale.cg(f,z.m,z.n,w,X,P,1/C);m=E.Q(X*P);E.scale.pQ(s,z.m,z.n,m,X,P,1/C);E.round(m,1);
var Z=E.Nb(m,new iB(0,0,X,P));if(Z.VY())return 1;var Y=Math.round((Z.m+Z.n)/2/15),K=Date.now(),S=E.Q(X*P*4);
E.alW(w,S);var G=Int16Array,V=new G(X*P*24),T=new G(64),R=new G(64),x=new G(64),v=new G(64);for(var H=3;
H<P-4;H++)for(var F=3;F<X-4;F++){var t=H*X+F;if(m[t]==255)continue;if(E.jK.al0(S,m,F,H,X,P,T,R,x)!=0)continue;
E.jK.vl(T,v);V[N]=F;V[N+1]=H;E.jK.nX(T,V,N+4,12);N+=16;E.jK.vl(R,v);E.jK.nX(R,V,N,4);N+=4;E.jK.vl(x,v);
E.jK.nX(x,V,N,4);N+=4;var o=V[N-24+5],q=V[N-24+6];V[N-24+5]=V[N-24+20];V[N-24+6]=V[N-24+16];V[N-24+16]=o;
V[N-24+20]=q;u++}if(u==0)return 2;if(I)console.log(Date.now()-K,"FWHT computed");K=Date.now();var _=[];
E.jK.p5(0,u-1,_,V,new G(2*24));if(I)console.log(Date.now()-K,"KD tree computed");K=Date.now();var d=new Float32Array(X*P*4);
for(var L=0;L<u;L++){var p=L,Q=E.jK.aj9(p,V,_,Y);if(Q==-1)continue;var B=p*24,i=Q*24,c=V[B],h2=V[B+1],jX=V[i],bm=V[i+1];
r+=E.jK.getError(i,B,V,1e99);var dC=jX-c,fn=bm-h2;d[(P+fn)*2*X+(X+dC)]+=1}if(I)console.log(Date.now()-K,"NN found");
K=Date.now();var fK=[],i6=1/(2*X);for(var L=0;L<d.length;L++){if(d[L]>0){var H=Math.floor(L*i6),F=L-H*2*X;
fK.push({x:F-X,y:H-P,Z:d[L],VJ:-1})}}fK.sort(function(d0,e6){return e6.Z-d0.Z});var dh=new Int32Array(X*P),kA=[];
for(var L=0;L<X*P;L++){if(m[L]==255){dh[L]=ig;kA.push(L%X,Math.floor(L/X));ig++}else if(w[(L<<2)+3]<200){dh[L]=-2}else{dh[L]=-1}}var iJ=E.jK.a6k(X,P,fK,dh,kA,ig);
if(iJ==null){return 3}var fL=iJ.jc,top=iJ.top;fL=E.jK.aiG(fL,w,X,P,top,dh,kA,ig);if(I)console.log(Date.now()-K,"optimal labeling found");
K=Date.now();var U=j.clone();U.VD(1,1);U=U.wU(z);var fB=E.Q(U.O()*4),ah=E.Q(U.O());E.Cb(f,z,fB,U);var eS=z.m,gL=z.n;
for(var H=0;H<gL;H++)for(var F=0;F<eS;F++){if(s[H*eS+F]==0)continue;var e_=Math.min(Math.floor(F/C),X-1),c2=Math.min(Math.floor(H/C),P-1),jS=dh[c2*X+e_];
if(jS==-1)continue;var ie=fL[jS],as=top[ie],gb=F+as.x*C,gx=H+as.y*C,eo=gx*eS+gb<<2,di=(H-U.y+z.y)*U.m+(F-U.x+z.x)<<2;
fB[di]=f[eo];fB[di+1]=f[eo+1];fB[di+2]=f[eo+2];fB[di+3]=f[eo+3];fB[di+3]=f[eo+3];ah[di>>2]=ie+1}if(I)console.log(Date.now()-K,"copied back");
K=Date.now();E.PZ.ay(fB,ah,U,null,1e3);if(I)console.log(Date.now()-K,"poisson smooth");K=Date.now();
E.Cb(fB,U,D,j);return 0};E.jK.GB=function(w,n,W,D,j,I){return E.jK.wg(w+j.x,n+j.y,W,D)&&I[(n+j.y)*W+(w+j.x)]==-1?0:1e9};
E.jK.aiG=function(w,n,W,D,top,j,I,U){var M=Date.now(),m=[-1,0,0,-1,1,0,0,1],l=1e99,A=[],g=[],k=2*(U*2*3+U*2),$=null,C=0,f=0,z=0,s=1e99;
while(!0&&Date.now()<M+12e3){z++;var O=null,a=l;for(var X=0;X<top.length;X++){var P=top[X],Z=0,Y=U+2,K=0;
for(var L=0;L<U;L++){var S=I[L*2],G=I[L*2+1],V=top[w[L]],T=E.jK.GB(S,G,W,D,P,j),R=w[L]==X?1e9:E.jK.GB(S,G,W,D,V,j);
for(var bK=0;bK<4;bK++){if(bK==0&&S==0||bK==1&&G==0||bK==2&&S==W-1||bK==3&&G==D-1)continue;var x=m[2*bK],v=m[2*bK+1],N=S+x,u=G+v,H=j[u*W+N];
if(H==-2){}else if(H==-1){T+=3*E.jK.EJ(N+P.x,u+P.y,N,u,W,D,n,j);T+=2*E.jK.EJ(N+P.x+x,u+P.y+v,N+x,u+v,W,D,n,j);
R+=3*E.jK.EJ(N+V.x,u+V.y,N,u,W,D,n,j);R+=2*E.jK.EJ(N+V.x+x,u+V.y+v,N+x,u+v,W,D,n,j)}else if(bK>1){if(w[L]==w[H]){var F=0;
F+=E.jK.EJ(S+V.x,G+V.y,S+P.x,G+P.y,W,D,n,j);F+=E.jK.EJ(N+V.x,u+V.y,N+P.x,u+P.y,W,D,n,j);A[Z]=L;A[Z+1]=H;
g[Z]=F;g[Z+1]=F;Z+=2}else{var t=top[w[H]],o=Y,q=0,_=0,d=0;Y++;q+=E.jK.EJ(S+V.x,G+V.y,S+P.x,G+P.y,W,D,n,j);
q+=E.jK.EJ(N+V.x,u+V.y,N+P.x,u+P.y,W,D,n,j);_+=E.jK.EJ(S+t.x,G+t.y,S+P.x,G+P.y,W,D,n,j);_+=E.jK.EJ(N+t.x,u+t.y,N+P.x,u+P.y,W,D,n,j);
d+=E.jK.EJ(S+t.x,G+t.y,S+V.x,G+V.y,W,D,n,j);d+=E.jK.EJ(N+t.x,u+t.y,N+V.x,u+V.y,W,D,n,j);A[Z]=L;A[Z+1]=o;
g[Z]=q;g[Z+1]=q;Z+=2;A[Z]=H;A[Z+1]=o;g[Z]=_;g[Z+1]=_;Z+=2;A[Z]=o;A[Z+1]=U+1;g[Z]=d;g[Z+1]=0;Z+=2}}}A[Z]=U;
A[Z+1]=L;g[Z]=T;g[Z+1]=0;Z+=2;A[Z]=L;A[Z+1]=U+1;g[Z]=R;g[Z+1]=0;Z+=2;K+=Math.min(T,R)}if(K>a)continue;
var r=E.Hq.hU(Y,Z,U,U+1,A,g,a);if(r.VF<a){a=r.VF;var p=w.slice(0);E.jK.adX(p,Z,A,r.rX,X,U);O=p}}if(a*1>=l){break}l=a;
w=O;if((z&3)==0){if(a*1.03>=s)break;s=a}if((z&3)==0){var Q=0*top.length;for(var L=0;L<top.length&&top.length>Q;
L++){if(w.indexOf(L)!=-1)continue;top.splice(L,1);for(var H=0;H<w.length;H++)if(w[H]>L)w[H]--;L--}}}return w};
E.jK.adX=function(w,n,W,D,j,I){for(var L=0;L<D.length;L++){var U=D[L]<<1,M=0,m=0;if(U<n){M=W[U];m=W[U+1]}else{m=W[U];
M=W[U+1]}if(M==I&&w[m]!=j)w[m]=j}};E.jK.Cu=function(top,w,n,W,D,j,I,U,M){for(var L=0;L<n.length;L++){var m=n[L],l=!0;
if(U!=null&&!(E.jK.wg(U+m.x,M+m.y,j,I)&&W[j*(M+m.y)+U+m.x]==-1))continue;if(m.VJ==-1)m.VJ=E.jK.ab$(m,W,D,j,I);
if(m.VJ<=0)continue;for(var A=0;A<top.length;A++){var g=top[A],k=m.x-g.x,$=m.y-g.y;if(k*k+$*$<w){l=!1;
break}}if(l)return m}return null};E.jK.ab$=function(w,n,W,D,j){var I=0;for(var L=0;L<W.length;L+=2){var U=W[L]+w.x,M=W[L+1]+w.y;
if(E.jK.wg(U,M,D,j)&&n[D*M+U]==-1)I++}return I/(W.length>>1)};E.jK.a6k=function(w,n,W,D,j,I){var top=[];
for(var L=0;L<60;L++){var U=E.jK.Cu(top,25,W,D,j,w,n);if(U==null)break;else top.push(U)}if(top.length==0)return null;
var M=[];for(var L=0;L<I;L++){var m=j[L*2],l=j[L*2+1],A=-1,g=0;while(!0){g++;var k=Math.random();A=Math.floor(k*.99999*top.length);
var $=top[A],C=m+$.x,f=l+$.y;if(E.jK.wg(C,f,w,n)&&D[f*w+C]==-1)break;if(g>100){var U;U=E.jK.Cu(top,0,W,D,j,w,n,m,l);
if(U==null)return null;top.push(U);g=0}}M.push(A)}return{top:top,jc:M}};E.jK.EJ=function(w,n,W,D,j,I,U,M){if(w==W&&n==D)return 0;
if(w<0||n<0||w>=j||n>=I||W<0||D<0||W>=j||D>=I||M[n*j+w]!=-1||M[D*j+W]!=-1)return 1e7;var m=n*j+w<<2,l=D*j+W<<2,A=U[m]-U[l],g=U[m+1]-U[l+1],k=U[m+2]-U[l+2];
return 1+(A*A+g*g+k*k)};E.jK.wg=function(w,n,W,D){return w>=0&&w<W&&n>=0&&n<D};E.jK.aj9=function(w,n,W,D){var j=24*w,I=n[j],U=n[j+1],M=D*D,m=0,k=1e9;
while(W[m]!=99)if(n[j+W[m]]<W[m+1])m=W[m+2];else m=W[m+3];var l=W[m+1],A=W[m+2],g=-1;for(var L=l;L<=A;
L++){var m=L,$=m*24,C=n[$],f=n[$+1];if((C-I)*(C-I)+(f-U)*(f-U)<M)continue;var z=E.jK.getError($,j,n,k);
if(z<k){k=z;g=m}}return g};E.jK.getError=function(w,n,W,D){var j=0;for(var I=4;I<24;I+=4){var U=W[n+I]-W[w+I],M=W[n+I+1]-W[w+I+1],m=W[n+I+2]-W[w+I+2],l=W[n+I+3]-W[w+I+3];
j+=U*U+M*M+m*m+l*l;if(j>=D)return j+1}return j};E.jK.p5=function(w,n,W,D,j){var I=16,k=0;if(n-w<=I){W.push(99,w,n);
return}E.jK.mY(w,n,D,j);var U=-1,M=-1;for(var L=4;L<24;L++){var m=j[2*L+1]-j[2*L];if(m>M){M=m;U=L}}var l=w+n>>1,A=E.jK.avB(l,w,n,D,U),g=-1;
for(var L=w;L<=n;L++)if(D[24*L+U]==A){if(g==-1)g=L;k=L}if(w+8<g&&g-w>n-k)l=g;else if(k+1<n-8)l=k+1;else if(n-w<64){W.push(99,w,n);
return}else l=l;var $=W.length;W.push(U,A,0,0);W[$+2]=$+4;E.jK.p5(w,l-1,W,D,j);W[$+3]=W.length;E.jK.p5(l,n,W,D,j)};
E.jK.mY=function(w,n,W,D){for(var L=0;L<48;L+=4){D[L]=3e4;D[L+1]=-3e4;D[L+2]=3e4;D[L+3]=-3e4}for(var L=w;
L<=n;L++){var j=L*24;for(var I=0;I<24;I++){var U=W[j+I],M=D[I<<1],m=D[(I<<1)+1];if(U<M)D[I<<1]=U;if(U>m)D[(I<<1)+1]=U}}};
E.jK.zA=function(w,n,W){var D=0,L=0;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;
L++;D=W[w+L];W[w+L]=W[n+L];W[n+L]=D;L++};E.jK.nw=function(w,n,W,D){var j=W+D>>>1,I=w[24*j+n];while(W<=D){while(w[24*W+n]<I)W++;
while(w[24*D+n]>I)D--;if(W<=D){if(w[24*W+n]!=w[24*D+n])E.jK.zA(W*24,D*24,w);W++;D--}}return W};E.jK.avB=function(w,n,W,D,j){var I=0;
while(n!=W){I=E.jK.nw(D,j,n,W);if(w<I)W=I-1;else n=I}return D[w*24+j]};E.jK.nX=function(w,n,W,D){for(var L=0;
L<D;L++)n[W+L]=w[L]};E.jK.al0=function(w,n,W,D,j,I,U,M,m){var l=(D-3)*j+(W-3),A=l<<2;for(var g=0;g<8;
g++){if(n[l]+n[l+1]+n[l+2]+n[l+3]+n[l+4]+n[l+5]+n[l+6]+n[l+7]!=0||w[A+3]<200||w[A+7]<200||w[A+11]<200||w[A+15]<200||w[A+19]<200||w[A+23]<200||w[A+27]<200||w[A+31]<200)return 1;
var L=g<<3;U[L+0]=w[A+0];M[L+0]=w[A+1];m[L+0]=w[A+2];U[L+1]=w[A+4];M[L+1]=w[A+5];m[L+1]=w[A+6];U[L+2]=w[A+8];
M[L+2]=w[A+9];m[L+2]=w[A+10];U[L+3]=w[A+12];M[L+3]=w[A+13];m[L+3]=w[A+14];U[L+4]=w[A+16];M[L+4]=w[A+17];
m[L+4]=w[A+18];U[L+5]=w[A+20];M[L+5]=w[A+21];m[L+5]=w[A+22];U[L+6]=w[A+24];M[L+6]=w[A+25];m[L+6]=w[A+26];
U[L+7]=w[A+28];M[L+7]=w[A+29];m[L+7]=w[A+30];A+=j<<2;l+=j}return 0};E.jK.vl=function(w,n){n[0]=w[32]+w[0];
n[1]=w[33]+w[1];n[2]=w[34]+w[2];n[3]=w[35]+w[3];n[4]=w[36]+w[4];n[5]=w[37]+w[5];n[6]=w[38]+w[6];n[7]=w[39]+w[7];
n[8]=w[40]+w[8];n[9]=w[41]+w[9];n[10]=w[42]+w[10];n[11]=w[43]+w[11];n[12]=w[44]+w[12];n[13]=w[45]+w[13];
n[14]=w[46]+w[14];n[15]=w[47]+w[15];n[16]=w[48]+w[16];n[17]=w[49]+w[17];n[18]=w[50]+w[18];n[19]=w[51]+w[19];
n[20]=w[52]+w[20];n[21]=w[53]+w[21];n[22]=w[54]+w[22];n[23]=w[55]+w[23];n[24]=w[56]+w[24];n[25]=w[57]+w[25];
n[26]=w[58]+w[26];n[27]=w[59]+w[27];n[28]=w[60]+w[28];n[29]=w[61]+w[29];n[30]=w[62]+w[30];n[31]=w[63]+w[31];
n[32]=w[0]-w[32];n[33]=w[1]-w[33];n[34]=w[2]-w[34];n[35]=w[3]-w[35];n[36]=w[4]-w[36];n[37]=w[5]-w[37];
n[38]=w[6]-w[38];n[39]=w[7]-w[39];n[40]=w[8]-w[40];n[41]=w[9]-w[41];n[42]=w[10]-w[42];n[43]=w[11]-w[43];
n[44]=w[12]-w[44];n[45]=w[13]-w[45];n[46]=w[14]-w[46];n[47]=w[15]-w[47];n[48]=w[16]-w[48];n[49]=w[17]-w[49];
n[50]=w[18]-w[50];n[51]=w[19]-w[51];n[52]=w[20]-w[52];n[53]=w[21]-w[53];n[54]=w[22]-w[54];n[55]=w[23]-w[55];
n[56]=w[24]-w[56];n[57]=w[25]-w[57];n[58]=w[26]-w[58];n[59]=w[27]-w[59];n[60]=w[28]-w[60];n[61]=w[29]-w[61];
n[62]=w[30]-w[62];n[63]=w[31]-w[63];w[0]=n[16]+n[0];w[1]=n[17]+n[1];w[2]=n[18]+n[2];w[3]=n[19]+n[3];
w[4]=n[20]+n[4];w[5]=n[21]+n[5];w[6]=n[22]+n[6];w[7]=n[23]+n[7];w[8]=n[24]+n[8];w[9]=n[25]+n[9];w[10]=n[26]+n[10];
w[11]=n[27]+n[11];w[12]=n[28]+n[12];w[13]=n[29]+n[13];w[14]=n[30]+n[14];w[15]=n[31]+n[15];w[16]=n[0]-n[16];
w[17]=n[1]-n[17];w[18]=n[2]-n[18];w[19]=n[3]-n[19];w[20]=n[4]-n[20];w[21]=n[5]-n[21];w[22]=n[6]-n[22];
w[23]=n[7]-n[23];w[24]=n[8]-n[24];w[25]=n[9]-n[25];w[26]=n[10]-n[26];w[27]=n[11]-n[27];w[28]=n[12]-n[28];
w[29]=n[13]-n[29];w[30]=n[14]-n[30];w[31]=n[15]-n[31];n[0]=w[8]+w[0];n[1]=w[9]+w[1];n[2]=w[10]+w[2];
n[3]=w[11]+w[3];n[4]=w[12]+w[4];n[5]=w[13]+w[5];n[6]=w[14]+w[6];n[7]=w[15]+w[7];n[8]=w[0]-w[8];n[9]=w[1]-w[9];
n[10]=w[2]-w[10];n[11]=w[3]-w[11];n[12]=w[4]-w[12];n[13]=w[5]-w[13];n[14]=w[6]-w[14];n[15]=w[7]-w[15];
w[0]=n[4]+n[0];w[1]=n[5]+n[1];w[2]=n[6]+n[2];w[3]=n[7]+n[3];w[4]=n[0]-n[4];w[5]=n[1]-n[5];w[6]=n[2]-n[6];
w[7]=n[3]-n[7];w[8]=n[12]+n[8];w[9]=n[13]+n[9];w[10]=n[14]+n[10];w[11]=n[15]+n[11];w[12]=n[8]-n[12];
w[13]=n[9]-n[13];w[14]=n[10]-n[14];w[15]=n[11]-n[15];n[0]=w[2]+w[0];n[1]=w[3]+w[1];n[2]=w[0]-w[2];n[3]=w[1]-w[3];
n[4]=w[6]+w[4];n[5]=w[7]+w[5];n[6]=w[4]-w[6];n[7]=w[5]-w[7];n[8]=w[10]+w[8];n[9]=w[11]+w[9];n[10]=w[8]-w[10];
n[11]=w[9]-w[11];n[12]=w[14]+w[12];n[13]=w[15]+w[13];n[14]=w[12]-w[14];n[15]=w[13]-w[15];w[0]=n[1]+n[0];
w[1]=n[0]-n[1];w[2]=n[3]+n[2];w[3]=n[2]-n[3];w[4]=n[5]+n[4];w[5]=n[4]-n[5];w[6]=n[7]+n[6];w[7]=n[6]-n[7];
w[8]=n[9]+n[8];w[9]=n[8]-n[9];w[10]=n[11]+n[10];w[11]=n[10]-n[11];w[12]=n[13]+n[12];w[13]=n[12]-n[13];
w[14]=n[15]+n[14];w[15]=n[14]-n[15]};E.jK.aqx=function(){var w="",bK=64,n="v",W="t",D="a",j=5,L,I,U;
for(L=bK>>1;L>0;L>>=1,j--){for(I=0;I<bK;I++){U=(I>>j&1)!=0;if(U){w+=W+"["+I+"] = "+n+"["+(-L+I)+"] - "+n+"["+I+"]; "}else{w+=W+"["+I+"] = "+n+"["+(L+I)+"] + "+n+"["+I+"]; "}}D=n;
n=W;W=D;w+="\n"}console.log(w)};E.jK.a1D=function(bK,w,n){var W=w,D=n,j=W,I=0,L,M,m;while(bK>>I!=2)I++;
var U=I;for(L=bK>>1;L>0;L>>=1,I--){for(M=0;M<bK;M++){m=(M>>I&1)!=0;if(m)D[M]=W[-L+M]-W[M];else D[M]=W[L+M]+W[M]}j=W;
W=D;D=j}if((U&1)==1)for(L=0;L<bK;L++)n[L]=W[L]};E.wH={};E.wH.U$=function(w,n,W,D,j,I,U,M,m){var l=Date.now(),A=new Uint32Array(w.buffer),g=new Uint32Array(n.buffer),k=U/W,$=M/D,C=1/k,f=1/$,z=new Float64Array(2),s=3,O=1/s,a=1/(s*s),X=0,P=0,Z=W,Y=D;
if(j){X=j.x;P=j.y;Z=j.m;Y=j.n}for(var K=0;K<Y;K++)for(var S=0;S<Z;S++){var G=X+S,V=P+K,L=V*W+G,T=L<<1,R=L<<2;
E.wH.a1C(I,U,M,(G+.5)*k,(V+.5)*$,z);var x=z[0]*C,v=z[1]*f;if(x==0&&v==0)g[L]=A[L];else{E.K.hC(G+x+.5,V+v+.5,A,W,D,g,L,m)}}};
E.wH.a1C=function(w,n,W,D,j,I){D-=.499999;j-=.499999;var U=~~D,M=~~j,m=D-U,l=j-M,A=(1-l)*(1-m),g=(1-l)*m,k=l*(1-m),$=l*m,C=U<n-1?U+1:U,f=M<W-1?M+1:M,z=M*n+U<<1,s=M*n+C<<1,O=f*n+U<<1,a=f*n+C<<1;
I[0]=A*w[z]+g*w[s]+k*w[O]+$*w[a];I[1]=A*w[z+1]+g*w[s+1]+k*w[O+1]+$*w[a+1]};E.wH.a7O=function(w,n,W,D,j){var I=1/w,U=[-1,1,-w,w],M=D.length;
for(var m=0;m<M;m++){var L=D[m],l=L<<1,A=m<<1,g=~~(L*I),k=L-w*g,$=W[l],C=W[l+1],f=0,z=0;if(k!=0&&k!=w-1){var s=L-1<<1,O=L+1<<1,a=W[s],X=W[O],P=W[s+1],Z=W[O+1],Y=$-(a+X)*.5,K=C-(P+Z)*.5;
f-=Y*j;z-=K*j}if(g!=0&&g!=n-1){var s=L-w<<1,O=L+w<<1,a=W[s],X=W[O],P=W[s+1],Z=W[O+1],Y=$-(a+X)*.5,K=C-(P+Z)*.5;
f-=Y*j;z-=K*j}W[l]=$+f;W[l+1]=C+z}};E.wH.agu=function(w,n){var W=w+","+n;if(E.wH.RS==W)return E.wH._v;
var D=E.wH._v=[];E.wH.RS=W;for(var L=0;L<=1e3;L++){var j=L*.001,I=Math.sqrt(j),U=Math.exp(-4*I),M=.96*(1-I*I),m=n*((1-w)*U+w*M);
D[L]=m}return D};E.wH.RS="";E.wH._v=[];E.wH.a9Y=function(w,n,W,D,j,I,U,M,m,l,A,g,k){var $=Math.max(0,Math.floor(j-U-1)),C=Math.min(n,Math.ceil(j+U+1)),f=Math.max(0,Math.floor(I-U-1)),z=Math.min(W,Math.ceil(I+U+1)),s=2*n,O=U*U,a=1/U,X=0;
if(k&&(D==3||D==6))m=-m;var P=E.wH.agu(M,m);for(var Z=f;Z<z;Z++)for(var Y=$;Y<C;Y++){var L=Z*n+Y,K=L<<1,S=(j-Y)*a,G=(I-Z)*a,V=S*S+G*G;
if(V<1){g[X]=L;var T=P[~~(V*1e3)];if(D==1){w[K]=w[K]*(1-T*.05);w[K+1]=w[K+1]*(1-T*.05)}else{var R=0,x=0,u,H,F,t;
if(D==0){R=l*T;x=A*T}else if(D==2){}else if(D==3){R=T*G;x=-T*S}else if(D==4){R=T*S;x=T*G}else if(D==5){R=-T*S;
x=-T*G}else if(D==6){R=A*T;x=-l*T}var v=w[K],N=w[K+1];if(Y==0||Y!=n-1&&R<0){u=1+w[K+2]-v;F=w[K+3]-N}else{u=v-w[K-2]+1;
F=N-w[K-1]}if(Z==0||Z!=W-1&&x<0){H=w[K+s]-v;t=1+w[K+s+1]-N}else{H=v-w[K-s];t=N-w[K-s+1]+1}w[K]=-(u*R+H*x-v);
w[K+1]=-(F*R+t*x-N)}X++}}};E.wH.arQ=function(w){var n=w[0],W=w[0],D=w[1],j=w[1];for(var L=0;L<w.length;
L+=2){var I=w[L],U=w[L+1];if(I<n)n=I;else if(I>W)W=I;if(U<D)D=U;else if(U>j)j=U}return[n,D,W,j]};E.aef=function(w,n,W,D,j){function I(c,h2,jX,bm){return Math.sqrt((c-jX)*(c-jX)+(h2-bm)*(h2-bm))}function U(c,h2){return c>=0&&c<n&&h2>=0&&h2<W}function M(c){if(c<0)return 0;
if(c>=n)return n-1;return c}function m(c){if(c<0)return 0;if(c>=W)return W-1;return c}function l(L,c){var h2=c[3]*(1/255),jX=D[L]+c[0]*h2;
if(jX>255)jX=255;D[L]=jX;jX=D[L+1]+c[1]*h2;if(jX>255)jX=255;D[L+1]=jX;jX=D[L+2]+c[2]*h2;if(jX>255)jX=255;
D[L+2]=jX}function A(c,h2,jX){if(!o(c,h2))return;if(jX[3]<0)jX[3]=0;l((h2*n+c)*4,jX)}function g(c){var h2=c.slice(0,3);
h2[3]=0;return h2}var k=n/800;function $(c){return Math.round(c*k)}function C(){for(var L=0;L<=300;L++){_[L]=f(L)}}function f(W){var c=.8,h2=.2,jX=c*h2,bm=W/60%2-1,dC=jX*(1-bm*bm),fn=h2-jX,fK;
if(W<60){fK=[jX+fn,dC,0]}else if(W<120){fK=[dC,jX,0]}else if(W<180){fK=[0,jX,dC]}else if(W<240){fK=[0,dC,jX]}else if(W<300){fK=[dC,0,jX]}else{fK=[jX,0,dC]}return[(fK[0]+fn)*255,(fK[1]+fn)*255,(fK[2]+fn)*255]}function z(W){return _[~~W]}function s(c){return 1-O(c)}function O(c){return c-~~c}function a(c,h2,jX,bm){F(c,h2,jX,0,h2+1,1,bm)}function X(c,h2,jX,bm,dC,fn){F(c,h2,jX,0,bm,1,dC,fn)}function P(c){for(var L=0;
L<D.length;L+=4){l(L,c)}}function Z(c,h2,jX,bm,dC,fn,fK,i6){Y(c,h2,jX,bm,dC,1,fn,fK,i6)}function Y(c,h2,jX,bm,dC,fn,fK,i6,dh){if(fn==null)fn=.5;
if(fK==null)fK=0;if(i6==null)i6=0;if(dh==null)dh=!1;var kA=c.x,ig=c.y,iJ=jX.slice(0),fL=~~(jX[3]*r);
bm=bm*r;if(!dh){h2=t(h2);dC=t(dC);fK=t(fK);i6=t(i6)}var fB=M(kA-h2),ah=M(kA+h2);for(var eS=fB;eS<=ah;
eS++){var gL=eS-kA,e_=Math.floor(Math.sqrt(h2*h2-gL*gL)),c2=m(ig-e_),jS=m(ig);for(var ie=c2;ie<=jS;ie++){var as=I(eS,ie,kA,ig);
if(as>h2||as<=h2-dC)break;var gb=(as-h2+dC)/dC;iJ[3]=fL-bm*(fn==1?gb:Math.pow(gb,fn));l((ie*n+eS)*4,iJ)}c2=m(ig+e_);
for(var ie=c2;ie>jS;ie--){var as=I(eS,ie,kA,ig);if(as>h2||as<=h2-dC)break;var gb=(as-h2+dC)/dC;iJ[3]=fL-bm*(fn==1?gb:Math.pow(gb,fn));
l((ie*n+eS)*4,iJ)}}if(fK>0){F(c,h2+fK,iJ,iJ[3],fK,1,0,0,!0)}if(i6>0){F(c,h2-dC,q(jX),-jX[3],i6,1,0,0,!0)}}function K(c,h2,jX,bm,dC,fn){F(c,h2,jX,jX[3],h2+1,1,bm,dC,fn)}function S(c,h2,jX,bm,dC){if(dC==null)dC=!1;
var fn=c.x,fK=c.y;bm*=r;if(!dC){h2=t(h2);jX=t(jX)}var i6=M(fn-h2),dh=M(fn+h2);for(var kA=i6;kA<dh;kA++){var ig=kA-fn,iJ=~~Math.sqrt(h2*h2-ig*ig),fL=m(fK-iJ),fB=m(fK);
for(var ah=fL;ah<=fB;ah++){var eS=I(kA,ah,fn,fK);if(eS>h2||eS<=h2-jX)break;var gL=(h2-eS)/jX,e_=z(300*gL);
e_[3]=bm;l((ah*n+kA)*4,e_)}fL=m(fK+iJ);for(var ah=fL;ah>fB;ah--){var eS=I(kA,ah,fn,fK);if(eS>h2||eS<=h2-jX)break;
var gL=(h2-eS)/jX,e_=z(300*gL);e_[3]=bm;l((ah*n+kA)*4,e_)}}}function G(d,c){var h2=d.ds,jX=d.Wh,bm=c.slice(0),dC=c[3]*r,fn=Math.abs(jX.y-h2.y)>Math.abs(jX.x-h2.x);
if(fn){var fK=h2.x;h2.x=h2.y;h2.y=fK;fK=jX.x;jX.x=jX.y;jX.y=fK}if(h2.x>jX.x){var fK=h2;h2=jX;jX=fK}var i6=jX.x-h2.x,dh=jX.y-h2.y,kA=i6==0?1:dh/i6,ig=Math.round(h2.x),iJ=h2.y+kA*(ig-h2.x),fL=s(h2.x+.5),fB=ig,ah=~~iJ;
if(fn){bm[3]=dC*s(iJ)*fL;A(ah,fB,bm);bm[3]=dC*O(iJ)*fL;A(ah+1,fB,bm)}else{bm[3]=dC*s(iJ)*fL;A(fB,ah,bm);
bm[3]=dC*O(iJ)*fL;A(fB,ah+1,bm)}var eS=iJ-kA;ig=Math.round(jX.x);iJ=jX.y+kA*(ig-jX.x);fL=O(jX.x+.5);
var gL=ig,e_=~~iJ;if(fn){bm[3]=dC*s(iJ)*fL;A(e_,gL,bm);bm[3]=dC*O(iJ)*fL;A(e_+1,gL,bm)}else{bm[3]=dC*s(iJ)*fL;
A(gL,e_,bm);bm[3]=dC*O(iJ)*fL;A(gL,e_+1,bm)}if(fn){for(var c2=fB+1;c2<=gL-1;c2++){bm[3]=dC*s(eS);A(~~eS,c2,bm);
bm[3]=dC*O(eS);A(~~eS+1,c2,bm);eS+=kA}}else{for(var c2=fB+1;c2<=gL-1;c2++){bm[3]=dC*s(eS);A(c2,~~eS,bm);
bm[3]=dC*O(eS);A(c2,~~eS+1,bm);eS+=kA}}}function V(c,h2,jX,bm){for(var L=0;L<4;L++){var dC=c.di(h2+1.3*L,jX);
G(dC,bm,1)}}function ec(c,h2){this.x=Math.round(c);this.y=Math.round(h2)}var T=Math.PI/180;ec.prototype.di=function(c,h2){c=c*T;
var jX=this.x+h2*Math.cos(c),bm=this.y+h2*Math.sin(c);return new R(this.x,this.y,jX,bm)};ec.prototype.a6K=function(c,h2){c=c*T;
var jX=this.Pn+h2*Math.cos(c),bm=this.a4j+h2*Math.sin(c);return new ec(jX,bm)};function R(c,h2,jX,bm){this.ds=new ec(c,h2);
this.Wh=new ec(jX,bm)}R.prototype.fk=function(c){var h2=c*this.ds.x+(1-c)*this.Wh.x,jX=c*this.ds.y+(1-c)*this.Wh.y;
return new ec(h2,jX)};var x=Z,v=K,N=a,u=X,H=S,F=Y,t=$,o=U,q=g,_=[];C();for(var L=0;L<w.length;L++){D[L]=w[L]}var d=new R(n*j[2],W*j[3],n/2,W/2),r=j[1],p=[];
p[0]=function Q(){var c=[80,40,15,60],jX=0,bm=0;N(d.fk(1.4),260,c,10);N(d.fk(1),100,[240,50,50,30],30);
v(d.fk(1),60,[255,40,0,40]);var h2=[255,255,255,255];F(d.fk(1),70,h2,h2[3],58,.5);N(d.fk(1),12,h2);h2[3]=40;
x(d.fk(1),150,h2,h2[3],150);for(var L=0;L<40;L++){jX+=Math.random()*25;bm=Math.random()*t(300)+t(100);
var dC=d.fk(1).di(jX,bm);G(d.fk(1).di(jX,bm),[110,110,110,30])}v(d.fk(1),130,[255,255,255,8]);var fn=[170,30,23,70];
u(d.fk(1),70,fn,1,3,3);var fK=[60,60,130,40];N(d.fk(.47),44,fK,5);N(d.fk(.43),22,fK,3);fK[3]=16;N(d.fk(.53),15,fK,2);
var i6=[138,94,42,100];N(d.fk(.2),16,i6,2);var dh=[130,255,170,180];v(d.fk(0),4,dh);v(d.fk(-.25),5,dh);
i6=[150,90,0,50];x(d.fk(-.45),55,q(i6),-i6[3],40,2);N(d.fk(-.42),35,i6,2);N(d.fk(-.5),15,i6,2);H(d.fk(-1.28),145,11,70);
var kA=z(0);kA[3]=50;x(d.fk(-1.28),149,kA,kA[3],4);kA=z(300);kA[3]=50;x(d.fk(-1.28),155-1,q(kA),-kA[3],3);
var ig=[130,130,10,50];u(d.fk(-1),73,ig,3,2);var iJ=[40,130,70,40];x(d.fk(-1),70,q(iJ),-iJ[3],35);iJ=[40,170,60,50];
N(d.fk(-.7),25,iJ,4);var iJ=[70,110,50,60];x(d.fk(1.3),30,q(iJ),-iJ[3],11,3);fK=[0,50,210,80];v(d.fk(-.72),20,fK)};
p[1]=function B(){v(d.fk(1),150,[240,70,70,60]);N(d.fk(1),100,[200,60,60,40],30);var c=[255,255,255,255],h2=0,jX=0;
F(d.fk(1),75,c,c[3],63);N(d.fk(1),12,c);v(d.fk(1),270,[200,200,200,20],10);for(var L=0;L<10;L++){h2+=10+Math.random()*40;
jX=Math.random()*t(250)+t(80);var bm=d.fk(1).di(h2,jX);G(bm,[110,110,110,35])}h2=5;jX=100;for(var L=0;
L<12;L++){h2+=30;V(d.fk(1),h2,jX,[90,90,90,40])}var dC=[150,40,23,100];u(d.fk(1),70,dC,1,3,3);var fn=[30,100,60,40];
v(d.fk(-.9),180,[255,255,255,20]);N(d.fk(-.9),140,fn,15);var fK=[170,80,25,15];u(d.fk(-.9),120,fK,1,4,4);
var i6=[110,240,190,200];v(d.fk(-.6),3,i6);i6[3]=100;v(d.fk(-.6),7,i6);var dh=[230,120,40,85];v(d.fk(-.73),9,dh);
var kA=[60,60,190,50];N(d.fk(.3),28,kA,6);kA[3]=25;N(d.fk(.34),20,kA,3)};p[2]=function i(){var c=[255,255,255,255],jX=0,bm=0;
N(d.fk(1),13,c);F(d.fk(1),150,c,c[3],137);var h2=[120,80,35,20];N(d.fk(1.4),260,h2,10);for(var L=0;L<40;
L++){jX+=5+Math.random()*30;bm=Math.random()*t(300);G(d.fk(1).di(jX,bm),[110,110,110,20])}var dC=[10,30,255,30];
N(d.fk(1),70,dC,50);var fn=[15,90,170,15];N(d.fk(1.5),60,fn);var fK=[220,220,20,50];N(d.fk(-1.15),8,fK,2);
var c=[255,255,255,40];v(d.fk(-1.18),6,c);v(d.fk(-1.18),4,c);fK=[110,110,10,8];x(d.fk(-1.2),32,q(fK),-fK[3],20,3);
var i6=[5,0,16,255];for(var L=0;L<4;L++){N(d.fk(-1.36),10,i6,3)}var dh=[90,200,150,20],kA=dh.slice(0);
kA[3]*=2;N(d.fk(-1.32),7,kA,3);N(d.fk(-1.36),7,kA,3);N(d.fk(-1.4),7,kA,3);var c=[230,230,230,100];v(d.fk(-1.36),2,c);
c[3]=3;N(d.fk(-.55),10,c);fK=[120,100,10,18];N(d.fk(-.55),160,fK,8);N(d.fk(-.55),80,fK,4);dh[3]=3;kA[3]=6;
x(d.fk(-.49),13,q(kA),-kA[3],13,2);x(d.fk(-.55),13,q(kA),-kA[3],13,2);dh[3]=20;N(d.fk(.15),25,dh,3);
fK[3]=100;v(d.fk(-.52),3,fK);fK=[200,200,50,40];N(d.fk(.27),1,fK,4);var ig=[150,40,23,30];x(d.fk(1),80,q(ig),-ig[3],2,1)};
return p[j[0]]()};E.GY={};E.GY.nJ=function(w){var n=w.length,bK=w[0].length,W=new Array(bK);for(var L=0;
L<bK;L++)W[L]=new Array(n);for(var L=0;L<bK;L++)for(var D=0;D<n;D++)W[L][D]=w[D][L];return W};E.GY.eu=function(w,n){var W=w.length,bK=w[0].length,D=new Array(W);
for(var L=0;L<W;L++)D[L]=new Array(bK);for(var L=0;L<W;L++)for(var j=0;j<bK;j++)D[L][j]=w[L][j]-n[L][j];
return D};E.GY.add=function(w,n){var W=w.length,bK=w[0].length,D=new Array(W);for(var L=0;L<W;L++)D[L]=new Array(bK);
for(var L=0;L<W;L++)for(var j=0;j<bK;j++)D[L][j]=w[L][j]+n[L][j];return D};E.GY.multiply=function(w,n){var W=w.length,D=w[0].length,bK=n[0].length;
if(D!=n.length)throw"e";var j=new Array(W);for(var L=0;L<W;L++)j[L]=new Array(bK);if((D&1)!=0)for(var L=0;
L<W;L++){var I=w[L],U=j[L];for(var M=0;M<bK;M++){var m=0;for(var l=0;l<D;l++)m+=I[l]*n[l][M];U[M]=m}}else for(var L=0;
L<W;L++){var I=w[L],U=j[L];for(var M=0;M<bK;M++){var m=0;for(var l=0;l<D;l+=2)m+=I[l]*n[l][M]+I[l+1]*n[l+1][M];
U[M]=m}}return j};E.GY.uo=function(w,n){var W=w.length,bK=w[0].length,D=new Array(W);for(var L=0;L<W;
L++){var j=0;for(var I=0;I<bK;I++)j+=w[L][I]*n[I];D[L]=j}return D};E.GY.Gx=function(w,n){var W=[];for(var L=0;
L<w;L++){W.push([]);for(var D=0;D<n;D++)W[L].push(0)}return W};E.GY.ar$=function(w){for(var L=0;L<w.length;
L++)console.log(JSON.stringify(w[L]))};E.GY.ace=function(w){var n=[];for(var L=0;L<w.length;L++)n.push(w[L].join(","));
return"["+n.join(";")+"]"};E.GY.hU=function(w,n){var W=w.length;for(var D=0;D<W;D++){var j=0,I=Number.NEGATIVE_INFINITY;
for(var L=D;L<W;L++)if(Math.abs(w[L][D])>I){j=L;I=Math.abs(w[L][D])}E.GY.a53(w,D,j);for(var L=D+1;L<W;
L++){if(w[D][D]==0)return 1;var U=w[L][D]/w[D][D];for(var M=D;M<W+1;M++)w[L][M]-=w[D][M]*U}}for(var L=W-1;
L>=0;L--){if(w[L][L]==0)return 1;var m=w[L][W]/w[L][L];n[L]=m;for(var M=L-1;M>=0;M--){w[M][W]-=w[M][L]*m;
w[M][L]=0}}return 0};E.GY.a53=function(w,n,W){var D=w[n];w[n]=w[W];w[W]=D};E.GY.aaP=function(w){var n=w.length,W=E.GY.Gx(n,n);
for(var L=0;L<n;L++)W[L][L]=w[L];return W};E.GY.aew=function(w){var n=w.length,W=w[0].length,D=new Array(n);
for(var L=0;L<n;L++){D[L]=0;for(var j=0;j<W;j++)D[L]+=w[L][j];D[L]/=W}return D};E.GY.Hx=function(w){var n=0;
for(var L=0;L<w.length;L++)n+=w[L]*w[L];return Math.sqrt(n)};E.Mv={};E.Mv.Tb=function(w){var n=~~(w+.5);
return n<0?0:n>255?255:n};E.Mv.transform=function(w,n,W){var D=E.Mv.Tb,j=w.o.length;for(var L=0;L<j;
L++){var I=w.o[L],U=w.B[L],M=w.k[L];n.o[L]=D(W[0]*I+W[1]*U+W[2]*M+W[3]*255);n.B[L]=D(W[4]*I+W[5]*U+W[6]*M+W[7]*255);
n.k[L]=D(W[8]*I+W[9]*U+W[10]*M+W[11]*255)}};E.Mv.V9=function(w,n,W){var D=E.Mv.Tb,j=w.length;for(var L=0;
L<j;L+=4){var I=w[L],U=w[L+1],M=w[L+2];n[L]=D(W[0]*I+W[1]*U+W[2]*M+W[3]*255);n[L+1]=D(W[4]*I+W[5]*U+W[6]*M+W[7]*255);
n[L+2]=D(W[8]*I+W[9]*U+W[10]*M+W[11]*255)}};E.Mv.oN=function(w){var n=w[0]+w[1]+w[2],W=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1];
if(n==1){var D=w.indexOf(1);W[D]=W[D+4]=W[D+8]=1}else{W[0]=w[0];W[5]=w[1];W[10]=w[2]}return W};E.Mv.CD=function(w,n,W){return[1,0,0,w,0,1,0,n,0,0,1,W,0,0,0,1]};
E.Mv.Os=function(w,n,W){return[w,0,0,0,0,n,0,0,0,0,W,0,0,0,0,1]};E.Mv.arb=function(w){return[w[0],w[1],w[2],w[4],w[5],w[6],w[8],w[9],w[10]]};
E.Mv.Vr=function(w){return[w[0],w[1],w[2],0,w[3],w[4],w[5],0,w[6],w[7],w[8],0,0,0,0,1]};E.Mv.q4=function(w,n){return[w[0]*n[0]+w[1]*n[1]+w[2]*n[2]+w[3]*n[3],w[4]*n[0]+w[5]*n[1]+w[6]*n[2]+w[7]*n[3],w[8]*n[0]+w[9]*n[1]+w[10]*n[2]+w[11]*n[3],w[12]*n[0]+w[13]*n[1]+w[14]*n[2]+w[15]*n[3]]};
E.Mv.nJ=function(w){var n=[];n[0]=w[0];n[1]=w[4];n[2]=w[8];n[3]=w[12];n[4]=w[1];n[5]=w[5];n[6]=w[9];
n[7]=w[13];n[8]=w[2];n[9]=w[6];n[10]=w[10];n[11]=w[14];n[12]=w[3];n[13]=w[7];n[14]=w[11];n[15]=w[15];
return n};E.Mv.add=function(w,n){var W=w.slice(0);for(var L=0;L<16;L++)W[L]+=n[L];return W};E.Mv.multiply=function(w,n){var W=[];
W[0]=w[0]*n[0]+w[1]*n[4]+w[2]*n[8]+w[3]*n[12];W[1]=w[0]*n[1]+w[1]*n[5]+w[2]*n[9]+w[3]*n[13];W[2]=w[0]*n[2]+w[1]*n[6]+w[2]*n[10]+w[3]*n[14];
W[3]=w[0]*n[3]+w[1]*n[7]+w[2]*n[11]+w[3]*n[15];W[4]=w[4]*n[0]+w[5]*n[4]+w[6]*n[8]+w[7]*n[12];W[5]=w[4]*n[1]+w[5]*n[5]+w[6]*n[9]+w[7]*n[13];
W[6]=w[4]*n[2]+w[5]*n[6]+w[6]*n[10]+w[7]*n[14];W[7]=w[4]*n[3]+w[5]*n[7]+w[6]*n[11]+w[7]*n[15];W[8]=w[8]*n[0]+w[9]*n[4]+w[10]*n[8]+w[11]*n[12];
W[9]=w[8]*n[1]+w[9]*n[5]+w[10]*n[9]+w[11]*n[13];W[10]=w[8]*n[2]+w[9]*n[6]+w[10]*n[10]+w[11]*n[14];W[11]=w[8]*n[3]+w[9]*n[7]+w[10]*n[11]+w[11]*n[15];
W[12]=w[12]*n[0]+w[13]*n[4]+w[14]*n[8]+w[15]*n[12];W[13]=w[12]*n[1]+w[13]*n[5]+w[14]*n[9]+w[15]*n[13];
W[14]=w[12]*n[2]+w[13]*n[6]+w[14]*n[10]+w[15]*n[14];W[15]=w[12]*n[3]+w[13]*n[7]+w[14]*n[11]+w[15]*n[15];
return W};E.Mv.Ba=function(w){var n=[];n[0]=w[5]*w[10]*w[15]-w[5]*w[14]*w[11]-w[6]*w[9]*w[15]+w[6]*w[13]*w[11]+w[7]*w[9]*w[14]-w[7]*w[13]*w[10];
n[1]=-w[1]*w[10]*w[15]+w[1]*w[14]*w[11]+w[2]*w[9]*w[15]-w[2]*w[13]*w[11]-w[3]*w[9]*w[14]+w[3]*w[13]*w[10];
n[2]=w[1]*w[6]*w[15]-w[1]*w[14]*w[7]-w[2]*w[5]*w[15]+w[2]*w[13]*w[7]+w[3]*w[5]*w[14]-w[3]*w[13]*w[6];
n[3]=-w[1]*w[6]*w[11]+w[1]*w[10]*w[7]+w[2]*w[5]*w[11]-w[2]*w[9]*w[7]-w[3]*w[5]*w[10]+w[3]*w[9]*w[6];
n[4]=-w[4]*w[10]*w[15]+w[4]*w[14]*w[11]+w[6]*w[8]*w[15]-w[6]*w[12]*w[11]-w[7]*w[8]*w[14]+w[7]*w[12]*w[10];
n[5]=w[0]*w[10]*w[15]-w[0]*w[14]*w[11]-w[2]*w[8]*w[15]+w[2]*w[12]*w[11]+w[3]*w[8]*w[14]-w[3]*w[12]*w[10];
n[6]=-w[0]*w[6]*w[15]+w[0]*w[14]*w[7]+w[2]*w[4]*w[15]-w[2]*w[12]*w[7]-w[3]*w[4]*w[14]+w[3]*w[12]*w[6];
n[7]=w[0]*w[6]*w[11]-w[0]*w[10]*w[7]-w[2]*w[4]*w[11]+w[2]*w[8]*w[7]+w[3]*w[4]*w[10]-w[3]*w[8]*w[6];n[8]=w[4]*w[9]*w[15]-w[4]*w[13]*w[11]-w[5]*w[8]*w[15]+w[5]*w[12]*w[11]+w[7]*w[8]*w[13]-w[7]*w[12]*w[9];
n[9]=-w[0]*w[9]*w[15]+w[0]*w[13]*w[11]+w[1]*w[8]*w[15]-w[1]*w[12]*w[11]-w[3]*w[8]*w[13]+w[3]*w[12]*w[9];
n[10]=w[0]*w[5]*w[15]-w[0]*w[13]*w[7]-w[1]*w[4]*w[15]+w[1]*w[12]*w[7]+w[3]*w[4]*w[13]-w[3]*w[12]*w[5];
n[11]=-w[0]*w[5]*w[11]+w[0]*w[9]*w[7]+w[1]*w[4]*w[11]-w[1]*w[8]*w[7]-w[3]*w[4]*w[9]+w[3]*w[8]*w[5];n[12]=-w[4]*w[9]*w[14]+w[4]*w[13]*w[10]+w[5]*w[8]*w[14]-w[5]*w[12]*w[10]-w[6]*w[8]*w[13]+w[6]*w[12]*w[9];
n[13]=w[0]*w[9]*w[14]-w[0]*w[13]*w[10]-w[1]*w[8]*w[14]+w[1]*w[12]*w[10]+w[2]*w[8]*w[13]-w[2]*w[12]*w[9];
n[14]=-w[0]*w[5]*w[14]+w[0]*w[13]*w[6]+w[1]*w[4]*w[14]-w[1]*w[12]*w[6]-w[2]*w[4]*w[13]+w[2]*w[12]*w[5];
n[15]=w[0]*w[5]*w[10]-w[0]*w[9]*w[6]-w[1]*w[4]*w[10]+w[1]*w[8]*w[6]+w[2]*w[4]*w[9]-w[2]*w[8]*w[5];var W=w[0]*n[0]+w[1]*n[4]+w[2]*n[8]+w[3]*n[12];
for(var L=0;L<16;L++)n[L]/=W;return n};E.Mv.a9F=function(w){var n=[],W=w[5]*w[10]*w[15]-w[5]*w[14]*w[11]-w[6]*w[9]*w[15]+w[6]*w[13]*w[11]+w[7]*w[9]*w[14]-w[7]*w[13]*w[10],D=-w[4]*w[10]*w[15]+w[4]*w[14]*w[11]+w[6]*w[8]*w[15]-w[6]*w[12]*w[11]-w[7]*w[8]*w[14]+w[7]*w[12]*w[10],j=w[4]*w[9]*w[15]-w[4]*w[13]*w[11]-w[5]*w[8]*w[15]+w[5]*w[12]*w[11]+w[7]*w[8]*w[13]-w[7]*w[12]*w[9],I=-w[4]*w[9]*w[14]+w[4]*w[13]*w[10]+w[5]*w[8]*w[14]-w[5]*w[12]*w[10]-w[6]*w[8]*w[13]+w[6]*w[12]*w[9];
return w[0]*W+w[1]*D+w[2]*j+w[3]*I};E.Mv.anV=function(w,n,W,D){var j=Math.sin(D),I=Math.cos(D),U=1/Math.sqrt(w*w+n*n+W*W);
w*=U;n*=U;W*=U;return E.Mv.Vr([w*w*(1-I)+I,w*n*(1-I)-W*j,w*W*(1-I)+n*j,w*n*(1-I)+W*j,n*n*(1-I)+I,n*W*(1-I)-w*j,w*W*(1-I)-n*j,n*W*(1-I)+w*j,W*W*(1-I)+I])};
E.Mv.WE=E.Mv.Vr([3.1338561,-1.6168667,-.4906146,-.9787684,1.9161415,.033454,.0719453,-.2289914,1.4052427]);
E.Mv.awF=E.Mv.Vr([1.9624274,-.6105343,-.3413404,-.9787684,1.9161415,.033454,.0286869,-.1406752,1.3487655]);
E.Mv.Lv=E.Mv.Ba(E.Mv.WE);E.Hq={};E.Hq.jj=new Uint32Array(1);E.Hq.tm=function(w,n,W,D,j,I){var U=new Uint32Array(w),M=0,m=E.Hq.jj;
if(m.length<n*4)E.Hq.jj=m=new Uint32Array(n*4);var l=new Float64Array(m.buffer);for(var L=0;L<n;L+=2){var A=j[L],g=j[L+1],k=I[L],$=I[L+1];
m[M]=g;l[M+2>>1]=k;m[M+1]=U[A];U[A]=M+1;M+=4;m[M]=A;l[M+2>>1]=$;m[M+1]=U[g];U[g]=M+1;M+=4}return{mN:m,ath:l,am4:U}};
E.Hq.hU=function(w,n,W,D,j,I,U){var M=1,m=E.Hq.tm(w,n,W,D,j,I),l=m.mN,A=m.ath,g=m.am4,k=new Uint32Array(w),$=new E.Hq.ax(w),f=1,X=0;
$.push(W);$.push(D);var C=new E.Hq.ax(w),z=new Uint8Array(w),s=new Uint32Array(w);z[W]=1;z[D]=2;var O=new Uint32Array(w),a=new Uint32Array(w);
a[W]=a[D]=0;O[W]=O[D]=1;while(!0){var P=-1,T=0,N=1e30;while(!$.qN()&&P==-1){var Z=$.top(),Y=z[Z],K=g[Z]-1;
while(K!=-1){var S=l[K],G=z[S],V=K^Y-1<<2;if(A[V+2>>1]!=0){if(G==0){E.Hq.rL(Z,K,S,z,s,a,O);$.push(S)}else if(G==Y&&O[S]<=O[Z]&&a[S]>a[Z])E.Hq.rL(Z,K,S,z,s,a,O);
else if(G!=Y){P=V}}K=l[K+1]-1}if(P!=-1)break;$.pop()}if(P==-1){break}f++;var R=P;while(R!=-1){k[T]=R;
T++;R=s[l[R^4]]-1}var x=T>>1;for(var L=0;L<x;L++){var v=k[L];k[L]=k[T-L-1];k[T-L-1]=v}R=s[l[P]]-1;while(R!=-1){k[T]=R^4;
T++;R=s[l[R^4]]-1}for(var L=0;L<T;L++)N=Math.min(N,A[k[L]+2>>1]);X+=N;if(X>=U)return{rX:null,VF:X};for(var L=0;
L<T;L++){var u=k[L],H=u^4,Z=l[H],S=l[u];A[u+2>>1]-=N;A[H+2>>1]+=N;if(A[u+2>>1]==0&&z[Z]==z[S]){if(z[Z]==1){s[S]=0;
C.push(S)}if(z[Z]==2){s[Z]=0;C.push(Z)}}}while(!C.qN()){var Z=C.pop(),Y=z[Z],K=g[Z]-1,F=Y==1?4:0,t=0,o=0,q=1e9;
while(K!=-1){var S=l[K],_=K^4,V=K^F;if(z[S]==Y&&A[V+2>>1]>0&&E.Hq.acX(S,W,D,s,l,f,O,a)+1<q){t=S;o=_;
q=a[S]+1}K=l[K+1]-1}if(o!=0){E.Hq.rL(t,o,Z,z,s,a,O);continue}K=g[Z]-1;while(K!=-1){var S=l[K],V=K^F;
if(z[S]==Y){if(A[V+2>>1]>0){$.push(S)}if(s[S]==K+1){s[S]=0;C.push(S)}}K=l[K+1]-1}z[Z]=0;$.remove(Z)}}var d=[];
for(var L=0;L<n;L+=2){var Z=j[L],S=j[L+1];if(z[Z]==1&&z[S]!=1){d.push(L>>1)}if(z[S]==1&&z[Z]!=1){d.push(n+L>>1)}}return{rX:d,VF:X}};
E.Hq.rL=function(w,n,W,D,j,I,U){D[W]=D[w];j[W]=n+1;I[W]=I[w]+1;U[W]=U[w]};E.Hq.acX=function(w,n,W,D,j,I,U,M){var m=w,l=D[w]-1,A=0;
while(l!=-1&&U[w]!=I){w=j[l^4];l=D[w]-1;A++}if(l==-1&&w!=n&&w!=W)return 1e9;var g=M[w]+A;A=0;l=D[m]-1;
while(m!=w){M[m]=g-A;A++;U[m]=I;m=j[l^4];l=D[m]-1}return g};E.Hq.asx=function(w,n,W,D,j,I){var U=E.Hq.tm(w,n,W,D,j,I),M=U.mN,m=U.ath,l=U.am4,A=0,g=0,k=new Uint32Array(w*2),$=new E.Hq.bk(w),C=0;
while(!0){$.reset();$.push(W);for(var L=0;L<w;L++)k[L<<1]=0;while(!$.qN()){var f=$.pop(),z=l[f]-1;while(z!=-1){C=M[z];
if(k[C<<1]==0&&m[z+2>>1]>0&&C!=W){k[C<<1]=f+1;k[(C<<1)+1]=z;$.push(C)}z=M[z+1]-1}if(k[D<<1]!=0){break}}if(k[D<<1]==0){break}var s=1e30;
C=D;while(!0){var O=k[C<<1]-1;if(O==-1)break;var a=k[(C<<1)+1];s=Math.min(s,m[a+2>>1]);C=O}C=D;while(!0){var O=k[C<<1]-1;
if(O==-1)break;var a=k[(C<<1)+1],X=a^4;m[a+2>>1]-=s;m[X+2>>1]+=s;C=O}A+=s}var P=[];for(var L=0;L<n;L+=2){var O=j[L],C=j[L+1];
if((k[O<<1]!=0||O==W)&&k[C<<1]==0&&C!=W){P.push(L>>1)}if((k[C<<1]!=0||C==W)&&k[O<<1]==0&&O!=W){P.push(n+L>>1)}}return{rX:P,VF:A}};
E.Hq.bk=function(w){w|=w>>1;w|=w>>2;w|=w>>4;w|=w>>8;w|=w>>16;this.KR=new Uint32Array(w+1);this.nk=w;
this.MH=0;this.BQ=0};E.Hq.bk.prototype={push:function(w){var n=this.BQ;this.KR[n]=w;this.BQ=n+1&this.nk},pop:function(){var w=this.MH,n=this.KR[w];
this.MH=w+1&this.nk;return n},qN:function(){return this.MH==this.BQ},reset:function(){this.MH=0;this.BQ=0}};
E.Hq.ax=function(w){w|=w>>1;w|=w>>2;w|=w>>4;w|=w>>8;w|=w>>16;this.KR=new Uint32Array(w+1);this.qF=new Uint32Array(w+1);
this.nk=w;this.MH=0;this.BQ=0};E.Hq.ax.prototype={top:function(){return this.KR[this.MH]},atB:function(){return this.KR[this.BQ]},push:function(w){if(this.qF[w]!=0)return;
this.qF[w]=this.BQ+1;var n=this.BQ;this.KR[n]=w;this.BQ=n+1&this.nk},pop:function(){var w=this.MH,n=this.KR[w];
this.qF[n]=0;this.MH=w+1&this.nk;return n},qN:function(){return this.MH==this.BQ},remove:function(w){var n=this.qF[w]-1;
if(n==-1)return;this.qF[w]=0;if(n==this.MH){this.pop();return}var W=this.pop();this.KR[n]=W;this.qF[W]=n+1},RL:function(L){return L+this.nk+1&this.nk}};
E.Hq.A3=function(w,n,W){var D=E.Hq.nw(w,n,W);if(n<D-1)E.Hq.A3(w,n,D-1);if(D<W)E.Hq.A3(w,D,W)};E.Hq.nw=function(w,n,W){var D=w[n+W>>>1];
while(n<=W){while(w[n]<D)n++;while(w[W]>D)W--;if(n<=W){E.Hq.zA(w,n,W);n++;W--}}return n};E.Hq.zA=function(w,n,W){var D=w[n];
w[n]=w[W];w[W]=D};E.nx=function(){var w,n;function W(U,M,bK){var m=bK-1,l=M+bK;w[bK-2]=U[l-2];n[0]=U[l-1];
var A=Math.max;for(var L=1;L<m;L++){w[bK-2-L]=A(w[bK-1-L],U[l-2-L]);n[L]=A(n[L-1],U[l-1+L])}for(var L=0;
L<m;L++)U[M+L]=A(w[L],n[L])}function D(U,M,bK){var m=bK-1,l=Math.ceil(M/m)*m;for(var A=0;A<l;A+=m)W(U,A,bK)}function j(U,M,m,l,bK,A){M.set(U);
if(bK==1)return;w=E.Q(bK-1);n=E.Q(bK-1);var g=bK>>>1,k=E.Q(Math.ceil(Math.max(m,l)/(bK-1))*(bK-1)+(bK-2)),$=new Uint8Array(k.buffer,0,m);
if(!A)E.Ba(M);for(var C=0;C<l;C++){k.fill(0);k.set(new Uint8Array(M.buffer,C*m,m),g);D(k,m,bK);M.set($,C*m)}for(var f=0;
f<m;f++){k.fill(0);for(var C=0;C<l;C++)k[C+g]=M[C*m+f];D(k,l,bK);for(var C=0;C<l;C++)M[C*m+f]=k[C]}if(!A)E.Ba(M)}function I(U,M,m,l,bK,A){var g=E.Q(m*l);
for(var k=0;k<4;k++){E.hN(U,g,k);if(k==3)E.Ba(g);j(g,g,m,l,bK,A);if(k==3)E.Ba(g);E.IL(g,M,k)}}return{Ig:j,anO:I}}();
E.X={};E.X.H4=function(w){for(var L=0;L<w.length;L++)E.X.$G(w,L)};E.X.$G=function(w,L){w[L].v.keyShapeInvalidated={t:"bool",v:!0}};
E.X.atD=function(w){for(var L=0;L<w.length;L++)w[L].v.keyOriginIndex.v=L};E.X.LR=function(){return{t:"Objc",v:{classID:"null",keyOriginIndex:{t:"long",v:0},keyShapeInvalidated:{t:"bool",v:!0}}}};
E.X.Oq=function(w){w=w.v;var n={Rctn:2,Ln:4,Elps:5},W=n[w.classID],D=w.topLeft?E.X.z_(w):null,j=null,I=0,U=[!1,!1,0,0,0];
if(W==4){var M=w.Strt.v,m=w.End.v;j=[M.Hrzn.v.val,M.Vrtc.v.val,m.Hrzn.v.val,m.Vrtc.v.val];I=w.Wdth.v.val;
for(var L=0;L<2;L++){var l=w[L==0?"StrA":"EndA"];if(l==null)continue;l=l.v;U[L]=l.On.v;U[2]=l.Wdth.v;
U[3]=l.Lngt.v;U[4]=l.Cncv.v.val}}if(W==null)return null;return E.X.Cy(W,W==4?null:E.X.A_(w),D,j,I,U)};
E.X.k5=function(w,n,W,D,j,I,U){var M={classID:w,unitValueQuadVersion:{t:"long",v:1}};if(n)E.X.cU(M,["Left","Top","Rght","Btom"],n);
if(W)E.X.cU(M,["topLeft","topRight","bottomRight","bottomLeft"],W);if(w=="Ln"){M.Strt={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"UntF",v:{type:"#Pxl",val:D[0]}},Vrtc:{t:"UntF",v:{type:"#Pxl",val:D[1]}}}},M.End={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"UntF",v:{type:"#Pxl",val:D[2]}},Vrtc:{t:"UntF",v:{type:"#Pxl",val:D[3]}}}},M.Wdth={t:"UntF",v:{type:"#Pxl",val:j}};
for(var L=0;L<2;L++){var m=L==0?"StrA":"EndA";M[m]={t:"Objc",v:{classID:"cArw",On:{t:"bool",v:U[L]},Wdth:{t:"doub",v:U[2]},Lngt:{t:"doub",v:U[3]},Cncv:{t:"UntF",v:{type:"#Prc",val:U[4]}}}}}}if(I)M.Nm={t:"TEXT",v:I};
return{t:"Objc",v:M}};E.X.qJ=function(w,n){var W=E.X.XA(w),D=w[2]-w[0],j=w[3]-w[1],I=Math.sqrt(D*D+j*j),U=[0,0,I,0,I,n,0,n],M=new eh;
M.rotate(-W);M.translate(w[0],w[1]);E.p.D(U,M,U);return U};E.X.Cy=function(w,n,W,D,j,I){var U=E.X.LR(),M=U.v,m;
delete M.keyShapeInvalidated;M.keyOriginType={t:"long",v:w};M.keyOriginResolution={t:"doub",v:75};if(w==4){M.keyOriginLineStart={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:D[0]},Vrtc:{t:"doub",v:D[1]}}};
M.keyOriginLineEnd={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:D[2]},Vrtc:{t:"doub",v:D[3]}}};m=E.X.qJ(D,j);
var l=E.p.mY(m);n=[l.x,l.y,l.x+l.m,l.y+l.n];M.keyOriginLineWeight={t:"doub",v:j};if(I)E.X.a9D(M,I)}else m=[n[0],n[1],n[2],n[1],n[2],n[3],n[0],n[3]];
M.keyOriginBoxCorners={t:"Objc",v:{classID:"null"}};E.X.iH(M,"keyOriginBoxCorners",m);var A={classID:"unitRect",unitValueQuadVersion:{t:"long",v:1}};
M.keyOriginShapeBBox={t:"Objc",v:A};E.X.dN(M,n);if(W!=null){var g={classID:"radii",unitValueQuadVersion:{t:"long",v:1}};
M.keyOriginRRectRadii={t:"Objc",v:g};E.X.C$(M,W)}return U};E.X.D=function(w,n,W,D){var j=E.K.G6(n),I=E.K.u0(n),U=E.K.OT(n),M=U.dl*U.j7-U.k*U.Cj;
for(var L=0;L<w.length;L++){var m=w[L].v;if(!E.X.OL(m))continue;if(W.length!=0&&W.indexOf(L)==-1)continue;
var l=m.keyOriginType.v,A=n;if(M<0&&l==2){var g=E.X.uy(m),k=0;k=g[0];g[0]=g[1];g[1]=k;k=g[2];g[2]=g[3];
g[3]=k;E.X.C$(m,g);var $=E.X.QT(m,"keyOriginBoxCorners"),C=E.p.mY($),f=C.x+C.m/2,z=new eh;z.translate(-f,0);
z.scale(-1,1);z.translate(f,0);A=E.K.y9(A,E.K.yT(z))}var s=["keyOriginPolyTrueRectCorners","keyOriginBoxCorners"];
for(var a=0;a<s.length;a++){var $=E.X.QT(m,s[a]);if($==null)continue;E.K.D(A,$);E.X.iH(m,s[a],$);var C=E.p.mY($);
E.X.dN(m,[C.x,C.y,C.x+C.m,C.y+C.n]);var X=new eh;X.rotate(-E.X.XA($));var P={classID:"Trnf"};m.Trnf={t:"Objc",v:P};
var Z="xx xy yx yy tx ty".split(" "),Y=[X.dl,X.k,X.Cj,X.j7,X.z2,X.EU];for(var K=0;K<6;K++)P[Z[K]]={t:"doub",v:Y[K]}}if(l==2&&D){var g=E.X.uy(m);
for(var a=0;a<4;a++)g[a]=Math.round(g[a]*n[0]);E.X.C$(m,g)}var $=E.X.QT(m,"keyOriginBoxCorners"),S=$[2]-$[0],G=$[3]-$[1],V=Math.sqrt(S*S+G*G);
S/=V;G/=V;var T=$[6]-$[0],R=$[7]-$[1],x=Math.sqrt(T*T+R*R);T/=x;R/=x;if(l==4){m.keyOriginLineWeight.v=x;
var v=E.X.oW(m);E.K.D(n,v);E.X.afY(m,v)}var N=S*T+G*R;if(Math.abs(N)>.001){E.X.$G(w,L)}}};E.X.OL=function(w){var n=w.keyShapeInvalidated,W=w.keyOriginType;
return(n==null||!n.v)&&W!=null&&W.v!=9};E.X.a9k=function(w){var n=w.keyOriginType.v,W=E.X.O5(w),D=W[0],j=W[1],I=W[2],U=W[3],M=new eh,m=w.keyOriginPolyCornerRadius,$;
m=m?m.v:0;var l=E.X.QT(w,n==7||n==8?"keyOriginPolyTrueRectCorners":"keyOriginBoxCorners"),A=E.X.ux(l),g=A[2],k=A[3];
D=-g/2;I=g/2;j=-k/2;U=k/2;M.rotate(-E.X.XA(l));M.z2=A[0];M.EU=A[1];if(n==1||n==2){var C=n==1?0:E.X.uy(w);
$=E.P.AB.Rect(D,j,I-D,U-j,C)}else if(n==4){var f=E.X.oW(w),z=E.X.akZ(w);M=new eh;if(z==null)$=E.P.AB.xK(f[0],f[1],f[2],f[3],w.keyOriginLineWeight.v);
else $=E.P.AB.JJ(f[0],f[1],f[2],f[3],w.keyOriginLineWeight.v,z)}else if(n==5){$=E.P.AB.Po(D,j,I-D,U-j)}else if(n==7||n==8){var s=n==7?3:w.keyOriginPolySides.v;
$=E.P.AB.Je(0,0,100,Math.PI/s-Math.PI/2,s,m,I,U)}E.P.c0($,M);return $};E.X.A9=function(w,n){var W=n.i;
for(var L=0;L<w.length;L++){var D=w[L].v;if(!E.X.OL(D))continue;var j=E.X.a9k(D),I=E.P.tt(W,L),U=E.P.qA(W,L);
j[2].Ht=W[I].Ht;var M=W;W=W.slice(0,I);for(var m=2;m<j.length;m++)W.push(j[m]);for(var m=I+U;m<M.length;
m++)W.push(M[m])}n.i=W;n.eP=!0};E.X.kN=function(w){var n=1e9,W=-n,D=1e9,j=-D,I=[],U=w.OV(),M=U[0],m=U[1];
for(var l=0;l<m.length;l++){var A=M[m[l]],g=A.add.vogk;if(g==null)continue;var k=A.add.vmsk.g;for(var $=0;
$<g.length;$++){var C=g[$].v,s=0;if(!E.X.OL(C))continue;if(m.length==1&&k.length!=0&&k.indexOf($)==-1)continue;
var f=C.keyOriginType.v;if(f==9)continue;var z=E.X.O5(C);n=Math.min(n,z[0]);D=Math.min(D,z[1]);W=Math.max(W,z[2]);
j=Math.max(j,z[3]);var O=E.X.QT(C,"keyOriginBoxCorners");if(O){var a=E.X.ux(O),X=a[2],P=a[3];z[2]=z[0]+X;
z[3]=z[1]+P;s=E.X.XA(O)}var Z=[f,z,s];I.push(Z);if(f==2)Z.push(E.X.uy(C));if(f==7||f==8)Z.push(C.keyOriginPolyCornerRadius.v);
if(f==8)Z.push(C.keyOriginPolySides.v)}}return I.length==1?I[0]:[0,n<W?[n,D,W,j]:null,0]};E.X.XA=function(w){var n=w[2]-w[0],W=w[3]-w[1];
return-Math.atan2(-W,n)};E.X.VW=function(w){var n=E.X.O5(w);return E.X.XA(n)};E.X.a9c=function(w,n,W){var D=E.X.kN(w),j=-1;
for(var L=0;L<n.length;L++)if(JSON.stringify(n[L])!=JSON.stringify(D[L]))j=L;if(j==1||j==2){}var I=w.OV(),U=I[0],M=I[1];
for(var m=0;m<M.length;m++){var l=U[M[m]],A=l.add.vogk;if(A==null)continue;var g=l.add.vmsk.g;for(var k=0;
k<A.length;k++){var $=A[k].v;if(!E.X.OL($))continue;if(M.length==1&&g.length!=0&&g.indexOf(k)==-1)continue;
var C=$.keyOriginType.v;if(j==1||j==2){E.X.D(A,E.X.a4i(j,$,D,n),g,!1);break}if(j==3)if(C==2)E.X.C$($,n[3]);
else $.keyOriginPolyCornerRadius.v=n[3];if(j==4)$.keyOriginPolySides.v=n[4];if(W)E.X.$G(A,k)}}};E.X.a4i=function(w,n,W,D){var j=D[1],I=W[1],U=(j[2]-j[0])/(I[2]-I[0]),M=(j[3]-j[1])/(I[3]-I[1]),m=new eh;
if(w==1){if(Math.max(Math.abs(U-1),Math.abs(M-1))>1e-8){var l=j[0],A=j[1];if(D[0]!=0){var g=E.X.QT(n,"keyOriginBoxCorners");
l=g[0];A=g[1]}m.translate(-l,-A);m.rotate(D[2]);m.scale(U,M);m.rotate(-D[2]);m.translate(l,A)}else{m.translate(-I[0],-I[1]);
m.translate(j[0],j[1])}}else{if(D[0]!=0)j=E.X.O5(n);var l=(j[0]+j[2])/2,A=(j[1]+j[3])/2;m.translate(-l,-A);
if(W[0]!=0)m.rotate(W[2]);m.rotate(-D[2]);m.translate(l,A)}return E.K.yT(m)};E.X.ux=function(w){var n=w[0],W=w[1],D=w[2],j=w[3],I=w[4],U=w[5],M=w[6],m=w[7],l=D-n,A=j-W,g=Math.sqrt(l*l+A*A),l=I-D,A=U-j,k=Math.sqrt(l*l+A*A);
return[(n+I)/2,(W+U)/2,g,k]};E.X.QT=function(w,n){var W=w[n];if(W==null)return null;var D=[];W=W.v;for(var j=0;
j<4;j++){var I=W["rectangleCorner"+["A","B","C","D"][j]].v;D.push(I.Hrzn.v,I.Vrtc.v)}return D};E.X.iH=function(w,n,W){var D=w[n];
if(D==null)return null;D=D.v;for(var j=0;j<4;j++){var I="rectangleCorner"+["A","B","C","D"][j];D[I]={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:W[2*j]},Vrtc:{t:"doub",v:W[2*j+1]}}}}};
E.X.O5=function(w){return E.X.A_(w.keyOriginShapeBBox.v)};E.X.A_=function(w){var n=w.classID,W=w.Left.v,D=w.Rght.v,j=w.Top.v,I=w.Btom.v;
if(W.val!=null){W=W.val;D=D.val;j=j.val;I=I.val}return[W,j,D,I]};E.X.dN=function(w,n){E.X.cU(w.keyOriginShapeBBox.v,["Left","Top","Rght","Btom"],n)};
E.X.uy=function(w){var n=w.keyOriginRRectRadii;if(n==null)return[0,0,0,0];return E.X.z_(n.v)};E.X.z_=function(w){var n=[],W=["topLeft","topRight","bottomRight","bottomLeft"];
for(var D=0;D<4;D++)n.push(w[W[D]].v.val);return n};E.X.C$=function(w,n){E.X.cU(w.keyOriginRRectRadii.v,["topLeft","topRight","bottomRight","bottomLeft"],n)};
E.X.cU=function(w,n,W){var D=w.classID;if(D=="unitRect"||D=="radii"||D=="Rctn"){for(var L=0;L<4;L++)if(W[L]!=null)w[n[L]]={t:"UntF",v:{type:"#Pxl",val:W[L]}}}else{for(var L=0;
L<4;L++)if(W[L]!=null)w[n[L]]={t:"doub",v:W[L]}}};E.X.oW=function(w){var n=w.keyOriginLineStart.v,W=w.keyOriginLineEnd.v;
return[n.Hrzn.v,n.Vrtc.v,W.Hrzn.v,W.Vrtc.v]};E.X.afY=function(w,n){var W=w.keyOriginLineStart.v,D=w.keyOriginLineEnd.v;
W.Hrzn.v=n[0];W.Vrtc.v=n[1];D.Hrzn.v=n[2];D.Vrtc.v=n[3]};E.X.akZ=function(w){var n=[],W=["owSt","owEnd","Wdth","Lngth","Conc"];
for(var L=0;L<5;L++){var D=w["keyOriginLineArr"+W[L]];if(D==null)return null;n[L]=D.v}return n};E.X.a9D=function(w,n){w.keyOriginLineArrowSt={t:"bool",v:n[0]};
w.keyOriginLineArrowEnd={t:"bool",v:n[1]};w.keyOriginLineArrWdth={t:"doub",v:n[2]};w.keyOriginLineArrLngth={t:"doub",v:n[3]};
w.keyOriginLineArrConc={t:"long",v:n[4]}};E.X.amM=function(w){function n(Y,K){return Math.abs(Y-K)<.5}function W(Y,K){return n(Y.x,K.x)&&n(Y.y,K.y)}function D(Y,K,S,G,V,T,R){for(var L=0;
L<R;L++){var x=Y[K+(S+L)%R],v=G[V+(T+L)%R];if(!(W(x.H,v.H)&&W(x.T7,v.T7)&&W(x.mO,v.mO)))return!1}return!0}var j=[],I=E.P.bB(w);
for(var U=0;U<I;U++){var M=null,m=E.P.tt(w,U),l=w[m];if(l.length==4||l.length==8){var k=E.P.oc(w.slice(0,2).concat(w.slice(m,m+l.length+1)));
m=2;if(l.length==4){var $=E.P.bd(k,m+1,4),C=$.x,f=$.y,z=C+$.m,s=f+$.n;if($.O()>4){if(E.P.tF(k.slice(m-2,m+5)))M=E.X.Cy(2,[C,f,z,s],[0,0,0,0]);
else{var O=-1;for(var L=0;L<4;L++)if(n(k[m+1+L].H.y,s))O=L;if(O!=-1){var a=E.P.AB.Po(C,f,z-C,s-f),X=D(k,m+1,O,a,3,0,4);
if(X)M=E.X.Cy(5,[C,f,z,s])}}}}if(l.length==8){var $=E.P.bd(k,m+1,8),C=$.x,f=$.y,z=C+$.m,s=f+$.n;if($.O()>4){var O=-1;
for(var L=0;L<8;L++)if(n(k[m+1+(L+1&7)].H.y,f)&&n(k[m+1+(L+2&7)].H.y,f))O=L;if(O!=-1){var P=Math.abs(k[m+1+O].H.y-f),Z=[P,P,P,P];
if(P>.5){var a=E.P.AB.Rect(C,f,z-C,s-f,Z),X=D(k,m+1,O,a,3,0,8);if(X)M=E.X.Cy(2,[C,f,z,s],Z)}}}}}j.push(M?M:E.X.LR())}return j};
E.p={};E.p.clone=function(w){return{F:w.F.slice(0),w:w.w.slice(0)}};E.p.hq=function(w){if(w.length<6)return!0;
var n=w.length-4;for(var L=0;L<n;L+=2)if(!E.p.aW(w[L],w[L+1],w[L+2],w[L+3],w[L+4],w[L+5]))return!1;if(!E.p.aW(w[n],w[n+1],w[n+2],w[n+3],w[0],w[1]))return!1;
if(!E.p.aW(w[n+2],w[n+3],w[0],w[1],w[2],w[3]))return!1;return!0};E.p.aW=function(w,n,W,D,j,I){return(n-D)*(j-W)+(W-w)*(I-D)>=0};
E.p.e7=function(w){var n={},W=null,D=0,j={M:2,L:2,Q:4,C:6},I="",U="";for(var L=0;L<w.F.length;L++){var M=w.F[L];
if(M[0]=="#")I=M;else if(M[0]=="X")I="";else if(M[0]=="O"&&M[1]=="-")U=M;else if(M=="OX")U="";else{var m=I+U;
W=n[m];if(W==null)W=n[m]={w:[],F:[]};W.F.push(M);var l=j[M];if(l==null)l=0;for(var A=0;A<l;A++)W.w.push(w.w[D+A]);
D+=l}}return n};E.p.m4=function(w,n,W){var D=w[n]-w[W-2],j=w[n+1]-w[W-1];return D*D+j*j<1e-4};E.p.oF=function(w,n,W){w=E.p.jp(w);
var D=w.w,j=w.F,I=0,U="",M=0,m=0,I=0,g=null;for(var L=0;L<j.length;L++){var l=j[L];if(l=="M"){M=D[I];
m=D[I+1];I+=2;U=l}if(l=="C"){if(U=="Z"){j.splice(L,0,"M");D.splice(I,0,M,m);L--;continue}I+=6;U=l}if(l=="Z"){U=l}}var A=[];
I=0;for(var L=0;L<j.length;L++){var l=j[L];if(l=="M"){g={RI:I,_W:0,tH:!1};A.push(g);I+=2}if(l=="C"){g._W++;
I+=6}if(l=="Z"&&g!=null){g.tH=!0}}var k=[];for(var L=0;L<A.length;L++)if(A[L]._W!=0)k.push(A[L]);A=k;
for(var L=0;L<A.length;L++){var $=A[L],C=$.RI,f=C+2+$._W*6,s=0;$.H8=E.p.mY(D,C,f);var z=E.p.m4(D,C,f);
for(var O=0;O<$._W;O++){var a=C+O*6,X=a+6;s+=(D[X]-D[a])*(D[X+1]+D[a+1])}if($._W==2){var P=function(B,i,c){var h2=1-c;
return h2*h2*h2*B[i]+3*h2*h2*c*B[i+2]+3*h2*c*c*B[i+4]+c*c*c*B[i+6]},Z=D[C],Y=D[C+1],K=D[C+6],S=D[C+7],G=D[C+6],V=D[C+7],T=P(D,C,.5),R=P(D,C+1,.5),x=P(D,C+6,.5),v=P(D,C+7,.5);
s=(T-Z)*(R-Y)+(K-T)*(S-R)+(x-K)*(v-S)+(G-x)*(V-v)}if(!z)s+=(D[C]-D[f-2])*(D[C+1]+D[f-1]);$._D=s<=0}for(var L=0;
L<A.length-1;L++)for(var a=L+1;a<A.length;a++){var N=A[L],u=A[a];if(u.H8.Yy(N.H8)){A[L]=u;A[a]=N}}var H=A.length==0?!0:A[0]._D,F=[{type:6},{type:8,all:0}];
for(var L=0;L<A.length;L++){var $=A[L],C=$.RI,f=C+2+$._W*6,z=E.p.m4(D,C,f);if($._W==1)z=!1;var t=$.tH||z?0:3,o=$._D==H&&!n?1:0;
if(!n&&L!=0){if(A[L-1].H8.Yy($.H8)&&A[L-1]._D!=$._D)o=0;for(var a=0;a<A.length;a++)if(a!=L&&A[a].H8.Yy($.H8))o=0}F.push({type:t,length:$._W+(z?0:1),Ht:W?1:o,S1:2});
for(var a=0;a<$._W;a++){var I=C+a*6,q=new ec(D[I],D[I+1]),_=new ec(D[I+2],D[I+3]),d;if(a==0){if(z){d=new ec(D[f-4],D[f-3]);
if(ec.cS(d,q)<1e-5)d=q.clone()}else d=q.clone()}else d=new ec(D[I-2],D[I-1]);F.push({type:t+2,T7:d,H:q,mO:_})}if(!z){var r=new ec(D[f-2],D[f-1]);
F.push({type:t+2,T7:new ec(D[f-4],D[f-3]),H:r,mO:r.clone()})}}for(var a=0;a<F.length;a++){var p=F[a];
if(p.type>5||p.type==0||p.type==3)continue;var Q=p.T7.s9(p.H)||p.mO.s9(p.mO);if(!Q){var N=p.T7.x*(p.H.y-p.mO.y)+p.H.x*(p.mO.y-p.T7.y)+p.mO.x*(p.T7.y-p.H.y);
if(Math.abs(N)<1e-6)Q=!0}if(Q)p.type--}return F};E.p.tq=function(w,n){var W=E.P.bB(w),D=[];for(var L=2;
L<w.length;L++){var j=w[L].Ht;if(j!=null){if(j==2||j==0||j==3||j==-1)D.push(j)}}var I=D.length!=0;if((I||n)&&w.length<15e3&&1<W&&W<200)w=E.P.JC(w);
var U=E.p.xH(w);return{VN:U,M0:I?1:0}};E.p.xH=function(){function w(D,j,I,U){if(!U&&D.mO.s9(D.H)&&j.T7.s9(j.H)){I.w.push(j.H.x,j.H.y);
I.F.push("L")}else{var M=D.H,m=D.mO,l=j.T7,A=j.H,g=3/2*m.x-1/2*M.x,k=3/2*m.y-1/2*M.y,$=3/2*l.x-1/2*A.x,C=3/2*l.y-1/2*A.y,f=$-g,z=C-k;
if(!U&&f*f+z*z<.001){I.w.push((g+$)*.5,(k+C)*.5,A.x,A.y);I.F.push("Q")}else{I.w.push(m.x,m.y,l.x,l.y,A.x,A.y);
I.F.push("C")}}}function n(D,j,L,I,U,M){var m=j[L];D.w.push(m.H.x,m.H.y);D.F.push("M");for(var l=L;l<L+I-1;
l++)w(j[l],j[l+1],D,M);if(!U)w(j[l],j[L],D,M)}function W(D,j){D=E.P.oc(D);if(j==null)j=!1;var I={w:[],F:[]};
for(var L=0;L<D.length;L++){if(D[L].type>5)continue;var U=D[L].length;if(U==0)continue;if(L==D.length-1)break;
var M=D[L].type==3;n(I,D,L+1,U,M,j);if(!M)I.F.push("Z");L+=U}return I}return W}();E.p.aoE=function(w){var n=w.w,W=[],D,j=0;
for(var L=0;L<w.F.length;L++){var I=w.F[L];if(I=="C"){D.push(n[j++],n[j++],n[j++],n[j++],n[j++],n[j++])}else if(I=="Z"){}else{D=[];
if(I!="M"){D.push(I);L++}D.push(n[j++],n[j++]);W.push(D)}}return W};E.p.VK=function(w,n,W,D){if(D==null)D=1e9;
var j=1e9,I=0;for(var L=0;L<w.length;L+=2){var U=n-w[L],M=W-w[L+1],m=U*U+M*M;if(m<j){j=m;I=L>>>1}}return j<D*D?I:-1};
E.p.gp=function(w,n,W,D){for(var L=0;L<w.length;L+=2){var j=w[L],I=w[L+1],U=n[L],M=n[L+1];W[L]=j+(U-j)*D;
W[L+1]=I+(M-I)*D}};E.p.D=function(w,n,W){for(var L=0;L<w.length;L+=2){var D=w[L],j=w[L+1];W[L]=D*n.dl+j*n.Cj+n.z2;
W[L+1]=D*n.k+j*n.j7+n.EU}};E.p.mY=function(w,n,W){if(n==null)n=0;if(W==null)W=w.length;var D=99999999999,j=-D,I=99999999999,U=-I;
for(var L=n;L<W;L+=2){var M=w[L],m=w[L+1];D=Math.min(D,M);I=Math.min(I,m);j=Math.max(j,M);U=Math.max(U,m)}return new iB(D,I,j-D,U-I)};
E.p.mm=function(w,n){var W=Math.max(n.x,Math.min(n.x+n.m,w.x)),D=Math.max(n.y,Math.min(n.y+n.n,w.y)),j=w.x-W,I=w.y-D;
return Math.sqrt(j*j+I*I)};E.p.fF=function(w,n){var W=Math.floor,D=Math.ceil;if(n){W=Math.ceil;D=Math.floor}var j=W(w.x),I=D(w.x+w.m),U=W(w.y),M=D(w.y+w.n);
return new iB(j,U,I-j,M-U)};E.p.lV=function(w,n){return E.p.fF(E.p.mY(w),n)};E.p.Wx=function(w,n){var W=w.x,D=w.y,j=w.x+w.m,I=w.y+w.n,U=[W,D,j,D,j,I,W,I];
if(n){var M=n.clone();M.Ba();E.p.D(U,M,U)}return{F:["M","L","L","L","Z"],w:U}};E.p.concat=function(w,n,W){if(W==null)W=new eh;
for(var L=0;L<n.w.length;L+=2){var D=n.w[L],j=n.w[L+1];w.w.push(D*W.dl+j*W.Cj+W.z2);w.w.push(D*W.k+j*W.j7+W.EU)}for(var L=0;
L<n.F.length;L++)w.F.push(n.F[L])};E.p.ag6=function(w,n,W,D,j){function I(k,$,C){return new ec(k.x*(1-C)+$.x*C,k.y*(1-C)+$.y*C)}var U=I(w,n,j),M=I(W,D,j),m=I(n,W,j),l=I(U,m,j),A=I(m,M,j),g=I(l,A,j);
return[U,l,g,A,M]};E.p.jp=function(w){var n=w.w,W=[],D=[],j=0,I=0,U=0,M=0,m=0,l=0,A=0,g=0,k=0,$=0,C=0;
for(var L=0;L<w.F.length;L++){var f=w.F[L];if(f=="M"){I=n[j];U=n[j+1];j+=2;D.push(f);W.push(I,U);$=I;
C=U}else if(f=="C"){M=n[j];m=n[j+1];l=n[j+2];A=n[j+3];g=n[j+4];k=n[j+5];j+=6;D.push(f);W.push(M,m,l,A,g,k);
I=g;U=k}else if(f=="Q"){M=n[j];m=n[j+1];l=n[j+2];A=n[j+3];j+=4;var z=M-I,s=m-U,O=l-M,a=A-m;D.push("C");
W.push(I+2/3*z,U+2/3*s,M+1/3*O,m+1/3*a,l,A);I=l;U=A}else if(f=="L"){M=n[j];m=n[j+1];j+=2;if(M!=I||m!=U){D.push("C");
W.push(I,U,M,m,M,m);I=M;U=m}}else{if(f=="Z"){I=$;U=C}D.push(f)}}return{F:D,w:W}};E.p.ac9=function(w){var n=w.w,W=[],D=[],j=0;
for(var L=0;L<w.F.length;L++){var I=w.F[L];if(I=="Q"){var U=n[j-2],M=n[j-1],m=n[j],l=n[j+1],A=n[j+2],g=n[j+3];
j+=4;var k=m-U,$=l-M,C=A-m,f=g-l;D.push("C");W.push(U+2/3*k,M+2/3*$,m+1/3*C,l+1/3*f,A,g)}else{var z=0;
if(I=="M"||I=="L")z=2;else if(I=="C")z=6;for(var s=0;s<z;s++)W.push(n[j+s]);j+=z;D.push(I)}}return{F:D,w:W}};
E.p.Av=function(w,n){var W=w.w,D=[],j=[],I=0,U=0,M=0,m=0,l=0,A=0,g=0,k=0,$=0;for(var L=0;L<w.F.length;
L++){var C=w.F[L];if(C=="M"){U=W[I];M=W[I+1];I+=2;j.push(C);D.push(U,M)}else if(C=="C"){m=W[I];l=W[I+1];
A=W[I+2];g=W[I+3];k=W[I+4];$=W[I+5];I+=6;E.p.Bs(U,M,m,l,A,g,k,$,n,j,D,0);U=k;M=$}else j.push(C)}return{F:j,w:D}};
E.p.Bs=function(w,n,W,D,j,I,U,M,m,l,A,g){var k=Math.sqrt((U-w)*(U-w)+(M-n)*(M-n)),$=Math.sqrt((U-j)*(U-j)+(M-I)*(M-I))+Math.sqrt((j-W)*(j-W)+(I-D)*(I-D))+Math.sqrt((W-w)*(W-w)+(D-n)*(D-n)),C=(k+$)/2;
if(C<=m){l.push("C");A.push(W,D,j,I,U,M)}else{var f=0,z=0,s=0,O=0,a=0,X=0,P=0,Z=0,Y=0,K=0,S=0,G=0,V=0;
z=(w+W)/2;s=(n+D)/2;O=(W+j)/2;a=(D+I)/2;X=(j+U)/2;P=(I+M)/2;Z=(z+O)/2;Y=(s+a)/2;K=(O+X)/2;S=(a+P)/2;
G=(Z+K)/2;V=(Y+S)/2;E.p.Bs(w,n,z,s,Z,Y,G,V,m,l,A,g+1);E.p.Bs(G,V,K,S,X,P,U,M,m,l,A,g+1)}};E.p.RF=function(w,n,W,D,j){var I=Date.now(),U=E.p.a2y(w,n,W);
if(j){console.log("trace polygons",Date.now()-I);I=Date.now()}var M=[];for(var L=0;L<U.length;L++){var m=U[L],l=m[0],A=["M"],g=w[l[1]*n+l[0]];
if(l.length>8)l=E.p.TW(l,D,m[1]);if(l.length<=4)continue;for(var k=2;k<l.length;k+=2)A.push("L");A.push("Z");
M.push({path:{w:l,F:A},color:g,parent:-1,H8:E.p.mY(l)})}if(j){console.log("simplify polygons",Date.now()-I);
I=Date.now()}for(var L=1;L<M.length;L++){var $=M[L],C=$.path.w,f=C[0],z=C[1],s=C[2],O=C[3],a=s-f,X=O-z,P=f+.5*a-.001*X,Z=z+.5*X+.001*a;
for(var k=L-1;k>=0;k--){var Y=M[k];if(!Y.H8.Yy($.H8))continue;if(!cf.ku(Y.path.w,P,Z))continue;$.parent=k;
break}}if(j){console.log("checking parents",Date.now()-I);I=Date.now()}return M};E.p.a2y=function(w,n,W){var D=n*W,j=new Uint16Array(n*W),U=0;
for(var L=0;L<D;L++)j[L]=w[L];var I=new Uint8Array(n*W);I[1*n+1]=I[(W-1)*n+1]=I[1*n+n-1]=I[(W-1)*n+n-1]=1;
for(var M=1;M<W;M++)for(var m=1;m<n;m++){var L=M*n+m,l=j[L-n-1],A=j[L-n],g=j[L-1],k=j[L],$=l==k&&A==g&&l!=A,C=0;
if(k<g){U=k;k=g;g=U}if(g<A){U=g;g=A;A=U}if(A<l){U=A;A=l;l=U}if(k<g){U=k;k=g;g=U}if(g<A){U=g;g=A;A=U}if(k<g){U=k;
k=g;g=U}if(l!=A)C++;if(A!=g)C++;if(g!=k)C++;if(k!=l)C++;if(C>=3||$)I[L]=1}var f=[];for(var M=1;M<W;M++)for(var m=1;
m<n;m++){var L=M*n+m;if(j[L]!=j[L-1]){var z=E.p.abr(j,n,W,m,M),s=[];for(var O=0;O<z.length;O+=2)if(I[z[O+1]*n+z[O]]==1)s.push(O>>>1);
f.push([z,s]);E.p.dM(j,n,W,m,M)}}return f};E.p.dM=function(w,n,W,D,j){var I=[j*n+D],U=w[j*n+D];w[j*n+D]=65535;
while(I.length!=0){var L=I.pop();w[L]=0;if(w[L+n]==U){I.push(L+n);w[L+n]=65535}if(w[L-n]==U){I.push(L-n);
w[L-n]=65535}if(w[L-1]==U){I.push(L-1);w[L-1]=65535}if(w[L+1]==U){I.push(L+1);w[L+1]=65535}}};E.p.abr=function(w,n,W,D,j){var I=[0,-1,1,0,0,1,-1,0],A=1;
function U(k,$,A){var L=l*n+m,C=0;if(A==0)C=L-n;else if(A==1)C=L;else if(A==2)C=L-1;else if(A==3)C=L-n-1;
return w[C]}var M=[],m=D,l=j,g=U(m,l,A);do{M.push(m,l);m+=I[A*2];l+=I[A*2+1];if(U(m,l,A)!=g)A=A+1&3;
else if(U(m,l,A+3&3)!=g)A=A;else if(U(m,l,A+2&3)!=g)A=A+3&3}while(m!=D||l!=j);return M};E.p.TW=function(w,n,W){var D=w.length-2;
if(W&&W.length!=0){var j=W[0]*2,I=W[W.length-1]*2,U=j==0?D:j-2,M=w.slice(I);for(var L=0;L<j;L++)M.push(w[L]);
if(j==I)M.push(.9*w[j]+.1*w[U],.9*w[j+1]+.1*w[U+1]);else M.push(w[j],w[j+1]);M=E.p.EV(M,n);M.pop();M.pop();
for(var L=0;L<W.length-1;L++){var m=w.slice(W[L]*2,W[L+1]*2+2);m=E.p.EV(m,n);for(var l=0;l<m.length-2;
l++)M.push(m[l])}return M}var A=w.slice(0);A.push(.9*w[0]+.1*w[D],.9*w[1]+.1*w[D+1]);A=E.p.EV(A,n);A.pop();
A.pop();return A};E.p.EV=function(w,n){var W=w.length-2,D=w[0],j=w[1],I=w[W],U=w[W+1],M=I-D,m=U-j,l=1/Math.sqrt(M*M+m*m),A=I*j-U*D,g=-1,k=-1,$=0;
for(var L=2;L<W;L+=2){var C=w[L],f=w[L+1],z=f*f*1e6+C*C,s=Math.abs(m*C-M*f+A)*l;if(s>k||s==k&&z>$){k=s;
g=L;$=z}}if(k<n)return[D,j,I,U];var O=E.p.EV(w.slice(0,g+2),n),a=E.p.EV(w.slice(g),n);for(var L=2;L<a.length;
L++)O.push(a[L]);return O};E.p.a1E=function(){var w=function(D,j,I,U,M,m){return(j-U)*(M-I)+(I-D)*(m-U)>=0},n=function(D,j,I,U,M,m,l,A){var g=l-I,k=A-U,$=M-I,C=m-U,f=D-I,z=j-U,s=g*g+k*k,O=g*$+k*C,a=g*f+k*z,X=$*$+C*C,P=$*f+C*z,Z=1/(s*X-O*O),Y=(X*a-O*P)*Z,K=(s*P-O*a)*Z;
return Y>=0&&K>=0&&Y+K<1},W=function(D){var bK=D.length>>>1,L=0;if(bK<3)return[];var j=[],I=[];for(var L=0;
L<bK;L++)I.push(L);var U=bK;while(U>3){var M=I[(L+0)%U],m=I[(L+1)%U],l=I[(L+2)%U],A=D[2*M],g=D[2*M+1],k=D[2*m],$=D[2*m+1],C=D[2*l],f=D[2*l+1],z=!1;
if(w(A,g,k,$,C,f)){z=!0;for(var s=0;s<U;s++){var O=I[s];if(O==M||O==m||O==l)continue;if(n(D[2*O],D[2*O+1],A,g,k,$,C,f)){z=!1;
break}}}if(z){j.push(M,m,l);I.splice((L+1)%U,1);U--;L=0}else if(L++>3*U)break}j.push(I[0],I[1],I[2]);
return j};return W}();E.p.asy=function(w,n){var W={},D={F:[],w:[]};for(var L=0;L<n.length;L+=3){var j=n[L]*2,I=n[L+1]*2,U=n[L+2]*2;
E.p.MS(w,j,I,D,W);E.p.MS(w,j,U,D,W);E.p.MS(w,I,U,D,W)}return D};E.p.MS=function(w,n,W,D,j){if(n>W){var I=W;
W=n;n=I}if(j[n+","+W])return;j[n+","+W]=!0;D.F.push("M","L");D.w.push(w[n],w[n+1],w[W],w[W+1])};E.p.EM=function(w,n){var W=[],D=w.length;
for(var L=0;L<D;L+=2){var j=w[L],I=w[L+1],U=w[(L+2)%D],M=w[(L+3)%D];if(M<I){var m=I;I=M;M=m}if(I<n&&n<M){var l=(n-I)/(M-I);
W.push(j+l*(U-j))}}W.sort(function(A,g){return A-g});return W};E.p.eU=function(w,n,W,D,j,I,U){var M=w-W,m=n-D,l=j-W,A=I-D,g=1/Math.sqrt(M*M+m*m),k=1/Math.sqrt(l*l+A*A),$=M*g,C=m*g,f=l*k,z=A*k,s=C*U,O=-$*U,a=-z*U,X=f*U,P=E.p.qI(s,O,$,C,a,X,f,z),Z=s+$*P,Y=O+C*P,P=E.p.qI(0,0,$,C,Z,Y,-C,$),K=$*P,S=C*P;
return[Math.sqrt(K*K+S*S),$,C,f,z]};E.p.a6a=function(w,n,W,D,j,I,U){var M=E.p.eU(w,n,W,D,j,I,U),m=M[0],l=M[1],A=M[2],g=M[3],k=M[4],$=Math.atan2(l*k-A*g,l*g+A*k);
if($<0){$=$*-1}var C=Math.PI-$,f=4/3*Math.tan(C/4),z=W+m*l,s=D+m*A,O=W+m*g,a=D+m*k,X=z+f*U*-l,P=s+f*U*-A,Z=O+f*U*-g,Y=a+f*U*-k;
return[0,0,z,s,X,P,Z,Y,O,a]};E.p.qI=function(w,n,W,D,j,I,U,M){var m=U*(n-I)-M*(w-j),l=M*W-U*D;if(l==0)return 0;
return m/l};E.p.a9Z=function(w,n,W,D,j,I){return w*(D-I)+W*(I-n)+j*(n-D)};E.p.pl=function(w){function n(x,v,N,u,H,F,t,o,q){var _=E.p.qI(x,v,N,u,H,F,t,o);
q.push(x+N*_,v+u*_)}var W=[],D=w.length,j=[];for(var L=0;L<D;L+=2){var I=L==0?D-2:L-2,U=L==D-2?0:L+2,M=w[L],m=w[L+1],l=M-w[I],A=m-w[I+1],g=w[U]-M,k=w[U+1]-m,$=Math.sqrt(l*l+A*A),C=Math.sqrt(g*g+k*k);
j.push(C);var f=$/($+C),z=M-l*.5,s=m-A*.5,O=M+g*.5,a=m+k*.5,X=(w[U]+w[I])*.5,P=(w[U+1]+w[I+1])*.5,Z=z+f*(O-z),Y=s+f*(a-s),K=M-Z,S=m-Y,G=(g*-l+k*-A)/($*C),V=(f-.5)*7,T=1+V*f,R=1-V*(1-f);
W.push(z+K*T,s+S*T,O+K*R,a+S*R)}return W};E.PZ=function(){};E.PZ.ay=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=new Int32Array(M),bK=0;
for(var L=0;L<M;L++)if(n[L]!=0){m[L]=bK;bK++}else if(w[(L<<2)+3]<200){m[L]=-2}else m[L]=-1;if(bK==0)return;
var l=new E.l2(bK,bK),A=new Array(3*bK),g=new Array(3*bK);for(var L=0;L<g.length;L++)g[L]=A[L]=0;var k=1/255,$=[-I,-1,1,I],C=[],f=[];
for(var z=0;z<U;z++)for(var s=0;s<I;s++){var O=z*I+s,a=O<<2,L=m[O],X=L*3,P=0,Z=0,Y=0;if(L==-1||L==-2)continue;
for(var K=0;K<4;K++){if(K==2){Z=Y;C[Y]=0;f[Y]=L;Y++}var S=O+$[K],G=S<<2,V=m[S];if(K==0&&z==0||K==1&&s==0||K==2&&s==I-1||K==3&&z==U-1||V==-2)continue;
P++;if(V==-1){A[X+0]+=w[G+0];A[X+1]+=w[G+1];A[X+2]+=w[G+2]}else{C[Y]=-1;f[Y]=V;Y++;if(n[O]==n[S]){A[X+0]+=w[a+0]-w[G+0];
A[X+1]+=w[a+1]-w[G+1];A[X+2]+=w[a+2]-w[G+2]}}}C[Z]=P;l.eM(C,f,Y)}for(var L=0;L<M;L++)if(m[L]!=-1){var T=L<<2,R=m[L],x=R*3;
g[x]=w[T+0];g[x+1]=w[T+1];g[x+2]=w[T+2]}var v=Date.now();l.a7C(g,A,D,j);console.log(Date.now()-v);for(var L=0;
L<M;L++){var R=m[L],N=R*3,T=L<<2;if(R==-1||w[T+3]!=255)continue;w[T+0]=~~(.5+Math.max(0,Math.min(255,g[N+0])));
w[T+1]=~~(.5+Math.max(0,Math.min(255,g[N+1])));w[T+2]=~~(.5+Math.max(0,Math.min(255,g[N+2])))}};E.rect={};
E.rect.V0=function(w,n){var W=[w],D=[];for(var L=0;L<n.length;L++){var j=n[L],I=!1;for(var U=L+1;U<n.length;
U++){var M=n[U];if(M[0]<=j[0]&&M[1]<=j[1]&&j[2]<=M[2]&&j[3]<=M[3]){I=!0;break}}if(!I)D.push(j)}n=D;for(var L=0;
L<n.length;L++){var j=n[L];for(var U=0;U<W.length;U++){var M=W[U],m=Math.max(j[0],M[0]),l=Math.min(j[2],M[2]),A=Math.max(j[1],M[1]),g=Math.min(j[3],M[3]);
if(m<l&&A<g){var k=[];if(M[1]<j[1]){var $=M.slice(0);$[3]=j[1];k.push($)}if(M[0]<j[0]){var C=M.slice(0);
C[1]=A;C[2]=j[0];k.push(C)}if(j[2]<M[2]){var f=M.slice(0);f[1]=A;f[0]=j[2];k.push(f)}if(j[3]<M[3]){var z=[m,g,l,M[3]];
k.push(z)}if(k.length!=0){W[U]=k[0];for(var s=1;s<k.length;s++)W.push(k[s])}}}W.push(j);W=E.rect.aoy(W)}W.sort(function(j,M){return j[1]!=M[1]?j[1]-M[1]:j[0]-M[0]});
for(var L=1;L<W.length;L++){var j=W[L-1],M=W[L];if(j[0]==M[0]&&j[1]==M[1]&&j[2]==M[2]&&j[3]==M[3]){W.splice(j[4]==null?L-1:L,1);
L--}}return W};E.rect.aoy=function(w){w=w.slice(0);for(var L=0;L<w.length;L++){var n=w[L],W=null;if(n[4]!=null)continue;
for(var D=0;D<w.length;D++){var j=w[D];if(L==D||j[4]!=null)continue;var I=n[0]==j[0],U=n[1]==j[1],M=n[2]==j[2],m=n[3]==j[3];
if(U&&m&&(n[2]==j[0]||n[0]==j[2])){W=[Math.min(n[0],j[0]),n[1],Math.max(n[2],j[2]),n[3]]}if(I&&M&&(n[3]==j[1]||n[1]==j[3])){W=[n[0],Math.min(n[1],j[1]),n[2],Math.max(n[3],j[3])]}if(W){w[L]=W;
w.splice(D,1);break}}if(W){L--}}return w};E.rect.vx=function(w){var n=new iB;for(var L=0;L<w.length;
L++)n=n.x0(w[L]);return n};E.rect.aum=function(w,n){var W=E.rect.vx,D=new UnionFind(w.length),Z=1e3,Y=1e3;
for(var L=0;L<w.length;L++)for(var j=L+1;j<w.length;j++){if(!n)continue;var I=w[L],U=w[j],g=1e9,k=1e9;
if(I.L0(U)){D.link(L,j);continue}var M=I.x+I.m,m=I.y+I.n,l=U.x+U.m,A=U.y+U.n;if((M<U.x||l<I.x)&&(m<U.y||A<I.y))continue;
if(!(m<U.y||A<I.y))g=Math.min(Math.abs(M-U.x),Math.abs(I.x-l));if(!(M<U.x||l<I.x))k=Math.min(Math.abs(m-U.y),Math.abs(I.y-A));
var $=Math.min(g,k),C=Math.min(I.m,I.n,U.m,U.n);if($<.3*C)D.link(L,j)}var f=[],z={};for(var L=0;L<w.length;
L++){var s=D.find(L),O=w[L];if(z[s]==null){z[s]=f.length;f.push([])}f[z[s]].push(O)}var a=[],X=[];for(var L=0;
L<f.length;L++){a.push(W(f[L]));var P=W(f[L]);P.RL=L;X.push(P)}X.sort(function(u,H){return Math.max(H.n,H.m)-Math.max(u.n,u.m)});
var K=new NETXUS.RectanglePacker(Z,Y);while(!0){var S=!1;K.reset(Z,Y);for(var L=0;L<X.length;L++){var G=K.findCoords(X[L].m,X[L].n);
if(G){X[L].x=G.x;X[L].y=G.y}else{Z=Math.floor(Z*1.1);Y=Math.floor(Y*1.1);S=!0;break}}if(S)continue;break}for(var L=0;
L<f.length;L++){var V=X[L],T=V.RL,R=a[T],x=f[T],v=V.x-R.x,N=V.y-R.y;for(var j=0;j<x.length;j++)x[j].offset(v,N)}};
E.f_=function(){};E.f_.Nf=Math.floor(16*window.devicePixelRatio);E.f_.Q4={};E.f_.XR=0;E.f_.Ph=[[12,76,2],[12,76,3],[12,76,4],[12,76,5],[12,76,6]];
E.f_.agX=["px","in","cm","mm","%"];E.f_.M_=function(w,n,W,D){var j=[1,n,n/2.54,n/25.4,W/100][D];return w*j};
E.f_.abL=function(w,n,W,D){var j=[1,n,n/2.54,n/25.4,W/100][D];return w/j};E.f_.BE=function(w,n,W,D,j){var I=W.M3.Lf,U=[1,n,n/2.54,n/25.4,D/100][I],M=[2,3,2,1,2][I];
w=w/U;var m=Math.round(w),l=I==0&&Math.abs(w-m)<1e-6?m+"":w.toFixed(M);if(j)l+=" "+E.f_.agX[I];return l};
E.f_.aq8=function(w,n,W,D){var j=W.M3.Lf,I=[1,n,n/2.54,n/25.4,D/100][j];w=parseFloat(w)*I;return w};
E.f_.axz=function(w,n){var W=w+","+n;if(E.f_.Q4.clr==W)return;var D=Math.round(E.f_.Nf*.5);E.f_.XR=D;
var j=E.Om(D,D);j.save();j.font=D*1.5+"px monospace";var I="0 1 2 3 4 5 6 7 8 9 -".split(" ");for(var L=0;
L<I.length;L++){j.fillStyle="#"+E.$$(n);j.fillRect(0,0,D,D);j.fillStyle="#"+E.$$(w);j.fillText(I[L],0,D);
E.f_.Q4[I[L]]=new Uint8Array(j.getImageData(0,0,D,D).data.buffer)}E.f_.Q4.clr=W;j.restore()};E.f_.a38=function(w,n,W){var D=0,j=0,I=4*E.f_.Nf;
for(var L=9;L>=0;L--){var U=Math.pow(10,L);if(5*U*w<=I){D=5*U;j=10;break}if(2*U*w<=I){D=2*U;j=4;break}if(1*U*w<=I){D=1*U;
j=10;break}}if(D==0){D=1;j=10}var M=Math.ceil(D*w),m=E.Q(M*E.f_.Nf*4);E.cJ(m,4278190080|W);for(var L=0;
L<E.f_.Nf;L++)E.f_.bg(m,4*L*M,n);for(var L=0;L<M;L++)E.f_.bg(m,4*((E.f_.Nf-1)*M+L),n);if(D==2)j=2;if(D==5)j=5;
if(D>1||D==1&&M>20)for(var L=1;L<j;L++)E.f_.am_(m,L*(M/j),M,(L&1)==1?.8:.7,n);return{p0:m,step:D}};E.f_.am_=function(w,n,W,D,j){var n=Math.round(n);
for(var I=Math.round(E.f_.Nf*D);I<E.f_.Nf-1;I++)E.f_.bg(w,4*(I*W+n),j)};E.f_.bg=function(w,n,W){w[n+0]=W>>16&255;
w[n+1]=W>>8&255;w[n+2]=W&255};E.f_.a6O=function(w,n,W,D,j,I,U){var M=w.xq.m,m=w.xq.n,l=E.f_.Nf,A=n&255,g=n>>8&255,k=n>>16&255;
n=Math.round(A*.6)<<16|Math.round(g*.6)<<8|Math.round(k*.6);E.f_.axz(Math.round(A*.8)<<16|Math.round(g*.8)<<8|Math.round(k*.8),W);
var $=w.N,C=w.R,f=w.Tg;for(var z=0;z<2;z++){var s=z==0?I:U;w.N=s[0];w.R=s[1];w.Tg=0;var O=this.a38(w.N,n,W),a=w.Cg(0,0),X=w.Cg(M,m),P=Math.floor(a.x/O.step)*O.step,Z=Math.ceil(X.x/O.step)*O.step,Y=Math.floor(a.y/O.step)*O.step,K=Math.ceil(X.y/O.step)*O.step,S=w.m9(P,Y),G=w.m9(Z,Y),V=O.step*w.N,T=Math.ceil(V);
if(z==1){var R=O.p0;O.p0=E.Q(R.length*4);E.K.nJ(R,O.p0,T,l)}var x=z==0?w.eJ.data:w.Ie.data,v=new iB(0,0,[M,l][z],[l,m][z]),N=new iB(0,0,[T,l][z],[l,T][z]),u=new iB([0,Math.round(l*.2)][z],[Math.round(l*.08),0][z],E.f_.XR,E.f_.XR),H=(z==0?Z-P:K-Y)/O.step;
for(var L=0;L<H;L++){if(z==0)N.x=Math.round(S.x+L*V);else N.y=Math.round(S.y+L*V);E.Cb(O.p0,N,x,v,N);
var F=(z==0?P+L*O.step:Math.abs(Y+L*O.step)).toString(10);for(var t=0;t<F.length;t++){if(z==0)u.x=N.x+3+t*Math.round(E.f_.XR*.8);
else u.y=N.y+3+t*Math.round(E.f_.XR*1.15);var o=E.f_.Q4[F[t]];E.Cb(o,u,x,v,u)}}}w.N=$;w.R=C;w.Tg=f;var q=Math.floor(l*.6),_=new Uint32Array(w.eJ.data.buffer),d=new Uint32Array(w.Ie.data.buffer),r=A<128?4278190080:4294967295;
if(0<D&&D<M)for(var L=0;L<q;L++)_[L*M+D]=r;if(0<j&&j<m)for(var L=0;L<q;L++)d[j*l+L]=r};E.scale={};E.scale.T=document.createElement("canvas");
E.scale.VE=E.scale.T.getContext("2d");E.scale.GP=function(w,n,W){var D=E.scale.T,j=E.scale.VE;D.width=n;
D.height=W;var I=new ImageData(new Uint8ClampedArray(w.buffer),n,W);j.putImageData(I,0,0);return j.createPattern(j.canvas,"repeat")};
E.scale.a2D=function(w,n,W,D,j,I,U,M,m){var l=E.scale.adg(w,W,D,j,I,U,M,m);if(n)n.set(l);return new Uint8Array(l.buffer)};
E.scale.adg=function(w,n,W,D,j,I,U,M){var m=E.Om(n,W);m.save();m.rect(0,0,n,W);m.translate(I,U);m.scale(D,j);
if(M!=null)m.rotate(-M);m.fillStyle=w;m.fill();m.restore();return new Uint8Array(m.getImageData(0,0,n,W).data.buffer)};
E.scale.D=function(w,n,W,D,j){var I=W.k==0&&W.Cj==0,U=j.m,M=j.n,m=E.p.Wx(n,W).w,l=E.p.lV(m,I).wU(j),A=l.x,g=l.y,k=A+l.m,$=g+l.n,C=~~n.x,f=~~n.y,z=~~n.m,s=~~n.n;
if(I)for(var O=g;O<$;O++){var a=W.j7*(O+.5)+W.EU-f,X=~~a*z;for(var P=A;P<k;P++){var Z=W.dl*(P+.5)+W.z2-C;
D[O*U+P]=w[X+~~Z]}}else for(var O=g;O<$;O++)for(var P=A;P<k;P++){var Y=P+.5,K=O+.5,Z=W.dl*Y+W.Cj*K+W.z2-C,a=W.k*Y+W.j7*K+W.EU-f;
if(0<=Z&&0<=a&&Z<z&&a<s)D[O*U+P]=w[~~a*z+~~Z]}};E.scale.uq=function(w,n,W,D,j,I){var U=new Uint32Array(w.buffer),M=new Uint32Array(D.buffer),m=j.m,l=j.n,A=E.p.Wx(n,W).w,g=I?j:E.p.lV(A).wU(j),k=g.x,$=g.y,C=k+g.m,f=$+g.n,z=~~n.x,s=~~n.y,O=~~n.m,a=~~n.n;
for(var X=$;X<f;X++)for(var P=k;P<C;P++){var Z=P+.5,Y=X+.5,K=W.dl*Z+W.Cj*Y+W.z2-z,S=W.k*Z+W.j7*Y+W.EU-s;
if(I){K=((O<<10)+K)%O;S=((a<<10)+S)%a}if(0<=K&&0<=S&&K<O&&S<a)M[X*m+P]=U[~~S*O+~~K]}};E.scale.pQ=function(w,n,W,D,j,I,U){if(U<1)E.scale.a3t(w,n,W,D,j,I,Math.round(1/U));
else E.scale.a4D(w,n,W,D,j,I,U)};E.scale.cg=function(w,n,W,D,j,I,U,M){if(M)M=M.wU(new iB(0,0,n,W));w=new Uint32Array(w.buffer);
D=new Uint32Array(D.buffer);if(U<1)E.scale.aaE(w,n,W,D,j,I,Math.round(1/U),M);else E.scale.aw4(w,n,W,D,j,I,U)};
E.scale.a4D=function(w,n,W,D,j,I,U){for(var M=0;M<W;M++)for(var m=0;m<n;m++){var l=w[M*n+m],A=Math.min(U,j-m*U),g=Math.min(U,I-M*U);
for(var L=0;L<g;L++)for(var k=0;k<A;k++)D[(U*M+L)*j+U*m+k]=l}};E.scale.a3t=function(w,n,W,D,j,I,U){for(var M=0;
M<I;M++)for(var m=0;m<j;m++){var l=0,A=Math.min(U,n-m*U),g=Math.min(U,W-M*U);for(var L=0;L<g;L++)for(var k=0;
k<A;k++)l+=w[(U*M+L)*n+(U*m+k)];D[M*j+m]=Math.round(l/(A*g))}};E.scale.aw4=function(w,n,W,D,j,I,U){for(var M=0;
M<W;M++)for(var m=0;m<n;m++){var l=w[M*n+m],A=Math.min(U,j-m*U),g=Math.min(U,I-M*U);for(var L=0;L<g;
L++)for(var k=0;k<A;k++)D[(U*M+L)*j+U*m+k]=l}};E.scale.a1p=function(w,n,W){return(w>>>W&255)+(n>>>W&255)>>>1};
E.scale.xb=function(w,n){var W=E.scale.a1p;return W(w,n,24)<<24|W(w,n,16)<<16|W(w,n,8)<<8|W(w,n,0)};
E.scale.aA9=function(w,n,W,D,j,I){var U=new Uint32Array(w.buffer),M=new Uint32Array(D.buffer);for(var m=0;
m<W;m++){for(var l=0;l<n;l++){var A=m*n+l,g=U[A],k=g,$=g,C=g;if(l<n-1)k=E.scale.xb(g,U[A+1]);if(m<W-1)$=E.scale.xb(g,U[A+n]);
if(l<n-1&&m<W-1)C=E.scale.xb(g,U[A+n+1]);var f=(m*j+l)*2;M[f]=g;M[f+1]=k;M[f+j]=$;M[f+j+1]=C}}if((j&1)==1)for(var m=0;
m<I;m++)M[m*j+j-1]=M[m*j+j-2];var z=j*(I-1);if((I&1)==1)for(var l=0;l<j;l++)M[z+l]=M[z-j+l]};E.scale.aaE=function(w,n,W,D,j,I,U,M){var m=0,l=j,A=0,g=I;
if(M){m=Math.floor(M.x/U);l=Math.ceil((M.x+M.m)/U);A=Math.floor(M.y/U);g=Math.ceil((M.y+M.n)/U)}for(var k=A;
k<g;k++)for(var $=m;$<l;$++){var C=0,f=0,z=0,s=0,O=Math.min(U,n-$*U),a=Math.min(U,W-k*U);for(var L=0;
L<a;L++)for(var X=0;X<O;X++){var P=w[(U*k+L)*n+U*$+X],Z=P>>>24;C+=Z;f+=Z*(P>>>16&255);z+=Z*(P>>>8&255);
s+=Z*(P&255)}if(C!=0){var Y=1/C;D[k*j+$]=C/(O*a)<<24|f*Y<<16|z*Y<<8|s*Y}else D[k*j+$]=0}};E.J=function(){function w(M,m,L){return(128&M[L-m-1]&M[L-m]&M[L-2]&M[L-1]&M[L+1]&M[L+m-1]&M[L+m])==0}function n(M,m,L){return(128&M[L-m-m]&M[L-m+1]&M[L+2]&M[L+m+1]&M[L+m+m])==0}function W(M,m,L){return(M[L-m]&M[L-1]&M[L+1]&M[L+m]&128)==0}function D(M,L){return(M[L]&128)!=0}function j(M,m,l,A){var L=0,g=l.m,k=l.n;
if(A)for(var $=0;$<k;$++)for(var C=0;C<g;C++){if(D(M,L)&&(C<2||$<2||C>g-3||$>k-3||((M[L-1]&128)==0||m[L-1]!=0)&&w(M,g,L)||n(M,g,L)))m[L]=255;
L++}else for(var $=0;$<k;$++)for(var C=0;C<g;C++){if(D(M,L)&&(C==0||$==0||C==g-1||$==k-1||W(M,g,L)))m[L]=255;
L++}}function I(M,m,l,A,g){var k=l.m,$=l.n,C=new Uint8Array(m.buffer),f=new Uint32Array(m.buffer);if(g)for(var z=2;
z<$-2;z++)for(var s=2;s<k-2;s++){var L=z*k+s;if(D(M,L)&&(((M[L-1]&128)==0||f[L-1]!=0)&&w(M,k,L)||n(M,k,L)))f[L]=A[(s+z&4)>>>2]}else for(var z=1;
z<$-1;z++)for(var s=1;s<k-1;s++){var L=z*k+s;if(D(M,L)&&W(M,k,L)){f[L]=A[(s+z&4)>>>2]}}}function U(M,m,l,A,g){var k=l.m,$=l.n,C=new Uint8Array(m.buffer),f=new Uint32Array(m.buffer),L=0;
if(A==1)for(var z=0;z<$;z++)for(var s=0;s<k;s++,L++){var O=M[L];f[L]=255-O>>>1<<24|255}else for(var z=0;
z<$;z++)for(var s=0;s<k;s++,L++){var O=M[L];f[L]=255<<24|(O<<16|O<<8|O)}}return{aAz:j,anb:I,awn:U}}();
E.nj={};E.nj.VP=function(w,n,W){var D,j;if(W==0){D=w.rect.clone();j=E.nj.afk}if(W==1){D=w.rect.x0(n.rect);
j=E.nj.x0}if(W==2){D=n.rect.clone();j=E.nj.a1H}if(W==3){D=w.rect.wU(n.rect);j=E.nj.wU}if(W==4){D=w.rect.x0(n.rect);
j=E.nj.aaj}if(D.VY())return null;var I=E.Q(D.O());E.B0(n.channel,n.rect,I,D);var U=E.Q(D.O());E.B0(w.channel,w.rect,U,D);
j(U,I,I);var M=E.Nb(I,D);if(M.VY())return null;if(!M.s9(D)){var m=E.Q(M.O());E.B0(I,D,m,M);I=m;D=M}return{channel:I,rect:D}};
E.nj.afk=function(w,n,W){for(var L=0;L<w.length;L++)W[L]=w[L]};E.nj.x0=function(w,n,W){for(var L=0;L<w.length;
L++)W[L]=Math.min(w[L]+n[L],255)};E.nj.a1H=function(w,n,W){for(var L=0;L<w.length;L++)W[L]=Math.max(n[L]-w[L],0)};
E.nj.wU=function(w,n,W){var D=1/255;for(var L=0;L<w.length;L++)W[L]=w[L]*n[L]*D};E.nj.aaj=function(w,n,W){var D=1/255;
for(var L=0;L<w.length;L++)W[L]=Math.min(w[L]+n[L],255)-w[L]*n[L]*D};E.l2=function(w,n){this.c=[];this.E7=[0];
this.zT=[];this.AF=[];this.Rl=[0];this.b$=[];this.$0=[];this.rows=w;this.cols=n};E.l2.prototype.clone=function(){var w=this,n=w.rows,W=w.cols,D=new E.l2(n,W);
D.c=w.c.slice(0);D.E7=w.E7.slice(0);D.zT=w.zT.slice(0);D.AF=w.AF.slice(0);D.Rl=w.Rl.slice(0);D.b$=w.b$.slice(0);
D.$0=w.$0.slice(0);return D};E.l2.prototype.eM=function(w,n,W){var D=this.E7.length-1;for(var L=0;L<W;
L++){var j=w[L],I=n[L];this.c.push(j);this.zT.push(I);if(I==D){this.$0.push(j==0?0:1/j)}else{this.AF.push(j);
this.b$.push(I)}}this.E7.push(this.c.length);this.Rl.push(this.AF.length)};E.l2.prototype.uo=function(w,n){var W=this,D=W.rows,j=W.c,I=W.zT;
if(n==null)n=new Array(D);for(var L=0;L<D;L++){var U=W.E7[L],M=W.E7[L+1],m=0;while((M-U&3)!=0){m+=j[U]*w[I[U]];
U++}for(var l=U;l<M;l+=4)m+=j[l]*w[I[l]]+j[l+1]*w[I[l+1]]+j[l+2]*w[I[l+2]]+j[l+3]*w[I[l+3]];n[L]=m}return n};
E.l2.prototype.multiply=function(w){return this.sg(w.nJ())};E.l2.prototype.sg=function(w){var n=this,W=n.rows,D=n.cols,j=w.rows,I=new E.l2(W,j),U=n.zT,M=w.zT;
for(var L=0;L<W;L++){var m=[],l=[],A=n.E7[L],g=n.E7[L+1];for(var k=0;k<j;k++){var $=w.E7[k],C=w.E7[k+1],f=0,z=A,s=$;
while(z<g&&s<C){var O=Math.max(U[z],M[s]);while(z<g&&U[z]<O)z++;while(s<C&&M[s]<O)s++;if(z<g&&s<C&&U[z]==M[s])f+=n.c[z++]*w.c[s++]}if(f!=0){m.push(f);
l.push(k)}}I.eM(m,l,m.length)}return I};E.l2.prototype.nJ=function(){var w=this.rows,n=this.cols,W=[];
for(var L=0;L<n;L++)W.push([[],[]]);var D=this.c,j=this.E7,I=this.zT;for(var L=0;L<w;L++){var U=j[L],M=j[L+1];
for(var m=U;m<M;m++){var l=W[I[m]];l[0].push(D[m]);l[1].push(L)}}var A=new E.l2(n,w);for(var L=0;L<n;
L++)A.eM(W[L][0],W[L][1],W[L][1].length);return A};E.l2.prototype.PL=function(){var w=this.rows,n=this.cols,W=new Array(w),D=this.c,j=this.E7,I=this.zT;
for(var L=0;L<w;L++){var U=W[L]=new Array(n);for(var M=0;M<n;M++)U[M]=0;var m=j[L],l=j[L+1];for(var A=m;
A<l;A++)U[I[A]]=D[A]}return W};E.l2.prototype.vS=function(w,n,W,D,j){function I(Y,n,K,S){var G=Y.length;
for(var L=0;L<G;L++)S[L]=Y[L]-n[L]*K}function U(Y,n,K,S){var G=Y.length,V=0;while((G-V&3)!=0){S[V]=Y[V]+n[V]*K;
V++}for(var L=V;L<G;L+=4){S[L]=Y[L]+n[L]*K;S[L+1]=Y[L+1]+n[L+1]*K;S[L+2]=Y[L+2]+n[L+2]*K;S[L+3]=Y[L+3]+n[L+3]*K}}function M(Y,n,K){var S=Y.length;
for(var L=0;L<S;L++)K[L]=Y[L]*n[L]}function m(Y,n){var K=Y.length,S=0,G=0;while((K-S&3)!=0){G+=Y[S]*n[S];
S++}for(var L=S;L<K;L+=4)G+=Y[L]*n[L]+Y[L+1]*n[L+1]+Y[L+2]*n[L+2]+Y[L+3]*n[L+3];return G}var l=D!=null?2:1,A=Date.now(),g=0,k=this,$=w.slice(0),C=w.slice(0);
k.uo(w,C);I(n,C,1,$);var f=this.$0;if(l==0){f=$.slice(0);f.fill(1)}var z=$.slice(0);M(f,$,z);var s=z.slice(0),O=m($,z);
while(!0){k.uo(s,C);var a=O/m(s,C);U(w,s,a,w);I($,C,a,$);if((g&7)==0&&Math.sqrt(m($,$))<W)break;if(l<=1)M(f,$,z);
else{var X=$.slice(0);D.a2s(X,$);j.asR(z,X)}var P=m($,z),Z=P/O;U(z,s,Z,s);O=P;g++}};E.l2.prototype.azR=function(w,n,W,D){var j=Date.now(),I=1.96,M=0;
if(W==null)W=5e-6;if(D==null)D=1e9;var U=1-I,bK=this.rows,m=this.AF,l=this.Rl,A=this.b$,g=this.$0;while(!0){var k=0;
for(var L=0;L<bK;L++){var $=n[L],C=l[L],f=l[L+1];if(f-C==4)$-=m[C]*w[A[C]]+m[C+1]*w[A[C+1]]+m[C+2]*w[A[C+2]]+m[C+3]*w[A[C+3]];
else for(var z=C;z<f;z++)$-=m[z]*w[A[z]];var s=w[L]*U+g[L]*$*I,O=s-w[L];k+=O*O;w[L]=s}if(k/bK<W||Date.now()>j+D)break}};
E.l2.prototype.a7C=function(w,n,W,D){var j=Date.now(),I=1.96,M=0;if(W==null)W=5e-5;if(D==null)D=1e9;
var U=1-I,bK=this.rows,m=this.AF,l=this.Rl,A=this.b$,g=this.$0;while(!0){var k=0;for(var L=0;L<bK;L++){var $=L*3,C=n[$],f=n[$+1],z=n[$+2],s=l[L],O=l[L+1];
for(var a=s;a<O;a++){var X=m[a],P=A[a]*3;C-=X*w[P+0];f-=X*w[P+1];z-=X*w[P+2]}var Z=g[L]*I,Y=w[$+0]*U+C*Z,K=w[$+1]*U+f*Z,S=w[$+2]*U+z*Z,G=Y-w[$+0],V=K-w[$+1],T=S-w[$+2];
k+=.4*G*G+.5*V*V+.1*T*T;w[$+0]=Y;w[$+1]=K;w[$+2]=S}if(k/bK<W||Date.now()>j+D)break}};E.MU={};E.MU.$j=function(w,n,W){return{t:"Objc",v:{classID:"CrPt",Hrzn:{t:"doub",v:w},Vrtc:{t:"doub",v:n},Cnty:{t:"bool",v:W}}}};
E.MU.D=function(w,n){for(var L=0;L<w.length;L++){var W=w[L].v,D=n.bj(new ec(W.Hrzn.v,W.Vrtc.v));W.Hrzn.v=Math.round(D.x);
W.Vrtc.v=Math.round(D.y)}};E.MU.r5=function(w,n,W){var bK=w.length-1,D=E.GY.Gx(bK+1,bK+2);for(var L=1;
L<bK;L++){D[L][L-1]=1/(w[L]-w[L-1]);D[L][L]=2*(1/(w[L]-w[L-1])+1/(w[L+1]-w[L]));D[L][L+1]=1/(w[L+1]-w[L]);
D[L][bK+1]=3*((n[L]-n[L-1])/((w[L]-w[L-1])*(w[L]-w[L-1]))+(n[L+1]-n[L])/((w[L+1]-w[L])*(w[L+1]-w[L])))}D[0][0]=2/(w[1]-w[0]);
D[0][1]=1/(w[1]-w[0]);D[0][bK+1]=3*(n[1]-n[0])/((w[1]-w[0])*(w[1]-w[0]));D[bK][bK-1]=1/(w[bK]-w[bK-1]);
D[bK][bK]=2/(w[bK]-w[bK-1]);D[bK][bK+1]=3*(n[bK]-n[bK-1])/((w[bK]-w[bK-1])*(w[bK]-w[bK-1]));E.GY.hU(D,W)};
E.MU.alG=function(w,n,W,D){if(w<=n[0])return W[0];if(w>=n[n.length-1])return W[n.length-1];var L=1;while(n[L]<w)L++;
var j=n[L],I=n[L-1],U=W[L],M=W[L-1],m=(w-I)/(j-I),l=D[L-1]*(j-I)-(U-M),A=-D[L]*(j-I)+(U-M),g=(1-m)*M+m*U+m*(1-m)*(l*(1-m)+A*m);
return g};E.MU.bY=function(w,n,W,D){var j={hP:[w[0]],c$:[n[0]],DE:[]};D[0]=j;for(var L=1;L<w.length-1;
L++){j.hP.push(w[L]);j.c$.push(n[L]);if(W[L]==!1){E.MU.r5(j.hP,j.c$,j.DE);j={hP:[w[L]],c$:[n[L]],DE:[]}}D[L]=j}j.hP.push(w[L]);
j.c$.push(n[L]);E.MU.r5(j.hP,j.c$,j.DE);D[L]=j};E.MU.dG=function(w,n,W,D){if(w<=n[0])return W[0];if(w>=n[n.length-1])return W[n.length-1];
var L=1;while(n[L]<w)L++;var j=D[L-1];return E.MU.alG(w,j.hP,j.c$,j.DE)};E.MU.Is=function(w){var n={hP:[],c$:[],rl:[]};
for(var L=0;L<w.length;L++){n.hP[L]=w[L].v.Hrzn.v;n.c$[L]=w[L].v.Vrtc.v;n.rl[L]=w[L].v.Cnty?w[L].v.Cnty.v:!0}return n};
E.MU.I5=function(w,bK,n){var W=0,D=255;if(n){W=-1e9;D=1e9}var j=E.MU.Is(w),I=[];E.MU.bY(j.hP,j.c$,j.rl,I);
var U=[];for(var L=0;L<bK;L++)U[L]=1/255*Math.max(W,Math.min(D,E.MU.dG(L*(255/(bK-1)),j.hP,j.c$,I)));
return U};E.MU.anS=function(w,bK,n){var W=Math.round(w.length/20),D=bK-w.length,j=n?(w[W]-w[0])/W:0,I=n?w[0]-D*j:w[w.length-1],U=[];
for(var L=0;L<D;L++)U.push(I+L*j);return n?U.concat(w):w.concat(U)};E.MU.ou=function(w,bK,n){var W=E.MU.Is(w),D=[];
E.MU.bY(W.hP,W.c$,W.rl,D);var j=new Uint8Array(bK),I=bK/256;for(var L=0;L<bK;L++)j[L]=Math.max(0,Math.min(bK-1,E.MU.dG(L*I,W.hP,W.c$,D)));
if(n){j[0]=0;if(j[1]>100)j[1]=.4*j[1];if(j[2]>150)j[1]=.7*j[2]}return j};E.MU.Ao=function(w,n){var W=new Uint8Array(w.length);
for(var L=0;L<w.length;L++)W[L]=n[w[L]];return W};E.MU.sX=function(w,n,W){var D=document.createElement("canvas");
D.width=n;D.height=W;var j=D.getContext("2d"),I=E.MU.ou(w,256);j.scale(n/255,W/255);j.fillStyle="#fff";
j.fillRect(0,0,255,255);j.fillStyle="#333";j.beginPath();j.moveTo(0,255);for(var L=0;L<I.length;L++)j.lineTo(L,255-I[L]);
j.lineTo(255,255);j.closePath();j.fill();return D.toDataURL()};E.style={};E.style.stroke=function(w,n,W,D){var j=W.m,I=W.n,U=new Float64Array(j*I);
E.style.Wf(w,U,j,I);E.style.aX(n,W,U,W,D)};E.style.aX=function(w,n,W,D,j){var I=n.wU(D),U=I.m,M=I.n;
j+=.5;var m=I.x-n.x,l=I.y-n.y,A=n.m,g=I.x-D.x,k=I.y-D.y,$=D.m;for(var C=0;C<M;C++){var f=(C+k)*$+g,z=(C+l)*A+m;
for(var s=0;s<U;s++){var O=Math.max(0,Math.min(1,j-W[f+s]));w[z+s]=Math.round(O*255)}}};E.style.avO=function(w,n,W,D){for(var j=0;
j<W;j++)for(var I=0;I<n;I++){var U=j*n+I,M=0,m=0,l=w[U];if(I==0||j==0){M=w[U+1]-l;m=w[U+n]-l}else if(I==W-1||j==n-1){M=l-w[U-1];
m=l-w[U-n]}else{M=w[U+1]-w[U-1];m=w[U+n]-w[U-n]}if(M!=0||m!=0){var A=1/Math.sqrt(M*M+m*m);M*=A;m*=A}D[U+U]=M;
D[U+U+1]=m}};E.style.Wf=function(w,n,W,D){var j=0,I=W*D;for(var L=0;L<I;L++)j|=w[L];if(j==0){n.fill(1e9);
return}var U=E.style.Mh(w,W,D);for(var M=0;M<D;M++)for(var m=0;m<W;m++){var L=M*W+m,l=U[L*2],A=U[L*2+1],g=(M+A)*W+m+l;
if(l==0&&A==0){n[L]=0;continue}var k=Math.sqrt(l*l+A*A),$=w[g]*(1/255),C=1/k,f=Math.abs(l)*C,z=Math.abs(A)*C;
if(z>f){var s=z;z=f;f=s}n[L]=k+E.style.azb(f,z,$)}};E.style.azb=function(w,n,W){return(.5-W)*w};E.style.Mh=function(w,n,W,D){var j=new Int16Array(n*W*2);
E.style.ah2(w,j,n,W,128);return j};E.style.ah2=function(w,n,W,D,j){var I=new Int32Array(W*D);E.style.apr(w,I,W,D,j);
E.style.anF(I,n,W,D)};E.style.apr=function(w,n,W,D,j){var I=new Int32Array(D);for(var U=0;U<W;U++){var M=W+D;
for(var m=D-1;m>=0;m--){if(w[m*W+U]>j)M=0;else M++;I[m]=M}M=W+D;for(var m=0;m<D;m++){if(w[m*W+U]>j)M=0;
else M++;n[m*W+U]=M<I[m]?-M:I[m]}}};E.style.anF=function(w,n,W,D){var j=(W+D)*(W+D),I=new Float64Array(W),U=new Uint16Array(W);
for(var M=0;M<D;M++){var m=M*W,l=0;U[0]=0;I[0]=-j;I[1]=+j;for(var A=1;A<W;A++){var g=w[A+m]*w[A+m]+A*A,k=(g-(w[U[l]+m]*w[U[l]+m]+U[l]*U[l]))/(2*A-2*U[l]);
while(k<=I[l]){l--;k=(g-(w[U[l]+m]*w[U[l]+m]+U[l]*U[l]))/(2*A-2*U[l])}l++;U[l]=A;I[l]=k;I[l+1]=j}l=0;
for(var A=0;A<W;A++){while(I[l+1]<A)l++;var $=U[l]-A,C=w[U[l]+m],L=M*W+A<<1;n[L]=$;n[L+1]=C}}};E.style.Mq=function(w,n,W){if(W)for(var L=0;
L<w.length;L++){var D=w[L];if(D>0)w[L]=Math.max(0,Math.min(255,D+n*2*(E.style.lr(L)-128)))}else for(var L=0;
L<w.length;L++){var D=w[L];if(D>0)w[L]=Math.max(0,Math.min(255,D+Math.min(D*3,n*2*(E.style.lr(L)-128))))}};
E.style.lr=function(w){w=w^61^w>>16;w=w+(w<<3);w=w^w>>4;w=w*668265261;w=w^w>>15;return w&255};E.qg={};
E.qg.Va=function(w,n,W){var D=w.canvas;if(D.width!=n||D.height!=W){D.width=n;D.height=W}};E.qg.ow=function(w,n,W,D,j,I){E.qg.Va(w,n,W);
if(I==null)I=!1;var U=j.channel,M=j.rect,m=!j.isEnabled;if(n*W==0)return;var l=w.createImageData(n,W),A=l.data,g=1/n,k=1/W;
for(var L=0;L<W;L++)for(var $=0;$<n;$++){var C=L*n+$,f=C*4,z=Math.round(D.x+$*g*D.m),s=Math.round(D.y+L*k*D.n),O=0;
if(z<M.x||z>=M.x+M.m||s<M.y||s>=M.y+M.n)O=j.color;else O=U[(s-M.y)*M.m+(z-M.x)];O=255*(255-j.MX)+O*j.MX>>>8;
if(I)O=170+Math.round(.4*(O-170));A[f]=O;A[f+1]=O;A[f+2]=O;A[f+3]=255}w.putImageData(l,0,0);if(m)E.qg.ko(w,n,W)};
E.qg.Ev=[];E.qg.aak=function(w,n,W,D){var j,I,U;j=Math.ceil(Math.max(n,W)*.35);I=n-j;U=W-j;var M=E.qg.Ev[j];
if(M==null){var m=E.Om(j,j);m.fillStyle="#eeeeee";m.fillRect(0,0,j,j);var l=Math.round(j*.27),A=m.lineWidth=Math.max(1,Math.round(j*.12)),g=A/2;
m.strokeRect(1+g,1+g,j-A-2,j-A-2);m.strokeRect(l+g,l+g,j-l-l-A,j-l-l-A);M=E.qg.Ev[j]=m.getImageData(0,0,j,j)}w.putImageData(M,I,U)};
E.qg.xY=[];E.qg.azI=function(w,n,W){var D,j,I;D=Math.ceil(Math.max(n,W)*.35);j=n-D;I=W-D;var U=E.qg.xY[D];
if(U==null){var M=E.Om(D,D);M.fillStyle="#eeeeee";M.fillRect(0,0,D,D);M.lineWidth=1;M.strokeRect(2.5,2.5,D-5,D-5);
var m=M.createImageData(3,3);E.cJ(m.data,4278190080);m.data[4*4]=m.data[4*4+1]=m.data[4*4+2]=238;M.putImageData(m,1,1);
M.putImageData(m,D-4,1);M.putImageData(m,1,D-4);M.putImageData(m,D-4,D-4);U=E.qg.xY[D]=M.getImageData(0,0,D,D)}w.putImageData(U,j,I)};
E.qg.apI=function(w,n,W,D,j){E.qg.Va(w,n,W);var I=n/D.m;if(n*W==0)return;w.fillStyle="#999999";w.setTransform(1,0,0,1,0,0);
w.clearRect(0,0,n,W);var U=E.qg.Yn;if(U==null){U=E.qg.Yn=JSON.parse(JSON.stringify(at.QO.default));U.strokeEnabled.v=!0}U.strokeStyleLineWidth.v.val=1/I;
w.fillStyle="#ffffff";w.scale(I,I);E.P.BZ(j.i,w,0,0);E.P.BZ(j.i,w,0,0,U)};E.qg.S5=null;E.qg.mi=function(w,n,W,D,j,I,U,M,m){E.qg.Va(w,n,W);
if(n*W==0)return;var l=Math.max(n,W),A=E.qg.S5;if(A==null||A.width<l||A.height<l){E.qg.S5=A=w.createImageData(l,l)}l=A.width;
var g=A.data,k=D.m/n,$=D.n/W,C=I.x,f=I.x+I.m,z=I.y,s=I.y+I.n;for(var L=0;L<W;L++)for(var O=0;O<n;O++){var a=L*l+O,X=a*4,P=~~(D.x+O*k),Z=~~(D.y+L*$),Y=E.dv(L,O,2);
if(P<C||P>=f||Z<z||Z>=s||m){g[X]=Y;g[X+1]=Y;g[X+2]=Y;g[X+3]=255}else{var K=(Z-I.y)*I.m+(P-I.x)<<2,S=j[K+3]*(1/255);
g[X]=j[K+0]*S+Y*(1-S);g[X+1]=j[K+1]*S+Y*(1-S);g[X+2]=j[K+2]*S+Y*(1-S);g[X+3]=255}}if(M!=null)for(var L=0;
L<g.length;L+=4)g[L]=g[L+1]=g[L+2]=g[L+M];w.putImageData(A,0,0);if(U)E.qg.ko(w,n,W)};E.qg.azH=function(w,n,W,D){E.qg.Va(w,n,W);
w.fillStyle=E.qg.y_(D.Clr.v);w.fillRect(0,0,n,W);E.qg.gT(w,n,W)};E.qg.jY=null;E.qg.a2W=function(w,n,W,D){E.qg.Va(w,n,W);
var j=w.canvas.width,I=w.canvas.height,U=E.qg.jY;if(U==null||U.width!=j||U.height!=I){w.fillStyle="#ffffff";
w.fillRect(0,0,n,W);w.fillStyle="#000000";w.font=""+W*.7+"px serif";w.fillText("T",(n-W*.43)/2,W*.75);
w.fillText("T",(n-W*.43)/2,W*.75);E.qg.jY=w.getImageData(0,0,j,I)}else w.putImageData(U,0,0)};E.qg.a6w=function(w,n,W){E.qg.Va(w,n,W);
w.clearRect(0,0,n,W);w.font=W*.7+"px serif";w.fillText(":(",(n-W*.43)/2,W*.7)};E.qg.az0=function(w,n,W,D){E.qg.Va(w,n,W);
var j=eH.get(D),I=w.canvas.width,U=E.qg.pT[I+j];if(U==null){var M=PIMG["adj/"+j],m=jj.aL(M),l=UPNG.decode(m.buffer),A=new Uint8Array(UPNG.toRGBA8(l)[0]),g=new iB(0,0,160,160),k=0,$=I-k*2,C=y.wR.lD([A,g],new eh($/160,0,0,$/160,0,0)),f=new iB(0,0,I,I),z=E.Q(f.O()*4);
E.s._U("norm",C.buffer,C.rect,z,f,C.rect,1);U=E.qg.pT[I+j]=new ImageData(new Uint8ClampedArray(z.buffer),I,I)}w.putImageData(U,0,0)};
E.qg.pT={};E.qg.af8=function(w,n,W,D){E.qg.Va(w,n,W);var j=w.canvas.width,I=w.canvas.height,U=w.getImageData(0,0,j,I);
E.M.Yd(D.Grad.v,new Uint8Array(U.data.buffer),new iB(0,0,j,I),[1/j,0,0,1/I],j/2,I/2,!1,0,16711680,65280);
w.putImageData(U,0,0);E.qg.gT(w,n,W)};E.qg.a7x=function(w,n,W,D,j){E.qg.Va(w,n,W);var I=w,U=ge.f$(D.Ptrn.v,j.add.Patt);
if(U==null)return;var M=U.HY[1];E.qg.mi(w,n,W,M,U.HY[0],M,!1);E.qg.gT(I,n,W)};E.qg.ko=function(w,n,W){w.strokeStyle="#bb0000";
w.lineWidth=3;w.beginPath();w.moveTo(n*.15,W*.15);w.lineTo(n*.85,W*.85);w.moveTo(n*.85,W*.15);w.lineTo(n*.15,W*.85);
w.closePath();w.stroke()};E.qg.gT=function(w,n,W){w.fillStyle="#eeeeee";w.fillRect(0,W*.75,n,W*.25);
w.beginPath();w.moveTo(0,W*.75);w.lineTo(n,W*.75);w.moveTo(n*.1,W*.875);w.lineTo(n*.9,W*.875);w.moveTo(n*.65,W*.825);
w.lineTo(n*.65,W*.95);w.closePath();w.stroke()};E.qg.y_=function(w){var n=E.M.y_(w),W=Math.round(n.o)<<16|Math.round(n.B)<<8|Math.round(n.k);
return"#"+E.$$(W)};E.P={};E.P.Mn=function(w,n,W){var D=[],j=-1;for(var L=0;L<w.length;L++){var I=w[L];
if((I.type==0||I.type==3)&&I.Ht!=-1)j++;if(I.type>5||I.type==0||I.type==3)continue;if(n!=null&&n.indexOf(j)==-1)continue;
if(W!=null&&W.indexOf(L)==-1)continue;D.push(I.T7.x);D.push(I.T7.y);D.push(I.H.x);D.push(I.H.y);D.push(I.mO.x);
D.push(I.mO.y)}return D};E.P.r0=function(w,n,W,D){var j=0,I=-1;for(var L=0;L<n.length;L++){var U=n[L];
if((U.type==0||U.type==3)&&U.Ht!=-1)I++;if(U.type>5||U.type==0||U.type==3)continue;if(W!=null&&W.indexOf(I)==-1)continue;
if(D!=null&&D.indexOf(L)==-1)continue;U.T7.y1(w[j],w[j+1]);U.H.y1(w[j+2],w[j+3]);U.mO.y1(w[j+4],w[j+5]);
j+=6}};E.P.c0=function(w,n,W,D){var j=E.P.Mn(w,W,D);E.p.D(j,n,j);E.P.r0(j,w,W,D)};E.P.acl=function(w,n,W,D){var j=E.P.Mn(w,W,D);
E.K.D(n,j);E.P.r0(j,w,W,D)};E.P.ayL=function(w,n,W,D){if(D==null){var j=E.P.afg(w,40,W);for(var L=0;
L<j.length;L++)w[L]=j[L]}var I=E.P.Mn(w,W,D);E.xv.D(n,I,E.p.mY(I));E.P.r0(I,w,W,D)};E.P.afg=function(w,n,W){var D=[],j=-1;
for(var L=0;L<w.length;L++){var I=w[L],U=I.length;if(I.type>5){D.push(JSON.parse(JSON.stringify(I)));
continue}I=JSON.parse(JSON.stringify(I));D.push(I);if(I.Ht!=-1)j++;if(W&&W.indexOf(j)==-1){D=D.concat(w.slice(L+1,L+1+U))}else{var M=E.P.aA6(w,L+1,U);
M=E.p.Av(M,n);var m=E.P.aqC(M);I.length=m.length;for(var l=0;l<m.length;l++)D.push(m[l])}L+=U}return D};
E.P.aA6=function(w,n,W){var D={F:["M"],w:[]},j=w[n],I=w[n+W-1];D.w.push(j.H.x,j.H.y);for(var L=1;L<W;
L++){var U=w[n+L-1],M=w[n+L];D.F.push("C");D.w.push(U.mO.x,U.mO.y,M.T7.x,M.T7.y,M.H.x,M.H.y)}D.F.push("C");
D.w.push(I.mO.x,I.mO.y,j.T7.x,j.T7.y,j.H.x,j.H.y);return D};E.P.aqC=function(w){var n=[],W=w.F,D=w.w,j=0,bK=D.length;
n.push({type:2,T7:new ec(D[bK-4],D[bK-3]),H:new ec(D[0],D[1]),mO:new ec(D[2],D[3])});for(var L=0;L<W.length-2;
L++){var I=L*6+4;n.push({type:2,T7:new ec(D[I],D[I+1]),H:new ec(D[I+2],D[I+3]),mO:new ec(D[I+4],D[I+5])})}return n};
E.P.a8l=function(w){for(var L=0;L<w.length;L++){if(w[L].type>5)continue;var n=w[L].length;if(!(n==4||n==6||n==8)){L+=n;
continue}for(var W=0;W<n;W++){var D=w[L+1+W],j=w[L+1+(W+1)%n],I=Math.min(D.H.x,j.H.x),U=Math.min(D.H.y,j.H.y),M=0,m=0;
if(D.H.x<j.H.x){M=D.H.y-U;m=M-(j.H.x-I)}else{M=j.H.y-U;m=M-(D.H.x-I)}if(Math.abs(m)<.2*M)return M}}return-1};
E.P.b3=function(w,n,W){function D(k,$){var C=Math.min(k.x,$.x),f=Math.min(k.y,$.y),z=Math.max(k.x+k.m,$.x+$.m),s=Math.max(k.y+k.n,$.y+$.n);
return new iB(C,f,z-C,s-f)}var j=null,I=-1,U=!E.P.md(w);for(var L=0;L<w.length;L++){var M=w[L];if(M.type>5)continue;
if((M.type==0||M.type==3)&&M.Ht!=-1)I++;if(n!=null&&n.indexOf(I)==-1)continue;if(L==w.length-1)break;
var m=M.type==3,l=M.length,A=M.Ht,g=E.P.bd(w,L+1,l,m);if(j==null)j=g;else if(W)j=D(j,g);else if(U){if(n!=null||A==0||A==-1||A==2)j=D(j,g);
else if(A==1)j=j;else if(A==3){j=g;U=!1}}else{if(n!=null||A==0||A==-1||A==1)j=D(j,g);else if(A==2)j=j;
else if(A==3)j=j.wU(g)}L+=l}if(j==null||j.m<0||j.n<0)j=new iB(0,0,0,0);return j};E.P.a3Q=new Float64Array(4);
E.P.bd=function(w,L,n,W){var D=E.P.a3Q;D[0]=1e30;D[1]=1e30;D[2]=-1e30;D[3]=-1e30;var j=w[L+n-1];if(!W)E.P.GD(j.H.x,j.H.y,j.mO.x,j.mO.y,w[L].T7.x,w[L].T7.y,w[L].H.x,w[L].H.y,D);
for(var I=L;I<L+n-1;I++){var U=w[I],M=w[I+1];E.P.GD(U.H.x,U.H.y,U.mO.x,U.mO.y,M.T7.x,M.T7.y,M.H.x,M.H.y,D)}return new iB(D[0],D[1],D[2]-D[0],D[3]-D[1])};
E.P.GD=function(w,n,W,D,j,I,U,M,m){if(w==W&&n==D&&j==U&&I==M){m[0]=Math.min(m[0],Math.min(w,U));m[1]=Math.min(m[1],Math.min(n,M));
m[2]=Math.max(m[2],Math.max(w,U));m[3]=Math.max(m[3],Math.max(n,M));return}var l=w,A=n,g=w,k=n,$=40,C=1/($-1);
for(var f=0;f<$;f++){var z=f*C,s=1-z,O=s*s*s,a=3*s*s*z,X=3*s*z*z,P=z*z*z,Z=O*w+a*W+X*j+P*U,Y=O*n+a*D+X*I+P*M;
if(Z<l)l=Z;else if(Z>g)g=Z;if(Y<A)A=Y;else if(Y>k)k=Y}if(l<m[0])m[0]=l;if(A<m[1])m[1]=A;if(g>m[2])m[2]=g;
if(k>m[3])m[3]=k};E.P.QZ=function(w,n){var W=w.length-3,D=n%W,j=Math.floor(D);if(n<0||j>=W)return null;
var I=w[3+j],U=w[3+(j+1)%W],M=I.H,m=I.mO,l=U.T7,A=U.H,g=D-j,k=1-g,$=k*k*k*M.x+3*k*k*g*m.x+3*k*g*g*l.x+g*g*g*A.x,C=k*k*k*M.y+3*k*k*g*m.y+3*k*g*g*l.y+g*g*g*A.y;
return new ec($,C)};E.P.BK=function(w,n){var W=E.p.tq(w),D=W.VN;W.VN=Typr.U.pathToSVG({crds:D.w,cmds:D.F},n==null?2:n);
return W};E.P.JC=function(w){E.P.rJ();var n,W=E.P._k(w),D=[];for(var L=0;L<W.length;L++){var j=W[L][0],I=W[L][1];
if(Math.abs(j.area)<1e-5)D.push(j);else if(n==null)n=j;else{if(!j.closed)j.closed=!0;n=n[I](j);n.remove()}}if(n==null)n=new paper.CompoundPath(D);
else{if(n.segments)n=new paper.CompoundPath(n);for(var L=0;L<D.length;L++){n.addChild(D[L])}}var U=w.slice(0,2);
U=U.concat(E.P.SB(n));if(U[2])U[2].Ht=1;for(var L=3;L<U.length;L++)if(U[L].Ht!=null)U[L].Ht=-1;return U};
E.P.rJ=function(){if(E.P.a4m==null){var w=document.createElement("canvas");paper.setup(w);E.P.a4m=!0}};
E.P.a5K=function(w,n){E.P.rJ();var W=[],D=E.P._k(w),j=new paper.Path.Rectangle(new paper.Rectangle(n.x,n.y,n.m,n.n));
j.remove();j.fillColor=new paper.Color(1,0,0);for(var L=0;L<D.length;L++){if(j.intersects(D[L][0])||j.contains(D[L][0].children[0].segments[0].point))W.push(L)}return W};
E.P.pw=function(w,n,W,D){E.P.rJ();var j=W?{curves:!0,tolerance:D}:null,I=new paper.Point(n.x,n.y),U=E.P._k(w);
for(var L=U.length-1;L>=0;L--){var M=U[L][0],m=M.hitTest(I,j);if(m!=null)return{p_:L,po:W?m.location.index:null,Sd:W?m.location.time:0}}return{p_:-1}};
E.P.qk=function(w,n,W){var D=[[],[],[]];for(var L=0;L<w.length;L++){var j=w[L];if(j.type>5||j.type==0||j.type==3)continue;
var I=W==null?!0:W.indexOf(L)!=-1;if(n.y5(j.H))D[0].push(L);if(n.y5(j.T7)&&I)D[1].push(L);if(n.y5(j.mO)&&I)D[2].push(L)}return D};
E.P.a4u=function(w,n,W){var D=w[n];for(var j=n+1;j<W;j++)w[j-1]=w[j];w[W-1]=D};E.P.al2=function(w,n,W,D){var L,j,I,U=0;
w=w.slice(0);n.sort(function(C,f){return C-f});I=-1;for(L=2;L<w.length;){var M=w[L],m=M.length;if(M.Ht!=-1)I++;
var l=U;while(l<n.length&&n[l]<L+1+m)l++;if(U!=l){var A=n.slice(U,l);U=l;for(j=0;j<m;j++)if(A.indexOf(L+1+j)!=-1)w[L+1+j]=null;
if(M.type==0){var g=A[0]-(L+1);while(g!=0){E.P.a4u(w,L+1,L+1+m);g--}}var k=M;k.length=0;j=0;while(j<m&&w[L+1+j]==null)j++;
while(j<m){var $=w[L+1+j];if($!=null)k.length++;else if(j<m+1&&w[L+1+j+1]){k=w[L+1+j]={type:0,Ht:-1,length:0,_T:0,si:0,S1:1}}j++}if(D)for(j=-1;
j<m;j++)if(w[L+1+j]&&w[L+1+j].type<3)w[L+1+j].type+=3;E.X.$G(W,I)}L+=1+m}for(L=0;L<w.length;L++)if(w[L]==null){w.splice(L,1);
L--}I=0;for(L=2;L<w.length;L++){var M=w[L];if(M.length==0){if(w[L+1]&&w[L+1].Ht==-1)w[L+1].Ht=M.Ht;else if(M.Ht!=-1)W.splice(I,1);
w.splice(L,1);L--}else if(M.length!=null&&M.Ht!=-1)I++}return w};E.P.amm=function(w,n){var W=w.slice(0,2),D=-1;
for(var L=2;L<w.length;L++){if((w[L].type==0||w[L].type==3)&&w[L].Ht!=-1)D++;if(n.indexOf(D)==-1)W.push(w[L])}return W};
E.P.apW=function(w,n){var W=w.slice(0,2),D=-1;for(var L=2;L<w.length;L++){if((w[L].type==0||w[L].type==3)&&w[L].Ht!=-1)D++;
if(n.indexOf(D)!=-1)W.push(w[L])}return W};E.P.azz=function(w){var n=0;for(var L=0;L<w.length;L++)if(w[L].type==0||w[L].type==3)n=L;
return w[n]};E.P.bB=function(w){var n=-1;for(var L=0;L<w.length;L++)if((w[L].type==0||w[L].type==3)&&w[L].Ht!=-1)n++;
return n+1};E.P.tt=function(w,n,W){var D=-1;for(var L=0;L<w.length;L++)if((w[L].type==0||w[L].type==3)&&(W||w[L].Ht!=-1)){D++;
if(D==n)return L}return-1};E.P.de=function(w,n,W){var D=-1;for(var L=0;L<w.length;L++)if((w[L].type==0||w[L].type==3)&&(W||w[L].Ht!=-1)){if(L>=n)return D;
D++}return D};E.P.qA=function(w,n){var W=-1,D=0;for(var L=0;L<w.length;L++){if((w[L].type==0||w[L].type==3)&&w[L].Ht!=-1)W++;
if(W==n)D++}return D};E.P.aiR=function(w){var n=180;for(var L=0;L<w.length;L++){if(w[L].type!=0&&w[L].type!=3)continue;
var W=w[L].length;if(W<3)continue;for(var D=0;D<W;D++){var j=w[L+1+(D-1+W)%W],I=w[L+1+D],U=w[L+1+(D+1)%W],M=I.H,m=I.T7.s9(M)?j.mO:I.T7,l=I.mO.s9(M)?U.T7:I.mO;
if(M.s9(m)||M.s9(l))continue;var A=m.x-M.x,g=m.y-M.y,k=l.x-M.x,$=l.y-M.y,m=Math.atan2(m.y-M.y,m.x-M.x)*180/Math.PI,l=Math.atan2(l.y-M.y,l.x-M.x)*180/Math.PI,C=Math.abs(l-m)%360,f=C>180?360-C:C;
if(f<n)n=f}}return n*Math.PI/180};E.P.SB=function(w){var n=w.segments?[w]:w.children,W=[];for(var L=0;
L<n.length;L++){var D=n[L],j=D.segments,I=D.closed?0:3,U=W.length,M=null;if(j.length<=1)continue;W.push({type:I,length:j.length,Ht:0,S1:2});
for(var m=0;m<j.length;m++){var l=j[m],A=new ec(l.handleIn.x,l.handleIn.y),g=new ec(l.handleOut.x,l.handleOut.y),k=new ec(l.point.x,l.point.y),$={type:I+1,T7:k.add(A),H:k,mO:k.add(g)};
if(M==null)M=$;W.push($);if(m+1==j.length&&ec.cS(M.H,$.H)<1e-5){W.pop();W[U].length--;M.T7=$.T7;if(I==3)for(var C=U;
C<W.length;C++)W[C].type-=3}}}return W};E.P._k=function(w){E.P.rJ();var n=[],W,D=new paper.Color(1,0,0);
function j($,M){$.remove();$.closed=!M;$.fillRule="evenodd"}for(var L=0;L<w.length;L++){if(w[L].type>5)continue;
var I=w[L].length,U;if(L==w.length-1)break;var M=w[L].type==3;if(L==2){if(!E.P.dX(w))U="subtract";else U="unite"}else{if(w[L].Ht==0)U="exclude";
if(w[L].Ht==1)U="unite";if(w[L].Ht==2)U="subtract";if(w[L].Ht==3)U="intersect"}if(w[L].Ht!=-1){W=new paper.CompoundPath;
n.push([W,U]);W.fillRule="evenodd";W.fillColor=D}var m=[];for(var l=0;l<I;l++){var A=w[L+1+l],g=A.T7.eu(A.H),k=A.mO.eu(A.H);
m.push([[A.H.x,A.H.y],[g.x,g.y],[k.x,k.y]])}var $=new paper.Path(m);j($,M);W.addChild($);L+=I}return n};
E.P.q9=function(w){for(var L=0;L<w.length;L++){var n=w[L];if(n.H==null)continue;if(!n.H.s9(n.T7)||!n.H.s9(n.mO))return!1}return!0};
E.P.ajv=function(w){if(w.length<=5)return 0;var n=0,W=w.length-3-1;for(var L=0;L<W;L++){var D=w[3+L],j=w[3+L+1];
if(D.type==0||j.type==0)return 0;n+=(j.H.x-D.H.x)*(D.H.y+j.H.y)}n+=(w[3].H.x-w[3+W].H.x)*(w[3+W].H.y+w[3+1].H.y);
return-n*.5};E.P.md=function(w){var n=w[2],W=!1;if(w.length==2)W=w[1].all==0;else if(w[1].all==1){if(n.Ht==1||n.Ht==3)W=!0;
else W=!1}else{if(n.Ht==1||n.Ht==3||n.Ht==0)W=!0;else W=!1}return W};E.P.dX=function(w){var n=E.P.md(w);
for(var L=3;L<w.length;L++)if(w[L].Ht==3)n=!0;return n};E.P.ayh=0;E.P.B_=0;E.P.a80=0;E.P.a2k=function(w,n,W,D){if(W.VY())return;
var j=W.O(),s=16384;E.P.ayh+=j;if(j>E.P.B_){E.P.B_=j}var I=W.m,U=W.n;if(D==null&&E.P.q9(w)&&w[2]&&w[2].Ht!=2){var M=!0;
for(var L=2;L<w.length;)if(w[L].length==2)L+=3;else{M=!1;break}if(M){return}if(E.P.tF(w)){n.fill(255);
var m=E.P.b3(w);if(m.O()!=j){var l=1-(m.x-W.x),A=1-(m.y-W.y),g=1-(W.x+W.m-(m.x+m.m)),k=1-(W.x+W.n-(m.x+m.n)),$=~~(l*255),C=~~(g*255),f=~~(A*255),z=~~(k*255);
n.fill(f,0,I);n[0]=~~(l*A*255);n[I-1]=~~(g*A*255);for(var L=I;L<j;L+=I){n[L]=$;n[L+I-1]=C}n.fill(z,(U-1)*I,U*I);
n[j-I]=~~(l*k*255);n[j-1]=~~(g*k*255)}return}}var O=Math.ceil(I/s),a=Math.ceil(U/s),X=Math.ceil(I/O),P=Math.ceil(U/a),Z=Date.now();
for(var Y=0;Y<a;Y++)for(var K=0;K<O;K++){var S=K*X,G=Y*P,V=X,T=P,R=E.Om(V,T);if(!E.P.md(w))R.fillRect(0,0,V,T);
E.P.BZ(w,R,-W.x-S,-W.y-G,D);var x=new Uint8Array(R.getImageData(0,0,V,T).data.buffer);if(V==I&&T==U)E.hN(x,n,3);
else E.KB(x,new iB(S,G,V,T),n,new iB(0,0,I,U))}};E.P.a4M=function(w){var n=!1,W=!1,D=0,j=!1;for(var L=0;
L<w.length;L++){var I=w[L].Ht;if(I!=null){D++;if(I==-1)n=!0;if(I==1||I==2||I==3)W=!0;if(w[L].type==0)j=!0}}if(!n&&D<20&&j&&W)w=E.P.JC(w);
return w};E.P.BZ=function(w,n,W,D,j,I){if(j!=null){w=E.P.a4M(w)}for(var L=0;L<w.length;L++){if(w[L].type>5)continue;
var U=w[L].length;if(U==0)continue;if(L==w.length-1)break;var M=w[L].type==3,m=w[L].Ht;if(m!=-1&&j==null){var l=["xor","source-over","destination-out","source-in"][m];
n.globalCompositeOperation=l}if(w[L].Ht!=-1){n.beginPath();if(j){E.P.ZC(j,n)}}E.P.a7Q(n,w,L+1,U,W,D,M);
if(M){}else n.closePath();if(w[L+1+U]==null||w[L+1+U].Ht!=-1){if(j){if(I)n.clip();n.stroke()}else n.fill(m==-1?"nonzero":"evenodd")}L+=U}n.globalCompositeOperation="source-over";
n.setLineDash([])};E.P.ZC=function(w,n,W){if(W==null)W=1;var D=w.strokeStyleLineWidth.v.val*W,j=w.strokeStyleLineAlignment.v.strokeStyleLineAlignment,I=w.strokeStyleLineCapType.v.strokeStyleLineCapType,U=w.strokeStyleLineJoinType.v.strokeStyleLineJoinType,M=w.strokeStyleMiterLimit.v,m=[],l=w.strokeStyleLineDashSet.v;
for(var A=0;A<l.length;A++)m.push(l[A].v.val*D);n.setLineDash(m);n.lineCap=["butt","round","square"][at.QO.EZ.indexOf(I)];
n.lineJoin=["miter","round","bevel"][at.QO.join.indexOf(U)];n.lineWidth=at.QO.n2.indexOf(j)==1?D:D*2;
n.miterLimit=M};E.P.a7Q=function(w,n,L,W,D,j,I){var U=n[L],M=null;w.moveTo(U.H.x+D,U.H.y+j);for(var m=L;
m<L+W-1;m++){U=n[m];M=n[m+1];w.bezierCurveTo(U.mO.x+D,U.mO.y+j,M.T7.x+D,M.T7.y+j,M.H.x+D,M.H.y+j)}if(!I){U=n[m];
M=n[L];w.bezierCurveTo(U.mO.x+D,U.mO.y+j,M.T7.x+D,M.T7.y+j,M.H.x+D,M.H.y+j)}};E.P.a0a=function(w,n){var W=[],D=n?4:1;
for(var L=0;L<w.length;L+=2){var j=new ec(w[L],w[L+1]);W.push({type:D,T7:j.clone(),H:j.clone(),mO:j.clone()})}return W};
E.P.YT=function(w,n,W){var D=E.p.mY(w),j=Math.sqrt(Math.sqrt(D.O()))*.2,I=.2;w=w.slice(0);var U=w.length,M=n?0:2;
for(var m=0;m<5;m++)for(var L=M;L<w.length-M;L+=2){var l=(L-2+U)%U,A=(L+2)%U,g=w[L],k=w[L+1],$=(w[l]+w[A])*.5,C=(w[l+1]+w[A+1])*.5;
w[L]=g+($-g)*I;w[L+1]=k+(C-k)*I}if(W)return E.P.AB.cX(w,null,!n);E.P.rJ();var f=new paper.Path;f.remove();
f.closed=n;for(var L=0;L<w.length;L+=2)f.add(new paper.Point(w[L],w[L+1]));f.simplify(j);var z=[{type:6},{type:8,all:0}];
z=z.concat(E.P.SB(f));return z};E.P.QG=function(w,n,W){var D=w[n].length,j=w[n].type,I=0,U=w.slice(n+1,n+1+D);
for(var L=0;L<D;L++){var M=W[(L-1+D)%D],m=W[(L+1+D)%D],l=W[L];if(l!=0){var A=U[(L-1+D)%D].H,g=U[(L+0+D)%D].H,k=U[(L+1+D)%D].H,$=ec.cS(g,A),C=ec.cS(g,k),f=E.p.eU(A.x,A.y,g.x,g.y,k.x,k.y,l)[0],z=Math.min(f,M==0?$:$/2,m==0?C:C/2);
l*=z/f;var s=E.p.a6a(A.x,A.y,g.x,g.y,k.x,k.y,l),O={type:j+1,T7:new ec(s[2],s[3]),H:new ec(s[2],s[3]),mO:new ec(s[4],s[5])},a={type:j+1,T7:new ec(s[6],s[7]),H:new ec(s[8],s[9]),mO:new ec(s[8],s[9])};
w.splice(n+I+1,1,O,a);I++;w[n].length++}I++}};E.P.q9=function(w){for(var L=0;L<w.length;L++){var n=w[L],W=n.type;
if(W==1||W==2||W==4||W==5)if(!n.H.s9(n.T7)||!n.H.s9(n.mO))return!1}return!0};E.P.tF=function(w){if(w.length!=7||w[2].length!=4||!E.P.q9(w))return!1;
for(var L=0;L<4;L++){var n=!0;for(var W=0;W<4;W++){var D=w[3+(L+W&3)],j=w[3+(L+W+1&3)];if(D.H.x!=j.H.x&&D.H.y!=j.H.y)n=!1}if(n)return!0}return!1};
E.P.azx=function(w){if(w.length<6)return 0;var n=w.length-2,W=0;for(var L=0;L<n;L+=2)W+=(w[L+2]-w[L])*(w[L+1]+w[L+3]);
W+=(w[0]-w[n])*(w[n+1]+w[1]);return-W*.5};E.P.oc=function(w){w=h.Rd.Tv(w);var n=E.P.bB(w);for(var W=0;
W<n;W++){var D=E.P.tt(w,W)+1,j=w[D-1].length,I=[];for(var L=0;L<j;L++){var U=w[D+L].H;I.push(U.x,U.y)}var M=E.P.azx(I);
if(M<0)E.P.a8W(w,D-1)}return w};E.P.a8W=function(w,n){var W=n+1,D=w[n].length,j=[];for(var L=0;L<D;L++){var I=w[W+L],U=I.T7;
I.T7=I.mO;I.mO=U;j.push(I)}for(var L=0;L<D;L++)w[W+L]=j[D-1-L]};E.P.AB={};E.P.AB.cX=function(w,n,W){var D=[{type:6},{type:8,all:0}],j=null;
D.push({type:W?3:0,Ht:1,length:0,_T:0,si:0,S1:1});if(n==0||n==null)j=null;else if(n instanceof Array)j=n;
else{j=[];for(var L=0;L<w.length;L+=2)j.push(n)}D=D.concat(E.P.a0a(w,W));D[2].length=D.length-3;if(j)E.P.QG(D,2,j);
return D};E.P.AB.at5=function(w,n,W,D,j){var I=[],U=[],M=.553,m=1,l=-1;I.push({type:1,T7:new ec(0,M),H:new ec(0,0),mO:new ec(0,-M)});
j+=2;for(var L=0;L<j;L++){var A={type:1};if(L==0){A.H=new ec(1,-1);A.T7=new ec(1-M,-1);A.mO=new ec(1+M,-1)}else{var g=-(L+2)*Math.PI/2,k=1+((L&1)==1?L-1:L),$=Math.sin(g),C=Math.cos(g);
m+=k*($-C);l+=k*(C+$);A.H=new ec(m,l);A.T7=new ec(m+k*C*M,l-k*$*M);if((L&1)==1)k+=2;A.mO=new ec(m-k*C*M,l+k*$*M)}var f={type:1,T7:new ec(-A.mO.x,-A.mO.y),H:new ec(-A.H.x,-A.H.y),mO:new ec(-A.T7.x,-A.T7.y)};
I.push(A);if(L<j-2)U.push(f)}U.reverse();I=I.concat(U);var z=[{type:6},{type:8,all:0}];z.push({type:0,Ht:1,length:I.length,_T:0,si:0,S1:1});
z=z.concat(I);var s=new eh(W/j,0,0,W/j,0,0);s.rotate(D);s.translate(w,n);E.P.c0(z,s);return z};E.P.AB.Rect=function(w,n,W,D,j){var I=[w,n,w+W,n,w+W,n+D,w,n+D];
return E.P.AB.cX(I,j)};E.P.AB.Je=function(w,n,W,D,j,I,U,M){var m=[],l=2*Math.PI/j;for(var L=0;L<j;L++)m.push(Math.cos(L*l-D),Math.sin(L*l-D));
if(U!=null){var A=E.p.mY(m),g=A.m,k=A.n,$=U/(g/2),C=M/(k/2);for(var L=0;L<m.length;L+=2){m[L]=(m[L]-(A.x+g/2))*$;
m[L+1]=(m[L+1]-(A.y+k/2))*C}W=1}var f=new eh(W,0,0,W,0,0);f.translate(w,n);E.p.D(m,f,m);return E.P.AB.cX(m,I)};
E.P.AB.c4=function(w,n,W,D,j,I,U){var M=[],m=Math.PI/j;for(var L=0;L<j*2;L++){var l=(L&1)==0?1:U;M.push(l*Math.cos(L*m),l*Math.sin(L*m))}var A=new eh(W,0,0,W,0,0);
A.rotate(D);A.translate(w,n);E.p.D(M,A,M);return E.P.AB.cX(M,I)};E.P.AB.xK=function(w,n,W,D,j){return E.P.AB.hl(0,w,n,W,D,j)};
E.P.AB.a5s=function(w,n,W,D,j,I){return E.P.AB.hl(1,w,n,W,D,j,I)};E.P.AB.JJ=function(w,n,W,D,j,I){return E.P.AB.hl(2,w,n,W,D,j,I)};
E.P.AB.hl=function(w,n,W,D,j,I,U){var M=Math.sqrt((D-n)*(D-n)+(j-W)*(j-W)),m;I/=2;if(w==0)m=[-I,0,I,0,I,M,-I,M];
if(w==1){var l=I*2*U*1.3/1.5,A=I*U;m=[-I,0,I,0,I,M-l,A,M-l,0,M,-A,M-l,-I,M-l]}if(w==2){var l=U[3],A=U[2]/2,g=l*(2/3)*U[4]/100,k=l-g,$=l;
m=[];if(U[0])m.push(-I,k,-A,$,0,0,A,$,I,k);else m.push(-I,0,I,0);if(U[1])m.push(I,M-k,A,M-$,0,M,-A,M-$,-I,M-k);
else m.push(I,M,-I,M)}var C=new eh(1,0,0,1,0,0);C.rotate(Math.atan2(-j+W,D-n)+Math.PI/2);C.translate(n,W);
E.p.D(m,C,m);return E.P.AB.cX(m,0)};E.P.AB.Po=function(w,n,W,D){var j=[{type:6},{type:8,all:0}],g=.553;
j.push({type:0,Ht:1,length:4,_T:0,si:0,S1:1});var I=w,U=n,M=w+W,m=n+D,w=(I+M)/2,n=(U+m)/2,l=(I-M)/2,A=(U-m)/2;
j.push({type:1,T7:new ec(w-g*l,n-A),H:new ec(w,n-A),mO:new ec(w+g*l,n-A)});j.push({type:1,T7:new ec(w+l,n-g*A),H:new ec(w+l,n),mO:new ec(w+l,n+g*A)});
j.push({type:1,T7:new ec(w+g*l,n+A),H:new ec(w,n+A),mO:new ec(w-g*l,n+A)});j.push({type:1,T7:new ec(w-l,n+g*A),H:new ec(w-l,n),mO:new ec(w-l,n-g*A)});
return j};E.P.AB.a1a=function(w,n,W,D,j){var I=[{type:6},{type:8,all:0}];I.push({type:3,Ht:1,length:5,_T:0,si:0,S1:1});
var U=(j-D)/4;for(var L=0;L<5;L++){var M=L*U,m=Math.cos(M),l=Math.sin(M),A=.553*(U/(Math.PI/2)),g=l*A,k=-m*A,$=new ec(m,l);
I.push({type:4,T7:L==0?$.clone():new ec(m+g,l+k),H:$,mO:L==4?$.clone():new ec(m-g,l-k)})}var C=new eh;
C.rotate(-D);C.scale(W,W);C.translate(w,n);E.P.c0(I,C);return I};E.XB={};E.XB.type={warpNone:[22,5,0],warpCustom:[22,5,16],warpArc:[22,5,1],warpArcLower:[22,5,2],warpArcUpper:[22,5,3],warpArch:[22,5,4],warpBulge:[22,5,5],warpShellLower:[22,5,6],warpShellUpper:[22,5,7],warpFlag:[22,5,8],warpWave:[22,5,9],warpFish:[22,5,10],warpRise:[22,5,11],warpFisheye:[22,5,12],warpInflate:[22,5,13],warpSqueeze:[22,5,14],warpTwist:[22,5,15]};
E.XB.pi=function(w){var n=w.warpStyle.v.warpStyle;if(n=="warpNone")return!0;else if(n=="warpCustom"){var W=!1,D=w.customEnvelopeWarp.v.meshPoints.v.arr,j=D[0].arr,I=D[1].arr;
for(var L=0;L<4;L++)for(var U=0;U<4;U++){if(Math.abs(j[L]-j[U*4+L])>1||Math.abs(I[L*4]-I[L*4+U])>1)W=!0}return!W}else return w.warpValue.v==0&&w.warpPerspective.v==0&&w.warpPerspectiveOther.v==0};
E.XB.Q=function(w){var n={classID:"warp",warpStyle:{t:"enum",v:{warpStyle:"warpNone"}},warpValue:{t:"doub",v:0},warpPerspective:{t:"doub",v:0},warpPerspectiveOther:{t:"doub",v:0},warpRotate:{t:"enum",v:{Ornt:"Hrzn"}}};
if(w){n.bounds={t:"Objc",v:{classID:"Rctn",Top:{t:"UntF",v:{type:"#Pxl",val:w.y}},Left:{t:"UntF",v:{type:"#Pxl",val:w.x}},Btom:{t:"UntF",v:{type:"#Pxl",val:w.y+w.n}},Rght:{t:"UntF",v:{type:"#Pxl",val:w.x+w.m}}}};
n.uOrder={t:"long",v:4};n.vOrder={t:"long",v:4}}return n};E.XB.arm=function(w,n,W,D){for(var L=0;L<w.length;
L+=2){var j=w[L],I=w[L+1],U=(j-n.x)/n.m,M=(I-n.y)/n.n,m=(1-W)/2,l=1-m,A=m+U*(l-m);M=.5+(M-.5)*A*2;var g=(1-D)/2,k=1-g,$=g+M*(k-g);
U=.5+(U-.5)*$*2;j=n.x+U*n.m;I=n.y+M*n.n;w[L]=j;w[L+1]=I}};E.XB.NF=function(w,n){var W=[],D=[];for(var L=0;
L<w.length;L+=2){W.push(w[L]);D.push(w[L+1])}var j=[];j.push({id:"Hrzn",type:"UnFl",uID:"#Pxl",arr:W});
j.push({id:"Vrtc",type:"UnFl",uID:"#Pxl",arr:D});n.warpStyle.v.warpStyle="warpCustom";n.customEnvelopeWarp={t:"Objc",v:{classID:"customEnvelopeWarp",meshPoints:{t:"ObAr",v:{classID:"rationalPoint",arr:j}}}}};
E.XB.BI=function(w,n){if(n==null){var W=w.bounds.v,D=W.Left.v.val,j=W.Rght.v.val,I=W.Top.v.val,U=W.Btom.v.val;
if(D==null){D=W.Left.v,j=W.Rght.v;I=W.Top.v,U=W.Btom.v}n=new iB(D,I,j-D,U-I)}if(n.VY())n.m=n.n=1;var M=[],m=w.warpStyle.v.warpStyle;
if(m=="warpCustom"){var l=w.customEnvelopeWarp.v.meshPoints.v.arr,A=l[0].arr,g=l[1].arr;for(var L=0;
L<16;L++)M.push(A[L],g[L])}else M=E.XB.XB(n,m,w.warpRotate.v.Ornt=="Hrzn",w.warpValue.v/100,w.warpPerspective.v/100,w.warpPerspectiveOther.v/100);
return M};E.XB.XB=function(w,n,W,D,j,I){var U=E.xv.Q(w.x,w.y,w.m,w.n);if(n=="warpNone")return U;var M=JSON.parse(JSON.stringify(w)),m=new eh;
if(!W){m.translate(-w.x,-w.y);m.rotate(-Math.PI/2);m.translate(w.n,0);E.p.D(U,m,U);w=new iB(0,0,w.n,w.m);
U=E.xv.vm(U,!1)}E.XB.akl(U,w,n,D,j,I);if(!W){U=E.xv.vm(U,!0);w=M;m.Ba();E.p.D(U,m,U)}if(D==0)E.XB.arm(U,w,j,I);
else{var m=new eh(1/w.m,0,0,1/w.n,-w.x,-w.y);m.translate(-.5,-.5);E.p.D(U,m,U);E.XB.atp(U,I,j);m.Ba();
E.p.D(U,m,U)}return U};E.XB.akl=function(w,n,W,D,j,I){for(var L=0;L<4;L++){for(var U=0;U<4;U++){var M=2*(4*L+U),m=w[M]-n.x,l=w[M+1]-n.y,A=m,g=l;
if(D!=0){var k=n.m/2,$=n.n/2;A-=k;g-=$;var C=A,f=A,z=-$,s=$,O=Math.abs(D),a=Math.tan((1-O)*Math.PI/2),X=Math.sqrt(a*a+1),P=Math.atan2(1,a),Z=A/k*P,Y=k*X,K=k*X+n.n,S=Math.cos(P),G=Math.sin(P),V=E.XB.aph(S,G),T=E.XB.ade(S,G),R=-a*k+V*Y;
if(W=="warpArc"){C=Math.sin(Z)*K;z=a*k-Math.cos(P)*K+$;f=Math.sin(Z)*Y;s=a*k-Math.cos(P)*Y+$;if(U==1||U==2){C=U==1?-T*K:T*K;
f=U==1?-T*Y:T*Y;z=a*k+$-V*K;s=a*k+$-V*Y}if(D<0){var x=C;C=f;f=x;x=z;z=-s;s=-x}}if(W=="warpArcLower"){if(U==1||U==2){f=U==1?-T*Y:T*Y;
s=D<0?$-R:$+R}}if(W=="warpArcUpper"||W=="warpArch"||W=="warpBulge"){if(U==1||U==2){C=U==1?-T*Y:T*Y;z=D<0?-$+R:-$-R}if(W=="warpArch"){f=C;
s=z+2*$}if(W=="warpBulge"){f=C;s=-z}}if(W=="warpFish"||W=="warpFlag"||W=="warpWave"){var v=U;if(W=="warpFlag")v=3-U;
if(v==1){z-=D*4*$;s+=D*4*$}if(v==2){z+=D*4*$;s-=D*4*$}if(W=="warpFlag"||W=="warpWave")z=s-2*$}if(W=="warpRise"){if(U<2)z=-$+D*$*4;
s=z+2*$}var N=(g+$)/n.n;A=C+N*(f-C);g=z+N*(s-z);if(W=="warpWave"){if(L==0)g=-$;if(L==3)g=$;if(L==1||L==2)g=2*$*(L/3-.5)*(1/3)+g*(2/3)}if(W=="warpFisheye"){if((L==1||L==2)&&(U==1||U==2)){A=A+4*A*D;
g=g+4*g*D}}if(W=="warpInflate"){var u=2/3;if((L==1||L==2)&&(U==1||U==2)){A=A+.5*A*D;g=g+.5*g*D}else if(L==1||L==2)A=A+u*A*D;
else if(U==1||U==2)g=g+u*g*D}if(W=="warpSqueeze"){var u=2/3;if((L==1||L==2)&&(U==1||U==2)){if(D>0)A=A-u*A*D;
else g=g+u*g*D}else if(L==1||L==2)A=A-u*A*D;else if(U==1||U==2)g=g+u*g*D}if(W=="warpTwist"){if((L==1||L==2)&&(U==1||U==2)){var H=D*Math.PI/2,X=1+Math.abs(D)*2,F=A*Math.cos(H)-g*Math.sin(H),t=A*Math.sin(H)+g*Math.cos(H);
A=F*X;g=t*X}}if(W=="warpShellLower"||W=="warpShellUpper"){if(W=="warpShellUpper"){L=3-L;g=-g}if(L>2||L==2&&(U==0||U==3)){if(D>0){var o=Y+L/3*2*$;
A=Math.sin(Z)*o;g=-a*k-$+Math.cos(Z)*o;if(U==1||U==2){A=U==1?-T*o:T*o;g=-a*k-$+V*o}}else{if((U==1||U==2)&&L==3){A=U==1?-T*Y:T*Y;
g=a*k-V*Y+$}else if(L==2){g=$-$*(2/3)*Math.cos(Z);A=A+$*(2/3)*Math.sin(Z)}}}if(W=="warpShellUpper"){L=3-L;
g=-g}}A+=k;g+=$}m=A,l=g;w[M]=m+n.x;w[M+1]=l+n.y}}};E.XB.atp=function(w,n,W){var D=[];for(var j=0;j<4;
j++)D.push(1-W+j/3*2*W);var I=[];for(var j=0;j<4;j++)I.push(1-n+j/3*2*n);var U=[0,0,0,0],M=[0,0,0,0];
for(var L=0;L<4;L++)for(var j=0;j<4;j++){var m=2*(4*L+j),l=w[m],A=w[m+1];U[j]+=l/4;M[j]+=A/4}for(var L=0;
L<4;L++)for(var j=0;j<4;j++){var g=D[j],m=2*(4*L+j),l=w[m],A=w[m+1],k=U[j],$=M[j];w[m]=k+g*(l-k);w[m+1]=$+g*(A-$)}var C=w.slice(0);
for(var L=0;L<4;L++)for(var j=1;j<3;j++){var m=2*(4*L+j),l=w[m],A=w[m+1],f=m+(j==1?-2:2),z=w[f],s=w[f+1];
w[m]=l-z;w[m+1]=A-s}var O=w[0],a=w[1],X=w[8],P=w[9],Z=w[16],Y=w[17],K=w[24],S=w[25],G=w[6],V=w[7],T=w[14],R=w[15],x=w[22],v=w[23],N=w[30],u=w[31],H=G-O,F=V-a,t=T-X,o=R-P,q=x-Z,_=v-Y,d=N-K,r=u-S;
for(var L=0;L<4;L++){var p=2*L*4,Q=0,B=0,i=L==1?.33:.66,c=1-i;if(L==0){Q=H;B=F}if(L==1){Q=c*H+i*-d;B=c*F+i*-r}if(L==2){Q=c*H+i*-d;
B=c*F+i*-r}if(L==3){Q=-d;B=-r}w[p]=w[p]+Q/2;w[p+1]=w[p+1]+B/2;w[p+6]=w[p+6]-Q/2;w[p+7]=w[p+7]-B/2}for(var L=0;
L<4;L++)for(var j=1;j<3;j++){var m=2*(4*L+j),l=w[m],A=w[m+1],f=m+(j==1?-2:2),z=w[f],s=w[f+1],g=2*L/3;
w[m]=z+g*l;w[m+1]=s+g*A}for(var L=1;L<3;L++)for(var j=1;j<3;j++){var m=2*(4*L+j),l=w[m],A=w[m+1],h2=L==1?-8:-16,jX=L==1?16:8,bm=w[m+h2],dC=w[m+h2+1],fn=w[m+jX],fK=w[m+jX+1],g=L/3;
l=(1-g)*bm+g*fn;A=(1-g)*dC+g*fK;w[m]=l;w[m+1]=A}E.p.gp(C,w,w,n)};E.XB.aph=function(w,n){return(4-w)*(1/3)};
E.XB.ade=function(w,n){return(1-w)*(3-w)/(3*n)};E.dU={};E.dU.aih=function(w,n,W,D,j,I,U,M,m,l){for(var A=0;
A<M;A++)for(var g=0;g<U;g++){var k=3*(A*U+g),$=A+I,C=g+j,f=w[$*n+C];D[k]=f;D[k+1]=f;D[k+2]=f}};E.dU.pQ=function(w,n,W,D,j,I,U,M,m,l){var A=[0,1,1/2,1/3,1/4,1/5,1/6,1/7,1/8,1/9],g=1/m,k=[-1,-1,0,-1,1,-1,-1,0,1,0,-1,1,0,1,1,1],$=new Uint32Array(6);
for(var C=0;C<M;C++){for(var f=0;f<U;f++){var z=3*(C*U+f),s=C+I,O=f+j;$[0]=0;$[1]=0;$[2]=0;$[3]=0;$[4]=0;
$[5]=0;for(var L=0;L<16;L+=2){var a=O+k[L],X=s+k[L+1],P=a-m*~~(a*g),Z=X-m*~~(X*g),Y=l[Z*m+P];$[Y]+=w[X*n+a];
$[Y+3]++}var a=O,X=s,P=a-m*~~(a*g),Z=X-m*~~(X*g),Y=l[Z*m+P];$[Y]=w[s*n+O];$[Y+3]=1;D[z]=$[0]*A[$[3]];
D[z+1]=$[1]*A[$[4]];D[z+2]=$[2]*A[$[5]]}}};E.dU.Jq=function(w,n,W){for(var L=0;L<W;L+=2)w[n+L]=w[n+L+1];
n=n+W;for(var L=0;L<W;L+=2)w[n+L+1]=w[n+L]};E.dU.X4=function(w,n,W,D){for(var L=0;L<D;L+=2){var j=n+L*W;
w[j]=w[j+W];w[j+W+1]=w[j+1]}};E.dU.d_=function(w,n,W,D,j,I){var U=D[j],M=D[j+1],m=D[I],l=D[I+1],A=M+m>>>1;
w[n]=w[n+3]=w[W]=w[W+3]=U;w[n+1]=A;w[n+4]=M;w[W+1]=m;w[W+4]=A;w[n+2]=w[n+5]=w[W+2]=w[W+5]=l};E.dU.a0F=function(w,n,W,D,j,I){var U=I*3;
for(var L=0;L<I;L+=2){var M=n+L,m=j+L*3;E.dU.d_(D,m,m+U,w,M,M+W)}};E.dU.a7j=function(w,n,W,D,j,I,U){var M=I*3;
for(var L=0;L<U;L+=2){var m=n+L*W,l=j+L*I*3;E.dU.d_(D,l,l+M,w,m,m+W)}};E.dU.jR=function(w,L,n){var W=w[L-n-n],D=w[L-n],j=w[L-2],I=w[L-1],U=w[L],M=w[L+1],m=w[L+2],l=w[L+n],A=w[L+n+n],g=Math.abs(D-l),k=Math.abs(I-M),$=Math.abs(U-W)*2+g,C=Math.abs(U-m)*2+k,f=Math.abs(U-j)*2+k,z=Math.abs(U-A)*2+g,s=Math.min($,Math.min(C,Math.min(f,z)));
if(s==$)return D*3+l+U-W>>2;if(s==C)return M*3+I+U-m>>2;if(s==f)return I*3+M+U-j>>2;return l*3+D+U-A>>2};
E.dU.YF=function(w,n,W,D,j){if(w<n&&n<W||w>n&&n>W)return~~(.5+D+(j-D)*(n-w)/(W-w));else return(D+j>>1)+(n+n-w-W>>2)};
E.dU.bt=function(w,n,L,W){var D=n[L-W-1],j=n[L-W+1],I=n[L],U=n[L+W-1],M=n[L+W+1],m=w[L-W-1],l=w[L-W+1],A=w[L],g=w[L+W-1],k=w[L+W+1],$=Math.abs(l-g)+Math.abs(w[L-W-W+2]-A)+Math.abs(A-w[L+W+W-2])+Math.abs(j-I)+Math.abs(I-U),C=Math.abs(m-k)+Math.abs(w[L-W-W-2]-A)+Math.abs(A-w[L+W+W+2])+Math.abs(D-I)+Math.abs(I-M);
if($<C)return E.dU.YF(j,I,U,l,g);else return E.dU.YF(D,I,M,m,k)};E.dU.TE=function(w,n,W,D,j,I){w[n+0]=W[j];
w[n+1]=D[j];w[n+2]=E.dU.bt(W,D,j,I)};E.dU.dR=function(w,n,W,D,j,I){var U=D[j];w[n+0]=E.dU.YF(D[j-1],U,D[j+1],W[j-1],W[j+1]);
w[n+1]=U;w[n+2]=E.dU.YF(D[j-I],U,D[j+I],W[j-I],W[j+I])};E.dU.M8=function(w,n,W,D,j,I){var U=D[j];w[n+0]=E.dU.YF(D[j-I],U,D[j+I],W[j-I],W[j+I]);
w[n+1]=U;w[n+2]=E.dU.YF(D[j-1],U,D[j+1],W[j-1],W[j+1])};E.dU.iB=function(w,n,W,D,j,I){w[n+0]=E.dU.bt(W,D,j,I);
w[n+1]=D[j];w[n+2]=W[j]};E.dU.aoR=function(w,n,W,D,j,I,U,M,m){var l=Date.now(),A=2,g=n-2,k=2;if((j&1)==1){A++;
g--}var $=W-2;if((I&1)==1){k++;$--}if(m==1||m==3){A++;g--}var C=w.slice(0);E.dU.Jq(C,0,n);E.dU.X4(C,0,n,W);
E.dU.X4(C,n-2,n,W);E.dU.Jq(C,(W-2)*n,n);for(var f=k;f<$;f+=2)for(var z=A;z<g;z+=2){var L=f*n+z,s=E.dU.jR(C,L,n),O=E.dU.jR(C,L+n+1,n);
C[L]=Math.max(0,s);C[L+n+1]=Math.max(0,O)}var a=U,X=M;if(I+M==W){X-=2;E.dU.a0F(w,(W-2)*n+j,n,D,(M-2)*U*3,U)}if(j+U==n){a-=2;
E.dU.a7j(w,I*n+j+U-2,n,D,(U-2)*3,U,M)}if(m==0)for(var f=0;f<X;f+=2)for(var z=0;z<a;z+=2){var P=(f+I)*n+z+j,Z=(f*U+z)*3;
E.dU.TE(D,Z,w,C,P,n);E.dU.dR(D,Z+3,w,C,P+1,n);P+=n;Z+=3*U;E.dU.M8(D,Z,w,C,P,n);E.dU.iB(D,Z+3,w,C,P+1,n)}else if(m==1)for(var f=0;
f<X;f+=2)for(var z=0;z<a;z+=2){var P=(f+I)*n+z+j,Z=(f*U+z)*3;E.dU.dR(D,Z,w,C,P,n);E.dU.TE(D,Z+3,w,C,P+1,n);
P+=n;Z+=3*U;E.dU.iB(D,Z,w,C,P,n);E.dU.M8(D,Z+3,w,C,P+1,n)}else if(m==2)for(var f=0;f<X;f+=2)for(var z=0;
z<a;z+=2){var P=(f+I)*n+z+j,Z=(f*U+z)*3;E.dU.iB(D,Z,w,C,P,n);E.dU.M8(D,Z+3,w,C,P+1,n);P+=n;Z+=3*U;E.dU.dR(D,Z,w,C,P,n);
E.dU.TE(D,Z+3,w,C,P+1,n)}else if(m==3)for(var f=0;f<X;f+=2)for(var z=0;z<a;z+=2){var P=(f+I)*n+z+j,Z=(f*U+z)*3;
E.dU.M8(D,Z,w,C,P,n);E.dU.iB(D,Z+3,w,C,P+1,n);P+=n;Z+=3*U;E.dU.TE(D,Z,w,C,P,n);E.dU.dR(D,Z+3,w,C,P+1,n)}};
E.raw={};E.raw.awc=function(w){var n=Date.now(),W=w.width,D=w.height,j=0,I=0,U=W,M=D;if(w.t50829){var m=w.t50829;
j=m[1];I=m[0];U=m[3];M=m[2]}if(w.t50720&&w.t50720[0]*1.2>W){if(w.t50719){var l=w.t50719;j+=l[0]>>1<<1;
I+=l[1]>>1<<1}if(w.t50720){var A=w.t50720;U=j+A[0];M=I+A[1]}}var g=U-j,k=M-I,$=E.raw.alr(w),C=w.t33422,f=w.t33421;
if(f){var A=f[0],z=C.slice(0);for(var s=0;s<A;s++)for(var O=0;O<A;O++){var a=(O+(j&1))%A,X=(s+(I&1))%A;
z[s*A+O]=C[X*A+a]}C=z}if(w.t277[0]==1&&C)E.raw.avY($,W,D,w,C);E.raw.Sy(2,w,$,W,D);var P=new Float32Array(g*k*3);
if(w.t277[0]==1){if(f==null){E.dU.aih($,W,D,P,j,I,g,k)}else if(f.length!=2||f[0]!=2||f[1]!=2){console.log("Unknown CFA pattern size",f);
E.dU.pQ($,W,D,P,j,I,g,k,f[0],C)}else{var Z=w.t33422.join(","),Y=0;if(Z=="0,1,1,2")Y=0;else if(Z=="1,0,2,1")Y=1;
else if(Z=="2,1,1,0")Y=2;else if(Z=="1,2,0,1")Y=3;else throw"Unknown CFA pattern "+Z;if((g&1)!=0||(k&1)!=0)throw"e";
E.dU.aoR($,W,D,P,j,I,g,k,Y)}}else{for(var s=0;s<k;s++)for(var O=0;O<g;O++){var K=((s+I)*W+O+j)*3,S=(s*g+O)*3;
P[S+0]=$[K+0];P[S+1]=$[K+1];P[S+2]=$[K+2]}}var G=P,V=P.length,T=E.raw.sn(w),R=1/T;for(var L=0;L<V;L+=3){P[L]=G[L]*R;
P[L+1]=G[L+1]*R;P[L+2]=G[L+2]*R}E.raw.Sy(3,w,P,g,k);var x=w.jy,v=g,N=k;if(x==1||x==9){}else{var u=E.raw.IE(x,g,k),S=0;
v=u[0];N=u[1];var H=P.slice(0);for(var s=0;s<N;s++)for(var O=0;O<v;O++){var F=u[2]*O+u[3]*s+u[4],t=u[5]*O+u[6]*s+u[7],K=(t*g+F)*3;
P[S]=H[K];P[S+1]=H[K+1];P[S+2]=H[K+2];S+=3}}return{Q0:P,kT:v,qV:N}};E.raw.IE=function(w,n,W){var D=n,j=W;
if(!1){}else if(w==2)return[n,W,-1,0,n-1,0,1,0];else if(w==3)return[n,W,-1,0,n-1,0,-1,W-1];else if(w==4)return[n,W,1,0,0,0,-1,W-1];
else if(w==5)return[W,n,0,1,0,1,0,0];else if(w==6)return[W,n,0,1,0,-1,0,W-1];else if(w==7)return[W,n,0,-1,n-1,-1,0,W-1];
else if(w==8)return[W,n,0,-1,n-1,1,0,0];else throw"unknown orientation "+w};E.raw.avY=function(w,n,W,D,j){var I=Date.now(),R=0,N=0;
if(E.raw.sn(D)>4e4){for(var L=0;L<w.length;L++)w[L]>>=1;var U=["t50714","t50715","t50712","t50717"];
for(var L=0;L<U.length;L++){var M=D[U[L]];if(M)for(var m=0;m<M.length;m++)M[m]>>>=1}console.log("remapping to lower bit depth")}var l=~~Math.sqrt(j.length),A=[-1,-1,0,-1,0,1,-1,0,0,0,1,0,-1,1,0,1,1,1],g=[];
for(var k=0;k<l;k++)for(var $=0;$<l;$++){var L=k*l+$,C=j[L],f=4,z=4,s=8,O=0,a=0;for(var m=0;m<18;m+=2){var X=(l+$+A[m])%l,P=(l+k+A[m+1])%l,Z=j[P*l+X];
if(Z==C){}else if(f==4){f=Z;O=m}else if(z==4&&Z!=f){z=Z;a=m;break}}if(z<f){var Y=z;z=f;f=Y;Y=a;a=O;O=Y}if(f<C){var Y=f;
f=C;C=Y;Y=O;O=s;s=Y}if(z<f){var Y=z;z=f;f=Y;Y=a;a=O;O=Y}g[L*3]=A[s+1]*n+A[s];g[L*3+1]=A[O+1]*n+A[O];
g[L*3+2]=A[a+1]*n+A[a]}var K=~~(.996*E.raw.sn(D)),S=~~(.992*E.raw.sn(D)),G=D.t50728;if(G==null||G[0]==0)G=[1,1,1];
var V=[],T=[0,0,0];for(var k=1;k<W-1;k++)for(var $=1;$<n-1;$++){var L=k*n+$,x=k%l*l+$%l,C=w[L+g[x*3+0]],f=w[L+g[x*3+1]],z=w[L+g[x*3+2]],v=Math.max(C,f,z);
if(v>K)V.push(L);else if(v>S){T[0]+=C;T[1]+=f;T[2]+=z;R++}}if(V.length==0)return;if(R/(n*W)<1e-5){console.log("not enough semi-saturated pixels",R);
T=G}if(T[1]<T[N])N=1;if(T[2]<T[N])N=2;var u=[T[0]/T[N],T[1]/T[N],T[2]/T[N]],H=w.slice(0);for(var F=0;
F<V.length;F++){var L=V[F],k=~~(L/n),$=L-k*n,x=k%l*l+$%l,t=Math.min(65535,~~(w[L+g[x*3+N]]*u[j[x]]));
if(t>H[L])H[L]=t}w.set(H)};E.raw.N9=function(w,n,W,D){var j=Math.round(w.length/3),I=dS.s4(D[0],D[1]),U=E.raw.aj5(W,I),M=E.Mv.multiply(E.Mv.WE,U),m=Math.pow(2,W.t50730?W.t50730[0]:0);
M=E.Mv.multiply(M,E.Mv.Os(m,m,m));var l=E.raw.N9.aeF;if(l==null){l=E.raw.N9.aeF=new Float64Array(8e3);
for(var L=0;L<8e3;L++)l[L]=E.ae(L*(1/1e3))}for(var L=0;L<j;L++){var A=L<<2,g=A-L,k=w[g],$=w[g+1],C=w[g+2],f=M[0]*k+M[1]*$+M[2]*C,z=M[4]*k+M[5]*$+M[6]*C,s=M[8]*k+M[9]*$+M[10]*C;
if(f<0)f=0;if(z<0)z=0;if(s<0)s=0;n[g]=l[~~(f*1e3)];n[g+1]=l[~~(z*1e3)];n[g+2]=l[~~(s*1e3)]}};E.raw.alr=function(w){var n=w.width,W=w.height,D=n*W*w.t277,j=new Uint16Array(D),I=null,U=0;
E.raw.aoK(w,j);E.raw.Sy(1,w,j,n,W);if(w.t50712){I=w.t50712;U=I.length-1;if(I[U]>65535)throw"too big values"}var M=E.raw.yy(w),m=E.raw.Kz(w);
if(I==null)for(var L=0;L<D;L++)j[L]=Math.max(0,j[L]-M);else for(var L=0;L<D;L++){var l=j[L];if(l>U)l=U;
l=I[l];j[L]=Math.max(0,l-M)}return j};E.raw.yy=function(w){var n=w.t50714,W=n?n[0]:0,D=w.t50715,j=w.t50716;
if(D)W+=D[0][0]/D[0][1];if(j)W+=j[0][0]/j[0][1];return Math.round(W)};E.raw.Kz=function(w){var n=null,W=0;
if(w.t50712){n=w.t50712;W=n.length-1}var D=w.t50717?w.t50717[0]:(1<<w.t258[0])-1;if(n)D=Math.min(D,n[W]);
return D};E.raw.sn=function(w){var n=E.raw.yy(w),W=E.raw.Kz(w);return W-n};E.raw.aoK=function(w,n){var W=n.length,D=w.data,j=w.t258[0];
if(j!=16&&j!=14&&j!=12&&j!=10&&j!=8)throw"Unsupported Bits Per Sample:"+j;j=Math.round(D.length*8/W);
if(j==16&&w.isLE){E.nX(D,n);return}for(var L=0;L<W;L+=2){var I=0,U=0,M=0;if(j==16){I=L<<1;U=D[I]<<8|D[I+1];
M=D[I+2]<<8|D[I+3]}else if(j==14){var m=L*14,l=m>>>3,A=D[l]<<24|D[l+1]<<16|D[l+2]<<8|D[l+3];if((m&7)==0){U=A>>>18;
M=A>>>4&16383}else{U=A>>>14&16383;M=A&16383}}else if(j==12){I=L+(L>>>1);U=D[I]<<4|D[I+1]>>4;M=(D[I+1]&15)<<8|D[I+2]}else if(j==10){var m=L*10,l=m>>>3;
if((m&7)==0){U=(D[l]<<2|D[l+1]>>6)&1023;M=(D[l+1]<<4|D[l+2]>>4)&1023}else{U=(D[l]<<6|D[l+1]>>2)&1023;
M=(D[l+1]<<8|D[l+2]>>0)&1023}}else if(j==8){I=L;U=D[I];M=D[I+1]}n[L]=U;n[L+1]=M}};E.raw.avy=function(w,n,W,D,j,I,U){var M=w-.499999,m=n-.499999,l=~~M,A=~~m,g=M-l,k=m-A,$=(1-k)*(1-g),C=(1-k)*g,f=k*(1-g),z=k*g,s=(A*D+l)*3,O=((A+1)*D+l)*3,a=$*W[s]+C*W[s+3]+f*W[O]+z*W[O+3],X=$*W[s+1]+C*W[s+4]+f*W[O+1]+z*W[O+4],P=$*W[s+2]+C*W[s+5]+f*W[O+2]+z*W[O+5];
I[U]=a;I[U+1]=X;I[U+2]=P};E.raw.Sy=function(w,n,W,D,j){var I=n["t"+[51008,51009,51022][w-1]],A=0;if(I==null)return;
var U=D*j,M=J.q,m=J.Gb,l=new Uint8Array(I),b3=J.q(l,A);A+=4;for(var g=0;g<b3;g++){var k=M(l,A);A+=4;
var $=M(l,A);A+=4;var C=M(l,A);A+=4;var f=M(l,A);A+=4;if(!1){}else if(k==1&&w==3){var z=A,s=M(l,z);z+=4;
var O=m(l,z);z+=8;var a=m(l,z);z+=8;var X=m(l,z);z+=8;var P=m(l,z);z+=8;var Z=m(l,z);z+=8;var Y=m(l,z);
z+=8;z+=(s-1)*8*6;var K=m(l,z);z+=8;var S=m(l,z);z+=8;var G=K*D,V=S*j,T=Math.max(G,D-G),R=Math.max(V,j-V),x=Math.sqrt(T*T+R*R),v=1/x,N=W.slice(0);
for(var u=0;u<j;u++)for(var H=0;H<D;H++){var F=(H+.5-G)*v,t=(u+.5-V)*v,o=F*F+t*t,q=O+a*o+X*(o*o)+P*(o*o)*o,_=Z*(2*F*t)+Y*(o+2*F*F),d=Y*(2*F*t)+Z*(o+2*t*t),r=Math.min(G+x*(q*F+_),D-1),p=Math.min(V+x*(q*t+d),j-1),Q=(u*D+H)*3;
E.raw.avy(r,p,N,D,j,W,Q)}}else if(k==3&&w==3){var z=A,B=m(l,z);z+=8;var i=m(l,z);z+=8;var c=m(l,z);z+=8;
var h2=m(l,z);z+=8;var jX=m(l,z);z+=8;var K=m(l,z);z+=8;var S=m(l,z);z+=8;var G=K*D,V=S*j,T=Math.max(G,D-G),R=Math.max(V,j-V),x=Math.sqrt(T*T+R*R),v=1/x;
for(var u=0;u<j;u++)for(var H=0;H<D;H++){var F=(H+.5-G)*v,t=(u+.5-V)*v,o=F*F+t*t,bm=1+(B+(i+(c+(h2+jX*o)*o)*o)*o)*o,Q=(u*D+H)*3;
W[Q]=bm*W[Q];W[Q+1]=bm*W[Q+1];W[Q+2]=bm*W[Q+2]}}else if(k==4&&w==1){var z=A,dC=M(l,z);z+=4;var fn=M(l,z);
z+=4;for(var L=0;L<U;L++)if(W[L]==dC)W[L]=W[L-2]+W[L+2]>>1}else if(k==5&&w==1){var z=A,fK=M(l,z);z+=4;
var i6=M(l,z);z+=4;var dh=M(l,z);z+=4;for(var L=0;L<i6;L++){var kA=M(l,z);z+=4;var ig=M(l,z);z+=4;var L=kA*D+ig;
W[L]=W[L-2]+W[L+2]>>1}}else if(k==7&&w==1){var z=A,iJ=J._I(l,z);z+=16;var fL=M(l,z);z+=4;var fB=M(l,z);
z+=4;var ah=M(l,z),eS=M(l,z+4);z+=8;var gL=M(l,z);z+=4;var e_=new Uint16Array(gL);for(var L=0;L<gL;L++)e_[L]=J.IQ(l,z+2*L);
var c2=iJ.m,jS=iJ.n;for(var u=0;u<jS;u+=ah)for(var H=0;H<c2;H+=eS){var L=(iJ.y+u)*D+(iJ.x+H);W[L]=e_[W[L]]}}else if(k==8&&w==2){var z=A,iJ=J._I(l,z);
z+=16;var fL=M(l,z);z+=4;var fB=M(l,z);z+=4;var ah=M(l,z),eS=M(l,z+4);z+=8;var ie=M(l,z);z+=4;var as=[];
for(var L=0;L<=ie;L++)as[L]=J.Gb(l,z+L*8);var gb=iJ.x,gx=iJ.x+iJ.m,eo=iJ.y,di=iJ.y+iJ.n,d0=n.t50717[0],e6=1/d0;
for(var dt=0;dt<fB;dt++)for(var u=eo;u<di;u+=ah){var Q=3*u*D+fL+dt;for(var H=gb;H<gx;H+=eS){var L=Q+3*H,gJ=W[L]*e6,iW=as[ie];
for(var g5=ie;g5>0;g5--)iW=iW*gJ+as[g5-1];W[L]=Math.max(0,Math.min(65535,~~(iW*d0)))}}}else if(k==9&&w==2){var z=A,iJ=J._I(l,z),cB=!0;
z+=16;var fL=M(l,z);z+=4;var fB=M(l,z);z+=4;var ah=M(l,z),eS=M(l,z+4);z+=8;var jW=M(l,z),eP=M(l,z+4);
z+=8;var b_=m(l,z),fZ=m(l,z+8);z+=16;var im=m(l,z),j3=m(l,z+8);z+=16;var dr=M(l,z);z+=4;if(dr!=1)throw"more than one map plane";
var c0=jW*eP,fM=new Float32Array(c0);for(var g5=0;g5<c0;g5++)fM[g5]=J.F_(l,z+g5*4);for(var g5=0;g5<c0;
g5++)if(fM[g5]!=1)cB=!1;if(!cB){var c2=iJ.m,jS=iJ.n,iI=.9999*(eP-1)/c2,jD=.9999*(jW-1)/jS;for(var u=0;
u<jS;u+=ah)for(var H=0;H<c2;H+=eS){var L=(iJ.y+u)*D+(iJ.x+H),j8=H*iI,jG=u*jD,i1=Math.floor(j8),bH=Math.floor(jG),a_=j8-i1,aR=jG-bH,Q=bH*eP+i1,iY=fM[Q]*(1-a_)+fM[Q+1]*a_,gy=fM[Q+eP]*(1-a_)+fM[Q+1+eP]*a_,gr=iY*(1-aR)+gy*aR;
W[L]=Math.max(0,Math.min(65535,~~(W[L]*gr+.5)))}}}else console.log("Unknown opcode "+k+" in OpcodeList"+w+". Length: "+f);
A+=f}};E.raw.aj5=function(w,n){var W=dS.vz(n),D=E.raw.V1(w,n),j=E.Mv.Ba(D),I=dS.Lg(W,dS.vz(dS.awY)),U=E.Mv.multiply(I,j);
return U};E.raw.a66=function(w){var n=w.t50728,j=1;if(n==null||n[0]==0)n=[1,1,1];var W=n.slice(0);W.push(0);
var D={x:.34567,y:.3585};do{var I=E.Mv.Ba(E.raw.V1(w,D)),U=E.Mv.q4(I,W),M=dS.abz(U);j=Math.abs(D.x-M.x)+Math.abs(D.y-M.y);
D=M}while(j>1e-7);return D};E.raw.V1=function(w,n){var W=dS.t6(n),D=E.raw.alR,j=w.t50778?w.t50778[0]:0,I=w.t50779?w.t50779[0]:0,U=w.t50723,M=w.t50724;
if(U&&U.length==3)U=null;if(M&&M.length==3)M=null;var m=D(w.t50721,w.t50722,j,I,W.iP),l=D(U,M,j,I,W.iP);
m=m||[1,0,0,0,1,0,0,0,1];l=l||[1,0,0,0,1,0,0,0,1];var A=w.t50727?[w.t50727[0],0,0,0,w.t50727[1],0,0,0,w.t50727[2]]:[1,0,0,0,1,0,0,0,1];
return E.Mv.multiply(E.Mv.Vr(A),E.Mv.multiply(E.Mv.Vr(l),E.Mv.Vr(m)))};E.raw.alR=function(w,n,W,D,j){if(!w&&!n){return null}else if(w&&!n){return w}else if(j<W){return w}else if(j>D){return n}else{var I=(1/j-1/D)/(1/W-1/D),U=1-I,M=[];
for(var L=0;L<9;L++)M[L]=w[L]*I+n[L]*U;return M}};var dS={};dS.awY={x:.34567,y:.3585};dS.u2=[{o:0,WK:.18006,jB:.26352,ib:-.24341},{o:10,WK:.18066,jB:.26589,ib:-.25479},{o:20,WK:.18133,jB:.26846,ib:-.26876},{o:30,WK:.18208,jB:.27119,ib:-.28539},{o:40,WK:.18293,jB:.27407,ib:-.3047},{o:50,WK:.18388,jB:.27709,ib:-.32675},{o:60,WK:.18494,jB:.28021,ib:-.35156},{o:70,WK:.18611,jB:.28342,ib:-.37915},{o:80,WK:.1874,jB:.28668,ib:-.40955},{o:90,WK:.1888,jB:.28997,ib:-.44278},{o:100,WK:.19032,jB:.29326,ib:-.47888},{o:125,WK:.19462,jB:.30141,ib:-.58204},{o:150,WK:.19962,jB:.30921,ib:-.70471},{o:175,WK:.20525,jB:.31647,ib:-.84901},{o:200,WK:.21142,jB:.32312,ib:-1.0182},{o:225,WK:.21807,jB:.32909,ib:-1.2168},{o:250,WK:.22511,jB:.33439,ib:-1.4512},{o:275,WK:.23247,jB:.33904,ib:-1.7298},{o:300,WK:.2401,jB:.34308,ib:-2.0637},{o:325,WK:.24792,jB:.34655,ib:-2.4681},{o:350,WK:.25591,jB:.34951,ib:-2.9641},{o:375,WK:.264,jB:.352,ib:-3.5814},{o:400,WK:.27218,jB:.35407,ib:-4.3633},{o:425,WK:.28039,jB:.35577,ib:-5.3762},{o:450,WK:.28863,jB:.35714,ib:-6.7262},{o:475,WK:.29685,jB:.35823,ib:-8.5955},{o:500,WK:.30505,jB:.35907,ib:-11.324},{o:525,WK:.3132,jB:.35968,ib:-15.628},{o:550,WK:.32129,jB:.36011,ib:-23.325},{o:575,WK:.32931,jB:.36038,ib:-40.77},{o:600,WK:.33724,jB:.36051,ib:-116.45}];
dS.t6=function(w){var n=dS.u2,W=2*w.x/(1.5-w.x+6*w.y),D=3*w.y/(1.5-w.x+6*w.y),j=0,I=0,U=0;for(;U<31;
U++){j=D-n[U].jB-n[U].ib*(W-n[U].WK);if(U>0&&j<0){break}I=j}while(U>=n.length)U--;j/=Math.sqrt(1+n[U].ib*n[U].ib);
I/=Math.sqrt(1+n[U-1].ib*n[U-1].ib);var M=I/(I-j),m=1e6/((n[U].o-n[U-1].o)*M+n[U-1].o),l=W-((n[U].WK-n[U-1].WK)*M+n[U-1].WK),A=D-((n[U].jB-n[U-1].jB)*M+n[U-1].jB),g=Math.sqrt(1+n[U].ib*n[U].ib),k=1/g,$=n[U].ib/g,C=Math.sqrt(1+n[U-1].ib*n[U-1].ib),f=1/C,z=n[U-1].ib/C,s=(k-f)*M+f,O=($-z)*M+z,a=Math.sqrt(s*s+O*O);
s/=a;O/=a;var X=(l*s+A*O)*-3e3;return{iP:m,fH:X}};dS.s4=function(w,n){var W=dS.u2,D=1e6/w,j=1;for(;j<31;
j++){if(D<W[j].o){break}}var I=(W[j].o-D)/(W[j].o-W[j-1].o),U=(W[j-1].WK-W[j].WK)*I+W[j].WK,M=(W[j-1].jB-W[j].jB)*I+W[j].jB,m=Math.sqrt(1+W[j].ib*W[j].ib),l=1/m,A=W[j].ib/m,g=Math.sqrt(1+W[j-1].ib*W[j-1].ib),k=1/g,$=W[j-1].ib/g,C=(k-l)*I+l,f=($-A)*I+A,z=Math.sqrt(C*C+f*f);
C/=z;f/=z;U+=C*n/-3e3;M+=f*n/-3e3;return{x:1.5*U/(U-4*M+2),y:M/(U-4*M+2)}};dS.abz=function(w){var n=w[0]+w[1]+w[2];
return{x:w[0]/n,y:w[1]/n}};dS.vz=function(w){return{x:w.x/w.y,y:1,YD:(1-w.x-w.y)/w.y}};dS.Lg=function(w,n){var W=E.Mv.Vr([.8951,.2664,-.1614,-.7502,1.7135,.0367,.0389,-.0685,1.0296]),D=[w.x,w.y,w.YD,0],j=[n.x,n.y,n.YD,0];
D=E.Mv.q4(W,D);j=E.Mv.q4(W,j);var I=j[0]/D[0],U=j[1]/D[1],M=j[2]/D[2],m=E.Mv.Vr([I,0,0,0,U,0,0,0,M]),l=E.Mv.Ba(W);
return E.Mv.multiply(E.Mv.multiply(l,m),W)};E.raw.Hx={};E.raw.pd=function(w){w*=8;var n=[8,10,12,14,16];
for(var W in CAMS){var D=CAMS[W];if(D.length==4)continue;var j=D[4],I=D[5];for(var L=0;L<n.length;L++)if(j*I*n[L]==w)return[W,n[L]]}var U=[[4e3,3e3]];
for(var L=0;L<U.length;L++){var D=U[L],j=D[0],I=D[1];for(var L=0;L<n.length;L++)if(j*I*n[L]==w)return[D,n[L]]}return null};
E.raw.a8v=function(w){var w=new Uint8Array(w);for(var L=0;L<w.length;L+=2){var n=w[L];w[L]=w[L+1];w[L+1]=n}var W=E.raw.pd(w.length),D=CAMS[W[0]];
if(D==null)D=[[8489,-2583,-1036,-8051,15583,2643,-1307,1407,7354],0,1e3,64383,W[0][0],W[0][1]];var j=D[4],I=D[5],U=Math.max(D[2],116),M={data:w,jy:1,width:j,height:I,t256:[j],t257:[I],t258:[W[1]],t277:[1],t33421:[2,2],t33422:E.raw.JL[D[1]],t50706:[1,2,0,0],t50714:[U,U,U,U],t50717:[D[3]],t50721:D[0].slice(0),t50723:[1,0,0,0,1,0,0,0,1],t50728:[.64,1,.46],t50778:[17]};
for(var L=0;L<9;L++)M.t50721[L]/=1e4;return M};E.raw.ig=function(w){if(w==null||w.length==0||typeof w[0]=="number")return w;
var n=[];for(var L=0;L<w.length;L++)n[L]=w[L][1]==0?0:w[L][0]/w[L][1];return n};E.raw.JL=[[2,1,1,0],[0,1,1,2],[1,0,2,1],[1,2,0,1]];
E.raw.normalize=function(w,n){if(w.t50706!=null||w.t271[0].startsWith("Hasselblad")){var W=[50714,50718,50719,50720,50721,50722,50723,50724,50727,50728,50730,50731,50732,50734,50736,50738,50739,50780,50964,50965];
for(var L=0;L<W.length;L++)if(w["t"+W[L]]!=null)w["t"+W[L]]=E.raw.ig(w["t"+W[L]]);if(w.t271&&w.t271[0].startsWith("Hasselblad")){w.t50706=[1,2,0,0];
w.t33422=E.raw.JL[1];w.t50723=[1,0,0,0,1,0,0,0,1];w.t50778=[17];if(!w.isLE)for(var L=0;L<w.data.length;
L+=2){var D=w.data[L];w.data[L]=w.data[L+1];w.data[L+1]=D}}if(w.t272&&w.t272[0]=="HERO10 Black"){w.t50728=[.469725,1,.739884];
if(!w.t305[0].startsWith("Adobe")){var j=new Uint16Array(w.data.buffer);for(var L=0;L<j.length;L++)j[L]>>>=2}}return}var I=w.t258[0],U=w.exifIFD,n=new Uint8Array(n);
w.t50706=[1,2,0,0];var M=w.t272[0].trim();if(M.indexOf(" ")==-1)M=w.t271[0].trim()+" "+M;if(w.t50708==null)w.t50708=[M];
var m=M.toLowerCase(),l=CAMS,A=l[m];if(A==null)for(var g in l)if(m.startsWith(g))A=l[g];if(A==null)alert("Unknown camera:"+M);
else{var k=A[2];w.t50714=[k,k,k,k];if(w.t272=="Canon EOS REBEL T3")A[3]=13584;w.t50717=[A[3]];w.t50721=A[0].slice(0);
for(var L=0;L<9;L++)w.t50721[L]=w.t50721[L]*(1/1e4)}w.t50723=[1,0,0,0,1,0,0,0,1];if(w.t50728==null)w.t50728=[.35,1,.6];
w.t50778=[17];if(w.t271[0].startsWith("SONY")){var $=UTIF["_bin"+(w.isLE?"LE":"BE")],C=w.t28688,P;if(JSON.stringify(C)!="[8000,10400,12900,14100]")console.log(C);
if(C){var f=[0,0,0,0,0,4095],z=new Uint16Array(16385);for(var L=0;L<4;L++){var s=C[L]>>>2;f[L+1]=s;if(s>4095)throw"e"}for(var L=0;
L<16385;L++)z[L]=L;for(var L=0;L<5;L++)for(var O=f[L]+1;O<=f[L+1];O++)z[O]=z[O-1]+(1<<L);var a=n.length*8<w.width*w.height*I;
if(a)w.t50712=z}else console.log("no curve");var X=w.dngPrvt;if(X){var Z=X.t29184[0],Y=X.t29185[0],K=(w.isLE?J.ly:J.q)(X.t29217,0),S=new Uint32Array(n.slice(Z,Z+(Y&4294967292)).buffer),G=new Uint32Array(Y>>>2);
E.raw.a8d(S,G,Y>>>2,K);var V=new Uint8Array(Z+Y);V.set(new Uint8Array(G.buffer),Z);var T=[];UTIF._readIFD($,V,Z,T,0,!1);
var R=T.pop(),x=R.t29458;w.t50728=[x[1]/x[0],1,x[1]/x[3]];w.t50730=[.5];var v=R.t29891;w.t50829=[v[1],v[0],v[3],v[2]]}else if(U.makerNote&&U.makerNote.t8208){var P=U.makerNote,N=P.t8208,u=N.length,H=0,F=new Uint8Array(256);
for(var L=249;L<256;L++)F[L]=L;for(var L=0;L<249;L++)F[L*L*L%249]=L;for(var L=0;L<u;L++)N[L]=F[N[L]];
if(u==6604)H=612;else throw"e";var x=[];for(var L=0;L<3;L++)x.push(J.lm(N,H+L*2));console.log(x);w.t50728=[x[1]/x[0],1,x[1]/x[2]]}else console.log("no white balance");
if(w.width*w.height*1.5==w.t279[0]){k=k>>>2;w.t50714=[k,k,k,k];w.t50717=[A[3]>>>2]}}else if(w.t271[0].startsWith("Canon")){var n=w.data,t=n.slice(0),o=w.t50752,q=[],d=0;
if(o==null||o[0]==0&&o[1]==0)q.push(w.width);else{for(var L=0;L<o[0];L++)q.push(o[1]);q.push(o[2])}var _=w.width*2,r=w.t50885&&w.t50885[0]==4;
if(!r)for(var p=0;p<q.length;p++){var Q=q[p],B=2*d,i=2*Q;for(var c=0;c<w.height;c+=2){var h2=c*_+B,jX=w.height*B+c*i;
for(var L=0;L<i;L++){n[h2+L]=t[jX+L];n[h2+L+_]=t[jX+L+i]}}d+=Q}else{for(var p=0;p<q.length;p++){var Q=q[p]/((o[0]*o[1]+o[2])/w.width);
for(var c=0;c<w.height;c++){var h2=(c*w.width+d)*6,jX=(w.height*d+c*Q)*6;for(var L=0;L<Q*6;L++)n[h2+L]=t[jX+L]}d+=Q}var bm=new Uint16Array(n.buffer),dC=new Uint16Array(1),fn=new Int16Array(dC.buffer);
for(var L=0;L<bm.length;L+=3){var fK=bm[L],i6=bm[L+1],dh=bm[L+2];dC[0]=i6<<2;i6=fn[0]>>2;dC[0]=dh<<2;
dh=fn[0]>>2;bm[L+0]=Math.max(0,dh+fK);bm[L+1]=Math.max(0,(fK<<12)-i6*778-(dh<<11)>>12);bm[L+2]=Math.max(0,i6+fK)}}var P=U.makerNote;
if(P.t16385){var kA=P.t224,ah=0;if(kA){var Z=w.t50719=[kA[5],kA[6]],ig=w.t50720=[kA[7]+1-kA[5],kA[8]+1-kA[6]],iJ=P.t154;
if(iJ){Z[0]+=iJ[3];Z[1]+=iJ[4];ig[0]=iJ[1];ig[1]=iJ[2]}}var fL=P.t16385,fB=fL.length;if(fB==582)ah=1;
else if(fB==653)ah=2;else if(fB==796)ah=3;else if([692,674,702,1227,1250,1251,1337,1338,1346].indexOf(fB)!=-1)ah=4;
else if(fB==5120){ah=5;fL=new Int16Array(fL.slice(0).buffer)}else if(fB==1273||fB==1275)ah=6;else if([1312,1313,1316,1506].indexOf(fB)!=-1)ah=7;
else if([1560,1592,1353,1602].indexOf(fB)!=-1)ah=8;else throw"e"+fB;var eS=fL[0],gL=[null,[25,166],[34,286],[63,196],[63],[71,eS==-4?333:264],[63,251],[63,eS==10?504:728],[63,326]],H=gL[ah][0],e_=gL[ah][1];
if(ah==4){if(fL[0]==2)e_=231;else if(fL[0]==3)e_=231;else if(fL[0]==4)e_=231;else if(fL[0]==5)e_=231;
else if(fL[0]==6)e_=231;else if(fL[0]==7)e_=231;else if(fL[0]==9)e_=231;else throw"e"}w.t50728=[fL[H+1]/fL[H],1,fL[H+1]/fL[H+3]];
var k=e_==null?1024:fL[e_];if(ah!=4)w.t50714=[k,k,k,k]}else{w.t50728=[.4,1,.6]}if(r){w.t277=[3];w.t50728=[1,1,1];
w.t50714=[0,0,0,0]}}else if(w.t271[0].startsWith("NIKON")){var P=U.makerNote,c2=w.isLE?J.lm:J.zx,eo=0,di=0,gJ,im=0;
if(P.t61){var jS=P.t61,ie=[];for(var L=0;L<4;L++)ie[L]=jS[L]/Math.pow(2,14-I);w.t50714=ie}if(P.t3585){var as=P.t3585,L=0,Z=22;
while(Z<as.length&&L!=-4){var gb=J.ly(as,Z);Z+=4;Z+=14;L=J.ly(as,Z)-4;Z+=4;if(gb==1990472198){if(as[Z]!=0)throw"Flip"}if(gb==1990472199){var gx=J.lm(as,Z);
if(gx==0)w.jy=1;else if(gx==270)w.jy=8;else throw"e "+gx}Z+=L}}if(P.t183){var d0=P.t183,ig=[];for(var L=0;
L<6;L++)ig.push(c2(d0,16+L*2));eo=ig[0];di=ig[1]}if(P.t3614){var e6=P.t3614;eo=J.ly(e6,8);di=J.ly(e6,12)}if(eo!=0&&Math.max(eo,di)<Math.max(w.width,w.height)){if(eo<di){var D=eo;
eo=di;di=D}var d=w.width-eo>>>1,c=w.height-di>>>1;w.t50829=[c,d,c+di,d+eo]}else w.t50829=[8,8,w.height-8,w.width-56];
var dt=P.t69;if(dt)w.t50829=[dt[1],dt[0],dt[1]+dt[3],dt[0]+dt[2]];if(P.t12){var iW=E.raw.ig(P.t12);gJ=[1/iW[0],1,1/iW[1]]}else if(P.t151){var g5=E.raw.ahu(P,151),jW=g5[0],dN=g5[1],eP=g5[2];
if(jW=="0100"&&dN>=80)throw"e";else if(jW=="0102"){var b_=[];for(var L=0;L<4;L++)b_.push(c2(eP,6+L*2));
gJ=[b_[1]/b_[0],1,b_[1]/b_[3]]}else if(jW=="0103"&&dN>=26){var b_=[];for(var L=0;L<4;L++)b_.push(c2(eP,16+L*2));
gJ=[b_[1]/b_[0],1,b_[3]/b_[2]]}else if(jW=="0204"&&dN>=564||jW=="0205"&&dN>=284){var Z=jW=="0204"?6:14,b_=[];
for(var L=0;L<4;L++)b_.push(c2(eP,Z+L*2));gJ=[b_[1]/b_[0],1,b_[1]/b_[3]]}else throw"e"}else console.log("no white balance info");
if(M=="NIKON D1")gJ=[1,1,1];if(gJ)w.t50728=gJ;var fZ=P.t150?P.t150:P.t140;if(fZ){var j3=fZ[im++],dr=fZ[im++],cB;
if(j3==73||dr==88)im+=2110;im+=8;var c0=1<<I&32767,fM=c2(fZ,im);im+=2;var z=[];if(fM>1)cB=Math.floor(c0/(fM-1));
if(j3==68&&dr==32&&cB>0){for(L=0;L<fM;L++){z[L*cB]=c2(fZ,im);im+=2}for(L=0;L<c0;L++)z[L]=Math.floor((z[L-L%cB]*(cB-L%cB)+z[L-L%cB+cB]*(L%cB))/cB)}else if(j3!=70&&fM<=16385){c0=fM;
for(var L=0;L<fM;L++)z[L]=c2(fZ,im+2*L);im+=2*fM}var iI=w.t272[0];if(z.length!=0)w.t50712=new Uint16Array(z);
if(w.t258[0]==14&&w.t50717&&w.t50717[0]<1e4){console.log("fixing white");w.t50717[0]*=4}}}else if(M.startsWith("FujiFilm")){}else if(M.startsWith("Panasonic")){if(w.t277==null)w.t277=[1]}else alert("Unknown camera "+M)};
E.raw.a8d=function(w,n,W,D){if(0==W)return;var j=new Uint32Array(128),I=new Uint8Array(j.buffer),U=127,M=0,m=0;
for(var U=0;U<4;U++)j[U]=D=(D*15625>>>0)*3125+1>>>0;j[3]=j[3]<<1|(j[0]^j[2])>>>31;for(var U=4;U<127;
U++)j[U]=(j[U-4]^j[U-2])<<1|(j[U-3]^j[U-1])>>>31;for(var U=0;U<127;U++)j[U]=J.q(I,U*4);for(;W>0;W--){j[U&127]=j[U+1&127]^j[U+1+64&127];
var l=j[U&127],A=w[M];A^=l;n[m]=A;M++;m++;U++}};E.raw.aim=function(w,n){var W=J.sv(n,0,4),D=E.raw.ans;
for(var L=0;L<D.length;L++)if(D[L][0]==w&&W.startsWith(D[L][1])&&(D[L][2]==0||D[L][2]==n.length))return D[L];
throw"e"};E.raw.aa2=function(w){if(w.t29==null)return[];var n=E.raw.aip,W=E.raw.alC,D=w.t29[0],j=0,U=0;
for(var L=0;L<D.length;L++){var I=D.charCodeAt(L);j=j*10+(48<=I&&I<=57?I-48:I%10)}var dN=w.t167[0];for(var L=0;
L<4;L++)U^=dN>>>(L<<3)&255;var M=n[j&255],m=W[U&255];return[M,m,96]};E.raw.ahu=function(w,n){var W=w["t"+n],dN=W.length,D=E.raw.aim(n,W),j=J.sv(W,0,4),I,U=D[4];
if(U==null)I=W.slice(4);else{I=new Uint8Array(dN-U);var M=E.raw.aa2(w),m=M[0],l=M[1],A=M[2];for(var L=0;
L<I.length;L++){l=l+m*A++&255;I[L]=W[U++]^l}}return[j,dN,I]};E.raw.ans=[[145,"0208",0,0,4],[145,"0209",0,1,4],[145,"0210",5291,2,4],[145,"0210",5303,3,4],[145,"02",0,4,4],[145,"01",0,5,null],[151,"0100",0,0,null],[151,"0102",0,1,null],[151,"0103",0,4,null],[151,"0204",0,3,284],[151,"0205",0,2,4],[151,"0206",0,3,284],[151,"0207",0,3,284],[151,"0208",0,3,284],[151,"0209",0,5,284],[151,"02",0,3,284],[152,"0100",0,0,null],[152,"0101",0,1,null],[152,"0201",0,1,4],[152,"0202",0,1,4],[152,"0203",0,1,4],[152,"0204",0,2,4],[168,"0100",0,0,null],[168,"0101",0,0,null],[168,"0102",0,1,null],[168,"0103",0,2,null]];
E.raw.aip=[193,191,109,13,89,197,19,157,131,97,107,79,199,127,61,61,83,89,227,199,233,47,149,167,149,31,223,127,43,41,199,13,223,7,239,113,137,61,19,61,59,19,251,13,137,193,101,31,179,13,107,41,227,251,239,163,107,71,127,149,53,167,71,79,199,241,89,149,53,17,41,97,241,61,179,43,13,67,137,193,157,157,137,101,241,233,223,191,61,127,83,151,229,233,149,23,29,61,139,251,199,227,103,167,7,241,113,167,83,181,41,137,229,43,167,23,41,233,79,197,101,109,107,239,13,137,73,47,179,67,83,101,29,73,163,19,137,89,239,107,239,101,29,11,89,19,227,79,157,179,41,67,43,7,29,149,89,89,71,251,229,233,97,71,47,53,127,23,127,239,127,149,149,113,211,163,11,113,163,173,11,59,181,251,163,191,79,131,29,173,233,47,113,101,163,229,7,53,61,13,181,233,229,71,59,157,239,53,163,191,179,223,83,211,151,83,73,113,7,53,97,113,47,67,47,17,223,23,151,251,149,59,127,107,211,37,191,173,199,197,197,181,139,239,47,211,7,107,37,73,149,37,73,109,113,199];
E.raw.alC=[167,188,201,173,145,223,133,229,212,120,213,23,70,124,41,76,77,3,233,37,104,17,134,179,189,247,111,97,34,162,38,52,42,190,30,70,20,104,157,68,24,194,64,244,126,95,27,173,11,148,182,103,180,11,225,234,149,156,102,220,231,93,108,5,218,213,223,122,239,246,219,31,130,76,192,104,71,161,189,238,57,80,86,74,221,223,165,248,198,218,202,144,202,1,66,157,139,12,115,67,117,5,148,222,36,179,128,52,229,44,220,155,63,202,51,69,208,219,95,245,82,195,33,218,226,34,114,107,62,208,91,168,135,140,6,93,15,221,9,25,147,208,185,252,139,15,132,96,51,28,155,69,241,240,163,148,58,18,119,51,77,68,120,40,60,158,253,101,87,22,148,107,251,89,208,200,34,54,219,210,99,152,67,161,4,135,134,247,166,38,187,214,89,77,191,106,46,170,43,239,230,120,182,78,224,47,220,124,190,87,25,50,126,42,208,184,186,41,0,60,82,125,168,73,59,45,235,37,73,250,163,170,57,167,197,167,80,17,54,251,198,103,74,245,165,18,101,126,176,223,175,78,179,97,127,47];
E.z4={};E.z4.z4=function(w,n,W,D,j){if(D==null)D=3;if(j==null)j=!0;var I=w.m,U=w.n,M=1/I,m=I*U,l=Date.now(),A=!1,g=E.z4.Ej(W,I,U,255,128),k=E.z4.Ej(W,I,U,0,128),i=0;
if(A)console.log("extract contours",Date.now()-l);l=Date.now();var $=function(iW,g5){var jW=iW<<2,eP=g5<<2;
return n[jW]+n[jW+1]+n[jW+2]-(n[eP]+n[eP+1]+n[eP+2])};g.sort($);k.sort($);var C=E.Q(m),f=E.Q(m),z=[],s=new Uint32Array(I*U);
s.fill(4294967295);for(var L=0;L<m;L++)if(W[L]==0)f[L]=255;else if(W[L]==255)C[L]=255;else{s[L]=z.length;
z.push(L)}var O=g.length,a=k.length,X=z.length;function P(iW,g5,jW,eP){var b_=iW.length,fZ=new Array(b_*2);
for(var L=0;L<b_;L++){var u=iW[L],H=~~(u*eP),F=u-H*jW,e6=u<<2;fZ[L*2]=F<<16|H;fZ[L*2+1]=g5[e6]<<16|g5[e6+1]<<8|g5[e6+2]}return fZ}var Z=P(g,n,I,M),Y=P(k,n,I,M),K=P(z,n,I,M);
if(A)console.log("Itemize",Date.now()-l,"Unknown:",X,O,a);l=Date.now();var S=E.style.Mh(C,I,U,!0),G=E.style.Mh(f,I,U,!0),V=new Array(X),T=new Array(X),R=new Array(X),x=new Array(X),v=new Array(X);
if(A)console.log("Dist transform",Date.now()-l);l=Date.now();var N=E.z4.VF;for(var L=0;L<X;L++){var u=z[L],H=~~(u*M),F=u-H*I,t=S[u<<1],o=S[(u<<1)+1],q=Math.sqrt(t*t+o*o),_=G[u<<1],d=G[(u<<1)+1],r=Math.sqrt(_*_+d*d);
V[L]=1/q;T[L]=1/r;var p=Math.floor(E.s.lr(u*17)*O),Q=Math.floor(E.s.lr(u*19)*a);R[L]=p;x[L]=Q;v[L]=N(K[L*2],K[L*2+1],Z[p*2],Z[p*2+1],Y[Q*2],Y[Q*2+1],V[L],T[L],1e9)}var B=[-I-1,-I,-I+1,-1,1,I-1,I,I+1];
while(Math.floor(Math.max(O,a)*Math.pow(.5,i))>1)i++;for(var c=0;c<D;c++){var h2=0;for(var L=0;L<X;L++){var u=z[L],H=~~(u*M),F=u-H*I,jX=V[L],bm=T[L],dC=K[L*2],fn=K[L*2+1],fK=v[L],p=R[L],Q=x[L],fL=1;
if(H!=0&&F!=0&&F!=I-1&&H!=U-1)for(var i6=0;i6<8;i6++){var dh=s[u+B[i6]];if(dh==4294967295)continue;var kA=R[dh],ig=x[dh];
if(kA==p&&ig==Q)continue;var iJ=N(dC,fn,Z[kA*2],Z[kA*2+1],Y[ig*2],Y[ig*2+1],jX,bm,fK);if(iJ<fK){fK=iJ;
p=kA;Q=ig}}for(var fB=0;fB<i;fB++){var ah=~~(O*fL),eS=~~(a*fL);fL*=.5;var gL=E.s.lr(u+c*17+fB*31),e_=E.s.lr(u+c*29+fB*63),c2=Math.max(0,p-ah),jS=Math.min(p+ah,O-1),ie=Math.max(0,Q-eS),gb=Math.min(Q+eS,a-1),kA=c2+~~(gL*(jS-c2)),ig=ie+~~(e_*(gb-ie)),iJ=N(dC,fn,Z[kA*2],Z[kA*2+1],Y[ig*2],Y[ig*2+1],jX,bm,fK);
if(iJ<fK){fK=iJ;p=kA;Q=ig}}v[L]=fK;R[L]=p;x[L]=Q;h2+=fK}}if(A)console.log(h2);if(A)console.log("iterations",Date.now()-l);
l=Date.now();var gx=W.slice(0);for(var L=0;L<X;L++){var eo=E.z4.alpha(K[L*2+1],Z[R[L]*2+1],Y[x[L]*2+1]);
gx[z[L]]=~~(.5+255*eo)}gx=E.l8.ab5(gx,n,new iB(0,0,I,U),16,.01*.01);if(A)console.log("guided filter",Date.now()-l);
l=Date.now();if(j)for(var L=0;L<m;L++)if(W[L]==255||W[L]==0)gx[L]=W[L];var di=n.slice(0);for(var L=0;
L<X;L++){var d0=z[L],p=g[R[L]],fK=v[L],e6=d0<<2,dt=gx[d0],gJ=(dt>=250?d0:p)<<2;di[e6]=n[gJ];di[e6+1]=n[gJ+1];
di[e6+2]=n[gJ+2]}E.IL(gx,di,3);if(A)console.log(Date.now()-l);l=Date.now();return di};E.z4.VF=function(w,n,W,D,j,I,U,M,m){var l=w>>>16,A=w&65535,g=l-(W>>>16),k=A-(W&65535),$=l-(j>>>16),C=A-(j&65535),f=Math.sqrt(g*g+k*k)*U,z=Math.sqrt($*$+C*C)*M;
if(f+z>=m)return 1e9;var s=E.z4.ajs(n,D,I);return s+f+z};E.z4.ajs=function(w,n,W){var D=w>>>16,j=w>>>8&255,I=w&255,U=n>>>16,M=n>>>8&255,m=n&255,l=W>>>16,A=W>>>8&255,g=W&255,k=E.z4.alpha(w,n,W),$=D-(k*U+(1-k)*l),C=j-(k*M+(1-k)*A),f=I-(k*m+(1-k)*g);
return Math.sqrt($*$+C*C+f*f)};E.z4.alpha=function(w,n,W){var D=w>>>16,j=w>>>8&255,I=w&255,U=n>>>16,M=n>>>8&255,m=n&255,l=W>>>16,A=W>>>8&255,g=W&255,k=U-l,$=M-A,C=m-g,f=D-l,z=j-A,s=I-g,O=k*k+$*$+C*C,a=O==0?.5:(f*k+z*$+s*C)/O;
return Math.max(0,Math.min(1,a))};E.z4.am6=function(w){};E.z4.Ej=function(w,n,W,D,j){var I=[],U=n-1,M=W-1;
for(var m=1;m<M;m++)for(var l=1;l<U;l++){var L=m*n+l;if(w[L]==D&&(w[L-n-1]==j||w[L-n]==j||w[L-n+1]==j||(w[L-1]==j||w[L+1]==j)||(w[L+n-1]==j||w[L+n]==j||w[L+n+1]==j)))I.push(L)}return I};
E.l8={};E.l8.acS=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=E.l8.Lt,l=E.Q(M*4),A;E.cJ(l,4294967295);
var g=W,k=w,$=n,C=D;E.IL(w,l,0);A=E.VU(l,W);A=E.VU(A.Q0,A.rect);g=A.rect;C=D>>>2;console.log(g,C);k=E.Q(g.O());
E.hN(A.Q0,k,0);E.IL(n,l,0);A=E.VU(l,W);A=E.VU(A.Q0,A.rect);$=E.Q(g.O());E.hN(A.Q0,$,0);var f=E.l8.a6e(k,$,g,C,j),z=f[0],s=f[1],O=new iB(0,0,g.m*2,g.n*2);
z=m(z,g,O,!0);z=m(z,O,W,!0);s=m(s,g,O,!0);s=m(s,O,W,!0);var a=E.Q(M);for(var L=0;L<M;L++)a[L]=Math.max(0,Math.min(255,Math.floor(.5+(z[L]*n[L]+255*s[L]))));
return a};E.l8.Lt=function(w,n,W,D){var j=W.m,I=W.n,U=n.m,M=n.n,m=E.l8.hC,l=new Float32Array(j*I);for(var A=0;
A<M;A++){var g=(A+A)*j;for(var k=0;k<U;k++){if(!0||k==0||A==0||k==U-1||A==M-1)l[g]=l[g+1]=l[g+j]=l[g+j+1]=w[A*U+k];
else{l[g]=m(k+.25,A+.25,w,U,M);l[g+1]=m(k+.75,A+.25,w,U,M);l[g+j]=m(k+.25,A+.75,w,U,M);l[g+j+1]=m(k+.75,A+.75,w,U,M)}g+=2}}return l};
E.l8.hC=function(w,n,W,D,j){w-=.499999;n-=.499999;var I=Math.floor(w),U=Math.floor(n),M=U*D+I,m=w-I,l=n-U,A=(1-l)*(1-m),g=(1-l)*m,k=l*(1-m),$=l*m;
if(W[M]==null||W[M+D+1]==null){console.log(w,n,D,j);throw"e"}return A*W[M+0]+g*W[M+1]+k*W[M+D+0]+$*W[M+D+1]};
E.l8.a6e=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=E.l8.w8,l=E.l8.Q,A=E.xX.xn,g=E.l8.Kn,n=m(n),w=m(w),k=l(M);
A(n,k,W,D);var $=l(M);A(w,$,W,D);var C=l(M);g(n,n,C);A(C,C,W,D);var f=l(M);g(n,w,f);A(f,f,W,D);var z=l(M),s=l(M);
for(var L=0;L<M;L++){var O=k[L],a=$[L],X=C[L]-O*O,P=f[L]-O*a,Z=P/(X+j),Y=a-Z*O;z[L]=Z;s[L]=Y}var K=l(M);
A(z,K,W,D);var S=l(M);A(s,S,W,D);return[K,S]};E.l8.ab5=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=E.l8.Lt,l=Date.now(),A=!1,g=W,k=w,$=n,C=D;
g=new iB(0,0,I>>>2,U>>>2);C=D>>>2;k=E.l8.akm(w,I,U);$=E.l8.a5n(n,I,U);if(A)console.log(Date.now()-l);
l=Date.now();var f=E.l8.ar4(k,$,g,C,j),z=f[0],s=f[1],O=f[2],a=f[3];if(A)console.log(Date.now()-l);l=Date.now();
var X=E.Q(M);for(var P=0;P<U;P++)for(var Z=0;Z<I;Z++){var L=P*I+Z,Y=(P>>>2)*(I>>>2)+(Z>>>2),K=L<<2,S=z[Y]*n[K]+s[Y]*n[K+1]+O[Y]*n[K+2]+a[Y]*255;
X[L]=Math.max(0,Math.min(255,~~(.5+S)))}if(A)console.log(Date.now()-l);l=Date.now();return X};E.l8.akm=function(w,n,W){var D=n>>>2,j=W>>>2,I=E.Q(n*W);
for(var U=0;U<j;U++)for(var M=0;M<D;M++)I[U*D+M]=w[U*n+M<<2];return I};E.l8.a5n=function(w,n,W){var D=n>>>2,j=W>>>2,I=E.Q(n*W*4);
for(var U=0;U<j;U++)for(var M=0;M<D;M++){var m=U*D+M<<2,l=U*n+M<<4;I[m]=w[l];I[m+1]=w[l+1];I[m+2]=w[l+2];
I[m+3]=w[l+3]}return I};E.l8.ar4=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=E.l8.w8,l=E.l8.Q,A=E.xX.xn,g=E.l8.Kn,w=m(w),k=new E.H0(I*U);
E.rH(n,k);var n=[m(k.o),m(k.B),m(k.k)],$=E.l8.a4J(w,n,W,D,j),C=l(M);A(w,C,W,D);var f=l(M);g(n[0],w,f);
A(f,f,W,D);var z=l(M);g(n[1],w,z);A(z,z,W,D);var s=l(M);g(n[2],w,s);A(s,s,W,D);var O=l(M),a=l(M),X=l(M),P=l(M);
for(var L=0;L<M;L++){var Z=C[L],Y=$.T_[L],K=$.VM[L],S=$.nD[L],G=f[L]-Y*Z,V=z[L]-K*Z,T=s[L]-S*Z;O[L]=$.agO[L]*G+$.oS[L]*V+$.wK[L]*T;
a[L]=$.oS[L]*G+$.a4O[L]*V+$.Vg[L]*T;X[L]=$.wK[L]*G+$.Vg[L]*V+$.azD[L]*T;P[L]=Z-O[L]*Y-a[L]*K-X[L]*S}A(O,O,W,D);
A(a,a,W,D);A(X,X,W,D);A(P,P,W,D);return[O,a,X,P]};E.l8.a4J=function(w,n,W,D,j){var I=W.m,U=W.n,M=I*U,m=E.l8.Q,l=E.xX.xn,A=E.l8.Kn,g={};
g.T_=m(M);l(n[0],g.T_,W,D);g.VM=m(M);l(n[1],g.VM,W,D);g.nD=m(M);l(n[2],g.nD,W,D);var k=m(M);A(n[0],n[0],k);
l(k,k,W,D);var $=m(M);A(n[0],n[1],$);l($,$,W,D);var C=m(M);A(n[0],n[2],C);l(C,C,W,D);var f=m(M);A(n[1],n[1],f);
l(f,f,W,D);var z=m(M);A(n[1],n[2],z);l(z,z,W,D);var s=m(M);A(n[2],n[2],s);l(s,s,W,D);g.agO=k;g.oS=$;
g.wK=C;g.a4O=f;g.Vg=z;g.azD=s;for(var L=0;L<M;L++){var O=g.T_[L],a=g.VM[L],X=g.nD[L],P=k[L]-O*O+j,Z=$[L]-O*a,Y=C[L]-O*X,K=f[L]-a*a+j,S=z[L]-a*X,G=s[L]-X*X+j,V=K*G-S*S,T=S*Y-Z*G,R=Z*S-K*Y,x=P*G-Y*Y,v=Y*Z-P*S,N=P*K-Z*Z,u=V*P+T*Z+R*Y,H=1/u;
g.agO[L]=V*H;g.oS[L]=T*H;g.wK[L]=R*H;g.a4O[L]=x*H;g.Vg[L]=v*H;g.azD[L]=N*H}return g};E.l8.Q=function(w){return new Float32Array(w)};
E.l8.w8=function(w){var n=w.length,W=new Float32Array(n);for(var L=0;L<n;L++)W[L]=w[L]*(1/255);return W};
E.l8.Kn=function(w,n,W){for(var L=0;L<w.length;L++)W[L]=w[L]*n[L]};E.Np={};E.Np.oG=function(w,n,W,D){var j=w[n]-W[D],I=w[n+1]-W[D+1],U=w[n+2]-W[D+2];
return Math.sqrt(j*j+I*I+U*U)*(1/441.7)};E.Np.getSelection=function(w,n,W){var D=n*W,j=E.Q(D),I=!1,U=Math.round(W*.7),M=1,m=new Uint32Array(12),l=E.Q(12);
for(var A=0;A<U;A++)for(var g=0;g<n;g++){if(g<M||A<M||g>n-M-1||A>W-M-1){var L=A*n+g,k=L<<2,$=0;if(A<M)$=4;
else if(g>n-M-1)$=8;m[$]+=w[k];m[$+1]+=w[k+1];m[$+2]+=w[k+2];m[$+3]++;j[L]=255}}for(var L=0;L<12;L+=4)for(var C=0;
C<3;C++)l[L+C]=m[L+C]/m[L+3];var f=new Float32Array(D);for(var L=0;L<D;L++){var k=L*4,z=E.Np.oG(w,k,l,0),s=E.Np.oG(w,k,l,4),O=E.Np.oG(w,k,l,8),a=Math.max(z,Math.max(s,O));
f[L]=z+s+O-a}E.Np.CZ(f);var X=Date.now(),P=new Float32Array(D),Z=[],Y=E.Q(D);for(var L=0;L<3;L++){E.hN(w,Y,L);
var K=new Uint16Array(D);Z.push(K);E.Np.a0N(Y,j,n,W,K)}if(I)console.log("MBD",Date.now()-X);X=Date.now();
for(var L=0;L<D;L++)P[L]=Z[0][L]+Z[1][L]+Z[2][L];E.Np.CZ(P);for(var L=0;L<D;L++)P[L]+=.4*f[L];var S=n>>>1,U=W>>>1,G=1/Math.sqrt(S*S+U*U);
for(var A=0;A<W;A++)for(var g=0;g<n;g++){var V=g-S,T=A-U,R=1-Math.sqrt(V*V+T*T)*G;P[A*n+g]*=R}if(I)console.log("Centeredness",Date.now()-X);
X=Date.now();for(var L=0;L<D;L++)j[L]=P[L]*255;var x=Math.round(n/120),v=Math.round(x*.8);if(I)console.log(x,v);
E.nx.Ig(j,j,n,W,x+x+1,!1);if(I)console.log("erosion",Date.now()-X);X=Date.now();for(var L=0;L<D;L++)P[L]=j[L];
E.Np.CZ(P);var N=E.Q(256);for(var L=0;L<256;L++)N[L]=256/(1+Math.exp(-20*(L/255-.5)));for(var L=0;L<D;
L++){var u=~~(P[L]*255+.5);j[L]=N[u]}if(I)console.log("Simoid",Date.now()-X);X=Date.now();return j};
E.Np.CZ=function(w){var n=w.length,W=0;for(var L=0;L<n;L++)W=Math.max(W,w[L]);var D=1/W;for(var L=0;
L<n;L++)w[L]=w[L]*D};E.Np.a0N=function(w,n,W,D,j){var I=W*D,U=w.slice(0),M=w.slice(0);for(var L=0;L<I;
L++)j[L]=n[L]==255?0:65535;E.Np.o5(w,M,U,j,W,D);E.Np.Q1(w,M,U,j,W,D);E.Np.o5(w,M,U,j,W,D);E.Np.Q1(w,M,U,j,W,D);
return j};E.Np.o5=function(w,n,W,D,j,I){for(var U=1;U<j;U++)E.Np._h(U,-1,w,n,W,D);for(var M=1;M<I;M++){E.Np._h(M*j,-j,w,n,W,D);
for(var U=1;U<j;U++){var L=M*j+U;E.Np._h(L,-1,w,n,W,D);E.Np._h(L,-j,w,n,W,D)}}};E.Np.Q1=function(w,n,W,D,j,I){for(var U=j-2;
U>=0;U--)E.Np._h(j*I-j+U,1,w,n,W,D);for(var M=I-2;M>=0;M--){E.Np._h(M*j+j-1,j,w,n,W,D);for(var U=j-2;
U>=0;U--){var L=M*j+U;E.Np._h(L,1,w,n,W,D);E.Np._h(L,j,w,n,W,D)}}};E.Np._h=function(L,w,n,W,D,j){var I=L+w,U=n[L],M=W[I],m=D[I];
if(M<U)M=U;else if(U<m)m=U;var l=M-m;if(j[I]!=65535&&l<j[L]){j[L]=l;W[L]=M;D[L]=m}};E.Lx={};E.Lx.filter=function(w,n,W,D){var j=n.m,I=n.n,U=j*I,M=D[0],m=D[1],l=D[2],A=D[3],g=D[4],k=D[5],$=D[6],C=Date.now(),f=new Float32Array(j*I*4);
E.Lx.alS(w,j,I,f);var z=Math.ceil(M*Math.sqrt(-2*Math.log(.1))),s=new ArrayBuffer(U*4),O=new Float32Array(s),a=new Float32Array(U),X=new Float32Array(U);
for(var L=0;L<U;L++){var P=L*4;O[L]=f[P];a[L]=f[P+1];X[L]=f[P+2]}E.xX.uf(O,O,n,z*1/2.4,2);E.xX.uf(a,a,n,z*1/2.4,2);
E.xX.uf(X,X,n,z*1/2.4,2);for(var L=0;L<U;L++){var P=L*4;f[P]=O[L];f[P+1]=a[L];f[P+2]=X[L]}var Z=new Uint8Array(s);
for(var L=0;L<U;L++){var P=L*4,Y=L*4,O=f[P],a=f[P+1],X=f[P+2],K=Math.sqrt((O-X)*(O-X)+4*a*a),S=(O+X+K)*.5,G=(O+X-K)*.5,V=G-X,T=a,R=V*V+T*T;
if(R!=0){var x=Math.sqrt(R),v=1/x;V*=v;T*=v}Z[Y]=128+127*V;Z[Y+1]=128+127*T}var N=1.3*m+2,u=A*(2/10),H=w.slice();
if(je.YG){var F=new Float32Array([1/j,1/I]),t=je.vL(0,j,I);t.set(H);var o=je.vL(1,j,I);o.set(Z);je.t5(t,n);
if(g){t.Le(n);je.filter.zj({type:je.filter.a4s,q8:F,a03:1/l,ao3:u},t.Ef)}t.Le(n);je.filter.zj({type:je.filter.d7,XU:o.LJ,q8:F,anU:N,aiD:2},t.Ef);
if(g){t.Le(n);je.filter.zj({type:je.filter.azC,q8:F,ayj:new Float32Array($),awE:k},t.Ef)}t.get(W)}else{if(g)E.Lx.Mq(1/l,u,H,j,I);
E.Lx.d7(H,W,Z,j,I,N);if(g)E.Lx.ao2(j,I,W,$,k)}var q=U*4;for(var L=3;L<q;L+=4)W[L]=w[L]};E.Lx.d7=function(w,n,W,D,j,I){var U=Math.ceil(2*I),M=-1/(2*I*I),m=[],l=1;
for(var L=0;L<U+20;L++)m[L]=Math.exp(L*L*M);var A=[0,0,0,0];for(var g=0;g<j;g++){for(var k=0;k<D;k++){var $=g*D+k,C=$*4,f=1,z=w[C],s=w[C+1],O=w[C+2],a=w[C+3],X=(W[C]-128)*(1/127),P=(W[C+1]-128)*(1/127),Z=X,Y=P,K=k==0?.51:.49,S=g==0?.51:.49;
for(var L=0;L<2;L++){var G=k+K,V=g+S,T=0;while(T<U){if(G<.5||D-.5<G||V<.5||j-.5<V)break;var R=~~G,x=~~V,v=x*D+R,N=v*4,u=(W[N]-128)*(1/127),H=(W[N+1]-128)*(1/127);
if(u*Z+H*Y<0){u=-u;H=-H}Z=u;Y=H;G+=l*u;V+=l*H;if(G<.5||D-.5<G||V<.5||j-.5<V)break;var F=~~G,t=~~V,o=t*D+F<<2;
T+=l;var q=m[~~T];E.K.kG(G,V,w,D,j,A);z+=A[0]*q;s+=A[1]*q;O+=A[2]*q;a+=A[3]*q;f+=q}Z=-X;Y=-P}var _=1/f;
n[C]=~~(.5+z*_);n[C+1]=~~(.5+s*_);n[C+2]=~~(.5+O*_);n[C+3]=~~(.5+a*_)}}};E.Lx.ao2=function(w,n,W,D,j){for(var I=0;
I<n;I++)for(var U=0;U<w;U++){var M=I*w+U<<2,m=1+E.Lx.a10(U,I,W,w,n,D)*j;W[M]=Math.max(0,Math.min(255,W[M]*m));
W[M+1]=Math.max(0,Math.min(255,W[M+1]*m));W[M+2]=Math.max(0,Math.min(255,W[M+2]*m))}};E.Lx.a10=function(w,n,W,D,j,I){var U=W[(n*D+Math.max(0,w-1))*4+3],M=W[(n*D+Math.min(D-1,w+1))*4+3],m=W[(Math.max(0,n-1)*D+w)*4+3],l=W[(Math.min(j-1,n+1)*D+w)*4+3],A=.7,g=(M-U)*(1/255),k=.7,$=(l-m)*(1/255),C=-g*k,f=-A*$,z=A*k,s=Math.sqrt(C*C+f*f+z*z),O=1/s,a=C*O,X=f*O,P=z*O,Z=I[0]*a+I[1]*X+I[2]*P;
return Z};E.Lx.Mq=function(w,n,W,D,j){function I(M,l,A){return Math.max(l,Math.min(A,M))}for(var U=0;
U<j;U++)for(var M=0;M<D;M++){var m=E.Lx.ahX(M+.5,U+.5,w,n);W[(U*D+M)*4+3]=Math.max(0,Math.min(255,m*255))}};
E.Lx.ahX=function(w,n,W,D){function j(Y,K,S){return(1-S)*Y+S*K}var I=(w+613)*W,U=(n+117)*W,M=~~I,m=~~U,l=I-M,A=U-m,g=Math.sin(11),k=Math.cos(M)*g,$=Math.cos(M+1)*g,C=Math.cos(m)*g,f=Math.cos(m+1)*g,bK=E.Lx.hash(k,C),z=E.Lx.hash($,C),s=E.Lx.hash(k,f),O=E.Lx.hash($,f),a=j(bK,z,l),X=j(s,O,l),P=j(a,X,A);
P=P<.5?0:1;var Z=P+D*E.Lx.hash(Math.cos(I)*g,Math.cos(U)*g);return Z*(1/3)};E.Lx.hash=function(w,n){var W=Math.sin(w*11.697096+n*73.32456)*12157.47691;
return W-Math.floor(W)};E.Lx.alS=function(w,n,W,D){var j=[-1,0,1,-2,0,2,-1,0,1],I=[-1,-2,-1,0,0,0,1,2,1],U=n-1,M=W-1,m=n*4;
for(var l=1;l<M;l++)for(var A=1;A<U;A++){var L=l*n+A,g=L*4,k=E.Lx.yC(w,g,m,j),$=E.Lx.yC(w,g,m,I),C=E.Lx.yC(w,g+1,m,j),f=E.Lx.yC(w,g+1,m,I),z=E.Lx.yC(w,g+2,m,j),s=E.Lx.yC(w,g+2,m,I);
D[g]=k*k+C*C+z*z;D[g+1]=k*$+C*f+z*s;D[g+2]=$*$+f*f+s*s}E.Lx.adQ(D,n,W)};E.Lx.yC=function(w,n,W,D){return w[n-W-4]*D[0]+w[n-W]*D[1]+w[n-W+4]*D[2]+w[n-4]*D[3]+w[n]*D[4]+w[n+4]*D[5]+w[n+W-4]*D[6]+w[n+W]*D[7]+w[n+W+4]*D[8]};
E.Lx.adQ=function(w,n,W){function D(m,L,l){var A=L*4,g=l*4;m[g]=m[A];m[g+1]=m[A+1];m[g+2]=m[A+2]}var j=n-1,I=W-1;
D(w,n+1,0);D(w,2*n-2,n-1);for(var U=1;U<j;U++)D(w,n+U,U);for(var M=1;M<I;M++){D(w,M*n+1,M*n);D(w,M*n+n-2,M*n+n-1)}for(var U=1;
U<j;U++)D(w,(W-2)*n+U,(W-1)*n+U);D(w,(M-2)*n+1,(M-1)*n);D(w,(M-1)*n-2,M*n-1)};E.gX=function(){function w(l,A,g,k){var $=new Float32Array(l*l),C=l/2;
for(var f=0;f<l;f++)for(var z=0;z<l;z++){var s=z+g-C,O=f+k-C;$[f*l+z]=Math.max(0,Math.min(1,A+.5-Math.sqrt(s*s+O*O)))}return $}var n=[],D=null;
function W(l,A,g,k){var $=Math.floor(A*10),C=n[$],f=l*8,z=f>>>1;if(C==null){C=n[$]=[];var s=new iB(0,0,f,f),O=l/2/(1+.2*A),a=Math.floor(l*$*.1);
for(var X=0;X<2;X++)for(var P=0;P<2;P++){var Z=w(f,O,.25+P*.5,.25+X*.5),Y=0;E.xX.uf(Z,Z,s,a);while(Z[f*z+Y]<.005)Y++;
if(Y!=0)Y--;var K=2*(z-Y),S=new iB(Y,Y,K,K),G=new Float32Array(K*K);for(var V=0;V<K;V++)for(var T=0;
T<K;T++)G[V*K+T]=Z[(Y+V)*f+Y+T];C.push([G,S])}}var R=Math.floor(g),x=Math.floor(k),v=g-R,N=k-x,u=v<.5?1:0,H=N<.5?1:0;
C=C[H*2+u];var S=C[1].clone();S.x+=R-z;S.y+=x-z;return[C[0],S]}function j(l,A,g){if(D==null){D=new Uint8Array(4e4);
for(var L=0;L<4e4;L++)D[L]=Math.min(255,~~(.5+255*E.vw(L*(1/255))))}var k=l.length;for(var L=0;L<k;L++){var $=l[L],C=~~(255*$);
A[L]=D[C]<<24|g}}function I(l,A,g,k,$){var C=A.wU(k),f=Math.max(0,C.x-A.x),z=Math.max(0,C.x-k.x),s=Math.max(0,C.y-A.y),O=Math.max(0,C.y-k.y),a=C.m,X=C.n;
for(var L=0;L<X;L++){var P=(s+L)*A.m+f,Z=(O+L)*k.m+z;for(var Y=0;Y<a;Y++){g[Z+Y]+=$*l[P+Y]}}}var U=-1;
function M(l,A,g,k,$){var C=Math.round(k[1]*A*g*.01),f=k[2],z=k[3],s=k[4],O=k[5],a=k[6],X=k[7],P=k[8],Z=k[9],Y=k[10]?k[10]:1,q=!1;
if(f!=U){n=[];U=f}var K=Date.now(),S=new iB(0,0,A,g),G=new m(k[0]);if($)l.fill(0);var V=new Float32Array($?l.buffer:A*g);
for(var L=0;L<C;L++){var T=G.get()*A,R=G.get()*g,x=G.get()*z,v=G.get()*f*4,N=(G.get()+a)*Math.PI*2,u=G.get()*f*4,H=(G.get()+2*a)*Math.PI*2;
T+=Z*(v*Math.cos(N)+u*Math.cos(H));R+=Z*(v*Math.sin(N)+u*Math.sin(H));if(P)R=R+a*g*Y;var F=W(f,x,T,R%g),t=s,o=G.get();
if(X)t=.5+.5*s*(.5+.5*Math.sin((2*a+o)*2*Math.PI));I(F[0],F[1],V,S,t)}if(q)console.log(Date.now()-K,"add floats");
K=Date.now();var _=new Uint8Array(V.buffer);j(V,new Uint32Array(_.buffer),O.k<<16|O.B<<8|O.o);if(q)console.log(Date.now()-K,"toInt");
K=Date.now();if(!$){E.s._U("scrn",_,S,l,S,S,1);if(q)console.log(Date.now()-K,"blendOver")}}function m(l){this.r6=123456789;
this.Qv=987654321;this.z=4294967295;this.Ur(l)}m.prototype.Ur=function(L){this.r6=123456789+L&this.z;
this.Qv=987654321-L&this.z};m.prototype.get=function(){this.Qv=36969*(this.Qv&65535)+(this.Qv>>16)&this.z;
this.r6=18e3*(this.r6&65535)+(this.r6>>16)&this.z;var l=(this.Qv<<16)+(this.r6&65535)>>>0;l/=4294967296;
return l};return{ee:M}}();E.OY={};E.OY.FH=function(w,n,W,D){var j=w[n*2],I=w[n*2+1],U=w[W*2],M=w[W*2+1],m=w[D*2],l=w[D*2+1];
return j*M+U*l+m*I-m*M-U*I-j*l};E.OY.If=function(w,n){var W=[],D=[],j=[],I={};for(var L=0;L<n.length;
L+=3){var M=~~(L*(1/3)),m=n[L+0],l=n[L+1],A=n[L+2],g=E.OY.FH(w,m,l,A);if(g>0){var k=l;l=A;A=k}var $=I[A+"-"+l],C=I[l+"-"+m],f=I[m+"-"+A],z=[A,$,M,null],s=[l,C,M,z],O=[m,f,M,s];
z[3]=O;if($)$[1]=z;if(C)C[1]=s;if(f)f[1]=O;I[A+"-"+m]=O;I[m+"-"+l]=s;I[l+"-"+A]=z;W[m]=s;j[L]=s;W[l]=z;
j[L+1]=z;W[A]=O;j[L+2]=O;D[M]=s}return{cZ:W,J$:D,U9:j}};E.OY.aw_=function(w){var n=[],W=w.J$;for(var L=0;
L<W.length;L++){var D=W[L];n.push(D[0]);D=D[3];n.push(D[0]);D=D[3];n.push(D[0])}return n};E.OY.ast=function(w,n,W,D){var j=w[n*2],I=w[n*2+1],U=w[W*2],M=w[W*2+1],m=w[D*2],l=w[D*2+1],A=U-j,g=M-I,k=m-j,$=l-I,C=A*(j+U)+g*(I+M),f=k*(j+m)+$*(I+l),z=2*(A*(l-M)-g*(m-U));
if(Math.abs(z)<1e-5){var s=Math.min(j,U,m),O=Math.min(I,M,l),a=(Math.max(j,U,m)-s)*.5,X=(Math.max(I,M,l)-O)*.5;
return[s+a,O+X,a*a+X*X,1]}var P=($*C-g*f)/z,Z=(A*f-k*C)/z,a=P-j,X=Z-I;return[P,Z,a*a+X*X,0]};E.OY.ap$=function(w,n,W){var D=W[1],j=W[3],I=j[3],U=D[3],M=U[3],m=W[2],l=D[2],A=W[0],g=D[0],k=j[0],$=U[0],C=E.OY.ast(w,g,$,k),f=w[A*2]-C[0],z=w[A*2+1]-C[1],s=f*f+z*z>C[2]&&C[3]==0&&E.OY.FH(w,$,A,k)<0&&E.OY.FH(w,k,g,$)<0;
if(s){W[0]=k;D[0]=$;W[3]=I;I[3]=U;U[3]=W;D[3]=M;M[3]=j;j[3]=D;j[2]=l;U[2]=m;n.J$[l]=M;n.J$[m]=I;n.cZ[g]=U;
n.cZ[A]=j}return s};E.OY.adN=function(w,n,W){var D=w[n*2]-w[W*2],j=w[n*2+1]-w[W*2+1];return Math.sqrt(D*D+j*j)};
E.OY.ax8=function(w,n,W){var D=W[1],j=W[3],I=j[3],U,M,m=W[2],l,A=W[0],g=I[0],k=j[0],$;if(D){U=D[3];M=U[3];
l=D[2];$=U[0]}var C=w.length>>>1;w[2*C]=(w[2*g]+w[2*A])*.5;w[2*C+1]=(w[2*g+1]+w[2*A+1])*.5;if(!0){var f=m,z=W,s=n.J$.length,O=[C,null,f,z],a=[k,O,s,I];
O[1]=a;var X=[C,null,s,a];j[3]=O;I[3]=X;I[2]=s;n.J$[f]=j;n.J$[s]=X;n.cZ[A]=j;n.cZ[k]=I;n.U9.push(O,a,X)}if(D){var P=l,Z=D,Y=s+1;
X[1]=Z,Z[1]=X;var K=[C,null,P,Z],S=[$,K,Y,M];K[1]=S;var G=[C,z,Y,S];z[1]=G;U[3]=K;M[3]=G;M[2]=Y;n.J$[P]=U;
n.J$[Y]=M;n.cZ[g]=U;n.cZ[$]=M;n.U9.push(K,S,G)}n.cZ[C]=z};E.OY.an=function(w,n){var W=0;while(!0){var D=W;
for(var L=0;L<n.U9.length;L++){var j=n.U9[L];if(j[1]==null)continue;var I=E.OY.ap$(w,n,j);if(I){W++;
break}}if(D==W)break}return W!=0};E.OY.aen=function(w,n,W,D){var j=0;for(var L=0;L<D;L++){var I=null,U=0;
for(var M=0;M<n.U9.length;M++){var m=n.U9[M],l=E.OY.adN(w,m[0],m[3][3][0])*(m[1]?1:2);if(l>U){I=m;U=l}}if(U>W){E.OY.ax8(w,n,I);
j++}}return j!=0};E.OY.au_=function(w,n){var W=[],k=0;for(var L=0;L<w.length;L++)W.push(0);for(var L=0;
L<n.U9.length;L++){var D=n.U9[L],j=D[0],I=D[3][3][0],U=w[j*2],M=w[j*2+1],m=w[I*2],l=w[I*2+1],A=U-m,g=M-l;
W[j*2]+=-A;W[j*2+1]+=-g;W[I*2]+=A;W[I*2+1]+=g}for(var L=0;L<w.length;L+=2){var $=L>>>1,C=n.cZ[$],D=C,f=!0;
do{if(D[1]==null){f=!1;break}D=D[1][3]}while(D!=C);if(f){var z=.02;w[L]+=z*W[L];w[L+1]+=z*W[L+1];k+=z*(W[L]*W[L]+W[L+1]*W[L+1])}}return k};
E.OY.aud=function(w,n,W){var D=E.p.mY(w),j=E.OY.If(w,n);E.OY.an(w,j);for(var I=0;I<300;I++){var U=!1,M=!1;
U=E.OY.aen(w,j,W,5);if(U)M=E.OY.an(w,j);var m=E.OY.au_(w,j);if(!U&&!M&&m<1e-4){break}}return E.OY.aw_(j)};
E.mE={};E.mE.Am=function(w){var n=w.Pc,W=w.ZD,D=w.G2,j=w.IO,I=w.ty,U=w.Y2,M=w.dP,m=E.GY.uo,O,a,X=0;function l(bK){var h2=new Array(bK);
for(var L=0;L<bK;L++)h2[L]=0;return h2}var A=W.length>>>1,g=l(n.Bm*2),k=l(n.Bm),$=l(n.Bm),C=Date.now();
for(var L=0;L<w.be.length;L++){var f=n.aw6+L,z=n.gA*(U[L*2]+M[L*2]),s=n.gA*(U[L*2+1]+M[L*2+1]);g[f*2]=z;
g[f*2+1]=s;k[f]=z;$[f]=s}n.a5Z.vS(j,n.afZ.uo(g),.01,O,a);for(var L=0;L<n.av$.U9.length;L++){var P=n.av$.U9[L],Z=P[3][3][0],Y=P[0],K=P[3][0],S=P[1]?P[1][3][0]:K;
if(P[1]&&Z>Y)continue;var G=W[Z*2],V=W[Z*2+1],T=W[Y*2],R=W[Y*2+1],x=j[Z*2],v=j[Z*2+1],N=j[Y*2],u=j[Y*2+1],H=j[K*2],F=j[K*2+1],t=j[S*2],o=j[S*2+1],q=[x,v,N,u,H,F];
if(P[1])q.push(t,o);var _=m(n.a9K[X],q),d=_[0],r=_[1],p=1/Math.sqrt(d*d+r*r);d*=p;r*=p;var Q=T-G,B=R-V;
k[X]=d*Q+r*B;$[X]=-r*Q+d*B;X++}var i=new Array(A),c=new Array(A);for(var L=0;L<A;L++){i[L]=I[L*2];c[L]=I[L*2+1]}n.at$.vS(i,n.a6q.uo(k),.5);
n.at$.vS(c,n.a6q.uo($),.5);for(var L=0;L<A;L++){I[L*2]=i[L];I[L*2+1]=c[L]}};E.mE.pj=function(w){var n=w.ZD,W=w.G2,D=w.be,j=E.GY.multiply,I=Date.now(),U=E.OY.If(n,W),M=n.length>>>1,m=0,C=0,r=1e3;
for(var L=0;L<U.U9.length;L++)m+=U.U9[L][1]?.5:1;var l=m+D.length,A=[],g=new E.l2(l*2,M*2),k=new E.l2(l,M),$=[[[-1,0,1,0,0,0],[0,-1,0,1,0,0]],[[-1,0,1,0,0,0,0,0],[0,-1,0,1,0,0,0,0]]],f=[],z=[];
for(var L=0;L<U.U9.length;L++){var s=U.U9[L],O=s[3][3][0],a=s[0],X=s[3][0],P=s[1]?s[1][3][0]:X;if(s[1]&&O>a)continue;
var Z=n[O*2],Y=n[O*2+1],K=n[a*2],S=n[a*2+1],G=n[X*2],V=n[X*2+1],T=n[P*2],R=n[P*2+1],x=[[Z,Y,1,0],[Y,-Z,0,1],[K,S,1,0],[S,-K,0,1],[G,V,1,0],[V,-G,0,1]];
if(s[1])x.push([T,R,1,0],[R,-T,0,1]);var v=E.GY.nJ(x),N=j(linear.invert(j(v,x)),v);N.pop();N.pop();A.push(N);
var u=K-Z,H=S-Y,F=$[s[1]?1:0];F=E.GY.eu(F,j([[u,H],[H,-u]],N));var t=[O*2,O*2+1,a*2,a*2+1,X*2,X*2+1,P*2,P*2+1],o=s[1]?8:6,q=[];
for(var _=0;_<o;_++)q.push([t[_],F[0][_],F[1][_]]);q.sort(function(h2,jX){return h2[0]-jX[0]});for(var d=0;
d<2;d++){for(var _=0;_<o;_++){f[_]=q[_][0];z[_]=q[_][1+d]}g.eM(z,f,o)}if(O<a)k.eM([-1,1],[O,a],2);else k.eM([1,-1],[a,O],2);
C++}for(var L=0;L<D.length;L++){var p=D[L];g.eM([r],[p*2],1);g.eM([r],[p*2+1],1);k.eM([r],[p],1)}var Q=g.nJ(),B=Q.sg(Q),i=k.nJ(),c=i.sg(i);
return{aw6:m,Bm:l,afZ:Q,a5Z:B,a6q:i,at$:c,av$:U,a9K:A,gA:r}};E.mE.ahU=function(w,n,W,D,j){var I=new iB(0,0,n,W),U=E.Q(I.O());
E.hN(w,U,3);E.round(U,70);var M=E.Nb(U,I),m=[.1,.065,.035][D]*Math.max(M.m,M.n),l=j+1,A=n+l*2,g=W+l*2,k=new iB(-l,-l,A,g),$=E.Q(k.O());
E.B0(U,I,$,k);var C=$.slice(0);for(var f=0;f<j;f++){for(var z=1;z<g-1;z++){for(var s=1;s<A-1;s++){var L=z*A+s;
C[L]=$[L-A]|$[L-1]|$[L]|$[L+1]|$[L+A]}}var O=C;C=$;$=O}var a=cf.jo($,A,g,Math.round(M.O()*5e-4)),X=cf.OV(a),P=new eh(1,0,0,1,-l,-l);
for(var L=0;L<X.length;L++){var Z=X[L];E.p.D(Z.path.w,P,Z.path.w);Z.ZD=E.mE.aAa(Z.path);Z.G2=E.p.a1E(Z.ZD);
Z.G2=E.OY.aud(Z.ZD,Z.G2,m)}return X};E.mE.aAa=function(w){var n=[],W=w.w,D=w.F.length-1,j=0,I=0;for(var U=0;
U<D;U++){var L=U*6,M=W[L+6]-W[L+0],m=W[L+7]-W[L+1],l=Math.ceil(Math.sqrt(M*M+m*m));for(var A=0;A<l;A++){var g=A/l,k=1-g,$=k*k*k*W[L+0]+3*k*k*g*W[L+2]+3*k*g*g*W[L+4]+g*g*g*W[L+6],C=k*k*k*W[L+1]+3*k*k*g*W[L+3]+3*k*g*g*W[L+5]+g*g*g*W[L+7];
n.push($,C);j=$;I=C}}n=E.p.TW(n,1);var f=[],z=n.length;for(var L=0;L<z;L+=2){var C=n.pop(),$=n.pop();
f.push($,C)}return f};E.mE.a06=function(w,n,W,D){function j(K,S,G,V,T){var R=T[K*2]-T[S*2],x=T[K*2+1]-T[S*2+1],v=Math.sqrt(R*R+x*x);
if(G[K].indexOf(S)==-1){G[K].push(S);V[K].push(v)}if(G[S].indexOf(K)==-1){G[S].push(K);V[S].push(v)}}var I=w.length>>>1,U=new Array(I);
if(W.length==0){U.fill(0);return U}var M=new Array(I),m=new Array(I);for(var L=0;L<I;L++){M[L]=[];m[L]=[]}for(var L=0;
L<n.length;L+=3){j(n[L],n[L+1],M,m,w);j(n[L],n[L+2],M,m,w);j(n[L+1],n[L+2],M,m,w)}var l=new Float64Array(I*2),A=new Uint32Array(I*2);
l.fill(1e9);var g=new Uint8Array(I);for(var k=0;k<W.length;k++){g.fill(0);var $=["---",[0,W[k]]];while($.length!=1){var C=E.eA.FZ($),f=C[0],z=C[1];
if(g[z]==1)continue;var s=z<<1;if(f<l[s]){l[s+1]=l[s];A[s+1]=A[s];l[s]=f;A[s]=k}else if(f<l[s+1]){l[s+1]=f;
A[s+1]=k}g[z]=1;var O=M[z],a=m[z];for(var L=0;L<O.length;L++){var X=O[L];if(g[X]!=1){E.eA.GV($,[f+a[L],X])}}}}for(var L=0;
L<I;L++){var s=L<<1,P=l[s],Z=l[s+1],Y=1/(P+Z);U[L]=(1-P*Y)*D[A[s]]+(1-Z*Y)*D[A[s+1]]}return U};E.mE.a2w=function(w){var n={F:[],w:[]},W=[w];
while(W.length!=0){var D=W.pop(),j=D.H8;if(D.apq instanceof Array||D.aeK instanceof Array){n.F.push("M","L","L","L","Z");
n.w.push(j[0],j[1],j[2],j[1],j[2],j[3],j[0],j[3])}else W.push(D.apq,D.aeK)}return n};E.mE.mD=function(w,n,W,D,j,I,U,M,m,l){var A=Math.round(l.length/3),g=new Array(A);
for(var L=0;L<A;L++)g[L]=L;g.sort(function($,C){return m[l[$*3]]-m[l[C*3]]});for(var L=0;L<A;L++){var k=g[L]*3;
E.mE.adf(l[k]*2,l[k+1]*2,l[k+2]*2,U,M,w,n,W,D,j,I)}};E.mE.adf=function(w,n,W,D,j,I,U,M,m,l,A){var g=E.mE.CG,k=[w,n,W,1.2,1.2,1.2,0],$=[0,0,0,0],C=j[w],f=j[w+1],z=j[n],s=j[n+1],O=j[W],a=j[W+1],X=Math.max(0,Math.min(U-1,D[w])),P=Math.max(0,Math.min(U-1,D[n])),Z=Math.max(0,Math.min(U-1,D[W])),Y=Math.max(0,Math.min(M-1,D[w+1])),K=Math.max(0,Math.min(M-1,D[n+1])),S=Math.max(0,Math.min(M-1,D[W+1])),G=z-C,V=s-f,T=O-C,R=a-f,x=1/(G*R-T*V+1e-9),v=Math.max(0,Math.floor(Math.min(C,z,O))),N=Math.min(l,Math.ceil(Math.max(C,z,O))),u=Math.max(0,Math.floor(Math.min(f,s,a))),H=Math.min(A,Math.ceil(Math.max(f,s,a)));
for(var F=u;F<H;F++)for(var t=v;t<N;t++){var o=t+.5-C,q=F+.5-f,_=(o*R-T*q)*x,d=(G*q-o*V)*x;if(_>=0&&d>=0&&_+d<=1){var r=1-_-d,p=X*r+P*_+Z*d,Q=Y*r+K*_+S*d;
E.K.kG(p,Q,I,U,M,$);E.mE.aaO($,m,F*l+t<<2)}}};E.mE.aaO=function(w,n,W){var D=n[W],j=n[W+1],I=n[W+2],U=n[W+3],M=1-w[3]*(1/255);
n[W]=~~(.5+w[0]+D*M);n[W+1]=~~(.5+w[1]+j*M);n[W+2]=~~(.5+w[2]+I*M);n[W+3]=~~(.5+w[3]+U*M)};E.mE.CG=function(){var w=function(W,D,j,I){var U=I[0],M=I[1],m=I[2],l=W[U+0],A=W[U+1],g=W[M+0],k=W[M+1],$=W[m+0],C=W[m+1],f=g-l,z=k-A,s=$-l,O=C-A,a=D-l,X=j-A,P=f*O-s*z,Z=1/(P+1e-9),Y=(a*O-s*X)*Z,K=(f*X-a*z)*Z;
if(Y>=0&&K>=0&&Y+K<=1){I[3]=1-Y-K;I[4]=Y;I[5]=K;return 1}return 0},n=function(W,D,j,I){var U=[0,0,0,0,0,0];
for(var L=0;L<D.length;L+=3){U[0]=D[L]*2;U[1]=D[L+1]*2;U[2]=D[L+2]*2;if(w(W,j,I,U)==1)return!0}return!1};
return{ax5:w,aAu:n}}();E.kY={};E.kY.a4P=function(w,n,W){var D=E.Q(n*W*4),j=!1;E.K.pQ(w,n,W,D,[W,n,0,1,0,1,0,0]);
return[E.kY.wo(w,n,W,j),E.kY.wo(D,W,n,j)]};E.kY.D=function(w,n){var W=!1,D=w[0],j=w[1],I=D[1],U=D[2],M=D[3],m=n.m,l=n.n;
if(U==m&&M==l)I=I.slice(0);else if(M!=l){var A=E.Q(U*l*4);E.kY.lh(j,l,A,W);I=E.Q(U*l*4);E.K.pQ(A,l,U,I,[U,l,0,1,0,1,0,0]);
if(U!=m){D=E.kY.wo(I,U,l,W);I=E.Q(m*l*4);E.kY.lh(D,m,I,W)}}else if(U!=m){I=E.Q(m*M*4);E.kY.lh(D,m,I,W)}return I};
E.kY.wo=function(w,n,W,D){var j=Date.now(),I=new Uint16Array(n*W),U=1;E.kY.adv(w,n,W,I);var M=Math.ceil(n/U),m=new Uint32Array(U),l=new Uint32Array(U),M=Math.floor(n/U);
for(var A=0;A<U;A++)l[A]=A<U-1?M:n-(U-1)*M;for(var g=0;g<W;g++){var L=g*n;for(var A=0;A<U;A++){var M=l[A];
for(var k=0;k<M;k++)m[A]+=I[L+k];L+=M}}if(D){console.log(Date.now()-j,"cost");j=Date.now()}var $=new Uint32Array(n),C=new Uint32Array(n),f=new Uint32Array(n*W);
for(var k=0;k<n;k++){f[(W-1)*n+k]=I[(W-1)*n+k]}for(var g=W-2;g>=0;g--){var z=g*n;for(var A=0;A<U;A++){var M=l[A];
f[z]=I[z]+Math.min(f[z+n],f[z+n+1]);for(var k=1;k<M-1;k++){var L=z+k;f[L]=I[L]+Math.min(f[L+n-1],Math.min(f[L+n],f[L+n+1]))}z+=M-1;
f[z]=I[z]+Math.min(f[z+n-1],f[z+n]);z++}}if(D){console.log(Date.now()-j,"Building M");j=Date.now()}function s(V,T){return V<T?V:T}function O(L,V){var T=C[L],R=f[V],x=~~(T*R*1e-4);
return x}var a=new Uint8Array(n*W),X=new Uint32Array(n);for(var L=0;L<n;L++){$[L]=L;C[L]=I[L]}for(var g=1;
g<W;g++){var P=0,z=g*n;for(var A=0;A<U;A++){var M=l[A],L=z;X[P]=O(P,L);var Z=X[P]+O(P+1,L+1),Y=O(P,L+1)+O(P+1,L);
X[P+1]=s(Z,Y);for(var k=2;k<M;k++){var L=z+k,K=X[P+k-1]+O(P+k-1,L-1),S=X[P+k-2]+O(P+k-1,L-2)+O(P+k-2,L-1);
X[P+k]=s(K,S)}var k=M-1;while(k>=2){var L=z+k,K=X[P+k-1]+O(P+k-1,L-1),S=X[P+k-2]+O(P+k-1,L-2)+O(P+k-2,L-1);
if(X[P+k]==K){a[L-n]=1;k-=1}else{a[L-n]=0;a[L-n-1]=2;k-=2}}var L=z;if(k==0){a[L-n]=1}else{if(X[P+1]==Z){a[L+1-n]=1;
a[L-n]=1}else{a[L+1-n]=0;a[L-n]=2}}z+=M;P+=M}E.kY.awN(g,n,a,I,$,C,!0,j)}if(D){console.log(Date.now()-j,"Matching");
j=Date.now()}var G=I;return[UZIP.adler(w,0,w.length),w,n,W,U,l,m,$,C,a,G]};E.kY.lh=function(w,n,W,D){var j=w.slice(0),I=j.shift(),U=j.shift(),M=j.shift(),m=j.shift(),l=j.shift(),A=j.shift(),g=j.shift(),k=j.shift(),$=j.shift().slice(0),C=j.shift(),f=j.shift(),z=Date.now(),s=Math.abs(M-n),O=Math.floor(s/l),a=new Uint32Array(l),P=0,Z=1e9,K=0,S=0,G=0;
for(var X=0;X<l;X++)a[X]=X<l-1?O:s-(l-1)*O;f.fill(0);for(var Y=0;Y<M;Y++){P=Math.max(P,$[Y]);Z=Math.min(Z,$[Y])}for(var X=0;
X<l;X++){var V=A[X],O=a[X];for(var T=0;T<O;T++){var R=0,x=1e9;for(var Y=0;Y<V;Y++)if($[S+Y]<x){x=$[S+Y];
R=S+Y}if(n<M)$[R]=1e9;else $[R]*=1.2;if(G<M/3)K+=x;var v=k[R],N=f[v],u=N<65280?65280:N+1;if(u<65280)throw"e";
for(var H=0;H<m;H++){var L=H*M+v;f[L]=u;v+=C[L]-1}G++}S+=V}if(D){console.log(Date.now()-z,"Removing best seams");
z=Date.now()}function F(L,o){var q=L<<2,_=o<<2;W[q]=U[_];W[q+1]=U[_+1];W[q+2]=U[_+2];W[q+3]=U[_+3]}for(var H=0;
H<m;H++){var t=0,L=H*M;for(var Y=0;Y<n;Y++,t++){if(n<M){while(f[L+t]==65280)t++;F(H*n+Y,H*M+t)}else{F(H*n+Y,H*M+t);
while(f[L+t]>=65280){f[L+t]--;Y++;F(H*n+Y,H*M+t)}}}}if(D){console.log(Date.now()-z,"Shifting image pixels");
z=Date.now()}};E.kY.awN=function(w,n,W,D,j,I){var U=0,L=w*n;while(U<n){if(W[L-n]==1){I[U]=I[U]+D[L];
U++;L++}else{var M=j[U];j[U]=j[U+1];j[U+1]=M;var m=I[U];I[U]=I[U+1]+D[L];I[U+1]=m+D[L+1];U+=2;L+=2}}};
E.kY.adv=function(w,n,W,D){function j(w,L,m){var g=L<<2,k=m<<2,$=w[g]-w[k],C=w[g+1]-w[k+1],f=w[g+2]-w[k+2];
return Math.abs($)+Math.abs(C)+Math.abs(f)}for(var I=1;I<n;I++){var U=j(w,I,I-1);D[I-1]+=U;D[I]+=U}for(var M=1;
M<W;M++){var m=M*n,U=j(w,m,m-n);D[m]+=U;D[m-n]+=U;for(var I=1;I<n;I++){var L=M*n+I,l=j(w,L,L-1),A=j(w,L,L-n);
D[L-n]+=A;D[L-1]+=l;D[L]+=A+l}}for(var M=0;M<W;M++){D[M*n]*=2;D[M*n+n-1]*=2}for(var L=0;L<D.length;L++)if(D[L]==0)D[L]=1};
E.HZ=function(){function w(){return 1953e6+Math.floor(Math.random()*999999)}function n(K,S){var G=S[0]-K[0],V=S[1]-K[1];
return G*G+V*V}function W(K,S,G,V,T,R,x,v){var N=G-K,u=V-S,H=E.p.qI(K,S,N,u,T,R,x-T,v-R),F=[K+H*N,S+H*u],t=H>0?[[[K,S],F,!1,0,1],[[T,R],F,!1,0,5]]:[[[G,V],F,!1,0,1],[[x,v],F,!1,0,5]];
return t}function D(K){K=K.map(Math.round);var S=W(K[0],K[1],K[2],K[3],K[6],K[7],K[4],K[5]),G=W(K[0],K[1],K[6],K[7],K[2],K[3],K[4],K[5]),V=[S,G],T=[S[0][1],G[0][1]];
for(var L=0;L<2;L++){var R=T[1-L],x=V[L];if(n(x[0][0],R)<n(x[1][0],R)){var v=x[0];x[0]=x[1];x[1]=v}}var N=[w(),0,-1,0,[0,0],S[0],S[1],G[0],G[1]];
return N}function j(K){var S=K[5],G=K[8],V=K[6],T=S[0],R=G[0],x=V[0],v=S[1],N=G[1],u=R[0],H=R[1],F=N[0]-u,t=N[1]-H,o=E.p.qI(u,H,F,t,x[0],x[1],v[0]-x[0],v[1]-x[1]);
return[T[0],T[1],u,H,u+o*F,H+o*t,x[0],x[1]]}function I(K,S){return K[0]==S[0]&&K[1]==S[1]}function U(K){return{1:0,5:1,7:2,3:3}[K]}function M(K,S,G){var V=S[5+U(K)],T=V[1],R=V[0][0]-T[0],x=V[0][1]-T[1],v=Math.sqrt(R*R+x*x);
R/=v;x/=v;for(var N=0;N<G.length;N++){var u=G[N];if(u[0]!=S[1]&&u[1]!=S[0])continue;for(var L=0;L<4;
L++){var H=u[5+L],F=H[0];if(!I(T,H[1]))continue;var t=F[0]-T[0],o=F[1]-T[1];v=Math.sqrt(t*t+o*o);t/=v;
o/=v;var q=t*R+o*x;if(Math.abs(q-1)<1e-7)return!0}}return!1}function m(K,S){return[50,50,600,600]}function l(K,S){E.K.D(K,S);
return S}function A(K){var S=[];for(var G=0;G<K.length;G++){var V=K[G],T=V[1];for(var R=0;R<T.length;
R++){var x=T[R],v=[],N=E.K.kN(j(x),new iB(0,0,1,1));for(var L=1;L<=7;L+=2){v[L]=M(L,x,T)}if(!v[1]){if(!v[7])S.push([l(N,[0,0]),G,R,0]);
S.push([l(N,[.5,0]),G,R,1])}if(!v[3]){if(!v[1])S.push([l(N,[1,0]),G,R,2]);S.push([l(N,[1,.5]),G,R,3])}if(!v[5]){if(!v[3])S.push([l(N,[1,1]),G,R,4]);
S.push([l(N,[.5,1]),G,R,5])}if(!v[7]){if(!v[5])S.push([l(N,[0,1]),G,R,6]);S.push([l(N,[0,.5]),G,R,7])}}}return S}function g(K){var S=K.length-2,G=0;
for(var L=0;L<S;L+=2)G+=(K[L+2]-K[L])*(K[L+1]+K[L+3]);G+=(K[0]-K[S])*(K[S+1]+K[1]);return-G*.5}function k(K){function S(u,H,F,t){var o=l(u,[H,F]);
o.push(t);return o}var G=[];for(var V=0;V<K.length;V++){var T=K[V],R=T[1];for(var x=0;x<R.length;x++){var v=R[x],N=j(v),u=E.K.kN(N,new iB(0,0,1,1));
G.push(S(u,.5,0,1));G.push(S(u,1,.5,3));G.push(S(u,.5,1,5));G.push(S(u,0,.5,7));G.push(S(u,.5,.5,x*Math.sign(g(N))))}}return G}function $(K,S,G){var V=G[0],T=G[1],R=S.x-K[0],x=S.y-K[1],v=E.p.qI(K[0],K[1],R,x,T[0],T[1],V[0]-T[0],V[1]-T[1]);
return[K[0]+v*R,K[1]+v*x]}function C(K,S,G){K=JSON.parse(JSON.stringify(K));var V=K[S[1]][1][S[2]],T=S[3];
if((T&1)==0)return K;T=U(T);if(T==0||T==2){var R=V[5+T],x=V[5+2-T],v=V[5+(T==0?3:1)],N=R[1];R[0]=x[0]=$(N,G,x);
v[0]=$(N,G,v)}else{var v=V[5+T],N=v[1],R=V[5+(T==3?0:2)];v[0]=$(N,G,R)}return K}function f(K,S,G){var V=S[0]-K[0],T=S[1]-K[1],R=E.p.qI(G[0],G[1],-T,V,K[0],K[1],V,T);
return[G[0]-T*R,G[1]+V*R]}function z(K,S,G){var V=G[0],T=G[1],l=f(K,S,G),R=l[0],x=l[1],v=f(K,G,S),N=E.p.qI(R,x,V-R,T-x,S[0],S[1],v[0]-S[0],v[1]-S[1]);
return[R+(V-R)*N,x+(T-x)*N]}function s(K,S,G){K=JSON.parse(JSON.stringify(K));var V=K[S[1]][1][S[2]],T=S[3],R=S[4];
if(R==1)return K;var x=V[5][1],v=V[7][1],N=z(x,v,G),u=JSON.parse(JSON.stringify(V));K[S[1]][1].push(u);
u[0]=w();u[1]=V[0];if(T==0||T==1){u[7][1]=u[8][1]=N;if(T==1){u[5][0]=u[7][0]=V[6][0];u[8][0]=j(V).slice(0,2)}}else{u[5][1]=u[6][1]=N;
if(T==3){u[5][0]=u[7][0]=V[8][0];u[6][0]=j(V).slice(0,2)}}return K}function O(K,S,G){var bK=K.length>>1,V,T=K[2*bK-3]-G,R=K[2*bK-2]-S,x=K[2*bK-1]-G,v=!1,N=0;
for(var L=0;L<bK;L++){V=R;T=x;R=K[2*L]-S;x=K[2*L+1]-G;if(T==x)continue;v=x>T}for(var L=0;L<bK;L++){V=R;
T=x;R=K[2*L]-S;x=K[2*L+1]-G;if(T<0&&x<0)continue;if(T>0&&x>0)continue;if(V<0&&R<0)continue;if(T==x&&Math.min(V,R)<=0)return!0;
if(T==x)continue;var u=V+(R-V)*-T/(x-T);if(u==0)return!0;if(u>0)N++;if(T==0&&v&&x>T)N--;if(T==0&&!v&&x<T)N--;
v=x>T}return(N&1)==1}function a(K,S,G){for(var V=0;V<K.length;V++){var T=K[V][1];for(var R=0;R<T.length;
R++){var x=j(T[R]);if(O(x,S,G))return[V,R]}}}function X(K,S){for(var G=0;G<K.length;G++){var V=K[G][1],T=S[G];
if(T.length==0)continue;var R=P(V,T);for(var x=0;x<V.length;x++){if(R.indexOf(V[x][0])!=-1){V.splice(x,1);
x--}}}for(var G=0;G<K.length;G++)if(K[G][1].length==0){K.splice(G,1);G--}return K}function P(K,S){var G=[];
for(var L=0;L<10;L++)for(var V=0;V<K.length;V++){var T=K[V];if(S.indexOf(V)!=-1||G.indexOf(T[1])!=-1)if(G.indexOf(T[0])==-1)G.push(T[0])}return G}function Z(K){var S=J.sv(K,0,K.length),G=S.split("\n").slice(1);
function V(){return parseFloat(G.shift())}function T(){var jX=[V(),V()];R(1);return jX}function R(bK){for(var L=0;
L<bK;L++)G.shift()}var x=[],v=V();for(var N=0;N<v;N++){var u=V(),H=V(),F=[];x.push([u,F]);for(var t=0;
t<H;t++){var o=V(),q=V(),_=V(),d=V(),r=T(),p=[o,q,_,d,r];F.push(p);for(var L=0;L<4;L++){var Q=T(),B=T(),i=V()==1,c=V(),h2=V();
p.push([Q,B,i,c,h2])}}}return x}function Y(K){function S(H){G.push(H[0],H[1],"")}var G=["tNaF203"];G.push(K.length);
for(var V=0;V<K.length;V++){G.push(K[V][0]);var T=K[V][1];G.push(T.length);for(var R=0;R<T.length;R++){var x=T[R];
G.push(x[0],x[1],x[2],x[3]);S(x[4]);for(var L=0;L<4;L++){var v=x[5+L];S(v[0]);S(v[1]);G.push(v[2]?1:0,v[3],v[4])}}}var N=G.join("\n"),u=new Uint8Array(N.length);
J.Jm(u,0,N);return u}return{ew:Z,Pj:Y,a4B:j,aqD:D,W2:A,avm:C,kU:k,avp:function(K,S){return S&&(S[3]&1)==0&&K[S[1]][1].length==1},agc:function(K,S){return S&&(S[3]&1)==1},a1m:m,agW:s,akc:X,lS:P,awR:a}}();
E.XY=function(){var w=0,n=0,D=15,I=256;function W(A,g,k,$,C,f){var z=(C-1)*g,s=f*g;return A[s+$]-A[s+k-1]-A[z+$]+A[z+k-1]}var j=Math.round(D/8),U=[];
function M(A,g){for(var k=0;k<g.length;k++){var $=g[k],C=0,f=0,z=A[$.wl],s=z.w3,O=z.gA,a=z.ag;for(var X=-D;
X<=D;X++)for(var P=-D;P<=D;P++){var Z=P+$.ax0,Y=X+$.adt;if(P*P+X*X>D*D||Z<0||Y<0||Z>=O||Y>=O)continue;
var K=s[Y*O+Z];C+=P*K;f+=X*K}$.kI=Math.atan2(f,C)}}function m(A,g,k,$,C){var f=~~(A+.5),z=~~(g+.5);return W(k,$,f-j,f+j,z-j,z+j)}function l(A,g,k,$,C){w=$;
n=C;if(U.length==0){var f=new E.s.my(16200817),a=8,X=0;function z(h2){var G=h2[0]-h2[2],V=h2[1]-h2[3];
return G*G+V*V}function s(){var h2=0,jX=0;while(h2===0)h2=f.get();while(jX===0)jX=f.get();return Math.sqrt(-2*Math.log(h2))*Math.cos(2*Math.PI*jX)}var O=s,P=[];
while(X!=I){var Z=Math.max(-D,Math.min(D,O()*a)),Y=Math.max(-D,Math.min(D,O()*a)),K=Math.max(-D,Math.min(D,O()*a)),S=Math.max(-D,Math.min(D,O()*a)),G=Z-K,V=Y-S,T=Math.sqrt(G*G+V*V);
if(T<3||T>12)continue;U.push(Z,Y,K,S);X++}}var R=20;for(var x=0;x<g.length;x++){var v=g[x],N=A[v.wl],u=N.mu,k=N.w3,$=N.gA,C=N.ag,H=v.ax0,F=v.adt,t=v.kI,o=Math.cos(t),q=Math.sin(t),_=new Uint8Array(I>>>3);
v.E3=_;for(var L=0;L<I;L++){var d=L*4,Z=U[d+0],Y=U[d+1],K=U[d+2],S=U[d+3],r=o*Z-q*Y,p=q*Z+o*Y,Q=o*K-q*S,B=q*K+o*S,i=m(H+r,F+p,u,$,C),c=m(H+Q,F+B,u,$,C);
_[L>>>3]|=(i<c?0:1)<<(L&7)}}}return{aqq:M,anM:l}}();E.a9s=function(){function w(n,W){var D=[[9]],j=Date.now(),I=[];
for(var U=0;U<n.length;U++){var M=n[U],m=M.mu,l=M.gA,A=M.ag,$=9,a=1,v=24;if(m==null)continue;var g=new Float32Array(l*A),k=new Uint8Array(l*A),C=$>>>1,f=C>>>1,z=Math.round($/3);
if(z!=$/3)throw"e";var s=1/($*$),O=1.2*($/9);for(var X=C+1;X<A-C;X+=a)for(var P=C+1;P<l-C;P+=a){var Z=E.MM(m,l,P-f,P+f,X-C,X+C)-3*E.MM(m,l,P-f,P+f,X-C+z,X+C-z),Y=E.MM(m,l,P-C,P+C,X-f,X+f)-3*E.MM(m,l,P-C+z,P+C-z,X-f,X+f),K=P-C+1,S=P+C-1,G=X-C+1,V=X+C-1,T=E.MM(m,l,K,P-1,G,X-1)+E.MM(m,l,P+1,S,X+1,V)-E.MM(m,l,P+1,S,G,X-1)-E.MM(m,l,K,P-1,X+1,V),R=(Y*Z-.9*T*(.9*T))*(s*s);
g[X*l+P]=Math.abs(R);k[X*l+P]=R<0?0:1}var x=l*a;for(var X=v;X<A-v;X+=a)for(var P=v;P<l-v;P+=a){var L=X*l+P,N=g[L];
if(N<16)continue;if(g[L-a]>=N||g[L+a]>=N)continue;if(g[L-x-a]>=N||g[L-x]>=N||g[L-x+a]>=N)continue;if(g[L+x-a]>=N||g[L+x]>=N||g[L+x+a]>=N)continue;
I.push({x:~~(P*M.dI+.5),y:~~(X*M.dI+.5),ax0:P,adt:X,wl:U,Z:N,air:k[L],_6:O})}}if(W!=null){I.sort(function(d,r){return r.Z-d.Z});
I=I.slice(0,W)}return I;var u=[];for(var L=0;L<I.length;L++){var H=!0,F=I[L];for(var t=0;t<I.length;
t++){var o=I[t];if(t!=L&&o.Z>F.Z&&(o.wl==F.wl+1||o.wl==F.wl-1)){var q=F.x-o.x,_=F.y-o.y;if(q*q+_*_<5){H=!1;
break}}}if(H)u.push(F)}console.log(I.length,u.length);return u}return{a13:w}}();E.bi={};E.bi.avb=function(w){var n=w.length,W=E.bi.IT(w,!1),j=0,I=1;
throw"e";var D=[];for(var L=0;L<n;L++)D[L]=E.bi.Ru(W[L]);var U=w[0][1],M=E.bi.match(W[j],W[I],D[I]);
console.log(M.length);var m=Math.max(Math.min(M.length,40),M.length*.54);m=Math.min(m,200);var l=M.slice(0,m),A=E.me.axF(W[j],W[I],l,U.m,U.n),g=E.me.and(A,[0,0,0],1),k=U.m/2,$=U.n/2,C=1/Math.max(k,$);
for(var L=0;L<1;L++){var f=l[L],z=W[j][f[0]],s=W[I][f[1]],O=E.me.as3(g,C*(z.x-k),C*(z.y-$),C*(s.x-k),C*(s.y-$))}var a=E.me.ael(A,U),X=[];
for(var L=0;L<2;L++){var P=a[L],Z=[P[0][0],P[0][1],P[0][2],P[1][0],P[1][1],P[1][2],P[2][0],P[2][1]],Y=y.wR.z3(w[L],null,Z);
X.push([Y.buffer,Y.rect])}return[E.bi.anB(X[0],X[1],W[j],W[I],l,A,a,U)]};E.bi.SR=function(w,n){var W=w.length,D=!1,j=Date.now(),I=E.bi.IT(w,!1,1e4);
if(D)console.log("Descriptors ready",Date.now()-j);j=Date.now();for(var L=0;L<W;L++){var U=w[L][1];for(var M=0;
M<I[L].length;M++){I[L][M].x+=U.x;I[L][M].y+=U.y}}if(D)console.log("shifted",Date.now()-j);j=Date.now();
var m=[];for(var L=0;L<W;L++)m[L]=E.bi.Ru(I[L]);if(D)console.log("trees built",Date.now()-j);j=Date.now();
var l=[];for(var L=0;L<W-1;L++)for(var M=L+1;M<W;M++){var A=E.bi.match(I[L],I[M],m[M]);if(D)console.log("Matches found",L,M,A.length);
A=A.slice(0,A.length>>>1);if(A.length<10)return null;var g=E.bi.ams(I[L],I[M],A,2);l.push([L,M,A,g])}l.sort(function(S,G){return G[2].length-S[2].length});
if(D)console.log("Matches found",Date.now()-j);j=Date.now();var k=[],$=new UnionFind(W);for(var L=0;
L<l.length;L++){var C=l[L],f=$.find(C[0]),z=$.find(C[1]);if(f!=z){k.push(C);$.link(f,z)}}var s=[];for(var L=0;
L<W;L++)s[L]=[1,0,0,0,1,0,0,0];var O=[0],a=new Uint8Array(W);a[O[0]]=1;while(O.length!=0){var z=O.pop(),g=s[z],X=[];
for(var L=0;L<k.length;L++){var C=k[L],P=C[0],Z=C[1];if(P==z&&a[Z]==0){s[Z]=E.K.y9(g,C[3]);O.push(Z);
a[Z]=1}if(Z==z&&a[P]==0){s[P]=E.K.y9(g,E.K.Ba(C[3]));O.push(P);a[P]=1}}}if(n==null){var Y=[];for(var L=0;
L<W;L++)Y.push([s[L][2],L]);Y.sort(function(S,G){return S[0]-G[0]});n=Y[Y.length>>>1][1]}var K=E.K.Ba(s[n]);
for(var L=0;L<W;L++)s[L]=E.K.y9(s[L],K);if(D)console.log("Transforms reordered",Date.now()-j);j=Date.now();
return s};E.bi.IT=function(w,n,W){var D=[],j=!1;for(var L=0;L<w.length;L++){var I=w[L][0],U=w[L][1],M=U.m,m=U.n,l=E.Q(U.O());
E.fo(I,l);var A=Date.now(),g=E.bi.alJ(l,U,!0);if(j)console.log("Pyramid built ---------------",Date.now()-A);
A=Date.now();var k=E.a9s.a13(g,W);if(j)console.log("SURF Generation",Date.now()-A);A=Date.now();if(!n){E.XY.aqq(g,k);
if(j)console.log("ORB Orientations",Date.now()-A);A=Date.now();E.XY.anM(g,k,l,M,m);if(j)console.log("ORB Descriptors",Date.now()-A);
A=Date.now()}D.push(k)}return D};E.bi.alJ=function(w,n,W){var D=[],j=[w,n];E.BB(j);if(W){var I=E.MQ(w,n),U=I.rect,M=[I.Q0,U];
E.BB(M)}for(var L=0;L<j.length;L++){var m=j[2*L],l=j[2*L+1],A=l.m,g=l.n,k=Math.min(A,g);if(k<30)break;
if(k<1600)D.push({w3:m,gA:A,ag:g,dI:1<<L,mu:E.Wt(m,A,g)});if(!W)continue;var m=M[2*L],l=M[2*L+1],A=l.m,g=l.n,k=Math.min(A,g);
if(k<30)break;if(k<1600)D.push({w3:m,gA:A,ag:g,dI:(1<<L)*3/2,mu:E.Wt(m,A,g)})}return D};E.bi.ams=function(w,n,W,D){var j=Date.now(),I,U=0,M=0,m=W.length,l=new Float64Array(2);
for(var A=0;A<3e3;A++){var g=~~(Math.random()*m),k=~~(Math.random()*m),$=~~(Math.random()*m),C=~~(Math.random()*m),x=0,v=0;
if(g==k||g==$||g==C||k==$||k==C||$==C)continue;var f=W[g],z=W[k],s=W[$],O=W[C],a=w[f[0]],X=n[f[1]],P=w[z[0]],Z=n[z[1]],Y=w[s[0]],K=n[s[1]],S=w[O[0]],G=n[O[1]],V=[a.x,a.y,P.x,P.y,Y.x,Y.y,S.x,S.y],T=[X.x,X.y,Z.x,Z.y,K.x,K.y,G.x,G.y],R=E.K.tQ(V,T);
if(R[0]==0&&R[1]==0&&R[3]==0&&R[4]==0)continue;var N=m-U+2;for(var L=0;L<m&&L-x<N;L++){var u=w[W[L][0]],H=n[W[L][1]];
E.K.EQ(H.x,H.y,R,l);var F=l[0]-u.x,t=l[1]-u.y,o=F*F+t*t;if(o<D){x++;v+=o}}if(x>U||x==U&&v<M){I=R;U=x;
M=v}}return I};var b3=new Uint8Array(256);for(var L=0;L<256;L++){var dN=0,bK=L;while(bK!=0){bK=bK&bK-1;
dN++}b3[L]=dN}E.bi.ahF=function(w,n,W){var D=0,j=w.length;for(var L=0;L<j&&D<W;L++)D+=b3[w[L]^n[L]];
return D};E.bi.ac7=function(w,n,W,top,D){if(D[W]==1)return;var j=E.bi.ahF(w.E3,n.E3,top[0]);if(j<top[0]){if(j<top[2]){top[0]=top[2];
top[1]=top[3];top[2]=j;top[3]=W}else{top[0]=j;top[1]=W}}D[W]=1};E.bi.Ru=function(w){var n=[],W=[],D=[[],[]],j=4;
for(var L=0;L<w.length;L++)(w[L].air==0?n:W).push(L);for(var I=0;I<2;I++){var U=new Array(j),M=[],m=I==0?n:W,l=m.length/256,A=[];
for(var g=0;g<32;g++){var k=new Array(256),f=0;for(var $=0;$<256;$++)k[$]=[];for(var $=0;$<m.length;
$++){var C=m[$];k[w[C].E3[g]].push(C)}for(var $=0;$<256;$++)f+=Math.abs(k[$].length-l);A.push([f,g,k])}A.sort(function(z,s){return z[0]-s[0]});
var M=[],U=[];D[I]=[M,U];for(var L=0;L<j;L++){M.push(A[L][1]);U.push(A[L][2])}}return D};E.bi.match=function(w,n,W){var D=[],j=new Uint16Array(n.length);
j.fill(65535);var I=new Uint8Array(n.length),top=new Uint32Array(4),U=[];for(var M=0;M<w.length;M++){var m=w[M],l=m.E3;
top.fill(1e6);I.fill(0);var A=W[m.air];for(var g=0;g<A[1].length;g++){var k=A[1][g][l[A[0][g]]];for(var $=0;
$<k.length;$++){var C=k[$];E.bi.ac7(m,n[C],C,top,I)}}if(top[2]<50&&top[2]<top[0]*.5){var f=j[top[3]];
if(f==65535){j[top[3]]=D.length;D.push([M,top[3],top[2]])}else if(top[2]<D[f][2]){D[f]=[M,top[3],top[2]]}}}D.sort(function(z,s){return z[2]-s[2]});
return D};E.bi.a72=function(w){var n=new iB;for(var L=0;L<w.length;L++)n=n.x0(w[L][1]);var W=E.Q(n.O()*4);
for(var L=0;L<w.length;L++)E.s._U("norm",w[L][0],w[L][1],W,n,n,1);return[W,n]};E.bi.anB=function(w,n,W,D,j,I,U,M){var m=w[1].clone(),l=m.clone();
m.x=m.y=0;var A=n[1].clone(),g=A.clone();A.x=A.y=0;A.x=m.m;var k=m.x0(A),$=g.y-l.y,C=E.Q(k.O()*4);E.Cb(w[0],m,C,k);
E.Cb(n[0],new iB(A.x,A.y+$,A.m,A.n),C,k);var f=document.createElement("canvas");f.width=k.m;f.height=k.n;
var z=f.getContext("2d");z.lineWidth=.5;z.putImageData(new ImageData(new Uint8ClampedArray(C.buffer),k.m,k.n),0,0);
if(I){var s=I[0],O=E.GY.nJ(s),a=m.m,X=M.m;for(var L=0;L<j.length;L++){var P=j[L],w=W[P[0]],n=D[P[1]];
z.strokeStyle="#"+"ff0000";z.beginPath();var Z=E.me.au3(O,U[0],n,0,X),Y=E.me.au3(s,U[1],w,0,X);z.moveTo(-l.x+Z[0],-l.y+Z[1]);
z.lineTo(-l.x+Z[2],-l.y+Z[3]);z.moveTo(a-g.x+Y[0],-g.y+$+Y[1]);z.lineTo(a-g.x+Y[2],-g.y+$+Y[3]);z.stroke()}}if(j){var K=j.length;
for(var L=0;L<K;L++){var P=j[L],w=W[P[0]],n=D[P[1]];z.strokeStyle="#"+"ffff00"}}var S=new Uint8Array(z.getImageData(0,0,k.m,k.n).data.buffer);
if(!1){for(var G=0;G<2;G++){var V=G==0?W:D,T=G*m.m;for(var L=0;L<V.length;L++){var R=V[L],x=~~R.x,v=~~R.y,N=(v*k.m+x+T)*4;
S[N+1]=S[N+2]=R.acj*60;S[N+0]=0;S[N+3]=255}}}return[S,k]};E.stack={};E.stack.stack=function(w,n,W){var D=w.length,j=n.length;
if(D==1){n.set(w[0]);return}if(W=="avrg"||W=="stdv"||W=="summ"||W=="vari"){var I=1/D;for(var L=0;L<j;
L++){var U=0;for(var M=0;M<D;M++)U+=w[M][L];var m=~~(U*I+.5);if(W=="avrg"||(L&3)==3)n[L]=m;else if(W=="summ")n[L]=255*Math.pow(Math.min(255,U)*(1/255),1/2.4);
else{var l=0;for(var M=0;M<D;M++){var A=w[M][L]-m;l+=A*A}var g=Math.sqrt(l*I)*(1/255);if(W=="stdv")n[L]=255*Math.pow(g,1/2.4);
else n[L]=255*Math.pow(g*g,1/2.4)}}}else if(W=="maxx"){for(var L=0;L<j;L++){var k=0;for(var M=0;M<D;
M++)k=Math.max(k,w[M][L]);n[L]=k}}else if(W=="minn"){for(var L=0;L<j;L++){var k=255;for(var M=0;M<D;
M++)k=Math.min(k,w[M][L]);n[L]=k}}else if(W=="medn"||W=="rang"){var $=function(s,O){return s-O},C=new Array(D),f=0,z=0;
if((D&1)==0){z=D>>>1;f=z-1}else{f=z=D>>>1}for(var L=0;L<j;L++){for(var M=0;M<D;M++)C[M]=w[M][L];C.sort($);
if(W=="medn")n[L]=C[f]+C[z]>>>1;else n[L]=(L&3)==3?C[D-1]:C[D-1]-C[0]}}else console.log(W)};E.gq={};
E.gq.atE=function(w,n,W,D){var j=Date.now(),I=new Uint32Array(n*W),U=new Uint8Array(n*W);while(!0){U.fill(0);
I.fill(0);var M=[],m=0;for(var l=0;l<W;l++){for(var A=0;A<n;A++){var L=l*n+A;if(U[L]==0){var g=M.length,k=E.gq.dM(w,n,W,A,l,U,I,g);
M.push([g,A,l,k[0],k[1],w[L]]);if(k[0]<D)m++}}}if(m==0)break;var $=M.length,C=new UnionFind($),f=[];
for(var L=0;L<$;L++)f.push([]);for(var L=0;L<$;L++){var k=M[L],z=k[4],s=0,O=0;if(k[3]>=D)continue;var g=k[0];
for(var a=0;a<z.length;a+=2){var X=I[z[a+1]*n+z[a]],P=M[X];if(P[3]>O){O=P[3];s=X}}if(C.find(g)!=C.find(s)){C.link(g,s);
f[g].push(s);f[s].push(g)}}var Z=new Uint32Array($);Z.fill(4294967295);var Y=new Uint32Array($);for(var L=0;
L<$;L++){if(Z[L]!=4294967295||f[L].length==0)continue;var K=[L],S=[L],G=L,V=M[L][3];while(S.length!=0){var T=S.pop(),R=f[T];
for(var a=0;a<R.length;a++){var x=R[a];if(K.indexOf(x)==-1){K.push(x);S.push(x);var v=M[x];if(v[3]>V){V=v[3];
G=x}}}}for(var a=0;a<K.length;a++){Z[K[a]]=G;var N=M[G];Y[K[a]]=w[N[2]*n+N[1]]}}for(var l=0;l<W;l++)for(var A=0;
A<n;A++){var L=l*n+A,u=Z[I[L]];if(u!=4294967295)w[L]=Y[u]}}};E.gq.dM=function(w,n,W,D,j,I,U,M){var m=[D,j],l=w[j*n+D],A=0,g=[];
I[j*n+D]=1;while(m.length!=0){var k=m.pop(),$=m.pop(),L=k*n+$;U[L]=M;A++;if(k!=W-1)if(w[L+n]==l){if(I[L+n]==0){m.push($,k+1);
I[L+n]=1}}else g.push($,k+1);if(k!=0)if(w[L-n]==l){if(I[L-n]==0){m.push($,k-1);I[L-n]=1}}else g.push($,k-1);
if($!=n-1)if(w[L+1]==l){if(I[L+1]==0){m.push($+1,k);I[L+1]=1}}else g.push($+1,k);if($!=0)if(w[L-1]==l){if(I[L-1]==0){m.push($-1,k);
I[L-1]=1}}else g.push($-1,k)}return[A,g]};E.gq.a4k=function(w,n,W,D,j){var I=E.gq.FN(w.buffer,n,W).mR,U=Date.now(),M=[];
for(var L=0;L<I.length;L++){var m=I[L],l=1;for(var A=0;A<l;A++)M.push(m.Cj)}var g=new Uint32Array(M),k=UPNG.quantize.getKDtree(new Uint8Array(g.buffer),D),$=[n,1,-n,-1,n+1,-n+1,-n-1,n-1,n+n,2,-n-n,-2,n+n-1,n+n+1,n+2,-n+2,-n-n+1,-n-n-1,-n-2,n-2,n+n+2,-n-n+2-n-n-2,n+n-2],C=new Uint8Array(n*W),f=w;
for(var z=0;z<W;z++)for(var s=0;s<n;s++){var L=z*n+s<<2,O=f[L]*(1/255),a=f[L+1]*(1/255),X=f[L+2]*(1/255),P=f[L+3]*(1/255),Z=E.gq.Ui(k,O,a,X,P,j);
if(Z==null){var Y=[],K=0;while(K<20){var S=z*n+s+$[K]<<2,G=f[S]*(1/255),V=f[S+1]*(1/255),T=f[S+2]*(1/255),R=f[S+3]*(1/255),x=E.gq.Ui(k,G,V,T,R,.005);
if(x!=null){if(Y.indexOf(x)==-1){Y.push(x);x.K$=1}else x.K$++}K++}Y.sort(function(P,X){return X.K$-P.K$});
while(Y.length!=0&&Y[Y.length-1].K$<3)Y.pop();if(Y.length==0)Z=E.gq.Ui(k,O,a,X,P,100);else if(Y.length==1)Z=Y[0];
else if(Y.length==2){var v=Y[0],N=Y[1],u=v.est.q,H=N.est.q,F=H[0]-u[0],t=H[1]-u[1],o=H[2]-u[2],q=H[3]-u[3],_=O-u[0],d=a-u[1],r=X-u[2],p=P-u[3],Q=F*F+t*t+o*o+q*q,B=_*_+d*d+r*r+p*p,i=(_*F+d*t+r*o+p*q)/Q,c=B-i*i*Q;
if(c<.5)Z=i<.5?v:N;else{Z=E.gq.Ui(k,O,a,X,P,100)}}else{var v=Y[0],N=Y[1],h2=Y[2],u=v.est.q,H=N.est.q,jX=h2.est.q,bm=u[0]-jX[0],dC=u[1]-jX[1],fn=u[2]-jX[2],fK=u[3]-jX[3],i6=H[0]-jX[0],dh=H[1]-jX[1],kA=H[2]-jX[2],ig=H[3]-jX[3],iJ=jX[0]-O,fL=jX[1]-a,fB=jX[2]-X,ah=jX[3]-P,eS=bm*bm+dC*dC+fn*fn+fK*fK,gL=bm*i6+dC*dh+fn*kA+fK*ig,e_=iJ*bm+fL*dC+fB*fn+ah*fK,c2=bm*i6+dC*dh+fn*kA+fK*ig,jS=i6*i6+dh*dh+kA*kA+ig*ig,ie=iJ*i6+fL*dh+fB*kA+ah*ig,as=1/(gL*c2-eS*jS),i=(jS*e_-ie*gL)*as,gb=(ie*eS-e_*c2)*as,gx=1-i-gb,eo=Math.max(i,gb,gx);
if(eo==i)Z=v;else if(eo==gb)Z=N;else Z=h2}}C[L>>2]=Z.ind}return{G2:C,mR:k[1]}};E.gq.FN=function(w,n,W){var D=[],j={},I=n-1,U=W-1,M=0,m=new Uint32Array(w),l=[-n-1,-n,-n+1,-1,1,n-1,n,n+1,n+n,2,-n-n,-2,n+n-1,n+n+1,n+2,-n+2,-n-n+1,-n-n-1,-n-2,n-2,n+n+2,-n-n+2-n-n-2,n+n-2];
for(var A=1;A<U;A++)for(var g=1;g<I;g++){var k=A*n+g,$=m[k],C=!0;for(var L=0;L<8;L++)C=C&&m[k+l[L]]==$;
if(C){M++;var f=j[$];if(f==null){j[$]=D.length;D.push({Cj:$,r1:1})}else D[f].r1++}}return{mR:D,asz:M}};
E.gq.Ui=function(w,n,W,D,j,I){var U=UPNG.quantize.getNearest(w[0],n,W,D,j);return E.gq.a7n(U,n,W,D,j)<I?U:null};
E.gq.a7n=function(w,n,W,D,j){var I=w.est.q,U=n-I[0],M=W-I[1],m=D-I[2],l=j-I[3];return U*U+M*M+m*m+l*l};
E.gq.pV=function(){function w(s,O,a,X,P,Z){var Y=[],K=Z,S=Z,G=Z>>>2;for(var V=0;V<P;V++)for(var T=0;
T<X;T++){var R=~~((T+.5)*K),x=~~((V+.5)*S),v=1e9,N=Math.max(0,R-G),u=Math.min(O,R+G+1),H=Math.max(0,x-G),F=Math.min(a,x+G+1);
for(var t=H;t<F;t++)for(var o=N;o<u;o++){var q=n(s,O,o,t);if(q<v){R=o;x=t;v=q}}var _=(x*O+R)*4;Y.push(R,x)}return Y}function n(s,O,a,X){var P=(X*O+a)*4,Z=O*4,Y=W(s,P-4,P)+W(s,P,P+4),K=W(s,P-Z,P)+W(s,P,P+Z);
return Y+K}function W(s,O,a){var X=s[O]-s[a],P=s[O+1]-s[a+1],Z=s[O+2]-s[a+2];return X*X+P*P+Z*Z}var D=0,j=0;
function I(s,O,a,X){j++;if(X<D)D=X;s[X].push(O,a)}function U(s){j--;while(s[D].length==0)D++}function M(s,O,a,X,P){D=0;
j=0;var Z=O*a,Y=Math.round(Math.min(O,a)/(X?X:50)),N=0,u=16;if(Y==0)Y=1;var K=(P?P:30)/Y,S=Math.floor(O/Y),G=Math.floor(a/Y),V=new Uint16Array(Z);
for(var L=0;L<Z;L++)V[L]=65535;var T=w(s,O,a,S,G,Y),R=T.length>>>1;if(R>65535)throw R;var x=[];for(var L=0;
L<1e3+a;L++)x.push([]);var v=[0,1,0,-1,-1,0,1,0],H=Math.min(G,5),F=new Uint32Array(R*6);for(var t=0;
t<G;t+=H){var o=Math.min(t+H+1,G);for(var q=t;q<o;q++)for(var _=0;_<S;_++){var L=q*S+_,d=L*2,r=T[d+1]<<16|T[d];
I(x,r,L,T[d+1]>>>u)}var p=Math.min(a,o*Y);if(t+H>=G)p=a;while(j!=0){U(x);var Q=x[D].pop(),B=x[D].pop(),i=B>>>16,c=B&65535,L=i*O+c;
if(V[L]==65535){var h2=Q*6,jX=L<<2;V[L]=Q;F[h2]+=s[jX];F[h2+1]+=s[jX+1];F[h2+2]+=s[jX+2];F[h2+3]+=c;
F[h2+4]+=i;F[h2+5]++;var bm=i>>>u;if(i!=p-1&&V[L+O]==65535)I(x,i+1<<16|c,Q,m(s,O,K,c,i+1,F,h2)+bm);if(i!=0&&V[L-O]==65535)I(x,i-1<<16|c,Q,m(s,O,K,c,i-1,F,h2)+bm);
if(c!=0&&V[L-1]==65535)I(x,i<<16|c-1,Q,m(s,O,K,c-1,i,F,h2)+bm);if(c!=O-1&&V[L+1]==65535)I(x,i<<16|c+1,Q,m(s,O,K,c+1,i,F,h2)+bm)}}if(p!=i){var dC=(t+H)*S;
F.fill(0,dC*6,(dC+S)*6);for(var i=(t+H-2)*Y;i<p;i++)for(var c=0;c<O;c++){var L=i*O+c;if(V[L]>=dC){V[L]=65535}}}}return{G2:V,M$:R,pP:F}}E.gq.YT=function(s,O,a,X,P){var Z=s.M$,Y=O*a,K=s.pP,S=s.G2,G=$(X,S,Z,Y),V=new UnionFind(Z),u=0;
for(var T=1;T<a;T++)for(var R=1;R<O;R++){var L=T*O+R,x=S[L],v=0;if((v=S[L-1])!=x&&G[v]==G[x]&&l(K,0,x*6,v*6)<P)V.link(x,v);
if((v=S[L-O])!=x&&G[v]==G[x]&&l(K,0,x*6,v*6)<P)V.link(x,v)}var N=new Uint16Array(Z);N.fill(65535);var H=new Uint16Array(Z);
for(var L=0;L<Z;L++){var F=V.find(L);if(N[F]==65535)N[F]=u++;H[L]=N[F]}var t=new Uint16Array(Y);for(var L=0;
L<Y;L++)t[L]=H[S[L]];return{G2:t,M$:u}};E.gq.anN=function(s,O,a,X){var P=E.Q(a),Z=O.length,Y=0;for(var L=0;
L<Z&&Y!=3;L++){var K=X[L];if(K==0||K==255){var S=O[L],G=2-(K>>>7);P[S]=Y=P[S]|G}}return Y!=3};function m(s,O,a,X,P,Z,Y){var K=(P*O+X)*4,S=Z[Y+5],G=1/S,V=s[K]*S-Z[Y],T=s[K+1]*S-Z[Y+1],R=s[K+2]*S-Z[Y+2],x=X*S-Z[Y+3],v=P*S-Z[Y+4],N=Math.sqrt(V*V+T*T+R*R),u=Math.sqrt(x*x+v*v);
return~~((N+a*u)*G+.5)}function l(s,O,a,X){var P=1/s[a+5],Z=1/s[X+5],Y=s[a]*P-s[X]*Z,K=s[a+1]*P-s[X+1]*Z,S=s[a+2]*P-s[X+2]*Z,G=s[a+3]*P-s[X+3]*Z,V=s[a+4]*P-s[X+4]*Z,T=Math.sqrt(Y*Y+K*K+S*S),R=Math.sqrt(G*G+V*V);
return~~(T+O*R+.5)}function A(s,O,a){var X=E.Dl(s,new iB(0,0,O,a)),P=X.rect.m,Z=X.rect.n,Y=M(X.Q0,P,Z),K=Y.G2,S=Date.now(),G=new Uint16Array(O*a);
G.fill(65535);for(var V=0;V<Z;V++){for(var T=0;T<P;T++){var R=V*P+T,L=(V<<1)*O+(T<<1),x=K[R];if(K[R-P]!=x||K[R-1]!=x||K[R+1]!=x||K[R+P]!=x)x=65535;
G[L]=x;G[L+1]=x;G[L+O]=x;G[L+O+1]=x}}Y.G2=G;return Y}function g(s,O){var L=0,a=s.length;while(L!=a&&s[L]!=O)L+=2;
return L==a?-1:L}function k(s,L){if(L==s.length-2){s.pop();s.pop()}else{s[L+1]=s.pop();s[L]=s.pop()}}E.gq.apP=function(s,O,a,X,P){var Z=new Uint32Array(P*4400),n=[];
for(var L=0;L<P;L++)n.push([]);for(var Y=0;Y<a;Y++)for(var K=0;K<O;K++){var L=Y*O+K,S=L<<2,G=X[L],V=0,T=s[S]>>>4,R=s[S+1]>>>4,x=s[S+2]>>>4;
Z[G*4400+(T<<8|R<<4|x)]++;Z[G*4400+4096]++;Z[G*4400+4100+(T<<4|R)]++;Z[G*4400+4360+T]++;if(K!=0&&(V=X[L-1])!=G&&g(n[G],V)==-1){n[G].push(V,0);
n[V].push(G,0)}if(Y!=0&&(V=X[L-O])!=G&&g(n[G],V)==-1){n[G].push(V,0);n[V].push(G,0)}}for(var L=0;L<P;
L++){var x=n[L];for(var v=0;v<x.length;v+=2)x[v+1]=z(Z,L,x[v])}return[Z,n]};function $(s,O,a,X){var P=E.Q(a);
for(var L=0;L<X;L++){var Z=s[L];if(Z==0||Z==255)P[O[L]]=2-(Z>>>7)}return P}E.gq.aA8=function(s,O,a,X,P,Z,Y){var K=O*a,S=Y[0],n=Y[1],G=new UnionFind(X),V=$(P,s,X,K),T=-1,R=!0,x=0;
for(var L=0;L<X;L++)if(V[L]==1){if(T==-1)T=L;else G.link(L,T)}if(T==-1){for(var L=0;L<K;L++)Z[L]=P[L]==255?255:0;
return}while(R){while(R){R=!1;for(var L=0;L<X;L++){if(V[L]==0){var v=C(n[L]);if(V[v]==1){V[L]=V[v];R=!0;
G.link(L,v)}}}}R=!0;x=0;while(R){R=!1;for(var L=0;L<X;L++){if(V[L]==0){var v=C(n[L]);if(V[v]==0){var N=L*4400,u=v*4400;
for(var H=0;H<4400;H+=2){S[N+H]+=S[u+H];S[N+H+1]+=S[u+H+1]}f(n,S,L,v);x++;V[v]=3;R=!0;G.link(L,v)}}}}R=x!=0}var F=G.find(T);
for(var L=0;L<X;L++)V[L]=G.find(L)==F?255:0;for(var L=0;L<K;L++){Z[L]=V[s[L]]}for(var L=0;L<K;L++){var v=P[L];
if(v==0||v==255)Z[L]=v}};function C(s){var O=0,a=0,X=s.length;for(var P=0;P<X;P+=2){var Z=s[P+1];if(Z>a){a=Z;
O=P}}return s[O]}function f(n,s,O,a){var X=n[O],P=n[a];k(X,g(X,a));k(P,g(P,O));for(var L=0;L<P.length;
L+=2){var Z=P[L],Y=n[Z];k(Y,g(Y,a));if(g(Y,O)==-1){Y.push(O,0);X.push(Z,0)}}for(var L=0;L<X.length;L+=2){var Z=X[L],Y=n[Z],K=z(s,O,Z);
X[L+1]=K;Y[g(Y,O)+1]=K}}function z(s,O,a){var X=0,P=4096,Z=O*4400,Y=a*4400;for(var K=0;K<16;K++){if(s[Z+4360+K]==0||s[Y+4360+K]==0)continue;
for(var S=0;S<16;S++){var G=K<<4|S;if(s[Z+4100+G]==0||s[Y+4100+G]==0)continue;var V=Z+(G<<4),T=Y+(G<<4);
for(var L=0;L<16;L++)X+=Math.sqrt(s[V+L]*s[T+L])}}var R=X/Math.sqrt(s[Z+P]*s[Y+P]);return~~(999.99999*R)}return M}();
E.vy={};E.vy.acY=function(){var w=11,n=7,W=w>>>1,bK=n>>>1,D=2,j=2e3/D,I=[],M=null,m="";function U(A,g,k){var $=(A[g+0]-A[k+0])*(1/255),C=(A[g+1]-A[k+1])*(1/255),f=(A[g+2]-A[k+2])*(1/255),z=(A[g+3]-A[k+3])*(1/255),s=$*$*.125+C*C*.25+f*f*.5+z*z;
return I[~~(s*j)]}function l(A,g,k,$,C,f){var z=Date.now(),s=E.Q(g*k);E.fo(A,s);var O=UZIP.adler(s,0,g*k);
if(O!=m){var a=E.Wt(s,g,k);M=E.Q(g*k*4);m=O;var X=[1,1/9,1/25,1/49,1/81];for(var P=0;P<k;P++)for(var Z=0;
Z<g;Z++)for(var L=0;L<4;L++){var Y=Math.max(1,Z-L),K=Math.min(g-1,Z+L),S=Math.max(1,P-L),G=Math.min(k-1,P+L),V=E.MM(a,g,Y,K,S,G);
if(isNaN(V))throw Z+","+P+","+L+","+V;M[(P*g+Z)*4+L]=V*X[L]}}if(je.YG){var T=je.vL(0,g,k);T.set(A);var R=je.vL(1,g,k);
R.set(M);var x=je.vL(2,g,k);je.t5(x);je.filter.zj({type:je.filter.avZ,q8:new Float32Array([1/g,1/k]),ar5:R.LJ,agT:C,a0G:f},T.LJ);
x.get($)}else{for(var L=0;L<2e3;L++)I[L]=Math.exp(-(L/2e3)*D*(100+(1-C)*(1-C)*1e4));var v=bK+2;for(var P=v;
P<k-v;P++)for(var Z=v;Z<g-v;Z++){var N=0,u=0,H=0,F=0;for(var t=0;t<w;t++)for(var o=0;o<w;o++){var q=Z+o-W,_=P+t-W;
if(q==Z&&_==P||q<v||_<v||q>=g-v||_>=k-v)continue;var d=U(M,(P*g+Z)*4,(_*g+q)*4),r=_*g+q<<2;N+=d*A[r+0];
u+=d*A[r+1];H+=d*A[r+2];F+=d}if(F==0){continue}var p=1/F,Q=(P*g+Z)*4;$[Q+0]=~~((1-f)*p*N+f*$[Q+0]);$[Q+1]=~~((1-f)*p*u+f*$[Q+1]);
$[Q+2]=~~((1-f)*p*H+f*$[Q+2])}}}return l}();E.aa$=function(){var w=6,n=w>>>1,W=[[-.0662912607,-.0855816496],[.1104854346,-.0855816496],[.6629126074,.1711632992],[.6629126074,.1711632992],[.1104854346,-.0855816496],[-.0662912607,-.0855816496],[0,0],[0,0]],D=[[-.0662912607,.0855816496],[-.1104854346,-.0855816496],[.6629126074,-.1711632992],[-.6629126074,.1711632992],[.1104854346,.0855816496],[.0662912607,-.0855816496],[0,0],[0,0]];
function j(f,z){var s=!1,O=f.length,a=z[0],Y=5,S=0,G=0;for(var L=1;L<O;L++)a=a.x0(z[L]);if((a.m&1)!=0)a.m++;
if((a.n&1)!=0)a.n++;var X=a.m,P=a.n,Z=Math.max(X,P);while(Z>>>Y>8&&Y<10)Y++;var K=1<<Y;if(X%K!=0)S=K-X%K;
if(P%K!=0)G=K-P%K;a.VD(S>>>1,G>>>1);X=a.m;P=a.n;if(X%K!=0||P%K!=0)throw"e";var V=Date.now(),T=[],R=E.Q(a.O()),x=[],v=X*P,N=new Float32Array(X*P*2);
for(var L=0;L<O;L++){var u=z[L],H=E.Q(u.O());E.fo(f[L],H);R.fill(0);E.B0(H,u,R,a);T.push(R.slice(0));
var F=u.x-a.x,t=u.y-a.y,o=F+u.m-2,q=t+u.n;for(var _=0;_<u.n;_++){var d=(_+t)*X;for(var r=0;r<F;r++)R[d+r]=R[d+F];
for(var r=o;r<X;r++)R[d+r]=R[d+o-1]}for(var r=0;r<X;r++){for(var _=0;_<t;_++)R[_*X+r]=R[t*X+r];for(var _=q;
_<P;_++)R[_*X+r]=R[(q-1)*X+r]}var p=new Float32Array(X*P*2);x.push(p);for(var Q=0;Q<v;Q++)p[Q*2]=R[Q]*(1/255);
m(p,N,X,P,Y);I(p,X,P,Y)}if(s)console.log("to gray, decompose",Date.now()-V);V=Date.now();var B=E.Q(X*P);
for(var _=0;_<P;_++)for(var r=0;r<X;r++){var i=0,c=0,h2=_*X+r<<1;for(var L=0;L<O;L++){var jX=x[L],bm=jX[h2],dC=jX[h2+1],fn=bm*bm+dC*dC;
if(fn>c){c=fn;i=L}}B[h2>>>1]=i}if(s)console.log("max abs value",Date.now()-V);V=Date.now();U(B,X,P,Y);
M(B,X,P);if(s)console.log("denoise",Date.now()-V);V=Date.now();var fK=N.slice(0);for(var _=0;_<P;_++)for(var r=0;
r<X;r++){var L=_*X+r,h2=L<<1,i6=x[B[L]];fK[h2]=i6[h2];fK[h2+1]=i6[h2+1]}l(fK,N,X,P,Y);if(s)console.log("compose",Date.now()-V);
V=Date.now();for(var Q=0;Q<v;Q++){var fn=fK[Q*2]*255,i=0,c=1e9;for(var L=0;L<O;L++){var dh=Math.abs(T[L][Q]-fn);
if(dh<c){c=dh;i=L}T[L][Q]=0}T[i][Q]=255}if(s)console.log("toRGB",Date.now()-V);V=Date.now();return[T,a]}function I(f,z,s,O){var a=z>>>O,X=s>>>O,P=1e-4;
for(var Z=0;Z<s;Z++)for(var Y=0;Y<z;Y++){if(Y<a&&Z<X)continue;var K=(Z*z+Y)*2,S=f[K],G=f[K+1],V=S*S+G*G;
if(V<P)S=G=0;else{var T=(V-P)/V;S*=T;G*=T}f[K]=S;f[K+1]=G}}function U(f,z,s,O){for(var a=0;a<O;a++){var X=z>>>a,P=s>>>a,Z=X>>>1,Y=P>>>1;
for(var K=0;K<Y;K++)for(var S=0;S<Z;S++){var G=K*z+Z+S,V=(K+Y)*z+Z+S,T=(K+Y)*z+S,R=f[G],x=f[V],v=f[T];
if(R==x==v){}else if(R==x)f[T]=R;else if(x==v)f[G]=x;else if(R==v)f[V]=R}}}function M(f,z,s){for(var O=1;
O<s-1;O++)for(var a=1;a<z-1;a++){var L=O*z+a,X=f[L-z],P=f[L-1],Z=f[L],Y=f[L+1],K=f[L+z],S=X==P&&X==Y||X==Y&&Y==K||Y==K&&P==K||X==P&&K==P;
if(S)f[L]=X==P?X:P==Y?P:X;else if(Z>X&&Z>P&&Z>Y&&Z>K)f[L]=X+P+Y+K>>>2;else if(Z<X&&Z<P&&Z<Y&&Z<K)f[L]=X+P+Y+K>>>2}}function m(f,z,s,O,a){for(var L=0;
L<a;L++){var X=s>>>L,P=O>>>L;A(f,z,s,O,X,P)}}function l(f,z,s,O,a){for(var L=a-1;L>=0;L--){var X=s>>L,P=O>>L;
g(f,z,s,O,X,P)}}function A(f,z,s,O,a,X){$(f,z,s,O,a,X,!0);$(z,f,s,O,a,X,!1)}function g(f,z,s,O,a,X){C(f,z,s,O,a,X,!0);
C(z,f,s,O,a,X,!1)}function k(f,z,s,O,a,X){var P=s*O+z<<1;f[P]=a;f[P+1]=X}function $(f,z,s,O,a,X,P){var dN=P?a:X,Z=P?X:a,Y=Z>>>1;
for(var K=0;K<dN;K++){for(var S=0;S<Z;S+=2){var G=0,V=0,T=0,R=0,x=S>>>1;for(var v=0;v<6;v++){var N=S+v-3;
if(N<0)N=Z+N;if(N>=Z)N=N-Z;var u=(P?N*s+K:K*s+N)<<1,H=f[u],F=f[u+1],t=W[v],o=D[v];G+=H*t[0]-F*t[1];V+=F*t[0]+H*t[1];
T+=H*o[0]-F*o[1];R+=F*o[0]+H*o[1]}if(P){k(z,K,x,s,G,V);k(z,K,x+Y,s,T,R)}else{k(z,x,K,s,G,V);k(z,x+Y,K,s,T,R)}}}}function C(f,z,s,O,a,X,P){var dN=P?a:X,Z=P?X:a,Y=Z>>>1,K,S,G,V;
for(var T=0;T<dN;T++){for(var R=0;R<Z;R++){var x=0,v=0;for(var N=R+3&1;N<6;N+=2){var u=R-N+3>>1;if(u<0)u=Y+u;
if(u>=Y)u=u-Y;if(P){K=T;S=u;G=T;V=u+Y}else{S=T;K=u;V=T;G=u+Y}var H=S*s+K<<1,F=V*s+G<<1,t=f[H],o=f[H+1],q=f[F],_=f[F+1],d=W[N],r=D[N];
x+=t*d[0]+q*r[0];x+=o*d[1]+_*r[1];v+=o*d[0]+_*r[0];v-=t*d[1]+q*r[1]}if(P)k(z,T,R,s,x,v);else k(z,R,T,s,x,v)}}}return{Ig:j}}();
var cf=function(){function w(){this.O=0;this._W=0;this.kj={};this.p3=[];this.UH=1e5;this.Ip=1e5;this.lw=-1;
this.S_=-1;this.color=0}function n(bK){this.Xy=bK;this.su=new Array(bK);this.Cj=new Array(bK*6);this.ahB=0;
this.am=new Array(bK*2);this.alpha=new Array(bK);this.g2=new Array(bK);this.hv=new Array(bK)}function W(j,I,U,M){function m(z,s,j,I){return j[I*s+z]}function l(L){var Y=j.length;
while(L<Y&&j[L]==0)L++;return L<Y?L:-1}function A(z,s,Y){for(var L=2;L<5;L++){var K=0;for(var S=-L+1;
S<=L-1;S++){K+=m(z+S,s+L-1,j,I)==Y?1:-1;K+=m(z+L-1,s+S-1,j,I)==Y?1:-1;K+=m(z+S-1,s-L,j,I)==Y?1:-1;K+=m(z-L,s+S,j,I)==Y?1:-1}if(K>0)return 1;
else if(K<0)return 0}return 0}function g(Y,C){var f=new w,z=Y,s=C,K=0,S=1,G;f.color=j[C*I+Y];f.sign=m(Y,C,j,I)==f.color?"+":"-";
while(1){f.p3.push(z,s);if(z>f.lw)f.lw=z;if(z<f.UH)f.UH=z;if(s>f.S_)f.S_=s;if(s<f.Ip)f.Ip=s;f._W++;z+=K;
s+=S;f.O-=z*S;if(z==Y&&s==C)break;var V=m(z+(K+S-1>>1),s+(S-K-1>>1),j,I)==f.color,T=m(z+(K-S-1>>1),s+(S+K-1>>1),j,I)==f.color;
if(T&&!V){if(M.N8=="right"||M.N8=="black"&&f.sign=="+"||M.N8=="white"&&f.sign=="-"||M.N8=="majority"&&A(z,s,f.color)||M.N8=="minority"&&!A(z,s,f.color)){G=K;
K=-S;S=G}else{G=K;K=S;S=-G}}else if(T){G=K;K=-S;S=G}else if(!V){G=K;K=S;S=-G}}return f}var k=0,$=[];
while(!0){var k=l(k);if(k==-1)break;var C=Math.floor(k/I),f=g(k-C*I,C);for(var L=0;L<f.p3.length-2;L+=2){var z=f.p3[L],s=f.p3[L+1],O=s*I+z;
if(z==f.p3[L+2]&&s+1==f.p3[L+3]&&j[O]!=0)cf.fill(O,j,I,0)}if(f.O>M.a8r)$.push(f)}for(var L=0;L<$.length;
L++)$[L].parent=-1;var a=Date.now();for(var L=1;L<$.length;L++){var X=$[L];for(var P=L-1;P>=0;P--){var Z=$[P];
if(X.UH<Z.UH||X.lw>Z.lw||X.Ip<Z.Ip||X.S_>Z.S_)continue;if(!cf.ku(Z.p3,X.p3[0]+.5,X.p3[1]+.5))continue;
X.parent=P;break}}return $}function D(j,I){function U(K,S,G,V,T){this.x=K;this.y=S;this.W$=G;this.q7=V;
this.BR=T}function M(K,bK){return(bK+K)%bK}function m(K,S,G,V){return K*V-G*S}function l(K,S,G,V){return K*G+S*V}function A(K,S,G){if(K<=G)return K<=S&&S<G;
else return K<=S||S<G}function g(K,S,G){var V=0;V+=S*K[0]*S;V+=S*K[1]*G;V+=S*K[2];V+=G*K[3]*S;V+=G*K[4]*G;
V+=G*K[5];V+=K[6]*S;V+=K[7]*G;V+=K[8];return V}function k(K,S,G){return S+K*(G-S)}function $(K,S,G,V){var T=Math.sign(G-K),R=-Math.sign(V-S);
return T*(G-K)-R*(V-S)}function C(K,S){return Math.sqrt(K*K+S*S)}function f(K,S,G,V,T){var R=1-K;return R*R*R*S+3*(R*R*K)*G+3*(K*K*R)*V+K*K*K*T}function z(K,S,G,V,T,R,x,v){var N=m(K,S,x,v),u=m(G,V,x,v),H=m(T,R,x,v),F=N-2*u+H,t=-2*N+2*u,o=N,q=t*t-4*F*o;
if(F==0||q<0)return-1;var _=Math.sqrt(q),d=(-t+_)/(2*F),r=(-t-_)/(2*F);if(d>=0&&d<=1)return d;else if(r>=0&&r<=1)return r;
else return-1}function s(Y){var L,K,S;Y.DS=Y.p3[0];Y.aet=Y.p3[1];Y.jT=[];var G=Y.jT;G.push(new U(0,0,0,0,0));
for(L=0;L<Y._W;L++){K=Y.p3[L<<1]-Y.DS;S=Y.p3[(L<<1)+1]-Y.aet;G.push(new U(G[L].x+K,G[L].y+S,G[L].W$+K*S,G[L].q7+K*K,G[L].BR+S*S))}}function O(Y){var bK=Y._W,K=Y.p3,S,G=new Array(bK),V=new Array(bK),T=new Array(4),R,x,v,N,u,H,F,t,o,q,_,L,d,r,p,Q,B,i,c=0;
Y.K6=new Array(bK);for(L=bK-1;L>=0;L--){if(K[L<<1]!=K[c<<1]&&K[(L<<1)+1]!=K[(c<<1)+1])c=L+1;V[L]=c}for(L=bK-1;
L>=0;L--){var h2=M(L+1,bK)<<1;T[0]=T[1]=T[2]=T[3]=0;S=(3+3*(K[h2]-K[L<<1])+(K[h2+1]-K[(L<<1)+1]))/2;
T[S]++;R=0;x=0;v=0;N=0;c=V[L];r=L;while(1){_=0;S=(3+3*Math.sign(K[c*2]-K[r*2])+Math.sign(K[c*2+1]-K[r*2+1]))/2;
T[S]++;if(T[0]&&T[1]&&T[2]&&T[3]){G[L]=r;_=1;break}o=K[c*2]-K[L*2];q=K[c*2+1]-K[L*2+1];if(m(R,x,o,q)<0||m(v,N,o,q)>0){break}if(Math.abs(o)<=1&&Math.abs(q)<=1){}else{u=o+(q>=0&&(q>0||o<0)?1:-1);
H=q+(o<=0&&(o<0||q<0)?1:-1);if(m(R,x,u,H)>=0){R=u;x=H}u=o+(q<=0&&(q<0||o<0)?1:-1);H=q+(o>=0&&(o>0||q<0)?1:-1);
if(m(v,N,u,H)<=0){v=u;N=H}}r=c;c=V[r];if(!A(c,L,r)){break}}if(_==0){F=Math.sign(K[c*2]-K[r*2]);t=Math.sign(K[c*2+1]-K[r*2+1]);
o=K[r*2]-K[L*2];q=K[r*2+1]-K[L*2+1];p=m(R,x,o,q);Q=m(R,x,F,t);B=m(v,N,o,q);i=m(v,N,F,t);d=1e7;if(Q<0){d=Math.floor(p/-Q)}if(i>0){d=Math.min(d,Math.floor(-B/i))}G[L]=M(r+d,bK)}}d=G[bK-1];
Y.K6[bK-1]=d;for(L=bK-2;L>=0;L--){if(A(L+1,G[L],d)){d=G[L]}Y.K6[L]=d}for(L=bK-1;A(M(L+1,bK),d,Y.K6[L]);
L--){Y.K6[L]=d}}function a(Y){function K(Y,L,S){var bK=Y._W,o=Y.p3,q=Y.jT,_,d,r,p,Q,V,B,i,t,c,h2,jX,bm,dC,fn=0;
if(S>=bK){S-=bK;fn=1}if(fn==0){_=q[S+1].x-q[L].x;d=q[S+1].y-q[L].y;p=q[S+1].q7-q[L].q7;r=q[S+1].W$-q[L].W$;
Q=q[S+1].BR-q[L].BR;V=S+1-L}else{_=q[S+1].x-q[L].x+q[bK].x;d=q[S+1].y-q[L].y+q[bK].y;p=q[S+1].q7-q[L].q7+q[bK].q7;
r=q[S+1].W$-q[L].W$+q[bK].W$;Q=q[S+1].BR-q[L].BR+q[bK].BR;V=S+1-L+bK}h2=(o[L<<1]+o[S<<1])/2-o[0];jX=(o[(L<<1)+1]+o[(S<<1)+1])/2-o[1];
dC=o[S<<1]-o[L<<1];bm=-(o[(S<<1)+1]-o[(L<<1)+1]);B=(p-2*_*h2)/V+h2*h2;i=(r-_*jX-d*h2)/V+h2*jX;t=(Q-2*d*jX)/V+jX*jX;
c=bm*bm*B+2*bm*dC*i+dC*dC*t;return Math.sqrt(c)}var L,S,G,V,bK=Y._W,T=new Array(bK+1),R=new Array(bK+1),x=new Array(bK),v=new Array(bK+1),N=new Array(bK+1),u=new Array(bK+1),H,F,t;
for(L=0;L<bK;L++){t=M(Y.K6[M(L-1,bK)]-1,bK);if(t==L){t=M(L+1,bK)}if(t<L){x[L]=bK}else{x[L]=t}}S=1;for(L=0;
L<bK;L++){while(S<=x[L]){v[S]=L;S++}}L=0;for(S=0;L<bK;S++){N[S]=L;L=x[L]}N[S]=bK;G=S;L=bK;for(S=G;S>0;
S--){u[S]=L;L=v[L]}u[0]=0;T[0]=0;for(S=1;S<=G;S++){for(L=u[S];L<=N[S];L++){F=-1;for(V=N[S-1];V>=v[L];
V--){H=K(Y,V,L)+T[V];if(F<0||H<F){R[L]=V;F=H}}T[L]=F}}Y.aqL=G;Y.ayU=new Array(G);for(L=bK,S=G-1;L>0;
S--){L=R[L];Y.ayU[S]=L}}function X(Y){function K(Y,L,H,x,v,fK){var bK=Y._W,i6=Y.jT,dh=0,t;while(H>=bK){H-=bK;
dh+=1}while(L>=bK){L-=bK;dh-=1}while(H<0){H+=bK;dh-=1}while(L<0){L+=bK;dh+=1}var kA=i6[H+1].x-i6[L].x+dh*i6[bK].x,ig=i6[H+1].y-i6[L].y+dh*i6[bK].y,iJ=i6[H+1].q7-i6[L].q7+dh*i6[bK].q7,fL=i6[H+1].W$-i6[L].W$+dh*i6[bK].W$,fB=i6[H+1].BR-i6[L].BR+dh*i6[bK].BR,F=H+1-L+dh*bK;
x[fK]=kA/F;x[fK+1]=ig/F;var ah=(iJ-kA*kA/F)/F,eS=(fL-kA*ig/F)/F,gL=(fB-ig*ig/F)/F,e_=(ah+gL+Math.sqrt((ah-gL)*(ah-gL)+4*eS*eS))/2;
ah-=e_;gL-=e_;if(Math.abs(ah)>=Math.abs(gL)){t=Math.sqrt(ah*ah+eS*eS);if(t!=0){v[fK]=-eS/t;v[fK+1]=ah/t}}else{t=Math.sqrt(gL*gL+eS*eS);
if(t!=0){v[fK]=-gL/t;v[fK+1]=eS/t}}if(t==0){v[fK]=v[fK+1]=0}}var S=Y.aqL,G=Y.ayU,bK=Y._W,V=Y.p3,T=Y.DS,R=Y.aet,x=new Array(S*2),v=new Array(S*2),N=new Array(S),u=new Array(3),L,H,F,t,d,r,p,Q,B,i,c;
Y.kj=new n(S);for(L=0;L<S;L++){H=G[M(L+1,S)];H=M(H-G[L],bK)+G[L];x[L<<1]=0;x[(L<<1)+1]=0;v[L<<1]=0;v[(L<<1)+1]=0;
K(Y,G[L],H,x,v,L<<1)}for(L=0;L<S;L++){N[L]=[0,0,0,0,0,0,0,0,0];var o=v[L<<1]*v[L<<1]+v[(L<<1)+1]*v[(L<<1)+1],q=1/o;
if(o!=0){u[0]=v[(L<<1)+1];u[1]=-v[L<<1];u[2]=-u[1]*x[(L<<1)+1]-u[0]*x[L<<1];for(t=0;t<3;t++){N[L][t*3+0]=u[t]*u[0]*q;
N[L][t*3+1]=u[t]*u[1]*q;N[L][t*3+2]=u[t]*u[2]*q}}}var _=[0,0,0,0,0,0,0,0,0];for(L=0;L<S;L++){_[0]=_[1]=_[2]=_[3]=_[4]=_[5]=_[6]=_[7]=_[8]=_[9]=0;
var h2=V[G[L]<<1]-T,jX=V[(G[L]<<1)+1]-R,bm=0,dC=0;H=M(L-1,S);for(t=0;t<9;t+=3){_[t+0]=N[H][t+0]+N[L][t+0];
_[t+1]=N[H][t+1]+N[L][t+1];_[t+2]=N[H][t+2]+N[L][t+2]}while(1){var fn=_[0]*_[4]-_[1]*_[3];if(fn!=0){bm=(-_[2]*_[4]+_[5]*_[0])/fn;
dC=(_[2]*_[3]-_[5]*_[0])/fn;break}if(_[0]>_[4]){u[0]=-_[1];u[1]=_[0]}else if(_[4]){u[0]=-_[4];u[1]=_[3]}else{u[0]=1;
u[1]=0}var o=u[0]*u[0]+u[1]*u[1],q=1/o;u[2]=-u[1]*jX-u[0]*h2;for(t=0;t<3;t++){_[t*3+0]+=u[t]*u[0]*q;
_[t*3+1]+=u[t]*u[1]*q;_[t*3+2]+=u[t]*u[2]*q}}d=Math.abs(bm-h2);r=Math.abs(dC-jX);if(d<=.5&&r<=.5){Y.kj.am[L<<1]=bm+T;
Y.kj.am[(L<<1)+1]=dC+R;continue}p=g(_,h2,jX);B=h2;i=jX;if(_[0]!=0){for(c=0;c<2;c++){dC=jX-.5+c;bm=-(_[1]*dC+_[2])/_[0];
d=Math.abs(bm-h2);Q=g(_,bm,dC);if(d<=.5&&Q<p){p=Q;B=bm;i=dC}}}if(_[4]!=0){for(c=0;c<2;c++){bm=h2-.5+c;
dC=-(_[3]*bm+_[5])/_[4];r=Math.abs(dC-jX);Q=g(_,bm,dC);if(r<=.5&&Q<p){p=Q;B=bm;i=dC}}}for(t=0;t<2;t++){for(F=0;
F<2;F++){bm=h2-.5+t;dC=jX-.5+F;Q=g(_,bm,dC);if(Q<p){p=Q;B=bm;i=dC}}}Y.kj.am[L<<1]=B+T;Y.kj.am[(L<<1)+1]=i+R}}function P(Y){var K=Y.kj.Xy,S=Y.kj,L,G,V,T,R,x,v,N,u;
for(L=0;L<K;L++){G=M(L+1,K);V=M(L+2,K);var H=S.am[L<<1],F=S.am[(L<<1)+1],t=S.am[V<<1],o=S.am[(V<<1)+1],q=S.am[G<<1],_=S.am[(G<<1)+1],d=k(.5,t,q),r=k(.5,o,_);
R=$(H,F,t,o);if(R!=0){T=m(q-H,_-F,t-H,o-F)/R;T=Math.abs(T);x=T>1?1-1/T:0;x=x*(1/.75)}else{x=4/3}S.g2[G]=x;
var p=3*G<<1;if(x>=I.akt){S.su[G]=0;S.Cj[p+0]=S.Cj[p+1]=0;S.Cj[p+2]=q;S.Cj[p+3]=_;S.Cj[p+4]=d;S.Cj[p+5]=r}else{if(x<.55){x=.55}else if(x>1){x=1}var Q=.5+.5*x;
S.su[G]=1;S.Cj[p]=k(Q,H,q);S.Cj[p+1]=k(Q,F,_);S.Cj[p+2]=k(Q,t,q);S.Cj[p+3]=k(Q,o,_);S.Cj[p+4]=d;S.Cj[p+5]=r}S.alpha[G]=x;
S.hv[G]=.5}S.adC=1}function Z(Y){function K(){this.tP=0;this.Rz=0;this.zd=0;this.ja=0;this.bZ=0;this.ib=0;
this._6=0;this.alpha=0}function S(Y,L,H,jS,ie,B,i){var V=Y.kj.Xy,as=Y.kj.Cj,gb=Y.kj.am;if(L==H)return 1;
var gx=L,q=M(L+1,V),eo=M(gx+1,V),fL=gb[L<<1],fB=gb[(L<<1)+1],di=gb[q<<1],d0=gb[(q<<1)+1],e6=B[eo];if(e6==0)return 1;
var dt=C(fL-di,fB-d0);for(gx=eo;gx!=H;gx=eo){var eo=M(gx+1,V),gJ=M(gx+2,V),iW=gb[eo<<1],g5=gb[(eo<<1)+1],jW=gb[gJ<<1],eP=gb[(gJ<<1)+1];
if(B[eo]!=e6)return 1;if(Math.sign(m(di-fL,d0-fB,jW-iW,eP-g5))!=e6)return 1;if(l(di-fL,d0-fB,jW-iW,eP-g5)<dt*C(iW-jW,g5-eP)*-.999847695156)return 1}var b_=M(L,V)*3+2<<1,fZ=M(L+1,V)<<1,im=M(H,V)<<1,j3=M(H,V)*3+2<<1,fK=as[b_],i6=as[b_+1],dr=gb[fZ],c0=gb[fZ+1],fM=gb[im],cB=gb[im+1],iI=as[j3],jD=as[j3+1],c=gb[0],h2=gb[1];
b_=H*3+2<<1;var j8=as[b_],jG=as[b_+1],_=i[H]-i[L];_-=m(j8-c,jG-h2,j8-c,jG-h2)/2;if(L>=H){_+=i[V]}var i1=dr-fK,bH=c0-i6,a_=fM-fK,aR=cB-i6,iY=iI-fK,gy=jD-i6,gr=m(i1,bH,a_,aR),fs=m(i1,bH,iY,gy),dQ=m(a_,aR,iY,gy),ep=gr+dQ-fs;
if(fs==gr)return 1;var Q=dQ/(dQ-ep),p=fs/(fs-gr),b2=fs*Q/2;if(b2==0)return 1;var eX=_/b2,d=2-Math.sqrt(4-eX/.3);
jS.Rz=k(Q*d,fK,dr);jS.zd=k(Q*d,i6,c0);jS.ja=k(p*d,iI,fM);jS.bZ=k(p*d,jD,cB);jS.alpha=d;jS.ib=Q;jS._6=p;
dr=jS.Rz;c0=jS.zd;fM=jS.ja;cB=jS.bZ;jS.tP=0;for(gx=M(L+1,V);gx!=H;gx=eo){eo=M(gx+1,V);var iz=gb[gx<<1],en=gb[(gx<<1)+1],iW=gb[eo<<1],g5=gb[(eo<<1)+1];
Q=z(dr-fK,c0-i6,fM-dr,cB-c0,iI-fM,jD-cB,iW-iz,g5-en);if(Q<-.5)return 1;var ko=f(Q,fK,dr,fM,iI),fh=f(Q,i6,c0,cB,jD),dt=C(iW-iz,g5-en);
if(dt==0)return 1;var d1=m(iW-iz,g5-en,ko-iz,fh-en)/dt;if(Math.abs(d1)>ie)return 1;if(l(iW-iz,g5-en,ko-iz,fh-en)<0||l(iz-iW,en-g5,ko-iW,fh-g5)<0){return 1}jS.tP+=d1*d1}for(gx=L;
gx!=H;gx=eo){eo=M(gx+1,V);var b_=gx*3+2<<1,fZ=eo*3+2<<1,j_=as[b_],h9=as[b_+1],ha=as[fZ],fl=as[fZ+1];
Q=z(dr-fK,c0-i6,fM-dr,cB-c0,iI-fM,jD-cB,ha-j_,fl-h9);if(Q<-.5)return 1;var ko=f(Q,fK,dr,fM,iI),fh=f(Q,i6,c0,cB,jD),dt=C(ha-j_,fl-h9);
if(dt==0)return 1;var d1=m(ha-j_,fl-h9,ko-j_,fh-h9)/dt,ex=m(ha-j_,fl-h9,gb[eo<<1]-j_,gb[(eo<<1)+1]-h9)/dt;
ex*=.75*Y.kj.alpha[eo];if(ex<0){d1=-d1;ex=-ex}if(d1<ex-ie)return 1;if(d1<ex){jS.tP+=(d1-ex)*(d1-ex)}}return 0}var G=Y.kj,V=G.Xy,T=G.am,R=new Array(V+1),x=new Array(V+1),v=new Array(V+1),N=new Array(V+1),u,L,H,F,t=new K,o,q,_,d,r,p,Q,B=new Array(V),i=new Array(V+1);
for(L=0;L<V;L++){if(G.su[L]=="CURVE"){var c=T[M(L-1,V)<<1],h2=T[(M(L-1,V)<<1)+1],jX=T[L<<1],bm=T[(L<<1)+1],dC=T[M(L+1,V)<<1],fn=T[(M(L+1,V)<<1)+1];
B[L]=Math.sign(m(jX-c,bm-h2,dC-jX,fn-bm))}else{B[L]=0}}_=0;i[0]=0;var fK=G.am[0],i6=G.am[1];for(L=0;
L<V;L++){q=M(L+1,V);if(G.su[q]=="CURVE"){d=G.alpha[q];var dh=L*3+2<<1,kA=q*3+2<<1,ig=G.Cj[dh],iJ=G.Cj[dh+1],fL=T[q<<1],fB=T[(q<<1)+1],ah=G.Cj[kA],eS=G.Cj[kA+1];
_+=.3*d*(4-d)*m(fL-ig,fB-iJ,ah-ig,eS-iJ)/2;_+=m(ig-fK,iJ-i6,ah-fK,eS-i6)/2}i[L+1]=_}R[0]=-1;x[0]=0;v[0]=0;
for(H=1;H<=V;H++){R[H]=H-1;x[H]=x[H-1];v[H]=v[H-1]+1;for(L=H-2;L>=0;L--){F=S(Y,L,M(H,V),t,I.abx,B,i);
if(F){break}if(v[H]>v[L]+1||v[H]==v[L]+1&&x[H]>x[L]+t.tP){R[H]=L;x[H]=x[L]+t.tP;v[H]=v[L]+1;N[H]=t;t=new K}}}u=v[V];
r=new n(u);p=new Array(u);Q=new Array(u);H=V;for(L=u-1;L>=0;L--){var gL=M(H,V),e_=L*3+0<<1,c2=gL*3+0<<1;
if(R[H]==H-1){r.su[L]=G.su[gL];r.Cj[e_]=G.Cj[c2];r.Cj[e_+1]=G.Cj[c2+1];r.Cj[e_+2]=G.Cj[c2+2];r.Cj[e_+3]=G.Cj[c2+3];
r.Cj[e_+4]=G.Cj[c2+4];r.Cj[e_+5]=G.Cj[c2+5];r.am[L<<1]=G.am[gL<<1];r.am[(L<<1)+1]=G.am[(gL<<1)+1];r.alpha[L]=G.alpha[gL];
r.g2[L]=G.g2[gL];r.hv[L]=G.hv[gL];p[L]=Q[L]=1}else{r.su[L]="CURVE";r.Cj[e_]=N[H].Rz;r.Cj[e_+1]=N[H].zd;
r.Cj[e_+2]=N[H].ja;r.Cj[e_+3]=N[H].bZ;r.Cj[e_+4]=G.Cj[c2+4];r.Cj[e_+5]=G.Cj[c2+5];r.am[L<<1]=k(N[H]._6,G.Cj[c2+4],T[gL<<1]);
r.am[(L<<1)+1]=k(N[H]._6,G.Cj[c2+5],T[(gL<<1)+1]);r.alpha[L]=N[H].alpha;r.g2[L]=N[H].alpha;p[L]=N[H]._6;
Q[L]=N[H].ib}H=R[H]}for(L=0;L<u;L++){q=M(L+1,u);r.hv[L]=p[L]/(p[L]+Q[q])}r.adC=1;Y.kj=r}for(var L=0;
L<j.length;L++){var Y=j[L];s(Y);O(Y);a(Y);X(Y);P(Y);if(I.adF)Z(Y)}}return{aq2:W,azk:D}}();cf.jo=function(w,n,W,D){var j={N8:"minority",a8r:D,adF:!0,akt:1,abx:.2},I=cf.aq2(w,n,W,j);
cf.azk(I,j);return I};cf.OV=function(w){var n=[];for(var L=0;L<w.length;L++){var W=w[L],D=W.kj,j=["M"],I=[D.Cj[(D.Xy-1)*6+4],D.Cj[(D.Xy-1)*6+5]];
for(var U=0;U<D.Xy;U++){var M=U*6;if(D.su[U]==1){j.push("C");for(var m=0;m<6;m++)I.push(D.Cj[M+m])}else if(D.su[U]==0){j.push("L");
for(var m=2;m<4;m++)I.push(D.Cj[M+m])}}j.push("Z");n.push({parent:W.parent,color:W.color,path:{w:I,F:j}})}return n};
cf.ku=function(w,n,W){var bK=w.length>>1,D,j=w[2*bK-3]-W,I=w[2*bK-2]-n,U=w[2*bK-1]-W,M=U>j,m=0;for(var L=0;
L<bK;L++){D=I;j=U;I=w[2*L]-n;U=w[2*L+1]-W;if(j==U)continue;M=U>j}for(var L=0;L<bK;L++){D=I;j=U;I=w[2*L]-n;
U=w[2*L+1]-W;if(j<0&&U<0)continue;if(j>0&&U>0)continue;if(D<0&&I<0)continue;if(j==U&&Math.min(D,I)<=0)return!0;
if(j==U)continue;var l=D+(I-D)*-j/(U-j);if(l==0)return!0;if(l>0)m++;if(j==0&&M&&U>j)m--;if(j==0&&!M&&U<j)m--;
M=U>j}return(m&1)==1};cf.fill=function(w,n,W,D){var j=n[w],I=[w],U=0;while(U<I.length){var M=I[U];U++;
n[M]=D;if(n[M-W]==j){I.push(M-W);n[M-W]=254}if(n[M-1]==j){I.push(M-1);n[M-1]=254}if(n[M+1]==j){I.push(M+1);
n[M+1]=254}if(n[M+W]==j){I.push(M+W);n[M+W]=254}}};var hP=function(){function w(M){return Math.max(0,Math.min(1,M))}function n(M,m){var l=m<0?-m:m;
if(M>1)M=.99;M=M*.99;var g=Math.pow(l/5,.16),k=Math.pow(2,l<1?l:1+(l-1)*.8);if(m<0)k=1/k;M=g*(1-Math.pow(1-M,k))+(1-g)*M;
return M}function W(M,m){var l=m/100;M=M*.99;M=l*(.5-.5*Math.cos(M*Math.PI))+(1-l)*M;return M}var D=E.Mv.anV(1,1,1,-.3),j=E.Mv.Ba(D);
function I(M,m,l,A,g,k,$){var C=M[l],f=M[l+1],z=M[l+2],s=E.Mv.q4(D,[C,f,z,1]);C=s[0];f=s[1];z=s[2];C=n(C,A);
f=n(f,A);z=n(z,A);var s=E.Mv.q4(j,[C,f,z,1]);C=s[0];f=s[1];z=s[2];C=w(C);f=w(f);z=w(z);C=W(C,g);f=W(f,g);
z=W(z,g);var O=hl.ag4(C,f,z,k);C=O[0];f=O[1];z=O[2];C=w(C);f=w(f);z=w(z);if($){var a=new Uint8Array(4);
a[0]=~~(.5+C*255);a[1]=~~(.5+f*255);a[2]=~~(.5+z*255);eH.Ld($,a,a,new iB(0,0,1,1));C=a[0]/255;f=a[1]/255;
z=a[2]/255}m[l]=C;m[l+1]=f;m[l+2]=z}function U(M,m,l,A,g,k){var $=g.Temp?g.Temp.v:0,C=g.Tint?g.Tint.v:0,f=g.Ex12?g.Ex12.v:0,z=g.Cr12?g.Cr12.v:0,s=g.Vibr?g.Vibr.v:0,O=g.Strt?g.Strt.v:0,a=hl.kN($,C),X=null;
f+=a.apH;if(s!=0||O!=0)X=eH.rw("vibA",{Strt:g.Strt,vibrance:g.Vibr});console.log(X);var P=Date.now();
if(k){var Z=Math.pow(2,f),Y=M.length;f=0;var K=new Float32Array(4e3);for(var L=0;L<4e3;L++){var S=L*(1/1e3);
S=E.vw(S);S*=Z;S=E.ae(S);S=w(S);K[L]=S}for(var L=0;L<Y;L+=3){A[L]=K[~~(M[L]*1e3)];A[L+1]=K[~~(M[L+1]*1e3)];
A[L+2]=K[~~(M[L+2]*1e3)]}console.log(Date.now()-P,"Exposure normalizing");P=Date.now()}else A.set(M);
if(f!=0||z!=0||$!=0||C!=0||X){var G=17,V=1/(G-1),T=G*G*G,R=new Array(T*3);for(var x=0;x<G;x++)for(var v=0;
v<G;v++)for(var N=0;N<G;N++){var L=x*G*G+v*G+N,u=L*3;R[u]=x*V;R[u+1]=v*V;R[u+2]=N*V}for(var L=0;L<T;
L++)I(R,R,L*3,f,z,a,X);console.log(Date.now()-P,"making LUT");P=Date.now();ICC.U.applyLUTFloat(R,G,A,A);
console.log(Date.now()-P,"applying LUT");P=Date.now()}}return U}();function jl(){}jl.ew=function(w){var n=new Uint8Array(w),W=0,D={yg:[],j6:[],list:[]},j=J.IQ(n,W);
W+=2;if(j<=2){return jl.a83(n)}var I=J.IQ(n,W);W+=2;var U=J.sv(n,W,8);W+=8;var M=J.q(n,W);W+=4;if(M>0)D.yg=jl._G(n,W,M,I,j);
W+=M;var m=J.sv(n,W,8);W+=8;var l=J.q(n,W);W+=4;if(l>0)D.j6=kj.EH(n,W,l);W+=l;var A=J.sv(n,W,8);W+=8;
var g=J.q(n,W);W+=4;if(g>0){var k={};jH.iS(n,k,W+4);D.list=k.Brsh.v}W+=g;var $=D.list;for(var L=0;L<$.length;
L++){bj.Hx.check($[L].v)}return D};jl.UG=function(w,n){w.v.Nm.v=n};jl.a83=function(w){var n={yg:[],j6:[],list:[]},W=0,D=J.IQ(w,W);
W+=2;var j=J.IQ(w,W);W+=2;for(var L=0;L<j;L++){var I=J.IQ(w,W);W+=2;var U=J.q(w,W);W+=4;var M=W;if(I==2){var m={};
n.yg.push(m);var l=J.q(w,M);M+=4;var A=J.IQ(w,M);M+=2;if(D==2){var g=J.CX(w,M);M+=4+g.length*2+2}m.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";
M++;M+=8;m.WH=J._I(w,M);M+=16;var k=J.IQ(w,M);M+=2;var $=w[M];M++;var C=jY.PB(!1,k,w,m.WH.m,m.WH.n,M,$);
jl.yv(m,C);var f=bj.os(m.id),z=f.Brsh.v;z.Dmtr.v.val=m.WH.m;z.Spcn.v.val=A;n.list.push({t:"Objc",v:f})}W+=U}return n};
jl.z8=function(w){var n=new cs,W=0,D=0;J.vo(n,W,6);W+=2;J.vo(n,W,2);W+=2;J.YY(n,W,"8BIMsamp");W+=8;W+=4;
D=W;W=jl.qD(n,W,w.yg);J._Z(n,D-4,W-D);J.YY(n,W,"8BIMpatt");W+=8;W+=4;D=W;W=kj.iU(n,W,w.j6);J._Z(n,D-4,W-D);
var j={classID:"null",Brsh:{t:"VlLs",v:w.list}};J.YY(n,W,"8BIMdesc");W+=8;W+=4;D=W;J._Z(n,W,16);W+=4;
W+=jH.X3(n,j,W);J._Z(n,D-4,W-D);return n.data.slice(0,W).buffer};jl._G=function(w,n,W,D,j){var I=J.q,U=J._I,M=n+W,m=[];
while(n<M){var l={};m.push(l);var A=I(w,n);n+=4;var g=n,k=J.$B(w,n);n+=k.length;l.id=k.xi;if(D==1){n+=9;
l.WH=U(w,n);n+=16}else{n+=7;var $=I(w,n);n+=4;l.WH=U(w,n);n+=16;var C=I(w,n);n+=4;n+=C*4;var f=I(w,n);
n+=4;var z=I(w,n);n+=4;var s=U(w,n);n+=16}var O=J.IQ(w,n);n+=2;var a=w[n];n+=1;var X=jY.PB(!1,O,w,l.WH.m,l.WH.n,n,a);
jl.yv(l,X);if(A%4!=0)A+=4-A%4;n=g+A}return m};jl.yv=function(w,n){var W=w.WH.clone();W.x=W.y=0;w.HY=[n,W]};
jl.qD=function(w,n,W){var D=J._Z,j=J.zw;for(var L=0;L<W.length;L++){var I=W[L],U=n+4,m=56,A=1;n+=4;J.Tc(w,n,I.id);
n+=I.id.length+2;w.lN(n,1);w.data[n]=1;n+=3;D(w,n,3);n+=4;var M=n;n+=4;j(w,n,I.WH);n+=16;D(w,n,m);n+=4;
n+=m*4;D(w,n-4,1);var l=n;n+=4;D(w,n,8);n+=4;j(w,n,I.WH);n+=16;J.vo(w,n,8);n+=2;w.lN(n,1);w.data[n]=A;
n++;var g=I.HY[0];w.lN(n,I.WH.O()*2);n=jY.xd(!1,g,w.data,I.WH.m,I.WH.n,n,A);w.lN(n,8);n+=8;var k=n-U;
D(w,U-4,k);D(w,M,k-49);D(w,l,k-305);if(k%4!=0)n+=4-k%4}return n};function e0(){}e0.ew=function(w,n){var W=new Uint8Array(w),D=[],j=0,I=J.IQ(W,j);
j+=2;if(I!=4){throw"Unknown version of curves: "+I}var U=J.IQ(W,j);j+=2;for(var L=0;L<U;L++){var M=e0.YK(W,j);
j+=2+2*M.length;D.push(M)}if(j!=W.length){var m=J.sv(W,j,4);j+=4;var l=J.IQ(W,j);j+=2;var A=J.IQ(W,j);
j+=2;if(A!=0)throw"extra curves for channels"}var g=e0.pC(D,0);g.presetKind={t:"long",v:3};g.presetFileName={t:"TEXT",v:n.split("/").pop().split(".")[0]};
return[g]};e0.cW=function(w,n,W){var D=n,j=[],I=w[n];n+=3;var U=J.q(w,n);n+=4;for(var L=0;L<4;L++){var M=U>>>L&1;
if(M){if(I==0){var m=e0.YK(w,n);n+=2+2*m.length}else{var m=e0.afm(w,n);n+=256}j.push(m)}else j.push(I==0?[0,0,255,255]:e0.a9l())}var l=e0.pC(j,I);
return l};e0.pC=function(w,n){var W=cx._1("curv");for(var L=0;L<4;L++){if(n==0){var D=w[L],j=[];for(var I=0;
I<D.length;I+=2)j.push(E.MU.$j(D[I],D[I+1],!0));e0.nr(W,L,j)}else e0.nr(W,L,w[L])}return W};e0.k$=function(w,n,W){var D=[];
for(var L=0;L<4;L++){var j=e0.Qw(W,L);if(j.length==256)D.push(j);else{var I=[];for(var U=0;U<j.length;
U++)I.push(j[U].v.Hrzn.v,j[U].v.Vrtc.v);D.push(I)}}var M=n,m=D[0].length==256?1:0;w.lN(n,3);w.data[n]=m;
w.data[n+1]=0;w.data[n+2]=1;n+=3;J._Z(w,n,15);n+=4;for(var L=0;L<4;L++){var l=D[L];if(m==0){e0.avs(w,n,l);
n+=2+2*l.length}else{e0.aw8(w,n,l);n+=256}}return n-M};e0.a9l=function(){var w=[];for(var L=0;L<256;
L++)w.push(L);return w};e0.nr=function(w,n,W){var D=il.wc("CrvA",n);if(W.length<256)D.Crv={t:"VlLs",v:W};
else{D.Mpng={t:"VlLs",v:[]};for(var L=0;L<256;L++)D.Mpng.v[L]={t:"long",v:W[L]}}D={t:"Objc",v:D};var j=w.Adjs.v,I=il.va(j,n);
if(I==-1)j.push(D);else j[I]=D};e0.Qw=function(w,n){var W=w.Adjs.v,D=il.va(W,n);if(D==-1){if(W.length==0||W[0].v.Crv)return[E.MU.$j(0,0,!0),E.MU.$j(255,255,!0)];
if(W[0].v.autoMachineLearning||W[0].v.AuCo)return[E.MU.$j(0,0,!0),E.MU.$j(128,160,!0),E.MU.$j(255,255,!0)];
var j=[];for(var L=0;L<256;L++)j.push(L);return j}var I=W[D].v;if(I.Crv)return I.Crv.v;if(I.Mpng){var j=[];
for(var L=0;L<256;L++)j.push(I.Mpng.v[L].v);return j}return[E.MU.$j(0,0,!0),E.MU.$j(255,255,!0)]};e0.YK=function(w,n){var W=[],D=J.IQ(w,n);
n+=2;for(var j=0;j<D;j++){var I=J.IQ(w,n);n+=2;var U=J.IQ(w,n);n+=2;W.push(U,I)}return W};e0.avs=function(w,n,W){var D=W.length/2;
J.vo(w,n,D);n+=2;for(var j=0;j<D;j++){J.vo(w,n,W[j*2+1]);n+=2;J.vo(w,n,W[j*2+0]);n+=2}};e0.afm=function(w,n){var W=[];
for(var L=0;L<256;L++)W.push(w[n+L]);return W};e0.aw8=function(w,n,W){w.lN(n,256);for(var L=0;L<256;
L++)w.data[n+L]=W[L]};function cT(){}cT.cW=function(w,n,W){var D={},j=J.IQ(w,n);n+=2;D.AV=w[n]==1;n++;
n++;D.Ed=[J.zx(w,n),J.zx(w,n+2),J.zx(w,n+4)];n+=6;D.wF=[J.zx(w,n),J.zx(w,n+2),J.zx(w,n+4)];n+=6;D.D1=[];
for(var L=0;L<6;L++){var I={};I.k0=[J.zx(w,n),J.zx(w,n+2),J.zx(w,n+4),J.zx(w,n+6)];n+=8;I.Lh=[J.zx(w,n),J.zx(w,n+2),J.zx(w,n+4)];
n+=6;D.D1.push(I)}var U=cx._1("hue2"),M=D;if(U.Clrz==null)U.Clrz={t:"bool",v:!1};U.Clrz.v=M.AV;for(var L=0;
L<7;L++){var m=L==0?M.AV?M.Ed:M.wF:M.D1[L-1];cT.nr(U,L,m)}return U};cT.asA=function(w){return{classID:"Hst2",H:{t:"long",v:w[0]},Strt:{t:"long",v:w[1]},Lght:{t:"long",v:w[2]}}};
cT.va=function(w,n){for(var L=0;L<w.length;L++){var W=w[L].v.LclR;if(n==0&&W==null||W!=null&&W.v==n)return L}return-1};
cT.nr=function(w,n,W){var D=n==0?W:W.Lh,j=cT.asA(D);if(n!=0){var I=W.k0;j.LclR={t:"long",v:n},j.BgnR={t:"long",v:I[0]};
j.BgnS={t:"long",v:I[1]};j.EndS={t:"long",v:I[2]};j.EndR={t:"long",v:I[3]}}j={t:"Objc",v:j};var U=w.Adjs.v,M=cT.va(U,n);
if(M==-1)U.push(j);else U[M]=j};cT.Qw=function(w,n){var W=w.Adjs.v,D=cT.va(W,n);if(D==-1){if(n==0)return[0,0,0];
else return[{k0:[315,345,15,45],Lh:[0,0,0]},{k0:[15,45,75,105],Lh:[0,0,0]},{k0:[75,105,135,165],Lh:[0,0,0]},{k0:[135,165,195,225],Lh:[0,0,0]},{k0:[195,225,255,285],Lh:[0,0,0]},{k0:[255,285,315,345],Lh:[0,0,0]}][n-1]}var j=W[D].v,I=[j.H.v,j.Strt.v,j.Lght.v];
if(n==0)return I;return{Lh:I,k0:[j.BgnR.v,j.BgnS.v,j.EndS.v,j.EndR.v]}};cT.k$=function(w,n,W){var D={AV:W.Clrz?W.Clrz.v:!1,D1:[]};
D.Ed=D.wF=cT.Qw(W,0);for(var L=1;L<7;L++)D.D1.push(cT.Qw(W,L));var j=2+2+12+6*14,I=w.data;w.lN(n,j);
J.ey(I,n,2);n+=2;I[n]=D.AV?1:0;n++;n++;J.H$(I,n+0,D.Ed[0]);J.H$(I,n+2,D.Ed[1]);J.H$(I,n+4,D.Ed[2]);n+=6;
J.H$(I,n+0,D.wF[0]);J.H$(I,n+2,D.wF[1]);J.H$(I,n+4,D.wF[2]);n+=6;for(var L=0;L<6;L++){var U=D.D1[L].k0,M=D.D1[L].Lh;
J.H$(I,n+0,U[0]);J.H$(I,n+2,U[1]);J.H$(I,n+4,U[2]);J.H$(I,n+6,U[3]);n+=8;J.H$(I,n+0,M[0]);J.H$(I,n+2,M[1]);
J.H$(I,n+4,M[2]);n+=6}return j};function il(){}il.ew=function(w){var n=new Uint8Array(w),W=2,D=[];for(var L=0;
L<29;L++){var j=[];D.push(j);for(var I=0;I<5;I++)j.push(J.IQ(n,W+L*10+I*2))}W+=29*10;if(W<n.length){var U=J.sv(n,W,4);
W+=4;var M=J.IQ(n,W);W+=2;var m=J.IQ(n,W);W+=2;var l=m-29;for(var L=0;L<l;L++){var j=[];D.push(j);for(var I=0;
I<5;I++)j.push(J.IQ(n,W+L*10+I*2))}}var A=cx._1("levl");for(var L=0;L<4;L++)il.nr(A,L,D[L]);return A};
il.wc=function(w,L){var n=["Cmps","Rd","Grn","Bl"],W={t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:n[L]}}]};
return{classID:w,Chnl:W}};il.va=function(w,n){var W={Cmps:0,Rd:1,Grn:2,Bl:3};for(var L=0;L<w.length;
L++){var D=w[L].v,j=W[D.Chnl.v[0].v.enum];if(j==n)return L}return-1};il.nr=function(w,n,W){var D=il.wc("LvlA",n);
D.Inpt={t:"VlLs",v:[{t:"long",v:W[0]},{t:"long",v:W[1]}]};D.Otpt={t:"VlLs",v:[{t:"long",v:W[2]},{t:"long",v:W[3]}]};
D.Gmm={t:"doub",v:W[4]/100};D={t:"Objc",v:D};var j=w.Adjs.v,I=il.va(j,n);if(I==-1)j.push(D);else j[I]=D};
il.Qw=function(w,n){var W=[0,255,0,255,100],D=w.Adjs.v,j=il.va(D,n);if(j==-1)return W;var I=D[j].v;if(I.Inpt){W[0]=I.Inpt.v[0].v;
W[1]=I.Inpt.v[1].v}if(I.Otpt){W[2]=I.Otpt.v[0].v;W[3]=I.Otpt.v[1].v}if(I.Gmm){W[4]=Math.round(I.Gmm.v*100)}return W};
il.z8=function(w,n){var W=[],D=0;for(var L=0;L<4;L++)W.push(il.Qw(n,L));while(W.length<29)W.push([0,255,0,255,100]);
w.lN(0,2+10*29);J.ey(w.data,D,2);D+=2;for(var L=0;L<29;L++){var j=W[L];for(var I=0;I<5;I++)J.ey(w.data,D+L*10+I*2,j[I])}D+=29*10;
if(W.length==29)return D;w.lN(D,8+10*(W.length-29));J.Jm(w.data,D,"Lvls");D+=4;J.ey(w.data,D,3);D+=2;
J.ey(w.data,D,W.length);D+=2;var U=W.length-29;for(var L=0;L<U;L++){var j=W[29+L];for(var I=0;I<5;I++)J.ey(w.data,D+L*10+I*2,j[I])}D+=10*U;
return D};function bt(){}bt.ew=function(w){var n=new Uint8Array(w),W=2,D={ID:[],GM:[]},j=J.sv(n,W,4);
W+=4;var I=J.IQ(n,W);W+=2;var U=J.q(n,W);W+=4;D.ID=kj.EH(n,W,U);W+=U;var M=J.q(n,W);W+=4;for(var L=0;
L<M;L++){var m=J.q(n,W);W+=4;var l=W,A={UU:{},nK:{}};D.GM.push(A);W+=4;W+=jH.iS(n,A.UU,W);W+=4;W+=jH.iS(n,A.nK,W);
W=l+m;var g=A.nK.blendOptions,k=A.nK.Lefx;if(g&&Object.keys(g.v).length>1){}if(k){if(k.v.masterFXSwitch==null)k.v.masterFXSwitch={t:"bool",v:!0};
dR.ml(k.v)}}return D};bt.UG=function(w,n){w.UU.Nm.v=n};bt.z8=function(w){var n=new cs,W=0;J.vo(n,W,2);
W+=2;J.YY(n,W,"8BSL");W+=4;J.vo(n,W,3);W+=2;var D=W;W+=4;W=kj.iU(n,W,w.ID);J._Z(n,D,W-D-4);var j=w.GM.length;
J._Z(n,W,j);W+=4;for(var L=0;L<j;L++){W+=4;var I=W,U=w.GM[L];J._Z(n,W,16);W+=4;W+=jH.X3(n,U.UU,W);var M=U.nK.Lefx;
if(M){U.nK.Lefx=JSON.parse(JSON.stringify(M));dR.BA(U.nK.Lefx.v)}J._Z(n,W,16);W+=4;W+=jH.X3(n,U.nK,W);
if(M)U.nK.Lefx=M;J._Z(n,I-4,W-I)}return n.data.slice(0,W).buffer};function av(){}av.cW=function(w,n,W){var D=J.IQ(w,n);
n+=2;var j={};j.RK=J.IQ(w,n)==1;n+=2;j.pF=[];for(var L=0;L<10;L++){var I=[];j.pF.push(I);for(var U=0;
U<4;U++)I.push(J.zx(w,n+U*2));n+=8}var M=cx._1("selc");M.Mthd.v.CrcM=j.RK?"Absl":"Rltv";for(var L=1;
L<10;L++)av.nr(M,L-1,j.pF[L]);return M};av.Nw="Rds Ylws Grns Cyns Bls Mgnt Whts Ntrl Blks".split(" ");
av.wc=function(w,L){var n=["Cmps","Rd","Grn","Bl"],W={t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:n[L]}}]};
return{classID:w,Chnl:W}};av.va=function(w,n){var W=av.Nw;for(var L=0;L<w.length;L++){var D=w[L].v,j=W.indexOf(D.Clrs.v.Clrs);
if(j==n)return L}return-1};av.nr=function(w,n,W){var D=["Cyn","Mgnt","Ylw","Blck"],j={classID:"ClrC",Clrs:{t:"enum",v:{Clrs:av.Nw[n]}}};
for(var I=0;I<4;I++)j[D[I]]={t:"UntF",v:{type:"#Prc",val:W[I]}};j={t:"Objc",v:j};var U=w.ClrC.v,M=av.va(U,n);
if(M==-1)U.push(j);else U[M]=j};av.Qw=function(w,n){var W=[0,0,0,0],D=w.ClrC.v,j=av.va(D,n);if(j==-1)return W;
var I=["Cyn","Mgnt","Ylw","Blck"];for(var L=0;L<4;L++)if(D[j].v[I[L]])W[L]=D[j].v[I[L]].v.val;return W};
av.k$=function(w,n,W){var D={RK:W.Mthd.v.CrcM=="Absl",pF:[[0,0,0,0]]};for(var L=0;L<9;L++)D.pF.push(av.Qw(W,L));
w.lN(n,84);J.ey(w.data,n,1);n+=2;J.ey(w.data,n,D.RK?1:0);n+=2;for(var L=0;L<10;L++){var j=D.pF[L];for(var I=0;
I<4;I++)J.H$(w.data,n+I*2,j[I]);n+=8}return 84};function bI(){}bI._1=function(){return{H8:new iB(0,0,50,50),UU:"",fR:"play",i:E.P.AB.cX([.1,.1,.9,.5,.1,.9],0)}};
bI.ew=function(w){w=new Uint8Array(w);var n=0,W=[],D=Date.now(),j=J.sv(w,0,4);n+=4;var I=J.q(w,n);n+=4;
var U=J.q(w,n);n+=4;for(var L=0;L<U;L++){var M=J.CX(w,n);n+=M.length*2+4+2;if((M.length&1)==0)n+=2;n=bI.Dm(w,n,M,W)}return W};
bI.Dm=function(w,n,W,D){var j=J.q(w,n);n+=4;var I=J.q(w,n);n+=4;var U=n,M=J.$B(w,U).xi;U+=M.length+1;
var m=J._I(w,U);U+=16;var l=bI.mV(w,U,I-(U-n)),A=E.P.Mn(l),g=E.p.mY(A),k=1/g.m,$=1/g.n;E.P.c0(l,new eh(k,0,0,$,-g.x*k,-g.y*$));
D.push({fR:W,UU:M,i:l,H8:m});n+=I;return n};bI.UG=function(w,n){w.fR=n};bI.z8=function(w){var n=new cs,W=0;
J.YY(n,W,"cush");W+=4;J._Z(n,W,2);W+=4;J._Z(n,W,w.length);W+=4;for(var L=0;L<w.length;L++){var D=w[L],j=D.fR+"\0";
J.wk(n,W,j);W+=4+j.length*2;if((j.length&1)==1)W+=2;J._Z(n,W,1);W+=4;W+=4;var I=W;J.Tc(n,W,D.UU);W+=D.UU.length+1;
J.zw(n,W,D.H8);W+=16;n.lN(W,D.i.length*26);bI.yW(n.data,W,D.i,1,1);W+=D.i.length*26;var U=W-I;if((U&3)!=0)U+=4-(U&3);
J._Z(n,I-4,U);W=I+U}return n.data.slice(0,W).buffer};bI.afh=function(w){var n=[];for(var L=0;L<w.length;
L++){var W=w[L],D=W.type,j={type:D};n.push(j);if(D==6){}else if(D==8)j.all=W.all;else if(D==0||D==3){j.length=W.length;
j.frule=W.Ht;j.third=W.S1;j.prmA=W._T;j.prmB=W.si}else{j.c=[W.T7.x,W.T7.y,W.H.x,W.H.y,W.mO.x,W.mO.y]}}return n};
bI.sy=function(w){var n=[];for(var L=0;L<w.length;L++){var W=w[L],D=W.type,j={type:D};n.push(j);if(D==6){}else if(D==8)j.all=W.all;
else if(D==0||D==3){j.length=W.length;j.Ht=W.frule;j.S1=W.third;j._T=W.prmA;j.si=W.prmB}else{var I=W.c;
j.T7=new ec(I[0],I[1]);j.H=new ec(I[2],I[3]);j.mO=new ec(I[4],I[5])}}return n};bI.mV=function(w,n,W,D,j){if(D==null)D=1;
if(j==null)j=1;function I(f,z,s){var O=J.a8m(f,z)*s,a=Math.round(O);return Math.abs(O-a)<1e-6?a:O}var U=J.zx,M=[],m=Math.floor(W/26);
for(var L=0;L<m;L++){var l=n+L*26,A={},g=0;M.push(A);A.type=U(w,l);l+=2;if(A.type==6){g=24}if(A.type==8){A.all=U(w,l);
l+=2;g=22}if(A.type==0||A.type==3){A.length=U(w,l);l+=2;A.Ht=U(w,l);l+=2;A.S1=U(w,l);l+=2;A._T=J.q(w,l);
l+=4;A.si=J.q(w,l);l+=4;g=10}if(A.type==1||A.type==2||A.type==4||A.type==5){var k,$;$=I(w,l,j);l+=4;
k=I(w,l,D);l+=4;A.T7=new ec(k,$);$=I(w,l,j);l+=4;k=I(w,l,D);l+=4;A.H=new ec(k,$);$=I(w,l,j);l+=4;k=I(w,l,D);
l+=4;A.mO=new ec(k,$);g=0}for(var C=0;C<g;C++)if(w[l+C]!=0){console.log("Unexpected non-zero byte!",A,C,w[l+C])}}return M};
bI.yW=function(w,n,W,D,j){var I=J.H$,U=J.atj,M=W.length;for(var L=0;L<M;L++){var m=n+L*26,l=W[L];I(w,m,l.type);
m+=2;if(l.type==6){}if(l.type==8)I(w,m,l.all);if(l.type==0||l.type==3){I(w,m,l.length);m+=2;I(w,m,l.Ht);
m+=2;I(w,m,l.S1);m+=2}if(l.type==1||l.type==2||l.type==4||l.type==5){U(w,m,l.T7.y/j);m+=4;U(w,m,l.T7.x/D);
m+=4;U(w,m,l.H.y/j);m+=4;U(w,m,l.H.x/D);m+=4;U(w,m,l.mO.y/j);m+=4;U(w,m,l.mO.x/D);m+=4}}};function dm(){}dm.ew=function(w){var n=new Uint8Array(w),W=[],D=0;
if(J.sv(n,0,4)=="ASEF")W=dm.arW(n);else{D=dm.ln(n,D,W);if(D+3<n.length){W=[];D=dm.ln(n,D,W)}}return W};
dm.arW=function(w){var n=[],W=8,D=J.q(w,W),j,I=null,U,M,m,l;W+=4;for(var A=0;A<D;A++){var g=J.IQ(w,W);
W+=2;var k=J.q(w,W);W+=4;var $=W+k;if(g==49153||g==1){var C=J.IQ(w,W);W+=2;var f=J.yL(w,W,C-1);W+=C*2;
if(g==1)j=f;else I=f}if(g==1){var z=J.sv(w,W,4);W+=4;U=J.F_(w,W);W+=4;M=J.F_(w,W);W+=4;m=J.F_(w,W);W+=4;
if(z=="RGB "){}else if(z=="CMYK"){l=J.F_(w,W);W+=4;var s=UDOC.C.cmykToRgb([U,M,m,l]);U=s[0];M=s[1];m=s[2]}else alert("Unknown color space: "+z);
n.push({o:U*255,B:M*255,k:m*255,A7:(I?I+" : ":"")+j})}W=$}return n};dm.ln=function(w,n,W){var D=J.IQ,j=J.zx,I=D(w,n);
n+=2;var U=D(w,n);n+=2;for(var L=0;L<U;L++){var M=dm.mn(w,n);n+=10;if(I==2){M.A7=J.CX(w,n);n+=4+M.A7.length*2+2}W.push(M)}return n};
dm.mn=function(w,n){var W=J.IQ,D=J.zx,j=W(w,n),$=null;n+=2;var I=W(w,n);n+=2;var U=W(w,n);n+=2;var M=W(w,n);
n+=2;var m=W(w,n);n+=2;var l=1/65535,A=255/65535,g=100/65535,k=255/1e4;if(j==0)$={o:I*A,B:U*A,k:M*A};
else if(j==1){$=E.li(I*l,U*l,M*l);$.o*=255;$.B*=255;$.k*=255}else if(j==2)$=E.M.y_({classID:"CMYC",Cyn:{t:"doub",v:100-I*g},Mgnt:{t:"doub",v:100-U*g},Ylw:{t:"doub",v:100-M*g},Blck:{t:"doub",v:100-m*g}});
else if(j==7){var C=E.kH(I/100,D(w,n-6)/100,D(w,n-4)/100);$=C}else if(j==8){$={o:255-I*k,B:255-U*k,k:255-M*k}}else if(j==18){var f=255*I/16384;
$={o:f,B:f,k:f}}else{throw j}return $};dm.z8=function(w){var n=new cs,W=0,D=J.vo;D(n,W,2);W+=2;D(n,W,w.length);
W+=2;for(var L=0;L<w.length;L++){var j=w[L];n.lN(W,10);dm.Dg(n.data,W,j);W+=10;var I=(j.A7?j.A7:"")+"\0";
J.wk(n,W,I);W+=4+I.length*2}return n.data.slice(0,W).buffer};dm.UG=function(w,n){w.A7=n};dm.Dg=function(w,n,W){var D=65535/255,j=J.ey;
j(w,n,0);j(w,n+2,Math.round(W.o*D));j(w,n+4,Math.round(W.B*D));j(w,n+6,Math.round(W.k*D));j(w,n+8,0)};
function gc(){}gc.ew=function(w){var n=new Uint8Array(w),W=4,D={};D.s7=J.CX(n,W);W+=4+D.s7.length*2+2;
D.exp=n[W++]==1;D.xq=[];var j=J.q(n,W);W+=4;for(var L=0;L<j;L++){var I={};D.xq.push(I);I.p_=J.IQ(n,W);
W+=2;I.shift=n[W++]==1;I.acT=n[W++]==1;I.color=J.IQ(n,W);W+=2;I.s7=J.CX(n,W);W+=4+I.s7.length*2+2;I.exp=n[W++]==1;
I.xq=[];var U=J.q(n,W);W+=4;for(var M=0;M<U;M++){var m={};I.xq.push(m);m.exp=n[W++]==1;m.r=n[W++]==1;
m.aiK=n[W++]==1;m.ahp=n[W++];var l=J.sv(n,W,4);W+=4;if(l=="TEXT"){m.hZ=gc.mG(n,W);W+=4+m.hZ.length}else if(l=="long"){m.hZ=J.sv(n,W,4);
W+=4}else throw"e";m.oA=gc.mG(n,W);W+=4+m.oA.length;var A=J.W6(n,W);W+=4;if(A==-1){m.E3={};var g=jH.iS(n,m.E3,W);
W+=g}}}console.log(D);var k=new Uint8Array(gc.z8(D));for(var L=0;L<k.length;L++)if(k[L]!=n[L]&&J.sv(n,L+1,4)!="None"){console.log(n.length,k.length);
var $=4*(L>>>2)-16;console.log(J.eS(n,$,64));console.log(J.eS(k,$,64));console.log(n.slice($,$+64));
console.log(k.slice($,$+64));throw"i"}return[D]};gc.mG=function(w,n){var W=J.q(w,n);return J.sv(w,n+4,W)};
gc.KQ=function(w,n,W){J._Z(w,n,W.length);J.YY(w,n+4,W)};gc.z8=function(w){var n=new cs,W=0;J._Z(n,W,16);
W+=4;J.wk(n,W,w.s7+"\0");W+=4+w.s7.length*2+2;n.lN(W,1);n.data[W++]=w.exp?1:0;var D=w.xq.length;J._Z(n,W,D);
W+=4;for(var L=0;L<D;L++){var j=w.xq[L];J.vo(n,W,j.p_);W+=2;n.lN(W,2);n.data[W++]=j.shift?1:0;n.data[W++]=j.acT?1:0;
J.vo(n,W,j.color);W+=2;J.wk(n,W,j.s7+"\0");W+=4+j.s7.length*2+2;n.lN(W,1);n.data[W++]=j.exp?1:0;var I=j.xq.length;
J._Z(n,W,I);W+=4;for(var U=0;U<I;U++){var M=j.xq[U];n.lN(W,4);n.data[W++]=M.exp?1:0;n.data[W++]=M.r?1:0;
n.data[W++]=M.aiK?1:0;n.data[W++]=M.ahp;var m="LqFy Avrg GEfc PbPl Fbrs Bokh LnCr".split(" ").indexOf(M.hZ)!=-1;
J.YY(n,W,m?"long":"TEXT");W+=4;if(!m){gc.KQ(n,W,M.hZ);W+=4+M.hZ.length}else{J.YY(n,W,M.hZ);W+=4}gc.KQ(n,W,M.oA);
W+=4+M.oA.length;J.Wr(n,W,M.E3?-1:0);W+=4;if(M.E3){var l=jH.X3(n,M.E3,W);W+=l}}}return n.data.slice(0,W).buffer};
function fH(){}fH.ew=function(w){var n=new Uint8Array(w),W=0,D=J.q(n,W),m;W+=4;var j=J.sv(n,W,8);W+=8;
var I=J.ly(n,W);W+=4;var U=J.ly(n,W);W+=4;var M=J.ly(n,W);W+=4;if(D==2){m=new Float32Array(w,32,w.byteLength-32>>>2)}else if(D==3||D==4){m=new Float32Array(U*M*2);
var l=0,A=0,g=!0;W=D==3?32:16+8+40;while(W<n.length){var k=J.ly(n,W);W+=4;if(g)A+=k;else{for(var L=0;
L<k;L++){m[l+A+L<<1]=J.mg(n,W);m[(l+A+L<<1)+1]=J.mg(n,W+4);W+=8}A+=k}g=!g;if(k!=0&&A==U){l+=U;A=0;g=!0;
if(l==U*M)break}}}else throw"unknown Mesh version: "+D;return{gA:U,ag:M,map:m}};fH.Pj=function(w){var n=w.gA,W=w.ag,D=w.map,j=new Uint8Array(32+W*n*8+W*8),I=0,U=0;
J.Ms(j,I,3);I+=4;J.Jm(j,I,"yfqLhseM");I+=8;J.Fr(j,I,2);I+=4;J.Fr(j,I,n);I+=4;J.Fr(j,I,W);I+=4;J.Fr(j,I,0);
I+=4;J.Fr(j,I,1);I+=4;for(var M=0;M<W;M++){J.Fr(j,I,0);I+=4;J.Fr(j,I,n);I+=4;for(var m=0;m<n;m++){J.P5(j,I,D[U]);
J.P5(j,I+4,D[U+1]);U+=2;I+=8}}return j.buffer};function c7(){}c7.ew=function(w){var n=new Uint8Array(w),W=0,D=J.sv(n,W,4);
W+=4;var j=J.IQ(n,W);W+=2;var I=J.q(n,W);W+=4;var U=[];for(var L=0;L<I;L++){var M=J.q(n,W);W+=4;var m={classID:"ShpC",Nm:{t:"TEXT",v:""},Crv:{t:"VlLs",v:[]}};
U.push(m);var l=J.CX(n,W);m.Nm.v=l;W+=4+l.length*2+2;var A=J.IQ(n,W);W+=2;var g=J.IQ(n,W);W+=2;for(var k=0;
k<g;k++){var $=E.MU.$j(0,0,!0);$.v.Vrtc.v=J.IQ(n,W);W+=2;$.v.Hrzn.v=J.IQ(n,W);W+=2;m.Crv.v.push($)}if(M==1){}else if(M==2){for(var k=0;
k<g;k++){m.Crv.v[k].v.Cnty.v=n[W]==1;W+=1}}else throw"error";var C=J.q(n,W);W+=4;var f=J.q(n,W);W+=4}return U};
c7.UG=function(w,n){w.Nm.v=n};c7.z8=function(w){var n=new cs,W=0;J.YY(n,W,"8BFS");W+=4;J.vo(n,W,1);W+=2;
J._Z(n,W,w.length);W+=4;for(var L=0;L<w.length;L++){J._Z(n,W,2);W+=4;var D=w[L];J.wk(n,W,D.Nm.v+"\0");
W+=4+D.Nm.v.length*2+2;J.vo(n,W,2);W+=2;var j=D.Crv.v.length;J.vo(n,W,j);W+=2;for(var I=0;I<j;I++){var U=D.Crv.v[I];
J.vo(n,W,U.v.Vrtc.v);W+=2;J.vo(n,W,U.v.Hrzn.v);W+=2}n.lN(W,j);for(var I=0;I<j;I++){n.data[W]=D.Crv.v[I].v.Cnty.v;
W++}J._Z(n,W,0);W+=4;J._Z(n,W,0);W+=4}return n.data.slice(0,W).buffer};function kj(){}kj.ew=function(w){var n=new Uint8Array(w),W=4,D=J.IQ(n,W);
W+=2;var j=J.q(n,W);W+=4;var I=[];for(var L=0;L<j;L++){var U={};I.push(U);W=kj.azq(n,W,U)}return I};
kj.UG=function(w,n){w.name=n};kj.z8=function(w){var n=new cs,W=0;J.YY(n,W,"8BPT");W+=4;J.vo(n,W,1);W+=2;
J._Z(n,W,w.length);W+=4;for(var L=0;L<w.length;L++){W=kj.ajB(n,W,w[L])}return n.data.slice(0,W).buffer};
kj.EH=function(w,n,W){var D=n+W,j=[];while(n<D){var I={},U=J.q(w,n);n+=4;var M=n;n=kj.azq(w,n,I);if(!I.HY[1].VY())j.push(I);
if(U%4!=0)U+=4-U%4;n=M+U}return j};kj.iU=function(w,n,W){for(var L=0;L<W.length;L++){var D=W[L];n+=4;
var j=n;n=kj.ajB(w,n,D);var I=n-j;J._Z(w,j-4,I);if(I%4!=0)j+=4-I%4;n=j+I}return n};kj.azq=function(w,n,W){var D=J.q(w,n);
n+=4;if(D!=1)alert("Unknown version of pattern");var j=J.q(w,n);n+=4;if(j!=1&&j!=2&&j!=3)console.log("Unsupported mode of pattern: "+j);
var I=J.IQ(w,n);n+=2;var U=J.IQ(w,n);n+=2;var M=new iB(0,0,U,I);W.name=J.CX(w,n);n+=4+2*W.name.length+2;
var m=w[n];n++;W.id=J.sv(w,n,m);n+=W.id.length;var l=-1;if(j==2){l=n;n+=3*256+4}var A=new E.H0(U*I);
n=kj.atR(w,n,A);if(j==2){for(var L=0;L<A.o.length;L++){var g=3*A.o[L];A.o[L]=w[l+g+0];A.B[L]=w[l+g+1];
A.k[L]=w[l+g+2]}}var k=E.Q(M.O()*4);E.kX(A,k);W.HY=[k,M];return n};kj.ajB=function(w,n,W){var D=W.HY[0],j=W.HY[1];
J._Z(w,n,1);n+=4;J._Z(w,n,3);n+=4;J.vo(w,n,j.n);n+=2;J.vo(w,n,j.m);n+=2;J.wk(w,n,W.name+"\0");n+=4+2*W.name.length+2;
J.kW(w,n,W.id.length);n++;J.YY(w,n,W.id);n+=W.id.length;var I=new E.H0(j.O());E.rH(D,I);n=kj.abe(w,n,I,j);
return n};kj.atR=function(w,n,W){var D=n,j={WH:null,zC:[],arI:null,ul:null},I=J.q(w,n);n+=4;var U=J.q(w,n);
n+=4;j.WH=J._I(w,n);n+=16;var M=J.q(w,n);n+=4;for(var L=0;L<M+2;L++){var m=J.q(w,n);n+=4;if(m==0)continue;
var l=J.q(w,n);n+=4;if(l==0)continue;var A=J.q(w,n);n+=4;var g=J._I(w,n);n+=16;var k=J.IQ(w,n);n+=2;
var $=w[n];n++;var C=jY.PB(!1,A,w,g.m,g.n,n,$);if(L<M)j.zC.push(C);if(L==M)j.arI=C;if(L==M+1)j.ul=C;
n+=l-23}if(!j.WH.VY()){if(j.zC[0])W.o=j.zC[0];if(j.zC[1])W.B=j.zC[1];else W.B=j.zC[0].slice(0);if(j.zC[2])W.k=j.zC[2];
else W.k=j.zC[0].slice(0);if(j.ul)W.dl=j.ul;else W.dl.fill(255)}return n};kj.abe=function(w,n,W,D){var j=n,I={WH:D,zC:[W.o,W.B,W.k],arI:null,ul:W.dl};
J._Z(w,n,3);n+=4;J._Z(w,n,0);n+=4;J.zw(w,n,D);n+=16;J._Z(w,n,24);n+=4;for(var L=0;L<24+2;L++){var U=n,M=L<3||L==25?1:0;
J._Z(w,n,M);n+=4;if(M==0)continue;J._Z(w,n,0);n+=4;J._Z(w,n,8);n+=4;J.zw(w,n,D);n+=16;J.vo(w,n,8);n+=2;
J.kW(w,n,1,1);n++;var m=L<3?I.zC[L]:I.ul;w.lN(n,D.O()+2);n=jY.xd(!1,m,w.data,D.m,D.n,n,1);J._Z(w,U+4,n-U-8)}J._Z(w,j+4,n-j-8);
return n};function f8(){}f8.ew=function(w){var n=new Uint8Array(w),W=0;if(n[0]==71)return f8.acd(n);
var D=J.sv(n,W,4);W+=4;var j=J.IQ(n,W);W+=2;var I=[];if(j<=3){var U=J.IQ(n,W);W+=2;for(var L=0;L<U;L++){var M=n[W++],m=J.sv(n,W,M);
W+=M;var l=f8.a19(n,W,m),A=l[0];W=l[1];I.push(A)}}else{var l={},g=jH.iS(n,l,W+4),k=l.GrdL.v;for(var L=0;
L<k.length;L++)I[L]=k[L].v.Grad.v}return I};f8.UG=function(w,n){w.Nm.v=n};f8.z8=function(w){var n=new cs,W=0;
J.YY(n,W,"8BGR");W+=4;J.vo(n,W,5);W+=2;J._Z(n,W,16);W+=4;var D={classID:"null",GrdL:{t:"VlLs",v:[]}},j=D.GrdL.v;
for(var L=0;L<w.length;L++)j[L]={t:"Objc",v:{classID:"Grdn",__name:"Gradient ",Grad:{t:"Objc",v:w[L]}}};
W+=jH.X3(n,D,W);return n.data.slice(0,W).buffer};f8.a19=function(w,n,W){var D={classID:"Grdn",Clrs:{t:"VlLs",v:[]},GrdF:{t:"enum",v:{GrdF:"CstS"}},Intr:{t:"doub",v:4096},Nm:{t:"TEXT",v:W},Trns:{t:"VlLs",v:[]}},j=J.IQ(w,n);
n+=2;if(j==0)throw"e";for(var L=0;L<j;L++){var I=J.q(w,n),U=J.q(w,n+4),M=dm.mn(w,n+8),m={t:"Objc",v:{classID:"Clrt",Clr:{t:"Objc",v:{classID:"RGBC",Rd:{t:"doub",v:M.o},Grn:{t:"doub",v:M.B},Bl:{t:"doub",v:M.k}}},Type:{t:"enum",v:{Clry:"UsrS"}},Lctn:{t:"long",v:I},Mdpn:{t:"long",v:U}}};
D.Clrs.v.push(m);n+=20}var l=J.IQ(w,n);n+=2;for(var L=0;L<l;L++){var I=J.q(w,n),U=J.q(w,n+4),A=J.IQ(w,n+8),m={t:"Objc",v:{classID:"TrnS",Opct:{t:"UntF",v:{type:"#Prc",val:Math.round(100*A/255)}},Lctn:{t:"long",v:I},Mdpn:{t:"long",v:U}}};
D.Trns.v.push(m);n+=10}var g=J.IQ(w,n);n+=2;D.Intr.v=g==2?J.IQ(w,n):4096;n+=2;var k=J.IQ(w,n);n+=2;return[D,n]};
f8.ayK=function(w,n,W){var D=W.Clrs.v.length;J.vo(w,n,D);n+=2;for(var L=0;L<D;L++){var j=W.Clrs.v[L];
J._Z(w,n,j.v.Lctn.v);J._Z(w,n+4,j.v.Mdpn.v);J.vo(w,n+8,0);var I=E.M.lW(E.M.y_(j.v.Clr.v)),U=[I.Rd.v,I.Grn.v,I.Bl.v,0];
for(var M=0;M<4;M++)J.vo(w,n+10+M*2,Math.round(65535*(U[M]/255)));n+=20}var m=W.Trns.v.length;J.vo(w,n,m);
n+=2;for(var L=0;L<m;L++){var j=W.Trns.v[L];J._Z(w,n,j.v.Lctn.v);J._Z(w,n+4,j.v.Mdpn.v);J.vo(w,n+8,Math.round(255*j.v.Opct.v.val/100));
n+=10}J.vo(w,n,2);n+=2;J.vo(w,n,W.Intr.v);n+=2;J.vo(w,n,32);n+=2;return n};f8.acd=function(w){var n=J.KY(w,0,w.length).split("\n"),W=parseFloat(n[2]),D=[],j=JSON.parse(at.UR[at.order.indexOf("GrFl")]).Grad.v;
j.Intr.v=0;j.Nm.v=n[1];for(var L=0;L<W;L++){var I=n[3+L].split(" ").map(parseFloat),U=I[11],M=I[12];
D.push([I[0],I.slice(3,6),I[6]]);if(M!=0){var m=E.i8(I[3],I[4],I[5]),l=E.i8(I[7],I[8],I[9]),A=m.ag,g=l.ag;
if(M==1&&A>g)g++;if(M==2&&A<g)A++;var k=Math.round(Math.abs(g-A)*7);if(k>1)for(var $=0;$<k;$++){var C=1-($+1)/(k+1),f=1-C,z=E.li(C*A+f*g,C*m._6+f*l._6,C*m.jB+f*l.jB);
D.push([C*I[0]+f*I[2],[z.o,z.B,z.k],C*I[6]+f*I[10]])}}D.push([I[2],I.slice(7,10),I[10]])}D.sort(function(s,O){return s[0]-O[0]});
E.M.WP(D,j);return[j]};function kt(){}kt.ew=function(w){var n=new Uint8Array(w),W=[],D=[],j=[],I=[],U=[],M=0,m=J.sv(n,M,4);
M+=4;var l=J.q(n,M);M+=4;var A=J.q(n,M);M+=4;while(M<n.length){var g=J.sv(n,M,4);M+=4;var k=J.sv(n,M,4);
M+=4;var $=J.q(n,M);M+=4;if(k=="tppa"){D=kj.EH(n,M,$);M+=$}else if(k=="tpbd"){j=jl._G(n,M,$,1,1);M+=$}else if(k=="tptp"){var C=J.q(n,M);
M+=4;for(var L=0;L<C;L++){var f=J.CX(n,M);M+=6+f.length*2;M+=4;var z={};M+=jH.iS(n,z,M);W.push([f,z])}while((M&3)!=0)M++}else if(k=="tpsh"){var s=M,O=n.slice(M,M+$);
while(M<s+$){var a=J.q(n,M);M+=4;M=bI.Dm(n,M,"Shape",I)}M=s+$}else if(k=="tpst"){var s=M;M+=4;while(M<s+$){var X=J.q(n,M);
M+=4;var P=M,Z=J.q(n,M);M+=4;var z={UU:{},nK:{}};U.push(z);M+=4;M+=jH.iS(n,z.UU,M);M+=4;M+=jH.iS(n,z.nK,M);
M=P+X;var Y=z.nK.Lefx;if(Y){if(Y.v.masterFXSwitch==null)Y.v.masterFXSwitch={t:"bool",v:!0};dR.ml(Y.v)}}M=s+$}else{console.log(n.slice(M-8,M+64));
console.log(J.sv(n,M-8,64));throw k}}return{yg:j,j6:D,list:W,ad1:I,GM:U}};kt.UG=function(w,n){w[0]=n};
kt.z8=function(w){var n=new cs,W=0;J.YY(n,W,"8BTP");W+=4;J._Z(n,W,3);W+=4;J._Z(n,W,1);W+=4;var D=[w.j6,w.yg,w.list];
for(var L=0;L<3;L++){if(D[L].length==0)continue;J.YY(n,W,"8BIM");W+=4;var j=["tppa","tpbd","tptp"][L];
J.YY(n,W,j);W+=4;var I=W;W+=4;if(j=="tppa"){W=kj.iU(n,W,w.j6)}else if(j=="tpbd"){W=jl.qD(n,W,w.yg)}else if(j=="tptp"){J._Z(n,W,w.list.length);
W+=4;for(var U=0;U<w.list.length;U++){var M=w.list[U];J.wk(n,W,M[0]+"\0");W+=6+M[0].length*2;J._Z(n,W,16);
W+=4;W+=jH.X3(n,M[1],W)}}J._Z(n,I,W-I-4);while((W&3)!=0)W++;n.lN(W,0)}return n.data.slice(0,W).buffer};
function jF(){}jF.ew=function(w,n){var W=new Uint8Array(w),D;if(J.q(W,0)==W.length)D="icc";else if(W[0]=="<".charCodeAt(0))D="look";
else if(J.TN(W,"LUT_3D_SIZE")!=-1)D="cube";else D="3DL";if(D!="icc"){var j=jF.abB(W,D),I=jF.auc(j[0],j[1]);
W=I}var U=[];for(var L=0;L<W.length;L++)U.push(W[L]);return[{classID:"null",Dthr:{t:"bool",v:!0},Nm:{t:"TEXT",v:n?n:"file.icc"},lookupType:{t:"enum",v:{colorLookupType:"abstractProfile"}},profile:{t:"tdta",v:U}}]};
jF.z8=function(w){var n=w[0],W=new Uint8Array(n.profile.v);return W.buffer};jF.UG=function(w,n){w.Nm.v=n};
jF.auc=function(w,n){var W=new cs,D=128;W.lN(0,128);var j=[0,0,14,204,65,68,66,69,4,0,0,0,108,105,110,107,82,71,66,32,82,71,66,32,7,227,0,7,0,27,0,8,0,6,0,49,97,99,115,112,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,246,214,0,1,0,0,0,0,211,45,65,68,66,69,219,126,245,21,206,223,186,23,165,212,201,219,250,10,33,62];
for(var L=0;L<j.length;L++)W.data[L]=j[L];var I=["desc","A2B0"],U=I.length,M=128+4+U*12;J._Z(W,D,U);
D+=4;for(var m=0;m<U;m++){var l=I[m];J.YY(W,D,l);D+=4;J._Z(W,D,M);D+=4;var A=M;if(l=="desc"){J.YY(W,A,"mluc");
A+=4;A+=4;J._Z(W,A,1);A+=4;J._Z(W,A,12);A+=4;J.YY(W,A,"enUS");A+=4;var g="ICC by Photopea\0",k=g.length*2+2;
J._Z(W,A,k);A+=4;J._Z(W,A,28);A+=4;W.lN(A,k);for(var L=0;L<g.length;L++)W.data[A+L*2+1]=g.charCodeAt(L);
A+=k}if(l=="A2B0"){J.YY(W,A,"mAB ");A+=4;A+=4;W.lN(A,4);W.data[A]=3;W.data[A+1]=3;A+=4;W.lN(A,4*5);A+=4*3;
J._Z(W,A,A+8-M);A+=4;A+=4;W.lN(A,20);W.data[A]=w;W.data[A+1]=w;W.data[A+2]=w;A+=16;W.data[A]=2;A+=4;
var $=w*w*w*3;W.lN(A,$*2);for(var L=0;L<$;L++)J.ey(W.data,A+L*2,Math.max(0,Math.min(65535,Math.round(n[L]*65535))));
A+=$*2}var C=A-M;while((C&3)!=0)C++;J._Z(W,D,C);D+=4;M+=C}J._Z(W,0,M);return W.data.slice(0,M)};jF.abB=function(w,n){n="LUTFormat"+n.toUpperCase();
var W=[],D=0,j=J.KY(w,0,w.length),I="";for(var L=0;L<w.length&&I=="";L++){if(w[L]==10)I="\n";else if(w[L]==13){I="\r";
if(w[L+1]==10)I+="\n"}}if(n=="LUTFormatCUBE"){var U=j.split(I);for(var L=0;L<U.length;L++){if(U[L]==""||U[L][0]=="#")continue;
var M=U[L].split(" "),m=M[0];if(m=="LUT_3D_SIZE"){D=parseInt(M[1]);continue}if(["TITLE","DOMAIN_MIN","DOMAIN_MAX"].indexOf(m)!=-1)continue;
W.push(parseFloat(M[0]),parseFloat(M[1]),parseFloat(M[2]))}W=jF.$E(D,W)}else if(n=="LUTFormat3DL"){var U=j.split(I),l=1/4095;
for(var L=0;L<U.length;L++){var A=U[L];if(A==""||A=="3DMESH"||A.startsWith("Mesh")||A[0]=="#")continue;
var M=A.split(" "),m=M[0];if(D==0){D=M.length;continue}W.push(parseFloat(M[0])*l,parseFloat(M[1])*l,parseFloat(M[2])*l)}}else if(n=="LUTFormatLOOK"){var g=new DOMParser,k=g.parseFromString(j,"text/xml"),$=k.getElementsByTagName("LUT")[0],C=$.children[0].textContent;
D=parseInt(JSON.parse(C));var f=$.children[1].textContent;f=f.replace(/"/g,"").replace(/\s/g,"");var z=3*D*D*D,s=z*4,O=new Uint8Array(s);for(var L=0;L<s;L++){var a=f.charCodeAt(L*2),X=f.charCodeAt(L*2+1),P=a<58?a-48:a-55,Z=X<58?X-48:X-55;O[L]=(P<<4)+Z}for(var L=0;L<z;L++)W.push(J.mg(O,L<<2));W=jF.$E(D,W)}else throw n;return[D,W]};jF.aia=function(w,n,W){var D=["#Created by www.Photopea.com","TITLE \""+W+"\"","","#LUT size","LUT_3D_SIZE "+n,"","#data domain","DOMAIN_MIN 0.0 0.0 0.0","DOMAIN_MAX 1.0 1.0 1.0","","#LUT data points"],j=6;
for(var L=0;L<w.length;L+=3){D.push(w[L].toFixed(j)+" "+w[L+1].toFixed(j)+" "+w[L+2].toFixed(j))}D.push("");
return J.zY(D.join("\n")).buffer};jF.$E=function(w,n){var W=[],D=w*w*w;for(var L=0;L<D;L++)W.push(0,0,0);
for(var j=0;j<w;j++)for(var I=0;I<w;I++)for(var U=0;U<w;U++){var L=3*(U+I*w+j*w*w),M=3*(j+I*w+U*w*w);
W[M]=n[L];W[M+1]=n[L+1];W[M+2]=n[L+2]}return W};function jH(){}jH.iS=function(w,n,W,D,j){var I=W,U;if(j==null)j=0;
var M=J.q(w,W);if(M==0){U="";W+=4}else{U=J.CX(w,W);W+=4+2*U.length+2}if(U!="")n.__name=U;n.classID=jH.tv(w,W);
if(D)console.log("\t".repeat(j),"- reading descriptor",n.classID,W);W+=jH.Ws(w,W);var m=J.W6(w,W);W+=4;
for(var L=0;L<m;L++){var l=jH.tv(w,W);W+=jH.Ws(w,W);var A=jH.ajo(w,W,D,j);n[l]=A;W+=A.size;delete A.size}return W-I};
jH.X3=function(w,n,W,D){var j=W,I=n.__name;if(I==null)I="";I+="\0";J.wk(w,W,I);W+=4+2*I.length;jH.gy(w,W,n.classID);
W+=jH.Ws(w.data,W);J.Wr(w,W,Object.keys(n).length-1-(n.__name==null?0:1));W+=4;for(var U in n){if(U=="classID")continue;
if(U=="__name")continue;jH.gy(w,W,U);W+=jH.Ws(w.data,W);W+=jH.aiS(w,W,n[U])}return W-j};jH.ajo=function(w,n,W,D){var j=n,I=J.sv(w,n,4);
n+=4;var U={size:0,t:I,v:null};if(W)console.log("\t".repeat(D),"reading key",I,j);switch(I){case"obj ":case"VlLs":U.v=[];
var M=J.q(w,n);n+=4;for(var L=0;L<M;L++){var m=jH.ajo(w,n,W,D+1);n+=m.size;delete m.size;U.v.push(m)}break;
case"UntF":U.v={type:J.sv(w,n,4),val:J.Gb(w,n+4)};n+=12;break;case"doub":U.v=J.Gb(w,n);n+=8;break;case"bool":U.v=w[n]==1;
n+=1;break;case"long":U.v=J.W6(w,n);n+=4;break;case"comp":U.v=J.W6(w,n+4);n+=8;break;case"Objc":U.v={};
var l=jH.iS(w,U.v,n,W,D+1);n+=l;break;case"TEXT":var A=J.q(w,n);if(A==0){U.v="";n+=4}else{U.v=J.CX(w,n);
n+=4+U.v.length*2+2}break;case"enum":var g=jH.tv(w,n);n+=jH.Ws(w,n);var k=jH.tv(w,n);n+=jH.Ws(w,n);U.v={};
U.v[g]=k;break;case"tdta":var $=J.W6(w,n);n+=4;U.v=[];for(var L=0;L<$;L++)U.v.push(w[n+L]);n+=$;break;
case"ObAr":var C=J.q(w,n);n+=4;var f=J.CX(w,n);n+=4+2*f.length+2;if(f!="")throw f;var z=jH.tv(w,n);n+=4+Math.max(4,z.length);
U.v={classID:z,arr:[]};var s=J.q(w,n);n+=4;for(var L=0;L<s;L++){var z=jH.tv(w,n);n+=4+Math.max(4,z.length);
var g=J.sv(w,n,4);n+=4;var O=J.sv(w,n,4);n+=4;var a={id:z,type:g,uID:O,arr:[]};U.v.arr.push(a);var X=J.q(w,n,4);
n+=4;for(var P=0;P<X;P++){var Z=J.Gb(w,n);n+=8;a.arr.push(Z)}}break;case"Pth ":var Y=n,$=J.q(w,n);n+=4;
var K=J.sv(w,n,4);n+=4;var S=J.ly(w,n);n+=4;var G=J.ah_(w,n);n+=4+G.length*2;U.v={sig:K,pth:G};break;
case"Clss":case"type":case"rele":var G=J.CX(w,n);n+=4+G.length*2+2;var V=jH.tv(w,n);n+=4+Math.max(4,V.length);
U.v={classID:V};if(G!="")U.v.__name=G;if(I=="rele"){U.v.val=J.W6(w,n);n+=4}break;case"prop":case"Enmr":case"indx":case"name":case"Idnt":var T=jH.Uf[I],G=J.CX(w,n);
n+=4+G.length*2+2;if(G.length!=0){console.log(I,G);throw"e"}U.v={};for(var L=0;L<T.length;L++){var V=jH.tv(w,n);
n+=4+Math.max(4,V.length);U.v[T[L]]=V}if(I=="name"){var G=J.CX(w,n);n+=4+G.length*2+2;U.v.val=G}if(I=="indx"||I=="Idnt"){U.v.val=J.q(w,n);
n+=4}break;case"alis":var $=J.q(w,n);n+=4;U.v=J.sv(w,n,$);n+=$;break;default:{console.log("unknown oskey: "+I+", "+j);
throw"e";return U}}if(W){console.log("\t".repeat(D),U.v);console.log("\t".repeat(D),"======",n)}U.size=n-j;
return U};jH.Uf={name:["classID"],prop:["classID","keyID"],Enmr:["classID","typeID","enum"],indx:["classID"],Idnt:["classID"]};
jH.aiS=function(w,n,W){var D=n,j=W.t;W=W.v;J.YY(w,n,j);n+=4;switch(j){case"obj ":case"VlLs":J.Wr(w,n,W.length);
n+=4;for(var I=0;I<W.length;I++){var U=jH.aiS(w,n,W[I]);n+=U}break;case"UntF":J.YY(w,n,W.type);J.gP(w,n+4,W.val);
n+=12;break;case"doub":J.gP(w,n,W);n+=8;break;case"bool":J.kW(w,n,W?1:0,1);n+=1;break;case"long":J.Wr(w,n,W);
n+=4;break;case"comp":J.Wr(w,n+4,W);n+=8;break;case"Objc":var U=jH.X3(w,W,n);n+=U;break;case"TEXT":J.wk(w,n,W+"\0");
n+=4+W.length*2+2;break;case"enum":var M=Object.keys(W)[0],m=W[M];jH.gy(w,n,M);n+=jH.Ws(w.data,n);jH.gy(w,n,m);
n+=jH.Ws(w.data,n);break;case"tdta":J._Z(w,n,W.length);n+=4;J.sS(w,n,W);n+=W.length;break;case"ObAr":J._Z(w,n,W.arr[0].arr.length);
n+=4;J.wk(w,n,"\0");n+=6;jH.gy(w,n,W.classID);n+=4+Math.max(4,W.classID.length);J._Z(w,n,W.arr.length);
n+=4;for(var L=0;L<W.arr.length;L++){var l=W.arr[L];jH.gy(w,n,l.id);n+=4+Math.max(4,l.id.length);J.YY(w,n,l.type);
n+=4;J.YY(w,n,l.uID);n+=4;J._Z(w,n,l.arr.length);n+=4;for(var I=0;I<l.arr.length;I++){J.gP(w,n,l.arr[I]);
n+=8}}break;case"Pth ":var A=W.pth.length*2+4+8;J._Z(w,n,A);n+=4;J.YY(w,n,W.sig);n+=4;J.zL(w,n,A);n+=4;
J.alM(w,n,W.pth);n+=W.pth.length*2+4;break;case"Clss":case"type":case"rele":var g=W.__name;if(g==null)g="";
J.wk(w,n,g+"\0");n+=4+g.length*2+2;var k=W.classID;jH.gy(w,n,k);n+=4+Math.max(4,k.length);if(j=="rele"){J.Wr(w,n,W.val);
n+=4}break;case"prop":case"Enmr":case"indx":case"name":case"Idnt":var $=jH.Uf[j];J._Z(w,n,1);n+=6;for(var L=0;
L<$.length;L++){var k=W[$[L]];jH.gy(w,n,k);n+=4+Math.max(4,k.length)}if(j=="name"){J.wk(w,n,W.val+"\0");
n+=4+W.val.length*2+2}if(j=="indx"||j=="Idnt"){J._Z(w,n,W.val);n+=4}break;case"alis":var A=W.length;
J._Z(w,n,A);n+=4;J.YY(w,n,W);n+=A;break;default:console.log("unknown oskey: "+j);n=D;break}return n-D};
jH.tv=function(w,n){var W=J.W6(w,n);if(W>1e3)throw"e";if(W==0)W=4;return J.sv(w,n+4,W).trim()};jH.Ws=function(w,n){var W=J.W6(w,n);
return W==0?8:4+W};jH.gy=function(w,n,W){var D="warp list Comp None xx xy yx yy tx ty PinP PnRt PnOv PnDp xor PuX0 PuX1 PuX2 PuX3 PuY0 PuY1 PuY2 PuY3 base kana ruby box flow time hold trim then else".split(" "),j=4<W.length||D.indexOf(W)!=-1;
J.Wr(w,n,j?W.length:0);J.YY(w,n+4,W);if(W.length<4&&!j){var I="";for(var L=W.length;L<4;L++)I+=" ";J.YY(w,n+4+W.length,I)}};
jH.a1J=function(w){var n={};for(var W in w){if(W=="classID")n[W]=w[W];else if(W=="__name")n[W]=w[W];
else n[W]=jH.aoo(w[W])}return n};jH.aoo=function(w){if(w.ib=="Objc")return jH.a1J(w.v);else if(w.ib=="VlLs"){var n=[];
for(var L=0;L<w.v.length;L++)n.push(jH.aoo(w.v[L]));return n}else if(w.ib=="UntF")return w.v.val;else return w.v};
function dR(){}dR.a1V=function(w,n,W,D,j,I){while(n<W){var U=J.sv(w,n,4);n+=4;if(U!="8BIM"&&U!="8B64"){console.log("layer information signature error! "+U,"PSB = "+j);
alert("Error in PSD file: wrong signature.");return W}var M=J.sv(w,n,4);n+=4;var m=J.q(w,n);n+=4;var l=j&&"LMsk Lr16 Lr32 Layr Mt16 Mt32 Mtrn Alph FMsk lnk2 lnkE FEid FXid PxSD extn cinf artd pths".split(" ").indexOf(M)!=-1;
if(l){m=m<<32|J.W6(w,n);n+=4}var A=["lrFX","PlLd"];if(A.indexOf(M)!=-1){if(m%4!=0)m+=4-m%4;n+=m;continue}switch(M){case"iOpa":D[M]=w[n];
break;case"brst":D[M]=[1,1,1];for(var L=0;L<m;L+=4)D[M][J.q(w,n+L)]=0;break;case"knko":D[M]=w[n];break;
case"infx":D[M]=w[n];break;case"clbl":D[M]=w[n];break;case"lmgm":D[M]=w[n];break;case"vmgm":D[M]=w[n];
break;case"fcmy":D[M]=w[n];break;case"lyid":D[M]=J.q(w,n);break;case"lsct":D[M]={type:J.q(w,n)};if(m>=12)D[M].Bx=J.sv(w,n+8,4);
break;case"lsdk":D.lsct={type:J.q(w,n)};break;case"lyvr":D[M]=J.q(w,n);break;case"lnsr":var g={artb:1,bgnd:1,cont:1,layr:1,lset:1,rend:1,shap:1,user:1,____:null};
D[M]=J.sv(w,n,4);break;case"lspf":D[M]=J.q(w,n);break;case"lclr":D[M]=J.IQ(w,n);break;case"luni":D[M]=J.Nl(w,n);
break;case"fxrp":D[M]=new ec(J.Gb(w,n),J.Gb(w,n+8));break;case"artb":case"artd":D[M]={};jH.iS(w,D[M],n+4);
break;case"SoCo":D[M]={};jH.iS(w,D[M],n+4);break;case"GdFl":D[M]={};jH.iS(w,D[M],n+4);dR.Ua(D[M],M);
break;case"PtFl":D[M]={};jH.iS(w,D[M],n+4);dR.Ua(D[M],M);break;case"CgEd":D[M]={};jH.iS(w,D[M],n+4);
break;case"brit":var k=D.brit=cx._1("brit"),$={};k.Brgh.v=J.zx(w,n);k.Cntr.v=J.zx(w,n+2);k.useLegacy.v=!0;
break;case"levl":var C=w.buffer.slice(n,n+m);D[M]=il.ew(C);break;case"curv":D[M]=e0.cW(w,n,m);break;
case"expA":var f=J.IQ(w,n),z=D[M]=cx._1("expA");z.Exps.v=J.F_(w,n+2);z.Ofst.v=J.F_(w,n+6);z.gammaCorrection.v=J.F_(w,n+10);
break;case"vibA":D[M]={};jH.iS(w,D[M],n+4);break;case"hue2":D[M]=cT.cW(w,n,m);break;case"blnc":var z=D[M]=cx._1(M);
z.PrsL.v=w[n+18]==1;var s=["ShdL","MdtL","HghL"];for(var L=0;L<3;L++)for(var O=0;O<3;O++)z[s[L]].v[O].v=J.zx(w,n+L*6+O*2);
break;case"blwh":var a={};jH.iS(w,a,n+4);var z=cx._1(M),X="Bl Cyn Grn Mgnt Rd Yllw tintColor useTint".split(" ");
for(var L=0;L<X.length;L++){z[X[L]]=a[X[L]];delete a[X[L]]}D[M]=z;break;case"phfl":var z=D[M]=cx._1(M),P=z.Clr.v,f=J.IQ(w,n);
if(f==3){var Z=[J.q(w,n+2),J.q(w,n+6),J.q(w,n+10)],Y=32768,K=E.rI(Z[0]/Y,Z[1]/Y,Z[2]/Y);P.Lmnc.v=K.zP;
P.A.v=K.dl;P.B.v=K.k}if(f==2){var S=J.IQ(w,n+2);if(S!=7)throw"e";P.Lmnc.v=J.zx(w,n+4)/100;P.A.v=J.zx(w,n+6)/100;
P.B.v=J.zx(w,n+8)/100}var G=n+2+(f==3?12:10);z.Dnst.v=J.q(w,G);G+=4;z.PrsL.v=w[G]==1;break;case"mixr":var V={jD:J.IQ(w,n+2)==1,Z:[]};
for(var L=0;L<20;L++)V.Z.push(J.zx(w,n+4+L*2));D[M]=eH.a3Z(V);break;case"clrL":case"rplc":D[M]={};jH.iS(w,D[M],n+6);
break;case"nvrt":D[M]={};break;case"post":D[M]=cx._1("post");D[M].Lvls.v=J.IQ(w,n);break;case"thrs":D[M]=cx._1("thrs");
D[M].Lvl.v=J.IQ(w,n);break;case"grdm":var T=n,R=w[n+2]==1,x=w[n+3]==1;T+=4;var v=J.sv(w,T,4);if(v=="Perc"||v=="Gcls"||v=="Lnr ")T+=4;
var N=J.Nl(w,T);T+=4+N.length*2;var u=f8.a19(w,T,N),H=u[0];T=u[1];var F=J.IQ(w,T);T+=2;var t=J.q(w,T);
T+=4;var o=J.IQ(w,T)==1;T+=2;var q=J.IQ(w,T)==1;T+=2;var _=J.q(w,T);T+=4;var d=J.IQ(w,T);T+=2;var r=[],p=[];
for(var L=0;L<4;L++){r.push({t:"long",v:~~(J.IQ(w,T+L*2)*100/32768)});p.push({t:"long",v:~~(J.IQ(w,T+L*2+8)*100/32768)})}T+=16;
var Q=J.IQ(w,T);T+=2;if(F==1)H={classID:"Grdn",Nm:{t:"TEXT",v:N},GrdF:{t:"enum",v:{GrdF:"ClNs"}},ShTr:{t:"bool",v:o},VctC:{t:"bool",v:q},ClrS:{t:"enum",v:{ClrS:"RGBC"}},RndS:{t:"long",v:t},Smth:{t:"long",v:_},Mnm:{t:"VlLs",v:r},Mxm:{t:"VlLs",v:p}};
var B=cx._1("grdm");B.Rvrs.v=R;B.Grad.v=H;D[M]=B;break;case"selc":D[M]=av.cW(w,n,m);break;case"vmsk":case"vsms":var i=D.vmsk=new h.Rd,c=J.W6(w,n+4),h2=(c>>0&1)==1;
i.gm=(c>>1&1)==0;i.isEnabled=(c>>2&1)==0;i.i=bI.mV(w,n+8,m-8,I.m,I.n);break;case"shmd":D[M]={};var jX=J.q(w,n),G=n+4;
for(var L=0;L<jX;L++){var U=J.sv(w,G,4);G+=4;var bm=J.sv(w,G,4);G+=4;var dC=w[G];G++;if(Math.max(w[G],w[G+1])!=0)throw"e";
G+=3;var fn=J.q(w,G);G+=4;if(bm=="cust"||bm=="cmls"||bm=="extn"||bm=="mlst"){var fK=J.q(w,G);if(fK!=16)G+=4;
if(J.q(w,G)==16){var a={};jH.iS(w,a,G+4,!1);D[M][bm]=a;if(bm=="cmls")y.Ul.agp(D[M][bm])}}else{console.log("unknown shmd key: "+bm+", size: "+fn)}G+=fn}break;
case"shpa":var f=J.q(w,n),i6=J.q(w,n+4);if(i6!=0)console.log("some patterns present!");break;case"TySh":var dh=D[M]={},f=J.IQ(w,n);
dh.D=J.wq(w,n+2);var kA=J.IQ(w,n+2+48);dh.lz={};try{var ig=jH.iS(w,dh.lz,n+56)}catch(fV){D[M]=null;break}var iJ=hd.ah1();
for(var fL in iJ)if(dh.lz[fL]==null)dh.lz[fL]=iJ[fL];dh.hc={};var fB=jH.iS(w,dh.hc,n+56+ig+6);dh.IA=J.axR(w,n+56+ig+6+fB);
dh._o=eY.ew(dh.lz.EngineData.v);hd.alp(dh._o.EngineDict.StyleRun.RunArray);if(dh._o.ResourceDict==null)dh._o.ResourceDict=JSON.parse(JSON.stringify(dh._o.DocumentResources));
delete dh.lz.EngineData;break;case"lfx2":case"lmfx":case"lfxs":var ah=J.q(w,n),eS=J.q(w,n+4);D.lmfx={};
var ig=jH.iS(w,D.lmfx,n+8);dR.ml(D.lmfx);break;case"FMsk":D[M]=J.Xv(w,n,m);break;case"Txt2":D[M]={};
D[M].raw=J.Xv(w,n,m);D[M].bC=iK.ew(D[M].raw);break;case"Patt":D[M]=kj.EH(w,n,m);break;case"SoLd":var gL=J.sv(w,n,4),e_=J.q(w,n+4),c2=J.q(w,n+8);
D[M]={};var jS=jH.iS(w,D[M],n+12);if(D[M].nonAffineTransform==null)D[M].nonAffineTransform=JSON.parse(JSON.stringify(D[M].Trnf));
if(D[M].Impr==null)D[M].Impr={t:"Objc",v:{__name:"None",classID:"none"}};break;case"vstk":case"pths":var e_=J.q(w,n);
D[M]={};var jS=jH.iS(w,D[M],n+4);break;case"vscg":var bm=J.sv(w,n,4),e_=J.q(w,n+4);D[bm]={};var jS=jH.iS(w,D[bm],n+8);
dR.Ua(D[bm],bm);break;case"vogk":var ie=J.q(w,n),e_=J.q(w,n+4);D[M]={};var jS=jH.iS(w,D[M],n+8);D[M]=D[M].keyDescriptorList.v;
for(var L=0;L<D[M].length;L++){var as=D[M][L].v;if(!E.X.OL(as))continue;if(as.keyOriginBoxCorners==null){var gb=E.X.O5(as);
as.keyOriginBoxCorners={t:"Objc",v:{classID:"null"}};var gx=[gb[0],gb[1],gb[2],gb[1],gb[2],gb[3],gb[0],gb[3]];
if(as.keyOriginType.v==4)gx=E.X.qJ(E.X.oW(as),as.keyOriginLineWeight.v);E.X.iH(as,"keyOriginBoxCorners",gx)}}break;
case"lnk2":case"lnkD__":case"lnk3__":D[M]=[];var T=n;while(T<n+m){var eo=new h.FL;D[M].push(eo);var di=J.gg(w,T);
T+=8;var d0=T;eo.type=J.sv(w,T,4);T+=4;if(eo.type!="liFD"){alert("Unknown Linked Layer type: "+eo.type);
break;throw eo.type}eo.dk=J.q(w,T);T+=4;var e6=J.$B(w,T);T+=1+e6.xi.length;eo.Z4=e6.xi;eo.O7=J.CX(w,T);
T+=4+eo.O7.length*2+2;eo.oq=J.sv(w,T,4);T+=4;eo.TA=J.sv(w,T,4);T+=4;var dt=J.gg(w,T);T+=8;eo.open=w[T];
T+=1;if(eo.open!=0){var gJ={},ig=jH.iS(w,gJ,T+4);if(ig%4!=0)ig+=4-ig%4;console.log(gJ);T+=ig+4}eo.open=0;
eo.raw=J.Xv(w,T,dt);T=d0+di;if(di%4!=0)T+=4-di%4}break;case"FEid":var T=n;D[M]=[];var iW=T+m,f=J.q(w,T);
T+=4;while(T<iW){T+=4;var di=J.q(w,T);T+=4;var u={};D[M].push(u);u.id=J.$B(w,T).xi;T+=u.id.length+1;
var f=J.q(w,T);T+=4;T+=4;var g5=J.q(w,T);T+=4;u.rect=J._I(w,T);T+=16;var jW=J.q(w,T);T+=4;var eP=J.q(w,T);
T+=4;var b_=new E.H0(0);for(var L=0;L<eP+2;L++){var fZ=J.q(w,T);T+=4;if(fZ!=0){T+=4;var im=J.q(w,T),j3=null;
T+=4;if(L<3||L==25)j3=jY.V5(!0,jW,w,u.rect.m,u.rect.n,T,im);if(L==0)b_.o=j3;if(L==1)b_.B=j3;if(L==2)b_.k=j3;
if(L==25)b_.dl=j3;T+=im}}u.buffer=E.Q(u.rect.O()*4);E.kX(b_,u.buffer);E.qS(u);var dr=w[T];T++;if(dr!=0){u.z=new h.ac;
u.z.rect=J._I(w,T);T+=16;T+=4;var c0=J.q(w,T);T+=4;u.z.channel=jY.V5(!0,jW,w,u.z.rect.m,u.z.rect.n,T,c0);
u.z.color=255;u.z.ky();T+=c0}if(di%4!=0)T+=4-di%4}break;case"Lr16":gg.q2(I,w,n);break;case"Anno":D[M]=[];
var fM=n,cB=n+4,i6=J.q(w,cB);cB+=4;for(var L=0;L<i6;L++){var di=J.q(w,cB);cB+=4;var iI=J.sv(w,cB,4);
cB+=4;if(iI!="txtA")throw iI;var jD=w[cB++],j8=w[cB++],jG=J.IQ(w,cB);cB+=2;var i1=J._I(w,cB);cB+=16;
var bH=J._I(w,cB);cB+=16;var P=dm.mn(w,cB);cB+=10;var a_=J.$B(w,cB);cB+=a_.length;var aR=J.$B(w,cB);
cB+=aR.length;var iY=J.$B(w,cB);cB+=iY.length;var gy=J.q(w,cB);cB+=4;var gr=J.sv(w,cB,4);cB+=4;var fs=J.q(w,cB);
cB+=4;var dQ=J.yL(w,cB+2,fs-2>>1);cB+=fs;D[M].push([i1.x,i1.y,P,a_.xi,dQ])}break;default:break}var ep="Lr16 LMsk Txt2 artd extd luni pths extn tySh lfx2 cinf Anno".split(" ");
if(ep.indexOf(M)==-1)if(m%4!=0)console.log("size not multiple of 4!!!",M);if(M!="luni"&&M!="TySh"&&M!="tySh"&&M!="lfx2"&&M!="iOpa")if(m%4!=0)m+=4-m%4;
n+=m}var $=D.CgEd;if($){var k=D.brit;if(k){k.Brgh.v=$.Brgh?$.Brgh.v:0;k.Cntr.v=$.Cntr?$.Cntr.v:0;k.useLegacy.v=$.useLegacy?$.useLegacy.v:0}delete D.CgEd}var b2=[];
for(var L=0;L<b2.length;L++)delete D[b2[L]];return n};dR.abT=function(w,n,W,D,j){for(var I in W)if(W[I]==null){alert("A bug occured (see console).");
console.log("Please, report a bug, that \""+I+"\" tag was present with a null value.");delete W[I]}for(var I in W){var U=D&&"LMsk Lr16 Lr32 Layr Mt16 Mt32 Mtrn Alph FMsk lnk2 lnkE FEid FXid PxSD extn cinf artd pths".split(" ").indexOf(I)!=-1,m=0;
J.YY(w,n,U?"8B64":"8BIM");n+=4;var M=n;J.YY(w,n,I);n+=4;J.Wr(w,n,0);n+=U?8:4;switch(I){case"iOpa":J.kW(w,n,W[I],1);
m=4;break;case"brst":m=0;for(var L=0;L<3;L++)if(W[I][L]==0){J._Z(w,n+m,L);m+=4}break;case"knko":J.kW(w,n,W[I],1);
m=4;break;case"infx":J.kW(w,n,W[I],1);m=4;break;case"clbl":J.kW(w,n,W[I],1);m=4;break;case"lmgm":J.kW(w,n,W[I],1);
m=4;break;case"vmgm":J.kW(w,n,W[I],1);m=4;break;case"fcmy":J.kW(w,n,W[I],1);m=4;break;case"lyid":J._Z(w,n,W[I]);
m=4;break;case"lsct":J._Z(w,n,W[I].type);m=4;if(W[I].Bx){J.YY(w,n+4,"8BIM");J.YY(w,n+8,W[I].Bx);m=12}break;
case"lyvr":J._Z(w,n,W[I]);m=4;break;case"lnsr":J.YY(w,n,W[I]);m=4;break;case"lspf":J._Z(w,n,W[I]);m=4;
break;case"lclr":J.vo(w,n,W[I]);m=8;break;case"luni":J.wk(w,n,W[I]);m=4+2*W[I].length;break;case"fxrp":J.gP(w,n,W[I].x);
J.gP(w,n+8,W[I].y);m=16;break;case"artb":case"artd":J._Z(w,n,16);m=jH.X3(w,W[I],n+4)+4;break;case"SoCo":J._Z(w,n,16);
m=jH.X3(w,W[I],n+4)+4;break;case"GdFl":J._Z(w,n,16);m=jH.X3(w,W[I],n+4)+4;break;case"PtFl":J._Z(w,n,16);
m=jH.X3(w,W[I],n+4)+4;break;case"CgEd":var l={classID:"null",Vrsn:{t:"long",v:1},Brgh:{t:"long",v:24},Cntr:{t:"long",v:54},means:{t:"long",v:127},Lab:{t:"bool",v:!1},useLegacy:{t:"bool",v:!1},Auto:{t:"bool",v:!0}},A=l,g=W[I];
A.Brgh.v=g.Brgh.v;A.Cntr.v=g.Cntr.v;A.useLegacy.v=g.useLegacy.v;J._Z(w,n,16);m=jH.X3(w,l,n+4)+4;break;
case"brit":w.lN(n,8);m=8;break;case"levl":var k=new cs;m=il.z8(k,W[I]);J.sS(w,n,k.data);break;case"curv":m=e0.k$(w,n,W[I]);
break;case"expA":m=14;w.lN(n,14);J.ey(w.data,n,1);J.uS(w.data,n+2,W[I].Exps?W[I].Exps.v:0);J.uS(w.data,n+6,W[I].Ofst?W[I].Ofst.v:0);
J.uS(w.data,n+10,W[I].gammaCorrection?W[I].gammaCorrection.v:1);break;case"vibA":J._Z(w,n,16);m=jH.X3(w,W[I],n+4)+4;
break;case"hue2":m=cT.k$(w,n,W[I]);break;case"blnc":m=19;w.lN(n,m);var $=["ShdL","MdtL","HghL"];for(var L=0;
L<3;L++){var C=W[I][$[L]].v;for(var f=0;f<3;f++)C.push(J.H$(w.data,n+L*6+f*2,C[f].v))}w.data[n+18]=W[I].PrsL.v?1:0;
break;case"blwh":var l={classID:"null",bwPresetKind:{t:"long",v:1},blackAndWhitePresetFileName:{t:"TEXT",v:""}},z="Bl Cyn Grn Mgnt Rd Yllw tintColor useTint".split(" ");
for(var L=0;L<z.length;L++){l[z[L]]=W[I][z[L]]}J._Z(w,n,16);m=jH.X3(w,l,n+4)+4;break;case"phfl":J.vo(w,n,2);
var s=W[I].Clr.v;J.vo(w,n+2,7);J.vo(w,n+4,Math.round(s.Lmnc.v*100));J.vo(w,n+6,Math.round(s.A.v*100));
J.vo(w,n+8,Math.round(s.B.v*100));J.vo(w,n+10,0);var O=n+2+10;w.lN(O,5);J.Ms(w.data,O,W[I].Dnst.v);O+=4;
w.data[O]=W[I].PrsL.v?1:0;O++;m=O-n;break;case"mixr":m=44;w.lN(n,m);var a=eH.hm(W[I]);J.ey(w.data,n,1);
J.ey(w.data,n+2,a.jD?1:0);for(var L=0;L<20;L++)J.H$(w.data,n+4+L*2,a.Z[L]);break;case"clrL":case"rplc":J.vo(w,n,1);
J._Z(w,n+2,16);m=jH.X3(w,W[I],n+6)+6;break;case"nvrt":m=0;break;case"post":J.vo(w,n,W[I].Lvls.v);m=2;
break;case"thrs":J.vo(w,n,W[I].Lvl.v);m=2;break;case"grdm":var X=W[I].Rvrs?W[I].Rvrs.v:!1,P=!1,Z=867527939,Y=!1,K=!1,S=2048,G=[0,0,0,0],V=[32768,32768,32768,32768],T=W[I].Grad.v,R,x,v=T.Clrs==null?1:0;
if(v==0){R=T;x=JSON.parse(at._V.abX).v}else{R=cx._1("grdm").Grad.v;x=T}w.lN(n,4);J.ey(w.data,n,1);w.data[n+2]=X?1:0;
w.data[n+3]=P?1:0;var N=n+4;J.wk(w,N,T.Nm.v);N+=4+T.Nm.v.length*2;N=f8.ayK(w,N,R);J.vo(w,N,v);N+=2;J._Z(w,N,x.RndS.v);
N+=4;J.vo(w,N,x.ShTr.v?1:0);N+=2;J.vo(w,N,x.VctC.v?1:0);N+=2;J._Z(w,N,x.Smth.v);N+=4;J.vo(w,N,3);N+=2;
for(var L=0;L<4;L++)J.vo(w,N+L*2,G[L]);N+=8;for(var L=0;L<4;L++)J.vo(w,N+L*2,V[L]);N+=8;N+=2;m=N-n;break;
case"selc":m=av.k$(w,n,W[I]);break;case"FMsk":J.sS(w,n,W[I]);m=W[I].length;break;case"Txt2":var u=new cs,H=iK.Pj(W[I].bC,u),F=E.Q(H,!0);
for(var L=0;L<H;L++)F[L]=u.data[L];J.sS(w,n,F);m=F.length;break;case"vmsk":var t=W[I],o=0;J._Z(w,n,3);
if(!t.gm)o+=1<<1;if(!t.isEnabled)o+=1<<2;J._Z(w,n+4,o);m=8;var q=t.i.length;w.lN(n+8,q*26);bI.yW(w.data,n+8,t.i,j.m,j.n);
m+=q*26;break;case"shmd":J._Z(w,n,Object.keys(W[I]).length);var O=n+4;for(var _ in W[I]){J.YY(w,O,"8BIM");
O+=4;J.YY(w,O,_);O+=4;J._Z(w,O,0);O+=4;J._Z(w,O,0);O+=4;J._Z(w,O,16);O+=4;var d=jH.X3(w,W[I][_],O);if(d%4!=0)d+=4-d%4;
J._Z(w,O-8,d+4);O+=d}m=O-n;break;case"TySh":var O=n;J.im(w,O,1);O+=2;var r=W[I],u=new cs;r._o.DocumentResources=JSON.parse(JSON.stringify(r._o.ResourceDict));
var H=eY.Pj(r._o,u),F=E.Q(H,!0);for(var L=0;L<H;L++)F[L]=u.data[L];r.lz.EngineData={t:"tdta",v:F};var p=r._o.EngineDict.Editor.Text;
r.lz.Txt.v=p.substring(0,p.length-1);J.auX(w,O,r.D);O+=48;J.im(w,O,50);O+=2;J._Z(w,O,16);O+=4;O+=jH.X3(w,r.lz,O);
J.im(w,O,1);O+=2;J._Z(w,O,16);O+=4;O+=jH.X3(w,r.hc,O);J.aug(w,O,r.IA);O+=16;m=O-n;break;case"lmfx":J._Z(w,n,0);
J._Z(w,n+4,16);var l=JSON.parse(JSON.stringify(W[I])),Q=!1;dR.BA(l);for(var L=0;L<at.Pa.length;L++)if(l[at.Pa[L]]!=null)Q=!0;
J.YY(w,M,Q?"lmfx":"lfx2");m=jH.X3(w,l,n+8)+8;break;case"Patt":var O=kj.iU(w,n,W[I]);m=O-n;break;case"SoLd":J.YY(w,n,"soLD");
J._Z(w,n+4,4);J._Z(w,n+8,16);m=jH.X3(w,W[I],n+12)+12;break;case"vstk":case"pths":J._Z(w,n,16);m=jH.X3(w,W[I],n+4)+4;
break;case"vscg__":J.YY(w,n,W[I].key);J._Z(w,n+4,16);m=jH.X3(w,W[I].Z,n+8)+8;break;case"vogk":J._Z(w,n,1);
J._Z(w,n+4,16);E.X.atD(W[I]);for(var L=0;L<W[I].length;L++){var B=W[I][L].v.keyOriginResolution;if(B)B.v=j.hh}var i={classID:"null",keyDescriptorList:{t:"VlLs",v:W[I]}};
m=jH.X3(w,i,n+8)+8;break;case"lnkD":case"lnk2":case"lnk3":var N=n;for(var L=0;L<W[I].length;L++){var c=W[I][L],h2=N;
J.JH(w,N,0);N+=8;J.YY(w,N,c.type);N+=4;J._Z(w,N,c.dk);N+=4;w.lN(N,1);w.data[N]=c.Z4.length;N++;J.YY(w,N,c.Z4);
N+=c.Z4.length;J.wk(w,N,c.O7+"\0");N+=4+c.O7.length*2+2;J.YY(w,N,c.oq);N+=4;J.YY(w,N,c.TA);N+=4;J.JH(w,N,c.raw.length);
N+=8;w.lN(N,1);w.data[N]=c.open;N++;J.sS(w,N,c.raw);N+=c.raw.length;J._Z(w,N,1);N+=4;N+=11;var jX=N-h2-8;
J.JH(w,h2,jX);if(jX%4!=0){w.lN(N,4-jX%4);N+=4-jX%4}}m=N-n;break;case"FEid":var N=n;J._Z(w,N,3);N+=4;
for(var bm=0;bm<W[I].length;bm++){var dC=W[I][bm];N+=4;var fn=N;N+=4;J.Tc(w,N,dC.id);N+=dC.id.length+1;
J._Z(w,N,1);N+=4;var fK=E.Q(dC.rect.O()),i6=dC.rect,dh=E.Q(i6.O());N+=4;var kA=N;N+=4;J.zw(w,N,i6);N+=16;
J._Z(w,N,8);N+=4;J._Z(w,N,24);N+=4;for(var L=0;L<24+2;L++){var ig=-1;if(L==0)ig=0;if(L==1)ig=1;if(L==2)ig=2;
if(L==25)ig=3;J._Z(w,N,ig!=-1?1:0);N+=4;if(ig!=-1){E.hN(dC.buffer,fK,ig);E.B0(fK,dC.rect,dh,i6);N+=4;
var iJ=N;N+=4;w.lN(N,i6.O()+2);N=jY.sM(!0,dh,w.data,i6.m,i6.n,N,3);J._Z(w,iJ,N-(iJ+4))}}J._Z(w,kA,N-(kA+4));
w.lN(N,1);w.data[N]=dC.z?1:0;N++;if(dC.z!=null){var fL=i6,fB=E.Q(fL.O());fB.fill(dC.z.color);E.B0(dC.z.channel,dC.z.rect,fB,fL);
J.zw(w,N,fL);N+=16;N+=4;var ah=N;N+=4;w.lN(N,fL.O()+2);N=jY.sM(!0,fB,w.data,fL.m,fL.n,N,3);J._Z(w,ah,N-(ah+4))}var jX=N-(fn+4);
J._Z(w,fn,jX);if(jX%4!=0)N+=4-jX%4}m=N-n;break;case"Anno":var eS=n,gL=W[I].length;J.vo(w,eS,2);J.vo(w,eS+2,1);
eS+=4;J._Z(w,eS,gL);eS+=4;for(var L=0;L<gL;L++){var e_=W[I][L],c2=e_[0],jS=e_[1],ie=eS;eS+=4;J.YY(w,eS,"txtA");
eS+=4;w.lN(eS,2);w.data[eS]=1;w.data[eS+1]=28;eS+=2;J.vo(w,eS,1);eS+=2;J.zw(w,eS,new iB(c2,jS,17,21));
eS+=16;J.zw(w,eS,new iB(c2+8,jS+10,241,141));eS+=16;w.lN(eS,10);dm.Dg(w.data,eS,e_[2]);eS+=10;eS+=J.Tc(w,eS,e_[3]);
eS+=J.Tc(w,eS,"");eS+=J.Tc(w,eS,"D:20211012120233+01'00'");var as=e_[4].length*2;J._Z(w,eS,12+2+as);
eS+=4;J.YY(w,eS,"txtC");eS+=4;J._Z(w,eS,2+as);eS+=4;w.lN(eS,2);w.data[eS]=254;w.data[eS+1]=255;eS+=2;
J.acW(w,eS,e_[4]);eS+=as;J._Z(w,ie,eS-ie)}m=eS-n;break;default:console.log("unknown layer tag: "+I+", size: "+m);
n-=12;continue}var gb=["Txt2","artd","extd","pths"];if(gb.indexOf(I)==-1)if(m%4!=0)m+=4-m%4;if(U)J.JH(w,n-8,m);
else J._Z(w,n-4,m);if(I!="luni"&&I!="TySh")if(m%4!=0)m+=4-m%4;n+=m}return n};dR.ml=function(w){for(var L=0;
L<at.order.length;L++){var n=at.order[L],W=at.Pa[L];if(w[W]==null)w[W]={t:"VlLs",v:[]};if(w[n]!=null){w[W].v.push(w[n]);
delete w[n]}var D=[];for(var j=0;j<w[W].v.length;j++){var I=w[W].v[j];if(I.v.present==null||I.v.present.v==!0)D.push(I)}w[W].v=D}};
dR.BA=function(w){for(var L=0;L<at.order.length;L++){var n=at.order[L],W=at.Pa[L],D=w[W].v.length;if(D==0){delete w[W];
continue}if(D==1){w[n]=w[W].v[0];delete w[W];continue}}};dR.Ua=function(w,n){if(n=="GdFl"){if(w.Angl==null)w.Angl={v:{type:"#Ang",val:0},t:"UntF"};
if(w.Algn==null)w.Algn={v:!0,t:"bool"};if(w.Scl==null)w.Scl={v:{type:"#Prc",val:100},t:"UntF"};if(w.Ofst==null)w.Ofst={v:{classID:"Pnt",Hrzn:{v:{type:"#Prc",val:0},t:"UntF"},Vrtc:{v:{type:"#Prc",val:0},t:"UntF"}},t:"Objc"};
if(w.Rvrs==null)w.Rvrs={v:!1,t:"bool"};if(w.Dthr==null)w.Dthr={v:!1,t:"bool"}}if(n=="PtFl"){if(w.Algn==null)w.Algn={v:!0,t:"bool"};
if(w.Angl==null)w.Angl={v:{type:"#Ang",val:0},t:"UntF"};if(w.Scl==null)w.Scl={v:{type:"#Prc",val:100},t:"UntF"};
if(w.phase==null)w.phase={v:{classID:"Pnt",Hrzn:{v:0,t:"doub"},Vrtc:{v:0,t:"doub"}},t:"Objc"}}};dR.clone=function(w,n){var W={};
if(w=="TySh"){W.D=n.D.clone();W.lz=JSON.parse(JSON.stringify(n.lz));W.hc=JSON.parse(JSON.stringify(n.hc));
W.IA=n.IA.clone();W._o=JSON.parse(JSON.stringify(n._o));if(n.add)W.add={vmsk:n.add.vmsk.clone(),vogk:JSON.parse(JSON.stringify(n.add.vogk))};
return W}else if(w=="fxrp")return n.clone();else if(w=="vmsk")return n.clone();else return JSON.parse(JSON.stringify(n))};
function ke(w,n){}ke.ew=function(w,n,W,D){D=ke.a5D(w,n,W,D);return D};ke.Pj=function(w,n,W,D,j){D=ke.awO(w,n,W,D,j);
return D};ke.a5D=function(w,n,W,D){var j=D;w.rect=J._I(W,D);D+=16;var I=J.IQ(W,D);D+=2;w.fq=[];var U=n.Kl;
for(var L=0;L<I;L++){w.fq[L]={id:J.zx(W,D),length:(U?J.gg:J.q)(W,D+2)};D+=U?10:6}var M=J.sv(W,D,4);D+=4;
if(M!="8BIM"){console.log("Invalid Blend mode signature: "+M);alert("Error in Photoshop file: wrong signature.");
throw"e"}w.Bx=J.sv(W,D,4);D+=4;w.opacity=W[D];D+=1;w.QY=W[D]==1;D+=1;w.FK=W[D];D+=1;if(W[D]!=0)console.log("error in filler!");
D+=1;var m=J.q(W,D);D+=4;var l=D;D=ke.asV(w,W,D);D=ke.a49(w,W,D);var A=J.$B(W,D);w.name=A.xi;D+=A.length;
if(A.length%4!=0)D+=4-A.length%4;D=dR.a1V(W,D,l+m,w.add,U,n);if(w.add.lsct){if(w.add.lsct.Bx)w.Bx=w.add.lsct.Bx;
w.add.lsct=w.add.lsct.type}return D};ke.awO=function(w,n,W,D,j){var I=D;J.zw(W,D,w.rect);D+=16;var U=w.ag7();
J.vo(W,D,U.length);D+=2;var M=n.Kl;j.push(D);for(var L=0;L<U.length;L++){J.im(W,D,U[L]);if(M)J.JH(W,D+2,0);
else J._Z(W,D+2,0);D+=M?10:6}J.YY(W,D,"8BIM");D+=4;J.YY(W,D,w.Bx);D+=4;J.kW(W,D,w.opacity,1);D+=1;J.kW(W,D,w.QY?1:0,1);
D+=1;J.kW(W,D,w.FK,1);D+=1;J.kW(W,D,0,1);D+=1;var m=D;J._Z(W,D,0);D+=4;var l=D;D=ke.apn(w,W,D);D=ke.alv(w,W,D);
var A=J.Tc(W,D,w.name.slice(0,255));D+=A;if(A%4!=0)D+=4-A%4;if(w.add.lsct){w.add.lsct={type:w.add.lsct};
if(w.Bx=="pass"){w.add.lsct.Bx="pass";w.Bx="norm"}}if(w.Bx=="pass")w.add.lsct={type:w.add.lsct,Bx:"pass"};
if(w.add.brit)w.add.CgEd=w.add.brit;D=dR.abT(W,D,w.add,M,n);delete w.add.CgEd;if(w.add.lsct){if(w.add.lsct.Bx)w.Bx=w.add.lsct.Bx;
w.add.lsct=w.add.lsct.type}var g=D-l;J._Z(W,m,g);return D};ke.asV=function(w,n,W){var D=J.q(n,W);W+=4;
if(D==0)return W;var j=W;w.z=new h.ac;w.z.rect=J._I(n,W);W+=16;w.z.color=n[W];W+=1;var I=ke.a46(w.z,n,W);
W+=1;if(I){var U=!1,M=255,m=0,l=255,A=0;for(var L=0;L<w.fq.length;L++)if(w.fq[L].id==-3)U=!0;if(U){w.pv=ke.ar3(n,W);
W+=18}var g=W,k=n[W];W++;if(k>>0&1){M=n[W];W++}if(k>>1&1){m=J.Gb(n,W);W+=8}if(k>>2&1){l=n[W];W++}if(k>>3&1){A=J.Gb(n,W);
W+=8}if((W-g&1)==1)W++;w.Ic=[M,m,l,A]}else{if(D==20)W+=2;else{w.pv=ke.ar3(n,W);W+=18}}return j+D};ke.apn=function(w,n,W){J._Z(n,W,0);
W+=4;if(w.z==null)return W;var D=w._N(),j=w.add.vmsk,I=W,U=!0;J._Z(n,W,0);J.zw(n,W,w.z.rect);W+=16;J.kW(n,W,w.z.color);
W+=1;ke.alk(w.z,n,W,U);W+=1;if(U){if(w.pv){ke.a0E(n,W,w.pv);W+=18}J.kW(n,W,15);W+=1;J.kW(n,W,D?D.MX:255);
W+=1;J.gP(n,W,D?D.C3:0);W+=8;J.kW(n,W,j?j.MX:255);W+=1;J.gP(n,W,j?j.C3:0);W+=8;W++}J._Z(n,I-4,W-I);return W};
ke.ar3=function(w,n){var W=new h.ac;ke.a46(W,w,n);n+=1;W.color=w[n];n+=1;W.rect=J._I(w,n);n+=16;return W};
ke.a0E=function(w,n,W){ke.alk(W,w,n,!1);n+=1;J.kW(w,n,W.color);n+=1;J.zw(w,n,W.rect);n+=16};ke.a46=function(w,n,W){var D=n[W];
w.gm=(D>>0&1)==0;w.isEnabled=(D>>1&1)==0;w.CT=(D>>3&1)==1;return D>>4&1};ke.alk=function(w,n,W,D){var j=0;
if(!w.gm)j+=1<<0;if(!w.isEnabled)j+=1<<1;if(w.CT)j+=1<<3;if(D)j+=1<<4;J.kW(n,W,j)};ke.a49=function(w,n,W){var D=J.q(n,W);
W+=4;for(var L=0;L<D;L++)w.kQ[L]=n[W+L];return W+D};ke.alv=function(w,n,W){J._Z(n,W,w.kQ.length);W+=4;
n.lN(W,40);for(var L=0;L<40;L++){n.data[W+L]=w.kQ[L]}return W+40};function jY(){}jY.ew=function(w,n,W,D){D=jY.a9j(n,n.Kl,n.g3,n.UM,w,W,D);
return D};jY.z8=function(w,n,W,D,j,I){D=jY.a3W(w,n,W,D,j,I);return D};jY.a9j=function(w,n,W,D,j,I,U){var M=j.fq,m={},l=U;
for(var L=0;L<M.length;L++){var A=M[L],g=A.id,k=A.length,$;if(g==-2&&j.z==null)g=-1;if(g==-3)$=j.pv.rect;
else if(g==-2)$=j.z.rect;else $=j.rect;var C=jY.V5(n,W,I,$.m,$.n,U,k);U+=k;if(g==-3)j.pv.channel=C;else if(g==-2)j.z.channel=C;
else m["c"+g]=C}var f=new E.H0(0);f.dl=null;if(D==3){f.o=m.c0;f.B=m.c1;f.k=m.c2;f.dl=m["c-1"]}else if(D==1){f.o=m.c0;
f.B=m.c0;f.k=m.c0;f.dl=m["c-1"]}else if(D==4){var z=w.qL.r1039,s=m.c0,O=m.c1,a=m.c2,X=m.c3;if(z){var P=z.a2B,Z=17;
if(P==null){var Y=ICC.R(z.buffer);console.log(Y);P=z.a2B=ICC.U.sampleLUT(Y,Z)}var K={o:s,B:O,k:a,dl:X},S=E.Q(s.length*4);
E.kX(K,S);E.Ba(S);ICC.U.applyLUT4(P,Z,S,S);E.rH(S,K)}else{for(var L=0;L<s.length;L++){var G=1-s[L]*(1/255),V=1-O[L]*(1/255),T=1-a[L]*(1/255),R=1-X[L]*(1/255),x=UDOC.C.cmykToRgb([G,V,T,R]);
s[L]=x[0]*255;O[L]=x[1]*255;a[L]=x[2]*255}}f.o=s;f.B=O;f.k=a;f.dl=m["c-1"]}if(f.o==null)f.o=E.Q(0);if(f.dl==null&&f.o!=null){f.dl=f.o.slice(0);
f.dl.fill(255)}if(f.B==null)f.B=f.o.slice(0);if(f.k==null)f.k=f.o.slice(0);j.buffer=E.Q(Math.max(0,j.rect.O()*4));
E.kX(f,j.buffer);return U};jY.a3W=function(w,n,W,D,j,I){var U=n.ag7(),M=new E.H0(n.rect.O());E.rH(n.buffer,M);
for(var L=0;L<U.length;L++){var m=U[L],l,A;if(m==-3)l=n.pv.rect;else if(m==-2)l=n.z.rect;else l=n.rect;
if(m==-3)A=n.pv.channel;if(m==-2)A=n.z.channel;if(m==-1)A=M.dl;if(m==0)A=M.o;if(m==1)A=M.B;if(m==2)A=M.k;
W.lN(D,l.O()*3+4);var g=D;D=jY.sM(w,A,W.data,l.m,l.n,D,I[1]?3:1);var k=D-g;if(w)J.ayS(W.data,j+L*10+2,k);
else J.Ms(W.data,j+L*6+2,k)}return D};jY.V5=function(w,n,W,D,j,I,U){var M=J.IQ(W,I);I+=2;return jY.PB(w,n,W,D,j,I,M,U-2)};
jY.sM=function(w,n,W,D,j,I,U){J.H$(W,I,U);I+=2;I=jY.xd(w,n,W,D,j,I,U);return I};jY.PB=function(w,n,W,D,j,I,U,M){var m,l=D*j*(n>>>3),A=l&3,g=l+(A==0?0:4-A);
if(M<=0){return E.Q(g)}if(U>3){console.log("unknown compression: "+U,D,j,D*j,M);U=0}if(U==0){if(I+g<=W.length)m=W.slice(I,I+g);
else{m=E.Q(l);for(var L=0;L<l;L++)m[L]=W[I+L]}I+=l}else if(U==1){m=E.Q(l);var k=w?4:2,$=jY.alc(W,m,D,j,I,I+k*j,k);
I+=k*j+$}else if(U==2||U==3){var C=new Uint8Array(W.buffer,I+2,M-6),f=E.Q(g);UZIP.inflateRaw(C,f);if(U==3){if(n==8)for(var z=0;
z<j;z++){var s=z*D+1,a=s+D-1,X=f[s-1];for(var P=s;P<a;P++){X+=f[P];f[P]=X&255}}else for(var z=0;z<j;
z++){var s=z*D+1,a=s+D-1,X=f[2*s-2]<<8|f[2*s-1];for(var P=s;P<a;P++){var Z=P<<1;X+=f[Z]<<8|f[Z+1];f[Z]=X>>>8;
f[Z+1]=X&255}}}if(f.length==g)m=f;else{m=E.Q(g);for(var L=0;L<f.length;L++)m[L]=f[L]}}if(n==16){var Y=E.Q(D*j);
for(var L=0;L<l;L+=2)Y[L>>>1]=m[L];m=Y}return m};jY.xd=function(w,n,W,D,j,I,U){var M=D*j;if(U==0)for(var L=0;
L<M;L++)W[I++]=n[L];else if(U==1){var m=w?4:2,l=jY.a5M(n,W,D,j,I,I+m*j,m);I+=m*j+l}else if(U==2||U==3){if(U==3){var A=new Uint8Array(n.length);
for(var g=0;g<j;g++){var k=g*D+1,$=k+D-1,C=n[k-1];A[k-1]=C;for(var f=k;f<$;f++){A[f]=n[f]+(256-C)&255;
C=n[f]}}n=A}W[I]=120;W[I+1]=156;I+=2;var z=pako.deflateRaw(n,{a9L:4});J.a8b(W,I,z);I+=z.length+4}else console.log("Unknown compression: "+U);
return I};jY.alc=function(w,n,W,D,j,I,U){if(!(w instanceof Uint8Array)||!(n instanceof Uint8Array))throw"e";
var M=I,m=D|0;if(U==2)for(var L=0;L<m;L++){var l=J.IQ(w,j+(L<<1));jY.ZV(w,I,l,n,L*W,W);I+=l}else for(var L=0;
L<m;L++){var l=J.q(w,j+(L<<2));jY.ZV(w,I,l,n,L*W,W);I+=l}return I-M};jY.a5M=function(w,n,W,D,j,I,U){var M=I;
if(U==2)for(var L=0;L<D;L++){var m=jY.afT(w,L*W,W,n,I);J.ey(n,j+L*2,m);I+=m}else for(var L=0;L<D;L++){var m=jY.afT(w,L*W,W,n,I);
J.Ms(n,j+L*4,m);I+=m}return I-M};jY.afT=function(w,n,bK,W,D){var j,I,U,M,m,dN,l;M=n+bK;for(U=n,I=D;bK>0;
U=j,bK-=dN){l=bK<128?bK:128;if(U<=M-3&&w[U+1]==w[U+0]&&w[U+2]==w[U+0]){for(j=U+3;j<U+l&&w[j]==w[U+0];
)++j;dN=j-U;W[I++]=1+256-dN;W[I++]=w[U+0]}else{for(j=U;j<U+l;)if(j<=M-3&&w[j+1]==w[j+0]&&w[j+2]==w[j+0])break;
else++j;dN=j-U;W[I++]=dN-1;for(var L=0;L<dN;L++)W[I+L]=w[U+L];I+=dN}}return I-D};jY.ZV=function(w,n,W,D,j,I){for(var U=0;
U<W;){var bK=w[n++];if(bK>=128){var M=w[n++],m=j+(257-bK);D.fill(M,j,m);j=m;U+=2}else{for(var L=0;L<=bK;
L++)D[j+L]=w[n+L];n+=bK+1;j+=bK+1;U+=1+1+bK}}};function gg(){}gg.Fm=function(w,n,W){return;var D="",j=n;
while(j!=0){var I=j%1e3+"";while(I.length<3)I="0"+I;D=(D==""?I:I+" ")+D;j=Math.floor(j/1e3)}while(D.startsWith("0")&&D!="0")D=D.slice(1);
while(D.length<11)D=" "+D;console.log("===",D,"\t".repeat(w),": "+W)};gg.ajL=function(w){var n={qL:{}},D=0,j=0,M;
n.Kl=!1;n.g3=8;var W=new Uint8Array(w);j=gg.b9(n,W,D);D=j;j=gg.aeV(n,W,D);D=j;var I=J.q(W,D);D+=4+I;
var U=n.Kl?8:4;if(n.Kl)M=J.gg(W,D);else M=J.q(W,D);D+=U+M;j=gg.agt(n,W,D);return[{XL:new iB(0,0,n.m,n.n),data:n.buffer.buffer}]};
gg.ew=function(w,n){n.Kl=!1;n.g3=8;var W=new Uint8Array(w),D=0,j=0,o,fK=!1,i6=!0,dh=!1,kA=0,eX=0;j=gg.b9(n,W,D);
gg.Fm(0,j-D,"PSD Header");D=j;j=gg.aeV(n,W,D);gg.Fm(0,j-D,"Color Mode Data");D=j;j=gg.aa3(n,W,D);gg.Fm(0,j-D,"Image Resources");
D=j;j=gg.axZ(n,W,D);gg.Fm(0,j-D,"Layer And Mask Info");D=j;j=gg.agt(n,W,D);gg.Fm(0,j-D,"Merged Image");
D=j;if(n.C.length==0){var I=n.QI();I.nz("Background");n.C.push(I);I.buffer=n.buffer.slice(0);I.rect=new iB(0,0,n.m,n.n)}if(n.qL.r1005){n.hh=J.aq0(n.qL.r1005,0)}if(n.qL.r1026){var W=n.qL.r1026;
for(var L=0;L<W.length;L+=2){var j=n.C[L>>>1];if(j)j.Ux=J.IQ(W,L)}}if(n.qL.r1072){var W=n.qL.r1072;for(var L=0;
L<W.length;L++){var j=n.C[L];if(j)j.lj=W[L]==1}}if(n.qL.r1032){n.jg=gg.ass(n.qL.r1032,0)}delete n.qL.r1036;
n.y0(n.qL.r1039);if(n.qL.r1050){var U=J.q,M=n.qL.r1050,m=J.q(M,0);if(m==6){var l=4,A=J._I(M,l);l+=16;
var g=J.Nl(M,l);l+=4+g.length*2;var k=U(M,l);l+=4;var $=n.ej;for(var L=0;L<k;L++){var C=y.mk.Ih(),z;
$.push(C);C=C.v;C.sliceID.v=U(M,l);l+=4;C.groupID.v=U(M,l);l+=4;var f=U(M,l);l+=4;if(f==1){z=U(M,l);
l+=4}var g=J.Nl(M,l);l+=4+g.length*2;var s=U(M,l);l+=4;var O=[U(M,l),U(M,l+4),U(M,l+8),U(M,l+12)];l+=16;
y.mk.CA($,$.length-1,O);var a=C.url.v=J.Nl(M,l);l+=4+a.length*2;var X=C.null.v=J.Nl(M,l);l+=4+X.length*2;
var P=C.Msge.v=J.Nl(M,l);l+=4+P.length*2;var Z=C.altTag.v=J.Nl(M,l);l+=4+Z.length*2;C.cellTextIsHTML.v=M[l]==1;
l++;var Y=C.cellText.v=J.Nl(M,l);l+=4+Y.length*2;var K=U(M,l);l+=4;var S=U(M,l);l+=4;var G=M.slice(l,l+4);
l+=4;if(f!=2)$.pop()}}else if(m==8){var V={};jH.iS(M,V,8,!1);var M=n.ej=V.slices.v;for(var L=0;L<M.length;
L++){if(M[L].v.origin.v.ESliceOrigin!="userGenerated"){M.splice(L,1);L--}}}}if(n.qL.r1058){var T=n.qL.r1058,R=UTIF.decode(T.buffer,{parseMN:!1,debug:!1});
fd.X6(R[0],n.Zp);delete n.qL.r1058}if(n.qL.r1060){var x=J.KY(n.qL.r1060);fd.auh(x,n.Zp);delete n.qL.r1060}if(n.qL.r1065){var W=n.qL.r1065;
n.kO={};jH.iS(W,n.kO,4,!1)}if(n.qL.r1069){var W=n.qL.r1069,v=[];for(var L=2;L<W.length;L+=4){var z=J.q(W,L);
for(var N=0;N<n.C.length;N++){var j=n.C[N];if(j.add.lyid==z&&j.add.lsct!=3)v.push(N)}}n.g=v}if(n.qL.r1025){var u=n.qL.r1025;
delete n.qL.r1025;var H=bI.mV(u,0,u.length,n.m,n.n),F=new h.Rd;F.i=H;n.Oi[0]=kc.bb("Working Path",{vmsk:F})}var t=n.add.pths;
delete n.add.pths;var q=n.qL.r3000;if(q){o={};jH.iS(q,o,4,!1);delete n.qL.r3000}if(t){var _=t.pathSymmetrySelectedPath;
if(_){var d=t.pathList.v[_.v].v,r=d.pathUnicodeName.v;n.v_=r.startsWith("Tile Symmetry")}}for(var p=0;
p<=997;p++){var Q="r"+(2e3+p),u=n.qL[Q];if(u==null)break;var H=bI.mV(u,0,u.length,n.m,n.n),r="Path "+p;
if(t){var B=t.pathList.v[p].v;r=B.pathUnicodeName.v;if(r=="Tile Symmetry 1")continue}var i=o?o.keyRootDescriptorList.v[p].v.keyDescriptorList.v:h.hu(H),F=new h.Rd;
F.i=H;n.Oi.push(kc.bb(r,{vmsk:F,vogk:i}));delete n.qL[Q]}delete n.Kl;if(n.qL.r4000){n.HZ=E.HZ.ew(n.qL.r4000)}var c=n.qL.r7000,h2=n.qL.r7001;
if(c){var jX=J.KY(c);n.ol=gg.aaT(jX)}if(h2){var jX=J.KY(h2);n.Ei=gg.awK(jX)}delete n.qL.r7000;delete n.qL.r7001;
var bm=new iB(0,0,n.m,n.n),dC=n.add.Txt2,fn=dC;if(fn){fn=fn.bC;if(fn._DocumentResources==null)fn=cI.a7z(fn)}var ig=-1;
for(var L=0;L<n.C.length;L++){var j=n.C[L],iJ=j.add.lsct,fL=j.add.vmsk,fB=j._N();if(iJ==ef.Cq){kA++;
j.add.lspf=0}else if(iJ==ef.fz||iJ==ef.Se)kA--;if(j.name==""){j.name="Layer "+(L+1);dh=!0}if(dh&&j.ue()&&j.Bx=="norm")j.Bx="pass";
if(j.YC()&&j.NP(n)==null)delete j.add.SoLd;if(j.YC()&&j.NP(n).z){var ah=j.NP(n);ah.z.isEnabled=j.add.SoLd.filterFX.v.filterMaskEnable.v}if(fL&&j.I9()){var eS=at.QO.default;
if(j.add.vstk==null)j.add.vstk=JSON.parse(JSON.stringify(eS));else{var gL="strokeStyleLineDashSet";if(j.add.vstk[gL]==null)j.add.vstk[gL]=JSON.parse(JSON.stringify(eS[gL]))}j.add.vstk.strokeStyleResolution.v=n.hh}if(fL&&(j.add.vogk==null||E.P.bB(fL.i)!=j.add.vogk.length))j.hu();
if(!1){var e_=j.add.vogk,c2=!0;for(var jS=0;jS<e_.length;jS++){var ie=e_[jS].v.keyShapeInvalidated;if(ie==null||ie.v==!1)c2=!1}if(c2)j.hu()}if(j.add.SoLd&&j.rect.VY()){console.log("redrawing smart instance");
j.vr(n)}if(fB==null&&j.z!=null){if(j.z.CT==!1){j.z.CT=!0;j.pv=j.z.clone()}}fB=j._N();if(j.Ic){var eS=j.Ic,F=fL;
if(fB){fB.MX=eS[0];fB.C3=eS[1]}if(F){F.MX=eS[2];F.C3=eS[3]}j.Ic=null}if(fB!=null&&fL!=null&&(fB.C3+fL.C3!=0||fB.MX+fL.MX!=2*255))j.yb(n);
else if(fL!=null&&!j.I9())j.yb();else if(fB&&fB.MX!=255&&j.I9())j.yb(n);var as=j.add.artb;if(as&&as.artboardBackgroundType==null)as.artboardBackgroundType={t:"long",v:1};
if(as&&kA!=0)delete j.add.artb;var gb=j.add.vstk;if(j.I9()&&(j.rect.VY()||fL&&fL.C3!=0||gb&&!gb.fillEnabled.v&&(!gb.strokeEnabled.v||gb.strokeStyleLineWidth.v.val==0)))j.sO(n);
if(j.add.TySh){fK=!0;if(!j.rect.VY())i6=!1}if(j.add.TySh&&fn){ig++;var gx=j.add.TySh._o,eo=hd.Bj(gx),di=fn._DocumentObjects._TextObjects;
if(di.length<=ig){console.log("Txt2 incomplete");continue}var d0=di[ig]._Model,e6=d0._StyleRun?d0._StyleRun._RunArray:[],dt=gx.EngineDict.StyleRun.RunArray;
for(var gJ=0;gJ<dt.length;gJ++){var iW=dt[gJ].StyleSheet.StyleSheetData;if(e6[gJ]==null)continue;var g5=e6[gJ]._RunData._StyleSheet._Features;
if(g5&&g5._BaselineDirection)iW.BaselineDirection=parseInt(g5._BaselineDirection.slice(1));if(g5&&g5._FillBackgroundFlag)iW._FillBackgroundFlag=g5._FillBackgroundFlag;
if(g5&&g5._FillBackgroundColor){var jW=g5._FillBackgroundColor,eP=jW._Color._Values.slice(0);for(var N=0;
N<4;N++)eP[N]=parseFloat(eP[N].slice(1));iW._FillBackgroundColor={Type:1,Values:eP}}if(g5&&g5._LineWidth)iW._LineWidth=parseFloat(g5._LineWidth.slice(1))}var b_=gx.EngineDict.ParagraphRun.RunArray,fZ=d0._ParagraphRun._RunArray;
if(fZ==null)fZ=[];var im=Math.min(fZ.length,b_.length);for(var N=0;N<im;N++){var j3=b_[N].ParagraphSheet.Properties,dr=fn._DocumentResources._ParagraphSheetSet._Resources,c0=fZ[N]._RunData._ParagraphSheet;
if(typeof c0=="string")c0=dr[parseInt(c0.slice(1))]._Resource;var fM=c0._Parent==null?c0:dr[parseInt(c0._Parent.slice(1))]._Resource;
c0=c0._Features;fM=fM._Features;var cB=c0._ParagraphDirection;if(cB==null)cB=fM._ParagraphDirection;
if(cB)j3._Direction=parseInt(cB.slice(1));if(c0._ComposerEngine)j3._ComposerEngine=parseInt(c0._ComposerEngine.slice(1))}if(d0._AlternateGlyphRun){var fZ=d0._AlternateGlyphRun._RunArray,im=fZ.length,iI=gx.EngineDict.AlternateGlyphRun=hd.amY();
for(var N=0;N<im;N++){var c0=fZ[N],jD={},j8=c0._RunData._AlternateGlyphSheet;if(j8)jD.Glyph=parseInt(j8._Glyph.slice(1));
iI.RunArray.push(jD);iI.RunLengthArray.push(parseInt(c0._Length.slice(1)))}}var jG=fn._DocumentResources,i1=jG._TextFrameSet._Resources,bH=i1[ig]._Resource,a_=bH._Data,aR=new eh(1,0,0,1,0,0);
if(bH._0){var iY=parseFloat(bH._0[0].slice(1)),gy=parseFloat(bH._0[1].slice(1));aR.translate(iY,gy)}if(eo){aR.translate(eo[0],eo[1]);
hd.sV(gx,[0,0,eo[2]-eo[0],eo[3]-eo[1]])}else{if(bH._Bezier&&bH._Bezier._Points){var H=bH._Bezier._Points,iY=parseFloat(H[0].slice(1)),gy=parseFloat(H[1].slice(1));
if(iY!=0||gy!=0){aR.translate(iY,gy)}}}if(bH._Data&&bH._Data._FrameMatrix){var gr=bH._Data._FrameMatrix;
gr=gr.map(function(ko){return parseFloat(ko.slice(1))});aR.concat(new eh(gr[0],gr[1],gr[2],gr[3],gr[4],gr[5]))}aR.concat(j.add.TySh.D);
j.add.TySh.D=aR;var s=a_._Type?parseInt(a_._Type.slice(1)):0;if(s==2||s==1&&a_._PathData&&a_._PathData._Spacing=="i-3")if(bH._Bezier){var fs=function(ko){return parseFloat(ko.slice(1))},H=bH._Bezier._Points.map(fs);
if(eo)E.p.D(H,new eh(1,0,0,1,-eo[0],-eo[1]),H);var dQ=a_._PathData?a_._PathData._Reversed:!1,ep=a_._TextOnPathTRange;
if(ep==null)ep=["f-3","f-3"];gx.Curve={Points:H,TextOnPathTRange:ep.map(fs),Reversed:dQ==null?!1:dQ};
j.add.TySh.add={vmsk:new h.Rd,vogk:null};hd.ls(j.add.TySh)}if(a_._LineOrientation=="i2")gx._LineOrientation=2}}y.Ul.PR(n,!0);
var b2={},iz=[];for(var L=0;L<n.C.length;L++){var en=n.C[L].add.lyid;if(en==null)continue;var eX=Math.max(eX,en);
if(b2[en]!=null)iz.push(L);else b2[en]=!0}for(var L=0;L<iz.length;L++)n.C[iz[L]].add.lyid=eX+1+L};gg.ass=function(w,n){var W=J.q(w,n+12),D=[];
for(var L=0;L<W;L++){var j=w[n+16+L*5+4],I=J.W6(w,n+16+L*5)/32;D.push([j,I])}return D};gg.aaT=function(w){var n=new DOMParser,W=n.parseFromString(w,"text/xml").firstChild.children[0],D=W.getElementsByTagName("variables");
if(D.length==0)return[];D=D[0].children;var j=[],I="varName trait docRef placementMethod align valign clip".split(" ");
for(var U=0;U<D.length;U++){var M=D[U],m={};j.push(m);for(var l=0;l<I.length;l++){var A=I[l],g=M.getAttribute(A);
if(g==null)continue;m[A]=g}}return j};gg.awK=function(w){var n=new DOMParser,W=n.parseFromString(w,"text/xml").firstChild.children,D=[[]];
if(W==null)return D;for(var L=0;L<W.length;L++){var j=W[L],I=[];D.push(I);for(var U=0;U<j.children.length;
U++){var M=j.children[U];if(L==0)D[0].push(M.tagName);I.push(M.textContent)}}return D};gg.Pj=function(w,n,W){y.Ul.ak(w);
y.Ul.PR(w,!1);w.Kl=W[3]==!0;var D=[],j=[],C=0,z=1,Z=16,dh=0;for(var L=0;L<w.C.length;L++){var I=w.C[L];
if(I.YC()&&I.NP(w).z){I.add.SoLd.filterFX.v.filterMaskEnable.v=I.NP(w).z.isEnabled}if(I.add.TySh){var U=I.add.TySh._o,M=hd.F$(U);
I.add.TySh.lz.TextIndex={t:"long",v:D.length};D.push(U);if(M==2)hd.Y_(I.add.TySh)}var m=I.add.vstk;if(m)m.strokeStyleResolution.v=w.hh;
if(I.I9()||W[2]&&I.add.SoLd){j[L]=[I.rect,I.buffer];I.rect=new iB;I.buffer=E.Q(0);if(I.add.SoLd){var l=I.NP(w);
if(l!=null){j[L].push(l.buffer);l.buffer=E.Q(l.buffer.length)}}}}if(D.length>0){var A=w.add.Txt2?w.add.Txt2.bC:null;
if(w.add.Txt2==null)w.add.Txt2={};w.add.Txt2.bC=gD.a6F(D,null,A)}var g=[w.add.lnk2,w.add.FEid,w.add.Patt],k=w.apA(w.C);
w.a8p(k);w.qL.r1005=new Uint8Array([0,0,0,0,0,1,0,2,0,0,0,0,0,1,0,2]);J.az1(w.qL.r1005,0,w.hh);J.az1(w.qL.r1005,8,w.hh);
if(w._A()){w.qL.r1022=new Uint8Array([0,3+w.yo.length-1,0])}else delete w.qL.r1022;var $=new Uint8Array(w.C.length*2),f=new Uint8Array(w.C.length);
for(var L=0;L<w.C.length;L++){var I=w.C[L],s=I.Ux,O=I.lj?1:0;J.ey($,L*2,s);f[L]=O;if(s>C)C=s;if(O==0)z=0}if(C>0)w.qL.r1026=$;
if(z<1)w.qL.r1072=f;var a=w.jg,X=a.length,P=w.qL.r1032=E.Q(16+5*X,!0);J.Ms(P,0,1);J.Ms(P,4,576);J.Ms(P,8,576);
J.Ms(P,12,X);for(var L=0;L<X;L++){J.KW(P,Z,Math.round(a[L][1]*32));P[Z+4]=a[L][0];Z+=5}if(W[4]!=!0){var Y=[w.buffer,new iB(0,0,w.m,w.n)],K=0;
E.L3(Y);while(Y[K+1].O()>200*200)K+=2;var S=jj.ZO("jpg"),G=Y[K+1],V=new Uint8Array(S.La([[Y[K].buffer]],G.m,G.n)),P=w.qL.r1036=E.Q(28+V.length);
J.Ms(P,0,1);J.Ms(P,4,G.m);J.Ms(P,8,G.n);J.Ms(P,12,G.m*3);J.Ms(P,16,G.O()*3);J.Ms(P,20,V.length);J.ey(P,24,24);
J.ey(P,26,1);P.set(V,28)}var T=E.Ym(w.buffer),R=[];if(T)R.push({name:"Transparency",pL:{o:255,B:0,k:0},Zg:100,Y3:1});
R=R.concat(w.yo);delete w.qL.r1045;delete w.qL.r1006;delete w.qL.r1077;var x=new cs;Z=0;var v=new Uint8Array(4+R.length*13);
v[3]=1;for(var L=0;L<R.length;L++){var N=R[L],u=N.name+"\0";J.wk(x,Z,u);Z+=4+u.length*2;var H=4+L*13;
dm.Dg(v,H,N.pL);v[H+11]=N.Zg;v[H+12]=N.Y3}if(Z!=0)w.qL.r1045=x.data.slice(0,Z);w.qL.r1077=v;for(var L=0;
L<w.ej.length;L++)w.ej[w.ej.length-L-1].v.sliceID.v=2+L*3;var F={classID:"null",baseName:{t:"TEXT",v:"User"},bounds:{t:"Objc",v:{classID:"Rct1",Top:{t:"long",v:0},Left:{t:"long",v:0},Btom:{t:"long",v:0},Rght:{t:"long",v:0}}},slices:{t:"VlLs",v:w.ej}},x=new cs;
J._Z(x,0,8);J._Z(x,4,16);var t=jH.X3(x,F,8);w.qL.r1050=x.data.slice(0,t+8);var x=new cs;J._Z(x,0,16);
var t=jH.X3(x,w.kO,4);w.qL.r1065=x.data.slice(0,t+4);var o=w.g;P=w.qL.r1069=E.Q(2+o.length*4,!0);J.ey(P,0,o.length);
for(var L=0;L<o.length;L++)J.Ms(P,2+4*L,w.C[o[L]].add.lyid);delete w.qL.r1058;delete w.qL.r1060;if(Object.keys(w.Zp).length!=0){var q=[{t274:[1],t282:[[72,1]],t283:[[72,1]],t296:[2]},{t259:[6],t282:[[72,1]],t283:[[72,1]],t296:[2],t513:[302],t514:[0]}];
fd.cG(w.Zp,q[0],W[0]&&W[1]);w.qL.r1058=new Uint8Array(UTIF.encode(q));var _=fd.acC(w.Zp);w.qL.r1060=J.zY(_)}var d=[],r=[],p=w.Oi.slice(0);
if(w.v_){var Q=bI.sy([{type:6},{type:8,all:0},{type:3,length:5,frule:1,third:2,prmA:0,prmB:0},{type:5,c:[0,0,0,0,0,0]},{type:5,c:[20,0,20,0,20,0]},{type:5,c:[20,20,20,20,20,20]},{type:5,c:[0,20,0,20,0,20]},{type:5,c:[0,0,0,0,0,0]}]),B=new h.Rd;
B.i=Q;p.push(kc.bb("Tile Symmetry 1",{vmsk:B,vogk:h.hu(Q)}))}for(var L=0;L<p.length;L++){var i=p[L],Q=i.add.vmsk.i;
if(L==0&&Q.length==2)continue;var c=E.Q(Q.length*26);bI.yW(c,0,Q,w.m,w.n);var h2=L==0?1025:2e3+L-1;w.qL["r"+h2]=c;
if(L!=0){var jX={classID:"pathInfoClass",pathUnicodeName:{t:"TEXT",v:i.name}};if(i.name=="Tile Symmetry 1")jX.pathSymmetryClass={t:"Objc",v:{classID:"pathSymmetryClass",pathSymmetryMode:{t:"enum",v:{pathSymmetryModeEnum:"pathSymmetryModeRectangularTile"}},pathSymmetryCount:{t:"long",v:1}}};
d.push({t:"Objc",v:jX});r.push({t:"Objc",v:{classID:"null",keyDescriptorList:{t:"VlLs",v:i.add.vogk}}})}}if(d.length!=0){w.add.pths={classID:"pathsDataClass",pathList:{t:"VlLs",v:d}};
if(w.v_)w.add.pths.pathSymmetrySelectedPath={t:"long",v:d.length-1};r={classID:"null",keyRootDescriptorList:{t:"VlLs",v:r}};
var x=new cs;J._Z(x,0,16);var t=jH.X3(x,r,4);w.qL.r3000=x.data.slice(0,t+4)}else{delete w.add.pths;delete w.qL.r3000}if(w.HZ){w.qL.r4000=E.HZ.Pj(w.HZ)}if(w.ol.length!=0){var bm="<variableSets xmlns=\"http://ns.adobe.com/Variables/1.0/\">\n"+"<variableSet locked=\"none\" varSetName=\"binding1\">\n"+"<variables>";
for(var L=0;L<w.ol.length;L++){var dC=w.ol[L],fn=[];for(var h2 in dC)fn.push(h2+"=\""+dC[h2]+"\"");bm+="<variable "+fn.join(" ")+">\n</variable>\n"}bm+="</variables>\n</variableSet>\n</variableSets>";
w.qL.r7000=J.zY(bm)}if(w.Ei.length!=0){var bm="<sampleDataSets psdPath=\""+w.name+"\">\n";for(var L=1;
L<w.Ei.length;L++){var fK=w.Ei[L];bm+="<sampleDataSet dataSetName=\"Data Set "+L+"\">\n";for(var i6=0;
i6<fK.length;i6++)bm+="<"+w.Ei[0][i6]+">"+fK[i6].replace(/</g,"&lt;").replace(/>/g,"&gt;")+"</"+w.Ei[0][i6]+">\n";
bm+="</sampleDataSet>\n"}bm+="</sampleDataSets>";w.qL.r7001=J.zY(bm)}dh=gg.a2o(w,n,dh,3+R.length);dh=gg.aeN(w,n,dh);
dh=gg.axl(w,n,dh);dh=gg.a1Y(w,n,dh,W,T);dh=gg.at8(w,n,dh,W[0],T);var kA=[1025,2e3,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010,2011,2012,2013,2014,2015,2016,7e3,7001];
for(var L=0;L<kA.length;L++)delete w.qL["r"+kA[L]];for(var L=0;L<w.C.length;L++){var I=w.C[L];if(I.I9()||W[2]&&I.add.SoLd){I.rect=j[L][0];
I.buffer=j[L][1];if(j[L][2]){var l=I.NP(w);j[L].push(l.buffer);l.buffer=j[L][2]}}}w.a8p(g);y.Ul.PR(w,!0);
delete w.Kl;return dh};gg.b9=function(w,n,W){var D=J.sv(n,W,4);W+=4;if(D!="8BPS")alert("invalid header signature: "+D);
var j=J.IQ(n,W);W+=2;w.Kl=j==2;if(j!=1&&j!=2)alert("invalid version: "+j);W+=6;w.UY=J.IQ(n,W);W+=2;w.n=J.W6(n,W);
W+=4;w.m=J.W6(n,W);W+=4;w.g3=J.IQ(n,W);W+=2;w.UM=J.IQ(n,W);W+=2;return W};gg.a2o=function(w,n,W,D){n.lN(0,64);
J.Jm(n.data,W,"8BPS");W+=4;J.ey(n.data,W,w.Kl?2:1);W+=2;J.Ms(n.data,W,0);W+=4;J.ey(n.data,W,0);W+=2;
J.ey(n.data,W,D);W+=2;J.KW(n.data,W,w.n);W+=4;J.KW(n.data,W,w.m);W+=4;J.ey(n.data,W,8);W+=2;J.ey(n.data,W,3);
W+=2;return W};gg.aeV=function(w,n,W){var D=J.W6(n,W);W+=4;if(D!=0)w.tD=n.slice(W,W+D);W+=D;return W};
gg.aeN=function(w,n,W){J.Wr(n,W,0);W+=4;return W};gg.aa3=function(w,n,W){var D=J.q(n,W),j=0;W+=4;var I=[];
while(j<D){var U=J.sv(n,W+j,4);j+=4;var M=J.IQ(n,W+j);j+=2;var m=J.$B(n,W+j);j+=m.length;if(U=="MeSa"&&(M==7e3||M==7001)){}else if(U!="8BIM"){I.push(M);
console.log("Unknown Image Resources signature: "+U+", ID: "+M)}var l=J.q(n,W+j);j+=4;if(w.qL["r"+M]!=null)console.log("--- two resources with same ID");
w.qL["r"+M]=J.Xv(n,W+j,l);j+=l+(l&1)}for(var L=0;L<I.length;L++)delete w.qL["r"+I[L]];return W+D};gg.axl=function(w,n,W){var D=W,U=0;
W+=4;var j=[];for(var I in w.qL){j.push(parseInt(I.slice(1)))}j.sort(function(g,k){return g-k});for(var L=0;
L<j.length;L++){var M=j[L];J.YY(n,W+U,M==7e3||M==7001?"MeSa":"8BIM");U+=4;J.vo(n,W+U,M);U+=2;var m=J.Tc(n,W+U,"");
U+=m;var l=w.qL["r"+M],A=l.length;J._Z(n,W+U,A);U+=4;J.sS(n,W+U,l);U+=A;if(A%2==1)U++}J._Z(n,D,U);return W+U};
gg.axZ=function(w,n,W){var D=W,j,I,U=w.Kl?8:4;if(w.Kl)j=J.gg(n,W);else j=J.q(n,W);W+=U;if(j==0)return D+U;
I=gg.a3p(w,n,W);gg.Fm(1,I-W,"Layer Info");W=I;I=gg.a2A(w,n,W);gg.Fm(1,I-W,"Global Layer Mask Info");
W=I;I=dR.a1V(n,W,D+U+j,w.add,w.Kl,w);gg.Fm(1,I-W,"Project Add Info");W=I;return D+U+j};gg.a1Y=function(w,n,W,D,j){var I=W;
J._Z(n,W,0);W+=4;if(w.Kl){J._Z(n,W,0);W+=4}W=gg.a0j(w,n,W,D,j);W=gg.a3A(w,n,W);W=dR.abT(n,W,w.add,w.Kl,w);
if(w.Kl)J.JH(n,I,W-I-8);else J._Z(n,I,W-I-4);return W};gg.a3p=function(w,n,W){var D,j=w.Kl?8:4;if(w.Kl)D=J.gg(n,W);
else D=J.q(n,W);W+=j;if(D!=0)gg.q2(w,n,W);return W+D};gg.q2=function(w,n,W){var D=J.zx(n,W);W+=2;var j=Math.abs(D);
for(var L=0;L<j;L++){var I=new h;W=ke.ew(I,w,n,W);w.C[L]=I}var U=new iB(0,0,w.m,w.n);for(var L=0;L<j;
L++){var M=w.C[L],m=M._N(),l=jY.ew(M,w,n,W);if(l-W>8)gg.Fm(2,l-W,"Lay: "+M.getName());W=l;gg.ah6(M,U);
if(m)gg.ah6(m,U)}};gg.ah6=function(w,n){};gg.a0j=function(w,n,W,D,j){var I=W,U=w.Kl;W+=U?8:4;W=gg.avU(w,n,W,D,j);
var M=W-I-(U?8:4);if(M%2!=0)M++;if(U)J.JH(n,I,M);else J._Z(n,I,M);return I+M+(U?8:4)};gg.avU=function(w,n,W,D,j){var I=w.C.length;
J.im(n,W,j?-I:I);W+=2;var U=[];for(var L=0;L<I;L++)W=ke.Pj(w.C[L],w,n,W,U);for(var L=0;L<I;L++)W=jY.z8(w.Kl,w.C[L],n,W,U[L],D);
return W};gg.a2A=function(w,n,W){var D=J.q(n,W);W+=4;W+=D;return W};gg.a3A=function(w,n,W){var D=J._Z(n,W,0);
W+=4;return W};gg.agt=function(w,n,W){var D=w.UM,j="Bitmap Grayscale Indexed RGB CMYK Multichannel Duotone Lab".split(" "),I=[1,1,1,3,4,1,1,3],U,f;
if(D!=3){if(D==1||D==2||D==4)console.log("Project will be converted from "+j[D]+" to "+j[3]+" mode.");
else{alert("Color mode "+j[D]+" is not supported yet :(")}if(D==4)w.add.fcmy=1}if(w.qL.r1045){U=[];var M=w.qL.r1045,m=0;
while(m<M.length){var l=J.CX(M,m);U.push(l);m+=4+2+l.length*2}}var A=I[D]+(U==null||U[0]=="Transparency"?1:0),g=w.m,k=w.n,$=g*k,C=J.IQ(n,W);
W+=2;w.buffer=E.Q($*4);E.cJ(w.buffer,4278190080);var z=W;for(var s=0;s<w.UY;s++){if(C==0){f=jY.PB(w.Kl,w.g3,n,g,k,W,C);
W+=$*(w.g3>>>3)}else if(C==1){f=E.Q($);var O=w.Kl?4:2;if(s==0)W+=w.UY*k*O;W+=jY.alc(n,f,g,k,z+s*k*O,W,O)}else{console.log("unknown compression of image data: ",C);
return}if(s<A){E.IL(f,w.buffer,s);if(w.UY==1&&s==0){E.IL(f,w.buffer,1);E.IL(f,w.buffer,2)}}else{var a=new h.ac,X=s-A,P=s-I[w.UM];
a.name=U?U[P]:"Alpha";if(a.name=="Quick Mask"){a.$P=!0;w.v9.push(X)}a.rect=new iB(0,0,g,k);a.channel=f;
a.color=0;a.ky();w.yo[X]=a;if(w.qL.r1077){var M=w.qL.r1077.slice(4+P*13);a.pL=dm.mn(M,0);a.Zg=M[11];
a.Y3=M[12];if(a.Y3==2)a.$P=!0}}}w.UY=4;if(w.UM==2)for(var L=0;L<$;L++){var Z=L*4,Y=w.buffer[Z];w.buffer[Z]=w.tD[0+Y];
w.buffer[Z+1]=w.tD[256+Y];w.buffer[Z+2]=w.tD[512+Y]}return W};gg.at8=function(w,n,W,D,j){var I=1,U=16,M=w.m,m=w.n,A,g;
J.vo(n,W,I);W+=2;var l=M*m;if(!D){g=new E.H0(M*m);E.rH(w.buffer,g);var k=g.o,$=g.B,C=g.k,f=g.dl;for(var L=0;
L<l;L++){var z=f[L]*(1/255);k[L]=~~(k[L]*z+255*(1-z));$[L]=~~($[L]*z+255*(1-z));C[L]=~~(C[L]*z+255*(1-z))}}else A=E.Q(l);
var s=[A,A,A];if(!D)s=[g.o,g.B,g.k];if(j)s.push(D?A:g.dl);for(var L=0;L<w.yo.length;L++){s.push(w.yo[L].Ln(new iB(0,0,w.m,w.n)))}var O=W;
for(var a=0;a<s.length;a++){n.lN(W,M*m+4);A=s[a];if(I==0||I==2||I==3)W=jY.xd(w.Kl,A,n.data,M,m,W,I);
else{var X=w.Kl?4:2;if(a==0)W+=s.length*m*X;var P=W;W+=jY.a5M(A,n.data,M,m,O+a*m*X,W,X)}}return W};function eY(){}eY.ew=function(w){var n={};
eY.m8(w,n,0,0);return n};eY.Pj=function(w,n){var W=0;W=eY.dT(w,n,W,0);return W};eY.m8=function(w,n,W,D){while(w[W]!="<".charCodeAt(0))W++;
W+=2;while(!0){if(w[W]=="/".charCodeAt(0)){W++;var j=J.indexOf(w," ".charCodeAt(0),W,W+50),I=J.indexOf(w,"\n".charCodeAt(0),W,W+50);
if(I==-1)I=Infinity;if(j==-1)j=Infinity;var U=Math.min(I,j),M=J.sv(w,W,U-W),m=eY.vM(w,U+1,D+1,M);n[M]=m.Z;
W=U+1;W+=m.size}else if(w[W]==">".charCodeAt(0)){W+=2;break}else{var l=w[W];if(l==10||l==9||l==32)W++;
else{console.log("unknown byte: "+l+", char: "+String.fromCharCode(l),W);W++}}}return W};eY.dT=function(w,n,W,D){J.YY(n,W,"<<\n");
W+=3;var j=eY.ayt;for(var I in w){J.kW(n,W,"\t".charCodeAt(0),D+1);W+=D+1;J.YY(n,W,"/"+I);W+=1+I.length;
if(j(w[I])||w[I]instanceof Array){J.YY(n,W," ");W++}else{J.YY(n,W,"\n");W++;J.kW(n,W,"\t".charCodeAt(0),D+1);
W+=D+1}W=eY.FW(w[I],n,W,D+1);J.YY(n,W,"\n");W++}J.kW(n,W,"\t".charCodeAt(0),D);W+=D;J.YY(n,W,">>");W+=2;
return W};eY.vM=function(w,n,W,D){var j=n,I={size:0,Z:0};while(!0){while(w[n]==" ".charCodeAt(0)||w[n]=="\t".charCodeAt(0)||w[n]=="\n".charCodeAt(0))n++;
if(w[n]=="<".charCodeAt(0)){I.Z={};n=eY.m8(w,I.Z,n,W+1);break}else if(w[n]=="(".charCodeAt(0)){n+=3;
var U=n;while(!0){if(w[U-1]!="\\".charCodeAt(0)&&w[U]==")".charCodeAt(0)&&(w[U+1]=="\n".charCodeAt(0)||w[U+1]==" ".charCodeAt(0)))break;
else U++}I.Z=J.a5U(w,n,U);n=U+2;break}else if(w[n]=="[".charCodeAt(0)){n++;I.Z=[];while(w[n]==" ".charCodeAt(0)||w[n]=="\t".charCodeAt(0)||w[n]=="\n".charCodeAt(0))n++;
while(w[n]!="]".charCodeAt(0)){var M=eY.vM(w,n,W+1,D);I.Z.push(M.Z);n+=M.size;while(w[n]==" ".charCodeAt(0)||w[n]=="\t".charCodeAt(0)||w[n]=="\n".charCodeAt(0))n++}n++;
break}else{var m=J.indexOf(w," ".charCodeAt(0),n,n+50),l=J.indexOf(w,"\n".charCodeAt(0),n,n+50);if(l==-1)l=Infinity;
if(m==-1)m=Infinity;var A=J.sv(w,n,Math.min(m,l)-n).trim(),g=parseFloat(A);if(!isNaN(g)){I.Z=parseFloat(A);
n=Math.min(m,l)+1;break}else if(A=="true"||A=="false"){I.Z=A=="true";n=Math.min(m,l)+1;break}else if(A=="null"||A=="NaN"||A=="undefined"){I.Z=0;
n=Math.min(m,l)+1;break}else{console.log("unknown identifier: "+A);throw"e"}n=Math.min(m,l)+1}}I.size=n-j;
return I};eY.FW=function(w,n,W,D){if(w instanceof Array){var j=w.length==0||typeof w[0]=="number";if(j){J.YY(n,W,"[ ");
W+=2;for(var L=0;L<w.length;L++){var I=w[L]+" ";J.YY(n,W,I);W+=I.length}J.YY(n,W,"]");W+=1}else{J.YY(n,W,"[\n");
W+=2;for(var L=0;L<w.length;L++){J.kW(n,W,"\t".charCodeAt(0),D);W+=D;W=eY.FW(w[L],n,W,D);J.YY(n,W,"\n");
W++}J.kW(n,W,"\t".charCodeAt(0),D);W+=D;J.YY(n,W,"]");W+=1}}else if(w instanceof Object){W=eY.dT(w,n,W,D)}else if(typeof w=="string"){J.YY(n,W,"(");
W++;J.kW(n,W,254);W++;J.kW(n,W,255);W++;W=J.acw(n,W,w);J.YY(n,W,")");W+=1}else{var I=w+"";J.YY(n,W,I);
W+=I.length}return W};eY.ayt=function(w){var n=typeof w;return n=="string"||n=="number"||n=="boolean"};
function iK(){}iK.ew=function(w){var n={};iK.at7(w,n,0,0);return n};iK.Pj=function(w,n){var W=0;J.YY(n,W," ");
W++;W=iK.ahv(w,n,W,0);W--;n.lN(W,2);n.data[W]=n.data[W+1]=0;W+=2;return W};iK.m8=function(w,n,W,D){while(w[W]!="<".charCodeAt(0)){W++;
console.log("\u0161ipka")}W+=2;W=iK.at7(w,n,W,D);return W};iK.dT=function(w,n,W,D){J.YY(n,W,"<< ");W+=3;
W=iK.ahv(w,n,W,D);J.YY(n,W,">>");W+=2;return W};iK.BF=function(w){return w==9||w==10||w==32};iK.at7=function(w,n,W,D){while(!0){while(iK.BF(w[W])||w[W]==0)W++;
if(W>=w.length)break;if(w[W]=="/".charCodeAt(0)){W++;var j=W;while(!iK.BF(w[j]))j++;var I=J.sv(w,W,j-W);
W=j+1;var U=iK.vM(w,W,D,I);n["_"+I]=U.Z;W+=U.size}else if(w[W]==">".charCodeAt(0)){W+=2;break}else{var M=w[W];
console.log(J.sv(w,W,W+100));console.log("unknown byte: "+M+", char: "+String.fromCharCode(M)+", offset: "+W);
W++;throw"e";return-1}}return W};iK.ahv=function(w,n,W,D){for(var j in w){var I=j.substring(1,j.length);
J.YY(n,W,"/"+I);W+=1+I.length;J.YY(n,W," ");W++;W=iK.FW(w[j],n,W,D+1);J.YY(n,W," ");W++}return W};iK.vM=function(w,n,W,D){var j=n,I={type:"",size:0,Z:0};
while(iK.BF(w[n]))n++;if(w[n]=="<".charCodeAt(0)){I.type="Object";I.Z={};n=iK.m8(w,I.Z,n,W+1)}else if(w[n]=="(".charCodeAt(0)){I.type="String";
n++;if(w[n]==")".charCodeAt(0)){I.Z="e";n++}else{n+=2;var U=n,M=0;while(!0){if(w[U]==")".charCodeAt(0)&&w[U-1]!="\\".charCodeAt(0))break;
else U+=1}I.Z="s"+J.a5U(w,n,U);n=U+2}}else if(w[n]=="[".charCodeAt(0)){n++;I.Z=[];I.type="Array";while(iK.BF(w[n]))n++;
while(w[n]!="]".charCodeAt(0)){var m=iK.vM(w,n,W+1,D);if(m==-1)return-1;I.Z.push(m.Z);n+=m.size;delete m.size;
while(iK.BF(w[n]))n++}n++}else{var l=n;while(!iK.BF(w[l]))l++;var A=J.sv(w,n,l-n),g=parseFloat(A);if(!isNaN(g)&&A.indexOf(".")!=-1){I.type="Float";
var k=parseFloat(A);I.Z="f"+k}else if(!isNaN(g)&&A.indexOf(".")==-1){I.type="Integer";I.Z="i"+parseInt(A)}else if(A=="true"||A=="false"){I.type="Boolean";
I.Z=A=="true"}else if(A.charAt(0)=="/"){I.type="BString";I.Z=A}else if(A=="NaN"||A=="undefined"){I.type="Float";
I.Z="f0"}else{console.log("unknown value",JSON.stringify(A));throw"e"}n=l+1}I.size=n-j;return I};iK.aAG=function(w){if(w==Math.round(w))return w+".0";
var n=w.toFixed(5);while(n.endsWith("0")&&n[n.length-2]!=".")n=n.slice(0,n.length-1);if(0<w&&w<1)n=n.slice(1);
if(-1<w&&w<0)n="-"+n.slice(2);return n};iK.FW=function(w,n,W,D){var j=typeof w=="string"?w.charAt(0):"";
if(w instanceof Array){J.YY(n,W,"[ ");W+=2;for(var L=0;L<w.length;L++){W=iK.FW(w[L],n,W,D);J.YY(n,W," ");
W++}J.YY(n,W,"]");W+=1}else if(w instanceof Object){W=iK.dT(w,n,W,D)}else if(j=="e"){J.YY(n,W,"()");
W+=2}else if(j=="s"){J.YY(n,W,"(");W++;J.kW(n,W,254);W++;J.kW(n,W,255);W++;W=J.acw(n,W,w.substring(1));
J.YY(n,W,")");W++}else if(j=="/"){J.YY(n,W,w);W+=w.length}else if(j=="f"){var I=parseFloat(w.substring(1)),U=iK.aAG(I);
J.YY(n,W,U);W+=U.length}else if(j=="i"){J.YY(n,W,w.substring(1));W+=w.length-1}else{var U=w+"";J.YY(n,W,U);
W+=U.length}return W};function J(){}J.ahg=function(bK){var w="";for(var L=3;L>=0;L--)w+=String.fromCharCode(bK>>L*8&255);
return w};J.adu=function(w){var bK=0;for(var L=w.length-1;L>=0;L--)bK|=w.charCodeAt(L)<<(3-L)*8;return bK};
J.indexOf=function(w,n,W,D){if(W==null)W=0;if(D==null)D=w.length;D=Math.min(D,w.length);for(var L=W;
L<D;L++)if(w[L]==n)return L;return-1};J.TN=function(w,n,W){if(W==null)W=0;var D=n.length,j=w.length-D;
if(typeof n=="string"){var I=[];for(var L=0;L<D;L++)I.push(n.charCodeAt(L));n=I}if(n.length>0){var U=n[0];
for(var L=W;L<j;L++)if(w[L]==U){var M=!0;for(var m=1;m<D;m++)if(n[m]!=w[L+m]){M=!1;break}if(M)return L}}return-1};
J.a5U=function(w,n,W){var D=[],I="";while(n<W){var j=w[n++];if(j=="\\".charCodeAt(0))D.push(w[n++]);
else D.push(j)}for(var L=0;L<D.length;L+=2)I+=String.fromCharCode(D[L]<<8|D[L+1]);return I};J.a5v=function(w,n,W){var D=new Uint8Array(2);
for(var L=0;L<W.length;L++){J.ey(D,0,W.charCodeAt(L));if(D[0]==")".charCodeAt(0)||D[0]=="(".charCodeAt(0)||D[0]=="\\".charCodeAt(0)){w[n]="\\".charCodeAt(0);
n++}w[n]=D[0];n++;if(D[1]==")".charCodeAt(0)||D[1]=="(".charCodeAt(0)||D[1]=="\\".charCodeAt(0)){w[n]="\\".charCodeAt(0);
n++}w[n]=D[1];n++}return n};J.acw=function(w,n,W){w.lN(n,4*W.length);return J.a5v(w.data,n,W)};J.ND=function(w,n,W){var D="";
for(var L=0;L<W;L++){var j=w[n++]|w[n++]<<8;D+=String.fromCharCode(j)}return D};J.yL=function(w,n,W){var D="";
for(var L=0;L<W;L++){var j=w[n++]<<8|w[n++];D+=String.fromCharCode(j)}return D};J.aeT=function(w,n,W){for(var L=0;
L<W.length;L++){var D=W.charCodeAt(L);J.vP(w,n+2*L,D)}};J.azO=function(w,n,W){for(var L=0;L<W.length;
L++){var D=W.charCodeAt(L);J.ey(w,n+2*L,D)}};J.acW=function(w,n,W){w.lN(n,2*W.length);J.azO(w.data,n,W)};
J.a5m=function(w,L,n){var W=[],D=0,j=0;n+=L;while(L<n){D=w[L++];if((D&128)==0)j=D;else if((D&224)==192){j=(D&31)<<6;
D=w[L++];j|=D&63}else if((D&240)==224){j=(D&15)<<12;D=w[L++];j|=(D&63)<<6;D=w[L++];j|=D&63}else if((D&248)==240){j=(D&7)<<18;
D=w[L++];j|=(D&63)<<12;D=w[L++];j|=(D&63)<<6;D=w[L++];j|=D&63}else throw"e";W.push(j)}return W};J.agI=window.TextDecoder?new window.TextDecoder("utf8"):null;
J.KY=function(w,n,W){if(n==null)n=0;if(W==null)W=w.length;if(J.agI&&n==0&&W==w.length)return J.agI.decode(w);
var D=J.a5m(w,n,W),j=D.length;for(var L=0;L<j;L++)D[L]=String.fromCharCode(D[L]);return D.join("")};
J.aww=window.TextEncoder?new window.TextEncoder("utf8"):null;J.zY=function(w){if(J.aww)return J.aww.encode(w);
var n=new Uint8Array(w.length*4),W=J.Dj(w,n,0);return n.slice(0,W)};J.Dj=function(w,n,W){var D=w.length,L=0;
for(var j=0;j<D;j++){var I=w.charCodeAt(j);if((I&4294967295-(1<<7)+1)==0){n[W+L]=I;L++}else if((I&4294967295-(1<<11)+1)==0){n[W+L]=192|I>>6;
n[W+L+1]=128|I>>0&63;L+=2}else if((I&4294967295-(1<<16)+1)==0){n[W+L]=224|I>>12;n[W+L+1]=128|I>>6&63;
n[W+L+2]=128|I>>0&63;L+=3}else if((I&4294967295-(1<<21)+1)==0){n[W+L]=240|I>>18;n[W+L+1]=128|I>>12&63;
n[W+L+2]=128|I>>6&63;n[W+L+3]=128|I>>0&63;L+=4}else throw"e"}return L};J.to=function(w,n){var W=J.q(w,n),D=J.KY(w,n+4,W-1);
return{_6:D,EO:4+W}};J.ah_=function(w,n){var W=J.ly(w,n),D=J.ND(w,n+4,W);return D};J.Nl=function(w,n){var W=J.q(w,n),D=J.yL(w,n+4,W);
return D};J.CX=function(w,n){var W=J.q(w,n),D=J.yL(w,n+4,W-1);return D};J.amC=function(w,n,W){J.Fr(w,n,W.length);
n+=4;J.aeT(w,n,W)};J.aa6=function(w,n,W){J.Ms(w,n,W.length);n+=4;J.azO(w,n,W)};J.wk=function(w,n,W){w.lN(n,4+2*W.length);
J.aa6(w.data,n,W)};J.alM=function(w,n,W){w.lN(n,4+2*W.length);J.amC(w.data,n,W)};J.eS=function(w,n,W){var D=[];
for(var L=0;L<W;L++)D.push(String.fromCharCode(w[n+L]));return D};J.agB=function(w,n,W){var D=!1,j=w.length-W.length;
for(var L=n;L<j;L++){for(var I=0;I<W.length;I++){if(w[L+I]!=W.charCodeAt(I))break;if(I==W.length-1)return L}}};
J.sv=function(w,n,W){var D="";for(var L=0;L<W;L++)D+=String.fromCharCode(w[n+L]);return D};J.Jm=function(w,n,W){for(var L=0;
L<W.length;L++)w[n+L]=W.charCodeAt(L)};J.YY=function(w,n,W){w.lN(n,W.length);J.Jm(w.data,n,W)};J.aco=function(w,n,W){var D="";
for(var L=0;L<W;L++){var j=w[n+L];if(j<10)D+=" ";else if(j<100)D+=" ";D+=j+", "}return D};J.IQ=function(w,n){return w[n]<<8|w[n+1]};
J.ey=function(w,n,bK){w[n]=bK>>8&255;w[n+1]=bK&255};J.vo=function(w,n,bK){w.lN(n,4);J.ey(w.data,n,bK)};
J.aq0=function(w,n){var W=J.IQ(w,n),D=J.IQ(w,n+2);return W+D*(1/65536)};J.az1=function(w,n,bK){var W=Math.floor(bK),D=Math.floor((bK-W)*65536);
J.ey(w,n,W);J.ey(w,n+2,D)};J.vQ=function(w,n){return w[n+1]<<8|w[n]};J.vP=function(w,n,bK){w[n+1]=bK>>8&255;
w[n]=bK&255};J.D0=function(w,n,bK){w.lN(n,4);J.vP(w.data,n,bK)};J.zx=function(w,n){J.OX[0]=w[n+1];J.OX[1]=w[n];
return J.C8[0]};J.lm=function(w,n){J.OX[0]=w[n];J.OX[1]=w[n+1];return J.C8[0]};J.H$=J.ey;J.im=J.vo;J.W6=function(w,n){J.mf[0]=w[n+3];
J.mf[1]=w[n+2];J.mf[2]=w[n+1];J.mf[3]=w[n];return J.zz[0]};J.KW=function(w,n,bK){J.zz[0]=bK;w[n+3]=J.mf[0];
w[n+2]=J.mf[1];w[n+1]=J.mf[2];w[n+0]=J.mf[3]};J.Wr=function(w,n,bK){w.lN(n,4);J.KW(w.data,n,bK)};J.D$=function(w,n,W,D){W[D+0]=w[n+0];
W[D+1]=w[n+1];W[D+2]=w[n+2];W[D+3]=w[n+3]};J.ly=function(w,n){J.D$(w,n,J.mf,0);return J.aks[0]};J.Fr=function(w,n,bK){J.aks[0]=bK;
J.D$(J.mf,0,w,n)};J.zL=function(w,n,bK){w.lN(n,4);J.Fr(w.data,n,bK)};J.ck=function(w,n){J.D$(w,n,J.mf,0);
return J.zz[0]};J.ab9=function(w,n,bK){J.zz[0]=bK;J.D$(J.mf,0,w,n)};J.as6=function(w,n,bK){w.lN(n,4);
J.ab9(w.data,n,bK)};J.q=function(w,n){var W=w[n]*(256*256*256)+(w[n+1]<<16|w[n+2]<<8|w[n+3]);return W};
J.Ms=function(w,n,bK){w[n]=bK>>24&255;w[n+1]=bK>>16&255;w[n+2]=bK>>8&255;w[n+3]=bK>>0&255};J._Z=function(w,n,bK){w.lN(n,4);
J.Ms(w.data,n,bK)};J.gg=function(w,n){return J.q(w,n)<<32|J.q(w,n+4)};J.ayS=function(w,n,bK){J.Ms(w,n,bK>>16>>16);
J.Ms(w,n+4,bK&4294967295)};J.JH=function(w,n,bK){w.lN(n,8);J.ayS(w.data,n,bK)};J.Gb=function(w,n){var W=new Uint8Array(8);
for(var L=0;L<8;L++)W[L]=w[n+7-L];var D=new Float64Array(W.buffer);return D[0]};J.sY=function(w,n){var W=new Uint8Array(8);
for(var L=0;L<8;L++)W[L]=w[n+L];var D=new Float64Array(W.buffer);return D[0]};J.il=function(w,n,bK){var W=new Float64Array(1);
W[0]=bK;var D=new Uint8Array(W.buffer);for(var L=0;L<4;L++){var j=D[L];D[L]=D[7-L];D[7-L]=j}for(var L=0;
L<8;L++)w[n+L]=D[L]};J.gP=function(w,n,bK){w.lN(n,8);J.il(w.data,n,bK)};J.F_=function(w,n){J.mf[0]=w[n+3];
J.mf[1]=w[n+2];J.mf[2]=w[n+1];J.mf[3]=w[n+0];return J.Gv[0]};J.mg=function(w,n){J.mf[0]=w[n+0];J.mf[1]=w[n+1];
J.mf[2]=w[n+2];J.mf[3]=w[n+3];return J.Gv[0]};J.uS=function(w,n,bK){J.Gv[0]=bK;w[n+0]=J.mf[3];w[n+1]=J.mf[2];
w[n+2]=J.mf[1];w[n+3]=J.mf[0]};J.ags=function(w,n,bK){w.lN(n,4);J.uS(w.data,n,bK)};J.P5=function(w,n,bK){J.Gv[0]=bK;
w[n+0]=J.mf[0];w[n+1]=J.mf[1];w[n+2]=J.mf[2];w[n+3]=J.mf[3]};J.avG=function(w,n,bK){w.lN(n,4);J.P5(w.data,n,bK)};
J.a8m=function(w,n){var W=J.W6(w,n),D=W*(1/(1<<24));return D};J.atj=function(w,n,W){var D=Math.floor(W*(1<<24));
J.KW(w,n,D)};J.app=function(w,n,W){w.lN(n,4);J.atj(w.data,n,W)};J.$B=function(w,n){var W=w[n],D=J.sv(w,n+1,W);
W+=1-W%2;return{xi:D,length:W+1}};J.a0A=function(w,n,W){var D=W.length;w[n]=D;J.Jm(w,n+1,W);if(D%2==0){w[n+1+D]=0;
++D}return D+1};J.Tc=function(w,n,W){w.lN(n,W.length+2);return J.a0A(w.data,n,W)};J.wq=function(w,n){var W=new eh;
W.dl=J.Gb(w,n+0*8);W.k=J.Gb(w,n+1*8);W.Cj=J.Gb(w,n+2*8);W.j7=J.Gb(w,n+3*8);W.z2=J.Gb(w,n+4*8);W.EU=J.Gb(w,n+5*8);
return W};J.LN=function(w,n,W){J.il(w,n+0*8,W.dl);J.il(w,n+1*8,W.k);J.il(w,n+2*8,W.Cj);J.il(w,n+3*8,W.j7);
J.il(w,n+4*8,W.z2);J.il(w,n+5*8,W.EU)};J.auX=function(w,n,W){w.lN(n,48);J.LN(w.data,n,W)};J.axR=function(w,n){var W=J.F_(w,n),D=J.F_(w,n+4),j=J.F_(w,n+8),I=J.F_(w,n+12);
return new iB(W,D,j-W,I-D)};J.ak4=function(w,n,W){J.uS(w,n,W.x);J.uS(w,n+4,W.y);J.uS(w,n+8,W.x+W.m);
J.uS(w,n+12,W.y+W.n)};J.aug=function(w,n,W){w.lN(n,16);J.ak4(w.data,n,W)};J._I=function(w,n){var W=J.W6(w,n),D=J.W6(w,n+4),j=J.W6(w,n+8),I=J.W6(w,n+12);
return new iB(D,W,I-D,j-W)};J.aAv=function(w,n,W){J.KW(w,n,W.y);J.KW(w,n+4,W.x);J.KW(w,n+8,W.y+W.n);
J.KW(w,n+12,W.x+W.m)};J.zw=function(w,n,W){w.lN(n,16);J.aAv(w.data,n,W)};J.Xv=function(w,n,W){var D=new Uint8Array(W);
for(var L=0;L<W;L++)D[L]=w[n+L];return D};J.a8b=function(w,n,W){w.set(W,n)};J.sS=function(w,n,W){w.lN(n,W.length);
J.a8b(w.data,n,W)};J.aee=function(w,n,W,bK){if(!bK)bK=1;for(var L=0;L<bK;L++)w[n+L]=W};J.kW=function(w,n,W,bK){if(!bK)bK=1;
w.lN(n,bK);J.aee(w.data,n,W,bK)};J.C8=new Int16Array(1);J.OX=new Uint8Array(J.C8.buffer);J.zz=new Int32Array(1);
J.aks=new Uint32Array(J.zz.buffer);J.mf=new Uint8Array(J.zz.buffer);J.Gv=new Float32Array(J.zz.buffer);
function dE(){}dE.ew=function(w,n){var W=new Uint8Array(w),D=0,j=J.sv(W,D,9),M=4,m=100;D+=9;var I=J.sv(W,D,4);
D+=4;D++;n.m=J.q(W,D);D+=4;n.n=J.q(W,D);D+=4;var U=J.q(W,D);D+=4;if(U!=0)alert("Unsupported image format, not RGB!");
if(["file","v001","v002","v003"].indexOf(I)==-1){m=J.q(W,D);D+=4;if(parseInt(I.slice(1))>=7){m=m}else alert("Unknown XCF version: "+I);
M=8}var l={};D=dE.bx(W,D,l);var A=[];D=dE.mC(W,D,A,M);var g=[];D=dE.mC(W,D,g,M);n.E2=0;for(var L=0;L<A.length;
L++)dE.akf(W,A[L],n,l,M,m);while(n.E2>0){n.C.push(n.hG());n.E2--}n.C.reverse();delete n.E2;n.buffer=E.Q(n.m*n.n*4);
if(n.C.length==0)console.log("No layers!!!");for(var L=0;L<g.length;L++){var k=dE.a0I(W,g[L],l,M,m);
if(k.c7[eR.ary])n.J={channel:k.w3,rect:new iB(0,0,n.m,n.n)}}};dE.akf=function(w,n,W,D,j,I){var U=W.QI(),M=J.q(w,n),g=0;
n+=4;var m=J.q(w,n);n+=4;U.rect=new iB(0,0,M,m);var l=J.q(w,n);n+=4;var A=J.to(w,n);n+=A.EO;U.nz(A._6);
var k={};n=dE.bx(w,n,k);if(k[eR.aAr]){var $=k[eR.aAr];g=$.length/4-1}if(k[eR.yE]){U.rect.x=J.W6(k[eR.yE],0);
U.rect.y=J.W6(k[eR.yE],4)}if(k[eR.a2R]){U.opacity=J.q(k[eR.a2R],0)}if(k[eR.am2]){U.add.lsct=ef.fz;U.FK=24}if(k[eR.azn]){var C=J.q(k[eR.azn],0);
U.Bx=eR.ayC[C];if(U.ue()&&U.Bx=="norm")U.Bx="pass"}if(k[eR.ah8]){if(J.q(k[eR.ah8],0)==0)U.FK+=2}if(k[eR.afw]){var f=J.q(k[eR.afw],0);
U.add.lsct=f&1==1?ef.fz:ef.Se}if(k[eR.WT]){var z=k[eR.WT];for(var s in z){var O=z[s];if(s=="gimp-text-layer"){var a=dE.awA(O),X=a.text,P=a.font,Z=a.color,Y=a["font-size"];
if(X==null&&a.markup){var K=new DOMParser,S=K.parseFromString(a.markup,"image/svg+xml");while(S.firstChild!=null&&S.firstChild.tagName!=null){S=S.firstChild;
var G=S.getAttribute("font"),V=S.getAttribute("foreground"),T=S.getAttribute("size");if(G!=null)P=G;
if(V!=null){V=CSS.mn(V);Z=[1,V.o/255,V.B/255,V.k/255]}if(T!=null){Y=""+parseFloat(T)/245}}X=S.textContent}U.add.lnsr="rend";
U.add.TySh=hd._3(0,0);U.add.TySh.IA=new iB(0,0,100,100);U.add.TySh.D=new eh(1,0,0,1,U.rect.x,U.rect.y);
var R=U.add.TySh._o;hd.KO(R,0,X);var x=hd.tG(R,0,0),v=a.justify,N=a["line-spacing"];if(Z)x.lJ.FillColor={Type:1,Values:[1,parseFloat(Z[1]),parseFloat(Z[2]),parseFloat(Z[3])]};
if(Y){Y=Math.round(parseFloat(Y));x.lJ.FontSize=Y;U.add.TySh.D.EU+=Math.min(17,Y*.17)}if(N){N=Math.round(parseFloat(N)+x.lJ.FontSize*1.2);
x.lJ.Leading=N;x.lJ.AutoLeading=!1}if(v)x.ci.Justification=["left","right","center","fill"].indexOf(v);
if(P&&P!="Sans-serif"){var u=P.toLowerCase(),H="bold italic semi extra regular condensed light".split(" "),F=u.length;
for(var L=0;L<H.length;L++){var t=u.indexOf(H[L]);if(t!=-1&&t<F&&u[t-1]==" ")F=t}if(F!=u.length)P=P.slice(0,F-1).split(" ").join("")+"-"+P.slice(F).split(" ").join("");
hd.hI(x,P)}hd.g0(R,0,X.length,x);var o=a["box-width"],q=a["box-height"],_=o?parseFloat(o):U.rect.m,d=q?parseFloat(q):U.rect.n;
hd.VL(R,1);hd.sV(R,[0,0,Math.ceil(_),Math.ceil(d)])}else console.log("Unknown property "+s)}}while(W.E2>g){W.C.push(W.hG());
W.E2--}W.E2=g;if(U.add.lsct==ef.fz||U.add.lsct==ef.Se)W.E2++;var r=j==4?J.q:J.gg,p=r(w,n);n+=j;var Q=r(w,n);
n+=j;if(U.oK()){U.buffer=E.Q(U.rect.O()*4);var B=new E.H0(U.rect.O());dE.a9g(w,p,B,D,j,I);E.kX(B,U.buffer)}if(Q!=0){U.z=new h.ac;
var i=dE.a0I(w,Q,D,j,I);U.z.channel=i.w3;U.z.rect=U.rect.clone();if(k[eR.arG])U.z.isEnabled=J.q(k[eR.arG],0)==1;
U.z.color=U.z.channel[0];U.z.ky()}if(U.ue())U.rect=new iB;W.C.push(U)};dE.awA=function(w){var n="("+J.KY(w,0,w.length-1)+")",W=[],D={};
dE.a6M(n,1,W);dE.aiI(W,D);return D};dE.aiI=function(w,n){for(var L=0;L<w.length;L++){var W=w[L],D=W[0];
if(W.length==2)n[D]=W[1];else n[D]=W.slice(1)}};dE.a6M=function(w,n,W){while(!0){if(n>=w.length)throw"e";
var D=w.charAt(n);n++;if(D=="("){var j=[];n=dE.a6M(w,n,j);W.push(j)}else if(D==" "||D=="\n"||D=="\r"){}else if(D==")")return n;
else if(D=="\""){var I=n;while(!0){var U=w[n];n++;if(U=="\"")break;if(U=="\\")n++}W.push(JSON.parse(w.slice(I-1,n)))}else{var I=n-1;
while(w[n]!=" "&&w[n]!=")")n++;W.push(w.slice(I,n))}}};dE.a0I=function(w,n,W,D,j){var I=J.q(w,n);n+=4;
var U=J.q(w,n);n+=4;var M=J.to(w,n);n+=M.EO;var m={};n=dE.bx(w,n,m);var l=new E.H0(I*U),A=D==4?J.q:J.gg,g=A(w,n);
n+=D;dE.a9g(w,g,l,W,D,j);return{w3:l.o,c7:m}};dE.a9g=function(w,n,W,D,j,I){var U=J.q(w,n);n+=4;var M=J.q(w,n);
n+=4;var m=J.q(w,n);n+=4;var l=j==4?J.q:J.gg,A=l(w,n);n+=j;dE.azF(w,A,W,D,m,j,I)};dE.azF=function(w,n,W,D,j,I,U){var M=J.q(w,n),A=0,L=0;
n+=4;var m=J.q(w,n);n+=4;var l=new iB(0,0,M,m);if(U==100||U==150)A=1;else if(U==200||U==250)A=2;else if(U==300||U==350)A=4;
else if(U==500||U==550)A=2;else if(U==600||U==650)A=4;else if(U==700||U==750)A=8;else{alert("unsupported bit depth "+U);
throw"e"}var g=j/A,A=Math.round(j/g),k=[];n=dE.mC(w,n,k,I);var $=new E.H0(64*64*A),C=new iB,f=D[eR.aAK][0],z=[$.o,$.B,$.k,$.dl];
if(g==3)$.dl.fill(255);var s=Date.now();if(k.length!=0)for(var O=0;O<m;O+=64)for(var a=0;a<M;a+=64){var X=Math.min(M-a,64),P=Math.min(m-O,64),Z=X*P;
C.y1(a,O,X,P);dE.al3(w,k[L++],Z*A,f,g,z);if(U==100||U==150){}else if(U==250){for(var Y=0;Y<g;Y++){var K=z[Y];
for(var S=0;S<Z;S++){var G=K[S]<<8|K[Z+S];K[S]=Math.min(G>>>8,255)}}}else if(U==600){var V=dE.a1$(),T=new Uint32Array(1),R=new Float32Array(T.buffer);
for(var Y=0;Y<g;Y++){var K=z[Y];for(var S=0;S<Z;S++){T[0]=K[S]<<24|K[Z+S]<<16|K[(Z<<1)+S]<<8|K[(Z<<1)+Z+S]<<0;
var x=R[0];if(x<0)x=0;else if(x>1)x=1;K[S]=V[~~(.5+x*1e3)]}}}else console.log("unknown data format",U);
E.Jx($,C,W,l)}};dE.a1$=function(){var w=dE.a8C;if(w!=null)return w;w=dE.a8C=new Uint8Array(1001);for(var L=0;
L<1001;L++)w[L]=~~(.49+255*E.ae(L*.001));return w};dE.al3=function(w,n,W,D,j,I){if(D==1){for(var U=0;
U<j;U++){var M=I[U],m=0;while(m<W){var bK=w[n];n++;if(bK<127){var l=w[n];n++;bK++;for(var L=0;L<bK;L++)M[m+L]=l}else if(bK==127){var A=w[n];
n++;var g=w[n];n++;var l=w[n];n++;bK=A<<8|g;for(var L=0;L<bK;L++)M[m+L]=l}else if(bK==128){var A=w[n];
n++;var g=w[n];n++;bK=A<<8|g;for(var L=0;L<bK;L++)M[m+L]=w[n+L];n+=bK}else{bK=256-bK;for(var L=0;L<bK;
L++)M[m+L]=w[n+L];n+=bK}m+=bK}}}else if(D==2){var k=pako.inflate(w.slice(n)),$=Math.round(k.length/W);
for(var L=0;L<W;L++){var C=L*$;I[0][L]=k[C];I[1][L]=k[C+1];I[2][L]=k[C+2];I[3][L]=$==3?255:k[C+3]}}else alert("Unknown compression "+D)};
dE.mC=function(w,n,W,D){var j=D==4?J.q:J.gg;while(!0){var I=j(w,n);n+=D;if(I==0)break;else W.push(I)}return n};
dE.bx=function(w,n,W){while(!0){var D=J.q(w,n);n+=4;var j=J.q(w,n);n+=4;if(D==eR.asm)break;else if(D==eR.WT)W[D]=dE.aqr(w,n,n+j);
else W[D]=J.Xv(w,n,j);n+=j}return n};dE.aqr=function(w,n,W){var D={};while(n<W){var j=J.to(w,n);n+=j.EO;
var I=J.q(w,n);n+=4;if(I!=1)console.log("unknown flags",I);var U=J.q(w,n);n+=4;D[j._6]=J.Xv(w,n,U);n+=U}return D};
var eR={asm:0,afs:1,afi:2,aeW:3,ary:4,aed:5,a2R:6,azn:7,ah8:8,a44:9,adb:10,arG:11,ahA:12,a91:13,au0:14,yE:15,aiB:16,aAK:17,awM:18,a7P:19,amF:20,WT:21,a5C:22,aA4:23,acG:24,a6u:25,avA:26,aAj:27,ain:28,am2:29,aAr:30,afw:31,a5G:32,aaQ:33,a2v:34,a39:35,ahi:36,aqS:37,akD:38,ah4:0,ajq:1,alV:2,apy:3,acb:1,ajt:2,ae7:0,afW:1,ahm:1};
eR.ayC="norm,diss,norm,mul ,scrn,over,diff,lddg,fsub,dark,lite,hue ,sat ,colr,lum ,fdiv,lddg,idiv,hLit,sLit,fdiv,pLit,norm,over,hue ,hue ,colr,lite,norm,norm,mul ,scrn,diff,lddg,fsub,dark,lite,hue ,sat ,colr,lum ,fdiv,lddg,idiv,hLit,sLit,fdiv,pLit,vLit,pLit,lLit,hMix,smud,lbrn,lum ,lum ,lum ,lum ,norm,norm,norm,pass".split(",");
var gF=function(){var w=!1,n,W,s=0,X;function D(){var Y=J.sv(n,W,4);W+=4;return Y[3]+Y[2]+Y[1]+Y[0]}function j(){var Y=J.sv(n,W,4);
W+=4;return Y}function I(){var Y=n[W];W+=1;return Y}function U(){var Y=J.vQ(n,W);W+=2;return Y}function M(){var Y=J.ly(n,W);
W+=4;return Y}function m(){var Y=J.ck(n,W);W+=4;return Y}function l(){var Y=J.ly(n,W);W+=8;return Y}function A(){var Y=J.mg(n,W);
W+=4;return Y}function g(){var Y=J.sY(n,W);W+=8;return Y}function k(){var Y=J.vQ(n,W),K=J.KY(n,W+2,Y);
W+=2+Y;return K}function $(){var Y=J.ly(n,W),K=J.KY(n,W+4,Y);W+=4+Y;return K}function C(Y){W=Y;var K=[];
while(W!=0){var S=j();if(S!="#FT4"&&S!="#FT3"&&S!="#FT2")throw S;var G=l(),V=l(),T=l(),R=l(),x=l(),v=M(),N=M(),u=M(),H=U(),F=I(),t={};
K.push(t);for(var L=0;L<v;L++){var o=M(),q=I();if(q!=0&&q!=1&&q!=2)throw q;var _=[];if(q==0||q==1){var d=l(),r=l(),p=l(),Q=M(),B=I(),i=M(),c=S!="#FT4"?0:M(),h2=null;
if(S=="#FAT"||S=="#FT2"){switch(B){case 1:B=1;break;case 2:B=65;break;case 3:B=129;break;case 4:B=193;
break;default:B=0;break}}if(q==0)h2=k();_=[d,r,p,B,h2]}t["i"+o]=[q,_]}for(var L=0;L<H;L++){var jX=U(),bm=U(),dC=l(),fn=J.sv(n,W,jX);
W+=jX}W=G}K.reverse();for(var fK=1;fK<K.length;fK++){var t=K[fK],i6=K[fK]=JSON.parse(JSON.stringify(K[fK-1]));
for(var dh in t){var kA=t[dh];if(kA[0]==0)i6[dh]=kA;else if(kA[0]==1){kA[1][4]=i6[dh][1][4];i6[dh]=kA}else if(kA[0]==2)delete i6[dh]}}var ig=K.pop(),iJ=[];
for(var dh in ig)iJ.push(ig[dh][1]);iJ.sort(function(fL,fB){return fL[0]-fB[0]});return iJ}function f(Y,K,S,G){while(W<n.length){var V=I(),v=null;
if(V==0){if(G){var T=I();if(T!=2){var R=D()}if(T==0)W+=4;G=!1;continue}else{break}}var x=D();if(w)console.log(" ".repeat(K),V,V&127,x,Y._type);
if(V>127)v=z(V,K,S);else v=O(V,K,S);if(w)console.log(" ".repeat(K),v);Y[x]=v}}function z(Y,K,S){var G=[];
Y=Y&127;if(Y==43)W+=4;var V=M();if(Y==50){var T=D(),R=U();if(R!=1)throw"e";for(var L=0;L<V;L++){var x={_status:"NotShared",_type:T};
G.push(x);var v=I();if(v!=1)throw v;f(x,K+1,S)}}else if(Y==41){if(V>8)throw V;for(var L=0;L<V;L++)G.push((n[W]>>>L&1)==1);
W++}else for(var L=0;L<V;L++){G.push(O(Y,K,S,L!=0));if(Y==42)Y=2}return G}function O(Y,K,S,G){var V=null;
if(Y==49){V={};var T=I();if(T!=0){var R=M();if(S==null){V._id=R;V._status=["Shared","Link"][T-1]}if(S&&T==2)V=S[R];
if(T==1){if(S)S[R]=V;var x=I(),v=!1;if(x>1)throw x;V._type=D();if(w)console.log(" ".repeat(K),"new",V._type,x,W);
if(x==0){while(!0){var N=U();if(N!=0&&N!=1&&N!=2&&N!=4)throw N;if(n[W]!=0){v=!0;break}var u=U();if(u==512)break;
var H=D();if(u==256)break}}f(V,K+1,S,v)}}}else if(Y==50){V={_status:"NotShared"};if(I()==1){V._type=D();
W+=2;f(V,K+1,S)}}else if(Y==1)V={type:"byte",value:I()};else if(Y==2)V={type:"uint16",value:U()};else if(Y==3)V={type:"uint32",value:M()};
else if(Y==4)V={type:"uint64",value:l()};else if(Y==7)V={type:"int32",value:m()};else if(Y==8)V={type:"int64",value:l()};
else if(Y==9)V={type:"float32",value:A()};else if(Y==10)V={type:"float64",value:g()};else if(Y==21)V={type:"Vec2i",value:[M(),M()]};
else if(Y==23)V={type:"Vec4i",value:[M(),M(),M(),M()]};else if(Y==33)V={type:"Vec4f",value:[A(),A(),A(),A()]};
else if(Y==36)V={type:"Vec2",value:[g(),g()]};else if(Y==38)V={type:"Vec4",value:[g(),g(),g(),g()]};
else if(Y==40)V={type:"Vec6",value:[g(),g(),g(),g(),g(),g()]};else if(Y==41)V={type:"bool",value:I()!=0};
else if(Y==42)V={type:"Enum",value:M()};else if(Y==43)V={type:"string",value:$()};else if(Y==44){if(G!=!0)s=U();
V={type:"curv16",value:[g(),s==12?[I(),I(),I(),I()]:[M(),M()]]}}else if(Y==45){var F=M();V={type:"buff",value:n.slice(W,W+F)};
W+=F}else if(Y==47){V={type:"uint32",value:M()}}else if(Y==48){var t=[],o=U();if(o!=1)throw o;while(!0){if(n[W]==135){var q=z(I(),K+1,S),_=z(I(),K+1,S),d=z(I(),K+1,S);
t.push([q,_,d])}else{var r=1;if(n[W]==3){I();r=M()}for(var L=0;L<r;L++){if(I()!=41)throw"e";var R=I();
if(R!=0&&R!=1)throw R;if(I()!=172)throw"e";var p=M(),Q=U(),B=[];t.push(B);if(Q!=18)throw Q;if(p>2e3)throw p;
for(var i=0;i<p;i++)B.push([g(),g(),I(),I()])}}if(n[W]==0){W++;break}}V={type:"curve",value:t}}else if(Y==51){V={type:"EmbeddedData"};
V[D()]=$()}else if(Y==52)V={type:"uint32",value:M()};else if(Y==56)V={type:"Color32",value:[I(),I(),I(),I()]};
else if(Y==60)V={type:"ColorGRAY",value:[A(),A()]};else if(Y==68)V={type:"ColorRGBA",value:[A(),A(),A(),A()]};
else if(Y==72)V={type:"ColorCMYK",value:[A(),A(),A(),A(),A()]};else{throw Y}return Y==49||Y==50||Y==51?V:V.value}function a(Y){var K=0,S=Y.length;
for(var L=0;L<S;L++)Y[L]=K=K+Y[L]&255}function P(Y){n=Y;W=4;var K=M(),S=j();if(S!="nsrP")throw S;var S=j();
if(S!="#Inf")throw S;var G=l();X=l();var V=l(),T=l(),R=l(),x=M(),v=M(),S=j();if(S!="Prot")throw S;var x=M(),N=C(G),u={},H=Date.now();
for(var F=0;F<N.length;F++){var t=N[F],o=t[3],p=null;W=t[0];var S=j();if(S!="#Fil")throw S;var q=o>>>5&1,_=o&3,d=o&192;
switch(d){case 64:d=1;q=0;break;case 128:d=2;break;case 192:d=3;break;default:d=0;q=0}var r=new Uint8Array(n.buffer,W,t[2]);
if(_==0)p=r;else if(_==1)p=pako.inflate(r);else if(_==2)p=jj.xz.Ue(r,t[1]);else throw _;if(q==0){if(d==1)a(p);
if(d==2)throw"e"}else throw q;u[t[4]]=p}return u}function Z(Y){var K=P(new Uint8Array(Y));n=K["doc.dat"];
W=16;var S={};f(S,0,[]);return[K,S,X]}return{apd:Z}}();function ci(){}ci.ew=function(){function w($,C){var f=Date.now(),z=gF.apd($),s=z[0],O=z[1],a=z[2],X=O.DocR,P=X.DfSz,Z=X.Chld;
if(Z.length!=1)throw"e";var Y=Z[0],K=Y.SprB;Z=Y.Chld;C.m=~~K[2];C.n=~~K[3];C.buffer=E.Q(C.m*C.n*4);var S=[0,{}];
for(var L=0;L<Z.length;L++)j(Z[L],C,s,new eh,S,0);C.om(S[0]);console.log(Date.now()-f,"Document created");
f=Date.now()}function n($){return new eh($[0],$[3],$[1],$[4],$[2],$[5])}function W($,C){var f=C.Xfrm;
f=f?n(f):new eh;f.concat($);return f}function D($){var C={0:"norm",1:"dark",2:"mul ",3:"idiv",196613:"lbrn",65538:"dkCl",4:"lite",5:"scrn",6:"div ",7:"lddg",65542:"lgCl",8:"over",9:"sLit",10:"hLit",11:"vLit",65551:"lLit",12:"pLit",13:"hMix",14:"diff",15:"smud",16:"fsub",262165:"fdiv",17:"hue ",18:"sat ",20:"colr",19:"lum "}[$];
return C?C:"norm"}function j($,C,f,z,s,O){var a=$._type,X=$.Chld,P=C.QI();P.nz($.Desc==null||$.Desc==""?a=="Grup"?"Folder":"Layer":$.Desc);
P.gb($.Visi);P.opacity=Math.round(255*$.Opac);if($.FOpc!=1)P.add.iOpa=Math.round(255*$.FOpc);var Z=$.Blnd;
if(Z!=null)P.Bx=D(Z);var Y=W(z,$),K=a=="ShpN"||a=="PCrv";if(X){C.C.push(C.hG());P.add.lsct=ef.fz;P.Bx="pass";
P.FK=24;if(a=="ShpN"){var S=$.ShpB;P.MR(new iB(S[0]+Y.z2,S[1]+Y.EU,S[2]-S[0],S[3]-S[1]));s[0]++;P.add.artb.Clr={t:"Objc",v:E.M.lW({o:255,B:255,k:255})}}for(var L=0;
L<X.length;L++)j(X[L],C,f,Y,s,O+1)}else if(a=="Rstr"||a=="ImgN"||a=="MRst"){var G=$.Bitm,V=G.Bckg,T=Date.now(),R;
if(V==null){R=l(G,f,s[1]);P.rect=R[2].clone();P.buffer=R[1].slice(0);P.rect.x+=Y.z2;P.rect.y+=Y.EU}if(V||Y.NW()!=1){var x,v=0,N=0;
if(V){var u=f[V.Data],H=J.TN(u,"ataD")+4,F=J.ly(u,H);H+=4;x=u.slice(H,H+F)}else{v=P.rect.x-Y.z2;N=P.rect.y-Y.EU;
if(R[3]==null)R[3]=new Uint8Array(jj.ZO("PNG").La([[P.buffer.buffer]],P.rect.m,P.rect.n));x=R[3].slice(0)}var t=C.An(x,P.getName(),0,0);
t.FK=P.FK;t.opacity=P.opacity;P=t;var o=new eh;o.translate(v,N);o.concat(Y);var q=P.rect.clone();q.x=q.y=0;
var _=E.p.Wx(q).w;E.p.D(_,o,_);P.add.SoLd.Trnf=y.wR.Hh(_);P.add.SoLd.nonAffineTransform=y.wR.Hh(_);P.vr(C,!1)}}else if(a=="TxtA"||a=="TxtF"){P.add.lnsr="rend";
P.add.TySh=hd._3(0,0);P.add.TySh.IA=new iB(0,0,100,100);var d=$.TxtH.FrmB,r=new eh,i=0;r.translate(d[0],d[1]);
r.concat(Y);P.add.TySh.D=r;var p=P.add.TySh._o,Q=$.StSt,B=Q.Blok;if(B.length!=1)throw"e";for(var c=0;
c<B.length;c++){var h2=B[c],jX=i,bm=0,dC=h2.Glyp.Utf8;dC=dC.replace(/\u2028/g,"\n");dC=dC.replace(/\u2029/g,"\n");
dC=dC.slice(0,dC.length-1);if(dC=="")continue;hd.KO(p,i,dC);i+=dC.length;var fn=h2.GAtt.Runs,fK=h2.PAtt.Runs[0],i6=fK.Item.Ints[0];
for(var dh=0;dh<fn.length;dh++){var kA=fn[dh],ig=kA.Indx,iJ=kA.Item,fL=iJ.Objs,fB=hd.tG(p,jX,1);fB.ci.Justification=i6==0?0:i6==1?2:1;
hd.hI(fB,iJ.DFnt.Post);fB.lJ.FontSize=iJ.Doub[0];for(var L=0;L<fL.length;L++){var ah=fL[L];if(ah._type=="FDsc"){var eS=ah.FDeF;
if(eS._type=="FilS"){var gL=m(eS.Colr);fB.lJ.FillColor={Type:1,Values:[1,gL[0],gL[1],gL[2]]}}}}hd.g0(p,jX+bm,jX+Math.min(ig,dC.length),fB);
bm=ig}}hd.VL(p,1);hd.sV(p,[0,0,Math.round(d[2]-d[0]),Math.round((d[3]-d[1])*1.2)]);C.XW=!0}else if(K){P.FK|=16;
var e_=P.add.vstk=JSON.parse(JSON.stringify(at.QO.default));e_.strokeEnabled.v=!1;var c2=P.add.vmsk=I($);
E.P.c0(c2.i,Y);if($.BFFl){var jS=$.BFFl[0].FDeF,ie=jS._type;if(ie=="FilS")P.add.SoCo={classID:"null",Clr:M(jS.Colr)};
else if(ie=="FilG"){var as=P.add.GdFl=JSON.parse(at.UR[at.order.indexOf("GrFl")]);U(jS,as)}else if(ie=="FilN"){P.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}};
e_.fillEnabled.v=!1}else console.log(ie)}if($.LILn){var gb=$.LILn[0].LDeL,gx=gb.Wght;if(gx!=0){e_.strokeEnabled.v=!0;
e_.strokeStyleLineWidth.v.val=gx;var jS=$.LIFl[0].FDeF,ie=jS._type;if(ie=="FilS")e_.strokeStyleContent.v.Clr=M(jS.Colr);
else if(ie=="FilN")e_.strokeEnabled.v=!1}}P.hu();P.yb(C)}else console.log(a);var eo=$.AdCh,di=[];if(eo)for(var L=0;
L<eo.length;L++){var d0=eo[L],e6=d0._type;if(e6=="ShpN"||e6=="PCrv"){var c2=P.add.vmsk=I(d0),dt=W(Y,d0);
E.P.c0(c2.i,dt);P.hu();P.yb(C)}else if(d0.AdjP){var gJ=d0.AdjP,iW=gJ._type,g5={LevP:"levl",WhBP:"levl",SHiP:"curv",HSSP:"hue2",RecP:"hue2","B&WP":"blwh","B&CP":"brit",PosP:"post",VibP:"vibA",ExpP:"expA",ThrP:"thrs",CrvP:"curv"}[iW];
if(g5==null){console.log(gJ);continue}var eP=cx.gt(g5,{});di.push(eP);var b_=eP.v.Fltr.v;if(iW=="LevP"){var fZ=il.Qw(b_,0);
fZ[0]=gJ.OutB*255;fZ[1]=gJ.OutW*255;il.nr(b_,0,fZ)}else if(iW=="WhBP"){var fZ=il.Qw(b_,2);fZ[4]=100+gJ.WBTi*20;
il.nr(b_,2,fZ);var fZ=il.Qw(b_,3);fZ[4]=100+gJ.WBTi*200;il.nr(b_,3,fZ)}else if(iW=="HSSP"){var fZ=cT.Qw(b_,0);
fZ[0]=Math.round(gJ.HueA*256);fZ[1]=Math.round(gJ.SatA*256);fZ[2]=Math.round(gJ.LumA*256);cT.nr(b_,0,fZ)}else if(iW=="RecP"){b_.Clrz.v=!0;
var fZ=cT.Qw(b_,0);fZ[0]=Math.round(gJ.RecH*100);fZ[1]=Math.round(gJ.RecS*100);fZ[2]=Math.round(gJ.RecL*100);
cT.nr(b_,0,fZ)}else if(iW=="B&CP"){b_.Brgh.v=Math.round(gJ.Brig*100);b_.Cntr.v=Math.round(gJ.Ctrs*100-100)}else if(iW=="PosP"){b_.Lvls.v=gJ.Post}else if(iW=="VibP"){b_.vibrance.v=gJ.Vibr-100;
b_.Strt.v=Math.round(gJ.Satu*100)}else if(iW=="ExpP"){b_.Exps.v=gJ.Expo;b_.gammaCorrection.v=gJ.Gamm/2.2}else if(iW=="ThrP"){b_.Lvl.v=Math.round(gJ.Thre*255)}else if(iW=="CrvP"){var im=gJ.Mast["Cnt "],j3=gJ.Mast.Vals,fZ=e0.Qw(b_,0),dr=fZ[0];
for(var c0=0;c0<im;c0++){var fM=fZ[c0]=JSON.parse(JSON.stringify(dr));fM.v.Hrzn.v=Math.round(j3[c0]*255);
fM.v.Vrtc.v=Math.round(j3[4+c0]*255)}e0.nr(b_,0,fZ)}}else console.log(d0)}if(di.length!=0&&P.add.SoLd){P.add.SoLd.filterFX=cx.Gq();
C.V$({id:P.add.SoLd.placed.v,rect:new iB,buffer:E.Q(1),z:new h.ac});P.add.SoLd.filterFX.v.filterFXList.v=di;
P.vr(C,!1)}var cB=$.FiEf;if(cB&&cB.length!=0){var iI=P.add.lmfx=JSON.parse(at.default);for(var L=0;L<at.order.length;
L++)iI[at.Pa[L]]={t:"VlLs",v:[]};for(var jD=0;jD<cB.length;jD++){var j8=cB[jD],jG=j8._type,i1={ColO:"SoFi",GrdO:"GrFl",Shad:"DrSh",InnS:"IrSh",OutG:"OrGl",InnG:"IrGl",Strk:"FrFX",PhgB:"ebbl",BevE:"ebbl"}[jG],as=i1?JSON.parse(at.UR[at.order.indexOf(i1)]):null;
if(jG=="ColO"){as.Clr=M(j8.Colr)}else if(jG=="GrdO"){U(j8.GrFl.FDeF,as)}else if(jG=="Shad"||jG=="InnS"||jG=="OutG"||jG=="InnG"){as.Clr=M(j8.Colr);
as.blur.v.val=Math.round(j8.Radi/2.4);if(j8.Offs!=null){as.Dstn.v.val=j8.Offs;as.lagl.v.val=Math.round(180-j8.Angl*180/Math.PI);
as.uglg.v=!1}}else if(jG=="Strk"){as.Clr=M(j8.Colr);as.Sz.v.val=Math.round(j8.Radi)}else if(jG=="PhgB"||jG=="BevE"){as.blur.v.val=Math.round(j8.Radi);
if(jG=="BevE")as.bvlS.v.BESl="PlEb"}else if(jG=="Gaus"){if(K&&j8.Enab){P.add.vmsk.C3=j8.Radi/2.4;P.add.vmsk.eP=!0;
P.hu();P.yb(C)}}if(i1){as.enab.v=j8.Enab;if(as.Md&&j8.BlnM!=null)as.Md.v.BlnM=dD.Eu(D(j8.BlnM));if(as.Opct&&j8.Opac!=null)as.Opct.v.val=Math.round(j8.Opac*100);
var bH=at.Pa[at.order.indexOf(i1)];iI[bH].v.unshift({t:"Objc",v:as})}}}C.C.push(P)}function I($){var C=new h.Rd,f=$._type;
if(f=="PCrv"){var z=$.Crvs.Data,s=[],O=[];for(var L=0;L<z.length;L++){var a=z[L],X=a.length%3;if(X!=1){a=X==2?a[0][2]!=0?a.slice(0,a.length-1):a.slice(1):a.slice(1,a.length-1)}for(var P=0;
P<a.length;P++){var Z=a[P],Y=Z[2];if(Y!=0)s.push(P==0?"M":"C");O.push(Z[0],Z[1])}}C.i=E.p.oF({w:O,F:s},!0)}else{var K=$.ShpB,S=$.Shpe,G=S._type,V=K[2]-K[0];
if(G=="ShpE"){C.i=E.P.AB.Po(K[0],K[1],K[2]-K[0],K[3]-K[1])}else if(G=="ShNR"){var T=[0,0,0,0];if(S.CTyp){T=S.ShCR.slice(0);
for(var L=0;L<4;L++)T[L]*=K[2]-K[0]}C.i=E.P.AB.Rect(K[0],K[1],K[2]-K[0],K[3]-K[1],T)}else if(G=="ShpT"){C.i=E.p.oF({F:["M","L","L","Z"],w:[K[0],K[3],K[2],K[3],K[0]+V*.5,K[1]]},!0)}else if(G=="ShTz"){C.i=E.p.oF({F:["M","L","L","L","Z"],w:[K[0]+V*S.PosL,K[1],K[0]+V*S.PosR,K[1],K[2],K[3],K[0],K[3]]},!0)}else{console.log("--",G);
C.i=E.P.AB.Rect(K[0],K[1],K[2]-K[0],K[3]-K[1],[0,0,0,0])}}return C}function U($,C){var f=$.Grad,z=f.Cols;
C.Type.v.GrdT=$.Type==0?"Lnr":"Rdl";var s=[];for(var L=0;L<z.length;L++){var O=m(z[L]);s.push([f.Posn[L][0],O])}C.Grad.v.Intr.v=0;
E.M.WP(s,C.Grad.v);var a=f.Posn,X=new ec(a[0][0],a[0][1]),P=new ec(a[1][0],a[1][1]);if($.Type==0)X=new ec((X.x+P.x)/2,(X.y+P.y)/2);
E.M.n0(X,P,new iB(0,0,1,1),C)}function M($){var C=m($);return{t:"Objc",v:E.M.lW({o:C[0]*255,B:C[1]*255,k:C[2]*255})}}function m($){var C=$._col,f=$._type;
if(f=="HSLA"){var z=E.P4(C[0],C[1],C[2]);return[z.o,z.B,z.k,C[3]]}else if(f=="RGBA")return C;else if(f=="CMYK"){var s=1-C[3];
return[(1-C[0])*s,(1-C[1])*s,(1-C[2])*s]}else if(f=="GRAY")return[C[0],C[1],C[2]];else{console.log(C);
throw f}}function l($,C,f){var z=$.Frmt,V="";if(z!=0&&z!=4&&z!=6)throw z;var s=$.BmpW,O=$.BmpH,a=z==4?5:z==0?4:1,X=Math.ceil(s/256),P=Math.ceil(O/256),Z=new iB(0,0,X,P),Y=new iB;
for(var L=0;L<a;L++){var K=new Uint8Array($["Sta"+(L+1)]),S=E.Nb(K,Z);Y=Y.x0(S)}var G=[];for(var L=0;
L<a;L++){var K=new Uint8Array($["Sta"+(L+1)]),T=E.Q(Y.O());E.B0(K,Z,T,Y);G[L]=[];for(var R=0;R<T.length;
R++)G[L][R]=T[R];V+=JSON.stringify(G[L])+","+JSON.stringify($["Idx"+(L+1)])+","}if(f[V]==null){var x=Y.m*256,v=Y.n*256,N=new Array(a);
for(var L=0;L<a;L++){var K=N[L]=new Uint8Array(x*v);A(K,$["Idx"+(L+1)],G[L],C,x,v)}var u=E.Q(x*v*4);
if(z==0)E.kX({o:N[0],B:N[1],k:N[2],dl:N[3]},u);else if(z==4){for(var L=0;L<N[0].length;L++){var H=L*4,F=N[0][L]*(1/255),t=N[1][L]*(1/255),o=N[2][L]*(1/255),q=N[3][L]*(1/255),_=UDOC.C.cmykToRgb([F,t,o,q]);
u[H]=_[0]*255;u[H+1]=_[1]*255;u[H+2]=_[2]*255;u[H+3]=N[4][L]}}else{u.fill(255);E.Mj(N[0],u)}var d=new iB(0,0,x,v),r={buffer:u,rect:d};
E.qS(r);f[V]=[r.rect,r.buffer]}var S=f[V][2]=f[V][0].clone();S.x+=Y.x*256;S.y+=Y.y*256;return f[V]}function A($,C,f,z,s,O){var a=0,X=s>>>8,P=O>>>8;
for(var Z=0;Z<P;Z++)for(var Y=0;Y<X;Y++){var K=Y*256,S=Z*256,G=Z*X+Y,V=S*s+K,T=f[G];if(T<=1)g($,V,0,s,256,256);
else if(T==2)g($,V,4294967295,s,256,256);else if(T==4){var R=C[a];a++;var x=z[R.Data.DatI],v=R.Rect;
if(v==null)v=[0,0,256,256];g($,V,0,s,256,256);k($,(S+v[1])*s+K+v[0],x,v[1]*256+v[0],s,256,v[2]-v[0],v[3]-v[1])}else console.log(T)}}function g($,C,f,z,s,O){var a=C+z*O;
for(;C<a;C+=z){var X=C+s;for(var P=C;P<X;P++){$[P]=f}}}function k($,C,f,z,s,O,a,X){var P=C+s*X,Z=z+O*X;
for(;C<P&&z<Z;C+=s,z+=O){for(var L=0;L<a;L++)$[C+L]=f[z+L]}}return w}();function bW(){}bW.ew=function(w,n){var W=bW,D=ag.parse(w),I=0;
if(D.pages.length>1)console.log(D.pages.length,"pages");var j=[],U=new iB;for(var M=0;M<D.pages.length;
M++){var m=D.pages[M],l=m.layers,A=W.mY(l,M),k=!1;if(A.O()>8e3*8e3||A.m>3e4||A.n>3e4){W.awi(l,!0);var g=W.mY(l,M);
if(g.O()>=A.O())W.awi(l,!1)}A=W.mY(l,M);for(var $=0;$<l.length;$++){var C=l[$];if(W.lg(C)=="artboard")k=!0}if(!k){console.log("no artboard");
var f={};for(var z in m)f[z]=m[z];f._class="group";m.layers=[f]}j.push(A.clone());if(A.VY())continue;
A.x=0;A.y=I;I+=A.n+200;U=U.x0(A)}var s={};if(D.foreignSymbols)for(var L=0;L<D.foreignSymbols.length;
L++){var O=D.foreignSymbols[L].symbolMaster;s[O.symbolID]={o3:O}}W.asa(D.pages,s,n);for(var a in s){var C=s[a].o3,X=W.axa(C.layers)}var P=bW.CI(U,8192*8192);
n.XW=!0;n.m=Math.round(U.m/P);n.n=Math.round(U.n/P);n.buffer=E.Q(n.m*n.n*4);n.om(D.pages[0].layers.length);
n.Jw={};n.CU=[];I=0;for(var M=0;M<D.pages.length;M++){var Z=D.pages[M],A=j[M],Y=new eh(P,0,0,P,A.x,A.y-I);
W.Fi(Z.layers,n,Y,D,s,{},[]);I+=A.n+200}delete n.Jw;delete n.CU;if(P!=1)alert("File scaled down "+P+"x");
n.alY()};bW.akO=0;bW.lg=function(w){return w._class?w._class:w.$class};bW.CI=function(w,n){var W=1;while(Math.round(w.m/W)*Math.round(w.n/W)>n||Math.max(Math.round(w.m/W),Math.round(w.n/W))>3e4)W++;
if(W!=1&&!window.confirm("Your image is quite large ("+w.m+" x "+w.n+" px).\n"+"Press OK to scale it down "+W+"x, or Cancel to keep the size."))W=1;
return W};bW.mY=function(w,n){var W=[],D=bW;for(var j=0;j<w.length;j++){var I=w[j],U=D._I(I.frame);if(n==0||D.lg(I)=="artboard")W.push(U)}return E.rect.vx(W)};
bW.awi=function(w,n){var W=[],D=bW;for(var j=0;j<w.length;j++){var I=w[j],U=D._I(I.frame);U.m+=150;U.n+=150;
W.push(U)}var M=E.rect.vx(W);E.rect.aum(W,n);var m=E.rect.vx(W);if(m.O()*1.5<M.O()||M.m>3e4&&m.m<=3e4||M.n>3e4&&m.n<=3e4){alert("Re-arranging artboards");
for(var j=0;j<w.length;j++){var l=W[j],I=w[j],A=I.frame;A.x=l.x;A.y=l.y}}};bW.asa=function(w,n,W){var D=bW;
for(var j=0;j<w.length;j++){var I=w[j],U=D.lg(I);if(["page","artboard","group"].indexOf(U)!=-1)D.asa(I.layers,n,W);
else if(U=="symbolMaster")n[I.symbolID]={o3:I}}};bW.axa=function(w){var n=bW;for(var W=0;W<w.length;
W++){var D=w[W],j=n.lg(D),I=null;if(["page","artboard","group"].indexOf(j)!=-1)I=n.axa(D.layers);if(j=="symbolMaster"||j=="symbolInstance")I=D;
if(I!=null)return I}return null};bW.Fi=function(w,n,W,D,j,I,U){var M=bW,m=[];for(var l=0;l<w.length;
l++){var A=w[l],g=A.frame?M._I(A.frame):null,k=A.style,s="",Y=null,K=!1;if(k==null){console.log("no styles")}var $=M.af1(A,W),C=M.lg(A),f=C=="shapeGroup"||C=="shapePath"||C=="rectangle"||C=="oval"||C=="triangle"||C=="polygon",z=["page","artboard","group"].indexOf(C)!=-1;
if(C=="shapeGroup"){for(var L=0;L<A.layers.length;L++)if(M.lg(A.layers[L])=="shapeGroup")z=!0}var O=A.exportOptions;
if(O){var a=O.exportFormats;if(a==null)a=O.sizes;if(C!="artboard"&&(a&&a.length!=0)){var X=a[0].scale}}var P=n.QI();
P.gb(A.isVisible);var Z=A.name;if(!(typeof Z=="string"))Z=C;P.nz(s+Z.slice(0,250));if(k!=null)Y=M.aiv(D,n,k,g,$,P.getName(),f||C=="artboard"||z);
if(C=="rectangle"&&k&&k.fills&&k.fills[0]){var S=k.fills[0];if(S.fillType==4&&S.patternFillType>1&&S.image!=null)K=!0}if(A.shouldBreakMaskChain){while(m.length!=0)M.ac$(m.pop(),n)}if(z){P.add.lsct=A.layerListExpandedType==2?ef.fz:ef.Se;
P.Bx="pass";P.FK=24;P.gb(A.isVisible);n.C.push(n.hG());if(C=="artboard"){var G=g.clone(),V=$.NW();G.x=-Math.floor($.z2/V);
G.y=-Math.floor($.EU/V);G.m=Math.floor(G.m/V);G.n=Math.floor(G.n/V);P.MR(G);var T=A.backgroundColor,R=T?{o:255*T.red,B:255*T.green,k:255*T.blue}:{o:255,B:255,k:255};
P.add.artb.Clr={t:"Objc",v:E.M.lW(R)};P.add.artb.artboardBackgroundType={t:"long",v:4}}M.Fi(A.layers,n,$,D,j,I,U)}else if(f&&!K){P.add.vmsk=new h.Rd;
P.add.vstk=JSON.parse(JSON.stringify(at.QO.default));var x=Y!=null&&Y.frameFXMulti.v.length==1,v=k?k.fills:null,N=k?M.ahY(D,v,g,$,P.getName(),n,M.ZZ(U,A.do_objectID+"_image")):[];
if(N.length==0){if(x)P.add.vstk.fillEnabled.v=!1;else P.add.iOpa=0;P.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}}}else{var u=N[0],H=null,F=null;
if(u.type=="SoFi"){H="SoCo";F=at.Oa}if(u.type=="GrFl"){H="GdFl";F=at.Ki}if(u.type=="patternFill"){H="PtFl";
F=at.v7}if(H!=null){P.add[H]={classID:"null"};for(var L=0;L<F.length;L++){var t=F[L];P.add[H][t]=u.Z.v[t]}var o=u.Z.v.Opct.v.val;
if(x&&o==0)P.add.vstk.fillEnabled.v=!1;else P.add.iOpa=Math.round(255*o/100)}}P.FK|=16;P.add.vmsk.i=M.Pf(A.layers?A.layers:[A],A.layers?$:W);
var q=k?k.blur:null;if(q&&q.isEnabled&&q.type<=1)P.add.vmsk.C3=q.radius;if(P.add.vmsk.i.length==2){console.log("shape with no content:",P.getName())}if(x){var _=Y.frameFXMulti.v[0].v,d=P.add.vstk,r=k.borders[0];
Y.frameFXMulti.v=[];ge.a9C(_,d);var p=k.borderOptions,Q=k.miterLimit;if(p){var B=p.dashPattern;d.strokeStyleLineCapType.v.strokeStyleLineCapType=at.QO.EZ[p.lineCapStyle];
d.strokeStyleLineJoinType.v.strokeStyleLineJoinType=at.QO.join[p.lineJoinStyle];if(B)d.strokeStyleLineDashSet.v=ge.zW(B,1/_.Sz.v.val);
if(Q!=null)d.strokeStyleMiterLimit.v=Q}}P.hu();P.yb(n)}else if(C=="bitmap"||K){if(!K&&A.image==null)continue;
var i=K?k.fills[0]:null,c=K?i.image.bdata:A.image.bdata,h2=n.An(c,P.getName(),0,0);h2.FK=P.FK;P=h2;var q=k?k.blur:null,jX=k?k.colorControls:null;
if(q||jX){P.add.SoLd.filterFX=cx.Gq();n.V$({id:P.add.SoLd.placed.v,rect:new iB,buffer:E.Q(1),z:new h.ac});
var v=P.add.SoLd.filterFX.v.filterFXList.v;if(q){var bm=cx.gt("GsnB",{});bm.v.enab.v=q.isEnabled;bm.v.Fltr.v.Rds.v.val=q.radius;
v.push(bm)}if(jX){var dC=jX.brightness,fn=jX.contrast,fK=jX.hue,i6=jX.saturation;if(fK!=0||i6!=1){var bm=cx.gt("hue2",{});
bm.v.enab.v=jX.isEnabled;cT.nr(bm.v.Fltr.v,0,[Math.round(fK*180/Math.PI),Math.round((i6-1)*100),0]);
v.push(bm)}if(dC!=0||fn!=1){var bm=cx.gt("brit",{});bm.v.enab.v=jX.isEnabled;fn=fn-1;if(fn>0)fn/=2;var dh=bm.v.Fltr.v;
dh.Brgh.v=Math.round(dC*255);dh.Cntr.v=Math.round(fn*255);dh.useLegacy.v=!0;v.push(bm)}}}if(K){var kA=i.patternFillType;
if(kA==3){var ig=P.rect.m/P.rect.n,iJ=g.m/g.n;if(ig<iJ){$.translate(-(g.m*(1-ig/iJ))/2,0);$.scale(iJ/ig,1)}else{$.translate(0,-(g.n*(1-iJ/ig))/2);
$.scale(1,ig/iJ)}}}g.x=g.y=0;var fL=E.p.Wx(g).w;$.Ba();E.p.D(fL,$,fL);P.add.SoLd.Trnf=y.wR.Hh(fL);P.add.SoLd.nonAffineTransform=y.wR.Hh(fL);
P.vr(n,!1)}else if(C=="text"){if(A.attributedString==null)continue;var fB=$.clone(),ah,eS,ie=0;fB.Ba();
fB.dl=fB.j7=Math.min(fB.dl,fB.j7);P.add.lnsr="rend";P.add.TySh=hd._3(0,0);P.add.TySh.IA=new iB(0,0,g.m,g.n);
P.add.TySh.D=fB;var gL=A.attributedString;if(gL.archivedAttributedString)gL=gL.archivedAttributedString;
var e_=gL.NSString;if(e_==null)e_=gL.string;if(e_==null)e_="";if(e_["NS.string"])e_=e_["NS.string"];
if(I[A.do_objectID]!=null)e_=I[A.do_objectID];var c2=M.ZZ(U,A.do_objectID+"_stringValue");if(c2)e_=c2.value;
if(gL.attributes!=null){ah=[];eS=[];var jS=gL.attributes;for(var L=0;L<jS.length;L++){ah.push(jS[L].length,L);
eS.push(jS[L].attributes)}}else if(gL.NSAttributeInfo==null){ah=[e_.length,0];eS=[gL.NSAttributes]}else{ah=gL.NSAttributeInfo["NS.data"];
eS=gL.NSAttributes;ah=bW.afv(ah,eS)}for(var L=0;L<ah.length;L+=2)ie+=ah[L];if(ie!=e_.length){while(ie>e_.length){ah[ah.length-2]--;
ie--;if(ah[ah.length-2]==0){ah.pop();ah.pop()}}ah[ah.length-2]+=e_.length-ie}e_=e_.replace(/\u2028/g,"\n");
e_=e_.replace(/\u2029/g,"\n");e_=e_.replace(/\r/g,"\n");var as=P.add.TySh._o;hd.KO(as,0,e_);if(e_!=""){var gb=A.textBehaviour,gx=k.textStyle,eo=gx?gx.verticalAlignment:0,di=M.a5X(as,ah,eS,e_),V=fB.NW(),d0=hd.tG(as,0,1),gJ=0;
if(d0.lJ.Font){var e6=d0.JO[d0.lJ.Font].Name;if(e6=="FontAwesome"||e6=="Ionicons")di*=.87}var dt=d0.lJ.AutoLeading?0:d0.lJ.Leading*.6,g5=Math.max(di,dt)*V,jW=g.m,eP=g.n;
if(gb==0){hd.VL(as,0);var fZ=hd.Hm(d0.ci);if(fZ==1)gJ=jW*V;if(fZ==2)gJ=jW*V*.5;if(eo==0)g5*=1;else g5*=.9}else{hd.VL(as,1);
hd.sV(as,[0,0,Math.round(jW),Math.round(eP)]);if(gb==2&&eo==0)g5=g5*.2;else if(gb==2&&eo==1){g5=V*.5*(eP-d0.lJ.FontSize)}else if(gb==1&&eo==0)g5=g5*.2;
else g5=g5*.35}P.add.TySh.D.translate(gJ,g5)}}else if(C=="symbolInstance"||C=="symbolMaster"){var j3=A.symbolID;
if(I[A.do_objectID])j3=I[A.do_objectID].symbolID;var dr=M.ZZ(U,A.do_objectID+"_symbolID");if(dr)j3=dr.value;
if(j3=="")continue;var c0={};for(var t in I)c0[t]=I[t];if(A.overrides)for(var t in A.overrides)c0[t]=A.overrides[t];
var fM=U.slice(0);if(A.overrideValues)fM=fM.concat(A.overrideValues);var cB=j[j3];if(cB==null){console.log("Unknown master master",A.symbolID);
continue}var iI=bW._I(cB.o3.frame),jD=iI.m/g.m,j8=iI.n/g.n,jG=$.clone();jG.scale(jD,j8);P.add.lsct=ef.Se;
P.Bx="pass";P.FK=24;P.gb(A.isVisible);n.C.push(n.hG());var i1=cB.o3;if(n.CU.indexOf(i1)==-1){n.CU.push(i1);
M.Fi(i1.layers,n,jG,D,j,c0,fM);n.CU.pop()}}else if(C=="slice"){console.log("slice layers are ignored by now");
continue}else{console.log("unknown layer type: "+C,A);continue}if(k&&k.contextSettings){var bH=k.contextSettings,a_=bH.blendMode;
if(a_<M._z.length){P.Bx=dD.mS[dD.ik.indexOf(M._z[a_])];if(z&&P.Bx=="norm")P.Bx="pass"}P.opacity=Math.round(P.opacity*bH.opacity)}if(Y!=null){P.add.lmfx=Y}n.C.push(P);
if(A.hasClippingMask&&w.length>1){m.push(P);n.C.push(n.hG())}}while(m.length!=0)M.ac$(m.pop(),n)};bW.ZZ=function(w,n){for(var L=0;
L<w.length;L++)if(w[L].overrideName.startsWith(n))return w[L]};bW.afv=function(w,n){var W=0,D=[];while(W+1<w.length){var j=w[W];
W++;if(j>127){j+=128*(w[W]-1);W++;if(w[W-1]>127){j+=128*(w[W]-1);W++}}var I=w[W];W++;D.push(j,I)}return D};
bW.a5X=function(w,n,W,D){var j=bW,I=0,A=0,g=0;for(var L=0;L<D.length;L++){var U=D.charCodeAt(L),M=1473<=U&&U<=1479||1488<=U&&U<=1514||1520<=U&&U<=1524,m=1569<=U&&U<=1594||1600<=U&&U<=1749;
if(M||m)I++}var l=I>D.length/2;for(var L=0;L<n.length;L+=2){var k=n[L],P=14,Z="DejaVuSans";if(k==0)continue;
var $=n[L+1],C=W[$],f=hd.tG(w,A,A+k-1),z=C.NSColor;if(z==null){var z=C.MSAttributedStringColorDictionaryAttribute;
if(z==null)z=C.MSAttributedStringColorAttribute;if(z==null)z="0 0 0";else z=[z.red,z.green,z.blue].join(" ")}else if(j.lg(z)=="MSArchivedColor")z=z.dr+" "+z.dg+" "+z.db;
else if(z.NSRGB){z=z.NSRGB;z=J.sv(z,0,z.length-1)}else if(z.NSCMYK){z=z.NSCMYK;z=J.sv(z,0,z.length-1);
z=z.split(" ").map(parseFloat);var s=1-z[0],O=1-z[1],a=1-z[2],X=1-z[3];z=s*X+" "+O*X+" "+a*X}else if(z.NSWhite){z="1 1 1"}z=z.split(" ");
f.lJ.FillColor={Type:1,Values:[1,parseFloat(z[0]),parseFloat(z[1]),parseFloat(z[2])]};var Y=C.MSAttributedStringFontAttribute;
if(C.NSFont){P=C.NSFont.NSSize;Z=C.NSFont.NSName}else if(Y){if(Y.attributes){Y=Y.attributes;P=Y.size;
Z=Y.name}else{var K=Y.NSFontDescriptorAttributes;if(K==null)K=Y.UIFontDescriptorAttributes;Y=K;P=Y.NSFontSizeAttribute;
Z=Y.NSFontNameAttribute}if(Z==null)Z="DejaVuSans"}var g=Math.max(g,P);f.lJ.FontSize=Math.round(P);hd.hI(f,Z);
var S=C.NSKern;if(S==null)S=C.kerning;if(S!=null)f.lJ.Tracking=Math.round(1e3*S/P);if(C.NSUnderline!=null)f.lJ.Underline=C.NSUnderline>0;
var G=C.NSStrikethrough;if(G==null)G=C.strikethroughStyle;if(G!=null)f.lJ.Strikethrough=G>0;if(C.MSAttributedStringTextTransformAttribute==1)f.lJ.FontCaps=2;
var V=C.NSParagraphStyle;if(V==null)V=C.paragraphStyle;if(V){var T=V.paragraphSpacing;if(T!=null){f.ci.SpaceAfter=T}var R=V.NSAlignment;
if(R==null)R=V.alignment;if(R!=null){var x=0;if(!1){}else if(R==1)x=1;else if(R==2)x=2;else if(R==4)x=0;
else{x=R;console.log("unknown align",R)}if(l&&x<2)x=1-x;f.ci.Justification=x}var v=V.NSMinLineHeight;
if(v==null)v=V.minimumLineHeight;if(v!=null){f.lJ.AutoLeading=!1;f.lJ.Leading=v}}f.ci._Direction=l?1:0;
hd.g0(w,A,A+k,f);A+=k}return g};bW.aiv=function(w,n,W,D,j,I,U){var M=bW,m=JSON.parse(at.default),l=!1;
for(var L=0;L<at.order.length;L++)m[at.Pa[L]]={t:"VlLs",v:[]};var A=W.fills,g=M.ahY(w,A,D,j,I,n);for(var k=0;
k<2;k++){var $=W[["shadows","innerShadows"][k]];if($==null)continue;var C=["DrSh","IrSh"][k],f=at.Pa[at.order.indexOf(C)];
for(var L=0;L<$.length;L++){var z=$[L];if(!z.isEnabled)continue;if(z.contextSettings.opacity==0||z.color.alpha==0)continue;
var s=JSON.parse(at.UR[at.order.indexOf(C)]);m[f].v.unshift({t:"Objc",v:s});l=!0;s.Clr.v=M.mn(z.color);
s.blur.v.val=Math.round(z.blurRadius/j.NW());var O=j.clone();O.z2=O.EU=0;O.Ba();var a=O.bj(new ec(z.offsetX,z.offsetY)),X=Math.sqrt(a.x*a.x+a.y*a.y);
s.Dstn.v.val=Math.round(X);s.lagl.v.val=Math.round(Math.atan2(a.y,-a.x)*(180/Math.PI));if(s.layerConceals)s.layerConceals.v=g.length!=0;
M.od(z,s)}}var P=W.borders;if(P!=null&&(g.length==0||W.blur==null||!W.blur.isEnabled))for(var L=0;L<P.length;
L++){var Z=P[L];if(!Z.isEnabled)continue;var s=JSON.parse(at.UR[at.order.indexOf("FrFX")]),f=at.Pa[at.order.indexOf("FrFX")];
m[f].v.unshift({t:"Objc",v:s});l=!0;s.Clr.v=M.mn(Z.color);if(Z.fillType!=0&&Z.gradient){var Y=M.E1(Z.gradient,D,j,I),K=["Type","Angl","Ofst","Scl"];
for(var L=0;L<K.length;L++)s[K[L]]=Y[K[L]];s.Grad.v=Y.Grad.v;s.PntT.v.FrFl="GrFl"}s.Sz.v.val=Math.round(Z.thickness/j.NW());
s.Styl.v.FStl=["CtrF","InsF","OutF"][Z.position];M.od(Z,s)}for(var L=U?1:0;L<g.length;L++){var S=g[L],f=at.Pa[at.order.indexOf(S.type)];
m[f].v.unshift(S.Z);l=!0}return l?m:null};bW.ahY=function(w,n,W,D,j,I,U){if(n==null)return[];var M=bW,m=[];
for(var L=0;L<n.length;L++)if(n[L].isEnabled)m.push(n[L]);n=m;var l=[];for(var L=0;L<n.length;L++){var A=n[L],g=null,k=null;
if(A.fillType==0){g="SoFi";var $=JSON.parse(at.UR[at.order.indexOf("SoFi")]);k={t:"Objc",v:$};k.v.Clr.v=M.mn(A.color)}else if(A.fillType==1){g="GrFl";
k={t:"Objc",v:M.E1(A.gradient,W,D,j)}}else if(A.fillType==4&&A.image!=null){var C=A.image;if(U)C=U.value;
var f=jj.zJ(C.bdata.buffer);if(f!=null&&f!="pdf"&&f!="eps"){var z,Z=0,Y=0,K=0;if(I.Jw[C.key])z=I.Jw[C.key];
else{var s=jj.ZO(f).Vu(C.bdata)[0],O=s.XL.clone();z={};z.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";z.name="someImage";
z.HY=[new Uint8Array(s.data),O];I.qn(z);I.Jw[C.key]=z}var a=z.HY[1],$=JSON.parse(at.UR[at.order.indexOf("patternFill")]);
g="patternFill";k={t:"Objc",v:$};var X=A.patternFillType,P=A.patternTileScale;$.Algn.v=!0;$.Ptrn.v.Idnt.v=z.id;
if(X==0){Z=P*a.m/Math.min(a.m,a.n);Y=-D.z2;K=-D.EU}else{Z=Math.max(W.m/a.m,W.n/a.n);Y=-D.z2-(a.m*Z-W.m)/2;
K=-D.EU-(a.n*Z-W.n)/2}$.Scl.v.val=100*Z*(1/D.NW());$.phase.v.Hrzn.v=Math.round(Y/D.NW());$.phase.v.Vrtc.v=Math.round(K/D.NW())}}else if(A.fillType==5){console.log("fill type Noise not supported yet")}else console.log("unknown fill type",A.fillType);
if(g!=null){M.od(A,k.v);l.push({type:g,Z:k})}}return l};bW.ay_=function(w){var n=bW,W=new iB(0,0,1,1);
w=w.slice(0);while(!0){var D=!1;for(var L=0;L<w.length-1;L++){var j=w[L],I=w[L+1],U=null,M=j.contextSettings;
if(j.fillType==0&&(M==null||M.opacity==1&&M.blendMode==0)&&j.color.alpha==1){var m="norm",l=1,M=I.contextSettings;
if(M){l=M.opacity;m=dD.XK(n._z[M.blendMode])}if(I.fillType==0){U=JSON.parse(JSON.stringify(I));n.ai$(U.color,j.color,U.color,W,m,l)}if(I.fillType==1){U=JSON.parse(JSON.stringify(I));
var A=U.gradient.stops;for(var g=0;g<A.length;g++)n.ai$(A[g].color,j.color,A[g].color,W,m,l)}if(U!=null&&U.contextSettings){var M=U.contextSettings;
M.opacity=1;M.blendMode=0}}if(U!=null){w.splice(L,0,U);D=!0;break}}if(!D||w.length<2)break}return w};
bW.ai$=function(w,n,W,D,j,I){var U=bW,M=E.Q(4);U.amn(w,M);var m=E.Q(4);U.amn(n,m);E.s._U(j,M,D,m,D,D,I);
U.a8u(m,W)};bW.amn=function(w,n){n[0]=255*w.red;n[1]=255*w.green;n[2]=255*w.blue;n[3]=255*w.alpha};bW.a8u=function(w,n){n.red=w[0]/255;
n.green=w[1]/255;n.blue=w[2]/255;n.alpha=w[3]/255};bW.ac$=function(w,n){w=w.clone();w.FK=24;w.nz("Mask by "+w.getName());
n.C.push(w);w.add.lsct=ef.fz;w.add.lyid=n.jd();delete w.add.lmfx;delete w.add.SoCo;delete w.add.GdFl;
delete w.add.PtFl;delete w.add.iOpa;if(w.add.vmsk)w.add.vmsk.eP=!0;w.hu();w.yb(n);if((w.FK&16)==16)w.FK-=16;
if((w.FK&2)==2)w.FK-=2;w.Bx="pass";w.opacity=255};bW._z="Nrml Drkn Mltp CBrn Lghn Scrn CDdg Ovrl SftL HrdL Dfrn Xclu H Strt Clr Lmns linearBurn linearDodge".split(" ");
bW.E1=function(w,n,W,D){W=W.clone();W.Ba();W.z2=W.EU=0;var j=W.NW(),k=0,$=0;W.scale(1/j,1/j);var I=bW,U=JSON.parse(at.UR[at.order.indexOf("GrFl")]),M=U.Grad.v;
M.Intr.v=0;if(w==null)return U;var m=w.gradientType,l=I.gJ(w.from),A=I.gJ(w.to);l.offset(-.5,-.5);A.offset(-.5,-.5);
l=W.bj(l);A=W.bj(A);var g=Math.atan2(-(A.y-l.y),A.x-l.x);U.Type.v.GrdT=["Lnr","Rdl","Angl"][m];U.Scl.v.val=100*ec.cS(l,A);
if(m==0){U.Angl.v.val=180/Math.PI*g;U.Scl.v.val=100*ec.cS(l,A);k=(l.x+A.x)/2;$=(l.y+A.y)/2}if(m==1){U.Scl.v.val=200*ec.cS(l,A);
k=l.x;$=l.y}if(m==2){U.Angl.v.val=180/Math.PI*(g-Math.PI/2)}var C=U.Ofst.v;C.Hrzn.v.val=k*100;C.Vrtc.v.val=$*100;
var f=[];for(var L=0;L<w.stops.length;L++){var z=w.stops[L],s=z.color;f.push([z.position,s?[s.red,s.green,s.blue]:[0,0,0],s.alpha])}E.M.WP(f,M);
return U};bW.od=function(w,n){var W=bW,D=1,j=w.contextSettings;if(j!=null){n.Md.v.BlnM=W._z[j.blendMode];
D*=j.opacity}else n.Md.v.BlnM=W._z[0];n.enab.v=w.isEnabled;if(n.uglg!=null)n.uglg.v=!1;if(w.color!=null)D*=w.color.alpha;
n.Opct.v.val=Math.round(D*100)};bW.mn=function(w){return E.M.lW(w?{o:w.red*255,B:w.green*255,k:w.blue*255}:{o:0,B:0,k:0})};
bW.Pf=function(w,n){var W=bW,D=[{type:6},{type:8,all:0}];for(var j=0;j<w.length;j++){var I=w[j],U=I.booleanOperation,M=0,m=I._class,C=!1;
if(m=="group"||m=="text"||m=="symbolInstance"||m=="slice"){console.log(m+" inside ShapeGroup");continue}if(U==-1)M=0;
else if(U==0)M=1;else if(U==1)M=2;else if(U==2)M=3;else if(U==3)M=0;if(j==0)M=1;var l=bW._I(I.frame),A=W.af1(I,n),g=I.path?I.path:I,k=[{type:0,length:0,Ht:M,S1:2,_T:0,si:0}],$=g.points;
for(var L=0;L<$.length;L++){var f=$[L],z=W.gJ(f.curveTo),s=W.gJ(f.point),O=W.gJ(f.curveFrom);C=C||f.hasCurveFrom&&!O.s9(s)||f.hasCurveTo&&!z.s9(s)}var a=[];
if(!C){var X=[],bK=$.length;if(bK==0)continue;for(var L=0;L<bK;L++){a[L]=$[L].cornerRadius;var f=W.gJ($[L].point);
X.push(f.x,f.y)}A.scale(1/l.m,1/l.n);A.Ba();E.p.D(X,A,X);k=E.P.AB.cX(X,a).slice(2);k[0].Ht=M}else{var P=$.length;
k[0].length=P;for(var L=0;L<P;L++){var f=$[L],Z=f.curveMode,Y=W.gJ(f.point);k[1+L]={type:Z==2||Z==4?1:2,T7:f.hasCurveTo?W.gJ(f.curveTo):Y.clone(),H:Y,mO:f.hasCurveFrom?W.gJ(f.curveFrom):Y.clone()}}A.scale(1/l.m,1/l.n);
A.Ba();E.P.c0(k,A);var a=[];for(var L=0;L<P;L++){var f=$[L],Z=f.curveMode,K=f.cornerRadius;if(Z==1&&K!=0)a.push(K);
else a.push(0)}}if(!g.isClosed)for(var L=0;L<k.length;L++)k[L].type+=3;D=D.concat(k);var S=W.lg(I);if(A.k==0&&A.Cj==0){var G=A.z2,V=A.EU,T=G+A.dl,R=V+A.j7,x=[G,V,T,R]}}return D};
bW.af1=function(w,n){var W=n.clone(),D=w.frame?bW._I(w.frame):null;if(D)W.translate(-D.x-D.m/2,-D.y-D.n/2);
if(w.isFlippedHorizontal)W.scale(-1,1);if(w.isFlippedVertical)W.scale(1,-1);W.rotate(-w.rotation*(Math.PI/180));
if(D)W.translate(D.m/2,D.n/2);return W};bW.gJ=function(w){w=w.slice(1,w.length-1).split(",");return new ec(parseFloat(w[0]),parseFloat(w[1]))};
bW._I=function(w){return new iB(w.x,w.y,w.width,w.height)};bW.aAv=function(w){return{_class:"rect",constrainProportions:!1,x:w.x,y:w.y,width:w.m,height:w.n}};
function g6(){}g6.ew=function(w,n){var W=Date.now(),D=g6,j=UZIP.parse(w),I=JSON.parse(J.KY(j.manifest)),U=JSON.parse(J.KY(j["resources/graphics/graphicContent.agc"])).resources,M=[],m=[],l=I.children;
for(var L=0;L<l.length;L++){var A=l[L];if(A.name=="artwork"){var g=A.children;for(var k=0;k<g.length;
k++){var $=g[k],C=JSON.parse(J.KY(j["artwork/"+$.path+"/graphics/graphicContent.agc"])),f=C.children;
if(f.length==0){}else if(f.length==1){if($["uxdesign#bounds"]){$._node=f[0];M.push($)}}else{var z=f[0],s=z.transform,O=z.shape;
if(O==null)O={x:0,y:0,width:1e3,height:1e3};if(O.type=="path"){var a=E.p.lV(Typr.U.SVGToPath(O.path).crds);
O={x:a.x,y:a.y,width:a.m,height:a.n}}O=JSON.parse(JSON.stringify(O));if(s){O.x+=s.tx;O.y+=s.ty}$["uxdesign#bounds"]=O;
$._node={type:"artboard",artboard:{children:f}};m.push($)}}}}if(M.length==0)M=m;var X=[],P=new iB;for(var L=0;
L<M.length;L++){var $=M[L],Z=bW._I($["uxdesign#bounds"]);X.push(Z);P=P.x0(Z)}var Y=bW.CI(P,8192*8192);
n.XW=!0;n.m=Math.round(P.m/Y);n.n=Math.round(P.n/Y);n.buffer=E.Q(n.m*n.n*4);n.om(M.length);var K=new eh(Y,0,0,Y,P.x,P.y);
n.Jw={};for(var L=0;L<M.length;L++){var $=M[L],Z=bW._I($["uxdesign#bounds"]),S=$._node,G=K.clone(),V=Z.clone(),T=G.NW();
G.translate(-Z.x,-Z.y);V.x=-Math.floor(G.z2/T);V.y=-Math.floor(G.EU/T);V.m=Math.floor(V.m/T);V.n=Math.floor(V.n/T);
G.translate(Z.x,Z.y);g6.ab(S,n,G,U,j,V);var R=n.C[n.C.length-1];R.nz($.name);R.MR(V);if(L!=M.length-1)R.add.lsct=ef.Se}delete n.Jw};
g6.wq=function(w){if(w==null)return new eh;return new eh(w.a,w.b,w.c,w.d,w.tx,w.ty)};g6.ab=function(w,n,W,D,j,I){var U=g6,M=w.type,m=w[M],l=w.style,A=U.wq(w.transform),C,f="none",z,s="none",O,a;
A.Ba();var g=W.clone();g.concat(A);var k=n.QI(),$=w.name;k.nz($?$.slice(0,250):"Layer");if(w.visible!=null)k.gb(w.visible);
if(l){C=l.stroke;f=C?C.type:"none";z=l.fill;s=z?z.type:"none";O=l.filters;a=l.clipPath;if(a&&D.clipPaths[a.ref])a=D.clipPaths[a.ref].children;
else a=null;if(l.opacity!=null)k.opacity=Math.round(255*l.opacity);if(s=="solid"&&z.color.alpha)k.opacity=Math.round(k.opacity*z.color.alpha);
if(O){k.add.lmfx=U.a2m(O);for(var L=0;L<O.length;L++)if(O[L].type=="uxdesign#blur"){var X=O[L],P=X.params,Z=P.brightnessAmount;
if(Z==null)Z=0;Z=Math.abs(Z/100);if((X.visible==null||X.visible==!0)&&P.backgroundEffect)k.opacity=Math.round(k.opacity*(Z+(1-Z)*P.fillOpacity))}}if(s=="pattern"&&z.pattern.meta.ux.uid=="")s="none"}if(a==null&&w.meta&&w.meta.ux&&w.meta.ux.clipPathResources)a=w.meta.ux.clipPathResources.children;
if(M=="artboard"||M=="group"){if(a){var Y=a[0],K=Y.shape,S=K!=null&&K.type=="rect"&&K.width*K.height>1e6;
if(Y.type!="text"&&!S){if(K){var A=U.wq(Y.transform);A.Ba();var G=g.clone();G.concat(A);k.add.vmsk=new h.Rd;
k.add.vmsk.i=U.Pf(K);G=G.clone();G.Ba();E.P.c0(k.add.vmsk.i,G);k.hu();k.yb(n)}}else if(!S)alert("Clipping by text has been ignored")}k.add.lsct=ef.fz;
k.Bx="pass";k.FK=24;if(w.visible!=null)k.gb(w.visible);n.C.push(n.hG());var V=m.children,T=z;if(T)T=T.color;
if(T)T=T.value;if(z){if(M=="artboard"&&s=="solid"){k.MR(new iB(0,0,10,10));k.add.artb.Clr={t:"Objc",v:E.M.lW({o:T.r,B:T.g,k:T.b})};
k.add.artb.artboardBackgroundType={t:"long",v:4}}else{var R=n.QI();R.nz("BACKGROUND");R.FK|=16;R.add.vstk=JSON.parse(JSON.stringify(at.QO.default));
R.add.vmsk=new h.Rd;R.add.vmsk.i=U.Pf({type:"rect",x:I.x,y:I.y,width:I.m,height:I.n});U.f7(z,s,g,I,I,R,n,D,j);
R.hu();R.yb(n);n.C.push(R)}}for(var L=0;L<V.length;L++){g6.ab(V[L],n,g,D,j,I)}}else if(M=="shape"&&(m.type=="rect"&&(m.r==null||m.r==0)||m.type=="path"&&UDOC.G.isBox(Typr.U.SVGToPath(m.path)))&&s=="pattern"&&(Math.abs(m.width/m.height-z.pattern.width/z.pattern.height)<.01||l.fill.pattern.meta.ux.scaleBehavior=="fill")){var x=z.pattern,v=x.meta.ux,N=v.uid,u=j["resources/"+N];
if(u==null){console.log(x);return}var H=n.An(u,k.getName(),0,0);H.FK=k.FK;H.opacity=k.opacity;k=H;var F=E.P.b3(U.Pf(m),null),t=E.p.Wx(new iB(0,0,x.width,x.height)).w,o=new eh;
o.scale(x.width/F.m,x.height/F.n);if(v.offsetX)o.translate(-v.offsetX*x.width,0);if(v.offsetY)o.translate(0,-v.offsetY*x.height);
g.concat(o);g.Ba();E.p.D(t,g,t);k.add.SoLd.Trnf=y.wR.Hh(t);k.add.SoLd.nonAffineTransform=y.wR.Hh(t);
k.vr(n,!1)}else if(M=="shape"){k.FK|=16;k.add.vstk=JSON.parse(JSON.stringify(at.QO.default));k.add.vmsk=new h.Rd;
k.add.vmsk.i=U.Pf(m);var F=E.P.b3(k.add.vmsk.i,null),G=g.clone();G.Ba();E.P.c0(k.add.vmsk.i,G);var q=E.P.b3(k.add.vmsk.i,null);
if(f=="none"){}else{var _=C.color.value,d,r;d="SoFi";var p=JSON.parse(at.UR[at.order.indexOf("SoFi")]);
r={t:"Objc",v:p};r.v.Clr.v=E.M.lW({o:_.r,B:_.g,k:_.b});var Q=C.align,B=C.cap;if(Q==null)Q="center";var i=k.add.vstk;
i.strokeEnabled.v=!0;i.strokeStyleLineWidth.v.val=C.width;if(Q)i.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[["inside","center","outside"].indexOf(Q)];
if(B)i.strokeStyleLineCapType.v.strokeStyleLineCapType=at.QO.EZ[["butt","round","square"].indexOf(B)];
var c=["SoFi","GrFl","patternFill"].indexOf(d),h2=[at.Oa,at.Ki,at.v7][c];i.strokeStyleContent.v={classID:at.QO.W_[0]};
var jX=i.strokeStyleContent.v={classID:at.QO.W_[c]};for(var L=0;L<h2.length;L++)jX[h2[L]]=r.v[h2[L]]}if(O)for(var L=0;
L<O.length;L++)if(O[L].type=="uxdesign#blur"&&O[L].visible){var bm=O[L];k.add.vmsk.C3=bm.params.blurAmount}U.f7(z,s,g,F,q,k,n,D,j);
k.hu();k.yb(n)}else if(M=="text"&&w.text){var dC=w.text,fn=dC.frame,fK=l.font,i6=l.textAttributes,A=g.clone(),fB=0;
A.Ba();k.add.lnsr="rend";k.add.TySh=hd._3(0,0);k.add.TySh.IA=new iB(0,0,100,100);k.add.TySh.D=A;var dh=k.add.TySh._o,kA=dC.rawText.replace(/\r/g,"\n").replace(/\u000b/g,"\n");
hd.KO(dh,0,kA);if(kA!=""){var ig=hd.tG(dh,0,1),iJ=fK.postscriptName;if(iJ==null)iJ=fK.family;hd.hI(ig,iJ);
ig.lJ.FontSize=Math.round(fK.size);if(z){var _=z.color.value;ig.lJ.FillColor={Type:1,Values:[1,_.r/255,_.g/255,_.b/255]}}if(i6){if(i6.paragraphAlign)ig.ci.Justification=["left","right","center"].indexOf(i6.paragraphAlign);
if(i6.letterSpacing)ig.lJ.Tracking=Math.round(i6.letterSpacing);if(i6.lineHeight){ig.lJ.AutoLeading=!1;
ig.lJ.Leading=Math.round(i6.lineHeight)}}hd.g0(dh,0,kA.length,ig)}var fL=w.meta.ux.rangedStyles;if(fL)for(var L=0;
L<fL.length;L++){var m=fL[L],ah=Math.min(m.length,kA.length-fB);if(L==fL.length-1)ah=kA.length-fB;var ig=hd.tG(dh,fB,fB+ah),iJ=m.postscriptName;
if(iJ==null)iJ=m.family;if(iJ!=null)hd.hI(ig,iJ);var eS=m.textScript,gL=m.underline,e_=m.fontSize,X=m.fill,c2=m.textTransform;
if(eS&&eS!="none")ig.lJ.FontBaseline=eS=="superscript"?1:2;if(gL!=null)ig.lJ.Underline=gL;if(e_!=null)ig.lJ.FontSize=Math.round(e_);
if(c2!=null)ig.lJ.FontCaps=c2=="uppercase"?2:0;if(c2=="lowercase"){hd.Ec(dh,fB,fB+ah);hd.KO(dh,fB,kA.slice(fB,fB+ah).toLowerCase())}if(X!=null){var jS=X.value;
ig.lJ.FillColor={Type:1,Values:[1,(jS>>>16&255)/255,(jS>>>8&255)/255,(jS>>>0&255)/255]}}hd.g0(dh,fB,fB+ah,ig);
fB+=ah}if(fn.type=="area"||fn.type=="autoHeight"){var ie=fn.width,gb=fn.height;hd.VL(dh,1);hd.sV(dh,[0,0,ie,gb!=null?gb:ie*2])}}else if(M=="syncRef"){var gx=w.syncSourceGuid,di=D.meta.ux.symbols,e6=U.bq(di,gx);
if(e6){var dt=g.clone();dt.concat(U.wq(e6.transform));g6.ab(e6,n,dt,D,j,I)}return}else console.log(M,w);
n.C.push(k)};g6.bq=function(w,n){for(var L=0;L<w.length;L++){var W=w[L],D=W.group;if(W.id==n)return W;
if(D){var j=g6.bq(D.children,n);if(j)return j}}return null};g6.Pf=function(w){var n=w.type,W=[{type:6},{type:8,all:0}];
if(n=="rect"){var D=w.r,j=w.x,I=w.y,U=w.width,M=w.height;W=E.P.AB.Rect(j,I,U,M,D?D:0)}else if(n=="circle"){var D=w.r;
W=E.P.AB.Po(w.cx-D,w.cy-D,2*D,2*D)}else if(n=="ellipse"){var m=w.rx,l=w.ry;W=E.P.AB.Po(w.cx-m,w.cy-l,2*m,2*l)}else if(n=="path"||n=="compound"){var A=Typr.U.SVGToPath(w.path);
W=E.p.oF({F:A.cmds,w:A.crds},!1)}else if(n=="line"){var g=w.x1,k=w.x2,$=w.y1,C=w.y2;W=E.P.AB.cX([g,$,k,C],0,!0)}else if(n=="polygon"){var f=w.points,z=[];
for(var L=0;L<f.length;L++)z.push(f[L].x,f[L].y);W=W.concat(E.P.AB.cX(z,0,!1).slice(2))}else console.log(n,w);
return W};g6.a2m=function(w){var n=JSON.parse(at.default);for(var L=0;L<at.order.length;L++)n[at.Pa[L]]={t:"VlLs",v:[]};
for(var L=0;L<w.length;L++){var W=w[L],D=W.type,j=W.params,I=W.visible;if(D=="dropShadow"){var U=at.Pa[at.order.indexOf("DrSh")],M=JSON.parse(at.UR[at.order.indexOf("DrSh")]);
n[U].v.unshift({t:"Objc",v:M});var m=j.dropShadows;if(m.length!=1)throw"e";var l=m[L],A=l.color,g=A.value,k=l.dx,$=l.dy;
M.Clr.v=E.M.lW({o:g.r,B:g.g,k:g.b});M.Opct.v.val=Math.round((A.alpha!=null?A.alpha:1)*100);M.uglg.v=!1;
M.enab.v=I!=null?I:!0;M.lagl.v.val=Math.round(180/Math.PI*Math.atan2($,-k));M.Dstn.v.val=Math.round(Math.sqrt(k*k+$*$));
M.blur.v.val=Math.round(l.r*2.3)}}return n};g6.f7=function(w,n,W,D,j,I,U,M,m){var l=g6;if(n=="none"){I.add.vstk.fillEnabled.v=!1;
I.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}}}else{var A,g,k;if(n=="solid"){var $=w.color.value;
A="SoCo";g=at.Oa;var C=JSON.parse(at.UR[at.order.indexOf("SoFi")]);k={t:"Objc",v:C};k.v.Clr.v=E.M.lW({o:$.r,B:$.g,k:$.b})}else if(n=="gradient"){A="GdFl";
g=at.Ki;var C=JSON.parse(at.UR[at.order.indexOf("GrFl")]),f=C.Grad.v,X,P,Z;f.Intr.v=0;var z=w[n],s=z.ref?M.gradients[z.ref]:z.meta.ux.gradientResources,O=["linear","radial","angular"].indexOf(s.type),a=s.stops;
C.Type.v.GrdT=["Lnr","Rdl","Angl"][O];if(O==0){var X=new ec(z.x1,z.y1),P=new ec(z.x2,z.y2);X.x=P.x+.5*(X.x-P.x);
X.y=P.y+.5*(X.y-P.y)}else{var X=new ec(z.cx,z.cy),P=new ec(z.cx+z.r,z.cy)}Z=j;if(z.units=="objectBoundingBox"){var Y=new eh(D.m,0,0,D.n,D.x,D.y);
X=Y.bj(X);P=Y.bj(P)}var Y=l.wq(z.transform);X=Y.bj(X);P=Y.bj(P);Y=W.clone();Y.Ba();X=Y.bj(X);P=Y.bj(P);
E.M.n0(X,P,Z,C);var K=[];for(var L=0;L<a.length;L++){var S=a[L],G=S.color,$=G.value,V=G.alpha;if(V==null)V=1;
K.push([S.offset,[$.r/255,$.g/255,$.b/255],V])}E.M.WP(K,f);k={t:"Objc",v:C}}else if(n=="pattern"){A="PtFl";
g=at.v7;var C=JSON.parse(at.UR[at.order.indexOf("patternFill")]),t;k={t:"Objc",v:C};var T=w[n],R=T.meta.ux,x=R.uid,v=m["resources/"+x].buffer,N=R.flipX,u=R.flipY,H=x+N+u,F=jj.zJ(v);
if(U.Jw[H])t=U.Jw[H];else{var o=new iB(0,0,T.width,T.height),q;if(o.VY()||F==null){o=new iB(0,0,1,1);
q=new ArrayBuffer(4)}else{var _=jj.ZO(F);if(_.Xq){var d=new kc;_.Vu(v,d);q=d.Vc().buffer}else{try{var r=_.Vu(v)[0];
q=r.data;o=r.XL}catch(fV){q=new ArrayBuffer(o.O()*4)}}}t={};t.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";
t.name="someImage";t.HY=[new Uint8Array(q),o];if(N)E.K.oX(t.HY[0].slice(0),t.HY[0],o.m,o.n);if(u)E.K.au1(t.HY[0].slice(0),t.HY[0],o.m,o.n);
U.qn(t);U.Jw[H]=t}var p=W.clone();p.Ba();p.translate(D.x,D.y);var Q=D.m,B=D.n,i=t.HY[1].m,c=t.HY[1].n,h2=Math.max(Q/i,B/c);
if(R.scale)h2*=R.scale;var jX=new eh;jX.translate(-i/2,-c/2);jX.scale(1/i,1/c);if(R.offsetX!=null)jX.translate(R.offsetX,R.offsetY);
jX.scale(i,c);jX.scale(h2,h2);jX.translate(Q/2,B/2);jX.concat(p);ge.aeQ(t,C,0,0,1e3,jX)}else console.log(n);
if(A!=null){I.add[A]={classID:"null"};for(var L=0;L<g.length;L++){var bm=g[L];I.add[A][bm]=k.v[bm]}}}};
function eB(){}eB.ew=function(w,n,W){if(W&&W[0]==null)W=null;w=new Uint8Array(w);var D,$=1;if(w[0]==255&&w[1]==254)D=J.ND(w,2,(w.length>>>1)-1);
else D=J.KY(w,0,w.length);var j=new DOMParser,I=j.parseFromString(D,"image/svg+xml"),U=I.getElementsByTagName("style")[0];
if(U)U=Typr.U.SVG.cssMap(U.textContent);else U={};var M=I.firstChild;while(M.tagName!="svg")M=M.nextSibling;
var m=new iB(0,0,100,100),l=M.getAttribute("viewBox"),A=M.getAttribute("width"),g=M.getAttribute("height");
if(l){var k=eB.a1t(l);m.x=k[0];m.y=k[1];m.m=k[2];m.n=k[3]}else if(A!=null||g!=null){m.m=A!=null?parseFloat(A):parseFloat(g);
m.n=g!=null?parseFloat(g):parseFloat(A)}m=E.p.fF(m);while(W&&Math.max(m.m*$,m.n*$)<Math.max(W[0],W[1]))$++;
while(W==null&&Math.max(m.m,m.n)*$>8192)$*=.5;n.XW=!0;n.m=~~(m.m*$);n.n=~~(m.n*$);n.buffer=E.Q(n.m*n.n*4);
var C=new eh($,0,0,$,-m.x*$,-m.y*$),f={nK:eB.Yz(M),awy:U,C2:0};eB.q2(I,M.children,n,C,f,new eh,0);if(n.C.length==0){var z=n.QI();
z.nz("Layer");n.C.push(z)}};eB.a1t=function(w){var n=" ";if(w.indexOf(",")!=-1)n=",";return w.split(n).map(parseFloat)};
eB.q2=function(w,n,W,D,j,I,U,M){var m=eB,l=["display","opacity","fill-opacity","filter","clip-path"],A=0;
for(var g=0;g<n.length;g++){var k=n[g],$=k.tagName,C=k.getAttribute("id"),s=13,Z=1,S="clip-path",G=null,F=0;
if(C==null)C=k.getAttribute("data-name");var f=m.Yz(k,j.awy);for(var z in j.nK)if(l.indexOf(z)==-1&&f[z]==null)f[z]=j.nK[z];
if(f["font-size"])s=m.i3(f["font-size"],s);if(k.getAttribute("dx"))D.z2+=m.i3(k.getAttribute("dx"),s);
if(k.getAttribute("dy"))D.EU+=m.i3(k.getAttribute("dy"),s);var O=m.Xb(k);O.concat(D);var a=k.getAttribute("visibility"),X=f.display,P=W.QI();
if(a=="hidden"||X=="none")P.gb(!1);P.nz(C!=null?C.split(":::")[0]:"Layer");if(f.opacity)Z*=parseFloat(f.opacity);
if(f["fill-opacity"]){var Y=parseFloat(f["fill-opacity"]);if(Y!=0)Z*=Y}P.opacity=Math.round(255*Z);if(f["mix-blend-mode"]){var K=dD.R3.indexOf(f["mix-blend-mode"]);
if(K!=-1)P.Bx=dD.mS[K]}if(k.getAttribute(S)==null)S="mask";if(k.getAttribute(S)!=null||f["clip-path"]){var V=k.getAttribute(S);
if(V==null)V=f["clip-path"];V=V.slice(4,V.length-1);var T=w.getElementById(V.slice(1));if(T){var R=T.children;
G=W.QI();G.nz("Clip-Path"+(C?": "+C:""));G.add.lsct=U<2?ef.fz:ef.Se;G.Bx="pass";G.FK=24;var x=G.add.vmsk=new h.Rd;
W.C.push(W.hG());var v=[];if(T.getAttribute(S)){var V=T.getAttribute(S);V=V.slice(4,V.length-1);v=w.getElementById(V.slice(1)).children}for(var L=0;
L<R.length;L++){var N=m.Xb(R[L]);N.concat(O);var u=m.Pf(W,w,R[L],!1).slice(2);E.P.c0(u,N);x.i=x.i.concat(u)}for(var L=0;
L<v.length;L++){var N=m.Xb(R[L]);N.concat(O);var u=m.Pf(W,w,v[L],!1).slice(2);for(var H=0;H<u.length;
H++)if(u[L].Ht!=null)u[L].Ht=3;E.P.c0(u,N);x.i=x.i.concat(u)}G.hu();G.yb();U++}}if(f.filter&&f.filter!="none"){var t=f.filter,q,_,d,p=!1,Q=!1,B=!1;
t=t.slice(5,t.length-1);var o=w.getElementById(t),r=[0,0,0,.5],i=O.NW();if(o)for(var L=0;L<o.children.length;
L++){var c=o.children[L];if(c.tagName=="feGaussianBlur"){p=!0;q=parseFloat(c.getAttribute("stdDeviation"))*i}if(c.tagName=="feColorMatrix"){var h2=c.getAttribute("values");
if(h2){h2=h2.split(" ").map(parseFloat);r=[h2[4],h2[9],h2[14],h2[18]]}}if(c.tagName=="feComposite"){B=!0}if(c.tagName=="feOffset"){Q=!0;
var jX=c.getAttribute("dx"),bm=c.getAttribute("dy");_=parseFloat(jX?jX:0)*i;d=parseFloat(bm?bm:0)*i}}if(p&&(B||Q)){var dC=B?"IrSh":"DrSh";
if(dC=="IrSh"){P.add.iOpa=0}var fn=JSON.parse(at.UR[at.order.indexOf(dC)]);fn.blur.v.val=Math.round(q*2.4);
var fK=Math.sqrt(_*_+d*d);fn.uglg.v=!1;fn.Dstn.v.val=Math.round(fK);fn.lagl.v.val=Math.round(Math.atan2(d,-_)*(180/Math.PI));
fn.Clr.v=E.M.lW({o:r[0]*255,B:r[1]*255,k:r[2]*255});fn.Opct.v.val=Math.round(r[3]*100);m.axe(P,at.Pa[at.order.indexOf(dC)],fn)}else if(p)F=q}if($=="g"||$=="a"||$=="svg"||$=="switch"||($=="text"||$=="textPath")&&k.children.length>0||$=="symbol"&&M){if($=="text")I=m.l$(k,I);
var i6=k.getAttribute("viewBox"),dh=k.getAttribute("width"),kA=k.getAttribute("height");if(i6&&dh&&kA){var ig=eB.a1t(i6),iJ=m.l$(k),fL=new eh;
fL.translate(-ig[0],-ig[1]);fL.scale(parseFloat(dh)/ig[2],parseFloat(kA)/ig[3]);fL.translate(iJ.z2,iJ.EU);
fL.concat(O);O=fL}var fB=k.children.length,ah=j.nK;j.nK=f;var eS=j.C2;j.C2=Math.max(j.C2,F);var gL=$!="text"&&$!="textPath"||fB>1;
if(gL){var e_=P.I4();P.add.lsct=U<2&&e_&&(C==null||!C.endsWith(":::"))?ef.fz:ef.Se;P.Bx="pass";P.FK=24;
P.gb(e_);W.C.push(W.hG())}m.q2(w,k.children,W,O,j,I,U+1);if(gL)W.C.push(P);else{var c2=W.C[W.C.length-1];
c2.opacity=P.opacity;c2.Bx=P.Bx}j.C2=eS;j.nK=ah}else if($=="use"){var fL=m.l$(k);fL.concat(O);var jS=m.Ab(k),ie=w.getElementById(jS.slice(1));
if(ie){var ah=j.nK;j.nK=f;if(f.filter)ie.setAttribute("filter",f.filter);m.q2(w,[ie],W,fL,j,I,U+1,!0);
j.nK=ah}}else if($=="path"||$=="rect"||$=="circle"||$=="ellipse"||$=="polygon"||$=="polyline"||$=="line"){P.FK|=16;
P.add.vmsk=new h.Rd;P.add.vstk=JSON.parse(JSON.stringify(at.QO.default));P.add.vstk.strokeEnabled.v=!1;
var as=P.add.vstk,x=P.add.vmsk,gb=f.fill,gx=gb=="none"||f["fill-opacity"]&&parseFloat(f["fill-opacity"])==0;
x.i=m.Pf(W,w,k,f["fill-rule"]=="evenodd",gx);E.P.c0(x.i,O);var di=E.P.b3(x.i),d0=f.stroke,e6=f["stroke-width"],dt=f["stroke-dasharray"],gJ=f["stroke-linejoin"],iW=f["stroke-linecap"],g5=f["paint-order"];
if(d0==null||d0=="none"||d0=="null"){}else{var jW=m.axq(w,d0,O,di,W),eP=["SoFi","GrFl","patternFill"].indexOf(jW.type),b_=jW.Z.v.Opct.v,j3=1;
if(b_.val!=100){P.opacity=Math.round(P.opacity*b_.val/100);b_.val=100}var fZ=[at.Oa,at.Ki,at.v7][eP],im=as.strokeStyleContent.v={classID:at.QO.W_[eP]};
for(var L=0;L<fZ.length;L++)im[fZ[L]]=jW.Z.v[fZ[L]];e6=e6?parseFloat(e6):1;if(g5&&g5.replace(/\s\s+/g," ").slice(0,11)=="stroke fill"){j3=2;
e6/=2}as.strokeEnabled.v=!0;if(gJ)as.strokeStyleLineJoinType.v.strokeStyleLineJoinType=at.QO.join[["miter","round","bevel"].indexOf(gJ)];
if(iW)as.strokeStyleLineCapType.v.strokeStyleLineCapType=at.QO.EZ[["butt","round","square"].indexOf(iW)];
as.strokeStyleLineWidth.v.val=e6*O.NW();as.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[j3];
as.strokeStyleOpacity.v.val=100*(f["stroke-opacity"]?parseFloat(f["stroke-opacity"]):1);if(dt!=null&&dt!="none")as.strokeStyleLineDashSet.v=ge.zW(dt.split(",").map(parseFloat),1/e6)}if(gx){P.add.vstk.fillEnabled.v=!1;
P.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}}}else{var jW=m.axq(w,gb,O,di,W),dr=null,c0=null;
if(jW.type=="SoFi"){dr="SoCo";c0=at.Oa}if(jW.type=="GrFl"){dr="GdFl";c0=at.Ki}if(jW.type=="patternFill"){dr="PtFl";
c0=at.v7}if(dr!=null){var b_=jW.Z.v.Opct.v;if(b_.val!=100){P.opacity=Math.round(P.opacity*b_.val/100);
b_.val=100}P.add[dr]={classID:"null"};for(var L=0;L<c0.length;L++){var z=c0[L];P.add[dr][z]=jW.Z.v[z]}}}var fM=Math.max(F,j.C2);
if(fM!=0)P.add.vmsk.C3=fM;P.hu();P.yb(W);W.C.push(P)}else if(($=="text"||$=="tspan")&&k.textContent!=""){I=m.l$(k,I);
var fL=I.clone(),d=0;fL.concat(O);fL.translate(A,0);if(k.children.length>0){var cB=m.Yz(k.children[0],j.awy);
for(var z in cB)if(l.indexOf(z)==-1)f[z]=cB[z]}var iI=f["xml:space"],jD=k.textContent;if(iI=="preserve")jD=jD.replace(/\t/g," ").replace(/\n/g," ");
if(C==null)P.nz(jD);P.add.lnsr="rend";P.add.TySh=hd._3(0,0);P.add.TySh.IA=new iB(0,0,100,100);P.add.TySh.D=fL.clone();
var j8=P.add.TySh._o;hd.KO(j8,0,jD);if($=="tspan")A+=s*jD.length*.5*fL.NW();var gb=f.fill,jG=f["font-weight"],i1=f["font-family"],bH=f["text-decoration"],d0=f.stroke,e6=f["stroke-width"],a_=f["dominant-baseline"];
if(a_=="text-before-edge")d=s;else if(a_=="middle")d=s/2;else if(a_=="hanging")d=s;if(d!=0)P.add.TySh.D.translate(0,d);
var aR=hd.tG(j8,0,1);if(gb&&gb!="none"){var r=CSS.mn(gb);aR.lJ.FillColor={Type:1,Values:[1,r.o/255,r.B/255,r.k/255]}}if(bH=="underline")aR.lJ.Underline=!0;
aR.lJ.FontSize=Math.round(s);hd.hI(aR,"LiberationSans");if(jG=="bold")hd.hI(aR,"LiberationSans-Bold");
if(i1){i1=i1.split(",")[0].trim();if(i1[0]=="\"")i1=i1.slice(1);if(i1[i1.length-1]=="\"")i1=i1.slice(0,i1.length-1);
var iY=i1+":"+(jG?jG:"normal"),gy={"'DejaVu Sans':normal":"DejaVuSans","'DejaVu Sans':bold":"DejaVuSans-Bold","'Nimbus Sans L':normal":"NimbusSanL-Reg","'Nimbus Sans L':bold":"NimbusSanL-Bol","Libre Franklin:300":"LibreFranklin-Light","Libre Franklin:400":"LibreFranklin-Regular","Libre Franklin:500":"LibreFranklin-Medium","Libre Franklin:600":"LibreFranklin-SemiBold","Libre Franklin:700":"LibreFranklin-Bold"};
if(gy[iY])hd.hI(aR,gy[iY]);else hd.hI(aR,i1)}if(f["text-anchor"])aR.ci.Justification=["start","end","middle"].indexOf(f["text-anchor"]);
hd.g0(j8,0,jD.length,aR);if(d0==null||d0=="none"){}else{var fn=JSON.parse(at.UR[at.order.indexOf("FrFX")]);
fn.Clr.v=E.M.lW(CSS.mn(d0));fn.Sz.v.val=Math.round(parseFloat(e6)*fL.NW());m.axe(P,"frameFXMulti",fn)}W.C.push(P)}else if($=="image"){var jS=m.Ab(k);
if(jS&&jS.slice(0,4)=="data"){var gr=jj.aL(jS),fs=gr,dQ=W.An(fs,P.getName(),0,0);dQ.FK=P.FK;P=dQ;var ep=P.rect.clone();
ep.x=ep.y=0;var b2=k.getAttribute("width"),eX=k.getAttribute("height");if(b2)ep.m=parseFloat(b2);if(eX)ep.n=parseFloat(eX);
var iz=m.l$(k);iz.concat(O);var en=E.p.Wx(ep).w;E.p.D(en,iz,en);P.add.SoLd.Trnf=y.wR.Hh(en);P.add.SoLd.nonAffineTransform=y.wR.Hh(en);
P.vr(W,!1);W.C.push(P)}}else console.log("unknown tag: "+$,k.children.length,k.textContent.length);if(G!=null){W.C.push(G);
U--}}};eB.axe=function(w,n,W){var D=w.add.lmfx;if(D==null){var D=w.add.lmfx=JSON.parse(at.default);for(var L=0;
L<at.order.length;L++)D[at.Pa[L]]={t:"VlLs",v:[]}}D[n].v.push({t:"Objc",v:W})};eB.Pf=function(w,n,W,D,j){var I=eB,U=[{type:6},{type:8,all:0}],M=W.tagName;
if(M=="use"){var m=I.Ab(W),l=n.getElementById(m.slice(1)),A=new eh;if(l.tagName!="rect")A=I.l$(l);A.concat(I.Xb(l));
U=I.Pf(w,n,l,D,j);E.P.c0(U,A)}else if(M=="path"){var g=W.getAttribute("d");if(g==null)return U;var k=Typr.U.SVGToPath(g);
U=E.p.oF({w:k.crds,F:k.cmds},D,j)}else if(M=="rect"){var $=W.getAttribute("rx"),C=I.l$(W),f=new ec(0,0);
I.lL("width",W,w,f,!0);I.lL("height",W,w,f,!1);U=E.P.AB.Rect(C.z2,C.EU,f.x,f.y,$?parseFloat($):0)}else if(M=="circle"||M=="ellipse"){var z=[0,0,0,0],s=["cx","cy","rx","ry","r"];
for(var L=0;L<5;L++){var O=W.getAttribute(s[L]);if(O){O=parseFloat(O);if(L<4)z[L]=O;else z[2]=z[3]=O}}U=E.P.AB.Po(z[0]-z[2],z[1]-z[3],2*z[2],2*z[3])}else if(M=="polygon"||M=="polyline"||M=="line"){var a;
if(M=="line")a=[W.getAttribute("x1"),W.getAttribute("y1"),W.getAttribute("x2"),W.getAttribute("y2")].map(parseFloat);
else a=W.getAttribute("points").trim().replace(/\s\s+/g," ").split(",").join(" ").split(" ").map(parseFloat);
U=E.P.AB.cX(a,0,M!="polygon")}return U};eB.i3=function(w,n){if(w.charAt(w.length-1)=="m")return n*parseFloat(w.slice(0,w.length-2));
else return parseFloat(w)};eB.axq=function(w,n,W,D,j){var I,U,M=eB,m=JSON.parse(at.UR[at.order.indexOf("SoFi")]),l=n!=null?n.indexOf("("):-1;
if(l!=-1){var A=n.indexOf(")"),g=n.slice(0,l).trim(),k=n.slice(l+1,A).trim();if(k.charAt(0)=="'")k=k.slice(1,k.length-1);
if(g=="url"){if(k.charAt(0)=="#"){var $=w.getElementById(k.slice(1));if($&&$.tagName.toLowerCase().endsWith("gradient")){var C=M.E1(w,$,W,D);
I="GrFl";U={t:"Objc",v:C}}else if($&&$.tagName.toLowerCase()=="pattern"&&$.children[0]&&$.children[0].tagName=="use"){I="SoFi";
U={t:"Objc",v:m};var f=$.children[0],z=M.Xb(f),s=M.Ab(f),O=w.getElementById(s.slice(1)),a=jj.aL(M.Ab(O)).buffer,X=jj.ZO(jj.zJ(a)),P=X.Vu(a)[0],Z={};
Z.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";Z.name="someImage";Z.HY=[new Uint8Array(P.data),P.XL];j.qn(Z);
var m=JSON.parse(at.UR[at.order.indexOf("patternFill")]);m.Scl.v.val=Math.round(100*D.m*z.dl);var Y=m.phase.v;
Y.Hrzn.v=Math.round(D.x+z.z2*D.m);Y.Vrtc.v=Math.round(D.y+z.EU*D.n);m.Ptrn.v.Idnt.v=Z.id;I="patternFill";
U={t:"Objc",v:m}}else{I="SoFi";U={t:"Objc",v:m}}}else console.log("unknown url",k)}else if(g=="rgb"||g=="rgba"){I="SoFi";
U={t:"Objc",v:m};U.v.Clr.v=E.M.lW(CSS.mn(n));if(g=="rgba")U.v.Opct.v.val=Math.round(100*parseFloat(n.split(",").pop()))}else console.log("unknown fill",n)}else{I="SoFi";
U={t:"Objc",v:m};var K=CSS.mn(n);U.v.Clr.v=E.M.lW(K);if(K.dl!=null)U.v.Opct.v.val=Math.round(100*K.dl/255)}return{type:I,Z:U}};
eB.Xb=function(w){var n=new eh,W=w.getAttribute("transform");if(W)n=eB.zK(W);var D=w.getAttribute("style");
if(D!=null){var j={};eB.OU(j,D,["transform"]);D=j.transform;if(D)n.concat(eB.zK(D))}return n};eB.l$=function(w,n){var W=new eh,D=w.getAttribute("x"),j=w.getAttribute("y");
if(D)W.z2=parseFloat(D);else if(n)W.z2=n.z2;if(j)W.EU=parseFloat(j);else if(n)W.EU=n.EU;return W};eB.zK=function(w){var n=Typr.U.SVG.readTrnf(w);
return new eh(n[0],n[1],n[2],n[3],n[4],n[5])};eB.Yz=function(w,n){var W={},D="fill-rule fill stroke stroke-width stroke-dasharray stroke-opacity stroke-linejoin stroke-linecap font-size font-weight font-family text-decoration text-anchor dominant-baseline stop-color stop-opacity filter display opacity fill-opacity paint-order clip-path mix-blend-mode xml:space".split(" ");
for(var L=0;L<D.length;L++){var j=w.getAttribute(D[L]);if(j!=null&&j!="inherit")W[D[L]]=j}var I=w.getAttribute("class");
if(n!=null&&I!=null&&n["."+I]!=null)eB.OU(W,n["."+I],D);var U=w.getAttribute("id");if(n!=null&&U!=null&&n["#"+U]!=null)eB.OU(W,n["#"+U],D);
var M=w.getAttribute("style");if(M!=null)eB.OU(W,M,D);return W};eB.OU=function(w,n,W){n=n.trim().split(";");
for(var L=0;L<n.length;L++){var D=n[L].split(":"),j=D[0]?D[0].trim():"",I=D[1]?D[1].trim():"";for(var U=0;
U<W.length;U++)if(j==W[U]&&I!="inherit")w[W[U]]=I}};eB.Ab=function(w){var n=w.getAttribute("xlink:href");
if(n==null)n=w.getAttribute("href");if(n==null)n=w.getAttribute("xl:href");return n};eB.lL=function(w,n,W,D,j){var I=n.getAttribute(w);
if(I==null)return;var U=parseFloat(I);if(I.endsWith("%"))U*=(j?W.m:W.n)/100;if(j)D.x=U;else D.y=U};eB.E1=function(w,n,W,D){var j=eB,I=j.lL,U=new eh,M=n.getAttribute("gradientTransform"),$=!1;
if(M)U=j.zK(M);U.concat(W);var m=JSON.parse(at.UR[at.order.indexOf("GrFl")]),l=m.Grad.v;l.Intr.v=0;var A=n.tagName,g=new ec(0,0),k=new ec(D.m,0);
if(A=="linearGradient"){m.Type.v.GrdT="Lnr";I("x1",n,D,g,!0);I("y1",n,D,g,!1);I("x2",n,D,k,!0);I("y2",n,D,k,!1);
g.x=k.x+.5*(g.x-k.x);g.y=k.y+.5*(g.y-k.y)}if(A=="radialGradient"){m.Type.v.GrdT="Rdl";if(n.getAttribute("cx"))g.x=parseFloat(n.getAttribute("cx"));
if(n.getAttribute("cy"))g.y=parseFloat(n.getAttribute("cy"));k.y1(g.x,g.y);if(n.getAttribute("r"))k.x+=parseFloat(n.getAttribute("r"))}var C=n;
while(!0){if(C.getAttribute("gradientUnits")=="userSpaceOnUse")$=!0;var f=j.Ab(C);if(f==null)break;C=w.getElementById(f.slice(1))}if($){g=U.bj(g);
k=U.bj(k)}else{g.x=D.x+g.x*D.m;g.y=D.y+g.y*D.n;k.x=D.x+k.x*D.m;k.y=D.y+k.y*D.n}E.M.n0(g,k,D,m);var z=n.children;
if(z.length==0){var s=j.Ab(n);if(s==null)throw"gradient has no stops";var O=w.getElementById(s.slice(1));
if(O==null){console.log(s.slice(1))}else{var a=j.E1(w,O,U,D);m.Grad=a.Grad}}else{var X=[];for(var L=0;
L<z.length;L++){var P=z[L],Z=j.Yz(P),Y=Z["stop-color"],K=Z["stop-opacity"],S=P.getAttribute("offset");
if(Y==null)Y="#000000";K=K==null?1:parseFloat(K);var G=S?parseFloat(S):0;if(S&&S.endsWith("%"))G/=100;
Y=CSS.mn(Y);if(Y.dl!=null)K*=Y.dl/255;X.push([G,[Y.o/255,Y.B/255,Y.k/255],parseFloat(K)])}E.M.WP(X,l)}return m};
eB.z8=function(){var w=null,n=null,W="",D="";function j(Y,K,S){var G=[],x=" { ",v=" } ",N=!1;n=K;D=K.Qp?"":"\t";
W=K.Qp?"":" ";var V=K.adW,T=K.al4;G.push("<svg version=\"1.2\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 "+Y.m+" "+Y.n+"\" width=\""+V+"\" height=\""+T+"\">");
if(!K.Qp)G.push(I(1)+"<title>"+O(Y.name.split(".")[0])+"</title>");var R={xV:[],xq:[],dO:0,vt:0,WZ:0,R8:{},mX:{},Cm:0,GM:{},adE:{},Qm:0,hY:[]};
C(Y,R,Y.root.children,1,K,S);if(R.xV.length!=0){G.push(I(1)+"<defs>");G=G.concat(R.xV);G.push(I(1)+"</defs>")}G.push(I(1)+"<style>");
if(K.Qp){x="{";v="}"}for(var L=0;L<Y.C.length;L++)if(Y.C[L].add.TySh)N=!0;if(N&&!K.ax1&&!K.aaK)G.push(I(2)+"tspan"+x+"white-space:pre"+v);
for(var u in R.GM)G.push(I(2)+"."+u+x+R.GM[u]+v);G.push(I(1)+"</style>");G=G.concat(R.xq);G.push("</svg>");
G=G.join(K.Qp?"":"\n");return J.zY(G)}function I(bK){var Y="";for(var L=0;L<bK;L++)Y+=D;return Y}function U(bK,Y){if(Y==null)Y=1;
var K=""+parseFloat(bK.toFixed(Y));if(K.startsWith("0."))K=K.slice(1);return K}function M(Y,K){var S=Y.add.lmfx;
if(S)S=S[K].v[0];if(S)S=S.v;if(S&&!S.enab.v)S=null;return S}function m(Y,K){var S=M(Y,"frameFXMulti");
if(S){var G=S.Sz.v.val;if(S.Styl.v.FStl=="OutF"){K.push("paint-order:stroke fill markers");G*=2}$(K,CSS.JQ(S.Clr.v),1);
if(G!=1)K.push("stroke-width: "+G);K.push("stroke-linejoin: round;")}}var l="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ".split("");
function A(Y){var K=l.length,S="";for(var G=1;G<10;G++){var V=(K-10)*~~Math.pow(K,G-1);if(Y<V){for(var L=0;
L<G;L++){var T=L==G-1?10:0,R=K-T,x=Y%R;S=l[x+T]+S;Y=Math.floor((Y-x)/R)}break}Y-=V}return S}function g(Y,K,S,G){if(Y.length!=0){if(G==null)G="s";
var V=Y.join(";"),T=K.adE[V];if(T==null){T=n.Qp?A(K.Qm):G+K.Qm;K.Qm++;K.adE[V]=T;K.GM[T]=V}if(S)S.push(T);
return T}}function k(Y){if(n.Qp&&Y.length==7&&Y[0]=="#"){if(Y[1]==Y[2]&&Y[3]==Y[4]&&Y[5]==Y[6])Y="#"+Y[1]+Y[3]+Y[5]}return Y}function $(Y,K,S){K=k(K);
if(K!="#000"||S==1)Y.push((S==0?"fill:":"stroke:")+W+K)}function C(Y,K,S,G,V,T){var R=!1;for(var x=0;
x<S.length;x++){var v=S[x].j,N=v.add.lsct;if(!v.QY&&S[x+1]&&S[x+1].j.QY&&v.I9()&&v.add.vmsk){var u=[];
X(v,v.add.vmsk,K,u);K.xq.push(I(G)+"<g "+u[0]+">");G++;R=!0}else if(!v.QY&&S[x-1]&&S[x-1].j.QY&&R){G--;
K.xq.push(I(G)+"</g>");R=!1}var H=v.add.vmsk,F=v.add.vogk,t=v.add.vstk,o=v.add.TySh;if(H&&!H.isEnabled)H=t=null;
var q=[];if(!V.hidden&&!v.I4())continue;var _=v.opacity/255,d=v.add.iOpa?v.add.iOpa/255:1;if(v.ue()){_*=d;
d=1}if(_!=1)q.push("opacity:"+W+U(_));if(d!=1)q.push("fill-opacity:"+W+U(d));if(v.Bx!="norm"){var r=dD.R3[dD.mS.indexOf(v.Bx)];
if(r!=null)q.push("mix-blend-mode:"+W+r)}if(!v.I4())q.push("display:"+W+"none");var u=[],p=[],Q=v.getName(),B=Q.indexOf(" .");
if(!V.Qp)u.push("id=\""+O(Q)+"\"");var i=ge.mw(v.add.lmfx,v.add),c=i[0],h2=i[1];if(v.ue()){var jX=S[x].children;
if(!(jX.length==1&&jX[0].j.add.SoLd&&!V.kL)){if(w&&v.getName().split("-").length==3){w.push({I6:v.getName(),_W:0,H3:[]})}X(v,H,K,u);
if(q.length!=0)u.push("style=\""+q.join(";")+"\"");var bm=s(u,p),dC=V.Qp&&bm=="";if(!dC)K.xq.push(I(G)+"<g"+(bm==""?"":" "+bm)+">");
C(Y,K,jX,G+1,V,T);if(!dC)K.xq.push(I(G)+"</g>")}}else if(v.I9()&&H==null){var fn=new iB(0,0,Y.m,Y.n);
P(Y,q,v.add,K,fn,V);if(q.length!=0)u.push("style=\""+q.join(";")+"\"");K.xq.push(I(G)+"<rect width=\""+Y.m+"\" height=\""+Y.n+"\" "+s(u,p)+"/>")}else if(H&&v.add.SoLd==null){var fn=E.P.b3(H.i,null,!0),fK,i6=null,dh=0,kA;
P(Y,q,v.add,K,fn,V);g(q,K,p);if(F.length!=0){fK=F[0].v;i6=fK.keyOriginType;if(i6)i6=i6.v;if(i6==2){var ig=E.X.uy(fK);
dh=ig[0];for(var L=0;L<3;L++)if(dh!=ig[L+1])i6=null}}if(F.length==1&&i6==5&&Math.abs(E.X.VW(fK))<1e-4){var fn=E.X.O5(fK),iJ=(fn[0]+fn[2])/2,fL=(fn[1]+fn[3])/2,fB=iJ-fn[0],ah=fL-fn[1],eS=Math.abs(fB-ah)<.01,gL=eS?"r=\""+U(fB)+"\"":"rx=\""+U(fB)+"\" ry=\""+U(ah)+"\"";
kA="<"+(eS?"circle":"ellipse")+" "+s(u,p)+" cx=\""+U(iJ)+"\" cy=\""+U(fL)+"\" "+gL+"/>"}else if(F.length==1&&i6==2&&dh!=0&&Math.abs(E.X.VW(fK))<1e-4){var fn=E.X.O5(fK),e_=fn[0],c2=fn[1],jS=fn[2]-fn[0],ie=fn[3]-fn[1],as="";
if(e_!=0)as+=" x=\""+U(e_)+"\"";if(c2!=0)as+=" y=\""+U(c2)+"\"";as+=" width=\""+U(jS)+"\"";as+=" height=\""+U(ie)+"\"";
as+=" rx=\""+U(dh)+"\"";kA="<rect "+s(u,p)+as+"></rect>"}else{var gb=E.P.BK(H.i,1);if(gb.M0!=0){u.push("fill-rule=\"evenodd\"")}kA="<path "+s(u,p)+" d=\""+gb.VN+"\"/>"}K.xq.push(I(G)+kA);
if(w&&w[w.length-1]){var gx=E.p.xH(H.i);gx.w=gx.w.map(Math.round);var di=w[w.length-1];di._W+=JSON.stringify(gx).length;
di.H3.push([q[0].split("#").pop(),gx])}}else if(o&&V.ax1){W=V.Qp?"":" ";var d0=o._o,e6=new d2(d0,T),dt=null;
if(c)dt=CSS.JQ(c.Clr.v);if(h2){var fn=v.rect.clone();Z(h2,K,fn,V);dt="url(#g"+K.dO+")"}if(dt)q.push("fill:"+W+dt);
m(v,q);var gJ=aj.wh(e6,o),iW=E.p.e7(gJ);for(var g5 in iW){var jW=q.slice(0),eP=p.slice(0),b_=u.slice(0);
if(dt==null){$(jW,g5.slice(0,7),0);if(g5.length>7){var fZ=g5.slice(7).split("-");console.log(fZ);$(jW,fZ[1],1);
if(fZ[2]!="1")jW.push("stroke-width:"+W+fZ[2])}}g(jW,K,eP);var im=iW[g5],fZ=Typr.U.pathToSVG({crds:im.w,cmds:im.F},1);
K.xq.push(I(G)+"<path "+s(b_,eP)+(V.Qp?"":" "+z(o))+" d=\""+fZ+"\"/>")}}else if(o&&!V.aaK){var d0=o._o,j3=o.D.clone(),dt=null;
q.push("transform:"+W+a(j3));var dr=hd.Bb(d0),e6=new d2(d0,T);m(v,q);if(q.length!=0)u.push("style=\""+q.join(";")+"\"");
K.xq.push(I(G)+"<text "+s(u,p)+" >");if(c)dt=CSS.JQ(c.Clr.v);if(h2){var fn=v.rect.clone();fn.x-=j3.z2;
fn.y-=j3.EU;Z(h2,K,fn,V);dt=" url(#g"+K.dO+")"}for(var L=0;L<e6.ci.length;L++){var c0=e6.ci[L];if(c0.yr.length==1&&c0.yr[0].xS)continue;
for(var fM=0;fM<c0.Uv.length;fM++){var cB=c0.Uv[fM],fL=c0.zt.y+cB.zt.y,iI=c0.yr[cB.start].start,jD=c0.yr[cB.end-1].end,j8=hd.aw7(d0,iI,jD),jG="";
for(var i1=0;i1<j8.length;i1++){var bH=e6.ic(iI),a_=j8[i1],aR=hd.tG(d0,iI,iI),iY=aR.JO[aR.lJ.Font].Name,g5=hd.y_(aR.lJ.FillColor),gy=Math.round(aR.lJ.FontSize),gr=dr.slice(iI,iI+a_);
if(aR.lJ.FontCaps==2)gr=gr.toUpperCase();var fs=new eh;fs.translate(bH.WH.x,-fL);var dQ=[];CSS.a0Y(dQ,aR,null,!0,!0,dt);
var ep=g(dQ,K,null,"t");ep=ep?" class=\""+ep+"\"":"";var iJ=bH.WH.x,b2=f(aR,gr);jG+="<tspan "+(i1==0?"x=\""+U(bH.WH.x)+"\"":"")+" y=\""+U(fL)+"\""+ep+b2+">"+O(gr)+"</tspan>";
iI+=a_}K.xq.push(I(G+1)+jG)}}K.xq.push(I(G)+"</text>")}else if(v.add.SoLd&&V.kL&&c==null){var eX=v.add.SoLd,iz=eX.Idnt.v,en=0,ko=eX.Crop?eX.Crop.v:null;
if(K.mX[iz]!=null)en=K.mX[iz];else{K.Cm++;en=K.Cm;K.mX[iz]=K.Cm;var fh=Y.Zy(iz,ko),h9="";if(fh==null)return;
var d1=fh.PO,j_=jj.zJ(fh.raw.buffer);if(j_=="pdf"){var ha=new kc("h");jj.ZO("PDF").Vu(fh.raw.buffer,ha);
ha.X0();ha.hd();ha.l();ha.tw();if(eX.Crop&&eX.Crop.v==1){y.QJ.Ov(ha,ha.root.pJ(ha,!0))}var fl=jj.ZO("SVG").La(ha,ha.m,ha.n,null,{hY:T});
h9="data:image/svg+xml;base64,"+jj.Da(fl)}else if(j_=="jpg"||j_=="png"||j_=="gif"||j_=="svg"){var ex={jpg:"image/jpg",png:"image/png",jpg:"image/jpg",svg:"image/svg+xml"};
h9="data:"+ex[j_]+";base64,"+jj.Da(fh.raw.buffer)}else{h9=jj.Zz(d1[0].buffer,d1[1].m,d1[1].n)}K.xV.push(I(2)+"<image width=\""+d1[1].m+"\" height=\""+d1[1].n+"\" id=\"img"+en+"\" href=\""+h9+"\"/>")}var aI=E.K.ce(eX),ba=[];
X(v,H,K,ba);if(ba.length!=0)K.xq.push(I(G)+"<g "+s(ba,p)+">");if(q.length!=0)u.push("style=\""+q.join(";")+"\"");
var ik=s(u,p);K.xq.push(I(G)+"<use "+ik+" href=\"#img"+en+"\" transform=\""+a(aI)+"\"/>");if(ba.length!=0)K.xq.push(I(G)+"</g>")}else if(!v.rect.VY()&&(V.kL||o)){if(q.length!=0)u.push("style=\""+q.join(";")+"\"");
var ik=s(u,p),c3=v.buffer;if(c)c3=ge.a2b(c3,c,v.rect);var br=v.rect;K.Cm++;var h9=jj.Zz(c3.buffer,br.m,br.n,"png",null,!0);
K.xV.push(I(2)+"<image "+z(o)+" width=\""+v.rect.m+"\" height=\""+v.rect.n+"\" id=\"img"+K.Cm+"\" href=\""+h9+"\"/>");
K.xq.push(I(G)+"<use "+ik+" href=\"#img"+K.Cm+"\" x=\""+br.x+"\" y=\""+br.y+"\"/>")}}if(R){G--;K.xq.push(I(G)+"</g>");
R=!1}}function f(Y,K){var S=Y.lJ.Tracking,G="";if(S!=null&&S!=0){S=Math.round(S*Y.lJ.FontSize/1e3);G=" dx=\"0";
for(var V=1;V<K.length;V++)G+=" "+S;G+="\" "}return G}function z(Y){if(Y==null)return"";var K=Y._o,S=hd.Bb(K);
S=O(S.slice(0,S.length-1));return"aria-label=\""+S+"\" "}function s(Y,K){if(K.length!=0)Y.push("class=\""+K.join(" ")+"\"");
return Y.join(" ")}function O(Y){return String(Y).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\u0022/g,"&quot;")}function a(Y){var K=[Y.dl,Y.k,Y.Cj,Y.j7,Y.z2,Y.EU];
for(var L=0;L<6;L++)K[L]=U(K[L],3);return"matrix("+K.join(",")+")"}function X(Y,K,S,G){if(K||Y.add.artb){var V;
if(K)V=E.P.BK(K.i).VN;else{var T=Y.yP(),R=E.p.Wx(T);V=Typr.U.pathToSVG({crds:R.w,cmds:R.F},1)}S.WZ++;
G.push("clip-path=\"url(#cp"+S.WZ+")\"");S.xV.push(I(2)+"<clipPath clipPathUnits=\"userSpaceOnUse\" id=\"cp"+S.WZ+"\">");
S.xV.push(I(3)+"<path d=\""+V+"\"/>");S.xV.push(I(2)+"</clipPath>")}}function P(Y,K,S,G,V,T){var R=S.vstk,x=S.vmsk,v=S.lmfx,N=[];
if(x&&x.C3!=0){var u=U(x.C3);if(G.R8[u]==null){G.vt++;G.R8[u]=G.vt;G.xV.push(I(2)+"<filter x=\"-50%\" y=\"-50%\" width=\"200%\" height=\"200%\" id=\"f"+G.vt+"\"> <feGaussianBlur stdDeviation=\""+u+"\"/> </filter>")}N.push("url(#f"+G.R8[u]+")")}if(v)for(var L=0;
L<at.order.length;L++){var H=at.order[L],F=at.Pa[L],t=v[F].v;for(var o=0;o<t.length;o++){var q=t[o].v,_=q.classID;
if(!q.enab.v)continue;if(_=="OrGl"||_=="DrSh"){G.vt++;N.push("url(#f"+G.vt+")");var d=0,r=0,p=q.blur.v.val/2.4,Q=q.Opct.v.val/100;
if(_=="DrSh"){var B=q.uglg&&q.uglg.v?Y.d4():q.lagl.v.val;B=B*(Math.PI/180);var i=q.Dstn.v.val;d=-Math.cos(B)*i;
r=Math.sin(B)*i}if(_=="OrGl")Q/=q.Inpr.v.val/100;var c="<filter x=\"-50%\" y=\"-50%\" width=\"200%\" height=\"200%\" id=\"f"+G.vt+"\" >";
c+="<feDropShadow dx=\""+d+"\" dy=\""+r+"\" stdDeviation=\""+p+"\" flood-color=\""+CSS.JQ(q.Clr.v)+"\" flood-opacity=\""+U(Q)+"\"/>";
c+="</filter>";G.xV.push(I(2)+c)}}}if(N.length!=0)K.push("filter:"+W+N.join(" "));var h2=ge.mw(v,S),jX=h2[0],bm=h2[1];
if(R&&!R.fillEnabled.v)K.push("fill:"+W+"none");else if(jX){var dC=CSS.JQ(jX.Clr.v);$(K,dC,0)}else if(bm){Z(bm,G,V,T);
$(K,"url(#g"+G.dO+")",0)}if(R==null||!R.strokeEnabled.v)R=ge.Qk(v);if(R&&R.strokeEnabled.v){var fn=R.strokeStyleContent.v,fK=fn.classID;
if(fK=="solidColorLayer")$(K,CSS.JQ(fn.Clr.v),1);else{Z(fn,G,V,T);$(K,"url(#g"+G.dO+")",1)}var i6=at.QO.EZ.indexOf(R.strokeStyleLineCapType.v.strokeStyleLineCapType),dh=at.QO.join.indexOf(R.strokeStyleLineJoinType.v.strokeStyleLineJoinType),kA=R.strokeStyleOpacity.v.val/100,ig=R.strokeStyleLineWidth.v.val,iJ=at.QO.n2.indexOf(R.strokeStyleLineAlignment.v.strokeStyleLineAlignment);
if(iJ==2){ig*=2;K.push("paint-order:stroke fill markers")}var fL=R.strokeStyleLineDashSet.v,fB=[];for(var L=0;
L<fL.length;L++)fB.push(Math.round(fL[L].v.val*ig));if(i6!=0)K.push("stroke-linecap:"+W+["butt","round","square"][i6]);
if(dh!=0)K.push("stroke-linejoin:"+W+["miter","round","bevel"][dh]);if(kA!=1)K.push("stroke-opacity:"+W+U(kA));
if(ig!=1)K.push("stroke-width:"+W+U(ig));if(fB.length!=0)K.push("stroke-dasharray:"+W+fB.join(","))}}function Z(Y,K,S,G){K.dO++;
var V=Y.Grad.v,T=JSON.parse(JSON.stringify(V.Clrs.v)),R=JSON.parse(JSON.stringify(V.Trns.v)),x=Y.Ofst.v,v=Y.Type.v.GrdT,N=v=="Rdl"||v=="Dmnd"?1:0,u=(N==1?"radial":"linear")+"Gradient",H=E.M.Du(Y,S),t="";
if(N==0){H[0].x=H[1].x+2*(H[0].x-H[1].x);H[0].y=H[1].y+2*(H[0].y-H[1].y)}var F=I(2)+"<"+u+" id=\"g"+K.dO+"\"";
if(G.Qp){if(K.dO==1)K.xV.push("<linearGradient id=\"P\" gradientUnits=\"userSpaceOnUse\"/>");t=" href=\"#P\""}else t=" gradientUnits=\"userSpaceOnUse\"";
if(N==0)K.xV.push(F+" x1=\""+U(H[0].x)+"\" y1=\""+U(H[0].y)+"\" x2=\""+U(H[1].x)+"\" y2=\""+U(H[1].y)+"\""+t+">");
if(N==1)K.xV.push(F+" cx=\""+U(H[0].x)+"\" cy=\""+U(H[0].y)+"\" r=\""+U(ec.cS(H[0],H[1]))+"\""+t+">");
var o=Y.Rvrs.v,q=E.M.P$(V,o);for(var L=0;L<q.length;L++){var _=q[L],d=_[0],r=_[1],p=_[2];p=p==1?"":" stop-opacity=\""+U(p)+"\"";
var Q=d==0&&G.Qp?"":" offset=\""+U(d)+"\"",B=CSS.Dg({o:r[0]*255,B:r[1]*255,k:r[2]*255});B=G.Qp&&B=="#000000"?"":" stop-color=\""+k(B)+"\"";
K.xV.push(I(3)+"<stop"+Q+B+p+"/>")}K.xV.push(I(2)+"</"+u+">")}eB.LN=a;return j}();eB.AB=function(w,n,W,D,j){var I=[],U=eB.AB,M=!1,m={gA:w,ag:n,bK:[!0,!0,!0],I2:!1,Ur:W,az6:0};
m.$g=Math.round(Math.max(w,n)*(.02+U.NH(m)*.03));m.Rk=U.ae3(m);m.DK=U.aj3(m.Rk,(U.NH(m)<.5?-1:1)*(.2+U.NH(m)*.3));
if(U.NH(m)<.5){var l=m.Rk;m.Rk=m.DK;m.DK=l}m.avK=U.NH(m)<.4&&U.av2(m.DK,{o:1,B:1,k:1})>.3;m.a8w=U.NH(m)<.5?0:1;
I.push("<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 "+w+" "+n+"\" width=\""+w+"\" height=\""+n+"\">");
m.Sn=D[Math.floor(U.eX(m)*D.length)];m.rh=D[Math.floor(U.eX(m)*D.length)];I.push("<style>");I.push("@font-face { font-family: "+m.Sn[2]+"; src: url(rsrc/fonts/"+m.Sn[5]+"); }");
I.push("@font-face { font-family: "+m.rh[2]+"; src: url(rsrc/fonts/"+m.rh[5]+"); }");I.push("</style>");
var A=[0,0,w,n],g=A;if(j==null)I.push("<path style=\"fill: "+U.Mz(m.Rk)+"\" d=\""+U.Rect(A[0],A[1],A[2]-A[0],A[3]-A[1])+"\" id=\"Background\" />");
else{m.I2=!0;U.ata(m,A,I,j)}if(U.NH(m)<.25&&!m.I2){m.bK[0]=m.bK[2]=!1;U.af5(A,m,I);g=A}else if(U.NH(m)<.25||m.I2)g=A;
else{var k=.52+U.NH(m)*.2;if(U.NH(m)<.5)k=1-k;var $=A.slice(0),C=A.slice(0);if(U.NH(m)<.5)$[2]=C[0]=Math.round(k*w);
else $[3]=C[1]=Math.round(k*n);if(U.NH(m)<.5){var l=$;$=C;C=l}g=$;U.aeB(m,C,I,j)}U.a0_(m,g,I);I.push("</svg>");
I=I.join("\n");var f=E.Q(Math.round(I.length*1.5)),z=J.Dj(I,f,0);return[f.buffer.slice(0,z),m.p0]};eB.AB.af5=function(w,n,W){var D=eB.AB,j=w[2]-w[0],I=w[3]-w[1];
if(D.NH(n)<.5){W.push("<path id=\"Border\" style=\"fill: "+D.Mz(n.DK)+"\" d=\""+D.aeq(w[0],w[1],w[2]-w[0],w[3]-w[1],n.$g)+"\" />")}else if(D.NH(n)<-.4){D.auN(n,w,W)}else{var U=D.NH(n)<.5?0:1,M=(U==0?I:j)/4,m=D.wC(n,U,w,W,M,!0),m=D.wC(n,U+2,w,W,M,!0,m)}};
eB.AB.a0_=function(w,n,W){var D=eB.AB,j="Hello World!-What a beautiful day.-What Is Love?-Baby, don't hurt me.-Is This a Real Life?-Is this a fantasy?-Wake Me Up!-Before you go go.-I Saw The Sign.-And it opened up my mind!".split("-"),I=2*Math.floor(D.NH(w)*j.length/2),U=n[2]-n[0],M=n[3]-n[1],l=0,g=0;
w.aM=(w.gA+U)*.5*(.04+D.NH(w)*.05);w.aM=Math.min(w.aM,M*.4,U*.12);w.aM=Math.round(w.aM);var m=Math.min(w.aM*j[I].length*(.35+.3*D.NH(w)),U*.9),A=(n[1]+n[3])/2,k=E.Mg(w.Rk)<.85?{o:1,B:1,k:1}:{o:.1,B:.1,k:.1};
if(D.NH(w)<.25&&w.bK[0]){g=0;l=n[0]+w.$g}else if(D.NH(w)<.33&&w.bK[2]){g=2;l=n[2]-w.$g}else{g=1;l=(n[0]+n[2])/2}var $=k.o==1?"0,0,0":"255,255,255",C=w.I2&&D.NH(w)<1;
if(C){var f=n[0],z=U,s=A-w.aM*1.1,O=w.aM*2.2,a=.7;if(g==1&&D.NH(w)<.5){f=s=.2*Math.min(U,M);z=U-2*s;
O=M-s-s}else if(D.NH(w)<.7){f=s=0;z=U;O=M;a=.25}W.push("<path id=\"Strip\" style=\"fill: rgb("+$+"); opacity: "+a+"\" d=\""+D.Rect(f,s,z,O)+"\" />")}if(D.NH(w)<.4){var X=w.aM*.07;
X*=1.5+D.NH(w)*1;if(g==-1&&U/M<3&&!C){W.push("<path id=\"Bar-bottom\" style=\"fill: "+D.Mz(k)+"\" d=\""+D.Rect(l-m/2,A+w.aM*1.1-X/2,m,X)+"\" />");
W.push("<path id=\"Bar-top\" style=\"fill: "+D.Mz(k)+"\" d=\""+D.Rect(l-m/2,A-w.aM*1.1-X/2,m,X)+"\" />")}if(g!=1){W.push("<path id=\"Bar\" style=\"fill: "+D.Mz(k)+"\" d=\""+D.Rect(l-X/2,A-w.aM*.8,X,w.aM*.8*2)+"\" />");
l+=(g==0?1:-1)*w.aM/3}}var P=w.aM*.4;W.push(D.anR(j[I+1],l,A+P*1.6,P,k,g,w.rh));W.push(D.anR(j[I],l,A+w.aM*.04,w.aM,k,g,w.Sn))};
eB.AB.aeB=function(w,n,W,D){var j=n[2]-n[0],I=n[3]-n[1],U=Math.max(j,I),M=Math.min(j,I),m=eB.AB;if(U/M<5&&!w.I2&&!1){m.ata(w,n,W,D)}else if(m.NH(w)<0)W.push("<path style=\"fill: "+m.Mz(w.DK)+"\" d=\""+m.Rect(n[0],n[1],j,I)+"\" />");
else{var l=0;if(n[3]!=w.ag)l=0;if(n[2]!=w.gA)l=3;if(n[0]!=0)l=1;if(n[1]!=0)l=2;var A=l+2&3;if(U/M<3){var g=m.akV(A),k=g[Math.round(m.NH(w)*(g.length-1))],$=k.I6.slice(0,4),C=$.indexOf(1);
k=JSON.parse(JSON.stringify(k));var f=-1;if($!="0000"){var z=new eh;if(k.I6[5]=="0"){if(C==3&&l==1){f=1;
z.scale(-1,1)}else f=C}else{var s=A;while(s==A)s=Math.floor(m.NH(w)*4)&3;z.rotate((-C+s)*Math.PI/2)}m.D(k,z)}var O=m.mY(k),a=j-2*w.$g,X=I-2*w.$g;
if(f!=-1){if((f&1)==0)X-=w.$g;else a-=w.$g}var P=Math.min(a/O.m,X/O.n),Z=new eh;Z.translate(-O.x,-O.y);
Z.scale(P,P);var Y=(j-O.m*P)/2,K=(I-O.n*P)/2;if(f!=-1){if(f==3)Y=0;if(f==0)K=0;if(f==1)Y=j-O.m*P;if(f==2)K=I-O.n*P}Z.translate(n[0]+Y,n[1]+K);
m.IG(w,k,Z,w.DK,W)}else{m.wC(w,l,n,W,1e9)}}};eB.AB.ata=function(w,n,W,D){var j=n[2]-n[0],I=n[3]-n[1],U=Math.max(j,I),M=Math.min(j,I),m=eB.AB,l=m.eX(w),A,g,k,$=D[0]instanceof ArrayBuffer;
if($){A="data:image/jpg;base64,"+e8.vT(D[0]);g=D[1];k=D[2]}else{var C=Math.floor(l*D.length),f=D[C];
w.p0=f;A=f.webformatURL;g=f.webformatWidth;k=f.webformatHeight}var z=n[0],s=n[1],O=j,a=I;if(j/I>g/k){a=O*k/g;
s=s-(a-I)/2}else{O=a*g/k;z=z-(O-j)/2}if($){W.push("<defs>");W.push("<image width=\""+g+"\" height=\""+k+"\" id=\"Background\" href=\""+A+"\" />");
W.push("</defs>");var X=O/g;W.push("<use href=\"#Background\" transform=\""+eB.LN(new eh(X,0,0,X,z,s))+"\" />")}else{var P="cp"+Math.random();
W.push("<clipPath id=\""+P+"\">");W.push("<path style=\"fill: "+m.Mz(w.DK)+"\" d=\""+m.Rect(n[0],n[1],j,I)+"\" />");
W.push("</clipPath>");W.push("<image clip-path=\"url(#"+P+")\" xlink:href=\""+A+"\" x=\""+z+"\" y=\""+s+"\" width=\""+O+"\" height=\""+a+"\" />")}};
eB.AB.anR=function(w,n,W,D,j,I,U){var M=eB.AB;return"<text x=\""+n+"\" y=\""+W+"\" style=\"fill:"+M.Mz(j)+"; font-size:"+D+"px; text-anchor:"+["start","middle","end"][I]+"; font-family:"+U[2]+";\"><tspan>"+w+"</tspan></text>"};
eB.AB.IG=function(w,n,W,D,j){var I=eB.AB,U=[];for(var L=0;L<n.H3.length;L++){U.push(D);if(w.avK){D=(L&1)==w.a8w?{o:1,B:1,k:1}:U[0]}}j.push("<g id=\""+n.I6.split("-")[2]+":::\" style=\"transform: "+eB.LN(W)+";\" >");
for(var L=0;L<n.H3.length;L++){var M=n.H3[L];D=U.pop();j.push("<path style=\"fill: "+(D?I.Mz(D):"#"+M[0])+"\" d=\""+Typr.U.pathToSVG({crds:M[1].w,cmds:M[1].F})+"\" />")}j.push("</g>")};
eB.AB.auN=function(w,n,W){var D=eB.AB,j=eB.AB.sF,I=[];for(var L=0;L<j.length;L++){var U=j[L],M=U.I6.slice(0,4);
if(M!="1001")continue;I.push(U)}var U=I[Math.floor(D.NH(w)*I.length)];if(D.NH(w)<.5)D.D(U,new eh(0,1,1,0,0,0));
var m=n[3]-n[1],l=n[2]-n[0],A=D.mY(U),g=.7*Math.min(l,m,.5*Math.max(l,m))/Math.max(A.m,A.n),k=new eh;
k.scale(g,g);if(D.NH(w)<.5){k.scale(1,-1);k.translate(0,m)}D.IG(w,U,k,w.DK,W);k.rotate(Math.PI);k.translate(l,m);
D.IG(w,U,k,w.DK,W)};eB.AB.akV=function(w){var n=eB.AB.sF,W=[];for(var L=0;L<n.length;L++){var D=n[L],j=D.I6.slice(0,4);
if(j=="0000"){W.push(D);continue}if(["1000","0100","0010","0001"].indexOf(j)==-1)continue;var I=j.indexOf("1");
if(D.I6[5]=="0"&&w==I&&I!=3)continue;W.push(D)}return W};eB.AB.wC=function(w,n,W,D,j,I,U){var M=eB.AB.sF,m=eB.AB,l=[],O,a;
for(var L=0;L<M.length;L++){var A=M[L],g=A.I6.slice(0,4);if(["1110","1101","1011","0111"].indexOf(g)==-1)continue;
var k=g.indexOf("0")+2&3;if(A.I6[5]=="0")if(I==!0||n!=k&&!(n==1&&k==3))continue;l.push(A)}var $=U!=null?U:Math.floor(m.NH(w)*l.length),A=l[$],A=JSON.parse(JSON.stringify(A)),g=A.I6.slice(0,4),k=g.indexOf("0")+2&3;
if(k==3&&n==1)E.D(A,new eh(1,0,0,-1,0,1e3));var C=new eh;C.translate(-500,-500);C.rotate(-k*Math.PI/2);
C.translate(500,500);m.D(A,C);var f=W[3]-W[1],z=W[2]-W[0],s=m.mY(A);if(s.y<0){s.n+=s.y;s.y=0}if(s.y>0){s.n+=s.y;
s.y=0}if((n&1)==0){a=f;O=z}else{O=f;a=z}var X=Math.min(Math.min(.5+.5*m.NH(w))*Math.min(z,f),j)/s.n,P=Math.ceil(O/(1e3*X)),Z=new eh,Y=new eh;
Y.scale(X,X);if(n==0||n==2){Y.translate(-(z/2),-(f/2));Y.rotate(-n*Math.PI/2);Y.translate(z/2+W[0],f/2+W[1])}else{Y.rotate(Math.PI/2);
Y.scale(1,-1);Y.translate(W[0],W[1]);if(n==1){Y.scale(-1,1);Y.translate(z,0)}}D.push("<g id=\"Border-"+["top","right","bottom","left"][n]+":::\">");
for(var L=0;L<P;L++){var K=Z.clone();K.concat(Y);m.IG(w,A,K,w.DK,D);Z.translate(1e3-2,0)}D.push("</g>");
return $};eB.AB.Rect=function(w,n,W,D){return Typr.U.pathToSVG({crds:[w,n,w+W,n,w+W,n+D,w,n+D],cmds:["M","L","L","L","Z"]})};
eB.AB.aeq=function(w,n,W,D,j){var I=[w,n,w+W,n,w+W,n+D,w,n+D];w+=j;n+=j;W-=2*j;D-=2*j;I.push(w,n,w,n+D,w+W,n+D,w+W,n);
return Typr.U.pathToSVG({crds:I,cmds:"M L L L Z M L L L Z".split(" ")})};eB.AB.aj3=function(w,n){var W=E.AO(w.o,w.B,w.k);
W.EO=Math.max(.1,Math.min(.9,W.EO+n));return E.P4(W.ag,W._6,W.EO)};eB.AB.acI=function(w,n){var W=E.AO(w.o,w.B,w.k);
W.ag+=n;return E.P4(W.ag,W._6,W.EO)};eB.AB.a7I=function(w){var n=E.AO(w.o,w.B,w.k);n.EO=1-n.EO;return E.P4(n.ag,n._6,n.EO)};
eB.AB.av2=function(w,n){var W=w.o-n.o,D=w.B-n.B,j=w.k-n.k;return Math.sqrt(W*W+D*D+j*j)};eB.AB.ae3=function(w){var n=eB.AB;
return{o:n.NH(w),B:n.NH(w),k:n.NH(w)}};eB.AB.Mz=function(w){return CSS.Dg({o:w.o*255,B:w.B*255,k:w.k*255})};
eB.AB.mY=function(w){var n=w.H3,W=new iB;for(var L=0;L<n.length;L++)W=W.x0(E.p.mY(n[L][1].w));return W};
eB.AB.D=function(w,n){var W=w.H3;for(var L=0;L<W.length;L++)E.p.D(W[L][1].w,n,W[L][1].w)};eB.AB.NH=function(w){w.az6++;
var n=w.az6&3;if(n==0)w.Ur=eB.AB.yF(w.Ur);var W=w.Ur>>>8*n&255;return W*(.99999999/255)};eB.AB.eX=function(w){var n=eB.AB.yF(w.Ur);
w.Ur=eB.AB.yF(n);return n*(1/4294967295)};eB.AB.yF=function(w){w=(w^61^w>>>16)>>>0;w=w+(w<<3)>>>0;w=(w^w>>>4)>>>0;
w=w*668265261>>>0;w=(w^w>>>15)>>>0;return w};eB.AB.sF=[{I6:"0001-0-bird",H3:[["4b3c34",{F:"M C L C C L Z M C C L C C L Z M C L C L Z M C L C C L Z".split(" "),w:[208,16,253,5,247,86,228,104,218,108,253,60,235,12,211,18,210,18,209,17,208,16,208,16,187,140,238,125,326,133,319,189,318,198,307,210,299,207,297,205,307,208,316,195,317,188,320,126,208,137,174,149,187,140,137,75,156,79,177,94,164,157,173,147,177,101,165,79,142,75,137,75,368,59,165,59,182,233,0,210,0,225,161,250,194,61,364,63,367,61,368,59,368,59,368,59]}],["3c7040",{F:"M C C C C C L Z M C C C C L Z M C C C C L Z M C C C C L Z M C C C C C L Z M C C C C L Z M C C C C Z".split(" "),w:[345,123,324,113,331,70,284,80,287,79,310,89,314,103,314,104,306,90,284,82,281,81,270,85,268,86,274,117,335,119,345,123,345,123,270,0,283,29,282,58,244,66,258,62,265,40,269,27,265,37,256,56,249,58,242,31,263,18,270,0,270,0,89,100,81,136,47,182,101,196,90,189,92,157,91,145,94,160,93,191,109,195,148,158,96,129,89,100,89,100,230,187,201,240,160,226,133,198,150,191,172,197,187,198,166,193,153,190,134,193,159,162,207,194,230,187,230,187,126,177,131,159,129,150,119,139,122,122,145,112,147,97,166,128,164,155,134,168,139,154,146,142,145,131,143,145,133,159,126,177,126,177,209,86,195,86,166,91,173,109,177,102,181,97,191,96,180,99,174,113,175,113,194,114,200,96,209,86,209,86,278,175,254,167,235,168,231,143,245,143,248,151,256,158,252,147,243,144,240,142,276,147,265,171,278,175]}],["b588c1",{F:"M C C C C C C C C C C C C L Z".split(" "),w:[189,40,188,42,186,44,184,47,184,52,183,55,181,59,175,70,160,78,147,79,142,79,131,78,127,75,118,74,95,71,93,70,89,70,88,70,69,72,74,66,82,68,93,65,78,64,83,62,95,59,128,50,128,33,155,29,162,16,180,13,189,31,193,31,196,34,198,37,197,37,193,39,189,40,189,40]}]]},{I6:"0001-0-bird2",H3:[["ff7f2a",{F:"M L L L Z M L L L Z".split(" "),w:[296,0,296,62,335,62,296,0,357,0,357,62,318,62,357,0]}],["b588c1",{F:"M C C C C C C C C C C C L Z".split(" "),w:[321,48,344,48,379,67,396,121,408,176,396,230,337,255,303,265,265,268,217,235,191,217,170,188,186,180,195,177,199,187,205,192,203,185,199,178,207,172,217,165,224,178,225,182,227,196,231,203,250,206,273,205,290,196,292,165,289,133,269,118,268,101,267,77,288,49,321,48,321,48]}],["74439e",{F:"M C C C C C C L Z M C C Z".split(" "),w:[337,187,329,202,317,204,304,204,293,204,284,205,293,224,286,216,278,209,268,214,257,220,262,237,269,243,284,258,310,256,323,243,337,227,339,208,337,187,337,187,340,77,310,78,287,81,315,96,269,83,309,75,340,77]}],["000000",{F:"M L L L Z M L L L Z".split(" "),w:[326,258,334,315,323,316,326,258,298,262,296,318,286,317,298,262]}],["4b3c34",{F:"M L C C C C C C C C L Z".split(" "),w:[0,272,0,336,63,296,119,296,175,320,205,330,229,339,278,338,322,337,354,322,405,325,443,329,482,332,501,377,501,366,502,348,474,328,464,320,440,312,384,309,296,309,300,333,186,293,118,264,54,250,0,272,0,272]}],["3c7040",{F:"M C C C Z M C C C Z M C C C L Z M C C C L Z M C C C L Z M C C C Z".split(" "),w:[58,260,44,247,27,239,20,208,15,188,32,182,43,198,59,227,56,242,58,260,181,323,167,336,150,345,143,375,138,396,155,401,166,385,182,356,179,342,181,323,60,260,79,249,100,243,113,214,122,194,102,186,86,200,62,227,65,242,60,260,60,260,499,378,479,377,462,372,435,388,417,399,425,415,444,411,476,403,484,390,499,378,499,378,501,379,494,397,482,411,488,442,491,463,511,461,514,442,520,410,508,397,501,379,501,379,503,378,513,390,516,402,531,413,546,421,557,412,548,401,534,382,519,379,503,378]}]]},{I6:"0000-1-flower",H3:[["7a59a2",{F:"M C C C C C C C Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z".split(" "),w:[468,470,411,473,371,480,351,495,332,509,322,536,325,581,325,601,328,621,325,637,346,634,371,638,397,637,427,636,456,626,465,611,478,596,485,553,489,490,477,489,470,483,468,470,445,563,435,583,425,591,415,590,401,588,401,572,410,549,388,558,375,557,369,546,366,533,374,524,390,517,416,506,441,498,465,495,463,519,455,542,445,563,445,563,489,450,486,392,480,352,465,332,451,313,425,302,380,305,360,305,340,307,324,304,327,324,322,350,323,376,323,406,332,435,347,444,362,457,405,465,468,470,469,458,476,451,489,450,489,450,395,424,376,415,368,405,369,394,371,380,387,380,410,390,402,368,403,355,414,349,427,346,436,355,443,370,454,397,460,422,463,446,439,443,417,435,395,424,395,424,508,470,566,468,606,462,626,447,645,433,656,407,654,362,654,342,652,322,655,306,634,309,609,304,583,305,553,305,524,314,514,329,501,344,493,387,488,449,500,451,507,457,508,470,508,470,534,377,544,357,554,350,564,351,578,353,578,369,568,392,590,384,604,385,609,396,612,409,603,418,588,425,561,435,536,442,512,445,515,421,523,399,534,377,534,377,488,490,492,547,499,587,514,607,528,626,554,636,600,633,619,632,640,630,656,633,652,612,656,587,655,560,655,531,645,502,629,493,614,480,571,473,508,469,507,481,501,488,488,490,488,490,582,513,602,523,610,533,609,543,607,557,591,557,568,548,577,570,576,583,565,589,552,592,542,584,535,568,524,542,517,517,514,493,538,495,560,503,582,513,582,513]}]]},{I6:"0000-1-flower",H3:[["d13777",{F:"M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z".split(" "),w:[474,503,457,528,452,530,450,528,450,523,469,498,464,493,388,522,332,552,314,585,297,628,322,660,372,639,361,698,421,709,450,665,467,649,477,596,482,505,474,503,474,503,439,563,431,563,424,556,424,548,424,539,431,532,439,532,447,532,454,539,454,548,454,556,447,563,439,563,462,475,432,467,429,463,430,460,435,458,465,469,468,463,417,399,371,356,335,348,288,345,265,379,300,420,241,428,249,488,301,503,321,513,374,507,462,483,462,475,462,475,394,460,391,452,396,444,404,441,412,438,420,443,423,451,426,459,421,467,413,470,405,473,396,468,394,460,484,455,483,424,486,419,489,420,492,424,492,456,498,457,543,389,570,332,566,294,554,249,515,238,487,284,461,231,406,256,408,310,405,333,427,381,477,458,484,455,484,455,477,385,484,380,494,382,499,389,504,396,502,405,496,410,489,415,479,414,474,407,469,400,471,390,477,385,511,470,539,459,545,461,545,463,542,467,512,477,513,483,592,505,654,513,688,497,728,472,726,432,674,419,717,378,675,334,625,353,602,356,563,393,506,464,511,470,511,470,575,442,581,447,583,456,578,463,573,470,563,472,557,467,550,462,548,452,553,445,558,438,568,437,575,442,505,499,524,523,524,529,521,531,517,529,498,503,492,506,496,588,508,650,533,677,570,707,607,693,603,639,656,667,685,614,651,572,641,551,594,525,509,493,505,499,505,499,551,552,548,560,540,564,532,561,524,559,519,550,522,542,524,534,533,530,541,532,549,535,554,543,551,552]}]]},{I6:"0000-1-flower",H3:[["ffac42",{F:"M C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C Z M C C C C Z".split(" "),w:[646,471,646,446,626,426,601,426,599,426,597,426,595,427,596,426,598,424,599,423,616,406,616,378,599,360,581,343,553,343,536,360,534,361,533,363,532,364,532,363,532,361,532,359,532,335,512,315,488,315,463,315,443,335,443,359,443,361,443,363,443,365,442,364,441,363,440,362,422,344,394,344,377,362,359,379,359,407,377,425,378,426,380,427,381,429,379,428,378,428,376,428,351,428,331,448,331,473,331,498,351,518,376,518,378,518,380,517,382,517,381,518,379,519,378,521,361,538,361,566,378,584,396,601,424,601,441,584,443,582,444,581,445,579,445,581,445,583,445,584,445,609,465,629,490,629,514,629,534,609,534,584,534,582,534,580,534,579,535,580,536,581,537,582,555,600,583,600,600,582,618,565,618,537,600,519,599,518,597,516,596,515,598,515,599,516,601,516,626,516,646,496,646,471,489,552,444,552,409,516,409,472,409,428,444,392,489,392,533,392,569,428,569,472,569,516,533,552,489,552]}]]},{I6:"0000-1-flower",H3:[["d04040",{F:"M C C L L C C C C L L C C L L C C C C L C C C C L Z M C C C Z M C C C L Z M C C C L Z".split(" "),w:[691,424,690,369,680,330,660,303,634,320,601,361,568,406,568,406,568,327,578,326,585,317,585,306,585,294,576,284,564,284,552,284,542,294,542,306,542,317,550,326,560,327,560,406,559,406,540,359,522,311,501,291,475,319,453,360,433,407,431,406,431,327,441,326,448,317,448,306,448,294,439,284,427,284,415,284,405,294,405,306,405,317,412,326,423,327,423,404,390,363,360,326,341,308,296,401,299,489,360,567,396,613,443,639,500,638,624,636,694,524,692,424,691,424,389,543,370,514,379,498,399,504,439,518,470,564,488,613,455,600,414,580,389,543,481,480,488,445,505,441,515,459,533,497,524,552,501,599,487,567,472,523,481,480,481,480,624,523,610,563,565,595,515,613,528,580,548,538,585,514,614,494,629,503,624,523,624,523]}]]},{I6:"0000-1-flower",H3:[["ec7272",{F:"M C C C C Z M C C C C Z M C C C C L Z M C C C C L Z M C C C C Z M C C C C L Z".split(" "),w:[447,475,452,450,452,438,437,423,422,407,407,412,390,383,398,418,421,415,433,434,445,453,446,474,447,475,495,446,520,439,529,433,535,412,542,390,529,380,546,351,520,376,533,394,523,414,513,434,495,445,495,446,545,473,564,490,574,495,595,490,617,485,620,469,653,468,619,459,610,479,587,480,565,482,546,472,545,473,545,473,549,533,543,558,543,569,559,585,574,601,589,596,606,624,597,590,575,592,563,573,551,555,550,534,549,533,549,533,504,562,480,570,470,575,464,596,458,618,470,628,454,657,479,632,466,614,476,594,486,575,504,563,504,562,459,536,440,519,430,513,409,518,387,524,384,539,351,540,385,549,394,529,417,528,439,527,457,536,459,536,459,536]}],["333333",{F:"M C C C C C C C C C C C C L Z M C C C C C C C C C C C C L Z M C C C C C C C C C C C C L Z M C C C C C C C C C C C C L Z M C C C C C C C C C C C C L Z M C C C C C C C C C C C C L Z".split(" "),w:[534,455,584,415,579,358,577,335,574,315,585,304,585,304,585,304,568,308,561,312,554,316,520,333,500,363,479,392,493,437,486,456,479,476,452,485,452,485,452,485,471,474,475,454,479,434,460,402,482,365,505,328,565,292,597,294,612,295,591,298,587,316,583,333,593,373,584,404,574,440,533,456,534,455,534,455,559,506,619,530,666,497,685,483,701,471,716,475,716,475,716,475,704,463,697,459,690,454,657,434,622,431,587,428,554,462,534,465,513,469,492,451,492,451,492,451,511,461,530,455,549,448,568,416,611,417,654,418,716,452,730,481,737,495,724,478,706,483,689,489,660,516,628,524,592,534,558,506,559,506,559,506,524,552,534,615,586,640,607,649,625,657,629,672,629,672,629,672,634,655,634,647,634,639,636,601,621,569,606,537,560,525,547,509,534,494,539,466,539,466,539,466,539,488,554,501,569,514,607,514,627,552,648,590,650,660,632,687,623,700,631,680,617,667,605,656,566,644,543,621,517,594,524,551,524,552,524,552,467,546,417,585,421,643,424,665,426,686,415,697,415,697,415,697,432,693,439,689,446,684,481,667,501,638,521,609,508,563,515,544,522,524,548,515,548,515,548,515,530,527,526,546,522,566,540,598,518,635,496,672,436,709,404,706,388,705,409,702,413,684,417,667,408,628,417,596,426,561,467,544,467,546,467,546,442,495,383,472,336,504,317,518,301,530,286,526,286,526,286,526,298,539,305,543,312,547,344,568,380,571,415,574,448,539,468,536,488,532,510,551,510,551,510,551,490,540,471,547,452,553,434,585,391,584,348,583,286,550,272,521,265,507,278,524,296,518,313,513,342,485,373,477,409,468,444,495,442,495,442,495,476,449,467,386,415,361,394,352,375,344,371,329,371,329,371,329,366,346,366,354,366,362,364,400,379,433,394,465,440,476,453,492,467,508,462,535,462,535,462,535,461,513,446,500,431,487,394,487,373,449,352,411,350,341,368,314,377,301,369,321,383,334,396,345,434,357,457,380,483,407,477,450,476,449,476,449]}]]},{I6:"0000-0-hearts",H3:[["d17070",{F:"M C C C C C C C C C L Z".split(" "),w:[415,584,413,585,411,586,409,587,392,596,389,620,395,633,401,647,414,663,450,668,485,674,487,681,494,690,491,679,487,673,507,643,527,613,524,593,518,579,512,566,493,552,475,558,467,561,451,566,448,586,435,578,423,581,415,584,415,584]}],["6bcc6b",{F:"M C C C C C C C C C L Z".split(" "),w:[595,451,593,449,590,448,588,448,563,439,537,457,529,475,521,493,516,520,542,560,568,601,563,609,559,623,568,611,571,602,618,595,666,589,684,567,692,550,700,532,697,501,674,488,665,482,645,472,622,486,619,465,606,456,595,451,595,451]}],["5c5cc2",{F:"M C C C C C C C C C L Z".split(" "),w:[341,362,338,364,335,366,332,368,304,385,301,424,312,446,323,468,345,494,405,501,465,508,468,520,480,534,475,516,468,506,499,455,531,404,524,370,514,348,503,325,470,304,440,315,427,320,401,331,397,364,374,351,355,356,341,362,341,362]}]]},{I6:"0000-0-anchor",H3:[["2a3b66",{F:"M C C C C L Z M C C C C C C C C C C C C C C L C C C C C C C C C C C C C L C C C C C C C C C C C C C L Z".split(" "),w:[495,315,490,315,488,318,489,323,491,328,502,326,502,320,502,317,501,316,497,315,496,315,496,315,495,315,495,315,496,303,509,303,521,320,514,327,511,330,513,345,517,348,519,350,531,352,546,354,570,357,572,357,578,354,588,347,592,351,592,369,592,385,588,390,580,385,576,383,570,383,552,384,524,387,519,389,517,397,515,404,517,515,520,554,522,583,525,599,530,606,534,610,555,617,565,617,584,616,607,602,635,572,639,568,641,566,644,563,633,559,616,557,616,557,675,533,675,533,671,605,669,609,667,611,664,591,658,577,657,579,657,580,656,582,628,638,603,660,565,664,545,666,521,672,514,675,512,677,507,682,504,688,501,693,497,698,496,698,494,698,490,693,487,688,484,682,480,677,477,675,471,672,447,666,427,664,391,660,367,640,340,591,335,604,332,621,331,619,329,615,325,544,325,544,384,568,384,568,368,569,357,573,385,602,408,616,426,617,437,617,458,610,461,606,466,599,470,583,472,554,474,515,476,404,475,397,473,389,468,387,440,384,422,383,416,383,412,385,403,390,400,385,400,369,400,351,403,347,414,354,419,357,421,357,446,354,460,352,473,350,475,348,478,345,481,330,478,327,470,320,483,303,496,303,496,303]}]]},{I6:"0000-1-leaf",H3:[["fbb600",{F:"M L L L L L L C L L C L C L C C C C C L C C C C C C C C C L C C C C C C C C C C C C C L L L L Z".split(" "),w:[642,726,633,723,632,707,591,631,570,582,526,521,537,547,535,579,517,598,501,619,486,602,414,634,412,606,379,609,346,611,394,557,406,547,401,539,386,532,319,519,337,508,332,493,320,478,326,464,302,450,287,436,303,436,324,441,330,432,346,434,359,434,359,415,377,428,397,431,417,432,442,440,437,418,417,416,406,372,401,370,395,367,389,355,417,363,408,339,406,323,416,312,427,303,417,276,433,295,444,297,452,294,479,321,490,313,496,294,503,322,510,329,517,338,522,353,530,371,530,379,546,402,551,389,555,378,578,333,606,333,628,304,652,280,646,306,644,327,657,329,649,356,658,374,679,384,666,392,656,415,645,432,627,457,653,451,661,457,692,460,698,473,715,481,697,485,678,488,669,509,656,523,655,533,666,539,659,537,659,542,643,531,630,535,613,543,608,539,598,535,594,542,590,553,590,566,594,564,596,569,568,575,551,543,531,519,575,577,597,628,639,708,642,726]}]]},{I6:"0000-1-acorn",H3:[["a05a2c",{F:"M C C C C C C C L Z".split(" "),w:[506,453,450,426,413,422,398,444,374,480,374,533,384,573,391,602,407,625,430,645,451,658,487,654,509,647,554,633,587,605,612,565,635,527,591,500,565,482,557,476,515,457,506,453,506,453]}],["502d16",{F:"M C C C C C C C C C C C Z".split(" "),w:[640,524,639,539,623,540,623,540,627,522,607,504,583,488,547,465,507,445,470,434,439,426,412,417,400,437,400,437,391,424,400,414,434,370,498,356,551,376,555,349,583,317,597,321,612,326,621,346,620,350,619,354,594,352,584,368,580,375,577,382,575,387,619,412,649,460,640,524]}]]},{I6:"0000-0-skull",H3:[["808080",{F:"M C L C C L C L C C C C C C C L C L C C C C C C C C L C C L C L C C C C C C C L C L C L C C C C C C Z M C C C C Z M C C C C Z M L L L Z".split(" "),w:[396,410,398,415,398,420,398,424,420,437,433,404,465,382,501,382,538,382,569,404,582,435,602,424,602,419,603,415,604,410,604,410,609,392,622,379,633,382,643,384,648,402,643,420,643,421,642,421,642,422,643,422,643,422,644,422,662,427,675,440,672,450,669,461,652,465,633,460,628,459,624,457,620,455,589,473,588,491,582,507,572,520,607,540,611,538,615,536,620,535,639,530,656,535,659,545,662,556,649,568,630,573,630,574,629,574,629,574,629,574,629,575,629,575,634,594,630,611,619,614,609,617,596,604,591,585,590,580,589,576,589,571,565,557,564,592,536,619,501,619,466,619,438,591,437,557,412,572,411,576,411,580,410,585,410,585,405,604,392,617,381,614,371,611,366,593,371,575,371,574,371,574,372,574,371,573,371,573,370,573,352,568,339,556,342,545,345,534,362,530,381,535,385,536,390,538,394,540,430,519,421,507,415,491,414,475,380,455,376,457,372,459,367,460,367,460,349,465,331,461,328,450,326,440,338,427,357,422,357,422,358,422,358,422,358,421,358,421,358,420,353,402,357,384,368,381,379,379,391,391,396,410,463,439,445,439,431,453,431,470,431,488,445,502,463,502,480,502,494,488,494,470,494,453,480,439,463,439,540,439,522,439,508,453,508,470,508,488,522,502,540,502,557,502,571,488,571,470,571,453,557,439,540,439,483,528,518,528,500,503,483,528]}]]},{I6:"0000-0-ghost",H3:[["e6e6e6",{F:"M C C C C C C C C C C L Z M C C C C C C C C Z M C C Z".split(" "),w:[653,486,653,574,689,597,689,638,689,661,640,644,620,656,601,666,609,682,583,692,563,700,538,666,512,666,490,666,451,695,433,686,415,677,416,646,388,644,367,641,313,671,313,648,313,619,346,588,346,486,346,388,415,308,500,308,584,308,653,388,653,486,653,486,449,396,428,396,412,415,412,439,412,462,428,482,449,482,465,482,478,470,484,454,489,470,503,482,519,482,539,482,556,462,556,439,556,415,539,396,519,396,503,396,489,407,484,423,478,407,465,396,449,396,482,505,441,505,465,560,482,560,503,560,524,505,482,505]}],["000000",{F:"M C C C C Z M C C C C Z".split(" "),w:[526,446,526,455,519,462,510,462,501,462,494,455,494,446,494,437,501,430,510,430,519,430,526,437,526,446,475,446,475,455,468,462,459,462,450,462,442,455,442,446,442,437,450,430,459,430,468,430,475,437,475,446]}]]},{I6:"1001-1-rose",H3:[["9e1460",{F:"M C C C C C C C C C Z M C C C C C C C C C Z".split(" "),w:[568,83,558,83,548,88,539,96,538,98,536,99,535,101,522,115,513,134,517,149,522,172,561,200,592,207,604,210,611,215,615,221,622,234,611,258,611,258,613,260,615,264,618,264,627,266,638,241,640,236,660,188,614,83,568,83,526,125,527,97,567,68,593,75,616,81,642,121,649,152,651,165,656,172,662,176,675,183,698,173,698,173,698,173,698,173,698,173,704,176,705,179,705,180,706,189,681,199,678,200,678,200,677,201,677,201,627,220,524,170,526,125]}],["020304",{F:"M C C C C C Z M C C C C C Z M C C C C C Z M C C C C Z".split(" "),w:[60,151,60,151,37,125,60,98,83,72,95,91,115,66,134,42,117,26,120,30,123,34,146,83,132,114,114,154,60,151,60,151,280,70,280,70,258,97,283,122,308,147,318,127,339,150,361,173,344,190,347,186,350,182,370,132,354,101,333,62,280,70,280,70,61,150,61,150,27,143,30,108,33,73,54,81,55,50,57,19,33,16,38,17,43,19,91,44,98,78,107,121,61,150,61,150,-27,185,184,158,222,43,352,32,444,24,538,97,538,97,538,97,453,45,354,48,241,51,185,170,-27,185]}]]},{I6:"1001-1-curls",H3:[["53a7ab",{F:"M C C C C C C C C C C C C C C C C L Z M C C C C C C C C C C C C C C C C L Z M C C C C C C C C C C C C C C C C C C C C C L Z".split(" "),w:[68,114,121,103,159,110,183,135,212,169,211,204,189,237,162,277,124,291,86,276,52,263,38,236,47,202,55,168,79,151,121,156,147,162,165,177,160,205,155,228,135,241,113,237,97,234,92,221,96,205,98,195,105,194,115,200,124,205,133,204,135,197,139,183,122,167,95,171,68,176,54,193,68,220,84,252,131,261,165,238,201,202,199,164,158,136,118,113,52,122,-23,151,2,134,33,122,68,114,68,114,71,83,119,75,163,79,198,107,226,129,247,174,271,207,291,229,316,241,342,232,370,222,394,206,418,209,443,212,461,238,485,258,500,272,522,276,543,271,543,271,524,279,518,281,500,287,483,277,466,256,453,243,441,230,427,223,413,217,392,220,372,229,372,230,371,230,370,230,354,241,337,251,315,250,283,248,253,222,229,172,209,133,178,106,137,94,103,84,52,94,-30,133,-3,108,30,91,71,83,71,83,83,54,122,46,166,49,195,67,219,82,250,122,290,168,308,186,330,194,355,192,393,183,400,145,383,118,372,101,355,91,328,91,313,92,303,98,300,109,298,116,299,125,304,131,315,147,327,152,340,149,349,149,354,132,343,131,330,131,326,129,328,120,332,97,355,100,365,114,381,137,367,165,343,168,321,170,289,150,288,117,290,77,319,58,352,64,388,74,405,104,404,141,403,177,382,202,345,207,312,211,284,191,260,161,245,141,229,122,213,106,196,84,166,73,129,67,80,62,28,79,-26,108,10,79,46,63,83,54,83,54]}],["bbdc54",{F:"M C C C C C L Z M C C C C C L Z M C C C C L Z M C C C C L Z M C C C C C C C C C L Z M C C C C C C C C C C C C C C C C C C C C C C C C C C C C C L Z".split(" "),w:[321,315,287,324,252,312,211,219,217,284,239,326,279,341,324,352,362,329,398,291,316,305,258,269,217,196,238,284,274,319,321,315,321,315,211,261,223,300,234,345,252,374,220,378,194,367,193,324,194,306,198,288,206,270,197,315,204,340,221,351,206,327,202,297,211,261,211,261,206,246,193,301,170,317,138,297,162,281,184,254,205,222,201,246,191,267,174,283,186,279,197,267,206,246,206,246,378,233,370,286,337,299,294,270,312,277,330,276,347,267,294,278,259,252,234,203,280,259,327,278,378,233,378,233,626,217,604,273,555,313,511,315,484,316,438,289,432,232,450,253,488,296,511,291,532,286,551,277,566,261,527,269,498,263,480,243,478,241,478,237,480,235,486,230,504,220,519,226,537,233,551,242,567,241,591,236,611,228,626,217,626,217,411,192,432,183,439,166,420,136,443,144,460,158,466,182,470,165,456,149,430,133,459,136,485,145,505,165,503,143,463,133,434,128,486,127,526,124,539,118,505,123,470,124,435,122,461,111,483,96,500,76,475,95,450,110,424,118,450,96,465,72,466,48,458,75,440,98,419,112,424,106,428,99,428,91,429,68,413,57,393,51,419,70,426,92,411,110,408,77,385,58,343,52,383,26,422,25,445,62,458,47,465,29,467,8,477,27,479,51,475,76,497,64,515,49,528,29,524,57,515,82,496,103,521,113,549,111,579,99,560,122,535,136,502,137,518,149,521,173,514,205,505,181,492,166,476,158,483,188,470,205,447,216,456,183,451,166,438,157,444,193,426,211,379,207,403,193,416,172,416,140,434,156,428,173,411,192,411,192]}]]},{I6:"0111-0-pines",H3:[["e9e9e9",{F:"M C C C C C C C C L L L Z".split(" "),w:[0,946,0,946,54,960,99,944,149,927,182,954,205,956,245,960,298,940,382,974,435,995,478,957,538,956,571,955,597,969,631,968,663,967,701,938,749,944,805,950,851,960,893,946,950,928,1e3,946,1e3,946,1e3,1e3,0,1e3,0,946]}],["437a26",{F:"M C L C C C L L C C L L L L L C Z M C L C C C L L C C L L L L L C Z M C L C C C L L C C L L L L L C Z M C L C C C L L C C L L L L L C Z M C L C C C L L C C L L L L L C Z".split(" "),w:[119,801,120,801,148,859,148,859,137,853,137,853,155,890,155,891,156,892,138,887,140,888,141,888,171,925,171,925,126,924,125,943,125,943,105,944,106,944,107,944,106,924,106,924,61,925,93,886,77,891,100,854,89,860,89,860,119,801,119,801,286,871,286,871,303,905,303,905,296,902,296,902,307,924,307,924,307,925,297,922,297,922,298,922,316,944,316,944,289,944,289,955,289,955,277,956,278,956,278,956,278,944,278,944,251,944,270,921,260,924,274,902,268,906,268,906,285,871,286,871,526,863,526,863,546,903,546,903,538,899,538,899,550,924,550,925,550,926,539,922,540,922,540,922,561,948,561,948,530,947,529,960,529,960,516,961,517,961,518,961,517,947,517,947,486,948,508,921,497,925,513,899,505,903,505,903,526,863,526,863,731,841,731,841,752,883,752,883,744,879,744,879,757,907,757,908,758,908,745,905,746,905,747,905,769,932,769,932,736,932,735,946,735,946,721,946,721,946,722,947,721,932,721,932,688,932,712,903,700,908,717,880,709,884,709,884,731,841,731,841,889,826,889,826,914,876,914,876,904,871,904,871,920,904,920,905,920,906,906,901,907,902,908,902,934,934,934,934,894,933,894,950,894,950,877,951,878,951,879,951,878,933,878,933,838,934,866,900,852,905,872,872,862,877,862,877,889,826,889,826]}]]},{I6:"0111-0-flowers",H3:[["8cae40",{F:"M C L C C C L C C L C C C L C C C L C C L C C L Z M C L C C C L C C L C C C L C C C L C C L C C L Z M C L C C C L C C L C C C L C C C L C C L C C L Z M C L C C C L C C L C C C L C C C L C C L C C L Z".split(" "),w:[182,866,160,879,146,903,135,929,135,844,177,842,228,831,230,796,231,770,207,765,182,779,160,792,146,816,135,843,135,713,135,711,134,710,132,710,130,710,128,711,128,713,128,841,117,815,103,791,82,779,57,764,33,769,34,795,36,830,86,841,128,844,128,930,117,903,103,880,82,867,57,853,33,858,34,884,36,919,86,930,128,932,128,1009,128,1010,130,1012,132,1012,134,1012,135,1010,135,1009,135,931,177,928,228,918,230,882,231,856,207,851,182,866,182,866,447,904,430,898,412,904,394,916,394,861,413,873,431,879,447,873,458,868,458,852,447,848,430,841,412,848,394,859,394,788,394,787,393,786,391,786,389,786,388,787,388,788,388,859,370,847,352,841,336,848,325,852,325,868,336,873,352,879,370,873,388,862,388,915,370,904,352,898,336,904,325,909,325,925,336,929,352,936,370,930,388,918,388,1009,388,1010,389,1011,391,1011,393,1011,394,1010,394,1009,394,918,413,930,431,936,447,929,458,925,458,909,447,904,447,904,662,943,650,954,641,972,634,993,634,914,659,907,680,895,692,873,707,846,686,836,662,859,650,870,641,888,634,909,634,818,634,816,632,815,631,815,629,815,628,816,628,818,628,908,621,887,612,870,600,859,576,836,555,846,570,873,582,895,603,907,628,914,628,992,621,971,612,954,600,943,576,920,555,930,570,957,582,978,603,990,628,998,628,1009,628,1010,629,1011,631,1011,632,1011,634,1010,634,1009,634,998,659,991,680,978,692,957,707,930,686,920,662,943,662,943,892,842,875,857,862,882,850,912,850,822,874,817,896,805,908,778,919,755,896,751,877,769,866,779,857,796,850,815,850,737,850,736,848,735,847,735,845,735,844,736,844,737,844,815,836,795,828,779,817,769,798,751,775,755,785,777,797,804,820,817,844,822,844,912,832,882,818,857,801,842,772,816,737,822,753,854,772,894,806,911,844,918,844,1009,844,1010,845,1011,847,1011,848,1011,850,1010,850,1009,850,918,887,911,922,894,941,854,957,822,922,816,892,842,892,842]}],["d13777",{F:"M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M L C L L C C C C L L Z M C C C C Z M C C C C C C C Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z M C C C C C C C L Z M C C C C C C L Z M C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C Z M C C C C Z M C C L L C C C C L L C C L L C C C C L C C C C L Z M C C C Z M C C C L Z M C C C L Z".split(" "),w:[125,603,115,617,112,619,110,618,111,615,122,600,119,597,75,614,43,631,32,650,22,675,36,694,65,682,59,716,94,722,111,696,120,687,126,657,129,604,125,603,125,603,104,638,99,638,95,634,95,629,95,624,99,620,104,620,109,620,113,624,113,629,113,634,109,638,104,638,117,587,100,582,98,579,99,578,102,577,119,583,121,580,92,543,65,517,44,513,17,512,4,531,24,555,-10,560,-6,594,24,603,36,609,67,605,118,591,118,587,117,587,78,578,77,573,79,568,84,567,88,565,93,568,95,573,96,577,94,582,89,584,85,585,80,583,78,578,130,575,130,557,131,554,133,555,135,557,135,575,138,576,164,537,180,504,177,482,171,456,148,449,132,476,117,445,85,460,86,491,84,504,97,532,126,577,130,575,130,575,126,535,130,532,136,533,139,537,142,541,141,546,137,549,133,552,127,551,125,547,122,543,122,538,126,535,146,584,162,577,165,578,166,580,164,582,146,588,147,591,193,604,229,609,249,600,271,585,271,562,240,554,265,530,241,505,212,516,199,518,176,539,143,580,146,584,146,584,183,567,187,570,187,576,185,580,182,584,176,585,172,582,168,579,167,573,170,569,173,565,179,565,183,567,142,601,153,615,153,618,152,619,149,618,138,603,135,605,137,652,144,688,159,704,180,721,202,713,199,681,230,698,246,667,227,643,221,631,194,616,145,597,142,601,142,601,169,631,167,636,162,638,158,637,153,635,151,630,152,625,154,621,159,618,163,620,168,621,170,626,169,631,376,691,343,693,320,697,309,706,297,714,291,729,294,756,294,767,295,779,294,788,305,786,320,788,335,788,353,787,369,782,375,773,382,764,386,739,388,703,381,702,377,699,376,691,363,745,357,757,351,761,345,761,337,760,337,751,343,737,330,742,322,742,319,735,317,728,322,723,331,718,346,712,360,708,374,706,373,720,369,733,363,745,363,745,388,680,387,646,383,623,375,612,366,600,351,594,325,596,314,596,302,597,293,595,295,607,292,622,292,637,292,654,298,671,306,676,315,684,340,689,376,692,377,684,381,680,388,680,388,680,334,665,323,659,318,654,319,648,320,639,329,640,343,645,338,632,339,625,345,621,352,620,358,625,362,634,368,649,372,664,373,677,360,676,347,671,334,665,334,665,399,691,433,690,456,686,467,678,479,670,485,655,484,629,484,617,482,606,484,597,472,598,458,595,442,596,425,596,409,601,403,610,395,618,391,643,388,679,395,680,399,684,399,691,399,691,414,638,420,626,426,622,432,622,440,624,440,633,434,646,447,641,455,642,458,648,459,656,454,661,445,665,430,671,416,675,402,677,403,663,408,650,414,638,414,638,388,703,390,736,394,759,403,770,411,782,426,788,452,785,464,785,475,784,485,785,483,774,485,759,485,744,484,726,479,710,470,704,461,697,436,693,400,691,399,698,395,702,388,703,388,703,442,716,453,722,458,728,458,734,456,742,447,742,434,736,439,749,438,757,432,760,425,762,419,757,415,748,409,733,404,719,403,705,416,706,429,710,442,716,442,716,722,716,722,701,710,690,696,690,695,690,694,690,693,690,693,689,694,689,695,688,705,678,705,662,695,651,685,641,668,641,658,651,658,652,657,653,656,654,656,653,656,652,656,651,656,637,645,625,630,625,616,625,605,637,605,651,605,652,605,653,605,654,604,654,604,653,603,652,593,642,576,642,566,652,556,662,556,679,566,689,567,690,568,690,569,691,568,691,567,691,566,691,552,691,540,702,540,717,540,731,552,743,566,743,567,743,568,743,569,742,569,743,568,744,567,744,557,754,557,771,567,781,577,791,594,791,604,781,605,780,605,779,606,778,606,779,606,780,606,781,606,795,617,807,632,807,646,807,657,795,657,781,657,780,657,779,657,778,658,779,658,779,659,780,669,790,686,790,696,780,706,770,706,754,696,743,695,743,694,742,693,741,694,741,695,741,696,741,710,741,722,730,722,716,631,762,605,762,585,742,585,716,585,691,605,670,631,670,657,670,677,691,677,716,677,742,657,762,631,762,958,602,957,570,951,547,940,532,925,541,905,565,887,591,886,591,886,546,892,545,897,540,897,533,897,527,891,521,884,521,877,521,872,527,872,533,872,540,876,545,882,546,882,591,882,591,870,564,860,536,848,525,833,541,820,565,808,592,807,592,807,546,813,545,817,540,817,533,817,527,812,521,805,521,798,521,792,527,792,533,792,540,797,545,802,546,802,590,784,567,766,545,755,534,729,588,731,639,766,684,787,711,814,726,847,725,919,724,960,659,958,602,958,602,783,671,772,653,777,645,789,648,812,656,830,682,840,711,821,704,797,692,783,671,836,634,840,614,850,612,856,622,867,644,861,676,848,703,840,684,831,659,836,634,836,634,919,659,911,682,885,701,856,711,863,692,875,668,896,654,913,642,922,647,919,659,919,659]}]]},{I6:"1101-1-confetti",H3:[["e789ff",{F:"M C C C C C Z M C C C C C C C Z M C C C C C C C Z M C C C C C Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[170,439,169,438,59,370,108,300,152,238,298,276,318,337,338,398,265,380,285,358,312,328,185,247,121,307,72,353,171,440,170,439,318,338,336,399,262,408,184,346,138,309,73,237,112,174,167,88,345,115,377,222,393,276,296,260,335,236,375,212,236,111,155,183,73,254,265,380,285,358,312,328,318,338,318,338,377,222,394,276,318,288,243,236,187,197,146,120,201,56,254,-5,365,26,407,68,407,68,414,94,378,71,344,50,258,31,221,89,178,154,297,260,336,235,374,211,377,222,377,222,406,70,452,115,432,189,324,115,214,39,323,-85,322,-85,320,-85,229,38,331,100,439,166,413,95,377,72,343,51,364,28,406,70,346,405,369,418,356,441,333,428,346,405,513,298,536,311,523,334,500,321,513,298,891,91,914,104,901,127,878,114,891,91,24,123,47,136,34,159,11,146,24,123,664,33,687,46,674,69,651,56,664,33,910,482,933,495,920,518,897,505,910,482]}],["666666",{F:"M C C C C C Z M C C C C C C C Z M C C C C C C C Z M C C C C C Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[919,442,917,443,802,510,764,432,730,364,837,250,901,261,965,272,913,329,903,301,889,262,755,338,777,424,794,490,920,442,919,442,901,261,964,274,936,345,842,386,787,410,690,435,654,370,604,279,716,132,827,153,883,164,821,244,819,197,817,150,659,228,682,335,706,443,913,329,903,301,889,262,901,261,901,261,827,153,884,163,857,238,774,281,711,313,622,313,593,233,564,157,647,71,705,54,705,54,732,60,694,82,658,102,599,170,632,231,669,301,822,244,819,197,816,150,827,153,827,153,706,54,769,34,825,87,706,149,583,213,527,56,526,57,526,59,590,200,696,137,807,70,732,60,694,82,658,102,648,73,706,54,362,328,383,340,371,361,350,349,362,328,52,189,73,201,61,222,40,210,52,189,509,119,530,131,517,152,496,140,509,119,912,16,933,28,921,49,900,37,912,16,629,380,650,392,638,413,617,401,629,380,77,414,98,426,86,447,65,435,77,414,240,76,261,88,249,109,228,97,240,76]}]]},{I6:"1101-1-branch",H3:[["7f500b",{F:"M C C C L C C Z M C C C L C C Z M C C C L C C Z M C C C L C C Z M C C C L C C Z M C C C L C C Z".split(" "),w:[144,-14,144,-14,149,-12,150,-12,150,-12,106,22,86,75,63,137,93,193,69,238,64,236,89,174,53,146,80,72,99,19,144,-14,144,-14,280,-18,281,-18,276,-20,276,-20,276,-20,282,23,264,64,244,113,196,129,185,168,189,170,209,120,244,123,269,66,288,25,280,-18,280,-18,429,-5,429,-5,434,-4,434,-4,435,-4,405,28,396,72,386,124,415,164,402,203,398,202,410,150,379,132,391,70,399,26,429,-5,429,-5,514,-7,514,-7,519,-12,519,-12,520,-12,532,50,577,96,630,151,703,150,738,197,733,201,681,144,635,166,571,101,526,54,514,-7,514,-7,666,-67,666,-68,663,-65,662,-64,662,-64,704,-52,734,-18,768,22,763,72,793,99,796,96,760,57,778,26,737,-22,708,-56,666,-67,666,-67,936,-8,936,-8,932,-9,931,-9,931,-9,947,32,938,76,927,127,884,154,881,194,886,195,895,142,930,138,943,76,952,32,936,-8,936,-8]}],["5c7f0b",{F:"M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z".split(" "),w:[119,6,121,16,113,31,81,33,58,34,27,27,27,27,27,27,53,5,70,-1,93,-9,117,-4,119,6,124,8,132,1,151,12,165,33,179,54,180,87,180,87,180,87,153,75,139,60,122,41,115,14,124,8,78,74,82,83,76,97,48,103,27,108,-2,105,-2,105,-2,105,19,81,33,74,53,64,75,65,78,74,83,75,90,68,108,76,124,93,139,110,144,140,144,140,144,140,117,132,104,121,85,105,76,83,83,75,72,152,75,159,72,172,48,179,30,185,6,185,6,185,6,185,22,163,33,156,49,145,68,145,72,152,76,153,81,146,98,151,112,165,126,178,133,203,133,203,133,203,110,199,97,190,80,178,70,160,76,153,73,206,75,213,71,224,49,228,34,232,12,230,12,230,12,230,28,212,39,206,53,199,70,200,73,206,76,207,81,202,95,207,107,220,118,233,122,255,122,255,122,255,102,250,92,241,78,230,71,213,76,207,70,232,78,236,76,252,66,269,56,286,33,297,33,297,33,297,33,274,39,260,46,241,62,228,70,232,285,3,278,8,274,21,291,39,304,52,325,63,325,63,325,63,323,36,316,24,308,7,291,-2,285,3,281,1,280,-7,263,-10,244,-5,224,1,205,20,205,20,205,20,228,27,244,25,264,22,283,10,281,1,270,65,264,69,259,80,272,99,281,112,299,125,299,125,299,125,300,100,296,88,290,72,277,61,270,65,267,64,267,56,252,51,234,53,216,56,197,71,197,71,197,71,216,80,230,80,249,80,267,72,267,64,231,116,225,119,220,128,230,145,237,157,251,170,251,170,251,170,254,148,251,138,248,123,237,113,231,116,228,114,229,108,217,102,201,103,186,103,168,115,168,115,168,115,184,124,196,126,212,127,228,121,228,114,201,148,196,151,192,160,202,174,209,184,222,194,222,194,222,194,223,175,220,166,216,154,206,145,201,148,198,147,198,141,187,137,174,139,160,141,145,152,145,152,145,152,160,159,171,159,185,160,198,153,198,147,188,165,182,163,173,174,170,190,167,205,173,224,173,224,173,224,186,210,191,198,197,183,195,166,188,165,415,10,417,18,413,31,389,36,371,39,347,37,347,37,347,37,364,16,377,9,393,0,412,2,415,10,418,11,424,4,440,11,453,27,466,43,470,69,470,69,470,69,448,62,436,52,420,38,412,17,418,11,391,69,394,76,392,89,371,96,355,102,333,103,333,103,333,103,346,81,357,74,371,64,388,63,391,69,395,70,399,63,414,68,428,80,441,92,448,116,448,116,448,116,427,113,415,105,400,94,390,77,395,70,395,133,398,139,397,150,379,158,367,164,348,167,348,167,348,167,358,148,366,140,377,130,391,128,395,133,398,134,401,128,414,130,427,140,439,149,447,169,447,169,447,169,429,167,418,162,404,154,394,140,398,134,401,177,404,182,402,192,386,198,374,202,358,203,358,203,358,203,368,187,375,181,386,173,399,172,401,177,404,178,408,173,419,176,429,185,439,194,445,212,445,212,445,212,429,210,420,204,408,196,401,183,404,178,402,198,408,201,409,214,403,229,397,244,381,255,381,255,381,255,378,236,381,224,385,208,396,196,402,198,519,23,531,26,543,42,528,75,518,99,495,125,495,125,495,125,485,87,487,67,490,40,508,19,519,23,523,19,521,7,542,-6,571,-8,600,-10,636,6,636,6,636,6,609,27,586,32,557,39,526,32,523,19,570,100,581,102,594,115,585,147,579,170,562,197,562,197,562,197,548,163,547,145,547,120,560,98,570,100,574,97,570,86,587,72,613,66,639,60,673,71,673,71,673,71,652,93,632,101,607,110,578,107,574,97,649,149,659,150,670,160,666,188,662,208,650,232,650,232,650,232,635,205,633,189,631,168,640,149,649,149,652,146,648,137,662,123,683,116,705,109,734,116,734,116,734,116,718,137,702,145,681,155,657,155,652,146,707,178,715,179,724,189,718,213,714,230,701,250,701,250,701,250,690,225,690,211,689,193,699,177,707,178,710,175,707,167,720,156,739,151,759,147,784,155,784,155,784,155,768,172,753,177,734,185,713,183,710,175,732,194,740,189,757,199,770,218,782,237,783,266,783,266,783,266,758,254,746,240,730,223,724,199,732,194,687,-62,688,-54,699,-45,722,-53,739,-59,759,-73,759,-73,759,-73,733,-82,719,-82,701,-81,685,-71,687,-62,684,-60,676,-62,666,-48,662,-28,659,-9,669,17,669,17,669,17,684,-1,689,-16,696,-35,692,-57,684,-60,737,-23,738,-15,746,-5,768,-9,784,-12,804,-23,804,-23,804,-23,782,-34,769,-36,752,-38,736,-30,737,-23,734,-20,727,-24,716,-13,711,5,705,22,711,46,711,46,711,46,727,33,734,20,742,3,742,-17,734,-20,766,35,766,41,772,50,792,48,806,47,823,40,823,40,823,40,805,28,795,26,780,23,766,28,766,35,763,37,758,33,747,42,741,56,735,70,738,91,738,91,738,91,753,81,760,71,768,57,769,40,763,37,782,76,783,82,789,89,806,86,818,84,832,76,832,76,832,76,816,67,806,66,794,65,782,70,782,76,780,78,775,75,766,84,762,97,758,110,762,128,762,128,762,128,775,118,779,108,786,95,785,80,780,78,792,94,788,100,794,112,807,122,819,131,839,133,839,133,839,133,832,116,823,107,812,95,796,89,792,94,945,11,939,18,938,31,959,45,974,55,997,62,997,62,997,62,989,36,980,25,968,11,950,5,945,11,941,11,938,3,921,3,903,13,885,22,871,45,871,45,871,45,894,47,909,42,929,35,944,19,941,11,944,75,938,80,935,93,952,108,964,119,984,128,984,128,984,128,980,104,974,93,965,78,949,70,944,75,940,75,938,67,923,65,906,71,889,77,873,96,873,96,873,96,894,101,908,99,926,95,942,82,940,75,916,133,911,137,907,147,920,162,930,172,946,182,946,182,946,182,944,160,940,151,933,137,921,129,916,133,913,132,912,125,899,123,884,127,869,130,854,145,854,145,854,145,871,151,883,150,899,148,913,139,913,132,893,171,888,175,887,184,899,196,908,204,923,211,923,211,923,211,920,193,915,184,909,173,897,167,893,171,890,170,889,165,877,163,864,168,851,172,839,187,839,187,839,187,855,190,865,188,879,186,891,176,890,170,884,190,877,190,871,202,871,218,871,234,881,251,881,251,881,251,891,234,893,222,896,206,890,190,884,190]}]]},{I6:"1101-1-sticks",H3:[["ec7272",{F:"M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[260,148,297,180,286,192,249,160,260,148,114,31,161,47,155,63,109,47,114,31,931,91,902,52,915,42,945,81,931,91,711,19,746,-15,758,-3,723,31,711,19,812,161,782,122,795,112,825,151,812,161,389,34,424,0,436,12,401,46,389,34,431,209,465,175,477,186,442,221,431,209,282,90,282,41,299,41,299,90,282,90,58,233,29,194,42,184,72,223,58,233,574,58,621,74,615,90,569,74,574,58]}],["0000ff",{F:"M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[722,208,733,161,717,157,706,205,722,208,843,12,797,28,802,44,849,28,843,12,31,74,60,35,47,25,18,64,31,74,220,21,185,-13,173,-1,208,33,220,21,140,166,170,127,157,117,127,156,140,166,558,148,523,114,511,126,546,160,558,148,562,9,516,25,521,41,568,25,562,9,697,105,726,66,713,56,684,95,697,105,961,180,990,141,977,131,948,170,961,180,399,97,353,113,358,129,405,113,399,97]}]]},{I6:"1101-1-dots",H3:[["ec7272",{F:"M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z".split(" "),w:[154,47,144,47,136,39,136,29,136,19,144,11,154,11,164,11,172,19,172,29,172,39,164,47,154,47,272,164,262,164,254,156,254,146,254,136,262,128,272,128,282,128,290,136,290,146,290,156,282,164,272,164,529,48,519,48,511,40,511,30,511,20,519,12,529,12,539,12,547,20,547,30,547,40,539,48,529,48,696,101,686,101,678,93,678,83,678,73,686,65,696,65,706,65,714,73,714,83,714,93,706,101,696,101,929,91,919,91,911,83,911,73,911,63,919,55,929,55,939,55,947,63,947,73,947,83,939,91,929,91]}],["0000ff",{F:"M C C C C Z M C C C C Z M C C C C Z M C C C C Z M C C C C Z".split(" "),w:[66,122,56,122,48,114,48,104,48,94,56,86,66,86,76,86,84,94,84,104,84,114,76,122,66,122,309,55,299,55,291,47,291,37,291,27,299,19,309,19,319,19,327,27,327,37,327,47,319,55,309,55,785,180,775,180,767,172,767,162,767,152,775,144,785,144,795,144,803,152,803,162,803,172,795,180,785,180,459,147,449,147,441,139,441,129,441,119,449,111,459,111,469,111,477,119,477,129,477,139,469,147,459,147,811,48,801,48,793,40,793,30,793,20,801,12,811,12,821,12,829,20,829,30,829,40,821,48,811,48]}],["88a500",{F:["M","C","C","Z"],w:[389,224,389,224,410,230,410,230,410,230,389,224,389,224]}]]},{I6:"1101-1-strips",H3:[["ffc88c",{F:"M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[-40,0,44,0,137,99,53,99,-40,0,296,0,380,0,473,99,389,99,296,0,632,0,716,0,809,99,725,99,632,0]}],["88a500",{F:"M L L L L Z M L L L L Z M L L L L Z".split(" "),w:[128,0,212,0,305,99,221,99,128,0,464,0,548,0,641,99,557,99,464,0,800,0,884,0,977,99,893,99,800,0]}],["88a500",{F:["M","C","C","Z"],w:[407,217,407,217,428,223,428,223,428,223,407,217,407,217]}]]},{I6:"1101-1-circs",H3:[["ec7272",{F:"M C C C C Z M C C C C Z".split(" "),w:[61,209,27,209,0,181,0,147,0,113,27,86,61,86,96,86,123,113,123,147,123,181,96,209,61,209,551,209,517,209,489,181,489,147,489,113,517,86,551,86,585,86,612,113,612,147,612,181,585,209,551,209]}],["217995",{F:"M C C C C Z M C C C C Z".split(" "),w:[303,209,269,209,241,181,241,147,241,113,269,86,303,86,337,86,364,113,364,147,364,181,337,209,303,209,799,209,765,209,738,181,738,147,738,113,765,86,799,86,834,86,861,113,861,147,861,181,834,209,799,209]}],["88a500",{F:["M","C","C","Z"],w:[530,273,530,273,551,279,551,279,551,279,530,273,530,273]}]]},{I6:"1101-1-squares",H3:[["014ea7",{F:"M L L L L Z M L L L L Z".split(" "),w:[0,120,124,120,124,244,0,244,0,120,497,120,621,120,621,244,497,244,497,120]}],["fc54ff",{F:"M L L L L Z M L L L L Z".split(" "),w:[249,120,373,120,373,244,249,244,249,120,746,120,870,120,870,244,746,244,746,120]}],["88a500",{F:["M","C","C","Z"],w:[389,354,389,354,410,360,410,360,410,360,389,354,389,354]}]]},{I6:"1101-0-christmas",H3:[["014ea7",{F:"M C C C C Z M C C C C Z M L L L L Z".split(" "),w:[255,480,178,480,116,418,116,341,116,264,178,202,255,202,332,202,394,264,394,341,394,418,332,480,255,480,255,232,236,232,221,217,221,198,221,179,236,164,255,164,274,164,289,179,289,198,289,217,274,232,255,232,251,-152,260,-152,260,248,251,248,251,-152]}],["ff9518",{F:"M C C C C Z M C C C C Z M L L L L Z".split(" "),w:[746,623,669,623,607,561,607,484,607,407,669,345,746,345,823,345,885,407,885,484,885,561,823,623,746,623,747,376,728,376,713,361,713,342,713,323,728,308,747,308,766,308,781,323,781,342,781,361,766,376,747,376,742,-8,751,-8,751,392,742,392,742,-8]}]]}];
var ag={};ag.parse=function(w){var n=new Uint8Array(w),W=null;if(n[0]==80&&n[1]==75){var D=Date.now(),j=UZIP.parse(n.buffer),W=j["document.json"];
W=JSON.parse(J.KY(W,0,W.length));ag.SQ(W,j)}else{var I=i3.parse(w);W=ag.atW(I[2][0][1])}return W};ag.SQ=function(w,n){var W=typeof w;
if(W=="string"||W=="number"||W=="boolean")return w;if(w instanceof Array){for(var L=0;L<w.length;L++)w[L]=ag.SQ(w[L],n);
return w}var D=w._class;if(D==null)return w;if(D=="MSJSONFileReference"){var j=w._ref;if(!1){}else if(n[j+".json"]!=null){var I=n[j+".json"],U=I.length;
for(var L=0;L<U;L++)if(I[L]==11||I[L]==3)I[L]=32;var M=J.KY(I,0,U);w=JSON.parse(M)}else if(n[j+".png"]!=null)return{key:j.split("/").pop(),bdata:n[j+".png"]};
else if(n[j+".jpg"]!=null)return{key:j.split("/").pop(),bdata:n[j+".jpg"]};else if(n[j+".pdf"]!=null)return{key:j.split("/").pop(),bdata:n[j+".pdf"]};
else if(n[j]!=null)return{key:j.split("/").pop(),bdata:n[j]};else{console.log(w,n);return}}else if(D=="MSAttributedString"){var M=atob(w.archivedAttributedString._archive),m=M.length,l=new Uint8Array(m);
for(var L=0;L<m;L++)l[L]=M.charCodeAt(L);w.archivedAttributedString=ag.atW(l)}for(var A in w)w[A]=ag.SQ(w[A],n);
return w};ag.adZ=function(w,n,W,D){if(w instanceof Uint8Array)return null;if(D.indexOf(w)!=-1)return null;
D.push(w);if(w==n)return W;for(var j in w){W.push(j);var I=ag.adZ(w[j],n,W,D);if(I){console.log(w,I);
throw"e"}W.pop()}};ag.atW=function(w){var n=du.parse(w,0),W=n.$objects,D=new Uint8Array(W.length),j=ag.nb(W,D,n.$top.root);
for(var L=0;L<W.length;L++)if(D[L]==0&&L!=0){console.log(L,W[L]);ag.adZ(j,L,[],[])}for(var L=0;L<W.length;
L++){var I=W[L];if(I._class&&(I._class=="bitmap"||I._class=="fill"&&I.fillType==4&&(I.image||I.imageSHA))){var U=I.image,M=I.imageSHA,m=null,l=null;
if(U=="$null")U=null;if(M=="$null")M=null;if(U&&U.data){l=U.sha1["NS.bytes"];l=btoa(J.sv(l,0,l.length));
m=U.data instanceof Uint8Array?U.data:U.data["NS.bytes"]}else if(U==null&&M==null){var A=jj.ZO("PNG").La([[E.Q(4).buffer]],1,1);
m=new Uint8Array(A)}else{var g=(j.assets?j.assets.imageCollection:j.images).images;if(M)l=M instanceof Uint8Array?M:M["NS.bytes"];
else l=U.sha1["NS.bytes"];l=btoa(J.sv(l,0,l.length));var m=g[l].data;if(m["NS.bytes"])m=m["NS.bytes"]}m=new Uint8Array(m.buffer.slice(m.byteOffset,m.byteOffset+m.length));
delete I.imageSHA;I.image={key:l,bdata:m}}}return j};ag.azA=function(w){return w.slice(0,11)=="MSImmutable"?"MS"+w.slice(11):w};
ag.nb=function(w,n,W){var D=w[W];if(n[W]==1){return D}n[W]=1;if(typeof D=="string")return D;if(typeof D=="number")return D;
if(typeof D=="boolean")return D;if(D instanceof Array)return D;if(D instanceof Uint8Array){return D}if(w[D.$class]==null){if(D.$class==null&&D["NS.data"]!=null)return D;
console.log(W,D);throw"e"}var j=w[D.$class],I=ag.azA(j.$classname);n[D.$class]=1;D.$class=I;if(ag.asI[I]){delete D.$class;
D._class=ag.asI[I]}var U=ag.nb;if(I=="NSMutableArray"||I=="NSArray"){var M=[];if(D["NS.objects"]!=null)for(var L=0;
L<D["NS.objects"].length;L++)M.push(U(w,n,D["NS.objects"][L]));else for(var L=0;D["NS.object."+L]!=null;
L++)M.push(U(w,n,D["NS.object."+L]));w[W]=M;return M}if(I=="NSDictionary"||I=="NSMutableDictionary"){var m={$class:I};
if(D["NS.keys"]!=null)for(var L=0;L<D["NS.keys"].length;L++){var l=U(w,n,D["NS.keys"][L]);if(l instanceof Uint8Array)l=btoa(ag.C4.sv(l,0,l.length));
else if(typeof l!="string"&&typeof l!="number")l=btoa(ag.C4.sv(l["NS.bytes"],0,l["NS.bytes"].length));
m[l]=U(w,n,D["NS.objects"][L])}else for(var L=0;D["NS.key."+L]!=null;L++){var l=U(w,n,D["NS.key."+L]);
if(l instanceof Uint8Array)l=btoa(ag.C4.sv(l,0,l.length));else if(typeof l!="string"&&typeof l!="number")l=btoa(ag.C4.sv(l["NS.bytes"],0,l["NS.bytes"].length));
m[l]=U(w,n,D["NS.object."+L])}for(var A in D)delete D[A];for(var A in m)D[A]=m[A];return D}if(I=="NSURL")return{$class:I,base:U(w,n,D["NS.base"]),relative:U(w,n,D["NS.relative"])};
if(ag.adw.indexOf(I)!=-1){w[W]=U(w,n,D.array_do);return w[W]}if(D.do_objectID!=null)D.do_objectID=U(w,n,D.do_objectID);
if(ag.an8.indexOf(I)!=-1)return D;var g=ag.a6x[I];if(g==null){console.log(w,D);throw"unknown class "+I}for(var L=0;
L<g.length;L++)if(D[g[L]]!=null)D[g[L]]=U(w,n,D[g[L]]);if(I=="MSTextLayer"){var k=D,$,C,f,z;if(k.attributedString)$=k.attributedString.archivedAttributedString;
else $=k.storage;z=$.NSString;if(typeof z!="string")z=J.KY(z["NS.bytes"],0,z["NS.bytes"].length);if($.NSAttributeInfo)C=$.NSAttributeInfo["NS.bytes"];
else{var s=z.length,O=[];while(s>0){var a=Math.min(100,s);O.push(a,0);s-=a}C=new Uint8Array(O)}f=$.NSAttributes instanceof Array?$.NSAttributes:[$.NSAttributes];
var X={$class:"NSAttributedString",NSString:z,NSAttributes:f};k.attributedString={_class:"MSAttributedString",archivedAttributedString:X};
X.NSAttributeInfo={$class:"NSMutableData","NS.data":C};delete k.storage}return D};ag.C4={IQ:function(w,n){return w[n+1]<<8|w[n]},q:function(w,n){return w[n+3]<<24|w[n+2]<<16|w[n+1]<<8|w[n]},sv:function(w,n,W){var D="";
for(var L=0;L<W;L++)D+=String.fromCharCode(w[n+L]);return D}};ag.asI={MSPage:"page",MSArtboardGroup:"artboard",MSShapeGroup:"shapeGroup",MSLayerGroup:"group",MSBitmapLayer:"bitmap",MSTextLayer:"text",MSSliceLayer:"slice",MSSymbolMaster:"symbolMaster",MSSymbolInstance:"symbolInstance",MSStyleFill:"fill",MSShapePathLayer:"shapePath",MSRectangleShape:"rectangle",MSOvalShape:"oval",MSTriangleShape:"triangle"};
ag.adw=["MSArray","MSFillStyleCollection","MSBorderStyleCollection","MSShadowStyleCollection","MSInnerShadowStyleCollection"];
ag.an8="MSArchivedColor MSLayoutGrid MSSimpleGrid MSColor MSRect MSStyleColorControls MSGraphicsContextSettings NSMutableString NSMutableData NSDecimalNumberPlaceholder MSStyleReflection".split(" ");
ag.a6x={MSAssetCollection:["gradients","colors","imageCollection","images"],MSImageCollection:["images"],MSSharedStyleContainer:["objects"],MSSharedTextStyleContainer:["objects"],MSSharedLayerStyleContainer:["objects"],MSSharedLayerTextStyleContainer:["objects"],MSSharedLayerContainer:["objects"],MSSymbolContainer:["objects"],MSGradient:["stops","from","to","points"],MSGradientStop:["color"],MSStyleFill:["color","gradient","contextSettings","image","imageSHA"],MSExportFormat:["fileFormat","name"],MSExportOptions:["exportFormats","includedLayerIds","sizes"],MSRulerData:["guides"],MSStyle:"textStyle fills contextSettings sharedObjectID borders blur shadows innerShadows borderOptions colorControls reflection".split(" "),MSSharedStyle:["name","value"],MSSymbol:["name","value"],MSAttributedString:["archivedAttributedString"],MSSharedLayerStyle:["name","value","instances"],MSSharedLayer:["name","value","instances"],MSDocumentData:"assets layerStyles pages layerTextStyles layerSymbols images userInfo".split(" "),MSShapePathLayer:"exportOptions frame name userInfo path originalObjectID".split(" "),MSOvalShape:"exportOptions frame name userInfo path originalObjectID".split(" "),MSRectangleShape:"exportOptions frame name userInfo path originalObjectID".split(" "),MSPolygonShape:"exportOptions frame name userInfo path originalObjectID".split(" "),MSTriangleShape:"exportOptions frame name userInfo path originalObjectID".split(" "),MSStarShape:"exportOptions frame name userInfo path originalObjectID".split(" "),MSBitmapLayer:"exportOptions frame name userInfo style imageSHA nineSliceCenterRect nineSliceScale image clippingMask originalObjectID".split(" "),MSTextLayer:"exportOptions frame name userInfo style originalObjectID attributedString glyphBounds storage".split(" "),MSShapeGroup:"exportOptions frame name userInfo style originalObjectID layers".split(" "),MSLayerGroup:"exportOptions frame name userInfo style originalObjectID layers sharedObjectID".split(" "),MSArtboardGroup:"exportOptions frame name userInfo style layers horizontalRulerData verticalRulerData layout grid backgroundColor".split(" "),MSPage:"exportOptions frame name userInfo style layers horizontalRulerData verticalRulerData layout grid scrollOrigin".split(" "),MSSymbolMaster:"exportOptions frame name userInfo style layers horizontalRulerData verticalRulerData layout grid originalObjectID symbolID backgroundColor".split(" "),MSSymbolInstance:"exportOptions frame name userInfo style symbolID overrides masterInfluenceBounds originalObjectID".split(" "),MSSliceLayer:["exportOptions","frame","name","userInfo","backgroundColor"],MSTextStyle:["attributes","encodedAttributes"],MSShapePath:["points"],MSPointArray:["points"],MSImageData:["data","sha1","name"],MSCurvePoint:["curveFrom","curveTo","point"],MSImageProxy:["sha1"],MSStyleBorder:["color","gradient","contextSettings"],MSStyleBlur:["center"],MSStyleShadow:["color","contextSettings"],MSStyleInnerShadow:["color","contextSettings"],MSExportSize:["format","name"],MSStyleBorderOptions:["dashPattern"],NSFont:["NSName","NSDescriptor"],NSColor:["NSCustomColorSpace"],NSFontDescriptor:["NSFontDescriptorAttributes"],NSMutableParagraphStyle:["NSTextBlocks","NSTabStops","NSTextLists"],NSAttributedString:["NSAttributes","NSString","NSAttributeInfo"],NSTextStorage:["NSAttributeInfo","NSAttributes","NSString"],NSColorSpace:["NSICC"],NSParagraphStyle:["NSTabStops","NSTextBlocks","NSTextLists"],NSTextList:["NSMarkerFormat"],NSTextTab:["NSTabOptions"],UIFontDescriptor:["UIFontDescriptorAttributes"]};
var du={};du.parse=function(w,n){var W=J.sv(w,n,8);n+=8;var D=w.length-32,j=du.parse.api(w,D),I=[];if(j.Xo==1){var n=D-j.Xo*j.i9;
for(var L=0;L<j.i9;L++)I.push(w[n+L])}else if(j.Xo==2){var n=D-j.Xo*j.i9;for(var L=0;L<j.i9;L++)I.push(J.IQ(w,n+L*2))}else if(j.Xo==4){var n=D-j.Xo*j.i9;
for(var L=0;L<j.i9;L++)I.push(J.q(w,n+L*4))}else{throw"e"}var U=du.parse.nb(w,I,j.root,j);return U};
du.parse.nb=function(w,n,W,D){var j=du.C4,I=D.axO,U=I==4?j.q:I==2?j.IQ:j.ay1,M=du.parse,m=n[W],l=w[m],A=l>>4,g=l&15,$=null;
m+=1;if([4,5,6,10,12,13].indexOf(A)!=-1&&g==15){var k=M.W6(w,m);m+=k._W;g=k.Z}if(!1){}else if(A==0)$=g==8?!1:g==9?!0:null;
else if(A==1)$=M.W6(w,m-1).Z;else if(A==2)$=1<<g==4?J.F_(w,m):J.Gb(w,m);else if(A==3)$=J.Gb(w,m);else if(A==4)$=new Uint8Array(w.buffer,m,g);
else if(A==5)$=J.sv(w,m,g);else if(A==6)$=J.yL(w,m,g);else if(A==8){$=0;for(var L=0;L<g+1;L++)$=$<<8|w[m+L]}else if(A==10){$=[];
for(var L=0;L<g;L++)$.push(M.nb(w,n,U(w,m+I*L),D))}else if(A==12){$=[];for(var L=0;L<g;L++)$.push(M.nb(w,n,U(w,m+I*L),D))}else if(A==13){$={};
for(var L=0;L<g;L++){var C=M.nb(w,n,U(w,m+I*L),D),f=M.nb(w,n,U(w,m+I*(g+L)),D);$[C]=f}}else throw"unknown mask "+A;
return $};du.parse.W6=function(w,n){var W=1<<(w[n]&15),D=0;for(var L=0;L<W;L++)D=D<<8|w[n+1+L];return{Z:D,_W:W+1}};
du.parse.api=function(w,n){var W={};n+=6;W.Xo=w[n];n++;W.axO=w[n];n++;n+=4;W.i9=J.q(w,n);n+=4;n+=4;W.root=J.q(w,n);
n+=4;n+=4;W.a4f=J.q(w,n);n+=4;return W};du.C4={ay1:function(w,n){return w[n]},IQ:function(w,n){return w[n]<<8|w[n+1]},q:function(w,n){return w[n]<<24|w[n+1]<<16|w[n+2]<<8|w[n+3]},sv:function(w,n,W){var D="";
for(var L=0;L<W;L++)D+=String.fromCharCode(w[n+L]);return D}};var i3={parse:function(w){var n=new Uint8Array(w),W=i3.b9(n),D=[],j=new Uint8Array(n.length),I=[];
D.push(I);i3.h9(n,W,1,j,I);for(var L=0;L<I.length;L++){var U=[];D.push(U);i3.h9(n,W,I[L][3],j,U,L==11);
I[L][3]=L+1}return D},h9:function(w,n,W,D,j,I){W--;var U=W*n.dy+(W==0?100:0),M=w[U],m=i3.IQ(w,U+1),l=i3.IQ(w,U+3),A=i3.IQ(w,U+5),k=0;
if(A==0)A=65536;var g=w[U+7];U+=8;if(M==2||M==5){k=i3.q(w,U);U+=4}for(var $=0;$<l;$++){var C=W*n.dy+i3.IQ(w,U+2*$),f=-1,z=0,s=0,O=0;
if(M==2||M==5){f=i3.q(w,C);C+=4}if(M==2||M==10||M==13){z=i3.Hp(w,C);C+=z._W}if(M==5||M==13){s=i3.Hp(w,C);
C+=s._W}if(M==2||M==5){i3.h9(w,n,f,D,j,I);continue}var a=n.dy-(W==0?100:0),X=z.jB,P=M==13?a-35:Math.floor((a-12)*64/255)-23,Z=Math.floor((a-12)*32/255)-23,Y=Z+(X-Z)%(a-4);
if(X<=P){i3.nX(w,C,D,0,X)}else{var K=Y<=P?Y:Z,S=0;i3.nX(w,C,D,0,K);S+=K;O=i3.q(w,C+K);while(O!=0){var G=(O-1)*n.dy;
O=i3.q(w,G);var V=Math.min(n.dy-4,X-S);i3.nX(w,G+4,D,S,V);S+=V}}j.push(i3.a4$(D,X))}if(k!=0)i3.h9(w,n,k,D,j,I)},a4$:function(w,n){var W=0,D=i3.Hp(w,W);
W+=D._W;var j=[],I=[];while(W<D.jB){var U=i3.Hp(w,W);W+=U._W;j.push(U.jB)}if(W!=D.jB)throw"e";for(var L=0;
L<j.length;L++){var U=j[L];if(!1){}else if(U==0)I.push(null);else if(U==1){I.push(i3.av4(w,W));W+=1}else if(U==2){I.push(i3.zx(w,W));
W+=2}else if(U==3){I.push(i3.aAk(w,W));W+=3}else if(U==4){I.push(i3.W6(w,W));W+=4}else if(U==5){I.push(i3.q(w,W+2));
W+=6}else if(U==6){I.push(i3.q(w,W)+":"+i3.q(w,W+4));W+=8}else if(U==7){I.push(i3.al$(w,W));W+=8}else if(U==8)I.push(0);
else if(U==9)I.push(1);else if(U>=12&&(U&1)==0){var M=U-12>>1,m=new Uint8Array(M);i3.nX(w,W,m,0,M);I.push(m);
W+=M}else if(U>=13&&(U&1)==1){var M=U-13>>1;I.push(i3.KY(w,W,M));W+=M}else throw"unknonw type "+U}return I},b9:function(w){if(!(w[18]==1&&w[19]==1&&w[20]==0&&w[21]==64&&w[22]==32&&w[23]==32))throw"unexpected SQL3 header";
var n={nY:i3.sv(w,0,15),dy:i3.IQ(w,16),a5i:i3.q(w,24),size:i3.q(w,28),amu:i3.q(w,32),alx:i3.q(w,36),arM:i3.q(w,40),a9_:i3.q(w,44),a16:i3.q(w,48),ai2:i3.q(w,52),a6$:i3.q(w,56),a5_:i3.q(w,60),a5R:i3.q(w,64)!=0,awe:i3.q(w,68),a8P:i3.q(w,92),a9S:i3.q(w,96)};
if(n.dy==1)n.dy=65536;if(n.a6$!=1)throw"unsupported text encoding "+n.a6$;return n},aiM:function(w,n){return w[n]<<16|w[n+1]<<8|w[n+2]},aAk:function(w,n){var W=i3.aiM(w,n),D=W&8388608;
return D?-(16777215-W+1):W},av4:function(w,n){i3.hQ[0]=w[n];return i3.ajw[0]},W6:function(w,n){var W=i3.hQ;
for(var L=0;L<4;L++)W[L]=w[n+3-L];return i3.aaN[0]},zx:function(w,n){var W=i3.hQ;W[0]=w[n+1];W[1]=w[n];
return i3.aul[0]},IQ:function(w,n){return w[n]<<8|w[n+1]},q:function(w,n){var W=i3.hQ;for(var L=0;L<4;
L++)W[L]=w[n+3-L];return i3.awV[0]},al$:function(w,n){var W=i3.hQ;for(var L=0;L<8;L++)W[L]=w[n+7-L];
return i3.atA[0]},Hp:function(w,n){var W=n,bK=0;while(!0){var D=w[n];n++;bK=bK*128+(D&127);if(D<128)break}return{jB:bK,_W:n-W}},sv:function(w,n,W){var D="";
for(var L=0;L<W;L++)D+=String.fromCharCode(w[n+L]);return D},KY:function(w,n,W){var D="";for(var L=0;
L<W;L++)D+="%"+i3.a2P(w[n+L].toString(16));try{D=decodeURIComponent(D);return D}catch(fV){return D}},nX:function(w,n,W,D,j){if(w[n+j-1]==null||W[D+j-1]==null){console.log(n,D,j);
throw"e"}for(var L=0;L<j;L++)W[D+L]=w[n+L]},a2P:function(bK){return bK.length<2?"0"+bK:bK}};i3.hQ=new Uint8Array(8);
i3.ajw=new Int8Array(i3.hQ.buffer);i3.aul=new Int16Array(i3.hQ.buffer);i3.aaN=new Int32Array(i3.hQ.buffer);
i3.awV=new Uint32Array(i3.hQ.buffer);i3.atA=new Float64Array(i3.hQ.buffer);i3.a5r=function(w,n){var W=w[0],D={};
for(var L=0;L<W.length;L++){var j=W[L],I=j[1];if(j[0]!="table")continue;var U=j[4];U=U.slice(U.indexOf("(")+1,U.indexOf(")"));
U=U.split(",");for(var M=0;M<U.length;M++){var m=U[M].trim().split(" ")[0];if(n&&m.startsWith(I))m=m.slice(I.length);
U[M]=m}var l=D[I]=[],A=w[j[3]];for(var M=0;M<A.length;M++){var g=A[M],k={};l.push(k);for(var $=0;$<U.length;
$++){if(k[U[$]]!=null)throw"e";k[U[$]]=g[$]}}}return D};function f3(w,n,W){this.AR=w;this.N1=n;this.agU=W;
this.iM=new ec(0,0);this.Rc=-1;this.cB=0;this.jL=0;this.HC=new iB;this.yZ=[];this.hj=null;this.afJ=null;
this.vB=null;this.J5=null;this.la=null;this.a4L=null}f3.prototype.StartPage=function(w,n,W,D,j){var I=this.N1,U=I.NW(),M=1,m=(W-w)*(D-n);
if(j!=null)m=j;while(m*U*U/(M*M)>2*8192*8192)M++;I.scale(1/M,1/M);this.afJ=[w,n,W,D];var M=I.NW();w=Math.round(w*M);
n=Math.round(n*M);W=Math.round(W*M);D=Math.round(D*M);var l=this.AR,A=this.vB;if(A==null){I.z2=-w}else{var g=A[2]-A[0]+30,k=Math.round(W-w)+30;
if(this.iM.x+g+k>8192){I.z2=-w;this.iM.x=0;this.iM.y+=this.jL+120;this.jL=0}else{I.z2+=g;this.iM.x+=g}}I.EU=this.iM.y+(this.agU?D:-n);
this.jL=Math.max(this.jL,Math.round(D-n));this.vB=[w,n,W,D];this.ao6=[];l.C.push(l.hG())};f3.prototype.StartTGroup=function(w){this.GR();
var n=this.AR;n.C.push(n.hG());var W=f3.IR[w.bmode];if(W==null)W="norm";var D=n.QI();D.nz("<Group>");
D.add.lsct=ef.fz;D.Bx=W=="norm"?"pass":W;D.FK=24;D.opacity=Math.round(255*w.ca);this.ao6.push(D)};f3.prototype.EndTGroup=function(){this.AR.C.push(this.ao6.pop())};
f3.prototype.aif=function(){var w=this.AR,n=w.C[w.C.length-1];return n};f3.prototype.aok=function(){var w=JSON.parse(JSON.stringify(at.QO.default));
w.strokeStyleLineAlignment.v.strokeStyleLineAlignment="strokeStyleAlignCenter";w.strokeEnabled.v=!1;
w.fillEnabled.v=!1;return w};f3.prototype.acU=function(){var w=this.AR,n=w.QI();n.nz("Path "+w.C.length);
this.AR.C.push(n);n.FK|=16;n.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}};n.add.vmsk=new h.Rd;
n.add.vstk=this.aok();return n};f3.prototype.g_=function(w){var n={w:w.crds,F:w.cmds},W=E.p.oF(n,!1);
E.P.c0(W,this.N1);return W};f3.a9w=function(w,n){for(var L=0;L<w.length;L++)if(w[L].Ht!=null)w[L].Ht=n};
f3.apa=function(w){return Math.sqrt(Math.abs(w[0]*w[3]-w[1]*w[2]))};f3.RH=function(w){return E.M.lW({o:w[0]*255,B:w[1]*255,k:w[2]*255})};
f3.Hg=function(w){return new eh(w[0],w[1],w[2],w[3],w[4],w[5])};f3.prototype.Stroke=function(w){if(this.Rc!=-1&&this.Rc!=this.cB)return;
if(w.pth.cmds.length<=1)return;var n=this.g_(w.pth);if(n.length<=2)return;this.IV(w);f3.a9w(n,-1);n[2].Ht=1;
var W=f3.RH(w.COLR),D=this.aif(),j=this.aok();f3.ZC(j,w,this.N1.NW(),W);var I=D!=null&&D.add.vmsk!=null&&!D.ue(),U=I&&!D.add.vstk.strokeEnabled.v&&h.Rd.an3(D.add.vmsk.i,n,!0),M=I&&!D.add.vstk.fillEnabled.v&&JSON.stringify(j)==JSON.stringify(D.add.vstk);
if(M){D.add.vmsk.i=D.add.vmsk.i.concat(n.slice(2))}else if(U){D.add.vstk=j;j.fillEnabled.v=!0}else{D=this.acU();
D.add.vmsk.i=n;D.add.vstk=j}};f3.ZC=function(w,n,W,D){w.strokeEnabled.v=!0;w.strokeStyleMiterLimit.v=n.mlimit;
w.strokeStyleLineDashSet.v=ge.zW(n.dash,1/n.lwidth);w.strokeStyleLineDashOffset.v.val=n.doff;w.strokeStyleLineJoinType.v.strokeStyleLineJoinType=at.QO.join[n.ljoin];
w.strokeStyleLineCapType.v.strokeStyleLineCapType=at.QO.EZ[n.lcap];w.strokeStyleLineWidth.v.val=Math.max(.4,n.lwidth*f3.apa(n.ctm)*W);
w.strokeStyleContent.v.Clr.v=D};f3.prototype.Fill=function(w,n){if(this.Rc!=-1&&this.Rc!=this.cB)return;
if(w.ca==0)return;var W=w.pth.cmds;if(W.length==0)return;if(W.length==2&&JSON.stringify(W)=="[\"M\",\"L\"]")return;
var D=E.p.mY(w.pth.crds),j=E.p.mY(w.cpth.crds);if(D.wU(j).VY())return;var I=w.pth,U=UDOC.G.isBox(I,[D.x,D.y,D.x+D.m,D.y+D.n]),M=w.cpth,m=UDOC.G.isBox(M,[j.x,j.y,j.x+j.m,j.y+j.n]);
if(U&&m&&D.O()>j.O()*2){var l=D.wU(j),A=l.x,g=l.y,k=A+l.m,$=g+l.n;I={cmds:["M","L","L","L","Z"],crds:[A,g,k,g,k,$,A,$]};
D=l}else if(this.J5==null&&UDOC.G.isBox(I,[D.x,D.y,D.x+D.m,D.y+D.n])&&D.Yy(j)){I=M;D=j}else this.IV(w);
var C=this.g_(I),f=E.p.Wx(D);E.p.D(f.w,this.N1,f.w);D=E.p.mY(f.w);var z=f3.ajA(w.colr,this.N1,D),s=this.aif(),O=s!=null&&s.opacity==Math.round(255*w.ca)&&s.add.vstk!=null&&!s.add.vstk.strokeEnabled.v&&s.add.SoCo&&z.type=="SoFi"&&JSON.stringify(s.add.SoCo.Clr.v)==JSON.stringify(z.Z.v.Clr.v);
if(O){var a=!1;for(var L=0;L<C.length;L++){if(C[L].Ht==0||C[L].Ht==2)a=!0}if(a){var X=E.p.mY(E.P.Mn(s.add.vmsk.i)),P=E.p.mY(E.P.Mn(C));
O=X.wU(P).VY()}}if(O){var Z=s.add.vmsk.i;for(var L=2;L<C.length;L++)Z.push(C[L])}else{s=this.acU();delete s.add.SoCo;
s.add.vmsk.i=h.Rd.Tv(C);f3.f7(w.colr,s,this.N1,D);f3.a4G(w,s)}};f3.f7=function(w,n,W,D){var j=f3.ajA(w,W,D),I=null,U=null;
n.add.vstk.fillEnabled.v=!0;if(j.type=="SoFi"){I="SoCo";U=at.Oa}if(j.type=="GrFl"){I="GdFl";U=at.Ki}if(j.type=="patternFill"){I="PtFl";
U=at.v7}if(I!=null){n.add[I]={classID:"null"};for(var L=0;L<U.length;L++){var M=U[L];n.add[I][M]=j.Z.v[M]}}};
f3.prototype.IV=function(w){var n=this.AR,W=w.cpth,D=W.cmds.join(""),j=W.crds,I=D+" "+j.join(","),U=UDOC.G.isBox(W,this.afJ);
if(U&&this.J5==null)return;if(I==this.J5)return;this.GR();if(!U){this.J5=I;n.C.push(n.hG());var M=n.QI();
M.nz("Mask");M.add.lsct=ef.Se;M.Bx="pass";M.FK=24;var m=M.add.vmsk=new h.Rd;m.i=this.g_(w.cpth);if(UDOC.G.isBox(W)){this.la=E.P.b3(m.i);
this.la.VD(3,3)}else this.la=null;this.a4L=M}};f3.prototype.GR=function(){var w=this.AR;if(this.J5!=null){var n=w.C.length-1,L=n,W=!1;
while(L>=0&&w.C[L].add.lsct!=ef.Cq)L--;var D=this.la;if(D){var j=new iB,I=n;while(I>L){j=w.C[I].$k(this.AR,!1,!0);
I--}W=D.Yy(j)}if(W){this.yZ.splice(L,1);w.C.splice(L,1)}else{w.C.push(this.a4L)}this.J5=null}};f3.ajA=function(w,n,W){var D,j;
if(w.length!=null){D="SoFi";var I=JSON.parse(at.UR[at.order.indexOf("SoFi")]);j={t:"Objc",v:I};j.v.Clr.v=f3.RH(w)}else{var U=f3.apf(w,n,W);
D="GrFl";j={t:"Objc",v:U}}return{type:D,Z:j}};f3.apf=function(w,n,W){var D=JSON.parse(at.UR[at.order.indexOf("GrFl")]),j=D.Grad.v;
j.Intr.v=0;var I=f3.Hg(w.mat);I.concat(n);var U=new ec(0,0),M=new ec(W.m,0),m=w.crds;if(w.typ=="rad"){D.Type.v.GrdT="Rdl";
var l=.7;U.x=(1-l)*m[0]+l*m[3];U.y=(1-l)*m[1]+l*m[4];M.x=U.x;M.y=U.y;M.x+=Math.max(m[2],m[5])}else{D.Type.v.GrdT="Lnr";
U.x=m[0];U.y=m[1];M.x=m[2];M.y=m[3];U.x=M.x+.5*(U.x-M.x);U.y=M.y+.5*(U.y-M.y)}U=I.bj(U);M=I.bj(M);E.M.n0(U,M,W,D);
var A=w.grad;E.M.WP(A,j);return D};f3.prototype.PutText=function(w,n,W,D){var j=n.charCodeAt(0),$=null;
if(this.Rc!=-1&&this.Rc!=this.cB)return;if(n.length==0||n.length==1&&(j==0||j==8203))return;this.IV(w);
var I=this.AR,U=w.font,M=Math.round(255*w.ca);if(w.font.Tmode==3)M=0;var m=f3.Hg(w.ctm);m.concat(this.N1);
var l=f3.Hg(U.Tm);l.concat(m);var A=l.NW(),g=new eh(1/A,0,0,-1/A,0,0);g.concat(l);var k=U.Tfs*A,C=I.C.length-1;
while(C>=0&&I.C[C].add.TySh==null)C--;if(g.k*g.k+g.Cj*g.Cj<.001&&D==null&&C>=0&&I.C[C].add.TySh&&I.C[C].opacity==M){var f=I.C[C],z=this.yZ[C],s=f.add.TySh.D,O=(g.z2-z.a6J)/k,a=Math.abs(O),X=s.dl==g.dl&&s.k==g.k&&s.Cj==g.Cj&&s.j7==g.j7,P=g.EU-z.Xa,Z=X&&Math.abs(P)<1e-5&&a<1;
if(Z){$=f;if(O>.2&&[".",",","?",":","!"].indexOf(n)==-1){n=" "+n;W+=.5}}else if(X&&0<P&&P<k*1.7&&z.ao0==k){$=f;
this.a8Q(z);z.Xa=g.EU;z.a5f=g.z2;n="\n"+n}}if($==null){C=I.C.length;this.yZ[C]={xW:[],Vl:0,a6J:g.z2,Xa:g.EU,a5f:g.z2,tT:"",ao0:k};
$=I.QI();I.C.push($);$.add.lnsr="rend";$.add.TySh=hd._3(0,0);$.add.TySh.D=g}var z=this.yZ[C];z.Vl+=W*k;
z.tT+=n;z.a6J=g.z2+W*k;var Y=$.add.TySh._o,K=hd.Bb(Y);if(D){hd.VL(Y,1);var S=[0,0,Math.ceil(D[0]*A),Math.ceil(D[1]*A)];
hd.sV(Y,S)}var G=K.length-1,V=G+n.length;hd.KO(Y,G,n);if(this.hj==null)this.hj=hd.tG(Y,G,G);var T=this.hj;
T.lJ.FontSize=Math.round(k);T.lJ.Tracking=Math.round(U.Tc*100);T.lJ.Underline=U.Tun==1;T.lJ.FillColor={Type:1,Values:[1,w.colr[0],w.colr[1],w.colr[2]]};
if(U.Tal!=null)T.ci.Justification=U.Tal;if(z.xW.length!=0){T.lJ.AutoLeading=!1;T.lJ.Leading=z.Xa-z.xW[z.xW.length-1].y}var R=U.Tf;
R=R.replace(/#2B/g,"+");R=R.replace(/#2C/g,"-");R=R.split("+").pop();var x={"NimbusRomNo9L-Medi":"NimbusRomNo9L-Med","NimbusRomNo9L-Regu":"NimbusRomNo9L-Reg","NimbusRomNo9L-MediItal":"NimbusRomNo9L-MedIta","NimbusRomNo9L-ReguItal":"NimbusRomNo9L-RegIta",CMTT9:"NimbusMono-Regular",Arial:"ArialMT","BebasNeue-Regular":"BebasNeueRegular"};
if(x[R])R=x[R];hd.hI(T,R);hd.g0(Y,G,V-1,T);$.iQ();$.opacity=M};f3.prototype.a8Q=function(w){w.xW.push({gA:w.Vl,ib:w.tT.slice(w.xW.length==0?0:1)+"\n",x:w.a5f,y:w.Xa,_6:w.ao0});
w.Vl=0;w.tT=""};f3.prototype.rn=function(w,n,W){return new Uint8Array(jj.ZO("PNG").La([[w.buffer,0]],n,W))};
f3.prototype.PutImage=function(w,n,W,D,j,I,U){if(this.Rc!=-1&&this.Rc!=this.cB)return;var M=this.AR,m=w.font.Tmode;
if(m==7&&M.C[M.C.length-1].add.TySh){return}this.IV(w);var l=f3.Hg(w.ctm);l.concat(this.N1);var A=new eh(1/W,0,0,-1/D,0,1);
A.concat(l);l=A;n=f3.abl(n,W,D,I,!1);if(j)j=f3.abl(j,W,D,U,!0);if(j==null){if(n.length==W*D*4)n=this.rn(n,W,D)}else{n=this.azB(n,W,D,I,!1);
j=this.azB(j,W,D,U,!0);var g=E.Q(W*D);E.hN(j,g,0);E.IL(g,n,3);n=this.rn(n,W,D)}var k=M.An(n,"Bitmap",0,0),$=k.rect.clone();
$.x=$.y=0;var C=E.p.Wx($).w;E.p.D(C,l,C);k.add.SoLd.Trnf=y.wR.Hh(C);k.add.SoLd.nonAffineTransform=y.wR.Hh(C);
k.vr(M,!1);f3.a4G(w,k);M.C.push(k)};f3.a4G=function(w,n){n.opacity=Math.round(255*w.ca);var W=f3.IR[w.bmode];
if(W==null)console.log("Unknown blend mode",W);else n.Bx=W};f3.IR={"/Normal":"norm","/Multiply":"mul ","/Screen":"scrn","/Overlay":"over","/Darken":"dark","/Lighten":"lite","/ColorDodge":"div ","/ColorBurn":"idiv","/HardLight":"hLit","/SoftLight":"sLit","/Difference":"diff","/Exclusion":"smud","/Hue":"hue ","/Saturation":"sat ","/Color":"colr","/Luminosity":"lum "};
f3.ahd=function(w){if(w=="pass")w="norm";for(var n in f3.IR)if(f3.IR[n]==w)return n};f3.abl=function(w,n,W,D,j){var I=jj.zJ(w.buffer);
if(I=="jpg"){try{w=new Uint8Array(jj.ZO("JPG").a25(w.buffer))}catch(fV){w=new Uint8Array(n*W*4)}}else if(I=="jb2"){w=new Uint8Array(jj.ZO("JPG").Vu(w.buffer,D,j)[0].data)}else if(w.length!=n*W*4){var U=new Uint8Array(n*W*4),M=Math.ceil(n/8),m=new Uint8Array(W*M);
UTIF.decode._decodeG4(w,0,w.length,m,0,n,1);var l=m[0]==(j?255:0);for(var A=0;A<W;A++){var g=M*A;for(var k=0;
k<n;k++){var L=A*n+k,$=L*4,C=(m[g+(k>>3)]>>7-(k&7)&1)*255;if(l)C=255-C;U[$]=C;U[$+1]=C;U[$+2]=C;U[$+3]=255}}w=U}return w};
f3.prototype.azB=function(w,n,W,D,j){if(w.length!=n*W*4){var I=jj.zJ(w.buffer);if(I=="jb2")throw"e";
var U=jj.ZO(I);if(U==null||I=="tga")U=jj.ZO("jpg");w=new Uint8Array(U.Vu(w,D,j)[0].data)}return w};f3.prototype.ShowPage=function(){var w=this.AR;
this.cB++;var n=this.vB;this.GR();var W=w.QI();w.C.push(W);var D=new iB(Math.round(this.iM.x),Math.round(this.iM.y),Math.round(n[2]-n[0]),Math.round(n[3]-n[1]));
if(D.VY())D.m=D.n=2e3;this.HC=this.HC.x0(D);W.MR(D);W.add.artb.artboardBackgroundType.v=1;W.nz("Page "+this.cB);
W.add.lsct=ef.Se;W.Bx="pass";W.FK=24};f3.prototype.Print=function(w){console.log("Print:",w)};f3.prototype.Done=function(){var w=this.AR;
if(this.cB==1)w.C[w.C.length-1].add.lsct=ef.fz;w.om(this.cB);for(var L=0;L<w.C.length;L++){var n=w.C[L],W=n.add.vmsk,D=n.add.TySh,j=this.yZ[L];
n.hu();if(W){var I=!1;for(var U=0;U<W.i.length;U++){var M=W.i[U];if((M.type==0||M.type==3)&&M.length>32767)I=!0}if(I){w.C.splice(L,1);
L--;continue}}n.yb(w);if(D&&j&&j.xW.length!=0){this.a8Q(j);var m=D._o,l=j.xW.length,A=j.xW[0],g=1e9,k=-1e9,Z="";
for(var U=0;U<l;U++){var $=j.xW[U];g=Math.min(g,$.x);k=Math.max(k,$.x+$.gA)}var C=[];for(var U=0;U<l;
U++){var $=j.xW[U],f=-1,z=A._6*.1,s=Math.abs($.x-g),O=Math.abs($.x+$.gA-k),a=Math.abs(s-O);if(a<z)f=2;
if(O<z){f=1;if($.x!=g)if(U!=0&&j.xW[U-1].x==$.x||U!=l-1&&j.xW[U+1].x==$.x)f=-1}if(s<z)f=0;if($.gA==k-g)f=3;
C.push(f)}var X=[!1,!1,!1];for(var U=0;U<l;U++){var f=C[U];if(f==3)f=U==0?C[U+1]:C[U-1];if(f==3)f=0;
C[U]=f;X[f]=!0}var P=(k-g)*.05;if(X[0]&&!X[1])k+=P;if(!X[0]&&X[1])g-=P;if(!X[0]&&!X[1]){g-=P;k+=2*P}hd.VL(m,1);
D.D.EU-=A._6*.7;D.D.z2=Math.round(g);hd.sV(m,[0,0,Math.ceil(k-g),Math.ceil(j.xW[l-1].y-A.y+A._6*2)]);
for(var U=0;U<l;U++){var $=j.xW[U],f=C[U],Y=0;if(f==-1){f=0;Y=Math.round($.x-g)}var K=Z.length,S=K+$.ib.length;
Z+=$.ib;var G={JO:[],lJ:{},ci:{Justification:f,StartIndent:Y}};hd.g0(D._o,K,S-1,G)}}if(D){var m=D._o;
hd.ad8(m);var V=hd.Bb(m).split("\n");for(var U=0;U<V.length-1;U++){var $=V[U],T=0;for(var R=0;R<$.length;
R++){var x=$.charCodeAt(R);if(1473<=x&&x<=1524)T++}if(T>$.length/2){V[U]=$.split("").reverse().join("");
var v=m.EngineDict.ParagraphRun.RunArray[U].ParagraphSheet.Properties;v._Direction=1;v.Justification=hd.Hm(v)}}hd.Gc(m,V.join("\n"))}}w.XW=!0;
w.m=this.HC.m;w.n=this.HC.n;w.buffer=E.Q(this.HC.O()*4)};var jv={};jv.tI=null;jv.z8=function(w,n,W,D,j,I){if(j==null)j=w.m;
if(I==null)I=w.n;jv.tI=w;var U=!1,M=[w.root],m=w.root.children;if(w.add.artd){U=!0;for(var L=0;L<m.length;
L++)if(m[L].j.add.artb==null)U=!1;if(U)M=m}var l=new iB(0,0,w.m,w.n),A=n[0];A=A.replace(/,/g," ").replace(/\-/g," - ").replace(/ +/g," ").trim();
A=A.split(" ");var g=[];for(var L=0;L<A.length;L++){var k=A[L];if(k=="-"){var $=g.pop(),C=parseInt(A[L+1]);
while($<C){g.push($);$++}}else g.push(parseInt(k))}A=g;for(var L=0;L<A.length;L++)if(isNaN(A[L])||A[L]<1||A[L]>M.length){A.splice(L,1);
L--}var f=j/w.m,z=I/w.n,s=f*72/w.hh,O=z*72/w.hh,a=n[5];if(a==null)a=0;var X=72*a,P=72*a;for(var Z=0;
Z<M.length;Z++){var L=Z;if(n[2])L=M.length-1-Z;if(A.length!=0&&A.indexOf(L+1)==-1)continue;var Y=M[L],K=U?Y.j.yP():l;
if(!Y.j.I4())continue;var S=Math.round(K.m*s+2*X),G=Math.round(K.n*O+2*P);W.StartPage(0,0,S,G);var V=UDOC.getState(),T=new eh;
T.translate(-K.x,-K.y-K.n);T.scale(s,-O);T.translate(X,P);if(U){var R=Y.j.add.artb,x=R.artboardBackgroundType.v;
if(x!=1&&x!=3){var v=Y.j.L9(),N=X*s,u=P*O,H=N+K.m*s,F=u+K.n*O;V.colr=[(v>>>0&255)/255,(v>>>8&255)/255,(v>>>16&255)/255];
V.pth={cmds:["M","L","L","L","Z"],crds:[N,u,H,u,H,F,N,F]};W.Fill(V)}}if(n[3]){var t=w.Vc();if(!l.s9(K)){t=E.Q(K.O()*4);
E.Cb(w.Vc(),l,t,K)}var o=w.Xf();if(o)ICC.U.applyLUT(o[w.add.fcmy==1?5:3],o[2],t,t);if(n[1]!=100){var q=jj.ZO("JPG").La([[t.buffer]],K.m,K.n,[n[1]]);
t=new Uint8Array(q)}var _=new eh;_.translate(K.x,K.y);jv.Xt(V,W,t,K,_,T)}else{jv.aeU(w,Y,V,W,T,n,D);
if(X!=0){var N=X,u=P,H=N+K.m,F=u+K.n,d=H+X,r=F+X;V.ca=1;V.colr=[1,1,1];V.pth={cmds:"M L L L Z M L L L Z".split(" "),crds:[0,0,0,r,d,r,d,0,N,u,H,u,H,F,N,F]};
W.Fill(V)}}if(n[6]){var p=[[0,0],[1,0],[1,1],[0,1]],Q=50,B=5,i=Q*.5,c=B*.5;V.colr=[.1,.1,.1];for(var Z in p){var h2=p[Z],jX=[Z==0||Z==3?-1:1,Z==0||Z==1?-1:1],bm=[X-i+c*jX[0]+h2[0]*w.m,P-(jX[1]!=1?B:0)+h2[1]*w.n],dC=[X-(jX[0]!=1?B:0)+h2[0]*w.m,P-i+c*jX[1]+h2[1]*w.n];
V.pth={cmds:"M L L L Z M L L L Z".split(" "),crds:[bm[0],bm[1],bm[0]+Q,bm[1],bm[0]+Q,bm[1]+B,bm[0],bm[1]+B,dC[0],dC[1],dC[0]+B,dC[1],dC[0]+B,dC[1]+Q,dC[0],dC[1]+Q]};
W.Fill(V)}}W.ShowPage()}W.Done();jv.tI=null};jv.Zi=function(w){w=E.M.y_(w);return[w.o/255,w.B/255,w.k/255]};
jv.aeU=function(w,n,W,D,j,I,U){var M=n.j,m=M.add.lsct,l=M.add.lmfx,A=M.add.vmsk,g=M.add.vstk,k=M.add.TySh,s,O,V;
if(!M.I4())return;var $=M.opacity/255,C=M.add.iOpa!=null?M.add.iOpa/255:1;W.bmode=f3.ahd(M.Bx);var f=W.ca;
W.ca=W.CA=$*C;var z=l;if(z)z=z.solidFillMulti.v[0];if(z)z=z.v;if(z&&!z.enab.v)z=null;var a=M.rect;if(M.Jp()&&(!M.ue()||M.US&&M.US.gY)){if(M.ue()){s=M.US.gY;
a=M.US.axv}else{s=E.Q(M.rect.O());E.hN(M.buffer,s,3)}O=ge.og(l,M.add.fxrp,s,a,w,a).type;var X=["DrSh","OrGl"];
if(C!=1||g&&!g.fillEnabled.v){var P=s.slice(0);E.Ba(P);for(var L=0;L<X.length;L++){var Z=O[X[L]];for(var Y=0;
Y<Z.length;Y++){var K=Z[Y],S=K.aA.clone();S.x+=a.x;S.y+=a.y;E.AG(P,a,K.Q0,S)}}}}if(O)jv.azT(M,s,a,O,W,D,j,I,!0);
var G=ge.anc(M,!1);if(G){D.StartTGroup(W);V=W;W=UDOC.getState()}var T=A&&!M.I9();if(T){var R=E.p.tq(A.i,!1),x=R.VN;
E.p.D(x.w,j,x.w);W.cpth={cmds:x.F,crds:x.w}}if(M.ue()){for(var L=0;L<n.children.length;L++)jv.aeU(w,n.children[L],W,D,j,I,U)}else if(A&&M.I9()&&M.add.PtFl==null){var v=A.i,N=E.P.b3(v),u=!1;
if(g.fillEnabled.v){var H=ge.mw(l,M.add),F=H[0],t=H[1];W.colr=jv.DO(F?F:t,j,N);u=!0}var o=ge.Qk(l);if(!g.strokeEnabled.v&&o)g=o;
var R=E.p.tq(v,g.strokeEnabled.v),x=R.VN;E.p.D(x.w,j,x.w);W.pth={cmds:x.F,crds:x.w};jv.adY(D,W,u,g,j,N,R.M0!=0)}else if(k&&I[4]){var q=k._o,_=new d2(q,U),x=aj.wh(_,k),d=E.p.e7(x),r=ge.Qk(l);
for(var p in d){var Q=parseInt(p.slice(1,7),16),B=0;W.colr=z?jv.Zi(z.Clr.v):jv.axT(Q);var i=d[p];E.p.D(i.w,j,i.w);
i=E.p.ac9(i);W.pth={cmds:i.F,crds:i.w};var g=r;if(p.length>7){g=JSON.parse(JSON.stringify(at.QO.default));
var c=p.slice(7).split("-"),Q=parseInt(c[1].slice(1),16),h2=jv.axT(Q);g.strokeEnabled.v=!0;g.strokeStyleLineWidth.v.val=parseFloat(c[2]);
g.strokeStyleContent.v.Clr.v=z?z.Clr.v:E.M.lW({o:h2[0]*255,B:h2[1]*255,k:h2[2]*255});g.strokeStyleMiterLimit.v=parseFloat(c[2])}jv.adY(D,W,!0,g,j,null,!1)}}else if(k){var q=JSON.parse(JSON.stringify(k._o));
hd.ad8(q);var jX=k.D.clone(),bm=new eh(1,0,0,-1,0,0);bm.concat(jX);bm.concat(j);var dC=hd.Bb(q),_=new d2(q,U);
for(var L=0;L<_.ci.length;L++){var fn=_.ci[L];if(fn.yr.length==1&&fn.yr[0].xS)continue;for(var Y=0;Y<fn.Uv.length;
Y++){var fK=fn.Uv[Y],i6=fn.zt.y+fK.zt.y,dh=fn.yr[fK.start].start,kA=fn.yr[fK.end-1].end,ig=hd.aw7(q,dh,kA);
for(var iJ=0;iJ<ig.length;iJ++){var fL=_.ic(dh),fB=ig[iJ],ah=hd.tG(q,dh,dh),eS=ah.JO[ah.lJ.Font].Name;
W.font.Tf=eS;var p=hd.y_(ah.lJ.FillColor);W.colr=z?jv.Zi(z.Clr.v):[p.o/255,p.B/255,p.k/255];var gL=W.font.Tfs=Math.round(ah.lJ.FontSize),e_=dC.slice(dh,dh+fB);
if(ah.lJ.FontCaps==2)e_=e_.toUpperCase();var c2=new eh;c2.translate(fL.WH.x,-i6);c2.concat(bm);W.ctm=[c2.dl,c2.k,c2.Cj,c2.j7,c2.z2,c2.EU];
D.PutText(W,e_,0);for(var jS=0;jS<2;jS++){var ie=ah.lJ[jS==0?"Strikethrough":"Underline"];if(!ie)continue;
var as=_.ic(dh+fB-1),gb=jS==0?.27:-.2,gx=gL*gb,di=gL*(gb+.07),B=as.WH.x+as.WH.m-fL.WH.x,e6=[0,gx,B,gx,B,di,0,di];
E.p.D(e6,c2,e6);W.pth={cmds:["M","L","L","L","Z"],crds:e6};D.Fill(W)}W.ctm=[1,0,0,1,0,0];dh+=fB}}}}else if(!M.rect.VY()){var dt,gJ,iW=!1,g5=new eh,jW=M.add.SoLd,eP=!0;
if(jW)eP=E.K.RC(E.K.kN(y.wR.Aa(jW.Trnf)));var b_=w.Xf();if(jW&&eP&&b_==null){var fZ=jW.Idnt.v,j3=w.Zy(fZ,jW.Crop?jW.Crop.v:null),fM="";
if(j3==null)return;var dr=j3.PO,c0=jj.zJ(j3.raw.buffer);if(I[7].indexOf(c0)!=-1){dt=j3.raw;iW=!0}else dt=dr[0];
gJ=dr[1];g5=E.K.ce(jW)}else{dt=M.buffer;gJ=M.rect;g5.translate(gJ.x,gJ.y);if(b_){dt=dt.slice(0);ICC.U.applyLUT(b_[w.add.fcmy==1?5:3],b_[2],dt,dt)}}if(z&&!iW)dt=ge.a2b(dt,z,gJ);
jv.Xt(W,D,dt,gJ,g5,j);if(z&&iW){var e6=[0,0,gJ.m,0,gJ.m,gJ.n,0,gJ.n];E.p.D(e6,g5,e6);E.p.D(e6,j,e6);
var cB=JSON.parse(JSON.stringify(W));cB.ca=z.Opct.v.val/100;cB.pth={cmds:["M","L","L","L","Z"],crds:e6};
cB.colr=jv.Zi(z.Clr.v);D.Fill(cB)}}if(T)W.cpth=null;if(G){D.EndTGroup();W=V}W.ca=W.CA=f;if(O)jv.azT(M,s,a,O,W,D,j,I,!1)};
jv.adY=function(w,n,W,D,j,I,U){var M=!1,m=0,A=0;if(D&&D.strokeEnabled.v){var g=D.strokeStyleContent.v,k=D.strokeStyleLineDashSet.v;
m=at.QO.n2.indexOf(D.strokeStyleLineAlignment.v.strokeStyleLineAlignment);n.COLR=jv.DO(g,j,I);A=D.strokeStyleLineWidth.v.val*j.NW();
n.mlimit=D.strokeStyleMiterLimit.v*j.NW();n.doff=D.strokeStyleLineDashOffset.v.val;n.ljoin=at.QO.join.indexOf(D.strokeStyleLineJoinType.v.strokeStyleLineJoinType);
n.lcap=at.QO.EZ.indexOf(D.strokeStyleLineCapType.v.strokeStyleLineCapType);n.dash=[];for(var L=0;L<k.length;
L++)n.dash.push(k[L].v.val*A);if(n.dash.length==1&&n.dash[0]==0)n.dash=[];M=!0}var $=m==2;if(W&&!$)w.Fill(n,U);
if(M){n.lwidth=A*(m==2?2:1);w.Stroke(n)}if(W&&$)w.Fill(n,U)};jv.aqn=function(w){var n=jv.tI;if(n==null)return w;
var W=n.Xf();if(W&&n.add.fcmy){var D=new Uint8Array(4);D[0]=.5+w[0]*255;D[1]=.5+w[1]*255;D[2]=.5+w[2]*255;
ICC.U.applyLUT(W[n.add.fcmy==1?5:3],W[2],D,D);w=[D[0]/255,D[1]/255,D[2]/255]}return w};jv.Zi=function(w){w=E.M.y_(w);
return jv.aqn([w.o/255,w.B/255,w.k/255])};jv.axT=function(w){return jv.aqn([(w>>>16&255)/255,(w>>>8&255)/255,(w&255)/255])};
jv.DO=function(w,n,W){if(w.Clr)return jv.Zi(w.Clr.v);var D=w,j=D.Rvrs?D.Rvrs.v:!1,I=D.Type.v.GrdT,U,M=I=="Rdl"||I=="Dmnd"?"rad":"lin",m=E.M.Du(D,W),l=n.bj(m[0]),A=n.bj(m[1]);
if(M=="rad")U=[l.x,l.y,0,l.x,l.y,ec.cS(l,A)];else{l.y1(A.x+(l.x-A.x)*2,A.y+(l.y-A.y)*2);U=[l.x,l.y,A.x,A.y]}var g=E.M.P$(D.Grad.v,j);
return{typ:M,mat:[1,0,0,1,0,0],grad:g,crds:U}};jv.azT=function(w,n,W,D,j,I,U,M,m){var l=W.clone(),A=n;
if(w.add.TySh&&!M[3]&&!M[4])return;var g=j.ca,k=j.bmode;for(var L=at.order.length-1;L>=0;L--){var $=at.order[L];
if($=="GrFl"||$=="SoFi")continue;if((w.add.vmsk||w.add.TySh)&&$=="FrFX")continue;var C=D[$],f=L>7||$=="FrFX";
if(f!=m)continue;for(var z=0;z<C.length;z++){var s=C[z];if(s.aA==null)s=s.WY?s.WY:s.T4;var O=s.aA.clone();
O.offset(l.x,l.y);if(!f){if(!l.Yy(O)){var a=l.x0(O),X=E.Q(a.O());E.B0(A,l,X,a);A=X;l=a}E.AG(A,l,s.Q0,O)}if(f&&$=="FrFX"&&s.fO)E.AG(s.fO,O,s.Q0,O);
var P=new eh;P.translate(O.x,O.y);j.ca=s.K8;j.bmode=f3.ahd(s.ZA);jv.Xt(j,I,s.Q0,O,P,U)}}j.ca=g;j.bmode=k};
jv.Xt=function(w,n,W,D,j,I){var U=new eh;U.scale(D.m,-D.n);U.translate(0,D.n);U.concat(j);U.concat(I);
w.ctm=[U.dl,U.k,U.Cj,U.j7,U.z2,U.EU];n.PutImage(w,W,D.m,D.n);w.ctm=[1,0,0,1,0,0]};var eD={};eD.ew=function(w){var n=new Uint8Array(w);
return eD._t(n,0)};eD._t=function(w,n){var W=J.q,D=J.sv,j={Z4:D(w,n,4),R:n+8,size:W(w,n+4)},I=j.Z4=="FORM"||j.Z4=="LIST"||j.Z4=="CAT ";
if(I)j.W_=D(w,n+8,4);if(j.size<0||j.R+j.size>w.length)throw"e";if(I){j.sub=[];n+=12;var U=j.R+j.size;
while(n<U){var M=eD._t(w,n);j.sub.push(M);n+=8+M.size+(M.size&1)}}return j};var ce={};ce.ew=function(w,n){var W=new Uint8Array(w);
return ce._t(W,0,n)};ce._t=function(w,n,W){var D=J.ly,j=J.sv,I={Z4:j(w,n,4),R:n+8,size:D(w,n+4)};if(W&&W[I.size]!=null)I.size=W[I.size];
if(I.Z4=="RIFF"||I.Z4=="LIST"){I.W_=j(w,n+8,4)}if(I.size<0||I.R+I.size>w.length)throw"e";if(I.Z4=="RIFF"||I.Z4=="LIST"&&(I.W_!="cmpr"&&I.W_!="stlt")){I.sub=[];
n+=12;var U=I.R+I.size;while(n<U){var M=ce._t(w,n,W);I.sub.push(M);n+=8+M.size+(M.size&1)}}return I};
var a5=function(){function w(Q,B){var i=null;if(Q.sub==null)return i;for(var L=0;L<Q.sub.length;L++){var c=Q.sub[L];
if(c.Z4==B||c.W_==B)i=c}return i}function n(Q){if(Q==32)return 300;else if(Q<49)return 0;else if(Q<58)return 100*(Q-48);
else if(Q<65)return 0;return 100*(Q-55)}var W;function D(Q,B){var i=new Uint8Array(Q);B.XW=!0;W={};var c=J.sv(i,0,2);
if(c=="WL"){alert("Unsupported CDR version")}else{var h2,jX,bm,fK,eS=300,c2=0;if(c=="PK"){jX=UZIP.parse(i);
i=jX["content/root.dat"];bm=J.KY(jX["content/dataFileList.dat"]).split("\n")}h2=ce.ew(i.buffer);console.log(h2);
var dC=n(i[11]),fn={data:i,R:0,EP:dC};fn.j3=fn.EP<600?16:32;K(i,fn,bm,jX,h2.sub,0);var i6=[];if(jX){fK=w(h2,"doc ");
j(fK);var dh=h2.sub;for(var L=0;L<dh.length;L++)if(dh[L].W_=="page")i6.push(dh[L]);i6=i6.slice(1)}else if(w(h2,"cmpr")==null){fK=w(h2,"page");
i6.push(fK)}else{var kA=w(h2,"cmpr").sub;fK=kA[0];i6=[kA.slice(1)[1]];j(fK)}var ig=w(fK,"mcfg").Z,iJ=ig.alE,fL=iJ.x*.1,fB=iJ.x*i6.length+fL*(i6.length-1),ah=iJ.y;
eS/=bW.CI(new iB(0,0,Math.round(fB*eS),Math.round(ah*eS)),8192*8192);var gL=Math.round(fB*eS),e_=Math.round(ah*eS);
B.m=gL;B.n=e_;B.buffer=E.Q(B.m*B.n*4);for(var L=0;L<i6.length;L++){var jS=new eh(eS,0,0,-eS,iJ.x*eS/2+c2,iJ.y*eS/2);
I(i6[L],fK,B,jS);var ie=B.C[B.C.length-1];ie.MR(new iB(Math.round(c2),0,Math.round(iJ.x*eS),Math.round(iJ.y*eS)));
ie.nz("Page "+(L+1));c2+=iJ.x*eS+fL*eS}B.om(i6.length)}}function j(Q){var B=w(Q,"filt").sub,i=w(Q,"otlt").sub,c=w(Q,"fntt");
if(c)c=c.sub;Q.ep={};for(var L=0;L<B.length;L++)Q.ep[B[L].sub[0].Z.id]=B[L].sub[0].Z;Q.LX={};for(var L=0;
L<i.length;L++)Q.LX[i[L].Z.id]=i[L].Z;if(c){Q.fonts={};for(var L=0;L<c.length;L++)Q.fonts[c[L].Z.id]=c[L].Z}}function I(Q,B,i,c){var h2=Q.W_?Q.W_:Q.Z4,jX=w(Q,"lgob"),bm=w(Q,"txsm"),dC=null,fn=null;
if(jX){dC=w(jX,"trfl");fn=w(jX,"loda")}else if(w(Q,"lobj"))fn=w(Q,"lobj");var fK=dC&&dC.sub[0].GY?dC.sub[0].GY.clone():new eh;
fK.concat(c);var i6=i.QI();if(h2=="page"||h2=="layr"||h2=="grp "){i6.nz((h2=="page"?"Page":"Group")+" "+i.C.length);
i6.add.lsct=ef.fz;i6.Bx="pass";i6.FK=24;var dh=[];if(h2=="page")dh=w(Q,"gobj").sub;if(h2=="layr")dh=Q.sub.slice(2);
if(h2=="grp ")dh=Q.sub.slice(4);if(dh.length==0)return;i.C.push(i.hG());for(var L=dh.length-1;L>=0;L--)I(dh[L],B,i,c)}else if(h2=="obj "&&fn.Z&&fn.Z.path){var kA,ig;
if(B.ep){kA=B.ep[fn.Z.ajO];ig=B.LX[fn.Z.a4H]}if(kA==null)kA=fn.Z.a3i;if(ig==null)ig=fn.Z.a7N;i6=U(i,fn.Z.path,c,fK,kA,ig)}else if(h2=="obj "&&bm){var iJ=fn.Z.a1j,fL=fn.Z.a63,eS="";
i6.add.TySh=hd._3(0,0);var fB=fK.NW();i6.add.TySh.D.translate(fK.z2,fK.EU);var ah=i6.add.TySh._o,gL=bm.Z.gX;
if(gL==null)return;for(var L=0;L<gL.length;L++){var e_=gL[L],c2=eS.length;eS+=e_.text+"\n";hd.KO(ah,c2,e_.text+"\n");
if(e_.text=="")continue;var jS=M(e_.ajI,B),ie=jS.ai8,as=B.fonts[ie.aut],gb=hd.tG(ah,c2,eS.length);if(jS.align==3)gb.ci.Justification=1;
else if(jS.align==2)gb.ci.Justification=2;else gb.ci.Justification=0;var gx=jS.fill.Z;if(gx==null)gx=[0,0,0];
if(as.x2)hd.hI(gb,as.x2);gb.lJ.FillColor={Type:1,Values:[1,gx[0],gx[1],gx[2]]};gb.lJ.FontSize=Math.round(ie.fontSize*c.NW());
hd.g0(ah,c2,eS.length-1,gb)}if(fL){hd.VL(ah,0)}else{hd.VL(ah,1);hd.sV(ah,[0,0,Math.round(iJ.x*fK.dl),Math.round(-iJ.y*fK.j7)])}i6.nz(eS.slice(0,10))}else{i6=null}if(i6)i.C.push(i6)}function U(Q,B,i,c,h2,jX){var bm=Q.QI();
bm.nz("Object "+Q.C.length);bm.FK|=16;bm.add.vstk=JSON.parse(JSON.stringify(at.QO.default));var dC=bm.add.vstk;
dC.strokeEnabled.v=!1;bm.add.vmsk=new h.Rd;bm.add.vmsk.i=E.p.oF(B,!1);E.P.c0(bm.add.vmsk.i,c);var fn=h2&&h2.type!=0,fK=fn&&h2.Z!=null?h2.Z:[0,0,0];
f3.f7(fK,bm,c,E.P.b3(bm.add.vmsk.i));dC.fillEnabled.v=fn;if(jX&&jX.ar1!=1){dC.strokeEnabled.v=!0;dC.strokeStyleLineAlignment.v.strokeStyleLineAlignment="strokeStyleAlignCenter";
var i6=dC.strokeStyleLineWidth.v.val=jX.lineWidth*i.NW(),dh=jX.color;dC.strokeStyleContent.v.Clr.v=E.M.lW({o:dh[0]*255,B:dh[1]*255,k:dh[2]*255});
if(jX.KL.length!=0)dC.strokeStyleLineDashSet.v=ge.zW(jX.KL,4/i6);var kA=jX.aag,ig=jX.amz;if(ig!=0){var iJ=B.w,L=iJ.length-4,fL=iJ[L],fB=iJ[L+1],ah=iJ[L+2],eS=iJ[L+3],gL=new eh;
gL.scale(.15,.15);gL.rotate(-Math.PI/2+Math.atan2(eS-fB,-(ah-fL)));gL.translate(ah,eS);gL.concat(c);
if(W[ig]){var e_=U(Q,W[ig],i,gL,dh,null);Q.C.push(e_)}}}bm.hu();bm.yb(Q);return bm}function M(Q,B){var i=w(B,"stlt").Z,c=JSON.parse(JSON.stringify(i.IH[Q]));
if(c.uJ!=0){var h2=i.IH[c.uJ];for(var jX in h2)if(c[jX]==null||c[jX]==0)c[jX]=h2[jX];delete c.uJ}c.align=i.awS[c.a7R];
c.fill=B.ep[i.a85[c.a1P]];c.aeg=B.LX[i.a1Z[c.a2a]];c.ai8=i.a5l[c.abS];return c}function m(L){var bK=L.data[L.R];
L.R+=1;return bK}function l(L){var bK=J.vQ(L.data,L.R);L.R+=2;return bK}function A(L){var bK=J.ly(L.data,L.R);
L.R+=4;return bK}function g(L){var bK=J.ly(L.data,L.R);L.R+=8;return bK}function k(L){var bK=J.lm(L.data,L.R);
L.R+=2;return bK}function $(L){var bK=J.ck(L.data,L.R);L.R+=4;return bK}function C(L){var bK=J.sY(L.data,L.R);
L.R+=8;return bK}function f(L){if(L.R>=L.data.length)throw"e";var Q=0;while(L.data[L.R+Q]!=0)Q++;var B=J.sv(L.data,L.R,Q);
L.R+=Q+1;return B}function z(L){var Q="";while(!0){var B=l(L);if(B==0)break;Q+=String.fromCharCode(B)}return Q}function s(Q){var B=A(Q),i=(B&4294901760)>>>16,c=(B&65535)/65535;
return i+c}function O(Q){if(Q.EP<600)return Math.PI*k(Q)/1800;return Math.PI*$(Q)/18e7}function a(Q){if(Q.EP<1500)return X(Q);
else return C(Q)/254e3}function X(Q){if(Q.EP<600)return k(Q)/1e3;else return $(Q)/254e3}function P(Q){if(Q.EP<600)return l(Q);
else return A(Q)}function Z(Q){if(Q.EP<600)return k(Q);else return $(Q)}function Y(Q,B,i){var c="";for(var L=0;
L<i;L++){for(var h2=0;h2<B;h2+=4){var bK=J.ly(Q.data,Q.R+L*B+h2);c+=(bK<500?bK:bK)+","}c+="\n"}return c}function K(Q,B,i,c,h2,jX){var bm,dC,fn;
for(var fK=0;fK<h2.length;fK++){var i6=B.EP,dh=h2[fK];B.data=Q;B.R=dh.R+(dh.Z4=="LIST"?4:0);if(c&&dh.sub==null){bm=A(B);
dC=A(B);fn=A(B);var kA=l(B);if(kA!=0)throw"e";var ig=l(B);if(ig>32)throw"e";B.R-=16;if(bm!=4294967295){B.data=c["content/data/"+i[bm]];
B.R=fn}}if(dh.Z4=="vrsn"){if(dh.size==16)B.R+=8;var iJ=l(B);B.EP=iJ;console.log("Version",iJ);B.j3=iJ<600?16:32}else if(dh.Z4=="DISP"){}else if(dh.Z4=="LIST"&&dh.W_=="cmpr"){var fL=A(B),fB=A(B),ah=A(B),eS=A(B),gL=new Uint8Array(B.data.buffer,B.R+8+2,fL-6-8),e_=pako.inflateRaw(gL),as=0;
B.R+=fL;gL=new Uint8Array(B.data.buffer,B.R+8+2);var c2=pako.inflateRaw(gL),jS=[];for(var ie=0;ie<c2.length;
ie+=4)jS.push(J.ly(c2,ie));dh.sub=[];while(as<e_.length){var gb=ce._t(e_,as,jS);as=gb.R+gb.size;dh.sub.push(gb)}var gx={data:e_,R:0,EP:i6,j3:B.j3};
K(e_,gx,i,c,dh.sub,jX+1)}else if(dh.Z4=="LIST"&&dh.W_=="stlt"||dh.Z4=="stlt"){if(bm==4294967295)return;
var eo=B.R,g5="",jG=32;dh.Z={};var di=A(B);if(di==0)return;dh.Z.a85=u(B,i6>=1300);dh.Z.a1Z=u(B);dh.Z.a5l={};
var d0=A(B);for(var L=0;L<d0;L++){var e6=A(B);B.R+=i6<1e3?12:20;var dt=l(B),gJ=l(B);B.R+=8;var iW=X(B);
B.R+=i6<1e3?12:20;dh.Z.a5l[e6]={aut:dt,a8Y:gJ,fontSize:iW}}dh.Z.awS=u(B);var jW=A(B);g5+="Intervals\n"+Y(B,52,jW)+"\n";
B.R+=52*jW;var eP=A(B);g5+="Set5s\n"+Y(B,152,eP)+"\n";B.R+=152*eP;var b_=A(B);g5+="Tabs\n"+Y(B,784,b_)+"\n";
B.R+=784*b_;var fZ=A(B);g5+="Bullets\n";for(var L=0;L<fZ;L++){var im=B.R,j3=A(B);B.R+=4*3;if(i6>1300)B.R+=4;
var dr=A(B);B.R+=4*5;if(i6>=1300){var c0=A(B);if(c0){if(A(B))B.R+=64;else B.R+=60}else B.R+=12}else{B.R+=20;
if(i6>=1e3)B.R+=8;if(A(B))B.R+=8;B.R+=8}var fM=B.R;B.R=im;g5+=Y(B,fM-im,1);B.R=fM}g5+="\n";var cB=A(B);
g5+="Indents\n";dh.Z.a2U={};for(var L=0;L<cB;L++){var im=B.R,iI=A(B),jD={};B.R+=12;jD.right=X(B);jD.axw=X(B);
jD.left=X(B);dh.Z.a2U[iI]=jD;var fM=B.R;B.R=im;g5+=Y(B,fM-im,1);B.R=fM}g5+="\n";var j8=A(B);if(i6>=1300)jG+=4;
g5+="Hypens\n"+Y(B,jG,j8)+"\n";B.R+=jG*j8;var i1=A(B);g5+="Dropcaps\n"+Y(B,28,i1)+"\n";B.R+=28*i1;if(i6>800){var bH=A(B);
g5+="Set11s\n"+Y(B,28,bH)+"\n";B.R+=12*bH}dh.Z.IH={};for(var L=0;L<di;L++){var a_=A(B);if(a_>3)throw a_;
var aR=A(B),iY={};iY.uJ=A(B);B.R+=8;var gy=A(B);if(i6>=1200)gy*=2;B.R+=gy;iY.a1P=A(B);iY.a2a=A(B);if(a_>1){iY.abS=A(B);
iY.a7R=A(B);iY.a1R=A(B);iY.ahc=A(B);if(i6>800)iY.a3s=A(B)}if(a_>2){iY.azU=A(B);iY.arB=A(B);iY.aiu=A(B);
iY.az2=A(B);iY.a1I=A(B)}dh.Z.IH[aR]=iY}}else if(dh.Z4=="LIST")K(Q,B,i,c,dh.sub,jX+1);else if(dh.Z4=="txsm"){dh.Z={};
if(i6<600)throw"e";if(i6<700)throw"e";if(i6>=1600){dh.Z=N(B);return}if(i6>=1500)B.R+=37;else B.R+=36;
if(A(B)){if(i6<800)B.R+=32}if(i6<800)B.R+=4;dh.Z.amQ=A(B);dh.Z.gX=[];B.R+=48;if(i6>=800){if(A(B)){B.R+=32;
if(i6>=1300)B.R+=8}}if(i6>=1500)B.R+=12;var a_=A(B),gr=1,fs=!1;if(!a_){if(i6>=800)B.R+=4;if(i6>800)B.R+=2;
if(i6>=1400)B.R+=2;B.R+=24;if(i6<800)B.R+=8;gr=A(B)}for(var ie=0;ie<gr;ie++){var dQ=A(B),L=0;if(i6>=1300&&a_)B.R++;
B.R++;var di=A(B),ep=[];for(L=0;L<di;L++){var b2=m(B),iz=0;m(B);var eX=m(B);if(i6>=800)iz=m(B);var iY={};
if(eX&1){iY.aut=l(B);var en=l(B);if(en)iY.adP=en}if(eX&2)B.R+=4;if(eX&4)iY.ama=X(B);if(eX&8)B.R+=4;if(eX&16)B.R+=4;
if(eX&32)B.R+=4;if(eX&64){iY.a1P=A(B);if(i6>=1500)B.R+=48}if(eX&128){iY.a2a=A(B)}if(iz&8){if(i6>=1300){var ko=A(B);
if(B.R+ko*2>=B.data.length){fs=!0;break}B.R+=ko*2}else B.R+=4}if(iz&32){var fh=m(B);if(fh)B.R+=52}if(b2==2)if(i6>=1300)B.R+=48;
ep.push(iY)}if(fs){break}var d1=A(B);if(B.R+d1*4>B.data.length)break;var j_=[];for(L=0;L<d1;L++){var h9=0;
if(i6>=1200)h9=g(B)&4294967295;else h9=A(B);j_[L]=h9>>16|h9&1}var ha=d1;if(i6>=1200)ha=A(B);var fl=f(B);
dh.Z.gX.push({ajI:dQ,text:fl,IH:ep})}}else if(dh.Z4=="arrw")dh.Z=S(B);else if(dh.Z4=="font"){var im=B.R,ex=l(B),aI=l(B),ba="";
B.R+=14;if(B.EP>=1200)ba=z(B);else ba=f(B);dh.Z={id:ex,azu:aI,name:ba};if(c){var ik=im+dC;while(B.data[B.R]==0)B.R++;
B.R+=2;var c3=z(B);while(B.data[B.R]==0)B.R++;while(B.data[B.R]<=2)B.R+=4;dh.Z.x2=z(B)}}else if(["IKEY","ICMT","pfrd","bcfg"].indexOf(dh.Z4)!=-1){}else if(dh.Z4=="flgs")dh.Z=A(B);
else if(dh.Z4=="bbox"){var br=X(B),bi=X(B),cZ=X(B),ib=X(B);dh.Z=new iB(br,bi,cZ-br,ib-bi)}else if(dh.Z4=="fild"){var hb=A(B),kh;
if(i6>=1300)B.R+=8;var kg=l(B);if(kg==0){}else if(kg==1){B.R+=i6>=1300?13:2;kh=r(B)}else if(kg==2){B.R+=i6>=1300?8:2;
var ct=m(B),cy=0;if(i6>=1300){B.R+=17;cy=k(B)}else if(i6>=600){B.R+=19;cy=$(B)}else{B.R+=11;cy=k(B)}var hA=O(B),iO=.5+Z(B),fj=.5+Z(B)-.5;
if(i6>=600)B.R+=2;var io=P(B)&255,fX=m(B)/100;B.R++;var a0=P(B)&65535;if(i6>=1300)B.R+=3;var ia=[];for(var L=0;
L<a0;L++){var eK=r(B);if(i6>=1400)B.R+=26;else if(i6>=1300)B.R+=5;var hH=(P(B)&65535)/100;if(i6>=1300)B.R+=3;
ia.push([hH,eK])}kh={typ:ct==1?"lin":"rad",crds:[iO-Math.cos(hA)/2,fj-Math.sin(hA)/2,iO,fj],grad:ia,mat:[1,0,0,1,0,0]}}else console.log("Unknown fill type",kg);
dh.Z={id:hb,type:kg,Z:kh}}else if(dh.Z4=="outl"){var eA=A(B);if(i6>=1300){var cN=0,a4=0;while(cN!=1){B.R+=a4;
cN=A(B);a4=A(B)}}var h7=l(B),cD=l(B),gY=l(B);if(i6<1300&&i6>=600)B.R+=2;var iv=X(B),b4=l(B)/100;if(i6>=600)B.R+=2;
var e5=O(B);if(i6>=1300)B.R+=46;else if(i6>=600)B.R+=52;var kh=r(B);if(i6<600)B.R+=10;else B.R+=16;var kd=l(B),aG=B.R,d$=[];
for(var L=0;L<kd;++L)d$.push(l(B));if(i6<600)B.R=aG+20;else B.R=aG+22;var cc=A(B),dq=A(B);dh.Z={id:eA,ar1:h7,a3a:cD,a0q:gY,lineWidth:iv,color:kh,KL:d$,aag:cc,amz:dq}}else if(dh.Z4=="mcfg"){if(1300<=i6)B.R+=12;
else if(900<=i6)B.R+=4;else if(600<=i6&&i6<700)B.R+=28;var gi=0,gG=0;if(i6<400){B.R+=2;var br=X(B),bi=X(B),cZ=X(B),ib=X(B);
gi=Math.abs(cZ-br);gG=Math.abs(ib-bi)}else{gi=X(B);gG=X(B)}dh.Z={alE:new ec(gi,gG)}}else if(dh.Z4=="loda"||dh.Z4=="lobj"){var eo=B.R,dK=P(B),gv=P(B),cm=P(B),jP=P(B),cW=P(B),ii=[],ju=[],L=0,b8=null;
B.R=eo+cm;while(L<gv)ii[L++]=P(B);B.R=eo+jP;while(L>0)ju[--L]=P(B);dh.Z={};for(L=0;L<gv;L++){B.R=eo+ii[L];
var jM=ju[L];if(jM==30){if(i6>=400&&cW==1||i6<400&&cW==0){dh.Z.path=x(B)}else if(i6>=400&&cW==2||i6<400&&cW==1){dh.Z.path=R(B)}else if(i6>=400&&cW==3||i6<400&&cW==2){dh.Z.path=o(B)}else if(cW==37){dh.Z.path=t(B)}else if(i6>=400&&cW==4||i6<400&&cW==3){dh.Z.a63=H(B)}else if(i6>=400&&cW==6||i6<400&&cW==5){dh.Z.a1j=F(B)}else console.log(cW)}else if(jM==20){if(i6<400)dh.Z.a3i=V(B);
else dh.Z.ajO=A(B)}else if(jM==10){if(i6<400)dh.Z.a7N=T(B);else dh.Z.a4H=A(B)}else if(jM==200)dh.Z.azl=P(B);
else if(jM==100){if(i6<400)b8=G(B)}}if(b8&&dh.Z.path)E.p.D(dh.Z.path.w,b8,dh.Z.path.w)}else if(dh.Z4=="trfd"){var eo=B.R,dK=P(B),gv=P(B),cm=P(B);
B.R=eo+cm;var ii=[];for(var L=0;L<gv;L++)ii[L]=P(B);for(var L=0;L<gv;L++){B.R=eo+ii[L];if(i6>=1300)B.R+=8;
var f6=l(B);if(f6==8){var it,iG,br,j0,cS,bi;if(i6>=600)B.R+=6;if(i6>=500){it=C(B);iG=C(B);br=C(B)/(i6<600?1e3:254e3);
j0=C(B);cS=C(B);bi=C(B)/(i6<600?1e3:254e3)}else throw"e";dh.GY=new eh(it,j0,iG,cS,br,bi)}else console.log(f6)}}else if(!1){console.log(dh);
var ar=Math.min(dh.size,32);console.log(J.eS(Q,dh.R,ar));console.log(J.aco(Q,dh.R,ar))}}}function S(Q){var B=A(Q);
Q.R+=4;var i=l(Q);Q.R+=4;var c=[];for(var h2=0;h2<i;h2++)c.push(m(Q));Q.R+=1;var jX=[];for(var bm=0;
bm<i;bm++){var dC=[];dC[1]=X(Q);dC[0]=X(Q);jX.push(dC)}var fn=_(jX,c);W[B]=fn}function G(Q){var B=0,i=0,c=0,h2=0,jX=0,bm=0;
if(Q.EP>=300){var dC=Q.R;Q.R+=10;var fn=P(Q);Q.R=dC+fn;B=s(Q);i=s(Q);c=$(Q)/1e3;h2=s(Q);jX=s(Q);bm=$(Q)/1e3}else{c=X(Q);
bm=X(Q);B=s(Q);i=s(Q);c+=s(Q)/1e3;h2=s(Q);jX=s(Q);bm+=s(Q)/1e3}return new eh(B,i,h2,jX,c,bm)}function V(Q){var B=m(Q);
if(B==0)return null;else if(B==1)return r(Q);else console.log(B)}function T(Q){var B=m(Q);B<<=1;var i=X(Q),c=l(Q)/100,h2=O(Q),jX=r(Q);
return{ar1:B,lineWidth:i,color:jX,KL:[],aag:0,amz:0}}function R(Q){var B=X(Q),i=X(Q),c=O(Q),h2=O(Q),jX=E.p.xH(E.P.AB.Po(0,0,B,i));
return jX}function x(Q){var B=Q.EP,i=a(Q),c=a(Q),h2=0,jX=0,bm=0,dC=0,fn=0,fK=1,i6=1;if(B<1500){dC=a(Q);
bm=B<900?dC:a(Q);jX=B<900?dC:a(Q);h2=B<900?dC:a(Q)}else{var dh=C(Q);if(dh!=0)fK=dh;dh=C(Q);if(dh!=0)i6=dh;
var kA=m(Q);Q.R+=7;if(kA==0){dC=C(Q);fn=m(Q);Q.R+=15;bm=C(Q);Q.R+=16;jX=C(Q);Q.R+=16;h2=C(Q);var ig=Math.abs(i*fK/2),iJ=Math.abs(c*i6/2);
dC*=ig<iJ?ig:iJ;bm*=ig<iJ?ig:iJ;jX*=ig<iJ?ig:iJ;h2*=ig<iJ?ig:iJ}else{dC=a(Q);fn=m(Q);Q.R+=15;bm=a(Q);
Q.R+=16;jX=a(Q);Q.R+=16;h2=a(Q)}}return E.p.xH(E.P.AB.Rect(0,0,i,c,[h2,jX,bm,dC]))}function v(Q){var B=A(Q);
if(Q.EP<1700)B*=2;Q.R+=B;return""}function N(Q){var B=A(Q),c=0;Q.R+=37;var i=A(Q);for(var L=0;L<i;L++){var h2=A(Q);
c=h2;Q.R+=48;var jX=A(Q);if(jX==1)Q.R+=12*4;else Q.R+=8;if(!B){Q.R+=16;v(Q)}}var bm={amQ:c,gX:[]},dC=A(Q);
for(var fn=0;fn<dC;fn++){var fK=A(Q),e_="";Q.R+=1;if(B)Q.R+=1;var i6=v(Q),dh=A(Q);for(var L=0;L<dh;L++){Q.R+=2;
var kA=l(Q),ig=l(Q);if(ig&4){var iJ=A(Q);iJ*=2;Q.R+=iJ}if(kA||ig&4){var fL=v(Q)}}var fB=A(Q),ah=[];for(var L=0;
L<fB;L++){var eS=g(Q)&4294967295;ah[L]=eS>>16|eS&1}var gL=A(Q);for(var L=0;L<fB;L++){var c2=ah[L]&7,jS=0;
if(c2==0||c2==2||c2==4||c2==6)jS=Q.data[Q.R++];else if(c2==1||c2==3)jS=Q.data[Q.R++]+Q.data[Q.R++]*256;
else throw c2;e_+=String.fromCharCode(jS)}var ie=e_.split("\r");for(var L=0;L<ie.length;L++)bm.gX.push({text:ie[L],ajI:fK,IH:[]})}return bm}function u(Q,B){var i={},c=A(Q);
for(var L=0;L<c;L++){var h2=A(Q);Q.R+=4;var jX=A(Q);i[h2]=jX;if(B)Q.R+=48}return i}function H(Q){var B=X(Q),i=X(Q);
return new ec(B,i)}function F(Q){Q.R+=4;var B=X(Q),i=X(Q);return new ec(B,i)}function t(Q){Q.R+=4;var B=l(Q)+l(Q);
Q.R+=16;var i=q(Q,B);return i}function o(Q){var B=l(Q);Q.R+=2;return q(Q,B)}function q(Q,B){var i=[],c=[];
for(var L=0;L<B;L++)i.push([X(Q),X(Q)]);for(var L=0;L<B;L++)c.push(m(Q));return _(i,c)}function _(Q,B){var i={w:[],F:[]},c=0,h2=0,jX=0;
for(var L=0;L<Q.length;L++){var c=Q[L][0],h2=Q[L][1],bm=B[L];if(!(bm&64)&&!(bm&128)){i.w.push(c,h2);
i.F.push("M");jX+=2}else if(bm&64&&!(bm&128)){i.w.push(c,h2);i.F.push("L");jX+=2}else if(!(bm&64)&&bm&128){i.w.push(c,h2);
i.F.push("C");jX+=6}else if(bm&64&&bm&128){i.w.push(c,h2)}}if(jX!=i.w.length)throw"e";return i}function d(Q,B){var i=J.ly;
B+=8;var c=i(Q,B);B+=4;var h2=i(Q,B);B+=4;B+=4*7;var jX=B,bm=E.Q(c*h2*4);B+=1024;for(var dC=0;dC<h2;
dC++)for(var fn=0;fn<c;fn++){var L=dC*c+fn,fK=(h2-dC-1)*c+fn,i6=Q[B+L]<<2,dh=fK<<2;bm[dh+0]=Q[jX+i6+2];
bm[dh+1]=Q[jX+i6+1];bm[dh+2]=Q[jX+i6+0];bm[dh+3]=255}return{Q0:bm,rect:new iB(0,0,c,h2)}}function r(Q){var B=Q.EP,i=0,c=0,h2=0;
if(B>=500){i=l(Q);if(i==1&&B>=1300)i=25;if(i==30){i=25;c=30}else{c=l(Q);Q.R+=4}h2=A(Q)}else if(B>=400)throw"e";
else{i=m(Q);h2=A(Q)}return p(i,c,h2)}function p(Q,B,i){var c=[0,0,0];if(Q==2||Q==3||Q==9||Q==17){var h2=[i>>>0&255,i>>>8&255,i>>>16&255,i>>>24&255];
if(Q==2)for(var L=0;L<4;L++)h2[L]=Math.round(255*h2[L]/100);for(var L=0;L<4;L++)h2[L]/=255;c=UDOC.C.cmykToRgb(h2)}else if(Q==1||Q==5){c=[i>>>0&255,i>>>8&255,i>>>16&255];
for(var L=0;L<3;L++)c[L]=c[L]/255;if(Q==5)c.reverse()}else console.log("Unknown color model "+Q,i,i.toString(16));
return c}return{ew:D}}(),fI=function(){var w,n,W=new ArrayBuffer(4),D=new Uint8Array(W),j=new Uint32Array(W),I=new Float32Array(W);
function U(k,$){for(var C=0;C<k.length;C++)if(k[C][0]==$)return k[C]}function M(){var k=0,$=0,C=0;do{C=w[n++];
k|=(C&127)<<$;$+=7}while(C&128&&$<35);return k>>>0}function m(k,$,C,f,z){w=k;n=$;var s=f[0]=="mesg",O=f[2],a={},X=1,P=s?1e9:O.length;
while(X<=P){var Z=X;if(s){Z=M();if(Z==0)break}var Y=U(O,Z),K=Y[2],S=Y[1]==1,G=S?M():1,V=new Array(G);
if(K==3){if(!S)throw"e";V=w.slice(n,n+G);n+=G}else for(var L=0;L<G;L++){var T;if((K&1)==1){if(K==1)T=w[n++]==1;
else if(K==3)T=w[n++];else if(K==5){var R=M();T=R&1?~(R>>>1):R>>>1}else if(K==7)T=M();else if(K==9){if(w[n]==0){T=0;
n++}else{D[0]=w[n];D[1]=w[n+1];D[2]=w[n+2];D[3]=w[n+3];var x=j[0];j[0]=x<<23|x>>>9;T=I[0];n+=4}}else if(K==11){var v=l(w,n);
T=v[0];n+=v[1]+1}else throw K}else{var N=C[K>>>1];if(N[0]=="enum"){var u=w[n++];if(u>127)throw"e";T=N[2][u]}else{var H=m(w,n,C,N,z+1);
T=H[0];n=H[1]}}V[L]=T}a[Y[3]]=S?V:V[0];X++}return[a,n]}function l(k,$){var C=$;while(k[C]!=0)C++;return[J.KY(k,$,C-$),C-$]}function A(k,$){var C=$;
while(k[C]!=0)C++;for(var L=$;L<C;L++)if(k[L]>127)throw"e";return J.sv(k,$,C-$)}function g(k){w=k;n=1;
var $=[];while(n<k.length){var C=n,f=$.length,z=A(k,n);n+=z.length+1;var s=M();if(s>2)throw"e";var O=M(),a=[];
for(var L=0;L<O;L++){var X=A(k,n);n+=X.length+1;var P=M(),Z=M(),Y=M();a.push(s==0?X:[Y,Z,P,X])}$.push([["enum","strc","mesg"][s],z,a])}return $}return{a4w:g,ab6:m}}();
function gs(){}gs.ew=function(w,n){var W=new Uint8Array(w),D=8,j,A=0,u=0;if(W[0]==80&&W[1]==75){j=UZIP.parse(w);
W=j["canvas.fig"]}var I=J.ly(W,D);D+=4;var U=[];while(D<W.length){var M=J.ly(W,D);D+=4;var m=W.slice(D,D+M);
if(W[D]==137&&W[D+1]==80){}else m=UZIP.inflateRaw(m);U.push(m);D+=M}var l=fI.a4w(U[0]);for(var L=0;L<l.length;
L++)if(l[L][1]=="Message")A=L;var g=fI.ab6(U[1],0,l,l[A],0)[0],k={po:{},_i:{},acy:{},Cf:j},$=g.nodeChanges;
for(var C=0;C<$.length;C++){var f=$[C],z=f.guid;k._i[z.sessionID+","+z.localID]=f}for(var C=0;C<$.length;
C++){var f=$[C],z=f.parentIndex;if(z){var s=gs.bq(k._i,z.guid);if(s.children==null)s.children=[];s.children.push(f)}}var O=$[0],a=O.children,X=new iB,P=[],Z=[];
for(var z=0;z<a.length;z++){var Y=a[z],K=Y.children;if(Y.name=="Internal Only Canvas"||K==null)continue;
var S=new iB;for(var L=0;L<K.length;L++){var G=K[L],V=G.transform,T=G.size;if(V.m00==1&&V.m10==0&&V.m01==0&&V.m11==1){var R=new iB(V.m02,V.m12,T.x,T.y);
S=S.x0(R)}}var x=X.n==0?0:X.n+100,v=S.clone();v.x=0;v.y=x;X=X.x0(v);P[z]=S;Z[z]=x}var N=bW.CI(new iB(0,0,X.m,X.n),8192*8192);
n.m=Math.round(X.m/N);n.n=Math.round(X.n/N);n.buffer=E.Q(n.m*n.n*4);for(var z=0;z<a.length;z++){var Y=a[z],K=Y.children;
if(Y.name=="Internal Only Canvas"||K==null)continue;K.sort(gs.arU);var H=new eh(1,0,0,1,-P[z].x,Z[z]-P[z].y);
H.scale(1/N,1/N);for(var L=0;L<K.length;L++){var G=K[L];gs.ab(G,[],H,g.blobs,n,0,k);u++}}n.om(u);n.XW=!0;
if(N!=1)alert("File scaled down "+N+"x")};gs.ab=function(w,n,W,D,j,I,U){var M=gs,G=!1,V,x,v,N;n=JSON.parse(JSON.stringify(n));
var m=w.overrideKey?w.overrideKey:w.guid;for(var L=0;L<n.length;L++){var l=n[L],A=l.guidPath.guids;if(M.auW(A[0],m)){if(A.length==1){var g={};
for(var k in w)g[k]=l[k]!=null?l[k]:w[k];w=g}else l.guidPath.guids=A.slice(1)}}var $=w.type,C=w.children,f=w.size,z=w.effects,s=j.QI();
s.nz(w.name);s.gb(w.visible);s.opacity=Math.round(w.opacity*255);var O=M.wq(w.transform),a=O.clone();
a.concat(W);if(f==null)f={x:0,y:0};var X=new iB(Math.round(a.z2),Math.round(a.EU),Math.round(f.x*a.NW()),Math.round(f.y*a.NW()));
if(X.m==0||isNaN(X.m))X.m=100;if(X.n==0||isNaN(X.n))X.n=100;var P=w.fillPaints,Z=w.inheritFillStyleID;
if(Z){var g=M.bq(U._i,Z);if(g)P=g.fillPaints}if(P==null)P=[];var P=M.aaa(P),Y=P[0],K=w.strokePaints,Z=w.inheritFillStyleIDForStroke;
if(Z){var g=M.bq(U._i,Z);if(g)K=g.fillPaints}if(K==null)K=[];var K=M.aaa(K),S="BOOLEAN_OPERATION LINE RECTANGLE ROUNDED_RECTANGLE ELLIPSE VECTOR REGULAR_POLYGON STAR".split(" ").indexOf($)!=-1;
if(S||$=="FRAME"){V=new h.Rd;M.a4T(w,D,V);G=E.P.tF(V.i);E.P.c0(V.i,a);var T=E.p.fF(E.P.b3(V.i));if(!T.VY())X=T;
if(U.po.XF&&Y){var R=h.Rd.Tv(U.po.XF.i);for(var L=2;L<R.length;L++)if(R[L].Ht!=null)R[L].Ht=3;V.i=V.i.concat(R.slice(2))}}if(Y&&Y.type=="IMAGE"){N=Y.imageScaleMode;
x=M.Vc(D,gs.cQ(Y),U);var u=x.XL.m/x.XL.n,H=f.x/f.y;v=Math.abs(u-H)}if($=="FRAME"){}else if(S&&G&&x&&(N=="FIT"||N=="FILL"&&v<=.05)){var F=M.Vc(D,gs.cQ(Y),U,!0),t=j.An(F,s.getName(),0,0);
t.FK=s.FK;t.opacity=s.opacity;s=t;var o=new iB(0,0,f.x,f.y);if(N=="FIT"){var q=x.XL.m,_=x.XL.n,d=Math.min(f.x/q,f.y/_),r=q*d,p=_*d;
o=new iB(o.x+(o.m-r)/2,o.y+(o.n-p)/2,r,p)}var Q=E.p.Wx(o).w;E.p.D(Q,a,Q);s.add.SoLd.Trnf=y.wR.Hh(Q);
s.add.SoLd.nonAffineTransform=y.wR.Hh(Q);var B=[],z=w.effects,i=Y.paintFilter;if(z)for(var L=0;L<z.length;
L++)if(z[L].type=="FOREGROUND_BLUR"){var c=z[L],h2=cx.gt("GsnB",{});B.push(h2);h2.v.enab.v=c.visible;
h2.v.Fltr.v.Rds.v.val=c.radius/2.4}if(i&&i.exposure!=0){var h2=cx.gt("brit",{});B.push(h2);h2.v.Fltr.v.Brgh.v=Math.round(i.exposure*160);
h2.v.Fltr.v.useLegacy.v=!0}if(i&&i.vibrance!=0){var h2=cx.gt("vibA",{});B.push(h2);console.log(h2);h2.v.Fltr.v.Strt.v=Math.round(Math.round(i.vibrance*100))}if(B.length!=0){s.add.SoLd.filterFX=cx.Gq();
j.V$({id:s.add.SoLd.placed.v,rect:new iB,buffer:E.Q(1),z:new h.ac});s.add.SoLd.filterFX.v.filterFXList.v=B}s.vr(j,!1);
M.a6s(U,s,j)}else if(S){M.agS(s,V,w,Y,K,a,X,D,j,U);if(z)for(var L=0;L<z.length;L++){var c=z[L];if(c.type!="FOREGROUND_BLUR")continue;
V.C3=c.radius/2.4}s.hu();s.yb(j)}else if($=="TEXT"){var jX=w.textData,bm=jX.layoutSize,dC=["LEFT","RIGHT","CENTER"].indexOf(w.textAlignHorizontal);
s.add.lnsr="rend";s.add.TySh=hd._3(0,0);s.add.TySh.IA=new iB(0,0,100,100);var fn=a.clone();s.add.TySh.D=fn;
var fK=s.add.TySh._o,i6=jX.characters;if(w.textCase=="TITLE"){for(var L=0;L<i6.length;L++)if(L==0||i6[L-1]==" "){var dh=i6.slice(0,L),kA=i6.slice(L+1);
i6=dh+i6[L].toUpperCase()+kA}}i6=i6.replace(/\u2028/g,"\n");i6=i6.replace(/\u2029/g,"\n");i6=i6.replace(/\r\n/g," \n");
hd.KO(fK,0,i6);var ig=w.textAutoResize,iJ=jX.baselines;if(ig=="WIDTH_AND_HEIGHT"){var fL=dC==0?0:dC==1?bm.x:bm.x/2,fB=iJ?iJ[0].position.y:0;
fn.translate(fL*a.NW(),fB*a.NW());hd.VL(fK,0)}else if(ig=="HEIGHT"||ig=="NONE"||ig==null){var fB=iJ?iJ[0].position.y-w.fontSize*.7:0;
fn.translate(0,fB*a.NW());hd.VL(fK,1);hd.sV(fK,[0,0,Math.round(bm.x),Math.round((ig=="NONE"?1.8:1)*bm.y)])}else throw ig;
if(i6!=""){var ah=hd.tG(fK,0,1);M.aii(w,a,f,ah,s,D,j,U);hd.g0(fK,0,i6.length,ah);var eS=jX.characterStyleIDs,gL=jX.styleOverrideTable;
if(eS){eS=eS.slice(0);for(var L=0;L<eS.length;L++)if(i6[L]=="\n")eS[L]=-L-1;var e_=[0],c2=0,jS=0;for(var L=0;
L<eS.length;L++){jS++;var ie=eS[L];if(L==0||ie==eS[L-1]){}else{e_.push(jS-1,L);jS=1}}e_.push(jS);for(var L=0;
L<e_.length;L+=2){var as=e_[L],gb=e_[L+1];if(i6[as]=="\n")continue;var ie=eS[as];if(ie!=0){var gx;for(var eo=0;
eo<gL.length;eo++)if(gL[eo].styleID==ie)gx=gL[eo];var ah=hd.tG(fK,as,as+1);M.aii(gx,a,f,ah,s,D,j,U);
hd.g0(fK,as,as+gb-1,ah)}}}}}else if($=="SYMBOL"){}else if($=="INSTANCE"){var di=w.symbolData,d0=di.symbolOverrides,g=M.bq(U._i,di.symbolID);
if(g)C=g.children;else console.log(w.name,"symbol not found",di.symbolID);n=n.slice(0);for(var L=0;L<d0.length;
L++)n.push(d0[L])}else console.log($);if(!1){}else if(C&&!S){j.C.push(j.hG());var e6=!1,dt=I==0&&$!="SYMBOL"&&$!="INSTANCE";
if(dt){if(X.VY())console.log(X);s.MR(X)}Y=P[P.length-1];if(dt&&Y&&Y.type=="SOLID"){var gJ=Y.color;s.add.artb.artboardBackgroundType.v=4;
s.add.artb.Clr=M.mn(gJ)}else if((Y||K[0])&&V){var iW=j.QI();iW.nz("Background");M.agS(iW,V,w,Y,K,a,X,D,j,U);
iW.hu();iW.yb(j);j.C.push(iW);e6=!0}C.sort(M.arU);var g5=U.po;U.po={};for(var jW=0;jW<C.length;jW++)M.ab(C[jW],n,a,D,j,I+1,U);
U.po=g5;s.add.lsct=!1?ef.fz:ef.Se;s.Bx="pass";var eP=s.I4();s.FK=24;s.gb(eP);var b_=I!=0&&P.length!=0&&!w.frameMaskDisabled&&w.containerSupportsFillStrokeAndCorners;
if(!e6&&b_&&V){s.add.vmsk=V;s.hu();s.yb(j)}else M.a6s(U,s,j);j.C.push(s)}else if(w.mask){if(V){U.po.XF=V}}else{var fZ=[],iI=1;
if(z)for(var im=0;im<z.length;im++){var c=z[im],j3=c.color,dr=c.type,c0=["DROP_SHADOW","INNER_SHADOW"].indexOf(dr);
if(c0!=-1){var fM=["DrSh","IrSh"][c0],cB=JSON.parse(at.UR[at.order.indexOf(fM)]);fZ.push([fM,cB]);cB.enab.v=c.visible;
cB.Md.v.BlnM=dD.Eu(M.ajV(c.blendMode));cB.Opct.v.val=Math.round(100*j3.a);cB.blur.v.val=Math.round(c.radius*a.NW());
cB.Clr=M.mn(j3);var fL=c.offset.x,fB=c.offset.y;cB.uglg.v=!1;cB.lagl.v.val=Math.round(180/Math.PI*Math.atan2(fB,-fL));
cB.Dstn.v.val=Math.round(Math.sqrt(fL*fL+fB*fB)*a.NW())}}if($=="TEXT"&&P[0]&&P[0].type!="SOLID")iI=0;
for(var L=iI;L<P.length;L++){var jD=P[L],j8=M.Dd(w,jD,a,X,D,j,U);if(j8[0]=="GdFl")fZ.push(["GrFl",j8[1]]);
else if(j8[0]=="SoCo")fZ.push(["SoFi",j8[1]]);else if(j8[0]=="PtFl")fZ.push(["patternFill",j8[1]]);else if(j8[0]=="None"){}else throw j8}if(!S)for(var L=0;
L<K.length;L++){var jD=K[L],j8=M.Dd(w,jD,a,X,D,j,U);if(j8[0]=="SoCo"){var cB=JSON.parse(at.UR[at.order.indexOf("FrFX")]);
fZ.push(["FrFX",cB]);cB.enab=j8[1].enab;cB.Opct=j8[1].Opct;cB.Md=j8[1].Md;cB.Clr=j8[1].Clr;cB.Sz.v.val=w.strokeWeight}}if(fZ.length!=0){var jG=JSON.parse(at.default);
for(var L=0;L<at.order.length;L++)jG[at.Pa[L]]={t:"VlLs",v:[]};for(var L=0;L<fZ.length;L++){var i1=fZ[L],fM=at.Pa[at.order.indexOf(i1[0])];
jG[fM].v.unshift({t:"Objc",v:i1[1]})}if(C==null)s.add.lmfx=jG}j.C.push(s)}};gs.agS=function(w,n,W,D,j,I,U,M,m,l){var A=gs;
w.FK|=16;w.add.vmsk=n;var g=w.add.vstk=JSON.parse(JSON.stringify(at.QO.default)),k=A.Dd(W,D,I,U,M,m,l);
if(k[0]=="None"){g.fillEnabled.v=!1;w.add.SoCo=k[1]}else{A.Ap(k,w);w.add[k[0]]=k[1]}var k=A.Dd(W,j[0],I,U,M,m,l);
if(k[0]!="None"){var g=w.add.vstk;g.strokeEnabled.v=!0;g.strokeStyleLineWidth.v.val=W.strokeWeight*I.NW();
g.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[["INSIDE","CENTER","OUTSIDE"].indexOf(W.strokeAlign)];
var $={SoCo:"SoFi",GdFl:"GrFl",PtFl:"patternFill"}[k[0]],C=["SoFi","GrFl","patternFill"].indexOf($),f=[at.Oa,at.Ki,at.v7][C];
g.strokeStyleContent.v={classID:at.QO.W_[0]};var z=W.dashPattern;if(z)g.strokeStyleLineDashSet.v=ge.zW(z,1/W.strokeWeight);
var s=g.strokeStyleContent.v={classID:at.QO.W_[C]};for(var L=0;L<f.length;L++)s[f[L]]=k[1][f[L]];if(!g.fillEnabled.v)A.Ap(k,w)}};
gs.Ap=function(w,n){var W=w[1].Opct.v.val;if(W!=100)n.opacity=Math.round(n.opacity/255*(W/100)*255)};
gs.arU=function(w,n){var W=w.parentIndex.position,D=n.parentIndex.position;return W>D?1:-1};gs.aaa=function(w){for(var L=1;
L<w.length;L++){var n=w[L];if(n.type=="IMAGE"&&n.opacity==1){w=w.slice(L);break}}for(var L=0;L<w.length;
L++){var n=w[L],W=n.imageThumbnail;if(n.type=="IMAGE"&&(n.image==null||n.image.dataBlob==null)&&W&&W.dataBlob)n.image=W;
if(!n.visible){w.splice(L,1);L--}}return w};gs.a6s=function(w,n,W){if(w.po.XF){n.add.vmsk=w.po.XF.clone();
n.hu();n.yb(W)}};gs.aii=function(w,n,W,D,j,I,U,M){var m=w.fontSize,l=w.lineHeight,A=w.fontName,g=w.textAlignHorizontal,k=w.textTracking,$=w.textCase,C=w.textDecoration;
if(m==null)m=D.lJ.FontSize;if(A){var f=A.postscript;if(f==""){var z=A.family,s=A.style;f=z.split(" ").join("")+"-"+s}hd.hI(D,f)}if(m!=null)D.lJ.FontSize=Math.round(m);
if(C=="UNDERLINE")D.lJ.Underline=!0;if(k)D.lJ.Tracking=Math.round(k*1e3);if($)D.lJ.FontCaps=$=="UPPER"?2:0;
if(l&&(l.units!="PERCENT"||l.value!=100)){if(m==null)m=15;var O=l.value;if(l.units=="PERCENT")O=1*m*O/100;
if(l.units=="RAW")O=1*m*O;D.lJ.AutoLeading=!1;D.lJ.Leading=Math.round(O)}if(g)D.ci.Justification=["LEFT","RIGHT","CENTER"].indexOf(g);
var a=w.fillPaints,X=w.inheritFillStyleID;if(X){var P=gs.bq(M._i,X);if(P)a=P.fillPaints}if(a&&a[0]){var Z=gs.Dd(w,a[0],n,W,I,U,M);
if(Z[0]=="SoCo"){var Y=E.M.y_(Z[1].Clr.v);D.lJ.FillColor={Type:1,Values:[1,Y.o/255,Y.B/255,Y.k/255]};
gs.Ap(Z,j)}}};gs.Dd=function(w,n,W,D,j,I,U){var M=gs,m,l,A=w.size;if(n){var g=n.type,k=["GRADIENT_LINEAR","GRADIENT_RADIAL","GRADIENT_DIAMOND","GRADIENT_ANGULAR"].indexOf(g);
if(g=="SOLID"){m="SoCo";var $=n.color;l=JSON.parse(at.UR[at.order.indexOf("SoFi")]);l.Clr=M.mn($)}else if(k!=-1){var C=JSON.parse(at.UR[at.order.indexOf("GrFl")]),f=C.Grad.v;
f.Intr.v=0;C.Type.v.GrdT=["Lnr","Rdl","Dmnd","Angl"][k];var z=[],s=n.stops;for(var L=0;L<s.length;L++){var O=s[L],a=O.color;
z.push([O.position,[a.r,a.g,a.b],a.a])}E.M.WP(z,f);var X=M.wq(n.transform);X.Ba();var P=X.clone();if(A)P.scale(A.x,A.y);
P.concat(W);var Z=new ec(0,.5),Y=new ec(1,.5);Z=P.bj(Z);Y=P.bj(Y);if(!0){Z.x=Y.x+.5*(Z.x-Y.x);Z.y=Y.y+.5*(Z.y-Y.y)}E.M.n0(Z,Y,D,C);
if(k==3){if(P.dl*P.j7-P.k*P.Cj<0)C.Rvrs.v=!C.Rvrs.v}m="GdFl";l=C}else if(g=="IMAGE"){var C=JSON.parse(at.UR[at.order.indexOf("patternFill")]),X=M.wq(n.transform);
X.Ba();var K=gs.cQ(n),S=U.acy[K];if(S==null){var G=M.Vc(j,K,U);S=U.acy[K]={};S.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";
S.HY=[new Uint8Array(G.data),G.XL];if(X.dl<0){var V=S.HY[0].slice(0);E.K.oX(V,S.HY[0],G.XL.m,G.XL.n)}S.name="someImage";
I.qn(S)}if(X.dl<0)X.dl=-X.dl;var T=["FILL","FIT","STRETCH","TILE"].indexOf(n.imageScaleMode),R=T==3?n.scale:1;
ge.aeQ(S,C,A.x,A.y,T,W,X,R);m="PtFl";l=C}else throw g;if(l)l.Opct={t:"UntF",v:{type:"#Prc",val:Math.round(n.opacity*100)}}}if(m==null||n.opacity<.001){m="None";
l={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:0,B:0,k:0})}}}return[m,l]};gs.cQ=function(w){var n=w.image,W=n.dataBlob;
if(W==null){W="";for(var L=0;L<20;L++)W+=n.hash[L].toString(16).padStart(2,"0")}return W};gs.Vc=function(w,n,W,D){if(w[n]){var j=w[n];
if(D)return j.bytes;if(j.rslt)return j.rslt;var I=j.bytes.buffer,U=jj.zJ(I),M=jj.ZO(U);try{j.rslt=M.Vu(I)[0]}catch(fV){j.rslt={data:E.Q(4),XL:new iB(0,0,1,1)}}return j.rslt}else{if(D)return W.Cf["images/"+n];
var I=W.Cf["images/"+n].buffer;if(W.Cf["images/-"+n])return W.Cf["images/-"+n];var U=jj.zJ(I);if(U=="fpng")U="png";
var M=jj.ZO(U);W.Cf["images/-"+n]=M.Vu(I)[0];return W.Cf["images/-"+n]}};gs.a4T=function(w,n,W){var D=w.type,j=w.size,I=w.cornerRadius,l;
if(I==null)I=0;var U=j.x,M=j.y,m=[I,I,I,I],A=["rectangleTopLeftCornerRadius","rectangleTopRightCornerRadius","rectangleBottomRightCornerRadius","rectangleBottomLeftCornerRadius"];
for(var L=0;L<4;L++)if(w[A[L]]!=null)m[L]=w[A[L]];if(D=="RECTANGLE"||D=="ROUNDED_RECTANGLE"||D=="FRAME"){l=E.P.AB.Rect(0,0,U,M,m)}else if(D=="ELLIPSE"){var g=w.arcData,k=g?g.startingAngle:0,$=g?g.endingAngle:2*Math.PI,C=g?g.innerRadius:0;
if(k==0&&$>1.999*Math.PI)l=E.P.AB.Po(0,0,U,M,0);else l=E.P.AB.a1a(U/2,M/2,M/2,k,$);if(C!=0&&C!=1){var f=h.Rd.Tv(l).slice(3);
f.reverse();for(var L=0;L<f.length;L++){var z=f[L],s=z.T7;z.T7=z.mO;z.mO=s}var O=new eh;O.translate(-U/2,-M/2);
O.scale(C,C);O.translate(U/2,M/2);E.P.c0(f,O);l=l.concat(f);l[2].length*=2}}else if(D=="LINE"){l=E.P.AB.Rect(0,0,U,M,0);
l.pop();l.pop();l[2].length=2}else if(D=="STAR"){l=E.P.AB.c4(U/2,M/2,U/2,2*Math.PI*(1/4),5,0,w.starInnerScale)}else if(D=="REGULAR_POLYGON"){l=E.P.AB.Je(.5,.5,.5,Math.PI/2,w.count,0);
var a=new eh;a.scale(U,M);E.P.c0(l,a)}else if(D=="BOOLEAN_OPERATION"){l=[{type:6},{type:8,all:0}];var X=w.children,P=["XOR","UNION","SUBTRACT","INTERSECT"].indexOf(w.booleanOperation);
if(P==-1)throw w;if(X==null)X=[];for(var L=0;L<X.length;L++){var Z=X[L],Y=new h.Rd,K=gs.a4T(Z,n,Y);if(Y.i==null)continue;
E.P.c0(Y.i,gs.wq(Z.transform));l=l.concat(Y.i.slice(2))}for(var L=3;L<l.length;L++)if(l[L].Ht!=null)l[L].Ht=P}else if(D=="VECTOR"){var S,G,o=3;
if(!0){var V=w.vectorData;if(V==null)return;S=V.normalizedSize;G=V.vectorNetworkBlob}var T=n[G].bytes,R=new Uint32Array(T.buffer),x=new Float32Array(T.buffer),v=R[0],N=R[1],u=R[2],H=[],F=[],t=[],q=o+v*3,_=q+N*7;
for(var L=0;L<v;L++){var d=o+L*3,r=new ec(x[d+1],x[d+2]);H.push(r)}for(var L=0;L<N;L++){var p=q+L*7;
F.push([R[p+0],R[p+1],x[p+2],x[p+3],R[p+4],x[p+5],x[p+6]])}for(var L=0;L<u;L++){var Q=R[_+1],B=t[L]=[];
_+=2;for(var i=0;i<Q;i++){var c=R[_++],h2=B[i]=[];for(var jX=0;jX<c;jX++)h2[jX]=R[_+jX];_+=c}}if(_!=R.length)throw"e";
if(u==0){var bm=-1;for(var L=0;L<N;L++){if(bm==-1){}else{var dC=-1;for(var i=L;i<N;i++)if(F[i][4]==bm)dC=i;
for(var i=L;i<N;i++)if(F[i][1]==bm)dC=i;if(dC!=-1){var fn=0,s=F[dC];F[dC]=F[L];F[L]=s;if(s[1]!=bm){fn=s[1];
s[1]=s[4];s[4]=fn;fn=s[2];s[2]=s[5];s[5]=fn;fn=s[3];s[3]=s[6];s[6]=fn}}}bm=F[L][4]}t.push([[]]);for(var L=0;
L<N;L++)t[0][0].push(L)}var fK=[],i6=[];for(var dh=0;dh<t.length;dh++){for(var kA=0;kA<t[dh].length;
kA++){var ig=t[dh][kA],iJ=0;if(ig.length>1){var fL=F[ig[0]],ah=F[ig[1]];iJ=fL[4]==ah[1]?1:0}for(var L=0;
L<ig.length;L++){var eS=F[ig[L]],gL=1,e_=4;if(iJ==0){gL=4;e_=1}var c2=H[eS[gL]],jS=H[eS[e_]];if(L==0){i6.push("M");
fK.push(c2.x,c2.y)}i6.push("C");fK.push(c2.x+eS[gL+1],c2.y+eS[gL+2],jS.x+eS[e_+1],jS.y+eS[e_+2],jS.x,jS.y)}}}l=E.p.oF({w:fK,F:i6},!1);
if(I!=0){var m=[],ie=l[2].length;for(var L=0;L<ie;L++)m.push(I);if(E.P.q9(l))E.P.QG(l,2,m)}var as=new eh;
as.scale(S.x==0?1:j.x/S.x,S.y==0?1:j.y/S.y);E.P.c0(l,as)}W.i=l};gs.bq=function(w,n){return w[n.sessionID+","+n.localID]};
gs.auW=function(w,n){return w.sessionID==n.sessionID&&w.localID==n.localID};gs.ajV=function(w){var n={NORMAL:"norm",MULTIPLY:"mul ",SCREEN:"scrn",COLOR_DODGE:"div ",COLOR_BURN:"idiv",HARD_LIGHT:"hLit",DARKEN:"dark",LUMINOSITY:"lum ",OVERLAY:"over"}[w];
if(n==null)throw w;return n};gs.mn=function(w){return{t:"Objc",v:E.M.lW({o:w.r*255,B:w.g*255,k:w.b*255})}};
gs.wq=function(w){if(w==null)return new eh;var n=[w.m00,w.m10,w.m01,w.m11,w.m02,w.m12];for(var L=0;L<6;
L++)if(Math.abs(n[L])<1e-20)n[L]=0;return new eh(n[0],n[1],n[2],n[3],n[4],n[5])};function bE(){}bE.ew=function(){var w=J.sv;
function n($,C,f,z){var s=z?[]:{};while(C<$.length-1&&$[C]!=125){var O=w($,C,3),a=w($,C+3,1),X;C+=4;
C++;if(a=="v"){var P=n($,C,f+1,O=="ELM"||O=="TIL");X=P.Z;C=P.R}else if(a=="i"||a=="f"){var Z=C;while($[Z]!=125)Z++;
var Y=w($,C,Z-C);X=a=="i"?parseInt(Y,16):parseFloat(Y);C=Z+1}else if(a=="s"){var K=J.IQ($,C),Y="";C+=2;
for(var L=0;L<K;L++)Y+=String.fromCharCode($[C+2*L+1]);X=Y;C=C+2*K+1}else if(a=="b"){X=$[C]==49;C=C+2}else throw"e";
if(z)s.push([O,X]);else if(s[O]==null)s[O]=X;else{if(!(s[O]instanceof Array))s[O]=[s[O]];s[O].push(X)}}C++;
return{Z:s,R:C}}function W($,C){var f=D($).slice(1),$=C.Clr.v;$.Rd.v=f[0]*255;$.Grn.v=f[1]*255;$.Bl.v=f[2]*255}function D($){return[($>>>24&255)/255,($>>>16&255)/255,($>>>8&255)/255,($>>>0&255)/255]}function j($,C){var f=C&4278190080|(C&255)<<16|(C>>>8&255)<<8|C>>>16&255;
new Uint32Array($.buffer).fill(f)}function I($,C){var f=$.TSZ,z=$.WPX,s=$.HPX,O=$.TIL,a=new iB(0,0,z,s),X=E.Q(z*s*4),P=0;
for(var Z=0;Z<s;Z+=f)for(var Y=0;Y<z;Y+=f){var K=new iB(Y,Z,f,f),S,G=O[P];if(G[0]=="TMC"){S=E.Q(K.O()*4);
j(S,G[1])}else if(G[0]=="TID"){S=C[G[1]]}E.Cb(S,K,X,a);P++}return[X,a]}function U($,C){$=new Uint8Array($);
var f=8,z,s={},N=0;while(f<$.length){var O=J.q($,f);f+=4;var a=w($,f,4);f+=4;if(a=="mkTS"){var X=pako.inflate($.slice(f,f+O)),P=n(X,0,0);
z=P.Z}else if(a=="mkBT"){var Z=J.q($,f+4),Y=J.q($,f+8),X=pako.inflate($.slice(f+76,f+O));if(Y==0)for(var L=0;
L<X.length;L+=4){var K=X[L],S=X[L+1],G=X[L+2],V=X[L+3];X[L+3]=K;X[L+2]=V;X[L+1]=G;X[L]=S}else{var T=E.Q(X.length*4);
T.fill(255);E.Mj(X,T);X=T}s[Z]=X}f+=O+4}var R=z.PDC,x=R?R instanceof Array?R:[R]:[z.MKB],v=new iB;for(var L=0;
L<x.length;L++){var u=x[L];v=v.x0(new iB(0,N,u.WID,u.HIT));N+=u.HIT+100}C.m=v.m;C.n=v.n;C.buffer=E.Q(v.O()*4);
C.om(x.length);N=0;for(var H=0;H<x.length;H++){C.C.push(C.hG());var u=x[H],F=u.WID,t=u.HIT,o=u.BGC,q=(u.LYL?u:z).LYL.LAY,r=3;
for(var L=0;L<q.length;L++)m(q[L],C,null,s,new eh(1,0,0,1,-u.XLC,-u.YLC+N));var _=C.QI();C.C.push(_);
var d=new iB(0,N,F,t);N+=t+100;_.MR(d);if(o>>>24!=0){var p=E.M.lW({o:o>>>16&255,B:o>>>8&255,k:o>>>0&255});
_.add.artb.Clr={t:"Objc",v:p};r=4}_.add.artb.artboardBackgroundType.v=r;_.nz(u.PGN?u.PGN:"Page "+(H+1));
_.add.lsct=ef.Se;_.Bx="pass";_.FK=24}}function M($,C,f){var z=$[C];return z instanceof Array?z[f]:z}function m($,C,f,z,s){var O=C.QI();
if($.VIS!=null)O.gb($.VIS);if($.VIF!=null)O.gb($.VIF.VIS);if($.OPA!=null)O.opacity=Math.round(255*$.OPA/1e3);
O.Bx=$.CLL||f=="GRP"?"pass":"norm";if($.BLD!=null){var a=$.BLD,X={"0":"norm","2":"mul ","4":"over","5":"scrn","7":"diss","9":"dark","10":"lite","37":"idiv","30":"norm","39":"lbrn","41":"vLit"}[a+""];
if(X==null)console.log($.OBN,a);else O.Bx=X;if(a==30)O.opacity>>>=1}if($.CLL){O.nz($.LNM);C.C.push(C.hG());
var P=$.CLL.CEL;if(P.length==null)P=[P];for(var Z=P.length-1;Z>=0;Z--){var Y=P[Z].ELM;for(var L=Y.length-1;
L>=0;L--)m(Y[L][1],C,Y[L][0],z,s)}O.add.lsct=$.DIS?ef.fz:ef.Se;O.FK|=24}else if(f=="GRP"){var K=O.add.lmfx=A($.EFL),S;
C.C.push(C.hG());var Y=$.ELM;if($.MNA){S=Y[0][1];Y=Y.slice(1)}O.nz("Group: "+Y.length+" objects");for(var L=Y.length-1;
L>=0;L--)m(Y[L][1],C,Y[L][0],z,s);if(S){if($.MRX){var G=I(S,z),V=O.z=new h.ac;V.rect=G[1].clone();V.rect.x=S.XLC;
V.rect.y=S.YLC+s.EU;V.channel=E.Q(V.rect.O());E.hN(G[0],V.channel,0);E.Ba(V.channel)}else{l(O,S,s);O.hu();
O.yb(C)}}O.add.lsct=ef.Se;O.FK|=24}else if(f=="IMG"){O.nz($.OBN?$.OBN:"Bitmap");var G=I($,z);O.rect=G[1].clone();
O.rect.x=$.XLC;O.rect.y=$.YLC+s.EU;O.buffer=G[0]}else if(f=="TXT"){var T=$.TFS,R=T.TRN instanceof Array?T.TRN.length:1,u="",H="Arial",F=20,t=0;
O.add.lnsr="rend";O.add.TySh=hd._3(0,0);O.add.TySh.IA=new iB(0,0,100,100);var x=new eh(1,0,0,1,$.LFT,$.TOP);
if($.MTX){var v=$.MTX,V=new eh(v.M00,v.M01,v.M10,v.M11,v.M20,v.M21);x.concat(V)}x.concat(s);O.add.TySh.D=x;
var N=O.add.TySh._o;for(var L=0;L<R;L++){var o=M(T,"TRN",L);if(o==null)continue;o=o.replaceAll("\x18","'").replaceAll("\x19","'").replaceAll("\x1C","'").replaceAll("\x1D","'");
o=o.replaceAll("\x03","\n").replaceAll("\r","\n");hd.KO(N,u.length,o);var q=hd.tG(N,0,1),_=M(T,"FON",L);
if(_)H=_;hd.hI(q,H);var d=M(T,"PTS",L);if(d!=null)F=d;q.lJ.FontSize=Math.round(F);var r=M(T,"LED",L);
if(r!=null){q.lJ.Leading=r*F;q.lJ.AutoLeading=!1}var p=M(T,"UND",L);if(p!=null){q.lJ.Underline=p}var Q=M(T,"ITL",L);
if(Q!=null){q.lJ.FauxItalic=Q}var B=M(T,"FCL",L);if(B!=null)t=B;q.lJ.FillColor={Type:1,Values:D(t)};
var i=M(T,"JST",L);if(i!=null)q.ci.Justification=[0,2,1,3,5,4,6,7,8][i];hd.g0(N,u.length,u.length+o.length,q);
u+=o}O.nz(u.slice(0,255));var c=$.RIT-$.LFT,h2=$.BOT-$.TOP;if($.IMG){m($.IMG,C,"IMG",z,s);var jX=C.C.pop();
O.buffer=jX.buffer;O.rect=jX.rect.clone()}hd.VL(N,1);hd.sV(N,[0,0,c,h2])}else if(f=="PTH"){O.nz($.OBN?$.OBN:"Path");
O.FK|=16;var bm=!1;l(O,$,s);var dC=O.add.vmsk,fn=O.add.vstk,fK=E.P.b3(dC.i),i6=$.PAT,dh=i6.BPL,kA=i6.FPL,ig=i6.TXF;
if(kA&&kA.FEF)dC.C3+=kA.FEF/2.4;if(dh){var iJ=dh.CAT;fn.strokeEnabled.v=!0;fn.strokeStyleLineWidth.v.val=dh.BDI;
fn.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[$.BRP];W(i6.BCL,fn.strokeStyleContent.v);
if(iJ!="bc_Basic"&&iJ!="bc_Pencil")bm=!0}if(kA==null){fn.fillEnabled.v=!1;O.add.SoCo=JSON.parse(at.UR[at.order.indexOf("SoFi")]);
W(0,O.add.SoCo)}else if(kA.CAT=="fc_Solid"){O.add.SoCo=JSON.parse(at.UR[at.order.indexOf("SoFi")]);W($.PAT.FCL,O.add.SoCo)}else if(kA.CAT=="fc_Linear"||kA.CAT=="fc_Circular"||kA.CAT=="fc_Elliptical"){var fL=kA.CAT=="fc_Linear",fB=O.add.GdFl=JSON.parse(at.UR[at.order.indexOf("GrFl")]),ah=fB.Grad.v,eS=[],gL=kA.FGL,e_,c2=[];
if(gL.FGY){var jS=gL.FGY,e_=jS.FG0.FGI,c2=jS.FG1.FGI}else e_=gL.FGV.FGI;for(var L=0;L<e_.length;L++){var ie=e_[L],as=D(ie.FGC),gb=1;
if(c2.length==e_.length)gb=D(c2[L].FGC)[0];eS.push([ie.FGP,as.slice(1),gb])}fB.Type.v.GrdT=fL?"Lnr":"Rdl";
E.M.WP(eS,ah);ah.Intr.v=0;var gx=$.PRI?$.PRI:$,eo=new ec(gx.PSX,gx.PSY),di=new ec(gx.PEX,gx.PEY);if(kA.CAT=="fc_Elliptical"&&gx.PFX!=null){var d0=new ec(gx.PFX,gx.PFY),e6=ec.cS(eo,di),dt=ec.cS(eo,d0);
if(dt<e6){var gJ=e6;e6=dt;dt=gJ}di=new ec(eo.x+(e6+dt)/2,eo.y);if(e6/dt<.5)bm=!0}if(fL){eo.x=(eo.x+di.x)/2;
eo.y=(eo.y+di.y)/2}E.M.n0(eo,di,fK,fB)}else console.log(kA.CAT);var K=O.add.lmfx=A($.EFL,dC);if(kA&&kA.FTB!=0&&ig){var G=I(ig.MSK,z),iW={};
iW.id=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";iW.name="someImage";iW.HY=G;C.qn(iW);var g5=G[0];for(var L=0;
L<g5.length;L+=4){g5[L+3]=255-g5[L];g5[L]=g5[L+1]=g5[L+2]=255}var fB=JSON.parse(at.UR[at.order.indexOf("patternFill")]);
fB.Opct.v.val=Math.round(kA.FTB/10);fB.Algn.v=!0;fB.Ptrn.v.Idnt.v=iW.id;K.patternFillMulti.v.unshift({t:"Objc",v:fB})}if(bm&&$.IMG){m($.IMG,C,"IMG",z,s);
var jW=C.C[C.C.length-1];jW.opacity=O.opacity;return}O.hu();O.yb(C)}else if(f=="URL")return;else{console.log("unknown layer type",f,$);
O.nz("Layer")}C.C.push(O)}function l($,C,f){if(C.PBL==null)return;var z=$.add.vmsk=new h.Rd,s=$.add.vstk=JSON.parse(JSON.stringify(at.QO.default)),O=C.PBL.PBP;
if(!(O instanceof Array))O=[O];for(var a=0;a<O.length;a++){var X=O[a].PBT;if(X==null)continue;if(!(X instanceof Array))X=[X];
var P=O[a].ISC?0:3;z.i.push({type:P,length:X.length,Ht:0,S1:2,_T:0,si:0});for(var L=0;L<X.length;L++){var Z=X[L],Y=Z.XLC,K=Z.YLC,S=[Y,K,Y,K,Y,K],G="XPC YPC XLC YLC XSC YSC".split(" ");
for(var V=0;V<6;V++){var T=G[V],R=Z[T];if(R!=null)S[V]=R}z.i.push({type:P+2,H:new ec(Y,K),T7:new ec(S[0],S[1]),mO:new ec(S[4],S[5])})}}E.P.c0(z.i,f)}function A($,C){var f=JSON.parse(at.default);
for(var L=0;L<at.order.length;L++)f[at.Pa[L]]={t:"VlLs",v:[]};if($==null||$.EPS==null)return f;var z=$.EPS;
if(!(z instanceof Array))z=[z];for(var L=0;L<z.length;L++){var s=z[L].DCE,O={};for(var a=0;a<s.length;
a++)O[s[a].DCK]=s[a].DCV;if(O.EffectIsVisible=="false")continue;var X=O.mkbFile_WriteOnly_TemporaryEffectUiName;
if(X=="Gaussian Blur..."&&C){C.C3+=parseFloat(O.gaussian_blur_radius);continue}var P=["Drop Shadow","Inner Bevel","Inner Glow","Glow"].indexOf(X);
if(P==-1){continue}var Z=["DrSh","ebbl","IrGl","OrGl"][P],Y=at.Pa[at.order.indexOf(Z)],K=JSON.parse(at.UR[at.order.indexOf(Z)]);
f[Y].v.unshift({t:"Objc",v:K});if(Z=="DrSh"){K.uglg.v=!1;g(O,"ShadowDistance",K,"Dstn");g(O,"ShadowBlur",K,"blur");
g(O,"ShadowAngle",K,"lagl",180);K.Opct.v.val=100;k(O,"ShadowColor",K,"Clr")}if(Z=="IrGl"){K.Md.v.BlnM="Nrml";
var S=O.MaskSoftness,G=O.GlowWidth;if(S&&G){S=parseInt(S);G=parseInt(G);K.blur.v.val=G+S;K.Ckmt.v.val=Math.round(100*G/(G+S))}g(O,"BevelContrast",K,"Opct");
k(O,"OuterBevelColor",K,"Clr")}if(Z=="OrGl"){K.Md.v.BlnM="Nrml";var S=O.MaskSoftness,G=O.GlowWidth;if(S&&G){S=parseInt(S);
G=parseInt(G);K.blur.v.val=G+S}g(O,"BevelContrast",K,"Opct");k(O,"OuterBevelColor",K,"Clr")}if(Z=="ebbl"){K.uglg.v=!1;
g(O,"BevelWidth",K,"blur");g(O,"AngleSoftness",K,"Sftn");g(O,"BevelContrast",K,"srgR");g(O,"LightAngle",K,"lagl")}}return f}function g($,C,f,z,s){var O=$[C];
if(s==null)s=0;if(O)f[z].v.val=parseInt(O)+s}function k($,C,f,z){var s=$[C];if(s){s=s.slice(1);if(s.length==6)s=s+"ff";
if(s.length!=8)throw"e";var O=D(parseInt(s,16)),a=f[z].v;a.Rd.v=O[0]*255;a.Grn.v=O[1]*255;a.Bl.v=O[2]*255;
f.Opct.v.val=Math.round(f.Opct.v.val/100*O[3]*100)}}return U}();function bv(){}bv.ew=function(){function w(R,x,v){var N=!1,u=Date.now(),H=P(R,N);
if(N)console.log("part found",Date.now()-u);u=Date.now();var F=X(H),t=F.Layer,o=F.Header;if(N)console.log(F);
var q=t[0];q=F.Layer[0];if(N)console.log("document parsed",Date.now()-u);u=Date.now();F.Setup.Gradient=a(F.Setup.Gradient,H);
if(N)console.log("grads loaded",Date.now()-u);u=Date.now();F.Setup.Pattern=O(F.Setup.Pattern,H);if(N)console.log("patts loaded",Date.now()-u);
u=Date.now();F.Setup.DocumentData=s(F.Setup.DocumentData,H).pop();if(N)console.log("docdata loaded",Date.now()-u);
u=Date.now();F.Setup.SVGFilter=s(F.Setup.SVGFilter,H);if(N)console.log("svgfilter loaded",Date.now()-u);
u=Date.now();var _=o.Cropmarks,d=o.BoundingBox.split(" ").map(parseFloat),r=o.ArtSize?o.ArtSize.split(" ").map(parseFloat):[d[2]-d[0],d[3]-d[1]];
x.m=Math.round(r[0]);x.n=Math.round(r[1]);var p=[1,0,0,1,-d[0]+(x.m-(d[2]-d[0]))/2,-d[1]+(x.n-(d[3]-d[1]))/2];
p[3]=-1;p[5]=x.n-p[5];if(_){_=_.split(" ").map(parseFloat);x.m=Math.round(_[2]-_[0]);x.n=Math.round(_[3]-_[1]);
p=[1,0,0,-1,-_[0],x.n+_[1]]}var Q=F.Setup.DocumentData;if(Q&&Q[0]&&Q[0].ArtboardArray){var B=Q[0].ArtboardArray;
if(B.length!=1)console.log(B.length,"artboards");var i=new iB,c=[];for(var L=0;L<B.length;L++){var h2=B[L],jX=h2.PositionPoint1,bm=h2.PositionPoint2,dC=jX[0],fn=Math.min(jX[1],bm[1]),fK=bm[0],i6=Math.max(jX[1],bm[1]),dh=new iB(dC,fn,fK-dC,i6-fn);
c.push(dh);i=i.x0(dh)}x.m=Math.round(i.m);x.n=Math.round(i.n);p[4]=-i.x;p[5]=i.y+x.n;if(B.length!=1){x.C.push(x.hG());
for(var L=0;L<c.length;L++){var h2=B[L],dh=c[L],kA=x.QI();kA.nz(h2.Name);x.C.push(kA);kA.add.SoCo=JSON.parse(at.UR[at.order.indexOf("SoFi")]);
var ig=kA.add.SoCo.Clr.v;l(ig,[1,1,1]);var dC=dh.x,fn=dh.y,fK=dC+dh.m,i6=fn+dh.n,iJ=[dC,fn,fK,fn,fK,i6,dC,i6];
E.p.D(iJ,g(p),iJ);$(kA,{cmds:["M","L","L","L","Z"],crds:iJ},x);kA.add.vstk=JSON.parse(JSON.stringify(at.QO.default))}var kA=x.QI();
kA.nz("_Artboards_");kA.add.lsct=ef.Se;kA.Bx="pass";kA.FK=24;x.C.push(kA)}}if(Q&&Q[0]&&Q[0]["#document"]){var fL=Q[0]["#document"],fB=fL["xmlnode-children"][0];
if(fB&&fB["xmlnode-children"])fB=fB["xmlnode-children"][0];if(fB["xmlnode-nodename"]=="variableSets"){var ah=fB["xmlnode-children"][0]["xmlnode-children"],eS=ah[0],gL=ah[1],e_=T(eS);
x.ol=gg.aaT("<variableSets><variableSet>"+e_+"</variableSet></variableSets>");if(gL){var c2=T(gL),jS=x.Ei=gg.awK(c2);
for(var L=0;L<jS.length;L++)for(var ie=0;ie<jS[L].length;ie++)jS[L][ie]=jS[L][ie].trim()}}}var as=1/bW.CI(new iB(0,0,x.m,x.n),8192*8192);
while(x.m*x.n*as*as<800*800)as*=2;while(v&&Math.max(x.m*as,x.n*as)<Math.max(v[0],v[1]))as++;x.m=Math.round(x.m*as);
x.n=Math.round(x.n*as);x.hh=Math.round(72*as);x.buffer=E.Q(x.m*x.n*4);for(var L=0;L<6;L++)p[L]*=as;W=[0,0,0];
D=[0,0,0];j="SoCo";for(var gb=0;gb<t.length;gb++){var gx=t[gb];gx.Raster=n(gx,"Raster");gx.Place=n(gx,"Place");
var eo=f(H,gx);I(x,eo,p,F,gx,H)}if(N)console.log("layers created",Date.now()-u);u=Date.now()}function n(R,x){var v=R.Layer,N=R[x];
if(N==null)N=[];if(v){for(var L=0;L<v.length;L++){var u=v[L],H=u[x]=n(u,x);N=N.concat(H)}N.sort(function(F,t){return F._begin-t._begin})}return N}var W,D,j;
function I(R,x,v,N,u,H){var F="",t=0,o="",q=!1,_={},d=UDOC.G,r=UDOC.getState(),p="norm",Q=1,B=!1,i=0,h2=null,jX=!1,bm=0,dC=null,fn,fK,i6=0,dh=0,kA=0,fL=0,fB=!1;
r.ctm=v;var c=[],ig=[],iJ=[];for(var ah=0;ah<x.length;ah++){var eS=x[ah],jS=1e9;if(eS[0]=="%"){if(eS=="%_/ArtDictionary :"&&bm==0)h2=[eS.slice(2)];
else if(h2!=null){if(eS=="%_"&&bm==0){var gL=K(h2)[0],e_=gL.AI10_ArtUID;if(e_&&!e_.startsWith("XMLID"))R.C[R.C.length-1].nz(G(e_));
h2=null}else{h2.push(eS.slice(jX?1:2));if(eS=="%_X=")bm++;if(eS=="%_X+")bm--;if(eS=="%_/Binary : /ASCII85Decode ,")jX=!0;
if(jX&&eS.endsWith("~>"))jX=!1}}else if(dC){fn+=(fn==""?"":" ")+eS.slice(2);if(fn.endsWith("X#")){dC.push(fn.slice(0,fn.length-3));
fn=""}}continue}else if(eS=="/Mesh X!"){dC=[];fn="";continue}else if(eS=="/End X!"){U(dC,r,R);dC=null;
continue}var c2="Xa XR m l c f U u *U w J j M d".split(" "),ie=-1,as=eS.indexOf("(")!=-1;for(var L=0;
L<c2.length;L++){var gb=eS.indexOf(" "+c2[L]+" ");if(gb!=-1&&gb<jS&&!as){jS=gb;ie=L}}if(ie!=-1){q=!0;
var gx=jS+1+c2[ie].length;x[ah]=eS.slice(0,gx);var eo=x[ah+1];if(eo==null||eo[0]=="%"||ie>9)x.splice(ah+1,0,eS.slice(gx));
else x[ah+1]=(eS.slice(gx)+" "+eo).replace(/\s\s+/g," ");ah--;continue}eS=eS.trim();var di=eS.split(" "),d0=di[di.length-1],e6=d0.toLowerCase(),dt=di.map(parseFloat);
if(d0=="m")d.moveTo(r,dt[0],dt[1]);else if(d0=="L"||d0=="l")d.lineTo(r,dt[0],dt[1]);else if(d0=="V"||d0=="v"){var gJ=r.pth.crds,iW=r.cpos[0],g5=r.cpos[1];
d.curveTo(r,iW,g5,dt[0],dt[1],dt[2],dt[3]);var jW=gJ.length;gJ[jW-6]=iW;gJ[jW-5]=g5}else if(d0=="Y"||d0=="y")d.curveTo(r,dt[0],dt[1],dt[2],dt[3],dt[2],dt[3]);
else if(d0=="C"||d0=="c")d.curveTo(r,dt[0],dt[1],dt[2],dt[3],dt[4],dt[5]);else if(d0=="H"||d0=="h"){if(d0==e6)d.closePath(r);
c.push(JSON.parse(JSON.stringify(r.pth)))}else if(d0=="Xy"){p=["norm","mul ","scrn","over","sLit",null,"div "][dt[0]];
Q=dt[1];if(p==null){p="norm";console.log("unknown blend mode",dt[0])}}else if(d0=="Xd"){var eP=R.C[R.C.length-1];
eP.opacity=Math.round(255*Q);eP.Bx=eP.ue()&&p=="norm"?"pass":p}else if(d0=="AE")i6=dt[0];else if(d0=="Ae")dh=dt[0];
else if(d0=="Xw")kA=dt[0];else if(d0=="*"){var b_=r.pth.crds,fZ=r.ctm,gb=b_[0]==b_[2]?0:1;R.jg.push([gb,b_[gb]]);
d.newPath(r)}else if(d0=="XN")fK=eS.split(" ")[0];else if(d0=="XI"){var im=u.Raster,j3,dr;if(im==null||im.length==0){console.log("no Raster");
continue}if(eS!="XI"){continue}else{if(im[t].Data==null){continue}var c0=im[t++].Data,fM=c0._begin,cB=c0._end;
while(H[fM]!=88)fM++;fM+=3;j3=H.slice(fM,cB);dr=x[ah-2].split(" ").map(parseFloat)}var iI=dr.slice(8),jD=iI[2],j8=iI[3],jG=jD*j8,i1=E.Q(jG*4);
i1.fill(255);var bH=iI[7],a_=iI[8],aR=iI[6],iY=Math.ceil(jD*bH*aR/8);if(bH==1){if(aR==8)for(var L=0;
L<jG;L++)for(var gy=0;gy<3;gy++)i1[4*L+gy]=j3[L];else if(aR==1)for(var gr=0;gr<j8;gr++)for(var fs=0;
fs<jD;fs++)for(var gy=0;gy<3;gy++)i1[4*(gr*jD+fs)+gy]=255*(j3[gr*iY+(fs>>>3)]>>>7-(fs&7)&1);else throw aR}else if(bH==3)for(var L=0;
L<jG;L++)for(var gy=0;gy<3;gy++)i1[4*L+gy]=j3[3*L+gy];else if(bH==4||bH==5)for(var L=0;L<jG;L++){var dQ=k([j3[bH*L+0]/255,j3[bH*L+1]/255,j3[bH*L+2]/255,j3[bH*L+3]/255]);
i1[4*L+0]=dQ[0]*255;i1[4*L+1]=dQ[1]*255;i1[4*L+2]=dQ[2]*255}else if(bH==7)for(var L=0;L<jG;L++){i1[4*L+0]=j3[bH*L+0];
i1[4*L+1]=j3[bH*L+1];i1[4*L+2]=j3[bH*L+2]}else console.log("unknown number of channels",bH);if(a_==1){var ep=j8*iY;
for(var L=0;L<jG;L++)i1[4*L+3]=j3[ep+L]}var b2=E.Bw(i1,jD,j8)?"JPG":"PNG";if(jD*j8<700*700)b2="PNG";
var eX=jj.ZO(b2).La([[i1.buffer]],jD,j8),iz=R.An(new Uint8Array(eX),"<Image>",0,0);R.C.push(iz);iz.Bx=p;
iz.opacity=Math.round(255*Q);iz.gb(kA==0);var v=new eh;v.scale(1,-1);v.concat(g(dr.slice(1)));v.concat(g(r.ctm));
var en=iz.rect.clone();en.x=en.y=0;var di=E.p.Wx(en).w;E.p.D(di,v,di);iz.add.SoLd.Trnf=y.wR.Hh(di);iz.add.SoLd.nonAffineTransform=y.wR.Hh(di);
iz.vr(R,!1)}else if(d0=="Ln"){F=m(eS)}else if(d0=="u"||d0=="q"||d0=="Lb"){ig.push(dh==1);iJ.push((d0=="Lb"?1-dt[0]:kA)==0);
if(B)continue;R.C.push(R.hG())}else if(d0=="U"||d0=="Q"||d0=="LB"){if(ig.length==0||iJ.length==0)throw ah;
var ko=ig.pop(),fh=iJ.pop();if(d0=="LB")ko=i6==1;if(B)continue;var iz=R.QI();iz.nz((d0=="U"?"<Group>":"<Clip Group>")+o);
if(d0=="LB")iz.nz(F);if(d0=="Q"&&c.length!=0){var d1=c.pop(),j_=UDOC.G.isBox(d1,[0,0,R.m,R.n]);if(!j_)$(iz,d1,R)}iz.add.lsct=ko?ef.fz:ef.Se;
iz.Bx="pass";iz.FK=24;iz.gb(fh);R.C.push(iz);if(fB){if(R.C[R.C.length-3].getName()=="</Layer group>"){R.C.pop();
R.C.splice(R.C.length-2,1)}fB=!1}}else if(d0=="Bb"||d0=="Bh"||d0=="BB"){}else if(d0=="Bg"){var h9=N.Setup.Gradient,ha=h9[m(eS)];
if(ha==null){console.log("gradient not found");for(var fl in h9){ha=h9[fl];break}}j="GdFl";W=M(ha.Y3,ha.arA)}else if(d0=="Bm"||d0=="Xm"){var ex=W.Type.v.GrdT;
if(ex=="Lnr"&&d0!="Xm"||ex=="Rdl"&&d0!="Bm")continue;var aI=new ec(0,0),ba=new ec(1,0),ik=new eh;ik.concat(g(dt));
ik.concat(g(r.ctm));aI=ik.bj(aI);ba=ik.bj(ba);var c3=E.p.mY(r.pth.crds);if(c3.VY())c3=E.p.mY([aI.x,aI.y,ba.x,ba.y]);
if(ex=="Lnr"){aI.x=(aI.x+ba.x)/2;aI.y=(aI.y+ba.y)/2}E.M.n0(aI,ba,c3,W)}else if(d0=="p"){var br=m(eS),bi=N.Setup.Pattern[br];
if(bi.raw==null){var c3=bi.H8,jD=Math.round(c3[2]-c3[0]),j8=Math.round(c3[3]-c3[1]),gL=new kc;gL.m=jD;
gL.n=j8;gL.buffer=E.Q(jD*j8*4);I(gL,bi.xW,[1,0,0,-1,-bi.H8[0],j8+bi.H8[1]],N,u,H);bi.raw=new Uint8Array(jj.ZO("PSD").La(gL))}var cZ=eS.slice(eS.indexOf(")")+2),ib=cZ.slice(0,cZ.indexOf("[")-1).split(" ").map(parseFloat),hb=cZ.slice(cZ.indexOf("[")+1,cZ.indexOf("]")).split(" ").map(parseFloat);
j="patt";W=[br,ib,hb]}else if(d0=="J"||d0=="j"||d0=="w"||d0=="M"||d0=="d"){for(var L=1;L<di.length;L++){var kg=di[L],kh=dt[L-1];
if(kg=="w")r.lwidth=kh;if(kg=="j")r.ljoin=kh;if(kg=="J")r.lcap=kh;if(kg=="d"){var ct=eS.slice(eS.indexOf("[")+1,eS.indexOf("]")).trim();
if(ct.length!=0){var cy=ct.split(" ").map(parseFloat);r.dash=cy}else if(ct=="")r.dash=[]}}}else if(e6=="xa"||e6=="xx"){var hA=dt[4]==null?dt.slice(0,3):[dt[4],dt[5],dt[6]];
if(e6=="xx"&&dt[dt.length-2]==2)hA=k(dt);j="SoCo";if(d0=="Xa"||d0=="Xx")W=hA;else D=hA}else if(e6=="xk"){var hA,iO=dt[dt.length-2],fj=dt[dt.length-3];
if(iO==0)hA=k(dt);else if(iO==1){hA=[dt[4],dt[5],dt[6]];for(var L=0;L<3;L++)hA[L]=fj*1+(1-fj)*hA[L]}else throw eS;
j="SoCo";if(d0=="Xk")W=hA;else D=hA}else if(e6=="k"||e6=="x"){if(e6=="x"){dt.pop();var io=1-dt.pop();
for(var L=0;L<4;L++)dt[L]*=io}var hA=k(dt);j="SoCo";if(d0==e6)W=hA;else D=hA}else if(e6=="g"){var hA=[dt[0],dt[0],dt[0]];
j="SoCo";if(d0==e6)W=hA;else D=hA}else if(e6=="n"){if(!B)d.newPath(r)}else if(d0=="*u"){B=!0;i=0}else if(d0=="*U"||e6=="s"||e6=="f"||e6=="b"){if(d0!="*U"&&B){if(e6=="f"||e6=="b")i|=1;
if(e6=="s"||e6=="b")i|=2;continue}if(d0==e6)d.closePath(r);if(d0=="*U"){B=!1}var iz;if(j=="patt"){var bi=N.Setup.Pattern[W[0]];
iz=R.An(bi.raw,"<Pattern>",0,0);var en=iz.rect.clone();en.x=en.y=0;var di=E.p.Wx(en).w,hb=g(W[2]);hb.z2=hb.EU=0;
E.p.D(di,hb,di);iz.add.SoLd.Trnf=y.wR.Hh(di);iz.add.SoLd.nonAffineTransform=y.wR.Hh(di);iz.vr(R,!1)}else{iz=R.QI();
iz.FK|=16;var fX=iz.add.vstk=JSON.parse(JSON.stringify(at.QO.default));fX.strokeEnabled.v=fX.fillEnabled.v=!1;
if(j=="SoCo"){iz.add.SoCo=JSON.parse(at.UR[at.order.indexOf("SoFi")]);var a0=iz.add.SoCo.Clr.v;l(a0,W)}if(j=="GdFl")iz.add.GdFl=W;
if(e6=="f"||e6=="b"||d0=="*U"&&i&1)fX.fillEnabled.v=!0;if(e6=="s"||e6=="b"||d0=="*U"&&i&2)f3.ZC(fX,r,1,f3.RH(D))}iz.nz("<"+(d0=="*U"?"Compound ":"")+"Path>"+o);
iz.Bx=p;iz.opacity=Math.round(255*Q);iz.gb(kA==0);$(iz,r.pth,R);R.C.push(iz);d.newPath(r)}else if(d0==","&&di[0]=="/XMLUID"){var eP=R.C[R.C.length-1];
for(var L=0;L<R.ol.length;L++)if("("+R.ol[L].docRef+")"==di[2])R.ol[L].docRef="id('"+eP.add.lyid+"')"}else if(d0==","&&di[1]=="/FreeUndo"){fL=dt[0]}else if(d0==","&&di[1]=="/StoryIndex"){var ia=N.Setup.TextDocument,iv=null;
if(!(ia instanceof Array))ia=N.Setup.TextDocument=z(ia,H);var eK=ia[0],hH=ia[2];if(eK._DocumentResources)eK=ia[0]=cI.avn(eK);
else cI.a7z(eK);var iz=R.QI();iz.add.lnsr="rend";iz.add.TySh=hd._3(0,0);var eA=dt[0];if(fL==1){for(var L=1;
L<60;L++){var eo=x[ah+L];if(eo.endsWith("/StoryIndex ,")){eA=parseFloat(eo.slice(2,eo.indexOf(" ")));
fB=!0;break}}fL=0}var cN=gD.anv(eK),a4=iz.add.TySh._o=cN[eA];if(a4==null){console.log("text not found");
fB=!1;continue}iz.nz(hd.Bb(a4).slice(0,50));iz.Bx=p;iz.opacity=Math.round(255*Q);iz.gb(kA==0);var io=eK._1._1[eA]._1._0[0]._0;
io=parseInt(io.slice(1));var h7=eK._0._8._0,cD=h7[io]._0;if(cD._0)iv=A(cD._0);else if(cD._1)iv=A(cD._1._0);
else iv=A(cD._2._2).slice(3);if(iv.length!=2){var c3=E.p.mY(iv);iv=[c3.x,c3.y];if(c3.O()!=0){hd.VL(a4,1);
hd.sV(a4,[0,0,Math.round(c3.m),Math.round(c3.n)])}}var b4=new eh,e5=new eh(1,0,0,1,iv[0],iv[1]),kd=new eh(1,0,0,1,-hH[0],-hH[1]),aG=g(r.ctm),d$=new eh;
if(cD._2&&cD._2._2){var v=A(cD._2._2);d$=new eh(v[0],v[1],v[2],v[3],v[4],v[5])}b4.concat(e5);b4.concat(d$);
b4.concat(kd);b4.scale(1,-1);b4.concat(aG);iz.add.TySh.D=b4;R.C.push(iz);R.XW=!0}else if(d0=="Tp"){_.GY=g(dt)}else if(d0=="Tf"){_.font=di[0].slice(2)}else if(d0=="Tk"){var iz=R.QI();
iz.add.lnsr="rend";var cc=iz.add.TySh=hd._3(0,0),a4=cc._o,ik=_.GY.clone(),dq=ik.NW();ik.concat(g(r.ctm));
var gi=new eh(1/dq,0,0,-1/dq,0,0);gi.concat(ik);cc.D=gi;var gG=m(eS);iz.nz(gG);hd.KO(a4,0,gG);var dK=hd.tG(a4,0,gG.length);
dK.lJ.FontSize=dq;dK.lJ.FillColor={Type:1,Values:[1,W[0],W[1],W[2]]};hd.hI(dK,_.font);hd.g0(a4,0,gG.length,dK);
R.C.push(iz);R.XW=!0}else if(q&&dt.length>3){var gv=!1;for(var L=0;L<dt.length;L++)if(isNaN(dt[L]))gv=!0;
if(!gv)x[ah+1]=(eS+" "+x[ah+1]).replace(/\s\s+/g," ")}}}function U(R,x,v){var N=UDOC.G,u=[],H=[],F="/DeviceGray",t=1,o=[],q=1;
for(var _=0;_<R.length;_++){var d=R[_];if(d.endsWith(" /CS")){var r=d.indexOf("/NChannel"),p=d.indexOf("/Process");
if(d.startsWith("/DeviceRGB")){F="/DeviceRGB";t=3}else if(d.startsWith("/DeviceGray")){F="/DeviceGray";
t=1}else if(d.startsWith("/DeviceCMYK")){F="/DeviceCMYK";t=4;o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]]}else if(r!=-1){F="/DeviceCMYK";
t=parseInt(d.slice(r-2,r-1));var Q=1;for(var L=0;L<t;L++){Q=d.indexOf("[",Q);o[t-1-L]=d.slice(Q+1,Q+8).split(" ").map(parseFloat);
Q++}}else if(p){F="/DeviceGray";t=1}else throw d}else if(d[0]=="["){var B=d.indexOf("]"),i=d.slice(1,B).split(" ").map(parseFloat),c=d.slice(B+2),h2,jX,bm,dC,fn,fK;
if(c=="/Size"||c=="/P"||c=="/R")continue;if(c=="/S"||c=="/A"){h2=i[0];jX=i[1];bm=i[2];dC=i[3];fn=i[4];
fK=i[5]}else if(c=="/N"){var i6=t+(q==1?0:1),dh;h2=i[i6+0];jX=i[i6+1];bm=i[i6+2];dC=i[i6+3];fn=i[i6+5];
fK=i[i6+6];if(F=="/DeviceRGB")dh=i.slice(0,3);else if(F=="/DeviceGray")dh=[i[0],i[0],i[0]];else if(F=="/DeviceCMYK"){var kA=[0,0,0,0];
for(var L=0;L<t;L++){var ig=i[L],iJ=o[L];kA[0]+=ig*iJ[0];kA[1]+=ig*iJ[1];kA[2]+=ig*iJ[2];kA[3]+=ig*iJ[3]}dh=k(kA)}else throw dh;
dh.push(i[t]);H.push([dh,h2,jX])}else throw c;u.push([c,fn,fK,h2,jX,bm,dC])}else if(d=="/E"){var fL=u.slice(0),fB=0;
for(var L=0;L<u.length;L++){var ah=u[L][0];if(ah=="/N"){fB++;continue}var eS=L,gL=L+1;while(u[gL][0]!="/N"&&gL<u.length)gL++;
if(fB==0||fB==3){for(var e_=0;e_<gL-eS;e_++)fL[eS+e_]=u[gL-1-e_]}else for(var e_=eS;e_<gL;e_++){var c2=fL[e_],jS=c2[1];
c2[1]=c2[5];c2[5]=jS;jS=c2[2];c2[2]=c2[6];c2[6]=jS}L=gL-1}u=[];for(var L=0;L<fL.length;L++){var c2=fL[L];
u.push(c2[1],c2[2],c2[3],c2[4],c2[5],c2[6])}var ie=u.length;N.moveTo(x,u[2],u[3]);for(var L=0;L<ie;L+=6){var bm=u[(L+4)%ie],dC=u[(L+5)%ie],fn=u[(L+6)%ie],fK=u[(L+7)%ie],h2=u[(L+8)%ie],jX=u[(L+9)%ie];
N.curveTo(x,bm,dC,fn,fK,h2,jX)}N.closePath(x);u=[]}else if(d.endsWith("/Version"))q=parseFloat(d[0])}var as=v.QI();
as.FK|=16;as.nz("<Mesh>");var gb=as.add.vstk=JSON.parse(JSON.stringify(at.QO.default));gb.strokeEnabled.v=!1;
if(H.length>=2){var gx=0,eo=0,di=0;for(var L=0;L<H.length;L++)for(var e_=L+1;e_<H.length;e_++){var d0=H[L][0],e6=H[e_][0],dt=d0[0]-e6[0],gJ=d0[1]-e6[1],iW=d0[2]-e6[2],g5=Math.sqrt(dt*dt+gJ*gJ+iW*iW);
if(g5>di){di=g5;gx=L;eo=e_}}var jW=H[gx],eP=H[eo],b_=as.add.GdFl=M(0,[[0,jW[0]],[1,eP[0]]]),fZ=g(x.ctm),im=fZ.bj(new ec(jW[1],jW[2])),j3=fZ.bj(new ec(eP[1],eP[2])),dr=E.p.mY(x.pth.crds);
im.x=(im.x+j3.x)/2;im.y=(im.y+j3.y)/2;E.M.n0(im,j3,dr,b_)}$(as,x.pth,v);v.C.push(as);N.newPath(x)}function M(R,x){var W=JSON.parse(at.UR[at.order.indexOf("GrFl")]),v=W.Grad.v;
v.Intr.v=0;W.Type.v.GrdT=["Lnr","Rdl"][R];E.M.WP(x,v);return W}function m(R){var x=R.indexOf(")");while(R[x-1]=="\\")x=R.indexOf(")",x+1);
return R.slice(R.indexOf("(")+1,x).replaceAll("\\","")}function l(R,W){R.Rd.v=W[0]*255;R.Grn.v=W[1]*255;
R.Bl.v=W[2]*255}function A(R){var x=[];for(var L=0;L<R.length;L++)x[L]=parseFloat(R[L].slice(1));return x}function g(R){return new eh(R[0],R[1],R[2],R[3],R[4],R[5])}function k(R){return E.aN(R)}function $(R,x,v){R.add.vmsk=new h.Rd;
if(x.crds.length!=0)R.add.vmsk.i=C(x);R.hu();R.yb(v)}function C(R){var x={w:R.crds,F:R.cmds},v=E.p.oF(x,!1);
return v}function f(R,x){var v=[],q=0,p=0;for(var N=0;N<2;N++){var u=x[["Raster","Place"][N]];if(u){for(var L=0;
L<u.length;L++){var H=u[L][["Data","PlacedObjectPreview"][N]];if(H==null)continue;var F=H._begin,t=H._end;
if(F>t)F=t;v.push([F,t])}}}v.sort(function(B,i){return B[0]-i[0]});var o=[x._begin];for(var L=0;L<v.length;
L++){var _=v[L],F=_[0]+32;o.push(F,_[1]);q+=_[1]-F}o.push(x._end);var d=x._end-x._begin,r=new Uint8Array(d-q);
for(var L=0;L<o.length;L+=2){var F=o[L],Q=o[L+1]-F;r.set(new Uint8Array(R.buffer,F,Q),p);p+=Q}return J.KY(r).split(/\r\n|\r|\n/)}function z(R,x){if(R==null)return[];
var v=f(x,R),N="",u="",H=0,F;for(var L=2;L<v.length;L++){var t=v[L];if(t[0]=="%"){if(H==0)N+=t.slice(1);
else u+=t.slice(1)}else if(t==";")H++;else if(t.endsWith("/RulerOrigin ,"))F=t.split(" ").slice(0,2).map(parseFloat)}var o=[N,u],q=[];
for(var L=0;L<2;L++){var _=o[L],d=new Uint8Array(_.length);J.Jm(d,0,_);var r=FromPS.F.ASCII85Decode({buff:d,off:0}),p=iK.ew(r);
q.push(p)}q.push(F);return q}function s(R,x){if(R==null)return[];var v=f(x,R);v=v.slice(1);for(var L=0;
L<v.length;L++){var N=v[L];if(N[0]=="%")v[L]=N.slice(N[1]=="_"?2:1)}var u=K(v);return u}function O(R,x){var v={};
if(R==null)return v;for(var L=0;L<R.length;L++){var N=f(x,R[L]),u=N[1],H=m(u),F=u.slice(u.indexOf(")")+2).split(" ").map(parseFloat),t=[];
for(var o=2;o<N.length;o++)t.push(N[o].slice(2));v[H]={H8:F,xW:t}}return v}function a(R,x){var v={},N,u;
if(R==null)return v;var H=[];for(var L=0;L<R.length;L++){var F=f(x,R[L]);for(var t=0;t<F.length;t++){var o=F[t];
if(o.endsWith("%_Bs")){var q=o.slice(0,o.length-4);if(!q.endsWith(" "))q+=" ";o=q+"%_BS"}if(o[0]=="("){N=m(o);
var _=o.split(")"),d=_[1].split(" ");u=parseInt(d[1])}else if(o.endsWith("%_BS")){var _=o.split(" "),B,i=1;
_.pop();_=_.map(parseFloat);var r=_.pop(),p=_.pop(),Q=_.pop();if(Q==0)B=[_[0],_[0],_[0]];else if(Q==2||Q==4)B=[_[4],_[5],_[6]];
else if(Q==1||Q==3)B=k(_);else if(Q==6){if(_.length==3)B=[_[0],_[0],_[0]];else B=k(_);i=_.pop()}else{throw Q}H.push([r/100,B,i,p/100])}else if(o=="BD"){for(var c=0;
c<H.length-1;c++)H[c][3]=H[c+1][3];H.sort(function(h2,jX){return h2[0]-jX[0]});v[N]={Y3:u,arA:H};H=[]}}}return v}function X(R){var x="Gradient PluginObject Symbol Pattern PatternLayer BrushPattern Encoding Raster Layer Resource Place Rider".split(" "),v=Date.now(),N=0,u=[],H={Header:{}},F=[H],t=R.length;
while(N<t){var o=N;while(o!=t&&R[o]!=13&&R[o]!=10){o++}if(R[N]==37&&R[N+1]==95&&R[N+2]==37)N+=2;if(R[N]==37&&(R[N+1]==37||R[N+1]==65)){var q=J.sv(R,N,o-N);
if(q=="%%EOF")break;if(q=="%%EndComments"||q=="%EndComments"||q=="%AI5_Begin_NonPrinting"||q=="%AI5_End_NonPrinting--"||q.startsWith("%AI17_Begin_Content_if_version_gt")||q=="%AI17_End_Versioned_Content"){}else{var _=q.indexOf("Begin"),d=Math.max(q.indexOf("_End"),q.indexOf("%End"));
if(_!=-1&&q[_-1]!="%"&&q[_-1]!="_")_=-1;if(_!=-1){var r=q.slice(_+5).split(":")[0],p={_begin:N,_end:N},Q=F[F.length-1];
if(x.indexOf(r)!=-1){if(Q[r]==null)Q[r]=[];Q[r].push(p)}else{if(Q[r]!=null){console.log(F);throw q}Q[r]=p}F.push(p);
if(q.startsWith("%%BeginData")){o=J.TN(R,"%%EndData",N)}else if(q=="%AI9_BeginDocumentData")o=J.TN(R,"%AI9_EndDocumentData",o);
else if(q=="%AI11_BeginTextDocument")o=J.TN(R,"%AI11_EndTextDocument",o)}else if(d!=-1){if(F.length>1)F.pop()._end=N}else if(F.length==1&&(q.startsWith("%AI")||q.startsWith("%%")&&q.indexOf(" ")!=-1)){var B=1;
if(q.startsWith("%AI"))while(q[B]!="_"&&B<q.length)B++;var i=q.indexOf(":");if(i==-1)i=q.indexOf(" ");
var c=q.slice(B+1,i),h2=q.slice(i+1).trim();H.Header[c]=h2}}}N=o;if(R[N]==13)N++;if(R[N]==10)N++}return H}function P(R,x){var v=Date.now(),N=new Uint8Array(R),u,H=N[2]==68;
if(x)console.log(!H?"EPS":"PDF");if(H){var F=J.TN(N,"/AIMetaData "),dC=!1,fn=!1;while(N[F]!=60)F--;F--;
var t=J.TN(N,">>",F),o=J.sv(N,F+2,t-F-2).split("/"),q=[];for(var L=0;L<o.length;L++){var _=o[L],d=_.startsWith("AIPrivateData"),r=_.startsWith("AIPDFPrivateData");
if(!d&&!r)continue;var p=_.trim().split(/\s+/),Q=parseInt(p[1]),B=parseInt(p[0].slice(d?13:16));q.push([B,Q])}if(x)console.log("--- map made",Date.now()-v);
v=Date.now();var i=FromPDF.indexOfXref(N),c=[],h2=FromPDF.readXrefTrail(N,i,c),jX={buff:N,off:0},bm=new Array(q.length),fK=F;
for(var L=0;L<q.length;L++){var B=q[L][0],Q=q[L][1],i6=FromPDF.getIndirect(Q,0,jX,c),dh=i6.buff,kA=i6["/Filter"],ig=0;
if(kA!=null&&typeof kA=="string")kA=[kA];var iJ=J.sv(dh,ig,ig+20);if(iJ=="%AI12_CompressedData"){ig+=20;
dC=!0}else if(iJ=="%AI24_ZStandard_Data"){ig+=20;fn=!0}dh=new Uint8Array(dh.buffer,dh.byteOffset+ig,dh.length-ig);
if(kA)for(var fL=0;fL<kA.length;fL++){var fB=kA[fL];if(fB=="/FlateDecode")dh=pako.inflate(dh);else if(fB=="/ASCIIHexDecode")dh=FromPS.F.HexDecode({buff:dh,off:0});
else if(fB=="/ASCII85Decode")dh=FromPS.F.ASCII85Decode({buff:dh,off:0});else throw fB}bm[B-1]=dh}if(x)console.log("--- arrays found",Date.now()-v);
v=Date.now();var ah=J.sv(bm[0],0,13);if(ah=="%%BoundingBox"||ah=="%AI7_Thumbnai")bm=bm.slice(1);if(ah=="%AI24_ZStanda"){bm[0]=bm[0].slice(20);
fn=!0}if(J.sv(bm[0],0,13)=="%AI12_Compres"){bm[0]=bm[0].slice(20);dC=!0}u=Z(bm);if(x)console.log("--- concatenated",Date.now()-v);
v=Date.now();if(dC)u=UZIP.inflate(u);if(fn)u=jj.xz.Ue(u);if(x)console.log("--- inflated",Date.now()-v);
v=Date.now()}else{var eS=J.KY(N);if(eS.indexOf("%AI5_BeginLayer")!=-1){u=N}else{var gL=eS.split(/[\n\r]+/),e_=[],c2=!1;
for(var jS=0;jS<gL.length;jS++){var ie=gL[jS].trim();if(ie=="%AI9_PrivateDataEnd"){c2=!1;break}else if(ie=="%AI9_DataStream"||ie=="%AI24_DataStream"){c2=!0}else if(c2)e_.push(ie.slice(1))}var gb=J.zY(e_.join("")),gx=FromPS.F.ASCII85Decode({buff:gb,off:0});
if(gx[0]==120&&gx[1]==156)u=UZIP.inflate(gx);else u=jj.xz.Ue(gx)}}return u}function Z(R){var x=0,N=0;
for(var L=0;L<R.length;L++)x+=R[L].length;var v=new Uint8Array(x);for(var L=0;L<R.length;L++){var u=R[L];
v.set(u,N);N+=u.length}return v}function Y(R,x){for(var L=0;L<x.length;L++)if(R.startsWith(x[L]))return!0;
return!1}function K(R){var x=[],v=[],top=-1,N,u=null,H=null,F=null,t=0;for(var o=0;o<R.length;o++){var q=R[o];
if(N){q=N+q;N=null}var _="\t".repeat(x.length);if(u!=null){u.push(q);if(q.endsWith("~>")){var d=J.zY(u.join("")),r=FromPS.F.ASCII85Decode({off:0,buff:d});
x.push(r);v.push(!1);top++;u=null}}else if(F!=null){if(q=="X+"){if(t==1){x.push(F);v.push(!1);top++;
F=null}else t--}else if(q=="X=")t++;else F.push(q)}else if(H!=null){if(q=="/Def ; "){x.push(H);v.push(!1);
top++;H=null}else H.push(q)}else if(q=="/Binary : /ASCII85Decode ,"){u=[]}else if(q=="X="){F=[];t++}else if(q=="/FillStyle : 0 O"){H=["0 O"]}else if(q=="/SVGFilter :"||q=="; /Def ;")continue;
else if(q.startsWith("/XMLUIDREF :")){var p=S(q);x[top][p[4]]=p[2]}else if(q.startsWith("/")&&q[1].toUpperCase()!=q[1].toLowerCase()){if(q.startsWith("/XMLUID")){var p=S(q);
if(v[top])throw"e";x[top][p[4]]=p[2]}if(q.startsWith("/GObjRef")){var p=S(q);if(p.length==7){if(v[top])throw"e";
x[top][p[5]]=p[2]}else{if(!v[top])throw"e";x[top].push(p[2])}}else{var Q=q.startsWith("/Array")||q.startsWith("/Document");
x.push(Q?[]:{});v.push(Q);top++}}else if(q.endsWith(",")){var B,i,p=S(q);p.pop();if(p[0]==";"||p.length==1||q==" ,"){i=x.pop();
v.pop();top--;B=v[top]?null:p.pop()}else{B=v[top]?null:p.pop();var c=p.pop(),h2=p[0];if(c=="/Int")i=parseInt(h2);
else if(c=="/Real")i=parseFloat(h2);else if(c=="/Bool")i=h2=="1";else if(c=="/String"||c=="/UnicodeString")i=p.join("");
else if(c=="/RealMatrix"||c=="/RealPoint"||c=="/RealPointRelToROrigin")i=p.map(parseFloat);else throw c}if(v[top])x[top].push(i);
else x[top][B]=i}else if(q==";"){}else if(q==""){}else{if(q.indexOf("/RealPoint")!=-1){}else if(q.startsWith("(")&&q.endsWith(")")){}else if(q.endsWith("/RealMatrix")){}else throw q;
N=N?N+q:q}}return x}function S(R){var x=0,v=[];while(x<R.length){var N=R[x],u=N.charCodeAt(0);if(N==" ")x++;
else if(N==","||N==";"||N==":"){v.push(N);x++}else if(N=="("){var H=x+1;while(!(R[H]==")"&&R[H-1]!="\\"))H++;
var F=R.slice(x+1,H);v.push(F);x=H+1}else if(N=="/"||N=="-"||48<=u&&u<=57){var H=x;while(R[H]!=" ")H++;
v.push(R.slice(x,H));x=H}else throw N}return v}function G(R){var x="";for(var L=0;L<R.length;L++){if(R[L]=="_"&&R[L+1]=="x"){var bK=parseInt(R.slice(L+2,L+4),16);
x+=String.fromCharCode(bK);L+=4}else if(R[L]=="_")x+=" ";else x+=R[L]}return x}function V(R){var x="xmlnode-nodename",v="xmlnode-nodevalue",N="xmlnode-attributes",u="xmlnode-children",H=R[x],F=R[N],t=R[u],o={_nam:H};
for(var q in F){var _=F[q];if(Object.keys(_[N]).length!=0||_[u].length!=0)throw"e";if(_[x]!=q)throw"e";
o[q]=_[v]}if(t.length==0)return o;var d=o.cln=[];for(var L=0;L<t.length;L++)d.push(V(t[L]));return o}function T(R){var x="xmlnode-nodename",v="xmlnode-nodevalue",N="xmlnode-attributes",u="xmlnode-children",H=R[x].split(":").pop().replace("#",""),F=R[N],t=R[u],o="<"+H;
for(var q in F)if(q!="xmlns"&&q!="xmlns:v")o+=" "+q.split(":").pop()+"=\""+F[q][v]+"\"";o+=">"+(t.length==0?"":"\n");
for(var L=0;L<t.length;L++)o+=T(t[L]);if(R[v])o+=R[v];return o+"</"+H+">\n"}return w}();function eU(){}eU.ew=function(){var w,n,W,D,j,s,O,a;
function I(N){return J.sY(w,N)}function U(N){return J.vQ(w,N)}function M(N){return J.ly(w,N)}function m(N){return J.ck(w,N)}function l(N,u){var H=[];
for(var L=0;L<u;L++)H.push(M(N+L*4));return H}function A(N,u){var H=[];for(var L=0;L<u;L++)H.push(I(N+L*8));
return H}function g(N){return M((N+1)*4096-12)}function k(N){return M((N+1)*4096-8)}function $(N,n,u,H){if(D[N]==null)D[N]=[];
D[N].push([H,new Uint8Array(w.buffer,n,u)])}function C(N,u,H,F){var t=W[N],n=t*4096;n=n+M(n+4096-24-12-u*4);
var o=U(n),q=w[n+2],_=w[n+3];if(u!=q)throw q;if(_==0)$(F,n+4,H,9);else{var d=U(n+6),r=M(n+8);$(F,n+12,o-12,9);
C(r,d,H-(o-12),F)}}function f(){var N=M(352),u=M(N*4096+128),H=M(936);W=[];D={};j={};for(var L=0;L<1e9;
L++){var F=M(H*4096+128+L*4);if(F==0)break;var t=l(F*4096+128,4096-128-12>>>2);W=W.concat(t)}for(var o=0;
o<W.length;o++){var q=W[o],_=g(q);if(_!=6)continue;var n=q*4096,d=M(n);n+=4;for(var L=0;L<d;L++){var r=M(n);
n+=4;var p=M(n);n+=4;var Q=M(n);n+=4;var B=M(n);n+=4;if(r==0)j[p]=Q;else{var i=Q&65535,c=Q>>>16;if(c==0)$(p,B*4096,i,8);
else C(B,c,i,p)}}}var s={};for(var h2 in D){var jX=D[h2],bm=jX.length;if(bm==1)s[h2]=jX[0][1];else{var dC=0,n=0;
for(var L=0;L<bm;L++)dC+=jX[L][1].length;var fn=s[h2]=new Uint8Array(dC);for(var L=0;L<bm;L++){fn.set(jX[L][1],n);
n+=jX[L][1].length}}}return s}function z(n,N){var u=N?M(n):U(n),H="";n+=N?4:2;while(H.length<u){var F=w[n++],t=w[n++],o=0,q="";
F+=(t&15)*256;t=t&240;for(var L=0;L<F;L++){if(t==64)o=w[n++];else if(t==128)o=w[n++]|w[n++]<<8;else throw t;
q+=String.fromCharCode(o)}H+=q}return[H,n]}function X(n,N,u){var H=l(n,N);for(var L=0;L<N;L++){u.push(L);
if(H[L]>O)throw"e";H[L]=Z(H[L],u);u.pop()}return H}var P={};function Z(N,u){if(a.indexOf(N)!=-1)return s[N];
if(N==0)return null;if(s[N]==null)return null;if(!(s[N]instanceof Uint8Array))return s[N];var H=w,n=0;
w=s[N];a.push(N);var F=j[N].toString(16),t=s[N]={_type:v[F]?v[F]+":"+F:"typ-"+F,_eid:N};while(n+8<w.length){var o=M(n);
n+=4;var q=o.toString(16),_=M(n);n+=4;var d=n+_;if(n+_>w.length){t._bin=w;break}Y(q,V,t,n,_,u);n=d}w=H;
a.pop();return t}function Y(N,u,H,n,F,t){var o=u[N+":"+H._type];if(o==null)o=u[N];t.push(o?o[0]==""?N:o[0]:N);
if(o){var q=o[0],_=null,d=o[1];if(q=="")q=d+"-"+N;if(R[d]&&F!=R[d]){console.log(d);console.log(N,o);
console.log(w.slice(n,n+F));throw"e"}if(d=="mat")_=A(n,6);else if(d=="mmat")_=[Z(M(n),t),A(n+6,6)];else if(d=="rect")_=A(n,4);
else if(d=="mrct"){_=A(n,4);_.push(U(n+32))}else if(d=="doub")_=I(n);else if(d=="pointArr"){var r=U(n);
_=l(n+2,r*2)}else if(d=="usrt")_=U(n);else if(d=="uint")_=M(n);else if(d=="pntr"||d=="ptr6"){_=Z(M(n),t)}else if(d=="bool2"){if(U(n)!=0&&U(n)!=1)throw U(n);
_=U(n)==1}else if(d=="bool4"){if(M(n)!=0&&M(n)!=1)throw N+","+M(n);_=M(n)==1}else if(d=="color"){if(F!=38&&F!=30)throw F;
var p=M(n),Q=U(n+4);_=[p];for(var L=0;L<Q;L++)_.push(I(n+6+L*8))}else if(d=="path"){var B=n+F;_=[];var i=M(n);
n+=4;for(var L=0;L<i;L++){var c=[[]];_.push(c);var h2=M(n);n+=4;for(var jX=0;jX<h2;jX++){var p=M(n);
n+=4;if(p<2){c[0].push([p,I(n),I(n+8),I(n+16),I(n+24),I(n+32),I(n+40)]);n+=48}else if(p==2){c[0].push([p,I(n),I(n+8)]);
n+=16}else throw p}c.push(U(n));n+=2}}else if(d=="ptrAndList"){var bm=M(n),dC=M(n+4);_=X(n+8,dC,t);_.unshift(Z(bm,t))}else if(d=="ptrArray"||d=="ptrArrayX"){var fn=F>>2;
if(d=="ptrArray"){fn=M(n);n+=4;if(F!=4+fn*4)throw F}_=X(n,fn,t)}else if(d=="ptrArray2"){var fn=M(n);
n+=4;_=X(n,fn,t);n+=fn*4;fn=M(n);n+=4;_.push(X(n,fn,t))}else if(d=="cldrn"){var fK=M(n),i6=M(n+4),fn=M(n+8);
_={c:Z(fK,t),T2:Z(i6,t),hK:X(n+12,fn,t)};if(F!=12+fn*4){console.log(N,sa);throw"e"}if(fK==0)throw fK}else if(d=="aprnc"){var fn=M(n);
n+=4;_={};for(var L=0;L<fn;L++){var dh=M(n),kA=U(n+4),ig=U(n+6);n+=8;var iJ=x[dh.toString(16)];if(iJ==null)iJ="prm-"+dh.toString(16);
else iJ=G(iJ);_[iJ]=[];for(var jX=0;jX<ig;jX++){var fL=M(n),fB=U(n+4),ah=null;n+=6;if(fL==28264)ah=I(n);
else if(fL==28263)ah=M(n);else if(fL==279)ah=Z(M(n),t);else if(fL==28261)ah=U(n)==1;else if(fL==28265)ah=[I(n),I(n+4)];
else if(fL==83231)ah=z(n+3)[0];else if(fL==28259||fL==28260||fL==23094||fL==67679){ah=w.slice(n,n+fB)}else throw fL.toString(16);
_[iJ].push(ah);n+=fB}}}else if(d=="lopts"){_={au5:U(n+0)==1,show:U(n+2)==1,akI:U(n+4)==1,MB:M(n+10),name:z(n+21)[0]}}else if(d=="origin"){var B=n+F;
if(w[n++]!=1)throw"e";var r=M(n);n+=4;var eS=J.sv(w,n,r);n+=r;if(w[n++]!=1)throw"e";var gL=w[n++];if(gL!=1&&gL!=53)throw gL;
var e_=U(n);n+=2;if(e_!=0&&e_!=1)throw e_;var c2=M(n);n+=4;if(c2!=0&&c2!=1)throw c2;var jS=M(n);n+=4;
if(jS!=0&&jS!=2&&jS!=3)throw jS;var ie=M(n);n+=4;var as=z(n,!0);n=as[1];as=as[0];var gb=M(n),gx=M(n+4);
n+=8;var eo=M(n);n+=4;if(eo!=0)throw eo;var di=M(n);n+=4;n+=3;var d0=z(n)[0];n+=2+2+d0.length;_={file:eS,id:as,$x:d0}}else if(d=="string")_=z(n+3)[0];
else if(d=="relEnt"){var e6=U(n);n+=2;_=[];for(var L=0;L<e6;L++)_.push([M(n+L*8),Z(M(n+L*8+4),t)])}else if(d=="textData"){var B=n+F,dt=M(n);
n+=4;var dh=M(n);n+=4;var Q=U(n);n+=2;var gJ=[];for(var L=0;L<Q;L++){var iW=M(n);n+=4;if(dt==514)gJ.push(z(n,!0)[0]);
else if(dt==515){var g5=M(n),N=M(n+4),jW=K(n+8,t);gJ.push([g5,Z(N,t),jW])}else if(dt==516){var g5=M(n),N=M(n+4),eP=U(n+8),jW=K(n+8,t);
gJ.push([g5,Z(N,t),jW])}else gJ.push(w.slice(n,n+iW));n+=iW}if(B-n!=12)throw B-n;_=gJ}else if(d=="storyProps"){var b_=M(n);
if(U(n+4)>1)throw"e";var fZ=Z(M(n+6),t),Q=M(n+10),im=Z(M(n+14+Q*4),t);_={abu:b_,aeD:fZ,hK:X(n+14,Q,t),acz:im,a4U:l(n+14+Q*4+4,4)}}else if(d=="styleProps")_=K(n,t);
else if(d=="bounds"){var j3=n,e6=M(n);n+=4;_=[];for(var L=0;L<e6;L++){var dr=[];_.push(dr);for(var jX=0;
jX<4;jX++)dr.push(I(n+jX*8));n+=32;dr.push(w[n]);n++}if(n!=j3+F)throw"e"}else if(d=="columnPos"){var e6=M(n);
n+=4;_=[A(n,e6),I(n+e6*8)];n+=e6*8+8}else if(d=="StyleName"){_=[M(n+4)]}else if(d=="fontName"){var B=n+F;
_=[U(n)];n+=2;for(var L=0;L<2;L++){var eS=z(n+3);n=eS[1];_.push(eS[0])}_.push(M(n));n+=4;var c0=U(n);
n+=2;_.push(c0);var fM=U(n);n+=2;var cB=[];_.push(cB);for(var iI=0;iI<fM;iI++){var jD=[];cB.push(jD);
var eS=z(n+3);n=eS[1];jD.push(eS[0]);var j8=U(n);n+=2;var eS=J.sv(w,n,j8);n+=j8;jD.push(eS);for(var L=0;
L<3;L++){var eS=z(n+3);n=eS[1];jD.push(eS[0])}jD.push(M(n));n+=4;var eS=z(n,!0);n=eS[1];jD.push(eS[0])}if(n+4!=B)throw"e";
_.push(M(n))}else throw d;if(H[q]!=null){console.log(q,H[q],_);console.log(t.slice(0));console.log(eid,N,n,H[q],o,_);
throw"e"}H[q]=_}else{var jG=w.slice(n,n+F);H["prop-"+N]=jG}t.pop()}function K(n,N){var u=U(n);n+=2;var H={};
for(var L=0;L<u;L++){var F=M(n);n+=4;var t=F.toString(16),o=U(n);n+=2;var q=U(n);n+=2;for(var _=0;_<q;
_++){var d=M(n);n+=4;var r=U(n);n+=2;Y(t,T,H,n,r,N);n+=r}}return H}function S(N){w=new Uint8Array(N);
s=f();var u=s[2147483649];u=J.KY(u,4,u.length-4);delete s[2147483649];O=0;for(var H in s)O=Math.max(O,parseInt(H));
a=[];var F={};for(var H in s)F[H]=s[H];for(var H in s)Z(parseInt(H),[]);return s}function G(N){N=N.split(" ").join("");
return N[0].toLowerCase()+N.slice(1)}var V={"2d2":["","bool2"],"1623":["","bool2"],"2c32":["visible","bool2"],cd1f:["","bool2"],"1b8":["","bool4"],"2c2d":["locked","bool4"],"118":["","uint"],"119":["bitmap","uint"],"117":["","uint"],"117:Page:50f":["color","pntr"],"117:Fill:1f05":["parentFill","pntr"],"56c":["","uint"],bf31:["","uint"],ca58:["","uint"],cade:["","uint"],"313":["","pntr"],a6b:["trapPreset","pntr"],e02:["","pntr"],"170d":["bitmapFill","pntr"],"1b916":["","pntr"],"205":["columns","ptrAndList"],"220":["obj228","ptrAndList"],"2ab":["story","ptrArrayX"],"302":["layer","ptr6"],"21f":["rect","rect"],"27e":["","rect"],"2d6":["rect","rect"],"565":["rect","rect"],"5dd":["rect","rect"],"1633":["rect","rect"],"51a":["margins","mrct"],"151":["transform","mat"],"2de":["transform","mat"],"40d":["transform","mat"],"56e":["transform","mat"],"5cc":["transform","mat"],"140f":["mTransform","mmat"],"14527":["transform","mat"],"528":["columnPos","columnPos"],"261":["relEnt","relEnt"],"262":["textData","textData"],"15b":["children","cldrn"],"2c8":["children","cldrn"],"303":["children","cldrn"],"503":["children","cldrn"],"28dc":["children","cldrn"],"104e5":["children","cldrn"],"1b95a":["children","cldrn"],"1f01":["color","color"],"162b":["path","path"],"6e03":["appearance","aprnc"],"304":["lopts","lopts"],"2c10":["name","string"],"8c92":["origin","origin"],"3e05":["name","fontName"],"20f":["","ptrArrayX"],"210":["","ptrArrayX"],"211":["","ptrArrayX"],"222":["stories","ptrArray2"],"223":["stoProps","storyProps"],"23f":["styProps","styleProps"],"2c6b":["bounds","bounds"],"230":["name","StyleName"],"301":["layers","ptrArray"],"501":["spreads","ptrArray"],"4c01":["sections","ptrArray"],"1401":["masterSpreads","ptrArray"],a67:["","ptrArray"],"1f05":["colors","ptrArray"],"1f0c":["","ptrArray"],"1f60":["","ptrArray"],"1f61":["","ptrArray"],"288a":["","ptrArray"],"377c":["textFrames","ptrArray"],"3e06":["","ptrArray"],"1081d":["","ptrArray"]},T={"1b01":["fillColor","pntr"],"1b02":["fontStyle","string"],"1b03":["FontSize","doub"],"1b11":["FontCaps","usrt"],"1b16":["StartIndent","doub"],"1b17":["EndIndent","doub"],"1b18":["FirstLineIndent","doub"],"1b1b":["leading","doub"],"1b26":["SpaceBefore","doub"],"1b27":["SpaceAfter","doub"],"1b2a":["Underline","bool2"],"1b2b":["font","pntr"],"1b3c":["FontBaseline","usrt"],"1b3d":["Strikethrough","bool2"],"1b7e":["align","usrt"]},R={mmat:54,mat:48,mrct:34,rect:32,doub:8,ptr6:6,uint:4,pntr:4,bool4:4,bool2:2,usrt:2},x={"10816":"Object Opacity","10891":"Stroke Opacity","10892":"Stroke Blending Mode","10893":"Stroke Knockout Group","10894":"Stroke Isolate Blending","108d8":"Fill Opacity","108d9":"Fill Blending Mode","108da":"Fill Knockout Group","108db":"Fill Isolate Blending","10817":"Object Blending Mode","10818":"Object Knockout Group","10819":"Object Isolate Blending","6e64":"Stroke Swatch","6e65":"Stroke Weight","6e66":"Stroke Tint","6e6e":"Stroke Type","6e68":"Fill Swatch","6e69":"Fill Tint","6e6b":"Stroke Cap","6e6c":"Stroke Join","6e6d":"Stroke Mitre Limit","6e8c":"Stroke Align Stroke","6e71":"Stroke Start Arrrowhead","6e72":"Stroke End Arrrowhead","6e89":"Stroke Gap Color Swatch","6e8a":"Stroke Gap Tint","6e84":"Stroke Arrowhead Align","6e95":"Stroke Start Arrowhead Scale","6e96":"Stroke End Arrowhead Scale","6e8f":"Corner 1 Shape","6e6f":"Corner 2 Shape","6e90":"Corner 3 Shape","6e91":"Corner 4 Shape","6e70":"Corner 1 Size","6e92":"Corner 2 Size","6e93":"Corner 3 Size","6e94":"Corner 4 Size","1081a":"Drop Shadow","1081b":"Drop Shadow DX","1081c":"Drop Shadow DY","1081e":"Drop Shadow Opacity","1081f":"Drop Shadow BMode","10820":"Drop Shadow Size","10837":"Drop Shadow Color","1084d":"Inner Shadow","1084e":"Inner Shadow Color","1084f":"Inner Shadow BMode","10850":"Inner Shadow Opacity","10851":"Inner Shadow Angle","10852":"Inner Shadow Dist","10855":"Inner Shadow Size","10857":"Oglow","10858":"Oglow BMode","10859":"Oglow Opacity","1085b":"Oglow Color","1086d":"Oglow Choke","1085e":"Oglow Size","1085f":"Iglow","10860":"Iglow BMode","10861":"Iglow Opacity","10863":"Iglow Color","10865":"Iglow Choke","10866":"Iglow Size","10868":"Bevel","1086b":"Bevel Depth","1086d":"Bevel Size","1086f":"Bevel Angle","10870":"Bevel Alt","10872":"Bevel ColorH","10873":"Bevel BModeH","10874":"Bevel OpacityH","10875":"Bevel ColorS","10875":"Bevel BModeS","10877":"Bevel OpacityS","10878":"Satin","10879":"Satin Color","1087a":"Satin BMode","1087b":"Satin Opacity","1087c":"Satin Angle","1087d":"Satin Dist","1087e":"Satin Size","1087f":"Satin Invert","10821":"Basic Feather","10822":"Basic Feather Width","10895":"Stroke Drop Shadow","10899":"Stroke Drop Shadow Blending Mode","1eb8f":"GradientFeatherSetting GradientStart","1eb8e":"GradientFeatherSetting Length","14534":"name"},v={e01:"Document","301":"RESpread","236":"REParStyle","302":"Layer","401":"Group","501":"Spread","50f":"Page","227":"Column","201":"Story","205":"Style","263":"TextFrame",a32:"Trapping","1f05":"Fill","3e03":"Font","6201":"Path",ca18:"StoryText"};
return S}();function eq(){}eq.ew=function(){var w=0;function n(g,k){var $=eU.ew(g),T=1;w=0;var C=$[1],f=C.spreads,z=[],s=new iB;
for(var O=0;O<f.length;O++){var a=f[O],X=a.children.hK,P=D(a),Z=X[0].children.hK,Y=new iB;for(var K=0;
K<Z.length;K++){var S=Z[K],G=D(S);G.concat(P);var V=W(S);V.offset(G.z2,G.EU);V=E.p.fF(V);Y=Y.x0(V)}z.push(Y);
s=s.x0(Y)}while(Math.sqrt(s.O())*T<1e3)T++;k.m=s.m*T;k.n=s.n*T;k.buffer=new Uint8Array(4*k.m*k.n);k.XW=!0;
k.om(f.length);for(var O=0;O<f.length;O++){var a=f[O],X=a.children.hK,R=k.QI();R.FK=24;R.add.lsct=ef.fz;
R.nz("Artboard "+(O+1));var x=z[O].clone();x.offset(-s.x,-s.y);x.x*=T;x.y*=T;x.m*=T;x.n*=T;x=E.p.fF(x);
R.MR(x);R.Bx="pass";k.C.push(k.hG());var P=D(a);P.translate(-s.x,-s.y);P.scale(T,T);var v={};for(var N=0;
N<X.length-1;N++){var u=X[N],H=u.children.hK,F=k.QI(),t=u.layer.lopts;if(t.name=="Internal_pages_layer_name"||v[t.name])continue;
v[t.name]=!0;F.FK=24;F.add.lsct=ef.fz;F.nz(t.name);F.gb(t.show);if(t.au5)F.add.lspf=1<<31;F.Bx="pass";
k.C.push(k.hG());for(var L=0;L<H.length;L++)m(H[L],k,P,$);k.C.push(F)}k.C.push(R)}}function W(g){var k=g.rect;
return new iB(k[0],k[1],k[2]-k[0],k[3]-k[1])}function D(g){var k=g.transform;return new eh(k[0],k[1],k[2],k[3],k[4],k[5])}function j(g){var k=g.color,$=g.parentFill,f;
if(k==null&&$)k=$.color;if(k==null){console.log("strange color",g);return[0,0,0]}var C=k[0];if(C==5)f=k.slice(1);
else if(C==6)f=UDOC.C.cmykToRgb(k.slice(1));else if(C==7){var z=E.kH(k[1],k[2],k[3]);f=[z.o/255,z.B/255,z.k/255]}else if(C==14){f=k.slice(1);
console.log("unsure about the color")}else{console.log(k);throw C}return f}function I(g){var k=j(g);
return E.M.lW({o:k[0]*255,B:k[1]*255,k:k[2]*255})}function U(g){return"norm,mul ,scrn,over,sLit,hLit,div ,idiv,dark,lite,diff,smud,hue ,sat ,colr,lum ".split(",")[g]}function M(g,k){var L=0,$=0;
while($+g[L][0]<=k){$+=g[L][0];L++}g=g[L][1].textData;L=0;while($+g[L][0]<=k){$+=g[L][0];L++}return g[L]}function m(g,k,$,C){var f=g.transform?D(g):new eh;
f.concat($);$=f;var z=g.path,s=g.appearance,O=g.visible,a=g.children?g.children.hK:null,X=k.QI();if(O!=null)X.gb(O);
var P=a&&a.length==1&&a[0].bitmapFill,Z=g["bool2-1623"]&&a&&a.length==1&&a[0].rect&&a[0]._type.startsWith("TextFrame");
if(P){X.nz("bitmap");var Y=a[0],K=W(Y),S=D(Y);S.concat($);var G=Y.bitmapFill.bitmap;G=C[G]._bin;if(G.length!=G.buffer.byteLength)G=G.slice(0);
var V=k.An(G,"img.jpg",0,0);V.FK=X.FK;X=V;var T=[0,0,K.m,0,K.m,K.n,0,K.n];E.p.D(T,S,T);X.add.SoLd.Trnf=y.wR.Hh(T);
X.add.SoLd.nonAffineTransform=y.wR.Hh(T);X.vr(k,!1);var R=Y.path;if(R&&R.length!=0)X.add.vmsk=A(R,S,s);
else if(z&&z.length!=0)X.add.vmsk=A(z,$,s);X.hu();X.yb(k)}else if(Z){if(s&&s.strokeSwatch){var x=k.QI();
l(x,k,s,z,$);k.C.push(x)}var v=a[0],K=W(v),S=D(v),jX=0;S.concat($);var N=v.children.hK[0],u=N.obj228,H=u[0].story[1],F=H.stoProps.aeD.relEnt,t=H.stoProps.hK[0].relEnt,o=H.stoProps.hK[1]["ptrArrayX-210"][0].textData,q=C[F[0][1].textData[0][1].name[0]],_=q?q.styProps:{};
o=o.join("").replace(/\r/g,"\n");var d=-1;while((d=o.indexOf("\uFFFC"))!=-1){o=o.slice(0,d)+(o[d-1]=="\n"?" ":" ")+o.slice(d+1)}X.nz(o.slice(0,255));
X.add.lnsr="rend";X.add.TySh=hd._3(0,0);X.add.TySh.IA=K;X.add.TySh.D=S;var r=X.add.TySh._o;hd.KO(r,0,o);
var p=hd.tG(r,0,o.length);p.lJ.FontSize=10;hd.g0(r,0,o.length,p);var Q=[];if(o.length!=0){var B=M(F,0),i=M(t,0),c=1;
for(var L=1;L<o.length;L++){var z=M(F,L),h2=M(t,L);if(z!=B||h2!=i){Q.push(c);c=0}B=z;i=h2;c++}if(c!=0)Q.push(c)}for(var L=0;
L<Q.length;L++){var bm=M(t,jX),dC=Q[L],fn=Math.min(jX+dC,o.length-1),fK=bm[2],i6=bm[1].styProps;if(i6==null)i6={};
var dh=M(F,jX),kA=dh[1].styProps,ig=dh[2],iJ={};for(var fL in _)iJ[fL]=_[fL];for(var fL in kA)iJ[fL]=kA[fL];
for(var fL in ig)iJ[fL]=ig[fL];for(var fL in i6)iJ[fL]=i6[fL];for(var fL in fK)iJ[fL]=fK[fL];var p=hd.tG(r,jX,fn),fB=["FontSize","FontCaps","Underline","Strikethrough","FontBaseline"],ah=fB.concat(["StartIndent","EndIndent","FirstLineIndent","SpaceBefore","SpaceAfter"]);
for(var eS=0;eS<ah.length;eS++){var fL=ah[eS],gL=eS<fB.length?p.lJ:p.ci;if(iJ[fL]!=null)gL[fL]=iJ[fL]}if(iJ.fillColor){var e_=j(iJ.fillColor);
p.lJ.FillColor={Type:1,Values:[1].concat(e_)}}if(iJ.font){var c2=iJ.font.name[5],jS=iJ.fontStyle;if(jS==null)jS="Regular";
for(var ie=0;ie<c2.length;ie++)if(c2[ie][0]==jS)hd.hI(p,c2[ie][1])}if(iJ.leading!=null&&iJ.leading>1){p.lJ.Leading=iJ.leading;
p.lJ.AutoLeading=!1}if(iJ.align!=null)p.ci.Justification=[0,2,1,6,3,5,4,0,0,0][iJ.align];hd.g0(r,jX,fn,p);
jX+=dC}hd.VL(r,1);hd.sV(r,[0,0,Math.round(K.m),Math.round(K.n)])}else if(g._type.startsWith("Path")&&(a==null||a.length==0)&&z){l(X,k,s,z,$)}else{var as=g["prop-14526"];
if(a==null&&as){var gb=C[J.ly(as,20)];a=[gb]}if(a){if(z&&z.length!=0){X.add.vmsk=A(z,$,s);X.hu();X.yb(k)}X.nz("group");
X.FK=24;X.add.lsct=ef.fz;k.C.push(k.hG());for(var L=0;L<a.length;L++)m(a[L],k,$,C)}}if(s){var gx=s.objectBlendingMode,eo=s.objectOpacity,di=s.fillTint,e6=!1;
if(gx)X.Bx=U(gx[0]);if(eo)X.opacity=Math.round(X.opacity*eo[0]/100);if(!P&&di)X.opacity=Math.round(X.opacity*di[0]/100);
var d0=JSON.parse(at.default);for(var L=0;L<at.order.length;L++)d0[at.Pa[L]]={t:"VlLs",v:[]};var dt="dropShadow innerShadow satin bevel iglow oglow".split(" "),gJ="DrSh IrSh ChFX ebbl IrGl OrGl".split(" ");
for(var L=0;L<dt.length;L++){var iW=dt[L];if(s[iW]&&s[iW][0]){var eP=s[iW],fZ=135,j3=10;e6=!0;var b_=JSON.parse(at.UR[at.order.indexOf(gJ[L])]);
d0[at.Pa[at.order.indexOf(gJ[L])]].v.push({t:"Objc",v:b_});if(s[iW+"Color"])b_.Clr.v=I(s[iW+"Color"][0]);
else if(dt[L]=="iglow"||dt[L]=="oglow")b_.Clr.v=E.M.lW({o:255,B:255,k:255});if(s[iW+"ColorH"])b_.hglC.v=I(s[iW+"ColorH"][0]);
if(s[iW+"ColorS"])b_.sdwC.v=I(s[iW+"ColorS"][0]);if(s[iW+"BMode"])b_.Md.v.BlnM=dD.Eu(U(s[iW+"BMode"][0]));
if(s[iW+"BModeH"])b_.hglM.v.BlnM=dD.Eu(U(s[iW+"BModeH"][0]));if(s[iW+"BModeS"])b_.sdwM.v.BlnM=dD.Eu(U(s[iW+"BModeS"][0]));
if(s[iW+"Opacity"])b_.Opct.v.val=s[iW+"Opacity"][0];if(s[iW+"OpacityH"])b_.hglO.v.val=s[iW+"OpacityH"][0];
if(s[iW+"OpacityS"])b_.sdwO.v.val=s[iW+"OpacityS"][0];if(s[iW+"Size"])b_.blur.v.val=s[iW+"Size"][0];
if(s[iW+"Angle"])fZ=s[iW+"Angle"][0];if(s[iW+"Dist"])j3=s[iW+"Dist"][0];if(s[iW+"DX"]){var dr=s[iW+"DX"][0],c0=s[iW+"DY"][0];
j3=Math.round(Math.sqrt(dr*dr+c0*c0));fZ=Math.round(Math.atan2(c0,-dr)*180/Math.PI)}if(b_.lagl)b_.lagl.v.val=fZ;
if(b_.Dstn)b_.Dstn.v.val=j3;if(b_.uglg)b_.uglg.v=!1;if(s[iW+"Invert"])b_.Invr.v=s[iW+"Invert"][0];else if(dt[L]=="satin")b_.Invr.v=!1;
if(s[iW+"Alt"])b_.Lald.v.val=s[iW+"Alt"][0];if(s[iW+"Depth"])b_.srgR.v.val=s[iW+"Depth"][0];if(s[iW+"Choke"])b_.Ckmt.v.val=s[iW+"Choke"][0]}}if(e6)X.add.lmfx=d0}if(g.name)X.nz(g.name);
else if(s&&s.name)X.nz(s.name[0]);k.C.push(X)}function l(g,k,$,C,f){g.nz("path");g.FK|=16;g.add.vmsk=A(C,f,$);
var z=g.add.vstk=JSON.parse(JSON.stringify(at.QO.default)),s=null;if($){var O=$.strokeSwatch,a=$.fillSwatch,X=$.basicFeather,P=$.basicFeatherWidth,Z=$.strokeWeight;
z.strokeEnabled.v=O!=null;z.fillEnabled.v=a!=null;if(X)g.add.vmsk.C3=P?P[0]:9;if(O){z.strokeStyleLineWidth.v.val=Z?Z[0]:1;
s=I(O[0]);z.strokeStyleContent.v.Clr.v=s}if(a){s=I(a[0])}}if(s)g.add.SoCo={classID:"null",Clr:{t:"Objc",v:s}};
g.hu();g.yb(k)}function A(g,k,$){var C=new h.Rd,f=C.i;for(var z=0;z<g.length;z++){var s=g[z],O=s[0].length,a=s[1]==0,X=a?0:3;
f.push({type:X,length:O,Ht:0,S1:2,_T:0,si:0});for(var L=0;L<O;L++){var P=s[0][L],Z=P[0],Y=new ec(P[1],P[2]),K=new ec(P[3],P[4]),S=new ec(P[5],P[6]);
if(Z==0||Z==1)f.push({type:X+2,T7:Y,H:K,mO:S});else if(Z==2)f.push({type:X+2,T7:Y,H:Y,mO:Y});else throw Z}}E.P.c0(f,k);
return C}return n}();var hj=function(w){function n(U,M){var m=[];for(var L=0;L<9;L++){var l=J.q(U,M+L*4);
if(L%3==2)m.push((l>>>30)+(l&1073741823)/1073741823);else m.push((l>>>16)+(l&65535)/65535)}return m}function W(U,M,m,l){var A={},g=J.q,k=J.IQ;
while(M<m){var $=M,C=J.q(U,M);M+=4;if(C==0){C=J.q(U,M);M+=4}var f=J.sv(U,M,4);M+=4;if(C==0)throw"e";
if(C==1){C=J.gg(U,M);M+=8}var z=$+C,s="".padStart(l,"\t"),O={};if(f=="mvhd"){var a=U[M];if(a!=0)throw"e";
M+=4;O.a0l=g(U,M);M+=4;O.aya=g(U,M);M+=4;O.MZ=g(U,M);M+=4;O.duration=g(U,M);M+=4;O.ak8=g(U,M);M+=4;O.volume=k(U,M);
M+=2;M+=10;O.aal=n(U,M);M+=4*9;O.a3n=[];for(var L=0;L<6;L++)O.a3n.push(g(U,M+L*4));M+=4*6;O.a8o=g(U,M);
M+=4}else if(f=="tkhd"){var a=U[M];if(a!=0)throw"e";M+=4;O.a0l=g(U,M);M+=4;O.aya=g(U,M);M+=4;O.a8V=g(U,M);
M+=4;M+=4;O.duration=g(U,M);M+=4;M+=8;O.j=k(U,M);M+=2;O.atZ=k(U,M);M+=2;O.volume=k(U,M);M+=2;M+=2;O.aal=n(U,M);
M+=4*9;O.gA=g(U,M)>>>16;M+=4;O.ag=g(U,M)>>>16;M+=4}else if(f=="mdhd"){O.FK=g(U,M);M+=4;O.a0l=g(U,M);
M+=4;O.aya=g(U,M);M+=4;O.MZ=g(U,M);M+=4;O.duration=g(U,M);M+=4;O.lang=k(U,M);M+=2;O.B9=k(U,M);M+=2}else if(f=="hdlr"){var X=g(U,M);
M+=4;if(X!=0)throw X;O.Y3=J.sv(U,M,4);M+=4;O.aev=J.sv(U,M,4);M+=4;O.ajj=g(U,M);M+=4;O.FK=g(U,M);M+=4;
O.ahk=g(U,M);M+=4;var P=M;while(U[P]!=0)P++;O.name=J.sv(U,M,P-M);M+=P-M+1}else if(f=="stsd"){var X=g(U,M);
M+=4;if(X!=0)throw X;var Z=g(U,M);M+=4;if(Z!=1)throw Z;var Y=g(U,M);M+=4;O.M6=J.sv(U,M,4);M+=4;if(O.M6=="mett"){O.apl=J.sv(U,M,z-M)}else{for(var L=0;
L<6;L++)if(U[M+L]!=0)throw"e";M+=6;O.a5O=k(U,M);M+=2;O.au6=k(U,M);M+=2;O.aq7=k(U,M);M+=2;O.aca=g(U,M);
M+=4;if("mp4v avc1 encv s263 vp09 hvc1".split(" ").indexOf(O.M6)!=-1){O.auZ=g(U,M);M+=4;O.avP=g(U,M);
M+=4;O.aos=[k(U,M),k(U,M+2)];M+=4;O.ah5=[g(U,M)/(1<<16),g(U,M+4)/(1<<16)];M+=8;var K=g(U,M);M+=4;if(K!=0)throw"e";
var S=k(U,M);M+=2;if(S!=1)throw"e";var G=U[M];M++;O.auI=J.sv(U,M,G);M+=31;O.a2x=k(U,M);M+=2;var V=k(U,M);
M+=2;if(V!=65535)throw"e";if(M!=z)O.aaF=W(U,M,z,l+1)}else if(["mp4a","enca","samr","sawb","ec-3"].indexOf(O.M6)!=-1){O.yo=k(U,M);
M+=2;O.ao$=k(U,M);M+=2;var T=k(U,M);M+=2;if(T!=0&&T!=65534)throw T;var R=k(U,M);M+=2;if(R!=0)throw R;
O.a79=g(U,M)/(1<<16);M+=4}else if(O.M6=="tx3g"){}else throw O.M6}}else if(f=="stts"||f=="stsz"||f=="stco"||f=="stsc"||f=="ctts"){var X=g(U,M),x=0,N=0;
M+=4;if(X!=0)throw X;if(f=="stsz"){x=g(U,M);M+=4}var v=g(U,M)*(f=="stsc"?3:f=="stts"||f=="ctts"?2:1);
M+=4;O=[];for(var L=0;L<v;L++){if(x!=0)O.push(x);else{O.push(g(U,M));M+=4}}for(var L=0;L<v;L++)N+=O[L]}else if(f=="co64"){var X=g(U,M);
M+=4;if(X!=0)throw X;var v=g(U,M);M+=4;O=[];for(var L=0;L<v;L++){O.push(J.gg(U,M));M+=8}}else if(f=="moov"||f=="trak"||f=="mdia"||f=="minf"||f=="dinf"||f=="stbl"){O=W(U,M,z,l+1)}else{O.R=M;
O.Rf=C}M=z;if(f=="trak"){if(A[f]==null)A[f]=[];A[f].push(O)}else{if(A[f]!=null)throw f;A[f]=O}}return A}function D(U){var M=new Uint8Array(U);
return W(M,0,M.length,0)}function j(U,M,m){var l=I(U,M),A=l.mdia.minf.stbl,g=A.stsc,k=0,$=0;for(var L=0;
L<g.length;L+=3){var C=(L+3<g.length?g[L+3]:1e4)-g[L],f=$+C*g[L+1];if($<=m&&m<f){while($+g[L+1]<=m){k++;
$+=g[L+1]}break}k+=C;$=f}var z=A.stco;if(z==null)z=A.co64;var s=z[k];while($<m){s+=A.stsz[$];$++}return[s,A.stsz[m]]}function I(U,M){var m=U.moov.trak;
for(var L=0;L<m.length;L++)if(m[L].mdia.hdlr.aev==M)return m[L]}return{ew:D,a7B:j,akS:I}}(),y={};y.V=function(w){return window.devicePixelRatio||1};
y.N5=function(w,n){return(n.ag8=="touch"?12:8)*y.V()/w.u.N};y.qw=function(w,n,W){this.name=w;this.id=n;
this.xh=null;if(W!=null)this.GH=W};y.qw.prototype.Al=function(w,n,W,D,j){};y.qw.prototype.enable=function(w,n,W,D,j,I){var U=new ed(b.E.L,!0);
U.data={d:b.c.ph,In:"default"};n.S(U)};y.qw.prototype.disable=function(w,n,W,D,j){};y.qw.prototype.amK=function(w,n,W,D,j){return!1};
y.qw.prototype.WQ=function(w,n,W,D,j){};y.qw.prototype.Eq=function(w,n,W,D,j){};y.qw.prototype.QD=function(w,n,W,D,j){};
y.qw.prototype.H5=function(w,n,W,D,j,I){};y.qw.prototype.cF=function(w,n,W,D,j){};y.qw.prototype.oe=function(w,n,W,D){};
y.qw.prototype.BW=function(w,n,W,D){};y.qw.prototype.Fd=function(w,n){};y.qw.prototype.ZE=function(w,n){};
y.qw.prototype.sm=function(w,n,W,D,j){};y.qw.prototype.GZ=function(w,n){};y.qw.prototype.wO=function(w,n){return!1};
y.qw.prototype.LL=function(w,n){return!1};y.qw.prototype.wb=function(){return!1};y.qw.prototype.Tr=function(w,n){return!0};
y.qw.prototype.Th=function(){return null};y.qw.prototype.QW=function(w,n,W){};y.qw.prototype.age=function(){return!1};
y.qw.prototype.Lp=function(w,n,W,D){};y.qw.prototype.track=function(w){var n=new ed(b.E.W1,!0);n.data=w;
w.Q9=!0;this.xh.S(n)};y.qw.Co=function(w,n,W,D){var j=10*y.V()*(w.ag8=="touch"?2:1),I=w.x+j,U=w.y-j,M=E.f_.BE(n.m,W.hh,D,W.m,!0),m=E.f_.BE(n.n,W.hh,D,W.n,!0);
while(M.length<m.length)M=" "+M;while(M.length>m.length)m=" "+m;y.qw.A1(I,U,[fV.get([12,41]).charAt(0)+": "+M,fV.get([12,42]).charAt(0)+": "+m],W)};
y.qw.A1=function(w,n,W,D){function j(l,f,z,s,O,a){l.beginPath();l.moveTo(f,z+a);l.arcTo(f,z+O,f+a,z+O,a);
l.arcTo(f+s,z+O,f+s,z+O-a,a);l.arcTo(f+s,z,f+s-a,z,a);l.arcTo(f,z,f,z+a,a)}var I=y.V(),U=Math.round,M=U(11*I),m=y.qw.a9R,A=0;
if(m==null)m=y.qw.a9R=document.createElement("canvas");var l=m.getContext("2d");l.font=M+"px monospace";
for(var L=0;L<W.length;L++)A=Math.max(A,l.measureText(W[L]).width);var g=U(A+12*I),k=U((W.length*14+5)*I),$=new iB(w,n-k,g,k);
if(m.width!=g||m.height!=k){m.width=g;m.height=k;l.font=M+"px monospace"}l.clearRect(0,0,g,k);l.fillStyle="rgba(0,0,3,0.8)";
j(l,0,0,g,k,U(4*I));l.fill();l.fillStyle="rgba(255,255,255,1)";for(var L=0;L<W.length;L++)l.fillText(W[L],U(6*I),U((L+1)*13*I));
var C=[l.getImageData(0,0,g,k).data,$.clone()];if(D)D.I.r7=[C];return C};y.qw.a9R=null;y.Rv="0";y.wA="1";
y.a8F="2";y.a8k="3";y.GO="5";y.a4C="6";y.an9="7";y.N4="8";y.Y5="9";y.xA="10";y.r_="11";y.Od="12";y.Xg="13";
y.Ky="14";y.Rp="16";y.Ug="18";y.e$="19";y.FS="20";y.i5="21";y.z$="22";y.zq="23";y.uX="24";y.YL="25";
y.OW="27";y.rU="31";y.RV="32";y.ZI="34";y.afO="35";y.yJ="36";y.w7="37";y.mH="38";y.wD="39";y.NR="40";
y.jG="41";y.ET="42";y.o4="43";y.a76="44";y.Lu="47";y.Kk="48";y.Au="51";y.Kr="52";y.K7="54";y.Ww="55";
y.Eh="56";y.Hw="57";y.dY="58";y.pX="59";y._E="60";y.Nt="61";y.yl="70";y.Sv="100";y.Zt="101";y.uW="102";
y.o0="103";y.gR="120";y.DW="230";y.a3X="231";y.eb="232";y.Yu="233";y.EA="234";y.sT="235";y.q$="236";
y.apO=function(w){var n=y.l5,W=null;for(var D in n)if(n[D][1].indexOf(w[1].classID)!=-1)W=D;return W};
y.l5={};y.l5[y.zq]=["tools/brush",["PbTl"]];y.l5[y.uX]=["tools/pencil",["PcTl"]];y.l5[y.rU]=["tools/eraser",["ErTl"]];
y.JT=function(w,n,W){y.qw.call(this,w,n,W);this.RQ={brush:w?bj.os():null,bmode:"norm",opacity:1,flow:1,smth:0,samp:0,emode:0,wconf:[40,!0,!0],sall:!1,algnd:!1,sfrom:0,alt:[!1],expo:.5,rng:1,strn:.5,pdetail:!0,smode:1,qsmode:0,setop:0,patch:0};
this.ww=null;this.rN=null;this.hV=null;this.XV=null;this.hy=null;this.Qt=null;this.$w=null;this.ma=null;
this.HJ=null;this.oJ=null;this.A$=null;this.Dx=null;this.Py=null;this.M5=1;this.TC=!1;this.X1=null;this.caller=null};
y.JT.prototype=new y.qw;y.JT.prototype.LL=function(w,n){return w.WS&&n.U(aK.WO)};y.JT.prototype.Eq=function(w,n,W,D,j){if(D.U(aK.PJ)){this.Qt=new ec(j.x,j.y);
var I=this.RQ.brush.Brsh.v,U=I.Dmtr.v.val,M=I.Hrdn!=null?I.Hrdn.v.val:-1;this.$w=[U,M,!0,JSON.parse(JSON.stringify(this.RQ.brush)),j];
this.eg(W)}};y.JT.prototype.$X=function(w,n,W){var D=this.$w,j=w.u.N,I=W.x-D[4].x,U=W.y-D[4].y,M=D[0],m=D[1],l=Math.abs(I)>Math.abs(U);
if(l&&D[2]){var A=Math.round(2*I/j);M+=A;W.x-=I-.5*A*j}if(!l&&!D[2]&&m!=-1){var A=Math.round(.25*U);
m+=A;W.y-=U-4*A}M=Math.max(1,M);m=D[1]==-1?-1:Math.max(0,Math.min(100,m));var g=D[3];g.Brsh.v.Dmtr.v.val=M;
if(m!=-1)g.Brsh.v.Hrdn.v.val=m;this.$w=[M,m,l,g,W];var k=iV.d9(g,n.t$.yg,j),$=k[1];$.x=Math.round(this.Qt.x-$.m/2);
$.y=Math.round(this.Qt.y-$.n/2);w.I.pb=[k];var C=w.u.Cg(this.Qt.x,this.Qt.y);w.I.TH={yi:[],eF:[C.x-M/2,C.y,C.x+M/2,C.y]};
if(m!=-1)w.I.TH.eF.push(C.x+50/j,C.y-m/2,C.x+50/j,C.y+m/2);w.RP=!0};y.JT.prototype.cF=function(w,n,W,D,j){if(this.id==y.FS||this.id==y.i5)return;
if(this.Qt){this.Qt=null;this.YN(JSON.parse(JSON.stringify(this.$w[3])));w.I.pb=[];w.I.TH=null;w.RP=!0;
return}var I=new ed(b.E.L,!0);I.data={d:b.c.Bg,G:this.id,akT:"showBrushOpts",Sd:new ec(j.Qc+4,j.tc)};
n.S(I)};y.JT.prototype.YN=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.oj,AH:bk.ef,UT:w};this.caller.S(n)};
y.JT.YE=function(w,n,W,D,j,I){if(w==null)w="FrgC";if(n==null)n="norm";if(W==null)W=1;if(j==null)j=!1;
var U={classID:"Fl",Usng:{t:"enum",v:{FlCn:w}},Opct:{t:"UntF",v:{type:"#Prc",val:Math.round(W*100)}},PrsT:{t:"bool",v:j},Md:{t:"enum",v:{BlnM:dD.Eu(n)}}};
if(w=="Clr")U.Clr={t:"Objc",v:D};if(w=="contentAware")U.contentAwareColorAdaptationFill={t:"bool",v:!0};
if(w=="Ptrn")U.Ptrn={t:"Objc",v:I};return{hZ:"fill",E3:U}};y.JT.prototype.Al=function(w,n,W,D,j){this.xh=n;
var I=W.v9.length;if(I==0&&!W.d2())return;var U=I!=0?-1-W.v9[0]:W.g[0],M=W.C[U];if(w.d=="fromAction"){var m=w.bs,l=m.E3;
if(l&&l.null&&l.null.v[0]&&l.null.v[0].v.classID=="Path"){var A=W.OV(),g=A[0],k=A[1],$=g[k.length==0?0:k[0]].add.vmsk;
if(m.hZ=="fill"){var C=$._N(),f=j.Gp,z=this.RQ,s=f>>16&255,O=f>>8&255,a=f>>0&255;this.gn(W,M,C,s,O,a,Math.round(z.opacity*255),z.bmode,"Fill Path")}else{for(var X=0;
X<1e3;X++){var P=E.P.tt($.i,X,!0);if(P==-1){this.H5(W,n,j,D,null);break}var Z=$.i[P],Y=$.i.slice(P,P+1+Z.length),K=E.p.xH(Y,!0).w,S=K.slice(0,8);
for(var G=8;G<K.length;G+=6)S.push(K[G-2],K[G-1],K[G],K[G+1],K[G+2],K[G+3],K[G+4],K[G+5]);var V={};V.Points=S;
V.TextOnPathTRange=$.H3.slice(0);var V=d2.AL(V,2,Z.type==3),T=V[0];if(X==0)this.WQ(W,n,j,D,W.u.m9(T[0],T[1]));
else this.rN.moveTo(T[0],T[1]);var R=T.length,x=Z.type==0?R+2:R;for(var L=2;L<x;L+=2){var v=W.u.m9(T[L%R],T[(L+1)%R]);
v.WS=!0;this.QD(W,n,j,D,v,this.RQ.flow)}this.rN.finish();this.kC(W)}}}else if(m.hZ=="fill"){var N=l.PrsT?l.PrsT.v:!1,u=M?M.add.lspf:0;
if(N&&M){M.add.lspf=u==null?1:u|1}var H=(l.Opct?l.Opct.v.val:100)/100,F=l.Md?dD.XK(l.Md.v.BlnM):"norm",t=l.Usng.v.FlCn;
if(t=="contentAware"){if(W.J==null){alert("Select an area to heal first.");return}if(!W.d2())return;
this.W5(W);this.R9(W,0);var o=W.J,q=E.Q(o.rect.O()*4);E.IL(o.channel,q,3);this.X_(W,"sheal",q,o.rect,o.rect);
this.l(W,o.rect);this.finish(W,o.rect)}else if(t=="Ptrn"){var _=j.V8,d=W.J?W.J.rect.clone():new iB(0,0,W.m,W.n),r=E.Q(d.O()*4);
ge.GP(l,r,d,_,new ec(0,0));this.Qq(W,M,W.J,r,"norm",[6,48,0,2])}else{var f;if(t=="FrgC")f=j.Gp;else if(t=="BckC")f=j.as;
else if(t=="Blck")f=0;else if(t=="Wht")f=16777215;else if(t=="Gry")f=8421504;else if(t=="Clr"){var p=E.M.y_(l.Clr.v);
f=p.o<<16|p.B<<8|p.k}var s=f>>16&255,O=f>>8&255,a=f>>0&255;this.gn(W,M,W.J,s,O,a,Math.round(255*H),F,[2,3])}if(N&&M){M.add.lspf=u==null?0:u}}else if(m.hZ=="delete"){var Q=U<0?1:M.eL,o=W.J,h2;
if(o==null)return;var B=U<0?W.yo[-U-1]:Q<=0?null:Q==1?M._N():M.NP(W).z,d=Q<=0?M.rect:B.rect,i=Q<=0?o.rect.wU(d):o.rect.clone();
if(i.VY())return;var c=i.O();if(Q<=0){h2=E.Q(c*4);E.Cb(M.buffer,M.rect,h2,i)}else{h2=E.Q(c);B.extend(i);
E.B0(B.channel,B.rect,h2,i)}if(0<=U&&M.er(W,o)){if(Q<=0){E.cJ(h2,0);E.Cb(M.zZ.H8,M.zZ.Ox,h2,i)}else{h2.fill(255);
E.B0(M.zZ.H8,M.zZ.Ox,h2,i)}}else{if(Q<=0){var jX=E.Q(h2.length>>2);E.hN(h2,jX,3);E.s.gZ(E.LR(o.rect.O()),o.rect,jX,i,o.channel,i,1);
E.IL(jX,h2,3)}else{var bm=E.Q(o.rect.O()),s=j.as>>>16&255,O=j.as>>8&255,a=j.as>>0&255;bm.fill(Math.round(E.g7(s,O,a)));
E.s.gZ(bm,o.rect,h2,i,o.channel,i,1)}}this.Jl(W,!0,[2,2],U,Q,i,h2)}}if(w.d=="stroke"){var dC=w.auv,o=W.J;
if(o==null){o={rect:M.rect.clone(),channel:E.Q(M.rect.O())};E.hN(M.buffer,o.channel,3)}var fn=ge.i7(dC),fK=y.eZ.ac1(o,Math.ceil(fn[0]),Math.ceil(fn[1])),f=E.M.y_(dC.Clr.v),s=Math.round(f.o),O=Math.round(f.B),a=Math.round(f.k);
this.gn(W,M,fK,s,O,a,Math.round(255*dC.Opct.v.val/100),dD.XK(dC.Md.v.BlnM),[14,9])}if(w.d=="fillBMP"){this.Qq(W,M,W.J,w.rY,w.ZA,w.s7)}if(w.d=="draw"){var i6=w.qH,dh=i6.rect;
this.W5(W);var kA=W.C[W.g[0]];if(w.ake&&kA&&kA.eL<=0&&W.v9.length==0){dh=y.G$.a5H(i6,W);kA.buffer=i6.buffer.slice(0);
kA.rect=dh.clone()}else{var ig=this.RQ.bmode;this.RQ.bmode="norm";this.X_(W,"draw",i6.buffer,dh,dh.wU(new iB(0,0,W.m,W.n)));
this.RQ.bmode=ig}this.l(W,dh);W.rR=!0;this.finish(W,dh,w.s7,w.ake)}};y.JT.prototype.gn=function(w,n,W,D,j,I,U,M,m){var l=W==null?new iB(0,0,w.m,w.n):W.rect,A=U<<24|I<<16|j<<8|D<<0,g=E.Q(l.O()*4);
E.cJ(g,A);this.Qq(w,n,W,g,M,m)};y.JT.prototype.Qq=function(w,n,W,D,j,I){var U=w.v9.length!=0?-1-w.v9[0]:w.g[0],M=U<0?1:n.eL,m=U<0?w.yo[-1-U]:M<=0?null:M==1?n._N():n.NP(w).z,l=M<=0?n.rect:m.rect,A=W==null?new iB(0,0,w.m,w.n):W.rect,g=W==null?E.PL(w.m*w.n):W.channel;
if(W!=null)E.py(g,D);var k=A.O(),$=E.Q(k*4);if(M<=0)E.Cb(n.buffer,n.rect,$,A);else{m.extend(A);$.fill(255);
E.Mj(m.Tt(A),$)}if(0<=U&&W&&n.er(w,W)&&M<=0){var C=n.zZ.WL,f=n.zZ.WL.slice(0);if(M<=0)E.nX(D,f);else E.nX(fullc,f);
var z=new go([2,3],this);z.data={d:"drawtemp",j:w.g[0],vi:M,af9:C,aoi:f};w.kK(z);this.Fd(z.data,w)}else{if(M<=0){var s;
if(n.m7(0)){s=E.Q(A.O());E.hN($,s,3)}E.s._U(j,D,A,$,A,A,1);if(n.m7(0))E.IL(s,$,3)}else{E.s._U(j,D,A,$,A,A,1);
var O=E.Q(k);E.fo($,O);$=O}this.Jl(w,!0,I,U,M,A,$)}};y.JT.prototype.wO=function(w){if(aK.xL.indexOf(w)!=-1)return!0;
return!1};y.JT.prototype.oe=function(w,n,W,D){var j=this.RQ.brush,I=D.U(aK.PJ),U=I!=this.TC,M=y.JT.u_(j,D);
if(M!=null)this.YN(M);if(!D.U(aK.CQ)&&D.$N()!=-1){var m=aK.Af(Math.round(this.RQ.opacity*100),D.$N())/100;
this.qG({opacity:m},n)}if(this.id==y.N4&&U&&w!=null){var l=this.RQ.qsmode;if(l==2)l=w.J==null?0:1;else l=2;
this.qG({qsmode:l},n)}this.TC=I;if(U){if(w)this.M5=w.u.N;this.eg(W,D)}};y.JT.u_=function(w,n){var W=w.Brsh.v.Dmtr.v.val,D=w.Brsh.v.Hrdn!=null?w.Brsh.v.Hrdn.v.val:-1,j=W,I=D,U=n.U(aK.WO);
if(n.U(aK.yq)){if(U)D=25*Math.floor((D-1)/25);else{if(W<=10)W--;else if(W<=50)W=5*Math.floor((W-1)/5);
else if(W<=100)W=10*Math.floor((W-1)/10);else if(W<=200)W=25*Math.floor((W-1)/25);else if(W<=400)W=50*Math.floor((W-1)/50);
else W=100*Math.floor((W-1)/100)}}if(n.U(aK.vs)){if(U)D=25*Math.ceil((D+1)/25);else{if(W<10)W++;else if(W<50)W=5*Math.ceil((W+1)/5);
else if(W<100)W=10*Math.ceil((W+1)/10);else if(W<200)W=25*Math.ceil((W+1)/25);else if(W<400)W=50*Math.ceil((W+1)/50);
else W=100*Math.ceil((W+1)/100)}}W=Math.max(1,W);D=Math.max(0,Math.min(100,D));if(I==-1)D=-1;if(W!=j||D!=I){var M=JSON.parse(JSON.stringify(w));
M.Brsh.v.Dmtr.v.val=W;if(I!=-1)M.Brsh.v.Hrdn.v.val=D;return M}return null};y.JT.prototype.eg=function(w,n,W,D){if(w.t$.list.length==0)return;
var j=this.id,I;if((j==y.OW||j==y.e$||j==y.zq||j==y.uX)&&(n!=null&&n.U(aK.PJ)||this.RQ.alt[0]))I="crosshair";
else{var U=this.M5,M=this.RQ.brush;if((j==y.OW||j==y.e$)&&W&&this.Dx&&this.Dx.length==this.A$.O()*4){var m=W.u.Cg(D.x,D.y),l=this.amE(m),A=this.Dx,g=this.A$,k=new iB(g.x+l.x,g.y+l.y,g.m,g.n),$=iV.d9(M,w.t$.yg,U),C=$[0],f=$[1],z=Math.ceil(f.m/U),s=new iB(Math.round(m.x-z/2),Math.round(m.y-z/2),z,z),O=E.Q(s.O()*4),a,X;
E.Cb(A,k,O,s);if(U==1){a=O;X=s}else{var P=new eh(U,0,0,U,0,0),Z=y.wR.lD([O,s],P,!0);X=f.clone();X.x=Z.rect.x;
X.y=Z.rect.y;if(X.s9(Z.rect))a=Z.buffer;else{a=E.Q(X.O()*4);E.Cb(Z.buffer,Z.rect,a,X)}}var Y=this.RQ.opacity/255;
for(var L=0;L<a.length;L+=4)a[L+3]=Y*(C[L+3]*a[L+3]);iV.ayH(new Uint32Array(a.buffer),X,4278190080,4294967295);
I={p0:a,WH:X,Q5:new ec(X.m/2,X.n/2)}}else I=iV.QM(M,w.t$.yg,U,j==y.YL||j==y.RV)}var K=new ed(b.E.L,!0);
K.data={d:b.c.ph,In:I};if(this.caller)this.caller.S(K)};y.JT.prototype.enable=function(w,n,W,D){this.ww=W;
this.caller=n;this.YN(JSON.parse(JSON.stringify(this.RQ.brush)));if(w&&w.u.N!=0)this.M5=w.u.N;this.eg(W,D)};
y.JT.prototype.GZ=function(w,n){if(n==bk.ef){this.RQ.brush=w.t$.lH;this.eg(w)}};y.JT.prototype.sm=function(w,n,W,D,j){for(var I in w)this.RQ[I]=w[I];
if(this.RQ.alt[0])this.eg(j,D,W)};y.JT.prototype.aoX=function(w){var n=w.v9.length!=0?-1-w.v9[0]:w.g[0],W=w.C[n],D=n<0?1:W.eL,j=n<0?w.yo[-n-1]:D<=0?null:D==1?W._N():W.NP(w).z,I=j?j.channel:W.buffer,U=(j?j.rect:W.rect).clone();
return[W,D,j,I,U]};y.JT.prototype.W5=function(w,n){this.Py=w.J==null?null:{rect:w.J.rect.clone(),channel:w.J.channel.slice(0)};
var W=this.oJ,D=this.aoX(w),j=D[0],I=D[1],U=D[2];this.oJ=D[3];this.HJ=D[4];var M=new iB(0,0,w.m,w.n),m=M.x0(this.HJ);
if((this.S0()&&I<=0||m.s9(this.HJ))&&n!=!0){if(W&&W.length==this.oJ.length){W.set(this.oJ);this.oJ=W}else this.oJ=this.oJ.slice(0)}else{if(U)U.extend(m);
else j.extend(m)}};y.JT.prototype.R9=function(w,n){var W=this.aoX(w),D=W[1],j=W[3],I=W[4],U=[j,I],M=n!=null?n:this.RQ.sfrom;
if(D<=0&&M!=0){U[1]=new iB(0,0,w.m,w.n);U[0]=w.Vc(M==1&&w.g[0]!=w.C.length-1?w.g[0]:null).slice(0)}this.A$=U[1].clone();
this.Dx=U[0].slice(0)};y.JT.prototype.rG=function(w,n,W){if(w.U(aK.PJ)){var D=new ed(b.E.v,!0);D.G=y.Ky;
D.data={d:"pickhere",axb:W};n.S(D);return!0}return!1};y.JT.prototype.jM=function(w,n,W,D,j,I){if(this.id!=y.N4&&!w.d2(this.caller)){this.rN=null;
return}if(this.id!=y.N4&&this.rN)return;this.W5(w);var U=new iB(0,0,w.m,w.n),M=null;if(I!=null){var m=w.v9.length!=0?-1-w.v9[0]:w.g[0],l=w.C[m],A=m<0?w.yo[-m-1]:l.eL<=0?null:l.eL==1?l._N():l.NP(w).z;
M=E.Q(U.O()*4);if(A)y.JT.gv(this.oJ,this.HJ,A.color,M,U);else E.Cb(this.oJ,this.HJ,M,U)}var g=this.RQ;
if(this.rN&&this.id==y.N4&&g.qsmode!=0&&w.J!=null){}else{var k=n.Gp,$=n.as;if(this.X1=="erase"){var C=k;
k=$;$=C}var f=this.id==y.N4?this.HJ:U;this.rN=new iV(g.brush,n.t$.yg,n.t$.j6,{Z8:j,gQ:I,a9m:g.smth*50/w.u.N,dE:this.id==y.uX||g.emode==1,v_:w.v_},k,$,f,M)}if(this.id==y.N4){this.rN.alj(g.brush,g.qsmode==2?0:16777215)}var z=w.u.Cg(D.x,D.y);
if(W.U(aK.WO)&&this.hV){var s=this.hV;this.rN.moveTo(s.x,s.y,D.MJ);this.rN.lineTo(.001*s.x+.999*z.x,.001*s.y+.999*z.y,D.MJ);
this.rN.lineTo(z.x,z.y,D.MJ)}else this.rN.moveTo(z.x,z.y,D.MJ);this.hV=z;this.XV=z.clone();this.hy=new h3(z,w.u.Tg)};
y.JT.prototype.ez=function(w,n,W){if(w&&w.u.N!=0&&w.u.N!=this.M5){this.M5=w.u.N;this.eg(W)}};y.JT.prototype.WD=function(w,n,W,D){if(this.rN==null)return;
var j=w.C[w.g[0]],I=w.u.Cg(D.x,D.y),U=this.hy.db(I,W);if(U.s9(this.hV))return 1;this.rN.lineTo(U.x,U.y,D.MJ);
this.hV=U;if(this.id==y.OW||this.id==y.e$){var M=this.bO(),m=11;M=w.u.m9(I.x-M.x,I.y-M.y);var l=m>>>1,A=new iB(Math.round(M.x)-l,Math.round(M.y)-l,m,m),g=E.Q(A.O()*4);
E.cJ(16777215);for(var L=0;L<m;L++)g[(L*m+l)*4+3]=g[(m*l+L)*4+3]=255;w.I.r7=[[g,A]];w.RP=!0}};y.JT.prototype.BW=function(w,n,W,D){if(W.No!=this.id)return;
if(this.id!=y.N4||w==null)return;if(w.J==null||w.g[0]!=this.a09){this.a09=w.g[0];this.qG({qsmode:0},n)}};
y.JT.prototype.l=function(w,n){if(w.v9.length!=0){w.RP=!0;return}var W=w.C[w.g[0]];if(n==null){n=this.rN.iO();
if(this.S0()&&W.eL<=0)n=n.wU(this.HJ)}var D=W.eL;if(D==1||D==3){var j=Math.round((D==1?W._N():W.NP(w).z).C3*2.4);
n=n.clone();n.VD(j,j)}if(n.VY())return;if(D<=0){W.l(n)}if(D==1){W._N().eP=!0;W.yb(w,n)}if(D==3){W.l(n)}w.l(w.root.a7(n,w,w.g[0],!0))};
y.JT.prototype.H5=function(w,n,W,D,j){if(this.rN==null)return;this.rN.finish();if(this.id!=y.Ug&&this.id!=y.e$&&this.id!=y.N4)this.kC(w);
if(this.id==y.OW||this.id==y.e$){w.I.r7=[];w.RP=!0}if(this.id==y.N4){var I=w.J;w.J=this.Py;var U=new ed(b.E.v,!0);
U.data={d:"setsel",s7:this.name,J:I};U.G=y.wA;n.S(U);if(this.RQ.qsmode==0)this.qG({qsmode:1},n)}else{this.finish(w,this.rN.oi());
this.rN=null;this.ma=null}this.dir=0};y.JT.prototype.qG=function(w,n){for(var W in w)this.RQ[W]=w[W];
var D=new ed(b.E.L,!0);D.data={d:b.c.Bg,G:this.id,EK:w};n.S(D)};y.JT.prototype.S0=function(){var w=this.id;
return w==y.N4||w==y.rU||w==y.wD||w==y.NR||w==y.jG||w==y.z$};y.JT.prototype.finish=function(w,n,W,D,j){var I=w.v9.length!=0?-1-w.v9[0]:w.g[0],U=w.C[I],M=I<0?1:U.eL,m=I<0?w.yo[-I-1]:M<=0?null:M==1?U._N():U.NP(w).z,l=m?m.rect:U.rect,k;
if(this.S0()||!l.s9(this.HJ)){if(m==null){if(this.S0())U.ky();else{var A=n.x0(this.HJ),g=E.Q(A.O()*4);
E.Cb(U.buffer,U.rect,g,A);U.buffer=g;U.rect=A}}else m.ky();this.l(w,l)}if(M<=0){k=E.Q(n.O()*4);E.Cb(this.oJ,this.HJ,k,n)}else{k=E.Q(n.O());
k.fill(m.color);E.B0(this.oJ,this.HJ,k,n)}this.Jl(w,!1,W?W:this.name,I,M,n,k,D,j)};y.JT.prototype.Jl=function(w,n,W,D,j,I,U,M,m){var l=U;
if(j>0){l=E.Q(I.O()*4);y.JT.gv(U,I,0,l,I)}var A=new go(W,this);A.data=[{j:D,vi:j,WH:I,Ey:l}];if(M)A.data.w0=[w.J,null];
if(m)A.data.w0=[this.Py,w.J];w.kK(A);if(n)this.Fd(A.data,w);else if(M)w.J=null;y.CY.a8A(w,A.data)};y.JT.prototype.ZE=function(w,n){this.a32(w,n,!1)};
y.JT.prototype.Fd=function(w,n){this.a32(w,n,!0)};y.JT.prototype.a32=function(w,n,W){if(w.d=="drawtemp"){var D=W?w.aoi:w.af9,j=n.C[w.j];
j.zZ.WL=D;j.p9(n,0,0,n.J);j.l();n.rR=!0}else{y.CY.Ek(n,w);if(w.w0){n.J=w.w0[W?1:0];n.Iq=!0}}n.l()};y.JT.prototype.kC=function(w){this.X_(w,this.X1,this.rN._a(),this.rN.pJ(),this.rN.iO());
this.l(w)};y.JT.prototype.X_=function(w,n,W,D,j){var I=this.RQ,U=w.C[w.g[0]],M=w.v9.length!=0?w.yo[w.v9[0]]:U.eL<=0?null:U.eL==1?U._N():U.NP(w).z,m=E.Q(j.O()*4),l,A=U.m7(0);
if(M==null){if(this.id==y.i5&&n=="heal")E.Cb(U.buffer,U.rect,m,j);else E.Cb(this.oJ,this.HJ,m,j);if(A){l=E.Q(j.O());
E.hN(m,l,3)}}else{y.JT.gv(this.oJ,this.HJ,M.color,m,j)}if(w.J&&n!="qselect"){var g=j.wU(w.J.rect),k=E.Q(g.O()*4);
if(n=="copy"){var $=E.Q(g.O());E.B0(w.J.channel,w.J.rect,$,g);E.Cb(m,j,k,g);E.s.eY(W,D,k,g,$,g,0,g,1,!1)}else{E.Cb(W,D,k,g);
E.AG(w.J.channel,w.J.rect,k,g)}W=k;D=g}function C(s,dh){var ig=Math.max(dh.x,Math.min(dh.x+dh.m-1,s.x)),iJ=Math.max(dh.y,Math.min(dh.y+dh.n-1,s.y));
return new ec(ig,iJ)}if(n=="idraw"||n=="ierase"){if(this.ma==null)this.ma=E.Q(this.HJ.O());var f=this.RQ.samp,z=this.ww.as,s=C(this.hV,j),O=f==0?s:this.XV,a=O.x,X=O.y,P=y.KF.Kt(this.oJ,this.HJ,[O,new ec(a-2,X),new ec(a+2,X),new ec(a,X-2),new ec(a,X+2)]);
if(f==2)P=[[z>>>16&255,z>>>8&255,z>>>0&255,255]];var Z=y.KF.Yi(m,j,s,P,this.RQ.wconf),Y=E.Q(j.O());E.B0(this.ma,this.HJ,Y,j);
E.nj.x0(Z,Y,Y);E.B0(Y,j,this.ma,this.HJ);E.AG(Y,j,W,D);n=n.slice(1)}if(n=="erase"&&(y.CY.a0U(w)!=16777215||M))n="draw";
if(n=="draw")E.s._U(I.bmode,W,D,m,j,j,I.opacity);else if(n=="erase"){var K=E.Q(j.O()*4);E.Cb(W,D,K,j);
if(M==null){var S=E.Q(j.O());E.hN(K,S,3);E.D9(S,I.opacity);E.Ba(S);E.AG(S,j,m,j)}else{E.cJ(K,0,4278190080);
E.s._U("norm",K,j,m,j,j,I.opacity)}}else if(n=="clone"||n=="heal"){var G=this.bO(),V=this.A$.clone();
V.offset(G.x,G.y);var T=j.clone();T.VD(1,1);var R=E.Q(T.O()*4),x=E.Q(T.O());E.Cb(W,D,R,T);E.hN(R,x,3);
E.cJ(R,0);if(M==null){E.Cb(this.Dx,V,R,T);var v=E.Q(T.O());E.hN(R,v,3);E.w5(v,x)}else y.JT.gv(this.Dx,V,M.color,R,T);
if(n=="clone"){E.IL(x,R,3);E.s._U(I.bmode,R,T,m,j,j,I.opacity)}if(n=="heal"){var N=x.slice(0);E.round(N,20);
var u=E.Q(T.O()*4);if(M==null)E.Cb(this.oJ,this.HJ,u,T);else y.JT.gv(this.oJ,this.HJ,M.color,u,T);E.s.eY(R,T,u,T,N,T,0,T,1,!1);
E.PZ.ay(u,N,T);E.s.eY(u,T,m,j,x,T,0,j,1,!1)}}else if(n=="dodge"||n=="burn"){var R=E.Q(j.O()*4),t=1,o=0,q=0,_=0;
E.Cb(W,D,R,j);var H=j.O()*4,F=y.JT.yS;if(this.TC){if(n=="dodge")n="burn";else n="dodge"}var d=I.rng;
if(n=="dodge"){o=[1-t/2,1,1+t][d];q=[1,1/(1+t),1][d];_=[t/2,0,0][d]}if(n=="burn"){o=[1/(1-t/2),1,1-t/2][d];
q=[1,1+t,1][d];_=[-(t/2)/(1-t/2),0,0][d]}for(var L=0;L<H;L+=4){var r=R[L+3];m[L+0]=F(m[L+0],o,q,_,r);
m[L+1]=F(m[L+1],o,q,_,r);m[L+2]=F(m[L+2],o,q,_,r)}}else if(n=="sponge"||n=="redeye"){var R=E.Q(j.O()*4),x=E.Q(j.O());
E.Cb(W,D,R,j);E.hN(R,x,3);E.nX(m,R);var p=I.smode;if(this.TC)p=1-p;var Q=cx._1("hue2");if(n=="sponge")cT.nr(Q,0,[0,[-50,46][p],[6,5][p]]);
else cT.nr(Q,1,{k0:[265,305,25,55],Lh:[0,-90,-70]});var B=eH.rw("hue2",Q);eH.Ld(B,R,R,j);E.s.eY(R,j,m,j,x,j,0,j,1,!1)}else if(n=="copy")E.Cb(W,D,m,j);
else if(n=="sheal"){var R=E.Q(j.O()*4),x=E.Q(j.O());E.Cb(W,D,R,j);E.hN(R,x,3);R.fill(0);var i=this.Dx,c=this.A$;
if(M){i=E.Q(c.O()*4);y.JT.gv(this.Dx,c,0,i,c)}var h2=E.jK.ay(i,c,x,R,j);if(h2!=0)E.Cb(i,c,R,j);if(this.RQ.sfrom==0)E.Cb(R,j,m,j);
else{E.Cb(this.oJ,this.HJ,m,j);E.IL(x,R,3);E.s._U("norm",R,j,m,j,j,1)}}else if(n=="qselect"){var jX=this.HJ,bm=jX.m,dC=jX.n,fn=bm*dC,fK=this.rN._a(),P=this.oJ,i6=y.eZ.bV,x=i6.mB;
x.fill(128);for(var L=0;L<fn;L++){var dh=fK[L<<2],kA=fK[(L<<2)+3];if(kA==255&&(dh==0||dh==255))x[L]=dh}x[0]=x[bm-1]=0;
x[(dC>>>1)*bm]=x[(dC>>>1)*bm+bm-1]=0;y.fc.so(i6,!0);w.J={rect:jX,channel:i6.J.slice(0)};w.Iq=!0}if(M==null){if(A)E.IL(l,m,3);
E.Cb(m,j,U.buffer,U.rect)}else y.JT.au(m,j,M)};y.JT.bO=function(){return null};y.JT.yS=function(w,n,W,D,j){var I=w*(1/255),U=D+n*Math.pow(I,W),M=Math.round(U*j+I*(255-j));
return Math.max(0,Math.min(255,M))};y.JT.gv=function(w,n,W,D,j){var I=E.Q(j.O());I.fill(W);E.B0(w,n,I,j);
D.fill(255);E.Mj(I,D)};y.JT.au=function(w,n,W){var D=E.Q(n.O());E.fo(w,D);E.B0(D,n,W.channel,W.rect)};
y.eZ=function(w,n,W){y.qw.call(this,w,n,W);this.RQ={binop:0,feat:0,cstr:{ib:0,x:3,y:2},wconf:[16,!0,!0],anta:!0,sall:!1};
this.gs=new ec(-1,-1);this.Gs=new ec(-1,-1);this.t1="default";this.xh=null;this.xs=!1;this.Y7=new hY;
this.nM=!1;this.Tn=null;this.NN=null;this.QH=!1;this.kq=!1};y.eZ.prototype=new y.qw;y.eZ.prototype.axk=function(){var w=this.RQ,n=[w.binop,w.feat];
if(this.id==y.Y5)n.push(w.wconf);return n};y.eZ.prototype.ark=function(w,n,W){var D=this.RQ;D.binop=w[0];
D.feat=w[1];D.wconf=w[2];this.ts(W)};y.eZ.prototype.ts=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.Bg,G:this.id,RQ:this.RQ};
w.S(n)};y.eZ.bV={key:""};y.eZ.SH=function(w,n,W){var D={hZ:w,E3:{classID:"setd",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]}}};
if(n)D.E3.T=n;if(W!=null)D.E3.AntA={t:"bool",v:W};return D};y.eZ.Pd=function(w,n,W){return y.eZ.SH("set",{t:"Objc",v:{classID:w,Top:{t:"UntF",v:{type:"#Pxl",val:n.y}},Left:{t:"UntF",v:{type:"#Pxl",val:n.x}},Btom:{t:"UntF",v:{type:"#Pxl",val:n.y+n.n}},Rght:{t:"UntF",v:{type:"#Pxl",val:n.x+n.m}}}},W)};
y.eZ.KI=function(w,n,W){var D=[],j=[],U="set";for(var L=0;L<w.length;L+=2){D.push(w[L]);j.push(w[L+1])}var I={t:"Objc",v:{classID:"Plgn",Pts:{t:"ObAr",v:{classID:"Pnt",arr:[{id:"Hrzn",type:"UnFl",uID:"#Pxl",arr:D},{id:"Vrtc",type:"UnFl",uID:"#Pxl",arr:j}]}}}};
if(n)U=["set","addTo","subtractFrom","interfaceWhite"][n];return y.eZ.SH(U,I,W)};y.eZ.aba=function(w,n,W){var D={t:"Objc",v:{classID:"Pnt",Hrzn:{t:"UntF",v:{type:"#Pxl",val:w.x}},Vrtc:{t:"UntF",v:{type:"#Pxl",val:w.y}}}},j=y.eZ.SH("set",D);
j.E3.Tlrn={t:"long",v:n[0]};j.E3.AntA={t:"bool",v:n[1]};j.E3.Cntg={t:"bool",v:n[2]};if(W==!0)j.E3.Mrgd={t:"bool",v:W};
return j};y.eZ.Jj=function(w){return y.eZ.SH("set",{t:"enum",v:{Ordn:w?"Al":"None"}})};y.eZ.cp=function(w,n,W){var D={classID:"null"};
if(w!="border")D.selectionModifyEffectAtCanvasBounds={t:"bool",v:W};var j={e:"By",c:"By",b:"Wdth",f:"Rds",s:"Rds"}[w[0]];
D[j]={t:"UntF",v:{type:"#Pxl",val:n}};return{hZ:w,E3:D}};y.eZ.anl=function(w,n,W){var D={t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]},j={t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:n}}]};
if(W)j.v.push({t:"name",v:{classID:"Lyr",val:W}});var I=[{classID:"null",null:D,T:j},{classID:"null",null:j,T:D},{classID:"null",null:j,From:D},{classID:"null",null:j,With:D}],U=["set","add","subtract","interfaceIconFrameDimmed"];
return{hZ:U[w],E3:I[w]}};y.eZ.a4x=function(w,n){var W=new ed(b.E.L,!0);W.data={d:b.c.oj,AH:bk.Xh};if(!n.Ar)w.S(W);
W.data={d:b.c.oj,AH:bk.TK};if(!n.M3.zc)w.S(W)};y.eZ.prototype.Al=function(w,n,W,D,j){y.eZ.a4x(n,j);this.xh=n;
var I=w.d,U,M,m=new iB(0,0,W.m,W.n),g5=!1,jW,eP,b_,fZ;if(I=="fromAction"){var l=w.bs,A=l.hZ,g=l.E3,k=g?g.selectionModifyEffectAtCanvasBounds:null,$=k&&k.v;
if(A=="colorRange"){if(g.Clrs){var C=g.Clrs.v.Clrs,f=0,z=255,s=["Shdw","Mdtn","Hghl"].indexOf(C),P=.4;
if(s==0)z=60;else if(s==1){f=100;z=150}else f=190;var O=["shadows","midtones","highlights"][s],a=g[O+"LowerLimit"],X=g[O+"UpperLimit"];
if(a)f=a.v;if(X)z=X.v;var Z=g[O+"Fuzziness"];if(Z)P=Z.v/100;U=y.eZ.zk(W,f,z,P,!0)}else{var f=g.Mnm.v,z=g.Mxm.v,P;
f={zP:f.Lmnc.v,dl:f.A.v,k:f.B.v};z={zP:z.Lmnc.v,dl:z.A.v,k:z.B.v};P=g.Fzns.v/200;U=y.eZ.zk(W,f,z,P)}M=[7,8]}else if(A=="inverse"){if(W.J==null){alert("No selection!");
return}U={channel:E.Q(m.O()),rect:m};E.B0(W.J.channel,W.J.rect,U.channel,U.rect);E.Ba(U.channel);M=[7,2]}else if(A=="expand"){var Y=g.By.v.val,K=W.J.rect.clone();
K.VD(Y,Y);var S=E.Q(K.O()),G=E.Q(K.O());E.B0(W.J.channel,W.J.rect,G,K);E.style.stroke(G,S,K,Y);U={channel:S,rect:K};
M=[7,4]}else if(A=="contract"){var Y=g.By.v.val,V=W.J.rect.clone();V.VD(1,1);if(!$)V=V.wU(m);var G=E.Q(V.O()),T=E.Q(G.length);
E.B0(W.J.channel,W.J.rect,G,V);E.Ba(G);E.style.stroke(G,T,V,Y);E.Ba(T);U={channel:T,rect:V};E.ky(U);
M=[7,5]}else if(A=="border"){var Y=g.Wdth.v.val;U=y.eZ.ac1(W.J,Y/2,Y/2);M=[7,9]}else if(A=="feather"||A=="smoothness"){var Y=g.Rds.v.val;
U=y.eZ.aaU(W.J,Y,A=="smoothness",m,$);M=A=="feather"?[7,6]:[19,3,0]}else if(A=="move"){var R=g.T.v,K=W.J.rect.clone();
K.x+=R.Hrzn.v.val;K.y+=R.Vrtc.v.val;U={channel:W.J.channel,rect:K};M=[7,7]}else if(A=="grow"||A=="similar"){var x=this.RQ.wconf.slice(0);
if(g.Tlrn)x[0]=g.Tlrn.v;x[2]=A=="grow";var v=W.Vc(),N=new iB(0,0,W.m,W.n),u=W.J.rect,H=Math.round(Math.sqrt(u.O())/10),F=E.Q(N.O());
E.B0(W.J.channel,u,F,N);var t=[];for(var o=0;o<u.n;o+=H)for(var q=(u.O()+o)%H;q<u.m;q+=H)if(W.J.channel[o*u.m+q]==255){var _=new ec(u.x+q,u.y+o);
t.push(_);if(x[2])E.nj.x0(y.KF.Yi(v,N,_,null,x),F,F)}if(!x[2])E.nj.x0(y.KF.Yi(v,N,_,y.KF.Kt(v,N,t),x),F,F);
U={channel:F,rect:N};M=A=="grow"?"Grow Selection":"Similar Selection";console.log(g)}else{var d=g.null.v,r=g.AntA!=null&&g.AntA.v;
function p(aR){var iY=aR.Top.v.val,dr=aR.Left.v.val;return new iB(dr,iY,aR.Rght.v.val-dr,aR.Btom.v.val-iY)}function Q(aR){var iY=aR[0].arr,gy=aR[1].arr,gr={w:[],F:[]};
for(var L=0;L<iY.length;L++){gr.F.push(L==0?"M":"L");gr.w.push(iY[L],gy[L])}gr.F.push("Z");return gr}var B=["set","addTo","subtractFrom","interfaceWhite"].indexOf(A),i=g.T?g.T.v:null;
if(i&&i.classID=="Elps"){U=this.a0t(y.t9.a9U(p(i)));M=[10,4]}else if(i&&i.classID=="Rctn"){var c=p(i);
U={channel:E.Q(c.O()),rect:c.clone()};U.channel.fill(255);M=[10,15]}else if(i&&i.classID=="ObSl"){var c=p(i),h2=y.eZ.bV,jX=h2.rect,bm=h2.mB,dC=jX.m,fn=jX.n,fK=c.x-jX.x,i6=fK+c.m-1,dh=Math.max(fK,Math.min(i6,fK+i6>>>1)),kA=c.y-jX.y,ig=kA+c.n-1,iJ=Math.max(kA,Math.min(ig,kA+ig>>>1)),fL=Math.max(fK,0),fB=Math.min(i6,dC),ah=Math.max(kA,0),eS=Math.min(ig,fn);
bm.fill(128);if(0<=kA)for(var q=fL;q<fB;q++)bm[kA*dC+q]=0;if(ig<fn)for(var q=fL;q<fB;q++)bm[ig*dC+q]=0;
if(0<=fK)for(var o=ah;o<eS;o++)bm[o*dC+fK]=0;if(i6<dC)for(var o=ah;o<eS;o++)bm[o*dC+i6]=0;var gL=y.$W.abQ,e_=Math.round(c.m*gL),c2=Math.round(c.n*gL);
for(var q=Math.max(0,dh-e_);q<Math.min(dC,dh+e_);q++)bm[iJ*dC+q]=255;for(var o=Math.max(0,iJ-c2);o<Math.min(fn,iJ+c2);
o++)bm[o*dC+dh]=255;y.fc.so(h2,!0);U={channel:h2.J.slice(0),rect:jX.clone()};M=[10,44]}else if(i&&i.classID=="Plgn"){U=this.a0t(Q(i.Pts.v.arr));
M=[10,9]}else if(i&&i.classID=="Pnt"){U=y.KF.axY(W,new ec(i.Hrzn.v.val,i.Vrtc.v.val),[g.Tlrn.v,r,g.Cntg==null||g.Cntg.v],g.Mrgd?g.Mrgd.v:!1);
M=[10,12]}else if(i&&i.Ordn=="None"){U=null;M=[7,1]}else if(i&&i.Ordn=="Al"){var jS=m;if(W.g.length!=0){var ie=W.root.fs(W.g[0]);
while(ie.parent&&ie.parent.parent)ie=ie.parent;if(ie.j.add.artb)jS=ie.j.yP()}U={channel:E.Q(jS.O()),rect:jS};
U.channel.fill(255);M=[7,0]}else if(i&&i[0]&&i[0].v.keyID=="WrPt"){var as={d:"frompath",HD:[-1,0,0]};
this.Al(as,n,W,D,j);return}else{var gb=["set","add","subtract","interfaceIconFrameDimmed"].indexOf(A),gx=A=="set"?i:d,eo=gx[0].v.enum,as;
if(eo=="Trsp"||eo=="Msk"||eo=="vectorMask"||eo=="Trgt"){var di=W.g[0];if(gx.length==2)di=cq.zN(W,gx[1]);
var d0=["Trsp","Msk","vectorMask"].indexOf(eo);if(eo=="Trgt"&&W.C[di].eL==1)d0=1;as={d:"fromlayer",HD:[di,d0,gb]}}else{if(gx[0].t=="name"){var di=0;
for(var L=0;L<W.yo.length;L++)if(W.yo[L].name==gx[0].v.val)di=L;as={d:"fromchannel",HD:[-5-di,0,gb]}}else{var e6=["RGB","Rd","Grn","Bl"].indexOf(eo);
as={d:"fromchannel",HD:[-1-e6,0,gb]}}}this.Al(as,n,W,D,j);return}if(U){if(!r)E.round(U.channel);if(g.Fthr)U=y.eZ.aaU(U,g.Fthr.v.val,!1);
if(A!="set"&&W.J!=null)U=E.nj.VP(U,W.J,B)}}if(A=="expand"||A=="contract")if(!$&&!m.contains(U.rect)){var dt=U.rect.wU(m),gJ=E.Q(dt.O());
E.B0(U.channel,U.rect,gJ,dt);U.channel=gJ;U.rect=dt}}if(I=="qmask"){g5=!0;var im=W._A(),N=new iB(0,0,W.m,W.n);
if(im){U=im.rect.s9(N)&&E.em(im.channel,255)?null:{rect:im.rect.clone(),channel:im.channel.slice(0)};
jW=im}else{U=null;eP=new h.ac;eP.color=0;eP.name="Quick Mask";eP.$P=!0;if(W.J){eP.rect=W.J.rect.clone();
eP.channel=W.J.channel.slice(0)}else{eP.rect=N;eP.channel=E.Q(eP.rect.O());eP.channel.fill(255)}}M=[6,6,1];
W.rR=!0}if(I=="setsel"){U=w.J;M=w.s7}if(I=="crange"){var f=w.x8,z=w.wI;U=y.eZ.zk(W,f,z,w.$e);M=[7,8]}if(I=="fromlayer"||I=="fromchannel"||I=="frompath"){var j3=w.HD[0],d0=w.HD[1],B=w.HD[2];
if(I=="fromlayer"){if(j3==null)j3=W.g[0];var dr=W.C[j3];if(d0==0){var c0=dr.rect,fM=dr.buffer;if(c0.VY())return;
var cB=E.Q(fM.length>>>2);E.hN(fM,cB,3);U={channel:cB,rect:c0.clone()}}else{if(dr.z==null)dr.yb(W);var iI=d0==1?dr._N():dr.z;
U=y.eZ.asF(iI,m)}this.track(y.eZ.anl(B,["Trsp","Msk"][d0],dr.getName()))}else if(I=="frompath"){var jD=W.OV(),j8=jD[1],jD=jD[0],bH=!0;
if(j3==null)if(jD.length==0||j8.length==0)return;var jG=jD[j8[0]];if(j3!=null)for(var L=0;L<jD.length;
L++)if(jD[L].p_==j3)jG=jD[L];var iI=jG.add.vmsk._N(),i1=iI.pJ();if(i1.O()==0)return;var cB=iI.Ob();if(w.HD[3]!=null)bH=w.HD[3];
if(!bH){cB=cB.slice(0);E.round(cB)}b_=[JSON.stringify(W.rs),JSON.stringify(W.zS)];fZ=["[]","[]"];W.rs=[];
W.zS=[];U={channel:cB,rect:i1}}else{if(j3==null)j3=y.eZ.ajY(W);U=y.eZ.aaX(W,j3)}if(B!=0&&W.J)U=E.nj.VP(U,W.J,B);
M=[14,11]}if(U!=null&&E.em(U.channel,0)){U=null;M=[7,1]}if(U)E.ky(U);var a_=new go(M,this);a_.data={d:"changesel",Py:W.J,TY:U,_A:g5,ar2:jW,axW:eP,r8:b_,awU:fZ};
W.kK(a_);this.Fd(a_.data,W)};y.eZ.ajY=function(w){var n=0;if(w.v9.length!=0)n=-5-w.v9[0];else if(JSON.stringify(w.u.zC)=="[1,1,1]")n=-1;
else n=-2-w.u.zC.indexOf(1);return n};y.eZ.aaX=function(w,n){var W,D=new iB(0,0,w.m,w.n);if(-5<n&n<0){var j=-n-1,I=w.Vc(),U=E.Q(D.O());
if(j==0)E.fo(I,U);else E.hN(I,U,j-1);W={channel:U,rect:D.clone()}}if(n<-4){W=y.eZ.asF(w.yo[-n-5],D)}return W};
y.eZ.asF=function(w,n){var W,D;if(w.y_()==0){D=w.pJ().clone();if(D.O()==0)return;W=w.Ob()}else{D=n;W=E.Q(D.O());
w.Ln(D,W)}return{channel:W,rect:D}};y.eZ.prototype.LL=function(w){return this.nM||w.WS&&this.id!=y.GO};
y.eZ.prototype.CP=function(w,n,W){var D=new ed(n,!0);D.data=W;w.S(D)};y.eZ.prototype.a0H=function(w,n){var W=new ed(b.E.L,!0);
W.data={d:b.c.ph,In:n};w.S(W)};y.eZ.prototype.pJ=function(w,n,W){n=w.J==null||this.Y7.m$(1)||this.Y7.i6(1)?n:null;
var D=this.gs,j=this.Gs;if(W){D.x=Math.max(0,Math.min(w.m,D.x));D.y=Math.max(0,Math.min(w.n,D.y));j.x=Math.max(0,Math.min(w.m,j.x));
j.y=Math.max(0,Math.min(w.n,j.y))}var I=y.IG.fS(D,j,n,!0,this.RQ.cstr),U=I[0].x,M=I[0].y,m=new iB(U,M,I[1].x-U,I[1].y-M);
if(W){m.x=Math.max(m.x,0);m.y=Math.max(m.y,0)}return m};y.eZ.prototype.WQ=function(w,n,W,D,j){this.kq=!0;
if(this.rT())return;this.xh=n;this.xs=!1;this.Y7.WQ(D);this.gs=w.u.Cg(j.x,j.y);this.gs=y.mU.JW(w,this.gs,W);
if(this.alg(w,this.gs,D)){this.nM=!0;this.Tn=w.J.rect.clone();return}this.jx(w,W,D,j);w.u.Bn=new iB};
y.eZ.prototype.alg=function(w,n,W){var D=W.U(aK.WO),j=W.U(aK.PJ);if(w.J&&!D&&!j&&this.RQ.binop==0)return E.pw(n,w.J.channel,w.J.rect);
return!1};y.eZ.prototype.QD=function(w,n,W,D,j){this.xh=n;if(this.QH)return;var I=w.u.Cg(j.x,j.y);if(ec.cS(this.gs,I)*w.u.N>5){this.xs=!0;
this.Y7.QD()}if(D.U(aK.Xu)){if(this.NN==null)this.NN=new ec(I.x-this.gs.x,I.y-this.gs.y);this.gs.x=I.x-this.NN.x;
this.gs.y=I.y-this.NN.y}else this.NN=null;this.Gs=I;if(!this.nM)this.Gs=y.mU.JW(w,this.Gs,W);if(this.alg(w,this.Gs,D))this.a0H(n,"move");
else this.a0H(n,this.t1);if(this.nM){var U=this.Tn.clone();U.x+=this.Gs.x-this.gs.x;U.y+=this.Gs.y-this.gs.y;
var M=y.mU.uP(w,U,W);w.J.rect.x=Math.round(this.Gs.x-this.gs.x+this.Tn.x+M[0]);w.J.rect.y=Math.round(this.Gs.y-this.gs.y+this.Tn.y+M[1]);
w.Iq=!0;y.mU.Iy(w,U,M);return}this.Gi(w,W,D,j,n);if(w.u.Bn)w.u.Bn=this.pJ(w,D)};y.eZ.prototype.rT=function(){return!1};
y.eZ.prototype.H5=function(w,n,W,D,j,I){var U=this.kq;this.kq=!1;if(I||!U)return;w.u.Bn=null;this.Gs=w.u.Cg(j.x,j.y);
this.Gs=y.mU.JW(w,this.Gs,W);if(this.nM){this.nM=!1;if(w!=null&&w.I.t7){w.I.t7=null;w.RP=!0}if(this.Gs.s9(this.gs)&&this.PC()==0){this.CP(n,b.E.W1,y.eZ.Jj());
return}this.ao8(w,this.Tn,w.J.rect.clone());return}this.WB(w,W,D,j,n);y.eZ.a4x(n,W);this.Y7.H5();this.za(n)};
y.eZ.prototype.ao8=function(w,n,W){var D=w.by();if(D!=null&&D.G==this&&D.data.d=="movesel"){}else{D=new go([7,7],this);
D.data={d:"movesel",G8:n};w.kK(D)}D.data.uU=W;this.Fd(D.data,w)};y.eZ.prototype.Eq=function(w,n,W,D,j){this.QH=!0};
y.eZ.prototype.cF=function(w,n,W,D,j){var I=new ed(b.E.L,!0);I.data={d:b.c.Bg,G:this.id,ao:j,AR:w,Yo:W};
n.S(I);this.QH=!1};y.eZ.prototype.oe=function(w,n,W,D){this.Y7.oe(D);if(w!=null&&w.J!=null){var j=D.aa();
if(j.x!=0||j.y!=0){var I=w.J.rect.clone();I.x+=j.x;I.y+=j.y;this.ao8(w,w.J.rect.clone(),I)}}this.za(n)};
y.eZ.prototype.za=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.Bg,G:this.id,K8:this.PC()};w.S(n)};
y.eZ.prototype.PC=function(){var w=this.Y7.m$(0),n=this.Y7.i6(0);return y.eZ.H9(this.RQ.binop,w,n)};
y.eZ.H9=function(w,n,W){if(n)w=1;if(W)w=2;if(n&&W)w=3;return w};y.eZ.prototype.finish=function(w,n,W,D){var j=w.J,I=this.getSelection(w,n,W,D);
if(I==null)I=y.eZ.Jj();else{var U=this.RQ.feat,M=this.PC();if(U!=0)I.E3.Fthr={t:"UntF",v:{type:"#Pxl",val:U}};
if(M!=0&&M!=4)I.hZ=["","addTo","subtractFrom","interfaceWhite",""][M]}this.CP(this.xh,b.E.W1,I);this.gs.y1(-1,-1);
this.Gs.y1(-1,-1)};y.eZ.prototype.getSelection=function(w,n,W,D){return null};y.eZ.prototype.jx=function(w,n,W,D){};
y.eZ.prototype.Gi=function(w,n,W,D){};y.eZ.prototype.WB=function(w,n,W,D){};y.eZ.prototype.ZE=function(w,n){var W=w.d;
if(W=="changesel")n.J=w.Py;if(W=="movesel")n.J.rect=w.G8;if(w._A){if(w.ar2){n.v9=[n.yo.length];n.yo.push(w.ar2)}else{n.yo.pop();
n.v9=[]}}if(w.r8){n.rs=JSON.parse(w.r8[0]);n.zS=JSON.parse(w.r8[1])}n.Iq=!0};y.eZ.prototype.Fd=function(w,n){var W=w.d;
if(W=="changesel")n.J=w.TY;if(W=="movesel")n.J.rect=w.uU;if(w._A){if(w.axW){n.v9=[n.yo.length];n.yo.push(w.axW)}else{n.yo.pop();
n.v9=[]}}if(w.r8){n.rs=JSON.parse(w.awU[0]);n.zS=JSON.parse(w.awU[1])}n.Iq=!0};y.eZ.prototype.sm=function(w){this.RQ=w.RQ};
y.eZ.prototype.a0t=function(w){var n=E.p.lV(w.w);if(n.VY())return null;var W=E.Om(n.m,n.n);W.save();
W.beginPath();W.translate(-n.x,-n.y);Typr.U.pathToContext({cmds:w.F,crds:w.w},W);W.closePath();W.fill();
W.restore();var D=E.Q(n.O()),j=W.getImageData(0,0,n.m,n.n);E.hN(j.data,D,3);return{rect:n,channel:D}};
y.eZ.aaU=function(w,n,W,D,j){if(W)n=Math.round(n*.7);var I=Math.ceil(2.6*n),U=w.rect.clone();U.VD(I,I);
if(D&&!j)U=U.wU(D);var M=E.Q(U.O()),m=E.Q(M.length);E.B0(w.channel,w.rect,m,U);E.xX.So(m,M,U,n);if(W){var l=M.length;
for(var L=0;L<l;L++){var A=(M[L]-128)*n*2.5;M[L]=Math.max(0,Math.min(255,Math.round(128+A)))}}return{channel:M,rect:U}};
y.eZ.ac1=function(w,n,W){var D=Math.max(1,Math.ceil(W)),j=w.rect.clone();j.VD(D,D);var I=j.O(),U={channel:E.Q(I),rect:j},M=E.Q(I);
E.B0(w.channel,w.rect,M,U.rect);if(W!=0)E.style.stroke(M,U.channel,U.rect,W);else E.nX(M,U.channel);
var m=E.Q(I);E.Ba(M);if(n!=0)E.style.stroke(M,m,U.rect,n);else E.nX(M,m);E.nj.wU(U.channel,m,U.channel);
return U};y.eZ.zk=function(w,n,W,D,j){var I=new iB(0,0,w.m,w.n),U=w.Vc();if(w.J){var M=w.J.rect.wU(I),m=E.Q(M.O()*4);
E.Cb(U,I,m,M);I=M;U=m}var l=I.O(),A=E.Q(l),g=1/D;if(j){if(n>=W)n=W-1;var k=n*(1-D),$=n,C=W,f=W+(255-W)*D,z=k==$?0:1/($-k),s=C==f?0:1/(f-C);
for(var L=0;L<l;L++){var O=L<<2,a=E.g7(U[O],U[O+1],U[O+2]),X=0;if(a<k)X=0;else if(a<$)X=(a-k)*z;else if(a<=C)X=1;
else if(a<=f)X=1-(a-C)*s;else X=0;A[L]=U[O+3]*X*X}}else for(var L=0;L<l;L++){var O=L<<2,P=E.gK(U[O],U[O+1],U[O+2]),X=E.fA(P,n,W,D,g);
A[L]=U[O+3]*X}return{rect:I,channel:A}};y.DU=function(){y.JT.call(this,[10,18],y.yJ,"tools/blur");this.X1="copy"};
y.DU.prototype=new y.JT;y.DU.prototype.WQ=function(w,n,W,D,j){var I=D.U(aK.PJ)?iV.vO:iV.yJ;this.jM(w,W,D,j,this.RQ.strn,I);
if(this.rN==null)return;this.kC(w)};y.DU.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.CN=function(){y.JT.call(this,[10,0],y.zq,"tools/brush");
this.X1="draw"};y.CN.prototype=new y.JT;y.CN.prototype.WQ=function(w,n,W,D,j){if(this.rG(D,n,j))return;
this.jM(w,W,D,j,this.RQ.flow);if(this.rN==null)return;this.kC(w)};y.CN.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.LZ=function(){y.JT.call(this,[10,42],y.YL,"tools/crepl");
this.X1="idraw";this.RQ.bmode="hue "};y.LZ.prototype=new y.JT;y.LZ.prototype.WQ=function(w,n,W,D,j){if(this.rG(D,n,j))return;
this.jM(w,W,D,j,this.RQ.flow);if(this.rN==null)return;this.kC(w)};y.LZ.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.bS=function(){y.JT.call(this,[10,43],y.z$,"tools/redeye");
this.RQ.smode=0;this.X1="redeye"};y.bS.prototype=new y.JT;y.bS.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.flow);
if(this.rN==null)return;this.kC(w)};y.bS.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.Ye=function(){y.JT.call(this,[10,38],y.uX,"tools/pencil");
this.X1="draw"};y.Ye.prototype=new y.JT;y.Ye.prototype.WQ=function(w,n,W,D,j){if(this.rG(D,n,j))return;
this.jM(w,W,D,j,this.RQ.flow);if(this.rN==null)return;this.kC(w)};y.Ye.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.$u=function(){y.JT.call(this,[10,22],y.NR,"tools/burn");
this.X1="burn"};y.$u.prototype=new y.JT;y.$u.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.expo/Math.E);
if(this.rN==null)return;this.kC(w)};y.$u.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.Wp=function(w,n,W){y.JT.call(this,w==""?null:w?w:[10,1],n?n:y.OW,W?W:"tools/clone");
this.X1="clone";this.es=null;this.R=null};y.Wp.prototype=new y.JT;y.Wp.prototype.WQ=function(w,n,W,D,j){var I=this.RQ,U=I.alt[0];
if(D.U(aK.PJ)||D.U(aK.M$)||U){this.es=w.u.Cg(j.x,j.y);this.R=null;if(U)this.qG({alt:[!1]},n);this.R9(w);
this.eg(W,D,w,j);return}if(this.es==null){alert(fV.get([15,7,0]));return}this.eg(W,D);this.jM(w,W,D,j,this.RQ.flow);
if(this.rN==null)return;this.R=this.amE(w.u.Cg(j.x,j.y));this.kC(w)};y.Wp.prototype.amE=function(w){var n=this.R;
if(n==null||!this.RQ.algnd)n=new ec(Math.round(w.x-this.es.x),Math.round(w.y-this.es.y));return n};y.Wp.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null){if(this.es!=null)this.eg(W,D,w,j);return}if(!j.WS||this.es==null)return;
this.WD(w,W,D,j);this.kC(w)};y.Wp.prototype.bO=function(){return this.R};y.QJ=function(w,n,W){y.qw.call(this,w,n,W);
this.$I={$o:{ib:0,x:0,y:0},Ov:!1};this.$p=!1;this.yU=null;this.cursor=null;this.a9f=0;this.Ol=null;this.gs=null;
this.Bf=null;this.sx=!1};y.QJ.prototype=new y.qw;y.QJ.prototype.wb=function(){return this.yU!=null};
y.QJ.prototype.LL=function(w){return this.gs!=null||this.yU&&this.yU.aou()};y.QJ.prototype.WQ=function(w,n,W,D,j){this.Ol=j;
var I=w.u.Cg(j.x,j.y),U=this.$I.$o,M=U.ib!=0?U.x/U.y:null,m=this.sx;this.sx=!1;if(this.yU){var l=this.yU.G_(I,w.u.N);
if(m&&l==null){this.yU.clear(w);this.yU=null}else{this.yU.WQ(w,W,D,I,M,!1,j);return}}this.gs=y.mU.JW(w,I,W)};
y.QJ.prototype.TT=function(w,n,W){if(W==null)W=[w.x,w.y,w.x+w.m,w.y,w.x+w.m,w.y+w.n,w.x,w.y+w.n];return new gX(W,!0,!1,this.id==y.r_,!0,n,this.id==y.r_?2:0,this.id==y.r_?4:3)};
y.QJ.prototype.eg=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.ph,In:this.cursor};w.S(n)};y.QJ.prototype.enable=function(w,n,W,D){this.xh=n;
this.cursor="crosshair";this.eg(n);if(w!=null&&this.yU==null){var j=w.J?{_b:"cropby",ahT:3}:{_b:"config",$I:this.$I,av7:!0};
this.sm(j,n,w,D,W);if(w.J==null&&this.$I.$o.ib==0)this.sx=!0}};y.QJ.prototype.QD=function(w,n,W,D,j){this.Ol=j;
var I=w.u.Cg(j.x,j.y);if(!j.WS){var U="crosshair";if(this.yU){var M=this.yU.G_(I,w.u.N,null,j);if(M)U=M;
else U="default"}if(U!=this.cursor){this.cursor=U;this.eg(n)}}if(this.yU)this.yU.QD(w,W,D,I);else if(this.gs){if(this.$p){w.I.VZ={F:["M","L"],w:[this.gs.x,this.gs.y,I.x,I.y]}}else{var m=y.IG.fS(this.gs,y.mU.JW(w,I,W),D,!0,this.$I.$o),l=m[0].x,A=m[0].y,g=this.Bf=new iB(l,A,m[1].x-l,m[1].y-A);
w.I.VZ=E.p.Wx(g);y.qw.Co(j,g,w,W)}w.RP=!0}};y.QJ.agr=function(w,n,W){var D,j,M,m;if(n<=W){D=n;j=W}else{D=W;
j=n}var I=w-Math.floor((w+Math.PI)/(2*Math.PI))*2*Math.PI;I=Math.abs(I);if(I>Math.PI/2)I=Math.PI-I;var U=D/(j*Math.sin(I)+D*Math.cos(I));
if(n<=W){M=D*U;m=j*U}else{M=j*U;m=D*U}return{gA:M,ag:m}};y.QJ.prototype.H5=function(w,n,W,D,j){this.Ol=j;
var I=w.u.Cg(j.x,j.y);if(this.yU==null){var U=this.Bf;if(this.gs&&(U||this.$p)){if(this.$p){var M=this.gs,m=I;
if(M.x>m.x){var l=M;M=m;m=l}var M=Math.atan2(-(m.y-M.y),m.x-M.x),A=y.QJ.agr(M,w.m,w.n),g=[0,0,A.gA,0,A.gA,A.ag,0,A.ag],k=new eh;
k.translate(-A.gA/2,-A.ag/2);k.rotate(M);k.translate(w.m/2,w.n/2);E.p.D(g,k,g);this.yU=this.TT(U,!1,g);
w.I.VZ=null;this.$p=!1}else{var $=this.$I.$o;this.yU=this.TT(U,$.ib!=0)}this.yU.qz(w,W);this.Bf=null;
this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,Az:!0});this.gs=null;w.I.r7=[];w.RP=!0}return}this.yU.H5(w,W,D,I);
this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,Az:!0});var g=this.yU.W2();if(Math.abs(g[0]-g[4])<2&&Math.abs(g[1]-g[5])<2){this.disable(w,n,null,D);
return}if(Date.now()-this.a9f<200&&this.yU.gO(I)){this.mK(w,W);this.disable(w,n,W,D);return}this.a9f=Date.now()};
y.QJ.prototype.oe=function(w,n,W,D){var j=this.yU;if(j==null||this.Ol&&this.Ol.WS)return;if(D.U(aK.yG)){this.mK(w,W);
this.disable(w,n,W,D)}else if(D.U(aK.QX)){this.disable(w,n,W,D)}else j.oe(w,W,D)};y.QJ.a9T=function(w,n,W){var D={classID:"null",T:{t:"Objc",v:{classID:"Rctn",Top:{t:"UntF",v:{type:"#Pxl",val:w[1]}},Left:{t:"UntF",v:{type:"#Pxl",val:w[0]}},Btom:{t:"UntF",v:{type:"#Pxl",val:w[1]+w[3]}},Rght:{t:"UntF",v:{type:"#Pxl",val:w[0]+w[2]}}}},Angl:{t:"UntF",v:{type:"#Ang",val:n!=null?n:0}},Dlt:{t:"bool",v:W!=null?W:!0},cropAspectRatioModeKey:{t:"enum",v:{cropAspectRatioModeClass:"pureAspectRatio"}},CnsP:{t:"bool",v:!1}};
return{hZ:"crop",E3:D}};y.QJ.Mf=function(w,n){if(n==null)n=[!0,!0,!0,!0];var W={classID:"trim",trimBasedOn:{t:"enum",v:{trimBasedOn:["topLeftPixelColor","bottomRightPixelColor","Trns"][w]}}},D=["Top","Left","Btom","Rght"];
for(var L=0;L<4;L++)W[D[L]]={t:"bool",v:n[L]};return{hZ:"trim",E3:W}};y.QJ.axS=function(w,n,W,D){var j={classID:"null"};
if(D!=null){j.Wdth={t:"UntF",v:{type:"#Pxl",val:w}};j.Hght={t:"UntF",v:{type:"#Pxl",val:n}};j.Intr={t:"enum",v:{Intp:["Nrst","Blnr","bicubicSharper"][D]}}}if(W!=null)j.Rslt={t:"UntF",v:{type:"#Rsl",val:W}};
return{hZ:"imageSize",E3:j}};y.QJ.a94=function(w,n,W){if(W==null)W=4;var D=Math.floor(W/3),j=W%3;return{hZ:"canvasSize",E3:{classID:"null",Wdth:{t:"UntF",v:{type:"#Pxl",val:w}},Hght:{t:"UntF",v:{type:"#Pxl",val:n}},Hrzn:{t:"enum",v:{HrzL:["Left","Cntr","Rght"][j]}},Vrtc:{t:"enum",v:{VrtL:["Top","Cntr","Btom"][D]}}}}};
y.QJ.prototype.Al=function(w,n,W,D,j){var I=new iB(0,0,W.m,W.n),U=[11,3],M=W.hh,m=W.m/2,l=W.n/2,A=1,d,r,p;
if(w.d=="fromAction"){var g=w.bs,k=g.hZ,$=g.E3,C=W.m/W.n,f=$.Wdth?$.Wdth.v.val:-1,z=$.Hght?$.Hght.v.val:-1,M=$.Rslt?$.Rslt.v.val:null,s=$.Wdth?$.Wdth.v.type:$.Hght?$.Hght.v.type:-1,O=1,a;
if(s=="#Prc"){if(f!=-1)f=Math.round(W.m*f/100);if(z!=-1)z=Math.round(W.n*z/100)}if(k=="imageSize"){if($.Intr){if($.Intr.v.Intp=="Nrst")O=0;
if($.Intr.v.Intp=="bicubicSharper")O=2;if(f==-1&&z==-1){var X=M/W.hh;f=Math.round(W.m*X);z=Math.round(W.n*X)}if($.CnsP&&$.CnsP.v){if(f==-1)f=Math.round(z*C);
if(z==-1)z=Math.round(f/C)}}else{if(s=="#Prc")M=Math.round(W.hh*(W.m/f));else if(s==-1)M=Math.round(M);
else throw"e";f=W.m;z=W.n}a={d:"imgsize",YU:f,fb:z,lF:M,Yk:O}}else if(k=="canvasSize"){if(f==-1)f=W.m;
if(z==-1)z=W.n;if($.Rltv&&$.Rltv.v==!0){if($.Wdth)f+=W.m;if($.Hght)z+=W.n}var P=$.Vrtc?$.Vrtc.v.VrtL:"Cntr",Z=$.Hrzn?$.Hrzn.v.HrzL:"Cntr";
a={d:"canvsize",YU:f,fb:z,Zl:3*["Top","Cntr","Btom"].indexOf(P)+["Left","Cntr","Rght"].indexOf(Z)}}else if(k=="revealAll"){a={d:"revealAll"}}else if(k=="trim"){var Y={topLeftPixelColor:0,bottomRightPixelColor:1,Trns:2}[$.trimBasedOn.v.trimBasedOn];
if(Y==null)throw"e";var K=["Top","Left","Btom","Rght"],S=[!0,!0,!0,!0];for(var L=0;L<4;L++)if($[K[L]])S[L]=$[K[L]].v;
a={d:"trim",a6l:Y,lR:S}}else if(k=="crop"){var G,V,T,R;if($.T){var x=$.T.v,G=Math.round(x.Left.v.val),V=Math.round(x.Top.v.val),T=Math.round(x.Rght.v.val)-G,R=Math.round(x.Btom.v.val)-V}else{var v=W.J.rect;
G=v.x;V=v.y;T=v.m;R=v.n}a={d:"canvsize",YU:T,fb:R,R:new ec(G,V),a5W:$.Dlt!=null&&$.Dlt.v}}else console.log(g);
if(a)this.Al(a,n,W,D,j);return}else if(w.d=="imgsize"){I=new iB(0,0,w.YU,w.fb);if(w.lF)M=w.lF;A=w.Yk}else if(w.d=="canvsize"){var N=w.Zl!=null?w.Zl:0;
I=new iB(0,0,w.YU,w.fb);var u=W.m-w.YU,H=W.n-w.fb,F=Math.round(u/2),t=Math.round(H/2);if(N==1||N==4||N==7)I.x=F;
if(N==2||N==5||N==8)I.x=u;if(N==3||N==4||N==5)I.y=t;if(N==6||N==7||N==8)I.y=H;if(w.R){I.x=w.R.x;I.y=w.R.y}}else if(w.d=="rot"&&(w.Z+2*Math.PI)%(Math.PI/2)!=0){var o=E.p.Wx(I).w,q=new eh;
q.translate(-m,-l);q.rotate(w.Z);q.translate(m,l);E.p.D(o,q,o);I=E.p.lV(o)}else if(w.d=="rot"&&w.Z!=Math.PI&&w.Z!=-Math.PI){I=new iB(m-W.n/2,l-W.m/2,W.n,W.m);
if((W.m+W.n&1)==1){m=Math.floor(m);l=Math.floor(l);I=new iB(m-Math.floor(W.n/2),l-Math.floor(W.m/2),W.n,W.m);
if((W.m&1)==1&&w.Z!=-Math.PI/2)I.y--;if((W.n&1)==1&&w.Z==-Math.PI/2)I.x--}}else if(w.d=="trim"){U=[11,12,0];
var _=W.Vc(),v=new iB(0,0,W.m,W.n);I=E.tx(_,v,w.a6l,w.lR);if(I.VY())I=v}else if(w.d=="revealAll"){U=[11,12,2];
I=W.root.pJ(W,!0)}var Q=w.d=="canvsize"&&w.a5W;if(w.d=="imgsize"||w.d=="rot"||w.d=="scl"||Q){var B=new eh;
if(w.d=="imgsize"){U=[11,10];B.scale(w.YU/W.m,w.fb/W.n);p=W.Iw();for(var L=0;L<p[0].length;L++)p[0][L][1]*=p[0][L][0]==0?B.dl:B.j7}else if(Q){}else{B.translate(-m,-l);
if(w.d=="rot")B.rotate(w.Z);if(w.d=="scl")B.scale(w.Z.x,w.Z.y);B.translate(m,l);U=w.s7}r=E.K.yT(B);d=this.Em(W,j,!0,r,A,Q?I:null)}else if(w.d=="auto-align"){if(W.g.length<2){alert("Select two or more layers.");
return}var i=[];for(var L=0;L<W.g.length;L++){var c=W.C[W.g[L]];if(!c.oK()&&c.add.SoLd==null){alert("Unsupported layer selected.");
return}if(c.rect.VY()){alert("Empty layer selected.");return}i.push([c.buffer,c.rect])}var h2=E.bi.SR(i,0);
if(h2==null){alert("No similarity found.");return}r=h2[1];var jX=W.g;W.g=W.g.slice(1);d=this.Em(W,j,!1,h2.slice(1),A);
W.g=jX;I=W.root.pJ(W,!0);U=[2,10,1]}var bm=new iB(0,0,W.m,W.n);if(!I.VY()&&(!I.s9(bm)||d!=null)){var dC=new go(U,this);
dC.data={amj:W.hh,lF:M,Ls:d,A6:r,bu:y.QJ.a5L(W,I,bm,d!=null)};if(p){dC.data.an7=W.Iw();dC.data.a7u=p}y.QJ.auF(W,dC.data,I);
W.kK(dC);this.Fd(dC.data,W)}};y.QJ.a5L=function(w,n,W,D){if(w.ej.length==0)return null;var j=JSON.stringify(w.ej),I=JSON.parse(j);
y.mk.ak5(I,n,W,D);I=JSON.stringify(I);return[j,I]};y.QJ.prototype.Em=function(w,n,W,D,j,I){var U={C:[],qm:null,Hb:null};
if(W){for(var L=0;L<w.C.length;L++)U.C.push(L);for(var L=0;L<w.Oi.length;L++)U.C.push(-1-L);for(var L=0;
L<w.yo.length;L++)U.C.push(-1e3-L)}else U.C=w.g.slice(0);U.qm=y.wR.ZQ(w,U.C,!0);y.wR.At(w,n,U.C,U.qm,j,D,null,!0,I);
U.Hb=y.wR.ZQ(w,U.C,!0);return U};y.QJ.prototype.Fd=function(w,n){if(w.lF)n.hh=w.lF;if(w.bu)n.ej=JSON.parse(w.bu[1]);
if(w.Ls){y.QJ._O(n,E.K.OT(w.A6));y.wR.k9(n,w.Ls.C,w.Ls.Hb);if(w.a7u)n.Pu(w.a7u)}y.QJ.$v(n,w)};y.QJ.prototype.ZE=function(w,n){if(w.amj)n.hh=w.amj;
if(w.bu)n.ej=JSON.parse(w.bu[0]);y.QJ.y3(n,w);if(w.br)n.u.R.$d(w.br);n.a4h();if(w.Ls){var W=E.K.OT(w.A6).clone();
W.Ba();y.QJ._O(n,W);y.wR.k9(n,w.Ls.C,w.Ls.qm);if(w.an7)n.Pu(w.an7)}};y.QJ._O=function(w,n){for(var L=0;
L<w.C.length;L++){var W=w.C[L];if(W.add.artb==null)continue;var D=E.p.Wx(W.yP()).w;E.p.D(D,n,D);var j=E.p.lV(D);
W.MR(j)}};y.QJ.cK=function(w){var n=new iB,W=0,D=w.root.children.length;for(var L=0;L<D;L++){var j=w.root.children[L].j;
if(j.add.artb==null)continue;n=n.x0(j.yP());W++}var I=new iB(0,0,w.m,w.n);if(!n.VY()&&!I.s9(n))return n;
return null};y.QJ.xJ=function(w){var n=y.QJ.cK(w);if(n)y.QJ.Ov(w,n,!0);return n};y.QJ.Ov=function(w,n,W){var D=w.m,j=w.n,I=n.m,U=n.n,M=n.x==0&&n.y==0;
if(M&&D==I&&j==U)return;w.m=I;w.n=U;var m=[];for(var L=0;L<w.C.length;L++)m.push(L);if(!M)y.mU.Gt(w,m,null,-n.x,-n.y);
for(var L=0;L<w.C.length;L++){w.C[L].yb(w)}w.a4h();if(W){var l=w.u.R,A=w.u.N;l.x+=Math.round((n.x+(I-D)/2)*A);
l.y+=Math.round((n.y+(U-j)/2)*A)}else w.u.R.y1(0,0);if(w.J)w.J.rect.offset(-n.x,-n.y);var g=w.Iw();for(var k=0;
k<g[0].length;k++)if(g[1][k]==-1){var $=w.jg[k];$[1]-=$[0]==0?n.x:n.y}for(var L=0;L<w.yo.length;L++)w.yo[L].rect.offset(-n.x,-n.y)};
y.QJ.prototype.sm=function(w,n,W,D,j){if(w._b=="commit"){this.mK(W,j);this.disable(W,n,null,D)}else if(w._b=="cancel"){this.disable(W,n,null,D)}var I=null,U=new iB(0,0,W.m,W.n),M=this.$I.$o;
if(w._b=="config"){this.$I=w.$I;M=this.$I.$o;if(W==null||!w.av7)return;I=U;if(M.ib==1){var m=M.x/M.y;
if(I.m/m<I.n)I.n=Math.round(I.m/m);else I.m=Math.round(I.n*m)}if(M.ib==2){I.m=M.x;I.n=M.y}I.x=Math.round((W.m-I.m)/2);
I.y=Math.round((W.n-I.n)/2)}if(w._b=="straighten"){alert("Draw a line in the image.");this.$p=!0}if(w._b=="cropby"){if(W==null)return;
var l=w.ahT,I;if(l==0)I=W.root.pJ(W,!0);if(l==1){if(W.g.length==0)alert("No layer is selected.");else{var A=W.root.fs(W.g[0]);
I=A.pJ(W,!0)}}if(l==2){if(W.g.length==0)alert("No layer is selected.");else{I=E.tx(W.Vc(),U,0);if(I.VY())I=U.clone()}}if(l==3){if(W.J!=null)I=W.J.rect;
else alert("There is no selection.")}if(l==4){I=new iB(0,0,W.m,W.n)}}if(I&&I.VY())I=null;if(I!=null){this.yU=this.TT(I,M.ib!=0);
this.yU.qz(W,j);this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,Az:!0})}};y.QJ.prototype.mK=function(w,n){var W=this.yU.W2(),D=E.p.lV(W),j=this.a1v(w,W),I=!1,U=this.$I.$o,M=this.$I.Ov,m=U.x,l=U.y,k;
if(this.id==y.xA&&U.ib==2&&j.O()!=m*l){j=new iB(j.x,j.y,m,l);I=!0}var A=E.K.kN(W,j);A=E.K.Ba(A);var g=E.K.RC(A),$=Math.atan2(A[3],A[0]);
if(Math.abs($)>1e-9||!g||I||M)k=this.Em(w,n,!0,A,1,D);var C=new go(this.name,this),f=new iB(0,0,w.m,w.n);
C.data={Ls:k,A6:A,br:w.u.R.clone(),bu:y.QJ.a5L(w,j,f,!1)};y.QJ.auF(w,C.data,j);w.kK(C);this.Fd(C.data,w);
this.track(y.QJ.a9T([D.x,D.y,D.m,D.n],null,M))};y.QJ.auF=function(w,n,W){if(W==null)return;n.G8=new iB(0,0,w.m,w.n);
n.uU=W};y.QJ.$v=function(w,n){if(n.uU==null)return;y.QJ.Ov(w,n.uU)};y.QJ.y3=function(w,n){if(n.uU==null)return;
var W=n.G8.clone();W.offset(-n.uU.x,-n.uU.y);y.QJ.Ov(w,W)};y.QJ.prototype.a1v=function(w,n){var W=E.K.kN(n),D=E.K.RC(W),j=E.K.OT(W),I=j.z2,U=j.EU,M=Math.atan2(j.k,j.dl);
j.rotate(M);var m=new iB(I,U,j.dl,j.j7);if(!D){function l(a,L,X){var P=a[L]-a[X],Z=a[L+1]-a[X+1];return Math.sqrt(P*P+Z*Z)}var A=l(n,0,2),g=l(n,4,6),k=Math.max(A,g),$=l(n,2,4),C=l(n,6,0),f=Math.max($,C),z=y.QJ.aqo(n,w.m/2,w.n/2),s,O;
if(isNaN(z)||z==Infinity||z==-Infinity||Math.min(z,1/z)<.1)z=(A+g)/($+C);if(k/f>z){s=k*1;O=s/z}else{O=f*1;
s=O*z}m.m=s;m.n=O}m.x=Math.round(m.x);m.y=Math.round(m.y);m.m=Math.round(m.m);m.n=Math.round(m.n);return m};
y.QJ.aqo=function(w,n,W){var D=w[0]-n,j=w[1]-W,I=w[2]-n,U=w[3]-W,M=w[6]-n,m=w[7]-W,l=w[4]-n,A=w[5]-W,g=((j-A)*M-(D-l)*m+D*A-j*l)/((U-A)*M-(I-l)*m+I*A-U*l),k=((j-A)*I-(D-l)*U+D*A-j*l)/((m-A)*I-(M-l)*U+M*A-m*l),$=-((k*m-j)*(g*U-j)+(k*M-D)*(g*I-D))/((k-1)*(g-1));
function C(z){return z*z}var f=Math.sqrt((C(g-1)+C(g*U-j)/$+C(g*I-D)/$)/(C(k-1)+C(k*m-j)/$+C(k*M-D)/$));
if(g==1&&k==1)f=Math.sqrt((C(U-j)+C(I-D))/(C(m-j)+C(M-D)));return f};y.QJ.prototype.disable=function(w,n,W,D){if(w==null)return;
if(this.yU)this.yU.clear(w);this.yU=null;this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,Az:!1})};y.QJ.prototype.CP=function(w,n,W,D){var j=new ed(n,!0);
j.data=W;if(D)j.G=D;w.S(j)};y.a82=function(){y.QJ.call(this,[10,2],y.xA,"tools/rcrop")};y.a82.prototype=new y.QJ;
y.ail=function(){y.QJ.call(this,[10,39],y.r_,"tools/pcrop")};y.ail.prototype=new y.QJ;y.pS=function(){y.JT.call(this,[10,21],y.wD,"tools/dodge");
this.X1="dodge"};y.pS.prototype=new y.JT;y.pS.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.expo/Math.PI);
if(this.rN==null)return;this.kC(w)};y.pS.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.LW=function(){y.JT.call(this,[10,3],y.rU,"tools/eraser");
this.X1="erase"};y.LW.prototype=new y.JT;y.LW.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.flow);
if(this.rN==null)return;this.kC(w)};y.LW.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;var I=this.WD(w,W,D,j);this.kC(w)};y.pN=function(){y.JT.call(this,[10,45],y.RV,"tools/beraser");
this.X1="ierase"};y.pN.prototype=new y.JT;y.pN.prototype.WQ=function(w,n,W,D,j){if(this.rG(D,n,j))return;
this.jM(w,W,D,j,this.RQ.flow);if(this.rN==null)return;this.kC(w)};y.pN.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.Rb=function(){y.eZ.call(this,[10,15],y.wA,"tools/rselect");
this.t1="crosshair"};y.Rb.prototype=new y.eZ;y.Rb.prototype.Gi=function(w,n,W,D){if(!D.WS||!this.xs)return;
var j=this.pJ(w,W,!0);w.I.VZ=E.p.Wx(j);w.RP=!0;y.qw.Co(D,j,w,n)};y.Rb.prototype.WB=function(w,n,W,D){w.I.VZ=null;
w.I.r7=[];w.RP=!0;this.finish(w,n,W,D)};y.Rb.prototype.getSelection=function(w,n,W,D){if(this.gs.s9(this.Gs)||!this.xs)return null;
var j=this.pJ(w,W,!0);if(j.VY())return null;return y.eZ.Pd("Rctn",j,this.RQ.anta)};y.t9=function(){y.eZ.call(this,[10,4],y.a8F,"tools/eselect");
this.t1="crosshair"};y.t9.prototype=new y.eZ;y.t9.prototype.Gi=function(w,n,W,D){if(!D.WS||!this.xs)return;
var j=this.pJ(w,W);w.I.VZ=y.t9.a9U(j);w.RP=!0;y.qw.Co(D,j,w,n)};y.t9.prototype.WB=function(w,n,W,D){w.I.VZ=null;
w.I.r7=[];w.RP=!0;this.finish(w,n,W,D)};y.t9.prototype.getSelection=function(w,n,W,D){if(this.gs.s9(this.Gs)||!this.xs)return null;
var j=this.pJ(w,W);if(!j.L0(new iB(0,0,w.m,w.n)))return null;return y.eZ.Pd("Elps",j,this.RQ.anta)};
y.t9.a9U=function(w){var n=w.x,W=w.y,D=w.x+w.m,j=w.y+w.n,I=(n+D)/2,U=(W+j)/2,M=(n-D)/2,m=(W-j)/2,l=.5522848,A={w:[I,U-m],F:["M","C","C","C","C"]};
A.w.push(I+l*M,U-m,I+M,U-l*m,I+M,U);A.w.push(I+M,U+l*m,I+l*M,U+m,I,U+m);A.w.push(I-l*M,U+m,I-M,U+l*m,I-M,U);
A.w.push(I-M,U-l*m,I-l*M,U-m,I,U-m);return A};y.Mi=function(w){y.qw.call(this,[10,5],w?y.o0:y.Ky,"tools/eyedropper");
this.oU=null;this.T$=0;this.O$=null;this.cs=1;this.lq=2;this.aoh=!0;this.n9=!1};y.Mi.prototype=new y.qw;
y.Mi.prototype.LL=function(w){return w.WS};y.Mi.prototype.Al=function(w,n,W,D,j){if(w.d=="pickhere")this.u3(W,n,j,null,w.axb);
if(w.d=="supertool")this.oU=w.G};y.Mi.prototype.WQ=function(w,n,W,D,j){var I=this.oU;if(I){I.WQ(w,n,W,D,j);
return}this.T$=W.Gp;this.O$=j;var U=this.u3(w,null,W,D,j);this.eg(w,n,U,j)};y.Mi.prototype.QD=function(w,n,W,D,j){var I=this.oU;
if(I){I.QD(w,n,W,D,j);return}var U=this.O$;if(U){var M=j.x-U.x,m=j.y-U.y,l=1,A=new ec(U.x+M*l,U.y+m*l),g=this.u3(w,null,W,D,A);
this.eg(w,n,g,A,new ec(M*(1-l),m*(1-l)))}};y.Mi.prototype.eg=function(w,n,W,D,j){var I=this.aoh,U=this.n9,l=12,A=11;
if(w.u.N>4)U=!1;if(!U&&!I)return;if(j==null)j=new ec(0,0);var M=new iB(0,0,w.m,w.n),m=w.Vc(),g=(l*2+1)*A,k=new ec(g/2,g/2),$=new iB(0,0,g,g),C=E.Q($.O()*4),f=w.u.Cg(D.x,D.y),z=Math.floor(f.x),s=Math.floor(f.y),O=new eh;
O.scale(1/A,1/A);O.translate(z-l,s-l);if(U)E.scale.uq(m,M,O,C,$);var a=(l-3.4)*A,X=(l-1.7)*A,P=l*A;for(var Z=0;
Z<g;Z++)for(var Y=0;Y<g;Y++){var K=ec.cS(new ec(Y,Z),k);if(K>a){if(I){var S=Math.max(0,a-K+1),G=(Z*g+Y)*4,V=C[G+3]<<24|C[G]<<16|C[G+1]<<8|C[G+2],T=255<<24|(Z<P+A*.5?W:this.T$);
if(K>X){S=Math.max(0,X-K+1);V=T;T=4286611584}else if(!U){V=T&16777215}C[G+0]=(1-S)*(T>>>16&255)+S*(V>>>16&255);
C[G+1]=(1-S)*(T>>>8&255)+S*(V>>>8&255);C[G+2]=(1-S)*(T>>>0&255)+S*(V>>>0&255);C[G+3]=(1-S)*(T>>>24&255)+S*(V>>>24&255)}if(K>P){C[(Z*g+Y)*4+3]=Math.max(0,255*(P-K+1))}}}function R(L){var p=L<<2;
C[p]=0;C[p+1]=0;C[p+2]=0;C[p+3]=255}function x(L){var p=L<<2;C[p]=255;C[p+1]=255;C[p+2]=255;C[p+3]=255}var v=this.cs*A+2,N=g-v>>>1,u=N+v-1;
if(U&&v<g)for(var L=0;L<v;L++){var H=N*g+N+L,F=u*g+N+L,t=(N+L)*g+N,o=(N+L)*g+u;R(H);R(F);R(t);R(o);if(L!=0&&L!=v-1){x(H+g);
x(F-g);x(t+1);x(o-1)}}if(!U)for(var L=-9;L<=9;L++){if(-3<L&&L<3)continue;var q=g>>>1,Y=q*g+q+L,Z=(q+L)*g+q;
x(Y-g);R(Y);x(Y+g);x(Z-1);R(Z);x(Z+1)}var _=y.qw.A1(0,0,["#"+E.$$(W),"RGB "+(W>>>16&255)+","+(W>>>8&255)+","+(W>>>0&255)]),M=_[1];
M.y=0;M.x=g-M.m>>>1;E.Cb(_[0],M,C,$);var d={p0:C,WH:$,Q5:new ec(k.x+j.x,k.y+j.y)},r=new ed(b.E.L,!0);
r.data={d:b.c.ph,In:d};n.S(r)};y.Mi.prototype.H5=function(w,n,W,D,j,I){this.u3(w,n,W,D,j);var U=this.oU;
if(U){U.H5(w,n,W,D,j);return}if(this.O$){this.O$=null;if(I)this.u3(w,n,W,D,j,this.T$);var M=new ed(b.E.L,!0);
M.data={d:b.c.ph,In:"default"};n.S(M)}};y.Mi.prototype.u3=function(w,n,W,D,j,I){if(I==null)I=y.Mi.B4(w,j,this.cs,this.lq);
var U=new ed(b.E.L);U.data={d:b.c.oj,AH:bk.X$,vK:D&&D.U(aK.PJ)?1:0,Z:I};if(n)n.S(U);return I};y.Mi.B4=function(w,n,W,D){if(D==null)D=2;
var j=w.u.Cg(n.x,n.y),I,U,M=w.g.length==1&&w.C[w.g[0]].eL>0,m=w.v9.length!=0,X=0,P=0,Z=0;if(M||m){var l;
if(m)l=w.yo[w.v9[0]];else{var A=w.C[w.g[0]];l=A.eL==1?A._N():A.ad0()}U=l.pJ();if(!U.y5(j))return l.color==0?0:16777215;
I=E.Q(U.O()*4);I.fill(255);var g=l.Ob();E.Mj(g,I)}else if(D==0&&w.g.length!=0){var A=w.C[w.g[0]];I=A.buffer;
U=A.rect}else{I=D==2?w.Vc():w.Vc(w.g[0]);U=new iB(0,0,w.m,w.n)}var k=Math.floor(j.x)-U.x,$=Math.floor(j.y)-U.y,C=(W-1)/2,f=Math.max(0,k-C),z=Math.max(0,$-C),s=Math.min(U.m,k+C+1),O=Math.min(U.n,$+C+1),a=(s-f)*(O-z);
for(var k=f;k<s;k++)for(var $=z;$<O;$++){var L=4*($*U.m+k);X+=I[L];P+=I[L+1];Z+=I[L+2]}X=Math.round(X/a);
P=Math.round(P/a);Z=Math.round(Z/a);return X<<16|P<<8|Z};y.Mi.prototype.sm=function(w){var n=w.RQ;this.cs=[1,3,5,11,31][n[0]];
this.lq=n[1];this.aoh=n[2];this.n9=n[3]};y.mr=function(){y.qw.call(this,[10,6],y.ZI,"tools/gradient");
this.RQ={M:JSON.parse(at._V.a1X).v,nK:"Lnr",Ty:!1,WV:!1,aoc:"norm",Z8:1};this.Hr=!1;this.k8=null};y.mr.prototype=new y.qw;
y.mr.prototype.enable=function(w,n,W,D){var j=new ed(b.E.L,!0);j.data={d:b.c.ph,In:"default"};n.S(j)};
y.mr.prototype.sm=function(w){this.RQ=w.AH};y.mr.prototype.WQ=function(w,n,W,D,j){if(!w.d2())return;
this.k8=w.u.Cg(j.x,j.y);this.k8=y.mU.JW(w,this.k8,W);this.Hr=!0};y.mr.prototype.QD=function(w,n,W,D,j){if(!this.Hr)return;
var I=w.u.Cg(j.x,j.y);I=y.mU.JW(w,I,W);if(D.U(aK.WO))I=y.mr.RM(this.k8,I);w.I.VZ={w:[this.k8.x,this.k8.y,I.x,I.y],F:["M","L"]};
w.I.cc=[this.k8.x,this.k8.y,I.x,I.y];w.RP=!0};y.mr.prototype.H5=function(w,n,W,D,j){if(!this.Hr)return;
var I=w.C[w.g[0]],U=w.u.Cg(j.x,j.y);U=y.mU.JW(w,U,W);if(D.U(aK.WO))U=y.mr.RM(this.k8,U);var M=U.eu(this.k8),m=ec.gp(this.k8,U,.5),l=Math.atan2(M.y,M.x),A=ec.cS(this.k8,U),g=Math.sin(l),k=Math.cos(l);
if(A>2){var $;if(w.J)$=w.J.rect;else $=new iB(0,0,w.m,w.n);var C=E.Q($.O()*4),f=this.RQ,z=f.nK;if(z!="Lnr"){A*=2;
m=this.k8}E.M.Yd(f.M,C,$,[k*1/A,g*1/A,-g*1/A,k*1/A],m.x,m.y,f.Ty,at.M.types.indexOf(z),W.Gp,W.as,null,f.WV);
var s=Math.round(f.Z8*256),O=C.length;if(s!=256)for(var L=0;L<O;L+=4)C[L+3]=C[L+3]*s>>>8;var a=new ed(b.E.v);
a.G=y.rU;a.data={d:"fillBMP",rY:C,ZA:f.aoc,s7:this.name};n.S(a)}w.I.VZ=null;w.I.cc=[];w.RP=!0;this.Hr=!1};
y.mr.prototype.Al=function(w,n,W,D,j){function I(k){k=k.v;var $=k.Hrzn.v.val,C=k.Vrtc.v.val;return W.u.m9($,C)}if(w.d=="fromAction"){var U=this.RQ,M=this.RQ={};
for(var m in U)M[m]=U[m];var l=w.bs.E3;if(l.Opct)M.Z8=l.Opct.v.val/100;if(l.Dthr)M.WV=l.Dthr.v;if(l.Grad)M.M=l.Grad.v;
if(l.Type)M.nK=l.Type.v.GrdT;var A=I(l.From),g=I(l.T);this.WQ(W,n,j,D,A);this.H5(W,n,j,D,g);this.RQ=U}};
y.mr.RM=function(w,n){if(w.s9(n))return w;var W=n.x-w.x,D=n.y-w.y,j=Math.abs(W),I=Math.abs(D);if(j>I)I=j/2>I?0:j;
if(I>j)j=I/2>j?0:I;j=W>0?j:-j;I=D>0?I:-I;var U=Math.sqrt(W*W+D*D)/Math.sqrt(j*j+I*I);return new ec(w.x+j*U,w.y+I*U)};
y.mr.sX=function(w,n,W,D,j,I,U){var M=new iB(0,0,n,W),m=E.Q(n*W*4);E.b6(m,n,W,4);var l=Math.sin(D),A=Math.cos(D),g=E.Q(n*W*4);
E.M.Yd(w,g,M,[A*1/n,l*1/n,-l*1/W,A*1/W],n/2,W/2,!1,0,j,I);E.s._U("norm",g,M,m,M,M,1);if(U)U.putImageData(new ImageData(new Uint8ClampedArray(m.buffer),n,W),0,0);
else return jj.Zz(m.buffer,n,W,null,null,!0)};y.mr.avh=function(w,n,W){var D=JSON.parse(JSON.stringify(w));
if(D.Clrs)for(var L=0;L<D.Clrs.v.length;L++){var j=D.Clrs.v[L].v,I=j.Type.v.Clry;if(I=="UsrS")continue;
var U=I=="FrgC"?n:W;j.Type.v.Clry="UsrS";j.Clr={t:"Objc",v:E.M.lW({o:U>>16&255,B:U>>8&255,k:U&255})}}return D};
y.fK=function(){y.qw.call(this,[10,7],y.pX,"tools/hand");this.j4=!1;this.O$=new ec(0,0);this.f1=null;
this.ft=0};y.fK.prototype=new y.qw;y.fK.prototype.sm=function(w,n,W,D){this.j4=w.j4};y.fK.prototype.Al=function(w,n,W,D,j){var I=w.d;
if(I=="setcls"){W.u.zC=w.zC;W.RP=!0;W.tL=!0}if(I=="scroll"&&!D.U(aK.PJ)){if(D.U(aK.CQ))y.fK.U5(W,W.u.R.x-w.jP.y,W.u.R.y-w.jP.x);
else y.fK.U5(W,W.u.R.x-w.jP.x,W.u.R.y-w.jP.y)}};y.fK.prototype.enable=function(w,n,W,D){this.f1=null;
var j=new ed(b.E.L,!0);j.data={d:b.c.ph,In:"grab"};n.S(j);if(w&&Date.now()-this.ft<300){j.type=b.E.v;
j.G=y.Nt;j.data={d:"adapt",Z:"fitscr"};n.S(j)}this.ft=Date.now()};y.fK.prototype.WQ=function(w,n,W,D,j){this.f1=w.u.R.clone();
this.O$.y1(j.x,j.y)};y.fK.prototype.QD=function(w,n,W,D,j){if(!j.WS)return;if(this.f1==null)this.WQ(w,n,W,D,j);
var I=this.j4?n.oZ:[w];for(var L=0;L<I.length;L++)y.fK.U5(I[L],this.f1.x+(j.x-this.O$.x),this.f1.y+(j.y-this.O$.y))};
y.fK.prototype.H5=function(w,n,W,D,j){this.f1=null};y.fK.U5=function(w,n,W){var D=w.u.N,j=w.u.xq,I=j.m,U=j.n,M=w.m*D,m=w.n*D,l=M<I&&m<U,A=I/2+M/2-64,g=U/2+m/2-64;
w.u.R.y1(Math.max(-A,Math.min(A,n)),Math.max(-g,Math.min(g,W)));w.tL=!0};y.dh=function(){y.qw.call(this,[10,47],y._E,"tools/rview");
this.O$=new ec(0,0);this.hV=null;this.jt=null;this.ft=0};y.dh.prototype=new y.qw;y.dh.prototype.enable=function(w,n,W,D){this.f1=null;
var j=new ed(b.E.L,!0);j.data={d:b.c.ph,In:"grab"};n.S(j);if(w&&Date.now()-this.ft<300&&w.u.Tg!=0){w.u.Tg=0;
w.RP=!0}this.ft=Date.now();if(w)this.wu(w,n)};y.dh.prototype.disable=function(w,n,W,D,j){if(w)this.wu(w,n)};
y.dh.prototype.Lp=function(w,n,W,D){if(w)this.wu(w,n)};y.dh.prototype.WQ=function(w,n,W,D,j){this.O$.y1(j.x,j.y);
var I=w.u;this.hV=I.Cg(I.xq.m/2,I.xq.n/2);this.jt=I.Pv();var U=I.Cg(I.xq.m/2,I.xq.n/2),M=Math.min(I.xq.m,I.xq.n)*.35/I.N,m=M*.2,l=U.x,A=U.y;
w.I.VZ={F:"M L L L L L".split(" "),w:[l,A,l,A-M,l+m,A,l,A+M,l-m,A,l,A-M]};w.RP=!0};y.dh.prototype.abq=function(w){var n=w.u,W=n.Cg(n.xq.m/2,n.xq.n/2);
w.I.VZ={F:["M","L"],w:[W.x,W.y,W.x,W.y-200]}};y.dh.prototype.QD=function(w,n,W,D,j){if(!j.WS)return;
var I=w.u,U=this.hV,M=this.O$,m=new ec(I.xq.m/2,I.xq.n/2),l=Math.atan2(j.y-m.y,j.x-m.x),A=Math.atan2(M.y-m.y,M.x-m.x),g=Math.atan2(this.jt.k,this.jt.dl),k=l-A,$=Math.PI/4;
if(D.U(aK.WO)){k=g+$*Math.round((k-g)/$)}this.ad2(w,n,this.jt.clone(),U,k)};y.dh.prototype.H5=function(w,n,W,D,j){w.I.VZ=null;
w.RP=!0};y.dh.prototype.sm=function(w,n,W,D){this.ad2(W,n,null,null,w.kI-W.u.Tg);W.u.Tg=w.kI};y.dh.prototype.ad2=function(w,n,W,D,j){var I=w.u;
if(W==null)W=I.Pv();if(D==null)D=I.Cg(I.xq.m/2,I.xq.n/2);W.translate(-D.x,-D.y);W.rotate(j);W.translate(D.x,D.y);
I.a3Y(W);if(w.m*I.N<I.xq.m&&w.n*I.N<I.xq.n)I.R.y1(0,0);w.RP=!0;this.wu(w,n)};y.dh.prototype.wu=function(w,n){var W=new ed(b.E.L,!0);
W.data={d:b.c.Bg,G:this.id,kI:w.u.Tg};n.S(W)};y.Vj=function(){y.Wp.call(this,[10,25],y.e$,"tools/hbrush")};
y.Vj.prototype=new y.Wp("");y.Vj.prototype.H5=function(w,n,W,D,j){if(this.rN==null)return;this.X_(w,"heal",this.rN._a(),this.rN.pJ(),this.rN.oi());
this.l(w,this.rN.oi());y.JT.prototype.H5.call(this,w,n,W,D,j);if(!this.RQ.algnd)this.R=null};y.hr=function(w){y.qw.call(this,w?["VAR0 VAR1",[22,4,1],[10,8]]:[10,8],w?y.Kk:y.Lu,w?"tools/vtype":"tools/htype");
this.lk=[];this.Yo=null;this.caller=null;this.E8=1;this.Ny=null;this.abb=0;this.$i=0;this.a9h=null;this.KN=null;
this.IU=null;this.kr=null;this.ub=null;this.SD=null;this.a1S=null;this.FY=null;this.yU=null;this.zQ=null;
this.ag5=null;this.Rh=!1;this.fL=!1;this.Lb=!1;this.rB=null;this.yu=null;this.aoV=null;this.Lo=!1;this.HN=!1;
this.GL=-1;this.oQ=-1;this.YV=document.createElement("textarea");this.YV.setAttribute("style","font-family:Arial; font-size:14px; z-index:-1; "+" position:absolute; top:0px; left:0px; pointer-events: none; opacity:0; width:"+(window.innerWidth-10)+"px; height:150px;");
this.YV.addEventListener("input",this.NZ.bind(this),!1);this.YV.addEventListener("keydown",this.adA.bind(this),!1);
this.YV.addEventListener("keyup",this.ami.bind(this),!1)};y.hr.prototype=new y.qw;y.hr.prototype.LL=function(w){return w.WS};
y.hr.prototype.BW=function(w,n,W,D){if(this.IU!=null||this.id==y.Kk)return;this.caller=n;var j=this.aah(w);
if(j.length!=0){var I=null,U=[],M=[];for(var L=0;L<j.length;L++){var m=w.C[j[L]],l=m.add.TySh,A=0,g=hd.Bb(l._o).length-2,k=hd.tG(l._o,A,g);
hd.mh(k,l.D.NW());if(k.lJ.Font!=null)k.lJ.Font=k.JO[k.lJ.Font].Name;I=k.JO;U.push(k.lJ);M.push(k.ci)}var k={JO:I,lJ:hd.y9(U),ci:hd.y9(M)};
if(k.lJ.Font!=null)hd.hI(k,k.lJ.Font);this.a8g(n,k,l)}};y.hr.prototype.aah=function(w){var n=[];for(var L=0;
L<w.g.length;L++)if(w.C[w.g[L]]&&w.C[w.g[L]].add.TySh)n.push(w.g[L]);return n};y.hr.prototype.Al=function(w,n,W,D,j){var I=w.d=="insertGlyph",U=w.d=="copyText",M=w.d=="selectAll";
if((I||U||w.d=="insertText"||M)&&this.IU){var m=I?String.fromCharCode(65533):w.Z,l=this.YV,A=l.value,g=l.selectionStart,k=l.selectionEnd;
if(U){e8.mJ(new Blob([A.slice(g,k)],{type:"text/plain"}))}else if(M){this.GL=l.selectionStart=0;this.oQ=l.selectionEnd=A.length;
this.dj(W);l.focus()}else{l.value=A.slice(0,g)+m+A.slice(k);l.selectionStart=l.selectionEnd=g+m.length;
this.NZ(null,I?w.Z:null);l.focus()}}if(w.d=="updateStyles"){if(this.IU==null){var $=this.aah(W),C=!1;
if($.length!=0){this.VG(W,n,j,$);for(var L=0;L<$.length;L++){var f=W.C[$[L]],z=f.add.TySh;hd.Yg(z,this.E8);
this.IU=f;var s=hd.Bb(z._o);this.GL=0;this.oQ=s.length-1;hd.g0(z._o,this.GL,this.oQ,this.gk(j,z));var O=this.a5(W,j);
if(O==!1)C=!0}if(C){this.Lo=!0;return}this.Jh(W,n)}return}this.Td(j)}if(w.d.startsWith("warp")){var a=this.HN;
if(w.d=="warp"||w.d=="warpCancel"){if(this.IU==null)return;if(w.d=="warp")this.IU.add.TySh.hc=w.XB;else this.IU.add.TySh.hc=this.a1S;
this.a5(W,j);if(!a)this.dj(W)}if(w.d!="warp")this.YV.focus();if((w.d=="warpConfirm"||w.d=="warpCancel")&&a){this.HN=!1;
if(w.d=="warpConfirm")this.Jh(W,n);else this.oz(W,n)}}if(w.d=="editCurr"){if(j.No!=y.Lu){this.Ny=j.No;
var X=new ed(b.E.L,!0);X.data={d:b.c.CV,G:y.Lu};n.S(X)}if(this.IU!=null)this.disable(W,n,j,D);this.Yo=j;
this.caller=n;this.VG(W,n,j,[w.XT]);var s=hd.Bb(this.IU.add.TySh._o);this.GL=0;this.oQ=s.length-1;this.dj(W);
this.Uw();this.YV.focus()}if(w.d=="switchPntPrgr"){if(this.IU)return;var f=W.C[W.g[0]],z=f.add.TySh,P=z.D.NW(),Z=JSON.parse(JSON.stringify(z._o)),Y=hd.F$(Z),K=Y==1?hd.Bj(Z):[0,0,Math.round(f.rect.m*1.05/P),Math.round(f.rect.n*1.25/P)],S=hd.tG(Z,0,0),G=S.JO[S.lJ.Font].Name,V=j.hY.lY(G),T=[0,K[2],K[2]/2][S.ci.Justification%3],R=V?d2.Ea(V,G,S.lJ):S.lJ.FontSize*.8;
hd.VL(Z,1-Y);if(Y==0){T=-T;R=-R;hd.sV(Z,[0,0,K[2],K[3]])}var x=new eh(1,0,0,1,T,R);x.concat(z.D);this.Al({$Z:W.g[0],d:"newED",xw:Z,D:x,a9$:[16,3,Y==1?0:1]},n,W,D,j)}if(w.d=="newED"){var f=W.C[w.$Z],z=f.add.TySh,v=this.yR(W,[w.$Z]);
z._o=w.xw;if(w.D)z.D=w.D;if(aj.bN(z,j.hY,n)){aj.a5(f,j.hY,W);W.l()}else W.XW=!0;var N=new go(w.a9$?w.a9$:this.name,this);
N.data={M4:v,LH:this.yR(W,[w.$Z])};W.kK(N)}if(w.d=="fromAction"){var u=w.bs.E3.Usng.v,H=u.TxtC.v,F=[];
for(var L=0;L<2;L++){var t=H[L==0?"Hrzn":"Vrtc"].v,m=t.val;if(t.type=="#Prc")m=(L==0?W.m:W.n)*(m/100);
F[L]=m}this.sP(W,n,j,D,W.u.m9(F[0],F[1]),!0);var f=W.C[W.g[0]],z=f.add.TySh,o=z._o,A=hd.Bb(o);hd.Ec(o,0,A.length-1);
hd.KO(o,0,u.Txt.v.replace(/\r/g,"\n"));A=hd.Bb(o);for(var Y=0;Y<2;Y++){var q=u[Y==0?"Txtt":"paragraphStyleRange"].v;
for(var L=0;L<q.length;L++){var _=q[L].v,g=_.From.v,k=Math.min(_.T.v-1,A.length-1);_=_[Y==0?"TxtS":"paragraphStyle"].v;
var d=hd.tG(o,g,k),r=Y==0?d.lJ:d.ci;for(var p in _){var Q=_[p].v;if(p=="Sz")r.FontSize=Math.round(Q.val*(Q.type=="#Pnt"?W.hh/72:1));
else if(p=="fontPostScriptName")hd.hI(d,Q);else if(p=="Algn")r.Justification={Left:1,Cntr:2}[Q.Alg];
else if(p=="leading")r.Leading=_[p].v.val;else if(p=="baselineShift")r.BaselineShift=_[p].v.val;else if(p=="autoLeading")r.AutoLeading=_[p].v;
else if(p=="syntheticBold")r.FauxBold=_[p].v;else if(p=="syntheticItalic")r.FauxItalic=_[p].v;else if(p=="Trck")r.Tracking=_[p].v;
else if(p=="verticalScale")r.VerticalScale=_[p].v/100;else if(p=="horizontalScale")r.HorizontalScale=_[p].v/100;
else if(p=="Clr")r.FillColor={Type:1,Values:[1,Q.Rd.v/255,Q.Grn.v/255,Q.Bl.v/255]}}hd.g0(o,g,k,d)}}if(aj.MF(W,j.hY,n))aj.a5(f,j.hY,W);
else W.XW=!0;W.l();this.Jh(W,n)}};y.hr.prototype.Td=function(w){var n=Math.min(this.GL,this.oQ),W=Math.max(this.GL,this.oQ),D=this.IU.add.TySh;
hd.Yg(D,this.E8);var j=this.gk(w,D);hd.g0(D._o,n,W-1,j);var I=this.caller.Nc(),U=this.a5(I,w);if(U)this.dj(I);
if(document.activeElement.tagName.toLowerCase()!="input")this.YV.focus()};y.hr.prototype.wO=function(w){return this.lk.indexOf(w)!=-1};
y.hr.prototype.enable=function(w,n,W,D){var j=this.YV;n.e.appendChild(j);this.FY="default";this.eg(n)};
y.hr.prototype.wb=function(){return this.IU!=null};y.hr.c1=function(w,n){for(var L=w.C.length-1;L>=0;
L--){var W=w.C[L];if(W.add.TySh&&W.rect.y5(n)&&w.ajb(L)){var D=W.m7(31);return D?-2:L}}return-1};y.hr.prototype.WQ=function(w,n,W,D,j){this.Yo=W;
this.caller=n;var I=w.u.Cg(j.x,j.y),U=this.IU==null;if(U){var M=y.hr.c1(w,I);if(M==-2){alert(fV.get([6,57,0]));
return}if(M>=0&&!D.U(aK.WO)){if(!aj.bN(w.C[M].add.TySh,W.hY,n)){alert("Fonts not loaded yet");return}this.VG(w,n,W,[M])}else{this.Lb=!0;
this.rB=j;return}}var m=U?-1:hd.F$(this.IU.add.TySh._o),l=this.zQ?this.zQ:this.yU;if(l&&l.WQ(w,W,D,I,null,null,j)&&E.XB.pi(this.IU.add.TySh.hc)||!U&&E.p.mm(I,this.IU.rect)>20/w.u.N&&(m==0||m==1)){this.Rh=!0;
this.yu=I;this.aoV=this.IU.add.TySh.D.clone();if(this.GL==-1&&this.oQ==-1)this.GL=this.oQ=this.Wy(I)}else{if(this.ub==null){alert("Fonts not loaded yet");
return}this.fL=!0;this.GL=this.oQ=this.Wy(I);var A=Date.now();if(A-this.abb>300)this.$i=0;this.$i++;
this.abb=A;if(this.$i==2)this.alX();if(this.$i==3)this.aqR();if(this.$i>1){this.fL=!1}}this.Uw();this.dj(w)};
y.hr.prototype.VG=function(w,n,W,D){var j=w.C[D[0]];this.IU=j;this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,_b:"showactive"});
this.kr=D;w.g=D.slice(0);w.jO();w.gL=!0;this.SD=this.yR(w,D);this.Cl(j.add.TySh);this.a5(w,W)};y.hr.prototype.Cl=function(w){if(hd.F$(w._o)!=1)return;
var n=hd.Bj(w._o);n=new iB(0,0,n[2]-n[0],n[3]-n[1]);var W=[n.x,n.y,n.x+n.m,n.y,n.x+n.m,n.y+n.n,n.x,n.y+n.n];
E.p.D(W,w.D,W);this.yU=new gX(W,!1,!1,!1,!0)};y.hr.prototype.alX=function(){var w=hd.Bb(this.IU.add.TySh._o);
this.GL=this.a0n(w,this.GL);this.oQ=this.alQ(w,this.GL)};y.hr.prototype.a0n=function(w,n){var W=" \t\n,.?!_-+=@#$%^&*'\"(){}[]\\/<>:;|",D=[];
for(var L=0;L<W.length;L++)D.push(W.charAt(L));var j=D.indexOf(w[n])==-1?!0:!1;for(var L=n-1;L>=0;L--)if(D.indexOf(w.charAt(L))!=-1==j)return L+1;
return 0};y.hr.prototype.alQ=function(w,n){var W=" \t\n,.?!_-+=@#$%^&*'\"(){}[]\\/<>:;|",D=[];for(var L=0;
L<W.length;L++)D.push(W.charAt(L));var j=D.indexOf(w[n])==-1?!0:!1;for(var L=n+1;L<w.length;L++)if(D.indexOf(w.charAt(L))!=-1==j)return L;
return w.length-1};y.hr.prototype.aqR=function(){var w=this.ub.auH(this.GL);this.GL=w[0];this.oQ=w[1]};
y.hr.prototype.eg=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.ph,In:this.FY};w.S(n)};y.hr.prototype.QD=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=this.IU;
if(!j.WS){var M="default",m=this.yU,l=this.zQ?this.zQ:m;if(l&&E.XB.pi(U.add.TySh.hc)){var A=l.G_(I,w.u.N,null,j);
if(A)M=A;else if(l==m&&m.gO(I))M="text"}else if(U&&E.p.mm(I,U.rect)>20/w.u.N)M="move";else if(y.hr.c1(w,I)>=0)M="text";
if(M!=this.FY){this.FY=M;this.eg(n)}}var g=this.rB;if(this.Lb&&Math.min(j.x-g.x,j.y-g.y)>4/w.u.N){this.Lb=!1;
this.sP(w,n,W,D,j);U=this.IU;this.Rh=!0;this.yU=new gX(null,!1,!1,!1,!0);var k=w.u.Cg(this.rB.x,this.rB.y);
k.x=Math.round(k.x);k.y=Math.round(k.y);this.yU.WQ(w,W,D,k,null,null,j,w.u.Tg)}if(this.Rh){var $=U.add.TySh;
if(this.zQ){this.zQ.QD(w,W,D,I);var C=E.K.OT(E.K.kN(this.zQ.W2(),this.ag5));$.D=C;this.a5(w,W);hd.ls($)}else if(this.yU){this.yU.QD(w,W,D,I);
var f=$.D.clone(),z=Math.atan2(f.k,f.dl);f.rotate(z);var C=E.K.OT(E.K.kN(this.yU.W2())),s=Math.atan2(C.k,C.dl);
C.rotate(s);if(!isNaN(C.dl)&&C.dl*C.j7-C.k*C.Cj!=0){var O=new iB(0,0,C.dl/f.dl,C.j7/f.j7),a=Math.round(O.m),X=Math.round(O.n),P=$._o.Curve;
if(P){var Z=hd.Bj($._o),Y=new eh(a/Z[2],0,0,X/Z[3],0,0);E.p.D(P.Points,Y,P.Points);hd.ls($)}hd.sV($._o,[0,0,a,X]);
$.D=E.K.OT(E.K.kN(this.yU.W2(),O));this.a5(w,W);hd.ls($)}}else{var K=I.x-this.yu.x,S=I.y-this.yu.y;$.D=this.aoV.clone();
var G=new ec($.D.z2+K,$.D.EU+S);G=y.mU.JW(w,G,W);$.D.z2=G.x;$.D.EU=G.y;this.a5(w,W)}}if(this.fL)this.oQ=this.Wy(I);
if(this.Rh||this.fL)this.dj(w)};y.hr.prototype.sP=function(w,n,W,D,j,I){var U=w.OV(),M=U[0],m=U[1],l=w.QI();
l.add.lnsr="rend";var A=w.C.slice(0);l.nz("Text layer "+A.length);this.IU=l;var g=w.g.length==0?w.C.length-1:w.g[w.g.length-1],k=g+1;
if(A[g].add.lsct==ef.fz)k--;this.SD={VQ:A.slice(0),Py:w.g.slice(0)};A.splice(k,0,l);w.g=[k];this.GL=this.oQ=0;
w.Gd(A);this.SD._B=A.slice(0);this.SD.TY=w.g.slice(0);this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,_b:"showactive"});
var $=w.u.Cg(j.x,j.y),C=W.Hu;console.log(C);if(this.id==y.Kk){C=JSON.parse(JSON.stringify(C));C.lJ.BaselineDirection=1}l.add.TySh=hd._3($.x,$.y,C,w.u.Tg);
var f=l.add.TySh,z=f._o;if(this.id==y.Kk)z._LineOrientation=2;hd.Yg(f,this.E8);if(j.WS)hd.VL(z,1);else{hd.VL(z,0);
var s=M[m.pop()],O=s?s.add.vmsk:null;if(I)O=null;if(O&&!D.U(aK.WO)){O=O.clone();var a=O.i,P,Z;for(var L=0;
L<a.length;L++)if(a[L].Ht!=null)a[L].Ht=0;var X=5/w.u.N;P=E.P.pw(O.i,$,!0,X);if(P.p_==-1)P=E.P.pw(O.i,$);
if(P.p_!=-1){hd.VL(z,1);var Y=E.P.tt(a,P.p_),K=E.P.qA(a,P.p_)-1;a=O.i=a.slice(0,2).concat(a.slice(Y,Y+K+1));
O.g=[];f.add={vmsk:O,vogk:h.hu(a)};z.Curve={};hd.Y_(f);if(P.po!=null){var S=d2.AL(z.Curve);E.p.D(S[0],f.D,S[0]);
var G=E.p.VK(S[0],$.x,$.y),V=W.Hu.ci.Justification;if(V==2||V==5){var T=(S[2][G]+S[3]*.5)%S[3];G=d2.nQ(T,S[2])}var R=S[1][G];
R=R%K;O.H3=[R,R];hd.Y_(f)}else this.Cl(f)}}}return l};y.hr.prototype.H5=function(w,n,W,D,j,I){if(I){this.Lb=!1;
return}if(this.IU==null&&!this.Lb)return;var U=w.u.Cg(j.x,j.y),M=this.Lb;if(this.Lb){this.Lb=!1;this.sP(w,n,W,D,j);
this.fL=!0}if(this.Rh||this.fL){this.dj(w);this.Uw();if(M)this.Td(W)}if(this.Rh&&this.yU)this.yU.H5(w,W,D,U);
this.Rh=this.fL=!1;this.YV.focus()};y.hr.prototype.Uw=function(){var w=this.IU.add.TySh,n=Math.min(this.GL,this.oQ),W=Math.max(this.GL,this.oQ),D,j;
if(n==W){var I=hd.Bb(w._o);if(n==0||I.charAt(n-1)=="\n")D=j=n;else D=j=n-1}else{D=n;j=W-1}var U=hd.tG(w._o,D,j);
hd.mh(U,w.D.NW());this.a8g(this.caller,U,w)};y.hr.prototype.a8g=function(w,n,W){this.CP(w,b.E.L,{d:b.c.oj,AH:bk.a8,Hu:n});
var D=this.E8=hd.J8(W);this.CP(this.caller,b.E.L,{d:b.c.Bg,G:this.id,_b:"changeAA",qY:D})};y.hr.prototype.cF=function(w,n,W,D,j){if(w==null)return;
var I=w.u.Cg(j.x,j.y),U=y.hr.c1(w,I);if(U==-1)return;var M=new ed(b.E.L,!0);M.data={d:b.c.Bg,G:this.id,_b:"showpan",azv:this.IU!=null,XT:U,ao:j,AR:w,Yo:W};
n.S(M)};y.hr.prototype.ag_=function(){var w=this.IU;if(w&&!this.Rh&&this.zQ!=null){var n=this.caller.Nc();
this.zQ.H5(n,this.Yo,null,null);this.zQ=null;this.Cl(w.add.TySh);this.dj(n)}};y.hr.prototype.disable=function(w,n,W,D){var j=this.IU;
this.Jh(w,n)};y.hr.prototype.sm=function(w,n,W,D,j){if(this.HN)return;if(w._b=="commit")this.Jh(W,n);
if(w._b=="cancel")this.oz(W,n);if(w._b=="changeAA"){this.E8=w.qY;if(W!=null)this.Al({d:"updateStyles"},n,W,D,j)}if(w._b=="showwarp"){if(W==null)return;
if(this.IU==null){var I=W.C[W.g[0]],U=I.add.TySh;if(U==null)return;this.VG(W,n,j,[W.g[0]]);this.YV.focus();
this.HN=!0}this.a1S=this.IU.add.TySh.hc;var M=new ed(b.E.L,!0);M.data={d:b.c.P2,jW:"textwarp"};n.S(M)}};
y.hr.prototype.GZ=function(w,n){if(n!=bk.v3)return;if(this.Lo){this.Lo=!1;var W=this.caller.Nc(),D=this.kr;
for(var L=0;L<D.length;L++){this.IU=W.C[D[L]];this.a5(W,w)}this.Jh(W,this.caller);return}if(this.IU)this.Td(w)};
y.hr.prototype.gk=function(w,n){var W=JSON.parse(JSON.stringify(w.Hu));hd.mh(W,1/n.D.NW());return W};
y.hr.prototype.Fd=function(w,n){if(w.M4!=null)this.bv(n,w.LH);else this.a1h(n,w._B,w.TY)};y.hr.prototype.ZE=function(w,n){if(w.M4!=null)this.bv(n,w.M4);
else this.a1h(n,w.VQ,w.Py)};y.hr.prototype.bv=function(w,n){for(var L=0;L<n.length;L++){var W=n[L],D=W.$Z,j=w.C[D];
j.buffer=W.Ey;j.rect=W.WH.clone();j.l();j.US.HY=null;j.US.path=null;var I=j.add.TySh;I.hc=W.XB;I.IA=W.IA.clone();
I.D=W.D.clone();I._o=JSON.parse(JSON.stringify(W._o));j.iQ()}w.l()};y.hr.prototype.yR=function(w,n){var W=[];
for(var L=0;L<n.length;L++){var D=n[L],j=w.C[D],I=j.add.TySh;W.push({$Z:D,D:I.D.clone(),XB:JSON.parse(JSON.stringify(I.hc)),IA:I.IA.clone(),_o:JSON.parse(JSON.stringify(I._o)),Ey:j.buffer.slice(0),WH:j.rect.clone()})}return W};
y.hr.prototype.a1h=function(w,n,W){w.g=W;w.Gd(n);w.l();w.rR=!0};y.hr.prototype.a5=function(w,n,W){if(W==null)W=!1;
var D=this.IU.add.TySh;if(!aj.bN(D,n.hY,this.caller))return!1;if(!W){var j=hd.Bb(D._o);this.YV.value=j.slice(0,j.length-1)}var I=this.IU.rect,U=aj.a5(this.IU,n.hY,w);
this.ub=U[0];var M=U[1];if(E.XB.pi(D.hc))D.IA=new iB;else{if(hd.F$(D._o)==1){var m=hd.Bj(D._o),bK=M.IA.y;
D.IA=new iB(0,bK,m[2]-m[0],m[3]-m[1]-bK)}else D.IA=M.IA}w.X0();w.l(w.root.a7(M.WH.x0(I),w,w.C.indexOf(this.IU)));
return!0};y.hr.prototype.NZ=function(w,n){if(this.IU==null||this.HN)return;var W=this.YV.selectionStart,D=this.IU.add.TySh,j=hd.Bb(D._o),I=this.YV.value+"\n",U=Math.min(this.GL,this.oQ),M=Math.max(this.GL,this.oQ),k=!1;
this.GL=Math.min(W,U);if(I.length-W<j.length-this.oQ)this.oQ=j.length-I.length+W;if(j!=I){while(this.GL>0&&j.charAt(this.GL-1)!=I.charAt(this.GL-1))this.GL--}var m=j.substring(0,this.GL),l=j.substring(this.oQ,j.length),A=I.substring(this.GL,I.length-l.length);
hd.Ec(D._o,this.GL,this.oQ);hd.KO(D._o,this.GL,A);if(n!=null)hd.aqP(D._o,this.GL,n);var g=this.gk(this.Yo,D),$=-1,C=Array.from(A);
for(var L=0;L<C.length;L++)$=Math.max($,C[L].codePointAt(0));if($!=-1&&$>128&&$!=65533&&g.lJ.Font!=null){var f=g.JO[g.lJ.Font].Name,z=this.Yo.hY.zv($,f,g.JO);
if(f!=z){hd.hI(g,z);k=!0}}if(this.KN!=null&&A==this.KN){var s=JSON.parse(this.a9h);g.lJ=s.lJ;g.JO=s.JO;
k=!0}hd.g0(D._o,this.GL,this.GL+A.length-1,g);this.GL=this.oQ=m.length+A.length;var O=this.caller.Nc(),a=this.a5(O,this.Yo,!0);
if(a)this.dj(O,!0);if(k)this.Uw()};y.hr.prototype.ami=function(w){var n=aK;if(!w.ctrlKey)this.ag_();
w.stopPropagation()};y.hr.prototype.adA=function(w){w.stopPropagation();var n=w.ctrlKey||w.metaKey,W=aK,m=0,l=0,a=0,x=!1;
if(this.IU==null||this.HN)return;if(this.IU==null)return;var D=this.caller.Nc();if(this.zQ==null&&n){var j=this.IU.add.TySh,I=hd.F$(j._o),U;
if(I==1){U=hd.Bj(j._o);U=new iB(0,0,U[2]-U[0],U[3]-U[1])}else U=this.ub.jS();var M=[U.x,U.y,U.x+U.m,U.y,U.x+U.m,U.y+U.n,U.x,U.y+U.n];
E.p.D(M,j.D,M);this.zQ=new gX(M,!0,!0,!1,!1);this.ag5=U;this.dj(D)}if(W.$L(w.code,W.i$))m=1;if(W.$L(w.code,W.z5))m=-1;
if(W.$L(w.code,W.Fe))l=-1;if(W.$L(w.code,W.I$))l=1;var A=W.$L(w.code,aK.LT),g=W.$L(w.code,aK.alP);if(W.$L(w.code,aK.yG)&&n){this.Jh(D,this.caller);
return}if(W.$L(w.code,aK.QX)){this.oz(D,this.caller);return}if(W.$L(w.code,aK.R4)){w.preventDefault();
var k=this.YV,$=k.value,C=k.selectionStart,f=k.selectionEnd;k.value=$.substring(0,C)+"\t"+$.substring(f);
k.selectionStart=k.selectionEnd=C+1;this.NZ(null);return}var z=W.$L(w.code,W.fQ),s=W.$L(w.code,W.Ne);
if(n&&(z||s)){w.preventDefault();var O=new ed(b.E.v,!0);O.G=y.Nt;O.data={d:"zoom",pZ:z};this.caller.S(O)}if(W.$L(w.code,W.k2))a=1;
if(W.$L(w.code,W.W8))a=-1;var X=this.GL==this.oQ,P=n&&w.shiftKey&&a!=0&&!X;if(P||w.altKey&&m!=0){var Z=JSON.parse(JSON.stringify(this.Yo.Hu));
if(P){var Y=Z.lJ.FontSize;if(Y==null)Y=16;Z.lJ.FontSize=Math.max(1,Y+a*(w.altKey?5:1))}else{if(X){Z.lJ.Kerning+=20*m;
Z.lJ.AutoKerning=!1}else Z.lJ.Tracking+=20*m}w.preventDefault();var K=new ed(b.E.L,!0);K.data={d:b.c.oj,AH:bk.a8,Hu:Z};
this.caller.S(K);var O=new ed(b.E.v,!0);O.G=y.Lu;O.data={d:"updateStyles"};this.caller.S(O);return}if((W.$L(w.code,W.Ak)||W.$L(w.code,W.Pn))&&n){var S=this.GL,G=this.oQ;
if(S>G){var V=S;S=G;G=V}var j=this.IU.add.TySh,T=hd.Bb(j._o);if(S!=G){this.KN=T.slice(S,G);this.a9h=JSON.stringify(this.Yo.Hu)}}var R=hd.Bb(this.IU.add.TySh._o);
if(m!=0||l!=0||A||g){w.preventDefault();var v=this.GL;if(m!=0){if(n&&m==-1)v=this.a0n(R,this.GL-1);else if(n&&m==1)v=this.alQ(R,this.GL);
else{var k=this.YV,$=k.value;v=this.GL+m;if(v!=0&&$.codePointAt(v-1)>65535)v+=m}}else if(l!=0){var N=this.ub.ic(this.GL);
if(l==-1&&N.TL==0)v=0;else if(l==1&&N.TL==this.ub.aep()-1)v=99999999999;else v=this.ub.a3v(new ec(N.WH.x+N.WH.m/2,0),N.TL+l)}else if(A){var u=this.GL-1;
while(u>0&&R.charCodeAt(u)!=10)u--;v=u==0?0:u+1}else if(g){var u=this.GL;while(u<R.length-1&&R.charCodeAt(u)!=10)u++;
v=u}v=Math.max(0,Math.min(R.length-1,v));if(w.shiftKey)this.GL=v;else this.GL=this.oQ=v;x=!0}if(W.$L(w.code,aK.c)&&n){this.GL=0;
this.oQ=R.length-1;x=!0}if(x){this.Uw();this.dj(D)}};y.hr.a4e=function(w,n){var W=w.length;if(W!=n.length)return!1;
for(var L=0;L<W;L++)if(w[L].$Z!=n[L].$Z)return!1;return!0};y.hr.prototype.Jh=function(w,n){if(this.IU==null)return;
this.IU.iQ();var W=this.SD;if(W instanceof Array){var D=this.yR(w,this.kr),j=w.by();if(j!=null&&j.G==this&&j.data.M4&&y.hr.a4e(j.data.M4,W))j.data.LH=D;
else{var I=new go(this.name,this);I.data={M4:W,LH:D};w.kK(I)}}else{var I=new go(this.name,this);I.data={VQ:W.VQ,_B:W._B,Py:W.Py,TY:W.TY};
w.kK(I)}this.escape(w,n)};y.hr.prototype.oz=function(w,n){if(this.IU==null)return;if(this.SD instanceof Array){this.bv(w,this.SD);
if(this.IU)hd.ls(this.IU.add.TySh)}else{w.g=this.SD.Py;w.Gd(this.SD.VQ);w.rR=!0}w.l();this.escape(w,n)};
y.hr.prototype.escape=function(w,n){this.ag_();this.IU=null;this.kr=null;this.ub=null;this.yU=null;this.YV.blur();
w.I.VZ=null;w.I.Im=null;w.I.cc=[];w.RP=!0;this.Rh=!1;this.fL=!1;this.GL=this.oQ=-1;this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,_b:"hideactive"});
if(this.Ny){var W=new ed(b.E.L,!0);W.data={d:b.c.CV,G:this.Ny};n.S(W);this.Ny=null}};y.hr.prototype.CP=function(w,n,W,D){var j=new ed(n,!0);
j.data=W;if(D)j.G=D;w.S(j)};y.hr.prototype.Wy=function(w){var n=this.IU.add.TySh,W=this.ub,D=n.D.clone();
D.Ba();var j=D.bj(w),I=hd.pJ(n,W),U=E.XB.BI(n.hc,I),M=E.xv.aic(U,j);if(M==null)M=new Float64Array(2);
j=new ec(I.x+M[0]*I.m,I.y+M[1]*I.n);if(W.UX){var m=W.UX.clone();m.Ba();j=m.bj(j)}var l=W.a3v(j);return l};
y.hr.prototype.dj=function(w,n){if(n==null)n=!1;var W=this.IU.add.TySh,D=hd.F$(W._o),j=this.ub,I=j?hd.pJ(W,j):null;
w.I.cc=[];w.I.VZ=null;w.I.Im=null;var U=this.zQ?this.zQ:this.yU;if(U){U.qz(w,this.Yo,!E.XB.pi(W.hc));
var M=W.D.clone();M.Ba();if(j&&j.UX&&j.Y3==1){var m=j.UX.clone();m.Ba();M.concat(m)}E.p.D(w.I.cc,M,w.I.cc);
E.p.D(w.I.VZ.w,M,w.I.VZ.w);if(j&&j.UX==null&&j.a7J()){var l=I.m-20,A=I.n+8;w.I.VZ.w.push(l,A,l+10,A,l+5,A-5,l+5,A+5);
w.I.VZ.F.push("M","L","M","L")}}else if(D==0)this.a4F(w,W,j);else w.I.VZ={w:[],F:[]};var g=Math.min(this.GL,this.oQ),k=Math.max(this.GL,this.oQ);
if(!n){this.YV.selectionStart=g;this.YV.selectionEnd=k}if(j!=null){var $=function(U,X){var P=U.x,Z=U.y+U.n,Y=new eh;
Y.translate(-P,-Z);Y.rotate(-X);Y.translate(P,Z);U.y+=U.n*.27;var a=E.p.Wx(U);E.p.D(a.w,Y,a.w);return a};
if(g==k){g=Math.max(g,0);var C=j.ic(g);if(C){var f=C.WH,z=this.Yo.Hu.lJ.FontSize;if(z!=null&&z!=0){z/=W.D.NW();
f.y+=f.n-z;f.n=z}var s=j.axu(g);if(s!=null&&s.G7==1)f.x+=f.m;var O=$(f,C.Tg).w;w.I.VZ.F.push("M","L");
w.I.VZ.w.push(O[0],O[1]-1,O[6],O[7]-1)}}else{w.I.Im={w:[],F:[]};for(var L=g;L<k;L++){var C=j.ic(L),a=$(C.WH,C.Tg);
E.p.concat(w.I.Im,a)}}}w.I.VZ=aj.W4(w.I.VZ,W,j);w.I.Im=aj.W4(w.I.Im,W,j);w.I.cc=aj.W4({w:w.I.cc},W,j).w;
w.RP=!0};y.hr.prototype.a4F=function(w,n,W){if(W==null)return;w.I.cc.push(0,0);if(w.I.VZ==null)w.I.VZ={F:[],w:[]};
for(var L=0;L<W.ci.length;L++){var D=W.ci[L];for(var j=0;j<D.Uv.length;j++){var I=D.Uv[j],U=D.zt.x+I.zt.x+I.WH.x,M=D.zt.y+I.zt.y+I.WH.y+I.WH.n;
w.I.VZ.F.push("M","L");w.I.VZ.w.push(U,M,U+I.WH.m,M)}}w.RP=!0};y.ahZ=function(){y.hr.call(this,!0)};
y.ahZ.prototype=new y.hr;y.Et=function(){y.eZ.call(this,[10,9],y.GO,"tools/lasso");this.t1="crosshair";
this.YA=null;this.gj=null;this.yu=null};y.Et.prototype=new y.eZ;y.Et.prototype.jx=function(w,n,W,D){this.YA=this.gs;
this.gj={w:[this.YA.x,this.YA.y],F:["M"]}};y.Et.prototype.Gi=function(w,n,W,D){this.yu=D;var j=this.gj;
if(j==null)return;if(!D.WS){if(this.gj!=null&&this.Y7.i6(1)&&W.U(aK.PJ)){j.w.pop();j.w.pop();j.w.push(this.Gs.x,this.Gs.y);
w.I.VZ=j;w.RP=!0}return}j.F.push("L");j.w.push(this.Gs.x,this.Gs.y);this.YA=this.Gs;if(this.xs){w.I.VZ=j;
w.RP=!0}};y.Et.prototype.wb=function(){return this.gj!=null};y.Et.prototype.rT=function(){return this.gj!=null};
y.Et.prototype.oe=function(w,n,W,D){y.eZ.prototype.oe.call(this,w,n,W,D);if(this.gj&&this.Y7.i6(1)&&this.yu&&!this.yu.WS&&!D.U(aK.PJ))this.ajH(w,W,D)};
y.Et.prototype.WB=function(w,n,W,D){this.yu=D;var j=this.gj;if(j==null)return;if(this.Y7.i6(1)&&W.U(aK.PJ)){j.F.push("L");
j.w.push(this.Gs.x,this.Gs.y);return}this.ajH(w,n,W)};y.Et.prototype.ajH=function(w,n,W){this.finish(w,n,W,this.yu);
this.gj=null;w.I.VZ=null;w.RP=!0};y.Et.prototype.getSelection=function(w,n,W,D){if(this.gs.s9(this.Gs)||!this.xs)return null;
return y.eZ.KI(this.gj.w,null,this.RQ.anta)};y.mU=function(){y.qw.call(this,[10,11],y.Rv,"tools/move");
this.qZ=new ec(0,0);this.MK=new ec(0,0);this.tJ=null;this.hy=null;this.Cr=new ec(0,0);this.HI=null;this.ww=null;
this.xh=null;this.ft=0;this.sJ=null;this.Qf=[];this.IJ=null;this.Ry=null;this.Hr=!1;this.d=0;this.g8=null;
this.l3=null;this.n6=null;this.n5=!1;this.RQ={az:!0,Qe:!1,TH:!1,a6H:1};this.asf=!1;this.aqZ=!1;this.yU=null;
this.t8=null;this.wP=null;var w=[];for(var L=0;L<E.f_.Ph.length;L++)w.push({name:E.f_.Ph[L],r:function(n,W,D){return{hO:W.M3.Lf==D}}});
this.fU=new cA(w);this.fU.h("select",this.zs,this)};y.mU.prototype=new y.qw;y.qw.prototype.LL=function(w){return this.Hr&&this.d!=2};
y.mU.prototype.age=function(){return this.Hr&&(this.d==0||this.d==1)};y.mU.prototype.Lp=function(w,n,W,D){this.jQ(w,-this.Cr.x,-this.Cr.y);
this.Cr.y1(0,0);this.qv(w,null,W);this.nA(w)};y.mU.prototype.Th=function(){var w=this.RQ;return[w.az?1:0,w.Qe?1:0,w.TH?1:0]};
y.mU.prototype.QW=function(w,n,W){var D=this.RQ;if(w&&w[0]!=null)D.az=w[0]==1;if(w&&w[1]!=null)D.Qe=w[1]==1;
if(w&&w[2]!=null)D.TH=w[2]==1;var j=new ed(b.E.L,!0);j.data={d:b.c.Bg,G:this.id,LQ:D,adr:n};W.S(j)};
y.mU.akQ=function(w,n,W,D,j,I,U){if(U==null)U=[!1,!0];var M=w.qu(null,j,!0),m,l;if(w.add.artd&&w.g.length==1&&w.C[w.g[0]].add.artb){var g=w.C[w.g[0]].yP();
m=w.nT(M,g,g)[0]}else{var k=new iB(0,0,w.m,w.n),m=w.nT(M,U[0]?k:null,U[1]?null:k)[0];delete m.add.artd;
if(U[1]){var $=E.tx(m.Vc(),new iB(0,0,m.m,m.n),2);y.QJ.Ov(m,$)}}if(W!=1){var C=new iB(0,0,Math.round(m.m*W),Math.round(m.n*W));
y.QJ.Ov(m,C);var f=[];for(var L=0;L<m.C.length;L++)f.push(L);var z=y.wR.ZQ(m,f,!0);y.QJ._O(m,new eh(W,0,0,W,0,0));
y.wR.At(m,D,f,z,1,E.K.yT(new eh(W,0,0,W,0,0)),null,!0);m.tw()}else if(l){m.l();m.tw()}var s=[];for(var L=0;
L<n.length;L++)if(m.m*m.n!=0)s.push(jj.rk(m,n[L].toUpperCase(),null,null,I?I[L]:null,D));return s};y.mU.prototype.arw=function(w,n,W,D,j){if(w==null||w.g.length==0)return;
var I=y.mU.akQ(w,[n],W,D,null)[0],U=new ed(b.E.L,!0);U.data={d:b.c.pA,data:I,name:w.C[w.g[0]].getName()+(W==1?"":"@"+W+"x")+"."+n};
j.S(U)};y.mU.prototype.sm=function(w,n,W,D,j){if(w.vK=="getPNG"){this.arw(W,"png",w.dI,j,n)}else if(w.vK=="getSVG"){this.arw(W,"svg",w.dI,j,n)}if(w.vK=="prms"){this.RQ=w;
this.nA(W)}};y.mU.ayA=function(w){var bK=w.length,W=0;w.sort(function(I,U){return I[0]+I[1]/2-(U[0]+U[1]/2)});
var n=w[bK-1][0]+w[bK-1][1]-w[0][0];for(var L=0;L<bK;L++)W+=w[L][1];var D=Math.round((n-W)/(bK-1)),j=w[0][0];
for(var L=0;L<bK;L++){w[L][0]=j;j+=w[L][1]+D}};y.mU.prototype.Al=function(w,n,W,D,j){var I=w.d;if(I=="trsl"){var U=Math.round(w.Bi),M=Math.round(w.ah);
this.Cr.y1(U,M);this.EF(W,n,D,j,!1,w.j);this.jQ(W,U,M);this.qv(W,null,j)}else if(I=="fcmy"||I=="fvec"){var m=["RGB","CMYK"][w.Z]+" Color";
if(I=="fvec")m=["Raster","Vector"][w.Z]+" Mode";var l=new go(m,this);l.data={d:w.d,Z1:W.add[I]==null?0:W.add[I],qY:w.Z};
W.kK(l);this.Fd(l.data,W)}else if(I=="pview"){var I=new go([8,14],this);I.data={d:w.d};W.kK(I);this.Fd(I.data,W)}else if(I=="lockguides"){if(W)W.PK=!W.PK}else if(I=="gids"||I=="gidsFromLayer"){var A=w.l3,g,k;
if(A==null)A=W.Iw();if(I=="gids"){g=w.Qh;var $=A[0].length,C=g[0].length;k=$==C?[23,2]:$>C?[23,3]:[23,4];
if(C==0)k=[11,15,0]}else if(I=="gidsFromLayer"){var f=[],z=[],s=W.H2();for(var L=0;L<W.g.length;L++){var O=W.C[W.g[L]].rect;
if(O.VY())continue;f.push([0,O.x],[1,O.y],[0,O.x+O.m],[1,O.y+O.n]);z.push(s,s,s,s)}k=[11,15,1];g=W.Iw();
y.mU.w6(g,[f,z])}if(JSON.stringify(A)==JSON.stringify(g))return;var I=new go(k,this);I.data={d:2,l3:A,Qh:g};
W.kK(I);this.Fd(I.data,W)}else if(I=="algn"){var a=w.Z;if(W==null)return;if(W.g.length<2&&!(W.J!=null&&a!=3&&a!=7)){alert(fV.get([15,7,5]));
return}var X=W.J;W.J=null;var O=X?X.rect:y.wR.pJ(W);this.EF(W,n,D,j,!1);if(!this.Hr)return;var P=this.sJ,Z={},Y=[],K=[],S=[];
for(var L=0;L<P.length;L++){var G=P[L];while(W.C[G].getName()=="</Layer group>")G++;var V=W.root.fs(G),T=V;
while(V.parent!=null){V=V.parent;if(P.indexOf(V.index)!=-1)T=V}var R=K.indexOf(T.index);if(R==-1){R=K.length;
K.push(T.index)}Y[L]=R}var x=[],v=[],N=[];for(var L=0;L<K.length;L++){var u=y.wR.pJ(W,W.qu(!0,K[L]));
N.push(u);var H=a==3?[u.y,u.n]:[u.x,u.m];x[L]=H;v.push(H)}y.mU.ayA(v);for(var L=0;L<K.length;L++){var u=N[L],F=u.x,t=u.y;
if(a==0)F=O.x;if(a==1)F=O.x+(O.m-u.m)/2;if(a==2)F=O.x+(O.m-u.m);if(a==3)t=x[L][0];if(a==4)t=O.y;if(a==5)t=O.y+(O.n-u.n)/2;
if(a==6)t=O.y+(O.n-u.n);if(a==7)F=x[L][0];S.push(Math.round(F-u.x),Math.round(t-u.y))}var o=[];for(var L=0;
L<P.length;L++){var q=Y[L];o[2*L]=S[2*q];o[2*L+1]=S[2*q+1]}this.jQ(W,0,0,null,o);var _=a==3||a==7?[20,4,6]:[20,4,a<3?a:a-1];
this.qv(W,null,j,o,_);W.J=X}else if(I=="disabAuto"){this.QW([!1],null,n)}};y.mU.w6=function(w,n){for(var L=0;
L<n[0].length;L++){var W=n[0][L],D=n[1][L],j=!1;for(var I=0;I<w[0].length;I++){var U=w[0][I],M=w[1][I];
if(W[0]==U[0]&&W[1]==U[1]&&D==M)j=!0}if(!j){w[0].push(W.slice(0));w[1].push(D)}}};y.mU.prototype.enable=function(w,n,W,D,j){this.ww=W;
this.xh=n;this.n5=j?!0:!1;this.nA(w);this.eg("default",n);this.oe(w,n,W,D)};y.mU.prototype.disable=function(w,n,W,D){this.a67(w)};
y.mU.prototype.a67=function(w){if(w==null)return;if(this.yU){this.yU.clear(w);this.yU=null}if(w.I.TH){w.I.TH=null;
w.RP=!0}if(w.I.t7){w.I.t7=null;w.RP=!0}if(w.I.hF[this.id]){delete w.I.hF[this.id];w.RP=!0}if(w.I.r7.length!=0){w.I.r7=[];
w.RP=!0}};y.mU.prototype.BW=function(w,n,W,D){if(W.No!=this.id)return;this.nA(w)};y.mU.prototype.nA=function(w,n){if(w==null)return;
var W=this.RQ;this.a67(w);if(!this.n5){var D;if(W.Qe||W.TH)D=E.p.fF(y.wR.pJ(w));if(W.Qe&&!D.VY()){this.yU=new gX([D.x,D.y,D.x+D.m,D.y,D.x+D.m,D.y+D.n,D.x,D.y+D.n],!0);
this.yU.qz(w,this.ww)}if(W.TH){var j=null,A=null,g=!1;if(w.H2()!=-1)j=w.C[w.H2()].yP();else j=new iB(0,0,w.m,w.n);
w.I.TH={yi:[D],eF:[]};var I=w.I.TH.eF,U=D.x+D.m,M=D.y+D.n,m=D.x+Math.floor(D.m/2),l=D.y+Math.floor(D.n/2);
if(n){var k=w.root.pw(new ec(Math.floor(n.x),Math.floor(n.y)));if(k){A=E.p.fF(k.j.$k(w));if(A.L0(D)){g=(A.Yy(D)||D.Yy(A))&&!D.s9(A);
if(!g)A=null}}}this.abO(D,I);if(A!=null){w.I.TH.yi.push(A);var $=A.x+A.m,C=A.y+A.n,f=A.x+Math.floor(A.m/2),z=A.y+Math.floor(A.n/2);
if(g){var s=m,O=l;if(D.Yy(A)){s=f;O=z}I.push(D.x,O,A.x,O);I.push(U,O,$,O);I.push(s,D.y,s,A.y);I.push(s,M,s,C)}else{this.abO(A,I);
var a=M<A.y||C<D.y,X=U<A.x||$<D.x;if(U<A.x)I.push(U,l,A.x,l);if($<D.x)I.push($,l,D.x,l);if(M<A.y)I.push(m,M,m,A.y);
if(C<D.y)I.push(m,C,m,D.y);if(a&&!X){if(D.x<A.x)I.push(D.x,z,A.x,z);if(A.x<D.x)I.push(A.x,l,D.x,l)}}}else{if(D.y>j.y)I.push(m,j.y,m,D.y);
if(M<j.y+j.n)I.push(m,M,m,j.y+j.n);if(D.x>j.x)I.push(j.x,l,D.x,l);if(U<j.x+j.m)I.push(U,l,j.x+j.m,l)}w.RP=!0}}if(this.d==2&&this.Hr){var P=new iB(0,0,w.m,w.n),Z=w.H2();
if(Z!=-1){var Y=w.Iw(),K=Y[1][this.sJ];if(K==-1)K=Z;P=w.C[K].yP()}var S=w.jg[this.sJ],G=S[0],V=(G==0?"X":"Y")+": "+E.f_.BE(S[1]-(G==0?P.x:P.y),w.hh,this.ww,G==0?P.m:P.n,!0);
y.qw.A1(Math.round(this.tJ.x)+10,Math.round(this.tJ.y)-10,[V],w);w.RP=!0}if(this.d==3&&this.Hr){var T=E.p.Wx(this.g8);
w.I.hF[this.id]={VZ:T};w.RP=!0}};y.mU.prototype.abO=function(w,n){var W=w.m,D=w.n,j=w.x+Math.floor(W*.2),I=w.y+Math.floor(D*.2);
n.push(j,w.y,j,w.y+D);n.push(w.x,I,w.x+W,I)};y.mU.prototype.eg=function(w,n){var W={d:b.c.ph,In:w},D=new ed(b.E.L,!0);
D.data=W;n.S(D)};y.mU.prototype.pU=function(w){var n=this.t8.aJ()[0];if(n==this.wP.length){var W=new ed(b.E.L,!0);
W.data={d:b.c.J6,$x:"psd"};this.xh.S(W);return}var D=this.HI,j=this.wP[n];this.au7(D,j)};y.mU.prototype.zs=function(w){var n=JSON.parse(JSON.stringify(this.ww.M3));
n.Lf=this.fU.aJ()[0];var W=new ed(b.E.L,!0);W.data={d:b.c.oj,AH:bk.OS,qY:n};this.xh.S(W)};y.mU.prototype.cF=function(w,n,W,D,j){if(this.Hr)this.H5(w,n,W,D,j);
this.HI=w;this.ww=W;this.xh=n;var I=w.u.Cg(j.x,j.y),U;if(y.mU.cz(W,j,w.u)){U=this.fU}else{if(this.t8)this.t8.removeEventListener("select",this.pU);
var M=[];w.root.pw(I,M);if(M.length==0)return;var m=[];this.wP=M;for(var L=0;L<M.length;L++)m.push({name:w.C[M[L]].getName(),nW:L==M.length-1});
m.push({name:[1,18],$r:!0});U=this.t8=new cA(m);U.h("select",this.pU,this)}U.parent=n;U.f();U.update(w,W);
var l=new ed(b.E.L,!0);l.data={d:b.c.Uq,BT:U,x:j.Qc+2,y:j.tc+1};n.S(l)};y.mU.prototype.amK=function(w,n,W,D,j){var I=y.mU.ff(w,j);
return I!=-1||y.mU.cz(W,j,w.u)};y.mU.ff=function(w,n){if(w==null||w.add.artd==null)return-1;var W=w.u.Cg(n.x,n.y),D=12*y.V()/w.u.N;
for(var L=0;L<w.C.length;L++){var j=w.C[L];if(!j.I4()||j.add.artb==null)continue;var I=j.yP(),U=new iB(I.x,I.y-1.7*D,D*j.getName().length*.5,D);
if(U.y5(W))return L}return-1};y.mU.prototype.WQ=function(w,n,W,D,j){var I=y.mU.ff(w,j),U=y.mU.abZ(w,w.u.Cg(j.x,j.y));
if(I!=-1){w.g=[I];if(W.No==y.Rv){var M=new ed(b.E.L);M.data={d:b.c.CV,G:y.yl};n.S(M)}return}if(U!=-1){w.u.PM=U;
w.tL=!0;var M=new ed(b.E.L,!0);M.data={d:b.c._y,jW:et.ip.anu};n.S(M);return}this.tJ=j;this.qZ.y1(j.x,j.y);
this.MK=w.u.Cg(j.x,j.y);this.hy=new h3(this.MK);this.EF(w,n,D,W,!0)};y.mU.cz=function(w,n,W,D){var j=E.f_.Nf,I=W.xq.n;
return w.fM&&(0<n.x&&n.x<j||0<n.y&&n.y<j||D&&0<n.x&&n.x<4*j&&I-j<n.y&&n.y<I)};y.mU.prototype.EF=function(w,n,W,D,j,I){var U,M=this.MK,m=!1;
if(j){var l=D.Ar&&D.M3.jg;if(y.mU.cz(D,this.qZ,w.u)){U=w.Iw();var A=w.Iw(),g=null;if(this.qZ.x<E.f_.Nf){g=[0,M.x]}if(this.qZ.y<E.f_.Nf){g=[1,M.y]}A[0].push(g);
A[1].push(w.H2(!0));w.Pu(A);if(!l){var k=new ed(b.E.L);if(!D.M3.jg){k.data={d:b.c.oj,AH:bk.pa};n.S(k)}if(!D.Ar){k.data={d:b.c.oj,AH:bk.Xh};
n.S(k)}l=!0}}var $=this.aqy(w,M);if(l&&$!=null&&!w.PK){this.d=2;this.l3=U?U:w.Iw();this.sJ=$;this.Hr=!0;
this.Ry=y.wR.pJ(w);return}if(w.v9.length!=0){this.d=4;this.Ry=w.yo[w.v9[0]].rect.clone();this.Hr=!0;
return}if(this.yU&&this.yU.G_(M,w.u.N,!0,this.tJ)!=null){var k=new ed(b.E.L);k.data={d:b.c.CV,G:y.Sv,asq:!0};
n.S(k);return}if(w.J&&w.J.rect.y5(M)){var C=Math.round(M.x),f=Math.round(M.y),z=w.J.rect;m=w.J.channel[(f-z.y)*z.m+C-z.x]>128}if(!m&&(!this.n5&&this.RQ.az||this.n5&&this.RQ.az&&(W.U(aK.WO)||w.g.length<2))){var s=this.akY(w,M,W);
if(!s){w.g=[];w.zS=null;w.rR=w.Uu=!0;this.d=3;this.g8=new iB;this.Hr=!0;return}}if(W.U(aK.PJ)&&!m){var O=new ed(b.E.v);
O.G=y.Yu;O.data={d:h.R6,a22:!0};n.S(O)}}if(w.v9.length!=0){this.d=4;this.Ry=w.yo[w.v9[0]].rect.clone();
this.Hr=!0;return}this.sJ=w.qu(I==null,I,null,!0);for(var L=0;L<this.sJ.length;L++){var a=this.sJ[L],X=w.C[a];
if(X.m7(2)||X.m7(31)||w.gr(a)){alert(fV.get([6,57,0]));return}}if(w.add.artd&&j){var P=this.sJ,Z=!1;
for(var L=0;L<P.length;L++)if(w.C[P[L]].add.artb)Z=!0;if(!Z){this.IJ=[w,w.C.slice(0),w.g.slice(0),-1];
this.sJ.sort(function(x,v){return x-v})}}this.Qf=y.mU.asw(w,this.sJ);this.d=0;if(w.J&&(!j||m)&&w.g.length==1&&w.d2(!1)){if(!w.aiC()){this.Hr=!1;
return}var Y=w.C[w.g[0]],K=W.U(aK.PJ);this.d=1;var S=w.history[w.QQ];if(S.G==this&&S.data.d==1&&S.data.j==w.g[0]&&Y.eL==Y.zZ.eL&&!K){this.n6=S}else{var G=Y.zZ,V=!1,T;
if(!Y.er(w,w.J)||K){V=!0;Y.Eo(w,w.J,K)}if(Y.zZ.eL<=0){T=E.Q(Y.zZ.WL.length>>2);E.hN(Y.zZ.WL,T,3)}else T=w.J.channel.slice(0);
var R={rect:Y.zZ.M0.clone(),channel:T};this.n6=new go(K?[12,53]:[12,54],this);this.n6.data={d:1,j:w.g[0],zZ:Y.zZ,Zw:G,vX:V,Py:w.J,TY:R,j7:new ec(0,0)};
w.kK(this.n6);w.J=R;w.Iq=!0}}this.Hr=!0;this.Ry=y.wR.pJ(w)};y.mU.prototype.akY=function(w,n,W){var D=w.root.pw(new ec(Math.floor(n.x),Math.floor(n.y)));
if(D){if(D.j.add.vmsk)w.RP=!0;var j=w.C.indexOf(D.j);if(this.RQ.a6H==0){var I=w.root.fs(j);while(I.parent&&I.parent.depth!=0&&I.parent.j.add.artb==null)I=I.parent;
j=I.index}if(W.U(aK.WO)){var U=w.g.indexOf(j);if(U==-1)w.g.push(j);else if(w.g.length>1)w.g.splice(U,1)}else if(w.g.indexOf(j)==-1){this.au7(w,j)}}return D!=null};
y.mU.prototype.au7=function(w,n){w.C[n].eL=0;w.g=[n];w.zS=null;w.jO();w.gL=!0;w.rR=!0};y.mU.abZ=function(w,n){var W=w.add.Anno;
if(W==null||W.length==0)return-1;var D=30/w.u.N;for(var L=0;L<W.length;L++)if(new iB(W[L][0],W[L][1],D,D).y5(n))return L;
return-1};y.mU.prototype.QD=function(w,n,W,D,j){this.tJ=j;var I=w.u.Cg(j.x,j.y),$,C;if(this.hy&&this.d<2)I=this.hy.db(I,D);
if(!this.Hr){if(W.Ar&&W.M3.jg&&w&&!w.PK){var U=this.aqy(w,I),M="default",m=y.mU.ff(w,j);if(U!=null)M=["col-resize","row-resize"][w.jg[U][0]];
else if(this.yU){var l=this.yU.G_(I,w.u.N,null,j);if(l)M=l}else if(m!=-1||y.mU.abZ(w,I)!=-1){M="pointer"}this.eg(M,n)}this.nA(w,I);
return}var A=this.MK,g=Math.round(I.x-A.x)-this.Cr.x,k=Math.round(I.y-A.y)-this.Cr.y;if(this.Ry){if(this.d==2){var f=[];
if(w.J)f.push(w.J.rect);if(this.Ry)f.push(this.Ry);if(w.u.Bn)f.push(w.u.Bn);I=y.mU.JW(w,I,W,[!1,f,!0])}else{C=this.Ry.clone();
C.offset(this.Cr.x+g,this.Cr.y+k);$=y.mU.uP(w,C,W);var z=this.hy.ate(D);if(z==1){$[0]=0;$[2]=1e9}if(z==2){$[1]=0;
$[3]=1e9}g+=Math.round($[0]);k+=Math.round($[1])}}this.Cr.x+=g;this.Cr.y+=k;var s=this.IJ;if(s&&w==s[0]){w.Gd(s[1]);
w.g=s[2].slice(0);s[3]=-1}this.jQ(w,g,k,I,null,D.U(aK.WO));if(s&&w==s[0]){var O=this.Ry.clone();O.offset(this.Cr.x,this.Cr.y);
var a=I,m=w.H2(),X=-1;for(var L=0;L<w.C.length;L++){var P=w.C[L];if(!P.I4()||P.add.artb==null)continue;
var Z=P.yP();if(Z.y5(a))X=L}if(X!=-1&&X!=m){var Y=y.G$._c(w,this.sJ,X,!0,null,!1);w.Gd(Y[0]);w.g=Y[1];
s[3]=X}}this.nA(w,I);if($)y.mU.Iy(w,C,$)};y.mU.prototype.aqy=function(w,n){var W=y.N5(w,this.tJ);n=[n.x,n.y];
var D=w.Iw(),j=w.H2();for(var L=0;L<D[0].length;L++){var I=D[0][L],U=D[1][L];if(U!=-1&&U!=j)continue;
if(Math.abs(I[1]-n[I[0]])<W)return L}return null};y.mU.prototype.jQ=function(w,n,W,D,j,I){if(this.d==0){if(j)y.mU.HA(w,this.sJ,this.Qf,j);
else y.mU.Gt(w,this.sJ,this.Qf,n,W)}else if(this.d==1){var U=this.n6.data;U.j7.offset(n,W);y.mU.SN(w,U.j,n,W)}else if(this.d==2){var M=1e-5;
if(I)M=w.u.N<=1?10:1;else if(w.u.N<=1)M=1;var m=M*Math.round(D.x/M),l=M*Math.round(D.y/M),A=[m,l],g=w.jg[this.sJ];
g[1]=A[g[0]]}else if(this.d==3){var k=this.MK,$=E.p.lV([k.x,k.y,D.x,D.y]);this.g8=$;var C=[];w.root.aq$($,C);
if(JSON.stringify(w.g)!=JSON.stringify(C)){w.g=C;w.rR=w.Uu=!0}}else if(this.d==4){for(var L=0;L<w.v9.length;
L++)w.yo[w.v9[L]].rect.offset(n,W);w.RP=!0}};y.mU.SN=function(w,n,W,D){var j=w.C[n];w.J.rect.offset(W,D);
j.p9(w,W,D,w.J);w.Iq=!0;w.l()};y.mU.prototype.H5=function(w,n,W,D,j,I){this.qv(w,j,W);this.nA(w);if(Date.now()-this.ft<300&&!I){var U=y.hr.c1(w,w.u.Cg(j.x,j.y));
if(y.mU.cz(W,j,w.u,!0)){var M=new ed(b.E.L);if(j.y>w.u.xq.n-20){M.data={d:b.c.P2,jW:"doczoom",Z1:w.u.N*100,j2:{Y:b.E.v,G:y.Nt,W:{d:"pzoom"}}}}else{M.data={d:b.c.P2,jW:"preferences"}}n.S(M)}else if(U>=0){var m=new ed(b.E.v,!0);
m.G=y.Lu;m.data={d:"editCurr",XT:U};n.S(m)}}this.ft=Date.now();y.QJ.xJ(w)};y.mU.prototype.qv=function(w,n,W,D,j){if(!this.Hr)return;
this.Hr=!1;if(this.d==0){if(D){this.azt(w,null,D,j)}else{if(this.Cr.x==0&&this.Cr.y==0)return;this.azt(w,this.Cr.clone())}w.tL=!0}else if(this.d==2){var I=0;
n=[n.x,n.y];var U=this.sJ,M=w.jg[U],b3=this.l3[0].length,m=w.jg.length;if(W.fM&&n[M[0]]<E.f_.Nf){var l=w.Iw();
l[0].splice(U,1);l[1].splice(U,1);w.Pu(l);I=1;if(b3==m-1)return}if(b3<m)I=2;var A=new go([[23,2],[23,3],[23,4]][I],this);
A.data={d:2,l3:this.l3,Qh:w.Iw()};w.kK(A)}else if(this.d==4){var A=new go([12,54],this);A.data={d:4,g:w.v9.slice(0),R:this.Cr.clone()};
w.kK(A)}this.Cr.y1(0,0)};y.mU.prototype.oe=function(w,n,W,D){var j=D.aa(w?w.u.Tg:0);if(w!=null&&(j.x!=0||j.y!=0)){if(D.U(aK.PJ)&&w.J==null){var I=new ed(b.E.v);
I.G=y.Yu;I.data={d:h.R6,a22:!0};n.S(I)}this.Cr.y1(j.x,j.y);this.EF(w,n,D,W,!1);if(!this.Hr)return;this.jQ(w,j.x,j.y);
this.qv(w,null,W);this.nA(w)}var U=D.U(aK.CQ);if(!this.n5&&this.aqZ!=U){if(U){this.asf=this.RQ.az;this.RQ.az=!0}else{this.RQ.az=this.asf}this.aqZ=U;
var M=new ed(b.E.L,!0);M.data={d:b.c.Bg,G:this.id,LQ:this.RQ};n.S(M)}};y.mU.prototype.ZE=function(w,n){if(w.d==0){var W=w.Vs;
if(W){n.Gd(W.VQ);n.g=W.Sz.slice(0);n.l();n.rR=!0}y.mU.HA(n,w.g,w.ek,w.u7,!0);y.QJ.xJ(n)}else if(w.d=="fcmy"||w.d=="fvec"){if(w.Z1==0)delete n.add[w.d];
else n.add[w.d]=w.Z1;n.RP=!0}else if(w.d=="pview"){n.v_=!n.v_;n.l()}else if(w.d==2){n.Pu(w.l3);n.RP=!0}else if(w.d==4){for(var L=0;
L<w.g.length;L++)n.yo[w.g[L]].rect.offset(-w.R.x,-w.R.y);n.RP=!0}else{var D=n.C[w.j];if(w.vX){D.$H(n,w.Zw);
n.J=w.Py;n.Iq=!0;n.l();D.l()}else{y.mU.SN(n,w.j,-w.j7.x,-w.j7.y)}}};y.mU.prototype.Fd=function(w,n){if(w.d==0){y.mU.HA(n,w.g,w.ek,w.u7);
var W=w.Vs;if(W){n.Gd(W._B);n.g=W.zu.slice(0);n.l();n.rR=!0}y.QJ.xJ(n)}else if(w.d=="fcmy"||w.d=="fvec"){if(w.qY==0)delete n.add[w.d];
else n.add[w.d]=w.qY;n.RP=!0}else if(w.d=="pview"){n.v_=!n.v_;n.l()}else if(w.d==2){n.Pu(w.Qh);n.RP=!0}else if(w.d==4){for(var L=0;
L<w.g.length;L++)n.yo[w.g[L]].rect.offset(w.R.x,w.R.y);n.RP=!0}else{var D=n.C[w.j];if(w.vX){D.zZ=w.zZ;
n.J=w.TY;y.mU.SN(n,w.j,0,0);D.l()}else{y.mU.SN(n,w.j,w.j7.x,w.j7.y)}}};y.mU.prototype.azt=function(w,n,W,D){if(W){var j=!0;
for(var L=0;L<W.length;L++)if(W[L]!=0)j=!1;if(j)return}var I=w.history[w.QQ],U=this.IJ,M=U!=null&&U[3]!=-1&&U[0]==w;
if(!M&&W==null&&I.data&&I.G==this&&I.data.d==0&&JSON.stringify(I.data.g)==JSON.stringify(this.sJ)&&JSON.stringify(I.data.ek)==JSON.stringify(this.Qf)){var m=I.data.u7,l=I.data.a0f.E3.T.v;
l.Hrzn.v.val+=n.x;l.Vrtc.v.val+=n.y;for(var L=0;L<m.length;L+=2){m[L]+=n.x;m[L+1]+=n.y}}else{if(n==null)n=new ec(W[0],W[1]);
var A={hZ:"move",E3:{classID:"null",null:cq.Pz("Lyr",!0),T:{t:"Objc",v:{classID:"Ofst",Hrzn:{t:"UntF",v:{type:"#Rlt",val:n.x}},Vrtc:{t:"UntF",v:{type:"#Rlt",val:n.y}}}}}},g=null;
if(M)g={VQ:U[1],Sz:U[2],_B:w.C.slice(0),zu:w.g.slice(0)};this.IJ=null;var k=new go(D?D:[12,54],this);
if(W)k.data={d:0,g:this.sJ,ek:this.Qf,Vs:g,u7:W};else k.data={d:0,g:this.sJ,ek:this.Qf,Vs:g,u7:y.mU.arl(this.sJ,n.x,n.y)};
k.data.a0f=A;w.kK(k);this.track(A)}};y.mU.arl=function(w,n,W){var D=[];for(var L=0;L<w.length;L++)D.push(n,W);
return D};y.mU.Gt=function(w,n,W,D,j){y.mU.HA(w,n,W,y.mU.arl(n,D,j))};y.mU.HA=function(w,n,W,D,j){if(n.length==0)return;
if(W==null){W=[];for(var L=0;L<n.length;L++){W.push(w.C[n[L]].V6(w,!0))}}var I=new iB,U=new iB(0,0,w.m,w.n);
for(var L=0;L<n.length;L++){var M=D[2*L],m=D[2*L+1];if(j){M=-M;m=-m}var l=w.C[n[L]],A=W[L];if(l.add.fxrp&&(A.indexOf(0)!=-1||l.I9()))l.add.fxrp.offset(M,m);
for(var g=0;g<A.length;g++){var k=A[g];if(k==0){l.rect.offset(M,m);if(l.YC()&&l.NP(w))l.NP(w).rect.offset(M,m);
if(l.add.artb){var $=l.yP();$.offset(M,m);l.MR($);var C=l.add.artb.guideIndeces;C=C?C.v:[];for(var f=0;
f<C.length;f++){var z=w.jg[C[f].v];z[1]+=z[0]==0?M:m}}if(l.add.TySh){l.add.TySh.D.translate(M,m);if(l.add.TySh.add){l.add.TySh.add.vmsk.offset(M,m)}}if(l.add.SoLd){var s=new eh(1,0,0,1,M,m),O=l.add.SoLd,a=y.wR.Aa(O.Trnf),X=y.wR.Aa(O.nonAffineTransform);
E.p.D(a,s,a);E.p.D(X,s,X);O.Trnf=y.wR.Hh(a);O.nonAffineTransform=y.wR.Hh(X);y.wR.a6n(O,s)}}if(k==1)l._N().rect.offset(M,m);
if(k==2){l.add.vmsk.offset(M,m);if(l.add.vogk)E.X.D(l.add.vogk,[1,0,M,0,1,m,0,0],[]);if(l.US.gj){var P=l.US.gj.VN.w;
E.p.D(P,new eh(1,0,0,1,M,m),P)}}if(k==3){l.NP(w).z.rect.offset(M,m);if(A.length==1)l.l()}}if(A.length>0){var Z=l.add.GdFl;
if(Z==null)Z=l.add.PtFl;if(l.I9()&&!l.f6()&&l.add.vmsk!=null&&E.P.dX(l.add.vmsk.i)&&l.add.vmsk.MX==255&&(Z==null||Z.Algn&&Z.Algn.v)){l.rect.offset(M,m)}else l.yb(w);
var Y=w.root.a7(l.$k(w),w,n[L]);if(l.add.artb)Y=Y.x0(l.yP());I=I.x0(Y);Y.offset(-M,-m);I=I.x0(Y);if(l.Jp()&&l.z&&l.z.color==255)I=I.x0(U);
l.aqs()}}w.l(E.p.fF(I))};y.mU.asw=function(w,n){var W=[];for(var L=0;L<n.length;L++){var D=w.C[n[L]];
W.push(D.V6(w))}return W};y.mU.Iy=function(w,n,W){var D={w:[],F:[]},j=n.x+W[0],I=n.y+W[1];if(W[2]!=1e9){D.F.push("M","L");
var U=I+n.n;if(W[4])D.w.push(W[2],Math.min(I,U,W[4][1]),W[2],Math.max(I,U,W[4][1]));else D.w.push(W[2],I,W[2],I+n.n)}if(W[3]!=1e9){D.F.push("M","L");
var M=j+n.m;if(W[5])D.w.push(Math.min(j,M,W[5][0]),W[3],Math.max(j,M,W[5][0]),W[3]);else D.w.push(j,W[3],M,W[3])}if(D.w.length!=0){w.I.t7=D;
w.RP=!0}};y.mU.JW=function(w,n,W,D){var j=y.mU.anP(w,[[n.x],[n.y]],W,D);return new ec(n.x+j[0],n.y+j[1])};
y.mU.uP=function(w,n,W,D,j){var I=j==!0?1:.5,U=y.mU.anP(w,[[n.x,n.x+Math.round(n.m*I),n.x+n.m],[n.y,n.y+Math.round(n.n*I),n.y+n.n]],W,D);
return U};y.mU.anP=function(w,n,W,D){if(D==null)D=[!0,null,!0];var j=[0,0,1e9,1e9,null,null];if(!W.CF)return j;
var I=JSON.parse(JSON.stringify(n));for(var U=0;U<2;U++){var M=1e9,m=n[U],l=0,A=null;for(var g=0;g<m.length;
g++){var k=y.mU.asn(w,m[g],I[1-U][g],U,W,D),$=k[0];if($!=1e9)I[U][g]=$;if($!=1e9&&Math.abs($-m[g])<Math.abs(M)){M=$-m[g];
l=$;A=k[1]}}if(M!=1e9){j[U]=M;j[U+2]=l;j[U+4]=A}}return j};y.mU.asn=function(w,n,W,D,j,I){var U=1e9,M=null,m=j.PW,l=j.M3,A=[w.root];
while(A.length!=0&&m[2]){var g=A.pop(),k=g.j,$=k.rect;if(!k.I4())continue;if(g.children)for(var L=0;
L<g.children.length;L++)A.push(g.children[L]);if(w.g.indexOf(g.index)!=-1||$.VY())continue;var C=$.m,f=C>>>1,z=$.n,s=z>>>1,O=U;
if(D==0){if(Math.abs($.x-n)<Math.abs(U-n))U=$.x;if(Math.abs($.x+f-n)<Math.abs(U-n))U=$.x+f;if(Math.abs($.x+C-n)<Math.abs(U-n))U=$.x+C}else{if(Math.abs($.y-n)<Math.abs(U-n))U=$.y;
if(Math.abs($.y+s-n)<Math.abs(U-n))U=$.y+s;if(Math.abs($.y+z-n)<Math.abs(U-n))U=$.y+z}if(O!=U){M=[$.x+f,$.y+s]}}var a=U;
U=1e9;if(I[0]&&m[0]&&l.jg&&j.Ar){var X=w.Iw(),P=X[0],Z=X[1],Y=w.H2();for(var L=0;L<P.length;L++)if((Z[L]==-1||Z[L]==Y)&&P[L][0]==D&&Math.abs(P[L][1]-n)<Math.abs(U-n))U=P[L][1]}if(m[1]&&l.Vk&&j.Ar){var K=Math.round(E.f_.M_(l.Jt,w.hh,w.m,l.Cp));
if(D==1&&l.df==1){var S=W*.5*Math.sqrt(4/3),G;K*=Math.sqrt(4/3);G=Math.round((n-S)/K)*K+S;if(Math.abs(G-n)<Math.abs(U-n))U=G;
G=Math.round((n+S)/K)*K-S;if(Math.abs(G-n)<Math.abs(U-n))U=G}else{var G=Math.round(n/K)*K;if(Math.abs(G-n)<Math.abs(U-n))U=G}}var V=w.ej;
if(m[3]&&l.ej&&j.Ar&&V.length!=0){for(var L=0;L<V.length;L++){if(!I[2]&&w.UF.indexOf(L)!=-1)continue;
var T=y.mk.uw(V,L);for(var R=0;R<3;R+=2)if(T[R+D]!=n&&Math.abs(T[R+D]-n)<Math.abs(U-n))U=T[R+D]}}if(I[1])for(var x=0;
x<I[1].length;x++){var $=I[1][x],C=$.m,z=$.n,v=[$.x,$.y,$.x+(C>>>1),$.y+(z>>>1),$.x+C,$.y+z];for(var L=0;
L<6;L+=2)if(Math.abs(v[L+D]-n)<Math.abs(U-n))U=v[L+D]}if(m[4]){var $=new iB(0,0,w.m,w.n),Y=w.H2();if(Y!=-1)$=w.C[Y].yP();
var C=$.m,z=$.n,v=[$.x,$.y,$.x+(C>>>1),$.y+(z>>>1),$.x+C,$.y+z];for(var L=0;L<6;L+=2)if(Math.abs(v[L+D]-n)<Math.abs(U-n))U=v[L+D]}if(Math.abs(U-n)<=Math.abs(a-n))M=null;
else U=a;var N=Math.abs(U-n)<=4*y.V()/w.u.N?U:1e9;return[N,M]};y.KF=function(){y.eZ.call(this,[10,12],y.Y5,"tools/mwand");
this.xB=null};y.KF.prototype=new y.eZ;y.KF.prototype.Th=y.eZ.prototype.axk;y.KF.prototype.QW=y.eZ.prototype.ark;
y.KF.prototype.jx=function(w,n,W,D){this.xB=D;this.aqT=this.RQ.wconf[0];this.finish(w,n,W,D)};y.KF.prototype.Gi=function(w,n,W,D,j){if(!D.WS)return;
var I=new ed(b.E.v);I.G=y.eb;I.data={d:"h_stepbck"};j.S(I);var U=D.x-this.xB.x,M=Math.max(0,Math.min(255,Math.round(this.aqT+U/4)));
this.RQ.wconf[0]=M;this.ts(j);this.finish(w,n,W,this.xB)};y.KF.prototype.WB=function(w,n,W,D,j){this.RQ.wconf[0]=this.aqT;
this.ts(j)};y.KF.prototype.getSelection=function(w,n,W,D){var j=this.Gs;j=w.u.Cg(D.x,D.y);var I=y.eZ.aba(new ec(Math.floor(j.x),Math.floor(j.y)),this.RQ.wconf,this.RQ.sall);
return I};y.KF.axY=function(w,n,W,D,j){if(n.x<0||n.x>w.m||n.y<0||n.y>w.n)return null;var I,U=new iB(0,0,w.m,w.n);
if(D)I=w.Vc();else{var M=w.g.length,l=null;if(M!=1){alert(M==0?"No layer selected.":"More than one layer selected.");
return null}var m=w.C[w.g[0]];if(j)l=m.eL<=0?null:m.eL==1?m._N():m.NP(w).z;if(l==null&&m.add.lsct!=null&&m.add.lsct!=ef.Zd){alert("No layer selected.");
return null}if(l==null&&U.s9(m.rect))I=m.buffer;else{I=E.Q(U.O()*4);if(l==null)E.Cb(m.buffer,m.rect,I,U);
else y.JT.gv(l.channel,l.rect,l.color,I,U)}}var A=y.KF.Yi(I,U,n,null,W),g=E.Nb(A,U),k=E.Q(g.O());E.B0(A,U,k,g);
return{rect:g,channel:k}};y.KF.Kt=function(w,n,W){var D=n.m,j=n.n,U=0,M=0,m=0,l=0;w=new Uint32Array(w.buffer);
var I=[],A=W.length;for(var L=0;L<A;L++){var g=W[L],k=Math.round(g.x-.5-n.x),$=Math.round(g.y-.5-n.y);
k=Math.max(0,Math.min(D-1,k));$=Math.max(0,Math.min(j-1,$));var C=$*D+k,f=w[C];I.push([f&255,f>>8&255,f>>16&255,f>>>24])}return I};
y.KF.Yi=function(w,n,W,D,j){w=new Uint32Array(w.buffer);var I=n.m,U=n.n,M=I*U;if(D==null)D=y.KF.Kt(w,n,[W]);
var m=Math.round(W.x-.5-n.x),l=Math.round(W.y-.5-n.y),A=l*I+m,g=Date.now(),k=E.Q(I*U),$=j[0],C=1/$,f=j[1]&&$>0?255:0;
if(j[2]){var z=E.Q(k.length),s=new Uint32Array(M),O=1;s[0]=m<<16|l;z[A]=1;while(O>0){var a=s[O-1];O--;
var X=a>>>16,P=a&65535,L=P*I+X,Z=y.KF.ex(w[L],D);if(Z>$){var Y=f*(1-Math.max(0,Math.min(1,(Z-$)*C)));
k[L]=~~Y}else{k[L]=255;if(P!=U-1&&z[L+I]==0){s[O++]=X<<16|P+1;z[L+I]=1}if(P!=0&&z[L-I]==0){s[O++]=X<<16|P-1;
z[L-I]=1}if(X!=I-1&&z[L+1]==0){s[O++]=X+1<<16|P;z[L+1]=1}if(X!=0&&z[L-1]==0){s[O++]=X-1<<16|P;z[L-1]=1}}}}else{for(var L=0;
L<M;L++){var Z=y.KF.ex(w[L],D);if(Z<=$)k[L]=255}for(var P=0;P<U;P++)for(var X=0;X<I;X++){var L=P*I+X;
if(k[L]==0&&(X>0&&(k[L-1]==255||P>0&&k[L-I-1]==255||P<U-1&&k[L+I-1]==255)||X<I-1&&(k[L+1]==255||P>0&&k[L-I+1]==255||P<U-1&&k[L+I+1]==255)||P>0&&k[L-I]==255||P<U-1&&k[L+I]==255)){var Z=y.KF.ex(w[L],D),Y=f*(1-Math.max(0,Math.min(1,(Z-$)*C)));
k[L]=~~Y}}}return k};y.KF.ex=function(w,n){var W=n.length,D=y.KF.am3(w,n[0]),L=1;while(L!=W){D=Math.min(D,y.KF.am3(w,n[L]));
L++}return D};y.KF.am3=function(w,n){var W=w&255,D=w>>>8&255,j=w>>>16&255,I=w>>>24&255;if(n[3]==0)return I<5?0:255;
var U=Math.max(Math.abs(W-n[0]),Math.max(Math.abs(D-n[1]),Math.abs(j-n[2])));return I==0?255:U};y.QU=function(w,n){if(n)y.JT.call(this);
else if(w)y.JT.call(this,[10,49],y.i5,"tools/camove");else y.JT.call(this,[10,26],y.FS,"tools/patch");
this.YA=null;this.gj=null;this.R=null;this.zt=null;this.Rq=new ec;this.JG=null;this._f=null};y.QU.prototype=new y.JT;
y.QU.prototype.WQ=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);if(w.J&&E.pw(I,w.J.channel,w.J.rect)){var U=new iB(0,0,w.m,w.n),M=U.wU(w.J.rect);
if(!w.d2()||M.VY())return;if(!0){var m=E.Q(M.O());E.B0(w.J.channel,w.J.rect,m,M);w.J={channel:m,rect:M}}this.W5(w);
this.R9(w);this.zt=I;this.Rq=new ec(I.x-w.J.rect.x,I.y-w.J.rect.y);this._f=E.Q(w.J.rect.O()*4);this._f.fill(255);
if(this.RQ.patch==1){var l=w.C[w.g[0]];l.Eo(w,w.J,!0);if(l.zZ==null)this.zt=null}this.JG=w.J.rect.clone()}else{this.gj={w:[I.x,I.y],F:["M"]};
this.YA=I}};y.QU.prototype.QD=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);if(this.zt){if(this.RQ.patch==1){if(w.v9.length==0){var U=w.C[w.g[0]].zZ,M=I.x-this.Rq.x,m=I.y-this.Rq.y;
y.mU.SN(w,w.g[0],Math.round(M-U.M0.x),Math.round(m-U.M0.y))}}else this.az_(w,I,"clone")}if(this.YA){this.gj.F.push("L");
this.gj.w.push(I.x,I.y);this.YA=I;w.I.VZ=this.gj;w.RP=!0}};y.QU.prototype.H5=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);
if(this.zt){var U=w.J.rect.clone();if(this.id==y.i5){var M=w.C[w.g[0]];M.$H(w,M.zZ);w.J.rect=this.JG.clone();
var m=E.Q(w.J.rect.O()*4);E.IL(w.J.channel,m,3);this.X_(w,"sheal",m,w.J.rect,w.J.rect);w.J.rect=U;U=U.x0(this.JG)}this.az_(w,I,"heal");
this.finish(w,U,null,null,!0);w.l(U);this.zt=null}if(this.YA){var l=y.eZ.H9(this.RQ.setop,D.U(aK.WO),D.U(aK.PJ)),A=new ed(b.E.W1,!0);
if(this.gj.w.length<=4)A.data=y.eZ.Jj();else A.data=y.eZ.KI(this.gj.w,l);n.S(A);this.YA=null;w.I.VZ=null;
w.RP=!0}};y.QU.prototype.bO=function(){return this.R};y.QU.prototype.sm=function(w,n,W,D,j){y.JT.prototype.sm.call(this,w,n,W,D,j);
this.eg(j,D)};y.QU.prototype.eg=function(w,n){var W="auto;";if(n!=null&&n.U(aK.WO)&&!n.U(aK.PJ)||this.RQ.setop=="union")W="copy";
var D=new ed(b.E.L,!0);D.data={d:b.c.ph,In:W};if(this.caller)this.caller.S(D)};y.QU.prototype.az_=function(w,n,W){var D=new ec(Math.round(this.zt.x-n.x),Math.round(this.zt.y-n.y));
if(this.RQ.patch==1)D.y1(-D.x,-D.y);this.R=D;this.X_(w,W,this._f,w.J.rect,w.J.rect);this.l(w,w.J.rect)};
y.amq=function(){y.QU.call(this,!0);this.RQ.patch=1};y.amq.prototype=new y.QU(!0,!0);y.XM=function(){y.JT.call(this,[10,13],y.afO,"tools/pbucket");
this.XJ=!1};y.XM.prototype=new y.JT;y.XM.prototype.enable=function(w,n,W,D){var j=new ed(b.E.L,!0);j.data={d:b.c.ph,In:"default"};
n.S(j)};y.XM.prototype.GZ=function(w,n){};y.XM.prototype.WQ=function(w,n,W,D,j){this.XJ=!0};y.XM.prototype.H5=function(w,n,W,D,j,I){var U=this.XJ;
this.XJ=!1;if(!U||I)return;if(this.rG(D,n,j))return;if(!w.d2())return;var M=w.u.Cg(j.x,j.y),m=y.KF.axY(w,M,this.RQ.wconf,this.RQ.sall,!0);
if(m==null)return;var l=E.Q(m.rect.O()*4);E.cJ(l,(W.Gp&255)<<16|(W.Gp>>8&255)<<8|(W.Gp>>16&255)<<0);
E.IL(m.channel,l,3);this.W5(w);this.X_(w,"draw",l,m.rect,m.rect);this.l(w,m.rect);this.finish(w,m.rect)};
y.TB=function(){y.eZ.call(this,[10,14],y.a4C,"tools/plasso");this.t1="crosshair";this.lk=[];this.kt=null;
this.gj=null;this.apv=0};y.TB.prototype=new y.eZ;y.TB.prototype.disable=function(w,n,W,D){this.fm(w)};
y.TB.prototype.jx=function(w,n,W,D){this.lk=[aK.m2,aK.on]};y.TB.prototype.wO=function(w){return this.lk.indexOf(w)!=-1};
y.TB.prototype.LL=function(w){return this.gj!=null};y.TB.prototype.rT=function(){return this.gj!=null};
y.TB.prototype.wb=function(){return this.gj!=null};y.TB.prototype.Gi=function(w,n,W,D){if(this.gj==null)return;
var j=this.gj,I=j.w,U=I.length-2,M=this.Gs;if(this.Y7.i6(1)&&W.U(aK.PJ)&&D.WS){I.push(0,0);j.F.push("L");
U+=2}else if(W.U(aK.WO))M=y.mr.RM(new ec(I[U-2],I[U-1]),M);I[U]=M.x;I[U+1]=M.y;w.I.VZ=j;w.RP=!0};y.TB.prototype.WB=function(w,n,W,D){var j=Date.now();
if(this.gj==null)this.gj={w:[this.Gs.x,this.Gs.y,this.Gs.x,this.Gs.y],F:["M","L"]};else{this.Gi(w,n,W,D);
if(j-this.apv<250||ec.cS(this.Gs,new ec(this.gj.w[0],this.gj.w[1]))<y.N5(w,D)){this.kt=this.gj;this.finish(w,n,W,D);
this.fm(w);return}this.gj.F.push("L");this.gj.w.push(this.Gs.x,this.Gs.y)}this.apv=j;w.I.VZ=this.gj};
y.TB.prototype.fm=function(w){this.gj=null;this.lk=[];if(w!=null){w.I.VZ=null;w.RP=!0}};y.TB.prototype.oe=function(w,n,W,D){y.eZ.prototype.oe.call(this,w,n,W,D);
if(D.U(aK.QX)&&this.gj==null&&this.kt&&w.J!=null){var j=new ed(b.E.v);j.G=y.eb;j.data={d:"h_stepbck"};
n.S(j);this.jx(w,W,D,null);this.gj=this.kt;return}if(this.gj==null)return;if(D.U(aK.m2)||D.U(aK.on)){this.gj.w.pop();
this.gj.w.pop();this.gj.F.pop();this.Gi(w,W,D)}if(D.U(aK.yG)){if(this.gj.w.length>4){this.kt=this.gj;
this.finish(w,W,D)}this.gj=null}if(D.U(aK.QX)){this.gj=null}w.I.VZ=this.gj;w.RP=!0};y.TB.prototype.getSelection=function(w,n,W,D){return y.eZ.KI(this.gj.w,null,this.RQ.anta)};
y.nZ=function(){y.eZ.call(this,[10,10],y.an9,"tools/mlasso");this.t1="crosshair";this.lk=[];this.i=[];
this.nd=[];this.Uv=[];this.$K=null;this.pM=null;this.SS=null;this.ft=0;this.y6=0};y.nZ.prototype=new y.eZ;
y.nZ.prototype.disable=function(w,n,W,D){this.clear(w)};y.nZ.prototype.LL=function(w){return this.i.length!=0};
y.nZ.prototype.wb=function(){return this.i.length!=0};y.nZ.prototype.wO=function(w){return this.lk.indexOf(w)!=-1};
y.nZ.prototype.jx=function(w,n,W,D){this.lk=[aK.m2,aK.on];var j=this.KH(this.gs,w);if(this.i.length!=0&&(ec.cS(j,this.i[0])<y.N5(w,D)||Date.now()-this.ft<300)){this.Lq(w,this.i[0]);
this.finish(w,n,W);this.clear(w);return}this.ft=Date.now();if(this.i.length!=0)j=this.h4(j,w);else{var I=w.m,U=w.n,M=E.Q(I*U),m=w.Vc(),l=I*U*4;
for(var L=0;L<l;L+=4)M[L>>>2]=~~(.5+E.g7(m[L],m[L+1],m[L+2])*(m[L+3]*(1/255)));this.$K=E.Hs.aw9(M,I,U);
this.SS=new Uint16Array(M.length)}this.Lq(w,j);this.y6=W.U(aK.PJ)?1:0;this.T5(w)};y.nZ.prototype.Lq=function(w,n){var W=this.i;
this.nd[W.length]=this.Uv.length;if(W.length!=0){E.Hs.OG(this.pM,n.y*w.m+n.x);var D=this.wm(w,n);D.reverse();
var j=y.nZ.amT(w,D);this.Uv=this.Uv.concat(j)}W.push(n);this.a87(w)};y.nZ.prototype.a87=function(w){var n=this.i[this.i.length-1],W=n.y*w.m+n.x;
this.pM=E.Hs.arz(this.$K.r1,this.$K.EO,W);this.SS.fill(0)};y.nZ.prototype.KH=function(w,n){return new ec(Math.floor(Math.max(0,Math.min(n.m-1,w.x))),Math.floor(Math.max(0,Math.min(n.n-1,w.y))))};
y.nZ.prototype.clear=function(w){this.Uv=[];this.i=[];this.nd=[];this.$K=null;this.pM=null;this.SS=null;
if(w!=null){w.I.VZ=null;w.I.cc=[];w.RP=!0}this.lk=[]};y.nZ.prototype.Gi=function(w,n,W,D){var j=this.i,I=j.length;
if(I==0)return;var U=this.h4(this.KH(this.Gs,w),w),M=this.wm(w,U);for(var L=0;L<M.length;L++){var m=M[L],l=new ec(m%w.m,Math.floor(m/w.m));
if(this.SS[m]>30&&ec.cS(l,j[I-1])>20){this.Lq(w,l);return}this.SS[m]++}if(this.y6==1&&D.WS)this.Lq(w,U);
this.T5(w)};y.nZ.prototype.T5=function(w){var n=this.i;if(n.length!=0){var W=this.h4(this.KH(this.Gs,w),w),D=this.wm(w,W);
D.reverse();var j=y.nZ.amT(w,D),I=this.Uv.concat(j),U=w.I.VZ={w:I,F:["M"]};for(var L=2;L<I.length;L+=2)U.F.push("L")}w.I.cc=[];
for(var L=0;L<n.length;L++)w.I.cc.push(n[L].x+.5,n[L].y+.5);w.RP=!0};y.nZ.prototype.WB=function(w,n,W,D){};
y.nZ.prototype.oe=function(w,n,W,D){if(this.i.length==0)return;if(D.U(aK.m2)||D.U(aK.on)){this.i.pop();
this.Uv=this.Uv.slice(0,this.nd[this.i.length]);this.nd.pop();if(this.i.length==0)this.clear(w);else this.a87(w);
this.T5(w)}if(D.U(aK.yG)){var j=this.KH(this.Gs,w);this.Lq(w,j);this.finish(w,W,D);this.clear(w)}if(D.U(aK.QX)){this.clear(w)}};
y.nZ.prototype.getSelection=function(w,n,W,D){return y.eZ.KI(this.Uv,null,this.RQ.anta)};y.nZ.prototype.wm=function(w,n){var W=this.i[this.i.length-1],D=W.y*w.m+W.x,j=n.y*w.m+n.x;
if(this.y6==1)return[j,D];var I=[j];while(j!=D){j=this.pM.hW[j];I.push(j);if(I.length>5e3){console.log(I);
throw"e"}}return I};y.nZ.amT=function(w,n){var W=[],D=w.m;for(var L=0;L<n.length;L++){var j=n[L];W.push(j%D+.5,Math.floor(j/D)+.5)}return W};
y.nZ.prototype.h4=function(w,n){var W=n.m,D=n.n,j=w.clone(),U=3;E.Hs.OG(this.pM,w.y*W+w.x);var I=this.pM.VF[w.y*W+w.x];
for(var M=-U+1;M<U;M++)for(var m=-U+1;m<U;m++){var l=w.x+m,A=w.y+M;if(l<0||l>=W||A<0||A>=D)continue;
E.Hs.OG(this.pM,A*W+l);if(this.pM.VF[A*W+l]<I)j.y1(l,A)}return j};y.L8=function(){y.qw.call(this,[10,36],y.Rp,"tools/ruler");
this.H3=null;this.iW=null;this.bW=null;this.N_=null;this.ZH=null};y.L8.prototype=new y.qw;y.L8.prototype.LL=function(w){return w.WS};
y.L8.prototype.enable=function(w,n,W,D){y.qw.prototype.enable.call(this,w,n,D,W);if(w)this.nA(w)};y.L8.prototype.disable=function(w,n,W,D){if(w)this.fm(w)};
y.L8.prototype.Al=function(w,n,W,D,j){this.H3=this.bW=null;this.nA(W)};y.L8.prototype.WQ=function(w,n,W,D,j){var I=y.N5(w,j),U=w.u.Cg(j.x,j.y);
U.x=Math.round(U.x);U.y=Math.round(U.y);var M=this.H3;this.iW=M?M.slice(0):null;var m=M&&ec.cS(U,M[0])<I,l=M&&ec.cS(U,M[1])<I,A=M&&M[2]&&ec.cS(U,M[2])<I;
if(m||l||A){if(D.U(aK.PJ)&&M.length==2){if(l){var g=M[0];M[0]=M[1];M[1]=g}M[2]=M[0].clone();this.bW=[2]}else this.bW=[m?0:l?1:2]}else if(M&&y.L8.aAf(M[0],M[1],U)<I&&Math.min(M[0].x,M[1].x)-5<=U.x&&U.x<=Math.max(M[0].x,M[1].x)+5&&Math.min(M[0].y,M[1].y)-5<=U.y&&U.y<=Math.max(M[0].y,M[1].y)+5){this.bW=[];
this.ZH=[];for(var L=0;L<M.length;L++){this.bW.push(L);this.ZH.push(M[L].clone())}this.N_=U}else{this.H3=[U.clone(),U.clone()];
this.bW=[1]}};y.L8.prototype.QD=function(w,n,W,D,j){if(this.bW==null)return;var I=this.H3,U=this.bW,M=w.u.Cg(j.x,j.y);
M.x=Math.round(M.x);M.y=Math.round(M.y);if(U.length>1){var m=M.x-this.N_.x,l=M.y-this.N_.y;for(var L=0;
L<I.length;L++){I[L]=this.ZH[L].clone();I[L].offset(m,l)}}else{I[U[0]].y1(M.x,M.y);if(D.U(aK.WO)){I[U[0]]=y.mr.RM(I[1-U[0]],I[U[0]])}}this.nA(w);
this.CP(n,b.E.L,{d:b.c.Bg,G:this.id,anr:I[0],ds:I[1],Wh:I[2],hh:w.hh,akv:w.m});w.u.Bn=E.p.lV([I[0].x,I[0].y,I[1].x,I[1].y]);
console.log(w.u.Bn)};y.L8.prototype.H5=function(w,n,W,D,j,I){this.bW=null;if(I){this.H3=this.iW.slice(0);
this.nA(w)}};y.L8.prototype.CP=function(w,n,W){var D=new ed(n,!0);D.data=W;w.S(D)};y.L8.prototype.nA=function(w){var n=this.H3;
if(n==null)this.fm(w);else{var W=[n[1].x,n[1].y,n[0].x,n[0].y],D=["M","L"];if(n.length>2){W.push(n[2].x,n[2].y);
D.push("L")}w.I.VZ={F:D,w:W};w.I.cc=W}w.RP=!0};y.L8.prototype.fm=function(w){w.I.VZ=null;w.I.cc=[]};
y.L8.aAf=function(w,n,W){var D=n.x-w.x,j=n.y-w.y,I=Math.abs(j*W.x-D*W.y+n.x*w.y-n.y*w.x),U=Math.sqrt(D*D+j*j);
return U==0?0:I/U};y.qe=function(){y.JT.call(this,[10,19],y.w7,"tools/sharpen");this.X1="copy"};y.qe.prototype=new y.JT;
y.qe.prototype.WQ=function(w,n,W,D,j){var I=this.RQ.pdetail?iV.vO:iV.w7;if(D.U(aK.PJ))I=iV.yJ;this.jM(w,W,D,j,this.RQ.strn,I);
if(this.rN==null)return;this.kC(w)};y.qe.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.xU=function(){y.JT.call(this,[10,24],y.Ug,"tools/shbrush");
this.X1="draw";this.RQ.opacity=.5};y.xU.prototype=new y.JT;y.xU.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,1);
if(this.rN==null)return;this.R9(w);this.kC(w)};y.xU.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.xU.prototype.H5=function(w,n,W,D,j){if(this.rN==null)return;
this.X_(w,"sheal",this.rN._a(),this.rN.pJ(),this.rN.oi(),null);this.l(w,this.rN.oi());y.JT.prototype.H5.call(this,w,n,W,D,j)};
y._F=function(){y.JT.call(this,[10,20],y.mH,"tools/smudge");this.X1="copy"};y._F.prototype=new y.JT;
y._F.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.strn,iV.mH);if(this.rN==null)return;this.kC(w)};
y._F.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;
if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.C6=function(){y.JT.call(this,[10,23],y.jG,"tools/sponge");
this.X1="sponge"};y.C6.prototype=new y.JT;y.C6.prototype.WQ=function(w,n,W,D,j){this.jM(w,W,D,j,this.RQ.flow);
if(this.rN==null)return;this.kC(w)};y.C6.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);if(this.Qt)this.$X(w,W,j);
if(this.rN==null)return;if(!j.WS)return;this.WD(w,W,D,j);this.kC(w)};y.Jd=function(){y.qw.call(this,[10,17],y.Nt,"tools/zoom");
this.Ba=!1;this.pZ=!0;this.j4=!1;this.Ps=0;this.sH=null;this.k8=null;this.CE=0;this.br=null;this.apM=0;
this.fU=new cA([{name:[8,0],pn:"Ctrl + +"},{name:[8,1],pn:"Ctrl + -",nW:!0},{name:[20,3],pn:"Ctrl + 0"},{name:["VAR0: 100%",[20,2]],pn:"Ctrl + 1"}],[{Y:b.E.v,G:y.Nt,W:{d:"zoom",pZ:!0}},{Y:b.E.v,G:y.Nt,W:{d:"zoom",pZ:!1}},{Y:b.E.v,G:y.Nt,W:{d:"adapt",Z:"fitscr"}},{Y:b.E.v,G:y.Nt,W:{d:"adapt",Z:"pixel"}}])};
y.Jd.prototype=new y.qw;y.Jd.prototype.cF=function(w,n,W,D,j){var I=this.fU;I.f();I.parent=n;I.update(w,W);
var U=new ed(b.E.L,!0);U.data={d:b.c.Uq,BT:I,x:j.Qc+2,y:j.tc+1};n.S(U)};y.Jd.prototype.enable=function(w,n,W,D){this.Oj(n,D);
if(w&&Date.now()-this.Ps<300)this.Al({d:"adapt",Z:"pixel"},n,w,D,W);this.Ps=Date.now()};y.Jd.prototype.WQ=function(w,n,W,D,j){this.k8=new ec(j.x,j.y);
this.CE=w.u.N;this.br=w.u.R.clone()};y.Jd.prototype.QD=function(w,n,W,D,j){if(this.k8==null)return;var I=Math.exp(Math.log(this.CE)+(j.x-this.k8.x)/64);
I=Math.max(.02,Math.min(y.Jd.Sh[0],I));w.u.N=this.CE;w.u.R=this.br.clone();this.Al({d:"zoom",N:I,tJ:this.k8,j4:this.j4},n,w,D,W)};
y.Jd.prototype.H5=function(w,n,W,D,j){if(ec.cS(this.k8,j)<4){var I=this.aoP(D);this.Al({d:"zoom",pZ:I,tJ:j,j4:this.j4},n,w,D,W)}this.k8=null};
y.Jd.Sh=[128,64,32,16,12,8,6,5,4,3,2,1,2/3,1/2,1/2*(2/3),1/4,1/4*(2/3),1/8,1/8*(2/3),1/16,1/16*(2/3),1/32,1/32*(2/3),1/64];
y.Jd.ajJ=function(w,n,W,D){var j=1;while(w*j*1/2>W||n*j*1/2>D)j*=1/2;if(w*j*2/3>W||n*j*2/3>D)j*=1/2;
else if(w*j>W||n*j>D)j*=2/3;return j};y.Jd.amZ=function(w,n){var W=y.Jd.ajU(w);if(n&&W==0)return w;if(!n&&W==y.Jd.Sh.length-1)return w;
return y.Jd.Sh[n?W-1:W+1]};y.Jd.ajU=function(w){var n=0;while(y.Jd.Sh[n]>w)n++;return n};y.Jd.Oh=function(w,n,W,D){var j=w.On;
if(D==0||D==null){D=y.Jd.amZ(w.N,W);if(D==w.N)return}var I=w.Cg(n.x,n.y);I.x=Math.max(0,Math.min(j.m,I.x));
I.y=Math.max(0,Math.min(j.n,I.y));if(!1){}else{var U=w.Pv(),M=w.N/D;U.translate(-I.x,-I.y);U.scale(M,M);
U.translate(I.x,I.y);w.a3Y(U)}};y.Jd.prototype.Al=function(w,n,W,D,j){if(w.d=="pzoom"){if(typeof w.Z=="string")return;
w={d:"zoom",N:w.Z/100}}var I=0,U=!1,M=null;if(w.d=="adapt"){var m=0;if(w.Z=="pixel")m=1;if(w.Z=="fitscr"){var m=0,l=W.u.xq.m,A=W.u.xq.n,g=new iB(0,0,W.m,W.n),k=E.p.Wx(g).w,$=new eh;
$.rotate(W.u.Tg);E.p.D(k,$,k);var C=E.p.mY(k),f=j.fM?E.f_.Nf+4:8;m=Math.min((l-f*2)/C.m,(A-f*2)/C.n);
W.u.R.y1(0,0)}M=new ec(Math.round(W.u.xq.m/2),Math.round(W.u.xq.n/2));I=m;y.Jd.Oh(W.u,M,U,I);W.tL=!0}if(w.d.startsWith("multi")){function z(G){var v=G[0].x-G[1].x,N=G[0].y-G[1].y;
return Math.sqrt(v*v+N*N)}function s(G){return new ec((G[0].x+G[1].x)/2,(G[0].y+G[1].y)/2)}var O=w.LE,a=s(O);
if(w.d=="multidown"){this.sH=[O,W.u.N,W.u.Cg(a.x,a.y)]}else{var X=y.Jd.Sh;I=this.sH[1]*z(O)/z(this.sH[0]);
I=Math.max(X[X.length-1],Math.min(X[0],I));if(I!=W.u.N)y.Jd.Oh(W.u,a,U,I);var P=this.sH[2],Z=W.u.m9(P.x,P.y),Y=W.u.R;
Y.x=Math.round(Y.x+a.x-Z.x);Y.y=Math.round(Y.y+a.y-Z.y);W.tL=!0}}if(w.d=="scroll"){M=w.tJ;var X=y.Jd.Sh,K=w.jP.y,S=1+Math.abs(K)*8e-4*(w.a8n?10:1);
if(K>0)S=1/S;I=W.u.N*S;y.Jd.Oh(W.u,M,U,Math.min(X[0],Math.max(X[X.length-1],I)));W.tL=!0}if(w.d=="zoom"){var G=w.j4?n.oZ:[W];
for(var L=0;L<G.length;L++){var V=G[L],T=V.u;M=w.tJ?w.tJ:new ec(Math.round(T.xq.m/2),Math.round(T.xq.n/2));
if(w.N!=null)I=w.N;else U=w.pZ;y.Jd.Oh(T,M,U,I);V.tL=!0}}if(w.d=="mskView"){var R=W.C[W.g[0]];if(R.eL<=0){R.eL=1;
W.rR=!0}var x=R.eL==3?R.NP(W).z:R._N();if(w.Z==0){W.u.zC=[1,1,1];x.$P=!1}if(w.Z==1){W.u.zC=[1,1,1];x.$P=!0}if(w.Z==2){W.u.zC=[0,0,0];
x.$P=!0}for(var L=0;L<W.yo.length;L++)W.yo[L].$P=!1;W.v9=[];W.RP=!0}};y.Jd.prototype.oe=function(w,n,W,D){if(this.Ba!=D.U(aK.PJ)){this.Ba=D.U(aK.PJ);
var j={d:b.c.Bg,G:this.id,Ba:this.Ba},I=new ed(b.E.L,!0);I.data=j;n.S(I);this.Oj(n,D)}};y.Jd.prototype.Oj=function(w,n){var W=new ed(b.E.L,!0),D=this.aoP(n);
W.data={d:b.c.ph,In:D?"zoom-in":"zoom-out"};w.S(W)};y.Jd.prototype.sm=function(w,n,W,D){this.pZ=w.pZ;
this.j4=w.j4;this.Oj(n,D)};y.Jd.prototype.aoP=function(w){var n=this.pZ;if(w.U(aK.Xu)&&w.U(aK.CQ))n=!0;
if(this.Ba)n=!n;return n};y.Jd.a0D=function(w,n){if(w.U(aK.fQ)||w.U(aK.aqB)){n.G=y.Nt;n.data={d:"zoom",pZ:!0}}if(w.U(aK.Ne)){n.G=y.Nt;
n.data={d:"zoom",pZ:!1}}if(w.U(aK.zf)){n.G=y.Nt;n.data={d:"adapt",Z:"fitscr"}}if(w.U(aK.ed)){n.G=y.Nt;
n.data={d:"adapt",Z:"pixel"}}};y.rK=function(w,n,W){y.qw.call(this,w,n,W);this.yV=null;this.ww=null;
this.xh=null;this.ac5=0};y.rK.prototype=new y.qw;y.rK.un=function(w){var n={t:"obj ",v:[{t:"prop",v:{classID:"Path",keyID:"WrPt"}}]},W=w==0?{classID:"null",null:n,WhPt:{t:"bool",v:!0}}:{classID:"Strk",null:n,Usng:{t:"type",v:{classID:"PbTl"}},__name:"Stroke"};
return{hZ:w==0?"fill":"stroke",E3:W}};y.rK.prototype.enable=function(w,n,W,D,j){this.ww=W;var I=new ed(b.E.L,!0);
I.data={d:b.c.ph,In:"default"};n.S(I)};y.rK.prototype.cF=function(w,n,W,D,j){var I=w.OV(),U=I[0],M=I[1];
if(M.length==0)return;var m=U[M[0]],l=m.add.vmsk,A=w.u.Cg(j.x,j.y),g=4*y.V()/w.u.N,k=new iB(A.x-g,A.y-g,g*2,g*2),$=E.P.qk(l.i,k)[0];
if($.length!=0){l.Rw=$;w.RP=!0}var C=E.P.pw(l.i,A).p_;if(C!=-1){l.g=[C];w.RP=!0}var f=new ed(b.E.L,!0);
f.data={d:b.c.Bg,G:this.id,ao:j,AR:w,Yo:W};n.S(f)};y.rK.prototype.anW=function(w,n){var W=new ed(b.E.L,!0);
W.data={d:b.c.oj,AH:bk.Xh};if(!n.Ar)w.S(W);W.data={d:b.c.oj,AH:bk.aK};if(!n.M3.Oi)w.S(W)};y.rK.prototype.BW=function(w,n,W,D){if(W.No!=this.id)return;
if(w.g.length==0)return;var j=w.C[w.g[0]],I=j.add.vmsk,U=j.add.vstk,M=y.rK.wj(w,w.g[0]);this.yV=w;this.xh=n;
if(j.I9()&&I!=null&&(JSON.stringify(U)!=JSON.stringify(W.jH)||JSON.stringify(M)!=JSON.stringify(W.rg))){this.ac5=Date.now();
var m=new ed(b.E.L,!0);m.data={d:b.c.oj,AH:bk.ut,Z:M};n.S(m);m.data={d:b.c.oj,AH:bk.Nd,Z:U};n.S(m)}};
y.rK.prototype.GZ=function(w,n){if(this.yV==null)return;if(n==bk.bI||n==bk.ut||n==bk.Nd){if(Date.now()-this.ac5<50)return;
var W=n==bk.ut,D=this.yV,j=W?w.rg:w.jH,I=[],U=D.g;for(var L=0;L<U.length;L++){var M=U[L],m=D.C[M];if(!m.I9()||m.add.vmsk==null)continue;
I.push(M)}var l=new ed(b.E.v,!0);l.G=y.Yu;l.data={d:h.Q2,G1:I,Mr:W,Z:j};if(I.length!=0)this.xh.S(l)}};
y.rK.prototype.ahb=function(w){if(typeof w=="number"){var n=new ed(b.E.W1,!0);n.data=y.IG.YE(0);n.data.E3.Usng.v.Type.v.Clr.v=E.M.lW({o:w>>>16&255,B:w>>>8&255,k:w>>>0&255});
this.xh.S(n)}};y.rK.prototype.Al=function(w,n,W,D,j){this.xh=n;if(w.d=="newfill"){if(w.Y3==0){var I=new ed(b.E.L,!0);
I.data={d:b.c.P2,jW:"colorpicker",pL:j.Gp,fT:this.ahb.bind(this)};n.S(I)}}else if(w.d=="pathedit"){var U=w.vK,M="",m=W.Oi.slice(0),l=W.rs.slice(0),A=W.Oi.slice(0),g=W.rs.slice(0);
if(U=="rnm"){var k=-1-w.p_,$=m[k],C=kc.bb(w.name,$.add);if(k!=0)A[k]=C;else{g=[A.length];A.push(C);A[0]=kc.bb("Work Path")}M="Rename"}else if(U=="new"){var C=kc.bb("Path "+m.length);
if(w.a8L){var f=W.OV(),s=f[0],O=f[1],a=s[O[0]];C.add.vmsk=a.add.vmsk.clone();C.add.vogk=JSON.parse(JSON.stringify(a.add.vogk));
if(a.p_==-1){var X=A[g[0]]=kc.bb("Path "+m.length);X.name=a.name;X.p_=a.p_}}A.push(C);g=[A.length-1];
M="New"}else if(U=="del"){if(g.length==0)return;g.sort(function(x,p){return x-p});if(g[0]==0){A[0]=kc.bb(m[0].name);
g=g.slice(1)}var P=0;while(g.length!=0){A.splice(g[0]-P,1);g=g.slice(1);P++}M="Delete"}else if(U=="fromsel"){var Z=A[0]=kc.bb("Work Path");
g=[0];if(W.J==null)return;var Y=W.J.channel.slice(0);for(var L=0;L<Y.length;L++)Y[L]=Y[L]>128?2:1;var K=W.J.rect.clone();
K.VD(1,1);var S=E.Q(K.O());E.B0(Y,W.J.rect,S,K);var G=cf.jo(S,K.m,K.n,Math.round(K.O()*5e-4)),s=cf.OV(G),V=new eh(1,0,0,1,-1+W.J.rect.x,-1+W.J.rect.y);
for(var L=0;L<s.length;L++)E.p.D(s[L].path.w,V,s[L].path.w);for(var L=0;L<s.length;L++){var T=s[L];if(T.color==1&&T.parent==-1)continue;
var R=E.p.oF(s[L].path,!1);Z.add.vmsk.i=Z.add.vmsk.i.concat(R.slice(2))}Z.add.vogk=h.hu(Z.add.vmsk.i);
M="Selection to"}var x=new go(M+" Path",this);x.data={iW:m,DD:l,aAs:A,Ib:g};if(U=="fromsel"){x.data.Py=W.J;
x.data.TY=null}W.kK(x);this.Fd(x.data,W)}else{var v=w.s7,f=W.OV(w.d=="append"||w.d=="fromAction"),s=f[0],O=f[1],Z=s[O[0]],N=Z.add.vmsk,u=Z.add.vogk,H=N.clone(),F=N.clone(),t=JSON.stringify(u);
if(w.d=="fromAction"){var o=w.bs,q=o.hZ,_=o.E3,d=_.T;if(q=="set"){if(d){u.push(E.X.Oq(d));F.i.push({type:0,Ht:1,length:0});
E.X.A9(u,F);v=[12,76,0]}else throw _}else if(q=="draw"){u=[E.X.Oq(_.Shp)];F.i.push({type:0,Ht:1,length:0});
E.X.A9(u,F);y.rK.a37(F.i,_.AntA.v,j.Gp,n);return}else throw q}else if(w.d=="remove"){if(w.gi&&F.Rw.length!=0){F.i=E.P.al2(F.i,F.Rw,u,w.aaH);
var r=E.P.bB(F.i);for(var L=0;L<F.g.length;L++)if(F.g[L]>=r){F.g.splice(L,1);L--}F.Rw=[];v="Delete Anchors"}else{if(F.g.length==0)return;
var P=0;for(var L=0;L<F.g.length;L++){u.splice(F.g[L]+P,1);P--}F.i=E.P.amm(F.i,F.g);F.g=[];F.Rw=[];if(v==null)v="Delete Paths"}}if(w.d=="append"){y.rK.J4(w.akR,F,u)}this.z6(W,Z.p_,F,u);
this.sc(W,v,Z.p_,H,F.clone(),null,t,JSON.stringify(u))}};y.rK.a37=function(w,n,W,D){var j=new h.Rd;j.i=j.i.concat(w.slice(2));
var I=j._N();if(!n)E.round(I.channel);var U=E.Q(I.rect.O()*4);E.cJ(U,(W&255)<<16|(W>>8&255)<<8|(W>>16&255)<<0);
E.IL(I.channel,U,3);var M=new ed(b.E.v,!0);M.G=y.zq;M.data={d:"draw",qH:{buffer:U,rect:I.rect.clone()},s7:this.name};
D.S(M)};y.rK.WR=function(w,n){var W=E.P.apW(w.i,w.g),D=[];for(var L=0;L<w.g.length;L++)D.push(JSON.parse(JSON.stringify(n[w.g[L]])));
return[W,D]};y.rK.J4=function(w,n,W){var D=E.P.bB(n.i),j=E.P.bB(w[0]);n.i=n.i.concat(w[0].slice(2));
n.g=[];for(var L=0;L<j;L++)n.g.push(D+L);for(var L=0;L<j;L++)W.push(JSON.parse(JSON.stringify(w[1][L])))};
y.rK.prototype.wO=function(w,n){if(n==null)return!1;var W=n.OV(),D=W[0],j=W[1];if(j.length==0)return!1;
var I=D[j[0]],U=I.add.vmsk;if(U&&U.g.length+U.Rw.length!=0)return[aK.m2,aK.on].indexOf(w)!=-1};y.rK.prototype.oe=function(w,n,W,D){if(w==null)return;
var j=w.OV(),I=j[0],U=j[1];if(U.length==0)return;var M=I[U[0]],m=M.add.vmsk;if(D.U(aK.QX)||D.U(aK.yG)||this.id==y.ET&&D.U(aK.b8)){m.Rw=[];
w.RP=!0}if(m.g.length!=0){var l=D.aa(w?w.u.Tg:0);if(l.x!=0||l.y!=0){var A=m.clone(),g=m.clone(),k=new eh(1,0,0,1,l.x,l.y),$=M.add.vogk,C=JSON.stringify($);
if(D.U(aK.PJ)){var f=y.rK.WR(g,$);y.rK.J4(f,g,$)}E.P.c0(g.i,k,g.g);E.X.D($,E.K.yT(k),g.g);this.z6(w,M.p_,g,$);
this.sc(w,"Move Paths",M.p_,A,g.clone(),!0,C,JSON.stringify($))}if(D.U(aK.m2)||D.U(aK.on))this.Al({d:"remove",gi:this.id==y.ET},n,w,D,W)}};
y.rK.prototype.sc=function(w,n,W,D,j,I,U,M){var m=new go(n,this);m.data={Ay:W,Hi:D,DG:j,ae8:I,adj:U,Gj:M};
w.kK(m)};y.rK.prototype.Fd=function(w,n){if(w.Ay!=null)this.z6(n,w.Ay,w.DG.clone(),JSON.parse(w.Gj));
else{n.Oi=w.aAs.slice(0);n.rs=w.Ib.slice(0);n.RP=n.rR=!0}if(w.Py||w.TY){n.J=w.TY;n.Iq=!0}};y.rK.prototype.ZE=function(w,n){if(w.Ay!=null)this.z6(n,w.Ay,w.Hi.clone(),JSON.parse(w.adj));
else{n.Oi=w.iW.slice(0);n.rs=w.DD.slice(0);n.RP=n.rR=!0}if(w.Py||w.TY){n.J=w.Py;n.Iq=!0}};y.rK.prototype.z6=function(w,n,W,D){var j=n<0?w.Oi[-1-n]:n<1e6?w.C[n]:w.C[n-1e6].add.TySh,I=j.add.vmsk;
I.channel=null;I.eP=!0;if(I.pv){I.pv.channel=null;I.pv.eP=!0}j.add.vmsk=W;j.add.vogk=D;if(1e6<=n){hd.Y_(j);
var U=w.C[n-1e6],M=j,m=this.ww;aj.a5(U,m.hY);w.l()}else if(0<=n){W.eP=!0;j.yb(w);w.l()}w.RP=w.rR=!0};
y.rK.wj=function(w,n){var W=w.C[n],D=W.add.vstk,j=null;if(D&&!D.fillEnabled.v)j={oq:0};else if(W.add.SoCo)j={oq:1,S8:W.add.SoCo};
else if(W.add.GdFl)j={oq:2,S8:W.add.GdFl};else if(W.add.PtFl)j={oq:3,S8:W.add.PtFl};return j};y.rK.KG=function(w,n){var W=w.add.vmsk,D=w.add.vstk,j=n.oq;
if(D)D.fillEnabled.v=j!=0;if(j>0){var I=["SoCo","GdFl","PtFl"][j-1];for(var L=0;L<3;L++)delete w.add[["SoCo","GdFl","PtFl"][L]];
w.add[I]=n.S8}};y.IG=function(w,n,W,D){y.rK.call(this,w,n,W);this.RQ={shape:bI._1(),pshape:0,binop:0,crad:0,irad:40,length:4,sides:5,width:5,tolr:5,tsiz:300,cstr:{ib:0},anta:!0,aopts:[!1,!1,50,100,0]};
this.anX=D;this.rz=null;this.Q$=null;this.ti=null;this.Y7=new hY};y.IG.prototype=new y.rK;y.IG.prototype.LL=function(w){return w.WS&&this.id!=y.o4};
y.IG.prototype.enable=function(w,n,W,D,j){this.ww=W;var I=new ed(b.E.L,!0);I.data={d:b.c.ph,In:"crosshair"};
n.S(I)};y.IG.prototype.oe=function(w,n,W,D){y.rK.prototype.oe.call(this,w,n,W,D);this.Y7.oe(D);this.za(n,W)};
y.IG.prototype.za=function(w,n){var W=new ed(b.E.L,!0);W.data={d:b.c.Bg,G:this.id,K8:this.PC(n)};w.S(W)};
y.IG.prototype.PC=function(w){var n=this.Y7.m$(0),W=this.Y7.i6(0),D=y.eZ.H9(this.RQ.binop,n,W);if(w.R_==1&&D==0)D=1;
return D};y.IG.prototype.Cy=function(w,n,W,D){};y.IG.prototype.WQ=function(w,n,W,D,j){var I=W.R_;if(I!=2)this.anW(n,W);
if(I==2&&!w.d2())return;var U=w.u.Cg(j.x,j.y);U=y.mU.JW(w,U,W);this.ti=[U.x,U.y];this.rz=U;this.Q$=new ec(0,0);
this.Y7.WQ(D)};y.IG.prototype.a2C=function(w,n,W,D){var j=[this.rz.clone(),n.clone()];W=this.Y7.m$(1)||W.U(aK.WO)||this.Y7.i6(1)?W:null;
if(this.anX)j=y.IG.fS(j[0],j[1],W,!0,this.RQ.cstr);if(w)w.u.Bn=new iB(j[0].x,j[0].y,j[1].x-j[0].x,j[1].y-j[0].y);
return this.Cy(j[0],j[1],this.Y7.m$(1)&&W.U(aK.WO),this.ti,w.u,D)};y.IG.prototype.a4Q=function(w,n,W){var D=w.u.Cg(n.x,n.y);
if(this.id==y.o4)return D;var j=this.RQ.cstr;if(j.ib==2){var I=new iB(D.x-j.x,D.y-j.y,j.x,j.y),U=y.mU.uP(w,I,W);
D.x+=U[0];D.y+=U[1];y.mU.Iy(w,I,U)}else D=y.mU.JW(w,D,W);return D};y.IG.prototype.QD=function(w,n,W,D,j){if(this.rz==null)return;
var I=this.ti,U=I.length,M=j?this.a4Q(w,j,W):new ec(I[U-2],I[U-1]);if(D.U(aK.Xu))this.rz=M.eu(this.Q$);
else this.Q$=M.eu(this.rz);I.push(M.x,M.y);if(this.RQ.shape==null)this.RQ.shape=W.Jz[0];var m=this.a2C(w,M,D,!0)[0],l=E.p.xH(m);
w.I.VZ=l;if(this.id!=y.o4&&this.id!=y.Eh&&this.id!=y.Hw)y.qw.Co(j,w.u.Bn,w,W);w.RP=!0;this.Y7.QD()};
y.IG.prototype.a0R=function(w,n,W,D){var j=w[4].clone();if(D){j.x-=n/2;j.y-=W/2}if(this.id==y.Eh){n/=2;
W/=2;j.x+=n;j.y+=W;W=-W;n=0}var I=this.Cy(j,new ec(j.x+n,j.y+W),!1,this.ti);this.a2S(w[0],w[1],w[2],I)};
y.IG.prototype.a2S=function(w,n,W,D){var j=W.R_,I=new ed(b.E.W1,!0);if(j==0)I.data=y.IG.aaR(D[1],W);
else if(j==1){var U={__name:"Set",classID:"setd",null:{t:"obj ",v:[{t:"prop",v:{classID:"Path",keyID:"WrPt"}}]},T:D[1]};
I.data={hZ:"set",E3:U}}else{var U={__name:"Draw",classID:"Draw",AntA:{t:"bool",v:!0},Shp:D[1]};I.data={hZ:"draw",E3:U}}n.S(I);
if(D[1].v.classID=="customShape"&&D[1].v.Nm.v.startsWith("--")){var M=w.OV(),m=M[0],l=M[1],A=m[l.pop()],g=A.add.vmsk,k=A.add.vogk;
E.X.H4(k);var $=g.clone();$.i=D[0];this.z6(w,A.p_,$,k)}};y.IG.prototype.H5=function(w,n,W,D,j,I){if(this.rz==null)return;
var U=this.a4Q(w,j,W),M=this.PC(W),m=W.R_,l=this.ti,A=l.length;if(this.id==y.o4&&A<=4){}else if(A<=4){U.x=Math.round(U.x);
U.y=Math.round(U.y);var g=new ed(b.E.L);g.data={d:b.c.P2,jW:"createshape",agJ:this.a0R.bind(this),aan:this.name,atn:[w,n,W,D,U]};
if(!I)n.S(g)}else if(A!=2){var k=this.a2C(w,U,D),$=k[0],C=w.OV(!0),f=C[0],z=C[1],s=z.length-1;if(m==1&&$.length>2||m==0&&M!=0&&s!=-1&&f[z[s]].p_>=0){$[2].Ht=[1,2,3,0][M-1];
var O=f[z.pop()],a=O.add.vmsk,X=O.add.vogk,P=a.clone(),Z=a.clone(),Y=JSON.stringify(X);Z.i=Z.i.concat($.slice(2));
Z.g=[E.P.bB(Z.i)-1];var K=E.X.Oq(k[1]);X.push(K?K:E.X.LR());this.z6(w,O.p_,Z,X);this.sc(w,this.name,O.p_,P,Z,null,Y,JSON.stringify(X))}else if(m==0){this.a2S(w,n,W,k)}else if(m==2){y.rK.a37($,this.RQ.anta,W.Gp,n)}}this.rz=null;
w.I.VZ=null;w.I.t7=null;w.I.r7=[];w.u.Bn=null;w.RP=!0;this.Y7.H5();this.za(n,W)};y.IG.prototype.sm=function(w,n,W,D,j){for(var W in w)this.RQ[W]=w[W]};
y.IG.fS=function(w,n,W,D,j){var I=w.x,U=w.y,M=n.x,m=n.y;if(j&&j.ib==2){if(D){M=Math.round(M);m=Math.round(m)}I=M-j.x;
U=m-j.y}else{var l=0;if(j&&j.ib==1)l=j.y/j.x;else if(W&&W.U(aK.WO))l=1;if(l!=0){if(D){if(I<M)I=Math.floor(I);
else I=Math.ceil(I);if(U<m)U=Math.floor(U);else U=Math.ceil(U)}var A=Math.abs(M-I),g=Math.abs(m-U),k=A;
if(g/A<l)k*=g/A/l;M=M>I?I+k:I-k;m=m>U?U+k*l:U-k*l}if(W&&W.U(aK.PJ)){I-=M-I;U-=m-U}}var w=new ec(I,U),n=new ec(M,m);
if(D)y.IG.a8K(w,n);return[w,n]};y.IG.a8K=function(w,n){if(w.x>n.x){var W=w.x;w.x=n.x;n.x=W}if(w.y>n.y){var W=w.y;
w.y=n.y;n.y=W}w.x=Math.floor(w.x);w.y=Math.floor(w.y);n.x=Math.ceil(n.x);n.y=Math.ceil(n.y)};y.IG.a6V=function(){return{classID:"Mk",null:{t:"obj ",v:[{t:"Clss",v:{classID:"contentLayer"}}]},Usng:{t:"Objc",v:{classID:"contentLayer",Type:{t:"Objc",v:{}}}}}};
y.IG.YE=function(w,n){var W=y.IG.a6V(),D=W.Usng.v.Type;if(n==null){D.v=JSON.parse(JSON.stringify(at.Iz[w]));
D.v.classID=["solidColorLayer","gradientLayer","patternLayer"][w]}else y.G$.xk(n,D.v,w);return{hZ:"make",E3:W}};
y.IG.aaR=function(w,n){var W=n.rg,D=JSON.parse(JSON.stringify(n.jH));D.fillEnabled.v=W.oq!=0;var j=y.IG.YE(Math.max(0,W.oq-1),W.S8);
j.E3.Usng.v.Shp=w;j.E3.Usng.v.strokeStyle={t:"Objc",v:D};return j};y.p4=function(w){y.rK.call(this,w==0?[10,29]:[10,51],w==0?y.ET:y.a76,w==0?"tools/pen":"tools/cpen");
this.y6=w;this.Op=null;this.Dr=null;this.Q3=null;this.ahq=0;this.Uy=null;this.GE=!1;this.tu=!1;this.Vo=!1;
this.XH=!1;this.Ps=0};y.p4.prototype=new y.rK;y.p4.prototype.LL=function(w){return this.Dr!=null};y.p4.prototype.oe=function(w,n,W,D){if(!D.U(aK.PJ))this.Vo=!1;
if(this.y6==1&&(D.U(aK.m2)||D.U(aK.on))&&this.wO(aK.m2,w)){this.Al({d:"remove",gi:!0},n,w,D,W);return}y.rK.prototype.oe.call(this,w,n,W,D)};
y.p4.prototype.WQ=function(w,n,W,D,j){this.Op=j;this.anW(n,W);var I=w.u.Cg(j.x,j.y),f,z;I.x=Math.round(I.x);
I.y=Math.round(I.y);var U=y.mU.JW(w,I,W),M=W.R_,m=this.ahq;if(M==2)M=0;var l=w.OV(M==1),A=l[0],g=l[1],k=A[g.pop()],$=k?k.add.vmsk:null;
if(M==0&&m!=0&&k&&k.p_>=0)M=1;var C=y.N5(w,j);if($)f=E.P.pw($.i,I,!0,C);var s=D.U(aK.PJ);if(M==0&&($==null||$.Rw.length==0&&f.p_==-1)){var O=new ed(b.E.W1,!0),a=E.X.k5("customShape",[0,0,1,1],null,null,null,"--");
O.data=y.IG.aaR(a,W);n.S(O);this.XH=!0;l=w.OV(!0);A=l[0];g=l[1];k=A[g.pop()];$=k.add.vmsk;$.i=$.i.slice(0,2)}var X=k.add.vogk;
this.Dr=$.clone();this.Q3=JSON.stringify(X);var P=$.i,Z=E.P.bB(P);z=E.P.qk($.i,new iB(I.x-C,I.y-C,C*2,C*2),$.Rw);
f=E.P.pw($.i,I,!0,C);var Y=z[0].length+z[1].length+z[2].length;if(f.p_!=-1&&z[0].length==0){var K=E.P.tt(P,f.p_),S=P[K].length;
while(S<=f.po){f.po-=S;K+=S+1}var G={type:4,T7:U.clone(),H:U.clone(),mO:U.clone()},V=K+2+f.po,T=K+1+(1+f.po)%S,R=P[V-1],x=P[T];
if(!R.H.s9(R.mO)||!x.T7.s9(x.H)){var v=E.p.ag6(R.H,R.mO,x.T7,x.H,f.Sd);R.mO=v[0];G.T7=v[1];G.H=v[2];
G.mO=v[3];x.T7=v[4]}P.splice(V,0,G);P[K].length++;$.Rw=[V];if(this.y6==1){G.T7.x+=2;this.Qy($)}}else if(Y!=0&&s){var N=0;
for(var L=0;L<3;L++)if(z[L].length!=0){N=z[L][0];this.tu=L==1;break}if(z[0].length!=0){var u=$.i.length-1,H=$.i[N];
H.mO=H.H.clone();var F=H.type>=3?3:0;if(N!=u){H.T7=H.H.clone();H.type=F+1;this.Vo=!0}else H.type=F+2}$.Rw=[N]}else if(z[0].length==1&&P[z[0][0]-1]&&(P[z[0][0]-1].H!=null||P[z[0][0]-1].type==0||P[z[0][0]-1].length==1)){var N=z[0][0];
if(this.y6==1){var t=P[N],o=t.H,q=Math.abs(E.p.a9Z(t.T7.x,t.T7.y,o.x,o.y,t.mO.x,t.mO.y));if(q>.01){t.T7=o.clone();
t.mO=o.clone()}if(Date.now()-this.Ps<300){var _=t.T7.s9(o)&&t.mO.s9(o);if(_)t.mO.offset(2,2);else{t.T7=o.clone();
t.mO=o.clone()}this.Ps=0}else this.Ps=Date.now();$.Rw=[N];this.Qy($)}else{var K=E.P.tt(P,E.P.de(P,N)),a=P[K],d=K+a.length;
if(N!=d||a.type==0){P[K].length--;P.splice(N,1);d--;if(a.length==0){P.splice(K,1);d=-1}}if(d!=-1)$.Rw=[d];
else $.Rw=[]}}else{var r=0;if($.Rw.length!=1){$.g=[Z];P.push({type:3,length:1,Ht:[1,2,3,0][Math.max(0,m-1)],S1:0,_T:0,si:0});
r=P.length;X.push(E.X.LR())}else{var t=$.Rw[0],p=E.P.de(P,t),K=E.P.tt(P,p);t=K+P[K].length;if(ec.cS(I,P[K+1].H)<C){P[K].type=0;
$.Rw=[K+1];this.Uy=U;this.GE=!0;this.z6(w,k.p_,$,X);w.RP=!0;return}P[K].length++;r=t+1;if(t==K+1&&P[K].length!=2)r=K+1}if(D.U(aK.WO)&&P[r-1]&&P[r-1].H)U=y.mr.RM(P[r-1].H,U);
var G={type:4,T7:U.clone(),H:U.clone(),mO:U.clone()};P.splice(r,0,G);$.Rw=[r];this.Uy=U;if(this.y6==1){G.T7.x+=2;
this.Qy($)}this.Ps=Date.now()}this.z6(w,k.p_,$,X);w.RP=!0};y.p4.prototype.Qy=function(w){var n=w.i,W=w.Rw[0],D=E.P.tt(n,E.P.de(n,W))+1,j=n[D-1].length;
if(j<3)return;var I=[],U=[];for(var L=0;L<5;L++){var M=D+(W-D-2+L+5*j)%j;U.push(M);var m=n[M].H;I.push(m.x,m.y)}var l=E.p.pl(I);
for(var L=1;L<4;L++){var A=L*4,g=n[U[L]],m=g.H,k=g.T7.s9(m)&&g.mO.s9(m);if(!k){g.T7.y1(l[A],l[A+1]);
g.mO.y1(l[A+2],l[A+3])}else{g.T7=m.clone();g.mO=m.clone()}}};y.p4.prototype.QD=function(w,n,W,D,j){if(this.Dr==null)return;
var I=this.Op;if(I&&ec.cS(I,j)<y.N5({u:{N:1}},j))return;this.Op=null;var U=w.u.Cg(j.x,j.y),M=y.mU.JW(w,U,W),m=w.OV(W.R_==1),l=m[0],A=m[1],g=l[A.pop()],k=g.add.vmsk,$=k.i,C=$[k.Rw[0]];
if(this.y6==1){var f=C.H.s9(C.T7)&&C.H.s9(C.mO);C.H=U.clone();C.T7=U.clone();C.mO=U.clone();if(!f)C.T7.x+=2;
this.Qy(k)}else if(D.U(aK.Xu)){if(D.U(aK.WO))M=y.mr.RM(this.Uy,M);var z=C.H.eu(C.mO),s=C.T7.eu(C.H);
C.mO=M;C.H=M.add(z);C.T7=C.H.add(s)}else{if(D.U(aK.WO))M=y.mr.RM(C.H,M);if(this.tu){var O=C.T7;C.T7=C.mO;
C.mO=O}if(this.GE){var a=ec.cS(C.H,M),X=a==0?0:ec.cS(C.H,C.mO)/a;C.mO.x=C.H.x+X*(M.x-C.H.x);C.mO.y=C.H.y+X*(M.y-C.H.y)}else C.mO=M;
if(D.U(aK.PJ)&&!this.Vo)C.type=5;else{C.type=4;C.T7=C.H.add(C.H.eu(M))}this.Uy=M;if(this.tu){var O=C.T7;
C.T7=C.mO;C.mO=O}}this.z6(w,g.p_,k,g.add.vogk);w.RP=!0};y.p4.prototype.H5=function(w,n,W,D,j){if(this.Dr==null)return;
var I=w.OV(W.R_==1),U=I[0],M=I[1],m=U[M.pop()],l=m.add.vmsk,A=m.add.vogk;if(this.GE){l.Rw=[];this.z6(w,m.p_,l,m.add.vogk)}var g=this.Dr.i.length,k=l.i.length;
if(!this.XH)this.sc(w,this.GE?"Close Path":(g==k?"Move":g<k?"Add":"Delete")+" Anchor Point",m.p_,this.Dr,l.clone(),null,this.Q3,JSON.stringify(A));
this.XH=!1;this.GE=!1;this.tu=!1;this.Vo=!1;this.Dr=null};y.p4.prototype.sm=function(w,n,W,D,j){this.ahq=w.binop};
y.f3=function(){y.IG.call(this,[10,30],y.o4,"tools/fpen",!1)};y.f3.prototype=new y.IG;y.f3.prototype.Cy=function(w,n,W,D,j,I){var U=D.length-1,M=Math.sqrt((D[U-1]-D[0])*(D[U-1]-D[0])+(D[U]-D[1])*(D[U]-D[1]))<6/j.N;
return[E.P.YT(D,M,I),E.X.k5("customShape",[0,0,1,1],null,null,null,"--")]};y.hn=function(){y.rK.call(this,[10,27],y.Au,"tools/pselect");
this.Zc=null;this.Ut=!1;this.gj=null;this.Dr=null;this.P3=null;this.Q3=null;this.Bv=null;this.Ry=null;
this.Sm=null;this.hy=null};y.hn.prototype=new y.rK;y.hn.prototype.LL=function(w){return w.WS};y.hn.prototype.WQ=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=w.OV(),M=U[0],m=U[1],l,A;
for(var L=0;L<m.length;L++){var g=M[m[L]],k=g.add.vmsk,$=E.P.pw(k.i,I).p_;if($!=-1){this.gj=l=g;A=$}for(var C=0;
C<k.H3.length;C++){var f=E.P.QZ(k.i,k.H3[C]);if(f==null)continue;var z=ec.cS(f,I);if(z<4*y.V()/w.u.N){var s=w.C[g.p_-1e6].add.TySh,O=s._o.Curve,a=s.D,X=O.Reversed;
O.Reversed=!1;var O=d2.AL(s._o.Curve);O.Reversed=X;E.p.D(O[0],a,O[0]);this.Sm=[O,C,a.dl*a.j7-a.k*a.Cj];
this.gj=l=g;A=0}}if(this.Sm)break}if(l!=null){var k=l.add.vmsk;k.Rw=[];var P=k.g.indexOf(A);if(D.U(aK.WO)){if(P==-1){k.g.push(A);
this.Ut=!0}else k.g.splice(P,1)}else{if(P==-1)k.g=[A];this.Ut=!0}this.Ry=E.P.b3(k.i,k.g)}this.Zc=I;this.hy=new h3(I);
w.rR=!0;w.RP=!0};y.hn.prototype.QD=function(w,n,W,D,j){if(this.Zc==null)return;var I=w.u.Cg(j.x,j.y);
if(this.Ut){I=this.hy.db(I,D);var U=this.gj;if(this.Dr==null){this.Dr=this.P3=U.add.vmsk.clone();this.Q3=this.Bv=JSON.stringify(U.add.vogk);
if(D.U(aK.PJ)){var M=this.Dr.clone(),m=JSON.parse(this.Q3),l=y.rK.WR(M,m);y.rK.J4(l,M,m);this.P3=M;this.Bv=JSON.stringify(m)}}var M=this.P3.clone(),m=JSON.parse(this.Bv);
if(this.Sm){var A=this.Sm,g=A[0][0],k=E.p.VK(g,I.x,I.y);M.H3[A[1]]=A[0][1][k];var $=g[k*2],C=g[k*2+1],f=(g[k*2+2]-$)*(I.y-C)-(g[k*2+3]-C)*(I.x-$);
if(A[2]<0)f=-f;M.Ty=f>0}else{var z=this.Ry.clone(),s=z.x,O=z.y;z.offset(I.x-this.Zc.x,I.y-this.Zc.y);
z.x=Math.round(z.x);z.y=Math.round(z.y);var a=y.mU.uP(w,z,W),X=new eh(1,0,0,1,z.x-s+a[0],z.y-O+a[1]);
E.P.c0(M.i,X,M.g);E.X.D(m,E.K.yT(X),M.g);y.mU.Iy(w,z,a)}this.z6(w,U.p_,M,m)}else{var P=this.Zc;w.I.VZ=E.p.Wx(new iB(P.x,P.y,I.x-P.x,I.y-P.y));
w.RP=!0}};y.hn.prototype.H5=function(w,n,W,D,j){if(this.Zc==null)return;var I=w.u.Cg(j.x,j.y),U=this.gj,M=U?U.add.vmsk:null;
if(this.Ut){var m=JSON.stringify(U.add.vogk);if(!this.Zc.s9(I))this.sc(w,"Move Paths",U.p_,this.Dr,M,null,this.Q3,m);
if(w!=null&&w.I.t7){w.I.t7=null;w.RP=!0}}else{if(M){var l=this.Zc,A=new iB(l.x,l.y,I.x-l.x,I.y-l.y),g=E.P.a5K(M.i,A);
if(D.U(aK.WO)){for(var L=0;L<g.length;L++)if(M.g.indexOf(g[L])==-1)M.g.push(g[L])}else M.g=g}w.I.VZ=null;
w.RP=!0}this.Zc=null;this.Dr=null;this.Sm=null;this.Ut=!1;this.hy=null};y.hn.prototype.BW=function(w,n,W,D){y.rK.prototype.BW.call(this,w,n,W,D);
if(W.No!=this.id)return;if(w.g.length==0)return;var j=w.OV(),I=j[0],U=j[1];if(U.length==0)return;var M=I[U[0]],m=M.add.vmsk,l=M.add.vstk,A=M.add.vogk,g=new ed(b.E.L,!0);
g.data={d:b.c.Bg,G:this.id,_b:"main",XF:m?m:null,X:A};n.S(g)};y.hn.prototype.sm=function(w,n,W,D,j){var I=w.HD;
if(I.XF){var U=W.OV(),M=U[0],m=U[1];if(m.length==0)return;var l=M[m[0]],A=l.add.vmsk.clone(),g=JSON.stringify(l.add.vogk),k=I.XF;
this.z6(W,l.p_,k,I.X);var $=[18,5];if(A.i.length==k.i.length)$=A.g[0]==k.g[0]?"Fill Rule":"Path Order";
this.sc(W,$,l.p_,A,k,null,g,JSON.stringify(I.X))}};y.Z5=function(){y.rK.call(this,[10,28],y.Kr,"tools/dselect");
this.rF=-1;this.Ik=-1;this.wQ=null;this.Zc=null;this.gj=null;this.Dr=null;this.Q3=null;this.yV=null;
this.ft=0;this.Ah={psnap:!1};this.hy=null};y.Z5.prototype=new y.rK;y.Z5.prototype.LL=function(w){return w.WS};
y.Z5.prototype.sm=function(w){this.Ah=w};y.Z5.prototype.Al=function(w,n,W,D,j){if(w.d=="crnr"){if(W==null)return;
var I=W.OV(),U=I[0],M=I[1];if(M.length==0){alert("No paths selected");return}var m=U[M[0]],l=m.add.vmsk;
if(l.Rw.length==0){alert("No corners selected");return}for(var L=0;L<l.Rw.length;L++){var A=l.i[l.Rw[L]];
if(!A.H.s9(A.mO)||!A.H.s9(A.T7)){alert("Only sharp corners can be rounded");return}}if(this.Dr==null){this.Dr=m.add.vmsk.clone();
this.Q3=JSON.stringify(m.add.vogk);this.gj=m;this.yV=W}var g=new ed(b.E.L,!0);g.data={d:b.c.P2,jW:"cornerradius",Z1:5,FJ:this.amL.bind(this)};
n.S(g)}else y.rK.prototype.Al.call(this,w,n,W,D,j)};y.Z5.prototype.amL=function(w){if(w=="confirm"){var n=this.yV,W=this.gj,D=W.add.vmsk,j=W.add.vogk;
this.sc(n,[12,94,0],W.p_,this.Dr,D,null,this.Q3,JSON.stringify(j));this.fm();return}var D=this.Dr.clone(),j=JSON.parse(this.Q3),I=D.Rw;
if(w=="cancel"){}else{var U=[];for(var L=0;L<I.length;L++){var M=I[L],m=E.P.de(D.i,M,!0),g=0;if(U.indexOf(m)!=-1)continue;
U.push(m);var l=E.P.tt(D.i,m,!0),A=D.i[l].length,k=[];for(var $=0;$<A;$++){var C=D.Rw.indexOf(l+$+1)==-1?0:w;
k.push(C);if(C!=0)g++}E.P.QG(D.i,l,k);for(var $=0;$<I.length;$++)if(I[$]>l+A)I[$]+=g}this.v6(D,j);D.Rw=[]}this.z6(this.yV,this.gj.p_,D,j);
if(w=="cancel")this.fm()};y.Z5.prototype.disable=function(w,n,W,D){this.af(w)};y.Z5.prototype.WQ=function(w,n,W,D,j){this.af(w);
var I=w.u.Cg(j.x,j.y),g,k,$;this.wQ=I.clone();var U=w.OV(),M=U[0],m=U[1];if(m.length==0)return;var l=y.N5(w,j),A=new iB(I.x-l,I.y-l,l*2,l*2);
for(var C=0;C<m.length;C++){g=this.gj=M[m[C]];k=g.add.vmsk;$=E.P.qk(k.i,A);if($[0].length+$[1].length+$[2].length!=0)break}var f=[!1,!1,!1];
for(var L=0;L<3;L++){for(var z=0;z<$[L].length;z++){var s=$[L][z],O=k.i[s];if(k.Rw.indexOf(s)!=-1||L==1&&k.Rw.indexOf(s-1)!=-1&&!O.H.s9(O.T7)||L==2&&k.Rw.indexOf(s+1)!=-1&&!O.H.s9(O.mO)){$[L]=[s];
f[L]=!0;break}}}if($[0].length!=0&&(f[0]||!f[1]&&!f[2])){var a=$[0][0],X=k.Rw.indexOf(a);if(D.U(aK.WO)){if(X==-1)k.Rw.push(a);
else{k.Rw.splice(X,1);w.RP=!0;return}}else if(X==-1)k.Rw=[a];this.rF=a;this.Ik=0}else if($[1].length!=0&&f[1]){this.rF=$[1][0];
this.Ik=1}else if($[2].length!=0&&f[2]){this.rF=$[2][0];this.Ik=2}else{var P=E.P.pw(k.i,I,!0,l);if(P.p_==-1)this.Zc=I;
else{k.g=[P.p_];k.Rw=[]}}if(this.Dr==null){this.Dr=g.add.vmsk.clone();this.Q3=JSON.stringify(g.add.vogk)}this.hy=new h3(I);
w.RP=!0};y.Z5.prototype.QD=function(w,n,W,D,j){if(w==null)return;var I=w.u.Cg(j.x,j.y),U=this.gj;if(this.rF!=-1){var M=this.Dr.clone(),m=U.add.vogk,l=M.i[this.rF];
l=[l.H,l.T7,l.mO][this.Ik];if(D.U(aK.WO)){if(this.Ik==0){I=this.hy.db(I,D);I.x+=l.x-this.wQ.x;I.y+=l.y-this.wQ.y}else I=y.mr.RM(M.i[this.rF].H,I)}else{if(this.Ah.psnap){I.x=Math.round(I.x);
I.y=Math.round(I.y)}I=y.mU.JW(w,I,W)}if(this.Ik==0){var A=new eh(1,0,0,1,I.x-l.x,I.y-l.y);E.P.c0(M.i,A,null,M.Rw)}else{var g=M.i[this.rF],k=g.T7,$=g.mO;
if(this.Ik==2){k=g.mO;$=g.T7}if(D.U(aK.PJ)&&(g.type==1||g.type==4))g.type++;k.y1(I.x,I.y);if(g.type==1||g.type==4){var C=ec.cS(k,g.H),f=ec.cS($,g.H);
if(f!=0){$.x=g.H.x-(k.x-g.H.x)*(f/C);$.y=g.H.y-(k.y-g.H.y)*(f/C)}}}this.v6(M,m);this.z6(w,U.p_,M,m)}else if(this.Zc!=null){var z=this.Zc;
w.I.VZ=E.p.Wx(new iB(z.x,z.y,I.x-z.x,I.y-z.y));w.RP=!0}else{var s=w.OV(),O=s[0],a=s[1],U,M,Z;if(a.length==0)return;
var X=y.N5(w,j),P=new iB(I.x-X,I.y-X,X*2,X*2);for(var Y=0;Y<a.length;Y++){U=O[a[Y]];M=U.add.vmsk;Z=E.P.qk(M.i,P);
if(Z[0].length+Z[1].length+Z[2].length!=0)break}this.af(w);for(var L=0;L<3;L++){for(var K=0;K<Z[L].length;
K++){var S=Z[L][K],G=M.i[S];G=L==0?G.H:L==1?G.T7:G.mO;w.I.hA.push(w.I.r4.length>>>1);w.I.r4.push(G.x,G.y);
w.RP=!0}}}};y.Z5.prototype.af=function(w){if(w&&w.I.r4.length!=0){w.I.r4=[];w.I.hA=[];w.RP=!0}};y.Z5.prototype.H5=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=this.gj,M=U?U.add.vmsk:null,m=U?U.add.vogk:null;
if(this.rF!=-1){if(Date.now()-this.ft<300){var l=M.i[this.rF],A=this.Ik,g=null;if(A==0){var k=l.T7.s9(l.H),$=l.mO.s9(l.H);
if(!k&&!$){g="Anchor Type";if(l.type==1||l.type==4)l.type++;else{l.type--;l.mO=l.H.add(l.H.eu(l.T7))}}else{g="Add Handles";
if(k&&$){l.T7.x-=30;l.mO.x+=30}else if(k)l.T7=l.H.add(l.H.eu(l.mO));else if($)l.mO=l.H.add(l.H.eu(l.T7))}}else{g="Remove Handle";
if(A==1)l.T7.$d(l.H);else l.mO.$d(l.H)}this.v6(M,m);this.z6(w,U.p_,M,m);this.sc(w,g,U.p_,this.Dr,M,null,this.Q3,JSON.stringify(m))}else if(!this.wQ.s9(I)){this.sc(w,"Drag Anchors",U.p_,this.Dr,M,null,this.Q3,JSON.stringify(m))}this.ft=Date.now()}else if(this.Zc!=null){var C=this.Zc,f=new iB(C.x,C.y,I.x-C.x,I.y-C.y);
if(f.m<0)f.x+=f.m;if(f.n<0)f.y+=f.n;f.m=Math.abs(f.m);f.n=Math.abs(f.n);var z=E.P.qk(M.i,f);M.Rw=z[0].concat(D.U(aK.WO)?M.Rw:[]);
w.I.VZ=null}this.fm();w.RP=!0};y.Z5.prototype.fm=function(){this.gj=null;this.Dr=null;this.Zc=null;this.rF=this.Ik=-1;
this.hy=null};y.Z5.prototype.v6=function(w,n){for(var L=0;L<w.Rw.length;L++){var W=E.P.de(w.i,w.Rw[L]);
E.X.$G(n,W)}};y.Z5.prototype.oe=function(w,n,W,D){if(w==null)return;var j=w.OV(),I=j[0],U=j[1];if(U.length==0)return;
var M=I[U[0]],m=M.add.vmsk;if(m==null||m.Rw.length==0)return;var l=M.add.vogk,A=JSON.stringify(l),g=D.aa(w?w.u.Tg:0);
if(g.x!=0||g.y!=0){var k=m.clone(),$=m.clone(),C=new eh(1,0,0,1,g.x,g.y);E.P.c0($.i,C,null,$.Rw);this.v6($,l);
this.z6(w,M.p_,$,l);this.sc(w,"Move Anchors",w.g[0],k,$.clone(),!0,A,JSON.stringify(l))}if(D.U(aK.m2)||D.U(aK.on))this.Al({d:"remove",gi:!0,aaH:!0},n,w,D,W)};
y.Z5.prototype.sc=function(w,n,W,D,j,I,U,M){var m=w.by();if(I&&m!=null&&m.G==this&&m.data.ae8&&m.data.Ay==W&&JSON.stringify(m.data.Hi.Rw)==JSON.stringify(D.Rw)){m.data.DG=j;
m.data.Gj=M}else{var m=new go(n,this);m.data={Ay:W,Hi:D,DG:j,ae8:I,adj:U,Gj:M};w.kK(m)}};y.Rect=function(){y.IG.call(this,[10,32],y.K7,"tools/rect",!0)};
y.Rect.prototype=new y.IG;y.Rect.prototype.Cy=function(w,n,W){var D=this.RQ.crad,j=n.x-w.x,I=n.y-w.y;
return[E.P.AB.Rect(w.x,w.y,j,I,D),E.X.k5("Rctn",[w.x,w.y,n.x,n.y],[D,D,D,D])]};y.Po=function(){y.IG.call(this,[10,33],y.Ww,"tools/ellipse",!0)};
y.Po.prototype=new y.IG;y.Po.prototype.Cy=function(w,n,W){var D=n.x-w.x,j=n.y-w.y;return[E.P.AB.Po(w.x,w.y,D,j),E.X.k5("Elps",[w.x,w.y,n.x,n.y])]};
y.Dz=function(){y.IG.call(this,[10,34],y.Eh,"tools/pshape",!1);this.RQ.aopts=[!1,!0,50,100,0]};y.Dz.prototype=new y.IG;
y.Dz.prototype.Cy=function(w,n,W){var D=this.RQ.pshape,j=this.RQ.crad,I=this.RQ.irad/100,U=this.RQ.sides,M=this.RQ.width,m=this.RQ.aopts,l=this.RQ.length,z;
n=n.clone();var A=w.x,g=w.y,k=n.x,$=n.y,C=Math.sqrt((k-A)*(k-A)+($-g)*($-g)),f=Math.atan2(-$+g,k-A);
if(W)f=Math.round(f*180/Math.PI/15)*15*Math.PI/180;if(D==0)z=E.P.AB.Je(A,g,C,f,U,j);if(D==1)z=E.P.AB.c4(A,g,C,f,U,j,I);
if(D==2)z=E.P.AB.JJ(w.x,w.y,n.x,n.y,M,m);if(D==3)z=E.P.AB.at5(A,g,C,f,l);return[z,E.X.k5("customShape",[w.x,w.y,n.x,n.y],null,null,null,"--")]};
y.Dz.prototype.oe=function(w,n,W,D){y.IG.prototype.oe.call(this,w,n,W,D);var j=D.aa(),I=this.RQ,U,M;
if(j.y!=0){var m=-j.y,l=I.pshape;if(l<2){U="sides";M=Math.max(3,Math.min(100,I.sides+m))}else if(l==2){U="width";
M=Math.max(1,Math.min(100,I.width+m))}else if(l==3){U="length";M=Math.max(4,Math.min(40,I.length+m))}}if(j.x!=0){U="pshape";
M=Math.max(0,Math.min(3,I.pshape+j.x))}if(U){var A=new ed(b.E.L,!0),g={};g[U]=M;I[U]=M;A.data={d:b.c.Bg,G:this.id,vK:"vals",a17:g};
n.S(A);this.QD(w,n,W,D)}};y.xK=function(){y.IG.call(this,[10,35],y.Hw,"tools/line",!1)};y.xK.prototype=new y.IG;
y.xK.prototype.Cy=function(w,n,W){var D=this.RQ.width,j=this.RQ.aopts;n=n.clone();if(W){n=y.mr.RM(w,n)}return[E.P.AB.JJ(w.x,w.y,n.x,n.y,D,j),E.X.k5("Ln",null,null,[w.x,w.y,n.x,n.y],D,null,j)]};
y.r2=function(){y.IG.call(this,[10,31],y.dY,"tools/cshape",!0)};y.r2.prototype=new y.IG;y.r2.prototype.Cy=function(w,n,W){var D=this.RQ.shape,j=D.H8.m/D.H8.n,I=h.Rd.Tv(D.i);
n=n.clone();if(W){n.y=w.y+(n.x-w.x)/j}var U=n.x-w.x,M=n.y-w.y;E.P.c0(I,new eh(U,0,0,M,w.x,w.y));return[I,E.X.k5("customShape",[w.x,w.y,n.x,n.y],null,null,null,D.fR)]};
y.wR=function(w,n,W){y.qw.call(this,w,n,W);this.rf=0;this.C=null;this.wN=null;this.Yo=null;this.Yk=1;
this.yx=!0;this.H6=!1;this.cursor=null;this.Zw=null;this.Py=null;this.vX=!1;this.qm=null;this.aA5=0;
this.WX=null;this.y6=0;this.G8=null;this.yU=null;this.X8=null;this.pt=null;this.aiz=null;this.ms=null};
y.wR.prototype=new y.qw;y.wR.CO=function(w,n,W){var D={classID:"null",null:cq.Pz(W?"Lyr":"Dcmn",!0)};
if(w)D.Angl={t:"UntF",v:{type:"#Ang",val:n}};else D.Axis={t:"enum",v:{Ornt:n}};return{hZ:w?"rotateEventEnum":"flip",E3:D}};
y.wR.prototype.cF=function(w,n,W,D,j){var I=new ed(b.E.L,!0);I.data={d:b.c.Bg,G:this.id,ao:j,AR:w,Yo:W};
n.S(I);this.QH=!1};y.wR.prototype.LL=function(w){return this.yU&&this.yU.aou()};y.wR.prototype.Al=function(w,n,W,D,j){this.Yo=j;
if(w.d=="again"&&this.WX==null)return;if(!this.Tr(W,j))return;if(this.yU){this.ajk(w,this.yU.I7(),n,W,D,j);
this.uE(W,j,0,!0);this.OA(W);return}this.ayx(W,w.j==null,w.j);this.akB(W);this.ajk(w,w.aik,n,W,D,j);
this.Jh(W,n,w.s7,!1)};y.wR.prototype.ajk=function(w,n,W,D,j,I){var U=this.G8;if(n==null){var M=w.Zl!=null?w.Zl:4;
n=this.yU.a5e()[M]}var m=n.x,l=n.y;if(w.d=="rot"&&w.Z!=Math.PI&&(U.m+U.n&1)==1){m=Math.floor(m);l=Math.floor(l)}var A=new eh;
A.translate(-m,-l);if(w.d=="rot")A.rotate(w.Z);if(w.d=="scl")A.scale(w.Z.x,w.Z.y);if(w.d=="mat")A.concat(w.Z);
A.translate(m,l);if(w.d=="again")A=this.WX;var g=E.K.yT(A);if(w.d=="dtr"){var k=E.K;g=k.y9(w.Z,k.Q(-m,-l));
g=k.y9(k.Q(m,l),g)}var $=this.yU.W2();E.K.D(g,$);this.yU.vY($);if(w.gz){var C=w.gz.v;this.sm({_b:"switchWarp"},W,D,j);
this.sm({_b:"wrp",gz:C},W,D,j)}};y.wR.prototype.wb=function(){return!0};y.wR.prototype.Tr=function(w,n){if(w==null)return!1;
if(this.id==y.Zt)return w.J!=null;var W=w.qu(!0,null,null,!0);if(this.id==y.uW&&w.C[W[0]].rect.VY()){alert("Layer is empty.");
return!1}for(var L=0;L<W.length;L++){var D=w.C[W[L]];if(D.m7(2)||D.m7(31)){alert(fV.get([6,57,0]));return!1}if(D.add.artb){alert("You can not transform the whole artboard");
return!1}if(D.add.TySh)if(!aj.bN(D.add.TySh,n.hY))return!1;if(D.add.SoLd){if(W.length==1&&!E.XB.pi(D.add.SoLd.warp.v)&&(D._N()&&D._N().gm||D.add.vmsk&&D.add.vmsk.gm)){alert("Unlink masks before transforming Smart Object");
return!1}if(!w.abg(D.add.SoLd.Idnt.v)){alert("Unsupported format of the smart object ("+w.mZ(D.add.SoLd.Idnt.v).O7+")");
return!1}}}if(w.J==null)return!0;if(!w.d2())return!1;return w.aiC()};y.wR.prototype.WQ=function(w,n,W,D,j){var I=this.aAF(j,w),U=I[0],M=I[1],m=this.y6==0?this.yU:this.X8;
w.u.N*=M;this.H6=m.WQ(w,W,D,U,null,null,j);w.u.N/=M;if(this.H6&&m.gO(U)){if(Date.now()-this.aA5<250)this.Jh(w,n,null,!0);
this.aA5=Date.now()}};y.wR.prototype.eg=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.ph,In:this.cursor};
w.S(n)};y.wR.prototype.aAF=function(w,n){var W=1;w=n.u.Cg(w.x,w.y);if(this.y6==1){var D=E.K.kN(this.yU.W2(),this.G8);
W=E.K.OT(D).NW();var j=E.K.Ba(D);w=E.K.ac8(j,w)}return[w,W]};y.wR.prototype.QD=function(w,n,W,D,j){var I=this.aAF(j,w),U=I[0],M=I[1],m=this.y6==0?this.yU:this.X8;
if(!j.WS){var l="default";if(m){var A=m.G_(U,w.u.N*M,null,j);if(A)l=A}if(l!=this.cursor){this.cursor=l;
this.eg(n)}}if(!this.H6)return;w.u.N*=M;m.QD(w,W,D,U,this.yx);w.u.N/=M;this.uE(w,W,0,!0);this.OA(w);
this.$T(n)};y.wR.prototype.H5=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);this.yU.H5(w,W,D,I);this.H6=!1};
y.wR.prototype.oe=function(w,n,W,D){if(D.U(aK.yG))this.Jh(w,n,null,!0);else if(D.U(aK.QX))this.oz(w,n);
else{var j=this.yU.oe(w,W,D);if(j){this.uE(w,W,0,!0);this.$T(n)}}};y.wR.prototype.sm=function(w,n,W,D){if(w._b=="commit")this.Jh(W,n,null,!0);
else if(w._b=="cancel")this.oz(W,n);else if(w._b=="switchWarp"){this.y6=1-this.y6;this.anh();this.OA(W);
this.$T(n)}else if(w._b=="wrp"){this.X8.a8B(w.gz);this.OA(W);this.uE(W,this.Yo,0,!0)}else if(w._b=="ctyp"){this.yU.apg(w.wL);
this.OA(W);this.$T(n)}else if(w._b=="cen"){this.yU.a6Q(w.Q5);this.OA(W);this.uE(W,this.Yo,0,!0)}else if(w._b=="trn"){var j=E.K.yT(w.V7),I=this.G8,U=E.K.kN(this.yU.W2(),this.G8);
j[6]=U[6],j[7]=U[7];var M=[I.x,I.y,I.x+I.m,I.y,I.x+I.m,I.y+I.n,I.x,I.y+I.n];E.K.D(j,M);this.Yk=w.Yk;
this.yx=w.yx;this.yU.vY(M);this.OA(W);this.uE(W,this.Yo,0,!0)}};y.wR.prototype.OA=function(w){if(this.y6==0)this.yU.qz(w,this.Yo);
else{this.X8.qz(w);var n=E.K.kN(this.yU.W2(),this.G8);E.K.D(n,w.I.VZ.w);E.K.D(n,w.I.cc)}};y.wR.prototype.Jh=function(w,n,W,D){this.uE(w,this.Yo,this.Yk);
var j=new go(W?W:this.name,this),s="";if(this.rf==0)j.data={type:this.rf,C:this.C,qm:this.wN,Hb:y.wR.ZQ(w,this.C)};
else if(this.rf==1){var I=w.C[this.C[0]],U;if(I.zZ.eL<=0){U=E.Q(I.zZ.M0.O());E.hN(I.zZ.WL,U,3)}else U=w.J.channel;
var M={rect:I.zZ.M0.clone(),channel:U};j.data={type:this.rf,j:this.C[0],Py:this.Py,TY:M,Zw:this.Zw,vX:this.vX,zZ:I.zZ,qm:this.qm,Hb:{WH:I.zZ.M0,Ey:I.zZ.WL}}}else if(this.rf==2){j.data={type:this.rf,Py:this.Py,TY:{rect:w.J.rect.clone(),channel:w.J.channel.slice(0)}}}w.kK(j);
var m=this.G8,l=E.K.kN(this.yU.W2(),m),A=E.K.OT(l),g=this.yU.I7(),k=new eh;k.translate(g.x,g.y);k.concat(A);
k.translate(-g.x,-g.y);A=k.clone();var $=-Math.atan2(-A.k,A.dl),C=new eh;C.rotate($);A.concat(C);function f(Z,Y){return{t:"UntF",v:{type:["#Pxl","#Prc","#Ang"][Y],val:Z}}}var z=cq.Pz("Lyr",!0);
if(this.id==y.Zt)z.v[0]={t:"prop",v:{classID:"Chnl",keyID:"fsel"}};var O=y.wR.axK;for(var a in O)if(O[a]==this.yU.lK)s=a;
if(s==""){s="Qcsi";k.z2=k.EU=0}var X={classID:"null",null:z,FTcs:{t:"enum",v:{QCSt:s}},Intr:{t:"enum",v:{Intp:"Bcbc"}},Ofst:{t:"Objc",v:{__name:"Offset",classID:"Ofst",Hrzn:f(k.z2,0),Vrtc:f(k.EU,0)}},Skew:{t:"Objc",v:{classID:"Pnt",Hrzn:f(Math.atan(A.Cj/A.j7)*180/Math.PI,2),Vrtc:f(0,2)}},Usng:{t:"Objc",v:{classID:"Pnt",Hrzn:f(100*0,1),Vrtc:f(100*0,1)}},Wdth:f(A.dl*100,1),Hght:f(A.j7*100,1),Angl:f($*180/Math.PI,2)};
if(s=="Qcsi")X.Pstn={t:"Objc",v:{Hrzn:f(g.x,0),Vrtc:f(g.y,0)}};var P=this.X8?this.X8.l4():null;if(P&&!E.XB.pi(P)){X.warp={t:"Objc",v:P}}this.xh=n;
this.track({hZ:"transform",E3:X});this.escape(w,n,D)};y.wR.axK={Qcsa:4,Qcs0:0,Qcs1:2,Qcs2:8,Qcs3:6,Qcs4:1,Qcs5:5,Qcs6:7,Qcs7:3};
y.wR.prototype.oz=function(w,n){if(this.rf==0)y.wR.k9(w,this.C,this.wN);else if(this.rf==1){var W=w.C[this.C[0]];
w.J=this.Py;if(!this.vX){W.zZ.M0=this.qm.WH;W.zZ.WL=this.qm.Ey;W.p9(w,0,0,w.J)}else{W.$H(w,this.Zw)}w.l();
w.Iq=!0}else if(this.rf==2){w.J=this.Py;w.Iq=!0}this.escape(w,n,!0)};y.wR.prototype.escape=function(w,n,W){this.yU.clear(w);
this.yU=null;this.X8=null;this.ms=null;this.y6=0;if(W)this.CP(n,b.E.L,{d:b.c.Oy})};y.wR.prototype.Fd=function(w,n){if(w.type==0)y.wR.k9(n,w.C,w.Hb);
else{if(w.type==1){var W=n.C[w.j];if(w.vX){W.zZ=w.zZ}else{W.zZ.M0=w.Hb.WH;W.zZ.WL=w.Hb.Ey}W.p9(n,0,0,n.J);
n.l()}n.J={rect:w.TY.rect.clone(),channel:w.TY.channel.slice(0)};n.Iq=!0}};y.wR.prototype.ZE=function(w,n){if(w.type==0)y.wR.k9(n,w.C,w.qm);
else{if(w.type==1){var W=n.C[w.j];if(w.vX){W.$H(n,w.Zw)}else{W.zZ.M0=w.qm.WH;W.zZ.WL=w.qm.Ey;W.p9(n,0,0,n.J)}n.l()}n.J=w.Py;
n.Iq=!0}};y.wR.prototype.ayx=function(w,n,W){w.OV();var D=[];if(W==null)for(var L=0;L<w.rs.length;L++)if(w.Oi[w.rs[L]].add.vmsk.i.length>2)D.push(-1-w.rs[L]);
var j=[],I=w.u.zC;if(I[0]+I[1]+I[2]==3)if(W!=null||D.length==0||w.zS!=null&&w.zS.length!=0){if(w.g.length==1){var U=w.C[w.g[0]];
if(U.ue()&&U.na)j=[w.g[0]]}if(j.length==0)j=w.qu(n,W,null,!0)}j=j.concat(D);for(var L=0;L<w.v9.length;
L++)j.push(-1e3-w.v9[L]);this.C=j};y.wR.prototype.enable=function(w,n,W,D,j,I){if(this.cursor==null)this.cursor="default";
this.eg(n);if(this.yU)return;this.Yo=W;this.ayx(w,!0);this.akB(w,I&&I.IZ!=null&&I.IZ!=-1?I.IZ:null);
this.$T(n);this.OA(w);if(I&&I.IZ==-1)this.sm({_b:"switchWarp"},n,w,D)};y.wR.prototype.Th=function(){return[this.yx?1:0]};
y.wR.prototype.QW=function(w,n,W){if(w&&w[0]!=null)this.yx=w[0]==1};y.wR.prototype.$T=function(w){var n={d:b.c.Bg,G:this.id};
if(this.y6==0){var W=E.K.kN(this.yU.W2(),this.G8),D=E.K.OT(W);n.V7={GY:D,wL:this.yU.aqO(),Q5:this.yU.I7(),WH:this.G8.clone(),yx:this.yx}}else{n.gz=this.X8.l4()}n.apE=this.X8!=null;
this.CP(w,b.E.L,n)};y.wR.prototype.akB=function(w,n){var W=this.id==y.Zt,D=!0,j=this.C[0],I=w.C[j],M=null,m=null;
if(W){this.rf=2;this.Py=w.J}else if(w.J&&this.C.length==1&&j>=0&&!I.rect.VY()){this.rf=1;this.Py=w.J;
this.Zw=I.zZ;this.vX=!1;if(!I.er(w,w.J)){this.vX=!0;I.Eo(w,w.J,!1)}this.qm={Ey:I.zZ.WL,WH:I.zZ.M0}}else{this.rf=0;
this.wN=y.wR.ZQ(w,this.C,null);for(var L=0;L<this.wN.length;L++)if(this.wN[L][3]!=null)D=!1}var U=this.rf==1;
if(this.wN&&this.wN.length==1){var l=this.wN[0];if(l[2]!=null&&l[2].X){var A=l[2].XF.g;if(A.length<2){m=l[2].X[A.length==0?0:A[0]].v;
if(!E.X.OL(m))m=null}}if(l[3]==null)U=!0;if(l[4]!=null){M=w.C[this.C[0]].add.SoLd;if(l[1]||l[2])U=!1}}var g=W?w.J.rect.clone():y.wR.pJ(w,this.C);
this.G8=g;if(!W&&M){var k=y.wR.Aa(M.nonAffineTransform);this.G8=E.p.mY(E.XB.BI(M.warp.v));if(U)this.X8=new dg(M.warp.v);
this.pt=E.K.kN(k,this.G8);this.yU=new gX(k,!0,!0,D,!1,!1,n)}else{if(U||W)this.X8=new dg(E.XB.Q(this.G8));
this.pt=[1,0,0,0,1,0,0,0];if(this.id==y.uW)n=3;this.yU=new gX([g.x,g.y,g.x+g.m,g.y,g.x+g.m,g.y+g.n,g.x,g.y+g.n],!0,!0,D,!1,!1,n)}this.aiz=[1,0,0,0,1,0,0,0];
if(this.id==y.uW){var $,C;if(this.wN){var f=this.wN[0][0],z=f.Kd;$=z[0];C=z[1]}else if(this.qm){$=this.qm.Ey;
C=this.qm.WH}this.ms=E.kY.a4P($,C.m,C.n)}};y.wR.pJ=function(w,n){if(n==null)n=w.qu(!0,null,null,!0);
var W=new iB,D=new iB;if(w.J&&n.length==1&&n[0]>=0)W=w.J.rect.clone();else for(var L=0;L<n.length;L++){var j=n[L],I=0<=j?w.C[j]:-1e3<j?w.Oi[-1-j]:w.yo[-1e3-j],U=I.add?I.add.vmsk:null,M=0<=j?I.$k(w,n.length==1,!1,!0):-1e3<j?E.P.b3(U.i,n.length==1&&U.g.length!=0?U.g:null):I.rect.clone();
W=W.x0(M);if(j>0&&I.add.artb)D=D.x0(I.yP())}return!D.VY()?D:W};y.wR.prototype.CP=function(w,n,W,D){var j=new ed(n,!0);
j.data=W;if(D)j.G=D;w.S(j)};y.wR.ZQ=function(w,n,W){var D=[];for(var L=0;L<n.length;L++){var j=n[L],I,U;
if(j>=0){I=w.C[j];U=I.V6(w,W,!0)}else if(j>-1e3){I=w.Oi[-1-j];U=[2]}else{D.push([null,null,null,null,null,null,null,w.yo[-1e3-j].clone()]);
continue}var M=[],m=U.indexOf(0)!=-1;if(m){var l={Kd:I.add.SoLd?null:[I.buffer.slice(0),I.rect.clone()]};
M.push(l);if(I.YC()){var A=I.NP(w);l.a8y=A.buffer.slice(0);l.aoa=A.rect.clone()}}else M.push(null);if(U.indexOf(1)!=-1)M.push(I._N().clone());
else M.push(null);if(U.indexOf(2)!=-1)M.push({XF:I.add.vmsk.clone(),QO:I.add.vstk?JSON.parse(JSON.stringify(I.add.vstk)):null,S8:I.add.vstk?y.rK.wj(w,j):null,X:I.add.vogk?JSON.parse(JSON.stringify(I.add.vogk)):null});
else M.push(null);if(I.add.TySh&&m){hd.Y_(I.add.TySh);M.push(I.add.TySh.D.clone())}else M.push(null);
if(I.add.SoLd&&m)M.push(JSON.parse(JSON.stringify(I.add.SoLd)));else M.push(null);if(U.indexOf(3)!=-1)M.push(I.NP(w).z.clone());
else M.push(null);if(I.add.lmfx)M.push(JSON.stringify(I.add.lmfx));else M.push(null);D.push(M)}return D};
y.wR.k9=function(w,n,W){for(var L=0;L<n.length;L++){var D=n[L],j=0<=D?w.C[D]:-1e3<D?w.Oi[-1-D]:w.yo[-1e3-D],I=W[L];
if(I[0]){if(I[0].Kd){j.rect=I[0].Kd[1].clone();j.buffer=I[0].Kd[0].slice(0)}if(j.YC()){var U=j.NP(w);
U.buffer=I[0].a8y.slice(0);U.rect=I[0].aoa.clone()}}if(I[1]){j._N().channel=I[1].channel.slice(0);j._N().rect=I[1].rect.clone();
j._N().eP=!0}if(I[2]){j.add.vmsk=I[2].XF.clone();if(I[2].S8)y.rK.KG(j,I[2].S8);if(I[2].QO)j.add.vstk=JSON.parse(JSON.stringify(I[2].QO));
if(I[2].X)j.add.vogk=JSON.parse(JSON.stringify(I[2].X))}if(I[3]){j.add.TySh.D=I[3].clone();hd.ls(j.add.TySh)}if(I[4]){j.add.SoLd=JSON.parse(JSON.stringify(I[4]))}if(I[5]){var M=j.NP(w).z;
M.channel=I[5].channel.slice(0);M.rect=I[5].rect.clone()}if(I[6]){j.add.lmfx=JSON.parse(I[6])}if(I[7]){j.channel=I[7].channel.slice(0);
j.rect=I[7].rect.clone();j.eP=!0}if(0<=D){j.yb(w);j.l();if(I[4])j.vr(w,!1)}}w.l()};y.wR.At=function(w,n,W,D,j,I,U,M,m,l){if(typeof I[0]=="number"){var A=[];
for(var L=0;L<W.length;L++)A[L]=I;I=A}for(var L=0;L<W.length;L++){var g=I[L],k=E.K.OT(g),$=k.NW(),C=W[L],f=0<=C?w.C[C]:-1e3<C?w.Oi[-1-C]:w.yo[-1e3-C],z=D[L];
if(f.add&&f.add.lmfx&&M)ge.Sq(f.add.lmfx,$);if(z[0]&&!z[3]&&!z[4]&&!z[5]){var s=z[0].Kd;if(m){var O=m.clone(),a=E.Q(O.O()*4);
E.Cb(s[0],s[1],a,O);s=[a,O]}var X=y.wR.z3(s,j,g,U,j==0?f.buffer.buffer:null,null,null,l);if(X){f.rect=X.rect;
f.buffer=X.buffer}}if(z[1]){var P=f._N();y.wR.S6(w,z[1],P,j,g,U,P.gm&&U&&!E.XB.pi(U)&&z[0]?z[0].Kd[1]:null);
if(m){var O=f.rect.wU(m),Z=E.Q(O.O());E.B0(P.channel,P.rect,Z,O);P.channel=Z;P.rect=O}}if(z[2]){var Y=U&&!E.XB.pi(U),K=z[2].XF.clone(),S=W.length==1&&K.g.length!=0,G=W.length==1&&K.Rw.length>1;
if(G)S=!1;var V=S?K.g:null,T=G?K.Rw:null;if(Y){var R=E.XB.BI(U);E.K.D(g,R);E.P.ayL(K.i,R,V,T)}else E.P.acl(K.i,g,V,T);
if(f.add.vstk&&M){f.add.vstk.strokeStyleLineWidth.v.val=z[2].QO.strokeStyleLineWidth.v.val*$;var x=z[2].S8;
if(x&&x.oq==3){x=JSON.parse(JSON.stringify(x));var v=x.S8.phase.v;x.S8.Scl.v.val=Math.round(x.S8.Scl.v.val*$);
v.Hrzn.v=Math.round(v.Hrzn.v*$);v.Vrtc.v=Math.round(v.Vrtc.v*$);y.rK.KG(f,x)}}if(f.add.vogk){f.add.vogk=JSON.parse(JSON.stringify(z[2].X));
if(Y||G)E.X.H4(f.add.vogk);else E.X.D(f.add.vogk,g,W.length>1?[]:K.g,M)}K.C3*=$;f.add.vmsk=K;if(f.add.vogk)E.X.A9(f.add.vogk,f.add.vmsk)}if(z[3]){var N=z[3].clone();
N.concat(k);f.add.TySh.D=N;hd.ls(f.add.TySh);aj.a5(f,n.hY)}if(z[4]){var u=f.add.SoLd,H=y.wR.Aa(z[4].nonAffineTransform);
E.K.D(g,H);var F=E.p.lV(H);if(gX.tj(H)){if(U){var t=E.p.mY(E.XB.BI(z[4].warp.v)),Z=E.K.kN(H,t),o=E.p.mY(E.XB.BI(U));
H=[o.x,o.y,o.x+o.m,o.y,o.x+o.m,o.y+o.n,o.x,o.y+o.n];E.K.D(Z,H);u.warp.v=U}var q=E.K.kN(H),_=H;if(!E.K.RC(q)){q[6]=q[7]=0;
_=[0,0,1,0,1,1,0,1];E.K.D(q,_)}u.Trnf=y.wR.Hh(_);u.nonAffineTransform=y.wR.Hh(H);if(u.filterFX)u.filterFX=JSON.parse(JSON.stringify(z[4].filterFX));
y.wR.a6n(u,k);f.vr(w,j==0,n.hY)}}if(z[5])y.wR.S6(w,z[5],f.NP(w).z,j,g,U);if(z[7])y.wR.S6(w,z[7],f,j,g,U);
if(0<=C){if(j!=0)f.ky();f.yb(w);f.l()}}w.l()};y.wR.aqN=function(w,n){var W=n.NW(),D=0;E.BB(w);while(W<.45&&D<w.length-4){D+=2;
W*=2;var j=new eh;j.scale(2,2);j.concat(n);n=j}var I=w[D],U=w[D+1],M=U.m,m=U.n,l=E.p.Wx(U).w;E.p.D(l,n,l);
var A=E.p.lV(l),g=E.Q(A.O()),k=A.x,$=A.y,C=A.m,f=A.n,z=n.clone();z.Ba();var s=z.bj(new ec(0,0)),O=z.bj(new ec(1,0)),a=O.x-s.x,X=O.y-s.y,P=M-.51,Z=m-.51;
for(var Y=0;Y<f;Y++){var K=z.dl*(k+.5)+z.Cj*(Y+$+.5)+z.z2,S=z.k*(k+.5)+z.j7*(Y+$+.5)+z.EU;for(var G=0;
G<C;G++){if(K<.5||K>P||S<.5||S>Z){}else g[Y*C+G]=Math.floor(.5+E.K.aw5(K,S,I,M,m));K+=a;S+=X}}return{rect:A,channel:g}};
y.wR.lD=function(w,n,W,D,j,I){if(W==null)W=!1;return y.wR.z3(w,W?0:1,E.K.yT(n),null,D,j,I,W)};y.wR.z3=function(w,n,W,D,j,I,U,M){if(M==null)M=!1;
if(M&&U)throw"e";var m={},k=0,$=.3;if(D&&!E.XB.pi(D)){var l=E.XB.BI(D);E.K.D(W,l);m.rect=E.p.lV(l);m.buffer=E.Q(m.rect.O()*4);
E.xv.drawImage(l,w[0],w[1].m,w[1].n,m.buffer,m.rect,n==0);return m}E.L3(w);var A=w[0],g=w[1],C=g.O()*E.K.OT(W).NW();
if(M&&C>4e6)$=C>8e6?2.2:1.2;while(k+3<w.length&&w[k+3].O()>16&&E.K.RC(W)&&E.K.OT(W).NW()<$){k+=2;var f=w[k],z=w[k+1],s=g.m/z.m,O=g.n/z.n;
W=E.K.y9(W,[1,0,g.x,0,1,g.y,0,0]);W=E.K.y9(W,[s,0,0,0,O,0,0,0]);W=E.K.y9(W,[1,0,-g.x,0,1,-g.y,0,0]);
g=z;A=f}var a=E.K.y9(W,E.K.yT(new eh(g.m,0,0,g.n,g.x,g.y))),X=[0,0,1,0,1,1,0,1];E.K.D(a,X);m.rect=E.p.lV(X);
if(U)m.rect=m.rect.wU(U);if(M){while((m.rect.m&3)!=0)m.rect.m++;while((m.rect.n&3)!=0)m.rect.n++}if(!gX.tj(X)||m.rect.m>1e5||m.rect.n>1e5||m.rect.O()>3e4*3e4)return null;
var P=m.rect.O()*4;if(j&&j.byteLength>=P&&P>=j.byteLength>>2){m.buffer=new Uint8Array(j)}else{m.buffer=E.Q(P)}E.K.drawImage(a,A,g.m,g.n,m.buffer,m.rect,n==0,I,M);
if(n==2&&m.buffer){var Z=m.rect.m,Y=m.rect.n,K;K=[0,-1,0,-1,16,-1,0,-1,0];K=E.Z3.kd(K);var S=m.buffer.slice(0);
E.Z3.yz(S,m.buffer,Z,Y,K,255,!1,!0)}if(m.buffer)return m};y.wR.S6=function(w,n,W,D,j,I,U){var M=n.rect,m=n.channel;
if(U){M=U;m=n.Ln(M)}if(n.color==255)E.Ba(m);var l=E.Q(M.O()*4);E.IL(m,l,3);var A=y.wR.z3([l,M],D,j,I);
if(A){W.rect=A.rect;W.channel=E.Q(A.rect.O());E.hN(A.buffer,W.channel,3);W.eP=!0}if(n.color==255){E.Ba(m);
if(A)E.Ba(W.channel)}};y.wR.a6n=function(w,n){var W=w.filterFX;if(W)W=W.v.filterFXList;if(W)W=W.v;if(W)for(var D=0;
D<W.length;D++){var j=W[D].v.Fltr;if(j==null||j.v.classID!="rigidTransform")continue;j=j.v;console.log(j);
var I=[];for(var U=0;U<4;U++)I.push(j["PuX"+U].v,j["PuY"+U].v);E.p.D(I,n,I);for(var U=0;U<4;U++){j["PuX"+U].v=I[U*2];
j["PuY"+U].v=I[U*2+1]}var M=["PinP","posFinalPins"],m=["originalVertexArray","deformedVertexArray"],l=j.puppetShapeList.v;
for(var A=0;A<l.length;A++){var g=l[A].v;for(var k=0;k<M.length;k++){var $=y.wR.Aa(g[M[k]]);E.p.D($,n,$);
g[M[k]]=y.wR.Hh($);var C=new Uint8Array(g[m[k]].v),f=new Float32Array(C.buffer);E.p.D(f,n,f);var z=[];
for(var s=0;s<C.length;s++)z[s]=C[s];g[m[k]].v=z}}}};y.wR.Aa=function(w){var n=[],W=w.v.length;for(var L=0;
L<W;L++)n.push(w.v[L].v);return n};y.wR.Hh=function(w){var n={t:"VlLs",v:[]},W=w.length;for(var L=0;
L<W;L++)n.v.push({t:"doub",v:w[L]});return n};y.wR.prototype.anh=function(){var w=E.p.mY(E.XB.BI(this.X8.l4())),n=E.K.kN(this.yU.W2(),this.G8),W=[w.x,w.y,w.x+w.m,w.y,w.x+w.m,w.y+w.n,w.x,w.y+w.n];
E.K.D(n,W);this.yU.vY(W);this.G8=w};y.wR.prototype.uE=function(w,n,W,D){var j=E.K.kN(this.yU.W2(),this.G8);
j=E.K.y9(j,E.K.Ba(this.pt));var I=this.X8?this.X8.l4():null;if(this.rf==0){var U=this.WX=E.K.OT(j);if(this.id==y.uW){var M=this.wN[0][0],m=M.Kd,l=m[1],A=~~(l.m*Math.max(0,U.dl)),g=~~(l.n*Math.max(0,U.j7)),k=new iB(Math.round(U.dl*l.x+U.z2),Math.round(U.j7*l.y+U.EU),A,g),$=E.kY.D(this.ms,k),C=w.C[this.C[0]];
C.buffer=$;C.rect=k;C.l();w.l()}else y.wR.At(w,n,this.C,this.wN,W,j,I,null,null,D)}else if(this.rf==1){var f=w.C[this.C[0]],l=this.qm.WH;
if(f.eL<=0){var z=this.qm.Ey,s=this.Py,O=null;if(I&&!E.XB.pi(I)&&!s.rect.s9(l)){var $=E.Q(s.rect.O()*4);
E.Cb(z,l,$,s.rect);z=$;l=s.rect}if(this.id==y.uW){var U=this.WX=E.K.OT(j),A=~~(l.m*Math.max(0,U.dl)),g=~~(l.n*Math.max(0,U.j7)),k=new iB(Math.round(U.dl*l.x+U.z2),Math.round(U.j7*l.y+U.EU),A,g),$=E.kY.D(this.ms,k);
O={buffer:$,rect:k}}else O=y.wR.z3([z,l],W,j,I);if(O){f.zZ.WL=O.buffer;f.zZ.M0=O.rect;var a=E.Q(O.rect.O());
E.hN(f.zZ.WL,a,3);w.J={channel:a,rect:f.zZ.M0.clone()}}}else{var X=E.Q(l.O()*4);E.IL(this.qm.Ey,X,3);
var O=y.wR.z3([X,l],W,j,I);if(O){f.zZ.WL=E.Q(O.rect.O());E.hN(O.buffer,f.zZ.WL,3);f.zZ.M0=O.rect}this.aoU(w,W,j,I)}f.p9(w,0,0,w.J);
if(W!=0){f.ky();E.ky(w.J)}w.Iq=!0;w.l()}else if(this.rf==2)this.aoU(w,W,j,I)};y.wR.prototype.aoU=function(w,n,W,D){var j=this.Py.rect,I=E.Q(j.O()*4);
E.IL(this.Py.channel,I,3);var U=y.wR.z3([I,j],n,W,D),M=E.Q(U.rect.O());E.hN(U.buffer,M,3);w.J={channel:M,rect:U.rect};
w.Iq=!0};y.wR.prototype.disable=function(w,n,W,D){if(this.yU)this.Jh(w,n,null,!0)};y.afe=function(){y.wR.call(this,[10,16],y.Sv,"tools/transform")};
y.afe.prototype=new y.wR;y.ad5=function(){y.wR.call(this,[7,10],y.Zt,"tools/transform")};y.ad5.prototype=new y.wR;
y.amx=function(){y.wR.call(this,[10,48],y.uW,"tools/transform")};y.amx.prototype=new y.wR;y.Qi=function(w,n,W){y.qw.call(this,[10,46],y.gR,"tools/transform");
this.pY=[1,1,2,!0];this.su="rigidTransform";this.u$=null;this.a3T=null;this.ss=null;this.n_=null;this.yu=null;
this.lo=null;this.GK=[]};y.Qi.prototype=new y.qw;y.Qi.prototype.wb=function(){return!0};y.Qi.aaS=function(w){if(w==null)return!1;
if(w.g.length!=1)return!1;var n=w.C[w.g[0]];return n.add.SoLd||w.d2(!1)};y.Qi.prototype.Tr=function(w,n){return y.Qi.aaS(w)};
y.Qi.prototype.enable=function(w,n,W,D,j,I,U){this.a3T=I.PX;var M=I.PX,m,f=null;if(M){var l=w.C[M.j];
if(l.add.SoLd.filterFX!=null){var A=l.add.SoLd.filterFX.v.filterFXList.v;if(A[M.index])m=JSON.parse(JSON.stringify(A[M.index].v.Fltr.v))}}var g=m==null,l=w.C[w.g[0]],k=l.buffer,$=l.rect,C=l.add.SoLd;
if(C){var z=C.nonAffineTransform.v;f=[];for(var L=0;L<4;L++)f.push(z[L*2].v,z[L*2+1].v);if(g)this.Dh("edit",n);
var s=l.NP(w);k=s.buffer;$=s.rect}this.u$={buffer:k.slice(0),rect:$.clone(),aws:f};if(g)m=y.Qi.Pg(this.u$,this.pY);
this.ss=m;this.n_=y.Qi.UW(this.ss,this.pY);this.uC();this.nA(w);if(g)this.Uc(n);var O=new ed(b.E.L,!0);
O.data={d:b.c.Bg,G:this.id,AH:this.pY};n.S(O);O.data={d:b.c.ph,In:"default"};n.S(O)};y.Qi.prototype.disable=function(w,n,W,D){if(this.n_)this.Jh(w,n,!0)};
y.Qi.prototype.uC=function(w){var n=this.n_;this.GK=[];for(var L=0;L<n.length;L++){var W=n[L];for(var D=0;
D<W.g.length;D++)this.GK.push([L,W.g[L]]);W.Pc=E.mE.pj(W);if(w)E.mE.Am(W)}};y.Qi.prototype.sm=function(w,n,W,D){if(w._b=="commit")this.Jh(W,n,!0);
else if(w._b=="cancel")this.oz(W,n,!0);else if(w._b=="prm"){var j=!1;for(var L=0;L<3;L++)if(this.pY[L]!=w.AH[L])j=!0;
this.pY=w.AH;if(j){this.ss=y.Qi.Pg(this.u$,this.pY,this.ss);this.n_=y.Qi.UW(this.ss,this.pY);this.uC(!0);
this.Uc(n)}this.nA(W)}else if(w._b=="moveDepth"){var I=this.n_;for(var U=0;U<I.length;U++){var M=I[U];
for(var L=0;L<M.g.length;L++){var m=M.g[L];M.G9[m]+=w.a6G?1:-1}}this.Uc(n)}};y.Qi.prototype.wO=function(w,n){return w==aK.m2||w==aK.on};
y.Qi.prototype.oe=function(w,n,W,D){var j=D.aa();if(D.U(aK.yG))this.Jh(w,n,!0);else if(D.U(aK.QX))this.oz(w,n,!0);
else if(D.U(aK.m2)||D.U(aK.on)){var I=this.n_;for(var U=0;U<I.length;U++){var M=I[U];M.g.sort(function(A,g){return g-A});
for(var L=0;L<M.g.length;L++){var m=M.g[L],l=m*2;M.G9.splice(m,1);M.uK.splice(m,1);M.eB.splice(m,1);
M.be.splice(m,1);M.dP.splice(l,2);M.Y2.splice(l,2)}M.g=[];if(M.be.length==0){M.IO=M.ZD.slice(0);M.ty=M.ZD.slice(0)}}this.uC(!0);
this.Uc(n);this.nA(w)}else if(j.x!=0||j.y!=0){this.ayQ(w,j.x,j.y,n);this.nn=null}};y.Qi.prototype.Jh=function(w,n,W){this.Dh("confirm",n);
this.escape(w,n,W)};y.Qi.prototype.oz=function(w,n,W){this.Dh("cancel",n);this.escape(w,n,W)};y.Qi.prototype.escape=function(w,n,W){w.I.VZ=null;
w.I.r4=[];w.RP=!0;this.n_=null;var D=new ed(b.E.L,!0);D.data={d:b.c.Oy};if(W)n.S(D)};y.Qi.prototype.WQ=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=I.x,M=I.y,m=this.n_,l=null,A=[0,2,4,1.2,1.2,1.2],g=-1,k=y.N5(w,j);
for(var L=0;L<m.length;L++){var $=m[L],C=E.p.VK($.Y2,U,M,k);if(C!=-1)l=[L,C];if(g==-1&&E.mE.CG.aAu($.ty,$.G2,U,M))g=L}if(l==null&&g!=-1){var $=m[g];
y.Qi.adV($,U,M,U,M,0);l=[g,$.be.length-1];$.Pc=E.mE.pj($)}this.yu=I;if(l){var f=m[l[0]].g.indexOf(l[1])!=-1;
if(D.U(aK.WO)&&!f){m[l[0]].g.push(l[1]);this.GK.push(l)}else if(!f){m[l[0]].g=[l[1]];this.GK=[l]}}this.nA(w)};
y.Qi.adV=function(w,n,W,D,j,I){var U=E.p.VK(w.ty,n,W);w.be.push(U);w.Y2.push(D,j);w.dP.push(w.ty[U*2]-n,w.ty[U*2+1]-W);
w.eB.push(0);w.uK.push(!1);w.G9.push(I)};y.Qi.prototype.QD=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=this.yu;
if(U)this.ayQ(w,I.x-U.x,I.y-U.y,n)};y.Qi.prototype.ayQ=function(w,n,W,D){var j={},I=this.GK,U=this.n_;
if(this.nn==null){this.nn=[];for(var L=0;L<U.length;L++)this.nn.push(U[L].Y2.slice(0))}for(var L=0;L<I.length;
L++){var M=this.GK[L],m=M[0],l=U[M[0]],A=M[1]*2;l.Y2[A+0]=this.nn[m][A+0]+n;l.Y2[A+1]=this.nn[m][A+1]+W;
j[m]=m}for(var m in j)E.mE.Am(this.n_[j[m]]);this.nA(w);this.Uc(D)};y.Qi.prototype.Dh=function(w,n){var W=new ed(b.E.v,!0);
W.G=y.sT;W.data={d:w,PX:this.a3T,su:this.su,jB:this.ss};n.S(W)};y.Qi.prototype.H5=function(w,n,W,D,j){this.yu=null;
this.nn=null};y.Qi.prototype.Uc=function(w){y.Qi.adG(this.n_,this.pY,this.ss);this.Dh("edit",w)};y.Qi.prototype.nA=function(w){var n=this.n_,W=this.ss;
w.I.VZ={w:[],F:[]};w.I.r4=[];w.I.hA=[];for(var L=0;L<n.length;L++){var D=n[L];for(var j=0;j<D.g.length;
j++)w.I.hA.push((w.I.r4.length>>>1)+D.g[j]);w.I.r4=w.I.r4.concat(D.Y2);if(this.pY[3])E.p.concat(w.I.VZ,E.p.asy(D.ty,D.G2))}w.RP=!0};
y.Qi.Pg=function(w,n,W){var D=w.buffer,j=w.rect,I=w.aws,U=cx._1("rigidTransform");if(I)for(var L=0;L<4;
L++){U["PuX"+L].v=I[L*2];U["PuY"+L].v=I[L*2+1]}var M=U.puppetShapeList.v,m=E.mE.ahU(D,j.m,j.n,n[1],n[2]),l=[];
for(var A=0;A<m.length;A++){var g={classID:"puppetShape",rigidType:{t:"bool",v:!0},VrsM:{t:"long",v:1},VrsN:{t:"long",v:0},originalVertexArray:{t:"tdta",v:[]},deformedVertexArray:{t:"tdta",v:[]},indexArray:{t:"tdta",v:[]},pinOffsets:{t:"VlLs",v:[]},posFinalPins:{t:"VlLs",v:[]},pinVertexIndices:{t:"VlLs",v:[]},PinP:{t:"VlLs",v:[]},PnRt:{t:"VlLs",v:[]},PnOv:{t:"VlLs",v:[]},PnDp:{t:"VlLs",v:[]},meshQuality:{t:"long",v:2},meshExpansion:{t:"long",v:2},meshRigidity:{t:"long",v:2},imageResolution:{t:"doub",v:72},selectedPin:{t:"VlLs",v:[]}};
g.meshBoundaryPath={t:"Objc",v:{classID:"pathClass",pathComponents:{t:"VlLs",v:[{t:"Objc",v:{classID:"PaCm",shapeOperation:{t:"enum",v:{shapeOperation:"xor"}},SbpL:{t:"VlLs",v:[{t:"Objc",v:{classID:"Sbpl",Clsp:{t:"bool",v:!0},Pts:{t:"VlLs",v:[]}}}]}}}]}}};
var k=m[A];M.push({t:"Objc",v:g});var $=k.ZD.slice(0);E.p.D($,new eh(1,0,0,1,j.x,j.y),$);var C=k.G2;
for(var L=0;L<C.length;L+=3){var f=C[L+1];C[L+1]=C[L+2];C[L+2]=f}l.push({G2:C,ZD:$,IO:$,ty:$,be:[],dP:[],Y2:[],Pc:null,g:[],eB:[],uK:[],G9:[]})}if(W){var z=y.Qi.UW(W,[]),s=l[0];
for(var L=0;L<z.length;L++){var O=z[L];for(var a=0;a<O.g.length;a++)s.g.push((s.Y2.length>>>1)+O.g[a]);
for(var a=0;a<O.be.length;a++){var X=O.be[a]*2,P=O.ZD[X]-O.dP[a*2],Z=O.ZD[X+1]-O.dP[a*2+1];y.Qi.adV(s,P,Z,O.Y2[a*2],O.Y2[a*2+1],O.G9[a])}}}y.Qi.adG(l,n,U);
return U};y.Qi.UW=function(w,n){var W=y.wR.Aa,D=w.puppetShapeList.v,j=[];for(var I=0;I<D.length;I++){var U=D[I].v;
n[0]=U.meshRigidity.v-1;n[1]=U.meshQuality.v-1;n[2]=U.meshExpansion.v;var M=U.pinVertexIndices.v.length,m=U.meshBoundaryPath.v.pathComponents.v;
if(m.length!=0){var l=m[0].v.SbpL.v[0].v.Pts;l.v=[]}var A=new Uint32Array(new Uint8Array(U.indexArray.v).buffer),g=new Float32Array(new Uint8Array(U.originalVertexArray.v).buffer),k=new Float32Array(new Uint8Array(U.deformedVertexArray.v).buffer),$=[],C=[],f=[];
for(var L=0;L<A.length;L++)$.push(A[L]);for(var L=0;L<g.length;L++){C.push(g[L]);f.push(k[L])}var z=W(U.pinVertexIndices),s=W(U.pinOffsets),O=W(U.posFinalPins),a=W(U.PnRt),X=W(U.PnOv),P=W(U.PnDp),Z=W(U.selectedPin);
j.push({G2:$,ZD:C,IO:f.slice(0),ty:f,be:z,dP:s,Y2:O,Pc:null,eB:a,uK:X,G9:P,g:Z})}return j};y.Qi.adG=function(w,n,W){function D(k,$){var C=[];
for(var L=0;L<k.length;L++)C.push({t:$,v:k[L]});return C}function j(k,$,C){var f=new(C?Uint32Array:Float32Array)(k),z=new Uint8Array(f.buffer);
for(var L=0;L<z.length;L++)$[L]=z[L]}var I=W.puppetShapeList.v;for(var U=0;U<I.length;U++){var M=w[U],m=I[U].v;
m.meshRigidity.v=n[0]+1;m.meshQuality.v=n[1]+1;m.meshExpansion.v=n[2];j(M.G2,m.indexArray.v,!0);j(M.ZD,m.originalVertexArray.v);
j(M.ty,m.deformedVertexArray.v);var l=[];for(var L=0;L<M.be.length;L++){var A=M.be[L]*2,g=L*2;l[g]=M.ZD[A]-M.dP[g];
l[g+1]=M.ZD[A+1]-M.dP[g+1]}m.PinP.v=D(l,"doub");m.pinVertexIndices.v=D(M.be,"long");m.pinOffsets.v=D(M.dP,"doub");
m.posFinalPins.v=D(M.Y2,"doub");m.PnRt.v=D(M.eB,"long");m.PnOv.v=D(M.uK,"bool");m.PnDp.v=D(M.G9,"doub");
m.selectedPin.v=D(M.g,"long")}};y.mk=function(w,n,W){y.qw.call(this,w?w:[10,40],n?n:y.Od,W?W:"tools/slice");
this.tI=null;this.xh=null;this.AW=null;this.aln=null;this.OK=null;this.fU=null};y.mk.prototype=new y.qw;
y.mk.pw=function(w,n){var W=-1;for(var L=0;L<w.length;L++){var D=y.mk.uw(w,L);if(D[0]<=n.x&&n.x<=D[2]&&D[1]<=n.y&&n.y<=D[3]){W=L;
break}}return W};y.mk.prototype.Al=function(w,n,W,D,j){if(W==null)return;this.Vw(W);if(w.d=="fromAction"){var I=w.bs,U=I.hZ,M=I.E3,m=W.Iw(),l=W.H2(),A=l==-1?new iB(0,0,W.m,W.n):W.C[l].yP();
if(U=="divide"){if(W.UF.length!=0){var g=W.UF[0],k=y.mk.uw(W.ej,g);A=new iB(k[0],k[1],k[2]-k[0],k[3]-k[1]);
W.ej.splice(g,1);W.UF=[]}m=[[],[]];for(var $=0;$<2;$++){var C=["Across","Down"][$],f=M["pixels"+C]?0:1,z=M[["pixels","slices"][f]+C];
if(z==null)continue;z=z.v;var s=$==0?A.x:A.y,O=$==0?A.m:A.n;if(f==0)for(var L=1;L*z<O;L++){m[0].push([$,s+L*z]);
m[1].push(l)}else{var a=Math.floor(O/z);for(var L=1;L<z;L++){m[0].push([$,s+L*a]);m[1].push(l)}}}}var X=[A.x,A.x+A.m],P=[A.y,A.y+A.n];
for(var L=0;L<m[0].length;L++){var Z=m[0][L],Y=Math.round(Z[1]),K=m[1][L];if(K!=-1&&K!=l)continue;if(Z[0]==0&&X.indexOf(Y)==-1)X.push(Y);
if(Z[0]==1&&P.indexOf(Y)==-1)P.push(Y)}X.sort(function(H,F){return H-F});P.sort(function(H,F){return H-F});
for(var S=1;S<P.length;S++)for(var G=1;G<X.length;G++){W.ej.push(y.mk.Ih());y.mk.CA(W.ej,W.ej.length-1,[X[G-1],P[S-1],X[G],P[S]]);
W.RP=!0}}else if(w.d=="reorder"){if(W.UF.length==0)return;var V=W.ej,T=W.UF;T.sort(function(H,F){return H-F});
console.log(T);var R=V.slice(0),x=[],v=[];for(var L=0;L<T.length;L++){var g=T[L],N=V[g];v.push(N);R.splice(R.indexOf(N),1)}var u=Math.max(0,Math.min(R.length,T[0]-w.dir));
for(var L=0;L<v.length;L++){R.splice(u+L,0,v[L]);x.push(u+L)}W.ej=R;W.UF=x}else if(w.d=="delete"){var V=W.ej.slice(0);
for(var L=0;L<W.UF.length;L++)W.ej.splice(W.ej.indexOf(V[W.UF[L]]),1);W.UF=[]}else if(w.d=="deleteAll"){W.ej=[];
W.UF=[]}else{W.ej[W.UF[0]].v=w;W.RP=!0}this.eO(W)};y.mk.prototype.enable=function(w,n,W,D,j,I){y.qw.prototype.enable.call(this,w,n,W,D,j,I);
if(!W.M3.ej){var U=new ed(b.E.L,!0);U.data={d:b.c.oj,AH:bk.WA};n.S(U)}};y.mk.prototype.disable=function(){this.tI=null;
this.xh=null};y.mk.prototype.cF=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=y.mk.pw(w.ej,I);if(U==-1)return;
this.tI=w;this.xh=n;w.UF=[U];w.RP=!0;if(this.fU==null){this.fU=new cA([{name:[5,4]},{name:[8,11,1],$r:!0}]);
this.fU.h("select",this.zs,this)}var M=this.fU;M.parent=n;M.f();M.update(w,W);var m=new ed(b.E.L,!0);
m.data={d:b.c.Uq,BT:M,x:j.Qc+2,y:j.tc+1};n.S(m)};y.mk.prototype.zs=function(w){var n=this.fU.aJ()[0],W=this.tI;
if(n==0){this.Vw(W);W.ej.splice(W.UF[0],1);W.UF=[];W.RP=!0;this.eO(W)}if(n==1){var D=new ed(b.E.L,!0);
D.data={d:b.c.P2,jW:"soptions",Z:W.ej[W.UF[0]].v};this.xh.S(D)}};y.mk.prototype.WQ=function(w,n,W,D,j){if(w==null)return;
this.Vw(w);var I=w.u.Cg(j.x,j.y);I=y.mU.JW(w,I,W,[!0,null,!1]);I.x=Math.round(I.x);I.y=Math.round(I.y);
this.OK=I;w.ej.unshift(y.mk.Ih());w.UF=[0];y.mk.CA(w.ej,0,[I.x,I.y,I.x+20,I.y+20]);w.RP=!0};y.mk.prototype.QD=function(w,n,W,D,j){if(this.AW==null)return;
var I=w.u.Cg(j.x,j.y),U=this.OK;I=y.mU.JW(w,I,W,[!0,null,!1]);I.x=Math.round(I.x);I.y=Math.round(I.y);
var M=[U.x,U.y,I.x,I.y];y.mk.a6m(M);y.mk.CA(w.ej,0,M);w.RP=!0};y.mk.prototype.H5=function(w,n,W,D,j){this.eO(w);
this.OK=null};y.mk.prototype.Vw=function(w){this.AW=JSON.stringify(w.ej);this.aln=JSON.stringify(w.UF)};
y.mk.prototype.eO=function(w){var n=JSON.stringify(w.ej);if(n!=this.AW){var W=new go(this.name,this);
W.data={qm:this.AW,Hb:n,aAC:this.aln,any:JSON.stringify(w.UF)};w.kK(W)}this.AW=null};y.mk.prototype.ZE=function(w,n){n.ej=JSON.parse(w.qm);
n.UF=JSON.parse(w.aAC);n.RP=!0};y.mk.prototype.Fd=function(w,n){n.ej=JSON.parse(w.Hb);n.UF=JSON.parse(w.any);
n.RP=!0};y.mk.prototype.wO=function(w,n){return n!=null&&n.UF.length!=0&&(w==aK.m2||w==aK.on)};y.mk.prototype.oe=function(w,n,W,D){if(w==null)return;
if(D.U(aK.m2)||D.U(aK.on))this.Al({d:"delete"},n,w,D,W);var j=D.aa();if(j.x!=0||j.y!=0){this.Vw(w);y.mk.fL(w,j);
this.eO(w)}};y.mk.prototype.sm=function(w,n,W,D,j){};y.mk.ak5=function(w,n,W,D){var j=new ec(-n.x,-n.y),I=n.m/W.m,U=n.n/W.n,M=[0,0,n.m,n.n];
for(var L=0;L<w.length;L++){var m=y.mk.uw(w,L);if(D){m[0]=Math.round(m[0]*I);m[1]=Math.round(m[1]*U);
m[2]=Math.round(m[2]*I);m[3]=Math.round(m[3]*U)}else{y.mk.t4(m,j);y.mk.am8(m,M)}if(m[0]>=m[2]||m[1]>=m[3]){w.splice(L,1);
L--;continue}y.mk.CA(w,L,m)}};y.mk.fL=function(w,n){var W=w.ej;for(var L=0;L<w.UF.length;L++){var D=y.mk.uw(W,w.UF[L]);
y.mk.t4(D,n);y.mk.CA(W,w.UF[L],D)}};y.mk.am8=function(w,n){if(w[0]<n[0])w[0]=n[0];if(w[1]<n[1])w[1]=n[1];
if(n[2]<w[2])w[2]=n[2];if(n[3]<w[3])w[3]=n[3]};y.mk.t4=function(w,n){w[0]=Math.round(w[0]+n.x);w[2]=Math.round(w[2]+n.x);
w[1]=Math.round(w[1]+n.y);w[3]=Math.round(w[3]+n.y)};y.mk.CA=function(w,L,n){var W=w[L].v.bounds.v;W.Left.v=n[0];
W.Top.v=n[1];W.Rght.v=n[2];W.Btom.v=n[3]};y.mk.uw=function(w,L){var n=w[L].v.bounds.v;return[n.Left.v,n.Top.v,n.Rght.v,n.Btom.v,L]};
y.mk.a6m=function(w){if(w[2]<w[0]){var n=w[0];w[0]=w[2];w[2]=n}if(w[2]==w[0])w[2]++;if(w[3]<w[1]){var n=w[1];
w[1]=w[3];w[3]=n}if(w[3]==w[1])w[3]++};y.mk.mY=function(w,n){var W=1e9,D=-1e9,j=1e9,I=-1e9;for(var L=0;
L<n.length;L++){var U=y.mk.uw(w,n[L]);W=Math.min(W,U[0]);j=Math.min(j,U[1]);D=Math.max(D,U[2]);I=Math.max(I,U[3])}return[W,j,D,I]};
y.mk.Ih=function(){return{t:"Objc",v:{classID:"slice",sliceID:{t:"long",v:0},groupID:{t:"long",v:0},origin:{t:"enum",v:{ESliceOrigin:"userGenerated"}},Type:{t:"enum",v:{ESliceType:"Img"}},bounds:{t:"Objc",v:{classID:"Rct1",Top:{t:"long",v:0},Left:{t:"long",v:0},Btom:{t:"long",v:0},Rght:{t:"long",v:0}}},url:{t:"TEXT",v:""},null:{t:"TEXT",v:""},Msge:{t:"TEXT",v:""},altTag:{t:"TEXT",v:""},cellTextIsHTML:{t:"bool",v:!0},cellText:{t:"TEXT",v:""},horzAlign:{t:"enum",v:{ESliceHorzAlign:"default"}},vertAlign:{t:"enum",v:{ESliceVertAlign:"default"}},bgColorType:{t:"enum",v:{ESliceBGColorType:"None"}},topOutset:{t:"long",v:0},leftOutset:{t:"long",v:0},bottomOutset:{t:"long",v:0},rightOutset:{t:"long",v:0}}}};
y.cD=function(){y.mk.call(this,[10,41],y.Xg,"tools/sselect");this.OK=null;this.Hz=null;this.jj=null;
this.lo=null;this.wd=!1};y.cD.prototype=new y.mk;y.cD.prototype.WQ=function(w,n,W,D,j){if(w==null)return;
var I=w.u.Cg(j.x,j.y),U=y.cD.an$(I,4/w.u.N,w.ej,w.UF);U.pop();if(U.length!=0){this.OK=I;this.jj=U;this.Vw(w);
return}var M=w.ej,m=y.mk.pw(M,I);if(m==-1)w.UF=[];else{var l=w.UF.indexOf(m);if(D.U(aK.WO)){if(l==-1)w.UF.push(m);
else w.UF.splice(l,1)}else{w.UF.sort(function(f,z){return f-z});if(l==-1)w.UF=[m];this.OK=I;this.Vw(w);
this.Hz=y.mk.mY(M,w.UF);this.lo=[];for(var L=0;L<w.UF.length;L++)this.lo.push(y.mk.uw(M,w.UF[L]));if(D.U(aK.PJ)){var A=M.slice(0),g=w.UF,k=[];
for(var L=0;L<g.length;L++){var m=g[L],$=A[m],C=M.indexOf($);k.push(C);M.splice(C,0,JSON.parse(JSON.stringify($)))}w.UF=k}}}w.RP=!0};
y.cD.prototype.QD=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);if(this.OK==null){var U=y.cD.an$(I,4/w.u.N,w.ej,w.UF),M=U.pop(),m=U.length==0?"default":["ew","nwse","ns","nesw"][M]+"-resize",l=new ed(b.E.L,!0);
l.data={d:b.c.ph,In:m};n.S(l);return}if(!this.wd&&I.s9(this.OK))return;this.wd=!0;var A=w.ej,U=this.jj;
if(U){I=y.mU.JW(w,I,W,[!0,null,!1]);var g=Math.round(I.x),k=Math.round(I.y);for(var L=0;L<U.length;L+=2){var $=y.mk.uw(A,U[L]),C=U[L+1];
$[C]=(C&1)==0?g:k;y.mk.a6m($);y.mk.CA(A,U[L],$)}}else{var f=I.eu(this.OK),s=this.Hz.slice(0);y.mk.t4(s,f);
var O=new iB(s[0],s[1],s[2]-s[0],s[3]-s[1]),a=y.mU.uP(w,O,W,[!0,null,!1],!0);y.mU.Iy(w,O,a);f.x+=a[0];
f.y+=a[1];for(var L=0;L<w.UF.length;L++)y.mk.CA(A,w.UF[L],this.lo[L]);y.mk.fL(w,f)}w.RP=!0};y.cD.prototype.H5=function(w,n,W,D,j){if(this.OK==null)return;
this.eO(w);w.I.t7=null;w.RP=!0;this.OK=null;this.jj=null;this.lo=null;this.wd=!1};y.cD.an$=function(w,n,W,D){var j=w.x,I=w.y,U=[],M=-1,m=[];
for(var L=0;L<D.length;L++){var l=D[L],A=y.mk.uw(W,l),g=A[0],k=A[1],$=A[2],C=A[3];if(j<g-n||$+n<j||I<k-n||C+n<I)continue;
var f=[j<g+n,I<k+n,$-n<j,C-n<I],z=-1;for(var s=0;s<4;s++){if(f[s]&&f[s+1&3])z=1+2*(s&1);if(f[s])U.push(l,s)}if(z==-1){if(f[0]||f[2])z=0;
if(f[1]||f[3])z=2}if(z!=-1){M=z;m.push(l)}}var O=U.length;for(var L=0;L<O;L+=2){var l=U[L],a=U[L+1],X=y.mk.uw(W,l)[a];
for(var s=0;s<D.length;s++){var P=D[s];if(m.indexOf(P)!=-1)continue;var A=y.mk.uw(W,P);if(A[a&1]==X)U.push(P,a&1);
if(A[2+(a&1)]==X)U.push(P,2+(a&1))}}U.push(M);return U};y.$W=function(){y.eZ.call(this,[10,44],y.a8k,"tools/oselect");
this.t1="crosshair";this.aye=0};y.$W.prototype=new y.eZ;y.$W.prototype.jx=function(w,n,W,D){if(Math.random()<1/(1+this.aye)){alert("The cross should be fully inside the object.",3500);
this.aye++}};y.$W.prototype.Gi=function(w,n,W,D){y.fc.ha(w,y.eZ.bV,this.xh);if(!D.WS||!this.xs)return;
var j=this.pJ(w,W,!1),I=j.m,U=j.n,M=j.x,m=j.y,l=j.x+I,A=j.y+U,g=M+I/2,k=m+U/2,$=y.$W.abQ;w.I.VZ={w:[M,m,l,m,l,A,M,A,g-I*$,k,g+I*$,k,g,k-U*$,g,k+U*$],F:"M L L L Z M L M L".split(" ")};
w.RP=!0};y.$W.abQ=.12;y.$W.prototype.WB=function(w,n,W,D){w.I.VZ=null;w.RP=!0;this.finish(w,n,W,D)};
y.$W.prototype.getSelection=function(w,n,W,D){if(this.gs.s9(this.Gs)||!this.xs)return null;var j=this.pJ(w,W,!1),I=w.C[w.g[0]];
if(j.VY()||!j.L0(I.rect))return null;return y.eZ.Pd("ObSl",j)};y.fc=function(){y.JT.call(this,[10,37],y.N4,"tools/qselect");
this.X1="qselect"};y.fc.prototype=new y.JT;y.fc.prototype.WQ=function(w,n,W,D,j){y.fc.ha(w,y.eZ.bV,n,!0);
this.jM(w,W,D,j,1);if(this.rN==null)return;this.kC(w)};y.fc.prototype.QD=function(w,n,W,D,j){this.ez(w,n,W);
y.fc.ha(w,y.eZ.bV,n);if(this.Qt)this.$X(w,W,j);if(this.rN==null)return;if(!j.WS)return;var I=this.WD(w,W,D,j);
if(I!=1)this.kC(w)};y.fc.ha=function(w,n,W,D){if(w&&n.key!=y.fc.ur(w)){n.key=y.fc.ur(w);var j=w.C[w.g[0]].rect.O(),U="Image Analysis ...";
if(j==0)return;var I=j>1e6&&D!=!0,M=new ed(b.E.L,!0);M.data={d:b.c.Ql,mz:U};if(I)W.S(M);var m=function(){var l=y.fc.aiJ(w);
for(var A in l)n[A]=l[A];var M=new ed(b.E.L,!0);M.data={d:b.c.SO,mz:U};if(I)W.S(M)};if(D)m();else setTimeout(m,30)}};
y.fc.ur=function(w){var n=w.g[0],W=w.C[n],D=W.rect,j=D.m,I=D.n,U=j*I,M=W.buffer;return[n,D.x,D.y,j,I,M[0],M[1],M[2],M[3]].join(",")};
y.fc.aiJ=function(w){var n=w.g[0],W=w.C[n],D=W.rect,j=D.m,I=D.n,U=j*I,M=W.buffer,m=Date.now(),l=E.Q(U);
l.fill(128);var A=E.gq.pV(M,j,I);console.log(Date.now()-m);var g={key:y.fc.ur(w),vJ:M,rect:D.clone(),gA:j,ag:I,$e:12,ap0:!1,mB:l,ya:A,J:E.Q(U),mR:null,Sk:null,Yp:null};
y.fc.so(g);return g};y.fc.so=function(w,n){var W=w.gA,D=w.ag,j=0,I=0,U=Date.now(),M=w.mR!=null&&E.gq.anN(w.ya.G2,w.mR.G2,w.mR.M$,w.mB);
j=Date.now()-U;U=Date.now();if(!M&&!w.ap0){w.mR=E.gq.YT(w.ya,W,D,w.mB,w.$e);if(!E.gq.anN(w.ya.G2,w.mR.G2,w.mR.M$,w.mB)){w.ap0=!0;
console.log("conflict")}w.Sk=E.gq.apP(w.vJ,W,D,w.mR.G2,w.mR.M$);w.Yp=[w.Sk[0].slice(0),[]];I=Date.now()-U;
U=Date.now()}var U=Date.now();if(n){w.Yp[0].set(w.Sk[0]);var m=w.Sk[1],l=w.Yp[1];for(var A=0;A<m.length;
A++)l[A]=m[A].slice(0);E.gq.aA8(w.mR.G2,W,D,w.mR.M$,w.mB,w.J,w.Yp)}};y.s2=function(){y.qw.call(this,[10,50],y.yl,"tools/artb");
this.hw=null;this.vA=!1;this.yU=null;this.p$=!1;this.aji=null;this.PH=100;this.iK=null;this.ft=0};y.s2.prototype=new y.qw;
y.s2.prototype.Al=function(w,n,W,D,j){this.ct(W,w.aap,n,w.IZ)};y.s2.akK=function(w,n){var W=w[0],D=0,j=0;
if(W==0)j=-1;else if(W==1)D=1;else if(W==2)j=1;else D=-1;return[20/n.fd,w[1]+D*60/n.fd,w[2]+j*60/n.fd]};
y.s2.prototype.sm=function(w,n,W,D,j){this.hw=w.AH;this.ft=Date.now()};y.s2.prototype.BW=function(w,n,W,D){if(W.No!=this.id)return;
if(w==null||w.g.length!=1){this.fm(w);return}var j=w.g[0],I=w.C[j],U=I.add.artb;if(U==null){this.fm(w);
return}if(this.p$)return;if(Date.now()-this.ft>50){this.hw={};var M=["artboardBackgroundType","Clr"];
for(var L=0;L<M.length;L++)if(U[M[L]])this.hw[M[L]]=JSON.parse(JSON.stringify(U[M[L]]));var m=new ed(b.E.L,!0);
m.data={d:b.c.Bg,G:this.id,LQ:this.hw};n.S(m)}var l=I.yP(),A=E.p.Wx(l).w,g=this.yU=new gX(A,!0,!1,!1,!0,!1,3,!1);
g.qz(w,W,!1);var k={w:[1,0],F:["M"]};for(var L=1;L<30;L++){var $=Math.PI*2*L/30;k.w.push(Math.cos($),Math.sin($));
k.F.push("L")}k.F.push("Z","M","L","M","L");k.w.push(-.5,0,.5,0,0,-.5,0,.5);var C=l.x+l.m/2,f=l.y+l.n/2,s=this.PH*1.1,O=this.aji=[C,l.y,l.x+l.m,f,C,l.y+l.n,l.x,f],a=[0,-s,s,0,0,s,-s,0],X=w.root.children;
w.I.JF=[];for(var L=0;L<4;L++){var P=new ec(O[L*2]+a[L*2],O[L*2+1]+a[L*2+1]),Z=!1;for(var Y=0;Y<X.length;
Y++){var I=X[Y].j;if(I.add.artb==null)continue;var l=I.yP();if(l.y5(P))Z=!0}if(Z){O[L*2]=1e9;continue}w.I.JF.push([L,O[L*2],O[L*2+1]])}};
y.s2.prototype.disable=function(w,n,W,D,j){this.fm(w)};y.s2.prototype.fm=function(w){if(this.yU){this.yU.clear(w);
this.yU=null;w.I.JF=null}};y.s2.prototype.WQ=function(w,n,W,D,j){this.ft=Date.now();var I=w.u.Cg(j.x,j.y),U=this.yU;
if(U){var M=new ed(b.E.v),m=U.aw3(null,I,w,j);if(m<9){this.p$=U.WQ(w,W,D,I,null,!0,j);return}else if(U.gO(I)){M.G=y.Rv;
M.data={d:"disabAuto"};n.S(M);var l=new ed(b.E.L);l.data={d:b.c.CV,G:y.Rv,asq:!0};n.S(l);return}else{var A=-1,g=w.I.JF;
for(var L=0;L<g.length;L++){var k=y.s2.akK(g[L],w.u);if(ec.cS(I,new ec(k[1],k[2]))<k[0])A=g[L][0]}if(A!=-1){var $=w.C[w.g[0]].yP(),C=$.clone(),f=(A==0||A==2?$.n:$.m)+this.PH;
if(A==0||A==3)f=-f;if(A==0||A==2)$.y+=f;else $.x+=f;if(D.U(aK.PJ)){var s=new iB(0,0,w.m,w.n);M.G=y.Yu;
M.data={d:h.R6};n.S(M);y.mU.Gt(w,w.qu(null,w.g[0],null,!0),null,$.x-C.x,$.y-C.y);w.g=w.g.slice(w.g.length-1);
var O=y.QJ.xJ(w);if(O){var a=w.by();a.data.G8=s;a.data.uU=O;a.data.zu=w.g}}else this.ct(w,$,n);return}}}this.iK=y.mU.JW(w,I,W)};
y.s2.prototype.ct=function(w,n,W,D){if(D==null)D=0;var j=w.C.slice(0),I=[w.C.length+1],U=w.QI();U.nz(fV.get([1,16,0])+" "+(w.add.artd==null?1:w.root.children.length+1));
U.add.lsct=ef.fz;U.MR(n);if(this.hw){var M=U.add.artb,m=this.hw;for(var l in m)M[l]=m[l]}U.Bx="pass";
U.FK=24;if(D==0){if(w.add.artd||n.wU(new iB(0,0,w.m,w.n)).VY())j.push(w.hG());else j.unshift(w.hG())}else{var A=w.qu();
A.sort(function(f,z){return f-z});var g=y.G$._c(w,A,j.length-1,!1,null,!1),k=g.pop(),$=g.pop();j=g.pop();
j.splice(w.C.length-A.length,0,w.hG())}j.push(U);var C=new ed(b.E.v);C.G=y.Yu;C.data={d:h.ZM,_B:j,TY:I,s7:[1,16,2]};
W.S(C)};y.s2.prototype.QD=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=this.yU,M=this.iK;if(U){if(this.p$){U.QD(w,W,D,I)}else{var m=U.G_(I,w.u.N,null,j);
if(m==null)m="default";var l=new ed(b.E.L,!0);l.data={d:b.c.ph,In:m};n.S(l)}}if(M){var A=this.uw(w,I,D,W);
w.I.VZ=E.p.Wx(A);w.RP=!0;y.qw.Co(j,A,w,W)}};y.s2.prototype.H5=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y),U=this.iK;
if(this.p$){this.yU.H5(w,W,D,I);this.p$=!1;var M=E.p.lV(this.yU.W2()),m=h.B3(M),l=w.C[w.g[0]],A=JSON.parse(JSON.stringify(l.add.artb));
A.artboardRect.v=m;var g=new ed(b.E.v,!0);g.G=y.Yu;g.data={d:h.nL,oL:A};n.S(g)}if(U){var k=this.uw(w,I,D,W);
if(k.O()>20)this.ct(w,k,n);w.I.VZ=null;w.RP=!0;this.iK=null;w.I.r7=[]}};y.s2.prototype.uw=function(w,n,W,D){var j=this.iK,I=y.mU.JW(w,n,D),U=y.IG.fS(j,I,W,!0);
j=U[0];I=U[1];return E.p.lV([j.x,j.y,I.x,I.y])};function gX(w,n,W,D,j,I,U,M){this.iW=null;this.H3=w?w.slice(0):null;
this.lK=4;this.Gs=null;this.ap=null;this.$s=null;this.yw=-1;this.gC=null;this.a05=!1;this.aj_=[];for(var L=0;
L<8;L++)this.aj_.push(jj.acE(0,PIMG.rotate,-.5,-.5,-45-L*45));this.a7d=n;this.a50=W;this.a5b=D;this.ak7=j;
this.eE=I;this.IZ=U;this.amN=M==null?1:M}gX.prototype.aou=function(){return this.yw!=-1};gX.prototype.W2=function(){return this.H3.slice(0)};
gX.prototype.vY=function(w){this.H3=w};gX.prototype.a5e=function(){return this.jZ(this.H3)};gX.prototype.aqO=function(){return this.lK};
gX.prototype.apg=function(w){this.lK=w};gX.prototype.I7=function(w){if(w==null)w=this.H3;if(this.lK==9)return this.Gs;
else return this.jZ(w)[this.lK]};gX.prototype.a6Q=function(w){if(this.lK==9)this.Gs=w.clone();else{var n=this.I7(),W=new eh(1,0,0,1,w.x-n.x,w.y-n.y);
E.p.D(this.H3,W,this.H3)}};gX.prototype.G_=function(w,n,W,D){var j=this.eT(null,w,n,D),I;if(j==9)return"default";
if(j==10){if(W)return null;return!this.a7d?"move":null}if(j==-1||j==4)return null;if(j==11){var U=this.I7().eu(w);
I=90-Math.atan2(U.y,U.x)*180/Math.PI;var M=Math.round(8*(I/360));M=(M+8)%8;return this.aj_[M]}else{var m=this.E9(w,this.H3);
I=[135,90,45,180,0,0,225,270,315][j];var l=E.K.kN(this.H3);I+=Math.atan2(-l[3],l[0])*180/Math.PI;var A="ew nesw ns nwse ew nesw ns nwse".split(" "),M=Math.round(8*(I/360));
M=(M+8)%8;return A[M]+"-resize"}};gX.prototype.E9=function(w,n){var W=E.K.Ba(E.K.kN(n)),D=new Float64Array(2);
E.K.EQ(w.x,w.y,W,D);return new ec(D[0],D[1])};gX.prototype.gO=function(w){var n=this.E9(w,this.H3);return 0<=n.x&&n.x<=1&&0<=n.y&&n.y<=1};
gX.prototype.WQ=function(w,n,W,D,j,I,U,M){this.a05=I;this.gC=D;var m=w.u.N,l;if(this.H3==null)D=y.mU.JW(w,D,n);
this.$s=D.clone();if(this.H3==null){if(M==null)M=0;var A=new eh;A.rotate(M);var g=A.bj(new ec(1,1));
this.$s.offset(g.x,g.y);var k=j==null?1:1/j,$=this.H3=[0,0,1,0,1,k,0,k];A.translate(D.x,D.y);E.p.D(this.H3,A,this.H3);
l=8}else{l=this.eT(W,D,m,U);if(0<=l&&l<=8)this.$s=this.jZ(this.H3)[l];if(l==9){this.lK=9;this.Gs=D.clone()}}this.iW=this.H3.slice(0);
this.yw=l;this.qz(w,n);this.ap=this.I7();return l!=-1};gX.prototype.aw3=function(w,n,W,D){return this.eT(w,n,W.u.N,D)};
gX.prototype.eT=function(w,n,W,D){var j=-1,I=this.jZ(),U=[0,2,6,8,1,3,5,7],M=D?y.N5({u:{N:W}},D):8*y.V()/W,m=ec.cS(I[0],I[2]),l=ec.cS(I[0],I[6]),A=this.E9(n,this.H3);
A.x*=m;A.y*=l;var g=new iB(0,0,m,l);g.VD(M,M);if(j==-1)if(ec.cS(this.I7(),n)<M)j=9;if(j==-1)for(var L=0;
L<U.length;L++)if(ec.cS(I[U[L]],n)<M)j=U[L];if(j==-1&&g.y5(A)){if(Math.abs(A.y-0)<M)j=1;if(Math.abs(A.x-0)<M)j=3;
if(Math.abs(A.y-l)<M)j=7;if(Math.abs(A.x-m)<M)j=5}if(j==-1&&w&&w.U(aK.PJ))j=9;if(j==-1||this.IZ==4){if(this.gO(n)){if(this.a7d)j=10}else{g.VD(3*M,3*M);
j=g.y5(A)&&this.IZ!=3?11:10}}return j};gX.prototype.QD=function(w,n,W,D,j){if(this.yw==-1)return;this.gC=D;
var I=W.U(aK.WO),U=W.U(aK.PJ),M=W.U(aK.CQ),m=w.u.N,l=this.$s,A=this.yw,g=this.jZ(),k=y.mU.JW(w,l,n),$=y.mU.JW(w,D,n),C,f;
if(A==9){var g=this.jZ(),z=-1;for(var L=0;L<g.length;L++)if(ec.cS(g[L],$)*m<10)z=L;this.lK=z==-1?9:z;
this.Gs=I?y.mr.RM(k,$):$.clone()}else if(A==10){f=E.p.mY(this.iW);var s=f.x,O=f.y;f.offset(D.x-l.x,D.y-l.y);
if(this.a90()){f.x=Math.round(f.x);f.y=Math.round(f.y)}C=y.mU.uP(w,f,n);var a=new eh(1,0,0,1,f.x-s+C[0],f.y-O+C[1]);
E.p.D(this.iW,a,this.H3)}else if(A==11){var X=this.I7(this.iW),P=X.eu(D),Z=X.eu(l),Y=Math.atan2(P.y,P.x),K=Math.atan2(Z.y,Z.x),a=new eh(1,0,0,1,-X.x,-X.y),S=Math.PI/12;
if(I)a.rotate(Math.round((K-Y)/S)*S);else a.rotate(K-Y);a.translate(X.x,X.y);E.p.D(this.iW,a,this.H3)}else{if(j&&!M)I=!I;
var G,V=this.iW,T=A==0||A==2||A==6||A==8;if(this.IZ==1){if(T)I=U=M=!0}else if(this.IZ==2&&T&&this.a05!=!0)M=!0;
if(this.IZ==3)M=!1;if(this.a5b&&T&&M){var L=[0,0,2,0,0,0,6,0,4,0][A],R=-1,x=$.x,v=$.y;if(I){var N=L+6&7,u=L+10&7,H=gX.a3P(V[L],V[L+1],V[N],V[N+1],$.x,$.y),F=gX.a3P(V[L],V[L+1],V[u],V[u+1],$.x,$.y),t=H[2]<F[2]?H:F;
x=t[0];v=t[1];if(U)R=H[2]<F[2]?N:u}else if(U)R=L+4&7;G=V.slice(0);if(R!=-1){var o=V[R],q=V[R+1],_=(V[L]+o)/2,d=(V[L+1]+q)/2;
G[R]=_-(x-_);G[R+1]=d-(v-d)}G[L]=x;G[L+1]=v}else if(T&&U){var X=this.ap,r=X.x,p=X.y,Q=k.x-r,B=k.y-p,i=1,c=1;
if(Math.abs(Q)>=1)i=($.x-r)/Q;if(Math.abs(B)>=1)c=($.y-p)/B;if(I||this.eE)i=c=(i+c)/2;var a=new eh;a.translate(-r,-p);
a.scale(i,c);a.translate(r,p);G=V.slice(0);E.p.D(G,a,G)}else{if(this.a90()){$.x=Math.round($.x);$.y=Math.round($.y)}var h2=[0,1,2,5,8,7,6,3],jX=h2[(h2.indexOf(A)+4)%8],bm=[];
for(var L=0;L<3;L++)for(var R=0;R<3;R++)bm.push(new ec(R/2,L/2));var X=this.ap,dC=this.E9($,V),fn=this.E9(l,V),fK=U&&(this.lK==4||this.lK==9)?this.E9(X,V):bm[jX],i6=new eh,dh=new eh,i=(dC.x-fK.x)/(fn.x-fK.x);
if(i==0)i=1e-4;var c=(dC.y-fK.y)/(fn.y-fK.y);if(c==0)c=1e-4;if(this.ak7){i=Math.max(i,0);c=Math.max(c,0)}if(A==0||A==2||A==6||A==8){if(I||this.eE)i6.scale(i,i);
else i6.scale(i,c)}if(A==1||A==3||A==5||A==7){var kA=this.eE||I,ig=M&&I;if(A==1||A==7)i6.scale(kA?c:1,ig?1:c);
else i6.scale(ig?1:i,kA?i:1);if(this.a50&&M){if(A==1||A==7)dh.Cj=(dC.x-fK.x)/(dC.y-fK.y);else dh.k=(dC.y-fK.y)/(dC.x-fK.x)}}var a=new eh;
a.translate(-fK.x,-fK.y);a.concat(i6);a.concat(dh);a.translate(fK.x,fK.y);G=[0,0,1,0,1,1,0,1];E.p.D(G,a,G);
var t=E.K.kN(V);E.K.D(t,G)}if(gX.tj(G))this.H3=G}this.qz(w,n);if(C)y.mU.Iy(w,f,C)};gX.a3P=function(w,n,W,D,j,I){var U=W-w,M=D-n,m=j-w,l=I-n,A=U*U+M*M,g=m*U+l*M,k=g/A,$=w+k*U,C=n+k*M,f=j-$,z=I-C;
return[$,C,Math.sqrt(f*f+z*z)]};gX.prototype.a90=function(){var w=this.H3;return Math.abs(w[1]-w[3])<1e-6&&Math.abs(w[2]-w[4])<1e-6||Math.abs(w[0]-w[2])<1e-6&&Math.abs(w[3]-w[5])<1e-6};
gX.tj=function(w){return E.p.hq(w)||E.p.hq([w[6],w[7],w[4],w[5],w[2],w[3],w[0],w[1]])};gX.prototype.H5=function(w,n,W,D){this.yw=-1;
this.gC=null;w.I.t7=null;w.I.r7=[];w.RP=!0};gX.prototype.oe=function(w,n,W){var D=W.aa(w?w.u.Tg:0);if(D.x||D.y){var j=new eh(1,0,0,1,D.x,D.y);
E.p.D(this.H3,j,this.H3);this.qz(w,n);return!0}return!1};gX.prototype.jZ=function(w){if(w==null)w=this.H3;
var n=w[6]-w[0],W=w[7]-w[1],D=w[4]-w[2],j=w[5]-w[3],I=[w[0],w[1],w[2],w[3],w[0]+n/2,w[1]+W/2,w[2]+D/2,w[3]+j/2,w[6],w[7],w[4],w[5]],U=[];
for(var L=0;L<3;L++){var M=L*4,m=I[M+0],l=I[M+1],A=I[M+2],g=I[M+3];U.push(new ec(m,l));U.push(new ec(m+(A-m)/2,l+(g-l)/2));
U.push(new ec(A,g))}return U};gX.prototype.qz=function(w,n,W){if(W==null)W=!1;var D=this.jZ(),j=D[0],I=D[2],U=D[6],M=D[8];
w.I.VZ={F:[],w:[]};w.I.VZ.F.push("M","L","L","L","Z");w.I.VZ.w.push(j.x,j.y,I.x,I.y,M.x,M.y,U.x,U.y);
var m=this.amN;if(m>1){w.I.oP=JSON.parse(JSON.stringify(w.I.VZ));var l=I.eu(j),A=U.eu(j),g=M.eu(I),k=M.eu(U);
for(var L=1;L<m;L++){w.I.VZ.F.push("M","L","M","L");var $=L/m;w.I.VZ.w.push(j.x+l.x*$,j.y+l.y*$,U.x+k.x*$,U.y+k.y*$);
w.I.VZ.w.push(j.x+A.x*$,j.y+A.y*$,I.x+g.x*$,I.y+g.y*$)}}w.u.Bn=new iB(0,0,ec.cS(D[0],D[2]),ec.cS(D[0],D[6]));
if(this.yw!=-1&&this.yw<9&&this.gC){var C=w.u.m9(this.gC.x,this.gC.y);y.qw.Co(C,w.u.Bn,w,n)}if(!W){w.I.cc=[];
for(var L=0;L<D.length;L++)if(L!=4)w.I.cc.push(D[L].x,D[L].y);var f=this.I7();w.I.cc.push(f.x,f.y)}w.RP=!0};
gX.prototype.clear=function(w){w.u.Bn=null;w.I.t7=null;w.I.VZ=null;w.I.oP=null;w.I.cc=[];w.RP=!0};function dg(w,n){this.XB=null;
this.yw=-1;this.a8B(w)}dg.prototype.l4=function(){return JSON.parse(JSON.stringify(this.XB))};dg.prototype.a8B=function(w){this.XB=JSON.parse(JSON.stringify(w))};
dg.prototype.gO=function(w){return!0};dg.prototype.G_=function(w,n,W,D){var j=this.eT(w,n,D);if(j==-1)return"default";
return"pointer"};dg.prototype.WQ=function(w,n,W,D,j,I,U){this.yw=this.eT(D,w.u.N,U);return this.yw!=-1};
dg.prototype.eT=function(w,n,W){var D=this.acQ(),j=-1,I=1e6;for(var L=0;L<D.length;L++){var U=ec.cS(D[L],w);
if(U<I){j=L;I=U}}return I<(W?y.N5({u:{N:n}},W)*2:20*y.V()/n)?j:-1};dg.prototype.QD=function(w,n,W,D){if(this.yw==-1)return;
var j=w.u.N,I=this.yw,U=E.XB.BI(this.XB);U[I*2]=D.x;U[I*2+1]=D.y;E.XB.NF(U,this.XB)};dg.prototype.H5=function(w,n,W,D){this.yw=-1;
w.RP=!0};dg.prototype.oe=function(w,n,W){var D=W.aa();if(D.x||D.y){var j=new eh(1,0,0,1,D.x,D.y);E.p.D(this.H3,j,this.H3);
this.qz(w)}};dg.prototype.acQ=function(w){var n=E.XB.BI(this.XB),W=[];for(var L=0;L<n.length;L+=2)W.push(new ec(n[L],n[L+1]));
return W};dg.prototype.qz=function(w){var n=this.acQ();w.I.VZ={F:[],w:[]};w.I.VZ.F.push("M","C","C","C","C");
var W=[0,1,2,3,7,11,15,14,13,12,8,4,0];for(var L=0;L<W.length;L++)w.I.VZ.w.push(n[W[L]].x,n[W[L]].y);
w.I.VZ.F.push("M","L","L","M","L","L","M","L","L","M","L","L");W=[4,0,1,2,3,7,11,15,14,13,12,8];for(var L=0;
L<W.length;L++)w.I.VZ.w.push(n[W[L]].x,n[W[L]].y);w.I.cc=[];for(var L=0;L<n.length;L++)w.I.cc.push(n[L].x,n[L].y);
w.RP=!0};dg.prototype.clear=function(w){w.I.VZ=null;w.I.cc=[];w.RP=!0};function hY(){this.J3=!1;this.nG=!1;
this.agw=!1;this.aoL=!1;this.Iu=!1;this.TC=!1;this.yp=0;this.TP=0}hY.prototype.WQ=function(w){this.J3=!0;
this.nG=!1;this.Iu=w.U(aK.WO);this.TC=w.U(aK.PJ);this.yp=this.Iu?0:1;this.TP=this.TC?0:1};hY.prototype.oe=function(w){var n=this.aoL=w.U(aK.WO),W=this.agw=w.U(aK.PJ);
if(this.nG){if(this.yp==0&&!n)this.yp++;if(this.yp==1&&n)this.yp++;if(this.TP==0&&!W)this.TP++;if(this.TP==1&&W)this.TP++}};
hY.prototype.QD=function(){this.nG=!0};hY.prototype.H5=function(){this.J3=!1};hY.prototype.i6=function(L){if(L==0)return this.J3?this.TC:this.agw;
if(L==1)return this.nG?this.TP==2:!1};hY.prototype.m$=function(L){if(L==0)return this.J3?this.Iu:this.aoL;
if(L==1)return this.nG?this.yp==2:!1};y.History=function(){y.qw.call(this,"History",y.eb);this.gV=!0;
this.ahe=0};y.History.prototype=new y.qw;y.History.prototype.Al=function(w,n,W,D){W.tL=!0;if(w.d=="h_itemchange"){if(w.index<W.QQ)for(var L=W.QQ;
L>w.index;L--)this.u8(W);if(w.index>W.QQ)for(var L=W.QQ;L<w.index;L++)this.bD(W)}if(w.d=="h_stepfwd")this.bD(W);
if(w.d=="h_stepbck")this.u8(W);if(w.d=="h_undoredo"){var j=this.gV||this.ahe!=W.QQ;if(j){this.u8(W);
j=!1}else{this.bD(W);j=!0}this.gV=j;this.ahe=W.QQ}if(w.d=="h_clear"){if(!window.confirm("Do you really want to clear all states in History? You won't be able to undo it."))return;
W.history=[new go([1,0],null)];W.QQ=0}else this.gV=!0};y.History.prototype.u8=function(w){if(w.QQ==0)return;
var n=w.history[w.QQ];n.G.ZE(n.data,w);w.QQ--};y.History.prototype.bD=function(w){if(w.QQ==w.history.length-1)return;
var n=w.history[w.QQ+1];n.G.Fd(n.data,w);w.QQ++};y.G$=function(){y.qw.call(this,"Layers",y.Yu);this.xh=null};
y.G$.prototype=new y.qw;y.G$.prototype.Al=function(w,n,W,D,j){this.xh=n;var I=w.d,U=w.j!=null?w.j:W.g.length!=0?W.g[0]:W.C.length-1,M=W.C[U];
W.rR=!0;var m=D.U(aK.PJ),l=D.U(aK.WO),A=D.U(aK.CQ);if(I==h.Nk&&W.J==null&&(W.g.length>1||!W.d2(!1)))I=h.R6;
if(I==h.jC){var g=new go([6,33],this),k=M.ue()?["pass"].concat(dD.mS):dD.mS,$=k[w.qY],C=w.j!=null?[w.j]:W.g,f=JSON.stringify(C),z=[];
for(var L=0;L<C.length;L++)z.push(W.C[C[L]].Bx);g.data={d:I,G1:f,hM:z,qY:$};W.kK(g);this.Fd(g.data,W);
this.track(cq.Jf("Md",{t:"enum",v:{BlnM:dD.Eu($)}}))}if(I==h.JM){var g,s=W.by(),C=w.j!=null?[w.j]:W.g,f=JSON.stringify(C);
if(s&&s.data&&s.data.d==I&&s.data.G1==f)g=s;else{var O=cq.Jf("Opct",{t:"UntF",v:{type:"#Prc",val:0}});
this.track(O);var z=[];for(var L=0;L<C.length;L++)z.push(W.C[C[L]].opacity);g=new go([6,32],this);g.data={d:I,G1:f,hM:z,qY:w.qY,Yw:O.E3};
W.kK(g)}g.data.qY=w.qY;g.data.Yw.T.v.Opct.v.val=Math.round(w.qY*100/255);this.Fd(g.data,W)}if(I==h.p6){if(M.add.iOpa==null)M.add.iOpa=255;
var g,s=W.by();if(s&&s.data&&s.data.d==I&&s.data.j==U)g=s;else{g=new go("Fill Opacity Change",this);
g.data={d:I,j:U,hM:M.add.iOpa,qY:w.qY};W.kK(g)}g.data.qY=w.qY;this.Fd(g.data,W)}if(I==h.ge){var a=w.qY,X=w.j!=null?[w.j]:W.g.slice(0),P=[],Z=[],g;
for(var Y=0;Y<X.length;Y++){var K=W.C[X[Y]];if(K.add.lspf==null)K.add.lspf=0;var z=K.add.lspf,$=z;for(var L=0;
L<a[0].length;L++){var S=a[1][L],G=1<<S;if(($&G)==0&&a[0][L])$^=G;else if(($&G)!=0&&!a[0][L])$^=G}P.push(z);
Z.push($)}var s=W.by(),C=JSON.stringify(X);if(s&&s.data&&s.data.d==I&&JSON.stringify(s.data.G1)==C){g=s;
g.data.qY=Z}else{var g=new go([6,57,1],this);g.data={d:I,G1:C,hM:P,qY:Z};W.kK(g)}this.Fd(g.data,W)}if(I==h.Wm){var V="----",T=w.qp,$=null;
for(var L=0;L<gQ.aH.Pi.length;L++)if(M.add[gQ.aH.Pi[L]])V=gQ.aH.Pi[L];var R=M.add[V];if(T=="TySh")$=hd._3(50,50,j.Hu);
var g=new go("Layer Type",this);g.data={d:I,j:U,ar9:[V,R],qp:[T,$]};W.kK(g);this.Fd(g.data,W)}if(I==h.Ll){var X=[];
if(m){var x=W.by(),v=x?x.data:null;if(x!=null&&x.G==this&&v.d==h.Ll&&v.G1.length!=1){var N=new ed(b.E.v);
N.G=y.eb;N.data={d:"h_stepbck"};n.S(N);if(v.j==U)return}var u=W.root.fs(U),H=u,F=[w.j];while(H.parent!=W.root){F.push(H.parent.index);
H=H.parent}for(var L=0;L<W.C.length;L++){var t=W.C[L],H=W.root.fs(L),o=F.indexOf(L)!=-1?!0:t.I4()&&u.depth<H.depth;
if(o!=t.I4())X.push(L)}}else if(w.G1)X=w.G1;else{X.push(U);var q=W.C[U].I4(),O={hZ:q?"hide":"show",E3:{classID:q?"Hd":"Shw",null:{t:"VlLs",v:[cq.Pz("Lyr",!0)]}}};
this.track(O)}var g=new go("Layer visibility",this,!0);g.data={d:I,G1:X,j:U};W.kK(g);this.Fd(g.data,W)}if(I==h.Gz){if(j.No==y.yl){var _=new ed(b.E.L);
_.data={d:b.c.CV,G:y.Rv};n.S(_)}var d=w.aej,r=w.LM,B,escape=!1,i=!1;if(w.sL){if(A&&(r==0||r==1||r==2)){var p=0;
if(l)p++;if(m)p+=2;var Q=new ed(b.E.v,!0);Q.G=y.wA;Q.data={d:"fromlayer",HD:[w.j,r,p]};n.S(Q);return}}var O={hZ:"select",E3:{classID:"null",MkVs:{t:"bool",v:!1}}};
W.a6X();if(D.U(aK.CQ)||w.y$==0){var c=W.g.indexOf(U);if(c==-1)W.g.push(U);else if(W.g.length>1){if(w.y$!=0)W.g.splice(c,1)}W.g.sort(function(g,ji){return g-ji});
O.E3.selectionModifier={t:"enum",v:{selectionModifierType:"addToSelection"}};B=U}else if(l&&!m&&r>0){I=r==1?h.Gw:r==2?h.Uo:h.cV;
escape=!0}else if((l||w.y$==1)&&W.g.length>0){var h2=Math.min(U,W.g[0]),jX=Math.max(U,W.g[W.g.length-1]);
W.g=[];for(var L=h2;L<=jX;L++)if(W.C[L].add.lsct!=ef.Cq)W.g.push(L);O.E3.selectionModifier={t:"enum",v:{selectionModifierType:"addToSelectionContinuous"}};
B=U}else{B=U;if(U>=W.C.length)return;var t=W.C[U];if(t&&t.ue()&&w.ahL)t.add.lsct=ef.fz;else if(W.g.length==1&&W.g[0]==U&&Math.max(0,r)==t.eL){i=!0;
W.rR=!1}if(!i){W.g=[U];W.jO()}}if(!i){if(B!=null&&B<W.C.length){O.E3.null={t:"obj ",v:[{t:"name",v:{classID:"Lyr",val:W.C[B].getName()}}]},this.track(O)}if(!escape){console.log("no escape");
if(W.g.length==1){var bm=W.g[0];for(var L=0;L<W.C.length;L++){if(L==bm)continue;var K=W.C[L];K.eL=0;
K.na=!1}var M=W.C[bm];if(r==2){M.na=!M.na;W.rs=[]}else if(M){M.eL=r<=0?0:r}}else for(var L=0;L<W.C.length;
L++){var K=W.C[L];K.eL=0;K.na=!1}W.zS=null;W.tL=!0}}if(w.sL&&m){if((r==1||r==3)&&d!=null){var Q=new ed(b.E.v,!0);
Q.G=y.Nt;Q.data={d:"mskView",Z:d!=0?0:l?1:2};n.S(Q)}else{this.Al({d:h.Yt,j:w.j},n,W,D,j)}}}if(I==h.Gw||I==h.cV){var dC=I==h.Gw,fn=dC?M._N():M.NP(W).z;
if(fn==null)return;var g=new go(fn.isEnabled?dC?[6,15]:[6,42]:dC?[6,14]:[6,41],this);g.data={d:I,j:U};
W.kK(g);this.Fd(g.data,W)}if(I==h.Uo){var fn=M.add.vmsk;if(fn==null)return;var g=new go(fn.isEnabled?[6,17]:[6,16],this);
g.data={d:I,j:U};W.kK(g);this.Fd(g.data,W)}if(I==h.a2z){var fK=M.add.lsct==ef.fz?ef.Se:ef.fz,H=W.root.fs(W.C.indexOf(M)),kA=!1;
if(D.U(aK.CQ)){var i6=H.parent;for(var L=0;L<i6.children.length;L++){var dh=i6.children[L].j;if(dh.ue())dh.add.lsct=fK}}else M.add.lsct=fK;
for(var L=0;L<W.g.length;L++){var ig=W.g[L];if(H.r$<ig&&ig<H.index)kA=!0}if(kA)W.g=[H.index];W.tL=!0}if(I==h.Yt){if(!W.aV(U))return;
var g=new go(M.QY?[6,19]:[6,18],this);g.data={d:I,j:U};W.kK(g);if(w.qY==null||w.qY!=M.QY)this.Fd(g.data,W)}if(I==h.ax7){if(M.IF())M.FK-=32;
else M.FK+=32;W.tL=!0}if(I==h.Aj||I==h.lf){var g;if(I==h.Aj)g=new go(M.add.lmfx.masterFXSwitch.v?[6,30,0]:[6,29],this);
if(I==h.lf)g=new go(M.add.SoLd.filterFX.v.enab.v?[6,44]:[6,43],this);g.data={d:I,j:U};W.kK(g);this.Fd(g.data,W)}if(I==h.oO||I==h.GG){var bm=w.index,g;
if(I==h.oO)g=new go(M.add.lmfx[at.Pa[bm[0]]].v[bm[1]].v.enab.v?[6,30,0]:[6,29],this);if(I==h.GG)g=new go(M.add.SoLd.filterFX.v.filterFXList.v[bm].v.enab.v?[6,44]:[6,43],this);
g.data={d:I,j:U,index:w.index};W.kK(g);this.Fd(g.data,W)}if(I==h.eI){if(w.src==w.b2)return;var iJ=W.C[w.src],fL=W.C[w.b2],fB=iJ.add.lmfx?JSON.stringify(iJ.add.lmfx):"",ah=fL.add.lmfx?JSON.stringify(fL.add.lmfx):"";
if(fL.add.lmfx==null){fL.add.lmfx=JSON.parse(at.default);for(var L=0;L<at.order.length;L++)fL.add.lmfx[at.Pa[L]]={t:"VlLs",v:[]}}if(w.cf==null){fL.add.lmfx=JSON.parse(fB);
if(!m)delete iJ.add.lmfx}else{var eS=w.cf[0],gL=at.Pa[eS];if(at.af4.indexOf(at.order[eS])==-1)fL.add.lmfx[gL].v=[];
fL.add.lmfx[gL].v.push(iJ.add.lmfx[gL].v[w.cf[1]]);if(!m)iJ.add.lmfx[gL].v.splice(w.cf[1],1)}var e_=iJ.add.lmfx?JSON.stringify(iJ.add.lmfx):"",c2=fL.add.lmfx?JSON.stringify(fL.add.lmfx):"";
if(!fL.IF())fL.FK+=32;var g=new go("Move Layer Styles",this);g.data={d:I,tr:w.src,k1:w.b2,atF:fB,abE:ah,a0p:e_,avl:c2};
W.kK(g);this.Fd(g.data,W)}if(I==h.jX){if(w.src!=null)U=w.src;var K=W.C[U],jS=JSON.stringify(K.add.SoLd),ie=JSON.parse(jS),as=ie.filterFX.v.filterFXList.v;
as.splice(w.cf,1);var g=new go([6,53],this);g.data={d:h.U7,ek:[{Ay:U,Bp:[jS,JSON.stringify(ie)]}]};W.kK(g);
this.Fd(g.data,W)}if(I==h.aox){var gb=m,iJ=W.C[w.src],fL=W.C[w.b2],gx=[];if(iJ!=fL&&fL.add.SoLd==null){alert("Target layer is not a smart object!");
return}if(iJ==fL&&!gb&&w.cf==w.a9)return;if(iJ==fL&&w.cf==-1)return;var eo=iJ.NP(W),jS=JSON.stringify(iJ.add.SoLd),ie=JSON.parse(jS),as=ie.filterFX.v.filterFXList.v;
if(iJ==fL){as.splice(w.a9,0,as[w.cf]);if(!gb)as.splice(w.cf+(w.cf<w.a9?0:1),1);gx.push({Ay:w.src,Bp:[jS,JSON.stringify(ie)]})}else if(w.cf==-1){var di=ie.filterFX;
if(!gb){delete ie.filterFX;gx.push({Ay:w.src,Bp:[jS,JSON.stringify(ie)],Nq:[eo,null]})}var d0=fL.YC()?fL.NP(W):null,e6=kc.a2e(eo),dt=JSON.stringify(fL.add.SoLd),gJ=JSON.parse(dt);
gJ.placed.v=e6.id;gJ.filterFX=di;gx.push({Ay:w.b2,Bp:[dt,JSON.stringify(gJ)],Nq:[d0,e6]})}else{var iW=as[w.cf];
if(!gb){as.splice(w.cf,1);gx.push({Ay:w.src,Bp:[jS,JSON.stringify(ie)]})}var dt=JSON.stringify(fL.add.SoLd),gJ=JSON.parse(dt);
if(gJ.filterFX==null)gJ.filterFX=cx.Gq();var g5=gJ.filterFX.v.filterFXList.v;g5.splice(w.a9,0,iW);var jW={Ay:w.b2,Bp:[dt,JSON.stringify(gJ)]};
if(!fL.YC()){var e6=kc.ap8(fL.add.SoLd.placed.v);jW.Nq=[null,e6]}gx.push(jW)}var g=new go([6,52],this);
g.data={d:h.U7,ek:gx};W.kK(g);this.Fd(g.data,W)}if(I==h._9){var fn=M._N(),g=new go(fn.gm?[6,26]:[6,25],this);
g.data={d:I,j:U};W.kK(g);this.Fd(g.data,W);this.track({hZ:"set",E3:{classID:"setd",null:{t:"obj ",v:[cq.Pz("Lyr",!0)]},T:{t:"Objc",v:{classID:"Lyr",Usrs:{t:"bool",v:fn.gm}}}}})}if(I==h._x){var fn=M.add.vmsk,g=new go(fn.gm?[6,28]:[6,27],this);
g.data={d:I,j:U};W.kK(g);this.Fd(g.data,W)}if(I==h.ws){var g=new go("Variables / Datasets",this),eP=JSON.stringify([W.ol,W.Ei]);
if(eP==w.Z)return;g.data={d:I,ait:eP,azy:w.Z};W.kK(g);this.Fd(g.data,W)}if(I==h.Di){var b_=[],g;for(var L=0;
L<W.g.length;L++){var Y=W.g[L],t=W.C[Y];if(t.add.vogk)b_.push(Y,JSON.stringify(t.add.vogk))}for(var L=0;
L<W.rs.length;L++){var Y=W.rs[L],t=W.Oi[Y];if(t.add.vogk)b_.push(-1-Y,JSON.stringify(t.add.vogk))}E.X.a9c(W,w.Z,w.ar_);
var fZ=[];for(var L=0;L<W.g.length;L++){var Y=W.g[L],t=W.C[Y];if(t.add.vogk)fZ.push(Y,JSON.stringify(t.add.vogk))}for(var L=0;
L<W.rs.length;L++){var Y=W.rs[L],t=W.Oi[Y];if(t.add.vogk)fZ.push(-1-Y,JSON.stringify(t.add.vogk))}var s=W.by();
if(s&&s.data&&s.data.d==I){var im=!0;for(var L=0;L<b_.length;L+=2)if(b_[L]!=s.data.tO[L])im=!1;if(im){g=s;
g.data.EK=fZ}}if(g==null){var g=new go([12,91,1],this);g.data={d:I,tO:b_,EK:fZ};W.kK(g)}this.Fd(g.data,W)}if(I==h.nL){var j3=JSON.stringify(M.add.artb),dr=JSON.stringify(w.oL),g;
W.C[U].add.artb=JSON.parse(dr);var c0=new iB(0,0,W.m,W.n),fM=y.QJ.cK(W),s=W.by();if(s&&s.data&&s.data.d==I&&s.data.j==U){g=s;
g.data.oL=dr}if(g==null){var g=new go("Editing Artboard",this);g.data={d:I,j:U,a11:j3,oL:dr,G8:c0};W.kK(g)}g.data.uU=fM;
this.Fd(g.data,W)}if(I==h.QE){var fZ=W.yo.slice(0),cB=W.v9.slice(0),iI=W.J,jD=W.J;if(w.vK=="fromAction"){var j8=w.Z.hZ,jG=w.Z.E3;
if(j8=="make"||j8=="duplicate"){var i1=fZ.length,a_=!1,aR=!1;if(W._A())i1--;var bH=new h.ac;bH.name="Alpha "+(i1+1);
if(j8=="make"){var iY=jG.Nw.v;bH.color=0;cB=[i1];bH.$P=!0;bH.Zg=iY.Opct.v;if(iY.Nm)bH.name=iY.Nm.v;if(iY.classID=="SCch"){a_=!0;
jD=null;bH.Y3=1}}else{var gy=jG.null.v[0].v;if(gy.keyID=="fsel")a_=!0;else{var gr=y.eZ.ajY(W);jD=y.eZ.aaX(W,gr);
bH.color=0;bH.rect=jD.rect;bH.channel=jD.channel}}if(a_){bH.color=0;if(W.J){bH.rect=W.J.rect.clone();
bH.channel=W.J.channel.slice(0)}if(aR){bH.color=255-bH.color;E.Ba(bH.channel)}}for(var L=0;L<W.yo.length;
L++)W.yo[L].$P=!1;W.u.zC=[0,0,0];fZ.splice(i1,0,bH)}else if(j8=="delete"){if(M&&M._N()&&M.eL==1){this.Al({d:h.kR},n,W,D,j);
return}var fs=W.v9;fs.sort(function(g,ji){return ji-g});if(fs.length==0)return;for(var L=0;L<fs.length;
L++)fZ.splice(fs[L],1);cB=[];W.u.zC=[1,1,1]}else if(j8=="hide"){fZ[cB[0]]=fZ[cB[0]].clone();fZ[cB[0]].$P=!1}}if(w.vK=="rnm"){fZ[w.p_]=fZ[w.p_].clone();
fZ[w.p_].name=w.name}var g=new go("Channel Edit",this);g.data={d:I,tO:W.yo.slice(0),DD:W.v9.slice(0),EK:fZ,Ib:cB,Py:iI,TY:jD};
this.Fd(g.data,W);W.kK(g)}if(I==h.ZM){var dQ=new iB(0,0,W.m,W.n),g=new go(w.s7,this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:w._B,Sz:W.g.slice(0),zu:w.TY};
W.kK(g);this.Fd(g.data,W);var ep=y.QJ.xJ(W);if(ep){g.data.G8=dQ;g.data.uU=ep}}if(I==h.du){var b2=W.qu(null,w.j),iz=1e10;
if(b2.length==0)return;if(W.C.length==b2.length){alert("Project must have at least 1 layer");return}var eX=[];
for(var L=0;L<W.C.length;L++)if(b2.indexOf(L)==-1)eX.push(W.C[L]);for(var L=0;L<b2.length;L++)iz=Math.min(iz,b2[L]);
iz=Math.max(iz-1,0);while(eX[iz].name=="</Layer group>")iz++;this.track({hZ:"delete",E3:{classID:"Dlt",null:cq.Pz("Lyr",!0)}});
var c0=new iB(0,0,W.m,W.n),g=new go([6,31],this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[iz]};
W.kK(g);this.Fd(g.data,W);var fM=y.QJ.cK(W);if(fM){g.data.uU=fM;g.data.G8=c0;y.QJ.xJ(W)}}if(I==h.K9){if(!D.U(aK.WO))return;
var g=new go("Switch Layer Link",this);g.data={d:I,j:w.j};W.kK(g);this.Fd(g.data,W)}if(I==h.qf){var fs=w.a6Z?w.a6Z:W.g,en=0,d1=!1;
if(fs.length==0)return;if(fs.length==1&&W.C[fs[0]].Ux==0){alert(fV.get([15,7,5]));return}var ko=[];for(var L=0;
L<W.C.length;L++){var fh=W.C[L].Ux;ko.push(fh);en=Math.max(en,fh)}var j_=-1,h9=-1;for(var L=0;L<fs.length;
L++){var fh=W.C[fs[L]].Ux;if(fh==0)d1=!0;else if(j_==-1||j_==fh)j_=fh;else h9=fh}if(!d1)for(var L=0;
L<fs.length;L++)W.C[fs[L]].Ux=0;else if(j_!=-1&&h9==-1)for(var L=0;L<fs.length;L++)W.C[fs[L]].Ux=j_;
else for(var L=0;L<fs.length;L++)W.C[fs[L]].Ux=en+1;var ha=[];for(var L=0;L<W.C.length;L++){var fh=W.C[L].Ux;
if(ha[fh]==null)ha[fh]=0;ha[fh]++}for(var L=0;L<W.C.length;L++){var fh=W.C[L].Ux;if(ha[fh]==1)W.C[L].Ux=0}var fl=ko;
ko=[];for(var L=0;L<W.C.length;L++){var fh=W.C[L].Ux;ko.push(fh);en=Math.max(en,fh)}var g=new go(d1?[6,54,0]:[6,54,1],this);
g.data={d:h.qf,afF:fl,alz:ko};W.kK(g);this.Fd(g.data,W)}if(I==h.R6&&(w.j!=null||W.g.length!=0)||I==h.v0){var ex=W.Jr(I==h.R6?w.j:U,null,w.a22),aI;
if(I==h.v0){var K=ex[0],j8=K.add.SoLd.Idnt.v,ba=W.mZ(j8).clone();K.add.SoLd.Idnt.v=ba.Z4=kc.Fa()+j8.slice(8);
W.add.lnk2.push(ba)}if(I==h.R6){var ik={hZ:"duplicate",E3:{classID:"null",null:cq.Pz("Lyr",!0)}};if(w.np){ex[ex.length-1].nz(w.np);
ik.Nm={t:"TEXT",v:w.np}}this.track(ik);w.aeo=w.j}I=h.jF;w.C=ex;w.Wv=W;w.SY=W}if(I==h.jF){var c3,br,bi=w.Wv,cZ=w.SY,ct=0,cy=0,fX=!1,a0,cN=0,a4=0;
if(bi!=cZ){console.log("ADDLAYERS different projs");var c3=new iB(0,0,bi.m,bi.n),br=new iB(0,0,cZ.m,cZ.n),ib=[],hb=[];
for(var L=0;L<w.C.length;L++){var K=w.C[L];if(K.add.SoLd==null)continue;var j8=K.add.SoLd.Idnt.v;if(ib.indexOf(j8)==-1){ib.push(j8);
hb.push(kc.Fa()+j8.slice(8))}K.add.SoLd.Idnt.v=hb[ib.indexOf(j8)];var eo=K.NP(bi);if(eo){bi._7(eo);cZ.V$(eo)}}if(ib.length>0){if(cZ.add.lnk2==null)cZ.add.lnk2=[];
for(var L=0;L<ib.length;L++){var kg=bi.mZ(ib[L]),ba=kg.clone();ba.Z4=hb[L];cZ.add.lnk2.push(ba)}}}var iI=cZ.g.slice(0);
iI.sort(function(g,ji){return g-ji});var eX=cZ.C.slice(0),jD=[],kh=-1;for(var L=0;L<iI.length;L++)kh=Math.max(kh,iI[L]);
if(w.aeo!=null)kh=w.aeo;var hA=bi.H2();if(w.sR){kh=w.sR-1;var iO=cZ.C[w.sR].yP();ct+=iO.x;cy+=iO.y}if(hA!=-1&&(bi!=cZ||w.sR)){var fj=bi.C[hA].yP();
ct-=fj.x;cy-=fj.y}var io=cZ.Iw();for(var L=0;L<io[0].length;L++){var ia=io[1][L];if(ia!=-1)io[1][L]=eX[ia]}kh++;
for(var L=0;L<w.C.length;L++){var t=w.C[L],eK=t.add.artb;eX.splice(kh,0,t);jD.push(kh);kh++;if(eK){a0=!0;
var hH=eK.guideIndeces;if(hH){hH=hH.v;for(var eA=0;eA<hH.length;eA++){io[0].push(bi.jg[hH[eA].v].slice(0));
io[1].push(t);fX=!0}}}}for(var L=0;L<io[0].length;L++){var ia=io[1][L];if(ia!=-1)io[1][L]=eX.indexOf(ia)}for(var L=0;
L<w.C.length;L++){var t=w.C[L];if(t.add.lsct==ef.Cq){if(cN==0)a4++;cN++}else if(t.ue())cN--}if(a4==1)jD=[kh-1];
var g=new go([6,0],this);g.data={d:h.ZM,VQ:cZ.C.slice(0),_B:eX,Sz:iI,zu:jD};if(fX){g.data.N2=[cZ.Iw(),io]}cZ.kK(g);
this.Fd(g.data,cZ);if(ct!=0||cy!=0)y.mU.Gt(cZ,cZ.qu(),null,ct,cy);if(a0){g.data.G8=new iB(0,0,cZ.m,cZ.n);
g.data.uU=y.QJ.cK(cZ);y.QJ.xJ(cZ)}}if(I==h.a1O){var h7=w.j!=null?[w.j]:W.qu(),eX=W.C.slice(0);for(var L=0;
L<h7.length;L++){var t=W.C[h7[L]].clone();t.i0(W);eX.splice(h7[L],1,t)}var g=new go([6,8],this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:W.g.slice(0)};
W.kK(g);this.Fd(g.data,W)}if(I==h.atm){var eX=W.C.slice(0),t=eX[W.g[0]]=eX[W.g[0]].clone(),gY=t.add.lmfx,iv,iO;
delete t.add.lmfx;var b4=W.g[0],e5=b4+1;if(t.ue()){var kd=W.C[W.g[0]].US;iO=kd.axv;iv=kd.gY;var H=W.root.fs(b4);
b4=H.r$}else{iO=t.rect;iv=E.Q(iO.O());E.hN(t.buffer,iv,3)}var aG=ge.og(gY,t.add.fxrp,iv,iO,W,iO).type;
for(var L=0;L<at.order.length;L++){var d$=at.order[L],cc=aG[d$];cc.reverse();for(var eA=0;eA<cc.length;
eA++){var dq=cc[eA],C=W.QI(),gi=L>7;if(d$=="ebbl"){if(dq.T4||dq.WY){var gG=dq.T4?dq.T4:dq.WY;if(dq.T4)delete dq.T4;
else delete dq.WY;if(dq.WY||dq.ql)eA--}else if(dq.ql||dq.TV){var gG=dq.TV?dq.TV:dq.ql;if(dq.TV){delete dq.TV;
if(dq.ql)eA--}gi=!0}dq=gG}C.Bx=dq.ZA;C.opacity=Math.round(255*dq.K8);C.buffer=dq.Q0;C.rect=dq.aA.clone();
C.rect.offset(iO.x,iO.y);if(d$=="FrFX"){C.buffer=C.buffer.slice(0);E.IL(dq.fO?dq.fO:dq.bU,C.buffer,3);
if(dq.fO){gi=!0;delete dq.fO;if(dq.bU)eA--}}C.QY=!gi;C.nz(t.getName()+"'s "+fV.get(at.names[L]));eX.splice(gi?b4:e5,0,C);
if(gi)e5++}}var g=new go("Styles to Layers",this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[e5-1]};
W.kK(g);this.Fd(g.data,W)}if(I==h.fi){var h7=W.qu(),eX=W.C.slice(0),dK=new iB(0,0,W.m,W.n);for(var L=0;
L<h7.length;L++){var gv=W.C[h7[L]],cm=gv.I4();gv.gb(!0);var jP=W.root.fs(h7[L]);if(gv.ue())continue;
if(jP==null)continue;var t=gv.clone();t.i0(W);var cW=jP.pJ(W,!0),ii=W.C;W.Gd([gv]);W.l();W.tw();t.buffer=E.Q(cW.O()*4);
E.Cb(W.Vc(),dK,t.buffer,cW);t.rect=cW;t.opacity=255;t.add.iOpa=255;t.Bx="norm";t.l();t.US.Wq=!0;W.Gd(ii);
if(t.add.lmfx)delete t.add.lmfx;t.z=t.pv=null;eX.splice(h7[L],1,t);t.gb(cm);gv.gb(cm)}var g=new go([6,34],this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:W.g.slice(0)};W.kK(g);this.Fd(g.data,W)}if(I==h.atX){var h7=W.qu(),eX=W.C.slice(0);
for(var L=0;L<h7.length;L++){var t=W.C[h7[L]],ju=t.add.TySh;if(ju==null)continue;var K=new d2(ju._o,j.hY),b8=E.p.e7(aj.wh(K,ju));
for(var jM in b8){var f6=b8[jM],dh=t.clone();delete dh.add.TySh;dh.FK=dh.FK|1<<4;dh.add.SoCo=JSON.parse(JSON.stringify(at.Iz[0]));
var it=dh.add.SoCo.Clr.v;it.Rd.v=parseInt(jM.slice(1,3),16);it.Grn.v=parseInt(jM.slice(3,5),16);it.Bl.v=parseInt(jM.slice(5,7),16);
var iG=new h.Rd;iG.i=E.p.oF(f6,!1);if(dh.add.vmsk!=null){dh.add.vmsk.aaA();iG.concat(dh.add.vmsk)}dh.add.vmsk=iG;
dh.add.vstk=JSON.parse(JSON.stringify(at.QO.default));dh.hu();dh.yb(W);eX.splice(eX.indexOf(t),0,dh)}eX.splice(eX.indexOf(t),1)}var jD=W.g.slice(0);
for(var L=jD.length-1;L>=0;L--)if(jD[L]>=eX.length)jD.splice(L,1);var g=new go([6,40],this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:jD};
W.kK(g);this.Fd(g.data,W)}if(I==h.jh){var j0=W.g.length,cS,ar;if(j0<2){alert("Select two or more layers.");
return}for(var L=0;L<j0;L++){var fj=W.C[W.g[L]].rect;cS=L==0?fj:cS.wU(fj);ar=L==0?fj:ar.x0(fj)}if(cS.O()*1.2>ar.O()){alert("stacking images");
var fC=[],kp=[];for(var L=0;L<j0;L++){var t=W.C[W.g[L]];fC.push(t.buffer);kp.push(t.rect)}var dO=E.aa$.Ig(fC,kp),iN=dO[0],iU=dO[1],g$=[];
for(var L=0;L<j0;L++){var fn=new h.ac;fn.color=255;fn.rect=iU;fn.channel=iN[L];g$.push(W.g[L],null,fn)}var g=new go("Focus-Stack",this);
g.data={d:h.Xw,Xi:g$};W.kK(g);this.Fd(g.data,W);return}if(!W.dD())return;var dh=W.C[W.g[0]].clone(),eX=[];
for(var L=0;L<W.C.length;L++)if(W.g.indexOf(L)==-1)eX.push(W.C[L]);eX.splice(W.g[0],0,dh);for(var L=1;
L<j0;L++)if(W.C[W.g[L]].rect.O()>2e6){alert("Blended areas are too large.");return}for(var L=1;L<j0;
L++){var t=W.C[W.g[L]],iU=t.rect.clone();iU.VD(1,1);var ji=E.Q(iU.O()*4);E.Cb(t.buffer,t.rect,ji,iU);
dh.extend(iU);var hr=E.Q(iU.O()*4);E.Cb(dh.buffer,dh.rect,hr,iU);var g=E.Q(iU.O());E.hN(ji,g,3);E.round(g,200);
E.IL(g,ji,3);E.s._U("norm",ji,iU,hr,iU,iU,1);E.PZ.ay(hr,g,iU);E.Cb(hr,iU,dh.buffer,dh.rect)}var g=new go([2,10,0],this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[W.g[0]]};W.kK(g);this.Fd(g.data,W)}if(I==h.x9){var eX=W.C.slice(0),cB=W.g.slice(0);
for(var L=0;L<eX.length;L++){var t=eX[L],hW=t.add.vmsk;if(t.I9()&&hW&&t.add.vstk.strokeEnabled.v&&!t.add.vstk.fillEnabled.v){var f5=hW.i,j2=0,fP=-1;
for(var eA=0;eA<f5.length;eA++){if((f5[eA].type==0||f5[eA].type==3)&&f5[eA].Ht!=-1){j2++;if(f5[eA].type==3&&fP==-1){f5[eA].S1=f5[eA].Ht=1;
fP=eA}}}if(j2>1&&fP!=-1&&j2<10){console.log("separating an open path into a new layer");t=t.clone();
hW=t.add.vmsk;f5=hW.i;var C=f5[fP].length,ay=t.clone();ay.add.lyid=W.jd();hW.i=f5.slice(0,2).concat(f5.slice(fP,fP+C+1));
hW.g=[];t.yb(W);t.l();var ca=ay.add.vmsk.i;ay.add.vmsk.i=ca.slice(0,fP).concat(ca.slice(fP+C+1,ca.length));
ay.add.vmsk.g=[];ay.yb(W);eX[L]=t;eX.splice(L+1,0,ay);for(var eA=0;eA<cB.length;eA++)if(cB[eA]>L)cB[eA]++;
var aW=cB.indexOf(L);if(aW!=-1){cB.splice(aW+1,0,L+1)}}}}if(eX.length!=W.C.length){var g=new go("Splitting open paths",this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:cB};W.kK(g);this.Fd(g.data,W)}}if(I==h.zi){this.Al({d:h.x9},n,W,D,j);
var iI=W.g.slice(0),ii=W.C.slice(0),h7=W.qu();if(h7.length==0)return;W.ad7(h7,!1,w.$x);var g=new go([6,36,0],this);
g.data={d:h.ZM,VQ:ii,_B:W.C.slice(),Sz:iI,zu:W.g.slice(0)};W.kK(g);this.Fd(g.data,W)}if(I==h.aqY){var jS=M.add.SoLd;
if(jS==null)return;var j8=jS.Idnt.v,ak=W.mZ(j8);ak.Vc(!1);var fF=ak.PO[0],iU=ak.PO[1];if(E.Ym(fF)){alert("The smart object contains transparency.");
return}var kn=jj.ZO("jpg").La([[fF.buffer]],iU.m,iU.n,[90]);this.Al({d:h.v4,data:new Uint8Array(kn),O7:"image.jpg"},n,W,D,j);
console.log(W.add);return}if(I==h.v4){var dK=w.On,j8=w.id;if(dK==null)dK=W;if(j8==null)j8=M.add.SoLd.Idnt.v;
var kg=dK.mZ(j8),ba=kg.clone();ba.raw=w.data;ba.O7=w.O7;var jc=jj.zJ(w.data.buffer);if(jc=="psd"){ba.TA="8BIM";
ba.oq="8BPB"}else{ba.TA=" ";ba.oq=" "}ba.Vc(!1);kg.Vc(!1);var g=new go([6,36,1],this);g.data={d:h.v4,id:j8,kV:kg,QF:ba};
dK.kK(g);this.Fd(g.data,dK)}if(I==h.vZ){var g=new go([6,36,4],this);g.data={d:I,j:U,Z1:M.add.SoLd.Impr.v.classID,qY:w.qY};
W.kK(g);this.Fd(g.data,W)}if(I==h.aly){var ky,f0;if(w.HS){ky=w.On;f0=w.HS}else{w.On.X0();w.On.hd();w.On.l();
w.On.tw();w.On.Vc();ky=jj.ZO("PSD").La(w.On,0,0,[!0,!0]);f0=w.On.name}if(!(ky instanceof ArrayBuffer))throw"e";
ky=new Uint8Array(ky);var c=w.XT;if(c==null){if(W.g.length==0)c=W.g.length;else{var ig=W.g[W.g.length-1],C=W.C[ig];
c=C.ue()?ig:ig+1}}var hS=new iB(0,0,W.m,W.n),fr=W.H2();if(fr!=-1)hS=W.C[fr].yP();var iD=W.An(ky,f0,null,null,hS,j.hY,n),eX=W.C.slice(0);
eX.splice(c,0,iD);var g=new go([6,36,2],this);g.data={d:h.ZM,VQ:W.C.slice(),_B:eX,Sz:W.g.slice(0),zu:[eX.indexOf(iD)]};
W.kK(g);this.Fd(g.data,W)}if(I==h.rC&&w.vK=="merge"){var dL=[],aQ=W.root.children,jg=0;for(var L=0;L<aQ.length;
L++){var H=aQ[L],t=H.j,h4=H.children,eZ=!0;if(!t.ue()||h4.length==0)continue;for(var eA=0;eA<h4.length;
eA++)if(!h4[eA].j.getName().startsWith("_a_")){eZ=!1;break}if(eZ)dL.push(W.C.indexOf(t))}var jd=[];for(var L=0;
L<dL.length;L++)if(W.g.indexOf(dL[L])!=-1)jd.push(dL[L]);if(jd.length>=2)dL=jd;if(dL.length<2){alert("At least two animation folders needed (whose layers start with \"_a_\").",3500);
return}var fQ=[];for(var L=0;L<dL.length;L++)fQ.push(W.C[dL[L]].getName());var cc=[];for(var hK=0;hK<dL.length;
hK++){var H=W.root.fs(dL[hK]),jW=[[],[],0,hK];cc.push(jW);for(var L=0;L<H.children.length;L++){var Y=H.children[L].index,t=H.children[L].j,bH=t.getName(),cb=20,dF=bH.split(",");
if(dF.length>1){var i_=parseInt(dF.pop());if(!isNaN(i_)&&i_!=0)cb=i_}jW[0].push(t);jW[1].push(cb);jW[2]+=cb}}cc.sort(function(g,ji){return ji[2]-g[2]});
var ew=cc[0],eT=ew[2];for(var ia=1;ia<cc.length;ia++){var jW=cc[ia],h0=1,f_=jW[1].slice(0),jx=0;while((h0+1)*jW[2]<=ew[2]){h0++;
f_=f_.concat(jW[1])}jW[1]=f_;jW[2]*=h0;var gm=ew[2]/jW[2];for(var L=0;L<jW[1].length;L++){var km=Math.floor(jW[1][L]*gm);
jW[1][L]=km;jx+=km}while(jx<eT){jx++;jW[1][jW[1].length-1]++}jW[2]=jx}var i8=[],bx=[],km=[];for(var L=0;
L<cc.length;L++){i8.push(0);bx.push(0)}while(jg<eT){var h6=1e9,i1=-1;for(var L=0;L<cc.length;L++){var dT=cc[L][1],b4=i8[L];
if(b4!=dT.length&&bx[L]+dT[b4]<jg+h6){i1=L;h6=bx[L]+dT[b4]-jg}}bx[i1]+=cc[i1][1][i8[i1]];i8[i1]++;if(h6!=0){km.push(h6);
jg+=h6}}for(var L=1;L<km.length;L++){var ds=km[L];if(ds<16&&(km[L-1]<16||L<km.length-1&&16<=km[L+1])){km[L-1]+=ds;
km.splice(L,1);L--}}var cm=[],dK=new iB(0,0,W.m,W.n);for(var L=0;L<W.C.length;L++){cm[L]=W.C[L].I4();
W.C[L].gb(!1)}var ih=W.g.slice(0);W.g=dL;var b2=W.qu();b2.sort(function(g,ji){return g-ji});var eX=[];
for(var L=0;L<W.C.length;L++){if(b2.indexOf(L)==-1)eX.push(W.C[L])}cc.sort(function(g,ji){return g[3]-ji[3]});
function aM(dT,ek){var L=0,gC=0;while(gC+dT[L]<=ek){gC+=dT[L];L++}return L}jg=0;eX.splice(b2[0],0,W.hG());
for(var dM=0;dM<km.length;dM++){var X=[];for(var L=0;L<cc.length;L++){var b4=aM(cc[L][1],jg)%cc[L][0].length,t=cc[L][0][b4];
X.push(t)}var t=W.QI();for(var L=0;L<cc.length;L++){var f4=X[L],i6=W.C[dL[L]];f4.gb(!0);i6.gb(!0)}W.l();
W.tw();var fF=W.Vc();t.rect=E.tx(fF,dK,2);t.buffer=E.Q(t.rect.O()*4);E.Cb(fF,dK,t.buffer,t.rect);for(var L=0;
L<cc.length;L++){var f4=X[L],i6=W.C[dL[L]];f4.gb(!1);i6.gb(!1)}t.gb(dM==0);t.nz("_a_frm"+dM+","+km[dM]);
eX.splice(b2[0]+1+dM,0,t);jg+=km[dM]}var t=W.QI();t.nz(fQ.join(" + "));t.Bx="pass";t.add.lsct=ef.Se;
t.FK=24;eX.splice(b2[0]+1+km.length,0,t);for(var L=0;L<W.C.length;L++)W.C[L].gb(cm[L]);var g=new go([6,12,0],this);
g.data={d:h.ZM,VQ:W.C,_B:eX,Sz:ih,zu:[b2[0]+1+km.length]};W.kK(g);this.Fd(g.data,W)}if(I==h.g6||I==h.nH){var bP=W.g.length==1&&!W.C[W.g[0]].ue(),cd=!0,iD=null,jD;
if(bP&&W.g[0]==0)return;var ii=W.C.slice(0),iI=W.g.slice(0);if(bP)W.g=[U,U-1];if(I==h.nH){W.g=[];for(var L=0;
L<W.C.length;L++)if(W.C[L].I4())W.g.push(L)}var h7=W.qu();h7.sort(function(g,ji){return g-ji});var gd=new iB,dK=new iB(0,0,W.m,W.n);
for(var L=0;L<h7.length;L++){var Y=h7[L],t=W.C[Y];if(t.ue()||t.getName()=="</Layer group>")continue;
cd=cd&&t.I9()&&t.add.vmsk!=null;gd=gd.x0(W.root.fs(Y).pJ(W,!0))}if(cd){var hW=null;for(var L=0;L<h7.length;
L++){var C=W.C[h7[L]];if(C.rect.O()==0)continue;if(iD==null){iD=C.clone();hW=iD.add.vmsk}else{var C=W.C[h7[L]],ca=h.Rd.Tv(C.add.vmsk.i);
hW.i=hW.i.concat(ca.slice(2));iD.add.vogk=iD.add.vogk.concat(JSON.parse(JSON.stringify(C.add.vogk)))}}iD.add.vmsk.eP=!0;
iD.yb(W)}else if(dK.Yy(gd)){iD=W.QI();iD.nz(W.C[h7[h7.length-1]].getName());iD.rect=gd;iD.buffer=E.Q(gd.O()*4);
var em=W.add.artd;delete W.add.artd;var bD=W.Vc(h7);if(em)W.add.artd=em;E.Cb(bD,dK,iD.buffer,gd);iD.ky();
iD.l()}else{W.ad7(h7,!0);iD=W.C[W.g[0]];W.C.splice(W.g[0],1);var jL=W.mZ(iD.add.SoLd.Idnt.v);W.add.lnk2.splice(W.add.lnk2.indexOf(jL),1);
delete iD.add.SoLd}var fW=m,cG=-1;if(w.E3&&w.E3.Dplc&&w.E3.Dplc.v)fW=!0;if(fW&&I==h.nH&&W.C[iI[0]].oK()&&W.C[iI[0]].rect.VY()){cG=iI[0]}if(cG!=-1||bP){var fz=W.C[cG!=-1?cG:U-1];
iD.nz(fz.getName());iD.add.lclr=fz.add.lclr}var eX=[];for(var L=0;L<W.C.length;L++)if(fW||h7.indexOf(L)==-1)if(L!=cG)eX.push(W.C[L]);
var a3=h7[h7.length-1],a7=a3==W.C.length-1?null:W.C[a3+1],d3=a7?eX.indexOf(a7):eX.length;eX.splice(d3,0,iD);
jD=[d3];var g=new go([6,12,0],this);g.data={d:h.ZM,VQ:ii,_B:eX,Sz:iI,zu:jD};W.kK(g);this.Fd(g.data,W)}if(I==h.aza){var dh=W.QI();
dh.rect=new iB(0,0,W.m,W.n);dh.buffer=E.Q(dh.rect.O()*4);E.cJ(dh.buffer,4294967295);E.s._U("norm",W.Vc(),dh.rect,dh.buffer,dh.rect,dh.rect,1);
dh.nz("Background");dh.add.lspf=1<<2;var g=new go([6,12,1],this);g.data={d:h.ZM,VQ:W.C.slice(),_B:[dh],Sz:W.g.slice(0),zu:[0]};
W.kK(g);this.Fd(g.data,W)}var hQ=I==h.Nk||I==h.cP;if(I==h.tp||I==h.yH||I==h.YS||I==h.nS||hQ){var t=hQ?W.Jr()[0]:W.QI(),ee=fV.get([0,3]),e$=w.np,dG=!1,de,aX;
if(I==h.YS)ee=fV.get([12,76,1]);if(hQ){if(W.J){var gv=W.C[W.g[0]],a8=gv.WC(W,W.J);if(a8==null){alert("Copied area is empty");
return}t.rect=a8.rect;t.buffer=a8.Ey;t.i0(W);t.gb(!0)}else e$=t.getName();t.add.lspf=0;t.QY=!1;if((t.FK&1)!=0)t.FK--}if(I==h.nS){t.rect=y.G$.a5H(w.qH,W);
t.buffer=w.qH.buffer.slice(0);if(w.dV&&W.J){t.z=new h.ac;t.z.rect=W.J.rect;t.z.color=0;t.z.channel=W.J.channel.slice(0)}}if(I==h.tp){this.track({hZ:"make",E3:{classID:"Mk",null:cq.Pz("Lyr")}})}if(I==h.yH){t.FK|=16;
var h$=w.E3.Usng.v,gw=h$.Type.v,fv=eH.Nn[gw.classID];ee=fV.get(eH.names[fv]);if(h$.Nm)e$=h$.Nm.v;t.add[fv]=cx._1(fv);
if(t.add[fv]==null)t.add[fv]={};for(var ei in gw)t.add[fv][ei]=JSON.parse(JSON.stringify(gw[ei]));t.z=y.G$.a2E(W);
t.eL=1}if(I==h.YS){t.FK|=16;var jG=w.E3,h$=jG.Usng.v,bZ=h$.Type.v,aq=h$.Shp;if(h$.Nm)e$=h$.Nm.v;if(aq==null){var el=W.OV(),b8=el[0],ip=el[1];
if(ip.length!=0&&b8[ip[0]].p_<0){var gk=b8[ip[0]].add;t.add.vmsk=gk.vmsk.clone();t.add.vstk=JSON.parse(JSON.stringify(at.QO.default));
t.add.vogk=JSON.parse(JSON.stringify(gk.vogk));W.rs=[]}else t.z=y.G$.a2E(W)}else{t.add.vmsk=new h.Rd;
t.add.vstk=JSON.parse(JSON.stringify(h$.strokeStyle?h$.strokeStyle.v:at.QO.default));t.add.vogk=[];if(aq){var gU=E.X.Oq(aq);
if(gU){t.add.vogk=[gU];t.add.vmsk.i.push({type:0,Ht:1,length:0});E.X.A9(t.add.vogk,t.add.vmsk)}else{aq=aq.v;
var kz=aq.classID;if(kz=="Plgn"){var g4=aq.Cntr.v,fj=aq.corner.v;g4=new ec(g4.Hrzn.v.val,g4.Vrtc.v.val);
fj=new ec(fj.Hrzn.v.val,fj.Vrtc.v.val);t.add.vmsk.i=E.P.AB.Je(g4.x,g4.y,Math.sqrt(fj.x*fj.x+fj.y*fj.y),Math.atan2(fj.y,fj.x),aq.sides.v,0)}else if(kz=="customShape"){var c4=E.X.A_(aq),ae=c4[2]-c4[0],cU=c4[3]-c4[1],ea=j.Jz,jt,hM;
for(var L=0;L<ea.length;L++)if(ea[L].fR==aq.Nm.v)jt=ea[L];if(jt){hM=h.Rd.Tv(jt.i);E.P.c0(hM,new eh(ae,0,0,cU,c4[0],c4[1]))}else hM=E.P.AB.Rect(c4[0],c4[1],ae,cU,0);
t.add.vmsk.i=hM}t.hu()}}}var kk={solidColorLayer:0,gradientLayer:1,patternLayer:2}[bZ.classID],gW=["SoCo","GdFl","PtFl"][kk];
t.add[gW]=JSON.parse(JSON.stringify(at.Iz[kk]));if(kk==0)t.add[gW].Clr.v=E.M.lW(E.uv(j.Gp));y.G$.xk(bZ,t.add[gW],kk);
if(aq==null)ee=fV.get([6,48,0,kk]);if(gW=="PtFl"){var aY=t.add[gW].Ptrn.v,dF=ge.f$(aY,j.V8);if(dF==null)dF=ge.f$(aY,W.add.Patt);
aY.Idnt.v=dF.id;W.qn(dF)}t.yb(W)}var j0=y.G$.Ro(W,ee+" ");t.nz(ee+" "+(j0+1));if(e$)t.nz(e$);var e2=W.g.length==0?W.C.length-1:W.g[W.g.length-1],eb=W.C[e2];
if(I==h.YS&&eb.oK()&&eb.rect.VY()){dG=!0;t.nz(eb.getName());de=e2}else{de=e2+(I==h.tp&&A&&!l?0:1);if(eb&&eb.add.lsct==ef.fz)de--}if(w.awQ)de=Math.max(0,de-1);
var eX=W.C.slice(0);if(I==h.cP){var dw=eX[W.g[0]]=eX[W.g[0]].clone(),hE=W.J.channel.slice(0);E.Ba(hE);
E.AG(hE,W.J.rect,dw.buffer,dw.rect)}eX.splice(de,dG?1:0,t);var b0=[5,2];if(I==h.tp)b0=[6,13];if(I==h.yH)b0=[6,1];
if(I==h.YS){b0=[6,48,1];var aq=w.E3.Usng.v.Shp;if(aq){var bo={Rctn:[10,32],Ln:[10,35],Elps:[10,33],Plgn:[12,93,0],customShape:[10,31]}[aq.v.classID];
if(bo)b0=bo}}if(hQ){b0=[6,49,I==h.Nk?0:1]}if(hQ||I==h.YS||I==h.nS||I==h.yH)if(W.J)aX=[W.J,null];var g=new go(b0,this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[de],px:aX};W.kK(g);this.Fd(g.data,W);if(I==h.YS&&aq==null&&kk!=0||I==h.yH){var _=new ed(b.E.L);
_.data={d:b.c._y,jW:et.ip.$z};n.S(_)}}if(I==h.Si){var t=W.QI(),ee=fV.get([0,4]),j0=y.G$.Ro(W,ee+" ");
t.nz(ee+" "+(j0+1));t.Bx="pass";t.add.lsct=ef.fz;t.FK=24;if(w.np)t.nz(w.np);if(w.ve!=null)t.add.lclr=w.ve;
var bY=W.hG(),e2=U,de=e2+(A?0:1),eX=W.C.slice(0);eX.splice(de,0,bY,t);var g=new go([6,20],this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[de+1]};
W.kK(g);this.Fd(g.data,W)}if(I==h.nP||I==h.iv){var jm=I==h.nP?w.source:W.g[0],aE,aJ,aS=W.g.indexOf(jm)!=-1,dz=m|w.axD,iM,h6=null;
if(aS)iM=W.qu();else iM=W.rZ(jm);iM.sort(function(g,ji){return g-ji});if(I==h.nP){aE=w.target;aJ=w.TJ>.5}else if(w.target!=null){aE=Math.min(w.target,W.C.length-1);
aJ=w.target<W.C.length;W.gL=!0}else{var gV=w.vK;aJ=gV>1;if(gV==0){aE=W.C.length-1}if(gV==1){aE=iM[iM.length-1]+1;
var C=W.rZ(aE);if(C.indexOf(jm)==-1)aE+=C.length-1}if(gV==2){aE=iM[0]-1;var C=W.rZ(aE);if(C.indexOf(jm)==-1)aE-=C.length-1}if(gV==3){aE=0;
if(W.C[0].add.lnsr=="bgnd")aE++}if(aE<0||aE>W.C.length-1)return;W.gL=!0}if(iM.indexOf(aE)!=-1&&!dz)return;
var cL=y.G$._c(W,iM,aE,aJ,dz?W.Jr(aS?null:jm):null,I==h.nP&&w.TJ>.8),ka=cL.pop(),cB=cL.pop(),eX=cL.pop(),bS=W.g;
W.g=[jm];var hA=W.H2();W.g=[aE];var k7=W.H2();if(k7==aE&&!aJ)k7=-1;W.g=bS;if(jm==hA){}else if(hA!=k7){var h6=new ec(0,0);
if(hA!=-1){var iU=W.C[hA].yP();h6.x-=iU.x;h6.y-=iU.y}if(k7!=-1){var iU=W.C[k7].yP();h6.x+=iU.x;h6.y+=iU.y}}var g=new go(dz?[6,0]:[6,35],this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:cB,dx:h6};W.kK(g);this.Fd(g.data,W);var jG={classID:"move",null:cq.Pz("Lyr",!0),T:{t:"obj ",v:[{t:"indx",v:{classID:"Lyr",val:ka+(aJ?0:1)}}]},Adjs:{t:"bool",v:!1},Vrsn:{t:"long",v:5},Dplc:{t:"long",v:dz}};
this.track({hZ:"move",E3:jG})}if(I==h.Vp){if(w.iZ){if(M==null||!M.ue())return;var H=W.root.fs(U),dd=W.C.indexOf(H.ap3),eX=W.C.slice(0);
eX.splice(U,1);eX.splice(dd,1);var cB=[];for(var L=dd;L<U-1;L++)cB.push(L);var g=new go("Ungroup Layers",this);
g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:cB};W.kK(g);this.Fd(g.data,W)}else{var t=W.QI(),dY=fV.get([0,4])+" ";
t.nz(dY+(y.G$.Ro(W,dY)+1));t.Bx="pass";if(w.np)t.nz(w.np);if(w.ve!=null)t.add.lclr=w.ve;t.add.lsct=W.g.length==1?ef.fz:ef.Se;
t.FK=24;var bY=W.hG(),iM=W.qu();if(iM.length==0)return;iM.sort(function(g,ji){return g-ji});var eX=[];
for(var L=0;L<W.C.length;L++)if(iM.indexOf(L)==-1)eX.push(W.C[L]);var e2=W.g[W.g.length-1]-iM.length;
eX.splice(e2+1,0,bY);for(var L=0;L<iM.length;L++)eX.splice(e2+2+L,0,W.C[iM[L]]);eX.splice(e2+2+iM.length,0,t);
var g=new go([6,9],this);g.data={d:h.ZM,VQ:W.C.slice(0),_B:eX,Sz:W.g.slice(0),zu:[eX.indexOf(t)]};W.kK(g);
this.Fd(g.data,W);var O={hZ:"make",Q9:!0};O.E3={classID:"Mk",null:cq.Pz("layerSection"),From:cq.Pz("Lyr",!0),Usng:{t:"Objc",v:{classID:"layerSection",Nm:{t:"TEXT",v:t.getName()}}}};
this.track(O)}}if(I==h.amd){if(W.g.length!=1)return;var c=W.g[0],ix=m;if(W.C[c]._N()==null&&!D.U(aK.CQ)){I=h.uV;
w.IZ=W.J?!ix?"RvlS":"HdSl":!ix?"RvlA":"HdAl"}else{I=h.PE;w.a2J=!0}}if(I==h.uV){if(W.g.length!=1)return;
var c=W.g[0],t=W.C[c];if(t.add.vmsk&&t.z==null)t.yb(W);var bN=t._N();if(bN==null||w.acm){var g=new go([6,21],this),jh=new h.ac,ap=w.IZ,fq=ap=="RvlS"||ap=="HdSl";
if(ap=="RvlS"||ap=="HdAl"||ap=="Trns")jh.color=0;if(fq){jh.channel=W.J.channel.slice(0);jh.rect=W.J.rect.clone();
if(ap=="HdSl")E.Ba(jh.channel)}if(ap=="Trns"){jh.rect=t.rect.clone();jh.channel=E.Q(t.rect.O());E.hN(t.buffer,jh.channel,3)}g.data={d:h.Xw,Xi:[c,bN,jh],px:fq?[W.J,null]:null};
W.kK(g);this.Fd(g.data,W);W.C[c].eL=1;this.track({hZ:"make",E3:{__name:"Make",classID:"Mk",Nw:{t:"type",v:{classID:"Chnl"}},At:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"Msk"}}]},Usng:{t:"enum",v:{UsrM:ap}}}})}}else if(I==h.a5T){var iJ=W.C[w.src],fL=W.C[w.b2],g=new go([6,21],this),fx=iJ._N(),fc=fL._N(),fn=[w.src,fx,null,w.b2,fc,fx];
if(m||l){var bH=fx.clone();if(m)fn=[w.b2,fc,bH];else fn[5]=bH;if(l){E.Ba(bH.channel);bH.color=255-bH.color}}g.data={d:h.Xw,Xi:fn};
W.kK(g);this.Fd(g.data,W)}if(I==h.kR){if(W.g.length!=1)return;var c=U,aV=W.C[c]._N();if(aV!=null){var g=new go([6,22],this);
g.data={d:h.Xw,Xi:[U,aV,null]};W.kK(g);this.Fd(g.data,W)}}if(I==h.Q_){var ii=W.C.slice(0),dh=M.clone(),au=dh._N();
E.AG(au.Ln(dh.rect),dh.rect,dh.buffer,dh.rect);y.G$.xZ(W,dh);dh.ky();W.C[W.g[0]]=dh;var g=new go([5,8],this);
g.data={d:h.ZM,VQ:ii,_B:W.C.slice(),Sz:W.g.slice(0),zu:W.g.slice(0)};W.kK(g);this.Fd(g.data,W)}if(I==h.lc){if(W.g.length!=1)return;
var c=W.g[0];if(W.C[c].NP(W).z==null){var g=new go([6,45],this);g.data={d:I,j:c,z:new h.ac};W.kK(g);
this.Fd(g.data,W)}}if(I==h.Wu){if(W.g.length!=1)return;var c=W.g[0];if(W.C[c].NP(W).z!=null){var g=new go([6,46],this);
g.data={d:I,j:c,z:W.C[c].NP(W).z};W.kK(g);this.Fd(g.data,W)}}if(I==h.fE){if(w.src==null&&W.g.length!=1)return;
if(w.src!=null)U=w.src;if(W.C[U].YC()){var g=new go([6,47],this),jS=JSON.stringify(W.C[U].add.SoLd),ie=JSON.parse(jS);
delete ie.filterFX;g.data={d:h.U7,ek:[{Ay:U,Bp:[jS,JSON.stringify(ie)],Nq:[W.C[U].NP(W),null]}]};W.kK(g);
this.Fd(g.data,W)}}if(I==h.PE){if(W.g.length!=1)return;if(M.add.vmsk==null){var g=new go([6,23],this),f5=W.OV(),fs=f5[1],f5=f5[0],jh,gU;
if(w.a2J&&fs.length!=0){var gk=f5[fs[0]].add;jh=gk.vmsk.clone();gU=gk.vogk}else{jh=new h.Rd;gU=[];jh.i[1].all=w.a0P?0:1}g.data={d:I,j:U,cd:!0,z:jh,X:JSON.stringify(gU),QO:null};
if(M.I9()){g.data.QO=JSON.stringify(at.QO.default)}W.kK(g);this.Fd(g.data,W)}}if(I==h.AP){var iJ=W.C[w.src],fL=W.C[w.b2];
if(fL.add.vmsk)return;var g=new go([6,23],this),hW=iJ.add.vmsk;g.data={j:w.b2,cd:iJ.na,z:hW.clone(),X:JSON.stringify(iJ.add.vogk),QO:iJ.add.vstk?JSON.stringify(iJ.add.vstk):null};
if(m){g.data.d=h.PE}else{g.data.d=I;g.data.src=w.src;g.data.b2=w.b2}W.kK(g);this.Fd(g.data,W)}if(I==h.qc||I==h.lB){if(W.g.length!=1)return;
var t=W.C[U],hW=t.add.vmsk;if(hW!=null){var cJ=I==h.lB,g=new go(cJ?[6,8]:[6,24],this);g.data={d:h.qc,j:U,cd:t.na,z:hW,X:JSON.stringify(t.add.vogk),QO:t.add.vstk?JSON.stringify(t.add.vstk):null};
if(cJ){g.data.pv=hW._N(t.add.vstk)}W.kK(g);this.Fd(g.data,W)}}if(I==h.NU){var g=new go("Metadata",this);
g.data={d:I,qm:JSON.stringify(W.Zp),Hb:JSON.stringify(w.Hb)};W.kK(g);this.Fd(g.data,W)}if(I==h.w2){var gB=w.b2?w.b2:W,eN=gB.name,e$=w.Z+".psd";
if(eN==e$)return;var g=new go([6,37],this);g.data={d:I,a1A:eN,np:e$};if(w.a4K!=!0)gB.kK(g);this.Fd(g.data,gB)}if(I==h.rC&&w.vK.endsWith("makeframes")){var f9=[],iQ=w.vK.startsWith("make");
for(var L=0;L<W.g.length;L++){var Y=W.g[L],t=W.C[Y],hw=t.getName(),jp=hw.startsWith("_a_");if(iQ==jp||t.add.lsct==ef.Cq)continue;
var cw=iQ?"_a_"+hw:hw.slice(3);f9.push([Y,hw,cw,t.add.lnsr,null])}var g=new go([6,37],this);g.data={d:h.Bl,AH:f9};
W.kK(g);this.Fd(g.data,W)}if(I==h.Bl){var eN=M.getName(),e$=w.name.substring(0,255);if(eN==e$)return;
var g=new go([6,37],this);g.data={d:I,AH:[[U,eN,e$,M.add.lnsr,null]]};W.kK(g);this.Fd(g.data,W);this.track(cq.Jf("Nm",{t:"TEXT",v:e$}))}if(I==h.HT){var am=W.qu(),cn=[],gR=[];
for(var L=0;L<am.length;L++){cn.push(W.C[am[L]].add.lclr);gR.push(w.ayZ)}var g=new go([6,38],this);g.data={d:I,C:am,aa7:cn,ve:gR};
W.kK(g);this.Fd(g.data,W)}if(I==h.vE){var g=W.history[W.QQ];if(g!=null&&g.G==this&&g.data.d==I&&g.data.j==w.hB&&g.data.qY.le==w.KP.le)g.data.qY=w.KP;
else{g=new go("Mask Density / Feather",this);g.data={d:I,j:w.hB,Z1:W.C[w.hB].c3(w.KP.le),qY:w.KP};W.kK(g)}this.Fd(g.data,W)}if(I==h.Q2){var c$=JSON.stringify(w.Z),eL=JSON.parse(c$),g=W.history[W.QQ];
if(g!=null&&g.G==this&&g.data.d==I&&g.data.Mr==w.Mr&&g.data.G1.join(",")==w.G1.join(",")){for(var L=0;
L<w.G1.length;L++)g.data.SC[L]=eL;if(g.data.E3&&eL.oq!=0)y.G$.xk(eL.S8,g.data.E3.T.v,eL.oq-1)}else{g=new go([11,6],this);
g.data={d:I,G1:w.G1,Mr:w.Mr,ae2:[],SC:[]};var fg=!1;for(var L=0;L<w.G1.length;L++){var Y=w.G1[L],t=W.C[Y],hv=w.Mr?y.rK.wj(W,Y):JSON.parse(JSON.stringify(t.add.vstk));
g.data.ae2.push(hv);g.data.SC.push(eL);if(JSON.stringify(hv)!=c$)fg=!0}if(!fg)return;W.kK(g);if(w.Mr&&eL.oq>0){var jG=g.data.E3={classID:"setd",null:cq.Pz("contentLayer",!0),T:{t:"Objc",v:{}}};
y.G$.xk(eL.S8,jG.T.v,eL.oq-1);this.track({hZ:"set",E3:jG})}}if(w.Mr&&eL.oq==3)W.qn(ge.f$(eL.S8.Ptrn.v,j.V8));
if(!w.Mr){var i9=eL.strokeStyleContent.v;if(i9.classID==at.QO.W_[2])W.qn(ge.f$(i9.Ptrn.v,j.V8))}this.Fd(g.data,W)}};
y.G$._c=function(w,n,W,D,j,I){var U=w.C[W],M=[];if(j)M=w.C.slice(0);else for(var L=0;L<w.C.length;L++)if(n.indexOf(L)==-1)M.push(w.C[L]);
var m=M.indexOf(U);if(I&&U.ue()&&U.add.lsct==ef.Se)m-=w.rZ(W).length-1;var l=[];for(var L=0;L<n.length;
L++){var A=m+(D?0:1)+L,g=j?j[L]:w.C[n[L]];M.splice(A,0,g);l.push(A)}return[M,l,m]};y.G$.xk=function(w,n,W){var D=[at.Oa,at.Ki,at.v7][W];
if(n.classID==null)n.classID=["solidColorLayer","gradientLayer","patternLayer"][W];for(var L=0;L<D.length;
L++)if(w[D[L]])n[D[L]]=JSON.parse(JSON.stringify(w[D[L]]))};y.G$.a2E=function(w){var n=new h.ac;if(w.J!=null){n.color=0;
n.channel=w.J.channel.slice(0);n.rect=w.J.rect.clone()}return n};y.G$.mv=function(w,n,W,D,j){var I=D.m/W.m,U=D.n/W.n,M=D.m/2,m=D.n/2,l=E.p.Wx(D).w;
for(var L=0;L<w.C.length;L++){var A=w.C[L],g=A.add.SoLd;if(g==null||g.Idnt.v!=n)continue;if(I!=1||U!=1){var k=y.wR.Aa(g.nonAffineTransform),$=E.K.kN(k,D),C=new eh;
C.translate(-M,-m);C.scale(I,U);C.translate(M,m);var f=E.K.y9($,E.K.yT(C)),z=l.slice(0);E.K.D(f,z);g.Trnf=y.wR.Hh(z);
g.nonAffineTransform=y.wR.Hh(z);if(E.XB.pi(g.warp.v)){var s=g.warp.v.bounds.v;s.Rght.v.val=D.m;s.Btom.v.val=D.n}}A.vr(w,null,j)}w.l()};
y.G$.ajz=function(w,n,W){n.color=255-n.color;E.Ba(n.channel);n.eP=!0;w.yb(W);W.l()};y.G$.prototype.ZE=function(w,n){var W=w.d,D=n.C[w.j];
n.rR=!0;if(W==h.v4){n.add.lnk2.splice(n.add.lnk2.indexOf(w.QF),1,w.kV);y.G$.mv(n,w.id,w.QF.PO[1],w.kV.PO[1])}if(W==h.vZ){D.add.SoLd.Impr.v.classID=w.Z1;
D.vr(n)}if(W==h.jC){var j=JSON.parse(w.G1);for(var L=0;L<j.length;L++)n.C[j[L]].Bx=w.hM[L];n.l()}if(W==h.JM){var j=JSON.parse(w.G1);
for(var L=0;L<j.length;L++)n.C[j[L]].opacity=w.hM[L];n.l()}if(W==h.ge){var j=JSON.parse(w.G1);for(var L=0;
L<j.length;L++)if(n.C[j[L]].add.lsct!=ef.Cq)n.C[j[L]].add.lspf=w.hM[L]}if(W==h.Wm){var I=w.qp,U=w.ar9;
delete D.add[I[0]];if(U[0]!="----")D.add[U[0]]=U[1]}if(W==h.p6){D.add.iOpa=w.hM;n.l()}if(W==h.Ll){for(var L=0;
L<w.G1.length;L++){var M=n.C[w.G1[L]];M.gb(!M.I4())}n.l()}if(W==h.Gw){var m=D._N();m.isEnabled=!m.isEnabled;
D.yb(n);n.l()}if(W==h.cV){var m=D.NP(n).z;m.isEnabled=!m.isEnabled;D.l();n.l()}if(W==h.Uo){var m=D.add.vmsk;
m.isEnabled=!m.isEnabled;if(!m.isEnabled){if(D.pv){D.z=D.pv;D.pv=null}else D.z=null}else if(D.z){D.pv=D.z;
D.z=null}D.yb(n);n.l()}if(W==h.Yt){D.QY=!D.QY;n.l()}if(W==h.Aj){D.add.lmfx.masterFXSwitch.v=!D.add.lmfx.masterFXSwitch.v;
D.US.Wq=!0;n.l()}if(W==h.lf){D.add.SoLd.filterFX.v.enab.v=!D.add.SoLd.filterFX.v.enab.v;D.AK(n);n.l()}if(W==h.oO){var l=w.index,A=D.add.lmfx[at.Pa[l[0]]].v[l[1]].v;
A.enab.v=!A.enab.v;D.US.Wq=!0;n.l()}if(W==h.eI){var g=n.C[w.tr],k=n.C[w.k1],$=w.atF,C=w.abE;if($=="")delete g.add.lmfx;
else g.add.lmfx=JSON.parse($);if(C=="")delete k.add.lmfx;else k.add.lmfx=JSON.parse(C);g.US.Wq=!0;k.US.Wq=!0;
n.l()}if(W==h.GG){var f=D.add.SoLd.filterFX.v.filterFXList.v[w.index].v;f.enab.v=!f.enab.v;D.AK(n);n.l()}if(W==h.aml){D.add.SoLd.filterFX.v=JSON.parse(JSON.stringify(w.aeb));
D.AK(n);n.l()}if(W==h._9){var m=D._N();m.gm=!m.gm}if(W==h._x){var m=D.add.vmsk;m.gm=!m.gm}if(W==h.ws){var z=JSON.parse(w.ait);
n.ol=z[0];n.Ei=z[1]}if(W==h.Di){var z=w.tO;for(var L=0;L<z.length;L+=2){var s=z[L],M=s>=0?n.C[s]:n.Oi[-1-s];
M.add.vogk=JSON.parse(z[L+1]);E.X.A9(M.add.vogk,M.add.vmsk);if(s>=0)M.yb(n)}n.l()}if(W==h.nL){D.add.artb=JSON.parse(w.a11);
n.l();y.QJ.y3(n,w)}if(W==h.QE){n.J=w.Py;n.yo=w.tO.slice(0);n.v9=w.DD.slice(0);n.RP=n.tL=!0}if(W==h.K9){D.lj=!D.lj}if(W==h.qf){var O=w.afF;
for(var L=0;L<O.length;L++)n.C[L].Ux=O[L]}if(W==h.ZM){if(w.dx)y.mU.Gt(n,n.g,null,-w.dx.x,-w.dx.y);if(w.Sz)n.g=w.Sz;
if(w.px)n.J=w.px[0];n.zS=null;n.l();n.Gd(w.VQ);y.QJ.y3(n,w);if(w.N2)n.Pu(w.N2[0])}if(W==h.Xw){for(var L=0;
L<w.Xi.length;L+=3)y.G$.xZ(n,n.C[w.Xi[L]],w.Xi[L+1]);if(w.px){var a=w.px[0];if(a==null)delete n.J;else n.J=a}}if(W==h.lc){D.NP(n).z=null;
D.l();n.l()}if(W==h.Wu){D.NP(n).z=w.z;D.l();n.l()}if(W==h.U7){y.G$.aiP(n,w.ek,0)}if(W==h.PE){y.G$.sD(n,D,!0)}if(W==h.AP){y.G$.sD(n,n.C[w.b2],w.z.isEnabled);
y.G$.XX(n,n.C[w.src],w)}if(W==h.qc){if(w.pv)y.G$.xZ(n,D,null);y.G$.XX(n,D,w)}if(W==h.NU){n.Zp=JSON.parse(w.qm)}if(W==h.w2){n.name=w.a1A}if(W==h.Bl){for(var L=0;
L<w.AH.length;L++){var X=w.AH[L],M=n.C[X[0]];M.nz(X[1]);if(X[3])M.add.lnsr=X[3];else delete M.add.lnsr}}if(W==h.HT){for(var L=0;
L<w.C.length;L++)n.C[w.C[L]].add.lclr=w.aa7[L]}if(W==h.Q2){var P=w.ae2;for(var L=0;L<w.G1.length;L++){var M=n.C[w.G1[L]],Z=P[L];
if(!w.Mr)M.add.vstk=JSON.parse(JSON.stringify(Z));else y.rK.KG(M,JSON.parse(JSON.stringify(Z)));M.sO(n)}n.l()}if(W==h.vE){D.avi(w.Z1);
D.yb(n);n.l()}n.tL=!0};y.G$.prototype.Fd=function(w,n){var W=w.d,D=n.C[w.j];n.rR=!0;if(W==h.v4){n.add.lnk2.splice(n.add.lnk2.indexOf(w.kV),1,w.QF);
y.G$.mv(n,w.id,w.kV.PO[1],w.QF.PO[1])}if(W==h.vZ){D.add.SoLd.Impr.v.classID=w.qY;D.vr(n)}if(W==h.jC){var j=JSON.parse(w.G1);
for(var L=0;L<j.length;L++)n.C[j[L]].Bx=w.qY;n.l()}if(W==h.JM){var j=JSON.parse(w.G1);for(var L=0;L<j.length;
L++)n.C[j[L]].opacity=w.qY;n.l()}if(W==h.ge){var j=JSON.parse(w.G1);for(var L=0;L<j.length;L++)if(n.C[j[L]].add.lsct!=ef.Cq)n.C[j[L]].add.lspf=w.qY[L]}if(W==h.Wm){var I=w.ar9,U=w.qp;
delete D.add[I[0]];if(U[0]!="----")D.add[U[0]]=U[1]}if(W==h.p6){D.add.iOpa=w.qY;n.l()}if(W==h.Ll){for(var L=0;
L<w.G1.length;L++){var M=n.C[w.G1[L]];M.gb(!M.I4())}n.l()}if(W==h.Gw){var m=D._N();m.isEnabled=!m.isEnabled;
D.yb(n);n.l()}if(W==h.cV){var m=D.NP(n).z;m.isEnabled=!m.isEnabled;D.l();n.l()}if(W==h.Uo){var m=D.add.vmsk;
m.isEnabled=!m.isEnabled;if(!m.isEnabled){if(D.pv){D.z=D.pv;D.pv=null}else D.z=null}else if(D.z){D.pv=D.z;
D.z=null}D.yb(n);n.l()}if(W==h.Yt){D.QY=!D.QY;n.l()}if(W==h.Aj){D.add.lmfx.masterFXSwitch.v=!D.add.lmfx.masterFXSwitch.v;
D.US.Wq=!0;n.l()}if(W==h.lf){D.add.SoLd.filterFX.v.enab.v=!D.add.SoLd.filterFX.v.enab.v;D.AK(n);n.l()}if(W==h.oO){var l=w.index,A=D.add.lmfx[at.Pa[l[0]]].v[l[1]].v;
A.enab.v=!A.enab.v;D.US.Wq=!0;n.l()}if(W==h.eI){var g=n.C[w.tr],k=n.C[w.k1],$=w.a0p,C=w.avl;if($=="")delete g.add.lmfx;
else g.add.lmfx=JSON.parse($);if(C=="")delete k.add.lmfx;else k.add.lmfx=JSON.parse(C);g.US.Wq=!0;k.US.Wq=!0;
n.l()}if(W==h.GG){var f=D.add.SoLd.filterFX.v.filterFXList.v[w.index].v;f.enab.v=!f.enab.v;D.AK(n);n.l()}if(W==h.aml){D.add.SoLd.filterFX.v=JSON.parse(JSON.stringify(w.a9t));
D.AK(n);n.l()}if(W==h._9){var m=D._N();m.gm=!m.gm}if(W==h._x){var m=D.add.vmsk;m.gm=!m.gm}if(W==h.ws){var z=JSON.parse(w.azy);
n.ol=z[0];n.Ei=z[1]}if(W==h.Di){var z=w.EK;for(var L=0;L<z.length;L+=2){var s=z[L],M=s>=0?n.C[s]:n.Oi[-1-s];
M.add.vogk=JSON.parse(z[L+1]);E.X.A9(M.add.vogk,M.add.vmsk);if(s>=0)M.yb(n)}n.l()}if(W==h.nL){D.add.artb=JSON.parse(w.oL);
n.l();y.QJ.$v(n,w)}if(W==h.QE){n.J=w.TY;n.yo=w.EK.slice(0);n.v9=w.Ib.slice(0);n.RP=n.tL=!0}if(W==h.K9){D.lj=!D.lj}if(W==h.qf){var O=w.alz;
for(var L=0;L<O.length;L++)n.C[L].Ux=O[L]}if(W==h.ZM){n.a6X();var a=w._B,X=0,P;for(var L=0;L<a.length;
L++){var M=a[L],Z=M.add.lsct;if(Z==ef.Cq)X++;else if(Z==ef.fz||Z==ef.Se)X--;if(M.add.artb&&X!=0)P="Artboards can not be inside folders."}if(P){n.history.pop();
n.QQ--;alert(P);return}y.QJ.$v(n,w);if(w.zu)n.g=w.zu;if(w.px)n.J=w.px[1];n.zS=null;n.l();n.Gd(w._B);
if(w.dx)y.mU.Gt(n,n.g,null,w.dx.x,w.dx.y);if(w.N2)n.Pu(w.N2[1])}if(W==h.Xw){for(var L=0;L<w.Xi.length;
L+=3)y.G$.xZ(n,n.C[w.Xi[L]],w.Xi[L+2]);if(w.px){var Y=w.px[1];if(Y==null)delete n.J;else n.J=Y}}if(W==h.lc){D.NP(n).z=w.z;
D.eL=0;D.l();n.l()}if(W==h.Wu){D.NP(n).z=null;D.eL=0;D.l();n.l()}if(W==h.U7){y.G$.aiP(n,w.ek,1)}if(W==h.PE){y.G$.XX(n,D,w)}if(W==h.AP){y.G$.sD(n,n.C[w.src],w.z.isEnabled);
y.G$.XX(n,n.C[w.b2],w)}if(W==h.qc){y.G$.sD(n,D,w.z.isEnabled);if(w.pv)y.G$.xZ(n,D,w.pv)}if(W==h.NU){n.Zp=JSON.parse(w.Hb)}if(W==h.w2){n.name=w.np}if(W==h.Bl){for(var L=0;
L<w.AH.length;L++){var K=w.AH[L],M=n.C[K[0]];M.nz(K[2]);if(K[4])M.add.lnsr=K[4];else delete M.add.lnsr}}if(W==h.HT){for(var L=0;
L<w.C.length;L++)n.C[w.C[L]].add.lclr=w.ve[L]}if(W==h.Q2){var S=w.SC;for(var L=0;L<w.G1.length;L++){var M=n.C[w.G1[L]],G=S[L];
if(!w.Mr)M.add.vstk=JSON.parse(JSON.stringify(G));else y.rK.KG(M,JSON.parse(JSON.stringify(G)));M.sO(n)}n.l()}if(W==h.vE){D.avi(w.qY);
D.yb(n);n.l()}n.tL=!0};y.G$.Ro=function(w,n){var W=0;for(var L=0;L<w.C.length;L++){var D=w.C[L].getName();
if(D.startsWith(n)){var j=D.slice(n.length).trim(),I=parseInt(j);if(!isNaN(I)&&I+""==j&&I>W)W=I}}return W};
y.G$.aiP=function(w,n,W){for(var L=0;L<n.length;L++){var D=n[L],j=w.C[D.Ay];if(D.Bp){j.add.SoLd=JSON.parse(D.Bp[W])}if(D.Nq){if(D.Nq[1-W]!=null)w._7(D.Nq[1-W]);
if(D.Nq[W]!=null)w.V$(D.Nq[W]);else j.eL=0}j.vr(w)}};y.G$.a5H=function(w,n){var W=w.HJ,D=w.rect.clone();
if(W!=null&&(W.x!=n.m||W.y!=n.n)){D.x=Math.floor((n.m-D.m)/2);D.y=Math.floor((n.n-D.n)/2)}else if(W==null){var j=new iB(0,0,n.m,n.n),I=n.H2();
if(I!=-1)j=n.C[I].yP();D.x+=j.x;D.y+=j.y}return D};y.G$.a5S=function(w,n){if(n.pv)n.pv=null;else n.z=null;
n.yb(w);w.l();n.eL=0};y.G$.xZ=function(w,n,W){var D=n._N();if(D==null&&W==null)return;if(D)y.G$.a5S(w,n);
if(W==null)return;if(n.z)n.pv=W;else n.z=W;n.yb(w);w.l()};y.G$.sD=function(w,n,W){if(n.pv&&W){n.z=n.pv;
n.pv=null}else if(n.z&&W){n.z=null}delete n.add.vogk;delete n.add.vstk;delete n.add.vmsk;n.yb(w);n.na=!1;
w.zS=[];w.l()};y.G$.XX=function(w,n,W){n.add.vogk=JSON.parse(W.X);if(W.QO)n.add.vstk=JSON.parse(W.QO);
else delete n.add.vstk;n.add.vmsk=W.z.clone();if(n.z&&n.add.vmsk.isEnabled)n.pv=n.z;n.yb(w);n.na=W.cd;
w.zS=[w.C.indexOf(n)];w.rs=[];w.l()};y.Su=function(){y.qw.call(this,"Layer Styles",y.EA);this.dC=null;
this.FE=null;this.ys=null;this.UR=[];this.qx=null};y.Su.prototype=new y.qw;y.Su.prototype.Al=function(w,n,W,D,j){var I=w.j;
if(I==null)I=W.g[0];var U=W.C[I],M=w.p_;if(this.dC==null){this.ys=y.Su.qB(W,U);this.dC=JSON.stringify(this.ys);
if(U.add.lmfx)this.FE=JSON.stringify(U.add.lmfx)}if(U.add.lmfx==null){U.add.lmfx=JSON.parse(at.default);
for(var L=0;L<at.order.length;L++)U.add.lmfx[at.Pa[L]]={t:"VlLs",v:[]}}if(w.d=="scaleeffects"){if(w.Z=="confirm"||w.Z=="cancel"){this.Al({d:w.Z},n,W,D,j);
return}U.add.lmfx=JSON.parse(this.FE);ge.Sq(U.add.lmfx,w.Z/100)}else if(w.d=="changeprop"){var m=null;
if(M!=0){var l=this.UR[M[0]];if(l==null)l=at.UR[M[0]];l=JSON.parse(l);var A=U.add.lmfx[at.Pa[M[0]]].v;
if(A[M[1]]==null)A[M[1]]={t:"Objc",v:l};m=A[M[1]].v;for(var g in l)if(m[g]==null)m[g]=l[g]}if(w.d=="changeprop"){if(M==0){this.ys[w.c7].v=w.Z;
y.Su.aq(W,U,this.ys)}else if(w.c7=="lagl"){if(m.uglg&&m.uglg.v){W.UB(w.Z.val);this.ys.gagl.v.val=W.d4()}else m[w.c7].v=w.Z}else if(w.c7=="Lald"){if(m.uglg.v){W.GT(w.Z.val);
this.ys.ai5=W.wS()}else m[w.c7].v=w.Z}else if((M[0]==3||M[0]==8)&&(w.c7=="Clr"||w.c7=="Grad")){if(w.c7=="Clr"){m.Clr={t:"Objc",v:w.Z};
delete m.Grad}if(w.c7=="Grad"){m.Grad={t:"Objc",v:w.Z};delete m.Clr}}else{m[w.c7].v=w.Z}if(M!=0)this.UR[M[0]]=JSON.stringify(m)}if(M!=0)if(m.Ptrn)W.qn(ge.f$(m.Ptrn.v,j.V8))}else if(w.d=="setstl"){var k=w.Z.Lefx;
if(k)ge.axf(k,W,j.V8);ge.acF(w.Z,U,null,W);this.ys=y.Su.qB(W,U)}else if(w.d=="st_dupsingle"){var $=U.add.lmfx[at.Pa[w.RL[0]]].v;
if($[w.RL[1]]==null)return;var C=JSON.parse(JSON.stringify($[w.RL[1]]));$.splice(w.RL[1],0,C)}else if(w.d=="st_movsingle"){var f=w.RL[1],$=U.add.lmfx[at.Pa[w.RL[0]]].v;
if($[w.RL[1]]==null)return;var z=Math.max(0,Math.min($.length-1,f+w.a0i)),s=$[z];$[z]=$[f];$[f]=s}else if(w.d=="cancel"){if(this.FE==null)delete U.add.lmfx;
else U.add.lmfx=JSON.parse(this.FE);y.Su.aq(W,U,JSON.parse(this.dC));this.dC=null;this.FE=null}else if(w.d=="confirm"){var O=JSON.stringify(U.add.lmfx),a=new go([11,6],this);
a.data={C:[I],A0:[this.FE],iy:[O],jb:[this.dC],pK:[JSON.stringify(this.ys)]};W.kK(a);this.dC=null;this.FE=null;
if(O!=null){var X=JSON.parse(O);dR.BA(X);X.classID="Lefx";delete X.masterFXSwitch;var P=new ed(b.E.W1);
P.HH=!0;P.data={hZ:"set",Q9:!0};var Z=cq.Pz("Lyr",!0);Z.v.splice(0,0,{t:"prop",v:{classID:"Prpr",keyID:"Lefx"}});
P.data.E3={__name:"Set",classID:"setd",null:Z,T:{t:"Objc",v:X}};n.S(P)}}else if(w.d=="st_copy"){this.qx=[this.dC,this.FE];
this.dC=null;this.FE=null}else if(w.d=="st_paste"||w.d=="st_clear"){if(w.d=="st_paste"&&this.qx==null)return;
var Y=w.j!=null?[w.j]:W.g.slice(0),K=[],S=[],G=[],V=[];for(var L=0;L<Y.length;L++){var U=W.C[Y[L]],T=y.Su.qB(W,U);
K.push(U.add.lmfx?JSON.stringify(U.add.lmfx):null);G.push(JSON.stringify(T));if(w.d=="st_paste"){S.push(this.qx[1]);
V.push(this.qx[0])}else{S.push(null);T.lrMd.v=0;T.Opct.v.val=100;T.iOpa.v.val=100;T.blIf={v:[]};for(var R=0;
R<10;R++)T.blIf.v.push(0,0,255,255);V.push(JSON.stringify(T))}}var a=new go([11,6],this);a.data={C:Y,A0:K,iy:S,jb:G,pK:V};
this.Fd(a.data,W);W.kK(a);this.dC=null;this.FE=null}else{var x=this.ys,X=null;if(w.d=="st_delsingle"){X=JSON.parse(this.FE);
X[at.Pa[w.RL[0]]].v.splice(w.RL[1],1);X=JSON.stringify(X)}if(X==null)delete U.add.lmfx;else U.add.lmfx=JSON.parse(X);
if(x!=null)y.Su.aq(W,U,x);var a=new go([11,6],this);a.data={C:[w.j],A0:[this.FE],iy:[X],jb:[this.dC],pK:[JSON.stringify(x)]};
W.kK(a);this.dC=null;this.FE=null}U.US.Wq=!0;W.rR=!0;W.l()};y.Su.qB=function(w,n){if(n.add.iOpa==null)n.add.iOpa=255;
if(n.add.brst==null)n.add.brst=[1,1,1];var W=n.ue()?["pass"].concat(dD.mS):dD.mS;return{lrMd:{v:W.indexOf(n.Bx)},Opct:{v:{type:"#Prc",val:Math.round(n.opacity*100/255)},t:"UntF"},iOpa:{v:{type:"#Prc",val:Math.round(n.add.iOpa*100/255)},t:"UntF"},blIf:{v:n.kQ.slice(0)},brst:{v:n.add.brst},gagl:{t:"UntF",v:{type:"#Ang",val:w.d4()}},ai5:w.wS(),ue:n.ue()}};
y.Su.aq=function(w,n,W){var D=n.ue()?["pass"].concat(dD.mS):dD.mS;n.Bx=D[W.lrMd.v];n.opacity=Math.round(W.Opct.v.val*255/100);
n.add.iOpa=Math.round(W.iOpa.v.val*255/100);n.kQ=W.blIf.v.slice(0);n.add.brst=W.brst.v.slice(0);w.UB(W.gagl.v.val);
w.GT(W.ai5)};y.Su.prototype.ZE=function(w,n){for(var L=0;L<w.C.length;L++){var W=n.C[w.C[L]],D=w.A0[L];
if(D==null)delete W.add.lmfx;else W.add.lmfx=JSON.parse(D);y.Su.aq(n,W,JSON.parse(w.jb[L]));W.US.Wq=!0}n.rR=!0;
n.l()};y.Su.prototype.Fd=function(w,n){for(var L=0;L<w.C.length;L++){var W=n.C[w.C[L]],D=w.iy[L];if(D==null)delete W.add.lmfx;
else W.add.lmfx=JSON.parse(D);y.Su.aq(n,W,JSON.parse(w.pK[L]));W.US.Wq=!0}n.rR=!0;n.l()};y.Ul=function(){y.qw.call(this,"Layer Comps",y.q$)};
y.Ul.prototype=new y.qw;y.Ul.prototype.Al=function(w,n,W,D){var j=JSON.parse(JSON.stringify(W.kO)),I=JSON.parse(JSON.stringify(W.kO)),U=null,M=null,m=null,l=-1,A=!1;
if(w.d=="delLC"){var g=y.Ul.pp(W.kO,w.p_),k=W.kO.lastAppliedComp?W.kO.lastAppliedComp.v:0;I.list.v.splice(g,1);
if(k==w.p_)delete I.lastAppliedComp;U="Delete Layer Comp"}if(w.d=="editLC"){var g=y.Ul.pp(W.kO,w.p_),$=I.list.v[g].v;
if(w.np!=null)$.Nm.v=w.np;if(w.a9G!=null){var C=w.a9G,f=$.capturedInfo.v,z=f&(1<<C)-1;f=f>>C;if((f&1)==1)f--;
else f++;$.capturedInfo.v=(f<<C)+z}U="Layer Comp properties"}if(w.d=="setLC"){y.Ul.ak(W);if(w.p_==0)delete I.lastAppliedComp;
else I.lastAppliedComp={t:"long",v:w.p_};U="Switch Layer Comp";A=!0}if(w.d=="updLC"){y.Ul.ak(W);M=y.Ul.ac3(W,w.p_);
m=y.Ul.S2(W,w.p_);I.lastAppliedComp={t:"long",v:w.p_};U="Update Layer Comp";l=w.p_;A=!0}if(w.d=="addLC"){y.Ul.ak(W);
var s=1;for(var L=0;L<I.list.v.length;L++)s=Math.max(s,I.list.v[L].v.compID.v)+1;s+=Math.floor(Math.random()*1e4);
var O={t:"Objc",v:{classID:"Comp",Nm:{t:"TEXT",v:"New Comp "+(I.list.v.length+1)},compID:{t:"long",v:s},capturedInfo:{t:"long",v:7}}};
I.list.v.push(O);I.lastAppliedComp={t:"long",v:s};U="New Layer Comp";var a=y.Ul.S2(W,s);y.Ul.wf(W,a,s)}var X=new go(U,this);
X.data={ajr:j,awD:I,adI:M,aro:m,p_:l,T5:A};this.Fd(X.data,W);W.kK(X)};y.Ul.prototype.Fd=function(w,n){n.kO=w.awD;
n.rR=!0;if(w.aro)y.Ul.wf(n,w.aro,w.p_);if(w.T5){var W=n.kO.lastAppliedComp?n.kO.lastAppliedComp.v:0,D=y.Ul.pp(n.kO,W),j=D==-1?null:n.kO.list.v[D].v,I=j?j.capturedInfo.v:7;
y.Ul.YW(n,W,I);n.l()}};y.Ul.prototype.ZE=function(w,n){n.kO=w.ajr;n.rR=!0;if(w.adI)y.Ul.wf(n,w.adI,w.p_);
if(w.T5){var W=n.kO.lastAppliedComp?n.kO.lastAppliedComp.v:0,D=y.Ul.pp(n.kO,W),j=D==-1?null:n.kO.list.v[D].v,I=j?j.capturedInfo.v:7;
y.Ul.YW(n,W,I);n.l()}};y.Ul.ak=function(w){if(w.kO.lastAppliedComp!=null||!w.P6)return;var n=y.Ul.S2(w,0);
y.Ul.wf(w,n,0);w.P6=!1};y.Ul.T6=function(w,n,W){w.v.Hrzn.v+=n;w.v.Vrtc.v+=W};y.Ul.pp=function(w,n){var W=w.list.v;
for(var L=0;L<W.length;L++)if(W[L].v.compID.v==n)return L;return-1};y.Ul.agp=function(w){var n=w.layerSettings.v,j=null;
if(n.length==0)return;var W="compList enab Ofst blendOptions Lefx FXRefPoint imageMask vectorMask layerSpecific".split(" "),D=n[0].v;
if(D.enab==null)D.enab={t:"bool",v:!0};if(D.Ofst==null)D.Ofst={t:"Objc",v:{classID:"null",Hrzn:{t:"long",v:0},Vrtc:{t:"long",v:0}}};
for(var L=0;L<n.length;L++){var I=n[L].v;if(j==null)j=JSON.parse(JSON.stringify(I));else for(var U=0;
U<W.length;U++){var M=W[U];if(I[M])j[M]=JSON.parse(JSON.stringify(I[M]))}n[L].v=JSON.parse(JSON.stringify(j))}};
y.Ul.aaI=function(w,n){var W=w.add.shmd.cmls,D=W.layerSettings.v;for(var j=0;j<D.length;j++){var I=D[j].v,U=I.compList.v[0].v;
if(U==n)return j}return-1};y.Ul.aeZ=function(w,n){var W=y.Ul.aaI(w,n);return W==-1?null:w.add.shmd.cmls.layerSettings.v[W].v};
y.Ul.YW=function(w,n,W){for(var L=0;L<w.C.length;L++){var D=w.C[L],j=D.add.shmd.cmls;if(j==null)continue;
var I=j.layerSettings.v,U=y.Ul.aeZ(D,n);if(U==null){D.gb(!1);continue}if((W&1)!=0){if(U.enab)D.gb(U.enab.v);
else D.gb(!0)}if((W&2)!=0){if(U.Ofst){var M=U.Ofst.v,m=D.$k(w),l=Math.round(M.Hrzn.v-m.x),A=Math.round(M.Vrtc.v-m.y);
if(l!=0||A!=0)y.mU.Gt(w,[L],null,l,A)}}if((W&4)!=0){if(U.Lefx){var g=JSON.parse(JSON.stringify(U.Lefx.v));
dR.ml(g);if(JSON.stringify(g)!=JSON.stringify(D.add.lmfx)){D.add.lmfx=g;D.US.Wq=!0}}else delete D.add.lmfx;
if(U.blendOptions){var k=U.blendOptions.v;if(k.Opct)D.opacity=Math.round(255*k.Opct.v.val/100);if(k.fillOpacity)D.add.iOpa=Math.round(255*k.fillOpacity.v.val/100);
if(k.Md)D.Bx=D.add.lsct==ef.Cq?"norm":dD.XK(k.Md.v.BlnM)}else{D.opacity=255;D.Bx=D.ue()?"pass":"norm";
D.add.iOpa=255}}}};y.Ul.ac3=function(w,n){var W={};for(var L=0;L<w.C.length;L++){var D=w.C[L];if(D.add.shmd==null||D.add.shmd.cmls==null)continue;
W["l"+D.add.lyid]=JSON.parse(JSON.stringify(y.Ul.aeZ(D,n)))}return W};y.Ul.S2=function(w,n){var W={};
for(var L=0;L<w.C.length;L++){var D=w.C[L],j=D.add.lyid;W["l"+j]=y.Ul.ajD(w,D,n)}return W};y.Ul.ajD=function(w,n,W){var D=n.add.shmd?n.add.shmd.cmls:null,j={classID:"null"},I=n.$k(w),U={t:"Objc",v:{classID:"null",Hrzn:{t:"long",v:I.x},Vrtc:{t:"long",v:I.y}}};
j.compList={t:"VlLs",v:[{t:"long",v:W}]};j.enab={t:"bool",v:n.I4()};j.Ofst=JSON.parse(JSON.stringify(U));
j.FXRefPoint=JSON.parse(JSON.stringify(D&&D.origFXRefPoint?D.origFXRefPoint:U));j.blendOptions={t:"Objc",v:{classID:"null",Md:{t:"enum",v:{BlnM:dD.Eu(n.Bx)}},Opct:{t:"UntF",v:{type:"#Prc",val:100*n.opacity/255}},fillOpacity:{t:"UntF",v:{type:"#Prc",val:n.add.iOpa!=null?100*n.add.iOpa/255:100}}}};
if(n.add.vmsk){j.vectorMask={t:"Objc",v:{classID:"null"}};j.vectorMask.v.Ofst=JSON.parse(JSON.stringify(U))}if(n.add.lmfx){j.Lefx={t:"Objc",v:JSON.parse(JSON.stringify(n.add.lmfx))};
dR.BA(j.Lefx.v)}return j};y.Ul.adm=function(w,n){var W=n.add.lyid;if(n.add.shmd==null)n.add.shmd={};
if(n.add.shmd.cmls==null){n.add.shmd.cmls={classID:"null",LyrI:{t:"long",v:W},layerSettings:{t:"VlLs",v:[{t:"Objc",v:y.Ul.ajD(w,n,0)}]}}}};
y.Ul.wf=function(w,n,W){for(var L=0;L<w.C.length;L++){var D=w.C[L],j=D.add.lyid;y.Ul.adm(w,D);var I=D.add.shmd.cmls,U=I.layerSettings.v,M=n["l"+j];
if(M!=null)M={t:"Objc",v:JSON.parse(JSON.stringify(M))};var m=y.Ul.aaI(D,W);if(m==-1){if(M==null)continue;
else U.push(M)}else{if(M==null)U.splice(m,1);else U[m]=M}}};y.Ul.PR=function(w,n){for(var L=0;L<w.C.length;
L++){var W=w.C[L],D=W.add.lyid;if(W.add.shmd==null||W.add.shmd.cmls==null)continue;var j=W.$k(w),I=Math.round(j.x),U=Math.round(j.y);
if(!n){I=-I;U=-U}var M=W.add.shmd.cmls,m=M.layerSettings.v;if(M.origFXRefPoint)y.Ul.T6(M.origFXRefPoint,-I,-U);
for(var l=0;l<m.length;l++){var A=m[l].v;y.Ul.T6(A.Ofst,I,U);var g=A.imageMask,k=A.vectorMask;if(g&&g.v.Ofst)y.Ul.T6(g.v.Ofst,I,U);
if(k&&k.v.Ofst)y.Ul.T6(k.v.Ofst,I,U)}}};y.CY=function(){y.qw.call(this,"Adjust Edit",y.DW);this.Hb=null;
this.jf=null};y.CY.prototype=new y.qw;y.CY.se=function(w,n,W,D){if(D)n/=4;var j=0,I=0,U=255,M=0,m=0,l=255;
while(I+w[j]<n){I+=w[j];j++}while(M+w[U]<n){M+=w[U];U--}if(D){j-=Math.round(w[j]/(W/32));U+=Math.round(w[U]/(W/32));
if(j<0)m=Math.round(-j*255/(U-j));if(U>255)l=255-Math.round((U-255)*255/(U-j))}return[Math.max(j,0),Math.min(U,255),m,l,100]};
y.CY.prototype.Al=function(w,n,W,D,j){var I=w.d;if(I=="auto"){var U=w.Fv,M=y.CY.getData(W);for(var L=0;
L<M.length;L++){var m=M[L],l;if(U<3){}else{var A=cx._1("hue2");cT.nr(A,0,[0,-100,0]);l=eH.rw("hue2",A)}eH.Ld(l,m.Ey,m.VC,m.WH)}y.CY.ER(W,M);
y.CY.Zx(W,M,U<3?[4,16,U]:[19,7,0],this);W.l()}if(I=="edit_layer")this.atJ(w,n,W,D);if(I=="edit"||I=="confirm"||I=="cancel")this.sw(w,n,W,j,!0);
if(I=="start"){if(W.g.length==0)return;var g=W.C[W.g[0]];if(g.add.SoLd&&g.eL<=0&&W.v9.length==0){var k=new ed(b.E.v,!0);
k.G=y.sT;k.data={d:"start",su:w.u4,jB:w.jB};n.S(k);return}if(!W.dD(n,null,!0))return;if(gu[w.u4]&&w.jB==null){if(W.g.length!=1)alert("Will be applied to "+W.g.length+" layers.");
var k=new ed(b.E.L,!0);k.data={d:b.c.P2,jW:"afw_"+w.u4};n.S(k)}else{this.sw({d:"edit",jB:w.jB,su:w.u4},n,W,j);
this.sw({d:"confirm",su:w.u4},n,W,j)}}};y.CY.prototype.atJ=function(w,n,W,D){var j=w.d,I=W.g[0],U=W.C[I],M=eH.get(U.add),m=JSON.parse(JSON.stringify(U.add[M])),k;
for(var l in w.Z)m[l]=w.Z[l];var A=JSON.parse(JSON.stringify(m));for(var l in eH.Nn)if(eH.Nn[l]==M)A.classID=l;
var g=W.history[W.QQ];if(g&&g.G==this&&g.data.Z1!=null&&g.data.j==I)k=g;else{var $=new ed(b.E.W1,!0),C={classID:"setd",null:cq.Pz("AdjL",!0),T:{t:"Objc",v:A}};
$.data={Q9:!0,hZ:"set",E3:C};n.S($);var k=new go([6,39],this);k.data={j:I,Z1:U.add[M],qY:m,Yw:C};W.kK(k)}k.data.qY=m;
k.data.Yw.T.v=A;this.Fd(k.data,W)};y.CY.getData=function(w,n,W){var D=[],j=new iB(0,0,w.m,w.n),I=w.v9.length!=0?[-1-w.v9[0]]:w.g;
for(var L=0;L<I.length;L++){var U=I[L],M=U<0?null:w.C[U],m={j:U,vi:U<0?1:M.eL};D.push(m);var l=w.yo[-1-U];
if(0<=U)l=M.eL<=0?null:M.eL==1?M._N():M.NP(w).z;var A=l?l.rect:M.rect;if(w.J){m.WH=w.J.rect.wU(n||l!=null?j:A)}else m.WH=n||l!=null?A.x0(j):A.clone();
if(W)m.WH=W[L].WH.clone();var g=m.WH.O();m.Ey=E.Q(g*4);if(l)y.JT.gv(l.channel,l.rect,l.color,m.Ey,m.WH);
else E.Cb(M.buffer,A,m.Ey,m.WH);m.VC=m.Ey.slice(0);if(w.J){m.Xi=E.Q(g);E.B0(w.J.channel,w.J.rect,m.Xi,m.WH)}}return D};
y.CY.arn=function(w,n,W){if(n==null)return n;var D=eH.Zk(w,n),I;if(D==-1)return n;var j=W.length>>>2,U=E.Bk(W),M=.001*j;
if(D==0||D==2)I=[[0,255,0,255,100],y.CY.se(U[1],M,j,D==2),y.CY.se(U[2],M,j,D==2),y.CY.se(U[3],M,j,D==2)];
if(D==1)I=[y.CY.se(U[0],M*.33,j,!1),[0,255,0,255,100],[0,255,0,255,100],[0,255,0,255,100]];var m=cx._1("levl");
for(var L=0;L<4;L++)il.nr(m,L,I[L]);return m};y.CY.ayE=function(w,n,W,D){var j,I;if(W.t=="name"){var U=0;
for(var M=0;M<w.C.length;M++)if(w.C[M].getName()==W.v.val)U=M;if(w==n&&U==D.j){j=D.Ey;I=D.WH}else{var m=w.C[U];
j=m.buffer;I=m.rect}}else{I=new iB(0,0,w.m,w.n);j=w==n?D.p0:w.Vc()}return[j,I]};y.CY.prototype.sw=function(w,n,W,D){if(this.Hb==null){if(w.su=="aply")W.C[W.g[0]].extend(new iB(0,0,W.m,W.n));
this.Hb=y.CY.getData(W,null,w.su=="fade"?W.by().data:null);if(w.su=="aply"||w.su=="matc")this.Hb[0].p0=W.Vc()}if(w.d=="edit"){this.jf=[w.su,w.jB];
var j=this.Hb[0],I=y.CY.arn(w.su,w.jB,j.Ey),U=eH.rw(w.su,I);if(w.su=="fade"||w.su=="matc"||w.su=="aply")U=w.jB;
if(U!=null){for(var M=0;M<this.Hb.length;M++){var m=this.Hb[M];if(w.vv)E.nX(m.Ey,m.VC);else if(w.su=="fade"){var l=dD.XK(w.jB.Md.v.BlnM),A=w.jB.Opct.v.val/100,g=W.by().data[M];
E.nX(g.Ey,m.VC);if(l=="norm")E.s.eY(m.Ey,m.WH,m.VC,m.WH,null,null,null,m.WH,A);else{var k=ge.cT();k.MY=!0;
for(var L=0;L<g.Ey.length;L+=4)if(g.Ey[L+3]!=m.Ey[L+3]){k=null;break}E.s._U(l,m.Ey,m.WH,m.VC,m.WH,m.WH,A,k)}}else if(w.su=="matc"){var $;
if(U.noReference&&U.noReference.v)$=m.Ey;else{var C=U.Srce.v,f=C[1].v.val,z=n.oZ,s=W;for(var L=0;L<z.length;
L++)if(z[L].name==f)s=z[L];var O=y.CY.ayE(s,W,C[0],m);$=O[0]}d9(m.Ey,m.WH.m,m.WH.n,$,m.VC,[U.Lght.v,U.ClrR.v,U.Fade.v,U.neutralizeColor?U.neutralizeColor.v:!1])}else if(w.su=="aply"){U=U.With.v;
var a=U.T.v,O=y.CY.ayE(W,W,a[1],m),$=O[0],X=O[1],P=U.Clcl?U.Clcl.v.Clcn:null,l=P?dD.XK(P):"norm",A=U.Opct?U.Opct.v.val/100:1,Z=["RGB","Rd","Grn","Bl","Trsp"].indexOf(a[0].v.enum),I=U.Invr&&U.Invr.v;
if(I||Z!=0){$=$.slice(0);if(I)E.afz($);if(Z!=0){var Y=E.Q(X.O());E.hN($,Y,Z-1);if(Z==4)E.Ba(Y);for(var K=0;
K<3;K++)E.IL(Y,$,K)}}if(P=="Add"||P=="Sbtr"){var S=1/U.Scl.v,G=U.Ofst.v,V=P=="Add"?1:-1,T=new Uint8ClampedArray(m.VC.buffer);
for(var L=0;L<$.length;L+=4){T[L]=(m.Ey[L]+V*$[L])*S+G;T[L+1]=(m.Ey[L+1]+V*$[L+1])*S+G;T[L+2]=(m.Ey[L+2]+V*$[L+2])*S+G}}else{var k=ge.cT();
k.MY=U.PrsT&&U.PrsT.v;m.VC.fill(0);m.VC.set(m.Ey);E.s._U(l,$,X,m.VC,m.WH,m.WH,A,k)}}else eH.Ld(U,m.Ey,m.VC,m.WH)}y.CY.ER(W,this.Hb)}}if(w.d=="cancel"){y.CY.aaw(W,this.Hb);
this.Hb=null}if(w.d=="confirm"){var R={fade:[2,11],aply:[2,12],matc:[4,18]},x=R[w.su];if(x==null)x=eH.names[w.su];
var v=eH.Zk(w.su,this.jf[1]);if(v!=-1)x=[4,16,v];y.CY.Zx(W,this.Hb,x,this);this.Hb=null;if(v==-1)y.CY.rr(n,this.jf)}W.l()};
y.CY.rr=function(w,n){var W=n[0],D=n[1],j,I;if(eH.Hc[W]){j=eH.Hc[W];if(gu[W])I=D}if(cx.Hc[W]){j=cx.Hc[W];
if(gu[W])I=D}if(W=="fade"){j="fade";I=D}if(W=="matc"){j="matchColor";I=D}if(W=="aply"){j="applyImageEvent";
I=D}if(j==null)return;var U=new ed(b.E.W1,!0);U.data={Q9:!0,hZ:j};if(I){I=JSON.parse(JSON.stringify(I));
U.data.E3=I}w.S(U)};y.CY.aaw=function(w,n){y.CY.Ek(w,n)};y.CY.Zx=function(w,n,W,D){for(var L=0;L<n.length;
L++){var j=n[L],I=w.C[j.j],U=j.j<0?w.yo[-1-j.j]:j.vi<=0?null:j.vi==1?I._N():I.NP(w).z;if(U){U.ky();U.eP=!0;
if(I)I.yb(w)}else{I.ky();I.l()}delete j.VC;delete j.Xi}var M=new go(W,D);M.data=n;w.kK(M);w.rR=!0};y.CY.ER=function(w,n,W){for(var L=0;
L<n.length;L++){var D=n[L],j=w.C[D.j],I=W?D.Ey:D.VC,U=D.WH;if(D.vi==0){j.extend(U);if(D.Xi){E.Cb(D.Ey,U,j.buffer,j.rect);
E.s.eY(I,U,j.buffer,j.rect,D.Xi,U,0,U,1)}else E.Cb(I,U,j.buffer,j.rect)}else{var M=D.j<0?w.yo[-1-D.j]:D.vi==1?j._N():j.NP(w).z;
M.extend(U);if(D.Xi){var m=E.Q(U.O()*4);E.nX(D.Ey,m);E.s.eY(I,U,m,U,D.Xi,U,0,U,1);y.JT.au(m,U,M)}else y.JT.au(I,U,M);
M.eP=!0;if(j)j.yb(w)}if(j)j.l()}if(!W)y.CY.a8A(w,n)};y.CY.Ek=function(w,n){for(var L=0;L<n.length;L++){var W=n[L],D=w.C[W.j],j=W.WH,I=E.Q(j.O()*4);
if(W.vi==0){E.Cb(D.buffer,D.rect,I,j);D.extend(j);E.Cb(W.Ey,j,D.buffer,D.rect);D.ky()}else{var U=W.j<0?w.yo[-1-W.j]:W.vi==1?D._N():D.NP(w).z;
y.JT.gv(U.channel,U.rect,U.color,I,j);U.extend(j);y.JT.au(W.Ey,j,U);U.ky();U.eP=!0;if(D)D.yb(w)}W.Ey=I;
if(D)D.l()}w.rR=!0};y.CY.a8A=function(w,n){var W=y.CY.a0U(w),D=~W;if(W==16777215)return;for(var L=0;
L<n.length;L++){var j=n[L],I=w.C[j.j],U=j.WH;if(j.vi!=0)continue;I.extend(U);var M=U.x-I.rect.x,m=U.y-I.rect.y,l=I.rect.m,A=new Uint32Array(j.Ey.buffer),g=new Uint32Array(I.buffer.buffer);
for(var k=0;k<U.n;k++)for(var $=0;$<U.m;$++){var C=k*U.m+$,f=(k+m)*l+($+M);g[f]=g[f]&W|A[C]&D}I.ky();
I.l()}w.l()};y.CY.a0U=function(w){var n=w.u.zC;return n[2]*16711680|n[1]*65280|n[0]*255};y.CY.prototype.ZE=function(w,n){var W=n.C[w.j];
if(w.Z1!=null)W.add[eH.get(W.add)]=w.Z1;else y.CY.Ek(n,w);n.l()};y.CY.prototype.Fd=function(w,n){var W=n.C[w.j];
if(w.Z1!=null)W.add[eH.get(W.add)]=w.qY;else y.CY.Ek(n,w);n.l()};y.N$=function(){y.qw.call(this,"Filter Edit",y.sT);
this.Hb=null;this.Kb=null;this.d=null;this.jf=null};y.N$.prototype=new y.qw;y.N$.prototype.Al=function(w,n,W,D,j){if(w.d=="start"){if(W.g.length==0)return;
var I=W.C[W.g[0]];if(I.add.SoLd&&I.eL<=0&&W.v9.length==0){}else if(!W.dD(n,null,!0))return;var U=w.su;
if((gu[U]||cx.a[U])&&w.jB==null){if(W.g.length!=1)alert("Will be applied to "+W.g.length+" layers.");
var M=new ed(b.E.L,!0);M.data=y.N$.atu(U,this.qo(W,U));n.S(M)}else{var m={d:"edit",su:U,jB:w.jB,PX:this.qo(W)};
this.Al(m,n,W,D,j);m.d="confirm";delete m.jB;this.Al(m,n,W,D,j)}}if(w.d=="edit"||w.d=="cancel"||w.d=="confirm"){if(w.d=="edit")this.jf=[w.su,w.jB];
if(w.PX)this.auB(w,n,W,j);else this.aem(w,n,W,j)}if(w.d=="applylast"&&this.jf!=null){var m={d:"edit",su:this.jf[0],jB:this.jf[1],PX:this.qo(W)};
this.Al(m,n,W,D,j);m.d="confirm";delete m.jB;this.Al(m,n,W,D,j)}};y.N$.atu=function(w,n){var W=cx.a[w];
if(W)return{d:b.c.CV,G:W,LQ:{PX:n}};else return{d:b.c.P2,jW:"afw_"+w,PX:n}};y.N$.prototype.qo=function(w,n){var W=w.C[w.g[0]],D;
if(W.add.SoLd&&W.eL<=0&&w.v9.length==0){D={j:w.g[0],index:0};if(W.add.SoLd.filterFX!=null){var j=W.add.SoLd.filterFX.v.filterFXList.v;
D.index=j.length;for(var L=0;L<j.length;L++)if(cx.iF(j[L].v)==n&&cx.a[n])D.index=L}}return D};y.N$.prototype.auB=function(w,n,W,D){var j=W.C[w.PX.j],I=w.su;
if(w.d=="edit"){if(this.d==null){var U=cx.names[I];if(U==null)U=eH.names[I];if(I=="blendOptions")U=[14,10];
this.d=new go(U,this);this.d.data={PX:w.PX,a1u:JSON.parse(JSON.stringify(j.add.SoLd))}}if(!j.YC()){j.add.SoLd.filterFX=cx.Gq();
this.d.data.Nq=kc.ap8(j.add.SoLd.placed.v);W.V$(this.d.data.Nq);j.vr(W)}var M=j.add.SoLd.filterFX.v.filterFXList.v;
if(M[w.PX.index]==null){M.push(cx.gt(I,D))}if(w.jB){M[w.PX.index].v.enab.v=w.vv!=!0;if(I=="blendOptions")M[w.PX.index].v.blendOptions.v=w.jB;
else M[w.PX.index].v.Fltr.v=w.jB}this.d.data.ao4=JSON.parse(JSON.stringify(j.add.SoLd));this.Fd(this.d.data,W)}if(w.d=="cancel"){if(this.d)this.ZE(this.d.data,W);
this.d=null}if(w.d=="confirm"){if(this.d)W.kK(this.d);y.CY.rr(n,this.jf);this.d=null}};y.N$.prototype.Ak=function(w){return{o:w>>>16,B:w>>>8&255,k:w&255}};
y.N$.prototype.aem=function(w,n,W,D){if(this.Hb==null){var j=cx.R5(w.su,w.jB);this.Hb=y.CY.getData(W,j.x!=0||j.y!=0)}if(w.d=="edit"){var I=JSON.stringify(w.jB);
if((w.jB==null||I!=this.Kb)&&w.vv!=!0)for(var L=0;L<this.Hb.length;L++){var U=this.Hb[L],M={rect:U.WH,buffer:U.Ey},m={rect:U.WH,buffer:U.VC};
if(w.su=="Avrg"&&U.Xi){M.buffer=U.Ey.slice(0);E.py(U.Xi,M.buffer)}cx.Ld(w.su,M,w.jB,this.Ak(D.Gp),this.Ak(D.as),m,[W.add.lnk2?W.add.lnk2:[],W.C[W.g[0]]._N(),W.yo,W.OV()]);
if(w.su=="Avrg"&&U.Xi){var l=U.Ey.length;for(var L=0;L<l;L+=4)U.VC[L+3]=U.Ey[L+3]}this.Kb=I}y.CY.ER(W,this.Hb,w.vv)}if(w.d=="cancel"){y.CY.aaw(W,this.Hb);
this.Hb=null;this.Kb=null}if(w.d=="confirm"){y.CY.Zx(W,this.Hb,cx.names[w.su],this);this.Hb=null;this.Kb=null;
y.CY.rr(n,this.jf)}W.l();W.rR=!0};y.N$.prototype.ZE=function(w,n){if(w.PX){var W=n.C[w.PX.j];if(w.Nq)n._7(w.Nq);
W.add.SoLd=JSON.parse(JSON.stringify(w.a1u));if(W.YC())W.AK(n);else{W.vr(n);W.eL=0}}else y.CY.Ek(n,w);
n.l();n.rR=!0};y.N$.prototype.Fd=function(w,n){if(w.PX){var W=n.C[w.PX.j];if(w.Nq)n.V$(w.Nq);W.add.SoLd=JSON.parse(JSON.stringify(w.ao4));
if(W.YC())W.AK(n);else W.vr(n);if(!W.IF())W.FK+=32}else y.CY.Ek(n,w);n.l();n.rR=!0};var bk={bI:"0",zq:"1",tU:"2",tX:"3",K_:"3.5",gB:"4",C0:"5",Iv:"6",qs:"7",v:"8",Q6:"8.5",M9:"8.8",dp:"9",v3:"10",a8:"11",ut:"12",Nd:"13",ef:"14",SJ:"15",ad:"16",xo:"17",X$:"21",SU:"22",Xh:"23",OS:"23.0",pa:"23.1",ZX:"23.2",aK:"23.3",Qu:"23.4",WA:"23.5",TK:"23.6",agg:"30",Uj:"31",Z0:"40",ix:"41",_w:"42"};
bk.Fj={};bk.Fj[bk.zq]=["abr","brushes",jl,[9,3],3];bk.Fj[bk.tU]=["grd","gradients",f8,[12,37],4];bk.Fj[bk.tX]=["shc","contours",c7,[12,21],0];
bk.Fj[bk.K_]=["acv","curves",e0,[4,2],0];bk.Fj[bk.gB]=["asl","styles",bt,[12,22],5];bk.Fj[bk.C0]=["pat","patterns",kj,[12,62],6];
bk.Fj[bk.Iv]=["csh","shapes",bI,[12,77],7];bk.Fj[bk.qs]=["aco","swatches",dm,[9,8],0];bk.Fj[bk.v]=["atn","actions",gc,[9,9],2];
bk.Fj[bk.Q6]=["tpl","tpresets",kt,[9,12],0];bk.Fj[bk.M9]=["icc","profiles",jF,"ICCs",8];function go(w,n,W){if(W==null)W=!1;
this.name=w;this.G=n;this._$=W;this.data=null;this.a1w=Date.now()}var cq={};cq.Pz=function(w,n){var W={t:"Clss",v:{classID:w}};
if(n)W={t:"Enmr",v:{classID:w,typeID:"Ordn",enum:"Trgt"}};return{t:"obj ",v:[W]}};cq.Jf=function(w,n){var W={classID:"Lyr"};
W[w]=n;return{hZ:"set",E3:{classID:"null",null:cq.Pz("Lyr",!0),T:{t:"Objc",v:W}}}};cq.aqF=function(w,n,W,D,j){var I=new ed(b.E.W1,!0),U=[],L=0,M=cq.iR(n,W,D,U);
while(U.length!=0){var m=U.pop();L++;if(!m.r)continue;console.log(L-1);if(m.hZ=="conditional"){var l=w.C[w.g[0]],A=m.E3.null.v.Cndt,g=!1;
if(A=="Bckg")g=!1;else if(A=="Pxel"&&w.d2(!1))g=!0;else if(A=="Adjs"&&eH.get(l.add))g=!0;else if(A=="Shp"&&l.add.vogk)g=!0;
else if(A=="Grup"&&l.ue())g=!0;else if(A=="Opn"&&w!=null)g=!0;else if(A=="32Bt")g=!1;else if(A=="RGB")g=!0;
var k=m.E3.then,$=m.E3.else;if(g&&k)cq.iR(n,k.v[0].v.val,k.v[1].v.val,U);if(!g&&$)cq.iR(n,$.v[0].v.val,$.v[1].v.val,U)}else if(m.hZ=="stop"){if(m.E3.Cntn&&m.E3.Cntn.v==!0)window.confirm(m.E3.Msge.v);
else{alert(m.E3.Msge.v);break}}else if(m.hZ=="play"){var C=m.E3.null.v,f=new ed(b.E.L,!0);f.data={d:b.c.if,HD:[C[0].v.val,C[1].v.val]};
j.S(f)}else{I.data={hZ:m.hZ,E3:m.E3};j.S(I)}}};cq.iR=function(w,n,W,D){var j;for(var L=0;L<w.length;
L++){if(w[L].s7!=W)continue;var I=w[L].xq;for(var U=0;U<I.length;U++){if(I[U].s7!=n)continue;j=I[U].xq}}var M=j.length;
for(var L=0;L<M;L++)D.push(j[M-1-L])};cq.agF=function(w){var n=w.hZ,W=w.E3,D,U,M,m,l;if(W&&W.null)D=W.null.v[0];
if(W&&D==null&&W.At)D=W.At.v[0];if(D&&D.t=="obj ")D=D.v[0];var j=D&&D.v?D.v.classID:null,I=["purge"];
if(I.indexOf(n)!=-1)return n[0].toUpperCase()+n.slice(1);if(n=="GEfc"||n=="paintDaubs")return ic.names[W.GEfk.v.GEft][1];
l=eH.Hc;for(U in l)if(l[U]==n)M=U;l=cx.Hc;for(U in l)if(l[U]==n)m=U;if(M){var A=eH.Zk(M,W);if(A!=-1)return[4,16,A];
return eH.names[M]}if(m)return cx.names[m];var g=cq.aqU;if(n=="make"){if(D){if(j=="AdjL")return[6,1];
else if(j=="layerSection")return W.From?[6,9]:[6,20];else if(j=="Lyr")return[6,13];else if(j=="Chnl"&&D.v.enum=="Msk")return[6,2];
else if(j=="contentLayer")return[6,48,1];else if(j=="BckL")return"Make Background Layer";else if(j=="Path")return"Make Path";
else if(j=="TxLr")return"Make Text Layer";else if(j=="slice")return"Make Slices";else if(j=="Dcmn")return[11,7];
else if(j=="Gd")return[23,4]}if(W.Nw){j=W.Nw.v.classID;if(j=="Dcmn")return[11,7];else if(j=="Chnl"||j=="SCch")return"New Channel"}}else if(n=="deselect"){if(j=="Path")return"Deselect current path";
else throw j}else if(n=="draw"){return"Draw"}else if(n=="select"){if(j=="Chnl")return"Select "+(D.v.enum=="Msk"?"Mask ":"")+"Channel";
else if(j=="Mn")return"Select Panel \""+D.v.enum+"\"";else if(j=="Lyr"){if(D.t=="Enmr")return"Select "+{Bckw:"Backward",Frwr:"Forward",Back:"Back",Frnt:"Front"}[D.v.enum]+" Layer";
return"Select Layer \""+D.v.val+"\""}else if(j=="Path")return"Select Path";else if(j=="Brsh")return"Select Brush";
else if(j=="Dcmn")return"Select Document"}else if(g[n]&&j=="Chnl"){var k=D.v.keyID=="fsel";return g[n]+" "+(k?"Selection":"Channel")}else if(n=="set"){if(j=="Lyr")return"Set Current Layer";
else if(j=="AdjL")return[6,39];else if(j=="contentLayer")return[6,48,2];else if(j=="Prpr"){var $=D.v.keyID;
if($=="TxtS")return"Set Text Style";else if($=="paragraphStyle")return"Set Paragraph Style";else if($=="Lefx")return[11,6];
else console.log($)}else if(j=="Clr")return"Set "+(D.v.keyID=="FrgC"?"Foreground":"Background")+" color";
else if(j=="Brsh")return"Set Brush";else if(j=="Path")return"Set Work Path";else console.log(j)}else if(n=="move"){if(j=="Lyr")return"Move Layer";
else if(j=="Chnl"&&D.v.keyID=="fsel")return[7,7];else console.log(j)}else if(n=="show"||n=="hide"){var C="";
if(j=="Lyr")+"Layer";if(j=="Chnl")+"Channel";return(n=="show"?"Show":"Hide")+" "+C}else if(n=="reset"){if(j=="Clr")return"Reset Colors"}else if(n=="exchange"){if(j=="Clr")return[22,7,0]}else if(n=="rotateEventEnum")return[2,5];
else if(n=="flip"){var f=W.Axis.v.Ornt=="Hrzn";return[[2,6],[22,4,f?2:3]]}if(j=="Chnl"){if(n=="duplicate"){if(D.v.keyID=="fsel")return"Selection to Channel";
else return"Duplicate Channel"}if(n=="delete")return"Delete Channel"}if(n=="transform")return D&&D.v.keyID=="fsel"?[7,10]:[10,16];
var z={cut:[5,0],copyEvent:[5,1],copyToLayer:[6,49,0],cutToLayer:[6,49,1],copyMerged:[5,7],paste:[5,2],close:[1,12,0],save:[1,2],groupEvent:[6,18],ungroup:[6,19],duplicate:[6,0],mergeLayersNew:[6,12,0],mergeVisible:"Merge Visible",flattenImage:[6,12,1],updatePlacedLayer:[6,36,1],fade:[2,11],applyImageEvent:[2,12],matchColor:[4,18],fill:[2,3],colorRange:[7,8],desaturate:[19,7,0],delete:W?j=="Lyr"?[6,31]:"Delete Path":[2,2],align:[20,4,0],applyLocking:[6,57,1],crop:[11,12,1],placedLayerEditContents:"Edit Contents",placedLayerExportContents:"Export Contents",placedLayerReplaceContents:"Replace Contents",convertMode:"Convert Mode",grow:"Grow Selection",similar:"Similar Selection",newPlacedLayer:[6,7,0],selectNoLayers:"Deselect Layers",canvasSize:[11,3],imageSize:[11,10],rasterizeLayer:[6,8],revealAll:[11,12,2],divide:"Divide Current Slice",collapseAllGroupsEvent:"Collapse All Groups",conditional:"If"},s=z[n];
if(s==null)s=cq.a92[n];if(s)return s;return n};cq.a92={border:[7,9],smoothness:[19,3,0],expand:[7,4],contract:[7,5],feather:[7,6],inverse:[7,2]};
cq.aqU={set:"Set",add:"Add Transparency",addTo:"Add To",subtract:"Subtract Transparency",subtractFrom:"Subtract From",interfaceIconFrameDimmed:"Intersect Transparency",interfaceWhite:"Intersect With"};
cq.a2c=function(w,n,W,D){var j=w.hZ,I=w.E3,U=!1,M=new ed(b.E.v,!0),A,g,k,$;M.G=y.Yu;var m=new ed(b.E.L,!0),l=["purge","updatePlacedLayer","convertMode","convertToProfile"];
if(l.indexOf(j)!=-1)return;$=eH.Hc;for(A in $)if($[A]==j)g=A;$=cx.Hc;for(A in $)if($[A]==j)k=A;if(j=="fade")g=j;
if(j=="matchColor")g="matc";if(j=="applyImageEvent")g="aply";if(g){M.G=y.DW;M.data={d:"start",u4:g,jB:I}}else if(k){M.G=y.sT;
M.data={d:"start",su:k,jB:I}}else if(j=="GEfc"||j=="paintDaubs"){M.G=y.sT;M.data={d:"start",su:"GEfc",jB:I}}else if(j=="imageSize"||j=="canvasSize"||j=="revealAll"||j=="trim"||j=="crop"){M.G=y.xA;
M.data={d:"fromAction",bs:w}}else if(j=="fill"||j=="stroke"||j=="delete"&&I==null){var C=null;if(D.g.length!=0)C=D.C[D.g[0]];
var f=E.uv(W.Gp);if(C!=null&&j=="fill"&&C.add.TySh){var s="var c = new SolidColor(); c.rgb.red="+f.o+"; c.rgb.green="+f.B+"; c.rgb.blue="+f.k+"; app.activeDocument.activeLayer.textItem.color = c;";
m.data={d:b.c.zM,wx:s}}else if(C!=null&&j=="delete"&&C.add.TySh){M.G=y.Lu;M.data={d:"insertText",Z:""}}else if(C!=null&&j=="fill"&&C.I9()){var M=new ed(b.E.W1,!0),I={classID:"setd",null:cq.Pz("contentLayer",!0),T:{t:"Objc",v:{}}};
y.G$.xk({Clr:{v:E.M.lW(E.uv(W.Gp))}},I.T.v,0);M.data={hZ:"set",E3:I};n.S(M);return}else{M.G=W.No==y.uX?y.uX:y.zq;
M.data={d:"fromAction",bs:w}}}else if(j=="colorRange"||j=="grow"||j=="similar"){M.G=y.Y5;M.data={d:"fromAction",bs:w}}else if(j=="set"&&I&&I.T&&I.T.v.Ordn=="Al"&&W.No==y.Lu&&n.RR().wb()){M.G=y.Lu;
M.data={d:"selectAll"}}else if(cq.a92[j]||cq.aqU[j]&&(!1||I.With&&I.With.v[0].v.keyID=="fsel"||I.From&&I.From.v[0].v.keyID=="fsel"||I.null&&I.null.v[0].v.keyID=="fsel"||I.T.v[0]&&I.T.v[0].v.keyID=="fsel")){M.G=y.wA;
M.data={d:"fromAction",bs:w}}var O={copyToLayer:h.Nk,cutToLayer:h.cP,mergeLayersNew:h.g6,rasterizeLayer:h.a1O,mergeVisible:h.nH,flattenImage:h.aza,newPlacedLayer:h.zi};
if(O[j])M.data={d:O[j],E3:I};if(M.data){n.S(M);return}if(j=="collapseAllGroupsEvent"){for(var L=0;L<D.C.length;
L++){var C=D.C[L];if(C.ue())C.add.lsct=ef.Se}D.tL=!0;return}if(j=="desaturate"){M.G=y.DW;M.data={d:"auto",Fv:3};
if(D&&D.C[D.g[0]].add.SoLd==null)n.S(M);return}if(j=="close"){if(I&&I.Svng.v.YsN=="Ys"){m.data={d:b.c.LI};
n.S(m)}m.data={d:b.c.L1,Pk:D};n.S(m);return}if(j=="save"){m.data={d:b.c.LI};n.S(m);return}if(j=="copyMerged"){m.data={d:b.c.UA,O0:!0,bh:!0};
n.S(m);return}if(j=="placedLayerReplaceContents")m.data={d:b.c.J0,I3:!0};var O={placedLayerEditContents:b.c.agP,placedLayerExportContents:b.c.ayP,copyEvent:b.c.UA,paste:b.c.s_};
if(O[j])m.data={d:O[j],bh:!0};if(m.data){n.S(m);return}var a=I.null?I.null.v:null,X=a?a[0].v.classID:"";
if(j=="make"){if(I.null==null&&I.Nw)X=I.Nw.v.classID;if(X=="AdjL"){M.data={d:h.yH,E3:I}}else if(X=="layerSection"){M.data=I.From?{d:h.Vp}:{d:h.Si};
if(I.Usng){var P=I.Usng.v;if(P.Nm)M.data.np=P.Nm.v;if(P.Clr)M.data.ve=cq.Qs(P)}}else if(X=="Lyr"){if(I.Usng&&I.Usng.v.length==2)M.data={d:h.atm};
else{M.data={d:h.tp};if(I.Usng)M.data.np=I.Usng.v.Nm.v;if(I.below&&I.below.v)M.data.awQ=!0}}else if(X=="Chnl"&&I.At&&I.At.v[0].v.enum=="Msk"){M.data={d:h.uV,IZ:I.Usng.v.UsrM}}else if(X=="Chnl"||X=="SCch"){M.data={d:h.QE,vK:"fromAction",Z:w}}else if(X=="contentLayer"){M.data={d:h.YS,E3:I}}else if(X=="BckL"){D.C[D.g[0]].at0();
return}else if(X=="Dcmn"){if(I.Nw==null)return;var Z=I.Nw.v;m.data={d:b.c.dH,On:kc.awd(Z,W)}}else if(X=="Ptrn")m.data={d:b.c.lb,AH:0};
else if(X=="Path"){M.G=y.Au;M.data={d:"pathedit",vK:"fromsel"}}else if(X=="TxLr"){M.G=y.Lu;M.data={d:"fromAction",bs:w}}else if(X=="slice"){M.G=y.Od;
M.data={d:"fromAction",bs:w}}else if(X=="Gd"){var Y=[[],[]],Z=I.Nw.v;Y[Z.Ornt.v.Ornt=="Vrtc"?0:1].push(Z.Pstn.v.val);
var K=aC.LC(Y);y.mU.w6(K,D.Iw());M.G=y.Rv;M.data={d:"gids",Qh:K}}else{console.log(j,X,I);throw"e"}}else if(j=="divide"){M.G=y.Od;
M.data={d:"fromAction",bs:w}}else if(j=="deselect"){if(X=="Path"){D.rs=[];D.zS=[];D.tL=D.RP=!0;return}else throw X}else if(j=="selectNoLayers"){D.g=[];
D.rR=!0}else if(j=="select"){var S={PcTl:y.uX,PbTl:y.zq,moveTool:y.Rv,cloneStampTool:y.OW,typeCreateOrEditTool:y.Lu,artboardTool:y.yl,marqueeRectTool:y.wA,typeVerticalCreateOrEditTool:y.Kk,perspectiveCropTool:y.r_,marqueeEllipTool:y.a8F,eyedropperTool:y.Ky,eraserTool:y.rU,pathComponentSelectTool:y.Au,lassoTool:y.GO,backgroundEraserTool:y.RV,directSelectTool:y.Kr,polySelTool:y.a4C,rectangleTool:y.K7,magneticLassoTool:y.an9,gradientTool:y.ZI,quickSelectTool:y.N4,bucketTool:y.afO,ellipseTool:y.Ww,magicWandTool:y.Y5,blurTool:y.yJ,polygonTool:y.Eh,cropTool:y.xA,sharpenTool:y.w7,lineTool:y.Hw,sliceTool:y.Od,smudgeTool:y.mH,customShapeTool:y.dY,sliceSelectTool:y.Xg,dodgeTool:y.wD,spotHealingBrushTool:y.Ug,burnInTool:y.NR,saturationTool:y.jG,penTool:y.ET,redEyeTool:y.z$,freeformPenTool:y.o4,rulerTool:y.Rp,paintbrushTool:y.zq,handTool:y.pX,pencilTool:y.uX,zoomTool:y.Nt,objectSelectTool:y.a8k,healingBrushTool:y.e$,patchTool:y.FS,contentAwareMoveTool:y.i5,colorReplacementBrushTool:y.YL,curvaturePenTool:y.a76,rotareViewTool:y._E};
if(X=="Lyr"){var G=I.selectionModifier,V=G?G.v.selectionModifierType:null,T=cq.zN(D,a[0]),R=0;if(T==-1){alert("Layer "+a[0].v.val+" does not exist.");
return}var C=D.C[T];if(C.ue()&&C._N()&&G==null)R=1;M.data={d:h.Gz,j:T,y$:V?["addToSelection","addToSelectionContinuous"].indexOf(V):null,LM:R}}else if(X=="Path"){if(a[0].v.keyID=="WrPt"){D.rs=[0];
D.tL=D.RP=!0;return}else throw a[0]}else if(X=="Chnl"){M.data={d:h.Gz,j:T,LM:a&&a[0].v.enum=="RGB"?0:1}}else if(X=="Dcmn"){if(n.oZ.length<2)return;
m.data={d:b.c.a61,dir:I.null.v[0].v.val}}else if(X=="Brsh"){var x=W.t$.list,v;for(var L=0;L<x.length;
L++){if(x[L].v.Nm.v==a[0].v.val)v=x[L].v}m.data={d:b.c.oj,AH:bk.ef,UT:v}}else if(X=="Mn"){if(a[0].v.enum=="Scl")m.data={d:b.c.CV,G:y.Sv,LQ:{IZ:3}};
if(a[0].v.enum=="Plce")m.data={d:b.c.J0,awp:!0};if(a[0].v.enum=="ZmIn"){M.G=y.Nt;M.data={d:"zoom",pZ:!0}}if(a[0].v.enum=="ZmOt"){M.G=y.Nt;
M.data={d:"zoom",pZ:!1}}if(a[0].v.enum=="FtOn"){M.G=y.Nt;M.data={d:"adapt",Z:"fitscr"}}}else if(S[X]){m.data={d:b.c.CV,G:S[X]}}else throw X}else if(j=="draw"){M.G=y.Au;
M.data={d:"fromAction",bs:w}}else if(j=="gradientClassEvent"){M.G=y.ZI;M.data={d:"fromAction",bs:w}}else if((j=="set"||j=="reset"||j=="exchange")&&X=="Clr"){m.data={d:b.c.oj,AH:bk.X$,vK:j=="reset"?3:2};
if(j=="set"){m.data.vK=a[0].v.keyID=="FrgC"?0:1;var N=E.M.y_(I.T.v);m.data.Z=N.o<<16|N.B<<8|N.k}}else if(j=="set"){if(X=="AdjL"){var u=I.T.v.classID;
u=eH.Nn[u];M.G=y.DW;if(u)M.data={d:"edit_layer",Z:I.T.v}}else if(X=="Lyr"){var H=I.T.v,T=cq.zN(D,a[0]);
for(var F in H){if(F=="classID")continue;M.G=y.Yu;if(F=="Nm")M.data={d:h.Bl,name:H.Nm.v};else if(F=="Opct")M.data={d:h.JM,qY:Math.round(H.Opct.v.val*255/100)};
else if(F=="fillOpacity")M.data={d:h.p6,qY:Math.round(H.fillOpacity.v.val*255/100)};else if(F=="Md")M.data={d:h.jC,qY:dD.ik.indexOf(H.Md.v.BlnM)+(D.C[T].ue()?1:0)};
else if(F=="Usrs")M.data={d:h._9,j:T};else if(F=="Blnd"){M.G=y.EA;M.data={d:"setstl",j:T,Z:{blendOptions:{t:"objc",v:H}}};
n.S(M);M.data={d:"confirm",j:T}}else if(F=="userMaskFeather"||F=="userMaskDensity"){var t=H.userMaskFeather,o=H.userMaskDensity,T=D.g[0],q=D.C[T].c3(0);
if(t)q.dK=t.v.val;if(o)q.ij=o.v.val;M.data={d:h.vE,hB:T,KP:q}}else if(F=="Clr"){var f=cq.Qs(H);M.data={d:h.HT,ayZ:f}}else if(F=="Lefx")cq.acq(n,T,H.Lefx.v,W);
else{console.log(I);throw F}if(M.data){n.S(M);delete M.data}}M.data={};var C=D.C[T];C.abc()}else if(X=="Prpr"){var H=JSON.parse(JSON.stringify(I.T.v)),T=cq.zN(D,I.null.v[1]),C=D.C[T],_=a[0].v.keyID;
if(_=="TxtS"||_=="paragraphStyle"){var d=C.add.TySh,r=JSON.parse(JSON.stringify(d._o)),p=hd.Bb(r),Q=hd.tG(r,0,p.length-2);
if(_=="TxtS")hd.a6B(H,Q);else hd.a51(H,Q);hd.g0(r,0,p.length-1,Q);M.G=y.Lu;M.data={d:"newED",$Z:T,xw:r}}else if(_=="Lefx"){for(var B in H)if(H[B].v){if(B=="Scl")H[B].v.val=100}cq.acq(n,T,H,W);
M.data={}}else throw _}else if(X=="contentLayer"){var T=cq.zN(D,a[0]),H=I.T.v;if(H.classID=="shapeStyle")H=H.FlCn.v;
var i={solidColorLayer:0,gradientLayer:1,patternLayer:2}[H.classID],c=y.rK.wj(D,T),k=c.oq==i+1?c.S8:at.Iz[i];
k=JSON.parse(JSON.stringify(k));y.G$.xk(H,k,i);M.data={d:h.Q2,G1:[T],Mr:!0,Z:{oq:i+1,S8:k}}}else if(X=="Brsh"){var v=JSON.parse(JSON.stringify(W.t$.lH)),h2=I.T.v;
if(h2.masterDiameter)v.Brsh.v.Dmtr.v.val=h2.masterDiameter.v.val;else console.log("unknown brush parameters");
m.data={d:b.c.oj,AH:bk.ef,UT:v}}else if(X=="Path"){M.G=y.Au;M.data={d:"fromAction",bs:w}}else{console.log(a[0],I);
throw X}}else if(j=="move"){if(X=="Lyr"){var H=I.T.v;if(H.classID=="Ofst"){M.data={d:"trsl",Bi:H.Hrzn.v.val,ah:H.Vrtc.v.val};
M.G=y.Rv}else{var jX,bm;if(H[0].t=="Enmr"){if(H[0].v.enum=="Frnt")bm=0;else if(H[0].v.enum=="Nxt")bm=1;
else if(H[0].v.enum=="Prvs")bm=2;else if(H[0].v.enum=="Back")bm=3;else throw"e"}else jX=H[0].v.val;M.data={d:h.iv,target:jX,vK:bm,axD:I.Dplc?I.Dplc.v:!1}}}else if(X=="Chnl"&&a[0].v.keyID=="fsel"){M.G=y.wA;
M.data={d:"fromAction",bs:w}}}else if(j=="groupEvent"||j=="ungroup")M.data={d:h.Yt};else if(j=="show"||j=="hide"){var dC=a[0].v;
for(var L=0;L<dC.length;L++){var fn=dC[L],X=fn.v.classID;if(X=="Lyr"){if(M.data==null)M.data={d:h.Ll,G1:[]};
var T=cq.zN(D,fn);if(T==-1)continue;var fK=D.C[T].I4();if(j=="show"&&fK||j=="hide"&&!fK)continue;M.data.G1.push(T)}else if(X=="Chnl"){M.data={d:h.QE,vK:"fromAction",Z:w}}else if(X=="filterFX"){if(fn.v.val!=null)M.data={d:h.GG,index:fn.v.val-1};
M.data={d:h.lf}}}}else if(j=="rotateEventEnum"){M.G=X=="Lyr"?y.Sv:y.xA;var i6=I.Angl.v.val;M.data={d:"rot",s7:[2,5],Z:-i6*Math.PI/180}}else if(j=="flip"){M.G=X=="Lyr"?y.Sv:y.xA;
var dh=I.Axis.v.Ornt=="Hrzn",kA=dh?new ec(-1,1):new ec(1,-1);M.data={d:"scl",s7:[[2,6],[22,4,dh?2:3]],Z:kA}}else if(j=="transform"){var ig=1,iJ=1,fL=0,fB=0,ah=0,eS=0,gL=0,gb=null,gx=null;
if(I.Wdth)ig=I.Wdth.v.val/100;if(I.Hght)iJ=I.Hght.v.val/100;if(I.Skew){var c2=I.Skew.v;fL=c2.Hrzn.v.val;
fB=c2.Vrtc.v.val}if(I.Ofst){var jS=I.Ofst.v;eS=jS.Hrzn.v.val;gL=jS.Vrtc.v.val}if(I.Angl)ah=I.Angl.v.val;
var ie=new eh;ie.concat(new eh(ig,ig*Math.tan(fB*Math.PI/180),iJ*Math.tan(fL*Math.PI/180),iJ,0,0));ie.rotate(-ah*Math.PI/180);
ie.translate(eS,gL);var as=E.K.yT(ie);if(I.Usng){var jS=I.Usng.v;as[6]=jS.Hrzn.v.val/100;as[7]=jS.Vrtc.v.val/100}var eo=I.FTcs.v.QCSt;
if(eo=="Qcsi"){var di=I.Pstn.v;gb=new ec(di.Hrzn.v.val,di.Vrtc.v.val)}else gx=y.wR.axK[eo];var a=I.null;
if(a&&a.v instanceof Array)a=a.v[0];var T=a?cq.zN(D,a):null;if(T==-1)T=null;M.G=a&&a.v.keyID=="fsel"?y.Zt:y.Sv;
M.data={d:"dtr",Zl:gx,Z:as,gz:I.warp,aik:gb}}else if(j=="duplicate"){if(X=="Chnl")M.data={d:h.QE,vK:"fromAction",Z:w};
else M.data={d:h.R6,np:I.Nm?I.Nm.v:null}}else if(j=="delete"){if(X=="filterFX"){if(a[0].v.val!=null)M.data={d:h.jX,cf:a[0].v.val-1};
else M.data={d:h.fE}}else if(X=="Path"){M.G=y.Au;M.data={d:"pathedit",vK:"del"}}else if(X=="Lyr")M.data={d:h.du};
else if(X=="Chnl"&&a[0].v.enum=="Msk")M.data={d:h.kR};else if(X=="Chnl")M.data={d:h.QE,vK:"fromAction",Z:w};
else throw X}else if(j=="align"){if(I.Aply&&I.Aply.v.projection=="Auto"){M.G=y.xA;M.data={d:"auto-align"}}else{M.G=y.Rv;
var d0=I.Usng.v.ADSt,g={AdLf:0,AdCH:1,AdRg:2,AdTp:4,AdCV:5,AdBt:6}[d0];if(g==null)throw d0;M.data={d:"algn",Z:g}}}else if(j=="applyLocking"){var e6=I.layerLocking.v,dt;
if(e6.protectTransparency)dt=[[e6.protectTransparency.v],[0]];else if(e6.protectNone)dt=[[!1,!1,!1,!1],[0,1,2,31]];
else{console.log(e6);throw"e"}M.data={d:h.ge,qY:dt}}if(M.data)n.S(M);else if(m.data)n.S(m);else{console.log(w);
alert("Unknown action \""+j+"\"");throw"e"}};cq.acq=function(w,n,W,D){W=JSON.parse(JSON.stringify(W));
dR.ml(W);if(W.masterFXSwitch==null)W.masterFXSwitch={t:"bool",v:!0};console.log(W);var j=at.Pa;for(var I=0;
I<j.length;I++)if(W[j[I]]){for(var L=0;L<W[j[I]].v.length;L++){var U=W[j[I]].v[L].v,M=U.TrnS;if(M==null)M=U.MpgS;
if(M&&M.v.Crv==null){var m=M.v,l=m.Nm.v.split("=").pop(),A=D.h$;for(var g=0;g<A.length;g++){var k=A[g].Nm.v.split("=").pop();
if(k==l)m.Crv=JSON.parse(JSON.stringify(A[g].Crv))}if(M.v.Crv==null){console.log(M);throw"e"}}}}var $=new ed(b.E.v,!0);
$.G=y.EA;$.data={d:"setstl",j:n,Z:{Lefx:{t:"objc",v:W}}};w.S($);$.data={d:"confirm",j:n};w.S($)};cq.Qs=function(w){var n={None:0,Rd:1,Orng:2,Ylw:3,Grn:4,Bl:5,Vlt:6,Gry:7}[w.Clr.v.Clr];
if(n==null)throw w.Clr.v.Clr;return n};cq.zN=function(w,n){var W=1e6,D=0,j=w.C.length;for(var L=0;L<w.g.length;
L++){W=Math.min(W,w.g[L]);D=Math.max(D,w.g[L])}var I=n.t,U=-1;if(I=="name"){var M=n.v.val,U=-1;for(var L=0;
L<j;L++)if(w.C[L].getName()==M){U=L;break}}else if(I=="Enmr"){if(w.g.length!=0)U=w.g[0];if(n.v.enum=="Frwr")U=D+1;
if(n.v.enum=="Bckw")U=W-1;if(n.v.enum=="Back")U=0;if(n.v.enum=="Frnt")U=j-1;U=(U+j)%j}else if(I=="prop"){if(n.v.keyID=="Bckg")U=0}return U};
var eH={};eH.names={brit:[4,0],levl:[4,1],curv:[4,2],expA:[4,3],vibA:[4,4],hue2:[4,5],blnc:[4,6],blwh:[4,7],phfl:[4,8],mixr:[4,9],clrL:[4,10],nvrt:[4,11],post:[4,12],thrs:[4,13],grdm:[4,14],selc:[4,15],rplc:[4,17]};
eH.aoW=["expA","clrL","selc"];eH.Nv=[[13,1,1],[13,1,3],[13,1,4],[13,1,11],[13,1,5],[13,1,12]];eH.a1c=[[13,1,11],[13,1,12],[13,1,3],[13,1,10]];
eH.RU=[[13,1,1],[13,1,4],[13,1,5]];eH.SM={BrgC:"brit",Lvls:"levl",Crvs:"curv",Exps:"expA",vibrance:"vibA",HStr:"hue2",ClrB:"blnc",BanW:"blwh",photoFilter:"phfl",Invr:"nvrt",Pstr:"post",Thrs:"thrs",GrMp:"grdm",SlcC:"selc",ChnM:"mixr",colorLookup:"clrL",rplc:"rplc"};
eH.Nn=function(){var w=JSON.parse(JSON.stringify(eH.SM));delete w.GrMp;w.GdMp="grdm";return w}();eH.Hc={brit:"brightnessEvent",levl:"levels",curv:"curves",expA:"exposure",vibA:"vibrance",hue2:"hueSaturation",blnc:"colorBalance",blwh:"blackAndWhite",phfl:"photoFilter",mixr:"channelMixer",clrL:"colorLookup",nvrt:"invert",post:"posterization",thrs:"thresholdClassEvent",grdm:"gradientMapEvent",selc:"selectiveColor",rplc:"replaceColor"};
eH.keys={levl:[aK.CQ,aK.zP],curv:[aK.CQ,aK.$g],hue2:[aK.CQ,aK.Eg],nvrt:[aK.CQ,aK.Zb],blnc:[aK.CQ,aK.T2]};
eH.a3Z=function(w){var n=cx._1("mixr");n.Mnch={t:"bool",v:w.jD};function W(D,L){var j={classID:"ChMx"},I={Rd:0,Grn:1,Bl:2,Cnst:4};
for(var U in I)j[U]={t:"UntF",v:{type:"#Prc",val:D[L+I[U]]}};return{t:"Objc",v:j}}if(w.jD)n.Gry=W(w.Z,0);
else{n.Rd=W(w.Z,0);n.Grn=W(w.Z,5);n.Bl=W(w.Z,10)}return n};eH.hm=function(w){function n(D,j,L){var I={Rd:0,Grn:1,Bl:2,Cnst:4};
for(var U in I)if(D[U])j[L+I[U]]=D[U].v.val}var W={jD:!1,Z:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]};
if(w.Mnch&&w.Mnch.v)W.jD=!0;if(W.jD)n(w.Gry.v,W.Z,0);else{n(w.Rd.v,W.Z,0);n(w.Grn.v,W.Z,5);n(w.Bl.v,W.Z,10)}return W};
eH.get=function(w){for(var n in eH.names)if(w[n]!=null)return n;return null};eH.rw=function(w,n){var W=eH.$V,D;
if(w=="brit"){var j=n.Brgh?n.Brgh.v:0,I=n.Cntr?n.Cntr.v:0,U=n.useLegacy?n.useLegacy.v:!1;if(U){var M=j/255,m=1+I/100;
if(m>1)m=1+Math.tan(Math.PI/2*I/101);var l=(1-m)/2,A=E.Mv.CD(M,M,M),g=[m,0,0,l,0,m,0,l,0,0,m,l,0,0,0,1],k=E.Mv.multiply(g,A),$=new E.H0(256);
for(var L=0;L<256;L++)$.o[L]=L;E.Mv.transform($,$,k);D={type:W.Pq,UX:$.o,D4:$.o,ZA:$.o,iA:!1,gd:!1}}else{var C=1024,f=-30+60*(I+100)/200,z=[];
for(var L=0;L<4;L++)z.push(E.MU.$j(L/3*255,L/3*255,!0));z[1].v.Hrzn.v=64;z[1].v.Vrtc.v=64-f;z[2].v.Hrzn.v=128+64;
z[2].v.Vrtc.v=128+64+f;z.sort(function(cy,hA){return cy.v.Hrzn.v-hA.v.Hrzn.v});var s=E.MU.I5(z,C);function O(cy,C){var z=[],bK=3;
for(var L=0;L<bK+1;L++)z.push(E.MU.$j(L/bK*255,L/bK*255,!0));z[1].v.Hrzn.v=130-cy*26;z[1].v.Vrtc.v=130+cy*51;
z[2].v.Hrzn.v=233-cy*48;z[2].v.Vrtc.v=233+cy*10;return E.MU.I5(z,C)}var a=O(Math.abs(j)/100,C);if(j<0){var X=[],P=1/C;
for(var L=0;L<C;L++){var Z=L*P,Y=L;while(a[Y]>Z&&Y>1)Y--;X[L]=Y*P}a=X}var K=new Uint8Array(C);for(var L=0;
L<C;L++){var S=Math.round((C-1)*a[L]);K[L]=Math.round(255*s[S])}D={type:W.Pq,UX:K,D4:K,ZA:K,iA:!1,gd:!1}}}if(w=="levl"){var G=[],V,T,A,R,x,v;
for(var L=0;L<4;L++)G.push(il.Qw(n,L));V=-G[0][0]/255;T=1/(G[0][1]/255-G[0][0]/255);A=E.Mv.multiply(E.Mv.Os(T,T,T),E.Mv.CD(V,V,V));
R=E.Mv.Os(1/(G[1][1]/255-G[1][0]/255),1/(G[2][1]/255-G[2][0]/255),1/(G[3][1]/255-G[3][0]/255));x=E.Mv.CD(-G[1][0]/255,-G[2][0]/255,-G[3][0]/255);
v=E.Mv.multiply(R,x);var K=new E.H0(256);for(var L=0;L<256;L++)K.o[L]=K.B[L]=K.k[L]=L;var N=1/(G[0][4]/100),u=1/(G[1][4]/100),H=1/(G[2][4]/100),F=1/(G[3][4]/100);
E.Mv.transform(K,K,v);for(var L=0;L<256;L++){K.o[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.o[L]/255,u))));
K.B[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.B[L]/255,H))));K.k[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.k[L]/255,F))))}E.Mv.transform(K,K,A);
for(var L=0;L<256;L++){K.o[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.o[L]/255,N))));K.B[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.B[L]/255,N))));
K.k[L]=Math.round(Math.max(0,Math.min(255,255*Math.pow(K.k[L]/255,N))))}V=G[0][2]/255;T=G[0][3]/255-G[0][2]/255;
A=E.Mv.multiply(E.Mv.CD(V,V,V),E.Mv.Os(T,T,T));R=E.Mv.Os(G[1][3]/255-G[1][2]/255,G[2][3]/255-G[2][2]/255,G[3][3]/255-G[3][2]/255);
x=E.Mv.CD(G[1][2]/255,G[2][2]/255,G[3][2]/255);v=E.Mv.multiply(x,R);E.Mv.transform(K,K,E.Mv.multiply(A,v));
D={type:W.Pq,UX:K.o,D4:K.B,ZA:K.k,iA:!1,gd:!1}}if(w=="curv"){var t=e0.Qw(n,0).length==256?1:0,o=[];if(t==0){var q=E.MU.ou(e0.Qw(n,0),256);
for(var L=1;L<4;L++){var _=E.MU.ou(e0.Qw(n,L),256);o.push(E.MU.Ao(_,q))}}else{var d=[];for(var L=0;L<4;
L++){var r=new Uint8Array(256);d.push(r);var p=e0.Qw(n,L);for(var Y=0;Y<256;Y++)r[Y]=p[Y]}for(var L=1;
L<4;L++)o.push(E.MU.Ao(d[L],d[0]))}D={type:W.Pq,UX:o[0],D4:o[1],ZA:o[2],iA:!1,gd:!1}}if(w=="expA"){var Q=n.Exps,B=n.Ofst,i=n.gammaCorrection,c=Q?Q.v:0,h2=B?B.v:0,jX=i?i.v:1,K=new Uint8Array(256);
for(var L=0;L<256;L++){var n=L/255,bm=Math.pow(Math.abs(h2),1/(Math.PI/2));if(h2>0){n=Math.max(h2/Math.E,n);
n=n*Math.exp(h2/1.75+c/Math.PI);n=(1-bm)*n+bm*1}else{n=n*Math.exp(-h2*1.75+c/Math.PI);n=n+-bm*1.14}n=Math.pow(n,1/jX);
n=Math.max(0,Math.min(1,n));K[L]=Math.round(n*255)}D={type:W.Pq,UX:K,D4:K,ZA:K,iA:!1,gd:!1}}if(w=="vibA"){var dC=(n.vibrance?n.vibrance.v:0)/100,fn=(n.Strt?n.Strt.v:0)/100,bm=1+dC*(dC>0?.25:.5),fK=.8+.2/bm;
D={type:W.T0,AH:[dC,fn,fK,bm]}}if(w=="hue2"){var i6=[],dh=[],kA=[],ig=n.Clrz?n.Clrz.v:!1;for(var L=0;
L<256;L++){i6[L]=L/255;dh[L]=0;kA[L]=0}var iJ=cT.Qw(n,0),fL=eH.a3(iJ[1]/100);if(ig){var fB=iJ[0]/360;
for(var L=0;L<256;L++){i6[L]=fB;dh[L]=fL}}else{for(var L=0;L<256;L++){var ah=i6[L],eS=dh[L];i6[L]+=iJ[0]/360;
for(var Y=0;Y<6;Y++){var gL=cT.Qw(n,Y+1),e_=gL.Lh,c2=gL.k0,bm=0;for(var jS=1;jS<4;jS++)if(c2[jS]<c2[0])c2[jS]+=360;
var ie=c2[0],as=c2[1],gb=c2[2],gx=c2[3],eo=ah*360;if(eo<c2[0])eo+=360;var di=(eo-ie)/(as-ie),d0=(eo-gb)/(gx-gb);
if(di<0)bm=0;else if(di<1)bm=di;else if(d0<0)bm=1;else if(d0<1)bm=1-d0;else bm=0;var m=eH.a3(e_[1]/100);
i6[L]+=bm*e_[0]/360;dh[L]+=bm*m;kA[L]+=bm*e_[2]/100}}for(var L=0;L<256;L++){dh[L]=(1+dh[L])*(1+fL)-1;
kA[L]=Math.max(-1,Math.min(1,kA[L]))}}var e6=new Uint8Array(256),dt=new Uint8Array(256),gJ=new Uint8Array(256);
for(var L=0;L<256;L++){var iW=i6[L],fn=dh[L],g5=kA[L];if(iW>1)iW--;if(iW<0)iW++;fn=eH.aAA(fn);fn=(1+fn)*.5;
g5=(1+g5)*.5;e6[L]=Math.round(255*iW);dt[L]=Math.round(255*fn);gJ[L]=Math.round(255*g5)}var jW=iJ[2]/100,eP=jW<0?-jW:jW,b_=jW<0?0:1;
D={type:W.yX,a3M:e6,rl:dt,az$:gJ,anD:eP*b_,AZ:1-eP,abN:iJ[2]/100,apK:ig?1:0}}if(w=="nvrt"){var K=new Uint8Array(256);
for(var L=0;L<256;L++)K[L]=255-L;D={type:W.Pq,UX:K,D4:K,ZA:K,iA:!1,gd:!1}}if(w=="post"){var fZ=n.Lvls.v,K=new Uint8Array(256),bm=fZ/255.001,im=255/(fZ-1);
for(var L=0;L<256;L++)K[L]=Math.floor(L*bm)*im;D={type:W.Pq,UX:K,D4:K,ZA:K,iA:!1,gd:!1}}if(w=="grdm"){var j3=n.Grad.v,dr=n.Rvrs,C=1024,c0;
if(j3.Clrs){var fM=E.M.oR(j3,0,0);c0=E.M.P7(j3,fM,C,dr?dr.v:!1)}else{c0=E.M.Fc(j3,C,dr?dr.v:!1)}var cB=E.Q(C),iI=E.Q(C),jD=E.Q(C);
E.hN(c0,cB,0);E.hN(c0,iI,1);E.hN(c0,jD,2);D={type:W.Pq,UX:cB,D4:iI,ZA:jD,iA:!0,gd:!1}}if(w=="selc"){var j8=new Float32Array(9*3*2),jG=n.pF,i1=n.Mthd?n.Mthd.v.CrcM=="Absl":!1;
for(var Y=0;Y<9;Y++){var bH=Y*6,a_=av.Qw(n,Y),aR=a_[0]/100,iY=a_[1]/100,gy=a_[2]/100,gr=a_[3]/100;if(i1){j8[bH]=j8[bH+1]=j8[bH+2]=1;
j8[bH+3]=aR*(1+gr)+gr;j8[bH+4]=iY*(1+gr)+gr;j8[bH+5]=gy*(1+gr)+gr}else{j8[bH+0]=(1+aR)*(1+gr);j8[bH+1]=(1+iY)*(1+gr);
j8[bH+2]=(1+gy)*(1+gr)}}D={type:W.yO,a7g:j8}}if(w=="blwh"){var fs="Rd Yllw Grn Cyn Bl Mgnt".split(" "),D=[],iz=0,en=0;
for(var L=0;L<6;L++)D.push(n[fs[L]].v);D.push(n.useTint.v,n.tintColor.v);var dQ=[];for(var L=0;L<6;L++)dQ.push((D[L]-50)/50);
var ep=E.M.y_(D[7]);ep.o/=255;ep.B/=255;ep.k/=255;var b2=E.i8(ep.o,ep.B,ep.k),g5=E.Mg(E.P4(b2.ag,1,.5)),eX=b2._6*b2.jB;
if(g5==.5)iz=en=.5;else{iz=eX*(.5-g5)/(.5/g5-1);en=1-eX*(.5-g5)-1/(2*(1-g5));en/=1-1/(2*(1-g5))}D={type:W.mM,av9:dQ,fH:D[6]?1:0,a2H:b2.ag,Mg:g5,agZ:eX,DS:iz,a0b:en}}if(w=="blnc"){var G=[],ko=["ShdL","MdtL","HghL"];
for(var L=0;L<3;L++){if(n[ko[L]]==null){G[L]=[0,0,0];continue}var fZ=n[ko[L]].v,fh=fZ[0].v/100,d1=fZ[1].v/100,j_=fZ[2].v/100,h9=n.PrsL==null||n.PrsL.v?(Math.min(fh,d1,j_)+Math.max(fh,d1,j_))/2:0;
G[L]=[fh-h9,d1-h9,j_-h9]}var o=[E.Q(256),E.Q(256),E.Q(256)];for(var Y=0;Y<3;Y++)for(var L=0;L<256;L++){var Z=L*(1/255),ha=0,f=0,fl=0;
f=G[2][Y];fl=Math.abs(f);if(f<0)ha=Math.pow(Z,Math.SQRT2);else ha=1.63*(Math.pow(Z+.04,.5)-.2);Z=fl*ha+(1-fl)*Z;
f=G[1][Y];fl=Math.abs(f);if(f<0)ha=Math.pow(Z,2);else ha=Math.min(2.35*(Math.pow(Z+.09,.5)-.3),Math.pow(Z,1/2));
Z=fl*ha+(1-fl)*Z;f=G[0][Y];fl=Math.abs(f);if(f<0)ha=Z<.4?0:Math.pow((Z-.4)/.6,Math.SQRT2);else ha=Math.pow(Z,Math.SQRT2/2);
Z=fl*ha+(1-fl)*Z;Z=Math.max(0,Math.min(1,Z));o[Y][L]=Math.round(Z*255)}D={type:W.Pq,UX:o[0],D4:o[1],ZA:o[2],iA:!1,gd:!1}}if(w=="phfl"){var ex=E.M.y_(n.Clr.v),aI=[ex.o/255,ex.B/255,ex.k/255],ba=n.Dnst.v/100,o=[E.Q(256),E.Q(256),E.Q(256)];
for(var Y=0;Y<3;Y++)for(var L=0;L<256;L++){var Z=L*(1/255),ik=Z*aI[Y];ik=Math.max(0,Math.min(1,ik));
Z=ba*ik+(1-ba)*Z;o[Y][L]=Math.round(Z*255)}D={type:W.Pq,UX:o[0],D4:o[1],ZA:o[2],iA:!1,gd:n.PrsL.v}}if(w=="thrs"){var K=E.Q(256);
for(var L=n.Lvl.v;L<256;L++)K[L]=255;D={type:W.Pq,UX:K,D4:K,ZA:K,iA:!0,gd:!1}}if(w=="mixr"){var c3=eH.hm(n),k=[];
for(var L=0;L<c3.Z.length;L++)if(L%5!=3)k.push(c3.Z[L]/100);if(c3.jD){for(var br=1;br<3;br++)for(var Z=0;
Z<4;Z++)k[br*4+Z]=k[Z]}D={type:W.TR,GY:k}}if(w=="rplc"){var bi=n.Mnm.v,cZ=n.Mxm.v;D={type:W.da,x8:[bi.Lmnc.v,bi.A.v,bi.B.v],wI:[cZ.Lmnc.v,cZ.A.v,cZ.B.v],shift:[n.H.v/360,n.Strt.v/100,n.Lght.v/100],$e:n.Fzns.v/150}}if(w=="clrL"&&n.profile){var ib=new Uint8Array(n.profile.v),hb=ICC.R(ib.buffer),kg=[],kh=17,kg=ICC.U.sampleLUT(hb,kh);
D={type:W.l0,Ey:ICC.U.lutToRGBA8(kg,kh),aiY:kg,r1:kh}}return D};eH.Zk=function(w,n){var W=-1;if(w!="levl"||n==null)W=-1;
else if(n.Auto)W=0;else if(n.AuCo)W=1;else if(n.autoBlackWhite)W=2;return W};eH.$V={Pq:0,yX:1,T0:2,yO:3,mM:4,TR:5,da:6,l0:7};
eH.a3=function(w){if(w<0)return w;return Math.pow(Math.tan(Math.PI/2*w),1.3)};eH.aAA=function(w){if(w<0)return w;
w=Math.pow(w,1/1.3);return Math.atan2(w,1)/(Math.PI/2)};eH.Ld=function(w,n,W,D){var j=eH.$V,I=Date.now();
if(je.YG&&D.O()>300*300&&w.type!=j.Pq&&w.type!=j.l0){D=D.clone();D.x=D.y=0;var U=je.vL(0,D.m,D.n);U.set(n);
je.t5(U,D);U.Le(D);eH.zj(w,U.Ef,D);U.get(W);return}if(w.type==j.l0){var M=w.aiY,m=w.r1;ICC.U.applyLUT(M,m,n,W);
var l=n.length;for(var L=0;L<l;L+=4)W[L+3]=n[L+3]}if(w.type==j.TR)E.Mv.V9(n,W,w.GY);if(w.type==j.mM){var A=w.agZ,g=w.Mg,k=w.DS,$=w.a0b,l=n.length;
for(var L=0;L<l;L+=4){var D=n[L]*(1/255),C=n[L+1]*(1/255),f=n[L+2]*(1/255),z=E.AO(D,C,f),s=0;for(var O=0;
O<6;O++)s+=Math.min(1,1.7*(1-z.EO))*z._6*w.av9[O]*eH.amt(z.ag,O*(1/6));var a=Math.max(0,Math.min(1,z.EO*(1+s)));
if(w.fH==1){var X=0;if(a<k)X=a*(.5/g);else if(a<$)X=a+A*(.5-g);else X=1-(1-a)*.5/(1-g);z.ag=w.a2H;z._6=Math.min(1,A+3*A*Math.abs(a-.5*(k+$)));
z.EO=X}else{z.ag=0;z._6=0;z.EO=a}var P=E.P4(z.ag,z._6,z.EO);W[L]=Math.round(P.o*255);W[L+1]=Math.round(P.B*255);
W[L+2]=Math.round(P.k*255)}}if(w.type==j.yO){var Z=w.a7g,l=n.length,Y=1/255;for(var L=0;L<l;L+=4){var D=n[L]*Y,C=n[L+1]*Y,f=n[L+2]*Y,z=E.AO(D,C,f),K=Math.max(D,Math.max(C,f)),S=Math.min(D,Math.min(C,f)),G=1-D,V=1-C,T=1-f,R=0,x=0,v=0;
for(var O=0;O<9;O++){var N=O*6,t=0;if(Z[N]==1&&Z[N+1]==1&&Z[N+2]==1&&Z[N+3]==0&&Z[N+4]==0&&Z[N+5]==0)continue;
var u=G*Z[N]+Z[N+3],H=V*Z[N+1]+Z[N+4],F=T*Z[N+2]+Z[N+5];if(O<6)t=eH.amt(z.ag,O*(1/6))*z._6*2*Math.min(z.EO,1-z.EO);
else if(O==6)t=Math.max(0,S-.5)*2;else if(O==7)t=1-(Math.abs(K-.5)+Math.abs(S-.5));else t=Math.max(0,.5-K)*2;
R+=(Math.max(0,Math.min(1,u))-G)*t;x+=(Math.max(0,Math.min(1,H))-V)*t;v+=(Math.max(0,Math.min(1,F))-T)*t}G=Math.max(0,Math.min(1,G+R));
V=Math.max(0,Math.min(1,V+x));T=Math.max(0,Math.min(1,T+v));D=1-G;C=1-V;f=1-T;W[L]=Math.round(D*255);
W[L+1]=Math.round(C*255);W[L+2]=Math.round(f*255)}}if(w.type==j.Pq){E.a8M(n,W,w.UX,w.D4,w.ZA,w.iA,w.gd)}if(w.type==j.yX){var o=new Uint32Array(n.buffer),q=new Uint32Array(W.buffer),l=o.length;
if(eH.i1==null){eH.i1=new Float64Array(256);for(var L=0;L<256;L++)eH.i1[L]=eH.a3(-1+2*L/255)}var _=eH.i1;
for(var L=0;L<l;L++){var d=o[L],D=(d&255)*(1/255),C=(d>>>8&255)*(1/255),f=(d>>>16&255)*(1/255),r=d>>>24,p=Math.min(D,C,f),Q=Math.max(D,C,f),B=0,i=0,c=0;
B=E.AO(D,C,f).ag;var h2=~~(B*255+.5),jX=w.a3M[h2]*(1/255),bm=w.rl[h2]*(1/255)*2-1,dC=w.az$[h2]*(1/255)*2-1,s=-dC,fn=p;
if(0<dC){s=dC;fn=Q}var fK=w.anD+w.AZ*s*fn,i6=w.AZ*(1-s);D=fK+i6*D;C=fK+i6*C;f=fK+i6*f;Q=Math.max(D,C,f);
p=Math.min(D,C,f);c=(Q+p)*.5;if(Q!=p){var dh=Q-p;i=c>.5?dh/(2-(Q+p)):dh/(Q+p)}var kA=bm;if(w.apK==0){bm=_[Math.floor((1+bm)*127.5)];
kA=Math.min(i*(1+bm),1)}var P=E.P4(jX,kA,c);D=P.o;C=P.B;f=P.k;q[L]=r<<24|f*255<<16|C*255<<8|D*255}}if(w.type==j.da){E.nX(n,W);
var o=new Uint32Array(n.buffer),q=new Uint32Array(W.buffer),l=o.length,ig=w.$e,iJ=1/ig,fL={zP:w.x8[0],dl:w.x8[1],k:w.x8[2]},fB={zP:w.wI[0],dl:w.wI[1],k:w.wI[2]};
for(var L=0;L<l;L++){var d=o[L],ah=d&255,eS=d>>>8&255,gL=d>>>16&255,D=ah*(1/255),C=eS*(1/255),f=gL*(1/255),r=d>>>24,e_=E.gK(ah,eS,gL),c2=E.fA(e_,fL,fB,ig,iJ);
if(c2==0)continue;var z=E.AO(D,C,f),jX=2+z.ag+w.shift[0];z.ag=jX-~~jX;z._6=Math.max(0,Math.min(1,z._6+w.shift[1]));
z.EO=Math.max(0,Math.min(1,z.EO+w.shift[2]));var P=E.P4(z.ag,z._6,z.EO);D=(1-c2)*D+c2*P.o;C=(1-c2)*C+c2*P.B;
f=(1-c2)*f+c2*P.k;q[L]=r<<24|f*255<<16|C*255<<8|D*255}}if(w.type==j.T0){var o=new Uint32Array(n.buffer),q=new Uint32Array(W.buffer),l=o.length,jS=w.AH[0],ie=w.AH[1],as=w.AH[2],s=w.AH[3],gb=E.Mv.Vr([.299,.587,.114,-.147,-.289,.436,.615,-.515,-.1]),gx=E.Mv.Ba(gb),eo=2.4;
function m(gJ){return Math.max(0,Math.min(1,gJ))}function di(gJ){return Math.pow(gJ,eo)}function d0(gJ){return Math.pow(gJ,1/eo)}function e6(D,C,f,gJ){D=di(D);
C=di(C);f=di(f);var iW=E.Mv.q4(gb,[D,C,f,1]);iW[0]*=as;iW[1]*=s;iW[2]*=s;var P=E.Mv.q4(gx,iW);P[0]=d0(m(P[0]));
P[1]=d0(m(P[1]));P[2]=d0(m(P[2]));return P}for(var L=0;L<l;L++){var d=o[L],D=(d&255)*(1/255),C=(d>>>8&255)*(1/255),f=(d>>>16&255)*(1/255),r=d>>>24,P=e6(D,C,f,jS);
D=P[0];C=P[1];f=P[2];var dt=E.AO(D,C,f);dt._6=Math.max(0,Math.min(1,dt._6*(1+ie)));P=E.P4(dt.ag,dt._6,dt.EO);
D=P.o;C=P.B;f=P.k;q[L]=r<<24|f*255<<16|C*255<<8|D*255}}};eH.zj=function(w,n,W){je.u4.zj(w,n)};eH.amt=function(w,n){var W=E.oC(n,w)*6;
return Math.max(0,Math.min(1,W<0?1+W:1-W))};var cx={};cx.iF=function(w){var n=w.filterID.v;return n>16777215?J.ahg(n):w.Fltr.v.classID};
cx.ie=[{S8:"GEfc"},{S8:"LnCr"},{S8:"Adobe Camera Raw Filter"},{S8:"LqFy",nW:!0},{A7:"3D",sj:["lightFilterGradient","Dila"]},{A7:[24,2],sj:"Avrg,Blr ,BlrM,boxblur,GsnB,Bokh,MtnB,RdlB,surfaceBlur".split(",")},{A7:[24,4],sj:"Dspl,Kale,Pnch,Plr ,Rple,Shr ,Sphr,Twrl,Wave,ZgZg".split(",")},{A7:[24,6],sj:["AdNs","Dspc","DstS","Mdn ","denoise"]},{A7:[24,8],sj:"ClrH,Crst,Frgm,Mztn,Msc ,Pntl".split(",")},{A7:[24,10],sj:["Flam","Clds","DfrC","Fbrs","LnsF"]},{A7:[24,12],sj:["Shrp","ShrE","ShrM","smartSharpen","UnsM"]},{A7:[24,14],sj:"Dfs ,Embs,FndE,oilPaint,Slrz,TrcC,Wnd ".split(",")},{A7:[24,16],sj:"HghP,HsbP,Mxm ,Mnm ,Ofst,Rept,Ctoa,Dthr,Part".split(",")},{A7:"Fourier",sj:["dDFT","iDFT"]}];
cx.Hc={LqFy:"LqFy",Avrg:"Avrg","Blr ":"blurEvent",BlrM:"blurMethod",boxblur:"boxblur",GsnB:"gaussianBlur",MtnB:"motionBlur",RdlB:"radialBlur",surfaceBlur:"surfaceBlur",lightFilterGradient:"lightFilterGradient",adaptCorrect:"adaptCorrect",Pnch:"pinch","Plr ":"polar",Rple:"ripple","Shr ":"shear",Sphr:"spherize",Twrl:"twirl",Wave:"wave",AdNs:"addNoise",DstS:"dustAndScratches","Mdn ":"median",denoise:"denoise",ClrH:"colorHalftone",Crst:"",Frgm:"",Mztn:"mezzotint","Msc ":"mosaic",Pntl:"",Flam:"",Clds:"clouds",DfrC:"differenceClouds",LnsF:"LnsF",Shrp:"sharpen",ShrM:"sharpenMore",smartSharpen:"smartSharpen",UnsM:"unsharpMask","Dfs ":"diffuse",FndE:"findEdges",oilPaint:"oilPaint","Adobe Camera Raw Filter":"Adobe Camera Raw Filter",HghP:"highPass","Mxm ":"maximum","Mnm ":"minimum",Ofst:"offset"};
cx.FT={AddNoise:"AdNs",Average:"Avrg",Blur:"Blr ",BlurMore:"BlrM",Clouds:"Clds",DifferenceClouds:"DfrC",DustAndScratches:"DstS",GaussianBlur:"GsnB",HighPass:"HghP",Maximum:"Mxm ",Minimum:"Mnm ",MotionBlur:"MtnB",Offset:"Ofst",Pinch:"Pnch",PolarCoordinates:"Plr ",Ripple:"Rple",Sharpen:"Shrp",SharpenMore:"ShrM",Twirl:"Twrl",UnsharpMask:"UnsM",Wave:"Wave",BrightnessContrast:"brit"};
cx.a={rigidTransform:y.gR};cx.names={lightFilterGradient:[24,17,8],rigidTransform:[10,46],LnCr:[24,1,1,0],LqFy:[24,1,0,0],GEfc:[24,0],Avrg:[24,3,0],"Blr ":[24,3,1],BlrM:[24,3,2],boxblur:[24,3,3],GsnB:[24,3,4],Bokh:[24,3,5],MtnB:[24,3,6],RdlB:[24,3,7],surfaceBlur:[24,3,10],Dspl:[24,5,0],Pnch:[24,5,1],"Plr ":[24,5,2],Rple:[24,5,3],"Shr ":[24,5,4],Sphr:[24,5,5],Twrl:[24,1,0,1,3],Wave:[24,5,6],ZgZg:[24,5,7],Kale:[24,5,8],AdNs:[24,7,0],Dspc:[24,7,1],DstS:[24,7,2],"Mdn ":[24,7,3],denoise:[24,7,4],ClrH:[24,9,0],Crst:[24,9,1],Frgm:[24,9,3],Mztn:[24,9,4],"Msc ":[24,9,5],Pntl:[24,9,6],Clds:[24,11,0],DfrC:[24,11,1],LnsF:[24,11,2],Flam:[24,11,3],Fbrs:[24,11,4],Shrp:[24,13,0],ShrE:[24,13,1],ShrM:[24,13,2],smartSharpen:[24,13,3],UnsM:[24,13,4],"Dfs ":[24,15,0],Embs:[24,15,1],FndE:[24,15,3],oilPaint:[24,15,4],Slrz:[24,15,5],TrcC:[24,15,6],"Wnd ":[24,15,7],HghP:[24,17,1],HsbP:"HSB/HSL","Mxm ":[24,17,2],"Mnm ":[24,17,3],Ofst:[24,17,4],Rept:[24,17,5],Ctoa:[24,17,6],Dthr:[12,23,3],Part:[24,17,7],dDFT:"Fourier Transform",iDFT:"Inverse Fourier Transform",defr:[2,13],Dila:"Texture Dilation",VaPo:"Vanishing Point",adaptCorrect:["VAR0/VAR1",[19,6,0],[19,6,2]],"Adobe Camera Raw Filter":"Camera Raw"};
cx._1=function(w){var n=null;if(w=="GEfc")n={__name:"Filter Gallery",classID:"GEfc",GEfs:{t:"VlLs",v:[{t:"Objc",v:ic._1("GlwE")}]}};
if(w=="LqFy"){var W={gA:5,ag:5,map:new Float32Array(5*5*2)},D=new Uint8Array(fH.Pj(W)),j=[];for(var L=0;
L<D.length;L++)j.push(D[L]);n={__name:"Liquify",classID:"LqFy",LqMe:{t:"tdta",v:j}}}if(w=="rigidTransform"){n={__name:"Puppet Warp",classID:"rigidTransform",null:{t:"obj ",v:[{t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Trgt"}}]},rigidType:{t:"bool",v:!0},puppetShapeList:{t:"VlLs",v:[]},PuX0:{t:"doub",v:0},PuX1:{t:"doub",v:1e3},PuX2:{t:"doub",v:1e3},PuX3:{t:"doub",v:0},PuY0:{t:"doub",v:0},PuY1:{t:"doub",v:0},PuY2:{t:"doub",v:1e3},PuY3:{t:"doub",v:1e3}}}if(w=="LnCr")n={__name:"Lens Correction",classID:"LnCr",LnAg:{t:"bool",v:!0},LnAc:{t:"bool",v:!1},LnAv:{t:"bool",v:!1},LnAs:{t:"bool",v:!1},LnIp:{t:"bool",v:!1},LnFo:{t:"doub",v:0},LnPr:{t:"TEXT",v:""},LnIa:{t:"doub",v:0},LnI0:{t:"doub",v:0},LnI1:{t:"doub",v:0},LnI2:{t:"doub",v:0},LnI3:{t:"doub",v:1},LnRa:{t:"doub",v:0},LnVp:{t:"doub",v:0},LnHp:{t:"doub",v:0},LnSi:{t:"doub",v:100},LnFt:{t:"long",v:2},LnSb:{t:"doub",v:0},LnSt:{t:"long",v:50},LnRc:{t:"doub",v:0},LnGm:{t:"doub",v:0},LnBy:{t:"doub",v:0},LnNa:{t:"long",v:64},LnIh:{t:"long",v:0},LnIv:{t:"long",v:0},LnIs:{t:"Objc",v:{classID:"RGBC",Rd:{t:"doub",v:127},Grn:{t:"doub",v:127},Bl:{t:"doub",v:127}}},LnNm:{t:"bool",v:!1}};
if(w=="adaptCorrect")n={__name:"Shadow/Highlight",classID:"adaptCorrect",sdwM:{t:"Objc",v:{__name:"Parameters",classID:"adaptCorrectTones",Amnt:{t:"UntF",v:{type:"#Prc",val:50}},Wdth:{t:"UntF",v:{type:"#Prc",val:25}},Rds:{t:"long",v:12}}},hglM:{t:"Objc",v:{__name:"Parameters",classID:"adaptCorrectTones",Amnt:{t:"UntF",v:{type:"#Prc",val:0}},Wdth:{t:"UntF",v:{type:"#Prc",val:0}},Rds:{t:"long",v:0}}},BlcC:{t:"doub",v:0},WhtC:{t:"doub",v:0},Cntr:{t:"long",v:0},ClrC:{t:"long",v:0}};
if(w=="Dfs ")n={__name:"Diffuse",classID:"Dfs",Md:{t:"enum",v:{DfsM:"Nrml"}},FlRs:{t:"long",v:14061024}};
if(w=="Fbrs")n={__name:"Fibers",classID:"Fbrs",Vrnc:{t:"long",v:10},Strg:{t:"long",v:1},RndS:{t:"long",v:8438429}};
if(w=="Embs")n={__name:"Emboss",classID:"Embs",Angl:{t:"long",v:45},Hght:{t:"long",v:5},Amnt:{t:"long",v:100}};
if(w=="oilPaint")n={__name:"Oil Paint",classID:"oilPaint",lightingOn:{t:"bool",v:!0},stylization:{t:"doub",v:3},brushScale:{t:"doub",v:1},microBrush:{t:"doub",v:0},LghD:{t:"long",v:45},specularity:{t:"doub",v:1},cleanliness:{t:"doub",v:2}};
if(w=="TrcC")n={__name:"Trace Contour",classID:"TrcC",Lvl:{t:"long",v:128},Edg:{t:"enum",v:{CntE:"Lwr"}}};
if(w=="Wnd ")n={__name:"Wind",classID:"Wnd",WndM:{t:"enum",v:{WndM:"Wnd"}},Drct:{t:"enum",v:{Drct:"Rght"}}};
if(w=="lightFilterGradient")n={__name:"Generate Normals",classID:"lightFilterGradient",blur:{t:"doub",v:0},textureScale:{t:"doub",v:1},Scl:{t:"doub",v:1},Dtl:{t:"VlLs",v:[{t:"doub",v:1},{t:"doub",v:1},{t:"doub",v:1}]}};
if(w=="boxblur")n={__name:"Box Blur",classID:"boxblur",Rds:{t:"UntF",v:{type:"#Pxl",val:15}}};if(w=="GsnB")n={__name:"Gaussian Blur",classID:"GsnB",Rds:{t:"UntF",v:{type:"#Pxl",val:7.2}}};
if(w=="Bokh")n={__name:"Lens Blur",classID:"Bokh",BkDi:{t:"enum",v:{BtDi:"BeIn"}},BkDp:{t:"long",v:0},BkDs:{t:"bool",v:!1},BkIs:{t:"enum",v:{BtIs:"BeS6"}},BkIb:{t:"doub",v:30},BkIc:{t:"long",v:0},BkIr:{t:"long",v:0},BkSb:{t:"doub",v:0},BkSt:{t:"long",v:255},BkNa:{t:"long",v:0},BkNt:{t:"enum",v:{BtNt:"BeNu"}},BkNm:{t:"bool",v:!1}};
if(w=="MtnB")n={__name:"Motion Blur",classID:"MtnB",Angl:{t:"long",v:0},Dstn:{t:"UntF",v:{type:"#Pxl",val:4}}};
if(w=="RdlB")n={__name:"Radial Blur",classID:"RdlB",Amnt:{t:"long",v:10},BlrM:{t:"enum",v:{BlrM:"Spn"}},BlrQ:{t:"enum",v:{BlrQ:"Gd"}},Cntr:{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:.5},Vrtc:{t:"doub",v:.5}}}};
if(w=="surfaceBlur")n={__name:"Surface Blur",classID:"surfaceBlur",Rds:{t:"UntF",v:{type:"#Pxl",val:15}},Thsh:{t:"long",v:15}};
if(w=="denoise")n={__name:"Reduce Noise",classID:"denoise",ClNs:{t:"UntF",v:{type:"#Prc",val:29}},Shrp:{t:"UntF",v:{type:"#Prc",val:0}},removeJPEGArtifact:{t:"bool",v:!1},channelDenoise:{t:"VlLs",v:[{t:"Objc",v:{classID:"channelDenoiseParams",Chnl:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"Cmps"}}]},Amnt:{t:"long",v:5},EdgF:{t:"long",v:0}}},{t:"Objc",v:{classID:"channelDenoiseParams",Chnl:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"Rd"}}]},Amnt:{t:"long",v:0}}},{t:"Objc",v:{classID:"channelDenoiseParams",Chnl:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"Grn"}}]},Amnt:{t:"long",v:0}}},{t:"Objc",v:{classID:"channelDenoiseParams",Chnl:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"Bl"}}]},Amnt:{t:"long",v:0}}}]},preset:{t:"TEXT",v:"Default"}};
if(w=="Dspl")n={__name:"Displace",classID:"Dspl",HrzS:{t:"long",v:10},VrtS:{t:"long",v:10},DspM:{t:"enum",v:{DspM:"StrF"}},UndA:{t:"enum",v:{UndA:"RptE"}},DspF:{t:"Pth ",v:{sig:"txtu",pth:"file.psd\0"}}};
if(w=="Pnch")n={__name:"Pinch",classID:"Pnch",Amnt:{t:"long",v:-100}};if(w=="Plr ")n={__name:"Polar Coordinates",classID:"Plr",Cnvr:{t:"enum",v:{Cnvr:"RctP"}}};
if(w=="Rple")n={__name:"Ripple",classID:"Rple",Amnt:{t:"long",v:999},RplS:{t:"enum",v:{RplS:"Mdm"}}};
if(w=="Shr ")n={__name:"Shear",classID:"Shr",ShrP:{t:"VlLs",v:[{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:0},Vrtc:{t:"doub",v:1}}},{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:0},Vrtc:{t:"doub",v:128}}}]},UndA:{t:"enum",v:{UndA:"WrpA"}},ShrS:{t:"long",v:0},ShrE:{t:"long",v:1}};
if(w=="Sphr")n={__name:"Spherize",classID:"Sphr",Amnt:{t:"long",v:100},SphM:{t:"enum",v:{SphM:"Nrml"}}};
if(w=="Twrl")n={__name:"Twirl",classID:"Twrl",Angl:{t:"long",v:90}};if(w=="Wave")n={__name:"Wave",classID:"Wave",Wvtp:{t:"enum",v:{Wvtp:"WvSn"}},NmbG:{t:"long",v:1},WLMn:{t:"long",v:101},WLMx:{t:"long",v:102},AmMn:{t:"long",v:36},AmMx:{t:"long",v:37},SclH:{t:"long",v:100},SclV:{t:"long",v:100},UndA:{t:"enum",v:{UndA:"WrpA"}},RndS:{t:"long",v:743887}};
if(w=="ZgZg")n={__name:"ZigZag",classID:"ZgZg",Amnt:{t:"long",v:50},NmbR:{t:"long",v:10},ZZTy:{t:"enum",v:{ZZTy:"ArnC"}}};
if(w=="AdNs")n={__name:"Add Noise",classID:"AdNs",Dstr:{t:"enum",v:{Dstr:"Unfr"}},Nose:{t:"UntF",v:{type:"#Prc",val:20}},Mnch:{t:"bool",v:!1},FlRs:{t:"long",v:100691320}};
if(w=="DstS")n={__name:"Dust & Scratches",classID:"DstS",Rds:{t:"long",v:2},Thsh:{t:"long",v:26}};if(w=="Mdn ")n={__name:"Median",classID:"Mdn",Rds:{t:"UntF",v:{type:"#Pxl",val:7}}};
if(w=="ClrH")n={__name:"Color Halftone",classID:"ClrH",Rds:{t:"long",v:8},Ang1:{t:"long",v:10},Ang2:{t:"long",v:40},Ang3:{t:"long",v:70},Ang4:{t:"long",v:80}};
if(w=="Crst")n={__name:"Crystallize",classID:"Crst",ClSz:{t:"long",v:10},FlRs:{t:"long",v:1554929224}};
if(w=="Mztn")n={__name:"Mezzotint",classID:"Mztn",MztT:{t:"enum",v:{MztT:"FnDt"}},FlRs:{t:"long",v:204994187}};
if(w=="Msc ")n={__name:"Mosaic",classID:"Msc",ClSz:{t:"UntF",v:{type:"#Pxl",val:12}}};if(w=="Pntl")n={__name:"Pointillize",classID:"Pntl",ClSz:{t:"long",v:10},FlRs:{t:"long",v:1554929236}};
if(w=="LnsF")n={__name:"Lens Flare",classID:"LnsF",Brgh:{t:"long",v:100},FlrC:{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:.19140625},Vrtc:{t:"doub",v:.185628741979599}}},Lns:{t:"enum",v:{Lns:"Zm"}}};
if(w=="Dthr")n={__name:"Dither",classID:"Dthr",Plte:{t:"long",v:0},Mthd:{t:"long",v:1}};if(w=="Part")n={__name:"Dither",classID:"Part",Cont:{t:"long",v:10},Size:{t:"long",v:8},Dpth:{t:"long",v:100},Brgh:{t:"long",v:800},Clr:{t:"Objc",v:{classID:"RGBC",Rd:{v:255,t:"doub"},Grn:{v:255,t:"doub"},Bl:{v:255,t:"doub"}}},Time:{t:"doub",v:0},Turb:{t:"long",v:0},Blnk:{t:"bool",v:!0},Fall:{t:"bool",v:!1},RndS:{t:"long",v:8438429}};
if(w=="Adobe Camera Raw Filter")n={__name:"Camera Raw Filter",classID:"Adobe Camera Raw Filter",CMod:{t:"TEXT",v:"Filter"},Sett:{t:"enum",v:{Sett:"Cst"}},WBal:{t:"enum",v:{WBal:"AsSh"}},Temp:{t:"long",v:0},Tint:{t:"long",v:0},CtoG:{t:"bool",v:!1},Strt:{t:"long",v:0},Shrp:{t:"long",v:0},LNR:{t:"long",v:0},CNR:{t:"long",v:0},VigA:{t:"long",v:0},BlkB:{t:"long",v:0},RHue:{t:"long",v:0},RSat:{t:"long",v:0},GHue:{t:"long",v:0},GSat:{t:"long",v:0},BHue:{t:"long",v:0},BSat:{t:"long",v:0},Vibr:{t:"long",v:0},HA_R:{t:"long",v:0},HA_O:{t:"long",v:0},HA_Y:{t:"long",v:0},HA_G:{t:"long",v:0},HA_A:{t:"long",v:0},HA_B:{t:"long",v:0},HA_P:{t:"long",v:0},HA_M:{t:"long",v:0},SA_R:{t:"long",v:0},SA_O:{t:"long",v:0},SA_Y:{t:"long",v:0},SA_G:{t:"long",v:0},SA_A:{t:"long",v:0},SA_B:{t:"long",v:0},SA_P:{t:"long",v:0},SA_M:{t:"long",v:0},LA_R:{t:"long",v:0},LA_O:{t:"long",v:0},LA_Y:{t:"long",v:0},LA_G:{t:"long",v:0},LA_A:{t:"long",v:0},LA_B:{t:"long",v:0},LA_P:{t:"long",v:0},LA_M:{t:"long",v:0},STSH:{t:"long",v:0},STSS:{t:"long",v:0},STHH:{t:"long",v:0},STHS:{t:"long",v:0},STB:{t:"long",v:0},PC_S:{t:"long",v:0},PC_D:{t:"long",v:0},PC_L:{t:"long",v:0},PC_H:{t:"long",v:0},PC_1:{t:"long",v:25},PC_2:{t:"long",v:50},PC_3:{t:"long",v:75},ShpR:{t:"doub",v:1},ShpD:{t:"long",v:25},ShpM:{t:"long",v:0},PCVA:{t:"long",v:0},GRNA:{t:"long",v:0},LPEn:{t:"long",v:0},MDis:{t:"long",v:0},PerV:{t:"long",v:0},PerH:{t:"long",v:0},PerR:{t:"doub",v:0},PerS:{t:"long",v:100},PerA:{t:"long",v:0},PerU:{t:"long",v:0},PerX:{t:"doub",v:0},PerY:{t:"doub",v:0},AuCA:{t:"long",v:0},Ex12:{t:"doub",v:0},Cr12:{t:"long",v:0},Hi12:{t:"long",v:0},Sh12:{t:"long",v:0},Wh12:{t:"long",v:0},Bk12:{t:"long",v:0},Cl12:{t:"long",v:0},DfPA:{t:"long",v:0},DPHL:{t:"long",v:30},DPHH:{t:"long",v:70},DfGA:{t:"long",v:0},DPGL:{t:"long",v:40},DPGH:{t:"long",v:60},Dhze:{t:"long",v:0},TMMs:{t:"long",v:0},Crv:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:255},{t:"long",v:255}]},CrvR:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:255},{t:"long",v:255}]},CrvG:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:255},{t:"long",v:255}]},CrvB:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:255},{t:"long",v:255}]},CamP:{t:"TEXT",v:"Embedded"},CP_D:{t:"TEXT",v:"54650A341B5B5CCAE8442D0B43A92BCE"},PrVe:{t:"long",v:184549376},Rtch:{t:"TEXT",v:""},REye:{t:"TEXT",v:""},LCs:{t:"TEXT",v:""},Look:{t:"TEXT",v:""},Pset:{t:"TEXT",v:""}};
if(w=="smartSharpen")n={__name:"Smart Sharpen",classID:"smartSharpen",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},useLegacy:{t:"bool",v:!1},Amnt:{t:"UntF",v:{type:"#Prc",val:150}},Rds:{t:"UntF",v:{type:"#Pxl",val:1}},noiseReduction:{t:"UntF",v:{type:"#Prc",val:0}},blur:{t:"enum",v:{blurType:"GsnB"}}};
if(w=="UnsM")n={__name:"Unsharp Mask",classID:"UnsM",Amnt:{t:"UntF",v:{type:"#Prc",val:142}},Rds:{t:"UntF",v:{type:"#Pxl",val:4.5}},Thsh:{t:"long",v:0}};
if(w=="HghP")n={__name:"High Pass",classID:"HghP",Rds:{t:"UntF",v:{type:"#Pxl",val:3}}};if(w=="HsbP")n={__name:"HSB/HSL",classID:"HsbP",Inpt:{t:"enum",v:{ClrS:"RGBC"}},Otpt:{t:"enum",v:{ClrS:"HSBl"}}};
if(w=="Mxm ")n={__name:"Maximum",classID:"Mxm",Rds:{t:"UntF",v:{type:"#Pxl",val:8}},preserveShape:{t:"enum",v:{preserveShape:"squareness"}}};
if(w=="Mnm ")n={__name:"Minimum",classID:"Mnm",Rds:{t:"UntF",v:{type:"#Pxl",val:8}},preserveShape:{t:"enum",v:{preserveShape:"squareness"}}};
if(w=="Ofst")n={__name:"Offset",classID:"Ofst",Hrzn:{t:"long",v:144},Vrtc:{t:"long",v:278},Fl:{t:"enum",v:{FlMd:"Wrp"}}};
if(w=="Kale")n={__name:"Kaleidoscope",classID:"Kale",Mirr:{t:"long",v:6},MRot:{t:"long",v:0}};if(w=="Rept")n={__name:"Repeat",classID:"Rept",Scl:{v:{type:"#Prc",val:100},t:"UntF"},Rsft:{v:{type:"#Prc",val:0},t:"UntF"},SpcX:{v:{type:"#Prc",val:0},t:"UntF"},SpcY:{v:{type:"#Prc",val:0},t:"UntF"},SpcC:{t:"bool",v:!1},Angl:{t:"long",v:0}};
if(w=="Flam")n={__name:"Repeat",classID:"Flam",Type:{t:"long",v:0},Leng:{t:"long",v:140},RndL:{t:"bool",v:!1},Widt:{t:"long",v:100},Angl:{t:"long",v:0},Intr:{t:"long",v:100},Adpt:{t:"bool",v:!1},Qual:{t:"long",v:1},Clr:{v:{classID:"RGBC",Rd:{v:255,t:"doub"},Grn:{v:110,t:"doub"},Bl:{v:28,t:"doub"}},t:"Objc"},Turb:{t:"long",v:50},Jag:{t:"long",v:0},Opct:{v:{type:"#Prc",val:25},t:"UntF"},Lins:{t:"long",v:10},Botm:{t:"long",v:30},Styl:{t:"long",v:0},Shap:{t:"long",v:0},RnSh:{t:"bool",v:!1},Arng:{t:"long",v:18}};
if(w=="Ctoa")n={__name:"Color to Alpha",classID:"Ctoa",Trsp:{v:{type:"#Prc",val:0},t:"UntF"},Opct:{v:{type:"#Prc",val:100},t:"UntF"},Clr:{v:{classID:"RGBC",Rd:{v:0,t:"doub"},Grn:{v:0,t:"doub"},Bl:{v:0,t:"doub"}},t:"Objc"}};
if(w=="brit")n={__name:"Brightness/Contrast",classID:"BrgC",Brgh:{t:"long",v:0},Cntr:{t:"long",v:0},useLegacy:{t:"bool",v:!1}};
if(w=="levl")n={__name:"Levels",classID:"Lvls",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Adjs:{t:"VlLs",v:[]}};
if(w=="curv")n={__name:"Curves",classID:"Crvs",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Adjs:{t:"VlLs",v:[]}};
if(w=="expA")n={__name:"Exposure",classID:"Exps",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Exps:{t:"doub",v:0},Ofst:{t:"doub",v:0},gammaCorrection:{t:"doub",v:1}};
if(w=="vibA")n={__name:"Vibrance",classID:"vibrance",vibrance:{t:"long",v:0},Strt:{t:"long",v:0}};if(w=="hue2")n={__name:"Hue/Saturation",classID:"HStr",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Clrz:{t:"bool",v:!1},Adjs:{t:"VlLs",v:[]}};
if(w=="blnc")n={__name:"Color Balance",classID:"ClrB",ShdL:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:0}]},MdtL:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:0}]},HghL:{t:"VlLs",v:[{t:"long",v:0},{t:"long",v:0},{t:"long",v:0}]},PrsL:{t:"bool",v:!0}};
if(w=="blwh")n={__name:"Black & White",classID:"BanW",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Rd:{t:"long",v:40},Yllw:{t:"long",v:85},Grn:{t:"long",v:204},Cyn:{t:"long",v:60},Bl:{t:"long",v:20},Mgnt:{t:"long",v:80},useTint:{t:"bool",v:!0},tintColor:{t:"Objc",v:{classID:"RGBC",Rd:{t:"doub",v:0},Grn:{t:"doub",v:0},Bl:{t:"doub",v:0}}}};
if(w=="phfl")n={__name:"Photo Filter",classID:"photoFilter",Clr:{t:"Objc",v:{classID:"LbCl",Lmnc:{t:"doub",v:67.06},A:{t:"doub",v:32},B:{t:"doub",v:120}}},Dnst:{t:"long",v:80},PrsL:{t:"bool",v:!0}};
if(w=="grdm")n={__name:"Gradient Map",classID:"GrMp",Rvrs:{t:"bool",v:!1},Grad:JSON.parse(at.UR[6]).Grad};
if(w=="selc")n={__name:"Selective Color",classID:"SlcC",presetKind:{t:"enum",v:{presetKindType:"presetKindCustom"}},Mthd:{t:"enum",v:{CrcM:"Rltv"}},ClrC:{t:"VlLs",v:[]}};
if(w=="thrs")n={__name:"Threshold",classID:"Thrs",Lvl:{t:"long",v:128}};if(w=="mixr")n={__name:"Channel Mixer",classID:"ChnM",presetKind:{t:"enum",v:{presetKindType:"presetKindDefault"}},Mnch:{t:"bool",v:!1},Rd:{t:"Objc",v:{classID:"ChMx",Rd:{t:"UntF",v:{type:"#Prc",val:100}}}},Grn:{t:"Objc",v:{classID:"ChMx",Grn:{t:"UntF",v:{type:"#Prc",val:100}}}},Bl:{t:"Objc",v:{classID:"ChMx",Bl:{t:"UntF",v:{type:"#Prc",val:100}}}}};
if(w=="clrL")n={__name:"Color Lookup",classID:"colorLookup"};if(w=="post")n={__name:"Posterize",classID:"Pstr",Lvls:{t:"long",v:3}};
if(w=="rplc")n={__name:"Replace Color",classID:"RplC",Fzns:{t:"long",v:55},Mnm:{t:"Objc",v:{classID:"LbCl",Lmnc:{t:"doub",v:73.1},A:{t:"doub",v:23.95},B:{t:"doub",v:8.03}}},Mxm:{t:"Objc",v:{classID:"LbCl",Lmnc:{t:"doub",v:73},A:{t:"doub",v:23},B:{t:"doub",v:8}}},H:{t:"long",v:-22},Strt:{t:"long",v:0},Lght:{t:"long",v:0}};
if(w=="fade")n={__name:"Fade",classID:"fade",Opct:{t:"UntF",v:{type:"#Prc",val:100}},Md:{t:"enum",v:{BlnM:"Nrml"}}};
if(w=="aply")n={classID:"null",With:{t:"Objc",v:{classID:"Clcl",T:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:"RGB"}},{t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Mrgd"}}]},Invr:{t:"bool",v:!1},Clcl:{t:"enum",v:{Clcn:"Nrml"}},Opct:{t:"UntF",v:{type:"#Prc",val:100}},Ofst:{t:"long",v:128},Scl:{t:"doub",v:1},PrsT:{t:"bool",v:!1}}}};
if(w=="matc"){n={__name:"Match Color",classID:"matchColor",Lght:{t:"long",v:100},ClrR:{t:"long",v:100},Fade:{t:"long",v:0},fsel:{t:"bool",v:!0},neutralizeColor:{t:"bool",v:!1},noReference:{t:"bool",v:!0}}}if(w=="Dila")n={__name:"Texture Dilation",classID:"Dila",Crop:{t:"UntF",v:{type:"#Pxl",val:0}},Rds:{t:"UntF",v:{type:"#Pxl",val:10}}};
if(w=="blendOptions")n={classID:"blendOptions",Opct:{t:"UntF",v:{type:"#Prc",val:100}},Md:{t:"enum",v:{BlnM:"Nrml"}}};
return n};cx.fI={sFlam:function(w,n){n[0]=w.Type.v;n[1]=w.Leng.v;n[2]=w.RndL.v;n[3]=w.Widt.v;n[4]=w.Angl.v;
n[5]=w.Intr.v;n[6]=w.Adpt.v;n[7]=w.Clr.v;n[8]=w.Qual.v;n[9]=w.Turb.v;n[10]=w.Jag.v;n[11]=w.Opct.v.val;
n[12]=w.Lins.v;n[13]=w.Botm.v;n[14]=w.Styl.v;n[15]=w.Shap.v;n[16]=w.RnSh.v;n[17]=w.Arng.v},gFlam:function(w,n){w.Type.v=n[0];
w.Leng.v=n[1];w.RndL.v=n[2];w.Widt.v=n[3];w.Angl.v=n[4];w.Intr.v=n[5];w.Adpt.v=n[6];w.Clr.v=n[7];w.Qual.v=n[8];
w.Turb.v=n[9];w.Jag.v=n[10];w.Opct.v.val=n[11];w.Lins.v=n[12];w.Botm.v=n[13];w.Styl.v=n[14];w.Shap.v=n[15];
w.RnSh.v=n[16];w.Arng.v=n[17]},sAdNs:function(w,n){n[0]=w.Nose.v.val;n[1]=["Gsn","Unfr"].indexOf(w.Dstr.v.Dstr);
n[2]=w.Mnch.v},gAdNs:function(w,n){w.Nose.v.val=n[0];w.Dstr.v.Dstr=["Gsn","Unfr"][n[1]];w.Mnch.v=n[2]},sDstS:function(w,n){n[0]=w.Rds.v;
n[1]=w.Thsh.v},gDstS:function(w,n){w.Rds.v=n[0];w.Thsh.v=n[1]},sGsnB:function(w,n){n[0]=w.Rds.v.val},gGsnB:function(w,n){w.Rds.v.val=n[0]},sDila:function(w,n){n[0]=w.Crop.v.val;
n[1]=w.Rds.v.val},gDila:function(w,n){w.Crop.v.val=n[0];w.Rds.v.val=n[1]},sHghP:function(w,n){n[0]=w.Rds.v.val},gHghP:function(w,n){w.Rds.v.val=n[0]},sHsbP:function(w,n){var W=["RGBC","HSBl","HSLC"];
n[0]=W.indexOf(w.Inpt.v.ClrS);n[1]=W.indexOf(w.Otpt.v.ClrS)},gHsbP:function(w,n){var W=["RGBC","HSBl","HSLC"];
w.Inpt.v.ClrS=W[n[0]];w.Otpt.v.ClrS=W[n[1]]},"sMxm ":function(w,n){var W="preserveShape";n[0]=w.Rds.v.val;
n[1]=w[W]?["squareness","Rndn"].indexOf(w[W].v[W]):0},"gMxm ":function(w,n){var W="preserveShape";w.Rds.v.val=n[0];
w[W]={t:"enum",v:{preserveShape:["squareness","Rndn"][n[1]]}}},"sMnm ":function(w,n){var W="preserveShape";
n[0]=w.Rds.v.val;n[1]=w[W]?["squareness","Rndn"].indexOf(w[W].v[W]):0},"gMnm ":function(w,n){var W="preserveShape";
w.Rds.v.val=n[0];w[W]={t:"enum",v:{preserveShape:["squareness","Rndn"][n[1]]}}},sMtnB:function(w,n){n[0]=[w.Angl.v];
n[1]=w.Dstn.v.val;console.log(n)},gMtnB:function(w,n){w.Angl.v=typeof n[0]=="number"?n[0]:n[0][0];w.Dstn.v.val=n[1]},sOfst:function(w,n){n[0]=w.Hrzn.v;
n[1]=w.Vrtc.v;n[2]=["Rpt","Bckg","Wrp"].indexOf(w.Fl.v.FlMd)},gOfst:function(w,n){w.Hrzn.v=n[0];w.Vrtc.v=n[1];
w.Fl.v.FlMd=["Rpt","Bckg","Wrp"][n[2]]},sPnch:function(w,n){n[0]=w.Amnt.v},gPnch:function(w,n){w.Amnt.v=n[0]},"sPlr ":function(w,n){n[0]=["RctP","PlrR"].indexOf(w.Cnvr.v.Cnvr)},"gPlr ":function(w,n){w.Cnvr.v.Cnvr=["RctP","PlrR"][n[0]]},sRple:function(w,n){n[0]=w.Amnt.v;
n[1]=["Sml","Mdm","Lrg"].indexOf(w.RplS.v.RplS)},gRple:function(w,n){w.Amnt.v=n[0];w.RplS.v.RplS=["Sml","Mdm","Lrg"][n[1]]},sTwrl:function(w,n){n[0]=w.Angl.v},gTwrl:function(w,n){w.Angl.v=n[0]},sZgZg:function(w,n){n[0]=w.Amnt.v;
n[1]=w.NmbR.v;n[2]=["ArnC","OtFr","PndR"].indexOf(w.ZZTy.v.ZZTy)},gZgZg:function(w,n){w.Amnt.v=n[0];
w.NmbR.v=n[1];w.ZZTy.v.ZZTy=["ArnC","OtFr","PndR"][n[2]]},sUnsM:function(w,n){n[0]=w.Amnt.v.val;n[1]=w.Rds.v.val;
n[2]=w.Thsh.v},gUnsM:function(w,n){w.Amnt.v.val=n[0];w.Rds.v.val=n[1];w.Thsh.v=n[2]},sWave:function(w,n){n[0]=w.NmbG.v;
n[1]=w.WLMn.v;n[2]=w.WLMx.v;n[3]=w.AmMn.v;n[4]=w.AmMx.v;n[5]=w.SclH.v;n[6]=w.SclV.v;n[7]=["WvSn","WvTr","WvSq"].indexOf(w.Wvtp.v.Wvtp);
n[8]=["WrpA","RptE"].indexOf(w.UndA.v.UndA);n[9]=w.RndS.v},gWave:function(w,n){w.NmbG.v=n[0];w.WLMn.v=n[1];
w.WLMx.v=n[2];w.AmMn.v=n[3];w.AmMx.v=n[4];w.SclH.v=n[5];w.SclV.v=n[6];w.Wvtp.v.Wvtp=["WvSn","WvTr","WvSq"][n[7]];
w.UndA.v.UndA=["WrpA","RptE"][n[8]];if(n[9]!=null){var W=parseInt(n[9]);if(isNaN(W))W=248325464;W=Math.max(0,Math.min(268435455,W));
w.RndS.v=W}},sbrit:function(w,n){n[0]=w.Brgh?w.Brgh.v:0;n[1]=w.Cntr?w.Cntr.v:0;n[2]=w.useLegacy?w.useLegacy.v:!1},gbrit:function(w,n){w.Brgh.v=n[0];
w.Cntr.v=n[1];if(n[2]!=null)w.useLegacy.v=n[2]}};cx.agD=function(w){var n=new ec(0,0);if(w.enab.v==!1)return n;
var W=w.filterFXList.v;for(var L=0;L<W.length;L++){var D=W[L].v;if(D.enab.v==!1)continue;var j=cx.iF(D),I=cx.R5(j,D.Fltr?D.Fltr.v:null);
if(I.x>n.x)n.x=I.x;if(I.y>n.y)n.y=I.y}return n};cx.R5=function(w,n){var W=0,D=0;if(["GsnB","boxblur","smartSharpen","UnsM","HghP"].indexOf(w)!=-1){var j=n.Rds?n.Rds.v.val:1;
W=D=j*2.57}if(w=="MtnB")W=D=n.Dstn.v.val;if("Dila,Ofst,Rept,LqFy,Dspl,Pnch,Rple,Shr ,Sphr,Twrl,ZgZg,Wave,RdlB,Clds,DfrC,Plr ,LnCr,Wnd ,lightFilterGradient,rigidTransform,Frgm,Flam".split(",").indexOf(w)!=-1){W=D=1e4}if(w=="GEfc")return ic.R5(n);
return new ec(Math.ceil(W),Math.ceil(D))};cx.Gq=function(){return{t:"Objc",v:{classID:"filterFXStyle",enab:{t:"bool",v:!0},validAtPosition:{t:"bool",v:!0},filterMaskEnable:{t:"bool",v:!0},filterMaskLinked:{t:"bool",v:!0},filterMaskExtendWithWhite:{t:"bool",v:!0},filterFXList:{t:"VlLs",v:[]}}}};
cx.gt=function(w,n){var W={o:n.Gp>>16,B:n.Gp>>8&255,k:n.Gp&255},D={o:n.as>>16,B:n.as>>8&255,k:n.as&255},j=cx.names[w];
if(j==null)j=eH.names[w];var I=w;for(var U in eH.SM)if(eH.SM[U]==w)I=U;var M={t:"Objc",v:{classID:"filterFX",Nm:{t:"TEXT",v:fV.get(j)},blendOptions:{t:"Objc",v:{classID:"blendOptions",Opct:{t:"UntF",v:{type:"#Prc",val:100}},Md:{t:"enum",v:{BlnM:"Nrml"}}}},enab:{t:"bool",v:!0},hasoptions:{t:"bool",v:!0},FrgC:{t:"Objc",v:E.M.lW(W)},BckC:{t:"Objc",v:E.M.lW(D)},filterID:{t:"long",v:I.length==4?J.adu(I):777}}},m=cx._1(w);
if(m)M.v.Fltr={t:"Objc",v:m};return M};cx.ks=function(w,n,W,D){var j=Date.now(),I=je.YG&&Math.max(D.m,D.n)<=je.VE.getParameter(je.VE.MAX_TEXTURE_SIZE);
if(w<1){var U=Math.round(w*5),M=[1,2,1,2,[40,26,13,6,4,2][U],2,1,2,1];M=E.Z3.kd(M);if(!I){E.y8(W);var m=W.slice(0);
E.Z3.yz(m,W,D.m,D.n,M,255);E.Hd(W)}else{var l=D.m,A=D.n,g=je.vL(0,l,A);g.set(W);var k=je.vL(1,l,A),$=new Float32Array([1/l,1/A]);
je.t5(k);je.filter.zj({type:je.filter.axV,q8:$,aer:new Float32Array(M)},g.LJ);k.get(W)}}else{var C=n==E.xX.Qz?0:n==E.xX.$f?1:2,f=[];
while(C!=2&&w*[1,2.4][C]>20&&f.length<4){var z=E.VU(W,D);f.push(W,D);W=z.Q0;D=z.rect;w/=2}var l=D.m,A=D.n;
if(!I||C==2&&w>15){E.y8(W);n(W,D,w);E.Hd(W)}else{var g=je.vL(0,l,A);g.set(W);var k=je.vL(1,l,A),$=new Float32Array([1/l,1/A]);
if(C==0){var s=1;while(s<w)s<<=1;je.t5(k);je.filter.zj({type:je.filter.yJ,q8:$,lX:w,LQ:[0,0,s]},g.LJ);
je.t5(g);je.filter.zj({type:je.filter.yJ,q8:$,lX:w,LQ:[0,1,s]},k.LJ);g.get(W)}else if(C==1){var O=3,a=E.xX.gS(w,O);
for(var L=0;L<O;L++){var X=a[L]>>>1,P=1;while(P<X)P<<=1;if(X==0)continue;je.t5(k);je.filter.zj({type:je.filter.yJ,q8:$,lX:X,LQ:[0,0,P]},g.LJ);
je.t5(g);je.filter.zj({type:je.filter.yJ,q8:$,lX:X,LQ:[0,1,P]},k.LJ)}g.get(W)}else{var s=1;while(s<w)s<<=1;
je.t5(k);je.filter.zj({type:je.filter.yJ,q8:$,lX:w,LQ:[0,0,s]},g.LJ);k.get(W)}}var Z=Date.now();while(f.length!=0){var Y=f.pop(),K=f.pop();
E.scale.aA9(W,D.m,D.n,K,Y.m,Y.n);W=K;D=Y}}};cx.a8O=function(w,n,W,D){for(var L=0;L<w.length;L++){W[L]=w[L]*(1/255);
D[L]=0}FFT.fft2d(W,D);var j=n>>>1,I=16384,U=128,m=100;while(U<n){U<<=1;I<<=2}var M=255/Math.log(I),l=-100;
for(var A=0;A<n;A++)for(var g=0;g<j;g++){var k=n+j+A&n-1,$=W[k*n+g],C=D[k*n+g],f=Math.sqrt($*$+C*C),z=Math.atan2(C,$);
w[A*n+g]=Math.round(M*Math.log(f+1));w[A*n+j+g]=Math.round((Math.PI+z)*(255*.5/Math.PI))}};cx.aqA=function(w,n,W,D){W.fill(0);
D.fill(0);var j=n>>>1,I=16384,U=128;while(U<n){U<<=1;I<<=2}var M=255/Math.log(I),m=[],l=[],A=[];for(var L=0;
L<256;L++){m[L]=Math.exp(L/M)-1;var g=L*(2*Math.PI/255)-Math.PI;l[L]=Math.sin(g);A[L]=Math.cos(g)}for(var k=0;
k<n;k++)for(var $=0;$<j;$++){var C=n+j+k&n-1,f=m[w[k*n+$]],g=w[k*n+j+$],z=f*A[g],s=f*l[g];W[C*n+$]=z;
D[C*n+$]=s;if($!=0){var O=C==0?C*n+n-$:(n-C)*n+(n-$);W[O]=z;D[O]=-s}}FFT.ifft2d(W,D);for(var L=0;L<w.length;
L++){w[L]=Math.max(0,Math.min(255,~~(.5+255*W[L])))}};cx.a0o=new ArrayBuffer(512);cx.a4b=function(w){var n=cx.a0o,W=w.length;
if(n.byteLength<W)cx.a0o=n=new ArrayBuffer(W);var D=new Uint8Array(n);for(var L=0;L<W;L+=4){D[L]=w[L];
D[L+1]=w[L+1];D[L+2]=w[L+2];D[L+3]=w[L+3]}return n};cx.Ld=function(w,n,W,D,j,I,U){if(I==null)I={buffer:E.Q(n.buffer.length),rect:n.rect.clone()};
I.buffer.set(n.buffer);var M=W&&W.RndS?W.RndS.v>>>1:0;if(w=="GEfc"){var m=[];if(W.GEfs){var l=W.GEfs.v;
for(var L=0;L<l.length;L++){var A=l[L].v;if(A.GELv&&A.GELv.v==!1)continue;m.push(A)}}else m=[W];for(var L=0;
L<m.length;L++){var g;if(L==0)ic.Ld(w,n,m[L],D,j,I,U);else{if(g==null)g={buffer:E.Q(n.buffer.length),rect:n.rect.clone()};
E.nX(I.buffer,g.buffer);ic.Ld(w,g,m[L],D,j,I,U)}}}if(w=="Dila"){var k=W.Crop.v.val,$=W.Rds.v.val+k;$=$*$;
if($==0)return;var C=n.rect,f=C.m,z=C.n,s=f*z,O=n.buffer,g=I.buffer,a=E.Q(s);E.hN(O,a,3);if(k!=0){var X=C.clone();
X.VD(1,1);var P=E.Q(X.O());E.B0(a,C,P,X);E.Ba(P);E.style.stroke(P,P,X,k);E.Ba(P);E.B0(P,X,a,C)}var Z=E.style.Mh(a,f,z);
g.fill(0);for(var Y=0;Y<z;Y++)for(var K=0;K<f;K++){var L=Y*f+K,S=L<<1,G=L<<2,V=Z[S],T=Z[S+1];if(V*V+T*T<$){var R=(Y+T)*f+(K+V)<<2;
g[G]=O[R];g[G+1]=O[R+1];g[G+2]=O[R+2];g[G+3]=255}}}if(w=="Adobe Camera Raw Filter"){var C=n.rect,f=C.m,z=C.n,s=f*z,x=s*4,v=s*3,N=new Float32Array(f*z*3),u=n.buffer;
for(var L=0;L<s;L++){var H=L*3,G=L*4;N[H]=u[G]*(1/255);N[H+1]=u[G+1]*(1/255);N[H+2]=u[G+2]*(1/255)}var F=JSON.parse(JSON.stringify(W));
delete F.Upri;delete F.GuUr;var t=N.slice(0);hP(N,f,z,t,F);N=t;u=I.buffer;for(var L=0;L<s;L++){var H=L*3,G=L*4;
u[G]=255*Math.max(0,Math.min(1,N[H]));u[G+1]=255*Math.max(0,Math.min(1,N[H+1]));u[G+2]=255*Math.max(0,Math.min(1,N[H+2]))}}if(w=="Fct "){var C=n.rect,f=C.m,z=C.n,s=f*z,x=s*4;
function o(eb){var gx=eb.slice(0);for(var Y=0;Y<3;Y++)for(var K=0;K<3;K++)gx[Y*3+K]=eb[(2-K)*3+Y];return gx}function q(d3,dI,gV,cL){var f5=0;
for(var Y=0;Y<3;Y++)for(var K=0;K<3;K++)f5+=dI[Y*3+K]*d3[(cL-1+Y)*f+gV-1+K];return f5}var _=[8,5,2,5,2,-1,2,-1,-4],d=[5,5,5,2,2,2,-1,-1,-1],r=[2,2,2,2,2,2,2,2,2],p=[];
p.push(_);for(var L=0;L<3;L++)p.push(o(p[p.length-1]));p.push(d);for(var L=0;L<3;L++)p.push(o(p[p.length-1]));
p.push(r);for(var L=0;L<9;L++)p[L]=E.Z3.kd(p[L]);var Q=[-f-1,-f,-f+1,-1,0,1,f-1,f,f+1],B=[-1,-1,0,-1,1,-1,-1,0,0,0,1,0,-1,1,0,1,1,1],i=E.Q(s),c=new Float32Array(s),t=E.Q(s);
for(var h2=0;h2<3;h2++){E.hN(n.buffer,i,h2);for(var jX=0;jX<1;jX++){for(var Y=1;Y<z-1;Y++)for(var K=1;
K<f-1;K++){var bm=Y*f+K,dC=i[bm];c[bm]=1e9;for(var L=0;L<9;L++){var fn=q(i,p[L],K,Y),fK=(fn-dC)*(fn-dC);
if(fK<c[bm])c[bm]=fK}}for(var Y=1;Y<z-1;Y++)for(var K=1;K<f-1;K++){var i6=0,dh=1e9;for(var L=0;L<9;L++){var kA=Y*f+K+Q[L],fK=c[kA];
if(fK<dh){dh=fK;i6=i[kA]}}t[Y*f+K]=i6}i.set(t)}E.IL(t,I.buffer,h2)}}if(w=="adaptCorrect"){var C=n.rect,f=C.m,z=C.n,s=f*z,x=s*4,ig=W.sdwM.v,iJ=ig.Amnt.v.val/100,fL=ig.Wdth.v.val/100,fB=ig.Rds.v,ah=W.hglM.v,gL=ah.Amnt.v.val/100,e_=ah.Wdth.v.val/100,c2=ah.Rds.v;
E.c8.Ig(n.buffer,I.buffer,f,z,iJ,fL,fB,gL,e_,c2,W.ClrC.v/100,W.Cntr.v/100)}if(w=="denoise"){var C=n.rect,f=C.m,z=C.n,jS=W.channelDenoise.v[0].v;
E.vy.acY(n.buffer,f,z,I.buffer,jS.Amnt.v/10,jS.EdgF.v/100)}if(w=="HsbP"){var ie=W.Inpt.v.ClrS,as=W.Otpt.v.ClrS,C=n.rect,f=C.m,z=C.n,s=f*z;
for(var L=0;L<s;L++){var G=L*4,jX=n.buffer[G]*(1/255),gb=n.buffer[G+1]*(1/255),gx=n.buffer[G+2]*(1/255);
if(ie=="RGBC"){}else if(ie=="HSLC"){var t=E.P4(jX,gb,gx);jX=t.o;gb=t.B;gx=t.k}else if(ie=="HSBl"){var t=E.ap9(jX,gb,gx);
jX=t.o;gb=t.B;gx=t.k}var eo=jX,di=gb,d0=gx;if(as=="RGBC"){}else if(as=="HSLC"){var t=E.AO(jX,gb,gx);
eo=t.ag;di=t._6;d0=t.EO}else if(as=="HSBl"){var t=E.Yc(jX,gb,gx);eo=t.ag;di=t._6;d0=t.k}I.buffer[G]=~~(255*eo);
I.buffer[G+1]=~~(255*di);I.buffer[G+2]=~~(255*d0)}}if(w=="Fbrs"){var C=n.rect,f=C.m,z=C.n;E._.yt(n.buffer,f,z,I.buffer,[W.Vrnc.v,W.Strg.v,M]);
var e6=E.Q(f*z);E.hN(I.buffer,e6,0);E.Ba(e6);ic.D_(e6,I.buffer,D,j)}if(w=="Frgm"){var C=n.rect,f=C.m,z=C.n,dt=n.buffer.slice(0);
E.y8(dt);E._.aqv(dt,f,z,I.buffer);E.Hd(I.buffer)}if(w=="Flam"){var C=n.rect,f=C.m,z=C.n,gJ=W.Clr.v,iW={type:W.Type.v+1,length:W.Leng.v,a8I:W.RndL.v,_X:W.Widt.v,ayf:W.Angl.v,ayD:W.Intr.v,aiU:W.Adpt.v,color:{o:gJ.Rd.v,B:gJ.Grn.v,k:gJ.Bl.v},g$:W.Qual.v+1,s3:W.Turb.v,DP:W.Jag.v,opacity:W.Opct.v.val,v8:W.Lins.v,axc:W.Botm.v,style:W.Styl.v+1,shape:W.Shap.v+1,aq_:W.RnSh.v,aiO:W.Arng.v,a3H:!1},g5=U[3],jW=g5[0],eP=g5[1],b_=jW[eP.length!=0?eP[0]:0];
if(b_==null){alert("Make a path first");return}var fZ=b_.add.vmsk.i,im=E.P.bB(fZ),j3=[];for(var R=0;
R<im;R++){var dr=E.P.tt(fZ,R),c0=fZ[dr];if(c0.length<2)continue;var fM=[];j3.push(fM);var cB=c0.length-(c0.type==3?1:0);
for(var bm=0;bm<cB;bm++){var iI=fZ[dr+1+bm],jD=bm==c0.length-1?fZ[dr+1]:fZ[dr+1+bm+1],j8=iI.H,jG=iI.mO,_=jD.T7,i1=jD.H,bH=Math.round(ec.cS(j8,i1)/5);
for(var a_=0;a_<bH;a_++){var aR=a_/bH,iY=1-aR,K=iY*iY*iY*j8.x+3*iY*iY*aR*jG.x+3*iY*aR*aR*_.x+aR*aR*aR*i1.x,Y=iY*iY*iY*j8.y+3*iY*iY*aR*jG.y+3*iY*aR*aR*_.y+aR*aR*aR*i1.y;
fM.push(K,Y)}}}var gy=[j3,iW],gr=Date.now(),fs=e1(gy);aB(n.buffer,f,z,I.buffer,fs,gy)}if(w=="Dfs "){var C=n.rect,f=C.m,z=C.n,dQ=["Nrml","DrkO","LghO","anisotropic"].indexOf(W.Md.v.DfsM);
if(dQ<3)E._.aad(n.buffer,f,z,I.buffer,[dQ]);else{var gy=[1.4,1.6,1,4,!1,2,[0,0,.001]],C=n.rect.clone();
C.x=C.y=0;E.Lx.filter(n.buffer,C,I.buffer,gy)}}if(w=="TrcC"){var C=n.rect,f=C.m,ep=f<<2,z=C.n,b2=W.Lvl.v,eX=W.Edg.v.CntE=="Lwr",iz=n.buffer,en=I.buffer;
E.cJ(en,16777215,4278190080);function ko(gU,kz){d1(gU,kz);d1(gU+1,kz+1);d1(gU+2,kz+2)}function fh(gU,kz){j_(gU,kz);
j_(gU+1,kz+1);j_(gU+2,kz+2)}function d1(gU,kz){var eo=iz[gU],di=iz[kz];if(eo>=b2&&di<b2)en[gU]=0;if(eo<b2&&di>=b2)en[kz]=0}function j_(gU,kz){var eo=iz[gU],di=iz[kz];
if(eo>b2&&di<=b2)en[kz]=0;if(eo<=b2&&di>b2)en[gU]=0}if(eX)for(var Y=1;Y<z;Y++)for(var K=1;K<f;K++){var G=Y*f+K<<2;
ko(G,G-4);ko(G,G-ep)}else for(var Y=1;Y<z;Y++)for(var K=1;K<f;K++){var G=Y*f+K<<2;fh(G,G-4);fh(G,G-ep)}}if(w=="Embs"){var C=n.rect,f=C.m,z=C.n,h9=-W.Angl.v*Math.PI/180,ha=W.Hght.v,fl=W.Amnt.v/100;
ha/=2;var V=Math.cos(h9)*ha,T=Math.sin(h9)*ha,iz=n.buffer,en=I.buffer;en.fill(0);var ex=new Uint32Array(iz.buffer),t=new Uint8Array(4),aI=new Uint32Array(t.buffer);
for(var Y=0;Y<z;Y++)for(var K=0;K<f;K++){var ba=0,ik=0,c3=0;if(0<=K+V&&K+V<f&&0<=Y+T&&Y+T<z){E.K.hC(K+V+.5,Y+T+.5,ex,f,z,aI,0,0);
ba+=t[0]-128;ik+=t[1]-128;c3+=t[2]-128}if(0<=K-V&&K-V<f&&0<=Y-T&&Y-T<z){E.K.hC(K-V+.5,Y-T+.5,ex,f,z,aI,0,0);
ba-=t[0]-128;ik-=t[1]-128;c3-=t[2]-128}var G=Y*f+K<<2;en[G]=Math.max(0,Math.min(255,ba*fl+128));en[G+1]=Math.max(0,Math.min(255,ik*fl+128));
en[G+2]=Math.max(0,Math.min(255,c3*fl+128));en[G+3]=iz[G+3]}}if(w=="ShrE"){var C=n.rect,f=C.m,z=C.n;
E._.akX(n.buffer,f,z,I.buffer)}if(w=="Dspc"){var C=n.rect,f=C.m,z=C.n;E._.atI(n.buffer,f,z,I.buffer)}if(w=="Slrz"){var br=I.buffer,bi=128;
for(var L=0;L<br.length;L+=4){if(br[L]>bi)br[L]=255-br[L];if(br[L+1]>bi)br[L+1]=255-br[L+1];if(br[L+2]>bi)br[L+2]=255-br[L+2]}}if(w=="Wnd "){var C=n.rect,f=C.m,z=C.n,cZ=["Wnd","Blst","Stgr"],ib=W.WndM.v.WndM;
E._.jW(n.buffer,f,z,I.buffer,[cZ.indexOf(ib),W.Drct.v.Drct!="Left"])}if(w=="Bokh"){var C=n.rect,f=C.m,z=C.n,s=f*z,x=s*4,hb=n.buffer.slice(0),kg=W.BkDi.v.BtDi,kh=W.BkDc,ct=W.BkDs.v,cy=W.BkDp.v/255;
if(kg=="BeIn")cy=0;var hA=57*(.3+.7*((f+z)/2)/1750)*(W.BkIb.v/100)*(1+.2*Math.pow(cy,.1)),bK=parseInt(W.BkIs.v.BtIs.slice(3)),iO=-W.BkIr.v*Math.PI/180,fj=[];
for(var L=0;L<8;L++){var io=iO+L*(Math.PI*2/bK),fX=iO+(L+1)*(Math.PI*2/bK),a0=Math.cos(io),ia=Math.sin(io),eK=Math.cos(fX),hH=Math.sin(fX),eA=[0,0,0];
E.GY.hU([[a0,ia,1,0],[eK,hH,1,0],[1,1,1,1]],eA);if(eA[2]>0){eA[0]*=-1;eA[1]*=-1;eA[2]*=-1}fj.push(eA[0],eA[1],eA[2],0)}if(kg=="BeIn"){E.cJ(hb,0,16777215);
cy=1}else if(kg=="BeIt"&&kh.v.BtDc=="BeCt"){}else{var cN;if(kg=="BeIt"&&kh.v.BtDc=="BeCm")cN=U[1];else if(kg=="BeIa")cN=U[2][kh.v];
if(cN==null){E.cJ(hb,0,16777215)}else{var i;if(cN.rect.s9(C))i=cN.channel;else i=cN.Ln(C);E.IL(i,hb,3)}}if(ct)for(var L=0;
L<x;L+=4)hb[L+3]=255-hb[L+3];if(je.YG){var a4=hb,h7=f,cD=z,gY=1,iv=(W.BkSb.v==0||W.BkSt.v==255)&&kg=="BeIn";
if(!iv){var b4=0;for(var L=0;L<x;L+=4)b4+=Math.abs(cy-hb[L+3]*(1/255));b4=b4/s*hA;var e5=3.14*b4*b4*f*z/3e6;
if(e5>2e3){alert("too large radius");return}}while(iv&&3*(hA/gY)*(hA/gY)*f*z>500*2e3*2e3){var kd=E.Dl(hb,new iB(0,0,h7,cD));
hb=kd.Q0;h7=kd.rect.m;cD=kd.rect.n;gY*=2}var gr=Date.now(),O=je.vL(0,h7,cD);O.set(hb);var aG=je.vL(1,f,z);
je.t5(aG);je.filter.zj({type:je.filter.a9X,q8:new Float32Array([1/h7,1/cD]),aAy:cy,Jb:hA/gY,awX:new Float32Array([W.BkSb.v/100,W.BkSt.v/255]),azp:new Float32Array([W.BkNa.v/100,W.BkNt.v.BtNt=="BeNu"?0:1,W.BkNm.v?1:0]),ahy:new Float32Array(fj.slice(0,16)),av8:new Float32Array(fj.slice(16))},O.LJ);
aG.get(I.buffer);var d$=I.buffer;for(var L=0;L<x;L+=4)d$[L+3]=n.buffer[L+3]}}if(w=="rigidTransform"){var gr=Date.now(),cc=cx.a4b,O=n.buffer.slice(0),cm=0,jP=0;
E.y8(O);E.cJ(I.buffer,0);var f=n.rect.m,z=n.rect.n,dq=W.puppetShapeList.v,gi=[],gG=[],dK=[],gv=[];for(var bm=0;
bm<dq.length;bm++){var cW=dq[bm].v,S=cm*2,H=jP*3,ii=cW.originalVertexArray.v.length>>>2,ju=cW.indexArray.v.length>>>2,b8=new Float32Array(cc(cW.originalVertexArray.v));
for(var L=0;L<ii;L++)gi[S+L]=b8[L];var jM=new Float32Array(cc(cW.deformedVertexArray.v));for(var L=0;
L<ii;L++)gG[S+L]=jM[L];var f6=new Uint32Array(cc(cW.indexArray.v));for(var L=0;L<ju;L++)dK[H+L]=cm+f6[L];
var it=[],iG=[],j0=cW.PnDp.v;for(var L=0;L<j0.length;L++){it.push(cW.pinVertexIndices.v[L].v);iG.push(j0[L].v)}var cS=E.mE.a06(b8,f6,it,iG);
for(var L=0;L<cS.length;L++)gv[cm+L]=cS[L];cm+=ii>>>1;jP+=~~(ju/3)}var jX=n.rect,f=jX.m,z=jX.n;E.mE.mD(O,f,z,I.buffer,f,z,gi,gG,gv,dK);
E.Hd(I.buffer)}if(w=="lightFilterGradient"){function ar(j8){var dI=1/Math.sqrt(j8[0]*j8[0]+j8[1]*j8[1]+j8[2]*j8[2]);
j8[0]*=dI;j8[1]*=dI;j8[2]*=dI}var f=n.rect.m,z=n.rect.n,s=f*z,gr=Date.now(),fC=E.Q(s),di=.3,d0=.7;E.fo(I.buffer,fC);
var kp=E.Q(s);E.xX.So(fC,kp,I.rect,16);var dO=E.Q(s);E.xX.So(fC,dO,I.rect,8);var iN=fC,iU=new Float32Array(s),g$=W.Dtl.v,ji=g$[2].v,hr=g$[1].v,hW=g$[0].v,f5=W.Scl.v*40*W.textureScale.v/(ji+hr+hW);
ji*=f5;hr*=f5;hW*=f5;for(var L=0;L<s;L++){var j2=kp[L]*(1/255),fP=dO[L]*(1/255),ay=iN[L]*(1/255);ay=ay*ay;
iU[L]=ji*j2+hr*fP+hW*ay}var ca=W.blur.v;if(ca!=0){var aW=iU.slice(0);E.xX.uf(aW,iU,I.rect,ca)}var ak=f-1,fF=z-1;
for(var Y=0;Y<z;Y++)for(var K=0;K<f;K++){var L=Y*f+K,G=L*4,kn=iU[L],V=di*(iU[L+(K==ak?0:1)]-kn)+d0*(kn-iU[L-(K==0?0:1)]),T=di*(iU[L+(Y==fF?0:f)]-kn)+d0*(kn-iU[L-(Y==0?0:f)]),j8=[1,0,V],jG=[0,1,T];
ar(j8);ar(jG);var fX=j8[0],jc=j8[2],ky=jG[1],f0=jG[2],hS=-jc*ky,fr=-fX*f0,iD=fX*ky;I.buffer[G]=~~(127.5+hS*127.5);
I.buffer[G+1]=~~(127.5+fr*127.5);I.buffer[G+2]=~~(127.5+iD*127.5)}}if(w=="defr"){var f=n.rect.m,z=n.rect.n;
iw(n.buffer,f,z,I.buffer)}if(w=="dDFT"||w=="iDFT"){function dL(bK){if(bK==0)return 1;bK--;bK|=bK>>1;
bK|=bK>>2;bK|=bK>>4;bK|=bK>>8;bK|=bK>>16;return bK+1}var f=n.rect.m,z=n.rect.n,aQ=dL(Math.max(f,z)),h4=aQ>>>1,jd=new iB(0,0,aQ,aQ),fQ=new iB(0,0,f,z);
fQ.y=aQ-z>>>1;var hK=f>>>1,cb=new iB(0,fQ.y,hK,z),dF=new E.H0(f*z);E.rH(n.buffer,dF);var i_=new Float64Array(aQ*aQ),ew=new Float64Array(aQ*aQ),i=E.Q(aQ*aQ);
FFT.init(aQ);var eT=[dF.o,dF.B,dF.k];for(var L=0;L<3;L++){var h0=eT[L];i.fill(0);if(w=="dDFT"){E.B0(h0,fQ,i,jd);
cx.a8O(i,aQ,i_,ew);E.B0(i,jd,h0,fQ,cb);cb.x+=hK;jd.x-=h4-hK;E.B0(i,jd,h0,fQ,cb);cb.x-=hK;jd.x+=h4-hK}else{E.B0(h0,fQ,i,jd,cb);
cb.x+=h4;fQ.x+=h4-hK;E.B0(h0,fQ,i,jd,cb);cb.x-=h4;fQ.x-=h4-hK;cx.aqA(i,aQ,i_,ew);E.B0(i,jd,h0,fQ)}}E.kX(dF,I.buffer)}if(w=="Avrg"){var f_=0,jx=0,km=0,jg=0,i8=1;
for(var L=0;L<n.buffer.length;L+=4){var a=n.buffer[L+3];km+=n.buffer[L]*a;jx+=n.buffer[L+1]*a;f_+=n.buffer[L+2]*a;
jg+=a}var bx=1/jg;f_=Math.round(i8*(f_*bx)+(1-i8)*255);jx=Math.round(i8*(jx*bx)+(1-i8)*255);km=Math.round(i8*(km*bx)+(1-i8)*255);
E.cJ(I.buffer,f_<<16|jx<<8|km,4278190080)}if(["GsnB","boxblur","smartSharpen","UnsM","HghP"].indexOf(w)!=-1){var h6=W.Rds?W.Rds.v.val:1,dT=w=="boxblur"?E.xX.Qz:E.xX.$f;
cx.ks(h6,dT,I.buffer,I.rect);if(w=="UnsM"||w=="smartSharpen"){var fl=(W.Amnt?W.Amnt.v.val:200)/100,ds=0;
if(w=="UnsM")ds=W.Thsh.v;else fl*=.75;for(var L=0;L<n.buffer.length;L++){if((L&3)==3){I.buffer[L]=n.buffer[L];
continue}var dC=n.buffer[L],fn=I.buffer[L],ih=fl*(dC-fn);if(ih>0)ih=Math.max(0,ih-ds);else ih=Math.min(0,ih+ds);
I.buffer[L]=Math.max(0,Math.min(255,dC+ih))}}if(w=="HghP")for(var L=0;L<n.buffer.length;L++){if((L&3)==3){I.buffer[L]=n.buffer[L];
continue}var dC=n.buffer[L],fn=I.buffer[L];I.buffer[L]=Math.max(0,Math.min(255,128+dC-fn))}}if(w=="AdNs"){var aM=new Uint8ClampedArray(I.buffer.buffer),dM=255*W.Nose.v.val/100,f4;
if(W.Dstr.v.Dstr=="Gsn")f4=function(){return(Math.random()+Math.random()+Math.random()+Math.random()-2)*2};
else f4=function(){return Math.random()*2-1};for(var L=0;L<aM.length;L+=4){var jX=aM[L],gb=aM[L+1],gx=aM[L+2],bP,cd,gd;
if(W.Mnch.v){bP=cd=gd=f4()}else{bP=f4();cd=f4();gd=f4()}jX+=dM*bP;gb+=dM*cd;gx+=dM*gd;aM[L]=jX;aM[L+1]=gb;
aM[L+2]=gx}}var gr=Date.now();if(w=="Mdn "||w=="DstS"||w=="Mxm "||w=="Mnm "||w=="surfaceBlur"){var jX=0,em=W.Thsh,cW=0;
if(em)em=em.v;else em=0;if(w=="Mdn "||w=="Mxm "||w=="Mnm "||w=="surfaceBlur")jX=W.Rds.v.val;else jX=W.Rds.v;
var bD=10*Math.ceil(jX/10),f=n.rect.m,z=n.rect.n,jL=["Mnm ","Mxm ","surfaceBlur"].indexOf(w),fW=(cW==0?1:.75)*[.73,.73,1.2][jL]*(f*z*Math.pow(bD*bD,1.05))/6022387,cG=.6*(f*z*Math.pow(jX,1/2.6))/6500;
if(w=="Mxm "||w=="Mnm ")cG=f*z/13e3;var fz=W.preserveShape;if(fz&&fz.v.preserveShape=="Rndn")cW=1;if(je.YG&&jL!=-1&&(fW<cG||cW==1)&&fW<500){var O=je.vL(0,f,z);
O.set(n.buffer);var g=je.vL(1,f,z);je.t5(g);je.filter.zj({type:je.filter.agn,q8:new Float32Array([1/f,1/z]),Jb:jX,a1n:em/255,LQ:[cW,jL,bD]},O.LJ);
g.get(I.buffer)}else if(w=="Mxm "||w=="Mnm "){var f=n.rect.m,z=n.rect.n;E.nx.anO(n.buffer,I.buffer,f,z,1+Math.floor(W.Rds.v.val)*2,w=="Mxm ")}else{jX=Math.round(jX);
E.h1.QB=.5;E.h1.tB=em;var dT=w=="surfaceBlur"?1:0;E.h1.jI(n.buffer,I.buffer,f,z,jX,dT);if(w=="DstS")for(var L=0;
L<f*z*4;L++){var a3=Math.abs(n.buffer[L]-I.buffer[L]);if(a3<=em)I.buffer[L]=n.buffer[L]}}}if(w=="ClrH"){var cb=n.rect.clone();
cb.x=cb.y=0;var jX=W.Rds.v;jX=Math.round(jX*Math.sqrt(2));var f=cb.m,z=cb.n,dF=new E.H0(f*z);E.rH(n.buffer,dF);
E.Ba(dF.o);E.Ba(dF.B);E.Ba(dF.k);var a7=E.Om(f,z),d$=E.Q(f*z*4);for(var d3=0;d3<3;d3++){var i=d3==0?dF.o:d3==1?dF.B:dF.k,h9=Math.PI*W["Ang"+(d3+1)].v/180,ee=new eh(1/jX,0,0,1/jX,0,0);
ee.rotate(h9);E.IL(i,d$,3);var t=y.wR.lD([d$,cb],ee,!0),fQ=t.rect;a7.clearRect(0,0,f,z);var a8=Math.sin(h9),h$=Math.cos(h9);
for(var L=0;L<fQ.n;L++)for(var a_=0;a_<fQ.m;a_++){var K=(a_+fQ.x+.5)*jX,Y=(L+fQ.y+.5)*jX,gw=K,fv=Y;K=h$*gw-a8*fv;
Y=a8*gw+h$*fv;var s=t.buffer[(L*fQ.m+a_<<2)+3]*(1/255),h6=jX*Math.sqrt(s*(1/Math.PI));a7.beginPath();
a7.arc(K,Y,h6,0,2*Math.PI);a7.fill()}var ei=a7.getImageData(0,0,f,z);E.hN(ei.data,i,3)}E.Ba(dF.o);E.Ba(dF.B);
E.Ba(dF.k);E.kX(dF,I.buffer)}if(w=="Crst"||w=="Pntl"){var f=n.rect.m,z=n.rect.n,dT=w=="Crst"?E.C1.asG:E.C1.a99;
dT(n.buffer,f,z,I.buffer,W.ClSz.v,[Math.round(j.o),Math.round(j.B),Math.round(j.k)])}if(w=="Mztn"){var f=n.rect.m,z=n.rect.n,s=f*z,dF=new E.H0(s),bZ=[dF.o,dF.B,dF.k];
E.rH(n.buffer,dF);var ib=W.MztT.v.MztT,aq={FnDt:[.1,0,.3,1.4],MdmD:[.9,0,.1,1.4],GrnD:[3,0,.2,1.4],CrsD:[7,0,.1,1.4],ShrL:[0,10,.16,3],MdmL:[0,22,.06,3],LngL:[0,25,.01,4.5],ShSt:[3,10,.05,4.4],MdmS:[4,25,.15,4],LngS:[4,30,.05,4]}[ib],gr=Date.now(),el=[];
for(var L=0;L<s;L++){el[L]=Math.random()}var s=f*z,fU=Math.round(s*aq[0]),iZ=s-f-1;for(var L=0;L<fU;
L++){var ip=Math.random(),gk=1;if(ip<.5){gk=f;ip*=2}else ip=2*(ip-.5);var gU=Math.floor(ip*iZ),kz=gU+gk;
el[gU]=el[kz]}var g4=Math.round(f*aq[1]);for(var Y=0;Y<z;Y++)for(var L=0;L<g4;L++){var ip=E.s.lr(Y*s+L),gU=Y*f+Math.floor(ip*(f-1));
el[gU]=el[gU+1]}var c4=new Float64Array(256);for(var L=0;L<256;L++){var ae=L/255,cU=2*(ae<.5?ae:1-ae);
cU=aq[2]+Math.pow(cU,aq[3])*(1-aq[2]);ae=ae<.5?cU*.5:1-cU*.5;c4[L]=ae}for(var h2=0;h2<3;h2++){var i=bZ[h2];
for(var Y=0;Y<z;Y++){for(var K=0;K<f;K++){var L=Y*f+K,hM=i[L],ae=c4[hM],ip=el[L];i[L]=ip>ae?0:255}}}E.kX(dF,I.buffer)}if(w=="Msc "){var im=W.ClSz.v.val,f=n.rect.m,z=n.rect.n,bf=Math.ceil(f/im),kk=Math.ceil(z/im),gW=E.Q(bf*kk*4);
E.scale.cg(n.buffer,f,z,gW,bf,kk,1/im);E.scale.cg(gW,bf,kk,I.buffer,f,z,im)}if(w=="Clds"||w=="DfrC"){var f=I.rect.m,z=I.rect.n,s=f*z,aY=E.Q(s);
if(w=="Clds")E.cJ(I.buffer,4278190080);var e2=E.Q(256*4);for(var L=0;L<256;L++){var G=L<<2,eb=L/255,f6=1-eb;
e2[G]=Math.round(eb*D.o+f6*j.o);e2[G+1]=Math.round(eb*D.B+f6*j.B);e2[G+2]=Math.round(eb*D.k+f6*j.k)}E._.a9r(n.buffer,f,z,aY);
var dG=I.buffer;for(var L=0;L<s;L++){var G=L<<2,h2=aY[L]<<2,jX=e2[h2],gb=e2[h2+1],gx=e2[h2+2];if(w=="Clds"){dG[G]=jX;
dG[G+1]=gb;dG[G+2]=gx}else{dG[G]=Math.abs(dG[4*L]-jX);dG[G+1]=Math.abs(dG[4*L+1]-gb);dG[G+2]=Math.abs(dG[4*L+2]-gx)}}}if(w=="LnsF"){var f=n.rect.m,z=n.rect.n,ib=["Zm","Nkn","Nkn1","PnVs"].indexOf(W.Lns.v.Lns),de=W.FlrC.v,hE=[Math.min(ib,2),W.Brgh.v/100,de.Hrzn.v,de.Vrtc.v],gr=Date.now();
E.aef(n.buffer,f,z,I.buffer,hE)}var b0=["Blr ","BlrM","Shrp","ShrM"].indexOf(w);if(b0!=-1){var aX=b0>1,f=n.rect.m,z=n.rect.n,h_=E.Z3.eq[b0],jQ=n.buffer.slice(0);
if(!aX)E.y8(jQ);E.Z3.yz(jQ,I.buffer,f,z,h_,255,!1,aX);if(!aX)E.Hd(I.buffer)}if(w=="MtnB"){var bY=-W.Angl.v*Math.PI/180,aE=W.Dstn.v.val/2,gr=Date.now(),f=n.rect.m,z=n.rect.n,C=n.rect.clone();
C.x=C.y=0;if(je.YG){var gr=Date.now(),aJ=I.buffer;aJ.set(n.buffer);E.y8(aJ);var aS=je.vL(0,f,z);aS.set(aJ);
var iz=E.Q(4);iz[0]=Math.round(128+127*Math.cos(bY));iz[1]=Math.round(128+127*Math.sin(bY));new Uint32Array(aJ.buffer).fill(new Uint32Array(iz.buffer)[0]);
var dz=je.vL(1,f,z);dz.set(aJ);je.t5(aS,C);aS.Le(C);je.filter.zj({type:je.filter.d7,XU:dz.LJ,q8:new Float32Array([1/f,1/z]),anU:aE/2,aiD:1},aS.Ef);
aS.get(aJ);E.Hd(aJ)}else{var ee=new eh;ee.rotate(bY);var t=y.wR.lD([n.buffer,n.rect],ee,!1,null,!0);
cx.ks(aE,E.xX.pc,t.buffer,t.rect);ee.Ba();t=y.wR.lD([t.buffer,t.rect],ee,!1,I.buffer.buffer,!0,I.rect)}console.log(Date.now()-gr)}if(w=="RdlB"){var f=n.rect.m,z=n.rect.n,fl=W.Amnt.v,iM=W.BlrM.v.BlrM=="Zm",d3=W.Cntr.v,gV=d3.Hrzn.v,cL=d3.Vrtc.v,V=Math.max(gV,1-gV)*f,T=Math.max(cL,1-cL)*z,h6=Math.sqrt(V*V+T*T),ka=2*Math.PI*h6*1.5,bS=Math.round(ka),k7=Math.round(h6),cb=new iB(0,0,bS,k7),dd=E.Q(bS*k7*4),dY=iM?4:1,ix=iM?.6:8*((f+z)/2)/1400,bN=.1,gY=1,jh=1;
E.K.sB(n.buffer,f,z,dd,bS,k7,gV,cL,dY,bN,gY,jh);var ap=iM?E.Q(bS*k7*4):null;if(iM){E.K.nJ(dd,ap,bS,k7);
var aR=ap;ap=dd;dd=aR;cb.m=k7;cb.n=bS}cx.ks(ix*fl,E.xX.pc,dd,cb);if(iM){E.K.nJ(dd,ap,k7,bS);var aR=ap;
ap=dd;dd=aR;cb.m=bS;cb.n=k7}E.K.al(dd,bS,k7,I.buffer,f,z,gV,cL,dY,bN,gY,jh)}if(w=="Plr "){var f=n.rect.m,z=n.rect.n;
if(W.Cnvr.v.Cnvr=="RctP")E.K.al(n.buffer,f,z,I.buffer,f,z,.5,.5,1,0,2,f/z);else E.K.sB(n.buffer,f,z,I.buffer,f,z,.5,.5,1,0,2,f/z)}if(w=="FndE"){var f=n.rect.m,z=n.rect.n;
E.Z3.eh(n.buffer,I.buffer,f,z)}if(w=="oilPaint"){var h9=W.LghD.v*Math.PI/180,fq=[Math.cos(h9),Math.sin(h9),.001],gy=[W.stylization.v,W.cleanliness.v,W.brushScale.v,W.microBrush.v,W.lightingOn.v,W.specularity.v,fq],C=n.rect.clone();
C.x=C.y=0;E.Lx.filter(n.buffer,C,I.buffer,gy)}if(w=="Ofst"){var f=n.rect.m,z=n.rect.n,fx=new Uint32Array(n.buffer.buffer),fc=new Uint32Array(I.buffer.buffer),gw=W.Hrzn.v,fv=W.Vrtc.v,aV=W.Fl.v.FlMd;
E.cJ(fc,0);if(aV=="Bckg"||aV=="Rpt"){var cb=n.rect.clone();cb.offset(gw,fv);E.Cb(fx,cb,fc,I.rect)}if(aV=="Rpt"){var a0,ia,eK,hH,au;
gw=Math.max(-f,Math.min(f,gw));fv=Math.max(-z,Math.min(z,fv));a0=gw>0?gw:0;eK=gw>0?f:f+gw;ia=fv>0?0:fv+z;
hH=fv>0?fv:z;au=fv>0?0:f*(z-1);for(var Y=ia;Y<hH;Y++)for(var K=a0;K<eK;K++)fc[Y*f+K]=fx[au+K-gw];a0=gw>0?0:f+gw;
eK=gw>0?gw:f;ia=fv>0?fv:0;hH=fv>0?z:z+fv;au=gw>0?0:f-1;for(var Y=ia;Y<hH;Y++)for(var K=a0;K<eK;K++)fc[Y*f+K]=fx[au+f*(Y-fv)];
if(gw>=0&&fv>=0){a0=0;eK=gw;ia=0;hH=fv;au=0}if(gw>=0&&fv<0){a0=0;eK=gw;ia=z+fv;hH=z;au=f*(z-1)}if(gw<0&&fv>=0){a0=f+gw;
eK=f;ia=0;hH=fv;au=f-1}if(gw<0&&fv<0){a0=f+gw;eK=f;ia=z+fv;hH=z;au=f*z-1}for(var Y=ia;Y<hH;Y++)for(var K=a0;
K<eK;K++)fc[Y*f+K]=fx[au]}if(aV=="Wrp"){gw=(gw+100*f)%f;fv=(fv+100*z)%z;var cb=new iB(gw-f,fv-z,f,z);
E.Cb(fx,cb,fc,I.rect);cb.offset(f,0);E.Cb(fx,cb,fc,I.rect);cb.offset(0,z);E.Cb(fx,cb,fc,I.rect);cb.offset(-f,0);
E.Cb(fx,cb,fc,I.rect)}}if(w=="Rept"){var cJ=W.Rsft.v.val/100,gB=W.SpcX.v.val/100;gB=Math.max(gB,-.99);
var eN=W.SpcY.v.val/100;eN=Math.max(eN,-.99);var gY=W.Scl.v.val/100,ee=new eh;ee.rotate(W.Angl.v*Math.PI/180);
ee.scale(gY,gY);var f9={buffer:n.buffer,rect:n.rect};E.qS(f9);if(f9.rect.VY()){f9.buffer=n.buffer;f9.rect=n.rect}var dG=f9.buffer,cb=f9.rect,iQ=E.tx(dG,cb,0),hw=new Uint32Array(dG.buffer)[0];
if(!iQ.VY()&&!iQ.s9(cb)){var jp=E.Q(iQ.O()*4);E.Cb(dG,cb,jp,iQ);dG=jp;cb=iQ}cb.x=cb.y=0;hw=gB==0&&eN==0||W.SpcC.v?hw:0;
function cw(K){return K<0?Math.ceil(K):Math.floor(K)}var am=ee.bj(new ec(cb.m,0));am.x=cw(am.x);am.y=cw(am.y);
var cn=ee.bj(new ec(0,cb.n));cn.x=cw(cn.x);cn.y=cw(cn.y);var t=y.wR.lD([dG,cb],ee,!1),fQ=t.rect,en=t.buffer,gR=Math.round(fQ.x),c$=Math.round(fQ.y),eL=Math.max(I.rect.m,I.rect.n)/Math.min(cb.m*gY*(1+gB),cb.n*gY*(1+eN));
eL=Math.ceil(eL*1.7);E.cJ(I.buffer,hw);for(var Y=-eL;Y<eL;Y++){for(var K=-eL;K<eL;K++){var fg=(K+Y*cJ)*(1+gB),hv=Y*(1+eN);
fQ.x=gR+Math.round(fg*am.x+hv*cn.x);fQ.y=c$+Math.round(fg*am.y+hv*cn.y);if(fQ.L0(I.rect))E.s._U("norm",en,fQ,I.buffer,I.rect,fQ,1)}}}if(w=="Ctoa"){var j=E.M.y_(W.Clr.v),em=W.Trsp.v.val/100,i9=W.Opct.v.val/100;
em=i9==0?0:em/i9;var f=n.rect.m,z=n.rect.n,ek=~~j.o,gC=~~j.B,ej=~~j.k,au=n.buffer,kA=I.buffer;for(var Y=0;
Y<z;Y++)for(var K=0;K<f;K++){var L=Y*f+K,G=L<<2,cb=au[G],h5=au[G+1],dG=au[G+2],k8=Math.abs(ek-cb),jz=Math.abs(gC-h5),eG=Math.abs(ej-dG),hc=Math.max(k8,jz,eG)*(1/255);
hc=Math.max(0,Math.min(1,hc/i9));var fY=hc==0?0:1/hc,bb=em==1?1:Math.max(0,Math.min(1,(hc-em)/(1-em)));
kA[G]=Math.max(0,Math.min(255,(cb-ek*(1-hc))*fY));kA[G+1]=Math.max(0,Math.min(255,(h5-gC*(1-hc))*fY));
kA[G+2]=Math.max(0,Math.min(255,(dG-ej*(1-hc))*fY));kA[G+3]=~~(.5+bb*255)}}if(w=="Dthr"){function b6(K){return~~(.5+255*E.vw(K/255))}var bm=W.Plte.v,k4;
if(bm==0)k4=[4278190080,4294967295];else{var j7=[[1,1,1],[2,2,2],[3,3,2]][bm-1],dv=[1<<j7[0],1<<j7[1],1<<j7[2]],al=[~~(255/(dv[0]-1)),~~(255/(dv[1]-1)),~~(255/(dv[2]-1))];
k4=[];for(var jX=0;jX<dv[0];jX++)for(var gb=0;gb<dv[1];gb++)for(var gx=0;gx<dv[2];gx++)k4.push(255<<24|b6(gx*al[2])<<16|b6(gb*al[1])<<8|b6(jX*al[0]))}var f=n.rect.m,z=n.rect.n,s=f*z,j1=s*4,c3=n.buffer.slice(0),ac=I.buffer;
for(var L=0;L<j1;L++)c3[L]=~~(.5+255*E.vw(c3[L]/255));var gN=E.Q(f*z);UPNG.encode.dither(c3,f,z,k4,ac,gN,W.Mthd?W.Mthd.v:1);
for(var L=0;L<j1;L++)ac[L]=~~(.5+255*E.ae(ac[L]/255))}if(w=="Part"){var i$=[W.RndS.v,W.Cont.v/100,W.Size.v,W.Dpth.v/100,W.Brgh.v/100,E.M.y_(W.Clr.v),W.Time.v,W.Blnk.v,W.Fall.v,W.Turb.v/100];
E.gX.ee(I.buffer,n.rect.m,n.rect.n,i$)}if("LqFy,Dspl,Pnch,Sphr,Twrl,Rple,Shr ,Wave,LnCr,ZgZg,Kale".split(",").indexOf(w)!=-1){var iq=U[0],f=n.rect.m,z=n.rect.n,c4,bJ=0;
if(w=="LqFy")c4=fH.ew(new Uint8Array(W.LqMe.v).buffer);else{var c_=3;c4={gA:Math.floor(f/c_),ag:Math.floor(z/c_)};
c4.map=new Float32Array(c4.gA*c4.ag*2);if(w=="LnCr"){var gV=.5*(c4.gA-1),cL=.5*(c4.ag-1),id=Math.max(Math.abs(0-gV),Math.abs(1-gV)),jE=Math.max(Math.abs(0-cL),Math.abs(1-cL)),hU=Math.sqrt(id*id+jE*jE),dp=0,fN=0,ho=-1,iL=2,gY=W.LnSi.v/100,iM=1/gY,jN=W.LnIa.v/100,jC=jN==0?1e-6:jN*4.6,kl=iM/hU;
for(var Y=0;Y<c4.ag;Y++){for(var K=0;K<c4.gA;K++){var V=(K-gV)*kl,T=(Y-cL)*kl,jX=Math.sqrt(V*V+T*T)*jC,b5=Math.atan(jX),ck=jN>0?b5/jX:jX/b5,jh=gV+hU*ck*V,hu=cL+hU*ck*T,L=Y*c4.gA+K<<1;
c4.map[L]=jh-K;c4.map[L+1]=hu-Y}}}else if(w=="Kale"){var bf=c4.gA,kk=c4.ag,bu=(bf-1)*.5,fF=(kk-1)*.5,e9=W.MRot.v*Math.PI/180+Math.PI/2+4*Math.PI,hg=W.Mirr.v,bQ=Math.PI*2/hg,iy=.5*bQ;
for(var Y=0;Y<kk;Y++)for(var K=0;K<bf;K++){var V=K-bu,T=Y-fF,g7=Math.sqrt(V*V+T*T),h9=Math.atan2(T,V)+e9;
h9=h9%bQ;if(h9>iy)h9=bQ-h9;var jh=bu+Math.cos(h9-e9)*g7,hu=fF+Math.sin(h9-e9)*g7,L=(Y*bf+K)*2;c4.map[L]=jh-K;
c4.map[L+1]=hu-Y}}else if(w=="Dspl"&&iq.length!=0){bJ=W.UndA.v.UndA=="WrpA"?2:1;var eV=W.DspF.v.pth,gK;
for(var L=0;L<iq.length;L++)if(iq[L].Z4==eV)gK=iq[L];if(gK==null)gK=iq[0];gK.Vc();var k8=gK.PO[1],d8=E.Q(k8.O());
E.fo(gK.PO[0],d8);var jV=k8.m,ij=k8.n;c4={gA:jV,ag:ij};c4.map=new Float32Array(c4.gA*c4.ag*2);var k6=2.54*W.HrzS.v*jV/f,fS=2.54*W.VrtS.v*ij/z;
for(var Y=0;Y<c4.ag;Y++){for(var K=0;K<c4.gA;K++){var a3=-.5+d8[Y*jV+K]*(1/255),L=Y*c4.gA+K<<1;c4.map[L]=a3*k6;
c4.map[L+1]=a3*fS}}}else if(w=="Pnch"||w=="Twrl"||w=="Sphr"||w=="ZgZg"){var fl=1,bY=Math.PI,dx=0,aP=1,j9=0,d3=3,im=1.53,ck=1;
if(w=="Pnch"||w=="Sphr"||w=="ZgZg")fl=W.Amnt.v/100;if(w=="ZgZg"){aP=W.NmbR.v;j9=["ArnC","OtFr","PndR"].indexOf(W.ZZTy.v.ZZTy)}if(w=="Twrl")bY=W.Angl.v*Math.PI/180;
if(w=="Sphr")dx=["Nrml","HrzO","VrtO"].indexOf(W.SphM.v.SphM);function dT(K){K=Math.pow(K,1-K*.3-K*K*(K*K)*.5);
return-.225*Math.sin(K*Math.PI)}function fu(z,dI,jX,a0,ia,eK,hH,ck){var V=eK-a0,T=hH-ia,hZ=a0-z,es=ia-dI,eb=V*V+T*T,gx=2*(V*hZ+T*es),d3=hZ*hZ+es*es-jX*jX,jO=Math.sqrt(gx*gx-4*eb*d3),fG=ck/(2*eb),aF=(-gx+jO)*fG,bn=(-gx-jO)*fG;
return ck*Math.min(aF,bn)}var bf=c4.gA,kk=c4.ag,bu=c4.gA/2,fF=c4.ag/2,iX=1/bu,jX=Math.sqrt(d3*d3+1)/d3,h0=d3+Math.sqrt(1/(d3*d3));
if(fl<0){d3=1.72;jX=1;h0=d3;im=-1;ck=-1}for(var Y=0;Y<kk;Y++){var T=(Y-fF)/fF;for(var K=0;K<bf;K++){var V=(K-bu)*iX;
if(dx==1)T=0;else if(dx==2)V=0;var f1=Math.sqrt(V*V+T*T);if(f1<1&&f1!=0){var L=Y*c4.gA+K<<1;if(w=="Pnch"){var hO=-fl*dT(f1)/f1;
c4.map[L]=V*hO*bu;c4.map[L+1]=T*hO*fF}else if(w=="Sphr"){var aR=fu(0,h0,jX,0,0,f1,d3,ck),bR=im*fl*(aR-1);
c4.map[L]=V*bR*bu;c4.map[L+1]=T*bR*fF}else if(w=="Twrl"){var h9=Math.atan2(T,V)-bY*(1-f1)*(1-f1),dW=Math.cos(h9),aL=Math.sin(h9);
c4.map[L]=(f1*dW-V)*bu;c4.map[L+1]=(f1*aL-T)*fF}else if(w=="ZgZg"){var dW=0,aL=0,gE=fl*(.5-.5*Math.cos(f1*aP*2*Math.PI))*(1-f1);
if(j9==0){var h9=Math.atan2(T,V)-3.5*gE;dW=f1*Math.cos(h9);aL=f1*Math.sin(h9)}if(j9==1){gE=100/f*gE/f1;
dW=(1-gE)*V;aL=(1-gE)*T}if(j9==2){var r=512/f*gE*Math.PI/4;dW=r+V;aL=r+T}c4.map[L]=(dW-V)*bu;c4.map[L+1]=(aL-T)*fF}}}}}else if(w=="Shr "){var fZ=JSON.parse(JSON.stringify(W.ShrP.v));
E.MU.D(fZ,new eh(0,255/127,255/127,0,-2,0));var kr=E.MU.I5(fZ,c4.ag,!0);bJ=W.UndA.v.UndA=="WrpA"?2:1;
for(var Y=0;Y<c4.ag;Y++){var V=-kr[Y]*c4.gA;for(var K=0;K<c4.gA;K++){var L=Y*c4.gA+K<<1;c4.map[L]=V}}}else if(w=="Wave"){var d7=W.NmbG.v,az=W.WLMn.v,iC=W.WLMx.v,dc=W.AmMn.v*(Math.PI/4),cz=W.AmMx.v*(Math.PI/4),jq=W.SclH.v/100,iu=W.SclV.v/100,ib=W.Wvtp.v.Wvtp,gE=Math.sin;
if(ib=="WvTr")gE=function(K){K*=2/Math.PI;return-.5+Math.abs(K%2-1)};if(ib=="WvSq")gE=function(K){K*=2/Math.PI;
return 1+2*Math.floor(K%2-1)};var b$=[],ad=new E.s.my(W.RndS.v);for(var L=0;L<d7;L++){b$.push(ad.get()*10);
b$.push(Math.PI*c_/(az+ad.get()*(iC-az)));b$.push(jq*(dc+ad.get()*(cz-dc))/c_);b$.push(ad.get()*10);
b$.push(Math.PI*c_/(az+ad.get()*(iC-az)));b$.push(iu*(dc+ad.get()*(cz-dc))/c_)}var hC=[],ks=[],a$=Math.max(c4.gA,c4.ag);
for(var L=0;L<a$;L++){var V=0,T=0;for(var a_=0;a_<d7;a_++){var iE=a_*6;V+=b$[iE+2]*gE(b$[iE]+L*b$[iE+1]);
T+=b$[iE+5]*gE(b$[iE+3]+L*b$[iE+4])}hC[L]=T;ks[L]=V}for(var Y=0;Y<c4.ag;Y++){for(var K=0;K<c4.gA;K++){var L=Y*c4.gA+K<<1;
c4.map[L]=ks[Y];c4.map[L+1]=hC[K]}}bJ=W.UndA.v.UndA=="WrpA"?2:1}else if(w=="Rple"){bJ=1;var fl=W.Amnt.v/100,bG=4,cC=[0,-.19,-.29,-.32,.92,.37,.93,.54,-.54,.42,-.29,-.58,-.67,.85,0,.64],aU=1,k9=1,hZ=0,bX=["Sml","Mdm","Lrg"].indexOf(W.RplS.v.RplS);
if(bX==0){aU=1;k9=.2;hZ=3}if(bX==2){aU=1;k9=2;hZ=-1;cC=cC.reverse()}var bT=function(K,Y){var d3=Math.cos,f5=0;
for(var L=0;L<bG;L++)for(var a_=0;a_<bG;a_++)f5+=cC[L*bG+a_]*d3(K*(L+hZ)-Y*(a_+hZ));return f5},dV=Math.floor(50/c_),be=new Float32Array(dV*dV*2),j5=k9*fl*.5/c_;
for(var Y=0;Y<dV;Y++)for(var K=0;K<dV;K++){var gV=aU*K*2*Math.PI/dV,cL=aU*Y*2*Math.PI/dV,eE=bT(gV,cL),V=(bT(gV+.01,cL)-eE)*100,T=(bT(gV,cL+.01)-eE)*100,L=(Y*dV+K)*2;
be[L]=V*j5;be[L+1]=T*j5}for(var Y=0;Y<c4.ag;Y++)for(var K=0;K<c4.gA;K++){var aL=Y%dV,dW=K%dV,L=Y*c4.gA+K<<1,hz=aL*dV+dW<<1;
c4.map[L]=be[hz];c4.map[L+1]=be[hz+1]}}}E.wH.U$(n.buffer,I.buffer,f,z,null,c4.map,c4.gA,c4.ag,bJ)}return I};
var ic={};ic.aAE="BrSm BrsL BrDR BrsW BrbW BrSp".split(" ");ic.NQ="LDBt LDBL LDLf LDTL LDTp LDTR LDRg LDBR".split(" ");
ic.Pm=["ScrC","ScrD","ScrL"];ic.Uk=["SDRD","SDHz","SDLD","SDVt"];ic.zR="TxBl TxCa TxFr TxTL TxBr TxBu TxSt".split(" ");
ic.Ij="LPBt LPBL LPLf LPTL LPTp LPTR LPRg LPBR".split(" ");ic.kl="GrnR GrSf GrSr GrnC GrCn GrnE GrSt GrnH GrnV GrSp".split(" ");
ic.ie=[[24,19,0],[24,19,1],[24,4],[24,19,2],[24,14],[12,67]];ic.names={ClrP:[0,[24,20,0]],Ct:[0,[24,20,1]],DryB:[0,[24,20,2]],FlmG:[0,[24,20,3]],Frsc:[0,[24,20,4]],NGlw:[0,[24,20,5]],PntD:[0,[24,20,6]],PltK:[0,[24,20,7]],PlsW:[0,[24,20,8]],PstE:[0,[24,20,9]],RghP:[0,[24,20,10]],SmdS:[0,[24,20,11]],Spng:[0,[24,20,12]],Undr:[0,[24,20,13]],Wtrc:[0,[24,20,14]],AccE:[1,[24,20,15]],AngS:[1,[24,20,16]],Crsh:[1,[24,20,17]],DrkS:[1,[24,20,18]],InkO:[1,[24,20,19]],Spt:[1,[24,20,20]],SprS:[1,[24,20,21]],Smie:[1,[24,20,22]],DfsG:[2,[24,20,23]],Gls:[2,[24,20,24]],OcnR:[2,[24,20,25]],BsRl:[3,[24,20,26]],ChlC:[3,[24,20,27]],Chrc:[3,[24,20,28]],Chrm:[3,[24,20,29]],CntC:[3,[24,20,30]],GraP:[3,[24,20,31]],HlfS:[3,[24,20,32]],NtPr:[3,[24,20,33]],Phtc:[3,[24,20,34]],Plst:[3,[24,20,35]],Rtcl:[3,[24,20,36]],Stmp:[3,[24,20,37]],TrnE:[3,[24,20,38]],WtrP:[3,[24,20,39]],GlwE:[4,[24,20,40]],Crql:[5,[24,20,41]],Grn:[5,[24,20,42]],MscT:[5,[24,20,43]],Ptch:[5,[24,20,44]],StnG:[5,[24,20,45]],Txtz:[5,[24,20,46]]};
ic._1=function(w){var n;if(w=="ClrP")n={Pncl:{t:"long",v:4},StrP:{t:"long",v:8},PprB:{t:"long",v:25}};
if(w=="Ct")n={NmbL:{t:"long",v:4},EdgS:{t:"long",v:3},EdgF:{t:"long",v:1}};if(w=="DryB")n={BrsS:{t:"long",v:4},BrsD:{t:"long",v:4},Txtr:{t:"long",v:2}};
if(w=="FlmG")n={Grn:{t:"long",v:4},HghA:{t:"long",v:0},Intn:{t:"long",v:10},FlRs:{t:"long",v:23068185}};
if(w=="Frsc")n={BrsS:{t:"long",v:2},BrsD:{t:"long",v:8},Txtr:{t:"long",v:1}};if(w=="NGlw")n={Sz:{t:"long",v:5},Brgh:{t:"long",v:15},Clr:{t:"Objc",v:{classID:"RGBC",Rd:{t:"doub",v:0},Grn:{t:"doub",v:0},Bl:{t:"doub",v:255}}}};
if(w=="PntD")n={Sz:{t:"long",v:10},Shrp:{t:"long",v:10},BrsT:{t:"enum",v:{BrsT:"BrSm"}}};if(w=="PltK")n={StrS:{t:"long",v:25},StDt:{t:"long",v:3},Sftn:{t:"long",v:2}};
if(w=="PlsW")n={HghS:{t:"long",v:20},Dtl:{t:"long",v:4},Smth:{t:"long",v:5}};if(w=="PstE")n={EdgT:{t:"long",v:2},EdgI:{t:"long",v:1},Pstr:{t:"long",v:2}};
if(w=="RghP")n={StrL:{t:"long",v:6},StDt:{t:"long",v:4},TxtT:{t:"enum",v:{TxtT:"TxCa"}},Scln:{t:"long",v:100},Rlf:{t:"long",v:20},LghD:{t:"enum",v:{LghD:"LDBt"}},InvT:{t:"bool",v:!1}};
if(w=="SmdS")n={StrL:{t:"long",v:2},HghA:{t:"long",v:0},Intn:{t:"long",v:10},FlRs:{t:"long",v:6399750}};
if(w=="Spng")n={BrsS:{t:"long",v:2},Dfnt:{t:"long",v:12},Smth:{t:"long",v:5},FlRs:{t:"long",v:218877241}};
if(w=="Undr")n={BrsS:{t:"long",v:6},TxtC:{t:"long",v:16},TxtT:{t:"enum",v:{TxtT:"TxCa"}},Scln:{t:"long",v:100},Rlf:{t:"long",v:4},LghD:{t:"enum",v:{LghD:"LDTp"}},InvT:{t:"bool",v:!1}};
if(w=="Wtrc")n={BrsD:{t:"long",v:9},ShdI:{t:"long",v:1},Txtr:{t:"long",v:3}};if(w=="AccE")n={EdgW:{t:"long",v:2},EdgB:{t:"long",v:38},Smth:{t:"long",v:5}};
if(w=="AngS")n={DrcB:{t:"long",v:50},StrL:{t:"long",v:15},Shrp:{t:"long",v:3}};if(w=="Crsh")n={StrL:{t:"long",v:9},Shrp:{t:"long",v:6},Strg:{t:"long",v:1}};
if(w=="DrkS")n={Blnc:{t:"long",v:5},BlcI:{t:"long",v:6},WhtI:{t:"long",v:2}};if(w=="InkO")n={StrL:{t:"long",v:4},DrkI:{t:"long",v:20},LghI:{t:"long",v:10}};
if(w=="Smie")n={StrW:{t:"long",v:10},StrP:{t:"long",v:5},Cntr:{t:"long",v:16}};if(w=="Spt")n={SprR:{t:"long",v:10},Smth:{t:"long",v:5},FlRs:{t:"long",v:10738420}};
if(w=="SprS")n={StrL:{t:"long",v:12},SprR:{t:"long",v:7},SDir:{t:"enum",v:{StrD:"SDRD"}},FlRs:{t:"long",v:893120664}};
if(w=="DfsG")n={Grns:{t:"long",v:6},GlwA:{t:"long",v:10},ClrA:{t:"long",v:15},FlRs:{t:"long",v:325892160}};
if(w=="Gls")n={Dstr:{t:"long",v:3},Smth:{t:"long",v:1},TxtT:{t:"enum",v:{TxtT:"TxTL"}},Scln:{t:"long",v:100},InvT:{t:"bool",v:!1}};
if(w=="OcnR")n={RplS:{t:"long",v:5},RplM:{t:"long",v:15},FlRs:{t:"long",v:64008840}};if(w=="BsRl")n={Dtl:{t:"long",v:11},Smth:{t:"long",v:7},LghD:{t:"enum",v:{LghD:"LDBt"}}};
if(w=="ChlC")n={ChrA:{t:"long",v:6},ChlA:{t:"long",v:6},StrP:{t:"long",v:1},FlRs:{t:"long",v:314004633}};
if(w=="Chrc")n={ChAm:{t:"long",v:1},Dtl:{t:"long",v:5},LgDr:{t:"long",v:50},GELv:{t:"bool",v:!0}};if(w=="Chrm")n={Dtl:{t:"long",v:4},Smth:{t:"long",v:4}};
if(w=="CntC")n={FrgL:{t:"long",v:11},BckL:{t:"long",v:7},TxtT:{t:"enum",v:{TxtT:"TxCa"}},Scln:{t:"long",v:100},Rlf:{t:"long",v:4},LghD:{t:"enum",v:{LghD:"LDTp"}},InvT:{t:"bool",v:!1}};
if(w=="GraP")n={StrL:{t:"long",v:7},LgDr:{t:"long",v:50},SDir:{t:"enum",v:{StrD:"SDRD"}},FlRs:{t:"long",v:55993248}};
if(w=="HlfS")n={HlSz:{t:"long",v:1},Cntr:{t:"long",v:5},ScrT:{t:"enum",v:{ScrT:"ScrD"}}};if(w=="NtPr")n={ImgB:{t:"long",v:25},Grns:{t:"long",v:10},Rlf:{t:"long",v:11},FlRs:{t:"long",v:52642770}};
if(w=="Phtc")n={Dtl:{t:"long",v:10},Drkn:{t:"long",v:4}};if(w=="Plst")n={ImgB:{t:"long",v:20},Smth:{t:"long",v:2},LghP:{t:"enum",v:{LghP:"LPTp"}}};
if(w=="Rtcl")n={Dnst:{t:"long",v:12},BlcL:{t:"long",v:40},WhtL:{t:"long",v:5},FlRs:{t:"long",v:301835400}};
if(w=="Stmp")n={LgDr:{t:"long",v:25},Smth:{t:"long",v:4}};if(w=="TrnE")n={ImgB:{t:"long",v:25},Smth:{t:"long",v:11},Cntr:{t:"long",v:17},FlRs:{t:"long",v:461109340}};
if(w=="WtrP")n={FbrL:{t:"long",v:15},Brgh:{t:"long",v:60},Cntr:{t:"long",v:80},FlRs:{t:"long",v:83852682}};
if(w=="GlwE")n={EdgW:{t:"long",v:1},EdgB:{t:"long",v:10},Smth:{t:"long",v:1}};if(w=="Crql")n={CrcS:{t:"long",v:15},CrcD:{t:"long",v:6},CrcB:{t:"long",v:9},FlRs:{t:"long",v:495615720}};
if(w=="Grn")n={Intn:{t:"long",v:40},Cntr:{t:"long",v:50},Grnt:{t:"enum",v:{Grnt:"GrnR"}},FlRs:{t:"long",v:217582197}};
if(w=="MscT")n={TlSz:{t:"long",v:12},GrtW:{t:"long",v:3},LghG:{t:"long",v:9},FlRs:{t:"long",v:25445584}};
if(w=="Ptch")n={SqrS:{t:"long",v:4},Rlf:{t:"long",v:8},FlRs:{t:"long",v:383529723}};if(w=="StnG")n={ClSz:{t:"long",v:10},BrdT:{t:"long",v:4},LghI:{t:"long",v:0},FlRs:{t:"long",v:319935998}};
if(w=="Txtz")n={TxtT:{t:"enum",v:{TxtT:"TxBr"}},Scln:{t:"long",v:100},Rlf:{t:"long",v:10},LghD:{t:"enum",v:{LghD:"LDBL"}},InvT:{t:"bool",v:!1}};
n.__name="Filter Gallery";n.classID="GEfc";n.GEfk={t:"enum",v:{GEft:w}};n.GELv={t:"bool",v:!0};return n};
ic.iA=function(w,n){for(var L=0;L<n.length;L++)~~(n[L]=(w[4*L]+w[4*L+1]+w[4*L+2])*(1/3))};ic.ank=function(w,n,W,D){var j=UPNG.quantize(w,n);
j={G2:j.inds,mR:j.plte};var I=Math.floor((W+D)*.015);if(I!=0)E.gq.atE(j.G2,W,D,I);return j};ic.Ld=function(w,n,W,D,j,I,U){w=W.GEfk.v.GEft;
var M=n.rect,m=M.m,l=M.n,A=m*l,g=W.FlRs?W.FlRs.v>>>1:0;function k(P){return P.o<<24|P.B<<16|P.k<<8|255}if(w=="ClrP")E._.a43(n.buffer,m,l,I.buffer,[W.Pncl.v,W.StrP.v,W.PprB.v]);
if(w=="Ct"){var $=W.NmbL.v,C=W.EdgS.v,f=ic.ank(n.buffer.buffer,$*2,m,l);for(var L=0;L<f.G2.length;L++)f.G2[L]++;
var z=new Uint8Array((m+2)*(l+2));E.B0(f.G2,new iB(1,1,m,l),z,new iB(0,0,m+2,l+2));var s=E.p.RF(z,m+2,l+2,C,!1),O=new eh(1,0,0,1,-1,-1);
for(var L=0;L<s.length;L++)E.p.D(s[L].path.w,O,s[L].path.w);var a=[],X=f.mR;for(var L=0;L<X.length;L++){var P=X[L].est.q;
a.push({o:Math.round(255*P[0]),B:Math.round(255*P[1]),k:Math.round(255*P[2]),dl:Math.round(255*P[3])})}var Z=E.Om(m,l);
for(var L=0;L<s.length;L++){var Y=s[L],P=a[Y.color-1];if(P.dl==0)continue;Z.fillStyle="rgba("+P.o+","+P.B+","+P.k+","+P.dl/255+")";
Z.beginPath();Typr.U.pathToContext({crds:Y.path.w,cmds:Y.path.F},Z);Z.fill()}if(!M.VY()){var K=Z.getImageData(0,0,m,l);
E.nX(K.data,I.buffer)}}if(w=="DryB")E._.avx(n.buffer,m,l,I.buffer,[W.BrsS.v,W.BrsD.v,W.Txtr.v]);if(w=="FlmG")E._.a3b(n.buffer,m,l,I.buffer,[W.Grn.v,W.HghA.v,W.Intn.v,g]);
if(w=="Frsc")E._.aql(n.buffer,m,l,I.buffer,[W.BrsS.v,W.BrsD.v,W.Txtr.v]);if(w=="NGlw")E._.as9(n.buffer,m,l,I.buffer,[W.Sz.v,W.Brgh.v,k(E.M.y_(W.Clr.v)),k(D),k(j)]);
if(w=="PltK")E._.acp(n.buffer,m,l,I.buffer,[W.StrS.v,W.StDt.v,W.Sftn.v]);if(w=="PstE")E._.agN(n.buffer,m,l,I.buffer,[W.EdgT.v,W.EdgI.v,W.Pstr.v]);
if(w=="RghP")E._.ajh(n.buffer,m,l,I.buffer,[W.StrL.v,W.StDt.v,ic.zR.indexOf(W.TxtT.v.TxtT),W.Scln.v,W.Rlf.v,ic.NQ.indexOf(W.LghD.v.LghD),W.InvT.v]);
if(w=="SmdS")E._.auG(n.buffer,m,l,I.buffer,[W.StrL.v,W.HghA.v,W.Intn.v,W.FlRs.v,g]);if(w=="Spng")E._.aqJ(n.buffer,m,l,I.buffer,[W.BrsS.v,W.Dfnt.v,W.Smth.v,W.FlRs.v,g]);
if(w=="Undr")E._.amW(n.buffer,m,l,I.buffer,[W.BrsS.v,W.TxtC.v,ic.zR.indexOf(W.TxtT.v.TxtT),W.Scln.v,W.Rlf.v,ic.NQ.indexOf(W.LghD.v.LghD),W.InvT.v]);
if(w=="Wtrc")E._.aoO(n.buffer,m,l,I.buffer,[W.BrsD.v,W.ShdI.v,W.Txtr.v]);if(w=="AccE")E._.aa5(n.buffer,m,l,I.buffer,[W.EdgW.v,W.EdgB.v,W.Smth.v]);
if(w=="AngS")E._.ap6(n.buffer,m,l,I.buffer,[W.DrcB.v,W.StrL.v,W.Shrp.v]);if(w=="Crsh")E._.amD(n.buffer,m,l,I.buffer,[W.StrL.v,W.Shrp.v,W.Strg.v]);
if(w=="DrkS")E._.atr(n.buffer,m,l,I.buffer,[W.Blnc.v,W.BlcI.v,W.WhtI.v]);if(w=="InkO")E._.ahz(n.buffer,m,l,I.buffer,[W.StrL.v,W.DrkI.v,W.LghI.v]);
if(w=="Smie")E._.a1U(n.buffer,m,l,I.buffer,[W.StrW.v,W.StrP.v,W.Cntr.v]);if(w=="DfsG")E._.awa(n.buffer,m,l,I.buffer,[W.Grns.v,W.GlwA.v,W.ClrA.v,k(j),g]);
if(w=="CntC")E._.apx(n.buffer,m,l,I.buffer,[W.FrgL.v,W.BckL.v,ic.zR.indexOf(W.TxtT.v.TxtT),W.Scln.v,W.Rlf.v,ic.NQ.indexOf(W.LghD.v.LghD),W.InvT.v,k(j),k(D)]);
if(w=="ChlC")E._.aiN(n.buffer,m,l,I.buffer,[W.ChrA.v,W.ChlA.v,W.StrP.v,g,k(j),k(D)]);var S=w=="GraP"||w=="Chrc"||w=="Plst"||w=="Rtcl"||w=="Stmp"||w=="TrnE";
if(S){var G=E.Q(m*l);if(w=="GraP")E._.aqg(n.buffer,m,l,I.buffer,[W.StrL.v,W.LgDr.v,ic.Uk.indexOf(W.SDir.v.StrD),g]);
if(w=="Chrc")E._.ayY(n.buffer,m,l,I.buffer,[W.ChAm.v,W.Dtl.v,W.LgDr.v]);if(w=="Plst")E._.a07(n.buffer,m,l,I.buffer,[W.ImgB.v,ic.Ij.indexOf(W.LghP.v.LghP),W.Smth.v]);
if(w=="Rtcl")E._.aol(n.buffer,m,l,I.buffer,[W.Dnst.v,W.BlcL.v,W.WhtL.v,g]);if(w=="Stmp")E._.aw$(n.buffer,m,l,I.buffer,[W.LgDr.v,W.Smth.v]);
if(w=="TrnE")E._.axP(n.buffer,m,l,I.buffer,[W.ImgB.v,W.Smth.v,W.Cntr.v,g]);E.hN(I.buffer,G,0);ic.D_(G,I.buffer,D,j)}if(w=="NtPr")E._.a77(n.buffer,m,l,I.buffer,[W.ImgB.v,W.Grns.v,W.Rlf.v,k(D),k(j),g]);
if(w=="WtrP")E._.a6y(n.buffer,m,l,I.buffer,[W.FbrL.v,W.Brgh.v,W.Cntr.v,g>>>1]);if(w=="Crql")E._.a1d(n.buffer,m,l,I.buffer,[W.CrcS.v,W.CrcD.v,W.CrcB.v,g]);
if(w=="Grn")E._.a7D(n.buffer,m,l,I.buffer,[W.Intn.v,ic.kl.indexOf(W.Grnt.v.Grnt),W.Cntr.v,k(D),k(j),g]);
if(w=="MscT")E._.an0(n.buffer,m,l,I.buffer,[W.TlSz.v,W.GrtW.v,W.LghG.v,g]);if(w=="Ptch")E._.a04(n.buffer,m,l,I.buffer,[W.SqrS.v,W.Rlf.v,g]);
if(w=="Phtc"){function V(fZ,im,M,h9){E.xX.ye(fZ,im,M,h9);for(var L=0;L<A;L++)im[L]=Math.max(0,Math.min(255,128+fZ[L]-im[L]))}var T=W.Dtl.v,R=W.Drkn.v,x=E.Q(A);
E.fo(n.buffer,x);var v=E.Q(A);V(x,v,M,1);if(T==1){T=2;R=Math.round(R/4)}var N=E.Q(A);V(x,N,M,T);for(var L=0;
L<A;L++)x[L]=Math.max(0,Math.min(255,255-(v[L]-N[L])*R));ic.D_(x,I.buffer,D,j)}if(w=="Spt"||w=="SprS"){var u,H=1,F=1;
u={gA:Math.floor(m/F),ag:Math.floor(l/F)};u.map=new Float32Array(u.gA*u.ag*2);var t=new E.s.my(W.FlRs.v),o=new Float32Array(8192),q=W.SprR.v,_=q<20?.018*q:.36+(q-20)*.128;
if(w=="SprS"){_=.07+[0,.02,.04,.06,.08,.1,.12,.14,.16,.18,.2,.22,.24,.26,.28,.3,.34,.38,.5,.65,.75,.85,1,1.5,2.2,3][q]}for(var L=0;
L<8192;L++)o[L]=(-1+2*t.get())*_*70;for(var d=0;d<l;d++)for(var r=0;r<m;r++){var p=d*m+r<<1;u.map[p]=o[p%7919];
u.map[p+1]=o[(p+1)%7919]}var Q=u.map.slice(0),B=w=="Spt"?W.Smth.v-1:1;if(w=="Spt"&&B!=0){ic.a4t(u.map,Q,m,l,B);
ic.a55(Q,u.map,m,l,B)}if(w=="SprS"){var i=W.StrL.v>>>1,c=i==0?2:1;ic.a4t(u.map,Q,m,l,c);ic.a55(Q,u.map,m,l,c);
if(i!=0){var h2=ic.Uk.indexOf(W.SDir.v.StrD),jX=[1,1,1,0][h2],bm=[-1,0,1,1][h2],dC=2*i+1,fn=1/dC;for(var d=0;
d<l;d++)for(var r=0;r<m;r++){var p=d*m+r<<1,fK=0,i6=0;for(var L=0;L<dC;L++){var dh=Math.max(0,Math.min(m-1,r-(i+L)*jX)),kA=Math.max(0,Math.min(l-1,d-(i+L)*bm)),ig=kA*m+dh<<1;
fK+=u.map[ig];i6+=u.map[ig+1]}Q[p]=fK*fn;Q[p+1]=i6*fn}u.map=Q}}E.wH.U$(n.buffer,I.buffer,m,l,null,u.map,u.gA,u.ag,H)}if(w=="BsRl"||w=="PlsW"||w=="Chrm"){var iJ=Date.now(),fL=E.Q(A),fB=fL.slice(0);
E.fo(n.buffer,fL);var T=W.Dtl.v,ah=W.Smth.v;if(T!=15){E.xX.So(fL,fB,M,Math.round((15-T)*.5));E.nX(fB,fL)}var gL=1.4/m,e_=1.4/l,c2=new Float32Array(A),jS=new Float32Array(A),ie=new Float32Array(I.buffer.buffer);
for(var d=0;d<l;d++)for(var r=0;r<m;r++){var L=d*m+r,jX=r==m-1?fL[L]-fL[L-1]:fL[L+1]-fL[L],bm=d==l-1?fL[L]-fL[L-m]:fL[L+m]-fL[L],as=r*gL-.7,gb=d*e_-.7;
c2[L]=jX==0?as:jX*.4;jS[L]=bm==0?gb:bm*.4}if(w=="BsRl"){var gx=(2+ic.NQ.indexOf(W.LghD.v.LghD))*Math.PI*.25,fK=Math.cos(gx);
if(Math.abs(fK)<.1)fK=0;fK=Math.sign(fK);var i6=Math.sin(gx);if(Math.abs(i6)<.1)i6=0;i6=Math.sign(i6);
var eo=1/(fK*fK+i6*i6);for(var d=0;d<l;d++)for(var r=0;r<m;r++){var L=d*m+r,di=Math.max(-1,Math.min(1,fK*c2[L])),d0=Math.max(-1,Math.min(1,i6*jS[L]));
fB[L]=128+127*(di+d0)*eo}if(ah!=1){E.xX.So(fB,fL,M,Math.round((ah-1)*.5));E.nX(fL,fB)}ic.D_(fB,I.buffer,D,j)}else{if(w=="Chrm")ah=5+ah;
if(ah>1)ic.ks(c2,jS,ie,M,ah-1);if(w=="PlsW"){var e6=new Uint8Array(c2.buffer);for(var L=0;L<A;L++){var dt=L<<2,jX=c2[L],bm=jS[L],gJ=1/(Math.sqrt(1+jX*jX)*Math.sqrt(1+bm*bm)),iW=gJ*gJ,g5=iW*iW,P=~~(255*(g5*g5*iW));
e6[dt+0]=P;e6[dt+1]=P;e6[dt+2]=P;e6[dt+3]=P}I.buffer.set(n.buffer);E.s._U("norm",e6,M,I.buffer,M,M,W.HghS.v/20)}else if(w=="Chrm"){var jW=I.buffer,eP=m>>>1,b_=l>>>1;
for(var L=0;L<A;L++){var dt=L<<2,jX=c2[L],bm=jS[L],fZ={x:1,y:0,YD:jX};ge.Hx(fZ);var im={x:0,y:1,YD:bm};
ge.Hx(im);var j3=ge.acH(fZ,im),dr=1/j3.YD,c0=~~Math.max(0,Math.min(m-1,eP-j3.x*dr*eP)),fM=~~Math.max(0,Math.min(l-1,b_-j3.y*dr*b_)),P=fL[fM*m+c0];
jW[dt+0]=P;jW[dt+1]=P;jW[dt+2]=P}}}}if(w=="Gls"||w=="OcnR"||w=="Txtz"){var cB=w=="OcnR"?2:ic.zR.indexOf(W.TxtT.v.TxtT),iI=ic.Yh(cB),jD=iI[0],fL=iI[1],j8=jD.m,jG=jD.n,dC=24,dQ=0,ep,b2;
function i1(eA,cN,a4){return~~(bH*(eA+cN)+8192)&127}var c2=new Float32Array(A),jS=new Float32Array(A),ie=new Float32Array(I.buffer.buffer),bH=w=="OcnR"?1/(1+(W.RplS.v-1)*.1):100/W.Scln.v;
if(cB==3)bH*=32/22.2;var iJ=Date.now(),a_=bH,gL=1.4/m,e_=1.4/l;if(w=="Txtz"){a_*=1/255;dC=256}for(var d=0;
d<l;d++){var aR=i1(d,M.y,jG),kA=aR+1&127;for(var r=0;r<m;r++){var L=d*m+r,iY=i1(r,M.x,j8),dh=iY+1&127,gy=0,gr=0,fs=0;
if(w=="Txtz"){gy=E.K.iL(bH*r,bH*d,fL,128,128);gr=E.K.iL(bH*r,bH*d+1,fL,128,128);fs=E.K.iL(bH*r+1,bH*d,fL,128,128)}else{gy=fL[aR*j8+iY];
gr=fL[kA*j8+iY];fs=fL[aR*j8+dh]}c2[L]=Math.max(-dC,Math.min((fs-gy)*a_,dC));jS[L]=Math.max(-dC,Math.min((gr-gy)*a_,dC))}}if(w=="Txtz")ic.amg(c2,jS,ie,M,6);
else ic.ks(c2,jS,ie,M,w=="Txtz"?1:w=="OcnR"?3.5/bH:W.Smth.v);if(w=="Txtz")dQ=W.InvT.v?-1:1;else if(w=="Gls"){dQ=[1,.4,.5,.5][cB]*(Math.exp(W.Dstr.v*.155)-1);
if(W.InvT.v)dQ=-dQ}else{dQ=.5*(Math.exp(W.RplM.v*.155)-1)}var jW=I.buffer;if(w=="Txtz"){var gx=(2+ic.NQ.indexOf(W.LghD.v.LghD))*Math.PI*.25,fK=Math.cos(gx),i6=Math.sin(gx);
ep={x:fK,y:i6,YD:0};ge.Hx(ep);b2=W.Rlf.v;b2=b2/4+Math.max(0,(b2-35)*2)}function eX(fZ,im,en){var ik=E.s.overF(im,fZ,1),eA=(1-en)*fZ+en*(en*im+(1-en)*ik);
return eA*255}for(var d=0;d<l;d++)for(var r=0;r<m;r++){var L=d*m+r,dt=L<<2,jX=c2[L],bm=jS[L],fZ={x:1,y:0,YD:jX};
ge.Hx(fZ);var im={x:0,y:1,YD:bm};ge.Hx(im);var j3=ge.acH(fZ,im);if(w=="Txtz"){var iz=ge.aj2(j3,ep)*dQ,en=1,P=1;
if(iz<0){P=0;iz=-iz}en=Math.min(1,iz*b2);jW[dt+0]=~~eX(n.buffer[dt]*(1/255),P,en);jW[dt+1]=~~eX(n.buffer[dt+1]*(1/255),P,en);
jW[dt+2]=~~eX(n.buffer[dt+2]*(1/255),P,en)}else{var dr=dQ/j3.YD,c0=~~Math.max(0,Math.min(m-1,r-j3.x*dr)),fM=~~Math.max(0,Math.min(l-1,d-j3.y*dr)),ko=fM*m+c0<<2;
jW[dt+0]=n.buffer[ko];jW[dt+1]=n.buffer[ko+1];jW[dt+2]=n.buffer[ko+2]}}}if(w=="PntD"){var fh=W.Shrp.v*.4,d1=W.BrsT.v.BrsT,j_={BrSm:[.75],BrsL:[.85],BrDR:[.68],BrsW:[.75],BrbW:[.78],BrSp:[.62]}[d1],h9=Math.round(W.Sz.v*.5);
E.h1.QB=j_[0];E.h1.jI(n.buffer,I.buffer,m,l,h9,0,[]);var ha=[-.7,-1,-.7,-1,10,-1,-.7,-1,-.7];ha=E.Z3.kd(ha);
var fl=I.buffer.slice(0);E.Z3.yz(fl,I.buffer,m,l,ha,0);for(var L=0;L<n.buffer.length;L++){var ex=I.buffer[L]-fl[L];
I.buffer[L]=Math.max(0,Math.min(255,fl[L]+fh*ex))}}if(w=="GlwE"){var aI=I.buffer.slice(0);E.h1.QB=.5;
E.h1.jI(n.buffer,aI,m,l,W.Smth.v>>>1,0,[]);E.Z3.eh(aI,I.buffer,m,l);E.nX(I.buffer,aI);E.Ba(aI);E.cJ(aI,4278190080,16777215);
E.nx.anO(aI,I.buffer,m,l,(W.EdgW.v>>>1)*2+1,!0);var ba=W.EdgB.v/10;for(var L=0;L<aI.length;L++){if((L&3)==3)continue;
var ik=I.buffer[L];I.buffer[L]=Math.max(0,Math.min(255,ik*ba))}}if(w=="StnG"){E.C1.a28(n.buffer,m,l,I.buffer,W.ClSz.v,[Math.round(D.o),Math.round(D.B),Math.round(D.k)],W.BrdT.v)}if(w=="HlfS"){var c3=W.HlSz.v,br=c3*2+1,bi=W.Cntr.v,cZ=ic.Pm.indexOf(W.ScrT.v.ScrT),A=m*l,ib=A*4,hb=E.Q(A),kg=n.buffer,iO=0,fj=0;
ic.iA(kg,hb);var kh=hb.slice(0);E.xX.KA(kh,hb,M,c3);var ct=Math.PI/br,cy=new Float64Array(m),fK=new Float64Array(m),hA=new Float64Array(2*m);
for(var r=0;r<m;r++){var iY=(r-(m>>>1))*ct;cy[r]=iY*iY;fK[r]=Math.cos(iY);var jX=r<<1;hA[jX]=Math.sin(jX*(1/4.5));
hA[jX+1]=Math.sin((jX+1)*(1/4.5))}for(var d=0;d<l;d++){var aR=(d-(l>>>1))*ct,i6=Math.cos(aR),io=aR*aR;
for(var r=0;r<m;r++){var P=i6;if(cZ==0){var fX=.5+Math.sqrt(cy[r]+io)*4.5;P=hA[~~fX]}else if(cZ==1){P=fK[r]*i6}var L=d*m+r,a0=hb[L]*(.75+.25*P),en=kg[(L<<2)+3]*(1/255),ia=Math.max(0,Math.min(255,~~a0));
iO+=ia*en,fj+=en;hb[L]=ia}}iO/=fj;var eK=128+1.26*(iO-128),ba=.08+.25*Math.abs((128-iO)/128),hH=1+ba*bi;
for(var L=0;L<A;L++){var a0=eK+(hb[L]-eK)*hH;hb[L]=Math.max(0,Math.min(255,~~a0))}if(bi>46)E.round(hb);
ic.D_(hb,I.buffer,D,j)}for(var L=0;L<n.buffer.length;L+=4)I.buffer[L+3]=n.buffer[L+3]};ic.D_=function(w,n,W,D){var j=w.length,I=W.o,U=W.B,M=W.k,m=D.o,l=D.B,A=D.k;
for(var L=0;L<j;L++){var g=w[L]*(1/255),k=1-g,$=L<<2;n[$]=~~(I*k+m*g);n[$+1]=~~(U*k+l*g);n[$+2]=~~(M*k+A*g)}};
ic.Yh=function(w){if(w==6)w=2;var n="blocks canvas frosted tinylens brick burlap".split(" ")[w];if(ic.Hn==null)ic.Hn=[];
if(ic.Hn[w]==null){var W,D;if(w==2){D=new iB(0,0,128,128);var j=cx._1("AdNs");j.Mnch.v=!0;j.Dstr.v.Dstr="Gsn";
j.Nose.v.val=50;var W=E.Q(D.O()*4),I=W.slice(0);new Uint32Array(I.buffer).fill(4286611584);cx.Ld("AdNs",{buffer:I,rect:D},j,0,0,{buffer:W,rect:D})}else{var U=jj.gF.get("tex/"+n,!0)[0];
D=U.XL;W=new Uint8Array(U.data)}var M=E.Q(D.O());E.hN(W,M,0);ic.Hn[w]=[D,M]}return ic.Hn[w]};ic.ks=function(w,n,W,D,j){if(j<=1){j=Math.round(j);
ic.amg(w,n,W,D,[1,16,4][j]);return}var I=j*.42;if(w){E.xX.uf(w,W,D,I,3);w.set(W)}if(n){E.xX.uf(n,W,D,I,3);
n.set(W)}};ic.amg=function(w,n,W,D,j){var I=E.Z3.kd([1,2,1,2,j,2,1,2,1]);if(w){W.set(w);E.Z3.G0(w,W,D.m,D.n,I);
w.set(W)}if(n){W.set(n);E.Z3.G0(n,W,D.m,D.n,I);n.set(W)}};ic.R5=function(w){if(w==null)return new ec(0,0);
var n=0,W=w.GEfs?w.GEfs.v:[{v:w}];for(var L=0;L<W.length;L++){var D=W[L].v,I=1e4;if(D.GELv&&!D.GELv.v)continue;
var j=D.GEfk.v.GEft;if(j=="GlwE"||j=="Phtc"||j=="BsRl"||j=="PlsW"||j=="Chrm"||j=="Gls"||j=="OcnR"||j=="InkO")I=0;
n=Math.max(n,I)}return new ec(n,n)};ic.aoF=function(w){var n=[0,0,0,0,0,0,0,0,0,0,0,0,0],W=[0,.6,.7,.8,1,1.2,1.4,1.6,1.8,2,2.2,2.6,3,4,5][w];
for(var L=0;L<13;L++){var D=L-6;n[L]=1/(W*Math.sqrt(2*Math.PI))*Math.exp(-.5*(D/W)*(D/W))}return n};
ic.a4t=function(w,n,W,D,j){var I=ic.aoF(j),U=6,M=13;for(var m=0;m<D;m++)for(var l=0;l<W;l++){var A=m*W+l<<1,g=0,k=0;
for(var L=0;L<M;L++){var $=l+L-U,C=$<0?0:$>=W?W-1:$,f=(m*W+C)*2,z=I[L];g+=z*w[f];k+=z*w[f+1]}n[A]=g;
n[A+1]=k}};ic.a55=function(w,n,W,D,j){var I=ic.aoF(j),U=6,M=13;for(var m=0;m<D;m++)for(var l=0;l<W;l++){var A=m*W+l<<1,g=0,k=0;
for(var L=0;L<M;L++){var $=m+L-U,C=$<0?0:$>=D?D-1:$,f=(C*W+l)*2,z=I[L];g+=z*w[f];k+=z*w[f+1]}n[A]=g;
n[A+1]=k}};function dD(){}dD.E5=[2,5,5,7,4,4];dD.mS="norm,diss,dark,mul ,idiv,lbrn,dkCl,lite,scrn,div ,lddg,lgCl,over,sLit,hLit,vLit,lLit,pLit,hMix,diff,smud,fsub,fdiv,hue ,sat ,colr,lum ".split(",");
dD.ik="Nrml Dslv Drkn Mltp CBrn linearBurn darkerColor Lghn Scrn CDdg linearDodge lighterColor Ovrl SftL HrdL vividLight linearLight pinLight hardMix Dfrn Xclu blendSubtraction blendDivide H Strt Clr Lmns".split(" ");
dD.AE=[[15,10,0],[15,10,1],[15,10,2],[15,10,3],[15,10,4],[15,10,5],[15,10,6],[15,10,7],[15,10,8],[15,10,9],[15,10,10],[15,10,11],[15,10,12],[15,10,13],[15,10,14],[15,10,15],[15,10,16],[15,10,17],[15,10,18],[15,10,19],[15,10,20],[15,10,21],[15,10,22],[15,10,23],[15,10,24],[15,10,25],[15,10,26]];
dD.R3=["normal",null,"darken","multiply","color-burn",null,null,"lighten","screen","color-dodge",null,null,"overlay","soft-light","hard-light",null,null,null,null,"difference","exclusion",null,null,"hue","saturation","color","luminosity"];
dD.XK=function(w){if(w=="passThrough")return"pass";return dD.mS[dD.ik.indexOf(w)]};dD.Eu=function(w){if(w=="pass")return"passThrough";
return dD.ik[dD.mS.indexOf(w)]};dD.getName=function(w){return dD.AE[dD.mS.indexOf(w)]};function h(){this.rect=null;
this.buffer=null;this.Bx="norm";this.opacity=255;this.QY=!1;this.FK=0;this.Ux=0;this.lj=!0;this.kQ=[];
for(var L=0;L<10;L++)this.kQ.push(0,0,255,255);this.name=null;this.add={};this.fq=null;this.Ic=null;
this.z=null;this.pv=null;this.a2j=30;this.ji=null;this.pO=null;this.bA=null;this.RX=null;this.eL=0;this.na=!1;
this.zZ=null;this.US=new h.fw}h.fw=function(){this.jA=!0;this.Wq=!0;this.gY=E.Q(0);this.a93=E.Q(0);this.zm=null;
this.IH={};this.aam=null;this.mI=null;this.x5=null;this.zO=null;this.z9=null;this.kh=null;this.kB=null;
this.EG=null;this.AT=null;this.hX=null;this.j1=null;this.cL=null;this.sI=!1};h.fw.prototype.aje=function(){this.jA=null;
this.Wq=!1;this.zm=null;this.sI=je.YG};h.fw.prototype.a98=function(){ge.a9o(this.IH);this.gY=E.Q(0);
this.a93=E.Q(0);if(this.zO)this.zO.delete();if(this.z9)this.z9.delete();this.zO=null;this.z9=null;var w=[this.kh,this.kB,this.EG,this.AT,this.hX,this.j1];
for(var L=0;L<6;L++)if(w[L]!=null&&w[L]instanceof je.H0)w[L].delete();this.kh=null;this.kB=null;this.EG=null;
this.AT=null;this.hX=null;this.j1=null};h.prototype.l=function(w){if(w==null)w=this.rect.clone();if(this.US.zm==null)this.US.zm=w;
else this.US.zm=this.US.zm.x0(w)};h.prototype.ue=function(){return this.add.lsct==ef.fz||this.add.lsct==ef.Se};
h.prototype.I9=function(){var w=this.add;return w.SoCo!=null||w.GdFl!=null||w.PtFl!=null};h.prototype.aqs=function(){var w=this.add.lmfx;
if(w==null)return;var n=["GrFl","patternFill"];for(var L=0;L<n.length;L++){var W=at.Pa[at.order.indexOf(n[L])],D=w[W].v;
if(D.length==0)continue;for(var j=0;j<D.length;j++){var I=D[j].v;if(I.enab.v&&(I.Algn==null||!I.Algn.v))this.US.Wq=!0}}};
h.prototype.amU=function(){var w=this.z,n=this.US.jA;if(this.I9())w=this._N();if(!je.YG)return w.Ob();
if(this.US.z9==null||n||je.YG!=this.US.sI){var W=w.pJ(),D=this.US.z9,j=null;if(n!=!0&&n!=null){j=n.clone();
j.offset(-W.x,-W.y)}if(D==null||D.m!=W.m||D.n!=W.n){D=this.US.z9=new je.dt(W.m,W.n);j=null}D.set(w.Ob(),j)}return this.US.z9};
h.prototype.awG=function(w){var n=this.rect,W=this.buffer;if(!je.YG){var D=this.Nu(w,W,n);if(D){W=D.Q0;
n=D.rect}return W}if(this.US.zm!=null||je.YG!=this.US.sI){var D=this.Nu(w,W,n);if(D){W=D.Q0;n=D.rect}var j=n;
if(je.YG!=this.US.sI||this.US.zO==null||this.US.zO.m!=j.m||this.US.zO.n!=j.n){if(this.US.zO)this.US.zO.delete();
this.US.zO=new je.H0(j.m,j.n);this.US.zO.set(W)}else{var I=this.US.zm.clone();I.offset(-n.x,-n.y);this.US.zO.set(W,I)}}return this.US.zO};
h.prototype.f6=function(){var w=this.z;if(this.I9())w=this._N();return w!=null&&w.isEnabled&&(!w.rect.VY()||w.y_()!=255)};
h.prototype.Nu=function(w,n,W){if(this.YC()){var D=this.NP(w);if(D.z&&D.z.isEnabled&&(!D.z.rect.VY()||D.z.color==0)){var j=this.add.SoLd.filterFX.v;
D.z.MX=j.filterMaskDensity?j.filterMaskDensity.v:255;D.z.C3=j.filterMaskFeather?j.filterMaskFeather.v:0;
var I=D.buffer,U=D.rect;if(U.O()<W.O()){U=W;I=E.Q(U.O()*4);E.Cb(D.buffer,D.rect,I,U)}var M=D.z.Ln(W);
E.Ba(M);n=n.slice(0);E.s.eY(I,U,n,W,M,W,0,W,1);return{Q0:n,rect:W}}}};h.prototype.a7y=function(){var w={no:!1,qW:!1,$c:0,D8:0};
if(this.add.vmsk&&this.add.vmsk.isEnabled)w.qW=!0;if(this._N()&&this._N().isEnabled)w.no=!0;if(w.no&&w.qW){w.$c=this._N().rect.x-this.add.vmsk._N().rect.x;
w.D8=this._N().rect.y-this.add.vmsk._N().rect.y}return w};h.prototype.yb=function(w,n){this.US.gj=null;
if(n&&this._N().C3!=0){n=n.clone();var W=Math.round(this._N().C3*2.4);n.VD(W,W)}var D=!1;if(this.add.lsct==ef.Cq)return;
var j=this,I=this._N()!=null&&this._N().eP,U=this.add.vmsk!=null&&this.add.vmsk.eP,M=this.a7y(),m=JSON.stringify(M)!=this.US.aam||M.no&&I||M.qW&&U;
if(m){if(M.qW){var l=this.add.vmsk._N();if(M.no){this.z=this._N().y9(l);this.US.mI=new ec(this.z.rect.x-this._N().rect.x,this.z.rect.y-this._N().rect.y)}else this.z=l}if(this.z)D=!0;
if(this.z)this.US.x5=new ec(this.rect.x-this.z.rect.x,this.rect.y-this.z.rect.y);if(M.no)this._N().eP=!1;
if(M.qW)this.add.vmsk.eP=!1;this.l(n)}else{if(M.no&&M.qW){this.z.rect.x=this._N().rect.x+this.US.mI.x;
this.z.rect.y=this._N().rect.y+this.US.mI.y}}if(j.I9()){this.sO(w)}if(j.oK()){var A;if(this.z)A=new ec(this.rect.x-this.z.rect.x,this.rect.y-this.z.rect.y);
if(this.z&&this.z.isEnabled&&(this.US.x5==null||!A.s9(this.US.x5))){this.US.x5=A;this.l(n);D=!0}}if(eH.get(j.add)!=null)D=!0;
if(D){var g=this.US.jA;if(n&&g&&g!=!0)g=g.x0(n);else g=n?n:!0;this.US.jA=g}this.US.aam=JSON.stringify(M)};
h.prototype.sO=function(w){var n=this,W=n.add.vstk,D=new iB(0,0,w.m,w.n),j,I=n.add.vmsk?this.add.vmsk._N():null,m=!0,g;
if(I&&I.isEnabled&&I.y_()==0)j=I.pJ().clone();else j=D;var U=n._N();if(U&&U.isEnabled&&U.y_()==0)j=j.wU(n.z.pJ());
var M=I&&W;if(W&&(!W.strokeEnabled.v||W.strokeStyleLineWidth.v.val==0))M=!1;if(W&&!W.fillEnabled.v&&M)m=!1;
var l=E.Q(j.O()*4);if(m){if(n.add.SoCo)ge.Cw(l,n.add.SoCo.Clr.v);if(n.add.GdFl){var A=I&&I.color==0?E.P.b3(n.add.vmsk.i,null,!0):null;
ge.zH(n.add.GdFl,l,j,w,null,A)}if(n.add.PtFl)ge.GP(n.add.PtFl,l,j,w.add.Patt,n.add.fxrp)}if(M)g=at.QO.n2.indexOf(W.strokeStyleLineAlignment.v.strokeStyleLineAlignment);
if(I){var k=I.MX;if(M)I.MX=255;var $=E.Q(j.O());if(I.y_()!=0)$.fill(Math.round(I.y_()));if(I&&I.isEnabled){var C=I.pJ(),f=I.Ob();
if(C.s9(j))E.nX(f,$);else E.B0(f,C,$,j)}if(M&&g==2){}else{if(n.add.SoCo&&m){E.IL($,l,3)}else E.AG($,j,l,j)}if(M)I.MX=k}n.buffer=l;
n.rect=j;if(M){var z=W.strokeStyleContent.v,s=at.QO.W_.indexOf(z.classID),O=this.add.vmsk._N(W);if(g!=0&&!n.rect.s9(D))n.extend(n.rect.x0(O.pJ()));
var k=O.MX;O.MX=255;var a=O.Ln(n.rect);O.MX=k;if(O.color==255)E.Ba(a);var X=E.Q(n.rect.O()*4);if(s==0)ge.Cw(X,z.Clr.v);
if(s==1)ge.zH(z,X,n.rect,w,null,I.color==0?I.rect:null);if(s==2)ge.GP(z,X,n.rect,w.add.Patt,n.add.fxrp);
var P=W.strokeStyleOpacity.v.val/100;if(P!=1)E.D9(a,P);if(O.color==255)g=2-g;if(g<2){E.s.eY(X,n.rect,n.buffer,n.rect,a,n.rect,255,n.rect,1,!1);
if(g==0)E.py($,n.buffer)}if(g==2){E.py(a,X);E.Ba($);E.s.eY(X,n.rect,n.buffer,n.rect,$,j,255,n.rect,1,!1);
E.Ba($)}if(O.MX!=255){var Z=X.slice(0);E.cJ(Z,4278190080,16777215);E.s._U("norm",Z,n.rect,n.buffer,n.rect,n.rect,1-O.MX/255)}k=I.MX;
I.MX=255;this.a93=I.Ln(n.rect);I.MX=k}this.l()};h.prototype.vr=function(w,n,W){var D=this,j=D.add.SoLd.Idnt.v,I=D.add.SoLd,U=E.p.mY(y.wR.Aa(I.nonAffineTransform)),M=w.Zy(j,I.Crop?I.Crop.v:null,[U.m,U.n],I.Impr.v.classID,W),$=1;
if(M==null)return;var m=M.PO;I.Sz.v.Wdth.v=m[1].m;I.Sz.v.Hght.v=m[1].n;var l=M.hh==null?I.Rslt.v.val:M.hh,A=I.warp.v,g=y.wR.Aa(I.nonAffineTransform),k=m[1].clone();
k.m*=$;k.n*=$;k.x=(m[1].m-k.m)/2;k.y=(m[1].n-k.n)/2;var C=E.K.kN(g,k);if(A&&!E.XB.pi(A)){var U=E.p.mY(E.XB.BI(A)),f=U.x,z=U.y,s=1/U.m,O=1/U.n;
C=E.K.kN(g);C=E.K.y9(C,[s,0,-f*s,0,O,-z*O,0,0])}var a=y.wR.z3(m,n?0:1,C,A,null,null,null,n);if(a==null){D.buffer=E.Q();
D.rect=new iB}else if(D.YC()){var X=D.NP(w);X.buffer=a.buffer;X.rect=a.rect.clone();this.AK(w,n)}else{D.buffer=a.buffer;
D.rect=a.rect}D.yb(w);D.l();w.l()};h.prototype.AK=function(w,n){if(n==null)n=!1;var W=this.NP(w),D=this.add.SoLd.filterFX.v,j=cx.agD(D),I=new iB(0,0,w.m,w.n),U=W.rect.x0(I),M=W.rect.clone();
M.VD(j.x,j.y);var m={buffer:null,rect:U.wU(M)};m.buffer=E.Q(m.rect.O()*4);E.Cb(W.buffer,W.rect,m.buffer,m.rect);
if(D.enab.v&&n==!1){var l=D.filterFXList.v;for(var L=0;L<l.length;L++){var A=l[L].v;if(A.enab.v==!1)continue;
var g=A.blendOptions.v,k=dD.XK(g.Md.v.BlnM),$=g.Opct.v.val/100,C=E.M.y_(A.FrgC.v),f=E.M.y_(A.BckC.v),z=cx.iF(A),s={buffer:E.Q(m.buffer.length),rect:m.rect.clone()},O=A.Fltr?A.Fltr.v:null;
if(eH.SM[z]!=null){var a=eH.SM[z],X=eH.rw(a,O);if(X)eH.Ld(X,m.buffer,s.buffer,m.rect)}else cx.Ld(z,m,O,C,f,s,[w.add.lnk2?w.add.lnk2:[],this._N(),w.yo]);
if(k=="norm"&&$==1)m=s;else if(k=="norm"){E.s.eY(s.buffer,s.rect,m.buffer,m.rect,null,null,null,m.rect,$)}else{E.s._U(k,s.buffer,s.rect,m.buffer,m.rect,m.rect,$)}}}this.rect=m.rect;
this.buffer=m.buffer;this.ky();this.l();w.l()};h.prototype.Eo=function(w,n,W){this.zZ=this.apF(w,n,W)};
h.prototype.WC=function(w,n){var W=this.apF(w,n,!0);if(W==null)return null;var D={LM:W.eL,Ey:W.WL,rect:W.M0};
if(D.LM==1||D.LM==3){var j=D.rect,I=E.Q(j.m*j.n*4);E.IL(D.Ey,I,0);E.IL(D.Ey,I,1);E.IL(D.Ey,I,2);E.MN(w.J.channel,w.J.rect,I,j);
D.Ey=I}return D};h.prototype.apF=function(w,n,W){var D,j,I,U,M,m,l;if(this.eL<=0){var A=E.Q(this.rect.O());
E.hN(this.buffer,A,3);D=E.nj.VP(n,{channel:A,rect:this.rect},3);if(D==null)return null;var g=E.Nb(D.channel,D.rect);
U=D.rect.clone();M=this.rect.clone();j=E.Q(U.O()*4);E.Cb(this.buffer,M,j,U);E.IL(D.channel,j,3);I=this.buffer.slice(0);
if(!W){var k=n.channel.slice(0);E.Ba(k);E.AG(k,n.rect,I,M)}m=this.buffer.slice(0);l=this.rect.clone()}if(this.eL==1||this.eL==3){var $=this.eL==1?this._N():this.NP(w).z;
U=n.rect.clone();M=$.rect.clone();j=$.Tt(U);var I=$.channel.slice(0);if(!W)E.s.gZ($.color==255?E.PL(U.O()):E.LR(U.O()),U,I,M,n.channel,U,1);
m=$.channel.slice(0);l=$.rect.clone()}return{eL:this.eL,WL:j,M0:U,H8:I,Ox:M,IP:m,__:l}};h.prototype.$H=function(w,n){var W=this.zZ;
if(W.eL==0){this.rect=W.__;this.buffer=W.IP;this.l()}if(W.eL==1||W.eL==3){var D=W.eL==1?this._N():this.NP(w).z;
D.channel=W.IP;D.rect=W.__;if(this.eL==1){D.eP=!0;this.yb(w)}if(this.eL==3)this.l()}this.zZ=n};h.prototype.er=function(w,n){if(this.eL<=0&&n.rect.s9(this.rect)){var W=E.Q(this.rect.O());
E.hN(this.buffer,W,3);if(E.s9(w.J.channel,W)){var D=this.rect,j=this.buffer;this.zZ={eL:this.eL,WL:j.slice(0),M0:D.clone(),H8:E.Q(0),Ox:new iB,IP:E.Q(0),__:new iB};
return!0}}var I=this.zZ;if(I==null)return!1;if(I.eL!=this.eL)return!1;if(!n.rect.s9(I.M0))return!1;var U=I.Ox.x0(I.M0);
if(I.eL<=0){if(!U.s9(this.rect))return!1;var M=E.Q(I.WL.length>>2);E.hN(I.WL,M,3);if(!E.s9(n.channel,M))return!1;
var m=E.Q(U.m*U.n*4);E.Cb(I.H8,I.Ox,m,U);E.s._U("norm",I.WL,I.M0,m,U,U,1);return E.s9(m,this.buffer)}if(I.eL==1||I.eL==3){var l=I.eL==1?this._N():this.NP(w).z;
if(!U.s9(l.rect))return!1;var A=E.Q(U.O());A.fill(l.color);E.B0(I.H8,I.Ox,A,U);E.s.gZ(I.WL,I.M0,A,U,n.channel,U,1);
return E.s9(A,l.channel)}};h.prototype.p9=function(w,n,W,D){var j=this.zZ;j.M0.offset(n,W);var I=j.Ox.x0(j.M0);
if(j.eL<=0){var U=E.Q(I.O()*4);E.Cb(j.H8,j.Ox,U,I);E.s._U("norm",j.WL,j.M0,U,I,I,1);this.buffer=U;this.rect=I;
this.l()}else{var M=this.eL==1?this._N():this.NP(w).z,m=E.Q(I.O());m.fill(M.color);E.B0(j.H8,j.Ox,m,I);
E.s.gZ(j.WL,j.M0,m,I,D.channel,I,1);M.channel=m;M.rect=I.clone();if(this.eL==1){M.eP=!0;this.yb(w)}if(this.eL==3)this.l()}};
h.prototype.ag7=function(){var w=[-1,0,1,2];if(this.z)w.push(-2);if(this.pv)w.push(-3);return w};h.prototype.getName=function(){return this.add.luni?this.add.luni:this.name};
h.prototype.nz=function(bK){this.add.luni=this.name=bK};h.prototype.iQ=function(w){var n=this.add.lnsr,W=this.add.TySh;
if(n=="rend"&&W){var D=hd.Bb(W._o);this.nz(D.slice(0,D.length-1).replace(/(?:\r\n|\r|\n)/g," ").slice(0,32))}};
h.prototype.I4=function(){return(this.FK&1<<1)==0};h.prototype.oK=function(){return(this.FK&1<<4)==0};
h.prototype.IF=function(){return(this.FK&1<<5)!=0};h.prototype.at0=function(){var w=this;if(w.add.lnsr!="bgnd"){w.add.lnsr="bgnd";
w.nz("Background");w.add.lspf=1<<2}};h.prototype.abc=function(){var w=this;if(w.add.lnsr=="bgnd"){delete w.add.lnsr;
w.nz("Layer 0");w.add.lspf=0}};h.prototype.m7=function(w){var n=this.add.lspf;return n==null?!1:(n>>w&1)!=0};
h.prototype.gb=function(w){if(w&&!this.I4())this.FK-=2;if(!w&&this.I4())this.FK+=2};h.prototype.Z_=function(){var w=this.add.lmfx;
if(w==null)return!1;for(var n in w){if(n=="masterFXSwitch")continue;if(n=="Scl")continue;if(n=="classID")continue;
if(w[n].v.length>0)return!0}return!1};h.prototype.YC=function(){return this.add.SoLd!=null&&this.add.SoLd.filterFX!=null};
h.prototype.Jp=function(){var w=this.add.lmfx;if(w==null)return!1;if(!w.masterFXSwitch.v)return!1;for(var n in w){if(n=="masterFXSwitch")continue;
if(n=="Scl")continue;if(n=="classID")continue;var W=w[n].v;for(var L=0;L<W.length;L++)if(W[L].v.enab.v)return!0}return!1};
h.prototype.$k=function(w,n,W,D){var j=new iB,I=this.V6(w,W,D);if(I.indexOf(0)!=-1)j=j.x0(this.rect);
if(I.indexOf(1)!=-1){var U=this._N(),M=U.pJ();j=W&&U.y_()==0?j.VY()?M:j.wU(M):j.x0(M)}if(I.indexOf(2)!=-1){var m=this.add.vmsk,l=this.add.vstk,A;
if(n){A=E.P.b3(m.i,m.g.length!=0?m.g:null)}else A=E.P.b3(m.i);if(!D&&l&&l.strokeEnabled.v){var g=l.strokeStyleLineAlignment.v.strokeStyleLineAlignment,k=l.strokeStyleLineJoinType.v.strokeStyleLineJoinType;
if(g!="strokeStyleAlignInside"){var $=l.strokeStyleLineWidth.v.val;if(k=="strokeStyleMiterJoin")A=new iB(0,0,w.m,w.n);
else A.VD($,$)}}j=j.x0(A)}if(I.indexOf(3)!=-1)j=j.x0(this.NP(w).z.pJ());if(I.length==0&&this.I9())j=D?new iB(0,0,0,0):new iB(0,0,w.m,w.n);
return j};h.prototype.L9=function(){var w=this.add.artb,n=w.artboardBackgroundType.v,W=0;if(n==1)W=4294967295;
else if(n==2)W=4278190080;else if(n==3)W=0;else if(n==4){W=w.Clr.v;W=255<<24|W.Bl.v<<16|W.Grn.v<<8|W.Rd.v}else throw n;
return W};h.prototype.yP=function(){var w=this.add.artb.artboardRect.v,n=w.Btom.v,W=w.Left.v,D=w.Rght.v,top=w.Top.v;
return new iB(W,top,D-W,n-top)};h.prototype.MR=function(w){var n=h.B3(w);if(this.add.artb==null)this.add.artb={classID:"artboard",artboardRect:{t:"Objc",v:null},artboardBackgroundType:{t:"long",v:1}};
this.add.artb.artboardRect.v=n};h.B3=function(w){var n={classID:"classFloatRect",Top:{t:"doub",v:0},Left:{t:"doub",v:0},Btom:{t:"doub",v:0},Rght:{t:"doub",v:0}};
n.Btom.v=w.y+w.n;n.Left.v=w.x;n.Rght.v=w.x+w.m;n.Top.v=w.y;return n};h.prototype.V6=function(w,n,W){var D=[],j=this;
if(!n&&j.na&&W){D.push(2)}else if(j.eL<=0||n){if(j.oK())if(!this.rect.VY())D.push(0);if(j._N()&&!j._N().rect.VY())if(j._N().gm||n)D.push(1);
if(j.add.vmsk)if(j.add.vmsk.gm||n)D.push(2);if(j.YC()&&j.NP(w).z&&!j.NP(w).z.rect.VY())D.push(3)}else if(j.eL==1){D.push(1);
if(j._N().gm&&!j._N().rect.VY()){if(j.oK())if(!this.rect.VY())D.push(0);if(j.add.vmsk)if(j.add.vmsk.gm)D.push(2)}}else if(j.eL==3&&!j.NP(w).z.rect.VY())D.push(3);
if(j.add.artb&&D.indexOf(0)==-1)D.push(0);D.sort();return D};h.prototype._N=function(){var w=this;return w.pv?w.pv:w.add.vmsk&&w.add.vmsk.isEnabled?null:w.z};
h.prototype.NP=function(w){var n=this.add.SoLd.placed.v,W=w.add.FEid;if(W==null)return null;for(var L=0;
L<W.length;L++)if(W[L].id==n)return W[L];return null};h.prototype.extend=function(w){E.anw(this,w)};
h.prototype.ah$=function(w,n,W){var D=w.clone();if(this.Jp()){var j=this.add.lmfx,I=n.root.fs(n.C.indexOf(this)),U=j.gradientFillMulti.v,M=!1;
for(var L=0;L<U.length;L++)if(U[L].v.enab.v&&U[L].v.Algn.v)M=!0;if(M)D=D.x0(I.pJ(n,!1));var m=ge.a3w(this.add.lmfx,n,W);
D.offset(m.x,m.y);D.m+=m.m;D.n+=m.n}return D};h.prototype.ky=function(){if(this.oK())E.qS(this);var w=this._N();
if(w)w.ky()};h.prototype.clone=function(){var w=new h;w.rect=this.rect.clone();w.buffer=this.buffer.slice(0);
w.Bx=this.Bx;w.opacity=this.opacity;w.QY=this.QY;w.FK=this.FK;w.name=this.name;w.kQ=this.kQ.slice(0);
if(this.z)w.z=this.z.clone();if(this.pv)w.pv=this.pv.clone();for(var n in this.add)w.add[n]=dR.clone(n,this.add[n]);
return w};h.prototype.i0=function(w){var n=this;if(n.add.TySh)delete n.add.TySh;if(n.add.SoLd){var W=this.Nu(w,this.buffer,this.rect);
if(W){this.buffer=W.Q0;this.rect=W.rect;this.l()}delete n.add.SoLd}if(n.add.SoCo||n.add.GdFl||n.add.PtFl){if(n.add.vogk)delete n.add.vogk;
if(n.add.SoCo)delete n.add.SoCo;if(n.add.GdFl)delete n.add.GdFl;if(n.add.PtFl)delete n.add.PtFl;if(n.add.vmsk){console.log(n.pv,n.z);
delete n.add.vmsk;if(n.pv==null&&n.z)delete n.z;else if(n.pv!=null&&n.z!=null){n.z=n.pv;delete n.pv}}}if(!n.ue()&&eH.get(n.add)==null&&!this.oK())this.FK-=16};
h.prototype.c3=function(w){var n=255,W=0;if(w==2){var D=this.add.SoLd.filterFX.v;if(D.filterMaskDensity)n=D.filterMaskDensity.v;
if(D.filterMaskFeather)W=D.filterMaskFeather.v}else{var j=w==0?this._N():this.add.vmsk;n=j.MX;W=j.C3}return{le:w,ij:n,dK:W}};
h.prototype.avi=function(w){if(w.le==2){var n=this.add.SoLd.filterFX.v;if(w.ij==255)delete n.filterMaskDensity;
else n.filterMaskDensity={t:"long",v:w.ij};if(w.dK==0)delete n.filterMaskFeather;else n.filterMaskFeather={t:"doub",v:w.dK};
this.l()}else{var W=w.le==0?this._N():this.add.vmsk;W.MX=w.ij;W.C3=w.dK;W.eP=!0}};h.prototype.hu=function(){var w=this,n=w.add.vmsk;
if(n==null)return;w.add.vogk=E.X.amM(n.i)};h.hu=function(w){var n=[],W=E.P.bB(w);for(var D=0;D<W;D++)n.push(E.X.LR());
return n};var ef={Zd:0,fz:1,Se:2,Cq:3};h.ac=function(){this.name="Mask";this.$P=!1;this.pL={o:255,B:0,k:0};
this.Zg=50;this.Y3=0;this.color=255;this.gm=!0;this.isEnabled=!0;this.CT=!1;this.MX=255;this.C3=0;this.rect=new iB;
this.channel=E.Q(0);this.zQ=null;this.aqQ=null;this.eP=!0};h.ac.prototype.y9=function(w){if(!this.isEnabled)return w;
var n=new h.ac;n.color=Math.round(this.y_()*w.y_()/255);if(this.y_()==0&&w.y_()==0)n.rect=this.pJ().wU(w.pJ());
else if(w.y_()==0)n.rect=w.pJ().clone();else if(this.y_()==0)n.rect=this.pJ().clone();else n.rect=this.pJ().x0(w.pJ());
n.channel=this.Ln(n.rect);n.MX=255;n.C3=0;var W=w.Ln(n.rect);E.aqV(W,n.rect,n.channel,n.rect);return n};
h.ac.prototype.pJ=function(){if(this.C3==0)return this.rect;var w=Math.ceil(this.C3*2.2),n=this.rect.clone();
if(n.y==0){if(n.x==0)n.m+=w;else n.VD(w,0);n.n+=w}else n.VD(w,w);return n};h.ac.prototype.Ob=function(){if(this.C3==0&&this.MX==255)return this.channel;
if(this.C3==0){var w=this.channel.slice(0);E.Ba(w);E.D9(w,this.MX/255);E.Ba(w);return w}var n=this.pJ(),W=this.Tt(n),w=E.Q(n.O());
E.xX.So(W,w,n,this.C3);if(this.MX!=255){E.Ba(w);E.D9(w,this.MX/255);E.Ba(w)}return w};h.ac.prototype.y_=function(){return Math.round(255-(255-this.color)*(this.MX/255))};
h.ac.prototype.extend=function(w){E.extend(this,w,this.color)};h.ac.prototype.ky=function(){if(this.color==255)E.Ba(this.channel);
E.ky(this);if(this.color==255)E.Ba(this.channel)};h.ac.prototype.clone=function(){var w=new h.ac;w.name=this.name;
w.$P=this.$P;w.pL=this.pL;w.Zg=this.Zg;w.Y3=this.Y3;w.color=this.color;w.gm=this.gm;w.isEnabled=this.isEnabled;
w.CT=this.CT;w.MX=this.MX;w.C3=this.C3;w.rect=this.rect.clone();w.channel=this.channel.slice(0);return w};
h.ac.prototype.Tt=function(w,n){if(n==null)n=E.Q(w.O());n.fill(this.color);E.B0(this.channel,this.rect,n,w);
return n};h.ac.prototype.Ln=function(w,n){var W=this.pJ(),D=this.Ob();if(n==null)n=E.Q(w.O());n.fill(this.y_());
E.B0(D,W,n,w);return n};h.Rd=function(){this.gm=!0;this.isEnabled=!0;this.MX=255;this.C3=0;this.i=[{type:6},{type:8,all:0}];
this.H3=[-3,-3];this.Ty=!1;this.pv=null;this.eP=!0;this.g=[];this.Rw=[]};h.Rd.prototype.offset=function(w,n){this.pv=this._N();
E.P.c0(this.i,new eh(1,0,0,1,w,n));this.pv.rect.offset(w,n)};h.Rd.prototype._N=function(w){if(!this.eP&&this.pv&&w==null){this.pv.isEnabled=this.isEnabled;
return this.pv}var n=E.P.b3(this.i),W="strokeStyleLineAlignment",D="strokeStyleLineJoinType";if(n.O()>2e4*2e4)n=new iB(0,0,100,100);
if(w&&w[W].v[W]!="strokeStyleAlignInside"){var j=1;if(w[D].v[D]=="strokeStyleMiterJoin"){var I=E.P.aiR(this.i),U=I/2,M=Math.sin(U),m=Math.cos(U);
m/=M;M=1;var j=Math.sqrt(m*m+M*M);if(isNaN(j)||j<1)j=1}j*=w[W].v[W]=="strokeStyleAlignOutside"?1:.5;
var l=Math.ceil(w.strokeStyleLineWidth.v.val*j);l=Math.min(l,600);n.VD(l,l)}n=E.p.fF(n);var A=new h.ac;
A.color=E.P.dX(this.i)?0:255;A.gm=this.gm;A.isEnabled=this.isEnabled;A.CT=!0;A.rect=n;A.MX=this.MX;A.C3=this.C3;
A.channel=E.Q(A.rect.O());if(!n.VY())E.P.a2k(this.i,A.channel,A.rect,w);if(w==null){this.pv=A;this.eP=!1}return A};
h.Rd.prototype.clone=function(){var w=new h.Rd;w.gm=this.gm;w.isEnabled=this.isEnabled;w.MX=this.MX;
w.C3=this.C3;w.i=h.Rd.Tv(this.i);w.H3=this.H3.slice(0);w.Ty=this.Ty;w.g=this.g.slice(0);w.Rw=this.Rw.slice(0);
return w};h.Rd.prototype.concat=function(w){var n=w.i.slice(2);if(n.length==0)return;n[0].Ht=3;this.i=this.i.concat(n)};
h.Rd.Tv=function(w){var n=[];for(var L=0;L<w.length;L++){var W=w[L];if(W.type>5||W.type==0||W.type==3)n.push(JSON.parse(JSON.stringify(W)));
else n.push({type:W.type,T7:W.T7.clone(),H:W.H.clone(),mO:W.mO.clone()})}return n};h.Rd.an3=function(w,n,W){if(w.length!=n.length)return!1;
for(var L=2;L<w.length;L++){var D=w[L],j=n[L];if(D.type!=j.type)return!1;if(D.type==0||D.type==3){if(D.length!=j.length||!W&&D.Ht!=j.Ht)return!1}else if(!D.T7.s9(j.T7)||!D.H.s9(j.H)||!D.mO.s9(j.mO))return!1}return!0};
h.Rd.prototype.aaA=function(){var w=this.i;for(var L=3;L<w.length;L++)if(w[L].type==0||w[L].type==3)w[L].Ht=-1};
h.FL=function(){this.type=null;this.dk=2;this.Z4=null;this.O7="";this.oq="";this.TA="";this.open=0;this.raw=null;
this.PO=null;this.a4q="";this.XW=!1};h.FL.prototype.clone=function(){var w=new h.FL;w.type=this.type;
w.dk=this.dk;w.Z4=this.Z4;w.O7=this.O7;w.oq=this.oq;w.TA=this.TA;w.open=this.open;w.raw=new Uint8Array(this.raw.buffer.slice(0));
return w};h.FL.prototype.Vc=function(w,n,W,D,j){if(W==null)W="none";var I=this,U=jj.zJ(I.raw.buffer),M=U=="svg"||U=="pdf"||U=="ai";
if(I.PO){var m=n&&M&&Math.max(I.PO[1].m,I.PO[1].n)<Math.max(n[0],n[1]);if(!m&&W==this.a4q&&!I.XW)return}this.a4q=W;
if(!M)w=0;if(U==null){alert("Unsupported format: "+J.sv(I.raw,0,4));return null}var l=jj.ZO(U);if(l.Xq){var A=new kc(name+(U=="psd"?"":"-"+U)+".psd"),g;
l.Vu(I.raw.buffer,A,n);var k=new iB(0,0,A.m,A.n);if("avrg maxx medn minn rang stdv summ vari".split(" ").indexOf(W)!=-1){var $=[];
for(var L=0;L<A.C.length;L++){var C=A.C[L],f=C.buffer;if(!C.rect.s9(k)){f=E.Q(k.O()*4);E.Cb(C.buffer,C.rect,f,k);
console.log("resizing")}$.push(f)}g=E.Q(k.O()*4);E.stack.stack($,g,W)}else{for(var L=0;L<A.C.length;
L++)if(A.C[L].I9())A.C[L].yb(A);if(D&&A.XW){var z=aj.MF(A,D,j);I.XW=!z;if(z)aj.yf(A,D,j)}A.X0();A.l();
A.tw();g=A.Vc()}I.PO=[g,k];I.hh=A.hh!=null&&A.hh!=0?A.hh:72}else if(l){var s=l.Vu(I.raw.buffer)[0];I.PO=[new Uint8Array(s.data),s.XL];
I.hh=s.hh!=null&&s.hh!=0?s.hh:72}if(I.PO){if(w==1){var f=I.PO[0],O=I.PO[1],a=E.Q(O.O());E.hN(f,a,3);
var X=E.Nb(a,O),P=E.Q(X.O()*4);E.Cb(f,O,P,X);X.x=X.y=0;I.PO=[P,X]}E.L3(I.PO)}};h.R6="0";h.du="2";h.qf="2.5";
h.K9="2.6";h.zi="3";h.v4="4";h.vZ="4.5";h.aqY="4.6";h.aly="5";h.v0="5.5";h.a1O="6";h.fi="7";h.atm="8";
h.g6="9";h.nH="9.3";h.aza="9.5";h.rC="9.6";h.Gw="10";h.Uo="11";h.cV="12";h.uV="13";h.kR="13.1";h.a5T="13.2";
h.Q_="13.3";h.Xw="13.4";h.PE="14";h.qc="14.1";h.AP="14.2";h.lB="14.3";h._9="17";h._x="18";h.amd="19";
h.Di="19.5";h.QE="19.6";h.nL="19.7";h.ws="19.8";h.jC="20";h.JM="21";h.ge="21.5";h.p6="22";h.Wm="22.5";
h.Ll="23";h.a8i="24";h.Gz="25";h.a2z="26";h.ax7="27";h.Aj="28";h.oO="29";h.jF="30";h.Yt="31";h.tp="32";
h.Si="33";h.yH="34";h.nS="35";h.nP="36";h.eI="36.5";h.Vp="37";h.iv="37.5";h.abI="37.6";h.Bl="38";h.w2="38.5";
h.NU="38.6";h.ZM="39";h.HT="40";h.atX="41";h.jh="42";h.lf="50";h.GG="51";h.lc="52";h.Wu="53";h.fE="54";
h.aox="54.5";h.jX="54.6";h.aml="54.7";h.U7="54.8";h.Q2="55";h.YS="56";h.Nk="57";h.cP="58";h.vE="59";
h.x9="60";function jo(){this.depth=0;this.index=-1;this.j=null;this.ap3=null;this.r$=-1;this.children=null;
this.parent=null;this.lp=null}jo.prototype.ajG=function(w,n){if(this.depth!=0)w.push(this.j.getName());
if(this.children)for(var L=0;L<this.children.length;L++)this.children[L].ajG(w,n);if(w.length>n.jB.length)n.jB=w.slice(0);
if(this.depth!=0)w.pop()};jo.prototype.ava=function(){var w=0;if(this.j.ue()){for(var L=0;L<this.children.length;
L++)w+=this.children[L].ava()}else if(this.j.buffer)w+=this.j.buffer.length;return w};jo.prototype.fs=function(w){var n=this.lp[w];
return this.lp[w]};jo.prototype.aq$=function(w,n){var W=this.j;if(!W.I4()||W.m7(2)||W.m7(31))return null;
if(W.f6()){var D=W.z.rect.L0(w);if(!D&&W.z.color==0)return}if(W.ue()){for(var L=0;L<this.children.length;
L++){var bK=this.children[L];bK.aq$(w,n)}}else if(W.rect.L0(w))n.push(this.index)};jo.prototype.pw=function(w,n){var W=this.j;
if(!W.I4()||W.m7(2)||W.m7(31))return null;if(W.f6()){if(W.z.rect.y5(w)){if(!E.pw(w,W.z.channel,W.z.rect))return null}else if(W.z.color==0)return null}if(W.ue()){if(W.add.artb&&!W.yP().y5(w))return null;
for(var L=this.children.length-1;L>=0;L--){var bK=this.children[L],D=bK.pw(w,n);if(D&&n==null)return D}return null}else if(W.add.TySh&&W.rect.y5(w)||E.amV(w,W.buffer,W.rect)){if(n==null)return this;
else n.push(this.index)}return null};jo.prototype.aAe=function(w){var n=this.j;if(!n.I4()||n.m7(2)||n.m7(31))return null;
var W=n.add.vmsk;if(W&&W.isEnabled){var D=E.P.pw(W.i,w).p_;if(D!=-1)return{a86:this,azZ:D}}if(n.ue()){if(n.add.artb&&!n.yP().y5(w))return null;
for(var L=this.children.length-1;L>=0;L--){var bK=this.children[L],j=bK.aAe(w);if(j)return j}return null}return null};
jo.prototype.lS=function(w,n){w.push(this.index);if(this.j.ue()){w.push(this.r$);if(n)if(this.j.eL==1&&this.j._N().gm==!1)return;
for(var L=0;L<this.children.length;L++)this.children[L].lS(w)}};jo.Gk=function(){var w=document.createElement("canvas");
return w.getContext("2d")};jo.a7e=function(w,n){var W,D;if(w.m>w.n){W=n;D=Math.floor(n*(w.n/w.m))}else{W=Math.floor(n*(w.m/w.n));
D=n}return new ec(W,D)};jo.k_=32;jo.kZ=1;jo.prototype.sX=function(w,n,W){var D=jo.kZ,j=this.j;if(j.ue()&&j.add.artb!=null)n=j.yP();
var I=D==0?j.rect:n;if(I.VY()||j.add.TySh)I=n;var U=jo.k_*y.V(),M=jo.a7e(I,U),m=M.x,l=M.y,A=jo.a7e(n,U);
if(j.I9()&&j.add.vmsk==null||j.add.TySh)m=l=Math.max(l,16);else if(j.ue()){m=l=16}else{m=Math.max(m,6);
l=Math.max(l,6)}if(W&&j.ji==null){j.ji=jo.Gk();j.pO=jo.Gk();j.bA=jo.Gk();j.RX=jo.Gk()}var g=j.I9()&&j.add.vmsk;
if(g){if(W&&j.add.vstk)E.qg.mi(j.ji,m,l,I,j.buffer,j.rect,!1,null,!j.add.vstk.fillEnabled.v&&!j.add.vstk.strokeEnabled.v);
if(W)E.qg.azI(j.ji,m,l)}else if(j.add.TySh){if(W)E.qg.a2W(j.ji,l,l,j.add.TySh)}else if(j.add.SoCo){if(W)E.qg.azH(j.ji,l,l,j.add.SoCo)}else if(j.add.GdFl){if(W)E.qg.af8(j.ji,l,l,j.add.GdFl)}else if(j.add.PtFl){if(W)E.qg.a7x(j.ji,l,l,j.add.PtFl,w)}else if(eH.get(j.add)!=null){if(W)E.qg.az0(j.ji,l,l,j.add)}else if(j.add.SoLd){if(W)E.qg.mi(j.ji,m,l,I,j.buffer,j.rect,!1);
if(W)E.qg.aak(j.ji,m,l,j.add.SoLd)}else if(j.ue()){}else{if(W){if(j.oK())E.qg.mi(j.ji,m,l,I,j.buffer,j.rect,!1);
else{E.qg.a6w(j.ji,l,l)}}}var k=j._N();if(W){if(k)E.qg.ow(j.pO,A.x,A.y,n,k);if(j.YC()&&j.NP(w)&&j.NP(w).z){var $=j.NP(w).z;
E.qg.ow(j.RX,A.x,A.y,n,$)}if(!g&&j.add.vmsk){E.qg.ow(j.bA,A.x,A.y,n,j.add.vmsk._N(),!0)}}if(k||j.add.vmsk)l=Math.max(l,A.y);
j.a2j=Math.max(l,16);if(W!=!0&&j.ue()&&(j.add.lsct==ef.fz||w.C.length<4e3))for(var L=0;L<this.children.length;
L++)this.children[L].sX(w,n)};jo.prototype.arN=function(w,n,W,D){this.depth=W;var j=w[n];if(D==null)D=[];
this.lp=D;if(j.add.lsct==ef.Cq){this.ap3=j;this.r$=n-1;this.children=[];var L=n+1;while(!0){var I=w[L];
if(I==null)console.log(L,w.length);if(I.add.lsct==ef.fz||I.add.lsct==ef.Se){if(j.add.lyid==I.add.lyid)j.add.lyid+=16777215;
this.j=I;this.index=L-1;D[this.index]=this;D[n-1]=this;break}var U=new jo;U.parent=this;L=U.arN(w,L,W+1,D);
this.children.push(U)}return L+1}else{this.j=j;this.index=n-1;D[this.index]=this;return n+1}};jo.prototype.a7=function(w,n,W,D){var j=this.fs(W),I=w;
while(j.parent!=null){I=j.j.ah$(I,n,D);j=j.parent}return I};jo.prototype.pJ=function(w,n){var W=this.j,D=new iB;
if(!W.I4())return D;var j=W._N();if(W.ue())for(var L=0;L<this.children.length;L++){var I=this.children[L].pJ(w,!0);
D=D.x0(I)}else if(eH.get(W.add)!=null)D=W.f6()&&W.z.color==0?W.z.pJ().clone():new iB(0,0,w.m,w.n);else if(W.I9()&&W.add.vmsk&&W.add.vmsk.isEnabled&&W.add.vstk){D=W.rect.clone()}else if(W.I9()&&j&&j.isEnabled&&j.y_()!=0)D=new iB(0,0,w.m,w.n);
else{D=W.$k(w,!1,!0);if(W.add.vmsk)D=E.p.fF(D)}return n?W.ah$(D,w):D};jo.Eg={delete:function(w){if(w&&w.m)w.delete()},Q:function(w,n){return je.YG?new je.H0(w,n):E.Q(w*n*4)},yM:function(w,n,W){if(je.YG){if(w==null||w.m!=n||w.n!=W){jo.Eg.delete(w);
return new je.H0(n,W)}}else{if(w==null||!(w instanceof Uint8Array)||w.length!=n*W*4){jo.Eg.delete(w);
return E.Q(n*W*4)}}return w},B0:function(w,n,W,D,j){(je.YG?je.Jx:E.Cb)(w,n,W,D,j)},eY:function(w,n,W,D,j,I,U,M,L,m,l){(je.YG?je.s.mT:E.s.eY)(w,n,W,D,j,I,U,M,L,m,l)},a9J:function(w,n,W,D,j,I,U,M){var m=W.clone(),l=j.m,A=j.n,g=m.x,k=m.y,$=m.x+m.m>l?-1:0,C=m.x<0?2:1,f=m.y+m.n>A?-1:0,z=m.y<0?2:1;
for(var s=f;s<z;s++)for(var O=$;O<C;O++){m.x=g+O*l;m.y=k+s*A;jo.Eg._U(w,n,m,D,j,I,U,M)}},_U:function(w,n,W,D,j,I,U,M){if(je.YG)je.s.Q7(w,n,W,D,j,I,U,M);
else E.s._U(w,n,W,D,j,I,U,M)},cJ:function(w,n,W){if(je.YG){je.t5(w);je.oT(n,W)}else E.cJ(w,n,W)},ayr:function(w,n,W,D,j){if(je.YG){je.s.mT(null,null,D,j,w,n,W,j,1,!1)}else{if(W==255)E.AG(w,n,D,j);
else{var I=E.Q(n.O());E.KB(D,j,I,n);E.w5(w,I);E.cJ(D,0,16777215);E.MN(I,n,D,j)}}},Yj:function(w,n,W,D){if(je.YG)je.s.mT(null,null,W,D,w,n,0,D,1,!1);
else E.Yj(w,n,W,D)}};jo.prototype.MP=function(w,n,W,D,j,I){var U=typeof I=="number";if(!this.j.ue()&&(U&&this.index>I||!U&&I.indexOf(this.index)==-1)){return}var M=this.j,m=ge.qB(M),l=jo.Eg,A=M.I9()?M._N():M.z;
if(!M.I4())return;if(M.f6()&&A.rect.VY()&&A.y_()==0){return}if(M.add.vstk==null&&this.pJ(D,!1).VY()){return}var g=this.pJ(D,!0).wU(W);
if(!n.s9(W)&&!W.L0(g))return;if(M.ue()&&M.add.artb){var k=M.yP();W=W.wU(k)}var $=jo.a8T(M,j,m);if(!$){this.ag3(w,n,W,D,j,I);
return}M.US.kh=l.yM(M.US.kh,g.m,g.n);l.B0(w,n,M.US.kh,g,W);this.ag3(M.US.kh,g,W,D,j,I);l.eY(M.US.kh,g,w,n,null,null,0,W,M.opacity/255,M.Bx=="diss",m.e6)};
jo.a8T=function(w,n,W){if(W.e6[0]*W.e6[1]*W.e6[2]==0)return!0;return w.opacity!=255&&(n.length!=0||w.ue()||w.Jp())};
jo.a0y={US:{}};jo.prototype.ag3=function(w,n,W,D,j,I){var U=this.j,M=ge.qB(U),m=eH.get(U.add)!=null,l=jo.Eg,A=jo.a8T(U,j,M),g=A?1:U.opacity/255,k=U.I9()?U._N():U.z,$=U.ue()&&M.vn==null&&(U.Bx=="pass"||U.add.artb)&&!(j.length>0||M.fill!=1||U.Jp()),C=!U.ue()&&!m&&!U.Jp()&&j.length==0,f=m&&!U.Jp()&&j.length==0,P=null,Z=null,Y=null,T;
if($||C||f){var z=w,s=n;if(U.f6()){s=this.pJ(D,!1);z=U.US.AT=l.yM(U.US.AT,s.m,s.n);l.B0(w,n,U.US.AT,s)}if($)this.d0(z,s,W,D,I);
if(C)l._U(U.Bx,U.awG(D),U.rect,z,s,W,g,M);if(f){var O=U.f6()&&k.y_()==0?k.pJ().clone():s.clone(),a=U.US;
if(O.s9(new iB(0,0,D.m,D.n)))a=jo.a0y;a.EG=this.a65(z,s,a.EG,O,U.add);M.MY=!0;l._U(U.Bx,a.EG,O,z,s,W,g,M)}if(U.f6())l.eY(z,s,w,n,U.amU(),k.pJ(),k.y_(),W,1,U.Bx=="diss");
U.US.aje();return}var X=U.ue()&&U.Bx=="pass"&&(j.length>0||M.fill!=1||U.Jp()),O=U.rect;if(U.ue()){O=this.pJ(D,!1);
Y=U.US.EG=l.yM(U.US.EG,O.m,O.n);l.cJ(Y,0);this.d0(Y,O,O,D,I);Z=l.yM(U.US.kB,O.m,O.n);l.B0(Y,O,Z,O)}else if(m){O=U.f6()&&k.y_()==0?k.pJ().clone():n.clone();
Z=l.yM(U.US.kB,O.m,O.n);l.cJ(Z,4294967295)}else{O=U.rect;P=U.awG(D);Z=l.yM(U.US.kB,O.m,O.n);l.B0(P,O,Z,O)}U.US.kB=Z;
if(U.f6())l.ayr(U.amU(),k.pJ(),k.y_(),Z,O);if(U.Jp())if(U.US.zm||U.US.Wq||U.US.sI!=je.YG||U.US.jA||U.ue()){var K=U.add.vmsk,S=E.Q(O.O());
if(ge.arR(U.add.lmfx)){if(je.YG){if(!U.ue()&&U._N()==null&&U.rect.s9(O)&&K==null)E.hN(U.buffer,S,3);
else{var G=E.Q(O.O()*4);Z.get(G);E.hN(G,S,3)}}else E.hN(Z,S,3)}if(U.US.Wq||U.US.sI!=je.YG||!E.s9(S,U.US.gY)){var V=null;
if(U.I9()&&K&&K.isEnabled&&K._N().color==0)V=K._N().rect;ge.a9o(U.US.IH);U.US.IH=ge.a1k(S,O,U.add.lmfx,U.add.fxrp,D,V);
U.US.gY=S;U.US.axv=O}}if(U.Jp())ge.a3o(U.add.lmfx,U.US.IH,O,w,n,W);if(U.ue()){P=l.yM(U.US.AT,O.m,O.n);
l.cJ(P,0);if(U.Bx=="pass")l.B0(w,n,P,O);if(X)l.Yj(Y,O,P,O);this.d0(P,O,W,D,I);U.US.AT=P}if(m){P=U.US.AT=this.a65(w,n,U.US.AT,O,U.add)}if(U.ue()||m)T=P;
else{T=l.yM(U.US.AT,O.m,O.n);l.B0(P,O,T,O,W);U.US.AT=T}l.cJ(T,4278190080,16777215);for(var L=0;L<j.length;
L++)j[L].MP(T,O,W,D,[],I);var R=U.US.hX=l.yM(U.US.hX,O.m,O.n);l.B0(w,n,R,O,W);if(m)M.MY=!0;l._U(U.Bx=="pass"?"norm":U.Bx,T,O,R,O,W,1,M);
if(U.Jp()){var x=U.US.IH.type.FrFX,v=null;if(x.length!=0){v=x[0];for(var L=0;L<x.length;L++)if(x[L].TM.m>v.TM.m)v=x[L];
U.US.j1=l.yM(U.US.j1,v.TM.m,v.TM.n);l.B0(w,n,U.US.j1,v.TM,W);U.US.cL=l.yM(U.US.cL,v.TM.m,v.TM.n)}ge.axB(U.add.lmfx,U.US.IH,O,w,n,W,R,U.US.j1,U.US.cL,v?v.TM:null)}if(!je.YG){var N=E.Q(O.O());
E.hN(Z,N,3);Z=N}l.eY(R,O,w,n,Z,O,0,W,1,U.Bx=="diss");U.US.aje()};jo.prototype.awr=function(w,n,W,D){var j=this.j,I=j.add.lmfx,U=j.add.TySh,M=j.add.SoLd,C=!1,z=null;
if(!j.I4())return;if(!j.rect.VY()&&!j.rect.L0(D))return;n.save();if(j.add.artb){var m=j.yP();n.beginPath();
n.rect(m.x,m.y,m.m,m.n);n.clip();D=D.wU(m);var l=j.L9();if(l!=0){var m=l>>>16&255,A=l>>>8&255,g=l&255;
n.fillStyle="#"+E.$$(g<<16|A<<8|m);n.fillRect(D.x,D.y,D.m,D.n)}}var k=j.opacity/255*(j.add.iOpa?j.add.iOpa/255:1);
n.globalAlpha*=k;n.globalCompositeOperation=dD.R3[dD.mS.indexOf(j.Bx)];var $=[];CSS.a6S(w,I,$);for(var L=0;
L<$.length;L++){var f=$[L];if(f.startsWith("filter: drop-shadow")){f=f.slice(20,-1).split(" ");n.shadowOffsetX=parseFloat(f[0])*w.u.N;
n.shadowOffsetY=parseFloat(f[1])*w.u.N;n.shadowBlur=parseFloat(f[2])*w.u.N*2.4;n.shadowColor=f[3];C=!0}}var s=ge.anc(j,C);
if(s){z=n;var O=document.createElement("canvas");O.width=n.canvas.width;O.height=n.canvas.height;var a=n.getTransform();
n=O.getContext("2d");n.setTransform(a.a,a.b,a.c,a.d,a.e,a.f)}function X(r,p){var P=r.US.gj;if(P==null)P=r.US.gj=E.p.tq(r.add.vmsk.i,p);
return P}if(j.add.vmsk&&!j.I9()){var P=X(j,!1),Z=P.VN;n.beginPath();Typr.U.pathToContext({cmds:Z.F,crds:Z.w},n);
n.clip()}function Y(r,p){return CSS.Dg({o:r[0]*255,B:r[1]*255,k:r[2]*255},p)}function K(v,r,p,Q){if(v.Ptrn){var B=ge.GP(v,null,new iB(0,0,1,1),r,p);
Q.save();Q.translate(B[2],B[3]);Q.scale(B[1],B[1]);Q.rotate(-B[4]);return B}var i=jv.DO(v,new eh,j.rect);
if(i.length==3)return[Y(i),1];else{var c,h2=i.crds,jX=i.grad;if(i.typ=="lin")c=n.createLinearGradient(h2[0],h2[1],h2[2],h2[3]);
else c=n.createRadialGradient(h2[0],h2[1],h2[2],h2[3],h2[4],h2[5]);for(var L=0;L<jX.length;L++)c.addColorStop(jX[L][0],Y(jX[L][1],jX[L][2]));
return[c,1]}}if(j.ue()){for(var L=0;L<this.children.length;L++)this.children[L].awr(w,n,W,D)}else if(U){var S=!0;
if(j.US.path==null){S=aj.bN(U,W.hY);if(S)aj.a5(j,W.hY,!1)}if(S){if(w.u.N<1)jo.amh(w,j,n,new eh(1,0,0,1,j.rect.x,j.rect.y),j.US.HY);
else if(j.US.path){n.save();n.translate(j.rect.x-j.US.__.x,j.rect.y-j.US.__.y);aj.a6o(j.US.path,n);n.restore()}}}else if(j.I9()&&j.add.vmsk){var G=j.add.vmsk,V=j.add.vstk,I=j.add.lmfx,T=V.fillEnabled.v;
if(!V.strokeEnabled.v)V=ge.Qk(I);var R=V?at.QO.n2.indexOf(V.strokeStyleLineAlignment.v.strokeStyleLineAlignment):-1,P=X(j,R!=-1),Z=P.VN;
if(G.C3!=0)n.filter="blur("+G.C3*w.u.N+"px)";n.beginPath();Typr.U.pathToContext({cmds:Z.F,crds:Z.w},n);
var x=R==2?[1,0]:[0,1];for(var L=0;L<2;L++){if(x[L]==0&&T){var v=ge.mw(I,j.add),N=v[0],u=v[1];v=j.add.PtFl;
v=v?v:N?N:u;v=K(v,w.add.Patt,j.add.fxrp,n);n.fillStyle=v[0];n.fill(["nonzero","evenodd"][j.US.gj.M0]);
if(v.length>2)n.restore();if(R==0)n.clip()}if(x[L]==1&&V){var H=K(V.strokeStyleContent.v,w.add.Patt,j.add.fxrp,n);
n.strokeStyle=H[0];E.P.ZC(V,n,1/H[1]);n.stroke();if(H.length>2)n.restore()}}}else if(!j.rect.VY()){var F=null,t=null;
if(M){var o=M.filterFX;if(o){var v=o.v.filterFXList.v;for(var L=0;L<v.length;L++){var f=v[L].v;if(!f.enab.v)continue;
var q=cx.iF(f);if(q=="GsnB"){n.filter="blur("+f.Fltr.v.Rds.v.val*w.u.N+"px)"}}}var _=M.Idnt.v,d=w.Zy(_,M.Crop?M.Crop.v:null);
F=E.K.ce(M);t=d.PO}jo.amh(w,j,n,F,t)}if(s){z.save();z.setTransform(1,0,0,1,0,0);z.drawImage(n.canvas,0,0);
z.restore();n=z}n.globalAlpha/=k;n.globalCompositeOperation="source-over";n.restore()};jo.amh=function(w,n,W,D,j){if(D==null)D=new eh;
var I=n.buffer,U=n.rect;if(j){var M=D.NW()*w.u.N,m=0;while(1<<m/2<.5/M&&m+2<j.length)m+=2;I=j[m];U=j[m+1];
U=U.clone();U.x=U.y=0;var M=1<<m/2,l=new eh;l.scale(M,M);l.concat(D);D=l}if(U.VY())return;var A=document.createElement("canvas");
A.width=U.m;A.height=U.n;var g=A.getContext("2d");g.putImageData(new ImageData(new Uint8ClampedArray(I.buffer),U.m,U.n),0,0);
W.transform(D.dl,D.k,D.Cj,D.j7,D.z2,D.EU);W.drawImage(A,U.x,U.y);D.Ba();W.transform(D.dl,D.k,D.Cj,D.j7,D.z2,D.EU)};
jo.prototype.a65=function(w,n,W,D,j){var I=eH.get(j),U;if(I)U=eH.rw(I,j[I]);var M=jo.Eg;W=M.yM(W,D.m,D.n);
if(!(je.YG&&n.s9(D)))M.B0(w,n,W,D);if(U){if(je.YG){var m=D.clone();m.x=m.y=0;if(n.s9(D)){je.t5(W,m);
eH.zj(U,w.LJ,m)}else{je.t5(W,D);W.Le(D);eH.zj(U,W.Ef,m)}}else eH.Ld(U,W,W,D)}return W};jo.prototype.d0=function(w,n,W,D,j){var I=n,U=I.m,M=I.n,m=I.x,l=I.y,bK=W,A=bK.x,g=bK.y,k=-1,$=-1,C=2,f=2;
if(!D.v_){k=$=0;C=f=1}var z=this.children;for(var L=0;L<z.length;L++){var s=[];for(var O=L+1;O<z.length;
O++)if(z[O].j.QY)s.push(z[O]);else break;for(var a=$;a<f;a++)for(var X=k;X<C;X++){I.x=m+X*U;I.y=l+a*M;
bK.x=A+X*U;bK.y=g+a*M;z[L].MP(w,I,bK,D,s,j)}L+=s.length}I.x=m;I.y=l;bK.x=A;bK.y=g};function kc(w){this.Mc="psd";
this.wW=!1;this.name=w;this.UM=-1;this.v_=!1;this.BX=null;this.ea=null;this.gN=null;this.Kh=null;this.m=0;
this.n=0;this.buffer=null;this.C=[];this.qL={};this.add={};this.UY=4;this.tD=null;this.hh=72;this.Zp={};
this.g=[];this.jg=[];this.PK=!1;this.ej=[];this.UF=[];this.Oi=[kc.bb("Work Path")];this.rs=[];this.zS=null;
this.kO={classID:"CompList",list:{t:"VlLs",v:[]}};this.ol=[];this.Ei=[];this.root=null;this.jw=null;
this.XW=!1;this.a1e=!1;this.a08=!1;this.P6=!1;this.Iq=!1;this.RP=!1;this.tL=!1;this.rR=!1;this.Uu=!1;
this.gL=!1;this.zm=null;this.FB=null;this.J=null;this.yo=[];this.v9=[];this.I={hF:{},cc:[],r4:[],hA:[],VZ:null,Im:null,t7:null,oP:null,TH:null,pb:[],r7:[],JF:null};
this.history=[new go([1,0],null)];this.QQ=0;this.Js=0;this.o2=0;this.u=new hs(this);this.To=null;this.Kq=null}kc.Ka=function(){var w=8,n=[0,0,0,.145,.051,.051,.263,.071,.067,.416,.051,.055,.573,.102,.11,.71,.122,.141,.851,.122,.149,.929,.122,.141,.075,.149,.078,.153,.153,.078,.275,.153,.055,.424,.157,.071,.569,.153,.114,.706,.165,.141,.855,.161,.153,.933,.196,.141,.118,.282,.133,.18,.29,.129,.286,.29,.122,.427,.294,.114,.573,.298,.129,.71,.294,.149,.855,.298,.153,.941,.306,.133,.035,.431,.224,.157,.427,.212,.294,.431,.204,.427,.435,.18,.569,.431,.165,.71,.435,.161,.851,.431,.153,.953,.435,.133,.012,.576,.278,.145,.569,.271,.29,.576,.259,.427,.576,.239,.569,.576,.212,.706,.573,.184,.855,.576,.157,.969,.569,.118,.114,.698,.294,.165,.702,.29,.29,.714,.286,.424,.714,.271,.573,.718,.243,.71,.714,.204,.855,.714,.153,.988,.714,.078,.314,.722,.282,.329,.722,.278,.392,.737,.275,.478,.757,.259,.584,.788,.239,.714,.827,.2,.859,.859,.125,.996,.855,0,.412,.741,.271,.427,.745,.267,.471,.753,.259,.533,.773,.251,.624,.8,.227,.725,.835,.2,.843,.875,.137,.973,.925,.075,.055,.059,.137,.141,.059,.141,.271,.059,.149,.424,.043,.149,.576,.098,.157,.714,.122,.153,.859,.122,.153,.929,.114,.176,.02,.145,.141,.137,.137,.137,.282,.141,.137,.431,.141,.145,.576,.145,.141,.714,.149,.145,.859,.141,.153,.933,.192,.184,.012,.286,.145,.145,.286,.141,.286,.286,.141,.431,.29,.141,.576,.286,.141,.714,.286,.149,.855,.286,.153,.941,.302,.176,.027,.427,.22,.153,.431,.216,.29,.427,.2,.427,.431,.18,.576,.431,.165,.714,.427,.161,.859,.431,.153,.949,.427,.165,.039,.576,.278,.153,.573,.271,.282,.573,.259,.431,.576,.239,.569,.573,.212,.71,.573,.184,.859,.576,.153,.969,.569,.165,.114,.698,.294,.165,.702,.29,.286,.718,.286,.424,.714,.267,.576,.722,.243,.714,.714,.204,.855,.714,.153,.988,.71,.137,.314,.722,.282,.341,.725,.278,.396,.737,.275,.486,.761,.259,.588,.788,.239,.714,.831,.2,.859,.855,.145,.996,.859,.129,.416,.741,.271,.439,.749,.271,.482,.757,.263,.537,.776,.251,.631,.804,.231,.725,.831,.196,.851,.878,.133,.969,.925,.18,.075,.075,.278,.145,.063,.29,.282,.067,.286,.424,.082,.294,.573,.102,.298,.714,.118,.298,.855,.11,.298,.933,.11,.306,.063,.141,.278,.137,.141,.286,.286,.137,.282,.427,.145,.286,.573,.141,.286,.714,.141,.29,.863,.149,.294,.937,.188,.302,0,.29,.29,.141,.286,.286,.29,.286,.286,.427,.29,.29,.573,.29,.29,.718,.29,.286,.859,.282,.286,.941,.302,.302,0,.427,.286,.145,.431,.29,.286,.427,.29,.424,.427,.286,.573,.427,.29,.718,.427,.286,.859,.427,.282,.953,.431,.302,0,.573,.282,.145,.576,.282,.286,.573,.282,.427,.573,.282,.576,.573,.282,.71,.569,.282,.859,.573,.278,.969,.569,.306,.114,.698,.294,.176,.702,.29,.286,.718,.286,.427,.718,.282,.576,.714,.278,.718,.722,.294,.855,.71,.278,.988,.71,.286,.329,.725,.282,.349,.729,.278,.4,.737,.278,.486,.761,.29,.592,.792,.298,.714,.835,.306,.859,.859,.278,1,.855,.286,.431,.745,.267,.451,.749,.267,.482,.757,.259,.549,.776,.247,.639,.804,.224,.733,.839,.224,.855,.882,.275,.973,.929,.306,.141,.133,.392,.165,.133,.408,.29,.141,.42,.416,.141,.424,.561,.133,.431,.71,.122,.439,.859,.082,.435,.929,.098,.431,.137,.184,.408,.176,.169,.424,.282,.157,.431,.424,.145,.424,.573,.141,.427,.714,.145,.427,.859,.137,.427,.929,.173,.427,0,.286,.427,.141,.29,.431,.29,.29,.431,.427,.29,.427,.576,.286,.427,.718,.29,.431,.859,.286,.427,.941,.298,.431,0,.427,.424,.145,.427,.427,.286,.427,.427,.427,.427,.427,.569,.427,.424,.718,.431,.431,.863,.427,.427,.949,.424,.431,0,.573,.427,.125,.573,.427,.282,.573,.427,.431,.576,.431,.569,.573,.427,.714,.573,.424,.851,.569,.424,.965,.569,.431,.082,.706,.427,.133,.71,.427,.282,.71,.424,.424,.714,.424,.576,.718,.427,.714,.714,.424,.863,.718,.427,.984,.71,.427,.322,.729,.404,.345,.733,.408,.404,.745,.412,.478,.765,.42,.588,.796,.424,.718,.843,.431,.863,.863,.435,1,.863,.435,.439,.749,.341,.455,.753,.341,.494,.765,.345,.557,.784,.349,.643,.812,.373,.733,.843,.388,.851,.89,.424,.976,.941,.451,.169,.184,.51,.176,.176,.522,.298,.176,.537,.416,.169,.541,.553,.153,.557,.698,.118,.553,.847,.094,.557,.929,.133,.565,.161,.212,.529,.18,.184,.541,.294,.184,.553,.427,.173,.561,.565,.153,.561,.718,.157,.565,.851,.157,.565,.933,.196,.565,.075,.29,.561,.141,.286,.573,.286,.29,.576,.424,.286,.573,.576,.29,.576,.718,.29,.576,.859,.286,.573,.933,.298,.569,0,.427,.573,.141,.427,.573,.286,.427,.573,.427,.427,.569,.573,.427,.573,.718,.431,.576,.859,.427,.573,.945,.424,.569,0,.573,.573,.149,.576,.576,.286,.573,.576,.427,.573,.573,.573,.573,.573,.718,.576,.576,.859,.573,.573,.961,.565,.573,0,.714,.573,.133,.714,.573,.278,.71,.573,.427,.714,.576,.573,.718,.573,.718,.714,.573,.859,.714,.576,.98,.71,.576,.325,.741,.537,.345,.745,.537,.404,.757,.545,.482,.78,.553,.588,.808,.565,.718,.851,.573,.859,.859,.569,1,.863,.573,.439,.761,.49,.451,.761,.486,.49,.776,.498,.557,.796,.51,.635,.82,.518,.737,.855,.537,.863,.906,.561,.976,.953,.588,.165,.231,.588,.227,.231,.592,.31,.235,.592,.408,.227,.588,.525,.227,.588,.635,.227,.584,.761,.239,.588,.878,.243,.588,.173,.255,.608,.216,.255,.604,.314,.255,.604,.408,.255,.6,.525,.255,.6,.643,.255,.596,.761,.267,.6,.882,.267,.596,.141,.314,.639,.208,.318,.639,.306,.318,.639,.42,.314,.631,.541,.318,.631,.659,.318,.624,.784,.325,.62,.91,.337,.624,.012,.431,.718,.149,.431,.714,.294,.431,.71,.431,.431,.702,.573,.427,.69,.71,.431,.678,.835,.435,.671,.945,.435,.667,0,.573,.714,.145,.573,.718,.29,.576,.718,.427,.573,.714,.576,.573,.714,.71,.569,.71,.859,.573,.714,.957,.569,.71,0,.71,.71,.129,.714,.714,.278,.714,.71,.427,.714,.714,.576,.718,.718,.714,.714,.714,.859,.718,.714,.973,.706,.714,.322,.753,.667,.337,.757,.667,.4,.769,.671,.482,.792,.686,.588,.824,.698,.714,.867,.718,.859,.863,.714,.996,.855,.714,.435,.773,.62,.459,.78,.627,.49,.788,.631,.557,.808,.643,.647,.835,.659,.749,.875,.675,.867,.918,.702,.988,.969,.725,.212,.29,.624,.243,.29,.62,.318,.29,.62,.396,.286,.62,.486,.286,.616,.58,.282,.608,.686,.282,.608,.788,.29,.608,.216,.306,.631,.251,.306,.631,.314,.306,.627,.392,.306,.627,.49,.302,.624,.58,.302,.62,.686,.302,.616,.796,.314,.616,.224,.345,.655,.255,.345,.659,.318,.345,.651,.396,.345,.651,.494,.345,.643,.592,.345,.639,.702,.353,.635,.816,.373,.643,.212,.424,.71,.247,.424,.706,.318,.424,.702,.412,.42,.694,.525,.431,.694,.635,.447,.698,.749,.459,.69,.859,.467,.69,.133,.569,.816,.2,.565,.812,.31,.569,.808,.443,.569,.792,.576,.569,.78,.694,.569,.765,.812,.58,.761,.914,.584,.753,0,.714,.855,.133,.714,.859,.286,.714,.863,.431,.714,.859,.573,.714,.859,.718,.714,.863,.859,.714,.839,.969,.706,.82,.302,.765,.796,.329,.769,.796,.392,.784,.808,.471,.804,.82,.588,.839,.847,.718,.859,.859,.859,.859,.859,.988,.855,.855,.439,.788,.749,.451,.792,.749,.498,.804,.757,.553,.82,.769,.647,.851,.784,.753,.886,.812,.871,.933,.839,.996,.984,.863,.224,.325,.643,.251,.325,.643,.306,.322,.639,.38,.322,.635,.459,.318,.631,.545,.318,.631,.631,.314,.624,.725,.322,.624,.235,.333,.647,.263,.337,.651,.31,.333,.647,.38,.333,.643,.463,.333,.639,.545,.333,.635,.631,.325,.627,.737,.337,.627,.251,.365,.671,.275,.365,.667,.318,.365,.667,.384,.361,.659,.467,.361,.655,.549,.361,.651,.651,.376,.651,.757,.4,.659,.255,.427,.71,.275,.42,.702,.329,.42,.702,.4,.42,.694,.486,.431,.698,.58,.447,.698,.686,.467,.702,.8,.494,.71,.278,.529,.78,.306,.533,.78,.373,.541,.78,.455,.545,.776,.553,.557,.776,.643,.569,.773,.749,.592,.776,.843,.604,.773,.275,.694,.898,.302,.694,.894,.384,.69,.886,.49,.698,.878,.604,.706,.871,.718,.706,.855,.812,.714,.847,.898,.722,.839,.31,.784,.925,.333,.788,.925,.388,.8,.941,.471,.824,.961,.592,.855,.973,.725,.851,.949,.859,.851,.929,.957,.855,.914,.435,.8,.867,.443,.804,.867,.494,.816,.875,.557,.835,.886,.651,.867,.91,.757,.906,.933,.878,.953,.969,1,1,1];
n=jF.$E(w,n);return[w,n]}();kc.prototype.y0=function(w){if(w){if(w.length==30240){this.y0(null);return}this.qL.r1039=w;
var n=ICC.R(w.buffer),j=null,I=17,m,l;if(n==null){this.y0(null);return}var W=n.header.spaceIn.toLowerCase(),D=JSON.stringify(n.tags.desc).toLowerCase();
try{j=ICC.U.profileName(n)}catch(fV){}if(W!="rgb "||j==null||D.indexOf("srgb")!=-1){this.y0(null);return}console.log("We got an ICC profile!",n,j);
try{var U=ICC.U.sampleLUT(n,I)}catch(fV){this.y0(null);return}var M=U.slice(0),A=E.Q(4),g=kc.Ka[0],k=kc.Ka[1];
for(var L=0;L<U.length;L+=3){A[0]=U[L]*255;A[1]=U[L+1]*255;A[2]=U[L+2]*255;ICC.U.applyLUT(k,g,A,A);M[L]=A[0]/255;
M[L+1]=A[1]/255;M[L+2]=A[2]/255}if(je.YG){m=new je.H0(I,I*I);m.set(ICC.U.lutToRGBA8(U,I));l=new je.H0(I,I*I);
l.set(ICC.U.lutToRGBA8(M,I))}this.To=[w,n,I,U,m,M,l]}else{delete this.qL.r1039;this.To=null}};kc.prototype.EY=function(){return this.To};
kc.prototype.Xf=function(){if(this.To)return this.To;if(this.add.fcmy==1){if(this.Kq==null){var w=kc.Ka[0],n=kc.Ka[1],W;
if(je.YG){W=new je.H0(w,w*w);W.set(ICC.U.lutToRGBA8(n,w))}this.Kq=[null,null,w,null,null,n,W]}return this.Kq}};
kc.prototype.a6X=function(){var w=this;if(w.u.zC.join("")!="111"){w.u.zC=[1,1,1];w.RP=!0}for(var L=0;
L<w.C.length;L++){var n=w.C[L],W=n.add.vmsk;if(n.YC()){var D=n.NP(w);if(D&&D.z&&D.z.$P){D.z.$P=!1;w.RP=!0}}var j=n._N();
if(j&&j.$P){j.$P=!1;w.RP=!0}if(W){if(W.g.length!=0)W.g=[];if(W.Rw.length!=0)W.Rw=[]}}};kc.prototype.j5=function(){var w=this;
return w.J!=null||w.OV()[1].length!=0||w.g.length>1};kc.prototype.Iw=function(){var w=this.jg,n=[];for(var L=0;
L<w.length;L++)n[L]=-1;var W=this.root.children;for(var L=0;L<W.length;L++){var D=W[L],j=D.j.add.artb;
if(j==null)continue;var I=j.guideIndeces;I=I?I.v:[];for(var U=0;U<I.length;U++)n[I[U].v]=D.index}return[JSON.parse(JSON.stringify(w)),n]};
kc.prototype.Pu=function(w){this.jg=JSON.parse(JSON.stringify(w[0]));var n=w[1],W=this.root.children;
for(var L=0;L<W.length;L++){var D=W[L],j=D.j.add.artb;if(j==null)continue;j.guideIndeces={t:"VlLs",v:[]}}for(var L=0;
L<n.length;L++)if(n[L]!=-1)this.C[n[L]].add.artb.guideIndeces.v.push({t:"long",v:L})};kc.prototype.a8p=function(w){var n=this;
if(w[0])n.add.lnk2=w[0];else delete n.add.lnk2;if(w[1])n.add.FEid=w[1];else delete n.add.FEid;if(w[2])n.add.Patt=w[2];
else delete n.add.Patt};kc.prototype.apA=function(w){var n=this,W=[],D=[],j=[],C=null,f=null,z=null;
for(var L=0;L<w.length;L++){var I=w[L];if(I.add.SoLd){W.push(I.add.SoLd.Idnt.v);D.push(I.add.SoLd.placed.v)}if(I.add.PtFl)j.push(I.add.PtFl.Ptrn.v.Idnt.v);
if(I.add.lmfx){for(var U=0;U<at.Pa.length;U++){var M=I.add.lmfx[at.Pa[U]].v;for(var m=0;m<M.length;m++)if(M[m].v.Ptrn){var l=M[m].v;
if(l.classID=="FrFX"&&l.PntT.v.FrFl!="Ptrn")continue;j.push(l.Ptrn.v.Idnt.v)}}}var A=I.add.vstk;if(A&&A.strokeStyleContent.v.classID=="patternLayer"){j.push(A.strokeStyleContent.v.Ptrn.v.Idnt.v)}}var g=n.add.lnk2,k=n.add.FEid,$=n.add.Patt;
if(g){C=[];for(var L=0;L<g.length;L++)if(W.indexOf(g[L].Z4)!=-1)C.push(g[L]);if(C.length==0)C=null}if(k){f=[];
for(var L=0;L<k.length;L++)if(D.indexOf(k[L].id)!=-1)f.push(k[L]);if(f.length==0)f=null}if($){z=[];for(var L=0;
L<$.length;L++)if(j.indexOf($[L].id)!=-1)z.push($[L]);if(z.length==0)z=null}return[C,f,z]};kc.prototype.gr=function(w){var n=this,W=n.root.fs(w==null?n.g[0]:w),D=!1;
while(W.parent!=null){D=D||W.j.m7(31);W=W.parent}return D};kc.prototype._A=function(){var w=this.yo,n=this.yo.length;
if(n!=0&&w[n-1].name=="Quick Mask")return w[n-1]};kc.prototype.Tu=function(){return this.Mc==hk.GF("% |/!)")||this.Mc==hk.Dn("gP")};
kc.prototype.om=function(w){var n=this.add.artd;if(w!=0)this.add.artd={classID:"null",Cnt:{t:"long",v:w},autoExpandOffset:{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:0},Vrtc:{t:"doub",v:0}}},origin:{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"doub",v:0},Vrtc:{t:"doub",v:0}}},autoExpandEnabled:{t:"bool",v:!0},autoNestEnabled:{t:"bool",v:!0},autoPositionEnabled:{t:"bool",v:!0}};
else delete this.add.artd};kc.prototype.V$=function(w){if(this.add.FEid==null)this.add.FEid=[];if(this.add.FEid.indexOf(w)==-1)this.add.FEid.push(w)};
kc.prototype._7=function(w){var n=this.add.FEid.indexOf(w);this.add.FEid.splice(n,1);if(this.add.FEid.length==0)delete this.add.FEid};
kc.prototype.l=function(w){if(w==null)w=new iB(0,0,this.m,this.n);if(this.zm==null)this.zm=w;else this.zm=this.zm.x0(w)};
kc.prototype.avj=function(w){return this.zm!=null};kc.prototype.aV=function(w){var n=this.C[w],W=this.root.fs(w);
if(W==null)return!1;if(n.ue()||W.parent.children.indexOf(W)==0)return!1;return!0};kc.adS=function(w){if(w.add.lnk2)for(var L=0;
L<w.add.lnk2.length;L++){var n=w.add.lnk2[L].Z4;w.add.lnk2[L].Z4=kc.Fa()+n.slice(8);for(var W=0;W<w.C.length;
W++){var D=w.C[W].add.SoLd;if(D&&D.Idnt.v==n)D.Idnt.v=w.add.lnk2[L].Z4}}};kc.prototype.nT=function(w,n,W){w.sort(function(g,k){return g-k});
var top=w[w.length-1],D=this.C.slice(0),j=this.g.slice(0),I=[],U=[];for(var L=0;L<this.C.length;L++){if(w.indexOf(L)!=-1)U.push(this.C[L]);
else I.push(this.C[L])}this.Gd(U);this.g=[];var M=this.root.pJ(this,!0);if(n)M=M.wU(n);if(W)M=M.x0(W);
if(M.VY())M=new iB(0,0,100,100);var m=new iB(-M.x,-M.y,this.m,this.n),l=new Uint8Array(jj.ZO("PSD").La(this,0,0,[!0,!1]));
this.Gd(D);this.g=j;var A=new kc(this.C[top].getName());jj.ZO("PSD").Vu(l.buffer,A);delete A.add.artd;
A.ej=[];A.Gd(A.C);A.Pu([[],[]]);kc.adS(A);y.QJ.Ov(A,M);A.l();A.tw();A.Vc();return[A,M,I,top]};kc.prototype.ad7=function(w,n,W){var D=this.nT(w),j=D[0],I=D[1],U=D[2],top=D[3],M;
if(W=="jpg")M=new Uint8Array(jj.ZO("JPG").La([[j.Vc().buffer]],j.m,j.n,[80]));else M=new Uint8Array(jj.ZO("PSD").La(j,null,null,[!0,!1]));
if(n)U=this.C.slice(0);var m=this.An(M,j.name,I.x,I.y);if(top==this.C.length-1)U.push(m);else U.splice(n?top+1:top-w.length+1,0,m);
this.Gd(U);this.g=[U.indexOf(m)]};kc.Fa=function(w){if(w==null)w="";var n="";while(n==""||n==w){n="";
for(var L=0;L<8;L++)n+=Math.floor(Math.random()*16).toString(16)}return n};kc.prototype.qn=function(w){if(w==null)return;
if(this.add.Patt==null)this.add.Patt=[];var n=this.add.Patt;for(var L=0;L<n.length;L++)if(n[L].id==w.id)return;
n.push(w)};kc.prototype.An=function(w,n,W,D,j,I,U){if(this.add.lnk2==null)this.add.lnk2=[];var M=null,$=!1;
for(var L=0;L<this.add.lnk2.length;L++)if(E.s9(w,this.add.lnk2[L].raw)){M=this.add.lnk2[L].Z4;break}if(M==null){var m=jj.zJ(w.buffer);
M=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f";var l=new h.FL;l.Z4=M;l.TA=m=="psd"?"8BIM":" ";l.O7=n+"."+m;
l.oq=m=="psd"?"8BPB":" ";l.open=0;l.raw=w;l.type="liFD";l.dk=2;this.add.lnk2.push(l)}var A=this.Zy(M,null,null,null,I,U),g=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f",k=this.QI();
k.nz(n);if(A!=null){var C=W==null,f=0,z=0;if(W==null)W=D=0;var s=this.m,O=this.n;if(j){f=j.x;z=j.y;s=j.m;
O=j.n}var a=k.rect=A.PO[1].clone();a.offset(f+W,z+D);var X=Math.max(a.m/s,a.n/O),$=j!=null&&X>1.0001;
if($){a.m=Math.round(a.m/X);a.n=Math.round(a.n/X)}else if(j!=null&&jj.zJ(w.buffer)=="pdf"&&this.hh!=144){var X=144/this.hh;
a.m=Math.round(a.m/X);a.n=Math.round(a.n/X);$=!0}if($||C){a.x=Math.round(f+(s-a.m)/2);a.y=Math.round(z+(O-a.n)/2)}k.buffer=E.Q(a.O()*4);
if(!$)E.nX(A.PO[0],k.buffer)}k.add.SoLd={classID:"null",Idnt:{t:"TEXT",v:M},Impr:{t:"Objc",v:{__name:"None",classID:"none"}},placed:{t:"TEXT",v:g},PgNm:{t:"long",v:1},totalPages:{t:"long",v:1},frameStep:{t:"Objc",v:{classID:"null",numerator:{t:"long",v:0},denominator:{t:"long",v:600}}},duration:{t:"Objc",v:{classID:"null",numerator:{t:"long",v:0},denominator:{t:"long",v:600}}},frameCount:{t:"long",v:1},Annt:{t:"long",v:16},Type:{t:"long",v:2},Trnf:null,nonAffineTransform:null,warp:{t:"Objc",v:E.XB.Q(A?A.PO[1]:k.rect)},Sz:{t:"Objc",v:{classID:"Pnt",Wdth:{t:"doub",v:k.rect.m},Hght:{t:"doub",v:k.rect.n}}},Rslt:{t:"UntF",v:{type:"#Rsl",val:A?A.hh:72}}};
var P=E.p.Wx(k.rect).w;k.add.SoLd.Trnf=y.wR.Hh(P);k.add.SoLd.nonAffineTransform=y.wR.Hh(P);if($)k.vr(this,!1);
return k};kc.prototype.Vc=function(w){if(w!=null){this.l();this.tw(w);var n=this.buffer;if(je.YG)this.jw.get(n);
else n=n.slice(0);this.l();this.tw();return n}if(this.zm){this.tw();this.zm=null}if(je.YG&&this.FB){this.jw.get(this.buffer);
this.FB=null;this.tL=!0}return this.buffer};kc.prototype.a4h=function(){for(var L=0;L<this.C.length;
L++)this.C[L].aqs();this.l()};kc.prototype.a5Q=function(){for(var L=0;L<this.C.length;L++)if(this.C[L].add.lmfx)this.C[L].US.Wq=!0};
kc.prototype.jd=function(){var w=this.qL.r1044;if(w==null){w=this.qL.r1044=new Uint8Array(4);var n=0;
for(var L=0;L<this.C.length;L++)n=Math.max(n,this.C[L].add.lyid);J.Ms(w,0,n)}var W=J.q(w,0);J.Ms(w,0,W+1);
return W+1};kc.prototype.d2=function(w,n,W){if(w==null)w=!0;var D=this;if(D.v9.length!=0)return!0;if(D.g.length!=1){if(w)alert(D.g.length==0?"Select a layer first.":"More than one layer selected.");
return!1}return this.dD(w,n,W)};kc.prototype.dD=function(w,n,W){if(w==null)w=!0;if(n==null)n=!1;var D=this;
if(D.v9.length!=0)return!0;for(var L=0;L<D.g.length;L++){var j=D.C[D.g[L]],I=n||j.eL<=0;if(j.add.lsct!=null&&j.add.lsct!=ef.Zd&&j.eL!=1){if(w)alert(fV.get([15,7,2]));
return!1}if(I&&!j.oK()){if(w)alert(fV.get([15,7,2]));return!1}if(I&&j.add.TySh){return this.aor(w,[15,7,3],W)}if(I&&j.add.SoLd){return this.aor(w,[15,7,4],W)}if(j.m7(1)||D.gr(D.g[L])){if(w)alert(fV.get([6,57,0]));
return!1}}return!0};kc.prototype.aor=function(w,n,W){if(w&&typeof w=="object"){var D=new ed(b.E.L);D.data={d:b.c.P2,jW:"confirm"};
D.data.Z=fV.get(n)+". "+fV.get([6,8])+"?";var j=w;D.data.FJ=function(){var I=new ed(b.E.W1,!0);I.data={hZ:"rasterizeLayer",E3:{classID:"rasterizeLayer",null:cq.Pz("Lyr",!0)}};
j.S(I)};w.S(D);return!1}if(w)alert(fV.get(n));return!1};kc.prototype.ajb=function(w){var n=this.root.fs(w);
if(n.parent)return n.j.I4()&&this.ajb(n.parent.index);else return n.j.I4()};kc.prototype.H2=function(w){var n=this;
if(w){var W=0;for(var L=0;L<n.g.length;L++)if(n.C[n.g[L]].add.artb)W++;if(W>1)return-1}if(n.add.artd&&n.g.length!=0){var D=n.root.fs(n.g[0]);
while(D.parent.parent)D=D.parent;if(D.j.add.artb)return D.index}return-1};kc.prototype.aiC=function(){var w=this.C[this.g[0]];
if(w.eL<=0&&!w.rect.L0(this.J.rect)){alert("Selected area is empty.");return!1}if(this.g.length==1&&this.J){var n=E.Q(this.J.channel.length);
E.KB(w.buffer,w.rect,n,this.J.rect);E.w5(this.J.channel,n);if(E.em(n,0)){alert("Selected area is empty.");
return!1}}return!0};kc.prototype.d4=function(){if(this.qL["r"+1037]==null)this.UB(30);return J.W6(this.qL["r"+1037],0)};
kc.prototype.UB=function(w){if(this.qL["r"+1037]==null)this.qL["r"+1037]=new Uint8Array(4);if(J.W6(this.qL["r"+1037],0)==w)return;
J.KW(this.qL["r"+1037],0,w);this.a5Q()};kc.prototype.wS=function(){if(this.qL["r"+1049]==null)this.GT(30);
return J.W6(this.qL["r"+1049],0)};kc.prototype.GT=function(w){if(this.qL["r"+1049]==null)this.qL["r"+1049]=new Uint8Array(4);
if(J.W6(this.qL["r"+1049],0)==w)return;J.KW(this.qL["r"+1049],0,w);this.a5Q()};kc.prototype.mZ=function(w){if(this.add.lnk2==null)return null;
for(var L=0;L<this.add.lnk2.length;L++)if(this.add.lnk2[L].Z4==w)return this.add.lnk2[L];return null};
kc.prototype.abg=function(w){var n=this.mZ(w);if(n==null)return!1;var W=jj.zJ(n.raw.buffer);if(W==null)return!1;
if(jj.ZO(W)!=null||W=="psd")return!0;return!1};kc.prototype.Zy=function(w,n,W,D,j,I){var U=this.mZ(w);
if(U==null)return null;U.Vc(n,W,D,j,I);if(U.PO)return U};kc.prototype.apB=function(){var w=this.m,n=this.n;
if(je.YG&&this.jw==null)this.jw=new je.H0(w,n,!0);if(this.buffer==null||this.buffer.length!=w*n*4||je.YG&&(this.jw.m!=w||this.jw.n!=n)){this.buffer=E.Q(w*n*4);
if(this.jw)this.jw.delete();if(je.YG)this.jw=new je.H0(w,n,!0)}};kc.prototype.aAt=function(){this.apB();
if(je.YG){this.jw.set(this.buffer)}};kc.prototype.tw=function(w){var n=this.m,W=this.n,D=new iB(0,0,n,W),j=this.v_?D:D.wU(this.zm);
this.apB();if(j.VY())return;if(!j.s9(D)){if(!je.YG){var I=E.LR(j.O()*4);E.Cb(I,j,this.buffer,D)}if(je.YG){je.t5(this.jw,j);
je.oT(0)}}else{if(je.YG){this.jw.set(null)}else{this.buffer.fill(0)}}var U=Date.now(),M=je.YG?this.jw:this.buffer;
if(w==null)w=1e9;var m=this.root.children;for(var L=0;L<m.length;L++){var l=m[L].j;if(l.I4()&&l.add.artb&&this.add.artd){var A=l.yP(),g=j.wU(A),k=l.L9();
if(k!=0){if(je.YG){je.t5(M,g);je.oT(k);je.oT(k)}else E.ae$(M,D,g,k)}}}this.root.MP(M,D,j,this,[],w);
this.FB=this.zm.clone()};kc.prototype.QI=function(w){var n=new h;n.rect=new iB(0,0,0,0);n.buffer=E.Q(1);
n.add.luni=new ec(0,0);if(w!=!0)n.add.lyid=this.jd();n.add.lsct=ef.Zd;n.add.lclr=0;n.add.fxrp=new ec(0,0);
return n};kc.prototype.hG=function(w){var n=this.QI(w);n.nz("</Layer group>");n.add.lsct=ef.Cq;n.FK=24;
return n};kc.prototype.VO=function(){return this.QQ!=this.Js};kc.prototype.kK=function(w){while(this.history.length>this.QQ+1)this.history.pop();
if(this.Js>this.QQ)this.Js=-1;if(w.G.id!=y.q$){this.P6=!0;if(this.kO.lastAppliedComp){delete this.kO.lastAppliedComp;
this.tL=!0}}this.history.push(w);this.QQ++;this.tL=!0;var n=bh.d$()?60:30,W=0;for(var L=this.history.length-1;
L>=0;L--){var D=this.history[L];if(D._$)continue;W++;if(W==n){this.QQ-=L;this.history=this.history.slice(L);
break}}};kc.prototype.by=function(){if(this.QQ!=this.history.length-1)return null;return this.history[this.history.length-1]};
kc.prototype.qu=function(w,n,W,D){if(w==null)w=!1;var j=n!=null?[n]:this.g.slice(0);if(D){var I=[];for(var L=0;
L<j.length;L++){var U=this.C[j[L]],M=U.Ux;if(U.lj&&M!=0&&I.indexOf(M)==-1)I.push(M)}if(I.length!=0)for(var L=0;
L<this.C.length;L++){var U=this.C[L],M=U.Ux;if(U.lj&&M!=0&&I.indexOf(M)!=-1&&j.indexOf(L)==-1)j.push(L)}}var m=[];
for(var L=0;L<j.length;L++){var l=this.rZ(j[L],w);for(var A=0;A<l.length;A++)if(m.indexOf(l[A])==-1)m.push(l[A]);
if(W){var bK=this.root.fs(j[L]);while(bK.parent!=null&&bK.parent.parent!=null){bK=bK.parent;if(m.indexOf(bK.index)==-1){m.push(bK.index,bK.r$)}}}}return m};
kc.prototype.Jr=function(w,n,W){var D=this,j=D.qu(!1,w,null,W);j.sort(function(a,X){return a-X});var I={};
for(var U=0;U<D.C.length;U++){var M=D.C[U].getName();I[M]=!0}var m=[];for(var L=0;L<j.length;L++){var l=D.C[j[L]].clone(),z,s;
l.add.lyid=D.jd();l.add.lspf=0;if(l.YC()){var A=l.NP(D),g=kc.a2e(A);D.V$(g);l.add.SoLd.placed.v=g.id}else if(l.add.SoLd){var k=l.add.SoLd.placed.v;
l.add.SoLd.placed.v=kc.Fa(k.slice(0,8))+k.slice(8)}l.yb(D);var $=l.getName(),C=$.length;while(48<=$.charCodeAt(C-1)&&$.charCodeAt(C-1)<=57)C--;
var f=parseInt($.slice(C));if(isNaN(f)){if($.endsWith(" copy")){f=1;z=$.slice(0,$.length-5)}else{f=0;
z=$}}else if($.slice(0,C).endsWith(" copy ")){f=f;z=$.slice(0,C-6)}else{f=0;z=$}f++;while(!0){s=z+" copy"+(f==1?"":" "+f);
if(I[s]==null)break;f++}var O=j.indexOf(this.root.fs(j[L]).parent.index)!=-1;if($=="Background"&&D.C.length==1)s="Layer 1";
if(n!=!0&&!O)l.nz(s);I[s]=!0;m.push(l)}return m};kc.a2e=function(w){return{id:kc.Fa(w.id.slice(0,8))+w.id.slice(8),buffer:w.buffer.slice(0),rect:w.rect.clone(),z:w.z?w.z.clone():null}};
kc.ap8=function(w){return{id:w,rect:new iB,buffer:E.Q(1),z:new h.ac}};kc.bb=function(w,n){if(n==null)n={vmsk:new h.Rd};
if(n.vogk==null){n.vogk=[];var W=E.P.bB(n.vmsk.i);for(var D=0;D<W;D++)n.vogk.push(E.X.LR())}return{name:w,p_:0,add:n}};
kc.prototype.OV=function(w){var n=[],W=[],D=this;for(var L=1;L<D.Oi.length;L++){var j=D.Oi[L];j.p_=-1-L;
n.push(j);if(D.rs.indexOf(L)!=-1)W.push(n.length-1)}if(D.Oi[0].add.vmsk.i.length>2){var j=D.Oi[0];j.p_=-1;
n.push(j);if(D.rs.indexOf(0)!=-1)W.push(n.length-1)}var I=D.zS==null;if(I)D.zS=[];for(var L=D.g.length-1;
L>=0;L--){var U=D.g[L],M=D.C[U],m=M.add.TySh;if(M.add.vmsk!=null){var j=kc.bb("\""+M.getName()+"\" Shape Path",M.add);
j.p_=U;n.push(j);if(I&&(M.na||M.I9()))D.zS.push(U);if(D.zS.indexOf(U)!=-1)W.push(n.length-1)}if(w!=!0&&m&&m.add&&E.XB.pi(m.hc)){var j=kc.bb("\""+M.getName().slice(0,10)+"..\" Text Path",m.add);
j.p_=1e6+D.g[L];n.push(j);W.push(n.length-1)}}if(W.length==0&&w){D.Oi[0].p_=-1;D.rs=[0];W.push(n.length);
n.push(D.Oi[0])}return[n,W]};kc.prototype.rZ=function(L,w){var n=[],bK=this.root.fs(L);if(bK)bK.lS(n,w);
return n};kc.prototype.hd=function(){this.root.sX(this,new iB(0,0,this.m,this.n))};kc.prototype.Gd=function(w){for(var L=0;
L<this.C.length;L++){var n=this.C[L];if(w.indexOf(n)==-1){n.US.a98();n.l()}}var W=0;for(var L=0;L<w.length;
L++)if(w[L].add.artb)W++;this.om(W);this.C=w.slice(0);this.X0()};kc.prototype.X0=function(){var w=this.C,n=w.length;
this.root=new jo;var W=this.QI(!0);W.Bx="pass";W.add.lsct=ef.fz;W.nz("");var D=this.hG(!0),j=[D];for(var L=0;
L<n;L++)j.push(w[L]);j.push(W);this.root.arN(j,0,0);if(this.g.length==0)this.g=[n-1]};kc.prototype.jO=function(){if(this.g.length!=1)return;
var w=this.root.fs(this.g[0]);while(w.parent!=null){var n=w.parent.j;n.add.lsct=ef.fz;w=w.parent}this.RP=this.a2t=!0};
kc.prototype.alY=function(){this.X0();var w=[this.root],b3=0;while(w.length!=0){var top=w.pop();b3++;
if(top.j.add.lsct==ef.fz)for(var L=0;L<top.children.length;L++)w.push(top.children[L])}if(b3>1e3){var n=this.root.children;
for(var L=0;L<n.length;L++)if(n[L].j.add.lsct==ef.fz)n[L].j.add.lsct=ef.Se}};kc.xM=function(w,n,W,D,j,I,U,M){if(M==null)M="sRGB IEC61966-2.1";
var m={__name:"Make",classID:"Mk",Nw:{t:"Objc",v:{classID:"Dcmn",Nm:{t:"TEXT",v:D},artboard:{t:"bool",v:I},Md:{t:"type",v:{classID:"RGBM"}},Wdth:{t:"UntF",v:{type:"#Rlt",val:w*72/W}},Hght:{t:"UntF",v:{type:"#Rlt",val:n*72/W}},Rslt:{t:"UntF",v:{type:"#Rsl",val:W}},pixelScaleFactor:{t:"doub",v:1},Fl:{t:"enum",v:{Fl:j}},Dpth:{t:"long",v:8},profile:{t:"TEXT",v:M}}}};
if(j=="Clr")m.Nw.v.FlCl={t:"Objc",v:U};return{hZ:"make",E3:m}};kc.awd=function(w,n){var W=0,D=0,j=72,I=n.ag$,U=w.preset&&w.preset.v=="Clipboard";
if(U){W=I.m;D=I.n}else{W=w.Wdth.v.val;D=w.Hght.v.val;j=w.Rslt.v.val;W=Math.round(W*j/72);D=Math.round(D*j/72)}var M=new kc((w.Nm?w.Nm.v:fV.get([11,7]))+".psd");
M.m=W;M.n=D;M.hh=j;var m=w.Fl?w.Fl.v.Fl:"Wht";if(w.artboard&&w.artboard.v){var l=M.QI();l.nz(fV.get([1,16,0])+" 1");
l.add.lsct=ef.fz;l.MR(new iB(0,0,W,D));l.add.artb.artboardBackgroundType={t:"long",v:{Wht:1,Blck:2,Trns:3,BckC:1,Clr:4}[m]};
if(m=="Clr")l.add.artb.Clr={t:"Objc",v:E.M.lW(E.M.y_(w.FlCl.v))};l.Bx="pass";l.FK=24;var A=M.QI();A.nz("Layer 1");
M.Gd([M.hG(),A,l]);M.om(1);M.g=[1]}else{var g=M.QI(),k=0;g.nz("Background");M.Gd([g]);g.add.lspf=1<<2;
if(m=="Clr"){k=E.M.y_(w.FlCl.v);k=255<<24|Math.round(k.k)<<16|Math.round(k.B)<<8|Math.round(k.o)}else{var $=n.as;
$=($&255)<<16|($>>>8&255)<<8|$>>>16;k={Trns:0,Wht:4294967295,Blck:4278190080,BckC:255<<24|$}[m]}g.rect=new iB(0,0,W,D);
g.buffer=E.Q(W*D*4);E.cJ(g.buffer,k)}M.buffer=E.Q(W*D*4);var C=w.profile;if(C){var f={"Adobe RGB (1998)":"icc/adobe","ProPhoto RGB":"icc/prophoto","image P3":"icc/displayp3"}[C.v];
if(f)M.y0(jj.gF.get(f))}return M};function hs(w){this.On=w;this.N=0;this.fd=1;this.R=new ec(0,0);this.$M=new ec(0,0);
this.Tg=0;this.zC=[1,1,1];this.PM=0;this.xq=new iB(0,0,1,1);this.azK=new iB(0,0,w.m,w.n);this.Bn=null;
this.PS=null;this.YM=new Uint32Array(0);this.eJ=null;this.Ie=null;this.Fl=E.Q(0);this.Ud=null;this.x4=null}hs.prototype.Pv=function(w){var n=new eh,W=this.xq,D=this.On,j=w?this.fd:this.N,I=w?this.$M:this.R,U=Math.round((W.m-D.m*j)/2+I.x),M=Math.round((W.n-D.n*j)/2+I.y);
n.translate(-U,-M);n.scale(1/j,1/j);var m=D.m/2,l=D.n/2;n.translate(-m,-l);n.rotate(this.Tg);n.translate(m,l);
return n};hs.prototype.a3Y=function(w){var n=this.xq,W=this.On,D=Math.atan2(-w.k,w.dl),j=W.m/2,I=W.n/2;
w.translate(-j,-I);w.rotate(-D);w.translate(j,I);var U=1/w.NW();w.scale(U,U);var M=-w.z2,m=-w.EU,l=Math.round(M-(n.m-W.m*U)/2),A=Math.round(m-(n.n-W.n*U)/2);
if(Math.abs(U-Math.round(U))<1e-6)U=Math.round(U);this.Tg=D;this.N=U;this.R=new ec(l,A)};hs.prototype.Cg=function(w,n){var W=this.Pv();
return W.bj(new ec(w,n))};hs.prototype.m9=function(w,n){var W=this.Pv();W.Ba();return W.bj(new ec(w,n))};
function at(){}at.order="ebbl FrFX IrSh IrGl ChFX SoFi GrFl patternFill OrGl DrSh".split(" ");at.Pa="ebblMulti frameFXMulti innerShadowMulti IrGlMulti ChFXMulti solidFillMulti gradientFillMulti patternFillMulti OrGlMulti dropShadowMulti".split(" ");
at.names=[[14,4],[14,9],[14,1],[14,3],[14,8],[14,5],[14,6],[14,7],[14,2],[14,0]];at.af4=["DrSh","IrSh","SoFi","GrFl","FrFX"];
at.Oa=["Clr"];at.Ki="Grad Rvrs Type Algn Angl Dthr Scl Ofst".split(" ");at.v7=["Ptrn","Angl","Scl","Algn","phase"];
at._V={MB:"{\"t\":\"Objc\",\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":0,\"t\":\"doub\"},\"Grn\":{\"v\":0,\"t\":\"doub\"},\"Bl\":{\"v\":0,\"t\":\"doub\"}}}",a0x:"{\"t\":\"Objc\",\"v\":{\"classID\":\"Grdn\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"Two Color\" },\"GrdF\":{\"t\":\"enum\",\"v\":{\"GrdF\":\"CstS\"}},\"Intr\":{\"t\":\"doub\",\"v\":4096},\"Clrs\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"Objc\",\"v\":{\"classID\":\"Clrt\",\"Type\":{\"t\":\"enum\",\"v\":{\"Clry\":\"UsrS\"}},\"Lctn\":{\"t\":\"long\",\"v\":0},\"Mdpn\":{\"t\":\"long\",\"v\":50},\"Clr\":{\"t\":\"Objc\",\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"t\":\"doub\",\"v\":0},\"Grn\":{\"t\":\"doub\",\"v\":0},\"Bl\":{\"t\":\"doub\",\"v\":0}}}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"Clrt\",\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":255,\"t\":\"doub\"},\"Grn\":{\"v\":255,\"t\":\"doub\"},\"Bl\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"},\"Type\":{\"v\":{\"Clry\":\"UsrS\"},\"t\":\"enum\"},\"Lctn\":{\"v\":4096,\"t\":\"long\"},\"Mdpn\":{\"v\":50,\"t\":\"long\"}},\"t\":\"Objc\"}]},\"Trns\":{\"v\":[{\"v\":{\"classID\":\"TrnS\",\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},\"Lctn\":{\"v\":0,\"t\":\"long\"},\"Mdpn\":{\"v\":50,\"t\":\"long\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"TrnS\",\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},\"Lctn\":{\"v\":4096,\"t\":\"long\"},\"Mdpn\":{\"v\":50,\"t\":\"long\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}}}",a1X:"{\"t\":\"Objc\",\"v\":{\"classID\":\"Grdn\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"Foreground to Background\"},\"GrdF\":{\"t\":\"enum\",\"v\":{\"GrdF\":\"CstS\"}},\"Intr\":{\"t\":\"doub\",\"v\":4096},\"Clrs\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"Objc\",\"v\":{\"classID\":\"Clrt\",\"Type\":{\"t\":\"enum\",\"v\":{\"Clry\":\"FrgC\"}},\"Lctn\":{\"t\":\"long\",\"v\":0},\"Mdpn\":{\"t\":\"long\",\"v\":50}}},{\"t\":\"Objc\",\"v\":{\"classID\":\"Clrt\",\"Type\":{\"t\":\"enum\",\"v\":{\"Clry\":\"BckC\"}},\"Lctn\":{\"t\":\"long\",\"v\":4096},\"Mdpn\":{\"t\":\"long\",\"v\":50}}}]},\"Trns\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"Objc\",\"v\":{\"classID\":\"TrnS\",\"Opct\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":100}},\"Lctn\":{\"t\":\"long\",\"v\":0},\"Mdpn\":{\"t\":\"long\",\"v\":50}}},{\"t\":\"Objc\",\"v\":{\"classID\":\"TrnS\",\"Opct\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":100}},\"Lctn\":{\"t\":\"long\",\"v\":4096},\"Mdpn\":{\"t\":\"long\",\"v\":50}}}]}}}",abX:"{\"t\":\"Objc\",\"v\":{\"classID\":\"Grdn\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"Custom\" },\"GrdF\":{\"t\":\"enum\",\"v\":{\"GrdF\":\"ClNs\"}},\"ShTr\":{\"t\":\"bool\",\"v\":false},\"VctC\":{\"t\":\"bool\",\"v\":false},\"ClrS\":{\"t\":\"enum\",\"v\":{\"ClrS\":\"RGBC\"}},\"RndS\":{\"t\":\"long\",\"v\":1466092501},\"Smth\":{\"t\":\"long\",\"v\":2048},\"Mnm\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"long\",\"v\":0},{\"t\":\"long\",\"v\":0},{\"t\":\"long\",\"v\":0},{\"t\":\"long\",\"v\":0}]},\"Mxm\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"long\",\"v\":100},{\"t\":\"long\",\"v\":100},{\"t\":\"long\",\"v\":100},{\"t\":\"long\",\"v\":100}]}}}",Ke:"{\"t\":\"Objc\",\"v\":{\"classID\":\"Ptrn\",\"Nm\":{\"v\":\"orangeslices\",\"t\":\"TEXT\"},\"Idnt\":{\"v\":\"c7acb22a-47a6-11de-919a-bf574370eaaf\",\"t\":\"TEXT\"}}}"};
at._V.MB="\"Clr\": "+at._V.MB;at._V.M="\"Grad\":"+at._V.a0x+",\"Scl\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},\"Algn\":{\"v\":true,\"t\":\"bool\"},\"Angl\":{\"v\":{\"type\":\"#Ang\",\"val\":90},\"t\":\"UntF\"},\"Rvrs\":{\"v\":false,\"t\":\"bool\"},\"Type\":{\"v\":{\"GrdT\":\"Lnr\"},\"t\":\"enum\"},\"Ofst\":{\"v\":{\"classID\":\"Pnt\",\"Hrzn\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"Vrtc\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"}},\"t\":\"Objc\"},\"Dthr\":{\"v\":false,\"t\":\"bool\"}";
at._V.Ke="\"Ptrn\":"+at._V.Ke+",\"Scl\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},\"Algn\":{\"v\":true,\"t\":\"bool\"},\"Angl\":{\"v\":{\"type\":\"#Ang\",\"val\": 0},\"t\":\"UntF\"},\"phase\":{\"v\":{\"classID\":\"Pnt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"}";
at.default="{ \"classID\": \"null\", \"Scl\": {\"t\": \"UntF\", \"v\": { \"type\": \"#Prc\",\"val\": 100} }, \"masterFXSwitch\": {\"t\": \"bool\",\"v\": true} }";
at.UR=["{\"classID\":\"ebbl\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"hglM\":{\"t\":\"enum\",\"v\":{\"BlnM\":\"Scrn\"}},\"hglC\":{\"t\":\"Objc\",\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"t\":\"doub\",\"v\":255},\"Grn\":{\"t\":\"doub\",\"v\":255},\"Bl\":{\"t\":\"doub\",\"v\":255}}},\"hglO\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":75}},\"sdwM\":{\"t\":\"enum\",\"v\":{\"BlnM\":\"Mltp\"}},\"sdwC\":{\"t\":\"Objc\",\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"t\":\"doub\",\"v\":0},\"Grn\":{\"t\":\"doub\",\"v\":0},\"Bl\":{\"t\":\"doub\",\"v\":0}}},\"sdwO\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":75}},\"bvlT\":{\"t\":\"enum\",\"v\":{\"bvlT\":\"SfBL\"}},\"bvlS\":{\"t\":\"enum\",\"v\":{\"BESl\":\"InrB\"}},\"uglg\":{\"t\":\"bool\",\"v\":true},\"lagl\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Ang\",\"val\":120}},\"Lald\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Ang\",\"val\":30}},\"srgR\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":100}},\"blur\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Pxl\",\"val\":5}},\"bvlD\":{\"t\":\"enum\",\"v\":{\"BESs\":\"In\"}},\"TrnS\":{\"t\":\"Objc\",\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"Linear\"},\"Crv\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"Objc\",\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"t\":\"doub\",\"v\":0},\"Vrtc\":{\"t\":\"doub\",\"v\":0}}},{\"t\":\"Objc\",\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"t\":\"doub\",\"v\":255},\"Vrtc\":{\"t\":\"doub\",\"v\":255}}}]}}},\"antialiasGloss\":{\"t\":\"bool\",\"v\":false},\"Sftn\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Pxl\",\"val\":0}},\"useShape\":{\"t\":\"bool\",\"v\":false},\"MpgS\":{\"t\":\"Objc\",\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"Linear\"},\"Crv\":{\"t\":\"VlLs\",\"v\":[{\"t\":\"Objc\",\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"t\":\"doub\",\"v\":0},\"Vrtc\":{\"t\":\"doub\",\"v\":0}}},{\"t\":\"Objc\",\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"t\":\"doub\",\"v\":255},\"Vrtc\":{\"t\":\"doub\",\"v\":255}}}]}}},\"AntA\":{\"t\":\"bool\",\"v\":false},\"Inpr\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":28}},\"useTexture\":{\"t\":\"bool\",\"v\":false},\"InvT\":{\"t\":\"bool\",\"v\":false},\"Algn\":{\"t\":\"bool\",\"v\":true},\"Scl\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":100}},\"textureDepth\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":100}},\"Ptrn\":{\"t\":\"Objc\",\"v\":{\"classID\":\"Ptrn\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"orangeslices\"},\"Idnt\":{\"t\":\"TEXT\",\"v\":\"c7acb22a-47a6-11de-919a-bf574370eaaf\"}}},\"phase\":{\"t\":\"Objc\",\"v\":{\"classID\":\"Pnt\",\"Hrzn\":{\"t\":\"doub\",\"v\":0},\"Vrtc\":{\"t\":\"doub\",\"v\":0}}}}","{\"classID\":\"FrFX\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Nrml\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},\"Styl\":{\"v\":{\"FStl\":\"OutF\"},\"t\":\"enum\"},\"PntT\":{\"v\":{\"FrFl\":\"SClr\"},\"t\":\"enum\"},\"Sz\":{\"v\":{\"type\":\"#Pxl\",\"val\":3},\"t\":\"UntF\"},"+at._V.MB+","+at._V.M+","+at._V.Ke+"}","{\"classID\":\"IrSh\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Mltp\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\": 75},\"t\":\"UntF\"},\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":0,\"t\":\"doub\"},\"Grn\":{\"v\":0,\"t\":\"doub\"},\"Bl\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},\"uglg\":{\"v\":true,\"t\":\"bool\"},\"lagl\":{\"v\":{\"type\":\"#Ang\",\"val\":120},\"t\":\"UntF\"},\"Dstn\":{\"v\":{\"type\":\"#Pxl\",\"val\":5},\"t\":\"UntF\"},\"Ckmt\":{\"v\":{\"type\":\"#Pxl\",\"val\":0},\"t\":\"UntF\"},\"blur\":{\"v\":{\"type\":\"#Pxl\",\"val\":5},\"t\":\"UntF\"},\"Nose\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"AntA\":{\"v\":false,\"t\":\"bool\"},\"TrnS\":{\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"v\":\"Linear\",\"t\":\"TEXT\"},\"Crv\":{\"v\":[{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":255,\"t\":\"doub\"},\"Vrtc\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}},\"t\":\"Objc\"}}","{\"classID\":\"IrGl\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Scrn\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\": 75},\"t\":\"UntF\"},\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":255,\"t\":\"doub\"},\"Grn\":{\"v\":255,\"t\":\"doub\"},\"Bl\":{\"v\":189.99710083007812,\"t\":\"doub\"}},\"t\":\"Objc\"},\"GlwT\":{\"v\":{\"BETE\":\"SfBL\"},\"t\":\"enum\"},\"Ckmt\":{\"v\":{\"type\":\"#Pxl\",\"val\":0},\"t\":\"UntF\"},\"blur\":{\"v\":{\"type\":\"#Pxl\",\"val\":5},\"t\":\"UntF\"},\"ShdN\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"Nose\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"AntA\":{\"v\":false,\"t\":\"bool\"},\"glwS\":{\"v\":{\"IGSr\":\"SrcE\"},\"t\":\"enum\"},\"TrnS\":{\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"v\":\"Linear\",\"t\":\"TEXT\"},\"Crv\":{\"v\":[{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":255,\"t\":\"doub\"},\"Vrtc\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}},\"t\":\"Objc\"},\"Inpr\":{\"v\":{\"type\":\"#Prc\",\"val\":50},\"t\":\"UntF\"}}","{\"classID\":\"ChFX\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Mltp\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\": 50},\"t\":\"UntF\"},\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":0,\"t\":\"doub\"},\"Grn\":{\"v\":0,\"t\":\"doub\"},\"Bl\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},\"AntA\":{\"v\":false,\"t\":\"bool\"},\"Invr\":{\"v\":true,\"t\":\"bool\"},\"lagl\":{\"v\":{\"type\":\"#Ang\",\"val\":19},\"t\":\"UntF\"},\"Dstn\":{\"v\":{\"type\":\"#Pxl\",\"val\":11},\"t\":\"UntF\"},\"blur\":{\"v\":{\"type\":\"#Pxl\",\"val\":14},\"t\":\"UntF\"},\"MpgS\":{\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"v\":\"Gaussian\",\"t\":\"TEXT\"},\"Crv\":{\"v\":[{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":32,\"t\":\"doub\"},\"Vrtc\":{\"v\":7,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":64,\"t\":\"doub\"},\"Vrtc\":{\"v\":38,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":96,\"t\":\"doub\"},\"Vrtc\":{\"v\":101,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":128,\"t\":\"doub\"},\"Vrtc\":{\"v\":166,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":159,\"t\":\"doub\"},\"Vrtc\":{\"v\":209,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":191,\"t\":\"doub\"},\"Vrtc\":{\"v\":235,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":223,\"t\":\"doub\"},\"Vrtc\":{\"v\":248,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":255,\"t\":\"doub\"},\"Vrtc\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}},\"t\":\"Objc\"}}","{\"classID\":\"SoFi\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Nrml\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},"+at._V.MB+"}","{\"classID\":\"GrFl\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Nrml\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},"+at._V.M+"}","{\"classID\":\"patternFill\",\"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Nrml\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\":100},\"t\":\"UntF\"},"+at._V.Ke+"}","{\"classID\":\"OrGl\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Scrn\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\": 75},\"t\":\"UntF\"},\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":255,\"t\":\"doub\"},\"Grn\":{\"v\":255,\"t\":\"doub\"},\"Bl\":{\"v\":189.99710083007812,\"t\":\"doub\"}},\"t\":\"Objc\"},\"GlwT\":{\"v\":{\"BETE\":\"SfBL\"},\"t\":\"enum\"},\"Ckmt\":{\"v\":{\"type\":\"#Pxl\",\"val\":0},\"t\":\"UntF\"},\"blur\":{\"v\":{\"type\":\"#Pxl\",\"val\":5},\"t\":\"UntF\"},\"Nose\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"ShdN\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"AntA\":{\"v\":false,\"t\":\"bool\"},\"TrnS\":{\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"v\":\"Linear\",\"t\":\"TEXT\"},\"Crv\":{\"v\":[{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":255,\"t\":\"doub\"},\"Vrtc\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}},\"t\":\"Objc\"},\"Inpr\":{\"v\":{\"type\":\"#Prc\",\"val\":50},\"t\":\"UntF\"}}","{\"classID\":\"DrSh\", \"enab\":{\"v\":true,\"t\":\"bool\"}, \"Md\":{\"v\":{\"BlnM\":\"Mltp\"},\"t\":\"enum\"},\"Opct\":{\"v\":{\"type\":\"#Prc\",\"val\": 57},\"t\":\"UntF\"},\"Clr\":{\"v\":{\"classID\":\"RGBC\",\"Rd\":{\"v\":0,\"t\":\"doub\"},\"Grn\":{\"v\":0,\"t\":\"doub\"},\"Bl\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},\"uglg\":{\"v\":true,\"t\":\"bool\"},\"lagl\":{\"v\":{\"type\":\"#Ang\",\"val\":120},\"t\":\"UntF\"},\"Dstn\":{\"v\":{\"type\":\"#Pxl\",\"val\":27},\"t\":\"UntF\"},\"Ckmt\":{\"v\":{\"type\":\"#Pxl\",\"val\":0},\"t\":\"UntF\"},\"blur\":{\"v\":{\"type\":\"#Pxl\",\"val\":13},\"t\":\"UntF\"},\"Nose\":{\"v\":{\"type\":\"#Prc\",\"val\":0},\"t\":\"UntF\"},\"AntA\":{\"v\":false,\"t\":\"bool\"},\"TrnS\":{\"v\":{\"classID\":\"ShpC\",\"Nm\":{\"v\":\"Line\xE1rn\xED\",\"t\":\"TEXT\"},\"Crv\":{\"v\":[{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":0,\"t\":\"doub\"},\"Vrtc\":{\"v\":0,\"t\":\"doub\"}},\"t\":\"Objc\"},{\"v\":{\"classID\":\"CrPt\",\"Hrzn\":{\"v\":255,\"t\":\"doub\"},\"Vrtc\":{\"v\":255,\"t\":\"doub\"}},\"t\":\"Objc\"}],\"t\":\"VlLs\"}},\"t\":\"Objc\"},\"layerConceals\":{\"v\":true,\"t\":\"bool\"},\"Cntn\":{\"v\":false,\"t\":\"bool\"}}"];
at.M={types:"Lnr Rdl Angl Rflc Dmnd shapeburst".split(" "),names:[[19,0,0],[19,0,1],[19,0,2],[19,0,3],[19,0,4],[19,0,5]]};
at.stroke={types:["InsF","CtrF","OutF"],names:[[19,5,2],[19,5,1],[19,5,0]],iX:["SClr","GrFl","Ptrn"],azS:[[13,0],[12,37],[12,62]]};
at.Nx={types:["SfBL","PrBL"],names:[[19,1,0],[19,1,1]],azc:["SrcC","SrcE"],avL:[[19,5,1],[12,69]]};at.x7={types:["OtrB","InrB","Embs","PlEb","strokeEmboss"],style:[[19,2,0],[19,2,1],[19,2,2],[19,2,3],[19,2,4]],axt:["SfBL","PrBL","Slmt"],ab1:[[19,3,0],[19,3,1],[19,3,2]],dir:[[19,4,0],[19,4,1]]};
at.QO={EZ:["strokeStyleButtCap","strokeStyleRoundCap","strokeStyleSquareCap"],n2:["strokeStyleAlignInside","strokeStyleAlignCenter","strokeStyleAlignOutside"],join:["strokeStyleMiterJoin","strokeStyleRoundJoin","strokeStyleBevelJoin"],W_:["solidColorLayer","gradientLayer","patternLayer"],default:{classID:"strokeStyle",strokeStyleVersion:{t:"long",v:2},strokeEnabled:{t:"bool",v:!1},fillEnabled:{t:"bool",v:!0},strokeStyleLineWidth:{t:"UntF",v:{type:"#Pnt",val:1}},strokeStyleLineDashOffset:{t:"UntF",v:{type:"#Pnt",val:0}},strokeStyleMiterLimit:{t:"doub",v:100},strokeStyleLineCapType:{t:"enum",v:{strokeStyleLineCapType:"strokeStyleButtCap"}},strokeStyleLineJoinType:{t:"enum",v:{strokeStyleLineJoinType:"strokeStyleMiterJoin"}},strokeStyleLineAlignment:{t:"enum",v:{strokeStyleLineAlignment:"strokeStyleAlignCenter"}},strokeStyleScaleLock:{t:"bool",v:!1},strokeStyleStrokeAdjust:{t:"bool",v:!1},strokeStyleLineDashSet:{t:"VlLs",v:[]},strokeStyleBlendMode:{t:"enum",v:{BlnM:"Nrml"}},strokeStyleOpacity:{t:"UntF",v:{type:"#Prc",val:100}},strokeStyleContent:{t:"Objc",v:JSON.parse("{\"classID\":\"solidColorLayer\","+at._V.MB+"}")},strokeStyleResolution:{t:"doub",v:72}}};
at.Iz=[{classID:"null",Clr:JSON.parse(at.UR[5]).Clr},{classID:"null",Grad:JSON.parse(at.UR[6]).Grad,Dthr:{t:"bool",v:!1},Rvrs:{t:"bool",v:!1},Angl:{t:"UntF",v:{type:"#Ang",val:0}},Type:{t:"enum",v:{GrdT:"Lnr"}},Algn:{t:"bool",v:!0},Scl:{t:"UntF",v:{type:"#Prc",val:100}},Ofst:{t:"Objc",v:{classID:"Pnt",Hrzn:{t:"UntF",v:{type:"#Prc",val:0}},Vrtc:{t:"UntF",v:{type:"#Prc",val:0}}}}},{classID:"null",Ptrn:JSON.parse(at.UR[7]).Ptrn,Algn:{v:!0,t:"bool"},Scl:{v:{type:"#Prc",val:100},t:"UntF"},Angl:{v:{type:"#Ang",val:0},t:"UntF"},phase:{v:{classID:"Pnt",Hrzn:{v:0,t:"doub"},Vrtc:{v:0,t:"doub"}},t:"Objc"}}];
var ge={};ge.mw=function(w,n){function W(w,k){if(w==null||!w.masterFXSwitch.v)return null;var $=w[k].v,C;
if($.length!=0){C=$[0].v;if(!C.enab.v)C=null}return C}var D=n.SoCo,j=n.GdFl,I=W(w,"solidFillMulti"),U=W(w,"gradientFillMulti");
if(I==null&&U==null)return[D,j];var M=ge.agH;if(D&&I&&U==null){var m=JSON.parse(JSON.stringify(D));m.Clr.v=M(I.Clr.v,D.Clr.v,I);
return[m,null]}if(j&&I&&U==null){var l=JSON.parse(JSON.stringify(j)),A=l.Grad.v.Clrs.v;for(var L=0;L<A.length;
L++){var g=A[L].v.Clr;g.v=M(I.Clr.v,g.v,I)}return[null,l]}if(D&&U){var l=JSON.parse(JSON.stringify(U)),A=l.Grad.v.Clrs.v;
for(var L=0;L<A.length;L++){var g=A[L].v.Clr;g.v=M(g.v,D.Clr.v,U)}return[null,l]}return[I,U]};ge.bE={cu:E.Q(4),fh:E.Q(4),o:new iB(0,0,1,1)};
ge.agH=function(w,n,W){var D=dD.XK(W.Md.v.BlnM),j=W.Opct.v.val/100,I=ge.bE;w=E.M.y_(w);n=E.M.y_(n);I.cu[0]=w.o;
I.cu[1]=w.B;I.cu[2]=w.k;I.cu[3]=255;I.fh[0]=n.o;I.fh[1]=n.B;I.fh[2]=n.k;I.fh[3]=255;E.s._U(D,I.cu,I.o,I.fh,I.o,I.o,j);
return{classID:"RGBC",Rd:{t:"doub",v:I.fh[0]},Grn:{t:"doub",v:I.fh[1]},Bl:{t:"doub",v:I.fh[2]}}};ge.a2b=function(w,n,W){var D=w;
w=w.slice(0);var j=dD.mS[dD.ik.indexOf(n.Md.v.BlnM)],I=E.M.y_(n.Clr.v),U=4278190080|Math.round(I.k)<<16|Math.round(I.B)<<8|Math.round(I.o),M=E.Q(W.O()*4);
E.cJ(M,U);E.s._U(j,M,W,w,W,W,n.Opct.v.val/100);for(var L=0;L<w.length;L+=4)w[L+3]=D[L+3];return w};ge.Sq=function(w,n){var W=["Sz","blur","Sftn","Dstn"];
for(var L=0;L<at.order.length;L++){var D=at.order[L],j=w[at.Pa[L]].v;for(var I=0;I<j.length;I++){var U=j[I].v;
for(var M=0;M<W.length;M++){var m=U[W[M]];if(m){var l=m.v.val,A=l;A=Math.max(l==0?0:1,A*n);if(D=="ChFX")A=Math.min(A,250);
if(D=="ebbl"){if(W[M]=="blur")A=Math.min(A,250);if(W[M]=="Sftn")A=Math.min(A,16)}m.v.val=Math.round(A)}}if(D=="ebbl"||D=="patternFill"||D=="FrFX")if(U.Ptrn&&U.Scl)U.Scl.v.val=Math.max(1,Math.min(1e3,U.Scl.v.val*n))}}};
ge.a3w=function(w,n,W){var D=new iB(-.5,-.5,1,1);for(var L=0;L<at.order.length;L++){var j=at.order[L],I=w[at.Pa[L]].v;
for(var U=0;U<I.length;U++){var M=I[U].v,g;if(!M.enab.v)continue;var m=M.blur?M.blur.v.val+1:0,l=M.Ckmt?M.Ckmt.v.val/100:0,A=Math.round(m*l);
if(j=="DrSh"||j=="IrSh"&&W){g=new iB(-.5,-.5,1,1);g.VD(m,m);ge.BL(g,M,n,0)}if(j=="OrGl"||j=="IrGl"&&W){g=new iB(-.5,-.5,1,1);
g.VD(m,m)}if(j=="FrFX"){var k=ge.i7(M),$=k[1];if(W)$=Math.max(k[0],$);g=new iB(-.5,-.5,1,1);g.VD(Math.ceil($),Math.ceil($))}if(j=="ebbl"){var m=M.blur.v.val,C=M.bvlS.v.BESl;
if(C=="Embs"||C=="PlEb")m/=2;var f=["OtrB","InrB","Embs","PlEb","strokeEmboss"],z=["SfBL","PrBL","Slmt"],s=["In","Out"],O=M.bvlT.v.bvlT!="SfBL"?m:m*.43,a=Math.round(m);
g=new iB(-a-1,-a-1,2*a+2,2*a+2)}if(W&&j=="ChFX"){g=new iB(-.5,-.5,1,1);g.VD(m,m);var X=g.clone();ge.BL(g,M,n,0);
ge.BL(X,M,n,Math.PI);g=g.x0(X)}if(g)D=D.x0(g)}}if(D.x!=Math.ceil(D.x)){D.x=Math.ceil(D.x);D.m-=1}if(D.y!=Math.ceil(D.y)){D.y=Math.ceil(D.y);
D.n-=1}D.m=Math.floor(D.m);D.n=Math.floor(D.n);return D};ge.i7=function(w){var n=0,W=0,D=w.Styl.v.FStl,j=w.Sz.v.val;
if(D=="OutF")W=j;if(D=="InsF")n=j;if(D=="CtrF")n=W=j/2;return[n,W]};ge.a33=function(w){if(je.YG&&w.cl==null){w.cl=new je.H0(w.aA.m,w.aA.n);
w.cl.set(w.Q0);delete w.Q0;if(w.bU){w._P=new je.dt(w.aA.m,w.aA.n);w._P.set(w.bU);delete w.bU}if(w.fO){w.xF=new je.dt(w.aA.m,w.aA.n);
w.xF.set(w.fO);delete w.fO}}};ge.amX=function(w){if(w.cl)w.cl.delete();if(w._P)w._P.delete();if(w.xF)w.xF.delete()};
ge.a9o=function(w){if(w.all==null)return;for(var L=0;L<w.all.length;L++){ge.amX(w.all[L])}};ge.a1k=function(w,n,W,D,j,I){var U=ge.og(W,D,w,n,j,I);
for(var L=0;L<U.all.length;L++)ge.a33(U.all[L]);return U};ge.arR=function(w){for(var L=0;L<at.order.length;
L++){var n=at.order[L],W=at.Pa[L],D=w[W].v;for(var j=0;j<D.length;j++){var I=D[j].v;if(I.enab.v&&["patternFill","GrFl","SoFi"].indexOf(n)==-1)return!0}}return!1};
ge.og=function(w,n,W,D,j,I){if(I==null)I=D;var U=0,M=0;for(var L=0;L<at.order.length;L++){var m=at.order[L],l=at.Pa[L],A=w[l].v;
for(var g=0;g<A.length;g++){var k=A[g].v;if(m=="DrSh"&&k.enab.v&&k.Ckmt.v.val>0&&k.blur.v.val>0)U=Math.max(U,Math.ceil(k.Ckmt.v.val*k.blur.v.val/100));
if(m=="OrGl"&&k.enab.v&&k.Ckmt.v.val>0&&k.blur.v.val>0&&k.GlwT.v.BETE=="SfBL")U=Math.max(U,Math.ceil(k.Ckmt.v.val*k.blur.v.val/100));
if(m=="OrGl"&&k.enab.v&&k.blur.v.val>0&&k.GlwT.v.BETE=="PrBL")U=Math.max(U,k.blur.v.val);if(m=="FrFX"&&k.enab.v&&k.Sz.v.val>0){if(k.Styl.v.FStl=="OutF")U=Math.max(U,k.Sz.v.val);
if(k.Styl.v.FStl=="CtrF")U=Math.max(U,Math.ceil(k.Sz.v.val/2));M=Math.max(M,ge.i7(k)[1])}}}var $=new ge.LO(W,D,U,ge.arR(w)),C=-D.x,f=-D.y,z={type:{},all:[]};
for(var s=0;s<at.order.length;s++){var m=at.order[s],l=at.Pa[s];z.type[m]=[];for(var O=w[l].v.length-1;
O>=0;O--){var a=w[l].v[O].v,Y;if(!a.enab.v)continue;var X=a.blur?a.blur.v.val:0,P=a.Ckmt?a.Ckmt.v.val/100:0,Z=X*P;
if(m=="DrSh"){var K=$.KX(Z,X-Z,!0),S=K.w3,G=K.WH.clone();ge.m0(S,a,!1);if(a.Cntn&&a.Cntn.v){var V=new iB;
ge.BL(V,a,j,0);var T=G.clone();T.offset(-V.x,-V.y);T=T.x0(G);var R=E.Q(T.O());E.B0(S,G,R,T);var x=Math.sqrt(V.x*V.x+V.y*V.y),v=S.slice(0);
for(var L=0;L<x-1;L++){var N=Math.round(-V.x*L/x),u=Math.round(-V.y*L/x),H=K.WH.clone();H.offset(N,u);
E.aua(v,H,R,T)}S=R;G=T}G.offset(C,f);ge.BL(G,a,j,0);var F=E.Q(G.O()*4);ge.Cw(F,a.Clr.v);E.IL(S,F,3);
Y={Q0:F,aA:G,aex:a.layerConceals.v}}else if(m=="IrSh"){var K=$.KX(Z,X-Z,!1);ge.BL(K.WH,a,j,0);var G=$.rect().clone(),S=E.Q(G.O());
S.fill(255);E.B0(K.w3,K.WH,S,G);ge.m0(S,a,!0,!0);var F=E.Q(G.O()*4);ge.Cw(F,a.Clr.v);E.IL(S,F,3);G.offset(C,f);
Y={Q0:F,aA:G}}else if(m=="GrFl"){var F=E.Q($.rect().O()*4);ge.zH(a,F,$.rect(),j,null,I);var G=$.rect().clone();
G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="SoFi"){var F=E.Q($.w3().length*4);ge.Cw(F,a.Clr.v);var G=$.rect().clone();
G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="ebbl"){var t=!1;if(t)console.log(a);var o=Date.now(),q=a.bvlS.v.BESl;
if(q=="strokeEmboss"){var _=w.frameFXMulti.v;if(_.length==0)continue;_=_[0].v;if(!_.enab.v)continue;
var d=_.Styl.v.FStl;if(d=="OutF")q="OtrB";if(d=="CtrF")q="Embs";if(d=="InsF")q="InrB"}var X=a.blur.v.val;
if(X==0)X=.7;if(q=="Embs"||q=="PlEb")X/=2;var r=["OtrB","InrB","Embs","PlEb","strokeEmboss"],p=["SfBL","PrBL","Slmt"],Q=["In","Out"],B=a.bvlT.v.bvlT!="SfBL"?X:X*.45,i=Math.round(X),c=$.rect().clone(),h2=c.clone();
h2.VD(i,i);var jX=h2.m,bm=h2.n,dC=jX*bm,fn=E.Q(dC);E.B0($.w3(),c,fn,h2);var fK=new Float64Array(dC),i6=new Float64Array(dC);
E.style.Wf(fn,fK,jX,bm);E.Ba(fn);E.style.Wf(fn,i6,jX,bm);if(t)console.log("distTransform computed",Date.now()-o);
for(var L=0;L<dC;L++)i6[L]=i6[L]-fK[L];for(var L=0;L<dC;L++){var dh=i6[L];if(dh<-B)i6[L]=-B;else if(dh>B)i6[L]=B}if(t)console.log("summing + cropping",Date.now()-o);
if(a.bvlT.v.bvlT=="SfBL"){var kA=Math.pow(X*.21,1.22);if(!0)kA=Math.max(kA,2);var ig=E.xX.gS(kA,2);E.xX.xn(i6,fK,h2,ig[0]>>>1);
E.xX.xn(fK,i6,h2,ig[1]>>>1)}if(t)console.log("blurring",Date.now()-o);var iJ=i6,fL=iJ.slice(0);if(a.useShape.v){var fB=Math.min(100,a.Inpr.v.val+1)/100;
if(q!="OtrB"&&q!="InrB")fB=1;var ah=E.MU.I5(a.MpgS.v.Crv.v,2e3),eS=Math.round(2e3/fB);ah=E.MU.anS(ah,eS,q=="InrB");
var gL=.5/B;for(var L=0;L<dC;L++){var e_=iJ[L],c2=.99999*(e_+B)*gL;iJ[L]=-B+2*B*ah[~~(c2*(eS-1))]}if(t)console.log("applying shape",Date.now()-o)}if(a.useTexture.v){var jS=E.Q(jX*bm*4);
ge.GP(a,jS,h2,j.add.Patt,n);var ie=E.Q(jX*bm);E.fo(jS,ie);var as=E.Q(jX*bm);E.xX.KA(ie,as,h2,1);ie=as;
var gb=X*a.textureDepth.v.val*(1/100)*(1/255);if(a.InvT.v)gb=-gb;for(var L=0;L<dC;L++)iJ[L]+=-gb*ie[L];
if(t)console.log("applying texture",Date.now()-o)}var gx=(a.bvlT.v.bvlT=="SfBL"?1:.5)*(a.bvlD.v.BESs=="In"?1:-1)*a.srgR.v.val/100;
for(var L=0;L<dC;L++)iJ[L]*=gx;if(t)console.log("scaling",Date.now()-o);var eo=a.uglg&&a.uglg.v?j.d4():a.lagl.v.val;
eo=eo*(Math.PI/180);var di=a.uglg&&a.uglg.v?j.wS():a.Lald.v.val;di=di*(Math.PI/180);var d0=Math.cos(eo)*Math.cos(di),e6=-Math.sin(eo)*Math.cos(di),dt=Math.sin(di),gJ=new Float64Array(dC),iW=new Float64Array(dC),g5=q=="PlEb";
for(var jW=0;jW<bm;jW++)for(var eP=0;eP<jX;eP++){var L=jW*jX+eP,b_=0,fZ=0,im=1;if(jW!=0&&jW!=bm-1&&eP!=0&&eP!=jX-1){var j3=iJ[L-jX-1],dr=iJ[L-jX+1],c0=iJ[L+jX-1],fM=iJ[L+jX+1];
b_=-.125*(dr+2*iJ[L+1]+fM-(j3+2*iJ[L-1]+c0));fZ=-.125*(c0+2*iJ[L+jX]+fM-(j3+2*iJ[L-jX]+dr))}else{var cB=iJ[L];
fZ=-(jW==0?iJ[L+jX]-cB:jW==bm-1?cB-iJ[L-jX]:.5*(iJ[L+jX]-iJ[L-jX]));b_=-(eP==0?iJ[L+1]-cB:eP==jX-1?cB-iJ[L-1]:.5*(iJ[L+1]-iJ[L-1]))}var iI=1/Math.sqrt(b_*b_+fZ*fZ+1);
b_*=iI;fZ*=iI;im*=iI;var jD=b_*d0+fZ*e6+im*dt,j8=jD;if(g5)j8=-b_*d0-fZ*e6+im*dt;if(jD>0)gJ[L]=jD;if(j8>0)iW[L]=j8}if(t)console.log("raycasting",Date.now()-o);
if(a.Sftn.v.val!=0){E.xX.uf(gJ,fK,h2,a.Sftn.v.val*.43);var jG=fK,fK=gJ,gJ=jG;if(g5){E.xX.uf(iW,fK,h2,a.Sftn.v.val*.43);
var jG=fK,fK=iW,iW=jG}else E.nX(gJ,iW)}if(t)console.log("softening",Date.now()-o);var ah=E.MU.I5(a.TrnS.v.Crv.v,1024);
for(var L=0;L<dC;L++){gJ[L]=ah[~~(gJ[L]*1024)];iW[L]=ah[~~(iW[L]*1024)]}if(t)console.log("contour remap",Date.now()-o);
jX=Math.round(jX);bm=Math.round(bm);var i1=E.Q(jX*bm*4);ge.Cw(i1,a.hglC.v);var bH=E.Q(jX*bm*4);ge.Cw(bH,a.sdwC.v);
var a_=E.Q(jX*bm*4);ge.Cw(a_,a.hglC.v);var aR=E.Q(jX*bm*4);ge.Cw(aR,a.sdwC.v);var iY=1/dt,gy=1/(1-dt),gL=1/B,gr=new Float64Array(1e3);
for(var L=0;L<1e3;L++)gr[L]=Math.pow(L*.001,.2);for(var jW=0;jW<bm;jW++)for(var eP=0;eP<jX;eP++){var L=jW*jX+eP,fs=4*L+3,dQ=0,ep=0;
dQ=gJ[L];ep=iW[L];var b2=Math.max(0,Math.min(.9999,(fL[L]+B*.993)*gL));b2=gr[Math.floor(b2*1e3)];var eX=b2*(1-Math.min(1,dQ*iY)),iz=b2*(1-Math.min(1,(1-dQ)*gy)),en=b2*(1-Math.min(1,ep*iY)),ko=b2*(1-Math.min(1,(1-ep)*gy));
bH[fs]=Math.round(255*eX);i1[fs]=Math.round(255*iz);aR[fs]=Math.round(255*en);a_[fs]=Math.round(255*ko)}if(t)console.log("baking textures",Date.now()-o);
h2=$.rect().clone();h2.VD(i,i);h2.offset(C,f);Y={as_:a.bvlS.v.BESl=="strokeEmboss"};var fh=dD.XK(a.hglM.v.BlnM),d1=a.hglO.v.val/100,j_=dD.XK(a.sdwM.v.BlnM),h9=a.sdwO.v.val/100;
if(["InrB","Embs","PlEb"].indexOf(q)!=-1){Y.WY={Q0:i1,aA:h2,ZA:fh,K8:d1};Y.T4={Q0:bH,aA:h2,ZA:j_,K8:h9}}if(["OtrB","Embs","PlEb"].indexOf(q)!=-1){Y.ql={Q0:a_,aA:h2,ZA:fh,K8:d1};
Y.TV={Q0:aR,aA:h2,ZA:j_,K8:h9}}if(t)console.log(Date.now()-o)}else if(m=="patternFill"){var ha=$.rect(),F=E.Q(ha.O()*4);
ge.GP(a,F,ha,j.add.Patt,n);var G=ha.clone();G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="ChFX"){var F=E.Q($.w3().length*4);
ge.Cw(F,a.Clr.v);var X=a.blur.v.val,fl=$.rect().clone();fl.VD(X,X);var ex=E.Q(fl.O()),aI=E.Q(fl.O());
E.B0($.w3(),$.rect(),aI,fl);E.xX.So(aI,ex,fl,X*.43);var ba=E.MU.ou(a.MpgS.v.Crv.v,256,!0);E.Ni(ex,ba);
var ik=E.Q($.w3().length),c3=E.Q($.w3().length),br=$.rect().clone();ge.BL(br,a,j,0);E.B0(ex,fl,ik,br);
br=$.rect().clone();ge.BL(br,a,j,Math.PI);E.B0(ex,fl,c3,br);var bi=ik.length;for(var L=0;L<bi;L++)F[4*L+3]=Math.abs(ik[L]-c3[L]);
if(a.Invr.v)for(var L=0;L<bi;L++)F[4*L+3]=255-F[4*L+3];var G=$.rect().clone();G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="OrGl"){var K;
if(a.GlwT.v.BETE=="SfBL")K=$.KX(Z,X-Z,!0);else K=$.ayX(X,P,!0);var S=K.w3,G=K.WH,cZ=S.slice(0);ge.a7Z(S,a);
var F=E.Q(G.O()*4);if(a.Grad==null){ge.Cw(F,a.Clr.v);ge.m0(S,a,!1)}else{ge.m0(S,a,null);var ib={PH:S,rW:255,xR:0,gl:G};
ge.zH(a,F,G,j,ib);var hb=a.Nose.v.val/100,kg=G.m;for(var L=0;L<cZ.length;L++){var kh=255,ct=cZ[L];if(ct<32){var cy=(ct+cZ[L-1]+cZ[L+1]+cZ[L-kg]+cZ[L+kg])*.2-1;
kh=Math.min(255,Math.round(Math.max(0,cy)*8))}S[L]=kh}ge.a3J(S,a)}E.IL(S,F,3);G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="IrGl"){var K;
if(a.GlwT.v.BETE=="SfBL")K=$.KX(Z,X-Z,!1);else K=$.ayX(X,P,!1);var S=K.w3,G=K.WH;ge.a7Z(S,a);if(a.glwS.v.IGSr=="SrcC")E.Ba(S);
var F=E.Q(G.O()*4);if(a.Grad==null){ge.Cw(F,a.Clr.v);ge.m0(S,a,!0)}else{ge.m0(S,a,null);var ib={PH:S,rW:255,xR:0,gl:G};
ge.zH(a,F,G,j,ib);S.fill(255);ge.a3J(S,a)}E.IL(S,F,3);G.offset(C,f);Y={Q0:F,aA:G}}else if(m=="FrFX"){var hA=ge.i7(a),iO=hA[0],fj=hA[1],G=$.rect().clone(),io=null,fX=null;
G.VD(Math.ceil(M),Math.ceil(M));if(fj>0){var K=$.KX(fj,0,!0);fX=K.w3;if(fX.length<G.O()){fX=E.Q(G.O());
E.B0(K.w3,K.WH,fX,G)}}if(iO>0){var K=$.KX(iO,0,!1);io=E.Q(G.O());io.fill(255);E.B0(K.w3,K.WH,io,G)}G.offset(C,f);
var F=E.Q(G.O()*4),a0=a.PntT.v.FrFl;if(a0=="SClr")ge.Cw(F,a.Clr.v);if(a0=="GrFl")ge.zH(a,F,G,j,$.ahV(iO,fj));
if(a0=="Ptrn")ge.GP(a,F,G,j.add.Patt,n);Y={Q0:F,aA:G,fO:fX,bU:io}}z.type[m].push(Y);if(m=="ebbl"){if(Y.WY)z.all.push(Y.WY,Y.T4);
if(Y.ql)z.all.push(Y.ql,Y.TV)}else{Y.ZA=dD.XK(a.Md.v.BlnM);Y.K8=a.Opct.v.val/100,z.all.push(Y)}}}return z};
ge.Hx=function(w){var n=1/Math.sqrt(w.x*w.x+w.y*w.y+w.YD*w.YD);w.x*=n;w.y*=n;w.YD*=n};ge.acH=function(w,n){return{x:w.y*n.YD-w.YD*n.y,y:w.YD*n.x-w.x*n.YD,YD:w.x*n.y-w.y*n.x}};
ge.aj2=function(w,n){return w.x*n.x+w.y*n.y+w.YD*n.YD};ge.a3J=function(w,n){var W=n.Nose.v.val/100;if(W>0)for(var L=0;
L<w.length;L++){var D=w[L];D=Math.min(510-(1+W)*E.style.lr(L),D);w[L]=D}};ge.qB=function(w){var n=ge.cT(),W=w.kQ,D=!1;
for(var L=0;L<32;L+=8)if(W[L]+W[L+1]+W[L+4]+W[L+5]!=0||W[L+2]+W[L+3]+W[L+6]+W[L+7]!=1020)D=!0;if(D){W=W.slice(0);
for(var L=0;L<40;L+=4){var j=W[L]/255,I=W[L+1]/255,U=W[L+2]/255,M=W[L+3]/255;W[L]=j-.001;W[L+1]=j==I?1e6:1/(I-j);
W[L+2]=U==M?-1e6:1/(U-M);W[L+3]=M+.001}}var m=w.add.iOpa!=null?w.add.iOpa/255:n.fill,l=w.add.vstk;if(l&&!l.fillEnabled.v&&(!l.strokeEnabled.v||l.strokeStyleLineWidth.v.val==0))m=0;
return{fill:m,vn:D?W:null,e6:w.add.brst!=null?w.add.brst:n.e6,a31:w.add.knko!=null?w.add.knko:n.a31,style:!1,MY:!1}};
ge.cT=function(){return{fill:1,vn:null,e6:[1,1,1],a31:0,style:!1,MY:!1}};ge.aeQ=function(w,n,W,D,j,I,U,M){if(M==null)M=1;
if(U==null)U=new eh;var m=w.HY[1].m,l=w.HY[1].n,A=new eh,g=j<2;if(g)A.translate(-m/2,-l/2);if(j==0){M*=Math.max(W/m,D/l)}else if(j==1){M*=Math.min(W/m,D/l)}else if(j==2){A.scale(1/m,1/l);
A.concat(U);A.scale(W,D)}else if(j==3){M=M}A.scale(M,M);if(g)A.translate(W/2,D/2);A.concat(I);n.Ptrn.v.Idnt.v=w.id;
n.Scl.v.val=Math.round(100*A.NW());n.Angl.v.val=Math.round(180*Math.atan2(-A.k,A.dl)/Math.PI);n.Algn.v=!0;
var k=n.phase.v;k.Hrzn.v=Math.round(A.z2);k.Vrtc.v=Math.round(A.EU)};ge.f$=function(w,n){if(n==null)return null;
var W=w.Idnt.v,D=w.Nm.v;for(var L=0;L<n.length;L++)if(n[L].id==W)return n[L];for(var L=0;L<n.length;
L++)if(n[L].name==D)return n[L];return null};ge.axf=function(w,n,W){var D=["patternFillMulti","ebblMulti","frameFXMulti"];
for(var L=0;L<D.length;L++){var j=w.v[D[L]].v;for(var I=0;I<j.length;I++)if(j[I].v.Ptrn)n.qn(ge.f$(j[I].v.Ptrn.v,W))}};
ge.ax9=function(w,n,W){var D=["patternFillMulti","ebblMulti","frameFXMulti"];for(var L=0;L<D.length;
L++){var j=w.v[D[L]].v;for(var I=0;I<j.length;I++)if(j[I].v.Ptrn){var U=j[I].v.Ptrn.v,M=ge.f$(U,W),m=ge.f$(U,n.add.Patt);
if(M==null&&m)W.push(m)}}};ge.GP=function(w,n,W,D,j){var I=ge.f$(w.Ptrn.v,D);if(I!=null&&!W.VY()){var U=I.HY,M=U[0],m=U[1],l=0;
E.L3(U);var A=(w.Scl?w.Scl.v.val:100)/100;while((A<.3||A==.5)&&U[l+2]){A*=m.m/U[l+3].m;l+=2;M=U[l];m=U[l+1]}var g=E.scale.GP(M,m.m,m.n),k=w.phase?w.phase.v:{Hrzn:{v:0},Vrtc:{v:0}},$=w.Angl?w.Angl.v.val:0,C=-W.x+k.Hrzn.v-1,f=-W.y+k.Vrtc.v-1;
if(w.Algn!=null&&!w.Algn.v){}else{C+=j.x;f+=j.y}if(n)E.scale.a2D(g,n,W.m,W.n,A,A,C+1,f+1,$*Math.PI/180);
else return[g,A,C+1,f+1,$*Math.PI/180]}};ge.zH=function(w,n,W,D,j,I){if(I==null)I=W;var U=w.Type?w.Type.v.GrdT:"shapeburst",M=w.Algn&&w.Algn.v?I:new iB(0,0,D.m,D.n),m=w.Angl?E.M.Du(w,M):[new ec(0,0),new ec(100,0)],l=m[0].x,A=m[0].y,g=m[1].x-l,k=m[1].y-A,$=Math.sqrt(g*g+k*k);
$=1/(2*$*$);var C=[g*$,k*$,-k*$,g*$],f=w.Rvrs?w.Rvrs.v:!1,z=w.Dthr?w.Dthr.v:!1;E.M.Yd(w.Grad.v,n,W,C,l,A,f,at.M.types.indexOf(U),0,0,j,z)};
ge.afy=function(w,n,W){for(var L=0;L<w.all.length;L++){var D=w.all[L];D.TM=D.aA.clone();D.TM.offset(n,W)}};
ge.a3o=function(w,n,W,D,j,I){var U=je.YG?ge.a6t:ge.aoT;ge.afy(n,W.x,W.y);var M=n.type.DrSh;for(var L=0;
L<M.length;L++)if(!M[L].aex)U(M[L],D,j,I)};ge.axB=function(w,n,W,D,j,I,U,M,m,l){var A=W,g=je.YG?ge.a6t:ge.aoT,k=je.YG?je.s.mT:E.s.eY,$;
$=n.type.DrSh;for(var L=0;L<$.length;L++)if($[L].aex)g($[L],D,j,I);$=n.type.OrGl;for(var L=0;L<$.length;
L++)g($[L],D,j,I);var C="patternFill GrFl SoFi ChFX IrGl IrSh".split(" ");for(var f=0;f<C.length;f++){var $=n.type[C[f]];
for(var L=0;L<$.length;L++)g($[L],U,A,I)}var z=n.type.ebbl[0],s=z!=null&&z.as_;$=n.type.FrFX;for(var L=0;
L<$.length;L++){var O=$[L];jo.Eg.B0(M,l,m,l,I);g(O,m,l,I);if(s&&L==$.length-1){if(z.TV)g(z.TV,m,l,I);
if(z.ql)g(z.ql,m,l,I);if(z.T4)g(z.T4,m,l,I);if(z.WY)g(z.WY,m,l,I)}if(O.bU||O._P)k(m,l,U,A,je.YG?O._P:O.bU,O.TM,0,I,1);
if(O.fO||O.xF)k(m,l,D,j,je.YG?O.xF:O.fO,O.TM,0,I,1)}if(!s&&z!=null){if(z.TV)g(z.TV,D,j,I);if(z.ql)g(z.ql,D,j,I);
if(z.T4)g(z.T4,U,A,I);if(z.WY)g(z.WY,U,A,I)}};ge.aoT=function(w,n,W,D){var j=ge.cT();j.fill=w.K8;j.style=!0;
E.s._U(w.ZA,w.Q0,w.TM,n,W,D,1,j)};ge.a6t=function(w,n,W,D){var j=ge.cT();j.fill=w.K8;j.style=!0;je.s.Q7(w.ZA,w.cl,w.TM,n,W,D,1,j)};
ge.a7Z=function(w,n){var W=1-n.Inpr.v.val/100,D=1+Math.tan(W*(Math.PI/2)),j=w.length;for(var L=0;L<j;
L++)w[L]=Math.min(255,Math.round(w[L]*D))};ge.m0=function(w,n,W,D){var j=n.blur.v.val,I=Math.round(j*(n.Ckmt.v.val/100));
if(j>I){var U=E.MU.ou(n.TrnS.v.Crv.v,256,D!=!0);E.Ni(w,U)}if(W!=null&&n.Nose.v.val>0)E.style.Mq(w,n.Nose.v.val/100,W)};
ge.Cw=function(w,n,W){if(W==null)W=255;var D=E.M.y_(n),j=W<<24|D.k<<16|D.B<<8|D.o,I=new Uint32Array(w.buffer);
I.fill(j)};ge.BL=function(w,n,W,D){var j=n.uglg&&n.uglg.v?W.d4():n.lagl.v.val;j=j*Math.PI/180+D;var I=Math.cos(j)*n.Dstn.v.val,U=Math.sin(j)*n.Dstn.v.val;
w.x-=Math.round(I);w.y+=Math.round(U)};ge.Qk=function(w){if(w==null)return null;var n=w.frameFXMulti.v;
if(n.length==0)return null;n=n[0].v;var W=JSON.parse(JSON.stringify(at.QO.default));ge.a9C(n,W);return W};
ge.a9C=function(w,n){var W=at.stroke.iX.indexOf(w.PntT.v.FrFl),D=[at.Oa,at.Ki,at.v7][W],j=n.strokeStyleContent.v={classID:at.QO.W_[W]};
for(var L=0;L<D.length;L++)j[D[L]]=w[D[L]];n.strokeEnabled=w.enab;n.strokeStyleLineWidth=w.Sz;n.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[at.stroke.types.indexOf(w.Styl.v.FStl)];
n.strokeStyleOpacity=w.Opct;n.strokeStyleBlendMode=w.Md;n.strokeStyleLineJoinType.v.strokeStyleLineJoinType="strokeStyleRoundJoin"};
ge.zW=function(w,n){var W=[];for(var L=0;L<w.length;L++)W.push({t:"UntF",v:{type:"#Nne",val:Math.round(w[L]*n)}});
return W};ge.anc=function(w,n){var W=w.opacity/255*(w.add.iOpa?w.add.iOpa/255:1),D=w.add.TySh,j=w.ue()||w.I9()&&w.add.vmsk&&w.add.vstk.fillEnabled.v&&w.add.vstk.strokeEnabled.v;
if(D){var I=D._o.EngineDict.StyleRun.RunArray,U=I[0].StyleSheet.StyleSheetData,M=0;if(U.FillFlag)M++;
if(U.StrokeFlag)M++;if(U._FillBackgroundFlag)M++;if(M>1)j=!0}return j&&(n||W!=1||w.Bx!="pass"&&w.Bx!="norm")};
ge.LO=function(w,n,W,D){this.cE=n.clone();this.amf=n.clone();this.amf.VD(W,W);if(D){this.cE.VD(1,1);
this.sf=E.Q(this.cE.O());E.B0(w,n,this.sf,this.cE)}else this.sf=w;this.g9=null;this.rV=null;this.kx=null};
ge.LO.prototype.w3=function(){return this.sf};ge.LO.prototype.rect=function(){return this.cE};ge.LO.prototype.WG=function(){return this.amf};
ge.LO.prototype.iZ=function(){if(this.g9)return this.g9;this.g9=this.w3().slice(0);E.Ba(this.g9);return this.g9};
ge.LO.prototype.Tw=function(){if(this.rV)return this.rV;this.rV=new Float64Array(this.rect().O());E.style.Wf(this.iZ(),this.rV,this.rect().m,this.rect().n);
return this.rV};ge.LO.prototype.hE=function(){if(this.kx)return this.kx;var w=this.WG(),n=E.Q(w.O());
E.B0(this.w3(),this.rect(),n,w);this.kx=new Float64Array(w.O());E.style.Wf(n,this.kx,w.m,w.n);return this.kx};
ge.LO.prototype.ahV=function(w,n){var W={rW:-n,xR:w,gl:null,PH:null};if(n==0){W.gl=this.rect();W.PH=this.Tw();
return W}var D=this.hE().slice(0),j=this.WG();W.gl=j;W.PH=D;for(var L=0;L<D.length;L++)D[L]=-D[L];if(w==0)return W;
var I=this.Tw(),U=this.rect();for(var M=0;M<U.n;M++)for(var m=0;m<U.m;m++){var l=M*U.m+m,A=(M+U.y-j.y)*j.m+m+U.x-j.x;
D[A]+=I[l]}return W};ge.LO.prototype.KX=function(w,n,W){var D=Math.ceil(w+n),j={WH:this.rect().clone(),w3:null};
j.WH.VD(D,D);j.w3=E.Q(j.WH.O());if(w==0&&n==0)E.nX(W?this.w3():this.iZ(),j.w3);else{var I=E.Q(j.WH.O());
E.B0(this.w3(),this.rect(),I,j.WH);if(!W)E.Ba(I);if(w!=0){if(W)E.style.aX(I,j.WH,this.hE(),this.WG(),w);
else E.style.aX(I,j.WH,this.Tw(),this.rect(),w)}if(n!=0)E.xX.So(I,j.w3,j.WH,Math.max(1,n*.43));else j.w3=I}return j};
ge.LO.prototype.ayX=function(w,n,W){var D=w*(n-.5),j={WH:this.rect().clone(),w3:null};if(W)j.WH.VD(w,w);
j.w3=E.Q(j.WH.O());var I=j.WH.m,U=j.WH.n,M=W?this.hE():this.Tw(),m=W?this.WG():this.rect(),l=j.WH,A=l.wU(m),I=A.m,U=A.n,g=A.x-l.x,k=A.y-l.y,$=A.x-m.x,C=A.y-m.y,f=1-n*2;
for(var z=0;z<U;z++)for(var s=0;s<I;s++){var O=M[(z+C)*m.m+s+$],a=O/w;j.w3[(z+k)*l.m+s+g]=Math.max(0,Math.min(255,255-255*((a+f)/(1+f))))}return j};
ge.acF=function(w,n,W,D){var j=w.Lefx,I=w.blendOptions;if(j){var U=n.add.lmfx;if(W==null)W=U?U.Scl.v.val:100;
n.add.lmfx=JSON.parse(JSON.stringify(j.v));if(n.add.lmfx.Scl==null)n.add.lmfx.Scl={t:"UntF",v:{type:"#Prc",val:100}};
ge.Sq(n.add.lmfx,W/n.add.lmfx.Scl.v.val);if(U)n.add.lmfx.Scl.v.val=U.Scl.v.val;var M=j.v.gagl;if(M&&D)D.UB(M.v.val)}else delete n.add.lmfx;
if(I){I=I.v;if(I.Md)n.Bx=dD.XK(I.Md.v.BlnM);if(I.Opct)n.opacity=Math.round(I.Opct.v.val*255/100);if(I.fillOpacity)n.add.iOpa=Math.round(I.fillOpacity.v.val*255/100);
if(I.Blnd){var m=[];for(var L=0;L<10;L++)m.push(0,0,255,255);var l=I.Blnd.v,A="SrcB Srcl SrcW Srcm DstB Dstl DstW Dstt".split(" ");
for(var L=0;L<l.length;L++){var g=l[L].v,k=8*["Gry","Rd","Grn","Bl"].indexOf(g.Chnl.v[0].v.enum);for(var $=0;
$<8;$++){m[k+$]=g[A[$]].v}}n.kQ=m}}};ge.a6C=function(w){var n="SrcB Srcl SrcW Srcm DstB Dstl DstW Dstt".split(" "),W=[],D=w.kQ;
for(var L=0;L<4;L++){var j=L*8;if(D[j]+D[j+1]+D[j+4]+D[j+5]==0&&D[j+2]+D[j+3]+D[j+6]+D[j+7]==4*255)continue;
var I={t:"Objc",v:{classID:"Blnd",Chnl:{t:"obj ",v:[{t:"Enmr",v:{classID:"Chnl",typeID:"Chnl",enum:["Gry","Rd","Grn","Bl"][L]}}]}}};
W.push(I);for(var U=0;U<8;U++)I.v[n[U]]={t:"long",v:D[L*8+U]}}var M={classID:"blendOptions"};if(w.Bx!="norm")M.Md={t:"enum",v:{BlnM:dD.Eu(w.Bx)}};
if(w.opacity!=255)M.Opct={t:"UntF",v:{type:"#Prc",val:Math.round(w.opacity*100/255)}};if(w.add.iOpa!=null)M.fillOpacity={t:"UntF",v:{type:"#Prc",val:Math.round(w.add.iOpa*100/255)}};
if(W.length!=0)M.Blnd={t:"VlLs",v:W};var m={UU:{classID:"null",Idnt:{t:"TEXT",v:kc.Fa()+"-bd9f-11d5-b8ba-b73f8571793d"},Nm:{t:"TEXT",v:"Custom Style"}},nK:{classID:"Styl",blendOptions:{t:"Objc",v:M}}},l=w.add.lmfx;
if(l)m.nK.Lefx={t:"Objc",v:l};return m};function bj(){}bj.iJ=function(w){return JSON.parse(JSON.stringify(w))};
bj.os=function(w){var n=bj.iJ(bj.axg),W=n.Brsh.v;if(w!=null){delete W.Hrdn;W.classID="sampledBrush";
W.Nm={t:"TEXT",v:"layer.png"},W.sampledData={t:"TEXT",v:w}}return n};bj.axg={classID:"brushPreset",Nm:{t:"TEXT",v:"Custom Brush"},Brsh:{t:"Objc",v:{classID:"computedBrush",Dmtr:{t:"UntF",v:{type:"#Pxl",val:15}},Hrdn:{t:"UntF",v:{type:"#Prc",val:100}},Angl:{t:"UntF",v:{type:"#Ang",val:0}},Rndn:{t:"UntF",v:{type:"#Prc",val:100}},Spcn:{t:"UntF",v:{type:"#Prc",val:25}},Intr:{t:"bool",v:!0},flipX:{t:"bool",v:!1},flipY:{t:"bool",v:!1}}},useTipDynamics:{t:"bool",v:!1},useScatter:{t:"bool",v:!1},dualBrush:{t:"Objc",v:{classID:"dualBrush",useDualBrush:{t:"bool",v:!1}}},brushGroup:{t:"Objc",v:{classID:"brushGroup",useBrushGroup:{t:"bool",v:!1}}},useTexture:{t:"bool",v:!1},usePaintDynamics:{t:"bool",v:!1},useColorDynamics:{t:"bool",v:!1},Wtdg:{t:"bool",v:!1},Nose:{t:"bool",v:!1},Rpt:{t:"bool",v:!1}};
bj.Hx={};bj.Hx.check=function(w){var n=bj.Hx.Tp;for(var L=0;L<n.length;L++)if(w[n[L]]==null)w[n[L]]=JSON.parse(bj.Hx.KK[n[L]]);
var W=[];for(var L=0;L<n.length;L++)W.push(n[L]);var D=bj.Hx.agY;for(var L=0;L<D.length;L++){var j=D[L][0],I=D[L][1],U=!0;
for(var M=0;M<j.length;M++)U=U&&w[j[M]].v==!0;if(U)for(var M=0;M<I.length;M++){if(w[I[M]]==null)console.log("Missing conditional parameter "+I[M]);
else W.push(I[M])}}for(var m in w)if(W.indexOf(m)==-1)console.log("Extra parameter "+m);w=w.Brsh.v;n=bj.Hx.UT.Tp;
for(var L=0;L<n.length;L++)if(w[n[L]]==null)w[n[L]]=JSON.parse(bj.Hx.UT.KK[n[L]]);W=[];for(var L=0;L<n.length;
L++)if(w[n[L]])W.push(n[L]);else console.log("Missing default parameter "+n[L]);D=bj.Hx.UT.alL[w.classID];
for(var L=0;L<D.length;L++)if(w[D[L]]==null&&D[L]!="dtipsGridSize"&&D[L]!="dtipsErodibleTipHeightMap"&&w.afE!=1)console.log("Missing conditional parameter "+D[L]);
else W.push(D[L]);for(var m in w)if(W.indexOf(m)==-1)console.log("Extra parameter "+m)};bj.Hx.amr=function(w){var n=bj.Hx.agY;
for(var L=0;L<n.length;L++){var W=n[L][0],D=n[L][1],j=!0;for(var I=0;I<W.length;I++)j=j&&w[W[I]]&&w[W[I]].v==!0;
if(j){for(var I=0;I<D.length;I++)if(w[D[I]]==null){w[D[I]]=JSON.parse(bj.Hx.KK[D[I]])}}else for(var I=0;
I<D.length;I++)if(w[D[I]]!=null){delete w[D[I]]}}};bj.Hx.UT={};bj.Hx.UT.Tp="classID Dmtr Angl Spcn Intr flipX flipY".split(" ");
bj.Hx.UT.KK={flipX:"{\"t\":\"bool\",\"v\":false}",flipY:"{\"t\":\"bool\",\"v\":false}"};bj.Hx.UT.alL={computedBrush:["Hrdn","Rndn"],sampledBrush:["Nm","Rndn","sampledData"],dBrush:"Shp Dnst Lngt clumping thickness stiffness physics".split(" "),dTips:"dtipsType Shp dtipsLengthRatio dtipsHardness dtipsGridSize dtipsErodibleTipHeightMap physics dtipsAirbrushCutoffAngle dtipsAirbrushGranularity dtipsAirbrushStreakiness dtipsAirbrushSplatSize dtipsAirbrushSplatCount".split(" ")};
bj.Hx.agY=[[["useTipDynamics"],"flipX flipY brushProjection minimumDiameter minimumRoundness tiltScale szVr angleDynamics roundnessDynamics".split(" ")],[["usePaintDynamics"],["prVr","opVr","wtVr","mxVr"]],[["useBrushPose"],"overridePoseAngle overridePoseTiltX overridePoseTiltY overridePosePressure brushPosePressure brushPoseTiltX brushPoseTiltY brushPoseAngle".split(" ")],[["useTexture"],"TxtC interpretation textureBlendMode textureDepth minimumDepth textureDepthDynamics Txtr textureScale InvT textureBrightness textureContrast".split(" ")],[["useColorDynamics"],"clVr H Strt Brgh purity colorDynamicsPerTip".split(" ")],[["useScatter"],["Cnt","countDynamics","bothAxes","scatterDynamics"]],[["useScatter","bothAxes"],["Spcn"]]];
bj.Hx.Tp="classID Nm Brsh useTipDynamics usePaintDynamics useColorDynamics useScatter useTexture useBrushSize useBrushPose Wtdg Nose Rpt dualBrush brushGroup".split(" ");
bj.Hx.KK={useBrushSize:"{\"t\":\"bool\",\"v\":false}",useBrushPose:"{\"t\":\"bool\",\"v\":false}",brushGroup:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brushGroup\",\"useBrushGroup\":{\"t\":\"bool\",\"v\":false}}}",flipX:"{\"t\":\"bool\",\"v\":false}",flipY:"{\"t\":\"bool\",\"v\":false}",brushProjection:"{\"t\":\"bool\",\"v\":false}",minimumDiameter:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}",minimumRoundness:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":25}}",tiltScale:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":200}}",szVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",angleDynamics:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",roundnessDynamics:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",prVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",opVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",wtVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",mxVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",overridePoseAngle:"{\"t\":\"bool\",\"v\":false}",overridePoseTiltX:"{\"t\":\"bool\",\"v\":true}",overridePoseTiltY:"{\"t\":\"bool\",\"v\":true}",overridePosePressure:"{\"t\":\"bool\",\"v\":true}",brushPosePressure:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":9}}",brushPoseTiltX:"{\"t\":\"long\",\"v\":0}",brushPoseTiltY:"{\"t\":\"long\",\"v\":0}",brushPoseAngle:"{\"t\":\"long\",\"v\":0}",TxtC:"{\"t\":\"bool\",\"v\":false}",interpretation:"{\"t\":\"bool\",\"v\":true}",textureBlendMode:"{\"t\":\"enum\",\"v\":{\"BlnM\":\"CBrn\"}}",textureDepth:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":37}}",minimumDepth:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":97}}",textureDepthDynamics:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",Txtr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"Ptrn\",\"Nm\":{\"t\":\"TEXT\",\"v\":\"$$$/Presets/Patterns/Patterns_pat/Laidhorizontal=Laid-horizontal\"},\"Idnt\":{\"t\":\"TEXT\",\"v\":\"52a93427-f5d6-1172-a989-8dc82a43aa51\"}}}",textureScale:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":99}}",InvT:"{\"t\":\"bool\",\"v\":false}",textureBrightness:"{\"t\":\"long\",\"v\":14}",textureContrast:"{\"t\":\"long\",\"v\":100}",Cnt:"{\"t\":\"doub\",\"v\":4}",countDynamics:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":98}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",bothAxes:"{\"t\":\"bool\",\"v\":false}",scatterDynamics:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":56}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",clVr:"{\"t\":\"Objc\",\"v\":{\"classID\":\"brVr\",\"bVTy\":{\"t\":\"long\",\"v\":0},\"fStp\":{\"t\":\"long\",\"v\":100},\"jitter\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}},\"Mnm\":{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}}}",H:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}",Strt:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}",Brgh:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":36}}",purity:"{\"t\":\"UntF\",\"v\":{\"type\":\"#Prc\",\"val\":0}}",colorDynamicsPerTip:"{\"t\":\"bool\",\"v\":false}"};
function h3(w,n){this.abo=w;this.Tg=n==null?0:n;this.dir=0}h3.prototype.db=function(w,n){var W=this.abo,D=new ec(w.x-W.x,w.y-W.y),j=new eh;
j.rotate(-this.Tg);D=j.bj(D);if(this.dir==0&&!W.s9(w))this.dir=Math.abs(D.x)<Math.abs(D.y)?1:2;if(n.U(aK.WO)){if(this.dir==1)D.x=0;
if(this.dir==2)D.y=0}j.Ba();D=j.bj(D);var I=new ec(W.x+D.x,W.y+D.y);return I};h3.prototype.ate=function(w){if(w.U(aK.WO))return this.dir;
return 0};var eJ=function(){function w(){this.akd={}}w.asJ=function(n,W){var D=n.clone();D.z2-=Math.floor(D.z2);
D.EU-=Math.floor(D.EU);var j=new ec(W,0),I=new ec(0,W),U=D.bj(j),M=D.bj(I),m=new ec(D.z2,D.EU);return[U,M,m]};
w.a12=function(n,W){var D=ec.cS;return D(n[0],W[0])+D(n[1],W[1])+D(n[2],W[2]);return dsum};w.prototype.a9P=function(n){var W=this.akd,D=W[n];
if(D==null)D=W[n]={zI:[],Hl:0,O:0,a1L:0,a8R:0};D.Hl=Date.now();while(Object.keys(W).length>3){var j="",I=Date.now();
for(var U in W){var M=W[U].Hl;if(M<I){I=M;j=U}}delete W[j]}return D};w.prototype.akW=function(n,W){var D=n.zI,j,I=1e6;
for(var L=0;L<D.length;L++){var U=D[L],M=w.a12(U.C3,W);if(M<I){j=U;I=M}}return j};w.prototype.ayG=function(n,W){var D=n.zI;
D.push(W);n.O+=W.rect.O();if(D.length>1e3||n.O>100*100*1600){console.log("pruning",n.O,D.length);D.sort(function(I,U){return U.Hl-I.Hl});
while(D.length>500||n.O>100*100*800){var j=D.pop();n.O-=j.rect.O()}}};return w}();function iV(w,n,W,D,j,I,U,M,m){this.yg=n;
this.j6=W;this.as=I;this.HD=D;this.XV=null;this.hV=null;this.vV=0;this.asX=0;this.awt=0;this.NL=0;this.k6=0;
this.Ur=m==null?Math.floor(Math.random()*16777215):m;this.P0=m==null?Math.floor(Math.random()*16777215):m;
this.XL=new iB;this.XZ=new iB;if(M!=null){this.Q0=M}else{var l=iV.anC;if(l.length!=U.O()*4)l=E.Q(U.O()*4);
else l.fill(0);this.Q0=iV.anC=l}this.rect=U.clone();this.ZG=[];this.LF=[];this.Gs=null;this.Gp=0;this.k=null;
this.aa4="";this.jr=null;this.alj(w,j)}iV.anC=E.Q(16);iV.prototype.alj=function(w,n){this.Gp=n;this.k=w;
this.aa4=JSON.stringify(w)+JSON.stringify(this.HD.dE);this.jr=iV.asM(this.k,this.yg,this.j6)};iV.prototype.moveTo=function(w,n,W){W=this.afP(W);
this.vV=W;var D=new ec(w,n),j=this.k.Brsh.v.Dmtr.v.val;this.XV=D.clone();this.hV=D.clone();this.Gs=D.clone();
this.ZG=[w,n];this.LF=[W];if(this.HD.gQ!=iV.mH){var I=this.k.angleDynamics,U=I?I.v.bVTy.v==6:!1;this.Fg(U?new iB:this.aby(D,this.ahD(W),W,new ec(0,0)))}this.NL=D.clone()};
iV.prototype.lineTo=function(w,n,W){W=this.afP(W);var D=this.ZG,j=D.length,I=D[j-2],U=D[j-1];if(w==I&&n==U)return;
var M=this.k.Brsh.v.Dmtr.v.val,m=Math.ceil(M)+1,l=new iB(Math.round(I),Math.round(U),0,0);l.VD(m,m);
var A=new iB(Math.round(w),Math.round(n),0,0);A.VD(m,m);this.ZG.push(w,n);this.LF.push(W);j+=2;if(j>=6)this.Fg(this.a2K(j))};
iV.prototype.afP=function(w){if(w==null)w=1;w=Math.max(.05,Math.min(5,w));if(isNaN(w)){alert("Pressure is not a number");
throw"e"}return w};iV.prototype.Fg=function(w){this.XL=w;this.XZ=this.XZ.x0(w)};iV.prototype.finish=function(){var w=this.ZG,n=w.length,W;
if(n==4)W=this.alH(w[n-2],w[n-1],this.LF[(n>>1)-1],!0);if(n>4)W=this.a2K(n+2);if(W)this.Fg(W)};iV.prototype.pJ=function(){return this.rect.clone()};
iV.prototype.iO=function(){return this.XL.wU(this.rect)};iV.prototype.oi=function(){return this.XZ.wU(this.rect)};
iV.prototype._a=function(){return this.Q0};iV.prototype.a2K=function(w){var n=this.ZG,W=this.LF,D=n[w-6],j=n[w-5],I=n[w-4],U=n[w-3],M=W[(w>>1)-3],m=W[(w>>1)-2],l=new ec(0,0),A=new ec(0,0);
if(8<=w)l=iV.ac_(n[w-8],n[w-7],D,j,I,U);if(w<=n.length)A=iV.ac_(n[w-2],n[w-1],I,U,D,j);var g=D+l.x,k=j+l.y,$=I+A.x,C=U+A.y,f=new iB,z=this.abV()?1:10;
for(var L=0;L<z;L++){var s=(L+1)/z,O=1-s,a=O*O*O*D+3*s*O*O*g+3*s*s*O*$+s*s*s*I,X=O*O*O*j+3*s*O*O*k+3*s*s*O*C+s*s*s*U,P=this.alH(a,X,M+s*(m-M));
f=f.x0(P)}return f};iV.ac_=function(w,n,W,D,j,I){var U=w-W,M=n-D,m=j-W,l=I-D,A=Math.sqrt(U*U+M*M),g=Math.sqrt(m*m+l*l),k=Math.acos((U*m+M*l)/(A*g))/Math.PI,$=.35,C=.1;
k=C+k*($-C);var f=j-w,z=I-n,s=Math.sqrt(f*f+z*z),O=k*g/s;return new ec(f*O,z*O)};iV.prototype.alH=function(w,n,W,D){var j=new iB,I=this.HD.a9m;
if(I==null)I=0;if(I==0||D){j=this.axQ(w,n,W);return j}var U=this.Gs,M=w-U.x,m=n-U.y,l=Math.sqrt(M*M+m*m);
M/=l;m/=l;if(l>I){var A=U.x+M*(l-I),g=U.y+m*(l-I);j=this.axQ(A,g,W);this.Gs.y1(A,g)}return j};iV.prototype.abV=function(){var w=this.k,n=w.Brsh.v.Dmtr.v.val;
return this.HD.dE&&n==1};iV.prototype.axQ=function(w,n,W){var D=new iB,j=new ec(w,n),I=this.HD.gQ,U=j.eu(this.hV);
U.normalize(1);var M=ec.cS(this.hV,j),m=-this.asX,l=this.hV.clone();if(this.abV()){if(M>.99){var A=this.hV;
iV.adR(A,j,this.Q0,this.rect,this.Qs(this.k));D=E.p.lV([A.x,A.y,j.x,j.y]);m=M}else j=this.hV}else while(!0){var g=this.vV+(W-this.vV)*(Math.max(0,m)/M),k=this.ahD(g),$=this.a7q()*(k+this.awt)/2*this.jr.as8;
if(I==iV.mH)$=1;$=Math.max($,.5);if(m+$<M){m+=$;this.k6+=$;var C=new ec(this.hV.x+U.x*m,this.hV.y+U.y*m),s=1;
if(I==iV.mH){var f=l.clone();f.x+=U.x>0?1:-1;var z=l.clone();z.y+=U.y>0?1:-1;if(ec.cS(f,C)<ec.cS(z,C))C=f;
else C=z;m=ec.cS(C,this.hV)}if(this.k.useScatter.v==!0){s=this.k.Cnt.v;var O=this.k.countDynamics.v.jitter.v.val/100,a=O*(-1+2*this.NH());
s+=Math.round(s*a)}for(var L=0;L<s;L++){var X=this.aby(C,k,W,U);D=D.x0(X)}l=C}else break}this.asX=M-m;
this.hV=j;this.vV=W;return D};iV.prototype.a7q=function(){var w=this.k.Brsh.v,n=w.Spcn.v.val,W=Math.max(5,w.Rndn.v.val);
return W/100*(n/100)};iV.prototype.ahD=function(w){var n=this.k,W=n.Brsh.v.Dmtr.v.val;if(n.useTipDynamics.v){var D=W*(n.minimumDiameter.v.val/100);
W=D+(W-D)*(1-this.NH(this.P0)*(n.szVr.v.jitter.v.val/100));W*=iV.UO(n,"szVr",w,this.k6)}return W};iV.UO=function(w,n,W,D){var j=1,I=w[n].v,U=I.bVTy.v,M=I.fStp.v;
if(U==1)j*=Math.max(0,(M-D)/M);if(U==2)j*=W;return j};iV.prototype.aby=function(w,n,W,D){var j=this.HD.Z8,f=0;
j=Math.min(1,j);var I=this.k,U=this.k.Brsh.v,M=U.Dmtr.v.val,m=this.HD,l=m.gQ,A=m.aeJ,g=this.jr.HY[1],k=new eh;
k.translate(-g.m/2,-g.n/2);k.scale(1/this.jr.a9y,1/this.jr.a9y);k.scale(n/M,n/M);k.scale(1,Math.max(5,U.Rndn.v.val)/100);
if(I.usePaintDynamics&&I.usePaintDynamics.v){var $=I.opVr.v.jitter.v.val/100,C=I.prVr.v.jitter.v.val/100;
j*=1-this.NH()*$;j*=1-this.NH()*C;j*=iV.UO(I,"opVr",W,this.k6)*iV.UO(I,"prVr",W,this.k6)}if(I.useTipDynamics.v){var z=I.angleDynamics.v,s=I.minimumRoundness.v.val/100;
k.scale(1,s+(1-s)*Math.round(100-this.NH()*I.roundnessDynamics.v.jitter.v.val)/100);f+=(-.5+this.NH())*4*Math.PI*(z.jitter.v.val/100);
f+=iV.UO(I,"angleDynamics",W,this.k6)*2*Math.PI;if(z.bVTy.v==6)f+=Math.atan2(-D.y,D.x)}f+=U.Angl.v.val*(Math.PI/180);
k.rotate(f);if(I.useScatter.v){var O=(-1+2*this.NH())*I.scatterDynamics.v.jitter.v.val/100;k.translate(-O*n*D.y,O*n*D.x)}k.translate(w.x,w.y);
var a=this.auo(k,w,n),X=a.rect.clone();if(l==null){var P=this.Qs(I);E.cJ(a.SX,Math.round(P.k*255)<<16|Math.round(P.B*255)<<8|Math.round(P.o*255)<<0,4278190080);
if(this.XZ.VY()&&this.rect.s9(a.rect)&&j==1)this.Q0=a.SX.slice(0);else{var Z=-1,Y=2,K=-1,S=2;if(!m.v_){Z=K=0;
Y=S=1}for(var G=K;G<S;G++)for(var V=Z;V<Y;V++){var T=a.rect.clone();T.x+=V*this.rect.m;T.y+=G*this.rect.n;
if(T.L0(this.rect)){X=X.x0(T);E.s.an1(a.SX,T,this.Q0,this.rect,T,j)}}}}if(l==iV.mH){var R=new ec(a.rect.x+a.rect.m/2,a.rect.y+a.rect.n/2),x=Math.round(R.x-this.NL.x),v=Math.round(R.y-this.NL.y),N=a.rect.clone();
N.offset(-x,-v);var u=N.wU(this.rect);u.offset(x,v);E.Cb(this.Q0,this.rect,a.SX,N);E.s.ga(a.SX,a.rect,this.Q0,this.rect,a.mB,a.rect,j)}if(l==iV.yJ||l==iV.w7||l==iV.vO){var H=a.rect.wU(this.rect),F;
if(H.s9(a.rect))F=a.mB;else{F=E.Q(H.O());E.B0(a.mB,a.rect,F,H)}var t=E.Q(H.O()*4);E.Cb(this.Q0,this.rect,t,H);
if(l==iV.w7){var o=t.slice(0),q=E.Z3.kd([-1,-1,-1,-1,25,-1,-1,-1,-1]);E.Z3.yz(t,o,H.m,H.n,q,0);E.nX(o,t)}else if(l==iV.vO){var _=cx._1("UnsM");
_.Amnt.v.val=15;_.Thsh.v=0;_.Rds.v.val=5;var o=E.Q(t.length);cx.Ld("UnsM",{buffer:t,rect:H},_,0,0,{buffer:o,rect:H});
E.nX(o,t)}else{cx.ks(1,E.xX.Qz,t,H)}E.s.ga(t,H,this.Q0,this.rect,F,H,j)}this.awt=n;this.NL=R;this.P0++;
return X};iV.prototype.Qs=function(w){var n=iV.aeP(this.Gp);if(w.useColorDynamics&&w.useColorDynamics.v){var W=1-this.NH()*w.clVr.v.jitter.v.val/100,D=iV.aeP(this.as);
n.o=W*n.o+(1-W)*D.o;n.B=W*n.B+(1-W)*D.B;n.k=W*n.k+(1-W)*D.k;var j=(-.5+this.NH())*w.H.v.val/100,I=(-1+2*this.NH())*w.Strt.v.val/100,U=(-1+2*this.NH())*w.Brgh.v.val/100,M=E.i8(n.o,n.B,n.k);
M.ag=(M.ag+j+1)%1;M._6=M._6+I;if(M._6<0)M._6=-M._6;if(M._6>1)M._6=1-(M._6-1);M.jB=M.jB+U;if(M.jB<0)M.jB=-M.jB;
if(M.jB>1)M.jB=1-(M.jB-1);n=E.li(M.ag,M._6,M.jB)}return n};iV.prototype.Hx=function(w){return Math.max(0,Math.min(1,w))};
iV.prototype.NH=function(w){if(w==null){w=this.Ur++}return iV.hash(w)};iV.aeP=function(w){return{o:(w>>16&255)/255,B:(w>>8&255)/255,k:(w>>0&255)/255}};
iV.hash=function(w){w=w^61^w>>16;w=w+(w<<3);w=w^w>>4;w=w*668265261;w=w^w>>15;return(w&16777215)/16777215};
iV.aiV=new eJ;iV.prototype.auo=function(w,n,W){var D=Math.sqrt(this.jr.HY[1].O()),j=D*w.NW(),I=j<10?1:j<50?1.5:j<200?3:8;
if(j<30)I=0;var U=iV.aiV,M=U.a9P(this.aa4),m=this.HD.dE;if(m){w=w.clone();w.z2=Math.floor(w.z2);w.EU=Math.floor(w.EU)}var l=eJ.asJ(w,D),A=U.akW(M,l);
if(A&&eJ.a12(A.C3,l)>I)A=null;if(A){A.rect.x=Math.round(A.a74.x+w.z2);A.rect.y=Math.round(A.a74.y+w.EU);
if(m){A.rect.x=Math.round(n.x-A.rect.m/2);A.rect.y=Math.round(n.y-A.rect.n/2)}A.Hl=Date.now()}else{var g=Math.round(this.k.Brsh.v.Dmtr.v.val),k;
if(m&&g<=3){k={channel:E.Q(g*g),rect:new iB(Math.round(n.x-g/2),Math.round(n.y-g/2),g,g)};k.channel.fill(255)}else if(w.dl==1&&w.k==0&&w.Cj==0&&w.j7==1){k={channel:this.jr.HY[0],rect:this.jr.HY[1].clone()};
k.rect.x=Math.round(w.z2);k.rect.y=Math.round(w.EU)}else{if(w.NW()>1e-4)k=y.wR.aqN(this.jr.HY,w)}if(m){for(var L=0;
L<k.channel.length;L++)k.channel[L]=k.channel[L]>127?255:0}if(k==null)k={channel:E.Q(0),rect:new iB};
A={SX:E.Q(k.rect.O()*4),mB:k.channel,rect:k.rect,a74:new ec(k.rect.x-w.z2,k.rect.y-w.EU),C3:l,Hl:Date.now()};
E.IL(A.mB,A.SX,3);if(M)U.ayG(M,A)}return A};iV.asM=function(w,n,W){var D,j,I,U=w.Brsh.v.Dmtr.v.val,M=w.Brsh.v.classID;
if(M=="computedBrush"){var m=w.Brsh.v.Hrdn.v.val/100;j=U<100?1.4:1;I=1;D=E.arS.adT(U,m,j)}if(M=="sampledBrush"){var l;
for(var L=0;L<n.length;L++)if(n[L].id==w.Brsh.v.sampledData.v)l=n[L];D=l.HY;var A=D[1];j=Math.max(A.m,A.n)/U;
I=Math.min(A.m,A.n)/Math.max(A.m,A.n)}return{a9y:j,as8:I,HY:D}};iV.T=null;iV.VE=null;iV.sX=function(w,n,W,D,j,I){var U=iV.T,M=iV.VE;
if(U==null){iV.T=U=document.createElement("canvas");iV.VE=M=U.getContext("2d")}if(I==null)I=D;if(U.width!=I||U.height!=j){U.width=I;
U.height=j}else M.clearRect(0,0,I,j);M.fillStyle="#000000";M.font=Math.floor(10*y.V())+"px sans-serif";
var m=w.Brsh.v.Dmtr.v.val,l=""+m,A=w.useBrushSize;if(A&&A.v)l="---";var g=M.measureText(l);M.fillText(l,(D-g.width)/2,j-2);
var k=D,$=j-10*y.V(),C=Math.min(k,$),f=w.Brsh.v.classID;if(f=="computedBrush"){M.translate(k/2,$/2);
M.rotate(-w.Brsh.v.Angl.v.val*Math.PI/180);M.scale(1,.1+.9*w.Brsh.v.Rndn.v.val/100);var z=Math.min(.95*C/2,m/2)+.5,O=.9*w.Brsh.v.Hrdn.v.val/100,a=M.createRadialGradient(0,0,0,0,0,z);
a.addColorStop(O,"rgba(0,0,0,1)");a.addColorStop((.5+O)/1.5,"rgba(0,0,0,.5)");a.addColorStop(1,"rgba(0,0,0,0)");
M.fillStyle=a;M.fillRect(-z,-z,2*z,2*z);M.setTransform(1,0,0,1,0,0)}else if(f=="sampledBrush"){var X,S=0;
for(var L=0;L<n.length;L++)if(n[L].id==w.Brsh.v.sampledData.v)X=n[L];var P=X.HY;E.BB(P);var Z=P[0],Y=P[1].m,K=P[1].n;
while((Y>k||K>$)&&P[S+2]){S+=2;Z=P[S];Y=P[S+1].m;K=P[S+1].n}if(Y*K!=0){var G=E.Q(Y*K*4);E.IL(Z,G,3);
var V=new ImageData(new Uint8ClampedArray(G.buffer),Y,K);M.putImageData(V,Math.round((k-Y)/2),Math.round(($-K)/2))}}else{}return U.toDataURL()};
iV.d9=function(w,n,W,D){if(W==0)W=1;var j=w.Brsh.v,I=j.Dmtr.v.val,U=j.Dmtr.v.val=Math.min(D!=null?Math.round(D*2.6):3e3,I*W),M=j.Hrdn?j.Hrdn.v.val/100:1,m=D!=null?D:Math.round(U*(1+.55*(1-M)))+4,g;
m=Math.max(15,Math.min(m,3e3));var l=new iB(0,0,m,m),A=new iV(w,n,null,{Z8:1},16711712,0,l);j.Dmtr.v.val=I;
A.moveTo(l.m/2,l.n/2);var k=A._a(),$=A.pJ();if(l.s9($))g=k;else{g=E.Q(l.O()*4);E.Cb(k,$,g,l)}return[g,l,U]};
iV.ayH=function(w,n,W,D){var j=n.m,I=j>>>1;for(var L=0;L<4;L++){var U=6-L;w[j*(I-U)+I-1]=D;w[j*(I-U)+I]=W;
w[j*(I-U)+I+1]=D;w[j*(I+U)+I-1]=D;w[j*(I+U)+I]=W;w[j*(I+U)+I+1]=D;w[j*(I-1)+I-U]=D;w[j*I+I-U]=W;w[j*(I+1)+I-U]=D;
w[j*(I-1)+I+U]=D;w[j*I+I+U]=W;w[j*(I+1)+I+U]=D}};iV.QM=function(w,n,W,D){var j=iV.d9(w,n,W),I=j[0].slice(0),U=j[1],M=j[2],m=U.O(),l=E.Q(m);
E.hN(I,l,3);var A=E.Q(m);E.J.aAz(l,A,U,y.V()>1.9);if(M<3||E.em(A,0)||D&&M>12){iV.ayH(A,U,255,0)}var g=[3,5,3,4,8,4,3,5,3];
g=E.Z3.kd(g);E.Z3.Zu(A,l,U.m,U.n,g);E.cJ(I,4294967295);E.IL(l,I,3);for(var L=0;L<m;L++)if(A[L]==255){I[L<<2]=I[(L<<2)+1]=I[(L<<2)+2]=0;
I[(L<<2)+3]=255}return{p0:I,WH:U,Q5:new ec(U.m/2,U.n/2)}};iV.adR=function(w,n,W,D,j){var I=4278190080|Math.round(j.k*255)<<16|Math.round(j.B*255)<<8|Math.round(j.o*255)<<0;
W=new Uint32Array(W.buffer);var U=Math.floor(w.x),M=Math.floor(w.y),m=Math.floor(n.x),l=Math.floor(n.y),A=Math.abs(m-U),g=Math.abs(l-M),k=U<m?1:-1,$=M<l?1:-1,C=A-g;
while(!0){W[M*D.m+U]=I;if(U==m&&M==l)break;var f=2*C;if(f>-g){C-=g;U+=k}if(f<A){C+=A;M+=$}}};iV.mH="0";
iV.yJ="1";iV.w7="2";iV.vO="3";var aj={};aj.a5=function(w,n,W){if(W==null)W=!0;var D=w.add.TySh,j=new d2(D._o,n),I=aj.mD(j,D);
w.US.path=I.path;w.US.HY=[I.Q0,I.WH];E.L3(w.US.HY);w.US.__=I.WH.clone();if(W){w.rect=I.WH;w.buffer=I.Q0;
w.l()}return[j,I]};aj.mD=function(w,n){var W=w.jS(),U=0,l;if(W.x==Infinity||W.VY())return{Q0:E.Q(0),WH:new iB,IA:new iB};
var D=w.jS(),j=aj.wh(w,n),I=E.p.lV(j.w);for(var L=0;L<w.lJ.length;L++){var M=w.lJ[L].mq;if(M.StrokeFlag&&M._LineWidth)U=Math.max(U,Math.ceil(n.D.NW()*M._LineWidth/2))}I.VD(U,U);
if(I.VY())return{Q0:E.Q(0),WH:new iB,IA:new iB};var m=E.Om(I.m,I.n);m.translate(-I.x,-I.y);aj.a6o(j,m);
if(w.lJ.length!=0){var A=hd.J8(n),g=m.getImageData(0,0,I.m,I.n);l=new Uint8Array(g.data.buffer);if(A==0)for(var L=0;
L<l.length;L+=4)l[L+3]=l[L+3]>80?255:0;if(A==3)for(var L=0;L<l.length;L+=4)l[L+3]=Math.min(255,l[L+3]*1.5)}else l=E.Q(I.O()*4);
m.resetTransform();m.beginPath();return{Q0:l,WH:I,IA:D,path:j}};aj.wh=function(w,n){var W=n.D,D=n._o;
aj.QV=W.NW();var j=hd.J8(n),I=Math.max(W.k*W.k,W.Cj*W.Cj)<1e-9?W:null;if(j==3||j==4)I=null;var U={F:[],w:[]};
aj.a7$(w,U,I,!0);aj.a7$(w,U,I,!1);U=aj.W4(U,n,w);return U};aj.QV=1;aj.W4=function(w,n,W){if(w==null)return w;
if(W&&W.UX)E.p.D(w.w,W.UX,w.w);if(W&&!E.XB.pi(n.hc)){var D=hd.pJ(n,W);if(!D.VY()){if(w.F){w=E.p.jp(w);
var j=Math.min(D.m,D.n)/8;if(j<1)j=1;w=E.p.Av(w,j)}var I=E.XB.BI(n.hc,D);E.xv.D(I,w.w,D)}}var U=n.D;
E.p.D(w.w,U,w.w);return w};aj.a6o=function(w,n){n.save();n.miterLimit=2;Typr.U.pathToContext({crds:w.w,cmds:w.F},n);
n.restore()};aj.bN=function(w,n,W){var D=d2.acA(W),j=w._o,I=j.ResourceDict.FontSet,U=j.ResourceDict.StyleSheetSet[0].StyleSheetData,M=j.EngineDict.StyleRun.RunLengthArray,m=j.EngineDict.StyleRun.RunArray,l=hd.Bb(j),A=!0,g={},k=0;
for(var L=0;L<m.length;L++){var $=m[L].StyleSheet.StyleSheetData.Font;if($==null)$=U.Font;for(var C=0;
C<M[L];C++){var f=l.charCodeAt(k+C),z=$+","+(f>128?f:-1);if(g[z]==null){g[z]=1;if(n.lY(I[$].Name,f)==null)A=!1}}k+=M[L]}return A&&D};
aj.MF=function(w,n,W){var D=!0;for(var j=0;j<w.C.length;j++){var I=w.C[j],U=I.add.TySh;if(U!=null&&!aj.bN(U,n,W))D=!1}return D};
aj.yf=function(w,n,W){for(var D=0;D<w.C.length;D++){var j=w.C[D],I=j.add.TySh;if(I!=null&&aj.bN(I,n,W)){aj.a5(j,n);
w.l()}}};aj.a7$=function(w,n,W,D){var j=new eh;for(var L=0;L<w.ci.length;L++)aj.a0e(w.lJ,w.ci[L],n,j,W,D)};
aj.a0e=function(w,n,W,D,j,I){D.translate(n.zt.x,n.zt.y);for(var L=0;L<n.Uv.length;L++){var U={},M=n.Uv[L];
if(!M.tY)break;var m=D.clone();m.translate(M.zt.x,M.zt.y);if(j){var l=j.EU+m.EU*j.j7;m.EU=(Math.round(l)-j.EU)/j.j7}for(var A=M.start;
A<M.end;A++)aj.auU(w,n.yr[A],n,U,W,m,I)}D.translate(-n.zt.x,-n.zt.y)};aj.atx="()<>[]{}\xAB\xBB\u0F3A\u0F3B\u0F3C\u0F3D\u169B\u169C\u2039\u203A\u2045\u2046\u207D\u207E\u208D\u208E\u2208\u2209\u220A\u220B\u220C\u220D\u2215\u223C\u223D\u2243\u2252\u2253\u2254\u2255\u2264\u2265\u2266\u2267\u2268\u2269\u226A\u226B\u226E\u226F\u2270\u2271\u2272\u2273\u2274\u2275\u2276\u2277\u2278\u2279\u227A\u227B\u227C\u227D\u227E\u227F\u2280\u2281\u2282\u2283\u2284\u2285\u2286\u2287\u2288\u2289\u228A\u228B\u228F\u2290\u2291\u2292\u2298\u22A2\u22A3\u22A6\u22A8\u22A9\u22AB\u22B0\u22B1\u22B2\u22B3\u22B4\u22B5\u22B6\u22B7\u22C9\u22CA\u22CB\u22CC\u22CD\u22D0\u22D1\u22D6\u22D7\u22D8\u22D9\u22DA\u22DB\u22DC\u22DD\u22DE\u22DF\u22E0\u22E1\u22E2\u22E3\u22E4\u22E5\u22E6\u22E7\u22E8\u22E9\u22EA\u22EB\u22EC\u22ED\u22F0\u22F1\u22F2\u22F3\u22F4\u22F6\u22F7\u22FA\u22FB\u22FC\u22FD\u22FE\u2308\u2309\u230A\u230B\u2329\u232A\u2768\u2769\u276A\u276B\u276C\u276D\u276E\u276F\u2770\u2771\u2772\u2773\u2774\u2775\u27C3\u27C4\u27C5\u27C6\u27C8\u27C9\u27CB\u27CD\u27D5\u27D6\u27DD\u27DE\u27E2\u27E3\u27E4\u27E5\u27E6\u27E7\u27E8\u27E9\u27EA\u27EB\u27EC\u27ED\u27EE\u27EF\u2983\u2984\u2985\u2986\u2987\u2988\u2989\u298A\u298B\u298C\u298D\u298E\u298F\u2990\u2991\u2992\u2993\u2994\u2995\u2996\u2997\u2998\u29B8\u29C0\u29C1\u29C4\u29C5\u29CF\u29D0\u29D1\u29D2\u29D4\u29D5\u29D8\u29D9\u29DA\u29DB\u29F5\u29F8\u29F9\u29FC\u29FD\u2A2B\u2A2C\u2A2D\u2A2E\u2A34\u2A35\u2A3C\u2A3D\u2A64\u2A65\u2A79\u2A7A\u2A7D\u2A7E\u2A7F\u2A80\u2A81\u2A82\u2A83\u2A84\u2A8B\u2A8C\u2A91\u2A92\u2A93\u2A94\u2A95\u2A96\u2A97\u2A98\u2A99\u2A9A\u2A9B\u2A9C\u2AA1\u2AA2\u2AA6\u2AA7\u2AA8\u2AA9\u2AAA\u2AAB\u2AAC\u2AAD\u2AAF\u2AB0\u2AB3\u2AB4\u2ABB\u2ABC\u2ABD\u2ABE\u2ABF\u2AC0\u2AC1\u2AC2\u2AC3\u2AC4\u2AC5\u2AC6\u2ACD\u2ACE\u2ACF\u2AD0\u2AD1\u2AD2\u2AD3\u2AD4\u2AD5\u2AD6\u2ADE\u2AE3\u2AE4\u2AE5\u2AEC\u2AED\u2AF7\u2AF8\u2AF9\u2AFA\u2E02\u2E03\u2E04\u2E05\u2E09\u2E0A\u2E0C\u2E0D\u2E1C\u2E1D\u2E20\u2E21\u2E22\u2E23\u2E24\u2E25\u2E26\u2E27\u2E28\u2E29\u3008\u3009\u300A\u300B\u300C\u300D\u300E\u300F\u3010\u3011\u3014\u3015\u3016\u3017\u3018\u3019\u301A\u301B\uFE59\uFE5A\uFE5B\uFE5C\uFE5D\uFE5E\uFE64\uFE65\uFF08\uFF09\uFF1C\uFF1E\uFF3B\uFF3D\uFF5B\uFF5D\uFF5F\uFF60\uFF62\uFF63";
aj.auU=function(w,n,W,D,j,I,U){I.translate(n.zt.x,n.zt.y);for(var M=n.HB;M<=n.jE;M++){var m=W.Lw[M],l=m.WH.m,A=w[W.a1l+m.QR],g=A.mq._FillBackgroundFlag;
if(A.qQ=="\n"||U&&!g)continue;var k=A.mq.FontSize/A.kS.head.unitsPerEm,$=I.clone();$.translate(m.zt.x+m.$c*k,m.zt.y-m.D8*k);
var C=new eh;C.scale(k,-k);if(A.G7==1&&aj.atx.indexOf(A.qQ)!=-1)C.concat(new eh(-1,0,0,1,l,0));if(A.mq.FauxItalic)C.concat(new eh(1,0,-Math.tan(.18),1,0,0));
C.translate(0,A.Sf);C.scale(A.scale.x,A.scale.y);if(A.mq.BaselineShift!=null)C.translate(0,-A.mq.BaselineShift);
if(m.Tg!=0){C.rotate(-m.Tg)}C.concat($);var f=(A.mq._LineWidth?A.mq._LineWidth:1)*aj.QV;if(U){j.F.push(aj.Qs(A.mq._FillBackgroundColor));
var z=1.005*m.WH.n/k,s=new iB(-m.$c,-z*.27,1.03*m.WH.m/(k*A.scale.x),z);if(A.mq.StrokeFlag)s.VD(f/k,f/k);
E.p.concat(j,E.p.Wx(s),C);j.F.push("X");continue}if(A.mq.FillFlag)j.F.push(aj.Qs(A.mq.FillColor));if(A.mq.StrokeFlag)j.F.push("O-"+aj.Qs(A.mq.StrokeColor)+"-"+f);
if(m.path.F.length!=0&&A.qQ!="\t"){if(A.mq.FauxBold){var O=A.mq.FontSize/2048*27*A.scale.x;C.z2+=O;E.p.concat(j,m.path,C);
C.z2-=O+O;E.p.concat(j,m.path,C)}else E.p.concat(j,m.path,C)}if(A.qQ!="\n"){if(A.mq.Underline){if(D.Xs==null)D.Xs=A.kS.post.underlineThickness;
if(D.agV==null)D.agV=A.kS.post.underlinePosition;var a=0,X=D.agV-D.Xs/2,P=m.Qc*1.05,Z=-D.Xs;E.p.concat(j,{F:["M","L","L","L","Z"],w:[a,X,a+P,X,a+P,X+Z,a,X+Z]},C)}if(A.mq.Strikethrough){var Y=A.kS["OS/2"].yStrikeoutSize,K=A.kS["OS/2"].yStrikeoutPosition,a=0,X=K+Y/2,P=m.Qc*1.05,Z=-Y;
E.p.concat(j,{F:["M","L","L","L","Z"],w:[a,X,a+P,X,a+P,X+Z,a,X+Z]},C)}}if(A.mq.FillFlag)j.F.push("X");
if(A.mq.StrokeFlag)j.F.push("OX")}I.translate(-n.zt.x,-n.zt.y)};aj.Qs=function(w){var n=hd.y_(w),W=(Math.round(n.o)<<16)+(Math.round(n.B)<<8)+Math.round(n.k);
return"#"+E.$$(W)};function d2(w,n){var W=hd.F$(w),D,j,I=hd.Bj(w),U=w._LineOrientation==2?new eh:null,A,k;
if(w.Curve)j=d2.AL(w.Curve);if(W!=0){D=new iB(I[0],I[1],I[2],I[3]);if(U){var M=D.m;D.m=D.n;D.n=M;U.translate(0,-I[2])}if(W==2){D.m=j[5]-j[4];
D.n=9999}}this.ci=[];this.lJ=[];this.Y3=W;this.UX=U;var m=this.ag1=hd.Bb(w),l=-1,g=-1;for(var L=0;L<m.length;
L++){var $=A,C=hd.acL(w,L);if(C!=l){l=C;$=A=hd.atq(w,C)}var f=k,C=hd.azw(w,L);if(C!=g){g=C;f=k=hd.a68(w,C)}var z={qQ:m.charAt(L),mq:$,kS:null,St:-1,kM:hd.a3j(w,L),Sf:0,scale:new ec(0,0),Ea:0,lineHeight:0,G7:0},s=w.ResourceDict.FontSet[$.Font].Name,O=z.kS=n.lY(s,m.charCodeAt(L));
z.scale.x=$.HorizontalScale==null?1:$.HorizontalScale;z.scale.y=$.VerticalScale==null?1:$.VerticalScale;
var a=O["OS/2"],X=O.hhea;if($.FontCaps==1&&z.qQ!=z.qQ.toUpperCase()){var P=a.sxHeight?a.sxHeight/a.sTypoAscender:.76;
z.scale.x*=P;z.scale.y*=P}var Z=1/O.head.unitsPerEm*$.FontSize;if($.FontBaseline==1){var P=w.ResourceDict.SuperscriptSize;
z.scale.x*=P;z.scale.y*=P;z.Sf-=w.ResourceDict.SuperscriptPosition*$.FontSize}if($.FontBaseline==2){var P=w.ResourceDict.SubscriptSize;
z.scale.x*=P;z.scale.y*=P;z.Sf+=w.ResourceDict.SubscriptPosition*$.FontSize}z.Ea=d2.Ea(O)*$.FontSize;
var Y=f.AutoLeading;z.lineHeight=$.FontSize*(Y==null?1.2:Y);if($.AutoLeading==!1)z.lineHeight=$.Leading;
if(z.lineHeight==0)z.lineHeight=.01;this.lJ.push(z)}var K=this.ci,S=[0];for(var L=0;L<w.EngineDict.ParagraphRun.RunLengthArray.length;
L++){var G=new d2.U3(w,n,this.lJ,L,D,S,W==1?j:null);K.push(G)}if(U){if(W==0)U.translate(0,K[0].yr[0].Ea/2);
U.rotate(-Math.PI/2)}if(W==2){var V=w.Curve.Points,T=j[0],R=j[1],x=j[2],v=j[3],N=j[4],u=j[5];for(var L=0;
L<K.length;L++)for(var H=0;H<K[L].Uv.length;H++)if(!(L==0&&H==0))K[L].Uv[H].tY=!1;var G=K[0],F=G.Uv[0];
G.zt.y1(0,0);F.zt.y1(0,0);for(var H=F.start;H<F.end;H++){var t=G.yr[H],o=t.zt.x;t.zt.x=0;for(var q=t.HB;
q<=t.jE;q++){var _=G.Lw[q],d=_.WH.m/2;_.zt.x+=o;var r=d2.agv(T,(N+_.zt.x+d)%v);_.zt.x=r[0]-d*r[2];_.zt.y=r[1]-d*r[3];
_.Tg=Math.atan2(r[3],r[2])}}}}d2.Ea=function(w){var n=w._hh;if(n==null){var W=Typr.U,D=W.codeToGlyph(w,104),j=E.p.mY(Typr.U.glyphToPath(w,D).crds).n;
n=w._hh=j*(1/w.head.unitsPerEm)}return n};d2.prototype.a7J=function(){return!this.ao_(0)};d2.prototype.aep=function(){return this.ao_(1)};
d2.prototype.ao_=function(w){var n=this.ci,W=!0,D=0;for(var L=0;L<n.length;L++){var j=n[L].Uv,I=j.length;
D+=I;for(var U=0;U<I;U++)W&=j[U].tY}return[W,D][w]};d2.AL=function(w,n,W){if(n==null)n=.25;var D=w.Points,j=D.length,I=j>>>3,U=w.TextOnPathTRange,M=w.Reversed,k=0,$=0;
if(M){var m=D.slice(0);for(var L=0;L<j;L+=2){m[L]=D[j-2-L];m[L+1]=D[j-1-L]}D=m;U=[I-U[1]%I,I-U[0]%I]}var l=[],A=[0],g=[0];
for(var L=0;L<j;L+=8){var C=D[L+6]-D[L+0],f=D[L+7]-D[L+1],z=Math.round(Math.sqrt(C*C+f*f)/n),s=W&&L==j-8?z+1:z;
for(var O=0;O<s;O++){var a=O/z,X=1-a,P=X*X*X*D[L+0]+3*X*X*a*D[L+2]+3*X*a*a*D[L+4]+a*a*a*D[L+6],Z=X*X*X*D[L+1]+3*X*X*a*D[L+3]+3*X*a*a*D[L+5]+a*a*a*D[L+7];
l.push(P,Z);if(L+O!=0){var C=P-k,f=Z-$;g.push(g[g.length-1]+Math.sqrt(C*C+f*f));A.push((L>>>3)+a)}k=P;
$=Z}}var n=g.length,Y=g[n-1],K=d2.nQ(U[0]%I,A),S=d2.nQ(U[1]%I,A),G=g[K%n],V=g[S%n];if(G>=V)V+=Y;return[l,A,g,Y,G,V]};
d2.nQ=function(w,n){var L=0;while(n[L]<w)L++;return L};d2.agv=function(w,n){var W=0,L=0,D,j,I;while(W<n){D=w[L+2]-w[L];
j=w[L+3]-w[L+1];I=Math.sqrt(D*D+j*j);W+=I;L+=2}return[w[L],w[L+1],D/I,j/I]};d2.prototype.axu=function(w){return this.lJ[w]};
d2.prototype.auH=function(w){for(var n=0;n<this.ci.length;n++){var W=this.ci[n];for(var D=0;D<W.Uv.length;
D++){var j=W.Uv[D],I=W.yr[j.start].start,U=W.yr[j.end-1].end;if(I<w&&w<U)return[I,U-1]}}return[0,1]};
d2.prototype.a3v=function(w,n){var W=-1,D=this.ci;if(this.Y3==2){var j=1e9,I=0,U=D[0],M=U.Uv[0];for(var m=M.start;
m<M.end;m++){var l=U.yr[m];for(var A=l.HB;A<=l.jE;A++){var g=U.Lw[A],k=g.WH.m,$=w.x-g.zt.x,C=w.y-g.zt.y,f=$*$+C*C;
if(f<j){j=f;I=g.QR}}}if(I!=0&&this.ag1.codePointAt(I-1)>65535)I--;return I}for(var z=0;z<D.length;z++){var U=D[z];
for(var s=0;s<U.Uv.length;s++){W++;var M=U.Uv[s],O=U.Uv[s+1];if(O==null&&z<D.length-1)O=D[z+1].Uv[0];
if(n!=null){if(W!=n)continue}else{if(O!=null&&U.zt.y+M.zt.y<w.y)continue}for(var m=M.start;m<M.end;m++){var l=U.yr[m];
for(var A=l.HB;A<=l.jE;A++){var g=U.Lw[A],k=g.WH.m,a=U.zt.x+M.zt.x+l.zt.x,X=a+g.zt.x,P=a+(A<l.jE?U.Lw[A+1].zt.x:g.zt.x+k);
if(w.x<=P||m+1==M.end&&A==l.jE){var Z=U.a1l+g.QR,Y=this.lJ[Z],K=Y.G7&1;if(Y.qQ!="\n"&&(K==0&&w.x>X+k/2||K==1&&w.x<X+k/2))Z+=this.ag1.codePointAt(Z)>65535?2:1;
return Z}}}}}};d2.prototype.ic=function(w){var n={WH:new iB,TL:0},W=0;for(var D=0;D<this.ci.length;D++){var j=this.ci[D];
for(var I=0;I<j.Uv.length;I++){var U=j.Uv[I];n.TL=W;W++;for(var M=U.start;M<U.end;M++){var m=j.yr[M];
for(var l=m.start;l<m.end;l++){if(l==w){var A=this.lJ[l],g=A.St,k=j.Lw[g].QR,$=1;while(j.Lw[g]!=null&&j.Lw[g].QR==k){var C=j.Lw[g],f=j.zt.x+U.zt.x+m.zt.x+C.zt.x,z=j.zt.y+U.zt.y+m.zt.y+C.zt.y;
n.WH=n.WH.x0(new iB(f,z-A.lineHeight,C.WH.m,A.lineHeight));n.Tg=C.Tg;g+=$}return n}}}}}};d2.prototype.jS=function(){var w=Infinity,n=Infinity,W=-Infinity,D=-Infinity;
for(var L=0;L<this.ci.length;L++){var j=this.ci[L];for(var I=0;I<j.Uv.length;I++){var U=j.Uv[I];if(!U.tY)break;
for(var M=U.start;M<U.end;M++){var m=j.yr[M];for(var l=m.HB;l<=m.jE;l++){var A=j.Lw[l],g=A.WH,k=j.zt.x+U.zt.x+m.zt.x+A.zt.x,$=j.zt.y+U.zt.y+m.zt.y+A.zt.y;
w=Math.min(w,k+g.x);n=Math.min(n,$+g.y);W=Math.max(W,k+g.x+g.m);D=Math.max(D,$+g.y+g.n)}}}}return new iB(w,n,W-w,D-n)};
d2.Wb=function(w){return 19968<=w&&w<=40959||12288<=w&&w<=12543};d2.afq=function(w,n,W,D,j,I,U){var M=[I],m=0;
for(var L=I;L<U;L++){if(W[L]==null)console.log(L,I,U,W);var l=W[L].qQ,A=l.charCodeAt(0);if(A==32||A==9){M.push(m,L,1,L+1);
m=0}else if(A==3851){M.push(m+1,L+1);m=0}else if(d2.Wb(A)){M.push(m,L);m=1}else if(L!=I&&W[L].G7!=W[L-1].G7){M.push(m,L);
m=1}else m++}M.push(m);var g=[];for(var L=0;L<M.length;L+=2){var k=M[L],$=M[L+1];if($==0)continue;g.push(new d2.a1M(w,n,W,D,j,k,$))}return g};
d2.ard=function(w,n,W,D,j,I,U){var M=[0,n?n.m:1e9],m=[];if(D){var l=w[I].Ea,A=j+(j==0?l:w[I].lineHeight),g=A-l*.9,k=E.p.EM(D[0],g),$=k.length,C=E.p.EM(D[0],A),f=C.length;
if($!=0&&f!=0){var z=0,s=0,O=[];while(z<$&&s<f){var a=Math.max(k[z],C[s]),X=k[z+1],P=C[s+1],Z=Math.min(X,P);
if(a<Z)O.push(a,Z);if(X<P)z+=2;else s+=2}if(O.length!=0)M=O}}for(var Y=0;Y<M.length;Y+=2){var K=0,S=I,G=n?M[Y+1]-M[Y]-W.StartIndent-W.EndIndent-(I==0?W.FirstLineIndent:0):Infinity;
while(I!=w.length){var V=w[I],T=K==0||(V.r9||V.xS)||K+V.WH.m<G;if(!T)break;K+=V.WH.m;I++}m.push(I-S)}U[0]=m;
U[1]=M;U[2]=I};d2.a71=function(w,n){var W=w.length,D=new Uint32Array(W),j=new Uint8Array(W),I=0;for(var L=0;
L<W;L++){j[L]=0;var U=w.charCodeAt(L);D[L]=U;if(U>I)I=U}if(I>1424)j=d2.a8G(D,n);return j};d2.afu=function(w){return w=="\xDF"?w:w.toUpperCase()};
d2.U3=function(w,n,W,D,j,I,U){this.yr=[];this.Uv=[];this.zt=new ec(0,0);this.Lw=null;this.yr=null;this.mq=hd.a68(w,D);
var M=this.mq,g=0,C="",a=0,X=1,_=0;if(D!=0){var m=M.SpaceBefore;if(m!=null)I[0]+=m}var l=w.EngineDict.ParagraphRun.RunLengthArray,A=l[D];
for(var L=0;L<D;L++)g+=l[L];var k=M._Direction?M._Direction:0;this.a1l=g;var $=hd.Bb(w).slice(g,g+A);
for(var f=0;f<$.length;f++){var z=$.charAt(f);C+=W[g+f].mq.FontCaps==0?z:d2.afu(z)}$=C;var s=d2.a71($,k),O=[],P=s[L]&1,Z=W[g].kS;
W[g].G7=s[0];for(var L=1;L<$.length;L++){var z=W[g+L],Y=s[L];z.G7=Y;if(Y!=P||z.kS!=Z){O.push(a,X);a=L;
X=1;P=Y;Z=z.kS}else X++}O.push(a,X);var K=this.Lw=[];for(var L=0;L<O.length;L+=2){var S=O[L],G=O[L+1],V=(W[g+S].G7&1)==0,T=$.slice(S,S+G),R=Typr.U.shapeHB(W[g+S].kS,T,V),x=[],u=0;
for(var f=0;f<R.length;f++){var v=R[f];x.push({B:v.g,QR:v.cl,Qc:v.ax,tc:v.ay,$c:v.dx,D8:v.dy})}R=x;var N=R.slice(0);
if(!V)N.reverse();for(var f=0;f<T.length;f++){while(u+1<N.length&&N[u+1].QR<=f){u++}while(u>0&&N[u-1].QR==f)u--;
W[g+S+f].St=K.length+(V?u:N.length-u-1)}for(var f=0;f<R.length;f++){K.push(R[f]);R[f].QR+=S;var z=W[g+R[f].QR];
if(z.kM!=-1&&z.kM<z.kS.maxp.numGlyphs){R[f].B=z.kM;var H=z.kS.hmtx;if(H){var F=Object.keys(H)[0];R[f].Qc=H[F][z.kM]}}if(z.qQ=="\n")R[f].Qc=0;
if(z.qQ=="\t")R[f].Qc=z.kS.head.unitsPerEm*36/z.mq.FontSize}}var t=hd.Hm(M),o=this.yr=d2.afq(w,n,W,g,K,g,g+A),q=this.Uv,d=-1,C=[null,null,0];
while(_<o.length){d2.ard(o,j,M,U,I[0],_,C);d++;var r={start:_,end:0,WH:new iB,zt:new ec(0,0),tY:!0},iJ=0,fL=0;
q.push(r);r.end=C[2];if(r.start==r.end)throw"e";var p=r.end==o.length;function Q(N,S,eS){var gL=eS-S>>>1;
for(var L=0;L<gL;L++){var e_=N[S+L];N[S+L]=N[eS-1-L];N[eS-1-L]=e_}}for(var B=1;B<5;B++){var i=-1;for(var L=r.start;
L<r.end;L++){var Y=W[o[L].start].G7;if(i==-1&&Y>=B)i=L;else if(i!=-1&&Y<B){Q(o,i,L);i=-1}}var c=r.end;
if(k==0&&o[c-1].r9)c--;if(i!=-1)Q(o,i,c)}var h2=C[0],jX=C[1],i=_,bm=_;for(var dC=0;dC<jX.length;dC+=2){var fn=j?jX[dC+1]-jX[dC]-M.StartIndent-M.EndIndent-(_==0?M.FirstLineIndent:0):Infinity,fK=0;
i=bm;bm+=h2[dC>>>1];var i6=this.amH(i,bm,o,k,j!=null);if(j){if(t==1||p&&t==4)fK=i6[1]+(fn-i6[0]);if(t==2||p&&t==5)fK=i6[1]+(fn-i6[0])/2;
if(bm-i==1&&o[i].WH.m>fn)fK=0;if(d==0)fK+=M.FirstLineIndent;fK+=M.StartIndent}else{if(t==0)fK=M.StartIndent+M.FirstLineIndent;
if(t==1)fK=-i6[0]-M.EndIndent;if(t==2)fK=-i6[0]/2}fK+=jX[dC];if(j&&t>2&&(t==6||!p))this.agf(i,bm,o,fn,k,fK);
else{var dh=fK;for(var L=i;L<bm;L++){var kA=o[L],ig=kA.WH.m;kA.zt.x=dh;if(kA.xi=="\t")ig=Math.ceil((dh+4)/36)*36-dh;
dh+=ig}}}_=r.end;for(var L=r.start;L<r.end;L++){var fB=o[L].WH.clone();fB.dS(o[L].zt);r.WH=r.WH.x0(fB);
iJ=Math.max(iJ,o[L].Ea);fL=Math.max(fL,o[L].lineHeight)}r.zt.y=d==0?0:q[d-1].zt.y+fL;if(d==0){if(D==0&&j)I[0]+=iJ;
if(D!=0)I[0]+=fL;this.zt.y=I[0]}else I[0]+=fL;if(j)r.tY=this.zt.y+r.zt.y<j.y+j.n||D==0&&d==0}var ah=M.SpaceAfter;
if(ah!=null)I[0]+=ah};d2.U3.prototype.amH=function(w,n,W,D,j){var I=0,U=0;for(var L=w;L<n;L++)I+=W[L].WH.m;
if(j){if(D==0)for(var L=n-1;L>=w;L--)if(W[L].r9||W[L].xS)I-=W[L].WH.m;else break;if(D==1)for(var L=w;
L<n;L++)if(W[L].r9||W[L].xS){var M=W[L].WH.m;I-=M;U-=M}else break}return[I,U]};d2.U3.prototype.agf=function(w,n,W,D,j,I){var U=0,M=0,m=0,l=0;
for(var L=w;L<n;L++)if(W[L].r9)m++;else{U+=W[L].WH.m;M++}if(j==0)for(var L=n-1;L>=w;L--)if(W[L].r9||W[L].xS){if(W[L].r9){m--}}else break;
if(j==1)for(var L=w;L<n;L++)if(W[L].r9||W[L].xS){if(W[L].r9){m--;l++}}else break;if(M<=1||m==0){if(M==1)W[w].zt.x=I;
return}var A=(D-U)/m,g=-l*A;for(var L=w;L<n;L++){if(W[L].r9)this.Lw[W[L].HB].WH.m=W[L].WH.m=A;W[L].zt.x=I+g;
g+=W[L].WH.m}};d2.a1M=function(w,n,W,D,j,I,U){this.xi="";for(var L=0;L<U;L++)this.xi+=W[I+L].qQ;this.r9=U==1&&(W[I].qQ==" "||W[I].qQ=="\t");
this.xS=U==1&&W[I].qQ=="\n";this.start=I;this.end=I+U;this.WH=new iB;this.zt=new ec(0,0);this.Ea=0;this.lineHeight=0;
var M=0,m=0;if(U==0){this.lineHeight=W[I].lineHeight;this.Ea=W[I].Ea;this.WH=new iB(0,-W[I].lineHeight,0,W[I].lineHeight)}var l=W[I].St,A=W[I+U-1].St;
if(A<l){var g=l;l=A;A=g}while(A+1<j.length&&j[A].QR==j[A+1].QR){A++}this.HB=l;this.jE=A;for(var k=l;
k<=A;k++){var $=j[k],C=W[D+$.QR],f=w._LineOrientation==2&&(C.mq.BaselineDirection!=2||d2.Wb(C.qQ.charCodeAt(0))),z=Typr.U.glyphToPath(C.kS,$.B),P=0;
$.path={F:z.cmds,w:z.crds};var s=C.mq.FontSize,O=1/C.kS.head.unitsPerEm*s;if(!C.mq.AutoKerning)M+=C.mq.Kerning*2*O*C.scale.x;
$.zt=new ec(M,0);$.Tg=0;if(f&&$.path.w.length>0){$.Tg=-Math.PI/2;$.zt.x+=s*.83;$.zt.y=-s*.3+$.Qc*O/2;
$.Qc=s/O}var a=$.Qc*O*C.scale.x;$.WH=new iB(0,-C.lineHeight,a,C.lineHeight);var X=$.WH.clone();X.dS($.zt);
if(C.mq.Tracking!=null)P=C.mq.Tracking*.001*s;if(C.mq.FauxBold==!0)P+=.027*s;M+=a+P;if(U==1&&C.qQ==" ")X.m+=2*P;
else if(U==1&&C.qQ!=null&&d2.Wb(C.qQ.charCodeAt(0)))X.m+=P;this.WH=this.WH.x0(X);this.Ea=Math.max(this.Ea,C.Ea);
this.lineHeight=Math.max(this.lineHeight,C.lineHeight)}};d2.yD=0;d2.acA=function(w){if(d2.yD==2)return!0;
if(d2.yD==1)return!1;d2.yD=1;function n(){fetch("code/ext/fribidi.wasm").then(function(W){return W.arrayBuffer()}).then(function(W){return WebAssembly.instantiate(W)}).then(function(W){var D=W.instance.exports,j=D.memory,I=16,U=256,M=1,m=I|U,l=I|U|M;
d2.a8G=function(g,k){var $=g.length,C=$*4+4+$*4+$*4+$;jj.ne(D,C+$+1e7);var f=new Uint8Array(j.buffer),s=new Uint32Array(j.buffer),O=D.calloc(C,1),a=O+$*4,X=a+4,P=X+$*4,Z=P+$*4;
s.set(g,O>>>2);s[a>>>2]=k==0?m:l;D.fribidi_get_bidi_types(O,$,X);D.fribidi_get_bracket_types(O,$,X,P);
D.fribidi_get_par_embedding_levels_ex(X,P,$,a,Z);var Y=f.slice(Z,Z+$);D.free(O);return Y};d2.yD=2;var A=new ed(b.E.L,!0);
A.data={d:b.c.oj,BX:"add",AH:bk.v3,O2:null};w.S(A)})}Typr.U.initHB("code/ext/hb.wasm",n);return!1};function hd(){}hd.iJ=function(w){return JSON.parse(JSON.stringify(w))};
hd.J9=function(w,n){for(var W in n)w[W]=n[W]};hd._3=function(w,n,W,D){var j=hd.amo();if(W)hd.g0(j,0,0,W);
var I=new eh;if(D!=null)I.rotate(D);I.translate(Math.round(w),Math.round(n));var U={D:I,_o:j};U.lz=hd.ah1();
U.hc=E.XB.Q();U.IA=new iB;return U};hd.arC=function(w){var n=["CharacterDirection",0];for(var L=0;L<n.length;
L+=2){if(w[n[L]]!=null&&w[n[L]]!=n[L+1]){throw"e";console.log(n[L],w[n[L]])}}if(w instanceof Array)for(var L=0;
L<w.length;L++)hd.arC(w[L]);else if(w instanceof Object)for(var W in w)hd.arC(w[W])};hd.Hm=function(w,n){if(n==null)n=w.Justification;
var W=w._Direction?w._Direction:0;if(W==1){if(n==0||n==3)n++;else if(n==1||n==4)n--}return n};hd.Y_=function(w){if(w.add==null)return;
var n=w._o,W=n.Curve,D=w.add.vmsk,j=D.i,I=E.p.xH(j,!0).w,U=w.D.clone();U.Ba();E.p.D(I,U,I);var M=I.slice(0,8);
for(var m=8;m<I.length;m+=6)M.push(I[m-2],I[m-1],I[m],I[m+1],I[m+2],I[m+3],I[m+4],I[m+5]);W.Points=M;
W.TextOnPathTRange=D.H3.slice(0);W.Reversed=D.Ty;if(hd.F$(n)==1){var W=d2.AL(n.Curve),l=E.p.mY(W[0]);
hd.sV(n,[0,0,l.m,l.n].map(Math.round));for(var L=0;L<M.length;L+=2){M[L]-=l.x;M[L+1]-=l.y}var A=new eh(1,0,0,1,l.x,l.y);
A.concat(w.D);w.D=A}};hd.ls=function(w){if(w.add==null)return;var n=w.add.vmsk,W=w._o.Curve,D=W.Points,j={F:["M"],w:[D[0],D[1]]};
for(var L=0;L<D.length;L+=8){j.F.push("C");j.w.push(D[L+2],D[L+3],D[L+4],D[L+5],D[L+6],D[L+7])}E.p.D(j.w,w.D,j.w);
var I=E.p.oF(j,!0);n.i=I;n.Ty=W.Reversed;n.H3=W.TextOnPathTRange.slice(0);w.add.vogk=h.hu(I)};hd.y_=function(w){var n={o:0,B:0,k:0};
if(w){var W=w.Values;if(w.Type==1)n={o:W[1]*255,B:W[2]*255,k:W[3]*255};else if(w.Type==2){var D={classID:"CMYC",Cyn:{t:"doub",v:W[1]*100},Mgnt:{t:"doub",v:W[2]*100},Ylw:{t:"doub",v:W[3]*100},Blck:{t:"doub",v:W[4]*100}};
n=E.M.y_(D)}else console.log("Unknown color type")}return n};hd.alp=function(w){for(var L=0;L<w.length;
L++){var n=w[L].StyleSheet.StyleSheetData,W=n.FillColor;if(W&&W.Type==2){var D=hd.y_(W);W.Type=1;W.Values=[1,D.o/255,D.B/255,D.k/255]}}};
hd.pJ=function(w,n){var W;if(hd.F$(w._o)==1){var D=hd.Bj(w._o);W=new iB(0,0,D[2]-D[0],D[3]-D[1])}else{W=n.jS();
if(n.UX){var j=n.UX.clone(),I=E.p.Wx(W);E.p.D(I.w,j,I.w);W=E.p.mY(I.w)}}return W};hd.y9=function(w){var n=w[0];
for(var L=0;L<w.length;L++)n=hd.auz(n,w[L]);return n};hd.auz=function(w,n){var W={};for(var D in w)if(JSON.stringify(w[D])==JSON.stringify(n[D]))W[D]=w[D];
return W};hd.hI=function(w,n){var W=w.JO,D=-1;for(var L=0;L<W.length;L++)if(W[L].Name==n)D=L;if(D==-1){D=W.length;
W.push({FontType:1,Name:n,Script:0,Synthetic:0})}w.lJ.Font=D};hd.Bb=function(w){return w.EngineDict.Editor.Text.replace(/\r/g,"\n").replace(/\u0003/g,"\n")};
hd.Gc=function(w,n){w.EngineDict.Editor.Text=n.replace(/\n/g,"\r")};hd.F$=function(w){return w.Curve&&w.Curve.TextOnPathTRange[0]>=0?2:w.EngineDict.Rendered.Shapes.Children[0].ShapeType};
hd.VL=function(w,n){var W=w.EngineDict.Rendered.Shapes.Children[0];W.ShapeType=n;var D=W.Cookie.Photoshop;
D.ShapeType=n;D.Base.ShapeType=n;if(n==0){delete D.BoxBounds;D.PointBase=[0,0]}if(n==1){delete D.PointBase;
D.BoxBounds=[0,0,1,1]}};hd.Bj=function(w){return w.EngineDict.Rendered.Shapes.Children[0].Cookie.Photoshop.BoxBounds};
hd.sV=function(w,n){w.EngineDict.Rendered.Shapes.Children[0].Cookie.Photoshop.BoxBounds=n};hd.a3j=function(w,n){var W=w.EngineDict.AlternateGlyphRun;
if(W==null)return-1;var D=hd.Rt(W.RunLengthArray,n).Pb;if(W.RunArray[D]==null)return-1;var j=W.RunArray[D].Glyph;
return j==null?-1:j};hd.aqP=function(w,n,W){var D=w.EngineDict.AlternateGlyphRun;if(D==null){D=w.EngineDict.AlternateGlyphRun=hd.amY();
D.RunArray.push({});D.RunLengthArray.push(hd.Bb(w).length)}var j=hd.Rt(D.RunLengthArray,n),I=j.Pb,U=n-j.sp,M=D.RunArray[I],m=JSON.stringify(M),l=D.RunLengthArray[I];
if(U!=0){D.RunArray.splice(I,0,JSON.parse(m));D.RunLengthArray.splice(I,0,U);D.RunLengthArray[I+1]-=U;
I++;l-=U;U=0}if(l!=1){D.RunArray.splice(I+1,0,JSON.parse(m));D.RunLengthArray.splice(I+1,0,l-1);D.RunLengthArray[I]=1;
l=1}M.Glyph=W};hd.acL=function(w,n){var W=w.EngineDict.StyleRun.RunLengthArray;return hd.Rt(W,n).Pb};
hd.atq=function(w,n){var W=w.ResourceDict.StyleSheetSet[0].StyleSheetData,D={};for(var j in W)D[j]=W[j];
var I=w.EngineDict.StyleRun.RunArray[n].StyleSheet.StyleSheetData;hd.J9(D,I);return D};hd.azw=function(w,n){var W=w.EngineDict.ParagraphRun.RunLengthArray;
return hd.Rt(W,n).Pb};hd.a68=function(w,n){var W=w.ResourceDict.ParagraphSheetSet[0].Properties,D={};
for(var j in W)D[j]=W[j];var I=w.EngineDict.ParagraphRun.RunArray[n].ParagraphSheet.Properties;hd.J9(D,I);
var U=["StartIndent","EndIndent","FirstLineIndent"];for(var L=0;L<3;L++)if(D[U[L]]==null)D[U[L]]=0;return D};
hd.KO=function(w,n,W){if(W=="")return;var D=hd.Bb(w);hd.Gc(w,D.substring(0,n)+W+D.substring(n,D.length));
var j=w.EngineDict.StyleRun,I=j.RunLengthArray,U=hd.Rt(I,n-1);I[U.Pb]+=W.length;var M=w.EngineDict.AlternateGlyphRun;
if(M){var I=M.RunLengthArray,U=hd.Rt(I,n-1);I[U.Pb]+=W.length}var m=w.EngineDict.ParagraphRun,I=m.RunLengthArray,l=hd.Rt(I,n),A=W.split("\n");
if(A.length==1){I[l.Pb]+=W.length;return}I.splice(l.Pb+1,0,I[l.Pb]-(n-l.sp));m.RunArray.splice(l.Pb+1,0,hd.iJ(m.RunArray[l.Pb]));
I[l.Pb]-=I[l.Pb+1];I[l.Pb]+=A[0].length+1;for(var L=1;L<A.length-1;L++){m.RunArray.splice(l.Pb+L,0,hd.iJ(m.RunArray[l.Pb+L-1]));
m.RunLengthArray.splice(l.Pb+L,0,A[L].length+1)}I[l.Pb+A.length-1]+=A[A.length-1].length};hd.Ec=function(w,n,W){var D=hd.Bb(w);
hd.Gc(w,D.substring(0,n)+D.substring(W,D.length));hd.En(w.EngineDict.ParagraphRun,n,W,!0);hd.En(w.EngineDict.StyleRun,n,W,!1);
var j=w.EngineDict.AlternateGlyphRun;if(j)hd.En(j,n,W,!1)};hd.En=function(w,n,W,D){var j=w.RunLengthArray,I=hd.Rt(j,n),U=hd.Rt(j,W),M=[];
for(var L=0;L<j.length;L++)for(var m=0;m<j[L];m++)M.push(L);M.splice(n,W-n);var l=[];for(var L=0;L<j.length;
L++)l.push(0);for(var L=0;L<M.length;L++)l[M[L]]++;for(var L=0;L<j.length;L++){if(l[L]==0){l.splice(L,1);
j.splice(L,1);w.RunArray.splice(L,1);L--}else if(l[L]<j[L])j[L]=l[L]}if(D&&I.Pb!=U.Pb&&I.sp!=n){j[I.Pb]+=j[I.Pb+1];
j.splice(I.Pb+1,1);w.RunArray.splice(I.Pb+1,1)}};hd.g0=function(w,n,W,D){var j=w.EngineDict.Editor.Text.length;
if(W==j-2)W++;if(D.lJ.Font!=null)w.ResourceDict.FontSet=D.JO.slice(0);if(n<=W)hd.asU(w.EngineDict.StyleRun,D.lJ,n,W,!0);
hd.asU(w.EngineDict.ParagraphRun,D.ci,n,W,!1)};hd.tG=function(w,n,W){var D={JO:w.ResourceDict.FontSet.slice(0),lJ:[],ci:[]},j=w.EngineDict.StyleRun.RunLengthArray,I=hd.Rt(j,n).Pb,U=hd.Rt(j,W).Pb;
for(var L=I;L<=U;L++){var M=hd.iJ(w.ResourceDict.StyleSheetSet[0].StyleSheetData),m=w.EngineDict.StyleRun.RunArray;
if(m.length==0)continue;var l=m[L].StyleSheet.StyleSheetData;hd.J9(M,l);D.lJ.push(M)}var A=w.EngineDict.ParagraphRun.RunLengthArray,g=hd.Rt(A,n).Pb,k=hd.Rt(A,W).Pb;
for(var L=g;L<=k;L++){var $=w.EngineDict.ParagraphRun.RunArray;if($.length==0)continue;D.ci.push(hd.iJ($[L].ParagraphSheet.Properties))}D.lJ=D.lJ.length==0?{}:hd.y9(D.lJ);
D.ci=D.ci.length==0?{}:hd.y9(D.ci);return D};hd.asU=function(w,n,W,D,j){var I=w.RunLengthArray;if(j){var U=hd.Rt(I,W);
if(U.sp!=W){var M=I[U.Pb];I.splice(U.Pb,0,W-U.sp);I[U.Pb+1]=M-I[U.Pb];w.RunArray.splice(U.Pb+1,0,hd.iJ(w.RunArray[U.Pb]))}var m=hd.Rt(I,D);
if(m.sp+I[m.Pb]-1!=D){var M=I[m.Pb];I.splice(m.Pb,0,D-m.sp+1);I[m.Pb+1]=M-I[m.Pb];w.RunArray.splice(m.Pb+1,0,hd.iJ(w.RunArray[m.Pb]))}}var U=hd.Rt(I,W),m=hd.Rt(I,D);
if(j)for(var L=U.Pb;L<=m.Pb;L++)hd.J9(w.RunArray[L].StyleSheet.StyleSheetData,n);else for(var L=U.Pb;
L<=m.Pb;L++)hd.J9(w.RunArray[L].ParagraphSheet.Properties,n)};hd.aw7=function(w,n,W){var D=w.EngineDict.StyleRun.RunLengthArray,j=[],I=0;
for(var L=0;L<D.length;L++){var U=D[L];for(var M=0;M<U;M++)if(n<=I+M&&I+M<W)j.push(L);I+=U}var m=j[0],l=[];
for(var L=0;L<j.length;L++){var A=j[L]-m;if(A==l.length)l.push(0);l[A]++}return l};hd.ad8=function(w){var n=w.EngineDict.StyleRun,W=n.RunArray,D=n.RunLengthArray;
for(var L=0;L<D.length-1;L++){var j=W[L].StyleSheet.StyleSheetData,I=W[L+1].StyleSheet.StyleSheetData;
if(JSON.stringify(j)==JSON.stringify(I)){W.splice(L+1,1);D[L]+=D[L+1];D.splice(L+1,1);L--}}};hd.J8=function(w){var n=w.lz.AntA.v.Annt;
n=["Anno","antiAliasSharp","AnCr","AnSt","AnSm"].indexOf(n);if(n==-1)n=1;return n};hd.Yg=function(w,n){w.lz.AntA.v.Annt=["Anno","antiAliasSharp","AnCr","AnSt","AnSm"][n]};
hd.mh=function(w,n){var W,D;W=["FontSize","Leading","BaselineShift","_LineWidth"];D=w.lJ;for(var L=0;
L<W.length;L++)if(D[W[L]]!=null)D[W[L]]*=n;W=["StartIndent","EndIndent","FirstLineIndent","SpaceBefore","SpaceAfter"];
D=w.ci;for(var L=0;L<W.length;L++)if(D[W[L]]!=null)D[W[L]]*=n};hd.a9Q=function(){return hd.tG(hd.aea,0,0)};
hd.ah1=function(){return{classID:"TxLr",Txt:{t:"TEXT",v:"\0"},textGridding:{t:"enum",v:{textGridding:"None"}},Ornt:{t:"enum",v:{Ornt:"Hrzn"}},AntA:{t:"enum",v:{Annt:"antiAliasSharp"}},TextIndex:{t:"long",v:0}}};
hd.Rt=function(w,n){var W=0,L=0;while(W+w[L]<=n){W+=w[L];L++}return{Pb:L,sp:W}};hd.amo=function(){var w=hd.iJ(this.aea);
return w};hd.a51=function(w,n){var W=n.ci};hd.a6B=function(w,n){var W=n.lJ,D;D=w.Undl;if(D&&D.v.Undl=="underlineOnLeftInVertical")W.Underline=!0;
D=w.syntheticItalic;if(D)W.FauxItalic=D.v};hd.aga={Justification:0,FirstLineIndent:0,StartIndent:0,EndIndent:0,SpaceBefore:0,SpaceAfter:0,AutoHyphenate:!1,HyphenatedWordSize:6,PreHyphen:2,PostHyphen:2,ConsecutiveHyphens:8,Zone:36,WordSpacing:[.8,1,1.33],LetterSpacing:[0,0,0],GlyphSpacing:[1,1,1],AutoLeading:1.2,LeadingType:0,Hanging:!1,Burasagari:!1,KinsokuOrder:0,EveryLineComposer:!1,_Direction:0,_ComposerEngine:1};
hd.apL={Font:0,FontSize:12,FauxBold:!1,FauxItalic:!1,AutoLeading:!0,Leading:0,HorizontalScale:1,VerticalScale:1,Tracking:0,AutoKerning:!0,Kerning:0,BaselineShift:0,FontCaps:0,FontBaseline:0,Underline:!1,Strikethrough:!1,Ligatures:!0,DLigatures:!1,BaselineDirection:2,Tsume:0,StyleRunAlignment:2,Language:0,NoBreak:!1,FillColor:{Type:1,Values:[1,0,0,0]},StrokeColor:{Type:1,Values:[1,0,0,0]},_FillBackgroundColor:{Type:1,Values:[1,0,0,0]},FillFlag:!0,StrokeFlag:!1,_LineWidth:1,_FillBackgroundFlag:!1,FillFirst:!0,YUnderline:1,OutlineWidth:1,CharacterDirection:0,HindiNumbers:!1,Kashida:1,DiacriticPos:2};
hd.amY=function(){return{RunArray:[],RunLengthArray:[],IsJoinable:2}};hd.aea={EngineDict:{Editor:{Text:"\n"},ParagraphRun:{DefaultRunData:{ParagraphSheet:{DefaultStyleSheet:0,Properties:{}},Adjustments:{Axis:[1,0,1],XY:[0,0]}},RunArray:[{ParagraphSheet:{DefaultStyleSheet:0,Properties:JSON.parse(JSON.stringify(hd.aga))},Adjustments:{Axis:[1,0,1],XY:[0,0]}}],RunLengthArray:[1],IsJoinable:1},StyleRun:{DefaultRunData:{StyleSheet:{StyleSheetData:{}}},RunArray:[{StyleSheet:{StyleSheetData:{Font:0,FontSize:24,AutoKerning:!0,Kerning:0}}}],RunLengthArray:[1],IsJoinable:2},GridInfo:{GridIsOn:!1,ShowGrid:!1,GridSize:18,GridLeading:22,GridColor:{Type:1,Values:[0,0,0,1]},GridLeadingFillColor:{Type:1,Values:[0,0,0,1]},AlignLineHeightToGridFlags:!1},AntiAlias:4,UseFractionalGlyphWidths:!0,Rendered:{Version:1,Shapes:{WritingDirection:0,Children:[{ShapeType:0,Procession:0,Lines:{WritingDirection:0,Children:[]},Cookie:{Photoshop:{ShapeType:0,PointBase:[0,0],Base:{ShapeType:0,TransformPoint0:[1,0],TransformPoint1:[0,1],TransformPoint2:[0,0]}}}}]}}},ResourceDict:{KinsokuSet:[{Name:"PhotoshopKinsokuHard",NoStart:"\u3001\u3002\uFF0C\uFF0E\u30FB\uFF1A\uFF1B\uFF1F\uFF01\u30FC\u2015\u2019\u201D\uFF09\u3015\uFF3D\uFF5D\u3009\u300B\u300D\u300F\u3011\u30FD\u30FE\u309D\u309E\u3005\u3041\u3043\u3045\u3047\u3049\u3063\u3083\u3085\u3087\u308E\u30A1\u30A3\u30A5\u30A7\u30A9\u30C3\u30E3\u30E5\u30E7\u30EE\u30F5\u30F6\u309B\u309C?!)]},.:;\u2103\u2109\xA2\uFF05\u2030",NoEnd:"\u2018\u201C\uFF08\u3014\uFF3B\uFF5B\u3008\u300A\u300C\u300E\u3010([{\uFFE5\uFF04\xA3\uFF20\xA7\u3012\uFF03",Keep:"\u2015\u2025",Hanging:"\u3001\u3002.,"},{Name:"PhotoshopKinsokuSoft",NoStart:"\u3001\u3002\uFF0C\uFF0E\u30FB\uFF1A\uFF1B\uFF1F\uFF01\u2019\u201D\uFF09\u3015\uFF3D\uFF5D\u3009\u300B\u300D\u300F\u3011\u30FD\u30FE\u309D\u309E\u3005",NoEnd:"\u2018\u201C\uFF08\u3014\uFF3B\uFF5B\u3008\u300A\u300C\u300E\u3010",Keep:"\u2015\u2025",Hanging:"\u3001\u3002.,"}],MojiKumiSet:[{InternalName:"Photoshop6MojiKumiSet1"},{InternalName:"Photoshop6MojiKumiSet2"},{InternalName:"Photoshop6MojiKumiSet3"},{InternalName:"Photoshop6MojiKumiSet4"}],TheNormalStyleSheet:0,TheNormalParagraphSheet:0,ParagraphSheetSet:[{Name:"Normal RGB",DefaultStyleSheet:0,Properties:JSON.parse(JSON.stringify(hd.aga))}],StyleSheetSet:[{Name:"Normal RGB",StyleSheetData:JSON.parse(JSON.stringify(hd.apL))}],FontSet:[{Name:"DejaVuSans",Script:0,FontType:1,Synthetic:0},{Name:"AdobeInvisFont",Script:0,FontType:0,Synthetic:0},{Name:"MyriadHebrew-Regular",Script:6,FontType:0,Synthetic:0}],SuperscriptSize:.583,SuperscriptPosition:.333,SubscriptSize:.583,SubscriptPosition:.333,SmallCapSize:.7}};
var gD={};gD.anv=function(w){var n=gD.aie(w._0,w._1);gD.ads(n,w._0);return n};gD.a6F=function(w,n,W){var D={};
D._98={_0:"i7"};D._0=gD.aso(w,n,W?W._0:null);D._1=gD.acZ(w,n,D._0,W?W._1:null);return D};gD.aso=function(w,n,W){var D={};
D._1=gD.awo(w,W?W._1:null);D._2={_0:[{_0:{_0:"s"}}],_1:[{_0:"i0"}]};D._3=JSON.parse(JSON.stringify(gD.aj7));
D._4=JSON.parse(JSON.stringify(gD.a3m));D._5=gD.akh(w,D._1._0,W?W._5:null);D._6=gD.ajX(w,W?W._6:null);
D._8=gD.a2r(w,n,W?W._8:null);D._9=gD.a4R;return D};gD.ads=function(w,n){gD.avr(w,n._5,n._1._0)};gD.awo=function(w,n){var W=[],D=[];
for(var L=0;L<w.length;L++){var j=w[L].ResourceDict.FontSet;for(var I=0;I<j.length;I++){var U=j[I];if(D.indexOf(U.Name)!=-1)continue;
W.push(U);D.push(U.Name)}}var M={_0:[]};for(var L=0;L<W.length;L++){var m=W[L],l={_0:{_99:"/CoolTypeFont",_0:{_0:"s"+m.Name,_1:"i"+m.Script,_2:"i"+m.FontType}}};
if(m.Script==0)delete l._0._0._1;M._0.push(l)}return M};gD.akh=function(w,n,W){var D={_0:[],_1:[]},j={_0:JSON.parse(JSON.stringify(gD.atK))};
gD.art(j._0,w[0].ResourceDict.StyleSheetSet[0],n,w[0].ResourceDict.FontSet);D._0.push(j);D._1.push({_0:"i0"});
D._0.push({_0:{_0:"sNone",_5:"i0",_6:{}}});D._1.push({_0:"i1"});return D};gD.avr=function(w,n,W){var D=n._0[0];
for(var L=0;L<w.length;L++)gD.awh(D._0,w[L].ResourceDict.StyleSheetSet[0],W,w[L].ResourceDict.FontSet)};
gD.ajX=function(w,n){var W={_0:[],_1:[]},D={_0:JSON.parse(JSON.stringify(gD.Vn))};gD.Sw(D._0,w[0].ResourceDict.ParagraphSheetSet[0]);
W._0.push(D);W._1.push({_0:"i0"});D={_0:JSON.parse(JSON.stringify(gD.Vn))};gD.Sw(D._0,w[0].ResourceDict.ParagraphSheetSet[0]);
D._0._0="sBasic Paragraph";D._0._6="i0";W._0.push(D);W._1.push({_0:"i1"});return W};gD.a2r=function(w,n,W){var D={_0:[]};
for(var L=0;L<w.length;L++){var j=w[L].Curve,I={};D._0.push({_0:I});var U=hd.F$(w[L]);I._2={};I._2._0="i"+U;
if(w[L]._LineOrientation==2)I._2._1="i2";if(U==0){I._2._6=["f-1","f-1"];I._2._11={_4:"i-1",_7:!1}}else if(U==1&&j==null){var M=hd.Bj(w[L]),m=M[2],l=M[3];
I._1={_0:gD.sQ("f",[0,0,0,0,m,0,m,0,m,0,m,0,m,l,m,l,m,l,m,l,0,l,0,l,0,l,0,l,0,0,0,0])};I._2._6=["f-2","f-2"];
I._2._11={_4:"i-2",_7:!1}}else if(U==1){var M=hd.Bj(w[L]),m=M[2],l=M[3];I._1={_0:gD.sQ("f",j.Points)};
I._2._6=["f-3","f-3"];I._2._11={_4:"i-3",_7:!1}}else if(U==2){I._1={_0:gD.sQ("f",j.Points)};I._2._6=gD.sQ("f",j.TextOnPathTRange);
I._2._11={_0:j.Reversed,_3:"i0",_5:"f0",_7:!1}}}return D};gD.acZ=function(w,n,W,D){var j={};j._0=JSON.parse(JSON.stringify(gD.amO));
j._1=gD.arL(w,n,W,D?D._1:null);j._2=JSON.parse(JSON.stringify(gD.atK._6));j._3=JSON.parse(JSON.stringify(gD.Vn._5));
return j};gD.aie=function(w,n){return gD.amJ(w,n._1)};gD.arL=function(w,n,W,D){var j=[],I=W._1._0;for(var L=0;
L<w.length;L++){var U=w[L],M={_0:{}};j.push(M);M._0._0="s"+U.EngineDict.Editor.Text;M._0._0=M._0._0;
var m=M._0._5={_0:[]},l=U.EngineDict.ParagraphRun;for(var A=0;A<l.RunArray.length;A++){var g={_0:{}};
m._0.push(g);g._0._0={_0:"s",_5:{},_6:"i1"};gD.Sw(g._0._0,l.RunArray[A].ParagraphSheet);g._1="i"+l.RunLengthArray[A]}var k=M._0._6={_0:[]};
l=U.EngineDict.StyleRun;for(var A=0;A<l.RunArray.length;A++){var $={_0:{}};k._0.push($);$._0._0={_0:"s",_5:"i1",_6:{}};
gD.art($._0._0,l.RunArray[A].StyleSheet,I,U.ResourceDict.FontSet);$._1="i"+l.RunLengthArray[A]}l=U.EngineDict.AlternateGlyphRun;
if(l){var C=M._0._9={_0:[]};for(var A=0;A<l.RunArray.length;A++){var f={_0:{}};C._0.push(f);var z=l.RunArray[A];
if(z.Glyph!=null){f._0._0={_0:"i"+z.Glyph,_1:"e"}}f._1="i"+l.RunLengthArray[A]}}M._0._10={_0:"i4",_2:!0};
M._1=gD.view.a6A(U,null,L,null)}return j};gD.amJ=function(w,n){var W=[],D=w._1._0;for(var L=0;L<n.length;
L++){var j=hd.amo();W.push(j);var I=n[L];j.EngineDict.Editor.Text=I._0._0.slice(1);var U=j.EngineDict.ParagraphRun.RunArray[0],M=j.EngineDict.ParagraphRun,m=I._0._5;
if(m)for(var l=0;l<m._0.length;l++){var A=m._0[l];M.RunLengthArray[l]=parseInt(A._1.slice(1));M.RunArray[l]=JSON.parse(JSON.stringify(U));
gD.aiy(A._0._0,M.RunArray[l].ParagraphSheet)}else{M.RunLengthArray[0]=hd.Bb(j).length}var g=I._0._6;
M=j.EngineDict.StyleRun;if(g)for(var l=0;l<g._0.length;l++){var k=g._0[l];M.RunLengthArray[l]=parseInt(k._1.slice(1));
M.RunArray[l]={StyleSheet:{StyleSheetData:{}}};gD.awh(k._0._0,M.RunArray[l].StyleSheet,D,j.ResourceDict.FontSet)}else{M.RunLengthArray[0]=hd.Bb(j).length;
M.RunArray[0]={StyleSheet:{StyleSheetData:{}}}}}return W};gD.art=function(w,n,W,D,j){w._0="s"+(n.Name?n.Name:"");
var I=w._6,U=j?j._6:null,M=n.StyleSheetData;if(M.Font==null)return;var m=D[M.Font].Name,l=-1;for(var L=0;
L<W.length;L++)if("s"+m==W[L]._0._0._0){l=L;break}I._0="i"+l;if(M.FontSize!=null)I._1="f"+M.FontSize;
if(M.FauxBold!=null)I._2=M.FauxBold;if(M.FauxItalic!=null)I._3=M.FauxItalic;if(M.AutoLeading!=null)I._4=M.AutoLeading;
if(M.Leading!=null)I._5="f"+M.Leading;if(M.HorizontalScale!=null)I._6="f"+M.HorizontalScale;if(M.VerticalScale!=null)I._7="f"+M.VerticalScale;
if(M.Tracking!=null)I._8="i"+M.Tracking;if(M.BaselineShift!=null)I._9="f"+M.BaselineShift;if(M.AutoKerning!=null)I._11="i"+(M.AutoKerning?1:0);
if(M.FontCaps!=null)I._12="i"+M.FontCaps;if(M.FontBaseline!=null)I._13="i"+M.FontBaseline;if(M.Strikethrough!=null)I._15="i"+(M.Strikethrough?1:0);
if(M.Underline!=null)I._16="i"+(M.Underline?2:0);if(M.Ligatures!=null)I._18=M.Ligatures;if(M.DLigatures!=null)I._19=M.DLigatures;
if(M.BaselineDirection!=null)I._35="i"+M.BaselineDirection;if(M.Language!=null)I._38="i"+M.Language;
if(M.FillColor!=null)I._53=gD.Qs(M.FillColor);if(M.StrokeColor!=null)I._54=gD.Qs(M.StrokeColor);if(M.FillFlag!=null)I._56=M.FillFlag;
if(M.StrokeFlag!=null)I._57=M.StrokeFlag;if(M._LineWidth!=null)I._63="f"+M._LineWidth;if(M._FillBackgroundColor!=null)I._79=gD.Qs(M._FillBackgroundColor);
if(M._FillBackgroundFlag!=null)I._80=M._FillBackgroundFlag};gD.Qs=function(w){return{_99:"/SimplePaint",_0:{_0:"i1",_1:gD.sQ("f",w.Values)}}};
gD.awh=function(w,n,W,D){var j=w._6;if(j==null)return;var I=n.StyleSheetData;if(j._0){var U=parseInt(j._0.slice(1)),M=W[U]._0._0._0.slice(1);
hd.hI({lJ:I,JO:D},M)}if(j._1!=null)I.FontSize=parseFloat(j._1.slice(1));if(j._2!=null)I.FauxBold=j._2;
if(j._3!=null)I.FauxItalic=j._3;if(j._4!=null)I.AutoLeading=j._4;if(j._5!=null)I.Leading=parseFloat(j._5.slice(1));
if(j._6!=null)I.HorizontalScale=parseFloat(j._6.slice(1));if(j._7!=null)I.VerticalScale=parseFloat(j._7.slice(1));
if(j._8!=null)I.Tracking=parseFloat(j._8.slice(1));if(j._9!=null)I.BaselineShift=parseFloat(j._9.slice(1));
if(j._11!=null)I.AutoKerning=parseFloat(j._11.slice(1))==1;if(j._12!=null)I.FontCaps=parseFloat(j._12.slice(1));
if(j._13!=null)I.FontBaseline=parseFloat(j._13.slice(1));if(j._15!=null)I.Strikethrough=parseFloat(j._15.slice(1))==1;
if(j._16!=null)I.Underline=parseFloat(j._16.slice(1))==1;if(j._18!=null)I.Ligatures=j._18;if(j._19!=null)I.DLigatures=j._19;
if(j._35!=null)I.BaselineDirection=parseFloat(j._35.slice(1));if(j._38!=null)I.Language=parseFloat(j._38.slice(1));
if(j._53!=null)I.FillColor=gD.Hf(j._53);if(j._54!=null)I.StrokeColor=gD.Hf(j._54);if(j._56!=null)I.FillFlag=j._56;
if(j._57!=null)I.StrokeFlag=j._57;if(j._63!=null)I._LineWidth=parseFloat(j._63.slice(1));if(j._79!=null)I._FillBackgroundColor=gD.Hf(j._79);
if(j._80!=null)I._FillBackgroundFlag=j._80};gD.Hf=function(w){var n=w._0._0,W=w._0._1,D=[1,0,0,0],j=[];
for(var L=0;L<W.length;L++)j[L]=parseFloat(W[L].slice(1));if(n=="i0")D[1]=D[2]=D[3]=j[1];else if(n=="i1")D=j;
else if(n=="i2")D=[1].concat(UDOC.C.cmykToRgb(j.slice(1)));else console.log("unknown color type",n,j);
return{Type:1,Values:D}};gD.Sw=function(w,n){w._0="s"+(n.Name?n.Name:"");var W=w._5,D=n.Properties;if(D.Justification!=null)W._0="i"+D.Justification;
if(D.FirstLineIndent!=null)W._1="f"+D.FirstLineIndent;if(D.StartIndent!=null)W._2="f"+D.StartIndent;
if(D.EndIndent!=null)W._3="f"+D.EndIndent;if(D.SpaceBefore!=null)W._4="f"+D.SpaceBefore;if(D.SpaceAfter!=null)W._5="f"+D.SpaceAfter;
if(D.AutoLeading!=null)W._7="f"+D.AutoLeading;if(D.AutoHyphenate!=null)W._9=D.AutoHyphenate;if(D._Direction!=null)W._33="i"+D._Direction;
if(D._ComposerEngine!=null)W._35="i"+D._ComposerEngine};gD.aiy=function(w,n){var W=w._5;if(W==null)return;
var D=n.Properties;if(W._0)D.Justification=parseInt(W._0.slice(1))};gD.sQ=function(w,n){var W=[];for(var L=0;
L<n.length;L++)W.push(w+n[L]);return W};gD.aj7={_0:[{_0:{_0:"sPhotoshop6MojiKumiSet4",_5:{_0:"i0",_3:"i2"}}},{_0:{_0:"sPhotoshop6MojiKumiSet3",_5:{_0:"i0",_3:"i4"}}},{_0:{_0:"sPhotoshop6MojiKumiSet2",_5:{_0:"i0",_3:"i3"}}},{_0:{_0:"sPhotoshop6MojiKumiSet1",_5:{_0:"i0",_3:"i1"}}},{_0:{_0:"sYakumonoHankaku",_5:{_0:"i0",_3:"i1"}}},{_0:{_0:"sGyomatsuYakumonoHankaku",_5:{_0:"i0",_3:"i3"}}},{_0:{_0:"sGyomatsuYakumonoZenkaku",_5:{_0:"i0",_3:"i4"}}},{_0:{_0:"sYakumonoZenkaku",_5:{_0:"i0",_3:"i2"}}}],_1:[{_0:"i0"},{_0:"i1"},{_0:"i2"},{_0:"i3"},{_0:"i4"},{_0:"i5"},{_0:"i6"},{_0:"i7"}]};
gD.a3m={_0:[{_0:{_0:"sNone",_5:{_0:"s",_1:"s",_2:"s",_3:"s",_4:"i0"}}},{_0:{_0:"sPhotoshopKinsokuHard",_5:{_0:"s!),.:;?]}\xA2\u2014\u2019\u201D\u2030\u2103\u2109\u3001\u3002\u3005\u3009\u300B\u300A\u300F\u3011\u3015\u3041\u3043\u3045\u3047\u3049\u3063\u3083\u3085\u3087\u308E\u309B\u309C\u309D\u309E\u30A1\u30A3\u30A5\u30A7\u30A9\u30C3\u30E3\u30E5\u30E7\u30EE\u30F5\u30F6\u30FB\u30FC\u30FD\u30FE\uFF01\uFF05\uFF09\uFF0C\uFF0E\uFF1A\uFF1B\uFF1F\uFF3D\uFF5D",_1:"s([{\xA3\xA7\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3012\u3014\uFF03\uFF04\uFF08\uFF20\uFF3B\uFF5B\uFFE5",_2:"s\u2014\u2025\u2026",_3:"s\u3001\u3002\uFF0C\uFF0E",_4:"i1"}}},{_0:{_0:"sPhotoshopKinsokuSoft",_5:{_0:"s\u2019\u201D\u3001\u3002\u3005\u3009\u300B\u300A\u300F\u3011\u3015\u309D\u309E\u30FB\u30FD\u30FE\uFF01\uFF09\uFF0C\uFF0E\uFF1A\uFF1B\uFF1F\uFF3D\uFF5D",_1:"s\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3014\uFF08\uFF3B\uFF5B",_2:"s\u2014\u2025\u2026",_3:"s\u3001\u3002\uFF0C\uFF0E",_4:"i2"}}},{_0:{_0:"sHard",_5:{_0:"s!),.:;?]}\xA2\u2014\u2019\u201D\u2030\u2103\u2109\u3001\u3002\u3005\u3009\u300B\u300A\u300F\u3011\u3015\u3041\u3043\u3045\u3047\u3049\u3063\u3083\u3085\u3087\u308E\u309B\u309C\u309D\u309E\u30A1\u30A3\u30A5\u30A7\u30A9\u30C3\u30E3\u30E5\u30E7\u30EE\u30F5\u30F6\u30FB\u30FC\u30FD\u30FE\uFF01\uFF05\uFF09\uFF0C\uFF0E\uFF1A\uFF1B\uFF1F\uFF3D\uFF5D",_1:"s([{\xA3\xA7\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3012\u3014\uFF03\uFF04\uFF08\uFF20\uFF3B\uFF5B\uFFE5",_2:"s\u2014\u2025\u2026",_3:"s\u3001\u3002\uFF0C\uFF0E",_4:"i1"}}},{_0:{_0:"sSoft",_5:{_0:"s\u2019\u201D\u3001\u3002\u3005\u3009\u300B\u300A\u300F\u3011\u3015\u309D\u309E\u30FB\u30FD\u30FE\uFF01\uFF09\uFF0C\uFF0E\uFF1A\uFF1B\uFF1F\uFF3D\uFF5D",_1:"s\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3014\uFF08\uFF3B\uFF5B",_2:"s\u2014\u2025\u2026",_3:"s\u3001\u3002\uFF0C\uFF0E",_4:"i2"}}}],_1:[{_0:"i0"},{_0:"i1"},{_0:"i2"},{_0:"i3"},{_0:"i4"}]};
gD.atK={_0:"sNormal RGB",_6:{_0:"i0",_1:"f12",_2:!1,_3:!1,_4:!0,_5:"f0",_6:"f1",_7:"f1",_8:"i0",_9:"f0",_10:"f0",_11:"i1",_12:"i0",_13:"i0",_14:"i0",_15:"i0",_16:"i0",_17:"f0",_18:!0,_19:!1,_20:!1,_21:!1,_22:!1,_23:!1,_24:!1,_25:!1,_26:!1,_27:!1,_28:!1,_29:!1,_30:"i0",_31:!1,_32:!1,_33:!1,_34:!1,_35:"i2",_36:"f0",_37:"i2",_38:"i0",_39:"i0",_40:!1,_41:"i2",_42:"i0",_43:{_0:"f.5"},_44:"i2",_45:"i2",_46:"i7",_47:"i0",_48:"i0",_49:"f-1",_50:"f-1",_51:"i0",_52:!1,_53:{_99:"/SimplePaint",_0:{_0:"i1",_1:["f1","f0","f0","f0"]}},_54:{_99:"/SimplePaint",_0:{_0:"i1",_1:["f1","f0","f0","f0"]}},_55:{_99:"/SimpleBlender"},_56:!0,_57:!1,_58:!0,_59:!1,_60:!1,_61:"i0",_62:"i0",_63:"f1",_64:"f4",_65:"f0",_66:[],_67:[],_68:"i0",_69:"i0",_70:"i0",_71:"i4",_72:"f0",_73:"f0",_74:!1,_75:!1,_76:!1,_77:!0,_78:!0,_79:{_99:"/SimplePaint",_0:{_0:"i1",_1:["f1","f1","f1","f0"]}},_80:!1,_81:"i0",_82:"f3",_83:"f3",_84:!1,_85:"i0",_86:{_99:"/SimpleCustomFeature"},_87:"f100",_88:!0}};
gD.Vn={_0:"sNormal RGB",_5:{_0:"i0",_1:"f0",_2:"f0",_3:"f0",_4:"f0",_5:"f0",_6:"i1",_7:"f1.2",_8:"i0",_9:!0,_10:"i6",_11:"i2",_12:"i2",_13:"i0",_14:"f36",_15:!0,_16:"f.5",_17:["f.8","f1","f1.33"],_18:["f0","f0","f0"],_19:["f1","f1","f1"],_20:"i6",_21:!1,_22:"i0",_23:!0,_24:"i0",_25:"i0",_27:"/nil",_26:!1,_28:"/nil",_29:!1,_30:{},_31:"f36",_32:{},_33:"i0",_34:"i7",_35:"i1",_36:"/nil",_37:"i0",_38:!1,_39:"i0",_40:"i2"}};
gD.a4R={_0:[{_0:{_0:"skPredefinedNumericListStyleTag",_6:"i1"}},{_0:{_0:"skPredefinedUppercaseAlphaListStyleTag",_6:"i2"}},{_0:{_0:"skPredefinedLowercaseAlphaListStyleTag",_6:"i3"}},{_0:{_0:"skPredefinedUppercaseRomanNumListStyleTag",_6:"i4"}},{_0:{_0:"skPredefinedLowercaseRomanNumListStyleTag",_6:"i5"}},{_0:{_0:"skPredefinedBulletListStyleTag",_6:"i6"}}],_1:[{_0:"i0"},{_0:"i1"},{_0:"i2"},{_0:"i3"},{_0:"i4"},{_0:"i5"}]};
gD.amO={_0:{_0:"i1",_1:[{_0:"s ",_1:"s1"},{_0:"s\r",_1:"s6"},{_0:"s\t",_1:"s0"},{_0:"s\u2029",_1:"s5"},{_0:"s\x03",_1:"s5"},{_0:"s\u3000",_1:"s1"},{_0:"s\xAD",_1:"s3"}]},_1:"i0",_2:"i0",_3:"f.583",_4:"f.333",_5:"f.583",_6:"f.333",_7:"f.7",_8:!0,_9:[{_0:"i0",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i1",_1:"s\u201D",_2:"s\u201D",_3:"s\u2019",_4:"s\u2019"},{_0:"i2",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i3",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i4",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i5",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i6",_1:"s\xAB",_2:"s\xBB",_3:"s\u2039",_4:"s\u203A"},{_0:"i7",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i8",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i9",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i10",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i11",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i12",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i13",_1:"s\u201D",_2:"s\u201D",_3:"s\u2019",_4:"s\u2019"},{_0:"i14",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i15",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i16",_1:"s\u201D",_2:"s\u201D",_3:"s\u2019",_4:"s\u2019"},{_0:"i17",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i18",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i19",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i20",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i21",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i22",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i23",_1:"s\u201E",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i24",_1:"s\u201E",_2:"s\u201D",_3:"s\u201A",_4:"s\u2019"},{_0:"i25",_1:"s\xAB",_2:"s\xBB",_3:"s\u2039",_4:"s\u203A"},{_0:"i26",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i27",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i28",_1:"s\u201E",_2:"s\u201D",_3:"s\u2019",_4:"s\u2019"},{_0:"i29",_1:"s\u301D",_2:"s\u301E"},{_0:"i30",_1:"s\u300C",_2:"s\u300D"},{_0:"i31",_1:"s\u201E",_2:"s\u201C",_3:"s\u2018",_4:"s\u2019"},{_0:"i32",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i33",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i34",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i35",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i36",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i37",_1:"s\xAB",_2:"s\xBB",_3:"s\u2018",_4:"s\u2019"},{_0:"i38",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i39",_1:"s\xAB",_2:"s\xBB",_3:"s<",_4:"s>"},{_0:"i40",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i41",_1:"s\xAB",_2:"s\xBB",_3:"s<",_4:"s>"},{_0:"i42",_1:"s\u201E",_2:"s\u201C",_3:"s\u201A",_4:"s\u2018"},{_0:"i43",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"},{_0:"i44",_1:"s\xAB",_2:"s\xBB",_3:"s\u2039",_4:"s\u203A"},{_0:"i45",_1:"s\u201C",_2:"s\u201D",_3:"s\u2018",_4:"s\u2019"}],_15:{_0:"sWinSoft"},_16:!1};
var cI={};cI.a7z=function(w){return cI.ME(w,cI._C,0)};cI.avn=function(w){return cI.e1(w,cI._C)};cI.ME=function(w,n,W){var D;
if(typeof w=="string")return w;if(w instanceof Array){D=[];for(var L=0;L<w.length;L++)D[L]=cI.ME(w[L],n,W+1)}else{D={};
var j={};for(var I in n){var U=n[I],M="_"+U[0];if(w[M]!=null){D[I]=U[1]?cI.ME(w[M],U[1],W+1):w[M];j[M]=!0}}for(var I in w){if(j[I]==null){if(I.length>3)continue;
console.log(n,j);console.log(I,w);throw"e"}}}return D};cI.e1=function(w,n){var W;if(typeof w=="string")return w;
else if(w instanceof Array){W=[];for(var L=0;L<w.length;L++)W[L]=cI.e1(w[L],n)}else{W={};var D={};for(var j in n){var I=n[j],U="_"+I[0];
if(w[j]!=null){W[U]=I[1]?cI.e1(w[j],I[1]):w[j];D[j]=!0}}for(var j in w){if(D[j]==null){console.log(n,D);
console.log(j,w);throw"e"}}}return W};cI.yY={_Color:[0,{_Type:[0],_Values:[1]}],_CAIKnownStyleID:[5],_StreamTag:[99]};
cI.ik={_Font:[0],_FontSize:[1],_FauxBold:[2],_FauxItalic:[3],_AutoLeading:[4],_Leading:[5],_HorizontalScale:[6],_VerticalScale:[7],_Tracking:[8],_BaselineShift:[9],_CharacterRotation:[10],_AutoKern:[11],_FontCaps:[12],_FontBaseline:[13],_FontOTPosition:[14],_StrikethroughPosition:[15],_UnderlinePosition:[16],_UnderlineOffset:[17],_Ligatures:[18],_DiscretionaryLigatures:[19],_ContextualLigatures:[20],_AlternateLigatures:[21],_OldStyle:[22],_Fractions:[23],_Ordinals:[24],_Swash:[25],_Titling:[26],_ConnectionForms:[27],_StylisticAlternates:[28],_Ornaments:[29],_FigureStyle:[30],_ProportionalMetrics:[31],_Kana:[32],_Italics:[33],_Ruby:[34],_BaselineDirection:[35],_Tsume:[36],_StyleRunAlignment:[37],_Language:[38],_JapaneseAlternateFeature:[39],_EnableWariChu:[40],_WariChuLineCount:[41],_WariChuLineGap:[42],_WariChuSubLineAmount:[43,{_WariChuSubLineScale:[0]}],_WariChuWidowAmount:[44],_WariChuOrphanAmount:[45],_WariChuJustification:[46],_TCYUpDownAdjustment:[47],_TCYLeftRightAdjustment:[48],_LeftAki:[49],_RightAki:[50],_JiDori:[51],_NoBreak:[52],_FillColor:[53,cI.yY],_StrokeColor:[54,cI.yY],_Blend:[55,{_1:[1],_3:[3],_Knockout:[4],_StreamTag:[99]}],_FillFlag:[56],_StrokeFlag:[57],_FillFirst:[58],_FillOverPrint:[59],_StrokeOverPrint:[60],_LineCap:[61],_LineJoin:[62],_LineWidth:[63],_MiterLimit:[64],_LineDashOffset:[65],_LineDashArray:[66],_Type1EncodingNames:[67],_Kashidas:[68],_DirOverride:[69],_DigitSet:[70],_DiacVPos:[71],_DiacXOffset:[72],_DiacYOffset:[73],_OverlapSwash:[74],_JustificationAlternates:[75],_StretchedAlternates:[76],_FillVisibleFlag:[77],_StrokeVisibleFlag:[78],_FillBackgroundColor:[79,cI.yY],_FillBackgroundFlag:[80],_UnderlineStyle:[81],_DashedUnderlineGapLength:[82],_DashedUnderlineDashLength:[83],_SlashedZero:[84],_StylisticSets:[85],_CustomFeature:[86,{_StreamTag:[99]}],_MarkYDistFromBaseline:[87],_AutoMydfb:[88],_RefFontSize:[89],_FontSizeRefType:[90]};
cI.apz={_Justification:[0],_FirstLineIndent:[1],_StartIndent:[2],_EndIndent:[3],_SpaceBefore:[4],_SpaceAfter:[5],_DropCaps:[6],_AutoLeading:[7],_LeadingType:[8],_AutoHyphenate:[9],_HyphenatedWordSize:[10],_PreHyphen:[11],_PostHyphen:[12],_ConsecutiveHyphens:[13],_Zone:[14],_HyphenateCapitalized:[15],_HyphenationPreference:[16],_WordSpacing:[17],_LetterSpacing:[18],_GlyphSpacing:[19],_SingleWordJustification:[20],_Hanging:[21],_AutoTCY:[22],_KeepTogether:[23],_BurasagariType:[24],_KinsokuOrder:[25],_Kinsoku:[27],_KurikaeshiMojiShori:[26],_MojiKumiTable:[28],_EveryLineComposer:[29],_TabStops:[30],_DefaultTabWidth:[31],_DefaultStyle:[32,cI.ik],_ParagraphDirection:[33],_JustificationMethod:[34],_ComposerEngine:[35],_ListStyle:[36],_ListTier:[37],_ListSkip:[38],_ListOffset:[39],_KashidaWidth:[40]};
cI.awm={_Name:[0],_Features:[5,cI.apz],_Parent:[6],_UUID:[97]};cI.a3O={_Name:[0],_Parent:[5],_Features:[6,cI.ik],_UUID:[97]};
cI._C={_98:[98,{_0:[0]}],_DocumentResources:[0,{_0:[0],_FontSet:[1,{_Resources:[0,{_Resource:[0,{_StreamTag:[99],_Identifier:[0,{_Name:[0],_ScriptType:[1],_Type:[2],_Synthetic:[3],_4:[4],_MMAxis:[5]}],_UUID:[97]}]}],_DisplayList:[1,{_Resource:[0]}]}],_MojiKumiCodeToClassSet:[2,{_Resources:[0,{_Resource:[0,{_Name:[0],_Members:[5],_UUID:[97]}]}],_DisplayList:[1,{_Resource:[0]}]}],_MojiKumiTableSet:[3,{_Resources:[0,{_Resource:[0,{_Name:[0],_Members:[5,{_CodeToClass:[0],_AutoTsume:[1,{_TsumeMappings:[0,{_Before:[0],_After:[1],_Code:[2]}]}],_Table:[2,{_DataArray:[0,{_SparseArray:[0,{_Index:[0],_Elements:[1,{_P:[0],_Data:[1,{_A:[0,{_R:[0],_P:[1]}],_B:[1,{_R:[0],_P:[1]}]}]}]}]}]}],_PredefinedTag:[3]}],_UUID:[97]}]}],_DisplayList:[1,{_Resource:[0]}]}],_KinsokuSet:[4,{_Resources:[0,{_Resource:[0,{_Name:[0],_Data:[5,{_NoStart:[0],_NoEnd:[1],_Keep:[2],_Hanging:[3],_PredefinedTag:[4]}],_UUID:[97]}]}],_DisplayList:[1,{_Resource:[0]}]}],_StyleSheetSet:[5,{_Resources:[0,{_Resource:[0,cI.a3O]}],_DisplayList:[1,{_Resource:[0]}]}],_ParagraphSheetSet:[6,{_Resources:[0,{_Resource:[0,cI.awm]}],_DisplayList:[1,{_Resource:[0]}]}],_7:[7,{_Resources:[0,{_Resource:[0,{_0:[0,{_0:[0],_1:[1,{_0:[0]}]}],_1:[1]}]}]}],_TextFrameSet:[8,{_Resources:[0,{_Resource:[0,{_0:[0],_Bezier:[1,{_Points:[0]}],_Data:[2,{_Type:[0],_LineOrientation:[1],_FrameMatrix:[2],_4:[4],_TextOnPathTRange:[6],_RowGutter:[7],_ColumnGutter:[8],_9:[9],_FirstBaselineAlignment:[10,{_Flag:[0],_Min:[1]}],_PathData:[11,{_1:[1],_Reversed:[0],_2:[2],_3:[3],_Spacing:[4],_5:[5],_6:[6],_7:[7],_18:[18]}],_12:[12],_13:[13]}],_3:[3,{_0:[0]}],_UUID:[97]}]}]}],_ListStyleSet:[9,{_Resources:[0,{_Resource:[0,{_Name:[0],_LevelStyle:[5,{_IndentUnits:[0],_TextIndent:[1],_LabelIndent:[2],_LabelAlignment:[3],_SequenceGenerator:[5,{_Prefix:[0],_Postfix:[1],_2:[2],_CaseType:[3],_Bullet:[9],_StreamTag:[99]}],_Font:[6],_7:[7]}],_PredefinedTag:[6],_UUID:[97]}]}],_DisplayList:[1,{_Resource:[0]}]}]}],_DocumentObjects:[1,{_DocumentSettings:[0,{_HiddenGlyphFont:[0,{_AlternateGlyphFont:[0],_WhitespaceCharacterMapping:[1,{_WhitespaceCharacter:[0],_AlternateCharacter:[1]}]}],_NormalStyleSheet:[1],_NormalParagraphSheet:[2],_SuperscriptSize:[3],_SuperscriptPosition:[4],_SubscriptSize:[5],_SubscriptPosition:[6],_SmallCapSize:[7],_UseSmartQuotes:[8],_SmartQuoteSets:[9,{_Language:[0],_OpenDoubleQuote:[1],_CloseDoubleQuote:[2],_OpenSingleQuote:[3],_CloseSingleQuote:[4]}],_10:[10],_11:[11],_LinguisticSettings:[15,{_PreferredProvider:[0],_LinguisticProviderInfo:[1]}],_13:[13],_UseSmartLists:[16],_DefaultStoryDir:[17],_18:[18],_GreekingSize:[20]}],_TextObjects:[1,{_Model:[0,{_Text:[0],_ParagraphRun:[5,{_RunArray:[0,{_RunData:[0,{_ParagraphSheet:[0,cI.awm]}],_Length:[1]}]}],_StyleRun:[6,{_RunArray:[0,{_RunData:[0,{_StyleSheet:[0,cI.a3O]}],_Length:[1]}]}],_FirstKern:[7],_8:[8],_AlternateGlyphRun:[9,{_RunArray:[0,{_RunData:[0,{_AlternateGlyphSheet:[0,{_Glyph:[0],_Name:[1],_2:[2]}]}],_Length:[1]}]}],_StorySheet:[10,{_AntiAlias:[0],_1:[1],_UseFractionalGlyphWidths:[2],_3:[3],_4:[4]}],_KernRun:[15],_HyperlinkRun:[16]}],_View:[1,{_Frames:[0,{_Resource:[0]}],_RenderedData:[1,{_RunArray:[0,{_RunData:[0,{_0:[0],_LineCount:[1]}],_Length:[1]}]}],_Strikes:[2]}],_OpticalAlignment:[2]}],_OriginalNormalStyleFeatures:[2,cI.ik],_OriginalNormalParagraphFeatures:[3,cI.apz]}]};
gD.view={};gD.view.a6A=function(w,n,W,D){var j={},I=hd.F$(w);j._0=[{_0:"i"+W}];return j};function CSS(){}CSS.auE=function(w,n){var W=w.add,D=W.vmsk,j=W.vstk,I=W.lmfx,U=W.TySh,M=[],m=CSS.avz(I,W),l=w.opacity/255*(w.add.iOpa!=null?w.add.iOpa/255:1);
if(l!=1)M.push("opacity: "+l.toFixed(3));if(w.I9()&&D){var A=E.P.b3(D.i);if(!A.VY()){M.push("width: "+Math.round(A.m)+"px");
M.push("height: "+Math.round(A.n)+"px")}var g=E.P.a8l(D.i);if(g>0)M.push("border-radius: "+Math.round(g)+"px")}else if(U){var k=U._o;
if(hd.F$(k)==1){var A=hd.Bj(k);M.push("width: "+Math.round(A[2])+"px");M.push("height: "+Math.round(A[3])+"px")}CSS.a0Y(M,hd.tG(k,0,0),U.D,!1,!1,m[0])}CSS.a6S(n,I,M);
if(U==null)CSS.apZ(m,M);if(j==null||!j.strokeEnabled.v)j=ge.Qk(I);if(j&&j.strokeEnabled.v){var $=j.strokeStyleContent.v,C=$.classID,f=at.QO.EZ.indexOf(j.strokeStyleLineCapType.v.strokeStyleLineCapType),z=at.QO.join.indexOf(j.strokeStyleLineJoinType.v.strokeStyleLineJoinType),s=j.strokeStyleOpacity.v.val/100,O=j.strokeStyleLineWidth.v.val,a="";
if(C=="solidColorLayer")a=CSS.JQ($.Clr.v,s);M.push("border: "+O+"px solid "+a)}return M};CSS.a6S=function(w,n,W){if(n==null||!n.masterFXSwitch.v)return;
var D=n.dropShadowMulti.v.concat(n.innerShadowMulti.v);for(var L=0;L<D.length;L++){var j=D[L].v;if(j.enab.v){var I=j.classID=="IrSh",U=j.Dstn.v.val,M=j.lagl.v.val*Math.PI/180;
if(j.uglg&&j.uglg.v)M=w.d4()*Math.PI/180;var m=U*Math.cos(M),l=U*Math.sin(M),A=(m==0?"0 ":CSS.asg(-m)+"px ")+(l==0?"0 ":CSS.asg(l)+"px ")+j.blur.v.val/2+"px "+CSS.JQ(j.Clr.v,j.Opct.v.val/100);
if(I)W.push("box-shadow: inset "+A);else W.push("filter: drop-shadow("+A+")")}}};CSS.avz=function(w,n){var W=ge.mw(w,n),D=W[0],j=W[1],I,U;
if(D){I=CSS.JQ(D.Clr.v,n.iOpa!=null?n.iOpa/255:1)}else if(j){U=CSS.a9W(j)}return[I,U]};CSS.apZ=function(w,n){if(w[0])n.push("background-color: "+w[0]);
if(w[1])n.push("background-image: "+w[1])};CSS.Nw={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};
CSS.asg=function(bK){return""+parseFloat(bK.toFixed(3))};CSS.mn=function(w){if(w==null)return{o:0,B:0,k:0};
var n=w.indexOf("(");if(n!=-1){var W=w.slice(n+1,w.length-1).split(",");for(var L=0;L<W.length;L++){var D=W[L].trim();
W[L]=parseFloat(D)*(D.endsWith("%")?255/100:1)}return{o:W[0],B:W[1],k:W[2]}}if(w.charAt(0)!="#"){var j=CSS.Nw;
if(j[w])w=j[w];else console.log("unknown color "+w)}w=w.slice(1);if(w.length==4)w=w[0]+w[0]+w[1]+w[1]+w[2]+w[2]+w[3]+w[3];
if(w.length==3)w=w[0]+w[0]+w[1]+w[1]+w[2]+w[2];var I=-1;if(w.length==8){I=parseInt(w.slice(6),16);w=w.slice(0,6)}w=parseInt(w,16);
var U={o:w>>16&255,B:w>>8&255,k:w&255};if(I!=-1)U.dl=I;return U};CSS.JQ=function(w,n){return CSS.Dg(E.M.y_(w),n)};
CSS.Dg=function(w,n){if(n==null)n=1;var W=Math.round(w.o),D=Math.round(w.B),j=Math.round(w.k),I=W<<16|D<<8|j;
return n==1?"#"+E.$$(I):"rgba("+W+","+D+","+j+","+n+")"};CSS.a9W=function(w){var n=w.Grad.v;if(n.Clrs==null)return"";
var W=n.Clrs.v.slice(0),D=n.Trns.v.slice(0),j=w.Ofst.v,I=w.Type.v.GrdT=="Rdl"?1:0,U=(I==1?"radial":"linear")+"-gradient",M=I==0?Math.round(-w.Angl.v.val+90)+"deg":"circle at center",m=w.Rvrs.v,l=E.M.P$(n,m);
for(var L=0;L<l.length;L++){var A=l[L],g=A[1];M+=", "+CSS.Dg({o:g[0]*255,B:g[1]*255,k:g[2]*255},A[2])+" "+Math.round(A[0]*100)+"%"}return U+"("+M+")"};
CSS.a0Y=function(w,n,W,D,j,I){var U=n.lJ,M=D?1:W.NW(),m=Math.round(U.FontSize*M);w.push("font-size: "+m+"px");
var l=U.Tracking;if(!D&&l!=null&&l!=0)w.push("letter-spacing: "+Math.round(l*m/1e3)+"px");if(!U.AutoLeading)w.push("line-height: "+Math.round(U.Leading*M)+"px");
if(U.Strikethrough)w.push("text-decoration: line-through");if(U.Underline)w.push("text-decoration: underline");
if(U.FontCaps==2)w.push("text-transform: uppercase");var A=hd.y_(U.FillColor);A=[A.o,A.B,A.k].map(Math.round);
w.push((D?"fill: ":"color: ")+(I?I:"#"+E.$$(A[0]<<16|A[1]<<8|A[2])));var g=n.JO[U.Font].Name;if(g){var k=hy.sU.lY(g),$="",C=null,f=null;
if(k!=null&&g!=hy.x2(k))k=null;if(j&&k)$+="\""+g+"\", ";var z=g.toLowerCase();if(k){C=hy.Tz(k)[0];if(k["OS/2"])f=k["OS/2"].usWeightClass}else{C=CSS.aot(g);
if(z.indexOf("light")!=-1)f=300;else if(z.indexOf("medium")!=-1)f=500;else if(z.indexOf("black")!=-1||z.indexOf("extrabold")!=-1)f=800;
else if(z.indexOf("bold")!=-1)f="bold"}if(C!=null)$+="\""+C+"\"";if(f!=null)w.push("font-weight: "+f);
if(z.indexOf("italic")!=-1||z.indexOf("oblique")!=-1)w.push("font-style: italic");if($)w.push("font-family: "+$)}var s=n.ci.Justification;
if(s!=null&&s!=0)if(D){}else w.push("text-align: "+["left","right","center"][s%3])};CSS.aot=function(w){w=w.split("-")[0];
while(w.endsWith("MT")||w.endsWith("PS"))w=w.slice(0,w.length-2);var n=!0;for(var L=0;L<w.length;L++){var W=w.charAt(L);
if(!n&&W.toLowerCase()!=W){w=w.slice(0,L)+" "+w.slice(L);L++;n=!0}else n=!1}return w};function gQ(){}gQ.iY={document:!0,parent:!0,top:!0,eval:!0,postMessage:!0,UTIF:!0,PIMG:!0,LNG:!0,FNTS:!0};
gQ.V_=function(w,n){var W=Date.now(),D=w.split("\n"),j;for(var L=0;L<D.length;L++)if(D[L].trim()[0]=="#"){D[L]=""}w=D.join("\n");
try{j=acorn.parse(w)}catch(fV){console.log(fV);return}var I=JSON.parse(JSON.stringify(gQ.aH.RZ));I.__return=!1;
I.__continue=!1;I.__break=!1;I.__throw=!1;I.__fs={};I.__window={};gQ.eval(j,n,I);var U=I.__fs;if(Object.keys(U).length!=0){var M=UZIP.encode(U);
e8.save(M,"output.zip")}};gQ.eval=function(w,n,W){var D=w.type;if(!1){}else if(D=="Program"||D=="BlockStatement"){var j=w.body;
for(var L=0;L<j.length;L++){var I=j[L].type;if(I=="FunctionDeclaration")W[j[L].id.name]=j[L]}for(var L=0;
L<j.length;L++){var I=j[L].type,U=gQ.eval(j[L],n,W);if(W.__continue){W.__continue=!1;return U}if(W.__return||W.__break||W.__throw)return U}}else if(D=="ReturnStatement"){W.__return=!0;
return w.argument?gQ.Hj(w.argument,n,W):null}else if(D=="BreakStatement"){W.__break=!0}else if(D=="ContinueStatement"){W.__continue=!0}else if(D=="VariableDeclaration"){var M=w.declarations;
for(var L=0;L<M.length;L++)gQ.eval(M[L],n,W)}else if(D=="VariableDeclarator"){W[w.id.name]=w.init?gQ.Hj(w.init,n,W):null}else if(D=="FunctionDeclaration"){W[w.id.name]=w}else if(D=="MemberExpression"){var m=gQ.Hj(w.object,n,W),l=w.computed?gQ.Hj(w.property,n,W):gQ.eval(w.property,n,W),U;
if(m.zC!=null)U=gQ.aH.c7(m,l,n,W);else if(m==window&&gQ.iY[l]){}else U=m[l];return U}else if(D=="ArrayExpression"){var A=[],g=w.elements;
for(var L=0;L<g.length;L++)A.push(gQ.Hj(g[L],n,W));return A}else if(D=="ObjectExpression"){var A={},g=w.properties;
for(var L=0;L<g.length;L++){var k=g[L],$=g[L].key.name?g[L].key.name:g[L].key.value;A[$]=gQ.Hj(g[L].value,n,W)}return A}else if(D=="ExpressionStatement"){return gQ.eval(w.expression,n,W)}else if(D=="NewExpression"){var C=w.arguments,f=w.callee,z=f.type,s=f.name,O=[],A=null;
for(var L=0;L<C.length;L++)O.push(gQ.Hj(C[L],n,W));if(s=="Array")A=new window[s];else if(z=="Identifier")A=gQ.aH.avF(s,O,n,W);
else throw"e";if(A==null)throw"new "+s;return A}else if(D=="CallExpression"){var C=w.arguments,f=w.callee,z=f.type,a={};
for(var X in W)a[X]=W[X];var O=[];for(var L=0;L<C.length;L++)O.push(gQ.Hj(C[L],n,W));if(z=="Identifier"){var P=f.name,Z=W[P];
if(Z){if(Z.params){var Y=Z.params;for(var L=0;L<Y.length;L++)a[Y[L].name]=O[L];return gQ.eval(Z.body,n,a)}else{return Z.apply(null,O)}}else if(gQ.aH.afH.indexOf(P)!=-1)return gQ.aH.yS({zC:"Application"},P,O,n,W);
else if(window[P]==null)console.log("Unknown function "+P);else if(gQ.iY[P])alert(P+"() not available");
else{var K=window[P].apply(window,O);return K}}else if(z=="MemberExpression"){var m=gQ.Hj(f.object,n,W),l=f.computed?gQ.Hj(f.property,n,W):gQ.eval(f.property,n,W);
if(m==window&&gQ.iY[l])return;if(m.zC!=null)return gQ.aH.yS(m,l,O,n,W);else if(l=="sort"&&m[0]&&m[0].zC=="Layer"){return m.sort(function(r,p){return r.Z.getName()>p.Z.getName()?1:-1})}else return m[l].apply(m,O)}else if(z=="FunctionExpression"){return gQ.eval(f.body,n,W)}else console.log(w)}else if(D=="AssignmentExpression"){var S=w.operator,G=w.left,V=G.type,T=gQ.Hj(G,n,W),R=gQ.Hj(w.right,n,W),U=null;
if(!1){}else if(S=="=")U=R;else if(S=="+=")U=T+R;else if(S=="-=")U=T-R;else if(S=="*=")U=T*R;else if(S=="/=")U=T/R;
else if(S=="%=")U=T%R;else if(S=="&=")U=T&R;else if(S=="|=")U=T|R;else if(S=="&&=")U=T&&R;else if(S=="||=")U=T||R;
else console.log(w);if(V=="Identifier"){var x=G.name;if(W.hasOwnProperty(x))W[x]=U;else W.__window[x]=U}else if(V=="MemberExpression"){var v=gQ.eval(G.property,n,W),N=gQ.Hj(G.object,n,W);
if(N.zC!=null)gQ.aH.a3u(N,v,U,n,W);else N[v]=U}else console.log(w)}else if(D=="Identifier")return w.name;
else if(D=="Literal")return w.value;else if(D=="UpdateExpression"){var S=w.operator,u=w.argument.name,A=gQ.Hj(w.argument,n,W),H=W;
if(H[u]==null)H=W.__window;if(!1){}else if(S=="++"){H[u]++;return w.prefix?H[u]:H[u]-1}else if(S=="--"){H[u]--;
return w.prefix?H[u]:H[u]+1}else console.log(w)}else if(D=="UnaryExpression"){var S=w.operator,F=gQ.Hj(w.argument,n,W);
if(F.zC=="UnitValue"){if(S=="-")return-F.Z;else return gQ.ayk(F.Z,S)}else return gQ.ayk(F,S)}else if(D=="BinaryExpression"||D=="LogicalExpression"){var S=w.operator,G=gQ.Hj(w.left,n,W),F=gQ.Hj(w.right,n,W);
if(G==null||F==null)return gQ.Gr(G,F,S);else if(G.zC=="UnitValue"&&F.zC=="UnitValue")return gQ.Gr(G.Z,F.Z,S);
else if(G.zC=="UnitValue")return gQ.Gr(G.Z,F,S);else if(F.zC=="UnitValue"){if(S=="-")return-(G-F.Z);
else return gQ.Gr(G,F.Z,S)}else return gQ.Gr(G,F,S)}else if(D=="IfStatement"){var t=gQ.Hj(w.test,n,W);
if(t)return gQ.eval(w.consequent,n,W);else if(w.alternate)return gQ.eval(w.alternate,n,W)}else if(D=="ConditionalExpression"){var t=gQ.Hj(w.test,n,W);
if(t)return gQ.Hj(w.consequent,n,W);else if(w.alternate)return gQ.Hj(w.alternate,n,W)}else if(D=="ForInStatement"){gQ.eval(w.left,n,W);
var o=w.left.declarations[0].id.name,q=gQ.Hj(w.right,n,W);for(var X in q){W[o]=X;var _=gQ.eval(w.body,n,W);
if(W.__break)break;if(W.__return)return _}W.__break=!1}else if(D=="ForStatement"){gQ.eval(w.init,n,W);
while(gQ.eval(w.test,n,W)){var _=gQ.eval(w.body,n,W);if(W.__break)break;if(W.__return)return _;gQ.eval(w.update,n,W)}W.__break=!1}else if(D=="DoWhileStatement"){do{var _=gQ.eval(w.body,n,W);
if(W.__break)break;if(W.__return)return _}while(gQ.eval(w.test,n,W));W.__break=!1}else if(D=="TryStatement"){gQ.eval(w.block,n,W);
if(W.__throw){var d=w.handler;W[d.param.name]=W.__throw;W.__throw=!1;gQ.eval(d.body,n,W);delete W[d.param.name]}}else if(D=="EmptyStatement"){}else console.log(w)};
gQ.Gr=function(w,n,W){if(W=="+")return w+n;else if(W=="-")return w-n;else if(W=="*")return w*n;else if(W=="/")return w/n;
else if(W=="%")return w%n;else if(W=="^")return w^n;else if(W=="&")return w&n;else if(W=="&&")return w&&n;
else if(W=="|")return w|n;else if(W=="||")return w||n;else if(W=="<")return w<n;else if(W==">")return w>n;
else if(W=="=="){if(w.zC&&n.zC)return w.Z==n.Z;return w==n}else if(W=="===")return w===n;else if(W=="<=")return w<=n;
else if(W==">=")return w>=n;else if(W=="!=")return w!=n;else if(W=="!==")return w!==n;else if(W=="<<")return w<<n;
else if(W==">>")return w>>n;else console.log(W)};gQ.ayk=function(w,n){if(n=="-")return-w;else if(n=="!")return!w;
else if(n=="~")return~w;else if(n=="+")return w;else if(n=="typeof")return typeof w;else console.log(n,w)};
gQ.Hj=function(w,n,W){var D=w.type;if(D=="Identifier")return gQ.ag2(w.name,n,W);else return gQ.eval(w,n,W)};
gQ.ag2=function(w,n,W){if(w=="undefined")return undefined;else if(W.hasOwnProperty(w))return W[w];else if(w=="app")return{zC:"Application"};
else if(w=="Folder")return{zC:"Folder"};else if(w=="$")return{zC:"$"};else if(gQ.aH.ajc.indexOf(w)!=-1)return gQ.aH.c7({zC:"Application"},w,n,W);
else if(W.__window.hasOwnProperty(w))return W.__window[w];else if(window[w]&&!gQ.iY[w])return window[w];
else{W[w]=null;return null}};gQ.aH={};gQ.aH.avF=function(w,n,W,D){var j;if(w=="SolidColor")j={zC:w,Z:[1,0,0,0]};
if(w=="RGBColor")j={zC:w,Z:[1,0,0,0]};if(w=="Window")j={zC:w,Z:new kw(n[0],n[1],n[2])};if(w=="ExportOptionsSaveForWeb")j={zC:w,Z:{$x:"png",B9:100}};
if(w=="PhotoshopSaveOptions")j={zC:w,Z:{$x:"psd"}};if(w=="PNGSaveOptions")j={zC:w,Z:{$x:"png",B9:100}};
if(w=="JPEGSaveOptions")j={zC:w,Z:{$x:"jpg",B9:100}};if(w=="PDFSaveOptions")j={zC:w,Z:{$x:"pdf",a0k:""}};
if(w=="File")j={zC:w,Z:n[0]};if(w=="ActionReference")j={zC:w,Z:[]};if(w=="ActionDescriptor")j={zC:w,Z:{}};
if(w=="ActionList")j={zC:w,Z:[]};if(w=="UnitValue")j={zC:w,Z:n.length==0?0:parseFloat(n[0])};return j};
gQ.aH.ajc="activeDocument documents fonts preferences displayDialogs foregroundColor backgroundColor version".split(" ");
gQ.aH.afH="charIDToTypeID stringIDToTypeID typeIDToStringID executeAction executeActionGet doAction showWindow".split(" ");
gQ.aH.c7=function(w,n,W,D){var j=W.Ir,I=W.Nc();if(!1){}else if(n=="typename"){if(w.zC=="Layer")return w.Z.ue()?"LayerSet":"ArtLayer";
else return w.zC}else if(["Document","Layer"].indexOf(w.zC)!=-1&&["layers","artLayers","layerSets"].indexOf(n)!=-1){var U=I;
if(w.zC=="Document")U=w.Z;else U=w.LK;var M=U.root,m={zC:"Layers",axU:n,Z:[],LK:U};if(w.zC=="Layer")M=U.root.fs(U.C.indexOf(w.Z));
if(M.children==null)return null;for(var L=0;L<M.children.length;L++){var l=M.children[L].j,A=l.ue();
if(A&&n=="artLayers"||!A&&n=="layerSets")continue;m.Z.push({zC:"Layer",Z:l,LK:U})}m.Z.reverse();return m}else if(w.zC=="Documents"||w.zC=="Layers"||w.zC=="HistoryStates"||w.zC=="LayerComps"){if(!1){}else if(n=="length")return w.Z.length;
else if(Number.isInteger(n))return w.Z[n];else console.log(w.zC+": unknown property ",n)}else if(w.zC=="Application"){if(!1){}else if(n=="activeDocument")return{zC:"Document",Z:W.Nc()};
else if(n=="documents"){var m={zC:"Documents",Z:[]};for(var L=0;L<W.oZ.length;L++)m.Z.push({zC:"Document",Z:W.oZ[L]});
return m}else if(n=="fonts")return{zC:"TextFonts"};else if(n=="preferences")return{zC:"Preferences"};
else if(n=="displayDialogs")return{zC:"DialogModes"};else if(n=="foregroundColor"||n=="backgroundColor"){var g=n[0]=="f"?j.Gp:j.as;
return{zC:"SolidColor",Z:[1,(g>>>16&255)/255,(g>>>8&255)/255,(g>>>0&255)/255]}}else if(n=="UI")return{zC:"UI"};
else if(n=="version")return 30;else console.log(w,n)}else if(w.zC=="Document"){var I=w.Z;if(!1){}else if(n=="activeLayer"){var l=I.C[I.g[0]];
return{zC:"Layer",Z:l,LK:I}}else if(n=="resolution")return I.hh;else if(n=="width")return I.m;else if(n=="height")return I.n;
else if(n=="name")return I.name;else if(n=="saved")return!I.VO();else if(n=="selection")return{zC:"Selection"};
else if(n=="activeHistoryState")return{zC:"HistoryState",p_:I.QQ};else if(n=="source")return I.ea;else if(n=="layerComps"){var k=I.kO.list.v,$=[];
for(var L=0;L<k.length;L++)$.push({zC:"LayerComp",Z:L});return{zC:"LayerComps",Z:$}}else if(n=="historyStates"){var C=[];
for(var L=0;L<I.history.length;L++)C.push({zC:"HistoryState",p_:L});return{zC:"HistoryStates",Z:C}}else if(n=="mode")return 7;
else console.log(w,n)}else if(w.zC=="LayerComp"){if(n=="name")return I.kO.list.v[w.Z].v.Nm.v;else throw n}else if(w.zC=="Layer"){var f={transparentPixelsLocked:0,pixelsLocked:1,positionLocked:2,allLocked:31},l=w.Z;
if(!1){}else if(n=="visible")return l.I4();else if(n=="selected")return I.g.indexOf(I.C.indexOf(l))!=-1;
else if(n=="grouped")return l.QY;else if(f[n]!=null)return l.m7(f[n]);else if(n=="opacity")return l.opacity*100/255;
else if(n=="blendMode")return l.Bx;else if(n=="name")return l.getName();else if(n=="textItem")return{zC:"TextItem",Z:l};
else if(n=="bounds"){var z=y.wR.pJ(I,[I.C.indexOf(l)]);return gQ.aH.a4d(z,I)}else if(n=="parent"){var s=W.oZ,U;
for(var L=0;L<s.length;L++)if(s[L].C.indexOf(l)!=-1)U=s[L];var O=U.root.fs(U.C.indexOf(l)).parent;return O.depth==0?{zC:"Document",Z:U}:{zC:"Layer",Z:O.j,LK:U}}else if(n=="kind"){var a=gQ.aH.Pi;
for(var L=0;L<a.length;L++)if(l.add[a[L]]!=null)return L;return 0}else if(n=="isBackgroundLayer")return l.add.lnsr="bgnd";
else console.log(w,n)}else if(w.zC=="Selection"){if(!1){}else if(n=="bounds"){if(I.J==null)D.__throw={message:"no selection"};
else return gQ.aH.a4d(I.J.rect,I)}else console.log(w,n)}else if(w.zC=="TextItem"){var X=w.Z.add.TySh,P=X._o,Z=hd.Bb(P),Y=X.D.NW(),K=hd.tG(P,0,Math.max(0,Z.length-2));
if(n=="contents")return Z.slice(0,Z.length-1).replace(/\n/g,"\r");else if(n=="font")return K.lJ.Font!=null?K.JO[K.lJ.Font].Name:null;
else if(n=="size")return gQ.aH.Hy(K.lJ.FontSize*Y,I);else if(n=="leading")return gQ.aH.Hy(K.lJ.Leading*Y,I);
else if(n=="tracking")return gQ.aH.Hy(K.lJ.Tracking);else if(n=="baselineShift")return gQ.aH.Hy(K.lJ.BaselineShift);
else if(n=="fauxBold")return K.lJ.FauxBold;else if(n=="fauxItalic")return K.lJ.FauxItalic;else if(n=="kind")return 1-hd.F$(P);
else if(n=="useAutoLeading")return K.ci.AutoLeading;else if(n=="hyphenation")return K.ci.AutoHyphenate;
else if(n=="justification")return gQ.aH.Hy(K.ci.Justification);else if(n=="color")return{zC:"SolidColor",Z:K.lJ.FillColor.Values.slice(0)};
else if(n=="width"||n=="height"){var S=hd.Bj(P),G=(S[2]-S[0])*Y,V=(S[3]-S[1])*Y;return gQ.aH.Hy(n=="width"?G:V,I)}else if(n=="position"){var T=X.D;
return gQ.aH.ayv([T.z2,T.EU],I)}else if(n=="horizontalScale"||n=="verticalScale"){var R=n[0].toUpperCase()+n.slice(1);
return Math.round(K.lJ[R]*100)}else if(n=="antiAliasMethod")hd.J8(X);else if(n=="totalTextStyle"){var m={};
for(var x=0;x<2;x++){var v=["Style","Paragraph"][x],N=P.EngineDict[v+"Run"].RunLengthArray,u=[],H=0;
for(var L=0;L<N.length;L++){var F=hd.tG(P,H,Math.min(H+N[L],Z.length-2));H+=N[L];u.push(x==0?F.lJ:F.ci);
m.fontSet=F.JO}m[v]={runs:N,styles:u}}return JSON.stringify(m)}else if(n=="transform"){var T=X.D;return JSON.stringify([T.dl,T.k,T.Cj,T.j7,T.z2,T.EU])}else console.log(w,n)}else if(w.zC=="Preferences"){if(n=="rulerUnits")return j.M3.Lf;
else console.log(w,n)}else if(w.zC=="SolidColor"){if(n=="rgb")return{zC:"RGBColor",Z:w.Z};else console.log(w,n)}else if(w.zC=="RGBColor"){var z=Math.round(255*w.Z[1]),t=Math.round(255*w.Z[2]),o=Math.round(255*w.Z[3]);
if(!1){}else if(n=="red")return z;else if(n=="green")return t;else if(n=="blue")return o;else if(n=="hexValue")return"#"+E.$$(z<<16|t<<8|o).toUpperCase();
else console.log(w,n)}else if(w.zC=="UnitValue"){if(n=="value")return w.Z;else throw"e"}else if(w.zC=="ExportOptionsSaveForWeb"){if(n=="format")return w.Z.$x;
else if(n=="PNG8"||n=="interlaced")return!1;else if(n=="quality")return w.Z.B9;else if(n=="transparency")return!0;
else throw n}else if(w.zC=="PNGSaveOptions"||w.zC=="JPEGSaveOptions"||w.zC=="PDFSaveOptions"){return 0}else if(w.zC=="$"){if(n=="localize")return!1}else if(w.zC=="ActionList"){if(n=="count")return w.bC.length;
else throw n}else console.log(w,n)};gQ.aH.a4d=function(w,n){return gQ.aH.ayv([w.x,w.y,w.x+w.m,w.y+w.n],n)};
gQ.aH.ayv=function(w,n){var W=[];for(var L=0;L<w.length;L++)W.push(gQ.aH.Hy(w[L],n));return W};gQ.aH.alO=function(w){var n=[];
for(var L=0;L<w.length;L++)n.push(w[L].zC?w[L].Z:w[L]);return n};gQ.aH.Hy=function(w,n){return{zC:"UnitValue",Z:w}};
gQ.aH.afM=function(w,n){if(w.zC=="UnitValue")return w.Z;return w};gQ.aH.a3u=function(w,n,W,D,j){var I=new ed(b.E.v,!0),U=new ed(b.E.L,!0),M=D.Nc(),m=D.Ir;
if(!1){}else if(w.zC=="Application"){if(!1){}else if(n=="activeDocument"){U.data={d:b.c.dH,On:W.Z};D.S(U)}else if(n=="displayDialogs"){}else if(n=="foregroundColor"||n=="backgroundColor"){var l=W.Z,A=l[1]*255<<16|l[2]*255<<8|l[3]*255<<0;
U.data={d:b.c.oj,AH:bk.X$,vK:n=="foregroundColor"?0:1,Z:A};D.S(U)}else console.log(w,n,W)}else if(w.zC=="Document"){var g=w.Z;
if(!1){}else if(n=="name"){I.G=y.Yu;I.data={d:h.w2,Z:W,a4K:!0,b2:g};M.tL=!0}else if(n=="source")g.ea=W;
else if(n=="activeLayer"){g.g=[g.C.indexOf(W.Z)]}else if(n=="activeHistoryState"){I.G=y.eb;I.data={d:"h_itemchange",index:W.p_}}else console.log(w,n)}else if(w.zC=="Layer"){I.G=y.Yu;
var k={transparentPixelsLocked:0,pixelsLocked:1,positionLocked:2,allLocked:31},$=w.Z,C=M.C.indexOf($);
if(!1){}else if(n=="visible"){if($.I4()!=W)I.data={d:h.Ll,j:C}}else if(n=="opacity"){I.data={d:h.JM,j:C,qY:Math.round(255*W/100)}}else if(n=="blendMode"){I.data={d:h.jC,j:C,qY:dD.mS.indexOf(W)}}else if(n=="name"){I.data={d:h.Bl,j:C,name:W}}else if(k[n]!=null){I.data={d:h.ge,j:C,qY:[[W],[k[n]]]}}else if(n=="kind"){I.data={d:h.Wm,j:C,qp:gQ.aH.Pi[W]}}else if(n=="grouped"){I.data={d:h.Yt,j:C,qY:W}}else console.log(w,n,W)}else if(w.zC=="TextItem"){I.G=y.Lu;
var $=w.Z,f=$.add.TySh,s=JSON.parse(JSON.stringify(f._o)),O=f.D.clone(),a=f.D.NW(),X=hd.Bb(s),P=hd.tG(s,0,X.length-2),Z=!1;
if(!1){}else if(n=="contents"){hd.Ec(s,0,X.length-1);hd.KO(s,0,W.replace(/\r/g,"\n"))}else if(n=="size"){P.lJ.FontSize=(W.Z!=null?W.Z:W)/a;
Z=!0}else if(n=="leading"){P.lJ.Leading=(W.Z!=null?W.Z:W)/a;Z=!0}else if(n=="tracking"){P.lJ.Tracking=W.Z!=null?W.Z:W;
Z=!0}else if(n=="baselineShift"){P.lJ.BaselineShift=W.Z!=null?W.Z:W;Z=!0}else if(n=="fauxBold"){P.lJ.FauxBold=W;
Z=!0}else if(n=="fauxItalic"){P.lJ.FauxItalic=W;Z=!0}else if(n=="kind"){var Y=hd.F$(s);if(Y==1&&W==1){var K=new d2(s,D.Ir.hY).ci[0],S=K.Uv[0].end,G=K.yr[S-1].end;
hd.Ec(s,0,X.length-1);hd.KO(s,0,X.slice(0,G-1))}if(Y==W)hd.VL(s,1-W)}else if(n=="useAutoLeading"){P.ci.AutoLeading=W;
Z=!0}else if(n=="hyphenation"){P.ci.AutoHyphenate=W;Z=!0}else if(n=="justification"){P.ci.Justification=W;
Z=!0}else if(n=="font"){hd.hI(P,W);Z=!0}else if(n=="color"){P.lJ.FillColor.Values=W.Z.slice(0);Z=!0}else if(n=="width"||n=="height"){var V=hd.Bj(s).slice(0),T=gQ.aH.afM(W);
if(n=="width")V[2]=Math.round(V[0]+T/a);else V[3]=Math.round(V[1]+T/a);hd.sV(s,V)}else if(n=="position"){O.z2=W[0];
O.EU=W[1]}else if(n=="horizontalScale"||n=="verticalScale"){var R=n[0].toUpperCase()+n.slice(1);P.lJ[R]=W/100;
Z=!0}else if(n=="antiAliasMethod")hd.Yg(f,W);else console.log(w,n,W);if(Z)hd.g0(s,0,X.length-1,P);I.data={d:"newED",$Z:M.C.indexOf($),xw:s,D:O}}else if(w.zC=="Preferences"){if(!1){}else if(n=="rulerUnits"){var x=JSON.parse(JSON.stringify(m.M3));
x.Lf=W;U.data={d:b.c.oj,AH:bk.OS,qY:x};D.S(U)}else console.log(w,n,W)}else if(w.zC=="SolidColor"){if(n=="rgb")w.Z=W.Z;
else throw n}else if(w.zC=="RGBColor"){if(!1){}else if(n=="red")w.Z[1]=W/255;else if(n=="green")w.Z[2]=W/255;
else if(n=="blue")w.Z[3]=W/255;else if(n=="hexValue"){var v=E.lO(W.slice(1));w.Z[1]=(v>>>16&255)/255;
w.Z[2]=(v>>>8&255)/255;w.Z[3]=(v>>>0&255)/255}else console.log(w,n)}else if(w.zC=="ExportOptionsSaveForWeb"){if(n=="format")w.Z.$x=W;
else if(n=="PNG8"||n=="transparency"||n=="interlaced"){}else if(n=="quality")w.Z.B9=W;else throw n}else if(w.zC=="PNGSaveOptions"||w.zC=="JPEGSaveOptions"){if(n=="quality")w.Z.B9=Math.round(100*W/12)}else if(w.zC=="PDFSaveOptions"){if(n=="preset")w.Z.a0k=W}else if(w.zC=="$"){if(n=="localize"){}}else console.log(w,n,W);
if(I.data!=null)D.S(I)};gQ.aH.yS=function(w,n,W,D,j){var I=w.zC,U=null,M=new ed(b.E.v,!0),m=new ed(b.E.W1,!0),l=new ed(b.E.L,!0),A=D.Nc(),g=D.oZ;
if(!1){}else if(I=="Application"){if(!1){}else if(n=="charIDToTypeID"){var k=W[0].trim(),$={slct:"select",Dlt:"delete",Mk:"make"};
return $[k]?$[k]:k}else if(n=="stringIDToTypeID"){var C=W[0].trim(),$={red:"Rd",blue:"Bl",color:"Clr",RGBColor:"RGBC",type:"Type",using:"Usng"},f=$[C];
return f==null?C:f}else if(n=="typeIDToStringID"){return W[0].trim()}else if(n=="executeAction"){console.log(W);
var s;if(W[1]){s=W[1].Z;s.classID=W[0]}var O={setd:"set"},a=O[W[0]];if(a==null)a=W[0];var X=eH.SM[W[0]];
if(X&&eH.Hc[X])a=eH.Hc[X];m.data={hZ:a,E3:s}}else if(n=="executeActionGet"){return{zC:"ActionDescriptor",Z:{classID:"null",null:{t:"obj ",v:W[0].Z}},bC:A.C[A.g[0]]}}else if(n=="doAction"){l.data={d:b.c.if,HD:[W[0],W[1]]}}else if(n=="bringToFront"){}else if(n=="open"){l.data={d:b.c.VR,AH:{url:W[0]}};
if(W[2]&&g.length!=0)l.data.AH.ev=g.indexOf(A)}else if(n=="echoToOE"){l.data={d:b.c.vN,AH:W[0]}}else if(n=="showWindow"){l.data={d:b.c.P2,jW:W[0]}}else console.log(n)}else if(I=="LayerComp"){if(n=="apply"){M.G=y.q$;
M.data={d:"setLC",p_:A.kO.list.v[w.Z].v.compID.v}}else throw n}else if(I=="Document"){var A=w.Z;if(!1){}else if(n=="crop"){m.data=y.QJ.a9T(W[0])}else if(n=="trim"){var P=[];
for(var L=0;L<4;L++)P.push(W[L+1]!=null?W[L+1]:!0);m.data=y.QJ.Mf(W[0]!=null?W[0]:0,P)}else if(n=="suspendHistory"){var Z=acorn.parse(W[1]);
gQ.eval(Z,D,j)}else if(n=="save"){l.data={d:b.c.LI}}else if(n=="saveToOE"){l.data={d:b.c.LI,mP:W}}else if(n=="rotateCanvas"){m.data=y.wR.CO(!0,W[0])}else if(n=="resizeImage"||n=="resizeCanvas"){var Y=W[0],K=W[1];
if(typeof Y!="number"){Y=A.m*parseFloat(Y.slice(0,Y.length-1))/100;K=A.n*parseFloat(K.slice(0,K.length-1))/100}if(n=="resizeCanvas")m.data=y.QJ.a94(Math.round(Y),Math.round(K),W[2]);
else m.data=y.QJ.axS(Math.round(Y),Math.round(K),null,1)}else if(n=="paste"){l.data={d:b.c.s_,dV:W.length!=0&&W[0],bh:!0}}else if(n=="close"){l.data={d:b.c.L1,Pk:A}}else if(n=="exportDocument"||n=="saveAs"){var S=j.__fs,G=n=="exportDocument"?W[2].Z:W[1].Z,V=W[0].Z.replace(":","").replace("~/","");
if(!V.toLowerCase().endsWith("."+G.$x))V+="."+G.$x;var T=jj.rk(A,G.$x,null,null,G.$x=="pdf"?null:[G.B9],D.Ir);
S[V]=new Uint8Array(T)}else if(n=="flatten"){m.data={hZ:"flattenImage"}}else console.log(w,n,W)}else if(I=="Layer"){var R=w.Z,x=A.C.indexOf(R);
if(!1){}else if(n=="copy"){gQ.aH.qX(A,D,0);l.data={d:b.c.UA,O0:W[0],Ay:x,bh:!0};D.S(l);delete l.data;
gQ.aH.qX(A,D,1)}else if(n=="clear"){gQ.aH.qX(A,D,0);m.data={hZ:"delete"};D.S(m);delete m.data;gQ.aH.qX(A,D,1)}else if(n=="duplicate"){if(W.length==0){var v=A.g.slice(0);
M.data={d:h.R6,j:x};M.G=y.Yu;D.S(M);M.data=null;U={zC:"Layer",Z:A.C[A.g[0]],LK:w.LK};A.g=v}else if(W[0].zC=="Document"){M.data={d:h.jF,C:A.Jr(x),Wv:A,SY:W[0].Z};
M.G=y.Yu}}else if(n=="merge"||n=="remove"){M.data={d:n=="merge"?h.g6:h.du,j:x};M.G=y.Yu;if(n!="remove")U={zC:"Layer",Z:A.C[A.g[0]],LK:w.LK}}else if(n=="move"){M.data={d:h.nP,source:x,target:A.C.indexOf(W[0].Z),TJ:W[1]!=3?.6:.3};
M.G=y.Yu}else if(n=="rasterize"){m.data={hZ:"rasterizeLayer",E3:{classID:"rasterizeLayer",null:cq.Pz("Lyr",!0)}}}else if(n=="rotate"){M.data={d:"rot",s7:[2,5],Z:-W[0]*Math.PI/180,Zl:W[1],j:x};
M.G=y.Sv}else if(n=="resize"){M.data={d:"scl",s7:[2,4],Z:new ec(W[0]/100,W[1]/100),Zl:W[2],j:x};M.G=y.Sv}else if(n=="translate"){var N=gQ.aH.alO(W);
M.data={d:"trsl",j:x,Bi:N[0],ah:N[1]};M.G=y.Rv}else if(n=="link"){M.data={d:h.qf,a6Z:[x,A.C.indexOf(W[0].Z)]};
M.G=y.Yu}else if(n=="invert"){M.G=y.DW;M.data={d:"start",u4:"nvrt"}}else if(n=="desaturate"){m.data={hZ:"desaturate"}}else if(n.startsWith("apply")&&cx.FT[n.slice(5)]||n.startsWith("adjust")&&cx.FT[n.slice(6)]){var u=n.startsWith("apply"),N=gQ.aH.alO(W),H=cx.FT[n.slice(u?5:6)];
m.data={hZ:u?cx.Hc[H]:eH.Hc[H]};var s=cx._1(H);if(s){A.g=[x];cx.fI["g"+H](s,N);m.data.E3=s}}else console.log(w,n,W)}else if(I=="Documents"){if(n=="getByName"){for(var L=0;
L<g.length;L++)if(g[L].name==W[0])return{zC:"Document",Z:g[L]};return null}else if(n=="add"){var F=W[5];
if(F==null)F=1;m.data=kc.xM(W[0],W[1],W[2],W[3],["Wht","Trns","BckC"][F],!1)}else throw"e"}else if(I=="Layers"){if(n=="getByName"){for(var L=0;
L<w.Z.length;L++)if(w.Z[L].Z.getName()==W[0]){U=w.Z[L];break}if(U==null)j.__throw={message:"No layer with a name "+W[0]}}else if(n=="add"){M.data={d:w.axU=="layerSets"?h.Si:h.tp};
M.G=y.Yu;D.S(M);M.data=null;U={zC:"Layer",Z:A.C[A.g[0]],LK:w.LK}}else console.log(w,n,W)}else if(w.zC=="Selection"){if(n=="select"){var t=W[0],o=[];
for(var L=0;L<t.length;L++)o.push(t[L][0],t[L][1]);m.data=y.eZ.KI(o)}else if(n=="clear"){m.data={hZ:"delete"}}else if(n=="selectAll"){m.data=y.eZ.Jj(!0)}else if(n=="invert"){m.data={hZ:"inverse"}}else if(n=="copy"){l.data={d:b.c.UA}}else if(n=="deselect"){m.data=y.eZ.Jj()}else if(n=="fill"){var q=W[0].Z;
q=E.M.lW({o:q[1]*255,B:q[2]*255,k:q[3]*255});m.data=y.JT.YE("Clr",W[1],W[2]==null?1:W[2]/100,q)}else if(n=="grow"||n=="similar"){var s={classID:"null",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]}};
if(W[0]!=null)s.Tlrn={t:"long",v:W[0]};m.data={hZ:n,E3:s}}else if(n=="expand"||n=="contract"||n=="feather"){m.data=y.eZ.cp(n,W[0],!0)}else if(n=="translate"){var s={classID:"null",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]},T:{t:"Objc",v:{__name:"Offset",classID:"Ofst",Hrzn:{t:"UntF",v:{type:"#Pxl",val:W[0]}},Vrtc:{t:"UntF",v:{type:"#Pxl",val:W[1]}}}}};
m.data={hZ:"move",E3:s}}else if(n=="smooth"){m.data=y.eZ.cp("smoothness",W[0],!1)}else console.log(w,n,W)}else if(w.zC=="Window"){if(n=="show"){l.data={d:b.c.P2,jW:w.Z}}else throw"e"}else if(w.zC=="ActionReference"){if(n=="putProperty"){w.Z.push({t:"prop",v:{classID:W[0],keyID:W[1]}})}else if(n=="putClass"){w.Z.push({t:"Clss",v:{classID:W[0]}})}else if(n=="putEnumerated"){w.Z.push({t:"Enmr",v:{classID:W[0],typeID:W[1],enum:W[2]}})}else if(n=="putName"){w.Z.push({t:"name",v:{classID:W[0],val:W[1]}})}else console.log(n,W)}else if(w.zC=="ActionDescriptor"||w.zC=="ActionList"){if(n=="putReference"){w.Z[W[0]]={t:"obj ",v:W[1].Z}}else if(n=="putDouble"){w.Z[W[0]]={t:"doub",v:W[1]}}else if(n=="putUnitDouble"){w.Z[W[0]]={t:"UntF",v:{type:W[1],val:W[2]}}}else if(n=="putObject"){if(w.zC=="ActionList"){var _=W[1].Z;
_.classID=W[0];w.Z.push({t:"Objc",v:_})}else{var _=W[2].Z;_.classID=W[1];w.Z[W[0]]={t:"Objc",v:_}}}else if(n=="putList"){w.Z[W[0]]={t:"VlLs",v:W[1].Z}}else if(n=="putBoolean"){w.Z[W[0]]={t:"bool",v:W[1]}}else if(n=="putInteger"){w.Z[W[0]]={t:"long",v:W[1]}}else if(n=="putString"){w.Z[W[0]]={t:"TEXT",v:W[1]}}else if(n=="putEnumerated"){var d={};
d[W[1]]=W[2];w.Z[W[0]]={t:"enum",v:d}}else if(n=="hasKey"){var R=A.C[A.g[0]],k=W[0];if(k=="textKey")return R.add.TySh!=null;
var r=w.Z.null.v;for(var L=0;L<r.length;L++){if(r[L].v.keyID==W[0]){if(k=="UsrM"){return R._N()!=null}else throw W}}}else if(n=="getEnumerationValue"){if(W[0]=="layerSection")U="layerSectionContent";
else console.log(W)}else if(n=="getBoolean"){if(W[0]=="background")U=!1;else console.log(W)}else if(n=="getString"){if(W[0]=="name")U=w.bC.getName();
else if(W[0]=="textKey")U=hd.Bb(w.bC._o);else console.log(w,W)}else if(n=="getObjectValue"){if(W[0]=="textKey"){U={zC:"ActionDescriptor",bC:w.bC.add.TySh}}else if(typeof W[0]=="number")U=w.bC[W[0]];
else throw W[0]}else if(n=="getList"){U={zC:"ActionList"};if(W[0]=="paragraphStyleRange")U.bC=w.bC._o.EngineDict.ParagraphRun.RunArray;
else if(W[0]=="kerningRange")U.bC=[];else if(W[0]=="textStyleRange")U.bC=w.bC._o.EngineDict.StyleRun.RunArray;
else throw W}else console.log(n,W)}else if(w.zC=="$"){if(n=="writeln"){console.log(W[0])}else throw n}else if(w.zC=="UI"){if(n=="scroll"||n=="scrollTo"){var p=W[0],Q=W[1],B=A.u.N;
if(n=="scrollTo"){p=(-A.m/2+p)*B+A.u.R.x;Q=(-A.n/2+Q)*B+A.u.R.y}M.G=y.pX;M.data={d:"scroll",jP:new ec(Math.round(p),Math.round(Q))}}else{var i;
if(n=="zoomIn"||n=="zoomOut"){i={d:"zoom",pZ:n=="zoomIn"}}else if(n=="fitTheArea"){i={d:"adapt",Z:"fitscr"}}else if(n=="pixelToPixel"){i={d:"adapt",Z:"pixel"}}M.G=y.Nt;
M.data=i;if(n=="switchFullscreen"){var c=D.Ir.jq,h2=document.fullscreenElement!=null==(c==2);l.data={d:b.c.sa,Z:c==0?2:0,dJ:h2}}}}else if(w.zC=="Folder"){if(n=="selectDialog")U="img";
else throw n}else console.log(w,n,W);if(M.data)D.S(M);if(m.data)D.S(m);if(l.data)D.S(l);return U};gQ.aH.qX=function(w,n,W){var D=new ed(b.E.v,!0);
D.G=y.wA;var j=new ed(b.E.W1,!0);if(W==0){gQ.aH.avS=w.J;j.data=y.eZ.Jj(!0)}else{var I=gQ.aH.avS;if(I)D.data={d:"setsel",s7:"Restore Selection",J:{rect:I.rect.clone(),channel:I.channel.slice(0)}};
else j.data=y.eZ.Jj()}n.S(D.data?D:j)};gQ.aH.avS=null;gQ.aH.RZ={AnchorPosition:{TOPLEFT:0,TOPCENTER:1,TOPRIGHT:2,MIDDLELEFT:3,MIDDLECENTER:4,MIDDLERIGHT:5,BOTTOMLEFT:6,BOTTOMCENTER:7,BOTTOMRIGHT:8},Units:{PIXELS:0,INCHES:1,CM:2,MM:3,PERCENT:4,PICAS:5,POINTS:6},ElementPlacement:{INSIDE:0,PLACEATBEGINNING:1,PLACEATEND:2,PLACEBEFORE:3,PLACEAFTER:4},LayerKind:{NORMAL:0,SMARTOBJECT:1,TEXT:2,SOLIDFILL:3,GRADIENTFILL:4,PATTERNFILL:5},RippleSize:{SMALL:0,MEDIUM:1,LARGE:2},PolarConversionType:{POLARTORECTANGULAR:1,RECTANGULARTOPOLAR:0},OffsetUndefinedAreas:{REPEATEDGEPIXELS:0,SETTOBACKGROUND:1,WRAPAROUND:2},NoiseDistribution:{GAUSSIAN:0,UNIFORM:1},TextType:{PARAGRAPHTEXT:0,POINTTEXT:1},DialogModes:{ALL:0,ERROR:1,NO:2},SaveOptions:{DONOTSAVECHANGES:0,PROMPTTOSAVECHANGES:1,SAVECHANGES:2},SaveDocumentType:{PNG:"png",JPEG:"jpg",COMPUSERVEGIF:"gif"},ExportType:{SAVEFORWEB:0},MatteType:{BACKGROUND:0,BLACK:1,FOREGROUND:2,NETSCAPE:3,NONE:4,SEMIGRAY:5,WHITE:6},FormatOptions:{OPTIMIZEDBASELINE:0,PROGRESSIVE:1,STANDARDBASELINE:3},DocumentMode:{BITMAP:0,CMYK:1,DUOTONE:2,GRAYSCALE:3,INDEXEDCOLOR:4,LAB:5,MULTICHANNEL:6,RGB:7},NewDocumentMode:{BITMAP:0,CMYK:1,DUOTONE:2,GRAYSCALE:3,INDEXEDCOLOR:4,LAB:5,MULTICHANNEL:6,RGB:7},DocumentFill:{WHITE:0,TRANSPARENT:1,BACKGROUNDCOLOR:2},TrimType:{TOPLEFT:0,BOTTOMRIGHT:1,TRANSPARENT:2},WaveType:{SINE:0,TRIANGULAR:1,SQUARE:2},UndefinedAreas:{WRAPAROUND:0,REPEATEDGEPIXELS:1},BlendMode:{NORMAL:"norm",DISSOLVE:"diss",DARKEN:"dark",MULTIPLY:"mul ",COLORBURN:"idiv",LINEARBURN:"lbrn",DARKERCOLOR:"dkCl",LIGHTEN:"lite",SCREEN:"scrn",COLORDODGE:"div ",LINEARDODGE:"lddg",LIGHTERCOLOR:"lgCl",OVERLAY:"over",SOFTLIGHT:"sLit",HARDLIGHT:"hLit",VIVIDLIGHT:"vLit",LINEARLIGHT:"lLit",PINLIGHT:"pLit",HARDMIX:"hMix",DIFFERENCE:"diff",EXCLUSION:"smud",SUBTRACT:"fsub",DIVIDE:"fdiv",HUE:"hue ",SATURATION:"sat ",COLOR:"colr",LUMINOSITY:"lum "},Justification:{LEFT:0,RIGHT:1,CENTER:2,LEFTJUSTIFIED:3,RIGHTJUSTIFIED:4,CENTERJUSTIFIED:5,FULLYJUSTIFIED:6},AntiAlias:{NONE:0,SHARP:1,CRISP:2,STRONG:3,SMOOTH:4},Extension:{LOWERCASE:0,NONE:1,UPPERCASE:2},RasterizeType:{ENTIRELAYER:0,FILLCONTENT:1,LAYERCLIPPINGPATH:2,LINKEDLAYERS:3,SHAPE:4,TEXTCONTENTS:5}};
gQ.aH.RZ.ColorBlendMode=gQ.aH.RZ.BlendMode;gQ.aH.Pi="---- SoLd TySh SoCo GdFl PtFl".split(" ");function fd(){}fd.g4={"dc:Title":["",null,"dc:title"],"tiff:Artist":["",315,"dc:creator"],"tiff:ImageDescription":["",270,"dc:description"],"dc:Keywords":["",null,"dc:subject"],"tiff:Copyright":["",33432],"tiff:Make":["",271],"tiff:Model":["",272],"exif:ExposureTime":[[1,200],33434],"exif:FNumber":[[16,1],33437],"exif:ExposureProgram":[1,34850],"exif:ISOSpeedRatings":[200,34855],"exif:DateTimeOriginal":["",36867],"exif:ShutterSpeedValue":[[1,1],37377],"exif:ApertureValue":[[8,1],37378],"exif:ExposureBiasValue":[[1,1],37380],"exif:MaxApertureValue":[[1,1],37381],"exif:MeteringMode":[5,37383],"exif:LightSource":[0,37384],"exif:Flash":[0,37385],"exif:FocalLength":[[60,1],37386],"exif:PixelXDimension":[1,40962],"exif:PixelYDimension":[1,40963],"exif:FocalPlaneXResolution":[[1,1],41486],"exif:FocalPlaneYResolution":[[1,1],41487],"exif:FocalPlaneResolutionUnit":[2,41488],"exif:DigitalZoomRatio":[[100,100],41988],"exif:FocalLengthIn35mmFilm":[1,41989],"exif:SceneCaptureType":[0,41990],"exif:LensInfo":["",42034],"exif:Lens":["",42036],"exif:LensSerialNumber":["",42037],"exif:SensitivityType":[2,34864],"exif:RecommendedExposureIndex":[100,34866],"exif:GPSVersionID":["2.3.0.0",0],"exif:GPSLatitude":["48,35,57.646N",2],"exif:GPSLongitude":["22,56,42.238E",4],"exif:GPSAltitudeRef":[0,5],"exif:GPSAltitude":[[1,1],6],"exif:GPSStatus":["A",9],"exif:GPSMapDatum":["",18],"Iptc4xmpCore:IntellectualGenre":[""],"Iptc4xmpCore:Location":[""],"Iptc4xmpCore:CountryCode":[""],"photoshop:Instructions":[""],"photoshop:AuthorsPosition":[""],"photoshop:City":[""],"photoshop:State":[""],"photoshop:Country":[""],"photoshop:TransmissionReference":[""],"photoshop:Headline":[""],"photoshop:Credit":[""],"photoshop:Source":[""],"dc:rights":[""],"photoshop:CaptionWriter":[""]};
fd.Jg={"4":"Iptc4xmpCore:IntellectualGenre","5":"dc:Title","40":"photoshop:Instructions","80":"tiff:Artist","85":"photoshop:AuthorsPosition","90":"photoshop:City","92":"Iptc4xmpCore:Location","95":"photoshop:State","100":"Iptc4xmpCore:CountryCode","101":"photoshop:Country","103":"photoshop:TransmissionReference","105":"photoshop:Headline","110":"photoshop:Credit","115":"photoshop:Source","116":"dc:rights","120":"tiff:ImageDescription","122":"photoshop:CaptionWriter"};
fd.a9n=function(w,n){if(n==null)n={};var W=fd.Jg,D=[],j=[],I="";for(var L=0;L<w.length;L++){var U=w[L],M=W[U[0]+""];
if(M&&n[M]==null)n[M]=U[1];else if(U[0]==12)j.push(U[1]);else if(U[0]==25)D.push(U[1]);else if(U[0]==55)I=U[1];
else if(U[0]==60)I+=";"+U[1]}if(I!=""&&n["exif:DateTimeOriginal"]==null)n["exif:DateTimeOriginal"]=I;
if(j.length!=0&&n["Iptc4xmpCore:SubjectCode"]==null)n["Iptc4xmpCore:SubjectCode"]=j.join(";");if(D.length!=0&&n["dc:Keywords"]==null)n["dc:Keywords"]=D.join(";");
return n};fd.ant=function(w){var n=fd.Jg,W=[];for(var D in n)if(w[n[D]])W.push([parseInt(D),w[n[D]]]);
if(w["Iptc4xmpCore:SubjectCode"]){var j=w["Iptc4xmpCore:SubjectCode"].split(";");for(var L=0;L<j.length;
L++)W.push([12,j[L].trim()])}if(w["dc:Keywords"]){var j=w["dc:Keywords"].split(";");for(var L=0;L<j.length;
L++)W.push([25,j[L].trim()])}W.sort(function(I,U){return I[0]-U[0]});return W};fd.auh=function(w,n){if(n==null)n={};
var W=new DOMParser,D=W.parseFromString(w,"image/svg+xml"),j=D.getElementsByTagName("rdf:Description")[0];
if(j==null)return n;var I=fd.g4;for(var U in I){var M=I[U][2];if(M==null)continue;var m=j.getElementsByTagName(M)[0];
if(m==null)continue;var l=m.getElementsByTagName("rdf:li"),A=[];for(var L=0;L<l.length;L++)A.push(l[L].textContent);
n[U]=A.join("; ")}return n};fd.acC=function(w){var n=["<?xpacket begin=\"\uFEFF\" id=\"W5M0MpCehiHzreSzNTczkc9d\"?>","<x:xmpmeta xmlns:x=\"adobe:ns:meta/\" x:xmptk=\"Adobe XMP Core 5.6-c145 79.163499, 2018/08/13-16:40:22\">","<rdf:RDF xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\">","<rdf:Description rdf:about=\"\" xmlns:xmp=\"http://ns.adobe.com/xap/1.0/\" xmlns:dc=\"http://purl.org/dc/elements/1.1/\" xmlns:xmpMM=\"http://ns.adobe.com/xap/1.0/mm/\" xmlns:stEvt=\"http://ns.adobe.com/xap/1.0/sType/ResourceEvent#\" xmlns:stRef=\"http://ns.adobe.com/xap/1.0/sType/ResourceRef#\">"],W=fd.g4;
for(var D in W){var j=w[D],I=W[D][2],U="Seq",M="";if(j==null||I==null)continue;if(I=="dc:title"||I=="dc:description"){U="Alt";
M=" xml:lang=\"x-default\""}if(I=="dc:subject")U="Bag";n.push("\t<"+I+"><rdf:"+U+">");var m=I=="dc:subject"?j.split(";").join(",").split(","):[j];
for(var L=0;L<m.length;L++)n.push("\t\t<rdf:li"+M+">"+m[L].trim()+"</rdf:li>");n.push("\t</rdf:"+U+"></"+I+">")}n.push("</rdf:Description>","</rdf:RDF>","</x:xmpmeta>","<?xpacket end=\"w\"?>");
return n.join("\n")};fd.ad4=function(w){var n=[];for(var L=0;L<w.length;L++)n[L]=w[L][1]==0?0:w[L][0]/w[L][1];
return n};fd.are=function(w){var n=[];for(var L=0;L<w.length;L++){var W=w[L],D=1;if(W!=Math.round(W)){D=1e3;
W=Math.round(W*D)}n[L]=[W,D]}return n};fd.X6=function(w,n){var W=fd.g4;if(n==null)n={};for(var D in W){var j=W[D][1],I="t"+j;
if(j!=null&&w[I]!=null){var U=w[I];if(j==0)U=U.join(".");else if(j==2||j==4){var M=w["t"+(j-1)];if(M==null)M=[j==2?"N":"E"];
U=fd.ad4(U).join(",")+M[0]}else if(j==42034)U=fd.ad4(U).join(" ");else if(j==270||j==315){var m=U[0],l=new Uint8Array(m.length);
J.Jm(l,0,m);U=J.KY(l)}else U=U[0];n[D]=U}}if(w.exifIFD)fd.X6(w.exifIFD,n);if(w.gpsiIFD)fd.X6(w.gpsiIFD,n);
return n};fd.cG=function(w,n,W){var D=fd.g4,I=0,M=0;if(n==null)n={};var j={},U={};for(var m in D){if(w[m]==null||D[m][1]==null)continue;
var l=D[m][1],A="t"+l,g=n;if(m.startsWith("exif:")){g=j;I++;if(m.startsWith("exif:GPS")){g=U;M++}}var k=w[m];
if(l==0)k=new Uint8Array(k.split(".").map(parseFloat));else if(l==2||l==4){var $=k.length;g["t"+(l-1)]=[k.slice(k.length-1)];
k=fd.are(k.split(",").map(parseFloat))}else if(l==42034)k=fd.are(k.split(" ").map(parseFloat));else if(l==270||l==315){var C=J.zY(k);
k=[J.sv(C,0,C.length)]}else k=[k];g[A]=k}if(I!=0){n.exifIFD=j;n.t34665=[0]}if(M!=0){n.gpsiIFD=U;n.t34853=[0]}var f=new Date,z=[f.getFullYear(),f.getMonth()+1,f.getDate(),f.getHours(),f.getMinutes(),f.getSeconds()];
for(var L=0;L<6;L++)z[L]=(z[L]+"").padStart(2,"0");n.t305=["Photopea Editor (www.photopea.com)"];if(W!=!0)n.t306=[z[0]+":"+z[1]+":"+z[2]+" "+z[3]+":"+z[4]+":"+z[5]];
return n};function aa(){}aa.ew=function(w){var n={a3C:",",aQ:"\r\n",tN:"\""},W=[[""]],D,j,I,U,M;for(D=j=I=U=0;
I<w.length;I++){switch(M=w.charAt(I)){case n.tN:if(U&&w.charAt(I+1)==n.tN){W[D][j]+=n.tN;++I}else{U^=1}break;
case n.a3C:if(!U){W[D][++j]=""}else{W[D][j]+=M}break;case n.aQ.charAt(0):if(!U&&(!n.aQ.charAt(1)||n.aQ.charAt(1)&&n.aQ.charAt(1)==w.charAt(I+1))){W[++D]=[""];
W[D][j=0]="";if(n.aQ.charAt(1)){++I}}else{W[D][j]+=M}break;default:W[D][j]+=M}}if(W[W.length-1].length<W[0].length)W.pop();
return W};var e={};e.apo=0;e.iF=function(){e.apo++;return e.apo};e.aup="uint8";e.r3=function(w){w.e.style.transition="opacity 0.1s ease-out, transform 0.1s ease-out";
w.e.style.opacity="1";w.e.style.transform="scale(1)"};e.Qa=function(w,n){w.e.style.opacity="0";w.e.style.transform="scale(0.95)";
if(n)setTimeout(function(){n.removeChild(w.e)},100)};e.aqj=function(){var w=e.a8D();if(w=="")return 0;
if(w!=e.Dn("_TXZRPB;d7@;")){var n=e.eH[hk.Xe][hk.op],W=n.indexOf(String.fromCharCode(35)),D;if(W==-1)return 0;
try{D=JSON.parse(e.eH[hk.afQ](n.slice(W+1)))}catch(fV){return 0}var j=D[e.Dn("bQ[ODL<E<M")];if(j==null||j.length<<2!=64)return 0;
var I=hk.Hl(),U=parseInt(j.slice(3*4).split("").reverse().join(""),16)<<16;if(U<I||j!=hk.a2T(U,w))return 0;
return 2}return 1};e.a8D=function(){var w=e.eH[e.GF("}$z{2*35")][e.Dn("W[\\ZQAJ?")],n=String.fromCharCode(46),W=w.split(n);
if(W.length<2)return"";var D=W.pop();D=W.pop()+n+D;return D};e.aaY=function(){if(e.eH[hk.anx][hk.a5a]){var w=new e.eH[hk.GJ];
w[hk.or](hk.adz,e.Dn("W`]VVykhNKH[;046.,}v@r{v5samc&YgSY\\rRGLw=oaR3+`%|")+e.a8D());w[hk.Z2]()}};e.aO=function(){if(window.top!=window.self)return!1;
var w=navigator.userAgent.toLowerCase();if(w.indexOf("android")!=-1)return!1;if(w.indexOf("safari")!=-1&&w.indexOf("chrome")==-1)return!1;
return window.ClipboardItem!=null};e.BC=function(w){this.yd=w;this.fJ=e.t("img");this.Ml=e.t("canvas");
this.b4=null;this.V2="";this.AA=null;this.Ol=new ec(0,0);this.vA=!0;e.Ko(this.yd,this.zV.bind(this))};
e.BC.prototype.mQ=function(w,n){this.b4=w;if(n)this.V2=n;this.zV()};e.BC.prototype.G3=function(w){this.vA=w;
this.zV()};e.BC.prototype.zV=function(w){if(w)this.Ol=e.rv(w,this.yd);var n=this.vA?this.b4:"auto",W=typeof n=="string";
if(!W){var D=e.V(),j=this.Ol,I=n.WH.m,U=n.WH.n,M=typeof n.p0=="string",m=M?this.fJ:this.Ml;if(M)m.setAttribute("src",n.p0);
else{m.width=I;m.height=U;var l=m.getContext("2d"),A=new ImageData(new Uint8ClampedArray(n.p0.buffer),I,U);
l.putImageData(A,0,0)}m.setAttribute("style"," position:absolute; pointer-events:none;user-select:none;"+"top:"+(j.y-n.Q5.y/D)+"px; left:"+(j.x-n.Q5.x/D)+"px; width:"+I/D+"px; height:"+U/D+"px");
var g=this.AA;if(g==null||g!=m){if(g)this.yd.removeChild(g);this.yd.appendChild(m);this.AA=m}}else if(this.AA){this.yd.removeChild(this.AA);
this.AA=null}this.yd.setAttribute("style","cursor:"+(W?n:"none")+"; "+this.V2)};e.VT=function(w){return w.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/'/g,"&#039;")};
e.We=function(w,n){w.wV(fV.get([12,41]).charAt(0)+":");n.wV(fV.get([12,42]).charAt(0)+":")};e.t=function(w,n){var W=document.createElement(w);
if(n!=null)W.className=n;return W};e._g=function(w){while(w.firstChild)w.removeChild(w.firstChild)};
e.W0=function(w,n){var W=w.className;W=W.split(" ");if(W.indexOf(n)==-1)W.push(n);w.className=W.join(" ")};
e.IX=function(w,n){var W=w.className;if(W=="")return;W=W.split(" ");if(W.indexOf(n)!=-1)W.splice(W.indexOf(n),1);
w.className=W.join(" ")};e.LY=function(w){while(!0){if(w==document)return!0;if(w==null)return!1;w=w.parentNode}};
e.x$=function(w){w.appendChild(e.t("br"))};e.R2=function(w){w.appendChild(e.t("hr"))};e.bp=function(w,n,W){var D=new iP([1,12,1],W==null?!0:W,null,!0);
if(w)D.h("click",w.j8,w);if(n)n.appendChild(D.e);return D};e.eH=document;e.pI=function(w){var n=0;for(var L=0;
L<w;L++)n+=Math.random();return n/w<Math.PI/4};e.Dn=function(w){var n="";if(!e.pI(28))w+="-3";for(var L=0;
L<w.length;L++){var W=w.charCodeAt(L);if(W<32||126<W)throw"e";n+=String.fromCharCode(32+(W-32+17+3*L)%95)}return n};
e.GF=function(w){var n="";if(!e.pI(28))w+="-1";for(var L=0;L<w.length;L++){var W=w.charCodeAt(L);W-=32;
W+=95e4;W-=17+3*L;W=W%95;n+=String.fromCharCode(32+W)}return n};e.Lb=function(w){var n=Math.random();
e.aup="uint"+(3+n);return new w};(function(){var w=window.PointerEvent,n=w?"pointer":"mouse",W=n+"down",D=n+"move",j=n+"up",I=!1;
e.L_=function(U,M){U.addEventListener(W,M,I);if(!w)U.addEventListener("touchstart",M,I)};e.Ko=function(U,M){U.addEventListener(D,M,I);
if(!w)U.addEventListener("touchmove",M,I)};e.d6=function(U,M){U.addEventListener(j,M,I);if(!w)U.addEventListener("touchend",M,I)};
e.a8X=function(U,M){U.removeEventListener(W,M,I);if(!w)U.removeEventListener("touchstart",M,I)};e.MC=function(U,M){U.removeEventListener(D,M,I);
if(!w)U.removeEventListener("touchmove",M,I)};e.i_=function(U,M){U.removeEventListener(j,M,I);if(!w)U.removeEventListener("touchend",M,I)}}());
e.ZS=function(w){w.addEventListener("touchstart",e._L,!1);w.addEventListener("touchmove",e._L,!1);w.addEventListener("touchend",e._L,!1);
w.addEventListener("gesturestart",e._L,!1);w.addEventListener("gesturechange",e._L,!1);w.addEventListener("gestureend",e._L,!1)};
e.av6=function(w){var n=w.sourceCapabilities;if(n)return n.firesTouchEvents;return!1};e.dz=function(w,n,W,D){var j=e.V();
w.width=Math.floor(n*j);w.height=Math.floor(W*j);if(D)D.scale(j,j);e.gH(w)};e.gH=function(w){var n=e.V();
w.style.width=w.width/n+"px";w.style.height=w.height/n+"px"};e.UE=function(w,n,W){w.setAttribute("style","width:"+n/e.V()+"px; height:"+W/e.V()+"px")};
e.rv=function(w,n){if(n==null)n=w.currentTarget;var W=n.getBoundingClientRect();if(w.touches)w=w.touches.item(0);
return{x:w.clientX-W.left,y:w.clientY-W.top}};e.V=function(){return window.devicePixelRatio||1};e.xr=function(w){w.addEventListener("keydown",e.arH,!1)};
e.arH=function(w){w.stopPropagation()};e._L=function(w){w.preventDefault()};e.oz=function(w){w.stopPropagation();
w.preventDefault()};e.DZ=function(w,n,W){W=W?W:"";if(PIMG["__"+w]==null)W+=" gsicon";return"<img src=\""+PIMG[w]+"\" alt=\""+(n?n:"")+"\" class=\""+W+"\" />"};
e.ri=function(w,n,W,D){var j=w.dataTransfer.getData("text/uri-list");if(j!=null&&j.startsWith("http")){var I=new ed(b.E.L,!0);
I.data={d:b.c.VR,AH:{url:j,AM:!0,ev:W,Ze:D}};n.S(I)}if(w.dataTransfer.files.length==0)return;if(window.showOpenFilePicker){var U=[],M=w.dataTransfer.items.length,m=w.dataTransfer.files;
for(var l of w.dataTransfer.items)l.getAsFileSystemHandle().then(function(A){U.push(A);if(U.length==M){var I=new ed(b.E.L,!0);
I.data={d:b.c.Bc,data:m,ev:W,Ze:D,aoG:U};n.S(I)}})}else{var I=new ed(b.E.L,!0);I.data={d:b.c.Bc,data:w.dataTransfer.files,ev:W,Ze:D};
n.S(I)}};if(e.pI(27))e.eH=window;else e.eH=e.atw;e.eH._cwY=e.eH[e.GF("t$&!'31")];var hp={};hp.aoC=function(L){var w=hp.fX[L],n=document.documentElement.style,D=1;
n.setProperty("--base","#"+E.$$(w["--base"]));n.setProperty("--bg-panel","#"+E.$$(w["--bg-panel"]));
n.setProperty("--bg-canvas","#"+E.$$(w["--bg-canvas"]));n.setProperty("--bg-input","#"+E.$$(w["--bg-input"]));
n.setProperty("--bg-bbtn","#"+E.$$(w["--bg-bbtn"]));n.setProperty("--bg-bbtnOver","#"+E.$$(w["--bg-bbtnOver"]));
n.setProperty("--brdr","#"+E.$$(w["--brdr"]));n.setProperty("--text-color","#"+E.$$(w["--text-color"]));
n.setProperty("--brdrLgt","rgba(255,255,255,"+w["--brdrLgt"]+")");n.setProperty("--brdrDrk","rgba( 0, 0, 0,"+w["--brdrDrk"]+")");
n.setProperty("--alphaDark",""+w["--alphaDark"]);n.setProperty("--gs-invert",""+w["--gs-invert"]);n.setProperty("--accent","#"+E.$$(w["--accent"]));
var W=w["--sh-clr"];n.setProperty("--sh-clr","rgba("+(W>>16)+","+(W>>8&255)+","+(W&255)+", 0.45)");n.setProperty("--absc",""+w["--absc"]);
n.setProperty("--abs255",""+w["--abs255"]);if(1<e.V()&&e.V()<1.5)D=1/e.V();n.setProperty("--img20",20*D+"px");
n.setProperty("--img18",18*D+"px");n.setProperty("--img15",15*D+"px");if(PIMG!=null){var j="lrs/eye lrs/square lrs/arrow_down lrs/arrow_right lrs/chain lrs/link lrs/linkX lrs/clipping lrs/lock lrs/fx lrs/folder cross tools/cshape checkmark".split(" ");
for(var L=0;L<j.length;L++){var I=j[L],U=I.split("/").pop(),M=PIMG["__"+I]==null?w["--gs-invert"]:"0";
n.setProperty("--icon_"+U,"url("+PIMG[I]+")");n.setProperty("--icon_"+U+"_invrt",M)}}var m=document.querySelector("meta[name=theme-color]");
if(m)m.setAttribute("content","#"+E.$$(w["--base"]))};(function(){var w=3441398,n=3441398;hp.fX=[{name:"Light Grey","--base":14737632,"--bg-panel":11579568,"--bg-canvas":11579568,"--bg-input":16777215,"--bg-bbtn":15921906,"--bg-bbtnOver":16777215,"--brdrLgt":.5,"--brdrDrk":.4,"--alphaDark":.12,"--text-color":3749943,"--gs-invert":.22,"--brdr":11579568,"--sh-clr":16777215,"--absc":1,"--abs255":255,"--accent":n},{name:"Dark Grey","--base":4671303,"--bg-panel":2434341,"--bg-canvas":2434341,"--bg-input":2434341,"--bg-bbtn":6118749,"--bg-bbtnOver":6974058,"--brdrLgt":.15,"--brdrDrk":.6,"--alphaDark":.25,"--text-color":14013909,"--gs-invert":.78,"--brdr":2434341,"--sh-clr":0,"--absc":0,"--abs255":0,"--accent":w},{name:"Blue","--base":4212048,"--bg-panel":2435637,"--bg-canvas":2434341,"--bg-input":2435637,"--bg-bbtn":6316138,"--bg-bbtnOver":6974074,"--brdrLgt":.15,"--brdrDrk":.6,"--alphaDark":.25,"--text-color":15790330,"--gs-invert":.88,"--brdr":2435637,"--sh-clr":0,"--absc":0,"--abs255":0,"--accent":w},{name:"Dark Blue","--base":2237745,"--bg-panel":1513761,"--bg-canvas":1513761,"--bg-input":1513761,"--bg-bbtn":3554128,"--bg-bbtnOver":3158085,"--brdrLgt":.15,"--brdrDrk":.6,"--alphaDark":.25,"--text-color":12303291,"--gs-invert":.8,"--brdr":1513761,"--sh-clr":0,"--absc":0,"--abs255":0,"--accent":w},{name:"Purple","--base":4931153,"--bg-panel":3287605,"--bg-canvas":2434341,"--bg-input":3287605,"--bg-bbtn":6840430,"--bg-bbtnOver":7694970,"--brdrLgt":.15,"--brdrDrk":.6,"--alphaDark":.25,"--text-color":15790330,"--gs-invert":.88,"--brdr":3287605,"--sh-clr":0,"--absc":0,"--abs255":0,"--accent":w},{name:"Black","--base":3487029,"--bg-panel":1710618,"--bg-canvas":1710618,"--bg-input":1710618,"--bg-bbtn":5263440,"--bg-bbtnOver":5921370,"--brdrLgt":.15,"--brdrDrk":.6,"--alphaDark":.25,"--text-color":13421772,"--gs-invert":.7,"--brdr":1710618,"--sh-clr":0,"--absc":0,"--abs255":0,"--accent":w},{name:"White","--base":16250871,"--bg-panel":14737632,"--bg-canvas":14737632,"--bg-input":16777215,"--bg-bbtn":14737632,"--bg-bbtnOver":14079702,"--brdrLgt":.2,"--brdrDrk":.2,"--alphaDark":.065,"--text-color":3355443,"--gs-invert":.18,"--brdr":14737632,"--sh-clr":16777215,"--absc":1,"--abs255":255,"--accent":n}]}());
function hG(){this.xQ={};this.ov={}}hG.prototype.a6U=function(w){var n=this.xQ[w];if(n==null)return!1;
return n.length>0};hG.prototype.addEventListener=function(w,n){this.h(w,n,null)};hG.prototype.h=function(w,n,W){if(this.xQ[w]==null){this.xQ[w]=[];
this.ov[w]=[]}this.xQ[w].push(n);this.ov[w].push(W)};hG.prototype.removeEventListener=function(w,n){var W=this.xQ[w];
if(W==null)return;var D=W.indexOf(n);if(D<0)return;var j=this.ov[w];W.splice(D,1);j.splice(D,1)};hG.prototype.S=function(w){w.currentTarget=this;
if(w.target==null)w.target=this;var n=this.xQ[w.type];if(n==null)return;var W=this.ov[w.type];for(var L=0;
L<n.length;L++){if(W[L]==null)n[L](w);else n[L].call(W[L],w)}};var ed=function(w,n){if(!n)n=!1;this.type=w;
this.target=null;this.currentTarget=null;this.bubbles=n;this.G=null;this.HH=!1},b={E:{v:"0",L:"1",W1:"1.5",A:"2",gh:"3",aeI:"4"},c:{aR:"10",Uq:"11",Eb:"12",xl:"13",ph:"14",a7X:"14.1",VR:"15",J0:"16",N0:"17",J6:"18",LI:"19",apu:"19.5",agP:"20",ayP:"20.1",akb:"20.5",abm:"20.6",jm:"21",UA:"22",s_:"23",_y:"24",P2:"25",pA:"26",dH:"27",l9:"28",aeR:"28.5",aqc:"29",Bc:"30",CV:"31",Oy:"32",bw:"33",Bg:"34",oj:"35",aqt:"35.5",aT:"37",aA1:"38",Ql:"39",SO:"40",zM:"41",vN:"41.5",ahn:"42",lb:"43",a61:"43.5",L1:"44",a1B:"45",RN:"46",D7:"47",$C:"48",if:"49",aoH:"50",sa:"51"}};
function eg(){hG.call(this);this.parent=null;this.e=null;this.gA=0;this.ag=0;this.avN=!1}eg.prototype=new hG;
eg.prototype.a01=function(w){var bK=this;while(bK!=null){if(bK==w)return!0;bK=bK.parent}return!1};eg.prototype.P8=function(){var w=this.e;
return w.offsetWidth+w.clientLeft};eg.prototype.aiE=function(){var w=this.e;return w.offsetHeight+w.clientTop};
eg.prototype.update=function(w){};eg.prototype.S=function(w){hG.prototype.S.call(this,w);if(w.bubbles&&this.parent!=null)this.parent.S(w)};
eg.prototype.f=function(){};eg.prototype.zl=function(w,n){};eg.prototype.rx=function(w){e.W0(this.e,"disabled")};
eg.prototype.Te=function(w){e.IX(this.e,"disabled")};eg.prototype.G3=function(w){if(w)this.Te();else this.rx()};
eg.prototype.Mk=function(){this.avN=!0};eg.prototype.q6=function(){var w=this.lU,n=this.avN,W=this.MO;
if(w){w=fV.get(this.lU);if(!n)w+=":";W.textContent=w;if(n){W.style.display="block";W.style.lineHeight="1.6em";
W.style.marginLeft="3px";e.IX(W,"flabel")}}if(n){this.q1.style.fontSize="1.15em"}};function c8(w){eg.call(this);
this.Pw=[];this.Ii=!1;this.akC=0;this.gC={x:0,y:0,WS:!1};this._r=w;this.a9A=this.jx.bind(this);this.mL=this.Gi.bind(this);
this.adk=this.WB.bind(this);e.L_(w,this.a9A);e.Ko(w,this.mL);w.addEventListener("wheel",this.JR.bind(this),!1);
w.addEventListener("contextmenu",this.asd.bind(this),!1);var n=this.ahJ.bind(this);w.addEventListener("gesturestart",n,!1);
w.addEventListener("gesturechange",n,!1);w.addEventListener("gestureend",n,!1);e.ZS(w)}c8.prototype=new eg;
c8.prototype.ahJ=function(w){if(w.type=="gesturestart")this.QV=w.scale;if(w.type=="gesturechange"){var n=new ed("mouse",!0);
n.action="scroll";n.wt=!0;this.nR(w,n);var W=(this.QV-w.scale)/this.QV;n.jP=new ec(0,100*W);this.QV=w.scale;
this.S(n)}};c8.prototype.cy=function(w){var n=-1,W=this.Pw;for(var L=0;L<W.length;L++)if(W[L].pointerId==w.pointerId)n=L;
return n};c8.xe=function(w){var n=w.pointerType,W=window.__kb;return n=="touch"&&W.U(aK.ax6)};c8.prototype.jx=function(w){if(c8.xe(w))return;
var n=this.cy(w);if(n!=-1)this.Pw[n]=w;else this.Pw.push(w);if(this.Pw.length==1){this.akC=Date.now();
var W=w.button!=null&&w.button!=0?w.which==2?"idown":"rdown":"down",j=new ed("mouse",!0);j.action=W;
this.nR(w,j);this.S(j);e.MC(this._r,this.mL);e.Ko(window,this.mL);e.d6(window,this.adk)}if(this.Pw.length==2){if(Date.now()-this.akC<100){var j=new ed("mouse",!0);
j.action="cancellast";this.nR(w,j);this.S(j)}this.Ii=!0}if(this.Pw.length==2)this.av3("multidown")};
c8.prototype.Gi=function(w){if(c8.xe(w))return;var n=this.cy(w);if(n!=-1)this.Pw[n]=w;if(this.Pw.length>1){this.av3("multimove")}if(this.Ii)return;
if(this.Pw.length==1&&n==-1)return;var W=new ed("mouse",!0);W.action="move";this.nR(w,W);this.S(W)};
c8.prototype.WB=function(w){if(c8.xe(w))return;var n=this.Pw;n=this.Pw=[];if(n.length==0){var W=w.button!=null&&w.button>0?w.which==2?"iup":"rup":"up",D=new ed("mouse",!0);
D.action=W;this.nR(w,D);this.S(D);e.MC(window,this.mL);e.i_(window,this.adk);e.Ko(this._r,this.mL);this.Ii=!1}};
c8.prototype.JR=function(w){w.preventDefault();if(w.deltaX==0&&w.deltaY==0)return;var n=new ed("mouse",!0);
n.action="scroll";n.wt=w.ctrlKey;this.nR(w,n);this.S(n)};c8.prototype.asd=function(w){e.oz(w);if(e.av6(w)){var n=new ed("mouse",!0);
this.nR(w,n);n.action="rdown";this.S(n);n.action="rup";this.S(n)}};c8.prototype.av3=function(w){var n=this.Pw,W=e.V(),D=[];
for(var L=0;L<n.length;L++){var j=D[L]=e.rv(n[L],this._r);j.x*=W;j.y*=W}var I=new ed("mouse",!0);I.action=w;
I.LE=D;if(n.length==2)this.S(I)};c8.prototype.nR=function(w,n,W){var D=this.Pw.length!=0;if(n.action!="up"){var j=e.V();
if(W==null)W=e.rv(w,this._r);this.gC=n.tJ={x:j*W.x,y:j*W.y,WS:D};var I=e.rv(w,document.body);n.tJ.Qc=I.x;
n.tJ.tc=I.y}else this.gC=n.tJ={x:this.gC.x,y:this.gC.y,WS:D};n.tJ.MJ=.5;if(w.pressure!=null&&w.pressure!=0)n.tJ.MJ=w.pressure;
if(w.pointerType=="mouse")n.tJ.MJ*=2;n.tJ.ag8=w.pointerType;if(w.deltaX!=null){var U=w.deltaMode==0?1:40;
n.jP=new ec(w.deltaX*U,w.deltaY*U)}};function cA(w,n,W){eg.call(this);this.U6=null;this.axp=this.WB.bind(this);
this.afn=this.Gu.bind(this);this.arj=this.a0B.bind(this);this.avQ=this.aat.bind(this);this.oP=[];this.sb=[];
this.RB=[];this.akr=[];this.e=e.t("div","contextpanel "+(W?"cp_dark":"cp_trsp"));this.e.addEventListener("contextmenu",e._L,!1);
this.kc=null;this.Lc=0;this.hK=w;this.aC=n;this.bT=[];for(var L=0;L<w.length;L++){var D=e.t("div","enab");
this.sb.push(D);this.e.appendChild(D);var j=w[L].qg;if(j){if(j.startsWith("#")){var I=e.t("span");I.setAttribute("style","display:inline-block; width:16px; height:16px; vertical-align:middle; margin:0 5px 0 -3px; border-radius:4px; background-color:"+j);
D.appendChild(I)}else D.innerHTML=e.DZ(w[L].qg,null,"thumb")}else{var U=e.t("span","check");this.akr.push(U);
D.appendChild(U)}var M=e.t("span","label");M.textContent=fV.get(w[L].name);D.appendChild(M);this.RB.push(M);
if(w[L].nW)this.e.appendChild(e.t("hr"));if(w[L].pn||w[L].sub){var m=D.dB=e.t("span","right");D.appendChild(m);
if(w[L].pn)m.textContent=aK.cO(w[L].pn);else if(w[L].sub)m.innerHTML="<svg height='10px' width='6px' fill='none' stroke-width='1.35' stroke='currentColor'><path d='M 1 1 L 5 5 L 1 9'/></svg>"}D.addEventListener(W?"mouseup":"click",this.axp,!1);
D.addEventListener("mouseover",this.afn,!0);D.addEventListener("mouseout",this.arj,!0);if(w[L].sub){var l=new cA(w[L].sub,n?n[L].sub:null);
l.parent=this;this.bT.push(l);l.h("select",this.a2F,this)}else this.bT.push(null)}}cA.prototype=new eg;
cA.prototype.aub=function(w){e._g(this.e);for(var L=0;L<w.length;L++)if(w[L]!=0&&w[L]!=null){this.e.appendChild(this.sb[L]);
if(w[L]!=1&&this.bT[L])this.bT[L].aub(w[L])}};cA.prototype.f=function(){var w=this.hK;for(var L=0;L<w.length;
L++){if(w[L].title)this.sb[L].title=fV.get(w[L].title);this.RB[L].textContent=fV.get(w[L].name)+(w[L].$r?"...":"")}for(var L=0;
L<this.bT.length;L++)if(this.bT[L])this.bT[L].f()};cA.prototype.update=function(w,n){var W=this.hK,D=window.innerWidth<450?"none":"inline";
for(var L=0;L<W.length;L++){var j=this.sb[L];if(j.dB&&!this.bT[L])j.dB.style.display=D;if(W[L].r){var I=W[L].r(w,n,L);
if(I.r!=null)this.sb[L].className=I.r?"enab":"disab";if(I.fP!=null)this.RB[L].textContent=I.fP;if(I.hO!=null)this.akr[L].innerHTML=I.hO?"<svg height='10px' width='10px' fill='none' stroke-width='1.35' stroke='currentColor'><path d='M 1 5 L 4 8 L 9 2'/></svg>":"";
if(I.W!=null)this.aC[L]=I.W}}for(var L=0;L<this.bT.length;L++)if(this.bT[L])this.bT[L].update(w,n)};
cA.prototype.aJ=function(){return this.oP};cA.prototype.WB=function(w){if(w.button!=0)return;var L=this.sb.indexOf(w.currentTarget);
if(this.bT[L]){this.Lc=L;this.aat()}else{if(this.aC){var n=this.aC[L],W=new ed(n.Y,!0);W.G=n.G;W.data=n.W;
this.S(W)}this.U6=null;this.oP=[L];this.S(new ed("select",!1));var W=new ed(b.E.L,!0);W.data={d:b.c.xl};
this.S(W)}};cA.prototype.Gu=function(w){var L=this.sb.indexOf(w.currentTarget);this.$S();this.Lc=L;this.kc=setTimeout(this.avQ,300)};
cA.prototype.a0B=function(w){this.$S()};cA.prototype.$S=function(){if(this.kc){clearTimeout(this.kc);
this.kc=null}};cA.prototype.aat=function(){this.$S();var L=this.Lc;if(this.U6)this.U6.a3q();if(this.bT[L]==null)return;
this.U6=this.bT[L];var w=this.sb[L].getBoundingClientRect(),n=new ed(b.E.L,!0);n.data={d:b.c.Uq,BT:this.bT[L],x:w.left+w.width+2,y:w.top};
this.S(n)};cA.prototype.a3q=function(){for(var L=0;L<this.bT.length;L++)if(this.bT[L])this.bT[L].a3q();
var w=new ed(b.E.L,!0);w.data={d:b.c.Eb,BT:this};this.S(w)};cA.prototype.a2F=function(w){var L=this.bT.indexOf(w.target);
this.oP=[L].concat(w.target.aJ());this.S(new ed("select",!1))};function b7(w,n,W){eg.call(this);this.e=e.t("span","fitem cbox");
if(n==null)n=!0;if(W==null)W="flabel";var D="cb"+e.iF();this.q1=e.t("input","");this.q1.setAttribute("type","checkbox");
this.q1.setAttribute("id",D);this.e.appendChild(this.q1);this.lU=w;this.jc=e.t("label",W);if(n)this.jc.setAttribute("for",D);
this.e.appendChild(this.jc);this.f();this.q1.addEventListener("change",this.p8.bind(this),!1)}b7.prototype=new eg;
b7.prototype.a8f=function(){return this.lU};b7.prototype.wV=function(w){this.jc.textContent=w};b7.prototype.f=function(){var w=this.lU;
if(typeof w=="string"&&w.startsWith("<"))this.jc.innerHTML=w;else this.jc.textContent=fV.get(w)};b7.prototype.d3=function(){this.q1.checked=!0};
b7.prototype.OD=function(){this.q1.checked=!1};b7.prototype.zr=function(){return this.q1.checked};b7.prototype.$=function(w){this.q1.checked=w};
b7.prototype.b=b7.prototype.zr;b7.prototype.p8=function(w){this.S(new ed(b.E.A,!1))};function ga(w,n){eg.call(this);
this.lU=w;this.e=e.t("span","labelitem fitem"+(n?" spread":""));this.f()}ga.prototype=new eg;ga.prototype.$=function(w){this.e.textContent=w};
ga.prototype.b=function(){return this.e.textContent};ga.prototype.Te=function(){this.e.removeAttribute("disabled")};
ga.prototype.rx=function(){this.e.setAttribute("disabled","")};ga.prototype.wV=function(w){this.e.textContent=w};
ga.prototype.f=function(){this.e.textContent=fV.get(this.lU)};ga.prototype.a8f=function(){return this.lU};
function iP(w,n,W,D,j){eg.call(this);this.Wg=!1;this.e=e.t("button","fitem"+(n?" spread":"")+(D?" bbtn":""));
this.lU=w;this.jv=W;this.f();var I=j&&window.PointerEvent?"pointerup":"click";this.e.addEventListener(I,this.nV.bind(this),!1)}iP.prototype=new eg;
iP.prototype.f=function(){var w=this.e,n=this.lU,W=this.jv;if(typeof n=="string"&&(n.startsWith("<img")||n.startsWith("<svg")||n.startsWith("<span"))){if(!this.Wg){w.innerHTML=n;
w.setAttribute("style","padding:2px");this.Wg=!0}}else w.textContent=fV.get(n);if(W){w.setAttribute("title",fV.get(W))}};
iP.prototype.ayn=function(w){this.e.setAttribute("title",w)};iP.prototype.nV=function(w){this.S(new ed("click",!1))};
iP.prototype.d3=function(){e.W0(this.e,"bactive")};iP.prototype.OD=function(){e.IX(this.e,"bactive")};
iP.prototype.wV=function(w,n){if(w&&w!=this.lU){this.lU=w;this.Wg=!1}if(n)this.jv=n;this.f()};iP.prototype.$=function(w){if(w)this.d3();
else this.OD()};iP.prototype.zr=function(){return this.e.getAttribute("class").indexOf("bactive")!=-1};
iP.prototype.b=function(){return this.zr()};function e7(w,n,W,D,j){eg.call(this);var I=e.iF();this.e=e.t("span","fitem tinput");
if(w){this.lU=w;this.MO=e.t("label","flabel");this.e.appendChild(this.MO);this.MO.setAttribute("for",I);
this.f()}if(j){this.q1=e.t("span")}else if(D==null){this.q1=e.t("input");this.q1.setAttribute("type","text")}else this.q1=e.t("textarea","scrollable");
this.q1.setAttribute("id",I);if(W)this.q1.setAttribute("style","width:"+W+"em;"+(j?" display:inline-block; margin-left:6px;":""));
if(D)this.q1.setAttribute("rows",D);this.e.appendChild(this.q1);if(n){this.hJ=e.t("span");this.hJ.textContent=n;
this.hJ.style.marginLeft="2px";this.e.appendChild(this.hJ)}e.xr(this.q1);this.q1.addEventListener("change",this.p8.bind(this),!1);
this.q1.addEventListener("input",this.alI.bind(this),!1);if(D==null)this.q1.addEventListener("keyup",this.fW.bind(this),!1)}e7.prototype=new eg;
e7.prototype.f=function(){this.q6()};e7.prototype.fW=function(w){var n=aK.$L(w.code,aK.QX),W=aK.$L(w.code,aK.yG);
if(W||n)this.q1.blur()};e7.prototype.wV=function(w){this.MO.textContent=w};e7.prototype.$=function(w){var n=this.q1,W=w==null?"":w,D=n.tagName=="SPAN";
if(D){n.textContent=" "+W;if(this.hJ)n.appendChild(this.hJ)}else n.value=W};e7.prototype.a4A=function(w){this.hJ.textContent=w};
e7.prototype.b=function(){return this.q1.value};e7.prototype.Me=function(){this.q1.select();this.q1.focus()};
e7.prototype.p8=function(w){this.S(new ed(b.E.A,!1))};e7.prototype.alI=function(w){this.S(new ed("input",!1))};
function i2(w,n,W,D,j,I,U,M,m){eg.call(this);if(j==null)j=0;this.e=e.t("span","fitem");var l=e.iF();
this.lU=w;this.jv=M;this.b4=0;this.vp=m;this.rW=n;this.xR=W;this.hH=null;if(D instanceof Array){this.hH=D;
D=D[0]}this.xp=D;this.wY=j;this.aj6=I;this.R0=U;this.Ju=0;this.MO=e.t("label","flabel");this.MO.setAttribute("style","cursor:col-resize;");
this.n7=e.t("input");this.n7.setAttribute("type","range");if(U){this.n7.min=0;this.n7.max=400}else{this.n7.min=n;
this.n7.max=W;if(j!=0)this.n7.step=(W-n)/200}this.q1=e.t("input");this.q1.setAttribute("type","text");
this.q1.setAttribute("id",l);this.hJ=e.t("span");this.hJ.textContent=D;e.xr(this.q1);this.q1.addEventListener("change",this.p8.bind(this),!1);
this.q1.addEventListener("keydown",this.rM.bind(this),!1);this.q1.addEventListener("keyup",this.fW.bind(this),!1);
this.q1.addEventListener("wheel",this.JR.bind(this),!1);this.n7.addEventListener("input",this.p8.bind(this),!1);
if(m)this.n7.addEventListener("change",this.p8.bind(this),!1);this.n7.addEventListener("click",this.a6c.bind(this),!1);
this.a0V=this.ap7.bind(this);this.aiQ=this.axx.bind(this);this.a9B=this.asj.bind(this);this.fB=0;this.b7=0;
this.E6=!1;e.L_(this.MO,this.a0V);e.ZS(this.MO)}i2.prototype=new eg;i2.prototype.Z6=function(w){this.wY=w};
i2.prototype.wV=function(w){this.MO.style.display=w?"inherit":"none";if(w)this.MO.textContent=fV.get(w)};
i2.prototype.f=function(){var bK=this.lU,w=this.jv;if(bK){if(typeof bK=="string"&&bK.startsWith("<"))this.MO.innerHTML=bK;
else this.q6()}if(w){w=fV.get(w);if(bK)this.MO.setAttribute("title",w);this.q1.setAttribute("title",w)}};
i2.prototype.$=function(w,n){var W=this.rW==this.xR,j;if(!W&&this.rW>=0)w=Math.max(this.rW,w);if(this.wY==0)w=Math.round(w);
var D=this.xp;this.b4=w;this.q1.value=(this.wY!=0?w.toFixed(this.wY):w)+(this.aj6&&D?(D.toLowerCase()==D.toUpperCase()?"":" ")+D:"");
if(-this.rW==this.xR)j=200+Math.sign(w)*200*Math.pow(Math.abs(w)/this.xR,1/2.7);else j=400*Math.pow((w-this.rW)/(this.xR-this.rW),1/2.7);
this.n7.value=this.R0?j:w;if(n)this.bX()};i2.prototype.b=function(){var w=this.b4;if(isNaN(w))w=0;return w};
i2.prototype.xm=function(){return this.xp};i2.prototype.p8=function(w){var n=0;if(w.currentTarget==this.q1){var W=w.target.value,D=0;
n=W==""?0:this.xp?parseFloat(W):eval(W);if(isNaN(n))n=0;while(D<W.length&&(W.charAt(D)=="."||48<=W.charCodeAt(D)&&W.charCodeAt(D)<=57))D++;
var j=W.slice(D).trim();if(this.hH&&this.hH.indexOf(j)!=-1)this.xp=j}else{if(Date.now()-this.Ju<10)return;
n=parseFloat(w.target.value);if(this.R0){if(-this.rW==this.xR)n=Math.sign(n-200)*Math.pow(Math.abs(n-200)/200,2.7)*this.xR;
else n=this.rW+Math.pow(n/400,2.7)*(this.xR-this.rW);n=this.a9V(n)}}this.$(n);if(w.type=="input"&&this.vp)return;
this.bX()};i2.prototype.bX=function(){this.S(new ed(b.E.A))};i2.prototype.a9V=function(w){if(this.xR-this.rW>50&&w>10)w=Math.round(w);
return w};i2.prototype.rM=function(w){var n=0;if(aK.$L(w.code,aK.Fe))n=1;if(aK.$L(w.code,aK.I$))n=-1;
if(n!=0)this.aay(n,w.shiftKey)};i2.prototype.fW=function(w){var n=aK.$L(w.code,aK.QX),W=aK.$L(w.code,aK.yG);
if(n)this.$(this.b());if(W||n)this.q1.blur()};i2.prototype.JR=function(w){this.aay(w.deltaY>0?-1:1,w.shiftKey)};
i2.prototype.aay=function(w,n){var W=this.b(),D=this.wY,j=w*(D==null||D==0||W>5?1:.1);if(n)j*=10;var I=W+j;
if(!this.R0&&this.xR!=this.rW)I=Math.min(this.xR,I);this.$(I);this.bX()};i2.prototype.a6c=function(w){var n=Date.now()-this.Ju;
this.Ju=Date.now();if(n>200)return;var W=this.rW,D=this.xR,j=(W+D)/2;if(W<1&&D>1&&D<10)j=1;else if(W<90&&D>110)j=100;
else if(W<0&&D>0)j=0;this.$(j);this.bX()};i2.prototype.ap7=function(w){e.Ko(document,this.aiQ);e.d6(document,this.a9B);
this.fB=e.rv(w,document.body).x;this.b7=this.b()};i2.prototype.axx=function(w){e.oz(w);var n=this.rW==this.xR,W=e.rv(w,document.body).x,D=(W-this.fB)*(n?1:1/120*(this.xR-this.rW)),j=this.b7+D;
if(n)j=Math.round(j);if(!n){if(!0){j=Math.max(this.rW,j);if(j==this.rW){this.fB=W;this.b7=this.rW}}if(!this.R0){j=Math.min(this.xR,j);
if(j==this.xR){this.fB=W;this.b7=this.xR}}j=this.a9V(j)}this.E6=!0;this.$(j);if(!this.vp)this.bX()};
i2.prototype.asj=function(w){if(!this.E6)this.q1.focus();this.E6=!1;if(this.vp)this.bX();e.MC(document,this.aiQ);
e.i_(document,this.a9B)};i2.prototype.Me=function(){this.q1.select();this.q1.focus()};function g_(w,n,W,D,j,I,U,M,m,l){i2.call(this,w,n,W,D,j,!0,I,m,l);
e.W0(this.e,"rangedropinput");this.e.appendChild(this.MO);this.q1.setAttribute("style","width:"+(M?M:3.3)+"em");
this.e.appendChild(this.q1);this.at3=e.t("span","rangecontFloat");this.at3.appendChild(this.n7);this.XP=e.t("button");
this.XP.textContent="\u25BC";e.L_(this.XP,this.acf.bind(this));if(U!=!0)this.e.appendChild(this.XP);
this.eo=new eg;this.eo.e=this.at3}g_.prototype=new i2;g_.prototype.acf=function(w){if(e.LY(this.eo.e))return;
w.stopPropagation();var n=this.e.getBoundingClientRect();this.n7.setAttribute("style","width:"+n.width+"px;");
var W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:this.eo,x:n.left-10,y:n.top+n.height};this.S(W)};function f2(w,n,W,D,j,I){i2.call(this,w,n,W,D,j,!1,I);
this.e.appendChild(this.MO);var U=e.t("span");this.e.appendChild(U);U.appendChild(this.n7);this.e.appendChild(this.q1);
this.q1.setAttribute("style","width:3.3em");if(this.xp)this.e.appendChild(this.hJ)}f2.prototype=new i2;
function eu(w,n,W,D,j,I,U,M){i2.call(this,w,n,W,D,j,!0,I,null,U);e.W0(this.e,"trangeinput");this.e.appendChild(this.MO);
this.e.appendChild(this.q1);var m=e.t("span");if(M!=!0)this.e.appendChild(m);m.appendChild(this.n7)}eu.prototype=new i2;
function i0(w,n,W){eg.call(this);if(!n)return;this.JV=0;this.lU=w;this.Jg=null;this.anJ=W;this.ei=[];
var D="dd"+e.iF();this.e=e.t("span","fitem ddmenu");if(w){this.MO=e.t("label","flabel");this.e.appendChild(this.MO);
this.MO.setAttribute("for",D)}this.q1=e.t("select");this.q1.setAttribute("id",D);this.e.appendChild(this.q1);
this.q1.addEventListener("change",this.p8.bind(this),!1);function j(I){var U=0;if(aK.$L(I.code,aK.Fe))U=1;
if(aK.$L(I.code,aK.I$))U=-1;if(U!=0)I.stopPropagation()}this.q1.addEventListener("keydown",j,!1);this.q1.addEventListener("keyup",j,!1);
this.iW=[];this.VX=null;this.TF(n,W);this.f()}i0.prototype=new eg;i0.prototype.wV=function(w){this.lU=w;
this.f()};i0.prototype.f=function(){this.q6();if(this.VX)this.TF(this.VX,this.anJ);this.$(this.JV)};
i0.prototype.b=function(){return this.JV};i0.prototype.TF=function(w,n){e._g(this.q1);var W=[],D=0;if(n){W.push(n[0]);
for(var L=1;L<n.length;L++)W.push(W[L-1]+n[L])}this.VX=w;this.Jg=[];this.anJ=n;for(var L=0;L<w.length;
L++){var j=e.t("option");if(this.ei.indexOf(L)!=-1)j.setAttribute("disabled","");j.textContent=fV.get(w[L]);
j.setAttribute("value",L);this.q1.appendChild(j);this.iW.push(j);this.Jg.push(L+D);if(W.indexOf(L+1)!=-1&&L!=w.length-1){var I=e.t("option");
I.setAttribute("disabled","");I.textContent="";this.q1.appendChild(I);D++}}};i0.prototype.a1y=function(L){var w=this.ei,n=w.indexOf(L);
if(n==-1)w.push(L);this.f()};i0.prototype.aq1=function(L){var w=this.ei,n=w.indexOf(L);if(n!=-1)w.splice(n,1);
this.f()};i0.prototype.$=function(w){this.JV=w;this.q1.selectedIndex=this.Jg[w]};i0.prototype.p8=function(w){this.JV=this.Jg.indexOf(this.q1.selectedIndex);
this.S(new ed(b.E.A,!1))};i0.prototype.Me=function(){this.q1.focus()};function j$(w,n,W,D){eg.call(this);
if(!n)return;this.JV=0;this.ao5=D;this.e=e.t("span","fitem bbmenu");this.jc=e.t("label","flabel");if(w){this.lU=w;
this.jc.textContent=w+":";this.e.appendChild(this.jc)}this.iW=[];this.Aq=e.t("span");this.e.appendChild(this.Aq);
this.VX=null;this.TF(n,W);this.$(0)}j$.prototype=new eg;j$.prototype.wV=function(w){this.lU=w;this.f()};
j$.prototype.f=function(){var w=this.jc.parentNode!=null,n=this.e;if(this.lU!=null){if(!w){n.appendChild(this.jc);
n.appendChild(this.Aq)}this.jc.textContent=fV.get(this.lU)+": "}else if(w)n.removeChild(this.jc);for(var L=0;
L<this.iW.length;L++)this.iW[L].f()};j$.prototype.b=function(){return this.JV};j$.prototype.TF=function(w,n){e._g(this.Aq);
this.iW=[];this.VX=w;for(var L=0;L<w.length;L++){var W=new iP(w[L],!1,n?n[L]:null,this.ao5);W.h("click",this.p8,this);
this.Aq.appendChild(W.e);this.iW.push(W)}this.f()};j$.prototype.$=function(w){this.JV=w;for(var L=0;
L<this.iW.length;L++)this.iW[L].OD();this.iW[w].d3()};j$.prototype.p8=function(w){var L=this.iW.indexOf(w.target);
this.$(L);this.S(new ed(b.E.A,!1))};j$.ES=function(w,n,W){if(n==null)n=16;var D=j$.Ml,j=D.getContext("2d"),I=n>>>1;
D.width=D.height=n;var U=[];for(var L=0;L<w.length;L++){if(w[L][0]=="-")U.push(w[L].slice(1));else if(w[L]=="checker"||w[L].startsWith("#")){if(w[L]=="checker"){j.fillStyle="white";
j.fillRect(0,0,n,n);j.fillStyle="#bbbbbb";j.fillRect(I,0,I,I);j.fillRect(0,I,I,I)}else if(w[L].startsWith("#")){j.fillStyle=w[L];
j.fillRect(0,0,n,n)}U.push("<img src=\""+D.toDataURL()+"\" />")}else U.push(e.DZ(w[L],null,W?W:"autoscale"))}return U};
j$.Ml=e.t("canvas");function jw(w,n,W,D,j,I){eg.call(this);this.e=e.t("span","fitem mbox");this.a2l=W;
this.a18=j;if(w){this.lU=w;this.jc=e.t("label","flabel");this.e.appendChild(this.jc)}this.Ci=n;this.a0=[];
for(var L=0;L<n.length;L++){var U=W?new iP(n[L],!1,D?D[L]:null,!1,I):new b7(n[L],!0,"");U.h(W?"click":b.E.A,this.p8,this);
this.a0.push(U);this.e.appendChild(U.e)}this.f()}jw.prototype=new eg;jw.prototype.$=function(w){for(var n=0;
n<this.Ci.length;n++)this.a0[n].$(w[n])};jw.prototype.b=function(){var w=[];for(var n=0;n<this.Ci.length;
n++)w[n]=this.a0[n].b();return w};jw.prototype.f=function(){if(this.lU)this.jc.innerHTML=fV.get(this.lU)+": ";
var w=this.a0;for(var n=0;n<w.length;n++){w[n].f();if(n==w.length-1)w[n].e.style.marginRight="0px"}};
jw.prototype.p8=function(w){var L=this.a0.indexOf(w.currentTarget),n=this.a0[L];if(this.a2l)n.$(!n.b());
if(this.a18){var W=n.b();for(var L=0;L<this.a0.length;L++)this.a0[L].$(!1);n.$(W)}this.S(new ed(b.E.A,!1))};
function dX(w,n){eg.call(this);this.Qf=[];this.g=[];this.a5o=w;this.HQ=n;this.i4=0;this.n_=null;this.Ol=new ec(0,0);
if(n!=null){this.zg=new cA([{name:[6,37]},{name:[5,4]}]);this.zg.parent=this;this.zg.h("select",this.pU,this)}this.e=e.t("div","imageset scrollable");
this.e.addEventListener("contextmenu",e._L,!1)}dX.prototype=new eg;dX.prototype.f=function(){if(this.zg)this.zg.f()};
dX.prototype.pU=function(w){var L=this.zg.aJ()[0],n=new ed(b.E.L,!0),W={d:b.c.oj,AH:this.HQ,G2:this.g.slice(0)};
if(L==0){var D=this.n_[1][this.g[0]];W.BX="rnm";n.data={d:b.c.P2,jW:"namewindow",Z1:D,j2:{Y:b.E.L,W:W}}}else{n.data=W;
W.BX="del"}this.S(n)};dX.prototype.aog=function(){return this.i4};dX.prototype.h8=function(w){this.i4=w;
if(this.n_)this.Uc()};dX.prototype.jJ=function(w,n,W,D){this.n_=[w,n,W,D];this.Uc()};dX.prototype.Uc=function(){var w=this.n_,n=w[0],W=w[1],D=w[2],j=w[3];
this.Qf=[];this.e.innerHTML="";var I=this.nV.bind(this),U=this.i4;if(U==0)e.W0(this.e,"imageset");else e.IX(this.e,"imageset");
for(var L=0;L<n.length;L++){var M=n[L],m=null;if(M==null){this.Qf.push(null);continue}if(typeof M=="string"){m=e.t("img","image");
m.setAttribute("src",M)}else m=M;if(D)e.UE(m,D,j);if(this.a5o)e.W0(m,"gsicon");if(U==0){}else{var l=e.t("div","listitem");
l.appendChild(m);var A=e.t("span");A.textContent=W?W[L]:"Item "+(L+1);A.setAttribute("style","margin-left:4px;");
l.appendChild(A);m=l}if(W)m.setAttribute("title",W[L]);m.addEventListener("mousedown",I,!1);this.Qf.push(m);
this.e.appendChild(m)}};dX.prototype.nV=function(w){if(this.HQ==null)w.preventDefault();var n=this.Qf.indexOf(w.currentTarget),W=window.__kb,D=this.g,j=D.length;
if(W.U(aK.WO)){var I=Math.min(D[0],D[D.length-1],n),U=Math.max(D[0],D[D.length-1],n);D=[];for(var L=I;
L<=U;L++)D.push(L)}else if(W.U(aK.CQ)){var M=D.indexOf(n);if(M==-1)D.push(n);else D.splice(M,1)}else D=[n];
D.sort(function(g,k){return g-k});if(w.button==0||j==1)this.$(D);this.Ol=e.rv(w,w.currentTarget);if(w.button==0)this.S(new ed(b.E.A));
if(w.button==2&&this.zg){var m=this.zg;m.update(null);var l=e.rv(w,document.body),A=new ed(b.E.L,!0);
A.data={d:b.c.Uq,BT:m,x:l.x,y:l.y+2};this.S(A)}};dX.prototype.b=function(){return this.g.slice(0)};dX.prototype.ahl=function(){var w=this.Ol;
return new ec(w.x,w.y)};dX.prototype.$=function(w){this.g=w.slice(0);for(var L=0;L<this.Qf.length;L++){var n=this.Qf[L];
if(n==null)continue;if(w.indexOf(L)!=-1)e.W0(n,"selected");else e.IX(n,"selected")}};function jT(w,n,W,D,j,I,U){eg.call(this);
this.e=e.t("span","fitem "+W);this.bL=new eg;this.bL.e=e.t("div","floatcont");this.bL.e.setAttribute("style","width: "+(D+1.5)+"em;");
this.bL.parent=this;this.abG=e.t("div");this.bL.e.appendChild(this.abG);this.sz=e.t("div");this.bL.e.appendChild(this.sz);
if(w){this.lU=w;this.jc=e.t("label","flabel");this.e.appendChild(this.jc)}this.d=e.t("button",U?"nopadding":"");
this.d.setAttribute("style","position:relative;");var M=this.E0.bind(this),m=this.rS.bind(this);e.L_(this.d,n?m:M);
this.e.appendChild(this.d);this.p2=e.t("img",U?"gsicon":"");this.d.appendChild(this.p2);if(n){var l=e.t("button");
l.textContent="\u25BC";e.L_(l,M);this.e.appendChild(l)}else{var A=e.t("span");A.textContent="\u25BC";
A.setAttribute("style","position:absolute; bottom:2px; right:4px;");this.d.appendChild(A)}var g=e.t("span");
this.sz.appendChild(g);g.setAttribute("style","display:inline-block; vertical-align:top; width:"+D+"em;");
this._e=new dX(U,I);g.appendChild(this._e.e);this._e.parent=this.bL;this._e.h(b.E.A,this.J2,this);this._e.e.style.height=j+"em";
this.LP=e.t("button");this.LP.textContent="\u25BC";this.LP.setAttribute("style","padding:3px");e.L_(this.LP,this.UN.bind(this));
this.sz.appendChild(this.LP);var k=this.AU(),$=this.ajW=I!=bk.gB&&I!=bk.Iv?I:null,C=this.arp=I==null?!1:bk.Fj[I][4]!=0,f=I==null?"":bk.Fj[I][0].toUpperCase(),z=[];
if($)z.push({name:[12,87]});z.push({name:["VAR0 / VAR1",[25,3,0],[25,3,1]],nW:!0});z.push({name:[[23,6],"."+(f=="ICC"?"icc .cube .look .3dl":f)]},{name:["VAR0 ."+f,[1,8]]},{name:[6,37]},{name:[5,4],nW:k.length!=0});
for(var L=0;L<k.length;L++)z.push({name:k[L].split("/").pop()});this.aec=z;this.HQ=I;this.R$=null;this.Ve=!0;
this.NK=null}jT.prototype=new eg;jT.prototype.AU=function(){return[]};jT.prototype.rS=function(){};jT.prototype.f=function(){this._e.f();
var w=this.lU;if(w)this.jc.textContent=fV.get(w)+":"};jT.prototype.wV=function(w){this.jc.textContent=w};
jT.prototype.FC=function(w){var n=this.HQ,W=0;if(n==bk.M9){W=this.R$?this.R$.length:0;w=w.slice(0)}this.R$=w;
this.Ve=!0;if(e.LY(this._e.e)||n==bk.qs)this.gx();if(n==bk.M9&&w.length-W==1&&e.LY(this.e)){this.$(w[W]);
this.Ve=!0;this.gx();this._e.$([W]);this.S(new ed(b.E.A))}};jT.prototype.pU=function(w){var n=w.target.aJ()[0];
if(this.ajW==null)n++;var W=new ed(b.E.L,!0);if(n==0){var D=this.uQ();if(this.HQ==bk.M9&&D[0].profile==null)return;
W.data={d:b.c.oj,BX:"add",AH:this.ajW,O2:D}}else if(n==1)this._e.h8(1-this._e.aog());else if(n<=5)this.Al(n-2);
else{var j=this.AU();W.data={d:b.c.VR,AH:{url:"rsrc/"+j[n-6]}}}if(W.data)this.S(W)};jT.prototype.Al=function(w){var n=new ed(b.E.L,!0),W=this._e.b(),D={d:b.c.oj,AH:this.HQ,G2:W};
if(w>1&&W.length==0){alert("No items selected");return}if(w==0)n.data={d:b.c.J0};else if(w==1)n.data={d:b.c.RN,a97:this.HQ,G2:W.length==0?null:W};
else if(w==2){var j=this._e.n_[1][W[0]];D.BX="rnm";n.data={d:b.c.P2,jW:"namewindow",Z1:j,j2:{Y:b.E.L,W:D}}}else if(w==3){n.data=D;
D.BX="del"}this.S(n)};jT.prototype.uQ=function(){return[this.b()]};jT.prototype.UN=function(w){if(this.zg==null){this.zg=new cA(this.aec);
this.zg.parent=this.bL;this.zg.h("select",this.pU,this)}if(e.LY(this.zg.e))return;w.stopPropagation();
var n=this.zg;n.f();n.update(null);var W=w.currentTarget.getBoundingClientRect(),D=new ed(b.E.L,!0);
D.data={d:b.c.Uq,BT:n,x:W.left,y:W.top+W.height};this.S(D)};jT.prototype.E0=function(w,n,W){if(e.LY(this.bL.e))return;
if(w)w.stopPropagation();this.gx();if(n==null){var D=this.d.getBoundingClientRect(),n=D.left,W=D.top+D.height}var j=new ed(b.E.L,!0);
j.data={d:b.c.Uq,BT:this.bL,x:n,y:W,SR:!0};this.S(j)};jT.prototype.a7v=function(w,n){this.E0(null,w,n)};
function fy(){eg.call(this);this.e=e.t("div");this.b4=!1;this.ZW=[new i0([12,19,1],[[13,1,7]].concat(eH.RU)),new fA([17,1]),new fA([12,46])];
for(var L=0;L<3;L++){var w=this.ZW[L];this.e.appendChild(w.e);w.h(b.E.A,this.WJ,this)}this.f()}fy.prototype=new eg;
fy.prototype.f=function(){for(var L=0;L<3;L++)this.ZW[L].f()};fy.prototype.b=function(){return this.b4.slice(0)};
fy.prototype.$=function(w){this.b4=w.slice(0);var n=this.ZW,W=n[0].b();n[1].$(w.slice(W*8,W*8+4),W);
n[2].$(w.slice(W*8+4,W*8+8),W)};fy.prototype.WJ=function(w){var n=this.ZW,W=n.indexOf(w.currentTarget);
if(W==0)this.$(this.b4);else{var D=n[0].b()*8+(W==1?0:4),j=n[W].b();for(var L=0;L<4;L++)this.b4[D+L]=j[L];
this.S(new ed(b.E.A,!1))}};function fA(w){eg.call(this);this.e=e.t("div");this.T=e.t("canvas");this.Kf=w;
this.b4=[0,20,200,255];this.Zi=0;this.P1=-1;this.acx=[];for(var L=0;L<5;L++){var n=e.t("span");n.setAttribute("style","display:inline-block;width:"+(L==0?8:L==2?7:2)+"em");
this.acx.push(n);this.e.appendChild(n)}this.aF=this.jx.bind(this);this.OO=this.Gi.bind(this);this.Ou=this.WB.bind(this);
e.ZS(this.T);e.L_(this.T,this.aF);this.e.appendChild(this.T);this.Uc()}fA.prototype=new eg;fA.prototype.f=function(){this.Uc()};
fA.prototype.$=function(w,n){this.b4=w;this.Zi=n;this.Uc()};fA.prototype.b=function(){return this.b4.slice(0)};
fA.prototype.jx=function(w){var n=this.b4,W=e.rv(w,this.T),D=W.x-8,j=-1,I=1e9;for(var L=0;L<4;L++){var U=D-n[L],M=Math.abs(U);
if(M<8&&M<I&&((L&1)==0&&U<0||(L&1)==1&&U>0)){I=U;j=L}}if(j==-1)return;this.P1=j;this.Vx=window.__kb.U(aK.PJ)||n[(j>>>1)*2]!=n[(j>>>1)*2+1];
e.Ko(window,this.OO);e.d6(window,this.Ou)};fA.prototype.Gi=function(w){var n=this.b4,W=this.P1,D=(W>>>1)*2,j=D+1,I=e.rv(w,this.T),U=Math.round(Math.max(0,Math.min(255,I.x-8)));
n[W]=U;if(this.Vx&&n[D]>=n[j])this.Vx=!1;if(!this.Vx)n[D]=n[j]=U;this.Uc();this.S(new ed(b.E.A,!1))};
fA.prototype.WB=function(w){e.MC(window,this.OO);e.i_(window,this.Ou)};fA.prototype.Uc=function(){var w=this.T;
e.dz(w,255+16,16);var n=w.getContext("2d"),W=w.width,D=w.height,j=Math.round(255*e.V()),I=Math.round(8*e.V());
n.translate(I,0);var U=n.createLinearGradient(0,0,j,0);U.addColorStop(0,"black");U.addColorStop(1,"#"+["ffffff","ff0000","00ff00","0000ff"][this.Zi]);
n.fillStyle=U;n.fillRect(0,0,j,I);var M=this.acx,m=fV.get(this.Kf)+":";M[0].textContent=m;for(var L=0;
L<4;L++){var l=this.b4[L];M[1+L].textContent=l;var A=Math.round(l*e.V());n.beginPath();n.moveTo(A,I);
n.lineTo(A,I+I);n.lineTo(A+((L&1)==0?-1:1)*I,I+I);n.closePath();n.fillStyle=L<2?"#666666":"#cccccc";
n.fill();n.strokeStyle="black";n.stroke()}};function aA(w,n,W){eg.call(this);if(W==null)W=!1;this.Z=[0,0,1];
this.asY=n;this.aku=W;this.a4n=0;var D="ai"+e.iF();this.e=e.t("span","fitem angleinput");if(w){this.jc=e.t("label","flabel");
this.lU=w;this.e.appendChild(this.jc);this.jc.setAttribute("for",D)}this.lX=W?44:20;this.T=e.t("canvas","gsicon");
this.VE=this.T.getContext("2d");e.ZS(this.T);e.dz(this.T,this.lX*2+1,this.lX*2+1);this.VE.scale(e.V(),e.V());
this.e.appendChild(this.T);e.L_(this.T,this.WI.bind(this));this.k7=this.n$.bind(this);this.sE=this.KJ.bind(this);
var j=this.p8.bind(this),I=e.t("div");I.setAttribute("style","display:inline-block; vertical-align:middle;");
if(!W)this.e.appendChild(I);this.Tl=[];for(var L=0;L<2;L++){var U=e.t("input");this.Tl.push(U);U.setAttribute("type","text");
e.xr(U);if(L==0)U.setAttribute("id",D);U.addEventListener("change",j,!1);var M=e.t("span");M.textContent="\xB0";
if(L==0||n){I.appendChild(U);I.appendChild(M);e.x$(I)}}this.$(this.Z)}aA.prototype=new eg;aA.prototype.f=function(){if(this.lU)this.jc.textContent=fV.get(this.lU)+":"};
aA.prototype.wV=function(w){this.jc.textContent=w};aA.prototype.b=function(){return this.Z.slice(0)};
aA.prototype.$=function(w,n){var W=this.Z;w=w.slice(0);if(w[0]==null)w[0]=W[0];if(w[1]==null)w[1]=W[1];
if(w[2]==null)w[2]=W[2];this.Z=w;var D=w[0],j=w[1],I=w[2],U=this.asY,M=this.aku,m=this.lX*.85;if(!U)j=0;
this.Tl[0].value=D;this.Tl[1].value=j;var l=this.VE;l.clearRect(0,0,100,100);D=Math.PI*D/180;j=m*(90-j)/90;
var A=this.lX+.5;l.save();l.translate(A,A);l.rotate(-D);l.strokeStyle="rgba(0,0,0,0.5)";l.beginPath();
l.ellipse(0,0,m,m*I,0,0,2*Math.PI);if(M){l.moveTo(0,-m*I);l.lineTo(0,m*I);l.moveTo(-j,0)}else l.moveTo(0,0);
l.lineTo(j,0);l.stroke();var g=this.lX*.15;l.fillStyle="black";l.beginPath();if(M){l.arc(0,-m*I,g*.66,0,2*Math.PI);
l.arc(0,m*I,g*.66,0,2*Math.PI)}if(U){l.arc(j,0,g*.4,0,2*Math.PI)}else{l.moveTo(A-g,-g*.66);l.lineTo(A,0);
l.lineTo(A-g,g*.66)}l.fill();l.restore();if(n)this.p8()};aA.prototype.p8=function(w){var n=parseInt(this.Tl[0].value);
if(isNaN(n))n=0;var W=parseInt(this.Tl[1].value);if(isNaN(W))W=0;n=n%360;W=W%360;this.$([n,W]);this.S(new ed(b.E.A,!1))};
aA.prototype.WI=function(w){e.Ko(window,this.k7);e.d6(window,this.sE);var n=e.rv(w,this.T),A=0,g=1e9;
n.x-=this.lX;n.y-=this.lX;var W=this.Z,D=W[0]*Math.PI/180,j=(90-W[1])/90,I=W[2],U=this.lX*.85,M=Math.sin(-D),m=Math.cos(-D),l=[new ec(m*U,M*U)];
if(this.aku)l.push(new ec(-M*U*I,m*U*I),new ec(M*U*I,-m*U*I));for(var L=0;L<l.length;L++){var k=ec.cS(n,l[L]);
if(k<g){g=k;A=L}}this.a4n=A;if(A==0)this.n$(w)};aA.prototype.n$=function(w){var n=e.rv(w,this.T),W=this.a4n,D=[],j=n.x-this.lX,I=n.y-this.lX,U=this.lX*.85;
if(W==0){var M=180*Math.atan2(-I,j)/Math.PI,m=90-90*Math.min(1,Math.sqrt(j*j+I*I)/U);if(w.shiftKey)M=Math.round(M/15)*15;
D=[Math.round(M),Math.round(m)]}else D=[null,null,Math.max(.01,Math.min(1,Math.sqrt(j*j+I*I)/U))];this.$(D);
this.S(new ed(b.E.A,!1))};aA.prototype.KJ=function(w){this.S(new ed(b.E.A,!1));e.MC(window,this.k7);
e.i_(window,this.sE)};function dl(w,n){eg.call(this);this.b4=0;this.cH=n;this.e=e.t("span","fitem angleinput");
if(w){this.jc=e.t("label","flabel");this.lU=w;this.e.appendChild(this.jc)}this.T=e.t("canvas","gsicon");
this.VE=this.T.getContext("2d");e.dz(this.T,n,n);this.e.appendChild(this.T);e.ZS(this.T);e.L_(this.T,this.WI.bind(this));
this.k7=this.n$.bind(this);this.sE=this.KJ.bind(this);this.$(0)}dl.prototype=new eg;dl.prototype.f=function(){if(this.lU)this.jc.textContent=fV.get(this.lU)+":"};
dl.prototype.wV=function(w){this.jc.textContent=w};dl.prototype.b=function(){return this.b4};dl.prototype.azi=function(w){var n=this.b4,W=Math.floor(n/3),D=n-W*3;
D=Math.max(0,Math.min(2,D+w.x));W=Math.max(0,Math.min(2,W+w.y));this.$(W*3+D)};dl.prototype.$=function(w){this.b4=w;
var n=this.T.width,W=Math.floor(w/3),D=w-3*W,j=(D+.5)*n/3,I=(W+.5)*n/3,U=this.VE,M=[.5,Math.round(n/3)+.5,Math.round(2*n/3)+.5,n-.5];
U.clearRect(0,0,n,n);var m=this.cH<30;U.setLineDash([]);U.strokeStyle=m?"rgba(0,0,0,0.5)":"#000000";
U.beginPath();for(var L=0;L<4;L++){var l=M[L];U.moveTo(l,0);U.lineTo(l,n);U.moveTo(0,l);U.lineTo(n,l)}U.stroke();
if(w==9)return;if(!m){U.setLineDash([1,2]);var A=n*.53,g=Math.max(0,Math.min(n-A,j-A/2)),k=Math.max(0,Math.min(n-A,I-A/2));
U.strokeRect(Math.round(g)+.5,Math.round(k)+.5,Math.round(A),Math.round(A))}U.fillStyle="#000000";U.beginPath();
U.arc(j,I,n/8,0,Math.PI*2);U.fill()};dl.prototype.WI=function(w){e.Ko(document.body,this.k7);e.d6(document.body,this.sE);
this.n$(w)};dl.prototype.n$=function(w){var n=e.rv(w,this.T),W=Math.max(0,Math.min(2,Math.floor(n.x/(this.cH/3)))),D=Math.max(0,Math.min(2,Math.floor(n.y/(this.cH/3))));
this.$(D*3+W)};dl.prototype.KJ=function(w){this.S(new ed(b.E.A,!1));e.MC(document.body,this.k7);e.i_(document.body,this.sE)};
function ai(bK){eg.call(this);this.e=e.t("span","fitem cswatch");this.awI=0;this.Dv=[];this.uH=[];var w=this.at9.bind(this);
for(var L=0;L<bK;L++){this.Dv.push(0);var n=e.t("span","colorsample");n.addEventListener("click",w,!1);
this.uH.push(n);this.e.appendChild(n)}var W=[16711680,65280,255,65535,16711935,16776960,0,8421504,16777215],D=Math.min(bK,W.length);
for(var L=0;L<D;L++)this.Dv[L]=W[L];this.w$()}ai.prototype=new eg;ai.prototype.at9=function(w){this.awI=this.uH.indexOf(w.currentTarget);
this.S(new ed(b.E.A))};ai.prototype.b=function(){return this.Dv[this.awI]};ai.prototype.$=function(w){var n=this.Dv,W=n.indexOf(w);
if(W!=-1)n.splice(W,1);else n.pop();n.unshift(w);this.w$()};ai.prototype.w$=function(){for(var L=0;L<this.Dv.length;
L++){this.uH[L].setAttribute("style","background-color:#"+E.$$(this.Dv[L]))}};function gM(w){eg.call(this);
this.yY={o:0,B:0,k:0};this.en=w;this.e=e.t("span","fitem colorsample");this.e.addEventListener("click",this.ZU.bind(this),!1)}gM.prototype=new eg;
gM.prototype.f=function(){};gM.prototype.ZU=function(w){var n=this.yY;this.S(new ed("click"));var W=new ed(b.E.L,!0);
W.data={d:b.c.P2,jW:"colorpicker",pL:n.o<<16|n.B<<8|n.k,fT:this.$m.bind(this),NG:this.en};this.S(W)};
gM.prototype.$m=function(w){this.hR(w);this.S(new ed(b.E.A))};gM.prototype.$F=function(){this.ZU(null)};
gM.prototype.agb=function(){var w=this.yY;return w.o<<16|w.B<<8|w.k};gM.prototype.b=function(){return E.M.lW(this.yY)};
gM.prototype.hR=function(w){this.yY={o:w>>16&255,B:w>>8&255,k:w&255};this.azX()};gM.prototype.$=function(w){this.yY=E.M.y_(w);
this.azX()};gM.prototype.azX=function(){var w=this.yY,n=w.o,W=w.B,D=w.k,j=n<<16|W<<8|D;this.e.setAttribute("style","background-color:#"+E.$$(j))};
function aD(){eg.call(this);this.NO=!1;this.As=20;this.adB=10;this.vc=0;this.NO=!1;this.$h={o:255,B:0,k:0};
this.tl={o:0,B:0,k:0};this.e=e.t("canvas");this.Uc();e.ZS(this.e);e.L_(this.e,this.aF.bind(this))}aD.prototype=new eg;
aD.prototype.anH=function(w){if(this.NO==w)return;this.NO=w;this.Uc()};aD.prototype.f=function(){};aD.prototype.ayV=function(w,n){function W(D){return{o:D>>16&255,B:D>>8&255,k:D&255}}if(w!=null)this.$h=W(w);
if(n!=null)this.tl=W(n);this.Uc()};aD.prototype.aF=function(w){var n=e.rv(w,this.e),W=n.x*e.V(),D=n.y*e.V(),j=this.As,I=this.adB,U=0;
if(W<I&&D<I){U=0}else if(W>j-I&&D>j-I){U=1}else if(W<I){U=2}else{U=3}this.$F(U)};aD.prototype.$F=function(w){var n=new ed(b.E.L,!0);
if(w>1)n.data={d:b.c.oj,AH:bk.X$,vK:w};else{this.vc=w;var W=w==0?this.$h:this.tl;n.data={d:b.c.P2,jW:"colorpicker",pL:W.o<<16|W.B<<8|W.k,fT:this.$m.bind(this)}}this.S(n)};
aD.prototype.$m=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.oj,AH:bk.X$,vK:this.vc,Z:w};this.S(n)};
aD.prototype.Uc=function(){var w=this.e,n=w.getContext("2d"),W=e.V(),j="#aaaaaa",I=.62;e.dz(w,34,34);
w.setAttribute("style",w.getAttribute("style")+";cursor:pointer");var D=this.As=w.width,U=this.adB=Math.round(D*I);
function M(C,f){var z=C.o,s=C.B,O=C.k;if(f)z=s=O=Math.round(E.g7(z,s,O));var a=z<<16|s<<8|O;return"#"+E.$$(a)}function m(n,C,f,z,s,O){n.beginPath();
if(z>=O*2&&s>=O*2){n.moveTo(C+O,f);n.lineTo(C+z-O,f);n.quadraticCurveTo(C+z,f,C+z,f+O);n.lineTo(C+z,f+s-O);
n.quadraticCurveTo(C+z,f+s,C+z-O,f+s);n.lineTo(C+O,f+s);n.quadraticCurveTo(C,f+s,C,f+s-O);n.lineTo(C,f+O);
n.quadraticCurveTo(C,f,C+O,f)}n.closePath()}function l(C,f,U,z,s){n.strokeStyle=s?s:"black";n.fillStyle=z;
m(n,C+.5,f+.5,U-1,U-1,U*.2);n.fill();n.stroke()}l(D-U,D-U,U,M(this.tl,this.NO));l(0,0,U,M(this.$h,this.NO));
var A=D-U,g=Math.round(A*I);l(D-g,A-g,g,"white",j);l(D-A,0,g,"black",j);n.save();n.fillStyle=j;n.translate(0,D);
n.rotate(-Math.PI/2);A=D-U;var k=Math.round(A*.28),$=Math.round(A*.25);for(var L=0;L<2;L++){n.fillRect(k,k,A-k,1);
n.beginPath();n.moveTo(A-$,k+.5-$);n.lineTo(A,k+.5);n.lineTo(A-$,k+.5+$);n.closePath();n.fill();n.transform(0,1,1,0,0,0)}n.restore()};
function ch(w){jT.call(this,w,!1,"brushbutton nopadding",19,10,bk.zq,!0);var n=this.abG;e.W0(n,"flexrow");
var W=e.t("div");n.appendChild(W);var D=e.t("div");n.appendChild(D);D.setAttribute("style","margin-left:8px");
this.YB=new aA(null,null,!0);this.YB.h(b.E.A,this.xN,this);W.appendChild(this.YB.e);this.O9=new eu([12,14,0],1,1e3," px",0,!0);
this.O9.h(b.E.A,this.xN,this);D.appendChild(this.O9.e);this.dr=new eu([12,17],0,100,"%");this.dr.h(b.E.A,this.xN,this);
D.appendChild(this.dr.e);this.$Y=new jw(null,["<img src=\""+PIMG.prsO+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG.prsS+"\" class=\"autoscale gsicon\" />"],!0,[[15,9,0],[15,9,1]]);
this.$Y.h(b.E.A,this.xN,this);D.appendChild(this.$Y.e)}ch.prototype=new jT;ch.prototype.AU=function(){var w=["pencil","trees"];
for(var L=0;L<w.length;L++)w[L]="brushes/"+w[L]+".abr";return w};ch.prototype.$=function(w,n,W){this.NK=JSON.parse(JSON.stringify(w));
var D=Math.floor(20*e.V()),j=Math.floor(36*e.V()),I=Math.floor(24*e.V()),U=iV.sX(w,n,W,D,I,j);this.p2.setAttribute("src",U);
e.UE(this.p2,j,I);var M=w.Brsh.v;this.O9.$(M.Dmtr.v.val);if(M.Hrdn!=null){this.dr.Te();this.dr.$(M.Hrdn.v.val)}else this.dr.rx();
if(M.Angl!=null)this.YB.$([M.Angl.v.val]);if(M.Rndn!=null)this.YB.$([null,null,M.Rndn.v.val/100]);var m=[!1,!1];
if(w.opVr)m[0]=w.opVr.v.bVTy.v==2;if(w.szVr)m[1]=w.szVr.v.bVTy.v==2;this.$Y.$(m)};ch.prototype.uQ=function(){return{list:[{t:"Objc",v:this.b()}],yg:[],j6:[]}};
ch.prototype.b=function(){return this.NK};ch.prototype.gx=function(){if(!this.Ve)return;var w=[],n=[],W=this.R$,D=Math.floor(33*e.V()),j=Math.floor(40*e.V());
for(var L=0;L<W.list.length;L++){var I=W.list[L].v,U=iV.sX(I,W.yg,W.j6,D,j);w.push(U);n.push(I.Nm.v.split("=").pop())}this._e.jJ(w,n,D,j);
this.Ve=!1};ch.prototype.J2=function(w){var n=this.R$;this.$(n.list[this._e.b()[0]].v,n.yg,n.j6);this.S(new ed(b.E.A))};
ch.prototype.f=function(){jT.prototype.f.call(this);this.YB.f();this.O9.f();this.dr.f()};ch.prototype.xN=function(w){var n=this.R$,W=this.NK,D=W.Brsh.v;
D.Dmtr.v.val=this.O9.b();if(D.Hrdn!=null)D.Hrdn.v.val=this.dr.b();if(D.Angl!=null)D.Angl.v.val=this.YB.b()[0];
if(D.Rndn!=null)D.Rndn.v.val=Math.round(this.YB.b()[2]*100);if(w.target==this.$Y){var j=this.$Y.b(),I=["opVr","szVr"],U=["usePaintDynamics","useTipDynamics"];
for(var L=0;L<2;L++){var M=I[L];if(W[M]==null)W[M]=JSON.parse(bj.Hx.KK[M]);W[M].v.bVTy.v=j[L]?2:0;if(j[L])W[U[L]].v=!0}bj.Hx.amr(W)}this.$(W,n.yg,n.j6);
this.S(new ed(b.E.A))};function jJ(w){jT.call(this,w,!0,"contourbutton",17,10.5,bk.tX)}jJ.prototype=new jT;
jJ.prototype.J2=function(w){this.$(this.R$[w.target.b()]);this.S(new ed(b.E.A))};jJ.prototype.rS=function(w){var n=new ed(b.E.L,!0);
n.data={d:b.c.P2,jW:"contoureditor",xq:this.NK,response:this.as7.bind(this)};this.S(n)};jJ.prototype.as7=function(w){this.$(w);
this.S(new ed(b.E.A))};jJ.prototype.gx=function(){if(!this.Ve)return;var w=Math.floor(38*e.V()),n=Math.floor(38*e.V()),W=[],D=[],j=this.R$;
for(var L=0;L<j.length;L++){D.push(j[L].Nm?j[L].Nm.v:"");W.push(E.MU.sX(j[L].Crv.v,w,n))}this._e.jJ(W,D,w,n);
this.Ve=!1};jJ.prototype.$=function(w){this.NK=JSON.parse(JSON.stringify(w));var n=this.NK.Crv.v;for(var L=0;
L<n.length;L++)if(n[L].v.Cnty==null)n[L].v.Cnty={t:"bool",v:!0};this.qE()};jJ.prototype.qE=function(){var w=Math.floor(30*e.V()),n=Math.floor(30*e.V()),W=E.MU.sX(this.NK.Crv.v,w,n);
this.p2.setAttribute("src",W);e.UE(this.p2,w,n)};jJ.prototype.b=function(){return JSON.parse(JSON.stringify(this.NK))};
function bc(w){eg.call(this);this.HO=null;this.ww=null;this.HI=null;this.I8=null;this.abj=[];this.a7M=[];
this.e=e.t("span","fitem fillbutton");this.bL=new eg;this.bL.e=e.t("div","floatcont form");this.bL.e.setAttribute("style","width: 21em;");
this.bL.parent=this;this.Vd=w;this.jc=this.jc=e.t("label","flabel");this.e.appendChild(this.jc);this.T=e.t("canvas");
this.VE=this.T.getContext("2d");this.apk=null;this.e.appendChild(this.T);e.L_(this.T,this.E0.bind(this));
this.Xp=new j$([12,66],["","Color","Grad","Patt"]);this.bL.e.appendChild(this.Xp.e);this.Xp.h(b.E.A,this.WJ,this);
this.bL.e.appendChild(e.t("hr"));this.ahw=e.t("span");this.C5=new gM(!1);this.C5.parent=this.bL;this.C5.h(b.E.A,this.WJ,this);
this.pB=new ai(10);this.pB.h(b.E.A,this.WJ,this);this.Mx=e.t("div","marged hiline");this.Mx.appendChild(this.C5.e);
e.x$(this.Mx);this.Mx.appendChild(this.pB.e);this.kf=new bF("GrFl",!0);this.kf.parent=this.bL;this.kf.h(b.E.A,this.WJ,this);
this.GQ=e.t("div","marged hiline");var n="Grad Type Algn Angl Rvrs Scl Ofst".split(" ");for(var L=0;
L<n.length;L++){var W=this.kf.CL[n[L]].e;this.GQ.appendChild(W)}this.Rr=new bF("patternFill",!0);this.Rr.parent=this.bL;
this.Rr.h(b.E.A,this.WJ,this);this.B$=e.t("div","marged hiline");var n=["Ptrn","Angl","Scl","Algn","phase"];
for(var L=0;L<n.length;L++){var W=this.Rr.CL[n[L]].e;this.B$.appendChild(W)}}bc.prototype=new eg;bc.prototype.GZ=function(w,n){var W=ku.qr(w,n);
if(W!=null)this.pB.$(W);if(n==bk.C0){this.abj=[];this.a7M=[];if(this.HO)this.$(this.HI,this.b(),this.HO)}this.ww=w;
this.kf.GZ(w,n);this.Rr.GZ(w,n)};bc.prototype.f=function(){this.jc.textContent=fV.get(this.Vd)+": ";
this.Xp.f();this.C5.f();this.kf.f();this.Rr.f()};bc.prototype.WJ=function(w){var n=w.currentTarget;if(n==this.Xp){var W=this.Xp.b(),D={oq:W,S8:this.HO[W]};
if(W>0&&D.S8==null)D.S8=JSON.parse(JSON.stringify(at.Iz[W-1]));if(this.HO)this.$(this.HI,D,this.HO)}if(n==this.pB)this.C5.hR(n.b());
this.S(new ed(b.E.A,!1))};bc.prototype.E0=function(w){if(e.LY(this.bL.e))return;w.stopPropagation();
var n=this.T.getBoundingClientRect(),W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height+4};
this.S(W)};bc.prototype.$=function(w,n,W){this.HO=W;this.HI=w;var D=[[13,1,0],[13,0],[12,37],[12,62]],j=this.abj,I=this.a7M,U=!1,A;
for(var L=0;L<4;L++){var M={oq:L,S8:W[L]},m=bc.aiZ(M);if(I[L]==m)continue;U=!0;var l=bc.a59(null,M,this.ww,this.HI,22,22,!1);
j[L]="<img width=\"22\" height=\"22\" src=\""+l+"\" />";I[L]=m}if(U)this.Xp.TF(j,D);this.Xp.$(n.oq);
var m=bc.aiZ(n);if(m!=this.apk)bc.a59(this.VE,n,this.ww,this.HI,30,23,!0);this.apk=m;var g=n.oq;if(g==0){A=this.ahw}if(g==1){this.C5.$(n.S8.Clr.v);
A=this.Mx}if(g==2){this.kf.update(w,n.S8);A=this.GQ}if(g==3){this.Rr.update(w,n.S8);A=this.B$}if(A!=this.I8){if(this.I8!=null){this.bL.e.removeChild(this.I8)}this.bL.e.appendChild(A);
this.I8=A}};bc.prototype.b=function(){var w={oq:this.Xp.b()};if(w.oq==1){w.S8=JSON.parse(JSON.stringify(at.Iz[0]));
w.S8.Clr.v=this.C5.b()}if(w.oq==2){w.S8=this.kf.b()}if(w.oq==3){w.S8=this.Rr.b()}return w};bc.aiZ=function(w){var n=w.oq,W=w.S8,D="empty";
if(n==1){D=E.M.y_(W.Clr.v);D=D.o+","+D.B+","+D.k}if(n==2)D=JSON.stringify(W.Grad.v);if(n==3)D=W.Ptrn.v.Idnt.v;
return D};bc.a59=function(w,n,W,D,j,I,U){if(w==null)w=bc.VE;var M=Math.floor(j*e.V()),m=Math.floor(I*e.V()),l=w.canvas,A;
l.width=M;l.height=m;e.UE(l,M,m);var g=n.oq;if(g==0){w.fillStyle="#ffffff";w.fillRect(0,0,M,m);w.strokeStyle="#ff0000";
w.lineWidth=2;w.moveTo(0,0);w.lineTo(M,m);w.moveTo(0,m);w.lineTo(M,0);w.stroke()}if(g==1){var k=n.S8.Clr.v;
k=E.M.y_(k);w.fillStyle="#"+E.$$(k.o<<16|k.B<<8|k.k);w.fillRect(0,0,M,m)}if(g==2){y.mr.sX(n.S8.Grad.v,M,m,0,W.Gp,W.as,w)}if(g==3){var $=n.S8.Ptrn.v,C;
if(D!=null)C=ge.f$($,D.add.Patt);if(C==null)C=ge.f$($,W.V8);jZ.sX(C,M,m,l)}if(U){w.beginPath();w.strokeStyle="#000000";
w.fillStyle="#ffffff";w.lineWidth=2;var f=M*.7,z=Math.floor(m*.7),s=7*e.V();w.moveTo(f,z);w.lineTo(f+s,z);
w.lineTo(f+s/2,z+s/2);w.closePath();w.stroke();w.fill()}if(w==bc.VE)return l.toDataURL()};bc.VE=e.t("canvas").getContext("2d");
function jZ(w){jT.call(this,w,!1,"patternbutton",18,10,bk.C0);this.O6=null}jZ.prototype=new jT;jZ.prototype.J2=function(w){var n=this.R$[this._e.b()];
this.NK={classID:"Ptrn",Nm:{t:"TEXT",v:n.name},Idnt:{t:"TEXT",v:n.id}};this.S(new ed(b.E.A));this.qE()};
jZ.prototype.gx=function(){if(!this.Ve)return;var w=this.R$,n=Math.floor(34*e.V()),W=Math.floor(34*e.V()),D=[],j=[];
for(var L=0;L<w.length;L++){D.push(jZ.sX(w[L],n,W));j.push(w[L].name)}this._e.jJ(D,j,n,W);this.Ve=!1};
jZ.prototype.$=function(w,n){if(this.NK&&w.Idnt.v==this.NK.Idnt.v)return;this.NK=JSON.parse(JSON.stringify(w));
this.qE(n)};jZ.prototype.b=function(){return JSON.parse(JSON.stringify(this.NK))};jZ.prototype.uQ=function(){return this.O6?[this.O6]:[]};
jZ.prototype.qE=function(w){var n=Math.floor(50*e.V()),W=Math.floor(50*e.V()),D;if(w!=null)D=ge.f$(this.NK,w.add.Patt);
if(D==null)D=ge.f$(this.NK,this.R$);this.O6=D;var j=jZ.sX(D,n,W);this.p2.setAttribute("src",j);e.UE(this.p2,n,W)};
jZ.T=e.t("canvas","");jZ.sX=function(w,n,W,D){if(D==null)D=jZ.T;var j=D.getContext("2d");D.width=n;D.height=W;
if(w){var I=w.HY[1],U=I.m,M=I.n,m=w.HY[0],l=Math.min(n/U,W/M),A=l;if(A*U<2)A=2/U;var g=l;if(g*M<2)g=2/M;
var k=y.wR.lD([m,I],new eh(A,0,0,g,0,0),A>2),$=k.rect.m,C=k.rect.n,f=j.createImageData($,C);E.nX(k.buffer,f.data);
j.putImageData(f,Math.floor((n-$)/2),Math.floor((W-C)/2))}return D.toDataURL()};function jR(w,n,W){if(n==null)n=24.2;
if(W==null)W=17;jT.call(this,w,!1,"patternbutton",n,W,bk.gB);this.$o=""}jR.prototype=new jT;jR.prototype.J2=function(w){this.NK=JSON.parse(JSON.stringify(this.R$[0][this._e.b()[0]]));
this.S(new ed(b.E.A))};jR.prototype.gx=function(){var w=this.R$;if(w==null||!this.Ve)return;var n=Math.floor(50*e.V()),W=Math.floor(50*e.V()),D=[],j=[];
for(var L=0;L<w[0].length;L++){D.push(jR.sX(this.R$[0][L].nK,n,W,this.R$[1]));j.push(w[0][L].UU.Nm.v.split("=").pop())}this._e.jJ(D,j,n,W);
this.Ve=!1};jR.prototype.$=function(w,n,W,D){var j=JSON.stringify(w.nK)+","+W+","+D;if(this.$o!=j){this.$o=j;
this.NK=JSON.parse(JSON.stringify(w));this.qE(n,W,D)}};jR.prototype.b=function(){return JSON.parse(JSON.stringify(this.NK))};
jR.prototype.qE=function(w,n,W){var D=Math.floor(68*e.V()),j=Math.floor(68*e.V()),I=jR.sX(this.NK.nK,D,j,w?w:this.R$[1],n,W);
this.p2.setAttribute("src",I);e.UE(this.p2,D,j)};jR.sX=function(w,n,W,D,j,I){var U=new kc;U.m=n;U.n=W;
U.buffer=E.Q(n*W*4);U.add.Patt=D;U.UB(j==null?90:j);U.GT(I==null?30:I);var M=new iB(0,0,Math.round(n*.5),Math.round(W*.5));
M.x=Math.round((n-M.m)/2);M.y=Math.round((W-M.n)/2);var m=U.QI();m.rect=M;m.buffer=E.Q(M.O()*4);E.cJ(m.buffer,4284045657);
ge.acF(w,m,.5*100);U.C.push(m);U.X0();U.l();var l=je.YG;je.YG=!1;U.tw();var A=U.Vc();je.YG=l;var g=jj.Zz(A.buffer,U.m,U.n);
return g};function gp(w){jT.call(this,null,!1,"tpresetbutton",18,24,bk.Q6,!0);e.IX(this.e,"fitem");this._e.h8(1);
this.id=w;this.qE();this.d.style.overflow="hidden";this.wr=new b7([15,7,9]);this.wr.$(!0);this.wr.h(b.E.A,this.a29,this);
this.sz.appendChild(this.wr.e)}gp.prototype=new jT;gp.prototype.auy=function(w){if(this.id==w)return;
this.id=w;this.FC(this.R$)};gp.prototype.J2=function(w){var n=this.R$[this._e.b()],W=new ed(b.E.L,!0);
W.data={d:b.c.oj,BX:"set",AH:bk.Q6,O2:n};this.S(W)};gp.prototype.f=function(){jT.prototype.f.call(this);
this.wr.f()};gp.prototype.a29=function(){this.Ve=!0;this.gx()};gp.prototype.gx=function(){if(!this.Ve)return;
var w=Math.floor(16*e.V()),n=Math.floor(16*e.V()),W=[],D=[],j=this.R$,I=this.wr.b();for(var L=0;L<j.length;
L++){var U=y.apO(j[L]);if(!I||U==this.id){D.push(j[L][0]?j[L][0].split("=").pop():"");W.push(U==-1?"":PIMG[y.l5[U][0]])}else{W.push(null);
D.push(null)}}this._e.jJ(W,D,w,n);this.Ve=!1};gp.prototype.qE=function(){var w=this.p2;w.setAttribute("src",PIMG[y.l5[this.id][0]]);
e.W0(w,"toolicon")};gp.prototype.uQ=function(){return null};gp._C={};gp.sX=function(w,n,W){var D=gp.VE,j=gp._C,I=E.$$(w.o<<16|w.B<<8|w.k);
if(j[I])return j[I];if(D==null){var U=e.t("canvas");D=gp.VE=U.getContext("2d")}var U=D.canvas;U.width=n;
U.height=W;D.fillStyle="#"+I;D.fillRect(0,0,n,W);var M=j[I]=U.toDataURL();return M};function dA(w,n,W){eg.call(this);
this.e=e.t("span","fitem curveeditor");this.mA=null;this.auu=0;this.Zi="";this.mode=0;this.B7=w;this.a1_=n;
this.ase=W;this.kj=null;this.eD=null;this.aav=0;this.azL=0;this.hV=new ec;this.vW=this.n$.bind(this);
this.VB=this.KJ.bind(this);this.cH=256;this.T=e.t("canvas");this.VE=this.T.getContext("2d");e.ZS(this.T);
this.e.appendChild(this.T);this.zl(256,256);e.L_(this.T,this.WI.bind(this));this.coords=e.t("div");this.coords.setAttribute("style","width:250px");
this.e.appendChild(this.coords);var D=this.xR=W?100:255,j=null;this.Sg=new g_("X (in)",0,D,j,0,!1,!0);
this.Be=new g_("Y (out)",0,D,j,0,!1,!0);this.el=new b7([19,3,0]);this.Sg.h(b.E.A,this.Ce,this);this.Be.h(b.E.A,this.Ce,this);
this.el.h(b.E.A,this.Ce,this);this.coords.appendChild(this.Sg.e);if(W)this.coords.appendChild(this.el.e);
this.coords.appendChild(this.Be.e)}dA.prototype=new eg;dA.prototype.f=function(){this.el.f();this.Sg.f();
this.Be.f()};dA.prototype.zl=function(w,n){this.cH=Math.round(w);this.VE.resetTransform();e.dz(this.T,this.cH,this.cH,this.VE);
this.VE.scale(this.cH/256,this.cH/256);if(this.kj)this.T5()};dA.prototype.Ce=function(w){var L=this.ay8(),n=this.kj[L],W=255/this.xR;
n.v.Hrzn.v=this.Sg.b()*W;n.v.Vrtc.v=this.Be.b()*W;if(this.ase)n.v.Cnty.v=this.el.b();this.kj.sort(function(D,j){return D.v.Hrzn.v-j.v.Hrzn.v});
this.T5();this.S(new ed(b.E.A))};dA.prototype.$=function(w,L){var n=JSON.stringify(w);if(n==JSON.stringify(this.kj))return;
this.mode=w.length==256?1:0;this.kj=JSON.parse(n);if(L!=null)this.eD=this.kj[L];this.T5()};dA.prototype.pH=function(w,n,W){this.mA=w;
this.auu=n;this.Zi=W;this.T5()};dA.prototype.b=function(){return JSON.parse(JSON.stringify(this.kj))};
dA.prototype.ay8=function(){return this.kj.indexOf(this.eD)};dA.prototype.WI=function(w){var n=256/this.cH,W=e.rv(w,this.T);
W.x*=n;W.y*=n;var D=W.x,j=256-W.y;if(this.B7){var I=D;D=256-j;j=I}this.hV.y1(D,j);if(this.mode==0){var U=0,M=1e9,k;
for(var L=0;L<this.kj.length;L++){var m=this.kj[L].v,l=m.Hrzn.v-D,A=m.Vrtc.v-j,g=Math.sqrt(l*l+A*A);
if(g<M){M=g;U=L}}if(M<15)k=this.kj[U];else{k=E.MU.$j(D,j,!0);this.kj.push(k);this.kj.sort(function($,C){return $.v.Hrzn.v-C.v.Hrzn.v})}this.eD=k;
this.azL=this.kj.slice(0)}e.Ko(document.body,this.vW);e.d6(document.body,this.VB);this.n$(w)};dA.prototype.n$=function(w){var n=256/this.cH,W=e.rv(w,this.T);
W.x*=n;W.y*=n;var D=W.x,j=256-W.y;if(this.B7){var I=D;D=256-j;j=I}if(this.mode==0){var U=this.kj,M=this.eD,m=this.azL,l=m.indexOf(M),A=U.indexOf(M)!=-1,g=m.length-1,k=D;
if(l==0){k=Math.max(0,Math.min(m[1].v.Hrzn.v-1,D))}else if(l==g){k=Math.min(255,Math.max(m[g-1].v.Hrzn.v+1,D))}else{var $=D<0||D>255||j<0||j>255;
if(D<=m[l-1].v.Hrzn.v||D>=m[l+1].v.Hrzn.v)$=!0;if(!$&&!A)U.splice(l,0,M);if($&&A)U.splice(l,1)}if(this.a1_&&(l==0||l==m.length-1)){}else M.v.Hrzn.v=Math.round(k);
M.v.Vrtc.v=Math.max(0,Math.min(255,Math.round(j)))}else{D=Math.round(D);j=Math.round(j);D=Math.max(0,Math.min(255,D));
j=Math.max(0,Math.min(255,j));var C=this.hV.x,f=D,z=this.hV.y,s=j;if(D<this.hV.x){f=C;C=D;s=z;z=j}this.kj[D]=j;
if(C!=f)for(var O=C;O<=f;O++)this.kj[O]=Math.round(z+(O-C)*(s-z)/(f-C))}this.hV.y1(D,j);this.T5();this.S(new ed(b.E.A))};
dA.prototype.KJ=function(w){e.MC(document.body,this.vW);e.i_(document.body,this.VB);this.S(new ed(b.E.A))};
dA.prototype.T5=function(){var w=this.VE,n=this.T;w.fillStyle="#ffffff";w.fillRect(0,0,256,256);var W=256/n.width;
if(this.mA){w.save();w.translate(0,256);w.scale(1,-1);dJ.avX(w,this.mA,5700/this.auu,this.Zi);w.restore()}w.strokeStyle="#aaaaaa";
w.lineWidth=1*W;w.beginPath();for(var L=1;L<4;L++){var D=(Math.floor(64*L/W)+.5)*W;w.moveTo(0,D);w.lineTo(255,D);
w.moveTo(D,0);w.lineTo(D,255)}w.stroke();if(this.B7){w.save();w.transform(0,1,-1,0,256,0)}if(this.mode==0){var j=this.kj,I=E.MU.ou(j,256);
w.strokeStyle="#000000";w.beginPath();w.moveTo(0,255.5-I[0]);for(var L=0;L<256;L++)w.lineTo(L,255.5-I[L]);
w.stroke();w.lineWidth=2*W;for(var L=0;L<j.length;L++){var U=j[L].v;w.fillStyle=this.eD==j[L]?"#333":"#fff";
w.beginPath();w.moveTo(U.Hrzn.v,255.5-U.Vrtc.v);w.arc(U.Hrzn.v,255.5-U.Vrtc.v,5*W,0,2*Math.PI);w.stroke();
w.fill()}}else{var I=this.kj;w.strokeStyle="#000000";w.beginPath();w.moveTo(0,255.5-I[0]);for(var L=0;
L<256;L++)w.lineTo(L,255.5-I[L]);w.stroke()}if(this.B7)w.restore();var L=this.ay8();this.coords.className=L==-1?"disabled":"";
if(L==-1)return;var U=this.kj[L].v,M=255/this.xR;this.Sg.$(Math.round(U.Hrzn.v/M));this.Be.$(Math.round(U.Vrtc.v/M));
if(U.Cnty)this.el.$(U.Cnty.v)};function dJ(w,n){eg.call(this);this.e=e.t("span","");this.ps=new i0([12,4],["RGB",[13,1,1],[13,1,4],[13,1,5],[12,82]]);
this.ps.h(b.E.A,this.Uc,this);this.e.appendChild(this.ps.e);e.x$(this.e);var W=e.t("div");this.e.appendChild(W);
W.setAttribute("style","background-color: var(--bg-canvas); margin:6px 0;");this.T=e.t("canvas");var D=this.T;
W.appendChild(D);D.width=Math.round(w*e.V());D.height=Math.round(100*e.V());e.UE(D,D.width,D.height);
D.style.display="block";this.VE=D.getContext("2d");this.mA=null;this.RH=0;this.axn=null;this.apj=[];
this.Fw=[];var j=["Mean:","Pixels:"],I=this.e;if(n)for(var L=0;L<j.length;L++){var U=new ga(j[L]);this.apj.push(U);
I.appendChild(U.e);var M=new ga("hi");this.Fw.push(M);I.appendChild(M.e);e.x$(I)}}dJ.prototype=new eg;
dJ.prototype.f=function(){this.ps.f()};dJ.prototype.h8=function(w){this.ps.$(w);this.Uc()};dJ.prototype.$=function(w,n){this.mA=w;
this.axn=n;this.Uc()};dJ.prototype.hR=function(w){if(w==this.RH)return;this.RH=w;this.Uc()};dJ.prototype.Uc=function(){if(this.mA==null)return;
var w=this.T,n=this.VE,W=this.mA,D=this.axn,j=this.ps.b(),I=6e3/W[4],U="#"+E.$$(this.RH),M=dJ.avX;w.width=w.width;
n.setTransform(w.width/256,0,0,-w.height/100,0,w.height);n.globalCompositeOperation="lighter";if(j==0)M(n,W[0],I/3,U);
else if(j<4)M(n,W[j],I,U);else{M(n,W[1],I,"#ff0000");M(n,W[2],I,"#00ff00");M(n,W[3],I,"#0000ff")}n.setTransform(1,0,0,1,0,0);
if(D!=null){if(j==4)j=0;var m=0;for(var L=0;L<256;L++)m+=L*W[j][L];if(j==0)m/=3;this.Fw[0].$((m/D).toFixed(1)+"");
this.Fw[1].$(D+"")}};dJ.avX=function(w,n,W,D){w.beginPath();w.moveTo(0,0);for(var j=0;j<256;j++)w.lineTo(j,n[j]*W);
w.lineTo(256,0);w.closePath();w.fillStyle=D;w.fill()};function bL(w,n){eg.call(this);this.L$={o:0,B:0,k:0};
if(Math.abs(w-256/e.V())<10)w=256/e.V();var W=this.e=e.t("div","flexrow");W.style.position="relative";
var D=this.akw=e.t("div");W.appendChild(D);this.OJ=new ec;this.qh=new ec;this.k7=this.a3G.bind(this);
this.sE=this.aq5.bind(this);this.T=e.t("canvas","");this.VE=this.T.getContext("2d");this.T.width=this.T.height=256;
this.aey=this.VE.getImageData(0,0,256,256);this.ajF=-1;this.ayq="";e.ZS(this.T);e.L_(this.T,this.a1b.bind(this));
D.appendChild(this.T);this.atf=this.a2I.bind(this);this.a0Q=this.ave.bind(this);this.Ly=e.t("canvas","");
this.gG=this.Ly.getContext("2d");this.Ly.width=20;this.Ly.height=256;this.abA=this.gG.getImageData(0,0,20,256);
bL.abC(this.abA.data,20,256);e.ZS(this.Ly);e.L_(this.Ly,this.ae1.bind(this));W.appendChild(this.Ly);
this.T.setAttribute("style","width:"+w+"px; height:"+w+"px");this.Ly.setAttribute("style","width:16px; height:"+w+"px");
this.$b=new b7("Web Colors\u2001");this.$b.h(b.E.A,this.update,this);this.NJ=new b7("CMYK gamut");this.NJ.h(b.E.A,this.update,this);
if(n){e.x$(D);D.appendChild(this.$b.e);D.appendChild(this.NJ.e)}var j=this.tK=document.createElementNS("http://www.w3.org/2000/svg","svg");
W.appendChild(j)}bL.prototype=new eg;bL.prototype.zl=function(w,n){this.T.style.width=this.akw.style.width=w-16+"px"};
bL.prototype.$=function(w){if(this.$b.b()){var n=JSON.parse(JSON.stringify(w));bL.uk(n);var W=this.b();
if(n.o==W.o&&n.B==W.B&&n.k==W.k)w=this.L$}this.L$=w;this.update()};bL.prototype.b=function(){var w=JSON.parse(JSON.stringify(this.L$));
if(this.$b.b())bL.uk(w);return w};bL.prototype.update=function(){var w=this.L$,n=E.i8(w.o,w.B,w.k),M=18;
if(n.jB==0)n._6=this.OJ.x/255;if(n._6==0||n.jB==0)n.ag=(255-this.Hx(this.qh.y))/255;if(n.jB!=0)this.OJ.x=n._6*255;
this.OJ.y=(1-n.jB)*255;this.qh.y=(1-n.ag)*255;var W=this.aey,D=this.$b.b(),j=this.NJ.b(),I=D+","+j;if(Math.abs(n.ag-this.ajF)>.002||this.ayq!=I){this.ane(W.data,256,256,n.ag,D,j);
this.ajF=n.ag;this.ayq=I}var U=this.VE;U.putImageData(W,0,0);W=this.abA;U=this.gG;U.putImageData(W,0,0);
U.strokeStyle="#ffffff";U.beginPath();U.moveTo(0,this.qh.y);U.lineTo(20,this.qh.y);U.lineWidth=2;U.stroke();
var m=this.OJ.y/255,l=parseFloat(this.T.style.width),A=parseFloat(this.T.style.height),g=this.tK;g.setAttribute("width",M);
g.setAttribute("height",M);var k=Math.round(w.o*255)<<16|Math.round(w.B*255)<<8|Math.round(w.k*255),$="<circle cx=\""+M/2+"\" cy=\""+M/2+"\" r=\""+M/2+"\" fill=\"#"+E.$$(k)+"\"></circle>";
$+="<circle cx=\""+M/2+"\" cy=\""+M/2+"\" r=\""+(-.5+M/2)+"\" fill=\"none\" stroke=\"rgba(255,255,255,"+(.5-.2*m)+")\" stroke-width=\"1\"></circle>";
$+="<circle cx=\""+M/2+"\" cy=\""+M/2+"\" r=\""+(-1.2+M/2)+"\" fill=\"none\" stroke=\"rgba(0,0,0,0.07)\" stroke-width=\"0.4\"></circle>";
g.innerHTML=$;g.style.pointerEvents="none";g.style.filter="drop-shadow(0px 3px 2px rgba(0,0,0,0.4)";
g.style.position="absolute";g.style.left=l*(this.OJ.x/255)-M/2+"px";g.style.top=A*(this.OJ.y/255)-M/2+"px"};
bL.uk=function(w){w.o=~~(.5+w.o*5)*.2;w.B=~~(.5+w.B*5)*.2;w.k=~~(.5+w.k*5)*.2};bL.prototype.ane=function(w,n,W,D,j,I){var U=1/n,M=1/W;
for(var m=0;m<W;m++)for(var l=0;l<n;l++){var A=E.li(D,l*U,(W-m-1)*M);if(j)bL.uk(A);var L=m*n+l<<2;w[L+0]=~~(A.o*255);
w[L+1]=~~(A.B*255);w[L+2]=~~(A.k*255);w[L+3]=255}if(I){var g=w.slice(0),k=kc.Ka[0],$=kc.Ka[1];ICC.U.applyLUT($,k,g,g);
for(var L=0;L<w.length;L+=4){var C=w[L]-g[L],f=w[L+1]-g[L+1],z=w[L+2]-g[L+2],s=C*C+f*f+z*z;if(s>300)w[L]=w[L+1]=w[L+2]=200}}};
bL.abC=function(w,n,W,D,j){if(D==null)D=1;if(j==null)j=0;var I=new Uint32Array(w.buffer);for(var U=0;
U<W;U++){var M=E.li((1+D*(1-U/W)+j)%1,1,1),m=255<<24|M.k*255<<16|M.B*255<<8|M.o*255;for(var l=0;l<n;
l++)I[U*n+l]=m}};bL.prototype.a1b=function(w){e.Ko(window,this.k7);e.d6(window,this.sE);this.a3G(w);
this.tK.style.transition="transform 150ms cubic-bezier(.4,2.2,.6,.5)";this.tK.style.transform="scale(2.4)"};
bL.prototype.aq5=function(w){e.MC(window,this.k7);e.i_(window,this.sE);this.tK.style.transition="transform 200ms cubic-bezier(.4,2.2,.6,.5)";
this.tK.style.transform="scale(1)"};bL.prototype.a3G=function(w){var n=e.rv(w,this.T);n.x=n.x*(256/parseFloat(this.T.style.width));
n.y=n.y*(256/parseFloat(this.T.style.height));this.OJ.y1(this.Hx(n.x),this.Hx(n.y));this.bX()};bL.prototype.bX=function(){this.L$=this.ara();
this.S(new ed(b.E.A))};bL.prototype.ara=function(){var w=E.li((255-this.Hx(this.qh.y))/255,this.e0(this.OJ.x/255),this.e0(1-this.OJ.y/255));
return{o:w.o,B:w.B,k:w.k}};bL.prototype.ae1=function(w){e.Ko(window,this.atf);e.d6(window,this.a0Q);
this.a2I(w)};bL.prototype.ave=function(w){e.MC(window,this.atf);e.i_(window,this.a0Q)};bL.prototype.a2I=function(w){var n=e.rv(w,this.Ly);
n.y=n.y*(256/parseFloat(this.Ly.style.height));this.qh.y1(this.Hx(n.x),this.Hx(n.y));this.bX()};bL.prototype.Hx=function(w){return Math.max(0,Math.min(255,w))};
bL.prototype.e0=function(w){return Math.max(0,Math.min(1,w))};function cu(w,n,W,D){var j=j$.ES(n,D);
j$.call(this,w,j,W)}cu.prototype=new j$;function af(){eg.call(this);this.Yo=null;this.W3=new bs;this.W3.h(b.E.A,this.adh,this);
this.W3.parent=this;this.f4=new g_([12,14,0],1,150,"px",0,!0);this.f4.h(b.E.A,this.oy,this);this.f4.parent=this;
this.H1=new g_([16,0],.01,100,"px",2,!0,null,5);this.H1.h(b.E.A,this.oy,this);this.H1.parent=this;this.ar=new b7("Auto");
this.ar.h(b.E.A,this.oy,this);this.vG=new g_([16,1],-500,5e3,"%",0,!0);this.vG.h(b.E.A,this.oy,this);
this.vG.parent=this;this.z0=new g_("\u2B0D",1,300,"%",null,null,null,null,[[2,7],[22,4,3]]);this.z0.h(b.E.A,this.oy,this);
this.z0.parent=this;this.vg=new g_("\u2B0C",1,300,"%",null,null,null,null,[[2,7],[22,4,2]]);this.vg.h(b.E.A,this.oy,this);
this.vg.parent=this;this.VI=new g_([16,2],-10,10,"px");this.VI.h(b.E.A,this.oy,this);this.VI.parent=this;
this.a6=new gM(!0);this.a6.h(b.E.A,this.Xz,this);this.a6.parent=this;this.Pl=new gM(!0);this.Pl.h(b.E.A,this.Xz,this);
this.Pl.parent=this;this.L2=new gM(!0);this.L2.h(b.E.A,this.Xz,this);this.L2.parent=this;this.hT=new gM(!0);
this.hT.h(b.E.A,this.Xz,this);this.hT.parent=this;this.DI=new b7([2,3]);this.DI.h(b.E.A,this.oy,this);
this.th=new b7([14,9]);this.th.h(b.E.A,this.oy,this);this.qT=new b7([12,46]);this.qT.h(b.E.A,this.oy,this);
this.aj=new iP("...",null,null,!0);this.aj.e.style.marginLeft="-8px";e.L_(this.aj.e,this.a7S.bind(this));
this.bL=new eg;var w=this.bL.e=e.t("div","floatcont form"),j=100;this.bL.parent=this;this.f5=new g_([12,41],1,20,"px",0,!0,!0);
this.f5.e.style.marginLeft="16px";this.f5.h(b.E.A,this.oy,this);this.f5.parent=this.bL;w.appendChild(this.Pl.e);
w.appendChild(this.DI.e);e.x$(this.bL.e);w.appendChild(this.L2.e);w.appendChild(this.th.e);w.appendChild(this.f5.e);
e.x$(this.bL.e);w.appendChild(this.hT.e);w.appendChild(this.qT.e);this.Rg=new iP("<img src=\""+PIMG["type/bold"]+"\" class=\"autoscale gsicon\" />");
this.oY=new iP("<img src=\""+PIMG["type/italic"]+"\" class=\"autoscale gsicon\" />");this.JA=new iP("<img src=\""+PIMG["type/caps"]+"\" class=\"autoscale gsicon\" />");
this.Ma=new iP("<img src=\""+PIMG["type/scaps"]+"\" class=\"autoscale gsicon\" />");this.rD=new iP("<img src=\""+PIMG["type/sub"]+"\" class=\"autoscale gsicon\" />");
this.Zs=new iP("<img src=\""+PIMG["type/sup"]+"\" class=\"autoscale gsicon\" />");this.p1=new iP("<img src=\""+PIMG["type/under"]+"\" class=\"autoscale gsicon\" />");
this.ZY=new iP("<img src=\""+PIMG["type/strike"]+"\" class=\"autoscale gsicon\" />");var n=[this.Rg,this.oY,this.JA,this.Ma,this.rD,this.Zs,this.p1,this.ZY];
for(var L=0;L<n.length;L++)n[L].h("click",this.akJ,this);this.cv=new iP("<img src=\""+PIMG["par/left"]+"\" class=\"autoscale gsicon\" />");
this.iC=new iP("<img src=\""+PIMG["par/right"]+"\" class=\"autoscale gsicon\" />");this.Md=new iP("<img src=\""+PIMG["par/center"]+"\" class=\"autoscale gsicon\" />");
this.aAb=new iP("<img src=\""+PIMG["par/jleft"]+"\" class=\"autoscale gsicon\" />");this.ai6=new iP("<img src=\""+PIMG["par/jright"]+"\" class=\"autoscale gsicon\" />");
this.aki=new iP("<img src=\""+PIMG["par/jcenter"]+"\" class=\"autoscale gsicon\" />");this.aft=new iP("<img src=\""+PIMG["par/jall"]+"\" class=\"autoscale gsicon\" />");
this.aw=[this.cv,this.iC,this.Md,this.aAb,this.ai6,this.aki,this.aft];for(var L=0;L<this.aw.length;L++)this.aw[L].h("click",this.oy,this);
var W=["lind","rind","flind","bind","aind"],D=[];for(var L=0;L<5;L++)D.push("<img src=\""+PIMG["par/"+W[L]]+"\" class=\"autoscale gsicon\" /> ");
this.t_=new g_(D[0],-j,j,"px");this.ZL=new g_(D[1],-j,j,"px");this.ia=new g_(D[2],-j,j,"px");this.SG=new g_(D[3],-j,j,"px");
this.nB=new g_(D[4],-j,j,"px");this.cq=new j$([12,33],["Abc ...","... \u0623\u064A \u0628\u064A"]);this.De=new g_(["Auto VAR0",[16,0]],0,500,"%");
this.Qo=[this.t_,this.ZL,this.ia,this.SG,this.nB,this.cq,this.De];for(var L=0;L<this.Qo.length;L++){var I=this.Qo[L];
I.h(b.E.A,this.oy,this);I.parent=this}}af.prototype=new eg;af.prototype.a7S=function(w){if(e.LY(this.bL.e))return;
w.stopPropagation();var n=this.aj.e.getBoundingClientRect(),W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height+4};
this.S(W)};af.prototype.f=function(){this.W3.f();this.f4.f();this.H1.f();this.vG.f();this.VI.f();this.z0.f();
this.vg.f();this.DI.f();this.th.f();this.qT.f();this.f5.f();for(var L=0;L<this.Qo.length;L++)this.Qo[L].f()};
af.prototype.$=function(w,n,W){this.Hu=JSON.parse(JSON.stringify(w));var D=this.Hu,j=D.lJ,I=D.ci;this.Rg.$(j.FauxBold!=null?j.FauxBold:!1);
this.oY.$(j.FauxItalic!=null?j.FauxItalic:!1);this.JA.$(j.FontCaps==2);this.Ma.$(j.FontCaps==1);this.Zs.$(j.FontBaseline==1);
this.rD.$(j.FontBaseline==2);this.p1.$(j.Underline);this.ZY.$(j.Strikethrough);this.W3.$(j.Font==null?null:D.JO[j.Font].Name,n,W);
var U=j.FontSize==null?20:j.FontSize;this.f4.$(U);var M=j.Tracking;this.vG.$(M==null?0:M);this.f5.$(j._LineWidth!=null?j._LineWidth:1);
this.H1.$(j.Leading!=null&&j.Leading!=0?j.Leading:U);this.ar.$(j.AutoLeading);this.z0.$((j.VerticalScale!=null?j.VerticalScale:0)*100);
this.vg.$((j.HorizontalScale!=null?j.HorizontalScale:0)*100);this.VI.$(j.BaselineShift!=null?j.BaselineShift:0);
this.DI.$(j.FillFlag!=null?j.FillFlag:!1);this.th.$(j.StrokeFlag!=null?j.StrokeFlag:!1);this.qT.$(j._FillBackgroundFlag!=null?j._FillBackgroundFlag:!1);
this.L4(j.FillColor,this.a6);this.L4(j.FillColor,this.Pl);this.L4(j.StrokeColor,this.L2);this.L4(j._FillBackgroundColor,this.hT);
var m=I._Direction!=null?I._Direction:0,l=hd.Hm(I);for(var L=0;L<this.aw.length;L++)this.aw[L].$(l==L);
this.cq.$(m);this.De.$((I.AutoLeading!=null?I.AutoLeading:1.2)*100);this.t_.$(I.StartIndent!=null?I.StartIndent:0);
this.ZL.$(I.EndIndent!=null?I.EndIndent:0);this.ia.$(I.FirstLineIndent!=null?I.FirstLineIndent:0);this.SG.$(I.SpaceBefore!=null?I.SpaceBefore:0);
this.nB.$(I.SpaceAfter!=null?I.SpaceAfter:0)};af.prototype.L4=function(w,n){if(w){var W=hd.y_(w);n.hR(Math.round(W.o)<<16|Math.round(W.B)<<8|Math.round(W.k))}else n.hR(0)};
af.prototype.FI=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.oj,AH:bk.a8,Hu:this.Hu};this.S(w);var w=new ed(b.E.v,!0);
w.G=y.Lu;w.data={d:"updateStyles"};this.S(w)};af.prototype.akJ=function(w){var n=this.Hu.lJ,W=w.target,D=!W.zr();
if(W==this.Rg)n.FauxBold=D;if(W==this.oY)n.FauxItalic=D;if(W==this.JA)n.FontCaps=D?2:0;if(W==this.Ma)n.FontCaps=D?1:0;
if(W==this.Zs)n.FontBaseline=D?1:0;if(W==this.rD)n.FontBaseline=D?2:0;if(W==this.p1)n.Underline=D;if(W==this.ZY)n.Strikethrough=D;
this.FI()};af.prototype.oy=function(w){var n=this.Hu.lJ,W=this.Hu.ci,D=w.target;if(D==this.vG){var j=this.vG.b();
n.Tracking=j}if(D==this.H1){n.AutoLeading=!1;n.Leading=this.H1.b()}if(D==this.ar){n.AutoLeading=this.ar.b()}if(D==this.f5)n._LineWidth=D.b();
if(D==this.f4)n.FontSize=D.b();if(D==this.z0)n.VerticalScale=D.b()/100;if(D==this.vg)n.HorizontalScale=D.b()/100;
if(D==this.VI)n.BaselineShift=D.b();if(D==this.DI)n.FillFlag=D.b();if(D==this.th)n.StrokeFlag=D.b();
if(D==this.qT)n._FillBackgroundFlag=D.b();if(this.aw.indexOf(D)!=-1){W.Justification=hd.Hm(W,this.aw.indexOf(D))}if(D==this.t_)W.StartIndent=D.b();
if(D==this.ZL)W.EndIndent=D.b();if(D==this.ia)W.FirstLineIndent=D.b();if(D==this.SG)W.SpaceBefore=D.b();
if(D==this.nB)W.SpaceAfter=D.b();if(D==this.cq)W._Direction=D.b();if(D==this.De)W.AutoLeading=D.b()/100;
this.FI()};af.prototype.adh=function(w){var n=this.Hu,W=this.W3.b(),D=-1;for(var L=0;L<n.JO.length;L++)if(n.JO[L].Name==W)D=L;
if(D==-1){D=n.JO.length;var j=JSON.parse(JSON.stringify(n.JO[0]));j.Name=W;n.JO.splice(D,0,j)}n.lJ.Font=D;
this.FI()};af.prototype.Xz=function(w){var n=w.target,W=n.agb(),D={Type:1,Values:[1,(W>>16&255)/255,(W>>8&255)/255,(W>>0&255)/255]};
for(var L=0;L<4;L++)D.Values[L]=Math.round(D.Values[L]*1e3)/1e3;var j=n==this.a6||n==this.Pl?0:n==this.L2?1:2;
this.Hu.lJ[["FillColor","StrokeColor","_FillBackgroundColor"][j]]=D;this.FI()};function bs(){eg.call(this);
this.e=e.t("span","fontinput");this.FX=null;this.Yq=null;this.wZ=null;this.ob="";this.Qf={};this.T8=[];
this.zh={};this.ap1={};this.jf=[];this._Y=!1;this.MT=e.t("button","fitem");this.MT.setAttribute("style","width:9em;");
this.MT.textContent="Family Name \u25BC";this.e.appendChild(this.MT);e.L_(this.MT,this.ald.bind(this));
this.jk=new eg;this.jk.parent=this;var w=this.jk.e=e.t("div","floatcont");w.style.padding="7px 7px 3px 7px";
var n=new ga("Recent");w.appendChild(n.e);var W=this.ayB=new iP([[23,6],[22,6,0]],!1,"Load OTF / TTF file from your computer",!0);
W.h("click",this.afN,this);W.e.style.float="right";w.appendChild(W.e);e.x$(w);this.Gm=e.t("span","fitem imageset scrollable");
this.Gm.style.maxHeight="8em";w.appendChild(this.Gm);var D=e.t("div","form");this.jk.e.appendChild(D);
this.gc=new iP(e.DZ("tools/cshape",null,"autoscale"),!1,"Show Favorites Only");this.gc.h("click",this.azo,this);
D.appendChild(this.gc.e);this.VH=new e7([12,86],null,7.5);this.VH.h("input",this.Q8,this);D.appendChild(this.VH.e);
this.Lz=new j6(6.8,"\u2630");D.appendChild(this.Lz.e);this.Lz.parent=this.jk;this.Lz.h(b.E.A,this.Gf,this);
this.Lz.e.style.float="right";this.Lz.e.style.marginRight="0";this.lT=e.t("span","fitem imageset scrollable");
this.lT.style.height="30em";this.jk.e.appendChild(this.lT);this.lT.addEventListener("scroll",this.anq.bind(this),!1);
this.aY=e.t("button","fitem");this.aY.setAttribute("style","width:7em;");this.aY.textContent="SubFamily Name \u25BC";
this.e.appendChild(this.aY);e.L_(this.aY,this.ald.bind(this));this.sq=new eg;this.sq.parent=this;this.sq.e=e.t("div","floatcont");
this.dQ=e.t("span","fitem imageset scrollable");this.sq.e.appendChild(this.dQ);this.aj1=this.anK.bind(this);
this.azN=this.ayp.bind(this)}bs.prototype=new eg;bs.prototype.anq=function(w){var n=this.lT.scrollTop,W=this.T8,D=Math.floor(n/27),j=Math.min(D+20,W.length);
for(var L=D;L<j;L++)this.alb(W[L])};bs.prototype.afN=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.J0,ahh:".otf,.ttf,.ttc"};
this.S(w)};bs.prototype.f=function(){this.Lz.f();this.ayB.f();this.gc.wV(e.DZ("tools/cshape",null,"autoscale"))};
bs.prototype.azo=function(w){this.gc.$(!this.gc.zr());this.Gf()};bs.prototype.Q8=function(w){this.ob=this.VH.b().toLowerCase();
this.Gf()};bs.prototype.ald=function(w){e.oz(w);var n=w.currentTarget,W=n.getBoundingClientRect(),D=n==this.MT,j=D?this.jk:this.sq;
if(e.LY(j.e)){this.ani(j);return}if(!D&&this.FX.hz()[this.wZ]==null)return;var I=new ed(b.E.L,!0);I.data={d:b.c.Uq,BT:j,x:W.left,y:W.top+W.height};
this.S(I);if(D){this.Gf(null,!0)}};bs.prototype.anK=function(w){var n=w.currentTarget.firstChild.nextSibling.textContent;
if(w.target.tagName.toLowerCase()=="button"){var W=this.Yq.slice(0),D=W.indexOf(n);if(D==-1){W=W.slice(Math.max(0,W.length-29));
W.push(n)}else W.splice(D,1);var j=new ed(b.E.L,!0);j.data={d:b.c.oj,AH:bk.SJ,qY:W};this.S(j);this._Y=!0;
this.Gf()}else{this.agh(n,null)}};bs.prototype.ayp=function(w){this.agh(null,w.currentTarget.firstChild.textContent)};
bs.prototype.agh=function(w,n){var W=w==null?this.sq:this.jk,D=this.FX;if(w==null)w=D.hz()[this.wZ][0];
else{var j=D.My(w),I=D.hz()[this.wZ];n=hy.Kp(j,I?I[1]:"regular")}var U=D.S7(w,n)[2];this.$(U,D);this.S(new ed(b.E.A,!1));
this.ani(W);this.Gf()};bs.prototype.ani=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.Eb,BT:w};this.S(n)};
bs.prototype.b=function(){return this.wZ};bs.prototype.$=function(w,n,W){var D=this.FX;if(w!=null)this.wZ=w;
else w=this.wZ;this.FX=n;this.Yq=W;if(w!=null){var j=n.hz()[w],I,U;if(j==null){I="- "+w;U="-------"}else{I=j[0];
U=j[1];var M=this.jf;for(var L=0;L<M.length;L++)if(M[L][0][0]==I)M.splice(L,1);M.push([j,Date.now()]);
M.sort(function(g,k){return k[1]-g[1]});M=M.slice(0,10);e._g(this.Gm);for(var L=1;L<M.length;L++){var m=M[L][0],l=this.Nz(m,!0);
this._R(l,m,!0);this.Gm.appendChild(l)}var A=n.My(I);A.sort(hy.a56);this.dQ.textContent="";for(var L=0;
L<A.length;L++){var j=n.S7(I,A[L]);if(!this.Lz.Mw(j))continue;var l=this.Nz(j,!1);this.dQ.appendChild(l)}}this.MT.textContent=I.substring(0,15)+" \u25BC";
this.MT.setAttribute("title",I+", \""+w+"\"");this.aY.textContent=U.substring(0,10)+" \u25BC";this.aY.setAttribute("title",U)}};
bs.prototype.Gf=function(w,n){var W=this.FX.hz()[this.wZ],D=this.Yq,j=this.FX.OB();this.T8=[];for(var I in j){var U=D.indexOf(I)!=-1,M=this.FX.My(I),m=!1;
for(var L=0;L<M.length;L++){var l=this.FX.S7(I,M[L]),A=!0;if(this.ob.length>0&&l[0].toLowerCase().indexOf(this.ob)==-1)A=!1;
else if(!this.Lz.Mw(l))A=!1;else if(this.gc.zr()&&!U)A=!1;if(A)m=!0}var g=this.Qf[I];if(g==null){var k=hy.Kp(j[I],"regular"),$=this.FX.S7(I,k),g=this.Nz($,!0);
this.Qf[I]=g;this.lT.appendChild(g);this.zh[I]="[true,false,false]"}if(m)this.T8.push(I);var C=W!=null&&W[0]==I;
this.ap1[I]="["+m+","+C+","+U+"]";if(!n)this.alb(I)}if(W&&!this._Y){var f=this.Qf[W[0]];this.lT.scrollTop=f.offsetTop-210}this.anq();
this._Y=!1};bs.prototype.alb=function(w){var n=this.Qf[w];if(n.firstChild==null){var W=this.FX.OB(),D=hy.Kp(W[w],"regular"),j=this.FX.S7(w,D);
this._R(n,j,!0)}var I=this.zh[w],U=this.ap1[w];if(I==U)return;var M=JSON.parse(I),m=JSON.parse(U);if(M[0]!=m[0]||M[1]!=m[1]){var l=m[0]?"":"display:none; ";
if(m[1])l+="background-color:rgba(0,0,0,0.13);";n.setAttribute("style",l)}if(M[2]!=m[2])n.firstChild.setAttribute("style","opacity: "+(m[2]?"1":"0.2"));
this.zh[w]=U};bs.prototype.Nz=function(w,n){var W=e.t("div","fontitem");if(!n)this._R(W,w,n);return W};
bs.prototype._R=function(w,n,W){var D=n[W?0:1],j=W?this.aj1:this.azN,m="";w.addEventListener("click",j,!1);
if(W)w.appendChild(e.t("button","star"));var I=e.t("span","label");I.setAttribute("title",D);I.textContent=D;
w.appendChild(I);var U=e.V(),M=1/U,l=hy.uh*M,A=hy.Ns*M;if(1<U&&U<1.5)m="width:"+l+"px; height:"+A+"px;";
var g=e.t("span","thumb gsicon");if(n.a5u){m+="background: url("+n.a5u+");";if(1<U&&U<1.5)m+="background-size: "+l+"px "+A+"px;"}else{var k=Math.ceil(FNTS.list.length/hy.cols),$=Math.floor(n.p_/k),C=n.p_%k,f=$*hy.uh,z=C*hy.Ns;
if(1<U&&U<1.5){m+="background-size: "+hy.cols*l+"px "+k*A+"px;";f*=M;z*=M}m+="background-position:-"+f+"px -"+z+"px;"}g.setAttribute("style",m);
w.appendChild(g)};function j6(w,n){eg.call(this);this.e=e.t("button","fitem bbtn");this.e.addEventListener("click",this.aa9.bind(this),!1);
this.bL=new eg;this.bL.e=e.t("div","floatcont");this.bL.parent=this;this.yn=e.t("div","flexrow");this.bL.e.appendChild(this.yn);
this.Kf=n;this.iV=[];this.it=[];var W=this.yn,D=e.t("div",""),j=e.t("div","");W.appendChild(D);W.appendChild(j);
this.ie=[];for(var L=0;L<FNTS.cats.length;L++)this.ie.push({name:FNTS.cats[L],index:L,K$:0});this.NA=new b7([7,0]);
this.NA.$(!0);this.NA.h(b.E.A,this.azV,this);D.appendChild(this.NA.e);this.Ew=e.t("div","vlist marged scrollable");
this.Ew.setAttribute("style","width:10.3em; height:"+w+"em; ");D.appendChild(this.Ew);this.T9=[];for(var L=0;
L<this.ie.length;L++){var I=this.ie[L],U=new b7(I.name);this.T9.push(U);U.h(b.E.A,this.aoI,this);U.$(!0);
this.Ew.appendChild(U.e);this.iV.push(1)}this.a8z=new b7([7,0]);this.a8z.h(b.E.A,this.am0,this);this.ni=e.t("div","vlist marged scrollable");
this.ni.setAttribute("style","width:8.6em; height:"+(w+1.5)+"em; ");j.appendChild(this.ni);this.Fu=[];
for(var L=0;L<FNTS.subsetNames.length;L++){var U=new b7(FNTS.subsetNames[L]);this.Fu.push(U);U.h(b.E.A,this.a8s,this);
U.$(!1);this.ni.appendChild(U.e);this.it.push(U.b()?1:0)}}j6.prototype=new eg;j6.prototype.a8U=function(w){var n=this.Fu;
for(var L=0;L<n.length;L++){var W=(w>>>L&1)==1;this.it[L]=W;n[L].$(W)}};j6.prototype.azs=function(){return this.yn};
j6.prototype.f=function(){this.e.textContent=this.Kf?this.Kf:fV.get([25,1,0])+" \u25BC";this.NA.f();
this.a8z.f()};j6.prototype.aa9=function(w){var n=this.e.getBoundingClientRect(),W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height,SR:!1};
this.S(W)};j6.prototype.Mw=function(w){if(this.iV[w[4]]==0)return!1;else for(var n=0;n<this.it.length;
n++)if(this.it[n]==1&&(w[3]>>>n&1)==0)return!1;return!0};j6.prototype.azV=function(w){var n=w.target.b(),W=this.T9,D=this.iV;
for(var L=0;L<W.length;L++){W[L].$(n);D[L]=n?1:0}this.S(new ed(b.E.A,!1))};j6.prototype.am0=function(w){var n=w.target.b(),W=this.Fu,D=this.it;
for(var L=0;L<W.length;L++){W[L].$(n);D[L]=n?1:0}this.S(new ed(b.E.A,!1))};j6.prototype.aoI=function(w){var L=this.T9.indexOf(w.target),n=this.ie[L].index;
this.iV[n]=1-this.iV[n];this.S(new ed(b.E.A,!1));this.afo(this.T9,this.NA)};j6.prototype.a8s=function(w){var L=this.Fu.indexOf(w.target);
this.it[L]=1-this.it[L];this.S(new ed(b.E.A,!1))};j6.prototype.afo=function(w,n){var W=!0;for(var L=0;
L<w.length;L++)W=W&&w[L].b();n.$(W)};function jr(w,n,W){jT.call(this,n,!0,"gradientbutton",18,10,bk.tU);
this.Gp=-1;this.as=-1;this.a78=null;this.aaD=w;this.en=W}jr.prototype=new jT;jr.prototype.J2=function(w){var n=this.R$;
this.$(n[this._e.b()]);this.S(new ed(b.E.A))};jr.prototype.rS=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.P2,jW:"gradienteditor",M:this.NK,fT:this.a5Y.bind(this),NG:this.en};
this.S(n)};jr.prototype.a5Y=function(w){this.$(w);this.S(new ed(b.E.A))};jr.prototype.gx=function(){if(!this.Ve)return;
var w=Math.floor(36*e.V()),n=Math.floor(36*e.V()),W=[],D=[],j=this.R$,I=Date.now();for(var L=0;L<j.length;
L++){var U=j[L];D.push(U.Nm?U.Nm.v.split("=").pop():"");var M=y.mr.sX(U,w,n,Math.PI/4,this.Gp,this.as);
W.push(M)}this._e.jJ(W,D,w,n);this.Ve=!1};jr.prototype.Wc=function(w,n){this.abR(this.NK,w,n)};jr.prototype.$=function(w){this.abR(w,this.Gp,this.as)};
jr.prototype.abR=function(w,n,W){this.Gp=n;this.as=W;if(w==null)return;var D=JSON.stringify(w),j=D+n+","+W;
if(j==this.a78)return;this.a78=j;this.NK=JSON.parse(D);var I=Math.floor(80*e.V()),U=Math.floor(16*e.V()),M=y.mr.sX(this.NK,I,U,0,this.Gp,this.as);
this.p2.setAttribute("src",M);e.UE(this.p2,I,U)};jr.prototype.b=function(){var w;if(this.aaD)w=y.mr.avh(this.NK,this.Gp,this.as);
else w=JSON.parse(JSON.stringify(this.NK));return w};function c5(w){jT.call(this,w,!1,"swatchbutton",16,8.75,bk.qs)}c5.prototype=new jT;
c5.prototype.J2=function(w){this.$(this.R$[w.target.b()]);this.S(new ed(b.E.A))};c5.prototype.gx=function(){if(!this.Ve)return;
var w=Date.now(),n=Math.floor(10*e.V()),W=Math.floor(10*e.V()),D=[],j=[],I=this.R$;for(var L=0;L<I.length;
L++){j.push(I[L].A7?I[L].A7.split("=").pop():"");D.push(c5.sX(I[L],n,W))}this._e.jJ(D,j,n,W);this.Ve=!1};
c5.prototype.$=function(w){this.NK=JSON.parse(JSON.stringify(w));this.qE()};c5.prototype.qE=function(){var w=Math.floor(24*e.V()),n=Math.floor(20*e.V()),W=c5.sX(this.NK,w,n);
this.p2.setAttribute("src",W);e.UE(this.p2,w,n)};c5.prototype.b=function(){return JSON.parse(JSON.stringify(this.NK))};
c5._C={};c5.sX=function(w,n,W){var D=c5.VE,j=c5._C,I=E.$$(w.o<<16|w.B<<8|w.k);if(j[I])return j[I];if(D==null){var U=e.t("canvas");
D=c5.VE=U.getContext("2d")}var U=D.canvas;U.width=n;U.height=W;D.fillStyle="#"+I;D.fillRect(0,0,n,W);
var M=j[I]=U.toDataURL();return M};function aH(w,n,W){eg.call(this);this.e=e.t(W?"div":"span");var D=this.Lk=e.t("input");
this.Lk.setAttribute("type","file");if(n)D.setAttribute("multiple","");this.Lk.addEventListener("change",this.a3z.bind(this),!1);
this.a27=this.al5.bind(this);this.C9={};this._u=0;this.MO=w;var j=this.afR=new iP(fV.get(w)+" (0)",null,null,!0);
this.e.appendChild(j.e);j.addEventListener("click",function(I){D.click()});if(W){this.j$=e.t("div","scrollable");
this.j$.setAttribute("style","height:120px; width:100%; line-height:1.5em;");this.e.appendChild(this.j$);
this.Uc()}}aH.prototype=new eg;aH.prototype.$=function(w){};aH.prototype.b=function(w){return this.C9};
aH.prototype.a3z=function(w){var n=w.target.files;this._u=n.length;this.C9={};for(var L=0;L<n.length;
L++){var W=n[L],D=new FileReader;D.onload=this.a27;D.lU=W.name;D.readAsArrayBuffer(W)}this.afR.wV(fV.get(this.MO)+" ("+n.length+")")};
aH.prototype.al5=function(w){var n=this.C9[w.target.lU]=new Uint8Array(w.target.result);this._u--;if(this._u==0){if(this.j$)this.Uc();
this.S(new ed(b.E.A));this.Lk.value=null}};aH.prototype.Uc=function(){var w=this.j$;e._g(w);for(var n in this.C9){var W=e.t("div");
W.textContent=n;w.appendChild(W)}};function dZ(w,n,W,D,j){if(w==null)w=!1;if(n==null)n=!1;if(W==null)W=!1;
eg.call(this);this.OF=new ec;this.KP=new ec;this.Vt=72;this.Jc=72;this.wi=!0;this.Sc=!1;this.e=e.t("span");
this.LS=new g_([12,41],0,0,null,0,!1,!0,4);this.e.appendChild(this.LS.e);this.LS.h(b.E.A,this.WJ,this);
var I=["px","%"];if(w)I=I.concat(["mm","in"]);if(j){I=[[12,76,2],[12,76,6]];if(w)I=I.concat([[12,76,5],[12,76,3]])}this.jz=new i0(null,I);
this.e.appendChild(this.jz.e);e.x$(this.e);this.jz.h(b.E.A,this.WJ,this);this.Ai=new g_([12,42],0,0,null,0,!1,!0,4);
this.e.appendChild(this.Ai.e);this.Ai.h(b.E.A,this.WJ,this);var U=new iP("\u21F5",!1,null,!0);U.h("click",this.ahS,this);
this.qC=new iP("<img src=\""+PIMG["lrs/chain"]+"\" class=\"autoscale gsicon\" />",!1,[12,51]);this.qC.h("click",this.WJ,this);
this.tb=new ga("");this.tb.e.style.margin="0";this.tb.e.style.padding="0";if(n){this.e.appendChild(this.qC.e);
this.e.appendChild(this.tb.e);this.qC.d3()}else this.e.appendChild(U.e);this.gU=new g_("DPI",0,0,null,3,!1,!0,4);
this.k4=new i0(null,[["VAR0 / Inch",[12,76,2]],["VAR0 / Cm",[12,76,2]]]);if(w&&D==null){e.x$(this.e);
this.e.appendChild(this.gU.e);this.e.appendChild(this.k4.e)}this.k4.h(b.E.A,this.WJ,this);this.gU.h(b.E.A,this.WJ,this);
this.D6=new b7([12,23,1]);this.D6.h(b.E.A,this.WJ,this);if(W){e.x$(this.e);this.e.appendChild(this.D6.e)}e.x$(this.e)}dZ.prototype=new eg;
dZ.prototype.zl=function(w,n){this.LS.q1.style.width=this.Ai.q1.style.width=(w-74-this.qC.P8())/2+"px"};
dZ.prototype.Mk=function(){this.LS.Mk();this.Ai.Mk();this.jz.Mk();var w=this.e;e._g(w);this.jz.e.style.marginRight="0";
w.appendChild(this.LS.e);w.appendChild(this.qC.e);w.appendChild(this.Ai.e);w.appendChild(this.jz.e)};
dZ.prototype.Me=function(){this.LS.Me()};dZ.prototype.amp=function(w,n){this.wi=w;if(n!=null)this.Sc=n;
if(!this.wi&&!this.Sc&&this.jz.b()==0){this.jz.$(3);this.te()}};dZ.prototype.apS=function(w){this.qC.$(w)};
dZ.prototype.f=function(){this.LS.f();this.Ai.f();this.gU.f();this.k4.f();this.qC.f();this.D6.f();this.jz.f()};
dZ.prototype.ahS=function(w){var n=this.KP.x;this.KP.x=this.KP.y;this.KP.y=n;this.te();this.S(new ed(b.E.A,!1))};
dZ.prototype.WJ=function(w){if(w.target==this.jz&&!this.wi&&!this.Sc&&this.jz.b()==0)this.jz.$(3);if(w.target==this.jz||w.target==this.D6){this.te();
return}if(w.target==this.qC)w.target.$(!w.target.b());var n=this.OF,W=parseFloat(this.LS.b());if(isNaN(W))W=1;
var D=parseFloat(this.Ai.b());if(isNaN(D))D=1;var j=this.gU.b()*[1,2.54][this.k4.b()],I=this.jz.b();
if(this.wi){var U=this.Jc;if(I==1){W=this.OF.x*(W/100);D=this.OF.y*(D/100)}var M=[1,1,25.4/U,1/U][I];
W/=M;D/=M;if(this.D6.b()){W+=this.OF.x;D+=this.OF.y}if(w.target==this.gU){var m=j;if(!this.Sc){var l=m/U;
W*=l;D*=l}U=m}if(this.qC.b()){if(w.target==this.LS)D=W*(n.y/n.x);else W=D*(n.x/n.y)}W=Math.max(Math.abs(W),1);
D=Math.max(Math.abs(D),1)}else{var U=this.Vt;if(w.target==this.gU)U=j;else{if(this.qC.b()){if(w.target==this.LS)D=W*(n.y/n.x);
else W=D*(n.x/n.y)}var M=[1,1,25.4/U,1/U][I],A=W/(I==1?100:n.x*M);U=U/A}W=n.x;D=n.y}this.KP=new ec(Math.round(W),Math.round(D));
this.Jc=U;this.te();this.S(new ed(b.E.A,!1))};dZ.prototype.ai1=function(L){this.jz.$(L);this.te()};dZ.prototype.$=function(w,n,W){if(W!=!0)this.OF=w.clone();
this.KP=w.clone();if(n!=null){this.Vt=n;this.Jc=n}this.te()};dZ.prototype.te=function(){var w=this.KP.x,n=this.KP.y,W=this.Jc,D=(w/n).toFixed(3);
while(D.charAt(D.length-1)=="0")D=D.substring(0,D.length-1);if(D.charAt(D.length-1)==".")D=D.substring(0,D.length-1);
var j=" "+D+" : 1",I=function(A,g){while(g!=0){var k=g;g=A%g;A=k}return A},U=I(w,n);if(Math.min(w,n)/U<10)j=" "+Math.round(w/U)+" : "+Math.round(n/U);
this.tb.$(j);if(this.D6.b()){w-=this.OF.x;n-=this.OF.y}var M=this.jz.b();if(M==1){if(this.wi){w=100*w/this.OF.x;
n=100*n/this.OF.y}else{w=n=100*this.Vt/this.Jc}}else{w=Math.round(w);n=Math.round(n)}var m=[1,1,25.4/W,1/W][M];
w*=m;n*=m;var l=M==1||M==3?2:0;this.LS.Z6(l);this.Ai.Z6(l);this.LS.$(w);this.Ai.$(n);this.gU.$(W*[1,1/2.54][this.k4.b()])};
dZ.prototype.b=function(){return this.KP.clone()};dZ.prototype.Y0=function(){return this.Jc};function d6(w,n,W){eg.call(this);
var D=w==0?["W","X","H","Y"]:["\u250F","\u2513","\u2517","\u251B"];this.y6=w;this.azg=n;this.IK=1;this.xT=[1,1,0];
var j=this.e=e.t("div","numlist"),I=this.eG=[];for(var L=0;L<4;L++){var U=new g_(D[L],0,0,null,2,!1,!0,4,null,W&&(L==0||L==2));
U.h(b.E.A,this.WJ,this);j.appendChild(U.e);I[L]=U;if(L==1||L==3)e.x$(j)}I[4]=new b7(w==0?[12,51]:[12,91,2]);
I[4].$(!0);j.appendChild(I[4].e)}d6.prototype=new eg;d6.prototype.f=function(){var w=this.eG;for(var L=0;
L<5;L++)w[L].f();if(this.y6==0)e.We(w[0],w[2])};d6.prototype.$=function(w,n,W){if(n)this.xT=n;n=this.xT;
var D=W?w:this.y6==0?[w[2],w[0],w[3],w[1]]:[w[0],w[1],w[3],w[2]];this.IK=D[0]/D[2];for(var L=0;L<4;L++){var j=this.eG[L];
j.Z6(n[2]==0&&this.azg?0:2);j.$(E.f_.abL(D[L],n[0],n[1],n[2]))}};d6.prototype.b=function(w){var n=[],W=this.xT;
for(var L=0;L<4;L++){var D=E.f_.M_(this.eG[L].b(),W[0],W[1],W[2]);n[L]=this.azg?Math.round(D):D}return w?n:this.y6==0?[n[1],n[3],n[0],n[2]]:[n[0],n[1],n[3],n[2]]};
d6.prototype.WJ=function(w){var n=this.y6,W=this.eG.indexOf(w.currentTarget),D=this.b(!0),j=this.eG[4].b();
if(n==0){D[0]=Math.max(1,D[0]);D[2]=Math.max(1,D[2]);if(j&&W==0)D[2]=D[0]/this.IK;if(j&&W==2)D[0]=D[2]*this.IK}if(n==1){D[W]=Math.max(0,D[W]);
if(j)for(var L=0;L<4;L++)D[L]=D[W]}this.$(D,null,!0);this.S(new ed(b.E.A,!1))};function bV(){eg.call(this);
this.mp=0;this.Fw=[0,0,1,1,100,100];this.e=e.t("span","fitem");this.hb=new i0(null,[[12,89,0],[12,89,1],[12,89,2]]);
this.e.appendChild(this.hb.e);this.hb.h(b.E.A,this.WJ,this);this.LS=new g_("W",0,0,null,0,!1,!0);this.e.appendChild(this.LS.e);
this.LS.h(b.E.A,this.WJ,this);this.Ai=new g_("H",0,0,null,0,!1,!0);this.e.appendChild(this.Ai.e);this.Ai.h(b.E.A,this.WJ,this);
this.$({ib:0,x:0,y:0})}bV.prototype=new eg;bV.prototype.f=function(){e.We(this.LS,this.Ai);this.hb.f()};
bV.prototype.WJ=function(w){if(w.target==this.hb){var n=this.b(),W=this.Fw;W[this.mp*2]=n.x;W[this.mp*2+1]=n.y;
this.mp=n.ib;this.$({ib:n.ib,x:W[n.ib*2],y:W[n.ib*2+1]})}if(this.LS.b()<1)this.LS.$(1);if(this.Ai.b()<1)this.Ai.$(1);
this.S(new ed(b.E.A,!1))};bV.prototype.$=function(w){this.hb.$(w.ib);this.LS.$(w.x);this.Ai.$(w.y);if(w.ib==0){this.LS.rx();
this.Ai.rx()}else{this.LS.Te();this.Ai.Te()}};bV.prototype.b=function(){return{ib:this.hb.b(),x:this.LS.b(),y:this.Ai.b()}};
function aw(w){eg.call(this);this.e=e.t("span","");this.axI=w;this.Wa=new f2("Off X",-100,100,w?"%":"px",0,!1);
this.X9=new f2("Off Y",-100,100,w?"%":"px",0,!1);this.Wa.h(b.E.A,this.WJ,this);this.X9.h(b.E.A,this.WJ,this);
this.e.appendChild(this.Wa.e);this.e.appendChild(this.X9.e)}aw.prototype=new eg;aw.prototype.f=function(){this.Wa.f();
this.X9.f()};aw.prototype.WJ=function(w){this.S(new ed(b.E.A,!1))};aw.prototype.ajg=function(w){this.Wa.$(w.x);
this.X9.$(w.y)};aw.prototype.alT=function(){return new ec(this.Wa.b(),this.X9.b())};aw.prototype.$=function(w,n){var W=w.Hrzn.v,D=w.Vrtc.v;
if(this.axI){W=W.val;D=D.val}this.Wa.$(W);this.X9.$(D);if(n==!0)this.WJ()};aw.prototype.b=function(){var w=this.Wa.b(),n=this.X9.b();
if(this.axI)return{classID:"Pnt",Hrzn:{t:"UntF",v:{type:"#Prc",val:w}},Vrtc:{t:"UntF",v:{type:"#Prc",val:n}}};
else return{classID:"Pnt",Hrzn:{v:w,t:"doub"},Vrtc:{v:n,t:"doub"}}};function fi(){eg.call(this);this.e=e.t("span","fitem strokebutton");
this.KT=[[null,null,null,50,""],[null,0,null,50,"4 2"],[1,1,null,50,"0 2"]];this.Yn=JSON.parse(JSON.stringify(at.QO.default));
this.Jk=e.t("button");this.e.appendChild(this.Jk);e.L_(this.e,this.E0.bind(this));var w=e.t("canvas","gsicon");
this.VE=w.getContext("2d");this.Jk.appendChild(w);var n=e.t("span");n.textContent=" \u25BC";this.Jk.appendChild(n);
this.bL=new eg;this.bL.parent=this;this.bL.e=e.t("div","floatcont form");var W=this.bL.e;W.setAttribute("style","width: 16.7em;");
this.Qf=[new i0([12,40],[[19,5,2],[19,5,1],[19,5,0]]),new j$([19,9,0],["<img src=\""+PIMG["caps/butt"]+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG["caps/round"]+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG["caps/square"]+"\" class=\"autoscale gsicon\" />"]),new j$([19,9,1],["<img src=\""+PIMG["joins/miter"]+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG["joins/round"]+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG["joins/bevel"]+"\" class=\"autoscale gsicon\" />"]),new g_("Limit",0,50,null,null,null,!0,2.5),new e7([19,9,2])];
for(var L=0;L<this.Qf.length;L++){var D=this.Qf[L];W.appendChild(D.e);D.h(b.E.A,this.WJ,this)}e.x$(W);
this.uH=[];var j=this.X5.bind(this);this.Yn.strokeStyleLineWidth.v.val=3;for(var L=0;L<this.KT.length;
L++){var I=e.t("button","fitem");this.uH.push(I);W.appendChild(I);I.addEventListener("click",j,!1);var w=e.t("canvas","gsicon"),U=w.getContext("2d");
I.appendChild(w);this.axh(U,40,20,this.KT[L])}this.Yn.strokeStyleLineWidth.v.val=1}fi.prototype=new eg;
fi.prototype.E0=function(w){if(e.LY(this.bL.e))return;w.stopPropagation();var n=this.Jk.getBoundingClientRect(),W=new ed(b.E.L,!0);
W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height+4};this.S(W)};fi.prototype.WJ=function(w){var n=this.Qf,W=[];
for(var L=0;L<5;L++)W.push(n[L].b());this.Yn=this.a64(W);this.S(new ed(b.E.A,!1))};fi.prototype.X5=function(w){var n=this.uH.indexOf(w.currentTarget);
this.$(this.a64(this.KT[n]));this.S(new ed(b.E.A,!1))};fi.prototype.a64=function(w){var n=JSON.parse(JSON.stringify(this.Yn)),W=w[0],D=w[1],j=w[2],I=w[3],U=w[4];
if(W!=null)n.strokeStyleLineAlignment.v.strokeStyleLineAlignment=at.QO.n2[W];if(D!=null)n.strokeStyleLineCapType.v.strokeStyleLineCapType=at.QO.EZ[D];
if(j!=null)n.strokeStyleLineJoinType.v.strokeStyleLineJoinType=at.QO.join[j];n.strokeStyleMiterLimit.v=I;
var M=n.strokeStyleLineDashSet.v=[];U=U.split(" ");while((U.length&1)!=0)U.pop();for(var L=0;L<U.length;
L++)M.push({t:"UntF",v:{type:"#Nne",val:parseInt(U[L])}});return n};fi.prototype.f=function(){for(var L=0;
L<this.Qf.length;L++)this.Qf[L].f()};fi.prototype.$=function(w){this.Yn=JSON.parse(JSON.stringify(w));
var n=at.QO.n2.indexOf(w.strokeStyleLineAlignment.v.strokeStyleLineAlignment),W=at.QO.EZ.indexOf(w.strokeStyleLineCapType.v.strokeStyleLineCapType),D=at.QO.join.indexOf(w.strokeStyleLineJoinType.v.strokeStyleLineJoinType),j=w.strokeStyleMiterLimit.v,I=[],U=w.strokeStyleLineDashSet.v;
for(var M=0;M<U.length;M++)I.push(U[M].v.val);var m=this.Qf;m[0].$(n);m[1].$(W);m[2].$(D);m[3].$(j);
m[3].G3(D==0);m[4].$(I.join(" "));var l=[];for(var L=0;L<5;L++)l.push(m[L].b());this.axh(this.VE,40,16,l)};
fi.prototype.b=function(){return JSON.parse(JSON.stringify(this.Yn))};fi.prototype.axh=function(w,n,W,D){var j=D[0],I=D[1],U=D[2],M=D[3],m=D[4].split(" ").map(parseFloat);
e.dz(w.canvas,n,W);var l=Math.min(5,this.Yn.strokeStyleLineWidth.v.val);for(var L=0;L<m.length;L++)m[L]*=l;
w.clearRect(0,0,n,W);w.setLineDash(m);w.lineCap=["butt","round","square"][I];w.lineJoin=["miter","round","bevel"][U];
w.lineWidth=l;w.beginPath();w.moveTo(0,W/2);w.lineTo(n*2,W/2);w.stroke()};function df(w){jT.call(this,w,!1,"contourbutton",34,16,bk.Iv,!0);
this.VH=new e7([12,86],null,16);this.VH.h("input",this.Q8,this);this.bL.e.appendChild(this.VH.e);this.Ta=null;
this.ob="";this.S$=null;this.$(bI._1())}df.prototype=new jT;df.prototype.f=function(){jT.prototype.f.call(this);
this.VH.f()};df.prototype.J2=function(w){this.$(this.Ta[w.target.b()[0]]);this.S(new ed(b.E.A))};df.prototype.Q8=function(w){this.ob=this.VH.b().toLowerCase();
this.als()};df.aes=!1;df.prototype.gx=function(){if(!this.Ve)return;var w=this.R$;if(w==null||!df.aes){var n=new ed(b.E.L,!0);
n.data={d:b.c.VR,AH:{url:"rsrc/basic/fa_basic.csh"}};this.S(n);df.aes=!0}else{var W=Math.floor(38*e.V()),D=Math.floor(38*e.V());
this.S$=[];for(var L=0;L<w.length;L++)this.S$.push(df.a0X(w[L],W,D));this.als();this.Ve=!1}};df.prototype.als=function(){var w=Math.floor(38*e.V()),n=Math.floor(38*e.V());
this.Ta=[];var W=[],D=[],j=this.R$;for(var L=0;L<j.length;L++){if(j[L].fR.toLowerCase().indexOf(this.ob)==-1)continue;
this.Ta.push(j[L]);W.push(this.S$[L]);D.push(j[L].fR)}this._e.jJ(W,D,w,n)};df.prototype.$=function(w){this.NK=df.clone(w);
this.qE()};df.prototype.qE=function(){var w=Math.floor(23*e.V()),n=Math.floor(23*e.V()),W=df.a0X(this.NK,w,n);
this.p2.setAttribute("src",W);e.UE(this.p2,w,n)};df.prototype.b=function(){return df.clone(this.NK)};
df.clone=function(w){return{fR:w.fR,UU:w.UU,i:h.Rd.Tv(w.i),H8:w.H8.clone()}};df.T=null;df.yB=null;df.a0X=function(w,n,W){var D=h.Rd.Tv(w.i),j=w.H8,I=Math.min(n/j.m,W/j.n)*.9,U=new eh;
U.translate(-.5,-.5);U.scale(.95,.95);U.translate(.5,.5);U.scale(I*j.m,I*j.n);E.P.c0(D,U);var M=new h.Rd;
M.i=D;var m=M._N();m.rect.x=Math.floor((n-m.rect.m)/2);m.rect.y=Math.floor((W-m.rect.n)/2);var l=E.Q(m.rect.O()*4);
E.IL(m.channel,l,3);var A=df;if(A.T==null)A.T=e.t("canvas");var g=A.T,k=g.getContext("2d");if(g.width!=n||g.height!=W||A.yB==null){g.width=n;
g.height=W;A.yB=k.createImageData(n,W)}var $=A.yB;$.data.fill(0);E.Cb(l,m.rect,$.data,new iB(0,0,n,W));
k.putImageData($,0,0);return g.toDataURL()};function bC(w){jT.call(this,w,!1,"ICCButton",16,12,bk.M9,!0);
this._e.h8(1)}bC.prototype=new jT;bC.prototype.AU=function(){var w="Arabica 12,Ava 614,Azrael 93,Bourbon 64,Byers 11,Clayton 33,Clouseau 54,Cobi 3,Contrail 35,Cubicle 99,Django 25,Domingo 145,Faded 47,Folger 50,Fusion 88,Hyla 68,Chemical 168,Korben 214,Lenox 340,Lucky 64,McKinnon 75,Milo 5,Neon 770,Paladin 1875,Pasadena 21,Pitaya 15,Reeve 38,Remy 24,Sprocket 231,Teigen 28,Trent 18,Tweed 71,Vireo 37,Zed 32,Zeke 39".split(",");
for(var L=0;L<w.length;L++)w[L]="luts/"+w[L]+".CUBE";return w};bC.prototype.J2=function(w){this.$(this.R$[w.target.b()]);
this.S(new ed(b.E.A))};bC.prototype.gx=function(){if(!this.Ve)return;var w=Math.floor(1*e.V()),n=Math.floor(1*e.V()),W=[],D=[],j=this.R$;
for(var L=0;L<j.length;L++){var I=j[L].Nm.v.split("\\").pop().split("/").pop();D.push(I);W.push(bC.sX(j[L],w,n))}this._e.jJ(W,D,w,n);
this.Ve=!1};bC.prototype.$=function(w){this.NK=JSON.parse(JSON.stringify(w));this.qE()};bC.sX=function(w,n,W){var D=e.t("canvas"),U="ICC / 3DL / look / cube";
D.width=n;D.height=W;var j=D.getContext("2d"),I=Math.floor(14*e.V());j.font=I+"px sans-serif";if(w.Nm)U=w.Nm.v.split("\\").pop().split("/").pop();
j.fillText(U,10,I);return D.toDataURL()};bC.prototype.qE=function(){var w=Math.floor(120*e.V()),n=Math.floor(20*e.V());
this.p2.setAttribute("src",bC.sX(this.NK,w,n));e.UE(this.p2,w,n)};bC.prototype.b=function(){return JSON.parse(JSON.stringify(this.NK))};
function fw(){eg.call(this);this.L$=null;this.e=e.t("span","fitem");this.JN=new bc([14,9]);this.Vi=new g_(null,0,150,"px",1,!0,null,null,[19,2,5]);
this.d1=new fi;this.e9=[this.JN,this.Vi,this.d1];for(var L=0;L<this.e9.length;L++){var w=this.e9[L];
this.e.appendChild(w.e);w.parent=this;w.h(b.E.A,this.WJ,this)}}fw.prototype=new eg;fw.prototype.f=function(){for(var L=0;
L<this.e9.length;L++)this.e9[L].f()};fw.prototype.GZ=function(w,n){this.JN.GZ(w,n)};fw.prototype.WJ=function(w){var n=this.L$,W=this.JN.b(),D=W.oq;
n.strokeEnabled.v=D!=0;if(D!=0){n.strokeStyleContent.v=W.S8;W.S8.classID=at.QO.W_[D-1]}n.strokeStyleLineWidth.v.val=this.Vi.b();
if(w.target==this.d1)n=this.d1.b();this.L$=n;this.S(new ed(b.E.A,!1))};fw.prototype.$=function(w,n,W){this.L$=JSON.parse(JSON.stringify(n));
var D=n.strokeEnabled.v,j=n.strokeStyleContent.v,I=D?{oq:1+at.QO.W_.indexOf(j.classID),S8:j}:{oq:0};
this.JN.$(w,I,W);this.Vi.$(n.strokeStyleLineWidth.v.val);this.d1.$(n)};fw.prototype.b=function(){return JSON.parse(JSON.stringify(this.L$))};
function jb(w){var n=[[18,0],[18,1],[18,2],[18,3]],W=j$.ES(["set/front","set/union","set/difference","set/intersection"]);
j$.call(this,w?[12,36]:null,W,n)}jb.prototype=new j$;function bl(){eg.call(this);this.e=e.t("button","fitem bbtn");
e.L_(this.e,this.E0.bind(this));this.bL=new eg;this.bL.e=e.t("div","floatcont form");this.bL.e.setAttribute("style","max-width: 200px;");
this.bL.parent=this;var w=eu;this.pY=[new b7("Start"),new b7("End"),new w([12,41],0,100,"px",null,!0,null,!0),new w([12,80,0],0,100,"px",null,!0,null,!0),new w("Concavity",-50,50,"%",null,null,null,!0)];
for(var L=0;L<this.pY.length;L++){var n=this.pY[L];n.parent=this;n.h(b.E.A,this.bX,this);this.bL.e.appendChild(n.e)}this.ayl=e.t("div");
this.bL.e.appendChild(this.ayl)}bl.prototype=new eg;bl.prototype.$=function(w){for(var L=0;L<5;L++)this.pY[L].$(w[L]);
this.Uc()};bl.prototype.b=function(w){var n=[];for(var L=0;L<5;L++)n[L]=this.pY[L].b();return n};bl.prototype.f=function(){this.e.textContent=fV.get([12,93,4]);
for(var L=0;L<this.pY.length;L++)this.pY[L].f()};bl.prototype.bX=function(w){this.S(new ed(b.E.A,!1));
this.Uc()};bl.prototype.Uc=function(w){var n=this.b(),W=200,D=60;n[2]/=e.V();n[3]/=e.V();var j=E.P.AB.JJ(0,D/2,W,D/2,5,n),I=E.P.BK(j);
this.ayl.innerHTML="<svg width=\""+W+"\" height=\""+D+"\" class=\"gsicon\">\t\t\t<path d=\""+I.VN+"\" />\t\t\t</svg>"};
bl.prototype.E0=function(w){if(e.LY(this.bL.e))return;w.stopPropagation();var n=this.e.getBoundingClientRect(),W=new ed(b.E.L,!0);
W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height,SR:!0};this.S(W)};function cv(){eg.call(this);
this.e=e.t("div");this.eG=[];this.aAd=[];var w=this.sU=e.t("div"),n=e.t("h2");n.textContent="Create Teams";
w.appendChild(n);n.style.margin="26px 0 16px 0";var W=new iP("More about Teams",!1,null,!0);n.appendChild(W.e);
W.e.style.float="right";W.h("click",this.ahG,this);this.hs=e.t("div");w.appendChild(this.hs);this.ano=new e7("Team Name",null,10);
w.appendChild(this.ano.e);var D=this.atS=new iP("Create Team",null,null,!0);w.appendChild(D.e);D.h("click",this.am$,this);
var n=e.t("h2");n.textContent="Join Teams";w.appendChild(n);n.style.margin="26px 0 16px 0";this.Vm=e.t("div");
w.appendChild(this.Vm);this.avR=new e7("Team ID",null,10);w.appendChild(this.avR.e);var D=new iP("Join Team",null,null,!0);
w.appendChild(D.e);D.h("click",this.am$,this);this.ajx;this.ae0=this.mQ.bind(this);this.amc=this.awz.bind(this);
this.BJ=!1;this.Mp();this.Mb=null;this.aht=""}cv.prototype=new eg;cv.prototype.ahG=function(w){var n=new ed(b.E.L,!0);
n.data={d:b.c.aT,link:"https://www.photopea.com/api/accounts#teams"};this.S(n)};cv.prototype.Mp=function(){clearTimeout(this.az5);
this.az5=setTimeout(this.amc,this.Mb?10:3e3)};cv.prototype.awz=function(){var w=bh.rE();if(document.hidden||!e.LY(this.e)||w==null){this.Mp();
return}var n=bh.bl();if(this.Mb==null&&n==null)return;bh.qK(this.Mb?this.Mb:n,this.ae0);this.BJ=!0;this.Mb=null};
cv.prototype.ayO=function(w){w.acc.update=!0;this.e.style.pointerEvents="none";this.e.style.opacity="0.5";
if(this.BJ)this.Mb=w;else{clearTimeout(this.az5);bh.qK(w,this.ae0)}};cv.prototype.lE=function(w){var n=typeof w=="string"?this.ajx:this.eG.indexOf(w.target),W=this.aAd[n],j=W[0],I=bh.bl();
if(I==null)I={};var U=I.acc,M=U.tjoin,m=U.tstart;if(j=="leave"){M.splice(M.indexOf(W[1]),1)}if(j=="add"||j=="remove"||j=="delTeam"||j=="showRename"||j=="rename"){var l=-1,A=0;
for(var L=0;L<m.length;L++){A+=m[L][1].length;if(m[L][2]==W[1])l=L}var g=m[l];if(j=="add"){var k=bh.d$();
if(k&&k[0]==0&&k[1][2]<=A){alert("You can have at most "+k[1][2]+" members in your Premium.");return}g[1].push(W[2])}if(j=="remove")g[1].splice(g[1].indexOf(W[2]),1);
if(j=="delTeam"){if(g[1].length!=0){alert("Remove members first.");return}m.splice(l,1)}if(j=="showRename"){var $=new ed(b.E.L,!0);
$.data={d:b.c.P2,jW:"namewindow",Z1:g[0],FJ:this.lE.bind(this)};this.S($);this.ajx=n;W[0]="rename";return}if(j=="rename")g[0]=w}this.ayO(I)};
cv.prototype.am$=function(w){var n=this.atS==w.target,W=(n?this.ano:this.avR).b().trim();if(W==""){alert("The Team "+(n?"Name":"ID")+" is empty.");
return}if(!n){W=parseInt(W);if(isNaN(W)){alert("The ID must be a number");return}}var D=bh.bl();if(D==null)D={};
var j=D.acc;if(j==null)j=D.acc={};var I=j.tstart,U=j.tjoin;if(n){if(I==null)I=j.tstart=[];if(I.length>5){alert("You can have at most 5 teams");
return}I.push([W,[]])}else{if(I)for(var L=0;L<I.length;L++)if(I[L][2]==W){alert("You are the owner of this team");
return}if(U==null)U=j.tjoin=[];if(U.indexOf(W)!=-1){alert("You already asked to join this team.");return}j.tjoin.push(W)}j.update=!0;
this.ayO(D)};cv.prototype.mQ=function(){this.BJ=!1;var w=bh.rE(),n=w!=null,W=this.sU.parentNode!=null;
if(n!=W){e._g(this.e);if(n)this.e.appendChild(this.sU);else this.e.textContent="Log In to access Team Settings."}if(!n)return;
var D=bh.bl();if(D==null)D={};var j=D.acc;if(j==null)j={};var I=JSON.stringify(j)+"===="+JSON.stringify(w);
if(I!=this.aht){this.aht=I;var U=this.hs,M=this.Vm;e._g(U);e._g(M);var m=this.eG=[],l=this.aAd=[],A=this.lE.bind(this);
function g(x,v){x.addEventListener("click",A);m.push(x);l.push(v)}function k(X,x){var Y=e.t("div"),v="rgba(255,255,255,0.15)";
Y.appendChild(C("ID: "+X[2],54,v));Y.appendChild(C(X[0],160,null,!0));if(x){Y.appendChild(C(X[1].length+" members",80,null,!0))}else{Y.appendChild(C(X[1]==-1?"... not accepted yet":"Accepted",160));
if(Date.now()<X[1]*1e3)Y.appendChild(C("Premium",80,"rgba(0,140,0,1)"))}var N=C("",120);Y.appendChild(N);
N.setAttribute("style","float:right;text-align:right");if(x){var u=new iP("Rename",null,null,!0);g(u,["showRename",X[2]]);
N.appendChild(u.e)}var u=new iP(x?"Delete":"Leave",null,null,!0);g(u,[x?"delTeam":"leave",X[2]]);N.appendChild(u.e);
return Y}function $(x,v,R){var Y=e.t("div");Y.style.paddingLeft="46px";Y.appendChild(C(v?"\u2713":"...",8,v?"#229922":"#aa7700"));
Y.appendChild(C(x[1],200));Y.appendChild(C(x[2],240));var N=C("",120);Y.appendChild(N);N.setAttribute("style","float:right;text-align:right");
var u=new iP(v?"Remove":"Add",null,null,!0);g(u,[v?"remove":"add",R,x[0]]);N.appendChild(u.e);return Y}function C(x,v,N,u){var H=e.t("span");
H.textContent=x;H.setAttribute("style","display:inline-block; padding:0 10px; border-radius:4px; overflow:hidden; width:"+v+"px; "+(N!=null?"background-color:"+N+";":"")+(u?"font-weight:bold;":""));
return H}var f=j.tstart,z=j.tjoin,s=w.wantToJoin,O=w.inTeams;if(f)for(var a=0;a<f.length;a++){var X=f[a],P=s["t"+X[2]];
if(P==null)P=[];var Z={};for(var L=0;L<P.length;L++)Z["u"+P[L][0]]=P[L];var Y=k(X,!0);U.appendChild(Y);
Y.style.marginTop="10px";for(var L=0;L<X[1].length;L++){var K=X[1][L],S=Z["u"+K];if(S==null)S=[K,"========","... user has left your team"];
delete Z["u"+K];var G=$(S,!0,X[2]);U.appendChild(G)}for(var V in Z){var S=Z[V],G=$(S,!1,X[2]);U.appendChild(G)}}if(z){var T={};
for(var L=0;L<O.length;L++)T["t"+O[L][2]]=O[L];for(var a=0;a<z.length;a++){var R=z[a],X=T["t"+R],Y=k(X?X:["==========",-1,R],!1);
M.appendChild(Y)}}this.S(new ed(b.E.A))}if(this.Mb==null){this.e.style.pointerEvents="auto";this.e.style.opacity="1"}this.Mp()};
function hq(){eg.call(this);this.n_=[16,!0,!0];this.e=e.t("span","");this.ZW=[new g_([12,24],0,255),new b7([12,25,1]),new b7([12,25,0])];
for(var L=0;L<3;L++){var w=this.ZW[L];w.parent=this;w.$(this.n_[L]);this.e.appendChild(w.e);w.h(b.E.A,this.WJ,this)}}hq.prototype=new eg;
hq.prototype.WJ=function(){for(var L=0;L<3;L++)this.n_[L]=this.ZW[L].b();this.S(new ed(b.E.A,!1))};hq.prototype.$=function(w){this.n_=w.slice(0);
for(var L=0;L<3;L++)this.ZW[L].$(w[L])};hq.prototype.b=function(){return this.n_.slice(0)};hq.prototype.f=function(){for(var L=0;
L<3;L++)this.ZW[L].f()};function kf(w,n){eg.call(this);if(n==null)n=!1;this.S$=[];this.vF=Math.floor(120*e.V());
this.azE=Math.floor(23*e.V());this.Wo=0;this.b_=[];this.AE=[];for(var W in E.XB.type){if(W=="warpCustom"&&!n)continue;
this.b_.push(W);this.AE.push(E.XB.type[W])}this.e=e.t("span","fitem warpbutton");this.bL=new eg;this.bL.e=e.t("div","floatcont");
if(w){this.MO=w;this.jc=e.t("label","flabel");this.e.appendChild(this.jc)}this.d=e.t("button");this.e.appendChild(this.d);
e.L_(this.d,this.E0.bind(this));this.w9=new dX(!0);this.bL.e.appendChild(this.w9.e);this.w9.h(b.E.A,this.asC,this);
this.bL.e.setAttribute("style","width:"+Math.floor(8+this.vF/e.V())+"px;");this.f()}kf.prototype=new eg;
kf.prototype.wV=function(w){this.jc.textContent=w};kf.prototype.f=function(){if(this.MO)this.jc.innerHTML=fV.get(this.MO)+":";
this.qE()};kf.a9O={};kf.a9z=function(w,n,W){var D=fV.get(E.XB.type[w]),j=D+"-"+w+"-"+n+"-"+W,I=kf.a9O[j];
if(I)return I;var U=kf.VE;if(M==null){var M=e.t("canvas");U=kf.VE=M.getContext("2d")}var M=U.canvas;
if(M.width!=n||M.height!=W){M.width=n;M.height=W}U.font=Math.floor(13*e.V())+"px sans-serif";U.lineWidth=1;
U.strokeStyle="#000000";var m=Math.floor(16*e.V()),l=new iB(0,0,m,m);U.clearRect(0,0,M.width,M.height);
var A=E.XB.XB(l,w,!0,.3,0,0),g=E.p.Wx(l);g.F.push("M","L","M","L");g.w.push(0,m/2,m,m/2);g.w.push(m/2,0,m/2,m);
g=E.p.jp(g);g=E.p.Av(g,m/5);E.xv.D(A,g.w,l);E.p.D(g.w,new eh(1,0,0,1,Math.floor(8*e.V())+.5,Math.floor(3*e.V())+.5),g.w);
U.beginPath();Typr.U.pathToContext({cmds:g.F,crds:g.w},U);U.stroke();U.fillText(D,Math.floor(40*e.V()),Math.floor(16*e.V()));
I=kf.a9O[j]=M.toDataURL();return I};kf.prototype.E0=function(w){if(e.LY(this.bL.e))return;w.stopPropagation();
var n=this.vF,W=this.azE;for(var L=0;L<this.b_.length;L++)this.S$[L]=kf.a9z(this.b_[L],n,W);this.w9.jJ(this.S$,null,n,W);
var D=this.d.getBoundingClientRect(),j=new ed(b.E.L,!0);j.data={d:b.c.Uq,BT:this.bL,x:D.left,y:D.top+D.height+4};
this.S(j)};kf.prototype.asC=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.Eb,BT:this.bL};this.S(n);
this.Wo=w.target.b()[0];this.qE();this.S(new ed(b.E.A))};kf.prototype.qE=function(){var w=this.vF,n=this.azE;
this.w9.$([this.Wo]);this.d.innerHTML="<img src=\""+kf.a9z(this.b_[this.Wo],w,n)+"\" class=\"gsicon\" />";
e.UE(this.d.firstChild,w,n)};kf.prototype.b=function(){return this.b_[this.Wo]};kf.prototype.$=function(w){this.Wo=this.b_.indexOf(w);
this.qE()};function hJ(w,n,W){eg.call(this);if(w==null)w=!1;if(n==null)n=!1;if(W==null)W=!1;this.axA=n;
this.XB=null;this.pf=new kf([12,22],W);this.pf.parent=this;this.pf.h(b.E.A,this.FI,this);this.Xx=new i0([22,0],[[22,4,0],[22,4,1]]);
this.Xx.h(b.E.A,this.FI,this);var D=w?g_:eu;this.UZ=new D([22,1],-100,100,"%");this.K0=new D("Horizontal Distortion:",-100,100,"%");
this.Dy=new D("Vertical Distortion:",-100,100,"%");this.UZ.parent=this.K0.parent=this.Dy.parent=this;
this.UZ.h(b.E.A,this.FI,this);this.K0.h(b.E.A,this.FI,this);this.Dy.h(b.E.A,this.FI,this)}hJ.prototype=new eg;
hJ.prototype.f=function(){this.pf.f();this.Xx.f();this.UZ.f();var w=this.axA?1:100;this.K0.wV(fV.get([22,2]).substring(0,w)+":");
this.Dy.wV(fV.get([22,3]).substring(0,w)+":")};hJ.prototype.FI=function(){var w=this.XB,n=this.pf.b(),W=w.warpStyle.v.warpStyle;
if(n=="warpCustom")E.XB.NF(E.XB.BI(w),w);else delete w.customEnvelopeWarp;w.warpStyle.v.warpStyle=this.pf.b();
w.warpRotate.v.Ornt=["Hrzn","Vrtc"][this.Xx.b()];w.warpValue.v=this.UZ.b();w.warpPerspective.v=this.K0.b();
w.warpPerspectiveOther.v=this.Dy.b();if(n=="warpNone"||n=="warpCustom"){w.warpValue.v=0;w.warpPerspective.v=0;
w.warpPerspectiveOther.v=0}else if(W=="warpNone"||W=="warpCustom")w.warpValue.v=50;this.S(new ed(b.E.A,!1));
this.$(w)};hJ.prototype.b=function(w){return JSON.parse(JSON.stringify(this.XB))};hJ.prototype.$=function(w){this.XB=JSON.parse(JSON.stringify(w));
this.pf.$(w.warpStyle.v.warpStyle);this.Xx.$(w.warpRotate.v.Ornt=="Hrzn"?0:1);this.UZ.$(w.warpValue.v);
this.K0.$(w.warpPerspective.v);this.Dy.$(w.warpPerspectiveOther.v);var n=w.warpStyle.v.warpStyle,W=n=="warpNone"||n=="warpCustom",D=[this.Xx,this.UZ,this.K0,this.Dy];
for(var L=0;L<D.length;L++)if(W)D[L].rx();else D[L].Te()};function hL(w){eg.call(this);this.a9I={};this.e=e.t("div");
this.aU=w;this.tg=null;this.Ol=new ec(0,0);this.V2="position:relative;overflow:hidden;background-color:var(--bg-canvas);";
this.FY=null;this.N3=new e.BC(this.e);this.$J("grab");this.T=e.t("canvas","canv");this.e.appendChild(this.T);
this.VE=this.T.getContext("2d");this.awT=null;this.aD=null;this.BP=null;this.pR=0;this.Gn=0;this.fZ=0;
this.ajp=this.a2Q.bind(this);this.ab7=null;this.u=new hs({m:1,n:1});this.$s=null;this.br=null;this.Pw=[];
this.agx=0;this.hf=0;this.a5E=this.jx.bind(this);this.apb=this.Gi.bind(this);this.auD=this.WB.bind(this);
this.agA=this.JR.bind(this);this.aqG=0;this.gw=null;this.ayJ(this.T);this.ui(this)}hL.prototype=new eg;
hL.prototype.azr=function(w){this.a9I=w;this.T5()};hL.acD=function(w){var n=new aK(!0);if(w>=0)n.xa("Space");
if(w>=1){n.xa("ControlLeft");if(w==2)n.xa("AltLeft")}return n};hL.prototype.oe=function(w){var n=this.FY,W=null;
if(w.U(aK.Xu)){W="grab";if(w.U(aK.CQ)){W="zoom-in";if(w.U(aK.PJ))W="zoom-out"}}this.tg=W;if(W)n=W;this.N3.mQ(n,this.V2);
if(w.U(aK.CQ)){var D=0;if(w.U(aK.fQ))D=1;if(w.U(aK.Ne))D=-1;if(D!=0){this.U1(new ec(this.T.width/2,this.T.height/2),D==1)}}};
hL.prototype.$J=function(w){this.FY=w;if(this.tg)return;this.N3.mQ(w,this.V2)};hL.prototype.ayJ=function(w){e.L_(w,this.a5E);
e.ZS(w);w.addEventListener("wheel",this.agA,!1)};hL.prototype.ui=function(w){w.h("viewchange",this.acV,this)};
hL.prototype.acV=function(w){var n=this.u.N,W=w.currentTarget.T3();this.u.N=W.N;this.u.R=W.R.clone();
if(n!=W.N)this.ho();this.T5()};hL.prototype.T3=function(){return{N:this.u.N,R:this.u.R}};hL.prototype.$=function(w,n){var W=w[0].XL;
if(this.aD!=null&&this.aD[0].XL.s9(W)){}else{this.u.On={m:W.m,n:W.n};this.u.R=new ec(0,0);this.u.N=1}this.aD=w;
this.ho();this.BS();this.pR=0;this.Gn=0;this.fZ=n==null?0:n;this.a2Q()};hL.prototype.JR=function(w){w.preventDefault();
if(w.deltaY==0||Date.now()-this.aqG<100)return;var n=e.rv(w);n.x=e.V()*n.x;n.y=e.V()*n.y;this.aqG=Date.now();
this.U1(n,w.deltaY<0)};hL.prototype.U1=function(w,n){y.Jd.Oh(this.u,w,n);this.ato()};hL.prototype.bP=function(){var w=this.u,n=w.On;
this.u.N=y.Jd.ajJ(n.m,n.n,w.xq.m,w.xq.n);this.ato()};hL.prototype.ato=function(){this.ho();this.S(new ed("viewchange"));
this.S(new ed("zoom"))};hL.prototype.ho=function(){this.BP=[];var w=this.u.N;if(this.aD==null)return;
for(var L=0;L<this.aD.length;L++){var n=this.aD[L],W=new Uint8Array(n.data),D;if(w>=1)D={Q0:W,rect:n.XL};
else D=E.a3_(W,n.XL,w);this.BP.push(D)}};hL.prototype.BS=function(){clearTimeout(this.ab7)};hL.prototype.T5=function(){if(this.aD==null||!e.LY(this.T))return;
var w=this.awT,n=this.T.width,W=this.T.height,C,f;if(w==null||w.width!=n||w.height!=W){w=this.awT=this.VE.createImageData(n,W);
console.log("creating image data")}var D=this.aD[this.pR],j=this.BP[this.pR],I=this.u,U=I.On,M=I.xq,m=M.m,l=M.n,A=U.m*I.N,g=U.n*I.N,k=Math.round((m-A)/2+I.R.x),$=Math.round((l-g)/2+I.R.y);
if(I.N<=1){f=j.rect.clone();f.x=k;f.y=$;A=f.m;g=f.n;C=j.Q0}else{var z=1/I.N,s=new iB(Math.floor((M.x-k)*z),Math.floor((M.y-$)*z),Math.ceil(M.m*z)+1,Math.ceil(M.n*z)+1),O=new iB(0,0,s.m*I.N,s.n*I.N);
O.x=s.x*I.N+k;O.y=s.y*I.N+$;if(I.YM==null||I.YM.length!=s.O()*4){I.YM=E.Q(s.O()*4)}if(I.PS==null||I.PS.length!=O.O()*4){I.PS=E.Q(O.O()*4)}E.cJ(I.YM,0);
E.Cb(j.Q0,j.rect,I.YM,s);E.scale.cg(I.YM,s.m,s.n,I.PS,O.m,O.n,I.N);C=I.PS;f=O}var a=new Uint8Array(w.data.buffer);
E.b6(a,m,l,8,-k,-$);E.s._U("norm",C,f,a,M,M,1);var X=this.VE;X.setTransform(1,0,0,1,0,0);X.putImageData(w,0,0);
X.clearRect(k-1e3,$,1e3,g);X.clearRect(k+A,$,1e3,g);X.clearRect(k-1e3,$-1e3,A+2e3,1e3);X.clearRect(k-1e3,$+g,A+2e3,1e3);
var P=hL.akA(I.N,"#ffffff");X.putImageData(P,0,I.xq.n-P.height);var Z=this.a9I,I=this.u;if(Z){var Y=cP.vJ([.1,.5,1,1]),K=cP.vJ([1,0,0,1]),S=I.Pv(!1);
S.Ba();X.save();X.setTransform(S.dl,S.k,S.Cj,S.j7,S.z2,S.EU);X.strokeStyle=K;if(Z.aqa){cP.ru(Z.aqa,null,X);
X.lineWidth=1/I.N;X.stroke()}X.strokeStyle=Y;X.fillStyle=cP.vJ([1,1,1,1]);if(Z.VZ){cP.ru(Z.VZ,null,X);
X.lineWidth=1/I.N;X.stroke()}if(Z.cc){cP.a5B(Z.cc,X,I,.5);X.lineWidth=2/I.N;X.stroke();X.fill()}if(Z.RB){X.font=16/I.N+"px sans-serif";
var G=1/I.N;for(var L=0;L<Z.RB.length;L++){var V=Z.RB[L],T=V[0],R=V[1]+6/I.N,x=V[2];X.fillStyle="black";
X.fillText(x,T-G,R);X.fillText(x,T+G,R);X.fillStyle="white";X.fillText(x,T,R)}}X.restore()}X.getImageData(0,0,1,1)};
hL.asL="";hL.aqb=null;hL.akA=function(w,n,W,D){if(W==null){W=0;D=0}var j=W+" \xD7 "+D,I="z"+w+","+n+","+W+","+D;
if(I==hL.asL)return hL.aqb;var U=Math.round(50*e.V()),M=Math.round(18*e.V()),m=W==0?0:Math.round((j.length+2)*M*.35),l=e.t("canvas"),A=l.getContext("2d");
l.width=U+m;l.height=M;A.fillStyle="rgba(1,1,1,1)";A.fillRect(0,0,U,M);if(W!=0)A.fillRect(U+2,0,m,M);
A.font=Math.round(11*e.V())+"px monospace";A.fillStyle=n;var g=w*100;if(g<100)g=g.toFixed(2);else g=Math.round(g);
g=g+"%";var k=A.measureText(g).width;A.fillText(g,(U-k)/2,Math.round(M*.7));if(W!=0){var $=A.measureText(j).width;
A.fillText(j,U+(m-$)/2+1,Math.round(M*.7))}var C=A.getImageData(0,0,U+m,M);hL.asL=I;hL.aqb=C;return C};
hL.prototype.a2Q=function(){var w=this.aD,n=w.length,W=this.pR,D=this.aD[W],j=(W+1)%n;this.T5();if(n!=1&&w[j].XL.s9(D.XL)){var I=D.$U?parseInt(D.$U.split(",").pop()):30;
if(I==0)I=16;if(j==0)this.Gn++;if(this.fZ==0||this.Gn<this.fZ)this.ab7=setTimeout(this.ajp,I)}this.pR=j};
hL.prototype.zl=function(w,n){if(w<=0||n<=0)return;var W=Math.floor(w*e.V()),D=Math.floor(n*e.V());this.u.xq=new iB(0,0,W,D);
this.T.width=W;this.T.height=D;this.T.setAttribute("style","width:"+W/e.V()+"px; height:"+D/e.V()+"px; display:block;");
this.T5()};hL.prototype.cy=function(w){var n=-1,W=this.Pw;for(var L=0;L<W.length;L++)if(W[L].pointerId==w.pointerId)n=L;
return n};hL.prototype.jx=function(w){var n=this.cy(w),W=this.Pw;if(n!=-1)W[n]=w;else W.push(w);if(W.length==1){this.gw=w.target;
e.Ko(window,this.apb);e.d6(window,this.auD);this.$s=e.rv(w,this.T);this.$s.x*=e.V();this.$s.y*=e.V();
this.Ol=this.$s;this.br=this.u.R.clone();if(this.aU&&this.gw==this.T&&!this.tg)this.S(new ed("mousedown"))}else this.agx=this.hf=ec.cS(e.rv(W[0],this.T),e.rv(W[1],this.T))};
hL.prototype.Gi=function(w){var n=this.cy(w),W=this.Pw;if(n!=-1)W[n]=w;var j=this.u,I=this.tg,U=this.aD[this.pR].XL.clone();
U.m*=j.N;U.n*=j.N;var M=e.rv(w,this.T);M.x*=e.V();M.y*=e.V();this.Ol=M;if(this.aU&&this.gw==this.T&&!I)this.S(new ed("mousemove"));
else if(I=="grab"||I==null){if(W.length>1){var m=e.rv(W[0],this.T),l=e.rv(W[1],this.T),A=new ec(e.V()*(m.x+l.x)/2,e.V()*(m.y+l.y)/2),g=ec.cS(m,l),k=null;
if(g>this.hf+50){this.hf+=50;k=!0}if(g<this.hf-50){this.hf-=50;k=!1}if(k!=null)this.U1(A,k);return}else{var $=M.x-this.$s.x,C=M.y-this.$s.y;
j.R.x=this.br.x+Math.round($);j.R.y=this.br.y+Math.round(C)}this.S(new ed("viewchange"))}};hL.prototype.WB=function(w){var n=this.cy(w),W=this.Pw;
W.splice(n,1);if(W.length==0){e.MC(window,this.apb);e.i_(window,this.auD);var j=this.tg;if(w.detail>1){this.u.N=1;
this.u.R.y1(0,0);this.T5()}if(this.aU&&this.gw==this.T&&!this.tg)this.S(new ed("mouseup"));else{if(j=="zoom-in"||j=="zoom-out")this.U1(this.Ol,j=="zoom-in")}}else{var I=this.$s=e.rv(W[0],this.T);
I.x*=e.V();I.y*=e.V()}};hL.prototype.PD=function(w){var n=this.Ol;if(w){n=e.rv(w,this.T);n.x*=e.V();
n.y*=e.V()}return this.u.Cg(n.x,n.y)};function a6(){eg.call(this);this.ns=null;this.As=null;this.iw=null;
this.uN=null;this.awP="";this.xu=[];this.v5=0;this.FD=[];this.Ps=0;this.ww=null;var w=this.e=e.t("div",""),n=this.ai3=e.t("div","form");
n.setAttribute("style","line-height:0; margin-bottom:0.5em;");w.appendChild(n);var W=this.MO=e.t("span");
n.appendChild(W);W.setAttribute("style","font-size:1.2em; font-weight:bold; margin-right:3em;");var D=this.a5g=new b7([25,2,0]);
D.$(!0);n.appendChild(D.e);D.h(b.E.A,this.w$,this);var j=this.c6=new b7([25,2,1]);j.$(!0);n.appendChild(j.e);
j.h(b.E.A,this.w$,this);var I=new ga(" ");n.appendChild(I.e);var U=this.Wd=new e7([25,1,1]);n.appendChild(U.e);
U.h(b.E.A,this.w$,this);this.Lz=new j6(14);this.Lz.a8U(3);n.appendChild(this.Lz.e);this.Lz.parent=this;
this.Lz.h(b.E.A,this.a5F,this);var M=this.ay6=new iP([25,1,2],null,null,!0);n.appendChild(M.e);M.h("click",this.b0,this);
var m=new iP("?",null,null,!0);n.appendChild(m.e);m.addEventListener("click",function(){alert("All our images come from Pixabay.com and are free to use for commercial purposes.")});
this.a5w=this.al9.bind(this);this.x_=e.t("div","svggallery scrollable");w.appendChild(this.x_);this.x_.addEventListener("scroll",this.axd.bind(this))}a6.prototype=new eg;
a6.prototype.GZ=function(w){this.a2n=w};a6.prototype.f=function(){this.MO.textContent=fV.get([25,0]);
this.Lz.f();this.a5g.f();this.c6.f();this.Wd.f();this.ay6.f()};a6.prototype.zl=function(w,n){this.ns=new ec(w,n);
this.ai3.setAttribute("style","width:"+w+"px");var W=this.ai3.getBoundingClientRect();n-=W.height;this.x_.setAttribute("style","width:"+w+"px; height:"+n+"px");
if(e.LY(this.e))this.w$()};a6.prototype.$=function(w){this.As=w;this.w$()};a6.prototype.axd=function(w){var n=this.x_;
if(n.scrollTop+n.clientHeight+10>=n.scrollHeight){this.w$(!0)}};a6.prototype.a5F=function(w){this.iw=null;
this.w$()};a6.prototype.al9=function(w){if(Date.now()-this.Ps<2e3)return;this.Ps=Date.now();this.v5=this.FD.indexOf(w.currentTarget);
var n=this.nu(this.As.x,this.As.y);if(n[1]){var W=n[1].largeImageURL,D=new XMLHttpRequest;D.responseType="arraybuffer";
D.open("GET",W,!0);D.onload=this.avk.bind(this);D.send();return}this.awl(n)};a6.prototype.avk=function(w){var n=w.target.response,W=jj.zJ(n),D=jj.ZO(W),j=D.Vu(n),I=this.nu(this.As.x,this.As.y,[n,j[0].XL.m,j[0].XL.n]);
this.awl(I)};a6.prototype.awl=function(w){var n=w[0],W=jj.zJ(n),D=jj.ZO(W),j=new kc("template.psd");
D.Vu(n,j);var I=new ed("tempready",!0);I.data={On:j};this.S(I)};a6.prototype.b0=function(w){var n=w.target;
this.xu=[];this.iw=null;this.w$()};a6.prototype.atc=function(w){var n=JSON.parse(w.target.response),W=this.uN=n.hits;
for(var L=0;L<W.length;L++)if(W[L].user_id==6314823)W.splice(L,1);this.w$()};a6.prototype.w$=function(w){if(this.As==null||this.ns==null||this.a2n==null)return;
if(this.ns.x<=0)return;var n=this.As.x,W=this.As.y;if(Math.min(n,W)<50)return;if(w!=!0){this.FD=[];e._g(this.x_);
this.x_.scrollTop=0}if(this.FD.length>300)return;var D=Math.min(1,300/Math.max(n,W)),j=this.ns.clone();
j.x-=20;var I=Math.max(1,Math.floor(j.x/(n*D))),U=Math.max(1,Math.ceil(j.y/(W*D)));D=j.x/I/n;var M=I*U;
if(this.iw==null){var m=this.a2n.hY.hz(),l=[];for(var A in m){var g=m[A],k=g[3];if(!this.Lz.Mw(g))continue;
if(g[5]==null||g[5].slice(0,2)=="gf")continue;l.push(g)}if(l.length==0)l.push(m.DejaVuSans);var $=l.length;
for(var L=0;L<$*10;L++){var C=Math.floor(Math.random()*$),f=Math.floor(Math.random()*$),z=l[C];l[C]=l[f];
l[f]=z}l=l.slice(0,10);this.iw=l}var s=this.c6.b(),O=this.Wd.b().trim();this.Wd.G3(s);if(s&&(this.uN==null||O!=this.awP)){var a=new XMLHttpRequest,X="https://pixabay.com/api/?image_type=photo"+(O==""?"":"&q="+encodeURIComponent(O))+"&per_page=200&page=1&key=10554583-a5eacb61c2e61105fdfb6eb88&safesearch=true";
if(O=="")X="plugins/gallery.json";a.open("GET",X,!0);a.onload=this.atc.bind(this);a.onerror=function(G){console.log(G.target.response)};
a.send();this.awP=O;return}D*=(n*D-5)/(n*D);var P=this.FD.length;for(var L=0;L<M;L++){var Z=this.v5=P+L;
if(this.xu[Z]==null)this.xu[Z]=Math.floor(Math.random()*4294967295);var Y=this.nu(Math.round(n*D),Math.round(W*D)),K=Y[0];
K=J.KY(new Uint8Array(K));var S=e.t("span");S.innerHTML=K;this.FD.push(S);this.x_.appendChild(S);S.addEventListener("click",this.a5w,!1)}};
a6.prototype.nu=function(w,n,W){var D=this.c6.b(),j=this.a5g.b(),I=D&&this.uN.length!=0?this.uN:null;
if(j&&!D)I=null;if(j&&D&&(this.v5&1)==0)I=null;return eB.AB(w,n,this.xu[this.v5],this.iw,W?W:I)};function kv(){eg.call(this);
this.e=e.t("div");this.sU=null;this.aeX=null;this.DY=-1;this.Za={JPG:[{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:70},{bm:new b7("attach metadata"),hx:!1}],TIFF:[{bm:new b7("attach metadata"),hx:!1}],WEBP:[{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:70}],GIF:[{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:100},{bm:new b7([12,23,3]),hx:!1}],PNG:[{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:100},{bm:new b7("don't use palettes"),hx:!1}],PDF:[{bm:new e7([12,52,1]),hx:""},{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:100},{bm:new b7("reverse pages"),hx:!1},{bm:new b7("rasterize all"),hx:!1},{bm:new b7("vectorize text"),hx:!1},{bm:new eu("Add Margin",0,5,"in",2),hx:0},{bm:new b7("add crop marks"),hx:!1}],EMF:[{bm:new e7([12,52,1]),hx:""},{bm:new eu([12,52,0],0,100,"%",null,null,!0),hx:100},{bm:new b7("reverse pages"),hx:!1},{bm:new b7("rasterize all"),hx:!1},{bm:new b7("vectorize text"),hx:!1},{bm:new eu("Add Margin",0,5,"in",2),hx:0}],SVG:[{bm:new b7("add raster graphics"),hx:!0},{bm:new b7("add hidden layers"),hx:!1},{bm:new b7("vectorize text"),hx:!1},{bm:new b7("rasterize text"),hx:!1},{bm:new b7("minify"),hx:!1}],RAW:[{bm:new j$([12,72],["1","3","4"]),hx:2},{bm:new j$([12,34],["8 Bits","16 Bits"]),hx:0},{bm:new j$("Byte Order",["12-34","34-12"]),hx:0}],DDS:[{bm:new i0("Compression",["8x | BC1","4x | BC3","4x | BC7","None"]),hx:0},{bm:new b7("Add Mipmaps"),hx:!0}],anim:[{bm:new eu("Speed",10,800,"%",null,!0,!0),hx:100},{bm:new g_("Repeat (0 = Forever)",0,10," \xD7",0,!1,!0),hx:0},{bm:new b7("reverse frames"),hx:!1},{bm:new b7("boomerang"),hx:!1},{bm:new eu("Reduce Frames",0,100,"%",null,null,!0),hx:100}],slcs:[{bm:new b7([8,11,0]),hx:!0}],artb:[{bm:new b7([1,16,1]),hx:!0}],hicc:[{bm:new b7("convert to sRGB"),hx:!0}]};
for(var w in this.Za){var n=this.Za[w];for(var L=0;L<n.length;L++){n[L].bm.$(n[L].hx);n[L].bm.h(b.E.A,this.Ch,this)}}}kv.prototype=new eg;
kv.prototype.ak6=function(){this.DY=-1};kv.prototype.f=function(){for(var w in this.Za)for(var L=0;L<this.Za[w].length;
L++)this.Za[w][L].bm.f()};kv.prototype.Ch=function(){this.w$();this.S(new ed(b.E.A,!1))};kv.prototype.w$=function(){var w=this.sU,n=w[0],W=w[1],D=w[2],j=w[3],I=w[4],U=this.Za[n];
if(U==null)U=[];else U=U.slice(0);if(W)U=U.concat(this.Za.anim);if(["GIF","PNG","JPG"].indexOf(n)!=-1&&D)U=U.concat(this.Za.slcs);
else if(["GIF","PNG","JPG"].indexOf(n)!=-1&&j)U=U.concat(this.Za.artb);if(I)U=U.concat(this.Za.hicc);
var M=w.join(",");if(M!=this.DY){this.DY=M;e._g(this.e);for(var L=0;L<U.length;L++){if(n=="PDF"&&!j&&(L==0||L==2))continue;
this.e.appendChild(U[L].bm.e);e.x$(this.e)}}var m=this.aeX=[];for(var L=0;L<U.length;L++)m.push(U[L].bm.b())};
kv.prototype.Pe=function(w,n,W,D,j){this.sU=[w,n,W,D,j];this.w$()};kv.prototype.b=function(){return this.aeX.slice(0)};
kv.prototype.$=function(w,n){var W=this.sU,D=W[0],j=this.Za[D],I=Math.min(j.length,w.length);for(var L=0;
L<I;L++)j[L].bm.$(w[L]);this.w$();if(n!=!0)this.Ch()};function c1(){eg.call(this);this.e=e.t("span","fitem");
this.b4=!1;this.cC=new iP("No",!1,"Cancel");this.QK=new iP("Yes",!1,"Confirm");this.e.appendChild(this.cC.e);
this.e.appendChild(this.QK.e);this.cC.h("click",this.qO,this);this.QK.h("click",this.qO,this);this.f()}c1.prototype=new eg;
c1.prototype.f=function(){this.cC.wV(e.DZ("cross",null,"autoscale"));this.QK.wV(e.DZ("checkmark",null,"autoscale"))};
c1.prototype.qO=function(w){this.b4=w.target==this.QK;this.S(new UIEvent("click"))};c1.prototype.b=function(){return this.b4};
function kq(w){eg.call(this);this.e=e.t("span","fitem");this.Qx=new iP("\u25BC",null,"Auto Options",!0);
e.L_(this.Qx.e,this.ajZ.bind(this));this.e.appendChild(this.Qx.e);this.bc=new iP("Auto",null,null,!0);
this.bc.h("click",this.bX,this);this.e.appendChild(this.bc.e);this.l1=new jw("Algorithms",["Enhance Monochromatic Contrast","Enhance Per Channel Contrast","Find Dark & Light Colors","Enhance Brightness And Contrast"],null,null,!0);
this.l1.h(b.E.A,this.bX,this);this.l1.$([!1,!1,!1,!0]);this.bL=new eg;var n=this.bL.e=e.t("div","floatcont form");
n.setAttribute("style","width: 250px;");this.bL.parent=this;n.appendChild(this.l1.e);this.u1=[];for(var L=0;
L<2;L++){var W=new g_((L==0?"Shadows":"Highlights")+" Clip",0,9.99,"%",2,!1,!0);W.$(.1);W.h(b.E.A,this.bX,this);
this.u1.push(W);n.appendChild(W.e)}}kq.prototype=new eg;kq.prototype.bX=function(w){this.S(new ed(b.E.A,!1))};
kq.prototype.f=function(){};kq.prototype.b=function(){return[this.l1.b().indexOf(!0),this.u1[0].b(),this.u1[1].b()]};
kq.prototype.ajZ=function(w){if(e.LY(this.bL.e))return;w.stopPropagation();var n=this.Qx.e.getBoundingClientRect(),W=new ed(b.E.L,!0);
W.data={d:b.c.Uq,BT:this.bL,x:n.left,y:n.top+n.height+4};this.S(W)};function b1(){eg.call(this);var w=this.e=e.t("div","fitem");
this.p7=new i0([12,46],[[13,1,8],[13,1,10],[13,1,9],[12,47]]);this.p7.h(b.E.A,this.WJ,this);w.appendChild(this.p7.e);
this.Dt=new gM(!1);this.Dt.parent=this;this.Dt.hR(16777215);this.Dt.h(b.E.A,this.WJ,this);w.appendChild(this.Dt.e)}b1.prototype=new eg;
b1.prototype.f=function(){this.p7.f();this.Dt.f()};b1.prototype.a8H=function(w){var n=[w.artboardBackgroundType.v-1];
if(w.Clr)n.push(w.Clr.v);this.$(n)};b1.prototype.am5=function(){var w=this.b();return{classID:"artboard",Clr:{t:"Objc",v:w[1]},artboardBackgroundType:{t:"long",v:w[0]+1}}};
b1.prototype.$=function(w){this.p7.$(w[0]);if(w[1])this.Dt.$(w[1])};b1.prototype.b=function(){return[this.p7.b(),this.Dt.b()]};
b1.prototype.WJ=function(w){if(w.target==this.Dt)this.p7.$(3);this.S(new ed(b.E.A,!1))};function hf(w){eg.call(this);
this.UD=w;this.TG=0;this.a3g=!1;this.yc=w?new hf.LT:null;this.e=e.t("div","flexrow storageset");this.e.style.background="var(--bg-panel)";
this.M2=e.t("div");this.e.appendChild(this.M2);this.dB=e.t("div");this.e.appendChild(this.dB);this.uH=[];
var n=Storage.list.length;if(w)n++;var W=this.Zr.bind(this);for(var L=0;L<n;L++){var D=e.t("div");this.uH.push(D);
this.M2.appendChild(D);D.addEventListener("click",W,!1)}this.Zr(null,0)}hf.prototype=new eg;hf.j$=[];
hf.GV=function(w){hf.j$.push(w);w.Uc()};hf.FZ=function(){var w=hf.j$;w.pop();w[w.length-1].Uc()};hf.prototype.Uc=function(){console.log(this.TG);
this.Zr(null,this.TG)};hf.prototype.GZ=function(w,n){if(!w.aE&&!this.a3g){var W=this.UD?2:1;for(var L=W;
L<this.uH.length;L++)this.M2.removeChild(this.uH[L]);this.a3g=!0;if(this.UD)this.yc.GZ(w,n)}if(this.V4)this.V4.GZ(w,n)};
hf.prototype.f=function(){if(this.UD)this.yc.f();if(this.V4)this.V4.f()};hf.prototype.Zr=function(w,n){var W=this.uH,D;
if(n==null)n=W.indexOf(w.currentTarget);this.TG=n;for(var L=0;L<W.length;L++)e.IX(W[L],"active");e.W0(W[n],"active");
if(this.UD)n--;e._g(this.dB);if(n==-1)D=this.yc;else D=Storage.ED(n);this.V4=D;D.parent=this;this.dB.appendChild(D.e);
this.zl(this.gA,this.ag);this.f()};hf.prototype.zl=function(w,n){this.gA=w;this.ag=n;var W=w<850,D=W?50:200,j=Storage.list;
if(this.UD)j=[["Home",null,"strg/home"]].concat(j);for(var L=0;L<j.length;L++){var I=this.uH[L],U="padding: 8px "+(W?13:36)+"px; cursor:pointer;";
I.setAttribute("style",U);I.innerHTML="<img style=\"margin:0 10px -6px 0; width:22px;\" class=\"gsicon\" src=\""+PIMG[j[L][2]]+"\" /> "+(W?"":j[L][0])}this.e.style.width=w+"px";
this.e.style.height=n+"px";this.M2.style.width=D+"px";this.M2.style.paddingTop="32px";if(this.V4)this.V4.zl(w-D,n)};
hf.LT=function(){var w=this.e=e.t("div");w.style.background="var(--bg-canvas)";var n=this.Bz=e.t("div");
w.appendChild(n);var W=e.t("style");w.appendChild(W);W.textContent=" .bhover { transition: background 0.2s ease-in-out; background:rgba(255,255,255,0 );} "+" .bhover:hover { transition: background 0.2s ease-in-out; background:rgba(255,255,255,0.05);}";
for(var L=0;L<2;L++){var D=e.t("div"),W="filter: drop-shadow(4px 6px 4px rgba(0,0,0,0.25)); ";n.appendChild(D);
if(L==0)W+="padding: 12px 0px";if(L==1)W+="position:absolute; bottom:0;";D.setAttribute("style",W);
var j=e.t("img");D.appendChild(j);j.setAttribute("src",PIMG[L==0?"l"+"o"+"g"+"o":"b"+"o"+"t"+"t"+"o"+"m"]);
if(L==0)this.YH=j;else this.aun=j;if(L==0)this.a2_=D;else this.aqw=D}this.uH=[];W="display:inline-block; font-size:1.25em; border:1px solid #aaa; border-radius:6px; margin:20px 0 0 20px;";
var I=this.fV.bind(this);for(var L=0;L<3;L++){var U=e.t("span","bhover");this.uH.push(U);U.setAttribute("style",W+"cursor:pointer; padding:12px;");
U.addEventListener("click",I,!1);n.appendChild(U)}e.x$(n);e.x$(n);var U=e.t("div");U.setAttribute("style",W+"width:min(80%,556px); padding:60px 0; text-align:center; opacity:0.3;");
U.textContent="Drop any files here";n.appendChild(U);this.T=e.t("canvas");this.T.setAttribute("style","position:absolute;top:0;pointer-events:none; mix-blend-mode: screen;");
this.VE=this.T.getContext("2d");this.a2d=E.Q(4);w.appendChild(this.T);var M=new Date().getDate(),m=new Date().getMonth();
if(m==11&&M>20||m==0&&M<10){var l=Math.random()<.5,A={o:255,B:255,k:255};if(!l){A=E.li(Math.random(),Math.random()*.7,1);
A.o*=255;A.B*=255;A.k*=255}this.Ah=[Math.round(1048575*Math.random()),l?.05:.02,Math.round(4+Math.random()*8),1,l?3:15,A,0,!0,l,l?1:.2,3];
this.avW=l?.1:.2;this.io=this.Lm.bind(this);window.requestAnimationFrame(this.io)}};hf.LT.prototype=new eg;
hf.LT.prototype.Lm=function(){window.requestAnimationFrame(this.io);if(!e.LY(this.e))return;var w=this.a2d,n=this.T,W=this.VE,D=n.width,j=n.height;
this.Ah[6]=Date.now()*.001*this.avW;E.gX.ee(w,D,j,this.Ah,!0);W.putImageData(new ImageData(new Uint8ClampedArray(w.buffer),D,j),0,0)};
hf.LT.prototype.fV=function(w){var L=this.uH.indexOf(w.currentTarget),n=new ed(b.E.L,!0);if(L==0)n.data={d:b.c.P2,jW:"newproject"};
if(L==1)n.data={d:b.c.J0};if(L==2)n.data={d:b.c.P2,jW:"res0"};this.S(n)};hf.LT.prototype.f=function(){var w=this.uH,n=[[11,7],[1,6],["PSD VAR0",[25,0]]],W=["\u2605","\uD83E\uDC7F","\u25A3"];
for(var L=0;L<w.length;L++)w[L].textContent=W[L]+"\u2000"+fV.get(n[L]);var D="l"+"o"+"g"+"o",j=new Date;
if(j.getMonth()==3&&j.getDate()==1)D="lo"+"go_cuc"+"umber";this.YH.setAttribute("src",PIMG[D]);this.aun.setAttribute("src",PIMG["b"+"o"+"t"+"t"+"o"+"m"])};
hf.LT.prototype.zl=function(w,n){var W=Math.min(n*1.5,Math.min(w,600));e.dz(this.T,w,W*.26);var D=this.T.width,j=this.T.height;
this.a2d=E.Q(D*j*4);this.e.style.width=w+"px";this.e.style.height=n+"px";this.aqw.style.width=w+"px";
this.Bz.style.marginLeft=Math.max(0,Math.round((w+200-600)/2)-200)+"px";this.YH.style.width=W+"px";this.aun.style.width=W+"px"};
hf.LT.prototype.GZ=function(w,n){if(!w.aE&&this.uH[2].parent)this.Bz.removeChild(this.uH[2])};function Storage(w){eg.call(this);
var n=this.e=e.t("div","storage");e.xr(n);n.addEventListener("drop",this.au8.bind(this),!1);var W=this.awx=e.t("style");
n.appendChild(W);n.setAttribute("tabindex","0");n.style.outline="none";n.addEventListener("keydown",this.af2.bind(this),!1);
this.YR=this.acv.bind(this);this.Jy=0;var D=e.t("div");n.appendChild(D);var j=this.aod.bind(this);this.mj=e.t("div","bar");
D.appendChild(this.mj);this.y7=e.t("div","fls scrollable");D.appendChild(this.y7);this.Bt=e.t("div");
D.appendChild(this.Bt);this.Bt.setAttribute("style","position:absolute; bottom:0; background-color:white; padding: 2px 8px 0px 8px;");
this._2=e.t("div","bar");this._2.textContent="Name: ";var I=this.Dw=e.t("input");I.setAttribute("type","text");
this._2.appendChild(I);var U=this.Id=e.t("div","btn");U.textContent="Save";this._2.appendChild(U);e.d6(U,j);
e.L_(this.y7,this.YR);this.B1=0;this.jl=w;var M=this.afr.bind(this),m=this.avH=e.t("div");m.setAttribute("style","text-align:center; font-size:1.6em");
var l=e.t("img");m.appendChild(l);e.x$(m);l.setAttribute("src",PIMG[Storage.list[this.jl][2]]);l.setAttribute("style","opacity:0.5; width:25%; cursor:pointer;");
e.d6(l,M);this.xP=e.t("div","btn");m.appendChild(this.xP);e.d6(this.xP,M);this.dA=new cA([{name:[6,20]},{name:[5,2],pn:[aK.CQ,aK.tM],r:function(){return{r:Storage.I0!=null}}}]);
this.dA.parent=this;this.dA.h("select",this.amy,this);this.y7.addEventListener("contextmenu",this.YR);
this.afb=e.t("span");this.KC=e.t("span");this.KC.setAttribute("style","position:absolute; right:0; top:5px;");
this.yh=[];this.HE=[];for(var L=0;L<3;L++){var A=e.t("div","btn");this.yh.push(A);this.afb.appendChild(A);
e.d6(A,j);A.textContent=["\u2B9C","\u2B9E","\uD83E\uDC09"][L]}for(var L=0;L<5;L++){var A=e.t("div","btn");
this.HE.push(A);this.KC.appendChild(A);e.d6(A,j)}window.addEventListener("message",this.akj.bind(this),!1);
this.a9H=!1;this.XN=0;setInterval(this.a69.bind(this),300);this.Wg();var g=this.asu=document.createElement("input");
g.setAttribute("type","file");g.addEventListener("change",this.au8.bind(this),!1);document.body.appendChild(g);
g.setAttribute("style","display:none");g.setAttribute("multiple","")}Storage.prototype=new eg;Storage.hi=!1;
Storage.prototype.au8=function(w){w.stopPropagation();w.preventDefault();var n=w.dataTransfer?w.dataTransfer.files:w.target.files;
this.afX=n.length;for(var L=0;L<n.length;L++){var W=n[L],D=new FileReader;D.oo=W;D.onload=this.ag9.bind(this);
D.readAsArrayBuffer(W)}};Storage.prototype.ag9=function(w){var n=Storage.I0;if(n==null)n=Storage.I0={};
n[w.target.oo.name]=w.target.result;this.afX--;if(this.afX==0)this.h0()};Storage.prototype.GZ=function(w,n){var W=Storage.list[this.jl][3],D=bh.rE();
if(W){if(this.XN==1&&e.LY(this.e)&&D!=null){this.Wg()}if(this.XN==2&&D==null){this.Z2("forget","")}}};
Storage.prototype.a69=function(){var w=e.LY(this.e),n=this.a9H;if(w&&!n){history.pushState(null,null,location.href);
window.onpopstate=function(){history.go(1)}}if(!w&&n){window.onpopstate=function(){};history.go(-1)}this.a9H=w};
Storage.prototype.Wg=function(){if(this.PA)document.body.removeChild(this.PA);this.O3=[[]];this.eR=0;
this.avw={"/":[]};this.ai9="";this.fl=null;this.ZW=[];this.mx=[];this.a2L=[];this.a7t=null;var w="code/storages/"+Storage.list[this.jl][1],n=this.PA=e.t("iframe");
n.setAttribute("src",w);n.setAttribute("style","display:none");document.body.appendChild(n)};Storage.prototype.c9=function(){return this.avw[this.UP()]};
Storage.prototype.wE=function(w){this.avw[this.UP()]=w};Storage.ED=function(L){var w=Storage.dg[L];if(w==null)w=Storage.dg[L]=new Storage(L);
return w};Storage.dg=[];Storage.y6=0;Storage.ayR="";Storage.h8=function(w,n){Storage.y6=w;Storage.ayR=n;
var W=Storage.dg;for(var L=0;L<W.length;L++)if(W[L])W[L].Uc()};Storage.au4=[200*(1<<20),2e3*(1<<20)];
Storage.Xc=0;Storage.pG=2;Storage.m1=0;Storage.list=[["This Device","deviceStorage.html","strg/tdevice",!1,"Give Photopea a direct access to a specific folder in your device."],["PeaDrive","peadriveStorage.html","strg/peadrive",!0,"A cloud storage system from Photopea."],["Dropbox","dropboxStorage.html","strg/dropbox",!1,"Give Photopea a direct access to your DropBox."],["OneDrive","onedriveStorage.html","strg/onedrive",!1,"Give Photopea a direct access to your OneDrive."],["Google Drive","googledriveStorage.html?mode=0","strg/gdrive",!1,"Give Photopea a direct access to your Google Drive."],["Shared Drives","googledriveStorage.html?mode=1","strg/gdrive",!1,"Give Photopea a direct access to Shared Drives in your Google Drive."],["Private Folder","googledriveStorage.html?mode=3","strg/gdrive",!1,"Let's make a folder \"Photopea\" in your Google Drive (we will have access only to that folder)."]];
Storage.auf=function(w){for(var L=0;L<Storage.dg.length;L++){if(Storage.dg[L]&&Storage.dg[L].PA.contentWindow==w)return!0}return!1};
Storage.prototype.af2=function(w){if(w.target.tagName=="INPUT")return;var n=aK;if(n.$L(w.code,n.m2)&&this.UP().length!=0)this.ay3();
else if(w.ctrlKey){if(n.$L(w.code,n.c)){var W=[];this.wE(W);for(var L=0;L<this.fl.length;L++)W.push(L);
this.v$()}if(n.$L(w.code,n.Ak))this.lI(2);if(n.$L(w.code,n.tM))this.h0()}else if(n.$L(w.code,n.yG)){var D=this.c9();
if(D.length!=0)this.a3R(D[0])}else if(n.$L(w.code,n.on)){this.eR=Math.max(this.eR-1,0);this.mb()}else{var j=0;
for(var L=65;L<=90;L++)if(w.code=="Key"+String.fromCharCode(L))j=L;if(j!=0){var I=String.fromCharCode(j).toLowerCase(),U=[],M=this.fl,m;
for(var L=0;L<M.length;L++)if(M[L][0][0].toLowerCase()==I)U.push(L);if(U.length==0)return;var D=this.c9();
if(D.length==0)m=U[0];else{var l=U.indexOf(D[0]);if(l==-1){m=U[0];for(var L=0;L<U.length;L++)if(U[L]>D[0]){m=U[L];
break}}else m=U[(l+1)%U.length]}this.wE([m]);this.v$(!0)}}};Storage.prototype.zl=function(w,n){this.gA=w;
this.ag=n;this.e.style.width=w+"px";this.e.style.height=n+"px";var W=w-30,D=Math.floor(W/230),W=Math.floor(W/D)-70;
this.awx.textContent=".storage .tile .name { width:"+W+"px; }";this.Dw.style.width=w-140+"px";this.y7.style.width=this.mj.style.width=w-20+"px";
this.y7.style.height=n-70-(Storage.y6==0?0:45)+"px"};Storage.prototype.afr=function(){this.mb()};Storage.prototype.mb=function(){this.Z2("show",this.UP())};
Storage.prototype.UP=function(w){var n=this.O3[this.eR],W="/"+n.join("/");if(w&&n.length!=0)W+="/";return W};
Storage.prototype.aod=function(w){var n=w.currentTarget,W=this.eR,D=this.yh.indexOf(n),j=this.HE.indexOf(n);
if(D>=0&&!this.acu(D))return;if(D==0){this.eR=Math.max(W-1,0);this.mb()}if(D==1){this.eR=Math.min(W+1,this.O3.length-1);
this.mb()}if(D==2){var I=this.O3[W+1]=this.O3[W].slice(0);I.pop();this.eR++;this.O3=this.O3.slice(0,this.eR+1);
this.mb()}if(j==0){var U=document.createEvent("MouseEvents");U.initMouseEvent("click",!0,!0,document.defaultView,1,0,0,0,0,!1,!1,!1,!1,0,null);
this.asu.dispatchEvent(U)}if(j==1){Storage.Xc=(Storage.Xc+1)%2;this.Uc()}if(j==2){Storage.pG=(Storage.pG+1)%3;
this.Uc()}if(j==3){Storage.m1=(Storage.m1+1)%3;this.Uc()}if(j==4){this.Z2("forget","")}if(n==this.Id){var M=this.Dw.value.trim(),m=this.fl,l=-1;
if(!M.toLowerCase().endsWith("psd")){alert("File Name has to end with \".psd\".");return}for(var L=0;
L<m.length;L++)if(m[L][0]==M)l=L;if(l!=-1){this.CC("Do you really want to replace \""+M+"\"?",this.apU.bind(this))}else this.apU()}};
Storage.prototype.apU=function(){var w=this.Dw.value.trim(),n=[this.jl,this.UP(!0)+w];this.DQ({d:b.c.abm,Il:n});
this.S(new ed("canclose",!0))};Storage.prototype.h0=function(){if(Storage.I0==null)return;this.DQ({d:b.c.Ql,mz:fV.get("Uploading ...")});
this.Jy=4;jA.ED(2,this.PA,[this.UP(),Storage.I0,this.fl],null,this.ap_.bind(this))};Storage.prototype.ap_=function(w){this.Jy=0;
this.DQ({d:b.c.SO,mz:fV.get("Uploading ...")});this.mb()};Storage.prototype.amy=function(w){var n=w.target.aJ();
if(w.target==this.dA){if(n[0]==0){var W=[fV.get([6,20]),-1,0];this.fl.push(W);this.Uc();var L=this.fl.indexOf(W),D=this.ZW[L].querySelector(".name");
console.log(D);var j=new et.IM(D,function(g){this.DQ({d:b.c.Ql,mz:fV.get([1,2])+" ..."});var k=this.UP(!0)+g+"/";
console.log(k);this.Z2("save",k)}.bind(this),!0)}else this.h0()}else{if(n[0]==0){this.lI(2)}else if(n[0]==1){var L=this.c9()[0],I=this.fl[L],D=this.ZW[L].querySelector(".name");
console.log(D);D.innerHTML=I[0];var j=new et.IM(D,function(g){g=g.trim();var k=this.fl;for(var L=0;L<k.length;
L++)if(k[L][0]==g){alert("Item with such name already exists.");this.Uc();return}var $=this.UP(!0)+I[0]+":"+g;
console.log($);this.Z2("rename",$)}.bind(this))}else if(n[0]==2){this.lI(3)}else if(n[0]==3)this.ay3();
else if(n[0]==4){this.lI(1)}else{var U=this.fl[this.c9()[0]],M=Storage.x3(U),m=M[n[1]],l=m[0],A=this.KV().pop()[1];
if(Storage.avC(U,l)!=-1){this.Z2("share",A+":"+l+":-1");alert("Unshared.")}else{this.Z2("share",A+":"+l+":"+n[2]);
alert("Shared.")}}}};Storage.avC=function(w,n){var W=w[4];if(W==null)return-1;if(W.indexOf(n+":0")!=-1)return 0;
if(W.indexOf(n+":1")!=-1)return 1;return-1};Storage.prototype.ay3=function(){var w=this.c9();this.CC("Do you really want to delete "+(w.length==1?"\""+this.fl[w[0]][0]+"\"":"these files")+"?",this.yN.bind(this))};
Storage.prototype.CC=function(w,n){var W={d:b.c.P2,jW:"confirm",Z:w,FJ:n};this.DQ(W)};Storage.prototype.lI=function(w){this.Jy=w;
if(1<w)this.DQ({d:b.c.Ql,mz:fV.get("Downloading ...")});else this.DQ({d:b.c.Ql,mz:fV.get("Getting info ...")});
jA.ED(0,this.PA,this.UP(),this.KV(!0),this.aqf.bind(this))};Storage.prototype.aqf=function(w){if(this.Jy==1){var n=0,W=0;
for(var D in w){var j=w[D];n+=j[1];W++}this.CC(W+" files, "+fp.cN(n)+" in total.",function(){});this.DQ({d:b.c.SO,mz:fV.get("Getting info ...")});
this.Jy=0}if(1<this.Jy)jA.ED(1,this.PA,w,null,this.aqz.bind(this))};Storage.prototype.aqz=function(w){if(1<this.Jy){if(1<this.Jy)this.DQ({d:b.c.SO,mz:fV.get("Downloading ...")});
var n={},W=this.UP(!0);for(var D in w)n[D.slice(W.length)]=w[D];if(this.Jy==2){Storage.I0=n;alert("Copied to a clipboard")}if(this.Jy==3){var j=Object.keys(w);
if(j.length==1)e8.save(w[j[0]].buffer,j[0].split("/").pop());else e8.save(UZIP.encode(n),W=="/"?"files.zip":this.UP().split("/").pop()+".zip")}}this.Jy=0};
Storage.I0=null;Storage.prototype.yN=function(){this.DQ({d:b.c.Ql,mz:fV.get([5,4])+" ..."});this.mx=this.KV();
this.wa()};Storage.prototype.wa=function(){if(this.mx.length==0){this.DQ({d:b.c.SO,mz:fV.get([5,4])+" ..."});
this.wE([]);this.mb()}else this.Z2("delete",this.mx.pop()[1])};Storage.prototype.KV=function(w){var n=[],W=this.UP(!0),D=this.c9();
for(var L=0;L<D.length;L++){var j=this.fl[D[L]];if(w)n.push(j[0]);else n.push([this.jl,W+j[0]])}return n};
Storage.prototype.Z2=function(w,n){e.W0(this.e,"disabled");this.ai9=w;if(Storage.hi)console.log(Math.floor(Date.now()/1e3),"{\"code\": \""+w+"\", \"prm\": "+JSON.stringify(n)+" }");
this.PA.contentWindow.postMessage("{\"code\": \""+w+"\", \"prm\": "+JSON.stringify(n)+" }","*")};Storage.prototype.akj=function(w){if(w.source!=this.PA.contentWindow||this.Jy!=0)return;
e.IX(this.e,"disabled");if(typeof w.data=="string"){if(Storage.hi)console.log("==",Math.floor(Date.now()/1e3),w.data);
var n=JSON.parse(w.data),W=n.code,D=n.prm,j=this.ai9,I=Storage.list[this.jl][3];if(W=="ready"){if(I&&!D){var U=bh.rE();
console.log(U);var M=bh.bl(),m=M.acc;if(U==null){this.XN=1;alert("Log in to use this storage (press Account at the top).");
this.A2();return}var l=[],A=U.wantToJoin;for(var g in A)l.push(parseInt(g.slice(1)));var k=[],$=U.inTeams;
for(var L=0;L<$.length;L++)k.push($[L][2]);var C={uid:U.id,limit:Storage.au4[bh.d$()?1:0],inTeams:k,myTeams:l};
C.secret=m&&m.pds?m.pds:"";this.Z2("login",C);return}if(I)this.XN=2;if(I&&n.secret){var M=bh.bl(),m=M.acc;
if(m==null)m=M.acc={};m.pds=n.secret;bh.qK(M)}if(D)this.mb();else this.A2()}else if(W!="0"){if(j=="save")this.DQ({d:b.c.SO,mz:fV.get([1,2])+" ..."});
if(j=="delete")this.wa();alert(D);this.Uc()}else if(j=="show"){this.fl=D;this.Uc()}else if(j=="save"){this.DQ({d:b.c.SO,mz:fV.get([1,2])+" ..."});
this.mb()}else if(j=="delete"){this.wa()}else if(j=="forget"){if(I)this.A2();else this.Wg()}else if(j=="rename"||j=="share"){this.mb()}else throw W}else{if(Storage.hi)console.log(Math.floor(Date.now()/1e3,"==","ArrayBuffer[]"));
this.DQ({d:b.c.akb,Il:this.KV()[0],Ey:w.data});this.DQ({d:b.c.SO,mz:"Opening ..."})}};Storage.prototype.A2=function(){e._g(this.mj);
e._g(this.y7);e._g(this.Bt);this.y7.appendChild(this.avH)};Storage.prototype.acu=function(L){if(L==0)return this.eR>0;
if(L==1)return this.eR<this.O3.length-1;if(L==2)return this.UP()!="/"};Storage.prototype.Uc=function(){var w=Storage.list[this.jl][3],n=this.fl,W=Storage.pG,D=Storage.Xc,j=Storage.m1;
if(n==null)return;n.sort(function(R,x){var v=R[1]==-1?1:5,N=x[1]==-1?1:5,u=0;if(Math.min(v,N)==1&&v!=N)return v-N;
else if(v==1||W==0)u=R[0].toLowerCase()<x[0].toLowerCase()?-1:1;else if(W==1)u=R[1]-x[1];else if(W==2)u=R[2]-x[2];
if(D==1)u=-u;if(R[0]=="Shared")u=-1;if(x[0]=="Shared")u=1;return u});var I=this.y7,U=this.mj,M=this.O3[this.eR];
e._g(I);e._g(U);this.ZW=[];for(var L=0;L<3;L++)if(this.acu(L))e.IX(this.yh[L],"disabled");else e.W0(this.yh[L],"disabled");
U.appendChild(this.afb);U.appendChild(this.KC);var m=e.t("span");m.textContent="/";U.appendChild(m);
for(var L=0;L<M.length;L++){var m=e.t("span");m.textContent=M[L];U.appendChild(m);var m=e.t("span");
m.textContent="/";U.appendChild(m)}var l=["tile","icon","litm"][j];for(var L=0;L<n.length;L++){var A=n[L],g=A[1]==-1,k=g?"":fp.cN(A[1]),$=e.t("div","cont "+l),Y=!1;
I.appendChild($);this.ZW.push($);$.setAttribute("title",A[0]+(g?"":"\nSize: "+k+"\nDate Modified: "+new Date(A[2]*1e3).toLocaleString().replaceAll(". ",".")));
var C=e.t("img");C.setAttribute("src",g?Storage.aoD:A[3]?A[3]:Storage.oo);if(!g&&A[3])C.setAttribute("style","box-shadow: 1px 1px 2.5px rgba(0,0,0, .4);");
var f=e.t("span","name"),z=A[0];if(l=="icon"&&z.length>30)z=z.slice(0,24)+".."+z.slice(z.length-5);if(w&&M.length==1&&M[0]=="Shared"){var s=Storage.x3(),O=parseInt(z.slice(5));
for(var a=0;a<s.length;a++)if(s[a][0]==O)z=s[a][1]}f.textContent=z;$.appendChild(C);$.appendChild(f);
if(l!="icon"&&!g){if(l=="tile")e.x$(f);var X=e.t("span");X.textContent=k;X.style.opacity="0.8";(l=="tile"?f:$).appendChild(X)}var P=A[0].split("."),Z=(P.length==1?"":P.pop()).toUpperCase();
if(w&&A[0]=="Shared"&&M.length==0){Y=!0;Z="\u21E7"}if(l!="litm"&&(!g&&A[3]==null||Y)){var K=e.t("span","ext");
K.textContent=Z;var S=Storage.Nw[Z];K.style.backgroundColor=S?S:Storage.a0g(Z);$.appendChild(K)}e.L_($,this.YR);
$.addEventListener("contextmenu",this.YR)}this.v$();var G=this._2.parentNode!=null,V=Storage.y6,T=this.e;
if(G&&V==0)T.removeChild(this._2);if(!G&&V==1)T.appendChild(this._2);this.zl(this.gA,this.ag);this.f()};
Storage.prototype.v$=function(w){var n=this.ZW,W=this.fl,D=this.c9(),j=!1,I=0;for(var L=0;L<n.length;
L++){var U=W[L],M=U[1]==-1,m=n[L];if(Storage.y6==1&&!M&&!U[0].toLowerCase().endsWith(".psd"))m.style.display="none";
else m.style.display="auto";if(D.indexOf(L)==-1)e.IX(m,"active");else{if(M)j=!0;else I+=U[1];e.W0(m,"active");
if(w)m.scrollIntoView({block:"center",behavior:"smooth"})}}var l=j?"":fp.cN(I);this.Bt.textContent=D.length==0?"":D.length+" item"+(D.length==1?"":"s")+" selected\u2001"+l;
this.Dw.value=D.length==1&&!j?W[D[0]][0]:Storage.ayR};Storage.prototype.a3R=function(L){var w=this.fl[L];
if(w[1]==-1){var n=this.O3[this.eR].slice(0);n.push(w[0]);this.eR++;this.O3[this.eR]=n;this.O3=this.O3.slice(0,this.eR+1);
this.wE([]);this.mb()}else if(Storage.y6==0){this.DQ({d:b.c.Ql,mz:"Opening ..."});this.S(new ed("canclose",!0));
var W=this.UP(!0)+w[0];this.Z2("load",W)}};Storage.prototype.f=function(){var w=Storage.pG,n=Storage.Xc,W=Storage.m1;
this.HE[0].textContent="Upload";this.HE[1].textContent=["\uD83E\uDC0B","\uD83E\uDC09"][n];this.HE[2].textContent=fV.get([[12,48],[12,14,0],"Date"][w]);
this.HE[3].textContent=fV.get(["Tiles","Icons",[25,3,1]][W]);this.HE[4].textContent="\u2716";this.xP.innerHTML=fV.get([[23,6],Storage.list[this.jl][0]])+"<br/><small><small>"+Storage.list[this.jl][4]+"</small></small>";
this.GZ()};Storage.prototype.acv=function(w){this.DQ({d:b.c.xl});if(e.LY(this.avH))return;if(w.button==3||w.button==4){if(Date.now()-this.a4N>50){var n=this.eR;
if(w.button==3)this.eR=Math.max(n-1,0);else this.eR=Math.min(n+1,this.O3.length-1);this.mb()}this.a4N=Date.now();
return}w.stopPropagation();var L=this.ZW.indexOf(w.currentTarget);if(w.type=="contextmenu"){if(this.fl==null)return;
w.preventDefault();var W=this.dA;if(L!=-1){var D=[{name:[5,1],pn:[aK.CQ,aK.Ak]},{name:[6,37]},{name:"Download",nW:!0},{name:[5,4],pn:[aK.m2]},{name:"Properties"}];
if(Storage.list[this.jl][3]){var j=this.fl[L],I=Storage.x3(j);if(I.length!=0){var U=[];for(var M=0;M<I.length;
M++){var m=[],l=I[M],A=Storage.avC(j,l[0]);if(A!=-1)m.push({name:"Unshare"});else m.push({name:"Allow Read"},{name:"Allow Read & Write"});
U.push({name:l[1]+[""," (R)"," (R,W)"][A+1],sub:m})}D.push({name:"Share With",sub:U})}}W=new cA(D);W.parent=this;
W.h("select",this.amy,this)}W.parent=this;W.f();W.update();this.DQ({d:b.c.Uq,BT:W,x:w.clientX+4,y:w.clientY});
return}var g=this.c9(),k=g.indexOf(L);if(w.button!=0&&k!=-1)return;if(w.target==this.y7)this.wE([]);
else{if(w.ctrlKey){if(k==-1)g.push(L);else g.splice(k,1)}else if(w.shiftKey&&g.length!=0){var M=g[0];
if(M<L){var $=L;L=M;M=$}g=[];this.wE(g);for(var C=L;C<=M;C++)g.push(C)}else{this.wE([L]);if(Date.now()-this.B1<300&&g.length!=0&&g[0]==L){this.a3R(L);
this.B1=0}}}this.B1=Date.now();this.v$()};Storage.prototype.DQ=function(w){var n=new ed(b.E.L,!0);n.data=w;
this.S(n)};Storage.x3=function(w){var n=[],W=[],D=bh.bl(),j=D.acc.tstart;if(j)for(var L=0;L<j.length;
L++){n.push([j[L][2],j[L][0]]);W.push(j[L][2])}var I=bh.rE();j=I.inTeams;if(j)for(var L=0;L<j.length;
L++){n.push([j[L][2],j[L][0]]);W.push(j[L][2])}if(w&&w[4]){for(var L=0;L<w[4].length;L++){var U=parseInt(w[4][L].split(":")[0]);
if(W.indexOf(U)==-1)n.push([U,"Team "+U])}}return n};Storage.prototype.agQ=function(w,n){this.DQ({d:b.c.Ql,mz:fV.get([1,2])+" ..."});
this.Z2("save",w);if(Storage.hi)console.log(Math.floor(Date.now()/1e3),"ArrayBuffer[]");this.PA.contentWindow.postMessage(n,"*")};
Storage.Nw={PDF:"#ff2222",PSD:"#005599",PSB:"#005599"};Storage.a0g=function(w){w=w.toLowerCase();var n=0;
for(var L=0;L<w.length;L++)n+=w.charCodeAt(L)*613<<8*L;return"#"+E.$$(n&16777215)};Storage.aoD="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjIiIGJhc2VQcm9maWxlPSJ0aW55LXBzIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0ODggNDEwIiB3aWR0aD0iNDg4IiBoZWlnaHQ9IjQxMCI+PHRpdGxlPmZvbGRlci1zdmc8L3RpdGxlPjxzdHlsZT50c3BhbiB7IHdoaXRlLXNwYWNlOnByZSB9LnNocDAgeyBmaWxsOiAjZGJiMDY1IH0gLnNocDEgeyBmaWxsOiAjOTY3YTQ0IH0gLnNocDIgeyBmaWxsOiAjZjVjZTg1IH0gPC9zdHlsZT48cGF0aCBjbGFzcz0ic2hwMCIgZD0iTTcuMiA0MDMuNEw3LjIgNi42TDEzOC45NSA2LjZMMTc3LjM1IDQ1TDQ4MC44IDQ1TDQ4MC44IDQwMy40TDcuMiA0MDMuNFoiIC8+PHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGFzcz0ic2hwMSIgZD0iTTE0MS42IDAuMkwxODAgMzguNkw0ODcuMiAzOC42TDQ4Ny4yIDQwOS44TDAuOCA0MDkuOEwwLjggMC4yTDE0MS42IDAuMlpNMTMuNiAxM0wxMy42IDM5N0w0NzQuNCAzOTdMNDc0LjQgNTEuNEwxNzQuNyA1MS40TDEzNi4zIDEzTDEzLjYgMTNaIiAvPjxnID48cGF0aCBjbGFzcz0ic2hwMiIgZD0iTTcuMiA0MDMuNEw3LjIgNzAuNkwxNDMuNTMgNzAuNkwxODEuOTMgNDVMNDgwLjggNDVMNDgwLjggNDAzLjRMNy4yIDQwMy40WiIgLz48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsYXNzPSJzaHAxIiBkPSJNNDg3LjIgMzguNkw0ODcuMiA0MDkuOEwwLjggNDA5LjhMMC44IDY0LjJMMTQxLjYgNjQuMkwxODAgMzguNkw0ODcuMiAzOC42Wk0xODMuODggNTEuNEwxNDUuNDggNzdMMTMuNiA3N0wxMy42IDM5N0w0NzQuNCAzOTdMNDc0LjQgNTEuNEwxODMuODggNTEuNFoiIC8+PC9nPjwvc3ZnPg==";
Storage.oo="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjIiIGJhc2VQcm9maWxlPSJ0aW55LXBzIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzNDggNDI0IiB3aWR0aD0iMzQ4IiBoZWlnaHQ9IjQyNCI+PHRpdGxlPmZpbGUtc3ZnPC90aXRsZT48c3R5bGU+dHNwYW4geyB3aGl0ZS1zcGFjZTpwcmUgfS5zaHAwIHsgZmlsbDogI2ZmZmZmZiB9IC5zaHAxIHsgZmlsbDogI2M3ZDdlMiB9IC5zaHAyIHsgZmlsbDogIzQ1NGI1NCB9IDwvc3R5bGU+PHBhdGggY2xhc3M9InNocDAiIGQ9Ik0yOTYgNDEyTDUyIDQxMkMzMCA0MTIgMTIgMzk0IDEyIDM3MkwxMiA1MkMxMiAzMCAzMCAxMiA1MiAxMkwyOTYgMTJDMzE4IDEyIDMzNiAzMCAzMzYgNTJMMzM2IDM3MkMzMzYgMzk0IDMxOCA0MTIgMjk2IDQxMloiIC8+PHBhdGggY2xhc3M9InNocDEiIGQ9Ik01MiA1MkwyOTYgNTJMMjk2IDExMkw1MiAxMTJMNTIgNTJaTTI3MiAxOTJMNjggMTkyQzYxLjIgMTkyIDU2IDE4Ni44IDU2IDE4MEM1NiAxNzMuMiA2MS4yIDE2OCA2OCAxNjhMMjcyIDE2OEMyNzguOCAxNjggMjg0IDE3My4yIDI4NCAxODBDMjg0IDE4Ni44IDI3OC44IDE5MiAyNzIgMTkyWk0yNzIgMjUyTDY4IDI1MkM2MS4yIDI1MiA1NiAyNDYuOCA1NiAyNDBDNTYgMjMzLjIgNjEuMiAyMjggNjggMjI4TDI3MiAyMjhDMjc4LjggMjI4IDI4NCAyMzMuMiAyODQgMjQwQzI4NCAyNDYuOCAyNzguOCAyNTIgMjcyIDI1MlpNMTc0IDMxMkw2OCAzMTJDNjEuMiAzMTIgNTYgMzA2LjggNTYgMzAwQzU2IDI5My4yIDYxLjIgMjg4IDY4IDI4OEwxNzQgMjg4QzE4MC44IDI4OCAxODYgMjkzLjIgMTg2IDMwMEMxODYgMzA2LjggMTgwLjggMzEyIDE3NCAzMTJaIiAvPjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xhc3M9InNocDIiIGQ9Ik0yOTYgNDI0TDUyIDQyNEMyMy4yIDQyNCAwIDQwMC44IDAgMzcyTDAgNTJDMCAyMy4yIDIzLjIgMCA1MiAwTDI5NiAwQzMyNC44IDAgMzQ4IDIzLjIgMzQ4IDUyTDM0OCAzNzJDMzQ4IDQwMC44IDMyNC44IDQyNCAyOTYgNDI0Wk01MiAyNEMzNi40IDI0IDI0IDM2LjQgMjQgNTJMMjQgMzcyQzI0IDM4Ny42IDM2LjQgNDAwIDUyIDQwMEwyOTYgNDAwQzMxMS42IDQwMCAzMjQgMzg3LjYgMzI0IDM3MkwzMjQgNTJDMzI0IDM2LjQgMzExLjYgMjQgMjk2IDI0TDUyIDI0WiIgLz48L3N2Zz4=";
var jA=function(){var w,n,W,D,j,I,U,M;function m($,C,f,z,s){n=C;D=z;U=s;w=$;I={};if(w==0){W=[f]}if(w==1){W=[];
for(var O in f)W.push(O)}if(w==2){var a=f[0],X=f[1],P=f[2],Z={};for(var L=0;L<P.length;L++)Z[P[L][0]]=!0;
var Y={};for(var O in X){var K=O.split("/"),S=K[0],G=S.split("."),V="";if(G.length!=1){V="."+G.pop();
S=G.join(".")}while(Z[S+V])S+=" - Copy";K[0]=S+V;Y[K.join("/")]=X[O]}var T={};W=[];for(var O in Y){var K=O.split("/");
for(var L=0;L<K.length-1;L++){var R=a+K.slice(0,L+1).join("/")+"/";if(T[R]==null){T[R]=!0;W.push([R])}}W.push([a+O,Y[O]])}}window.addEventListener("message",A,!1);
M=Date.now();l()}function l(){if(W.length==0){k();return}j=W.shift();if(w==0)g("show",j);if(w==1)g("load",j);
if(w==2){g("save",j[0]);if(j.length==2)n.contentWindow.postMessage(j[1],"*")}}function A($){if($.source!=n.contentWindow)return;
if(w==0){var C=JSON.parse($.data),f=C.code,z=C.prm;for(var L=0;L<z.length;L++){var s=z[L];if(D&&D.indexOf(s[0])==-1)continue;
var O=j+(j=="/"?"":"/"),a=O+s[0];if(s[1]==-1)W.push(a);else I[a]=s}D=null}else if(w==1){I[j]=new Uint8Array($.data)}l()}function g($,C){var f=$=="show"?", \"nothumbs\": true":"",z="{\"code\": \""+$+"\", \"prm\": "+JSON.stringify(C)+f+" }";
n.contentWindow.postMessage(z,"*")}function k(){console.log(Date.now()-M);window.removeEventListener("message",A,!1);
U(I)}return{ED:m}}();function cg(w){eg.call(this);var n=this.e=e.t("div","form scrollable padded label12");
this.ki=w;this.KP=null;var W=[],D=cg.ie[w];this.EL=[];for(var j in D){var I=parseInt(j.slice(1)),U=I%10==0?"":"\u2800\u2800- ";
W.push(U+D[j]);this.EL.push(I)}this.VV=[new e7("Name",null,30),new e7("Description",null,30,4),w==0?new e7("File"," www.Photopea.com#i...",17):new aH("File",!1,!1),new e7("Thumbnail URL","* Use Imgur.com etc.",17),new i0("Category",W),new b7("Make Public"),new iP("<< Back",null,null,!0),new iP("Save",null,null,!0)];
if(w==0)this.VV.push(new ga("Publish your PSD: File - Publish Online - PSD. Use that URL as \"File\"."),new ga("Get a Thumbnail URL: File - Publish Online - JPG. At Imgur.com, right-click your image and choose \"Copy Image Address\"."));
if(w==1)this.VV.push(new ga("\"File\" - select a .JSON file of a plugin from your computer. The content must be: {\"name\": ..., \"url\":..., \"icon\":... }"));
if(w!=0)this.VV.push(new ga("Do not load any file to preserve the old version."));for(var L=0;L<this.VV.length;
L++){var M=this.VV[L];n.appendChild(M.e);M.parent=this;if(L!=4&&L!=6)e.x$(n);if(M instanceof iP)M.h("click",this.af3,this)}}cg.prototype=new eg;
cg.prototype.af3=function(w){if(w.target==this.VV[6]){this.S(new ed("back"));return}var n=this.VV[3].b().trim(),W=n.startsWith("http")&&(n.endsWith(".jpeg")||n.endsWith(".jpg")||n.endsWith(".png")||n.endsWith(".gif"));
if(!W){alert("Thumbnail URL is incorrect.");return}var D=new XMLHttpRequest,j=(n);
D.open("GET",j);D.responseType="arraybuffer";D.onload=this.al1.bind(this);D.send()};cg.prototype.al1=function(w){var n=w.target.response,W=n.byteLength;
if(W>2e5&&jj.zJ(n)!="gif"){alert("Thumbnail is too large ("+fp.cN(W)+"). Make it under 200 kB.");return}var D=this.VV[2].b(),j=Object.keys(D);
if(this.ki!=0&&j.length!=0){console.log(D);e8.sU.amv(D[j[0]].buffer,j[0],this.aaJ.bind(this),"pp-resources");
return}this.aaJ()};cg.prototype.aaJ=function(w){var n=this.ki,W="name desc file thmb catg publ".split(" "),D=this.KP;
for(var L=0;L<6;L++){if(n!=0&&L==2)continue;var j=this.VV[L].b();if(L<=3){j=j.trim();if(j.length==0){alert("One of values is empty.");
return}}if(L==2){var I=j.split("#i");if(I.length!=2||I[1].length!=8){alert("File ID is incorrect.");
return}j=I.pop()}if(L==4)j=this.EL[j];D[W[L]]=j}if(n!=0){if(w)D.file=w;else if(D.file==null){alert("Select a file from your computer.");
return}}if(D.utme.length==0)D.utme=""+Math.round(Date.now()/1e3);D.type=n;this.S(new ed("save"))};cg.prototype.f=function(){};
cg.prototype.$=function(w){var n=this.KP=JSON.parse(JSON.stringify(w)),W="name desc file thmb catg publ".split(" ");
for(var L=0;L<6;L++){var D=n[W[L]];if(D!=""&&L==2)D="https://photopea.com#i"+D;if(L==4)D=this.EL.indexOf(D);
if(L==5&&D==null)D=!0;this.VV[L].$(D)}};cg.prototype.b=function(){return JSON.parse(JSON.stringify(this.KP))};
cg.ie=[{c0:"Mockups",c1:"Mobile & Web",c2:"Prints",c3:"Product",c10:"Social Media",c11:"Youtube",c12:"Instagram",c13:"Facebook",c14:"Memes",c15:"Signs",c16:"Animations",c20:"Print",c21:"Cards",c22:"Invitations",c23:"Brochures",c24:"Resumes",c25:"Diploma / Certificate",c30:"Mobile",c40:"Websites",c50:"Presentations",c60:"Other"},{c0:"Resources",c1:"Image Elements",c2:"Fonts",c10:"Effects",c11:"Filters",c12:"Combine Elements",c13:"Text Effects",c20:"Generate Content",c30:"Other Plugins"},{c0:"Default"},{c0:"Default"},{c0:"Default"},{c0:"Default"},{c0:"Default"},{c0:"Default"},{c0:"Default"}];
function gu(w){eg.call(this);this.o8=w;this.e=e.t("div","");this.pE=[];this.Fx=null;this.a2V=[]}gu.prototype=new eg;
gu.prototype.$A=function(w){};gu.prototype.Fn=function(){return!1};gu.prototype.zl=function(w,n){};gu.prototype.GZ=function(w,n){};
gu.prototype.pH=function(w){};gu.prototype.$=function(w,n,W,D,j,I){var U=[],M=this.pE,m=0,l=cx.fI["s"+this.o8];
l?l(w,U,I):this.qa(w,U,I);for(var L=0;L<M.length;L++)if(!(M[L]instanceof ga))M[L].$(U[m++]);if(w.RndS)this.Fx=w.RndS.v};
gu.prototype.b=function(){var w=cx._1(this.o8),n=[],W=this.pE,D=0;for(var L=0;L<W.length;L++)if(!(W[L]instanceof ga))n[D++]=W[L].b();
var j=cx.fI["g"+this.o8];j?j(w,n):this.EC(w,n);if(w.RndS)w.RndS.v=this.Fx;return w};gu.prototype.oe=function(w){};
gu.prototype.FI=function(w){if(w&&w.target instanceof iP){this.Fx=Math.floor(Math.random()*4294967295)}var n=this.a2V;
for(var L=0;L<n.length;L+=2){var W=this.pE[n[L]],D=this.pE[n[L+1]],j=W.b(),I=D.b();if(w.target==W)D.$(Math.max(j,I));
else W.$(Math.min(j,I))}this.S(new ed(b.E.A))};gu.prototype.f=function(){for(var L=0;L<this.pE.length;
L++)this.pE[L].f();var w=this.a1i;if(w)w.f()};gu.prototype.sk=function(w){e.W0(this.e,"form");var n=this.pE;
for(var L=0;L<n.length;L++){var W=n[L];W.parent=this;W.h(b.E.A,this.FI,this);this.e.appendChild(W.e);
if(W instanceof b7&&n[L+1]instanceof gM)continue;if(w&&w.indexOf(L)!=-1)e.R2(this.e);else e.x$(this.e)}var D=cx._1(this.o8);
if(D.RndS){var j=this.a1i=new iP([25,1,2],null,null,!0);this.e.appendChild(j.e);j.h("click",this.FI,this)}};
gu.prototype.tZ=function(){return!1};gu.prototype.WQ=function(w,n,W,D,j){};gu.prototype.QD=function(w,n,W,D,j){};
gu.prototype.H5=function(w,n,W,D,j){};gu.prototype.EC=function(w,n){};gu.prototype.qa=function(w,n){};
gu.prototype.OH=function(w){var n=w.target.b().indexOf(!0)!=-1,W=new ed(b.E.L,!0);W.HH=!0;W.data={d:n?b.c.CV:b.c.Oy,G:y.o0};
this.S(W);W=new ed(b.E.v,!0);W.G=y.o0;W.HH=!0;W.data={d:"supertool",G:n?this:null};this.S(W)};gu.agE=function(w){w.tZ=function(){return!0};
w.WQ=function(n,W,D,j,I){this.J3=!0;this.ahC(n,I)};w.QD=function(n,W,D,j,I){if(!this.J3)return;this.ahC(n,I)};
w.H5=function(n,W,D,j,I){this.J3=!1};w.ahC=function(n,W){var D=new iB(0,0,n.m,n.n);if(n.J)D=n.J.rect;
var j=n.u.Cg(W.x,W.y);j.x-=D.x;j.y-=D.y;function I(U,M){return Math.round(Math.max(0,Math.min(100,100*U/M)))}this.pE[2].$(I(j.x,D.m));
this.pE[3].$(I(j.y,D.n));this.FI()}};gu.Bokh=function(){gu.call(this,"Bokh");this.pE=[new i0("Depth Map",["A","b"]),new eu("Focal Distance",0,255),new b7([4,11]),new i0([12,76,1],["Triangle (3)",["VAR0 (4)",[12,93,3]],"Pentagon (5)","Hexagon (6)","Heptagon (7)","Octagon (8)"]),new eu([12,56],0,100),new eu([12,15],0,360),new eu([12,2],0,100),new eu([4,13],0,255),new eu([24,6],0,100),new j$([12,58],[[12,59,0],[12,59,1]]),new b7([12,60])];
this.sk([5,7])};gu.Bokh.prototype=new gu;gu.Bokh.prototype.qa=function(w,n,W){var D=[[22,5,0],[6,5,3],[6,2]],j=w.BkDi.v.BtDi,I=w.BkDc,U=0;
if(j=="BeIn")U=0;else if(j=="BeIt"&&I.v.BtDc=="BeCt")U=1;else if(j=="BeIt"&&I.v.BtDc=="BeCm")U=2;else U=3+I.v;
for(var L=0;L<W[1].length;L++)D.push(W[1][L].name);this.pE[0].TF(D,[3]);n[0]=U;n[1]=w.BkDp.v;n[2]=w.BkDs.v;
n[3]=parseInt(w.BkIs.v.BtIs.slice(3))-3;n[4]=w.BkIb.v;n[5]=w.BkIr.v;n[6]=w.BkSb.v;n[7]=w.BkSt.v;n[8]=w.BkNa.v;
n[9]=w.BkNt.v.BtNt=="BeNu"?0:1;n[10]=w.BkNm.v};gu.Bokh.prototype.EC=function(w,n){var W;if(n[0]==0){W="BeIn";
delete w.BkDc}else if(n[0]<3){W="BeIt";w.BkDc={t:"enum",v:{BtDc:["BeCt","BeCm"][n[0]-1]}}}else{W="BeIa";
w.BkDc={t:"long",v:n[0]-3}}w.BkDi.v.BtDi=W;w.BkDp.v=n[1];w.BkDs.v=n[2];w.BkIs.v.BtIs="BeS"+(3+n[3]);
w.BkIb.v=n[4];w.BkIr.v=n[5];w.BkSb.v=n[6];w.BkSt.v=n[7];w.BkNa.v=n[8];w.BkNt.v.BtNt=["BeNu","BeNg"][n[9]];
w.BkNm.v=n[10]};gu.oilPaint=function(){gu.call(this,"oilPaint");this.pE=[new eu([12,56],.1,10,"px",!0),new eu("Cleanliness",0,10,"px",!0),new eu([12,38],.1,10,null,!0),new eu("Bristle Detail",0,10,null,!0),new b7("Lighting"),new eu("Shine",0,10,null,!0),new aA([12,15])];
this.sk()};gu.oilPaint.prototype=new gu;gu.oilPaint.prototype.qa=function(w,n){var W="stylization cleanliness brushScale microBrush lightingOn specularity".split(" ");
for(var L=0;L<W.length;L++)n[L]=w[W[L]].v;n[6]=[w.LghD.v]};gu.oilPaint.prototype.EC=function(w,n){var W="stylization cleanliness brushScale microBrush lightingOn specularity".split(" ");
for(var L=0;L<W.length;L++)w[W[L]].v=n[L];w.LghD.v=n[6][0]};gu.TrcC=function(){gu.call(this,"TrcC");
this.pE=[new eu("Level",0,255),new j$([12,69],[[19,4,1],[19,4,0]])];this.sk()};gu.TrcC.prototype=new gu;
gu.TrcC.prototype.qa=function(w,n){n[0]=w.Lvl.v;n[1]=["Lwr","Upr"].indexOf(w.Edg.v.CntE)};gu.TrcC.prototype.EC=function(w,n){w.Lvl.v=n[0];
w.Edg.v.CntE=["Lwr","Upr"][n[1]]};gu["Dfs "]=function(){gu.call(this,"Dfs ");this.pE=[new j$([12,36],[[15,10,0],[15,10,6],[15,10,11],"Anisotropic"])];
this.sk()};gu["Dfs "].prototype=new gu;gu["Dfs "].prototype.qa=function(w,n){n[0]=["Nrml","DrkO","LghO","anisotropic"].indexOf(w.Md.v.DfsM)};
gu["Dfs "].prototype.EC=function(w,n){w.Md.v.DfsM=["Nrml","DrkO","LghO","anisotropic"][n[0]]};gu.Embs=function(){gu.call(this,"Embs");
this.pE=[new aA([12,15]),new eu([12,42],1,100,"px"),new eu([12,57],1,500,"%")];this.sk()};gu.Embs.prototype=new gu;
gu.Embs.prototype.qa=function(w,n){n[0]=[w.Angl.v];n[1]=w.Hght.v;n[2]=w.Amnt.v};gu.Embs.prototype.EC=function(w,n){w.Angl.v=n[0][0];
w.Hght.v=n[1];w.Amnt.v=n[2]};gu["Wnd "]=function(){gu.call(this,"Wnd ");this.pE=[new j$([12,32],["Wind","Blast","Stagger"]),new j$([12,33],["From the Right","From the Left"])];
this.sk()};gu["Wnd "].prototype=new gu;gu["Wnd "].prototype.qa=function(w,n){n[0]=["Wnd","Blst","Stgr"].indexOf(w.WndM.v.WndM);
n[1]=["Left","Rght"].indexOf(w.Drct.v.Drct)};gu["Wnd "].prototype.EC=function(w,n){w.WndM.v.WndM=["Wnd","Blst","Stgr"][n[0]];
w.Drct.v.Drct=["Left","Rght"][n[1]]};gu.denoise=function(){gu.call(this,"denoise");this.pE=[new eu([12,64],0,10),new eu([12,65],0,100,"%")];
this.sk()};gu.denoise.prototype=new gu;gu.denoise.prototype.qa=function(w,n){var W=w.channelDenoise.v[0].v;
n[0]=W.Amnt.v;n[1]=W.EdgF.v};gu.denoise.prototype.EC=function(w,n){var W=w.channelDenoise.v[0].v;W.Amnt.v=n[0];
W.EdgF.v=n[1]};gu.lightFilterGradient=function(){gu.call(this,"lightFilterGradient");this.pE=[new eu([24,3,1],0,100,"px",1,!0),new eu([12,38],0,200,"%"),new b7([4,11]),new eu("High",0,100,"%"),new eu("Medium",0,100,"%"),new eu("Low",0,100,"%")];
this.sk()};gu.lightFilterGradient.prototype=new gu;gu.lightFilterGradient.prototype.qa=function(w,n){n[0]=w.blur.v;
n[1]=w.textureScale.v*100;n[2]=w.Scl.v==-1;var W=w.Dtl.v;n[3]=W[0].v*100;n[4]=W[1].v*100;n[5]=W[2].v*100};
gu.lightFilterGradient.prototype.EC=function(w,n){w.blur.v=n[0];w.textureScale.v=n[1]/100;w.Scl.v=n[2]?-1:1;
var W=w.Dtl.v;W[0].v=n[3]/100;W[1].v=n[4]/100;W[2].v=n[5]/100};gu.Fbrs=function(){gu.call(this,"Fbrs");
this.pE=[new eu("Variance",1,64),new eu([12,64],1,64)];this.sk()};gu.Fbrs.prototype=new gu;gu.Fbrs.prototype.qa=function(w,n){n[0]=w.Vrnc.v;
n[1]=w.Strg.v};gu.Fbrs.prototype.EC=function(w,n){w.Vrnc.v=n[0];w.Strg.v=n[1]};gu.LnsF=function(){gu.call(this,"LnsF");
this.pE=[new eu([12,2],10,300,"%"),new j$([12,44],["Lens 1","Lens 2","Lens 3","Lens 4"]),new eu("Position X",0,100,"%"),new eu("Position Y",0,100,"%")];
this.sk()};gu.LnsF.prototype=new gu;gu.LnsF.prototype.qa=function(w,n){n[0]=w.Brgh.v;n[1]=["Zm","Nkn","Nkn1","PnVs"].indexOf(w.Lns.v.Lns);
var W=w.FlrC.v;n[2]=Math.round(W.Hrzn.v*100);n[3]=Math.round(W.Vrtc.v*100)};gu.LnsF.prototype.EC=function(w,n){w.Brgh.v=n[0];
w.Lns.v.Lns=["Zm","Nkn","Nkn1","PnVs"][n[1]];var W=w.FlrC.v;W.Hrzn.v=n[2]/100;W.Vrtc.v=n[3]/100};gu.agE(gu.LnsF.prototype);
gu.blendOptions=function(){gu.call(this,"blendOptions");this.pE.push(new i0([12,19,0],dD.AE,dD.E5));
this.pE.push(new eu([12,0],0,100,"%"));this.sk()};gu.blendOptions.prototype=new gu;gu.blendOptions.prototype.qa=function(w,n){n[0]=dD.ik.indexOf(w.Md.v.BlnM);
n[1]=w.Opct.v.val};gu.blendOptions.prototype.EC=function(w,n){w.Md.v.BlnM=dD.ik[n[0]];w.Opct.v.val=n[1]};
gu.LnCr=function(){gu.call(this,"LnCr");this.pE=[new eu([12,57],-100,100),new eu([12,38],10,150,"%")];
this.sk()};gu.LnCr.prototype=new gu;gu.LnCr.prototype.qa=function(w,n){n[0]=w.LnIa.v;n[1]=w.LnSi.v};
gu.LnCr.prototype.EC=function(w,n){w.LnIa.v=n[0];w.LnSi.v=n[1]};gu.adaptCorrect=function(){gu.call(this,"adaptCorrect");
var w=f2;this.pE=[new ga([19,6,0]),new w([12,57],0,100,"%"),new w("Tone",0,100,"%"),new w([12,56],0,200,"px"),new ga([19,6,2]),new w([12,57],0,100,"%"),new w("Tone",0,100,"%"),new w([12,56],0,200,"px"),new ga([3]),new w([13,0],-100,100)];
this.sk([3,7])};gu.adaptCorrect.prototype=new gu;gu.adaptCorrect.prototype.qa=function(w,n){var W=w.sdwM.v;
n[0]=W.Amnt.v.val;n[1]=W.Wdth.v.val;n[2]=W.Rds.v;var W=w.hglM.v;n[3]=W.Amnt.v.val;n[4]=W.Wdth.v.val;
n[5]=W.Rds.v;n[6]=w.ClrC.v};gu.adaptCorrect.prototype.EC=function(w,n){var W=w.sdwM.v;W.Amnt.v.val=n[0];
W.Wdth.v.val=n[1];W.Rds.v=n[2];var W=w.hglM.v;W.Amnt.v.val=n[3];W.Wdth.v.val=n[4];W.Rds.v=n[5];w.ClrC.v=n[6]};
gu.Flam=function(){gu.call(this,"Flam");var w=this.pE=[new i0([12,44],"One Flame Along Path,Multiple Flames Along Path,Multiple Flames One Direction,Multiple Flames Path Directed,Multiple Flames Various Angle,Candle Light".split(",")),new eu([12,80,0],20,1e3,"px"),new b7("Randomize Length"),new eu([12,41],5,600,"px"),new eu([12,15],0,360,"\xB0"),new eu("Interval",10,200,"px"),new b7("Adapt Interval for Loops"),new gM(!1),new i0([12,52,0],["1: Draft","2: Low","3: Medium","4: High","5: Fine"]),new eu("Turbulent",0,100),new eu("Jag",0,100),new eu([12,0],0,100),new eu("Lines",2,30),new eu("Bottom",0,100),new i0([12,22],["Normal","Violent","Flat"]),new i0([12,76,1],["Parallel","To the center","Spread","Oval","Pointing"]),new b7("Randomize Shape"),new eu("Random Seed",0,100)];
this.sk();var n=this.e;e._g(n);var W=new j$(null,["Basic","Advanced"]);W.h(b.E.A,this.a6D,this);n.appendChild(W.e);
e.R2(n);var D=e.t("div"),j=e.t("div");this.a6z=[D,j];n.appendChild(D);for(var L=0;L<w.length;L++){(L<9?D:j).appendChild(w[L].e);
if(L==6)e.x$(D)}w[0].h(b.E.A,this.ag0,this);this.ag0()};gu.Flam.prototype=new gu;gu.Flam.prototype.ag0=function(w){var n=this.pE,L=n[0].b();
n[1].G3(L!=0&&L!=5);n[2].G3(L!=0&&L!=5);n[4].G3(L!=0&&L!=5&&L!=1);n[5].G3(L!=0&&L!=5);n[6].G3(L!=0&&L!=5)};
gu.Flam.prototype.a6D=function(w){var L=w.target.b(),n=this.a6z,W=this.e;W.removeChild(n[1-L]);W.appendChild(n[L])};
gu.boxblur=function(){gu.call(this,"boxblur");this.pE=[new eu([12,56],1,200," px")];this.sk()};gu.boxblur.prototype=new gu;
gu.boxblur.prototype.qa=function(w,n){n[0]=w.Rds.v.val};gu.boxblur.prototype.EC=function(w,n){w.Rds.v.val=n[0]};
gu.GsnB=function(){gu.call(this,"GsnB");this.pE=[new eu([12,56],.1,400,"px",1,!0)];this.sk()};gu.GsnB.prototype=new gu;
gu.Dila=function(){gu.call(this,"Dila");this.pE=[new eu([11,12,1],0,20,"px",0),new eu([12,56],0,400,"px",0,!0)];
this.sk()};gu.Dila.prototype=new gu;gu.MtnB=function(){gu.call(this,"MtnB");this.pE=[new aA([12,15]),new eu([12,28],1,100," px")];
this.sk()};gu.MtnB.prototype=new gu;gu.RdlB=function(){gu.call(this,"RdlB");this.pE=[new eu([12,57],1,100),new j$([12,36],["Spin","Zoom"]),new eu("Position X",0,100,"%"),new eu("Position Y",0,100,"%")];
this.sk()};gu.RdlB.prototype=new gu;gu.RdlB.prototype.qa=function(w,n){n[0]=w.Amnt.v;n[1]=["Spn","Zm"].indexOf(w.BlrM.v.BlrM);
n[2]=w.Cntr.v.Hrzn.v*100;n[3]=w.Cntr.v.Vrtc.v*100};gu.RdlB.prototype.EC=function(w,n){w.Amnt.v=n[0];
w.BlrM.v.BlrM=["Spn","Zm"][n[1]];w.Cntr.v.Hrzn.v=n[2]/100;w.Cntr.v.Vrtc.v=n[3]/100};gu.agE(gu.RdlB.prototype);
gu.Dspl=function(){gu.call(this,"Dspl");this.pE=[new i0([6,36,3],["a","b"]),new eu([22,4,0],-100,100,"px"),new eu([22,4,1],-100,100,"px"),new i0([24,18,0],[[24,18,3],[24,18,2]])];
this.sk()};gu.Dspl.prototype=new gu;gu.Dspl.prototype.qa=function(w,n,W){this.akE=[];this.uL=[];var D=-1,j=W?W[0]:null;
if(j==null)j=this.a73;else this.a73=j;if(j)for(var L=0;L<j.length;L++){var I=j[L];this.akE.push(I.O7.trim());
this.uL.push(I.Z4);if(I.Z4==w.DspF.v.pth)D=L}this.pE[0].TF(this.akE);n[0]=D==-1?0:D;n[1]=w.HrzS.v;n[2]=w.VrtS.v;
n[3]=["WrpA","RptE"].indexOf(w.UndA.v.UndA)};gu.Dspl.prototype.EC=function(w,n){if(this.uL.length==0)return;
w.DspF.v.pth=this.uL[n[0]];w.HrzS.v=n[1];w.VrtS.v=n[2];w.UndA.v.UndA=["WrpA","RptE"][n[3]]};gu.Pnch=function(){gu.call(this,"Pnch");
this.pE=[new eu([12,57],-100,100,"%")];this.sk()};gu.Pnch.prototype=new gu;gu["Plr "]=function(){gu.call(this,"Plr ");
this.pE=[new j$(null,["Rect to Polar","Polar to Rect"])];this.sk()};gu["Plr "].prototype=new gu;gu.Rple=function(){gu.call(this,"Rple");
this.pE=[new eu([12,57],-999,999),new i0([12,14,0],[[19,8,0],[19,8,1],[19,8,2]])];this.sk()};gu.Rple.prototype=new gu;
gu["Shr "]=function(){gu.call(this,"Shr ");this.pE=[new dA(!0,!0),new i0([24,18,0],[[24,18,3],[24,18,2]])];
this.sk()};gu["Shr "].prototype=new gu;gu["Shr "].prototype.qa=function(w,n){var W=new eh(0,255/127,255/127,0,-2,128),D=JSON.parse(JSON.stringify(w.ShrP.v));
E.MU.D(D,W);n[0]=D;n[1]=["WrpA","RptE"].indexOf(w.UndA.v.UndA)};gu["Shr "].prototype.EC=function(w,n){var W=new eh(0,255/127,255/127,0,-2,128);
W.Ba();E.MU.D(n[0],W);w.ShrP.v=n[0];w.ShrE.v=n[0].length-1;w.UndA.v.UndA=["WrpA","RptE"][n[1]]};gu.Sphr=function(){gu.call(this,"Sphr");
this.pE=[new eu([12,57],-100,100),new i0([12,36],[[15,10,0],[22,4,0],[22,4,1]])];this.sk()};gu.Sphr.prototype=new gu;
gu.Sphr.prototype.qa=function(w,n){n[0]=w.Amnt.v;n[1]=["Nrml","HrzO","VrtO"].indexOf(w.SphM.v.SphM)};
gu.Sphr.prototype.EC=function(w,n){w.Amnt.v=n[0];w.SphM.v.SphM=["Nrml","HrzO","VrtO"][n[1]]};gu.Dthr=function(){gu.call(this,"Dthr");
this.pE=[new i0("Palette",[[4,7],"RGB 2x2x2","RGB 4x4x4","RGB 8x8x4"]),new j$("Method",["None","Floyd-Steinberg","Bayer 4x4"])];
this.sk()};gu.Dthr.prototype=new gu;gu.Dthr.prototype.qa=function(w,n){n[0]=w.Plte.v;n[1]=w.Mthd?w.Mthd.v:1};
gu.Dthr.prototype.EC=function(w,n){w.Plte.v=n[0];w.Mthd.v=n[1]};gu.Part=function(){gu.call(this,"Part");
this.pE=[new eu([15,5,1],0,100,"%"),new eu([12,14,0],1,50,"px"),new eu([12,34],0,100,"%"),new eu([12,2],10,1e3,"%"),new gM(!0),new eu("Time",0,1,null,3),new eu("Turbulence",0,100,"%"),new b7("Blink"),new b7("Fall")];
this.sk([4])};gu.Part.prototype=new gu;gu.Part.prototype.qa=function(w,n){n[0]=w.Cont.v;n[1]=w.Size.v;
n[2]=w.Dpth.v;n[3]=w.Brgh.v;n[4]=w.Clr.v;n[5]=w.Time.v;n[6]=w.Turb.v;n[7]=w.Blnk.v;n[8]=w.Fall.v};gu.Part.prototype.EC=function(w,n){w.Cont.v=n[0];
w.Size.v=n[1];w.Dpth.v=n[2];w.Brgh.v=n[3];w.Clr.v=n[4];w.Time.v=n[5];w.Turb.v=n[6];w.Blnk.v=n[7];w.Fall.v=n[8]};
gu.Twrl=function(){gu.call(this,"Twrl");this.pE=[new eu([12,15],-999,999)];this.sk()};gu.Twrl.prototype=new gu;
gu.Wave=function(){gu.call(this,"Wave");this.a2V=[1,2,3,4];this.pE=[new eu("Number of Generators",1,100),new f2("Min Length",1,999),new f2("Max Length",1,999),new f2("Min Ampl.",1,999),new f2("Max Ampl.",1,999),new f2("Scale X",1,100,"%"),new f2("Scale Y",1,100,"%"),new j$([12,44],["Sine","Triangle",[12,93,3]]),new i0([24,18,0],[[24,18,3],[24,18,2]])];
this.sk()};gu.Wave.prototype=new gu;gu.ZgZg=function(){gu.call(this,"ZgZg");this.pE=[new eu([12,57],-100,100),new eu("Ridges",0,20),new i0([12,22],["Around Center","Out From Center","Pond Ripples"])];
this.sk()};gu.ZgZg.prototype=new gu;gu.surfaceBlur=function(){gu.call(this,"surfaceBlur");this.pE=[new eu([12,56],1,200," px"),new eu([4,13],1,255," px")];
this.sk()};gu.surfaceBlur.prototype=new gu;gu.surfaceBlur.prototype.qa=function(w,n){n[0]=w.Rds.v.val;
n[1]=w.Thsh.v};gu.surfaceBlur.prototype.EC=function(w,n){w.Rds.v.val=n[0];w.Thsh.v=n[1]};gu.AdNs=function(){gu.call(this,"AdNs");
this.pE=[new eu([12,57],0,200," %"),new i0([12,58],[[12,59,1],[12,59,0]]),new b7([12,60])];this.sk()};
gu.AdNs.prototype=new gu;gu.DstS=function(){gu.call(this,"DstS");this.pE=[new eu([12,56],1,200," px"),new eu([4,13],1,255," px")];
this.sk()};gu.DstS.prototype=new gu;gu["Mdn "]=function(){gu.call(this,"Mdn ");this.pE=[new eu([12,56],1,200," px")];
this.sk()};gu["Mdn "].prototype=new gu;gu["Mdn "].prototype.qa=function(w,n){n[0]=w.Rds.v.val};gu["Mdn "].prototype.EC=function(w,n){w.Rds.v.val=n[0]};
gu.ClrH=function(){gu.call(this,"ClrH");this.pE=[new eu([12,56],4,100," px")];for(var L=1;L<4;L++)this.pE.push(new eu("Angle "+L,0,90," \xB0"));
this.sk()};gu.ClrH.prototype=new gu;gu.ClrH.prototype.qa=function(w,n){n[0]=w.Rds.v;for(var L=1;L<4;
L++)n[L]=w["Ang"+L].v};gu.ClrH.prototype.EC=function(w,n){w.Rds.v=n[0];for(var L=1;L<4;L++)w["Ang"+L].v=n[L]};
gu.ClrH.prototype.f=function(){var w=this.pE;w[0].f();for(var L=1;L<4;L++)w[L].wV(fV.get([12,15])+" "+L)};
gu.Crst=function(){gu.call(this,"Crst");this.pE=[new eu([12,61],3,100," px")];this.sk()};gu.Crst.prototype=new gu;
gu.Crst.prototype.qa=function(w,n){n[0]=w.ClSz.v};gu.Crst.prototype.EC=function(w,n){w.ClSz.v=n[0]};
gu.Mztn=function(){gu.call(this,"Mztn");this.pE.push(new i0([12,44],"Fine Dots,Medium Dots,Grainy Dots,Coarse Dots,Short Lines,Medium Lines,Long Lines,Short Strokes,Medium Strokes,Long Strokes".split(","),[4,3,3]));
this.uL="FnDt MdmD GrnD CrsD ShrL MdmL LngL ShSt MdmS LngS".split(" ");this.sk()};gu.Mztn.prototype=new gu;
gu.Mztn.prototype.qa=function(w,n){n[0]=this.uL.indexOf(w.MztT.v.MztT)};gu.Mztn.prototype.EC=function(w,n){w.MztT.v.MztT=this.uL[n[0]]};
gu["Msc "]=function(){gu.call(this,"Msc ");this.pE=[new eu([12,61],2,200," px")];this.sk()};gu["Msc "].prototype=new gu;
gu["Msc "].prototype.qa=function(w,n){n[0]=w.ClSz.v.val};gu["Msc "].prototype.EC=function(w,n){w.ClSz.v.val=n[0]};
gu.Pntl=function(){gu.call(this,"Pntl");this.pE=[new eu([12,61],3,100," px")];this.sk()};gu.Pntl.prototype=new gu;
gu.Pntl.prototype.qa=function(w,n){n[0]=w.ClSz.v};gu.Pntl.prototype.EC=function(w,n){w.ClSz.v=n[0]};
gu.smartSharpen=function(){gu.call(this,"smartSharpen");this.pE=[new eu([12,57],1,200,"%"),new eu([12,56],0,200,"px",1,!0)];
this.sk()};gu.smartSharpen.prototype=new gu;gu.smartSharpen.prototype.qa=function(w,n){n[0]=w.Amnt?w.Amnt.v.val:200;
n[1]=w.Rds?w.Rds.v.val:1};gu.smartSharpen.prototype.EC=function(w,n){w.Amnt.v.val=n[0];w.Rds.v.val=n[1]};
gu.UnsM=function(){gu.call(this,"UnsM");this.pE=[new eu([12,57],1,200," %"),new eu([12,56],.1,400,"px",1,!0),new eu([4,13],0,255," ")];
this.sk()};gu.UnsM.prototype=new gu;gu.HghP=function(){gu.call(this,"HghP");this.pE=[new eu([12,56],.1,400,"px",1,!0)];
this.sk()};gu.HghP.prototype=new gu;gu.HsbP=function(){gu.call(this,"HsbP");this.pE=[new j$("Input",["RGB","HSB","HSL"]),new j$("Output",["RGB","HSB","HSL"])];
this.sk()};gu.HsbP.prototype=new gu;gu["Mxm "]=function(){gu.call(this,"Mxm ");this.pE=[new eu([12,56],.1,200," px",1,!0),new i0([12,76,1],[[12,93,3],"Circle"])];
this.sk()};gu["Mxm "].prototype=new gu;gu["Mnm "]=function(){gu.call(this,"Mnm ");this.pE=[new eu([12,56],.1,200," px",1,!0),new i0([12,76,1],[[12,93,3],"Circle"])];
this.sk()};gu["Mnm "].prototype=new gu;gu.Ofst=function(){gu.call(this,"Ofst");this.pE=[new eu([22,4,0],-1024,1024," px"),new eu([22,4,1],-1024,1024," px"),new i0([24,18,0],[[24,18,2],[24,18,1],[24,18,3]])];
this.sk()};gu.Ofst.prototype=new gu;gu.Kale=function(){gu.call(this,"Kale");this.pE=[new f2("Mirrors",2,20),new f2([12,15],0,360,"\xB0")];
this.sk()};gu.Kale.prototype=new gu;gu.Kale.prototype.qa=function(w,n){n[0]=w.Mirr.v;n[1]=w.MRot.v};
gu.Kale.prototype.EC=function(w,n){w.Mirr.v=n[0];w.MRot.v=n[1]};gu.Rept=function(){gu.call(this,"Rept");
this.pE=[new f2([12,38],1,300," %"),new f2("Row Shift",-50,50," %"),new f2("Space X",-99,200," %"),new f2("Space Y",-99,200," %"),new b7([4,16,2]),new aA([12,15])];
this.sk()};gu.Rept.prototype=new gu;gu.Rept.prototype.qa=function(w,n){n[0]=w.Scl.v.val;n[1]=w.Rsft.v.val;
n[2]=w.SpcX.v.val;n[3]=w.SpcY.v.val;n[4]=w.SpcC.v;n[5]=[w.Angl.v]};gu.Rept.prototype.EC=function(w,n){w.Scl.v.val=n[0];
w.Rsft.v.val=n[1];w.SpcX.v.val=n[2];w.SpcY.v.val=n[3];w.SpcC.v=n[4];w.Angl.v=n[5][0];return w};gu.Ctoa=function(){gu.call(this,"Ctoa");
this.pE=[new ga([13,0]),new gM(!0),new eu(["VAR0 VAR1","Transparency",[4,13]],0,100," %"),new eu(["VAR0 VAR1",[12,0],[4,13]],0,100," %")];
this.sk()};gu.Ctoa.prototype=new gu;gu.Ctoa.prototype.qa=function(w,n){n[0]=w.Clr.v;n[1]=w.Trsp.v.val;
n[2]=w.Opct.v.val};gu.Ctoa.prototype.EC=function(w,n){w.Clr.v=n[0];w.Trsp.v.val=n[1];w.Opct.v.val=n[2]};
gu.LqFy=function(){gu.call(this,"LqFy");this.TC=!1;this.XJ=!1;this.gC=null;this.aq4=null;this.G=0;this.Bq=-1;
this.a={Bu:[[{G:{id:0,name:[24,1,0,1,0],GH:"liq/smudge"}}],[{G:{id:1,name:[24,1,0,1,1],GH:"liq/reconstruct"}}],[{G:{id:2,name:[24,1,0,1,2],GH:"liq/smooth"}}],[{G:{id:3,name:[24,1,0,1,3],GH:"liq/twirl"}}],[{G:{id:4,name:[24,1,0,1,4],GH:"liq/shrink"}}],[{G:{id:5,name:[24,1,0,1,5],GH:"liq/blow"}}],[{G:{id:6,name:[24,1,0,1,6],GH:"liq/pleft"}}],[{G:{id:7,name:"Hand",GH:"tools/hand"}}],[{G:{id:8,name:"Zoom In",GH:"zoomIn"}}],[{G:{id:9,name:"Zoom Out",GH:"zoomOut"}}]],keys:[]};
this.GX=new gP(this.a,!1);this.GX.Ct(0);this.GX.h(b.E.L,this.adH,this);this.Ff=bj.os();this._C=null;
this.c5=[];this.S3=-1;this.gl=null;this.arO=null;this.ST=null;this.Ix=null;this.It=null;var w=e.t("div","flexrow");
this.yd=w;this.e.appendChild(w);w.appendChild(this.GX.e);this.view=new hL(!0);this.view.zl(100,100);
this.view.h("mousedown",this.jx,this);this.view.h("mousemove",this.Gi,this);this.view.h("mouseup",this.WB,this);
this.view.h("zoom",this.eg,this);w.appendChild(this.view.e);var n=e.t("div","form");w.appendChild(n);
this.q3=n;n.style.width="230px";this.a0=[new eu([12,14,0],0,1e3,null,!1,!0),new eu([12,74],0,100,null,!1,!1),new eu([12,84],0,100,null,!1,!1),new b7([12,46]),new eu([12,0],0,100,null,!1,!1),new b7([24,18,5])];
var W=this.Ff.Brsh.v;W.Dmtr.v.val=100;var D=[100,50,100,!1,100,!0];for(var L=0;L<this.a0.length;L++){var j=this.a0[L];
j.$(D[L]);if(L==4)j.rx();j.h(b.E.A,this.a5t,this);n.appendChild(j.e)}var I=this.a96=new iP([1,12,2],!0,null,!0);
I.h("click",this.b0,this);n.appendChild(I.e);this.amB=this.Yr.bind(this);this.uT=new eg;this.uT.e=e.t("div","floatcont");
this.eW=new iP("Menu",!1,null,!0);var U=this.eW.e;U.setAttribute("style","position:absolute; right:13px; top:47px");
e.L_(U,this.atT.bind(this))};gu.LqFy.prototype=new gu;gu.LqFy.prototype.Fn=function(){return!0};gu.LqFy.prototype.$A=function(w){this.q3.appendChild(w)};
gu.LqFy.prototype.atT=function(w){if(e.LY(this.uT.e))return;w.stopPropagation();var n=this.eW.e.getBoundingClientRect();
this.uT.e.appendChild(this.q3);var W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:this.uT,x:n.right+n.width-290,y:n.top+n.height};
this.S(W)};gu.LqFy.prototype.oe=function(w){this.TC=w.U(aK.PJ);var n=y.JT.u_(this.Ff,w);if(n!=null){this.Ff=n;
this.eg();this.a0[0].$(n.Brsh.v.Dmtr.v.val)}else if(w.U(aK.CQ)&&w.U(aK.xD)){var W=this.c5;if(w.U(aK.WO)){if(this.S3+1<W.length)this.S3++}else if(this.S3>0)this.S3--;
this._C.map=W[this.S3].slice(0);this.Uc(null)}else if(this.G<=6)this.view.oe(w);var D=this.G,j=-1,I=w.U(aK.PJ);
if(I&&this.Bq==-1){if(D==0)j=1;if(D==4)j=5;if(D==5)j=4;if(j!=-1)this.Bq=D}if(!I&&this.Bq!=-1){j=this.Bq;
this.Bq=-1}if(j!=-1){this.G=j;this.GX.Ct(this.G)}};gu.LqFy.prototype.adH=function(w){if(w.data.d==b.c.CV){var n=this.G=w.data.G;
this.GX.Ct(this.G);this.view.oe(n>6?hL.acD(n-7):new aK)}};gu.LqFy.prototype.a5t=function(w){var n=w.currentTarget,L=this.a0.indexOf(n),W=this.Ff.Brsh.v;
if(L==0){W.Dmtr.v.val=n.b();this.eg()}this.a0[4].G3(this.a0[3].b());if(L>2)this.Uc(null)};gu.LqFy.prototype._n=function(){var w=this.c5;
this.S3++;w[this.S3]=this._C.map.slice(0);while(w.length>this.S3+1)w.pop();while(w.length>50){w=w.slice(1);
this.S3--}};gu.LqFy.prototype.jx=function(w){this.gC=this.view.PD();this.aq4=new ec(0,0);this.XJ=!0;
window.requestAnimationFrame(this.amB)};gu.LqFy.prototype.Gi=function(w){var n=this.view.PD(),W=new ec(n.x-this.gC.x,n.y-this.gC.y);
if(this.G==0||this.G==6)this.aib(W);this.gC=n};gu.LqFy.prototype.WB=function(w){this._n();this.XJ=!1};
gu.LqFy.prototype.Yr=function(w){if(this.G!=0&&this.G!=6)this.aib(new ec(0,0));if(this.XJ)window.requestAnimationFrame(this.amB)};
gu.LqFy.prototype.aib=function(w){var n=this._C,W=n.gA/this.gl.m,D=this.gC,j=this.Ff.Brsh.v,I=j.Dmtr.v.val,U=Date.now(),M=n.gA,m=n.ag,l=Math.sqrt(w.x*w.x+w.y*w.y),A=Math.max(1,Math.ceil(l/2)),g=w.x/A,k=w.y/A,$=D.clone(),C=this.G,f=this.a0[1].b()/100,z=this.a0[2].b()/100,s=[.005,.015,0,0,.2,.2,.01,.01,.05,.35,.1,.1,.005,.015],O=s[C*2],a=s[C*2+1],X=(1-f)*O+f*a,P=I*W/2;
for(var L=0;L<A;L++){var Z=[];$.x+=g;$.y+=k;E.wH.a9Y(n.map,M,m,C,$.x*W,$.y*W,P,f,z,g*W,k*W,Z,this.TC);
E.wH.a7O(M,m,n.map,Z,2*X*z)}var Y=new iB(0,0,M,m),K=new iB(D.x*W,D.y*W,0,0);K.VD(I*W*.5,I*W*.5);var S=K.clone();
S.offset(w.x*W,w.y*W);K=K.x0(S);var G=new iB(K.x/W,K.y/W,K.m/W,K.n/W);G=E.p.fF(G).wU(this.gl);this.a0[5].$(!0);
this.Uc(G)};gu.LqFy.prototype.eg=function(){var w=iV.QM(this.Ff,null,this.view.T3().N);this.view.$J(w)};
gu.LqFy.prototype.$=function(w,n,W,D,j){W=W.clone();if(n==null)return;if(!D.s9(W)){var I=W.x0(D),U=E.Q(I.O()*4);
E.Cb(n,W,U,I);n=U;W=I;var M=E.Q(I.O()*4);E.Cb(j,D,M,I);j=M}W.x=W.y=0;this.ST=n;this.arO=j;this.It=n.slice(0);
this.Ix=n.slice(0);this.gl=W;this._C=fH.ew(new Uint8Array(w.LqMe.v).buffer);var m=W.m,l=W.n;if(this._C.gA/m<.22){this._C={gA:Math.floor(m/4),ag:Math.floor(l/4)};
this._C.map=new Float32Array(this._C.gA*this._C.ag*2)}this.c5=[];this.S3=-1;this._n();this.Uc(null);
this.view.bP();this.eg()};gu.LqFy.prototype.b=function(){var w=cx._1("LqFy"),n=new Uint8Array(fH.Pj(this._C)),W=[];
for(var L=0;L<n.length;L++)W.push(n[L]);w.LqMe.v=W;return w};gu.LqFy.prototype.zl=function(w,n){this.GX.zl(w,n);
var W=this.eW.e,D=this.q3;this.yd.appendChild(D);this.yd.appendChild(W);if(w>450&&w-n>200){D.style.marginLeft="1em";
this.yd.removeChild(W);this.view.zl(w-238-45,n)}else{D.style.marginLeft="";this.yd.removeChild(D);this.view.zl(w-40,n)}};
gu.LqFy.prototype.f=function(){this.GX.f();this.a96.f();for(var L=0;L<this.a0.length;L++)this.a0[L].f()};
gu.LqFy.prototype.b0=function(){this._C.map.fill(0);this._n();this.Uc(null)};gu.LqFy.prototype.Uc=function(w){var n=this.gl,W=this.ST,D=this.It,j=this._C;
if(this.a0[5].b())E.wH.U$(W,this.Ix,n.m,n.n,w,j.map,j.gA,j.ag,0);else this.Ix.set(W);if(this.a0[3].zr()){E.Cb(this.arO,n,D,n,w?w:n);
E.s._U("norm",this.Ix,n,D,n,w?w:n,this.a0[4].b()/100)}else E.nX(this.Ix,D);this.view.$([{XL:n,data:D.buffer}])};
gu.GEfc=function(){gu.call(this,"GEfc");this.s1=0;this.w_=0;this.ST=null;this.It=null;this.gl=null;this.ww=null;
this.KP=null;this.JX=0;var w=e.t("div","flexrow");this.yd=w;this.e.appendChild(w);this.view=new hL(null);
this.view.zl(100,100);w.appendChild(this.view.e);this.DM="";this.Ep=270;var n=this.I_=e.t("div","form scrollable");
w.appendChild(n);n.setAttribute("style","width:"+this.Ep+"px;");var W=this.KC=e.t("div","form");w.appendChild(W);
W.setAttribute("style","width:230px; margin:0 10px");this.JI={};for(var D in ic.names){var j=new gu.GEfc.vb(D);
j.parent=this;this.JI[D]=j;j.h(b.E.A,this.aAJ,this)}this.qM=!0;this.eW=new iP("Menu",null,null,!0);this.eW.h("click",this.a4a,this);
w.appendChild(this.eW.e);this.Kj=new iP(">>",null,null,!0);this.Kj.h("click",this.acM,this);W.appendChild(this.Kj.e);
this.Sb=e.t("div");this.Sb.setAttribute("style","margin-bottom:1.5em; display:inline-block; width:calc(100% - 40px);");
W.appendChild(this.Sb);this.$a=e.t("div");this.$a.style.minHeight="14em";this.$a.style.marginBottom="1em";
W.appendChild(this.$a);this.cw=e.t("div","lpbody scrollable");this.jU=e.t("div","lpfoot");W.appendChild(this.cw);
W.appendChild(this.jU);this.h("click",this.an5,this);this.av=[];bg.$l([[5,3],[5,4]],this.av,this.jU,this.eN.bind(this))};
gu.GEfc.prototype=new gu;gu.GEfc.prototype.Fn=function(){return!0};gu.GEfc.prototype.$A=function(w){this.Sb.appendChild(w)};
gu.GEfc.prototype.GZ=function(w,n){this.ww=w};gu.GEfc.prototype.acM=function(w){var n=this.I_.style.display!="none";
this.I_.style.display=n?"none":"";this.Kj.wV(n?"<<":">>");this.zl()};gu.GEfc.prototype.a4a=function(w){this.qM=!this.qM;
this.zl()};gu.GEfc.prototype.zl=function(w,n){var W=this.I_.style.display!="none";if(w!=null){this.s1=w;
this.w_=n;if(w<1e3&&W||w>=1e3&&!W){this.acM();W=!W}this.qM=w>600}else{w=this.s1;n=this.w_}var D=this.qM?240+(W?this.Ep+10:0):0;
if(e.LY(this.KC)&&!this.qM){this.yd.removeChild(this.I_);this.yd.removeChild(this.KC)}if(!e.LY(this.KC)&&this.qM){this.yd.appendChild(this.I_);
this.yd.appendChild(this.KC)}this.I_.style.height=n+"px";this.view.zl(w-D,n);this.cw.style.height=n-Math.max(this.$a.getBoundingClientRect().height,186)-96+"px";
this.eW.e.setAttribute("style","position:absolute; top:46px; right:"+(D+16)+"px")};gu.GEfc.prototype.aym=function(){var w=jj.gF.get("img/beach",!0)[0],n=w.XL,W=this.I_,D=Math.floor(e.V()*(this.Ep-40)/3),j=~~(D*.7),I=new iB(0,0,D,j),U=E.Q(D*j*4),M=U.slice(0),m=Math.round(10*e.V()),l=new ImageData(new Uint8ClampedArray(M.buffer),D,j);
E.Cb(new Uint8Array(w.data),n,U,new iB(Math.round((n.m-D)/2),Math.round((n.n-j)/2),D,j));var A=e.t("canvas"),g=A.getContext("2d");
A.width=D;A.height=j+Math.round(m*1.5);g.font=m+"px sans-serif";this.JK={};var k=this.ajm.bind(this);
for(var L=0;L<ic.ie.length;L++){var $=ic.ie[L],C=e.t("div");W.appendChild(C);C.setAttribute("style","background-color:rgba(0,0,0,0.2); padding:0px 8px; margin-bottom:8px");
C.textContent=fV.get($);for(var f in ic.names){var z=ic.names[f];if(z[0]!=L)continue;ic.Ld(f,{rect:I,buffer:U},ic._1(f),{o:0,B:0,k:0},{o:255,B:255,k:255},{rect:I,buffer:M},{});
g.fillStyle="black";g.fillRect(0,0,500,500);g.putImageData(l,0,0);var s=fV.get(z[1]);g.fillStyle="white";
g.fillText(s,(D-g.measureText(s).width)/2,j+Math.round(m*1.1));var O=e.t("div");W.appendChild(O);O.setAttribute("style","display:inline-block; cursor:pointer; padding: 5px 5px 0 5px; margin-bottom:5px");
O.addEventListener("click",k,!1);var C=e.t("img");O.appendChild(C);C.setAttribute("src",A.toDataURL());
C.setAttribute("style","width:"+D/e.V()+"px; margin-bottom:0px;");this.JK[f]=O}}};gu.GEfc.prototype.ajm=function(w){var n;
for(var W in this.JK)if(this.JK[W]==w.currentTarget)this.DM=W;this.aAJ()};gu.GEfc.prototype.eN=function(w){var n=bg.Xd(this.av,w),W=this.KP.GEfs.v,D=W[this.JX].v;
if(n==0){W.push(JSON.parse(JSON.stringify(W[this.JX])));this.JX=W.length-1}else if(W.length>1){W.splice(this.JX,1);
if(this.JX==W.length)this.JX--}this._s();this.Uc()};gu.GEfc.prototype.aAJ=function(w){var n=this.DM,W;
if(w==null)W=ic._1(n);else W=this.JI[n].b();this.KP.GEfs.v[this.JX].v=W;this._s();this.Uc()};gu.GEfc.prototype.$=function(w,n,W,D,j){if(this.JK==null)this.aym();
w=this.KP=JSON.parse(JSON.stringify(w));if(w.GEfs==null)w=this.KP={__name:"Filter Gallery",classID:"GEfc",GEfs:{t:"VlLs",v:[{t:"Objc",v:w}]}};
var I=w.GEfs.v;for(var L=0;L<I.length;L++)if(I[L].v.GELv==null)I[L].v.GELv={t:"bool",v:!0};this.JX=I.length-1;
this._s();W=W.clone();if(n==null)return;if(!D.s9(W)&&ic.R5(w).x!=0){var U=W.x0(D),M=E.Q(U.O()*4);E.Cb(n,W,M,U);
n=M;W=U}W.x=W.y=0;this.ST=n;this.It=n.slice(0);this.gl=W;this.Uc();this.view.bP()};gu.GEfc.prototype.an5=function(w){var n=w.data,L=n.p_,W=this.KP.GEfs.v;
if(n.LG){W[L].v.GELv.v=!W[L].v.GELv.v;this.Uc()}else this.JX=L;this._s()};gu.GEfc.prototype._s=function(){var w=this.KP.GEfs.v,n=w[this.JX].v,W=n.GEfk.v.GEft,D=this.$a;
if(ic.names[W]==null){alert("Unsupported gallery filter");e._g(D)}else{this.DM=W;for(var j in this.JK)e.IX(this.JK[j],"selected");
e.W0(this.JK[W],"selected");var I=this.JI[W];I.$(n);if(D.firstChild!=I.e){e._g(D);D.appendChild(I.e)}}var U=[];
for(var L=0;L<w.length;L++){var M=w[L].v,m=ic.names[M.GEfk.v.GEft],l=new ev(L,!0,!0,null,m?m[1]:"Filter",L==this.JX,M.GELv.v);
l.parent=this;U.push(l.e)}e._g(this.cw);U.reverse();for(var L=0;L<U.length;L++)this.cw.appendChild(U[L]);
this.zl()};gu.GEfc.prototype.b=function(){return JSON.parse(JSON.stringify(this.KP))};gu.GEfc.prototype.Uc=function(w){var n=this.gl,W=this.ST,D=this.It,j=this.DM,I=this.KP,U=this.ww;
function M(m){return{o:m>>>16,B:m>>>8&255,k:m&255}}cx.Ld("GEfc",{rect:this.gl,buffer:this.ST},I,M(U.Gp),M(U.as),{rect:this.gl,buffer:this.It},null);
this.view.$([{XL:n,data:D.buffer}])};gu.GEfc.prototype.f=function(){for(var w in this.JI)this.JI[w].f();
bg.h5(this.av,["lrs/newlayer","lrs/bin"])};gu.GEfc.vb=function(w){eg.call(this);this.W_=w;this.e=e.t("div");
this.SE={};var n=ic._1(w);for(var W in n){var D=null;if(W=="__name"||W=="classID"||W=="GEfk"||W=="GELv"||["FlRs"].indexOf(W)!=-1)continue;
else if(W=="EdgW")D=new eu("Edge Width",1,14);else if(W=="EdgB")D=new eu("Edge Brightness",0,w=="AccE"?50:20);
else if(W=="Smth")D=new eu([19,3,3],1,w=="Stmp"?50:15);else if(W=="ClSz")D=new eu([12,61],3,100);else if(W=="BrdT")D=new eu([7,9],1,20);
else if(W=="HghS")D=new eu([12,64],0,20);else if(W=="HlSz")D=new eu([12,14,0],1,15);else if(W=="Cntr")D=new eu([12,3,0],0,w=="WtrP"?100:50);
else if(W=="Shrp")D=new eu("Sharpness",0,40);else if(W=="SprR")D=new eu("Spray Radius",0,25);else if(W=="LgDr")D=new eu("Light/Dark Balance",0,w=="Stmp"?50:100);
else if(W=="Drkn")D=new eu("Darkness",1,50);else if(W=="Dstr")D=new eu("Distortion",0,20);else if(W=="Scln")D=new eu([12,38],50,200);
else if(W=="Rlf")D=new eu("Relief",0,w=="Ptch"||w=="NtPr"?25:50);else if(W=="ChAm")D=new eu("Thickness",1,7);
else if(W=="Pncl")D=new eu([19,2,5],1,30);else if(W=="StrP")D=new eu("Stroke Pressure",0,15);else if(W=="PprB")D=new eu("Paper Brightness",0,50);
else if(W=="BrsS")D=new eu("Brush Size",0,10);else if(W=="BrsD")D=new eu("Brush Detail",0,10);else if(W=="Txtr")D=new eu([12,67],1,3);
else if(W=="Grn")D=new eu("Grain",0,20);else if(W=="HghA")D=new eu("Highlight Area",0,20);else if(W=="Intn")D=new eu("Intensity",0,10);
else if(W=="Brgh")D=new eu("Glow Brightness",0,w=="WtrP"?100:50);else if(W=="StrS")D=new eu("Stroke Size",1,50);
else if(W=="StDt")D=new eu("Stroke Detail",1,3);else if(W=="Sftn")D=new eu("Softness",0,10);else if(W=="EdgT")D=new eu("Edge Thickness",0,10);
else if(W=="EdgI")D=new eu("Edge Intensity",0,10);else if(W=="Pstr")D=new eu("Posterization",0,6);else if(W=="Dfnt")D=new eu("Definition",0,25);
else if(W=="TxtC")D=new eu("Texture Coverage",0,50);else if(W=="ShdI")D=new eu("Shadow Intensity",0,10);
else if(W=="DrcB")D=new eu("Direction Balance",0,100);else if(W=="Strg")D=new eu([12,64],1,3);else if(W=="Blnc")D=new eu("Balance",0,10);
else if(W=="BlcI")D=new eu("Black Intensity",0,10);else if(W=="WhtI")D=new eu("White Intensity",0,10);
else if(W=="DrkI")D=new eu("Dark Intensity",0,50);else if(W=="LghI")D=new eu("Light Intensity",0,50);
else if(W=="StrW")D=new eu("Stroke Width",3,15);else if(W=="Grns")D=new eu("Graininess",0,w=="NtPr"?20:10);
else if(W=="GlwA")D=new eu("Glow Amount",0,20);else if(W=="ClrA")D=new eu("Clear Amount",0,20);else if(W=="ChrA")D=new eu("Charcoal Area",0,20);
else if(W=="ChlA")D=new eu("Chalk Area",0,20);else if(W=="FrgL")D=new eu("Foreground Level",1,15);else if(W=="BckL")D=new eu("Background Level",1,15);
else if(W=="WhtL")D=new eu("Background Level",0,50);else if(W=="BlcL")D=new eu("Foreground Level",0,50);
else if(W=="ImgB")D=new eu("Image Balance",0,50);else if(W=="Dnst")D=new eu([12,74],0,50);else if(W=="FbrL")D=new eu("Fiber Length",3,50);
else if(W=="CrcS")D=new eu("Crack Sapcing",2,100);else if(W=="CrcD")D=new eu("Crack Depth",0,10);else if(W=="CrcB")D=new eu("Crack Brightness",0,10);
else if(W=="TlSz")D=new eu("Tile Size",2,100);else if(W=="GrtW")D=new eu("Grout Width",1,15);else if(W=="LghG")D=new eu("Lighten Grout",0,10);
else if(W=="SqrS")D=new eu("Square Size",0,10);else if(W=="RplS")D=new eu("Ripple Size",1,15);else if(W=="RplM")D=new eu("Ripple Magnitude",0,20);
else if(W=="NmbL")D=new eu("Number of Levels",2,8);else if(W=="EdgS")D=new eu("Edge Simplicity",0,10);
else if(W=="EdgF")D=new eu("Edge Fidelity",1,3);else if(W=="Sz")D=w=="NGlw"?new eu("Glow Size",-24,24):new eu("Brush Size",1,50);
else if(W=="Dtl")D=w=="Chrc"?new eu("Detail",0,5):new eu("Detail",1,15);else if(W=="StrL")D=w=="InkO"?new eu("Stroke Length",1,50):new eu("Stroke Length",0,20);
else if(W=="TxtT")D=new i0([12,67],"Blocks,Canvas,Frosted,Tiny Lens,Bricks,Burlap,Sandstone".split(","));
else if(W=="BrsT")D=new i0("Brush Type","Simple,Light Rough,Dark Rough,Wide Sharp,Wide Blurry,Sparkle".split(","));
else if(W=="Grnt")D=new i0("Grain Type","Regular Soft Sprinkles Clumped Contrasty Enlarged Stippled Horizontal Vertical Speckle".split(" "));
else if(W=="SDir")D=new i0([12,33],["Right Diagonal","Horizontal","Left Diagonal","Vertical"]);else if(W=="ScrT")D=new i0([12,62],["Circle","Dot",[10,35]]);
else if(W=="LghD"||W=="LghP")D=new i0("Light","Bottom,Bottom Left,Left,Top Left,Top,Top Right,Right,Bottom Right".split(","));
else if(W=="Clr")D=new gM("Glow Color");else if(W=="InvT")D=new b7([4,11]);else console.log(W);D.h(b.E.A,this.bX,this);
D.parent=this;this.SE[W]=D;this.e.appendChild(D.e)}};gu.GEfc.vb.prototype=new eg;gu.GEfc.vb.prototype.bX=function(w){this.S(new ed(b.E.A,!1))};
gu.GEfc.agL="Sz Dtl Shrp EdgW EdgB Smth ClSz BrdT HghS HlSz Cntr SprR StrL LgDr Drkn Dstr Scln Rlf ChAm InvT RplS RplM Pncl StrP PprB BrsS BrsD Txtr Grn HghA Intn Brgh Clr StrS StDt Sftn EdgT EdgI Pstr Dfnt TxtC ShdI DrcB Strg Blnc BlcI WhtI DrkI LghI StrW Grns GlwA ClrA ChrA ChlA FrgL BckL WhtL BlcL ImgB Dnst FbrL CrcS CrcD CrcB TlSz GrtW LghG SqrS NmbL EdgS EdgF".split(" ");
gu.GEfc.vb.prototype.$=function(w){for(var n in this.SE){var W;if(gu.GEfc.agL.indexOf(n)!=-1)W=w[n].v;
else if(n=="TxtT")W=ic.zR.indexOf(w[n].v[n]);else if(n=="BrsT")W=ic.aAE.indexOf(w[n].v[n]);else if(n=="LghD")W=ic.NQ.indexOf(w[n].v[n]);
else if(n=="LghP")W=ic.Ij.indexOf(w[n].v[n]);else if(n=="Grnt")W=ic.kl.indexOf(w[n].v[n]);else if(n=="ScrT")W=ic.Pm.indexOf(w[n].v[n]);
else if(n=="SDir")W=ic.Uk.indexOf(w[n].v.StrD);this.SE[n].$(W)}};gu.GEfc.vb.prototype.b=function(){var w=ic._1(this.W_);
for(var n in this.SE){var W=this.SE[n].b();if(gu.GEfc.agL.indexOf(n)!=-1)w[n].v=W;else if(n=="TxtT")w[n].v[n]=ic.zR[W];
else if(n=="BrsT")w[n].v[n]=ic.aAE[W];else if(n=="LghD")w[n].v[n]=ic.NQ[W];else if(n=="LghP")w[n].v[n]=ic.Ij[W];
else if(n=="Grnt")w[n].v[n]=ic.kl[W];else if(n=="ScrT")w[n].v[n]=ic.Pm[W];else if(n=="SDir")w[n].v.StrD=ic.Uk[W]}return w};
gu.GEfc.vb.prototype.f=function(){for(var w in this.SE)this.SE[w].f()};gu["Adobe Camera Raw Filter"]=function(w){gu.call(this,"Adobe Camera Raw Filter");
var n=this.e;this.agK=w;this.J1=null;this.Df=null;this.YH=null;e.W0(n,"flexrow");var W=e.t("div"),D=e.t("div","padded");
n.appendChild(W);n.appendChild(D);this.AD=new hL;W.appendChild(this.AD.e);this.mA=new dJ(225);this.mA.h8(4);
D.appendChild(this.mA.e);this.xG=e.t("div");this.xG.setAttribute("style","width:18em;");D.appendChild(this.xG);
this.alw=new ga("Hi",!0);this.xG.appendChild(this.alw.e);this.lC=e.t("div","scrollable");this.xG.appendChild(this.lC);
this.SE=[new eu("Temperature",-100,100),new eu("Tint",-100,100),new eu([4,3],-4,4,null,!0),new eu([12,3,0],-100,100),new eu([4,4],-100,100),new eu([12,9],-100,100)];
this.Jg="Temp Tint Ex12 Cr12 Vibr Strt".split(" ");for(var L=0;L<this.SE.length;L++){var j=this.SE[L];
j.$(0);j.h(b.E.A,this.Uc,this);this.lC.appendChild(j.e);if(L==1||L==3)this.lC.appendChild(e.t("hr"))}};
gu["Adobe Camera Raw Filter"].prototype=new gu;gu["Adobe Camera Raw Filter"].prototype.Fn=function(){return!0};
gu["Adobe Camera Raw Filter"].prototype.$A=function(w){this.xG.appendChild(w)};gu["Adobe Camera Raw Filter"].prototype.GZ=function(w,n){this.mA.hR(hp.fX[w.SI]["--text-color"])};
gu["Adobe Camera Raw Filter"].prototype.$=function(w,n,W,D,j){this.KP=w;var I=W.m,U=W.n,M=I*U;this.alw.$(I+" x "+U+", "+(I*U/1e6).toFixed(1)+" MPx");
this.gl=W;this.Df=new Float32Array(I*U*3);this.YH=new Uint8Array(I*U*4);this.YH.fill(255);if(n instanceof Float32Array)this.J1=n;
else{var m=this.J1=new Float32Array(I*U*3);for(var L=0;L<M;L++){var l=L*3,A=L*4;m[l+0]=n[A+0]*(1/255);
m[l+1]=n[A+1]*(1/255);m[l+2]=n[A+2]*(1/255)}}var g=this.Jg;for(var L=0;L<g.length;L++){var k=g[L];this.SE[L].$(w[k]?w[k].v:0)}this.Uc(null,!0)};
gu["Adobe Camera Raw Filter"].prototype.b=function(w){if(w)return this.YH;return JSON.parse(JSON.stringify(this.KP))};
gu["Adobe Camera Raw Filter"].prototype.adp=function(){this.J1=null;this.Df=null;this.YH=null};gu["Adobe Camera Raw Filter"].prototype.Uc=function(w,n){var W=this.Jg;
for(var L=0;L<W.length;L++){var D=W[L];this.KP[D]={t:D=="Ex12"?"doub":"long",v:this.SE[L].b()}}var j=this.gl,I=j.O();
hP(this.J1,j.m,j.n,this.Df,this.KP,this.agK);var U=Date.now(),M=this.Df,m=this.YH;for(var L=0;L<I;L++){var l=L*3,A=L*4;
m[A+0]=~~(.5+M[l+0]*255);m[A+1]=~~(.5+M[l+1]*255);m[A+2]=~~(.5+M[l+2]*255)}console.log(Date.now()-U,"integer conversion");
U=Date.now();var g=E.Bk(m,Math.max(1,Math.floor(I/2e5)));this.mA.$(g);console.log(Date.now()-U,"histogram done");
U=Date.now();this.AD.$([{XL:j,data:m.buffer}]);if(n)this.AD.bP()};gu["Adobe Camera Raw Filter"].prototype.zl=function(w,n){this.aaq=w-248;
this.abM=n;this.AD.zl(this.aaq,this.abM);this.lC.style.height=n-236+"px"};gu["Adobe Camera Raw Filter"].prototype.f=function(){for(var L=0;
L<this.SE.length;L++)this.SE[L].f()};gu.blnc=function(){gu.call(this);var w=this.e;this.b4=null;this.nq=new i0([12,12],[[19,6,0],[19,6,1],[19,6,2]]);
this.nq.h(b.E.A,this.Uc,this);w.appendChild(this.nq.e);this.Lh=[];for(var L=0;L<3;L++){var n=new eu(["VAR0 - VAR1",eH.a1c[L],eH.RU[L]],-100,100);
n.h(b.E.A,this.FI,this);this.Lh.push(n);w.appendChild(n.e)}this.eQ=new b7([13,4]);this.eQ.h(b.E.A,this.FI,this);
w.appendChild(this.eQ.e)};gu.blnc.prototype=new gu;gu.blnc.prototype.f=function(){this.nq.f();for(var L=0;
L<3;L++)this.Lh[L].f();this.eQ.f()};gu.blnc.prototype.$=function(w){this.b4=JSON.parse(JSON.stringify(w));
this.Uc()};gu.blnc.prototype.b=function(w){var n=["ShdL","MdtL","HghL"],W=this.b4[n[this.nq.b()]].v;
for(var L=0;L<3;L++)W[L].v=this.Lh[L].b();this.b4.PrsL.v=this.eQ.b();return JSON.parse(JSON.stringify(this.b4))};
gu.blnc.prototype.Uc=function(w){var n=["ShdL","MdtL","HghL"],W=this.b4[n[this.nq.b()]].v;for(var L=0;
L<3;L++)this.Lh[L].$(W[L].v);this.eQ.$(this.b4.PrsL.v)};gu.brit=function(){gu.call(this,"brit");this.pE.push(new eu([12,2],-150,150,""));
this.pE.push(new eu([12,3,0],-100,100,""));this.pE.push(new b7([12,3,1]));this.sk()};gu.brit.prototype=new gu;
gu.curv=function(){gu.call(this);this.value=null;this.zI=null;this.ww=null;var w=this.e;this.WF=new i0("Preset",["basic","advanced"]);
this.WF.h(b.E.A,this.alu,this);w.appendChild(this.WF.e);e.x$(w);this.OE=new i0([12,4],["RGB",[13,1,1],[13,1,4],[13,1,5]]);
this.OE.h(b.E.A,this.T5,this);w.appendChild(this.OE.e);this.hb=new i0(null,["Spline","Sketch"]);this.hb.h(b.E.A,this.alu,this);
w.appendChild(this.hb.e);this.bc=new kq;this.bc.parent=this;this.bc.h(b.E.A,this.m6,this);w.appendChild(this.bc.e);
e.x$(w);this.ZN=new dA;this.ZN.h(b.E.A,this.$y,this);w.appendChild(this.ZN.e);this.Gy=null;this.a88=0;
this.i2=0;e.x$(w);this.Oe=new jw("Sample from image",j$.ES(["-\u2195","#000000","#888888","#ffffff"]),!0,null,!0);
this.Oe.h(b.E.A,this.OH,this);this.Oe.e.style.marginRight="0";w.appendChild(this.Oe.e)};gu.curv.prototype=new gu;
gu.curv.prototype.GZ=function(w,n){if(n==bk.bI||n==bk.K_){var W=w.iE,D=["Default"];for(var L=0;L<W.length;
L++)D.push(W[L].presetFileName.v);D.push("Custom");this.WF.TF(D,[1,W.length,1]);this.ww=w}};gu.curv.prototype.zl=function(w,n){this.ZN.zl(w,n)};
gu.curv.prototype.f=function(){this.OE.f();this.ZN.f()};gu.curv.prototype.Xl=function(){this.WF.$(this.ww.iE.length+1)};
gu.curv.prototype.alu=function(w){if(w.target==this.WF){var n=this.WF.b(),W=this.ww.iE,D;if(n==0)D=cx._1("curv");
else if(n-1<W.length)D=JSON.parse(JSON.stringify(W[n-1]));else return;this.$(D);this.FI();return}this.Xl();
var j=e0.Qw(this.value,0),I=j.length==256?1:0,U=this.hb.b();if(I==U)return;var D=cx._1("curv");if(U==1){var M=[];
for(var L=0;L<256;L++)M.push(L);e0.nr(D,0,M)}this.$(D);this.FI()};gu.curv.prototype.$y=function(){this.Xl();
e0.nr(this.value,this.OE.b(),this.ZN.b());this.FI()};gu.curv.prototype.T5=function(){var w=this.OE.b(),n=e0.Qw(this.value,w),W=n.length==256?1:0;
this.hb.$(W);if(this.zI)this.ZN.pH(this.zI[w],this.zI[4]*[1,.33,.33,.33][w],["#ccc","#fcc","#cfc","#ccf"][w]);
this.ZN.$(n)};gu.curv.prototype.tZ=function(){return!0};gu.curv.prototype.WQ=function(w,n,W,D,j){var I=this.value;
this.value=cx._1("curv");this.FI();var U=y.Mi.B4(w,j,1),M=this.Gy=[U>>>16&255,U>>>8&255,U&255];this.a88=j.y;
var m=this.Oe.b().indexOf(!0);if(m==0){var l=(M[0]+M[1]+M[2])/3,A=this.OE.b(),g=e0.Qw(I,A),k=A==0?l:M[A-1],$=-1;
for(var L=0;L<g.length;L++)if(g[L].v.Hrzn.v==k)$=L;if($==-1){var C=JSON.parse(JSON.stringify(g[0]));
C.v.Hrzn.v=k;C.v.Vrtc.v=k;g.push(C);g.sort(function(f,z){return f.v.Hrzn.v-z.v.Hrzn.v});e0.nr(I,A,g);
this.i2=g.indexOf(C)}else this.i2=$}this.$(I);this.FI()};gu.curv.prototype.QD=function(w,n,W,D,j){if(this.Gy==null)return;
if(this.Oe.b().indexOf(!0)==0){var I=this.value,U=this.OE.b(),M=e0.Qw(I,U),m=M[this.i2];m.v.Vrtc.v=Math.max(0,Math.min(255,Math.round(m.v.Hrzn.v+(this.a88-j.y))));
e0.nr(I,U,M);this.$(I);this.FI()}};gu.curv.prototype.H5=function(w,n,W,D,j){var I=this.value,U=this.Gy,M=(U[0]+U[1]+U[2])/3,m=this.Oe.b().indexOf(!0)-1;
if(m<=-1){}else for(var L=0;L<3;L++){var l=e0.Qw(I,1+L);if(m==0)l[0].v.Hrzn.v=U[L];if(m==1){var A=Math.log(U[L]/255)/Math.log(M/255),g=Math.min(999,Math.max(10,Math.round(100*A)));
if(l.length==2)l.splice(1,0,JSON.parse(JSON.stringify(l[0])));l[1].v.Hrzn.v=127-Math.log(g/100)*127;
l[1].v.Vrtc.v=127}if(m==2)l[l.length-1].v.Hrzn.v=U[L];e0.nr(I,1+L,l)}this.$(I);this.FI();this.Xl();this.Gy=null};
gu.curv.prototype.$=function(w){this.value=w;this.T5()};gu.curv.prototype.pH=function(w){this.zI=w;this.T5()};
gu.curv.prototype.b=function(w){return JSON.parse(JSON.stringify(this.value))};gu.curv.prototype.m6=function(){var w=this.bc.b(),n=this.zI,W=this.value,D=E.co(w,n);
for(var L=0;L<4;L++){var j=D[L][0],I=D[L][1],U=D[L][2],M=[E.MU.$j(j,0,!0),E.MU.$j(I,255,!0)];if(U!=null)M.splice(1,0,E.MU.$j(128,U,!0));
e0.nr(W,L,M)}this.T5();this.FI()};gu.expA=function(){gu.call(this,"expA");this.pE.push(new eu([12,5],-20,20,null,2,!0));
this.pE.push(new eu([12,6],-.5,.5,null,2));this.pE.push(new eu([12,7],.01,9.99,null,2,!0));this.sk()};
gu.expA.prototype=new gu;gu.expA.prototype.qa=function(w,n){n[0]=w.Exps.v;n[1]=w.Ofst?w.Ofst.v:0;n[2]=w.gammaCorrection?w.gammaCorrection.v:1};
gu.expA.prototype.EC=function(w,n){w.Exps={t:"doub",v:n[0]};w.Ofst={t:"doub",v:n[1]};w.gammaCorrection={t:"doub",v:n[2]}};
gu.grdm=function(){gu.call(this,"grdm");this.pE.push(new jr(!0,null,!0));this.pE.push(new b7([12,23,0]));
this.sk()};gu.grdm.prototype=new gu;gu.grdm.prototype.qa=function(w,n){n[0]=w.Grad.v;n[1]=w.Rvrs?w.Rvrs.v:!1};
gu.grdm.prototype.EC=function(w,n){w.Grad.v=n[0];w.Rvrs={t:"bool",v:n[1]}};gu.grdm.prototype.GZ=function(w,n){this.pE[0].Wc(w.Gp,w.as);
if(n==bk.bI||n==bk.X$||n==bk.tU)this.pE[0].FC(w.wX)};gu.selc=function(){gu.call(this);var w=this.e;this.RY=[];
this.Mm=null;this.nq=new i0([12,82],eH.Nv.concat([[13,1,8],[13,1,13],[13,1,10]]));this.nq.h(b.E.A,this.bX,this);
w.appendChild(this.nq.e);e.x$(w);for(var L=0;L<4;L++){var n=new eu(eH.a1c[L],-100,100,"%");n.h(b.E.A,this.bX,this);
this.RY.push(n);w.appendChild(n.e)}this.fY=new b7([13,3]);w.appendChild(this.fY.e);this.fY.h(b.E.A,this.bX,this)};
gu.selc.prototype=new gu;gu.selc.prototype.f=function(){this.nq.f();this.fY.f();for(var L=0;L<4;L++)this.RY[L].f()};
gu.selc.prototype.$=function(w){this.Mm=JSON.parse(JSON.stringify(w));this.Uc()};gu.selc.prototype.b=function(w){return JSON.parse(JSON.stringify(this.Mm))};
gu.selc.prototype.bX=function(w){if(w.target!=this.nq){var n=this.Mm,W=[];for(var L=0;L<4;L++)W[L]=this.RY[L].b();
av.nr(n,this.nq.b(),W);n.Mthd={t:"enum",v:{CrcM:this.fY.b()?"Absl":"Rltv"}}}this.Uc();this.FI()};gu.selc.prototype.Uc=function(){var w=this.Mm,n=av.Qw(w,this.nq.b());
for(var L=0;L<4;L++)this.RY[L].$(n[L]);this.fY.$(w.Mthd?w.Mthd.v.CrcM=="Absl":!1)};gu.blwh=function(){gu.call(this,"blwh");
this.pE.push(new b7([12,11]));this.pE.push(new gM(!0));for(var L=0;L<6;L++)this.pE.push(new eu(eH.Nv[L],-200,300));
this.sk()};gu.blwh.prototype=new gu;gu.blwh.prototype.qa=function(w,n){n[0]=w.useTint.v;n[1]=w.tintColor.v;
var W="Rd Yllw Grn Cyn Bl Mgnt".split(" ");for(var L=0;L<6;L++)n[2+L]=w[W[L]].v};gu.blwh.prototype.EC=function(w,n){w.useTint.v=n[0];
w.tintColor.v=n[1];var W="Rd Yllw Grn Cyn Bl Mgnt".split(" ");for(var L=0;L<6;L++)w[W[L]].v=n[2+L]};
gu.hue2=function(){gu.call(this);this.value=null;this.Wa=null;this.adi=null;this.kp=[[0,0,0],[0,50,0]];
var w=this.e;this.Oe=new jw(null,["\u2194"],!0,["Click and drag in image to change saturation"],!0);
this.Oe.h(b.E.A,this.afI,this);this.Oe.h(b.E.A,this.OH,this);w.appendChild(this.Oe.e);var n=this.pE=[new i0([12,12],["Master"].concat(eH.Nv)),new eu([12,8],-180,180),new eu([12,9],-100,100),new eu([12,10],-100,100),new b7([12,11])];
for(var L=0;L<n.length;L++){var W=n[L];W.h(b.E.A,L==0?this.T5:this.az7,this);w.appendChild(W.e)}this.nq=n[0];
this.pm=n[1];this.wp=n[2];this.ym=n[3];this.J_=n[4];this.U8=new jw("Sample Hue",["<img src=\""+PIMG["tools/eyedropper"]+"\" class=\"autoscale gsicon\" />","+","-"],!0,null,!0);
this.U8.h(b.E.A,this.afI,this);this.U8.h(b.E.A,this.OH,this);this.U8.e.style.marginLeft="20px";w.appendChild(this.U8.e);
this.Xn=e.t("div");w.appendChild(this.Xn);this.vW=this.n$.bind(this);this.VB=this.KJ.bind(this);this.T=e.t("canvas");
this.VE=this.T.getContext("2d");this.P1=null;e.ZS(this.T);e.dz(this.T,282,18);w.appendChild(this.T);
e.L_(this.T,this.WI.bind(this))};gu.hue2.prototype=new gu;gu.hue2.prototype.zl=function(w,n){e.dz(this.T,Math.round(w),18);
if(this.value)this.T5()};gu.hue2.prototype.afI=function(w){var n=w.target.b().indexOf(!0);if(n==-1)return;
if(w.target==this.Oe)this.U8.$([!1,!1,!1]);else this.Oe.$([!1,!1,!1])};gu.hue2.prototype.WI=function(w){if(this.nq.b()==0||this.J_.b())return;
var n=e.rv(w,this.T).x/(this.T.width/e.V()),I=1e6;function W(g,k,$){return g<k&&k<$||$<g&&(g<k||k<$)}var D=this.uM(),j=-1;
for(var L=0;L<4;L++){var U=Math.abs(n-(D[L]+L*1e-5));if(U<I){I=U;j=L}}if(I>.025){j=-1;var M=D[0],m=D[1],l=D[2],A=D[3];
if(W(M,n,m))j=4;if(W(m,n,l))j=5;if(W(l,n,A))j=6}if(j==-1)return;this.P1=j;e.Ko(document.body,this.vW);
e.d6(document.body,this.VB)};gu.hue2.prototype.n$=function(w){var n=e.rv(w,this.T).x/(this.T.width/e.V()),W=this.uM(),D=this.P1;
for(var L=1;L<4;L++)if(W[L]<W[L-1]){W[L]+=1}if(D<4){var j=1e6,I=0;for(var L=-20;L<20;L++){var U=Math.abs(W[D]-(n+L));
if(U<j){j=U;I=L}}n+=I;W[D]=n;for(var L=D+1;L<4;L++)if(W[L]<W[L-1]){W[L]=W[L-1]}for(var L=D-1;L>=0;L--)if(W[L]>W[L+1]){W[L]=W[L+1]}}else{var M=n-(W[D-4]+W[D-3])/2;
if(M<-.5)M+=1;if(D==4){W[0]+=M;W[1]+=M;W[2]=Math.max(W[1],W[2]);W[3]=Math.max(W[1],W[3])}if(D==5)for(var L=0;
L<4;L++)W[L]+=M;if(D==6){W[2]+=M;W[3]+=M;W[0]=Math.min(W[0],W[2]);W[1]=Math.min(W[1],W[2])}}for(var L=1;
L<4;L++)if(W[L]<W[L-1])throw"e";this.avu(W);this.T5();this.FI()};gu.hue2.prototype.KJ=function(w){e.MC(document.body,this.vW);
e.i_(document.body,this.VB)};gu.hue2.prototype.f=function(){for(var L=0;L<this.pE.length;L++)this.pE[L].f()};
gu.hue2.prototype.az7=function(w){var n=this.value.Clrz.v=this.J_.b();if(n)this.nq.$(0);if(w&&w.target==this.J_){var W=n?1:0;
this.kp[1-W]=cT.Qw(this.value,0);var D=this.kp[W];cT.nr(this.value,0,D);if(this.nq.b()==0){this.pm.$(D[0]);
this.wp.$(D[1]);this.ym.$(D[2])}}var j=this.nq.b(),I=cT.Qw(this.value,j),D=j==0?I:I.Lh;D[0]=this.pm.b();
var U=this.wp.b();D[1]=n?Math.max(0,U):U;D[2]=this.ym.b();cT.nr(this.value,j,I);this.T5();this.FI()};
gu.hue2.prototype.T5=function(){var w=this.nq.b(),n=this.value.Clrz?this.value.Clrz.v:!1;this.J_.$(n);
this.nq.G3(!n);this.U8.G3(!n&&w!=0);var W=cT.Qw(this.value,w),D=w==0?W:W.Lh;this.pm.$(D[0]);this.wp.$(D[1]);
this.ym.$(D[2]);var j=this.T.width,I=this.T.height,U=this.VE;U.clearRect(0,0,j,I);if(n||w==0){this.Xn.innerHTML="";
return}var M=W.k0;this.Xn.innerHTML=M[0]+"\xB0 / "+M[1]+"\xB0<span style=\"float:right\">"+M[2]+"\xB0 \\ "+M[3]+"\xB0</span>";
var m=E.Q(j*4);bL.abC(m,1,j,-1,.5);var l=new ImageData(new Uint8ClampedArray(m.buffer),j,1),A=Math.round(I/4);
for(var L=0;L<A;L++)U.putImageData(l,0,L);function g(s,O,a){U.fillStyle=a;var X=A*2;if(s<=O)U.fillRect(s*j,X,(O-s)*j,A);
else{U.fillRect(0,X,O*j,A);U.fillRect(s*j,X,(1-s)*j,A)}}var k=this.uM();g(k[0],k[1],"#888888");g(k[1],k[2],"#cccccc");
g(k[2],k[3],"#888888");U.fillStyle="#ffffff";U.lineWidth=1;U.beginPath();var $=A+.5,C=4*A+.5;for(var L=0;
L<4;L++){var f=Math.floor(j*k[L])+.5,z=(L<2?-1:1)*A*(L==1||L==2?1:2);U.moveTo(f,$);U.lineTo(f,C);U.lineTo(f+z,C);
U.lineTo(f+z,A+A+.5);U.closePath()}U.fill();U.stroke()};gu.hue2.prototype.uM=function(){var w=this.nq.b(),n=cT.Qw(this.value,w).k0;
for(var L=0;L<4;L++)n[L]=(1000.5+n[L]/360)%1;return n};gu.hue2.prototype.avu=function(w){var n=this.nq.b(),W=cT.Qw(this.value,n);
for(var L=0;L<4;L++)W.k0[L]=Math.round(36e3+(w[L]-.5)*360)%360;cT.nr(this.value,n,W)};gu.hue2.prototype.tZ=function(){return!0};
gu.hue2.prototype.ab_=function(){var w=this.Oe.b().indexOf(!0),n=this.U8.b().indexOf(!0);return w!=-1?w:n!=-1?n+1:-1};
gu.hue2.prototype.WQ=function(w,n,W,D,j){var I=this.ab_();if(I==-1)return;var U=this.value;this.value=cx._1("hue2");
this.FI();var M=y.Mi.B4(w,j,1);this.$(U);var m=[M>>>16&255,M>>>8&255,M&255],l=E.i8(m[0]/255,m[1]/255,m[2]/255);
if(I==0){this.nq.$(1+Math.round(l.ag*6)%6)}else{var A=this.uM(),g=.5+l.ag,k=1/12,$=A[1],C=A[2];if(C<$){C++;
if(g<$&&g+1-C<$-g)g++}var f=$<=g&&g<=C;if(I==1){$=g-k/2;C=g+k/2}else if(I==2&&!f){$=Math.min(g,$);C=Math.max(g,C)}else if(I==3&&f){if(g-$<C-g)$=g;
else C=g}A=[$-k,$,C,C+k];this.avu(A)}this.FI();this.Wa=j.x;this.adi=this.wp.b()};gu.hue2.prototype.QD=function(w,n,W,D,j){var I=this.ab_();
if(I==-1)return;if(I==0){if(this.Wa!=null){var U=j.x-this.Wa;U=Math.max(-100,Math.min(100,this.adi+.5*U));
this.wp.$(U);this.az7()}}};gu.hue2.prototype.H5=function(w,n,W,D,j){this.Wa=null};gu.hue2.prototype.$=function(w){this.value=JSON.parse(JSON.stringify(w));
var n=this.value.Clrz?this.value.Clrz.v:!1;this.kp[n?1:0]=cT.Qw(this.value,0);this.T5()};gu.hue2.prototype.b=function(w){return JSON.parse(JSON.stringify(this.value))};
gu.levl=function(){function w(){gu.call(this);this.value=null;this.zI=null;this.YA=[new ec(0,0),new ec(0,0),new ec(0,0),new ec(0,0),new ec(0,0)];
this.s$=-1;this.vW=this.n$.bind(this);this.VB=this.KJ.bind(this);var n=this.e;this.OE=new i0([12,4],["RGB",[13,1,1],[13,1,4],[13,1,5]]);
this.OE.h(b.E.A,this.T5,this);n.appendChild(this.OE.e);this.bc=new kq;this.bc.parent=this;this.bc.h(b.E.A,this.m6,this);
n.appendChild(this.bc.e);var W=e.t("div","");n.appendChild(W);var D=e.t("div","");n.appendChild(D);this.T=e.t("canvas");
W.appendChild(this.T);this.VE=this.T.getContext("2d");this.IS=new ec(256,120);this.T.setAttribute("style","display:block");
e.ZS(this.T);e.L_(this.T,this.WI.bind(this));this.Ly=e.t("canvas","");D.appendChild(this.Ly);this.gG=this.Ly.getContext("2d");
this.KS=new ec(this.IS.x,40);this.Ly.setAttribute("style","display:block");e.ZS(this.Ly);e.L_(this.Ly,this.akL.bind(this));
var j=this.o_=[];for(var L=0;L<5;L++){var I=new e7(null,null,3);j.push(I);I.h(b.E.A,this.a42,this);(L<2||L==4?W:D).appendChild(I.e)}W.appendChild(j[1].e);
this.Oe=new jw("Sample from image",j$.ES(["#000000","#888888","#ffffff"]),!0,null,!0);this.Oe.h(b.E.A,this.OH,this);
n.appendChild(this.Oe.e);this.zl(250,100)}w.prototype=new gu;w.prototype.m6=function(){var n=this.bc.b(),W=this.zI,D=this.value,j=E.co(n,W);
for(var L=0;L<4;L++){var I=j[L][0],U=j[L][1],M=j[L][2],m=[E.MU.$j(I,0,!0),E.MU.$j(U,255,!0)];if(M!=null)m.splice(1,0,E.MU.$j(128,M,!0));
var l=[~~I,~~U,0,255,M==null?100:~~(100+.75*100*(M-128)/128)];il.nr(D,L,l)}this.T5();this.FI()};w.prototype.zl=function(n,W){n+=6;
this.IS.x=this.KS.x=n;e.dz(this.T,n,this.IS.y,this.VE);e.dz(this.Ly,n,this.KS.y,this.gG);var D=this.o_;
D[3].e.setAttribute("style","margin-left: "+(n-104)+"px");D[4].e.setAttribute("style","margin: 0 "+(n/2-74)+"px");
if(this.value)this.T5()};w.prototype.f=function(){this.OE.f()};w.prototype.a42=function(n){var W=[];
for(var L=0;L<5;L++){var D=255,j=1;if(L==4){D=999;j=100}var I=parseFloat(this.o_[L].b());W[L]=Math.max(0,Math.min(D,I*j))}il.nr(this.value,this.OE.b(),W);
this.T5();this.FI()};w.prototype.T5=function(n){var W=this.IS.x,D=this.IS.y,j=this.OE.b(),I=this.VE;
I.clearRect(0,0,W,D);I.fillStyle="#cccccc";I.fillRect(8,8,W-16,D-16-8);if(this.zI){var U=this.zI[0].slice(0),C=0;
if(j==0){U.fill(0);var M=JSON.parse(JSON.stringify(this.value));il.nr(M,0,[0,255,0,255,100]);var m=eH.rw("levl",M),l=[m.UX,m.D4,m.ZA];
for(var A=0;A<3;A++){var g=this.zI[1+A],k=l[A];for(var L=0;L<256;L++)U[k[L]]+=g[L]}}var $=j==0?U:this.zI[j];
for(var L=0;L<$.length;L++)C+=$[L];I.fillStyle="#333333";I.beginPath();I.moveTo(8,D-16);for(var L=0;
L<256;L++){var f=55*$[L]/C;I.lineTo(8+L/256*(W-16),Math.max(8,D-16-D*f))}I.lineTo(W-8,D-16);I.closePath();
I.fill()}var z=il.Qw(this.value,j);for(var L=0;L<5;L++)this.o_[L].$(z[L]/(L==4?100:1));this.YA[0].y1(8+z[0]/255*(W-16),D-14);
this.YA[1].y1(8+z[1]/255*(W-16),D-14);var s=Math.log(z[4]/100)/Math.log(9.99);s=.5-s/2;this.YA[4].y1(this.YA[0].x+s*(this.YA[1].x-this.YA[0].x),D-14);
this.bz(I,this.YA[0],"#000000");this.bz(I,this.YA[1],"#ffffff");this.bz(I,this.YA[4],"#777777");var W=this.KS.x,D=this.KS.y;
I=this.gG;I.clearRect(0,0,W,D);var O=I.createLinearGradient(0,0,W-16,0);O.addColorStop(0,"black");O.addColorStop(1,"white");
I.fillStyle=O;I.fillRect(8,8,W-16,16);this.YA[2].y1(8+z[2]/255*(W-16),D-14);this.YA[3].y1(8+z[3]/255*(W-16),D-14);
this.bz(I,this.YA[2],"#000000");this.bz(I,this.YA[3],"#ffffff")};w.prototype.bz=function(n,W,D){n.fillStyle=D;
n.fillRect(W.x-5,W.y,10,10)};w.prototype.WI=function(n){var W=e.rv(n,this.T),D=this.anA([0,1,4],W);if(D!=-1)this.s$=D;
this.a14()};w.prototype.akL=function(n){var W=e.rv(n,this.Ly),D=this.anA([2,3],W);if(D!=-1)this.s$=D;
this.a14()};w.prototype.anA=function(n,W){var D=-1,j=1e9;for(var L=0;L<n.length;L++){var I=Math.abs(this.YA[n[L]].x-W.x);
if(I<j){j=I;D=n[L]}}return j<16?D:-1};w.prototype.a14=function(n){if(this.s$==-1)return;e.Ko(document.body,this.vW);
e.d6(document.body,this.VB)};w.prototype.n$=function(n){var W=il.Qw(this.value,this.OE.b()),D=e.rv(n,this.s$==2&&this.s$==3?this.Ly:this.T),j=255*(D.x-8)/(this.IS.x-16);
j=Math.max(0,Math.min(255,j));if(this.s$==0)j=Math.min(j,W[1]-2);if(this.s$==1)j=Math.max(j,W[0]+2);
if(this.s$!=4)W[this.s$]=Math.round(j);else{var I=(j-W[0])/(W[1]-W[0]);I=1-2*I;I=Math.pow(9.99,I);W[4]=Math.min(999,Math.max(10,Math.round(I*100)))}il.nr(this.value,this.OE.b(),W);
this.T5();this.FI()};w.prototype.KJ=function(n){e.MC(document.body,this.vW);e.i_(document.body,this.VB);
this.s$=-1};w.prototype.tZ=function(){return!0};w.prototype.H5=function(n,W,D,j,I){var U=this.value,M=this.Oe.b().indexOf(!0);
if(M==-1)return;this.value=cx._1("levl");this.FI();var m=y.Mi.B4(n,I,1),l=[m>>>16&255,m>>>8&255,m&255];
for(var L=0;L<3;L++){var A=il.Qw(U,1+L);if(M==0)A[0]=l[L];if(M==1){var g=Math.log(l[L]/255)/Math.log((l[0]+l[1]+l[2])*.333/255);
A[4]=Math.min(999,Math.max(10,Math.round(100*g)))}if(M==2)A[1]=l[L];il.nr(U,1+L,A)}this.$(U);this.FI()};
w.prototype.$=function(n){this.value=n;this.T5()};w.prototype.pH=function(n){this.zI=n;this.T5()};w.prototype.b=function(n){return JSON.parse(JSON.stringify(this.value))};
return w}();gu.phfl=function(){gu.call(this,"phfl");this.pE.push(new gM);this.pE.push(new eu([12,74],0,100,"%"));
this.pE.push(new b7([13,4]));this.sk()};gu.phfl.prototype=new gu;gu.phfl.prototype.qa=function(w,n){n[0]=w.Clr.v;
n[1]=w.Dnst.v;n[2]=w.PrsL.v};gu.phfl.prototype.EC=function(w,n){var W=E.M.y_(n[0]),D=w.Clr.v,j=E.gK(W.o,W.B,W.k);
D.Lmnc.v=j.zP;D.A.v=j.dl;D.B.v=j.k;w.Dnst.v=n[1];w.PrsL.v=n[2]};gu.vibA=function(){gu.call(this,"vibA");
this.pE.push(new eu([12,13],-100,100,null));this.pE.push(new eu([12,9],-100,100,null));this.sk()};gu.vibA.prototype=new gu;
gu.vibA.prototype.qa=function(w,n){n[0]=w.vibrance?w.vibrance.v:0;n[1]=w.Strt?w.Strt.v:0};gu.vibA.prototype.EC=function(w,n){w.vibrance.v=n[0];
w.Strt.v=n[1]};gu.thrs=function(){gu.call(this,"thrs");this.pE.push(new eu([4,13],1,255,null));this.sk()};
gu.thrs.prototype=new gu;gu.thrs.prototype.qa=function(w,n){n[0]=w.Lvl.v};gu.thrs.prototype.EC=function(w,n){w.Lvl.v=n[0]};
gu.mixr=function(){gu.call(this);var w=this.e;this.RY=[];this.Mm=null;this.nq=new i0([12,4],[[13,1,1],[13,1,4],[13,1,5]]);
this.ab2=!1;this.nq.h(b.E.A,this.bX,this);w.appendChild(this.nq.e);e.x$(w);this.jD=new b7([12,60]);w.appendChild(this.jD.e);
this.jD.h(b.E.A,this.bX,this);for(var L=0;L<4;L++){var n=new eu([[13,1,1],[13,1,4],[13,1,5],[13,2]][L],-200,200,"%");
n.h(b.E.A,this.bX,this);this.RY.push(n);w.appendChild(n.e)}};gu.mixr.prototype=new gu;gu.mixr.prototype.f=function(){this.nq.f();
this.jD.f();for(var L=0;L<4;L++)this.RY[L].f()};gu.mixr.prototype.$=function(w){this.Mm=JSON.parse(JSON.stringify(w));
this.Uc()};gu.mixr.prototype.b=function(w){return JSON.parse(JSON.stringify(this.Mm))};gu.mixr.prototype.bX=function(w){if(w.target!=this.nq){var n=eH.hm(this.Mm);
if(w.target==this.jD){n.jD=this.jD.b();if(n.jD)n.Z=[40,40,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];else n.Z=[100,0,0,0,0,0,100,0,0,0,0,0,100,0,0,0,0,0,0,0]}else{var W=(n.jD?0:this.nq.b())*5,L=this.RY.indexOf(w.target);
n.Z[W+(L<3?L:4)]=w.target.b()}this.Mm=eH.a3Z(n)}this.Uc();this.FI()};gu.mixr.prototype.Uc=function(){var w=eH.hm(this.Mm);
if(w.jD!=this.ab2)this.nq.TF(w.jD?[[13,1,7]]:eH.RU);this.ab2=w.jD;this.jD.$(w.jD);var n=(w.jD?0:this.nq.b())*5;
for(var L=0;L<4;L++)this.RY[L].$(w.Z[n+(L<3?L:4)])};gu.post=function(){gu.call(this,"post");this.pE.push(new eu([4,1],2,255,null));
this.sk()};gu.post.prototype=new gu;gu.post.prototype.qa=function(w,n){n[0]=w.Lvls.v};gu.post.prototype.EC=function(w,n){w.Lvls.v=n[0]};
gu.clrL=function(){gu.call(this,"clrL");this.pE.push(new bC("LUTs"));this.sk()};gu.clrL.prototype=new gu;
gu.clrL.prototype.qa=function(w,n){n[0]=w};gu.clrL.prototype.EC=function(w,n){var W=n[0];for(var D in W)w[D]=W[D]};
gu.clrL.prototype.GZ=function(w,n){if(n==bk.bI||n==bk.M9)this.pE[0].FC(w.a6W)};gu.rplc=function(){gu.call(this,"rplc");
this.pE.push(new eu([12,92],0,200));this.pE.push(new gM);this.pE.push(new eu([12,8],-180,180));this.pE.push(new eu([12,9],-100,100));
this.pE.push(new eu([12,10],-100,100));this.sk()};gu.rplc.prototype=new gu;gu.rplc.prototype.qa=function(w,n){n[0]=w.Fzns.v;
n[1]=w.Mxm.v;n[2]=w.H.v;n[3]=w.Strt.v;n[4]=w.Lght.v};gu.rplc.prototype.EC=function(w,n){function W(j,I){I.Lmnc.v=j.zP;
I.A.v=j.dl;I.B.v=j.k}w.Fzns.v=n[0];w.H.v=n[2];w.Strt.v=n[3];w.Lght.v=n[4];var D=E.M.y_(n[1]),j=E.gK(D.o,D.B,D.k);
W(j,w.Mnm.v);W(j,w.Mxm.v)};gu.fade=function(){gu.call(this,"fade");this.pE.push(new eu([12,0],0,100,"%"));
this.pE.push(new i0([12,19,0],dD.AE,dD.E5));this.sk()};gu.fade.prototype=new gu;gu.fade.prototype.qa=function(w,n){n[0]=w.Opct.v.val;
n[1]=dD.ik.indexOf(w.Md.v.BlnM)};gu.fade.prototype.EC=function(w,n){w.Opct.v.val=n[0];w.Md.v.BlnM=dD.ik[n[1]]};
gu.aply=function(){var w=dD.ik.concat(["Add","Sbtr"]);w.splice(21,1);var n=dD.AE.concat([[15,10,28],[15,10,21]]);
n.splice(21,1);var W=dD.E5.slice(0);W[4]--;function D(){gu.call(this,"aply");this.pE.push(new i0([0,3],[]));
this.pE.push(new i0([12,4],["RGB"].concat(eH.RU).concat(["Transparency"])));this.pE.push(new b7([4,11]));
this.pE.push(new i0([12,19,0],n,W));this.pE.push(new eu([12,0],0,100,"%"));this.pE.push(new g_([12,38],1,2,null,2));
this.pE.push(new g_([12,6],-255,255));this.pE.push(new b7([13,5]));this.sk([2]);this.rO=null}D.prototype=new gu;
D.prototype.qa=function(j,I,U){if(U){var M=U[2].C,m=this.rO=[];for(var L=0;L<M.length;L++){var l=M[L].getName();
m.push(l.length<30?l:l.slice(0,27)+"...")}m.reverse();this.pE[0].TF([[5,7]].concat(m),[1,m.length])}else var m=this.rO;
j=j.With.v;var A=j.T.v;I[0]=A[1].t=="name"?1+m.indexOf(A[1].v.val):0;I[1]=["RGB","Rd","Grn","Bl","Trsp"].indexOf(A[0].v.enum);
I[2]=j.Invr.v;var g=j.Clcl.v.Clcn;I[3]=w.indexOf(g);I[4]=j.Opct.v.val;I[5]=j.Scl.v;I[6]=j.Ofst.v;I[7]=j.PrsT.v};
D.prototype.EC=function(j,I){j=j.With.v;var U=j.T.v;if(I[0]==0)U[1]={t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Mrgd"}};
else U[1]={t:"name",v:{classID:"Lyr",val:this.rO[I[0]-1]}};U[0].v.enum=["RGB","Rd","Grn","Bl","Trsp"][I[1]];
j.Invr.v=I[2];var M=j.Clcl.v.Clcn=w[I[3]];j.Opct.v.val=I[4];j.Scl.v=I[5];j.Ofst.v=I[6];j.PrsT.v=I[7];
var m=M=="Add"||M=="Sbtr";this.pE[5].G3(m);this.pE[6].G3(m)};return D}();gu.matc=function(){var w,n,W=0;
function D(){gu.call(this,"matc");this.pE.push(new eu("Luminance",1,200));this.pE.push(new eu("Color Intensity",1,200));
this.pE.push(new eu([2,11],0,100,"%"));this.pE.push(new b7("Neutralize"));this.pE.push(new i0([12,70],[]));
this.pE.push(new i0([0,3],[]));this.sk([2])}function j(I,U){I.pE[5].TF([[5,7]].concat(U),[1,U.length])}D.prototype=new gu;
D.prototype.qa=function(I,U,M){W=0;U[0]=I.Lght.v;U[1]=I.ClrR.v;U[2]=I.Fade.v;U[3]=I.neutralizeColor?I.neutralizeColor.v:!1;
U[4]=U[5]=0;var m=I.Srce;if(m)m=m.v;if(M){w=[];n=[];var l=M[2],A=M[3];for(var L=0;L<A.length;L++){var g=A[L];
w.push(g.name);var k=g.C,$=[];n.push($);for(var C=0;C<k.length;C++)$.push(k[C].getName());$.reverse()}this.pE[4].TF([[13,1,0]].concat(w),[1,w.length]);
var f=A.indexOf(l);if(m)f=w.indexOf(m[1].v.val);j(this,n[f])}if(m){var z=w.indexOf(m[1].v.val);U[3]=W=1+z;
if(m[0].t=="name")U[4]=1+n[z].indexOf(m[0].v.val)}};D.prototype.EC=function(I,U){I.Lght.v=U[0];I.ClrR.v=U[1];
I.Fade.v=U[2];I.neutralizeColor.v=U[3];if(U[4]==0){I.noReference={t:"bool",v:!0};delete I.Srce}else{if(U[4]!=W){W=U[4];
j(this,n[U[4]-1])}delete I.noReference;var M={t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Mrgd"}},m=n[U[4]-1];
if(U[5]!=0)M={t:"name",v:{classID:"Lyr",val:m[U[5]-1]}};I.Srce={t:"obj ",v:[M,{t:"name",v:{classID:"Dcmn",val:w[U[4]-1]}}]}}};
return D}();function dB(w,n){eg.call(this);if(w==null)return;this.id=n;this.II=w;this.td=null;this.e=e.t("div","window "+n);
this.ad3=null;this.Oc=e.t("div","whead");this.a54=e.t("span","wname");this.Oc.appendChild(this.a54);
this.aiF=!1;this.e.appendChild(this.Oc);this.aF=this.ahf.bind(this);this.OO=this.a6T.bind(this);this.Ou=this.a3x.bind(this);
e.ZS(this.Oc);e.L_(this.Oc,this.aF);this.a3L=e.t("span","cross gsicon");this.Oc.appendChild(this.a3L);
dB.prototype.f.call(this);e.d6(this.a3L,this.a1s.bind(this));this.body=e.t("div","body");this.e.appendChild(this.body)}dB.prototype=new eg;
dB.prototype.wb=function(){return!1};dB.prototype.tZ=function(){return!1};dB.prototype.f=function(){if(this.II==null)return;
this.a54.textContent=fV.get(this.II)};dB.prototype.WQ=function(w,n,W,D,j){};dB.prototype.Eq=function(w,n,W,D,j){};
dB.prototype.QD=function(w,n,W,D,j){};dB.prototype.H5=function(w,n,W,D,j){};dB.prototype.cF=function(w,n,W,D,j){};
dB.prototype.oe=function(w,n,W,D){if(D.U(aK.yG)&&this.j8)this.j8();if(D.U(aK.CQ)){var j=new ed(b.E.v);
j.HH=!0;y.Jd.a0D(D,j);if(j.data)n.S(j)}};dB.prototype.wO=function(w){return!1};dB.prototype.X7=function(w,n){return!0};
dB.prototype.mQ=function(w,n,W,D){};dB.prototype.GZ=function(w,n){};dB.prototype.aP=function(w,n){return null};
dB.prototype.aAg=function(w){return this.ad3};dB.prototype.zl=function(){};dB.prototype.close=function(){this.S(new ed(b.E.gh))};
dB.prototype.ahf=function(w){this.td=e.rv(w,this.e);e.Ko(window,this.OO);e.d6(window,this.Ou)};dB.prototype.a6T=function(w){var n=this.e.parentNode,W=e.rv(w,n),D=Math.round(W.x-this.td.x),j=n.offsetTop+Math.max(0,Math.min(window.innerHeight-36,Math.round(W.y-this.td.y)));
this.ad3=new ec(D,j);this.e.style.left=D+"px";this.e.style.top=j+"px"};dB.prototype.a3x=function(w){e.MC(window,this.OO);
e.i_(window,this.Ou)};dB.prototype.a1s=function(w){if(this.aiF){this.j8();return}this.S(new ed("closebtn"));
this.close()};function e4(){dB.call(this,"About Photopea","aboutpp");var w=e.t("div","flexrow");this.body.appendChild(w);
var n=this.aqM=e.t("img");w.appendChild(n);this.body.setAttribute("style","margin:0; padding:0");var W=this.ahx=e.t("div");
W.innerHTML=e4.Bz;w.appendChild(W);var D=this.Kf=e.t("span");D.innerHTML="<big style=\"text-shadow: 2px 2px 3px #000000;\">Ivan holding Photopea in Prague</big>";
this.body.appendChild(D)}e4.prototype=new dB;e4.prototype.aP=function(w,n){return new ec(0,0)};e4.prototype.zl=function(w,n){var W=this.aqM,D=this.ahx,j=this.Kf,I=(w+n-42-42)/110;
I=Math.sqrt((w-42)*(n-42))/50;W.setAttribute("style","width:"+w/2+"px; height:"+n+"px; display:block; object-fit:cover;");
D.setAttribute("style","width:"+(w/2-42)+"px; height:"+(n-42)+"px; padding:20px; font-size:"+I+"px;");
j.setAttribute("style","position:absolute; bottom:10px; right:"+(w/2+10)+"px")};e4.prototype.f=function(){};
e4.prototype.mQ=function(w,n,W,D){this.aqM.setAttribute("src","promo/ivan_pp.webp")};e4.Bz="\t<h1>Hi There!</h1>\t<p>My name is <b>Ivan Kutskir</b> and I'm the creator of Photopea.</p>\t<p>I'm a 30-year-old computer programmer. I was born in Ukraine, but I live in the Czech Republic most of my life (in <b>Prague</b> since 2009).</p>\t<p>I started developing Photopea back in 2012. I intended to call it <b>Photo Hammer</b>, \tbut I didn't register the .com domain right away, and when I tried to do so six months later, it was already taken.</p>\t\t<p>My friends and my family did not know about Photopea during the first four years of development.\tI was spending a lot of time building it, without making any money or learning new skills. So nothing to be proud of, \tbut the project was fun and I enjoyed working on it.\t</p>\t<p>\tNow, it's heartwarming to know that millions around the world use Photopea as their creative medium. \tTo this day I work on Photopea, driven by the positive impact of my creation.\t</p>\t\t<!--<p>You can not be completely sure if something is a good or a bad idea, until you actually try to do it.</p>-->\t\t<p style=\"text-align:right;\"><i><big>Ivan Kutskir</big><br/>support@photopea.com</i></p>\t";
function jU(){dB.call(this,[0,13,0],"account");this.xG=e.t("div","form scrollable");this.body.appendChild(this.xG);
this.body.style.padding="0";this.y4=[new jU.IY,new jU.lu("::privacy.html"),new jU.lu(jU.alZ)];for(var L=0;
L<this.y4.length;L++)this.y4[L].parent=this;this.h("showpage",this.aov,this)}jU.prototype=new dB;jU.prototype.X7=function(w,n){var W=navigator.onLine;
if(!W)alert("Go online first");return W};jU.prototype.zl=function(w,n){this.xG.setAttribute("style","width:"+Math.min(w-40,740)+"px; height:"+(n-38)+"px; padding:1.5em;");
this.y4[0].zl(w,n)};jU.prototype.aP=function(w,n){return new ec(Math.max(0,Math.min(150,(w-740)/2)),Math.max(0,Math.min(100,(n-500)/2)))};
jU.prototype.aov=function(w){e._g(this.xG);this.xG.scrollTop=0;this.xG.appendChild(this.y4[w.data.p_].e)};
jU.prototype.f=function(){dB.prototype.f.call(this);for(var L=0;L<this.y4.length;L++)this.y4[L].f()};
jU.prototype.mQ=function(w,n,W){if(!navigator.onLine)return;e._g(this.xG);var D=this.y4[0];this.xG.appendChild(D.e);
D.mQ();this.f()};jU.prototype.GZ=function(w,n){this.mQ(null,null,null)};jU.IY=function(){eg.call(this);
this.e=e.t("div");var w=this.e,M,m,A="font-size:1.25em;",g="text-align:center;",$="style=\"list-style-type: none; padding:0; margin:0; font-size:1.15em;\"",C="style=\"font-weight:bold; color:#00aa00; padding-right:4px;\"",f="style=\"width:50%; vertical-align:top; padding:10px 20px;\"",s=12;
this.dd=e.t("div");w.appendChild(this.dd);this.u5=new iP([0,11],!1,null,!0);this.u5.e.setAttribute("style","background-color: rgba(200,0,0,1); color:#ffffff; margin:4px 6px 4px 0;");
this.u5.h("click",this.uB,this);w.appendChild(this.u5.e);this.ta=new iP([0,13,1],!1,null,!0);this.ta.h("click",this.arv,this);
w.appendChild(this.ta.e);this.fr=new iP("Business Terms",!1,null,!0);this.fr.h("click",this.a9E,this);
w.appendChild(this.fr.e);var n=e.t("div");n.style.margin="20px 0";w.appendChild(n);var W=["Account Types","Go Premium","Team Settings","Distributors"],D=this.sb=[],j=this.a5$=[],I=this.xq=e.t("div");
w.appendChild(I);for(var L=0;L<W.length;L++){var U=e.t("span");U.textContent=W[L];n.appendChild(U);D.push(U);
U.setAttribute("style","font-weight:bold; display:inline-block; margin-right:2em; font-size:1.1em; cursor:pointer;");
U.addEventListener("click",this.s8.bind(this));j.push(e.t("div"))}this.s8(0);var l=this.aoq="background-color: #00aa00; text-shadow:none; padding:3px 7px; font-size:1.2em; color:#ffffff; cursor:pointer; margin:4px 0; width:100%;";
w=j[0];var m=e.t("table"),k="style=\" "+g+A+" padding-bottom:20px;\"";m.innerHTML="\t\t\t<tr>\t\t\t\t<th>FREE</th><th>PREMIUM</th>\t\t\t</tr>\t\t\t<tr>\t\t\t\t<td "+f+">\t\t\t\t\t<div "+k+">\t\t\t\t\t\t<sup>$</sup><big><big><b>0</b></big></big>/mo\t\t\t\t\t</div>\t\t\t\t\t<div>\t\t\t\t\t\t<ul>\t\t\t\t\t\t\t<li><span "+C+">\u2713</span> All Features</li>\t\t\t\t\t\t</ul>\t\t\t\t\t</div>\t\t\t\t</td>\t\t\t\t<td "+f+">\t\t\t\t\t<div "+k+">\t\t\t\t\t\tFrom <sup>$</sup><big><big><b>3.33</b></big></big>/mo\t\t\t\t\t</div>\t\t\t\t\t<div>\t\t\t\t\t\t<ul>\t\t\t\t\t\t\t<li><span "+C+">\u2713</span> All Features</li>\t\t\t\t\t\t\t<li><span "+C+">\u2713</span> No Ads <a href=\"//www.photopea.com/promo/no_ads.png\" target=\"_blank\">\uD83D\uDC41</a></li>\t\t\t\t\t\t\t<li><span "+C+">\u2713</span> 2\xD7 more steps in history</li> \t\t\t\t\t\t\t<li><span "+C+">\u2713</span> quick <a href=\"mailto:support@photopea.com\">email support</a></li> \t\t\t\t\t\t</ul>\t\t\t\t\t\t<span style=\"margin:10px 0 12px 0; font-size:0.75em;\">* No subscription, just one-time payments</span> \t\t\t\t\t\t\t\t\t\t\t</div>\t\t\t\t</td>\t\t\t</tr>\t\t";
w.appendChild(m);var U=new iP("Go Premium");U.e.setAttribute("style",l+"padding:10px 0;");U.h("click",function(X){this.s8(1)},this);
m.children[0].children[1].children[1].appendChild(U.e);this.K1=e.t("div");w.appendChild(this.K1);w=j[1];
var z=this.aAn=[[9,30,1],[10,90,1],[40,365,1],[15,30,5],[30,90,5],[120,365,5],[50,30,20],[100,90,20],[400,365,20],[100,30,50],[200,90,50],[800,365,50],[40,30,1e3],[80,90,1e3],[300,365,1e3],[100,30,5e3],[200,90,5e3],[700,365,5e3],[200,30,2e4],[400,90,2e4],[1400,365,2e4]];
this.Wi=[];for(var L=0;L<z.length;L++)this.Wi.push(new iP("Buy: $"+z[L][0],!1,null,!0));for(var L=0;
L<this.Wi.length;L++){this.Wi[L].h("click",this.agl,this)}this.ze=new iP("...",!0);this.ze.e.setAttribute("style",l);
w.appendChild(this.ze.e);m=this.auq(4,["Single user",this.Wi[0],this.Wi[1],this.Wi[2],"Team of 5",this.Wi[3],this.Wi[4],this.Wi[5],"Team of 20",this.Wi[6],this.Wi[7],this.Wi[8],"Team of 50",this.Wi[9],this.Wi[10],this.Wi[11]]);
w.appendChild(m);this.av5=new b7("I accept",!0,"");w.appendChild(this.av5.e);this.DC=new iP([0,13,1],!1,null,!0);
this.DC.h("click",this.arv,this);w.appendChild(this.DC.e);this.Mt=new iP("I have a key",!1,null,!0);
this.Mt.e.setAttribute("style",l+" float:right; width:inherit;");this.Mt.h("click",this.agl,this);w.appendChild(this.Mt.e);
w=j[2];this.L5=new cv;this.L5.parent=this;this.L5.h(b.E.A,this.pk,this);w.appendChild(this.L5.e);w=j[3];
this.NI=new iP("...",!0);this.NI.e.setAttribute("style",l);w.appendChild(this.NI.e);m=this.auq(3,["1000 views/mo",this.Wi[s++],this.Wi[s++],this.Wi[s++],"5000 views/mo",this.Wi[s++],this.Wi[s++],this.Wi[s++],"20000 views/mo",this.Wi[s++],this.Wi[s++],this.Wi[s++]]);
w.appendChild(m);var O=e.t("p");O.innerHTML="Insert Photopea into your webpage, with no ads, under your own brand \t\t... <a href=\"https://www.photopea.com/api/accounts#distributors\" target=\"_blank\" style=\"color:inherit;\">More</a>";
w.appendChild(O);this.NS=new e7("Domain name (e.g. domain.com)",null,14);w.appendChild(this.NS.e);var a=new iP("Save Domain Settings",!1,null,!0);
a.d3();w.appendChild(a.e);a.h("click",this.awH,this)};jU.IY.prototype=new eg;jU.IY.prototype.s8=function(w){var n=typeof w=="number"?w:this.sb.indexOf(w.target);
for(var L=0;L<4;L++)this.sb[L].style.opacity=.6;this.sb[n].style.opacity=1;e._g(this.xq);this.xq.appendChild(this.a5$[n])};
jU.IY.prototype.zl=function(w,n){var W=w<600?"d":" days",D=["30 days","90 days","365 days"];if(w<600)D=["30d","90d","365d"];
var j=this.aAn;for(var L=0;L<j.length;L++){this.Wi[L].wV("<span>"+D[L%3]+": <sup>$</sup><big><b>"+j[L][0]+"</b></big>"+"</span>");
this.Wi[L].e.setAttribute("style",this.aoq)}};jU.IY.prototype.arv=function(w){var n=new ed("showpage",!0);
n.data={p_:1};this.S(n)};jU.IY.prototype.a9E=function(w){var n=new ed("showpage",!0);n.data={p_:2};this.S(n)};
jU.IY.prototype.f=function(){this.u5.wV(bh.bH()?fV.get([0,11]):fV.get([0,10]));this.DC.f();this.ta.f();
this.fr.f()};jU.IY.prototype.ahG=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.aT,link:"https://www.photopea.com/api/accounts#"+(w.target==this.adn?"teams":"distributors")};
this.S(n)};jU.IY.prototype.avE=function(w){var n=w.currentTarget==this.a24;this.a24.$(n);this.ayd.$(!n)};
jU.IY.prototype.anf=function(w){var n=this.a24.b(),W=this.asv.b().trim().toLowerCase(),D=this.a52.value.trim().toLowerCase();
if(W.length>60){alert("Too long email address");return}if(D.length>600){alert("Too many team members");
return}D=D.split(",").join(" ").trim();D=D.replace(/\s+/g," ");if(D=="")D=[];else D=D.split(" ");var j=bh.bl();
if(j==null)j={};if(j.acc==null)j.acc={};j.acc.team={jin:n,ldr:W,mmb:D};bh.qK(j,this.pk.bind(this));alert("Saved!");
this.mQ()};jU.IY.prototype.awH=function(w){var n=this.NS.b().trim();if(!bh.bH()){alert("You have to log in first.");
return}if(bh.LD()==0){alert("Order a distributor account first.");return}var W=bh.bl();if(W==null)W={};
if(W.acc==null)W.acc={};if(n=="")delete W.acc.dname;else W.acc.dname=n;bh.qK(W,this.pk.bind(this));alert("Saved!");
this.mQ()};jU.IY.prototype.axG=function(w){var n=bh.rE(),L=this.ev,W=bh.bl();if(W==null)W={};if(W.acc==null)W.acc={};
W.acc.bto=w;bh.qK(W,function(){});var D=jU.aj4(w.split("\n"),n.pmnts[L]);e8.save(D,"photopea_invoice.pdf")};
jU.IY.prototype.a4X=function(w){var n=bh.rE(),W=bh.bl(),D=W.acc?W.acc.bto:null;if(D==null)D=n.name+"\n"+n.email;
var L=-1,j=w.target.e.parentNode;while((j=j.previousSibling)!=null)L++;this.ev=L;var I=new ed(b.E.L,!0);
I.data={d:b.c.P2,jW:"billto",Z1:D,FJ:this.axG.bind(this)};this.S(I)};jU.IY.prototype.mQ=function(){this.dd.innerHTML="";
e._g(this.K1);if(bh.bH()){var w=bh.rE(),n=w.pmnts;if(w==null)return;this.dd.innerHTML="<span style=\"font-size:1.5em; margin-right:0.7em;\">"+w.name+"</span> "+w.email+" <br/>";
if(n){var W="<h2>Payments</h2>";for(var L=0;L<n.length;L++){var D=n[L],j=new Date(D[0]*1e3);W+="<div style=\"font-size:1.2em\">"+j.getDate()+". "+(j.getMonth()+1)+". "+j.getFullYear()+" - "+jU.a9x(D)+"</div>"}this.K1.innerHTML=W;
for(var L=0;L<n.length;L++){var I=new iP("Get Invoice",!1,null,!0);I.e.setAttribute("style","float:right");
I.h("click",this.a4X,this);this.K1.children[L+1].appendChild(I.e)}}}else{}var U=bh.bH()&&bh.d$();this.ze.e.style.display=U?"block":"none";
if(U){var M,m,l=U;if(l[0]==0){M=bh.RW(l[1])-Date.now()*(1/1e3);m=l[1][2]==1?"Single User":"Team Of "+l[1][2]}else{M=l[1][1]-Date.now()*(1/1e3);
m="Member of \""+l[1][0]+"\""}this.ze.wV("Premium active for "+Math.round(M/(60*60*24))+" more days! ("+m+")")}var A=bh.bH()&&bh.LD()*1e3>Date.now();
this.NI.e.style.display=A?"block":"none";if(A){var M=bh.LD()-Date.now()/1e3;this.NI.wV("Distributor active for "+Math.round(M/(60*60*24))+" more days!")}var g=bh.bl();
this.L5.mQ();if(g&&g.acc&&g.acc.dname)this.NS.$(g.acc.dname);else this.NS.$("")};jU.IY.prototype.auq=function(w,n){var W=e.t("table");
if(!0){var D="<table><tr>";for(var L=0;L<w;L++)D+="<th>"+n[L*4]+"</th>";D+="</tr></table>";W.innerHTML=D;
for(var L=0;L<3;L++){var j=e.t("tr"),I;W.appendChild(j);for(var U=0;U<w;U++){I=e.t("td");I.style.width=Math.round(100/w)+"%";
j.appendChild(I);I.appendChild(n[U*4+1+L].e)}}}return W};jU.IY.prototype.agl=function(w){var n=this.Wi.indexOf(w.currentTarget),D=30,j=1;
if(!bh.bH()){this.uB();return}if(this.av5.b()==!1&&n<12){alert("You must accept Terms of Service");return}var W=bh.bH()&&bh.d$();
if(n!=-1){var I=this.aAn[n];D=I[1];j=I[2]}if(W&&j<1e3){alert("You already have premium.");return}console.log(I,D,j);
if(n==-1){var U=prompt("Please enter your key");if(U!=null){bh.auj(U,this.pk.bind(this));this.j0()}return}if(D==30&&j==1){var M=confirm("You can have a 90 days version for $10. Do you still want a 30 days version for $9?");
if(!M)return}bh.order(D,j,this.pk.bind(this));this.j0()};jU.IY.prototype.pk=function(w){this.mQ();this.j0()};
jU.IY.prototype.uB=function(w){if(bh.bH()){bh.aqh();this.j0();this.mQ(null,null,null)}else bh.uB(this.afa.bind(this))};
jU.IY.prototype.afa=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.a2u};this.S(w)};jU.IY.prototype.j0=function(){var w=new ed(b.E.L,!0);
w.data={d:b.c.aA1};this.S(w)};jU.lu=function(w){eg.call(this);this.e=e.t("div");var n=this.e,W=this.a3B=new iP([0,13,2],!1,null,!0),D;
W.h("click",this.afx,this);n.appendChild(W.e);if(w.startsWith("::")){D=e.t("iframe");D.setAttribute("style","width:100%;height:1700px; background-color:white;");
D.setAttribute("src",w.slice(2))}else{D=e.t("div");D.innerHTML=w}n.appendChild(D)};jU.lu.prototype=new eg;
jU.lu.prototype.afx=function(w){var n=new ed("showpage",!0);n.data={p_:0};this.S(n)};jU.lu.prototype.f=function(){this.a3B.f()};
jU.alZ="\t\t<h1>Contact</h1>\t\t<p>Photopea.com is operated by Ivan Kuckir (I\u010C 04498411, Tax ID CZ9011014309).</p>\t\t<ul>\t\t\t<li><b>Address</b>: H\xE1lkova 483, 517 41 Kostelec nad Orlic\xED, Czech Republic</li>\t\t\t<li><b>E-mail</b>: support@photopea.com, <b>Phone number</b>: +420 604 592 737</li>\t\t</ul>\t\t<h1>Refund Policy</h1>\t\t<p>You can ask for a refund by writing us an email to support@photopea.com and. \t\tWe offer only one kind of service, and if you have been refunded in the past, you can not get another refund.\t\t</p>\t\t<h1>Terms of Delivery</h1>\t\t<p>You can pay with a debit or a credit card. Payments are processed instantly, your Premium account will be activated instantly.</p>\t\t<h1>Payment Provider</h1>\t\t<p>Payments are provided by <a style=\"color:white\" href=\"https://www.comgate.cz/cz/platebni-brana\">ComGate pamyments, a.s</a>.</p>\t\t<ul>\t\t\t<li>ComGate Payments, a.s.</li>\t\t\t<li>Go\u010D\xE1rova t\u0159\xEDda 1754 / 48b, Hradec Kr\xE1lov\xE9</li>\t\t\t<li>E-mail: platby-podpora@comgate.cz, Tel: +420 228 224 267</li>\t\t</ul>\t\t<img src=\"https://www.comgate.cz/files/platebni-brana-comgate-paticka-e-shopu.png\" />\t";
jU.a9x=function(w){return"Photopea "+(w[1]<1e3?"Premium":"Distributor")+" ("+w[1]+" days, "+w[2]+" user"+(w[2]==1?"":"s")+")"};
jU.aj4=function(w,n){w=["Bill To:"].concat(w);var W=new ToPDF,D=595,j=842,I=40,U=18,M=12,m=500,l=100,A=400,f=0;
function g(G,V,T,R,x){$.font.Tf=x?"Helvetica-Bold":"Helvetica";$.ctm=[1,0,0,1,V,T];$.font.Tfs=R?R:M;
W.PutText($,G,0)}function k(G,V,T,R){for(var L=0;L<G.length;L++){g(G[L],V,T-L*R,null,L==0)}}var $=UDOC.getState();
W.StartPage(0,0,D,j);g("INVOICE",D-I-140,j-I-30,30,!0);k(["Bill From:","Ivan Kuckir","H\xE1lkova 483, 517 41 Kostelec nad Orlic\xED","Tax ID: CZ9011014309"],I,j-I-40,U);
var C=new Date(n[0]*1e3);k(["Date: "+C.getDate()+". "+(C.getMonth()+1)+". "+C.getFullYear(),"Transaction ID: "+n[4]],D-I-140,j-I-40-U*2,U);
var z=w.join("");for(var L=0;L<z.length;L++)f=Math.max(f,z.charCodeAt(L));if(f>256){var s=4,O=e.t("canvas"),a=O.getContext("2d"),X=0;
a.font=M*s+"px sans-serif";for(var L=0;L<w.length;L++)X=Math.max(X,a.measureText(w[L]).width);var P=Math.round(X)+20,Z=w.length*s*U+20;
O.width=P;O.height=Z;a.font=M*s+"px sans-serif";for(var L=0;L<w.length;L++){a.font=(L==0?"bold ":"")+M*s+"px sans-serif";
a.fillText(w[L],10,(L+1)*s*U)}document.body.appendChild(O);var Y=new Uint8Array(a.getImageData(0,0,P,Z).data.buffer);
$.ctm=[P/s,0,0,Z/s,I-10/s,j-I-40-100-Z/s];W.PutImage($,Y,P,Z);$.ctm=[1,0,0,1,0,0]}else k(w,I,j-I-40-100,U);
$.colr=[.8,.8,.8];$.pth={cmds:["M","L","L","L","Z"],crds:[I,m,D-I,m,D-I,m-U,I,m-U]};W.Fill($);$.colr=[0,0,0];
var K=[I,m,D-I,m,I,m-U,D-I,m-U,I,m-l,D-I,m-l,I,m,I,m-l,D-I,m,D-I,m-l,A,m,A,m-l],S=[];for(var L=0;L<K.length;
L+=4)S.push("M","L");$.pth={cmds:S,crds:K};W.Stroke($);g("Order details",I+4,m-14);g(jU.a9x(n),I+4,m-U-14);
g("TOTAL:",I+4,m-l-14,null,!0);g("Price",D-I-50,m-14);g(n[3]+" USD",D-I-60,m-U-14);g(n[3]+" USD",D-I-60,m-l-14,null,!0);
g("www.Photopea.com",I,I);g("support@photopea.com",D-I-130,I);W.ShowPage();W.Done();return W.buffer};
function fk(){dB.call(this,[11,14],"addguides");this.tI;this.ww={M3:{Lf:0}};this.Y8=null;var w=e.t("div","form");
this.body.appendChild(w);this.PT=[];this.Hz=new j$(null,["Hi"]);w.appendChild(this.Hz.e);e.x$(w);this.Hz.h(b.E.A,this.w$,this);
this.Ai=new e7([22,4,0],null,16);this.Ai.h(b.E.A,this.A5,this);this.qi=new e7([22,4,1],null,16);this.qi.h(b.E.A,this.A5,this);
this.mc=new i0(null,E.f_.Ph);this.mc.h(b.E.A,this.A5,this);w.appendChild(this.Ai.e);w.appendChild(this.mc.e);
e.x$(w);w.appendChild(this.qi.e);this.QK=e.bp(this,w);this.h("closebtn",this.ka,this)}fk.prototype=new dB;
fk.prototype.X7=function(w,n){return w!=null};fk.prototype.wb=function(){return!0};fk.prototype.f=function(){dB.prototype.f.call(this);
this.Ai.f();this.qi.f();this.mc.f();this.QK.f()};fk.prototype.GZ=function(w,n){var W=w.M3.Lf;this.ww.M3.Lf=W;
this.mc.$(W)};fk.prototype.mQ=function(w,n){this.tI=w;this.Y8=JSON.stringify(w.Iw());this.PT=[-1];var W=["Global"],D=w.root.children,j=w.H2();
for(var L=0;L<D.length;L++){var I=D[L].j;if(I.add.artb){W.push(I.getName());this.PT.push(D[L].index)}}this.Hz.TF(W);
this.Hz.$(this.PT.indexOf(j));this.w$()};fk.prototype.w$=function(){var w=this.tI,n=w.Iw(),W=this.PT[this.Hz.b()],D=[0,0];
if(W!=-1){var j=w.C[W].yP();D=[j.x,j.y]}var I=function(U,M,w,m,l){var A=U[0],g=[];for(var L=0;L<A.length;
L++)if(U[1][L]==W&&A[L][0]==M)g.push(E.f_.BE(A[L][1]-D[M],w.hh,m,l));g.sort(function(k,$){return k-$});
return g.join(", ")};this.Ai.$(I(n,0,w,this.ww,w.m));this.qi.$(I(n,1,w,this.ww,w.n))};fk.prototype.A5=function(w){if(w&&w.currentTarget==this.mc)this.ww.M3.Lf=this.mc.b();
else{var n=this.aoM(),W=this.tI;W.Pu(n);W.RP=!0}this.w$()};fk.prototype.aoM=function(){var w=this.tI,n=w.Iw(),W=this.PT[this.Hz.b()],D=[0,0];
if(W!=-1){var j=w.C[W].yP();D=[j.x,j.y]}var I=[];for(var U=0;U<2;U++){var M=U==0?this.Ai:this.qi,m=U==0?this.tI.m:this.tI.n,l=M.b().replace(/,/g," ").replace(/ +/g," ").trim(),A=l==""?[]:l.split(" ");
for(var L=0;L<A.length;L++)I.push([U,E.f_.aq8(A[L],this.tI.hh,this.ww,m)+D[U]])}for(var L=0;L<n[0].length;
L++)if(n[1][L]==W){n[0].splice(L,1);n[1].splice(L,1);L--}for(var L=0;L<I.length;L++){n[0].push(I[L]);
n[1].push(W)}return n};fk.prototype.ka=function(w){var n=this.tI;n.Pu(JSON.parse(this.Y8));n.RP=!0;this.tI=null};
fk.prototype.j8=function(w){this.A5(w);var n=new ed(b.E.v,!0);n.G=y.Rv;n.data={d:"gids",l3:JSON.parse(this.Y8),Qh:this.tI.Iw()};
this.tI=null;this.close();this.S(n)};function fe(w){dB.call(this,{pdfpres:"PDF Presentation",cformat:"Convert Formats"}[w],w);
this.ww=null;var n=e.t("div","form");this.body.appendChild(n);n.setAttribute("style","width:300px");
this.Lk=new aH("Source Images",!0,!0);n.appendChild(this.Lk.e);this.ec=new i0([12,14,0],["A4 Portrait","A4 Lanscape",[12,93,3],"Adapt to images"]);
this.zG=new b7("Order images by name");this.zG.$(!0);var W=this.avq=jj.pg();for(var L=0;L<W.length;L++)if(jj.ZO(W[L]).Xq){W.splice(L,1);
L--}W.push("SVG","PDF");this.lP=new i0([12,50],W);this.ii=new kv;this.lP.h(b.E.A,this.XQ,this);if(w=="pdfpres"){n.appendChild(this.ec.e);
n.appendChild(this.zG.e)}else{n.appendChild(this.lP.e);n.appendChild(this.ii.e)}var D=["VAR0 PDF",[1,8]];
if(w=="cformat")D="Convert Images";var j=new iP(D,!0,null,!0);j.h("click",this.GW,this);n.appendChild(j.e);
this.XQ()}fe.prototype=new dB;fe.prototype.XQ=function(w){var n=this.avq[this.lP.b()];this.ii.Pe(n)};
fe.prototype.GW=function(w){var n=this.Lk.b(),W=[],I=595,U=842,M=40;for(var D in n)W.push(D);if(W.length==0){alert("No images selected");
return}if(this.zG.b())W.sort();var j=this.ec.b(),m=new ToPDF,l=UDOC.getState(),A=this.avq[this.lP.b()],g=jj.ZO(A),k=this.ii.b(),$={};
for(var L=0;L<W.length;L++){var D=W[L],C=n[D],f=C[0]==255,z=jj.zJ(C.buffer),s=jj.ZO(z),O={XL:new iB,data:new ArrayBuffer(0)},a=null;
if(z=="psd"&&!g.Xq)O=gg.ajL(C.buffer)[0];else if(s.Xq){a=new kc("file.psd");s.Vu(C.buffer,a);a.X0();
if(!g.Xq){if(a.XW)aj.yf(a,this.ww.hY,this);a.l();a.tw();O={XL:new iB(0,0,a.m,a.n),data:a.Vc().buffer}}}else O=s.Vu(C.buffer)[0];
var X=O.XL,P=new Uint8Array(O.data),Z=X.m,Y=X.n;if(this.id=="pdfpres"){var K=[[595,842],[842,595],[595,595],[595,0]][j];
if(j==3)K[1]=Math.round(K[0]*Y/Z);var I=K[0],U=K[1],S=Math.min(I/Z,U/Y);m.StartPage(0,0,I,U);l.ctm=[Z*S,0,0,Y*S,(I-Z*S)/2,(U-Y*S)/2];
m.PutImage(l,f?C:P,Z,Y);m.ShowPage()}else{var G=D.split("."),V;G.pop();G.push(A.toLowerCase());if(g.Xq)V=g.La(a,I.m,a.n,k,this.ww);
else V=g.La([[P.buffer]],Z,Y,k);$[G.join(".")]=new Uint8Array(V)}}if(this.id=="pdfpres"){m.Done();e8.save(m.buffer,"file.pdf")}else{e8.save(UZIP.encode($),"images.zip")}};
fe.prototype.GZ=function(w,n){this.ww=w};fe.prototype.f=function(){dB.prototype.f.call(this);this.Lk.f();
this.ec.f();this.zG.f()};function jk(w){var n=cx.names[w];if(n==null)n=eH.names[w];if(w=="aply")n=[2,12];
if(w=="fade")n=[2,11];if(w=="matc")n=[4,18];if(w=="blendOptions")n=[14,10];dB.call(this,n,"afw_"+w);
this.su=w;this.PX=null;this.S9=null;this.ZN=new gu[w];this.ZN.h(b.E.A,this.FI,this);this.ZN.parent=this;
this.body.appendChild(this.ZN.e);this.hW=new b7([24,18,5]);this.hW.$(!0);this.hW.h(b.E.A,this.FI,this);
this.M1=new iP([1,12,2],!0,null,!0);this.M1.h("click",this.b0,this);this.QK=e.bp(this);if(this.Uz())this.ZN.$A(this.QK.e);
else{e.W0(this.ZN.e,"form");e.W0(this.body,"flexrow");this.ZN.e.setAttribute("style","width:312px");
var W=e.t("div");this.body.appendChild(W);W.setAttribute("style","width:8em; margin-left:1em; line-height:2.3em");
W.appendChild(this.QK.e);W.appendChild(this.M1.e);W.appendChild(this.hW.e)}this.h("closebtn",this.$S,this)}jk.prototype=new dB;
jk.prototype.wb=function(){return!0};jk.prototype.Uz=function(){return this.ZN!=null&&this.ZN.Fn()};
jk.prototype.aP=function(){return this.Uz()?new ec(0,0):dB.prototype.aP()};jk.prototype.tZ=function(){return this.ZN.tZ()};
jk.prototype.WQ=function(w,n,W,D,j){this.ZN.WQ(w,n,W,D,j)};jk.prototype.QD=function(w,n,W,D,j){this.ZN.QD(w,n,W,D,j)};
jk.prototype.H5=function(w,n,W,D,j){this.ZN.H5(w,n,W,D,j)};jk.prototype.X7=function(w,n){if(this.su=="fade")return jk.a0W(w);
return!0};jk.prototype.b0=function(w){this.ZN.$(cx._1(this.su));this.FI()};jk.prototype.FI=function(w){this.f8({d:"edit",jB:this.ZN.b(),vv:!this.hW.b()})};
jk.prototype.$S=function(w){this.f8({d:"cancel"})};jk.prototype.j8=function(w){if(!this.hW.b()){this.hW.$(!0);
this.FI()}this.S9=this.ZN.b();if(this.Uz())this.FI();this.f8({d:"confirm"});this.close()};jk.prototype.f=function(){dB.prototype.f.call(this);
this.hW.f();if(this.ZN)this.ZN.f();this.QK.f()};jk.prototype.GZ=function(w,n){if(this.ZN)this.ZN.GZ(w,n)};
jk.prototype.oe=function(w,n,W,D){if(this.Uz())this.ZN.oe(D);else dB.prototype.oe.call(this,w,n,W,D)};
jk.prototype.mQ=function(w,n,W,D){this.PX=n.PX;var j=w.add.lnk2?w.add.lnk2:[],I,U,M=new iB(0,0,w.m,w.n),m=w.C[w.g[0]],l=null;
I=m.buffer;U=m.rect;if(this.Uz())l=w.Vc(w.g[0]-1);var A=cx._1(this.su),g=[j,w.yo,w,W];if(n.PX==null){this.ZN.$(A,I,U,M,l,g);
if(eH.names[this.su]){if(D.U(aK.PJ)&&this.S9)this.ZN.$(this.S9);var k=y.CY.getData(w),$=E.Bk(k[0].Ey);
this.ZN.pH($)}}else{var C=!1,m=w.C[this.PX.j];if(m.YC()){var f=m.NP(w);I=f.buffer;U=f.rect;var z=m.add.SoLd.filterFX.v.filterFXList.v;
if(z[this.PX.index]){var s=z[this.PX.index].v;this.ZN.$(this.su=="blendOptions"?s.blendOptions.v:s.Fltr.v,I,U,M,l,g);
this.ZN.pH(E.Bk(I));C=!0}}if(!C){this.ZN.$(A,I,U,M,l,g);this.ZN.pH(E.Bk(I))}}if(!this.Uz()){this.FI();
var O=this.ZN;if(O&&O.pE&&O.pE[0]&&O.pE[0].Me)O.pE[0].Me()}};jk.prototype.f8=function(w){var n=new ed(b.E.v,!0);
w.su=this.su;w.PX=this.PX;n.data=w;n.G=cx.names[this.su]||this.PX?y.sT:y.DW;n.HH=!0;this.S(n)};jk.prototype.zl=function(w,n){if(!this.ZN.Fn()){}else{this.body.style.padding="0";
this.ZN.zl(w,n)}};jk.a0W=function(w){if(w==null)return!1;var n=w.by();if(n==null||!(n.data instanceof Array)||n.data.length!=w.g.length)return!1;
for(var L=0;L<n.data.length;L++){var W=n.data[L];if(W.j<0&&w.yo[-1-W.j])return!0;if(W.j==null||w.C[W.j]==null||w.C[W.j].eL!=W.vi)return!1;
if(w.g.indexOf(W.j)==-1)return!1}return!0};function fo(){dB.call(this,[11,0],"camera");this.data=null;
this.EE=new ec(1,1);this.a45=[];var w=e.t("div","form hbar");this.body.appendChild(w);this.a6g=new i0(null,[]);
this.v2=new i0([21,0],[[21,2],[21,1]]);w.appendChild(this.v2.e);this.Na=new i0(null,[]);this.Na.h(b.E.A,this.azM,this);
w.appendChild(this.Na.e);this.Zh=new iP([11,0],!1,null,!0);this.Zh.h("click",this.asH,this);w.appendChild(this.Zh.e);
this.e3=new ga("");w.appendChild(this.e3.e);this.stream=null;this.D3=e.t("video","");this.D3.setAttribute("autoplay","true");
this.body.appendChild(this.D3);this.avd=this.ak$.bind(this);this.adx=this.a7c.bind(this);this.afA=this.aaZ.bind(this);
this.h("closebtn",this.aAc,this)}fo.prototype=new dB;fo.prototype.f=function(){dB.prototype.f.call(this);
this.v2.f();this.Zh.f();this.zl(this.gA,this.ag)};fo.prototype.Vc=function(){var w=this.D3.videoWidth,n=this.D3.videoHeight,W=e.t("canvas","");
W.width=w;W.height=n;var D=W.getContext("2d");D.drawImage(this.D3,0,0,w,n);var j=D.getImageData(0,0,w,n);
return{XL:new iB(0,0,w,n),data:j.data.buffer}};fo.prototype.asH=function(w){if(this.v2.b()==0)this.aeH();
else this.aop()};fo.prototype.aop=function(){var w=this.Vc(),n={buffer:new Uint8Array(w.data),rect:w.XL},W=new ed(b.E.v,!0);
W.HH=!0;W.G=y.Yu;W.data={d:h.nS,qH:n};this.S(W);alert(fV.get([21,4]))};fo.prototype.aeH=function(){var w=this.Vc(),n=jj.Dk("camera",[w]),W=new ed(b.E.L,!0);
W.data={d:b.c.dH,On:n};this.S(W);alert(fV.get([21,5]))};fo.prototype.mQ=function(w,n,W){navigator.mediaDevices.enumerateDevices().then(this.aeG.bind(this))};
fo.prototype.aeG=function(w){var n=this.a45=[],W=[];for(var L=0;L<w.length;L++)if(w[L].kind=="videoinput"){n.push(w[L]);
W.push("Camera "+n.length)}this.Na.TF(W);this.Na.$(0);this.azM()};fo.prototype.azM=function(w){this.aAc();
var n={video:{deviceId:this.a45[this.Na.b()].deviceId,width:{ideal:8e3},height:{ideal:8e3}}};if(navigator.mediaDevices.getUserMedia)navigator.mediaDevices.getUserMedia(n).then(this.avd).catch(this.adx);
else navigator.webkitGetUserMedia(n,this.avd,this.adx)};fo.prototype.ak$=function(w){this.stream=w;this.D3.srcObject=w;
this.D3.addEventListener("loadedmetadata",this.afA,!1)};fo.prototype.aaZ=function(w){this.D3.play();
this.zl(this.gA,this.ag)};fo.prototype.aP=function(w,n){return new ec(0,0)};fo.prototype.zl=function(w,n){var W=this.D3.videoWidth,D=this.D3.videoHeight;
this.e3.$(W+" x "+D+" px");this.e3.e.setAttribute("style","position:absolute; left:14px; bottom:10px; z-index:1;");
this.EE.y1(W,D);this.gA=w;this.ag=n;var j=w-28,I=n-28-30,U=this.EE.x/this.EE.y;if(j/I>U)j=I*U;else I=j/U;
this.D3.setAttribute("style","display: block; width: "+Math.round(j)+"px; height:"+Math.round(I)+"px;")};
fo.prototype.a7c=function(w){console.log("error",w);alert(fV.get([21,6]));this.close()};fo.prototype.aAc=function(w){if(this.stream!=null){var n=this.stream.getTracks();
for(var L=0;L<n.length;L++)n[L].stop();this.stream=null}};function cR(){dB.call(this,[7,8],"crange");
this.tI=null;this.ox={zP:73,dl:4.45,k:4};this.Fb={zP:73,dl:4.45,k:4};this.body.style.width="20em";this.y6=new i0([0,5],["Sampled Colors",[19,6,0],[19,6,1],[19,6,2]]);
this.y6.h(b.E.A,this.a0C,this);this.body.appendChild(this.y6.e);this.Bz=e.t("div","form");this.body.appendChild(this.Bz);
var w=this.ay2=2,n=this.ZW=[new eu([12,92],0,200),new j$([12,36],[[18,0],"\uFF0B","-"]),new eu([12,92],0,100,"%"),new g_("Min",0,255),new g_("Max",0,255)];
n[0].$(40);n[w].$(40);for(var L=0;L<n.length;L++){n[L].h(b.E.A,this.Uc,this);n[L].parent=this}this.T=e.t("canvas");
this.body.appendChild(this.T);this.QK=e.bp(this,this.body)}cR.prototype=new dB;cR.prototype.X7=function(w,n){return w!=null};
cR.prototype.tZ=function(){return!0};cR.prototype.wb=function(){return!0};cR.prototype.a0C=function(w){var n=this.y6.b(),W=this.ZW,D=this.Bz,j=0,I=W.length,U=this.ay2;
if(n==0)I=U;else{j=U;W[j+1].$([0,100,190][n-1]);W[j+1].G3(n!=1);W[j+2].$([60,150,255][n-1]);W[j+2].G3(n!=3)}e._g(D);
for(var L=j;L<I;L++){D.appendChild(W[L].e)}this.Uc()};cR.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();this.y6.f();for(var L=0;L<this.ZW.length;L++)this.ZW[L].f()};cR.prototype.WQ=function(w,n,W,D,j){var I=w.u.Cg(j.x,j.y);
this.avI(I.x,I.y)};cR.prototype.avI=function(w,n){var W=Math.min,D=Math.max,j=this.tI,I=D(0,W(j.m-1,Math.floor(w))),U=D(0,W(j.n-1,Math.floor(n))),M=j.Vc(),m=(U*j.m+I)*4,l=M[m],A=M[m+1],g=M[m+2],k=E.gK(l,A,g),$=this.ZW[1].b(),C=this.ox,f=this.Fb;
if($==0){this.ox=JSON.parse(JSON.stringify(k));this.Fb=k}else if($==1){C.zP=W(C.zP,k.zP);C.dl=W(C.dl,k.dl);
C.k=W(C.k,k.k);f.zP=D(f.zP,k.zP);f.dl=D(f.dl,k.dl);f.k=D(f.k,k.k)}else if($==2){var z=(C.zP+f.zP)/2,s=(C.dl+f.dl)/2,O=(C.k+f.k)/2;
if(k.zP<z)C.zP=D(C.zP,k.zP+10);else f.zP=W(f.zP,k.zP-10);if(k.dl<s)C.dl=D(C.dl,k.dl+1);else f.dl=W(f.dl,k.dl-1);
if(k.k<O)C.k=D(C.k,k.k+1);else f.k=W(f.k,k.k-1)}this.Uc()};cR.prototype.j8=function(w){var n=this.y6.b(),W=this.ZW,D={__name:"Color Range",classID:"ClrR",colorModel:{t:"long",v:0}};
if(n==0){var j=this.ox,I=this.Fb;D.Mnm={t:"Objc",v:{classID:"LbCl",Lmnc:{t:"doub",v:j.zP},A:{t:"doub",v:j.dl},B:{t:"doub",v:j.k}}};
D.Mxm={t:"Objc",v:{classID:"LbCl",Lmnc:{t:"doub",v:I.zP},A:{t:"doub",v:I.dl},B:{t:"doub",v:I.k}}};D.Fzns={t:"long",v:W[0].b()}}else{n--;
var U=["shadows","midtones","highlights"][n];D.Clrs={t:"enum",v:{Clrs:["Shdw","Mdtn","Hghl"][n]}};if(0<n)D[U+"LowerLimit"]={t:"long",v:W[3].b()};
if(n<2)D[U+"UpperLimit"]={t:"long",v:W[4].b()};D[U+"Fuzziness"]={t:"long",v:W[2].b()}}this.close();var M=new ed(b.E.W1,!0);
M.data={hZ:"colorRange",E3:D};this.S(M)};cR.prototype.mQ=function(w,n){this.tI=w;this.avI(0,0);this.a0C()};
cR.prototype.Uc=function(){var w=this.tI,n=this.y6.b(),W=this.ox,D=this.Fb,j=this.ZW,I=j[0].b()/200,U=!1;
if(n>0){W=j[3].b();D=j[4].b();if(W>=D)W=D-1;U=!0;I=j[2].b()/100}var M=y.eZ.zk(w,W,D,I,U),m=M.rect,l=M.channel,A=this.T,g=A.getContext("2d"),k=Math.floor(230*e.V()),$=Math.floor(k*(m.n/m.m));
A.width=k;A.height=$;e.UE(A,k,$);var C=E.Q(l.length*4);E.cJ(C,4294967295);for(var L=0;L<3;L++)E.IL(l,C,L);
var f=y.wR.lD([C,m],new eh(k/m.m,0,0,$/m.n,0,0)),z=f.rect,s=new ImageData(new Uint8ClampedArray(f.buffer.buffer),z.m,z.n);
g.putImageData(s,0,0)};function kx(){dB.call(this,[12,76,1],"createshape");this.n_=null;var w=e.t("div","form");
w.setAttribute("style","width:20em");this.body.appendChild(w);this.Yx=new dZ(!0,!0,null,!0,!0);this.Yx.$(new ec(100,100));
w.appendChild(this.Yx.e);this.HX=new b7([19,5,3]);w.appendChild(this.HX.e);this.QK=e.bp(this,w)}kx.prototype=new dB;
kx.prototype.j8=function(w){var n=this.Yx.b();this.n_.agJ(this.n_.atn,n.x,n.y,this.HX.b());this.close()};
kx.prototype.f=function(){if(this.n_)this.II=fV.get([5,3])+": "+fV.get(this.n_.aan);dB.prototype.f.call(this);
this.QK.f();this.Yx.f();this.HX.f()};kx.prototype.mQ=function(w,n){this.n_=n;this.f();this.Yx.$(this.Yx.b(),w.hh)};
function cQ(){dB.call(this,[11,1],"colorpicker");this.ZF=null;this.L$=null;this.Ri=null;this.xt=!1;this.en=!1;
this.af$=[.9642,1,.8249];var w=e.t("div","flexrow"),U,M;this.body.appendChild(w);this.yQ=new bL(256,!0);
this.yQ.h(b.E.A,this.g5,this);w.appendChild(this.yQ.e);var n=e.t("div","form");n.setAttribute("style","width:14.5em; margin-left:1em;");
w.appendChild(n);var W=e.t("div","flexrow");n.appendChild(W);var D=e.t("div");W.appendChild(D);D.style="width:95px; margin-right:14px";
this.a8S=e.t("div","full");D.appendChild(this.a8S);this.asB=e.t("div","full");D.appendChild(this.asB);
var D=e.t("col");W.appendChild(D);D.style.width="80px";this.QK=e.bp(this,D);var W=e.t("div","flexrow");
n.appendChild(W);var j=e.t("div"),I=e.t("div");W.appendChild(j);W.appendChild(I);j.style=I.style="margin-left:14px; max-width:80px;";
U=["H","S","B"];M=j;this.js=[];for(var L=0;L<3;L++){var m=0,l=360,A="\xB0";if(L!=0){l=100;A="%"}var g=new g_(U[L],m,l,A,0,!1,!0);
this.js.push(g);g.h(b.E.A,this.agz,this);M.appendChild(g.e);if(L==2)g.e.style.marginBottom="8px"}U=["R","G","B"];
M=j;this.Nh=[];for(var L=0;L<3;L++){var g=new g_(U[L],0,255,null,0,!1,!0);this.Nh.push(g);g.h(b.E.A,this.afK,this);
M.appendChild(g.e)}U=["L","a","b"];M=I;this.NM=[];for(var L=0;L<3;L++){var m=[0,-128,-128][L],l=[100,127,127][L],g=new g_(U[L],m,l,null,0,!1,!0);
g.$(0);this.NM.push(g);g.h(b.E.A,this.aoY,this)}U=["C","M","Y","K"];M=I;this.DA=[];for(var L=0;L<4;L++){var g=new g_(U[L],0,100,"%",0,!1,!0);
g.$(0);this.DA.push(g);g.h(b.E.A,this.azJ,this);M.appendChild(g.e);if(L==3)g.e.style.marginBottom="8px"}this.Ai=new e7("#",null,4.5);
this.Ai.h(b.E.A,this.U_,this);I.appendChild(this.Ai.e);this.Ai.e.style.marginRight="0";this.DN=e.t("input","fitem");
this.DN.setAttribute("type","color");this.DN.setAttribute("style","width:59px; margin-left:19px;");
this.DN.addEventListener("change",this.U_.bind(this),!1);I.appendChild(this.DN);this.kE=new ai(9);this.kE.h(b.E.A,this.U_,this);
n.appendChild(this.kE.e);this.h("closebtn",this.$S,this);this.Z$=!1}cQ.prototype=new dB;cQ.prototype.tZ=function(){return!0};
cQ.prototype.aP=function(w,n){return new ec(Math.max(0,Math.min(150,(w-484)/2)),Math.max(0,Math.min(150,(n-316)/2)))};
cQ.prototype.zl=function(w,n){this.yQ.zl(Math.min(256,w-226),n)};cQ.prototype.f=function(w,n){dB.prototype.f.call(this);
for(var L=0;L<3;L++){this.Nh[L].f();this.js[L].f();this.NM[L].f()}for(var L=0;L<4;L++)this.DA[L].f();
this.QK.f()};cQ.prototype.g5=function(w){this.L$=this.yQ.b();this.update()};cQ.prototype.WQ=function(w,n,W,D,j){this.Z$=!0;
this.a7w(w,j)};cQ.prototype.QD=function(w,n,W,D,j){if(!this.Z$)return;this.a7w(w,j)};cQ.prototype.H5=function(w,n,W,D,j){this.Z$=!1};
cQ.prototype.a7w=function(w,n){var W=y.Mi.B4(w,n,1),D=W&255,j=W>>8&255,I=W>>16&255;this.L$={o:I/255,B:j/255,k:D/255};
this.update()};cQ.prototype.afK=function(w){var n=this.Nh,W=this.Hx(parseInt(n[0].b())),D=this.Hx(parseInt(n[1].b())),j=this.Hx(parseInt(n[2].b()));
this.L$={o:W/255,B:D/255,k:j/255};this.update()};cQ.prototype.agz=function(w){var n=this.js,W=this.e0(parseInt(n[0].b())/360),D=this.e0(parseInt(n[1].b())/100),j=this.e0(parseInt(n[2].b())/100);
this.L$=E.li(W,D,j);this.update()};cQ.prototype.azJ=function(w){var n=this.DA,W=[];for(var L=0;L<4;L++){var D=this.avD(parseInt(n[L].b()));
n[L].$(D);W.push(D/100)}var j=E.aN(W);this.L$={o:j[0],B:j[1],k:j[2]};this.update(!0)};cQ.prototype.aoY=function(w){var n=this.NM,W=parseInt(n[0].b()),D=parseInt(n[1].b()),j=parseInt(n[2].b()),I=E.kH(W,D,j);
this.L$={o:I.o/255,B:I.B/255,k:I.k/255};this.update()};cQ.prototype.U_=function(w){var n;if(w.currentTarget==this.kE)n=this.kE.b();
else{n=w.currentTarget==this.Ai?this.Ai.b():this.DN.value;if(n.charAt(0)=="#")n=n.slice(1);if(n.length==3)n=n[0]+n[0]+n[1]+n[1]+n[2]+n[2];
n=E.lO(n)}this.L$={o:(n>>16&255)/255,B:(n>>8&255)/255,k:(n&255)/255};this.update()};cQ.prototype.j_=function(w){var n=w.o,W=w.B,D=w.k;
return Math.round(n*255)<<16|Math.round(W*255)<<8|Math.round(D*255)};cQ.prototype.j8=function(w){this.a0s();
var n=this.j_(this.L$);this.Ri(n);this.close();this.en=!1;this.L$=null};cQ.prototype.$S=function(w){this.a0s();
if(this.xt)this.Ri(this.j_(this.ZF));this.en=!1;this.L$=null};cQ.prototype.a0s=function(w){var n=new ed(b.E.L,!0);
n.data={d:b.c.a7X};this.S(n)};cQ.prototype.GZ=function(w,n){var W=ku.qr(w,n);if(W!=null)this.kE.$(W);
if(n!=bk.X$)return;if(this.L$!=null){this.L$={o:(W>>16&255)/255,B:(W>>8&255)/255,k:(W>>0&255)/255};this.update()}};
cQ.prototype.mQ=function(w,n){var W=n.pL,D={o:(W>>16&255)/255,B:(W>>8&255)/255,k:(W>>0&255)/255};if(this.L$==null){var j=new ed(b.E.L,!0);
j.data={d:b.c.ph,In:"crosshair",push:!0};this.S(j);this.Z$=!1;this.Ri=n.fT;this.xt=!1;this.en=n.NG;this.ZF=JSON.parse(JSON.stringify(D));
this.asB.setAttribute("style","height:2.3em;background-color:#"+E.$$(W)+";")}this.L$=D;this.update()};
cQ.prototype.update=function(w){var n=this.L$,W=this.j_(n);this.Ai.$(E.$$(W));this.DN.value="#"+E.$$(W);
this.a8S.setAttribute("style","height:2.3em;background-color:#"+E.$$(W)+";");var D=this.Nh;D[0].$(Math.round(n.o*255));
D[1].$(Math.round(n.B*255));D[2].$(Math.round(n.k*255));var j=E.i8(n.o,n.B,n.k);D=this.js;D[0].$(Math.round(j.ag*360));
D[1].$(Math.round(j._6*100));D[2].$(Math.round(j.jB*100));var I=E.gK(n.o*255,n.B*255,n.k*255,this.af$);
D=this.NM;D[0].$(Math.round(I.zP));D[1].$(Math.round(I.dl));D[2].$(Math.round(I.k));if(w==null){var U=E.apV([n.o,n.B,n.k]);
D=this.DA;D[0].$(Math.round(U[0]*100));D[1].$(Math.round(U[1]*100));D[2].$(Math.round(U[2]*100));D[3].$(Math.round(U[3]*100))}this.yQ.$(n);
if(this.en){this.Ri(this.j_(this.L$));this.xt=!0}};cQ.prototype.avD=function(w){return Math.max(0,Math.min(100,w))};
cQ.prototype.Hx=function(w){return Math.max(0,Math.min(255,w))};cQ.prototype.e0=function(w){return Math.max(0,Math.min(1,w))};
function eW(){dB.call(this,[11,2],"contoureditor");this.a7Y=null;this.Hs=null;this.response=null;this.GN=e.t("div","cell");
this.body.appendChild(this.GN);this.fU=e.t("div","cell padded");this.body.appendChild(this.fU);var w=e.t("div","bordered padded vmargin");
this.GN.appendChild(w);this.ZN=new dA(null,null,!0);this.ZN.h(b.E.A,this.$y,this);w.appendChild(this.ZN.e);
this.QK=e.bp(this,this.fU);this.h("closebtn",this.oz,this)}eW.prototype=new dB;eW.prototype.j8=function(){this.close()};
eW.prototype.f=function(){dB.prototype.f.call(this);this.QK.f();this.ZN.f()};eW.prototype.$y=function(w){this.Hs.Crv.v=this.ZN.b();
this.response(this.Hs)};eW.prototype.oz=function(w){this.response(this.a7Y)};eW.prototype.mQ=function(w,n){this.a7Y=JSON.parse(JSON.stringify(n.xq));
this.Hs=n.xq;this.response=n.response;this.ZN.$(this.Hs.Crv.v)};function dH(){dB.call(this,[11,3],"csize");
this.uO=0;this.xG=e.t("div","form");this.xG.setAttribute("style","width:22em; margin-bottom:1em;");this.body.appendChild(this.xG);
this.Yx=new dZ(!0,!0,!0,!0,!0);this.Yx.apS(!1);this.xG.appendChild(this.Yx.e);this.gE=new j$("Align with",[[8,7,0],[12,6]]);
this.gE.h(b.E.A,this.aqp,this);this.Ds=new dl([12,23,2],41);this.xG.appendChild(this.Ds.e);this.Ds.$(4);
this.ok=new aw(!1);this.ok.ajg(new ec(0,0));this.QK=e.bp(this,this.body)}dH.prototype=new dB;dH.prototype.X7=function(w,n){return w!=null};
dH.prototype.wb=function(){return!0};dH.prototype.wO=function(w){return[aK.z5,aK.i$,aK.Fe,aK.I$].indexOf(w)!=-1};
dH.prototype.oe=function(w,n,W,D){if(D.U(aK.yG))this.j8();this.Ds.azi(D.aa())};dH.prototype.aqp=function(){var w=[this.Ds.e,this.ok.e];
this.xG.removeChild(w[this.uO]);this.uO=this.gE.b();this.xG.appendChild(w[this.uO])};dH.prototype.f=function(){dB.prototype.f.call(this);
this.Yx.f();this.gE.f();this.Ds.f();this.ok.f();this.QK.f()};dH.prototype.j8=function(w){var n=this.Yx.b(),W=n.x,D=n.y,j=new ed(b.E.W1,!0);
j.data=y.QJ.a94(W,D,this.Ds.b());this.close();this.S(j)};dH.prototype.mQ=function(w,n){this.Yx.$(new ec(w.m,w.n),w.hh);
this.Yx.Me()};function iS(){dB.call(this,[11,4],"duplinto");this.Pk=null;this.BV=null;this._Q=null;var w=e.t("div","form");
w.setAttribute("style","max-width:26em");this.body.appendChild(w);this.Vq=new i0([12,43],["abc","def"]);
this.Vq.h(b.E.A,this.bX,this);w.appendChild(this.Vq.e);e.x$(w);this.tk=new i0([1,16,0],["abc","def"]);
this.tk.h(b.E.A,this.bX,this);w.appendChild(this.tk.e);e.x$(w);this.aG=new e7([12,48],null,14);w.appendChild(this.aG.e);
this.QK=e.bp(this,w)}iS.prototype=new dB;iS.prototype.wb=function(){return!0};iS.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();this.Vq.f();this.aG.f()};iS.prototype.bX=function(w){if(w&&w.target==this.tk)return;var n=this.Vq.b(),W=this.BV[n],D=this.Pk,j=W!=null&&W.add.artd!=null;
for(var L=0;L<D.g.length;L++)if(D.C[D.g[L]].add.artb)j=!1;this.aG.G3(n==this.BV.length);this.tk.G3(j);
if(j){var I=W.root.children,U=[],M=this._Q=[];for(var L=0;L<I.length;L++){var m=I[L].j;if(m.add.artb)U.push(m.getName());
M.push(I[L].index)}this.tk.TF(U);this.tk.$(0)}else this._Q=null};iS.prototype.mQ=function(w,n,W){this.Pk=w;
this.BV=W;this.aG.$(w.g.length==0?"Layer":w.C[w.g[0]].getName());var D=[];for(var L=0;L<W.length;L++){var j=W[L].name;
D.push(j.length<30?j:j.slice(0,27)+"...")}D.push([11,7]);this.Vq.TF(D);this.Vq.$(W.indexOf(w));this.bX(null)};
iS.prototype.j8=function(w){var n=this.Vq.b();if(n==this.BV.length){var W=new kc(this.aG.b()+".psd"),D=this.Pk.m,j=this.Pk.n,I=this.Pk.H2();
if(I!=-1){var U=this.Pk.C[I].yP();D=U.m;j=U.n}W.m=D;W.n=j;W.buffer=E.Q(W.m*W.n*4);var M=W.QI();M.nz("Background");
W.Gd([M]);var m=new ed(b.E.L,!0);m.HH=!0;m.data={d:b.c.dH,On:W};this.S(m)}var l=this.Pk.Jr(null,this.Pk!=this.BV[n]),m=new ed(b.E.v,!0);
m.data={d:h.jF,C:l,Wv:this.Pk,SY:this.BV[n]};if(this._Q)m.data.sR=this._Q[this.tk.b()];m.G=y.Yu;m.HH=!0;
this.S(m);this.close()};function hx(){dB.call(this,[1,9],"eassets");this.ww=null;this.yV=null;var w=this.body;
e.W0(w,"form");w.style.width="32em";this.y6=new j$(null,["Layers","Combinations"]);this.y6.h(b.E.A,this.w$,this);
w.appendChild(this.y6.e);e.R2(w);this.mz=e.t("span");w.appendChild(this.mz);this.Kv=e.t("div");w.appendChild(this.Kv);
var n=e.t("div"),W=e.t("div","flexrow");this.ale=[n,W];this.nn=[new b7("Only layers / folders, whose name starts with \"-e-\""),new b7("Remove parts outside the canvas"),new b7("Trim transparent parts")];
for(var L=0;L<3;L++){var D=this.nn[L];D.$(!0);D.h(b.E.A,this.w$,this);n.appendChild(D.e);e.x$(n)}this.nC=new jw([12,14,0],["1x","2x","3x","4x"]);
this.nC.$([!0,!1,!1,!1]);n.appendChild(this.nC.e);var j=e.t("div");W.appendChild(j);var I=e.t("img");
I.setAttribute("src","img/nft.png");I.style.width="150px";W.appendChild(I);var U=e.t("span");U.textContent="File Names:";
j.appendChild(U);this.lU=new jw(null,["1-0-1.XYZ","head1-eyes0-mouth1.XYZ","red-green-brown.XYZ"],!1,null,!0);
j.appendChild(this.lU.e);this.lU.$([!0,!1,!1]);e.R2(w);this._M=["PNG","JPG","SVG","TIFF","TGA"];this.m3=new i0([12,50],this._M);
this.m3.h(b.E.A,this.XQ,this);w.appendChild(this.m3.e);this.ii=new kv;w.appendChild(this.ii.e);this.QK=new iP([1,9],!0,null,!0);
this.QK.h("click",this.j8,this);w.appendChild(this.QK.e);this.h("closebtn",this.gI,this)}hx.prototype=new dB;
hx.prototype.XQ=function(w){this.ii.Pe(this._M[this.m3.b()],!1,!1,!1,this.yV.EY()!=null)};hx.prototype.gI=function(w){this.yV=null};
hx.prototype.f=function(){dB.prototype.f.call(this);this.m3.f();this.nC.f();this.QK.f();this.ii.f()};
hx.prototype.mQ=function(w,n,W){this.yV=w;this.w$()};hx.prototype.w$=function(w){var n=this.y6.b(),W;
e._g(this.Kv);this.Kv.appendChild(this.ale[n]);if(n==0){var D=this.a0d();W=D.length+" exportable layers"}else{var D=this.ab4();
W=D[1]+" combinations ("+D[0].join(" \xD7 ")+")"}this.mz.textContent="- - - "+W;this.XQ(null)};hx.prototype.a0d=function(){var w=this.nn[0].b(),n=[],W=this.yV;
for(var L=0;L<W.C.length;L++){var D=W.C[L],j=D.getName();if(!w&&!D.ue()&&!D.rect.VY()||j.startsWith("-e"))n.push(L)}return n};
hx.prototype.ab4=function(){var w=this.yV,n=w.root.children,W=[],D=1,j=[];for(var L=0;L<n.length;L++){var I=n[L],U=I.j;
if(U.ue()){var M=I.children.length;W.push(M);D*=M;j.push(I.index)}U}return[W,D,j]};hx.prototype.GZ=function(w,n){this.ww=w};
hx.prototype.j8=function(w){var n=this.yV,W=this.y6.b(),D=[this._M[this.m3.b()]],j=[this.ii.b()],I={};
if(W==0){var U=this.nC.b(),M={},m=this.a0d();if(m.length==0){alert("No layers to export.");return}var l=[this.nn[1].b(),this.nn[2].b()];
for(var L=0;L<m.length;L++){var g=m[L],k=n.C[g],$=k.getName();if(M[$]!=null){M[$]++;$+=" "+M[$]}else M[$]=1;
var C=k.I4();k.gb(!0);for(var f=0;f<U.length;f++){if(!U[f])continue;var z=f+1,s=y.mU.akQ(n,D,z,this.ww,g,j,l);
for(var O=0;O<D.length;O++){var a=D[O],X=$.slice($.startsWith("-e-")?3:0)+(z==1?"":"@"+z+"x")+"."+a.toLowerCase();
if(s[O])I[X]=new Uint8Array(s[O])}}k.gb(C)}}else{var C=[];for(var L=0;L<n.C.length;L++)C.push(n.C[L].I4());
var P=this.ab4(),Z=P[0],m=P[2],Y=[];function K(T,g,R,x){if(g==T.length){x.push(R.slice(0));return}var v=T[g];
for(var L=0;L<v;L++){R.push(L);K(T,g+1,R,x);R.pop(L)}}K(Z,0,[],Y);var S=this.lU.b().indexOf(!0);this.pY=[Y,I,m,D,j,C,S,this.aoe.bind(this),0,0];
this.aoe();return}var G=UZIP.encode(I),V=new ed(b.E.L,!0);V.data={d:b.c.pA,data:G,name:"assets.zip"};
this.S(V)};hx.prototype.aoe=function(){var w=this.pY,n=w[0],W=w[1],D=this.yV,j=w[2],I=w[3],U=w[4],M=w[5],m=w[6],l=w[7],g=0;
while(n.length!=0&&g<1e3){var k=Date.now(),$=n.shift(),C=[];for(var L=0;L<$.length;L++){var f=D.root.fs(j[L]);
for(var z=0;z<f.children.length;z++)f.children[z].j.gb(!1);var s=f.children[$[L]].j;C.push(m==2?s.getName():f.j.getName()+$[L]);
s.gb(!0)}D.l();D.tw();var O=(m==0?$:C).join("-")+"."+I[0].toLowerCase();W[O]=new Uint8Array(jj.rk(D,I[0],D.m,D.n,U[0],this.ww));
w[8]++;w[9]+=W[O].length;g+=Date.now()-k}if(n.length!=0){alert(w[8]+" done, "+fp.cN(w[9])+".",800);setTimeout(l,35);
return}for(var L=0;L<D.C.length;L++)D.C[L].gb(M[L]);D.l();var a=UZIP.encode(W),X=new ed(b.E.L,!0);X.data={d:b.c.pA,data:a,name:"assets.zip"};
this.S(X)};function bd(){dB.call(this,"Export Color Lookup Tables","exlut");this.ww=null;this.yV=null;
var w=e.t("div","form");w.setAttribute("style","width:20em");this.body.appendChild(w);this.nn=[new g_("Grid Points",1,256),new j$([12,50],[".CUBE"])];
var n=[16,0];for(var L=0;L<this.nn.length;L++){var W=this.nn[L];W.$(n[L]);W.parent=this;W.h(b.E.A,this.w$,this);
w.appendChild(W.e);e.x$(w)}this.QK=e.bp(this,w);this.h("closebtn",this.gI,this)}bd.prototype=new dB;
bd.prototype.X7=function(w,n){if(Math.min(w.m,w.n)<16){alert("The document must be at least 16 x 16 pixels.",3200);
return!1}if(w.C.length<2){alert("There must be a background layer and some adjustment layers.",3200);
return!1}return!0};bd.prototype.gI=function(w){this.yV=null};bd.prototype.GZ=function(w,n){this.ww=w};
bd.prototype.mQ=function(w,n,W){this.yV=w};bd.prototype.j8=function(){var w=this.yV,n=this.nn[0].b(),W=[],D=new iB(0,0,w.m,w.n),j=E.Q(n*n*4),I=j.slice(0),U=new iB(w.m-n>>>1,w.n-n>>>1,n,n),M=w.C[0],m=M.buffer,l=M.rect;
M.rect=U;M.buffer=j;for(var A=0;A<n;A++){this.a6Y(n,A,j);M.l(U);w.l(U);var g=w.Vc();E.Cb(g,D,I,U);for(var k=0;
k<n;k++)for(var $=0;$<n;$++){var C=k*n+$<<2;W.push(I[C]/255,I[C+1]/255,I[C+2]/255)}}var f=jF.aia(W,n,w.name);
e8.save(f,w.name.split(".")[0]+".CUBE");M.buffer=m;M.rect=l;M.l();w.l()};bd.prototype.a6Y=function(w,n,W){var D=255/(w-1),j=Math.round(n*D);
for(var I=0;I<w;I++)for(var U=0;U<w;U++){var M=I*w+U<<2;W[M]=Math.round(U*D);W[M+1]=Math.round(I*D);
W[M+2]=j;W[M+3]=255}};bd.prototype.f=function(){dB.prototype.f.call(this);for(var L=0;L<this.nn.length;
L++)this.nn[L].f();this.QK.f()};function ao(){dB.call(this,[1,14],"finfo");this.BM=null;this._C=null;
this.jV=null;this.xG=e.t("div","form scrollable label12");this.xG.setAttribute("style","width:35em; height:38em; margin-bottom:8px");
this.body.appendChild(this.xG);var w=e.t("div","form");this.body.appendChild(w);this.Ck=new i0(null,["Hello"]);
w.appendChild(this.Ck.e);this.az3=new iP("Add Parameter",!1,null,!0);w.appendChild(this.az3.e);this.az3.h("click",this.p7,this);
this.Id=new iP("=== S A V E ===",!1,null,!0);w.appendChild(this.Id.e);this.Id.h("click",this.lZ,this);
this.a5q=""}ao.prototype=new dB;ao.prototype.aP=function(w,n){return w<450||n<450?new ec(0,0):new ec(150,100)};
ao.prototype.p7=function(w){if(this.jV.length==0)return;var n=this.jV[this.Ck.b()],W=this.o9();W[n]=fd.g4[n][0];
this.e2(W);this._C[n].e.scrollIntoView();this._C[n].Me()};ao.prototype.g1=function(w){var n=this.o9();
delete n[w.currentTarget.ada];this.e2(n)};ao.prototype.lZ=function(w){var n=this.o9(),W=this.BM,D=!0;
for(var j in W)if(JSON.stringify(W[j])!=JSON.stringify(n[j]))D=!1;for(var j in n)if(JSON.stringify(W[j])!=JSON.stringify(n[j]))D=!1;
if(D)return;var I=new ed(b.E.v,!0);I.G=y.Yu;I.data={d:h.NU,Hb:n};this.S(I);this.BM=n;this.e2(n)};ao.a5k=function(w){function n(j){var I=j.toLowerCase();
return j==I}var W=w.split(":").pop();for(var D=1;D<W.length-1;D++){if(W[D]==W[D].toUpperCase()&&(n(W[D+1])||n(W[D-1]))){W=W.slice(0,D)+" "+W.slice(D);
D++}}return W};ao.prototype.mQ=function(w,n){this.BM=w.Zp;this.e2(w.Zp)};ao.prototype.e2=function(w){var n=this.xG,j=0;
e._g(n);var W=this._C={},D=["tiff","exif","exif:GPS"],I=this.jV=[],U=[];for(var M in fd.g4){var m=ao.a5k(M),l=0,A=15,g=null;
if(w[M]==null){if(fd.g4[M].length!=1||M=="photoshop:Credit"||M=="photoshop:Source"){I.push(M);U.push(m)}continue}for(var L=0;
L<D.length;L++)if(M.startsWith(D[L]))l=L;if(l!=j){e.R2(n);j=l}if(M=="tiff:ImageDescription"||M=="dc:Keywords"){A=18.5;
g=3}var k=new e7(m,null,A,g);W[M]=k;var $=w[M];if($ instanceof Array)$=$[1]==0?"---":$[0]+"/"+$[1];var C=new iP("\u2716",null,fV.get([5,4]));
n.appendChild(C.e);C.h("click",this.g1,this);C.ada=M;k.$($);n.appendChild(k.e);e.x$(n);if(M=="exif:GPSLongitude"&&w["exif:GPSLatitude"]){this.a5q=ao.apc(w["exif:GPSLatitude"])+","+ao.apc(w["exif:GPSLongitude"]);
var f=new iP("Show on map",!1,null,!0);n.appendChild(f.e);e.x$(n);f.h("click",this.a1N,this)}}this.Ck.TF(U);
this.Ck.$(0)};ao.prototype.o9=function(){var w=this._C,n=fd.g4,W={};for(var D in n){var j=n[D][0],I=typeof j;
if(j==null||w[D]==null)continue;var U=w[D].b(),M="The value of \""+ao.a5k(D)+"\" must ";if(I=="number"){U=parseFloat(U);
if(isNaN(U)){alert(M+"be a number.");U=j}}else if(j instanceof Array&&j.length==2){if(U.indexOf("/")==-1){alert(M+"be a fraction.");
U=j.slice(0)}else{U=U.split("/").map(parseFloat);if(isNaN(U[0])||isNaN(U[1])){U=j.slice(0)}}}W[D]=U}return W};
ao.apc=function(w){var n=w.length,W=w.slice(0,n-1).split(",").map(parseFloat),D=w.slice(n-1),j=W[0]+W[1]/60+W[2]/3600;
if(D!="N"&&D!="E")j=-j;return j};ao.prototype.a1N=function(w){window.open("https://maps.google.com?q="+this.a5q,"Map")};
function cV(){dB.call(this,[11,5],"gradienteditor");this.ZF=null;this.L$=null;this.n8=null;this.Ri=null;
this.xt=!1;this.en=!1;this.tz=null;this.Ax=null;this.Hv=-1;this.Fy=-1;this.Ju=0;this.vW=this.n$.bind(this);
this.VB=this.KJ.bind(this);this.T=e.t("canvas");this.VE=this.T.getContext("2d");this.T.setAttribute("style","display:block");
this.A8=null;e.ZS(this.T);e.L_(this.T,this.WI.bind(this));this.Zm=e.t("div","form");this.hs=e.t("div");
this.YZ=e.t("div","form");this.Vm=e.t("div");this.ki=new i0([12,44],[[15,10,0],[24,6]]);this.ki.h(b.E.A,this.iG,this);
this.body.appendChild(this.ki.e);e.R2(this.body);var w=this.Zm;this.s5=new g_([19,3,3],0,100,"%");this.s5.h(b.E.A,this.iG,this);
this.s5.parent=this;w.appendChild(this.s5.e);e.x$(w);this.N6=new ga([12,0]);w.appendChild(this.N6.e);
this.UL=e.t("div","bordered padded noalign");w.appendChild(this.UL);this.Z8=new g_([12,0],0,100,"%");
this.Z8.parent=this;this.Z8.h(b.E.A,this.iG,this);this.UL.appendChild(this.Z8.e);this.cI=new g_([12,40],0,100,"%");
this.cI.parent=this;this.cI.h(b.E.A,this.iG,this);this.UL.appendChild(this.cI.e);this.Ho=new iP([5,4],!1,null,!0);
this.Ho.h("click",this.afL,this);this.UL.appendChild(this.Ho.e);w.appendChild(this.hs);this.apQ=new ga([13,0]);
w.appendChild(this.apQ.e);this.o6=e.t("div","bordered padded noalign");w.appendChild(this.o6);this.lK=new i0([12,44],[[12,45],[12,46],[12,47]]);
this.lK.h(b.E.A,this.iG,this);this.o6.appendChild(this.lK.e);this.$D=new gM(!0);this.$D.parent=this;
this.$D.h(b.E.A,this.iG,this);this.o6.appendChild(this.$D.e);this.Jn=new g_([12,40],0,100,"%");this.Jn.parent=this;
this.Jn.h(b.E.A,this.iG,this);this.o6.appendChild(this.Jn.e);this.JS=new iP([5,4],!1,null,!0);this.JS.h("click",this.abi,this);
this.o6.appendChild(this.JS.e);var w=this.YZ;this.iD=new g_("Roughness",0,100,"%");this.iD.h(b.E.A,this.iG,this);
this.iD.parent=this;w.appendChild(this.iD.e);w.appendChild(this.Vm);this.NH=new iP([25,1,2],!1,null,!0);
this.NH.h("click",this.iG,this);w.appendChild(this.NH.e);this.QK=e.bp(this);this.h("closebtn",this.$S,this)}cV.prototype=new dB;
cV.prototype.$S=function(w){if(this.xt)this.Ri(this.ZF)};cV.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();this.s5.f();this.N6.f();this.apQ.f();this.Ho.f();this.JS.f();this.Z8.f();this.cI.f();this.lK.f();
this.Jn.f();this.NH.f()};cV.prototype.GZ=function(w,n){this.n8=w};cV.prototype.mQ=function(w,n){this.L$=JSON.parse(JSON.stringify(n.M));
this.ZF=JSON.parse(JSON.stringify(n.M));this.tz=this.Ax=null;this.Ri=n.fT;this.xt=!1;this.en=n.NG;this.T5();
this.Nm()};cV.prototype.j8=function(w){var n=this.L$;this.Ri(n);this.close()};cV.prototype.wO=function(w){return w==aK.m2||w==aK.on};
cV.prototype.oe=function(w,n,W,D){if(D.U(aK.m2)||D.U(aK.on)){if(this.Ax)this.afL();if(this.tz)this.abi()}};
cV.prototype.afL=function(w){var n=this.L$.Trns.v;if(this.Ax==null||n.length==1)return;n.splice(n.indexOf(this.Ax),1);
this.Ax=null;this.T5();this.Nm()};cV.prototype.abi=function(w){var n=this.L$.Clrs.v;if(this.tz==null||n.length==1)return;
n.splice(n.indexOf(this.tz),1);this.tz=null;this.T5();this.Nm()};cV.prototype.T5=function(){var w=this.T,n=this.VE,W=e.V();
w.width=Math.floor(410*W);w.height=Math.floor(70*W);e.UE(w,w.width,w.height);w.style.marginTop="8px";
this.A8=new iB(0,0,Math.floor(380*W),Math.floor(32*W));this.A8.x=Math.floor((w.width-this.A8.m)/2);this.A8.y=Math.floor((w.height-this.A8.n)/2);
var D=this.A8,j=D.m,I=D.n,U=D.x,M=D.y,m=new iB(0,0,j,I),l=n.getImageData(0,0,j,I),A=new Uint8Array(l.data.buffer);
E.b6(A,j,I,8);var g=E.Q(j*I*4);E.M.Yd(this.L$,g,m,[1/j,0,0,1/I],j/2,I/2,!1,0,this.n8.Gp,this.n8.as);
E.s._U("norm",g,D,A,D,D,1);n.clearRect(0,0,w.width,w.height);n.putImageData(l,U,M);var k=this.L$;if(k.Clrs){var $=k.Trns.v,C=k.Clrs.v,f=E.M.oR(k,this.n8.Gp,this.n8.as),z=Math.round(6*e.V()),s=Math.round(14*e.V()),O=this.Ax?this.Ax.v:null,a=this.tz?this.tz.v:null;
for(var L=0;L<$.length;L++){var X=$[L].v,P=Math.round(255-255*X.Opct.v.val/100);if((X==O||$[L-1]&&$[L-1].v==O||L==this.Fy)&&L!=0){n.fillStyle="#000000";
n.fillRect(U-3+j*($[L-1].v.Lctn.v+(X.Lctn.v-$[L-1].v.Lctn.v)*X.Mdpn.v/100)/4096,M-6-2,6,6)}if(X==O){n.fillStyle="#ffffff";
n.fillRect(U-z+j*(X.Lctn.v/4096)-2,M-2-s-2,2*z+4,s+4)}n.fillStyle="rgb("+P+","+P+","+P+")";n.fillRect(U-z+j*(X.Lctn.v/4096),M-2-s,2*z,s)}for(var L=0;
L<C.length;L++){var Z=C[L].v,Y=f[0][L][0];if((Z==a||C[L-1]&&C[L-1].v==a||L==this.Hv)&&L!=0){n.fillStyle="#000000";
n.fillRect(U-3+j*(C[L-1].v.Lctn.v+(Z.Lctn.v-C[L-1].v.Lctn.v)*Z.Mdpn.v/100)/4096,M+I+2,6,6)}if(Z==a){n.fillStyle="#ffffff";
n.fillRect(U-z+j*(Z.Lctn.v/4096)-2,M+I+2-2,2*z+4,s+4)}n.fillStyle="rgb("+Math.round(Y.o)+", "+Math.round(Y.B)+","+Math.round(Y.k)+")";
n.fillRect(U-z+j*(Z.Lctn.v/4096),M+I+2,2*z,s)}}if(this.en){this.Ri(this.L$);this.xt=!0}};cV.prototype.Nm=function(){var w=this.L$,n=w.Clrs?0:1;
this.ki.$(n);if(e.LY(this.Zm))this.body.removeChild(this.Zm);if(e.LY(this.YZ))this.body.removeChild(this.YZ);
(n==0?this.hs:this.Vm).appendChild(this.T);if(n==0){this.body.appendChild(this.Zm);this.s5.$(Math.round(100*w.Intr.v/4096));
var W=w.Trns.v,D=w.Clrs.v,j=this.Ax!=null,I=this.Fy!=-1;this.Z8.G3(j);this.cI.G3(j||I);this.Ho.G3(j);
if(j){this.UL.setAttribute("style","");var U=this.Ax.v;this.cI.$(Math.round(100*U.Lctn.v/4096));this.Z8.$(U.Opct.v.val)}if(I)this.cI.$(W[this.Fy].v.Mdpn.v);
var j=this.tz!=null,I=this.Hv!=-1;this.lK.G3(j);this.$D.G3(j);this.Jn.G3(j||I);this.JS.G3(j);if(j){this.o6.setAttribute("style","");
var M=this.tz.v;this.Jn.$(Math.round(100*M.Lctn.v/4096));var m=M.Type.v.Clry;this.lK.$(["FrgC","BckC","UsrS"].indexOf(m));
if(m=="FrgC")this.$D.hR(this.n8.Gp);if(m=="BckC")this.$D.hR(this.n8.as);if(m=="UsrS")this.$D.$(M.Clr.v)}if(I)this.Jn.$(D[this.Hv].v.Mdpn.v)}else{this.body.appendChild(this.YZ);
this.iD.$(Math.round(100*w.Smth.v/4096))}this.body.appendChild(this.QK.e)};cV.prototype.iG=function(w){var n=this.L$,W=n.Clrs?0:1;
if(w.target==this.ki){var D=W==0?JSON.parse(at._V.abX).v:cx._1("grdm").Grad.v;this.L$=D;this.Nm();this.T5();
return}if(W==0){n.Intr.v=Math.round(4096*this.s5.b()/100);var j=n.Trns.v,I=n.Clrs.v;if(this.Ax!=null){var U=this.Ax.v;
U.Lctn.v=Math.round(4096*(this.cI.b()/100));U.Opct.v.val=this.Z8.b()}if(this.tz!=null){var M=this.tz.v;
M.Lctn.v=Math.round(4096*(this.Jn.b()/100));if(w.target==this.$D)this.lK.$(2);var m=this.lK.b();M.Type.v.Clry=["FrgC","BckC","UsrS"][m];
if(m==2)M.Clr={t:"Objc",v:this.$D.b()};else if(M.Clr)delete M.Clr}if(this.Fy!=-1)j[this.Fy].v.Mdpn.v=this.cI.b();
if(this.Hv!=-1)I[this.Hv].v.Mdpn.v=this.Jn.b()}else{n.Smth.v=Math.round(4096*this.iD.b()/100);if(w.target==this.NH)n.RndS.v=Math.floor(Math.random()*4294967295)}this.T5()};
cV.prototype.WI=function(w){var n=e.rv(w,this.T),W=this.A8,D=(n.x*e.V()-W.x)/W.m,j=(n.y*e.V()-W.y)/W.n,I=this.L$.Trns.v,U=this.L$.Clrs.v,M=null,m=null,l=-1,A=-1;
if(j<1)for(var L=0;L<I.length;L++){var g=I[L].v;if(Math.abs(g.Lctn.v/4096-D)<.02)M=I[L];if(L>0)if(Math.abs((I[L-1].v.Lctn.v+(g.Lctn.v-I[L-1].v.Lctn.v)*g.Mdpn.v/100)/4096-D)<.01)l=L}if(j>0)for(var L=0;
L<U.length;L++){var k=U[L].v;if(Math.abs(k.Lctn.v/4096-D)<.02)m=U[L];if(L>0)if(Math.abs((U[L-1].v.Lctn.v+(k.Lctn.v-U[L-1].v.Lctn.v)*k.Mdpn.v/100)/4096-D)<.01)A=L}if(m==null&&M==null&&l==-1&&A==-1){if(j<0){var g={t:"Objc",v:{classID:"TrnS",Opct:{t:"UntF",v:{type:"#Prc",val:100}},Lctn:{t:"long",v:0},Mdpn:{t:"long",v:50}}};
g.v.Lctn.v=Math.round(D*4096);I.push(g);I.sort(this.Vf);M=g}if(j>1){var U=this.L$.Clrs.v,$=E.M.oR(this.L$,this.n8.Gp,this.n8.as),C=E.M.Hj(this.L$,$,D),k={t:"Objc",v:{classID:"Clrt",Clr:{t:"Objc",v:E.M.lW({o:C&255,B:C>>8&255,k:C>>16&255})},Type:{t:"enum",v:{Clry:"UsrS"}},Lctn:{t:"long",v:0},Mdpn:{t:"long",v:50}}};
k.v.Lctn.v=Math.round(D*4096);U.push(k);U.sort(this.Vf);m=k}}if(m!=null)A=-1;if(M!=null)l=-1;if(m!=null||M!=null||l>-1||A>-1){this.Ax=M;
this.tz=m;this.Fy=l;this.Hv=A;this.Nm();this.T5();e.Ko(window,this.vW);e.d6(window,this.VB)}};cV.prototype.n$=function(w){var n=e.rv(w,this.T),W=this.A8,D=(n.x*e.V()-W.x)/W.m,j=(n.y*e.V()-W.y)/W.n;
D=Math.max(0,Math.min(1,D));var I=this.L$.Trns.v,U=this.L$.Clrs.v;if(this.Ax!=null){var M=this.Ax.v;
M.Lctn.v=Math.round(4096*D);var m=I.indexOf(this.Ax);if(m!=-1&&j<-1&&I.length>1)I.splice(m,1);if(m==-1&&j>-1)I.push(this.Ax);
I.sort(this.Vf)}if(this.tz!=null){var l=this.tz.v;l.Lctn.v=Math.round(4096*D);var A=U.indexOf(this.tz);
if(A!=-1&&j>2&&U.length>1)U.splice(A,1);if(A==-1&&j<2)U.push(this.tz);U.sort(this.Vf)}if(this.Fy>-1){var M=I[this.Fy].v;
M.Mdpn.v=Math.max(5,Math.min(95,Math.round(100*(D*4096-I[this.Fy-1].v.Lctn.v)/(M.Lctn.v-I[this.Fy-1].v.Lctn.v))))}if(this.Hv>-1){var l=U[this.Hv].v;
l.Mdpn.v=Math.max(5,Math.min(95,Math.round(100*(D*4096-U[this.Hv-1].v.Lctn.v)/(l.Lctn.v-U[this.Hv-1].v.Lctn.v))))}if(this.Ax!=null||this.tz!=null||this.Fy>-1||this.Hv>-1){this.Nm();
this.T5()}};cV.prototype.KJ=function(w){e.MC(window,this.vW);e.i_(window,this.VB);if(Date.now()-this.Ju<300){if(this.Hv!=-1||this.Fy!=-1){var n=(this.Hv!=-1?this.L$.Clrs.v[this.Hv]:this.L$.Trns.v[this.Fy]).v;
n.Mdpn.v=50;this.Nm();this.T5()}else if(this.tz!=null)this.$D.$F()}this.Ju=Date.now()};cV.prototype.Vf=function(w,n){return w.v.Lctn.v-n.v.Lctn.v};
function gI(){dB.call(this,[11,10],"isize");this.xG=e.t("div","form");this.xG.setAttribute("style","width:20em");
this.body.appendChild(this.xG);this.Yx=new dZ(!0,!0,null,null,!0);this.xG.appendChild(this.Yx.e);this.AC=new b7([12,25,3]);
this.AC.$(!0);this.xG.appendChild(this.AC.e);this.AC.h(b.E.A,this.aw1,this);this.hb=new i0([12,14,1],[[12,14,2],[12,14,3],[12,14,4]]);
this.hb.$(1);this.xG.appendChild(this.hb.e);this.QK=e.bp(this,this.body)}gI.prototype=new dB;gI.prototype.X7=function(w,n){return w!=null};
gI.prototype.wb=function(){return!0};gI.prototype.aw1=function(w){var n=this.AC.b(),W=this.Yx,D=this.hb;
if(n)D.Te();else D.rx();W.amp(n)};gI.prototype.f=function(){dB.prototype.f.call(this);this.AC.f();this.QK.f();
this.hb.f();this.Yx.f()};gI.prototype.j8=function(w){this.close();var n=this.Yx.b(),W=n.x,D=n.y,j=this.hb.b();
if(!this.AC.b())j=null;var I=new ed(b.E.W1,!0);I.data=y.QJ.axS(W,D,this.Yx.Y0(),j);this.S(I)};gI.prototype.mQ=function(w,n){this.Yx.$(new ec(w.m,w.n),w.hh);
this.Yx.Me()};function cH(){dB.call(this,"Import RAW","importraw");var w=e.t("div","flexrow"),n=e.t("div");
n.setAttribute("style","margin-bottom: 1em");this.body.appendChild(w);this.body.appendChild(n);var W=e.t("div","form");
W.setAttribute("style","width:18em");w.appendChild(W);var D=e.t("div","form");D.setAttribute("style","width:15em");
w.appendChild(D);this.n_=null;this.Dw=null;this.p2=null;this.Yl=null;this.acR=[];var j=[];for(var L=0;
L<cH.vC.length;L++)j.push(cH.vC[L]+" Bits");var I=this.pY=[new dZ(!0,null,null,!0),new g_([12,72],1,8),new b7("Last one is Transparency"),new j$([12,34],j),new j$("Byte Order",["12-34","34-12"]),new i0("Guesses",[])];
for(var L=0;L<I.length;L++){var U=I[L];U.parent=this;U.h(b.E.A,L==5?this.ahE:this.bX,this);var M=L==0?W:L==5?n:D;
M.appendChild(U.e)}this.T=e.t("canvas");this.VE=this.T.getContext("2d");this.body.appendChild(this.T);
this.QK=e.bp(this,this.body)}cH.prototype=new dB;cH.prototype.f=function(){dB.prototype.f.call(this);
var w=this.pY;this.QK.f();for(var L=0;L<w.length;L++)w[L].f()};cH.prototype.j8=function(w){this.close();
var n=this.pY[0].b(),W=jj.Dk(this.Dw,[{data:this.p2,XL:new iB(0,0,n.x,n.y)}]);if(this.Yl)W.yo=this.Yl;
var D=new ed(b.E.L,!0);D.data={d:!0?b.c.dH:b.c.l9,On:W};this.S(D)};cH.vC=[8,16];cH.prototype.mQ=function(w,n){this.n_=new Uint8Array(n.AY);
this.Dw=n.O7;var W=this.n_.length,D=[1,3,4],j=0,I=0,U=1,M=1,m=this.acR=[],l=Math.round(Math.sqrt(W)*2);
l=Math.max(l,4e3);for(var A=0;A<3;A++){for(var g=0;g<2;g++){var k=cH.vC[g],$=D[A],C=$*k,f=Math.round(W*8/C);
if(f!=W*8/C)continue;for(var z=0;z<=l;z++)for(var s=0;s<=l;s++)if(z*s==f){var O=0;if(z==s)O+=64;if(Math.round(z/100)==z/100&&Math.round(s/100)==s/100)O+=32;
if(Math.round(z/10)==z/10&&Math.round(s/10)==s/10)O+=16;if(Math.round(z/2)==z/2&&Math.round(s/2)==s/2)O+=8;
m.push([z,s,$,k,O])}}}var a=function(Y,K){if(K[4]!=Y[4])return K[4]-Y[4];var S=Math.max(Y[0],Y[1])/Math.min(Y[0],Y[1]),G=Math.max(K[0],K[1])/Math.min(K[0],K[1]);
if(S!=G)return S-G;return K[0]-Y[0]};m.sort(a);var X=this.pY,P=[];for(var L=0;L<m.length;L++){var Z=m[L];
P.push(Z[0]+" x "+Z[1]+", "+Z[2]+"ch, "+Z[3]+"-bit")}X[5].TF(P);X[5].$(0);this.ahE(null)};cH.prototype.ahE=function(w){var n=this.pY,W=this.acR[this.pY[5].b()];
n[0].$(new ec(W[0],W[1]),72);n[1].$(W[2]);n[3].$(cH.vC.indexOf(W[3]));this.bX()};cH.prototype.bX=function(w){var n=this.pY,W=n[0].b(),D=W.x,j=W.y,I=cH.vC[n[3].b()],U=this.n_;
if(I==16&&n[4].b()==1){U=U.slice(0);for(var L=0;L<U.length;L+=2){var M=U[L];U[L]=U[L+1];U[L+1]=M}}var m=this.p2=this.Vu(U,D,j,n[1].b(),I,n[2].b()),l=this.T,A=this.VE,g=[m,new iB(0,0,D,j)];
E.L3(g);for(var L=0;L<g.length;L+=2)if(g[L+1].n<300){m=g[L];D=g[L+1].m;j=g[L+1].n;break}l.width=D;l.height=j;
e.UE(l,D,j);var k=new ImageData(new Uint8ClampedArray(m.buffer),D,j);A.putImageData(k,0,0)};cH.prototype.Vu=function(w,n,W,D,j,I){this.Yl=null;
var U=[],M=n*W;for(var m=0;m<D;m++){var l=E.Q(M);U.push(l);if(j==8)for(var L=0;L<M;L++)l[L]=w[L*D+m];
else if(j==16)for(var L=0;L<M;L++)l[L]=Math.round((w[(L*D+m)*2]<<8|w[(L*D+m)*2+1])*(255/65535))}var A=E.Q(M*4);
new Uint32Array(A.buffer).fill(4278190080);if(I){E.IL(U.pop(),A,3);D--}if(D==0){}else if(D==1)E.Mj(U[0],A);
else{E.IL(U[0],A,0);E.IL(U[1],A,1);if(D>2){E.IL(U[2],A,2);if(D>3){this.Yl=[];for(var L=3;L<D;L++){var g=new h.ac;
g.name="Alpha "+(L-2);g.rect=new iB(0,0,n,W);g.channel=U[L];this.Yl.push(g)}}}}return A};function bF(w,n,W){eg.call(this);
this.e=e.t("div","");this.ik=w;this.CL=null;this.Tq=n==null?!1:n;this.Wn=null;this.V3=W;this.qR=[];this.s6=[];
this.st=[];this.Qf=[];this.t2=0;this.CL=this.a5d(bF.Qf[w]);this.sk();this.Op=null;this.ann;this.auQ}bF.prototype=new eg;
bF.prototype.WQ=function(w,n,W,D,j){this.Op=j;this.ann=JSON.parse(JSON.stringify(this.Wn));if(this.CL.lagl)this.auQ=this.CL.lagl.b()[0]};
bF.prototype.QD=function(w,n,W,D,j){var I=this.Op,U=this.ik,M=this.ann;if(I==null)return;var m=(j.x-I.x)/w.u.N,l=(j.y-I.y)/w.u.N;
if(U=="GrFl"){var A=JSON.parse(JSON.stringify(M.Ofst.v));A.Hrzn.v.val+=m*.5;A.Vrtc.v.val+=l*.5;this.CL.Ofst.$(A,!0)}if(U=="patternFill"){var A=JSON.parse(JSON.stringify(M.phase.v));
A.Hrzn.v+=m;A.Vrtc.v+=l;this.CL.phase.$(A,!0)}if(U=="DrSh"||U=="IrSh"||U=="ChFX"){var g=M.Dstn.v.val,k=this.auQ*Math.PI/180,$=-Math.cos(k)*g+m,C=Math.sin(k)*g+l;
this.CL.Dstn.$(Math.sqrt($*$+C*C),!0);this.CL.lagl.$([Math.atan2(C,-$)*180/Math.PI],!0)}};bF.prototype.H5=function(w,n,W,D,j){this.Op=null};
bF.prototype.a7i=function(){for(var L=0;L<this.Qf.length;L++){e.IX(this.Qf[L],"selected");if(this.st[L]instanceof b7)this.st[L].$(!1)}};
bF.prototype.a1F=function(w){var n=this.al_.bind(this);for(var L=0;L<this.st.length;L++){var W=e.t("div","listitem");
this.Qf.push(W);if(L>0)W.textContent="\u2003";W.appendChild(this.st[L].e);if(at.af4.indexOf(this.ik)!=-1){var D=new iP("+");
D.d3();D.e.style.float="right";W.appendChild(D.e);var j=new iP("\u2B0D");j.d3();j.e.style.float="right";
j.e.style["margin-right"]="2px";W.appendChild(j.e)}W.addEventListener("click",n,!1);w.appendChild(W)}};
bF.KE=function(w,n){var W=n.getBoundingClientRect();return(w.clientY-W.top)/W.height};bF.prototype.al_=function(w){var n=w.target.tagName.toLowerCase();
if(n=="input"){return}if(n=="button"){var W=new ed(b.E.v,!0),D=w.target.textContent=="+",j=D?0:bF.KE(w,w.target)<.5?-1:1;
if(D)W.data={d:"st_dupsingle",j:this.parent.data.j,RL:this.V3};else W.data={d:"st_movsingle",j:this.parent.data.j,RL:this.V3,a0i:j};
W.G=y.EA;W.HH=!0;this.S(W);W=new ed("redrawall",!0);W.data={a0i:j};this.S(W);return}e.oz(w);this.uR();
this.t2=this.Qf.indexOf(w.currentTarget);this.S(new ed("showme"))};bF.prototype.uR=function(){if(this.CL.enab&&this.CL.enab.b()==!1)this.f8({c7:"enab",Z:!0})};
bF.prototype.aqE=function(){var w=this.Qf[this.t2];if(w)e.W0(w,"selected");return this.s6[this.t2]};
bF.prototype.a5d=function(w){var n={};for(var L=0;L<w.length;L++){var W=w[L],D=null;if(W=="----")D={e:e.t("hr")};
if(W=="\n")D={e:e.t("br")};if(W=="blOptions")D=new ga([14,10]);if(W=="brst")D=new jw([12,72],["R","G","B"]);
if(W=="knko")D=new i0("Knockout",[[13,1,0],"Shallow","Deep"]);if(W=="enab")D=new b7(at.names[at.order.indexOf(this.ik)]);
if(W=="lrMd"||W=="Md")D=new i0([12,19,0],dD.AE,dD.E5);if(W=="Opct")D=new f2([12,0],0,100,"%");if(W=="iOpa")D=new f2([12,26],0,100,"%");
if(W=="blIf")D=new fy;if(W=="ShdN")D=new f2([12,68],0,100,"%");if(W=="lagl"||W=="Angl")D=new aA([12,15],this.ik=="ebbl");
if(W=="uglg")D=new b7([12,27]);if(W=="Dstn")D=new f2([12,28],0,200,"px");if(W=="Ckmt")D=new f2([12,29],0,100,"%");
if(W=="blur")D=new f2([12,14,0],0,200,"px");if(W=="TrnS"||W=="MpgS")D=new jJ([12,21]);if(W=="Nose")D=new f2([12,30],0,100,"%");
if(W=="layerConceals")D=new b7([12,31]);if(W=="Cntn")D=new b7([12,25,4]);if(W=="AntA"||W=="antialiasGloss")D=new b7([12,25,1]);
if(W=="GlwT")D=new i0([12,32],at.Nx.names);if(W=="glwS")D=new i0([12,70],at.Nx.avL);if(W=="Inpr")D=new f2([12,12],1,100,"%");
if(W=="bvlS")D=new i0([12,22],at.x7.style);if(W=="bvlT")D=new i0([12,32],at.x7.ab1);if(W=="bvlD")D=new i0(null,at.x7.dir);
if(W=="srgR")D=new f2([12,34],0,1e3,"%");if(W=="Sftn")D=new f2([12,35],0,20,"px");if(W=="Lald")D=n.lagl;
if(W=="hglM"||W=="sdwM")D=new i0([12,36],dD.AE,dD.E5);if(W=="hglC"||W=="sdwC")D=new gM;if(W=="hglO"||W=="sdwO")D=new f2([12,0],0,100,"%");
if(W=="Invr"||W=="InvT")D=new b7([4,11]);if(W=="Sz")D=new f2([12,14,0],1,200,"px");if(W=="Styl")D=new i0([12,40],at.stroke.names);
if(W=="PntT")D=new i0([12,66],at.stroke.azS);if(W=="Clr")D=new gM(!0);if(W=="Grad"){D=new jr(!0,[12,37],!0);
D.$(JSON.parse(at._V.a0x).v)}if(W=="Rvrs")D=new b7([12,23,0]);if(W=="Dthr")D=new b7([12,23,3]);if(W=="Type")D=new i0([12,22],at.M.names.slice(0,this.ik=="FrFX"?6:5));
if(W=="Ptrn")D=new jZ([12,62]);if(W=="Scl")D=new f2([12,38],5,500,"%",0,!0);if(W=="Algn")D=new b7([12,39]);
if(W=="Ofst")D=new aw(!0);if(W=="phase")D=new aw(!1);if(W=="useShape")D=new b7([12,21]);if(W=="useTexture")D=new b7([12,67]);
if(W=="textureDepth")D=new f2([12,34],-300,300,"%");var j=W=="----"||W=="\n"?W+L:W;if(D!=null)n[j]=D}return n};
bF.prototype.asS=function(w){var n=this.s6[this.t2];for(var L=0;L<w.length;L++){var W=this.CL[w[L]];
if(W&&n.contains(W.e))n.removeChild(W.e)}};bF.prototype.adD=function(w){var n=this.s6[this.t2];for(var L=0;
L<w.length;L++){var W=this.CL[w[L]];if(W&&!n.contains(W.e))n.appendChild(W.e)}};bF.prototype.GZ=function(w,n){if(this.CL==null)return;
var W=n==bk.bI;if(this.CL.Grad){this.CL.Grad.Wc(w.Gp,w.as);if(W||n==bk.X$||n==bk.tU)this.CL.Grad.FC(w.wX)}if(this.CL.Ptrn){if(W||n==bk.C0)this.CL.Ptrn.FC(w.V8)}if(this.CL.TrnS){if(W||n==bk.tX)this.CL.TrnS.FC(w.h$)}if(this.CL.MpgS){if(W||n==bk.tX)this.CL.MpgS.FC(w.h$)}};
bF.prototype.f=function(){for(var L=0;L<this.qR.length;L++)this.qR[L].f();for(var w in this.CL)if(this.CL[w]instanceof eg)this.CL[w].f()};
bF.prototype.sk=function(){for(var w in this.CL){var n=this.CL[w];n.parent=this;if(n instanceof eg)n.h(b.E.A,this.as$,this);
if(this.s6.length==0||w=="useShape"||w=="useTexture"){var W=new ga(n.a8f()),D=e.t("div","bordered padded");
if(this.Tq==!1){D.appendChild(W.e);D.appendChild(e.t("hr",""))}this.qR.push(W);this.s6.push(D);this.st.push(n)}else this.s6[this.s6.length-1].appendChild(n.e)}};
bF.prototype.update=function(w,n){if(this.CL==null)return;this.Wn=JSON.parse(JSON.stringify(n));for(var W in n){if("Opct iOpa hglO sdwO Dstn Ckmt blur Nose Scl Sz Inpr srgR Sftn textureDepth ShdN".split(" ").indexOf(W)!=-1)this.CL[W].$(n[W].v.val);
if("enab brst knko Clr hglC sdwC uglg Grad TrnS MpgS Rvrs Dthr Algn Invr InvT Ptrn layerConceals Cntn useShape useTexture Ofst phase blIf".split(" ").indexOf(W)!=-1){this.CL[W].$(n[W].v,w)}if(["Md","hglM","sdwM"].indexOf(W)!=-1)this.CL[W].$(dD.ik.indexOf(n[W].v.BlnM));
if(W=="lrMd"){var D=(n.ue?[[15,10,27]]:[]).concat(dD.AE),j=(n.ue?[1]:[]).concat(dD.E5);this.CL[W].TF(D,j);
this.CL[W].$(n[W].v)}if(W=="Angl")this.CL[W].$([n[W].v.val]);if(W=="lagl"){var I=n.uglg&&n.uglg.v?w.d4():n.lagl.v.val;
this.CL[W].$([I])}if(W=="Lald"){var I=n.uglg&&n.uglg.v?w.wS():n.Lald.v.val;this.CL[W].$([null,I])}if(W=="Type")this.CL[W].$(at.M.types.indexOf(n.Type.v.GrdT));
if(W=="Styl")this.CL[W].$(at.stroke.types.indexOf(n.Styl.v.FStl));if(W=="PntT"){var U=at.stroke.iX.indexOf(n.PntT.v.FrFl);
this.CL[W].$(U);if(!this.Tq){this.asS(at.Oa.concat(at.Ki.concat(at.v7)));this.adD([at.Oa,at.Ki,at.v7][U])}}if(W=="GlwT")this.CL[W].$(at.Nx.types.indexOf(n.GlwT.v.BETE));
if(W=="glwS")this.CL[W].$(at.Nx.azc.indexOf(n.glwS.v.IGSr));if(W=="bvlS")this.CL[W].$(at.x7.types.indexOf(n.bvlS.v.BESl));
if(W=="bvlT")this.CL[W].$(at.x7.axt.indexOf(n.bvlT.v.bvlT));if(W=="bvlD")this.CL[W].$(["In","Out"].indexOf(n.bvlD.v.BESs))}};
bF.prototype.as$=function(w){for(var n in this.CL){if(this.CL[n]!=w.target)continue;var W=null,D=!1;
if("Opct iOpa hglO Nose Scl sdwO Inpr srgR textureDepth ShdN".split(" ").indexOf(n)!=-1)W={type:"#Prc",val:w.target.b()};
if(["Dstn","Ckmt","blur","Sz","Sftn"].indexOf(n)!=-1)W={type:"#Pxl",val:w.target.b()};if(["Angl","lagl"].indexOf(n)!=-1)W={type:"#Ang",val:w.target.b()[0]};
if("enab brst knko Clr hglC sdwC Grad TrnS MpgS Rvrs Dthr Algn Invr InvT Ptrn layerConceals Cntn lrMd useShape useTexture AntA antialiasGloss Ofst phase blIf".split(" ").indexOf(n)!=-1)W=w.target.b();
if(["Md","hglM","sdwM"].indexOf(n)!=-1)W={BlnM:dD.ik[w.target.b()]};if(n=="uglg"){W=w.target.b();D=!0}if(n=="PntT"){W={FrFl:at.stroke.iX[w.target.b()]};
D=!0}if(n=="Lald")W={type:"#Ang",val:w.target.b()[1]};if(n=="Type")W={GrdT:at.M.types[w.target.b()]};
if(n=="Styl")W={FStl:at.stroke.types[w.target.b()]};if(n=="GlwT")W={BETE:at.Nx.types[w.target.b()]};
if(n=="glwS")W={IGSr:at.Nx.azc[w.target.b()]};if(n=="bvlS")W={BESl:at.x7.types[w.target.b()]};if(n=="bvlT")W={bvlT:at.x7.axt[w.target.b()]};
if(n=="bvlD")W={BESs:["In","Out"][w.target.b()]};this.f8({c7:n,Z:W});if(D){if(this.Tq)this.update(null,this.Wn);
else{var j=this.parent,I=j.On,U=this.V3,M=I.C[j.data.j].add.lmfx[at.Pa[U[0]]].v[U[1]].v;this.update(I,M)}}}};
bF.prototype.f8=function(w){if(this.Wn&&this.Wn[w.c7])this.Wn[w.c7].v=w.Z;if(this.Tq){this.S(new ed(b.E.A))}else{w.d="changeprop";
w.j=this.parent.data.j;w.p_=this.V3;var n=new ed(b.E.v,!0);n.data=w;n.G=y.EA;n.HH=!0;this.S(n);this.S(new ed("afterchange",!0))}};
bF.prototype.b=function(){return JSON.parse(JSON.stringify(this.Wn))};bF.Qf={bops:"blOptions lrMd Opct ---- iOpa brst ---- blIf".split(" "),DrSh:"enab Md Clr Opct lagl uglg Dstn Ckmt blur TrnS Nose layerConceals Cntn".split(" "),IrSh:"enab Md Clr Opct lagl uglg Dstn Ckmt blur TrnS Nose".split(" "),OrGl:["enab","Md","Opct","Nose","\n","Clr","Grad","----","GlwT","Ckmt","blur","TrnS","Inpr","ShdN"],IrGl:["enab","Md","Opct","Nose","\n","Clr","Grad","----","GlwT","glwS","Ckmt","blur","TrnS","Inpr","ShdN"],ebbl:["enab","bvlS","bvlT","bvlD","srgR","blur","Sftn","----","lagl","Lald","uglg","TrnS","\n","hglM","hglC","hglO","sdwM","sdwC","sdwO","useShape","MpgS","Inpr","useTexture","Ptrn","Scl","textureDepth","InvT","Algn","phase"],SoFi:["enab","Md","Opct"].concat(at.Oa),GrFl:["enab","Md","Opct"].concat(at.Ki),patternFill:["enab","Md","Opct"].concat(at.v7),ChFX:"enab Md Clr Opct lagl Dstn blur MpgS Invr".split(" "),FrFX:["enab","Sz","Styl","\n","Md","Opct","PntT","\n"].concat(at.Oa.concat(at.Ki.concat(at.v7)))};
function db(){dB.call(this,[11,6],"layerstyle");this.al8=-1;this.data={};this.On=null;this.ww=null;this.Vy=[];
this.RO=[];e.W0(this.body,"flexrow");this.GN=e.t("div","bordered");this.GN.setAttribute("style","min-width:13em;");
this.body.appendChild(this.GN);this.t8=e.t("div","");this.t8.setAttribute("style","width:25em; padding-left: 1em;");
this.body.appendChild(this.t8);this.fU=e.t("div","form");this.fU.setAttribute("style","padding-left: 1em; width:7em;");
this.body.appendChild(this.fU);this.QK=e.bp(this,this.fU);this.xf=new iP([12,87],!0,null,!0);this.xf.h("click",this.aqd,this);
this.fU.appendChild(this.xf.e);this.ud=new jR;this.ud.parent=this;this.ud.h(b.E.A,this.auO,this);this.fU.appendChild(this.ud.e);
this.h("closebtn",this.$S,this);this.h("redrawall",this.akq,this)}db.prototype=new dB;db.prototype.wb=function(){return!0};
db.prototype.tZ=function(){return!0};db.prototype.WQ=function(w,n,W,D,j){var I=this.at();if(I)I.WQ(w,n,W,D,j)};
db.prototype.QD=function(w,n,W,D,j){var I=this.at();if(I)I.QD(w,n,W,D,j)};db.prototype.H5=function(w,n,W,D,j){var I=this.at();
if(I)I.H5(w,n,W,D,j)};db.prototype.at=function(w){if(w==null)w=this.data.index;return w==null?null:w==0?this.Vy[0]:this.RO[w[0]][w[1]]};
db.prototype.auO=function(w){var n=this.ud.b();this.f8({d:"setstl",Z:n.nK});this.akq(null)};db.prototype.aqd=function(w){var n=this.On,W=this.data.j;
if(W==null)W=n.g[0];var D=this.On.C[W],j=ge.a6C(D),I=new ed(b.E.L,!0);I.data={d:b.c.oj,BX:"add",AH:bk.gB,O2:[JSON.parse(JSON.stringify(j))]};
this.S(I)};db.prototype.arE=function(w){this.data.index=w.currentTarget.V3;this.sN(w.currentTarget.V3)};
db.prototype.akq=function(w){this.mQ(this.On,this.data)};db.prototype.sN=function(w,n){e._g(this.t8);
for(var L=0;L<this.Vy.length;L++)this.Vy[L].a7i();var W=this.at(w);this.t8.appendChild(W.aqE());if(n)W.uR();
var D=this.On;if(D){var j=D.C[this.data.j];this.Vy[0].update(D,y.Su.qB(D,j));var I=j.add.lmfx;if(I==null)return;
for(var L=0;L<at.order.length;L++){var U=I[at.Pa[L]].v;for(var M=0;M<U.length;M++)this.RO[L][M].update(D,U[M].v)}}if(n)W.uR()};
db.prototype.f=function(){dB.prototype.f.call(this);this.xf.f();this.ud.f();this.QK.f();for(var L=0;
L<this.Vy.length;L++)this.Vy[L].f()};db.prototype.mQ=function(w,n){var W=n.j==null;this.data.j=n.j;this.data.index=n.index;
n=this.data;this.On=w;if(W)n.j=w.g.length==0?w.C.length-1:w.g[0];e._g(this.GN);var D=w.C[n.j].add.lmfx;
this.vq();this.Vy=[new bF("bops",!1,0)];this.RO=[];for(var L=0;L<at.order.length;L++){this.RO.push([]);
var j=D==null?[]:D[at.Pa[L]].v;for(var I=0;I<j.length;I++){var U=new bF(at.order[L],!1,[L,I]);this.Vy.push(U);
this.RO[L].push(U)}if(j.length==0){var U=new bF(at.order[L],!1,[L,0]);this.Vy.push(U);this.RO[L].push(U)}}this.f();
this.ajS(this.ww,bk.bI);for(var L=0;L<this.Vy.length;L++){this.Vy[L].parent=this;this.Vy[L].a1F(this.GN);
this.Vy[L].h("showme",this.arE,this)}if(n.index==null||n.index==0||!W&&D[at.Pa[n.index[0]]].v.length==0){this.sN(0)}else this.sN(n.index,W);
this.h("afterchange",this.vq,this)};db.prototype.vq=function(w){var n=this.On,W=this.data.j;if(W==null)W=n.g[0];
var D=this.On.C[W],j=ge.a6C(D);this.ud.$(j,n.add.Patt?n.add.Patt:[],n.d4(),n.wS())};db.prototype.GZ=function(w,n){this.ww=w;
this.ajS(w,n);if(n==bk.gB||n==bk.bI){this.ud.FC([w.IH,w.V8])}if(n==bk.Iv){}};db.prototype.ajS=function(w,n){for(var L=0;
L<this.Vy.length;L++)this.Vy[L].GZ(w,n)};db.prototype.$S=function(w){this.f8({d:"cancel"})};db.prototype.j8=function(w){this.f8({d:"confirm"});
this.close()};db.prototype.f8=function(w){w.j=this.data.j;var n=new ed(b.E.v,!0);n.data=w;n.G=y.EA;n.HH=!0;
this.S(n);this.vq()};db.aAI=function(){var w=function(n){if(n==null||n.g.length==0)return{r:!1};var W=n.C[n.g[0]];
return{r:W.add.lmfx!=null}};return{name:[11,6],nW:!0,sub:[{name:[5,1],r:w},{name:[5,2]},{name:[2,2],r:w}]}};
db.a1o=function(){return{sub:[{Y:b.E.v,G:y.EA,W:{d:"st_copy"}},{Y:b.E.v,G:y.EA,W:{d:"st_paste"}},{Y:b.E.v,G:y.EA,W:{d:"st_clear"}}]}};
db.pq=function(w){var n=[{name:[14,10],nW:!0}];for(var L=0;L<at.names.length;L++)n.push({name:at.names[L]});
if(w){n[n.length-1].nW=!0;n.push(db.aAI());n.push({name:[6,30,1],r:function(W){return{r:W!=null&&W.g.length!=0&&W.C[W.g[0]].Z_()}}});
n.push({name:["VAR0 VAR1",[12,49],[9,1]],r:function(W){return{r:W!=null&&W.g.length!=0&&W.C[W.g[0]].add.lmfx!=null}}})}return n};
db.Km=function(w){var n=[{Y:b.E.L,W:{d:b.c.P2,jW:"layerstyle"}}];for(var L=0;L<at.names.length;L++)n.push({Y:b.E.L,W:{d:b.c.P2,jW:"layerstyle",index:[L,0]}});
if(w){n.push(db.a1o());n.push({Y:b.E.L,W:{d:b.c.P2,jW:"scaleeffects",Z1:100,j2:{Y:b.E.v,G:y.EA,W:{d:"scaleeffects"}}}});
var W={classID:"Mk",null:cq.Pz("Lyr"),Usng:{t:"obj ",v:[{t:"prop",v:{classID:"Prpr",keyID:"Lefx"}},{t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Trgt"}}]}};
n.push({Y:b.E.W1,W:{hZ:"make",E3:W}})}return n};db.adM=function(w){var n=[];if(w)n.push({name:[6,48,0,0],$r:!0},{name:[6,48,0,1],$r:!0},{name:[6,48,0,2],$r:!0,nW:!0});
for(var W in eH.names)n.push({name:eH.names[W],nW:eH.aoW.indexOf(W)!=-1,$r:gu[W]!=null});return n};db.XG=function(w){var n=[];
if(w){n.push({Y:b.E.v,G:y.K7,W:{d:"newfill",Y3:0}});for(var L=1;L<3;L++)n.push({Y:b.E.W1,W:y.IG.YE(L)})}for(var W in eH.names){var D=cx._1(W);
if(D==null)D={};for(var j in eH.Nn)if(eH.Nn[j]==W)D.classID=j;var I={hZ:"make",E3:{classID:"Mk",null:cq.Pz("AdjL"),Usng:{t:"Objc",v:{classID:"AdjL",Type:{t:"Objc",v:D}}}}};
n.push({Y:b.E.W1,W:I})}return n};function iH(){dB.call(this,"Merge Channels","mergechannels");this.bn=null;
var w=e.t("div","form");this.body.appendChild(w);this.pY=[];for(var L=0;L<3;L++){var n=new i0(eH.RU[L],[]);
this.pY.push(n);w.appendChild(n.e);e.x$(w)}this.QK=e.bp(this,w)}iH.prototype=new dB;iH.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();for(var L=0;L<3;L++)this.pY[L].f()};iH.prototype.mQ=function(w,n,W,D){this.bn=W;var j=[];
for(var L=0;L<W.length;L++)j.push(W[L].name);for(var L=0;L<3;L++){var I=this.pY[L];I.TF(j);I.$(Math.min(L,W.length-1))}};
iH.prototype.j8=function(w){var n=this.bn,W=n[0],D=new ed(b.E.W1,!0);D.data=kc.xM(W.m,W.n,W.hh,"Merged Document","Wht",!1);
this.S(D);var j=[];for(var L=0;L<3;L++)j.push(n[this.pY[L].b()].Vc());var W=n[n.length-1],I=W.C[0],U=I.buffer;
for(var L=0;L<U.length;L+=4){U[L]=j[0][L];U[L+1]=j[1][L];U[L+2]=j[2][L]}I.l();W.l();this.close()};function hR(){dB.call(this,[1,10],"script");
var w=e.t("div","form");w.setAttribute("style","width:44em");this.body.appendChild(w);this.ww=null;this.uH=[];
this.Pt=[];this.a3N;var n=this.Id=new iP([1,2],!1,null,!0);n.h("click",this.lZ,this);w.appendChild(n.e);
var W=new iP("JS Reference",!1,null,!0);W.h("click",this.ako,this);w.appendChild(W.e);w.appendChild(new ga("Demos:").e);
this.ajR=[];var D=hR.Rs;for(var L=0;L<D.length;L++){var j=new iP(D[L].DG,!1,null,!0);this.ajR.push(j);
w.appendChild(j.e);j.h("click",this.aix,this)}this.RE=e.t("textarea");e.xr(this.RE);this.RE.setAttribute("rows",16);
this.RE.setAttribute("style","display:block;tab-size:4; font-family:monospace;width:100%;");w.appendChild(this.RE);
var I=new iP("Run",!0,null,!0);I.h("click",this.j8,this);w.appendChild(I.e);this.uc=e.t("div");w.appendChild(this.uc)}hR.prototype=new dB;
hR.prototype.f=function(){this.Id.f()};hR.prototype.lZ=function(){var w=this.a3N;if(w==null)w="script.jsx";
var n=new ed(b.E.L,!0);n.data={d:b.c.P2,jW:"namewindow",Z1:w.slice(0,w.length-4),FJ:this.amA.bind(this)};
this.S(n)};hR.prototype.amA=function(w){var n=this.RE.value,W=J.zY(n),D=new ed(b.E.L,!0);D.data={d:b.c.D7,AY:W.buffer,I6:w+".jsx",ao1:!0};
this.S(D)};hR.prototype.ai4=function(w){var L=this.uH.indexOf(w.target),n=this.a3N=this.Pt[L],W=this.ww.AJ.rA[n],D=new Uint8Array(W),j=J.KY(D,0,D.length);
this.RE.value=j};hR.prototype.mQ=function(w,n,W){this.RE.value=hR.Rs[0].FP;this.ay7()};hR.prototype.ay7=function(){var w=this.ww.AJ,n=this.uc;
e._g(n);this.uH=[];this.Pt=[];n.textContent="Saved scripts: ";for(var W in w.rA){if(W.endsWith(".jsx")){var D=new iP(W,!1,null,!0);
this.uH.push(D);this.Pt.push(W);D.h("click",this.ai4,this);n.appendChild(D.e)}}};hR.prototype.GZ=function(w,n){this.ww=w;
if(n==bk._w)this.ay7()};hR.prototype.ako=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.aT,link:"https://github.com/Adobe-CEP/CEP-Resources/blob/master/Documentation/Product%20specific%20Documentation/Photoshop%20Scripting/photoshop-javascript-ref-2020.pdf"};
this.S(n)};hR.prototype.j8=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.zM,wx:this.RE.value};this.S(n)};
hR.prototype.aix=function(w){var n=this.ajR.indexOf(w.currentTarget);this.RE.value=hR.Rs[n].FP};hR.Rs=[{DG:"Hello",FP:"\nalert(\"Hello Photopea!\");\n"},{DG:"Process Layers",FP:"\nvar lays = app.activeDocument.layers;\n\nfor(var i=0; i<lays.length; i++)\n{\n"+"\t//lays[i].visible = false;\n"+"\t//lays[i].opacity = 50;\n"+"\tlays[i].name = \"My Layer \"+i;\n}"},{DG:"Clone Layers",FP:"\nvar orig = app.activeDocument.activeLayer;\n"+"var cnt = 12;\n"+"var angle = Math.floor(360 / cnt);\n"+"\n"+"for(var i=1; i<cnt; i++)\n"+"{\n"+"\tvar nlay = orig.duplicate();\n"+"\t//nlay.translate(30*i, 20*i);\n"+"\tnlay.rotate(angle * i, AnchorPosition.BOTTOMCENTER);\n"+"}"}];
function bB(){dB.call(this,[11,7],"newproject");this.data=null;this.bn=null;this.ft=0;var w=e.t("div","flexrow");
this.Bz=w;this.body.appendChild(w);var n=e.t("div","form");this.xG=n;w.appendChild(n);this.aG=new e7([12,48],null,10);
n.appendChild(this.aG.e);e.x$(n);this.Yx=new dZ(!0,null,null,null,!0);this.Yx.$(new ec(1280,720),72);
this.Yx.amp(!0,!0);this.Yx.h(b.E.A,this.jn,this);n.appendChild(this.Yx.e);this.JP=new b1;this.JP.parent=this;
n.appendChild(this.JP.e);this.TD=new iP("\u02C5",null,[0,14],!0);this.TD.h("click",this.UN,this);n.appendChild(this.TD.e);
var W=this.arx=e.t("span");n.appendChild(W);W.style.display="none";this.a8h=new i0([13,6],["sRGB","Adobe RGB","ProPhoto RGB","Display P3"]);
W.appendChild(this.a8h.e);this.LV=new b7([1,16,1]);W.appendChild(this.LV.e);this.QK=new iP([12,49],!0,null,!0);
this.QK.h("click",this.j8,this);n.appendChild(this.QK.e);var D=bB.n_,j=[];for(var L=0;L<D.length;L++)j.push(D[L].name);
this.F0=new j$(null,j);this.F0.h(b.E.A,this.atL,this);n.appendChild(this.F0.e);this.F0.e.style["margin-top"]="1em";
this.Wj=new dX(!0);this.Wj.h(b.E.A,this.anL,this);n.appendChild(this.Wj.e);this.atL();this.nt=new a6;
this.nt.parent=this;this.nt.e.setAttribute("style","margin-left:1em");this.nt.h("tempready",this.aeO,this)}bB.prototype=new dB;
bB.prototype.UN=function(w){var n=this.arx,W=n.style.display!="none";n.style.display=W?"none":"";this.TD.wV(W?"\u02C5":"\u02C4");
this.zl(this.gA,this.ag)};bB.prototype.GZ=function(w,n){this.nt.GZ(w)};bB.prototype.aP=function(w,n){return new ec(Math.max(0,Math.min(70,(w-690)/2)),w>n?Math.max(0,Math.min(50,(n-400)/2)):0)};
bB.prototype.zl=function(w,n){this.gA=w;this.ag=n;this.xG.setAttribute("style","width:"+Math.min(w-24,338)+"px");
this.Wj.e.style.height=n-248-(this.arx.style.display=="none"?0:28)+"px";var W=this.nt.e,D=W.parentNode;
if(w<500){if(D!=null)this.Bz.removeChild(W)}else{if(D==null)this.Bz.appendChild(W);this.nt.zl(w-378,n-28)}};
bB.prototype.jn=function(){this.nt.$(this.Yx.b())};bB.prototype.anL=function(w){var n=this.Wj.b()[0],W=bB.n_[this.F0.b()].Lh[n],D=W[4];
if(D==0)D=72;var j=W[1],I=W[2],U=["px","%","mm","in"].indexOf(W[3]),M=[1,1,25.4/D,1/D][U];j/=M;I/=M;
this.Yx.$(new ec(Math.round(j),Math.round(I)),D);this.Yx.ai1(U);this.jn();if(Date.now()-this.ft<300)this.j8();
this.ft=Date.now()};bB.prototype.atL=function(w){var n=bB.n_[this.F0.b()].Lh,W=[],D=[],j=Math.round(106*e.V()),I=Math.round(106*e.V()),U=0;
for(var L=0;L<n.length;L++)U=Math.max(U,n[L][1],n[L][2]);for(var L=0;L<n.length;L++){var M=n[L],m=M[1]+" x "+M[2]+" "+M[3];
if(M[3]=="in")m=(M[1]*25.4).toFixed(0)+" x "+(M[2]*25.4).toFixed(0)+" mm";if(M[3]=="mm")m=(M[1]/25.4).toFixed(1)+" x "+(M[2]/25.4).toFixed(1)+" in";
if(M[4])m=m+" @ "+M[4]+" ppi";D.push(m);W.push(bB.sX(M,j,I,U))}this.Wj.jJ(W,D,j,I)};bB.sX=function(w,n,W,D){var j=e.t("canvas",""),I=j.getContext("2d");
j.width=n;j.height=W;var U=Math.round(n/8),M=Math.floor(11*e.V()),m=w[1],l=w[2];I.fillStyle="#000000";
I.font=Math.round(M*.9)+"px \"Open Sans\", Sans-Serif";var A=m+" x "+l+" "+w[3],g=I.measureText(A);I.fillText(A,Math.round((n-g.width)/2),W-Math.round(U/2));
if(w[0]!=null){I.font="bold "+M+"px \"Open Sans\", Sans-Serif";var A=w[0],g=I.measureText(A);I.fillText(A,Math.round((n-g.width)/2),W-Math.round(U/2)-Math.round(M*1.3))}W-=Math.round(2.5*M);
var k=Math.min((n-U)/m,(W-U)/l);k*=.5+.5*(Math.max(m,l)/D);var $=(n-m*k)/2,C=(W-l*k)/2;I.strokeRect(Math.round($)+.5,Math.round(C)+.5,Math.round(m*k),Math.round(l*k));
return j.toDataURL()};bB.prototype.f=function(){dB.prototype.f.call(this);this.Yx.f();this.aG.f();this.JP.f();
this.QK.f();this.aG.$(fV.get([11,7]));this.F0.f();this.LV.f();this.TD.f();this.nt.f()};bB.prototype.j8=function(w){var n=this.Yx.b(),W=n.x,D=n.y;
this.close();var j=this.JP.b(),I=["sRGB IEC61966-2.1","Adobe RGB (1998)","ProPhoto RGB","image P3"][this.a8h.b()],U=new ed(b.E.W1,!0);
U.data=kc.xM(W,D,this.Yx.Y0(),this.aG.b(),["Wht","Blck","Trns","Clr"][j[0]],this.LV.b(),j[1],I);this.S(U);
this.asZ()};bB.prototype.aeO=function(w){var n=w.data.On;n.hh=this.Yx.Y0();var W=new ed(b.E.L,!0);W.data={d:b.c.dH,On:n};
this.S(W);this.close();this.asZ()};bB.prototype.asZ=function(){var w=this.bn[this.bn.length-1],n=this.data.a7L;
if(n)e3.m_(function(){var W=new XMLHttpRequest,D="https://www.googleapis.com/drive/v3/files?"+e3.HK();
W.open("POST",D,!0);W.setRequestHeader("Content-Type","application/json");W.addEventListener("load",function(j){var I=JSON.parse(j.target.response);
w.Kh={file:I,q5:"psd"};alert(w.name+" created in Google Drive")});W.send(JSON.stringify({name:w.name,aac:[n]}))})};
bB.prototype.mQ=function(w,n,W,D){this.bn=W;if(w!=null&&w.J!=null){var j=new iB(0,0,w.m,w.n).wU(w.J.rect);
this.Yx.$(new ec(j.m,j.n))}this.data=n;this.jn();if(e.aO())e8.a34(this.a1g.bind(this))};bB.prototype.a1g=function(w){if(w=="granted")e8.h6(this,this.auw.bind(this))};
bB.prototype.auw=function(w,n){this.Yx.$(new ec(n.m,n.n))};bB.n_=[{name:"Social",Lh:[["FB Page Cover",1640,664,"px",0],["FB Shared Image",1200,630,"px",0],["FB Event Image",1920,1080,"px",0],["FB Group Header",1640,856,"px",0],["Instagram",1080,1080,"px",0],["Insta Story",1080,1920,"px",0],["Youtube Profile",800,800,"px",0],["Youtube Cover",2560,1440,"px",0],["Twitter Profile",400,400,"px",0],["Twitter Header",1500,500,"px",0]]},{name:[12,88,4],Lh:[["A3",297,420,"mm",300],["A4",210,297,"mm",300],["A5",148,210,"mm",300],["B3",353,500,"mm",300],["B4",250,353,"mm",300],["B5",176,250,"mm",300],["Letter",8.5,11,"in",300],["Ledger",11,17,"in",300],["Business Card",3.5,2,"in",300]]},{name:[12,88,0],Lh:[["Wallet",2,3,"in",300],["Enprint",3.5,5,"in",300],[null,5,7,"in",300],[null,8,12,"in",300],[null,12,18,"in",300],[null,16,24,"in",300],[null,20,30,"in",300],[null,24,36,"in",300]]},{name:[12,88,1],Lh:[["VGA",640,480,"px",0],["XGA",1024,768,"px",0],["HD",1280,720,"px",0],[null,1366,768,"px",0],[null,1600,900,"px",0],["Full HD",1920,1080,"px",0],["2K",2048,1080,"px",0],["UHD",3840,2160,"px",0],["4K",4096,2160,"px",0]]},{name:[12,88,2],Lh:[["iPhone 4",640,900,"px",326],["iPhone 5",640,1136,"px",326],["iPhone 6 7 8",750,1334,"px",326],["iPhone 6+ 7+ 8+",1080,1920,"px",401],["iPhone X",1125,2436,"px",458],["Samsung A5",720,1280,"px",0],["Samsung S5",1080,1920,"px",0],["Samsung S6",1440,2560,"px",0],["Samsung S8+",1440,2560,"px",0],["Google Pixel",1080,1920,"px",0],["iPad Mini 4",1536,2048,"px",0],["iPad Air 2",1536,2048,"px",0],["iPad Pro 9.7\"",1536,2048,"px",0],["iPad Pro 10.5\"",1668,2224,"px",0],["iPad Pro 12.9\"",2048,2732,"px",0]]},{name:[12,88,3],Lh:[["Small Square",200,200,"px",0],["Square",250,250,"px",0],["Medium Rect",300,250,"px",0],["Large Rect",336,280,"px",0],["Mobile Leaderboard",320,50,"px",0],["Large Mobile",320,100,"px",0],["Banner",468,60,"px",0],["Leaderboard",728,90,"px",0],["Large Leaderboard",970,90,"px",0],["Billboard",970,250,"px",0],["Vertical Rect",240,400,"px",0],["Skyscraper",120,600,"px",0],["Wide Skyscraper",160,600,"px",0],["Half Page",300,600,"px",0],["Portrait",300,1050,"px",0]]},{name:"2\u1D3A",Lh:[[null,16,16,"px",0],[null,32,32,"px",0],[null,64,64,"px",0],[null,128,128,"px",0],[null,256,256,"px",0],[null,512,512,"px",0],[null,1024,1024,"px",0],[null,2048,2048,"px",0],[null,4096,4096,"px",0]]}];
function cF(w,n,W){dB.call(this,n,"sel_"+w);this.d=w;var D=e.t("div","form");this.body.appendChild(D);
this.aG=new g_(n,0,255,null,0,!1,!0);D.appendChild(this.aG.e);this.aG.$(1);var j=e.t("span");j.textContent=W;
D.appendChild(j);e.x$(D);this.axi=new b7("Apply at canvas bounds");if(w!="border")D.appendChild(this.axi.e);
this.QK=e.bp(this,D)}cF.prototype=new dB;cF.prototype.X7=function(w,n){if(w==null)return;if(w.J==null)alert("No selection!");
return w.J!=null};cF.prototype.j8=function(w){var n=new ed(b.E.W1,!0);n.data=y.eZ.cp(this.d,this.aG.b(),this.axi.b());
n.HH=!0;this.S(n);this.close()};cF.prototype.f=function(){dB.prototype.f.call(this);this.QK.f();if(this.aG)this.aG.f()};
cF.prototype.mQ=function(w,n){this.aG.Me()};function gZ(w,n,W,D,j,I){dB.call(this,W,n);this.a84=I;this.en=j;
this.n_=null;this.xG=e.t("div","form");this.body.appendChild(this.xG);this.ayb=e.t("div");this.xG.appendChild(this.ayb);
this.aG=w==0?new e7(W,null,10):w==1?new f2(W,0,500,D,1):new e7(W,null,24,5);this.aG.h(b.E.A,this.Ch,this);
this.xG.appendChild(this.aG.e);this.QK=e.bp(this,this.xG);this.h("closebtn",this.$S,this)}gZ.prototype=new dB;
gZ.prototype.aP=function(w,n){return new ec(Math.max(0,Math.min(150,(w-250)/2)),Math.max(0,Math.min(150,(n-120)/2)))};
gZ.prototype.wb=function(){return this.a84};gZ.prototype.Ch=function(w){var n=this.aG.b();if(this.en)this._5(n)};
gZ.prototype.$S=function(w){if(this.en)this._5("cancel")};gZ.prototype.j8=function(w){if(this.en)this._5("confirm");
else this._5(this.aG.b());this.close()};gZ.prototype._5=function(w){if(this.n_.FJ)this.n_.FJ(w);else if(this.n_.j2){var n=this.n_.j2,W=new ed(n.Y,!0);
W.G=n.G;W.data=n.W;W.data.Z=w;W.HH=!0;this.S(W)}};gZ.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();if(this.aG)this.aG.f()};gZ.prototype.mQ=function(w,n){this.n_=n;this.aG.$(n.Z1);this.aG.Me();
this.ayb.innerHTML=n.ahQ?n.ahQ:"";this.Ch(null)};function dn(){dB.call(this,[1,5],"open_from_url");this.ev=null;
var w=e.t("div","form");this.body.appendChild(w);this.cn=new e7("URL",null,22);w.appendChild(this.cn.e);
e.x$(w);this.RT=new j$([21,0],[[21,2],[21,1]]);w.appendChild(this.RT.e);this.QK=e.bp(this,w)}dn.prototype=new dB;
dn.prototype.f=function(){dB.prototype.f.call(this);this.QK.f();this.RT.f()};dn.prototype.mQ=function(w,n,W){this.cn.Me();
this.ev=null;if(w&&W.indexOf(w)!=-1)this.ev=W.indexOf(w)};dn.prototype.j8=function(w){var n=new ed(b.E.L,!0),W=this.cn.b();
n.data={d:b.c.VR,AH:{url:W,AM:!0,ev:this.RT.b()==1?this.ev:null}};this.S(n);this.close()};function hi(){dB.call(this,[12,79],"preferences");
this.ww=null;var w=e.t("div","form");this.body.appendChild(w);this.Qf=[new b7([8,2]),new b7([8,4]),new i0([12,80,3],[[12,93,3],[12,80,4]]),new gM,new f2([12,80,5],.02,100,null,2),new i0(null,E.f_.Ph),new i0([12,80,6],E.f_.Ph),new b7("Remind me to save"),new f2("Cursor Offset",0,200)];
for(var L=0;L<this.Qf.length;L++){var n=this.Qf[L];n.parent=this;w.appendChild(n.e);if(L!=2&&L!=4)e.x$(w);
n.h(b.E.A,this.A5,this)}}hi.prototype=new dB;hi.prototype.f=function(){dB.prototype.f.call(this);for(var L=0;
L<this.Qf.length;L++)this.Qf[L].f()};hi.prototype.mQ=function(w,n,W){};hi.prototype.GZ=function(w,n){this.ww=w;
var W=w.M3;this.Qf[0].$(W.jg);this.Qf[1].$(W.Vk);this.Qf[2].$(W.df);this.Qf[3].hR(W._S);this.Qf[4].$(W.Jt);
this.Qf[5].$(W.Cp);this.Qf[6].$(W.Lf);this.Qf[7].$(w.vf==1);this.Qf[8].$(w.Tj)};hi.prototype.A5=function(w){var n=this.Qf;
if(w.target==n[7])this.ww.vf=1-this.ww.vf;var W=JSON.parse(JSON.stringify(this.ww.M3));W.jg=n[0].b();
W.Vk=n[1].b();W.df=n[2].b();W._S=n[3].agb();W.Jt=n[4].b();W.Cp=n[5].b();W.Lf=n[6].b();this.ww.Tj=n[8].b();
var D=new ed(b.E.L,!0);D.data={d:b.c.oj,AH:bk.OS,qY:W};this.S(D)};function fp(){dB.call(this,[11,8],"saveforweb");
this.af7="";this.h("closebtn",function(){this.yk.BS()},this);this.On=null;this.B2=null;this.abW=null;
this.ww=null;e.W0(this.body,"flexrow");this.body.style.padding="0";var w=e.t("div");w.setAttribute("style","position:relative;");
var n=e.t("div");this.body.appendChild(w);this.body.appendChild(n);this.o6=e.t("div","imgcont");w.appendChild(this.o6);
this.yk=new hL;this.yk.zl(512,512);this.nY=e.t("div");this.nY.setAttribute("style","position:absolute; right:0px; bottom:0px; padding: 3px 6px; background-color:black;");
w.appendChild(this.nY);var W=this.xG=e.t("div","form cell");W.setAttribute("style","width:195px; padding:9px 13px;");
n.appendChild(W);this.lU=new e7([12,48],null,7.6);this.lU.Mk();W.appendChild(this.lU.e);var D=jj.pg();
D[D.indexOf("WEBP")]="webP";this.a_=new i0([12,50],D);this.a_.e.style.marginRight="0";this.a_.Mk();W.appendChild(this.a_.e);
this.a_.h(b.E.A,this.w$,this);e.x$(W);this.Yx=new dZ(!0,!0,!1,!0);this.Yx.Mk();this.Yx.h(b.E.A,this.w$,this);
this.Yx.LS.e.style.paddingBottom="8px";W.appendChild(this.Yx.e);this.ii=new kv;this.ii.h(b.E.A,this.w$,this);
W.appendChild(this.ii.e);this.XO=new iP([1,2],!0,null,!0);this.XO.h("click",this.j8,this);W.appendChild(this.XO.e)}fp.prototype=new dB;
fp.prototype.X7=function(w,n){return w!=null};fp.prototype.f=function(){dB.prototype.f.call(this);this.Yx.f();
this.lU.f();this.a_.f();this.ii.f();this.XO.f()};fp.prototype.j8=function(w){var n=this.lU.b().trim(),W=jj.pg()[this.a_.b()],D=W=="JPG"||W=="PNG"||W=="GIF",j=jj.ZO(W),I="."+W.toLowerCase(),U=this.B2,M=n+I,m=this.On,l=m.ej,A=this.ii.b();
if(m.EY())A.pop();if(l.length!=0&&D&&A.pop()){var g="<!DOCTYPE html>\n<html>\n<style>div {position:absolute;}</style>\n<head></head>\n<body>\n",k=[],$={},C=new iB(0,0,m.m,m.n),f=m.Vc();
for(var L=0;L<l.length;L++)k.push(y.mk.uw(l,L));k.reverse();var z=E.rect.V0([0,0,m.m,m.n],k);for(var L=0;
L<z.length;L++){var s=z[L],O=new iB(s[0],s[1],s[2]-s[0],s[3]-s[1]),a=s.length==5?l[s[4]].v:null,X=E.Q(O.O()*4);
E.Cb(f,C,X,O);var P="img/img"+(L+1)+I;$[P]=new Uint8Array(j.La([[X.buffer,0]],O.m,O.n,A));g+="<div style=\"background-image:url('"+P+"'); left:"+O.x+"px; top:"+O.y+"px; width:"+O.m+"px; height:"+O.n+"px\">";
if(a&&a.url.v!="")g+="\n\t<a href=\""+a.url.v+"\" target=\""+a.null.v+"\" style=\"display:block;width:100%;height:100%;\"></a>\n";
g+="</div>\n"}g+="</body>\n</html>\n";var Z=E.Q(Math.round(g.length*1.5)),Y=J.Dj(g,Z,0);$["index.html"]=Z.slice(0,Y);
U=UZIP.encode($);M=n+".zip"}else if(m.add.artd&&m.add.artd.Cnt.v>1&&D&&A.pop()){var $={},C=new iB(0,0,m.m,m.n),f=m.Vc(),K=m.root.children;
for(var L=0;L<K.length;L++){var S=K[L].j;if(S.add.artb==null||!S.I4())continue;var G=S.yP(),V=E.Q(G.O()*4);
E.Cb(f,C,V,G);$[S.getName()+I]=new Uint8Array(j.La([[V.buffer,0]],G.m,G.n,A))}U=UZIP.encode($);M=n+".zip"}if(m.wW)e8.iT("act=1&id="+m.wW);
this.yk.BS();this.close();var T=function(){var x=new ed(b.E.L,!0);x.data={d:b.c.pA,data:U,name:M};this.S(x)}.bind(this);
if(!this.ww.aE||bh.d$()){T();return}var R=a1.Cd()!=0;T();var x=new ed(b.E.L,!0),v=hk.Dn("3UMe\\ORYBB@EVG9* 08{\"\",-913-yXs^]Y\\Mm^UHKR3.8F6&+*.y1oo{%qm{m^Xo_SNLU]NA97N-7*B32*'##\"*WlprjhZS.k9XHSPYXt41:=36@;y*2$tn&womykcpZPIWP^IHH8]");
if(R)v=hk.Dn("0^Ne\\ORYLG:<2G&0>\\|W~~otku?|J_ce][MFaVKNB7O;9;C&6$+)1wq(jxdnreaUlNPH`UC9IQH;>E'/J9f un}l0!u\\lXZn[^XbAAMd");
x.data={d:b.c.P2,jW:hk.mK,Z:v,FJ:function(){}};if(Math.random()<.1||R)this.S(x)};fp.prototype.mQ=function(w,n){if(n.$x!=null)this.a_.$(n.$x);
this.On=w;var W=this.On.name,D=W.lastIndexOf("."),W=D==-1?W:W.slice(0,D);this.lU.$(W);var j=w.m+","+w.n;
if(j!=this.af7){this.af7=j;this.Yx.$(new ec(w.m,w.n),w.hh)}this.ii.ak6();if(n.a7G){this.Yx.ai1(3);this.ii.Za.PDF[2].bm.$(!0)}this.w$(null,!0)};
fp.prototype.abk=function(w,n){return w<n&&w<660};fp.prototype.aP=function(w,n){return this.abk(w,n)?new ec(0,0):new ec(Math.max(0,Math.min(150,(w-770)/2)),Math.max(0,Math.min(150,(n-590)/2)))};
fp.prototype.zl=function(w,n,W){this.gA=w;this.ag=n;if(this.On==null)return;var D=this.XO.e,j=this.abk(w,n),I,U,k="<span style=\"width:",$="display:inline-block; text-align:right;\">";
if(j){var M=this.xG.getBoundingClientRect().height;I=w;U=n-Math.max(M,252);e.IX(this.body,"flexrow")}else{I=Math.min(512,w-195-2*13);
U=Math.min(512,n-24);e.W0(this.body,"flexrow")}var m=j?w-2*13:195;this.xG.style.width=m+"px";this.lU.q1.style.width=m-72+"px";
this.Yx.zl(m);var l=jj.pg()[this.a_.b()],A=jj.ZO(l);if(A.Xq||A.vv)this.o6.firstChild.setAttribute("style","display:block; width:"+I+"px; height:"+U+"px;");
else this.yk.zl(I,U);var g=this.B2.byteLength,C=k+64+"px;"+$+fp.cN(g)+"</span>";if(I>400)C+=k+90+"px; opacity:"+.5+";"+$+g.toLocaleString()+" B</span>";
this.nY.innerHTML=C;if(W)setTimeout(function(){this.zl(this.gA,this.ag)}.bind(this),20)};fp.cN=function(w){var n=w.toString(2),W=0;
while(W+10<n.length)W+=10;var D=(w/Math.pow(2,W)).toFixed(1);if(D.endsWith(".0"))D=D.slice(0,-2);var j="B KB MB GB TB PB".split(" ")[Math.floor(W/10)];
return D+" "+j};fp.prototype.GZ=function(w,n){this.ww=w};fp.prototype.w$=function(w,n){var W=this.On,D=this.Yx.b(),j=D.x,I=D.y,U=this.a_.b(),M=jj.pg()[U],m=jj.B6(W)[0].length,l=["GIF","PNG","WEBP"].indexOf(M)!=-1&&m>1,s="";
if(l&&n&&(m>4&&j*I>1024*1024||j*I*m>800*800*50)){var A=1;while(Math.max(j>>>A,I>>>A)>800)A++;var g=window.confirm("Your animation is large ("+j+" x "+I+" px). Press \"OK\" to scale it to "+(100>>>A)+"%. Press \"Cancel\" to keep the size.");
if(g){this.Yx.$(new ec(j>>>A,I>>>A),null,!0);j=j>>>A;I=I>>>A}}var k=W.add.artd,$=k!=null&&k.Cnt.v>1,C=W.EY();
this.ii.Pe(M,l,W.ej.length!=0,$,C!=null);var f=localStorage.getItem("sfwPrms");if(f==null)f={};else f=JSON.parse(f);
var z=this.ii.b();if(w&&w.target==this.ii){f[M]=z;localStorage.setItem("sfwPrms",JSON.stringify(f))}else if(f[M]){this.ii.$(f[M],!0);
z=this.ii.b()}this.B2=jj.rk(W,M,j,I,z,this.ww);if(this.B2==null){this.On=null;return}e._g(this.o6);this.yk.BS();
var O=jj.ZO(M);if(O.vv){this.o6.innerHTML="<div></div>"}else if(O.Xq){var a=j,X=I,P;if(M=="PDF"){P=URL.createObjectURL(new Blob([this.B2],{type:"application/pdf"}))}else{P=URL.createObjectURL(new Blob([this.B2],{type:"image/svg+xml"}))}this.o6.innerHTML="<iframe src=\""+P+"\"></iframe>"}else{var Z=this.abW=O.Vu(this.B2),Y=Z[0],K=Y.XL,a=K.m,X=K.n;
if(Y.XE){var S=ICC.R(Y.XE.buffer),G=17,V=ICC.U.sampleLUT(S,G);for(var L=0;L<Z.length;L++){var T=new Uint8Array(Z[L].data);
ICC.U.applyLUT(V,G,T,T)}}this.yk.$(Z,Z.length>1?z[z.length-3]:0);this.o6.appendChild(this.yk.e);s="background: rgba(0,0,0,0);"}this.o6.setAttribute("style","display:block; "+(O.vv?"background:rgba(0,0,0,0);":"background-size:"+16/e.V()+"px;")+s);
this.zl(this.gA,this.ag,n)};function ey(){dB.call(this,[11,13],"shortcuts");var w=this.Bz=e.t("div","scrollable");
w.setAttribute("style","min-width:700px; max-height:500px; padding:1.5em");this.body.appendChild(w);
this.aaL()}ey.prototype=new dB;ey.prototype.f=function(){dB.prototype.f.call(this);this.aaL()};ey.prototype.aaL=function(){var w="<div style=\"line-height:1.4em; column-count:3; column-gap:3em; column-rule-width:1px;\" class=\"\">",n="",W=aK,D=W.CQ,j=W.WO,I=W.PJ;
n+="<h2 style=\"margin-top:0;\">Main Menu</h2>";n+=w;n+=this.YQ([[0,0],"---",[1,0],[D,W.ke],[1,2],[D,W.qd],[1,3],[j,D,W.qd],[1,8],[I,j,D,W.qd],[0,1],"---",[2,0],[j,D,W.xD],[2,1],[D,W.xD],[5,0],[D,W.Pn],[5,1],[D,W.Ak],[5,2],[D,W.tM],[2,2],"Delete",[2,3],[I,W.on],[10,16],[I,D,W.US],[12,79],[D,W.M$],[3],"---",[4,1],[D,W.zP],[4,2],[D,W.$g],[4,5],[D,W.Eg],[4,11],[D,W.Zb],[0,3],"---",[6,13],[j,D,W.r1],[6,49,0],[D,W.KZ],[6,6,0],[I,D,W.rP],[6,9],[D,W.rP],[6,10],[D,W.E],[0,5],"---",[7,0],[D,W.c],[7,1],[D,W.Rn],[7,2],[j,D,W.Zb],[0,7],"---",[8,0],[D,W.fQ],[8,1],[D,W.Ne],[8,3],[D,W.ip],[8,2],[D,W.iI],[8,4],[D,W.m5],[11,13],"?"]);
n+="</div>";n+="<h2 style=\"margin-top:1.5em;\">Navigation</h2>";n+=w;n+=this.YQ(["Vertical scroll","Wheel","Horizontal scroll",[D,"Wheel"],"Zooming",[I,"Wheel"]]);
n+="</div>";n+="<h2 style=\"margin-top:1.5em;\">Quick tools (press to enable, release to disable)</h2>";
n+=w;n+=this.YQ([[10,11],[D],[10,7],"Space",[10,17],[D,W.Xu]]);n+="</div>";n+="<h2 style=\"margin-top:1.5em;\">Tools</h2>";
n+=w;var U=ey.a,M=[];for(var L=0;L<U.length;L+=3)if(U[L+1])M.push(U[L],U[L+1]);M=M.concat([[24,16],"---",[22,7,1],"D",[22,7,0],"X",[6,6,1],"Q","Decrease Brush Size","[","Increase Brush Size","]","Decrease Hardness","{","Increase Hardness","}",[12,86],[D,W.aM]]);
n+=this.YQ(M);n+="</div>";this.Bz.innerHTML=n};ey.prototype.YQ=function(w){var n="",W=!0;for(var L=0;
L<w.length;L+=2){var D=w[L],j=aK.cO(w[L+1]);if(j==null){W=!1;continue}var I=e.VT(fV.get(D));if(j=="---"){if(!W)n+="<br/>";
n+="<div style=\"font-weight:bold; border-bottom: 1px solid;\">"+I+"</div>"}else n+="<div>"+I+" <span style=\"float:right; font-weight:bold;\">"+j+"</span> </div>";
W=!1}return n};ey.a=[[10,11],"V",0,[10,50],"V",70,[10,15],"M",1,[10,4],"M",2,[10,9],"L",5,[10,14],"L",6,[10,10],"L",7,[10,12],"W",9,[10,37],"W",8,[10,44],"W",3,[10,2],"C",10,[10,39],"C",11,[10,40],"C",12,[10,41],"C",13,[10,5],"I",14,[10,36],"I",16,[10,24],"J",18,[10,25],"J",19,[10,26],"J",20,[10,49],"J",21,[10,43],"J",22,[10,0],"B",23,[10,38],"B",24,[10,42],"B",25,[10,1],"S",27,[10,3],"E",31,[10,45],"E",32,[10,6],"G",34,[10,13],"G",35,[10,18],null,36,[10,19],null,37,[10,20],null,38,[10,21],"O",39,[10,22],"O",40,[10,23],"O",41,[10,8],"T",47,["VAR0 VAR1",[22,4,1],[10,8]],"T",48,[10,29],"P",42,[10,30],"P",43,[10,51],"P",44,[10,27],"A",51,[10,28],"A",52,[10,32],"U",54,[10,33],"U",55,[10,35],"U",57,[10,34],"U",56,[10,31],"U",58,[10,7],"H",59,[10,47],"H",60,[10,17],"Z",61];
function ax(){dB.call(this,[8,11,1],"soptions");this.KP=null;var w=e.t("div","form");w.style.width="20em";
this.body.appendChild(w);this.X2={Nm:[12,48],url:"URL",null:[12,71]};this.Qf={};for(var n in this.X2){var W=new e7(this.X2[n],null,15);
this.Qf[n]=W;w.appendChild(W.e)}this.QK=e.bp(this,w)}ax.prototype=new dB;ax.prototype.mQ=function(w,n,W){var D=n.Z;
this.KP=JSON.stringify(D);for(var j in this.X2){if(D[j])this.Qf[j].$(D[j].v)}};ax.prototype.j8=function(w){var n=JSON.parse(this.KP);
for(var W in this.X2){var D=this.Qf[W].b();n[W]={t:"TEXT",v:D}}var j=new ed(b.E.v,!0);j.G=y.Od;j.data=n;
j.HH=!0;this.S(j);this.close()};ax.prototype.f=function(){dB.prototype.f.call(this);this.QK.f()};function g3(){dB.call(this,[2,3],"fill");
this.ww=null;this.tI=null;var w=e.t("div","form padded");w.style.width="22em";this.body.appendChild(w);
this.Uf="FrgC BckC Clr Blck Gry Wht contentAware Ptrn".split(" ");this.Xp=new i0([2,3],[[12,45],[12,46],[12,47],[13,1,10],[13,1,7],[13,1,8],[6,48,0,3],[12,62]],[3,3,2]);
this.Xp.h(b.E.A,this.aci,this);w.appendChild(this.Xp.e);this.o6=e.t("span");w.appendChild(this.o6);this.MB=new gM;
this.MB.parent=this;this.MB.hR(0);this.j6=new jZ;this.j6.parent=this;this.WM=new i0([12,19,0],dD.AE,dD.E5);
w.appendChild(this.WM.e);this.nc=new f2([12,0],0,100,"%",0,!1);this.nc.$(100);w.appendChild(this.nc.e);
this.Wz=new b7([13,5]);this.Wz.$(!1);w.appendChild(this.Wz.e);this.QK=e.bp(this,this.body)}g3.prototype=new dB;
g3.prototype.X7=function(w,n){return w!=null};g3.prototype.wb=function(){return!0};g3.prototype.aci=function(){var w=this.Xp.b(),n=this.MB.e,W=this.j6.e,D=this.o6;
if(w==2)D.appendChild(n);else if(D.contains(n))D.removeChild(n);if(w==7)D.appendChild(W);else if(D.contains(W))D.removeChild(W)};
g3.prototype.f=function(){dB.prototype.f.call(this);this.Xp.f();this.WM.f();this.nc.f();this.Wz.f();
this.QK.f()};g3.prototype.j8=function(w){if(!this.tI.d2())return;var n=new ed(b.E.W1,!0),W=this.Xp.b();
n.data=y.JT.YE(this.Uf[W],dD.mS[this.WM.b()],this.nc.b()/100,this.MB.b(),this.Wz.b(),this.j6.b());this.close();
this.S(n)};g3.prototype.mQ=function(w,n){this.tI=w};g3.prototype.GZ=function(w,n){this.ww=w;if(n==bk.bI||n==bk.C0){this.j6.FC(w.V8);
this.j6.$({classID:"Ptrn",Nm:{v:"orangeslices",t:"TEXT"},Idnt:{v:"c7acb22a-47a6-11de-919a-bf574370eaaf",t:"TEXT"}})}};
function j4(){dB.call(this,[14,9],"stroke");this.ww=null;this.xG=e.t("div","form");this.xG.setAttribute("style","width:24em");
this.body.appendChild(this.xG);this.d1=new bF("FrFX",!0);this.d1.parent=this;var w=["Sz","Styl","Md","Opct"].concat(at.Oa);
for(var L=0;L<w.length;L++){var n=this.d1.CL[w[L]].e;this.xG.appendChild(n)}this.zp=!1;this.QK=e.bp(this,this.body)}j4.prototype=new dB;
j4.prototype.X7=function(w,n){return w!=null};j4.prototype.wb=function(){return!0};j4.prototype.f=function(){dB.prototype.f.call(this);
this.QK.f();this.d1.f()};j4.prototype.j8=function(w){var n=new ed(b.E.v,!0);n.G=y.rU;n.data={d:"stroke",auv:this.d1.b()};
this.close();this.S(n)};j4.prototype.mQ=function(w,n){if(!this.zp){var W=at.UR[at.order.indexOf("FrFX")];
W=JSON.parse(W);this.d1.update(w,W);this.zp=!0}var W=this.d1.b(),D=this.ww.Gp;W.Clr.v=E.M.lW({o:D>>16&255,B:D>>8&255,k:D&255});
this.d1.update(w,W)};j4.prototype.GZ=function(w,n){this.ww=w};function g0(){dB.call(this,[11,9],"textwarp");
this.Qf=new hJ;this.Qf.h(b.E.A,this.FI,this);this.Qf.parent=this;this.xG=e.t("div","form");this.xG.setAttribute("style","width:20em");
this.body.appendChild(this.xG);this.xG.appendChild(this.Qf.pf.e);this.xG.appendChild(this.Qf.Xx.e);this.xG.appendChild(this.Qf.UZ.e);
this.xG.appendChild(this.Qf.K0.e);this.xG.appendChild(this.Qf.Dy.e);this.QK=e.bp(this,this.xG);this.h("closebtn",this.$S,this)}g0.prototype=new dB;
g0.prototype.wb=function(){return!0};g0.prototype.f=function(){dB.prototype.f.call(this);this.QK.f();
this.Qf.f()};g0.prototype.FI=function(w){var n=this.Qf.b();this._5({d:"warp",XB:n})};g0.prototype._5=function(w){var n=new ed(b.E.v,!0);
n.G=y.Lu;n.data=w;n.HH=!0;this.S(n)};g0.prototype.$S=function(w){this._5({d:"warpCancel"})};g0.prototype.j8=function(w){this._5({d:"warpConfirm"});
this.close()};g0.prototype.mQ=function(w,n){var W=w.C[w.g[0]];this.Qf.$(W.add.TySh.hc)};function gh(){dB.call(this,[11,12,0],"trim");
var w=this.xG=e.t("div","form");this.xG.setAttribute("style","width:22em");this.body.appendChild(this.xG);
var n=new ga("Color To Trim:");w.appendChild(n.e);this.y6=new jw(null,["Top Left Pixel Color","Bottom Right Pixel Color",[13,1,9]],null,null,!0);
this.y6.$([!0]);this.xG.appendChild(this.y6.e);var n=new ga("Sides:");w.appendChild(n.e);this.EB=new jw(null,["Top","Left","Bottom","Right"]);
this.EB.$([!0,!0,!0,!0]);this.xG.appendChild(this.EB.e);this.QK=e.bp(this,this.body)}gh.prototype=new dB;
gh.prototype.X7=function(w,n){return w!=null};gh.prototype.wb=function(){return!0};gh.prototype.f=function(){dB.prototype.f.call(this);
this.y6.f();this.EB.f();this.QK.f()};gh.prototype.j8=function(w){var n=this.y6.b().indexOf(!0),W=this.EB.b(),D=new ed(b.E.W1,!0);
D.data=y.QJ.Mf(n,W);this.close();this.S(D)};function hT(){dB.call(this,"Raw Photopea","rawpea");this.p2=null;
this.Ad=null;this.body.style.padding="0";var w=this.UQ=new gu["Adobe Camera Raw Filter"](!0),n="<svg class=\"autoscale gsicon\" viewBox=\"0 0 14 18\" width=\"14\" height=\"18\" fill=\"black\"><path d=\"M14,6 L10,6 L10,0 L4,0 L4,6 L0,6 L7,13 L14,6 L14,6 Z M0,14 L0,16 L14,16 L14,14 Z\" /></svg>";
this.body.appendChild(w.e);this.QK=new iP([1,0],!0,null,!0);this.QK.h("click",this.j8,this);this.f0=new iP(n+" JPG",!0,null,!0);
this.f0.h("click",this.a2g,this);this.f0.e.style.marginTop="6px";w.$A(this.QK.e);w.$A(this.f0.e)}hT.prototype=new dB;
hT.prototype.aP=function(){return new ec(0,0)};hT.prototype.zl=function(w,n){this.UQ.zl(w,n)};hT.prototype.f=function(){dB.prototype.f.call(this);
this.UQ.f()};hT.prototype.a2g=function(w){var n=this.p2,W=this.Ad,D=jj.ZO("JPG").La([[this.UQ.b(!0).buffer]],W.kT,W.qV,[85]),j=new ed(b.E.L,!0);
j.data={d:b.c.pA,data:D,name:"photo.jpg"};this.S(j)};hT.prototype.j8=function(w){var n=this.p2,W=this.Ad,D=fd.X6(n),n={XL:new iB(0,0,W.kT,W.qV),data:this.UQ.b(!0).buffer,Zp:D},j=jj.Dk("Raw Photo",[n]),I=new ed(b.E.L,!0);
I.data={d:b.c.dH,On:j};this.S(I);this.fm();this.close()};hT.prototype.fm=function(){this.p2=null;this.Ad=null;
this.UQ.adp()};hT.prototype.mQ=function(w,n,W,D){this.p2=n.p0;var j=this.Ad=E.raw.awc(this.p2),I=E.raw.a66(n.p0),U=dS.t6(I);
E.raw.N9(j.Q0,j.Q0,n.p0,[U.iP,U.fH]);var M=cx._1("Adobe Camera Raw Filter");this.UQ.$(M,j.Q0,new iB(0,0,j.kT,j.qV))};
function hI(w){dB.call(this,w?[11,11,0]:[11,11,1],w?"vbitmap":"rcolors");this.n_=null;this.wn=null;this.ju=null;
this.a4=null;this.iz=null;this.arg=null;this.yV=null;this.pY="";this.go=w;this.fD=this.T5.bind(this);
this.iq=!1;this.body.style.padding="0";this.xG=e.t("div","form hbar padded");this.body.appendChild(this.xG);
var n=this.Tl={cnum:new g_([12,82],2,50,null),nois:new b7([12,81]),mode:new i0(null,["Cartoon","Photo"]),segm:new b7("Segmentize"),poly:new b7("Polygon"),merg:new b7("Merge colors"),polE:new g_("Roughness",2,30,null),dthr:new b7([12,23,3]),ok:e.bp(this,null,!1)},I=16;
for(var W in n){var D=n[W];D.parent=this;if(W!="ok")D.h(b.E.A,this.T5,this)}var j=this.wM=e.t("div","flexrow");
this.body.appendChild(j);j.setAttribute("style","background-color:var(--bg-canvas)");this.Ti=new hL;
this.Ti.h("viewchange",this.U2,this);this._J=new hL;this.T=e.t("canvas");this.T.setAttribute("style","margin:0 0 0 1px; padding:0; cursor:grab;");
this.VE=this.T.getContext("2d");var U=E.Q(16*16*4);E.b6(U,I,I,8);this.Vz=E.scale.GP(U,I,I);this.Ti.ayJ(this.T);
this.Ti.ui(this._J);this._J.ui(this.Ti);j.appendChild(this.Ti.e);if(w)j.appendChild(this.T);else j.appendChild(this._J.e)}hI.prototype=new dB;
hI.prototype.aP=function(){return new ec(0,0)};hI.prototype.wb=function(){return!0};hI.prototype.zl=function(w,n){this.gA=w;
this.ag=n;n=n-44;if(w<600)n-=29;if(this.n_==null)return;var W=this.n_.XL,D=gT.adl(w,n,W.m,W.n);if(D==1)n-=3;
if(D==0){w=Math.floor(w/2);e.W0(this.wM,"flexrow")}else{n=Math.floor(n/2);e.IX(this.wM,"flexrow")}e.dz(this.T,w,n);
this.Ti.zl(w,n);if(this.go)this.U2();else this._J.zl(w,n)};hI.prototype.oe=function(w,n,W,D){this.Ti.oe(D)};
hI.prototype.f=function(){dB.prototype.f.call(this);for(var w in this.Tl)this.Tl[w].f()};hI.prototype.mQ=function(w,n){this.yV=w;
this.iz=null;var W=w.C[w.g[0]],D=E.gq.FN(W.buffer.buffer,W.rect.m,W.rect.n).asz,j=D/((W.rect.m-2)*(W.rect.n-2)),I=this.Tl;
I.cnum.$(20);I.nois.$(j<.75);I.mode.$(j<.75?1:0);I.segm.$(!1);I.poly.$(!1);I.merg.$(!0);I.polE.$(1);
I.dthr.$(!1);var U=W.rect.clone();U.x=U.y=0;this.n_={XL:U,data:W.buffer.buffer.slice(0)};this.wn=null;
this.zl(this.gA,this.ag);this.Ti.$([this.n_]);this.Ti.bP();this.iq=!0;setTimeout(this.fD,20)};hI.prototype.T5=function(){var w=!0,n=Date.now(),W=this.n_,D=this.Tl,j=D.cnum.b(),I=D.nois.b(),U=D.mode.b(),M=D.segm.b(),m=D.poly.b(),l=D.merg.b(),A=D.polE.b(),S=null;
if(U==0)M=m=!1;var g=D.dthr.b(),k=["cnum","nois","mode"];if(U==1){k.push("segm");if(this.go){k.push("poly");
if(m)k.push("polE")}}if(this.go)k.push("merg");else k.push("dthr");k.push("ok");e._g(this.xG);for(var L=0;
L<k.length;L++)this.xG.appendChild(D[k[L]].e);if(w)console.log("---------------------------------------");
var $=I||M,C=I+","+M;if($&&(this.wn==null||this.pY!=C)){this.pY=C;var f=new Uint8Array(W.data),z=W.XL.m,s=W.XL.n;
if(I){if(this.iz==null){this.iz=f.slice(0);E.h1.tB=35;E.h1.jI(this.iz,this.iz,z,s,15,1);if(w){console.log("denoise",Date.now()-n);
n=Date.now()}}f=this.iz.slice(0)}else f=f.slice(0);if(M){var O=E.gq.pV(f,z,s,40,10),a=O.M$,X=new Uint8Array(a*4);
for(var L=0;L<a;L++){var P=L*4,Z=L*6,Y=1/O.pP[Z+5];X[P]=O.pP[Z]*Y;X[P+1]=O.pP[Z+1]*Y;X[P+2]=O.pP[Z+2]*Y}for(var L=0;
L<f.length;L+=4){var K=O.G2[L>>>2]*4;f[L]=X[K];f[L+1]=X[K+1];f[L+2]=X[K+2]}if(w){console.log("segm",Date.now()-n);
n=Date.now()}}this.wn={XL:W.XL.clone(),data:f.buffer}}if($)W=this.wn;var f=new Uint8Array(W.data),z=W.XL.m,s=W.XL.n;
for(var L=0;L<f.length;L+=4){if(f[L+3]<10)f[L]=f[L+1]=f[L+2]=f[L+3]=0}if(U==0){S=E.gq.a4k(f,z,s,j,$?.1:2e-4);
if(w){console.log("quantize",Date.now()-n);n=Date.now()}}if(U!=0||S&&S.mR.length<2){S=ic.ank(f.buffer,j,z,s)}if(this.go){var G=S.G2.slice(0);
for(var L=0;L<G.length;L++)G[L]++;var V=new Uint8Array((z+2)*(s+2));E.B0(G,new iB(1,1,z,s),V,new iB(0,0,z+2,s+2));
if(!m){var T=Math.round((z+2)*(s+2)/1e4),R=cf.jo(V.slice(0),z+2,s+2,Math.min(12,T)),x=cf.OV(R);if(w){console.log("trace smooth",Date.now()-n);
n=Date.now()}}else{var x=E.p.RF(V,z+2,s+2,A,w)}var v=x.length,N=new eh(1,0,0,1,-1,-1);for(var L=0;L<v;
L++)E.p.D(x[L].path.w,N,x[L].path.w);this.a4=x;this.ju=S;for(var L=0;L<v;L++){var u=x[L];for(var H=L+1;
H<v;H++){var F=x[H];if(F.parent==L&&S.mR[F.color-1].est.q[3]<.05){var t=F.path.F.slice(1),o=t.pop();
if(o!="Z")t.push(o);t.reverse();t=["M"].concat(t);if(o=="Z")t.push("Z");var q=[],R=F.path.w.length;for(var _=0;
_<R;_+=2){q[_]=F.path.w[R-2-_];q[_+1]=F.path.w[R-2-_+1]}E.p.concat(u.path,{w:q,F:t})}}}if(w){console.log("finding holes",Date.now()-n);
n=Date.now()}for(var L=0;L<x.length;L++){var d=x[L];if(d.parent!=-1){var r=x[d.parent];d.parent=r;if(r.bJ==null)r.bJ=[];
r.bJ.push(d)}d.depth=d.parent==-1?0:d.parent.depth+1}if(l){function p(fB,i){var ah={},eS=0,gL=0;for(var L=0;
L<fB.length;L++){var h2=fB[L].color,_="c"+h2;if(h2==i)throw h2;if(ah[_]==null)ah[_]=0;ah[_]++;if(ah[_]>eS){eS=ah[_];
gL=h2}}return gL}var Q=[],B=[],i=-1,c=!0;for(var L=0;L<x.length;L++)if(x[L].parent==-1)B.push(x[L]);
while(B.length!=0){var h2=p(B,i);i=h2;for(var L=0;L<B.length;L++)if(B[L].color==h2){var jX=B[L];Q.push(jX);
B.splice(L,1);L--;if(jX.bJ)for(var H=0;H<jX.bJ.length;H++){B.push(jX.bJ[H]);if(jX.bJ[H].color!=h2)c=!1}}}if(c)x=Q;
else{var bm=[];for(var dC=0;dC<500;dC++){var fn=[],R=bm[dC-1];bm.push(fn);for(var L=0;L<x.length;L++){var d=x[L],r=d.parent;
if(dC==0&&r==-1||dC!=0&&R.indexOf(r)!=-1){fn.push(d);x.splice(L,1);L--}}fn.sort(function(fB,ah){return fB.color-ah.color});
if(x.length==0)break}for(var L=0;L<bm.length;L++)x=x.concat(bm[L])}}else{var Q=[],fK=[];while(x.length!=0){fK.push(x.shift());
while(fK.length!=0){var i6=fK.pop();Q.push(i6);if(i6.bJ)for(var L=0;L<i6.bJ.length;L++){var d=i6.bJ[L];
x.splice(x.indexOf(d),1);fK.push(d)}}}x=Q}this.a4=x;for(var L=0;L<x.length;L++){var u=x[L],dh=S.mR[u.color-1].est.q;
if(dh[3]<=.05){x.splice(L,1);L--;continue}}for(var L=1;L<x.length;L++){var kA=x[L-1],u=x[L];if(kA.color==u.color&&(l||kA.parent==u.parent&&kA.depth>=2)){E.p.concat(kA.path,u.path);
x.splice(L,1);L--;continue}}if(w){console.log("reordering layers",Date.now()-n,v,x.length);n=Date.now()}this.U2()}else{var ig=new Uint32Array(z*s),iJ=z*s;
if(g){var fL=[];for(var L=0;L<S.mR.length;L++)fL.push(S.mR[L].est.rgba);var K=E.Q(z*s);UPNG.encode.dither(new Uint8Array(W.data),z,s,fL,new Uint8Array(ig.buffer),K)}else{for(var L=0;
L<iJ;L++){var h2=S.mR[S.G2[L]];ig[L]=h2.est.rgba}}this.arg=new Uint8Array(ig.buffer);this._J.$([{XL:W.XL,data:ig.buffer}]);
if(this.iq){this._J.bP();this.iq=!1}}};hI.prototype.U2=function(w){if(this.a4==null)return;var n=this.n_.XL.m,W=this.n_.XL.n,D=this.a4,j=this.ju.mR,I=this.T,U=this.VE,M=this.Ti.T3();
U.setTransform(1,0,0,1,0,0);U.clearRect(0,0,I.width,I.height);U.translate(I.width/2,I.height/2);U.scale(M.N,M.N);
U.translate(M.R.x/M.N-n/2,M.R.y/M.N-W/2);U.scale(1/M.N,1/M.N);U.fillStyle=this.Vz;U.fillRect(0,0,n*M.N,W*M.N);
U.scale(M.N,M.N);var m=[];for(var L=0;L<j.length;L++){var l=j[L].est.q;m.push({o:Math.round(255*l[0]),B:Math.round(255*l[1]),k:Math.round(255*l[2]),dl:Math.round(255*l[3])})}for(var L=0;
L<D.length;L++){var A=D[L],l=m[A.color-1];if(l.dl==0)continue;U.fillStyle="rgba("+l.o+","+l.B+","+l.k+","+l.dl/255+")";
U.beginPath();Typr.U.pathToContext({crds:A.path.w,cmds:A.path.F},U);U.fill()}};hI.prototype.j8=function(w){var n=this.yV,W=n.g[0],D=n.C[W],j=new ed(b.E.v,!0);
j.HH=!0;j.G=y.Yu;if(this.go){var I=this.a4,U=I.length==1,M=n.C.slice(0,W);if(!U)M.push(n.hG());for(var L=0;
L<I.length;L++){var m=I[L],l=this.ju.mR[m.color-1].est.q;E.p.D(m.path.w,new eh(1,0,0,1,D.rect.x,D.rect.y),m.path.w);
var A=n.QI();A.nz("Path "+L);M.push(A);A.opacity=Math.round(l[3]*255);A.FK|=16;A.add.SoCo={classID:"null",Clr:{t:"Objc",v:E.M.lW({o:255*l[0],B:255*l[1],k:255*l[2]})}};
A.add.vmsk=new h.Rd;A.add.vstk=JSON.parse(JSON.stringify(at.QO.default));A.add.vmsk.i=E.p.oF(m.path,!1);
A.add.vogk=[];A.hu();A.yb(n)}var g=M[M.length-1];if(!U){var A=n.QI();A.nz(D.getName());A.add.lsct=ef.fz;
A.Bx="pass";A.FK=24;M.push(A);g=A}var k=D.add.lmfx;if(k)g.add.lmfx=JSON.parse(JSON.stringify(k));for(var L=W+1;
L<n.C.length;L++)M.push(n.C[L]);j.data={d:h.ZM,_B:M,TY:[W+I.length+(U?-1:1)],s7:[11,11,0]}}else{var M=n.C.slice(0),A=n.QI();
A.nz(D.getName());M.splice(n.g[0]+1,0,A);A.rect=D.rect.clone();A.buffer=this.arg;A.l();j.data={d:h.ZM,_B:M,TY:[n.g[0]+1],s7:[11,11,1]}}this.S(j);
this.close()};function gT(w){dB.call(this,[[7,11],[7,13]][w],["redge","magiccut"][w]);this.y6=w;this.n_={};
this.rN=null;this.Yo=null;this.yV=null;this.OQ=null;this.yu=null;this.body.style.padding="0";this.c5=[];
this.S3=-1;this.xG=e.t("div","form hbar padded");this.body.appendChild(this.xG);this.Hz=new ch;this.Hz.parent=this;
this.Hz.h(b.E.A,this.eg,this);this.xG.appendChild(this.Hz.e);var n=w==0?["#ffffff","#888888","#000000"]:["#00dd00","#888888","#ff0000"];
n=n.concat("tools/hand","zoomIn","zoomOut");var W=w==0?[[12,45],"Unknown",[12,46]]:[[12,45],"Erase",[12,46]];
this.XS=new cu(null,n,W,28);this.XS.h(b.E.A,this.oe,this);this.xG.appendChild(this.XS.e);this.CR=new g_([7,9],0,50,null);
this.CR.parent=this;this.CR.h(b.E.A,[this.a7T,this.T5][w],this);this.xG.appendChild(this.CR.e);var D=this.a9p=new iP([2,2],!1,null,!0);
D.h("click",this.fm,this);this.xG.appendChild(D.e);var j=this.dB=e.t("span","form");this.xG.appendChild(j);
var I=this.aoj=new iP([12,90],!1,null,!0);I.h("click",function(m){alert(w==0?fV.get([15,7,1]):"Mark the object with Green, background with Red. Two colors should never touch.",5e3)},this);
j.appendChild(I.e);var U=new iP("Tutorial",!1,null,!0);U.h("click",this.anG,this);j.appendChild(U.e);
this.eV=new cu([12,46],["checker","#ffffff","#000000"]);this.eV.h(b.E.A,this.awJ,this);j.appendChild(this.eV.e);
this.Tk=new i0(null,[[6,13],[6,2],[17,2]]);j.appendChild(this.Tk.e);this.QK=e.bp(this,j,!1);var M=this.wM=e.t("div","flexrow");
this.body.appendChild(M);this.QN=new hL(!0);this.FU=new hL;this.QN.ui(this.FU);this.FU.ui(this.QN);this.QN.h("mousedown",this.jx,this);
this.QN.h("mousemove",this.Gi,this);this.QN.h("mouseup",this.WB,this);this.QN.h("zoom",this.eg,this);
this.FU.h("zoom",this.eg,this);M.appendChild(this.QN.e);M.appendChild(this.FU.e)}gT.prototype=new dB;
gT.prototype.X7=function(w,n){var W=w!=null&&!w.C[w.g[0]].rect.VY();if(!W)alert("The layer is empty.");
return W};gT.prototype.aP=function(){return new ec(0,0)};gT.prototype.wb=function(){return!0};gT.prototype.zl=function(w,n){this.gA=w;
this.ag=n;n=n-12-33;if(w<900){this.dB.setAttribute("style","display:block; text-align:right;");n-=29}else{this.dB.setAttribute("style","position:absolute; right:0px")}this.eV.wV(w<440?null:[12,46]);
this.CR.wV(w<470?null:[7,9]);var W=this.n_.rect;if(W){var D=gT.adl(w,n,W.m,W.n);if(D==0){w=Math.floor(w/2);
e.W0(this.wM,"flexrow")}else{n=Math.floor(n/2);e.IX(this.wM,"flexrow")}this.QN.zl(w,n);this.FU.zl(w,n)}};
gT.adl=function(w,n,W,D){var j=w/2,I=n/2,U=Math.min(j/W,n/D),M=Math.min(w/W,I/D);return U>M?0:1};gT.prototype.f=function(){dB.prototype.f.call(this);
this.Hz.f();this.CR.f();this.QK.f();this.eV.f();this.Tk.f();this.a9p.f();this.aoj.f()};gT.prototype.anG=function(w){window.open("//www.photopea.com/"+["learn/refine-edge","tuts/magic-cut-remove-image-background-online"][this.y6],"_blank")};
gT.prototype.GZ=function(w,n){this.Yo=w;if(n==bk.zq||n==bk.bI){this.Hz.FC(w.t$);this.Hz.$(bj.os(),w.t$.yg,w.t$.j6)}};
gT.prototype.oe=function(w,n,W,D){var j=this.XS.b();if(D==null){this.QN.oe(hL.acD(j-3));return}this.OQ=D;
var I=y.JT.u_(this.Hz.b(),D);if(I!=null){this.Hz.$(I);this.eg()}else if(D.U(aK.CQ)&&D.U(aK.xD)){var U=this.c5,M=0;
if(D.U(aK.WO)){if(this.S3+1<U.length)M=1}else if(this.S3>0)M=-1;if(M!=0){this.S3+=M;var m=this.S3,l=this.n_;
if(M==1)E.Cb(U[m][2],U[m][0],l.uY,l.rect);else E.Cb(U[m+1][1],U[m+1][0],l.uY,l.rect);l.oD=l.rect;this.T5()}}else if(j<3)this.QN.oe(D)};
gT.prototype._n=function(w){var n=this.n_,W=this.c5,D=E.Q(w.O()*4);E.Cb(n.Sa,n.rect,D,w);n.Sa=null;var j=E.Q(w.O()*4);
E.Cb(n.uY,n.rect,j,w);this.S3++;W[this.S3]=[w.clone(),D,j];while(W.length>this.S3+1)W.pop();while(W.length>50){W=W.slice(1);
this.S3--}};gT.prototype.eg=function(){var w=this.Yo,n=iV.QM(this.Hz.b(),w.t$.yg,this.QN.T3().N);this.QN.$J(n)};
gT.prototype.jx=function(w){var n=this.Yo,W=this.n_,D=this.OQ,j=this.Hz.b(),I=this.QN.PD(),U=[16777215,8421504,0][this.XS.b()];
this.rN=new iV(j,n.t$.yg,n.t$.j6,{Z8:1,dE:!0},U,n.as,W.rect);W.Sa=W.uY.slice(0);if(D!=null&&D.U(aK.WO)&&this.yu){this.rN.moveTo(this.yu.x,this.yu.y);
this.rN.lineTo(I.x,I.y)}else this.rN.moveTo(I.x,I.y);this.a1z()};gT.prototype.Gi=function(w){var n=this.n_,W=this.QN.PD();
this.rN.lineTo(W.x,W.y);this.a1z()};gT.prototype.WB=function(w){this.yu=this.QN.PD();this._n(this.rN.oi());
this.T5()};gT.prototype.a1z=function(){var w=this.n_,n=this.rN,W=n.iO();if(W.VY())return;w.oD=W;E.s._U("norm",n._a(),n.pJ(),w.uY,w.rect,W,1);
this.aek()};gT.prototype.fm=function(w){var n=this.n_;n.Sa=n.uY.slice(0);n.oD=n.rect;E.cJ(n.uY,[4278190080,4292730333][this.y6]);
this._n(n.rect);this.T5()};gT.prototype.mQ=function(w,n){this.yV=w;var W=w.C[w.g[0]],D=W.rect.clone(),j=D.m,I=D.n;
this.CR.$(this.y6==0?3:j*I<3e6?3:0);this.XS.$(w.J==null?0:1);this.CR.rx();if(this.y6==0&&w.J!=null||this.y6==1)this.CR.Te();
var U=this.y6,M=E.Q(D.O()),m=new Float32Array(D.O());if(U==0&&w.J){E.B0(w.J.channel,w.J.rect,M,D);var l=E.Q(D.O());
for(var A=0;A<I;A++)for(var g=0;g<j;g++){var L=A*j+g,k=M[L];if(g>0&&M[L-1]!=k||g<j-1&&M[L+1]!=k||A>0&&M[L-j]!=k||A<I-1&&M[L+j]!=k)l[L]=255}E.style.Wf(l,m,j,I)}else m.fill(1e9);
D.x=D.y=0;this.n_={rect:D,Q0:W.buffer,Py:M,TH:m,kh:E.Q(D.O()*4),kB:E.Q(D.O()*4),uY:E.Q(D.O()*4),Sa:null,aS:null,oD:D,arT:{}};
if(U==0)this.a7T();else{this.n_.arT=y.fc.aiJ(w);var $=this.n_.uY;E.cJ($,4287137928);var C=E.Np.getSelection(W.buffer,j,I),f=Math.round(j/60),z=Math.round(.7*I);
for(var A=0;A<I;A++)for(var g=0;g<j;g++){var s=(A*j+g)*4,O=C[s>>>2];O=O>128?255:128;if(A<f||A<z&&(g<f||g>j-1-f))O=0;
$[s]=$[s+1]=$[s+2]=O}this.T5()}this.c5=[1];this.S3=0;var a=this.Hz.b();a.Brsh.v.Dmtr.v.val=Math.round(D.m/(U==0?10:20));
this.Hz.$(a);this.eg();this.zl(this.gA,this.ag);this.QN.bP()};gT.prototype.a7T=function(){var w=this.n_,n=w.rect.O(),W=this.CR.b(),D=w.Py.slice(0);
for(var L=0;L<n;L++)if(w.TH[L]<W)D[L]=128;E.cJ(w.uY,4294967295);E.IL(D,w.uY,0);E.IL(D,w.uY,1);E.IL(D,w.uY,2);
w.oD=w.rect;this.T5()};gT.prototype.T5=function(){var w=this.n_,j,M,m=0,l=0,A=0;this.aek();var n=w.rect,W=n.m,D=n.n,I=E.Q(n.O()),U=w.Q0;
E.hN(w.uY,I,0);for(var L=0;L<I.length;L++){if(U[(L<<2)+3]!=255)continue;var g=I[L];if(g==0)m++;else if(g==255)l++;
else A++}if(m*l*A!=0){if(this.y6==0)M=E.z4.z4(n,U,I);else{var k=this.XS.b();for(var $=1;$<D;$++)for(var C=1;
C<W;C++){var L=$*W+C,f=I[L],z=I[L-1];if(f==0&&z==255||f==255&&z==0){j="The Red and Green should never touch! Erase it with Grey.";
break}}var s=Date.now(),O=this.n_.arT;E.nX(I,O.mB);y.fc.so(O,!0);var a=Math.ceil(this.CR.b()/2);if(a==0){M=U.slice(0);
E.IL(O.J,M,3)}else{var X=O.J.slice(0),P=O.J.slice(0);for(var Z=0;Z<a;Z++){for(var $=1;$<D-1;$++)for(var C=1;
C<W-1;C++){var L=$*n.m+C,Y=X[L];if(X[L-W]!=Y||X[L-1]!=Y||X[L+1]!=Y||X[L+W]!=Y)P[L]=128;else P[L]=Y}var K=X;
X=P;P=K}M=E.z4.z4(n,U,X,20,!1)}}}else{M=U.slice(0);E.IL(I,M,3)}for(var L=3;L<M.length;L+=4)if(M[L]>U[L])M[L]=U[L];
if(n.s9(w.rect))w.aS=M;else E.Cb(M,n,w.aS,w.rect);this.awJ();if(j)alert(j,4e3)};gT.prototype.aek=function(w){var n=this.n_,W=n.oD;
E.Cb(n.Q0,n.rect,n.kh,n.rect,W,!0);var D=n.uY;if(this.y6==1){var j=new Uint32Array(256);j[0]=4278190335;
j[255]=4278255360;var I=n.rect.O();D=D.slice(0);var U=new Uint32Array(D.buffer);for(var L=0;L<I;L+=2){U[L]=j[U[L]&255];
U[L+1]=j[U[L+1]&255]}}E.s._U("norm",D,n.rect,n.kh,n.rect,W,.3);this.QN.$([{XL:n.rect,data:n.kh.buffer}])};
gT.prototype.awJ=function(w){var n=this.n_;E.cJ(n.kB,[0,4294967295,4278190080][this.eV.b()]);E.s._U("norm",n.aS,n.rect,n.kB,n.rect,n.rect,1);
this.FU.$([{XL:n.rect,data:n.kB.buffer}])};gT.prototype.j8=function(w){var n=this.yV,W=this.n_,D=this.Tk.b(),j=n.C[n.g[0]],I=new ed(b.E.v,!0);
I.HH=!0;var U=j.rect.clone();if(D==0&&j.I4()||D!=0&&!j.I4()){I.G=y.Yu;I.data={d:h.Ll,j:n.g[0]};this.S(I)}if(n.J!=null){I.G=y.wA;
I.data={d:"fromAction",bs:y.eZ.Jj()};this.S(I)}if(D==0){var M=n.C.slice(0),m=n.QI();m.nz(j.getName());
M.splice(n.g[0]+1,0,m);m.rect=U;m.buffer=W.aS;m.l();I.G=y.Yu;I.data={d:h.ZM,_B:M,TY:[n.g[0]+1],s7:[7,11]};
this.S(I)}if(D==1){var l=j._N();I.G=y.Yu;I.data={d:h.uV,acm:!0};this.S(I);var A=j._N();A.channel=E.Q(U.O());
A.rect=U;A.color=0;A.eP=!0;E.hN(W.aS,A.channel,3);if(l){var g=A.y9(l);A.rect=g.rect;A.channel=g.channel;
A.color=g.color}A.ky();j.yb()}if(D==2){var k={rect:U,channel:E.Q(U.O())};E.hN(W.aS,k.channel,3);I.G=y.wA;
I.data={d:"setsel",J:k,s7:this.II};this.S(I)}this.close()};function ft(){dB.call(this,[1,13],"locstor");
this.ww=null;this.b_=[];var w=this.body,n=e.t("p");n.textContent="These files are loaded every time you start Photopea.";
w.appendChild(n);this.aab=0;this.KM=e.t("span");w.appendChild(this.KM);this.KM.setAttribute("style","display:inline-block; width:12em; font-weight:bold;");
var W=e.t("span","form");w.appendChild(W);this.g1=new iP([5,4],!1,null,!0);this.g1.h("click",this.yN,this);
W.appendChild(this.g1.e);this.tR=new iP("Get all as ZIP",!1,null,!0);this.tR.h("click",this.lZ,this);
W.appendChild(this.tR.e);this.Fq=new dX(!0);this.Fq.parent=this;this.Fq.h8(1);w.appendChild(this.Fq.e);
this.Fq.e.setAttribute("style","width: 40em; height: 25em")}ft.prototype=new dB;ft.prototype.f=function(){dB.prototype.f.call(this);
this.KM.textContent=fV.get([13,2])+": "+fp.cN(this.aab);this.g1.f()};ft.prototype.GZ=function(w,n){this.ww=w;
if(n==bk._w)this.mQ()};ft.prototype.mQ=function(w,n){var W=this.ww.AJ.rA,m=0;this.b_=[];for(var D in W)this.b_.push(D);
this.b_.sort(function(A,g){A=A.split(".");g=g.split(".");return A[1]==g[1]?A[0]<g[0]?-1:1:A[1]<g[1]?-1:1});
var j=Math.floor(100*e.V()),I=Math.floor(16*e.V()),U=[],M=[];for(var L=0;L<this.b_.length;L++){var D=this.b_[L],l=ft.sX(D,W[D],j,I);
U.push(l);M.push(D);m+=W[D].byteLength}this.Fq.jJ(U,M,j,I);this.aab=m;this.f()};ft.prototype.yN=function(w){var n=this.Fq.b();
if(n.length==0){alert("Select a file first.");return}this.Fq.$([]);var W=this.ww.AJ.rA;for(var L=0;L<n.length;
L++)delete W[this.b_[n[L]]];var D=new ed(b.E.L,!0);D.data={d:b.c.oj,AH:bk._w};this.S(D)};ft.prototype.lZ=function(w){var n=this.ww.AJ.rA,W={};
for(var D in n)W[D]=new Uint8Array(n[D]);var j=UZIP.encode(W);e8.save(j,"resources.zip")};ft.sX=function(w,n,W,D){var j=e.t("canvas"),M=0;
j.width=W;j.height=D;var I=j.getContext("2d"),U=w.split(".").pop().toLowerCase();for(var L=0;L<U.length;
L++)M+=U.charCodeAt(L)*613<<8*L;I.fillStyle="#"+E.$$(M&16777215);I.fillRect(0,0,20,D);var m=Math.floor(14*e.V());
I.fillStyle="#000000";I.font="bold "+m+"px sans-serif";var l=(D-m)/2,A=fp.cN(n.byteLength),g=I.measureText(A);
I.fillText(A,W-12-g.width,D-l);return j.toDataURL()};function d_(){dB.call(this,[1,15],"pmanager");this.ww=null;
this.ps=new i0([12,44],[[9,3],[12,37],[12,62],[11,6],[12,77],[12,21]]);this.ps.h(b.E.A,this.mQ,this);
this.body.appendChild(this.ps.e);var w=e.t("div","flexrow");this.body.appendChild(w);var n=this.a8_=e.t("div");
w.appendChild(n);var W=e.t("div","form");w.appendChild(W);W.setAttribute("style","width:140px; margin-left:12px");
this.ac0=[bk.zq,bk.tU,bk.C0,bk.gB,bk.Iv,bk.tX];this.uH=[new ch,new jr,new jZ,new jR,new df,new jJ];for(var L=0;
L<this.uH.length;L++)this.uH[L].parent=this;this.M2=[];for(var L=0;L<4;L++){var D=new iP("Hello",!0,null,!0);
D.h("click",this.lE,this);this.M2.push(D);W.appendChild(D.e)}this.mQ()}d_.prototype=new dB;d_.prototype.wO=function(w){return w==aK.m2||w==aK.on};
d_.prototype.lE=function(w){var L=this.M2.indexOf(w.target);this.uH[this.ps.b()].Al(L)};d_.prototype.f=function(){dB.prototype.f.call(this);
this.ps.f();for(var L=0;L<this.uH.length;L++)this.uH[L].f();var w=this.M2,n=this.ps.b(),W=bk.Fj[this.ac0[n]],D=W[0].toUpperCase();
w[0].wV([[23,6],"."+D]);w[1].wV(["VAR0 ."+D,[1,8]]);w[2].wV([6,37]);w[3].wV([5,4])};d_.prototype.GZ=function(w,n){this.ww=w;
this.mQ()};d_.prototype.mQ=function(w,n){if(!e.LY(this.e))return;this.f();e._g(this.a8_);this.a8_.appendChild(this.uH[this.ps.b()].sz);
var W=this.uH,D=this.ww;if(D==null)return;W[0].FC(D.t$);W[1].Wc(D.Gp,D.as);W[1].FC(D.wX);W[2].FC(D.V8);
W[3].FC([D.IH,D.V8]);W[4].FC(D.Jz);W[5].FC(D.h$)};function kw(w,n,W){dB.call(this,n,"cwindow");this.auS=new ec(W[0],W[1]-33);
this.xG=e.t("div","form");this.xG.setAttribute("style","width:"+(W[2]-W[0])+"px; height:"+(W[3]-W[1])+"px");
this.body.appendChild(this.xG)}kw.prototype=new dB;kw.prototype.aP=function(w,n){return this.auS.clone()};
function co(w){var n=co.agk(w);dB.call(this,n,"res"+w);var W=this.ar6.bind(this);window.addEventListener("message",function(j){if(typeof j.data=="string"&&j.data.startsWith("--et ")){console.log(j.data);
var I=this.afB=j.data.slice(5).split(",");I[0]=parseFloat(I[0]);bh.W7(I[0],I[1],W)}}.bind(this));this.lU=n;
this.ki=w;this.ahs=null;this.x_=null;this.O1=0;this.MI=null;this._8=null;this.afB=null;this.ww=null;
this.body.setAttribute("style","padding:0");this.vR=new iP("",null,null,!0);this.body.appendChild(this.vR.e);
this.vR.h("click",this.dm,this);this.vR.e.setAttribute("style","position:absolute; margin-top: -28px; margin-left:150px");
this.P0=e.t("span","form");this.body.appendChild(this.P0);this.P0.setAttribute("style","position:absolute; margin-top: -31px; margin-left:270px");
this.M2=[];for(var L=0;L<9;L++){var D=new iP(co.agk(L));this.M2.push(D);if(L==w)D.$(!0);this.P0.appendChild(D.e);
D.h("click",this.a7l,this)}this.pu=new iP([5,3],null,null,!0);this.pu.h("click",this.a57,this);this.az4=new iP("Upload Current Document as a Template",null,null,!0);
this.az4.h("click",this.apG,this);this.AX=new e7("Creator / Brand name");this.XO=new iP([1,2],null,null,!0);
this.XO.h("click",this.lZ,this);this.UC=e.t("iframe","scrollable");this.UC.setAttribute("style","border:none; margin:0; padding:0;");
this.sh=e.t("div","form scrollable padded");this.ZN=new cg(w);this.ZN.h("back",this.fm,this);this.ZN.h("save",this.azm,this);
this.body.appendChild(this.UC)}co.prototype=new dB;co.agk=function(w){var n;if(w==0)n=[25,0];else if(w==1)n="Plugins";
else for(var W in bk.Fj)if(bk.Fj[W][4]==w)n=bk.Fj[W][3];return n};co.prototype.a7l=function(w){var L=this.M2.indexOf(w.target);
if(L==this.ki)return;this.close();var n=new ed(b.E.L,!0);n.data={d:b.c.P2,jW:"res"+L};this.S(n)};co.prototype.ar6=function(w){this.dm();
this._8=JSON.parse(w.target.response);this.ba()};co.prototype.aP=function(w,n){return new ec(0,0)};co.prototype.zl=function(w,n){this.gA=w;
this.ag=n;this.tI=null;n=n-4;w=w;var W=this.sh;W.style.width=w-12+"px";W.style.height=n-12+"px";var W=this.ZN.e;
W.style.width=w-12+"px";W.style.height=n-12+"px";var W=this.UC;W.style.width=w+"px";W.style.height=n+"px";
this.Tf()};co.prototype.GZ=function(w,n){this.ww=w};co.prototype.f=function(){dB.prototype.f.call(this);
for(var L=0;L<this.M2.length;L++)this.M2[L].f();this.pu.f()};co.prototype.mQ=function(w,n,W,D){this.tI=w;
this.dm(null,!1)};co.prototype.dm=function(w,n){var W=n!=null?n:e.LY(this.UC);if(W){if(!bh.bH()){alert("You need to log in first!");
return}var D=bh.bl();this.x_=D.tpl?D.tpl.list:[];this.AX.$(D.tpl&&D.tpl.brnd?D.tpl.brnd:"");this.Tf()}else{this.UC.setAttribute("src","");
this.UC.setAttribute("src","templates/?type="+this.ki+"&rsrc="+this.ww.O2.join(","))}this.body.removeChild(this.body.children[this.body.children.length-1]);
this.body.appendChild(W?this.sh:this.UC);var j=fV.get(this.lU);this.vR.wV(W?"All "+j:"Add "+j)};co.prototype.Tf=function(){var w=fV.get(this.lU),n=this.x_,W=this.ki,M=450;
if(n==null)return;var D=this.sh;e._g(D);var j=e.t("h1");D.appendChild(j);j.textContent="Share your "+w+" with the world!";
var I=e.t("ul");D.appendChild(I);var U=e.t("li");I.appendChild(U);U.textContent="By publishing your "+w+", you agree to let others use them for all kinds of purposes, even commercially.";
D.appendChild(this.pu.e);if(W==0)D.appendChild(this.az4.e);e.x$(D);D.appendChild(this.AX.e);D.appendChild(this.XO.e);
e.x$(D);M=(this.gA-20)/Math.max(1,Math.floor(this.gA/M))-42;var m="display:inline-block; width:"+M+"px; height:140px; overflow:hidden; background-color:rgba(255,255,255,0.2); margin:10px 20px 0px 0; line-height:1.5em; padding:10px;";
for(var L=n.length-1;L>=0;L--){var l=n[L];if(l.type==null)l.type=0;if(l.type!=W)continue;var A=e.t("div");
D.appendChild(A);A.setAttribute("style",m);var g=e.t("img");A.appendChild(g);g.setAttribute("src",l.thmb);
g.setAttribute("style","float:left; height:10em; width:10em; object-fit: contain; margin-right: 1em; margin-bottom:1em;");
var k=e.t("h3");A.appendChild(k);k.textContent=l.name;k.setAttribute("style","margin:0 0 10px 0");var $=e.t("p");
A.appendChild($);$.textContent=l.desc;$.setAttribute("style","height:76px; overflow:hidden; margin-bottom: 6px;");
for(var C=0;C<2;C++){var f=new iP(C==0?"Edit":"Delete",null,null,!0);f.aj8=L;f.ba=C==0;f.h("click",this.afd,this);
A.appendChild(f.e)}}};co.prototype.apG=function(w){if(this.tI==null){alert("No document opened.");return}var n=confirm("Your document will be uploaded to Photopea.com and a preview to Imgur.com. Proceed?");
if(!n)return;var W=new ed(b.E.L,!0);W.data={d:b.c.J6,$x:"psd",Xm:this.amS.bind(this)};this.S(W)};co.prototype.amS=function(w){this.a20=w;
var n=new ed(b.E.L,!0);n.data={d:b.c.J6,$x:"jpg",Xm:this.a9i.bind(this),abt:1400};this.S(n)};co.prototype.a9i=function(w){this.MI={type:0,catg:0,desc:"",file:this.a20,name:this.tI.name.split(".")[0],thmb:w,publ:!0,utme:""};
this.ba()};co.prototype.a57=function(w){this.MI={type:0,catg:0,desc:"",file:"",name:"",thmb:"",publ:!0,utme:""};
this.ba()};co.prototype.afd=function(w){this.O1=w.target.aj8;if(!w.target.ba){if(!window.confirm("Are you sure you want to delete your template?"))return;
this.x_.splice(this.O1,1);this.lZ();this.Tf();return}this.ba()};co.prototype.ba=function(){if(e.LY(this.sh))this.body.removeChild(this.sh);
this.body.appendChild(this.ZN.e);var w=this.MI?this.MI:this._8?this._8:this.x_[this.O1];if(w.type==null)w.type=0;
this.ZN.$(w)};co.prototype.azm=function(w){var n=this.ZN.b();if(this.MI)this.x_.push(n);else if(this._8){var W=this.afB;
bh.W7(W[0],W[1],this.fm.bind(this),JSON.stringify(n));return}else this.x_[this.O1]=n;this.lZ();this.fm()};
co.prototype.fm=function(){var w=this._8;this.MI=null;this._8=null;this.body.removeChild(this.ZN.e);
this.body.appendChild(this.sh);this.Tf();if(w)this.dm()};co.prototype.lZ=function(){var w=bh.bl();if(this.x_.length==0)delete w.tpl;
else{w.tpl={list:JSON.parse(JSON.stringify(this.x_))};var n=this.AX.b().trim();if(n!="")w.tpl.brnd=n}bh.qK(w,function(){alert("Saved.")})};
function cX(){dB.call(this,"Make Selection","makesel");this.ww=null;var w=e.t("div","form");this.body.appendChild(w);
this.iN=new b7([12,25,1]);this.iN.$(!0);w.appendChild(this.iN.e);e.x$(w);this.TO=new jb(!0);w.appendChild(this.TO.e);
this.QK=e.bp(this,this.body)}cX.prototype=new dB;cX.prototype.f=function(){dB.prototype.f.call(this);
this.TO.f();this.iN.f();this.QK.f()};cX.prototype.j8=function(w){var n=new ed(b.E.v,!0);n.G=y.wA;n.data={d:"frompath",HD:[null,0,this.TO.b(),this.iN.b()]};
this.close();this.S(n)};function jI(){dB.call(this,["VAR0 PSD/PSB",[1,2]],"savepsb");this.tI=null;this._V=null;
this.NT=null;var w=this.aeM=e.t("div","form");w.setAttribute("style","width:20em");this.body.appendChild(w);
this.lP=new j$([12,50],["PSD","PSB"]);this.lP.h(b.E.A,this.w$,this);w.appendChild(this.lP.e);e.R2(w);
var n=new ga("Minify the file");w.appendChild(n.e);e.x$(w);var W=["Blank preview image","ZIP for pixel data","Remove Smart Object pixels","Put the file into ZIP"];
this.Gh=[];for(var L=0;L<W.length;L++){var D=new b7(W[L]);this.Gh.push(D);w.appendChild(D.e);D.h(b.E.A,this.w$,this)}e.R2(w);
this.tr=new ga("aa.psd");this.k1=new ga("10 kB");w.appendChild(this.k1.e);this.aeC=new ga("1000 B");
w.appendChild(this.aeC.e);this.QK=new iP([1,2],!0,null,!0);this.QK.h("click",this.j8,this);w.appendChild(this.QK.e);
this.YO=new iP(["VAR0 (Google Drive)",[1,2]],!0,null,!0);this.YO.h("click",this.j8,this);w.appendChild(this.YO.e);
this.h("closebtn",this.$S,this)}jI.prototype=new dB;jI.prototype.mQ=function(w,n,W,D){var j=e.LY(this.YO.e),I=w.Kh!=null&&w.Kh.q5=="psd";
if(I&&!j)this.aeM.appendChild(this.YO.e);if(!I&&j)this.aeM.removeChild(this.YO.e);for(var L=0;L<this.Gh.length;
L++)this.Gh[L].$(!1);this.tI=w;this.w$()};jI.prototype.j8=function(w){if(w.target==this.QK)e8.save(this._V,this.NT);
else{if(this.Gh[3].b()){alert("You should not save a ZIP as a PSD to Google Drive.");return}g1.amP(this.tI,this._V)}};
jI.prototype.$S=function(){this.tI=null;this._V=null};jI.prototype.w$=function(){var w=this.tI,n=[!1,!1,!1,!1];
for(var L=0;L<3;L++)n[L]=this.Gh[L].b();var W=this.Gh[3].b(),D=n[3]=this.lP.b()==1,j=w.name.slice(0,w.name.length-3),I=this._V=jj.ZO("PSD").La(w,0,0,n),bK=this.NT=j+"ps"+(D?"b":"d");
if(W){var U={};U[bK]=new Uint8Array(I);I=this._V=UZIP.encode(U);bK=this.NT=j+"zip"}this.tr.$(bK);this.k1.$(fp.cN(I.byteLength));
this.k1.e.style["font-size"]="2em";this.aeC.$(" \u2001 "+I.byteLength+" B");this.QK.wV(fV.get([1,2])+" \""+bK+"\"")};
jI.prototype.f=function(){dB.prototype.f.call(this);this.lP.f();this.QK.f();this.YO.f()};function fJ(){dB.call(this,"Confirm","confirm");
this.FJ=null;var w=e.t("div");w.setAttribute("style","margin-bottom:1em");this.body.appendChild(w);this.aG=e.t("div");
this.aG.textContent="Hello";w.appendChild(this.aG);this.QK=e.bp(this,this.body)}fJ.prototype=new dB;
fJ.prototype.j8=function(w){if(this.FJ==null)return;console.log("okconfirm");this.close();this.FJ();
this.FJ=null};fJ.prototype.mQ=function(w,n){if(n.a7m)this.aG.innerHTML=n.Z;else this.aG.textContent=n.Z;
this.FJ=n.FJ;this.QK.e.focus();if(n.a7m!=null)this.e.style.top=Math.random()*(window.innerHeight-150)+"px";
this.aiF=n.a7m!=null};fJ.prototype.aP=function(w,n){return new ec(Math.max(0,(w-500)/2),Math.max(0,Math.min(60,(n-100)/2)))};
fJ.prototype.zl=function(w,n){this.aG.style.width=w-30+"px"};function aN(){dB.call(this,[1,16,2],"newartb");
this.y6=0;this.IN=null;var w=e.t("div","form");w.style.width="260px";this.body.appendChild(w);this.Fq=new dZ;
w.appendChild(this.Fq.e);this.QK=e.bp(this,w)}aN.prototype=new dB;aN.prototype.X7=function(w,n){return w!=null};
aN.prototype.j8=function(w){var n=this.Fq.b();this.IN.m=n.x;this.IN.n=n.y;var W=new ed(b.E.v,!0);W.G=y.yl;
W.data={aap:this.IN,IZ:this.y6};this.S(W);this.close()};aN.prototype.f=function(){dB.prototype.f.call(this);
this.Fq.f();this.QK.f()};aN.prototype.mQ=function(w,n){this.y6=n.IZ;var W=new iB(0,0,w.m,w.n);if(w.g.length!=0){var D=w.C[w.g[0]];
if(D.add.artb){W=D.yP();W.x+=W.m+100}if(n.IZ==1)W=y.wR.pJ(w)}this.IN=W;this.Fq.$(new ec(W.m,W.n))};function bM(){dB.call(this,"Storage","storwindow");
this.body.setAttribute("style","padding:0");this.Cs=null;this.h("closebtn",this.ka,this);this.h("canclose",this.ka,this)}bM.prototype=new dB;
bM.prototype.GZ=function(w,n){if(this.Cs)this.Cs.GZ(w,n)};bM.prototype.aP=function(w,n){return new ec(Math.max(0,Math.min(150,(w-980)/2)),Math.max(0,Math.min(150,(n-590)/2)))};
bM.prototype.zl=function(w,n){this.gA=w;this.ag=n;w=Math.min(w,980);n=Math.min(n,590);if(this.Cs)this.Cs.zl(w,n)};
bM.prototype.f=function(){dB.prototype.f.call(this);if(this.Cs)this.Cs.f()};bM.prototype.mQ=function(w,n,W,D){this.II=n.IZ==0?"Open from Storage":"Save to Storage";
this.f();if(this.Cs==null){this.Cs=new hf;this.Cs.parent=this;this.body.appendChild(this.Cs.e);this.f();
this.zl(this.gA,this.ag)}Storage.h8(n.IZ,w?w.name:"");hf.GV(this.Cs)};bM.prototype.ka=function(w){Storage.h8(0);
hf.FZ();if(w.type=="canclose")this.close()};function h8(){dB.call(this,[2,14],"varsdats");var w=this.xG=e.t("div","form");
w.setAttribute("style","width:300px");this.body.appendChild(w);this.tI=null;this.uu=0;this.ww=null;this.e8=new j$(null,[[2,14],"Data Sets",[1,8]]);
this.e8.h(b.E.A,this.a6v,this);this.qP=new h8.rj;this.Nj=new h8.PF;this.yj=new h8.Re;this.Nj.h("activate",this.h7,this);
this.yj.h("export",this.GW,this);this.QK=e.bp(this)}h8.prototype=new dB;h8.prototype.a6v=function(w){var n=this.e8.b(),W=this.xG;
e._g(W);W.appendChild(this.e8.e);e.R2(W);W.appendChild([this.qP,this.Nj,this.yj][n].e);W.appendChild(this.QK.e)};
h8.prototype.j8=function(w){var n=new ed(b.E.v,!0);n.G=y.Yu;n.data={d:h.ws,Z:JSON.stringify([this.qP.b(),this.Nj.b()])};
this.S(n);this.close()};h8.prototype.f=function(){dB.prototype.f.call(this);this.QK.f();this.yj.f()};
h8.prototype.mQ=function(w,n){this.tI=w;if(w==null)return;this.qP.mQ(w,n);this.Nj.mQ(w,n);this.e8.$(0);
this.a6v();this.uu=0};h8.prototype.GZ=function(w,n){this.ww=w};h8.prototype.GW=function(w){var n=this.qP.b(),W=this.Nj.b(),D=this.yj.b();
if(n.length==0){alert("There are no variables.");return}if(W.length==0){alert("There are no data sets.");
return}var j=jj.asi(this.tI,n,W,this.Nj.alA(),D[0],D[1],D[2],this.ww,this);if(j!=null)e8.save(j,"images.zip")};
h8.prototype.h7=function(w){var n=this.Nj.g,W=this.qP.b(),D=this.Nj.b();if(W.length==0){alert("There are no variables.");
return}if(D.length==0){alert("There are no data sets.");return}this.D2();this.uu+=jj.ll(this.tI,this,W,D,this.Nj.alA(),n)};
h8.prototype.D2=function(){var w=new ed(b.E.v,!0);w.G=y.eb;w.data={d:"h_stepbck"};while(this.uu>0){this.S(w);
this.uu--}};h8.Re=function(){eg.call(this);var w=this.e=e.t("div");this.R1=new e7("Variable for file names");
w.appendChild(this.R1.e);e.R2(w);this.m3=["JPG","PNG","PDF"];this.lP=new j$([12,50],this.m3);this.lP.h(b.E.A,this.a3d,this);
w.appendChild(this.lP.e);this.ii=new kv;w.appendChild(this.ii.e);this.a3d();this.tR=new iP("Export all items",!0,null,!0);
this.tR.h("click",this.GW,this);w.appendChild(this.tR.e)};h8.Re.prototype=new eg;h8.Re.prototype.f=function(w){this.R1.f();
this.lP.f();this.tR.f();this.ii.f()};h8.Re.prototype.a3d=function(w){var n=this.m3[this.lP.b()];this.ii.Pe(n)};
h8.Re.prototype.GW=function(w){this.S(new ed("export"))};h8.Re.prototype.b=function(){var w=this.m3[this.lP.b()];
return[w,this.ii.b(),this.R1.b().trim()]};h8.PF=function(){eg.call(this);this.fn=null;this.zo=[];this.g=0;
var w=this.e=e.t("div","form");this.O4=new aH("Import a CSV file");w.appendChild(this.O4.e);this.O4.h(b.E.A,this.adc,this);
this.uc=e.t("div","scrollable");this.uc.setAttribute("style","overflow:scroll; height:234px;");w.appendChild(this.uc);
this.atM=new aH("Source Images",!0);w.appendChild(this.atM.e)};h8.PF.prototype=new eg;h8.PF.prototype.adc=function(w){var n=this.O4.b();
for(var W in n){n=n[W];break}this.fn=aa.ew(J.KY(n));this.Uc()};h8.PF.prototype.alA=function(){return this.atM.b()};
h8.PF.prototype.mQ=function(w,n){var W=this.fn=JSON.parse(JSON.stringify(w.Ei));this.Uc()};h8.PF.prototype.b=function(){return this.fn};
h8.PF.prototype.Uc=function(){var w=this.X5.bind(this),n=this.fn,D="max-width: 100px; overflow:hidden; white-space: nowrap; border: 1px solid; padding:0px 5px;";
this.zo=[];var W=e.t("table");W.setAttribute("style","border-collapse: collapse;");for(var L=0;L<n.length;
L++){var j=e.t("tr"),I=n[L],U=L==0?"th":"td";W.appendChild(j);var M=e.t(U);j.appendChild(M);M.setAttribute("style",D+"cursor:pointer;");
if(L!=0)M.textContent="\u2713";this.zo.push(M);M.addEventListener("click",w,!1);for(var m=0;m<I.length;
m++){var M=e.t(U);M.textContent=I[m];j.appendChild(M);M.setAttribute("style",D);M.setAttribute("title",I[m])}}e._g(this.uc);
this.uc.appendChild(W)};h8.PF.prototype.X5=function(w){this.g=this.zo.indexOf(w.currentTarget);this.S(new ed("activate"))};
h8.rj=function(){eg.call(this);var w=this.e=e.t("div","form marged");this.lp=null;this.b1=[];this.Pt=[];
this.$O=null;this.Ts=new i0([0,3],[]);this.Ts.h(b.E.A,this.aao,this);w.appendChild(this.Ts.e);this.L7=[];
var n=["Visibility","Text Content","Pixel Content"];for(var L=0;L<n.length;L++){e.R2(w);var W=new b7(n[L]);
W.h(b.E.A,this.bX,this);w.appendChild(W.e);e.x$(w);var D=new e7("Variable Name");D.h(b.E.A,this.bX,this);
w.appendChild(D.e);this.L7.push(W,D)}};h8.rj.prototype=new eg;h8.rj.prototype.bX=function(w){var n=this.Ts.b(),W=this.$O[n],D=this.b1[n],j=this.lp["l"+W],I=this.L7;
if(j==null)this.lp["l"+W]=j=[];while(j.length!=0)j.pop();for(var L=0;L<3;L++){var U=I[2*L+1].b();if(!I[2*L].b())continue;
var M={varName:U,trait:["visibility","textcontent","fileref"][L]};j.push(M);if(L==2){M.align="center";
M.clip="false";M.placementMethod="fit";M.valign="middle"}}if(j.length==0)delete this.lp["l"+W];this.mQ()};
h8.rj.prototype.aao=function(w){var n=this.Ts.b(),W=this.$O[n],D=this.b1[n],j=this.lp["l"+W],I=this.L7;
if(j==null)j=[];for(var L=0;L<3;L++){var U=L==0||L==1&&D==0||L==2&&D==1;I[2*L].G3(U);I[2*L].$(!1);I[2*L+1].G3(U);
I[2*L+1].$("")}for(var L=0;L<j.length;L++){var M=j[L],m=M.trait,l=["visibility","textcontent","fileref"].indexOf(m);
I[l*2].$(!0);I[l*2+1].$(M.varName)}};h8.rj.prototype.mQ=function(w,n){if(w){var W=JSON.parse(JSON.stringify(w.ol)),D=this.lp={};
for(var L=0;L<W.length;L++){var j=W[L],I=j.docRef;I="l"+I.slice(4,I.length-2);if(D[I]==null)D[I]=[];
D[I].push(j)}this.$O=[];this.b1=[];this.Pt=[];for(var L=w.C.length-1;L>=0;L--){var U=w.C[L],I=U.add.lyid;
if(U.getName()=="</Layer group>")continue;this.$O.push(I);this.b1.push(U.add.TySh?0:1);this.Pt.push(U.getName())}}var M=[],m=this.Pt;
for(var L=0;L<m.length;L++){M.push(m[L]+(this.lp["l"+this.$O[L]]?" *":""))}var l=this.Ts.b();this.Ts.TF(M);
this.Ts.$(l);this.aao()};h8.rj.prototype.b=function(){var w=this.lp,n=[];for(var W in w){var D=w[W];
for(var j=0;j<D.length;j++){D[j].docRef="id('"+W.slice(1)+"')";n.push(D[j])}}return n};function eC(){dB.call(this,["VAR0 VAR1",[15,10,22],[8,11,0]],"divslice");
this.xj=!1;var w=this.Cx=[],n=e.t("div","form");n.setAttribute("style","width:20em");this.body.appendChild(n);
for(var L=0;L<2;L++){var W=new b7([22,4,2+L]);n.appendChild(W.e);e.x$(n);var D=new j$(null,[["N equal parts"],["N pixels per part"]]);
n.appendChild(D.e);e.x$(n);var j=new g_("N",0,1e3);j.$(4);j.parent=this;n.appendChild(j.e);e.x$(n);if(L==0)e.R2(n);
w.push(W,D,j)}for(var L=0;L<w.length;L++)w[L].h(b.E.A,this.WJ,this);w.push(e.bp(this,n));this.h("closebtn",this.D2,this)}eC.prototype=new dB;
eC.prototype.D2=function(){if(this.xj){var w=new ed(b.E.v,!0);w.G=y.eb;w.data={d:"h_stepbck"};this.S(w)}};
eC.prototype.WJ=function(w){this.D2();this.xj=!0;var n=[];for(var L=0;L<6;L++)n.push(this.Cx[L].b());
var W={__name:"Divide",classID:"divide",null:{t:"obj ",v:[{t:"Enmr",v:{classID:"slice",typeID:"Ordn",enum:"Trgt"}}]}};
for(var D=0;D<2;D++){if(!n[D*3])continue;var j=n[D*3+1],I=n[D*3+2];W[["slices","pixels"][j]+["Across","Down"][D]]={t:"long",v:I}}var U=new ed(b.E.W1,!0);
U.data={hZ:"divide",E3:W};this.S(U)};eC.prototype.j8=function(w){this.close()};eC.prototype.f=function(){dB.prototype.f.call(this);
var w=this.Cx;for(var L=0;L<w.length;L++)w[L].f()};eC.prototype.mQ=function(w,n){this.xj=!1};function et(w,n,W,D){eg.call(this);
this.name=w;this.aqH=W;this.JY=D;this.Uh=e.t("div","");this.Uh.setAttribute("draggable","true");this.h_=e.t("div","pbody");
this.Zo=new iP("",!1,"");this.Zo.parent=this;this.ajQ=e.t("span","cross gsicon");this.Vd=e.t("span","label");
var j=this.ahW.bind(this);this.Uh.addEventListener("mousedown",this.a5h.bind(this),!1);this.Uh.addEventListener("contextmenu",j,!1);
this.Zo.e.addEventListener("contextmenu",j,!1);this.ajQ.addEventListener("mousedown",this.gI.bind(this),!1);
this.Uh.appendChild(this.Vd);if(n)this.Uh.appendChild(this.ajQ);this.JV=!1;this.Vd.textContent=w}et.prototype=new eg;
et.prototype.GS=function(){return null};et.prototype.f=function(){var w=fV.get(this.name),n=!1,W=this.gA==0?22:Math.round(2+this.gA/50);
if(w.endsWith(" *")){n=!0;w=w.slice(0,w.length-2);W-=2}var D=w.length>W;this.Vd.textContent=D?w.slice(0,W-2):w;
if(D)for(var j=0;j<2;j++){var I=e.t("span");I.textContent=w.charAt(W-2+j);I.setAttribute("style","opacity:"+(.6-j*.4));
this.Vd.appendChild(I)}if(n){var I=e.t("span");I.textContent=" *";this.Vd.appendChild(I)}var U=w.split(" "),M=U.length==2?U[0].substring(0,2)+U[1][0]:w.substring(0,3);
if(M.charCodeAt(0)>=11776)M=M.substring(0,1);var m=this.aqH;if(m==null)this.Zo.wV(M,w);else{var l;if(m.startsWith("---"))l="<img src=\""+PIMG[m.slice(3)]+"\" class=\"autoscale gsicon\" style=\"margin:2px 4px;\"/>";
else if(m.startsWith("==="))l="<img src=\""+m.slice(3)+"\" class=\"autoscale gsicon\" style=\"margin:2px 4px;\"/>";
else if(m.indexOf("\"")==-1)l="<img src=\""+m+"\" alt=\""+e.VT(w).replace(/"/g,"&quot;")+"\" height=\"18\" width=\"18\" loading=\"lazy\" style=\"margin:1px 3px;\" />";
this.Zo.wV(l,w)}};et.prototype.enable=function(){this.h_.className="pbody"};et.prototype.disable=function(){this.h_.className="pbody disabled"};
et.prototype.GZ=function(w,n){};et.prototype.mQ=function(w,n,W){};et.prototype.E$=function(w){};et.prototype.zl=function(w,n){};
et.prototype.UG=function(w){this.name=w;this.f()};et.prototype.c2=function(){};et.prototype.a5h=function(w){if(w.button==0)this.S(new ed("select",!1))};
et.prototype.ahW=function(w){e.oz(w);if(this.JY!=null&&isNaN(this.JY))return;var n=e.rv(w,document.body),W=this.ra;
if(W==null){W=this.ra=new cA([{name:[1,12,0]}]);this.ra.h("select",this.gI,this)}W.update(null);W.f();
W.parent=this;var D=new ed(b.E.L,!0);D.data={d:b.c.Uq,BT:W,x:n.x+1,y:n.y+1};this.S(D)};et.prototype.K3=function(){this.gI({})};
et.prototype.gI=function(w){if(w.stopPropagation)w.stopPropagation();if(this.JY!=null&&!isNaN(this.JY)){var n=new ed(b.E.L,!0);
n.data={d:b.c.Eb,BT:this.ra};this.S(n);n.data={d:b.c.oj,AH:bk.dp,Z:parseFloat(this.JY),BX:"del"};this.S(n)}else if(this.ajP())this.S(new ed(b.E.gh,!1))};
et.prototype.ajP=function(w){return!0};et.prototype.WQ=function(w,n,W,D,j){};et.prototype.QD=function(w,n,W,D,j){};
et.prototype.H5=function(w,n,W,D,j){};et.IM=function(w,n,W){if(w.childElementCount!=0)return;var D=w.textContent;
this.fW=this.anT.bind(this);this.a3c=this.a7E.bind(this);this.sW=n;this.a6p=W;this._r=w;this.ahK=D;var j=e.t("input","");
j.setAttribute("type","text");j.setAttribute("size","10");j.setAttribute("value",D);e._g(w);w.appendChild(j);
j.select();j.focus();e.xr(w);w.addEventListener("keyup",this.fW,!1);document.body.addEventListener("mousedown",this.a3c,!1)};
et.IM.prototype.anT=function(w){var n=aK.$L,W=n(w.code,aK.yG);if(n(w.code,aK.QX)||W)this.azh(W)};et.IM.prototype.a7E=function(w){var n=w.target;
if(n.tagName&&n.tagName.toLowerCase()=="input")return;this.azh(!0)};et.IM.prototype.azh=function(w){var n=this._r,W=n.firstChild.value;
n.removeEventListener("keyup",this.fW);document.body.removeEventListener("mousedown",this.a3c);if(this.a6p||w&&W!=""&&W!=this.ahK){this.sW(W)}else{e._g(n);
n.textContent=this.ahK}};et.ip={eb:"0",apX:"1",Yu:"2",a8J:"3",akk:"4",$z:"5",CSS:"6",zq:"7",aax:"8",a60:"9",a7V:"10",a4Y:"11",abw:"12",X$:"13",Q6:"14",axH:"15",ajT:"16",aK:"17",ady:"18",a3f:"19",ayu:"20",gB:"21",anu:"22",a2X:"23"};
function is(){et.call(this,[9,9],!1,"---panels/actions",et.ip.a4Y);this.ww=null;this.hg=[0,0]}is.prototype=new et("");
is.prototype.Wg=function(){if(!e.LY(this.h_)||this.sU)return;this.sU=e.t("div","padded scrollable");
this.sU.setAttribute("style","width:260px; height:260px");this.h_.appendChild(this.sU);this.h(b.E.A,this.Ch,this);
this.jU=e.t("div","lpfoot");this.h_.appendChild(this.jU);this.uH=[];var w="<svg class=\"miniscale gsicon\" viewBox=\"0 0 15 15\" width=\"15\" height=\"15\" fill=\"black\">",n="</svg>",W=w+"<path d=\"M14,6 L10,6 L10,0 L4,0 L4,6 L0,6 L7,13 L14,6 L14,6 Z M0,14 L0,16 L14,16 L14,14 Z\" />"+n,D=w+"<path d=\"M0,0 L15,7.5 L0,15 Z\" />"+n;
this.a9M=w+"<circle cx=\"7.5\" cy=\"7.5\" r=\"7.5\" />"+n;this.ay0=w+"<path d=\"M1,1 L14,1 L14,14 L1,14 Z\" />"+n;
var j=[this.a9M,D,"lrs/folder","lrs/newlayer","lrs/bin",W],I=[[15,8,0],[5,8],[15,8,1],[15,8,2],[5,4],[1,2]];
for(var L=0;L<j.length;L++){var U=j[L];if(1<L&&L!=j.length-1)U="<img src=\""+PIMG[j[L]]+"\" class=\"miniscale gsicon\" />";
var M=new iP(U,!1,I[L]);M.h("click",this.apJ,this);this.jU.appendChild(M.e);this.uH.push(M)}this.Uc()};
is.prototype.f=function(){et.prototype.f.call(this);if(this.sU==null)return;for(var L=0;L<this.uH.length;
L++)this.uH[L].f()};is.prototype.apJ=function(w){var L=this.uH.indexOf(w.currentTarget),n=this.hg,W=this.ww,D=W.$q;
if(L==0){var j,I=W.LA;if(D.length==0){alert("Create an Action Set first.");return}if(n.length<2){alert("Select a target action first.");
return}if(I==null){j=this.ay0;I=this.hg}else{j=this.a9M;I=null}this.uH[0].wV(j);W.LA=I}else if(L==1)this.aAw();
else if(L==2||L==3){var U={s7:"Action Set "+D.length,xq:[],exp:!0};if(L==2||D.length==0){n=[D.length];
D.push(U)}if(L==3){var M=D[n[0]].xq;n=[n[0],M.length];M.push({s7:"Action "+M.length,color:0,xq:[],acT:!1,shift:!1,exp:!0,p_:M.length})}this.hg=n;
this.Uc()}else if(L==4){var m;if(n.length==1)m=D;else if(n.length==2)m=D[n[0]].xq;else m=D[n[0]].xq[n[1]].xq;
var l=n.length-1;m.splice(n[l],1);if(m.length==0)n.pop();else while(n[l]>=m.length)n[l]--;if(n.length==0)n.push(0);
this.Uc()}else if(L==5){if(D.length==0){alert("No Actions Present.");return}var A=new ed(b.E.L,!0);A.data={d:b.c.RN,a97:bk.v,RL:n[0]};
this.S(A)}};is.prototype.Ch=function(w){var n=this.ww.$q,W=w.data.d,D=w.data.aZ;if(W=="sel")this.hg=D;
if(W=="fold"){if(D.length==1)n[D[0]].exp=!n[D[0]].exp;else n[D[0]].xq[D[1]].exp=!n[D[0]].xq[D[1]].exp}if(W=="enab"){var j=n[D[0]].xq[D[1]].xq[D[2]];
j.r=!j.r}if(W=="nchange"){if(D.length==1)n[D[0]].s7=w.data.np;else n[D[0]].xq[D[1]].s7=w.data.np}this.Uc()};
is.prototype.mQ=is.prototype.c2=function(){this.Wg()};is.prototype.GZ=function(w,n){this.ww=w;if(this.sU==null)return;
if(n==bk.v||n==bk.bI)this.Uc()};is.prototype.Uc=function(){if(this.ww==null)return;e._g(this.sU);var w=this.ww.$q;
if(w.length==0)return;var n=JSON.stringify(this.hg);for(var L=0;L<w.length;L++){var W=w[L],D=new is.Vb([L],n,W.exp,W.s7.split("=").pop());
D.parent=this;this.sU.appendChild(D.e);if(!W.exp)continue;for(var j=0;j<W.xq.length;j++){var I=W.xq[j],D=new is.Vb([L,j],n,I.exp,I.s7.split("=").pop());
D.parent=this;this.sU.appendChild(D.e);if(!I.exp)continue;for(var U=0;U<I.xq.length;U++){var M=I.xq[U],D=new is.Vb([L,j,U],n,null,fV.get(cq.agF(M)),M.r);
D.parent=this;this.sU.appendChild(D.e)}}}};is.prototype.aAw=function(){var w=this.ww.$q,n=this.hg;if(w.length==0){alert("No Actions Present");
return}if(n.length==1){alert("Select an Action first");return}if(this.ww.LA!=null){alert("You can not apply actions while recording actions");
return}if(n.length==1)n.push(0);var W=w[n[0]],D=W.xq[n[1]],j=new ed(b.E.L,!0);j.data={d:b.c.if,HD:[D.s7,W.s7]};
this.S(j)};is.Vb=function(w,n,W,D,j){eg.call(this);this.aZ=w;var I=this.aZ.length-1;this.e=e.t("div","layeritem"+(JSON.stringify(w)==n?" selected":""));
this.Oc=e.t("div","head");this.e.appendChild(this.Oc);this.Oc.setAttribute("style","height:24px");this.e_=e.t("div","headL");
this.Oc.appendChild(this.e_);if(I!=0){var U=e.t("div");U.style.width=I*20+"px";this.e_.appendChild(U)}if(W!=null){var M=this.aei=e.t("div",W?"open":"closed");
this.e_.appendChild(M)}else{var m=this.a2M=e.t("div","cmark");m.setAttribute("style","background-size:12px 12px; opacity:"+(j?1:.3));
this.e_.appendChild(m)}if(I==0){var l=e.t("div","folder");this.e_.appendChild(l)}var A=this.Vd=e.t("div","label");
A.textContent=D;this.e_.appendChild(A);this.e.addEventListener("mouseup",this.h7.bind(this),!1)};is.Vb.prototype=new eg;
is.Vb.prototype.h7=function(w){if(w.detail==1&&w.target.tagName.toLowerCase()!="input"){var n="sel";
if(w.target==this.aei)n="fold";if(w.target==this.a2M)n="enab";var W=new ed(b.E.A,!0);W.data={d:n,aZ:this.aZ};
this.S(W)}else if(this.aZ.length<3)var D=new et.IM(this.Vd,this.sW.bind(this))};is.Vb.prototype.sW=function(w){var n=new ed(b.E.A,!0);
n.data={d:"nchange",np:w,aZ:this.aZ};this.S(n)};function h1(){et.call(this,[3],!1,"---lrs/adj",et.ip.ady)}h1.prototype=new et("");
h1.prototype.Wg=function(){if(!e.LY(this.h_)||this.uH)return;this.h_.setAttribute("style","text-align:center; padding:6px; min-width:220px");
this.uH=[];var L=0;for(var w in eH.names){var n=new iP("<img src=\""+PIMG["adj/"+w]+"\" class=\"autoscale gsicon\" style=\"margin:4px 4px;\"/>",!1,eH.names[w]);
n.h("click",this.adK,this);this.uH.push(n);this.h_.appendChild(n.e);if(L==4||L==10)e.x$(this.h_);L++}this.f()};
h1.prototype.mQ=function(){this.Wg()};h1.prototype.c2=function(){this.Wg()};h1.prototype.f=function(){et.prototype.f.call(this);
if(this.uH==null)return;for(var L=0;L<this.uH.length;L++)this.uH[L].f()};h1.prototype.adK=function(w){var n=this.uH.indexOf(w.target),W=db.XG()[n],D=new ed(W.Y,!0);
D.data=W.W;this.S(D)};function f7(){et.call(this,[12,22],!1,null,et.ip.gB);this.sU=e.t("div","padded");
this.ww=null;this.h_.appendChild(this.sU);this.ud=new jR(null,17.7,10);this.ud.parent=this;this.ud.h(b.E.A,this.WJ,this);
this.sU.appendChild(this.ud.sz)}f7.prototype=new et("");f7.prototype.WJ=function(w){var n=this.ud.b(),W=new ed(b.E.v,!0);
W.data={d:"setstl",Z:n.nK};W.G=y.EA;this.S(W);W.data={d:"confirm"};this.S(W)};f7.prototype.GZ=function(w,n){this.ww=w;
this.Uc()};f7.prototype.Uc=function(){var w=this.ww;if(w==null)return;this.ud.FC([w.IH,w.V8])};f7.prototype.mQ=function(){this.Uc()};
f7.prototype.c2=function(){this.Uc()};var eO=function(){function w(){et.call(this,[9,3],!1,"---panels/brush",et.ip.zq);
this.UT=null;this.ww=null}w.prototype=new et("");w.prototype.Wg=function(){var j=e.t("div","");this.h_.appendChild(j);
this.GN=e.t("div","bordered cell");this.GN.setAttribute("style","width:10em; height:28.5em;");j.appendChild(this.GN);
this.Qf=[];this.ld=null;this.VS=[];var I=this.aru.bind(this);this.Vy=[new W("basic"),new W("useTipDynamics"),new W("useScatter"),new W("useColorDynamics"),new W("usePaintDynamics")];
for(var L=0;L<this.Vy.length;L++){var U=e.t("div","listitem"),M=this.Vy[L],l=null;M.parent=this;M.h("brushchange",this.abK,this);
var m=M.HS;if(L==0){this.ld=new ga(m);U.appendChild(this.ld.e)}else{l=new b7(m,!1);l.h(b.E.A,this.aiX,this);
U.appendChild(l.e)}this.VS.push(l);this.GN.appendChild(U);this.Qf.push(U);U.addEventListener("click",I,!1)}this.t8=e.t("div","cell padded");
j.appendChild(this.t8);this.setItem(0);this.T=e.t("canvas");this.T.height=10;j.appendChild(this.T);this.VE=this.T.getContext("2d");
this.T5()};w.prototype.zl=function(j,I){if(this.gA==j)return;this.gA=j;this.ag=I;this.T5()};w.prototype.c2=function(){if(!e.LY(this.h_))return;
if(this.GN){this.T5();return}this.Wg();this.f();this.GZ(this.ww,bk.bI)};w.prototype.f=function(){et.prototype.f.call(this);
if(this.GN==null)return;this.ld.f();for(var L=1;L<this.VS.length;L++)this.VS[L].f();for(var L=0;L<this.Vy.length;
L++)this.Vy[L].f()};w.prototype.abK=function(j){var I=this.Vy.indexOf(j.currentTarget),U=JSON.parse(JSON.stringify(this.Vy[I].UT)),M=new ed(b.E.L,!0);
M.data={d:b.c.oj,AH:bk.ef,UT:U};this.S(M)};w.prototype.aiX=function(j){this.at_(this.VS.indexOf(j.currentTarget),j.currentTarget.zr())};
w.prototype.aru=function(j){var L=this.Qf.indexOf(j.currentTarget);if(j.target.tagName.toLowerCase()=="input")return;
if(this.VS[L]&&!this.VS[L].zr()){this.VS[L].d3();this.at_(L,!0)}this.setItem(L)};w.prototype.at_=function(j,I){this.Vy[j].ak0(I)};
w.prototype.setItem=function(j){for(var L=0;L<this.Vy.length;L++)this.Qf[L].className="listitem";if(this.t8.firstChild)this.t8.removeChild(this.t8.firstChild);
this.Qf[j].className="listitem selected";this.t8.appendChild(this.Vy[j].e)};w.prototype.GZ=function(j,I){this.ww=j;
if(this.GN==null)return;for(var L=0;L<this.Vy.length;L++)this.Vy[L].GZ(j,I);if(I==bk.ef||I==bk.bI){this.UT=j.t$.lH;
this.T5()}if(I==bk.X$)this.T5()};w.prototype.T5=function(){if(this.UT)this.enable();else{this.disable();
return}if(!e.LY(this.h_))return;var j=this.ww;for(var L=0;L<this.Vy.length;L++){this.Vy[L].$(this.UT);
if(this.VS[L])this.VS[L].$(this.Vy[L].zr())}var I=JSON.parse(JSON.stringify(this.UT));I.Brsh.v.Dmtr.v.val=Math.min(I.Brsh.v.Dmtr.v.val,50);
e.dz(this.T,this.gA,80);var U=new iB(0,0,this.T.width,this.T.height),M=this.ww.t$,m=new iV(I,M?M.yg:null,M?M.j6:null,{Z8:1},j.Gp,j.as,U,null,0),l=U.n/2,A=U.m-l*2;
m.moveTo(l,l);for(var L=0;L<=A;L+=10)m.lineTo(l+L,l+20*Math.sin(2*Math.PI*L/A));m.finish();var g=this.VE.createImageData(U.m,U.n);
E.Cb(m._a(),m.pJ(),g.data,U);this.VE.putImageData(g,0,0)};function n(j){eg.call(this);j=j.split(".")[0];
this.HU=j;var I=this.e=e.t("span"),U=["Off","Fade"];U.push(j=="angleDynamics"?"Direction":"Pen Pressure");
var M=this.ps=new i0("Control",U);M.h(b.E.A,this.bX,this);I.appendChild(M.e);var m=this.aon=new g_(null,0,100,null,null,null,!0);
m.$(50);m.h(b.E.A,this.bX,this)}n.prototype=new eg;n.prototype.$=function(j){j=j<2?j:2;this.ps.$(j);
this.Uc()};n.prototype.b=function(){var j=this.ps.b(),I=this.HU;j=j<=1?j:I=="angleDynamics"?6:2;return j};
n.prototype.bX=function(j){this.Uc();j.target=j.currentTarget=this;this.S(j)};n.prototype.Uc=function(j){this.aon.G3(this.ps.b()==1)};
function W(j){eg.call(this);this.e=e.t("div");this.UT=null;var I=["basic","useTipDynamics","useScatter","useColorDynamics","usePaintDynamics"].indexOf(j);
this.HS=[[15,0],[15,1],[15,2],[15,3],"Transfer"][I];this.y6=j;this.CL={};this.awq=null;var U=["--br Brsh.Dmtr Brsh.Angl Brsh.Rndn Brsh.Hrdn Brsh.Spcn".split(" "),"szVr.jitter szVr.bVTy szVr.fStp minimumDiameter angleDynamics.jitter angleDynamics.bVTy angleDynamics.fStp roundnessDynamics.jitter minimumRoundness".split(" "),["scatterDynamics.jitter","Cnt","countDynamics.jitter"],["clVr.jitter","H","Strt","Brgh"],"opVr.jitter opVr.bVTy opVr.fStp prVr.jitter prVr.bVTy prVr.fStp".split(" ")][I];
for(var L=0;L<U.length;L++){var M=U[L],m;if(M=="--br"){m=new ch;this.e.appendChild(m.sz.firstChild)}else if(M=="Brsh.Dmtr")m=new eu([12,14,0],1,1e3," px",0,!0);
else if(M=="Brsh.Angl")m=new eu([12,15],0,359," \xB0");else if(M=="Brsh.Rndn")m=new eu([12,16],0,100," %");
else if(M=="Brsh.Hrdn")m=new eu([12,17],0,100," %");else if(M=="Brsh.Spcn")m=new eu([12,18],1,300," %");
else if(M=="szVr.jitter")m=new eu([15,4,0],0,100,"%");else if(M=="minimumDiameter")m=new eu([15,4,1],0,100,"%");
else if(M=="angleDynamics.jitter")m=new eu([15,4,2],0,100,"%");else if(M.endsWith("bVTy"))m=new n(M);
else if(M.endsWith("fStp"))m=new g_(null,0,100,null,null,null,!0);else if(M=="roundnessDynamics.jitter")m=new eu([15,4,3],0,100,"%");
else if(M=="minimumRoundness")m=new eu([15,4,4],1,100,"%");else if(M=="scatterDynamics.jitter")m=new eu([15,5,0],0,1e3," %");
else if(M=="Cnt")m=new eu([15,5,1],1,20);else if(M=="countDynamics.jitter")m=new eu([15,5,2],0,100," %");
else if(M=="clVr.jitter")m=new eu([15,6,0],0,100," %");else if(M=="H")m=new eu([15,6,1],0,100," %");
else if(M=="Strt")m=new eu([15,6,2],0,100," %");else if(M=="Brgh")m=new eu([15,6,3],0,100," %");else if(M=="opVr.jitter")m=new eu("Opacity Jitter",0,100," %");
else if(M=="prVr.jitter")m=new eu("Flow Jitter",0,100," %");else throw M;this.CL[M]=m;m.parent=this;
m.h(b.E.A,this.bX,this)}}W.prototype=new eg;W.prototype.asl=function(){this.S(new ed("brushchange"))};
W.prototype.$=function(j){this.UT=JSON.parse(JSON.stringify(j));this.e.className=this.zr()?"":"disabled";
this.T5()};W.prototype.f=function(){for(var j in this.CL)this.CL[j].f()};W.prototype.zr=function(){return!0};
W.prototype.GZ=function(j,I){if(I==bk.zq||I==bk.bI){var U=this.CL["--br"];if(U)U.FC(j.t$)}};W.prototype.bX=function(j){var I=j.target,M=this.CL,m;
for(var l in M)if(M[l]==I)m=l;if(m=="--br"){var A=new ed(b.E.L,!0);A.data={d:b.c.oj,AH:bk.ef,UT:I.b()};
this.S(A)}else{var g=D(this.UT,m),k=I.b();if(g){if(m.endsWith("bVTy")||m.endsWith("fStp")||m=="Cnt")g.v=k;
else g.v.val=k;this.asl()}}};W.prototype.T5=function(){var j=this.UT,I=j.Brsh.v.classID,U=this.CL,M=I!=this.awq;
this.awq=I;if(M){e._g(this.e);for(var m in U){if(I!="computedBrush"&&I!="sampledBrush"&&m=="Brsh.Rndn")continue;
if(I!="computedBrush"&&m=="Brsh.Hrdn")continue;var l=U[m],A=l.e;if(m=="--br"){A=l._e.e;A.style.width="auto"}this.e.appendChild(A)}}for(var m in U){if(m=="--br")continue;
var g=D(j,m),k;if(g){if(m.endsWith("bVTy")||m.endsWith("fStp")||m=="Cnt")k=g.v;else k=g.v.val;U[m].$(k);
if(m.endsWith("fStp"))U[m].G3(D(j,m.split(".")[0]+".bVTy").v==1)}}};W.prototype.zr=function(){var j=this.y6;
return j=="basic"?!0:this.UT[j].v};W.prototype.ak0=function(j){var I=this.y6;if(I=="basic")return;this.UT[I].v=j;
bj.Hx.amr(this.UT);this.asl()};function D(j,I){var U=I.split(".");j=j[U[0]];for(var L=1;L<U.length;L++){if(j==null)return j;
j=j.v[U[L]]}return j}return w}();function he(){et.call(this,[9,0],!1,"---panels/history",et.ip.eb);this.h_.setAttribute("style","min-width:200px;");
this.yd=e.t("div","hpbody scrollable");this.yd.style.height="160px";this.h_.appendChild(this.yd);this.ayy=-1;
this.Bd=[];this.lr="";this.cb=new cA([{name:"Clear History"}],[{Y:b.E.v,G:y.eb,W:{d:"h_clear"}}])}he.prototype=new et("");
he.prototype.GS=function(){return this.cb};he.prototype.zl=function(w,n){this.c2()};he.prototype.mQ=function(w){if(w==null){e._g(this.yd);
this.lr="";return}e._g(this.yd);var n=0;for(var L=0;L<w.history.length;L++)if(L<=w.QQ&&!w.history[L]._$)n=L;
for(var L=0;L<w.history.length;L++){var W=w.history[L];if(W._$)continue;var D=new i4(W,L,n);D.parent=this;
this.yd.appendChild(D.e);this.Bd.push(D)}if(w.QQ==w.history.length-1)this.c2()};he.prototype.c2=function(){this.yd.scrollTop=this.yd.scrollHeight};
he.prototype.f=function(){et.prototype.f.call(this);for(var L=0;L<this.Bd.length;L++)this.Bd[L].f()};
function i4(w,L,n){eg.call(this);this.index=L;this.e=e.t("div",L==n?"listitem selected":"listitem");
this.lU=w.name;this.f();if(L>n)this.e.style.opacity=.4;this.e.addEventListener("click",this.WQ.bind(this),!1)}i4.prototype=new eg;
i4.prototype.f=function(){this.e.textContent=fV.get(this.lU)};i4.prototype.WQ=function(w){if(this.index==this.parent.ayy)return;
this.f8({d:"h_itemchange",index:this.index})};i4.prototype.f8=function(w){var n=new ed(b.E.v,!0);n.data=w;
n.G=y.eb;this.S(n)};function gf(){et.call(this,[9,10],!1,"---panels/histogram",et.ip.akk);var w=e.t("div","padded");
this.h_.appendChild(w);this.mA=new dJ(256,!0);w.appendChild(this.mA.e);this.tI=null}gf.prototype=new et("");
gf.prototype.mQ=function(w){this.tI=w;this.Uc()};gf.prototype.Uc=function(){var w=this.tI;if(!e.LY(this.h_))return;
if(w==null||w.g.length==0){this.mA.$(E.Bk(E.Q(4)));return}var n=w.Vc(),W=new iB(0,0,w.m,w.n),D=W.O();
if(w.J){var j=w.J.rect,I=E.Q(j.O()*4);E.Cb(n,W,I,j);E.py(w.J.channel,I);n=I;W=j;var U=w.J.channel;D=0;
for(var L=0;L<U.length;L++)D+=U[L];D=Math.round(D/255)}var M=E.Bk(n);M[0][255]+=3*(D-M[5]);for(var L=1;
L<4;L++)M[L][255]+=D-M[5];this.mA.$(M,D)};gf.prototype.GZ=function(w,n){this.mA.hR(hp.fX[w.SI]["--text-color"])};
gf.prototype.f=function(){et.prototype.f.call(this);this.mA.f()};gf.prototype.c2=function(){this.Uc()};
function ku(){et.call(this,[9,8],!1,"---adj/clrL",et.ip.apX);this.sU=e.t("div","padded");this.h_.appendChild(this.sU);
this.jf=new ai(10);this.sU.appendChild(this.jf.e);this.tf=new c5;this.tf.parent=this;this.sU.appendChild(this.tf.sz);
this.tf.sz.style.marginTop="6px";this.jf.h(b.E.A,this.ad9,this);this.tf.h(b.E.A,this.ad9,this)}ku.prototype=new et("");
ku.prototype.ad9=function(w){var n;if(w.target==this.jf)n=this.jf.b();else{var W=this.tf.b();n=Math.round(W.o)<<16|Math.round(W.B)<<8|Math.round(W.k)}var D=new ed(b.E.L,!0);
D.data={d:b.c.oj,AH:bk.X$,vK:0,Z:n};this.S(D)};ku.qr=function(w,n){var W=n==bk.bI,D=w.rg,j=w.jH,I=j.strokeStyleContent.v,U=null;
if((n==bk.ut||W)&&D.oq==1){U=E.M.y_(D.S8.Clr.v);U=U.o<<16|U.B<<8|U.k}if((n==bk.Nd||W)&&j.strokeEnabled.v&&I.classID=="solidColorLayer"){U=E.M.y_(I.Clr.v);
U=U.o<<16|U.B<<8|U.k}if(n==bk.X$||W)U=w.Gp;return U};ku.prototype.GZ=function(w,n){var W=w.Gp,D=n==bk.bI,j=ku.qr(w,n);
if(j!=null){this.jf.$(j);this.tf.$({o:j>>>16&255,B:j>>>8&255,k:j>>>0&255,A7:"Color #"+E.$$(j)})}if(n==bk.qs||D){var I=w.auR;
this.tf.FC(I)}};function bg(){et.call(this,[12,72],!1,"---adj/mixr",et.ip.ajT);this.fx=null;this.HI=null;
this.yd=e.t("div","lpbody scrollable");this.yd.style.marginTop="4px";this.jU=e.t("div","lpfoot");this.h_.appendChild(this.yd);
this.h_.appendChild(this.jU);this.sZ=[];this.h("click",this.IC,this);this.av=[];bg.$l([[17,2],"Save Selection as Channel",[5,3],[5,4]],this.av,this.jU,this.eN.bind(this),this.pr.bind(this));
this.cb=new cA([{name:"Merge Channels",$r:!0}],[{Y:b.E.L,W:{d:b.c.P2,jW:"mergechannels"}}])}bg.prototype=new et("");
bg.prototype.GS=function(){return this.cb};bg.$l=function(w,n,W,D,j){for(var L=0;L<w.length;L++){var I=new iP("W",!1,w[L]);
n.push(I);e.L_(I.e,D);W.appendChild(I.e);var U=I.e;U.addEventListener("drop",j,!1);U.addEventListener("dragover",function(M){M.preventDefault()},!1);
U.addEventListener("dragenter",e.oz,!1)}};bg.Xd=function(w,n){for(var L=0;L<w.length;L++)if(w[L].e==n.currentTarget)return L};
bg.prototype.eN=function(w){var n=bg.Xd(this.av,w);if(n==0)this.S(ev.GI(!0,null,w));else{n--;var W=new ed(b.E.W1,!0),D={classID:"null"};
if(n==0)D.null={t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]};else if(n==1)D.Nw={t:"Objc",v:{classID:"Chnl",ClrI:{t:"enum",v:{MskI:"SlcA"}},Opct:{t:"long",v:50}}};
else D.null=cq.Pz("Chnl",!0);W.data={hZ:["duplicate","make","delete"][n],E3:D};this.S(W)}};bg.prototype.pr=function(w){var n=bg.Xd(this.av,w);
if(n==2){var W=new ed(b.E.W1,!0),D={classID:"null"};D.null=cq.Pz("Chnl",!0);W.data={hZ:"duplicate",E3:D};
this.S(W)}else this.eN(w)};bg.prototype.Gk=function(L){var w=this.sZ,n=w[L];if(n==null){var W=e.t("canvas");
n=W.getContext("2d");w.push(n)}return n};bg.prototype.IC=function(w){var n=this.fx.slice(0),W=w.data.p_,D=n[0]+n[1]+n[2],j=this.HI;
if(-5<W&&W<0){var I=-W-1;if(w.data.LG){if(I==0)n=D==3?[0,0,0]:[1,1,1];else{if(n[I-1]==0)n[I-1]=1;else if(!0)n[I-1]=0}}else{if(I==0)n=[1,1,1];
else{n=[0,0,0];n[I-1]=1}for(var L=0;L<j.yo.length;L++)j.yo[L].$P=!1;j.v9=[]}var U=new ed(b.E.v,!0);U.G=y.pX;
U.data={d:"setcls",zC:n};this.S(U);return}if(-1<W){var M=j.C[W],m=M.eL==1?M._N():M.NP(j).z;if(w.data.LG)m.$P=!m.$P;
else{for(var L=0;L<j.yo.length;L++)j.yo[L].$P=!1;j.v9=[]}}else{var l=-W-5,m=j.yo[l];if(w.data.LG)m.$P=!m.$P;
else{for(var L=0;L<j.yo.length;L++)j.yo[L].$P=!1;m.$P=!0;j.v9=[l];if(D!=0){var U=new ed(b.E.v,!0);U.G=y.pX;
U.data={d:"setcls",zC:[0,0,0]};this.S(U)}}}j.RP=j.tL=!0};bg.prototype.c2=function(){this.w$()};bg.prototype.mQ=function(w){this.HI=w;
this.w$()};bg.prototype.w$=function(){var w=this.HI,n=this.yd,$=4;e._g(n);if(w==null||!e.LY(n))return;
var W=w.m,D=w.n,j=new iB(0,0,W,D),I=this.fx=w.u.zC.slice(0),U=I[0]+I[1]+I[2],M=Math.round(34*e.V()),m=M;
if(W>D)m=Math.round(m*D/W);else M=Math.round(M*W/D);var l=["RGB"].concat(eH.RU);for(var L=0;L<4;L++){var A=this.Gk(L);
E.qg.mi(A,M,m,j,w.Vc(),j,!1,L==0?null:L-1);var g=L==0?U==3:I[L-1]==1,k=new ev(-1-L,!0,!0,A,l[L],g,g);
k.parent=this;n.appendChild(k.e);e.gH(A.canvas)}for(var L=0;L<w.g.length;L++){var C=w.C[w.g[L]],f=C.eL;
if(f!=1&&f!=3)continue;var z=f==1?C._N():C.NP(w).z,A=this.Gk($+L);$++;E.qg.ow(A,M,m,j,z);var k=new ev(w.g[L],!0,!0,A,C.getName()+(f==1?"":" Filter")+" Mask",!0,z.$P);
k.parent=this;n.appendChild(k.e);e.gH(A.canvas)}for(var L=0;L<w.yo.length;L++){var z=w.yo[L],A=this.Gk($+L);
E.qg.ow(A,M,m,j,z);var k=new ev(-5-L,!0,z.name=="Quick Mask",A,z.name,w.v9.indexOf(L)!=-1,z.$P,y.Yu,{d:h.QE,vK:"rnm",p_:L});
k.parent=this;n.appendChild(k.e);e.gH(A.canvas)}};bg.prototype.zl=function(w,n){this.yd.style.height=n-30-4+"px";
this.yd.style.width=w+"px"};bg.prototype.f=function(){et.prototype.f.call(this);this.w$();bg.h5(this.av,["lrs/makesel","lrs/mask","lrs/newlayer","lrs/bin"])};
bg.h5=function(w,n){var n=j$.ES(n,null,"miniscale");for(var L=0;L<w.length;L++)w[L].wV(n[L])};function ev(w,n,W,D,j,I,U,M,m){eg.call(this);
this.e=e.t("div");this.abh=w;this.a0u=n;this.VE=D;this.aus=M;this.a8Z=m;this.Oc=e.t("div",I?"head selected":"head");
this.Oc.setAttribute("style","height: "+40+"px");var l=e.t("div","headL"),A=e.t("div","headR"),g=15;
this.e.appendChild(this.Oc);this.Oc.appendChild(l);this.Oc.appendChild(A);this.NB=e.t("div","eye");if(1<e.V()&&e.V()<1.5)g=g/e.V();
this.NB.setAttribute("style","background-size: "+g+"px "+g+"px;");this.NB.style.opacity=U?1:.2;if(n)l.appendChild(this.NB);
this.pe=e.t("div","thumb");if(D)this.pe.appendChild(D.canvas);l.appendChild(this.pe);this.oh=e.t("div","label");
if(W)this.oh.style.fontStyle="italic";this.oh.textContent=fV.get(j);l.appendChild(this.oh);var k=this.Oc;
k.setAttribute("draggable","true");k.addEventListener("dragstart",function($){$.stopPropagation();$.dataTransfer.setData("Text","hello")},!1);
k.addEventListener("drop",e.oz,!1);e.L_(this.Oc,this.ala.bind(this));if(!W)this.Oc.addEventListener("mouseup",this.ap5.bind(this),!1)}ev.prototype=new eg;
ev.prototype.sW=function(w){var n=new ed(b.E.v,!0);n.G=this.aus;n.data=this.a8Z;n.data.name=w;this.S(n)};
ev.prototype.ala=function(w){var n=w.ctrlKey||w.metaKey,W=this.abh;if(n&&w.target==this.VE.canvas){this.S(ev.GI(this.a0u,W,w))}else{var D=new ed("click",!0);
D.data={p_:W,LG:w.target==this.NB,wt:n};this.S(D)}};ev.prototype.ap5=function(w){if(w.detail==2&&w.target==this.oh){var n=new et.IM(this.oh,this.sW.bind(this))}};
ev.GI=function(w,n,W){var D=0;if(W.shiftKey)D++;if(W.altKey)D+=2;var j=new ed(b.E.v,!0);j.G=y.wA;if(w){if(-5<n&&n<0){j=new ed(b.E.W1,!0);
j.data=y.eZ.anl(D,["RGB","Rd","Grn","Bl"][-1-n])}else j.data={d:"fromchannel",HD:[n,0,D]}}else j.data={d:"frompath",HD:[n,0,D]};
return j};function c9(){et.call(this,[8,9],!1,"---panels/paths",et.ip.aK);this.fx=null;this.HI=null;
this.yd=e.t("div","lpbody scrollable");this.yd.style.marginTop="4px";this.jU=e.t("div","lpfoot");this.h_.appendChild(this.yd);
this.h_.appendChild(this.jU);this.h_.addEventListener("click",this.az9.bind(this),!1);this.sZ=[];this.h("click",this.IC,this);
this.av=[];bg.$l(["Fill Path","Stroke Path with Brush",[17,2],"Selection to Path",[5,3],[5,4]],this.av,this.jU,this.eN.bind(this),this.pr.bind(this))}c9.prototype=new et("");
c9.prototype.eN=function(w,n){var W=bg.Xd(this.av,w),D;if(W<2){D=new ed(b.E.W1,!0);D.data=y.rK.un(W)}else if(W==2)D=ev.GI(!1,null,w);
else if(W==3){D=new ed(b.E.W1,!0);D.data={hZ:"make",E3:{classID:"null",null:{t:"obj ",v:[{t:"Clss",v:{classID:"Path"}}]},From:{t:"obj ",v:[{t:"prop",v:{classID:"csel",keyID:"fsel"}}]},Tlrn:{t:"UntF",v:{type:"#Pxl",val:2}}}}}else if(W>3){var D=new ed(b.E.v,!0);
D.G=y.Au;D.data={d:"pathedit",vK:["new","del"][W-4],a8L:n}}this.S(D)};c9.prototype.pr=function(w){this.eN(w,!0)};
c9.prototype.Gk=function(L){var w=this.sZ,n=w[L];if(n==null){var W=e.t("canvas");n=W.getContext("2d");
w.push(n)}return n};c9.prototype.az9=function(w){if(w.target==this.yd){var n=this.HI;n.rs=[];n.zS=[];
n.tL=!0;n.RP=!0}};c9.prototype.IC=function(w){var n=w.data.p_,W=this.HI,D=w.data.wt,j=n,I=W.zS,U=W.rs;
if(n<0){j=-1-n;I=W.rs;U=W.zS}if(D){var M=I.indexOf(j);if(M==-1)I.push(j);else I.splice(M,1)}else{while(I.length!=0)I.pop();
while(U.length!=0)U.pop();I.push(j)}W.tL=!0;W.RP=!0};c9.prototype.c2=function(){this.w$()};c9.prototype.mQ=function(w){this.HI=w;
this.w$()};c9.prototype.w$=function(){var w=this.HI,n=this.yd;e._g(n);if(w==null||!e.LY(n))return;var W=w.m,D=w.n,j=new iB(0,0,W,D),I=this.fx=w.u.zC.slice(0),U=I[0]+I[1]+I[2],M=Math.round(34*e.V()),m=M;
if(W>D)m=Math.round(m*D/W);else M=Math.round(M*W/D);var l=w.OV(),A=l[0];for(var L=0;L<A.length;L++){var g=A[L],k=this.Gk(L);
E.qg.apI(k,M,m,j,g.add.vmsk);var $=new ev(g.p_,!1,g.p_>=0,k,g.name,l[1].indexOf(L)!=-1,!1,y.Au,{d:"pathedit",vK:"rnm",p_:g.p_});
$.parent=this;n.appendChild($.e);e.gH(k.canvas)}};c9.prototype.zl=function(w,n){this.yd.style.height=n-30-4+"px";
this.yd.style.width=w+"px"};c9.prototype.f=function(){et.prototype.f.call(this);this.w$();bg.h5(this.av,"-\u2B24 -\u25EF lrs/makesel lrs/makepath lrs/newlayer lrs/bin".split(" "))};
function cY(w){et.call(this,[9,w?4:5],!1,"---panels/"+(w?"character":"paragraph"),w?et.ip.a60:et.ip.a7V);
this.h_.setAttribute("style","min-width:240px;");this.ati=w;this.qj=null;this.ww=null}cY.prototype=new et("");
cY.prototype.Wg=function(){this.qj=new af;var w=this.qj,n=this.h_;w.parent=this;if(this.ati){var W=e.t("div","marged");
n.appendChild(W);W.appendChild(w.W3.e);n.appendChild(e.t("hr"));var D=e.t("div","marged");n.appendChild(D);
D.appendChild(w.f4.e);D.appendChild(w.vG.e);var j=e.t("div","marged");n.appendChild(j);j.appendChild(w.H1.e);
j.appendChild(w.ar.e);n.appendChild(e.t("hr"));var I=e.t("div","marged");n.appendChild(I);I.appendChild(w.z0.e);
I.appendChild(w.vg.e);var U=e.t("div","marged");n.appendChild(U);U.appendChild(w.VI.e);U.appendChild(w.a6.e);
U.appendChild(w.aj.e);n.appendChild(e.t("hr"));var M=e.t("div","marged");n.appendChild(M);M.appendChild(w.Rg.e);
M.appendChild(w.oY.e);M.appendChild(w.JA.e);M.appendChild(w.Ma.e);M.appendChild(w.Zs.e);M.appendChild(w.rD.e);
M.appendChild(w.p1.e);M.appendChild(w.ZY.e)}else{var W=e.t("div","marged");n.appendChild(W);W.appendChild(w.cv.e);
W.appendChild(w.Md.e);W.appendChild(w.iC.e);W.appendChild(w.aAb.e);W.appendChild(w.aki.e);W.appendChild(w.ai6.e);
W.appendChild(w.aft.e);n.appendChild(e.t("hr"));var D=e.t("div","marged");n.appendChild(D);D.appendChild(w.t_.e);
D.appendChild(w.ZL.e);D.appendChild(w.ia.e);n.appendChild(e.t("hr"));var j=e.t("div","marged");n.appendChild(j);
j.appendChild(w.SG.e);j.appendChild(w.nB.e);j.appendChild(w.De.e);j.appendChild(w.cq.e)}};cY.prototype.c2=function(){if(!e.LY(this.h_))return;
if(this.qj==null){this.Wg();var w=this.ww;if(w)this.qj.$(w.Hu,w.hY,w.Io);this.qj.f()}};cY.prototype.f=function(){et.prototype.f.call(this);
if(this.qj)this.qj.f()};cY.prototype.GZ=function(w,n){this.ww=w;if(n!=bk.bI&&n!=bk.a8&&n!=bk.v3&&n!=bk.SJ)return;
if(this.qj)this.qj.$(w.Hu,w.hY,w.Io)};function cl(){et.call(this,[9,13],!1,"---panels/glyphs",et.ip.a3f);
this.ww=null}cl.prototype=new et("");cl.prototype.Wg=function(){this.qj=new af;this.qj.parent=this;this.adO=null;
this.awL=null;this.oM=null;this.azd=null;this.DX=Math.round(290*e.V());this.SF=45;this.a0L=4;this.afc=this.Uc.bind(this);
this.a9q=0;this.lv=new i0(null,["Hi","Hello"]);this.lv.h(b.E.A,this.Uc,this);var w=this.rW=new iP("-",null,null,!0);
w.h("click",this.ahN,this);var n=this.a4y=new iP("+",null,null,!0);n.h("click",this.ahN,this);this._e=new dX(!1);
this._e.h(b.E.A,this.ZU,this);this._e.e.style.height=250+"px";var W=this.Y7=e.t("div","form padded");
this.h_.appendChild(W);W.appendChild(this.qj.W3.e);e.x$(W);W.appendChild(this.lv.e);W.appendChild(w.e);
W.appendChild(n.e);this.h_.appendChild(this._e.e)};cl.prototype.zl=function(w,n){if(this.gA==w||this.qj==null)return;
this.gA=w;this.DX=Math.floor((w-13)*e.V());this.Y7.setAttribute("style","width:"+this.DX/e.V()+"px;");
this._e.e.style.height=n-73+"px";this.Uc()};cl.prototype.ZU=function(w){var n=this.awj(),W=Math.round(this.DX/n);
n/=e.V();var D=this._e.b()[0]*W*this.a0L,j=this._e.ahl();D+=Math.floor(j.y/n)*W;D+=Math.floor(j.x/n);
var I=this.oM[this.lv.b()];if(D>=I.length)return;var U=I[D],M=this.azd[U],m=new ed(b.E.v,!0);m.G=y.Lu;
if(M.BO.length==0)m.data={d:"insertGlyph",Z:D+1};else m.data={d:"insertText",Z:String.fromCodePoint(M.BO[0])};
this.S(m)};cl.prototype.ahN=function(w){var n=1.2;if(w.target==this.rW){if(this.SF>20)this.SF/=n}else{if(this.SF<100)this.SF*=n}this.Uc()};
cl.prototype.c2=function(){this.GZ(this.ww)};cl.prototype.GZ=function(w,n){this.ww=w;if(!e.LY(this.h_))return;
if(this.qj==null)this.Wg();this.qj.$(w.Hu,w.hY,w.Io);var W=w.Hu,D=W.lJ.Font,m=0;if(D==null)return;var j=W.JO[D].Name;
if(this.adO==j)return;var D=w.hY.lY(j);if(D==null)return;var I=D.maxp.numGlyphs,U=this.azd=new Array(I);
for(var L=0;L<I;L++)U[L]={BO:[]};var M=Date.now(),l=new Uint8Array(1048575);for(var L=0;L<1048575;L++){var A=Typr.U.codeToGlyph(D,L);
if(A!=0&&A<I){l[L]=1;if(U[A].BO.length==0)m++;U[A].BO.push(L)}}var g=cl.ie,k=[];for(var L=0;L<g.length;
L++)k.push([]);for(var A=1;A<I;A++){k[0].push(A);var $=U[A].BO[0];if($==null){continue}for(var C=1;C<g.length;
C++){var f=g[C].OM;for(var L=0;L<f.length;L+=2)if(f[L]<=$&&$<=f[L+1]){k[C].push(A);break}}}this.oM=k;
var z=[];for(var L=0;L<g.length;L++)z.push(g[L].DG+" ("+k[L].length+")");var s=this.lv.b();this.lv.TF(z);
this.lv.$(s);this.adO=j;this.awL=D;this.Uc()};cl.prototype.awj=function(w){var n=Math.floor(this.DX/this.SF);
return Math.floor(this.DX/n)};cl.prototype.Uc=function(w){if(!e.LY(this.h_)||this.oM==null)return;var n=this.oM[this.lv.b()],W=n.length,D=this.awL,j=Typr.U,I=this.awj(),U=I,M=U*.8,m=U*.8/D.head.unitsPerEm,l=[],A=Math.floor(this.DX/I),g=Math.ceil(W/A),k=this.a0L,$=Date.now();
for(var C=0;C<g;C+=k){var f=e.t("canvas"),z=f.getContext("2d");f.width=I*A;f.height=U*k;z.fillStyle="white";
z.fillRect(0,0,A*I,U*k);for(var s=0;s<k;s++){for(var O=0;O<A;O++){var L=n[(C+s)*A+O];if(L==null)break;
var a=j.glyphToPath(D,L),X=E.p.mY(a.crds);z.fillStyle="#252525";if(X.VY()){var P=D.hmtx,Z=[],V=170;for(var Y in P)Z.push(Y);
var K=P[Z[0]][L],S=P[Z[1]][L],G=Math.max(K,S);a={cmds:"M L M L M L".split(" "),crds:[0,0,G,0,0,-V,0,V,G,-V,G,V]};
X.m=G;X.x=0;z.strokeStyle="rgba(0,255,0,1)"}z.beginPath();var T=O*I+(I-X.m*m)*.5-X.x*m,R=s*U+M;z.translate(T,R);
z.scale(m,-m);j.pathToContext(a,z);z.scale(1/m,-1/m);z.translate(-T,-R);X.VY()?z.stroke():z.fill()}}z.beginPath();
for(var O=0;O<A;O++){var x=O*I+I+.5;z.moveTo(x,0);z.lineTo(x,U*k)}for(var s=0;s<k;s++){var v=s*U+U+.5;
z.moveTo(0,v);z.lineTo(A*I,v)}z.strokeStyle="rgba(0,0,0,0.3)";z.stroke();l.push(f)}this._e.jJ(l,null,I*A,U*k)};
cl.ie=[{DG:"All Glyphs"},{DG:"Basic Latin, Latin 1",OM:[0,127,128,143]},{DG:"Latin Extended-A",OM:[256,383]},{DG:"Latin Extended-B",OM:[384,591]},{DG:"Punctuations",OM:[33,35,37,39,42,42,44,44,46,47,58,59,63,63,64,64,92,92,161,161,167,167,182,183,191,191,894,894,903,903,1370,1375,1417,1417,8192,8303,11776,11903]},{DG:"Greek",OM:[880,1023]},{DG:"Cyrillic",OM:[1024,1279]},{DG:"Hebrew",OM:[1424,1535]},{DG:"Arabic",OM:[1536,1791]},{DG:"Emoji",OM:[9728,10095,127744,129535]}];
function aO(){et.call(this,[13,0],!1,null,et.ip.X$);this.wT=0;this.a5J=0;this.ww=null}aO.prototype=new et("");
aO.prototype.Wg=function(){if(!e.LY(this.h_)||this.Jo)return;var w=e.t("div","flexrow padded");this.h_.appendChild(w);
var n=e.t("div");w.appendChild(n);this.Jo=[];for(var L=0;L<2;L++){var W=new gM;this.Jo.push(W);W.h("click",this.anE,this);
n.appendChild(W.e)}this.yQ=new bL(192);console.log("hsb picker");this.yQ.h(b.E.A,this.g5,this);this.d5=new aD;
this.d5.parent=this;w.appendChild(this.yQ.e);this.GZ(this.ww,bk.bI)};aO.prototype.anE=function(w){var n=w.currentTarget,W=this.Jo.indexOf(n);
if(W==this.wT){this.d5.$F(W)}else{this.wT=W;this.Uc()}};aO.prototype.g5=function(w){var n=this.yQ.b();
this.yQ.$(n);var W=Math.round(n.o*255)<<16|Math.round(n.B*255)<<8|Math.round(n.k*255),D=new ed(b.E.L,!0);
D.data={d:b.c.oj,AH:bk.X$,vK:this.wT,Z:W};this.S(D);this.a5J=Date.now()};aO.prototype.Uc=function(){if(this.d5==null)return;
var w=this.ww,n=this.wT,W=[w.Gp,w.as];for(var L=0;L<2;L++){var D=this.Jo[L],j=D.e.style;D.hR(W[L]);if(L==n)j.filter="drop-shadow(0 0 1px #000000)"}var I=W[n];
if(Date.now()-this.a5J>100)this.yQ.$({o:(I>>>16)/255,B:(I>>>8&255)/255,k:(I&255)/255})};aO.prototype.GZ=function(w,n){this.ww=w;
if(this.d5==null)return;if(n==bk.bI||n==bk.X$){this.d5.ayV(w.Gp,w.as);this.Uc()}};aO.prototype.mQ=function(){this.Wg()};
aO.prototype.c2=function(){this.Wg();this.Uc()};function gq(){et.call(this,"CSS",!1,"---panels/css",et.ip.CSS);
this.tI=null;var w=e.t("div","padded");this.h_.appendChild(w);this.RE=e.t("textarea");e.xr(this.RE);
w.appendChild(this.RE)}gq.prototype=new et("");gq.prototype.zl=function(w,n){if(this.gA==w)return;this.gA=w;
this.RE.setAttribute("style","display:block;tab-size:4; margin:0; font-family:monospace; width:"+(w-10)+"px; height:"+(n-10)+"px")};
gq.prototype.mQ=function(w){this.tI=w;this.Uc()};gq.prototype.GZ=function(w,n){if(n==bk.v3)this.Uc()};
gq.prototype.Uc=function(){var w=this.tI;if(w==null||w.g.length==0)return;if(!e.LY(this.h_))return;var n=w.C[w.g[0]],W=CSS.auE(n,w);
if(W.length!=0)this.RE.value=W.join(";\n")+";";else this.RE.value=""};gq.prototype.c2=function(){this.Uc()};
function dU(){et.call(this,"DALL\xB7E",!1,null,et.ip.a2X);this.tI=null;var w=this.aff=e.t("div","form padded labfxd");
this.h_.appendChild(w);this.Qg=["256x256","512x512","1024x1024"];this.ev=0;this.bE={};this._m=[];this.xx=[];
this.fJ=null;var n=["API Key","Generate"],W=this.Cx=[[new ga("Use our key (1000 generations a day) or get your own at beta.openai.com."),new j$(null,["Our key","Your own key"]),new e7],[new e7("Prompt",null,null,4),new i0([12,14,0],this.Qg),new g_([15,5,1],1,10),new iP([12,49],!0,null,!0)]];
W[1][0].$("goat riding a bike");W[1][1].$(2);W[1][2].$(1);for(var L=0;L<2;L++){var D=new iP(n[L]);this._m.push(D);
w.appendChild(D.e);D.h("click",this.aaf,this);var j=e.t("div");this.xx.push(j);var I=W[L];for(var U=0;
U<I.length;U++){I[U].parent=this;j.appendChild(I[U].e);if(L!=0||U!=1)e.x$(j);if(L==0)I[U].h(b.E.A,this.a95,this);
if(L==1&&U==3)I[U].h("click",this.aj$,this)}}e.R2(w);this.Bz=e.t("div");w.appendChild(this.Bz);this.mA=e.t("div","scrollable");
this.xx[1].appendChild(this.mA);var M=localStorage.getItem("sd_api_key");if(M){M=M.split(",");W[0][1].$(parseInt(M[0]));
W[0][2].$(M[1])}else W[0][2].$("your_api_key");this.a95();this.aaf(null,1)}dU.prototype=new et("");dU.prototype.aj$=function(){var w=this.Cx,n=w[0],W=w[1],D="https://api.openai.com/v1/images/generations",j="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";
if(n[1].b()==1)j=n[2].b().trim();var I={model:"image-alpha-001",prompt:W[0].b().trim(),num_images:W[2].b(),size:this.Qg[W[1].b()],response_format:"b64_json"},U=new XMLHttpRequest;
U.open("POST",D,!0);U.setRequestHeader("Content-type","application/json");U.setRequestHeader("Authorization","Bearer "+j);
U.onload=dU.prototype.ahI.bind(this);U.send(JSON.stringify(I));e.W0(this.h_,"disabled")};dU.prototype.ahI=function(w){e.IX(this.h_,"disabled");
var n=JSON.parse(w.target.response),W=n.error;if(W){alert(W.message,5e3);return}var D=this.bE,j=this.Cx,I=j[1][0].b().trim()+":"+j[1][1].b();
if(D[I]==null)D[I]=[];D[I].push(n);this.Uc()};dU.prototype.a95=function(w){var n=this.Cx,W=n[0][1].b(),D=n[0][2].b().trim();
localStorage.setItem("sd_api_key",W+","+D);n[0][2].G3(W==1)};dU.prototype.aaf=function(w,L){e._g(this.Bz);
if(L==null)L=this._m.indexOf(w.target);for(var n=0;n<2;n++)this._m[n].$(n==L);this.Bz.appendChild(this.xx[L])};
dU.prototype.zl=function(w,n){if(this.gA==w)return;this.gA=w;this.aff.style.width=w-16+"px";this.mA.style.height=n-190+"px"};
dU.prototype.mQ=function(w,n){this.tI=w;if(w)this.ev=n.indexOf(w);this.Uc()};dU.prototype.GZ=function(w,n){};
dU.prototype.f=function(w,n){et.prototype.f.call(this);for(var L=0;L<2;L++){this._m[L].f();for(var W=0;
W<this.Cx[L].length;W++)this.Cx[L][W].f()}};dU.prototype.Uc=function(){var w=this.mA,n=this.bE;e._g(w);
var W=[];for(var D in n){n[D].sort(function(f,z){return z.created-f.created});W.push([D,n[D]])}W.sort(function(f,z){return z[1][0].created-f[1][0].created});
var j=this.aiq.bind(this),I=this.fJ=[[],[]];for(var L=0;L<W.length;L++){var D=W[L][0].split(":"),U=W[L][1],M=this.Qg[D[1]],m=parseInt(M.split("x")[0]),l=e.t("div");
l.textContent=D[0]+", "+m+" x "+m;w.appendChild(l);for(var A=0;A<U.length;A++){var g=U[A].data;for(var k=0;
k<g.length;k++){var $=g[k].b64_json,C=e.t("img");C.setAttribute("src","data:image/png;base64,"+$);C.onclick=j;
C.style.width=128/e.V()+"px";C.style.marginRight="4px";C.style.cursor="pointer";w.appendChild(C);I[0].push(C);
I[1].push(g[k])}}}};dU.prototype.aiq=function(w){var L=this.fJ[0].indexOf(w.target),n=this.fJ[1][L].b64_json,W=jj.a4Z(n);
e8.rb({url:"file",ev:this.ev},W,this)};dU.prototype.c2=function(){this.Uc()};function b9(){et.call(this,[9,6],!1,"---panels/info",et.ip.a8J);
this.h_.setAttribute("style","min-width:240px;");this.tI=null;this.ww=null;var w=this.a0=[];for(var n=0;
n<3;n++){var W=e.t("div","marged row");this.h_.appendChild(W);var D=e.t("div","cell");D.setAttribute("style","width:10em");
W.appendChild(D);var j=e.t("div","cell");j.setAttribute("style","width:10em");W.appendChild(j);for(var L=0;
L<(n==2?3:4);L++){var I=new ga("");w.push(I);I.$(0);I.e.style.padding="0";var U=n!=1||L<2?D:j;U.appendChild(I.e);
e.x$(U)}if(n<2)e.R2(this.h_)}this.Sg=w[4];this.Be=w[5];this.LS=w[6];this.Ai=w[7]}b9.prototype=new et("");
b9.prototype.QD=function(w,n,W,D,j){if(!e.LY(this.h_)||w==null)return;var I=w.u.Cg(j.x,j.y),U=new ec(Math.floor(I.x),Math.floor(I.y));
if(!j.WS){var M=0,m=0,l=0,A=0,g=this.a0;if(!j.WS&&!w.avj()&&new iB(0,0,w.m-1,w.n-1).y5(U)){var k=w.Vc(),L=w.m*U.y+U.x<<2;
M=k[L+0];m=k[L+1];l=k[L+2];A=k[L+3]}g[0].$("R: "+M);g[1].$("G: "+m);g[2].$("B: "+l);g[3].$("A: "+A);
var $=E.Yc(M,m,l);g[8].$("H: "+Math.round($.ag*360)+"\xB0");g[9].$("S: "+Math.round($._6*100)+"%");g[10].$("B: "+Math.round($.k*100/255)+"%")}var C=w.u.N>1?new ec(I.x,I.y):U;
this.Sg.$("X: "+E.f_.BE(C.x,w.hh,W,w.m));this.Be.$("Y: "+E.f_.BE(C.y,w.hh,W,w.n));this.IB()};b9.prototype.IB=function(){var w=this.tI,n=this.ww,W=0,D=0;
if(w&&n){if(w.u.Bn){W=w.u.Bn.m;D=w.u.Bn.n}else if(w.J){W=w.J.rect.m;D=w.J.rect.n}W=E.f_.BE(Math.abs(W),w.hh,n,w.m);
D=E.f_.BE(Math.abs(D),w.hh,n,w.n)}this.LS.$(fV.get([12,41]).charAt(0)+": "+W);this.Ai.$(fV.get([12,42]).charAt(0)+": "+D)};
b9.prototype.f=function(){et.prototype.f.call(this);this.IB()};b9.prototype.mQ=function(w,n,W){this.tI=w;
this.ww=W;this.IB()};function c6(){et.call(this,[9,1],!1,"---panels/layers",et.ip.Yu);this.HV=null;this.K2=[];
this.On=null;this.BV=null;this.Oc=e.t("div","lphead");this.yd=e.t("div","lpbody scrollable");this.yd.addEventListener("scroll",this.a9e.bind(this),!1);
this.jU=e.t("div","lpfoot");var w=this.auP=e.t("span");w.setAttribute("style","display:inline-block; height:26px");
this.Oc.appendChild(w);this.sr=new i0(null,dD.AE,dD.E5);this.sr.h(b.E.A,this.awW,this);this.Oc.appendChild(this.sr.e);
this.Pr=new g_([12,0],0,100,"%",0);this.Pr.h(b.E.A,this.avM,this);this.Pr.parent=this;this.Oc.appendChild(this.Pr.e);
this.Qr=new jw([6,57,2],["<img src=\""+PIMG.trsp3+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG["tools/brush"]+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG.pos+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG["lrs/lock"]+"\" class=\"miniscale gsicon\" />"],!0,["Transparency",[12,76,2],[12,40],[7,0]]);
this.Qr.h(b.E.A,this.alq,this);this.Oc.appendChild(this.Qr.e);this.M7=new g_([12,26],0,100,"%",0);this.M7.h(b.E.A,this.aAi,this);
this.M7.parent=this;this.Oc.appendChild(this.M7.e);this.av=[];this.$l();this.h_.appendChild(this.Oc);
this.h_.appendChild(this.yd);this.yd.addEventListener("dragover",function(j){j.preventDefault()},!1);
this.yd.addEventListener("dragenter",e.oz,!1);this.yd.addEventListener("drop",this.a0m.bind(this),!1);
this.h_.appendChild(this.jU);this.h_.addEventListener("contextmenu",e.oz,!1);this.h("rclick",this.ago,this);
var n=function(j,I,L){return{hO:this.kv[L]==1}}.bind(this);this.acN=new cA([{name:[0,6],r:n},{name:[14,10],r:n},{name:[6,57,2],r:n,nW:!0},{name:"Long-tap as a right click",r:n,nW:!0},{name:"\u2796 Thumbnail Size"},{name:"\u2795 Thumbnail Size"},{name:"Thumbnails by Layer",r:function(){return{hO:jo.kZ==0,r:!0}}},{name:"Thumbnails by Document",r:function(){return{hO:jo.kZ==1,r:!0}}}]);
this.acN.h("select",this.ab0,this);this.kv=[0,1,1,0];var W=window.localStorage;if(W){var D=W.getItem("lpOpt");
if(D){D=JSON.parse(D);this.kv=D[0];jo.k_=D[1];jo.kZ=D[2]}}this.ab0()}c6.prototype=new et("");c6.prototype.Qj=function(){if(this.atQ)return;
var w=db.pq(!0),n=db.Km(!0);this.atQ=new cA(w,n);var w=[{name:[14,10]},{name:[14,11],nW:!0},{name:[6,0]},{name:[11,4]},{name:[5,4],nW:!0},{name:[6,7,0]},{name:"New Smart Obj. via Copy",r:function(W){return{r:W.C[W.g[0]].add.SoLd!=null}},nW:!0},{name:[6,8],r:c6.a2i},{name:[6,34],r:function(W){var D=W.C[W.g[0]];
return{r:D.add.lmfx!=null&&!D.ue()}}},{name:[6,40],nW:!0,r:function(W){var D=W.C[W.g[0]];return{r:D.add.TySh!=null}}},{name:"",nW:!0,r:function(W){var D=W.C[W.g[0]],j=D.add.TySh,I=j?j._o:null;
return{r:j!=null&&I.Curve==null,fP:fV.get(j&&hd.F$(I)==0?[16,3,1]:[16,3,0])}}},c6.a3y(!1),db.aAI(),{name:[6,12,0],r:function(W){var D=W==null?0:W.g.length;
return{r:D!=0&&(D!=1||W.g[0]!=0),fP:fV.get(D>1||D==1&&W.C[W.g[0]].ue()?[6,12,0]:[6,10])}}},{name:[6,12,1],nW:!0},{name:[13,0],sub:function(){var W=[];
for(var L=0;L<ir.kr.length;L++)W.push({name:[13,1,L],qg:"#"+E.$$(ir.kr[L])});return W}()}],n=[{Y:b.E.L,W:{d:b.c.P2,jW:"layerstyle"}},{Y:b.E.v,G:y.wA,W:{d:"fromlayer",HD:[null,0,0]}},{Y:b.E.v,G:y.Yu,W:{d:h.R6}},{Y:b.E.L,W:{d:b.c.P2,jW:"duplinto"}},{Y:b.E.v,G:y.Yu,W:{d:h.du}},{Y:b.E.W1,W:{hZ:"newPlacedLayer"}},{Y:b.E.v,G:y.Yu,W:{d:h.v0}},{Y:b.E.W1,W:{hZ:"rasterizeLayer",E3:{classID:"rasterizeLayer",null:cq.Pz("Lyr",!0)}}},{Y:b.E.v,G:y.Yu,W:{d:h.fi}},{Y:b.E.v,G:y.Yu,W:{d:h.atX}},{Y:b.E.v,G:y.Lu,W:{d:"switchPntPrgr"}},{Y:b.E.v,G:y.Yu,W:{d:h.Yt}},db.a1o(),{Y:b.E.W1,W:{hZ:"mergeLayersNew",E3:{__name:"Merge Layers",classID:"Mrg2"}}},{Y:b.E.W1,W:{hZ:"flattenImage"}},{sub:function(){var W=[];
for(var L=0;L<8;L++)W.push({Y:b.E.v,G:y.Yu,W:{d:h.HT,ayZ:L}});return W}()}];this.t8=new cA(w,n);var w=[{name:[6,45],r:function(W){var D=W.C[W.g[0]];
return{r:D.NP(W).z==null}}},{name:[6,47]}],n=[{Y:b.E.v,G:y.Yu,W:{d:h.lc}},{Y:b.E.v,G:y.Yu,W:{d:h.fE}}];
this.ape=new cA(w,n);var w=[{name:"enab/disab",r:function(W){return{fP:fV.get(W.C[W.g[0]]._N().isEnabled?[6,15]:[6,14])}}},{name:[6,22]},{name:[5,8],r:function(W){return{r:W.d2(!1,!0)}}}],n=[{Y:b.E.v,G:y.Yu,W:{d:h.Gw}},{Y:b.E.v,G:y.Yu,W:{d:h.kR}},{Y:b.E.v,G:y.Yu,W:{d:h.Q_}}];
this.awb=new cA(w,n);var w=[{name:"enab/disab",r:function(W){return{fP:fV.get(W.C[W.g[0]].NP(W).z.isEnabled?[6,42]:[6,41])}}},{name:[6,46]}],n=[{Y:b.E.v,G:y.Yu,W:{d:h.cV}},{Y:b.E.v,G:y.Yu,W:{d:h.Wu}}];
this.asr=new cA(w,n);var w=[{name:"enab/disab",r:function(W){return{fP:fV.get(W.C[W.g[0]].add.vmsk.isEnabled?[6,17]:[6,16])}}},{name:[6,24]},{name:[6,8]}],n=[{Y:b.E.v,G:y.Yu,W:{d:h.Uo}},{Y:b.E.v,G:y.Yu,W:{d:h.qc}},{Y:b.E.v,G:y.Yu,W:{d:h.lB}}];
this.ax3=new cA(w,n);this.asQ=new cA(db.adM(!0),db.XG(!0));this.ays=new cA(db.pq(),db.Km())};c6.prototype.a9e=function(w){var n=this.yd.scrollTop-600;
for(var L=0;L<this.K2.length;L++){var W=this.K2[L],D=W.X9;if(n<W.X9)W.asD();if(W.X9>n+this.ag+600)break}};
c6.prototype.GS=function(){return this.acN};c6.prototype.ab0=function(w){var n=this.kv;if(w){var W=w.target.aJ(),L=W[0];
if(L<4)n[L]=1-n[L];else if(L<6){if(L==4&&jo.k_-10>=10)jo.k_-=10;if(L==5&&jo.k_+10<=200)jo.k_+=10;if(this.On)this.On.rR=!0}else{if(L==6)jo.kZ=0;
if(L==7)jo.kZ=1;if(this.On)this.On.rR=!0}var D=window.localStorage;if(D)D.setItem("lpOpt",JSON.stringify([n,jo.k_,jo.kZ]))}if(n[0]==1)this.a6_();
var j=[[{e:this.auP}],[this.sr,this.Pr],[this.Qr,this.M7]];for(var L=0;L<3;L++)for(var I=0;I<j[L].length;
I++)j[L][I].e.style.display=n[L]==1?"inline-block":"none";this.zl(this.gA,this.ag)};c6.prototype.asW=function(){var w=this.d8;
if(w==null)return!1;if(w.b()){var n=this.FG.b(),W=this.Y9[n].b();if(n==0)return W.indexOf(!0)!=-1;if(n==1)return W!=""}return!1};
c6.a3y=function(w){var n=function(D){var j=D!=null&&D.g.length!=0&&D.C[D.g[0]].QY;return{hO:j,r:D!=null&&D.aV(D.g[0]),W:{Y:b.E.W1,W:{hZ:j?"ungroup":"groupEvent",E3:{classID:j?"Ungr":"GrpL",null:cq.Pz("Lyr",!0)}}}}},W={name:[6,6,0],nW:!0,r:n};
if(w)W.pn=[aK.PJ,aK.CQ,aK.rP];return W};c6.a2i=function(w,n){if(w)for(var L=0;L<w.g.length;L++){var W=w.C[w.g[L]];
if(W.add.TySh||W.add.SoLd||W.add.SoCo||W.add.GdFl||W.add.PtFl)return{r:!0}}return{r:!1}};c6.prototype.a0m=function(w){e.oz(w);
var n=w.dataTransfer.getData("Text"),W=1,D=0;if(n==""){e.ri(w,this,this.BV.indexOf(this.On),D+(W>.5?0:1))}else if(n!="--panel"){var n=JSON.parse(n),j=n.Y3;
if(j=="l")this.f8({d:h.nP,source:n.RL,target:D,TJ:W})}};c6.prototype.ago=function(w){var n=this.On,W=w.data,j;
if(n.g.indexOf(W.j)==-1){var D={d:h.Gz,j:w.target._r.index,LM:W.eL};this.f8(D)}if(n.g.indexOf(W.j)==-1)return;
this.Qj();if(W.eL==1){j=this.awb}else if(W.eL==2){j=this.ax3}else if(W.eL==3){j=this.asr}else if(W.eL==4){j=this.ape}else if(W.eL==5){j=this.atQ}else{j=this.t8}j.f();
j.update(n);j.parent=this;var I=new ed(b.E.L,!0);I.data={d:b.c.Uq,BT:j,x:W.Sd.x+1,y:W.Sd.y+1};this.S(I)};
c6.prototype.f=function(){et.prototype.f.call(this);this.sr.f();this.Pr.f();this.Qr.f();this.M7.f();
if(this.d8){this.d8.f();this.Y9[0].f()}if(this.On)this.mQ(this.On);var w="lrs/link lrs/fx lrs/adj lrs/mask lrs/folder lrs/newlayer lrs/bin".split(" ");
for(var L=0;L<this.av.length;L++){var n=this.av[L];n.wV(e.DZ(w[L],null,"miniscale"));if(L==1||L==2){n.e.style.position="relative";
var W=e.t("img","gsicon");W.setAttribute("src",PIMG["tools/corner"]);W.setAttribute("style","position:absolute; right:0; bottom:0; width:100%; height:100%;");
n.e.appendChild(W)}}};c6.prototype.mQ=function(w,n){if(w&&!w.rR)return;if(w==null)e.W0(this.h_,"disabled");
else e.IX(this.h_,"disabled");this.On=w;this.BV=n;if(this.HV!=null){e._g(this.yd);this.HV=null;this.K2=[]}if(w==null)return;
var W=!1;for(var L=0;L<w.yo.length;L++)if(w.yo[L].$P)W=!0;this.HV=new ir(w.root,this,w,{pL:0,HF:!1},{abY:W,ak2:this.asW()},this.K2,0,new iB(0,0,w.m,w.n));
if(w.g.length==0||w.C[w.g[0]]==null)e.W0(this.Oc,"disabled");else{e.IX(this.Oc,"disabled");if(w.g.length==1&&w.gL){var D=w.g[0];
for(var L=0;L<this.K2.length;L++){var j=this.K2[L];if(j._r.index==D&&j.Oc.scrollIntoView)j.Oc.scrollIntoView({block:"nearest"})}}var I=w.C[w.g[0]];
if(I.ue()){this.sr.TF([[15,10,27]].concat(dD.AE),[1].concat(dD.E5));var U=dD.mS.indexOf(I.Bx);this.sr.$(U+1)}else{this.sr.TF(dD.AE,dD.E5);
var U=dD.mS.indexOf(I.Bx);this.sr.$(U)}this.Pr.$(Math.round(100*I.opacity/255));this.Qr.$([I.m7(0),I.m7(1),I.m7(2),I.m7(31)]);
var M=w.gr();this.sr.G3(!M);this.M7.G3(!M);this.Pr.G3(!M);this.Qr.G3(!(M&&!I.m7(31)));this.M7.$(Math.round(100*(I.add.iOpa!=null?I.add.iOpa/255:1)));
this.av[3].ayn(fV.get(I._N()?[6,23]:[6,21]))}this.a9e(null)};c6.prototype.zl=function(w,n){this.gA=w;
this.ag=n;var W=this.Oc.getBoundingClientRect().height;if(55<W&&W<56)W=60.2;var D=this.jU.getBoundingClientRect().height,j=n-(W+D+3);
this.yd.style.height=j+"px";this.yd.style.width=w+"px"};c6.prototype.awW=function(w){this.f8({d:h.jC,qY:this.sr.b()})};
c6.prototype.avM=function(w){this.f8({d:h.JM,qY:Math.round(255*this.Pr.b()/100)})};c6.prototype.alq=function(w){this.f8({d:h.ge,qY:[this.Qr.b(),[0,1,2,31]]})};
c6.prototype.aAi=function(w){this.f8({d:h.p6,qY:Math.round(255*this.M7.b()/100)})};c6.prototype.Qd=function(w){if(w.target==this.FG)this.a6_();
var n=this.d8.b();if(n)e.IX(this.fy,"disabled");else e.W0(this.fy,"disabled");this.f();this.On.rR=!0;
this.mQ(this.On);this.On.rR=!1};c6.prototype.a6_=function(){var w=this.fy;if(w==null){var n=this.auP,W=this.d8=new b7([0,6]);
W.h(b.E.A,this.Qd,this);n.appendChild(W.e);w=this.fy=e.t("span","disabled");n.appendChild(w);this.FG=new i0(null,["Kind",[12,48]],[]);
this.FG.h(b.E.A,this.Qd,this);var D=this.Y9=[new jw(null,["<img src=\""+PIMG.pix_layer+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG["lrs/adj"]+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG["tools/htype"]+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG.shape_layer+"\" class=\"miniscale gsicon\" />","<img src=\""+PIMG.so_layer+"\" class=\"miniscale gsicon\" />"],!0,[[12,76,2],[3,0],[12,44],[12,77],[6,7,1]]),new e7(null,null,8)];
D[0].h(b.E.A,this.Qd,this);D[1].h("input",this.Qd,this)}e._g(w);w.appendChild(this.FG.e);w.appendChild(this.Y9[this.FG.b()].e)};
c6.prototype.ahP=function(w){this.Qj();this.aqX(w,this.asQ)};c6.prototype.a2f=function(w){this.Qj();
this.aqX(w,this.ays)};c6.prototype.aqX=function(w,n){var W=w.currentTarget;if(e.LY(n.e))return;w.stopPropagation();
var D=W.getBoundingClientRect();n.f();n.update(this.On);n.parent=this;var j=new ed(b.E.L,!0);j.data={d:b.c.Uq,BT:n,x:D.left,y:D.top,a5y:!0};
this.S(j)};c6.prototype.aw2=function(w){this.f8({d:h.amd})};c6.prototype.ac4=function(w){this.f8({d:this.On.g.length>1?h.Vp:h.Si})};
c6.prototype.afS=function(w){this.f8({d:h.tp})};c6.prototype.azf=function(w){var n=this.On;if(n.g.length==0)return;
var W=n.C[n.g[0]],D=W.eL;this.f8({d:D<=0?W.na?h.qc:h.du:D==3?h.Wu:h.kR})};c6.prototype.a2h=function(w){this.f8({d:h.qf})};
c6.prototype.f8=function(w){var n=new ed(b.E.v,!0);n.data=w;n.G=y.Yu;this.S(n)};c6.prototype.$l=function(){var w=[[6,54,0],[11,6],[6,1],[6,21],[6,20],[6,13],[5,4]],n=[this.a2h,this.a2f,this.ahP,this.aw2,this.ac4,this.afS,this.azf],W=this.a5x.bind(this);
for(var L=0;L<w.length;L++){var D=new iP("W",!1,w[L]);this.av.push(D);e.L_(D.e,n[L].bind(this));this.jU.appendChild(D.e);
if(L>=w.length-3){var j=D.e;j.addEventListener("drop",W,!1);j.addEventListener("dragover",function(I){I.preventDefault()},!1);
j.addEventListener("dragenter",e.oz,!1)}}};c6.prototype.a5x=function(w){e.oz(w);var n=0,W=this.av;while(W[n].e!=w.currentTarget)n++;
W[n].OD();var D=w.dataTransfer.getData("Text");if(D=="")return;var D=JSON.parse(D);if(D.Y3=="l"){var j={d:[h.Vp,h.R6,h.du][n-4]};
if(this.On.g.indexOf(D.RL)==-1)j.j=D.RL;this.f8(j)}if(n!=6)return;if(D.Y3=="sm"||D.Y3=="s"){var I=new ed(b.E.v,!0);
I.G=y.EA;I.data={d:D.Y3=="sm"?"st_clear":"st_delsingle",j:D.RL,RL:D.cf};this.S(I)}if(D.Y3=="fm"||D.Y3=="f"){this.f8({d:D.Y3=="fm"?h.fE:h.jX,src:D.RL,cf:D.cf})}if(D.Y3=="m"||D.Y3=="vm"){this.f8({d:D.Y3=="m"?h.kR:h.qc,j:D.RL})}};
function ir(w,n,W,D,j,I,U,M){eg.call(this);this.parent=n;this.X9=U;this._r=w;I.push(this);this.yV=W;
this.kn=D;var m=n.yd,l=w.j,A=W.g.indexOf(w.index)!=-1,C=null;this.Oc=e.t("div",A?"head selected":"head");
if(l.add.artb!=null){e.W0(this.Oc,"artb");M=l.yP()}var g=this.abv=Math.floor(10+l.a2j/e.V()),k="height: "+g+"px;";
if(A&&j.abY)k+="background-color:rgba(255,50,50,0.4);";this.Oc.setAttribute("style",k);this.AD=M;var $=this.adU=this.aqK.bind(this),f=j.ak2&&!this.akx();
if(!f){if(w.depth!=0){m.appendChild(this.Oc);U+=g}if(l.Z_()||l.YC())if(l.IF()){C=this.atk=e.t("div","lpineck");
m.appendChild(C);if(l.Z_()){C.addEventListener("contextmenu",$,!1);var z=new c6.Y1(fV.get([12,1]),"sm","layerstyle",w.depth,0,null);
U+=21;z.parent=this;C.appendChild(z.e);var s=l.add.lmfx,O=s.masterFXSwitch.v;z.gb(O);for(var L=0;L<at.order.length;
L++){var a=s[at.Pa[L]].v;if(a.length==0)continue;for(var X=0;X<a.length;X++){var z=new c6.Y1(fV.get(at.names[L]),"s","layerstyle",w.depth,1,[L,X]);
U+=21;z.gb(O&&a[X].v.enab.v);z.parent=this;C.appendChild(z.e)}}}if(l.YC()){var P=l.NP(W).z;if(P)this.$Q=e.t("div","thumb");
var z=new c6.Y1(fV.get([12,55]),"fm",null,w.depth,0,-1,P?this.$Q:null);U+=P?g:21;z.parent=this;C.appendChild(z.e);
this.agi=z.e;this.agi.addEventListener("contextmenu",$,!1);var s=l.add.SoLd.filterFX.v,Z=s.filterFXList.v,O=s.enab.v;
z.gb(O);for(var L=Z.length-1;L>=0;L--){var Y=Z[L].v,K=cx.iF(Y);if(eH.SM[K])K=eH.SM[K];var S=Y.Nm.v;if(cx.names[K])S=fV.get(cx.names[K]);
if(eH.names[K])S=fV.get(eH.names[K]);var G="afw_"+K,z=new c6.Y1(S,"f",G,w.depth,1,L);U+=21;z.gb(O&&Y.enab.v);
z.parent=this;C.appendChild(z.e)}}}}var V=l.add.lclr;if(V==null)V=0;V=V==0?D.pL:ir.kr[V];this.awv=V;
if(l.ue()&&(l.add.lsct==ef.fz||j.ak2)){var T={pL:V,HF:D.HF||l.m7(31)};for(var L=w.children.length-1;
L>=0;L--){var R=new ir(w.children[L],n,W,T,j,I,U,M);U=R.att}}this.att=U}ir.prototype=new eg;ir.kr=[16777215,16711680,16748544,16763904,4513024,22015,11141375,7829367];
ir.prototype.asD=function(){if(this.qt)return;var w=this._r,n=w.j,W=this.yV,D=this.kn,g=!0,T=!1;w.sX(W,this.AD,!0);
var j=e.t("div","headL"),I=e.t("div","headR");this.Oc.appendChild(j);this.Oc.appendChild(I);var U=this.Oc;
U.setAttribute("draggable","true");U.addEventListener("dragstart",this.fe.bind(this),!1);U.addEventListener("drop",this.eo.bind(this),!1);
U.addEventListener("dragover",this.kJ.bind(this),!1);U.addEventListener("dragenter",e.oz,!1);U.addEventListener("dragleave",this.QS.bind(this),!1);
var M=[],m=[null,null,null,null],l=n.I4(),A=w;while(A.parent){A=A.parent;l=l&&A.j.I4()}if(n.QY){for(var L=w.index-1;
L>=0;L--){var k=W.C[L];if(!k.QY){g=k.I4();break}}}var $=n.I4()?l&&g?2:1:0;this.qt=e.t("div");var C=e.t("div",$==0?"sqr":"eye");
this.qt.appendChild(C);C.style.opacity=[.12,.33,1][$];var f=e.t("div","space");this.oh=e.t("div","label");
this.oh.setAttribute("style","max-width:calc(100% - "+(96+w.depth*20)+"px); margin-top:"+(this.abv-19)/2+"px;");
this.oh.textContent=n.getName();this.ca=e.t("div","lock");this.atd=e.t("div","lrfx");this.Sr=e.t("div","arfx");
var z=this.adU,s=this.a8N.bind(this);this.Oc.addEventListener("click",s,!1);this.Oc.addEventListener("contextmenu",z,!1);
var O=this.awv;if(O!=0){var a=[O>>16,O>>8&255,O&255];for(var L=0;L<3;L++){a[L]="calc("+a[L]+"*0.7 + (var(--absc)) * 255 * 0.3)"}this.qt.setAttribute("style","background-color:rgba("+a.join(",")+",1);")}var X=this.axN.bind(this);
this.qt.addEventListener("mousedown",X,!1);this.qt.addEventListener("mouseover",X,!1);this.Sr.addEventListener("click",this.a4r.bind(this),!1);
M[0]=this.qt;M[1]=f;M[10]=this.oh;if(n.ue()){var P=e.t("div","arrow"),Z=e.t("div","folder");this.EI(Z);
P.addEventListener("click",this.atN.bind(this),!1);M[2]=P;M[3]=Z;P.className=n.add.lsct==ef.fz?"open":"closed"}else{this.pe=e.t("div","thumb");
M[5]=this.pe;ir.Z9(this.pe,n.ji);this.EI(this.pe);if(eH.get(n.add))e.W0(n.ji.canvas,"gsicon")}var Y=n._N();
if(Y){this.LB=e.t("div","chain");this.l_=e.t("div","thumb");ir.Z9(this.l_,n.pO,!0);this.LB.style.opacity=Y.gm?1:0;
this.LB.addEventListener("click",this.avc.bind(this),!1)}var K=n.I9()&&n.add.vmsk;if(n.add.vmsk&&!K){this.P_=e.t("div","chain");
this.zE=e.t("div","thumb");ir.Z9(this.zE,n.bA,!0);this.P_.style.opacity=n.add.vmsk.gm?1:0;this.P_.addEventListener("click",this.ay4.bind(this),!1)}if(n.YC()&&n.IF()&&n.NP(W).z){ir.Z9(this.$Q,n.RX,!1);
this.EI(this.$Q);this.$Q.addEventListener("click",s,!1);this.$Q.addEventListener("contextmenu",z,!1)}if(w.index==W.g[0]){var S=n.eL,G;
if(S<=0)G=this.pe;else if(S==1)G=this.l_;else if(S==3)G=this.$Q;if(G)G.className="thumb active";if(n.na&&this.zE)this.zE.className="thumb active"}f.setAttribute("style","width:"+Math.max(0,w.depth-1)*18+"px");
var V=n.add.lspf!=null&&n.add.lspf!=0||D.HF;this.ca.style.opacity=n.m7(31)?1:.5;M[4]=n.QY?e.t("div","clipp"):null;
M[6]=Y?this.LB:null;M[7]=Y?this.l_:null;M[8]=n.add.vmsk&&!K?this.P_:null;M[9]=n.add.vmsk&&!K?this.zE:null;
var R=n.Ux,x=W.g;if(R!=0)for(var L=0;L<x.length;L++)if(W.C[x[L]].Ux==R){T=!0;break}if(T){m[0]=e.t("div",n.lj?"link":"linkX");
m[0].addEventListener("click",this.aoB.bind(this),!1)}m[1]=V?this.ca:null;m[2]=n.Z_()?this.atd:null;
m[3]=n.Z_()||n.YC()?this.Sr:null;this.Sr.className=n.IF()?"arfx open gsicon":"arfx closed gsicon";
var v=M;for(var L=0;L<v.length;L++)if(v[L])j.appendChild(v[L]);v=m;for(var L=0;L<v.length;L++)if(v[L])I.appendChild(v[L])};
ir.Z9=function(w,n,W){var D=n.canvas;e.gH(D);if(W)w.setAttribute("draggable","true");w.appendChild(D);
D.setAttribute("style",D.getAttribute("style")+"; pointer-events:none")};ir.prototype.EI=function(w){e.L_(w,function(n){if(this.parent.kv[3]==0)return;
e._L(n);e.d6(document.body,function(){clearTimeout(this.aow)}.bind(this));this.aow=setTimeout(function(){var W=new ed("rclick",!0);
W.data={j:this._r.index,eL:this.eL(n),Sd:e.rv(n,document.body)};this.S(W)}.bind(this),600)}.bind(this))};
ir.KE=function(w,n){var W=n.getBoundingClientRect();return(w.clientY-W.top)/W.height};ir.prototype.fe=function(w){w.stopPropagation();
var n=w.target==this.l_?"m":w.target==this.zE?"vm":"l";w.dataTransfer.setData("Text",JSON.stringify({Y3:n,RL:this._r.index}))};
ir.prototype.QS=function(w){e.oz(w);this.Ag()};ir.prototype.eo=function(w){e.oz(w);this.Ag();var n=w.dataTransfer.getData("Text"),W=this.parent.On,D=ir.KE(w,this.Oc),j=this._r.index;
if(D>.8){var I=!0,U=W.root.fs(j);while(U.parent!=null){var M=U.parent,m=M.children;if(m.indexOf(U)!=0)I=!1;
U=U.parent}if(I){j=0;D=1}}if(n==""){e.ri(w,this,this.parent.BV.indexOf(W),j+(D>.5?0:1))}else if(n!="--panel"){var n=JSON.parse(n),l=n.Y3;
if(l=="l")this.f8({d:h.nP,source:n.RL,target:j,TJ:D});else if(l=="m"||l=="vm")this.f8({d:l=="m"?h.a5T:h.AP,src:n.RL,b2:j});
else ir.aq6(w,n,this)}};ir.aq6=function(w,n,W,D){var j=n.Y3,I=W._r.index,U=n.RL;if(j=="s"||j=="sm")W.f8({d:h.eI,src:U,b2:I,cf:n.cf});
if(j=="f"||j=="fm")W.f8({d:h.aox,src:U,b2:I,cf:n.cf,a9:D==null?0:D})};ir.prototype.kJ=function(w){e.oz(w);
var n=ir.KE(w,this.Oc),W=this._r.j.ue()&&.5<n&&n<.8;this.Ag();var D="inset 0 "+(W?0:n>.5?-3:3)+"px "+(W?"5px black":"0 rgba(0,0,0,0.5)");
this.Oc.style.boxShadow=D};ir.prototype.Ag=function(w){this.Oc.style.boxShadow=""};ir.auV=-1;ir.L6=!1;
ir.a0v=function(w){ir.L6=!1;document.body.removeEventListener("mouseup",ir.a0v)};ir.prototype.axN=function(w){if(w.button!=0)return;
if(w.type=="mousedown"){ir.L6=!0;document.body.addEventListener("mouseup",ir.a0v,!1)}if(w.type=="mouseover"&&(!ir.L6||ir.auV==this._r.index))return;
e.oz(w);this.f8({d:h.Ll,j:this._r.index});ir.auV=this._r.index};ir.prototype.atN=function(w){e.oz(w);
this.f8({d:h.a2z,j:this._r.index})};ir.prototype.avc=function(w){this.f8({d:h._9,j:this._r.index})};
ir.prototype.ay4=function(w){this.f8({d:h._x,j:this._r.index})};ir.Ps=0;ir.prototype.sW=function(w){this.f8({d:h.Bl,j:this._r.index,name:w})};
ir.prototype.a4r=function(w){this.f8({d:h.ax7,j:this._r.index})};ir.prototype.aoB=function(w){this.f8({d:h.K9,j:this._r.index})};
ir.prototype.aqK=function(w){if(w.button!=2&&!e.av6(w))return;var n=this.eL(w);if(n!=3&&w.currentTarget==this.agi)n=4;
if(w.target==this.atd||w.currentTarget==this.atk)n=5;var W=new ed("rclick",!0);W.data={j:this._r.index,eL:n,Sd:e.rv(w,document.body)};
this.S(W)};ir.prototype.eL=function(w){var n=w.target,W=n;return W==this.zE?2:W==this.l_?1:W==this.pe?0:W==this.$Q?3:-1};
ir.prototype.a8N=function(w){var n=w.target,$;if(n==this.qt.firstChild||n==this.Sr||n==this.LB||n==this.P_||n.tagName&&n.tagName.toLowerCase()=="input")return;
var W=this.eL(w),D=this.parent.On,j=this._r.index,I=D.C[j];if(n==this.ca){this.f8({d:h.ge,j:j,qY:[[!1,!1,!1,!1,!1],[0,1,2,3,31]]});
return}var U=ir.Ps,M=Date.now()-U<300;ir.Ps=Date.now();if(n==this.oh){if(M){this.Oc.setAttribute("draggable","false");
var m=new et.IM(this.oh,this.sW.bind(this))}else this.f8({d:h.Gz,j:j,LM:W,sL:!0});return}if(w.button==0&&M){if(n==this.oh)return;
var l=new ed(b.E.v,!0),A=new ed(b.E.L,!0),g=new ed(b.E.W1,!0);if(W==0&&I.add.SoCo){var k=E.M.y_(I.add.SoCo.Clr.v);
A.data={d:b.c.P2,jW:"colorpicker",pL:k.o<<16|k.B<<8|k.k,fT:function(z){var s=E.M.lW({k:z&255,B:z>>>8&255,o:z>>16&255});
s={classID:"null",Clr:{t:"Objc",v:s}};var O=new ed(b.E.v,!0);O.G=y.Yu;O.data={d:h.Q2,G1:[j],Mr:!0,Z:{oq:1,S8:s}};
this.S(O)}.bind(this),NG:!0}}else if(W==0&&(eH.get(I.add)||I.add.SoCo||I.add.GdFl||I.add.PtFl))A.data={d:b.c._y,jW:et.ip.$z};
else if(W!=0&&W!=-1)A.data={d:b.c._y,jW:et.ip.$z};else if(W==0&&I.add.SoLd)g.data={hZ:"placedLayerEditContents",E3:{classID:"placedLayerEditContents"}};
else if(W==0&&I.add.TySh){l.G=y.Lu;l.data={d:"editCurr",XT:j}}else A.data={d:b.c.P2,jW:"layerstyle",j:j};
this.S(g.data?g:A.data?A:l);return}if(w.button!=0)return;if(W==1||W==3){var C=W==3?I.NP(D).z:I._N();
$=C.$P?D.u.zC.join("")=="111"?1:2:0}var f={d:h.Gz,j:j,LM:W,aej:$,sL:!0};this.f8(f)};ir.prototype.f8=function(w){var n=new ed(b.E.v,!0);
n.data=w;n.G=y.Yu;this.S(n)};ir.prototype.akx=function(){var w=this._r.j,n=w.add,W=this.parent.FG.b(),D=this.parent.Y9[W].b();
if(W==0){if(D[0]&&n.SoLd==null&&n.TySh==null&&w.oK())return!0;if(D[1]&&eH.get(n)!=null)return!0;if(D[2]&&n.TySh!=null)return!0;
if(D[3]&&n.vstk!=null)return!0;if(D[4]&&n.SoLd!=null)return!0;return!1}if(W==1)return w.getName().toLowerCase().indexOf(D.toLowerCase())!=-1};
c6.Y1=function(w,n,W,D,j,I,U){eg.call(this);this.atl=n;this.Db=W;this.index=I;this.e=e.t("div","styleitem");
this.Oc=e.t("div","head");this.alm=null;if(n=="f"){var M=this.alm=e.t("div","headR");M.textContent="\u2699";
this.Oc.appendChild(M)}this.qt=e.t("div","eye gsicon");this.oh=e.t("div","label");this.e.appendChild(this.Oc);
this.Oc.appendChild(this.qt);if(U){this.l_=U;this.Oc.appendChild(U);this.Oc.setAttribute("style","height: "+(26/e.V()+10)+"px")}this.oh.innerHTML=w;
this.e.setAttribute("style","margin-left: "+(24+D*16+j*22)+"px");this.Oc.appendChild(this.oh);this.qt.addEventListener("click",this.aq3.bind(this),!1);
var m=this.e;m.setAttribute("draggable","true");m.addEventListener("dragstart",this.fe.bind(this),!1);
if(!0){m.addEventListener("drop",this.eo.bind(this),!1);m.addEventListener("dragover",this.kJ.bind(this),!1);
m.addEventListener("dragenter",e.oz,!1);m.addEventListener("dragleave",this.QS.bind(this),!1)}this.e.addEventListener("click",this.H5.bind(this),!1)};
c6.Y1.prototype=new eg;c6.Y1.prototype.fe=function(w){w.stopPropagation();w.dataTransfer.setData("Text",JSON.stringify({Y3:this.atl,RL:this.parent._r.index,cf:this.index}))};
c6.Y1.prototype.QS=function(w){e.oz(w);this.Ag()};c6.Y1.prototype.eo=function(w){e.oz(w);this.Ag();var n=w.dataTransfer.getData("Text");
if(n=="")return;var n=JSON.parse(n);ir.aq6(w,n,this.parent,this.index+(ir.KE(w,this.Oc)>.5?0:1))};c6.Y1.prototype.kJ=function(w){e.oz(w);
var n=ir.KE(w,this.Oc)>.5;this.Ag();var W="border-"+(n?"bottom":"top");this.Oc.style[W]="0.2em solid rgba(0,0,0,0.5)"};
c6.Y1.prototype.Ag=function(w){this.Oc.style.border="none"};c6.Y1.prototype.gb=function(w){this.qt.style.opacity=w?1:.2};
c6.Y1.prototype.H5=function(w){var n=ir.Ps,W=Date.now()-n<300;ir.Ps=Date.now();if(w.target==this.qt)return;
var D=this.parent._r.index;if(W&&this.Db!=null){var D=this.parent._r.index,j=new ed(b.E.L,!0);if(this.Db.indexOf("afw_")==0){var I=this.Db.slice(4),U=gu[I]||cx.a[I],M=w.target==this.alm;
if(!M&&!U)return;j.data=y.N$.atu(M?"blendOptions":I,{j:D,index:this.index})}else j.data={d:b.c.P2,jW:this.Db,j:D,index:this.index};
this.S(j)}else{if(w.target.className!="thumb")this.parent.f8({d:h.Gz,j:D,LM:0})}};c6.Y1.prototype.aq3=function(w){var n={fm:h.lf,f:h.GG,sm:h.Aj,s:h.oO}[this.atl];
this.parent.f8({d:n,j:this.parent._r.index,index:this.index})};function aC(){et.call(this,"Guide Guy",!1,"---panels/guideguy",et.ip.axH);
this.tI=null;this.ps=new i0(null,E.f_.Ph)}aC.prototype=new et("");aC.prototype.Wg=function(){this.a0=[];
var w=e.t("div","form padded");this.h_.appendChild(w);w.setAttribute("style","width:200px");this.h_.appendChild(w);
var n=e.t("canvas"),W=n.getContext("2d");n.width=n.height=160;var D=[32,0,16,160,0,32,160,16,0,112,160,16],j="Margin Left,Margin Top,Margin Right,Margin Bottom,Column Count,Row Count,Column Width,Row Height,Column Gap,Row Gap".split(","),I=[0,0,0,0,0,0,0,0,0,0];
w.appendChild(this.ps.e);for(var L=0;L<10;L++){W.clearRect(0,0,160,160);W.setTransform(1,0,0,1,80,80);
W.rotate((L&3)*Math.PI/2);W.translate(-80,-80);W.fillStyle="rgba(0,0,0,0.3)";if(L<4){for(var U=0;U<12;
U+=4){W.fillStyle=U==0?"#000000":"rgba(0,0,0,0.3)";W.fillRect(D[U],D[U+1],D[U+2],D[U+3])}}else if(L<6){var M=8*6;
W.fillRect(0,0,M,160);W.fillRect(8*7,0,M,160);W.fillStyle="#000000";W.fillRect(8*14,0,M,160)}else if(L<8){W.fillRect(0,0,16,160);
W.fillRect(160-16,0,16,160);W.fillRect(32,0,160-64,160);W.fillStyle="#000000";W.fillRect(32,80-8,160-64,8*1)}else{W.fillRect(0,0,8*7,160);
W.fillRect(8*13,0,160,160);W.fillStyle="#000000";W.fillRect(8*7,80-8,8*6,8*1)}var m="<img src=\""+n.toDataURL()+"\" class=\"autoscale gsicon\" /> ",l=new g_(m,0,200,null,L==4||L==5?0:2,null,null,4,j[L]);
l.parent=this;l.h(b.E.A,this.avV,this);l.$(I[L]);l.f();this.a0.push(l);w.appendChild(l.e)}var A=[[11,14],[11,15,0]];
this.uH=[];for(var L=0;L<A.length;L++){var g=new iP(A[L],!0,null,!0);this.uH.push(g);g.h("click",this.lE,this);
w.appendChild(g.e)}for(var L=0;L<6;L++){W.setTransform(1,0,0,1,80,80);W.rotate(Math.floor(L/3)*Math.PI/2);
W.translate(-80,-80);W.clearRect(0,0,160,160);W.fillStyle="rgba(0,0,0,0.3)";W.fillRect(0,0,160,160);
W.clearRect(16,16,128,128);W.fillStyle="#000000";var k=L%3;W.fillRect([0,9,18][k]*8,0,16,160);var m="<img src=\""+n.toDataURL()+"\" class=\"autoscale gsicon\" /> ",g=new iP(m,!1,null,!1);
this.uH.push(g);g.h("click",this.lE,this);w.appendChild(g.e)}};aC.prototype.f=function(){et.prototype.f.call(this);
this.ps.f();if(this.a0==null)return;for(var L=0;L<this.uH.length;L++)this.uH[L].f()};aC.prototype.avV=function(w){var n=this.a0,W=n.indexOf(w.target),D=Math.floor(W/2),j=W&1,I=[];
for(var L=0;L<4;L++)I.push(n[2*L+j].b());var U=-1;if(D==2&&I[2]!=0&&I[3]!=0&&I[4]!=0)U=4;if(D==3&&I[3]!=0&&I[2]!=0&&I[4]!=0)U=4;
if(D==4&&I[4]!=0&&I[2]!=0&&I[3]!=0)U=3;if(U!=-1)n[2*U+j].$(0)};aC.prototype.lE=function(w){var n=this.tI,W=this.uH.indexOf(w.target),D=[[],[]];
if(n==null)return;var j=n.J?n.J.rect:new iB(0,0,n.m,n.n),I=j.m,U=j.n;if(W==0){var M=[[],[]],m=this.ps.b();
for(var L=0;L<this.a0.length;L++){var l=this.a0[L].b();l=E.f_.M_(l,n.hh,n.m,m);M[L&1].push(l)}var A=[aC.ai0(M[0],j.x,j.x+I),aC.ai0(M[1],j.y,j.y+U)];
D=aC.LC(A);y.mU.w6(D,n.Iw())}else if(W==1){}else{W-=2;var g=Math.floor(W/3),A=[[],[]];A[g].push([j.x,j.x+I/2,j.x+I,j.y,j.y+U/2,j.y+U][W]);
D=aC.LC(A);y.mU.w6(D,n.Iw())}this.apC(D)};aC.LC=function(w){var n=[],W=[];for(var D=0;D<2;D++)for(var L=0;
L<w[D].length;L++){n.push([D,w[D][L]]);W.push(-1)}return[n,W]};aC.prototype.a7a=function(w){var n=this.a4E.indexOf(w.target)};
aC.prototype.apC=function(w){var n=new ed(b.E.v,!0);n.G=y.Rv;n.data={d:"gids",Qh:w};this.S(n)};aC.ai0=function(w,n,W){var D=[],j=w[2],I=w[3],U=w[4],M=0;
if(j==0)M++;if(I==0)M++;if(U==0)M++;if(M>1&&j==0&&I==0){if(w[0]!=0)D.push(n+w[0]);if(w[1]!=0)D.push(W-w[1]);
return D}var m=W-n-w[0]-w[1];if(j==0){if(U==0){j=Math.floor(m/I);U=(m-j*I)/(j-1)}else{j=1;while(I*j+U*(j-1)+I+U<=m)j++}}else if(j!=0&&I!=0){if(j*I>m)j=Math.floor(m/I);
U=(m-j*I)/(j-1)}D.push(n+w[0],W-w[1]);var I=(m-U*(j-1))/j;for(var L=1;L<j;L++){if(U==0)D.push(n+w[0]+L*I);
else D.push(n+w[0]+L*I+(L-1)*U,n+w[0]+L*I+L*U)}return D};aC.prototype.mQ=function(w,n,W){this.tI=w};
aC.prototype.c2=function(){if(e.LY(this.h_)&&this.a0==null)this.Wg();this.f()};aC.prototype.GZ=function(w){this.ps.$(w.M3.Lf)};
function eF(){et.call(this,[9,2],!1,"---panels/properties",et.ip.$z);this.an_=null;this.yV=null;this.ww=null;
this.apD=-1;this.sU=null}eF.prototype=new et("");eF.prototype.zl=function(w,n){this.gA=w;this.ag=n;w=w-16;
n=n-12;var W=this.sU;if(W){W.style.width=w+"px";W.style.height=n+"px";for(var L=0;L<3;L++)this.mW[L].zl(w-12,n)}};
eF.prototype.Wg=function(){this.sU=e.t("div","padded scrollable");this.h_.appendChild(this.sU);var w=e.t("span");
this.sU.appendChild(w);this.ai=[new iP([0,3]),new iP([12,73]),new iP([12,91,0])];for(var L=0;L<this.ai.length;
L++){var n=this.ai[L];n.h("click",this.afj,this);w.appendChild(n.e);if(L==2)n.e.style.marginRight="0"}this.sU.appendChild(e.t("hr"));
this.Ha=new eF.nh;this.Ha.parent=this;this.ir=new eF.U4;this.ir.parent=this;this.E_=new eF.Xk;this.E_.parent=this;
this.mW=[this.Ha,this.ir,this.E_];this.sU.appendChild(this.Ha.e);this.zl(this.gA,this.ag)};eF.prototype.afj=function(w){var L=this.ai.indexOf(w.currentTarget);
this.dw(L);this.ay$(L==1?this.ir.u6:-1)};eF.prototype.dw=function(w){for(var L=0;L<3;L++){this.ai[L].OD();
var n=this.mW[L].e;if(n.parentNode==this.sU&&L!=w)this.sU.removeChild(n);if(n.parentNode!=this.sU&&L==w)this.sU.appendChild(n)}this.ai[w].d3()};
eF.prototype.ay$=function(w){var n=this.yV.g[0],W=this.yV.C[n],D=w+1;if(w==1&&W.na)return;var j=new ed(b.E.v,!0);
j.G=y.Yu;if(w!=1&&W.na){j.data={d:h.Gz,j:n,LM:2};this.S(j)}j.data={d:h.Gz,j:n,LM:D};this.S(j)};eF.prototype.f=function(){et.prototype.f.call(this);
if(this.sU==null)return;this.mQ(this.yV);for(var L=0;L<3;L++){this.ai[L].f();this.mW[L].f()}};eF.prototype.c2=function(){if(!e.LY(this.h_))return;
if(this.sU==null){this.Wg();this.GZ(this.ww,bk.bI);this.mQ(this.an_);this.f()}};eF.prototype.mQ=function(w){this.an_=w;
if(this.sU==null)return;this.Ha.mQ(w);this.ir.mQ(w);this.E_.mQ(w);if(w==null||w.g.length==0||w.C[w.g[0]]==null){e.W0(this.h_,"disabled");
this.yV=null;return}else e.IX(this.h_,"disabled");var n=w.g[0],W=w.C[n],D=w.OV(),j=D[0],I=D[1];if(I.length!=0){var U=j[I[0]],M=U.add.vogk,m=!1;
if(M)for(var L=0;L<M.length;L++){var l=M[L].v;if(!E.X.OL(l))continue;m=!0;n=U.p_}}n+=","+m;if(w!=this.yV||this.apD!=n){this.yV=w;
this.apD=n;if(m)this.dw(2);else if(W.eL<1&&!W.na||eH.get(W.add))this.dw(0);else this.dw(1)}this.ai[1].G3(this.ir.u6!=-1);
this.ai[2].G3(m)};eF.prototype.GZ=function(w,n){this.ww=w;if(this.Ha)this.Ha.GZ(w,n);if(this.E_)this.E_.GZ(w,n)};
eF.nh=function(){eg.call(this);this.e=e.t("div","form");this.arq=new ga("Hello");this.M1=new iP([1,12,2],null,null,!0);
this.M1.e.style.a0r="right";this.M1.h("click",this.b0,this);this.e.appendChild(this.arq.e);this.e.appendChild(this.M1.e);
this.re=null;this.H_=null;this.yV=null;this.ww=null;this.ats=-1;this.a7s=null;this.fN=null;this.Hz=new d6(0,!0,!0);
this.Hz.parent=this;this.Hz.h(b.E.A,this.agy,this);this.e.appendChild(this.Hz.e);this.C5=new gM(!0);
this.C5.parent=this;this.C5.h(b.E.A,this.agm,this);this.Mx=e.t("div","marged hiline");this.Mx.appendChild(this.C5.e);
this.kf=new bF("GrFl",!0);this.kf.parent=this;this.kf.h(b.E.A,this.af0,this);this.GQ=e.t("div","marged hiline");
var w="Grad Rvrs Type Algn Angl Dthr Scl Ofst".split(" ");for(var L=0;L<w.length;L++){var n=this.kf.CL[w[L]].e;
this.GQ.appendChild(n)}this.Rr=new bF("patternFill",!0);this.Rr.parent=this;this.Rr.h(b.E.A,this.akP,this);
this.B$=e.t("div","marged hiline");var w=["Ptrn","Angl","Scl","Algn","phase"];for(var L=0;L<w.length;
L++){var n=this.Rr.CL[w[L]].e;this.B$.appendChild(n)}this.UI={};for(var W in eH.names){if(gu[W]==null)continue;
this.UI[W]=new gu[W];this.UI[W].h(b.E.A,this.arF,this);this.UI[W].parent=this}var D=this.aqi=e.t("div","marged hiline");
this.TZ=new d6(0,!0);D.appendChild(this.TZ.e);this.TZ.h(b.E.A,this.HG,this);this.arf=null;this.Dt=new b1;
this.Dt.parent=this;this.Dt.h(b.E.A,this.HG,this);D.appendChild(this.Dt.e)};eF.nh.prototype=new eg;eF.nh.prototype.agy=function(w){var n=this.Hz.b(),W=this.fN,D=new iB(n[0],n[1],n[2],n[3]);
if(D.s9(W))return;this.fN=D;var j=new ed(b.E.v,!0);if(W.m==D.m&&W.n==D.n){j.G=y.Rv;j.data={d:"trsl",Bi:D.x-W.x,ah:D.y-W.y}}else{j.G=y.Sv;
j.data={d:"scl",s7:[2,4],Z:new ec(D.m/W.m,D.n/W.n),Zl:0}}this.S(j)};eF.nh.prototype.zl=function(w,n){var W=this.UI;
for(var D in W)W[D].zl(w,n)};eF.nh.prototype.b0=function(w){var n=this.yV,W=n.C[n.g[0]],D=eH.get(W.add);
this.H_.$(cx._1(D));this.arF()};eF.nh.prototype.f=function(){for(var w in this.UI)this.UI[w].f();this.kf.f();
this.Rr.f();this.Dt.f();this.TZ.f();this.M1.f();this.Hz.f()};eF.nh.prototype.HG=function(w){var n=new ed(b.E.v,!0),W=this.TZ.b(),D=this.arf;
if(w.target==this.TZ&&W[2]==D[2]&&W[3]==D[3]){n.G=y.Rv;n.data={d:"trsl",Bi:W[0]-D[0],ah:W[1]-D[1]}}else{var j=h.B3(new iB(W[0],W[1],W[2],W[3])),I=this.Dt.am5();
I.artboardRect={t:"Objc",v:j};n.G=y.Yu;n.data={d:h.nL,oL:I}}this.S(n)};eF.nh.prototype.agm=function(w){var n=this.yV,W=n.g[0];
if(n.C[W].add.SoCo==null)return;var D=JSON.parse(JSON.stringify(n.C[W].add.SoCo));D.Clr.v=this.C5.b();
this.sG({oq:1,S8:D})};eF.nh.prototype.af0=function(w){var n=this.yV,W=n.g[0];if(n.C[W].add.GdFl==null)return;
this.sG({oq:2,S8:this.kf.b()})};eF.nh.prototype.akP=function(w){this.sG({oq:3,S8:this.Rr.b()})};eF.nh.prototype.sG=function(w){this.az8(y.Yu,{d:h.Q2,G1:[this.yV.g[0]],Mr:!0,Z:w})};
eF.nh.prototype.arF=function(w){this.az8(y.DW,{d:"edit_layer",Z:this.H_.b()})};eF.nh.prototype.az8=function(w,n){var W=new ed(b.E.v,!0);
W.G=w;W.data=n;this.S(W)};eF.nh.prototype.mQ=function(w,n){var W=fV.get([0,3]),D=!1,j=!1,I=null;this.yV=w;
if(w&&w.C.length>0&&w.g.length!=0&&w.C[w.g[0]]){var U=w.C[w.g[0]],M=eH.get(U.add);if(M!=null&&this.UI[M]!=null){I=this.UI[M].e;
this.H_=this.UI[M];this.UI[M].$(JSON.parse(JSON.stringify(U.add[M])));if(w.g[0]!=this.ats){var m=w.Vc(w.g[0]-1);
this.a7s=E.Bk(m)}this.UI[M].pH(this.a7s);W=fV.get(eH.names[M]);D=!0}if(M==null&&U.add.artb==null){var l=this.fN=E.p.fF(y.wR.pJ(w));
j=!l.VY();this.Hz.$([l.x,l.y,l.m,l.n],[w.hh,w.m,this.ww.M3.Lf])}if(U.add.SoCo){I=this.Mx;this.C5.$(U.add.SoCo.Clr.v);
W=fV.get([6,48,0,0])}if(U.add.GdFl){I=this.GQ;this.kf.update(w,U.add.GdFl);W=fV.get([6,48,0,1])}if(U.add.PtFl){I=this.B$;
this.Rr.update(w,U.add.PtFl);W=fV.get([6,48,0,2])}if(U.add.artb){var A=U.add.artb,g=U.yP();I=this.aqi;
this.Dt.a8H(A);var k=this.arf=[g.x,g.y,g.m,g.n];this.TZ.$(k,[w.hh,w.m,this.ww.M3.Lf]);W=fV.get([1,16,0])}this.ats=w.g[0]}if(I!=this.re){if(this.re)this.e.removeChild(this.re);
if(I!=null)this.e.appendChild(I);this.re=I}this.arq.$(W);this.M1.e.style.display=D?"":"none";this.Hz.e.style.display=j?"":"none"};
eF.nh.prototype.GZ=function(w,n){this.ww=w;this.kf.GZ(w,n);this.Rr.GZ(w,n);if(n==bk.OS)this.mQ(this.yV,w);
for(var W in this.UI)this.UI[W].GZ(w,n)};eF.U4=function(){eg.call(this);this.e=e.t("div","form");this.yV=null;
this.u6=0;var w=e.t("span","fitem");this.e.appendChild(w);this.ai=[new iP([6,2]),new iP([6,3]),new iP([6,50])];
for(var L=0;L<this.ai.length;L++){var n=this.ai[L];n.h("click",this.aeL,this);w.appendChild(n.e)}this.ij=new eu([12,74],0,255);
this.ij.h(b.E.A,this.bX,this);this.e.appendChild(this.ij.e);this.dK=new eu([7,6],0,500,"px",2,!0);this.dK.h(b.E.A,this.bX,this);
this.e.appendChild(this.dK.e);this.lA=new iP([4,11],null,null,!0);this.lA.h("click",this.apm,this)};
eF.U4.prototype=new eg;eF.U4.prototype.apm=function(){var w=new ed(b.E.v,!0);w.G=y.DW;w.data={d:"start",u4:"nvrt"};
this.S(w)};eF.U4.prototype.bX=function(w){var n=this.ij.b(),W=this.dK.b(),D=new ed(b.E.v,!0);D.G=y.Yu;
D.data={d:h.vE,hB:this.yV.g[0],KP:{le:this.u6,ij:n,dK:W}};this.S(D)};eF.U4.prototype.f=function(){for(var L=0;
L<this.ai.length;L++)this.ai[L].f();this.ij.f();this.dK.f();this.lA.f()};eF.U4.prototype.mQ=function(w){this.yV=w;
this.w$()};eF.U4.prototype.aeL=function(w){this.w$(this.ai.indexOf(w.currentTarget));this.parent.ay$(this.u6)};
eF.U4.prototype.w$=function(w){var n=this.yV,W=this.ai;for(var L=0;L<3;L++){var D=W[L];D.OD();D.rx()}if(n==null||n.C.length==0||n.g.length==0||n.C[n.g[0]]==null)return;
var j=-1,I=n.C[n.g[0]];if(I.YC()&&I.NP(n).z!=null){W[2].Te();j=2}if(I.add.vmsk){W[1].Te();j=1}if(I._N()){W[0].Te();
j=0}if(w!=null)j=w;else if(I.na)j=1;else if(I.eL==3)j=2;else if(I.eL==1)j=0;this.u6=j;if(j==-1){this.ij.rx();
this.dK.rx();return}var U=I.c3(j);this.ij.Te();this.dK.Te();this.ij.$(U.ij);this.dK.$(U.dK);W[j].d3();
var M=this.lA.e;if(j==0)this.e.appendChild(M);else if(M.parentNode==this.e)this.e.removeChild(M)};eF.Xk=function(){eg.call(this);
this.e=e.t("div","form");this.tI=null;this.ww=null;this.jf=-1;this.Hz=new d6(0,!1);this.aB=new eu([12,15],-180,180,"\xB0",2);
this.lQ=new d6(1,!0);this.bM=new eu([12,94,0],0,100,null,2);this.Oo=new eu([12,78],3,30);this.Tb=new iP(["\u279C ",[12,76,0]],null,null,!0);
this.Hz.h(b.E.A,this.aI,this);this.aB.h(b.E.A,this.aI,this);this.lQ.h(b.E.A,this.aI,this);this.bM.h(b.E.A,this.aI,this);
this.Oo.h(b.E.A,this.aI,this);this.Tb.h("click",this.aI,this)};eF.Xk.prototype=new eg;eF.Xk.prototype.f=function(){this.Hz.f();
this.aB.f();this.lQ.f();this.bM.f();this.Oo.f()};eF.Xk.prototype.aI=function(w){var n=this.tI,W=E.X.kN(n),D=w.target.b(),j=[this.Hz,this.aB,this.lQ,this.bM,this.Oo,this.Tb].indexOf(w.target);
if(j==0){var I=[];I[0]=D[0];I[1]=D[1];I[2]=I[0]+D[2];I[3]=I[1]+D[3];D=I}if(j==1)D=D*Math.PI/180;var U={0:1,1:2,2:3,3:3,4:4}[j];
W[U]=D;var M=new ed(b.E.v,!0);M.G=y.Yu;M.data={d:h.Di,Z:W,ar_:j==5};this.S(M)};eF.Xk.prototype.mQ=function(w){var n=this.e;
this.tI=w;if(w==null)return;var W=this.ww,D=[w.hh,w.m,W.M3.Lf],j=E.X.kN(w),I=j[0],U=j[1];if(U==null)return;
var M=I!=this.jf;this.jf=I;if(M)e._g(n);if(M)n.appendChild(this.Hz.e);if(M)n.appendChild(this.aB.e);
this.Hz.$([U[0],U[1],U[2]-U[0],U[3]-U[1]],D);this.aB.$(j[2]*180/Math.PI);if(I==2){if(M)n.appendChild(this.lQ.e);
var m=j[3];this.lQ.$(m,D)}if(I==7||I==8){if(M)n.appendChild(this.bM.e);this.bM.$(j[3])}if(I==8){if(M)n.appendChild(this.Oo.e);
this.Oo.$(j[4])}n.appendChild(this.Tb.e)};eF.Xk.prototype.GZ=function(w,n){this.ww=w;this.mQ(this.tI)};
function cP(w){et.call(this,w.name,!0);this.On=w;this.Yo=null;this.G5=new c8(this.h_);this.G5.parent=this}cP.prototype=new et;
cP.pD=function(){var w=document.createElement("canvas"),n=document.createElement("canvas"),W=16,D=E.Q(16*16*4);
E.b6(D,W,W,8);var j=E.scale.GP(D,W,W);return{CJ:w,Vv:n,xq:w.getContext("2d",{willReadFrequently:!0}),W9:n.getContext("2d"),Vz:j}}();
cP.prototype.ajP=function(){if(this.On.VO())return window.confirm(fV.get([22,6,3])+" "+this.On.name+". "+fV.get([22,6,4]));
return!0};cP.prototype.GZ=function(w,n){this.Yo=w};cP.prototype.mQ=function(w){this.c2();this.Uc()};
cP.prototype.zl=function(w,n){if(w<=0||n<=0)return;this.gA=w;this.ag=n;var W=this.On,D=cP.pD,j=e.V();
W.u.xq.m=Math.floor(w*j);W.u.xq.n=Math.floor(n*j);e.dz(D.CJ,w,n);e.dz(D.Vv,w,n);e.dz(je.Om(),w,n);if(W.u.N==0)W.u.N=y.Jd.ajJ(W.m,W.n,w*j,n*j);
this.Uc()};cP.prototype.c2=function(){var w=this.h_.firstChild,n=cP.pD,W=je.YG&&this.On.add.fvec==null;
if(!W&&w==je.Om()||W&&w==n.CJ)this.h_.removeChild(w);var D=W?je.Om():n.CJ;if(!e.LY(D))this.h_.appendChild(D)};
cP.prototype.Uc=function(){if(this.Yo==null)return;var w=this.On,n=je.YG&&this.On.add.fvec==null;if(n)this.aw0();
else this.fD()};cP.prototype.aw0=function(){if(je.YG&&cP.Ge==null){var w=cP.Ge=[],n=[0,2,8,32,128];for(var L=0;
L<5;L++)w[L]=[new cP.Vh(!1,n[L],!1),new cP.Vh(!0,n[L],!1)];w.push([new cP.Vh(!1,0,!0),new cP.Vh(!0,0,!0)])}var W=this.On,D=cP.pD,g,C=0,P,Z;
if(W.jw==null)return;var j=W.u,I=j.xq.m,U=j.xq.n,M=je.VE;D.xq.clearRect(0,0,I,U);var m=this.a7F(W);if(j.x4==null||j.x4.m!=I||j.x4.n!=U)j.x4=new je.H0(I,U);
if(m){var l=new Uint8Array(D.xq.getImageData(0,0,I,U).data.buffer);j.x4.set(l)}else{je.t5(j.x4);je.oT(1)}var A=j.m9(0,0);
if(cP.a9N==null)cP.a9N=new Float32Array(4*1024);var k=[0,0,0,0],$=cP.a9N;if(W.add.artd){$.fill(0);k=cP.vk(W);
var f=W.m,z=W.n,X=0;for(var L=0;L<W.C.length;L++){var s=W.C[L],O=s.add.artb;if(O==null||!s.I4())continue;
var a=s.yP();$[C]=a.x/f;$[C+1]=a.y/z;$[C+2]=a.m/f;$[C+3]=a.n/z;C+=4;if(C==$.length)break}if(C>2*4)X++;
if(C>8*4)X++;if(C>32*4)X++;g=cP.Ge[X+1];$=new Float32Array($.buffer,0,[2,8,32,128][X]*4)}else g=cP.Ge[W.v_?5:0];
var Y=W.Xf();if(Y==null)g=g[0];else{g=g[1];Z=Y[W.add.fcmy==1?6:4];P=Y[2]}je.GU(I,U);je.oT(0);je.GU(I,U);
g.FO();var K=new eh;K.scale(I,U);K.concat(j.Pv(!0));K.scale(1/W.m,1/W.n);var S=[K.dl,K.k,0,K.Cj,K.j7,0,K.z2,K.EU,1];
g.xC(j.x4.LJ,W.jw.LJ,new Float32Array(S),new Float32Array([I/8,U/8,A.x/I,A.y/U]),W.m,W.n,1/W.u.N,I,U,new Float32Array(k),$,new Float32Array(E.Mv.nJ(E.Mv.oN(j.zC))),Z,P);
M.drawArrays(M.TRIANGLES,0,6)};cP.vk=function(w){return[0,0,0,0]};cP.aij=function(w){var n=E.M.y_(w.v),W=[n.o/255,n.B/255,n.k/255,1];
for(var L=0;L<4;L++)W[L]=Math.min(1,W[L]);return W};cP.vJ=function(w,n){var W=w[2]*255;if(je.YG)W=n?0:Math.max(2,W);
return"rgba("+w[0]*255+","+w[1]*255+","+W+","+w[3]+")"};cP.Zn=function(w){var n=w.length;if(je.YG)for(var L=0;
L<n;L+=4){if(w[L+2]==0)w[L+2]=3}};cP.prototype.fD=function(){var w=this.On,n=cP.pD;if(w.buffer==null)return;
var W=w.u,D=W.xq,j=D.m,I=D.n,U=new iB(0,0,w.m,w.n);n.W9.clearRect(0,0,j,I);n.xq.clearRect(0,0,j,I);var M=W.Pv(!0),m=M.clone();
m.Ba();if(w.add.artd==null){n.xq.save();var l=m.bj(new ec(0,0));m.translate(-l.x,-l.y);n.xq.translate(Math.round(l.x),Math.round(l.y));
n.xq.fillStyle=n.Vz;if(w.v_)n.xq.fillRect(-5e3,-5e3,2e4,2e4);else{this.DV(E.p.Wx(U),m,n.xq);n.xq.fill()}n.xq.restore()}else{n.xq.fillStyle=cP.vJ(cP.vk(w));
n.xq.fillRect(0,0,j,I);n.xq.save();n.xq.setTransform(m.dl,m.k,m.Cj,m.j7,m.z2,m.EU);var A=w.root.children;
for(var L=0;L<A.length;L++){var g=A[L].j;if(g.add.artb==null||!g.I4())continue;var k=g.yP(),$=g.L9();
if($!=0)continue;n.xq.fillStyle=n.Vz;n.xq.save();n.xq.scale(1/W.N,1/W.N);n.xq.fillRect(W.N*k.x,W.N*k.y,k.m*W.N,k.n*W.N);
n.xq.restore()}n.xq.restore()}if(W.Fl.length!=D.O()){W.Fl=E.Q(D.O());W.Ud=E.Q(D.O()*4)}W.Ud.fill(0);
if(w.add.fvec){var m=W.Pv(!0);m.Ba();n.xq.save();var C=E.p.Wx(W.xq);E.p.D(C.w,W.Pv(!0),C.w);var f=E.p.lV(C.w);
n.xq.setTransform(m.dl,m.k,m.Cj,m.j7,m.z2,m.EU);this.DV(E.p.Wx(new iB(0,0,w.m,w.n)),null,n.xq);n.xq.clip();
w.root.awr(w,n.xq,this.Yo,f);n.xq.restore()}else{E.scale.uq(w.buffer,U,M,W.Ud,D,w.v_);var z=w.Xf();if(z)ICC.U.applyLUT(z[w.add.fcmy==1?5:3],z[2],W.Ud,W.Ud);
if(W.zC[0]+W.zC[1]+W.zC[2]!=3)E.Mv.V9(W.Ud,W.Ud,E.Mv.oN(W.zC));n.W9.putImageData(new ImageData(new Uint8ClampedArray(W.Ud.buffer),D.m,D.n),0,0);
n.xq.drawImage(n.Vv,0,0);n.xq.getImageData(0,0,1,1)}this.a7F(w)};cP.prototype.a7F=function(w){var n=w.u,W=n.zC[0]+n.zC[1]+n.zC[2],D=cP.pD,j=!1,I=[];
for(var L=0;L<w.g.length;L++){var U=w.C[w.g[L]];if(U==null)continue;var M=U.eL;if(M!=1&&M!=3)continue;
var m=M==1?U._N():U.NP(w).z;if(m.$P)I.push(m)}for(var L=0;L<w.yo.length;L++)if(w.yo[L].$P)I.push(w.yo[L]);
for(var L=0;L<I.length;L++){var m=I[L];this.afG(m,n,I.length==1&&W==0?2:1,m.color,m.pL);j=!0}var l=this.Yo;
j=this.avJ(w,D.xq,n,I.length!=0)||j;if(w.J&&l.Ar&&l.M3.zc){this.afG(w.J,n,0,0,null);j=!0}return j};cP.prototype.afG=function(w,n,W,D,j){var I=0;
if(j)I=Math.round(j.k)<<16|Math.round(j.B)<<8|Math.round(j.o);var U=n.Pv(!0),M=n.xq,m=new iB(0,0,n.On.m,n.On.n),l=cP.pD;
if(n.Ud==null||n.Ud.length!=M.O()*4){n.Fl=E.Q(M.O());n.Ud=E.Q(M.O()*4)}n.Fl.fill(D);n.Ud.fill(0);var A=w.channel,g=w.rect;
E.scale.D(A,g,U,n.Fl,M);if(W==0){var k=new Uint32Array([4278190080,4294967295]);cP.Zn(new Uint8Array(k.buffer));
E.J.anb(n.Fl,n.Ud,M,k,e.V()>1.9)}else{var $=Date.now();E.J.awn(n.Fl,n.Ud,M,W,I);cP.Zn(n.Ud)}var C=new ImageData(new Uint8ClampedArray(n.Ud.buffer),M.m,M.n);
l.W9.putImageData(C,0,0);l.xq.save();if(W!=0){var f=new iB(0,0,m.m,m.n),z=U.clone();z.Ba();this.DV(E.p.Wx(f),z,l.xq);
l.xq.clip()}l.xq.drawImage(l.Vv,0,0);l.xq.restore()};cP.prototype.avJ=function(w,n,W,D){var j=w.I.Im!=null||w.I.VZ!=null||w.I.t7!=null||w.I.pb.length!=0||w.I.r7.length!=0,I=this.Yo,U=I.M3,M=hp.fX[I.SI],m=Math.round(12*e.V()),l=m/w.u.N,g=W.Pv(!0);
g.Ba();n.save();n.setTransform(g.dl,g.k,g.Cj,g.j7,g.z2,g.EU);if(w.add.artd){var k=cP.vk(w)[0];k=k<.5?k+.5:k-.5;
k=""+Math.round(k*255).toString(16);while(k.length<2)k="0"+k;n.fillStyle="#"+k+k+k;n.font=l+"px sans-serif";
for(var L=0;L<w.C.length;L++){var $=w.C[L];if($.add.artb==null||!$.I4())continue;var C=$.yP();n.fillText($.getName(),C.x+2,C.y-l*.7);
j=!0}}function f(gr){return gr==1||gr==2||gr==4||gr==5}var z=cP.vJ([.1,.5,1,1]),s=cP.vJ([1,1,1,1]);if(I.Ar&&U.Oi){n.fillStyle=n.strokeStyle=z;
n.lineWidth=1.5/W.N;var O=w.OV(),a=O[0],X=O[1];for(var P=0;P<X.length;P++){var $=a[X[P]],Z=$.add.vmsk,Y=Z.i,K=E.p.xH(Y);
this.DV(K,null,n);n.stroke();j=!0;var S=3*e.V()/W.N,G=Y.length-3;for(var L=0;L<Z.H3.length;L++){var V=E.P.QZ(Y,Z.H3[L]);
if(V==null)continue;var T=V.x,R=V.y;n.beginPath();var x=L==0;if(Z.Ty)x=!x;if(x){n.moveTo(T-S,R-S);n.lineTo(T+S,R+S);
n.moveTo(T-S,R+S);n.lineTo(T+S,R-S);n.stroke()}else{n.arc(T,R,S*1,0,2*Math.PI);n.fill()}j=!0}if(w.g.length!=1)continue;
var v=-1;for(var L=0;L<Y.length;L++){if(Y[L].type>5)continue;if(Y[L].type==0||Y[L].type==3){if(Y[L].Ht!=-1)v++;
continue}if(Z.g.indexOf(v)!=-1){var T=Y[L].H.x,R=Y[L].H.y;n.fillRect(T-S*.8,R-S*.8,2*S*.8,2*S*.8)}if(Z.Rw.indexOf(L)!=-1){var N=Y[L],u=[N.H];
n.beginPath();n.moveTo(N.T7.x,N.T7.y);n.lineTo(N.H.x,N.H.y);n.lineTo(N.mO.x,N.mO.y);var H=Y[L-1],F=Y[L+1];
if(H&&f(H.type)&&Z.Rw.indexOf(L-1)==-1){n.moveTo(H.H.x,H.H.y);n.lineTo(H.mO.x,H.mO.y);u.push(H.mO)}if(F&&f(F.type)&&Z.Rw.indexOf(L+1)==-1){n.moveTo(F.H.x,F.H.y);
n.lineTo(F.T7.x,F.T7.y);u.push(F.T7)}n.stroke();if(!N.H.s9(N.T7))u.push(N.T7);if(!N.H.s9(N.mO))u.push(N.mO);
for(var t=0;t<u.length;t++){var V=u[t],T=V.x,R=V.y;if(t==0&&(N.type==2||N.type==5))n.fillRect(T-1.2*S,R-1.2*S,2.4*S,2.4*S);
else{n.beginPath();n.arc(T,R,S*1.2,0,2*Math.PI);n.fill();if(t!=0)n.fillStyle=s;n.beginPath();n.arc(T,R,S*.8,0,2*Math.PI);
n.fill();n.fillStyle=z}}}j=!0}}}n.lineWidth=1/W.N;if(w.I.JF){n.fillStyle=n.strokeStyle=z;var F={w:[],F:[]},o=cP.a7W;
if(o==null){o=cP.a7W={w:[1,0],F:["M"]};for(var L=1;L<30;L++){var q=Math.PI*2*L/30;o.w.push(Math.cos(q),Math.sin(q));
o.F.push("L")}o.F.push("Z","M","L","M","L");o.w.push(-.5,0,.5,0,0,-.5,0,.5)}for(var L=0;L<w.I.JF.length;
L++){var H=y.s2.akK(w.I.JF[L],W),_=new eh(H[0],0,0,H[0],H[1],H[2]);E.p.concat(F,o,_)}this.DV(F,null,n);
n.stroke();j=!0}var d=new eh(1,0,0,1,.5/W.N,.5/W.N);if(w.v_){n.fillStyle=n.strokeStyle=z;var F={w:[0,0,w.m,0,w.m,w.n,0,w.n],F:["M","L","L","L","Z"]};
this.DV(F,d,n);n.stroke();j=!0}if(w.I.oP){n.fillStyle=n.strokeStyle=cP.vJ([0,0,0,.5]);this.DV(w.I.oP,null,n,!0);
n.fill("evenodd")}n.fillStyle=n.strokeStyle=cP.vJ([0,0,0,je.YG&&w.add.fvec==null?1:.5],!0);if(w.I.Im){this.DV(w.I.Im,null,n);
n.fill()}if(w.I.VZ){this.DV(w.I.VZ,d,n);n.stroke()}for(var r in w.I.hF)if(w.I.hF[r].VZ){this.DV(w.I.hF[r].VZ,null,n);
n.stroke();j=!0}var p=cP.a5B(w.I.cc,n,W);n.stroke();j=j||p;var Q=w.I.r4;n.fillStyle=cP.vJ([1,1,1,1]);
n.beginPath();var S=6*e.V()/W.N;for(var L=0;L<Q.length;L+=2){j=!0;var T=Q[L],R=Q[L+1];n.moveTo(T+S,R);
n.arc(T,R,S,0,2*Math.PI)}n.fill();var S=4*e.V()/W.N;for(var L=0;L<Q.length;L+=2){j=!0;var T=Q[L],R=Q[L+1];
n.fillStyle=cP.vJ(w.I.hA.indexOf(L>>>1)!=-1?[0,.6,1,1]:[.7,.7,.7,1]);n.beginPath();n.moveTo(T+S,R);n.arc(T,R,S,0,2*Math.PI);
n.fill()}if(w.I.pb.length!=0){for(var L=0;L<w.I.pb.length;L++){var B=w.I.pb[L],i=B[1],c;if(D){c=n.getImageData(i.x,i.y,i.m,i.n);
E.s._U("norm",B[0],i,new Uint8Array(c.data.buffer),i,i,1)}else c=new ImageData(new Uint8ClampedArray(B[0].buffer),i.m,i.n);
n.putImageData(c,i.x,i.y)}}var h2=.5/W.N;n.lineWidth=1/W.N;if(w.I.TH){j=!0;var jX=w.I.TH,bm=jX.eF,K={F:[],w:[]};
for(var L=0;L<jX.yi.length;L++)E.p.concat(K,E.p.Wx(jX.yi[L]));K.w=K.w.concat(bm);for(var L=0;L<bm.length;
L+=4){K.F.push("M","L")}for(var L=0;L<K.w.length;L++){K.w[L]+=h2}n.strokeStyle=cP.vJ([.9,.2,.2,1]);this.DV(K,null,n);
n.stroke();var dC=e.V(),fn=2/W.N;n.font=l*.9+"px sans-serif";for(var L=0;L<bm.length;L+=4){var T=bm[L],R=bm[L+1],fK=bm[L+2],i6=bm[L+3],dh=Math.sqrt((i6-R)*(i6-R)+(fK-T)*(fK-T));
dh=E.f_.BE(dh,w.hh,I,R==i6?w.m:w.n);var kA=new ec((T+fK)/2,(R+i6)/2);n.fillStyle=cP.vJ([.9,.2,.2,1]);
var ig=n.measureText(dh).width;n.fillRect(kA.x-ig/2-fn*dC,kA.y-3.5*fn*dC,ig+2*fn*dC,7*fn*dC);n.fillStyle=cP.vJ([1,1,1,1]);
n.save();n.translate(kA.x-ig/2,kA.y+2*fn*dC);n.scale(.1,.1);n.font=l*9+"px sans-serif";n.fillText(dh,0,0);
n.restore()}}if(I.Ar){if(U.E4&&w.u.N>10&&w.add.fvec==null){this.b6(w,n,1,1,.25,U.df,16777215);j=!0}if(U.Vk){var iJ=E.f_.M_(U.Jt,w.hh,w.m,U.Cp),fL=iJ;
if(U.Cp==4)fL*=w.n/w.m;this.b6(w,n,iJ,fL,1,U.df,U._S);j=!0}if(U.jg){var fB=w.Iw(),ah=w.H2(),eS=Math.max(w.u.xq.m,w.u.xq.n)/w.u.N;
eS=Math.max(Math.max(w.m,w.n)*2,eS);for(var L=0;L<fB[0].length;L++){var gL=fB[0][L],e_=fB[1][L];if(e_!=-1&&e_!=ah)continue;
var c2=W.m9(gL[1],gL[1]),jS=W.Cg(Math.floor(c2.x)+.5,Math.floor(c2.y)+.5);n.beginPath();n.strokeStyle=cP.vJ([0,e_==-1?1:.5,1,1]);
if(gL[0]==0){var ie=jS.x;n.moveTo(ie,-eS);n.lineTo(ie,eS)}else{var as=jS.x;n.moveTo(-eS,as);n.lineTo(eS,as)}n.stroke();
j=!0}}var gb=w.ej;if(U.ej&&gb.length!=0){n.font=l*.8+"px sans-serif";var gx=[],eo=[];for(var L=0;L<gb.length;
L++){var di=y.mk.uw(gb,L);gx.push(di);if(w.UF.indexOf(L)!=-1)eo.push(di)}gx.reverse();var d0=Date.now();
gx=E.rect.V0([0,0,w.m,w.n],gx);for(var t=0;t<2;t++)for(var L=0;L<gx.length;L++){var e6=gx[L],v=e6[4],dt=v!=null?gb[v]:null;
if(dt&&t==0||dt==null&&t==1)continue;var T=Math.round(e6[0]),R=Math.round(e6[1]),fK=Math.round(e6[2]),i6=Math.round(e6[3]);
n.strokeStyle=n.fillStyle=cP.vJ(dt?[0,.7,.7,1]:[.8,.8,.8,1]);n.strokeRect(T+h2,R+h2,fK-T,i6-R);var gJ=L+1,iW=n.measureText(gJ),ig=iW.width;
n.fillRect(T,R,ig+l/2,l);n.fillStyle=cP.vJ([1,1,1,1]);n.fillText(gJ,T+l/4,R+l*.8)}var fn=2/w.u.N,g5=2*fn;
for(var L=0;L<eo.length;L++){var e6=eo[L],T=Math.round(e6[0]),R=Math.round(e6[1]),fK=Math.round(e6[2]),i6=Math.round(e6[3]);
n.strokeStyle=n.fillStyle=cP.vJ([1,.6,0,1]);n.strokeRect(T+h2,R+h2,fK-T,i6-R);var jW=[T,R,fK,R,fK,i6,T,i6];
for(var eP=0;eP<jW.length;eP+=2){var ie=jW[eP],as=jW[eP+1],b_=jW[eP+2&7],fZ=jW[eP+3&7];n.fillRect(ie-fn,as-fn,g5,g5);
n.fillRect(Math.round((ie+b_)/2)-fn,Math.round((as+fZ)/2)-fn,g5,g5)}}j=!0}var im=w.add.Anno;if(im&&im.length!=0)for(var L=0;
L<im.length;L++){var j3=im[L],dr=j3[2],ie=j3[0]-h2,as=j3[1]-h2,g5=30/W.fd,c0=.4*g5,fM=.6*g5;n.beginPath();
n.moveTo(ie,as+fM);n.lineTo(ie,as);n.lineTo(ie+g5,as);n.lineTo(ie+g5,as+g5);n.lineTo(ie+c0,as+g5);n.closePath();
n.lineTo(ie+c0,as+fM);n.lineTo(ie+c0,as+g5);if(L==w.u.PM){n.lineWidth*=5;n.strokeStyle=cP.vJ([0,0,0,.5]);
n.stroke();n.lineWidth/=5}n.fillStyle=cP.vJ([dr.o/255,dr.B/255,dr.k/255,1]);n.fill();n.strokeStyle=cP.vJ([0,0,0,1]);
n.stroke()}}n.strokeStyle=cP.vJ([1,0,0,1]);if(w.I.t7){this.DV(w.I.t7,d,n);n.stroke()}n.restore();if(I.fM){if(w.u.eJ==null||w.u.eJ.width!=w.u.xq.m||w.u.Ie.height!=w.u.xq.n){w.u.eJ=n.createImageData(w.u.xq.m,E.f_.Nf);
w.u.Ie=n.createImageData(E.f_.Nf,w.u.xq.n)}var M=hp.fX[I.SI],cB=0,iI=0,jD=w.m,j8=w.n;if(w.H2()!=-1){var C=w.C[w.H2()].yP();
cB=C.x;iI=C.y;jD=C.m;j8=C.n}cB*=W.N;iI*=W.N;var W=w.u,jG=[1,w.hh,w.hh/2.54,w.hh/25.4,jD/100][U.Lf],i1=W.N*w.m/2,bH=W.N*w.n/2,a_=[W.N*jG,new ec(W.R.x+(cB+i1*jG-i1),W.R.y+(iI+bH*jG-bH))];
if(U.Lf==4)jG*=j8/jD;var aR=[W.N*jG,new ec(W.R.x+(cB+i1*jG-i1),W.R.y+(iI+bH*jG-bH))],iY=this.G5.gC;E.f_.a6O(W,M["--text-color"],M["--bg-input"],Math.floor(iY.x),Math.floor(iY.y),a_,aR);
var gy=hL.akA(W.N,cP.vJ([1,1,1,1]),w.m,w.n);cP.Zn(w.u.Ie.data);cP.Zn(w.u.eJ.data);n.putImageData(w.u.Ie,0,0);
n.putImageData(w.u.eJ,0,0);n.putImageData(gy,0,w.u.xq.n-gy.height)}if(w.I.r7.length!=0){for(var L=0;
L<w.I.r7.length;L++){var B=w.I.r7[L],i=B[1];n.putImageData(new ImageData(new Uint8ClampedArray(B[0].buffer),i.m,i.n),i.x,i.y)}}return j||I.fM};
cP.prototype.b6=function(w,n,W,D,j,I,U){while(W*w.u.N<4){W*=2;D*=2}var M=w.m,m=w.n,l=.5/w.u.N;U=E.uv(U);
n.strokeStyle=cP.vJ([U.o/255,U.B/255,U.k/255,j],!1);n.save();n.rect(0,0,M,m);n.clip();n.beginPath();
for(var A=0;A<=M;A+=W){n.moveTo(A+l,0);n.lineTo(A+l,m)}if(I==0){for(var g=0;g<=m;g+=D){n.moveTo(0,g+l);
n.lineTo(M,g+l)}}else{D*=Math.sqrt(4/3);var k=D*Math.floor(M/D),$=M*(D/(2*W));for(var g=-k;g<=m+k;g+=D){n.moveTo(0,g);
n.lineTo(M,g-$);n.moveTo(0,g);n.lineTo(M,g+$)}}n.stroke();n.restore()};cP.a5B=function(w,n,W,D){n.beginPath();
var j=(D?D:1)*(4*e.V()+.5)/W.N,I=!1;for(var L=0;L<w.length;L+=2){I=!0;var U=w[L],M=w[L+1];n.rect(U-j,M-j,2*j,2*j)}return I};
cP.ru=function(w,n,W,D){W.beginPath();if(D)W.rect(-1e5,-1e5,1e6,1e6);var j=w;if(n){j=E.p.clone(w);E.p.D(j.w,n,j.w)}Typr.U.pathToContext({cmds:j.F,crds:j.w},W)};
cP.prototype.DV=cP.ru;cP.Vh=function(w,n,W){je.in.call(this);var D=n!=0,j=W?"true":"in01(sCoord)",I="\t\t\tprecision mediump float;\t\t\t\t\t\tuniform sampler2D source;\t\t\tuniform sampler2D target;\t\t\t"+(w?"uniform sampler2D lut; uniform float N; "+je.SW.tC:"")+"\t\t\tuniform vec3 contSizeZoom;\t\t\tuniform vec2 cnvSize;\t\t\tuniform mat4 ctrn; \t\t\t"+(D?"uniform vec4 bgClr; uniform vec4 ars["+n+"]; ":"")+"\t\t\t\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\tvarying vec2 gCoord;\t\t\t\t\t\t/* This approximates the error function, needed for the gaussian integral */ \t\t\tvec4 erf(vec4 x) { \t\t\t vec4 s = sign(x), a = abs(x);\t\t\t x = 1.0 + (0.278393 + (0.230389 + 0.078108 * (a * a)) * a) * a;\t\t\t x *= x; \t\t\t return s - s / (x * x); \t\t\t} \t\t\t/* Return the mask for the shadow of a box from lower to upper */ \t\t\tfloat boxShadow(vec2 lower, vec2 upper, vec2 point, float sigma) { \t\t\t vec4 query = vec4(point - lower, point-upper); \t\t\t vec4 integral = 0.5 + 0.5 * erf(query * (sqrt(0.5) / sigma)); \t\t\t return (integral.z - integral.x) * (integral.w - integral.y); \t\t\t} \t\t\t\t\t\tvec4 simpleBlend(vec4 src, vec4 tgt) {\t\t\t\tfloat na = src.w + tgt.w*(1.0-src.w);\t\t\t\t/* avoid division by zero */ \t\t\t\treturn na==0.0 ? vec4(0,0,0,0) : vec4( (src.xyz*src.w + tgt.w*tgt.xyz*(1.0-src.w))*(1.0/na), na);\t\t\t} \t\t\t\t\t\t"+je.SW.v1+"\t\t\t\t\t\tvoid main(void) {\t\t\t\tvec4 src = texture2D(source, tCoord); \t\t\t\tvec4 tgt = texture2D(target, sCoord"+(W?"-floor(sCoord)":"")+"); \t\t\t\t"+(w?"tgt.rgb = mapLut(tgt, lut, N).rgb; ":"")+"\t\t\t\ttgt = ctrn * tgt; "+(D?"\t\t\t\t\tbool inr = false; vec4 BG = bgClr; \t\t\t\t\tfor(int i=0; i<"+n+"; i++) { \t\t\t\t\t\tvec4 ar = ars[i]; \t\t\t\t\t\tvec2 nsc = sCoord - ar.xy; \t\t\t\t\t\tif( ar.z!=0.0 && in01(nsc/ar.zw) ){\t\t\t\t\t\tinr=true; BG=mod(floor(gCoord.x) + floor(gCoord.y), 2.0)==1.0 ? vec4(0.784,0.784,0.784,1) : vec4(1,1,1,1); }\t\t\t\t\t}\t\t\t\t":"\t\t\t\t\tfloat shdw = 0.3*boxShadow(vec2(0,0),contSizeZoom.xy, sCoord*contSizeZoom.xy+vec2(0.0,-6.0*contSizeZoom.z) , 10.0*contSizeZoom.z);\t\t\t\t\tvec4 grid = mod(floor(gCoord.x) + floor(gCoord.y), 2.0)==1.0 ? vec4(0.784,0.784,0.784,1) : vec4(1,1,1,1);\t\t\t\t\tvec4 BG = "+j+" ? grid : vec4(0.0,0.0,0.0,shdw); \t\t\t\t")+"\t\t\t\tvec4 outc = "+j+" ? simpleBlend(tgt,BG) : BG ; \t\t\t\tif(src.b == 0.0 && src.a >0.5) gl_FragColor = mix(outc, vec4(vec3(1,1,1)-outc.rgb,1.0), src.w); \t\t\t\telse gl_FragColor = simpleBlend(src,outc); \t\t\t\t\t\t\t}",U="\t\t\tattribute vec2 verPos;\t\t\tvarying vec2 tCoord;\t\t\tvarying vec2 sCoord;\t\t\tvarying vec2 gCoord;\t\t\t\t\t\tuniform mat3 tmat;\t\t\tuniform vec4 gsize;\t\t\tvoid main(void) {\t\t\t\ttCoord = verPos;\t\t\t\tsCoord = (tmat*vec3(verPos,1.0)).xy;\t\t\t\tgCoord = (verPos-gsize.zw) * gsize.xy ; \t\t\t\tgl_Position = vec4(vec2(-1.0, 1.0) + 2.0*vec2(verPos.x,-verPos.y), 0.0, 1.0);\t\t\t}";
this.sk(I,U)};cP.Vh.prototype=new je.in;cP.Vh.prototype.xC=function(w,n,W,D,j,I,U,M,m,l,A,g,k,$){this.f2("tmat gsize source target lut N contSizeZoom cnvSize bgClr ars ctrn".split(" "));
var C=je.VE,f=this.Eg;C.uniformMatrix3fv(f.tmat,!1,W);C.uniform4fv(f.gsize,D);C.uniform3f(f.contSizeZoom,j,I,U);
C.uniform2f(f.cnvSize,M,m);C.uniformMatrix4fv(f.ctrn,!1,g);if(this.aky){C.uniform4fv(f.ars,A);C.uniform4fv(f.bgClr,l)}C.uniform1i(f.source,0);
C.uniform1i(f.target,1);C.activeTexture(C.TEXTURE0);C.bindTexture(C.TEXTURE_2D,w);C.activeTexture(C.TEXTURE1);
C.bindTexture(C.TEXTURE_2D,n);if(k){C.uniform1f(f.N,$);C.uniform1i(f.lut,2);C.activeTexture(C.TEXTURE2);
C.bindTexture(C.TEXTURE_2D,k.LJ);var z=C.LINEAR;C.texParameteri(C.TEXTURE_2D,C.TEXTURE_MIN_FILTER,z);
C.texParameteri(C.TEXTURE_2D,C.TEXTURE_MAG_FILTER,z)}C.activeTexture(C.TEXTURE0)};function d4(){et.call(this,[9,7],!1,"---panels/layercomps",et.ip.aax);
this.h_.setAttribute("style","min-width:240px;");this.yV=null;this.He=-1;this.K2=[];this.yd=e.t("div","scrollable");
this.yd.style.height="160px";this.h_.appendChild(this.yd);this.jU=e.t("div","lpfoot");this.h_.appendChild(this.jU);
this.uH=[];var w=["<svg class=\"miniscale gsicon\" viewBox=\"0 0 15 15\" width=\"15\" height=\"15\" fill=\"black\"><path d=\"M14,6 L10,6 L10,0 L4,0 L4,6 L0,6 L7,13 L14,6 L14,6 Z M0,14 L0,16 L14,16 L14,14 Z\" /></svg>","reload","lrs/newlayer","lrs/bin"],n=["Layer Comps to Files",[5,10],[5,3],[5,4]];
for(var L=0;L<w.length;L++){var W=w[L];if(L>0)W="<img src=\""+PIMG[w[L]]+"\" class=\"miniscale gsicon\" />";
var D=new iP(W,!1,n[L]);D.h("click",this.apT,this);this.jU.appendChild(D.e);this.uH.push(D)}}d4.prototype=new et("");
d4.prototype.zl=function(w,n){this.h_.setAttribute("style","width:"+(w-2)+"px;");this.yd.style.height=n-28+"px"};
d4.prototype.f8=function(w){var n=new ed(b.E.v,!0);n.data=w;n.G=y.q$;this.S(n)};d4.a36="var opts = new ExportOptionsSaveForWeb(); opts.format = SaveDocumentType.PNG; opts.PNG8 = false; opts.quality = 100; var doc = app.activeDocument;var lc = doc.layerComps; if(lc.length==0) alert(\"No layer comps.\"); else { \tvar stat = doc.historyStates.length - 1;\t\tfor(var i=0; i<lc.length; i++) {\t\tlc[i].apply();\t\tpngFile = new File(lc[i].name+\".png\");\t\tapp.activeDocument.exportDocument(pngFile, ExportType.SAVEFORWEB, opts);\t}\t\tdoc.activeHistoryState = doc.historyStates[stat];}";
d4.prototype.apT=function(w){var L=this.uH.indexOf(w.currentTarget)-1;if(L==-1){var n=new ed(b.E.L,!0);
n.data={d:b.c.zM,wx:d4.a36};this.S(n);return}if(L!=1)if(this.He==-1)return;this.f8({d:["updLC","addLC","delLC"][L],p_:this.He});
if(L==2)this.He=-1};d4.prototype.f=function(){et.prototype.f.call(this);for(var L=0;L<this.uH.length;
L++)this.uH[L].f()};d4.prototype.mQ=function(w){if(w==null)e.W0(this.h_,"disabled");else e.IX(this.h_,"disabled");
this.yV=w;e._g(this.yd);if(w==null)return;var n=w.kO.lastAppliedComp?w.kO.lastAppliedComp.v:0,W=w.kO.list.v.slice(0);
W.unshift({v:{Nm:{v:"Last Document State"},compID:{v:0},capturedInfo:{v:0}}});for(var L=0;L<W.length;
L++){var D=W[L].v,j=new ab(D.Nm.v,D.compID.v,D.capturedInfo.v,n,this.He);j.h("activate",this.h7,this);
j.parent=this;this.yd.appendChild(j.e);this.K2.push(j)}};d4.prototype.h7=function(w){this.He=w.currentTarget.p_;
this.mQ(this.yV)};function ab(w,L,n,W,D){eg.call(this);this.p_=L;this.e=e.t("div","head listitem"+(L==D?" selected":""));
var j=L==W,I=new iP(j?"\u2713":"\u2014");if(j)I.d3();this.e.appendChild(I.e);I.h("click",this.YW,this);
var U=this.Vd=e.t("span");U.textContent=w;this.e.appendChild(U);this.uH=[];if(L!=0){this.e.addEventListener("mouseup",this.h7.bind(this),!1);
this.a7H=e.t("span","headR");this.e.appendChild(this.a7H);var M=["lrs/eye","pos","lrs/fx"],m=["Visibility","Position","Appearance"];
for(var l=0;l<M.length;l++){var A=new iP("<img src=\""+PIMG[M[l]]+"\" class=\"autoscale gsicon\" />",!1,m[l]);
if((n>>l&1)==0)A.e.setAttribute("style","opacity:0.3");A.h("click",this.aoA,this);this.a7H.appendChild(A.e);
this.uH.push(A)}}}ab.prototype=new eg;ab.prototype.h7=function(w){if(w.target!=this.Vd&&w.target!=this.e)return;
if(w.detail==1)this.S(new ed("activate",!1));else{var n=new et.IM(this.Vd,this.sW.bind(this))}};ab.prototype.aoA=function(w){var L=this.uH.indexOf(w.currentTarget);
this.f8({d:"editLC",a9G:L,p_:this.p_})};ab.prototype.sW=function(w){this.f8({d:"editLC",np:w,p_:this.p_})};
ab.prototype.YW=function(w){this.f8({d:"setLC",p_:this.p_})};ab.prototype.f8=function(w){var n=new ed(b.E.v,!0);
n.data=w;n.G=y.q$;this.S(n)};function aZ(){et.call(this,[9,11],!1,"---panels/navigator",et.ip.abw);var w=e.t("div","padded");
w.setAttribute("style","min-width:15em");this.h_.appendChild(w);var n=e.t("div");w.appendChild(n);n.setAttribute("style","cursor:grab;");
this.T=e.t("canvas");this.T.width=100;n.appendChild(this.T);e.ZS(this.T);e.L_(this.T,this.aF.bind(this));
this.n9=new f2(null,2,6400,"%",null,!0);this.n9.h(b.E.A,this.a48,this);w.appendChild(this.n9.e);this.a3e=this.OO.bind(this);
this.axJ=this.Ou.bind(this);this.tI=null;this.zy=null;this.J3=!1}aZ.prototype=new et("");aZ.prototype.zl=function(w,n){this.Uc()};
aZ.prototype.a48=function(w){var n=this.n9.b(),W=this.tI,D=n/100;if(.8<D&&D<1.2)D=1;else if(1.8<D)D=Math.round(D);
var j=new ed(b.E.v,!0);j.G=y.Nt;j.data={d:"zoom",N:D};this.S(j)};aZ.prototype.aF=function(w){var n=this.tI;
if(n==null)return;this.J3=!0;e.Ko(window,this.a3e);e.d6(window,this.axJ)};aZ.prototype.OO=function(w){var n=e.rv(w,this.T),W=this.tI,D=this.T.width,j=this.T.height,I=(n.x*e.V()-D/2)/D,U=(n.y*e.V()-j/2)/j,M=e.V()*W.u.N,m=Math.round(-W.u.N*W.m*I),l=Math.round(-W.u.N*W.n*U);
y.fK.U5(W,m,l)};aZ.prototype.Ou=function(w){e.MC(window,this.a3e);e.i_(window,this.axJ);this.J3=!1};
aZ.prototype.mQ=function(w){if(w==null&&this.tI!=null)this.T.width=100;this.tI=w;this.Uc()};aZ.prototype.a5N=function(){var w=300*e.V(),n=0,W=this.tI,D=[W.Vc(),new iB(0,0,W.m,W.n)];
E.L3(D);while(Math.max(D[n+1].m,D[n+1].n)>w){n+=2}this.zy=D.slice(n)};aZ.prototype.Uc=function(){var w=this.tI;
if(w==null||w.u.N==0)return;var n=w.u;if(!e.LY(this.h_))return;this.n9.$(n.N*100);if(!this.J3)this.a5N();
var W=this.zy[0],D=this.zy[1],j=D.m,I=D.n,U=this.T;U.width=j;U.height=I;e.UE(U,j,I);var M=U.getContext("2d"),m=M.createImageData(j,I);
E.nX(W,m.data);M.putImageData(m,0,0);M.getImageData(0,0,1,1);var l=n.xq,A=n.Cg(l.x,l.y),g=n.Cg(l.x+l.m,l.y+l.n),k=j/w.m;
M.scale(k,k);M.lineWidth=4/k;M.strokeStyle="#ff0000";M.strokeRect(A.x,A.y,g.x-A.x,g.y-A.y)};aZ.prototype.GZ=function(w,n){};
aZ.prototype.c2=function(){this.Uc()};function cK(w,n){et.call(this,w.name,!1,w.icon,n);this.a7h=w}cK.prototype=new et("");
cK.prototype.Wg=function(){var w=this.h_,n=this.a7h;if(!e.LY(w)||this.Pp)return;var W=this.Pp=e.t("iframe");
W.setAttribute("src",n.url);this.h_.appendChild(W)};cK.prototype.c2=cK.prototype.mQ=function(){this.Wg()};
cK.prototype.E$=function(w){if(e.LY(this.Pp))this.Pp.contentWindow.postMessage(w,"*")};cK.prototype.zl=function(w,n){if(this.Pp==null)return;
this.Pp.setAttribute("style","width:"+w+"px; height:"+n+"px")};function da(){et.call(this,[9,12],!1,"---panels/tpreset",et.ip.Q6);
this.ww=null;this.Um=new gp(y.zq);this.Um.parent=this;var w=e.t("div","padded");w.setAttribute("style","width:20em");
this.h_.appendChild(w);w.appendChild(this.Um.sz)}da.prototype=new et("");da.prototype.c2=function(){this.Um.FC(this.ww.oH)};
da.prototype.GZ=function(w,n){this.ww=w;if(n==bk.bI||n==bk.Q6)this.Um.FC(w.oH)};da.prototype.zl=function(w,n){this.Um.auy(this.ww.No)};
da.prototype.f=function(){et.prototype.f.call(this);this.Um.f()};var fE=function(){var w=[],n=null,W=null,D=null,j=[[100,180,255],[100,255,100],[255,200,100],[200,100,255],[255,100,200]];
function I(){et.call(this,"Memory",!1,null,et.ip.ayu);var k=e.t("div","padded");this.h_.appendChild(k);
W=new iP(["<< VAR0",[0,13,2]],!1,null,!0);W.addEventListener("click",function($){w.pop();M()});k.appendChild(W.e);
n=e.t("div","scrollable");n.setAttribute("style","width:20em; height:26em; margin-top:8px;");k.appendChild(n)}I.prototype=new et("");
I.prototype.mQ=function(k,$,C){D=$;this.c2()};I.prototype.c2=function(){W.G3(!1);if(!e.LY(n))return;
var k={I6:"Total:",vd:[]};for(var L=0;L<D.length;L++)k.vd.push(l(D[L]));g(k);w=[k];M()};I.prototype.f=function(){et.prototype.f.call(this);
W.f()};function U(k){var $=k.currentTarget,L=0;while(($=$.previousSibling)!=null)L++;w.push(w[w.length-1].vd[L-1]);
M()}function M(){W.G3(w.length>1);var k=w[w.length-1];e._g(n);m(k,n,0);k.vd.sort(function($,C){return C.Rf[0]-$.Rf[0]});
for(var L=0;L<k.vd.length;L++)m(k.vd[L],n,1)}function m(k,$,C){var f=fp.cN,z=C!=0&&k.vd,s="margin-left:"+C*10+"px; margin-bottom:8px; padding:3px 5px;";
if(z)s+="cursor:pointer;";if(k.Y3!=null)s+="background-color:rgba("+j[k.Y3].join(",")+",0.2);";var O=e.t("div");
$.appendChild(O);O.setAttribute("style",s);O.innerHTML=e.VT(k.I6)+"<br />"+"RAM: <b>"+f(k.Rf[0])+"</b>\u2001GPU: <b>"+f(k.Rf[1])+"</b>";
if(z)O.addEventListener("click",U,!1)}function l(k){var $={I6:k.name,vd:[],Y3:0},C=je.YG?1:0,f=1-C,z={I6:"Final Image",Rf:[k.m*k.n*4,C*k.m*k.n*4],Y3:2};
$.vd.push(z);for(var L=0;L<k.C.length;L++){var s=A(k.C[L]);if(s.vd.length!=0)$.vd.push(s)}var O=k.add.lnk2;
if(O)for(var L=0;L<O.length;L++){var s=O[L],a={I6:s.O7,vd:[],Y3:4},X=0;a.vd.push({I6:"Raw file",Rf:[s.raw.length,0]});
if(s.PO)for(var P=0;P<s.PO.length;P+=2)X+=s.PO[P].length;if(X!=0)a.vd.push({I6:"Decoded pixels",Rf:[X,0]});
g(a);$.vd.push(a)}g($);return $}function A(k){var $={I6:k.getName(),vd:[],Y3:1},C=je.YG?1:0,f=1-C,z=k.rect.O();
if(z!=0)$.vd.push({I6:"Layer pixels",Rf:[z*4,C*z*4]});if(k.add.lmfx&&k.US.IH.type){var s=k.US.IH.type,P=0;
for(var O in s){var a=0;for(var X=0;X<s[O].length;X++)if(O=="ebbl"){if(s[O][X].WY)a+=s[O][X].WY.aA.O();
if(s[O][X].T4)a+=s[O][X].T4.aA.O();if(s[O][X].ql)a+=s[O][X].ql.aA.O();if(s[O][X].TV)a+=s[O][X].TV.aA.O()}else a+=s[O][X].aA.O();
if(a!=0)$.vd.push({I6:fV.get(at.names[at.order.indexOf(O)]),Rf:[f*a*4,C*a*4],Y3:3})}if(k.US.kh)P+=z;
if(k.US.kB)P+=z;if(k.US.EG)P+=z;if(k.US.EG)P+=z;if(k.US.AT)P+=z;if(k.US.hX)P+=z;var Z=k.US.gY?k.US.gY.length:0;
if(P+Z!=0)$.vd.push({I6:"Additional Blending Data",Rf:[f*P*4+Z,C*P*4]})}var Y=k._N(),K=Y?Y.rect.O():0;
if(K!=0){$.vd.push({I6:"Raster Mask",Rf:[K,0]})}var Y=k.add.vmsk,K=Y&&Y.pv?Y.pv.rect.O():0;if(K!=0){$.vd.push({I6:"Vector Mask",Rf:[K,0]})}g($);
return $}function g(k){k.Rf=[0,0];for(var L=0;L<k.vd.length;L++){k.Rf[0]+=k.vd[L].Rf[0];k.Rf[1]+=k.vd[L].Rf[1]}}return I}();
function a9(){et.call(this,[9,14],!1,"---panels/notes",et.ip.anu);this.h_.setAttribute("style","min-width:240px;");
var w=e.t("div","padded");this.h_.appendChild(w);this.B5=new e7("Author");w.appendChild(this.B5.e);this.RE=e.t("textarea");
e.xr(this.RE);w.appendChild(this.RE);var n=new iP("<<",null,null,!0);w.appendChild(n.e);this.arD=n;var W=new iP(">>",null,null,!0);
w.appendChild(W.e);n.h("click",this.HA,this);W.h("click",this.HA,this);var D=this.axE=new ga("");w.appendChild(D.e)}a9.prototype=new et("");
a9.prototype.HA=function(w){var n=w.target==this.arD?-1:1,W=this.tI,D=W.add.Anno;if(D==null)return;var j=D.length,I=W.u.PM;
W.u.PM=(I+n+j)%j;W.tL=!0;this.Uc()};a9.prototype.Uc=function(){var w=this.tI;if(w==null)return;var n=w.add.Anno;
if(n==null||n.length==0)return;var W=w.u.PM,D=n[W];this.RE.value=D[4];this.axE.$(W+1+" / "+n.length);
this.B5.$(D[3])};a9.prototype.zl=function(w,n){if(this.gA==w)return;this.gA=w;n=Math.min(n,200);this.RE.setAttribute("style","display:block;tab-size:4; margin:0; font-family:monospace; width:"+(w-10)+"px; height:"+(n-66)+"px")};
a9.prototype.mQ=function(w,n,W){this.tI=w;this.Uc()};function ff(){eg.call(this);this.G=0;this.GH=null;
this.e=e.t("div","toolconf");this.Um=null;this.yK=null;this.body=new e.t("div","body")}ff.prototype=new eg;
ff.prototype.a1f=function(w,n){this.G=w;this.GH=n;if(y.l5[w]){var W=this.Um=new gp(w);this.e.appendChild(W.e);
W.parent=this}else{this.yK=e.t("div");this.e.appendChild(this.yK)}this.e.appendChild(this.body);this.f()};
ff.prototype.a5p=function(w,n){};ff.prototype.asT=function(w){};ff.prototype.GZ=function(w,n){if(n==bk.bI||n==bk.Q6)if(this.Um)this.Um.FC(w.oH)};
ff.prototype.um=function(w){};ff.prototype.f=function(){if(this.Um)this.Um.f();else this.yK.innerHTML=e.DZ(this.GH,null,"toolicon");
this.hp()};ff.prototype.hp=function(){};function hh(){ff.call(this);this.Dt=new b1;this.Dt.h(b.E.A,this.HG,this);
this.body.appendChild(this.Dt.e)}hh.prototype=new ff;hh.prototype.hp=function(){this.Dt.f()};hh.prototype.HG=function(w){var n=new ed(b.E.L,!0);
n.data={d:b.c.bw,G:this.G,AH:this.Dt.am5()};this.S(n)};hh.prototype.um=function(w){this.Dt.a8H(w.LQ)};
function gl(w){ff.call(this);if(w==null)return;this.ww=null;this.a0={};if(w.indexOf("brush")!=-1&&w.indexOf("prsr")==-1)w.push("prsr");
for(var L=0;L<w.length;L++){var n=w[L],W=null;if(n=="brush"){W=new ch}if(n=="bmode"){W=new i0([12,19,0],dD.AE,dD.E5)}if(n=="bmode0"){W=new i0([12,19,0],dD.AE.slice(23))}if(n=="emode"){W=new i0([12,36],[[9,3],[10,38]])}if(n=="opacity"){W=new g_([12,0],0,100,"%");
W.$(100)}if(n=="flow"){W=new g_([12,63],0,100,"%");W.$(100)}if(n=="smth"){W=new g_([19,3,0],0,100,"%");
W.$(0)}if(n=="samp"){W=new i0([12,36],[[12,25,4],[12,25,5],[12,46]])}if(n=="wconf"){W=new hq;W.$([40,!0,!0])}if(n=="sall"){W=new b7([12,25,2])}if(n=="strn"){W=new g_([12,64],1,100,"%");
W.$(50)}if(n=="smode"){W=new i0([12,36],[[19,7,0],[19,7,1]]);W.$(1)}if(n=="pdetail"){W=new b7([12,65]);
W.d3()}if(n=="rng"){W=new i0([12,12],[[19,6,0],[19,6,1],[19,6,2]]);W.$(1)}if(n=="expo"){W=new g_([12,5],0,100,"%");
W.$(50)}if(n=="algnd"){W=new b7([12,75]);W.$(!1)}if(n=="sfrom"){W=new i0([12,70],[[17,1],[17,3],[17,0]])}if(n=="alt"){W=new jw(null,["Alt"],!0,["Select Source"])}if(n=="qsmode"){W=new j$([12,36],["<img src=\""+PIMG["set/front"]+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG.zoomIn+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG.zoomOut+"\" class=\"autoscale gsicon\" />"],[[5,3],[18,1],[18,2]])}if(n=="redge"){W=new iP([7,11],!1,null,!0)}if(n=="setop"){W=new jb}if(n=="patch"){W=new j$(null,[[12,70],[12,71]])}if(n=="prsr"){W=this.a0.brush.$Y}this.body.appendChild(W.e);
if(n=="prsr")continue;W.parent=this;this.a0[n]=W;if(n=="brush")W.h(b.E.A,this.auL,this);else if(n=="redge")W.h("click",this.wG,this);
else W.h(b.E.A,this.Of,this)}}gl.prototype=new ff;gl.prototype.a5p=function(w,n){w=w[1];var W=this.a0;
if(w.Md)W.bmode.$(dD.ik.indexOf(w.Md.v.BlnM));if(w.Opct)W.opacity.$(w.Opct.v);if(w.flow)W.flow.$(w.flow.v);
if(w.Brsh)W.brush.$(w,n.t$.yg,n.t$.j6);if(w.FrgC){var D=E.M.y_(w.FrgC.v),j=new ed(b.E.L,!0);j.data={d:b.c.oj,AH:bk.X$,vK:0,Z:D.o<<16|D.B<<8|D.k};
this.S(j)}this.auL();this.Of()};gl.prototype.asT=function(){if(y.l5[this.G]==null)return null;var w=this.a0,n=JSON.parse(JSON.stringify(w.brush.b()));
n.classID=y.l5[this.G][1][0];if(w.bmode)n.Md={t:"enum",v:{BlnM:dD.ik[w.bmode.b()]}};if(w.opacity)n.Opct={t:"long",v:w.opacity.b()};
if(w.flow)n.flow={t:"long",v:w.flow.b()};var W=this.ww.Gp;W={o:W>>>16,B:W>>>8&255,k:W&255};n.FrgC={t:"Objc",v:E.M.lW(W)};
return["Brush Preset "+n.Brsh.v.Dmtr.v.val,n]};gl.prototype.wG=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.P2,jW:"redge"};
this.S(w)};gl.prototype.hp=function(){for(var w in this.a0)this.a0[w].f()};gl.prototype.um=function(w){if(w.akT=="showBrushOpts"){this.a0.brush.a7v(w.Sd.x,w.Sd.y)}for(var n in w.EK){var W=w.EK[n];
if(n!="qsmode")W*=100;if(this.a0[n])this.a0[n].$(W)}};gl.prototype.GZ=function(w,n){ff.prototype.GZ.call(this,w,n);
this.ww=w;var W=this.a0.brush;if(W==null)return;if(n==bk.bI||n==bk.zq)W.FC(w.t$);if(n==bk.ef){W.$(w.t$.lH,w.t$.yg,w.t$.j6)}};
gl.prototype.auL=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.oj,AH:bk.ef,UT:this.a0.brush.b()};this.S(w)};
gl.prototype.Of=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.bw,G:this.G};for(var n in this.a0){if(n=="brush"||n=="redge")continue;
var W=this.a0[n].b();if(["opacity","flow","smth","strn","expo"].indexOf(n)!=-1)w.data[n]=W/100;else if(n=="bmode")w.data.bmode=dD.mS[W];
else if(n=="bmode0")w.data.bmode=dD.mS[23+W];else w.data[n]=W}this.S(w)};function gO(w,n){ff.call(this);
if(w)return;this.a0={};for(var L=0;L<n.length;L++){var W=n[L],D=null;if(W=="binop")D=new jb;if(W=="feat"){D=new g_([7,6],0,100,"px");
D.$(0)}if(W=="redge")D=new iP([7,11],!1,null,!0);if(W=="wconf")D=new hq;if(W=="cstr")D=new bV;if(W=="anta"){D=new b7([12,25,1]);
D.$(!0)}if(W=="sall")D=new b7([12,25,2]);if(W=="redge")D.h("click",this.wG,this);else D.h(b.E.A,this.Of,this);
D.parent=this;this.body.appendChild(D.e);this.a0[W]=D}}gO.prototype=new ff;gO.prototype.um=function(w){if(w.K8!=null)this.a0.binop.$(w.K8);
else if(w.RQ){for(var n in w.RQ)if(this.a0[n])this.a0[n].$(w.RQ[n])}else{var W=gO.y2;if(W==null){var D=hn.alB(!0);
W=gO.y2=new cA(D.items,D.Zf)}W.f();W.parent=this;W.update(w.AR,w.Yo);var j=new ed(b.E.L,!0);j.data={d:b.c.Uq,BT:W,x:w.ao.Qc+2,y:w.ao.tc+1};
this.S(j)}};gO.prototype.hp=function(){for(var w in this.a0)this.a0[w].f()};gO.prototype.wG=function(){var w=new ed(b.E.L,!0);
w.data={d:b.c.P2,jW:"redge"};this.S(w)};gO.prototype.Of=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.bw,G:this.G,RQ:{}};
for(var n in this.a0)w.data.RQ[n]=this.a0[n].b();this.S(w)};function k5(){gl.call(this,["brush","strn"])}k5.prototype=new gl;
function bz(){gl.call(this,"brush bmode opacity flow smth prsr".split(" "))}bz.prototype=new gl;function d5(){gl.call(this,["brush","bmode0","samp","wconf"])}d5.prototype=new gl;
function iR(){gl.call(this,["brush"])}iR.prototype=new gl;function gH(){gl.call(this,["brush","bmode","opacity","smth","prsr"])}gH.prototype=new gl;
function hD(){gl.call(this,["brush","rng","expo"])}hD.prototype=new gl;function ht(){gl.call(this,"brush bmode opacity algnd sfrom alt".split(" "))}ht.prototype=new gl;
function jn(w){ff.call(this);if(w==null)return;var n=e.t("span","fitem");this.body.appendChild(n);var W=[[17,0],[17,1],[11,12,0],[17,2]];
this.ai=[];for(var L=0;L<W.length;L++){var D=new iP(W[L],!1,null,!0);this.ai.push(D);D.h("click",this.asE,this);
if(!w||L==1)n.appendChild(D.e)}this.lR=new bV;this.lR.h(b.E.A,this.a8j,this);if(!w)this.body.appendChild(this.lR.e);
this.RI=new iP([15,7,6],!1,null,!0);this.RI.h("click",this.asE,this);if(!w)this.body.appendChild(this.RI.e);
this.LU=new b7([15,7,10]);this.LU.h(b.E.A,this.a8j,this);if(!w)this.body.appendChild(this.LU.e);this.RD=new c1;
this.RD.h("click",this.qO,this)}jn.prototype=new ff;jn.prototype.hp=function(){this.RD.f();for(var L=0;
L<this.ai.length;L++)this.ai[L].f();this.lR.f();this.LU.f();this.RI.f()};jn.prototype.um=function(w){var n=this.RD.e;
if(w.Az)this.body.appendChild(n);else if(this.body.contains(n))this.body.removeChild(n);if(w.lR)this.lR.$(w.lR)};
jn.prototype.qO=function(w){var n={d:b.c.bw,G:this.G,_b:this.RD.b()?"commit":"cancel"},W=new ed(b.E.L,!0);
W.data=n;this.S(W)};jn.prototype.asE=function(w){w.target.e.blur();var n={d:b.c.bw,G:this.G,_b:"cropby",ahT:this.ai.indexOf(w.target)};
if(w.target==this.RI)n._b="straighten";var W=new ed(b.E.L,!0);W.data=n;this.S(W)};jn.prototype.a8j=function(w){var n={d:b.c.bw,G:this.G,_b:"config",$I:{$o:this.lR.b(),Ov:this.LU.b()},av7:w.target==this.lR},W=new ed(b.E.L,!0);
W.data=n;this.S(W)};function hV(){jn.call(this,!1)}hV.prototype=new jn;function eQ(){jn.call(this,!0)}eQ.prototype=new jn;
function fb(){gl.call(this,["brush","rng","expo"])}fb.prototype=new gl;function gn(){gl.call(this,"brush emode opacity flow smth prsr".split(" "))}gn.prototype=new gl;
function kb(){gl.call(this,["brush","samp","wconf"])}kb.prototype=new gl;function cr(){gO.call(this,!1,["binop","feat","anta","redge","cstr"])}cr.prototype=new gO(!0);
function ez(){ff.call(this);var w=this.a0=[new i0([12,20,0],["1x1","3x3","5x5","11x11","31x31"]),new i0([12,70],[[17,1],[17,3],[17,0]]),new b7([12,20,1]),new b7([8,0])];
w[1].$(2);w[2].$(!0);for(var L=0;L<w.length;L++){var n=w[L];n.h(b.E.A,this.Of,this);this.body.appendChild(n.e)}}ez.prototype=new ff;
ez.prototype.Of=function(w){var n=this.a0,W=[];for(var L=0;L<n.length;L++)W[L]=n[L].b();var D=new ed(b.E.L,!0);
D.data={d:b.c.bw,G:this.G,RQ:W};this.S(D)};ez.prototype.hp=function(){for(var L=0;L<this.a0.length;L++)this.a0[L].f()};
function ja(){ff.call(this);this.we=new jr(!1);this.we.parent=this;this.we.h(b.E.A,this.bX,this);this.body.appendChild(this.we.e);
this.we.$(JSON.parse(at._V.a1X).v);this.$t=new i0(null,at.M.names.slice(0,5));this.$t.h(b.E.A,this.bX,this);
this.body.appendChild(this.$t.e);this.HW=new i0([12,19,0],dD.AE,dD.E5);this.HW.h(b.E.A,this.bX,this);
this.body.appendChild(this.HW.e);this.N6=new g_([12,0],0,100,"%");this.N6.parent=this;this.N6.h(b.E.A,this.bX,this);
this.body.appendChild(this.N6.e);this.N6.$(100);this.fu=new b7([12,23,0]);this.fu.h(b.E.A,this.bX,this);
this.body.appendChild(this.fu.e);this.Z7=new b7([12,23,3]);this.Z7.h(b.E.A,this.bX,this);this.body.appendChild(this.Z7.e)}ja.prototype=new ff;
ja.prototype.hp=function(){this.$t.f();this.HW.f();this.N6.f();this.fu.f();this.Z7.f()};ja.prototype.GZ=function(w,n){ff.prototype.GZ.call(this,w,n);
var W=n==bk.X$;this.we.Wc(w.Gp,w.as);if(W||n==bk.tU||n==bk.bI)this.we.FC(w.wX)};ja.prototype.bX=function(){var w=new ed(b.E.L,!0);
w.data={d:b.c.bw,G:this.G};w.data.AH={M:this.we.b(),nK:at.M.types[this.$t.b()],Ty:this.fu.zr(),WV:this.Z7.zr(),aoc:dD.mS[this.HW.b()],Z8:this.N6.b()/100};
this.S(w)};function by(){ff.call(this);this.Fo=new b7([8,7,1]);this.body.appendChild(this.Fo.e);this.Fo.h(b.E.A,this.Of,this)}by.prototype=new ff;
by.prototype.Of=function(){var w={d:b.c.bw,G:this.G,j4:this.Fo.b()},n=new ed(b.E.L,!0);n.data=w;this.S(n)};
function fD(){ff.call(this);var w=e.t("span","fitem");this.body.appendChild(w);this.Mu=[new g_([12,15],-180,180,"\xB0"),new iP([1,12,2],null,null,!0)];
for(var L=0;L<this.Mu.length;L++){var n=this.Mu[L];n.parent=this;w.appendChild(n.e);n.h(L==1?"click":b.E.A,this.Ch,this)}}fD.prototype=new ff;
fD.prototype.hp=function(){for(var L=0;L<this.Mu.length;L++)this.Mu[L].f()};fD.prototype.um=function(w){this.Mu[0].$(w.kI*180/Math.PI)};
fD.prototype.Ch=function(w){var n=this.Mu.indexOf(w.target),W=new ed(b.E.L,!0);W.data={d:b.c.bw,G:this.G,kI:n==1?0:w.target.b()*Math.PI/180};
this.S(W)};function iA(){gl.call(this,["brush","algnd","sfrom","alt"])}iA.prototype=new gl;function bp(){ff.call(this);
this.Ee=new af;this.Ee.parent=this;this.body.appendChild(this.Ee.W3.e);this.body.appendChild(this.Ee.f4.e);
this.body.appendChild(this.Ee.a6.e);this.body.appendChild(this.Ee.aj.e);var w=e.t("span","fitem");this.body.appendChild(w);
w.appendChild(this.Ee.cv.e);w.appendChild(this.Ee.Md.e);w.appendChild(this.Ee.iC.e);this.rQ=new i0("Aa",[[22,5,0],[12,95,0],[12,95,1],[12,95,2],[12,95,3]]);
this.rQ.h(b.E.A,this.qO,this);this.body.appendChild(this.rQ.e);this.ro=new iP([11,9],!1,null,!0);this.ro.h("click",this.aeh,this);
this.body.appendChild(this.ro.e);this.RD=new c1;this.RD.h("click",this.qO,this)}bp.prototype=new ff;
bp.prototype.hp=function(){this.RD.f();this.Ee.f();this.ro.f()};bp.prototype.aeh=function(w){var n={d:b.c.bw,G:this.G,_b:"showwarp"},W=new ed(b.E.L,!0);
W.data=n;this.S(W)};bp.prototype.um=function(w){if(w._b=="showactive")this.body.appendChild(this.RD.e);
if(w._b=="hideactive")this.body.removeChild(this.RD.e);if(w._b=="changeAA")this.rQ.$(w.qY);if(w._b=="showpan"){var n=[{name:[0,1],nW:!0}],W=[{Y:b.E.v,G:y.Lu,W:{d:"editCurr",XT:w.XT}}],D=w.ao;
if(w.azv){n=[{name:["VAR0: VAR1",[0,5],[7,0]],nW:!0}];W=[{Y:b.E.W1,W:y.eZ.Jj(!0)}];var j=hn.a3h();n=n.concat(j[0]);
W=W.concat(j[1])}n.push({name:[11,9]});W.push({Y:b.E.L,W:{d:b.c.bw,G:this.G,_b:"showwarp"}});var I=new cA(n,W);
I.parent=this;I.f();I.update(w.AR,w.Yo);var U=new ed(b.E.L,!0);U.data={d:b.c.Uq,BT:I,x:D.Qc+2,y:D.tc+1};
this.S(U)}};bp.prototype.GZ=function(w,n){ff.prototype.GZ.call(this,w,n);if(n!=bk.bI&&n!=bk.a8&&n!=bk.v3&&n!=bk.SJ)return;
this.Ee.$(w.Hu,w.hY,w.Io)};bp.prototype.qO=function(w){var n={d:b.c.bw,G:this.G,_b:this.RD.b()?"commit":"cancel"};
if(w.target==this.rQ){n._b="changeAA";n.qY=this.rQ.b()}var W=new ed(b.E.L,!0);W.data=n;this.S(W)};function bU(){gO.call(this,!1,["binop","feat","anta","redge"])}bU.prototype=new gO(!0);
function dk(){ff.call(this);var w=[],W="<svg class=\"autoscale gsicon\" viewBox=\"0 0 14 18\" width=\"14\" height=\"18\" fill=\"black\"><path d=\"M14,6 L10,6 L10,0 L4,0 L4,6 L0,6 L7,13 L14,6 L14,6 Z M0,14 L0,16 L14,16 L14,14 Z\" /></svg>";
this.G4=new b7([12,85]);this.G4.$(!0);this.G4.h(b.E.A,this.Of,this);w.push(this.G4.e);this.gf=new i0(null,[[0,4],[0,3]]);
this.gf.h(b.E.A,this.Of,this);this.gf.$(1);w.push(this.gf.e);this.Lj=new b7([20,1]);this.Lj.h(b.E.A,this.Of,this);
w.push(this.Lj.e);this.bF=new b7([12,83]);this.bF.h(b.E.A,this.Of,this);w.push(this.bF.e);this.bL=new eg;
this.bL.e=e.t("div","floatcont form");this.bL.e.setAttribute("style","max-width: 200px;");this.bL.parent=this;
var n=this.bL.e;this.anZ=new i0("Scale for exported files",["1x","2x","3x","4x"]);n.appendChild(this.anZ.e);
this.rn=new iP(W+" PNG",!1,"Save selected layers as PNG",!0);n.appendChild(this.rn.e);this.rn.h("click",this.Ft,this);
this.aaz=new iP(W+" SVG",!1,"Save selected layers as SVG",!0);n.appendChild(this.aaz.e);this.aaz.h("click",this.Ft,this);
var D=new iP(W,!1,"Save selected layers",!0);w.push(D.e);D.h("click",function(m){if(e.LY(this.bL.e))return;
var l=D.e.getBoundingClientRect(),A=new ed(b.E.L,!0);A.data={d:b.c.Uq,BT:this.bL,x:l.left,y:l.top+l.height,SR:!0};
this.S(A)},this);var j=e.t("span","fitem");w.push(j);var I=e.t("span","fitem");w.push(I);this.uH=[];
for(var L=0;L<8;L++){var U=L==3||L==7?[20,4,6]:[20,4,L<3?L:L-1],M=new iP("Hi",!1,U);(L<4?j:I).appendChild(M.e);
M.h("click",this.Ft,this);this.uH.push(M)}for(var L=0;L<w.length;L++)this.body.appendChild(w[L]);this.a8$=w}dk.prototype=new ff;
dk.prototype.um=function(w){var n=w.LQ,W=w.adr;this.G4.$(n.az);this.Lj.$(n.Qe);this.bF.$(n.TH);if(W){e._g(this.body);
for(var L=0;L<W.length;L++)if(W[L]==1&&this.a8$[L])this.body.appendChild(this.a8$[L])}};dk.prototype.Ft=function(w){var n=this.uH.indexOf(w.target),W;
if(n==-1){W=new ed(b.E.L,!0);W.data={d:b.c.bw,G:this.G,vK:w.target==this.rn?"getPNG":"getSVG",dI:this.anZ.b()+1}}else{W=new ed(b.E.v,!0);
W.G=y.Rv;W.data={d:"algn",Z:n}}this.S(W)};dk.prototype.Of=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.bw,G:this.G,vK:"prms",az:this.G4.zr(),a6H:this.gf.b(),Qe:this.Lj.zr(),TH:this.bF.zr()};
this.S(n)};dk.prototype.hp=function(){this.G4.f();this.gf.f();this.Lj.f();this.bF.f();var w="h0 h1 h2 hG v0 v1 v2 vG".split(" ");
for(var L=0;L<8;L++){this.uH[L].wV(e.DZ("align/"+w[L],null,"autoscale"))}};function f$(){gO.call(this,!1,["binop","feat","redge","wconf","sall"])}f$.prototype=new gO(!0);
function a2(){gl.call(this,["setop","patch"])}a2.prototype=new gl;function eM(){gl.call(this,["setop"])}eM.prototype=new gl;
function gA(){gl.call(this,["bmode","opacity","wconf","sall"])}gA.prototype=new gl;function gS(){gO.call(this,!1,["binop","feat","anta","redge"])}gS.prototype=new gO(!0);
function i5(){gO.call(this,!1,["binop","feat","anta","redge"])}i5.prototype=new gO(!0);function bA(){gO.call(this,!1,["binop","feat","redge","cstr"])}bA.prototype=new gO(!0);
function fR(){ff.call(this);this.ww=null;this.kn=null;this.Ci=[new e7("X",null,3.2,null,!0),new e7("Y",null,3.2,null,!0),new e7("W",null,3.2,null,!0),new e7("H",null,3.2,null,!0),new e7([12,15],"\xB0",3.7,null,!0),new e7(["VAR0 1",[12,80,0]],null,3.5,null,!0),new e7(["VAR0 2",[12,80,0]],null,3.5,null,!0),new iP([15,7,6],!1,null,!0),new iP([2,2],!1,null,!0)];
for(var L=0;L<this.Ci.length;L++){var w=this.Ci[L];this.body.appendChild(w.e);if(L>6)w.h("click",this.$p,this)}this.EN=0}fR.prototype=new ff;
fR.prototype.$p=function(w){var n=this.Ci.indexOf(w.target)==7,W=new ed(b.E.v,!0);if(n){if(this.EN==0)return;
W.G=y.Sv;W.data={d:"rot",s7:[2,5],Z:-this.EN}}else{W.G=y.Rp;for(var L=0;L<6;L++)this.Ci[L].$(null)}this.S(W)};
fR.prototype.um=function(w){function n(M,m,l){var A=Math.sqrt(Math.pow(m.x-M.x,2)+Math.pow(m.y-M.y,2)),g=Math.sqrt(Math.pow(m.x-l.x,2)+Math.pow(m.y-l.y,2)),k=Math.sqrt(Math.pow(l.x-M.x,2)+Math.pow(l.y-M.y,2));
return Math.acos((g*g+A*A-k*k)/(2*g*A))}if(w==null)return;this.kn=w;var W=w.anr,D=w.ds,j=D.x-W.x,I=D.y-W.y;
this.EN=-Math.atan2(I,j);if(w.Wh)this.EN=n(D,W,w.Wh);var U=this.Ci;U[0].$(this.qb(w,W.x));U[1].$(this.qb(w,W.y));
U[2].$(this.qb(w,j));U[3].$(this.qb(w,I));U[4].$((this.EN*180/Math.PI).toFixed(2));U[5].$(this.qb(w,ec.cS(W,D)));
if(w.Wh){U[6].$(this.qb(w,ec.cS(W,w.Wh)))}else U[6].$("")};fR.prototype.qb=function(w,n){var W=E.f_.BE(n,w.hh,this.ww,w.akv,!1);
return parseFloat(W).toFixed(2)};fR.prototype.GZ=function(w,n){this.ww=w;this.um(this.kn)};fR.prototype.hp=function(){var w=this.Ci;
for(var L=0;L<w.length;L++)w[L].f();e.We(w[2],w[3])};function bq(){gl.call(this,["brush","strn","pdetail"])}bq.prototype=new gl;
function jK(){gl.call(this,["brush","sfrom"]);this.a5P=[];var w=[[7,12]];for(var L=0;L<w.length;L++){var n=new iP(w[L],!1,null,!0);
this.a5P.push(n);n.parent=this;this.body.appendChild(n.e);n.h("click",this.as1,this)}}jK.prototype=new gl;
jK.prototype.as1=function(w){var n=this.a5P.indexOf(w.currentTarget),W=new ed(b.E.W1,!0);W.data=y.JT.YE("contentAware");
this.S(W)};function fm(){gl.call(this,["brush","strn"])}fm.prototype=new gl;function jy(){gl.call(this,["brush","flow","smode"])}jy.prototype=new gl;
function fa(){ff.call(this);this.Ba=!1;var w=e.t("span","fitem");this.body.appendChild(w);this.R7=new j$(null,["<img src=\""+PIMG.zoomIn+"\" class=\"autoscale gsicon\" />","<img src=\""+PIMG.zoomOut+"\" class=\"autoscale gsicon\" />"]);
w.appendChild(this.R7.e);this.R7.h(b.E.A,this.Of,this);this.Fs=new iP([20,2]);this.body.appendChild(this.Fs.e);
this.Fs.h("click",this.a1W,this);this.Kg=new iP([20,3]);this.body.appendChild(this.Kg.e);this.Kg.h("click",this.a1W,this);
this.Fo=new b7([8,7,1]);this.body.appendChild(this.Fo.e);this.Fo.h(b.E.A,this.Of,this)}fa.prototype=new ff;
fa.prototype.hp=function(){this.Fs.f();this.Kg.f()};fa.prototype.Of=function(){var w={d:b.c.bw,G:this.G,pZ:this.R7.b()==0,j4:this.Fo.b()},n=new ed(b.E.L,!0);
n.data=w;this.S(n)};fa.prototype.um=function(w){if(this.Ba!=w.Ba)this.R7.$(1-this.R7.b());this.Ba=w.Ba};
fa.prototype.a1W=function(w){var n=new ed(b.E.v,!0);n.G=y.Nt;n.data={d:"adapt",Z:w.target==this.Fs?"pixel":"fitscr"};
this.S(n)};function jf(w,n){ff.call(this);if(w==null)return;this.pY=w;this.Tl={};this.acn=n;for(var L=0;
L<w.length;L++){var W=w[L],D=null;if(W=="tmode"){D=new i0(null,[[12,76,1],[12,76,0],[12,76,2]]);D.$(0);
if(n)D.a1y(2)}if(W=="make"){D=new j$("Make",[[17,2],[12,76,1]],null,!0)}if(W=="anta"){D=new b7([12,25,1]);
D.$(!0)}if(W=="binop"){D=new i0(null,[[6,13],[18,1],[18,2],[18,3],[18,4]])}if(W=="pshape")D=new i0(null,[[12,93,0],[12,93,1],[12,93,4],[12,93,2]]);
if(W=="shape")D=new df([12,76,1]);if(W=="crad"){D=new g_([12,94,0],0,50,"px");D.$(0)}if(W=="cstr"){D=new bV}if(W=="irad"){D=new g_([12,94,1],0,100,"%");
D.$(40)}if(W=="length"){D=new g_([12,80,0],4,40);D.$(4)}if(W=="sides"){D=new g_([12,78],3,30);D.$(5)}if(W=="width"){D=new g_([12,41],1,100,"px");
D.$(5)}if(W=="tolr"){D=new g_([12,24],0,100);D.$(5)}if(W=="fstyle"){D=new bc([12,26])}if(W=="sstyle"){D=new fw}if(W=="psnap"){D=new b7([8,10])}if(W=="crnr"){D=new iP("\u2312",!1,[12,94,0],!0)}if(W=="aopts"){D=new bl;
D.$([!1,!1,50,60,0])}D.parent=this;this.body.appendChild(D.e);this.Tl[W]=D;D.h(W=="crnr"?"click":b.E.A,this.Of,this)}}jf.prototype=new ff;
jf.prototype.um=function(w){if(w.K8!=null)this.Tl.binop.$(w.K8);else if(w.vK=="vals")for(var n in w.a17)this.Tl[n].$(w.a17[n]);
else{var W=jf.y2;if(W==null)W=jf.y2=new cA([{name:"Remove Anchor Point",r:function(j){var I=j?j.OV():null;
return{r:j&&I[1].length!=0&&I[0][I[1][0]].add.vmsk.Rw.length!=0}}},{name:"Remove Path",r:function(j){var I=j?j.OV():null;
return{r:j&&I[1].length!=0&&I[0][I[1][0]].add.vmsk.g.length!=0}},nW:!0},{name:"Make Selection"},{name:[2,3]},{name:[14,9]}],[{Y:b.E.v,G:y.Kr,W:{d:"remove",gi:!0}},{Y:b.E.v,G:y.Au,W:{d:"remove"}},{Y:b.E.L,W:{d:b.c.P2,jW:"makesel"}},{Y:b.E.W1,W:y.rK.un(0)},{Y:b.E.W1,W:y.rK.un(1)}]);
W.parent=this;W.update(w.AR,w.Yo);var D=new ed(b.E.L,!0);D.data={d:b.c.Uq,BT:W,x:w.ao.Qc+2,y:w.ao.tc+1};
this.S(D)}};jf.prototype.a00=function(L){return null};jf.prototype.hp=function(){for(var w in this.Tl){this.Tl[w].f()}};
jf.prototype.Of=function(w){var n=new ed(b.E.L,!0),W=this.Tl;if(w.target==W.crnr){n=new ed(b.E.v,!0);
n.G=y.Kr;n.data={d:"crnr"}}else if(w.target==W.make){var L=w.target.b();console.log(L);if(L==0)n.data={d:b.c.P2,jW:"makesel"};
else{n=new ed(b.E.v,!0);n.G=y.K7;n.data={d:"newfill",Y3:0}}}else if(w.target==W.fstyle){n.data={d:b.c.oj,AH:bk.ut,Z:W.fstyle.b()}}else if(w.target==W.sstyle){n.data={d:b.c.oj,AH:bk.Nd,Z:W.sstyle.b()}}else if(w.target==W.tmode){n.data={d:b.c.oj,AH:bk.xo,Z:W.tmode.b()}}else{if(W.pshape)this.Pg();
n.data={d:b.c.bw,G:this.G};for(var D in W)n.data[D]=W[D].b()}this.S(n)};jf.prototype.Pg=function(){var w=this.Tl,n=w.tmode.b(),W=w.pshape?this.a00(w.pshape.b()):this.pY,D;
if(n==0)D=["anta","make"];if(n==1)D=["anta","fstyle","sstyle"];if(n==2)D=["make","binop","fstyle","sstyle"];
var j=w.binop;if(j){var I=j.b();if(n==0){j.aq1(0)}else{j.a1y(0);if(I==0){j.$(1);this.Of({target:j})}}}e._g(this.body);
for(var L=0;L<W.length;L++){var U=W[L];if(D.indexOf(U)!=-1)continue;this.body.appendChild(w[U].e)}};
jf.prototype.GZ=function(w,n){ff.prototype.GZ.call(this,w,n);var W=this.Tl.fstyle,D=this.Tl.sstyle,j=this.Tl.tmode;
if(W)W.GZ(w,n);if(D)D.GZ(w,n);if(n==bk.bI||n==bk.Iv)if(w.Jz.length!=0&&this.Tl.shape){this.Tl.shape.FC(w.Jz)}if(n==bk.bI||n==bk.ut)if(W)W.$(null,w.rg,w.arK);
if(n==bk.bI||n==bk.Nd)if(D)D.$(null,w.jH,w.apY);if(n==bk.bI||n==bk.xo){var I=w.R_;if(this.acn&&I==2)I=0;
if(j){j.$(I);this.Pg()}}};function gt(){jf.call(this,["tmode","make","fstyle","sstyle","binop"],!0)}gt.prototype=new jf;
function fT(){jf.call(this,"tmode make anta fstyle sstyle binop".split(" "))}fT.prototype=new jf;function aT(){jf.call(this,["fstyle","sstyle"]);
this.ayg=null;this.a4o=null;this.a6L=null;this.x6=new i0([12,76,0],[[18,1],[18,2],[18,3],[18,4],[18,5]],[4]);
this.J3=new iP("\u25BC");this.J3.d3();this.Ys=new iP("\u25B2");this.Ys.d3();this.$R=[this.x6,this.J3,this.Ys];
for(var L=0;L<this.$R.length;L++){var w=this.$R[L];this.body.appendChild(w.e);w.parent=this;w.h(L==0?b.E.A:"click",this.WJ,this)}}aT.prototype=new jf;
aT.prototype.um=function(w){if(w._b=="main"){var n=this.$R,W=w.XF;if(W){this.a4o=W.clone();this.a6L=JSON.stringify(w.X);
var D=W.g.slice(0),j=D.length;for(var L=0;L<D.length;L++)D[L]++;D.sort(function(m,l){return m-l});n[0].Te();
n[1].G3(j!=0);n[2].G3(j!=0);n[0].wV(j==0?"No Paths":j==1?"Path "+D[0]:"Paths "+D.slice(0,3).join(",")+(j>3?"..":""));
if(j!=0){var I=W.g[0],U=E.P.tt(W.i,I),M=W.i[U];this.x6.$([3,0,1,2][M.Ht])}}else for(var L=0;L<n.length;
L++)n[L].rx()}else jf.prototype.um.call(this,w)};aT.prototype.hp=function(){jf.prototype.hp.call(this);
this.x6.f()};aT.prototype.WJ=function(w){if(w.target==this.x6||w.target==this.J3||w.target==this.Ys){var n={},W=this.a4o,D=W.i,j=W.g,I=E.P.bB(D),U=JSON.parse(this.a6L);
j.sort(function(O,a){return O-a});if(w.target==this.x6){var M=this.x6.b();if(M<4)for(var L=0;L<j.length;
L++)D[E.P.tt(D,j[L])].Ht=[1,2,3,0][M];else{if(I<=1)return;W.i=E.P.JC(D);W.g=W.i.length==2?[]:[0];W.Rw=[];
U=[E.X.LR()]}}else{var m=w.target==this.J3?-1:1,l=[];for(var L=0;L<I;L++){var A=E.P.tt(D,L),g=A+1+D[A].length;
l.push(D.slice(A,g))}var k=j.slice(0);for(var L=0;L<j.length;L++)k[L]=Math.max(L,Math.min(I-1-(j.length-1-L),k[L]+m));
if(j.join(",")==k.join(","))return;var $=JSON.parse(JSON.stringify(U));for(var L=0;L<j.length;L++){var C=m==-1?L:j.length-1-L,A=j[C],g=k[C];
if(A!=g){var f=l[A];l[A]=l[g];l[g]=f;f=$[A];$[A]=$[g];$[g]=f}}var z=D.slice(0,2);for(var L=0;L<l.length;
L++)z=z.concat(l[L]);W.i=z;W.g=k;U=$}n.XF=W;n.X=U;var s=new ed(b.E.L,!0);s.data={d:b.c.bw,G:this.G,HD:n};
this.S(s)}};function cp(){jf.call(this,["fstyle","sstyle","crnr","psnap"])}cp.prototype=new jf;function dj(){jf.call(this,"tmode make anta fstyle sstyle binop cstr crad".split(" "))}dj.prototype=new jf;
function an(){jf.call(this,"tmode make anta fstyle sstyle binop cstr".split(" "))}an.prototype=new jf;
function hF(){jf.call(this,"tmode make anta fstyle sstyle binop pshape sides irad crad width aopts length".split(" "));
this.Tl.aopts.$([!1,!0,50,60,0])}hF.prototype=new jf;hF.prototype.a00=function(L){var w=[["sides","crad"],["sides","irad","crad"],["width","aopts"],["length"]];
return"tmode make fstyle sstyle binop pshape".split(" ").concat(w[L])};function cE(){jf.call(this,"tmode make anta fstyle sstyle binop width aopts".split(" "))}cE.prototype=new jf;
function hN(){jf.call(this,"tmode make anta fstyle sstyle binop cstr shape".split(" "))}hN.prototype=new jf;
function cO(){gO.call(this,!1,["binop","feat","redge"])}cO.prototype=new gO(!0);function dy(){gl.call(this,["brush","qsmode","redge"])}dy.prototype=new gl;
function eI(){ff.call(this);this.ZW=[];for(var L=0;L<2;L++){var w=new iP(L==0?[8,11,3]:["VAR0...",[15,10,22]],null,null,!0);
this.ZW.push(w);w.h("click",this.WJ,this);this.body.appendChild(w.e)}}eI.prototype=new ff;eI.prototype.WJ=function(w){var n;
if(this.ZW.indexOf(w.target)==0){n=new ed(b.E.W1,!0);n.data={hZ:"make",E3:{__name:"Make",classID:"Mk",null:{t:"obj ",v:[{t:"Clss",v:{classID:"slice"}}]},Usng:{t:"type",v:{classID:"Gd"}}}}}else{n=new ed(b.E.L,!0);
n.data={d:b.c.P2,jW:"divslice"}}this.S(n)};eI.prototype.hp=function(w){for(var L=0;L<this.ZW.length;
L++)this.ZW[L].f()};function hm(){ff.call(this);var w=this.Cx=[new iP("\u25BC",null,null,!0),new iP("\u25B2",null,null,!0),new iP([5,4],null,null,!0),new iP(["VAR0...",[15,10,22]],null,null,!0)];
for(var L=0;L<4;L++){var n=w[L];this.body.appendChild(n.e);n.h("click",this.WJ,this)}}hm.prototype=new ff;
hm.prototype.WJ=function(w){var n=this.Cx.indexOf(w.target),W;if(n==3){W=new ed(b.E.L,!0);W.data={d:b.c.P2,jW:"divslice"}}else{W=new ed(b.E.v,!0);
W.G=y.Od;W.data={d:n==2?"delete":"reorder",dir:n==0?-1:1}}this.S(W)};hm.prototype.f=function(){ff.prototype.f.call(this);
for(var L=0;L<4;L++)this.Cx[L].f()};function js(w,n){ff.call(this);if(window.Typr==null||w)return;this.aig=n;
this.M4=null;this.abH=e.t("span","");this.aa0=e.t("span","");var W=1;this.V7={Zl:new dl(null,24),Sg:new g_("X",0,0,"px",0,!1,!0,4),Be:new g_("Y",0,0,"px",0,!1,!0,4),LS:new g_("W",0,0,["%","px"],2,!1,!0,5),cR:new iP("<img src=\""+PIMG["lrs/link"]+"\" class=\"autoscale gsicon\" />",null,[12,51],null),Ai:new g_("H",0,0,["%","px"],2,!1,!0,5),auk:new g_("\u2221",0,0,"\xB0",W,!1,!0),ar0:new g_("\u25B1 H",-85,85,"\xB0",W,!1,!0),alf:new g_("\u25B1 V",-85,85,"\xB0",W,!1,!0),hb:new i0(null,[[12,14,2],[12,14,3],"Bicubic Sharper"])};
this.V7.hb.$(1);this.V7.cR.$(!0);for(var D in this.V7){var j=this.V7[D];if(n&&(j==this.V7.auk||j==this.V7.ar0||j==this.V7.alf||j==this.V7.hb)){}else this.abH.appendChild(j.e);
var I=j==this.V7.cR?"click":b.E.A;j.h(I,this.aA0,this)}this.Gl=new hJ(!0,!0,!0);this.Gl.h(b.E.A,this.abd,this);
this.Gl.parent=this;var M=this.aa0,m=this.Gl;M.appendChild(m.pf.e);M.appendChild(m.Xx.e);M.appendChild(m.UZ.e);
M.appendChild(m.K0.e);M.appendChild(m.Dy.e);this.ro=new iP([11,9]);this.ro.h("click",this.a3E,this);
this.RD=new c1;this.RD.h("click",this.qO,this)}js.prototype=new ff;js.prototype.um=function(w){if(w.ao){var n=js,W=this.y2;
if(W==null)W=this.y2=new cA(n.ad_(),n.aeS(this.G));W.f();W.parent=this;W.update(w.AR,w.Yo);var D=new ed(b.E.L,!0);
D.data={d:b.c.Uq,BT:W,x:w.ao.Qc+2,y:w.ao.tc+1};this.S(D);return}e._g(this.body);this.M4=w;if(w.V7){var j=w.V7.WH,I=w.V7.GY.clone(),U=Math.atan2(-I.k,I.dl),M=new eh;
M.rotate(-U);I.concat(M);var m=this.V7;m.Zl.$(w.V7.wL);m.Sg.$(w.V7.Q5.x);m.Be.$(w.V7.Q5.y);m.LS.$(I.dl*(m.LS.xm()=="%"?100:j.m));
m.Ai.$(I.j7*(m.Ai.xm()=="%"?100:j.n));m.auk.$(-U*180/Math.PI);m.ar0.$(Math.atan(I.Cj/I.j7)*180/Math.PI);
m.alf.$(0*180/Math.PI);this.body.appendChild(this.abH);this.ro.OD();if(w.V7.yx!=null)m.cR.$(w.V7.yx)}if(w.gz){this.Gl.$(w.gz);
this.body.appendChild(this.aa0);this.ro.d3()}this.body.appendChild(this.RD.e);if(w.apE&&!this.aig)this.body.appendChild(this.ro.e)};
js.prototype.aA0=function(w){var n=this.V7,W=this.M4.V7.WH;if(w.target==n.cR)n.cR.$(!n.cR.b());else if(n.cR.zr()){var D=n.Ai,j=n.LS,I=W.n,U=W.m;
if(w.target==n.LS){D=n.LS;j=n.Ai;I=W.m;U=W.n}var M=D.b()/(D.xm()=="%"?100:I);M*=j.xm()=="%"?100:U;j.$(M)}var m=[];
for(var l in n)if(n[l]!=n.cR&&n[l]!=n.Zl){var M=n[l].b();if((n[l]==n.LS||n[l]==n.Ai)&&M==0){M=.1;n[l].$(M)}if(n[l]==n.LS&&n[l].xm()=="px")M/=W.m/100;
if(n[l]==n.Ai&&n[l].xm()=="px")M/=W.n/100;m.push(M)}var A=new ec(m[0],m[1]);if(w.target==n.Zl){this.nO({_b:"ctyp",wL:n.Zl.b()})}else if(w.target==n.Sg||w.target==n.Be){this.nO({_b:"cen",Q5:A})}else{var g=this.M4.V7.GY.clone(),k=g.clone(),$=Math.atan2(-g.k,g.dl);
k.translate(-A.x,-A.y);k.rotate(-$);var C=new eh(k.dl,k.k,k.Cj,k.j7,0,0);C.Ba();k.concat(C);var f=m[2]/100,z=m[3]/100;
k.concat(new eh(f,f*Math.tan(m[6]*Math.PI/180),z*Math.tan(m[5]*Math.PI/180),z,0,0));k.rotate(-m[4]*Math.PI/180);
k.translate(A.x,A.y);this.M4.V7.GY=k;this.nO({_b:"trn",V7:k,Yk:this.V7.hb.b(),yx:n.cR.b()})}};js.prototype.abd=function(w){this.nO({_b:"wrp",gz:this.Gl.b()})};
js.prototype.a3E=function(w){this.nO({_b:"switchWarp"})};js.prototype.qO=function(w){this.nO({_b:this.RD.b()?"commit":"cancel"})};
js.prototype.nO=function(w){w.d=b.c.bw;w.G=this.G;var n=new ed(b.E.L,!0);n.data=w;this.S(n)};js.prototype.hp=function(){var w=this.V7;
for(var n in w)w[n].f();e.We(w.LS,w.Ai);this.RD.f();this.Gl.f();this.ro.f()};js.ad_=function(){var w=function(n){var W=!0;
if(n==null||n.g.length==0)W=!1;else{var D=n.g;for(var L=0;L<D.length;L++){if(n.C[D[L]].add.TySh)W=!1}}return{r:W}};
return[{name:[5,9],pn:"Shift+Alt+Ctrl + T",nW:!0},{name:[12,38]},{name:[2,5]},{name:[24,4],r:w},{name:[2,9],r:w},{name:[11,9],r:function(n){if(n==null||n.g.length!=1)return{r:!1};
var W=n.C[n.g[0]];return{r:W.add.TySh==null&&!W.ue()}},nW:!0},{name:["VAR0 90\xB0 \u21BB",[2,5]]},{name:["VAR0 90\xB0 \u21BA",[2,5]]},{name:["VAR0 180\xB0",[2,5]]},{name:[[2,6],[22,4,2]]},{name:[[2,6],[22,4,3]]}]};
js.aeS=function(w){if(w==null)w=y.Sv;return[{Y:b.E.v,G:w,W:{d:"again"}},{Y:b.E.L,W:{d:b.c.CV,G:w,LQ:{IZ:3}}},{Y:b.E.L,W:{d:b.c.CV,G:w,LQ:{IZ:4}}},{Y:b.E.L,W:{d:b.c.CV,G:w,LQ:{IZ:2}}},{Y:b.E.L,W:{d:b.c.CV,G:w,LQ:{IZ:1}}},{Y:b.E.L,W:{d:b.c.CV,G:w,LQ:{IZ:-1}}},{Y:b.E.W1,W:y.wR.CO(!0,90,!0)},{Y:b.E.W1,W:y.wR.CO(!0,-90,!0)},{Y:b.E.W1,W:y.wR.CO(!0,-180,!0)},{Y:b.E.W1,W:y.wR.CO(!1,"Hrzn",!0)},{Y:b.E.W1,W:y.wR.CO(!1,"Vrtc",!0)}]};
function er(){js.call(this)}er.prototype=new js(!0);function iT(){js.call(this)}iT.prototype=new js(!0);
function bO(){js.call(this,!1,!0)}bO.prototype=new js(!0);function cM(){ff.call(this);var w=this.pY=[new i0([12,36],["Rigid",[15,10,0],[24,4]]),new i0([12,74],[[19,8,0],[19,8,1],[19,8,2]]),new g_([7,4],0,100,"px"),new b7("Show Mesh"),new iP("\u25BC",null,null,!0),new iP("\u25B2",null,null,!0)];
for(var L=0;L<w.length;L++){var n=w[L];n.parent=this;this.body.appendChild(n.e);n.h(L<4?b.E.A:"click",this.atb,this)}this.RD=new c1;
this.RD.h("click",this.qO,this);this.body.appendChild(this.RD.e)}cM.prototype=new ff;cM.prototype.hp=function(){var w=this.pY;
for(var L=0;L<4;L++)w[L].f();this.RD.f()};cM.prototype.um=function(w){var w=w.AH;for(var L=0;L<4;L++)this.pY[L].$(w[L])};
cM.prototype.atb=function(w){var n=[];for(var L=0;L<4;L++)n[L]=this.pY[L].b();var W=this.pY.indexOf(w.target);
if(W<4)this.nO({_b:"prm",AH:n});else this.nO({_b:"moveDepth",a6G:W==5})};cM.prototype.qO=function(w){this.nO({_b:this.RD.b()?"commit":"cancel"})};
cM.prototype.nO=function(w){w.d=b.c.bw;w.G=this.G;var n=new ed(b.E.L,!0);n.data=w;this.S(n)};function hX(){eg.call(this);
this.e=e.t("div","cmanager");window.alert=function(D,j){this.at2(D,j);console.log("Alert: "+D)}.bind(this);
window.onblur=function(D){var j=this;j.UK()}.bind(this);this.gA=0;this.ag=0;this.FV=[];this.YI={};this.MG=e.t("div","alertcont");
this.e.appendChild(this.MG);this.adq=e.t("div","alertcont");this.e.appendChild(this.adq);this.EX=e.t("div","alertcont");
this.acs=0;this.Nr=-1;this.apt=null;this.ZW=null;var w=this.af6=e.t("div","alertpanel");w.setAttribute("style","padding:0.7em 1em 0.1em 1em;");
this.EX.appendChild(w);var n=this.q1=e.t("input");n.setAttribute("type","text");e.xr(n);n.setAttribute("style","background-color:white; color:black; font-size:1.2em; width:100%; margin:0;");
n.addEventListener("input",this.a2$.bind(this),!1);n.addEventListener("keydown",this.ayF.bind(this),!1);
w.appendChild(n);var W=this.aAp=e.t("div","contextpanel scrollable");W.setAttribute("style","text-align:left; box-shadow:none; margin:0.5em 0 1em 0;color:#888;");
W.addEventListener("click",this.alh.bind(this),!1);w.appendChild(W);e.L_(document.body,this.a47.bind(this))}hX.prototype=new eg;
hX.prototype.a1=function(){if(e.LY(this.EX))this.e.removeChild(this.EX)};hX.prototype.a2G=function(w,n){var W=this.apt=[],D=n.aAm;
for(var L=0;L<hn.data.length;L++){var j=hn.data[L],I=[fV.get(j.name)],U=[L];hX.kU(j.items,I,U,W,w,n,D==null?null:D[L]==null?0:D[L])}var M=ey.a;
for(var L=0;L<M.length;L+=3){if(n.nf&&n.nf.indexOf(M[L+2])==-1)continue;W.push([["Tools",fV.get(M[L])],[-1,M[L+2]],M[L+1]])}this.e.appendChild(this.EX);
var m=this.q1;m.focus();m.select();this.Uc()};hX.prototype.a2$=function(w){this.Nr=-1;this.Uc()};hX.prototype.Uc=function(){var w=this.q1.value.toLowerCase().trim().replace(/ +/g," "),n=this.apt,W=[],D=[],j=w.split(" ");
if(w!="")for(var L=0;L<n.length;L++){var I=n[L][0],U=[],M=0;for(var m=0;m<I.length;m++)U[m]=-1;for(var l=0;
l<j.length;l++)for(var m=0;m<I.length;m++){var A=I[m].toLowerCase().indexOf(j[l]);if(A!=-1){U[m]=[A,A+j[l].length];
M++;break}}if(M==j.length){W.push(n[L]);D.push(U)}}var g=[],k=this.aAp;e._g(k);for(var L=0;L<W.length;
L++){var $=W[L],C=$[0],A=D[L],f="enab",s="";if(L==this.Nr)f+=" active";var z=e.t("div",f);g.push(z);
k.appendChild(z);for(var m=0;m<C.length;m++){var O=A[m],a=j[m],X=C[m];if(O!=-1)X=X.slice(0,O[0])+"<span style=\"color:black\">"+X.slice(O[0],O[1])+"</span>"+X.slice(O[1]);
s+=X;if(m<C.length-1)s+=" \uFE65 "}if($[2]&&(typeof $[2]!="string"||$[2].length==1))s+=" <span style=\"border:1px solid; margin-left:16px; padding:1px 5px; border-radius:5px; background-color:#f4f4f4;\">"+aK.cO($[2])+"</span>";
z.innerHTML=s}this.ZW=[W,g]};hX.prototype.ayF=function(w){var n=aK.$L,W=w.code;if(n(W,aK.QX))this.a1();
var D=n(W,aK.Fe),j=n(W,aK.I$),I=n(W,aK.yG);if(D||j){this.Nr=Math.max(0,Math.min(this.ZW[0].length-1,this.Nr+(D?-1:1)));
this.Uc()}if(I&&this.Nr!=-1)this.aob(this.Nr)};hX.kU=function(w,n,W,D,j,I,U){if(typeof U=="number"){if(U==0)return;
if(U==1)U=null}for(var L=0;L<w.length;L++){if(U!=null&&(U[L]==0||U[L]==null))continue;var M=w[L],m=n.slice(0),l=W.slice(0),A=fV.get(M.name);
if(M.r){var g=M.r(j,I,L);if(g.fP)A=g.fP;if(g.r==!1)continue}m.push(A);l.push(L);if(M.sub)hX.kU(M.sub,m,l,D,j,I,U?U[L]:null);
else D.push([m,l,M.pn])}};hX.prototype.alh=function(w){var n=w.target;if(n.tagName.toLowerCase()=="span")n=n.parentNode;
var W=this.ZW[1].indexOf(n);if(W!=-1)this.aob(W)};hX.prototype.aob=function(w){var n=this.ZW[0][w][1];
if(n[0]==-1){var W=new ed(b.E.L,!0);W.data={d:b.c.CV,G:n[1]};this.S(W)}else{var D=hn.data[n[0]].Zf[n[1]];
for(var L=2;L<n.length;L++)D=D.sub[n[L]];var j=new ed(D.Y,!0);j.G=D.G;j.data=D.W;this.S(j)}this.a1()};
hX.prototype.zl=function(w,n){this.gA=w;this.ag=n;this.aAp.style["max-height"]=n-120+"px"};hX.prototype.aAh=function(w){var n=e.t("div","alertpanel");
n.textContent=fV.get(w);this.MG.appendChild(n);this.YI[JSON.stringify(w)]=n};hX.prototype.aq9=function(w){var n=this.YI[JSON.stringify(w)];
this.MG.removeChild(n);delete this.YI[JSON.stringify(w)]};hX.prototype.at2=function(w,n){var W=this.adq;
for(var L=0;L<W.children.length;L++)if(W.children[L].textContent==w)return;var D=e.t("div","alertpanel tpanel");
D.textContent=w;D.setAttribute("style","opacity:0.5; transform:scale(0.9)\t");W.appendChild(D);if(n==null)n=1500;
var j=n,I=Math.max(Date.now()+j,this.acs+j);setTimeout(function(){D.setAttribute("style","transform:scale(1); opacity:1;")},10);
setTimeout(function(){W.setAttribute("style","margin-top: -3.6em; transform: translateY(3.6em);")},I-Date.now()-30);
setTimeout(function(){W.removeChild(W.firstChild);W.setAttribute("style","transition: transform 0.7s; margin-top: 1em; transform: translateY(0em);")},I-Date.now());
this.acs=I};hX.prototype.a47=function(w){var n=this.FV;for(var L=n.length-1;L>=0;L--){var W=n[L],D=w.target;
while(D!=null){if(D==W.e){this.UK(W);return}D=D.parentNode}}this.UK();var j=w.target;while(j!=this.EX&&j!=document.body)j=j.parentNode;
if(j!=this.EX)this.a1()};hX.prototype.UK=function(w){var n=this.FV;for(var L=0;L<n.length;L++){if(w&&w.a01(n[L]))continue;
var W=n[L].e;if(!(n[L]instanceof cA))e.Qa(n[L],this.e);else this.e.removeChild(W);W.style.height="auto";
e.IX(W,"scrollable");n.splice(L,1);L--}};hX.prototype.ajE=function(w){this.UK(w.BT);var n=w.BT,W=n.e;
if(this.FV.indexOf(n)!=-1)return;this.FV.push(n);this.e.appendChild(W);var D=this.gA,j=this.ag,I=w.x,U=w.y,M=this.e.getBoundingClientRect(),m=n instanceof cA,l=-1,A=j-2;
if(m||w.SR){var g=n.P8(),k=n.aiE();if(m)g=Math.min(g,200);var $=D-g-2,C=j-k-2;if(U<C)l=2;else if(I<$)l=1;
else if(0<U-k-2)l=0;else l=3;if(w.a5y)l=0;if(w.akn)l=2;if(l==2){I=Math.min(I,$)}else if(l==1){U=Math.min(U,C)}else if(l==0){U=U-k-2;
I=Math.min(I,$);A=w.y}else if(l==3){I=I-g-2;U=Math.min(U,C)}}U=Math.max(2,U);var top=Math.round(U-M.y+this.e.offsetTop);
W.style.position="absolute";W.style["z-index"]=10;if(U+n.aiE()>A){W.style.height=A-U+"px";e.W0(W,"scrollable");
if(l==3)I-=10}W.style.left=Math.round(I)+"px";W.style.top=top+"px";if(!(n instanceof cA))e.r3(n)};hX.prototype.awZ=function(w){var n=w.BT,W=this.FV.indexOf(n);
if(W==-1)return;this.FV.splice(W,1);var D=n.e;if(!(n instanceof cA))e.Qa(n,this.e);else this.e.removeChild(n.e)};
hX.prototype.DJ=function(){var w=this.FV;return w.length==0?null:w[w.length-1]};hX.prototype.a02=function(){this.awZ({BT:this.DJ()})};
function fO(){eg.call(this);this.e=e.t("div","confbar")}fO.prototype=new eg;fO.prototype.aau=function(w){w.parent=this;
e._g(this.e);this.e.appendChild(w.e)};function e8(w){eg.call(this);e8.sU=this;e8.rb=w;this.ww=null;this.O8=e.t("input","");
this.O8.setAttribute("type","file");this.O8.setAttribute("multiple","");this.O8.addEventListener("change",function(n){this.Ok(n.target.files,null,this.NX,null);
this.NX=null}.bind(this),!1);document.body.appendChild(this.O8);this.O8.setAttribute("style","display:none");
this.aeu=[];this.C_=!1;this.aez=[];this.WN=!1;this.avT={};this.NX=null}e8.prototype=new eg;e8.rb=null;
e8.mJ=function(w){try{var n={};n[w.type]=w;navigator.clipboard.write([new ClipboardItem(n)])}catch(fV){console.error(fV,fV.message)}};
e8.h6=function(w,n){navigator.clipboard.read().then(function(W){for(var L=0;L<W.length;L++){try{var D=W[L],j={},I=0,U=0;
for(var M=0;M<D.types.length;M++){var m=D.types[M];I++;D.getType(m).then(function(l){var A=m;new Response(l).arrayBuffer().then(function(g){j[this.Y3]=g;
U++;if(U==I)e8.a0S(j,w,n)}.bind({Y3:this.Y3}))}.bind({Y3:m}))}}catch(fV){console.error(fV,fV.message)}}}).catch(function(W){})};
e8.a34=function(w){navigator.permissions.query({name:"clipboard-read"}).then(function(n){w(n.state)})};
e8.a0S=function(w,n,W){var D=["text/plain","image/png","text/html","text/plain"];for(var j in w)console.log(j,j.startsWith("text")?J.KY(new Uint8Array(w[j])).slice(0,100)+"...":w[j]);
for(var I=0;I<D.length;I++){var U=D[I],M=w[U];if(M==null)continue;if(U=="image/png"){e8.rb({name:"image.png"},M,n,W);
return}if(U=="text/plain"){var m=J.KY(new Uint8Array(M));if(I==0)if(!m.startsWith("<!--")&&!m.startsWith("<svg"))continue;
if(W&&m.startsWith("<svg"))continue;var l=new ed(b.E.L,!0);l.data={d:b.c.aoH,Z:m};n.S(l);return}if(U=="text/html"){var m=J.KY(new Uint8Array(M)),A=m.indexOf("src=\"");
if(A!=-1&&m.slice(A+5,A+9)!="http"){var g=A+10;while(m[g]!="\"")g++;var k=m.slice(A+5,g);e8.rb({name:"chart.png"},jj.aL(k).buffer,n,W);
return}}}};e8.prototype.je=function(w){if(w==null)w=[23,5];var n=JSON.stringify(w),W=this.avT;if(W[n]==null)W[n]=0;
if(W[n]==0){var D=new ed(b.E.L,!0);D.data={d:b.c.Ql,mz:w};this.S(D)}W[n]++};e8.prototype.Br=function(w){if(w==null)w=[23,5];
var n=JSON.stringify(w),W=this.avT;if(W[n]==null)W[n]=0;W[n]--;if(W[n]==0){var D=new ed(b.E.L,!0);D.data={d:b.c.SO,mz:w};
this.S(D)}};e8.prototype.amG=function(w,n){this.NX=w;var W=window.showOpenFilePicker;if(W&&window.self==window.top){var D=this;
W({multiple:!0}).then(function(U){var M=[];function m(l){M.push(l);if(M.length==U.length){D.Ok(M,null,D.NX,null,U);
D.NX=null}else U[M.length].getFile().then(m)}U[M.length].getFile().then(m)});return}var j=this.O8;if(n)j.setAttribute("accept",n);
else j.removeAttribute("accept");var I=document.createEvent("MouseEvents");I.initMouseEvent("click",!0,!0,document.defaultView,1,0,0,0,0,!1,!1,!1,!1,0,null);
j.dispatchEvent(I)};e8.prototype.e5=function(w){if(w.url.indexOf("photopea.com#i")!=-1||w.url.indexOf("photopea.com/#i")!=-1){this.BH(w.url.split("#i").pop());
return}this.aeu.push(w);this.a0$()};e8.prototype.a0$=function(){var w=this.aeu;if(w.length==0||this.C_)return;
this.C_=!0;var n=w.shift();this.je();if(n.BX==null)n.BX={};var W=new XMLHttpRequest;W.oo=n;var D=n.url;
if(n.AM&&!D.startsWith("data:image"))D=(D);W.open("GET",D);if(n.$_)for(var j in n.$_)W.setRequestHeader(j,n.$_[j]);
W.responseType="arraybuffer";W.onload=this.at4.bind(this);W.send()};e8.prototype.Ok=function(w,n,W,D,j){for(var L=0;
L<w.length;L++){this.je();var I=w[L],U=new FileReader;U.oo=I;U.oo.ev=W;U.oo.Ze=D;U.aoS=n;if(j)U.oo.YX=j[L];
U.onload=this.at4.bind(this);U.onerror=function(M){this.Br()}.bind(this);this.aez.push([U,I])}this.O8.value=null;
this.ajK()};e8.prototype.ajK=function(){var w=this.aez;if(w.length==0||this.WN)return;this.WN=!0;var n=w.shift();
n[0].readAsArrayBuffer(n[1])};e8.prototype.a7U=function(w,n,W){this.je("Saving ...");this.ww=n;setTimeout(W.bind({Pk:w,caller:this}),50)};
e8.vT=function(w){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",W=new Uint8Array(w),D=W.length,j=D%3,I=D-j,U=[],M=0,m=0,l=0;
for(var L=0;L<I;L+=3){M=W[L];m=W[L+1];l=W[L+2];U.push(n[M>>2]+n[(M&3)<<4|m>>4]+n[(m&15)<<2|l>>6]+n[l&63])}if(j==1){M=W[I];
U.push(n[M>>2]+n[(M&3)<<4]+"==")}if(j==2){M=W[I];m=W[I+1];U.push(n[M>>2]+n[(M&3)<<4|m>>4]+n[(m&15)<<2]+"=")}var A=U.join("");
return A};e8.ao9=function(w,n){var W="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",D=new Uint8Array(64),M=0,m=0,l=0,g=0;
for(var L=0;L<64;L++)D[L]=W.charCodeAt(L);var j=new Uint8Array(w),I=n%3,U=n-I,A=new Uint8Array(Math.floor(n/3)*4+(I==0?0:4));
for(var L=0;L<U;L+=3){M=j[L];m=j[L+1];l=j[L+2];A[g]=D[M>>>2];A[g+1]=D[(M&3)<<4|m>>>4];A[g+2]=D[(m&15)<<2|l>>>6];
A[g+3]=D[l&63];g+=4}if(I==1){M=j[U];A[g]=D[M>>2];A[g+1]=D[(M&3)<<4];A[g+2]=61;A[g+3]=61}if(I==2){M=j[U];
m=j[U+1];A[g]=D[M>>2];A[g+1]=D[(M&3)<<4|m>>4];A[g+2]=D[(m&15)<<2];A[g+3]=61}return A};e8.prototype.at4=function(w){var n,W=w.target.oo;
if(w.target instanceof XMLHttpRequest)n=w.target.response;else n=w.target.result;e8.rb(W,n,this,w.target.aoS);
this.Br();if(w.target instanceof XMLHttpRequest){this.C_=!1;this.a0$()}else{this.WN=!1;this.ajK()}};
e8.a6r=function(w,n){var W=new XMLHttpRequest;W.open("POST","https://api.imgur.com/3/image",!0);W.Xm=n;
W.setRequestHeader("Authorization","Client-ID 3ad80d2d9969219");W.setRequestHeader("Content-type","application/x-www-form-urlencoded");
W.setRequestHeader("Accept","application/json");W.addEventListener("load",e8.ack);W.send("type=base64&image="+encodeURIComponent(e8.vT(w)));
alert("Saving to Imgur ...",4e3)};e8.ack=function(w){var n=JSON.parse(w.target.response);if(n.success){if(w.target.Xm)w.target.Xm(n.data.link);
else window.open(n.data.link,"Imgur")}};e8.prototype.BH=function(w,n,W){this.je();var D=new XMLHttpRequest;
D.responseType="arraybuffer";D.open("GET","https://f000.backblazeb2.com/file/"+(W?"pp-resources":"psdshared")+"/"+w);
D.onload=this.ax_.bind(this);D.send();D.kn=[Date.now(),w,n?w:null,W]};e8.prototype.ax_=function(w){var n=w.target.kn,W=new Uint8Array(w.target.response);
console.log(W.length+" B,",Date.now()-n[0]+" ms");for(var L=0;L<W.length;L++)W[L]=255-W[L];W=pako.inflateRaw(W);
var D=JSON.parse(J.KY(W,0,2e3));e8.rb({name:D.name,wW:n[2]},W.slice(2e3).buffer,this);this.Br();if(!n[3])e8.iT("act=0&id="+n[1])};
e8.prototype.amv=function(w,n,W,D){if(!(w instanceof ArrayBuffer))throw"e";w=new Uint8Array(w);var j=new Uint8Array(w.length+2e3),k="";
for(var L=0;L<2e3;L++)j[L]=32;J.Dj(JSON.stringify({name:n}),j,0);j.set(w,2e3);w=j;w=pako.deflateRaw(w);
for(var L=0;L<w.length;L++)w[L]=255-w[L];w=w.buffer;var I=w.byteLength,U=fp.cN(I),M=~~(609e5/2),m=~~(209e5/2);
if(I>M){confirm("Your file is "+U+". Our limit is "+fp.cN(M)+". Delete some layers and try again.");
return}if(I>m){var l=confirm("Your file is quite large ("+U+"). Opening it will take a lot of time. Do you still want to proceed?");
if(!l)return}var A=sha1(w),g=[];for(var L=0;L<20;L++){var $=parseInt(A.slice(L*2,L*2+2),16);g.push($);
k+=String.fromCharCode($)}var C=btoa(k).replace(/\+/g,"-").replace(/\//g,"_").slice(0,8);if(e8.ali(C,D)){console.log("file already exists");
if(W)W(C);else window.open("https://www.photopea.com#i"+C+".psd");return}this.je("Publishing ...");var f=new XMLHttpRequest;
f.kn=[w,A,C,W,D];f.open("GET","/papi/img/publish.php?rnd="+Math.random()+"&id="+C+"&size="+I+"&bname="+D);
f.onload=this.afU.bind(this);f.send()};e8.ali=function(w,n){try{var W=new XMLHttpRequest;W.open("HEAD","https://f000.backblazeb2.com/file/"+n+"/"+w,!1);
W.send();if(W.status==200)return!0}catch(fV){return!1}return!1};e8.prototype.afU=function(w){console.log(w.target.response);
var n=JSON.parse(w.target.response),W=w.target.kn,D=new XMLHttpRequest;D.open("POST",n.uploadUrl);D.setRequestHeader("Authorization",n.authorizationToken);
D.setRequestHeader("X-Bz-File-Name",W[2]);D.setRequestHeader("Content-Type","b2/x-auto");D.setRequestHeader("X-Bz-Content-Sha1",W[1]);
D.send(new Blob([W[0]]));D.onload=this.aty.bind({xh:this,kn:W})};e8.prototype.aty=function(w){this.xh.Br("Publishing ...");
if(this.kn[3])this.kn[3](this.kn[2]);else window.open("https://www.photopea.com#i"+this.kn[2]+".psd");
if(this.kn[4]=="psdshared")e8.iT("act=2&id="+this.kn[2]+"&fileId="+JSON.parse(w.target.response).fileId)};
e8.iT=function(w){var n=new XMLHttpRequest;n.open("GET","/papi/img/update.php?"+w+"&rnd="+Math.random());
n.send()};e8.save=function(w,n){var W=new Uint8Array(w),D=document.createElement("a");if(typeof D.download=="string"){var j=new Blob([W]),I=window.URL.createObjectURL(j);
D.href=I;D.download=n;document.body.appendChild(D);D.click();document.body.removeChild(D)}else{var U="data:application/octet-stream;base64,"+e8.vT(w);
window.open(U)}};function cs(){this.size=16;this.data=E.Q(16)}cs.prototype.lN=function(w,n){if(w+n<=this.size)return;
var W=this.size;while(w+n>this.size)this.size*=2;var D=E.Q(this.size);for(var L=0;L<W;L++)D[L]=this.data[L];
this.data=D};var g1={};g1.B8=function(w,n,W,D){var j=n.split(":"),I=j[0];if(j.length==2){if(I=="jpg")D=[Math.round(100*parseFloat(j[1]))];
if(I=="webp")D=[Math.round(100*parseFloat(j[1])),100,0,!1,!1];if(I=="psd")D=[!0,!0,!1,!1,!1];if(I=="svg")D=j[1].split(",").map(function(M){return M=="true"})}var U=jj.rk(w,I.toUpperCase(),null,null,D,W);
return U};g1.aqI=function(w,n,W){var D=w.Vc(),j=n[0];return g1.B8(w,j,W)};g1.aAx=function(){var w=this.Pk,n=this.caller,W=w.BX.nN,D=W.formats,j,I;
w.Vc();var U=Date.now();if(W.version==1){var M=[],m=0,A=0;for(var L=0;L<D.length;L++){var l=g1.B8(w,D[L],n.ww);
M.push(l);m+=l.byteLength}j=new Uint8Array(2e3+m);var g="{ \"source\": "+JSON.stringify(w.ea)+", \"versions\": [\n";
for(var L=0;L<D.length;L++){var k=new Uint8Array(M[L]);g+="\t{\"format\": \""+D[L].split(":")[0]+"\", \"start\": "+A+", \"size\": "+k.length+" }"+(L+1<D.length?", ":"")+"\n";
j.set(k,2e3+A);A+=M[L].byteLength}g+="] }";var $=J.Dj(g,j,0);for(var L=$;L<2e3;L++)j[L]=32;I="application/octet-stream"}else{var C=new cs,f=0,z="",s=encodeURIComponent;
z="p="+s("{ \"source\": "+JSON.stringify(w.ea)+", \"versions\": [");J.YY(C,f,z);f+=z.length;for(var L=0;
L<D.length;L++){z=s(" {\"format\": \""+D[L].split(":")[0]+"\", \"data\": \"");J.YY(C,f,z);f+=z.length;
var l=g1.B8(w,D[L],n.ww),O=e8.ao9(l,l.byteLength),$=O.length;C.lN(f,$);for(var a=0;a<$;a++){C.lN(f,3);
var X=O[a];if(X==43){C.data[f]=37;C.data[f+1]=50;C.data[f+2]=66;f+=3}else if(X==47){C.data[f]=37;C.data[f+1]=50;
C.data[f+2]=70;f+=3}else if(X==61){C.data[f]=37;C.data[f+1]=51;C.data[f+2]=68;f+=3}else{C.data[f]=X;
f++}}z=s("\" }"+(L+1<D.length?", ":""));J.YY(C,f,z);f+=z.length}z=s("] }");J.YY(C,f,z);f+=z.length;j=C.data.slice(0,f);
I="application/x-www-form-urlencoded"}var P=new XMLHttpRequest;P.open("POST",W.url,!0);if(I)P.setRequestHeader("Content-Type",I);
P.addEventListener("load",g1.akF.bind(this));P.send(new Blob([j.buffer]))};g1.akF=function(w){this.caller.Br("Saving ...");
var n=w.target.response;if(n.charAt(0)=="{"){n=JSON.parse(n);if(n.newSource)this.Pk.ea=n.newSource;if(n.message)alert(n.message,2e3);
if(n.script){var W=new ed(b.E.L,!0);W.data={d:b.c.zM,wx:n.script};this.caller.S(W)}}else alert("Saved. Response: "+n,1500)};
g1.arJ=function(w){var n=w.Il,W=n[1].split(".").pop(),D=g1.B8(w,W,null,W=="psd"&&n[0]==1?[!0,!1,!0,!1]:null);
console.log(D);var j=Storage.ED(n[0]);j.agQ(n[1],D)};g1.amP=function(w,n){var W=w.Kh.q5;if(n==null)n=g1.B8(w,W);
e3.m_(function(){var D=new XMLHttpRequest,j="https://www.googleapis.com/upload/drive/v3/files/"+w.Kh.file.id+"?uploadType=media"+"&"+e3.HK();
D.open("PATCH",j,!0);D.addEventListener("load",function(I){var U=JSON.parse(I.target.response);alert(U.name+" updated")});
D.send(n);alert("Saving \""+w.Kh.file.name+"\" to Google Drive ...")})};g1.rb=function(w,n,W,D){if(window.location.href.indexOf("photopea.com")==-1||window.top!=window.self)g1.aj0(w,n,W,D);
else{try{g1.aj0(w,n,W,D)}catch(fV){if(fV=="low_ram"){}else{var j="Error. Please, send your file to support@photopea.com and we will solve it.";
if(jj.zJ(n)=="eps")j="We support only basic EPS files. Convert your file into PDF (with an online converter) and open the PDF in Photopea.";
alert(j,1e4)}}}};g1.aj0=function(w,n,W,D){var j;if(w.name){var I=w.name.lastIndexOf(".");j=I==-1?w.name:w.name.slice(0,I)}else{if(w.url.substring(0,5)=="data:"||w.url.indexOf("googleapis")!=-1)j="image";
else j=w.url.substring(w.url.lastIndexOf("/")+1).split(".")[0];j=j.slice(0,50)}var U=w.name?w.name:w.url,M=new Uint8Array(n),m=jj.zJ(n),l=window.gtag;
if(Math.random()<.25&&l&&m!=null&&jj.ZO(m))l("event",m,{event_category:"Formats"});if(m==null)m=J.sv(M,0,4);
if(U&&U.toLowerCase().endsWith(".raw")){var A=new ed(b.E.L,!0);A.data={d:b.c.P2,jW:"importraw",AY:n,O7:U.split("/").pop()};
W.S(A);return}else if(m=="json"){var g="";for(var L=0;L<M.length;L++)g+=String.fromCharCode(M[L]);g=decodeURIComponent(escape(g));
var k=JSON.parse(g);if(k.name&&k.url){var A=new ed(b.E.L,!0);A.data={d:b.c.aeR,Z:k};W.S(A)}else{alert("Unknown JSON file opened. See the content in the console.",5e3);
console.log(k)}return}if(m=="html"){var g=J.KY(M,0,M.length),$=new DOMParser,C=$.parseFromString(g,"text/html"),f=C.getElementsByTagName("meta");
for(var L=0;L<f.length;L++){var s=f[L],O=s.getAttribute("property"),a=s.getAttribute("content"),X=null;
if(O=="og:image")X=a;if(O==null&&a&&a.startsWith("0;url=/imgres?")){var P=a.slice(14).split("&");for(var Z=0;
Z<P.length;Z++)if(P[Z].startsWith("imgurl"))X=decodeURIComponent(P[Z].slice(7))}if(X==null)continue;
var A=new ed(b.E.L,!0);A.data={d:b.c.VR,AH:{url:X,AM:!0,ev:w.ev}};W.S(A)}return}if(jj.ZO(m)){var Y,K,S=jj.ZO(m);
if(w.ev!=null&&"jpg png gif pdf svg ai psd".split(" ").indexOf(m)!=-1){var A=new ed(b.E.L,!0);if(0<=w.ev)A.data={d:b.c.l9,target:w.ev,XT:w.Ze,On:n,HS:j};
else{A=new ed(b.E.v,!0);A.data={d:h.v4,data:new Uint8Array(n),O7:j+"."+m};A.G=y.Yu}W.S(A);return}var G=[j,S,m,w,W,D,n];
if(S.Xq){Y=new kc(j+(m=="psd"?"":"-"+m)+".psd");S.Vu(n,Y,g1.vh,G)}else{K=S.Vu(n,null,g1.vh,G,W)}if(S.MA!=!0)g1.vh(Y,K,G);
else W.je();return}var V=new ed(b.E.L,!0);V.data={d:b.c.D7,AY:n,I6:w.name};var T=w instanceof File&&w.anz!=!0,A=new ed(b.E.L,!0);
A.data={d:b.c.oj,BX:"add",AH:null,O2:null,ahH:w.anz};if(m=="zip"){var R=Date.now(),x=UZIP.parse(n),v="xml rels plist iwa db ds_store txt rtf".split(" ");
for(var N in x){var u=!1;for(var L=0;L<v.length;L++)if(N.toLowerCase().endsWith("."+v[L]))u=!0;if(N.startsWith("__MACOSX/")||x[N].length==0)u=!0;
if(u)continue;var H=N.split("/").pop();g1.rb({name:H},x[N].buffer,W,D)}}else if(m=="jsx"||U&&U.toLowerCase().endsWith(".jsx")){var g=J.KY(new Uint8Array(n));
A.data={d:b.c.zM,wx:g};W.S(A)}else if(m=="otf"){if(T)W.S(V);var F=Typr.parse(n);A.data.AH=bk.v3;for(var L=0;
L<F.length;L++){A.data.O2=F[L];W.S(A)}}else if(m=="asl"){if(T)W.S(V);var F=bt.ew(n);A.data.AH=bk.C0;
A.data.O2=F.ID;W.S(A);A.data.AH=bk.gB;A.data.O2=F.GM;W.S(A)}else if(m=="tpl"){if(T)W.S(V);var F=kt.ew(n);
A.data.AH=bk.zq;A.data.O2={yg:F.yg,j6:F.j6,list:[]};W.S(A);if(F.ad1.length!=0){A.data.AH=bk.Iv;A.data.O2=F.ad1;
W.S(A)}if(F.GM.length!=0){A.data.AH=bk.gB;A.data.O2=F.GM;W.S(A)}A.data.AH=bk.Q6;A.data.O2=F.list;W.S(A)}else{var t="";
for(var o in bk.Fj)if(bk.Fj[o][0]==m)t=o;if(t!=""){if(T)W.S(V);A.data.O2=bk.Fj[t][2].ew(n,U);A.data.AH=t;
W.S(A)}else if(n.byteLength==0)alert("Empty file (0 Bytes)");else alert("Unknown file format: "+JSON.stringify(m))}};
g1.vh=function(w,n,W){var D=W[0],j=W[1],I=W[2],U=W[3],M=W[4],m=W[5],l=W[6];if(j.MA)M.Br();if(!j.Xq){if(n.length==0)return;
if(n[0].t33421||n[0].t50706){E.raw.normalize(n[0],l);console.log(n[0]);var A=new ed(b.E.L,!0);A.data={d:b.c.P2,jW:"rawpea",p0:n[0]};
M.S(A);return}if(m){m(new Uint8Array(n[0].data),n[0].XL);return}w=jj.Dk(D,n)}w.wW=U.wW;w.Mc=I;w.BX=U.BX;
w.ea=U.url;w.gN=U.gN;w.Kh=U.Kh;w.YX=U.YX;w.Il=U.Il;if(w.Kh)w.Kh.q5=I;if(w.C.length!=0){var A=new ed(b.E.L,!0);
A.data={d:U.ev==null?b.c.dH:b.c.l9,target:U.ev,XT:U.Ze,On:w};M.S(A)}};function g9(w){eg.call(this);this.kz=g9.kz++;
this.ZK=w;this.a4g=this.akz.bind(this);this.af_=this.a6R.bind(this);this.acJ=this.uT.bind(this);this.a5c=this.agR.bind(this);
this.aai=this.alN.bind(this);this.atO=this.aeE.bind(this);this.VA=0;this.a4V=0;this.ae4=0;this.e=e.t("div","panelblock");
this.K5=e.t("div","block");this.CB=e.t("div","collapsed");this.e.appendChild(this.K5);this.JV=-1;this.Ex=!0;
this.s0=e.t("div","panelhead");this.K5.appendChild(this.s0);this.vD(this.s0);this.tE=new iP("\u2261");
this.tE.e.setAttribute("style","position:absolute; right:0;");this.tE.h("click",this.auJ,this);this.yd=e.t("div","body");
this.K5.appendChild(this.yd);this.Qf=[];this.nE=null;this.xE=null}g9.kz=0;g9.prototype=new eg;g9.tW=26.1;
g9.prototype.auJ=function(w){var n=this.Qf[this.JV].GS(),W=w.currentTarget.e.getBoundingClientRect();
n.f();n.update();n.parent=this;var D=new ed(b.E.L,!0);D.data={d:b.c.Uq,BT:n,x:W.left,y:W.top+W.height+2};
this.S(D)};g9.prototype.AN=function(w){var n=this.K5,W=this.s0,D=this.yd;if(e.LY(W))n.removeChild(W);
if(e.LY(D))n.removeChild(D);if(w==0)n.appendChild(W);n.appendChild(D);this.ae4=w};g9.oz=function(w){w.stopPropagation();
w.preventDefault()};g9.prototype.akz=function(w){var n=w.dataTransfer.types;if(n[1]!=null&&n[1]!=this.kz+"")return;
g9.oz(w);var bK=w.currentTarget;if(w.target==bK)e.W0(bK,"highlight")};g9.prototype.a6R=function(w){g9.oz(w);
var bK=w.currentTarget;if(w.target==bK)e.IX(bK,"highlight")};g9.prototype.vD=function(w){w.addEventListener("dragenter",this.a4g,!1);
w.addEventListener("dragleave",this.af_,!1);w.addEventListener("dragover",g9.oz,!1);w.addEventListener("drop",this.acJ,!1);
w.addEventListener("dragstart",function(n){n.dataTransfer.setData("Text","--panel");n.dataTransfer.setData(this.kz+"","")}.bind(this),!1)};
g9.prototype.uT=function(w){this.af_(w);var n=null,bK=w.currentTarget,W=this.abf(bK);if(bK==this.yd&&this.JV!=-1)n=this.JV;
else if(bK==this.s0)n=null;else if(W!=-1)n=W;var D=w.dataTransfer.getData("Text");if(D==""||D.startsWith("http"))e.ri(w,this,n);
else if(D=="--panel"){var j=e.rv(w,bK),I=this.Qf,U=I.slice(0),L=this.JV,M=W==-1?I.length:j.x<bK.getBoundingClientRect().width/2?W:W+1;
if(L==M||L+1==M||bK==this.yd)return;var m=L<M?M-1:M,l=I[L];I.splice(L,1);I.splice(m,0,l);e._g(this.s0);
for(var A=0;A<I.length;A++)this.s0.appendChild(I[A].Uh);this.Rx(m);var g=[];for(var L=0;L<I.length;L++)g[L]=U.indexOf(I[L]);
var k=new ed("shuffleItems",!1);k.data={aof:g};this.S(k)}else if(n!=null&&this instanceof iF){var k=new ed(b.E.L,!0);
k.data={d:b.c.a1B,ars:n};this.S(k)}};g9.prototype.n3=function(){return null};g9.prototype.amR=function(){if(this.n3()){this.s0.style.padding="0px";
this.xE=this.n3();this.yd.appendChild(this.xE);this.N3.G3(!1);var w=new ed(b.E.L,!0);w.data={d:b.c.sa,Z:1};
this.S(w)}};g9.prototype.amw=function(){if(this.xE){this.s0.style.padding="";this.yd.removeChild(this.xE);
this.xE=null;this.N3.G3(!0);var w=new ed(b.E.L,!0);w.data={d:b.c.sa,Z:0};this.S(w)}};g9.prototype.abf=function(w){var n=this.Qf;
for(var L=0;L<n.length;L++)if(n[L].Uh==w)return L;return-1};g9.prototype.ug=function(){for(var L=0;L<this.Qf.length;
L++)this.Qf[L].Zo.OD()};g9.prototype.wz=function(){return this.JV};g9.prototype.CS=function(){if(this.Ex)return;
this.Ex=!0;this.e.removeChild(this.CB);this.e.appendChild(this.K5)};g9.prototype.collapse=function(){if(!this.Ex)return;
this.Ex=!1;this.e.appendChild(this.CB);this.e.removeChild(this.K5)};g9.prototype.tW=function(){var w=0;
if(this.ae4==0){w=this.s0.getBoundingClientRect().height+1;w=Math.max(w,g9.tW)}return w};g9.prototype.arh=function(){return this.tW()+this.yd.getBoundingClientRect().height};
g9.prototype.zl=function(w,n){this.s0.style.maxWidth=w+"px";var W=this.tW();if(this.JV!=-1)this.Qf[this.JV].zl(w,n-W);
return n-W};g9.prototype.GZ=function(w,n){if(this.JV!=-1)this.Qf[this.JV].GZ(w,n)};g9.prototype.mQ=function(w,n,W){this.Qf[this.JV].mQ(w,n,W)};
g9.prototype.f9=function(w){this.amw();if(this.Qf.indexOf(w)!=-1){this.Rx(this.Qf.indexOf(w));return}w.parent=this;
this.Qf.push(w);this.s0.appendChild(w.Uh);w.Uh.addEventListener("mouseover",this.a5c,!1);this.vD(w.Uh);
this.CB.appendChild(w.Zo.e);w.Zo.h("click",this.ayo,this);w.h("select",this.atP,this);w.h(b.E.gh,this.azY,this);
this.Rx(this.Qf.length-1)};g9.prototype.agR=function(w){if(w.buttons==0)return;var n=w.currentTarget,W=n,L=0;
while((W=W.previousSibling)!=null)L++;this.a4V=L;n.addEventListener("mouseout",this.aai,!1);this.VA=setTimeout(this.atO,700)};
g9.prototype.alN=function(w){var n=w.currentTarget,W=n,L=0;while((W=W.previousSibling)!=null)L++;n.removeEventListener("mouseout",this.aai);
clearTimeout(this.VA)};g9.prototype.aeE=function(w){this.S(new ed(b.E.aeI,!1))};g9.prototype.a6I=function(w){return this.a4V};
g9.prototype.kk=function(L){var w=new ed(b.E.gh,!1);w.data={tH:L};this.S(w);var n=this.Qf[L];this.Qf.splice(L,1);
this.s0.removeChild(n.Uh);this.CB.removeChild(n.Zo.e);n.Uh.className="";n.Zo.removeEventListener("click",this.ayo,this);
n.Zo.OD();n.removeEventListener("activate",this.atP);n.removeEventListener(b.E.gh,this.azY);var W=this.JV;
if(L<W)W--;else if(L==W&&L==this.Qf.length)W--;this.Rx(W);if(this.Qf.length==0)this.amR()};g9.prototype.at1=function(){return this.Qf.length};
g9.prototype.K3=function(){if(this.Qf.length!=0)this.Qf[this.JV].K3()};g9.prototype.Rx=function(w,n){if(n==null)n=!0;
for(var L=0;L<this.Qf.length;L++)this.Qf[L].Uh.className="";if(this.nE)this.yd.removeChild(this.nE);
this.nE=null;this.JV=w;if(w==-1)return;var W=this.Qf[this.JV];this.nE=W.h_;this.yd.appendChild(W.h_);
W.Uh.className="active";if(!this.Ex){this.S(new ed("showFloat"));this.Qf[w].Zo.d3()}if(n)this.S(new ed(b.E.A,!1));
W.c2();var D=this.tE.e;if(D.parentNode)this.s0.removeChild(D);if(W.GS())this.s0.appendChild(D);var j=new ed(b.E.L,!0);
j.data={d:b.c.aR};this.S(j)};g9.prototype.atP=function(w){if(this.ZK&&!this.ZK.agq())return;var L=this.Qf.indexOf(w.currentTarget);
this.Rx(L)};g9.prototype.azY=function(w){if(this.ZK&&!this.ZK.agq())return;var L=this.Qf.indexOf(w.currentTarget);
this.kk(L)};g9.prototype.ayo=function(w){var n=this.Qf.indexOf(w.currentTarget.parent);if(this.Qf[n].Zo.zr())this.S(new ed("hideFloat"));
else this.Rx(n)};g9.prototype.a3S=function(w){this.S(w)};function iF(w){g9.call(this,w);this.gA=0;this.ag=0;
e.d6(this.s0,this.aoz.bind(this));this.SL=0;this.axj=this.ash.bind(this);this.vD(this.yd);this.zn=["default;"];
this.N3=new e.BC(this.yd);this.Ac=new hf(!0);this.Ac.parent=this;this.wv=this.Ac.e;hf.GV(this.Ac)}iF.prototype=new g9;
iF.prototype.aoz=function(w){if(w.target!=this.s0)return;var n=this.SL;this.SL=Date.now();if(Date.now()-n>300)return;
var W=new ed(b.E.L,!0);W.data={d:b.c.P2,jW:"newproject"};this.S(W)};iF.prototype.$J=function(w,n){if(n)this.zn.push(w);
else{var W=this.zn.length-1;if(this.zn[W]==w)return;this.zn[W]=w}this.zV()};iF.prototype.axX=function(){this.zn.pop();
this.zV()};iF.prototype.zV=function(){var w=this.zn[this.zn.length-1];this.N3.mQ(w,this.V2)};iF.prototype.GZ=function(w,n){g9.prototype.GZ.call(this,w,n);
this.Ac.GZ(w,n);if(!w.aE){}};iF.prototype.f=function(){g9.prototype.f.call(this);this.Ac.f()};iF.prototype.mQ=function(w,n){for(var L=0;
L<n.length;L++){var W=n[L];this.Qf[L].UG(W.name+(W.VO()?" *":""))}g9.prototype.mQ.call(this,w,n)};iF.prototype.n3=function(){return this.wv};
iF.prototype.zl=function(w,n){if(this.Qf.length==0)n+=g9.tW-1;this.gA=w;this.ag=n;n=g9.prototype.zl.call(this,w,n);
this.V2="height:"+n+"px; width:"+w+"px; overflow:hidden; position:relative;";this.zV();this.Ac.zl(w,n)};
iF.prototype.f9=function(w){g9.prototype.f9.call(this,w);w.Uh.addEventListener("click",this.axj,!1)};
iF.prototype.kk=function(L){var w=this.Qf[L];e.i_(w.Uh,this.axj);g9.prototype.kk.call(this,L)};iF.prototype.ash=function(w){var n=this.SL;
this.SL=Date.now();if(Date.now()-n>300)return;var W=this.abf(w.currentTarget),D=this.Qf[W].On.name,j=new ed(b.E.L,!0),I={Y:b.E.v,G:y.Yu,W:{d:h.w2}};
j.data={d:b.c.P2,jW:"namewindow",Z1:D.slice(0,D.length-4),j2:I};this.S(j)};function jB(w){eg.call(this);
if(w)return;hp.aoC(1);this.e=e.t("div","flexrow app");this.Y$=e.t("div");this.e.appendChild(this.Y$);
setTimeout(function(){var W=window.hideCap;if(W)W()},25e3);this._0=new aK;window.addEventListener("blur",function(W){this._0.reset()}.bind(this),!1);
window.addEventListener("resize",this._K.bind(this),!1);var n=this.Y$;this.El=new g2;this.El.parent=this;
n.appendChild(this.El.e);this.lt=new hX;this.lt.parent=this;n.appendChild(this.lt.e);this.ML=new g8(!0);
this.ML.parent=this;n.appendChild(this.ML.e);this.h(b.E.L,this.w4,this);this.io=this.Lm.bind(this);window.requestAnimationFrame(this.io)}jB.prototype=new eg;
jB.prototype.Lm=function(w){this.Yr();window.requestAnimationFrame(this.io)};jB.prototype.f=function(){};
jB.prototype._K=function(w){var n=window.innerWidth,W=window.innerHeight;this.zl(n,W)};jB.prototype.zl=function(w,n){this.lt.zl(w,n);
this.El.zl(w,n)};jB.prototype.w4=function(w){var n=w.data.d;if(n==b.c.Uq)this.lt.ajE(w.data);if(n==b.c.Eb)this.lt.awZ(w.data);
if(n==b.c.Ql)this.lt.aAh(w.data.mz);if(n==b.c.SO)this.lt.aq9(w.data.mz);if(n==b.c.xl)this.lt.UK()};function hB(){jB.call(this);
this.gC={x:0,y:0,WS:!1};this.Yv=!1;this.Y4=!1;this.q_=null;this.as4=0;this.al7=!1;this.ft=0;window.onmessage=function(z){if(Storage.auf(z.source))return;
if(z.data instanceof ArrayBuffer){var s=jj.zJ(z.data),O=jj.ZO(s);e8.rb({url:"file"},z.data,this);if(O==null)this.KU()}else if(z.data instanceof Object||z.data.startsWith("{")||z.data.startsWith("amp-")||z.data.startsWith("0=goog")||z.data.startsWith("3PCoo")){}else if(z.data.startsWith("--ur ")){var a=z.data.split(" ").pop(),S=null;
a=a.length==0?[]:a.split(",");console.log(a);var X=this.Ir.O2,P=new ed(b.E.L,!0);P.data={d:b.c.oj,AH:bk.ad,qY:a};
this.S(P);var Z=a,Y=X;if(Y.length>Z.length){var K=Y;Y=Z;Z=K}for(var L=0;L<Z.length;L++)if(Y.indexOf(Z[L])==-1)S=Z[L];
e8.iT("act=3&id="+S+"&dif="+(Z==a?1:-1));alert((Z==a?"Resource added.":"Resource removed.")+" "+S)}else if(z.data.startsWith("--ot ")){this.El.DJ().close();
this.Px.BH(z.data.split(" ").pop(),!0)}else if(z.data.startsWith("--et ")){}else{var P=new ed(b.E.L,!0);
P.data={d:b.c.zM,wx:z.data};this.S(P);this.KU()}}.bind(this);window.onbeforeunload=function(z){for(var L=0;
L<this.oZ.length;L++)if(this.oZ[L].VO())return this.oZ[L].name}.bind(this);window.setInterval(function(){var z=this.Nc();
if(z==null)return;var s=(Date.now()-z.o2)/6e4;if(this.Ir.vf==1&&z.QQ!=z.Js&&s>60){var O="You haven't saved your work ("+z.name+") for "+Math.round(s)+" minutes. Would you like to save it now? "+"You can disable this message in Edit > Preferences.",a=new ed(b.E.L);
a.data={d:b.c.P2,jW:"confirm"};a.data.Z=O;a.data.FJ=function(){var a=new ed(b.E.L);a.data={d:b.c.LI};
this.S(a)}.bind(this);this.S(a)}}.bind(this),30*60*1e3);var w=this,M="",m="";if(window.indexedDB&&(!a1.Ub()||document.hasStorageAccess==null)){var n={lN:window.indexedDB.open("pp",1)};
n.lN.onupgradeneeded=function(z){var s=z.target.result,O=s.createObjectStore("rsrc",{keyPath:"k"})};
n.lN.onsuccess=function(z){var s=w.Ir.AJ.sF=z.target.result,O=s.transaction(["rsrc"],"readwrite").objectStore("rsrc"),a=O.get("fs0");
a.onsuccess=function(z){if(z.target.result){var X=w.Ir.AJ.rA=z.target.result.fset;for(var P in X){if(!P.endsWith(".jsx"))e8.rb({url:P,anz:!0},X[P],w)}}}}}var W=["rwx~#.-(;.]6EF","rx'|#1,6><@87f?NO"],D=e.eH[hk.EW][hk.Ks];
for(var L=0;L<W.length;L++){var j=e.GF(W[L]);if(D.indexOf(j)!=-1){var I=e.eH[hk.EW][hk.yd],U=e.GF("M|H:15=3/iQ6EEKQ{\\PTbV/Y[`kjxx\"}vOz( %0b1=?HcMFZH zy#Wby9Sti'~uu3{}&428H-Cm7Ji{X[^w=Xbjhldc3kz{MC K[");
e._g(I);I[hk.a58]=U;return}}this.a={aa1:[{G:y.Nt,rc:!1,pn:[aK.a7r,aK.Xu]},{G:y.pX,rc:!1,pn:[aK.Xu]},{G:y.Od,rc:!0,pn:[aK.CQ],b5:[y.Xg]},{G:y.Xg,rc:!0,pn:[aK.CQ],b5:[y.Od]},{G:y.Kr,rc:!0,pn:[aK.CQ],b5:[y.Au,y.ET,y.o4]},{G:y.Au,rc:!0,pn:[aK.CQ],b5:[y.Kr,y.K7,y.Ww,y.Hw,y.Eh,y.dY]},{G:y.Rv,rc:!0,pn:[aK.CQ]}],Bu:[[{G:new y.mU,vu:dk},{G:new y.s2,vu:hh}],[{G:new y.Rb,vu:bA},{G:new y.t9,vu:cr}],[{G:new y.Et,vu:bU},{G:new y.TB,vu:gS},{G:new y.nZ,vu:i5}],[{G:new y.KF,vu:f$},{G:new y.fc,vu:dy},{G:new y.$W,vu:cO}],[{G:new y.a82,vu:hV},{G:new y.ail,vu:eQ},{G:new y.mk,vu:eI},{G:new y.cD,vu:hm}],[{G:new y.Mi,vu:ez},{G:new y.L8,vu:fR}],[{G:new y.xU,vu:jK},{G:new y.Vj,vu:iA},{G:new y.QU,vu:a2},{G:new y.amq,vu:eM},{G:new y.bS,vu:iR}],[{G:new y.CN,vu:bz},{G:new y.Ye,vu:gH},{G:new y.LZ,vu:d5}],[{G:new y.Wp,vu:ht}],[{G:new y.LW,vu:gn},{G:new y.pN,vu:kb}],[{G:new y.mr,vu:ja},{G:new y.XM,vu:gA}],[{G:new y.DU,vu:k5},{G:new y.qe,vu:bq},{G:new y._F,vu:fm}],[{G:new y.pS,vu:fb},{G:new y.$u,vu:hD},{G:new y.C6,vu:jy}],[{G:new y.hr,vu:bp},{G:new y.ahZ,vu:bp}],[{G:new y.p4(0),vu:gt},{G:new y.f3,vu:fT},{G:new y.p4(1),vu:gt}],[{G:new y.hn,vu:aT},{G:new y.Z5,vu:cp}],[{G:new y.Rect,vu:dj},{G:new y.Po,vu:an},{G:new y.xK,vu:cE},{G:new y.Dz,vu:hF},{G:new y.r2,vu:hN}],[{G:new y.fK,vu:by},{G:new y.dh,vu:fD}],[{G:new y.Jd,vu:fa}]],cY:[],keys:[aK.tM,aK.$g,aK.zP,aK._j,aK.Ak,aK.Zb,aK.KZ,aK.T2,aK.qd,aK.E,aK.rP,null,aK.ke,aK.US,aK.b8,aK.c,aK.Eg,aK.Ga,aK.xD],D1:[{G:new y.afe,vu:er},{G:new y.ad5,vu:iT},{G:new y.amx,vu:bO},{G:new y.Mi(!0),vu:ez},{G:new y.Qi,vu:cM}],vI:[{G:new y.G$},{G:new y.History},{G:new y.Ul},{G:new y.Su},{G:new y.CY},{G:new y.N$}],map:{},JE:null,SV:null,gW:null};
for(var L=0;L<this.a.Bu.length;L++){var l=this.a.Bu[L];if(l=="---")continue;var A=this.a.keys[L];for(var g=0;
g<l.length;g++){this.a.map[l[g].G.id]=l[g];l[g].rq=L;l[g].av0=g;var k=fV.get(l[g].G.name);m+="<li>"+l[g].G.id+": "+k+"</li>";
M+="\t"+JSON.stringify(l[g].G.name)+", "+(A?"\""+A.DG+"\"":"null")+", "+l[g].G.id+", // "+k+"\n"}this.a.cY[L]=0}for(var L=0;
L<this.a.D1.length;L++)this.a.map[this.a.D1[L].G.id]=this.a.D1[L];for(var L=0;L<this.a.vI.length;L++)this.a.map[this.a.vI[L].G.id]=this.a.vI[L];
this.Ir={a7A:!1,No:null,jq:0,t$:{j6:[],yg:[],list:[],lH:null},oH:[],a6W:[],wX:[],h$:[],iE:[],V8:[],auR:[],ajn:[],iE:[],Jz:[bI._1()],IH:[],$q:[],LA:null,R_:0,rg:{oq:1,S8:JSON.parse(JSON.stringify(at.Iz[0]))},jH:JSON.parse(JSON.stringify(at.QO.default)),arK:[null].concat(at.Iz),apY:[null].concat(at.Iz),hY:new hy(function(z){var s=new ed(b.E.L,!0);
s.data={d:b.c.VR,AH:{url:"rsrc/fonts/"+z}};this.S(s)}.bind(this)),Hu:{JO:[],lJ:null,ci:null},font:null,Io:[],O2:[],a1q:{},Gp:0,as:16777215,fM:!1,Ar:!0,M3:{jg:!0,Vk:!1,zc:!0,Oi:!0,E4:!0,ej:!0,Jt:20,Cp:0,df:0,Lf:0,_S:8421504},CF:!0,PW:[!0,!0,!1,!0,!0],Vy:[0,1,2,3,5,6,7,9,10,16,17,100],SI:1,A4:!0,n4:{},aE:!0,aiW:!1,compact:!1,vf:1,Tj:0,wv:!0,QA:null,AJ:{acr:!1,aeY:!1,rA:{},sF:null},aps:0,ag$:null,qH:null,ajl:null,oB:null};
this.a62={WH:new iB,HJ:new ec};this.Ir.Hu=hd.a9Q();this.SP=new hn;this.z7=new fO;this.GX=new gP(this.a,!0);
this.cM=new gz;this.NV=new iF(this);this.a2=e.t("div");this.c_=!1;this.ZT=this.ajd.bind(this);e.W0(this.NV.e,"mainblock");
this.ML.parent=this.SP.parent=this.z7.parent=this.GX.parent=this.cM.parent=this.NV.parent=this;this.NV.h(b.E.A,this.yI,this);
this.NV.h(b.E.gh,this.a7f,this);this.NV.h("shuffleItems",this.azG,this);this.NV.h(b.E.aeI,this.a5V,this);
this.h("mouse",this.aqu,this);this.h(b.E.v,this.Al,this);this.h(b.E.W1,this.aA3,this);document.body.addEventListener("keydown",this.rM.bind(this),!1);
window.addEventListener("keyup",this.fW.bind(this),!1);window.addEventListener("paste",this.a8E.bind(this),!1);
window.addEventListener("copy",this.ahO.bind(this),!1);window.addEventListener("wheel",function(z){if(z.ctrlKey)z.preventDefault()},{passive:!1});
window.addEventListener("beforeinstallprompt",function(z){if(window.innerWidth>400)z.preventDefault();
this.Ir.QA=z}.bind(this));if(window.location.href.indexOf("photopea.com")!=-1&&"serviceWorker"in navigator){navigator.serviceWorker.register("sw.js",{scope:"./"}).then(function(z){if(z.a0T){console.log("Service worker installing")}else if(z.auM){console.log("Service worker installed")}else if(z.active){console.log("Service worker active")}}).catch(function(z){console.log("Registration failed with "+z)})}this.Us=0;
this.oZ=[];this.Px=new e8(g1.rb);this.Px.parent=this;var $=this.Y$,C=this.dd=e.t("div");C.appendChild(this.SP.e);
C.appendChild(this.z7.e);this.ML.ayI(C);var f=this.a1L=e.t("div","flexrow");$.appendChild(f);f.appendChild(this.GX.e);
f.appendChild(this.NV.e);f.appendChild(this.cM.e);this.Px.e5({url:"rsrc/basic/basic.zip"});this.Ct(y.Rv);
bh.sk(this.aaW.bind(this))}hB.prototype=new jB(!0);hB.prototype.KU=function(w){var n=new ed(b.E.L);n.data={d:b.c.vN,AH:w?w:"done"};
this.S(n)};hB.prototype.aaW=function(){e.eH[hk.UJ](this.aaM.bind(this),Math.pow(Math.PI,8)+e.eH[hk.a7k][hk.aka]()*1e4);
var w=bh.bl();if(w!=null&&w.globals!=null)this.nI(w.globals);else{this.al7=!0;var n=navigator.languages;
if(n&&n.length!=0){var W=n[0];fV.gD(W,this.ZT)}}if(!this.WW()){var D=e.aqj();if(D==0)this.aiW=!0;if(D==2)this.Ir.aE=!1;
if(D!=1&&Math.random()<.002)e.aaY()}if(!a1.Ub()||!this.Ir.aE){this.anI();this.rm()}else{var j=e.Lb(e.eH[hk.GJ]);
j[hk.ZR](hk.oE,this.anj.bind(this));j[hk.or](e.Dn("61="),e.Dn("_MYOqDLGJa;A:6"));j[hk.Z2]()}this.Yv=!0;
this.KU()};hB.prototype.anj=function(w){var n=JSON.parse(w.target[hk.Ri]),W=e.eH[hk.Gg][hk.aAo]()/1e3,D=e.eH[hk.EW][hk.Ks],j=!1;
for(var I in n)if(I.indexOf(".")!=-1&&D.indexOf(I)!=-1&&parseInt(n[I])>W)j=!0;if(j)this.Ir.aE=!1;this.anI();
this.rm()};hB.prototype.rm=function(w){this.Y4=!0;if(!this.Ir.wv)this.NV.wv=null;else if(this.oZ.length==0)this.NV.amR();
this.Qb(bk.bI);this.f();this._K();this.cM.mQ(this.Nc(),this.oZ,this.Ir)};hB.prototype.nI=function(w){var n=this.Ir;
if(w.fcolor!=null)n.Gp=w.fcolor;if(w.bcolor!=null)n.as=w.bcolor;if(w.rulers!=null)n.fM=w.rulers;if(w.extras!=null)n.Ar=w.extras;
if(w.favFam!=null)n.Io=w.favFam;if(w.rsrc!=null)n.O2=w.rsrc;if(w.font!=null)n.Hu.JO[0].Name=w.font;if(w.panels!=null)n.Vy=w.panels;
if(w.as!=null)n.vf=w.as;if(w.co!=null)n.Tj=w.co;if(w.eparams){var W=w.eparams,D=n.M3;if(W.guides!=null)D.jg=W.guides;
if(W.grid!=null)D.Vk=W.grid;if(W.gsize!=null)D.Jt=W.gsize;if(W.gunits!=null)D.Cp=W.gunits;if(W.gtype!=null)D.df=W.gtype;
if(W.runits!=null)D.Lf=W.runits;if(W.gcol!=null)D._S=W.gcol;if(W.sels!=null)D.zc=W.sels;if(W.paths!=null)D.Oi=W.paths;
if(W.pgrid!=null)D.E4=W.pgrid;if(W.slices!=null)D.ej=W.slices}if(w.lang!=null)fV.gD(w.lang,this.ZT);
if(w.theme!=null)n.SI=w.theme;if(w.topt||n.kg){var j=w.topt?w.topt:{},I=n.kg?n.kg:{};for(var U in this.a.map){if(U>=103)continue;
var M="t"+U;if(j[M]||I[M])this.a.map[U].G.QW(j[M],I[M],this)}}};hB.prototype.anI=function(){if(this.Ir.a7A)return;
this.Ir.a7A=!0;var w=null,n=window.location.href,W=n.indexOf("="),D=n.indexOf("#");if(W!=-1)w=n.substring(n.indexOf("?")+1,W);
if(D!=-1&&D!=n.length-1){w="p";W=D}if(D!=-1&&n[D+1]=="i"){this.Px.BH(n.slice(D+2,D+10))}else if(D!=-1&&n[D+1]=="t"){this.Px.BH(n.slice(D+2,D+10).split("").reverse().join(""),!0)}else if(w=="p"||w=="state"){var j=n.substring(W+1,n.length);
j=JSON.parse(decodeURI(j));if(w=="p"){if(j.script=="alert(73)")this.Ir.aE=!1;if(j.script)d2.acA(this);
if(j.server)this.q_=j.server;if(j.resources)for(var L=0;L<j.resources.length;L++)this.Px.e5({url:j.resources[L]});
if(j.files)for(var L=0;L<j.files.length;L++)this.Px.e5({url:j.files[L],BX:{nN:j.server,a70:j.script}});
var I=j.environment;if(I==null)I={};if(I.plugins!=null)this.cM.a6j(I.plugins);if(I.localsave!=null)this.Ir.A4=I.localsave;
if(I.customIO!=null)this.Ir.n4=I.customIO;if(I.vmode!=null){var U=I.vmode;if(U==1)this.Ir.compact=!0;
if(U==2)this.AN(1)}if(I.intro!=null)this.Ir.wv=I.intro;if(I.menus!=null)this.Ir.aAm=I.menus;if(I.tmnu!=null)this.Ir.kg=I.tmnu;
if(I.panels!=null)this.Ir.Vy=I.panels;if(I.showtools!=null){var M=I.showtools,m=M.indexOf(this.Ir.No);
this.Ir.nf=M;if(m==-1)this.Ct(M[0])}if(I.phrases!=null)fV.a3F(I.phrases);if(I.autosave!=null){this.Ir.vf=0;
window.setInterval(function(){var g=new ed(b.E.L);g.data={d:b.c.LI};this.S(g)}.bind(this),I.autosave*1e3)}if(I.icons!=null){for(var l in I.icons)if(I.icons[l].indexOf("\"")==-1){if((l==hk.ab8||l==hk.aAH)&&this.Ir.aE)continue;
PIMG[l]=I.icons[l];PIMG["__"+l]=!0}}this.nI(I);if(j.files==null&&j.script){gQ.V_(j.script,this);this.KU()}}else if(w=="state"){var A=this.Px;
if(j.action=="create"){var g=new ed(b.E.L);g.data={d:b.c.P2,jW:"newproject",a7L:j.folderId};this.S(g)}if(j.action=="open"){for(var L=0;
L<j.ids.length;L++)e3.m_(function(){var $="https://www.googleapis.com/drive/v3/files/"+this.awB,C=new XMLHttpRequest;
C.open("GET",$);C.setRequestHeader("Authorization",e3.x1());C.send();C.onload=function(f){var z=JSON.parse(f.target.response);
A.e5({url:$+"?alt=media",name:z.name,Kh:{file:z,q5:""},$_:{Authorization:e3.x1()}})}}.bind({awB:j.ids[L]}));
alert("Loading files from Google Drive ...")}}}else{var k=window.launchQueue;if(k){var A=this.Px;k.setConsumer(function($){var C=$.files;
console.log(C);for(var L=0;L<C.length;L++){var f=C[L];f.getFile().then(function(z){A.Ok([z],null,null,null,[f])})}})}}};
hB.prototype.f=function(){var w=document.getElementById("cap");if(w){var n=!1,W=w.getElementsByTagName("h1")[0],I=0,M=0,m=0;
W.textContent=n?"Photopea":fV.get([0,17,0]);var D=w.getElementsByTagName("p"),j=e.VT(fV.get([0,17,1])),U=["PSD","XCF","Sketch","XD","CDR"];
for(var L=0;L<U.length;L++)j=j.replace(U[L],"<b>"+U[L]+"</b>");if(!n)j+=" (<b>Adobe Photoshop</b>, <b>GIMP</b>, <b>Sketch App</b>, <b>Adobe XD</b>, <b>CorelDRAW</b>).";
D[0].innerHTML=j;j=fV.get([0,17,2])+" "+fV.get([0,17,3]);for(var L=0;L<j.length;L++){var l=j[L];if(l=="<")M++;
if(l==">")m++}if(!n&&M*m==9){var A=["//github.com/photopea/photopea/issues","//www.facebook.com/photopea/","//blog.photopea.com/introduction.html"];
for(var L=0;L<3;L++){var g=j.indexOf("<",I),k=j.indexOf(">",I),$=j.slice(0,g)+"<a href=\""+A[L]+"\" target=\"_blank\">"+j.slice(g+1,k)+"</a>";
I=$.length;j=$+j.slice(k+1)}D[1].innerHTML=j}else D[1].innerHTML=fV.get([0,17,2])}var C=document.getElementById("sponsors");
if(C)C.textContent=fV.get([0,17,4]);this.ML.f();this.SP.f();this.cM.f();this.GX.f();this.El.f();this.NV.f();
for(var f in this.a.map)if(this.a.map[f].n8)this.a.map[f].n8.f()};hB.prototype.WW=function(){var w=e.eH[hk.Xe][hk.a3$];
if(w&&w[1]){if(w[1].endsWith(hk.Dn("UUPSDm@ID")))return!0}return 4<e.eH[hk.Xe][hk.op][hk.aar](hk.Dn("'$!|"))||true};
hB.prototype.zl=function(w,n){w=Math.floor(w);n=Math.floor(n);var W=e.Dn("WUMK&AM"),D=hk.ik,j=e.eH[hk.EW],I=Math.max(w,window.screen.width),U=Math.max(n,window.screen.height),g=0;
if(this.fg==null)this.fg=Math.min(I,U)<500||I<750?0:I<1600?1:2;var M=this.fg,m=!this.Y4||this.WW()||!this.Ir.aE||bh.d$()||M==0;
if(!m&&a1.Ub()){if(this.ak9==null)this.ak9=Math.random()<.5;m=this.ak9}if(m){if(M!=0&&e.eH[W]&&this.Y4)e.eH[W]()}else{if(M==0)n-=60;
else w-=M==1?180:320}jB.prototype.zl.call(this,w,n);if(m&&this.c_){this.e[hk.uF](this.a2);e._g(this.a2);
this.c_=!1}if(!m&&!this.c_){var l=function(C){if(Math.random()<.002){bh.event(a1.Cd()?"gota_0":"gota_1")}this.a2q(w,n);
var f=M==0?j[hk.yd]:this.e;f.appendChild(this.a2);this.a2[hk.k3](D,e.Dn("_MMJLNDfKCAg")+(M==0?10:10)+e.Dn("_d$ebOS?I:==Ba-+# }$M"));
this.a2[D][e.Dn("_MMJLND&<:E")]=(M==0?0:19)+e.Dn("_d");this.a2[D][e.Dn("i5WJHX")]=M==0?0:1}.bind(this);
function A(){a1.ai_(l)}setTimeout(A,2300);this.c_=!0}if(e.LY(this.SP.e))g+=31;if(e.LY(this.z7.e))g+=32;
this.ML.a4c=this.Ir.aE&&this.Y4;this.ML.zl(w,g);var k=n-g,$=e.Dn("_d");this.a2[D][hk.a6i]=(M==0?100>>>1:n-11)+$;
this.a2[D][hk.hk]=(M==0?w:6*Math.pow(10,2))+$;if(e.LY(this.GX.e))this.GX.zl(w,k);this.cM.zl(w,k);this.NV.zl(w-this.GX.P8()-this.cM.P8(),k)};
hB.prototype.a2q=function(w,n){var W=function(){var D=new ed(b.E.L);D.data={d:b.c.P2,jW:"account"};this.S(D)}.bind(this);
a1.aom(w,n,this.a2,W,this.fg)};hB.prototype.ahO=function(w){console.log("systemCopy")};hB.prototype.a8E=function(w){if(e.aO())return;
console.log("systemPaste");if(!w.clipboardData)return;var n=w.target.tagName.toLowerCase(),W=w.clipboardData.items;
if(W==null)return;var D=this.awC.bind(this);for(var L=0;L<W.length;L++){var j=W[L],I=j.getAsFile();if(j.type.indexOf("text")!=-1){j.getAsString(this.acg.bind(this))}if(j.type.indexOf("image")!=-1){if(I.size==this.Ir.aps)return;
this.Ir.aps=I.size;if(I){I.name="image.png";this.Px.Ok([I],D)}}}};hB.prototype.acg=function(w){if(w.startsWith("http")){if(w==this.Ir.avo)return;
this.Ir.avo=w;var n=new ed(b.E.L,!0);n.data={d:b.c.VR,AH:{url:w,AM:!0}};this.S(n)}};hB.prototype.awC=function(w,n){var W={buffer:w,rect:n},D=this.Ir;
if(e.aO()){var j=this.a62,I=j.WH;if(I.m==n.m&&I.n==n.n){W.rect=I;W.HJ=j.HJ}}else{if(D.qH){var U=new ed(b.E.v,!0);
U.G=y.eb;U.data={d:"h_stepbck"};this.S(U)}}D.qH=W;var U=new ed(b.E.L,!0);U.data={d:b.c.s_,a4_:!0};this.S(U)};
hB.prototype.aAD=function(){if(this.El.DJ()!=null)alert(fV.get([15,7,8]));else alert("Escape or Confirm the current action (in the top menu).")};
hB.prototype.Al=function(w){var n=this.Nc();if(n==null){alert(fV.get([15,7,7]));return}var W=w.G==y.pX||w.G==y.Nt;
if(this.El.wb()&&w.HH!=!0&&!W){this.aAD();return}var D=this.a,j=this.Ir.No,I=w.G;if(I==y.Lu&&j==y.Kk)I=y.Kk;
if(j!=I&&D.map[j].G.wb()&&!W&&!(j==y.gR&&I==y.sT)){console.log("disabling",j);D.map[j].G.disable(n,this,this.Ir,this._0)}var U=this.a.map[I].G;
U.Al(w.data,this,n,this._0,this.Ir)};hB.prototype.aA3=function(w){var n=this.Ir;if(w.data.Q9!=!0)cq.a2c({hZ:w.data.hZ,E3:w.data.E3},this,n,this.Nc());
var W=n.LA,D=n.$q;if(W==null)return;var j={aiK:!1,oA:"Step",ahp:0,r:!0,exp:!1,hZ:w.data.hZ};if(W[2]==null)W[2]=D[W[0]].xq[W[1]].xq.length-1;
if(w.data.E3)j.E3=w.data.E3;D[W[0]].xq[W[1]].xq.splice(W[2]+1,0,j);W[2]++;this.Qb(bk.v)};hB.prototype.w4=function(w){if(this.aiW){w.data=0;
return w.type}jB.prototype.w4.call(this,w);var n=w.data.d;if(n==b.c.if)cq.aqF(this.Nc(),this.Ir.$q,w.data.HD[0],w.data.HD[1],this);
if(n==b.c.a1B){this.aoZ(w.data.ars)}if(n==b.c.aA1){this.f();this._K()}if(n==b.c.aR)this._K();if(n==b.c.ahn)if(this.Ir.QA){this.Ir.QA.prompt();
this.Ir.QA=null}if(n==b.c.ph)this.NV.$J(w.data.In,w.data.push);if(n==b.c.a7X)this.NV.axX();if(n==b.c.a61)this.yI(null,w.data.dir);
if(n==b.c.L1)this.NV.kk(this.oZ.indexOf(w.data.Pk));if(n==b.c.sa){if(w.data.dJ&&document.fullscreenEnabled){if(document.fullscreenElement)document.exitFullscreen();
else document.body.requestFullscreen()}else if(w.data.dJ)document.body.webkitRequestFullScreen();if(w.data.Z!=null)this.AN(w.data.Z)}if(n==b.c.aqt){if(w.data.WS)this._0.xa(w.data.abF);
else this._0.nv(w.data.abF);this.oe(w.data.WS?"down":"up")}if(n==b.c.aeR){var W=w.data.Z;this.cM.a6j([W]);
this.f()}if(n==b.c.lb){var D=this.Nc(),j=D.Vc().slice(0),I=D.C[D.g[0]],U=new iB(0,0,D.m,D.n),M=kc.Fa()+"-d71c-11e5-b1ae-a548a96e5f9f",m=new ed(b.E.L,!0);
if(w.data.AH==0){var l={name:D.name.split(".")[0],id:M,HY:[j,U]};m.data={d:b.c.oj,BX:"add",AH:bk.C0,O2:[l]};
this.S(m)}if(w.data.AH==1){var A=E.Q(U.O()*4);E.cJ(A,4294967295);E.s._U("norm",j,U,A,U,U,1);var g=E.Q(U.O());
E.fo(A,g);E.Ba(g);var k=E.Nb(g,U);if(k.VY())k=U;var $=E.Q(k.O());E.B0(g,U,$,k);k.x=k.y=0;var C={WH:k,id:M,HY:[$,k]},f=bj.os(M),s=f.Brsh.v;
s.Dmtr.v.val=Math.max(k.m,k.n);s.Spcn.v.val=10;m.data={d:b.c.oj,BX:"add",AH:bk.zq,O2:{list:[{t:"Objc",v:f}],yg:[C],j6:[]}};
this.S(m);m.data={d:b.c.oj,AH:bk.ef,UT:f};this.S(m)}if(w.data.AH==2){var O=D.OV(),a=O[0][O[1][0]],X={fR:I.getName(),UU:M,i:a.add.vmsk.clone().i},P=E.P.b3(X.i),Z=new eh(P.m,0,0,P.n,P.x,P.y);
Z.Ba();E.P.c0(X.i,Z);P.x=P.y=0;X.H8=P.clone();m.data={d:b.c.oj,BX:"add",AH:bk.Iv,O2:[X]};this.S(m)}}if(n==b.c.VR)this.Px.e5(w.data.AH);
if(n==b.c.J0){var Y=w.data.awp,K=w.data.I3;if(Y!=!0&&K!=!0&&this.OI("open"))return;var S=this.NV.wz();
if(K)S=-1-S;this.Px.amG(Y||K?S:null,w.data.ahh)}if(n==b.c.RN){var G=w.data.a97,V=w.data.G2,T=this.SZ(G);
if(V){var R=G==bk.zq,x=[];for(var L=0;L<V.length;L++)x.push((R?T.list:T)[V[L]]);T=R?{j6:T.j6,yg:T.yg,list:x}:x}if(G==bk.gB){var U=new kc;
for(var L=0;L<T.length;L++){var v=T[L].nK.Lefx;if(v)ge.axf(v,U,this.Ir.V8)}T={ID:U.add.Patt?U.add.Patt:[],GM:T}}if(G==bk.Q6){var N=this.Ir.t$;
T={yg:[],j6:[],list:T};console.log(T)}if(G==bk.v)T=T[w.data.RL];var u=bk.Fj[G],j=u[2].z8(T);e8.save(j,u[1]+"."+u[0])}if(n==b.c.D7){var H=this.Ir.AJ,F=w.data.ao1;
if(H.sF&&!H.acr&&!F){H.aeY=window.confirm("Load \""+w.data.I6+"\" also next time you use the editor?\nManage it in Edit - Local Storage.");
H.acr=!0}if((H.aeY||F)&&H.sF){H.rA[w.data.I6]=w.data.AY;var m=new ed(b.E.L);m.data={d:b.c.oj,AH:bk._w};
this.S(m)}}if(n==b.c.apu){var D=this.Nc(),q="<!DOCTYPE HTML>";if(D==null)return;var t=jj.Zz(D.Vc().buffer,D.m,D.n),o=window.open();
q+="<head><script>setTimeout(function() {window.print();}, 10);</script></head>";q+="<body><img src=\""+t+"\" /></body>";
q+="</html>";o.document.write(q)}if(n==b.c.J6){if(this.OI("publishOnline"))return;var _=w.data.$x!="psd",D=this.Nc();
if(D==null)return;if(!_&&D.wW)return;var d="Your "+(_?"picture":"document")+" will be published at "+(_?"Imgur":"Photopea")+".com under a public URL (known only to you). Proceed?";
if(!_)d+=" We guarantee 6+ months of storage.";var r=w.data.Xm?!0:confirm(d);if(r){if(!_){var m=new ed(b.E.v,!0);
m.G=y.Yu;m.data={d:h.x9};this.S(m);var p=new iB(0,0,D.m,D.n);for(var L=0;L<D.C.length;L++){var I=D.C[L];
if(I.rect.VY()||I.ue()||I._N()||I.Jp()||I.I9()||I.add.TySh||I.add.vmsk||I.add.SoLd)continue;var Q=p.wU(I.rect);
if(!Q.s9(I.rect)&&!Q.VY()){var B=E.Q(Q.O()*4);E.Cb(I.buffer,I.rect,B,Q);I.buffer=B;I.rect=Q}if(!E.Bw(I.buffer,I.rect.m,I.rect.n))continue;
var i=I.I4(),c=I.opacity,h2=I.Bx,jX=I.QY;I.gb(!0);I.opacity=255;I.Bx="norm";D.g=[L];m.data={d:h.zi,$x:"jpg"};
this.S(m);var bm=D.C[L];I.gb(i);bm.gb(i);I.opacity=bm.opacity=c;I.Bx=bm.Bx=h2,I.QY=bm.QY=jX}}if(D.zm){D.tw()}var dC=D.m,fn=D.n,fK=w.data.abt,i6;
if(fK)while(Math.max(dC,fn)>fK){dC=dC>>>1;fn=fn>>>1}console.log(dC,fn);if(w.data.$x=="psd")i6=jj.rk(D,"psd",0,0,[!0,!0,!0,!1,!0]);
else if(w.data.$x=="png")i6=jj.rk(D,"png",dC,fn);else{var dh=jj.rk(D,"png",dC,fn),kA=jj.rk(D,"jpg",dC,fn);
i6=dh.byteLength<kA.byteLength?dh:kA}if(_)e8.a6r(i6,w.data.Xm);else this.Px.amv(i6,D.name,w.data.Xm,"psdshared")}}if(n==b.c.LI){var D=this.Nc(),ig=!1;
if(D==null)return;if(D.zm){D.tw()}if(w.data.mP){if(!this.Xj(D,w.data.mP))return;var j=g1.aqI(D,w.data.mP,this.Ir);
this.KU(j);ig=!0}else if(D.gN){if(this.oZ.indexOf(D.gN.Wv)!=-1){var j=new Uint8Array(jj.ZO("PSD").La(D,null,null,[!0,!1])),m=new ed(b.E.v,!0);
m.data={d:h.v4,On:D.gN.Wv,data:j,id:D.gN.asK,O7:D.name};m.G=y.Yu;this.S(m);alert("Smart Object updated")}ig=!0}else if(this.OI("save")){ig=!0}else if(D.Kh){g1.amP(D);
ig=!0}else if(D.Il){g1.arJ(D);ig=!0}else if(D.BX&&D.BX.nN){if(!this.Xj(D,D.BX.nN.formats))return;this.Px.a7U(D,this.Ir,g1.aAx);
ig=!0}else if(D.YX&&"psd jpg png gif webp svg bmp".split(" ").indexOf(D.Mc)!=-1){this.atz();return}if(ig){D.Js=D.QQ;
D.o2=Date.now();D.RP=!0}else{var m=new ed(b.E.L,!0);m.data={d:b.c.N0};this.S(m)}}if(n==b.c.N0){if(!this.Ir.A4){alert("function is disabled");
return}if(this.OI("saveAsPSD"))return;var D=this.Nc();if(D==null)return;if(!this.Xj(D))return;var m=new ed(b.E.v,!0);
m.data={d:h.x9};m.G=y.Yu;this.S(m);if(D.C.length>8e3&&!confirm("Your document has "+D.C.length+" layers."+" Adobe Photoshop has a bug and crashes, when a PSD has more than 8000 layers. Do you want to proceed?"))return;
var iJ={jB:[]};D.root.ajG([],iJ);var fL=iJ.jB;if(fL.length>11&&!confirm("One layer is nested "+(fL.length-1)+" times."+" Adobe Photoshop crashes, when a layer in a PSD is nested more than 10 times. Do you want to proceed?\n\nLongest nesting: "+fL.join(" \uD83E\uDC1A ")+"."))return;
var fB=window.showSaveFilePicker;if(window.parent!=window)fB=null;if(fB&&!w.data.a81){var ah={suggestedName:D.name,types:[{description:"PSD Files",accept:{"image/psd":[".psd"]}}]};
fB(ah).then(function(w){D.YX=w;D.name=w.name;D.tL=!0;D.Mc="psd";this.atz()}.bind(this));return}var eS=window.gtag;
if(D.Tu()&&eS)eS("event",D.Mc+":"+e.GF(bh.d$()?"\"'|('61":"w'| "),{event_category:"Formats"});if(D.zm){D.tw()}if(w.data.a81){var j=D.Mc=="psd"?jj.ZO("PSD").La(D):g1.B8(D,D.Mc,this.Ir);
this.ayW(j,D,this)}else{var j=jj.ZO("PSD").La(D);e8.save(j,D.name);D.Js=D.QQ;D.o2=Date.now();D.RP=!0}}if(n==b.c.aT)window.open(w.data.link,"_blank");
if(n==b.c.agP){if(this.El.wb()){this.aAD();return}var D=this.Nc(),I=D.C[D.g[0]],W=D.mZ(I.add.SoLd.Idnt.v);
for(var L=0;L<this.oZ.length;L++){var gL=this.oZ[L].gN;if(gL!=null&&gL.asK==W.Z4&&gL.Wv==D){this.NV.Rx(L);
return}}e8.rb({name:W.O7,gN:{asK:I.add.SoLd.Idnt.v,Wv:D}},W.raw.buffer,this)}if(n==b.c.ayP){var D=this.Nc(),I=D.C[D.g[0]],W=D.mZ(I.add.SoLd.Idnt.v);
e8.save(W.raw.buffer,W.O7)}if(n==b.c.akb){console.log(w.data);e8.rb({name:w.data.Il[1].split("/").pop(),Il:w.data.Il},w.data.Ey,this)}if(n==b.c.abm){var D=this.Nc();
D.Il=w.data.Il;D.name=D.Il[1].split("/").pop();var m=new ed(b.E.L);m.data={d:b.c.LI};this.S(m)}if(n==b.c.jm){this.ap2()}if(n==b.c.UA){this.ajM(w.data.O0,w.data.Ay,w.data.bh)}if(n==b.c.s_){this.apR(w.data.a4_,w.data.dV,w.data.bh)}if(n==b.c.aoH){var e_=w.data.Z;
if(this.Ir.No==y.Lu&&this.RR().wb()){var m=new ed(b.E.v,!0);m.G=y.Lu;m.data={d:"insertText",Z:e_};this.S(m);
return}if(e_.startsWith("vcb;")){var c2=JSON.parse(e_.slice(4));c2[0]=bI.sy(c2[0]);var m=new ed(b.E.v,!0);
m.G=y.Au;m.data={d:"append",s7:"Paste Paths",akR:c2};this.S(m)}else if(e_.startsWith("lrs;")){var jS=e_.split(";"),ie=this.oZ[parseInt(jS[1])];
if(ie==null)return;var as=this.Nc(),gb=ie.g;ie.g=JSON.parse(jS[2]);var gx=ie.Jr(null,ie!=as),m=new ed(b.E.v,!0);
m.data={d:h.jF,C:gx,Wv:ie,SY:as};m.G=y.Yu;this.S(m);ie.g=gb}else if(e_.startsWith("<!--")||e_.startsWith("<svg")){var eo=J.zY(e_),di=jj.ZO("svg"),U=new kc("image.psd");
di.Vu(eo.buffer,U);if(this.oZ.length!=0){var d0=U.C;if(d0.length==3&&d0[0].getName()=="</Layer group>"&&d0[2].ue())d0=[d0[1]];
var m=new ed(b.E.v,!0);m.G=y.Yu;m.data={d:h.jF,C:d0,Wv:U,SY:this.Nc()};this.S(m)}else this.a5j(U)}}if(n==b.c.zM){gQ.V_(w.data.wx,this)}if(n==b.c.vN){if(window.parent!=window)window.parent.postMessage(w.data.AH,"*");
this.cM.E$(w.data.AH)}if(n==b.c._y){var e6=parseFloat(w.data.jW);if(this.Ir.Vy.indexOf(e6)==-1){var m=new ed(b.E.L,!0);
m.data={d:b.c.oj,AH:bk.dp,Z:e6,BX:"add"};this.S(m)}this.cM.ayM(w.data.jW)}if(n==b.c.$C){this.lt.a2G(this.Nc(),this.Ir)}if(n==b.c.P2){var dt="open_from_url openFromURL camera takePic templates showTemplates newproject new eassets exportLayers".split(" ");
for(var L=0;L<dt.length;L+=2)if(w.data.jW==dt[L]&&this.OI(dt[L+1]))return;if(!this.Ir.A4&&w.data.window=="saveforweb"){alert("function is disabled");
return}this.El.azW(w.data.jW,this.Nc(),w.data,this.oZ,this._0)}if(n==b.c.pA)e8.save(w.data.data,w.data.name);
if(n==b.c.dH){if(!this.El.wb()||w.HH)this.a5j(w.data.On)}if(n==b.c.l9){this.NV.Rx(w.data.target);var m=new ed(b.E.v,!0);
m.data={d:h.aly,On:w.data.On,HS:w.data.HS,XT:w.data.XT};m.G=y.Yu;this.S(m);this.Ct(y.Sv)}if(n==b.c.aqc){je.YG=!je.YG;
if(this.oZ.length>0)this.Nc().l()}if(n==b.c.a2u){var gJ=bh.bl();if(gJ!=null&&gJ.globals!=null)this.nI(gJ.globals);
this.rm()}if(n==b.c.Bc){this.Px.Ok(w.data.data,null,w.data.ev,w.data.Ze,w.data.aoG)}if(n==b.c.CV){var iW=this.RR();
if(!this.El.DJ()!=null)this.Ct(w.data.G,w.data.LQ);var g5=this.RR();if(g5!=iW&&w.data.asq)g5.WQ(this.Nc(),this,this.Ir,this._0,this.gC)}if(n==b.c.Oy){if(this.a.JE)this.Ct(this.a.JE)}if(n==b.c.bw){var jW=this.a.map[w.data.G].G,D=this.Nc();
jW.sm(w.data,this,D,this._0,this.Ir);if(D)D.rR=!0;this.aiT()}if(n==b.c.Bg){var eP=this.a.map[w.data.G];
this.aja(eP);eP.n8.um(w.data)}if(n==b.c.oj){var D=this.Nc(),b_=w.data.AH,fZ=w.data.O2,j3=this.Ir;if(w.data.BX=="set"){var g5=y.apO(fZ);
if(j3.No!=g5)this.Ct(g5);this.a.map[g5].n8.a5p(fZ,j3)}if(w.data.BX=="add"){var u=bk.Fj[b_];if(b_==bk.dp){j3.Vy.push(w.data.Z);
j3.Vy.sort(function(ep,b2){return ep-b2})}else if(u==null){if(fZ)j3.hY.avt(fZ,w.data.ahH);if(D)D.RP=!0}else{var dr=this.SZ(b_);
if(b_==bk.zq){dr.yg=dr.yg.concat(fZ.yg);dr.j6=dr.j6.concat(fZ.j6);dr=dr.list;fZ=fZ.list}if(b_==bk.gB&&D){for(var L=0;
L<fZ.length;L++){var v=fZ[L].nK.Lefx;if(v)ge.ax9(v,D,j3.V8)}}if(b_==bk.Q6&&fZ==null){var U=this.a.map[j3.No].n8.asT();
if(U==null)return;fZ=[U]}for(var L=0;L<fZ.length;L++)dr.push(fZ[L]);if(b_==bk.Iv){var c0={};for(var L=0;
L<dr.length;L++){var fM=dr[L].fR;while(c0[fM]!=null)fM=dr[L].fR=fM+"X";c0[fM]=!0}}if(w.data.ahH!=!0)if(dr.length!=fZ.length||b_==bk.qs||b_==bk.gB||b_==bk.K_||b_==bk.v)alert(fV.get(u[3])+" "+fV.get([23,1])+".")}}if(w.data.BX=="del"){if(b_==bk.dp){j3.Vy.splice(j3.Vy.indexOf(w.data.Z),1)}else{var u=bk.Fj[b_],V=w.data.G2,dr=this.SZ(b_);
if(b_==bk.zq)dr=dr.list;for(var L=0;L<V.length;L++)dr[V[L]]=null;for(var L=0;L<dr.length;L++)if(dr[L]==null){dr.splice(L,1);
L--}alert(fV.get(u[3])+" deleted.")}}if(w.data.BX=="rnm"){var u=bk.Fj[b_],dr=this.SZ(b_);if(b_==bk.zq)dr=dr.list;
if(dr[w.data.G2[0]]==null)return;u[2].UG(dr[w.data.G2[0]],w.data.Z)}if(b_==bk.ut){var cB=w.data.Z;j3.rg=cB;
j3.arK[cB.oq]=cB.S8}if(b_==bk.Nd){var cB=w.data.Z;j3.jH=JSON.parse(JSON.stringify(cB));var iI=cB.strokeEnabled.v,jD=cB.strokeStyleContent.v,j8=iI?{oq:1+at.QO.W_.indexOf(jD.classID),S8:jD}:{oq:0};
j3.apY[j8.oq]=j8.S8}if(b_==bk.xo){j3.R_=w.data.Z}if(b_==bk.a8){j3.Hu=w.data.Hu}if(b_==bk.ef){var B=JSON.parse(JSON.stringify(w.data.UT)),jG=B.useBrushSize;
if(jG&&jG.v){B.Brsh.v.Dmtr.v.val=j3.t$.lH.Brsh.v.Dmtr.v.val;jG.v=!1}j3.t$.lH=B}if(b_==bk.SJ){j3.Io=w.data.qY}if(b_==bk.ad){j3.O2=w.data.qY}if(b_==bk.X$){var i1,bH="Clrs";
if(w.data.vK<2){var a_=w.data.Z,aR=w.data.vK==0,iY=E.M.lW({o:a_>>>16,B:a_>>>8&255,k:a_&255});if(aR)j3.Gp=a_;
else j3.as=a_;bH=aR?"FrgC":"BckC";i1={hZ:"set",E3:{__name:"Set",classID:"setd",T:{t:"Objc",v:iY}}}}if(w.data.vK==2){var gy=j3.Gp;
j3.Gp=j3.as;j3.as=gy;i1={hZ:"exchange",E3:{__name:"Exchange",classID:"Exch"}}}if(w.data.vK==3){j3.Gp=0;
j3.as=16777215;if(D!=null&&D.g.length!=0&&D.C[D.g[0]].eL==1){var gy=j3.Gp;j3.Gp=j3.as;j3.as=gy}i1={hZ:"reset",E3:{__name:"Reset",classID:"Rset"}}}if(i1){i1.E3.null={t:"obj ",v:[{t:"prop",v:{classID:"Clr",keyID:bH}}]};
var eP=this.RR();eP.xh=this;eP.track(i1)}}if(b_==bk.SU){j3.fM=!j3.fM;this._K()}if(b_==bk.Xh){j3.Ar=!j3.Ar;
this._K()}var gr=j3.M3;if(b_==bk.TK){gr.zc=!gr.zc;this._K()}if(b_==bk.aK){gr.Oi=!gr.Oi;this._K()}if(b_==bk.pa){gr.jg=!gr.jg;
this._K()}if(b_==bk.ZX){gr.Vk=!gr.Vk;this._K()}if(b_==bk.Qu){gr.E4=!gr.E4;this._K()}if(b_==bk.WA){gr.ej=!gr.ej;
this._K()}if(b_==bk.OS){j3.M3=w.data.qY;this._K()}if(b_==bk.agg){j3.CF=!j3.CF;this._K()}if(b_==bk.Uj){j3.PW[w.data.hM]=!j3.PW[w.data.hM];
this._K()}if(b_==bk.Z0){fV.DF(w.data.lang,this.ZT)}if(b_==bk.ix){j3.SI=w.data.SI;this.f()}if(b_==bk._w&&j3.AJ.sF){var fs=j3.AJ.sF.transaction(["rsrc"],"readwrite").objectStore("rsrc"),dQ=fs.put({k:"fs0",fset:j3.AJ.rA});
dQ.onerror=function(w){console.log(w);alert("Storing failed. Browser says: "+w.target.error.message,7e3)}}this.Qb(b_)}};
hB.prototype.atz=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.Ql,mz:"Saving ..."};this.S(w);setTimeout(function(){var w=new ed(b.E.L,!0);
w.data={d:b.c.N0,a81:!0};this.S(w)}.bind(this),20)};hB.prototype.ayW=function(w,n){n.YX.createWritable().then(function(W){W.write(w);
return W}).then(function(W){return W.close()}).then(function(W){n.Js=n.QQ;n.o2=Date.now();n.RP=!0;var D=new ed(b.E.L,!0);
D.data={d:b.c.SO,mz:"Saving ..."};this.S(D)}.bind(this)).catch(function(W){var D=new ed(b.E.L,!0);D.data={d:b.c.SO,mz:"Saving ..."};
this.S(D)}.bind(this))};hB.prototype.a2O=function(){var w=this.Ir,n=w.O2,W=w.a1q;for(var L=0;L<n.length;
L++){var D=n[L];if(W[D])continue;W[D]=!0;this.Px.BH(D,!1,!0)}};hB.prototype.ajd=function(){this.f();
this._K()};hB.prototype.OI=function(w){var n=this.Ir.n4[w];if(n){var W=new ed(b.E.L,!0);W.data={d:b.c.zM,wx:n};
this.S(W)}return n!=null};hB.prototype.Xj=function(w,n){var W=!0,U=15;if(n){W=!1;for(var L=0;L<n.length;
L++)if(n[L].startsWith(e.Dn("__M")))W=!0}var D=w.Tu()||w.gN&&w.gN.Wv.Tu();if(this.WW())D=!1;var j=new e.eH[hk.Gg],I=(j[e.GF("xy,b-66:")]()&1)*60+j[e.Dn("VQ]3LNRN<G")]();
if(D&&!bh.d$()&&I>U&&W){var M=e.eH[e.GF("}$z{2*35")][e.GF("y'|!")],m=e.Dn("C[hMHT\\GFB6GJ.44>+.(2sq koomg\\beyj;PGS?Ad+sL>6Cpp^7w!|\"mwuhkguVQ[iII`SN=9Q>:5?B$2, \"w-~oi!ddjhfn|}ePIKOK9DM0>*48;--\"/tx{us+");
m+="\n\n"+e.Dn("6Q]eD_-L<A:C8G&%\"+.$'/4ouu qb\\sf\\WQRKSA=U430/:7II:''1&lqy\"")+(-I+120)+e.Dn("nYRTXTBMd");
if(M.indexOf(e.GF("\"|'/-1)(W0?@"))==-1)m=fV.get([0,11+6,3+2]);e.eH._cwY(m);return!1}return!0};hB.prototype.SZ=function(w){var n=this.Ir,W=[bk.zq,bk.tU,bk.tX,bk.K_,bk.C0,bk.Iv,bk.gB,bk.qs,bk.v,bk.Q6,bk.M9],D=[n.t$,n.wX,n.h$,n.iE,n.V8,n.Jz,n.IH,n.auR,n.$q,n.oH,n.a6W];
return D[W.indexOf(w)]};hB.prototype.ap2=function(){var w=this.ajM(),n=this.Nc();if(n==null||n.g.length==0)return;
var W=n.C[n.g[0]],D=new ed(b.E.v);if(w==1){D.G=y.Au;D.data={d:"remove",s7:"Cut Paths"}}else{D=new ed(b.E.W1);
D.data={hZ:"delete"}}this.S(D)};hB.prototype.ajM=function(w,n,W){if(w==null)w=!1;var D=this.Ir;console.log("doCopy",w,n);
var j=this.Nc();if(D.No==y.Lu&&this.RR().wb()){var I=new ed(b.E.v,!0);I.G=y.Lu;I.data={d:"copyText"};
this.S(I);return}if(j==null||j.g.length==0)return;var U=j.C[n==null?j.g[0]:n],M=j.OV(),m=M[0],l=M[1],A=m[l[0]];
if(!w&&A!=null&&A.add.vmsk.g.length!=0){var g=y.rK.WR(A.add.vmsk,A.add.vogk);if(e.aO()){g[0]=bI.afh(g[0]);
var k="vcb;"+JSON.stringify(g);e8.mJ(new Blob([k],{type:"text/plain"}))}else D.oB=g;return 1}else if(j.J==null){if(e.aO()){var k="lrs;"+this.oZ.indexOf(j)+";"+JSON.stringify(j.g);
e8.mJ(new Blob([k],{type:"text/plain"}))}}else{var $,C;if(w){var f=new iB(0,0,j.m,j.n);C=f.wU(j.J.rect);
$=E.Q(C.O()*4);E.Cb(j.Vc(),f,$,C);E.AG(j.J.channel,j.J.rect,$,C)}else if(j.v9.length!=0){C=j.J.rect.clone();
$=E.Q(C.O()*4);var s=j.yo[j.v9[0]],O=s.Ln(C);E.Mj(O,$);E.IL(j.J.channel,$,3)}else{var a=U.WC(j,j.J);
if(a==null){alert("Copied area is empty");return}$=a.Ey;C=a.rect}var X=j.u.zC,P=X[0]+X[1]+X[2];if(P==1){var Z=X.indexOf(1);
for(var L=0;L<$.length;L+=4)$[L]=$[L+1]=$[L+2]=$[L+Z]}var Y=new ec(j.m,j.n);if(e.aO()&&W!=!0){var K=jj.ZO("PNG").a30($.buffer,C.m,C.n);
e8.mJ(new Blob([new Uint8Array(K)],{type:"image/png"}));this.a62={WH:C,HJ:Y}}else D.qH={buffer:$,rect:C,HJ:Y};
D.ag$=C.clone();D.oB=null}};hB.prototype.apR=function(w,n,W){if(n)this.a0c=!0;console.log("doPaste");
var D=this.Ir,j=D.qH,m;if(this.oZ.length==0){if(!w&&e.aO()){e8.h6(this,null);return}if(j){var I=jj.Dk("image.psd",[{data:j.buffer.buffer,XL:j.rect}]),U=new ed(b.E.L);
U.data={d:b.c.dH,On:I};this.S(U)}return}var I=this.Nc();if(D.No==y.Lu&&this.RR().wb()){e8.h6(this,null);
return}var M=I.C[I.g.length==0?I.C.length-1:I.g[0]];if(D.oB){var l=I.OV(!0),A=l[0],g=l[1];m=A[g[0]]}var U=new ed(b.E.v,!0);
if(D.oB!=null&&m!=null){U.G=y.Au;U.data={d:"append",s7:"Paste Paths",akR:D.oB}}else if(!w&&e.aO()&&W!=!0){e8.h6(this,this.awC.bind(this));
return}else{if(j==null)return;if(I.d2(!1)&&(I.u.zC.join("")!="111"||I.v9.length!=0||M.eL>0||M.rect.VY())){U.G=y.zq;
U.data={d:"draw",ake:!0,s7:[5,2]}}else{U.G=y.Yu;U.data={d:h.nS,dV:this.a0c};this.a0c=!1}U.data.qH=j}this.S(U)};
hB.prototype.aae=function(){var w=this.Ir.hY;if(w.aoJ())return;for(var L=0;L<this.oZ.length;L++){var n=this.oZ[L];
if(!aj.MF(n,w,this))continue;if(n.XW)aj.yf(n,w,this);var W=n.add.lnk2;if(W)for(var D=0;D<W.length;D++){var j=W[D];
if(j.XW)y.G$.mv(n,j.Z4,j.PO[1],j.PO[1],w)}if(n.a08)continue;n.a08=!0;if(n.BX&&n.BX.a70)gQ.V_(n.BX.a70,this);
this.KU();var I=new ed(b.E.v);I.G=y.Yu;I.data={d:h.jh};var U=new ed(b.E.L);U.data={d:b.c._y,jW:et.ip.a2X};
U.data={d:b.c.P2,jW:"afw_VaPo"}}};hB.prototype.Qb=function(w){this.a2O();var n=this.Ir,W=n.No,U=!1;if(w==bk.ef){if(this.a.map[W].n8)this.a.map[W].n8.GZ(n,w)}else for(var D in this.a.map)if(this.a.map[D].n8)this.a.map[D].n8.GZ(n,w);
if(w==bk.v3){if(W!=y.Lu)this.a.map[y.Lu].G.GZ(n,w);this.aae()}this.NV.GZ(n,w);this.GX.GZ(n,w);this.El.GZ(n,w);
this.RR().GZ(n,w);this.cM.GZ(n,w);this.SP.GZ(n,w);if(w==bk.ix||w==bk.bI){hp.aoC(n.SI);this.update(!0)}var j=n.Hu,I=j.lJ.Font;
if(w==bk.a8&&I!=null&&j.JO[I].Name!=n.font){n.font=j.JO[I].Name;U=!0}if([bk.dp,bk.SJ,bk.ad,bk.X$,bk.SU,bk.Xh,bk.OS,bk.pa,bk.ZX,bk.TK,bk.aK,bk.Qu,bk.WA,bk.Z0,bk.ix].indexOf(w)!=-1||U)this.aiT()};
hB.prototype.aiT=function(){if(!this.Yv)return;var w={},n=this.a.map;for(var W in n){var D=n[W].G;if(D.Th&&D.Th()!=null)w["t"+W]=D.Th()}var j=this.Ir,I=j.M3,U={guides:I.jg,grid:I.Vk,sels:I.zc,paths:I.Oi,pgrid:I.E4,slices:I.ej,gsize:parseFloat(I.Jt.toFixed(2)),gunits:I.Cp,gtype:I.df,runits:I.Lf};
if(I._S!=8421504)U.gcol=I._S;var M={fcolor:j.Gp,bcolor:j.as,rulers:j.fM,extras:j.Ar,favFam:j.Io,rsrc:j.O2,panels:j.Vy,eparams:U,lang:fV.fG(),theme:j.SI,as:j.vf,co:j.Tj,topt:w};
if(j.font!=null)M.font=j.font;var m=bh.bl();if(m==null)m={};m.globals=M;bh.qK(m)};hB.prototype.h2=function(w){var n=this._0,W=this.gC,D=this.Ir.No,j=this.a.map[D].G,I=null,U=!1;
for(var L=0;L<this.a.aa1.length;L++){var M=this.a.aa1[L],m=!0;for(var l=0;l<M.pn.length;l++){var A=M.pn[l];
if(!n.U(A))m=!1}if(m&&(!M.rc||!j.wb())&&(M.b5==null||M.b5.indexOf(D)!=-1)){I=M.G;U=M.rc;break}}if((!W.WS||D==y.GO||w)&&this.a.SV!=I&&(I!=D||!U)){var g=this.Nc();
if(this.a.SV!=null&&I==null)this.RR().disable(g,this,this.Ir,n,!0);this.a.SV=I;this.RR().enable(g,this,this.Ir,n,I!=null&&I!=D)}};
hB.prototype.WU=function(w){var n=this.Ir.No,W=this.Nc();if(n!=null){this.a.map[n].G.disable(W,this,this.Ir,this._0)}};
hB.prototype.aja=function(w){if(w.n8==null){w.n8=new w.vu;w.n8.a1f(w.G.id,w.G.GH);w.n8.GZ(this.Ir,bk.bI);
w.n8.f()}};hB.prototype.Ct=function(w,n){if(w==y.Sv&&this.El.DJ())return;var W=this.Nc(),D=this.Ir;if(this.a.map[w].G.Tr(W,D)){this.WU();
if(w!=D.No)this.a.JE=D.No?D.No:y.Rv;D.No=w;this.GX.Ct(D.No);var j=this.a.map[w];this.a.cY[j.rq]=j.av0;
this.aja(j);this.z7.aau(j.n8);var I=j.G;I.enable(W,this,this.Ir,this._0,!1,n);if(W)W.rR=!0;this._K();
this.ML.abJ()}};hB.prototype.RR=function(w){var n=this.a,W=n.gW,D=n.SV,j=this.Ir.No;if(W)j=W;else if(D&&w==null)j=D;
return n.map[j].G};hB.prototype.a5j=function(w){var n=this.Ir,W=this.oZ.indexOf(w);if(W!=-1){this.NV.Rx(W);
return}if(this.q_&&(w.BX==null||w.BX.nN==null)){w.BX={nN:this.q_}}if(w.ea==null){w.ea="local,"+this.as4+","+w.name;
this.as4++}w.o2=Date.now();if(a1.Cd()!=0&&!this.al7&&e.eH[e.GF("t$&!'31")].toString().indexOf(e.GF(" u,$4&"))==-1){alert(e.GF("j$--=#66A@5EU`KQaFVjSih\\hpirt2,x&5&+#++A4<8SFOO_FUMQ|"));
return}for(var L=0;L<w.C.length;L++){var D=w.C[L];if(D.add.SoLd!=null){var j=Date.now()}}var I=w.C.length,U=hk.Hl(),M=Math.PI*(5465<<14)+(e.pI(31)?20:10)*7e7;
if(U>M){var I=w.C.length;w.C=[];return I}if(je.YG){je.D5(Math.max(w.m,w.n));for(var L=0;L<w.C.length;
L++){var D=w.C[L];if(D.oK())je.D5(Math.max(D.rect.m,D.rect.n))}}w.X0();w.hd();if(w.a1e)w.aAt();else w.l();
w.a1e=!1;this.oZ.push(w);this.NV.f9(new cP(w));w.rR=!0;w.RP=!0;this.aae();var m=new ed(b.E.v);m.G=y.DW;
m.data={d:"auto",Fv:2}};hB.prototype.Nc=function(){return this.oZ[this.Us]};hB.prototype.agq=function(){return this.El.DJ()==null};
hB.prototype.yI=function(w,n){this.WU();var W=this.oZ.length;if(n!=null)this.NV.Rx((this.NV.wz()+n+W)%W);
this.Us=this.NV.wz();var D=this.Nc();this.SP.a4v(D,this.Ir);this.cM.mQ(D,this.oZ,this.Ir);this._K();
if(D)D.rR=!0};hB.prototype.a7f=function(w){this.WU();var n=this.oZ[w.data.tH];this.oZ.splice(w.data.tH,1);
if(this.oZ.length==0){this.yI(w);var W=je.Om(),D=cP.pD.CJ;if(W.parentNode)W.parentNode.removeChild(W);
if(D.parentNode)D.parentNode.removeChild(D)}};hB.prototype.azG=function(w){var n=[],W=w.data.aof;for(var L=0;
L<W.length;L++)n[L]=this.oZ[W[L]];this.oZ=n;this.Us=this.NV.wz()};hB.prototype.a5V=function(w){var n=this.NV,W=n.a6I(),D=this.RR(),j=this.Nc();
if(W==n.wz()||!D.age())return;this.aoZ(W,D)};hB.prototype.aoZ=function(w,n){console.log("dup2doc");var W=this.Ir,D=this.NV,j=this.Nc(),I=this.oZ[w],U,M=new ed(b.E.v,!0);
M.G=y.Yu;if(j.J==null){M.data={d:h.jF,C:j.Jr(null,!0),Wv:j,SY:I};this.S(M)}else U=j.C[j.g[0]].WC(j,j.J);
var m=this.gC,l=W.fM;W.fM=!1;m=j.u.Cg(m.x,m.y);if(n)n.Lp(j,this,W,this._0);D.Rx(w);if(j.J){M.data={d:h.nS,qH:{buffer:U.Ey,rect:U.rect}};
this.S(M)}m=I.u.m9(m.x,m.y);if(n)n.WQ(I,this,W,this._0,m);W.fM=l};hB.prototype.aqu=function(w){var n=this.Nc(),W=this._0,D=this.Ir,j=w.tJ;
if(j)this.gC=j;if(j)j.y-=D.Tj;if(this.ot==null)this.ot=0;if(w.action=="multidown"){this.Kv=w.LE.length;
this.ot=Date.now()}if(w.action=="up"&&Date.now()-this.ot<100){var I=new ed(b.E.v);I.G=y.eb;I.data={d:this.Kv==2?"h_stepbck":"h_stepfwd"};
this.S(I)}if(w.action.startsWith("multi")){var U=new ed(b.E.v,!0);U.data={d:w.action,LE:w.LE};U.G=y.Nt;
this.S(U);return}var M=this.a.map[y.Rv].G;if((w.action=="down"||w.action=="rdown")&&D.No!=y.Rv&&this.a.SV!=y.Rv&&M.amK(n,this,D,W,j)){this.a.gW=y.Rv;
M.enable(n,this,D,W,!0)}if(w.action=="idown"){W.xa("Space");this.h2(!0);w.action="down"}var m=this.El.DJ(),l=m!=null&&m.tZ()&&this.a.SV==null?m:this.RR();
if(w.action=="scroll"){var A=!W.U(aK.CQ)&&w.wt,U=new ed(b.E.v,!0);U.data={d:"scroll",jP:w.jP.clone(),tJ:j,a8n:A};
U.G=W.U(aK.PJ)||A?y.Nt:y.pX;this.S(U)}if(m!=null&&l!=m&&this.El.wb()&&l.id!=y.pX&&l.id!=y.Nt)return;
if(w.action=="down")l.WQ(n,this,D,W,j);if(w.action=="rdown")l.Eq(n,this,D,W,j);if(w.action=="move")l.QD(n,this,D,W,j);
if(w.action=="up"||w.action=="iup"||w.action=="cancellast")l.H5(n,this,D,W,j,w.action=="cancellast");
if(w.action=="rup")l.cF(n,this,D,W,j);if(w.action=="iup"){W.nv("Space");this.h2(!0)}if(w.action=="cancellast"){if(n&&n.history.length!=0&&Date.now()-n.history[n.history.length-1].a1w<200){var I=new ed(b.E.v);
I.G=y.eb;I.data={d:"h_stepbck"};this.S(I)}}var g=this.cM;if(w.action=="down")g.WQ(n,this,D,W,j);if(w.action=="move")g.QD(n,this,D,W,j);
if(w.action=="up")g.H5(n,this,D,W,j);if(w.action=="down"||w.action=="up"){this.h2()}if(w.action=="down"||w.action=="up"||w.action=="ctx"){n.rR=!0}if((w.action=="up"||w.action=="rup")&&this.a.gW){this.a.gW=null;
M.disable(n,this,D,W)}};hB.prototype.Yr=function(w){var n=this.Nc(),W=this.gC;if(n&&this.RR().LL(W,this._0)){var D=n.u,j=D.xq.m,I=D.xq.n,U=0,M=0,m=16;
if(W.x<m)U=m-W.x;if(W.x>j-m)U=W.x-(j-m);if(W.y<m)M=m-W.y;if(W.y>I-m)M=W.y-(I-m);var l=this._0.U(aK.WO)?8:1;
if((U!=0||M!=0)&&(n.m*D.N>j||n.n*D.N>I)){U=Math.min(5,U*.5)*l;M=Math.min(5,M*.5)*l;if(W.x>m)U=-U;if(W.y>m)M=-M;
D.R.x+=U;D.R.y+=M;this.aqu({tJ:this.gC,action:"move"});n.tL=!0}}this.update()};hB.prototype.update=function(w){var n=this.Nc();
if(n==null)return;if(n.rR){var W=this.a.map;for(var D in W){if(W[D].G.BW)W[D].G.BW(n,this,this.Ir,this._0)}}if(n.zm)if(je.YG)je.D5(Math.max(n.m,n.n));
if(n.zm){n.tw()}var j=n.u,I=this.ft,U=this.ft=Date.now();if(n.zm||n.Iq||n.RP||n.tL||w||j.fd!=j.N||!j.$M.s9(j.R)){var M=j.fd;
if(j.fd!=j.N){var m=y.Jd.amZ(j.N,j.fd>j.N),l=.12;if(j.fd<j.N&&j.fd<m)j.fd=m;if(j.fd>j.N&&j.fd>m)j.fd=m;
var A=Math.abs(j.N-m)*(U-I)*.001/l;if(j.fd<j.N)j.fd=Math.min(j.N,j.fd+A);else j.fd=Math.max(j.N,j.fd-A)}var g=M==j.N?0:(j.fd-j.N)/(M-j.N);
j.$M.x=j.R.x+g*(j.$M.x-j.R.x);j.$M.y=j.R.y+g*(j.$M.y-j.R.y);this.NV.GZ(this.Ir,null);this.NV.mQ(n,this.oZ)}if((n.zm||n.tL||n.rR)&&(!this.gC.WS||n.Uu)){if(n.rR)n.hd();
this.cM.mQ(n,this.oZ,this.Ir);this.GX.awk(n,this._0);n.gL=!1}n.Uu=!1;n.rR=!1;n.zm=null;n.Iq=n.RP=n.tL=!1};
hB.prototype.rM=function(w){var n=w.target.tagName.toLowerCase(),W=w.target.getAttribute("type"),D=aK,j=D.$L(w.code,D.yG);
if(!((n=="input"||n=="select"||n=="button")&&D.$L(w.code,D.R4))){if(D.QC(w)&&n!="select"){w.preventDefault()}this._0.xa(D.Bo(w));
this.oe("down")}};hB.prototype.fW=function(w){if(w.key==" ")this._0.Ss();if(aK.$L(w.code,aK.xc))this._0.reset();
this._0.nv(aK.Bo(w));var n=w.target.tagName.toLowerCase();if(aK.QC(w)&&n!="select"){w.preventDefault()}this.oe("up")};
hB.prototype.oe=function(w){var n=this._0,W=this.Nc(),D=W!=null&&W.g.length!=0;if(this.lt.DJ()!=null){if(n.U(aK.QX)){this.lt.a02()}return}this.h2();
var j=this.BD(aK.CQ),I=n.U(aK.PJ),U=n.U(aK.WO);if(j&&n.U(aK.xD)&&w=="down"){var M=new ed(b.E.v),m=new ed(b.E.L);
M.G=y.eb;if(U){M.data={d:"h_stepfwd"}}else{M.data={d:"h_stepbck"}}if(this.El.DJ()!=null&&this.El.DJ().wb()){}else this.S(M)}if(j){var M=new ed(b.E.v),l=new ed(b.E.W1),m=new ed(b.E.L);
if(n.U(aK.Zb)&&n.U(aK.Eg)){m.data={d:b.c.P2,jW:"storwindow"};this.S(m)}if(!I&&w=="down")for(var A in eH.keys){var g=eH.keys[A],k=!0;
for(var L=0;L<g.length;L++)if(!n.U(g[L]))k=!1;if(k){M.G=y.DW;if(A=="hue2"&&U&&W.C[W.g[0]].add.SoLd==null)M.data={d:"auto",Fv:3};
else M.data={d:"start",u4:A}}}if(n.U(aK.c)){l.data=y.eZ.Jj(!0)}if(n.U(aK.Ak)){if(I)m.data={d:b.c.P2,jW:"csize"};
else if(W)m.data={d:b.c.UA,O0:U}}if(n.U(aK.Rn)){l.data=y.eZ.Jj()}if(n.U(aK.E)&&w=="down"){if(U)l.data={hZ:"mergeVisible"};
else l.data={hZ:"mergeLayersNew",E3:{__name:"Merge Layers",classID:"Mrg2"}}}if(n.U(aK.aM)){if(U&&this.Ir.No!=y.Sv)m.data={d:b.c.P2,jW:"afw_fade"};
else if(I){M.G=y.sT;M.data={d:"applylast"}}else m.data={d:b.c.$C}}if(n.U(aK.rP)){if(I&&W&&W.aV(W.g[0])){M.G=y.Yu;
M.data={d:h.Yt}}else{M.G=y.Yu;M.data={d:h.Vp,iZ:U}}}if(n.U(aK.Ga)){m.data={d:b.c.oj,AH:bk.Xh}}if(n.U(aK.Zb)){if(U){M.data=null;
if(I)m.data={d:b.c.P2,jW:"finfo"};else l.data={hZ:"inverse"}}else if(I)m.data={d:b.c.P2,jW:"isize"}}if(n.U(aK.KZ)){l.data={hZ:(U?"cut":"copy")+"ToLayer"}}if(n.U(aK.M$)){m.data={d:b.c.P2,jW:"preferences"}}if(n.U(aK.r1)){if(U){M.G=y.Yu;
M.data={d:h.tp}}else if(w=="down")m.data={d:b.c.P2,jW:"newproject"}}if(n.U(aK.ke)){if(I)m.data={d:b.c.P2,jW:"storwindow",IZ:0};
else{m.data={d:b.c.J0};n.reset()}}if(n.U(aK.b8)){m.data={d:b.c.apu};n.reset()}if(n.U(aK.ip)){m.data={d:b.c.oj,AH:bk.SU}}if(n.U(aK.qd)&&w=="down"){if(U){if(I)m.data={d:b.c.P2,jW:"saveforweb"};
else m.data={d:b.c.N0}}else m.data={d:b.c.LI}}if(n.U(aK.US)){if(U){M.G=y.Sv;M.data={d:"again"}}else m.data={d:b.c.CV,G:y.Sv}}if(n.U(aK.tM)){m.data={d:b.c.s_}}if(n.U(aK._j)){this.NV.K3()}if(n.U(aK.Pn)&&W&&W.j5()){m.data={d:b.c.jm}}if(n.U(aK.yq)||n.U(aK.vs)){M.G=y.Yu;
M.data={d:h.iv,vK:0};if(n.U(aK.yq))M.data.vK=U?3:2;else M.data.vK=U?0:1}if(n.U(aK.W8)&&W){M.G=y.Yu;M.data={d:h.Ll}}if(n.U(aK.yG)&&W){var $=0;
if(U)$++;if(I)$+=2;M.G=y.wA;M.data={d:"frompath",HD:[null,0,$]}}if(n.U(aK.k2)){l.data=y.QJ.Mf(0)}if(n.U(aK.R4)){var C=this.oZ.length,f=n.U(aK.WO)?-1:1;
if(C>1)this.NV.Rx((this.NV.wz()+C+f)%C)}if(n.U(aK.iI)){m.data={d:b.c.oj,AH:bk.pa}}if(n.U(aK.m5)){m.data={d:b.c.oj,AH:bk.ZX}}y.Jd.a0D(n,M);
if(this.El.DJ()!=null&&this.El.DJ().wb()){}else{if(M.data)this.S(M);if(l.data)this.S(l);if(m.data)this.S(m)}}if(!j&&I){var z;
if(n.U(aK.yq))z="Bckw";if(n.U(aK.vs))z="Frwr";if(n.U(aK.W8))z="Back";if(n.U(aK.k2))z="Frnt";if(z){var l=new ed(b.E.W1);
l.data={hZ:"select",E3:{__name:"Select",classID:"slct",null:{t:"obj ",v:[{t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:z}}]},MkVs:{t:"bool",v:!1}}};
this.S(l)}}if(W&&W.g.length!=0){var s=W.C[W.g[0]],O=s.eL;if(O==1||O==3||j){var M=new ed(b.E.v),a=O==3?s.NP(W).z:s._N();
if(a){var X=a.$P?W.u.zC.join("")=="111"?1:2:0;M.G=y.Nt;if(a&&n.U(aK.QX)&&X!=0){M.data={d:"mskView",Z:0}}if(a&&n.U(aK.abD)){M.data={d:"mskView",Z:X==1?0:1}}if(a&&n.U(aK.atV)){M.data={d:"mskView",Z:X==2?0:2}}if(M.data)this.S(M)}}}var P=n.$N();
if(W&&j&&2<=P&&P<=5){var Z=[1,1,1];if(P>2){Z=[0,0,0];Z[P-3]=1}var Y=new ed(b.E.v,!0);Y.G=y.pX;Y.data={d:"setcls",zC:Z};
this.S(Y)}if(!n.U(aK.CQ)&&!I&&w=="down"){var M=new ed(b.E.v),m=new ed(b.E.L),K=this.a.map[this.Ir.No],S=-1;
for(var L=0;L<this.a.keys.length;L++)if(this.a.keys[L]&&this.BD(this.a.keys[L]))S=L;if(S!=-1){var G=null;
if(K.rq!=S)G=this.a.cY[S];if(K.rq==S&&U)G=(K.av0+1)%this.a.Bu[S].length;if(G!=null){var V=this.a.Bu[S][G].G.id,T=this.Ir.nf;
if((T==null||T.indexOf(parseInt(V))!=-1)&&!this.gC.WS)m.data={d:b.c.CV,G:V}}}if(n.U(aK.Ga))m.data={d:b.c.CV,G:y.pX};
if(n.U(aK.ip))m.data={d:b.c.CV,G:y._E};if(n.U(aK.Pn))m.data={d:b.c.oj,AH:bk.X$,vK:2};if(n.U(aK.Rn))m.data={d:b.c.oj,AH:bk.X$,vK:3};
if(m.data)this.S(m);if(n.U(aK.aui)&&W&&W.g.length==1){var s=W.C[W.g[0]];M.G=y.Yu;var R=s.m7(0)||s.m7(1)||s.m7(2)||s.m7(31);
M.data={d:h.ge,qY:R?[[!1,!1,!1,!1],[0,1,2,31]]:[[!0],[31]]};this.S(M)}var P=n.$N();if(D&&P!=-1&&this.BD(aK.xL[P])){var x=W.g[0],s=W.C[x],v=aK.Af(Math.round(100*s.opacity/255),P);
M.G=y.Yu;M.data={d:h.JM,qY:Math.round(255*v/100)};this.S(M)}var N=this.Ir.jq;if(n.U(aK.R4)){m.data={d:b.c.sa,Z:N==0?1:0};
this.S(m)}if(n.U(aK.aM)||n.U(aK.QX)&&N==2){var u=document.fullscreenElement!=null==(N==2);m.data={d:b.c.sa,Z:N==0?2:0,dJ:u};
this.S(m)}if(n.U(aK.Hk)&&!this.gC.WS){M.G=y.wA;M.data={d:"qmask"};this.S(M)}}if(!n.U(aK.CQ)&&!I&&U){var M=new ed(b.E.v),m=new ed(b.E.L);
if(n.U(aK.W8))m.data={d:b.c.P2,jW:"shortcuts"};if(n.U(aK.Qn))m.data={d:b.c.P2,jW:"fill"};if(n.U(aK.ah0))m.data={d:b.c.P2,jW:"sel_feather"};
if(D&&(n.U(aK.fQ)||n.U(aK.Ne))){var x=W.g[0],s=W.C[x],H=dD.mS,F=H.length,t=H.indexOf(s.Bx);M.G=y.Yu;
M.data={d:h.jC,qY:(t+F+(n.U(aK.fQ)?1:-1))%F};this.S(M)}if(m.data)this.S(m)}var M=new ed(b.E.v),o=w=="down"&&(this.BD(aK.m2)||this.BD(aK.on));
if((j||I)&&o){M=new ed(b.E.W1);M.data=y.JT.YE(j?"BckC":"FrgC");this.S(M)}else if(W&&o&&!this.gC.WS){if(W.J!=null){M=new ed(b.E.W1);
M.data={hZ:"delete"}}else if(W.g.length!=0){var s=W.C[W.g[0]];if(s.eL==1)M.data={d:h.kR};else if(s.eL==3)M.data={d:h.Wu};
else M.data={d:h.du};M.G=y.Yu}this.S(M)}if(this.El.DJ()!=null){if(n.U(aK.QX)){this.El.DJ().a1s()}else{this.El.DJ().oe(W,this,this.Ir,n)}}if(this.Ir.No==null)return;
var K=this.RR();if(this.El.DJ()==null||this.a.SV)K.oe(W,this,this.Ir,n)};hB.prototype.BD=function(w){var n=this._0,W=this.a.map[this.Ir.No].G,top=this.El.DJ(),D=this.Nc();
return n.U(w)&&!W.wO(w,D)&&(top==null||!top.wO(w,D))};hB.prototype.AN=function(w){var n=this.a1L,W=this.Y$;
this.Ir.jq=w;var D=e.LY,j=this.SP.e;if(D(j))this.dd.removeChild(j);var I=this.z7.e;if(D(I))this.dd.removeChild(I);
var U=this.GX.e;if(D(U))n.removeChild(U);var M=this.NV.e;if(D(M))n.removeChild(M);var m=this.cM.e;if(D(m))n.removeChild(m);
if(w==0){this.dd.appendChild(j);this.dd.appendChild(I);W.appendChild(n);n.appendChild(U);n.appendChild(M);
n.appendChild(m)}if(w==1){this.dd.appendChild(j);n.appendChild(M)}if(w==2){n.appendChild(M)}this.NV.AN(w==2?1:0);
this._K()};hB.prototype.aaM=function(w){if(this.WW())return 1;if(e.aqj()==0){this.Ir={};this.zl=function(n,W){return Math.sqrt(n*W)}}return-1};
function dP(w){eg.call(this);if(w==null)return;this.gA=null;this.ag=null;this.e=e.t("div","sbar"+" "+w);
this.Er=new e.t("div","top");this.Er.innerHTML="> <";this.e.appendChild(this.Er);this.zb=1;this.Er.addEventListener("click",this.am7.bind(this),!1)}dP.prototype=new eg;
dP.prototype.am7=function(w){if(this.gA!=null&&this.gA<500&&this.zb==0)return;if(this.zb==0)this.CS(!0);
else this.collapse(!0)};dP.prototype.axy=function(w){this.zb=w;this.Er.innerHTML=this.zb==0?"< >":"> <"};
dP.prototype.a4I=function(){var w=new ed(b.E.L,!0);w.data={d:b.c.aR};this.S(w)};dP.prototype.CS=function(w){this.axy(1);
if(w)this.a4I()};dP.prototype.collapse=function(w){this.axy(0);if(w)this.a4I()};dP.prototype.Go=function(){return this.zb==1};
function bw(w,n){dP.call(this,"vcolumn");this.Zv=w;this.a7K=n;this.Rm();this.Bz=e.t("div");this.Bz.setAttribute("style","cursor:default;");
this.awu=this.aiw.bind(this);this.ax4=this.aze.bind(this);this.arP=this.a1x.bind(this);e.L_(this.e,this.awu);
this.e.appendChild(this.Bz);this.CM=e.t("div");this.Bz.appendChild(this.CM);this.oI=-1;this.aiL=e.t("div","float");
var W=this.PG=e.t("canvas","gsicon"),D=Math.round(12*e.V());W.width=W.height=D;var j=W.getContext("2d");
j.moveTo(2,2);j.lineTo(D-2,D-2);j.moveTo(2,7);j.lineTo(D-7,D-2);j.stroke();this.PG.setAttribute("style","position:absolute; bottom:0; left:0; cursor:nesw-resize;");
e.ZS(this.PG);e.L_(this.PG,this.awu);e.gH(W);this.wB=[];this.ih=[];this.a0h=null;this.pz=null;this.asP=0}bw.prototype=new dP;
bw.prototype.aiw=function(w){var n=w.target==this.PG;if(!n){if(w.target!=this.e)return;if(!this.Go())return}else{var W=this.wB[this.oI].K5;
W.style.pointerEvents="none";var D=W.getBoundingClientRect();this.a0h=[D.width,D.height];this.ih[this.oI]=[D.width,D.height]}w.stopPropagation();
this.pz=e.rv(w,document.body);this.asP=this.Zv;e.Ko(document,this.ax4);e.d6(document,this.arP)};bw.prototype.aze=function(w){var n=e.rv(w,document.body);
if(this.Go()){this.Zv=this.asP+this.pz.x-n.x;this.Rm()}else{var W=this.ih[this.oI],D=this.a0h;W[0]=D[0]+this.pz.x-n.x;
W[1]=D[1]+n.y-this.pz.y}var j=new ed(b.E.L,!0);j.data={d:b.c.aR};this.S(j)};bw.prototype.a1x=function(w){if(!this.Go()){var n=this.wB[this.oI].K5;
n.style.pointerEvents="auto"}e.MC(document,this.ax4);e.i_(document,this.arP)};bw.prototype.ak1=function(w){w.h("showFloat",this.au9,this);
w.h("hideFloat",this.cm,this);this.wB.push(w);w.parent=this;this.Bz.appendChild(w.e)};bw.prototype.axs=function(L){var w=this.wB[L];
w.removeEventListener("showFloat",this.au9,this);w.removeEventListener("hideFloat",this.cm,this);this.wB.splice(L,1);
w.parent=null;this.Bz.removeChild(w.e)};bw.prototype.akH=function(){return this.wB.length};bw.prototype.ug=function(){for(var L=0;
L<this.wB.length;L++)this.wB[L].ug()};bw.prototype.au9=function(w){this.ug();var n=this.aiL;this.CM.appendChild(n);
this.oI=this.wB.indexOf(w.currentTarget);var W=this.wB[this.oI].K5;e._g(n);n.appendChild(W);n.appendChild(this.PG);
this.zl(this.gA,this.ag)};bw.prototype.cm=function(w){this.ug();if(this.oI!=-1){this.CM.removeChild(this.aiL);
this.oI=-1}};bw.prototype.Rm=function(){function w(n){return Math.round(n*e.V())/e.V()}this.e.setAttribute("style","width: "+this.Zv+"px; border-left-width:"+w(4)+"px; cursor:ew-resize;")};
bw.prototype.CS=function(w){this.Rm();this.cm();for(var L=0;L<this.wB.length;L++)this.wB[L].CS();dP.prototype.CS.call(this,w)};
bw.prototype.collapse=function(w){this.e.removeAttribute("style");for(var L=0;L<this.wB.length;L++)this.wB[L].collapse();
dP.prototype.collapse.call(this,w)};bw.am1=11;bw.prototype.zl=function(w,n){this.gA=w;this.ag=n;n-=bw.am1;
var W=this.wB.length;if(W==0)return;if(!this.Go()){var D=n<400?n:400+(n-400)*.5;for(var L=0;L<W;L++){var j=this.wB[L],I=this.ih[L];
j.zl(I?I[0]:this.Zv,I?I[1]:D)}}else{var U=n;for(var L=0;L<W;L++){var j=this.wB[L],M=j.arh();if(L==W-1){M=U;
j.e.style.borderBottom="none"}j.zl(this.Zv,M);U-=M+4}}};function g8(w){eg.call(this);this.e=e.t("div");
this.Bz=null;this.s1=0;this.w_=0;this.a9u=w;this.afl=this.jx.bind(this);this.a9a=this.Gi.bind(this);
this.asO=this.WB.bind(this);this.lo=null;this.By=null;this.DH=null;e.L_(this.e,this.afl);var n=this.e,D="<svg class=\"gsicon\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">";
n.addEventListener("touchmove",e._L,!1);this.a4c=!0;this.uH=[];var W=this.aqe=e.t("div");W.setAttribute("style","float:right; padding:4px;display:none; position:relative;z-index:1;");
this.e.appendChild(W);var j=[[0,13,3],[0,13,4],[0,13,5],"Blog","API",D+"<path d=\"m21.325 9.308c-.758 0-1.425.319-1.916.816-1.805-1.268-4.239-2.084-6.936-2.171l1.401-6.406 4.461 1.016c0 1.108.89 2.013 1.982 2.013 1.113 0 2.008-.929 2.008-2.038s-.889-2.038-2.007-2.038c-.779 0-1.451.477-1.786 1.129l-4.927-1.108c-.248-.067-.491.113-.557.365l-1.538 7.062c-2.676.113-5.084.928-6.895 2.197-.491-.518-1.184-.837-1.942-.837-2.812 0-3.733 3.829-1.158 5.138-.091.405-.132.837-.132 1.268 0 4.301 4.775 7.786 10.638 7.786 5.888 0 10.663-3.485 10.663-7.786 0-.431-.045-.883-.156-1.289 2.523-1.314 1.594-5.115-1.203-5.117zm-15.724 5.41c0-1.129.89-2.038 2.008-2.038 1.092 0 1.983.903 1.983 2.038 0 1.109-.89 2.013-1.983 2.013-1.113.005-2.008-.904-2.008-2.013zm10.839 4.798c-1.841 1.868-7.036 1.868-8.878 0-.203-.18-.203-.498 0-.703.177-.18.491-.18.668 0 1.406 1.463 6.07 1.488 7.537 0 .177-.18.491-.18.668 0 .207.206.207.524.005.703zm-.041-2.781c-1.092 0-1.982-.903-1.982-2.011 0-1.129.89-2.038 1.982-2.038 1.113 0 2.008.903 2.008 2.038-.005 1.103-.895 2.011-2.008 2.011z\"/>",D+"<path d=\"M23.954 4.569c-.885.389-1.83.654-2.825.775 1.014-.611 1.794-1.574 2.163-2.723-.951.555-2.005.959-3.127 1.184-.896-.959-2.173-1.559-3.591-1.559-2.717 0-4.92 2.203-4.92 4.917 0 .39.045.765.127 1.124C7.691 8.094 4.066 6.13 1.64 3.161c-.427.722-.666 1.561-.666 2.475 0 1.71.87 3.213 2.188 4.096-.807-.026-1.566-.248-2.228-.616v.061c0 2.385 1.693 4.374 3.946 4.827-.413.111-.849.171-1.296.171-.314 0-.615-.03-.916-.086.631 1.953 2.445 3.377 4.604 3.417-1.68 1.319-3.809 2.105-6.102 2.105-.39 0-.779-.023-1.17-.067 2.189 1.394 4.768 2.209 7.557 2.209 9.054 0 13.999-7.496 13.999-13.986 0-.209 0-.42-.015-.63.961-.689 1.8-1.56 2.46-2.548l-.047-.02z\"/></svg>",D+"<path d=\"M23.9981 11.9991C23.9981 5.37216 18.626 0 11.9991 0C5.37216 0 0 5.37216 0 11.9991C0 17.9882 4.38789 22.9522 10.1242 23.8524V15.4676H7.07758V11.9991H10.1242V9.35553C10.1242 6.34826 11.9156 4.68714 14.6564 4.68714C15.9692 4.68714 17.3424 4.92149 17.3424 4.92149V7.87439H15.8294C14.3388 7.87439 13.8739 8.79933 13.8739 9.74824V11.9991H17.2018L16.6698 15.4676H13.8739V23.8524C19.6103 22.9522 23.9981 17.9882 23.9981 11.9991Z\"/></svg>"];
for(var L=0;L<j.length;L++){var I=new iP(j[L]);this.uH.push(I);I.e.setAttribute("style","margin-left:"+(L<7?4:0)+"px;cursor:pointer;");
I.h("click",this.lE,this)}}g8.prototype=new eg;g8.prototype.f=function(){var w=this.aqe;e._g(w);for(var L=0;
L<this.uH.length;L++){var n=this.uH[L];if(L<5)n.f();w.appendChild(n.e)}};g8.prototype.lE=function(w){var L=this.uH.indexOf(w.currentTarget);
if(L==0){if(window.showCap)window.showCap();return}var n=" issues learn blog api twitter facebook".split(" "),W=" //github.com/photopea/photopea/issues //www.photopea.com/learn //blog.photopea.com //www.photopea.com/api //www.reddit.com/r/photopea //www.twitter.com/photopeacom //www.facebook.com/photopea".split(" "),D=window.ga;
if(D)D("send","event","Links",n[L]);var j=new ed(b.E.L,!0);j.data={d:b.c.aT,link:W[L]};this.S(j)};g8.prototype.jx=function(w){if(w.avv){w.preventDefault();
w.stopPropagation()}var n=window;e.Ko(n,this.a9a);e.d6(n,this.asO);n=this.Bz;this.lo=new ec(parseInt(n.style.left),parseInt(n.style.top));
this.By=e.rv(w,this.e);this.DH=n.getBoundingClientRect()};g8.prototype.Gi=function(w){var n=e.rv(w,this.e),W=this.lo.x+n.x-this.By.x,D=this.lo.y+n.y-this.By.y,j=this.s1-this.DH.width,I=this.w_-this.DH.height;
if(this.a9u)this.Bz.style.left=Math.min(0,Math.max(j,W))+"px";else this.Bz.style.top=Math.min(0,Math.max(I,D))+"px";
if(W-10>0){this.By.x=n.x-10;this.lo.x=0}if(W+10<j){this.By.x=n.x+10;this.lo.x=j}};g8.prototype.WB=function(w){var n=window;
e.MC(n,this.a9a);e.i_(n,this.asO)};g8.prototype.ayI=function(w){if(this.Bz){this.e.removeChild(this.Bz)}this.Bz=w;
this.e.appendChild(w);w.style.position="absolute";if(this.a9u)w.style.left=0;else w.style.top=0};g8.prototype.zl=function(w,n){this.s1=w;
this.w_=n;this.e.setAttribute("style","position:relative; width: "+w+"px; height: "+n+"px; overflow:hidden; white-space: nowrap; ");
var W=this.Bz.firstChild,D=this.aqe,j=W?W.firstChild.getBoundingClientRect().width+80:1e9,I=170,U=this.a4c&&w>j+I;
D[hk.ik][hk.an6]=U?"":hk.lx;var M=this.uH;for(var L=0;L<M.length;L++){var m=L>4||w-j>500?"":hk.lx,l=M[L];
l.e.style.display=m}};g8.prototype.abJ=function(){this.Bz.style.left="0";this.Bz.style.top="0"};function gz(){eg.call(this);
this.ww=null;this.uz=gz.b8;this.ae9="";this.e=e.t("div","rightbar");this.Zj=[new bw(300),new bw(268,!0)];
this.wB=[new g9,new g9,new g9,new g9,new g9,new g9,new g9];this.a9b=[]}gz.prototype=new eg;gz.prototype.f=function(){var w=this.uz;
for(var L=0;L<w.length;L++)w[L].BT.f()};gz.b8=[{BT:new is,us:3},{BT:new h1,us:1},{BT:new eO,us:4},{BT:new bg,us:2},{BT:new cY(!0),us:5},{BT:new aO,us:0},{BT:new cl,us:5},{BT:new gf,us:3},{BT:new he,us:0},{BT:new b9,us:3},{BT:new c6,us:2},{BT:new d4,us:4},{BT:new aZ,us:3},{BT:new a9,us:5},{BT:new cY(!1),us:5},{BT:new c9,us:2},{BT:new eF,us:3},{BT:new f7,us:1},{BT:new ku,us:0},{BT:new da,us:5},{BT:new gq,us:6,Cc:!0},{BT:new dU,us:6,Cc:!0},{BT:new aC,us:6,Cc:!0},{BT:new fE,us:6,Cc:!0}];
(function(){var w=[{id:et.ip.aaG,name:"Gallery",url:"plugins/gallery.html",icon:"===data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKAAAACgBAMAAAB54XoeAAAAAXNSR0IB2cksfwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAB5QTFRFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAtyhvagAAAAp0Uk5TAP+mc4pfC+rILiKk3cQAAALjSURBVHic7dq/bxMxFAdwKy1HM16up4QtDCDYkv8gTIgtZWGNWMpIJKhgLAtriyrx71Lnh8/2e76c3/tOxW9olUb56Fvf3bPPOWNKlSpVqtSxPv6uIfXj1d77hOFs/bTeGc6r68UjuESCjTHPkF5dr801FrwxV1iwNS+x4MRs7a+3iNP5j5Vmxv5sEN7+fJnuwDkGHFlrB95hwLEDNxiwciDGM+Zpgw9v6vrXBxg4fr+/Lr6F54cYrNz1OtlAQK/Hf0eAI78bzPVgdRu0l40avAgblhdRCEYddKIFySS0VoJkErpRgmTO6P5nETiOPa+disBzCq5U4HMKflWB9xR8oQLfUfBSBTILA3eYReAtBWcqkHrd5ws4rOAHBX7aMCe2Ww2KwHsK6i49eHOAty94g4VPAfhJSjGNngUj7ko+0e/OYXoPMwrB+WDwcIIs4r9XQcSMxdJy/4kTEb2AJ0B3p08iChecy+NnLslboiWxtxWxIm9KFu1em6IRBbcVwcDTiHz1gUEfHXo/3QNGTYoe6FwwavQDI6bB6OryG4AMJD2v1YFMmx8UMQkyU+WgiCmQjGAU8Tx14FMgu9nkRUz0ySTIBvQipvpkEkzshrmIhxFmIvJgIqCL2NMneTC5XXeItIxenwKTAQ8RvT5JIrJgz35iGwRkInJgT0BacUQOzNrwjCMyYFZAEpEBM3dk21NgZsC4CVEwe8u47QeZPpgVkYCCPe2mD8weQVuLHlC06d6kQcEIRhEjUPitQJsCP8s8P2IIMvetuREDUHSIo4gBqPhepeVARcAuogdW4hG01VDwi8ZzETtQF9CtwjtQGfAYsQPVX501ISi+SLpaB6ByBG21AYioNRps0aA90FiwQYOPEcFggwbrBRps0GBdwAIW8AmBW6w3la8z+Zrhn7e5woIt/pkl4d1JqlbqpWFYs40xf5GgfdZtvMV50zvVLRSt1/ul8QPqccF4X7tUqVKl/uf6BxTPzN+MDvNvAAAAAElFTkSuQmCC"}];
for(var L=0;L<w.length;L++)gz.b8.push({BT:new cK(w[L],100+L),us:6,Cc:!0})}());gz.prototype.a6j=function(w){for(var L=0;
L<w.length;L++){var n=w[L],W=new cK(n,"plg_"+n.name);this.uz.push({BT:W,us:6});this.a9b.push(W.JY)}this.Uc()};
gz.prototype.GZ=function(w,n){this.ww=w;var W=this.uz;for(var L=0;L<W.length;L++)W[L].BT.GZ(w,n);if(n==bk.dp||n==bk.bI)this.Uc()};
gz.prototype.E$=function(w){var n=this.uz;for(var L=0;L<n.length;L++)n[L].BT.E$(w)};gz.prototype.zl=function(w,n){this.gA=w;
this.ag=n;this.Uc();this.Zj[0].zl(w,n);this.Zj[1].zl(w,n)};gz.prototype.Uc=function(){var w=this.ww,n=this.gA,W=this.ag;
if(w==null||n==0)return;var D=w.Vy.concat(this.a9b),j=n<500||n<700&&n<W,I=JSON.stringify(D)+","+j;if(I!=this.ae9){this.ae9=I;
e._g(this.e);var U=[];for(var L=0;L<this.Zj.length;L++){var M=this.Zj[L];U[L]=M.Go();while(M.akH()!=0)M.axs(0);
M.CS()}var m=[];for(var L=0;L<this.wB.length;L++){var l=this.wB[L];l.CS();while(l.at1()!=0)l.kk(0);m.push(0)}for(var L=0;
L<D.length;L++){var A=this.a8c(D[L].toString());if(A==null)continue;this.wB[A.us].f9(A.BT);this.wB[A.us].Rx(0);
m[A.us]++}var g=[];for(var L=0;L<m.length;L++){if(m[L]==0)continue;var k=L<3||j?1:0,M=this.Zj[k];M.parent=this;
M.ak1(this.wB[L]);g[k]=!0}for(var L=0;L<this.Zj.length;L++)if(g[L])this.e.appendChild(this.Zj[L].e);
this.Zj[0].collapse();if(n<700||this.ww.compact||!U[1]){this.Zj[1].collapse()}var $=new ed(b.E.L,!0);
$.data={d:b.c.aR};this.S($)}};gz.prototype.a8c=function(w){for(var L=0;L<this.uz.length;L++)if(this.uz[L].BT.JY==w)return this.uz[L]};
gz.prototype.ayM=function(w){var n=this.a8c(w);this.wB[n.us].f9(n.BT)};gz.prototype.mQ=function(w,n,W){var D=this.uz;
for(var L=0;L<D.length;L++)D[L].BT.mQ(w,n,W)};gz.prototype.WQ=function(w,n,W,D,j){var I=this.uz;for(var L=0;
L<I.length;L++)I[L].BT.WQ(w,n,W,D,j)};gz.prototype.QD=function(w,n,W,D,j){var I=this.uz;for(var L=0;
L<I.length;L++)I[L].BT.QD(w,n,W,D,j)};gz.prototype.H5=function(w,n,W,D,j){var I=this.uz;for(var L=0;
L<I.length;L++)I[L].BT.H5(w,n,W,D,j)};function gP(w,n){dP.call(this,"toolbar");this.e.removeChild(this.Er);
this.uI=e.t("div","tools");this.e.appendChild(this.uI);this.nf=null;this.No=null;this.ar8=n;this.OQ=null;
this.ana=-1;this.avf={};this.an2=w;this.a=null;this.Qf=null;this.nU=null;this.QL=null;this.cb=new aD;
this.cb.e.style.marginTop="5px";this.cb.e.style.marginBottom="3px";this.cb.parent=this;this._A=new iP(e.DZ("lrs/mask"),!1,[6,6,1]);
this._A.h("click",function(I){var U=new ed(b.E.v,!0);U.G=y.wA;U.data={d:"qmask"};this.S(U)},this);var W=new jw(null,["Ctrl","Alt","Shift","No Touch"],!0,null,null,!0);
W.h(b.E.A,this.a0z,this);var D=e.t("span","rangecontFloat form padded");D.appendChild(W.e);D.setAttribute("style","position:absolute; width:119px; z-index:2; padding-right:0px; ");
var j=this.e;this.aiA=[!1,!1,!1,!1];this.HP=new iP(e.DZ("kb"),!1,"Virtual Keys");this.HP.h("click",function(I){var U=this.HP.e.getBoundingClientRect();
D.style.top=U.top-110+"px";D.style.left=U.left+U.width+8+"px";if(e.LY(D)){e.Qa({e:D},j)}else{j.appendChild(D);
e.r3({e:D})}},this)}gP.prototype=new dP;gP.prototype.a0z=function(w){var n=w.target.b();this.HP.$(n[0]||n[1]||n[2]||n[3]);
var W=new ed(b.E.L,!0);for(var L=0;L<4;L++){if(n[L]!=this.aiA[L]){W.data={d:b.c.aqt,WS:n[L],abF:["ControlLeft","AltLeft","ShiftLeft","NoTouch"][L]};
this.S(W)}}this.aiA=n.slice(0)};gP.prototype.awk=function(w,n){this.OQ=n;if(w==null||w.g.length==0||w.C[w.g[0]]==null)return;
var W=w._A()!=null,D=w.u.zC,j=w.C[w.g[0]].eL,I=j==1||j==3||W||D[0]+D[1]+D[2]==1;this.cb.anH(I);this._A.$(W)};
gP.prototype.agG=function(w,n){var W=w.length,D=[];for(var L=0;L<W;L++)D[L]=w[L].slice(0);w=D;var j=[1,2,4,5,7,8,7,9,11,12,14,15,14,16,10,11,1,3,17,18,7,6,13,14],I=Math.min(j.length/2,W-n);
for(var L=0;L<I;L++){var U=j[2*L],M=j[2*L+1];w[U]=w[U].concat(w[M]);w[M]=null}for(var L=0;L<w.length;
L++)if(w[L]==null){w.splice(L,1);L--}return w};gP.prototype.awf=function(w,n){for(var L=0;L<n.length;
L++)for(var W=0;W<n[L].length;W++)if(n[L][W].G.id==w)return L};gP.prototype.aue=function(w){var n=this.an2;
this.Qf=[];this.nU=[];this.QL=[];this.a=[];var W=n.Bu;if(w!=null&&this.ar8)W=this.agG(W,w);var D=this.nf;
if(D){var j=[];for(var L=0;L<W.length;L++){var I=[];for(var U=0;U<W[L].length;U++){var M=W[L][U];if(D==null||D.indexOf(parseInt(M.G.id))!=-1)I.push(M)}if(I.length>0)j.push(I)}W=j}for(var L=0;
L<W.length;L++){var m=[],l=this.Qf.length,A=null,g=-1;for(var U=0;U<W[L].length;U++){var M=W[L][U].G,k=this.awf(M.id,n.Bu),$=n.keys[k];
if($==aK.Ga&&U==1)$=aK.ip;this.a.push(M);var C=new gj(M.name,$,M.GH,this.Qf.length,L,W[L].length>1);
this.Qf.push(C);var f=this.avf[M.id];if(f==null)f=0;if(f>g){g=f;A=C}C.h(b.E.A,this.p8,this);C.h("mover",this.Gu,this);
m.push({name:M.name,qg:M.GH,pn:$?$.DG:""})}this.nU.push(A);this.QL.push(m.length==1?null:[m,l])}};gP.prototype.zl=function(w,n){var W=this.ag=n,D=32;
if(1<e.V()&&e.V()<1.5)D=18+14*(1/e.V());var j=39+23,I=Math.floor((W-j)/D);if(I!=this.ana){this.ana=I;
this.aue(I);this.Ct()}var U=this.nU.length*D+j,M=Math.min(1,W/U);if(.75<=M){this.uI.setAttribute("style","width:34px; transform-origin: top left; transform: scale("+M+","+M+");");
this.e.setAttribute("style","height:"+(n-2)+"px;")}else{W-=4;this.uI.setAttribute("style","height: "+W+"px; width:"+Math.ceil(U/W)*34+"px");
this.e.setAttribute("style","")}};gP.prototype.f=function(){if(this.a==null)return;for(var L=0;L<this.Qf.length;
L++)this.Qf[L].f()};gP.prototype.p8=function(w){var n=new ed(b.E.L,!0);n.data={d:b.c.CV,G:this.a[w.id].id};
this.S(n)};gP.prototype.alK=function(w){var n=w.target.amk+w.target.aJ()[0];this.Qf[n].WB(null,!0)};
gP.prototype.Gu=function(w){var n=this.OQ,W=new ed(b.E.L,!0);W.data={d:b.c.xl};this.S(W);var D=w.target,j=this.QL[D.rq];
if(j==null)return;var I=new cA(j[0],null,!0);I.amk=j[1];I.rq=D.rq;I.h("select",this.alK,this);I.parent=this;
I.f();var U=D.e.getBoundingClientRect(),W=new ed(b.E.L,!0);W.data={d:b.c.Uq,BT:I,x:U.left+U.width+8,y:U.top};
if(n==null||!(n.U(aK.Xu)||n.U(aK.CQ)))this.S(W)};gP.prototype.Ct=function(w){if(w==null)w=this.No;this.No=w;
if(this.a==null)return;this.avf[w]=Date.now();var n=-1;for(var L=0;L<this.a.length;L++)if(this.a[L].id==w)n=L;
for(var L=0;L<this.Qf.length;L++){var W=this.Qf[L];W.amb(n==L)}if(n==-1)return;this.nU[this.Qf[n].rq]=this.Qf[n];
e._g(this.uI);var D=this.nU;for(var L=0;L<D.length;L++){this.uI.appendChild(D[L].e)}if(!this.ar8)return;
this.uI.appendChild(this.cb.e);if(this.ag>640)this.uI.appendChild(this._A.e);this.uI.appendChild(this.HP.e)};
gP.prototype.GZ=function(w,n){if(n==bk.bI&&w.nf){this.nf=w.nf;this.aue();this.Ct()}this.cb.ayV(w.Gp,w.as)};
function gj(w,n,W,D,j,I){eg.call(this);this.VA=0;this.G5=this.a6P.bind(this);this.rq=j;this.aZ=D;this.lU=w;
this.HU=n;this.acc=I;this.GH=W;this.e=e.t("button","");this.e.innerHTML=e.DZ(this.GH);if(this.acc){var U=e.t("img","gsicon");
U.setAttribute("src",PIMG["tools/corner"]);U.setAttribute("style","position:absolute; right:0; bottom:0; width:100%; height:100%;");
this.e.appendChild(U)}this.e.addEventListener("touchstart",e._L,!1);this.f();e.L_(this.e,this.jx.bind(this));
e.d6(this.e,this.WB.bind(this));this.e.addEventListener("contextmenu",this.G5,!1);this.e.addEventListener("contextmenu",gj.oz,!1)}gj.prototype=new eg;
gj.oz=function(w){w.stopPropagation();w.preventDefault();return!1};gj.prototype.f=function(){var w=this.HU?" ("+this.HU.DG+")":"";
this.e.setAttribute("title",fV.get(this.lU)+w)};gj.prototype.jx=function(w){gj.jf=this.aZ;this.VA=setTimeout(this.G5,160)};
gj.prototype.WB=function(w,n){if(n==null&&gj.jf!=this.aZ)return;clearTimeout(this.VA);var W=new ed(b.E.A,!1);
W.target=this;W.id=this.aZ;this.S(W)};gj.prototype.a6P=function(w){var n=new ed("mover",!1);n.target=this;
n.id=this.aZ;this.S(n)};gj.prototype.amb=function(w){this.e.className=w?"toolbtn active":"toolbtn"};
function hn(){eg.call(this);this.e=e.t("div","topbar");this.bo=e.t("span","");this.a35=0;this.e.appendChild(this.bo);
this.HI=null;this.XI=null;this.sb=[];this.Vy=[];var w=this.jx.bind(this);for(var L=0;L<hn.data.length;
L++){var n=e.t("button");this.sb.push(n);this.bo.appendChild(n);n.addEventListener("mouseover",w,!1);
e.L_(n,w)}this.QP=new iP([0,13,0],!1,null,!0);this.QP.h("click",this.nl,this);this.e.appendChild(this.QP.e);
this.Fh=new iP(e.DZ("tools/zoom",null,"autoscale"),!1,[12,86]);this.Fh.h("click",this.nl,this);this.e.appendChild(this.Fh.e);
this.vj=new iP("<svg class=\"gsicon\" version=\"1.1\" width=\"20\" height=\"20\" viewBox=\"8 8 20 20\"><path d=\"m 10,16 2,0 0,-4 4,0 0,-2 L 10,10 l 0,6 0,0 z\"></path><path d=\"m 20,10 0,2 4,0 0,4 2,0 L 26,10 l -6,0 0,0 z\"></path><path d=\"m 24,24 -4,0 0,2 L 26,26 l 0,-6 -2,0 0,4 0,0 z\"></path><path d=\"M 12,20 10,20 10,26 l 6,0 0,-2 -4,0 0,-4 0,0 z\"></path></svg>",!1,"Fullscreen");
this.vj.h("click",this.nl,this);this.e.appendChild(this.vj.e)}hn.prototype=new eg;hn.prototype.aqk=function(){if(this.Vy.length!=0)return;
for(var L=0;L<hn.data.length;L++){var w=hn.data[L],n=new cA(w.items,w.Zf);n.parent=this;this.Vy.push(n)}this.f()};
hn.prototype.f=function(){this.QP.f();this.Fh.f();this.vj.f();for(var L=0;L<this.sb.length;L++)this.sb[L].textContent=fV.get(hn.data[L].name);
this.afC();for(var L=0;L<this.Vy.length;L++)this.Vy[L].f()};hn.prototype.nl=function(w){var n=new ed(b.E.L,!0);
if(w.target==this.QP)n.data={d:b.c.P2,jW:"account"};else if(w.target==this.Fh)n.data={d:b.c.$C};else n.data={d:b.c.sa,dJ:!0};
this.S(n)};hn.prototype.a4v=function(w,n){this.HI=w;this.XI=n};hn.prototype.GZ=function(w,n){this.XI=w;
if(n==bk.bI){var W=w.aAm;e._g(this.bo);for(var L=0;L<this.sb.length;L++){if(W==null||W[L]==1||W[L]instanceof Array)this.bo.appendChild(this.sb[L]);
if(W!=null&&W[L]instanceof Array){this.aqk();this.Vy[L].aub(W[L])}}this.e.removeChild(this.QP.e);this.e.removeChild(this.Fh.e);
this.e.removeChild(this.vj.e);if(w.aE)this.e.appendChild(this.QP.e);this.e.appendChild(this.Fh.e);this.e.appendChild(this.vj.e)}this.afC()};
hn.prototype.afC=function(w,n){var W=this.QP,D=12255232;if(bh.rE())D=bh.d$()?43520:16755200;W.e.setAttribute("style","color:#ffffff; background-color:#"+E.$$(D))};
hn.prototype.jx=function(w){this.aqk();var L=this.sb.indexOf(w.currentTarget),n=this.Vy[L];if(w.type=="mouseover"&&!e.LY(this.Vy[this.a35].e))return;
if(e.LY(n.e))return;w.avv=!0;this.a35=L;for(var L=0;L<hn.data.length;L++)this.Vy[L].update(this.HI,this.XI);
var W=w.target.getBoundingClientRect(),D=new ed(b.E.L,!0);D.data={d:b.c.Uq,BT:n,x:W.left,y:W.top+W.height+2,akn:!0};
this.S(D)};hn.alB=function(w){var n=aK,W=n.CQ,D=n.WO,j=n.PJ,I=function(l){return{r:l!=null}},U=function(l){return{r:l!=null&&l.J!=null}},M={name:[0,5],items:[{name:[7,0],r:I,pn:[W,n.c]},{name:[7,1],pn:[W,n.Rn],r:U},{name:[7,2],pn:[D,W,n.Zb],r:U,nW:!0},{name:[7,8],r:I,$r:!0},{name:[7,13],$r:!0,r:function(l){return{r:l!=null&&l.g.length!=0&&!l.C[l.g[0]].rect.VY()}},nW:!0},{name:[7,11],$r:!0,r:function(l){return{r:l!=null&&l.g.length!=0&&!l.C[l.g[0]].rect.VY()}}},{name:[7,3],r:I,nW:!0,sub:[{name:[7,9],$r:!0,r:U},{name:[19,3,0],$r:!0,r:U},{name:[7,4],$r:!0,r:U},{name:[7,5],$r:!0,r:U},{name:[7,6],$r:!0,r:U,pn:"Shift+F6"}]},{name:"Grow",r:U},{name:"Similar",r:U,nW:!0},{name:[7,10],r:U,nW:!0},{name:[6,6,1],r:function(l){return{r:l!=null,hO:l!=null&&l._A()!=null}},pn:[n.Hk],nW:!0},{name:["VAR0 VAR1",[1,2],[17,2]],r:U}],Zf:[{Y:b.E.W1,W:y.eZ.Jj(!0)},{Y:b.E.W1,W:y.eZ.Jj()},{Y:b.E.W1,W:{hZ:"inverse"}},{Y:b.E.L,W:{d:b.c.P2,jW:"crange"}},{Y:b.E.L,W:{d:b.c.P2,jW:"magiccut"}},{Y:b.E.L,W:{d:b.c.P2,jW:"redge"}},{sub:[{Y:b.E.L,W:{d:b.c.P2,jW:"sel_border"}},{Y:b.E.L,W:{d:b.c.P2,jW:"sel_smoothness"}},{Y:b.E.L,W:{d:b.c.P2,jW:"sel_expand"}},{Y:b.E.L,W:{d:b.c.P2,jW:"sel_contract"}},{Y:b.E.L,W:{d:b.c.P2,jW:"sel_feather"}}]},{Y:b.E.W1,W:{hZ:"grow",E3:{classID:"null",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]}}}},{Y:b.E.W1,W:{hZ:"similar",E3:{classID:"null",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]}}}},{Y:b.E.L,W:{d:b.c.CV,G:y.Zt}},{Y:b.E.v,G:y.wA,W:{d:"qmask"}},{Y:b.E.W1,W:{hZ:"duplicate",E3:{classID:"null",null:{t:"obj ",v:[{t:"prop",v:{classID:"Chnl",keyID:"fsel"}}]}}}}]};
if(w){var m=M.items.length-1;M.items.splice(m-2,0,{name:[6,49],pn:[W,n.KZ],nW:!0});M.Zf.splice(m-2,0,{Y:b.E.W1,W:{hZ:"copyToLayer"}});
M.items.splice(m-1,0,{name:[10,16],pn:[j,W,n.US]});M.Zf.splice(m-1,0,{Y:b.E.L,W:{d:b.c.CV,G:y.Sv}})}return M};
hn.PN=function(w,n){if(w==null||w.g.length==0)return!1;var W=w.C[w.g[0]];return W.add.TySh!=null&&n.No==y.Lu};
hn.a3h=function(){var w=aK,n=w.CQ,W=w.WO,D=w.PJ,j=function(I){return{r:I!=null}};return[[{name:[5,0],pn:[n,w.Pn],r:function(I,U){return{r:I!=null&&(I.j5()||hn.PN(I,U))}}},{name:[5,1],pn:[n,w.Ak],r:j},{name:[5,2],pn:[n,w.tM],r:function(I,U){return{r:hn.PN()||e.aO()||U.qH!=null||U.oB!=null||U.avo!=null}}},{name:[2,2],r:function(I,U){return{r:I!=null&&(I.J!=null||hn.PN(I,U))}},pn:"Delete",nW:!0}],[{Y:b.E.L,W:{d:b.c.jm}},{Y:b.E.L,W:{d:b.c.UA}},{Y:b.E.L,W:{d:b.c.s_}},{Y:b.E.W1,W:{hZ:"delete"}}]]};
hn.data=function(){var w=aK,n=w.CQ,W=w.WO,D=w.PJ,j=function($){return{r:$!=null&&$.g.length!=0}},I=function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.SoLd!=null}},U=function($){return{r:$!=null}},M=function($){return{r:$!=null&&$.d2(!1)}},m=[],l=[],A="none maxx avrg medn minn rang stdv summ vari".split(" "),g=[[22,5,0],[24,17,2],[24,3,0],[24,7,3],[24,17,3],[12,12],"Standard Deviation","Summation","Variance"];
for(var L=0;L<A.length;L++){m.push({name:g[L],r:function($,C){if($==null||$.g.length!=1)return{r:!1};
var f=$.C[$.g[0]].add.SoLd;if(f==null)return{r:!1};return{r:!0,hO:f.Impr.v.classID==this.aa8}}.bind({aa8:A[L]})});
l.push({Y:b.E.v,G:y.Yu,W:{d:h.vZ,qY:A[L]}})}var k=hn.a3h(!0);return[{name:[0,0],items:[{name:[5,3],pn:[D,n,w.r1],title:[11,7],$r:!0},{name:[1,0],pn:[n,w.ke],$r:!0},{name:[1,11],$r:!0,r:U},{name:["VAR0 VAR1",[1,0],[0,14]],nW:!0,sub:[{name:"Storage",$r:!0,pn:[D,n,w.ke]},{name:[1,5],$r:!0},{name:[11,0],$r:!0},{name:["PSD VAR0",[25,0]],$r:!0}]},{name:[1,18],nW:!0,r:U,sub:[{name:"PNG",pn:"Imgur.com",r:function($,C){return{r:$!=null&&C.A4}}},{name:"JPG",pn:"Imgur.com",r:function($,C){return{r:$!=null&&C.A4}}},{name:"PSD",pn:"Photopea.com",r:function($,C){return{r:$!=null&&C.A4&&!$.wW}}}]},{name:"Save ...",pn:[n,w.qd],r:function($,C){var f=fV.get([1,2]),z=!0;
if($){if($.gN)f+=" ("+fV.get([6,7,1])+")";if($.Kh)f+=" (Google Drive)";if($.Il)f+=" ("+Storage.list[$.Il[0]][0]+")";
z="psd jpg png gif webp svg bmp".split(" ").indexOf($.Mc)!=-1}return{r:$!=null&&($.Il!=null||$.YX!=null&&z||$.gN!=null||$.BX!=null&&$.BX.nN!=null||$.Kh!=null||C.n4.save!=null),fP:f}}},{name:[1,3],r:function($,C){return{r:$!=null&&C.A4}}},{name:["VAR0 VAR1",[1,2],[0,14]],r:U,sub:[{name:"PSD to Storage",r:function($,C){return{r:$!=null&&C.A4}}},{name:["VAR0 PSD/PSB",[1,2]],$r:!0,r:function($,C){return{r:$!=null&&C.A4}}}]},{name:[1,8],r:U,sub:function(){var $=jj.pg(0),C=[];
for(var L=0;L<$.length;L++)C.push({name:$[L],pn:"."+$[L].toLowerCase()});C.push({name:[0,14],sub:function(){var $=jj.pg(1),C=[];
for(var L=0;L<$.length;L++)C.push({name:$[L],pn:"."+$[L].toLowerCase()});return C}()});return C}()},{name:[1,4],$r:!0,r:U,nW:!0},{name:[1,9],$r:!0,r:U},{name:"Export Color Lookup",$r:!0,r:U,nW:!0},{name:[1,14],$r:!0,r:U,nW:!0},{name:[1,17],sub:[{name:"PDF Presentation",$r:!0},{name:"Convert Formats",$r:!0}]},{name:[1,10]}],Zf:[{Y:b.E.L,W:{d:b.c.P2,jW:"newproject"}},{Y:b.E.L,W:{d:b.c.J0}},{Y:b.E.L,W:{d:b.c.J0,awp:!0}},{sub:[{Y:b.E.L,W:{d:b.c.P2,jW:"storwindow",IZ:0}},{Y:b.E.L,W:{d:b.c.P2,jW:"open_from_url"}},{Y:b.E.L,W:{d:b.c.P2,jW:"camera"}},{Y:b.E.L,W:{d:b.c.P2,jW:"res0"}}]},{sub:[{Y:b.E.L,W:{d:b.c.J6,$x:"png"}},{Y:b.E.L,W:{d:b.c.J6,$x:"jpg"}},{Y:b.E.L,W:{d:b.c.J6,$x:"psd"}}]},{Y:b.E.L,W:{d:b.c.LI}},{Y:b.E.L,W:{d:b.c.N0}},{sub:[{Y:b.E.L,W:{d:b.c.P2,jW:"storwindow",IZ:1}},{Y:b.E.L,W:{d:b.c.P2,jW:"savepsb"}}]},{sub:function(){var $=jj.pg(0),C=[];
for(var L=0;L<$.length;L++)C.push({Y:b.E.L,W:{d:b.c.P2,jW:"saveforweb",$x:L}});C.push({sub:function(){var f=jj.pg(0).length,$=jj.pg(1),C=[];
for(var L=0;L<$.length;L++)C.push({Y:b.E.L,W:{d:b.c.P2,jW:"saveforweb",$x:f+L}});return C}()});return C}()},{Y:b.E.L,W:{d:b.c.P2,jW:"saveforweb",$x:4,a7G:!0}},{Y:b.E.L,W:{d:b.c.P2,jW:"eassets"}},{Y:b.E.L,W:{d:b.c.P2,jW:"exlut"}},{Y:b.E.L,W:{d:b.c.P2,jW:"finfo"}},{sub:[{Y:b.E.L,W:{d:b.c.P2,jW:"pdfpres"}},{Y:b.E.L,W:{d:b.c.P2,jW:"cformat"}}]},{Y:b.E.L,W:{d:b.c.P2,jW:"script"}}]},{name:[0,1],items:[{name:[2,8],r:U},{name:[2,0],r:U,pn:[W,n,w.xD]},{name:[2,1],r:U,pn:[n,w.xD],nW:!0},{name:[2,11],pn:[W,n,w.aM],nW:!0,$r:!0,r:function($,C){return{r:jk.a0W($)&&C.No!=y.Sv}}},k[0][0],k[0][1],{name:[5,7],pn:[W,n,w.Ak],r:function($){return{r:$!=null&&$.j5()}}},k[0][2],k[0][3],{name:[2,3],r:U,$r:!0,pn:[W,w.Qn]},{name:[14,9],r:U,$r:!0,nW:!0},{name:[10,48],r:M},{name:[10,46],r:function($){return{r:y.Qi.aaS($)}}},{name:[10,16],r:U,pn:[D,n,w.US]},{name:[2,4],r:U,sub:js.ad_()},{name:[2,10,1],r:U},{name:[2,10,0],r:U,nW:!0},{name:[12,87],r:U,sub:[{name:[12,62],r:U},{name:[9,3],r:U},{name:[10,31],r:function($){return{r:$!=null&&$.OV()[1].length!=0}}}]},{name:[1,15],$r:!0},{name:[12,79],$r:!0,pn:[n,w.M$]},{name:[1,13],$r:!0}],Zf:[{Y:b.E.v,G:y.eb,W:{d:"h_undoredo"}},{Y:b.E.v,G:y.eb,W:{d:"h_stepfwd"}},{Y:b.E.v,G:y.eb,W:{d:"h_stepbck"}},{Y:b.E.L,W:{d:b.c.P2,jW:"afw_fade"}},k[1][0],k[1][1],{Y:b.E.L,W:{d:b.c.UA,O0:!0}},k[1][2],k[1][3],{Y:b.E.L,W:{d:b.c.P2,jW:"fill"}},{Y:b.E.L,W:{d:b.c.P2,jW:"stroke"}},{Y:b.E.L,W:{d:b.c.CV,G:y.uW}},{Y:b.E.v,G:y.sT,W:{d:"start",su:"rigidTransform"}},{Y:b.E.L,W:{d:b.c.CV,G:y.Sv}},{sub:js.aeS()},{Y:b.E.W1,W:{hZ:"align",E3:{classID:"null",null:{t:"obj ",v:[{t:"Enmr",v:{classID:"Lyr",typeID:"Ordn",enum:"Trgt"}}]},Usng:{t:"enum",v:{ADSt:"ADSContent"}},alignToCanvas:{t:"bool",v:!1},Aply:{t:"enum",v:{projection:"Auto"}},vignette:{t:"bool",v:!1},radialDistort:{t:"bool",v:!1}}}},{Y:b.E.v,G:y.Yu,W:{d:h.jh}},{sub:[{Y:b.E.L,W:{d:b.c.lb,AH:0}},{Y:b.E.L,W:{d:b.c.lb,AH:1}},{Y:b.E.L,W:{d:b.c.lb,AH:2}}]},{Y:b.E.L,W:{d:b.c.P2,jW:"pmanager"}},{Y:b.E.L,W:{d:b.c.P2,jW:"preferences"}},{Y:b.E.L,W:{d:b.c.P2,jW:"locstor"}}]},{name:[0,2],items:[{name:[12,36],r:U,nW:!0,sub:[{name:"RGB",r:function($){if($==null)return{r:!1};
return{hO:$.add.fcmy==null,r:!0}}},{name:"CMYK",r:function($){if($==null)return{r:!1};return{hO:$.add.fcmy!=null,r:!0}},nW:!0},{name:"Raster",r:function($){if($==null)return{r:!1};
return{hO:$.add.fvec==null,r:!0}}},{name:"Vector (Beta)",r:function($){if($==null)return{r:!1};return{hO:$.add.fvec!=null,r:!0}}}]},{name:[3],r:U,nW:!0,sub:function(){var $=[];
for(var C in eH.names){$.push({name:eH.names[C],$r:gu[C]!=null,pn:eH.keys[C],nW:eH.aoW.indexOf(C)!=-1});
if(C=="selc"){$.push({name:["VAR0/VAR1",[19,6,0],[19,6,2]],$r:!0,nW:!0});$.push({name:[19,7,0],pn:[n,W,w.Eg],r:M});
$.push({name:[4,18],$r:!0,r:M})}}return $}()},{name:[4,16,0],r:M},{name:[4,16,1],r:M},{name:[4,16,2],r:M,nW:!0},{name:[11,11,1],r:M},{name:[11,11,0],r:M,nW:!0},{name:[11,3],r:U,$r:!0,pn:[D,n,w.Ak]},{name:[11,10],r:U,$r:!0,pn:[D,n,w.Zb]},{name:[2,4],r:U,sub:[{name:["VAR0 90\xB0 \u21BB",[2,5]]},{name:["VAR0 90\xB0 \u21BA",[2,5]]},{name:["VAR0 180\xB0",[2,5]]},{name:[[2,6],[22,4,2]]},{name:[[2,6],[22,4,3]]}]},{name:[11,12,1],r:function($){return{r:$!=null&&$.J!=null}}},{name:[11,12,0],r:U,pn:[n,w.k2],$r:!0},{name:[11,12,2],r:U,nW:!0},{name:[2,12],r:M,$r:!0,nW:!0},{name:[2,14],r:U,$r:!0}],Zf:[{sub:[{Y:b.E.v,G:y.Rv,W:{d:"fcmy",Z:0}},{Y:b.E.v,G:y.Rv,W:{d:"fcmy",Z:1}},{Y:b.E.v,G:y.Rv,W:{d:"fvec",Z:0}},{Y:b.E.v,G:y.Rv,W:{d:"fvec",Z:1}}]},{sub:function(){var $=[];
for(var C in eH.names){$.push({Y:b.E.v,G:y.DW,W:{d:"start",u4:C}});if(C=="selc"){$.push({Y:b.E.v,G:y.sT,W:{d:"start",su:"adaptCorrect"}});
$.push({Y:b.E.W1,W:{hZ:"desaturate"}});$.push({Y:b.E.v,G:y.DW,W:{d:"start",u4:"matc"}})}}return $}()},{Y:b.E.W1,W:{hZ:"levels",E3:{classID:"Lvls",Auto:{t:"bool",v:!0}}}},{Y:b.E.W1,W:{hZ:"levels",E3:{classID:"Lvls",AuCo:{t:"bool",v:!0}}}},{Y:b.E.W1,W:{hZ:"levels",E3:{classID:"Lvls",autoBlackWhite:{t:"bool",v:!0},autoNeutrals:{t:"bool",v:!0}}}},{Y:b.E.L,W:{d:b.c.P2,jW:"rcolors"}},{Y:b.E.L,W:{d:b.c.P2,jW:"vbitmap"}},{Y:b.E.L,W:{d:b.c.P2,jW:"csize"}},{Y:b.E.L,W:{d:b.c.P2,jW:"isize"}},{sub:[{Y:b.E.W1,W:y.wR.CO(!0,90)},{Y:b.E.W1,W:y.wR.CO(!0,-90)},{Y:b.E.W1,W:y.wR.CO(!0,-180)},{Y:b.E.W1,W:y.wR.CO(!1,"Hrzn")},{Y:b.E.W1,W:y.wR.CO(!1,"Vrtc")}]},{Y:b.E.W1,W:{hZ:"crop",E3:{__name:"Crop",classID:"Crop"}}},{Y:b.E.L,W:{d:b.c.P2,jW:"trim"}},{Y:b.E.W1,W:{hZ:"revealAll",E3:{classID:"RvlA"}}},{Y:b.E.v,G:y.DW,W:{d:"start",u4:"aply"}},{Y:b.E.L,W:{d:b.c.P2,jW:"varsdats"}}]},{name:[0,3],items:[{name:[5,3],r:U,sub:[{name:[0,3],pn:[W,n,w.r1]},{name:[0,4]},{name:[1,16,0],$r:!0},{name:[1,16,3],$r:!0,nW:!0},{name:[6,49,0],pn:[n,w.KZ]},{name:[6,49,1],pn:[W,n,w.KZ],r:function($){return{r:$!=null&&$.J!=null&&$.d2(!1)}}}]},{name:[6,0],r:j,pn:[n,w.KZ]},{name:[11,4],r:j},{name:[5,4],r:j,nW:!0},{name:[11,6],r:j,nW:!0,sub:db.pq(!0)},{name:[6,48,1],r:U,sub:[{name:[6,48,0,0]},{name:[6,48,0,1]},{name:[6,48,0,2]}]},{name:[6,1],r:U,nW:!0,sub:db.adM()},{name:[6,2],r:U,sub:[{name:[6,4],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()==null}}},{name:[6,5,0],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()==null}}},{name:[6,5,1],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()==null&&$.J!=null}}},{name:[6,5,2],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()==null&&$.J!=null}}},{name:[6,5,3],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()==null}},nW:!0},{name:[5,4],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()!=null}}},{name:[5,8],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()!=null&&$.d2(!1,!0)}}},{name:["VAR0/VAR1",[5,5],[5,6]],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]]._N()!=null}}}]},{name:[6,3],r:U,sub:[{name:[6,4],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.vmsk==null}}},{name:[6,5,0],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.vmsk==null}}},{name:[12,76,7],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.vmsk==null}},nW:!0},{name:[5,4],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.vmsk!=null}}},{name:["VAR0/VAR1",[5,5],[5,6]],r:function($){return{r:$!=null&&$.g.length!=0&&$.C[$.g[0]].add.vmsk!=null}}}]},c6.a3y(!0),{name:[6,7,1],r:U,nW:!0,sub:[{name:[6,7,0],nW:!0},{name:"Open (Edit Contents)",r:I,$r:!0},{name:"Replace Contents",r:I,$r:!0},{name:"Export Contents",r:I,$r:!0,nW:!0},{name:[6,36,4],r:I,sub:m},{name:"Turn into JPG",r:I}]},{name:[6,8],r:c6.a2i},{name:[6,34],nW:!0,r:function($){if($==null||$.g.length==0)return{r:!1};
var C=$.C[$.g[0]];return{r:C.add.lmfx!=null&&!C.ue()}}},{name:[6,9],r:U,nW:!0,pn:[n,w.rP]},{name:[6,55],r:U,nW:!0,sub:[{name:[6,56,0],pn:[W,n,w.vs]},{name:[6,56,1],pn:[n,w.vs]},{name:[6,56,2],pn:[n,w.yq]},{name:[6,56,3],pn:[W,n,w.yq]}]},{name:[6,58],r:U,nW:!0,sub:[{name:["Make Frames"]},{name:["Unmake Frames"]},{name:[18,5]}]},{name:[6,12,0],pn:[n,w.E],r:function($){var C=$==null?0:$.g.length;
return{r:C!=0&&(C!=1||$.g[0]!=0),fP:fV.get(C>1||C==1&&$.C[$.g[0]].ue()?[6,12,0]:[6,10])}}},{name:[6,12,1],r:U},{name:[2,13],r:U}],Zf:[{sub:[{Y:b.E.v,G:y.Yu,W:{d:h.tp}},{Y:b.E.v,G:y.Yu,W:{d:h.Si}},{Y:b.E.L,W:{d:b.c.P2,jW:"newartb",IZ:0}},{Y:b.E.L,W:{d:b.c.P2,jW:"newartb",IZ:1}},{Y:b.E.W1,W:{hZ:"copyToLayer"}},{Y:b.E.W1,W:{hZ:"cutToLayer"}}]},{Y:b.E.v,G:y.Yu,W:{d:h.R6}},{Y:b.E.L,W:{d:b.c.P2,jW:"duplinto"}},{Y:b.E.v,G:y.Yu,W:{d:h.du}},{sub:db.Km(!0)},{sub:[{Y:b.E.v,G:y.K7,W:{d:"newfill",Y3:0}},{Y:b.E.W1,W:y.IG.YE(1)},{Y:b.E.W1,W:y.IG.YE(2)}]},{sub:db.XG()},{sub:[{Y:b.E.v,G:y.Yu,W:{d:h.uV,IZ:"RvlA"}},{Y:b.E.v,G:y.Yu,W:{d:h.uV,IZ:"HdAl"}},{Y:b.E.v,G:y.Yu,W:{d:h.uV,IZ:"RvlS"}},{Y:b.E.v,G:y.Yu,W:{d:h.uV,IZ:"HdSl"}},{Y:b.E.v,G:y.Yu,W:{d:h.uV,IZ:"Trns"}},{Y:b.E.v,G:y.Yu,W:{d:h.kR}},{Y:b.E.v,G:y.Yu,W:{d:h.Q_}},{Y:b.E.v,G:y.Yu,W:{d:h.Gw}}]},{sub:[{Y:b.E.v,G:y.Yu,W:{d:h.PE,a0P:!1}},{Y:b.E.v,G:y.Yu,W:{d:h.PE,a0P:!0}},{Y:b.E.v,G:y.Yu,W:{d:h.PE,a2J:!0}},{Y:b.E.v,G:y.Yu,W:{d:h.qc}},{Y:b.E.v,G:y.Yu,W:{d:h.Uo}}]},{Y:b.E.v,G:y.Yu,W:{d:h.Yt}},{sub:[{Y:b.E.W1,W:{hZ:"newPlacedLayer"}},{Y:b.E.W1,W:{hZ:"placedLayerEditContents",E3:{classID:"placedLayerEditContents"}}},{Y:b.E.W1,W:{hZ:"placedLayerReplaceContents",E3:{classID:"placedLayerReplaceContents"}}},{Y:b.E.W1,W:{hZ:"placedLayerExportContents",E3:{classID:"placedLayerExportContents"}}},{sub:l},{Y:b.E.v,G:y.Yu,W:{d:h.aqY}}]},{Y:b.E.W1,W:{hZ:"rasterizeLayer",E3:{classID:"rasterizeLayer",null:cq.Pz("Lyr",!0)}}},{Y:b.E.v,G:y.Yu,W:{d:h.fi}},{Y:b.E.v,G:y.Yu,W:{d:h.Vp}},{sub:[{Y:b.E.v,G:y.Yu,W:{d:h.iv,vK:0}},{Y:b.E.v,G:y.Yu,W:{d:h.iv,vK:1}},{Y:b.E.v,G:y.Yu,W:{d:h.iv,vK:2}},{Y:b.E.v,G:y.Yu,W:{d:h.iv,vK:3}}]},{sub:[{Y:b.E.v,G:y.Yu,W:{d:h.rC,vK:"makeframes"}},{Y:b.E.v,G:y.Yu,W:{d:h.rC,vK:"unmakeframes"}},{Y:b.E.v,G:y.Yu,W:{d:h.rC,vK:"merge"}}]},{Y:b.E.W1,W:{hZ:"mergeLayersNew",E3:{__name:"Merge Layers",classID:"Mrg2"}}},{Y:b.E.W1,W:{hZ:"flattenImage"}},{Y:b.E.v,G:y.sT,W:{d:"start",su:"defr"}}]},hn.alB(!1),function(){var $={name:[0,6],items:[{name:[24,18,4],pn:[D,n,w.aM],r:U,nW:!0}],Zf:[{Y:b.E.v,G:y.sT,W:{d:"applylast"}}]};
for(var L=0;L<cx.ie.length;L++){var C=cx.ie[L];if(C.S8!=null){$.items.push({name:cx.names[C.S8],$r:!0,nW:C.nW,r:U});
$.Zf.push({Y:b.E.v,G:y.sT,W:{d:"start",su:C.S8}});continue}var f={name:C.A7,sub:[],r:U};$.items.push(f);
var z={sub:[]};$.Zf.push(z);for(var s=0;s<C.sj.length;s++){var O={name:cx.names[C.sj[s]],$r:cx._1(C.sj[s])!=null};
f.sub.push(O);var a={Y:b.E.v,G:y.sT,W:{d:"start",su:C.sj[s]}};z.sub.push(a)}}return $}(),{name:[0,7],items:[{name:[8,0],r:U,pn:[n,w.fQ]},{name:[8,1],r:U,pn:[n,w.Ne]},{name:[20,3],r:U,pn:[n,w.zf]},{name:[20,2],r:U,pn:[n,w.ed]},{name:[8,14],r:function($,C){return{r:$!=null,hO:$!=null&&$.v_}},nW:!0},{name:[12,36],nW:!0,sub:[{name:"Fullscreen",r:function($,C){return{hO:document.fullscreenElement!=null}},nW:!0},{name:"Standard",r:function($,C){return{hO:C.jq==0}}},{name:"Menu Bar and Canvas",r:function($,C){return{hO:C.jq==1}}}]},{name:[8,13],pn:[n,w.Ga],r:function($,C){return{hO:C.Ar}}},{name:[8,12],nW:!0,sub:[{name:[17,2],r:function($,C){return{r:C.Ar,hO:C.M3.zc}}},{name:[8,9],r:function($,C){return{r:C.Ar,hO:C.M3.Oi}}},{name:[8,2],r:function($,C){return{r:C.Ar,hO:C.M3.jg}},pn:[n,w.iI]},{name:[8,4],r:function($,C){return{r:C.Ar,hO:C.M3.Vk}},pn:[n,w.m5]},{name:[8,8],r:function($,C){return{r:C.Ar,hO:C.M3.E4}}},{name:[8,11,0],r:function($,C){return{r:C.Ar,hO:C.M3.ej}}}]},{name:[8,3],r:function($,C){return{hO:C.fM}},pn:[n,w.ip],nW:!0},{name:[8,5],r:function($,C){return{hO:C.CF}}},{name:[8,6],nW:!0,sub:[{name:[8,2],r:function($,C){return{hO:C.PW[0]}}},{name:[8,4],r:function($,C){return{hO:C.PW[1]}}},{name:[9,1],r:function($,C){return{hO:C.PW[2]}}},{name:[8,11,0],r:function($,C){return{hO:C.PW[3]}}},{name:[8,7,0],r:function($,C){return{hO:C.PW[4]}}}]},{name:[11,15,2],r:function($,C){return{r:$!=null,hO:$!=null&&$.PK}}},{name:[11,15,0],r:U},{name:[11,14],r:U,$r:!0},{name:[11,15,1],r:function($,C){return{r:$!=null&&$.g.length!=0}},nW:!0},{name:[8,11,2],r:function($,C){return{r:$!=null&&$.ej.length!=0}}}],Zf:[{Y:b.E.v,G:y.Nt,W:{d:"zoom",pZ:!0}},{Y:b.E.v,G:y.Nt,W:{d:"zoom",pZ:!1}},{Y:b.E.v,G:y.Nt,W:{d:"adapt",Z:"fitscr"}},{Y:b.E.v,G:y.Nt,W:{d:"adapt",Z:"pixel"}},{Y:b.E.v,G:y.Rv,W:{d:"pview"}},{sub:[{Y:b.E.L,W:{d:b.c.sa,dJ:!0}},{Y:b.E.L,W:{d:b.c.sa,Z:0}},{Y:b.E.L,W:{d:b.c.sa,Z:1}},{Y:b.E.L,W:{d:b.c.sa,Z:2}}]},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Xh}},{sub:[{Y:b.E.L,W:{d:b.c.oj,AH:bk.TK}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.aK}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.pa}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.ZX}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Qu}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.WA}}]},{Y:b.E.L,W:{d:b.c.oj,AH:bk.SU}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.agg}},{sub:[{Y:b.E.L,W:{d:b.c.oj,AH:bk.Uj,hM:0}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Uj,hM:1}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Uj,hM:2}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Uj,hM:3}},{Y:b.E.L,W:{d:b.c.oj,AH:bk.Uj,hM:4}}]},{Y:b.E.v,G:y.Rv,W:{d:"lockguides"}},{Y:b.E.v,G:y.Rv,W:{d:"gids",Qh:[[],[]]}},{Y:b.E.L,W:{d:b.c.P2,jW:"addguides"}},{Y:b.E.v,G:y.Rv,W:{d:"gidsFromLayer"}},{Y:b.E.v,G:y.Od,W:{d:"deleteAll"}}]},function(){var $={name:[0,8],items:[{name:[0,14],nW:!0,sub:[]},{name:"Plugins",nW:!0}],Zf:[{sub:[]},{Y:b.E.L,W:{d:b.c.P2,jW:"res1"}}]};
for(var L=0;L<gz.b8.length;L++){var C=gz.b8[L],f=function(){var z=C.BT.JY;return function(s,O){return{hO:O.Vy.indexOf(parseInt(z))!=-1}}}();
(C.Cc?$.items[0].sub:$.items).push({name:C.BT.name,r:f});(C.Cc?$.Zf[0].sub:$.Zf).push({Y:b.E.L,W:{d:b.c._y,jW:C.BT.JY}})}return $}(),function(){var $={name:[0,14],items:[],Zf:[]},C={name:[0,9],sub:[]};
$.items.push(C);var f={sub:[]};$.Zf.push(f);var z=fV.at6();for(var L=0;L<z.length;L++){var s=z[L],O=s.code,a=fV.atY(O);
C.sub.push({name:s.name,pn:O,r:function(X,P){return{hO:this.pn==fV.fG()}}});f.sub.push({Y:b.E.L,W:{d:b.c.oj,AH:bk.Z0,lang:a}})}C.sub.push({name:[0,12]});
f.sub.push({Y:b.E.L,W:{d:b.c.aT,link:"https://www.photopea.com/translate/"}});var C={name:[0,15],sub:[]};
$.items.push(C);var f={sub:[]};$.Zf.push(f);for(var L=0;L<hp.fX.length;L++){C.sub.push({name:hp.fX[L].name,r:function(X,P){return{hO:this.name==hp.fX[P.SI].name}}});
f.sub.push({Y:b.E.L,W:{d:b.c.oj,AH:bk.ix,SI:L}})}$.items.push({name:[0,17,6],r:function(X,P){return{r:P.QA!=null}}});
$.Zf.push({Y:b.E.L,W:{d:b.c.ahn}});$.items.push({name:[11,13]});$.Zf.push({Y:b.E.L,W:{d:b.c.P2,jW:"shortcuts"}});
$.items.push({name:[0,16],r:function(X){return{hO:je.YG,r:je.RA}},nW:!0});$.Zf.push({Y:b.E.L,W:{d:b.c.aqc}});
$.items.push({name:"",r:function(X,P){return P.aE?{fP:"About Photopea",r:!0}:{fP:"",r:!1}}});$.Zf.push({Y:b.E.L,W:{d:b.c.P2,jW:"aboutpp"}});
return $}()]}();function g2(){eg.call(this);this.e=e.t("div","");this.s1=0;this.w_=0;this.ww=null;this.us=e.t("div","");
this.us.setAttribute("style","width:200em; height:100em; position:absolute;");this.fa=[];this.lM=[];
this.zp={}}g2.prototype=new eg;g2.prototype.Wg=function(w){var n=Date.now(),W=[];if(w=="-")W=[new jU,new fk,new fe("pdfpres"),new fe("cformat"),new ao,new iH,new fp,new ax,new bB,new dn,new hR,new fo,new hi,new ey,new cQ,new cV,new eW,new db,new dH,new gI,new gh,new cH,new iS,new g0,new cR,new hT,new g3,new j4,new hI(!1),new hI(!0),new gT(0),new gT(1),new hx,new bd,new kx,new eC,new ft,new d_,new co(0),new co(1),new co(2),new co(3),new co(4),new co(5),new co(6),new co(7),new co(8),new cX,new jI,new e4,new fJ,new aN,new bM,new h8,new cF("border",[7,9],"px"),new cF("smoothness",[19,3,0],"px"),new cF("expand",[7,4],"px"),new cF("contract",[7,5],"px"),new cF("feather",[7,6],"px"),new gZ(0,"namewindow",[12,48]),new gZ(2,"billto","Bill To"),new gZ(1,"cornerradius",[12,94,0],"px",!0,!0),new gZ(1,"scaleeffects",[6,30,1],"%",!0),new gZ(1,"doczoom","Zoom","%",!0),new gZ(1,"setFPS","Set FPS","fps",!1)];
else W=[new jk(w.slice(4))];this.aux(W);this.zp[w]=!0};g2.prototype.aux=function(w){var n=this.ww;for(var L=0;
L<w.length;L++){var W=w[L];W.parent=this;this.lM.push(W);this.Lr(W);W.f();if(n)W.GZ(n,bk.bI);W.h(b.E.gh,this.bf,this);
e.Qa(W)}};g2.prototype.zl=function(w,n){this.s1=w;this.w_=n;for(var L=0;L<this.lM.length;L++)this.Lr(this.lM[L])};
g2.prototype.f=function(){for(var L=0;L<this.lM.length;L++)this.lM[L].f()};g2.prototype.DJ=function(){return this.fa.length==0?null:this.fa[this.fa.length-1]};
g2.prototype.wb=function(){for(var L=0;L<this.fa.length;L++)if(this.fa[L].wb())return!0;return!1};g2.prototype.azW=function(w,n,W,D,j){var I=w.startsWith("afw_"),U=null;
if(!I&&!this.zp["-"])this.Wg("-");if(I&&!this.zp[w])this.Wg(w);if(typeof w=="object"){U=w;if(!U.a6U(b.E.gh,this.bf))U.h(b.E.gh,this.bf,this);
U.parent=this}else for(var L=0;L<this.lM.length;L++)if(this.lM[L].id==w)U=this.lM[L];if(this.wb()&&U.wb()){alert("Finish the current action first");
return}if(!U.X7(n))return;if(this.fa.indexOf(U)!=-1){if(w=="colorpicker")U.mQ(n,W,D,j);return}var M=this.fa.length-1;
if(M>=0)e.W0(this.fa[M].e,"wdisabled");this.e.appendChild(U.e);this.fa.push(U);this.Lr(U);e.r3(U);U.mQ(n,W,D,j)};
g2.prototype.Lr=function(w){var n=this.s1,W=this.w_,D=w.aP(n,W),j;if(D!=null){j=D}else{D=new ec(0,0);
j=w.aAg();if(j==null){var I=this.fa.indexOf(w)+1;if(n<450||W<450)j=new ec(0,0);else j=new ec(I*150,I*150)}}w.e.style.left=j.x+"px";
w.e.style.top=this.e.offsetTop+j.y+"px";w.zl(this.s1-D.x*2,this.w_-D.y*2-34)};g2.prototype.GZ=function(w,n){this.ww=w;
for(var L=0;L<this.lM.length;L++)this.lM[L].GZ(w,n)};g2.prototype.bf=function(w){var n=this.fa.pop();
e.Qa(n,this.e);var W=this.fa.length-1;if(W>=0)e.IX(this.fa[W].e,"wdisabled");if(this.us.parentNode==this.e)this.e.removeChild(this.us)};
window.onload=function(){document.body.appendChild(new hB().e)}}())