9);++r)n=10*n+i;if(t.s.r=--n,r===a||10!=i)return t.e.c=t.s.c,t.e.r=t.s.r,t;for(++r,n=0;r!=a&&!((i=e.charCodeAt(r)-64)<1||i>26);++r)n=26*n+i;for(t.e.c=--n,n=0;r!=a&&!((i=e.charCodeAt(r)-48)<0||i>9);++r)n=10*n+i;return t.e.r=--n,t}function Vi(e,t){var n="d"==e.t&&t instanceof Date;if(null!=e.z)try{return e.w=Tn(e.z,n?Ln(t):t)}catch(kC){}try{return e.w=Tn((e.XF||{}).numFmtId||(n?14:0),n?Ln(t):t)}catch(kC){return""+t}}function Ui(e,t,n){return null==e||null==e.t||"z"==e.t?"":void 0!==e.w?e.w:("d"==e.t&&!e.z&&n&&n.dateNF&&(e.z=n.dateNF),"e"==e.t?ya[e.v]||e.v:Vi(e,void 0==t?e.v:t))}function Hi(e,t){var n=t&&t.sheet?t.sheet:"Sheet1",r={};return r[n]=e,{SheetNames:[n],Sheets:r}}function Wi(e,t,n){var r=n||{},i=e?Array.isArray(e):r.dense;null!=wt&&null==i&&(i=wt);var a=e||(i?[]:{}),s=0,o=0;if(a&&null!=r.origin){if("number"==typeof r.origin)s=r.origin;else{var l="string"==typeof r.origin?Ni(r.origin):r.origin;s=l.r,o=l.c}a["!ref"]||(a["!ref"]="A1:A1")}var c={s:{c:1e7,r:1e7},e:{c:0,r:0}};if(a["!ref"]){var u=ji(a["!ref"]);c.s.c=u.s.c,c.s.r=u.s.r,c.e.c=Math.max(c.e.c,u.e.c),c.e.r=Math.max(c.e.r,u.e.r),-1==s&&(c.e.r=s=u.e.r+1)}for(var h=0;h!=t.length;++h)if(t[h]){if(!Array.isArray(t[h]))throw new Error("aoa_to_sheet expects an array of arrays");for(var f=0;f!=t[h].length;++f)if("undefined"!==typeof t[h][f]){var d={v:t[h][f]},p=s+h,m=o+f;if(c.s.r>p&&(c.s.r=p),c.s.c>m&&(c.s.c=m),c.e.r>2;return n?i/100:i}function ra(e){var t={s:{},e:{}};return t.s.r=e.read_shift(4),t.e.r=e.read_shift(4),t.s.c=e.read_shift(4),t.e.c=e.read_shift(4),t}var ia=ra;function aa(e){if(e.length-e.l<8)throw"XLS Xnum Buffer underflow";return e.read_shift(8,"f")}function sa(e,t){var n=e.read_shift(4);switch(n){case 0:return"";case 4294967295:case 4294967294:return{2:"BITMAP",3:"METAFILEPICT",8:"DIB",14:"ENHMETAFILE"}[e.read_shift(4)]||""}if(n>400)throw new Error("Unsupported Clipboard: "+n.toString(16));return e.l-=4,e.read_shift(0,1==t?"lpstr":"lpwstr")}var oa=2,la=3,ca=12,ua=80,ha=81,fa=[ua,ha],da={1:{n:"CodePage",t:oa},2:{n:"Category",t:ua},3:{n:"PresentationFormat",t:ua},4:{n:"ByteCount",t:la},5:{n:"LineCount",t:la},6:{n:"ParagraphCount",t:la},7:{n:"SlideCount",t:la},8:{n:"NoteCount",t:la},9:{n:"HiddenCount",t:la},10:{n:"MultimediaClipCount",t:la},11:{n:"ScaleCrop",t:11},12:{n:"HeadingPairs",t:4108},13:{n:"TitlesOfParts",t:4126},14:{n:"Manager",t:ua},15:{n:"Company",t:ua},16:{n:"LinksUpToDate",t:11},17:{n:"CharacterCount",t:la},19:{n:"SharedDoc",t:11},22:{n:"HyperlinksChanged",t:11},23:{n:"AppVersion",t:la,p:"version"},24:{n:"DigSig",t:65},26:{n:"ContentType",t:ua},27:{n:"ContentStatus",t:ua},28:{n:"Language",t:ua},29:{n:"Version",t:ua},255:{},2147483648:{n:"Locale",t:19},2147483651:{n:"Behavior",t:19},1919054434:{}},pa={1:{n:"CodePage",t:oa},2:{n:"Title",t:ua},3:{n:"Subject",t:ua},4:{n:"Author",t:ua},5:{n:"Keywords",t:ua},6:{n:"Comments",t:ua},7:{n:"Template",t:ua},8:{n:"LastAuthor",t:ua},9:{n:"RevNumber",t:ua},10:{n:"EditTime",t:64},11:{n:"LastPrinted",t:64},12:{n:"CreatedDate",t:64},13:{n:"ModifiedDate",t:64},14:{n:"PageCount",t:la},15:{n:"WordCount",t:la},16:{n:"CharCount",t:la},17:{n:"Thumbnail",t:71},18:{n:"Application",t:ua},19:{n:"DocSecurity",t:la},255:{},2147483648:{n:"Locale",t:19},2147483651:{n:"Behavior",t:19},1919054434:{}},ma={1:"US",2:"CA",3:"",7:"RU",20:"EG",30:"GR",31:"NL",32:"BE",33:"FR",34:"ES",36:"HU",39:"IT",41:"CH",43:"AT",44:"GB",45:"DK",46:"SE",47:"NO",48:"PL",49:"DE",52:"MX",55:"BR",61:"AU",64:"NZ",66:"TH",81:"JP",82:"KR",84:"VN",86:"CN",90:"TR",105:"JS",213:"DZ",216:"MA",218:"LY",351:"PT",354:"IS",358:"FI",420:"CZ",886:"TW",961:"LB",962:"JO",963:"SY",964:"IQ",965:"KW",966:"SA",971:"AE",972:"IL",974:"QA",981:"IR",65535:"US"},ga=[null,"solid","mediumGray","darkGray","lightGray","darkHorizontal","darkVertical","darkDown","darkUp","darkGrid","darkTrellis","lightHorizontal","lightVertical","lightDown","lightUp","lightGrid","lightTrellis","gray125","gray0625"];function va(e){return e.map((function(e){return[e>>16&255,e>>8&255,255&e]}))}var ba=$n(va([0,16777215,16711680,65280,255,16776960,16711935,65535,0,16777215,16711680,65280,255,16776960,16711935,65535,8388608,32768,128,8421376,8388736,32896,12632256,8421504,10066431,10040166,16777164,13434879,6684774,16744576,26316,13421823,128,16711935,16776960,65535,8388736,8388608,32896,255,52479,13434879,13434828,16777113,10079487,16751052,13408767,16764057,3368703,3394764,10079232,16763904,16750848,16737792,6710937,9868950,13158,3381606,13056,3355392,10040064,10040166,3355545,3355443,16777215,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])),ya={0:"#NULL!",7:"#DIV/0!",15:"#VALUE!",23:"#REF!",29:"#NAME?",36:"#NUM!",42:"#N/A",43:"#GETTING_DATA",255:"#WTF?"},xa={"#NULL!":0,"#DIV/0!":7,"#VALUE!":15,"#REF!":23,"#NAME?":29,"#NUM!":36,"#N/A":42,"#GETTING_DATA":43,"#WTF?":255},wa={"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":"workbooks","application/vnd.ms-excel.sheet.macroEnabled.main+xml":"workbooks","application/vnd.ms-excel.sheet.binary.macroEnabled.main":"workbooks","application/vnd.ms-excel.addin.macroEnabled.main+xml":"workbooks","application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":"workbooks","application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":"sheets","application/vnd.ms-excel.worksheet":"sheets","application/vnd.ms-excel.binIndexWs":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":"charts","application/vnd.ms-excel.chartsheet":"charts","application/vnd.ms-excel.macrosheet+xml":"macros","application/vnd.ms-excel.macrosheet":"macros","application/vnd.ms-excel.intlmacrosheet":"TODO","application/vnd.ms-excel.binIndexMs":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":"dialogs","application/vnd.ms-excel.dialogsheet":"dialogs","application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml":"strs","application/vnd.ms-excel.sharedStrings":"strs","application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":"styles","application/vnd.ms-excel.styles":"styles","application/vnd.openxmlformats-package.core-properties+xml":"coreprops","application/vnd.openxmlformats-officedocument.custom-properties+xml":"custprops","application/vnd.openxmlformats-officedocument.extended-properties+xml":"extprops","application/vnd.openxmlformats-officedocument.customXmlProperties+xml":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.customProperty":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":"comments","application/vnd.ms-excel.comments":"comments","application/vnd.ms-excel.threadedcomments+xml":"threadedcomments","application/vnd.ms-excel.person+xml":"people","application/vnd.openxmlformats-officedocument.spreadsheetml.sheetMetadata+xml":"metadata","application/vnd.ms-excel.sheetMetadata":"metadata","application/vnd.ms-excel.pivotTable":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.pivotTable+xml":"TODO","application/vnd.openxmlformats-officedocument.drawingml.chart+xml":"TODO","application/vnd.ms-office.chartcolorstyle+xml":"TODO","application/vnd.ms-office.chartstyle+xml":"TODO","application/vnd.ms-office.chartex+xml":"TODO","application/vnd.ms-excel.calcChain":"calcchains","application/vnd.openxmlformats-officedocument.spreadsheetml.calcChain+xml":"calcchains","application/vnd.openxmlformats-officedocument.spreadsheetml.printerSettings":"TODO","application/vnd.ms-office.activeX":"TODO","application/vnd.ms-office.activeX+xml":"TODO","application/vnd.ms-excel.attachedToolbars":"TODO","application/vnd.ms-excel.connections":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":"TODO","application/vnd.ms-excel.externalLink":"links","application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml":"links","application/vnd.ms-excel.pivotCacheDefinition":"TODO","application/vnd.ms-excel.pivotCacheRecords":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.pivotCacheDefinition+xml":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.pivotCacheRecords+xml":"TODO","application/vnd.ms-excel.queryTable":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.queryTable+xml":"TODO","application/vnd.ms-excel.userNames":"TODO","application/vnd.ms-excel.revisionHeaders":"TODO","application/vnd.ms-excel.revisionLog":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.revisionHeaders+xml":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.revisionLog+xml":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.userNames+xml":"TODO","application/vnd.ms-excel.tableSingleCells":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.tableSingleCells+xml":"TODO","application/vnd.ms-excel.slicer":"TODO","application/vnd.ms-excel.slicerCache":"TODO","application/vnd.ms-excel.slicer+xml":"TODO","application/vnd.ms-excel.slicerCache+xml":"TODO","application/vnd.ms-excel.wsSortMap":"TODO","application/vnd.ms-excel.table":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":"TODO","application/vnd.openxmlformats-officedocument.theme+xml":"themes","application/vnd.openxmlformats-officedocument.themeOverride+xml":"TODO","application/vnd.ms-excel.Timeline+xml":"TODO","application/vnd.ms-excel.TimelineCache+xml":"TODO","application/vnd.ms-office.vbaProject":"vba","application/vnd.ms-office.vbaProjectSignature":"TODO","application/vnd.ms-office.volatileDependencies":"TODO","application/vnd.openxmlformats-officedocument.spreadsheetml.volatileDependencies+xml":"TODO","application/vnd.ms-excel.controlproperties+xml":"TODO","application/vnd.openxmlformats-officedocument.model+data":"TODO","application/vnd.ms-excel.Survey+xml":"TODO","application/vnd.openxmlformats-officedocument.drawing+xml":"drawings","application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":"TODO","application/vnd.openxmlformats-officedocument.drawingml.diagramColors+xml":"TODO","application/vnd.openxmlformats-officedocument.drawingml.diagramData+xml":"TODO","application/vnd.openxmlformats-officedocument.drawingml.diagramLayout+xml":"TODO","application/vnd.openxmlformats-officedocument.drawingml.diagramStyle+xml":"TODO","application/vnd.openxmlformats-officedocument.vmlDrawing":"TODO","application/vnd.openxmlformats-package.relationships+xml":"rels","application/vnd.openxmlformats-officedocument.oleObject":"TODO","image/png":"TODO",sheet:"js"};var _a={WB:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",SHEET:"http://sheetjs.openxmlformats.org/officeDocument/2006/relationships/officeDocument",HLINK:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",VML:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",XPATH:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLinkPath",XMISS:"http://schemas.microsoft.com/office/2006/relationships/xlExternalLinkPath/xlPathMissing",XLINK:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLink",CXML:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml",CXMLP:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps",CMNT:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",CORE_PROPS:"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",EXT_PROPS:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",CUST_PROPS:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/custom-properties",SST:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",STY:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",THEME:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",CHART:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart",CHARTEX:"http://schemas.microsoft.com/office/2014/relationships/chartEx",CS:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/chartsheet",WS:["http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet","http://purl.oclc.org/ooxml/officeDocument/relationships/worksheet"],DS:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/dialogsheet",MS:"http://schemas.microsoft.com/office/2006/relationships/xlMacrosheet",IMG:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",DRAW:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",XLMETA:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sheetMetadata",TCMNT:"http://schemas.microsoft.com/office/2017/10/relationships/threadedComment",PEOPLE:"http://schemas.microsoft.com/office/2017/10/relationships/person",VBA:"http://schemas.microsoft.com/office/2006/relationships/vbaProject"};function Ta(e){var t=e.lastIndexOf("/");return e.slice(0,t+1)+"_rels/"+e.slice(t+1)+".rels"}function Ea(e,t){var n={"!id":{}};if(!e)return n;"/"!==t.charAt(0)&&(t="/"+t);var r={};return(e.match(hr)||[]).forEach((function(e){var i=pr(e);if("]*>([\\s\\S]*?)"+r+">")}return e}();function Aa(e){var t={};e=Ar(e);for(var n=0;n0&&(t[r[1]]=br(i[1])),"date"===r[2]&&t[r[1]]&&(t[r[1]]=Hn(t[r[1]]))}return t}var Ma=[["Application","Application","string"],["AppVersion","AppVersion","string"],["Company","Company","string"],["DocSecurity","DocSecurity","string"],["Manager","Manager","string"],["HyperlinksChanged","HyperlinksChanged","bool"],["SharedDoc","SharedDoc","bool"],["LinksUpToDate","LinksUpToDate","bool"],["ScaleCrop","ScaleCrop","bool"],["HeadingPairs","HeadingPairs","raw"],["TitlesOfParts","TitlesOfParts","raw"]];function Pa(e,t,n,r){var i=[];if("string"==typeof e)i=Ir(e,r);else for(var a=0;a0)for(var c=0;c!==i.length;c+=2){switch(l=+i[c+1].v,i[c].v){case"Worksheets":case"\u5de5\u4f5c\u8868":case"\u041b\u0438\u0441\u0442\u044b":case"\u0623\u0648\u0631\u0627\u0642 \u0627\u0644\u0639\u0645\u0644":case"\u30ef\u30fc\u30af\u30b7\u30fc\u30c8":case"\u05d2\u05dc\u05d9\u05d5\u05e0\u05d5\u05ea \u05e2\u05d1\u05d5\u05d3\u05d4":case"Arbeitsbl\xe4tter":case"\xc7al\u0131\u015fma Sayfalar\u0131":case"Feuilles de calcul":case"Fogli di lavoro":case"Folhas de c\xe1lculo":case"Planilhas":case"Regneark":case"Hojas de c\xe1lculo":case"Werkbladen":n.Worksheets=l,n.SheetNames=s.slice(o,o+l);break;case"Named Ranges":case"Rangos con nombre":case"\u540d\u524d\u4ed8\u304d\u4e00\u89a7":case"Benannte Bereiche":case"Navngivne omr\xe5der":n.NamedRanges=l,n.DefinedNames=s.slice(o,o+l);break;case"Charts":case"Diagramme":n.Chartsheets=l,n.ChartNames=s.slice(o,o+l)}o+=l}}var Oa=/<[^>]+>[^<]*/g;var Ra,Da={Title:"Title",Subject:"Subject",Author:"Author",Keywords:"Keywords",Comments:"Description",LastAuthor:"LastAuthor",RevNumber:"Revision",Application:"AppName",LastPrinted:"LastPrinted",CreatedDate:"Created",ModifiedDate:"LastSaved",Category:"Category",Manager:"Manager",Company:"Company",AppVersion:"Version",ContentStatus:"ContentStatus",Identifier:"Identifier",Language:"Language"};function La(e,t,n){Ra||(Ra=Rn(Da)),e[t=Ra[t]||t]=n}function Ia(e){var t=e.read_shift(4),n=e.read_shift(4);return new Date(1e3*(n/1e7*Math.pow(2,32)+t/1e7-11644473600)).toISOString().replace(/\.000/,"")}function Na(e,t,n){var r=e.l,i=e.read_shift(0,"lpstr-cp");if(n)for(;e.l-r&3;)++e.l;return i}function Fa(e,t,n){var r=e.read_shift(0,"lpwstr");return n&&(e.l+=4-(r.length+1&3)&3),r}function za(e,t,n){return 31===t?Fa(e):Na(e,0,n)}function Ba(e,t,n){return za(e,t,!1===n?0:4)}function ja(e){var t=e.l,n=Ha(e,ha);return 0==e[e.l]&&0==e[e.l+1]&&e.l-t&2&&(e.l+=2),[n,Ha(e,la)]}function Va(e,t){for(var n=e.read_shift(4),r={},i=0;i!=n;++i){var a=e.read_shift(4),s=e.read_shift(4);r[a]=e.read_shift(s,1200===t?"utf16le":"utf8").replace(Dt,"").replace(Lt,"!"),1200===t&&s%2&&(e.l+=2)}return 3&e.l&&(e.l=e.l>>3<<2),r}function Ua(e){var t=e.read_shift(4),n=e.slice(e.l,e.l+t);return e.l+=t,(3&t)>0&&(e.l+=4-(3&t)&3),n}function Ha(e,t,n){var r,i=e.read_shift(2),a=n||{};if(e.l+=2,t!==ca&&i!==t&&-1===fa.indexOf(t)&&(4126!=(65534&t)||4126!=(65534&i)))throw new Error("Expected type "+t+" saw "+i);switch(t===ca?i:t){case 2:return r=e.read_shift(2,"i"),a.raw||(e.l+=2),r;case 3:return r=e.read_shift(4,"i");case 11:return 0!==e.read_shift(4);case 19:return r=e.read_shift(4);case 30:return Na(e,0,4).replace(Dt,"");case 31:return Fa(e);case 64:return Ia(e);case 65:return Ua(e);case 71:return function(e){var t={};return t.Size=e.read_shift(4),e.l+=t.Size+3-(t.Size-1)%4,t}(e);case 80:return Ba(e,i,!a.raw).replace(Dt,"");case 81:return function(e,t){if(!t)throw new Error("VtUnalignedString must have positive length");return za(e,t,0)}(e,i).replace(Dt,"");case 4108:return function(e){for(var t=e.read_shift(4),n=[],r=0;r0&&t)switch(t[a[s-1][0]].t){case 2:e.l+2===a[s][1]&&(e.l+=2,d=!1);break;case 80:case 4108:e.l<=a[s][1]&&(e.l=a[s][1],d=!1)}if((!t||0==s)&&e.l<=a[s][1]&&(d=!1,e.l=a[s][1]),d)throw new Error("Read Error: Expected address "+a[s][1]+" at "+e.l+" :"+s)}if(t){var p=t[a[s][0]];if(f[p.n]=Ha(e,p.t,{raw:!0}),"version"===p.p&&(f[p.n]=String(f[p.n]>>16)+"."+("0000"+String(65535&f[p.n])).slice(-4)),"CodePage"==p.n)switch(f[p.n]){case 0:f[p.n]=1252;case 874:case 932:case 936:case 949:case 950:case 1250:case 1251:case 1253:case 1254:case 1255:case 1256:case 1257:case 1258:case 1e4:case 1200:case 1201:case 1252:case 65e3:case-536:case 65001:case-535:dt(o=f[p.n]>>>0&65535);break;default:throw new Error("Unsupported CodePage: "+f[p.n])}}else if(1===a[s][0]){if(o=f.CodePage=Ha(e,oa),dt(o),-1!==l){var m=e.l;e.l=a[l][1],c=Va(e,o),e.l=m}}else if(0===a[s][0]){if(0===o){l=s,e.l=a[s+1][1];continue}c=Va(e,o)}else{var g,v=c[a[s][0]];switch(e[e.l]){case 65:e.l+=4,g=Ua(e);break;case 30:case 31:e.l+=4,g=Ba(e,e[e.l-4]).replace(/\u0000+$/,"");break;case 3:e.l+=4,g=e.read_shift(4,"i");break;case 19:e.l+=4,g=e.read_shift(4);break;case 5:e.l+=4,g=e.read_shift(8,"f");break;case 11:e.l+=4,g=Ka(e,4);break;case 64:e.l+=4,g=Hn(Ia(e));break;default:throw new Error("unparsed value: "+e[e.l])}f[v]=g}}return e.l=n+r,f}function $a(e,t,n){var r=e.content;if(!r)return{};Ti(r,0);var i,a,s,o,l=0;r.chk("feff","Byte Order: "),r.read_shift(2);var c=r.read_shift(4),u=r.read_shift(16);if(u!==Mn.utils.consts.HEADER_CLSID&&u!==n)throw new Error("Bad PropertySet CLSID "+u);if(1!==(i=r.read_shift(4))&&2!==i)throw new Error("Unrecognized #Sets: "+i);if(a=r.read_shift(16),o=r.read_shift(4),1===i&&o!==r.l)throw new Error("Length mismatch: "+o+" !== "+r.l);2===i&&(s=r.read_shift(16),l=r.read_shift(4));var h,f=Wa(r,t),d={SystemIdentifier:c};for(var p in f)d[p]=f[p];if(d.FMTID=a,1===i)return d;if(l-r.l==2&&(r.l+=2),r.l!==l)throw new Error("Length mismatch 2: "+r.l+" !== "+l);try{h=Wa(r,null)}catch(kC){}for(p in h)d[p]=h[p];return d.FMTID=[a,s],d}function Ga(e,t){return e.read_shift(t),null}function Ka(e,t){return 1===e.read_shift(t)}function Ya(e){return e.read_shift(2,"u")}function Xa(e,t){return function(e,t,n){for(var r=[],i=e.l+t;e.l=12?2:1),i="sbcs-cont",a=lt;(n&&n.biff>=8&&(lt=1200),n&&8!=n.biff)?12==n.biff&&(i="wstr"):e.read_shift(1)&&(i="dbcs-cont");n.biff>=2&&n.biff<=5&&(i="cpstr");var s=r?e.read_shift(r,i):"";return lt=a,s}function Za(e){var t=lt;lt=1200;var n,r=e.read_shift(2),i=e.read_shift(1),a=4&i,s=8&i,o=1+(1&i),l=0,c={};s&&(l=e.read_shift(2)),a&&(n=e.read_shift(4));var u=2==o?"dbcs-cont":"sbcs-cont",h=0===r?"":e.read_shift(r,u);return s&&(e.l+=4*l),a&&(e.l+=n),c.t=h,s||(c.raw=""+c.t+"",c.r=c.t),lt=t,c}function Qa(e,t,n){if(n){if(n.biff>=2&&n.biff<=5)return e.read_shift(t,"cpstr");if(n.biff>=12)return e.read_shift(t,"dbcs-cont")}return 0===e.read_shift(1)?e.read_shift(t,"sbcs-cont"):e.read_shift(t,"dbcs-cont")}function Ja(e,t,n){var r=e.read_shift(n&&2==n.biff?1:2);return 0===r?(e.l++,""):Qa(e,r,n)}function es(e,t,n){if(n.biff>5)return Ja(e,0,n);var r=e.read_shift(1);return 0===r?(e.l++,""):e.read_shift(r,n.biff<=4||!e.lens?"cpstr":"sbcs-cont")}function ts(e,t){var n=e.read_shift(16);switch(16,n){case"e0c9ea79f9bace118c8200aa004ba90b":return function(e){var t=e.read_shift(4),n=e.l,r=!1;t>24&&(e.l+=t-24,"795881f43b1d7f48af2c825dc4852763"===e.read_shift(16)&&(r=!0),e.l=n);var i=e.read_shift((r?t-24:t)>>1,"utf16le").replace(Dt,"");return r&&(e.l+=24),i}(e);case"0303000000000000c000000000000046":return function(e){for(var t=e.read_shift(2),n="";t-- >0;)n+="../";var r=e.read_shift(0,"lpstr-ansi");if(e.l+=2,57005!=e.read_shift(2))throw new Error("Bad FileMoniker");if(0===e.read_shift(4))return n+r.replace(/\\/g,"/");var i=e.read_shift(4);if(3!=e.read_shift(2))throw new Error("Bad FileMoniker");return n+e.read_shift(i>>1,"utf16le").replace(Dt,"")}(e);default:throw new Error("Unsupported Moniker "+n)}}function ns(e){var t=e.read_shift(4);return t>0?e.read_shift(t,"utf16le").replace(Dt,""):""}function rs(e){return[e.read_shift(1),e.read_shift(1),e.read_shift(1),e.read_shift(1)]}function is(e,t){var n=rs(e);return n[3]=0,n}function as(e){return{r:e.read_shift(2),c:e.read_shift(2),ixfe:e.read_shift(2)}}function ss(e,t,n){var r=n.biff>8?4:2;return[e.read_shift(r),e.read_shift(r,"i"),e.read_shift(r,"i")]}function os(e){return[e.read_shift(2),na(e)]}function ls(e){var t=e.read_shift(2),n=e.read_shift(2);return{s:{c:e.read_shift(2),r:t},e:{c:e.read_shift(2),r:n}}}function cs(e){var t=e.read_shift(2),n=e.read_shift(2);return{s:{c:e.read_shift(1),r:t},e:{c:e.read_shift(1),r:n}}}var us=cs;function hs(e){e.l+=4;var t=e.read_shift(2),n=e.read_shift(2),r=e.read_shift(2);return e.l+=12,[n,t,r]}function fs(e){e.l+=2,e.l+=e.read_shift(2)}var ds={0:fs,4:fs,5:fs,6:fs,7:function(e){return e.l+=4,e.cf=e.read_shift(2),{}},8:fs,9:fs,10:fs,11:fs,12:fs,13:function(e){var t={};return e.l+=4,e.l+=16,t.fSharedNote=e.read_shift(2),e.l+=4,t},14:fs,15:fs,16:fs,17:fs,18:fs,19:fs,20:fs,21:hs};function ps(e,t){var n={BIFFVer:0,dt:0};switch(n.BIFFVer=e.read_shift(2),(t-=2)>=2&&(n.dt=e.read_shift(2),e.l-=2),n.BIFFVer){case 1536:case 1280:case 1024:case 768:case 512:case 2:case 7:break;default:if(t>6)throw new Error("Unexpected BIFF Ver "+n.BIFFVer)}return e.read_shift(t),n}function ms(e,t,n){var r=0;n&&2==n.biff||(r=e.read_shift(2));var i=e.read_shift(2);return n&&2==n.biff&&(r=1-(i>>15),i&=32767),[{Unsynced:1&r,DyZero:(2&r)>>1,ExAsc:(4&r)>>2,ExDsc:(8&r)>>3},i]}var gs=es;function vs(e,t,n){var r=e.l+t,i=8!=n.biff&&n.biff?2:4,a=e.read_shift(i),s=e.read_shift(i),o=e.read_shift(2),l=e.read_shift(2);return e.l=r,{s:{r:a,c:o},e:{r:s,c:l}}}function bs(e,t,n){var r=as(e);2!=n.biff&&9!=t||++e.l;var i=function(e){var t=e.read_shift(1);return 1===e.read_shift(1)?t:1===t}(e);return r.val=i,r.t=!0===i||!1===i?"b":"e",r}var ys=function(e,t,n){return 0===t?"":es(e,0,n)};function xs(e,t,n){var r,i=e.read_shift(2),a={fBuiltIn:1&i,fWantAdvise:i>>>1&1,fWantPict:i>>>2&1,fOle:i>>>3&1,fOleLink:i>>>4&1,cf:i>>>5&1023,fIcon:i>>>15&1};return 14849===n.sbcch&&(r=function(e,t,n){e.l+=4,t-=4;var r=e.l+t,i=qa(e,0,n),a=e.read_shift(2);if(a!==(r-=e.l))throw new Error("Malformed AddinUdf: padding = "+r+" != "+a);return e.l+=a,i}(e,t-2,n)),a.body=r||e.read_shift(t-2),"string"===typeof r&&(a.Name=r),a}var ws=["_xlnm.Consolidate_Area","_xlnm.Auto_Open","_xlnm.Auto_Close","_xlnm.Extract","_xlnm.Database","_xlnm.Criteria","_xlnm.Print_Area","_xlnm.Print_Titles","_xlnm.Recorder","_xlnm.Data_Form","_xlnm.Auto_Activate","_xlnm.Auto_Deactivate","_xlnm.Sheet_Title","_xlnm._FilterDatabase"];function _s(e,t,n){var r=e.l+t,i=e.read_shift(2),a=e.read_shift(1),s=e.read_shift(1),o=e.read_shift(n&&2==n.biff?1:2),l=0;(!n||n.biff>=5)&&(5!=n.biff&&(e.l+=2),l=e.read_shift(2),5==n.biff&&(e.l+=2),e.l+=4);var c=Qa(e,s,n);32&i&&(c=ws[c.charCodeAt(0)]);var u=r-e.l;n&&2==n.biff&&--u;var h=r!=e.l&&0!==o&&u>0?function(e,t,n,r){var i,a=e.l+t,s=ml(e,r,n);a!==e.l&&(i=pl(e,a-e.l,s,n));return[s,i]}(e,u,n,o):[];return{chKey:a,Name:c,itab:l,rgce:h}}function Ts(e,t,n){if(n.biff<8)return function(e,t,n){3==e[e.l+1]&&e[e.l]++;var r=qa(e,0,n);return 3==r.charCodeAt(0)?r.slice(1):r}(e,0,n);for(var r=[],i=e.l+t,a=e.read_shift(n.biff>8?4:2);0!==a--;)r.push(ss(e,n.biff,n));if(e.l!=i)throw new Error("Bad ExternSheet: "+e.l+" != "+i);return r}function Es(e,t,n){var r=us(e,6);switch(n.biff){case 2:e.l++,t-=7;break;case 3:case 4:e.l+=2,t-=8;break;default:e.l+=6,t-=12}return[r,wl(e,t,n)]}var ks={8:function(e,t){var n=e.l+t;e.l+=10;var r=e.read_shift(2);e.l+=4,e.l+=2,e.l+=2,e.l+=2,e.l+=4;var i=e.read_shift(1);return e.l+=i,e.l=n,{fmt:r}}};function Ss(e,t,n){if(!n.cellStyles)return Ei(e,t);var r=n&&n.biff>=12?4:2,i=e.read_shift(r),a=e.read_shift(r),s=e.read_shift(r),o=e.read_shift(r),l=e.read_shift(2);2==r&&(e.l+=2);var c={s:i,e:a,w:s,ixfe:o,flags:l};return(n.biff>=5||!n.biff)&&(c.level=l>>8&7),c}var Cs=as,As=Xa,Ms=Ja;var Ps=[2,3,48,49,131,139,140,245],Os=function(){var e={1:437,2:850,3:1252,4:1e4,100:852,101:866,102:865,103:861,104:895,105:620,106:737,107:857,120:950,121:949,122:936,123:932,124:874,125:1255,126:1256,150:10007,151:10029,152:10006,200:1250,201:1251,202:1254,203:1253,0:20127,8:865,9:437,10:850,11:437,13:437,14:850,15:437,16:850,17:437,18:850,19:932,20:850,21:437,22:850,23:865,24:437,25:437,26:850,27:437,28:863,29:850,31:852,34:852,35:852,36:860,37:850,38:866,55:850,64:852,77:936,78:949,79:950,80:874,87:1252,88:1252,89:1252,108:863,134:737,135:852,136:857,204:1257,255:16969},t=Rn({1:437,2:850,3:1252,4:1e4,100:852,101:866,102:865,103:861,104:895,105:620,106:737,107:857,120:950,121:949,122:936,123:932,124:874,125:1255,126:1256,150:10007,151:10029,152:10006,200:1250,201:1251,202:1254,203:1253,0:20127});function n(t,n){var r=n||{};r.dateNF||(r.dateNF="yyyymmdd");var i=$i(function(t,n){var r=[],i=Ct(1);switch(n.type){case"base64":i=Mt(Et(t));break;case"binary":i=Mt(t);break;case"buffer":case"array":i=t}Ti(i,0);var a=i.read_shift(1),s=!!(136&a),o=!1,l=!1;switch(a){case 2:case 3:case 131:case 139:case 245:break;case 48:case 49:o=!0,s=!0;break;case 140:l=!0;break;default:throw new Error("DBF Unsupported Version: "+a.toString(16))}var c=0,u=521;2==a&&(c=i.read_shift(2)),i.l+=3,2!=a&&(c=i.read_shift(4)),c>1048576&&(c=1e6),2!=a&&(u=i.read_shift(2));var h=i.read_shift(2),f=n.codepage||1252;2!=a&&(i.l+=16,i.read_shift(1),0!==i[i.l]&&(f=e[i[i.l]]),i.l+=1,i.l+=2),l&&(i.l+=36);for(var d=[],p={},m=Math.min(i.length,2==a?521:u-10-(o?264:0)),g=l?32:11;i.l0;)if(42!==i[i.l])for(++i.l,r[++v]=[],b=0,b=0;b!=d.length;++b){var y=i.slice(i.l,i.l+d[b].len);i.l+=d[b].len,Ti(y,0);var x=vt.utils.decode(f,y);switch(d[b].type){case"C":x.trim().length&&(r[v][b]=x.replace(/\s+$/,""));break;case"D":8===x.length?r[v][b]=new Date(+x.slice(0,4),+x.slice(4,6)-1,+x.slice(6,8)):r[v][b]=x;break;case"F":r[v][b]=parseFloat(x.trim());break;case"+":case"I":r[v][b]=l?2147483648^y.read_shift(-4,"i"):y.read_shift(4,"i");break;case"L":switch(x.trim().toUpperCase()){case"Y":case"T":r[v][b]=!0;break;case"N":case"F":r[v][b]=!1;break;case"":case"?":break;default:throw new Error("DBF Unrecognized L:|"+x+"|")}break;case"M":if(!s)throw new Error("DBF Unexpected MEMO for type "+a.toString(16));r[v][b]="##MEMO##"+(l?parseInt(x.trim(),10):y.read_shift(4));break;case"N":(x=x.replace(/\u0000/g,"").trim())&&"."!=x&&(r[v][b]=+x||0);break;case"@":r[v][b]=new Date(y.read_shift(-8,"f")-621356832e5);break;case"T":r[v][b]=new Date(864e5*(y.read_shift(4)-2440588)+y.read_shift(4));break;case"Y":r[v][b]=y.read_shift(4,"i")/1e4+y.read_shift(4,"i")/1e4*Math.pow(2,32);break;case"O":r[v][b]=-y.read_shift(-8,"f");break;case"B":if(o&&8==d[b].len){r[v][b]=y.read_shift(8,"f");break}case"G":case"P":y.l+=d[b].len;break;case"0":if("_NullFlags"===d[b].name)break;default:throw new Error("DBF Unsupported data type "+d[b].type)}}else i.l+=h;if(2!=a&&i.l=0&&dt(+i.codepage),"string"==i.type)throw new Error("Cannot write DBF to JS string");var a=Ci(),s=Nu(e,{header:1,raw:!0,cellDates:!0}),o=s[0],l=s.slice(1),c=e["!cols"]||[],u=0,h=0,f=0,d=1;for(u=0;u250&&(x=250),"C"==(y=((c[u]||{}).DBF||{}).type)&&c[u].DBF.len>x&&(x=c[u].DBF.len),"B"==b&&"N"==y&&(b="N",v[u]=c[u].DBF.dec,x=c[u].DBF.len),g[u]="C"==b||"N"==y?x:r[b]||0,d+=g[u],m[u]=b}else m[u]="?"}var _=a.next(32);for(_.write_shift(4,318902576),_.write_shift(4,l.length),_.write_shift(2,296+32*f),_.write_shift(2,d),u=0;u<4;++u)_.write_shift(4,0);for(_.write_shift(4,(+t[ct]||3)<<8),u=0,h=0;u":190,"?":191,"{":223},t=new RegExp("\x1bN("+On(e).join("|").replace(/\|\|\|/,"|\\||").replace(/([?()+])/g,"\\$1")+"|\\|)","gm"),n=function(t,n){var r=e[n];return"number"==typeof r?xt(r):r},r=function(e,t,n){var r=t.charCodeAt(0)-32<<4|n.charCodeAt(0)-48;return 59==r?e:xt(r)};function i(e,i){var a,s=e.split(/[\n\r]+/),o=-1,l=-1,c=0,u=0,h=[],f=[],d=null,p={},m=[],g=[],v=[],b=0;for(+i.codepage>=0&&dt(+i.codepage);c!==s.length;++c){b=0;var y,x=s[c].trim().replace(/\x1B([\x20-\x2F])([\x30-\x3F])/g,r).replace(t,n),w=x.replace(/;;/g,"\0").split(";").map((function(e){return e.replace(/\u0000/g,";")})),_=w[0];if(x.length>0)switch(_){case"ID":case"E":case"B":case"O":case"W":break;case"P":"P"==w[1].charAt(0)&&f.push(x.slice(3).replace(/;;/g,";"));break;case"C":var T=!1,E=!1,k=!1,S=!1,C=-1,A=-1;for(u=1;u-1&&h[C][A];if(!P||!P[1])throw new Error("SYLK shared formula cannot find base");h[o][l][1]=Go(P[1],{r:o-C,c:l-A})}break;case"F":var O=0;for(u=1;u0?(m[o].hpt=b,m[o].hpx=wo(b)):0===b&&(m[o].hidden=!0);break;default:if(i&&i.WTF)throw new Error("SYLK bad record "+x)}O<1&&(d=null);break;default:if(i&&i.WTF)throw new Error("SYLK bad record "+x)}}return m.length>0&&(p["!rows"]=m),g.length>0&&(p["!cols"]=g),i&&i.sheetRows&&(h=h.slice(0,i.sheetRows)),[h,p]}function a(e,t){var n=function(e,t){switch(t.type){case"base64":return i(Et(e),t);case"binary":return i(e,t);case"buffer":return i(kt&&Buffer.isBuffer(e)?e.toString("binary"):Pt(e),t);case"array":return i(Wn(e),t)}throw new Error("Unrecognized type "+t.type)}(e,t),r=n[0],a=n[1],s=$i(r,t);return On(a).forEach((function(e){s[e]=a[e]})),s}function s(e,t,n,r){var i="C;Y"+(n+1)+";X"+(r+1)+";K";switch(e.t){case"n":i+=e.v||0,e.f&&!e.F&&(i+=";E"+$o(e.f,{r:n,c:r}));break;case"b":i+=e.v?"TRUE":"FALSE";break;case"e":i+=e.w||e.v;break;case"d":i+='"'+(e.w||e.v)+'"';break;case"s":i+='"'+e.v.replace(/"/g,"").replace(/;/g,";;")+'"'}return i}return e["|"]=254,{to_workbook:function(e,t){return Hi(a(e,t),t)},to_sheet:a,from_sheet:function(e,t){var n,r,i=["ID;PWXL;N;E"],a=[],o=ji(e["!ref"]),l=Array.isArray(e),c="\r\n";i.push("P;PGeneral"),i.push("F;P0;DG0G8;M255"),e["!cols"]&&(r=i,e["!cols"].forEach((function(e,t){var n="F;W"+(t+1)+" "+(t+1)+" ";e.hidden?n+="0":("number"!=typeof e.width||e.wpx||(e.wpx=fo(e.width)),"number"!=typeof e.wpx||e.wch||(e.wch=po(e.wpx)),"number"==typeof e.wch&&(n+=Math.round(e.wch)))," "!=n.charAt(n.length-1)&&r.push(n)}))),e["!rows"]&&function(e,t){t.forEach((function(t,n){var r="F;";t.hidden?r+="M0;":t.hpt?r+="M"+20*t.hpt+";":t.hpx&&(r+="M"+20*xo(t.hpx)+";"),r.length>2&&e.push(r+"R"+(n+1))}))}(i,e["!rows"]),i.push("B;Y"+(o.e.r-o.s.r+1)+";X"+(o.e.c-o.s.c+1)+";D"+[o.s.c,o.s.r,o.e.c,o.e.r].join(" "));for(var u=o.s.r;u<=o.e.r;++u)for(var h=o.s.c;h<=o.e.c;++h){var f=Fi({r:u,c:h});(n=l?(e[u]||[])[h]:e[f])&&(null!=n.v||n.f&&!n.F)&&a.push(s(n,0,u,h))}return i.join(c)+c+a.join(c)+c+"E"+c}}}(),Ds=function(){function e(e,t){for(var n=e.split("\n"),r=-1,i=-1,a=0,s=[];a!==n.length;++a)if("BOT"!==n[a].trim()){if(!(r<0)){for(var o=n[a].trim().split(","),l=o[0],c=o[1],u=n[++a]||"";1&(u.match(/["]/g)||[]).length&&a=0?o=c:i=c}})),l>=0&&-1==o&&i>=0&&(o=i,i=-1);var c=(""+(r>=0?r:(new Date).getFullYear())).slice(-4)+"-"+("00"+(i>=1?i:1)).slice(-2)+"-"+("00"+(a>=1?a:1)).slice(-2);7==c.length&&(c="0"+c),8==c.length&&(c="20"+c);var u=("00"+(s>=0?s:0)).slice(-2)+":"+("00"+(o>=0?o:0)).slice(-2)+":"+("00"+(l>=0?l:0)).slice(-2);return-1==s&&-1==o&&-1==l?c:-1==r&&-1==i&&-1==a?u:c+"T"+u}(0,n.dateNF,t.match(g)||[]),i=1),n.cellDates?(r.t="d",r.v=Hn(t,i)):(r.t="n",r.v=Ln(Hn(t,i))),!1!==n.cellText&&(r.w=Tn(r.z,r.v instanceof Date?Ln(r.v):r.v)),n.cellNF||delete r.z}else r.t="s",r.v=t;else r.t="n",!1!==n.cellText&&(r.w=t),r.v=c;if("z"==r.t||(n.dense?(a[o]||(a[o]=[]),a[o][l]=r):a[Fi({c:l,r:o})]=r),u=h+1,m=e.charCodeAt(u),s.e.c0&&v(),a["!ref"]=Bi(s),a}function a(t,n){return n&&n.PRN?n.FS||"sep="==t.slice(0,4)||t.indexOf("\t")>=0||t.indexOf(",")>=0||t.indexOf(";")>=0?i(t,n):$i(function(t,n){var r=n||{},i=[];if(!t||0===t.length)return i;for(var a=t.split(/[\r\n]/),s=a.length-1;s>=0&&0===a[s].length;)--s;for(var o=10,l=0,c=0;c<=s;++c)-1==(l=a[c].indexOf(" "))?l=a[c].length:l++,o=Math.max(o,l);for(c=0;c<=s;++c){i[c]=[];var u=0;for(e(a[c].slice(0,o).trim(),i,c,u,r),u=1;u<=(a[c].length-o)/10+1;++u)e(a[c].slice(o+10*(u-1),o+10*u).trim(),i,c,u,r)}return r.sheetRows&&(i=i.slice(0,r.sheetRows)),i}(t,n),n):i(t,n)}function s(e,t){var n="",r="string"==t.type?[0,0,0,0]:Ou(e,t);switch(t.type){case"base64":n=Et(e);break;case"binary":case"string":n=e;break;case"buffer":n=65001==t.codepage?e.toString("utf8"):t.codepage&&"undefined"!==typeof vt?vt.utils.decode(t.codepage,e):kt&&Buffer.isBuffer(e)?e.toString("binary"):Pt(e);break;case"array":n=Wn(e);break;default:throw new Error("Unrecognized type "+t.type)}return 239==r[0]&&187==r[1]&&191==r[2]?n=Ar(n.slice(3)):"string"!=t.type&&"buffer"!=t.type&&65001==t.codepage?n=Ar(n):"binary"==t.type&&"undefined"!==typeof vt&&t.codepage&&(n=vt.utils.decode(t.codepage,vt.utils.encode(28591,n))),"socialcalc:version:"==n.slice(0,19)?Ls.to_sheet("string"==t.type?n:Ar(n),t):a(n,t)}return{to_workbook:function(e,t){return Hi(s(e,t),t)},to_sheet:s,from_sheet:function(e){for(var t,n=[],r=ji(e["!ref"]),i=Array.isArray(e),a=r.s.r;a<=r.e.r;++a){for(var s=[],o=r.s.c;o<=r.e.c;++o){var l=Fi({r:a,c:o});if((t=i?(e[a]||[])[o]:e[l])&&null!=t.v){for(var c=(t.w||(Ui(t),t.w)||"").slice(0,10);c.length<10;)c+=" ";s.push(c+(0===o?" ":""))}else s.push(" ")}n.push(s.join(""))}return n.join("\n")}}}();var Ns=function(){function e(e,t,n){if(e){Ti(e,e.l||0);for(var r=n.Enum||v;e.l=16&&5==t[14]&&108===t[15])throw new Error("Unsupported Works 3 for Mac file");if(2==t[2])r.Enum=v,e(t,(function(e,t,n){switch(n){case 0:r.vers=e,e>=4096&&(r.qpro=!0);break;case 6:h=e;break;case 204:e&&(s=e);break;case 222:s=e;break;case 15:case 51:r.qpro||(e[1].v=e[1].v.slice(1));case 13:case 14:case 16:14==n&&112==(112&e[2])&&(15&e[2])>1&&(15&e[2])<15&&(e[1].z=r.dateNF||Wt[14],r.cellDates&&(e[1].t="d",e[1].v=zn(e[1].v))),r.qpro&&e[3]>o&&(i["!ref"]=Bi(h),l[a]=i,c.push(a),i=r.dense?[]:{},h={s:{r:0,c:0},e:{r:0,c:0}},o=e[3],a=s||"Sheet"+(o+1),s="");var u=r.dense?(i[e[0].r]||[])[e[0].c]:i[Fi(e[0])];if(u){u.t=e[1].t,u.v=e[1].v,null!=e[1].z&&(u.z=e[1].z),null!=e[1].f&&(u.f=e[1].f);break}r.dense?(i[e[0].r]||(i[e[0].r]=[]),i[e[0].r][e[0].c]=e[1]):i[Fi(e[0])]=e[1]}}),r);else{if(26!=t[2]&&14!=t[2])throw new Error("Unrecognized LOTUS BOF "+t[2]);r.Enum=b,14==t[2]&&(r.qpro=!0,t.l=0),e(t,(function(e,t,n){switch(n){case 204:a=e;break;case 22:e[1].v=e[1].v.slice(1);case 23:case 24:case 25:case 37:case 39:case 40:if(e[3]>o&&(i["!ref"]=Bi(h),l[a]=i,c.push(a),i=r.dense?[]:{},h={s:{r:0,c:0},e:{r:0,c:0}},o=e[3],a="Sheet"+(o+1)),f>0&&e[0].r>=f)break;r.dense?(i[e[0].r]||(i[e[0].r]=[]),i[e[0].r][e[0].c]=e[1]):i[Fi(e[0])]=e[1],h.e.c=128?95:a)}return r.write_shift(1,0),r}function a(e,t,n){var r=ki(7);return r.write_shift(1,255),r.write_shift(2,t),r.write_shift(2,e),r.write_shift(2,n,"i"),r}function s(e,t,n){var r=ki(13);return r.write_shift(1,255),r.write_shift(2,t),r.write_shift(2,e),r.write_shift(8,n,"f"),r}function o(e,t,n){var r=32768&t;return t=(r?e:0)+((t&=-32769)>=8192?t-16384:t),(r?"":"$")+(n?Ii(t):Di(t))}var l={51:["FALSE",0],52:["TRUE",0],70:["LEN",1],80:["SUM",69],81:["AVERAGEA",69],82:["COUNTA",69],83:["MINA",69],84:["MAXA",69],111:["T",1]},c=["","","","","","","","","","+","-","*","/","^","=","<>","<=",">=","<",">","","","","","&","","","","","","",""];function u(e){var t=[{c:0,r:0},{t:"n",v:0},0];return t[0].r=e.read_shift(2),t[3]=e[e.l++],t[0].c=e[e.l++],t}function h(e,t,n,r){var i=ki(6+r.length);i.write_shift(2,e),i.write_shift(1,n),i.write_shift(1,t),i.write_shift(1,39);for(var a=0;a=128?95:s)}return i.write_shift(1,0),i}function f(e,t){var n=u(e),r=e.read_shift(4),i=e.read_shift(4),a=e.read_shift(2);if(65535==a)return 0===r&&3221225472===i?(n[1].t="e",n[1].v=15):0===r&&3489660928===i?(n[1].t="e",n[1].v=42):n[1].v=0,n;var s=32768&a;return a=(32767&a)-16446,n[1].v=(1-2*s)*(i*Math.pow(2,a+32)+r*Math.pow(2,a)),n}function d(e,t,n,r){var i=ki(14);if(i.write_shift(2,e),i.write_shift(1,n),i.write_shift(1,t),0==r)return i.write_shift(4,0),i.write_shift(4,0),i.write_shift(2,65535),i;var a,s=0,o=0,l=0;return r<0&&(s=1,r=-r),o=0|Math.log2(r),0==(2147483648&(l=(r/=Math.pow(2,o-31))>>>0))&&(++o,l=(r/=2)>>>0),r-=l,l|=2147483648,l>>>=0,a=(r*=Math.pow(2,32))>>>0,i.write_shift(4,a),i.write_shift(4,l),o+=16383+(s?32768:0),i.write_shift(2,o),i}function p(e,t){var n=u(e),r=e.read_shift(8,"f");return n[1].v=r,n}function m(e,t){return 0==e[e.l+t-1]?e.read_shift(t,"cstr"):""}function g(e,t){var n=ki(5+e.length);n.write_shift(2,14e3),n.write_shift(2,t);for(var r=0;r127?95:i}return n[n.l++]=0,n}var v={0:{n:"BOF",f:Ya},1:{n:"EOF"},2:{n:"CALCMODE"},3:{n:"CALCORDER"},4:{n:"SPLIT"},5:{n:"SYNC"},6:{n:"RANGE",f:function(e,t,n){var r={s:{c:0,r:0},e:{c:0,r:0}};return 8==t&&n.qpro?(r.s.c=e.read_shift(1),e.l++,r.s.r=e.read_shift(2),r.e.c=e.read_shift(1),e.l++,r.e.r=e.read_shift(2),r):(r.s.c=e.read_shift(2),r.s.r=e.read_shift(2),12==t&&n.qpro&&(e.l+=2),r.e.c=e.read_shift(2),r.e.r=e.read_shift(2),12==t&&n.qpro&&(e.l+=2),65535==r.s.c&&(r.s.c=r.e.c=r.s.r=r.e.r=0),r)}},7:{n:"WINDOW1"},8:{n:"COLW1"},9:{n:"WINTWO"},10:{n:"COLW2"},11:{n:"NAME"},12:{n:"BLANK"},13:{n:"INTEGER",f:function(e,t,r){var i=n(e,0,r);return i[1].v=e.read_shift(2,"i"),i}},14:{n:"NUMBER",f:function(e,t,r){var i=n(e,0,r);return i[1].v=e.read_shift(8,"f"),i}},15:{n:"LABEL",f:r},16:{n:"FORMULA",f:function(e,t,r){var i=e.l+t,a=n(e,0,r);if(a[1].v=e.read_shift(8,"f"),r.qpro)e.l=i;else{var s=e.read_shift(2);!function(e,t){Ti(e,0);var n=[],r=0,i="",a="",s="",u="";for(;e.ln.length)return void console.error("WK1 bad formula parse 0x"+h.toString(16)+":|"+n.join("|")+"|");var m=n.slice(-r);n.length-=r,n.push(l[h][0]+"("+m.join(",")+")")}}}1==n.length?t[1].f=""+n[0]:console.error("WK1 bad formula parse |"+n.join("|")+"|")}(e.slice(e.l,e.l+s),a),e.l+=s}return a}},24:{n:"TABLE"},25:{n:"ORANGE"},26:{n:"PRANGE"},27:{n:"SRANGE"},28:{n:"FRANGE"},29:{n:"KRANGE1"},32:{n:"HRANGE"},35:{n:"KRANGE2"},36:{n:"PROTEC"},37:{n:"FOOTER"},38:{n:"HEADER"},39:{n:"SETUP"},40:{n:"MARGINS"},41:{n:"LABELFMT"},42:{n:"TITLES"},43:{n:"SHEETJS"},45:{n:"GRAPH"},46:{n:"NGRAPH"},47:{n:"CALCCOUNT"},48:{n:"UNFORMATTED"},49:{n:"CURSORW12"},50:{n:"WINDOW"},51:{n:"STRING",f:r},55:{n:"PASSWORD"},56:{n:"LOCKED"},60:{n:"QUERY"},61:{n:"QUERYNAME"},62:{n:"PRINT"},63:{n:"PRINTNAME"},64:{n:"GRAPH2"},65:{n:"GRAPHNAME"},66:{n:"ZOOM"},67:{n:"SYMSPLIT"},68:{n:"NSROWS"},69:{n:"NSCOLS"},70:{n:"RULER"},71:{n:"NNAME"},72:{n:"ACOMM"},73:{n:"AMACRO"},74:{n:"PARSE"},102:{n:"PRANGES??"},103:{n:"RRANGES??"},104:{n:"FNAME??"},105:{n:"MRANGES??"},204:{n:"SHEETNAMECS",f:m},222:{n:"SHEETNAMELP",f:function(e,t){var n=e[e.l++];n>t-1&&(n=t-1);for(var r="";r.length>1;if(1&n[1].v)switch(7&r){case 0:r=5e3*(r>>3);break;case 1:r=500*(r>>3);break;case 2:r=(r>>3)/20;break;case 3:r=(r>>3)/200;break;case 4:r=(r>>3)/2e3;break;case 5:r=(r>>3)/2e4;break;case 6:r=(r>>3)/16;break;case 7:r=(r>>3)/64}return n[1].v=r,n}},25:{n:"FORMULA19",f:function(e,t){var n=f(e);return e.l+=t-14,n}},26:{n:"FORMULA1A"},27:{n:"XFORMAT",f:function(e,t){for(var n={},r=e.l+t;e.l>6,n}},38:{n:"??"},39:{n:"NUMBER27",f:p},40:{n:"FORMULA28",f:function(e,t){var n=p(e);return e.l+=t-10,n}},142:{n:"??"},147:{n:"??"},150:{n:"??"},151:{n:"??"},152:{n:"??"},153:{n:"??"},154:{n:"??"},155:{n:"??"},156:{n:"??"},163:{n:"??"},174:{n:"??"},175:{n:"??"},176:{n:"??"},177:{n:"??"},184:{n:"??"},185:{n:"??"},186:{n:"??"},187:{n:"??"},188:{n:"??"},195:{n:"??"},201:{n:"??"},204:{n:"SHEETNAMECS",f:m},205:{n:"??"},206:{n:"??"},207:{n:"??"},208:{n:"??"},256:{n:"??"},259:{n:"??"},260:{n:"??"},261:{n:"??"},262:{n:"??"},263:{n:"??"},265:{n:"??"},266:{n:"??"},267:{n:"??"},268:{n:"??"},270:{n:"??"},271:{n:"??"},384:{n:"??"},389:{n:"??"},390:{n:"??"},393:{n:"??"},396:{n:"??"},512:{n:"??"},514:{n:"??"},513:{n:"??"},516:{n:"??"},517:{n:"??"},640:{n:"??"},641:{n:"??"},642:{n:"??"},643:{n:"??"},644:{n:"??"},645:{n:"??"},646:{n:"??"},647:{n:"??"},648:{n:"??"},658:{n:"??"},659:{n:"??"},660:{n:"??"},661:{n:"??"},662:{n:"??"},665:{n:"??"},666:{n:"??"},768:{n:"??"},772:{n:"??"},1537:{n:"SHEETINFOQP",f:function(e,t,n){if(n.qpro&&!(t<21)){var r=e.read_shift(1);return e.l+=17,e.l+=1,e.l+=2,[r,e.read_shift(t-21,"cstr")]}}},1600:{n:"??"},1602:{n:"??"},1793:{n:"??"},1794:{n:"??"},1795:{n:"??"},1796:{n:"??"},1920:{n:"??"},2048:{n:"??"},2049:{n:"??"},2052:{n:"??"},2688:{n:"??"},10998:{n:"??"},12849:{n:"??"},28233:{n:"??"},28484:{n:"??"},65535:{n:""}};return{sheet_to_wk1:function(e,t){var n=t||{};if(+n.codepage>=0&&dt(+n.codepage),"string"==n.type)throw new Error("Cannot write WK1 to JS string");var r=Ci(),o=ji(e["!ref"]),l=Array.isArray(e),c=[];$c(r,0,function(e){var t=ki(2);return t.write_shift(2,e),t}(1030)),$c(r,6,function(e){var t=ki(8);return t.write_shift(2,e.s.c),t.write_shift(2,e.s.r),t.write_shift(2,e.e.c),t.write_shift(2,e.e.r),t}(o));for(var u=Math.min(o.e.r,8191),h=o.s.r;h<=u;++h)for(var f=Di(h),d=o.s.c;d<=o.e.c;++d){h===o.s.r&&(c[d]=Ii(d));var p=c[d]+f,m=l?(e[h]||[])[d]:e[p];if(m&&"z"!=m.t)if("n"==m.t)(0|m.v)==m.v&&m.v>=-32768&&m.v<=32767?$c(r,13,a(h,d,m.v)):$c(r,14,s(h,d,m.v));else $c(r,15,i(h,d,Ui(m).slice(0,239)))}return $c(r,1),r.end()},book_to_wk3:function(e,t){var n=t||{};if(+n.codepage>=0&&dt(+n.codepage),"string"==n.type)throw new Error("Cannot write WK3 to JS string");var r=Ci();$c(r,0,function(e){var t=ki(26);t.write_shift(2,4096),t.write_shift(2,4),t.write_shift(4,0);for(var n=0,r=0,i=0,a=0;a8191&&(n=8191);return t.write_shift(2,n),t.write_shift(1,i),t.write_shift(1,r),t.write_shift(2,0),t.write_shift(2,0),t.write_shift(1,1),t.write_shift(1,2),t.write_shift(4,0),t.write_shift(4,0),t}(e));for(var i=0,a=0;i":case"":t.shadow=1;break;case"":break;case"":case"":t.outline=1;break;case"":break;case"":case"":t.strike=1;break;case"":break;case"":case"":t.u=1;break;case"":break;case"":case"":t.b=1;break;case"":break;case"":case"":t.i=1;break;case"":break;case"":case"":case"":break;case"":case"":case"":break;case"":case"":case"":case"":case"":case"":case"":case"":break;case"":i=!1;break;default:if(47!==a[0].charCodeAt(1)&&!i)throw new Error("Unrecognized rich format "+a[0])}}return t}(a[1])),i}var r=/<(?:\w+:)?r>/g,i=/<\/(?:\w+:)?r>/;return function(e){return e.replace(r,"").split(i).map(n).filter((function(e){return e.v}))}}(),zs=function(){var e=/(\r\n|\n)/g;function t(t){var n=[[],t.v,[]];return t.v?(t.s&&function(e,t,n){var r=[];e.u&&r.push("text-decoration: underline;"),e.uval&&r.push("text-underline-style:"+e.uval+";"),e.sz&&r.push("font-size:"+e.sz+"pt;"),e.outline&&r.push("text-effect: outline;"),e.shadow&&r.push("text-shadow: auto;"),t.push(''),e.b&&(t.push(""),n.push("")),e.i&&(t.push(""),n.push("")),e.strike&&(t.push(""),n.push(""));var i=e.valign||"";"superscript"==i||"super"==i?i="sup":"subscript"==i&&(i="sub"),""!=i&&(t.push("<"+i+">"),n.push(""+i+">")),n.push("")}(t.s,n[0],n[2]),n[0].join("")+n[1].replace(e,"
")+n[2].join("")):""}return function(e){return e.map(t).join("")}}(),Bs=/<(?:\w+:)?t[^>]*>([^<]*)<\/(?:\w+:)?t>/g,js=/<(?:\w+:)?r>/,Vs=/<(?:\w+:)?rPh.*?>([\s\S]*?)<\/(?:\w+:)?rPh>/g;function Us(e,t){var n=!t||t.cellHTML,r={};return e?(e.match(/^\s*<(?:\w+:)?t[^>]*>/)?(r.t=br(Ar(e.slice(e.indexOf(">")+1).split(/<\/(?:\w+:)?t>/)[0]||"")),r.r=Ar(e),n&&(r.h=wr(r.t))):e.match(js)&&(r.r=Ar(e),r.t=br(Ar((e.replace(Vs,"").match(Bs)||[]).join("").replace(hr,""))),n&&(r.h=zs(Fs(r.r)))),r):{t:""}}var Hs=/<(?:\w+:)?sst([^>]*)>([\s\S]*)<\/(?:\w+:)?sst>/,Ws=/<(?:\w+:)?(?:si|sstItem)>/g,$s=/<\/(?:\w+:)?(?:si|sstItem)>/;function Gs(e){if("undefined"!==typeof vt)return vt.utils.encode(ct,e);for(var t=[],n=e.split(""),r=0;r=4&&(e.l+=t-4),n}function Ys(e){for(var t=e.read_shift(4),n=e.l+t-4,r={},i=e.read_shift(4),a=[];i-- >0;)a.push({t:e.read_shift(4),v:e.read_shift(0,"lpp4")});if(r.name=e.read_shift(0,"lpp4"),r.comps=a,e.l!=n)throw new Error("Bad DataSpaceMapEntry: "+e.l+" != "+n);return r}function Xs(e){var t=function(e){var t={};return e.read_shift(4),e.l+=4,t.id=e.read_shift(0,"lpp4"),t.name=e.read_shift(0,"lpp4"),t.R=Ks(e,4),t.U=Ks(e,4),t.W=Ks(e,4),t}(e);if(t.ename=e.read_shift(0,"8lpp4"),t.blksz=e.read_shift(4),t.cmode=e.read_shift(4),4!=e.read_shift(4))throw new Error("Bad !Primary record");return t}function qs(e,t){var n=e.l+t,r={};r.Flags=63&e.read_shift(4),e.l+=4,r.AlgID=e.read_shift(4);var i=!1;switch(r.AlgID){case 26126:case 26127:case 26128:i=36==r.Flags;break;case 26625:i=4==r.Flags;break;case 0:i=16==r.Flags||4==r.Flags||36==r.Flags;break;default:throw"Unrecognized encryption algorithm: "+r.AlgID}if(!i)throw new Error("Encryption Flags/AlgID mismatch");return r.AlgIDHash=e.read_shift(4),r.KeySize=e.read_shift(4),r.ProviderType=e.read_shift(4),e.l+=8,r.CSPName=e.read_shift(n-e.l>>1,"utf16le"),e.l=n,r}function Zs(e,t){var n={},r=e.l+t;return e.l+=4,n.Salt=e.slice(e.l,e.l+16),e.l+=16,n.Verifier=e.slice(e.l,e.l+16),e.l+=16,e.read_shift(4),n.VerifierHash=e.slice(e.l,r),e.l=r,n}function Qs(e){if(36!=(63&e.read_shift(4)))throw new Error("EncryptionInfo mismatch");var t=e.read_shift(4);return{t:"Std",h:qs(e,t),v:Zs(e,e.length-e.l)}}function Js(){throw new Error("File is password-protected: ECMA-376 Extensible")}function eo(e){var t=["saltSize","blockSize","keyBits","hashSize","cipherAlgorithm","cipherChaining","hashAlgorithm","saltValue"];e.l+=4;var n=e.read_shift(e.length-e.l,"utf8"),r={};return n.replace(hr,(function(e){var n=pr(e);switch(mr(n[0])){case"":case"":case"":break;case"":case"=0;--n)r=((0===(16384&r)?0:1)|r<<1&32767)^t[n];return 52811^r}var no=function(){var e=[187,255,255,186,255,255,185,128,0,190,15,0,191,15,0],t=[57840,7439,52380,33984,4364,3600,61902,12606,6258,57657,54287,34041,10252,43370,20163],n=[44796,19929,39858,10053,20106,40212,10761,31585,63170,64933,60267,50935,40399,11199,17763,35526,1453,2906,5812,11624,23248,885,1770,3540,7080,14160,28320,56640,55369,41139,20807,41614,21821,43642,17621,28485,56970,44341,19019,38038,14605,29210,60195,50791,40175,10751,21502,43004,24537,18387,36774,3949,7898,15796,31592,63184,47201,24803,49606,37805,14203,28406,56812,17824,35648,1697,3394,6788,13576,27152,43601,17539,35078,557,1114,2228,4456,30388,60776,51953,34243,7079,14158,28316,14128,28256,56512,43425,17251,34502,7597,13105,26210,52420,35241,883,1766,3532,4129,8258,16516,33032,4657,9314,18628],r=function(e,t){return 255&((n=e^t)/2|128*n);var n};return function(i){for(var a,s,o,l=Gs(i),c=function(e){for(var r=t[e.length-1],i=104,a=e.length-1;a>=0;--a)for(var s=e[a],o=0;7!=o;++o)64&s&&(r^=n[i]),s*=2,--i;return r}(l),u=l.length,h=Ct(16),f=0;16!=f;++f)h[f]=0;for(1===(1&u)&&(a=c>>8,h[u]=r(e[0],a),--u,a=255&c,s=l[l.length-1],h[u]=r(s,a));u>0;)a=c>>8,h[--u]=r(l[u],a),a=255&c,h[--u]=r(l[u],a);for(u=15,o=15-l.length;o>0;)a=c>>8,h[u]=r(e[o],a),--o,a=255&c,h[--u]=r(l[u],a),--u,--o;return h}}(),ro=function(e){var t=0,n=no(e);return function(e){var r=function(e,t,n,r,i){var a,s;for(i||(i=t),r||(r=no(e)),a=0;a!=t.length;++a)s=t[a],s=255&((s^=r[n])>>5|s<<3),i[a]=s,++n;return[i,n,r]}("",e,t,n);return t=r[1],r[0]}};function io(e,t,n){var r=n||{};return r.Info=e.read_shift(2),e.l-=2,1===r.Info?r.Data=function(e){var t={},n=t.EncryptionVersionInfo=Ks(e,4);if(1!=n.Major||1!=n.Minor)throw"unrecognized version code "+n.Major+" : "+n.Minor;return t.Salt=e.read_shift(16),t.EncryptedVerifier=e.read_shift(16),t.EncryptedVerifierHash=e.read_shift(16),t}(e):r.Data=function(e,t){var n={},r=n.EncryptionVersionInfo=Ks(e,4);if(t-=4,2!=r.Minor)throw new Error("unrecognized minor version code: "+r.Minor);if(r.Major>4||r.Major<2)throw new Error("unrecognized major version code: "+r.Major);n.Flags=e.read_shift(4),t-=4;var i=e.read_shift(4);return t-=4,n.EncryptionHeader=qs(e,i),t-=i,n.EncryptionVerifier=Zs(e,t),n}(e,t),r}var ao=function(){function e(e,n){switch(n.type){case"base64":return t(Et(e),n);case"binary":return t(e,n);case"buffer":return t(kt&&Buffer.isBuffer(e)?e.toString("binary"):Pt(e),n);case"array":return t(Wn(e),n)}throw new Error("Unrecognized type "+n.type)}function t(e,t){var n=(t||{}).dense?[]:{},r=e.match(/\\trowd.*?\\row\b/g);if(!r.length)throw new Error("RTF missing table");var i={s:{c:0,r:0},e:{c:0,r:r.length-1}};return r.forEach((function(e,t){Array.isArray(n)&&(n[t]=[]);for(var r,a=/\\\w+\b/g,s=0,o=-1;r=a.exec(e);){if("\\cell"===r[0]){var l=e.slice(s,a.lastIndex-r[0].length);if(" "==l[0]&&(l=l.slice(1)),++o,l.length){var c={v:l,t:"s"};Array.isArray(n)?n[t][o]=c:n[Fi({r:t,c:o})]=c}}s=a.lastIndex}o>i.e.c&&(i.e.c=o)})),n["!ref"]=Bi(i),n}return{to_workbook:function(t,n){return Hi(e(t,n),n)},to_sheet:e,from_sheet:function(e){for(var t,n=["{\\rtf1\\ansi"],r=ji(e["!ref"]),i=Array.isArray(e),a=r.s.r;a<=r.e.r;++a){n.push("\\trowd\\trautofit1");for(var s=r.s.c;s<=r.e.c;++s)n.push("\\cellx"+(s+1));for(n.push("\\pard\\intbl"),s=r.s.c;s<=r.e.c;++s){var o=Fi({r:a,c:s});(t=i?(e[a]||[])[s]:e[o])&&(null!=t.v||t.f&&!t.F)&&(n.push(" "+(t.w||(Ui(t),t.w))),n.push("\\cell"))}n.push("\\pard\\intbl\\row")}return n.join("")+"}"}}}();function so(e){for(var t=0,n=1;3!=t;++t)n=256*n+(e[t]>255?255:e[t]<0?0:e[t]);return n.toString(16).toUpperCase().slice(1)}function oo(e,t){if(0===t)return e;var n=function(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.max(t,n,r),a=Math.min(t,n,r),s=i-a;if(0===s)return[0,0,t];var o,l=0,c=i+a;switch(o=s/(c>1?2-c:c),i){case t:l=((n-r)/s+6)%6;break;case n:l=(r-t)/s+2;break;case r:l=(t-n)/s+4}return[l/6,o,c/2]}(function(e){var t=e.slice("#"===e[0]?1:0).slice(0,6);return[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16)]}(e));return n[2]=t<0?n[2]*(1+t):1-(1-n[2])*(1-t),so(function(e){var t,n=e[0],r=e[1],i=e[2],a=2*r*(i<.5?i:1-i),s=i-a/2,o=[s,s,s],l=6*n;if(0!==r)switch(0|l){case 0:case 6:t=a*l,o[0]+=a,o[1]+=t;break;case 1:t=a*(2-l),o[0]+=t,o[1]+=a;break;case 2:t=a*(l-2),o[1]+=a,o[2]+=t;break;case 3:t=a*(4-l),o[1]+=t,o[2]+=a;break;case 4:t=a*(l-4),o[2]+=a,o[0]+=t;break;case 5:t=a*(6-l),o[2]+=t,o[0]+=a}for(var c=0;3!=c;++c)o[c]=Math.round(255*o[c]);return o}(n))}var lo=6,co=15,uo=1,ho=lo;function fo(e){return Math.floor((e+Math.round(128/ho)/256)*ho)}function po(e){return Math.floor((e-5)/ho*100+.5)/100}function mo(e){return Math.round((e*ho+5)/ho*256)/256}function go(e){return mo(po(fo(e)))}function vo(e){var t=Math.abs(e-go(e)),n=ho;if(t>.005)for(ho=uo;ho]*)>[\S\s]*?<\/(?:\w+:)?numFmts>/,t=/<(?:\w+:)?cellXfs([^>]*)>[\S\s]*?<\/(?:\w+:)?cellXfs>/,n=/<(?:\w+:)?fills([^>]*)>[\S\s]*?<\/(?:\w+:)?fills>/,r=/<(?:\w+:)?fonts([^>]*)>[\S\s]*?<\/(?:\w+:)?fonts>/,i=/<(?:\w+:)?borders([^>]*)>[\S\s]*?<\/(?:\w+:)?borders>/;return function(a,s,o){var l,c={};return a?((l=(a=a.replace(//gm,"").replace(//gm,"")).match(e))&&function(e,t,n){t.NumberFmt=[];for(var r=On(Wt),i=0;i":case"":case"":case"":break;case"0){if(l>392){for(l=392;l>60&&null!=t.NumberFmt[l];--l);t.NumberFmt[l]=o}En(o,l)}break;default:if(n.WTF)throw new Error("unrecognized "+s[0]+" in numFmts")}}}(l,c,o),(l=a.match(r))&&function(e,t,n,r){t.Fonts=[];var i={},a=!1;(e[0].match(hr)||[]).forEach((function(e){var s=pr(e);switch(mr(s[0])){case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":break;case"":case"":t.Fonts.push(i),i={};break;case"":i.bold=1;break;case"":i.italic=1;break;case"":i.underline=1;break;case"":i.strike=1;break;case"":i.outline=1;break;case"":i.shadow=1;break;case"":i.condense=1;break;case"":i.extend=1;break;case"":case"":a=!1;break;default:if(r&&r.WTF&&!a)throw new Error("unrecognized "+s[0]+" in fonts")}}))}(l,c,s,o),(l=a.match(n))&&function(e,t,n,r){t.Fills=[];var i={},a=!1;(e[0].match(hr)||[]).forEach((function(e){var n=pr(e);switch(mr(n[0])){case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":break;case"":case"":i={},t.Fills.push(i);break;case"":t.Fills.push(i),i={};break;case"":n.patternType&&(i.patternType=n.patternType);break;case"":a=!1;break;default:if(r&&r.WTF&&!a)throw new Error("unrecognized "+n[0]+" in fills")}}))}(l,c,0,o),(l=a.match(i))&&function(e,t,n,r){t.Borders=[];var i={},a=!1;(e[0].match(hr)||[]).forEach((function(e){var n=pr(e);switch(mr(n[0])){case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":break;case"":case"":i={},n.diagonalUp&&(i.diagonalUp=Tr(n.diagonalUp)),n.diagonalDown&&(i.diagonalDown=Tr(n.diagonalDown)),t.Borders.push(i);break;case"":a=!1;break;default:if(r&&r.WTF&&!a)throw new Error("unrecognized "+n[0]+" in borders")}}))}(l,c,0,o),(l=a.match(t))&&function(e,t,n){var r;t.CellXf=[];var i=!1;(e[0].match(hr)||[]).forEach((function(e){var a=pr(e),s=0;switch(mr(a[0])){case"":case"":case"":case"":case"":case"":case"":case"":case"":break;case"":for(delete(r=a)[0],s=0;s392)for(s=392;s>60;--s)if(t.NumberFmt[r.numFmtId]==t.NumberFmt[s]){r.numFmtId=s;break}t.CellXf.push(r);break;case"":var o={};a.vertical&&(o.vertical=a.vertical),a.horizontal&&(o.horizontal=a.horizontal),null!=a.textRotation&&(o.textRotation=a.textRotation),a.indent&&(o.indent=a.indent),a.wrapText&&(o.wrapText=Tr(a.wrapText)),r.alignment=o;break;case"":case"":i=!1;break;default:if(n&&n.WTF&&!i)throw new Error("unrecognized "+a[0]+" in cellXfs")}}))}(l,c,o),c):c}}();var So=Ei;var Co=Ei;var Ao=["","","","","","","","","","","",""];function Mo(e,t,n){t.themeElements.clrScheme=[];var r={};(e[0].match(hr)||[]).forEach((function(e){var i=pr(e);switch(i[0]){case"":break;case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":"/"===i[0].charAt(1)?(t.themeElements.clrScheme[Ao.indexOf(i[0])]=r,r={}):r.name=i[0].slice(3,i[0].length-1);break;default:if(n&&n.WTF)throw new Error("Unrecognized "+i[0]+" in clrScheme")}}))}function Po(){}function Oo(){}var Ro=/]*)>[\s\S]*<\/a:clrScheme>/,Do=/]*)>[\s\S]*<\/a:fontScheme>/,Lo=/]*)>[\s\S]*<\/a:fmtScheme>/;var Io=/]*)>[\s\S]*<\/a:themeElements>/;function No(e,t){var n;e&&0!==e.length||(e=Fo());var r={};if(!(n=e.match(Io)))throw new Error("themeElements not found in theme");return function(e,t,n){var r;t.themeElements={},[["clrScheme",Ro,Mo],["fontScheme",Do,Po],["fmtScheme",Lo,Oo]].forEach((function(i){if(!(r=e.match(i[1])))throw new Error(i[0]+" not found in themeElements");i[2](r,t,n)}))}(n[0],r,t),r.raw=e,r}function Fo(e,t){if(t&&t.themeXLSX)return t.themeXLSX;if(e&&"string"==typeof e.raw)return e.raw;var n=[lr];return n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]='',n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]='',n[n.length]="",n[n.length]="",n[n.length]="",n[n.length]="",n.join("")}function zo(e){var t={};switch(t.xclrType=e.read_shift(2),t.nTintShade=e.read_shift(2),t.xclrType){case 0:case 4:e.l+=4;break;case 1:t.xclrValue=function(e,t){return Ei(e,t)}(e,4);break;case 2:t.xclrValue=rs(e);break;case 3:t.xclrValue=function(e){return e.read_shift(4)}(e)}return e.l+=8,t}function Bo(e){var t=e.read_shift(2),n=e.read_shift(2)-4,r=[t];switch(t){case 4:case 5:case 7:case 8:case 9:case 10:case 11:case 13:r[1]=zo(e);break;case 6:r[1]=function(e,t){return Ei(e,t)}(e,n);break;case 14:case 15:r[1]=e.read_shift(1===n?1:2);break;default:throw new Error("Unrecognized ExtProp type: "+t+" "+n)}return r}function jo(e,t,n,r){var i,a=Array.isArray(e);t.forEach((function(t){var s=Ni(t.ref);if(a?(e[s.r]||(e[s.r]=[]),i=e[s.r][s.c]):i=e[t.ref],!i){i={t:"z"},a?e[s.r][s.c]=i:e[t.ref]=i;var o=ji(e["!ref"]||"BDWGO1000001:A1");o.s.r>s.r&&(o.s.r=s.r),o.e.rs.c&&(o.s.c=s.c),o.e.c=0;--u){if(!n&&i.c[u].T)return;n&&!i.c[u].T&&i.c.splice(u,1)}if(n&&r)for(u=0;u0?0|parseInt(r,10):0,l=i.length>0?0|parseInt(i,10):0;return a?l+=t.c:--l,s?o+=t.r:--o,n+(a?"":"$")+Ii(l)+(s?"":"$")+Di(o)}return function(r,i){return t=i,r.replace(e,n)}}(),Wo=/(^|[^._A-Z0-9])([$]?)([A-Z]{1,2}|[A-W][A-Z]{2}|X[A-E][A-Z]|XF[A-D])([$]?)(10[0-3]\d{4}|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})(?![_.\(A-Za-z0-9])/g,$o=function(){return function(e,t){return e.replace(Wo,(function(e,n,r,i,a,s){var o=Li(i)-(r?0:t.c),l=Ri(s)-(a?0:t.r);return n+"R"+(0==l?"":a?l+1:"["+l+"]")+"C"+(0==o?"":r?o+1:"["+o+"]")}))}}();function Go(e,t){return e.replace(Wo,(function(e,n,r,i,a,s){return n+("$"==r?r+i:Ii(Li(i)+t.c))+("$"==a?a+s:Di(Ri(s)+t.r))}))}function Ko(e,t,n){var r=zi(t).s,i=Ni(n);return Go(e,{r:i.r-r.r,c:i.c-r.c})}function Yo(e){return e.replace(/_xlfn\./g,"")}function Xo(e){e.l+=1}function qo(e,t){var n=e.read_shift(1==t?1:2);return[16383&n,n>>14&1,n>>15&1]}function Zo(e,t,n){var r=2;if(n){if(n.biff>=2&&n.biff<=5)return Qo(e);12==n.biff&&(r=4)}var i=e.read_shift(r),a=e.read_shift(r),s=qo(e,2),o=qo(e,2);return{s:{r:i,c:s[0],cRel:s[1],rRel:s[2]},e:{r:a,c:o[0],cRel:o[1],rRel:o[2]}}}function Qo(e){var t=qo(e,2),n=qo(e,2),r=e.read_shift(1),i=e.read_shift(1);return{s:{r:t[0],c:r,cRel:t[1],rRel:t[2]},e:{r:n[0],c:i,cRel:n[1],rRel:n[2]}}}function Jo(e,t,n){if(n&&n.biff>=2&&n.biff<=5)return function(e){var t=qo(e,2),n=e.read_shift(1);return{r:t[0],c:n,cRel:t[1],rRel:t[2]}}(e);var r=e.read_shift(n&&12==n.biff?4:2),i=qo(e,2);return{r:r,c:i[0],cRel:i[1],rRel:i[2]}}function el(e){var t=e.read_shift(2),n=e.read_shift(2);return{r:t,c:255&n,fQuoted:!!(16384&n),cRel:n>>15,rRel:n>>15}}function tl(e){var t=1&e[e.l+1];return e.l+=4,[t,1]}function nl(e){return[e.read_shift(1),e.read_shift(1)]}function rl(e,t){var n=[e.read_shift(1)];if(12==t)switch(n[0]){case 2:n[0]=4;break;case 4:n[0]=16;break;case 0:n[0]=1;break;case 1:n[0]=2}switch(n[0]){case 4:n[1]=Ka(e,1)?"TRUE":"FALSE",12!=t&&(e.l+=7);break;case 37:case 16:n[1]=ya[e[e.l]],e.l+=12==t?4:8;break;case 0:e.l+=8;break;case 1:n[1]=aa(e);break;case 2:n[1]=es(e,0,{biff:t>0&&t<8?2:t});break;default:throw new Error("Bad SerAr: "+n[0])}return n}function il(e,t,n){for(var r=e.read_shift(12==n.biff?4:2),i=[],a=0;a!=r;++a)i.push((12==n.biff?ia:ls)(e,8));return i}function al(e,t,n){var r=0,i=0;12==n.biff?(r=e.read_shift(4),i=e.read_shift(4)):(i=1+e.read_shift(1),r=1+e.read_shift(2)),n.biff>=2&&n.biff<8&&(--r,0==--i&&(i=256));for(var a=0,s=[];a!=r&&(s[a]=[]);++a)for(var o=0;o!=i;++o)s[a][o]=rl(e,n.biff);return s}function sl(e,t,n){return e.l+=2,[el(e)]}function ol(e){return e.l+=6,[]}function ll(e){return e.l+=2,[Ya(e),1&e.read_shift(2)]}var cl=["Data","All","Headers","??","?Data2","??","?DataHeaders","??","Totals","??","??","??","?DataTotals","??","??","??","?Current"];var ul={1:{n:"PtgExp",f:function(e,t,n){return e.l++,n&&12==n.biff?[e.read_shift(4,"i"),0]:[e.read_shift(2),e.read_shift(n&&2==n.biff?1:2)]}},2:{n:"PtgTbl",f:Ei},3:{n:"PtgAdd",f:Xo},4:{n:"PtgSub",f:Xo},5:{n:"PtgMul",f:Xo},6:{n:"PtgDiv",f:Xo},7:{n:"PtgPower",f:Xo},8:{n:"PtgConcat",f:Xo},9:{n:"PtgLt",f:Xo},10:{n:"PtgLe",f:Xo},11:{n:"PtgEq",f:Xo},12:{n:"PtgGe",f:Xo},13:{n:"PtgGt",f:Xo},14:{n:"PtgNe",f:Xo},15:{n:"PtgIsect",f:Xo},16:{n:"PtgUnion",f:Xo},17:{n:"PtgRange",f:Xo},18:{n:"PtgUplus",f:Xo},19:{n:"PtgUminus",f:Xo},20:{n:"PtgPercent",f:Xo},21:{n:"PtgParen",f:Xo},22:{n:"PtgMissArg",f:Xo},23:{n:"PtgStr",f:function(e,t,n){return e.l++,qa(e,0,n)}},26:{n:"PtgSheet",f:function(e,t,n){return e.l+=5,e.l+=2,e.l+=2==n.biff?1:4,["PTGSHEET"]}},27:{n:"PtgEndSheet",f:function(e,t,n){return e.l+=2==n.biff?4:5,["PTGENDSHEET"]}},28:{n:"PtgErr",f:function(e){return e.l++,ya[e.read_shift(1)]}},29:{n:"PtgBool",f:function(e){return e.l++,0!==e.read_shift(1)}},30:{n:"PtgInt",f:function(e){return e.l++,e.read_shift(2)}},31:{n:"PtgNum",f:function(e){return e.l++,aa(e)}},32:{n:"PtgArray",f:function(e,t,n){var r=(96&e[e.l++])>>5;return e.l+=2==n.biff?6:12==n.biff?14:7,[r]}},33:{n:"PtgFunc",f:function(e,t,n){var r=(96&e[e.l])>>5;e.l+=1;var i=e.read_shift(n&&n.biff<=3?1:2);return[Ol[i],Pl[i],r]}},34:{n:"PtgFuncVar",f:function(e,t,n){var r=e[e.l++],i=e.read_shift(1),a=n&&n.biff<=3?[88==r?-1:0,e.read_shift(1)]:function(e){return[e[e.l+1]>>7,32767&e.read_shift(2)]}(e);return[i,(0===a[0]?Pl:Ml)[a[1]]]}},35:{n:"PtgName",f:function(e,t,n){var r=e.read_shift(1)>>>5&3,i=!n||n.biff>=8?4:2,a=e.read_shift(i);switch(n.biff){case 2:e.l+=5;break;case 3:case 4:e.l+=8;break;case 5:e.l+=12}return[r,0,a]}},36:{n:"PtgRef",f:function(e,t,n){var r=(96&e[e.l])>>5;return e.l+=1,[r,Jo(e,0,n)]}},37:{n:"PtgArea",f:function(e,t,n){return[(96&e[e.l++])>>5,Zo(e,n.biff>=2&&n.biff,n)]}},38:{n:"PtgMemArea",f:function(e,t,n){var r=e.read_shift(1)>>>5&3;return e.l+=n&&2==n.biff?3:4,[r,e.read_shift(n&&2==n.biff?1:2)]}},39:{n:"PtgMemErr",f:Ei},40:{n:"PtgMemNoMem",f:Ei},41:{n:"PtgMemFunc",f:function(e,t,n){return[e.read_shift(1)>>>5&3,e.read_shift(n&&2==n.biff?1:2)]}},42:{n:"PtgRefErr",f:function(e,t,n){var r=e.read_shift(1)>>>5&3;return e.l+=4,n.biff<8&&e.l--,12==n.biff&&(e.l+=2),[r]}},43:{n:"PtgAreaErr",f:function(e,t,n){var r=(96&e[e.l++])>>5;return e.l+=n&&n.biff>8?12:n.biff<8?6:8,[r]}},44:{n:"PtgRefN",f:function(e,t,n){var r=(96&e[e.l])>>5;e.l+=1;var i=function(e,t,n){var r=n&&n.biff?n.biff:8;if(r>=2&&r<=5)return function(e){var t=e.read_shift(2),n=e.read_shift(1),r=(32768&t)>>15,i=(16384&t)>>14;return t&=16383,1==r&&t>=8192&&(t-=16384),1==i&&n>=128&&(n-=256),{r:t,c:n,cRel:i,rRel:r}}(e);var i=e.read_shift(r>=12?4:2),a=e.read_shift(2),s=(16384&a)>>14,o=(32768&a)>>15;if(a&=16383,1==o)for(;i>524287;)i-=1048576;if(1==s)for(;a>8191;)a-=16384;return{r:i,c:a,cRel:s,rRel:o}}(e,0,n);return[r,i]}},45:{n:"PtgAreaN",f:function(e,t,n){var r=(96&e[e.l++])>>5,i=function(e,t,n){if(n.biff<8)return Qo(e);var r=e.read_shift(12==n.biff?4:2),i=e.read_shift(12==n.biff?4:2),a=qo(e,2),s=qo(e,2);return{s:{r:r,c:a[0],cRel:a[1],rRel:a[2]},e:{r:i,c:s[0],cRel:s[1],rRel:s[2]}}}(e,0,n);return[r,i]}},46:{n:"PtgMemAreaN",f:function(e){return[e.read_shift(1)>>>5&3,e.read_shift(2)]}},47:{n:"PtgMemNoMemN",f:function(e){return[e.read_shift(1)>>>5&3,e.read_shift(2)]}},57:{n:"PtgNameX",f:function(e,t,n){return 5==n.biff?function(e){var t=e.read_shift(1)>>>5&3,n=e.read_shift(2,"i");e.l+=8;var r=e.read_shift(2);return e.l+=12,[t,n,r]}(e):[e.read_shift(1)>>>5&3,e.read_shift(2),e.read_shift(4)]}},58:{n:"PtgRef3d",f:function(e,t,n){var r=(96&e[e.l])>>5;e.l+=1;var i=e.read_shift(2);return n&&5==n.biff&&(e.l+=12),[r,i,Jo(e,0,n)]}},59:{n:"PtgArea3d",f:function(e,t,n){var r=(96&e[e.l++])>>5,i=e.read_shift(2,"i");if(n)switch(n.biff){case 5:e.l+=12,6;break;case 12:12}return[r,i,Zo(e,0,n)]}},60:{n:"PtgRefErr3d",f:function(e,t,n){var r=(96&e[e.l++])>>5,i=e.read_shift(2),a=4;if(n)switch(n.biff){case 5:a=15;break;case 12:a=6}return e.l+=a,[r,i]}},61:{n:"PtgAreaErr3d",f:function(e,t,n){var r=(96&e[e.l++])>>5,i=e.read_shift(2),a=8;if(n)switch(n.biff){case 5:e.l+=12,a=6;break;case 12:a=12}return e.l+=a,[r,i]}},255:{}},hl={64:32,96:32,65:33,97:33,66:34,98:34,67:35,99:35,68:36,100:36,69:37,101:37,70:38,102:38,71:39,103:39,72:40,104:40,73:41,105:41,74:42,106:42,75:43,107:43,76:44,108:44,77:45,109:45,78:46,110:46,79:47,111:47,88:34,120:34,89:57,121:57,90:58,122:58,91:59,123:59,92:60,124:60,93:61,125:61},fl={1:{n:"PtgElfLel",f:ll},2:{n:"PtgElfRw",f:sl},3:{n:"PtgElfCol",f:sl},6:{n:"PtgElfRwV",f:sl},7:{n:"PtgElfColV",f:sl},10:{n:"PtgElfRadical",f:sl},11:{n:"PtgElfRadicalS",f:ol},13:{n:"PtgElfColS",f:ol},15:{n:"PtgElfColSV",f:ol},16:{n:"PtgElfRadicalLel",f:ll},25:{n:"PtgList",f:function(e){e.l+=2;var t=e.read_shift(2),n=e.read_shift(2),r=e.read_shift(4),i=e.read_shift(2),a=e.read_shift(2);return{ixti:t,coltype:3&n,rt:cl[n>>2&31],idx:r,c:i,C:a}}},29:{n:"PtgSxName",f:function(e){return e.l+=2,[e.read_shift(4)]}},255:{}},dl={0:{n:"PtgAttrNoop",f:function(e){return e.l+=4,[0,0]}},1:{n:"PtgAttrSemi",f:function(e,t,n){var r=255&e[e.l+1]?1:0;return e.l+=n&&2==n.biff?3:4,[r]}},2:{n:"PtgAttrIf",f:function(e,t,n){var r=255&e[e.l+1]?1:0;return e.l+=2,[r,e.read_shift(n&&2==n.biff?1:2)]}},4:{n:"PtgAttrChoose",f:function(e,t,n){e.l+=2;for(var r=e.read_shift(n&&2==n.biff?1:2),i=[],a=0;a<=r;++a)i.push(e.read_shift(n&&2==n.biff?1:2));return i}},8:{n:"PtgAttrGoto",f:function(e,t,n){var r=255&e[e.l+1]?1:0;return e.l+=2,[r,e.read_shift(n&&2==n.biff?1:2)]}},16:{n:"PtgAttrSum",f:function(e,t,n){e.l+=n&&2==n.biff?3:4}},32:{n:"PtgAttrBaxcel",f:tl},33:{n:"PtgAttrBaxcel",f:tl},64:{n:"PtgAttrSpace",f:function(e){return e.read_shift(2),nl(e)}},65:{n:"PtgAttrSpaceSemi",f:function(e){return e.read_shift(2),nl(e)}},128:{n:"PtgAttrIfError",f:function(e){var t=255&e[e.l+1]?1:0;return e.l+=2,[t,e.read_shift(2)]}},255:{}};function pl(e,t,n,r){if(r.biff<8)return Ei(e,t);for(var i=e.l+t,a=[],s=0;s!==n.length;++s)switch(n[s][0]){case"PtgArray":n[s][1]=al(e,0,r),a.push(n[s][1]);break;case"PtgMemArea":n[s][2]=il(e,n[s][1],r),a.push(n[s][2]);break;case"PtgExp":r&&12==r.biff&&(n[s][1][1]=e.read_shift(4),a.push(n[s][1]));break;case"PtgList":case"PtgElfRadicalS":case"PtgElfColS":case"PtgElfColSV":throw"Unsupported "+n[s][0]}return 0!==(t=i-e.l)&&a.push(Ei(e,t)),a}function ml(e,t,n){for(var r,i,a=e.l+t,s=[];a!=e.l;)t=a-e.l,i=e[e.l],r=ul[i]||ul[hl[i]],24!==i&&25!==i||(r=(24===i?fl:dl)[e[e.l+1]]),r&&r.f?s.push([r.n,r.f(e,t,n)]):Ei(e,t);return s}function gl(e){for(var t=[],n=0;n=",PtgGt:">",PtgLe:"<=",PtgLt:"<",PtgMul:"*",PtgNe:"<>",PtgPower:"^",PtgSub:"-"};function bl(e,t,n){if(!e)return"SH33TJSERR0";if(n.biff>8&&(!e.XTI||!e.XTI[t]))return e.SheetNames[t];if(!e.XTI)return"SH33TJSERR6";var r=e.XTI[t];if(n.biff<8)return t>1e4&&(t-=65536),t<0&&(t=-t),0==t?"":e.XTI[t-1];if(!r)return"SH33TJSERR1";var i="";if(n.biff>8)switch(e[r[0]][0]){case 357:return i=-1==r[1]?"#REF":e.SheetNames[r[1]],r[1]==r[2]?i:i+":"+e.SheetNames[r[2]];case 358:return null!=n.SID?e.SheetNames[n.SID]:"SH33TJSSAME"+e[r[0]][0];default:return"SH33TJSSRC"+e[r[0]][0]}switch(e[r[0]][0][0]){case 1025:return i=-1==r[1]?"#REF":e.SheetNames[r[1]]||"SH33TJSERR3",r[1]==r[2]?i:i+":"+e.SheetNames[r[2]];case 14849:return e[r[0]].slice(1).map((function(e){return e.Name})).join(";;");default:return e[r[0]][0][3]?(i=-1==r[1]?"#REF":e[r[0]][0][3][r[1]]||"SH33TJSERR4",r[1]==r[2]?i:i+":"+e[r[0]][0][3][r[2]]):"SH33TJSERR2"}}function yl(e,t,n){var r=bl(e,t,n);return"#REF"==r?r:function(e,t){if(!e&&!(t&&t.biff<=5&&t.biff>=2))throw new Error("empty sheet name");return/[^\w\u4E00-\u9FFF\u3040-\u30FF]/.test(e)?"'"+e+"'":e}(r,n)}function xl(e,t,n,r,i){var a,s,o,l,c=i&&i.biff||8,u={s:{c:0,r:0},e:{c:0,r:0}},h=[],f=0,d=0,p="";if(!e[0]||!e[0][0])return"";for(var m=-1,g="",v=0,b=e[0].length;v=0){switch(e[0][m][1][0]){case 0:g=Gn(" ",e[0][m][1][1]);break;case 1:g=Gn("\r",e[0][m][1][1]);break;default:if(g="",i.WTF)throw new Error("Unexpected PtgAttrSpaceType "+e[0][m][1][0])}s+=g,m=-1}h.push(s+vl[y[0]]+a);break;case"PtgIsect":a=h.pop(),s=h.pop(),h.push(s+" "+a);break;case"PtgUnion":a=h.pop(),s=h.pop(),h.push(s+","+a);break;case"PtgRange":a=h.pop(),s=h.pop(),h.push(s+":"+a);break;case"PtgAttrChoose":case"PtgAttrGoto":case"PtgAttrIf":case"PtgAttrIfError":case"PtgAttrBaxcel":case"PtgAttrSemi":case"PtgMemArea":case"PtgTbl":case"PtgMemErr":case"PtgMemAreaN":case"PtgMemNoMemN":case"PtgAttrNoop":case"PtgSheet":case"PtgEndSheet":case"PtgMemFunc":case"PtgMemNoMem":break;case"PtgRef":o=Ai(y[1][1],u,i),h.push(Pi(o,c));break;case"PtgRefN":o=n?Ai(y[1][1],n,i):y[1][1],h.push(Pi(o,c));break;case"PtgRef3d":f=y[1][1],o=Ai(y[1][2],u,i);p=yl(r,f,i);h.push(p+"!"+Pi(o,c));break;case"PtgFunc":case"PtgFuncVar":var x=y[1][0],w=y[1][1];x||(x=0);var _=0==(x&=127)?[]:h.slice(-x);h.length-=x,"User"===w&&(w=_.shift()),h.push(w+"("+_.join(",")+")");break;case"PtgBool":h.push(y[1]?"TRUE":"FALSE");break;case"PtgInt":case"PtgErr":h.push(y[1]);break;case"PtgNum":h.push(String(y[1]));break;case"PtgStr":h.push('"'+y[1].replace(/"/g,'""')+'"');break;case"PtgAreaN":l=Mi(y[1][1],n?{s:n}:u,i),h.push(Oi(l,i));break;case"PtgArea":l=Mi(y[1][1],u,i),h.push(Oi(l,i));break;case"PtgArea3d":f=y[1][1],l=y[1][2],p=yl(r,f,i),h.push(p+"!"+Oi(l,i));break;case"PtgAttrSum":h.push("SUM("+h.pop()+")");break;case"PtgName":d=y[1][2];var T=(r.names||[])[d-1]||(r[0]||[])[d],E=T?T.Name:"SH33TJSNAME"+String(d);E&&"_xlfn."==E.slice(0,6)&&!i.xlfn&&(E=E.slice(6)),h.push(E);break;case"PtgNameX":var k,S=y[1][1];if(d=y[1][2],!(i.biff<=5)){var C="";if(14849==((r[S]||[])[0]||[])[0]||(1025==((r[S]||[])[0]||[])[0]?r[S][d]&&r[S][d].itab>0&&(C=r.SheetNames[r[S][d].itab-1]+"!"):C=r.SheetNames[d-1]+"!"),r[S]&&r[S][d])C+=r[S][d].Name;else if(r[0]&&r[0][d])C+=r[0][d].Name;else{var A=(bl(r,S,i)||"").split(";;");A[d-1]?C=A[d-1]:C+="SH33TJSERRX"}h.push(C);break}S<0&&(S=-S),r[S]&&(k=r[S][d]),k||(k={Name:"SH33TJSERRY"}),h.push(k.Name);break;case"PtgParen":var M="(",P=")";if(m>=0){switch(g="",e[0][m][1][0]){case 2:M=Gn(" ",e[0][m][1][1])+M;break;case 3:M=Gn("\r",e[0][m][1][1])+M;break;case 4:P=Gn(" ",e[0][m][1][1])+P;break;case 5:P=Gn("\r",e[0][m][1][1])+P;break;default:if(i.WTF)throw new Error("Unexpected PtgAttrSpaceType "+e[0][m][1][0])}m=-1}h.push(M+h.pop()+P);break;case"PtgRefErr":case"PtgRefErr3d":case"PtgAreaErr":case"PtgAreaErr3d":h.push("#REF!");break;case"PtgExp":o={c:y[1][1],r:y[1][0]};var O={c:n.c,r:n.r};if(r.sharedf[Fi(o)]){var R=r.sharedf[Fi(o)];h.push(xl(R,u,O,r,i))}else{var D=!1;for(a=0;a!=r.arrayf.length;++a)if(s=r.arrayf[a],!(o.cs[0].e.c)&&!(o.rs[0].e.r)){h.push(xl(s[1],u,O,r,i)),D=!0;break}D||h.push(y[1])}break;case"PtgArray":h.push("{"+gl(y[1])+"}");break;case"PtgAttrSpace":case"PtgAttrSpaceSemi":m=v;break;case"PtgMissArg":h.push("");break;case"PtgList":h.push("Table"+y[1].idx+"[#"+y[1].rt+"]");break;case"PtgElfCol":case"PtgElfColS":case"PtgElfColSV":case"PtgElfColV":case"PtgElfLel":case"PtgElfRadical":case"PtgElfRadicalLel":case"PtgElfRadicalS":case"PtgElfRw":case"PtgElfRwV":throw new Error("Unsupported ELFs");default:throw new Error("Unrecognized Formula Token: "+String(y))}if(3!=i.biff&&m>=0&&-1==["PtgAttrSpace","PtgAttrSpaceSemi","PtgAttrGoto"].indexOf(e[0][v][0])){var L=!0;switch((y=e[0][m])[1][0]){case 4:L=!1;case 0:g=Gn(" ",y[1][1]);break;case 5:L=!1;case 1:g=Gn("\r",y[1][1]);break;default:if(g="",i.WTF)throw new Error("Unexpected PtgAttrSpaceType "+y[1][0])}h.push((L?g:"")+h.pop()+(L?"":g)),m=-1}}if(h.length>1&&i.WTF)throw new Error("bad formula stack");return h[0]}function wl(e,t,n){var r,i=e.l+t,a=2==n.biff?1:2,s=e.read_shift(a);if(65535==s)return[[],Ei(e,t-2)];var o=ml(e,s,n);return t!==s+a&&(r=pl(e,t-s-a,o,n)),e.l=i,[o,r]}function _l(e,t,n){var r,i=e.l+t,a=e.read_shift(2),s=ml(e,a,n);return 65535==a?[[],Ei(e,t-2)]:(t!==a+2&&(r=pl(e,i-a-2,s,n)),[s,r])}function Tl(e,t,n){var r=e.l+t,i=as(e);2==n.biff&&++e.l;var a=function(e){var t;if(65535!==fi(e,e.l+6))return[aa(e),"n"];switch(e[e.l]){case 0:return e.l+=8,["String","s"];case 1:return t=1===e[e.l+2],e.l+=8,[t,"b"];case 2:return t=e[e.l+2],e.l+=8,[t,"e"];case 3:return e.l+=8,["","s"]}return[]}(e),s=e.read_shift(1);2!=n.biff&&(e.read_shift(1),n.biff>=5&&e.read_shift(4));var o=function(e,t,n){var r,i=e.l+t,a=2==n.biff?1:2,s=e.read_shift(a);if(65535==s)return[[],Ei(e,t-2)];var o=ml(e,s,n);return t!==s+a&&(r=pl(e,t-s-a,o,n)),e.l=i,[o,r]}(e,r-e.l,n);return{cell:i,val:a[0],formula:o,shared:s>>3&1,tt:a[1]}}function El(e,t,n){var r=e.read_shift(4),i=ml(e,r,n),a=e.read_shift(4);return[i,a>0?pl(e,a,i,n):null]}var kl=El,Sl=El,Cl=El,Al=El,Ml={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",135:"FREEZE.PANES",136:"SHOW.INFO",137:"SPLIT",138:"ON.WINDOW",139:"ON.DATA",140:"DISABLE.INPUT",142:"OUTLINE",143:"LIST.NAMES",144:"FILE.CLOSE",145:"SAVE.WORKBOOK",146:"DATA.FORM",147:"COPY.CHART",148:"ON.TIME",149:"WAIT",150:"FORMAT.FONT",151:"FILL.UP",152:"FILL.LEFT",153:"DELETE.OVERLAY",155:"SHORT.MENUS",159:"SET.UPDATE.STATUS",161:"COLOR.PALETTE",162:"DELETE.STYLE",163:"WINDOW.RESTORE",164:"WINDOW.MAXIMIZE",166:"CHANGE.LINK",167:"CALCULATE.DOCUMENT",168:"ON.KEY",169:"APP.RESTORE",170:"APP.MOVE",171:"APP.SIZE",172:"APP.MINIMIZE",173:"APP.MAXIMIZE",174:"BRING.TO.FRONT",175:"SEND.TO.BACK",185:"MAIN.CHART.TYPE",186:"OVERLAY.CHART.TYPE",187:"SELECT.END",188:"OPEN.MAIL",189:"SEND.MAIL",190:"STANDARD.FONT",191:"CONSOLIDATE",192:"SORT.SPECIAL",193:"GALLERY.3D.AREA",194:"GALLERY.3D.COLUMN",195:"GALLERY.3D.LINE",196:"GALLERY.3D.PIE",197:"VIEW.3D",198:"GOAL.SEEK",199:"WORKGROUP",200:"FILL.GROUP",201:"UPDATE.LINK",202:"PROMOTE",203:"DEMOTE",204:"SHOW.DETAIL",206:"UNGROUP",207:"OBJECT.PROPERTIES",208:"SAVE.NEW.OBJECT",209:"SHARE",210:"SHARE.NAME",211:"DUPLICATE",212:"APPLY.STYLE",213:"ASSIGN.TO.OBJECT",214:"OBJECT.PROTECTION",215:"HIDE.OBJECT",216:"SET.EXTRACT",217:"CREATE.PUBLISHER",218:"SUBSCRIBE.TO",219:"ATTRIBUTES",220:"SHOW.TOOLBAR",222:"PRINT.PREVIEW",223:"EDIT.COLOR",224:"SHOW.LEVELS",225:"FORMAT.MAIN",226:"FORMAT.OVERLAY",227:"ON.RECALC",228:"EDIT.SERIES",229:"DEFINE.STYLE",240:"LINE.PRINT",243:"ENTER.DATA",249:"GALLERY.RADAR",250:"MERGE.STYLES",251:"EDITION.OPTIONS",252:"PASTE.PICTURE",253:"PASTE.PICTURE.LINK",254:"SPELLING",256:"ZOOM",259:"INSERT.OBJECT",260:"WINDOW.MINIMIZE",265:"SOUND.NOTE",266:"SOUND.PLAY",267:"FORMAT.SHAPE",268:"EXTEND.POLYGON",269:"FORMAT.AUTO",272:"GALLERY.3D.BAR",273:"GALLERY.3D.SURFACE",274:"FILL.AUTO",276:"CUSTOMIZE.TOOLBAR",277:"ADD.TOOL",278:"EDIT.OBJECT",279:"ON.DOUBLECLICK",280:"ON.ENTRY",281:"WORKBOOK.ADD",282:"WORKBOOK.MOVE",283:"WORKBOOK.COPY",284:"WORKBOOK.OPTIONS",285:"SAVE.WORKSPACE",288:"CHART.WIZARD",289:"DELETE.TOOL",290:"MOVE.TOOL",291:"WORKBOOK.SELECT",292:"WORKBOOK.ACTIVATE",293:"ASSIGN.TO.TOOL",295:"COPY.TOOL",296:"RESET.TOOL",297:"CONSTRAIN.NUMERIC",298:"PASTE.TOOL",302:"WORKBOOK.NEW",305:"SCENARIO.CELLS",306:"SCENARIO.DELETE",307:"SCENARIO.ADD",308:"SCENARIO.EDIT",309:"SCENARIO.SHOW",310:"SCENARIO.SHOW.NEXT",311:"SCENARIO.SUMMARY",312:"PIVOT.TABLE.WIZARD",313:"PIVOT.FIELD.PROPERTIES",314:"PIVOT.FIELD",315:"PIVOT.ITEM",316:"PIVOT.ADD.FIELDS",318:"OPTIONS.CALCULATION",319:"OPTIONS.EDIT",320:"OPTIONS.VIEW",321:"ADDIN.MANAGER",322:"MENU.EDITOR",323:"ATTACH.TOOLBARS",324:"VBAActivate",325:"OPTIONS.CHART",328:"VBA.INSERT.FILE",330:"VBA.PROCEDURE.DEFINITION",336:"ROUTING.SLIP",338:"ROUTE.DOCUMENT",339:"MAIL.LOGON",342:"INSERT.PICTURE",343:"EDIT.TOOL",344:"GALLERY.DOUGHNUT",350:"CHART.TREND",352:"PIVOT.ITEM.PROPERTIES",354:"WORKBOOK.INSERT",355:"OPTIONS.TRANSITION",356:"OPTIONS.GENERAL",370:"FILTER.ADVANCED",373:"MAIL.ADD.MAILER",374:"MAIL.DELETE.MAILER",375:"MAIL.REPLY",376:"MAIL.REPLY.ALL",377:"MAIL.FORWARD",378:"MAIL.NEXT.LETTER",379:"DATA.LABEL",380:"INSERT.TITLE",381:"FONT.PROPERTIES",382:"MACRO.OPTIONS",383:"WORKBOOK.HIDE",384:"WORKBOOK.UNHIDE",385:"WORKBOOK.DELETE",386:"WORKBOOK.NAME",388:"GALLERY.CUSTOM",390:"ADD.CHART.AUTOFORMAT",391:"DELETE.CHART.AUTOFORMAT",392:"CHART.ADD.DATA",393:"AUTO.OUTLINE",394:"TAB.ORDER",395:"SHOW.DIALOG",396:"SELECT.ALL",397:"UNGROUP.SHEETS",398:"SUBTOTAL.CREATE",399:"SUBTOTAL.REMOVE",400:"RENAME.OBJECT",412:"WORKBOOK.SCROLL",413:"WORKBOOK.NEXT",414:"WORKBOOK.PREV",415:"WORKBOOK.TAB.SPLIT",416:"FULL.SCREEN",417:"WORKBOOK.PROTECT",420:"SCROLLBAR.PROPERTIES",421:"PIVOT.SHOW.PAGES",422:"TEXT.TO.COLUMNS",423:"FORMAT.CHARTTYPE",424:"LINK.FORMAT",425:"TRACER.DISPLAY",430:"TRACER.NAVIGATE",431:"TRACER.CLEAR",432:"TRACER.ERROR",433:"PIVOT.FIELD.GROUP",434:"PIVOT.FIELD.UNGROUP",435:"CHECKBOX.PROPERTIES",436:"LABEL.PROPERTIES",437:"LISTBOX.PROPERTIES",438:"EDITBOX.PROPERTIES",439:"PIVOT.REFRESH",440:"LINK.COMBO",441:"OPEN.TEXT",442:"HIDE.DIALOG",443:"SET.DIALOG.FOCUS",444:"ENABLE.OBJECT",445:"PUSHBUTTON.PROPERTIES",446:"SET.DIALOG.DEFAULT",447:"FILTER",448:"FILTER.SHOW.ALL",449:"CLEAR.OUTLINE",450:"FUNCTION.WIZARD",451:"ADD.LIST.ITEM",452:"SET.LIST.ITEM",453:"REMOVE.LIST.ITEM",454:"SELECT.LIST.ITEM",455:"SET.CONTROL.VALUE",456:"SAVE.COPY.AS",458:"OPTIONS.LISTS.ADD",459:"OPTIONS.LISTS.DELETE",460:"SERIES.AXES",461:"SERIES.X",462:"SERIES.Y",463:"ERRORBAR.X",464:"ERRORBAR.Y",465:"FORMAT.CHART",466:"SERIES.ORDER",467:"MAIL.LOGOFF",468:"CLEAR.ROUTING.SLIP",469:"APP.ACTIVATE.MICROSOFT",470:"MAIL.EDIT.MAILER",471:"ON.SHEET",472:"STANDARD.WIDTH",473:"SCENARIO.MERGE",474:"SUMMARY.INFO",475:"FIND.FILE",476:"ACTIVE.CELL.FONT",477:"ENABLE.TIPWIZARD",478:"VBA.MAKE.ADDIN",480:"INSERTDATATABLE",481:"WORKGROUP.OPTIONS",482:"MAIL.SEND.MAILER",485:"AUTOCORRECT",489:"POST.DOCUMENT",491:"PICKLIST",493:"VIEW.SHOW",494:"VIEW.DEFINE",495:"VIEW.DELETE",509:"SHEET.BACKGROUND",510:"INSERT.MAP.OBJECT",511:"OPTIONS.MENONO",517:"MSOCHECKS",518:"NORMAL",519:"LAYOUT",520:"RM.PRINT.AREA",521:"CLEAR.PRINT.AREA",522:"ADD.PRINT.AREA",523:"MOVE.BRK",545:"HIDECURR.NOTE",546:"HIDEALL.NOTES",547:"DELETE.NOTE",548:"TRAVERSE.NOTES",549:"ACTIVATE.NOTES",620:"PROTECT.REVISIONS",621:"UNPROTECT.REVISIONS",647:"OPTIONS.ME",653:"WEB.PUBLISH",667:"NEWWEBQUERY",673:"PIVOT.TABLE.CHART",753:"OPTIONS.SAVE",755:"OPTIONS.SPELL",808:"HIDEALL.INKANNOTS"},Pl={0:"COUNT",1:"IF",2:"ISNA",3:"ISERROR",4:"SUM",5:"AVERAGE",6:"MIN",7:"MAX",8:"ROW",9:"COLUMN",10:"NA",11:"NPV",12:"STDEV",13:"DOLLAR",14:"FIXED",15:"SIN",16:"COS",17:"TAN",18:"ATAN",19:"PI",20:"SQRT",21:"EXP",22:"LN",23:"LOG10",24:"ABS",25:"INT",26:"SIGN",27:"ROUND",28:"LOOKUP",29:"INDEX",30:"REPT",31:"MID",32:"LEN",33:"VALUE",34:"TRUE",35:"FALSE",36:"AND",37:"OR",38:"NOT",39:"MOD",40:"DCOUNT",41:"DSUM",42:"DAVERAGE",43:"DMIN",44:"DMAX",45:"DSTDEV",46:"VAR",47:"DVAR",48:"TEXT",49:"LINEST",50:"TREND",51:"LOGEST",52:"GROWTH",53:"GOTO",54:"HALT",55:"RETURN",56:"PV",57:"FV",58:"NPER",59:"PMT",60:"RATE",61:"MIRR",62:"IRR",63:"RAND",64:"MATCH",65:"DATE",66:"TIME",67:"DAY",68:"MONTH",69:"YEAR",70:"WEEKDAY",71:"HOUR",72:"MINUTE",73:"SECOND",74:"NOW",75:"AREAS",76:"ROWS",77:"COLUMNS",78:"OFFSET",79:"ABSREF",80:"RELREF",81:"ARGUMENT",82:"SEARCH",83:"TRANSPOSE",84:"ERROR",85:"STEP",86:"TYPE",87:"ECHO",88:"SET.NAME",89:"CALLER",90:"DEREF",91:"WINDOWS",92:"SERIES",93:"DOCUMENTS",94:"ACTIVE.CELL",95:"SELECTION",96:"RESULT",97:"ATAN2",98:"ASIN",99:"ACOS",100:"CHOOSE",101:"HLOOKUP",102:"VLOOKUP",103:"LINKS",104:"INPUT",105:"ISREF",106:"GET.FORMULA",107:"GET.NAME",108:"SET.VALUE",109:"LOG",110:"EXEC",111:"CHAR",112:"LOWER",113:"UPPER",114:"PROPER",115:"LEFT",116:"RIGHT",117:"EXACT",118:"TRIM",119:"REPLACE",120:"SUBSTITUTE",121:"CODE",122:"NAMES",123:"DIRECTORY",124:"FIND",125:"CELL",126:"ISERR",127:"ISTEXT",128:"ISNUMBER",129:"ISBLANK",130:"T",131:"N",132:"FOPEN",133:"FCLOSE",134:"FSIZE",135:"FREADLN",136:"FREAD",137:"FWRITELN",138:"FWRITE",139:"FPOS",140:"DATEVALUE",141:"TIMEVALUE",142:"SLN",143:"SYD",144:"DDB",145:"GET.DEF",146:"REFTEXT",147:"TEXTREF",148:"INDIRECT",149:"REGISTER",150:"CALL",151:"ADD.BAR",152:"ADD.MENU",153:"ADD.COMMAND",154:"ENABLE.COMMAND",155:"CHECK.COMMAND",156:"RENAME.COMMAND",157:"SHOW.BAR",158:"DELETE.MENU",159:"DELETE.COMMAND",160:"GET.CHART.ITEM",161:"DIALOG.BOX",162:"CLEAN",163:"MDETERM",164:"MINVERSE",165:"MMULT",166:"FILES",167:"IPMT",168:"PPMT",169:"COUNTA",170:"CANCEL.KEY",171:"FOR",172:"WHILE",173:"BREAK",174:"NEXT",175:"INITIATE",176:"REQUEST",177:"POKE",178:"EXECUTE",179:"TERMINATE",180:"RESTART",181:"HELP",182:"GET.BAR",183:"PRODUCT",184:"FACT",185:"GET.CELL",186:"GET.WORKSPACE",187:"GET.WINDOW",188:"GET.DOCUMENT",189:"DPRODUCT",190:"ISNONTEXT",191:"GET.NOTE",192:"NOTE",193:"STDEVP",194:"VARP",195:"DSTDEVP",196:"DVARP",197:"TRUNC",198:"ISLOGICAL",199:"DCOUNTA",200:"DELETE.BAR",201:"UNREGISTER",204:"USDOLLAR",205:"FINDB",206:"SEARCHB",207:"REPLACEB",208:"LEFTB",209:"RIGHTB",210:"MIDB",211:"LENB",212:"ROUNDUP",213:"ROUNDDOWN",214:"ASC",215:"DBCS",216:"RANK",219:"ADDRESS",220:"DAYS360",221:"TODAY",222:"VDB",223:"ELSE",224:"ELSE.IF",225:"END.IF",226:"FOR.CELL",227:"MEDIAN",228:"SUMPRODUCT",229:"SINH",230:"COSH",231:"TANH",232:"ASINH",233:"ACOSH",234:"ATANH",235:"DGET",236:"CREATE.OBJECT",237:"VOLATILE",238:"LAST.ERROR",239:"CUSTOM.UNDO",240:"CUSTOM.REPEAT",241:"FORMULA.CONVERT",242:"GET.LINK.INFO",243:"TEXT.BOX",244:"INFO",245:"GROUP",246:"GET.OBJECT",247:"DB",248:"PAUSE",251:"RESUME",252:"FREQUENCY",253:"ADD.TOOLBAR",254:"DELETE.TOOLBAR",255:"User",256:"RESET.TOOLBAR",257:"EVALUATE",258:"GET.TOOLBAR",259:"GET.TOOL",260:"SPELLING.CHECK",261:"ERROR.TYPE",262:"APP.TITLE",263:"WINDOW.TITLE",264:"SAVE.TOOLBAR",265:"ENABLE.TOOL",266:"PRESS.TOOL",267:"REGISTER.ID",268:"GET.WORKBOOK",269:"AVEDEV",270:"BETADIST",271:"GAMMALN",272:"BETAINV",273:"BINOMDIST",274:"CHIDIST",275:"CHIINV",276:"COMBIN",277:"CONFIDENCE",278:"CRITBINOM",279:"EVEN",280:"EXPONDIST",281:"FDIST",282:"FINV",283:"FISHER",284:"FISHERINV",285:"FLOOR",286:"GAMMADIST",287:"GAMMAINV",288:"CEILING",289:"HYPGEOMDIST",290:"LOGNORMDIST",291:"LOGINV",292:"NEGBINOMDIST",293:"NORMDIST",294:"NORMSDIST",295:"NORMINV",296:"NORMSINV",297:"STANDARDIZE",298:"ODD",299:"PERMUT",300:"POISSON",301:"TDIST",302:"WEIBULL",303:"SUMXMY2",304:"SUMX2MY2",305:"SUMX2PY2",306:"CHITEST",307:"CORREL",308:"COVAR",309:"FORECAST",310:"FTEST",311:"INTERCEPT",312:"PEARSON",313:"RSQ",314:"STEYX",315:"SLOPE",316:"TTEST",317:"PROB",318:"DEVSQ",319:"GEOMEAN",320:"HARMEAN",321:"SUMSQ",322:"KURT",323:"SKEW",324:"ZTEST",325:"LARGE",326:"SMALL",327:"QUARTILE",328:"PERCENTILE",329:"PERCENTRANK",330:"MODE",331:"TRIMMEAN",332:"TINV",334:"MOVIE.COMMAND",335:"GET.MOVIE",336:"CONCATENATE",337:"POWER",338:"PIVOT.ADD.DATA",339:"GET.PIVOT.TABLE",340:"GET.PIVOT.FIELD",341:"GET.PIVOT.ITEM",342:"RADIANS",343:"DEGREES",344:"SUBTOTAL",345:"SUMIF",346:"COUNTIF",347:"COUNTBLANK",348:"SCENARIO.GET",349:"OPTIONS.LISTS.GET",350:"ISPMT",351:"DATEDIF",352:"DATESTRING",353:"NUMBERSTRING",354:"ROMAN",355:"OPEN.DIALOG",356:"SAVE.DIALOG",357:"VIEW.GET",358:"GETPIVOTDATA",359:"HYPERLINK",360:"PHONETIC",361:"AVERAGEA",362:"MAXA",363:"MINA",364:"STDEVPA",365:"VARPA",366:"STDEVA",367:"VARA",368:"BAHTTEXT",369:"THAIDAYOFWEEK",370:"THAIDIGIT",371:"THAIMONTHOFYEAR",372:"THAINUMSOUND",373:"THAINUMSTRING",374:"THAISTRINGLENGTH",375:"ISTHAIDIGIT",376:"ROUNDBAHTDOWN",377:"ROUNDBAHTUP",378:"THAIYEAR",379:"RTD",380:"CUBEVALUE",381:"CUBEMEMBER",382:"CUBEMEMBERPROPERTY",383:"CUBERANKEDMEMBER",384:"HEX2BIN",385:"HEX2DEC",386:"HEX2OCT",387:"DEC2BIN",388:"DEC2HEX",389:"DEC2OCT",390:"OCT2BIN",391:"OCT2HEX",392:"OCT2DEC",393:"BIN2DEC",394:"BIN2OCT",395:"BIN2HEX",396:"IMSUB",397:"IMDIV",398:"IMPOWER",399:"IMABS",400:"IMSQRT",401:"IMLN",402:"IMLOG2",403:"IMLOG10",404:"IMSIN",405:"IMCOS",406:"IMEXP",407:"IMARGUMENT",408:"IMCONJUGATE",409:"IMAGINARY",410:"IMREAL",411:"COMPLEX",412:"IMSUM",413:"IMPRODUCT",414:"SERIESSUM",415:"FACTDOUBLE",416:"SQRTPI",417:"QUOTIENT",418:"DELTA",419:"GESTEP",420:"ISEVEN",421:"ISODD",422:"MROUND",423:"ERF",424:"ERFC",425:"BESSELJ",426:"BESSELK",427:"BESSELY",428:"BESSELI",429:"XIRR",430:"XNPV",431:"PRICEMAT",432:"YIELDMAT",433:"INTRATE",434:"RECEIVED",435:"DISC",436:"PRICEDISC",437:"YIELDDISC",438:"TBILLEQ",439:"TBILLPRICE",440:"TBILLYIELD",441:"PRICE",442:"YIELD",443:"DOLLARDE",444:"DOLLARFR",445:"NOMINAL",446:"EFFECT",447:"CUMPRINC",448:"CUMIPMT",449:"EDATE",450:"EOMONTH",451:"YEARFRAC",452:"COUPDAYBS",453:"COUPDAYS",454:"COUPDAYSNC",455:"COUPNCD",456:"COUPNUM",457:"COUPPCD",458:"DURATION",459:"MDURATION",460:"ODDLPRICE",461:"ODDLYIELD",462:"ODDFPRICE",463:"ODDFYIELD",464:"RANDBETWEEN",465:"WEEKNUM",466:"AMORDEGRC",467:"AMORLINC",468:"CONVERT",724:"SHEETJS",469:"ACCRINT",470:"ACCRINTM",471:"WORKDAY",472:"NETWORKDAYS",473:"GCD",474:"MULTINOMIAL",475:"LCM",476:"FVSCHEDULE",477:"CUBEKPIMEMBER",478:"CUBESET",479:"CUBESETCOUNT",480:"IFERROR",481:"COUNTIFS",482:"SUMIFS",483:"AVERAGEIF",484:"AVERAGEIFS"},Ol={2:1,3:1,10:0,15:1,16:1,17:1,18:1,19:0,20:1,21:1,22:1,23:1,24:1,25:1,26:1,27:2,30:2,31:3,32:1,33:1,34:0,35:0,38:1,39:2,40:3,41:3,42:3,43:3,44:3,45:3,47:3,48:2,53:1,61:3,63:0,65:3,66:3,67:1,68:1,69:1,70:1,71:1,72:1,73:1,74:0,75:1,76:1,77:1,79:2,80:2,83:1,85:0,86:1,89:0,90:1,94:0,95:0,97:2,98:1,99:1,101:3,102:3,105:1,106:1,108:2,111:1,112:1,113:1,114:1,117:2,118:1,119:4,121:1,126:1,127:1,128:1,129:1,130:1,131:1,133:1,134:1,135:1,136:2,137:2,138:2,140:1,141:1,142:3,143:4,144:4,161:1,162:1,163:1,164:1,165:2,172:1,175:2,176:2,177:3,178:2,179:1,184:1,186:1,189:3,190:1,195:3,196:3,197:1,198:1,199:3,201:1,207:4,210:3,211:1,212:2,213:2,214:1,215:1,225:0,229:1,230:1,231:1,232:1,233:1,234:1,235:3,244:1,247:4,252:2,257:1,261:1,271:1,273:4,274:2,275:2,276:2,277:3,278:3,279:1,280:3,281:3,282:3,283:1,284:1,285:2,286:4,287:3,288:2,289:4,290:3,291:3,292:3,293:4,294:1,295:3,296:1,297:3,298:1,299:2,300:3,301:3,302:4,303:2,304:2,305:2,306:2,307:2,308:2,309:3,310:2,311:2,312:2,313:2,314:2,315:2,316:4,325:2,326:2,327:2,328:2,331:2,332:2,337:2,342:1,343:1,346:2,347:1,350:4,351:3,352:1,353:2,360:1,368:1,369:1,370:1,371:1,372:1,373:1,374:1,375:1,376:1,377:1,378:1,382:3,385:1,392:1,393:1,396:2,397:2,398:2,399:1,400:1,401:1,402:1,403:1,404:1,405:1,406:1,407:1,408:1,409:1,410:1,414:4,415:1,416:1,417:2,420:1,421:1,422:2,424:1,425:2,426:2,427:2,428:2,430:3,438:3,439:3,440:3,443:2,444:2,445:2,446:2,447:6,448:6,449:2,450:2,464:2,468:3,476:2,479:1,480:2,65535:0};function Rl(e){return"of:"==e.slice(0,3)&&(e=e.slice(3)),61==e.charCodeAt(0)&&61==(e=e.slice(1)).charCodeAt(0)&&(e=e.slice(1)),(e=(e=(e=e.replace(/COM\.MICROSOFT\./g,"")).replace(/\[((?:\.[A-Z]+[0-9]+)(?::\.[A-Z]+[0-9]+)?)\]/g,(function(e,t){return t.replace(/\./g,"")}))).replace(/\[.(#[A-Z]*[?!])\]/g,"$1")).replace(/[;~]/g,",").replace(/\|/g,";")}function Dl(e){var t=e.split(":");return[t[0].split(".")[0],t[0].split(".")[1]+(t.length>1?":"+(t[1].split(".")[1]||t[1].split(".")[0]):"")]}var Ll={},Il={};function Nl(e,t){if(e){var n=[.7,.7,.75,.75,.3,.3];"xlml"==t&&(n=[1,1,1,1,.5,.5]),null==e.left&&(e.left=n[0]),null==e.right&&(e.right=n[1]),null==e.top&&(e.top=n[2]),null==e.bottom&&(e.bottom=n[3]),null==e.header&&(e.header=n[4]),null==e.footer&&(e.footer=n[5])}}function Fl(e,t,n,r,i,a){try{r.cellNF&&(e.z=Wt[t])}catch(kC){if(r.WTF)throw kC}if("z"!==e.t||r.cellStyles){if("d"===e.t&&"string"===typeof e.v&&(e.v=Hn(e.v)),(!r||!1!==r.cellText)&&"z"!==e.t)try{if(null==Wt[t]&&En(Sn[t]||"General",t),"e"===e.t)e.w=e.w||ya[e.v];else if(0===t)if("n"===e.t)(0|e.v)===e.v?e.w=e.v.toString(10):e.w=en(e.v);else if("d"===e.t){var s=Ln(e.v);e.w=(0|s)===s?s.toString(10):en(s)}else{if(void 0===e.v)return"";e.w=tn(e.v,Il)}else"d"===e.t?e.w=Tn(t,Ln(e.v),Il):e.w=Tn(t,e.v,Il)}catch(kC){if(r.WTF)throw kC}if(r.cellStyles&&null!=n)try{e.s=a.Fills[n],e.s.fgColor&&e.s.fgColor.theme&&!e.s.fgColor.rgb&&(e.s.fgColor.rgb=oo(i.themeElements.clrScheme[e.s.fgColor.theme].rgb,e.s.fgColor.tint||0),r.WTF&&(e.s.fgColor.raw_rgb=i.themeElements.clrScheme[e.s.fgColor.theme].rgb)),e.s.bgColor&&e.s.bgColor.theme&&(e.s.bgColor.rgb=oo(i.themeElements.clrScheme[e.s.bgColor.theme].rgb,e.s.bgColor.tint||0),r.WTF&&(e.s.bgColor.raw_rgb=i.themeElements.clrScheme[e.s.bgColor.theme].rgb))}catch(kC){if(r.WTF&&a.Fills)throw kC}}}var zl=/<(?:\w:)?mergeCell ref="[A-Z0-9:]+"\s*[\/]?>/g,Bl=/<(?:\w+:)?sheetData[^>]*>([\s\S]*)<\/(?:\w+:)?sheetData>/,jl=/<(?:\w:)?hyperlink [^>]*>/gm,Vl=/"(\w*:\w*)"/,Ul=/<(?:\w:)?col\b[^>]*[\/]?>/g,Hl=/<(?:\w:)?autoFilter[^>]*([\/]|>([\s\S]*)<\/(?:\w:)?autoFilter)>/g,Wl=/<(?:\w:)?pageMargins[^>]*\/>/g,$l=/<(?:\w:)?sheetPr\b(?:[^>a-z][^>]*)?\/>/,Gl=/<(?:\w:)?sheetPr[^>]*(?:[\/]|>([\s\S]*)<\/(?:\w:)?sheetPr)>/,Kl=/<(?:\w:)?sheetViews[^>]*(?:[\/]|>([\s\S]*)<\/(?:\w:)?sheetViews)>/;function Yl(e,t,n,r,i,a,s){if(!e)return e;r||(r={"!id":{}}),null!=wt&&null==t.dense&&(t.dense=wt);var o=t.dense?[]:{},l={s:{r:2e6,c:2e6},e:{r:0,c:0}},c="",u="",h=e.match(Bl);h?(c=e.slice(0,h.index),u=e.slice(h.index+h[0].length)):c=u=e;var f=c.match($l);f?Xl(f[0],o,i,n):(f=c.match(Gl))&&function(e,t,n,r,i){Xl(e.slice(0,e.indexOf(">")),n,r,i)}(f[0],f[1],o,i,n);var d=(c.match(/<(?:\w*:)?dimension/)||{index:-1}).index;if(d>0){var p=c.slice(d,d+50).match(Vl);p&&function(e,t){var n=ji(t);n.s.r<=n.e.r&&n.s.c<=n.e.c&&n.s.r>=0&&n.s.c>=0&&(e["!ref"]=Bi(n))}(o,p[1])}var m=c.match(Kl);m&&m[1]&&function(e,t){t.Views||(t.Views=[{}]);(e.match(ql)||[]).forEach((function(e,n){var r=pr(e);t.Views[n]||(t.Views[n]={}),+r.zoomScale&&(t.Views[n].zoom=+r.zoomScale),Tr(r.rightToLeft)&&(t.Views[n].RTL=!0)}))}(m[1],i);var g=[];if(t.cellStyles){var v=c.match(Ul);v&&function(e,t){for(var n=!1,r=0;r!=t.length;++r){var i=pr(t[r],!0);i.hidden&&(i.hidden=Tr(i.hidden));var a=parseInt(i.min,10)-1,s=parseInt(i.max,10)-1;for(i.outlineLevel&&(i.level=+i.outlineLevel||0),delete i.min,delete i.max,i.width=+i.width,!n&&i.width&&(n=!0,vo(i.width)),bo(i);a<=s;)e[a++]=$n(i)}}(g,v)}h&&Zl(h[1],o,t,l,a,s);var b=u.match(Hl);b&&(o["!autofilter"]=function(e){var t={ref:(e.match(/ref="([^"]*)"/)||[])[1]};return t}(b[0]));var y=[],x=u.match(zl);if(x)for(d=0;d!=x.length;++d)y[d]=ji(x[d].slice(x[d].indexOf('"')+1));var w=u.match(jl);w&&function(e,t,n){for(var r=Array.isArray(e),i=0;i!=t.length;++i){var a=pr(Ar(t[i]),!0);if(!a.ref)return;var s=((n||{})["!id"]||[])[a.id];s?(a.Target=s.Target,a.location&&(a.Target+="#"+br(a.location))):(a.Target="#"+br(a.location),s={Target:a.Target,TargetMode:"Internal"}),a.Rel=s,a.tooltip&&(a.Tooltip=a.tooltip,delete a.tooltip);for(var o=ji(a.ref),l=o.s.r;l<=o.e.r;++l)for(var c=o.s.c;c<=o.e.c;++c){var u=Fi({c:c,r:l});r?(e[l]||(e[l]=[]),e[l][c]||(e[l][c]={t:"z",v:void 0}),e[l][c].l=a):(e[u]||(e[u]={t:"z",v:void 0}),e[u].l=a)}}}(o,w,r);var _=u.match(Wl);if(_&&(o["!margins"]=function(e){var t={};return["left","right","top","bottom","header","footer"].forEach((function(n){e[n]&&(t[n]=parseFloat(e[n]))})),t}(pr(_[0]))),!o["!ref"]&&l.e.c>=l.s.c&&l.e.r>=l.s.r&&(o["!ref"]=Bi(l)),t.sheetRows>0&&o["!ref"]){var T=ji(o["!ref"]);t.sheetRows<=+T.e.r&&(T.e.r=t.sheetRows-1,T.e.r>l.e.r&&(T.e.r=l.e.r),T.e.rl.e.c&&(T.e.c=l.e.c),T.e.c0&&(o["!cols"]=g),y.length>0&&(o["!merges"]=y),o}function Xl(e,t,n,r){var i=pr(e);n.Sheets[r]||(n.Sheets[r]={}),i.codeName&&(n.Sheets[r].CodeName=br(Ar(i.codeName)))}var ql=/<(?:\w:)?sheetView(?:[^>a-z][^>]*)?\/?>/;var Zl=function(){var e=/<(?:\w+:)?c[ \/>]/,t=/<\/(?:\w+:)?row>/,n=/r=["']([^"']*)["']/,r=/<(?:\w+:)?is>([\S\s]*?)<\/(?:\w+:)?is>/,i=/ref=["']([^"']*)["']/,a=Pr("v"),s=Pr("f");return function(o,l,c,u,h,f){for(var d,p,m,g,v,b=0,y="",x=[],w=[],_=0,T=0,E=0,k="",S=0,C=0,A=0,M=0,P=Array.isArray(f.CellXf),O=[],R=[],D=Array.isArray(l),L=[],I={},N=!1,F=!!c.sheetStubs,z=o.split(t),B=0,j=z.length;B!=j;++B){var V=(y=z[B].trim()).length;if(0!==V){var U=0;e:for(b=0;b":if("/"!=y[b-1]){++b;break e}if(c&&c.cellStyles){if(S=null!=(p=pr(y.slice(U,b),!0)).r?parseInt(p.r,10):S+1,C=-1,c.sheetRows&&c.sheetRows=b)break;if(S=null!=(p=pr(y.slice(U,b),!0)).r?parseInt(p.r,10):S+1,C=-1,!(c.sheetRows&&c.sheetRowsS-1&&(u.s.r=S-1),u.e.r":"")+y,null!=w&&2===w.length){for(_=0,k=w[1],T=0;T!=k.length&&!((E=k.charCodeAt(T)-64)<1||E>26);++T)_=26*_+E;C=--_}else++C;for(T=0;T!=y.length&&62!==y.charCodeAt(T);++T);if(++T,(p=pr(y.slice(0,T),!0)).r||(p.r=Fi({r:S-1,c:C})),d={t:""},null!=(w=(k=y.slice(T)).match(a))&&""!==w[1]&&(d.v=br(w[1])),c.cellFormula){if(null!=(w=k.match(s))&&""!==w[1]){if(d.f=br(Ar(w[1])).replace(/\r\n/g,"\n"),c.xlfn||(d.f=Yo(d.f)),w[0].indexOf('t="array"')>-1)d.F=(k.match(i)||[])[1],d.F.indexOf(":")>-1&&O.push([ji(d.F),d.F]);else if(w[0].indexOf('t="shared"')>-1){g=pr(w[0]);var W=br(Ar(w[1]));c.xlfn||(W=Yo(W)),R[parseInt(g.si,10)]=[g,W,p.r]}}else(w=k.match(/]*\/>/))&&R[(g=pr(w[0])).si]&&(d.f=Ko(R[g.si][1],R[g.si][2],p.r));var $=Ni(p.r);for(T=0;T=O[T][0].s.r&&$.r<=O[T][0].e.r&&$.c>=O[T][0].s.c&&$.c<=O[T][0].e.c&&(d.F=O[T][1])}if(null==p.t&&void 0===d.v)if(d.f||d.F)d.v=0,d.t="n";else{if(!F)continue;d.t="z"}else d.t=p.t||"n";switch(u.s.c>C&&(u.s.c=C),u.e.c0&&(l["!rows"]=L)}}();var Ql=ia;function Jl(e){return[Zi(e),aa(e),"n"]}var ec=ia;var tc=["left","right","top","bottom","header","footer"];function nc(e,t,n,r,i,a){var s=a||{"!type":"chart"};if(!e)return a;var o=0,l=0,c="A",u={s:{r:2e6,c:2e6},e:{r:0,c:0}};return(e.match(/[\s\S]*?<\/c:numCache>/gm)||[]).forEach((function(e){var t=function(e){var t,n=[],r=e.match(/^/);(e.match(/(.*?)<\/c:pt>/gm)||[]).forEach((function(e){var t=e.match(/(.*)<\/c:v><\/c:pt>/);t&&(n[+t[1]]=r?+t[2]:t[2])}));var i=br((e.match(/([\s\S]*?)<\/c:formatCode>/)||["","General"])[1]);return(e.match(/(.*?)<\/c:f>/gm)||[]).forEach((function(e){t=e.replace(/<.*?>/g,"")})),[n,i,t]}(e);u.s.r=u.s.c=0,u.e.c=o,c=Ii(o),t[0].forEach((function(e,n){s[c+Di(n)]={t:"n",v:e,z:t[1]},l=n})),u.e.r0&&(s["!ref"]=Bi(u)),s}var rc=[["allowRefreshQuery",!1,"bool"],["autoCompressPictures",!0,"bool"],["backupFile",!1,"bool"],["checkCompatibility",!1,"bool"],["CodeName",""],["date1904",!1,"bool"],["defaultThemeVersion",0,"int"],["filterPrivacy",!1,"bool"],["hidePivotFieldList",!1,"bool"],["promptedSolutions",!1,"bool"],["publishItems",!1,"bool"],["refreshAllConnections",!1,"bool"],["saveExternalLinkValues",!0,"bool"],["showBorderUnselectedTables",!0,"bool"],["showInkAnnotation",!0,"bool"],["showObjects","all"],["showPivotChartFilter",!1,"bool"],["updateLinks","userSet"]],ic=[["activeTab",0,"int"],["autoFilterDateGrouping",!0,"bool"],["firstSheet",0,"int"],["minimized",!1,"bool"],["showHorizontalScroll",!0,"bool"],["showSheetTabs",!0,"bool"],["showVerticalScroll",!0,"bool"],["tabRatio",600,"int"],["visibility","visible"]],ac=[],sc=[["calcCompleted","true"],["calcMode","auto"],["calcOnSave","true"],["concurrentCalc","true"],["fullCalcOnLoad","false"],["fullPrecision","true"],["iterate","false"],["iterateCount","100"],["iterateDelta","0.001"],["refMode","A1"]];function oc(e,t){for(var n=0;n!=e.length;++n)for(var r=e[n],i=0;i!=t.length;++i){var a=t[i];if(null==r[a[0]])r[a[0]]=a[1];else switch(a[2]){case"bool":"string"==typeof r[a[0]]&&(r[a[0]]=Tr(r[a[0]]));break;case"int":"string"==typeof r[a[0]]&&(r[a[0]]=parseInt(r[a[0]],10))}}}function lc(e,t){for(var n=0;n!=t.length;++n){var r=t[n];if(null==e[r[0]])e[r[0]]=r[1];else switch(r[2]){case"bool":"string"==typeof e[r[0]]&&(e[r[0]]=Tr(e[r[0]]));break;case"int":"string"==typeof e[r[0]]&&(e[r[0]]=parseInt(e[r[0]],10))}}}function cc(e){lc(e.WBProps,rc),lc(e.CalcPr,sc),oc(e.WBView,ic),oc(e.Sheets,ac),Il.date1904=Tr(e.WBProps.date1904)}var uc="][*?/\\".split("");function hc(e,t){if(e.length>31){if(t)return!1;throw new Error("Sheet names cannot exceed 31 chars")}var n=!0;return uc.forEach((function(r){if(-1!=e.indexOf(r)){if(!t)throw new Error("Sheet name cannot contain : \\ / ? * [ ]");n=!1}})),n}var fc=/<\w+:workbook/;function dc(e,t){var n={};return e.read_shift(4),n.ArchID=e.read_shift(4),e.l+=t-8,n}function pc(e,t,n){return".bin"===t.slice(-4)?function(e,t){var n={AppVersion:{},WBProps:{},WBView:[],Sheets:[],CalcPr:{},xmlns:""},r=[],i=!1;t||(t={}),t.biff=12;var a=[],s=[[]];return s.SheetNames=[],s.XTI=[],Hc[16]={n:"BrtFRTArchID$",f:dc},Si(e,(function(e,o,l){switch(l){case 156:s.SheetNames.push(e.name),n.Sheets.push(e);break;case 153:n.WBProps=e;break;case 39:null!=e.Sheet&&(t.SID=e.Sheet),e.Ref=xl(e.Ptg,0,null,s,t),delete t.SID,delete e.Ptg,a.push(e);break;case 1036:case 361:case 2071:case 158:case 143:case 664:case 353:case 3072:case 3073:case 534:case 677:case 157:case 610:case 2050:case 155:case 548:case 676:case 128:case 665:case 2128:case 2125:case 549:case 2053:case 596:case 2076:case 2075:case 2082:case 397:case 154:case 1117:case 553:case 2091:case 16:break;case 357:case 358:case 355:case 667:s[0].length?s.push([l,e]):s[0]=[l,e],s[s.length-1].XTI=[];break;case 362:0===s.length&&(s[0]=[],s[0].XTI=[]),s[s.length-1].XTI=s[s.length-1].XTI.concat(e),s.XTI=s.XTI.concat(e);break;case 35:case 37:r.push(l),i=!0;break;case 36:case 38:r.pop(),i=!1;break;default:if(o.T);else if(!i||t.WTF&&37!=r[r.length-1]&&35!=r[r.length-1])throw new Error("Unexpected record 0x"+l.toString(16))}}),t),cc(n),n.Names=a,n.supbooks=s,n}(e,n):function(e,t){if(!e)throw new Error("Could not find file");var n={AppVersion:{},WBProps:{},WBView:[],Sheets:[],CalcPr:{},Names:[],xmlns:""},r=!1,i="xmlns",a={},s=0;if(e.replace(hr,(function(o,l){var c=pr(o);switch(mr(c[0])){case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":rc.forEach((function(e){if(null!=c[e[0]])switch(e[2]){case"bool":n.WBProps[e[0]]=Tr(c[e[0]]);break;case"int":n.WBProps[e[0]]=parseInt(c[e[0]],10);break;default:n.WBProps[e[0]]=c[e[0]]}})),c.codeName&&(n.WBProps.CodeName=Ar(c.codeName));break;case"":delete c[0],n.WBView.push(c);break;case"":case"":r=!0;break;case"":case"":case"":r=!1;break;case"":a.Ref=br(Ar(e.slice(s,l))),n.Names.push(a);break;case"":delete c[0],n.CalcPr=c;break;default:if(!r&&t.WTF)throw new Error("unrecognized "+c[0]+" in workbook")}return o})),-1===Ur.indexOf(n.xmlns))throw new Error("Unknown Namespace: "+n.xmlns);return cc(n),n}(e,n)}function mc(e,t,n,r,i,a,s,o){return".bin"===t.slice(-4)?function(e,t,n,r,i,a,s){if(!e)return e;var o=t||{};r||(r={"!id":{}}),null!=wt&&null==o.dense&&(o.dense=wt);var l,c,u,h,f,d,p,m,g,v,b=o.dense?[]:{},y={s:{r:2e6,c:2e6},e:{r:0,c:0}},x=[],w=!1,_=!1,T=[];o.biff=12,o["!row"]=0;var E=0,k=!1,S=[],C={},A=o.supbooks||i.supbooks||[[]];if(A.sharedf=C,A.arrayf=S,A.SheetNames=i.SheetNames||i.Sheets.map((function(e){return e.name})),!o.supbooks&&(o.supbooks=A,i.Names))for(var M=0;M=I[0].s.r&&c.r<=I[0].e.r&&d>=I[0].s.c&&d<=I[0].e.c&&(u.F=Bi(I[0]),k=!0)}!k&&e.length>3&&(u.f=e[3])}if(y.s.r>c.r&&(y.s.r=c.r),y.s.c>d&&(y.s.c=d),y.e.rc.r&&(y.s.r=c.r),y.s.c>d&&(y.s.c=d),y.e.r=e.s;)R[e.e--]={width:e.w/256,hidden:!!(1&e.flags),level:e.level},L||(L=!0,vo(e.w/256)),bo(R[e.e+1]);break;case 161:b["!autofilter"]={ref:Bi(e)};break;case 476:b["!margins"]=e;break;case 147:i.Sheets[n]||(i.Sheets[n]={}),e.name&&(i.Sheets[n].CodeName=e.name),(e.above||e.left)&&(b["!outline"]={above:e.above,left:e.left});break;case 137:i.Views||(i.Views=[{}]),i.Views[0]||(i.Views[0]={}),e.RTL&&(i.Views[0].RTL=!0);break;case 485:case 64:case 1053:case 151:case 152:case 175:case 644:case 625:case 562:case 396:case 1112:case 1146:case 471:case 1050:case 649:case 1105:case 589:case 607:case 564:case 1055:case 168:case 174:case 1180:case 499:case 507:case 550:case 171:case 167:case 1177:case 169:case 1181:case 551:case 552:case 661:case 639:case 478:case 537:case 477:case 536:case 1103:case 680:case 1104:case 1024:case 663:case 535:case 678:case 504:case 1043:case 428:case 170:case 3072:case 50:case 2070:case 1045:break;case 35:w=!0;break;case 36:w=!1;break;case 37:x.push(M),w=!0;break;case 38:x.pop(),w=!1;break;default:if(t.T);else if(!w||o.WTF)throw new Error("Unexpected record 0x"+M.toString(16))}}),o),delete o.supbooks,delete o["!row"],!b["!ref"]&&(y.s.r<2e6||l&&(l.e.r>0||l.e.c>0||l.s.r>0||l.s.c>0))&&(b["!ref"]=Bi(l||y)),o.sheetRows&&b["!ref"]){var I=ji(b["!ref"]);o.sheetRows<=+I.e.r&&(I.e.r=o.sheetRows-1,I.e.r>y.e.r&&(I.e.r=y.e.r),I.e.ry.e.c&&(I.e.c=y.e.c),I.e.c0&&(b["!merges"]=T),R.length>0&&(b["!cols"]=R),D.length>0&&(b["!rows"]=D),b}(e,r,n,i,a,s,o):Yl(e,r,n,i,a,s,o)}function gc(e,t,n,r,i,a,s,o){return".bin"===t.slice(-4)?function(e,t,n,r,i){if(!e)return e;r||(r={"!id":{}});var a={"!type":"chart","!drawel":null,"!rel":""},s=[],o=!1;return Si(e,(function(e,r,l){switch(l){case 550:a["!rel"]=e;break;case 651:i.Sheets[n]||(i.Sheets[n]={}),e.name&&(i.Sheets[n].CodeName=e.name);break;case 562:case 652:case 669:case 679:case 551:case 552:case 476:case 3072:break;case 35:o=!0;break;case 36:o=!1;break;case 37:s.push(l);break;case 38:s.pop();break;default:if(r.T>0)s.push(l);else if(r.T<0)s.pop();else if(!o||t.WTF)throw new Error("Unexpected record 0x"+l.toString(16))}}),t),r["!id"][a["!rel"]]&&(a["!drawel"]=r["!id"][a["!rel"]]),a}(e,r,n,i,a):function(e,t,n,r,i){if(!e)return e;r||(r={"!id":{}});var a,s={"!type":"chart","!drawel":null,"!rel":""},o=e.match($l);return o&&Xl(o[0],0,i,n),(a=e.match(/drawing r:id="(.*?)"/))&&(s["!rel"]=a[1]),r["!id"][s["!rel"]]&&(s["!drawel"]=r["!id"][s["!rel"]]),s}(e,0,n,i,a)}function vc(e,t,n,r){return".bin"===t.slice(-4)?function(e,t,n){var r={NumberFmt:[]};for(var i in Wt)r.NumberFmt[i]=Wt[i];r.CellXf=[],r.Fonts=[];var a=[],s=!1;return Si(e,(function(e,i,o){switch(o){case 44:r.NumberFmt[e[0]]=e[1],En(e[1],e[0]);break;case 43:r.Fonts.push(e),null!=e.color.theme&&t&&t.themeElements&&t.themeElements.clrScheme&&(e.color.rgb=oo(t.themeElements.clrScheme[e.color.theme].rgb,e.color.tint||0));break;case 1025:case 45:case 46:case 48:case 507:case 572:case 475:case 1171:case 2102:case 1130:case 512:case 2095:case 3072:break;case 47:617==a[a.length-1]&&r.CellXf.push(e);break;case 35:s=!0;break;case 36:s=!1;break;case 37:a.push(o),s=!0;break;case 38:a.pop(),s=!1;break;default:if(i.T>0)a.push(o);else if(i.T<0)a.pop();else if(!s||n.WTF&&37!=a[a.length-1])throw new Error("Unexpected record 0x"+o.toString(16))}})),r}(e,n,r):ko(e,n,r)}function bc(e,t,n){return".bin"===t.slice(-4)?function(e,t){var n=[],r=!1;return Si(e,(function(e,i,a){switch(a){case 159:n.Count=e[0],n.Unique=e[1];break;case 19:n.push(e);break;case 160:return!0;case 35:r=!0;break;case 36:r=!1;break;default:if(i.T,!r||t.WTF)throw new Error("Unexpected record 0x"+a.toString(16))}})),n}(e,n):function(e,t){var n=[],r="";if(!e)return n;var i=e.match(Hs);if(i){r=i[2].replace(Ws,"").split($s);for(var a=0;a!=r.length;++a){var s=Us(r[a].trim(),t);null!=s&&(n[n.length]=s)}i=pr(i[1]),n.Count=i.count,n.Unique=i.uniqueCount}return n}(e,n)}function yc(e,t,n){return".bin"===t.slice(-4)?function(e,t){var n=[],r=[],i={},a=!1;return Si(e,(function(e,s,o){switch(o){case 632:r.push(e);break;case 635:i=e;break;case 637:i.t=e.t,i.h=e.h,i.r=e.r;break;case 636:if(i.author=r[i.iauthor],delete i.iauthor,t.sheetRows&&i.rfx&&t.sheetRows<=i.rfx.r)break;i.t||(i.t=""),delete i.rfx,n.push(i);break;case 3072:case 37:case 38:break;case 35:a=!0;break;case 36:a=!1;break;default:if(s.T);else if(!a||t.WTF)throw new Error("Unexpected record 0x"+o.toString(16))}})),n}(e,n):function(e,t){if(e.match(/<(?:\w+:)?comments *\/>/))return[];var n=[],r=[],i=e.match(/<(?:\w+:)?authors>([\s\S]*)<\/(?:\w+:)?authors>/);i&&i[1]&&i[1].split(/<\/\w*:?author>/).forEach((function(e){if(""!==e&&""!==e.trim()){var t=e.match(/<(?:\w+:)?author[^>]*>(.*)/);t&&n.push(t[1])}}));var a=e.match(/<(?:\w+:)?commentList>([\s\S]*)<\/(?:\w+:)?commentList>/);return a&&a[1]&&a[1].split(/<\/\w*:?comment>/).forEach((function(e){if(""!==e&&""!==e.trim()){var i=e.match(/<(?:\w+:)?comment[^>]*>/);if(i){var a=pr(i[0]),s={author:a.authorId&&n[a.authorId]||"sheetjsghost",ref:a.ref,guid:a.guid},o=Ni(a.ref);if(!(t.sheetRows&&t.sheetRows<=o.r)){var l=e.match(/<(?:\w+:)?text>([\s\S]*)<\/(?:\w+:)?text>/),c=!!l&&!!l[1]&&Us(l[1])||{r:"",t:"",h:""};s.r=c.r,""==c.r&&(c.t=c.h=""),s.t=(c.t||"").replace(/\r\n/g,"\n").replace(/\r/g,"\n"),t.cellHTML&&(s.h=c.h),r.push(s)}}}})),r}(e,n)}function xc(e,t,n){return".bin"===t.slice(-4)?function(e,t,n){var r=[];return Si(e,(function(e,t,n){if(63===n)r.push(e);else if(!t.T)throw new Error("Unexpected record 0x"+n.toString(16))})),r}(e):function(e){var t=[];if(!e)return t;var n=1;return(e.match(hr)||[]).forEach((function(e){var r=pr(e);switch(r[0]){case"":case"":break;case"":case"":case"":case"":case"":case"":case"":case"":case"":case"":break;case"":case"":s=2;break;case"":a=!1;break;case"-1?br(t||e).replace(/<.*?>/g,""):r.r;break;case"DateTime":"Z"!=e.slice(-1)&&(e+="Z"),r.v=(Hn(e)-new Date(Date.UTC(1899,11,30)))/864e5,r.v!==r.v?r.v=br(e):r.v<60&&(r.v=r.v-1),u&&"General"!=u||(u="yyyy-mm-dd");case"Number":void 0===r.v&&(r.v=+e),r.t||(r.t="n");break;case"Error":r.t="e",r.v=xa[e],!1!==c.cellText&&(r.w=e);break;default:""==e&&""==t?r.t="z":(r.t="s",r.v=_r(t||e))}if(Mc(r,u,c),!1!==c.cellFormula)if(r.Formula){var m=br(r.Formula);61==m.charCodeAt(0)&&(m=m.slice(1)),r.f=Ho(m,i),delete r.Formula,"RC"==r.ArrayRange?r.F=Ho("RC:RC",i):r.ArrayRange&&(r.F=Ho(r.ArrayRange,i),l.push([ji(r.F),r.F]))}else for(p=0;p=l[p][0].s.r&&i.r<=l[p][0].e.r&&i.c>=l[p][0].s.c&&i.c<=l[p][0].e.c&&(r.F=l[p][1]);c.cellStyles&&(d.forEach((function(e){!f.patternType&&e.patternType&&(f.patternType=e.patternType)})),r.s=f),void 0!==r.StyleID&&(r.ixfe=r.StyleID)}function Rc(e){e.t=e.v||"",e.t=e.t.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),e.v=e.w=e.ixfe=void 0}function Dc(e,t){var n=t||{};kn();var r=bt(Br(e));"binary"!=n.type&&"array"!=n.type&&"base64"!=n.type||(r="undefined"!==typeof vt?vt.utils.decode(65001,mt(r)):Ar(r));var i,a=r.slice(0,1024).toLowerCase(),s=!1;if((1023&(a=a.replace(/".*?"/g,"")).indexOf(">"))>Math.min(1023&a.indexOf(","),1023&a.indexOf(";"))){var o=$n(n);return o.type="string",Is.to_workbook(r,o)}if(-1==a.indexOf("=0&&(s=!0)})),s)return function(e,t){var n=e.match(/[\s\S]*?<\/table>/gi);if(!n||0==n.length)throw new Error("Invalid HTML: could not find ");if(1==n.length)return Hi(Gc(n[0],t),t);var r={SheetNames:[],Sheets:{}};return n.forEach((function(e,n){Wu(r,Gc(e,t),"Sheet"+(n+1))})),r}(r,n);Tc={"General Number":"General","General Date":Wt[22],"Long Date":"dddd, mmmm dd, yyyy","Medium Date":Wt[15],"Short Date":Wt[14],"Long Time":Wt[19],"Medium Time":Wt[18],"Short Time":Wt[20],Currency:'"$"#,##0.00_);[Red]\\("$"#,##0.00\\)',Fixed:Wt[2],Standard:Wt[4],Percent:Wt[10],Scientific:Wt[11],"Yes/No":'"Yes";"Yes";"No";@',"True/False":'"True";"True";"False";@',"On/Off":'"Yes";"Yes";"No";@'};var l,c=[];null!=wt&&null==n.dense&&(n.dense=wt);var u,h={},f=[],d=n.dense?[]:{},p="",m={},g={},v=Sc(''),b=0,y=0,x=0,w={s:{r:2e6,c:2e6},e:{r:0,c:0}},_={},T={},E="",k=0,S=[],C={},A={},M=0,P=[],O=[],R={},D=[],L=!1,I=[],N=[],F={},z=0,B=0,j={Sheets:[],WBProps:{date1904:!1}},V={};jr.lastIndex=0,r=r.replace(//gm,"");for(var U="";i=jr.exec(r);)switch(i[3]=(U=i[3]).toLowerCase()){case"data":if("data"==U){if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else"/"!==i[0].charAt(i[0].length-2)&&c.push([i[3],!0]);break}if(c[c.length-1][1])break;"/"===i[1]?Oc(r.slice(b,i.index),E,v,"comment"==c[c.length-1][0]?R:m,{c:y,r:x},_,D[y],g,I,n):(E="",v=Sc(i[0]),b=i.index+i[0].length);break;case"cell":if("/"===i[1])if(O.length>0&&(m.c=O),(!n.sheetRows||n.sheetRows>x)&&void 0!==m.v&&(n.dense?(d[x]||(d[x]=[]),d[x][y]=m):d[Ii(y)+Di(x)]=m),m.HRef&&(m.l={Target:br(m.HRef)},m.HRefScreenTip&&(m.l.Tooltip=m.HRefScreenTip),delete m.HRef,delete m.HRefScreenTip),(m.MergeAcross||m.MergeDown)&&(z=y+(0|parseInt(m.MergeAcross,10)),B=x+(0|parseInt(m.MergeDown,10)),S.push({s:{c:y,r:x},e:{c:z,r:B}})),n.sheetStubs)if(m.MergeAcross||m.MergeDown){for(var H=y;H<=z;++H)for(var W=x;W<=B;++W)(H>y||W>x)&&(n.dense?(d[W]||(d[W]=[]),d[W][H]={t:"z"}):d[Ii(H)+Di(W)]={t:"z"});y=z+1}else++y;else m.MergeAcross?y=z+1:++y;else(m=Cc(i[0])).Index&&(y=+m.Index-1),yw.e.c&&(w.e.c=y),"/>"===i[0].slice(-2)&&++y,O=[];break;case"row":"/"===i[1]||"/>"===i[0].slice(-2)?(xw.e.r&&(w.e.r=x),"/>"===i[0].slice(-2)&&(g=Sc(i[0])).Index&&(x=+g.Index-1),y=0,++x):((g=Sc(i[0])).Index&&(x=+g.Index-1),F={},("0"==g.AutoFitHeight||g.Height)&&(F.hpx=parseInt(g.Height,10),F.hpt=xo(F.hpx),N[x]=F),"1"==g.Hidden&&(F.hidden=!0,N[x]=F));break;case"worksheet":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"));f.push(p),w.s.r<=w.e.r&&w.s.c<=w.e.c&&(d["!ref"]=Bi(w),n.sheetRows&&n.sheetRows<=w.e.r&&(d["!fullref"]=d["!ref"],w.e.r=n.sheetRows-1,d["!ref"]=Bi(w))),S.length&&(d["!merges"]=S),D.length>0&&(d["!cols"]=D),N.length>0&&(d["!rows"]=N),h[p]=d}else w={s:{r:2e6,c:2e6},e:{r:0,c:0}},x=y=0,c.push([i[3],!1]),l=Sc(i[0]),p=br(l.Name),d=n.dense?[]:{},S=[],I=[],N=[],V={name:p,Hidden:0},j.Sheets.push(V);break;case"table":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else{if("/>"==i[0].slice(-2))break;c.push([i[3],!1]),D=[],L=!1}break;case"style":"/"===i[1]?Pc(_,T,n):T=Sc(i[0]);break;case"numberformat":T.nf=br(Sc(i[0]).Format||"General"),Tc[T.nf]&&(T.nf=Tc[T.nf]);for(var $=0;392!=$&&Wt[$]!=T.nf;++$);if(392==$)for($=57;392!=$;++$)if(null==Wt[$]){En(T.nf,$);break}break;case"column":if("table"!==c[c.length-1][0])break;if((u=Sc(i[0])).Hidden&&(u.hidden=!0,delete u.Hidden),u.Width&&(u.wpx=parseInt(u.Width,10)),!L&&u.wpx>10){L=!0,ho=lo;for(var G=0;G0&&(X.Sheet=j.Sheets.length-1),j.Names.push(X);break;case"namedcell":case"b":case"i":case"u":case"s":case"em":case"h2":case"h3":case"sub":case"sup":case"span":case"alignment":case"borders":case"border":case"protection":case"paragraphs":case"name":case"pixelsperinch":case"null":break;case"font":if("/>"===i[0].slice(-2))break;"/"===i[1]?E+=r.slice(k,i.index):k=i.index+i[0].length;break;case"interior":if(!n.cellStyles)break;T.Interior=Sc(i[0]);break;case"author":case"title":case"description":case"created":case"keywords":case"subject":case"category":case"company":case"lastauthor":case"lastsaved":case"lastprinted":case"version":case"revision":case"totaltime":case"hyperlinkbase":case"manager":case"contentstatus":case"identifier":case"language":case"appname":if("/>"===i[0].slice(-2))break;"/"===i[1]?La(C,U,r.slice(M,i.index)):M=i.index+i[0].length;break;case"styles":case"workbook":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else c.push([i[3],!1]);break;case"comment":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"));Rc(R),O.push(R)}else c.push([i[3],!1]),R={a:(l=Sc(i[0])).Author};break;case"autofilter":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else if("/"!==i[0].charAt(i[0].length-2)){var q=Sc(i[0]);d["!autofilter"]={ref:Ho(q.Range).replace(/\$/g,"")},c.push([i[3],!0])}break;case"datavalidation":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else"/"!==i[0].charAt(i[0].length-2)&&c.push([i[3],!0]);break;case"componentoptions":case"documentproperties":case"customdocumentproperties":case"officedocumentsettings":case"pivottable":case"pivotcache":case"names":case"mapinfo":case"pagebreaks":case"querytable":case"sorting":case"schema":case"conditionalformatting":case"smarttagtype":case"smarttags":case"excelworkbook":case"workbookoptions":case"worksheetoptions":if("/"===i[1]){if((l=c.pop())[0]!==i[3])throw new Error("Bad state: "+l.join("|"))}else"/"!==i[0].charAt(i[0].length-2)&&c.push([i[3],!0]);break;default:if(0==c.length&&"document"==i[3])return au(r,n);if(0==c.length&&"uof"==i[3])return au(r,n);var Z=!0;switch(c[c.length-1][0]){case"officedocumentsettings":switch(i[3]){case"allowpng":case"removepersonalinformation":case"downloadcomponents":case"locationofcomponents":case"colors":case"color":case"index":case"rgb":case"targetscreensize":case"readonlyrecommended":break;default:Z=!1}break;case"componentoptions":switch(i[3]){case"toolbar":case"hideofficelogo":case"spreadsheetautofit":case"label":case"caption":case"maxheight":case"maxwidth":case"nextsheetnumber":break;default:Z=!1}break;case"excelworkbook":switch(i[3]){case"date1904":j.WBProps.date1904=!0;break;case"windowheight":case"windowwidth":case"windowtopx":case"windowtopy":case"tabratio":case"protectstructure":case"protectwindow":case"protectwindows":case"activesheet":case"displayinknotes":case"firstvisiblesheet":case"supbook":case"sheetname":case"sheetindex":case"sheetindexfirst":case"sheetindexlast":case"dll":case"acceptlabelsinformulas":case"donotsavelinkvalues":case"iteration":case"maxiterations":case"maxchange":case"path":case"xct":case"count":case"selectedsheets":case"calculation":case"uncalced":case"startupprompt":case"crn":case"externname":case"formula":case"colfirst":case"collast":case"wantadvise":case"boolean":case"error":case"text":case"ole":case"noautorecover":case"publishobjects":case"donotcalculatebeforesave":case"number":case"refmoder1c1":case"embedsavesmarttags":break;default:Z=!1}break;case"workbookoptions":switch(i[3]){case"owcversion":case"height":case"width":break;default:Z=!1}break;case"worksheetoptions":switch(i[3]){case"visible":if("/>"===i[0].slice(-2));else if("/"===i[1])switch(r.slice(M,i.index)){case"SheetHidden":V.Hidden=1;break;case"SheetVeryHidden":V.Hidden=2}else M=i.index+i[0].length;break;case"header":d["!margins"]||Nl(d["!margins"]={},"xlml"),isNaN(+pr(i[0]).Margin)||(d["!margins"].header=+pr(i[0]).Margin);break;case"footer":d["!margins"]||Nl(d["!margins"]={},"xlml"),isNaN(+pr(i[0]).Margin)||(d["!margins"].footer=+pr(i[0]).Margin);break;case"pagemargins":var Q=pr(i[0]);d["!margins"]||Nl(d["!margins"]={},"xlml"),isNaN(+Q.Top)||(d["!margins"].top=+Q.Top),isNaN(+Q.Left)||(d["!margins"].left=+Q.Left),isNaN(+Q.Right)||(d["!margins"].right=+Q.Right),isNaN(+Q.Bottom)||(d["!margins"].bottom=+Q.Bottom);break;case"displayrighttoleft":j.Views||(j.Views=[]),j.Views[0]||(j.Views[0]={}),j.Views[0].RTL=!0;break;case"freezepanes":case"frozennosplit":case"splithorizontal":case"splitvertical":case"donotdisplaygridlines":case"activerow":case"activecol":case"toprowbottompane":case"leftcolumnrightpane":case"unsynced":case"print":case"printerrors":case"panes":case"scale":case"pane":case"number":case"layout":case"pagesetup":case"selected":case"protectobjects":case"enableselection":case"protectscenarios":case"validprinterinfo":case"horizontalresolution":case"verticalresolution":case"numberofcopies":case"activepane":case"toprowvisible":case"leftcolumnvisible":case"fittopage":case"rangeselection":case"papersizeindex":case"pagelayoutzoom":case"pagebreakzoom":case"filteron":case"fitwidth":case"fitheight":case"commentslayout":case"zoom":case"lefttoright":case"gridlines":case"allowsort":case"allowfilter":case"allowinsertrows":case"allowdeleterows":case"allowinsertcols":case"allowdeletecols":case"allowinserthyperlinks":case"allowformatcells":case"allowsizecols":case"allowsizerows":case"tabcolorindex":case"donotdisplayheadings":case"showpagelayoutzoom":case"blackandwhite":case"donotdisplayzeros":case"displaypagebreak":case"rowcolheadings":case"donotdisplayoutline":case"noorientation":case"allowusepivottables":case"zeroheight":case"viewablerange":case"selection":case"protectcontents":break;case"nosummaryrowsbelowdetail":d["!outline"]||(d["!outline"]={}),d["!outline"].above=!0;break;case"nosummarycolumnsrightdetail":d["!outline"]||(d["!outline"]={}),d["!outline"].left=!0;break;default:Z=!1}break;case"pivottable":case"pivotcache":switch(i[3]){case"immediateitemsondrop":case"showpagemultipleitemlabel":case"compactrowindent":case"location":case"pivotfield":case"orientation":case"layoutform":case"layoutsubtotallocation":case"layoutcompactrow":case"position":case"pivotitem":case"datatype":case"datafield":case"sourcename":case"parentfield":case"ptlineitems":case"ptlineitem":case"countofsameitems":case"item":case"itemtype":case"ptsource":case"cacheindex":case"consolidationreference":case"filename":case"reference":case"nocolumngrand":case"norowgrand":case"blanklineafteritems":case"hidden":case"subtotal":case"basefield":case"mapchilditems":case"function":case"refreshonfileopen":case"printsettitles":case"mergelabels":case"defaultversion":case"refreshname":case"refreshdate":case"refreshdatecopy":case"versionlastrefresh":case"versionlastupdate":case"versionupdateablemin":case"versionrefreshablemin":case"calculation":break;default:Z=!1}break;case"pagebreaks":switch(i[3]){case"colbreaks":case"colbreak":case"rowbreaks":case"rowbreak":case"colstart":case"colend":case"rowend":break;default:Z=!1}break;case"autofilter":switch(i[3]){case"autofiltercolumn":case"autofiltercondition":case"autofilterand":case"autofilteror":break;default:Z=!1}break;case"querytable":switch(i[3]){case"id":case"autoformatfont":case"autoformatpattern":case"querysource":case"querytype":case"enableredirections":case"refreshedinxl9":case"urlstring":case"htmltables":case"connection":case"commandtext":case"refreshinfo":case"notitles":case"nextid":case"columninfo":case"overwritecells":case"donotpromptforfile":case"textwizardsettings":case"source":case"number":case"decimal":case"thousandseparator":case"trailingminusnumbers":case"formatsettings":case"fieldtype":case"delimiters":case"tab":case"comma":case"autoformatname":case"versionlastedit":case"versionlastrefresh":break;default:Z=!1}break;case"datavalidation":switch(i[3]){case"range":case"type":case"min":case"max":case"sort":case"descending":case"order":case"casesensitive":case"value":case"errorstyle":case"errormessage":case"errortitle":case"inputmessage":case"inputtitle":case"combohide":case"inputhide":case"condition":case"qualifier":case"useblank":case"value1":case"value2":case"format":case"cellrangelist":break;default:Z=!1}break;case"sorting":case"conditionalformatting":switch(i[3]){case"range":case"type":case"min":case"max":case"sort":case"descending":case"order":case"casesensitive":case"value":case"errorstyle":case"errormessage":case"errortitle":case"cellrangelist":case"inputmessage":case"inputtitle":case"combohide":case"inputhide":case"condition":case"qualifier":case"useblank":case"value1":case"value2":case"format":break;default:Z=!1}break;case"mapinfo":case"schema":case"data":switch(i[3]){case"map":case"entry":case"range":case"xpath":case"field":case"xsdtype":case"filteron":case"aggregate":case"elementtype":case"attributetype":case"schema":case"element":case"complextype":case"datatype":case"all":case"attribute":case"extends":case"row":break;default:Z=!1}break;case"smarttags":break;default:Z=!1}if(Z)break;if(i[3].match(/!\[CDATA/))break;if(!c[c.length-1][1])throw"Unrecognized tag: "+i[3]+"|"+c.join("|");if("customdocumentproperties"===c[c.length-1][0]){if("/>"===i[0].slice(-2))break;"/"===i[1]?Ac(A,U,P,r.slice(M,i.index)):(P=i,M=i.index+i[0].length);break}if(n.WTF)throw"Unrecognized tag: "+i[3]+"|"+c.join("|")}var J={};return n.bookSheets||n.bookProps||(J.Sheets=h),J.SheetNames=f,J.Workbook=j,J.SSF=$n(Wt),J.Props=C,J.Custprops=A,J}function Lc(e,t){switch(Su(t=t||{}),t.type||"base64"){case"base64":return Dc(Et(e),t);case"binary":case"buffer":case"file":return Dc(e,t);case"array":return Dc(Pt(e),t)}}function Ic(e){var t={},n=e.content;if(n.l=28,t.AnsiUserType=n.read_shift(0,"lpstr-ansi"),t.AnsiClipboardFormat=function(e){return sa(e,1)}(n),n.length-n.l<=4)return t;var r=n.read_shift(4);return 0==r||r>40?t:(n.l-=4,t.Reserved1=n.read_shift(0,"lpstr-ansi"),n.length-n.l<=4||1907505652!==(r=n.read_shift(4))?t:(t.UnicodeClipboardFormat=function(e){return sa(e,2)}(n),0==(r=n.read_shift(4))||r>40?t:(n.l-=4,void(t.Reserved2=n.read_shift(0,"lpwstr")))))}var Nc=[60,1084,2066,2165,2175];function Fc(e,t,n,r,i){var a=r,s=[],o=n.slice(n.l,n.l+a);if(i&&i.enc&&i.enc.insitu&&o.length>0)switch(e){case 9:case 521:case 1033:case 2057:case 47:case 405:case 225:case 406:case 312:case 404:case 10:case 133:break;default:i.enc.insitu(o)}s.push(o),n.l+=a;for(var l=fi(n,n.l),c=Wc[l],u=0;null!=c&&Nc.indexOf(l)>-1;)a=fi(n,n.l+2),u=n.l+4,2066==l?u+=4:2165!=l&&2175!=l||(u+=12),o=n.slice(u,n.l+4+a),s.push(o),n.l+=4+a,c=Wc[l=fi(n,n.l)];var h=Rt(s);Ti(h,0);var f=0;h.lens=[];for(var d=0;d1)&&!(n.sheetRows&&e.r>=n.sheetRows)){if(n.cellStyles&&t.XF&&t.XF.data&&function(e,t,n){var r,i=t.XF.data;i&&i.patternType&&n&&n.cellStyles&&(t.s={},t.s.patternType=i.patternType,(r=so(S(i.icvFore)))&&(t.s.fgColor={rgb:r}),(r=so(S(i.icvBack)))&&(t.s.bgColor={rgb:r}))}(0,t,n),delete t.ixfe,delete t.XF,i=e,y=Fi(e),p&&p.s&&p.e||(p={s:{r:0,c:0},e:{r:0,c:0}}),e.rp.e.r&&(p.e.r=e.r+1),e.c+1>p.e.c&&(p.e.c=e.c+1),n.cellFormula&&t.f)for(var r=0;re.c||w[r][0].s.r>e.r)&&!(w[r][0].e.c>8)!==H)throw new Error("rt mismatch: "+G+"!="+H);12==$.r&&(e.l+=10,W-=10)}var K={};if(K=10===H?$.f(e,W,A):Fc(H,$,e,W,A),0==F&&-1===[9,521,1033,2057].indexOf(N))continue;switch(H){case 34:n.opts.Date1904=E.WBProps.date1904=K;break;case 134:n.opts.WriteProtect=!0;break;case 47:if(A.enc||(e.l=0),A.enc=K,!t.password)throw new Error("File is password-protected");if(null==K.valid)throw new Error("Encryption scheme unsupported");if(!K.valid)throw new Error("Password is incorrect");break;case 92:A.lastuser=K;break;case 66:var Y=Number(K);switch(Y){case 21010:Y=1200;break;case 32768:Y=1e4;break;case 32769:Y=1252}dt(A.codepage=Y),V=!0;break;case 317:A.rrtabid=K;break;case 25:A.winlocked=K;break;case 439:n.opts.RefreshAll=K;break;case 12:n.opts.CalcCount=K;break;case 16:n.opts.CalcDelta=K;break;case 17:n.opts.CalcIter=K;break;case 13:n.opts.CalcMode=K;break;case 14:n.opts.CalcPrecision=K;break;case 95:n.opts.CalcSaveRecalc=K;break;case 15:A.CalcRefMode=K;break;case 2211:n.opts.FullCalc=K;break;case 129:K.fDialog&&(f["!type"]="dialog"),K.fBelow||((f["!outline"]||(f["!outline"]={})).above=!0),K.fRight||((f["!outline"]||(f["!outline"]={})).left=!0);break;case 224:_.push(K);break;case 430:L.push([K]),L[L.length-1].XTI=[];break;case 35:case 547:L[L.length-1].push(K);break;case 24:case 536:I={Name:K.Name,Ref:xl(K.rgce,0,null,L,A)},K.itab>0&&(I.Sheet=K.itab-1),L.names.push(I),L[0]||(L[0]=[],L[0].XTI=[]),L[L.length-1].push(K),"_xlnm._FilterDatabase"==K.Name&&K.itab>0&&K.rgce&&K.rgce[0]&&K.rgce[0][0]&&"PtgArea3d"==K.rgce[0][0][0]&&(j[K.itab-1]={ref:Bi(K.rgce[0][0][1][2])});break;case 22:A.ExternCount=K;break;case 23:0==L.length&&(L[0]=[],L[0].XTI=[]),L[L.length-1].XTI=L[L.length-1].XTI.concat(K),L.XTI=L.XTI.concat(K);break;case 2196:if(A.biff<8)break;null!=I&&(I.Comment=K[1]);break;case 18:f["!protect"]=K;break;case 19:0!==K&&A.WTF&&console.error("Password verifier: "+K);break;case 133:d[K.pos]=K,A.snames.push(K.name);break;case 10:if(--F)break;if(p.e){if(p.e.r>0&&p.e.c>0){if(p.e.r--,p.e.c--,f["!ref"]=Bi(p),t.sheetRows&&t.sheetRows<=p.e.r){var X=p.e.r;p.e.r=t.sheetRows-1,f["!fullref"]=f["!ref"],f["!ref"]=Bi(p),p.e.r=X}p.e.r++,p.e.c++}M.length>0&&(f["!merges"]=M),P.length>0&&(f["!objects"]=P),O.length>0&&(f["!cols"]=O),R.length>0&&(f["!rows"]=R),E.Sheets.push(k)}""===v?b=f:r[v]=f,f=t.dense?[]:{};break;case 9:case 521:case 1033:case 2057:if(8===A.biff&&(A.biff={9:2,521:3,1033:4}[H]||{512:2,768:3,1024:4,1280:5,1536:8,2:2,7:2}[K.BIFFVer]||8),A.biffguess=0==K.BIFFVer,0==K.BIFFVer&&4096==K.dt&&(A.biff=5,V=!0,dt(A.codepage=28591)),8==A.biff&&0==K.BIFFVer&&16==K.dt&&(A.biff=2),F++)break;if(f=t.dense?[]:{},A.biff<8&&!V&&(V=!0,dt(A.codepage=t.codepage||1252)),A.biff<5||0==K.BIFFVer&&4096==K.dt){""===v&&(v="Sheet1"),p={s:{r:0,c:0},e:{r:0,c:0}};var q={pos:e.l-W,name:v};d[q.pos]=q,A.snames.push(v)}else v=(d[U]||{name:""}).name;32==K.dt&&(f["!type"]="chart"),64==K.dt&&(f["!type"]="macro"),M=[],P=[],A.arrayf=w=[],O=[],R=[],D=!1,k={Hidden:(d[U]||{hs:0}).hs,name:v};break;case 515:case 3:case 2:"chart"==f["!type"]&&(t.dense?(f[K.r]||[])[K.c]:f[Fi({c:K.c,r:K.r})])&&++K.c,c={ixfe:K.ixfe,XF:_[K.ixfe]||{},v:K.val,t:"n"},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t);break;case 5:case 517:c={ixfe:K.ixfe,XF:_[K.ixfe],v:K.val,t:K.t},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t);break;case 638:c={ixfe:K.ixfe,XF:_[K.ixfe],v:K.rknum,t:"n"},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t);break;case 189:for(var Z=K.c;Z<=K.C;++Z){var Q=K.rkrec[Z-K.c][0];c={ixfe:Q,XF:_[Q],v:K.rkrec[Z-K.c][1],t:"n"},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:Z,r:K.r},c,t)}break;case 6:case 518:case 1030:if("String"==K.val){m=K;break}if((c=Bc(K.val,K.cell.ixfe,K.tt)).XF=_[c.ixfe],t.cellFormula){var J=K.formula;if(J&&J[0]&&J[0][0]&&"PtgExp"==J[0][0][0]){var ee=J[0][0][1][0],te=J[0][0][1][1],ne=Fi({r:ee,c:te});x[ne]?c.f=""+xl(K.formula,0,K.cell,L,A):c.F=((t.dense?(f[ee]||[])[te]:f[ne])||{}).F}else c.f=""+xl(K.formula,0,K.cell,L,A)}z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C(K.cell,c,t),m=K;break;case 7:case 519:if(!m)throw new Error("String record expects Formula");m.val=K,(c=Bc(K,m.cell.ixfe,"s")).XF=_[c.ixfe],t.cellFormula&&(c.f=""+xl(m.formula,0,m.cell,L,A)),z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C(m.cell,c,t),m=null;break;case 33:case 545:w.push(K);var re=Fi(K[0].s);if(a=t.dense?(f[K[0].s.r]||[])[K[0].s.c]:f[re],t.cellFormula&&a){if(!m)break;if(!re||!a)break;a.f=""+xl(K[1],0,K[0],L,A),a.F=Bi(K[0])}break;case 1212:if(!t.cellFormula)break;if(y){if(!m)break;x[Fi(m.cell)]=K[0],((a=t.dense?(f[m.cell.r]||[])[m.cell.c]:f[Fi(m.cell)])||{}).f=""+xl(K[0],0,i,L,A)}break;case 253:c=Bc(g[K.isst].t,K.ixfe,"s"),g[K.isst].h&&(c.h=g[K.isst].h),c.XF=_[c.ixfe],z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t);break;case 513:t.sheetStubs&&(c={ixfe:K.ixfe,XF:_[K.ixfe],t:"z"},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t));break;case 190:if(t.sheetStubs)for(var ie=K.c;ie<=K.C;++ie){var ae=K.ixfe[ie-K.c];c={ixfe:ae,XF:_[ae],t:"z"},z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:ie,r:K.r},c,t)}break;case 214:case 516:case 4:(c=Bc(K.val,K.ixfe,"s")).XF=_[c.ixfe],z>0&&(c.z=B[c.ixfe>>8&63]),zc(c,t,n.opts.Date1904),C({c:K.c,r:K.r},c,t);break;case 0:case 512:1===F&&(p=K);break;case 252:g=K;break;case 1054:if(4==A.biff){B[z++]=K[1];for(var se=0;se=163&&En(K[1],z+163)}else En(K[1],K[0]);break;case 30:B[z++]=K;for(var oe=0;oe=163&&En(K,z+163);break;case 229:M=M.concat(K);break;case 93:P[K.cmo[0]]=A.lastobj=K;break;case 438:A.lastobj.TxO=K;break;case 127:A.lastobj.ImData=K;break;case 440:for(l=K[0].s.r;l<=K[0].e.r;++l)for(o=K[0].s.c;o<=K[0].e.c;++o)(a=t.dense?(f[l]||[])[o]:f[Fi({c:o,r:l})])&&(a.l=K[1]);break;case 2048:for(l=K[0].s.r;l<=K[0].e.r;++l)for(o=K[0].s.c;o<=K[0].e.c;++o)(a=t.dense?(f[l]||[])[o]:f[Fi({c:o,r:l})])&&a.l&&(a.l.Tooltip=K[1]);break;case 28:if(A.biff<=5&&A.biff>=2)break;a=t.dense?(f[K[0].r]||[])[K[0].c]:f[Fi(K[0])];var le=P[K[2]];a||(t.dense?(f[K[0].r]||(f[K[0].r]=[]),a=f[K[0].r][K[0].c]={t:"z"}):a=f[Fi(K[0])]={t:"z"},p.e.r=Math.max(p.e.r,K[0].r),p.s.r=Math.min(p.s.r,K[0].r),p.e.c=Math.max(p.e.c,K[0].c),p.s.c=Math.min(p.s.c,K[0].c)),a.c||(a.c=[]),s={a:K[1],t:le.TxO.t},a.c.push(s);break;case 2173:_[K.ixfe],K.ext.forEach((function(e){e[0]}));break;case 125:if(!A.cellStyles)break;for(;K.e>=K.s;)O[K.e--]={width:K.w/256,level:K.level||0,hidden:!!(1&K.flags)},D||(D=!0,vo(K.w/256)),bo(O[K.e+1]);break;case 520:var ce={};null!=K.level&&(R[K.r]=ce,ce.level=K.level),K.hidden&&(R[K.r]=ce,ce.hidden=!0),K.hpt&&(R[K.r]=ce,ce.hpt=K.hpt,ce.hpx=wo(K.hpt));break;case 38:case 39:case 40:case 41:f["!margins"]||Nl(f["!margins"]={}),f["!margins"][{38:"left",39:"right",40:"top",41:"bottom"}[H]]=K;break;case 161:f["!margins"]||Nl(f["!margins"]={}),f["!margins"].header=K.header,f["!margins"].footer=K.footer;break;case 574:K.RTL&&(E.Views[0].RTL=!0);break;case 146:T=K;break;case 2198:h=K;break;case 140:u=K;break;case 442:v?k.CodeName=K||k.name:E.WBProps.CodeName=K||"ThisWorkbook"}}else $||console.error("Missing Info for XLS Record 0x"+H.toString(16)),e.l+=W}return n.SheetNames=On(d).sort((function(e,t){return Number(e)-Number(t)})).map((function(e){return d[e].name})),t.bookSheets||(n.Sheets=r),!n.SheetNames.length&&b["!ref"]?(n.SheetNames.push("Sheet1"),n.Sheets&&(n.Sheets.Sheet1=b)):n.Preamble=b,n.Sheets&&j.forEach((function(e,t){n.Sheets[n.SheetNames[t]]["!autofilter"]=e})),n.Strings=g,n.SSF=$n(Wt),A.enc&&(n.Encryption=A.enc),h&&(n.Themes=h),n.Metadata={},void 0!==u&&(n.Metadata.Country=u),L.names.length>0&&(E.Names=L.names),n.Workbook=E,n}var Vc={SI:"e0859ff2f94f6810ab9108002b27b3d9",DSI:"02d5cdd59c2e1b10939708002b2cf9ae",UDI:"05d5cdd59c2e1b10939708002b2cf9ae"};function Uc(e,t){var n,r,i,a;if(t||(t={}),Su(t),pt(),t.codepage&&ft(t.codepage),e.FullPaths){if(Mn.find(e,"/encryption"))throw new Error("File is password-protected");n=Mn.find(e,"!CompObj"),r=Mn.find(e,"/Workbook")||Mn.find(e,"/Book")}else{switch(t.type){case"base64":e=Mt(Et(e));break;case"binary":e=Mt(e);break;case"buffer":break;case"array":Array.isArray(e)||(e=Array.prototype.slice.call(e))}Ti(e,0),r={content:e}}if(n&&Ic(n),t.bookProps&&!t.bookSheets)i={};else{var s=kt?"buffer":"array";if(r&&r.content)i=jc(r.content,t);else if((a=Mn.find(e,"PerfectOffice_MAIN"))&&a.content)i=Ns.to_workbook(a.content,(t.type=s,t));else{if(!(a=Mn.find(e,"NativeContent_MAIN"))||!a.content)throw(a=Mn.find(e,"MN0"))&&a.content?new Error("Unsupported Works 4 for Mac file"):new Error("Cannot find Workbook stream");i=Ns.to_workbook(a.content,(t.type=s,t))}t.bookVBA&&e.FullPaths&&Mn.find(e,"/_VBA_PROJECT_CUR/VBA/dir")&&(i.vbaraw=function(e){var t=Mn.utils.cfb_new({root:"R"});return e.FullPaths.forEach((function(n,r){if("/"!==n.slice(-1)&&n.match(/_VBA_PROJECT_CUR/)){var i=n.replace(/^[^\/]*/,"R").replace(/\/_VBA_PROJECT_CUR\u0000*/,"");Mn.utils.cfb_add(t,i,e.FileIndex[r].content)}})),Mn.write(t)}(e))}var o={};return e.FullPaths&&function(e,t,n){var r=Mn.find(e,"/!DocumentSummaryInformation");if(r&&r.size>0)try{var i=$a(r,da,Vc.DSI);for(var a in i)t[a]=i[a]}catch(kC){if(n.WTF)throw kC}var s=Mn.find(e,"/!SummaryInformation");if(s&&s.size>0)try{var o=$a(s,pa,Vc.SI);for(var l in o)null==t[l]&&(t[l]=o[l])}catch(kC){if(n.WTF)throw kC}t.HeadingPairs&&t.TitlesOfParts&&(Pa(t.HeadingPairs,t.TitlesOfParts,t,n),delete t.HeadingPairs,delete t.TitlesOfParts)}(e,o,t),i.Props=i.Custprops=o,t.bookFiles&&(i.cfb=e),i}var Hc={0:{f:function(e,t){var n={},r=e.l+t;n.r=e.read_shift(4),e.l+=4;var i=e.read_shift(2);e.l+=1;var a=e.read_shift(1);return e.l=r,7&a&&(n.level=7&a),16&a&&(n.hidden=!0),32&a&&(n.hpt=i/20),n}},1:{f:function(e){return[qi(e)]}},2:{f:function(e){return[qi(e),na(e),"n"]}},3:{f:function(e){return[qi(e),e.read_shift(1),"e"]}},4:{f:function(e){return[qi(e),e.read_shift(1),"b"]}},5:{f:function(e){return[qi(e),aa(e),"n"]}},6:{f:function(e){return[qi(e),Gi(e),"str"]}},7:{f:function(e){return[qi(e),e.read_shift(4),"s"]}},8:{f:function(e,t,n){var r=e.l+t,i=qi(e);i.r=n["!row"];var a=[i,Gi(e),"str"];if(n.cellFormula){e.l+=2;var s=Sl(e,r-e.l,n);a[3]=xl(s,0,i,n.supbooks,n)}else e.l=r;return a}},9:{f:function(e,t,n){var r=e.l+t,i=qi(e);i.r=n["!row"];var a=[i,aa(e),"n"];if(n.cellFormula){e.l+=2;var s=Sl(e,r-e.l,n);a[3]=xl(s,0,i,n.supbooks,n)}else e.l=r;return a}},10:{f:function(e,t,n){var r=e.l+t,i=qi(e);i.r=n["!row"];var a=[i,e.read_shift(1),"b"];if(n.cellFormula){e.l+=2;var s=Sl(e,r-e.l,n);a[3]=xl(s,0,i,n.supbooks,n)}else e.l=r;return a}},11:{f:function(e,t,n){var r=e.l+t,i=qi(e);i.r=n["!row"];var a=[i,e.read_shift(1),"e"];if(n.cellFormula){e.l+=2;var s=Sl(e,r-e.l,n);a[3]=xl(s,0,i,n.supbooks,n)}else e.l=r;return a}},12:{f:function(e){return[Zi(e)]}},13:{f:function(e){return[Zi(e),na(e),"n"]}},14:{f:function(e){return[Zi(e),e.read_shift(1),"e"]}},15:{f:function(e){return[Zi(e),e.read_shift(1),"b"]}},16:{f:Jl},17:{f:function(e){return[Zi(e),Gi(e),"str"]}},18:{f:function(e){return[Zi(e),e.read_shift(4),"s"]}},19:{f:Yi},20:{},21:{},22:{},23:{},24:{},25:{},26:{},27:{},28:{},29:{},30:{},31:{},32:{},33:{},34:{},35:{T:1},36:{T:-1},37:{T:1},38:{T:-1},39:{f:function(e,t,n){var r=e.l+t;e.l+=4,e.l+=1;var i=e.read_shift(4),a=ea(e),s=Cl(e,0,n),o=Ji(e);e.l=r;var l={Name:a,Ptg:s};return i<268435455&&(l.Sheet=i),o&&(l.Comment=o),l}},40:{},42:{},43:{f:function(e,t,n){var r={};r.sz=e.read_shift(2)/20;var i=function(e){var t=e.read_shift(1);return e.l++,{fBold:1&t,fItalic:2&t,fUnderline:4&t,fStrikeout:8&t,fOutline:16&t,fShadow:32&t,fCondense:64&t,fExtend:128&t}}(e);switch(i.fItalic&&(r.italic=1),i.fCondense&&(r.condense=1),i.fExtend&&(r.extend=1),i.fShadow&&(r.shadow=1),i.fOutline&&(r.outline=1),i.fStrikeout&&(r.strike=1),700===e.read_shift(2)&&(r.bold=1),e.read_shift(2)){case 1:r.vertAlign="superscript";break;case 2:r.vertAlign="subscript"}var a=e.read_shift(1);0!=a&&(r.underline=a);var s=e.read_shift(1);s>0&&(r.family=s);var o=e.read_shift(1);switch(o>0&&(r.charset=o),e.l++,r.color=function(e){var t={},n=e.read_shift(1)>>>1,r=e.read_shift(1),i=e.read_shift(2,"i"),a=e.read_shift(1),s=e.read_shift(1),o=e.read_shift(1);switch(e.l++,n){case 0:t.auto=1;break;case 1:t.index=r;var l=ba[r];l&&(t.rgb=so(l));break;case 2:t.rgb=so([a,s,o]);break;case 3:t.theme=r}return 0!=i&&(t.tint=i>0?i/32767:i/32768),t}(e),e.read_shift(1)){case 1:r.scheme="major";break;case 2:r.scheme="minor"}return r.name=Gi(e),r}},44:{f:function(e,t){return[e.read_shift(2),Gi(e)]}},45:{f:So},46:{f:Co},47:{f:function(e,t){var n=e.l+t,r=e.read_shift(2),i=e.read_shift(2);return e.l=n,{ixfe:r,numFmtId:i}}},48:{},49:{f:function(e){return e.read_shift(4,"i")}},50:{},51:{f:function(e){for(var t=[],n=e.read_shift(4);n-- >0;)t.push([e.read_shift(4),e.read_shift(4)]);return t}},52:{T:1},53:{T:-1},54:{T:1},55:{T:-1},56:{T:1},57:{T:-1},58:{},59:{},60:{f:Ss},62:{f:function(e){return[qi(e),Yi(e),"is"]}},63:{f:function(e){var t={};t.i=e.read_shift(4);var n={};n.r=e.read_shift(4),n.c=e.read_shift(4),t.r=Fi(n);var r=e.read_shift(1);return 2&r&&(t.l="1"),8&r&&(t.a="1"),t}},64:{f:function(){}},65:{},66:{},67:{},68:{},69:{},70:{},128:{},129:{T:1},130:{T:-1},131:{T:1,f:Ei,p:0},132:{T:-1},133:{T:1},134:{T:-1},135:{T:1},136:{T:-1},137:{T:1,f:function(e){var t=e.read_shift(2);return e.l+=28,{RTL:32&t}}},138:{T:-1},139:{T:1},140:{T:-1},141:{T:1},142:{T:-1},143:{T:1},144:{T:-1},145:{T:1},146:{T:-1},147:{f:function(e,t){var n={},r=e[e.l];return++e.l,n.above=!(64&r),n.left=!(128&r),e.l+=18,n.name=Qi(e,t-19),n}},148:{f:Ql,p:16},151:{f:function(){}},152:{},153:{f:function(e,t){var n={},r=e.read_shift(4);n.defaultThemeVersion=e.read_shift(4);var i=t>8?Gi(e):"";return i.length>0&&(n.CodeName=i),n.autoCompressPictures=!!(65536&r),n.backupFile=!!(64&r),n.checkCompatibility=!!(4096&r),n.date1904=!!(1&r),n.filterPrivacy=!!(8&r),n.hidePivotFieldList=!!(1024&r),n.promptedSolutions=!!(16&r),n.publishItems=!!(2048&r),n.refreshAllConnections=!!(262144&r),n.saveExternalLinkValues=!!(128&r),n.showBorderUnselectedTables=!!(4&r),n.showInkAnnotation=!!(32&r),n.showObjects=["all","placeholders","none"][r>>13&3],n.showPivotChartFilter=!!(32768&r),n.updateLinks=["userSet","never","always"][r>>8&3],n}},154:{},155:{},156:{f:function(e,t){var n={};return n.Hidden=e.read_shift(4),n.iTabID=e.read_shift(4),n.strRelID=ta(e,t-8),n.name=Gi(e),n}},157:{},158:{},159:{T:1,f:function(e){return[e.read_shift(4),e.read_shift(4)]}},160:{T:-1},161:{T:1,f:ia},162:{T:-1},163:{T:1},164:{T:-1},165:{T:1},166:{T:-1},167:{},168:{},169:{},170:{},171:{},172:{T:1},173:{T:-1},174:{},175:{},176:{f:ec},177:{T:1},178:{T:-1},179:{T:1},180:{T:-1},181:{T:1},182:{T:-1},183:{T:1},184:{T:-1},185:{T:1},186:{T:-1},187:{T:1},188:{T:-1},189:{T:1},190:{T:-1},191:{T:1},192:{T:-1},193:{T:1},194:{T:-1},195:{T:1},196:{T:-1},197:{T:1},198:{T:-1},199:{T:1},200:{T:-1},201:{T:1},202:{T:-1},203:{T:1},204:{T:-1},205:{T:1},206:{T:-1},207:{T:1},208:{T:-1},209:{T:1},210:{T:-1},211:{T:1},212:{T:-1},213:{T:1},214:{T:-1},215:{T:1},216:{T:-1},217:{T:1},218:{T:-1},219:{T:1},220:{T:-1},221:{T:1},222:{T:-1},223:{T:1},224:{T:-1},225:{T:1},226:{T:-1},227:{T:1},228:{T:-1},229:{T:1},230:{T:-1},231:{T:1},232:{T:-1},233:{T:1},234:{T:-1},235:{T:1},236:{T:-1},237:{T:1},238:{T:-1},239:{T:1},240:{T:-1},241:{T:1},242:{T:-1},243:{T:1},244:{T:-1},245:{T:1},246:{T:-1},247:{T:1},248:{T:-1},249:{T:1},250:{T:-1},251:{T:1},252:{T:-1},253:{T:1},254:{T:-1},255:{T:1},256:{T:-1},257:{T:1},258:{T:-1},259:{T:1},260:{T:-1},261:{T:1},262:{T:-1},263:{T:1},264:{T:-1},265:{T:1},266:{T:-1},267:{T:1},268:{T:-1},269:{T:1},270:{T:-1},271:{T:1},272:{T:-1},273:{T:1},274:{T:-1},275:{T:1},276:{T:-1},277:{},278:{T:1},279:{T:-1},280:{T:1},281:{T:-1},282:{T:1},283:{T:1},284:{T:-1},285:{T:1},286:{T:-1},287:{T:1},288:{T:-1},289:{T:1},290:{T:-1},291:{T:1},292:{T:-1},293:{T:1},294:{T:-1},295:{T:1},296:{T:-1},297:{T:1},298:{T:-1},299:{T:1},300:{T:-1},301:{T:1},302:{T:-1},303:{T:1},304:{T:-1},305:{T:1},306:{T:-1},307:{T:1},308:{T:-1},309:{T:1},310:{T:-1},311:{T:1},312:{T:-1},313:{T:-1},314:{T:1},315:{T:-1},316:{T:1},317:{T:-1},318:{T:1},319:{T:-1},320:{T:1},321:{T:-1},322:{T:1},323:{T:-1},324:{T:1},325:{T:-1},326:{T:1},327:{T:-1},328:{T:1},329:{T:-1},330:{T:1},331:{T:-1},332:{T:1},333:{T:-1},334:{T:1},335:{f:function(e,t){return{flags:e.read_shift(4),version:e.read_shift(4),name:Gi(e)}}},336:{T:-1},337:{f:function(e){return e.l+=4,0!=e.read_shift(4)},T:1},338:{T:-1},339:{T:1},340:{T:-1},341:{T:1},342:{T:-1},343:{T:1},344:{T:-1},345:{T:1},346:{T:-1},347:{T:1},348:{T:-1},349:{T:1},350:{T:-1},351:{},352:{},353:{T:1},354:{T:-1},355:{f:ta},357:{},358:{},359:{},360:{T:1},361:{},362:{f:Ts},363:{},364:{},366:{},367:{},368:{},369:{},370:{},371:{},372:{T:1},373:{T:-1},374:{T:1},375:{T:-1},376:{T:1},377:{T:-1},378:{T:1},379:{T:-1},380:{T:1},381:{T:-1},382:{T:1},383:{T:-1},384:{T:1},385:{T:-1},386:{T:1},387:{T:-1},388:{T:1},389:{T:-1},390:{T:1},391:{T:-1},392:{T:1},393:{T:-1},394:{T:1},395:{T:-1},396:{},397:{},398:{},399:{},400:{},401:{T:1},403:{},404:{},405:{},406:{},407:{},408:{},409:{},410:{},411:{},412:{},413:{},414:{},415:{},416:{},417:{},418:{},419:{},420:{},421:{},422:{T:1},423:{T:1},424:{T:-1},425:{T:-1},426:{f:function(e,t,n){var r=e.l+t,i=ra(e),a=e.read_shift(1),s=[i];if(s[2]=a,n.cellFormula){var o=kl(e,r-e.l,n);s[1]=o}else e.l=r;return s}},427:{f:function(e,t,n){var r=e.l+t,i=[ia(e,16)];if(n.cellFormula){var a=Al(e,r-e.l,n);i[1]=a,e.l=r}else e.l=r;return i}},428:{},429:{T:1},430:{T:-1},431:{T:1},432:{T:-1},433:{T:1},434:{T:-1},435:{T:1},436:{T:-1},437:{T:1},438:{T:-1},439:{T:1},440:{T:-1},441:{T:1},442:{T:-1},443:{T:1},444:{T:-1},445:{T:1},446:{T:-1},447:{T:1},448:{T:-1},449:{T:1},450:{T:-1},451:{T:1},452:{T:-1},453:{T:1},454:{T:-1},455:{T:1},456:{T:-1},457:{T:1},458:{T:-1},459:{T:1},460:{T:-1},461:{T:1},462:{T:-1},463:{T:1},464:{T:-1},465:{T:1},466:{T:-1},467:{T:1},468:{T:-1},469:{T:1},470:{T:-1},471:{},472:{},473:{T:1},474:{T:-1},475:{},476:{f:function(e){var t={};return tc.forEach((function(n){t[n]=aa(e)})),t}},477:{},478:{},479:{T:1},480:{T:-1},481:{T:1},482:{T:-1},483:{T:1},484:{T:-1},485:{f:function(){}},486:{T:1},487:{T:-1},488:{T:1},489:{T:-1},490:{T:1},491:{T:-1},492:{T:1},493:{T:-1},494:{f:function(e,t){var n=e.l+t,r=ia(e,16),i=Ji(e),a=Gi(e),s=Gi(e),o=Gi(e);e.l=n;var l={rfx:r,relId:i,loc:a,display:o};return s&&(l.Tooltip=s),l}},495:{T:1},496:{T:-1},497:{T:1},498:{T:-1},499:{},500:{T:1},501:{T:-1},502:{T:1},503:{T:-1},504:{},505:{T:1},506:{T:-1},507:{},508:{T:1},509:{T:-1},510:{T:1},511:{T:-1},512:{},513:{},514:{T:1},515:{T:-1},516:{T:1},517:{T:-1},518:{T:1},519:{T:-1},520:{T:1},521:{T:-1},522:{},523:{},524:{},525:{},526:{},527:{},528:{T:1},529:{T:-1},530:{T:1},531:{T:-1},532:{T:1},533:{T:-1},534:{},535:{},536:{},537:{},538:{T:1},539:{T:-1},540:{T:1},541:{T:-1},542:{T:1},548:{},549:{},550:{f:ta},551:{},552:{},553:{},554:{T:1},555:{T:-1},556:{T:1},557:{T:-1},558:{T:1},559:{T:-1},560:{T:1},561:{T:-1},562:{},564:{},565:{T:1},566:{T:-1},569:{T:1},570:{T:-1},572:{},573:{T:1},574:{T:-1},577:{},578:{},579:{},580:{},581:{},582:{},583:{},584:{},585:{},586:{},587:{},588:{T:-1},589:{},590:{T:1},591:{T:-1},592:{T:1},593:{T:-1},594:{T:1},595:{T:-1},596:{},597:{T:1},598:{T:-1},599:{T:1},600:{T:-1},601:{T:1},602:{T:-1},603:{T:1},604:{T:-1},605:{T:1},606:{T:-1},607:{},608:{T:1},609:{T:-1},610:{},611:{T:1},612:{T:-1},613:{T:1},614:{T:-1},615:{T:1},616:{T:-1},617:{T:1},618:{T:-1},619:{T:1},620:{T:-1},625:{},626:{T:1},627:{T:-1},628:{T:1},629:{T:-1},630:{T:1},631:{T:-1},632:{f:Vo},633:{T:1},634:{T:-1},635:{T:1,f:function(e){var t={};t.iauthor=e.read_shift(4);var n=ia(e,16);return t.rfx=n.s,t.ref=Fi(n.s),e.l+=16,t}},636:{T:-1},637:{f:Xi},638:{T:1},639:{},640:{T:-1},641:{T:1},642:{T:-1},643:{T:1},644:{},645:{T:-1},646:{T:1},648:{T:1},649:{},650:{T:-1},651:{f:function(e,t){return e.l+=10,{name:Gi(e)}}},652:{},653:{T:1},654:{T:-1},655:{T:1},656:{T:-1},657:{T:1},658:{T:-1},659:{},660:{T:1},661:{},662:{T:-1},663:{},664:{T:1},665:{},666:{T:-1},667:{},668:{},669:{},671:{T:1},672:{T:-1},673:{T:1},674:{T:-1},675:{},676:{},677:{},678:{},679:{},680:{},681:{},1024:{},1025:{},1026:{T:1},1027:{T:-1},1028:{T:1},1029:{T:-1},1030:{},1031:{T:1},1032:{T:-1},1033:{T:1},1034:{T:-1},1035:{},1036:{},1037:{},1038:{T:1},1039:{T:-1},1040:{},1041:{T:1},1042:{T:-1},1043:{},1044:{},1045:{},1046:{T:1},1047:{T:-1},1048:{T:1},1049:{T:-1},1050:{},1051:{T:1},1052:{T:1},1053:{f:function(){}},1054:{T:1},1055:{},1056:{T:1},1057:{T:-1},1058:{T:1},1059:{T:-1},1061:{},1062:{T:1},1063:{T:-1},1064:{T:1},1065:{T:-1},1066:{T:1},1067:{T:-1},1068:{T:1},1069:{T:-1},1070:{T:1},1071:{T:-1},1072:{T:1},1073:{T:-1},1075:{T:1},1076:{T:-1},1077:{T:1},1078:{T:-1},1079:{T:1},1080:{T:-1},1081:{T:1},1082:{T:-1},1083:{T:1},1084:{T:-1},1085:{},1086:{T:1},1087:{T:-1},1088:{T:1},1089:{T:-1},1090:{T:1},1091:{T:-1},1092:{T:1},1093:{T:-1},1094:{T:1},1095:{T:-1},1096:{},1097:{T:1},1098:{},1099:{T:-1},1100:{T:1},1101:{T:-1},1102:{},1103:{},1104:{},1105:{},1111:{},1112:{},1113:{T:1},1114:{T:-1},1115:{T:1},1116:{T:-1},1117:{},1118:{T:1},1119:{T:-1},1120:{T:1},1121:{T:-1},1122:{T:1},1123:{T:-1},1124:{T:1},1125:{T:-1},1126:{},1128:{T:1},1129:{T:-1},1130:{},1131:{T:1},1132:{T:-1},1133:{T:1},1134:{T:-1},1135:{T:1},1136:{T:-1},1137:{T:1},1138:{T:-1},1139:{T:1},1140:{T:-1},1141:{},1142:{T:1},1143:{T:-1},1144:{T:1},1145:{T:-1},1146:{},1147:{T:1},1148:{T:-1},1149:{T:1},1150:{T:-1},1152:{T:1},1153:{T:-1},1154:{T:-1},1155:{T:-1},1156:{T:-1},1157:{T:1},1158:{T:-1},1159:{T:1},1160:{T:-1},1161:{T:1},1162:{T:-1},1163:{T:1},1164:{T:-1},1165:{T:1},1166:{T:-1},1167:{T:1},1168:{T:-1},1169:{T:1},1170:{T:-1},1171:{},1172:{T:1},1173:{T:-1},1177:{},1178:{T:1},1180:{},1181:{},1182:{},2048:{T:1},2049:{T:-1},2050:{},2051:{T:1},2052:{T:-1},2053:{},2054:{},2055:{T:1},2056:{T:-1},2057:{T:1},2058:{T:-1},2060:{},2067:{},2068:{T:1},2069:{T:-1},2070:{},2071:{},2072:{T:1},2073:{T:-1},2075:{},2076:{},2077:{T:1},2078:{T:-1},2079:{},2080:{T:1},2081:{T:-1},2082:{},2083:{T:1},2084:{T:-1},2085:{T:1},2086:{T:-1},2087:{T:1},2088:{T:-1},2089:{T:1},2090:{T:-1},2091:{},2092:{},2093:{T:1},2094:{T:-1},2095:{},2096:{T:1},2097:{T:-1},2098:{T:1},2099:{T:-1},2100:{T:1},2101:{T:-1},2102:{},2103:{T:1},2104:{T:-1},2105:{},2106:{T:1},2107:{T:-1},2108:{},2109:{T:1},2110:{T:-1},2111:{T:1},2112:{T:-1},2113:{T:1},2114:{T:-1},2115:{},2116:{},2117:{},2118:{T:1},2119:{T:-1},2120:{},2121:{T:1},2122:{T:-1},2123:{T:1},2124:{T:-1},2125:{},2126:{T:1},2127:{T:-1},2128:{},2129:{T:1},2130:{T:-1},2131:{T:1},2132:{T:-1},2133:{T:1},2134:{},2135:{},2136:{},2137:{T:1},2138:{T:-1},2139:{T:1},2140:{T:-1},2141:{},3072:{},3073:{},4096:{T:1},4097:{T:-1},5002:{T:1},5003:{T:-1},5081:{T:1},5082:{T:-1},5083:{},5084:{T:1},5085:{T:-1},5086:{T:1},5087:{T:-1},5088:{},5089:{},5090:{},5092:{T:1},5093:{T:-1},5094:{},5095:{T:1},5096:{T:-1},5097:{},5099:{},65535:{n:""}},Wc={6:{f:Tl},10:{f:Ga},12:{f:Ya},13:{f:Ya},14:{f:Ka},15:{f:Ka},16:{f:aa},17:{f:Ka},18:{f:Ka},19:{f:Ya},20:{f:ys},21:{f:ys},23:{f:Ts},24:{f:_s},25:{f:Ka},26:{},27:{},28:{f:function(e,t,n){return function(e,t,n){if(!(n.biff<8)){var r=e.read_shift(2),i=e.read_shift(2),a=e.read_shift(2),s=e.read_shift(2),o=es(e,0,n);return n.biff<8&&e.read_shift(1),[{r:r,c:i},o,s,a]}}(e,0,n)}},29:{},34:{f:Ka},35:{f:xs},38:{f:aa},39:{f:aa},40:{f:aa},41:{f:aa},42:{f:Ka},43:{f:Ka},47:{f:function(e,t,n){var r={Type:n.biff>=8?e.read_shift(2):0};return r.Type?io(e,t-2,r):function(e,t,n,r){var i={key:Ya(e),verificationBytes:Ya(e)};n.password&&(i.verifier=to(n.password)),r.valid=i.verificationBytes===i.verifier,r.valid&&(r.insitu=ro(n.password))}(e,n.biff,n,r),r}},49:{f:function(e,t,n){var r={dyHeight:e.read_shift(2),fl:e.read_shift(2)};switch(n&&n.biff||8){case 2:break;case 3:case 4:e.l+=2;break;default:e.l+=10}return r.name=qa(e,0,n),r}},51:{f:Ya},60:{},61:{f:function(e){return{Pos:[e.read_shift(2),e.read_shift(2)],Dim:[e.read_shift(2),e.read_shift(2)],Flags:e.read_shift(2),CurTab:e.read_shift(2),FirstTab:e.read_shift(2),Selected:e.read_shift(2),TabRatio:e.read_shift(2)}}},64:{f:Ka},65:{f:function(){}},66:{f:Ya},77:{},80:{},81:{},82:{},85:{f:Ya},89:{},90:{},91:{},92:{f:function(e,t,n){if(n.enc)return e.l+=t,"";var r=e.l,i=es(e,0,n);return e.read_shift(t+r-e.l),i}},93:{f:function(e,t,n){if(n&&n.biff<8)return function(e,t,n){e.l+=4;var r=e.read_shift(2),i=e.read_shift(2),a=e.read_shift(2);e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=2,e.l+=6,t-=36;var s=[];return s.push((ks[r]||Ei)(e,t,n)),{cmo:[i,r,a],ft:s}}(e,t,n);var r=hs(e),i=function(e,t){for(var n=e.l+t,r=[];e.l7||t[1]>7)throw new Error("Bad Gutters: "+t.join("|"));return t}},129:{f:function(e,t,n){var r=n&&8==n.biff||2==t?e.read_shift(2):(e.l+=t,0);return{fDialog:16&r,fBelow:64&r,fRight:128&r}}},130:{f:Ya},131:{f:Ka},132:{f:Ka},133:{f:function(e,t,n){var r=e.read_shift(4),i=3&e.read_shift(1),a=e.read_shift(1);switch(a){case 0:a="Worksheet";break;case 1:a="Macrosheet";break;case 2:a="Chartsheet";break;case 6:a="VBAModule"}var s=qa(e,0,n);return 0===s.length&&(s="Sheet1"),{pos:r,hs:i,dt:a,name:s}}},134:{},140:{f:function(e){var t,n=[0,0];return t=e.read_shift(2),n[0]=ma[t]||t,t=e.read_shift(2),n[1]=ma[t]||t,n}},141:{f:Ya},144:{},146:{f:function(e){for(var t=e.read_shift(2),n=[];t-- >0;)n.push(is(e));return n}},151:{},152:{},153:{},154:{},155:{},156:{f:Ya},157:{},158:{},160:{f:As},161:{f:function(e,t){var n={};return t<32||(e.l+=16,n.header=aa(e),n.footer=aa(e),e.l+=2),n}},174:{},175:{},176:{},177:{},178:{},180:{},181:{},182:{},184:{},185:{},189:{f:function(e,t){for(var n=e.l+t-2,r=e.read_shift(2),i=e.read_shift(2),a=[];e.l>2&1,6,r.data=function(e,t,n,r){var i={},a=e.read_shift(4),s=e.read_shift(4),o=e.read_shift(4),l=e.read_shift(2);return i.patternType=ga[o>>26],r.cellStyles?(i.alc=7&a,i.fWrap=a>>3&1,i.alcV=a>>4&7,i.fJustLast=a>>7&1,i.trot=a>>8&255,i.cIndent=a>>16&15,i.fShrinkToFit=a>>20&1,i.iReadOrder=a>>22&2,i.fAtrNum=a>>26&1,i.fAtrFnt=a>>27&1,i.fAtrAlc=a>>28&1,i.fAtrBdr=a>>29&1,i.fAtrPat=a>>30&1,i.fAtrProt=a>>31&1,i.dgLeft=15&s,i.dgRight=s>>4&15,i.dgTop=s>>8&15,i.dgBottom=s>>12&15,i.icvLeft=s>>16&127,i.icvRight=s>>23&127,i.grbitDiag=s>>30&3,i.icvTop=127&o,i.icvBottom=o>>7&127,i.icvDiag=o>>14&127,i.dgDiag=o>>21&15,i.icvFore=127&l,i.icvBack=l>>7&127,i.fsxButton=l>>14&1,i):i}(e,0,r.fStyle,n),r}},225:{f:function(e,t){return 0===t||e.read_shift(2),1200}},226:{f:Ga},227:{},229:{f:function(e,t){for(var n=[],r=e.read_shift(2);r--;)n.push(ls(e));return n}},233:{},235:{},236:{},237:{},239:{},240:{},241:{},242:{},244:{},245:{},246:{},247:{},248:{},249:{},251:{},252:{f:function(e,t){for(var n=e.l+t,r=e.read_shift(4),i=e.read_shift(4),a=[],s=0;s!=i&&e.l255)throw new Error("Unexpected SupBook type: "+a);for(var s=Qa(e,a),o=[];r>e.l;)o.push(Ja(e));return[a,i,s,o]}},431:{f:Ka},432:{},433:{},434:{},437:{},438:{f:function(e,t,n){var r=e.l,i="";try{e.l+=4;var a=(n.lastobj||{cmo:[0,0]}).cmo[1];-1==[0,5,7,11,12,14].indexOf(a)?e.l+=6:function(e){var t=e.read_shift(1);e.l++;var n=e.read_shift(2);return e.l+=2,[t,n]}(e);var s=e.read_shift(2);e.read_shift(2),Ya(e);var o=e.read_shift(2);e.l+=o;for(var l=1;l=(c?s:2*s))break}if(i.length!==s&&i.length!==2*s)throw new Error("cchText: "+s+" != "+i.length);return e.l=r+t,{t:i}}catch(kC){return e.l=r+t,{t:i}}}},439:{f:Ka},440:{f:function(e,t){var n=ls(e);e.l+=16;var r=function(e,t){var n=e.l+t,r=e.read_shift(4);if(2!==r)throw new Error("Unrecognized streamVersion: "+r);var i=e.read_shift(2);e.l+=2;var a,s,o,l,c,u,h="";16&i&&(a=ns(e,e.l)),128&i&&(s=ns(e,e.l)),257===(257&i)&&(o=ns(e,e.l)),1===(257&i)&&(l=ts(e,e.l)),8&i&&(h=ns(e,e.l)),32&i&&(c=e.read_shift(16)),64&i&&(u=Ia(e)),e.l=n;var f=s||o||l||"";f&&h&&(f+="#"+h),f||(f="#"+h),2&i&&"/"==f.charAt(0)&&"/"!=f.charAt(1)&&(f="file://"+f);var d={Target:f};return c&&(d.guid=c),u&&(d.time=u),a&&(d.Tooltip=a),d}(e,t-24);return[n,r]}},441:{},442:{f:Ja},443:{},444:{f:Ya},445:{},446:{},448:{f:Ga},449:{f:function(e){return e.read_shift(2),e.read_shift(4)},r:2},450:{f:Ga},512:{f:vs},513:{f:Cs},515:{f:function(e,t,n){n.biffguess&&2==n.biff&&(n.biff=5);var r=as(e),i=aa(e);return r.val=i,r}},516:{f:function(e,t,n){n.biffguess&&2==n.biff&&(n.biff=5),e.l;var r=as(e);2==n.biff&&e.l++;var i=Ja(e,e.l,n);return r.val=i,r}},517:{f:bs},519:{f:Ms},520:{f:function(e){var t={};t.r=e.read_shift(2),t.c=e.read_shift(2),t.cnt=e.read_shift(2)-t.c;var n=e.read_shift(2);e.l+=4;var r=e.read_shift(1);return e.l+=3,7&r&&(t.level=7&r),32&r&&(t.hidden=!0),64&r&&(t.hpt=n/20),t}},523:{},545:{f:Es},549:{f:ms},566:{},574:{f:function(e,t,n){return n&&n.biff>=2&&n.biff<5?{}:{RTL:64&e.read_shift(2)}}},638:{f:function(e){var t=e.read_shift(2),n=e.read_shift(2),r=os(e);return{r:t,c:n,ixfe:r[0],rknum:r[1]}}},659:{},1048:{},1054:{f:function(e,t,n){return[e.read_shift(2),es(e,0,n)]}},1084:{},1212:{f:function(e,t,n){var r=cs(e);e.l++;var i=e.read_shift(1);return[_l(e,t-=8,n),i,r]}},2048:{f:function(e,t){e.read_shift(2);var n=ls(e),r=e.read_shift((t-10)/2,"dbcs-cont");return[n,r=r.replace(Dt,"")]}},2049:{},2050:{},2051:{},2052:{},2053:{},2054:{},2055:{},2056:{},2057:{f:ps},2058:{},2059:{},2060:{},2061:{},2062:{},2063:{},2064:{},2066:{},2067:{},2128:{},2129:{},2130:{},2131:{},2132:{},2133:{},2134:{},2135:{},2136:{},2137:{},2138:{},2146:{},2147:{r:12},2148:{},2149:{},2150:{},2151:{f:Ga},2152:{},2154:{},2155:{},2156:{},2161:{},2162:{},2164:{},2165:{},2166:{},2167:{},2168:{},2169:{},2170:{},2171:{},2172:{f:function(e){e.l+=2;var t={cxfs:0,crc:0};return t.cxfs=e.read_shift(2),t.crc=e.read_shift(4),t},r:12},2173:{f:function(e,t){e.l,e.l+=2;var n=e.read_shift(2);e.l+=2;for(var r=e.read_shift(2),i=[];r-- >0;)i.push(Bo(e,e.l));return{ixfe:n,ext:i}},r:12},2174:{},2175:{},2180:{},2181:{},2182:{},2183:{},2184:{},2185:{},2186:{},2187:{},2188:{f:Ka,r:12},2189:{},2190:{r:12},2191:{},2192:{},2194:{},2195:{},2196:{f:function(e,t,n){if(!(n.biff<8)){var r=e.read_shift(2),i=e.read_shift(2);return[Qa(e,r,n),Qa(e,i,n)]}e.l+=t},r:12},2197:{},2198:{f:function(e,t,n){var r=e.l+t;if(124226!==e.read_shift(4))if(n.cellStyles){var i,a=e.slice(e.l);e.l=r;try{i=sr(a,{type:"array"})}catch(kC){return}var s=nr(i,"theme/theme/theme1.xml",!0);if(s)return No(s,n)}else e.l=r},r:12},2199:{},2200:{},2201:{},2202:{f:function(e){return[0!==e.read_shift(4),0!==e.read_shift(4),e.read_shift(4)]},r:12},2203:{f:Ga},2204:{},2205:{},2206:{},2207:{},2211:{f:function(e){var t=function(e){var t=e.read_shift(2),n=e.read_shift(2);return e.l+=8,{type:t,flags:n}}(e);if(2211!=t.type)throw new Error("Invalid Future Record "+t.type);return 0!==e.read_shift(4)}},2212:{},2213:{},2214:{},2215:{},4097:{},4098:{},4099:{},4102:{},4103:{},4105:{},4106:{},4107:{},4108:{},4109:{},4116:{},4117:{},4118:{},4119:{},4120:{},4121:{},4122:{},4123:{},4124:{},4125:{},4126:{},4127:{},4128:{},4129:{},4130:{},4132:{},4133:{},4134:{f:Ya},4135:{},4146:{},4147:{},4148:{},4149:{},4154:{},4156:{},4157:{},4158:{},4159:{},4160:{},4161:{},4163:{},4164:{f:function(e,t,n){var r={area:!1};if(5!=n.biff)return e.l+=t,r;var i=e.read_shift(1);return e.l+=3,16&i&&(r.area=!0),r}},4165:{},4166:{},4168:{},4170:{},4171:{},4174:{},4175:{},4176:{},4177:{},4187:{},4188:{f:function(e){for(var t=e.read_shift(2),n=[];t-- >0;)n.push(is(e));return n}},4189:{},4191:{},4192:{},4193:{},4194:{},4195:{},4196:{},4197:{},4198:{},4199:{},4200:{},0:{f:vs},1:{},2:{f:function(e){var t=as(e);++e.l;var n=e.read_shift(2);return t.t="n",t.val=n,t}},3:{f:function(e){var t=as(e);++e.l;var n=aa(e);return t.t="n",t.val=n,t}},4:{f:function(e,t,n){n.biffguess&&5==n.biff&&(n.biff=2);var r=as(e);++e.l;var i=es(e,0,n);return r.t="str",r.val=i,r}},5:{f:bs},7:{f:function(e){var t=e.read_shift(1);return 0===t?(e.l++,""):e.read_shift(t,"sbcs-cont")}},8:{},9:{f:ps},11:{},22:{f:Ya},30:{f:gs},31:{},32:{},33:{f:Es},36:{},37:{f:ms},50:{f:function(e,t){e.l+=6,e.l+=2,e.l+=1,e.l+=3,e.l+=1,e.l+=t-13}},62:{},52:{},67:{},68:{f:Ya},69:{},86:{},126:{},127:{f:function(e){var t=e.read_shift(2),n=e.read_shift(2),r=e.read_shift(4),i={fmt:t,env:n,len:r,data:e.slice(e.l,e.l+r)};return e.l+=r,i}},135:{},136:{},137:{},145:{},148:{},149:{},150:{},169:{},171:{},188:{},191:{},192:{},194:{},195:{},214:{f:function(e,t,n){var r=e.l+t,i=as(e),a=e.read_shift(2),s=Qa(e,a,n);return e.l=r,i.t="str",i.val=s,i}},223:{},234:{},354:{},421:{},518:{f:Tl},521:{f:ps},536:{f:_s},547:{f:xs},561:{},579:{},1030:{f:Tl},1033:{f:ps},1091:{},2157:{},2163:{},2177:{},2240:{},2241:{},2242:{},2243:{},2244:{},2245:{},2246:{},2247:{},2248:{},2249:{},2250:{},2251:{},2262:{r:12},29282:{}};function $c(e,t,n,r){var i=t;if(!isNaN(i)){var a=r||(n||[]).length||0,s=e.next(4);s.write_shift(2,i),s.write_shift(2,a),a>0&&ci(n)&&e.push(n)}}function Gc(e,t){var n=t||{};null!=wt&&null==n.dense&&(n.dense=wt);var r=n.dense?[]:{},i=(e=e.replace(//g,"")).match(/");var a=e.match(/<\/table/i),s=i.index,o=a&&a.index||e.length,l=qn(e.slice(s,o),/(:?]*>)/i,"
"),c=-1,u=0,h=0,f=0,d={s:{r:1e7,c:1e7},e:{r:0,c:0}},p=[];for(s=0;s/i);for(o=0;o"))>-1;)y=y.slice(x+1);for(var w=0;w")));f=T.colspan?+T.colspan:1,((h=+T.rowspan)>1||f>1)&&p.push({s:{r:c,c:u},e:{r:c+(h||1)-1,c:u+f-1}});var E=T.t||T["data-t"]||"";if(y.length)if(y=Or(y),d.s.r>c&&(d.s.r=c),d.e.ru&&(d.s.c=u),d.e.cn||i[c].s.c>s)&&!(i[c].e.r1&&(d.rowspan=o),l>1&&(d.colspan=l),r.editable?f=''+f+"":h&&(d["data-t"]=h&&h.t||"z",null!=h.v&&(d["data-v"]=h.v),null!=h.z&&(d["data-z"]=h.z),h.l&&"#"!=(h.l.Target||"#").charAt(0)&&(f=''+f+"")),d.id=(r.id||"sjs")+"-"+u,a.push(zr("td",f,d))}}return""+a.join("")+"
"}var Yc='SheetJS Table Export',Xc="";function qc(e,t,n){return[].join("")+""}function Zc(e,t){var n=t||{},r=null!=n.header?n.header:Yc,i=null!=n.footer?n.footer:Xc,a=[r],s=zi(e["!ref"]);n.dense=Array.isArray(e),a.push(qc(0,0,n));for(var o=s.s.r;o<=s.e.r;++o)a.push(Kc(e,s,o,n));return a.push("
"+i),a.join("")}function Qc(e,t,n){var r=n||{};null!=wt&&(r.dense=wt);var i=0,a=0;if(null!=r.origin)if("number"==typeof r.origin)i=r.origin;else{var s="string"==typeof r.origin?Ni(r.origin):r.origin;i=s.r,a=s.c}var o=t.getElementsByTagName("tr"),l=Math.min(r.sheetRows||1e7,o.length),c={s:{r:0,c:0},e:{r:i,c:a}};if(e["!ref"]){var u=zi(e["!ref"]);c.s.r=Math.min(c.s.r,u.s.r),c.s.c=Math.min(c.s.c,u.s.c),c.e.r=Math.max(c.e.r,u.e.r),c.e.c=Math.max(c.e.c,u.e.c),-1==i&&(c.e.r=i=u.e.r+1)}var h=[],f=0,d=e["!rows"]||(e["!rows"]=[]),p=0,m=0,g=0,v=0,b=0,y=0;for(e["!cols"]||(e["!cols"]=[]);p1||y>1)&&h.push({s:{r:m+i,c:v+a},e:{r:m+i+(b||1)-1,c:v+a+(y||1)-1}});var S={t:"s",v:T},C=_.getAttribute("data-t")||_.getAttribute("t")||"";null!=T&&(0==T.length?S.t=C||"z":r.raw||0==T.trim().length||"s"==C||("TRUE"===T?S={t:"b",v:!0}:"FALSE"===T?S={t:"b",v:!1}:isNaN(Kn(T))?isNaN(Xn(T).getDate())||(S={t:"d",v:Hn(T)},r.cellDates||(S={t:"n",v:Ln(S.v)}),S.z=r.dateNF||Wt[14]):S={t:"n",v:Kn(T)})),void 0===S.z&&null!=E&&(S.z=E);var A="",M=_.getElementsByTagName("A");if(M&&M.length)for(var P=0;P=l&&(e["!fullref"]=Bi((c.e.r=o.length-p+m-1+i,c))),e}function Jc(e,t){return Qc((t||{}).dense?[]:{},e,t)}function eu(e){var t="",n=function(e){return e.ownerDocument.defaultView&&"function"===typeof e.ownerDocument.defaultView.getComputedStyle?e.ownerDocument.defaultView.getComputedStyle:"function"===typeof getComputedStyle?getComputedStyle:null}(e);return n&&(t=n(e).getPropertyValue("display")),t||(t=e.style&&e.style.display),"none"===t}function tu(e){var t=e.replace(/[\t\r\n]/g," ").trim().replace(/ +/g," ").replace(//g," ").replace(//g,(function(e,t){return Array(parseInt(t,10)+1).join(" ")})).replace(/]*\/>/g,"\t").replace(//g,"\n");return[br(t.replace(/<[^>]*>/g,""))]}var nu={day:["d","dd"],month:["m","mm"],year:["y","yy"],hours:["h","hh"],minutes:["m","mm"],seconds:["s","ss"],"am-pm":["A/P","AM/PM"],"day-of-week":["ddd","dddd"],era:["e","ee"],quarter:["\\Qm",'m\\"th quarter"']};function ru(e,t){var n=t||{};null!=wt&&null==n.dense&&(n.dense=wt);var r,i,a,s,o,l,c=Br(e),u=[],h={name:""},f="",d=0,p={},m=[],g=n.dense?[]:{},v={value:""},b="",y=0,x=[],w=-1,_=-1,T={s:{r:1e6,c:1e7},e:{r:0,c:0}},E=0,k={},S=[],C={},A=[],M=1,P=1,O=[],R={Names:[]},D={},L=["",""],I=[],N={},F="",z=0,B=!1,j=!1,V=0;for(jr.lastIndex=0,c=c.replace(//gm,"").replace(//gm,"");o=jr.exec(c);)switch(o[3]=o[3].replace(/_.*$/,"")){case"table":case"\u5de5\u4f5c\u8868":"/"===o[1]?(T.e.c>=T.s.c&&T.e.r>=T.s.r?g["!ref"]=Bi(T):g["!ref"]="A1:A1",n.sheetRows>0&&n.sheetRows<=T.e.r&&(g["!fullref"]=g["!ref"],T.e.r=n.sheetRows-1,g["!ref"]=Bi(T)),S.length&&(g["!merges"]=S),A.length&&(g["!rows"]=A),a.name=a["\u540d\u79f0"]||a.name,"undefined"!==typeof JSON&&JSON.stringify(a),m.push(a.name),p[a.name]=g,j=!1):"/"!==o[0].charAt(o[0].length-2)&&(a=pr(o[0],!1),w=_=-1,T.s.r=T.s.c=1e7,T.e.r=T.e.c=0,g=n.dense?[]:{},S=[],A=[],j=!0);break;case"table-row-group":"/"===o[1]?--E:++E;break;case"table-row":case"\u884c":if("/"===o[1]){w+=M,M=1;break}if((s=pr(o[0],!1))["\u884c\u53f7"]?w=s["\u884c\u53f7"]-1:-1==w&&(w=0),(M=+s["number-rows-repeated"]||1)<10)for(V=0;V0&&(A[w+V]={level:E});_=-1;break;case"covered-table-cell":"/"!==o[1]&&++_,n.sheetStubs&&(n.dense?(g[w]||(g[w]=[]),g[w][_]={t:"z"}):g[Fi({r:w,c:_})]={t:"z"}),b="",x=[];break;case"table-cell":case"\u6570\u636e":if("/"===o[0].charAt(o[0].length-2))++_,v=pr(o[0],!1),P=parseInt(v["number-columns-repeated"]||"1",10),l={t:"z",v:null},v.formula&&0!=n.cellFormula&&(l.f=Rl(br(v.formula))),"string"==(v["\u6570\u636e\u7c7b\u578b"]||v["value-type"])&&(l.t="s",l.v=br(v["string-value"]||""),n.dense?(g[w]||(g[w]=[]),g[w][_]=l):g[Fi({r:w,c:_})]=l),_+=P-1;else if("/"!==o[1]){b="",y=0,x=[],P=1;var U=M?w+M-1:w;if(++_>T.e.c&&(T.e.c=_),_T.e.r&&(T.e.r=U),I=[],N={},l={t:(v=pr(o[0],!1))["\u6570\u636e\u7c7b\u578b"]||v["value-type"],v:null},n.cellFormula)if(v.formula&&(v.formula=br(v.formula)),v["number-matrix-columns-spanned"]&&v["number-matrix-rows-spanned"]&&(C={s:{r:w,c:_},e:{r:w+(parseInt(v["number-matrix-rows-spanned"],10)||0)-1,c:_+(parseInt(v["number-matrix-columns-spanned"],10)||0)-1}},l.F=Bi(C),O.push([C,l.F])),v.formula)l.f=Rl(v.formula);else for(V=0;V=O[V][0].s.r&&w<=O[V][0].e.r&&_>=O[V][0].s.c&&_<=O[V][0].e.c&&(l.F=O[V][1]);switch((v["number-columns-spanned"]||v["number-rows-spanned"])&&(C={s:{r:w,c:_},e:{r:w+(parseInt(v["number-rows-spanned"],10)||0)-1,c:_+(parseInt(v["number-columns-spanned"],10)||0)-1}},S.push(C)),v["number-columns-repeated"]&&(P=parseInt(v["number-columns-repeated"],10)),l.t){case"boolean":l.t="b",l.v=Tr(v["boolean-value"]);break;case"float":case"percentage":case"currency":l.t="n",l.v=parseFloat(v.value);break;case"date":l.t="d",l.v=Hn(v["date-value"]),n.cellDates||(l.t="n",l.v=Ln(l.v)),l.z="m/d/yy";break;case"time":l.t="n",l.v=Bn(v["time-value"])/86400,n.cellDates&&(l.t="d",l.v=zn(l.v)),l.z="HH:MM:SS";break;case"number":l.t="n",l.v=parseFloat(v["\u6570\u636e\u6570\u503c"]);break;default:if("string"!==l.t&&"text"!==l.t&&l.t)throw new Error("Unsupported value type "+l.t);l.t="s",null!=v["string-value"]&&(b=br(v["string-value"]),x=[])}}else{if(B=!1,"s"===l.t&&(l.v=b||"",x.length&&(l.R=x),B=0==y),D.Target&&(l.l=D),I.length>0&&(l.c=I,I=[]),b&&!1!==n.cellText&&(l.w=b),B&&(l.t="z",delete l.v),(!B||n.sheetStubs)&&!(n.sheetRows&&n.sheetRows<=w))for(var H=0;H0;)g[w+H][_+P]=$n(l);else for(g[Fi({r:w+H,c:_})]=l;--P>0;)g[Fi({r:w+H,c:_+P})]=$n(l);T.e.c<=_&&(T.e.c=_)}_+=(P=parseInt(v["number-columns-repeated"]||"1",10))-1,P=0,l={},b="",x=[]}D={};break;case"document":case"document-content":case"\u7535\u5b50\u8868\u683c\u6587\u6863":case"spreadsheet":case"\u4e3b\u4f53":case"scripts":case"styles":case"font-face-decls":case"master-styles":if("/"===o[1]){if((r=u.pop())[0]!==o[3])throw"Bad state: "+r}else"/"!==o[0].charAt(o[0].length-2)&&u.push([o[3],!0]);break;case"annotation":if("/"===o[1]){if((r=u.pop())[0]!==o[3])throw"Bad state: "+r;N.t=b,x.length&&(N.R=x),N.a=F,I.push(N)}else"/"!==o[0].charAt(o[0].length-2)&&u.push([o[3],!1]);F="",z=0,b="",y=0,x=[];break;case"creator":"/"===o[1]?F=c.slice(z,o.index):z=o.index+o[0].length;break;case"meta":case"\u5143\u6570\u636e":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("/"===o[1]){if((r=u.pop())[0]!==o[3])throw"Bad state: "+r}else"/"!==o[0].charAt(o[0].length-2)&&u.push([o[3],!1]);b="",y=0,x=[];break;case"scientific-number":case"currency-symbol":case"currency-style":case"script":case"libraries":case"automatic-styles":case"default-style":case"page-layout":case"style":case"map":case"font-face":case"paragraph-properties":case"table-properties":case"table-column-properties":case"table-row-properties":case"table-cell-properties":case"fraction":case"boolean-style":case"boolean":case"text-style":case"text-content":case"text-properties":case"embedded-text":case"body":case"\u7535\u5b50\u8868\u683c":case"forms":case"table-column":case"table-header-rows":case"table-rows":case"table-column-group":case"table-header-columns":case"table-columns":case"null-date":case"graphic-properties":case"calculation-settings":case"named-expressions":case"label-range":case"label-ranges":case"named-expression":case"sort":case"sort-by":case"sort-groups":case"tab":case"line-break":case"span":case"s":case"date":case"object":case"title":case"\u6807\u9898":case"desc":case"binary-data":case"table-source":case"scenario":case"iteration":case"content-validations":case"content-validation":case"help-message":case"error-message":case"database-ranges":case"filter":case"filter-and":case"filter-or":case"filter-condition":case"list-level-style-bullet":case"list-level-style-number":case"list-level-properties":case"sender-firstname":case"sender-lastname":case"sender-initials":case"sender-title":case"sender-position":case"sender-email":case"sender-phone-private":case"sender-fax":case"sender-company":case"sender-phone-work":case"sender-street":case"sender-city":case"sender-postal-code":case"sender-country":case"sender-state-or-province":case"author-name":case"author-initials":case"chapter":case"file-name":case"template-name":case"sheet-name":case"event-listener":case"initial-creator":case"creation-date":case"print-date":case"generator":case"document-statistic":case"user-defined":case"editing-duration":case"editing-cycles":case"config-item":case"page-number":case"page-count":case"time":case"cell-range-source":case"detective":case"operation":case"highlighted-range":case"data-pilot-table":case"source-cell-range":case"source-service":case"data-pilot-field":case"data-pilot-level":case"data-pilot-subtotals":case"data-pilot-subtotal":case"data-pilot-members":case"data-pilot-member":case"data-pilot-display-info":case"data-pilot-sort-info":case"data-pilot-layout-info":case"data-pilot-field-reference":case"data-pilot-groups":case"data-pilot-group":case"data-pilot-group-member":case"rect":case"dde-connection-decls":case"dde-connection-decl":case"dde-link":case"dde-source":case"properties":case"property":case"table-protection":case"data-pilot-grand-total":case"office-document-common-attrs":break;case"number-style":case"percentage-style":case"date-style":case"time-style":if("/"===o[1]){if(k[h.name]=f,(r=u.pop())[0]!==o[3])throw"Bad state: "+r}else"/"!==o[0].charAt(o[0].length-2)&&(f="",h=pr(o[0],!1),u.push([o[3],!0]));break;case"number":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(u[u.length-1][0]){case"time-style":case"date-style":i=pr(o[0],!1),f+=nu[o[3]]["long"===i.style?1:0]}break;case"text":if("/>"===o[0].slice(-2))break;if("/"===o[1])switch(u[u.length-1][0]){case"number-style":case"date-style":case"time-style":f+=c.slice(d,o.index)}else d=o.index+o[0].length;break;case"named-range":L=Dl((i=pr(o[0],!1))["cell-range-address"]);var W={Name:i.name,Ref:L[0]+"!"+L[1]};j&&(W.Sheet=m.length),R.Names.push(W);break;case"p":case"\u6587\u672c\u4e32":if(["master-styles"].indexOf(u[u.length-1][0])>-1)break;if("/"!==o[1]||v&&v["string-value"])pr(o[0],!1),y=o.index+o[0].length;else{var $=tu(c.slice(y,o.index));b=(b.length>0?b+"\n":"")+$[0]}break;case"database-range":if("/"===o[1])break;try{p[(L=Dl(pr(o[0])["target-range-address"]))[0]]["!autofilter"]={ref:L[1]}}catch(kC){}break;case"a":if("/"!==o[1]){if(!(D=pr(o[0],!1)).href)break;D.Target=br(D.href),delete D.href,"#"==D.Target.charAt(0)&&D.Target.indexOf(".")>-1?(L=Dl(D.Target.slice(1)),D.Target="#"+L[0]+"!"+L[1]):D.Target.match(/^\.\.[\\\/]/)&&(D.Target=D.Target.slice(3))}break;default:switch(o[2]){case"dc:":case"calcext:":case"loext:":case"ooo:":case"chartooo:":case"draw:":case"style:":case"chart:":case"form:":case"uof:":case"\u8868:":case"\u5b57:":break;default:if(n.WTF)throw new Error(o)}}var G={Sheets:p,SheetNames:m,Workbook:R};return n.bookSheets&&delete G.Sheets,G}function iu(e,t){t=t||{},Jn(e,"META-INF/manifest.xml")&&function(e,t){for(var n,r,i=Br(e);n=jr.exec(i);)switch(n[3]){case"manifest":break;case"file-entry":if("/"==(r=pr(n[0],!1)).path&&r.type!==ka)throw new Error("This OpenDocument is not a spreadsheet");break;case"encryption-data":case"algorithm":case"start-key-generation":case"key-derivation":throw new Error("Unsupported ODS Encryption");default:if(t&&t.WTF)throw n}}(tr(e,"META-INF/manifest.xml"),t);var n=nr(e,"content.xml");if(!n)throw new Error("Missing content.xml in ODS / UOF file");var r=ru(Ar(n),t);return Jn(e,"meta.xml")&&(r.Props=Aa(tr(e,"meta.xml"))),r}function au(e,t){return ru(e,t)}function su(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}function ou(e){return"undefined"!=typeof TextDecoder?(new TextDecoder).decode(e):Ar(Pt(e))}function lu(e){var t=e.reduce((function(e,t){return e+t.length}),0),n=new Uint8Array(t),r=0;return e.forEach((function(e){n.set(e,r),r+=e.length})),n}function cu(e){return 16843009*((e=(858993459&(e-=e>>1&1431655765))+(e>>2&858993459))+(e>>4)&252645135)>>>24}function uu(e,t){var n=t?t[0]:0,r=127&e[n];e:if(e[n++]>=128){if(r|=(127&e[n])<<7,e[n++]<128)break e;if(r|=(127&e[n])<<14,e[n++]<128)break e;if(r|=(127&e[n])<<21,e[n++]<128)break e;if(r+=(127&e[n])*Math.pow(2,28),++n,e[n++]<128)break e;if(r+=(127&e[n])*Math.pow(2,35),++n,e[n++]<128)break e;if(r+=(127&e[n])*Math.pow(2,42),++n,e[n++]<128)break e}return t&&(t[0]=n),r}function hu(e){var t=0,n=127&e[t];e:if(e[t++]>=128){if(n|=(127&e[t])<<7,e[t++]<128)break e;if(n|=(127&e[t])<<14,e[t++]<128)break e;if(n|=(127&e[t])<<21,e[t++]<128)break e;n|=(127&e[t])<<28}return n}function fu(e){for(var t=[],n=[0];n[0]=128;);r=e.slice(l,n[0]);break;case 5:o=4,r=e.slice(n[0],n[0]+o),n[0]+=o;break;case 1:o=8,r=e.slice(n[0],n[0]+o),n[0]+=o;break;case 2:o=uu(e,n),r=e.slice(n[0],n[0]+o),n[0]+=o;break;default:throw new Error("PB Type ".concat(s," for Field ").concat(a," at offset ").concat(i))}var c={data:r,type:s};null==t[a]?t[a]=[c]:t[a].push(c)}return t}function du(e,t){return(null==e?void 0:e.map((function(e){return t(e.data)})))||[]}function pu(e){for(var t,n=[],r=[0];r[0]>>0>0),n.push(s)}return n}function mu(e,t){if(0!=e)throw new Error("Unexpected Snappy chunk type ".concat(e));for(var n=[0],r=uu(t,n),i=[];n[0]>2&7),s=(224&t[n[0]++])<<3,s|=t[n[0]++]):(o=1+(t[n[0]++]>>2),2==a?(s=t[n[0]]|t[n[0]+1]<<8,n[0]+=2):(s=(t[n[0]]|t[n[0]+1]<<8|t[n[0]+2]<<16|t[n[0]+3]<<24)>>>0,n[0]+=4)),i=[lu(i)],0==s)throw new Error("Invalid offset 0");if(s>i[0].length)throw new Error("Invalid offset beyond length");if(o>=s)for(i.push(i[0].slice(-s)),o-=s;o>=i[i.length-1].length;)i.push(i[i.length-1]),o-=i[i.length-1].length;i.push(i[0].slice(-s,-s+o))}else{var l=t[n[0]++]>>2;if(l<60)++l;else{var c=l-59;l=t[n[0]],c>1&&(l|=t[n[0]+1]<<8),c>2&&(l|=t[n[0]+2]<<16),c>3&&(l|=t[n[0]+3]<<24),l>>>=0,l++,n[0]+=c}i.push(t.slice(n[0],n[0]+l)),n[0]+=l}}var u=lu(i);if(u.length!=r)throw new Error("Unexpected length: ".concat(u.length," != ").concat(r));return u}function gu(e){for(var t=[],n=0;n>1,r=1&e[t+14],i=t+13;i>=t;--i)r=256*r+e[i];return(128&e[t+15]?-r:r)*Math.pow(10,n-6176)}(e,s),s+=16),2&a&&(u=i.getFloat64(s,!0),s+=8),4&a&&(h.setTime(h.getTime()+1e3*i.getFloat64(s,!0)),s+=8),8&a&&(l=i.getUint32(s,!0),s+=4),16&a&&(o=i.getUint32(s,!0),s+=4),e[1]){case 0:break;case 2:case 10:r={t:"n",v:c};break;case 3:r={t:"s",v:t[l]};break;case 5:r={t:"d",v:h};break;case 6:r={t:"b",v:u>0};break;case 7:r={t:"n",v:u/86400};break;case 8:r={t:"e",v:0};break;case 9:if(!(o>-1))throw new Error("Unsupported cell type ".concat(e[1]," : ").concat(31&a," : ").concat(e.slice(0,4)));r={t:"s",v:n[o]};break;default:throw new Error("Unsupported cell type ".concat(e[1]," : ").concat(31&a," : ").concat(e.slice(0,4)))}return r}function bu(e,t,n){switch(e[0]){case 0:case 1:case 2:case 3:return function(e,t,n,r){var i,a=su(e),s=a.getUint32(4,!0),o=(r>1?12:8)+4*cu(s&(r>1?3470:398)),l=-1,c=-1,u=NaN,h=new Date(2001,0,1);switch(512&s&&(l=a.getUint32(o,!0),o+=4),o+=4*cu(s&(r>1?12288:4096)),16&s&&(c=a.getUint32(o,!0),o+=4),32&s&&(u=a.getFloat64(o,!0),o+=8),64&s&&(h.setTime(h.getTime()+1e3*a.getFloat64(o,!0)),o+=8),e[2]){case 0:break;case 2:i={t:"n",v:u};break;case 3:i={t:"s",v:t[c]};break;case 5:i={t:"d",v:h};break;case 6:i={t:"b",v:u>0};break;case 7:i={t:"n",v:u/86400};break;case 8:i={t:"e",v:0};break;case 9:if(l>-1)i={t:"s",v:n[l]};else if(c>-1)i={t:"s",v:t[c]};else{if(isNaN(u))throw new Error("Unsupported cell type ".concat(e.slice(0,4)));i={t:"n",v:u}}break;default:throw new Error("Unsupported cell type ".concat(e.slice(0,4)))}return i}(e,t,n,e[0]);case 5:return vu(e,t,n);default:throw new Error("Unsupported payload version ".concat(e[0]))}}function yu(e){return uu(fu(e)[1][0].data)}function xu(e,t){var n=fu(t.data),r=hu(n[1][0].data),i=n[3],a=[];return(i||[]).forEach((function(t){var n=fu(t.data),i=hu(n[1][0].data)>>>0;switch(r){case 1:a[i]=ou(n[3][0].data);break;case 8:var s=fu(e[yu(n[9][0].data)][0].data),o=e[yu(s[1][0].data)][0],l=hu(o.meta[1][0].data);if(2001!=l)throw new Error("2000 unexpected reference to ".concat(l));var c=fu(o.data);a[i]=c[3].map((function(e){return ou(e.data)})).join("")}})),a}function wu(e,t){var n,r=fu(t.data),i=(null==(n=null==r?void 0:r[7])?void 0:n[0])?hu(r[7][0].data)>>>0>0?1:0:-1,a=du(r[5],(function(e){return function(e,t){var n,r,i,a,s,o,l,c,u,h,f,d,p,m,g,v,b=fu(e),y=hu(b[1][0].data)>>>0,x=hu(b[2][0].data)>>>0,w=(null==(r=null==(n=b[8])?void 0:n[0])?void 0:r.data)&&hu(b[8][0].data)>0||!1;if((null==(a=null==(i=b[7])?void 0:i[0])?void 0:a.data)&&0!=t)g=null==(o=null==(s=b[7])?void 0:s[0])?void 0:o.data,v=null==(c=null==(l=b[6])?void 0:l[0])?void 0:c.data;else{if(!(null==(h=null==(u=b[4])?void 0:u[0])?void 0:h.data)||1==t)throw"NUMBERS Tile missing ".concat(t," cell storage");g=null==(d=null==(f=b[4])?void 0:f[0])?void 0:d.data,v=null==(m=null==(p=b[3])?void 0:p[0])?void 0:m.data}for(var _=w?4:1,T=su(g),E=[],k=0;k=1&&(C[E[E.length-1][0]]=v.subarray(E[E.length-1][1]*_)),{R:y,cells:C}}(e,i)}));return{nrows:hu(r[4][0].data)>>>0,data:a.reduce((function(e,t){return e[t.R]||(e[t.R]=[]),t.cells.forEach((function(n,r){if(e[t.R][r])throw new Error("Duplicate cell r=".concat(t.R," c=").concat(r));e[t.R][r]=n})),e}),[])}}function _u(e,t){var n={"!ref":"A1"},r=e[yu(fu(t.data)[2][0].data)],i=hu(r[0].meta[1][0].data);if(6001!=i)throw new Error("6000 unexpected reference to ".concat(i));return function(e,t,n){var r,i=fu(t.data),a={s:{r:0,c:0},e:{r:0,c:0}};if(a.e.r=(hu(i[6][0].data)>>>0)-1,a.e.r<0)throw new Error("Invalid row varint ".concat(i[6][0].data));if(a.e.c=(hu(i[7][0].data)>>>0)-1,a.e.c<0)throw new Error("Invalid col varint ".concat(i[7][0].data));n["!ref"]=Bi(a);var s=fu(i[4][0].data),o=xu(e,e[yu(s[4][0].data)][0]),l=(null==(r=s[17])?void 0:r[0])?xu(e,e[yu(s[17][0].data)][0]):[],c=fu(s[3][0].data),u=0;c[1].forEach((function(t){var r=fu(t.data),i=e[yu(r[2][0].data)][0],a=hu(i.meta[1][0].data);if(6002!=a)throw new Error("6001 unexpected reference to ".concat(a));var s=wu(0,i);s.data.forEach((function(e,t){e.forEach((function(e,r){var i=Fi({r:u+t,c:r}),a=bu(e,o,l);a&&(n[i]=a)}))})),u+=s.nrows}))}(e,r[0],n),n}function Tu(e,t){var n={SheetNames:[],Sheets:{}};if(du(fu(t.data)[1],yu).forEach((function(t){e[t].forEach((function(t){if(2==hu(t.meta[1][0].data)){var r=function(e,t){var n,r=fu(t.data),i={name:(null==(n=r[1])?void 0:n[0])?ou(r[1][0].data):"",sheets:[]};return du(r[2],yu).forEach((function(t){e[t].forEach((function(t){6e3==hu(t.meta[1][0].data)&&i.sheets.push(_u(e,t))}))})),i}(e,t);r.sheets.forEach((function(e,t){Wu(n,e,0==t?r.name:r.name+"_"+t,!0)}))}}))})),0==n.SheetNames.length)throw new Error("Empty NUMBERS file");return n}function Eu(e){var t,n,r,i,a={},s=[];if(e.FullPaths.forEach((function(e){if(e.match(/\.iwpv2/))throw new Error("Unsupported password protection")})),e.FileIndex.forEach((function(e){if(e.name.match(/\.iwa$/)){var t,n;try{t=gu(e.content)}catch(kC){return console.log("?? "+e.content.length+" "+(kC.message||kC))}try{n=pu(t)}catch(kC){return console.log("## "+(kC.message||kC))}n.forEach((function(e){a[e.id]=e.messages,s.push(e.id)}))}})),!s.length)throw new Error("File has no messages");var o=(null==(i=null==(r=null==(n=null==(t=null==a?void 0:a[1])?void 0:t[0])?void 0:n.meta)?void 0:r[1])?void 0:i[0].data)&&1==hu(a[1][0].meta[1][0].data)&&a[1][0];if(o||s.forEach((function(e){a[e].forEach((function(e){if(1==hu(e.meta[1][0].data)>>>0){if(o)throw new Error("Document has multiple roots");o=e}}))})),!o)throw new Error("Cannot find Document root");return Tu(a,o)}function ku(e){return function(t){for(var n=0;n!=e.length;++n){var r=e[n];void 0===t[r[0]]&&(t[r[0]]=r[1]),"n"===r[2]&&(t[r[0]]=Number(t[r[0]]))}}}function Su(e){ku([["cellNF",!1],["cellHTML",!0],["cellFormula",!0],["cellStyles",!1],["cellText",!0],["cellDates",!1],["sheetStubs",!1],["sheetRows",0,"n"],["bookDeps",!1],["bookSheets",!1],["bookProps",!1],["bookFiles",!1],["bookVBA",!1],["password",""],["WTF",!1]])(e)}function Cu(e,t,n,r,i,a,s,o,l,c,u,h){try{a[r]=Ea(nr(e,n,!0),t);var f,d=tr(e,t);switch(o){case"sheet":f=mc(d,t,i,l,a[r],c,u,h);break;case"chart":if(!(f=gc(d,t,i,l,a[r],c))||!f["!drawel"])break;var p=or(f["!drawel"].Target,t),m=Ta(p),g=function(e,t){if(!e)return"??";var n=(e.match(/]*r:id="([^"]*)"/)||["",""])[1];return t["!id"][n].Target}(nr(e,p,!0),Ea(nr(e,m,!0),p)),v=or(g,p),b=Ta(v);f=nc(nr(e,v,!0),0,0,Ea(nr(e,b,!0),v),0,f);break;case"macro":x=t,a[r],x.slice(-4),f={"!type":"macro"};break;case"dialog":f=function(e,t,n,r,i,a,s,o){return t.slice(-4),{"!type":"dialog"}}(0,t,0,0,a[r]);break;default:throw new Error("Unrecognized sheet type "+o)}s[r]=f;var y=[];a&&a[r]&&On(a[r]).forEach((function(n){var i="";if(a[r][n].Type==_a.CMNT){i=or(a[r][n].Target,t);var s=yc(tr(e,i,!0),i,l);if(!s||!s.length)return;jo(f,s,!1)}a[r][n].Type==_a.TCMNT&&(i=or(a[r][n].Target,t),y=y.concat(function(e,t){var n=[],r=!1,i={},a=0;return e.replace(hr,(function(s,o){var l=pr(s);switch(mr(l[0])){case"":case"":case"":case"":break;case"":null!=i.t&&n.push(i);break;case"":case"":i.t=e.slice(a,o).replace(/\r\n/g,"\n").replace(/\r/g,"\n");break;case"":case"":case"":r=!1;break;default:if(!r&&t.WTF)throw new Error("unrecognized "+l[0]+" in threaded comments")}return s})),n}(tr(e,i,!0),l)))})),y&&y.length&&jo(f,y,!0,l.people||[])}catch(kC){if(l.WTF)throw kC}var x}function Au(e){return"/"==e.charAt(0)?e.slice(1):e}function Mu(e,t){if(kn(),Su(t=t||{}),Jn(e,"META-INF/manifest.xml"))return iu(e,t);if(Jn(e,"objectdata.xml"))return iu(e,t);if(Jn(e,"Index/Document.iwa")){if("undefined"==typeof Uint8Array)throw new Error("NUMBERS file parsing requires Uint8Array support");if(e.FileIndex)return Eu(e);var n=Mn.utils.cfb_new();return ir(e).forEach((function(t){ar(n,t,rr(e,t))})),Eu(n)}if(!Jn(e,"[Content_Types].xml")){if(Jn(e,"index.xml.gz"))throw new Error("Unsupported NUMBERS 08 file");if(Jn(e,"index.xml"))throw new Error("Unsupported NUMBERS 09 file");throw new Error("Unsupported ZIP file")}var r,i,a=ir(e),s=function(e){var t={workbooks:[],sheets:[],charts:[],dialogs:[],macros:[],rels:[],strs:[],comments:[],threadedcomments:[],links:[],coreprops:[],extprops:[],custprops:[],themes:[],styles:[],calcchains:[],vba:[],drawings:[],metadata:[],people:[],TODO:[],xmlns:""};if(!e||!e.match)return t;var n={};if((e.match(hr)||[]).forEach((function(e){var r=pr(e);switch(r[0].replace(fr,"<")){case"0?t.calcchains[0]:"",t.sst=t.strs.length>0?t.strs[0]:"",t.style=t.styles.length>0?t.styles[0]:"",t.defaults=n,delete t.calcchains,t}(nr(e,"[Content_Types].xml")),o=!1;if(0===s.workbooks.length&&tr(e,i="xl/workbook.xml",!0)&&s.workbooks.push(i),0===s.workbooks.length){if(!tr(e,i="xl/workbook.bin",!0))throw new Error("Could not find workbook");s.workbooks.push(i),o=!0}"bin"==s.workbooks[0].slice(-3)&&(o=!0);var l={},c={};if(!t.bookSheets&&!t.bookProps){if(Ll=[],s.sst)try{Ll=bc(tr(e,Au(s.sst)),s.sst,t)}catch(kC){if(t.WTF)throw kC}t.cellStyles&&s.themes.length&&(l=function(e,t,n){return No(e,n)}(nr(e,s.themes[0].replace(/^\//,""),!0)||"",s.themes[0],t)),s.style&&(c=vc(tr(e,Au(s.style)),s.style,l,t))}s.links.map((function(n){try{Ea(nr(e,Ta(Au(n))),n);return wc(tr(e,Au(n)),0,n,t)}catch(kC){}}));var u=pc(tr(e,Au(s.workbooks[0])),s.workbooks[0],t),h={},f="";s.coreprops.length&&((f=tr(e,Au(s.coreprops[0]),!0))&&(h=Aa(f)),0!==s.extprops.length&&(f=tr(e,Au(s.extprops[0]),!0))&&function(e,t,n){var r={};t||(t={}),e=Ar(e),Ma.forEach((function(n){var i=(e.match(Pr(n[0]))||[])[1];switch(n[2]){case"string":i&&(t[n[1]]=br(i));break;case"bool":t[n[1]]="true"===i;break;case"raw":var a=e.match(new RegExp("<"+n[0]+"[^>]*>([\\s\\S]*?)"+n[0]+">"));a&&a.length>0&&(r[n[1]]=a[1])}})),r.HeadingPairs&&r.TitlesOfParts&&Pa(r.HeadingPairs,r.TitlesOfParts,t,n)}(f,h,t));var d={};t.bookSheets&&!t.bookProps||0!==s.custprops.length&&(f=nr(e,Au(s.custprops[0]),!0))&&(d=function(e,t){var n={},r="",i=e.match(Oa);if(i)for(var a=0;a!=i.length;++a){var s=i[a],o=pr(s);switch(o[0]){case"":r=null;break;default:if(0===s.indexOf(""),c=l[0].slice(4),u=l[1];switch(c){case"lpstr":case"bstr":case"lpwstr":case"cy":case"error":n[r]=br(u);break;case"bool":n[r]=Tr(u);break;case"i1":case"i2":case"i4":case"i8":case"int":case"uint":n[r]=parseInt(u,10);break;case"r4":case"r8":case"decimal":n[r]=parseFloat(u);break;case"filetime":case"date":n[r]=Hn(u);break;default:if("/"==c.slice(-1))break;t.WTF&&"undefined"!==typeof console&&console.warn("Unexpected",s,c,l)}}else if(""===s.slice(0,2));else if(t.WTF)throw new Error(s)}}return n}(f,t));var p={};if((t.bookSheets||t.bookProps)&&(u.Sheets?r=u.Sheets.map((function(e){return e.name})):h.Worksheets&&h.SheetNames.length>0&&(r=h.SheetNames),t.bookProps&&(p.Props=h,p.Custprops=d),t.bookSheets&&"undefined"!==typeof r&&(p.SheetNames=r),t.bookSheets?p.SheetNames:t.bookProps))return p;r={};var m={};t.bookDeps&&s.calcchain&&(m=xc(tr(e,Au(s.calcchain)),s.calcchain));var g,v,b=0,y={},x=u.Sheets;h.Worksheets=x.length,h.SheetNames=[];for(var w=0;w!=x.length;++w)h.SheetNames[w]=x[w].name;var _=o?"bin":"xml",T=s.workbooks[0].lastIndexOf("/"),E=(s.workbooks[0].slice(0,T+1)+"_rels/"+s.workbooks[0].slice(T+1)+".rels").replace(/^\//,"");Jn(e,E)||(E="xl/_rels/workbook."+_+".rels");var k=Ea(nr(e,E,!0),E.replace(/_rels.*/,"s5s"));(s.metadata||[]).length>=1&&(t.xlmeta=_c(tr(e,Au(s.metadata[0])),s.metadata[0],t)),(s.people||[]).length>=1&&(t.people=function(e,t){var n=[],r=!1;return e.replace(hr,(function(e){var i=pr(e);switch(mr(i[0])){case"":case"":case"":case"":case"":break;case"":r=!1;break;default:if(!r&&t.WTF)throw new Error("unrecognized "+i[0]+" in threaded comments")}return e})),n}(tr(e,Au(s.people[0])),t)),k&&(k=function(e,t){if(!e)return 0;try{e=t.map((function(t){return t.id||(t.id=t.strRelID),[t.name,e["!id"][t.id].Target,(n=e["!id"][t.id].Type,_a.WS.indexOf(n)>-1?"sheet":_a.CS&&n==_a.CS?"chart":_a.DS&&n==_a.DS?"dialog":_a.MS&&n==_a.MS?"macro":n&&n.length?n:"sheet")];var n}))}catch(kC){return null}return e&&0!==e.length?e:null}(k,u.Sheets));var S=tr(e,"xl/worksheets/sheet.xml",!0)?1:0;e:for(b=0;b!=h.Worksheets;++b){var C="sheet";if(k&&k[b]?(g="xl/"+k[b][1].replace(/[\/]?xl\//,""),Jn(e,g)||(g=k[b][1]),Jn(e,g)||(g=E.replace(/_rels\/.*$/,"")+k[b][1]),C=k[b][2]):g=(g="xl/worksheets/sheet"+(b+1-S)+"."+_).replace(/sheet0\./,"sheet."),v=g.replace(/^(.*)(\/)([^\/]*)$/,"$1/_rels/$3.rels"),t&&null!=t.sheets)switch(typeof t.sheets){case"number":if(b!=t.sheets)continue e;break;case"string":if(h.SheetNames[b].toLowerCase()!=t.sheets.toLowerCase())continue e;break;default:if(Array.isArray&&Array.isArray(t.sheets)){for(var A=!1,M=0;M!=t.sheets.length;++M)"number"==typeof t.sheets[M]&&t.sheets[M]==b&&(A=1),"string"==typeof t.sheets[M]&&t.sheets[M].toLowerCase()==h.SheetNames[b].toLowerCase()&&(A=1);if(!A)continue e}}Cu(e,g,v,h.SheetNames[b],b,y,r,C,t,u,l,c)}return p={Directory:s,Workbook:u,Props:h,Custprops:d,Deps:m,Sheets:r,SheetNames:h.SheetNames,Strings:Ll,Styles:c,Themes:l,SSF:$n(Wt)},t&&t.bookFiles&&(e.files?(p.keys=a,p.files=e.files):(p.keys=[],p.files={},e.FullPaths.forEach((function(t,n){t=t.replace(/^Root Entry[\/]/,""),p.keys.push(t),p.files[t]=e.FileIndex[n]})))),t&&t.bookVBA&&(s.vba.length>0?p.vbaraw=tr(e,Au(s.vba[0]),!0):s.defaults&&s.defaults.bin===Uo&&(p.vbaraw=tr(e,"xl/vbaProject.bin",!0))),p}function Pu(e,t){var n=t||{},r="Workbook",i=Mn.find(e,r);try{if(r="/!DataSpaces/Version",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);if(function(e){var t={};t.id=e.read_shift(0,"lpp4"),t.R=Ks(e,4),t.U=Ks(e,4),t.W=Ks(e,4)}(i.content),r="/!DataSpaces/DataSpaceMap",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);var a=function(e){var t=[];e.l+=4;for(var n=e.read_shift(4);n-- >0;)t.push(Ys(e));return t}(i.content);if(1!==a.length||1!==a[0].comps.length||0!==a[0].comps[0].t||"StrongEncryptionDataSpace"!==a[0].name||"EncryptedPackage"!==a[0].comps[0].v)throw new Error("ECMA-376 Encrypted file bad "+r);if(r="/!DataSpaces/DataSpaceInfo/StrongEncryptionDataSpace",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);var s=function(e){var t=[];e.l+=4;for(var n=e.read_shift(4);n-- >0;)t.push(e.read_shift(0,"lpp4"));return t}(i.content);if(1!=s.length||"StrongEncryptionTransform"!=s[0])throw new Error("ECMA-376 Encrypted file bad "+r);if(r="/!DataSpaces/TransformInfo/StrongEncryptionTransform/!Primary",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);Xs(i.content)}catch(kC){}if(r="/EncryptionInfo",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);var o=function(e){var t=Ks(e);switch(t.Minor){case 2:return[t.Minor,Qs(e)];case 3:return[t.Minor,Js()];case 4:return[t.Minor,eo(e)]}throw new Error("ECMA-376 Encrypted file unrecognized Version: "+t.Minor)}(i.content);if(r="/EncryptedPackage",!(i=Mn.find(e,r))||!i.content)throw new Error("ECMA-376 Encrypted file missing "+r);if(4==o[0]&&"undefined"!==typeof decrypt_agile)return decrypt_agile(o[1],i.content,n.password||"",n);if(2==o[0]&&"undefined"!==typeof decrypt_std76)return decrypt_std76(o[1],i.content,n.password||"",n);throw new Error("File is password-protected")}function Ou(e,t){var n="";switch((t||{}).type||"base64"){case"buffer":case"array":return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7]];case"base64":n=Et(e.slice(0,12));break;case"binary":n=e;break;default:throw new Error("Unrecognized type "+(t&&t.type||"undefined"))}return[n.charCodeAt(0),n.charCodeAt(1),n.charCodeAt(2),n.charCodeAt(3),n.charCodeAt(4),n.charCodeAt(5),n.charCodeAt(6),n.charCodeAt(7)]}function Ru(e,t){var n=0;e:for(;n=2&&0===r[3])return Ns.to_workbook(i,n);if(0===r[2]&&(8===r[3]||9===r[3]))return Ns.to_workbook(i,n)}break;case 3:case 131:case 139:case 140:return Os.to_workbook(i,n);case 123:if(92===r[1]&&114===r[2]&&116===r[3])return ao.to_workbook(i,n);break;case 10:case 13:case 32:return function(e,t){var n="",r=Ou(e,t);switch(t.type){case"base64":n=Et(e);break;case"binary":n=e;break;case"buffer":n=e.toString("binary");break;case"array":n=Wn(e);break;default:throw new Error("Unrecognized type "+t.type)}return 239==r[0]&&187==r[1]&&191==r[2]&&(n=Ar(n)),t.type="binary",Ru(n,t)}(i,n);case 137:if(80===r[1]&&78===r[2]&&71===r[3])throw new Error("PNG Image File is not a spreadsheet")}return Ps.indexOf(r[0])>-1&&r[2]<=12&&r[3]<=31?Os.to_workbook(i,n):Du(e,i,n,a)}function Iu(e,t,n,r,i,a,s,o){var l=Di(n),c=o.defval,u=o.raw||!Object.prototype.hasOwnProperty.call(o,"raw"),h=!0,f=1===i?[]:{};if(1!==i)if(Object.defineProperty)try{Object.defineProperty(f,"__rowNum__",{value:n,enumerable:!1})}catch(kC){f.__rowNum__=n}else f.__rowNum__=n;if(!s||e[n])for(var d=t.s.c;d<=t.e.c;++d){var p=s?e[n][d]:e[r[d]+l];if(void 0!==p&&void 0!==p.t){var m=p.v;switch(p.t){case"z":if(null==m)break;continue;case"e":m=0==m?null:void 0;break;case"s":case"d":case"b":case"n":break;default:throw new Error("unrecognized type "+p.t)}if(null!=a[d]){if(null==m)if("e"==p.t&&null===m)f[a[d]]=null;else if(void 0!==c)f[a[d]]=c;else{if(!u||null!==m)continue;f[a[d]]=null}else f[a[d]]=u&&("n"!==p.t||"n"===p.t&&!1!==o.rawNumbers)?m:Ui(p,m,o);null!=m&&(h=!1)}}else{if(void 0===c)continue;null!=a[d]&&(f[a[d]]=c)}}return{row:f,isempty:h}}function Nu(e,t){if(null==e||null==e["!ref"])return[];var n={t:"n",v:0},r=0,i=1,a=[],s=0,o="",l={s:{r:0,c:0},e:{r:0,c:0}},c=t||{},u=null!=c.range?c.range:e["!ref"];switch(1===c.header?r=1:"A"===c.header?r=2:Array.isArray(c.header)?r=3:null==c.header&&(r=0),typeof u){case"string":l=ji(u);break;case"number":(l=ji(e["!ref"])).s.r=u;break;default:l=u}r>0&&(i=0);var h=Di(l.s.r),f=[],d=[],p=0,m=0,g=Array.isArray(e),v=l.s.r,b=0,y={};g&&!e[v]&&(e[v]=[]);var x=c.skipHidden&&e["!cols"]||[],w=c.skipHidden&&e["!rows"]||[];for(b=l.s.c;b<=l.e.c;++b)if(!(x[b]||{}).hidden)switch(f[b]=Ii(b),n=g?e[v][b]:e[f[b]+h],r){case 1:a[b]=b-l.s.c;break;case 2:a[b]=f[b];break;case 3:a[b]=c.header[b-l.s.c];break;default:if(null==n&&(n={w:"__EMPTY",t:"s"}),o=s=Ui(n,null,c),m=y[s]||0){do{o=s+"_"+m++}while(y[o]);y[s]=m,y[o]=1}else y[s]=1;a[b]=o}for(v=l.s.r+i;v<=l.e.r;++v)if(!(w[v]||{}).hidden){var _=Iu(e,l,v,f,r,a,g,c);(!1===_.isempty||(1===r?!1!==c.blankrows:c.blankrows))&&(d[p++]=_.row)}return d.length=p,d}var Fu=/"/g;function zu(e,t,n,r,i,a,s,o){for(var l=!0,c=[],u="",h=Di(n),f=t.s.c;f<=t.e.c;++f)if(r[f]){var d=o.dense?(e[n]||[])[f]:e[r[f]+h];if(null==d)u="";else if(null!=d.v){l=!1,u=""+(o.rawNumbers&&"n"==d.t?d.v:Ui(d,null,o));for(var p=0,m=0;p!==u.length;++p)if((m=u.charCodeAt(p))===i||m===a||34===m||o.forceQuotes){u='"'+u.replace(Fu,'""')+'"';break}"ID"==u&&(u='"ID"')}else null==d.f||d.F?u="":(l=!1,(u="="+d.f).indexOf(",")>=0&&(u='"'+u.replace(Fu,'""')+'"'));c.push(u)}return!1===o.blankrows&&l?null:c.join(s)}function Bu(e,t){var n=[],r=null==t?{}:t;if(null==e||null==e["!ref"])return"";var i=ji(e["!ref"]),a=void 0!==r.FS?r.FS:",",s=a.charCodeAt(0),o=void 0!==r.RS?r.RS:"\n",l=o.charCodeAt(0),c=new RegExp(("|"==a?"\\|":a)+"+$"),u="",h=[];r.dense=Array.isArray(e);for(var f=r.skipHidden&&e["!cols"]||[],d=r.skipHidden&&e["!rows"]||[],p=i.s.c;p<=i.e.c;++p)(f[p]||{}).hidden||(h[p]=Ii(p));for(var m=0,g=i.s.r;g<=i.e.r;++g)(d[g]||{}).hidden||null!=(u=zu(e,i,g,h,s,l,a,r))&&(r.strip&&(u=u.replace(c,"")),(u||!1!==r.blankrows)&&n.push((m++?o:"")+u));return delete r.dense,n.join("")}function ju(e,t){t||(t={}),t.FS="\t",t.RS="\n";var n=Bu(e,t);if("undefined"==typeof vt||"string"==t.type)return n;var r=vt.utils.encode(1200,n,"str");return String.fromCharCode(255)+String.fromCharCode(254)+r}function Vu(e,t,n){var r,i=n||{},a=+!i.skipHeader,s=e||{},o=0,l=0;if(s&&null!=i.origin)if("number"==typeof i.origin)o=i.origin;else{var c="string"==typeof i.origin?Ni(i.origin):i.origin;o=c.r,l=c.c}var u={s:{c:0,r:0},e:{c:l,r:o+t.length-1+a}};if(s["!ref"]){var h=ji(s["!ref"]);u.e.c=Math.max(u.e.c,h.e.c),u.e.r=Math.max(u.e.r,h.e.r),-1==o&&(o=h.e.r+1,u.e.r=o+t.length-1+a)}else-1==o&&(o=0,u.e.r=t.length-1+a);var f=i.header||[],d=0;t.forEach((function(e,t){On(e).forEach((function(n){-1==(d=f.indexOf(n))&&(f[d=f.length]=n);var c=e[n],u="z",h="",p=Fi({c:l+d,r:o+t+a});r=Uu(s,p),!c||"object"!==typeof c||c instanceof Date?("number"==typeof c?u="n":"boolean"==typeof c?u="b":"string"==typeof c?u="s":c instanceof Date?(u="d",i.cellDates||(u="n",c=Ln(c)),h=i.dateNF||Wt[14]):null===c&&i.nullError&&(u="e",c=0),r?(r.t=u,r.v=c,delete r.w,delete r.R,h&&(r.z=h)):s[p]=r={t:u,v:c},h&&(r.z=h)):s[p]=c}))})),u.e.c=Math.max(u.e.c,l+f.length-1);var p=Di(o);if(a)for(d=0;d=65535)throw new Error("Too many worksheets");if(r&&e.SheetNames.indexOf(n)>=0){var a=n.match(/(^.*?)(\d+)$/);i=a&&+a[2]||0;var s=a&&a[1]||n;for(++i;i<=65535&&-1!=e.SheetNames.indexOf(n=s+i);++i);}if(hc(n),e.SheetNames.indexOf(n)>=0)throw new Error("Worksheet with name |"+n+"| already exists!");return e.SheetNames.push(n),e.Sheets[n]=t,n}function $u(e,t,n){return t?(e.l={Target:t},n&&(e.l.Tooltip=n)):delete e.l,e}var Gu={encode_col:Ii,encode_row:Di,encode_cell:Fi,encode_range:Bi,decode_col:Li,decode_row:Ri,split_cell:function(e){return e.replace(/(\$?[A-Z]*)(\$?\d*)/,"$1,$2").split(",")},decode_cell:Ni,decode_range:zi,format_cell:Ui,sheet_add_aoa:Wi,sheet_add_json:Vu,sheet_add_dom:Qc,aoa_to_sheet:$i,json_to_sheet:function(e,t){return Vu(null,e,t)},table_to_sheet:Jc,table_to_book:function(e,t){return Hi(Jc(e,t),t)},sheet_to_csv:Bu,sheet_to_txt:ju,sheet_to_json:Nu,sheet_to_html:Zc,sheet_to_formulae:function(e){var t,n="",r="";if(null==e||null==e["!ref"])return[];var i,a=ji(e["!ref"]),s="",o=[],l=[],c=Array.isArray(e);for(i=a.s.c;i<=a.e.c;++i)o[i]=Ii(i);for(var u=a.s.r;u<=a.e.r;++u)for(s=Di(u),i=a.s.c;i<=a.e.c;++i)if(n=o[i]+s,r="",void 0!==(t=c?(e[u]||[])[i]:e[n])){if(null!=t.F){if(n=t.F,!t.f)continue;r=t.f,-1==n.indexOf(":")&&(n=n+":"+n)}if(null!=t.f)r=t.f;else{if("z"==t.t)continue;if("n"==t.t&&null!=t.v)r=""+t.v;else if("b"==t.t)r=t.v?"TRUE":"FALSE";else if(void 0!==t.w)r="'"+t.w;else{if(void 0===t.v)continue;r="s"==t.t?"'"+t.v:""+t.v}}l[l.length]=n+"="+r}return l},sheet_to_row_object_array:Nu,sheet_get_cell:Uu,book_new:Hu,book_append_sheet:Wu,book_set_sheet_visibility:function(e,t,n){e.Workbook||(e.Workbook={}),e.Workbook.Sheets||(e.Workbook.Sheets=[]);var r=function(e,t){if("number"==typeof t){if(t>=0&&e.SheetNames.length>t)return t;throw new Error("Cannot find sheet # "+t)}if("string"==typeof t){var n=e.SheetNames.indexOf(t);if(n>-1)return n;throw new Error("Cannot find sheet name |"+t+"|")}throw new Error("Cannot find sheet |"+t+"|")}(e,t);switch(e.Workbook.Sheets[r]||(e.Workbook.Sheets[r]={}),n){case 0:case 1:case 2:break;default:throw new Error("Bad sheet visibility setting "+n)}e.Workbook.Sheets[r].Hidden=n},cell_set_number_format:function(e,t){return e.z=t,e},cell_set_hyperlink:$u,cell_set_internal_link:function(e,t,n){return $u(e,"#"+t,n)},cell_add_comment:function(e,t,n){e.c||(e.c=[]),e.c.push({t:t,a:n||"SheetJS"})},sheet_set_array_formula:function(e,t,n,r){for(var i="string"!=typeof t?t:ji(t),a="string"==typeof t?t:Bi(t),s=i.s.r;s<=i.e.r;++s)for(var o=i.s.c;o<=i.e.c;++o){var l=Uu(e,s,o);l.t="n",l.F=a,delete l.v,s==i.s.r&&o==i.s.c&&(l.f=n,r&&(l.D=!0))}return e},consts:{SHEET_VISIBLE:0,SHEET_HIDDEN:1,SHEET_VERY_HIDDEN:2}};ot.version;const Ku=n.p+"static/media/Step 1 - Coordinates and Altitude.fe1aa07f594ec764c14a.png",Yu=n.p+"static/media/Step 1 - Coordinates only.046733c0988b82df7fb5.png",Xu=e=>(0,Ne.jsx)("div",{children:(()=>{if(e.file)return(0,Ne.jsxs)("table",{className:"divide-y divide-gray-200",children:[(0,Ne.jsx)("thead",{className:"bg-gray-200",children:(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Index"}),(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Latitude"}),(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Longitude"}),(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Altitude"})]})}),(0,Ne.jsx)("tbody",{className:"bg-white text-xs divide-y divide-gray-200",children:e.file.data.map(((e,t)=>(0,Ne.jsxs)("tr",{className:t%2===0?"bg-gray-50":"bg-white",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:t+1}),(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:e.Latitude}),(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:e.Longitude}),(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:e.Altitude?e.Altitude:"-"})]},t)))})]})})()});var qu=n(173),Zu=n.n(qu),Qu=n(283),Ju=n.n(Qu);function eh(e,t,n,r){return new(n||(n=Promise))((function(i,a){function s(e){try{l(r.next(e))}catch(kC){a(kC)}}function o(e){try{l(r.throw(e))}catch(kC){a(kC)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,o)}l((r=r.apply(e,t||[])).next())}))}function th(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}"function"===typeof SuppressedError&&SuppressedError;var nh=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var r,i,a;if(Array.isArray(t)){if((r=t.length)!=n.length)return!1;for(i=r;0!==i--;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((r=(a=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(i=r;0!==i--;)if(!Object.prototype.hasOwnProperty.call(n,a[i]))return!1;for(i=r;0!==i--;){var s=a[i];if(!e(t[s],n[s]))return!1}return!0}return t!==t&&n!==n},rh=th(nh);const ih="__googleMapsScriptId";var ah;!function(e){e[e.INITIALIZED=0]="INITIALIZED",e[e.LOADING=1]="LOADING",e[e.SUCCESS=2]="SUCCESS",e[e.FAILURE=3]="FAILURE"}(ah||(ah={}));class sh{constructor(e){let{apiKey:t,authReferrerPolicy:n,channel:r,client:i,id:a=ih,language:s,libraries:o=[],mapIds:l,nonce:c,region:u,retries:h=3,url:f="https://maps.googleapis.com/maps/api/js",version:d}=e;if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=t,this.authReferrerPolicy=n,this.channel=r,this.client=i,this.id=a||ih,this.language=s,this.libraries=o,this.mapIds=l,this.nonce=c,this.region=u,this.retries=h,this.url=f,this.version=d,sh.instance){if(!rh(this.options,sh.instance.options))throw new Error("Loader must not be called again with different options. ".concat(JSON.stringify(this.options)," !== ").concat(JSON.stringify(sh.instance.options)));return sh.instance}sh.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?ah.FAILURE:this.done?ah.SUCCESS:this.loading?ah.LOADING:ah.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let e=this.url;return e+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(e+="&key=".concat(this.apiKey)),this.channel&&(e+="&channel=".concat(this.channel)),this.client&&(e+="&client=".concat(this.client)),this.libraries.length>0&&(e+="&libraries=".concat(this.libraries.join(","))),this.language&&(e+="&language=".concat(this.language)),this.region&&(e+="®ion=".concat(this.region)),this.version&&(e+="&v=".concat(this.version)),this.mapIds&&(e+="&map_ids=".concat(this.mapIds.join(","))),this.authReferrerPolicy&&(e+="&auth_referrer_policy=".concat(this.authReferrerPolicy)),e}deleteScript(){const e=document.getElementById(this.id);e&&e.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise(((e,t)=>{this.loadCallback((n=>{n?t(n.error):e(window.google)}))}))}importLibrary(e){return this.execute(),google.maps.importLibrary(e)}loadCallback(e){this.callbacks.push(e),this.execute()}setScript(){var e,t;if(document.getElementById(this.id))return void this.callback();const n={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};Object.keys(n).forEach((e=>!n[e]&&delete n[e])),(null===(t=null===(e=null===window||void 0===window?void 0:window.google)||void 0===e?void 0:e.maps)||void 0===t?void 0:t.importLibrary)||(e=>{let t,n,r,i="The Google Maps JavaScript API",a="google",s="importLibrary",o="__ib__",l=document,c=window;c=c[a]||(c[a]={});const u=c.maps||(c.maps={}),h=new Set,f=new URLSearchParams,d=()=>t||(t=new Promise(((s,c)=>eh(this,void 0,void 0,(function*(){var d;for(r in yield n=l.createElement("script"),n.id=this.id,f.set("libraries",[...h]+""),e)f.set(r.replace(/[A-Z]/g,(e=>"_"+e[0].toLowerCase())),e[r]);f.set("callback",a+".maps."+o),n.src=this.url+"?"+f,u[o]=s,n.onerror=()=>t=c(Error(i+" could not load.")),n.nonce=this.nonce||(null===(d=l.querySelector("script[nonce]"))||void 0===d?void 0:d.nonce)||"",l.head.append(n)})))));u[s]?console.warn(i+" only loads once. Ignoring:",e):u[s]=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;ru[s](e,...n)))}})(n);const r=this.libraries.map((e=>this.importLibrary(e)));r.length||r.push(this.importLibrary("core")),Promise.all(r).then((()=>this.callback()),(e=>{const t=new ErrorEvent("error",{error:e});this.loadErrorCallback(t)}))}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(e){if(this.errors.push(e),this.errors.length<=this.retries){const e=this.errors.length*Math.pow(2,this.errors.length);console.error("Failed to load Google Maps script, retrying in ".concat(e," ms.")),setTimeout((()=>{this.deleteScript(),this.setScript()}),e)}else this.onerrorEvent=e,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach((e=>{e(this.onerrorEvent)})),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version)return console.warn("Google Maps already loaded outside @googlemaps/js-api-loader.This may result in undesirable behavior as options and script parameters may not match."),void this.callback();this.loading||(this.loading=!0,this.setScript())}}}var oh=n(353),lh=n.n(oh);function ch(){return(ch=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Ch);return Eh||(Eh=new sh(ch({apiKey:r||""},i,{libraries:n}))),kh=Eh.load().then((function(){return Sh(window.google.maps),window.google.maps})),Sh(kh),kh};function Ph(e,t,n){var r=n-t;return e===n?e:((e-t)%r+r)%r+t}var Oh=function(){function e(e,t){if(isNaN(e)||isNaN(t))throw new Error("Invalid LatLng object: ("+e+", "+t+")");this.lat=+e,this.lng=+t}return e.prototype.wrap=function(){return new e(this.lat,Ph(this.lng,-180,180))},e}();Oh.convert=function(e){return e instanceof Oh?e:Array.isArray(e)?new Oh(e[0],e[1]):"lng"in e&&"lat"in e?new Oh(e.lat,e.lng):e};var Rh=function(){function e(e,t,n){this.tileSize=e||512,this._minZoom=t||0,this._maxZoom=n||52,this.latRange=[-85.05113,85.05113],this.width=0,this.height=0,this.zoom=0,this.center=new Oh(0,0),this.angle=0}var t,n,r=e.prototype;return r.zoomScale=function(e){return Math.pow(2,e)},r.scaleZoom=function(e){return Math.log(e)/Math.LN2},r.project=function(e,t){return new(lh())(this.lngX(e.lng,t),this.latY(e.lat,t))},r.unproject=function(e,t){return new Oh(this.yLat(e.y,t),this.xLng(e.x,t))},r.lngX=function(e,t){return(180+e)*(t||this.worldSize)/360},r.latY=function(e,t){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))*(t||this.worldSize)/360},r.xLng=function(e,t){return 360*e/(t||this.worldSize)-180},r.yLat=function(e,t){return 360/Math.PI*Math.atan(Math.exp((180-360*e/(t||this.worldSize))*Math.PI/180))-90},r.locationPoint=function(e){var t=this.project(e);return this.centerPoint._sub(this.point._sub(t)._rotate(this.angle))},r.pointLocation=function(e){var t=this.centerPoint._sub(e)._rotate(-this.angle);return this.unproject(this.point.sub(t))},t=e,(n=[{key:"minZoom",get:function(){return this._minZoom},set:function(e){this._minZoom=e,this.zoom=Math.max(this.zoom,e)}},{key:"maxZoom",get:function(){return this._maxZoom},set:function(e){this._maxZoom=e,this.zoom=Math.min(this.zoom,e)}},{key:"worldSize",get:function(){return this.tileSize*this.scale}},{key:"centerPoint",get:function(){return new(lh())(0,0)}},{key:"size",get:function(){return new(lh())(this.width,this.height)}},{key:"bearing",get:function(){return-this.angle/Math.PI*180},set:function(e){this.angle=-Ph(e,-180,180)*Math.PI/180}},{key:"zoom",get:function(){return this._zoom},set:function(e){var t=Math.min(Math.max(e,this.minZoom),this.maxZoom);this._zoom=t,this.scale=this.zoomScale(t),this.tileZoom=Math.floor(t),this.zoomFraction=t-this.tileZoom}},{key:"x",get:function(){return this.lngX(this.center.lng)}},{key:"y",get:function(){return this.latY(this.center.lat)}},{key:"point",get:function(){return new(lh())(this.x,this.y)}}])&&function(e,t){for(var n=0;n0&&this.getHeight()-n-i>0){var s=this.transform_.pointLocation(lh().convert({x:a-this.getWidth()/2,y:n-this.getHeight()/2})),o=this.transform_.pointLocation(lh().convert({x:this.getWidth()/2-r,y:this.getHeight()/2-i})),l=[s.lat,s.lng,o.lat,o.lng,o.lat,s.lng,s.lat,o.lng];return t&&(l=l.map((function(e){return Math.round(e*t)/t}))),l}return[0,0,0,0]},e}();function Lh(e){if(window.requestAnimationFrame)return window.requestAnimationFrame(e);var t=window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame;return t?t(e):window.setTimeout(e,1e3/60)}var Ih=Math.log2?Math.log2:function(e){return Math.log(e)/Math.LN2};function Nh(e,t){return Object.keys(e).reduce((function(n,r){return t(e[r])&&(n[r]=e[r]),n}),{})}var Fh=function(e){if(null!==e&&"object"==typeof e){if(0===Object.keys(e).length)return!0}else if(null==e||""===e)return!0;return!1},zh=Object.prototype.toString;function Bh(e){return"number"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Number]"===zh.call(e)}var jh=null;function Vh(){if(jh)return jh;if("undefined"!=typeof navigator){var e=navigator.userAgent.indexOf("MSIE")>-1,t=navigator.userAgent.indexOf("Firefox")>-1,n=navigator.userAgent.toLowerCase().indexOf("op")>-1,r=navigator.userAgent.indexOf("Chrome")>-1,i=navigator.userAgent.indexOf("Safari")>-1;return r&&i&&(i=!1),r&&n&&(r=!1),jh={isExplorer:e,isFirefox:t,isOpera:n,isChrome:r,isSafari:i}}return jh={isChrome:!0,isExplorer:!1,isFirefox:!1,isOpera:!1,isSafari:!1}}var Uh=function(e){return Function.prototype.toString.call(e)};function Hh(e){if(!e||"object"!=typeof e)return!1;var t="function"==typeof e.constructor?Object.getPrototypeOf(e):Object.prototype;if(null===t)return!0;var n=t.constructor;return"function"==typeof n&&n instanceof n&&Uh(n)===Uh(Object)}function Wh(e,t,n,r){e.addEventListener(t,n,function(){var e=!1;try{var t=Object.defineProperty({},"passive",{get:function(){e=!0}});window.addEventListener("test",t,t),window.removeEventListener("test",t,t)}catch(t){e=!1}return e}()?{capture:r,passive:!0}:r)}var $h,Gh=!("undefined"==typeof window||!window.document||!window.document.createElement);$h=Gh?window:"undefined"!=typeof self?self:void 0;var Kh,Yh="undefined"!=typeof document&&document.attachEvent,Xh=!1;if(Gh&&!Yh){var qh=function(){var e=$h.requestAnimationFrame||$h.mozRequestAnimationFrame||$h.webkitRequestAnimationFrame||function(e){return $h.setTimeout(e,20)};return function(t){return e(t)}}(),Zh=(Kh=$h.cancelAnimationFrame||$h.mozCancelAnimationFrame||$h.webkitCancelAnimationFrame||$h.clearTimeout,function(e){return Kh(e)}),Qh=function(e){var t=e.__resizeTriggers__,n=t.firstElementChild,r=t.lastElementChild,i=n.firstElementChild;r.scrollLeft=r.scrollWidth,r.scrollTop=r.scrollHeight,i.style.width=n.offsetWidth+1+"px",i.style.height=n.offsetHeight+1+"px",n.scrollLeft=n.scrollWidth,n.scrollTop=n.scrollHeight},Jh=function(e){var t=this;Qh(this),this.__resizeRAF__&&Zh(this.__resizeRAF__),this.__resizeRAF__=qh((function(){(function(e){return e.offsetWidth!=e.__resizeLast__.width||e.offsetHeight!=e.__resizeLast__.height})(t)&&(t.__resizeLast__.width=t.offsetWidth,t.__resizeLast__.height=t.offsetHeight,t.__resizeListeners__.forEach((function(n){n.call(t,e)})))}))},ef=!1,tf="",nf="animationstart",rf="Webkit Moz O ms".split(" "),af="webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" ");if(Gh){var sf=document.createElement("fakeelement");if(void 0!==sf.style.animationName&&(ef=!0),!1===ef)for(var of=0;of0||r.geoService_.getHeight()>0){var e=Math.ceil(r.geoService_.getWidth()/256)+2,t=Math.ceil(r.geoService_.getHeight()/256)+2,n=Math.max(e,t);return Math.ceil(Ih(n))}return 3},r._computeMinZoom=function(e){return Fh(e)?r._getMinZoom():e},r._mapDomResizeCallback=function(){if(r.resetSizeOnIdle_=!0,r.maps_){var e=r.props.center||r.props.defaultCenter,t=r.map_.getCenter();r.maps_.event.trigger(r.map_,"resize"),r.map_.setCenter(r.props.resetBoundsOnResize?e:t)}},r._setLayers=function(e){e.forEach((function(e){r.layers_[e]=new r.maps_[e],r.layers_[e].setMap(r.map_)}))},r._renderPortal=function(){return e.createElement(wh,{experimental:r.props.experimental,onChildClick:r._onChildClick,onChildMouseDown:r._onChildMouseDown,onChildMouseEnter:r._onChildMouseEnter,onChildMouseLeave:r._onChildMouseLeave,geoService:r.geoService_,insideMapPanes:!0,distanceToMouse:r.props.distanceToMouse,getHoverDistance:r._getHoverDistance,dispatcher:r.markersDispatcher_})},r._initMap=function(){if(!r.initialized_){r.initialized_=!0;var e=df(r.props.center||r.props.defaultCenter);r.geoService_.setView(e,r.props.zoom||r.props.defaultZoom,0),r._onBoundsChanged();var t=ch({},r.props.apiKey&&{key:r.props.apiKey},r.props.bootstrapURLKeys);r.props.googleMapLoader(t,r.props.heatmapLibrary).then((function(e){if(r.mounted_){var t,n,i=r.geoService_.getCenter(),a={zoom:r.props.zoom||r.props.defaultZoom,center:new e.LatLng(i.lat,i.lng)};r.props.heatmap.positions&&(Object.assign(hh(r),{heatmap:(t=e,n=r.props.heatmap,new t.visualization.HeatmapLayer({data:n.positions.reduce((function(e,n){var r=n.weight,i=void 0===r?1:r;return e.push({location:new t.LatLng(n.lat,n.lng),weight:i}),e}),[])}))}),function(e,t){var n=t.options,r=void 0===n?{}:n;Object.keys(r).map((function(t){return e.set(t,r[t])}))}(r.heatmap,r.props.heatmap));var o=Nh(e,Hh),l="function"==typeof r.props.options?r.props.options(o):r.props.options,c=!Fh(r.props.draggable)&&{draggable:r.props.draggable},u=r._computeMinZoom(l.minZoom);r.minZoom_=u;var h=ch({},{overviewMapControl:!1,streetViewControl:!1,rotateControl:!0,mapTypeControl:!1,styles:[{featureType:"poi",elementType:"labels",stylers:[{visibility:"off"}]}],minZoom:3},{minZoom:u},l,a);r.defaultDraggableOption_=Fh(h.draggable)?r.defaultDraggableOption_:h.draggable;var f=ch({},h,c);f.minZoom=pf(f.minZoom,u);var d=new e.Map(s.findDOMNode(r.googleMapDom_),f);r.map_=d,r.maps_=e,r._setLayers(r.props.layerTypes);var p=e.version.match(/^3\.(\d+)\./),m=p&&Number(p[1]),g=hh(r),v=Object.assign(new e.OverlayView,{onAdd:function(){var t="undefined"!=typeof screen?screen.width+"px":"2000px",n="undefined"!=typeof screen?screen.height+"px":"2000px",r=document.createElement("div");if(r.style.backgroundColor="transparent",r.style.position="absolute",r.style.left="0px",r.style.top="0px",r.style.width=t,r.style.height=n,g.props.overlayViewDivStyle){var i=g.props.overlayViewDivStyle;"object"==typeof i&&Object.keys(i).forEach((function(e){r.style[e]=i[e]}))}this.getPanes().overlayMouseTarget.appendChild(r),g.geoService_.setMapCanvasProjection(e,v.getProjection()),hf?g.setState({overlay:r}):ff(g,g._renderPortal(),r,(function(){return g.setState({overlay:r})}))},onRemove:function(){var e=g.state.overlay;e&&!hf&&s.unmountComponentAtNode(e),g.setState({overlay:null})},draw:function(){if(g.updateCounter_++,g._onBoundsChanged(d,e,!g.props.debounced),g.googleApiLoadedCalled_||(g._onGoogleApiLoaded({map:d,maps:e,ref:g.googleMapDom_}),g.googleApiLoadedCalled_=!0),g.mouse_){var t=g.geoService_.fromContainerPixelToLatLng(g.mouse_);g.mouse_.lat=t.lat,g.mouse_.lng=t.lng}g._onChildMouseMove(),g.markersDispatcher_&&(g.markersDispatcher_.emit("kON_CHANGE"),g.fireMouseEventOnIdle_&&g.markersDispatcher_.emit("kON_MOUSE_POSITION_CHANGE"))}});r.overlay_=v,v.setMap(d),r.props.heatmap.positions&&r.heatmap.setMap(d),r.props.onTilesLoaded&&e.event.addListener(d,"tilesloaded",(function(){g._onTilesLoaded()})),e.event.addListener(d,"zoom_changed",(function(){g.geoService_.getZoom()!==d.getZoom()&&(g.zoomAnimationInProgress_||(g.zoomAnimationInProgress_=!0,g._onZoomAnimationStart(d.zoom)),m<32)&&((new Date).getTime()-r.zoomControlClickTime_<300?Lh((function(){return Lh((function(){g.updateCounter_++,g._onBoundsChanged(d,e)}))})):(g.updateCounter_++,g._onBoundsChanged(d,e)))})),e.event.addListener(d,"idle",(function(){if(r.resetSizeOnIdle_){r._setViewSize();var t=r._computeMinZoom(l.minZoom);t!==r.minZoom_&&(r.minZoom_=t,d.setOptions({minZoom:t})),r.resetSizeOnIdle_=!1}g.zoomAnimationInProgress_&&(g.zoomAnimationInProgress_=!1,g._onZoomAnimationEnd(d.zoom)),g.updateCounter_++,g._onBoundsChanged(d,e),g.dragTime_=0,g.markersDispatcher_&&g.markersDispatcher_.emit("kON_CHANGE")})),e.event.addListener(d,"mouseover",(function(){g.mouseInMap_=!0})),e.event.addListener(d,"click",(function(){g.mouseInMap_=!0})),e.event.addListener(d,"mouseout",(function(){g.mouseInMap_=!1,g.mouse_=null,g.markersDispatcher_.emit("kON_MOUSE_POSITION_CHANGE")})),e.event.addListener(d,"drag",(function(){g.dragTime_=(new Date).getTime(),g._onDrag(d)})),e.event.addListener(d,"dragend",(function(){var t=e.event.addListener(d,"idle",(function(){e.event.removeListener(t),g._onDragEnd(d)}))})),e.event.addListener(d,"maptypeid_changed",(function(){g._onMapTypeIdChange(d.getMapTypeId())}))}})).catch((function(e){throw r._onGoogleApiLoaded({map:null,maps:null,ref:r.googleMapDom_}),console.error(e),e}))}},r._onGoogleApiLoaded=function(){var e;r.props.onGoogleApiLoaded&&(e=r.props).onGoogleApiLoaded.apply(e,arguments)},r._getHoverDistance=function(){return r.props.hoverDistance},r._onDrag=function(){var e;return r.props.onDrag&&(e=r.props).onDrag.apply(e,arguments)},r._onDragEnd=function(){var e;return r.props.onDragEnd&&(e=r.props).onDragEnd.apply(e,arguments)},r._onMapTypeIdChange=function(){var e;return r.props.onMapTypeIdChange&&(e=r.props).onMapTypeIdChange.apply(e,arguments)},r._onZoomAnimationStart=function(){var e;return r.props.onZoomAnimationStart&&(e=r.props).onZoomAnimationStart.apply(e,arguments)},r._onZoomAnimationEnd=function(){var e;return r.props.onZoomAnimationEnd&&(e=r.props).onZoomAnimationEnd.apply(e,arguments)},r._onTilesLoaded=function(){return r.props.onTilesLoaded&&r.props.onTilesLoaded()},r._onChildClick=function(){var e;if(r.props.onChildClick)return(e=r.props).onChildClick.apply(e,arguments)},r._onChildMouseDown=function(e,t){r.childMouseDownArgs_=[e,t],r.props.onChildMouseDown&&r.props.onChildMouseDown(e,t,ch({},r.mouse_))},r._onChildMouseUp=function(){var e;r.childMouseDownArgs_&&(r.props.onChildMouseUp&&(e=r.props).onChildMouseUp.apply(e,r.childMouseDownArgs_.concat([ch({},r.mouse_)])),r.childMouseDownArgs_=null,r.childMouseUpTime_=(new Date).getTime())},r._onChildMouseMove=function(){var e;r.childMouseDownArgs_&&r.props.onChildMouseMove&&(e=r.props).onChildMouseMove.apply(e,r.childMouseDownArgs_.concat([ch({},r.mouse_)]))},r._onChildMouseEnter=function(){var e;if(r.props.onChildMouseEnter)return(e=r.props).onChildMouseEnter.apply(e,arguments)},r._onChildMouseLeave=function(){var e;if(r.props.onChildMouseLeave)return(e=r.props).onChildMouseLeave.apply(e,arguments)},r._setViewSize=function(){if(r.mounted_){if(document.fullscreen||document.webkitIsFullScreen||document.mozFullScreen||document.msFullscreenElement)r.geoService_.setViewSize(window.innerWidth,window.innerHeight);else{var e=s.findDOMNode(r.googleMapDom_);r.geoService_.setViewSize(e.clientWidth,e.clientHeight)}r._onBoundsChanged()}},r._onWindowResize=function(){r.resetSizeOnIdle_=!0},r._onMapMouseMove=function(e){if(r.mouseInMap_){var t=(new Date).getTime();t-r.mouseMoveTime_>50&&(r.boundingRect_=e.currentTarget.getBoundingClientRect()),r.mouseMoveTime_=t;var n=e.clientX-r.boundingRect_.left,i=e.clientY-r.boundingRect_.top;r.mouse_||(r.mouse_={x:0,y:0,lat:0,lng:0}),r.mouse_.x=n,r.mouse_.y=i;var a=r.geoService_.fromContainerPixelToLatLng(r.mouse_);r.mouse_.lat=a.lat,r.mouse_.lng=a.lng,r._onChildMouseMove(),t-r.dragTime_<100?r.fireMouseEventOnIdle_=!0:(r.markersDispatcher_.emit("kON_MOUSE_POSITION_CHANGE"),r.fireMouseEventOnIdle_=!1)}},r._onClick=function(){var e;return r.props.onClick&&!r.childMouseDownArgs_&&(new Date).getTime()-r.childMouseUpTime_>300&&0===r.dragTime_&&(e=r.props).onClick.apply(e,arguments)},r._onMapClick=function(e){r.markersDispatcher_&&(r._onMapMouseMove(e),(new Date).getTime()-r.dragTime_>100&&(r.mouse_&&r._onClick(ch({},r.mouse_,{event:e})),r.markersDispatcher_.emit("kON_CLICK",e)))},r._onMapMouseDownNative=function(e){r.mouseInMap_&&r._onMapMouseDown(e)},r._onMapMouseDown=function(e){r.markersDispatcher_&&(new Date).getTime()-r.dragTime_>100&&(r._onMapMouseMove(e),r.markersDispatcher_.emit("kON_MDOWN",e))},r._onMapMouseDownCapture=function(){Vh().isChrome&&(r.zoomControlClickTime_=(new Date).getTime())},r._onKeyDownCapture=function(){Vh().isChrome&&(r.zoomControlClickTime_=(new Date).getTime())},r._isCenterDefined=function(e){return e&&(Hh(e)&&Bh(e.lat)&&Bh(e.lng)||2===e.length&&Bh(e[0])&&Bh(e[1]))},r._onBoundsChanged=function(e,t,n){if(e){var i=e.getCenter();r.geoService_.setView([i.lat(),i.lng()],e.getZoom(),0)}if((r.props.onChange||r.props.onBoundsChange)&&r.geoService_.canProject()){var a=r.geoService_.getZoom(),s=r.geoService_.getBounds(),o=r.geoService_.getCenter();if(!function(e,t,n){if(e&&t){for(var r=0;r!==e.length;++r)if(Math.abs(e[r]-t[r])>1e-5)return!1;return!0}return!1}(s,r.prevBounds_)&&!1!==n){var l=r.geoService_.getBounds(r.props.margin);r.props.onBoundsChange&&r.props.onBoundsChange(r.centerIsObject_?ch({},o):[o.lat,o.lng],a,s,l),r.props.onChange&&r.props.onChange({center:ch({},o),zoom:a,bounds:{nw:{lat:s[0],lng:s[1]},se:{lat:s[2],lng:s[3]},sw:{lat:s[4],lng:s[5]},ne:{lat:s[6],lng:s[7]}},marginBounds:{nw:{lat:l[0],lng:l[1]},se:{lat:l[2],lng:l[3]},sw:{lat:l[4],lng:l[5]},ne:{lat:l[6],lng:l[7]}},size:r.geoService_.hasSize()?{width:r.geoService_.getWidth(),height:r.geoService_.getHeight()}:{width:0,height:0}}),r.prevBounds_=s}}},r._registerChild=function(e){r.googleMapDom_=e},r.mounted_=!1,r.initialized_=!1,r.googleApiLoadedCalled_=!1,r.map_=null,r.maps_=null,r.prevBounds_=null,r.heatmap=null,r.layers_={},r.mouse_=null,r.mouseMoveTime_=0,r.boundingRect_=null,r.mouseInMap_=!0,r.dragTime_=0,r.fireMouseEventOnIdle_=!1,r.updateCounter_=0,r.markersDispatcher_=new ph(hh(r)),r.geoService_=new Dh(256),r.centerIsObject_=Hh(r.props.center),r.minZoom_=3,r.defaultDraggableOption_=!0,r.zoomControlClickTime_=0,r.childMouseDownArgs_=null,r.childMouseUpTime_=0,r.googleMapDom_=null,r._isCenterDefined(r.props.center||r.props.defaultCenter)){var i=df(r.props.center||r.props.defaultCenter);r.geoService_.setView(i,r.props.zoom||r.props.defaultZoom,0)}return r.zoomAnimationInProgress_=!1,r.state={overlay:null},r}uh(n,t);var r=n.prototype;return r.componentDidMount=function(){var e=this;this.mounted_=!0,this.markersDispatcher_=new ph(this),Wh(window,"resize",this._onWindowResize,!1),Wh(window,"keydown",this._onKeyDownCapture,!0);var t=s.findDOMNode(this.googleMapDom_);t&&Wh(t,"mousedown",this._onMapMouseDownNative,!0),Wh(window,"mouseup",this._onChildMouseUp,!1);var n=ch({},this.props.apiKey&&{key:this.props.apiKey},this.props.bootstrapURLKeys);this.props.googleMapLoader(n,this.props.heatmapLibrary),setTimeout((function(){e._setViewSize(),e._isCenterDefined(e.props.center||e.props.defaultCenter)&&e._initMap()}),0,this),this.props.resetBoundsOnResize&&function(e,t){if(void 0===e.parentNode){var n=document.createElement("div");e.parentNode=n}e=e.parentNode,Yh?e.attachEvent("onresize",t):(e.__resizeTriggers__||("static"==getComputedStyle(e).position&&(e.style.position="relative"),function(){if(!Xh){var e=(cf||"")+".resize-triggers { "+(uf||"")+'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }',t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e)),t.appendChild(n),Xh=!0}}(),e.__resizeLast__={},e.__resizeListeners__=[],(e.__resizeTriggers__=document.createElement("div")).className="resize-triggers",e.__resizeTriggers__.innerHTML='',e.appendChild(e.__resizeTriggers__),Qh(e),Wh(e,"scroll",Jh,!0),nf&&e.__resizeTriggers__.addEventListener(nf,(function(t){t.animationName==lf&&Qh(e)}))),e.__resizeListeners__.push(t))}(t,this._mapDomResizeCallback)},r.shouldComponentUpdate=function(e,t){return!bh(mh(this.props,["draggable"]),mh(e,["draggable"]))||!bh(this.state,t)},r.componentDidUpdate=function(e){var t=this;if(!this._isCenterDefined(e.center)&&this._isCenterDefined(this.props.center)&&setTimeout((function(){return t._initMap()}),0),this.map_){var n=this.geoService_.getCenter();if(this._isCenterDefined(this.props.center)){var r=df(this.props.center),i=this._isCenterDefined(e.center)?df(e.center):null;(!i||Math.abs(r.lat-i.lat)+Math.abs(r.lng-i.lng)>1e-5)&&Math.abs(r.lat-n.lat)+Math.abs(r.lng-n.lng)>1e-5&&this.map_.panTo({lat:r.lat,lng:r.lng})}if(Fh(this.props.zoom)||Math.abs(this.props.zoom-e.zoom)>0&&this.map_.setZoom(this.props.zoom),!Fh(e.draggable)&&Fh(this.props.draggable)?this.map_.setOptions({draggable:this.defaultDraggableOption_}):bh(e.draggable,this.props.draggable)||this.map_.setOptions({draggable:this.props.draggable}),!Fh(this.props.options)&&!bh(e.options,this.props.options)){var a=Nh(this.maps_,Hh),s="function"==typeof this.props.options?this.props.options(a):this.props.options;if("minZoom"in(s=mh(s,["zoom","center","draggable"]))){var o=this._computeMinZoom(s.minZoom);s.minZoom=pf(s.minZoom,o)}this.map_.setOptions(s)}bh(this.props.layerTypes,e.layerTypes)||(Object.keys(this.layers_).forEach((function(e){t.layers_[e].setMap(null),delete t.layers_[e]})),this._setLayers(this.props.layerTypes)),this.heatmap&&!bh(this.props.heatmap.positions,e.heatmap.positions)&&this.heatmap.setData(this.props.heatmap.positions.map((function(e){return{location:new t.maps_.LatLng(e.lat,e.lng),weight:e.weight}}))),this.heatmap&&!bh(this.props.heatmap.options,e.heatmap.options)&&Object.keys(this.props.heatmap.options).forEach((function(e){t.heatmap.set(e,t.props.heatmap.options[e])}))}this.markersDispatcher_.emit("kON_CHANGE"),bh(this.props.hoverDistance,e.hoverDistance)||this.markersDispatcher_.emit("kON_MOUSE_POSITION_CHANGE")},r.componentWillUnmount=function(){this.mounted_=!1;var e,t,n=s.findDOMNode(this.googleMapDom_);n&&n.removeEventListener("mousedown",this._onMapMouseDownNative,!0),window.removeEventListener("resize",this._onWindowResize),window.removeEventListener("keydown",this._onKeyDownCapture),window.removeEventListener("mouseup",this._onChildMouseUp,!1),this.props.resetBoundsOnResize&&(t=this._mapDomResizeCallback,e=(e=n).parentNode,Yh?e.detachEvent("onresize",t):(e.__resizeListeners__.splice(e.__resizeListeners__.indexOf(t),1),e.__resizeListeners__.length||(e.removeEventListener("scroll",Jh),e.__resizeTriggers__=!e.removeChild(e.__resizeTriggers__)))),this.overlay_&&this.overlay_.setMap(null),this.maps_&&this.map_&&this.props.shouldUnregisterMapOnUnmount&&(this.map_.setOptions({scrollwheel:!1}),this.maps_.event.clearInstanceListeners(this.map_)),this.props.shouldUnregisterMapOnUnmount&&(this.map_=null,this.maps_=null),this.markersDispatcher_.dispose(),this.resetSizeOnIdle_=!1,this.props.shouldUnregisterMapOnUnmount&&(delete this.map_,delete this.markersDispatcher_)},r.render=function(){var t=this.state.overlay,n=t?null:e.createElement(Th,{experimental:this.props.experimental,onChildClick:this._onChildClick,onChildMouseDown:this._onChildMouseDown,onChildMouseEnter:this._onChildMouseEnter,onChildMouseLeave:this._onChildMouseLeave,geoService:this.geoService_,insideMapPanes:!1,distanceToMouse:this.props.distanceToMouse,getHoverDistance:this._getHoverDistance,dispatcher:this.markersDispatcher_});return e.createElement("div",{style:this.props.style,onMouseMove:this._onMapMouseMove,onMouseDownCapture:this._onMapMouseDownCapture,onClick:this._onMapClick},e.createElement(dh,{registerChild:this._registerChild}),hf&&t&&ff(this._renderPortal(),t),n)},n}(e.Component);mf.propTypes={apiKey:Zu().string,bootstrapURLKeys:Zu().any,defaultCenter:Zu().oneOfType([Zu().array,Zu().shape({lat:Zu().number,lng:Zu().number})]),center:Zu().oneOfType([Zu().array,Zu().shape({lat:Zu().number,lng:Zu().number})]),defaultZoom:Zu().number,zoom:Zu().number,onBoundsChange:Zu().func,onChange:Zu().func,onClick:Zu().func,onChildClick:Zu().func,onChildMouseDown:Zu().func,onChildMouseUp:Zu().func,onChildMouseMove:Zu().func,onChildMouseEnter:Zu().func,onChildMouseLeave:Zu().func,onZoomAnimationStart:Zu().func,onZoomAnimationEnd:Zu().func,onDrag:Zu().func,onDragEnd:Zu().func,onMapTypeIdChange:Zu().func,onTilesLoaded:Zu().func,options:Zu().any,distanceToMouse:Zu().func,hoverDistance:Zu().number,debounced:Zu().bool,margin:Zu().array,googleMapLoader:Zu().any,onGoogleApiLoaded:Zu().func,yesIWantToUseGoogleMapApiInternals:Zu().bool,draggable:Zu().bool,style:Zu().any,resetBoundsOnResize:Zu().bool,layerTypes:Zu().arrayOf(Zu().string),shouldUnregisterMapOnUnmount:Zu().bool},mf.defaultProps={distanceToMouse:function(e,t){return Math.sqrt((e.x-t.x)*(e.x-t.x)+(e.y-t.y)*(e.y-t.y))},hoverDistance:30,debounced:!0,options:function(){return{overviewMapControl:!1,streetViewControl:!1,rotateControl:!0,mapTypeControl:!1,styles:[{featureType:"poi",elementType:"labels",stylers:[{visibility:"off"}]}],minZoom:3}},googleMapLoader:Mh,yesIWantToUseGoogleMapApiInternals:!1,style:{width:"100%",height:"100%",margin:0,padding:0,position:"relative"},layerTypes:[],heatmap:{},heatmapLibrary:!1,shouldUnregisterMapOnUnmount:!0},mf.googleMapLoader=Mh;const gf=t=>{const{file:n,refLat:r,refLong:i,refAlt:a,startButton:s,setPlotData:o}=t,[l,c]=(0,e.useState)([]),[u,h]=(0,e.useState)([]),[f,d]=(0,e.useState)([]),[p,m]=(0,e.useState)([]),[g,v]=(0,e.useState)([]),[b,y]=(0,e.useState)(),[x,w]=(0,e.useState)(),[_,T]=(0,e.useState)(),[E,k]=(0,e.useState)(),[S,C]=(0,e.useState)(),[A,M]=(0,e.useState)(),[P,O]=(0,e.useState)(),[R,D]=(0,e.useState)(),[L,I]=(0,e.useState)(),[N,F]=(0,e.useState)(),[z,B]=(0,e.useState)(),[j,V]=(0,e.useState)(),[U,H]=(0,e.useState)(),[W,$]=(0,e.useState)(),[G,K]=(0,e.useState)();(0,e.useEffect)((()=>{try{(()=>{try{void 0===n||(c(n.data.map(((e,t)=>({id:t,lat:parseFloat(e.Latitude),lng:parseFloat(e.Longitude),alt:parseFloat(e.Altitude)})))),console.log(l))}catch(e){console.error("Error occurred while extracting markers:",e)}})(),q(),Z(),X()}catch(e){console.error("Error occurred while calculating stats:",e)}}),[n.data,r,i,a,s,l.length,u.length,E,S,A]);const Y=(e,t,n,r)=>{try{const i=6371e3,a=e=>e*(Math.PI/180),s=a(n-e),o=a(r-t),l=Math.sin(s/2)**2+Math.cos(a(e))*Math.cos(a(n))*Math.sin(o/2)**2,c=2*Math.atan2(Math.sqrt(l),Math.sqrt(1-l));return(i*c).toFixed(2)}catch(i){return console.error("Error occurred while calculating distance:",i),""}},X=()=>{if(l.length>1){const e=l.reduce(((e,t)=>e+t.lat),0),t=l.reduce(((e,t)=>e+t.lng),0),n=l.reduce(((e,t)=>e+t.alt),0);y(e/l.length),w(t/l.length),T(n/l.length)}},q=()=>{try{if(l.length>1){const e=l.map((e=>{const{lat:t,lng:n}=e;return parseFloat(Y(r,i,t,n))}));h(e),o(e);const t=u.sort(((e,t)=>e-t)),n=Math.floor(.5*t.length),a=Math.floor(.9*t.length),s=Math.floor(.98*t.length);k(t[n]),C(t[a]),M(t[s]);const c=l.map((e=>{const{lat:t,lng:n}=e;return parseFloat(Y(b,x,t,n))}));m(c);const f=p.sort(((e,t)=>e-t)),d=Math.floor(.5*f.length),g=Math.floor(.9*f.length),v=Math.floor(.98*f.length);O(f[d]),D(f[g]),I(f[v])}}catch(e){console.error("Error occurred while calculating stats:",e)}},Z=()=>{try{if(l.length>1&&l[0].alt){const e=l.map((e=>{const{lat:t,lng:n,alt:s}=e,o=parseFloat(((e,t,n,r,i,a)=>{const s=(r-e)*(Math.PI/180),o=(i-t)*(Math.PI/180),l=a-n,c=Math.sin(s/2)*Math.sin(s/2)+Math.cos(e*(Math.PI/180))*Math.cos(r*(Math.PI/180))*Math.sin(o/2)*Math.sin(o/2),u=2*Math.atan2(Math.sqrt(c),Math.sqrt(1-c));return Math.sqrt(Math.pow(6371e3*u,2)+Math.pow(l,2))})(r,i,a,t,n,s).toFixed(2));return o}));d(e);const t=f.sort(((e,t)=>e-t)),n=Math.floor(.5*t.length),s=Math.floor(.9*t.length),o=Math.floor(.98*t.length);F(t[n]),B(t[s]),V(t[o]);const c=l.map((e=>{const{lat:t,lng:n}=e;return parseFloat(Y(b,x,t,n))}));v(c);const u=g.sort(((e,t)=>e-t)),h=Math.floor(.5*u.length),p=Math.floor(.9*u.length),m=Math.floor(.98*u.length);H(u[h]),$(u[p]),K(u[m])}}catch(e){}};return(()=>{try{if(l.length>1)return(0,Ne.jsxs)("table",{className:"divide-y divide-gray-200",children:[(0,Ne.jsx)("thead",{className:"bg-gray-200",children:(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Statistics"}),(0,Ne.jsx)("th",{scope:"col",className:"px-6 py-3 text-left text-sm text-gray-600 uppercase tracking-wider",children:"Value"})]})}),(0,Ne.jsxs)("tbody",{className:"bg-white text-xs divide-y divide-gray-200",children:[(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Number of fixes"}),(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:u.length})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Max Fix Error"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[Math.max(...u)," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Min Fix Error"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[Math.min(...u)," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Average Fix Error"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[(u.reduce(((e,t)=>e+t),0)/u.length).toFixed(2)," ","m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"CEP 50%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[E," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"CEP 90%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[S," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"CEP 98%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[A," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean CEP 50%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[P," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean CEP 90%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[R," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean CEP 98%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[L," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"SEP 50%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[N," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"SEP 90%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[z," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"SEP 98%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[j," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean SEP 50%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[U," m"]})]}),(0,Ne.jsxs)("tr",{className:"bg-gray-50",children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean SEP 90%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[W," m"]})]}),(0,Ne.jsxs)("tr",{children:[(0,Ne.jsx)("td",{className:"px-6 py-4 whitespace-nowrap",children:"Mean SEP 98%"}),(0,Ne.jsxs)("td",{className:"px-6 py-4 whitespace-nowrap",children:[G," m"]})]})]})]})}catch(e){return console.error("Error occurred while rendering stats:",e),null}})()};function vf(e){return vf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},vf(e)}function bf(e){var t=function(e,t){if("object"!=vf(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=vf(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==vf(t)?t:t+""}function yf(e,t,n){return(t=bf(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xf(e){return e+.5|0}const wf=(e,t,n)=>Math.max(Math.min(e,n),t);function _f(e){return wf(xf(2.55*e),0,255)}function Tf(e){return wf(xf(255*e),0,255)}function Ef(e){return wf(xf(e/2.55)/100,0,1)}function kf(e){return wf(xf(100*e),0,100)}const Sf={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},Cf=[..."0123456789ABCDEF"],Af=e=>Cf[15&e],Mf=e=>Cf[(240&e)>>4]+Cf[15&e],Pf=e=>(240&e)>>4===(15&e);function Of(e){var t=(e=>Pf(e.r)&&Pf(e.g)&&Pf(e.b)&&Pf(e.a))(e)?Af:Mf;return e?"#"+t(e.r)+t(e.g)+t(e.b)+((e,t)=>e<255?t(e):"")(e.a,t):void 0}const Rf=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function Df(e,t,n){const r=t*Math.min(n,1-n),i=function(t){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(t+e/30)%12;return n-r*Math.max(Math.min(i-3,9-i,1),-1)};return[i(0),i(8),i(4)]}function Lf(e,t,n){const r=function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(r+e/60)%6;return n-n*t*Math.max(Math.min(i,4-i,1),0)};return[r(5),r(3),r(1)]}function If(e,t,n){const r=Df(e,1,.5);let i;for(t+n>1&&(i=1/(t+n),t*=i,n*=i),i=0;i<3;i++)r[i]*=1-t-n,r[i]+=t;return r}function Nf(e){const t=e.r/255,n=e.g/255,r=e.b/255,i=Math.max(t,n,r),a=Math.min(t,n,r),s=(i+a)/2;let o,l,c;return i!==a&&(c=i-a,l=s>.5?c/(2-i-a):c/(i+a),o=function(e,t,n,r,i){return e===i?(t-n)/r+(t>16&255,a>>8&255,255&a]}return e}(),Hf.transparent=[0,0,0,0]);const t=Hf[e.toLowerCase()];return t&&{r:t[0],g:t[1],b:t[2],a:4===t.length?t[3]:255}}const $f=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;const Gf=e=>e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055,Kf=e=>e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4);function Yf(e,t,n){if(e){let r=Nf(e);r[t]=Math.max(0,Math.min(r[t]+r[t]*n,0===t?360:1)),r=zf(r),e.r=r[0],e.g=r[1],e.b=r[2]}}function Xf(e,t){return e?Object.assign(t||{},e):e}function qf(e){var t={r:0,g:0,b:0,a:255};return Array.isArray(e)?e.length>=3&&(t={r:e[0],g:e[1],b:e[2],a:255},e.length>3&&(t.a=Tf(e[3]))):(t=Xf(e,{r:0,g:0,b:0,a:1})).a=Tf(t.a),t}function Zf(e){return"r"===e.charAt(0)?function(e){const t=$f.exec(e);let n,r,i,a=255;if(t){if(t[7]!==n){const e=+t[7];a=t[8]?_f(e):wf(255*e,0,255)}return n=+t[1],r=+t[3],i=+t[5],n=255&(t[2]?_f(n):wf(n,0,255)),r=255&(t[4]?_f(r):wf(r,0,255)),i=255&(t[6]?_f(i):wf(i,0,255)),{r:n,g:r,b:i,a:a}}}(e):jf(e)}class Qf{constructor(e){if(e instanceof Qf)return e;const t=typeof e;let n;"object"===t?n=qf(e):"string"===t&&(n=function(e){var t,n=e.length;return"#"===e[0]&&(4===n||5===n?t={r:255&17*Sf[e[1]],g:255&17*Sf[e[2]],b:255&17*Sf[e[3]],a:5===n?17*Sf[e[4]]:255}:7!==n&&9!==n||(t={r:Sf[e[1]]<<4|Sf[e[2]],g:Sf[e[3]]<<4|Sf[e[4]],b:Sf[e[5]]<<4|Sf[e[6]],a:9===n?Sf[e[7]]<<4|Sf[e[8]]:255})),t}(e)||Wf(e)||Zf(e)),this._rgb=n,this._valid=!!n}get valid(){return this._valid}get rgb(){var e=Xf(this._rgb);return e&&(e.a=Ef(e.a)),e}set rgb(e){this._rgb=qf(e)}rgbString(){return this._valid?function(e){return e&&(e.a<255?"rgba(".concat(e.r,", ").concat(e.g,", ").concat(e.b,", ").concat(Ef(e.a),")"):"rgb(".concat(e.r,", ").concat(e.g,", ").concat(e.b,")"))}(this._rgb):void 0}hexString(){return this._valid?Of(this._rgb):void 0}hslString(){return this._valid?function(e){if(!e)return;const t=Nf(e),n=t[0],r=kf(t[1]),i=kf(t[2]);return e.a<255?"hsla(".concat(n,", ").concat(r,"%, ").concat(i,"%, ").concat(Ef(e.a),")"):"hsl(".concat(n,", ").concat(r,"%, ").concat(i,"%)")}(this._rgb):void 0}mix(e,t){if(e){const n=this.rgb,r=e.rgb;let i;const a=t===i?.5:t,s=2*a-1,o=n.a-r.a,l=((s*o===-1?s:(s+o)/(1+s*o))+1)/2;i=1-l,n.r=255&l*n.r+i*r.r+.5,n.g=255&l*n.g+i*r.g+.5,n.b=255&l*n.b+i*r.b+.5,n.a=a*n.a+(1-a)*r.a,this.rgb=n}return this}interpolate(e,t){return e&&(this._rgb=function(e,t,n){const r=Kf(Ef(e.r)),i=Kf(Ef(e.g)),a=Kf(Ef(e.b));return{r:Tf(Gf(r+n*(Kf(Ef(t.r))-r))),g:Tf(Gf(i+n*(Kf(Ef(t.g))-i))),b:Tf(Gf(a+n*(Kf(Ef(t.b))-a))),a:e.a+n*(t.a-e.a)}}(this._rgb,e._rgb,t)),this}clone(){return new Qf(this.rgb)}alpha(e){return this._rgb.a=Tf(e),this}clearer(e){return this._rgb.a*=1-e,this}greyscale(){const e=this._rgb,t=xf(.3*e.r+.59*e.g+.11*e.b);return e.r=e.g=e.b=t,this}opaquer(e){return this._rgb.a*=1+e,this}negate(){const e=this._rgb;return e.r=255-e.r,e.g=255-e.g,e.b=255-e.b,this}lighten(e){return Yf(this._rgb,2,e),this}darken(e){return Yf(this._rgb,2,-e),this}saturate(e){return Yf(this._rgb,1,e),this}desaturate(e){return Yf(this._rgb,1,-e),this}rotate(e){return function(e,t){var n=Nf(e);n[0]=Bf(n[0]+t),n=zf(n),e.r=n[0],e.g=n[1],e.b=n[2]}(this._rgb,e),this}}function Jf(){}const ed=(()=>{let e=0;return()=>e++})();function td(e){return null===e||"undefined"===typeof e}function nd(e){if(Array.isArray&&Array.isArray(e))return!0;const t=Object.prototype.toString.call(e);return"[object"===t.slice(0,7)&&"Array]"===t.slice(-6)}function rd(e){return null!==e&&"[object Object]"===Object.prototype.toString.call(e)}function id(e){return("number"===typeof e||e instanceof Number)&&isFinite(+e)}function ad(e,t){return id(e)?e:t}function sd(e,t){return"undefined"===typeof e?t:e}const od=(e,t)=>"string"===typeof e&&e.endsWith("%")?parseFloat(e)/100*t:+e;function ld(e,t,n){if(e&&"function"===typeof e.call)return e.apply(n,t)}function cd(e,t,n,r){let i,a,s;if(nd(e))if(a=e.length,r)for(i=a-1;i>=0;i--)t.call(n,e[i],i);else for(i=0;ie,x:e=>e.x,y:e=>e.y};function bd(e,t){const n=vd[t]||(vd[t]=function(e){const t=function(e){const t=e.split("."),n=[];let r="";for(const i of t)r+=i,r.endsWith("\\")?r=r.slice(0,-1)+".":(n.push(r),r="");return n}(e);return e=>{for(const n of t){if(""===n)break;e=e&&e[n]}return e}}(t));return n(e)}function yd(e){return e.charAt(0).toUpperCase()+e.slice(1)}const xd=e=>"undefined"!==typeof e,wd=e=>"function"===typeof e,_d=(e,t)=>{if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0};const Td=Math.PI,Ed=2*Td,kd=Ed+Td,Sd=Number.POSITIVE_INFINITY,Cd=Td/180,Ad=Td/2,Md=Td/4,Pd=2*Td/3,Od=Math.log10,Rd=Math.sign;function Dd(e,t,n){return Math.abs(e-t)l&&c3&&void 0!==arguments[3]?arguments[3]:1e-6;return e>=Math.min(t,n)-r&&e<=Math.max(t,n)+r}function Kd(e,t,n){n=n||(n=>e[n]1;)r=a+i>>1,n(r)?a=r:i=r;return{lo:a,hi:i}}const Yd=(e,t,n,r)=>Kd(e,n,r?r=>{const i=e[r][t];return ie[r][t]Kd(e,n,(r=>e[r][t]>=n));const qd=["push","pop","shift","splice","unshift"];function Zd(e,t){const n=e._chartjs;if(!n)return;const r=n.listeners,i=r.indexOf(t);-1!==i&&r.splice(i,1),r.length>0||(qd.forEach((t=>{delete e[t]})),delete e._chartjs)}function Qd(e){const t=new Set(e);return t.size===e.length?e:Array.from(t)}const Jd="undefined"===typeof window?function(e){return e()}:window.requestAnimationFrame;function ep(e,t){let n=[],r=!1;return function(){for(var i=arguments.length,a=new Array(i),s=0;s{r=!1,e.apply(t,n)})))}}const tp=e=>"start"===e?"left":"end"===e?"right":"center",np=(e,t,n)=>"start"===e?t:"end"===e?n:(t+n)/2;function rp(e,t,n){const r=t.length;let i=0,a=r;if(e._sorted){const{iScale:s,_parsed:o}=e,l=s.axis,{min:c,max:u,minDefined:h,maxDefined:f}=s.getUserBounds();h&&(i=$d(Math.min(Yd(o,l,c).lo,n?r:Yd(t,l,s.getPixelForValue(c)).lo),0,r-1)),a=f?$d(Math.max(Yd(o,s.axis,u,!0).hi+1,n?0:Yd(t,l,s.getPixelForValue(u),!0).hi+1),i,r)-i:r-i}return{start:i,count:a}}function ip(e){const{xScale:t,yScale:n,_scaleRanges:r}=e,i={xmin:t.min,xmax:t.max,ymin:n.min,ymax:n.max};if(!r)return e._scaleRanges=i,!0;const a=r.xmin!==t.min||r.xmax!==t.max||r.ymin!==n.min||r.ymax!==n.max;return Object.assign(r,i),a}const ap=e=>0===e||1===e,sp=(e,t,n)=>-Math.pow(2,10*(e-=1))*Math.sin((e-t)*Ed/n),op=(e,t,n)=>Math.pow(2,-10*e)*Math.sin((e-t)*Ed/n)+1,lp={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>-e*(e-2),easeInOutQuad:e=>(e/=.5)<1?.5*e*e:-.5*(--e*(e-2)-1),easeInCubic:e=>e*e*e,easeOutCubic:e=>(e-=1)*e*e+1,easeInOutCubic:e=>(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2),easeInQuart:e=>e*e*e*e,easeOutQuart:e=>-((e-=1)*e*e*e-1),easeInOutQuart:e=>(e/=.5)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2),easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>(e-=1)*e*e*e*e+1,easeInOutQuint:e=>(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2),easeInSine:e=>1-Math.cos(e*Ad),easeOutSine:e=>Math.sin(e*Ad),easeInOutSine:e=>-.5*(Math.cos(Td*e)-1),easeInExpo:e=>0===e?0:Math.pow(2,10*(e-1)),easeOutExpo:e=>1===e?1:1-Math.pow(2,-10*e),easeInOutExpo:e=>ap(e)?e:e<.5?.5*Math.pow(2,10*(2*e-1)):.5*(2-Math.pow(2,-10*(2*e-1))),easeInCirc:e=>e>=1?e:-(Math.sqrt(1-e*e)-1),easeOutCirc:e=>Math.sqrt(1-(e-=1)*e),easeInOutCirc:e=>(e/=.5)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1),easeInElastic:e=>ap(e)?e:sp(e,.075,.3),easeOutElastic:e=>ap(e)?e:op(e,.075,.3),easeInOutElastic(e){const t=.1125;return ap(e)?e:e<.5?.5*sp(2*e,t,.45):.5+.5*op(2*e-1,t,.45)},easeInBack(e){const t=1.70158;return e*e*((t+1)*e-t)},easeOutBack(e){const t=1.70158;return(e-=1)*e*((t+1)*e+t)+1},easeInOutBack(e){let t=1.70158;return(e/=.5)<1?e*e*((1+(t*=1.525))*e-t)*.5:.5*((e-=2)*e*((1+(t*=1.525))*e+t)+2)},easeInBounce:e=>1-lp.easeOutBounce(1-e),easeOutBounce(e){const t=7.5625,n=2.75;return e<1/n?t*e*e:e<2/n?t*(e-=1.5/n)*e+.75:e<2.5/n?t*(e-=2.25/n)*e+.9375:t*(e-=2.625/n)*e+.984375},easeInOutBounce:e=>e<.5?.5*lp.easeInBounce(2*e):.5*lp.easeOutBounce(2*e-1)+.5};function cp(e){if(e&&"object"===typeof e){const t=e.toString();return"[object CanvasPattern]"===t||"[object CanvasGradient]"===t}return!1}function up(e){return cp(e)?e:new Qf(e)}function hp(e){return cp(e)?e:new Qf(e).saturate(.5).darken(.1).hexString()}const fp=["x","y","borderWidth","radius","tension"],dp=["color","borderColor","backgroundColor"];const pp=new Map;function mp(e,t,n){return function(e,t){t=t||{};const n=e+JSON.stringify(t);let r=pp.get(n);return r||(r=new Intl.NumberFormat(e,t),pp.set(n,r)),r}(t,n).format(e)}const gp={values:e=>nd(e)?e:""+e,numeric(e,t,n){if(0===e)return"0";const r=this.chart.options.locale;let i,a=e;if(n.length>1){const t=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(t<1e-4||t>1e15)&&(i="scientific"),a=function(e,t){let n=t.length>3?t[2].value-t[1].value:t[1].value-t[0].value;Math.abs(n)>=1&&e!==Math.floor(e)&&(n=e-Math.floor(e));return n}(e,n)}const s=Od(Math.abs(a)),o=isNaN(s)?1:Math.max(Math.min(-1*Math.floor(s),20),0),l={notation:i,minimumFractionDigits:o,maximumFractionDigits:o};return Object.assign(l,this.options.ticks.format),mp(e,r,l)},logarithmic(e,t,n){if(0===e)return"0";const r=n[t].significand||e/Math.pow(10,Math.floor(Od(e)));return[1,2,3,5,10,15].includes(r)||t>.8*n.length?gp.numeric.call(this,e,t,n):""}};var vp={formatters:gp};const bp=Object.create(null),yp=Object.create(null);function xp(e,t){if(!t)return e;const n=t.split(".");for(let r=0,i=n.length;r