thrownewError("Unsupported ELFs");case"PtgSxName":thrownewError("Unrecognized Formula Token: "+String(w));default:thrownewError("Unrecognized Formula Token: "+String(w));}varP=["PtgAttrSpace","PtgAttrSpaceSemi","PtgAttrGoto"];if(n.biff!=3)if(p>=0&&P.indexOf(e[0][b][0])==-1){w=e[0][p];varL=true;switch(w[1][0]){case4:L=false;case0:m=Er(" ",w[1][1]);break;case5:L=false;case1:m=Er("\r",w[1][1]);break;default:m="";if(n.WTF)thrownewError("Unexpected PtgAttrSpaceType "+w[1][0]);}f.push((L?m:"")+f.pop()+(L?"":m));p=-1}}if(f.length>1&&n.WTF)thrownewError("bad formula stack");returnf[0]}functionud(e,r,t){vara=e.l+r,n=t.biff==2?1:2;vari,s=e._R(n);if(s==65535)return[[],ma(e,r-2)];varf=nd(e,s,t);if(r!==s+n)i=ad(e,r-s-n,f,t);e.l=a;return[f,i]}functionhd(e,r,t){vara=e.l+r,n=t.biff==2?1:2;vari,s=e._R(n);if(s==65535)return[[],ma(e,r-2)];varf=nd(e,s,t);if(r!==s+n)i=ad(e,r-s-n,f,t);e.l=a;return[f,i]}functiondd(e,r,t,a){varn=e.l+r;vari=nd(e,a,t);vars;if(n!==e.l)s=ad(e,n-e.l,i,t);return[i,s]}functionvd(e,r,t){vara=e.l+r;varn,i=e._R(2);vars=nd(e,i,t);if(i==65535)return[[],ma(e,r-2)];if(r!==i+2)n=ad(e,a-i-2,s,t);return[s,n]}functionpd(e){varr;if(na(e,e.l+6)!==65535)return[gn(e),"n"];switch(e[e.l]){case0:e.l+=8;return["String","s"];case1:r=e[e.l+2]===1;e.l+=8;return[r,"b"];case2:r=e[e.l+2];e.l+=8;return[r,"e"];case3:e.l+=8;return["","s"];}return[]}functionmd(e){if(e==null){varr=ba(8);r._W(1,3);r._W(1,0);r._W(2,0);r._W(2,0);r._W(2,65535);returnr}elseif(typeofe=="number")returnwn(e);returnwn(0)}functionbd(e,r,t){vara=e.l+r;varn=_s(e,6);if(t.biff==2)++e.l;vari=pd(e,8);vars=e._R(1);if(t.biff!=2){e._R(1);if(t.biff>=5){e._R(4)}}varf=hd(e,a-e.l,t);return{cell:n,val:i[0],formula:f,shared:s>>3&1,tt:i[1]}}functiongd(e,r,t,a,n){vari=As(r,t,n);vars=md(e.v);varf=ba(6);varo=1|32;f._W(2,o);f._W(4,0);varc=ba(e.bf.length);for(varl=0;l<e.bf.length;++l)c[l]=e.bf[l];varu=I([i,s,f,c]);returnu}functionwd(e,r,t){vara=e._R(4);varn=nd(e,a,t);vari=e._R(4);vars=i>0?ad(e,i,n,t):null;return[n,s]}varkd=wd;varTd=wd;varEd=wd;varyd=wd;varSd={0:"BEEP",1:"OPEN",2:"OPEN.LINKS",3:"CLOSE.ALL",4:"SAVE",5:"SAVE.AS",6:"FILE.DELETE",7:"PAGE.SETUP",8:"PRINT",9:"PRINTER.SETUP",10:"QUIT",11:"NEW.WINDOW",12:"ARRANGE.ALL",13:"WINDOW.SIZE",14:"WINDOW.MOVE",15:"FULL",16:"CLOSE",17:"RUN",22:"SET.PRINT.AREA",23:"SET.PRINT.TITLES",24:"SET.PAGE.BREAK",25:"REMOVE.PAGE.BREAK",26:"FONT",27:"DISPLAY",28:"PROTECT.DOCUMENT",29:"PRECISION",30:"A1.R1C1",31:"CALCULATE.NOW",32:"CALCULATION",34:"DATA.FIND",35:"EXTRACT",36:"DATA.DELETE",37:"SET.DATABASE",38:"SET.CRITERIA",39:"SORT",40:"DATA.SERIES",41:"TABLE",42:"FORMAT.NUMBER",43:"ALIGNMENT",44:"STYLE",45:"BORDER",46:"CELL.PROTECTION",47:"COLUMN.WIDTH",48:"UNDO",49:"CUT",50:"COPY",51:"PASTE",52:"CLEAR",53:"PASTE.SPECIAL",54:"EDIT.DELETE",55:"INSERT",56:"FILL.RIGHT",57:"FILL.DOWN",61:"DEFINE.NAME",62:"CREATE.NAMES",63:"FORMULA.GOTO",64:"FORMULA.FIND",65:"SELECT.LAST.CELL",66:"SHOW.ACTIVE.CELL",67:"GALLERY.AREA",68:"GALLERY.BAR",69:"GALLERY.COLUMN",70:"GALLERY.LINE",71:"GALLERY.PIE",72:"GALLERY.SCATTER",73:"COMBINATION",74:"PREFERRED",75:"ADD.OVERLAY",76:"GRIDLINES",77:"SET.PREFERRED",78:"AXES",79:"LEGEND",80:"ATTACH.TEXT",81:"ADD.ARROW",82:"SELECT.CHART",83:"SELECT.PLOT.AREA",84:"PATTERNS",85:"MAIN.CHART",86:"OVERLAY",87:"SCALE",88:"FORMAT.LEGEND",89:"FORMAT.TEXT",90:"EDIT.REPEAT",91:"PARSE",92:"JUSTIFY",93:"HIDE",94:"UNHIDE",95:"WORKSPACE",96:"FORMULA",97:"FORMULA.FILL",98:"FORMULA.ARRAY",99:"DATA.FIND.NEXT",100:"DATA.FIND.PREV",101:"FORMULA.FIND.NEXT",102:"FORMULA.FIND.PREV",103:"ACTIVATE",104:"ACTIVATE.NEXT",105:"ACTIVATE.PREV",106:"UNLOCKED.NEXT",107:"UNLOCKED.PREV",108:"COPY.PICTURE",109:"SELECT",110:"DELETE.NAME",111:"DELETE.FORMAT",112:"VLINE",113:"HLINE",114:"VPAGE",115:"HPAGE",116:"VSCROLL",117:"HSCROLL",118:"ALERT",119:"NEW",120:"CANCEL.COPY",121:"SHOW.CLIPBOARD",122:"MESSAGE",124:"PASTE.LINK",125:"APP.ACTIVATE",126:"DELETE.ARROW",127:"ROW.HEIGHT",128:"FORMAT.MOVE",129:"FORMAT.SIZE",130:"FORMULA.REPLACE",131:"SEND.KEYS",132:"SELECT.SPECIAL",133:"APPLY.NAMES",134:"REPLACE.FONT",
v=n[q[0].r][q[0].c]={t:"z"}}else{v=n[Pa(q[0])]={t:"z"}}s.e.r=Math.max(s.e.r,q[0].r);s.s.r=Math.min(s.s.r,q[0].r);s.e.c=Math.max(s.e.c,q[0].c);s.s.c=Math.min(s.s.c,q[0].c)}if(!v.c)v.c=[];p={a:q[1],t:he.TxO.t};v.c.push(p)}break;case2173:zl(y[q.ixfe],q.ext);break;case125:{if(!O.cellStyles)break;while(q.e>=q.s){D[q.e--]={width:q.w/256,level:q.level||0,hidden:!!(q.flags&1)};if(!L){L=true;Fc(q.w/256)}Dc(D[q.e+1])}}break;case520:{varde={};if(q.level!=null){P[q.r]=de;de.level=q.level}if(q.hidden){P[q.r]=de;de.hidden=true}if(q.hpt){P[q.r]=de;de.hpt=q.hpt;de.hpx=Uc(q.hpt)}}break;case38:;case39:;case40:;case41:if(!n["!margins"])Ld(n["!margins"]={});n["!margins"][{38:"left",39:"right",40:"top",41:"bottom"}[X]]=q;break;case161:if(!n["!margins"])Ld(n["!margins"]={});n["!margins"].header=q.header;n["!margins"].footer=q.footer;break;case574:if(q.RTL)_.Views[0].RTL=true;break;case146:S=q;break;case2198:I=q;break;case140:E=q;break;case442:{if(!l)_.WBProps.CodeName=q||"ThisWorkbook";elseA.CodeName=q||A.name}break;}}else{if(!K)console.error("Missing Info for XLS Record 0x"+X.toString(16));e.l+=$}}t.SheetNames=nr(i).sort(function(e,r){returnNumber(e)-Number(r)}).map(function(e){returni[e].name});if(!r.bookSheets)t.Sheets=a;if(!t.SheetNames.length&&u["!ref"]){t.SheetNames.push("Sheet1");if(t.Sheets)t.Sheets["Sheet1"]=u}elset.Preamble=u;if(t.Sheets)z.forEach(function(e,r){t.Sheets[t.SheetNames[r]]["!autofilter"]=e});t.Strings=c;t.SSF=Tr(Y);if(O.enc)t.Encryption=O.enc;if(I)t.Themes=I;t.Metadata={};if(E!==undefined)t.Metadata.Country=E;if(M.names.length>0)_.Names=M.names;t.Workbook=_;returnt}varnb={SI:"e0859ff2f94f6810ab9108002b27b3d9",DSI:"02d5cdd59c2e1b10939708002b2cf9ae",UDI:"05d5cdd59c2e1b10939708002b2cf9ae"};functionib(e,r,t){vara=Ze.find(e,"/!DocumentSummaryInformation");if(a&&a.size>0)try{varn=Ji(a,Wn,nb.DSI);for(variinn)r[i]=n[i]}catch(s){if(t.WTF)throws}varf=Ze.find(e,"/!SummaryInformation");if(f&&f.size>0)try{varo=Ji(f,Hn,nb.SI);for(varcino)if(r[c]==null)r[c]=o[c]}catch(s){if(t.WTF)throws}if(r.HeadingPairs&&r.TitlesOfParts){wi(r.HeadingPairs,r.TitlesOfParts,r,t);deleter.HeadingPairs;deleter.TitlesOfParts}}functionsb(e,r){vart=[],a=[],n=[];vari=0,s;varf=ir(Wn,"n");varo=ir(Hn,"n");if(e.Props){s=nr(e.Props);for(i=0;i<s.length;++i)(Object.prototype.hasOwnProperty.call(f,s[i])?t:Object.prototype.hasOwnProperty.call(o,s[i])?a:n).push([s[i],e.Props[s[i]]])}if(e.Custprops){s=nr(e.Custprops);for(i=0;i<s.length;++i)if(!Object.prototype.hasOwnProperty.call(e.Props||{},s[i]))(Object.prototype.hasOwnProperty.call(f,s[i])?t:Object.prototype.hasOwnProperty.call(o,s[i])?a:n).push([s[i],e.Custprops[s[i]]])}varc=[];for(i=0;i<n.length;++i){if($i.indexOf(n[i][0])>-1||gi.indexOf(n[i][0])>-1)continue;if(n[i][1]==null)continue;c.push(n[i])}if(a.length)Ze.utils.cfb_add(r,"/SummaryInformation",qi(a,nb.SI,o,Hn));if(t.length||c.length)Ze.utils.cfb_add(r,"/DocumentSummaryInformation",qi(t,nb.DSI,f,Wn,c.length?c:null,nb.UDI))}functionfb(e,r){if(!r)r={};Pg(r);c();if(r.codepage)s(r.codepage);vart,a;if(e.FullPaths){if(Ze.find(e,"/encryption"))thrownewError("File is password-protected");t=Ze.find(e,"!CompObj");a=Ze.find(e,"/Workbook")||Ze.find(e,"/Book")}else{switch(r.type){case"base64":e=A(T(e));break;case"binary":e=A(e);break;case"buffer":break;case"array":if(!Array.isArray(e))e=Array.prototype.slice.call(e);break;}pa(e,0);a={content:e}}varn;vari;if(t)Zm(t);if(r.bookProps&&!r.bookSheets)n={};else{varf=E?"buffer":"array";if(a&&a.content)n=ab(a.content,r);elseif((i=Ze.find(e,"PerfectOffice_MAIN"))&&i.content)n=Io.to_workbook(i.content,(r.type=f,r));elseif((i=Ze.find(e,"NativeContent_MAIN"))&&i.content)n=Io.to_workbook(i.content,(r.type=f,r));elseif((i=Ze.find(e,"MN0"))&&i.content)thrownewError("Unsupported Works 4 for Mac file");elsethrownewError("Cannot find Workbook stream");if(r.bookVBA&&e.FullPaths&&Ze.find(e,"/_VBA_PROJECT_CUR/VBA/dir"))n.vbaraw=Eu(e)}varo={};if(e.FullPaths)ib(e,o,r);n.Props=n.Custprops=o;if(r.bookFiles)n.cfb=e;returnn}functionob(e,r){vart=r||{};vara=Ze.utils.cfb_new({root:"R"});var
I=parseInt(g["number-columns-spanned"],10)||0;R={s:{r:y,c:S},e:{r:y+O-1,c:S+I-1}};C.push(R)}if(g["number-columns-repeated"])D=parseInt(g["number-columns-repeated"],10);switch(m.t){case"boolean":m.t="b";m.v=ct(g["boolean-value"]);break;case"float":m.t="n";m.v=parseFloat(g.value);break;case"percentage":m.t="n";m.v=parseFloat(g.value);break;case"currency":m.t="n";m.v=parseFloat(g.value);break;case"date":m.t="d";m.v=wr(g["date-value"]);if(!t.cellDates){m.t="n";m.v=lr(m.v)}m.z="m/d/yy";break;case"time":m.t="n";m.v=pr(g["time-value"])/86400;if(t.cellDates){m.t="d";m.v=vr(m.v)}m.z="HH:MM:SS";break;case"number":m.t="n";m.v=parseFloat(g["数据数值"]);break;default:if(m.t==="string"||m.t==="text"||!m.t){m.t="s";if(g["string-value"]!=null){w=Qr(g["string-value"]);E=[]}}elsethrownewError("Unsupported value type "+m.t);}}else{V=false;if(m.t==="s"){m.v=w||"";if(E.length)m.R=E;V=k==0}if(M.Target)m.l=M;if(B.length>0){m.c=B;B=[]}if(w&&t.cellText!==false)m.w=w;if(V){m.t="z";deletem.v}if(!V||t.sheetStubs){if(!(t.sheetRows&&t.sheetRows<=y)){for(var$=0;$<F;++$){D=parseInt(g["number-columns-repeated"]||"1",10);if(t.dense){if(!v[y+$])v[y+$]=[];v[y+$][S]=$==0?m:Tr(m);while(--D>0)v[y+$][S+D]=Tr(m)}else{v[Pa({r:y+$,c:S})]=m;while(--D>0)v[Pa({r:y+$,c:S+D})]=Tr(m)}if(_.e.c<=S)_.e.c=S}}}D=parseInt(g["number-columns-repeated"]||"1",10);S+=D-1;D=0;m={};w="";E=[]}M={};break;case"document":;case"document-content":;case"电子表格文档":;case"spreadsheet":;case"主体":;case"scripts":;case"styles":;case"font-face-decls":;case"master-styles":if(p[1]==="/"){if((i=n.pop())[0]!==p[3])throw"Bad state: "+i}elseif(p[0].charAt(p[0].length-2)!=="/")n.push([p[3],true]);break;case"annotation":if(p[1]==="/"){if((i=n.pop())[0]!==p[3])throw"Bad state: "+i;W.t=w;if(E.length)W.R=E;W.a=H;B.push(W)}elseif(p[0].charAt(p[0].length-2)!=="/"){n.push([p[3],false])}H="";z=0;w="";k=0;E=[];break;case"creator":if(p[1]==="/"){H=a.slice(z,p.index)}elsez=p.index+p[0].length;break;case"meta":;case"元数据":;case"settings":;case"config-item-set":;case"config-item-map-indexed":;case"config-item-map-entry":;case"config-item-map-named":;case"shapes":;case"frame":;case"text-box":;case"image":;case"data-pilot-tables":;case"list-style":;case"form":;case"dde-links":;case"event-listeners":;case"chart":if(p[1]==="/"){if((i=n.pop())[0]!==p[3])throw"Bad state: "+i}elseif(p[0].charAt(p[0].length-2)!=="/")n.push([p[3],false]);w="";k=0;E=[];break;case"scientific-number":break;case"currency-symbol":break;case"currency-style":break;case"number-style":;case"percentage-style":;case"date-style":;case"time-style":if(p[1]==="/"){x[f.name]=o;if((i=n.pop())[0]!==p[3])throw"Bad state: "+i}elseif(p[0].charAt(p[0].length-2)!=="/"){o="";f=Kr(p[0],false);n.push([p[3],true])}break;case"script":break;case"libraries":break;case"automatic-styles":break;case"default-style":;case"page-layout":break;case"style":break;case"map":break;case"font-face":break;case"paragraph-properties":break;case"table-properties":break;case"table-column-properties":break;case"table-row-properties":break;case"table-cell-properties":break;case"number":switch(n[n.length-1][0]){case"time-style":;case"date-style":s=Kr(p[0],false);o+=Vb[p[3]][s.style==="long"?1:0];break;}break;case"fraction":break;case"day":;case"month":;case"year":;case"era":;case"day-of-week":;case"week-of-year":;case"quarter":;case"hours":;case"minutes":;case"seconds":;case"am-pm":switch(n[n.length-1][0]){case"time-style":;case"date-style":s=Kr(p[0],false);o+=Vb[p[3]][s.style==="long"?1:0];break;}break;case"boolean-style":break;case"boolean":break;case"text-style":break;case"text":if(p[0].slice(-2)==="/>")break;elseif(p[1]==="/")switch(n[n.length-1][0]){case"number-style":;case"date-style":;case"time-style":o+=a.slice(c,p.index);break;}elsec=p.index+p[0].length;break;case"named-range":s=Kr(p[0],false);U=Rd(s["cell-range-address"]);varY={Name:s.name,Ref:U[0]+"!"+U[1]};if(G)Y.Sheet=d.length;L.Names.push(Y);break;case"text-content":break;case"text-properties":break;case"embedded-text":break;case"body":;case"电子表格":break;case"forms":break;case"table-co
returnr}thrownewError("Too many messages")}vard=Ze.find(l,o[1].location);varv=lg(dg(d.content));varp;for(varm=0;m<v.length;++m){varb=v[m];if(b.id==1)p=b}varg=kg(fg(p.messages[0].data)[1][0].data);d=Ze.find(l,o[g].location);v=lg(dg(d.content));for(m=0;m<v.length;++m){b=v[m];if(b.id==g)p=b}varw=fg(p.messages[0].data);{w[1]=[{type:2,data:Zb(e.SheetNames[0])}]}p.messages[0].data=og(w);d.content=vg(ug(v));d.size=d.content.length;g=kg(w[2][0].data);d=Ze.find(l,o[g].location);v=lg(dg(d.content));for(m=0;m<v.length;++m){b=v[m];if(b.id==g)p=b}g=kg(fg(p.messages[0].data)[2][0].data);d=Ze.find(l,o[g].location);v=lg(dg(d.content));for(m=0;m<v.length;++m){b=v[m];if(b.id==g)p=b}vark=fg(p.messages[0].data);{k[6][0].data=ig(n.e.r+1);k[7][0].data=ig(n.e.c+1);varT=kg(k[46][0].data);varE=Ze.find(l,o[T].location);vary=lg(dg(E.content));{for(varS=0;S<y.length;++S){if(y[S].id==T)break}if(y[S].id!=T)throw"Bad ColumnRowUIDMapArchive";var_=fg(y[S].messages[0].data);_[1]=[];_[2]=[],_[3]=[];for(varA=0;A<=n.e.c;++A){_[1].push({type:2,data:og([[],[{type:0,data:ig(A+420690)}],[{type:0,data:ig(A+420690)}]])});_[2].push({type:0,data:ig(A)});_[3].push({type:0,data:ig(A)})}_[4]=[];_[5]=[],_[6]=[];for(varx=0;x<=n.e.r;++x){_[4].push({type:2,data:og([[],[{type:0,data:ig(x+726270)}],[{type:0,data:ig(x+726270)}]])});_[5].push({type:0,data:ig(x)});_[6].push({type:0,data:ig(x)})}y[S].messages[0].data=og(_)}E.content=vg(ug(y));E.size=E.content.length;deletek[46];varC=fg(k[4][0].data);{C[7][0].data=ig(n.e.r+1);varR=fg(C[1][0].data);varO=kg(R[2][0].data);E=Ze.find(l,o[O].location);y=lg(dg(E.content));{if(y[0].id!=O)throw"Bad HeaderStorageBucket";varI=fg(y[0].messages[0].data);if((t=I==null?void0:I[2])==null?void0:t[0])for(x=0;x<s.length;++x){varN=fg(I[2][0].data);N[1][0].data=ig(x);N[4][0].data=ig(s[x].length);I[2][x]={type:I[2][0].type,data:og(N)}}y[0].messages[0].data=og(I)}E.content=vg(ug(y));E.size=E.content.length;varF=kg(C[2][0].data);E=Ze.find(l,o[F].location);y=lg(dg(E.content));{if(y[0].id!=F)throw"Bad HeaderStorageBucket";I=fg(y[0].messages[0].data);for(A=0;A<=n.e.c;++A){N=fg(I[2][0].data);N[1][0].data=ig(A);N[4][0].data=ig(n.e.r+1);I[2][A]={type:I[2][0].type,data:og(N)}}y[0].messages[0].data=og(I)}E.content=vg(ug(y));E.size=E.content.length;if(a["!merges"]){varD=h({type:6144,deps:[g],location:o[g].location});varP=[[],[]];a["!merges"].forEach(function(e){P[1].push({type:2,data:og([[],[{type:2,data:og([[],[{type:5,data:newUint8Array(newUint16Array([e.s.r,e.s.c]).buffer)}]])}],[{type:2,data:og([[],[{type:5,data:newUint8Array(newUint16Array([e.e.r-e.s.r+1,e.e.c-e.s.c+1]).buffer)}]])}]])})});C[13]=[{type:2,data:Tg(D)}];v.push({id:D,messages:[Ig(6144,og(P))]})}varL=kg(C[4][0].data);(function(){vare=Ze.find(l,o[L].location);varr=lg(dg(e.content));vart;for(vara=0;a<r.length;++a){varn=r[a];if(n.id==L)t=n}vari=fg(t.messages[0].data);{i[3]=[];f.forEach(function(e,r){i[3].push({type:2,data:og([[],[{type:0,data:ig(r)}],[{type:0,data:ig(1)}],[{type:2,data:Zb(e)}]])})})}t.messages[0].data=og(i);e.content=vg(ug(r));e.size=e.content.length})();varM=fg(C[3][0].data);{varU=M[1][0];M[3]=[{type:0,data:ig(Ng?1:0)}];varB=fg(U.data);{varW=kg(B[2][0].data);(function(){vare=Ze.find(l,o[W].location);varr=lg(dg(e.content));vart;for(vara=0;a<r.length;++a){vari=r[a];if(i.id==W)t=i}varc=fg(t.messages[0].data);{deletec[6];deleteM[7];varu=newUint8Array(c[5][0].data);c[5]=[];for(varh=0;h<=n.e.r;++h){vard=fg(u);Og(d,s[h],f,Ng);d[1][0].data=ig(h);c[5].push({data:og(d),type:2})}c[1]=[{type:0,data:ig(0)}];c[2]=[{type:0,data:ig(0)}];c[3]=[{type:0,data:ig(0)}];c[4]=[{type:0,data:ig(n.e.r+1)}];c[6]=[{type:0,data:ig(5)}];c[7]=[{type:0,data:ig(1)}];c[8]=[{type:0,data:ig(Ng?1:0)}]}t.messages[0].data=og(c);e.content=vg(ug(r));e.size=e.content.length})()}U.data=og(B)}C[3][0].data=og(M)}k[4][0].data=og(C)}p.messages[0].data=og(k);d.content=vg(ug(v));d.size=d.content.length;returnl}functionDg(e){returnfunctionr(t){for(vara=0;a!=e.length;++a){varn=e[a];if(t[n[0]]===undefined)t[n[0]]=n[1];if(n[2]==="n")t[n[0]]=Number(t[n[0]])}}}functionPg(