sheetjs/dist/xlsx.mini.min.js

11 lines
262 KiB
JavaScript
Raw Normal View History

/*! xlsx.js (C) 2013-present SheetJS -- http://sheetjs.com */
2022-11-17 09:35:34 +00:00
var XLSX={};function make_xlsx_lib(e){e.version="0.19.1";var r=1200,t=1252;var a;var n=[874,932,936,949,950,1250,1251,1252,1253,1254,1255,1256,1257,1258,1e4];var s={0:1252,1:65001,2:65001,77:1e4,128:932,129:949,130:1361,134:936,136:950,161:1253,162:1254,163:1258,177:1255,178:1256,186:1257,204:1251,222:874,238:1250,255:1252,69:6969};var i=function(e){if(n.indexOf(e)==-1)return;t=s[0]=e};function l(){i(1252)}var o=function(e){r=e;i(e)};function c(){o(1200);l()}function f(e){var r=[];for(var t=0,a=e.length;t<a;++t)r[t]=e.charCodeAt(t);return r}function u(e){var r=[];for(var t=0;t<e.length>>1;++t)r[t]=String.fromCharCode(e.charCodeAt(2*t)+(e.charCodeAt(2*t+1)<<8));return r.join("")}function h(e){var r=[];for(var t=0;t<e.length>>1;++t)r[t]=String.fromCharCode(e.charCodeAt(2*t+1)+(e.charCodeAt(2*t)<<8));return r.join("")}var d=function(e){var r=e.charCodeAt(0),t=e.charCodeAt(1);if(r==255&&t==254)return u(e.slice(2));if(r==254&&t==255)return h(e.slice(2));if(r==65279)return e.slice(1);return e};var m=function _c(e){return String.fromCharCode(e)};var p=function Ac(e){return String.fromCharCode(e)};function v(e){a=e;o=function(e){r=e;i(e)};d=function(e){if(e.charCodeAt(0)===255&&e.charCodeAt(1)===254){return a.utils.decode(1200,f(e.slice(2)))}return e};m=function n(e){if(r===1200)return String.fromCharCode(e);return a.utils.decode(r,[e&255,e>>8])[0]};p=function s(e){return a.utils.decode(t,[e])[0]};na()}var g=null;var b=true;var w="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function k(e){var r="";var t=0,a=0,n=0,s=0,i=0,l=0,o=0;for(var c=0;c<e.length;){t=e.charCodeAt(c++);s=t>>2;a=e.charCodeAt(c++);i=(t&3)<<4|a>>4;n=e.charCodeAt(c++);l=(a&15)<<2|n>>6;o=n&63;if(isNaN(a)){l=o=64}else if(isNaN(n)){o=64}r+=w.charAt(s)+w.charAt(i)+w.charAt(l)+w.charAt(o)}return r}function y(e){var r="";var t=0,a=0,n=0,s=0,i=0,l=0,o=0;for(var c=0;c<e.length;){t=e.charCodeAt(c++);if(t>255)t=95;s=t>>2;a=e.charCodeAt(c++);if(a>255)a=95;i=(t&3)<<4|a>>4;n=e.charCodeAt(c++);if(n>255)n=95;l=(a&15)<<2|n>>6;o=n&63;if(isNaN(a)){l=o=64}else if(isNaN(n)){o=64}r+=w.charAt(s)+w.charAt(i)+w.charAt(l)+w.charAt(o)}return r}function x(e){var r="";var t=0,a=0,n=0,s=0,i=0,l=0,o=0;e=e.replace(/^data:([^\/]+\/[^\/]+)?;base64\,/,"").replace(/[^\w\+\/\=]/g,"");for(var c=0;c<e.length;){s=w.indexOf(e.charAt(c++));i=w.indexOf(e.charAt(c++));t=s<<2|i>>4;r+=String.fromCharCode(t);l=w.indexOf(e.charAt(c++));a=(i&15)<<4|l>>2;if(l!==64){r+=String.fromCharCode(a)}o=w.indexOf(e.charAt(c++));n=(l&3)<<6|o;if(o!==64){r+=String.fromCharCode(n)}}return r}var S=function(){return typeof Buffer!=="undefined"&&typeof undefined!=="undefined"&&typeof{}!=="undefined"&&!!{}.node}();var C=function(){if(typeof Buffer!=="undefined"){var e=!Buffer.from;if(!e)try{Buffer.from("foo","utf8")}catch(r){e=true}return e?function(e,r){return r?new Buffer(e,r):new Buffer(e)}:Buffer.from.bind(Buffer)}return function(){}}();var _=function(){if(typeof Buffer==="undefined")return false;var e=C([65,0]);if(!e)return false;var r=e.toString("utf16le");return r.length==1}();function A(e){if(S)return Buffer.alloc?Buffer.alloc(e):new Buffer(e);return typeof Uint8Array!="undefined"?new Uint8Array(e):new Array(e)}function F(e){if(S)return Buffer.allocUnsafe?Buffer.allocUnsafe(e):new Buffer(e);return typeof Uint8Array!="undefined"?new Uint8Array(e):new Array(e)}var E=function Fc(e){if(S)return C(e,"binary");return e.split("").map(function(e){return e.charCodeAt(0)&255})};function T(e){if(typeof ArrayBuffer==="undefined")return E(e);var r=new ArrayBuffer(e.length),t=new Uint8Array(r);for(var a=0;a!=e.length;++a)t[a]=e.charCodeAt(a)&255;return r}function D(e){if(Array.isArray(e))return e.map(function(e){return String.fromCharCode(e)}).join("");var r=[];for(var t=0;t<e.length;++t)r[t]=String.fromCharCode(e[t]);return r.join("")}function O(e){if(typeof Uint8Array==="undefined")throw new Error("Unsupported");return new Uint8Array(e)}function M(e){if(typeof ArrayBuffer=="undefined")throw new Error("Unsupported");if(e instanceof ArrayBuffer)return M(new Uint8Array(e));var r=new Array(e.length);for(var t=0;t<
2022-10-24 01:05:59 +00:00
}var t=r();function a(e){var r=0,t=0,a=0,n=typeof Int32Array!=="undefined"?new Int32Array(4096):new Array(4096);for(a=0;a!=256;++a)n[a]=e[a];for(a=0;a!=256;++a){t=e[a];for(r=256+a;r<4096;r+=256)t=n[r]=t>>>8^e[t&255]}var s=[];for(a=1;a!=16;++a)s[a-1]=typeof Int32Array!=="undefined"?n.subarray(a*256,a*256+256):n.slice(a*256,a*256+256);return s}var n=a(t);var s=n[0],i=n[1],l=n[2],o=n[3],c=n[4];var f=n[5],u=n[6],h=n[7],d=n[8],m=n[9];var p=n[10],v=n[11],g=n[12],b=n[13],w=n[14];function k(e,r){var a=r^-1;for(var n=0,s=e.length;n<s;)a=a>>>8^t[(a^e.charCodeAt(n++))&255];return~a}function y(e,r){var a=r^-1,n=e.length-15,k=0;for(;k<n;)a=w[e[k++]^a&255]^b[e[k++]^a>>8&255]^g[e[k++]^a>>16&255]^v[e[k++]^a>>>24]^p[e[k++]]^m[e[k++]]^d[e[k++]]^h[e[k++]]^u[e[k++]]^f[e[k++]]^c[e[k++]]^o[e[k++]]^l[e[k++]]^i[e[k++]]^s[e[k++]]^t[e[k++]];n+=15;while(k<n)a=a>>>8^t[(a^e[k++])&255];return~a}function x(e,r){var a=r^-1;for(var n=0,s=e.length,i=0,l=0;n<s;){i=e.charCodeAt(n++);if(i<128){a=a>>>8^t[(a^i)&255]}else if(i<2048){a=a>>>8^t[(a^(192|i>>6&31))&255];a=a>>>8^t[(a^(128|i&63))&255]}else if(i>=55296&&i<57344){i=(i&1023)+64;l=e.charCodeAt(n++)&1023;a=a>>>8^t[(a^(240|i>>8&7))&255];a=a>>>8^t[(a^(128|i>>2&63))&255];a=a>>>8^t[(a^(128|l>>6&15|(i&3)<<4))&255];a=a>>>8^t[(a^(128|l&63))&255]}else{a=a>>>8^t[(a^(224|i>>12&15))&255];a=a>>>8^t[(a^(128|i>>6&63))&255];a=a>>>8^t[(a^(128|i&63))&255]}}return~a}e.table=t;e.bstr=k;e.buf=y;e.str=x;return e}();var er=function Tc(){var e={};e.version="1.2.2";function r(e,r){var t=e.split("/"),a=r.split("/");for(var n=0,s=0,i=Math.min(t.length,a.length);n<i;++n){if(s=t[n].length-a[n].length)return s;if(t[n]!=a[n])return t[n]<a[n]?-1:1}return t.length-a.length}function t(e){if(e.charAt(e.length-1)=="/")return e.slice(0,-1).indexOf("/")===-1?e:t(e.slice(0,-1));var r=e.lastIndexOf("/");return r===-1?e:e.slice(0,r+1)}function a(e){if(e.charAt(e.length-1)=="/")return a(e.slice(0,-1));var r=e.lastIndexOf("/");return r===-1?e:e.slice(r+1)}function n(e,r){if(typeof r==="string")r=new Date(r);var t=r.getHours();t=t<<6|r.getMinutes();t=t<<5|r.getSeconds()>>>1;e._W(2,t);var a=r.getFullYear()-1980;a=a<<4|r.getMonth()+1;a=a<<5|r.getDate();e._W(2,a)}function s(e){var r=e._R(2)&65535;var t=e._R(2)&65535;var a=new Date;var n=t&31;t>>>=5;var s=t&15;t>>>=4;a.setMilliseconds(0);a.setFullYear(t+1980);a.setMonth(s-1);a.setDate(n);var i=r&31;r>>>=5;var l=r&63;r>>>=6;a.setHours(r);a.setMinutes(l);a.setSeconds(i<<1);return a}function i(e){ga(e,0);var r={};var t=0;while(e.l<=e.length-4){var a=e._R(2);var n=e._R(2),s=e.l+n;var i={};switch(a){case 21589:{t=e._R(1);if(t&1)i.mtime=e._R(4);if(n>5){if(t&2)i.atime=e._R(4);if(t&4)i.ctime=e._R(4)}if(i.mtime)i.mt=new Date(i.mtime*1e3)}break;case 1:{var l=e._R(4),o=e._R(4);i.usz=o*Math.pow(2,32)+l;l=e._R(4);o=e._R(4);i.csz=o*Math.pow(2,32)+l}break;}e.l=s;r[a]=i}return r}var l;function o(){return l||(l=rr)}function c(e,r){if(e[0]==80&&e[1]==75)return Oe(e,r);if((e[0]|32)==109&&(e[1]|32)==105)return $e(e,r);if(e.length<512)throw new Error("CFB file size "+e.length+" < 512");var t=3;var a=512;var n=0;var s=0;var i=0;var l=0;var o=0;var c=[];var m=e.slice(0,512);ga(m,0);var v=f(m);t=v[0];switch(t){case 3:a=512;break;case 4:a=4096;break;case 0:if(v[1]==0)return Oe(e,r);default:throw new Error("Major Version: Expected 3 or 4 saw "+t);}if(a!==512){m=e.slice(0,a);ga(m,28)}var w=e.slice(0,a);u(m,t);var k=m._R(4,"i");if(t===3&&k!==0)throw new Error("# Directory Sectors: Expected 0 saw "+k);m.l+=4;i=m._R(4,"i");m.l+=4;m.chk("00100000","Mini Stream Cutoff Size: ");l=m._R(4,"i");n=m._R(4,"i");o=m._R(4,"i");s=m._R(4,"i");for(var y=-1,x=0;x<109;++x){y=m._R(4,"i");if(y<0)break;c[x]=y}var S=h(e,a);p(o,s,S,a,c);var C=g(S,i,c,a);if(i<C.length)C[i].name="!Directory";if(n>0&&l!==B)C[l].name="!MiniFAT";C[c[0]].name="!FAT";C.fat_addrs=c;C.ssz=a;var _={},A=[],F=[],E=[];b(i,C,S,A,n,_,F,l);d(F,E,A);A.shift();var T={FileIndex:F,FullPaths:E};if(r&&r.raw)T.raw={header:w,sectors:S};return T}function f(e){if(e[e.l]==80&&e[e.l+1]==75)return[0,0];e.chk(z,"Header Signature: ");e.l+=16;var r=e._R(2,"u");return[e._R(2,"u"),r]}function u(e,r){
var r=new Date;r.setTime(e*24*60*60*1e3+mr);if(r.getTimezoneOffset()!==pr){r.setTime(r.getTime()+(r.getTimezoneOffset()-pr)*6e4)}return r}function gr(e){var r=0,t=0,a=false;var n=e.match(/P([0-9\.]+Y)?([0-9\.]+M)?([0-9\.]+D)?T([0-9\.]+H)?([0-9\.]+M)?([0-9\.]+S)?/);if(!n)throw new Error("|"+e+"| is not an ISO8601 Duration");for(var s=1;s!=n.length;++s){if(!n[s])continue;t=1;if(s>3)a=true;switch(n[s].slice(n[s].length-1)){case"Y":throw new Error("Unsupported ISO Duration Field: "+n[s].slice(n[s].length-1));case"D":t*=24;case"H":t*=60;case"M":if(!a)throw new Error("Unsupported ISO Duration Field: M");else t*=60;case"S":break;}r+=t*parseInt(n[s],10)}return r}var br=new Date("2017-02-19T19:06:09.000Z");var wr=isNaN(br.getFullYear())?new Date("2/19/17"):br;var kr=wr.getFullYear()==2017;function yr(e,r){var t=new Date(e);if(kr){if(r>0)t.setTime(t.getTime()+t.getTimezoneOffset()*60*1e3);else if(r<0)t.setTime(t.getTime()-t.getTimezoneOffset()*60*1e3);return t}if(e instanceof Date)return e;if(wr.getFullYear()==1917&&!isNaN(t.getFullYear())){var a=t.getFullYear();if(e.indexOf(""+a)>-1)return t;t.setFullYear(t.getFullYear()+100);return t}var n=e.match(/\d+/g)||["2017","2","19","0","0","0"];var s=new Date(+n[0],+n[1]-1,+n[2],+n[3]||0,+n[4]||0,+n[5]||0);if(e.indexOf("Z")>-1)s=new Date(s.getTime()-s.getTimezoneOffset()*60*1e3);return s}function xr(e,r){if(S&&Buffer.isBuffer(e)){if(r&&_){if(e[0]==255&&e[1]==254)return gt(e.slice(2).toString("utf16le"));if(e[1]==254&&e[2]==255)return gt(h(e.slice(2).toString("binary")))}return e.toString("binary")}if(typeof TextDecoder!=="undefined")try{if(r){if(e[0]==255&&e[1]==254)return gt(new TextDecoder("utf-16le").decode(e.slice(2)));if(e[0]==254&&e[1]==255)return gt(new TextDecoder("utf-16be").decode(e.slice(2)))}var t={"€":"€","":"‚","ƒ":"ƒ","„":"„","…":"…","†":"†","‡":"‡","ˆ":"ˆ","‰":"‰","Š":"Š","":"‹","Œ":"Œ","Ž":"Ž","":"‘","":"’","“":"“","”":"”","•":"•","":"–","—":"—","˜":"˜","™":"™","š":"š","":"›","œ":"œ","ž":"ž","Ÿ":"Ÿ"};if(Array.isArray(e))e=new Uint8Array(e);return new TextDecoder("latin1").decode(e).replace(/[€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ]/g,function(e){return t[e]||e})}catch(a){}var n=[];for(var s=0;s!=e.length;++s)n.push(String.fromCharCode(e[s]));return n.join("")}function Sr(e){if(typeof JSON!="undefined"&&!Array.isArray(e))return JSON.parse(JSON.stringify(e));if(typeof e!="object"||e==null)return e;if(e instanceof Date)return new Date(e.getTime());var r={};for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))r[t]=Sr(e[t]);return r}function Cr(e,r){var t="";while(t.length<r)t+=e;return t}function _r(e){var r=Number(e);if(!isNaN(r))return isFinite(r)?r:NaN;if(!/\d/.test(e))return r;var t=1;var a=e.replace(/([\d]),([\d])/g,"$1$2").replace(/[$]/g,"").replace(/[%]/g,function(){t*=100;return""});if(!isNaN(r=Number(a)))return r/t;a=a.replace(/[(](.*)[)]/,function(e,r){t=-t;return r});if(!isNaN(r=Number(a)))return r/t;return r}var Ar=/^(0?\d|1[0-2])(?:|:([0-5]?\d)(?:|(\.\d+)(?:|:([0-5]?\d))|:([0-5]?\d)(|\.\d+)))\s+([ap])m?$/;function Fr(e){if(!e[2])return new Date(1899,11,30,+e[1]%12+(e[7]=="p"?12:0),0,0,0);if(e[3]){if(e[4])return new Date(1899,11,30,+e[1]%12+(e[7]=="p"?12:0),+e[2],+e[4],parseFloat(e[3])*1e3);else return new Date(1899,11,30,e[7]=="p"?12:0,+e[1],+e[2],parseFloat(e[3])*1e3)}else if(e[5])return new Date(1899,11,30,+e[1]%12+(e[7]=="p"?12:0),+e[2],+e[5],e[6]?parseFloat(e[6])*1e3:0);else return new Date(1899,11,30,+e[1]%12+(e[7]=="p"?12:0),+e[2],0,0)}var Er=["january","february","march","april","may","june","july","august","september","october","november","december"];function Tr(e){var r=e.toLowerCase();var t=r.replace(/\s+/g," ").trim();var a=t.match(Ar);if(a)return Fr(a);var n=new Date(e),s=new Date(NaN);var i=n.getYear(),l=n.getMonth(),o=n.getDate();if(isNaN(o))return s;if(r.match(/jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec/)){r=r.replace(/[^a-z]/g,"").replace(/([^a-z]|^)[ap]m?([^a-z]|$)/,"");if(r.length>3&&Er.indexOf(r)==-1)return s}else if(r.repl
"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/
g.forEach(function(e){Es(e)});if(s&&s.sheetRows)h=h.slice(0,s.sheetRows);return[h,p,y]}function l(e,r){var t=s(e,r);var a=t[0],n=t[1],i=t[2];var l=Sr(r);l.date1904=(((i||{}).Workbook||{}).WBProps||{}).date1904;var o=Ga(a,l);ir(n).forEach(function(e){o[e]=n[e]});var c=Va(o,r);ir(i).forEach(function(e){c[e]=i[e]});c.bookType="sylk";return c}function c(e,r,t,a){var n="C;Y"+(t+1)+";X"+(a+1)+";K";switch(e.t){case"n":n+=e.v||0;if(e.f&&!e.F)n+=";E"+Ai(e.f,{r:t,c:a});break;case"b":n+=e.v?"TRUE":"FALSE";break;case"e":n+=e.w||e.v;break;case"d":n+='"'+(e.w||e.v)+'"';break;case"s":n+='"'+(e.v==null?"":String(e.v)).replace(/"/g,"").replace(/;/g,";;")+'"';break;}return n}function f(e,r){r.forEach(function(r,t){var a="F;W"+(t+1)+" "+(t+1)+" ";if(r.hidden)a+="0";else{if(typeof r.width=="number"&&!r.wpx)r.wpx=Ss(r.width);if(typeof r.wpx=="number"&&!r.wch)r.wch=Cs(r.wpx);if(typeof r.wch=="number")a+=Math.round(r.wch)}if(a.charAt(a.length-1)!=" ")e.push(a)})}function u(e,r){r.forEach(function(r,t){var a="F;";if(r.hidden)a+="M0;";else if(r.hpt)a+="M"+20*r.hpt+";";else if(r.hpx)a+="M"+20*Os(r.hpx)+";";if(a.length>2)e.push(a+"R"+(t+1))})}function h(e,r,t){var a=["ID;PSheetJS;N;E"],n=[];var s=Ua(e["!ref"]),i;var l=e["!data"]!=null;var o="\r\n";var h=(((t||{}).Workbook||{}).WBProps||{}).date1904;a.push("P;PGeneral");a.push("F;P0;DG0G8;M255");if(e["!cols"])f(a,e["!cols"]);if(e["!rows"])u(a,e["!rows"]);a.push("B;Y"+(s.e.r-s.s.r+1)+";X"+(s.e.c-s.s.c+1)+";D"+[s.s.c,s.s.r,s.e.c,s.e.r].join(" "));a.push("O;L;D;B"+(h?";V4":"")+";K47;G100 0.001");for(var d=s.s.r;d<=s.e.r;++d){if(l&&!e["!data"][d])continue;var m=[];for(var p=s.s.c;p<=s.e.c;++p){i=l?e["!data"][d][p]:e[Ma(p)+Ea(d)];if(!i||i.v==null&&(!i.f||i.F))continue;m.push(c(i,e,d,p,r))}n.push(m.join(o))}return a.join(o)+o+n.join(o)+o+"E"+o}return{to_workbook:l,from_sheet:h}}();var Zn=function(){function e(e,t){switch(t.type){case"base64":return r(x(e),t);case"binary":return r(e,t);case"buffer":return r(S&&Buffer.isBuffer(e)?e.toString("binary"):D(e),t);case"array":return r(xr(e),t);}throw new Error("Unrecognized type "+t.type)}function r(e,r){var t=e.split("\n"),a=-1,n=-1,s=0,i=[];for(;s!==t.length;++s){if(t[s].trim()==="BOT"){i[++a]=[];n=0;continue}if(a<0)continue;var l=t[s].trim().split(",");var o=l[0],c=l[1];++s;var f=t[s]||"";while((f.match(/["]/g)||[]).length&1&&s<t.length-1)f+="\n"+t[++s];f=f.trim();switch(+o){case-1:if(f==="BOT"){i[++a]=[];n=0;continue}else if(f!=="EOD")throw new Error("Unrecognized DIF special command "+f);break;case 0:if(f==="TRUE")i[a][n]=true;else if(f==="FALSE")i[a][n]=false;else if(!isNaN(_r(c)))i[a][n]=_r(c);else if(!isNaN(Tr(c).getDate()))i[a][n]=yr(c);else i[a][n]=c;++n;break;case 1:f=f.slice(1,f.length-1);f=f.replace(/""/g,'"');if(b&&f&&f.match(/^=".*"$/))f=f.slice(2,-1);i[a][n++]=f!==""?f:null;break;}if(f==="EOD")break}if(r&&r.sheetRows)i=i.slice(0,r.sheetRows);return i}function t(r,t){return Ga(e(r,t),t)}function a(e,r){var a=Va(t(e,r),r);a.bookType="dif";return a}function n(e,r){return"0,"+String(e)+"\r\n"+r}function s(e){return'1,0\r\n"'+e.replace(/"/g,'""')+'"'}function i(e){var r=b;var t=Ua(e["!ref"]);var a=e["!data"]!=null;var i=['TABLE\r\n0,1\r\n"sheetjs"\r\n',"VECTORS\r\n0,"+(t.e.r-t.s.r+1)+'\r\n""\r\n',"TUPLES\r\n0,"+(t.e.c-t.s.c+1)+'\r\n""\r\n','DATA\r\n0,0\r\n""\r\n'];for(var l=t.s.r;l<=t.e.r;++l){var o=a?e["!data"][l]:[];var c="-1,0\r\nBOT\r\n";for(var f=t.s.c;f<=t.e.c;++f){var u=a?o&&o[f]:e[La({r:l,c:f})];if(u==null){c+='1,0\r\n""\r\n';continue}switch(u.t){case"n":if(r){if(u.w!=null)c+="0,"+u.w+"\r\nV";else if(u.v!=null)c+=n(u.v,"V");else if(u.f!=null&&!u.F)c+=s("="+u.f);else c+='1,0\r\n""'}else{if(u.v==null)c+='1,0\r\n""';else c+=n(u.v,"V")}break;case"b":c+=u.v?n(1,"TRUE"):n(0,"FALSE");break;case"s":c+=s(!r||isNaN(+u.v)?u.v:'="'+u.v+'"');break;case"d":if(!u.w)u.w=Ue(u.z||K[14],hr(yr(u.v)));if(r)c+=n(u.w,"V");else c+=s(u.w);break;default:c+='1,0\r\n""';}c+="\r\n"}i.push(c)}return i.join("")+"-1,0\r\nEOD"}return{to_workbook:a,to_sheet:t,from_sheet:i}}();var qn=function(){function e(e){return e.replace(/\\b/g,"\\").replace(/\\c/g,":").replace(/\\n/g,"\n"
2022-11-17 09:35:34 +00:00
t[t.length]='<a:font script="Sinh" typeface="Iskoola Pota"/>';t[t.length]='<a:font script="Mong" typeface="Mongolian Baiti"/>';t[t.length]='<a:font script="Viet" typeface="Arial"/>';t[t.length]='<a:font script="Uigh" typeface="Microsoft Uighur"/>';t[t.length]='<a:font script="Geor" typeface="Sylfaen"/>';t[t.length]="</a:minorFont>";t[t.length]="</a:fontScheme>";t[t.length]='<a:fmtScheme name="Office">';t[t.length]="<a:fillStyleLst>";t[t.length]='<a:solidFill><a:schemeClr val="phClr"/></a:solidFill>';t[t.length]='<a:gradFill rotWithShape="1">';t[t.length]="<a:gsLst>";t[t.length]='<a:gs pos="0"><a:schemeClr val="phClr"><a:tint val="50000"/><a:satMod val="300000"/></a:schemeClr></a:gs>';t[t.length]='<a:gs pos="35000"><a:schemeClr val="phClr"><a:tint val="37000"/><a:satMod val="300000"/></a:schemeClr></a:gs>';t[t.length]='<a:gs pos="100000"><a:schemeClr val="phClr"><a:tint val="15000"/><a:satMod val="350000"/></a:schemeClr></a:gs>';t[t.length]="</a:gsLst>";t[t.length]='<a:lin ang="16200000" scaled="1"/>';t[t.length]="</a:gradFill>";t[t.length]='<a:gradFill rotWithShape="1">';t[t.length]="<a:gsLst>";t[t.length]='<a:gs pos="0"><a:schemeClr val="phClr"><a:tint val="100000"/><a:shade val="100000"/><a:satMod val="130000"/></a:schemeClr></a:gs>';t[t.length]='<a:gs pos="100000"><a:schemeClr val="phClr"><a:tint val="50000"/><a:shade val="100000"/><a:satMod val="350000"/></a:schemeClr></a:gs>';t[t.length]="</a:gsLst>";t[t.length]='<a:lin ang="16200000" scaled="0"/>';t[t.length]="</a:gradFill>";t[t.length]="</a:fillStyleLst>";t[t.length]="<a:lnStyleLst>";t[t.length]='<a:ln w="9525" cap="flat" cmpd="sng" algn="ctr"><a:solidFill><a:schemeClr val="phClr"><a:shade val="95000"/><a:satMod val="105000"/></a:schemeClr></a:solidFill><a:prstDash val="solid"/></a:ln>';t[t.length]='<a:ln w="25400" cap="flat" cmpd="sng" algn="ctr"><a:solidFill><a:schemeClr val="phClr"/></a:solidFill><a:prstDash val="solid"/></a:ln>';t[t.length]='<a:ln w="38100" cap="flat" cmpd="sng" algn="ctr"><a:solidFill><a:schemeClr val="phClr"/></a:solidFill><a:prstDash val="solid"/></a:ln>';t[t.length]="</a:lnStyleLst>";t[t.length]="<a:effectStyleLst>";t[t.length]="<a:effectStyle>";t[t.length]="<a:effectLst>";t[t.length]='<a:outerShdw blurRad="40000" dist="20000" dir="5400000" rotWithShape="0"><a:srgbClr val="000000"><a:alpha val="38000"/></a:srgbClr></a:outerShdw>';t[t.length]="</a:effectLst>";t[t.length]="</a:effectStyle>";t[t.length]="<a:effectStyle>";t[t.length]="<a:effectLst>";t[t.length]='<a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"><a:srgbClr val="000000"><a:alpha val="35000"/></a:srgbClr></a:outerShdw>';t[t.length]="</a:effectLst>";t[t.length]="</a:effectStyle>";t[t.length]="<a:effectStyle>";t[t.length]="<a:effectLst>";t[t.length]='<a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"><a:srgbClr val="000000"><a:alpha val="35000"/></a:srgbClr></a:outerShdw>';t[t.length]="</a:effectLst>";t[t.length]='<a:scene3d><a:camera prst="orthographicFront"><a:rot lat="0" lon="0" rev="0"/></a:camera><a:lightRig rig="threePt" dir="t"><a:rot lat="0" lon="0" rev="1200000"/></a:lightRig></a:scene3d>';t[t.length]='<a:sp3d><a:bevelT w="63500" h="25400"/></a:sp3d>';t[t.length]="</a:effectStyle>";t[t.length]="</a:effectStyleLst>";t[t.length]="<a:bgFillStyleLst>";t[t.length]='<a:solidFill><a:schemeClr val="phClr"/></a:solidFill>';t[t.length]='<a:gradFill rotWithShape="1">';t[t.length]="<a:gsLst>";t[t.length]='<a:gs pos="0"><a:schemeClr val="phClr"><a:tint val="40000"/><a:satMod val="350000"/></a:schemeClr></a:gs>';t[t.length]='<a:gs pos="40000"><a:schemeClr val="phClr"><a:tint val="45000"/><a:shade val="99000"/><a:satMod val="350000"/></a:schemeClr></a:gs>';t[t.length]='<a:gs pos="100000"><a:schemeClr val="phClr"><a:shade val="20000"/><a:satMod val="255000"/></a:schemeClr></a:gs>';t[t.length]="</a:gsLst>";t[t.length]='<a:path path="circle"><a:fillToRect l="50000" t="-80000" r="50000" b="180000"/></a:path>';t[t.length]="</a:gradFill>";t[t.length]='<a:gradFill rotWithShape="1">';t[t.length]="<a:gsLst>";t[t.length]='<a:gs pos="0"><a:schemeClr val
var h=-1,d,m=-1;if(o["!links"].length>0){n[n.length]="<hyperlinks>";o["!links"].forEach(function(e){if(!e[1].Target)return;d={ref:e[0]};if(e[1].Target.charAt(0)!="#"){m=Fn(a,-1,nt(e[1].Target).replace(/#.*$/,""),Sn.HLINK);d["r:id"]="rId"+m}if((h=e[1].Target.indexOf("#"))>-1)d.location=nt(e[1].Target.slice(h+1));if(e[1].Tooltip)d.tooltip=nt(e[1].Tooltip);d.display=e[1].display;n[n.length]=Ft("hyperlink",null,d)});n[n.length]="</hyperlinks>"}delete o["!links"];if(o["!margins"]!=null)n[n.length]=ul(o["!margins"]);if(!r||r.ignoreEC||r.ignoreEC==void 0)n[n.length]=_t("ignoredErrors",Ft("ignoredError",null,{numberStoredAsText:1,sqref:c}));if(u.length>0){m=Fn(a,-1,"../drawings/drawing"+(e+1)+".xml",Sn.DRAW);n[n.length]=Ft("drawing",null,{"r:id":"rId"+m});o["!drawing"]=u}if(o["!comments"].length>0){m=Fn(a,-1,"../drawings/vmlDrawing"+(e+1)+".vml",Sn.VML);n[n.length]=Ft("legacyDrawing",null,{"r:id":"rId"+m});o["!legacy"]=m}if(n.length>1){n[n.length]="</worksheet>";n[1]=n[1].replace("/>",">")}return n.join("")}function Sl(e){var r=[];var t=e.match(/^<c:numCache>/);var a;(e.match(/<c:pt idx="(\d*)">(.*?)<\/c:pt>/gm)||[]).forEach(function(e){var a=e.match(/<c:pt idx="(\d*?)"><c:v>(.*)<\/c:v><\/c:pt>/);if(!a)return;r[+a[1]]=t?+a[2]:a[2]});var n=rt((e.match(/<c:formatCode>([\s\S]*?)<\/c:formatCode>/)||["","General"])[1]);(e.match(/<c:f>(.*?)<\/c:f>/gm)||[]).forEach(function(e){a=e.replace(/<.*?>/g,"")});return[r,n,a]}function Cl(e,r,t,a,n,s){var i=s||{"!type":"chart"};if(!e)return s;var l=0,o=0,c="A";var f={s:{r:2e6,c:2e6},e:{r:0,c:0}};(e.match(/<c:numCache>[\s\S]*?<\/c:numCache>/gm)||[]).forEach(function(e){var r=Sl(e);f.s.r=f.s.c=0;f.e.c=l;c=Ma(l);r[0].forEach(function(e,t){if(i["!data"]){if(!i["!data"][t])i["!data"][t]=[];i["!data"][t][l]={t:"n",v:e,z:r[1]}}else i[c+Ea(t)]={t:"n",v:e,z:r[1]};o=t});if(f.e.r<o)f.e.r=o;++l});if(l>0)i["!ref"]=za(f);return i}function _l(e,r,t,a,n){if(!e)return e;if(!a)a={"!id":{}};var s={"!type":"chart","!drawel":null,"!rel":""};var i;var l=e.match(qi);if(l)al(l[0],s,n,t);if(i=e.match(/drawing r:id="(.*?)"/))s["!rel"]=i[1];if(a["!id"][s["!rel"]])s["!drawel"]=a["!id"][s["!rel"]];return s}var Al=[["allowRefreshQuery",false,"bool"],["autoCompressPictures",true,"bool"],["backupFile",false,"bool"],["checkCompatibility",false,"bool"],["CodeName",""],["date1904",false,"bool"],["defaultThemeVersion",0,"int"],["filterPrivacy",false,"bool"],["hidePivotFieldList",false,"bool"],["promptedSolutions",false,"bool"],["publishItems",false,"bool"],["refreshAllConnections",false,"bool"],["saveExternalLinkValues",true,"bool"],["showBorderUnselectedTables",true,"bool"],["showInkAnnotation",true,"bool"],["showObjects","all"],["showPivotChartFilter",false,"bool"],["updateLinks","userSet"]];var Fl=[["activeTab",0,"int"],["autoFilterDateGrouping",true,"bool"],["firstSheet",0,"int"],["minimized",false,"bool"],["showHorizontalScroll",true,"bool"],["showSheetTabs",true,"bool"],["showVerticalScroll",true,"bool"],["tabRatio",600,"int"],["visibility","visible"]];var El=[];var Tl=[["calcCompleted","true"],["calcMode","auto"],["calcOnSave","true"],["concurrentCalc","true"],["fullCalcOnLoad","false"],["fullPrecision","true"],["iterate","false"],["iterateCount","100"],["iterateDelta","0.001"],["refMode","A1"]];function Dl(e,r){for(var t=0;t!=e.length;++t){var a=e[t];for(var n=0;n!=r.length;++n){var s=r[n];if(a[s[0]]==null)a[s[0]]=s[1];else switch(s[2]){case"bool":if(typeof a[s[0]]=="string")a[s[0]]=ut(a[s[0]]);break;case"int":if(typeof a[s[0]]=="string")a[s[0]]=parseInt(a[s[0]],10);break;}}}}function Ol(e,r){for(var t=0;t!=r.length;++t){var a=r[t];if(e[a[0]]==null)e[a[0]]=a[1];else switch(a[2]){case"bool":if(typeof e[a[0]]=="string")e[a[0]]=ut(e[a[0]]);break;case"int":if(typeof e[a[0]]=="string")e[a[0]]=parseInt(e[a[0]],10);break;}}}function Ml(e){Ol(e.WBProps,Al);Ol(e.CalcPr,Tl);Dl(e.WBView,Fl);Dl(e.Sheets,El);Ri.date1904=ut(e.WBProps.date1904)}function Nl(e){if(!e.Workbook)return"false";if(!e.Workbook.WBProps)return"false";return ut(e.Workbook.WBProps.date1904)?"true":"false"}var Pl=":][*?/\\".split("");function Il(e,r){if(e.length>31)
2022-10-24 01:05:59 +00:00
var r="<office:document-styles "+At({"xmlns:office":"urn:oasis:names:tc:opendocument:xmlns:office:1.0","xmlns:table":"urn:oasis:names:tc:opendocument:xmlns:table:1.0","xmlns:style":"urn:oasis:names:tc:opendocument:xmlns:style:1.0","xmlns:text":"urn:oasis:names:tc:opendocument:xmlns:text:1.0","xmlns:draw":"urn:oasis:names:tc:opendocument:xmlns:drawing:1.0","xmlns:fo":"urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0","xmlns:xlink":"http://www.w3.org/1999/xlink","xmlns:dc":"http://purl.org/dc/elements/1.1/","xmlns:number":"urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0","xmlns:svg":"urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0","xmlns:of":"urn:oasis:names:tc:opendocument:xmlns:of:1.2","office:version":"1.2"})+">"+e+"</office:document-styles>";return function t(){return Hr+r}}();function go(e,r){var t="number",a="",n={"style:name":r},s="",i=0;e=e.replace(/"[$]"/g,"$");e:{if(e.indexOf(";")>-1){console.error("Unsupported ODS Style Map exported. Using first branch of "+e);e=e.slice(0,e.indexOf(";"))}if(e=="@"){t="text";a="<number:text-content/>";break e}if(e.indexOf(/\$/)>-1){t="currency"}if(e[i]=='"'){s="";while(e[++i]!='"'||e[++i]=='"')s+=e[i];--i;if(e[i+1]=="*"){i++;a+="<number:fill-character>"+nt(s.replace(/""/g,'"'))+"</number:fill-character>"}else{a+="<number:text>"+nt(s.replace(/""/g,'"'))+"</number:text>"}e=e.slice(i+1);i=0}var l=e.match(/# (\?+)\/(\?+)/);if(l){a+=Ft("number:fraction",null,{"number:min-integer-digits":0,"number:min-numerator-digits":l[1].length,"number:max-denominator-value":Math.max(+l[1].replace(/./g,"9"),+l[2].replace(/./g,"9"))});break e}if(l=e.match(/# (\?+)\/(\d+)/)){a+=Ft("number:fraction",null,{"number:min-integer-digits":0,"number:min-numerator-digits":l[1].length,"number:denominator-value":+l[2]});break e}if(l=e.match(/(\d+)(|\.\d+)%/)){t="percentage";a+=Ft("number:number",null,{"number:decimal-places":l[2]&&l.length-1||0,"number:min-decimal-places":l[2]&&l.length-1||0,"number:min-integer-digits":l[1].length})+"<number:text>%</number:text>";break e}var o=false;if(["y","m","d"].indexOf(e[0])>-1){t="date";r:for(;i<e.length;++i)switch(s=e[i].toLowerCase()){case"h":;case"s":o=true;--i;break r;case"m":t:for(var c=i+1;c<e.length;++c)switch(e[c]){case"y":;case"d":break t;case"h":;case"s":o=true;--i;break r;};case"y":;case"d":while((e[++i]||"").toLowerCase()==s[0])s+=s[0];--i;switch(s){case"y":;case"yy":a+="<number:year/>";break;case"yyy":;case"yyyy":a+='<number:year number:style="long"/>';break;case"mmmmm":console.error("ODS has no equivalent of format |mmmmm|");case"m":;case"mm":;case"mmm":;case"mmmm":a+='<number:month number:style="'+(s.length%2?"short":"long")+'" number:textual="'+(s.length>=3?"true":"false")+'"/>';break;case"d":;case"dd":a+='<number:day number:style="'+(s.length%2?"short":"long")+'"/>';break;case"ddd":;case"dddd":a+='<number:day-of-week number:style="'+(s.length%2?"short":"long")+'"/>';break;}break;case'"':while(e[++i]!='"'||e[++i]=='"')s+=e[i];--i;a+="<number:text>"+nt(s.slice(1).replace(/""/g,'"'))+"</number:text>";break;case"/":a+="<number:text>"+nt(s)+"</number:text>";break;default:console.error("unrecognized character "+s+" in ODF format "+e);}if(!o)break e;e=e.slice(i+1);i=0}if(e.match(/^\[?[hms]/)){if(t=="number")t="time";if(e.match(/\[/)){e=e.replace(/[\[\]]/g,"");n["number:truncate-on-overflow"]="false"}for(;i<e.length;++i)switch(s=e[i].toLowerCase()){case"h":;case"m":;case"s":while((e[++i]||"").toLowerCase()==s[0])s+=s[0];--i;switch(s){case"h":;case"hh":a+='<number:hours number:style="'+(s.length%2?"short":"long")+'"/>';break;case"m":;case"mm":a+='<number:minutes number:style="'+(s.length%2?"short":"long")+'"/>';break;case"s":;case"ss":if(e[i+1]==".")do{s+=e[i+1];++i}while(e[i+1]=="0");a+='<number:seconds number:style="'+(s.match("ss")?"long":"short")+'"'+(s.match(/\./)?' number:decimal-places="'+(s.match(/0+/)||[""])[0].length+'"':"")+"/>";break;}break;case'"':while(e[++i]!='"'||e[++i]=='"')s+=e[i];--i;a+="<number:text>"+nt(s.slice(1).replace(/""/g,'"'))+"</number:text>";break;case"/":a+="<number:text>"+nt(s)+"</number:text>";break;case"a
var t=Sr(r||{});var a=jo(e,t);return Xo(a,t)}function Vo(e,r){var t=Sr(r||{});var a=Oo(e,t);return Xo(a,t)}function Xo(e,r){var t={};var a=S?"nodebuffer":typeof Uint8Array!=="undefined"?"array":"string";if(r.compression)t.compression="DEFLATE";if(r.password)t.type=a;else switch(r.type){case"base64":t.type="base64";break;case"binary":t.type="string";break;case"string":throw new Error("'string' output type invalid for '"+r.bookType+"' files");case"buffer":;case"file":t.type=a;break;default:throw new Error("Unrecognized type "+r.type);}var n=e.FullPaths?er.write(e,{fileType:"zip",type:{nodebuffer:"buffer",string:"binary"}[t.type]||t.type,compression:!!r.compression}):e.generate(t);if(typeof Deno!=="undefined"){if(typeof n=="string"){if(r.type=="binary"||r.type=="base64")return n;n=new Uint8Array(T(n))}}if(r.password&&typeof encrypt_agile!=="undefined")return Uo(encrypt_agile(n,r.password),r);if(r.type==="file")return nr(r.file,n);return r.type=="string"?vt(n):n}function Go(e,r){var t=r||{};var a=write_xlscfb(e,t);return Uo(a,t)}function Yo(e,r,t){if(!t)t="";var a=t+e;switch(r.type){case"base64":return k(gt(a));case"binary":return gt(a);case"string":return e;case"file":return nr(r.file,a,"utf8");case"buffer":{if(S)return C(a,"utf8");else if(typeof TextEncoder!=="undefined")return(new TextEncoder).encode(a);else return Yo(a,{type:"binary"}).split("").map(function(e){return e.charCodeAt(0)})};}throw new Error("Unrecognized type "+r.type)}function Jo(e,r){switch(r.type){case"base64":return y(e);case"binary":return e;case"string":return e;case"file":return nr(r.file,e,"binary");case"buffer":{if(S)return C(e,"binary");else return e.split("").map(function(e){return e.charCodeAt(0)})};}throw new Error("Unrecognized type "+r.type)}function Ko(e,r){switch(r.type){case"string":;case"base64":;case"binary":var t="";for(var a=0;a<e.length;++a)t+=String.fromCharCode(e[a]);return r.type=="base64"?k(t):r.type=="string"?vt(t):t;case"file":return nr(r.file,e);case"buffer":return e;default:throw new Error("Unrecognized type "+r.type);}}function Zo(e,r){c();Ll(e);var t=Sr(r||{});if(t.cellStyles){t.cellNF=true;t.sheetStubs=true}if(t.type=="array"){t.type="binary";var a=Zo(e,t);t.type="array";return T(a)}return Vo(e,t)}function qo(e,r){c();Ll(e);var t=Sr(r||{});if(t.cellStyles){t.cellNF=true;t.sheetStubs=true}if(t.type=="array"){t.type="binary";var a=qo(e,t);t.type="array";return T(a)}var n=0;if(t.sheet){if(typeof t.sheet=="number")n=t.sheet;else n=e.SheetNames.indexOf(t.sheet);if(!e.SheetNames[n])throw new Error("Sheet not found: "+t.sheet+" : "+typeof t.sheet)}switch(t.bookType||"xlsb"){case"xml":;case"xlml":return Yo(write_xlml(e,t),t);case"slk":;case"sylk":return Yo(Kn.from_sheet(e.Sheets[e.SheetNames[n]],t,e),t);case"htm":;case"html":return Yo(no(e.Sheets[e.SheetNames[n]],t),t);case"txt":return Jo(oc(e.Sheets[e.SheetNames[n]],t),t);case"csv":return Yo(lc(e.Sheets[e.SheetNames[n]],t),t,"\ufeff");case"dif":return Yo(Zn.from_sheet(e.Sheets[e.SheetNames[n]],t),t);case"dbf":return Ko(Jn.from_sheet(e.Sheets[e.SheetNames[n]],t),t);case"prn":return Yo(Qn.from_sheet(e.Sheets[e.SheetNames[n]],t),t);case"rtf":return Yo(sheet_to_rtf(e.Sheets[e.SheetNames[n]],t),t);case"eth":return Yo(qn.from_sheet(e.Sheets[e.SheetNames[n]],t),t);case"fods":return Yo(ko(e,t),t);case"wk1":return Ko(WK_.sheet_to_wk1(e.Sheets[e.SheetNames[n]],t),t);case"wk3":return Ko(WK_.book_to_wk3(e,t),t);case"biff2":if(!t.biff)t.biff=2;case"biff3":if(!t.biff)t.biff=3;case"biff4":if(!t.biff)t.biff=4;return Ko(write_biff_buf(e,t),t);case"biff5":if(!t.biff)t.biff=5;case"biff8":;case"xla":;case"xls":if(!t.biff)t.biff=8;return Go(e,t);case"xlsx":;case"xlsm":;case"xlam":;case"xlsb":;case"numbers":;case"ods":return Ho(e,t);default:throw new Error("Unrecognized bookType |"+t.bookType+"|");}}function Qo(e){if(e.bookType)return;var r={xls:"biff8",htm:"html",slk:"sylk",socialcalc:"eth",Sh33tJS:"WTF"};var t=e.file.slice(e.file.lastIndexOf(".")).toLowerCase();if(t.match(/^\.[a-z]+$/))e.bookType=t.slice(1);e.bookType=r[e.bookType]||e.bookType}function ec(e,r,t){var a=t||{};a.type="file";a.file=r;Qo(