simple-mind-map
Version:
一个简单的web在线思维导图
2 lines • 1.6 MB
JavaScript
var vA=Object.create;var Zd=Object.defineProperty;var xA=Object.getOwnPropertyDescriptor;var yA=Object.getOwnPropertyNames;var bA=Object.getPrototypeOf,wA=Object.prototype.hasOwnProperty;var TA=(r,t,e)=>t in r?Zd(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var No=(r=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(r,{get:(t,e)=>(typeof require<"u"?require:t)[e]}):r)(function(r){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+r+'" is not supported')});var ve=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),Qd=(r,t)=>{for(var e in t)Zd(r,e,{get:t[e],enumerable:!0})},EA=(r,t,e,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of yA(t))!wA.call(r,n)&&n!==e&&Zd(r,n,{get:()=>t[n],enumerable:!(i=xA(t,n))||i.enumerable});return r};var Ve=(r,t,e)=>(e=r!=null?vA(bA(r)):{},EA(t||!r||!r.__esModule?Zd(e,"default",{value:r,enumerable:!0}):e,r));var Tt=(r,t,e)=>(TA(r,typeof t!="symbol"?t+"":t,e),e);var t5=ve((PJ,Yp)=>{"use strict";var kA=Object.prototype.hasOwnProperty,hi="~";function Kh(){}Object.create&&(Kh.prototype=Object.create(null),new Kh().__proto__||(hi=!1));function CA(r,t,e){this.fn=r,this.context=t,this.once=e||!1}function $v(r,t,e,i,n){if(typeof e!="function")throw new TypeError("The listener must be a function");var a=new CA(e,i||r,n),s=hi?hi+t:t;return r._events[s]?r._events[s].fn?r._events[s]=[r._events[s],a]:r._events[s].push(a):(r._events[s]=a,r._eventsCount++),r}function tf(r,t){--r._eventsCount===0?r._events=new Kh:delete r._events[t]}function Vr(){this._events=new Kh,this._eventsCount=0}Vr.prototype.eventNames=function(){var t=[],e,i;if(this._eventsCount===0)return t;for(i in e=this._events)kA.call(e,i)&&t.push(hi?i.slice(1):i);return Object.getOwnPropertySymbols?t.concat(Object.getOwnPropertySymbols(e)):t};Vr.prototype.listeners=function(t){var e=hi?hi+t:t,i=this._events[e];if(!i)return[];if(i.fn)return[i.fn];for(var n=0,a=i.length,s=new Array(a);n<a;n++)s[n]=i[n].fn;return s};Vr.prototype.listenerCount=function(t){var e=hi?hi+t:t,i=this._events[e];return i?i.fn?1:i.length:0};Vr.prototype.emit=function(t,e,i,n,a,s){var o=hi?hi+t:t;if(!this._events[o])return!1;var l=this._events[o],h=arguments.length,u,c;if(l.fn){switch(l.once&&this.removeListener(t,l.fn,void 0,!0),h){case 1:return l.fn.call(l.context),!0;case 2:return l.fn.call(l.context,e),!0;case 3:return l.fn.call(l.context,e,i),!0;case 4:return l.fn.call(l.context,e,i,n),!0;case 5:return l.fn.call(l.context,e,i,n,a),!0;case 6:return l.fn.call(l.context,e,i,n,a,s),!0}for(c=1,u=new Array(h-1);c<h;c++)u[c-1]=arguments[c];l.fn.apply(l.context,u)}else{var f=l.length,d;for(c=0;c<f;c++)switch(l[c].once&&this.removeListener(t,l[c].fn,void 0,!0),h){case 1:l[c].fn.call(l[c].context);break;case 2:l[c].fn.call(l[c].context,e);break;case 3:l[c].fn.call(l[c].context,e,i);break;case 4:l[c].fn.call(l[c].context,e,i,n);break;default:if(!u)for(d=1,u=new Array(h-1);d<h;d++)u[d-1]=arguments[d];l[c].fn.apply(l[c].context,u)}}return!0};Vr.prototype.on=function(t,e,i){return $v(this,t,e,i,!1)};Vr.prototype.once=function(t,e,i){return $v(this,t,e,i,!0)};Vr.prototype.removeListener=function(t,e,i,n){var a=hi?hi+t:t;if(!this._events[a])return this;if(!e)return tf(this,a),this;var s=this._events[a];if(s.fn)s.fn===e&&(!n||s.once)&&(!i||s.context===i)&&tf(this,a);else{for(var o=0,l=[],h=s.length;o<h;o++)(s[o].fn!==e||n&&!s[o].once||i&&s[o].context!==i)&&l.push(s[o]);l.length?this._events[a]=l.length===1?l[0]:l:tf(this,a)}return this};Vr.prototype.removeAllListeners=function(t){var e;return t?(e=hi?hi+t:t,this._events[e]&&tf(this,e)):(this._events=new Kh,this._eventsCount=0),this};Vr.prototype.off=Vr.prototype.removeListener;Vr.prototype.addListener=Vr.prototype.on;Vr.prefixed=hi;Vr.EventEmitter=Vr;typeof Yp<"u"&&(Yp.exports=Vr)});var Yh=ve((UJ,n5)=>{"use strict";var ef=function(t){return NA(t)&&!AA(t)};function NA(r){return!!r&&typeof r=="object"}function AA(r){var t=Object.prototype.toString.call(r);return t==="[object RegExp]"||t==="[object Date]"||FA(r)}var MA=typeof Symbol=="function"&&Symbol.for,DA=MA?Symbol.for("react.element"):60103;function FA(r){return r.$$typeof===DA}function zA(r){return Array.isArray(r)?[]:{}}function Xh(r,t){var e=t&&t.clone===!0;return e&&ef(r)?Kl(zA(r),r,t):r}function i5(r,t,e){var i=r.slice();return t.forEach(function(n,a){typeof i[a]>"u"?i[a]=Xh(n,e):ef(n)?i[a]=Kl(r[a],n,e):r.indexOf(n)===-1&&i.push(Xh(n,e))}),i}function LA(r,t,e){var i={};return ef(r)&&Object.keys(r).forEach(function(n){i[n]=Xh(r[n],e)}),Object.keys(t).forEach(function(n){!ef(t[n])||!r[n]?i[n]=Xh(t[n],e):i[n]=Kl(r[n],t[n],e)}),i}function Kl(r,t,e){var i=Array.isArray(t),n=Array.isArray(r),a=e||{arrayMerge:i5},s=i===n;if(s)if(i){var o=a.arrayMerge||i5;return o(r,t,e)}else return LA(r,t,e);else return Xh(t,e)}Kl.all=function(t,e){if(!Array.isArray(t)||t.length<2)throw new Error("first argument should be an array with at least two elements");return t.reduce(function(i,n){return Kl(i,n,e)})};var OA=Kl;n5.exports=OA});var Dx=ve((Mx,o2)=>{(function(r){typeof Mx=="object"&&typeof o2<"u"?o2.exports=r():typeof define=="function"&&define.amd?define([],r):(typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:this).JSZip=r()})(function(){return function r(t,e,i){function n(o,l){if(!e[o]){if(!t[o]){var h=typeof No=="function"&&No;if(!l&&h)return h(o,!0);if(a)return a(o,!0);var u=new Error("Cannot find module '"+o+"'");throw u.code="MODULE_NOT_FOUND",u}var c=e[o]={exports:{}};t[o][0].call(c.exports,function(f){var d=t[o][1][f];return n(d||f)},c,c.exports,r,t,e,i)}return e[o].exports}for(var a=typeof No=="function"&&No,s=0;s<i.length;s++)n(i[s]);return n}({1:[function(r,t,e){"use strict";var i=r("./utils"),n=r("./support"),a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";e.encode=function(s){for(var o,l,h,u,c,f,d,m=[],p=0,g=s.length,v=g,b=i.getTypeOf(s)!=="string";p<s.length;)v=g-p,h=b?(o=s[p++],l=p<g?s[p++]:0,p<g?s[p++]:0):(o=s.charCodeAt(p++),l=p<g?s.charCodeAt(p++):0,p<g?s.charCodeAt(p++):0),u=o>>2,c=(3&o)<<4|l>>4,f=1<v?(15&l)<<2|h>>6:64,d=2<v?63&h:64,m.push(a.charAt(u)+a.charAt(c)+a.charAt(f)+a.charAt(d));return m.join("")},e.decode=function(s){var o,l,h,u,c,f,d=0,m=0,p="data:";if(s.substr(0,p.length)===p)throw new Error("Invalid base64 input, it looks like a data url.");var g,v=3*(s=s.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(s.charAt(s.length-1)===a.charAt(64)&&v--,s.charAt(s.length-2)===a.charAt(64)&&v--,v%1!=0)throw new Error("Invalid base64 input, bad content length.");for(g=n.uint8array?new Uint8Array(0|v):new Array(0|v);d<s.length;)o=a.indexOf(s.charAt(d++))<<2|(u=a.indexOf(s.charAt(d++)))>>4,l=(15&u)<<4|(c=a.indexOf(s.charAt(d++)))>>2,h=(3&c)<<6|(f=a.indexOf(s.charAt(d++))),g[m++]=o,c!==64&&(g[m++]=l),f!==64&&(g[m++]=h);return g}},{"./support":30,"./utils":32}],2:[function(r,t,e){"use strict";var i=r("./external"),n=r("./stream/DataWorker"),a=r("./stream/Crc32Probe"),s=r("./stream/DataLengthProbe");function o(l,h,u,c,f){this.compressedSize=l,this.uncompressedSize=h,this.crc32=u,this.compression=c,this.compressedContent=f}o.prototype={getContentWorker:function(){var l=new n(i.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new s("data_length")),h=this;return l.on("end",function(){if(this.streamInfo.data_length!==h.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),l},getCompressedWorker:function(){return new n(i.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},o.createWorkerFrom=function(l,h,u){return l.pipe(new a).pipe(new s("uncompressedSize")).pipe(h.compressWorker(u)).pipe(new s("compressedSize")).withStreamInfo("compression",h)},t.exports=o},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(r,t,e){"use strict";var i=r("./stream/GenericWorker");e.STORE={magic:"\0\0",compressWorker:function(){return new i("STORE compression")},uncompressWorker:function(){return new i("STORE decompression")}},e.DEFLATE=r("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(r,t,e){"use strict";var i=r("./utils"),n=function(){for(var a,s=[],o=0;o<256;o++){a=o;for(var l=0;l<8;l++)a=1&a?3988292384^a>>>1:a>>>1;s[o]=a}return s}();t.exports=function(a,s){return a!==void 0&&a.length?i.getTypeOf(a)!=="string"?function(o,l,h,u){var c=n,f=u+h;o^=-1;for(var d=u;d<f;d++)o=o>>>8^c[255&(o^l[d])];return-1^o}(0|s,a,a.length,0):function(o,l,h,u){var c=n,f=u+h;o^=-1;for(var d=u;d<f;d++)o=o>>>8^c[255&(o^l.charCodeAt(d))];return-1^o}(0|s,a,a.length,0):0}},{"./utils":32}],5:[function(r,t,e){"use strict";e.base64=!1,e.binary=!1,e.dir=!1,e.createFolders=!0,e.date=null,e.compression=null,e.compressionOptions=null,e.comment=null,e.unixPermissions=null,e.dosPermissions=null},{}],6:[function(r,t,e){"use strict";var i=null;i=typeof Promise<"u"?Promise:r("lie"),t.exports={Promise:i}},{lie:37}],7:[function(r,t,e){"use strict";var i=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",n=r("pako"),a=r("./utils"),s=r("./stream/GenericWorker"),o=i?"uint8array":"array";function l(h,u){s.call(this,"FlateWorker/"+h),this._pako=null,this._pakoAction=h,this._pakoOptions=u,this.meta={}}e.magic="\b\0",a.inherits(l,s),l.prototype.processChunk=function(h){this.meta=h.meta,this._pako===null&&this._createPako(),this._pako.push(a.transformTo(o,h.data),!1)},l.prototype.flush=function(){s.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},l.prototype.cleanUp=function(){s.prototype.cleanUp.call(this),this._pako=null},l.prototype._createPako=function(){this._pako=new n[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var h=this;this._pako.onData=function(u){h.push({data:u,meta:h.meta})}},e.compressWorker=function(h){return new l("Deflate",h)},e.uncompressWorker=function(){return new l("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(r,t,e){"use strict";function i(c,f){var d,m="";for(d=0;d<f;d++)m+=String.fromCharCode(255&c),c>>>=8;return m}function n(c,f,d,m,p,g){var v,b,y=c.file,S=c.compression,k=g!==o.utf8encode,C=a.transformTo("string",g(y.name)),F=a.transformTo("string",o.utf8encode(y.name)),E=y.comment,q=a.transformTo("string",g(E)),z=a.transformTo("string",o.utf8encode(E)),R=F.length!==y.name.length,T=z.length!==E.length,j="",K="",H="",$=y.dir,X=y.date,gt={crc32:0,compressedSize:0,uncompressedSize:0};f&&!d||(gt.crc32=c.crc32,gt.compressedSize=c.compressedSize,gt.uncompressedSize=c.uncompressedSize);var tt=0;f&&(tt|=8),k||!R&&!T||(tt|=2048);var D=0,St=0;$&&(D|=16),p==="UNIX"?(St=798,D|=function(P,se){var pe=P;return P||(pe=se?16893:33204),(65535&pe)<<16}(y.unixPermissions,$)):(St=20,D|=function(P){return 63&(P||0)}(y.dosPermissions)),v=X.getUTCHours(),v<<=6,v|=X.getUTCMinutes(),v<<=5,v|=X.getUTCSeconds()/2,b=X.getUTCFullYear()-1980,b<<=4,b|=X.getUTCMonth()+1,b<<=5,b|=X.getUTCDate(),R&&(K=i(1,1)+i(l(C),4)+F,j+="up"+i(K.length,2)+K),T&&(H=i(1,1)+i(l(q),4)+z,j+="uc"+i(H.length,2)+H);var dt="";return dt+=`
\0`,dt+=i(tt,2),dt+=S.magic,dt+=i(v,2),dt+=i(b,2),dt+=i(gt.crc32,4),dt+=i(gt.compressedSize,4),dt+=i(gt.uncompressedSize,4),dt+=i(C.length,2),dt+=i(j.length,2),{fileRecord:h.LOCAL_FILE_HEADER+dt+C+j,dirRecord:h.CENTRAL_FILE_HEADER+i(St,2)+dt+i(q.length,2)+"\0\0\0\0"+i(D,4)+i(m,4)+C+j+q}}var a=r("../utils"),s=r("../stream/GenericWorker"),o=r("../utf8"),l=r("../crc32"),h=r("../signature");function u(c,f,d,m){s.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=f,this.zipPlatform=d,this.encodeFileName=m,this.streamFiles=c,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}a.inherits(u,s),u.prototype.push=function(c){var f=c.meta.percent||0,d=this.entriesCount,m=this._sources.length;this.accumulate?this.contentBuffer.push(c):(this.bytesWritten+=c.data.length,s.prototype.push.call(this,{data:c.data,meta:{currentFile:this.currentFile,percent:d?(f+100*(d-m-1))/d:100}}))},u.prototype.openedSource=function(c){this.currentSourceOffset=this.bytesWritten,this.currentFile=c.file.name;var f=this.streamFiles&&!c.file.dir;if(f){var d=n(c,f,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:d.fileRecord,meta:{percent:0}})}else this.accumulate=!0},u.prototype.closedSource=function(c){this.accumulate=!1;var f=this.streamFiles&&!c.file.dir,d=n(c,f,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(d.dirRecord),f)this.push({data:function(m){return h.DATA_DESCRIPTOR+i(m.crc32,4)+i(m.compressedSize,4)+i(m.uncompressedSize,4)}(c),meta:{percent:100}});else for(this.push({data:d.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},u.prototype.flush=function(){for(var c=this.bytesWritten,f=0;f<this.dirRecords.length;f++)this.push({data:this.dirRecords[f],meta:{percent:100}});var d=this.bytesWritten-c,m=function(p,g,v,b,y){var S=a.transformTo("string",y(b));return h.CENTRAL_DIRECTORY_END+"\0\0\0\0"+i(p,2)+i(p,2)+i(g,4)+i(v,4)+i(S.length,2)+S}(this.dirRecords.length,d,c,this.zipComment,this.encodeFileName);this.push({data:m,meta:{percent:100}})},u.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},u.prototype.registerPrevious=function(c){this._sources.push(c);var f=this;return c.on("data",function(d){f.processChunk(d)}),c.on("end",function(){f.closedSource(f.previous.streamInfo),f._sources.length?f.prepareNextSource():f.end()}),c.on("error",function(d){f.error(d)}),this},u.prototype.resume=function(){return!!s.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},u.prototype.error=function(c){var f=this._sources;if(!s.prototype.error.call(this,c))return!1;for(var d=0;d<f.length;d++)try{f[d].error(c)}catch{}return!0},u.prototype.lock=function(){s.prototype.lock.call(this);for(var c=this._sources,f=0;f<c.length;f++)c[f].lock()},t.exports=u},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(r,t,e){"use strict";var i=r("../compressions"),n=r("./ZipFileWorker");e.generateWorker=function(a,s,o){var l=new n(s.streamFiles,o,s.platform,s.encodeFileName),h=0;try{a.forEach(function(u,c){h++;var f=function(g,v){var b=g||v,y=i[b];if(!y)throw new Error(b+" is not a valid compression method !");return y}(c.options.compression,s.compression),d=c.options.compressionOptions||s.compressionOptions||{},m=c.dir,p=c.date;c._compressWorker(f,d).withStreamInfo("file",{name:u,dir:m,date:p,comment:c.comment||"",unixPermissions:c.unixPermissions,dosPermissions:c.dosPermissions}).pipe(l)}),l.entriesCount=h}catch(u){l.error(u)}return l}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(r,t,e){"use strict";function i(){if(!(this instanceof i))return new i;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var n=new i;for(var a in this)typeof this[a]!="function"&&(n[a]=this[a]);return n}}(i.prototype=r("./object")).loadAsync=r("./load"),i.support=r("./support"),i.defaults=r("./defaults"),i.version="3.10.1",i.loadAsync=function(n,a){return new i().loadAsync(n,a)},i.external=r("./external"),t.exports=i},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(r,t,e){"use strict";var i=r("./utils"),n=r("./external"),a=r("./utf8"),s=r("./zipEntries"),o=r("./stream/Crc32Probe"),l=r("./nodejsUtils");function h(u){return new n.Promise(function(c,f){var d=u.decompressed.getContentWorker().pipe(new o);d.on("error",function(m){f(m)}).on("end",function(){d.streamInfo.crc32!==u.decompressed.crc32?f(new Error("Corrupted zip : CRC32 mismatch")):c()}).resume()})}t.exports=function(u,c){var f=this;return c=i.extend(c||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:a.utf8decode}),l.isNode&&l.isStream(u)?n.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):i.prepareContent("the loaded zip file",u,!0,c.optimizedBinaryString,c.base64).then(function(d){var m=new s(c);return m.load(d),m}).then(function(d){var m=[n.Promise.resolve(d)],p=d.files;if(c.checkCRC32)for(var g=0;g<p.length;g++)m.push(h(p[g]));return n.Promise.all(m)}).then(function(d){for(var m=d.shift(),p=m.files,g=0;g<p.length;g++){var v=p[g],b=v.fileNameStr,y=i.resolve(v.fileNameStr);f.file(y,v.decompressed,{binary:!0,optimizedBinaryString:!0,date:v.date,dir:v.dir,comment:v.fileCommentStr.length?v.fileCommentStr:null,unixPermissions:v.unixPermissions,dosPermissions:v.dosPermissions,createFolders:c.createFolders}),v.dir||(f.file(y).unsafeOriginalName=b)}return m.zipComment.length&&(f.comment=m.zipComment),f})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(r,t,e){"use strict";var i=r("../utils"),n=r("../stream/GenericWorker");function a(s,o){n.call(this,"Nodejs stream input adapter for "+s),this._upstreamEnded=!1,this._bindStream(o)}i.inherits(a,n),a.prototype._bindStream=function(s){var o=this;(this._stream=s).pause(),s.on("data",function(l){o.push({data:l,meta:{percent:0}})}).on("error",function(l){o.isPaused?this.generatedError=l:o.error(l)}).on("end",function(){o.isPaused?o._upstreamEnded=!0:o.end()})},a.prototype.pause=function(){return!!n.prototype.pause.call(this)&&(this._stream.pause(),!0)},a.prototype.resume=function(){return!!n.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},t.exports=a},{"../stream/GenericWorker":28,"../utils":32}],13:[function(r,t,e){"use strict";var i=r("readable-stream").Readable;function n(a,s,o){i.call(this,s),this._helper=a;var l=this;a.on("data",function(h,u){l.push(h)||l._helper.pause(),o&&o(u)}).on("error",function(h){l.emit("error",h)}).on("end",function(){l.push(null)})}r("../utils").inherits(n,i),n.prototype._read=function(){this._helper.resume()},t.exports=n},{"../utils":32,"readable-stream":16}],14:[function(r,t,e){"use strict";t.exports={isNode:typeof Buffer<"u",newBufferFrom:function(i,n){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(i,n);if(typeof i=="number")throw new Error('The "data" argument must not be a number');return new Buffer(i,n)},allocBuffer:function(i){if(Buffer.alloc)return Buffer.alloc(i);var n=new Buffer(i);return n.fill(0),n},isBuffer:function(i){return Buffer.isBuffer(i)},isStream:function(i){return i&&typeof i.on=="function"&&typeof i.pause=="function"&&typeof i.resume=="function"}}},{}],15:[function(r,t,e){"use strict";function i(y,S,k){var C,F=a.getTypeOf(S),E=a.extend(k||{},l);E.date=E.date||new Date,E.compression!==null&&(E.compression=E.compression.toUpperCase()),typeof E.unixPermissions=="string"&&(E.unixPermissions=parseInt(E.unixPermissions,8)),E.unixPermissions&&16384&E.unixPermissions&&(E.dir=!0),E.dosPermissions&&16&E.dosPermissions&&(E.dir=!0),E.dir&&(y=p(y)),E.createFolders&&(C=m(y))&&g.call(this,C,!0);var q=F==="string"&&E.binary===!1&&E.base64===!1;k&&k.binary!==void 0||(E.binary=!q),(S instanceof h&&S.uncompressedSize===0||E.dir||!S||S.length===0)&&(E.base64=!1,E.binary=!0,S="",E.compression="STORE",F="string");var z=null;z=S instanceof h||S instanceof s?S:f.isNode&&f.isStream(S)?new d(y,S):a.prepareContent(y,S,E.binary,E.optimizedBinaryString,E.base64);var R=new u(y,z,E);this.files[y]=R}var n=r("./utf8"),a=r("./utils"),s=r("./stream/GenericWorker"),o=r("./stream/StreamHelper"),l=r("./defaults"),h=r("./compressedObject"),u=r("./zipObject"),c=r("./generate"),f=r("./nodejsUtils"),d=r("./nodejs/NodejsStreamInputAdapter"),m=function(y){y.slice(-1)==="/"&&(y=y.substring(0,y.length-1));var S=y.lastIndexOf("/");return 0<S?y.substring(0,S):""},p=function(y){return y.slice(-1)!=="/"&&(y+="/"),y},g=function(y,S){return S=S!==void 0?S:l.createFolders,y=p(y),this.files[y]||i.call(this,y,null,{dir:!0,createFolders:S}),this.files[y]};function v(y){return Object.prototype.toString.call(y)==="[object RegExp]"}var b={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(y){var S,k,C;for(S in this.files)C=this.files[S],(k=S.slice(this.root.length,S.length))&&S.slice(0,this.root.length)===this.root&&y(k,C)},filter:function(y){var S=[];return this.forEach(function(k,C){y(k,C)&&S.push(C)}),S},file:function(y,S,k){if(arguments.length!==1)return y=this.root+y,i.call(this,y,S,k),this;if(v(y)){var C=y;return this.filter(function(E,q){return!q.dir&&C.test(E)})}var F=this.files[this.root+y];return F&&!F.dir?F:null},folder:function(y){if(!y)return this;if(v(y))return this.filter(function(F,E){return E.dir&&y.test(F)});var S=this.root+y,k=g.call(this,S),C=this.clone();return C.root=k.name,C},remove:function(y){y=this.root+y;var S=this.files[y];if(S||(y.slice(-1)!=="/"&&(y+="/"),S=this.files[y]),S&&!S.dir)delete this.files[y];else for(var k=this.filter(function(F,E){return E.name.slice(0,y.length)===y}),C=0;C<k.length;C++)delete this.files[k[C].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(y){var S,k={};try{if((k=a.extend(y||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:n.utf8encode})).type=k.type.toLowerCase(),k.compression=k.compression.toUpperCase(),k.type==="binarystring"&&(k.type="string"),!k.type)throw new Error("No output type specified.");a.checkSupport(k.type),k.platform!=="darwin"&&k.platform!=="freebsd"&&k.platform!=="linux"&&k.platform!=="sunos"||(k.platform="UNIX"),k.platform==="win32"&&(k.platform="DOS");var C=k.comment||this.comment||"";S=c.generateWorker(this,k,C)}catch(F){(S=new s("error")).error(F)}return new o(S,k.type||"string",k.mimeType)},generateAsync:function(y,S){return this.generateInternalStream(y).accumulate(S)},generateNodeStream:function(y,S){return(y=y||{}).type||(y.type="nodebuffer"),this.generateInternalStream(y).toNodejsStream(S)}};t.exports=b},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(r,t,e){"use strict";t.exports=r("stream")},{stream:void 0}],17:[function(r,t,e){"use strict";var i=r("./DataReader");function n(a){i.call(this,a);for(var s=0;s<this.data.length;s++)a[s]=255&a[s]}r("../utils").inherits(n,i),n.prototype.byteAt=function(a){return this.data[this.zero+a]},n.prototype.lastIndexOfSignature=function(a){for(var s=a.charCodeAt(0),o=a.charCodeAt(1),l=a.charCodeAt(2),h=a.charCodeAt(3),u=this.length-4;0<=u;--u)if(this.data[u]===s&&this.data[u+1]===o&&this.data[u+2]===l&&this.data[u+3]===h)return u-this.zero;return-1},n.prototype.readAndCheckSignature=function(a){var s=a.charCodeAt(0),o=a.charCodeAt(1),l=a.charCodeAt(2),h=a.charCodeAt(3),u=this.readData(4);return s===u[0]&&o===u[1]&&l===u[2]&&h===u[3]},n.prototype.readData=function(a){if(this.checkOffset(a),a===0)return[];var s=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,s},t.exports=n},{"../utils":32,"./DataReader":18}],18:[function(r,t,e){"use strict";var i=r("../utils");function n(a){this.data=a,this.length=a.length,this.index=0,this.zero=0}n.prototype={checkOffset:function(a){this.checkIndex(this.index+a)},checkIndex:function(a){if(this.length<this.zero+a||a<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+a+"). Corrupted zip ?")},setIndex:function(a){this.checkIndex(a),this.index=a},skip:function(a){this.setIndex(this.index+a)},byteAt:function(){},readInt:function(a){var s,o=0;for(this.checkOffset(a),s=this.index+a-1;s>=this.index;s--)o=(o<<8)+this.byteAt(s);return this.index+=a,o},readString:function(a){return i.transformTo("string",this.readData(a))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var a=this.readInt(4);return new Date(Date.UTC(1980+(a>>25&127),(a>>21&15)-1,a>>16&31,a>>11&31,a>>5&63,(31&a)<<1))}},t.exports=n},{"../utils":32}],19:[function(r,t,e){"use strict";var i=r("./Uint8ArrayReader");function n(a){i.call(this,a)}r("../utils").inherits(n,i),n.prototype.readData=function(a){this.checkOffset(a);var s=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,s},t.exports=n},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(r,t,e){"use strict";var i=r("./DataReader");function n(a){i.call(this,a)}r("../utils").inherits(n,i),n.prototype.byteAt=function(a){return this.data.charCodeAt(this.zero+a)},n.prototype.lastIndexOfSignature=function(a){return this.data.lastIndexOf(a)-this.zero},n.prototype.readAndCheckSignature=function(a){return a===this.readData(4)},n.prototype.readData=function(a){this.checkOffset(a);var s=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,s},t.exports=n},{"../utils":32,"./DataReader":18}],21:[function(r,t,e){"use strict";var i=r("./ArrayReader");function n(a){i.call(this,a)}r("../utils").inherits(n,i),n.prototype.readData=function(a){if(this.checkOffset(a),a===0)return new Uint8Array(0);var s=this.data.subarray(this.zero+this.index,this.zero+this.index+a);return this.index+=a,s},t.exports=n},{"../utils":32,"./ArrayReader":17}],22:[function(r,t,e){"use strict";var i=r("../utils"),n=r("../support"),a=r("./ArrayReader"),s=r("./StringReader"),o=r("./NodeBufferReader"),l=r("./Uint8ArrayReader");t.exports=function(h){var u=i.getTypeOf(h);return i.checkSupport(u),u!=="string"||n.uint8array?u==="nodebuffer"?new o(h):n.uint8array?new l(i.transformTo("uint8array",h)):new a(i.transformTo("array",h)):new s(h)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(r,t,e){"use strict";e.LOCAL_FILE_HEADER="PK",e.CENTRAL_FILE_HEADER="PK",e.CENTRAL_DIRECTORY_END="PK",e.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",e.ZIP64_CENTRAL_DIRECTORY_END="PK",e.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(r,t,e){"use strict";var i=r("./GenericWorker"),n=r("../utils");function a(s){i.call(this,"ConvertWorker to "+s),this.destType=s}n.inherits(a,i),a.prototype.processChunk=function(s){this.push({data:n.transformTo(this.destType,s.data),meta:s.meta})},t.exports=a},{"../utils":32,"./GenericWorker":28}],25:[function(r,t,e){"use strict";var i=r("./GenericWorker"),n=r("../crc32");function a(){i.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}r("../utils").inherits(a,i),a.prototype.processChunk=function(s){this.streamInfo.crc32=n(s.data,this.streamInfo.crc32||0),this.push(s)},t.exports=a},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(r,t,e){"use strict";var i=r("../utils"),n=r("./GenericWorker");function a(s){n.call(this,"DataLengthProbe for "+s),this.propName=s,this.withStreamInfo(s,0)}i.inherits(a,n),a.prototype.processChunk=function(s){if(s){var o=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=o+s.data.length}n.prototype.processChunk.call(this,s)},t.exports=a},{"../utils":32,"./GenericWorker":28}],27:[function(r,t,e){"use strict";var i=r("../utils"),n=r("./GenericWorker");function a(s){n.call(this,"DataWorker");var o=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,s.then(function(l){o.dataIsReady=!0,o.data=l,o.max=l&&l.length||0,o.type=i.getTypeOf(l),o.isPaused||o._tickAndRepeat()},function(l){o.error(l)})}i.inherits(a,n),a.prototype.cleanUp=function(){n.prototype.cleanUp.call(this),this.data=null},a.prototype.resume=function(){return!!n.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,i.delay(this._tickAndRepeat,[],this)),!0)},a.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(i.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},a.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var s=null,o=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":s=this.data.substring(this.index,o);break;case"uint8array":s=this.data.subarray(this.index,o);break;case"array":case"nodebuffer":s=this.data.slice(this.index,o)}return this.index=o,this.push({data:s,meta:{percent:this.max?this.index/this.max*100:0}})},t.exports=a},{"../utils":32,"./GenericWorker":28}],28:[function(r,t,e){"use strict";function i(n){this.name=n||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}i.prototype={push:function(n){this.emit("data",n)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(n){this.emit("error",n)}return!0},error:function(n){return!this.isFinished&&(this.isPaused?this.generatedError=n:(this.isFinished=!0,this.emit("error",n),this.previous&&this.previous.error(n),this.cleanUp()),!0)},on:function(n,a){return this._listeners[n].push(a),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(n,a){if(this._listeners[n])for(var s=0;s<this._listeners[n].length;s++)this._listeners[n][s].call(this,a)},pipe:function(n){return n.registerPrevious(this)},registerPrevious:function(n){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=n.streamInfo,this.mergeStreamInfo(),this.previous=n;var a=this;return n.on("data",function(s){a.processChunk(s)}),n.on("end",function(){a.end()}),n.on("error",function(s){a.error(s)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var n=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),n=!0),this.previous&&this.previous.resume(),!n},flush:function(){},processChunk:function(n){this.push(n)},withStreamInfo:function(n,a){return this.extraStreamInfo[n]=a,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var n in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,n)&&(this.streamInfo[n]=this.extraStreamInfo[n])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var n="Worker "+this.name;return this.previous?this.previous+" -> "+n:n}},t.exports=i},{}],29:[function(r,t,e){"use strict";var i=r("../utils"),n=r("./ConvertWorker"),a=r("./GenericWorker"),s=r("../base64"),o=r("../support"),l=r("../external"),h=null;if(o.nodestream)try{h=r("../nodejs/NodejsStreamOutputAdapter")}catch{}function u(f,d){return new l.Promise(function(m,p){var g=[],v=f._internalType,b=f._outputType,y=f._mimeType;f.on("data",function(S,k){g.push(S),d&&d(k)}).on("error",function(S){g=[],p(S)}).on("end",function(){try{var S=function(k,C,F){switch(k){case"blob":return i.newBlob(i.transformTo("arraybuffer",C),F);case"base64":return s.encode(C);default:return i.transformTo(k,C)}}(b,function(k,C){var F,E=0,q=null,z=0;for(F=0;F<C.length;F++)z+=C[F].length;switch(k){case"string":return C.join("");case"array":return Array.prototype.concat.apply([],C);case"uint8array":for(q=new Uint8Array(z),F=0;F<C.length;F++)q.set(C[F],E),E+=C[F].length;return q;case"nodebuffer":return Buffer.concat(C);default:throw new Error("concat : unsupported type '"+k+"'")}}(v,g),y);m(S)}catch(k){p(k)}g=[]}).resume()})}function c(f,d,m){var p=d;switch(d){case"blob":case"arraybuffer":p="uint8array";break;case"base64":p="string"}try{this._internalType=p,this._outputType=d,this._mimeType=m,i.checkSupport(p),this._worker=f.pipe(new n(p)),f.lock()}catch(g){this._worker=new a("error"),this._worker.error(g)}}c.prototype={accumulate:function(f){return u(this,f)},on:function(f,d){var m=this;return f==="data"?this._worker.on(f,function(p){d.call(m,p.data,p.meta)}):this._worker.on(f,function(){i.delay(d,arguments,m)}),this},resume:function(){return i.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(f){if(i.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new h(this,{objectMode:this._outputType!=="nodebuffer"},f)}},t.exports=c},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(r,t,e){"use strict";if(e.base64=!0,e.array=!0,e.string=!0,e.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",e.nodebuffer=typeof Buffer<"u",e.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")e.blob=!1;else{var i=new ArrayBuffer(0);try{e.blob=new Blob([i],{type:"application/zip"}).size===0}catch{try{var n=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);n.append(i),e.blob=n.getBlob("application/zip").size===0}catch{e.blob=!1}}}try{e.nodestream=!!r("readable-stream").Readable}catch{e.nodestream=!1}},{"readable-stream":16}],31:[function(r,t,e){"use strict";for(var i=r("./utils"),n=r("./support"),a=r("./nodejsUtils"),s=r("./stream/GenericWorker"),o=new Array(256),l=0;l<256;l++)o[l]=252<=l?6:248<=l?5:240<=l?4:224<=l?3:192<=l?2:1;o[254]=o[254]=1;function h(){s.call(this,"utf-8 decode"),this.leftOver=null}function u(){s.call(this,"utf-8 encode")}e.utf8encode=function(c){return n.nodebuffer?a.newBufferFrom(c,"utf-8"):function(f){var d,m,p,g,v,b=f.length,y=0;for(g=0;g<b;g++)(64512&(m=f.charCodeAt(g)))==55296&&g+1<b&&(64512&(p=f.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(p-56320),g++),y+=m<128?1:m<2048?2:m<65536?3:4;for(d=n.uint8array?new Uint8Array(y):new Array(y),g=v=0;v<y;g++)(64512&(m=f.charCodeAt(g)))==55296&&g+1<b&&(64512&(p=f.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(p-56320),g++),m<128?d[v++]=m:(m<2048?d[v++]=192|m>>>6:(m<65536?d[v++]=224|m>>>12:(d[v++]=240|m>>>18,d[v++]=128|m>>>12&63),d[v++]=128|m>>>6&63),d[v++]=128|63&m);return d}(c)},e.utf8decode=function(c){return n.nodebuffer?i.transformTo("nodebuffer",c).toString("utf-8"):function(f){var d,m,p,g,v=f.length,b=new Array(2*v);for(d=m=0;d<v;)if((p=f[d++])<128)b[m++]=p;else if(4<(g=o[p]))b[m++]=65533,d+=g-1;else{for(p&=g===2?31:g===3?15:7;1<g&&d<v;)p=p<<6|63&f[d++],g--;1<g?b[m++]=65533:p<65536?b[m++]=p:(p-=65536,b[m++]=55296|p>>10&1023,b[m++]=56320|1023&p)}return b.length!==m&&(b.subarray?b=b.subarray(0,m):b.length=m),i.applyFromCharCode(b)}(c=i.transformTo(n.uint8array?"uint8array":"array",c))},i.inherits(h,s),h.prototype.processChunk=function(c){var f=i.transformTo(n.uint8array?"uint8array":"array",c.data);if(this.leftOver&&this.leftOver.length){if(n.uint8array){var d=f;(f=new Uint8Array(d.length+this.leftOver.length)).set(this.leftOver,0),f.set(d,this.leftOver.length)}else f=this.leftOver.concat(f);this.leftOver=null}var m=function(g,v){var b;for((v=v||g.length)>g.length&&(v=g.length),b=v-1;0<=b&&(192&g[b])==128;)b--;return b<0||b===0?v:b+o[g[b]]>v?b:v}(f),p=f;m!==f.length&&(n.uint8array?(p=f.subarray(0,m),this.leftOver=f.subarray(m,f.length)):(p=f.slice(0,m),this.leftOver=f.slice(m,f.length))),this.push({data:e.utf8decode(p),meta:c.meta})},h.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:e.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},e.Utf8DecodeWorker=h,i.inherits(u,s),u.prototype.processChunk=function(c){this.push({data:e.utf8encode(c.data),meta:c.meta})},e.Utf8EncodeWorker=u},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(r,t,e){"use strict";var i=r("./support"),n=r("./base64"),a=r("./nodejsUtils"),s=r("./external");function o(d){return d}function l(d,m){for(var p=0;p<d.length;++p)m[p]=255&d.charCodeAt(p);return m}r("setimmediate"),e.newBlob=function(d,m){e.checkSupport("blob");try{return new Blob([d],{type:m})}catch{try{var p=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return p.append(d),p.getBlob(m)}catch{throw new Error("Bug : can't construct the Blob.")}}};var h={stringifyByChunk:function(d,m,p){var g=[],v=0,b=d.length;if(b<=p)return String.fromCharCode.apply(null,d);for(;v<b;)m==="array"||m==="nodebuffer"?g.push(String.fromCharCode.apply(null,d.slice(v,Math.min(v+p,b)))):g.push(String.fromCharCode.apply(null,d.subarray(v,Math.min(v+p,b)))),v+=p;return g.join("")},stringifyByChar:function(d){for(var m="",p=0;p<d.length;p++)m+=String.fromCharCode(d[p]);return m},applyCanBeUsed:{uint8array:function(){try{return i.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return i.nodebuffer&&String.fromCharCode.apply(null,a.allocBuffer(1)).length===1}catch{return!1}}()}};function u(d){var m=65536,p=e.getTypeOf(d),g=!0;if(p==="uint8array"?g=h.applyCanBeUsed.uint8array:p==="nodebuffer"&&(g=h.applyCanBeUsed.nodebuffer),g)for(;1<m;)try{return h.stringifyByChunk(d,p,m)}catch{m=Math.floor(m/2)}return h.stringifyByChar(d)}function c(d,m){for(var p=0;p<d.length;p++)m[p]=d[p];return m}e.applyFromCharCode=u;var f={};f.string={string:o,array:function(d){return l(d,new Array(d.length))},arraybuffer:function(d){return f.string.uint8array(d).buffer},uint8array:function(d){return l(d,new Uint8Array(d.length))},nodebuffer:function(d){return l(d,a.allocBuffer(d.length))}},f.array={string:u,array:o,arraybuffer:function(d){return new Uint8Array(d).buffer},uint8array:function(d){return new Uint8Array(d)},nodebuffer:function(d){return a.newBufferFrom(d)}},f.arraybuffer={string:function(d){return u(new Uint8Array(d))},array:function(d){return c(new Uint8Array(d),new Array(d.byteLength))},arraybuffer:o,uint8array:function(d){return new Uint8Array(d)},nodebuffer:function(d){return a.newBufferFrom(new Uint8Array(d))}},f.uint8array={string:u,array:function(d){return c(d,new Array(d.length))},arraybuffer:function(d){return d.buffer},uint8array:o,nodebuffer:function(d){return a.newBufferFrom(d)}},f.nodebuffer={string:u,array:function(d){return c(d,new Array(d.length))},arraybuffer:function(d){return f.nodebuffer.uint8array(d).buffer},uint8array:function(d){return c(d,new Uint8Array(d.length))},nodebuffer:o},e.transformTo=function(d,m){if(m=m||"",!d)return m;e.checkSupport(d);var p=e.getTypeOf(m);return f[p][d](m)},e.resolve=function(d){for(var m=d.split("/"),p=[],g=0;g<m.length;g++){var v=m[g];v==="."||v===""&&g!==0&&g!==m.length-1||(v===".."?p.pop():p.push(v))}return p.join("/")},e.getTypeOf=function(d){return typeof d=="string"?"string":Object.prototype.toString.call(d)==="[object Array]"?"array":i.nodebuffer&&a.isBuffer(d)?"nodebuffer":i.uint8array&&d instanceof Uint8Array?"uint8array":i.arraybuffer&&d instanceof ArrayBuffer?"arraybuffer":void 0},e.checkSupport=function(d){if(!i[d.toLowerCase()])throw new Error(d+" is not supported by this platform")},e.MAX_VALUE_16BITS=65535,e.MAX_VALUE_32BITS=-1,e.pretty=function(d){var m,p,g="";for(p=0;p<(d||"").length;p++)g+="\\x"+((m=d.charCodeAt(p))<16?"0":"")+m.toString(16).toUpperCase();return g},e.delay=function(d,m,p){setImmediate(function(){d.apply(p||null,m||[])})},e.inherits=function(d,m){function p(){}p.prototype=m.prototype,d.prototype=new p},e.extend=function(){var d,m,p={};for(d=0;d<arguments.length;d++)for(m in arguments[d])Object.prototype.hasOwnProperty.call(arguments[d],m)&&p[m]===void 0&&(p[m]=arguments[d][m]);return p},e.prepareContent=function(d,m,p,g,v){return s.Promise.resolve(m).then(function(b){return i.blob&&(b instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(b))!==-1)&&typeof FileReader<"u"?new s.Promise(function(y,S){var k=new FileReader;k.onload=function(C){y(C.target.result)},k.onerror=function(C){S(C.target.error)},k.readAsArrayBuffer(b)}):b}).then(function(b){var y=e.getTypeOf(b);return y?(y==="arraybuffer"?b=e.transformTo("uint8array",b):y==="string"&&(v?b=n.decode(b):p&&g!==!0&&(b=function(S){return l(S,i.uint8array?new Uint8Array(S.length):new Array(S.length))}(b))),b):s.Promise.reject(new Error("Can't read the data of '"+d+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(r,t,e){"use strict";var i=r("./reader/readerFor"),n=r("./utils"),a=r("./signature"),s=r("./zipEntry"),o=r("./support");function l(h){this.files=[],this.loadOptions=h}l.prototype={checkSignature:function(h){if(!this.reader.readAndCheckSignature(h)){this.reader.index-=4;var u=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+n.pretty(u)+", expected "+n.pretty(h)+")")}},isSignature:function(h,u){var c=this.reader.index;this.reader.setIndex(h);var f=this.reader.readString(4)===u;return this.reader.setIndex(c),f},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var h=this.reader.readData(this.zipCommentLength),u=o.uint8array?"uint8array":"array",c=n.transformTo(u,h);this.zipComment=this.loadOptions.decodeFileName(c)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var h,u,c,f=this.zip64EndOfCentralSize-44;0<f;)h=this.reader.readInt(2),u=this.reader.readInt(4),c=this.reader.readData(u),this.zip64ExtensibleData[h]={id:h,length:u,value:c}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var h,u;for(h=0;h<this.files.length;h++)u=this.files[h],this.reader.setIndex(u.localHeaderOffset),this.checkSignature(a.LOCAL_FILE_HEADER),u.readLocalPart(this.reader),u.handleUTF8(),u.processAttributes()},readCentralDir:function(){var h;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(a.CENTRAL_FILE_HEADER);)(h=new s({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(h);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var h=this.reader.lastIndexOfSignature(a.CENTRAL_DIRECTORY_END);if(h<0)throw this.isSignature(0,a.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(h);var u=h;if(this.checkSignature(a.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===n.MAX_VALUE_16BITS||this.diskWithCentralDirStart===n.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===n.MAX_VALUE_16BITS||this.centralDirRecords===n.MAX_VALUE_16BITS||this.centralDirSize===n.MAX_VALUE_32BITS||this.centralDirOffset===n.MAX_VALUE_32BITS){if(this.zip64=!0,(h=this.reader.lastIndexOfSignature(a.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(h),this.checkSignature(a.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,a.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(a.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(a.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var c=this.centralDirOffset+this.centralDirSize;this.zip64&&(c+=20,c+=12+this.zip64EndOfCentralSize);var f=u-c;if(0<f)this.isSignature(u,a.CENTRAL_FILE_HEADER)||(this.reader.zero=f);else if(f<0)throw new Error("Corrupted zip: missing "+Math.abs(f)+" bytes.")},prepareReader:function(h){this.reader=i(h)},load:function(h){this.prepareReader(h),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},t.exports=l},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(r,t,e){"use strict";var i=r("./reader/readerFor"),n=r("./utils"),a=r("./compressedObject"),s=r("./crc32"),o=r("./utf8"),l=r("./compressions"),h=r("./support");function u(c,f){this.options=c,this.loadOptions=f}u.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(c){var f,d;if(c.skip(22),this.fileNameLength=c.readInt(2),d=c.readInt(2),this.fileName=c.readData(this.fileNameLength),c.skip(d),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((f=function(m){for(var p in l)if(Object.prototype.hasOwnProperty.call(l,p)&&l[p].magic===m)return l[p];return null}(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+n.pretty(this.compressionMethod)+" unknown (inner file : "+n.transformTo("string",this.fileName)+")");this.decompressed=new a(this.compressedSize,this.uncompressedSize,this.crc32,f,c.readData(this.compressedSize))},readCentralPart:function(c){this.versionMadeBy=c.readInt(2),c.skip(2),this.bitFlag=c.readInt(2),this.compressionMethod=c.readString(2),this.date=c.readDate(),this.crc32=c.readInt(4),this.compressedSize=c.readInt(4),this.uncompressedSize=c.readInt(4);var f=c.readInt(2);if(this.extraFieldsLength=c.readInt(2),this.fileCommentLength=c.readInt(2),this.diskNumberStart=c.readInt(2),this.internalFileAttributes=c.readInt(2),this.externalFileAttributes=c.readInt(4),this.localHeaderOffset=c.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");c.skip(f),this.readExtraFields(c),this.parseZIP64ExtraField(c),this.fileComment=c.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var c=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),c==0&&(this.dosPermissions=63&this.externalFileAttributes),c==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var c=i(this.extraFields[1].value);this.uncompressedSize===n.MAX_VALUE_32BITS&&(this.uncompressedSize=c.readInt(8)),this.compressedSize===n.MAX_VALUE_32BITS&&(this.compressedSize=c.readInt(8)),this.localHeaderOffset===n.MAX_VALUE_32BITS&&(this.localHeaderOffset=c.readInt(8)),this.diskNumberStart===n.MAX_VALUE_32BITS&&(this.diskNumberStart=c.readInt(4))}},readExtraFields:function(c){var f,d,m,p=c.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});c.index+4<p;)f=c.readInt(2),d=c.readInt(2),m=c.readData(d),this.extraFields[f]={id:f,length:d,value:m};c.setIndex(p)},handleUTF8:function(){var c=h.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=o.utf8decode(this.fileName),this.fileCommentStr=o.utf8decode(this.fileComment);else{var f=this.findExtraFieldUnicodePath();if(f!==null)this.fileNameStr=f;else{var d=n.transformTo(c,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(d)}var m=this.findExtraFieldUnicodeComment();if(m!==null)this.fileCommentStr=m;else{var p=n.transformTo(c,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(p)}}},findExtraFieldUnicodePath:function(){var c=this.extraFields[28789];if(c){var f=i(c.value);return f.readInt(1)!==1||s(this.fileName)!==f.readInt(4)?null:o.utf8decode(f.readData(c.length-5))}return null},findExtraFieldUnicodeComment:function(){var c=this.extraFields[25461];if(c){var f=i(c.value);return f.readInt(1)!==1||s(this.fileComment)!==f.readInt(4)?null:o.utf8decode(f.readData(c.length-5))}return null}},t.exports=u},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(r,t,e){"use strict";function i(f,d,m){this.name=f,this.dir=m.dir,this.date=m.date,this.comment=m.comment,this.unixPermissions=m.unixPermissions,this.dosPermissions=m.dosPermissions,this._data=d,this._dataBinary=m.binary,this.options={compression:m.compression,compressionOptions:m.compressionOptions}}var n=r("./stream/StreamHelper"),a=r("./stream/DataWorker"),s=r("./utf8"),o=r("./compressedObject"),l=r("./stream/GenericWorker");i.prototype={internalStream:function(f){var d=null,m="string";try{if(!f)throw