Lines Matching refs:return

37 var set_ansi = function(cp/*:number*/) { if(VALID_ANSI.indexOf(cp) == -1) return; current_ansi = CS…
43 …ber>*/ = []; for(var i = 0, len = data.length; i < len; ++i) o[i] = data.charCodeAt(i); return o; }
48 return o.join("");
53 return o.join("");
58 if(c1 == 0xFF && c2 == 0xFE) return utf16leread(data.slice(2));
59 if(c1 == 0xFE && c2 == 0xFF) return utf16beread(data.slice(2));
60 if(c1 == 0xFEFF) return data.slice(1);
61 return data;
64 var _getchar = function _gc1(x/*:number*/)/*:string*/ { return String.fromCharCode(x); };
65 var _getansi = function _ga1(x/*:number*/)/*:string*/ { return String.fromCharCode(x); };
71 …if(data.charCodeAt(0) === 0xFF && data.charCodeAt(1) === 0xFE) { return $cptable.utils.decode(1200…
72 return data;
75 if(current_codepage === 1200) return String.fromCharCode(x);
76 return $cptable.utils.decode(current_codepage, [x&255,x>>8])[0];
79 return $cptable.utils.decode(current_ansi, [x])[0];
104 return o;
130 return o;
152 return o;
154 var has_buf = /*#__PURE__*/(function() { return typeof Buffer !== 'undefined' && typeof process !==…
160return nbfs ? function(buf, enc) { return (enc) ? new Buffer(buf, enc) : new Buffer(buf); } : Buff…
162 return function() {};
165 if(typeof Buffer === 'undefined') return false;
167 if(!x) return false;
169 return o.length == 1;
175 if(has_buf) return Buffer.alloc ? Buffer.alloc(len) : new Buffer(len);
176 return typeof Uint8Array != "undefined" ? new Uint8Array(len) : new Array(len);
182 if(has_buf) return Buffer.allocUnsafe ? Buffer.allocUnsafe(len) : new Buffer(len);
183 return typeof Uint8Array != "undefined" ? new Uint8Array(len) : new Array(len);
188 if(has_buf) return Buffer_from(s, "binary");
189 return s.split("").map(function(x/*:string*/)/*:number*/{ return x.charCodeAt(0) & 0xff; });
193 if(typeof ArrayBuffer === 'undefined') return s2a(s);
196 return buf;
200 if(Array.isArray(data)) return data.map(function(c) { return String.fromCharCode(c); }).join("");
201 … = []; for(var i = 0; i < data.length; ++i) o[i] = String.fromCharCode(data[i]); return o.join("");
206 return new Uint8Array(data);
211 if(data instanceof ArrayBuffer) return ab2a(new Uint8Array(data));
215 return o;
218 var bconcat = has_buf ? function(bufs) { return Buffer.concat(bufs.map(function(buf) { return Buffe…
230 return o;
232return [].concat.apply([], bufs.map(function(buf) { return Array.isArray(buf) ? buf : [].slice.cal…
264 return bconcat(out);
288 …(x/*:string*/)/*:string*/ { var o = "", i = x.length-1; while(i>=0) o += x.charAt(i--); return o; }
289 function pad0(v/*:any*/,d/*:number*/)/*:string*/{var t=""+v; return t.length>=d?t:fill('0',d-t.leng…
290 function pad_(v/*:any*/,d/*:number*/)/*:string*/{var t=""+v;return t.length>=d?t:fill(' ',d-t.lengt…
291 function rpad_(v/*:any*/,d/*:number*/)/*:string*/{var t=""+v; return t.length>=d?t:t+fill(' ',d-t.l…
292 function pad0r1(v/*:any*/,d/*:number*/)/*:string*/{var t=""+Math.round(v); return t.length>=d?t:fil…
293 function pad0r2(v/*:any*/,d/*:number*/)/*:string*/{var t=""+v; return t.length>=d?t:fill('0',d-t.le…
295 …ny*/,d/*:number*/)/*:string*/{if(v>p2_32||v<-p2_32) return pad0r1(v,d); var i = Math.round(v); ret…
297 function SSF_isgeneral(s/*:string*/, i/*:?number*/)/*:boolean*/ { i = i || 0; return s.length >= 7 …
352 return t;
457 if(!mixed) return [0, sgn * P, Q];
459 return [q, sgn*P - q*Q, Q];
462 if(v > 2958465 || v < 0) return null;
489 return out;
498return (epoch - (SSFdnthresh + (/*#__PURE__*/v.getTimezoneOffset() - /*#__PURE__*/SSFbasedate.getT…
504 return (o.indexOf(".") == -1) ? o : o.replace(/(?:\.0*|(\.\d*[1-9])0+)$/, "$1");
509 if(o.indexOf("E") == -1) return o;
510 return o.replace(/(?:\.0*|(\.\d*[1-9])0+)[Ee]/,"$1E").replace(/(E[+-])(\d)$/,"$10$2");
516 var o = SSF_strip_decimal(v.toFixed(12)); if(o.length <= w) return o;
517 o = v.toPrecision(10); if(o.length <= w) return o;
518 return v.toExponential(5);
524 return (o.length > (v<0?12:11) || o === "0" || o === "-0") ? v.toPrecision(6) : o;
535 return SSF_strip_decimal(SSF_normalize_exp(o.toUpperCase()));
551 case 'string': return v;
552 case 'boolean': return v ? "TRUE" : "FALSE";
553 case 'number': return (v|0) === v ? v.toString(10) : SSF_general_num(v);
554 case 'undefined': return "";
556 if(v == null) return "";
557 if(v instanceof Date) return SSF_format(14, datenum_local(v, opts && opts.date1904), opts);
567 return dow;
584 case 3: return months[val.m-1][1];
585 case 5: return months[val.m-1][0];
586 default: return months[val.m-1][2];
591 case 3: return days[val.q][0];
592 default: return days[val.q][1];
611 if(val.u === 0 && (fmt == "s" || fmt == "ss")) return pad0(val.S, fmt.length);
617 if(fmt === 's') return ss === 0 ? "0" : ""+ss/tt;
619 if(fmt === 'ss') return o.substr(0,2);
620 return "." + o.substr(2,fmt.length-1);
632 return outstr;
640 if(s.length <= w) return s;
643 return o;
648 return write_num(type, sfmt, val * Math.pow(10,2*mul)) + fill("%",mul);
654 return write_num(type, fmt.substr(0,idx), val / Math.pow(10,3*(fmt.length-idx)));
661 if(val == 0) return "0.0E+0";
662 else if(val < 0) return "-" + write_num_exp(fmt, -val);
677 …o = o.replace(/^([+-]?)(\d*)\.(\d*)[Ee]/,function($$,$1,$2,$3) { return $1 + $2 + $3.substr(0,(per…
681 return o.replace("e","E");
687return sign + (base === 0 ? "" : ""+base) + " " + (myn === 0 ? fill(" ", r[1].length + 1 + r[4].le…
690 return sign + (aval === 0 ? "" : ""+aval) + fill(" ", r[1].length + 2 + r[4].length);
703 return o;
705 function rnd(val/*:number*/, d/*:number*/)/*:string*/ { var dd = Math.pow(10,d); return ""+(Math.ro…
708 if (d < ('' + Math.round(_frac * dd)).length) return 0;
709 return Math.round(_frac * dd);
713 return 1;
715 return 0;
718 if(val < 2147483647 && val > -2147483648) return ""+(val >= 0 ? (val|0) : (val-1|0));
719 return ""+Math.floor(val);
724 if(val >= 0) return write_num_flt('n', ffmt, val);
725 return '(' + write_num_flt('n', ffmt, -val) + ')';
727 if(fmt.charCodeAt(fmt.length - 1) === 44) return write_num_cm(type, fmt, val);
728 if(fmt.indexOf('%') !== -1) return write_num_pct(type, fmt, val);
729 if(fmt.indexOf('E') !== -1) return write_num_exp(fmt, val);
730 if(fmt.charCodeAt(0) === 36) return "$"+write_num_flt(type,fmt.substr(fmt.charAt(1)==' '?2:1),val);
733 if(fmt.match(/^00+$/)) return sign + pad0r(aval,fmt.length);
736 return o.length > fmt.length ? o : hashq(fmt.substr(0,fmt.length-o.length)) + o;
738 if((r = fmt.match(frac1))) return write_num_f1(r, aval, sign);
739 if(fmt.match(/^#+0+$/)) return sign + pad0r(aval,fmt.length - fmt.indexOf("0"));
741 …])).replace(/\.$/,"."+hashq(r[1])).replace(/\.(\d*)$/,function($$, $1) { return "." + $1 + fill("0…
742 return fmt.indexOf("0.") !== -1 ? o : o.replace(/^0\./,".");
746return sign + rnd(aval, r[2].length).replace(/\.(\d*[1-9])0*$/,".$1").replace(/^(-?\d*)$/,"$1.").r…
748 if((r = fmt.match(/^#{1,3},##0(\.?)$/))) return sign + commaify(pad0r(aval,0));
750return val < 0 ? "-" + write_num_flt(type, fmt, -val) : commaify(""+(Math.floor(val) + carry(val, …
752 if((r = fmt.match(/^#,#*,#0/))) return write_num_flt(type,fmt.replace(/^#,#*,/,""),val);
756return _strrev(_strrev(fmt.replace(/\\/g,"")).replace(/[0#]/g,function(x){return ri<o.length?o.cha…
760 return "(" + o.substr(0,3) + ") " + o.substr(3, 3) + "-" + o.substr(6);
773 return o;
778return sign + (ff[0]||(ff[1] ? "" : "0")) + " " + (ff[1] ? pad_(ff[1],ri) + r[2] + "/" + r[3] + rp…
782 if(fmt.length <= o.length) return o;
783 return hashq(fmt.substr(0,fmt.length-o.length)) + o;
789 return hashq(fmt.substr(0,lres) + o + fmt.substr(fmt.length-rres));
793return val < 0 ? "-" + write_num_flt(type, fmt, -val) : commaify(flr(val)).replace(/^\d,\d{3}$/,"0…
796 case "###,##0.00": return write_num_flt(type, "#,##0.00", val);
799 case "#,###": var x = commaify(pad0r(aval,0)); return x !== "0" ? sign + x : "";
800 case "###,###.00": return write_num_flt(type, "###,##0.00",val).replace(/^0\./,".");
801 case "#,###.00": return write_num_flt(type, "#,##0.00",val).replace(/^0\./,".");
809 return write_num(type, fmt.substr(0,idx), val / Math.pow(10,3*(fmt.length-idx)));
813 return write_num(type, sfmt, val * Math.pow(10,2*mul)) + fill("%",mul);
819 if(val == 0) return "0.0E+0";
820 else if(val < 0) return "-" + write_num_exp2(fmt, -val);
831 …o = o.replace(/^([+-]?)(\d*)\.(\d*)[Ee]/,function($$,$1,$2,$3) { return $1 + $2 + $3.substr(0,(per…
835 return o.replace("e","E");
840 if(val >= 0) return write_num_int('n', ffmt, val);
841 return '(' + write_num_int('n', ffmt, -val) + ')';
843 if(fmt.charCodeAt(fmt.length - 1) === 44) return write_num_cm2(type, fmt, val);
844 if(fmt.indexOf('%') !== -1) return write_num_pct2(type, fmt, val);
845 if(fmt.indexOf('E') !== -1) return write_num_exp2(fmt, val);
846 if(fmt.charCodeAt(0) === 36) return "$"+write_num_int(type,fmt.substr(fmt.charAt(1)==' '?2:1),val);
849 if(fmt.match(/^00+$/)) return sign + pad0(aval,fmt.length);
852 return o.length > fmt.length ? o : hashq(fmt.substr(0,fmt.length-o.length)) + o;
854 if((r = fmt.match(frac1))) return write_num_f2(r, aval, sign);
855 if(fmt.match(/^#+0+$/)) return sign + pad0(aval,fmt.length - fmt.indexOf("0"));
861 return "." + $1 + fill("0", hashq(r[1]).length-$1.length); });
862 return fmt.indexOf("0.") !== -1 ? o : o.replace(/^0\./,".");
866return sign + (""+aval).replace(/\.(\d*[1-9])0*$/,".$1").replace(/^(-?\d*)$/,"$1.").replace(/^0\./…
868 if((r = fmt.match(/^#{1,3},##0(\.?)$/))) return sign + commaify((""+aval));
870return val < 0 ? "-" + write_num_int(type, fmt, -val) : commaify((""+val)) + "." + fill('0',r[1].l…
872 if((r = fmt.match(/^#,#*,#0/))) return write_num_int(type,fmt.replace(/^#,#*,/,""),val);
876return _strrev(_strrev(fmt.replace(/\\/g,"")).replace(/[0#]/g,function(x){return ri<o.length?o.cha…
880 return "(" + o.substr(0,3) + ") " + o.substr(3, 3) + "-" + o.substr(6);
893 return o;
898return sign + (ff[0]||(ff[1] ? "" : "0")) + " " + (ff[1] ? pad_(ff[1],ri) + r[2] + "/" + r[3] + rp…
902 if(fmt.length <= o.length) return o;
903 return hashq(fmt.substr(0,fmt.length-o.length)) + o;
909 return hashq(fmt.substr(0,lres) + o + fmt.substr(fmt.length-rres));
912return val < 0 ? "-" + write_num_int(type, fmt, -val) : commaify(""+val).replace(/^\d,\d{3}$/,"0$&…
917 case "#,###": var x = commaify(""+aval); return x !== "0" ? sign + x : "";
919 …if(fmt.match(/\.[0#?]*$/)) return write_num_int(type, fmt.slice(0,fmt.lastIndexOf(".")), val) + ha…
924 return (val|0) === val ? write_num_int(type, fmt, val) : write_num_flt(type, fmt, val);
940 return out;
954 if(fmt.charAt(i+1) === "1" || fmt.charAt(i+1) === "2") return true;
958 case 'm': case 'd': case 'y': case 'h': case 's': case 'e': case 'g': return true;
960 if(fmt.substr(i, 3).toUpperCase() === "A/P") return true;
961 if(fmt.substr(i, 5).toUpperCase() === "AM/PM") return true;
962 if(fmt.substr(i, 5).toUpperCase() === "上午/下午") return true;
967 if(o.match(SSF_abstime)) return true;
983 return false;
1005 … if(dt==null) { dt=SSF_parse_date_code(v, opts, fmt.charAt(i+1) === "2"); if(dt==null) return ""; }
1013 if(v < 0) return "";
1014 if(dt==null) { dt=SSF_parse_date_code(v, opts); if(dt==null) return ""; }
1026 if(dt==null && q.t === 'T') return "";
1033 if(dt==null) { dt=SSF_parse_date_code(v, opts); if(dt==null) return ""; }
1191 return retval;
1196 if(rr == null) return false;
1199 case "=": if(v == thresh) return true; break;
1200 case ">": if(v > thresh) return true; break;
1201 case "<": if(v < thresh) return true; break;
1202 case "<>": if(v != thresh) return true; break;
1203 case ">=": if(v >= thresh) return true; break;
1204 case "<=": if(v <= thresh) return true; break;
1206 return false;
1213 if(typeof v !== "number") return [4, fmt.length === 4 || lat>-1?fmt[fmt.length-1]:"@"];
1221 if(fmt[0].indexOf("[") === -1 && fmt[1].indexOf("[") === -1) return [l, ff];
1225return chkcond(v, m1) ? [l, fmt[0]] : chkcond(v, m2) ? [l, fmt[1]] : [l, fmt[m1 != null && m2 != n…
1227 return [l, ff];
1244 if(SSF_isgeneral(sfmt,0)) return SSF_general(v, o);
1247 if(SSF_isgeneral(f[1])) return SSF_general(v, o);
1249 else if(v === "" || v == null) return "";
1250 return eval_fmt(f[1], v, o, f[0]);
1255 /*::if(typeof idx != 'number') return 0x188; */
1257 /*::if(typeof idx != 'number') return 0x188; */
1261 /*::if(typeof idx != 'number') return 0x188; */
1264 /*::if(typeof idx != 'number') return 0x188; */
1266 return idx;
1284 get_table: function get_table() { return SSF._table = table_fmt; }
1332 return new RegExp("^" + fmt + "$");
1349 if(H == -1 && M == -1 && S == -1) return datestr;
1350 if(Y == -1 && m == -1 && d == -1) return timestr;
1351 return datestr + "T" + timestr;
1360 return SSF_load(bad_formats[fmt] || fmt, idx);
1425 return typeof Int32Array !== 'undefined' ? new Int32Array(table) : table;
1439 return out;
1448 return ~C;
1463 return ~C;
1487 return ~C;
1493 return CRC32;
1503 if((c = L[i].length - R[i].length)) return c;
1504 if(L[i] != R[i]) return L[i] < R[i] ? -1 : 1;
1506 return L.length - R.length;
1509 …if(p.charAt(p.length - 1) == "/") return (p.slice(0,-1).indexOf("/") === -1) ? p : dirname(p.slice…
1511 return (c === -1) ? p : p.slice(0, c+1);
1515 if(p.charAt(p.length - 1) == "/") return filename(p.slice(0, -1));
1517 return (c === -1) ? p : p.slice(c+1);
1555 return val;
1589 return o;
1592 function get_fs() { return fs || (fs = _fs); }
1594 if(file[0] == 0x50 && file[1] == 0x4b) return parse_zip(file, options);
1595 if((file[0] | 0x20) == 0x6d && (file[1]|0x20) == 0x69) return parse_mad(file, options);
1616 case 0: if(mv[1] == 0) return parse_zip(file, options);
1691 return o;
1696 if(blob[blob.l] == 0x50 && blob[blob.l + 1] == 0x4b) return [0, 0];
1707 return [blob.read_shift(2,'u'), mver];
1736 return sectors;
1780 //return (payload.slice(start*MSSZ, start*MSSZ + size)/*:any*/);
1788 if(o.length === 0) return (new_buf(0)/*:any*/);
1789 return (bconcat(o).slice(0, entry.size)/*:any*/);
1800 if(!sector) return;
1824 return {nodes: buf, data:__toBuffer([buf_chain])};
1852 return sector_list;
1908return new Date(( ( (__readUInt32LE(blob,offset+4)/1e7)*Math.pow(2,32)+__readUInt32LE(blob,offset)…
1913 return parse(fs.readFileSync(filename), options);
1922 …peof blob !== 'string') throw "Must pass a filename when type='file'"; */return read_file(blob, op…
1923 …g') throw "Must pass a base64-encoded binary string when type='file'"; */return parse(s2a(Base64_d…
1924 …blob !== 'string') throw "Must pass a binary string when type='file'"; */return parse(s2a(blob), o…
1926 return parse(/*::typeof blob == 'string' ? new Buffer(blob, 'utf-8') : */blob, options);
1943 if(CFB.find(cfb, "/" + nm)) return;
1967 if(!gc && !f) return;
2000 data.sort(function(x,y) { return namecmp(x[0], y[0]); });
2033 if(_opts.fileType == 'mad') return write_mad(cfb, _opts);
2036 case 'zip': return write_zip(cfb, _opts);
2037 //case 'mad': return write_mad(cfb, _opts);
2060 return L;
2189 return o;
2193 var UCFullPaths/*:Array<string>*/ = cfb.FullPaths.map(function(x) { return x.toUpperCase(); });
2194 …var UCPaths/*:Array<string>*/ = UCFullPaths.map(function(x) { var y = x.split("/"); return y[y.len…
2200 if(w !== -1) return cfb.FileIndex[w];
2206 …if((m ? UCFullPaths[w].replace(chr1,'!') : UCFullPaths[w]).replace(chr0,'') == UCPath) return cfb.…
2207 …if((m ? UCPaths[w].replace(chr1,'!') : UCPaths[w]).replace(chr0,'') == UCPath) return cfb.FileInde…
2209 return null;
2247 return out.join("");
2253 case "file": get_fs(); fs.writeFileSync(options.filename, (o/*:any*/)); return o;
2254 case "binary": return typeof o == "string" ? o : a2s(o);
2255 case "base64": return Base64_encode(typeof o == "string" ? o : a2s(o));
2256 case "buffer": if(has_buf) return Buffer.isBuffer(o) ? o : Buffer_from(o);
2258 case "array": return typeof o == "string" ? s2a(o) : o;
2260 return o;
2273 if(!_zlib) return _inflate(payload, usz);
2278 return out;
2282 return _zlib ? _zlib.deflateRawSync(payload) : _deflate(payload);
2292 …var t = (((((n<<1)|(n<<11)) & 0x22110) | (((n<<5)|(n<<15)) & 0x88440))); return ((t>>16) | (t>>8) …
2301 if(b <= 8) return rev >>> (8-b);
2303 if(b <= 16) return rev >>> (16-b);
2305 return rev >>> (24-b);
2309 function read_bits_2(buf, bl) { var w = (bl&7), h = (bl>>>3); return ((buf[h]|(w <= 6 ? 0 : buf[h+1…
2310 function read_bits_3(buf, bl) { var w = (bl&7), h = (bl>>>3); return ((buf[h]|(w <= 5 ? 0 : buf[h+1…
2311 function read_bits_4(buf, bl) { var w = (bl&7), h = (bl>>>3); return ((buf[h]|(w <= 4 ? 0 : buf[h+1…
2312 function read_bits_5(buf, bl) { var w = (bl&7), h = (bl>>>3); return ((buf[h]|(w <= 3 ? 0 : buf[h+1…
2313 function read_bits_7(buf, bl) { var w = (bl&7), h = (bl>>>3); return ((buf[h]|(w <= 1 ? 0 : buf[h+1…
2319 if(n < 8 - w) return v & f;
2321 if(n < 16 - w) return v & f;
2323 if(n < 24 - w) return v & f;
2325 return v & f;
2335 return bl + 3;
2342 return bl + 1;
2349 return bl + 8;
2357 return bl + 16;
2363 if(L >= sz) return b;
2369 return o;
2374 return a;
2377 return b;
2384 return o;
2422 return maxlen;
2468 return out.l;
2549 return out.l;
2551 return function _deflateRaw(data, out) {
2552 if(data.length < 8) return write_stored(data, out);
2553 return write_huff_fixed(data, out);
2560 return buf.slice(0, off);
2639 return boff;
2642 /* return [ data, bytesRead ] */
2645 if(data[0] == 3 && !(data[1] & 0x3)) { return [new_raw_buf(usz), 2]; }
2717 if(usz) return [outbuf, (boff+7)>>>3];
2718 return [outbuf.slice(0, woff), (boff+7)>>>3];
2725 return out[0];
2782 return o;
2945 return bconcat(([bconcat((out/*:any*/)), bconcat(cdirs), o]/*:any*/));
2961 if(fi.ctype) return fi.ctype;
2964 if(m && ContentTypeMap[m[1]]) return ContentTypeMap[m[1]];
2968 if(m && ContentTypeMap[m[1]]) return ContentTypeMap[m[1]];
2971 return "application/octet-stream";
2979 return o.join("\r\n") + "\r\n";
2999 return "=" + (w.length == 1 ? "0" + w : w);
3024 return o.join("\r\n");
3037 …length; ++oi) o[oi] = o[oi].replace(/[=][0-9A-Fa-f]{2}/g, function($$) { return String.fromCharCod…
3038 return s2a(o.join("\r\n"));
3103 return o;
3127 return "_x" + c.charCodeAt(0).toString(16) + "_";
3129 return "_u" + u.charCodeAt(0).toString(16) + "_";
3151 return out.join("\r\n");
3156 return o;
3183 return file;
3192 return true;
3194 return false;
3203 return true;
3205 return false;
3231 return exports;
3239 if(typeof data === "string") return s2ab(data);
3240 if(Array.isArray(data)) return a2u(data);
3241 return data;
3246 …if(typeof _fs !== 'undefined' && _fs.writeFileSync) return enc ? _fs.writeFileSync(fname, payload,…
3255 return Deno.writeFileSync(fname, payload);
3259 if(typeof IE_SaveFile !== 'undefined') return IE_SaveFile(data, fname);
3263 …if(typeof navigator !== 'undefined' && navigator.msSaveBlob) return navigator.msSaveBlob(blob, fna…
3265 if(typeof saveAs !== 'undefined') return saveAs(blob, fname);
3271 return chrome.downloads.download({ url: url, filename: fname, saveAs: true});
3279 return url;
3288 out.write(payload); out.close(); return payload;
3295 if(typeof _fs !== 'undefined') return _fs.readFileSync(path);
3296 if(typeof Deno !== 'undefined') return Deno.readFileSync(path);
3302 return data;
3309 return o2;
3315 return o;
3321 return o;
3327 return o;
3336 return o;
3344 return (epoch - dnthresh) / (24 * 60 * 60 * 1000);
3355 return out;
3382 return sec;
3395 return d;
3397 if(str instanceof Date) return str;
3400 if(str.indexOf("" + s) > -1) return d;
3401 d.setFullYear(d.getFullYear() + 100); return d;
3406 return out;
3413 if(arr[0] == 0xFF && arr[1] == 0xFE) return utf8write(arr.slice(2).toString("utf16le"));
3414 …if(arr[1] == 0xFE && arr[2] == 0xFF) return utf8write(utf16beread(arr.slice(2).toString("binary"))…
3416 return arr.toString("binary");
3421 …if(arr[0] == 0xFF && arr[1] == 0xFE) return utf8write(new TextDecoder("utf-16le").decode(arr.slice…
3422 …if(arr[0] == 0xFE && arr[1] == 0xFF) return utf8write(new TextDecoder("utf-16be").decode(arr.slice…
3434return new TextDecoder("latin1").decode(arr).replace(/[€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ]/g, function(c)…
3439 return o.join("");
3443 if(typeof JSON != 'undefined' && !Array.isArray(o)) return JSON.parse(JSON.stringify(o));
3444 if(typeof o != 'object' || o == null) return o;
3445 if(o instanceof Date) return new Date(o.getTime());
3448 return out;
3451 function fill(c/*:string*/,l/*:number*/)/*:string*/ { var o = ""; while(o.length < l) o+=c; return
3456 if(!isNaN(v)) return isFinite(v) ? v : NaN;
3457 if(!/\d/.test(s)) return v;
3459 …e(/([\d]),([\d])/g,"$1$2").replace(/[$]/g,"").replace(/[%]/g, function() { wt *= 100; return "";});
3460 if(!isNaN(v = Number(ss))) return v / wt;
3461 ss = ss.replace(/[(](.*)[)]/,function($$, $1) { wt = -wt; return $1;});
3462 if(!isNaN(v = Number(ss))) return v / wt;
3463 return v;
3471 if(!M[2]) return new Date(1899,11,30,(+M[1]%12) + (M[7] == "p" ? 12 : 0), 0, 0, 0);
3473 …if(M[4]) return new Date(1899,11,30,(+M[1]%12) + (M[7] == "p" ? 12 : 0), +M[2], +M[4], parseFloat(…
3474 … else return new Date(1899,11,30,(M[7] == "p" ? 12 : 0), +M[1], +M[2], parseFloat(M[3])*1000);
3476 …else if(M[5]) return new Date(1899,11,30, (+M[1]%12) + (M[7] == "p" ? 12 : 0), +M[2], +M[5], M[6] …
3477 else return new Date(1899,11,30,(+M[1]%12) + (M[7] == "p" ? 12 : 0), +M[2], 0, 0);
3484 if(M) return fuzzytime1(M);
3488 if(isNaN(d)) return n;
3491 if(lower.length > 3 && lower_months.indexOf(lower) == -1) return n;
3492 } else if(lower.replace(/[ap]m?/, "").match(/[a-z]/)) return n;
3493 if(y < 0 || y > 8099 || s.match(/[^-0-9:,\/\\]/)) return n;
3494 return o;
3499 return function split_regex(str/*:string*/, re, def/*:string*/)/*:Array<string>*/ {
3500 if(safe_split_regex || typeof re == "string") return str.split(re);
3503 return o;
3507 if(!data) return null;
3508 if(data.content && data.type) return cc2str(data.content, true);
3509 if(data.data) return debom(data.data);
3510 if(data.asNodeBuffer && has_buf) return debom(data.asNodeBuffer().toString('binary'));
3511 if(data.asBinary) return debom(data.asBinary());
3512 …if(data._data && data._data.getContent) return debom(cc2str(Array.prototype.slice.call(data._data.…
3513 return null;
3517 if(!data) return null;
3518 if(data.data) return char_codes(data.data);
3519 if(data.asNodeBuffer && has_buf) return data.asNodeBuffer();
3522 if(typeof o == "string") return char_codes(o);
3523 return Array.prototype.slice.call(o);
3525 if(data.content && data.type) return data.content;
3526 return null;
3529 function getdata(data) { return (data && data.name.slice(-4) === ".bin") ? getdatabin(data) : getda…
3538 if(f == n || g == n) return zip.files ? zip.files[k[i]] : zip.FileIndex[i];
3540 return null;
3546 return o;
3550 if(!safe) return getdata(getzipfile(zip, file));
3551 if(!file) return null;
3552 try { return getzipdata(zip, file); } catch(e) { return null; }
3556 if(!safe) return getdatastr(getzipfile(zip, file));
3557 if(!file) return null;
3558 try { return getzipstr(zip, file); } catch(e) { return null; }
3562 if(!safe) return getdatabin(getzipfile(zip, file));
3563 if(!file) return null;
3564 try { return getzipbin(zip, file); } catch(e) { return null; }
3570 return o.sort();
3581 return CFB.utils.cfb_add(zip, path, res);
3588 function zip_new() { return CFB.utils.cfb_new(); }
3592 case "base64": return CFB.read(d, { type: "base64" });
3593 case "binary": return CFB.read(d, { type: "binary" });
3594 case "buffer": case "array": return CFB.read(d, { type: "buffer" });
3600 if(path.charAt(0) == "/") return path.slice(1);
3609 return result.join('/');
3621 if(eq === tag.length) return z;
3643 return z;
3645 function strip_ns(x/*:string*/)/*:string*/ { return x.replace(nsregex2, "<$1"); }
3663return s.replace(encregex, function($$, $1) { return encodings[$$]||String.fromCharCode(parseInt($…
3665 return raw_unescapexml(s.slice(0, i)) + s.slice(i+9,j) + raw_unescapexml(s.slice(j+3));
3667 return function unescapexml(text/*:string*/, xlsx/*:boolean*/) {
3669 return xlsx ? out.replace(/\r\n/g, "\n") : out;
3676return s.replace(decregex, function(y) { return rencoding[y]; }).replace(charegex,function(s) { re…
3678 function escapexmltag(text/*:string*/)/*:string*/{ return escapexml(text).replace(/ /g,"_x0020_"); }
3683return s.replace(decregex, function(y) { return rencoding[y]; }).replace(/\n/g, "<br/>").replace(h…
3688return s.replace(decregex, function(y) { return rencoding[y]; }).replace(htmlcharegex,function(s) …
3694 …function entrepl($$/*:string*/,$1/*:string*/)/*:string*/ { return String.fromCharCode(parseInt($1,…
3695 return function xlml_fixstr(str/*:string*/)/*:string*/ { return str.replace(entregex,entrepl); };
3697 function xlml_unfixstr(str/*:string*/)/*:string*/ { return str.replace(/(\r\n|[\r\n])/g,"\&#10;"); }
3702 case 1: case true: case '1': case 'true': return true;
3703 case 0: case false: case '0': case 'false': return false;
3706 return false;
3723 return out;
3740 return out.slice(0,k).toString('ucs2');
3743 function utf8readc(data) { return Buffer_from(data, 'binary').toString('utf8'); }
3748 var utf8write/*:StringConv*/ = has_buf ? function(data) { return Buffer_from(data, 'utf8').toString…
3771 return out.join("");
3777 return function matchtag(f/*:string*/,g/*:?string*/)/*:RegExp*/ {
3779 if(mtcache[t]) return mtcache[t];
3780return (mtcache[t] = new RegExp('<(?:\\w+:)?'+f+'(?: xml:space="preserve")?(?:[^>]*)>([\\s\\S]*?)<…
3788 ].map(function(x/*:[string, string]*/) { return [new RegExp('&' + x[0] + ';', "ig"), x[1]]; });
3789 return function htmldecode(str/*:string*/)/*:string*/ {
3804 return o;
3809 return function vt_regex(bt) {
3810 if(vt_cache[bt] !== undefined) return vt_cache[bt];
3811 return (vt_cache[bt] = new RegExp("<(?:vt:)?" + bt + ">([\\s\\S]*?)</(?:vt:)?" + bt + ">", 'g') );
3821 return res;
3827 return res;
3831 function writetag(f/*:string*/,g/*:string*/)/*:string*/ { return '<' + f + (g.match(wtregex)?' xml:…
3833 function wxt_helper(h)/*:string*/ { return keys(h).map(function(k) { return " " + k + '="' + h[k] +…
3834 function writextag(f/*:string*/,g/*:?string*/,h) { return '<' + f + ((h != null) ? wxt_helper(h) : …
3836 … t/*:?boolean*/)/*:string*/ { try { return d.toISOString().replace(/\.\d*/,""); } catch(e) { if(t)…
3843 return o;
3844 case 'number': return writextag((s|0)==s?'vt:i4':'vt:r8', escapexml(String(s)));
3845 case 'boolean': return writextag('vt:bool',s?'true':'false');
3847 if(s instanceof Date) return writextag('vt:filetime', write_w3cdtf(s));
3852 …"undefined" && d != null && d instanceof Buffer &&*/ Buffer.isBuffer(d)) return d.toString('utf8');
3853 if(typeof d === 'string') return d;
3855 if(typeof Uint8Array !== 'undefined' && d instanceof Uint8Array) return utf8read(a2s(ab2a(d)));
3901 if(e == 0x7ff) return m == 0 ? (s * Infinity) : NaN;
3904 return s * Math.pow(2, e - 52) * m;
3923 …]) for(var j=0,L=bufs[0][i].length;j<L;j+=w) x.push.apply(x, bufs[0][i].slice(j,j+w)); return x; };
3924 …buf ? function(bufs) { return (bufs[0].length > 0 && Buffer.isBuffer(bufs[0][0])) ? Buffer.concat(…
3926 …r(var i=s; i<e; i+=2) ss.push(String.fromCharCode(__readUInt16LE(b,i))); return ss.join("").replac…
3927 …sBuffer(b)/*:: || !(b instanceof Buffer)*/ || !buf_utf16le) return ___utf16le(b,s,e); return b.toS…
3929 …/=[]; for(var i=s; i<s+l; ++i) ss.push(("0" + b[i].toString(16)).slice(-2)); return ss.join(""); };
3930 …? function(b/*:RawBytes|CFBlob*/,s/*:number*/,l/*:number*/)/*:string*/ { return Buffer.isBuffer(b)…
3932 …s=[]; for(var i=s; i<e; i++) ss.push(String.fromCharCode(__readUInt8(b,i))); return ss.join(""); };
3933 var __utf8 = has_buf ? function utf8_b(b/*:RawBytes|CFBlob*/, s/*:number*/, e/*:number*/) { return
3935 var ___lpstr = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return
3938 var ___cpstr = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return
3941 …n(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = 2*__readUInt32LE(b,i); return len > 0 ? __utf8(b…
3944 …p4_(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return len > 0 ? __utf16l…
3947 var ___8lpp4 = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return
3950 var ___double = function(b/*:RawBytes|CFBlob*/, idx/*:number*/) { return read_double_le(b, idx);};
3953 var is_buf = function is_buf_a(a) { return Array.isArray(a) || (typeof Uint8Array !== "undefined" &…
3956 …r.isBuffer(b)/*:: || !(b instanceof Buffer)*/) return ___lpstr(b, i); var len = b.readUInt32LE(i);…
3957 …r.isBuffer(b)/*:: || !(b instanceof Buffer)*/) return ___cpstr(b, i); var len = b.readUInt32LE(i);…
3958 … || !(b instanceof Buffer)*/ || !buf_utf16le) return ___lpwstr(b, i); var len = 2*b.readUInt32LE(i…
3959 …:: || !(b instanceof Buffer)*/ || !buf_utf16le) return ___lpp4(b, i); var len = b.readUInt32LE(i);…
3960 …r.isBuffer(b)/*:: || !(b instanceof Buffer)*/) return ___8lpp4(b, i); var len = b.readUInt32LE(i);…
3961 …ber*/) { if(Buffer.isBuffer(b)/*::&& b instanceof Buffer*/) return b.readDoubleLE(i); return ___do…
3962 …is_buf = function is_buf_b(a) { return Buffer.isBuffer(a) || Array.isArray(a) || (typeof Uint8Arra…
3967 …__utf16le = function(b/*:RawBytes|CFBlob*/,s/*:number*/,e/*:number*/) { return $cptable.utils.deco…
3968 …__utf8 = function(b/*:RawBytes|CFBlob*/,s/*:number*/,e/*:number*/) { return $cptable.utils.decode(…
3969 …__lpstr = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return len…
3970 …__cpstr = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return len…
3971 …__lpwstr = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = 2*__readUInt32LE(b,i); return
3972 …__lpp4 = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return len …
3973 …__8lpp4 = function(b/*:RawBytes|CFBlob*/,i/*:number*/) { var len = __readUInt32LE(b,i); return len…
3977 var __readUInt8 = function(b/*:RawBytes|CFBlob*/, idx/*:number*/)/*:number*/ { return b[idx]; };
3978 var __readUInt16LE = function(b/*:RawBytes|CFBlob*/, idx/*:number*/)/*:number*/ { return (b[idx+1]*…
3979 …CFBlob*/, idx/*:number*/)/*:number*/ { var u = (b[idx+1]*(1<<8))+b[idx]; return (u < 0x8000) ? u :…
3980 var __readUInt32LE = function(b/*:RawBytes|CFBlob*/, idx/*:number*/)/*:number*/ { return b[idx+3]*(…
3981 var __readInt32LE = function(b/*:RawBytes|CFBlob*/, idx/*:number*/)/*:number*/ { return (b[idx+3]<<…
3982 var __readInt32BE = function(b/*:RawBytes|CFBlob*/, idx/*:number*/)/*:number*/ { return (b[idx]<<24…
3999 else return ReadShift.call(this, size, 'dbcs');
4026 return oo.join("") + vv;
4044 return oo.join("") + vv;
4052 case 1: oI = __readUInt8(this, this.l); this.l++; return oI;
4053 case 2: oI = (t === 'i' ? __readInt16LE : __readUInt16LE)(this, this.l); this.l += 2; return oI;
4055 …===0)) { oI = ((size > 0) ? __readInt32LE : __readInt32BE)(this, this.l); this.l += 4; return oI; }
4056 else { oR = __readUInt32LE(this, this.l); this.l += 4; } return oR;
4061 this.l += 8; return oR;
4066 this.l+=size; return o;
4106 } return this;
4116 return this;
4127 this.l += size; return this;
4148 return o;
4153 if(!data) return;
4167 if(cb(d, R, RT)) return;
4177 return o;
4183 if(!curbuf) return;
4193 if(curbuf && (sz < (curbuf.length - curbuf.l))) return curbuf;
4195 return (curbuf = newblk(Math.max(sz+1, blksz)));
4200 return bconcat(bufs);
4205 return ({ next:next, push:push, end:end, _bufs:bufs }/*:any*/);
4210 if(isNaN(t)) return; // TODO: throw something here?
4240 return out;
4247 return out;
4256 return s;
4262return (r.s.cRel ? "" : "$") + encode_col(r.s.c) + ":" + (r.e.cRel ? "" : "$") + encode_col(r.e.c);
4267return (r.s.rRel ? "" : "$") + encode_row(r.s.r) + ":" + (r.e.rRel ? "" : "$") + encode_row(r.e.r);
4270 return encode_cell_xls(r.s, opts.biff) + ":" + encode_cell_xls(r.e, opts.biff);
4272 function decode_row(rowstr/*:string*/)/*:number*/ { return parseInt(unfix_row(rowstr),10) - 1; }
4273 function encode_row(row/*:number*/)/*:string*/ { return "" + (row + 1); }
4274 function fix_row(cstr/*:string*/)/*:string*/ { return cstr.replace(/([A-Z]|^)(\d+)$/,"$1$$$2"); }
4275 function unfix_row(cstr/*:string*/)/*:string*/ { return cstr.replace(/\$(\d+)$/,"$1"); }
4277 …(colstr), d = 0, i = 0; for(; i !== c.length; ++i) d = 26*d + c.charCodeAt(i) - 64; return d - 1; }
4278 …++col; col; col=Math.floor((col-1)/26)) s = String.fromCharCode(((col-1)%26) + 65) + s; return s; }
4279 function fix_col(cstr/*:string*/)/*:string*/ { return cstr.replace(/^([A-Z])/,"$$$1"); }
4280 function unfix_col(cstr/*:string*/)/*:string*/ { return cstr.replace(/^\$([A-Z])/,"$1"); }
4282 function split_cell(cstr/*:string*/)/*:Array<string>*/ { return cstr.replace(/(\$?[A-Z]*)(\$?\d*)/,…
4283 //function decode_cell(cstr/*:string*/)/*:CellAddress*/ { var splt = split_cell(cstr); return { c:d…
4291 return { c: C - 1, r:R - 1 };
4293 //function encode_cell(cell/*:CellAddress*/)/*:string*/ { return encode_col(cell.c) + encode_row(ce…
4298 return s + (cell.r + 1);
4302 if(idx == -1) return { s: decode_cell(range), e: decode_cell(range) };
4303 return { s: decode_cell(range.slice(0, idx)), e: decode_cell(range.slice(idx + 1)) };
4309 return encode_range(cs.s, cs.e);
4316 return cs == ce ? cs : cs + ":" + ce;
4320return "$" + encode_col(s.s.c) + "$" + encode_row(s.s.r) + ":$" + encode_col(s.e.c) + "$" + encode…
4326 if (/[^\w\u4E00-\u9FFF\u3040-\u30FF]/.test(sname)) return "'" + sname.replace(/'/g, "''") + "'";
4327 return sname;
4346 if(i === len || cc != 10) { o.e.c=o.s.c; o.e.r=o.s.r; return o; }
4360 return o;
4365 if(cell.z != null) try { return (cell.w = SSF_format(cell.z, q ? datenum(v) : v)); } catch(e) { }
4366 …try { return (cell.w = SSF_format((cell.XF||{}).numFmtId||(q ? 14 : 0), q ? datenum(v) : v)); } c…
4370 if(cell == null || cell.t == null || cell.t == 'z') return "";
4371 if(cell.w !== undefined) return cell.w;
4373 if(cell.t == "e") return BErr[cell.v] || cell.v;
4374 if(v == undefined) return safe_format_cell(cell, cell.v);
4375 return safe_format_cell(cell, v);
4381 return { SheetNames: [n], Sheets: sheets };
4448 return ws;
4450 function aoa_to_sheet(data/*:AOA*/, opts/*:?any*/)/*:Worksheet*/ { return sheet_add_aoa(null, data,…
4453 return data.read_shift(4, 'i');
4458 return o;
4464 return cchCharacters === 0 ? "" : data.read_shift(cchCharacters, 'dbcs');
4470 return _null ? o.slice(0, o.l) : o;
4476 // return cchCharacters === 0 ? "" : data.read_shift(cchCharacters, "utf16le");
4481 return { ich: data.read_shift(2), ifnt: data.read_shift(2) };
4487 return o;
4508 return z;
4515 return _null ? o.slice(0, o.l) : o;
4526 return _null ? o.slice(0, o.l) : o;
4535 return { c: col, iStyleRef: iStyleRef };
4542 return o;
4550 return { c:-1, iStyleRef: iStyleRef };
4556 return o;
4566return cchCharacters === 0 || cchCharacters === 0xFFFFFFFF ? "" : data.read_shift(cchCharacters, '…
4572 return _null ? o.slice(0, o.l) : o;
4590 return fX100 ? (RK / 100) : RK;
4609 return cell;
4617 return o;
4632 // return out.join(",");
4641 // return bconcat(out);
4648 return data.read_shift(8, 'f');
4650 function write_Xnum(data, o) { return (o || new_buf(8)).write_shift(8, data, 'f'); }
4683 return out;
4687 if (!color || color.auto) { o.write_shift(4, 0); o.write_shift(4, 0); return o; }
4714 return o;
4731 return out;
4744 return o;
4753 case 0x00000000: return "";
4754 case 0xffffffff: case 0xfffffffe: return ClipFmt[o.read_shift(4)] || "";
4758 return o.read_shift(0, w == 1 ? "lpstr" : "lpwstr");
4760 function parse_ClipboardFormatOrAnsiString(o) { return parse_ClipboardFormatOrString(o, 1); }
4761 function parse_ClipboardFormatOrUnicodeString(o) { return parse_ClipboardFormatOrString(o, 2); }
4946 …r/*:Array<number>*/)/*:Array<[number, number, number]>*/ { return arr.map(function(x) { return [(x…
5307 return ({
5317 if(!data || !data.match) return ct;
5336 return ct;
5367 return writextag('Default', null, {'Extension':x[0], 'ContentType': x[1]});
5415 return o.join("");
5456 return file.slice(0,n+1) + '_rels/' + file.slice(n+1) + ".rels";
5461 if (!data) return rels;
5478 return rels;
5492 return o.join("");
5509 return rId;
5539 return o.join("");
5544 return [
5551 return [
5566 return o.join("");
5570return '<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmln…
5600 return r;
5613 return p;
5617 if(p[f] != null || g == null || g === "") return;
5633 if(!cp && !opts.Props) return o.join("");
5649 return o.join("");
5675 else for(var j = 0; j < HP.length; ++j) v = v.concat(HP[j].map(function(hp) { return {v:hp}; }));
5676 …var parts = (typeof TOP == "string") ? parseVector(TOP, opts).map(function (x) { return x.v; }) : …
5737 return p;
5751 if(cp[f[1]] === undefined) return;
5762 …o[o.length] = (W('TitlesOfParts', W('vt:vector', cp.SheetNames.map(function(s) { return "<vt:lpstr…
5764 return o.join("");
5809 return p;
5817 if(!cp) return o.join("");
5827 return o.join("");
5873 for(var i = 0; i < CORE_PROPS.length; ++i) if(CORE_PROPS[i][1] == m) return CORE_PROPS[i];
5874 for(i = 0; i < EXT_PROPS.length; ++i) if(EXT_PROPS[i][1] == m) return EXT_PROPS[i];
5877 if(Props[p[1]] == null) return;
5887 return writextag('DocumentProperties', o.join(""), {xmlns:XLMLNS.o });
5894 /*:: if(!Props) return; */
5895 if(!Object.prototype.hasOwnProperty.call(Props, k)) return;
5896 for(var i = 0; i < CORE_PROPS.length; ++i) if(k == CORE_PROPS[i][1]) return;
5897 for(i = 0; i < EXT_PROPS.length; ++i) if(k == EXT_PROPS[i][1]) return;
5898 for(i = 0; i < BLACKLIST.length; ++i) if(k == BLACKLIST[i]) return;
5908 /*:: if(!Custprops) return; */
5909 if(!Object.prototype.hasOwnProperty.call(Custprops, k)) return;
5910 if(Props && Object.prototype.hasOwnProperty.call(Props, k)) return;
5919 return '<' + T + ' xmlns="' + XLMLNS.o + '">' + o.join("") + '</' + T + '>';
5926return new Date(((dwHighDateTime/1e7*Math.pow(2,32) + dwLowDateTime/1e7) - 11644473600)*1000).toIS…
5935 var o = new_buf(8); o.write_shift(4, l); o.write_shift(4, h); return o;
5943 return str;
5950 return str;
5957 if(stringType === 0x1F /*VT_LPWSTR*/) return parse_lpwstr(blob);
5958 return parse_lpstr(blob, stringType, pad);
5961 function parse_VtString(blob, t/*:number*/, pad/*:?boolean*/) { return parse_VtStringBase(blob, t, …
5962 …{ if(!t) throw new Error("VtUnalignedString must have positive length"); return parse_VtStringBase…
5973 return ret;
5981 return ret;
5991 return [headingString, headerParts];
5999 return out;
6013 return dict;
6022 return bytes;
6032 return o;
6042 case 0x02 /*VT_I2*/: ret = blob.read_shift(2, 'i'); if(!opts.raw) blob.l += 2; return ret;
6043 case 0x03 /*VT_I4*/: ret = blob.read_shift(4, 'i'); return ret;
6044 case 0x0B /*VT_BOOL*/: return blob.read_shift(4) !== 0x0;
6045 case 0x13 /*VT_UI4*/: ret = blob.read_shift(4); return ret;
6046 case 0x1E /*VT_LPSTR*/: return parse_lpstr(blob, t, 4).replace(chr0,'');
6047 case 0x1F /*VT_LPWSTR*/: return parse_lpwstr(blob);
6048 case 0x40 /*VT_FILETIME*/: return parse_FILETIME(blob);
6049 case 0x41 /*VT_BLOB*/: return parse_BLOB(blob);
6050 case 0x47 /*VT_CF*/: return parse_ClipboardData(blob);
6051 case 0x50 /*VT_STRING*/: return parse_VtString(blob, t, !opts.raw).replace(chr0,'');
6052 case 0x51 /*VT_USTR*/: return parse_VtUnalignedString(blob, t/*, 4*/).replace(chr0,'');
6053 case 0x100C /*VT_VECTOR|VT_VARIANT*/: return parse_VtVecHeadingPairValue(blob);
6056 return t == 0x101F ? parse_VtVecLpwstrValue(blob) : parse_VtVecUnalignedLpstrValue(blob);
6078 return bconcat([o, p]);
6094 Props.sort(function(x,y) { return x[1] - y[1]; });
6170 return PropH;
6175 case "boolean": return 0x0B;
6176 case "number": return ((val|0)==val) ? 0x03 : 0x05;
6177 case "string": return 0x1F;
6178 case "object": if(val instanceof Date) return 0x40; break;
6180 return -1;
6247 return bconcat([hdr].concat(piao).concat(prop));
6253 if(!blob) return ({}/*:any*/);
6276 if(NumSets === 1) return rval;
6283 return rval;
6304 return bconcat(bufs);
6307 function parsenoop2(blob, length) { blob.read_shift(length); return null; }
6308 …on writezeroes(n, o) { if(!o) o=new_buf(n); for(var j=0; j<n; ++j) o.write_shift(1, 0); return o; }
6314 return arr;
6317 function parsebool(blob, length/*:number*/) { return blob.read_shift(length) === 0x1; }
6318 function writebool(v/*:any*/, o) { if(!o) o=new_buf(2); o.write_shift(2, +!!v); return o; }
6320 function parseuint16(blob/*::, length:?number, opts:?any*/) { return blob.read_shift(2, 'u'); }
6321 function writeuint16(v/*:number*/, o) { if(!o) o=new_buf(2); o.write_shift(2, v); return o; }
6322 function parseuint16a(blob, length/*:: :?number, opts:?any*/) { return parslurp(blob,length,parseui…
6329 return t === 0x01 ? v : v === 0x01;
6335 return o;
6353 return o;
6374 return z;
6389 return bconcat(out);
6396 if(opts.biff >= 2 && opts.biff <= 5) return blob.read_shift(cch, 'cpstr');
6397 if(opts.biff >= 12) return blob.read_shift(cch, 'dbcs-cont');
6402 return retval;
6408 if(cch === 0) { blob.l++; return ""; }
6409 return parse_XLUnicodeStringNoCch(blob, cch, opts);
6413 if(opts.biff > 5) return parse_XLUnicodeString(blob, length, opts);
6415 if(cch === 0) { blob.l++; return ""; }
6416 return blob.read_shift(cch, (opts.biff <= 4 || !blob.lens ) ? 'cpstr' : 'sbcs-cont');
6424 return o;
6433 return [flags, accel];
6448 return url;
6459 if(sz === 0) return preamble + ansiPath.replace(/\\/g,"/");
6463 return preamble + unicodePath;
6470 case "e0c9ea79f9bace118c8200aa004ba90b": return parse_URLMoniker(blob, length);
6471 case "0303000000000000c000000000000046": return parse_FileMoniker(blob, length);
6480 return o;
6487 return o;
6514 return out;
6549 return out.slice(0, out.l);
6553 …ift(1), g = blob.read_shift(1), b = blob.read_shift(1), a = blob.read_shift(1); return [r,g,b,a]; }
6556 function parse_LongRGB(blob, length) { var x = parse_LongRGBA(blob, length); x[3] = 0; return x; }
6564 return ({r:rw, c:col, ixfe:ixfe}/*:any*/);
6571 return o;
6579 return {type: rt, flags: flags};
6584 function parse_OptXLUnicodeString(blob, length, opts) { return length === 0 ? "" : parse_XLUnicodeS…
6590 return [iSupBook, itabFirst, itabLast];
6597 return [ixfe, RK];
6609 return udfName;
6618 return {s:{c:colFirst, r:rwFirst}, e:{c:colLast,r:rwLast}};
6626 return o;
6635 return {s:{c:colFirst, r:rwFirst}, e:{c:colLast,r:rwLast}};
6648 return [id, ot, flags];
6658 return out;
6666 return out;
6700 } catch(e) { blob.l = tgt; return fts; }
6703 return fts;
6725 return o;
6749 return out;
6755 if(length === 0) return 0x04b0;
6757 return 0x04b0;
6763 if(opts.enc) { blob.l += length; return ""; }
6768 return UserName;
6778 return o;
6784 return { fDialog: flags & 0x10, fBelow: flags & 0x40, fRight: flags & 0x80 };
6800 return { pos:pos, hs:hidden, dt:dt, name:name };
6812 out.l = o.l; return out;
6825 return strs;
6834 …/*::(*/o/*:: :any)*/.parts = [header.length].concat(strs.map(function(str) { return str.length; })…
6835 return o;
6843 return extsst;
6861 return z;
6870 return fullcalc !== 0x0;
6880 return blob.read_shift(4);
6894 return [fl, miyRw];
6902 return { Pos: [xWn, yWn], Dim: [dxWn, dyWn], Flags: flags, CurTab: iTabCur,
6916 return o;
6920 if(opts && opts.biff >= 2 && opts.biff < 5) return {};
6922 return { RTL: f & 0x40 };
6932 return o;
6951 return o;
6965 return o;
6972 return cell;
6978 return o;
6989 return cell;
6998 return o;
7006 return [numFmtId, fmtstr];
7017 return out;
7028 return {s: {r:r, c:c}, e: {r:R, c:C}};
7038 return o;
7045 return {r:rw, c:col, ixfe:rkrec[0], rknum:rkrec[1]};
7057 return {r:rw, c:col, C:lastcol, rkrec:rkrecs};
7068 return {r:rw, c:col, C:lastcol, ixfe:ixfes};
7078 if(!opts.cellStyles) return o;
7110 return o;
7112 //function parse_CellXF(blob, length, opts) {return parse_CellStyleXF(blob,length,0, opts);}
7113 //function parse_StyleXF(blob, length, opts) {return parse_CellStyleXF(blob,length,1, opts);}
7122 return o;
7141 return o;
7151 return out;
7158 return o;
7168 return cell;
7174 return o;
7183 return cell;
7189 return o;
7200 if(cch == 0x0401 || cch == 0x3A01) return [cch, ctab];
7206 return [cch, ctab, virtPath, rgst];
7226 return o;
7249 return {
7259 if(opts.biff < 8) return parse_BIFF5ExternSheet(blob, length, opts);
7264 return o;
7269 return o.charCodeAt(0) == 0x03 ? o.slice(1) : o;
7274 if(opts.biff < 8) { blob.l += length; return; }
7279 return [name, comment];
7288 return [parse_SharedParsedFormula(blob, length, opts), cUse, ref];
7300 return [ref, parse_ArrayParsedFormula(blob, length, opts, ref)];
7308 return [fMTREnabled, fUserSetThreadCount, cUserThreadCount];
7313 if(opts.biff < 8) return;
7318 return [{r:row,c:col}, stAuthor, idObj, flags];
7324 return parse_NoteSh(blob, length, opts);
7332 return merges;
7338 return o;
7343 if(opts && opts.biff < 8) return parse_BIFF5Obj(blob, length, opts);
7346 return { cmo: cmo, ft:fts };
7362 return { fmt:cf };
7384 return { cmo: [id, ot, grbit], ft:fts };
7423 return { t: texts };
7424 } catch(e) { blob.l = s + length; return { t: texts }; }
7432 return [ref, hlink];
7441 return bconcat([O, write_Hyperlink(hl[1])]);
7451 return [ref, wzTooltip];
7462 return O;
7470 return o;
7476 return o;
7484 return o;
7492 return o;
7501 return o;
7507 if(!opts.cellStyles) return parsenoop(blob, length);
7517 return o;
7531 return o;
7537 if(length < 32) return o;
7542 return o;
7548 if(opts.biff != 5) { blob.l += length; return def; }
7551 return def;
7558 return out;
7572 return o;
7583 return cell;
7592 return cell;
7598 return out;
7607 return cell;
7613 return out;
7618 if(cch === 0) { blob.l++; return ""; }
7619 return blob.read_shift(cch, 'sbcs-cont');
7641 return cell;
7863 return out;
7870 ws["!cols"] = o.DBF.map(function(field) { return {
7875 return ws;
7882 return o;
7884 return ({SheetNames:[],Sheets:{}});
8014 return ba.end();
8016 return {
8046 …var sylk_char_fn = function(_, $1){ var o = sylk_escapes[$1]; return typeof o == "number" ? _getan…
8047 … var newcc = (($1.charCodeAt(0) - 0x20)<<4) | ($2.charCodeAt(0) - 0x30); return newcc == 59 ? $$ :…
8052 case 'base64': return sylk_to_aoa_str(Base64_decode(d), opts);
8053 case 'binary': return sylk_to_aoa_str(d, opts);
8054 …case 'buffer': return sylk_to_aoa_str(has_buf && Buffer.isBuffer(d) ? d.toString('binary') : a2s(d…
8055 case 'array': return sylk_to_aoa_str(cc2str(d), opts);
8070 …var record=rstr.replace(/;;/g, "\u0000").split(";").map(function(x) { return x.replace(/\u0000/g, …
8199 return [arr, sht, wb];
8211 return outwb;
8225 return o;
8276 return preamble.join(RS) + RS + o.join(RS) + RS + "E" + RS;
8279 return {
8288 case 'base64': return dif_to_aoa_str(Base64_decode(d), opts);
8289 case 'binary': return dif_to_aoa_str(d, opts);
8290 …case 'buffer': return dif_to_aoa_str(has_buf && Buffer.isBuffer(d) ? d.toString('binary') : a2s(d)…
8291 case 'array': return dif_to_aoa_str(cc2str(d), opts);
8328 return arr;
8331 …function dif_to_sheet(str/*:string*/, opts)/*:Worksheet*/ { return aoa_to_sheet(dif_to_aoa(str, op…
8335 return o;
8338 …function make_value(v/*:number*/, s/*:string*/)/*:string*/ { return "0," + String(v) + "\r\n" + s;…
8339 …function make_value_str(s/*:string*/)/*:string*/ { return "1,0\r\n\"" + s.replace(/"/g,'""') + '"'…
8384 return o.join("") + "-1,0\r\nEOD";
8386 return {
8394 …function decode(s/*:string*/)/*:string*/ { return s.replace(/\\b/g,"\\").replace(/\\c/g,":").repla…
8395 …function encode(s/*:string*/)/*:string*/ { return s.replace(/\\/g, "\\b").replace(/:/g, "\\c").rep…
8419 return arr;
8422 …function eth_to_sheet(d/*:string*/, opts)/*:Worksheet*/ { return aoa_to_sheet(eth_to_aoa(d, opts),…
8423 …function eth_to_workbook(d/*:string*/, opts)/*:Workbook*/ { return sheet_to_workbook(eth_to_sheet(…
8445 if(!ws || !ws['!ref']) return "";
8478 return o.join("\n");
8482 return [header, sep, meta, sep, sheet_to_eth_data(ws), end].join("\n");
8483 // return ["version:1.5", sheet_to_eth_data(ws)].join("\n"); // clipboard form
8486 return {
8507 if(!f || f.length === 0) return arr;
8527 return arr;
8565 …cc.sort(function(a, b) { return a[0] - b[0] || guess_sep_weights[a[1]] - guess_sep_weights[b[1]]; …
8567 return guess_seps[cc.pop()[1]] || 0x2C;
8625 if(cc == sepcc) ++C; else { C = 0; ++R; if(o.sheetRows && o.sheetRows <= R) return true; }
8639 return ws;
8643 if(!(opts && opts.PRN)) return dsv_to_sheet_str(str, opts);
8644 if(opts.FS) return dsv_to_sheet_str(str, opts);
8645 if(str.slice(0,4) == "sep=") return dsv_to_sheet_str(str, opts);
8646 …if(str.indexOf("\t") >= 0 || str.indexOf(",") >= 0 || str.indexOf(";") >= 0) return dsv_to_sheet_s…
8647 return aoa_to_sheet(prn_to_aoa_str(str, opts), opts);
8667 …if(str.slice(0,19) == "socialcalc:version:") return ETH.to_sheet(opts.type == 'string' ? str : utf…
8668 return prn_to_sheet_str(str, opts);
8671 …function prn_to_workbook(d/*:RawData*/, opts)/*:Workbook*/ { return sheet_to_workbook(prn_to_sheet…
8689 return o.join("\n");
8692 return {
8705 return out;
8709 return PRN.to_workbook(d, opts);
8715 if(!data) return;
8725 if(cb(d, R, RT)) return;
8731 case 'base64': return lotus_to_workbook_buf(s2a(Base64_decode(d)), opts);
8732 case 'binary': return lotus_to_workbook_buf(s2a(d), opts);
8734 case 'array': return lotus_to_workbook_buf(d, opts);
8740 if(!d) return d;
8749 if(d[4] == 0x51 && d[5] == 0x50 && d[6] == 0x57) return qpw_to_workbook_buf(d, opts);
8818 …val[1].v = val[1].v.replace(/\x0F./g, function($$) { return String.fromCharCode($$.charCodeAt(1) -…
8853 if(!realnames.length) return { SheetNames: snames, Sheets: sheets };
8863 return { SheetNames: rnames, Sheets: osheets };
8897 return ba.end();
8939 return ba.end();
8946 return out;
8974 return out;
8986 return o;
8995 return o;
9003 return out;
9020 return o;
9031 return o;
9035 return o;
9049 return o;
9058 return o;
9061 return o;
9067 return o;
9075 return o;
9081 return o;
9089 return o;
9103 return o;
9110 return (rel ? "" : "$") + (col ? encode_col(V) : encode_row(V));
9228 if(blob.l < blob.length) { console.error("WK1 premature formula end"); return; }
9254 …console.error("WK1 bad formula parse 0x" + cc.toString(16) + ":|" + out.join("|") + "|"); return; }
9259 else if(cc <= 0x07) return console.error("WK1 invalid opcode " + cc.toString(16));
9260 else if(cc <= 0x18) return console.error("WK1 unsupported op " + cc.toString(16));
9261 else if(cc <= 0x1E) return console.error("WK1 invalid opcode " + cc.toString(16));
9262 else if(cc <= 0x73) return console.error("WK1 unsupported function opcode " + cc.toString(16));
9264 else return console.error("WK1 unrecognized opcode " + cc.toString(16));
9275 return o;
9282 return o;
9296 return o;
9316 return o;
9328 return o;
9332 return o;
9343 return o;
9360 return o;
9366 return o;
9373 return o;
9380 return o;
9386 return o;
9390 return blob[blob.l + length - 1] == 0 ? blob.read_shift(length, 'cstr') : "";
9397 return o;
9401 if(!opts.qpro || length < 21) return;
9407 return [id, nm];
9421 return o;
9432 return out;
9763 return wb;
9766 return {
9877 return font;
9886 if(!t) return {t:"s", v:""};
9891 return o;
9894 return function parse_rs(rs) {
9895 return rs.replace(rregex,"").split(rend).map(parse_r).filter(function(r) { return r.v; });
9923 return font;
9929 if(!r.v) return "";
9933 return terms[0].join("") + terms[1].replace(nlregex,'<br/>') + terms[2].join("");
9936 return function parse_rs(rs) {
9937 return rs.map(r_to_html).join("");
9947 if(!x) return { t: "" };
9964 return z;
9973 if(!data) return s;
9984 return s;
9989 if(!opts.bookSST) return "";
10011 return o.join("");
10015 return [data.read_shift(4), data.read_shift(4)];
10029 return true;
10041 return s;
10048 return o;
10059 return ba.end();
10062 if(typeof $cptable !== 'undefined') return $cptable.utils.encode(current_ansi, str);
10065 return o;
10073 /*:: if(length == null) return o; */
10075 return o;
10085 return o;
10100 return o;
10109 return o;
10118 return o;
10131 return o;
10142 return hdr;
10166 return o;
10177 return o;
10184 case 0x02: return [vers.Minor, parse_EncInfoStd(blob, vers)];
10185 case 0x03: return [vers.Minor, parse_EncInfoExt(blob, vers)];
10186 case 0x04: return [vers.Minor, parse_EncInfoAgl(blob, vers)];
10199 return { t:"Std", h:hdr, v:verifier };
10225 return o;
10238 return o;
10248 return o;
10267 return Verifier ^ 0xCE4B;
10275 var Ror = function(Byte) { return ((Byte/2) | (Byte*128)) & 0xFF; };
10276 var XorRor = function(byte1, byte2) { return Ror(byte1 ^ byte2); };
10287 return XorKey;
10289 return function(password/*:string*/) {
10324 return ObfuscationArray;
10341 return [O, XorArrayIndex, XorArray];
10346 return function(Data) {
10349 return O[0];
10359 return o;
10367 return o;
10373 return o;
10380 return rtf_to_sheet_str(Base64_decode(d), opts);
10382 return rtf_to_sheet_str(d, opts);
10384 return rtf_to_sheet_str(has_buf && Buffer.isBuffer(d) ? d.toString("binary") : a2s(d), opts);
10386 return rtf_to_sheet_str(cc2str(d), opts);
10442 return ws;
10447 return wb;
10452 return o[0] + "}";
10472 return o.join("") + "}";
10476 return [parseInt(o.slice(0,2),16),parseInt(o.slice(2,4),16),parseInt(o.slice(4,6),16)];
10480 return o.toString(16).toUpperCase().slice(1);
10486 if(C === 0) return [0, 0, R];
10495 return [H6 / 6, S, L2 / 2];
10513 return rgb;
10518 if(tint === 0) return hex;
10522 return rgb2Hex(hsl2RGB(hsl));
10528 function width2px(width) { return Math.floor(( width + (Math.round(128/MDW))/256 )* MDW ); }
10529 function px2char(px) { return (Math.floor((px - 5)/MDW * 100 + 0.5))/100; }
10530 function char2width(chr) { return (Math.round((chr * MDW + 5)/MDW*256))/256; }
10531 //function px2char_(px) { return (((px - 5)/MDW * 100 + 0.5))/100; }
10532 //function char2width_(chr) { return (((chr * MDW + 5)/MDW*256))/256; }
10533 function cycle_width(collw) { return char2width(px2char(width2px(collw))); }
10570 function px2pt(px) { return px * 96 / PPI; }
10571 function pt2px(pt) { return pt * PPI / 96; }
10859 if(!m) return;
10886 if(o.length === 1) return "";
10889 return o.join("");
10957 if(o.length === 2) return "";
10959 return o.join("");
10970 return function parse_sty_xml(data, themes, opts) {
10972 if(!data) return styles;
11000 return styles;
11020 return o.join("");
11026 return [numFmtId, stFmtCode];
11034 return out;
11080 return out;
11101 return o.length > o.l ? o.slice(0, o.l) : o;
11156 return o.length > o.l ? o.slice(0, o.l) : o;
11165 return {ixfe:ixfeParent, numFmtId:ifmt };
11181 return o;
11191 return o;
11203 return o.length > o.l ? o.slice(0, o.l) : o;
11214 return o.length > o.l ? o.slice(0, o.l) : o;
11223 return o.length > o.l ? o.slice(0, o.l) : o;
11286 return styles;
11290 if(!NF) return;
11293 /*:: if(!NF) return; */
11297 if(cnt == 0) return;
11300 /*:: if(!NF) return; */
11309 if(cnt == 0) return;
11325 if(cnt == 0) return;
11336 if(cnt == 0) return;
11393 return;
11413 return ba.end();
11520 return themes;
11524 if(opts && opts.themeXLSX) return opts.themeXLSX;
11525 if(Themes && typeof Themes.raw == "string") return Themes.raw;
11692 return o.join("");
11698 if(dwThemeVersion === 124226) return;
11699 if(!opts.cellStyles) { blob.l = end; return; }
11702 var zip; try { zip = zip_read(data, {type: "array"}); } catch(e) { return; }
11704 if(!themeXML) return;
11705 return parse_theme_xml(themeXML, opts);
11709 function parse_ColorTheme(blob/*::, length*/) { return blob.read_shift(4); }
11724 return o;
11729 return parsenoop(blob, length);
11734 return parsenoop(blob, length);
11750 return o;
11762 return {ixfe:ixfe, ext:ext};
11786 return {
11797 return o.slice(0, o.l);
11804 return out;
11813 return o;
11819 return o.slice(0, o.l);
11823 return data.read_shift(4) != 0;
11829 return o;
11870 return out;
11894 return ba.end();
11899 return out;
11972 return x;
11974 return out;
11979 return o.join("");
11984 if(!data) return d;
11996 return d;
12012 return out;
12029 return out;
12041 if(!data) return data;
12047 if(end) return;
12086 if(!data) return "??";
12100 return rels['!id'][id].Target;
12123 return o.join("");
12135 return [
12188 if(!threaded && cell.c[i].T) return;
12201 if(data.match(/<(?:\w+:)?comments *\/>/)) return [];
12206 if(x === "" || x.trim() === "") return;
12212 if(x === "" || x.trim() === "") return;
12214 if(!cm) return;
12218 if(opts.sheetRows && opts.sheetRows <= cell.r) return;
12227 return commentList;
12274 return o.join("");
12311 return x;
12313 return out;
12321 if(!c.T) { delete c.ID; return; }
12335 return o.join("");
12363 return x;
12365 return out;
12381 return o.join("");
12391 return out;
12401 return o;
12406 function write_BrtCommentAuthor(data) { return write_XLWideString(data.slice(0, 54)); }
12445 return out;
12456 if(iauthor.indexOf(c.a) > -1) return;
12477 return ba.end();
12484 return;
12488 return CFB.write(newcfb);
12493 return;
12501 …:data:any, opts, idx:number, rels, wb, themes, styles*/)/*:Worksheet*/ { return {'!type':'dialog'}…
12502 …:data:any, opts, idx:number, rels, wb, themes, styles*/)/*:Worksheet*/ { return {'!type':'dialog'}…
12503 …:data:any, opts, idx:number, rels, wb, themes, styles*/)/*:Worksheet*/ { return {'!type':'macro'};…
12504 …:data:any, opts, idx:number, rels, wb, themes, styles*/)/*:Worksheet*/ { return {'!type':'macro'};…
12522 return $1 + (cRel ? "" : "$") + encode_col(C) + (rRel ? "" : "$") + encode_row(R);
12524 return function rc_to_a1(fstr/*:string*/, base/*:Cell*/)/*:string*/ {
12526 return fstr.replace(rcregex, rcfunc);
12532 return function a1_to_rc(fstr/*:string*/, base/*:CellAddress*/) {
12533 return fstr.replace(crefregex, function($0, $1, $2, $3, $4, $5) {
12538 return $1 + "R" + R + "C" + C;
12545 return f.replace(crefregex, function($0, $1, $2, $3, $4, $5) {
12546return $1+($2=="$" ? $2+$3 : encode_col(decode_col($3)+delta.c))+($4=="$" ? $4+$5 : encode_row(dec…
12553 return shift_formula_str(f, delta);
12558 if(f.length == 1) return false;
12559 return true;
12563 return f.replace(/_xlfn\./g,"");
12565 function parseread1(blob) { blob.l+=1; return; }
12570 return [c & 0x3FFF, (c >> 14) & 1, (c >> 15) & 1];
12577 if(opts.biff >= 2 && opts.biff <= 5) return parse_RgceArea_BIFF2(blob, length, opts);
12583 return { s:{r:r, c:c[0], cRel:c[1], rRel:c[2]}, e:{r:R, c:C[0], cRel:C[1], rRel:C[2]} };
12590 return { s:{r:r[0], c:c, cRel:r[1], rRel:r[2]}, e:{r:R[0], c:C, cRel:R[1], rRel:R[2]} };
12595 if(opts.biff < 8) return parse_RgceArea_BIFF2(blob, length, opts);
12599 return { s:{r:r, c:c[0], cRel:c[1], rRel:c[2]}, e:{r:R, c:C[0], cRel:C[1], rRel:C[2]} };
12604 if(opts && opts.biff >= 2 && opts.biff <= 5) return parse_RgceLoc_BIFF2(blob, length, opts);
12607 return {r:r, c:c[0], cRel:c[1], rRel:c[2]};
12612 return {r:r[0], c:c, cRel:r[1], rRel:r[2]};
12619 return {r:r, c:c & 0xFF, fQuoted:!!(c & 0x4000), cRel:c>>15, rRel:c>>15 };
12625 if(biff >= 2 && biff <= 5) return parse_RgceLocRel_BIFF2(blob, length, opts);
12632 return {r:r,c:cl,cRel:cRel,rRel:rRel};
12641 return {r:rl,c:c,cRel:cRel,rRel:rRel};
12648 return [type, area];
12661 return [type, ixti, area];
12668 return [type];
12680 return [type, ixti];
12687 return [type, area];
12694 return [type];
12702 return [bitSemi, bitBaxcel];
12712 return o;
12719 return [bitGoto, blob.read_shift(opts && opts.biff == 2 ? 1 : 2)];
12726 return [bitIf, blob.read_shift(opts && opts.biff == 2 ? 1 : 2)];
12733 return [bitIf, blob.read_shift(2)];
12740 return [bitSemi];
12746 return [type, cch];
12752 return parse_PtgAttrSpaceType(blob, 2);
12758 return parse_PtgAttrSpaceType(blob, 2);
12767 return [type, loc];
12775 return [type, loc];
12785 return [type, ixti, loc];
12795 return [FtabArgc[iftab], Ftab[iftab], type];
12801 return [cparams, (tab[0] === 0 ? Ftab : Cetab)[tab[1]]];
12805 return [blob[blob.l+1]>>7, blob.read_shift(2) & 0x7FFF];
12810 blob.l += opts && opts.biff == 2 ? 3 : 4; return;
12816 if(opts && opts.biff == 12) return [blob.read_shift(4, 'i'), 0];
12819 return [row, col];
12823 function parse_PtgErr(blob) { blob.l++; return BErr[blob.read_shift(1)]; }
12826 function parse_PtgInt(blob) { blob.l++; return blob.read_shift(2); }
12829 function parse_PtgBool(blob) { blob.l++; return blob.read_shift(1)!==0;}
12832 function parse_PtgNum(blob) { blob.l++; return parse_Xnum(blob, 8); }
12835 function parse_PtgStr(blob, length, opts) { blob.l++; return parse_ShortXLUnicodeString(blob, lengt…
12863 return val;
12871 return out;
12888 return o;
12901 return [type, 0, nameindex];
12906 if(opts.biff == 5) return parse_PtgNameX_BIFF5(blob, length, opts);
12910 return [type, ixti, nameindex];
12918 return [type, ixti, nameindex];
12926 return [type, cce];
12933 return [type, cce];
12943 return [type];
12956 return [type, ixti];
12968 return [parse_RgceElfLoc(blob, 4, opts)];
12972 return [];
12985 return [parseuint16(blob), blob.read_shift(2) & 0x01];
13026 return {ixti: ixti, coltype:(flags&0x3), rt:rt, idx:idx, c:c, C:C};
13031 return [blob.read_shift(4)];
13039 return ["PTGSHEET"];
13043 return ["PTGENDSHEET"];
13048 return [type, cce];
13053 return [type, cce];
13057 return [0, 0];
13172 if(opts.biff < 8) return parsenoop(blob, length);
13202 return o;
13217 return ptgs;
13236 return o.join(";");
13258 if(s == -1 && e == -1) return start + ":" + end;
13259 …if(s > 0 && e > 0 && start.slice(0, s).toLowerCase() == end.slice(0, e).toLowerCase()) return star…
13261 return start + ":" + end;
13265 if(!supbooks) return "SH33TJSERR0";
13266 if(opts.biff > 8 && (!supbooks.XTI || !supbooks.XTI[ixti])) return supbooks.SheetNames[ixti];
13267 if(!supbooks.XTI) return "SH33TJSERR6";
13272 return ixti == 0 ? "" : supbooks.XTI[ixti - 1];
13274 if(!XTI) return "SH33TJSERR1";
13279 return XTI[1] == XTI[2] ? o : o + ":" + supbooks.SheetNames[XTI[2]];
13281 if(opts.SID != null) return supbooks.SheetNames[opts.SID];
13282 return "SH33TJSSAME" + supbooks[XTI[0]][0];
13285 default: return "SH33TJSSRC" + supbooks[XTI[0]][0];
13290 return XTI[1] == XTI[2] ? o : o + ":" + supbooks.SheetNames[XTI[2]];
13291 …case 0x3A01: return supbooks[XTI[0]].slice(1).map(function(name) { return name.Name; }).join(";;")…
13293 if(!supbooks[XTI[0]][0][3]) return "SH33TJSERR2";
13295 return XTI[1] == XTI[2] ? o : o + ":" + supbooks[XTI[0]][0][3][XTI[2]];
13300 return ixtiraw == "#REF" ? ixtiraw : formula_quote_sheet_name(ixtiraw, opts);
13306 if(!formula[0] || !formula[0][0]) return "";
13608 if(stack[0] == "TRUE") return true; if(stack[0] == "FALSE") return false;
13609 return stack[0];
13616 if(cce == 0xFFFF) return [[],parsenoop(blob, length-2)];
13620 return [rgce, rgcb];
13627 if(cce == 0xFFFF) return [[],parsenoop(blob, length-2)];
13631 return [rgce, rgcb];
13640 return [rgce, rgcb];
13648 if(cce == 0xFFFF) return [[],parsenoop(blob, length-2)];
13650 return [rgce, rgcb];
13656 if(__readUInt16LE(blob,blob.l + 6) !== 0xFFFF) return [parse_Xnum(blob),'n'];
13658 case 0x00: blob.l += 8; return ["String", 's'];
13659 case 0x01: b = blob[blob.l+2] === 0x1; blob.l += 8; return [b,'b'];
13660 case 0x02: b = blob[blob.l+2]; blob.l += 8; return [b,'e'];
13661 case 0x03: blob.l += 8; return ["",'s'];
13663 return [];
13674 return o;
13675 } else if(typeof value == "number") return write_Xnum(value);
13676 return write_Xnum(0);
13693 return {cell:cell, val:val[0], formula:cbf, shared: (flags >> 3) & 1, tt:val[1]};
13713 return out;
13723 return [rgce, rgcb];
13747 return oint;
13755 return num;
13764 return oint;
13773 return oint;
13789 return bconcat([preamble, body, postamble]);
13802 return out;
13816 …out.write_shift(2, 2 + wb.SheetNames.map(function(n) { return n.toLowerCase(); }).indexOf(sname.to…
13821 return out;
13834 …out.write_shift(2, 2 + wb.SheetNames.map(function(n) { return n.toLowerCase(); }).indexOf(sname.to…
13839 return out;
13868 return out;
13885 …out.write_shift(2, 2 + wb.SheetNames.map(function(n) { return n.toLowerCase(); }).indexOf(sname.to…
13892 …out.write_shift(2, 2 + wb.SheetNames.map(function(n) { return n.toLowerCase(); }).indexOf(sname.to…
13901 return out;
13916 …out.write_shift(2, 2 + wb.SheetNames.map(function(n) { return n.toLowerCase(); }).indexOf(sname.to…
13924 return out;
13930 if(typeof val == "number") return write_XLSBFormulaNum(val);
13931 if(typeof val == "boolean") return write_XLSBFormulaBool(val);
13932 …if(/^#(DIV\/0!|GETTING_DATA|N\/A|NAME\?|NULL!|NUM!|REF!|VALUE!)$/.test(val)) return write_XLSBForm…
13933 …|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})$/)) return write_XLSBFormulaR…
13934 …|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})$/)) return write_XLSBFormulaR…
13935 …|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})$/)) return write_XLSBFormulaA…
13936 …|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})$/)) return write_XLSBFormulaR…
13937 …|104[0-7]\d{3}|1048[0-4]\d{2}|10485[0-6]\d|104857[0-6]|[1-9]\d{0,5})$/)) return write_XLSBFormulaR…
13938 …if(/^(?:'[^\\\/?*\[\]:]*'|[^'][^\\\/?*\[\]:'`~!@#$%^()\-=+{}|;,<.>]*)!#REF!$/.test(val)) return wr…
13939 if(/^".*"$/.test(val)) return write_XLSBFormulaStr(val);
13940 if(/^[+-]\d+$/.test(val)) return write_XLSBFormulaNum(parseInt(val, 10));
15087 …f = f.replace(/\[((?:\.[A-Z]+[0-9]+)(?::\.[A-Z]+[0-9]+)?)\]/g, function($$, $1) { return $1.replac…
15088 f = f.replace(/\$'([^']|'')+'/g, function($$) { return $$.slice(1); });
15089 …f = f.replace(/\$([^\]\. #$]+)/g, function($$, $1) { return ($1).match(/^([A-Z]{1,2}|[A-W][A-Z]{2}…
15092 return f.replace(/[;~]/g,",").replace(/\|/g,";");
15098 return o.replace(/;/g, "|").replace(/,/g,";");
15102 r = r.replace(/\$'([^']|'')+'/g, function($$) { return $$.slice(1); });
15103 …r = r.replace(/\$([^\]\. #$]+)/g, function($$, $1) { return ($1).match(/^([A-Z]{1,2}|[A-W][A-Z]{2}…
15106return [s, a[0].split(".")[1] + (a.length > 1 ? (":" + (a[1].split(".")[1] || a[1].split(".")[0]))…
15110 return r.replace(/!/,".");
15126 if(sst[revarr[i]].t === str) { sst.Count ++; return revarr[i]; }
15130 if(sst[i].t === str) { sst.Count ++; return i; }
15142 return len;
15157 return p;
15161 if(!margins) return;
15184 for(i = 0; i != len; ++i) if(styles[i].numFmtId === z) return i;
15193 return len;
15200 if(p.t === 'z' && !opts.cellStyles) return;
15215 else if(p.v === undefined) return "";
15221 if(!opts.cellStyles) return;
15258 if(!data) return data;
15333 return s;
15337 if(merges.length === 0) return "";
15340 return o + '</mergeCells>';
15369 if(!needed && !payload) return;
15388 return writextag('sheetProtection', null, o);
15395 if(!val.ref) return;
15426 return o;
15430 return writextag('pageMargins', null, margin);
15453 return o.join("");
15458 return o;
15474 return writextag("autoFilter", null, {ref:ref});
15496 return writextag("sheetViews", writextag("sheetView", null, sview), {});
15501 …& !(opts||{}).sheetStubs) && typeof cell.f !== "string" && typeof cell.z == "undefined") return "";
15547 return writextag('c', v, o);
15556 return function parse_ws_xml_data(sdata/*:string*/, s, opts, guess/*:Range*/, themes, styles) {
15778 return o.join("");
15847 if(!l[1].Target) return;
15898 return o.join("");
15914 return z;
15962 return o.length > o.l ? o.slice(0, o.l) : o;
15987 return z;
16002 return o.slice(0, o.l);
16008 return [cell];
16012 return write_XLSBCell(ncell, o);
16016 return [cell];
16020 return write_XLSBShortCell(ncell, o);
16027 return [cell, fBool, 'b'];
16033 return o;
16038 return [cell, fBool, 'b'];
16044 return o;
16051 return [cell, bError, 'e'];
16057 return o;
16062 return [cell, bError, 'e'];
16070 return o;
16078 return [cell, isst, 's'];
16084 return o;
16089 return [cell, isst, 's'];
16095 return o;
16102 return [cell, value, 'n'];
16108 return o;
16113 return [cell, value, 'n'];
16119 return o;
16126 return [cell, value, 'n'];
16132 return o;
16137 return [cell, value, 'n'];
16143 return o;
16150 return [cell, value, 'is'];
16157 return [cell, value, 'str'];
16164 return o.length > o.l ? o.slice(0, o.l) : o;
16169 return [cell, value, 'str'];
16176 return o.length > o.l ? o.slice(0, o.l) : o;
16192 return o;
16208 return o;
16224 return o;
16240 return o;
16250 return o;
16264 return o;
16275 return o.slice(0, o.l);
16292 return o;
16305 return o;
16322 return o;
16330 return margins;
16336 return o;
16343 return { RTL: f & 0x20 };
16361 return o;
16370 return o;
16399 return o;
16408 if(!data) return data;
16431 supbooks.SheetNames = wb.SheetNames || wb.Sheets.map(function(x) { return x.name; });
16445 if(end) return;
16702 return s;
16709 if(cell.v === undefined) return false;
16737 return true;
16746 } return true;
16751 return true;
16756 return true;
16760 return true;
16789 if(!ws || !ws['!merges']) return;
16796 if(!ws || !ws['!cols']) return;
16803 if(!ws || !ws['!ref']) return;
16812 if(!l[1].Target) return;
16828 if(!ws['!autofilter']) return;
16874 if(!ws['!protect']) return;
16932 return ba.end();
16942 if(!q) return;
16951 return [col, nf, f];
16957 if(!data) return csheet;
16977 return cs;
16981 if(!data) return data;
16995 return s;
17005 // return o.join("");
17012 return { name: name };
17017 if(!data) return data;
17060 return s;
17079 // return ba.end();
17191 if(!wb.Workbook) return "false";
17192 if(!wb.Workbook.WBProps) return "false";
17193 return parsexmlbool(wb.Workbook.WBProps.date1904) ? "true" : "false";
17198 if(n.length > 31) { if(safe) return false; throw new Error("Sheet names cannot exceed 31 chars"); }
17201 if(n.indexOf(c) == -1) return;
17205 return _good;
17225 if(!ws || !ws["!autofilter"]) return;
17268 if(y[w[0]] == null) return;
17387 return x;
17393 return wb;
17414 if((wb.Workbook.WBProps[x[0]]/*:any*/) == null) return;
17415 if((wb.Workbook.WBProps[x[0]]/*:any*/) == x[1]) return;
17463 if(!n.Ref) return;
17481 return o.join("");
17490 return z;
17498 return o.length > o.l ? o.slice(0, o.l) : o;
17523 return o;
17536 return o.slice(0, o.l);
17544 return o;
17567 return out;
17596 return bconcat(arr);
17707 return wb;
17728 return o.length > o.l ? o.slice(0, o.l) : o;
17743 return o.length > o.l ? o.slice(0, o.l) : o;
17748 if(!wb.Workbook || !wb.Workbook.Sheets) return;
17755 if(hidden > vistab) return;
17763 if(!wb.Workbook || !wb.Workbook.Names) return;
17765 if(name.Flags & 0x0e) return; // TODO: macro name write
17781 return o;
17800 return o;
17807 return o;
17837 return ba.end();
17840 if(name.slice(-4)===".bin") return parse_wb_bin((data/*:any*/), opts);
17841 return parse_wb_xml((data/*:any*/), opts);
17845 …if(name.slice(-4)===".bin") return parse_ws_bin((data/*:any*/), opts, idx, rels, wb, themes, style…
17846 return parse_ws_xml((data/*:any*/), opts, idx, rels, wb, themes, styles);
17850 …if(name.slice(-4)===".bin") return parse_cs_bin((data/*:any*/), opts, idx, rels, wb, themes, style…
17851 return parse_cs_xml((data/*:any*/), opts, idx, rels, wb, themes, styles);
17855 …if(name.slice(-4)===".bin") return parse_ms_bin((data/*:any*/), opts, idx, rels, wb, themes, style…
17856 return parse_ms_xml((data/*:any*/), opts, idx, rels, wb, themes, styles);
17860 …if(name.slice(-4)===".bin") return parse_ds_bin((data/*:any*/), opts, idx, rels, wb, themes, style…
17861 return parse_ds_xml((data/*:any*/), opts, idx, rels, wb, themes, styles);
17865 if(name.slice(-4)===".bin") return parse_sty_bin((data/*:any*/), themes, opts);
17866 return parse_sty_xml((data/*:any*/), themes, opts);
17870 if(name.slice(-4)===".bin") return parse_sst_bin((data/*:any*/), opts);
17871 return parse_sst_xml((data/*:any*/), opts);
17875 if(name.slice(-4)===".bin") return parse_comments_bin((data/*:any*/), opts);
17876 return parse_comments_xml((data/*:any*/), opts);
17880 if(name.slice(-4)===".bin") return parse_cc_bin((data/*:any*/), name, opts);
17881 return parse_cc_xml((data/*:any*/), name, opts);
17885 if(name.slice(-4)===".bin") return parse_xlink_bin((data/*:any*/), rel, name, opts);
17886 return parse_xlink_xml((data/*:any*/), rel, name, opts);
17890 if(name.slice(-4)===".bin") return parse_xlmeta_bin((data/*:any*/), name, opts);
17891 return parse_xlmeta_xml((data/*:any*/), name, opts);
17898 if(words.length === 1) return z;
17910 return z;
17915 if(words.length === 1) return z;
17927 return z;
17937 if(fmt === "General") return SSF_general(value);
17938 return SSF_format(fmt, value);
17955 if(cell.t === 'z') return;
18055 return XLSLblBuiltIn.indexOf("_xlnm." + dname) > -1 ? "_xlnm." + dname : dname;
18075 … (opening.indexOf(";")&1023))) { var _o = dup(opts); _o.type = "string"; return PRN.to_workbook(st…
18077 if(ishtml) return html_to_workbook(str, opts);
18389 if(state.length == 0 && Rn[3] == "document") return parse_fods(str, opts);
18391 if(state.length == 0 && Rn[3] == "uof"/*"UOF"*/) return parse_fods(str, opts);
18815 return out;
18821 case "base64": return parse_xlml_xml(Base64_decode(data), opts);
18822 case "binary": case "buffer": case "file": return parse_xlml_xml(data, opts);
18823 case "array": return parse_xlml_xml(a2s(data), opts);
18835 return o.join("");
18841 …if((((wb||{}).Workbook||{}).WBProps||{}).date1904) return '<ExcelWorkbook xmlns="urn:schemas-micro…
18842 return "";
18855 return writextag("Styles", styles.join(""));
18857 function write_name_xlml(n) { return writextag("NamedRange", null, {"ss:Name": n.Name.slice(0,6) ==…
18859 if(!((wb||{}).Workbook||{}).Names) return "";
18869 return writextag("Names", out.join(""));
18872 if(!ws) return "";
18873 if(!((wb||{}).Workbook||{}).Names) return "";
18886 return out.join("");
18890 if(!ws) return "";
18993 if(o.length == 0) return "";
18994 return writextag("WorksheetOptions", o.join(""), {xmlns:XLMLNS.x});
18997 return comments.map(function(c) {
19001 return writextag("Comment", d, {"ss:Author":c.a});
19005 if(!cell || (cell.v == undefined && cell.f == undefined)) return "";
19030 case 'z': if(!opts.sheetStubs) return ""; break;
19046 return writextag("Cell", m, attr);
19055 return o + '>';
19059 if(!ws['!ref']) return "";
19093 return o.join("");
19112 return o.join("");
19134 return XML_HEADER + writextag("Workbook", d.join(""), {
19147 /*:: if(o == null) return; */
19155 if(o.length - o.l <= 4) return v;
19158 if(m == 0 || m > 40) return v;
19161 if(o.length - o.l <= 4) return v;
19163 if(m !== 0x71b239f4) return v;
19167 if(m == 0 || m > 40) return v;
19213 return R.f(b, b.length, opts);
19217 if(p.t === 'z') return;
19218 if(!p.XF) return;
19241 return ({v:val, ixfe:ixfe, t:t}/*:any*/);
19265 if(icv < 8) return XLSIcv[icv];
19266 if(icv < 64) return palette[icv-8] || XLSIcv[icv];
19267 return XLSIcv[icv];
19271 if(!xfd || !xfd.patternType || !options || !options.cellStyles) return;
19279 if(file_depth > 1) return;
19280 if(options.sheetRows && cell.r >= options.sheetRows) return;
19732 ….SheetNames=keys(Directory).sort(function(a,b) { return Number(a) - Number(b); }).map(function(x){
19749 return wb;
19847 return WorkbookP;
19868 return cfb;
21206 if(isNaN(t)) return;
21216 if(len <= 8224) return write_biff_rec(ba, type, payload, len);
21218 if(isNaN(t)) return;
21243 return out;
21250 return out;
21259 return out.l < out.length ? out.slice(0, out.l) : out;
21270 return;
21271 case 'b': case 'e': write_biff_rec(ba, 0x0005, write_BIFF2BERR(R, C, cell.v, cell.t)); return;
21275 return;
21315 return ba.end();
21330 if(!NF) return;
21332 /*:: if(!NF) return; */
21370 if(!cols) return;
21383 return;
21477 return ba.end();
21560 return bconcat(out);
21588 return bconcat(bufs);
21603 case 8: case 5: return write_biff8_buf(wb, opts);
21604 case 4: case 3: case 2: return write_biff2_buf(wb, opts);
21665 return ws;
21698 return preamble + oo.join("") + "</tr>";
21710 return w;
21715 return wb;
21720 return out.join("") + '<table' + (o && o.id ? ' id="' + o.id + '"' : "") + '>';
21733 return out.join("");
21820 return ws;
21826 return sheet_add_dom(ws, table, _opts);
21832 return o;
21840 return display === 'none';
21846 …ypeof element.ownerDocument.defaultView.getComputedStyle === 'function') return element.ownerDocum…
21848 if(typeof getComputedStyle === 'function') return getComputedStyle;
21849 return null;
21857 ….replace(/<text:s text:c="(\d+)"\/>/g, function($$,$1) { return Array(parseInt($1,10)+1).join(" ")…
21862 return [v];
22085 return number_format_map;
22611 return out;
22624 return wb;
22629 return wb;
22660 return function wso(/*::wb, opts*/) {
22661 return XML_HEADER + payload;
22811 if(!payload) { console.error("Could not generate ODS number format for |" + nf + "|"); return ""; }
22812 return writextag("number:" + type + "-style", payload, nopts);
22816 var scoped = Names.filter(function(name) { return name.Sheet == (idx == -1 ? null : idx); });
22817 if(!scoped.length) return "";
22818 return " <table:named-expressions>\n" + scoped.map(function(name) {
22820 return " " + writextag("table:named-range", null, {
22830 return escapexml(text)
22831 .replace(/ +/g, function($$){return '<text:s text:c="'+$$.length+'"/>';})
22922 return o.join("");
22930 wb.SheetNames.map(function(n) { return wb.Sheets[n]; }).forEach(function(ws) {
22931 if(!ws) return;
22949 wb.SheetNames.map(function(n) { return wb.Sheets[n]; }).forEach(function(ws) {
22950 if(!ws) return;
22979 wb.SheetNames.map(function(n) { return wb.Sheets[n]; }).forEach(function(ws) {
22980 if(!ws) return;
22999 return nfs;
23002 return function wcx(wb, opts) {
23066 return o.join("");
23071 if(opts.bookType == "fods") return write_content_ods(wb, opts);
23110 return zip;
23117 return "slice";
23119 return "slice";
23122 return "slice";
23124 return "subarray";
23125 return "slice";
23127 return "subarray";
23129 return "slice";
23133 return new DataView(array.buffer, array.byteOffset, array.byteLength);
23136 return typeof TextDecoder != "undefined" ? new TextDecoder().decode(u8) : utf8read(a2s(u8));
23139 return typeof TextEncoder != "undefined" ? new TextEncoder().encode(str) : s2a(utf8write(str));
23144 return false;
23150 return true;
23152 return false;
23156 return acc + x.length;
23164 return out;
23169 return (x + (x >> 4) & 252645135) * 16843009 >>> 24;
23176 return (buf[offset + 15] & 128 ? -mantissa : mantissa) * Math.pow(10, exp - 6176);
23216 return usz;
23253 return usz[subarray](0, L);
23260 return out;
23263 return u8concat(nums.map(function(x) {
23264 return write_varint49(x);
23282 return i32;
23315 return [lo >>> 0, hi >>> 0];
23363 return out;
23369 return;
23372 return;
23379 return u8concat(out);
23382 return (data == null ? void 0 : data.map(function(d) {
23383 return cb(d.data);
23410 return out;
23432 return bufs.push(mid);
23435 return u8concat(bufs);
23515 return acc + u8.length;
23518 return acc + u8.length;
23520 return chunks;
23536 return u8concat(out);
23572 return u8concat(out);
23575 return { sst: [], rsst: [], ofmt: [], nfmt: [] };
23730 return void 0;
23764 return ret;
23796 return void 0;
23834 return ret;
23866 return out[subarray](0, l);
23898 return out[subarray](0, l);
23907 return parse_old_storage(buf, lut, buf[0]);
23909 return parse_new_storage(buf, lut);
23916 return parse_varint49(pb[1][0].data);
23919 return write_shallow([
23937 return r != ref;
23948 return;
23964 return u8str(x.data);
23975 return data;
24007 return { R: R, cells: cells };
24020 return parse_TST_TileRowInfo(u8, storage);
24022 return {
24032 return acc;
24092 return {
24115 return out;
24132 return out;
24155 return out;
24166 return;
24168 return;
24173 return console.log("?? " + s.content.length + " " + (e.message || e));
24179 return console.log("## " + (e.message || e));
24205 return parse_TN_DocumentArchive(M, docroot, opts);
24215 return 255;
24220 return 255;
24287 return tri;
24290 return {
24304 return i;
24312 return [fi, cfb.FullPaths[idx]];
24316 return;
24318 return;
24320 return;
24327 return x - y;
24330 return x > 1;
24332 return [x, write_varint49(x)];
24336 return;
24338 return;
24342 return varint_to_i32(mess.meta[1][0].data) != 11006 && u8contains(mess.data, ivi[1]);
24349 return dependents;
24370 return cfb;
24378 return packet.id == id;
24390 return packet.id == id;
24392 return ainfo;
24410 return x.push(sheet);
24421 return numbers_del_oref(sheetroot, n);
24441 return u8str(mm[3][0].data) == loc2;
24443 return true;
24444 return false;
24460 return x.push(tia);
24486 return x.push(tma);
24499 return delete tma[n];
24512 return hsa[n][0];
24516 return;
24549 return;
24559 return;
24599 return u8str(mm[3][0].data) == loc;
24601 return true;
24602 return false;
24662 return u8str(mm[3][0].data) == loc;
24664 return true;
24665 return false;
24722 return u8str(mm[3][0].data) == loc;
24724 return true;
24725 return false;
24764 return write_numbers_tma(cfb, deps, ws, docroot, x, tmaref);
24829 return parse_varint49(parse_shallow(m.data)[1][0].data) == tileref;
24831return (mlst == null ? void 0 : mlst.length) ? parse_varint49(parse_shallow(mlst[0].data)[12][0].d…
24838 return parse_varint49(parse_shallow(m.data)[1][0].data) != tileref;
24844 return u8str(mm[3][0].data) == loc;
24846 return true;
24847 return false;
24853 return parse_varint49(parse_shallow(m.data)[1][0].data) != tileref;
24918 return u8str(mm[3][0].data) == loc;
24920 return true;
24921 return false;
24958 return { type: 2, data: write_shallow([
24979 return u8str(mm[3][0].data) == loc;
24981 return true;
24982 return false;
25007 return;
25024 return function fix_opts(opts) {
25070 if(RELS.WS.indexOf(n) > -1) return "sheet";
25071 if(RELS.CS && n == RELS.CS) return "chart";
25072 if(RELS.DS && n == RELS.DS) return "dialog";
25073 if(RELS.MS && n == RELS.MS) return "macro";
25074 return (n && n.length) ? n : "sheet";
25077 if(!wbrels) return 0;
25079 …wbrels = sheets.map(function pwbr(w) { if(!w.id) w.id = w.strRelID; return [w.name, wbrels['!id'][…
25080 } catch(e) { return null; }
25081 return !wbrels || wbrels.length === 0 ? null : wbrels;
25113 if(!comments || !comments.length) return;
25125 function strip_front_slash(x/*:string*/)/*:string*/ { return x.charAt(0) == '/' ? x.slice(1) : x; }
25133 if(safegetzipfile(zip, 'META-INF/manifest.xml')) return parse_ods(zip, opts);
25135 if(safegetzipfile(zip, 'objectdata.xml')) return parse_ods(zip, opts);
25140 if(zip.FileIndex) return parse_numbers_iwa(zip, opts);
25143 return parse_numbers_iwa(_zip, opts);
25156 …if(typeof Bun !== "undefined" && Buffer.isBuffer(index_zip.content)) return readSync(new Uint8Arra…
25157 return readSync(index_zip.content, opts);
25192 return parse_xlink(getzipdata(zip, strip_front_slash(link)), rels, link, opts);
25219 if(wb.Sheets) sheets = wb.Sheets.map(function pluck(x){ return x.name; });
25223 if(opts.bookSheets ? out.SheetNames : opts.bookProps) return out;
25322 return out;
25364 …if(einfo[0] == 0x04 && typeof decrypt_agile !== 'undefined') return decrypt_agile(einfo[1], data.c…
25367 …if(einfo[0] == 0x02 && typeof decrypt_std76 !== 'undefined') return decrypt_std76(einfo[1], data.c…
25503 return zip;
25658 return zip;
25664 case 'buffer': return [f[0], f[1], f[2], f[3], f[4], f[5], f[6], f[7]];
25667 case 'array': return [f[0], f[1], f[2], f[3], f[4], f[5], f[6], f[7]];
25670return [x.charCodeAt(0), x.charCodeAt(1), x.charCodeAt(2), x.charCodeAt(3), x.charCodeAt(4), x.cha…
25674 if(CFB.find(cfb, "EncryptedPackage")) return parse_xlsxcfb(cfb, opts);
25675 return parse_xlscfb(cfb, opts);
25683 return parse_zip(zip, o);
25690 case 0x3C: return parse_xlml(data.slice(i),o);
25693 return PRN.to_workbook(data, o);
25707 return read_plaintext(str, o);
25715 return read_plaintext(d, o);
25719 return !data.match(/[^\x00-\x7F]/) ? data : utf8write(data);
25723 if(str) { o.type = "string"; return PRN.to_workbook(data, o); }
25724 return PRN.to_workbook(d, o);
25731 …if(typeof ArrayBuffer !== 'undefined' && data instanceof ArrayBuffer) return readSync(new Uint8Arr…
25744 if(!vu.foo) {o=dup(o); o.type='array'; return readSync(ab2a(d), o);}
25747 …xE0 && n[4] === 0xA1 && n[5] === 0xB1 && n[6] === 0x1A && n[7] === 0xE1) return read_cfb(CFB.read(…
25748 case 0x09: if(n[1] <= 0x08) return parse_xlscfb(d, o); break;
25749 case 0x3C: return parse_xlml(d, o);
25752 if(n[1] === 0x44) return read_wb_ID(d, o);
25754 …case 0x54: if(n[1] === 0x41 && n[2] === 0x42 && n[3] === 0x4C) return DIF.to_workbook(d, o); break;
25755 …case 0x50: return (n[1] === 0x4B && n[2] < 0x09 && n[3] < 0x09) ? read_zip(d, o) : read_prn(data, …
25756 case 0xEF: return n[3] === 0x3C ? parse_xlml(d, o) : read_prn(data, d, o, str);
25758 if(n[1] === 0xFE) { return read_utf16(d, o); }
25759 else if(n[1] === 0x00 && n[2] === 0x02 && n[3] === 0x00) return WK_.to_workbook(d, o);
25763 if(n[2] >= 0x02 && n[3] === 0x00) return WK_.to_workbook(d, o);
25764 if(n[2] === 0x00 && (n[3] === 0x08 || n[3] === 0x09)) return WK_.to_workbook(d, o);
25767 case 0x03: case 0x83: case 0x8B: case 0x8C: return DBF.to_workbook(d, o);
25768 …case 0x7B: if(n[1] === 0x5C && n[2] === 0x72 && n[3] === 0x74) return rtf_to_workbook(d, o); break;
25769 case 0x0A: case 0x0D: case 0x20: return read_plaintext_raw(d, o);
25777 …if(DBF_SUPPORTED_VERSIONS.indexOf(n[0]) > -1 && n[2] <= 12 && n[3] <= 31) return DBF.to_workbook(d…
25778 return read_prn(data, d, o, str);
25783 return readSync(filename, o);
25789 case "file": return write_dl(o.file, CFB.write(cfb, {type:has_buf ? 'buffer' : ""}));
25793 return CFB.write(cfb, o);
25798 case "ods": return write_ods(wb, opts);
25799 case "numbers": return write_numbers_iwa(wb, opts);
25800 case "xlsb": return write_zip_xlsb(wb, opts);
25801 default: return write_zip_xlsx(wb, opts);
25809 return write_zip_denouement(z, o);
25814 return write_zip_denouement(z, o);
25832 if(o.type == "binary" || o.type == "base64") return out;
25837 …if(o.password && typeof encrypt_agile !== 'undefined') return write_cfb_ctr(encrypt_agile(out, o.p…
25839 if(o.type === "file") return write_dl(o.file, out);
25840 return o.type == "string" ? utf8read(/*::(*/out/*:: :any)*/) : out;
25846 return write_cfb_ctr(cfb, o);
25853 case "base64": return Base64_encode(utf8write(o));
25854 case "binary": return utf8write(o);
25855 case "string": return out;
25856 case "file": return write_dl(opts.file, o, 'utf8');
25858 if(has_buf) return Buffer_from(o, 'utf8');
25859 else if(typeof TextEncoder !== "undefined") return new TextEncoder().encode(o);
25860 …else return write_string_type(o, {type:'binary'}).split("").map(function(c) { return c.charCodeAt(…
25868 case "base64": return Base64_encode_pass(out);
25869 case "binary": return out;
25870 case "string": return out; /* override in sheet_to_txt */
25871 case "file": return write_dl(opts.file, out, 'binary');
25873 if(has_buf) return Buffer_from(out, 'binary');
25874 else return out.split("").map(function(c) { return c.charCodeAt(0); });
25889return opts.type == 'base64' ? Base64_encode(bstr) : opts.type == 'string' ? utf8read(bstr) : bstr;
25890 case "file": return write_dl(opts.file, out);
25891 case "buffer": return out;
25901 …binary"; var out/*:string*/ = (writeSyncXLSX(wb, o)/*:any*/); o.type = "array"; return s2ab(out); }
25902 return write_zip_typeXLSX(wb, o);
25910 … = "binary"; var out/*:string*/ = (writeSync(wb, o)/*:any*/); o.type = "array"; return s2ab(out); }
25919 case 'xlml': return write_string_type(write_xlml(wb, o), o);
25921 case 'sylk': return write_string_type(SYLK.from_sheet(wb.Sheets[wb.SheetNames[idx]], o, wb), o);
25923 case 'html': return write_string_type(sheet_to_html(wb.Sheets[wb.SheetNames[idx]], o), o);
25924 case 'txt': return write_stxt_type(sheet_to_txt(wb.Sheets[wb.SheetNames[idx]], o), o);
25925 case 'csv': return write_string_type(sheet_to_csv(wb.Sheets[wb.SheetNames[idx]], o), o, "\ufeff");
25926 case 'dif': return write_string_type(DIF.from_sheet(wb.Sheets[wb.SheetNames[idx]], o), o);
25927 case 'dbf': return write_binary_type(DBF.from_sheet(wb.Sheets[wb.SheetNames[idx]], o), o);
25928 case 'prn': return write_string_type(PRN.from_sheet(wb.Sheets[wb.SheetNames[idx]], o), o);
25929 case 'rtf': return write_string_type(sheet_to_rtf(wb.Sheets[wb.SheetNames[idx]], o), o);
25930 case 'eth': return write_string_type(ETH.from_sheet(wb.Sheets[wb.SheetNames[idx]], o), o);
25931 case 'fods': return write_string_type(write_ods(wb, o), o);
25932 case 'wk1': return write_binary_type(WK_.sheet_to_wk1(wb.Sheets[wb.SheetNames[idx]], o), o);
25933 case 'wk3': return write_binary_type(WK_.book_to_wk3(wb, o), o);
25936 case 'biff4': if(!o.biff) o.biff = 4; return write_binary_type(write_biff_buf(wb, o), o);
25940 case 'xls': if(!o.biff) o.biff = 8; return write_cfb_type(wb, o);
25946 case 'ods': return write_zip_type(wb, o);
25952 if(o.bookType) return;
25969 return writeSync(wb, o);
25976 return writeSyncXLSX(wb, o);
25986 return _fs.writeFile(filename, writeSync(wb, o), _cb);
26029 return { row: row, isempty: isempty };
26034 if(sheet == null || sheet["!ref"] == null) return [];
26085 return out;
26108 if(o.blankrows === false && isempty) return null;
26109 return row.join(FS);
26115 if(sheet == null || sheet["!ref"] == null) return "";
26134 return out.join("");
26140 if(typeof $cptable == 'undefined' || opts.type == 'string') return s;
26142 return String.fromCharCode(255) + String.fromCharCode(254) + o;
26147 if(sheet == null || sheet["!ref"] == null) return [];
26176 return cmds;
26246 return ws;
26248 function json_to_sheet(js/*:Array<any>*/, opts)/*:Worksheet*/ { return sheet_add_json(null, js, opt…
26258 return ws[RC.r][RC.c] || (ws[RC.r][RC.c] = {t:'z'});
26260 return ws[R] || (ws[R] = {t:'z'});
26263 if(typeof R != "number") return ws_get_cell_stub(ws, encode_cell(R));
26265 return ws_get_cell_stub(ws, encode_cell({r:R,c:C||0}));
26271 if(sh >= 0 && wb.SheetNames.length > sh) return sh;
26275 if(idx > -1) return idx;
26282 return { SheetNames: [], Sheets: {} };
26301 return name;
26324 return cell;
26335 return cell;
26337 function cell_set_internal_link(cell/*:Cell*/, range/*:string*/, tooltip/*:?string*/) { return cell…
26365 return ws;
26414 if(sheet == null || sheet["!ref"] == null) { stream.push(null); return stream; }
26427 if(!BOM) { BOM = true; return stream.push("\uFEFF"); }
26434 if(row || (o.blankrows !== false)) return stream.push((w++ ? RS : "") + row);
26437 return stream.push(null);
26439 return stream;
26457 return stream.push(null);
26465 return stream;
26471 if(sheet == null || sheet["!ref"] == null) { stream.push(null); return stream; }
26522 return;
26525 return stream.push(null);
26527 return stream;