vue-office/examples/dist/assets/docx-3e54e032.js
2024-04-17 20:38:25 +08:00

98 lines
176 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{x as _e}from"./index-0390a516.js";import{c as ke}from"./_commonjs-dynamic-modules-302442b1.js";var Ce={exports:{}},xe={exports:{}};/*!
JSZip v3.10.1 - A JavaScript class for generating and reading zip files
<http://stuartk.com/jszip>
(c) 2009-2016 Stuart Knightley <stuart [at] stuartk.com>
Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip/main/LICENSE.markdown.
JSZip uses the library pako released under the MIT license :
https://github.com/nodeca/pako/blob/main/LICENSE
*/var Pe;function Be(){return Pe||(Pe=1,function(ne,ce){(function(T){ne.exports=T()})(function(){return function T(L,B,S){function v(r,m){if(!B[r]){if(!L[r]){var f=typeof ke=="function"&&ke;if(!m&&f)return f(r,!0);if(e)return e(r,!0);var a=new Error("Cannot find module '"+r+"'");throw a.code="MODULE_NOT_FOUND",a}var i=B[r]={exports:{}};L[r][0].call(i.exports,function(y){var h=L[r][1][y];return v(h||y)},i,i.exports,T,L,B,S)}return B[r].exports}for(var e=typeof ke=="function"&&ke,u=0;u<S.length;u++)v(S[u]);return v}({1:[function(T,L,B){var S=T("./utils"),v=T("./support"),e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";B.encode=function(u){for(var r,m,f,a,i,y,h,d=[],p=0,g=u.length,w=g,P=S.getTypeOf(u)!=="string";p<u.length;)w=g-p,f=P?(r=u[p++],m=p<g?u[p++]:0,p<g?u[p++]:0):(r=u.charCodeAt(p++),m=p<g?u.charCodeAt(p++):0,p<g?u.charCodeAt(p++):0),a=r>>2,i=(3&r)<<4|m>>4,y=1<w?(15&m)<<2|f>>6:64,h=2<w?63&f:64,d.push(e.charAt(a)+e.charAt(i)+e.charAt(y)+e.charAt(h));return d.join("")},B.decode=function(u){var r,m,f,a,i,y,h=0,d=0,p="data:";if(u.substr(0,p.length)===p)throw new Error("Invalid base64 input, it looks like a data url.");var g,w=3*(u=u.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(u.charAt(u.length-1)===e.charAt(64)&&w--,u.charAt(u.length-2)===e.charAt(64)&&w--,w%1!=0)throw new Error("Invalid base64 input, bad content length.");for(g=v.uint8array?new Uint8Array(0|w):new Array(0|w);h<u.length;)r=e.indexOf(u.charAt(h++))<<2|(a=e.indexOf(u.charAt(h++)))>>4,m=(15&a)<<4|(i=e.indexOf(u.charAt(h++)))>>2,f=(3&i)<<6|(y=e.indexOf(u.charAt(h++))),g[d++]=r,i!==64&&(g[d++]=m),y!==64&&(g[d++]=f);return g}},{"./support":30,"./utils":32}],2:[function(T,L,B){var S=T("./external"),v=T("./stream/DataWorker"),e=T("./stream/Crc32Probe"),u=T("./stream/DataLengthProbe");function r(m,f,a,i,y){this.compressedSize=m,this.uncompressedSize=f,this.crc32=a,this.compression=i,this.compressedContent=y}r.prototype={getContentWorker:function(){var m=new v(S.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new u("data_length")),f=this;return m.on("end",function(){if(this.streamInfo.data_length!==f.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),m},getCompressedWorker:function(){return new v(S.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},r.createWorkerFrom=function(m,f,a){return m.pipe(new e).pipe(new u("uncompressedSize")).pipe(f.compressWorker(a)).pipe(new u("compressedSize")).withStreamInfo("compression",f)},L.exports=r},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(T,L,B){var S=T("./stream/GenericWorker");B.STORE={magic:"\0\0",compressWorker:function(){return new S("STORE compression")},uncompressWorker:function(){return new S("STORE decompression")}},B.DEFLATE=T("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(T,L,B){var S=T("./utils"),v=function(){for(var e,u=[],r=0;r<256;r++){e=r;for(var m=0;m<8;m++)e=1&e?3988292384^e>>>1:e>>>1;u[r]=e}return u}();L.exports=function(e,u){return e!==void 0&&e.length?S.getTypeOf(e)!=="string"?function(r,m,f,a){var i=v,y=a+f;r^=-1;for(var h=a;h<y;h++)r=r>>>8^i[255&(r^m[h])];return-1^r}(0|u,e,e.length,0):function(r,m,f,a){var i=v,y=a+f;r^=-1;for(var h=a;h<y;h++)r=r>>>8^i[255&(r^m.charCodeAt(h))];return-1^r}(0|u,e,e.length,0):0}},{"./utils":32}],5:[function(T,L,B){B.base64=!1,B.binary=!1,B.dir=!1,B.createFolders=!0,B.date=null,B.compression=null,B.compressionOptions=null,B.comment=null,B.unixPermissions=null,B.dosPermissions=null},{}],6:[function(T,L,B){var S=null;S=typeof Promise<"u"?Promise:T("lie"),L.exports={Promise:S}},{lie:37}],7:[function(T,L,B){var S=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",v=T("pako"),e=T("./utils"),u=T("./stream/GenericWorker"),r=S?"uint8array":"array";function m(f,a){u.call(this,"FlateWorker/"+f),this._pako=null,this._pakoAction=f,this._pakoOptions=a,this.meta={}}B.magic="\b\0",e.inherits(m,u),m.prototype.processChunk=function(f){this.meta=f.meta,this._pako===null&&this._createPako(),this._pako.push(e.transformTo(r,f.data),!1)},m.prototype.flush=function(){u.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},m.prototype.cleanUp=function(){u.prototype.cleanUp.call(this),this._pako=null},m.prototype._createPako=function(){this._pako=new v[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var f=this;this._pako.onData=function(a){f.push({data:a,meta:f.meta})}},B.compressWorker=function(f){return new m("Deflate",f)},B.uncompressWorker=function(){return new m("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(T,L,B){function S(i,y){var h,d="";for(h=0;h<y;h++)d+=String.fromCharCode(255&i),i>>>=8;return d}function v(i,y,h,d,p,g){var w,P,n=i.file,s=i.compression,t=g!==r.utf8encode,l=e.transformTo("string",g(n.name)),b=e.transformTo("string",r.utf8encode(n.name)),k=n.comment,E=e.transformTo("string",g(k)),_=e.transformTo("string",r.utf8encode(k)),C=b.length!==n.name.length,o=_.length!==k.length,R="",V="",F="",q=n.dir,W=n.date,Y={crc32:0,compressedSize:0,uncompressedSize:0};y&&!h||(Y.crc32=i.crc32,Y.compressedSize=i.compressedSize,Y.uncompressedSize=i.uncompressedSize);var z=0;y&&(z|=8),t||!C&&!o||(z|=2048);var O=0,J=0;q&&(O|=16),p==="UNIX"?(J=798,O|=function(Z,ae){var le=Z;return Z||(le=ae?16893:33204),(65535&le)<<16}(n.unixPermissions,q)):(J=20,O|=function(Z){return 63&(Z||0)}(n.dosPermissions)),w=W.getUTCHours(),w<<=6,w|=W.getUTCMinutes(),w<<=5,w|=W.getUTCSeconds()/2,P=W.getUTCFullYear()-1980,P<<=4,P|=W.getUTCMonth()+1,P<<=5,P|=W.getUTCDate(),C&&(V=S(1,1)+S(m(l),4)+b,R+="up"+S(V.length,2)+V),o&&(F=S(1,1)+S(m(E),4)+_,R+="uc"+S(F.length,2)+F);var X="";return X+=`
\0`,X+=S(z,2),X+=s.magic,X+=S(w,2),X+=S(P,2),X+=S(Y.crc32,4),X+=S(Y.compressedSize,4),X+=S(Y.uncompressedSize,4),X+=S(l.length,2),X+=S(R.length,2),{fileRecord:f.LOCAL_FILE_HEADER+X+l+R,dirRecord:f.CENTRAL_FILE_HEADER+S(J,2)+X+S(E.length,2)+"\0\0\0\0"+S(O,4)+S(d,4)+l+R+E}}var e=T("../utils"),u=T("../stream/GenericWorker"),r=T("../utf8"),m=T("../crc32"),f=T("../signature");function a(i,y,h,d){u.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=y,this.zipPlatform=h,this.encodeFileName=d,this.streamFiles=i,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}e.inherits(a,u),a.prototype.push=function(i){var y=i.meta.percent||0,h=this.entriesCount,d=this._sources.length;this.accumulate?this.contentBuffer.push(i):(this.bytesWritten+=i.data.length,u.prototype.push.call(this,{data:i.data,meta:{currentFile:this.currentFile,percent:h?(y+100*(h-d-1))/h:100}}))},a.prototype.openedSource=function(i){this.currentSourceOffset=this.bytesWritten,this.currentFile=i.file.name;var y=this.streamFiles&&!i.file.dir;if(y){var h=v(i,y,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:h.fileRecord,meta:{percent:0}})}else this.accumulate=!0},a.prototype.closedSource=function(i){this.accumulate=!1;var y=this.streamFiles&&!i.file.dir,h=v(i,y,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(h.dirRecord),y)this.push({data:function(d){return f.DATA_DESCRIPTOR+S(d.crc32,4)+S(d.compressedSize,4)+S(d.uncompressedSize,4)}(i),meta:{percent:100}});else for(this.push({data:h.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},a.prototype.flush=function(){for(var i=this.bytesWritten,y=0;y<this.dirRecords.length;y++)this.push({data:this.dirRecords[y],meta:{percent:100}});var h=this.bytesWritten-i,d=function(p,g,w,P,n){var s=e.transformTo("string",n(P));return f.CENTRAL_DIRECTORY_END+"\0\0\0\0"+S(p,2)+S(p,2)+S(g,4)+S(w,4)+S(s.length,2)+s}(this.dirRecords.length,h,i,this.zipComment,this.encodeFileName);this.push({data:d,meta:{percent:100}})},a.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},a.prototype.registerPrevious=function(i){this._sources.push(i);var y=this;return i.on("data",function(h){y.processChunk(h)}),i.on("end",function(){y.closedSource(y.previous.streamInfo),y._sources.length?y.prepareNextSource():y.end()}),i.on("error",function(h){y.error(h)}),this},a.prototype.resume=function(){return!!u.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},a.prototype.error=function(i){var y=this._sources;if(!u.prototype.error.call(this,i))return!1;for(var h=0;h<y.length;h++)try{y[h].error(i)}catch{}return!0},a.prototype.lock=function(){u.prototype.lock.call(this);for(var i=this._sources,y=0;y<i.length;y++)i[y].lock()},L.exports=a},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(T,L,B){var S=T("../compressions"),v=T("./ZipFileWorker");B.generateWorker=function(e,u,r){var m=new v(u.streamFiles,r,u.platform,u.encodeFileName),f=0;try{e.forEach(function(a,i){f++;var y=function(g,w){var P=g||w,n=S[P];if(!n)throw new Error(P+" is not a valid compression method !");return n}(i.options.compression,u.compression),h=i.options.compressionOptions||u.compressionOptions||{},d=i.dir,p=i.date;i._compressWorker(y,h).withStreamInfo("file",{name:a,dir:d,date:p,comment:i.comment||"",unixPermissions:i.unixPermissions,dosPermissions:i.dosPermissions}).pipe(m)}),m.entriesCount=f}catch(a){m.error(a)}return m}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(T,L,B){function S(){if(!(this instanceof S))return new S;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 v=new S;for(var e in this)typeof this[e]!="function"&&(v[e]=this[e]);return v}}(S.prototype=T("./object")).loadAsync=T("./load"),S.support=T("./support"),S.defaults=T("./defaults"),S.version="3.10.1",S.loadAsync=function(v,e){return new S().loadAsync(v,e)},S.external=T("./external"),L.exports=S},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(T,L,B){var S=T("./utils"),v=T("./external"),e=T("./utf8"),u=T("./zipEntries"),r=T("./stream/Crc32Probe"),m=T("./nodejsUtils");function f(a){return new v.Promise(function(i,y){var h=a.decompressed.getContentWorker().pipe(new r);h.on("error",function(d){y(d)}).on("end",function(){h.streamInfo.crc32!==a.decompressed.crc32?y(new Error("Corrupted zip : CRC32 mismatch")):i()}).resume()})}L.exports=function(a,i){var y=this;return i=S.extend(i||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:e.utf8decode}),m.isNode&&m.isStream(a)?v.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):S.prepareContent("the loaded zip file",a,!0,i.optimizedBinaryString,i.base64).then(function(h){var d=new u(i);return d.load(h),d}).then(function(h){var d=[v.Promise.resolve(h)],p=h.files;if(i.checkCRC32)for(var g=0;g<p.length;g++)d.push(f(p[g]));return v.Promise.all(d)}).then(function(h){for(var d=h.shift(),p=d.files,g=0;g<p.length;g++){var w=p[g],P=w.fileNameStr,n=S.resolve(w.fileNameStr);y.file(n,w.decompressed,{binary:!0,optimizedBinaryString:!0,date:w.date,dir:w.dir,comment:w.fileCommentStr.length?w.fileCommentStr:null,unixPermissions:w.unixPermissions,dosPermissions:w.dosPermissions,createFolders:i.createFolders}),w.dir||(y.file(n).unsafeOriginalName=P)}return d.zipComment.length&&(y.comment=d.zipComment),y})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(T,L,B){var S=T("../utils"),v=T("../stream/GenericWorker");function e(u,r){v.call(this,"Nodejs stream input adapter for "+u),this._upstreamEnded=!1,this._bindStream(r)}S.inherits(e,v),e.prototype._bindStream=function(u){var r=this;(this._stream=u).pause(),u.on("data",function(m){r.push({data:m,meta:{percent:0}})}).on("error",function(m){r.isPaused?this.generatedError=m:r.error(m)}).on("end",function(){r.isPaused?r._upstreamEnded=!0:r.end()})},e.prototype.pause=function(){return!!v.prototype.pause.call(this)&&(this._stream.pause(),!0)},e.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},L.exports=e},{"../stream/GenericWorker":28,"../utils":32}],13:[function(T,L,B){var S=T("readable-stream").Readable;function v(e,u,r){S.call(this,u),this._helper=e;var m=this;e.on("data",function(f,a){m.push(f)||m._helper.pause(),r&&r(a)}).on("error",function(f){m.emit("error",f)}).on("end",function(){m.push(null)})}T("../utils").inherits(v,S),v.prototype._read=function(){this._helper.resume()},L.exports=v},{"../utils":32,"readable-stream":16}],14:[function(T,L,B){L.exports={isNode:typeof Buffer<"u",newBufferFrom:function(S,v){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(S,v);if(typeof S=="number")throw new Error('The "data" argument must not be a number');return new Buffer(S,v)},allocBuffer:function(S){if(Buffer.alloc)return Buffer.alloc(S);var v=new Buffer(S);return v.fill(0),v},isBuffer:function(S){return Buffer.isBuffer(S)},isStream:function(S){return S&&typeof S.on=="function"&&typeof S.pause=="function"&&typeof S.resume=="function"}}},{}],15:[function(T,L,B){function S(n,s,t){var l,b=e.getTypeOf(s),k=e.extend(t||{},m);k.date=k.date||new Date,k.compression!==null&&(k.compression=k.compression.toUpperCase()),typeof k.unixPermissions=="string"&&(k.unixPermissions=parseInt(k.unixPermissions,8)),k.unixPermissions&&16384&k.unixPermissions&&(k.dir=!0),k.dosPermissions&&16&k.dosPermissions&&(k.dir=!0),k.dir&&(n=p(n)),k.createFolders&&(l=d(n))&&g.call(this,l,!0);var E=b==="string"&&k.binary===!1&&k.base64===!1;t&&t.binary!==void 0||(k.binary=!E),(s instanceof f&&s.uncompressedSize===0||k.dir||!s||s.length===0)&&(k.base64=!1,k.binary=!0,s="",k.compression="STORE",b="string");var _=null;_=s instanceof f||s instanceof u?s:y.isNode&&y.isStream(s)?new h(n,s):e.prepareContent(n,s,k.binary,k.optimizedBinaryString,k.base64);var C=new a(n,_,k);this.files[n]=C}var v=T("./utf8"),e=T("./utils"),u=T("./stream/GenericWorker"),r=T("./stream/StreamHelper"),m=T("./defaults"),f=T("./compressedObject"),a=T("./zipObject"),i=T("./generate"),y=T("./nodejsUtils"),h=T("./nodejs/NodejsStreamInputAdapter"),d=function(n){n.slice(-1)==="/"&&(n=n.substring(0,n.length-1));var s=n.lastIndexOf("/");return 0<s?n.substring(0,s):""},p=function(n){return n.slice(-1)!=="/"&&(n+="/"),n},g=function(n,s){return s=s!==void 0?s:m.createFolders,n=p(n),this.files[n]||S.call(this,n,null,{dir:!0,createFolders:s}),this.files[n]};function w(n){return Object.prototype.toString.call(n)==="[object RegExp]"}var P={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(n){var s,t,l;for(s in this.files)l=this.files[s],(t=s.slice(this.root.length,s.length))&&s.slice(0,this.root.length)===this.root&&n(t,l)},filter:function(n){var s=[];return this.forEach(function(t,l){n(t,l)&&s.push(l)}),s},file:function(n,s,t){if(arguments.length!==1)return n=this.root+n,S.call(this,n,s,t),this;if(w(n)){var l=n;return this.filter(function(k,E){return!E.dir&&l.test(k)})}var b=this.files[this.root+n];return b&&!b.dir?b:null},folder:function(n){if(!n)return this;if(w(n))return this.filter(function(b,k){return k.dir&&n.test(b)});var s=this.root+n,t=g.call(this,s),l=this.clone();return l.root=t.name,l},remove:function(n){n=this.root+n;var s=this.files[n];if(s||(n.slice(-1)!=="/"&&(n+="/"),s=this.files[n]),s&&!s.dir)delete this.files[n];else for(var t=this.filter(function(b,k){return k.name.slice(0,n.length)===n}),l=0;l<t.length;l++)delete this.files[t[l].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(n){var s,t={};try{if((t=e.extend(n||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:v.utf8encode})).type=t.type.toLowerCase(),t.compression=t.compression.toUpperCase(),t.type==="binarystring"&&(t.type="string"),!t.type)throw new Error("No output type specified.");e.checkSupport(t.type),t.platform!=="darwin"&&t.platform!=="freebsd"&&t.platform!=="linux"&&t.platform!=="sunos"||(t.platform="UNIX"),t.platform==="win32"&&(t.platform="DOS");var l=t.comment||this.comment||"";s=i.generateWorker(this,t,l)}catch(b){(s=new u("error")).error(b)}return new r(s,t.type||"string",t.mimeType)},generateAsync:function(n,s){return this.generateInternalStream(n).accumulate(s)},generateNodeStream:function(n,s){return(n=n||{}).type||(n.type="nodebuffer"),this.generateInternalStream(n).toNodejsStream(s)}};L.exports=P},{"./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(T,L,B){L.exports=T("stream")},{stream:void 0}],17:[function(T,L,B){var S=T("./DataReader");function v(e){S.call(this,e);for(var u=0;u<this.data.length;u++)e[u]=255&e[u]}T("../utils").inherits(v,S),v.prototype.byteAt=function(e){return this.data[this.zero+e]},v.prototype.lastIndexOfSignature=function(e){for(var u=e.charCodeAt(0),r=e.charCodeAt(1),m=e.charCodeAt(2),f=e.charCodeAt(3),a=this.length-4;0<=a;--a)if(this.data[a]===u&&this.data[a+1]===r&&this.data[a+2]===m&&this.data[a+3]===f)return a-this.zero;return-1},v.prototype.readAndCheckSignature=function(e){var u=e.charCodeAt(0),r=e.charCodeAt(1),m=e.charCodeAt(2),f=e.charCodeAt(3),a=this.readData(4);return u===a[0]&&r===a[1]&&m===a[2]&&f===a[3]},v.prototype.readData=function(e){if(this.checkOffset(e),e===0)return[];var u=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,u},L.exports=v},{"../utils":32,"./DataReader":18}],18:[function(T,L,B){var S=T("../utils");function v(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}v.prototype={checkOffset:function(e){this.checkIndex(this.index+e)},checkIndex:function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},setIndex:function(e){this.checkIndex(e),this.index=e},skip:function(e){this.setIndex(this.index+e)},byteAt:function(){},readInt:function(e){var u,r=0;for(this.checkOffset(e),u=this.index+e-1;u>=this.index;u--)r=(r<<8)+this.byteAt(u);return this.index+=e,r},readString:function(e){return S.transformTo("string",this.readData(e))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var e=this.readInt(4);return new Date(Date.UTC(1980+(e>>25&127),(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(31&e)<<1))}},L.exports=v},{"../utils":32}],19:[function(T,L,B){var S=T("./Uint8ArrayReader");function v(e){S.call(this,e)}T("../utils").inherits(v,S),v.prototype.readData=function(e){this.checkOffset(e);var u=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,u},L.exports=v},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(T,L,B){var S=T("./DataReader");function v(e){S.call(this,e)}T("../utils").inherits(v,S),v.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},v.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},v.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},v.prototype.readData=function(e){this.checkOffset(e);var u=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,u},L.exports=v},{"../utils":32,"./DataReader":18}],21:[function(T,L,B){var S=T("./ArrayReader");function v(e){S.call(this,e)}T("../utils").inherits(v,S),v.prototype.readData=function(e){if(this.checkOffset(e),e===0)return new Uint8Array(0);var u=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,u},L.exports=v},{"../utils":32,"./ArrayReader":17}],22:[function(T,L,B){var S=T("../utils"),v=T("../support"),e=T("./ArrayReader"),u=T("./StringReader"),r=T("./NodeBufferReader"),m=T("./Uint8ArrayReader");L.exports=function(f){var a=S.getTypeOf(f);return S.checkSupport(a),a!=="string"||v.uint8array?a==="nodebuffer"?new r(f):v.uint8array?new m(S.transformTo("uint8array",f)):new e(S.transformTo("array",f)):new u(f)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(T,L,B){B.LOCAL_FILE_HEADER="PK",B.CENTRAL_FILE_HEADER="PK",B.CENTRAL_DIRECTORY_END="PK",B.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",B.ZIP64_CENTRAL_DIRECTORY_END="PK",B.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(T,L,B){var S=T("./GenericWorker"),v=T("../utils");function e(u){S.call(this,"ConvertWorker to "+u),this.destType=u}v.inherits(e,S),e.prototype.processChunk=function(u){this.push({data:v.transformTo(this.destType,u.data),meta:u.meta})},L.exports=e},{"../utils":32,"./GenericWorker":28}],25:[function(T,L,B){var S=T("./GenericWorker"),v=T("../crc32");function e(){S.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}T("../utils").inherits(e,S),e.prototype.processChunk=function(u){this.streamInfo.crc32=v(u.data,this.streamInfo.crc32||0),this.push(u)},L.exports=e},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(T,L,B){var S=T("../utils"),v=T("./GenericWorker");function e(u){v.call(this,"DataLengthProbe for "+u),this.propName=u,this.withStreamInfo(u,0)}S.inherits(e,v),e.prototype.processChunk=function(u){if(u){var r=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=r+u.data.length}v.prototype.processChunk.call(this,u)},L.exports=e},{"../utils":32,"./GenericWorker":28}],27:[function(T,L,B){var S=T("../utils"),v=T("./GenericWorker");function e(u){v.call(this,"DataWorker");var r=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,u.then(function(m){r.dataIsReady=!0,r.data=m,r.max=m&&m.length||0,r.type=S.getTypeOf(m),r.isPaused||r._tickAndRepeat()},function(m){r.error(m)})}S.inherits(e,v),e.prototype.cleanUp=function(){v.prototype.cleanUp.call(this),this.data=null},e.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,S.delay(this._tickAndRepeat,[],this)),!0)},e.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(S.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},e.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var u=null,r=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":u=this.data.substring(this.index,r);break;case"uint8array":u=this.data.subarray(this.index,r);break;case"array":case"nodebuffer":u=this.data.slice(this.index,r)}return this.index=r,this.push({data:u,meta:{percent:this.max?this.index/this.max*100:0}})},L.exports=e},{"../utils":32,"./GenericWorker":28}],28:[function(T,L,B){function S(v){this.name=v||"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}S.prototype={push:function(v){this.emit("data",v)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(v){this.emit("error",v)}return!0},error:function(v){return!this.isFinished&&(this.isPaused?this.generatedError=v:(this.isFinished=!0,this.emit("error",v),this.previous&&this.previous.error(v),this.cleanUp()),!0)},on:function(v,e){return this._listeners[v].push(e),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(v,e){if(this._listeners[v])for(var u=0;u<this._listeners[v].length;u++)this._listeners[v][u].call(this,e)},pipe:function(v){return v.registerPrevious(this)},registerPrevious:function(v){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=v.streamInfo,this.mergeStreamInfo(),this.previous=v;var e=this;return v.on("data",function(u){e.processChunk(u)}),v.on("end",function(){e.end()}),v.on("error",function(u){e.error(u)}),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 v=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),v=!0),this.previous&&this.previous.resume(),!v},flush:function(){},processChunk:function(v){this.push(v)},withStreamInfo:function(v,e){return this.extraStreamInfo[v]=e,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var v in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,v)&&(this.streamInfo[v]=this.extraStreamInfo[v])},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 v="Worker "+this.name;return this.previous?this.previous+" -> "+v:v}},L.exports=S},{}],29:[function(T,L,B){var S=T("../utils"),v=T("./ConvertWorker"),e=T("./GenericWorker"),u=T("../base64"),r=T("../support"),m=T("../external"),f=null;if(r.nodestream)try{f=T("../nodejs/NodejsStreamOutputAdapter")}catch{}function a(y,h){return new m.Promise(function(d,p){var g=[],w=y._internalType,P=y._outputType,n=y._mimeType;y.on("data",function(s,t){g.push(s),h&&h(t)}).on("error",function(s){g=[],p(s)}).on("end",function(){try{var s=function(t,l,b){switch(t){case"blob":return S.newBlob(S.transformTo("arraybuffer",l),b);case"base64":return u.encode(l);default:return S.transformTo(t,l)}}(P,function(t,l){var b,k=0,E=null,_=0;for(b=0;b<l.length;b++)_+=l[b].length;switch(t){case"string":return l.join("");case"array":return Array.prototype.concat.apply([],l);case"uint8array":for(E=new Uint8Array(_),b=0;b<l.length;b++)E.set(l[b],k),k+=l[b].length;return E;case"nodebuffer":return Buffer.concat(l);default:throw new Error("concat : unsupported type '"+t+"'")}}(w,g),n);d(s)}catch(t){p(t)}g=[]}).resume()})}function i(y,h,d){var p=h;switch(h){case"blob":case"arraybuffer":p="uint8array";break;case"base64":p="string"}try{this._internalType=p,this._outputType=h,this._mimeType=d,S.checkSupport(p),this._worker=y.pipe(new v(p)),y.lock()}catch(g){this._worker=new e("error"),this._worker.error(g)}}i.prototype={accumulate:function(y){return a(this,y)},on:function(y,h){var d=this;return y==="data"?this._worker.on(y,function(p){h.call(d,p.data,p.meta)}):this._worker.on(y,function(){S.delay(h,arguments,d)}),this},resume:function(){return S.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(y){if(S.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new f(this,{objectMode:this._outputType!=="nodebuffer"},y)}},L.exports=i},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(T,L,B){if(B.base64=!0,B.array=!0,B.string=!0,B.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",B.nodebuffer=typeof Buffer<"u",B.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")B.blob=!1;else{var S=new ArrayBuffer(0);try{B.blob=new Blob([S],{type:"application/zip"}).size===0}catch{try{var v=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);v.append(S),B.blob=v.getBlob("application/zip").size===0}catch{B.blob=!1}}}try{B.nodestream=!!T("readable-stream").Readable}catch{B.nodestream=!1}},{"readable-stream":16}],31:[function(T,L,B){for(var S=T("./utils"),v=T("./support"),e=T("./nodejsUtils"),u=T("./stream/GenericWorker"),r=new Array(256),m=0;m<256;m++)r[m]=252<=m?6:248<=m?5:240<=m?4:224<=m?3:192<=m?2:1;r[254]=r[254]=1;function f(){u.call(this,"utf-8 decode"),this.leftOver=null}function a(){u.call(this,"utf-8 encode")}B.utf8encode=function(i){return v.nodebuffer?e.newBufferFrom(i,"utf-8"):function(y){var h,d,p,g,w,P=y.length,n=0;for(g=0;g<P;g++)(64512&(d=y.charCodeAt(g)))==55296&&g+1<P&&(64512&(p=y.charCodeAt(g+1)))==56320&&(d=65536+(d-55296<<10)+(p-56320),g++),n+=d<128?1:d<2048?2:d<65536?3:4;for(h=v.uint8array?new Uint8Array(n):new Array(n),g=w=0;w<n;g++)(64512&(d=y.charCodeAt(g)))==55296&&g+1<P&&(64512&(p=y.charCodeAt(g+1)))==56320&&(d=65536+(d-55296<<10)+(p-56320),g++),d<128?h[w++]=d:(d<2048?h[w++]=192|d>>>6:(d<65536?h[w++]=224|d>>>12:(h[w++]=240|d>>>18,h[w++]=128|d>>>12&63),h[w++]=128|d>>>6&63),h[w++]=128|63&d);return h}(i)},B.utf8decode=function(i){return v.nodebuffer?S.transformTo("nodebuffer",i).toString("utf-8"):function(y){var h,d,p,g,w=y.length,P=new Array(2*w);for(h=d=0;h<w;)if((p=y[h++])<128)P[d++]=p;else if(4<(g=r[p]))P[d++]=65533,h+=g-1;else{for(p&=g===2?31:g===3?15:7;1<g&&h<w;)p=p<<6|63&y[h++],g--;1<g?P[d++]=65533:p<65536?P[d++]=p:(p-=65536,P[d++]=55296|p>>10&1023,P[d++]=56320|1023&p)}return P.length!==d&&(P.subarray?P=P.subarray(0,d):P.length=d),S.applyFromCharCode(P)}(i=S.transformTo(v.uint8array?"uint8array":"array",i))},S.inherits(f,u),f.prototype.processChunk=function(i){var y=S.transformTo(v.uint8array?"uint8array":"array",i.data);if(this.leftOver&&this.leftOver.length){if(v.uint8array){var h=y;(y=new Uint8Array(h.length+this.leftOver.length)).set(this.leftOver,0),y.set(h,this.leftOver.length)}else y=this.leftOver.concat(y);this.leftOver=null}var d=function(g,w){var P;for((w=w||g.length)>g.length&&(w=g.length),P=w-1;0<=P&&(192&g[P])==128;)P--;return P<0||P===0?w:P+r[g[P]]>w?P:w}(y),p=y;d!==y.length&&(v.uint8array?(p=y.subarray(0,d),this.leftOver=y.subarray(d,y.length)):(p=y.slice(0,d),this.leftOver=y.slice(d,y.length))),this.push({data:B.utf8decode(p),meta:i.meta})},f.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:B.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},B.Utf8DecodeWorker=f,S.inherits(a,u),a.prototype.processChunk=function(i){this.push({data:B.utf8encode(i.data),meta:i.meta})},B.Utf8EncodeWorker=a},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(T,L,B){var S=T("./support"),v=T("./base64"),e=T("./nodejsUtils"),u=T("./external");function r(h){return h}function m(h,d){for(var p=0;p<h.length;++p)d[p]=255&h.charCodeAt(p);return d}T("setimmediate"),B.newBlob=function(h,d){B.checkSupport("blob");try{return new Blob([h],{type:d})}catch{try{var p=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return p.append(h),p.getBlob(d)}catch{throw new Error("Bug : can't construct the Blob.")}}};var f={stringifyByChunk:function(h,d,p){var g=[],w=0,P=h.length;if(P<=p)return String.fromCharCode.apply(null,h);for(;w<P;)d==="array"||d==="nodebuffer"?g.push(String.fromCharCode.apply(null,h.slice(w,Math.min(w+p,P)))):g.push(String.fromCharCode.apply(null,h.subarray(w,Math.min(w+p,P)))),w+=p;return g.join("")},stringifyByChar:function(h){for(var d="",p=0;p<h.length;p++)d+=String.fromCharCode(h[p]);return d},applyCanBeUsed:{uint8array:function(){try{return S.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return S.nodebuffer&&String.fromCharCode.apply(null,e.allocBuffer(1)).length===1}catch{return!1}}()}};function a(h){var d=65536,p=B.getTypeOf(h),g=!0;if(p==="uint8array"?g=f.applyCanBeUsed.uint8array:p==="nodebuffer"&&(g=f.applyCanBeUsed.nodebuffer),g)for(;1<d;)try{return f.stringifyByChunk(h,p,d)}catch{d=Math.floor(d/2)}return f.stringifyByChar(h)}function i(h,d){for(var p=0;p<h.length;p++)d[p]=h[p];return d}B.applyFromCharCode=a;var y={};y.string={string:r,array:function(h){return m(h,new Array(h.length))},arraybuffer:function(h){return y.string.uint8array(h).buffer},uint8array:function(h){return m(h,new Uint8Array(h.length))},nodebuffer:function(h){return m(h,e.allocBuffer(h.length))}},y.array={string:a,array:r,arraybuffer:function(h){return new Uint8Array(h).buffer},uint8array:function(h){return new Uint8Array(h)},nodebuffer:function(h){return e.newBufferFrom(h)}},y.arraybuffer={string:function(h){return a(new Uint8Array(h))},array:function(h){return i(new Uint8Array(h),new Array(h.byteLength))},arraybuffer:r,uint8array:function(h){return new Uint8Array(h)},nodebuffer:function(h){return e.newBufferFrom(new Uint8Array(h))}},y.uint8array={string:a,array:function(h){return i(h,new Array(h.length))},arraybuffer:function(h){return h.buffer},uint8array:r,nodebuffer:function(h){return e.newBufferFrom(h)}},y.nodebuffer={string:a,array:function(h){return i(h,new Array(h.length))},arraybuffer:function(h){return y.nodebuffer.uint8array(h).buffer},uint8array:function(h){return i(h,new Uint8Array(h.length))},nodebuffer:r},B.transformTo=function(h,d){if(d=d||"",!h)return d;B.checkSupport(h);var p=B.getTypeOf(d);return y[p][h](d)},B.resolve=function(h){for(var d=h.split("/"),p=[],g=0;g<d.length;g++){var w=d[g];w==="."||w===""&&g!==0&&g!==d.length-1||(w===".."?p.pop():p.push(w))}return p.join("/")},B.getTypeOf=function(h){return typeof h=="string"?"string":Object.prototype.toString.call(h)==="[object Array]"?"array":S.nodebuffer&&e.isBuffer(h)?"nodebuffer":S.uint8array&&h instanceof Uint8Array?"uint8array":S.arraybuffer&&h instanceof ArrayBuffer?"arraybuffer":void 0},B.checkSupport=function(h){if(!S[h.toLowerCase()])throw new Error(h+" is not supported by this platform")},B.MAX_VALUE_16BITS=65535,B.MAX_VALUE_32BITS=-1,B.pretty=function(h){var d,p,g="";for(p=0;p<(h||"").length;p++)g+="\\x"+((d=h.charCodeAt(p))<16?"0":"")+d.toString(16).toUpperCase();return g},B.delay=function(h,d,p){setImmediate(function(){h.apply(p||null,d||[])})},B.inherits=function(h,d){function p(){}p.prototype=d.prototype,h.prototype=new p},B.extend=function(){var h,d,p={};for(h=0;h<arguments.length;h++)for(d in arguments[h])Object.prototype.hasOwnProperty.call(arguments[h],d)&&p[d]===void 0&&(p[d]=arguments[h][d]);return p},B.prepareContent=function(h,d,p,g,w){return u.Promise.resolve(d).then(function(P){return S.blob&&(P instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(P))!==-1)&&typeof FileReader<"u"?new u.Promise(function(n,s){var t=new FileReader;t.onload=function(l){n(l.target.result)},t.onerror=function(l){s(l.target.error)},t.readAsArrayBuffer(P)}):P}).then(function(P){var n=B.getTypeOf(P);return n?(n==="arraybuffer"?P=B.transformTo("uint8array",P):n==="string"&&(w?P=v.decode(P):p&&g!==!0&&(P=function(s){return m(s,S.uint8array?new Uint8Array(s.length):new Array(s.length))}(P))),P):u.Promise.reject(new Error("Can't read the data of '"+h+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(T,L,B){var S=T("./reader/readerFor"),v=T("./utils"),e=T("./signature"),u=T("./zipEntry"),r=T("./support");function m(f){this.files=[],this.loadOptions=f}m.prototype={checkSignature:function(f){if(!this.reader.readAndCheckSignature(f)){this.reader.index-=4;var a=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+v.pretty(a)+", expected "+v.pretty(f)+")")}},isSignature:function(f,a){var i=this.reader.index;this.reader.setIndex(f);var y=this.reader.readString(4)===a;return this.reader.setIndex(i),y},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 f=this.reader.readData(this.zipCommentLength),a=r.uint8array?"uint8array":"array",i=v.transformTo(a,f);this.zipComment=this.loadOptions.decodeFileName(i)},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 f,a,i,y=this.zip64EndOfCentralSize-44;0<y;)f=this.reader.readInt(2),a=this.reader.readInt(4),i=this.reader.readData(a),this.zip64ExtensibleData[f]={id:f,length:a,value:i}},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 f,a;for(f=0;f<this.files.length;f++)a=this.files[f],this.reader.setIndex(a.localHeaderOffset),this.checkSignature(e.LOCAL_FILE_HEADER),a.readLocalPart(this.reader),a.handleUTF8(),a.processAttributes()},readCentralDir:function(){var f;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(e.CENTRAL_FILE_HEADER);)(f=new u({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(f);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 f=this.reader.lastIndexOfSignature(e.CENTRAL_DIRECTORY_END);if(f<0)throw this.isSignature(0,e.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(f);var a=f;if(this.checkSignature(e.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===v.MAX_VALUE_16BITS||this.diskWithCentralDirStart===v.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===v.MAX_VALUE_16BITS||this.centralDirRecords===v.MAX_VALUE_16BITS||this.centralDirSize===v.MAX_VALUE_32BITS||this.centralDirOffset===v.MAX_VALUE_32BITS){if(this.zip64=!0,(f=this.reader.lastIndexOfSignature(e.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(f),this.checkSignature(e.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,e.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(e.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(e.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var i=this.centralDirOffset+this.centralDirSize;this.zip64&&(i+=20,i+=12+this.zip64EndOfCentralSize);var y=a-i;if(0<y)this.isSignature(a,e.CENTRAL_FILE_HEADER)||(this.reader.zero=y);else if(y<0)throw new Error("Corrupted zip: missing "+Math.abs(y)+" bytes.")},prepareReader:function(f){this.reader=S(f)},load:function(f){this.prepareReader(f),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},L.exports=m},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(T,L,B){var S=T("./reader/readerFor"),v=T("./utils"),e=T("./compressedObject"),u=T("./crc32"),r=T("./utf8"),m=T("./compressions"),f=T("./support");function a(i,y){this.options=i,this.loadOptions=y}a.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(i){var y,h;if(i.skip(22),this.fileNameLength=i.readInt(2),h=i.readInt(2),this.fileName=i.readData(this.fileNameLength),i.skip(h),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((y=function(d){for(var p in m)if(Object.prototype.hasOwnProperty.call(m,p)&&m[p].magic===d)return m[p];return null}(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+v.pretty(this.compressionMethod)+" unknown (inner file : "+v.transformTo("string",this.fileName)+")");this.decompressed=new e(this.compressedSize,this.uncompressedSize,this.crc32,y,i.readData(this.compressedSize))},readCentralPart:function(i){this.versionMadeBy=i.readInt(2),i.skip(2),this.bitFlag=i.readInt(2),this.compressionMethod=i.readString(2),this.date=i.readDate(),this.crc32=i.readInt(4),this.compressedSize=i.readInt(4),this.uncompressedSize=i.readInt(4);var y=i.readInt(2);if(this.extraFieldsLength=i.readInt(2),this.fileCommentLength=i.readInt(2),this.diskNumberStart=i.readInt(2),this.internalFileAttributes=i.readInt(2),this.externalFileAttributes=i.readInt(4),this.localHeaderOffset=i.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");i.skip(y),this.readExtraFields(i),this.parseZIP64ExtraField(i),this.fileComment=i.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var i=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),i==0&&(this.dosPermissions=63&this.externalFileAttributes),i==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var i=S(this.extraFields[1].value);this.uncompressedSize===v.MAX_VALUE_32BITS&&(this.uncompressedSize=i.readInt(8)),this.compressedSize===v.MAX_VALUE_32BITS&&(this.compressedSize=i.readInt(8)),this.localHeaderOffset===v.MAX_VALUE_32BITS&&(this.localHeaderOffset=i.readInt(8)),this.diskNumberStart===v.MAX_VALUE_32BITS&&(this.diskNumberStart=i.readInt(4))}},readExtraFields:function(i){var y,h,d,p=i.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});i.index+4<p;)y=i.readInt(2),h=i.readInt(2),d=i.readData(h),this.extraFields[y]={id:y,length:h,value:d};i.setIndex(p)},handleUTF8:function(){var i=f.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=r.utf8decode(this.fileName),this.fileCommentStr=r.utf8decode(this.fileComment);else{var y=this.findExtraFieldUnicodePath();if(y!==null)this.fileNameStr=y;else{var h=v.transformTo(i,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(h)}var d=this.findExtraFieldUnicodeComment();if(d!==null)this.fileCommentStr=d;else{var p=v.transformTo(i,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(p)}}},findExtraFieldUnicodePath:function(){var i=this.extraFields[28789];if(i){var y=S(i.value);return y.readInt(1)!==1||u(this.fileName)!==y.readInt(4)?null:r.utf8decode(y.readData(i.length-5))}return null},findExtraFieldUnicodeComment:function(){var i=this.extraFields[25461];if(i){var y=S(i.value);return y.readInt(1)!==1||u(this.fileComment)!==y.readInt(4)?null:r.utf8decode(y.readData(i.length-5))}return null}},L.exports=a},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(T,L,B){function S(y,h,d){this.name=y,this.dir=d.dir,this.date=d.date,this.comment=d.comment,this.unixPermissions=d.unixPermissions,this.dosPermissions=d.dosPermissions,this._data=h,this._dataBinary=d.binary,this.options={compression:d.compression,compressionOptions:d.compressionOptions}}var v=T("./stream/StreamHelper"),e=T("./stream/DataWorker"),u=T("./utf8"),r=T("./compressedObject"),m=T("./stream/GenericWorker");S.prototype={internalStream:function(y){var h=null,d="string";try{if(!y)throw new Error("No output type specified.");var p=(d=y.toLowerCase())==="string"||d==="text";d!=="binarystring"&&d!=="text"||(d="string"),h=this._decompressWorker();var g=!this._dataBinary;g&&!p&&(h=h.pipe(new u.Utf8EncodeWorker)),!g&&p&&(h=h.pipe(new u.Utf8DecodeWorker))}catch(w){(h=new m("error")).error(w)}return new v(h,d,"")},async:function(y,h){return this.internalStream(y).accumulate(h)},nodeStream:function(y,h){return this.internalStream(y||"nodebuffer").toNodejsStream(h)},_compressWorker:function(y,h){if(this._data instanceof r&&this._data.compression.magic===y.magic)return this._data.getCompressedWorker();var d=this._decompressWorker();return this._dataBinary||(d=d.pipe(new u.Utf8EncodeWorker)),r.createWorkerFrom(d,y,h)},_decompressWorker:function(){return this._data instanceof r?this._data.getContentWorker():this._data instanceof m?this._data:new e(this._data)}};for(var f=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],a=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},i=0;i<f.length;i++)S.prototype[f[i]]=a;L.exports=S},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(T,L,B){(function(S){var v,e,u=S.MutationObserver||S.WebKitMutationObserver;if(u){var r=0,m=new u(y),f=S.document.createTextNode("");m.observe(f,{characterData:!0}),v=function(){f.data=r=++r%2}}else if(S.setImmediate||S.MessageChannel===void 0)v="document"in S&&"onreadystatechange"in S.document.createElement("script")?function(){var h=S.document.createElement("script");h.onreadystatechange=function(){y(),h.onreadystatechange=null,h.parentNode.removeChild(h),h=null},S.document.documentElement.appendChild(h)}:function(){setTimeout(y,0)};else{var a=new S.MessageChannel;a.port1.onmessage=y,v=function(){a.port2.postMessage(0)}}var i=[];function y(){var h,d;e=!0;for(var p=i.length;p;){for(d=i,i=[],h=-1;++h<p;)d[h]();p=i.length}e=!1}L.exports=function(h){i.push(h)!==1||e||v()}}).call(this,typeof _e<"u"?_e:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(T,L,B){var S=T("immediate");function v(){}var e={},u=["REJECTED"],r=["FULFILLED"],m=["PENDING"];function f(p){if(typeof p!="function")throw new TypeError("resolver must be a function");this.state=m,this.queue=[],this.outcome=void 0,p!==v&&h(this,p)}function a(p,g,w){this.promise=p,typeof g=="function"&&(this.onFulfilled=g,this.callFulfilled=this.otherCallFulfilled),typeof w=="function"&&(this.onRejected=w,this.callRejected=this.otherCallRejected)}function i(p,g,w){S(function(){var P;try{P=g(w)}catch(n){return e.reject(p,n)}P===p?e.reject(p,new TypeError("Cannot resolve promise with itself")):e.resolve(p,P)})}function y(p){var g=p&&p.then;if(p&&(typeof p=="object"||typeof p=="function")&&typeof g=="function")return function(){g.apply(p,arguments)}}function h(p,g){var w=!1;function P(t){w||(w=!0,e.reject(p,t))}function n(t){w||(w=!0,e.resolve(p,t))}var s=d(function(){g(n,P)});s.status==="error"&&P(s.value)}function d(p,g){var w={};try{w.value=p(g),w.status="success"}catch(P){w.status="error",w.value=P}return w}(L.exports=f).prototype.finally=function(p){if(typeof p!="function")return this;var g=this.constructor;return this.then(function(w){return g.resolve(p()).then(function(){return w})},function(w){return g.resolve(p()).then(function(){throw w})})},f.prototype.catch=function(p){return this.then(null,p)},f.prototype.then=function(p,g){if(typeof p!="function"&&this.state===r||typeof g!="function"&&this.state===u)return this;var w=new this.constructor(v);return this.state!==m?i(w,this.state===r?p:g,this.outcome):this.queue.push(new a(w,p,g)),w},a.prototype.callFulfilled=function(p){e.resolve(this.promise,p)},a.prototype.otherCallFulfilled=function(p){i(this.promise,this.onFulfilled,p)},a.prototype.callRejected=function(p){e.reject(this.promise,p)},a.prototype.otherCallRejected=function(p){i(this.promise,this.onRejected,p)},e.resolve=function(p,g){var w=d(y,g);if(w.status==="error")return e.reject(p,w.value);var P=w.value;if(P)h(p,P);else{p.state=r,p.outcome=g;for(var n=-1,s=p.queue.length;++n<s;)p.queue[n].callFulfilled(g)}return p},e.reject=function(p,g){p.state=u,p.outcome=g;for(var w=-1,P=p.queue.length;++w<P;)p.queue[w].callRejected(g);return p},f.resolve=function(p){return p instanceof this?p:e.resolve(new this(v),p)},f.reject=function(p){var g=new this(v);return e.reject(g,p)},f.all=function(p){var g=this;if(Object.prototype.toString.call(p)!=="[object Array]")return this.reject(new TypeError("must be an array"));var w=p.length,P=!1;if(!w)return this.resolve([]);for(var n=new Array(w),s=0,t=-1,l=new this(v);++t<w;)b(p[t],t);return l;function b(k,E){g.resolve(k).then(function(_){n[E]=_,++s!==w||P||(P=!0,e.resolve(l,n))},function(_){P||(P=!0,e.reject(l,_))})}},f.race=function(p){var g=this;if(Object.prototype.toString.call(p)!=="[object Array]")return this.reject(new TypeError("must be an array"));var w=p.length,P=!1;if(!w)return this.resolve([]);for(var n=-1,s=new this(v);++n<w;)t=p[n],g.resolve(t).then(function(l){P||(P=!0,e.resolve(s,l))},function(l){P||(P=!0,e.reject(s,l))});var t;return s}},{immediate:36}],38:[function(T,L,B){var S={};(0,T("./lib/utils/common").assign)(S,T("./lib/deflate"),T("./lib/inflate"),T("./lib/zlib/constants")),L.exports=S},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(T,L,B){var S=T("./zlib/deflate"),v=T("./utils/common"),e=T("./utils/strings"),u=T("./zlib/messages"),r=T("./zlib/zstream"),m=Object.prototype.toString,f=0,a=-1,i=0,y=8;function h(p){if(!(this instanceof h))return new h(p);this.options=v.assign({level:a,method:y,chunkSize:16384,windowBits:15,memLevel:8,strategy:i,to:""},p||{});var g=this.options;g.raw&&0<g.windowBits?g.windowBits=-g.windowBits:g.gzip&&0<g.windowBits&&g.windowBits<16&&(g.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new r,this.strm.avail_out=0;var w=S.deflateInit2(this.strm,g.level,g.method,g.windowBits,g.memLevel,g.strategy);if(w!==f)throw new Error(u[w]);if(g.header&&S.deflateSetHeader(this.strm,g.header),g.dictionary){var P;if(P=typeof g.dictionary=="string"?e.string2buf(g.dictionary):m.call(g.dictionary)==="[object ArrayBuffer]"?new Uint8Array(g.dictionary):g.dictionary,(w=S.deflateSetDictionary(this.strm,P))!==f)throw new Error(u[w]);this._dict_set=!0}}function d(p,g){var w=new h(g);if(w.push(p,!0),w.err)throw w.msg||u[w.err];return w.result}h.prototype.push=function(p,g){var w,P,n=this.strm,s=this.options.chunkSize;if(this.ended)return!1;P=g===~~g?g:g===!0?4:0,typeof p=="string"?n.input=e.string2buf(p):m.call(p)==="[object ArrayBuffer]"?n.input=new Uint8Array(p):n.input=p,n.next_in=0,n.avail_in=n.input.length;do{if(n.avail_out===0&&(n.output=new v.Buf8(s),n.next_out=0,n.avail_out=s),(w=S.deflate(n,P))!==1&&w!==f)return this.onEnd(w),!(this.ended=!0);n.avail_out!==0&&(n.avail_in!==0||P!==4&&P!==2)||(this.options.to==="string"?this.onData(e.buf2binstring(v.shrinkBuf(n.output,n.next_out))):this.onData(v.shrinkBuf(n.output,n.next_out)))}while((0<n.avail_in||n.avail_out===0)&&w!==1);return P===4?(w=S.deflateEnd(this.strm),this.onEnd(w),this.ended=!0,w===f):P!==2||(this.onEnd(f),!(n.avail_out=0))},h.prototype.onData=function(p){this.chunks.push(p)},h.prototype.onEnd=function(p){p===f&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=v.flattenChunks(this.chunks)),this.chunks=[],this.err=p,this.msg=this.strm.msg},B.Deflate=h,B.deflate=d,B.deflateRaw=function(p,g){return(g=g||{}).raw=!0,d(p,g)},B.gzip=function(p,g){return(g=g||{}).gzip=!0,d(p,g)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(T,L,B){var S=T("./zlib/inflate"),v=T("./utils/common"),e=T("./utils/strings"),u=T("./zlib/constants"),r=T("./zlib/messages"),m=T("./zlib/zstream"),f=T("./zlib/gzheader"),a=Object.prototype.toString;function i(h){if(!(this instanceof i))return new i(h);this.options=v.assign({chunkSize:16384,windowBits:0,to:""},h||{});var d=this.options;d.raw&&0<=d.windowBits&&d.windowBits<16&&(d.windowBits=-d.windowBits,d.windowBits===0&&(d.windowBits=-15)),!(0<=d.windowBits&&d.windowBits<16)||h&&h.windowBits||(d.windowBits+=32),15<d.windowBits&&d.windowBits<48&&!(15&d.windowBits)&&(d.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new m,this.strm.avail_out=0;var p=S.inflateInit2(this.strm,d.windowBits);if(p!==u.Z_OK)throw new Error(r[p]);this.header=new f,S.inflateGetHeader(this.strm,this.header)}function y(h,d){var p=new i(d);if(p.push(h,!0),p.err)throw p.msg||r[p.err];return p.result}i.prototype.push=function(h,d){var p,g,w,P,n,s,t=this.strm,l=this.options.chunkSize,b=this.options.dictionary,k=!1;if(this.ended)return!1;g=d===~~d?d:d===!0?u.Z_FINISH:u.Z_NO_FLUSH,typeof h=="string"?t.input=e.binstring2buf(h):a.call(h)==="[object ArrayBuffer]"?t.input=new Uint8Array(h):t.input=h,t.next_in=0,t.avail_in=t.input.length;do{if(t.avail_out===0&&(t.output=new v.Buf8(l),t.next_out=0,t.avail_out=l),(p=S.inflate(t,u.Z_NO_FLUSH))===u.Z_NEED_DICT&&b&&(s=typeof b=="string"?e.string2buf(b):a.call(b)==="[object ArrayBuffer]"?new Uint8Array(b):b,p=S.inflateSetDictionary(this.strm,s)),p===u.Z_BUF_ERROR&&k===!0&&(p=u.Z_OK,k=!1),p!==u.Z_STREAM_END&&p!==u.Z_OK)return this.onEnd(p),!(this.ended=!0);t.next_out&&(t.avail_out!==0&&p!==u.Z_STREAM_END&&(t.avail_in!==0||g!==u.Z_FINISH&&g!==u.Z_SYNC_FLUSH)||(this.options.to==="string"?(w=e.utf8border(t.output,t.next_out),P=t.next_out-w,n=e.buf2string(t.output,w),t.next_out=P,t.avail_out=l-P,P&&v.arraySet(t.output,t.output,w,P,0),this.onData(n)):this.onData(v.shrinkBuf(t.output,t.next_out)))),t.avail_in===0&&t.avail_out===0&&(k=!0)}while((0<t.avail_in||t.avail_out===0)&&p!==u.Z_STREAM_END);return p===u.Z_STREAM_END&&(g=u.Z_FINISH),g===u.Z_FINISH?(p=S.inflateEnd(this.strm),this.onEnd(p),this.ended=!0,p===u.Z_OK):g!==u.Z_SYNC_FLUSH||(this.onEnd(u.Z_OK),!(t.avail_out=0))},i.prototype.onData=function(h){this.chunks.push(h)},i.prototype.onEnd=function(h){h===u.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=v.flattenChunks(this.chunks)),this.chunks=[],this.err=h,this.msg=this.strm.msg},B.Inflate=i,B.inflate=y,B.inflateRaw=function(h,d){return(d=d||{}).raw=!0,y(h,d)},B.ungzip=y},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(T,L,B){var S=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";B.assign=function(u){for(var r=Array.prototype.slice.call(arguments,1);r.length;){var m=r.shift();if(m){if(typeof m!="object")throw new TypeError(m+"must be non-object");for(var f in m)m.hasOwnProperty(f)&&(u[f]=m[f])}}return u},B.shrinkBuf=function(u,r){return u.length===r?u:u.subarray?u.subarray(0,r):(u.length=r,u)};var v={arraySet:function(u,r,m,f,a){if(r.subarray&&u.subarray)u.set(r.subarray(m,m+f),a);else for(var i=0;i<f;i++)u[a+i]=r[m+i]},flattenChunks:function(u){var r,m,f,a,i,y;for(r=f=0,m=u.length;r<m;r++)f+=u[r].length;for(y=new Uint8Array(f),r=a=0,m=u.length;r<m;r++)i=u[r],y.set(i,a),a+=i.length;return y}},e={arraySet:function(u,r,m,f,a){for(var i=0;i<f;i++)u[a+i]=r[m+i]},flattenChunks:function(u){return[].concat.apply([],u)}};B.setTyped=function(u){u?(B.Buf8=Uint8Array,B.Buf16=Uint16Array,B.Buf32=Int32Array,B.assign(B,v)):(B.Buf8=Array,B.Buf16=Array,B.Buf32=Array,B.assign(B,e))},B.setTyped(S)},{}],42:[function(T,L,B){var S=T("./common"),v=!0,e=!0;try{String.fromCharCode.apply(null,[0])}catch{v=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{e=!1}for(var u=new S.Buf8(256),r=0;r<256;r++)u[r]=252<=r?6:248<=r?5:240<=r?4:224<=r?3:192<=r?2:1;function m(f,a){if(a<65537&&(f.subarray&&e||!f.subarray&&v))return String.fromCharCode.apply(null,S.shrinkBuf(f,a));for(var i="",y=0;y<a;y++)i+=String.fromCharCode(f[y]);return i}u[254]=u[254]=1,B.string2buf=function(f){var a,i,y,h,d,p=f.length,g=0;for(h=0;h<p;h++)(64512&(i=f.charCodeAt(h)))==55296&&h+1<p&&(64512&(y=f.charCodeAt(h+1)))==56320&&(i=65536+(i-55296<<10)+(y-56320),h++),g+=i<128?1:i<2048?2:i<65536?3:4;for(a=new S.Buf8(g),h=d=0;d<g;h++)(64512&(i=f.charCodeAt(h)))==55296&&h+1<p&&(64512&(y=f.charCodeAt(h+1)))==56320&&(i=65536+(i-55296<<10)+(y-56320),h++),i<128?a[d++]=i:(i<2048?a[d++]=192|i>>>6:(i<65536?a[d++]=224|i>>>12:(a[d++]=240|i>>>18,a[d++]=128|i>>>12&63),a[d++]=128|i>>>6&63),a[d++]=128|63&i);return a},B.buf2binstring=function(f){return m(f,f.length)},B.binstring2buf=function(f){for(var a=new S.Buf8(f.length),i=0,y=a.length;i<y;i++)a[i]=f.charCodeAt(i);return a},B.buf2string=function(f,a){var i,y,h,d,p=a||f.length,g=new Array(2*p);for(i=y=0;i<p;)if((h=f[i++])<128)g[y++]=h;else if(4<(d=u[h]))g[y++]=65533,i+=d-1;else{for(h&=d===2?31:d===3?15:7;1<d&&i<p;)h=h<<6|63&f[i++],d--;1<d?g[y++]=65533:h<65536?g[y++]=h:(h-=65536,g[y++]=55296|h>>10&1023,g[y++]=56320|1023&h)}return m(g,y)},B.utf8border=function(f,a){var i;for((a=a||f.length)>f.length&&(a=f.length),i=a-1;0<=i&&(192&f[i])==128;)i--;return i<0||i===0?a:i+u[f[i]]>a?i:a}},{"./common":41}],43:[function(T,L,B){L.exports=function(S,v,e,u){for(var r=65535&S|0,m=S>>>16&65535|0,f=0;e!==0;){for(e-=f=2e3<e?2e3:e;m=m+(r=r+v[u++]|0)|0,--f;);r%=65521,m%=65521}return r|m<<16|0}},{}],44:[function(T,L,B){L.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(T,L,B){var S=function(){for(var v,e=[],u=0;u<256;u++){v=u;for(var r=0;r<8;r++)v=1&v?3988292384^v>>>1:v>>>1;e[u]=v}return e}();L.exports=function(v,e,u,r){var m=S,f=r+u;v^=-1;for(var a=r;a<f;a++)v=v>>>8^m[255&(v^e[a])];return-1^v}},{}],46:[function(T,L,B){var S,v=T("../utils/common"),e=T("./trees"),u=T("./adler32"),r=T("./crc32"),m=T("./messages"),f=0,a=4,i=0,y=-2,h=-1,d=4,p=2,g=8,w=9,P=286,n=30,s=19,t=2*P+1,l=15,b=3,k=258,E=k+b+1,_=42,C=113,o=1,R=2,V=3,F=4;function q(c,I){return c.msg=m[I],I}function W(c){return(c<<1)-(4<c?9:0)}function Y(c){for(var I=c.length;0<=--I;)c[I]=0}function z(c){var I=c.state,M=I.pending;M>c.avail_out&&(M=c.avail_out),M!==0&&(v.arraySet(c.output,I.pending_buf,I.pending_out,M,c.next_out),c.next_out+=M,I.pending_out+=M,c.total_out+=M,c.avail_out-=M,I.pending-=M,I.pending===0&&(I.pending_out=0))}function O(c,I){e._tr_flush_block(c,0<=c.block_start?c.block_start:-1,c.strstart-c.block_start,I),c.block_start=c.strstart,z(c.strm)}function J(c,I){c.pending_buf[c.pending++]=I}function X(c,I){c.pending_buf[c.pending++]=I>>>8&255,c.pending_buf[c.pending++]=255&I}function Z(c,I){var M,A,x=c.max_chain_length,D=c.strstart,j=c.prev_length,U=c.nice_match,N=c.strstart>c.w_size-E?c.strstart-(c.w_size-E):0,H=c.window,G=c.w_mask,$=c.prev,K=c.strstart+k,re=H[D+j-1],ee=H[D+j];c.prev_length>=c.good_match&&(x>>=2),U>c.lookahead&&(U=c.lookahead);do if(H[(M=I)+j]===ee&&H[M+j-1]===re&&H[M]===H[D]&&H[++M]===H[D+1]){D+=2,M++;do;while(H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&H[++D]===H[++M]&&D<K);if(A=k-(K-D),D=K-k,j<A){if(c.match_start=I,U<=(j=A))break;re=H[D+j-1],ee=H[D+j]}}while((I=$[I&G])>N&&--x!=0);return j<=c.lookahead?j:c.lookahead}function ae(c){var I,M,A,x,D,j,U,N,H,G,$=c.w_size;do{if(x=c.window_size-c.lookahead-c.strstart,c.strstart>=$+($-E)){for(v.arraySet(c.window,c.window,$,$,0),c.match_start-=$,c.strstart-=$,c.block_start-=$,I=M=c.hash_size;A=c.head[--I],c.head[I]=$<=A?A-$:0,--M;);for(I=M=$;A=c.prev[--I],c.prev[I]=$<=A?A-$:0,--M;);x+=$}if(c.strm.avail_in===0)break;if(j=c.strm,U=c.window,N=c.strstart+c.lookahead,H=x,G=void 0,G=j.avail_in,H<G&&(G=H),M=G===0?0:(j.avail_in-=G,v.arraySet(U,j.input,j.next_in,G,N),j.state.wrap===1?j.adler=u(j.adler,U,G,N):j.state.wrap===2&&(j.adler=r(j.adler,U,G,N)),j.next_in+=G,j.total_in+=G,G),c.lookahead+=M,c.lookahead+c.insert>=b)for(D=c.strstart-c.insert,c.ins_h=c.window[D],c.ins_h=(c.ins_h<<c.hash_shift^c.window[D+1])&c.hash_mask;c.insert&&(c.ins_h=(c.ins_h<<c.hash_shift^c.window[D+b-1])&c.hash_mask,c.prev[D&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=D,D++,c.insert--,!(c.lookahead+c.insert<b)););}while(c.lookahead<E&&c.strm.avail_in!==0)}function le(c,I){for(var M,A;;){if(c.lookahead<E){if(ae(c),c.lookahead<E&&I===f)return o;if(c.lookahead===0)break}if(M=0,c.lookahead>=b&&(c.ins_h=(c.ins_h<<c.hash_shift^c.window[c.strstart+b-1])&c.hash_mask,M=c.prev[c.strstart&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=c.strstart),M!==0&&c.strstart-M<=c.w_size-E&&(c.match_length=Z(c,M)),c.match_length>=b)if(A=e._tr_tally(c,c.strstart-c.match_start,c.match_length-b),c.lookahead-=c.match_length,c.match_length<=c.max_lazy_match&&c.lookahead>=b){for(c.match_length--;c.strstart++,c.ins_h=(c.ins_h<<c.hash_shift^c.window[c.strstart+b-1])&c.hash_mask,M=c.prev[c.strstart&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=c.strstart,--c.match_length!=0;);c.strstart++}else c.strstart+=c.match_length,c.match_length=0,c.ins_h=c.window[c.strstart],c.ins_h=(c.ins_h<<c.hash_shift^c.window[c.strstart+1])&c.hash_mask;else A=e._tr_tally(c,0,c.window[c.strstart]),c.lookahead--,c.strstart++;if(A&&(O(c,!1),c.strm.avail_out===0))return o}return c.insert=c.strstart<b-1?c.strstart:b-1,I===a?(O(c,!0),c.strm.avail_out===0?V:F):c.last_lit&&(O(c,!1),c.strm.avail_out===0)?o:R}function Q(c,I){for(var M,A,x;;){if(c.lookahead<E){if(ae(c),c.lookahead<E&&I===f)return o;if(c.lookahead===0)break}if(M=0,c.lookahead>=b&&(c.ins_h=(c.ins_h<<c.hash_shift^c.window[c.strstart+b-1])&c.hash_mask,M=c.prev[c.strstart&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=c.strstart),c.prev_length=c.match_length,c.prev_match=c.match_start,c.match_length=b-1,M!==0&&c.prev_length<c.max_lazy_match&&c.strstart-M<=c.w_size-E&&(c.match_length=Z(c,M),c.match_length<=5&&(c.strategy===1||c.match_length===b&&4096<c.strstart-c.match_start)&&(c.match_length=b-1)),c.prev_length>=b&&c.match_length<=c.prev_length){for(x=c.strstart+c.lookahead-b,A=e._tr_tally(c,c.strstart-1-c.prev_match,c.prev_length-b),c.lookahead-=c.prev_length-1,c.prev_length-=2;++c.strstart<=x&&(c.ins_h=(c.ins_h<<c.hash_shift^c.window[c.strstart+b-1])&c.hash_mask,M=c.prev[c.strstart&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=c.strstart),--c.prev_length!=0;);if(c.match_available=0,c.match_length=b-1,c.strstart++,A&&(O(c,!1),c.strm.avail_out===0))return o}else if(c.match_available){if((A=e._tr_tally(c,0,c.window[c.strstart-1]))&&O(c,!1),c.strstart++,c.lookahead--,c.strm.avail_out===0)return o}else c.match_available=1,c.strstart++,c.lookahead--}return c.match_available&&(A=e._tr_tally(c,0,c.window[c.strstart-1]),c.match_available=0),c.insert=c.strstart<b-1?c.strstart:b-1,I===a?(O(c,!0),c.strm.avail_out===0?V:F):c.last_lit&&(O(c,!1),c.strm.avail_out===0)?o:R}function te(c,I,M,A,x){this.good_length=c,this.max_lazy=I,this.nice_length=M,this.max_chain=A,this.func=x}function oe(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=g,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new v.Buf16(2*t),this.dyn_dtree=new v.Buf16(2*(2*n+1)),this.bl_tree=new v.Buf16(2*(2*s+1)),Y(this.dyn_ltree),Y(this.dyn_dtree),Y(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new v.Buf16(l+1),this.heap=new v.Buf16(2*P+1),Y(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new v.Buf16(2*P+1),Y(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function se(c){var I;return c&&c.state?(c.total_in=c.total_out=0,c.data_type=p,(I=c.state).pending=0,I.pending_out=0,I.wrap<0&&(I.wrap=-I.wrap),I.status=I.wrap?_:C,c.adler=I.wrap===2?0:1,I.last_flush=f,e._tr_init(I),i):q(c,y)}function de(c){var I=se(c);return I===i&&function(M){M.window_size=2*M.w_size,Y(M.head),M.max_lazy_match=S[M.level].max_lazy,M.good_match=S[M.level].good_length,M.nice_match=S[M.level].nice_length,M.max_chain_length=S[M.level].max_chain,M.strstart=0,M.block_start=0,M.lookahead=0,M.insert=0,M.match_length=M.prev_length=b-1,M.match_available=0,M.ins_h=0}(c.state),I}function he(c,I,M,A,x,D){if(!c)return y;var j=1;if(I===h&&(I=6),A<0?(j=0,A=-A):15<A&&(j=2,A-=16),x<1||w<x||M!==g||A<8||15<A||I<0||9<I||D<0||d<D)return q(c,y);A===8&&(A=9);var U=new oe;return(c.state=U).strm=c,U.wrap=j,U.gzhead=null,U.w_bits=A,U.w_size=1<<U.w_bits,U.w_mask=U.w_size-1,U.hash_bits=x+7,U.hash_size=1<<U.hash_bits,U.hash_mask=U.hash_size-1,U.hash_shift=~~((U.hash_bits+b-1)/b),U.window=new v.Buf8(2*U.w_size),U.head=new v.Buf16(U.hash_size),U.prev=new v.Buf16(U.w_size),U.lit_bufsize=1<<x+6,U.pending_buf_size=4*U.lit_bufsize,U.pending_buf=new v.Buf8(U.pending_buf_size),U.d_buf=1*U.lit_bufsize,U.l_buf=3*U.lit_bufsize,U.level=I,U.strategy=D,U.method=M,de(c)}S=[new te(0,0,0,0,function(c,I){var M=65535;for(M>c.pending_buf_size-5&&(M=c.pending_buf_size-5);;){if(c.lookahead<=1){if(ae(c),c.lookahead===0&&I===f)return o;if(c.lookahead===0)break}c.strstart+=c.lookahead,c.lookahead=0;var A=c.block_start+M;if((c.strstart===0||c.strstart>=A)&&(c.lookahead=c.strstart-A,c.strstart=A,O(c,!1),c.strm.avail_out===0)||c.strstart-c.block_start>=c.w_size-E&&(O(c,!1),c.strm.avail_out===0))return o}return c.insert=0,I===a?(O(c,!0),c.strm.avail_out===0?V:F):(c.strstart>c.block_start&&(O(c,!1),c.strm.avail_out),o)}),new te(4,4,8,4,le),new te(4,5,16,8,le),new te(4,6,32,32,le),new te(4,4,16,16,Q),new te(8,16,32,32,Q),new te(8,16,128,128,Q),new te(8,32,128,256,Q),new te(32,128,258,1024,Q),new te(32,258,258,4096,Q)],B.deflateInit=function(c,I){return he(c,I,g,15,8,0)},B.deflateInit2=he,B.deflateReset=de,B.deflateResetKeep=se,B.deflateSetHeader=function(c,I){return c&&c.state?c.state.wrap!==2?y:(c.state.gzhead=I,i):y},B.deflate=function(c,I){var M,A,x,D;if(!c||!c.state||5<I||I<0)return c?q(c,y):y;if(A=c.state,!c.output||!c.input&&c.avail_in!==0||A.status===666&&I!==a)return q(c,c.avail_out===0?-5:y);if(A.strm=c,M=A.last_flush,A.last_flush=I,A.status===_)if(A.wrap===2)c.adler=0,J(A,31),J(A,139),J(A,8),A.gzhead?(J(A,(A.gzhead.text?1:0)+(A.gzhead.hcrc?2:0)+(A.gzhead.extra?4:0)+(A.gzhead.name?8:0)+(A.gzhead.comment?16:0)),J(A,255&A.gzhead.time),J(A,A.gzhead.time>>8&255),J(A,A.gzhead.time>>16&255),J(A,A.gzhead.time>>24&255),J(A,A.level===9?2:2<=A.strategy||A.level<2?4:0),J(A,255&A.gzhead.os),A.gzhead.extra&&A.gzhead.extra.length&&(J(A,255&A.gzhead.extra.length),J(A,A.gzhead.extra.length>>8&255)),A.gzhead.hcrc&&(c.adler=r(c.adler,A.pending_buf,A.pending,0)),A.gzindex=0,A.status=69):(J(A,0),J(A,0),J(A,0),J(A,0),J(A,0),J(A,A.level===9?2:2<=A.strategy||A.level<2?4:0),J(A,3),A.status=C);else{var j=g+(A.w_bits-8<<4)<<8;j|=(2<=A.strategy||A.level<2?0:A.level<6?1:A.level===6?2:3)<<6,A.strstart!==0&&(j|=32),j+=31-j%31,A.status=C,X(A,j),A.strstart!==0&&(X(A,c.adler>>>16),X(A,65535&c.adler)),c.adler=1}if(A.status===69)if(A.gzhead.extra){for(x=A.pending;A.gzindex<(65535&A.gzhead.extra.length)&&(A.pending!==A.pending_buf_size||(A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),z(c),x=A.pending,A.pending!==A.pending_buf_size));)J(A,255&A.gzhead.extra[A.gzindex]),A.gzindex++;A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),A.gzindex===A.gzhead.extra.length&&(A.gzindex=0,A.status=73)}else A.status=73;if(A.status===73)if(A.gzhead.name){x=A.pending;do{if(A.pending===A.pending_buf_size&&(A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),z(c),x=A.pending,A.pending===A.pending_buf_size)){D=1;break}D=A.gzindex<A.gzhead.name.length?255&A.gzhead.name.charCodeAt(A.gzindex++):0,J(A,D)}while(D!==0);A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),D===0&&(A.gzindex=0,A.status=91)}else A.status=91;if(A.status===91)if(A.gzhead.comment){x=A.pending;do{if(A.pending===A.pending_buf_size&&(A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),z(c),x=A.pending,A.pending===A.pending_buf_size)){D=1;break}D=A.gzindex<A.gzhead.comment.length?255&A.gzhead.comment.charCodeAt(A.gzindex++):0,J(A,D)}while(D!==0);A.gzhead.hcrc&&A.pending>x&&(c.adler=r(c.adler,A.pending_buf,A.pending-x,x)),D===0&&(A.status=103)}else A.status=103;if(A.status===103&&(A.gzhead.hcrc?(A.pending+2>A.pending_buf_size&&z(c),A.pending+2<=A.pending_buf_size&&(J(A,255&c.adler),J(A,c.adler>>8&255),c.adler=0,A.status=C)):A.status=C),A.pending!==0){if(z(c),c.avail_out===0)return A.last_flush=-1,i}else if(c.avail_in===0&&W(I)<=W(M)&&I!==a)return q(c,-5);if(A.status===666&&c.avail_in!==0)return q(c,-5);if(c.avail_in!==0||A.lookahead!==0||I!==f&&A.status!==666){var U=A.strategy===2?function(N,H){for(var G;;){if(N.lookahead===0&&(ae(N),N.lookahead===0)){if(H===f)return o;break}if(N.match_length=0,G=e._tr_tally(N,0,N.window[N.strstart]),N.lookahead--,N.strstart++,G&&(O(N,!1),N.strm.avail_out===0))return o}return N.insert=0,H===a?(O(N,!0),N.strm.avail_out===0?V:F):N.last_lit&&(O(N,!1),N.strm.avail_out===0)?o:R}(A,I):A.strategy===3?function(N,H){for(var G,$,K,re,ee=N.window;;){if(N.lookahead<=k){if(ae(N),N.lookahead<=k&&H===f)return o;if(N.lookahead===0)break}if(N.match_length=0,N.lookahead>=b&&0<N.strstart&&($=ee[K=N.strstart-1])===ee[++K]&&$===ee[++K]&&$===ee[++K]){re=N.strstart+k;do;while($===ee[++K]&&$===ee[++K]&&$===ee[++K]&&$===ee[++K]&&$===ee[++K]&&$===ee[++K]&&$===ee[++K]&&$===ee[++K]&&K<re);N.match_length=k-(re-K),N.match_length>N.lookahead&&(N.match_length=N.lookahead)}if(N.match_length>=b?(G=e._tr_tally(N,1,N.match_length-b),N.lookahead-=N.match_length,N.strstart+=N.match_length,N.match_length=0):(G=e._tr_tally(N,0,N.window[N.strstart]),N.lookahead--,N.strstart++),G&&(O(N,!1),N.strm.avail_out===0))return o}return N.insert=0,H===a?(O(N,!0),N.strm.avail_out===0?V:F):N.last_lit&&(O(N,!1),N.strm.avail_out===0)?o:R}(A,I):S[A.level].func(A,I);if(U!==V&&U!==F||(A.status=666),U===o||U===V)return c.avail_out===0&&(A.last_flush=-1),i;if(U===R&&(I===1?e._tr_align(A):I!==5&&(e._tr_stored_block(A,0,0,!1),I===3&&(Y(A.head),A.lookahead===0&&(A.strstart=0,A.block_start=0,A.insert=0))),z(c),c.avail_out===0))return A.last_flush=-1,i}return I!==a?i:A.wrap<=0?1:(A.wrap===2?(J(A,255&c.adler),J(A,c.adler>>8&255),J(A,c.adler>>16&255),J(A,c.adler>>24&255),J(A,255&c.total_in),J(A,c.total_in>>8&255),J(A,c.total_in>>16&255),J(A,c.total_in>>24&255)):(X(A,c.adler>>>16),X(A,65535&c.adler)),z(c),0<A.wrap&&(A.wrap=-A.wrap),A.pending!==0?i:1)},B.deflateEnd=function(c){var I;return c&&c.state?(I=c.state.status)!==_&&I!==69&&I!==73&&I!==91&&I!==103&&I!==C&&I!==666?q(c,y):(c.state=null,I===C?q(c,-3):i):y},B.deflateSetDictionary=function(c,I){var M,A,x,D,j,U,N,H,G=I.length;if(!c||!c.state||(D=(M=c.state).wrap)===2||D===1&&M.status!==_||M.lookahead)return y;for(D===1&&(c.adler=u(c.adler,I,G,0)),M.wrap=0,G>=M.w_size&&(D===0&&(Y(M.head),M.strstart=0,M.block_start=0,M.insert=0),H=new v.Buf8(M.w_size),v.arraySet(H,I,G-M.w_size,M.w_size,0),I=H,G=M.w_size),j=c.avail_in,U=c.next_in,N=c.input,c.avail_in=G,c.next_in=0,c.input=I,ae(M);M.lookahead>=b;){for(A=M.strstart,x=M.lookahead-(b-1);M.ins_h=(M.ins_h<<M.hash_shift^M.window[A+b-1])&M.hash_mask,M.prev[A&M.w_mask]=M.head[M.ins_h],M.head[M.ins_h]=A,A++,--x;);M.strstart=A,M.lookahead=b-1,ae(M)}return M.strstart+=M.lookahead,M.block_start=M.strstart,M.insert=M.lookahead,M.lookahead=0,M.match_length=M.prev_length=b-1,M.match_available=0,c.next_in=U,c.input=N,c.avail_in=j,M.wrap=D,i},B.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(T,L,B){L.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(T,L,B){L.exports=function(S,v){var e,u,r,m,f,a,i,y,h,d,p,g,w,P,n,s,t,l,b,k,E,_,C,o,R;e=S.state,u=S.next_in,o=S.input,r=u+(S.avail_in-5),m=S.next_out,R=S.output,f=m-(v-S.avail_out),a=m+(S.avail_out-257),i=e.dmax,y=e.wsize,h=e.whave,d=e.wnext,p=e.window,g=e.hold,w=e.bits,P=e.lencode,n=e.distcode,s=(1<<e.lenbits)-1,t=(1<<e.distbits)-1;e:do{w<15&&(g+=o[u++]<<w,w+=8,g+=o[u++]<<w,w+=8),l=P[g&s];t:for(;;){if(g>>>=b=l>>>24,w-=b,(b=l>>>16&255)===0)R[m++]=65535&l;else{if(!(16&b)){if(!(64&b)){l=P[(65535&l)+(g&(1<<b)-1)];continue t}if(32&b){e.mode=12;break e}S.msg="invalid literal/length code",e.mode=30;break e}k=65535&l,(b&=15)&&(w<b&&(g+=o[u++]<<w,w+=8),k+=g&(1<<b)-1,g>>>=b,w-=b),w<15&&(g+=o[u++]<<w,w+=8,g+=o[u++]<<w,w+=8),l=n[g&t];r:for(;;){if(g>>>=b=l>>>24,w-=b,!(16&(b=l>>>16&255))){if(!(64&b)){l=n[(65535&l)+(g&(1<<b)-1)];continue r}S.msg="invalid distance code",e.mode=30;break e}if(E=65535&l,w<(b&=15)&&(g+=o[u++]<<w,(w+=8)<b&&(g+=o[u++]<<w,w+=8)),i<(E+=g&(1<<b)-1)){S.msg="invalid distance too far back",e.mode=30;break e}if(g>>>=b,w-=b,(b=m-f)<E){if(h<(b=E-b)&&e.sane){S.msg="invalid distance too far back",e.mode=30;break e}if(C=p,(_=0)===d){if(_+=y-b,b<k){for(k-=b;R[m++]=p[_++],--b;);_=m-E,C=R}}else if(d<b){if(_+=y+d-b,(b-=d)<k){for(k-=b;R[m++]=p[_++],--b;);if(_=0,d<k){for(k-=b=d;R[m++]=p[_++],--b;);_=m-E,C=R}}}else if(_+=d-b,b<k){for(k-=b;R[m++]=p[_++],--b;);_=m-E,C=R}for(;2<k;)R[m++]=C[_++],R[m++]=C[_++],R[m++]=C[_++],k-=3;k&&(R[m++]=C[_++],1<k&&(R[m++]=C[_++]))}else{for(_=m-E;R[m++]=R[_++],R[m++]=R[_++],R[m++]=R[_++],2<(k-=3););k&&(R[m++]=R[_++],1<k&&(R[m++]=R[_++]))}break}}break}}while(u<r&&m<a);u-=k=w>>3,g&=(1<<(w-=k<<3))-1,S.next_in=u,S.next_out=m,S.avail_in=u<r?r-u+5:5-(u-r),S.avail_out=m<a?a-m+257:257-(m-a),e.hold=g,e.bits=w}},{}],49:[function(T,L,B){var S=T("../utils/common"),v=T("./adler32"),e=T("./crc32"),u=T("./inffast"),r=T("./inftrees"),m=1,f=2,a=0,i=-2,y=1,h=852,d=592;function p(_){return(_>>>24&255)+(_>>>8&65280)+((65280&_)<<8)+((255&_)<<24)}function g(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new S.Buf16(320),this.work=new S.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function w(_){var C;return _&&_.state?(C=_.state,_.total_in=_.total_out=C.total=0,_.msg="",C.wrap&&(_.adler=1&C.wrap),C.mode=y,C.last=0,C.havedict=0,C.dmax=32768,C.head=null,C.hold=0,C.bits=0,C.lencode=C.lendyn=new S.Buf32(h),C.distcode=C.distdyn=new S.Buf32(d),C.sane=1,C.back=-1,a):i}function P(_){var C;return _&&_.state?((C=_.state).wsize=0,C.whave=0,C.wnext=0,w(_)):i}function n(_,C){var o,R;return _&&_.state?(R=_.state,C<0?(o=0,C=-C):(o=1+(C>>4),C<48&&(C&=15)),C&&(C<8||15<C)?i:(R.window!==null&&R.wbits!==C&&(R.window=null),R.wrap=o,R.wbits=C,P(_))):i}function s(_,C){var o,R;return _?(R=new g,(_.state=R).window=null,(o=n(_,C))!==a&&(_.state=null),o):i}var t,l,b=!0;function k(_){if(b){var C;for(t=new S.Buf32(512),l=new S.Buf32(32),C=0;C<144;)_.lens[C++]=8;for(;C<256;)_.lens[C++]=9;for(;C<280;)_.lens[C++]=7;for(;C<288;)_.lens[C++]=8;for(r(m,_.lens,0,288,t,0,_.work,{bits:9}),C=0;C<32;)_.lens[C++]=5;r(f,_.lens,0,32,l,0,_.work,{bits:5}),b=!1}_.lencode=t,_.lenbits=9,_.distcode=l,_.distbits=5}function E(_,C,o,R){var V,F=_.state;return F.window===null&&(F.wsize=1<<F.wbits,F.wnext=0,F.whave=0,F.window=new S.Buf8(F.wsize)),R>=F.wsize?(S.arraySet(F.window,C,o-F.wsize,F.wsize,0),F.wnext=0,F.whave=F.wsize):(R<(V=F.wsize-F.wnext)&&(V=R),S.arraySet(F.window,C,o-R,V,F.wnext),(R-=V)?(S.arraySet(F.window,C,o-R,R,0),F.wnext=R,F.whave=F.wsize):(F.wnext+=V,F.wnext===F.wsize&&(F.wnext=0),F.whave<F.wsize&&(F.whave+=V))),0}B.inflateReset=P,B.inflateReset2=n,B.inflateResetKeep=w,B.inflateInit=function(_){return s(_,15)},B.inflateInit2=s,B.inflate=function(_,C){var o,R,V,F,q,W,Y,z,O,J,X,Z,ae,le,Q,te,oe,se,de,he,c,I,M,A,x=0,D=new S.Buf8(4),j=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!_||!_.state||!_.output||!_.input&&_.avail_in!==0)return i;(o=_.state).mode===12&&(o.mode=13),q=_.next_out,V=_.output,Y=_.avail_out,F=_.next_in,R=_.input,W=_.avail_in,z=o.hold,O=o.bits,J=W,X=Y,I=a;e:for(;;)switch(o.mode){case y:if(o.wrap===0){o.mode=13;break}for(;O<16;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(2&o.wrap&&z===35615){D[o.check=0]=255&z,D[1]=z>>>8&255,o.check=e(o.check,D,2,0),O=z=0,o.mode=2;break}if(o.flags=0,o.head&&(o.head.done=!1),!(1&o.wrap)||(((255&z)<<8)+(z>>8))%31){_.msg="incorrect header check",o.mode=30;break}if((15&z)!=8){_.msg="unknown compression method",o.mode=30;break}if(O-=4,c=8+(15&(z>>>=4)),o.wbits===0)o.wbits=c;else if(c>o.wbits){_.msg="invalid window size",o.mode=30;break}o.dmax=1<<c,_.adler=o.check=1,o.mode=512&z?10:12,O=z=0;break;case 2:for(;O<16;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(o.flags=z,(255&o.flags)!=8){_.msg="unknown compression method",o.mode=30;break}if(57344&o.flags){_.msg="unknown header flags set",o.mode=30;break}o.head&&(o.head.text=z>>8&1),512&o.flags&&(D[0]=255&z,D[1]=z>>>8&255,o.check=e(o.check,D,2,0)),O=z=0,o.mode=3;case 3:for(;O<32;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.head&&(o.head.time=z),512&o.flags&&(D[0]=255&z,D[1]=z>>>8&255,D[2]=z>>>16&255,D[3]=z>>>24&255,o.check=e(o.check,D,4,0)),O=z=0,o.mode=4;case 4:for(;O<16;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.head&&(o.head.xflags=255&z,o.head.os=z>>8),512&o.flags&&(D[0]=255&z,D[1]=z>>>8&255,o.check=e(o.check,D,2,0)),O=z=0,o.mode=5;case 5:if(1024&o.flags){for(;O<16;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.length=z,o.head&&(o.head.extra_len=z),512&o.flags&&(D[0]=255&z,D[1]=z>>>8&255,o.check=e(o.check,D,2,0)),O=z=0}else o.head&&(o.head.extra=null);o.mode=6;case 6:if(1024&o.flags&&(W<(Z=o.length)&&(Z=W),Z&&(o.head&&(c=o.head.extra_len-o.length,o.head.extra||(o.head.extra=new Array(o.head.extra_len)),S.arraySet(o.head.extra,R,F,Z,c)),512&o.flags&&(o.check=e(o.check,R,Z,F)),W-=Z,F+=Z,o.length-=Z),o.length))break e;o.length=0,o.mode=7;case 7:if(2048&o.flags){if(W===0)break e;for(Z=0;c=R[F+Z++],o.head&&c&&o.length<65536&&(o.head.name+=String.fromCharCode(c)),c&&Z<W;);if(512&o.flags&&(o.check=e(o.check,R,Z,F)),W-=Z,F+=Z,c)break e}else o.head&&(o.head.name=null);o.length=0,o.mode=8;case 8:if(4096&o.flags){if(W===0)break e;for(Z=0;c=R[F+Z++],o.head&&c&&o.length<65536&&(o.head.comment+=String.fromCharCode(c)),c&&Z<W;);if(512&o.flags&&(o.check=e(o.check,R,Z,F)),W-=Z,F+=Z,c)break e}else o.head&&(o.head.comment=null);o.mode=9;case 9:if(512&o.flags){for(;O<16;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(z!==(65535&o.check)){_.msg="header crc mismatch",o.mode=30;break}O=z=0}o.head&&(o.head.hcrc=o.flags>>9&1,o.head.done=!0),_.adler=o.check=0,o.mode=12;break;case 10:for(;O<32;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}_.adler=o.check=p(z),O=z=0,o.mode=11;case 11:if(o.havedict===0)return _.next_out=q,_.avail_out=Y,_.next_in=F,_.avail_in=W,o.hold=z,o.bits=O,2;_.adler=o.check=1,o.mode=12;case 12:if(C===5||C===6)break e;case 13:if(o.last){z>>>=7&O,O-=7&O,o.mode=27;break}for(;O<3;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}switch(o.last=1&z,O-=1,3&(z>>>=1)){case 0:o.mode=14;break;case 1:if(k(o),o.mode=20,C!==6)break;z>>>=2,O-=2;break e;case 2:o.mode=17;break;case 3:_.msg="invalid block type",o.mode=30}z>>>=2,O-=2;break;case 14:for(z>>>=7&O,O-=7&O;O<32;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if((65535&z)!=(z>>>16^65535)){_.msg="invalid stored block lengths",o.mode=30;break}if(o.length=65535&z,O=z=0,o.mode=15,C===6)break e;case 15:o.mode=16;case 16:if(Z=o.length){if(W<Z&&(Z=W),Y<Z&&(Z=Y),Z===0)break e;S.arraySet(V,R,F,Z,q),W-=Z,F+=Z,Y-=Z,q+=Z,o.length-=Z;break}o.mode=12;break;case 17:for(;O<14;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(o.nlen=257+(31&z),z>>>=5,O-=5,o.ndist=1+(31&z),z>>>=5,O-=5,o.ncode=4+(15&z),z>>>=4,O-=4,286<o.nlen||30<o.ndist){_.msg="too many length or distance symbols",o.mode=30;break}o.have=0,o.mode=18;case 18:for(;o.have<o.ncode;){for(;O<3;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.lens[j[o.have++]]=7&z,z>>>=3,O-=3}for(;o.have<19;)o.lens[j[o.have++]]=0;if(o.lencode=o.lendyn,o.lenbits=7,M={bits:o.lenbits},I=r(0,o.lens,0,19,o.lencode,0,o.work,M),o.lenbits=M.bits,I){_.msg="invalid code lengths set",o.mode=30;break}o.have=0,o.mode=19;case 19:for(;o.have<o.nlen+o.ndist;){for(;te=(x=o.lencode[z&(1<<o.lenbits)-1])>>>16&255,oe=65535&x,!((Q=x>>>24)<=O);){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(oe<16)z>>>=Q,O-=Q,o.lens[o.have++]=oe;else{if(oe===16){for(A=Q+2;O<A;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(z>>>=Q,O-=Q,o.have===0){_.msg="invalid bit length repeat",o.mode=30;break}c=o.lens[o.have-1],Z=3+(3&z),z>>>=2,O-=2}else if(oe===17){for(A=Q+3;O<A;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}O-=Q,c=0,Z=3+(7&(z>>>=Q)),z>>>=3,O-=3}else{for(A=Q+7;O<A;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}O-=Q,c=0,Z=11+(127&(z>>>=Q)),z>>>=7,O-=7}if(o.have+Z>o.nlen+o.ndist){_.msg="invalid bit length repeat",o.mode=30;break}for(;Z--;)o.lens[o.have++]=c}}if(o.mode===30)break;if(o.lens[256]===0){_.msg="invalid code -- missing end-of-block",o.mode=30;break}if(o.lenbits=9,M={bits:o.lenbits},I=r(m,o.lens,0,o.nlen,o.lencode,0,o.work,M),o.lenbits=M.bits,I){_.msg="invalid literal/lengths set",o.mode=30;break}if(o.distbits=6,o.distcode=o.distdyn,M={bits:o.distbits},I=r(f,o.lens,o.nlen,o.ndist,o.distcode,0,o.work,M),o.distbits=M.bits,I){_.msg="invalid distances set",o.mode=30;break}if(o.mode=20,C===6)break e;case 20:o.mode=21;case 21:if(6<=W&&258<=Y){_.next_out=q,_.avail_out=Y,_.next_in=F,_.avail_in=W,o.hold=z,o.bits=O,u(_,X),q=_.next_out,V=_.output,Y=_.avail_out,F=_.next_in,R=_.input,W=_.avail_in,z=o.hold,O=o.bits,o.mode===12&&(o.back=-1);break}for(o.back=0;te=(x=o.lencode[z&(1<<o.lenbits)-1])>>>16&255,oe=65535&x,!((Q=x>>>24)<=O);){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(te&&!(240&te)){for(se=Q,de=te,he=oe;te=(x=o.lencode[he+((z&(1<<se+de)-1)>>se)])>>>16&255,oe=65535&x,!(se+(Q=x>>>24)<=O);){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}z>>>=se,O-=se,o.back+=se}if(z>>>=Q,O-=Q,o.back+=Q,o.length=oe,te===0){o.mode=26;break}if(32&te){o.back=-1,o.mode=12;break}if(64&te){_.msg="invalid literal/length code",o.mode=30;break}o.extra=15&te,o.mode=22;case 22:if(o.extra){for(A=o.extra;O<A;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.length+=z&(1<<o.extra)-1,z>>>=o.extra,O-=o.extra,o.back+=o.extra}o.was=o.length,o.mode=23;case 23:for(;te=(x=o.distcode[z&(1<<o.distbits)-1])>>>16&255,oe=65535&x,!((Q=x>>>24)<=O);){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(!(240&te)){for(se=Q,de=te,he=oe;te=(x=o.distcode[he+((z&(1<<se+de)-1)>>se)])>>>16&255,oe=65535&x,!(se+(Q=x>>>24)<=O);){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}z>>>=se,O-=se,o.back+=se}if(z>>>=Q,O-=Q,o.back+=Q,64&te){_.msg="invalid distance code",o.mode=30;break}o.offset=oe,o.extra=15&te,o.mode=24;case 24:if(o.extra){for(A=o.extra;O<A;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}o.offset+=z&(1<<o.extra)-1,z>>>=o.extra,O-=o.extra,o.back+=o.extra}if(o.offset>o.dmax){_.msg="invalid distance too far back",o.mode=30;break}o.mode=25;case 25:if(Y===0)break e;if(Z=X-Y,o.offset>Z){if((Z=o.offset-Z)>o.whave&&o.sane){_.msg="invalid distance too far back",o.mode=30;break}ae=Z>o.wnext?(Z-=o.wnext,o.wsize-Z):o.wnext-Z,Z>o.length&&(Z=o.length),le=o.window}else le=V,ae=q-o.offset,Z=o.length;for(Y<Z&&(Z=Y),Y-=Z,o.length-=Z;V[q++]=le[ae++],--Z;);o.length===0&&(o.mode=21);break;case 26:if(Y===0)break e;V[q++]=o.length,Y--,o.mode=21;break;case 27:if(o.wrap){for(;O<32;){if(W===0)break e;W--,z|=R[F++]<<O,O+=8}if(X-=Y,_.total_out+=X,o.total+=X,X&&(_.adler=o.check=o.flags?e(o.check,V,X,q-X):v(o.check,V,X,q-X)),X=Y,(o.flags?z:p(z))!==o.check){_.msg="incorrect data check",o.mode=30;break}O=z=0}o.mode=28;case 28:if(o.wrap&&o.flags){for(;O<32;){if(W===0)break e;W--,z+=R[F++]<<O,O+=8}if(z!==(4294967295&o.total)){_.msg="incorrect length check",o.mode=30;break}O=z=0}o.mode=29;case 29:I=1;break e;case 30:I=-3;break e;case 31:return-4;case 32:default:return i}return _.next_out=q,_.avail_out=Y,_.next_in=F,_.avail_in=W,o.hold=z,o.bits=O,(o.wsize||X!==_.avail_out&&o.mode<30&&(o.mode<27||C!==4))&&E(_,_.output,_.next_out,X-_.avail_out)?(o.mode=31,-4):(J-=_.avail_in,X-=_.avail_out,_.total_in+=J,_.total_out+=X,o.total+=X,o.wrap&&X&&(_.adler=o.check=o.flags?e(o.check,V,X,_.next_out-X):v(o.check,V,X,_.next_out-X)),_.data_type=o.bits+(o.last?64:0)+(o.mode===12?128:0)+(o.mode===20||o.mode===15?256:0),(J==0&&X===0||C===4)&&I===a&&(I=-5),I)},B.inflateEnd=function(_){if(!_||!_.state)return i;var C=_.state;return C.window&&(C.window=null),_.state=null,a},B.inflateGetHeader=function(_,C){var o;return _&&_.state&&2&(o=_.state).wrap?((o.head=C).done=!1,a):i},B.inflateSetDictionary=function(_,C){var o,R=C.length;return _&&_.state?(o=_.state).wrap!==0&&o.mode!==11?i:o.mode===11&&v(1,C,R,0)!==o.check?-3:E(_,C,R,R)?(o.mode=31,-4):(o.havedict=1,a):i},B.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(T,L,B){var S=T("../utils/common"),v=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],e=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],u=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],r=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];L.exports=function(m,f,a,i,y,h,d,p){var g,w,P,n,s,t,l,b,k,E=p.bits,_=0,C=0,o=0,R=0,V=0,F=0,q=0,W=0,Y=0,z=0,O=null,J=0,X=new S.Buf16(16),Z=new S.Buf16(16),ae=null,le=0;for(_=0;_<=15;_++)X[_]=0;for(C=0;C<i;C++)X[f[a+C]]++;for(V=E,R=15;1<=R&&X[R]===0;R--);if(R<V&&(V=R),R===0)return y[h++]=20971520,y[h++]=20971520,p.bits=1,0;for(o=1;o<R&&X[o]===0;o++);for(V<o&&(V=o),_=W=1;_<=15;_++)if(W<<=1,(W-=X[_])<0)return-1;if(0<W&&(m===0||R!==1))return-1;for(Z[1]=0,_=1;_<15;_++)Z[_+1]=Z[_]+X[_];for(C=0;C<i;C++)f[a+C]!==0&&(d[Z[f[a+C]]++]=C);if(t=m===0?(O=ae=d,19):m===1?(O=v,J-=257,ae=e,le-=257,256):(O=u,ae=r,-1),_=o,s=h,q=C=z=0,P=-1,n=(Y=1<<(F=V))-1,m===1&&852<Y||m===2&&592<Y)return 1;for(;;){for(l=_-q,k=d[C]<t?(b=0,d[C]):d[C]>t?(b=ae[le+d[C]],O[J+d[C]]):(b=96,0),g=1<<_-q,o=w=1<<F;y[s+(z>>q)+(w-=g)]=l<<24|b<<16|k|0,w!==0;);for(g=1<<_-1;z&g;)g>>=1;if(g!==0?(z&=g-1,z+=g):z=0,C++,--X[_]==0){if(_===R)break;_=f[a+d[C]]}if(V<_&&(z&n)!==P){for(q===0&&(q=V),s+=o,W=1<<(F=_-q);F+q<R&&!((W-=X[F+q])<=0);)F++,W<<=1;if(Y+=1<<F,m===1&&852<Y||m===2&&592<Y)return 1;y[P=z&n]=V<<24|F<<16|s-h|0}}return z!==0&&(y[s+z]=_-q<<24|64<<16|0),p.bits=V,0}},{"../utils/common":41}],51:[function(T,L,B){L.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(T,L,B){var S=T("../utils/common"),v=0,e=1;function u(x){for(var D=x.length;0<=--D;)x[D]=0}var r=0,m=29,f=256,a=f+1+m,i=30,y=19,h=2*a+1,d=15,p=16,g=7,w=256,P=16,n=17,s=18,t=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],l=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],b=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],k=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],E=new Array(2*(a+2));u(E);var _=new Array(2*i);u(_);var C=new Array(512);u(C);var o=new Array(256);u(o);var R=new Array(m);u(R);var V,F,q,W=new Array(i);function Y(x,D,j,U,N){this.static_tree=x,this.extra_bits=D,this.extra_base=j,this.elems=U,this.max_length=N,this.has_stree=x&&x.length}function z(x,D){this.dyn_tree=x,this.max_code=0,this.stat_desc=D}function O(x){return x<256?C[x]:C[256+(x>>>7)]}function J(x,D){x.pending_buf[x.pending++]=255&D,x.pending_buf[x.pending++]=D>>>8&255}function X(x,D,j){x.bi_valid>p-j?(x.bi_buf|=D<<x.bi_valid&65535,J(x,x.bi_buf),x.bi_buf=D>>p-x.bi_valid,x.bi_valid+=j-p):(x.bi_buf|=D<<x.bi_valid&65535,x.bi_valid+=j)}function Z(x,D,j){X(x,j[2*D],j[2*D+1])}function ae(x,D){for(var j=0;j|=1&x,x>>>=1,j<<=1,0<--D;);return j>>>1}function le(x,D,j){var U,N,H=new Array(d+1),G=0;for(U=1;U<=d;U++)H[U]=G=G+j[U-1]<<1;for(N=0;N<=D;N++){var $=x[2*N+1];$!==0&&(x[2*N]=ae(H[$]++,$))}}function Q(x){var D;for(D=0;D<a;D++)x.dyn_ltree[2*D]=0;for(D=0;D<i;D++)x.dyn_dtree[2*D]=0;for(D=0;D<y;D++)x.bl_tree[2*D]=0;x.dyn_ltree[2*w]=1,x.opt_len=x.static_len=0,x.last_lit=x.matches=0}function te(x){8<x.bi_valid?J(x,x.bi_buf):0<x.bi_valid&&(x.pending_buf[x.pending++]=x.bi_buf),x.bi_buf=0,x.bi_valid=0}function oe(x,D,j,U){var N=2*D,H=2*j;return x[N]<x[H]||x[N]===x[H]&&U[D]<=U[j]}function se(x,D,j){for(var U=x.heap[j],N=j<<1;N<=x.heap_len&&(N<x.heap_len&&oe(D,x.heap[N+1],x.heap[N],x.depth)&&N++,!oe(D,U,x.heap[N],x.depth));)x.heap[j]=x.heap[N],j=N,N<<=1;x.heap[j]=U}function de(x,D,j){var U,N,H,G,$=0;if(x.last_lit!==0)for(;U=x.pending_buf[x.d_buf+2*$]<<8|x.pending_buf[x.d_buf+2*$+1],N=x.pending_buf[x.l_buf+$],$++,U===0?Z(x,N,D):(Z(x,(H=o[N])+f+1,D),(G=t[H])!==0&&X(x,N-=R[H],G),Z(x,H=O(--U),j),(G=l[H])!==0&&X(x,U-=W[H],G)),$<x.last_lit;);Z(x,w,D)}function he(x,D){var j,U,N,H=D.dyn_tree,G=D.stat_desc.static_tree,$=D.stat_desc.has_stree,K=D.stat_desc.elems,re=-1;for(x.heap_len=0,x.heap_max=h,j=0;j<K;j++)H[2*j]!==0?(x.heap[++x.heap_len]=re=j,x.depth[j]=0):H[2*j+1]=0;for(;x.heap_len<2;)H[2*(N=x.heap[++x.heap_len]=re<2?++re:0)]=1,x.depth[N]=0,x.opt_len--,$&&(x.static_len-=G[2*N+1]);for(D.max_code=re,j=x.heap_len>>1;1<=j;j--)se(x,H,j);for(N=K;j=x.heap[1],x.heap[1]=x.heap[x.heap_len--],se(x,H,1),U=x.heap[1],x.heap[--x.heap_max]=j,x.heap[--x.heap_max]=U,H[2*N]=H[2*j]+H[2*U],x.depth[N]=(x.depth[j]>=x.depth[U]?x.depth[j]:x.depth[U])+1,H[2*j+1]=H[2*U+1]=N,x.heap[1]=N++,se(x,H,1),2<=x.heap_len;);x.heap[--x.heap_max]=x.heap[1],function(ee,ue){var me,pe,ge,ie,ye,we,fe=ue.dyn_tree,Se=ue.max_code,Te=ue.stat_desc.static_tree,Ee=ue.stat_desc.has_stree,De=ue.stat_desc.extra_bits,Ae=ue.stat_desc.extra_base,be=ue.stat_desc.max_length,ve=0;for(ie=0;ie<=d;ie++)ee.bl_count[ie]=0;for(fe[2*ee.heap[ee.heap_max]+1]=0,me=ee.heap_max+1;me<h;me++)be<(ie=fe[2*fe[2*(pe=ee.heap[me])+1]+1]+1)&&(ie=be,ve++),fe[2*pe+1]=ie,Se<pe||(ee.bl_count[ie]++,ye=0,Ae<=pe&&(ye=De[pe-Ae]),we=fe[2*pe],ee.opt_len+=we*(ie+ye),Ee&&(ee.static_len+=we*(Te[2*pe+1]+ye)));if(ve!==0){do{for(ie=be-1;ee.bl_count[ie]===0;)ie--;ee.bl_count[ie]--,ee.bl_count[ie+1]+=2,ee.bl_count[be]--,ve-=2}while(0<ve);for(ie=be;ie!==0;ie--)for(pe=ee.bl_count[ie];pe!==0;)Se<(ge=ee.heap[--me])||(fe[2*ge+1]!==ie&&(ee.opt_len+=(ie-fe[2*ge+1])*fe[2*ge],fe[2*ge+1]=ie),pe--)}}(x,D),le(H,re,x.bl_count)}function c(x,D,j){var U,N,H=-1,G=D[1],$=0,K=7,re=4;for(G===0&&(K=138,re=3),D[2*(j+1)+1]=65535,U=0;U<=j;U++)N=G,G=D[2*(U+1)+1],++$<K&&N===G||($<re?x.bl_tree[2*N]+=$:N!==0?(N!==H&&x.bl_tree[2*N]++,x.bl_tree[2*P]++):$<=10?x.bl_tree[2*n]++:x.bl_tree[2*s]++,H=N,re=($=0)===G?(K=138,3):N===G?(K=6,3):(K=7,4))}function I(x,D,j){var U,N,H=-1,G=D[1],$=0,K=7,re=4;for(G===0&&(K=138,re=3),U=0;U<=j;U++)if(N=G,G=D[2*(U+1)+1],!(++$<K&&N===G)){if($<re)for(;Z(x,N,x.bl_tree),--$!=0;);else N!==0?(N!==H&&(Z(x,N,x.bl_tree),$--),Z(x,P,x.bl_tree),X(x,$-3,2)):$<=10?(Z(x,n,x.bl_tree),X(x,$-3,3)):(Z(x,s,x.bl_tree),X(x,$-11,7));H=N,re=($=0)===G?(K=138,3):N===G?(K=6,3):(K=7,4)}}u(W);var M=!1;function A(x,D,j,U){X(x,(r<<1)+(U?1:0),3),function(N,H,G,$){te(N),$&&(J(N,G),J(N,~G)),S.arraySet(N.pending_buf,N.window,H,G,N.pending),N.pending+=G}(x,D,j,!0)}B._tr_init=function(x){M||(function(){var D,j,U,N,H,G=new Array(d+1);for(N=U=0;N<m-1;N++)for(R[N]=U,D=0;D<1<<t[N];D++)o[U++]=N;for(o[U-1]=N,N=H=0;N<16;N++)for(W[N]=H,D=0;D<1<<l[N];D++)C[H++]=N;for(H>>=7;N<i;N++)for(W[N]=H<<7,D=0;D<1<<l[N]-7;D++)C[256+H++]=N;for(j=0;j<=d;j++)G[j]=0;for(D=0;D<=143;)E[2*D+1]=8,D++,G[8]++;for(;D<=255;)E[2*D+1]=9,D++,G[9]++;for(;D<=279;)E[2*D+1]=7,D++,G[7]++;for(;D<=287;)E[2*D+1]=8,D++,G[8]++;for(le(E,a+1,G),D=0;D<i;D++)_[2*D+1]=5,_[2*D]=ae(D,5);V=new Y(E,t,f+1,a,d),F=new Y(_,l,0,i,d),q=new Y(new Array(0),b,0,y,g)}(),M=!0),x.l_desc=new z(x.dyn_ltree,V),x.d_desc=new z(x.dyn_dtree,F),x.bl_desc=new z(x.bl_tree,q),x.bi_buf=0,x.bi_valid=0,Q(x)},B._tr_stored_block=A,B._tr_flush_block=function(x,D,j,U){var N,H,G=0;0<x.level?(x.strm.data_type===2&&(x.strm.data_type=function($){var K,re=4093624447;for(K=0;K<=31;K++,re>>>=1)if(1&re&&$.dyn_ltree[2*K]!==0)return v;if($.dyn_ltree[18]!==0||$.dyn_ltree[20]!==0||$.dyn_ltree[26]!==0)return e;for(K=32;K<f;K++)if($.dyn_ltree[2*K]!==0)return e;return v}(x)),he(x,x.l_desc),he(x,x.d_desc),G=function($){var K;for(c($,$.dyn_ltree,$.l_desc.max_code),c($,$.dyn_dtree,$.d_desc.max_code),he($,$.bl_desc),K=y-1;3<=K&&$.bl_tree[2*k[K]+1]===0;K--);return $.opt_len+=3*(K+1)+5+5+4,K}(x),N=x.opt_len+3+7>>>3,(H=x.static_len+3+7>>>3)<=N&&(N=H)):N=H=j+5,j+4<=N&&D!==-1?A(x,D,j,U):x.strategy===4||H===N?(X(x,2+(U?1:0),3),de(x,E,_)):(X(x,4+(U?1:0),3),function($,K,re,ee){var ue;for(X($,K-257,5),X($,re-1,5),X($,ee-4,4),ue=0;ue<ee;ue++)X($,$.bl_tree[2*k[ue]+1],3);I($,$.dyn_ltree,K-1),I($,$.dyn_dtree,re-1)}(x,x.l_desc.max_code+1,x.d_desc.max_code+1,G+1),de(x,x.dyn_ltree,x.dyn_dtree)),Q(x),U&&te(x)},B._tr_tally=function(x,D,j){return x.pending_buf[x.d_buf+2*x.last_lit]=D>>>8&255,x.pending_buf[x.d_buf+2*x.last_lit+1]=255&D,x.pending_buf[x.l_buf+x.last_lit]=255&j,x.last_lit++,D===0?x.dyn_ltree[2*j]++:(x.matches++,D--,x.dyn_ltree[2*(o[j]+f+1)]++,x.dyn_dtree[2*O(D)]++),x.last_lit===x.lit_bufsize-1},B._tr_align=function(x){X(x,2,3),Z(x,w,E),function(D){D.bi_valid===16?(J(D,D.bi_buf),D.bi_buf=0,D.bi_valid=0):8<=D.bi_valid&&(D.pending_buf[D.pending++]=255&D.bi_buf,D.bi_buf>>=8,D.bi_valid-=8)}(x)}},{"../utils/common":41}],53:[function(T,L,B){L.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(T,L,B){(function(S){(function(v,e){if(!v.setImmediate){var u,r,m,f,a=1,i={},y=!1,h=v.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(v);d=d&&d.setTimeout?d:v,u={}.toString.call(v.process)==="[object process]"?function(P){process.nextTick(function(){g(P)})}:function(){if(v.postMessage&&!v.importScripts){var P=!0,n=v.onmessage;return v.onmessage=function(){P=!1},v.postMessage("","*"),v.onmessage=n,P}}()?(f="setImmediate$"+Math.random()+"$",v.addEventListener?v.addEventListener("message",w,!1):v.attachEvent("onmessage",w),function(P){v.postMessage(f+P,"*")}):v.MessageChannel?((m=new MessageChannel).port1.onmessage=function(P){g(P.data)},function(P){m.port2.postMessage(P)}):h&&"onreadystatechange"in h.createElement("script")?(r=h.documentElement,function(P){var n=h.createElement("script");n.onreadystatechange=function(){g(P),n.onreadystatechange=null,r.removeChild(n),n=null},r.appendChild(n)}):function(P){setTimeout(g,0,P)},d.setImmediate=function(P){typeof P!="function"&&(P=new Function(""+P));for(var n=new Array(arguments.length-1),s=0;s<n.length;s++)n[s]=arguments[s+1];var t={callback:P,args:n};return i[a]=t,u(a),a++},d.clearImmediate=p}function p(P){delete i[P]}function g(P){if(y)setTimeout(g,0,P);else{var n=i[P];if(n){y=!0;try{(function(s){var t=s.callback,l=s.args;switch(l.length){case 0:t();break;case 1:t(l[0]);break;case 2:t(l[0],l[1]);break;case 3:t(l[0],l[1],l[2]);break;default:t.apply(e,l)}})(n)}finally{p(P),y=!1}}}}function w(P){P.source===v&&typeof P.data=="string"&&P.data.indexOf(f)===0&&g(+P.data.slice(f.length))}})(typeof self>"u"?S===void 0?this:S:self)}).call(this,typeof _e<"u"?_e:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})}(xe)),xe.exports}(function(ne,ce){(function(T,L){ne.exports=L(Be())})(globalThis,T=>(()=>{var L={438:(v,e,u)=>{u.r(e),u.d(e,{default:()=>g});var r=u(537),m=u.n(r),f=u(645),a=u.n(f),i=u(806),y=u.n(i),h=new URL(u(583),u.b),d=a()(m()),p=y()(h);d.push([v.id,`@namespace "http://www.w3.org/1998/Math/MathML";math{display:inline-block;line-height:initial}mfrac{display:inline-block;vertical-align:-50%;text-align:center}mfrac>:first-child{border-bottom:solid thin currentColor}mfrac>*{display:block}msub>:nth-child(2){font-size:smaller;vertical-align:sub}msup>:nth-child(2){font-size:smaller;vertical-align:super}munder,mover,munderover{display:inline-flex;flex-flow:column nowrap;vertical-align:middle;text-align:center}munder>:not(:first-child),mover>:not(:first-child),munderover>:not(:first-child){font-size:smaller}munderover>:last-child{order:-1}mroot,msqrt{position:relative;display:inline-block;border-top:solid thin currentColor;margin-top:.5px;vertical-align:middle;margin-left:1ch}mroot:before,msqrt:before{content:"";display:inline-block;position:absolute;width:1ch;left:-1ch;top:-1px;bottom:0;background-image:url(${p})}`,"",{version:3,sources:["webpack://./src/mathml.scss"],names:[],mappings:"AAAA,+CAAA,CAEA,KACI,oBAAA,CACA,mBAAA,CAGJ,MACI,oBAAA,CACA,mBAAA,CACA,iBAAA,CAEA,mBACI,qCAAA,CAGJ,QACI,aAAA,CAKJ,mBACI,iBAAA,CACA,kBAAA,CAKJ,mBACI,iBAAA,CACA,oBAAA,CAIR,wBACI,mBAAA,CACA,uBAAA,CACA,qBAAA,CACA,iBAAA,CAEA,iFACI,iBAAA,CAKJ,uBAAA,QAAA,CAGJ,YACI,iBAAA,CACA,oBAAA,CACA,kCAAA,CACA,eAAA,CACA,qBAAA,CACA,eAAA,CAEA,0BACI,UAAA,CACA,oBAAA,CACA,iBAAA,CACA,SAAA,CACA,SAAA,CACA,QAAA,CACA,QAAA,CACA,wDAAA",sourcesContent:[`@namespace "http://www.w3.org/1998/Math/MathML";\r
\r
math {\r
display: inline-block;\r
line-height: initial;\r
}\r
\r
mfrac {\r
display: inline-block;\r
vertical-align: -50%;\r
text-align: center;\r
\r
&>:first-child {\r
border-bottom: solid thin currentColor;\r
}\r
\r
&>* {\r
display: block;\r
}\r
}\r
\r
msub {\r
&>:nth-child(2) {\r
font-size: smaller;\r
vertical-align: sub;\r
}\r
}\r
\r
msup {\r
&>:nth-child(2) {\r
font-size: smaller;\r
vertical-align: super;\r
}\r
}\r
\r
munder, mover, munderover {\r
display: inline-flex;\r
flex-flow: column nowrap;\r
vertical-align: middle;\r
text-align: center;\r
\r
&>:not(:first-child) {\r
font-size: smaller;\r
}\r
}\r
\r
munderover {\r
&>:last-child { order: -1; }\r
}\r
\r
mroot, msqrt {\r
position: relative;\r
display: inline-block;\r
border-top: solid thin currentColor; \r
margin-top: 0.5px;\r
vertical-align: middle; \r
margin-left: 1ch; \r
\r
&:before {\r
content: "";\r
display: inline-block;\r
position: absolute;\r
width: 1ch;\r
left: -1ch;\r
top: -1px;\r
bottom: 0;\r
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 100' preserveAspectRatio='none'%3E%3Cpath d='m0,75 l5,0 l5,25 l10,-100' stroke='black' fill='none' vector-effect='non-scaling-stroke'/%3E%3C/svg%3E");\r
}\r
}`],sourceRoot:""}]);const g=d.toString()},645:v=>{v.exports=function(e){var u=[];return u.toString=function(){return this.map(function(r){var m="",f=r[5]!==void 0;return r[4]&&(m+="@supports (".concat(r[4],") {")),r[2]&&(m+="@media ".concat(r[2]," {")),f&&(m+="@layer".concat(r[5].length>0?" ".concat(r[5]):""," {")),m+=e(r),f&&(m+="}"),r[2]&&(m+="}"),r[4]&&(m+="}"),m}).join("")},u.i=function(r,m,f,a,i){typeof r=="string"&&(r=[[null,r,void 0]]);var y={};if(f)for(var h=0;h<this.length;h++){var d=this[h][0];d!=null&&(y[d]=!0)}for(var p=0;p<r.length;p++){var g=[].concat(r[p]);f&&y[g[0]]||(i!==void 0&&(g[5]===void 0||(g[1]="@layer".concat(g[5].length>0?" ".concat(g[5]):""," {").concat(g[1],"}")),g[5]=i),m&&(g[2]&&(g[1]="@media ".concat(g[2]," {").concat(g[1],"}")),g[2]=m),a&&(g[4]?(g[1]="@supports (".concat(g[4],") {").concat(g[1],"}"),g[4]=a):g[4]="".concat(a)),u.push(g))}},u}},806:v=>{v.exports=function(e,u){return u||(u={}),e&&(e=String(e.__esModule?e.default:e),/^['"].*['"]$/.test(e)&&(e=e.slice(1,-1)),u.hash&&(e+=u.hash),/["'() \t\n]|(%20)/.test(e)||u.needQuotes?'"'.concat(e.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):e)}},537:v=>{v.exports=function(e){var u=e[1],r=e[3];if(!r)return u;if(typeof btoa=="function"){var m=btoa(unescape(encodeURIComponent(JSON.stringify(r)))),f="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(m),a="/*# ".concat(f," */");return[u].concat([a]).join(`
`)}return[u].join(`
`)}},522:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.OpenXmlPackage=void 0;const r=u(626),m=u(472),f=u(593),a=u(461);class i{constructor(h,d){this._zip=h,this.options=d,this.xmlParser=new m.XmlParser}get(h){return this._zip.files[function(d){return d.startsWith("/")?d.substr(1):d}(h)]}update(h,d){this._zip.file(h,d)}static async load(h,d){const p=await r.loadAsync(h);return new i(p,d)}save(h="blob"){return this._zip.generateAsync({type:h})}load(h,d="string"){var p,g;return(g=(p=this.get(h))===null||p===void 0?void 0:p.async(d))!==null&&g!==void 0?g:Promise.resolve(null)}async loadRelationships(h=null){let d="_rels/.rels";if(h!=null){const[g,w]=(0,f.splitPath)(h);d=`${g}_rels/${w}.rels`}const p=await this.load(d);return p?(0,a.parseRelationships)(this.parseXmlDocument(p).firstElementChild,this.xmlParser):null}parseXmlDocument(h){return(0,m.parseXmlString)(h,this.options.trimXmlDeclaration)}}e.OpenXmlPackage=i},530:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.Part=void 0;const r=u(472);e.Part=class{constructor(m,f){this._package=m,this.path=f}async load(){this.rels=await this._package.loadRelationships(this.path);const m=await this._package.load(this.path),f=this._package.parseXmlDocument(m);this._package.options.keepOrigin&&(this._xmlDocument=f),this.parseXml(f.firstElementChild)}save(){this._package.update(this.path,(0,r.serializeXmlString)(this._xmlDocument))}parseXml(m){}}},461:(v,e)=>{var u;Object.defineProperty(e,"__esModule",{value:!0}),e.parseRelationships=e.RelationshipTypes=void 0,function(r){r.OfficeDocument="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",r.FontTable="http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",r.Image="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",r.Numbering="http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering",r.Styles="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",r.StylesWithEffects="http://schemas.microsoft.com/office/2007/relationships/stylesWithEffects",r.Theme="http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",r.Settings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings",r.WebSettings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings",r.Hyperlink="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",r.Footnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes",r.Endnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/endnotes",r.Footer="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer",r.Header="http://schemas.openxmlformats.org/officeDocument/2006/relationships/header",r.ExtendedProperties="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",r.CoreProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",r.CustomProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/custom-properties"}(u||(e.RelationshipTypes=u={})),e.parseRelationships=function(r,m){return m.elements(r).map(f=>({id:m.attr(f,"Id"),type:m.attr(f,"Type"),target:m.attr(f,"Target"),targetMode:m.attr(f,"TargetMode")}))}},168:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.DocumentParser=e.autos=void 0;const r=u(120),m=u(109),f=u(59),a=u(472),i=u(488),y=u(172),h=u(149),d=u(320);e.autos={shd:"inherit",color:"black",borderColor:"black",highlight:"transparent"};const p=[],g={oMath:r.DomType.MmlMath,oMathPara:r.DomType.MmlMathParagraph,f:r.DomType.MmlFraction,func:r.DomType.MmlFunction,fName:r.DomType.MmlFunctionName,num:r.DomType.MmlNumerator,den:r.DomType.MmlDenominator,rad:r.DomType.MmlRadical,deg:r.DomType.MmlDegree,e:r.DomType.MmlBase,sSup:r.DomType.MmlSuperscript,sSub:r.DomType.MmlSubscript,sPre:r.DomType.MmlPreSubSuper,sup:r.DomType.MmlSuperArgument,sub:r.DomType.MmlSubArgument,d:r.DomType.MmlDelimiter,nary:r.DomType.MmlNary,eqArr:r.DomType.MmlEquationArray,lim:r.DomType.MmlLimit,limLow:r.DomType.MmlLimitLower,m:r.DomType.MmlMatrix,mr:r.DomType.MmlMatrixRow,box:r.DomType.MmlBox,bar:r.DomType.MmlBar,groupChr:r.DomType.MmlGroupChar};e.DocumentParser=class{constructor(s){this.options=Object.assign({ignoreWidth:!1,debug:!1},s)}parseNotes(s,t,l){var b=[];for(let k of a.default.elements(s,t)){const E=new l;E.id=a.default.attr(k,"id"),E.noteType=a.default.attr(k,"type"),E.children=this.parseBodyElements(k),b.push(E)}return b}parseDocumentFile(s){var t=a.default.element(s,"body"),l=a.default.element(s,"background"),b=a.default.element(t,"sectPr");return{type:r.DomType.Document,children:this.parseBodyElements(t),props:b?(0,f.parseSectionProperties)(b,a.default):{},cssStyle:l?this.parseBackground(l):{}}}parseBackground(s){var t={},l=P.colorAttr(s,"color");return l&&(t["background-color"]=l),t}parseBodyElements(s){var t=[];for(let l of a.default.elements(s))switch(l.localName){case"p":t.push(this.parseParagraph(l));break;case"tbl":t.push(this.parseTable(l));break;case"sdt":t.push(...this.parseSdt(l,b=>this.parseBodyElements(b)))}return t}parseStylesFile(s){var t=[];return P.foreach(s,l=>{switch(l.localName){case"style":t.push(this.parseStyle(l));break;case"docDefaults":t.push(this.parseDefaultStyles(l))}}),t}parseDefaultStyles(s){var t={id:null,name:null,target:null,basedOn:null,styles:[]};return P.foreach(s,l=>{switch(l.localName){case"rPrDefault":var b=a.default.element(l,"rPr");b&&t.styles.push({target:"span",values:this.parseDefaultProperties(b,{})});break;case"pPrDefault":var k=a.default.element(l,"pPr");k&&t.styles.push({target:"p",values:this.parseDefaultProperties(k,{})})}}),t}parseStyle(s){var t={id:a.default.attr(s,"styleId"),isDefault:a.default.boolAttr(s,"default"),name:null,target:null,basedOn:null,styles:[],linked:null};switch(a.default.attr(s,"type")){case"paragraph":t.target="p";break;case"table":t.target="table";break;case"character":t.target="span"}return P.foreach(s,l=>{switch(l.localName){case"basedOn":t.basedOn=a.default.attr(l,"val");break;case"name":t.name=a.default.attr(l,"val");break;case"link":t.linked=a.default.attr(l,"val");break;case"next":t.next=a.default.attr(l,"val");break;case"aliases":t.aliases=a.default.attr(l,"val").split(",");break;case"pPr":t.styles.push({target:"p",values:this.parseDefaultProperties(l,{})}),t.paragraphProps=(0,m.parseParagraphProperties)(l,a.default);break;case"rPr":t.styles.push({target:"span",values:this.parseDefaultProperties(l,{})}),t.runProps=(0,i.parseRunProperties)(l,a.default);break;case"tblPr":case"tcPr":t.styles.push({target:"td",values:this.parseDefaultProperties(l,{})});break;case"tblStylePr":for(let b of this.parseTableStyle(l))t.styles.push(b);break;case"rsid":case"qFormat":case"hidden":case"semiHidden":case"unhideWhenUsed":case"autoRedefine":case"uiPriority":break;default:this.options.debug&&console.warn(`DOCX: Unknown style element: ${l.localName}`)}}),t}parseTableStyle(s){var t=[],l=a.default.attr(s,"type"),b="",k="";switch(l){case"firstRow":k=".first-row",b="tr.first-row td";break;case"lastRow":k=".last-row",b="tr.last-row td";break;case"firstCol":k=".first-col",b="td.first-col";break;case"lastCol":k=".last-col",b="td.last-col";break;case"band1Vert":k=":not(.no-vband)",b="td.odd-col";break;case"band2Vert":k=":not(.no-vband)",b="td.even-col";break;case"band1Horz":k=":not(.no-hband)",b="tr.odd-row";break;case"band2Horz":k=":not(.no-hband)",b="tr.even-row";break;default:return[]}return P.foreach(s,E=>{switch(E.localName){case"pPr":t.push({target:`${b} p`,mod:k,values:this.parseDefaultProperties(E,{})});break;case"rPr":t.push({target:`${b} span`,mod:k,values:this.parseDefaultProperties(E,{})});break;case"tblPr":case"tcPr":t.push({target:b,mod:k,values:this.parseDefaultProperties(E,{})})}}),t}parseNumberingFile(s){var t=[],l={},b=[];return P.foreach(s,k=>{switch(k.localName){case"abstractNum":this.parseAbstractNumbering(k,b).forEach(C=>t.push(C));break;case"numPicBullet":b.push(this.parseNumberingPicBullet(k));break;case"num":var E=a.default.attr(k,"numId"),_=a.default.elementAttr(k,"abstractNumId","val");l[_]=E}}),t.forEach(k=>k.id=l[k.id]),t}parseNumberingPicBullet(s){var t=a.default.element(s,"pict"),l=t&&a.default.element(t,"shape"),b=l&&a.default.element(l,"imagedata");return b?{id:a.default.intAttr(s,"numPicBulletId"),src:a.default.attr(b,"id"),style:a.default.attr(l,"style")}:null}parseAbstractNumbering(s,t){var l=[],b=a.default.attr(s,"abstractNumId");return P.foreach(s,k=>{k.localName==="lvl"&&l.push(this.parseNumberingLevel(b,k,t))}),l}parseNumberingLevel(s,t,l){var b={id:s,level:a.default.intAttr(t,"ilvl"),start:1,pStyleName:void 0,pStyle:{},rStyle:{},suff:"tab"};return P.foreach(t,k=>{switch(k.localName){case"start":b.start=a.default.intAttr(k,"val");break;case"pPr":this.parseDefaultProperties(k,b.pStyle);break;case"rPr":this.parseDefaultProperties(k,b.rStyle);break;case"lvlPicBulletId":var E=a.default.intAttr(k,"val");b.bullet=l.find(_=>_.id==E);break;case"lvlText":b.levelText=a.default.attr(k,"val");break;case"pStyle":b.pStyleName=a.default.attr(k,"val");break;case"numFmt":b.format=a.default.attr(k,"val");break;case"suff":b.suff=a.default.attr(k,"val")}}),b}parseSdt(s,t){const l=a.default.element(s,"sdtContent");return l?t(l):[]}parseInserted(s,t){var l,b;return{type:r.DomType.Inserted,children:(b=(l=t(s))===null||l===void 0?void 0:l.children)!==null&&b!==void 0?b:[]}}parseDeleted(s,t){var l,b;return{type:r.DomType.Deleted,children:(b=(l=t(s))===null||l===void 0?void 0:l.children)!==null&&b!==void 0?b:[]}}parseParagraph(s){var t={type:r.DomType.Paragraph,children:[]};for(let l of a.default.elements(s))switch(l.localName){case"pPr":this.parseParagraphProperties(l,t);break;case"r":t.children.push(this.parseRun(l,t));break;case"hyperlink":t.children.push(this.parseHyperlink(l,t));break;case"bookmarkStart":t.children.push((0,y.parseBookmarkStart)(l,a.default));break;case"bookmarkEnd":t.children.push((0,y.parseBookmarkEnd)(l,a.default));break;case"oMath":case"oMathPara":t.children.push(this.parseMathElement(l));break;case"sdt":t.children.push(...this.parseSdt(l,b=>this.parseParagraph(b).children));break;case"ins":t.children.push(this.parseInserted(l,b=>this.parseParagraph(b)));break;case"del":t.children.push(this.parseDeleted(l,b=>this.parseParagraph(b)))}return t}parseParagraphProperties(s,t){this.parseDefaultProperties(s,t.cssStyle={},null,l=>{if((0,m.parseParagraphProperty)(l,t,a.default))return!0;switch(l.localName){case"pStyle":t.styleName=a.default.attr(l,"val");break;case"cnfStyle":t.className=n.classNameOfCnfStyle(l);break;case"framePr":this.parseFrame(l,t);break;case"rPr":break;default:return!1}return!0})}parseFrame(s,t){a.default.attr(s,"dropCap")=="drop"&&(t.cssStyle.float="left")}parseHyperlink(s,t){var l={type:r.DomType.Hyperlink,parent:t,children:[]},b=a.default.attr(s,"anchor"),k=a.default.attr(s,"id");return b&&(l.href="#"+b),k&&(l.id=k),P.foreach(s,E=>{E.localName==="r"&&l.children.push(this.parseRun(E,l))}),l}parseRun(s,t){var l={type:r.DomType.Run,parent:t,children:[]};return P.foreach(s,b=>{switch((b=this.checkAlternateContent(b)).localName){case"t":l.children.push({type:r.DomType.Text,text:b.textContent});break;case"delText":l.children.push({type:r.DomType.DeletedText,text:b.textContent});break;case"fldSimple":l.children.push({type:r.DomType.SimpleField,instruction:a.default.attr(b,"instr"),lock:a.default.boolAttr(b,"lock",!1),dirty:a.default.boolAttr(b,"dirty",!1)});break;case"instrText":l.fieldRun=!0,l.children.push({type:r.DomType.Instruction,text:b.textContent});break;case"fldChar":l.fieldRun=!0,l.children.push({type:r.DomType.ComplexField,charType:a.default.attr(b,"fldCharType"),lock:a.default.boolAttr(b,"lock",!1),dirty:a.default.boolAttr(b,"dirty",!1)});break;case"noBreakHyphen":l.children.push({type:r.DomType.NoBreakHyphen});break;case"br":l.children.push({type:r.DomType.Break,break:a.default.attr(b,"type")||"textWrapping"});break;case"lastRenderedPageBreak":l.children.push({type:r.DomType.Break,break:"lastRenderedPageBreak"});break;case"sym":l.children.push({type:r.DomType.Symbol,font:a.default.attr(b,"font"),char:a.default.attr(b,"char")});break;case"tab":l.children.push({type:r.DomType.Tab});break;case"footnoteReference":l.children.push({type:r.DomType.FootnoteReference,id:a.default.attr(b,"id")});break;case"endnoteReference":l.children.push({type:r.DomType.EndnoteReference,id:a.default.attr(b,"id")});break;case"drawing":let k=this.parseDrawing(b);k&&(l.children=[k]);break;case"pict":l.children.push(this.parseVmlPicture(b));break;case"rPr":this.parseRunProperties(b,l)}}),l}parseMathElement(s){const t=`${s.localName}Pr`,l={type:g[s.localName],children:[]};for(const k of a.default.elements(s))if(g[k.localName])l.children.push(this.parseMathElement(k));else if(k.localName=="r"){var b=this.parseRun(k);b.type=r.DomType.MmlRun,l.children.push(b)}else k.localName==t&&(l.props=this.parseMathProperies(k));return l}parseMathProperies(s){const t={};for(const l of a.default.elements(s))switch(l.localName){case"chr":t.char=a.default.attr(l,"val");break;case"vertJc":t.verticalJustification=a.default.attr(l,"val");break;case"pos":t.position=a.default.attr(l,"val");break;case"degHide":t.hideDegree=a.default.boolAttr(l,"val");break;case"begChr":t.beginChar=a.default.attr(l,"val");break;case"endChr":t.endChar=a.default.attr(l,"val")}return t}parseRunProperties(s,t){this.parseDefaultProperties(s,t.cssStyle={},null,l=>{switch(l.localName){case"rStyle":t.styleName=a.default.attr(l,"val");break;case"vertAlign":t.verticalAlign=n.valueOfVertAlign(l,!0);break;default:return!1}return!0})}parseVmlPicture(s){const t={type:r.DomType.VmlPicture,children:[]};for(const l of a.default.elements(s)){const b=(0,d.parseVmlElement)(l,this);b&&t.children.push(b)}return t}checkAlternateContent(s){var t;if(s.localName!="AlternateContent")return s;var l=a.default.element(s,"Choice");if(l){var b=a.default.attr(l,"Requires"),k=s.lookupNamespaceURI(b);if(p.includes(k))return l.firstElementChild}return(t=a.default.element(s,"Fallback"))===null||t===void 0?void 0:t.firstElementChild}parseDrawing(s){for(var t of a.default.elements(s))switch(t.localName){case"inline":case"anchor":return this.parseDrawingWrapper(t)}}parseDrawingWrapper(s){var t,l={type:r.DomType.Drawing,children:[],cssStyle:{}},b=s.localName=="anchor";let k=null,E=a.default.boolAttr(s,"simplePos"),_={relative:"page",align:"left",offset:"0"},C={relative:"page",align:"top",offset:"0"};for(var o of a.default.elements(s))switch(o.localName){case"simplePos":E&&(_.offset=a.default.lengthAttr(o,"x",h.LengthUsage.Emu),C.offset=a.default.lengthAttr(o,"y",h.LengthUsage.Emu));break;case"extent":l.cssStyle.width=a.default.lengthAttr(o,"cx",h.LengthUsage.Emu),l.cssStyle.height=a.default.lengthAttr(o,"cy",h.LengthUsage.Emu);break;case"positionH":case"positionV":if(!E){let q=o.localName=="positionH"?_:C;var R=a.default.element(o,"align"),V=a.default.element(o,"posOffset");q.relative=(t=a.default.attr(o,"relativeFrom"))!==null&&t!==void 0?t:q.relative,R&&(q.align=R.textContent),V&&(q.offset=P.sizeValue(V,h.LengthUsage.Emu))}break;case"wrapTopAndBottom":k="wrapTopAndBottom";break;case"wrapNone":k="wrapNone";break;case"graphic":var F=this.parseGraphic(o);F&&l.children.push(F)}return k=="wrapTopAndBottom"?(l.cssStyle.display="block",_.align&&(l.cssStyle["text-align"]=_.align,l.cssStyle.width="100%")):k=="wrapNone"?(l.cssStyle.display="block",l.cssStyle.position="relative",l.cssStyle.width="0px",l.cssStyle.height="0px",_.offset&&(l.cssStyle.left=_.offset),C.offset&&(l.cssStyle.top=C.offset)):!b||_.align!="left"&&_.align!="right"||(l.cssStyle.float=_.align),l}parseGraphic(s){var t=a.default.element(s,"graphicData");for(let l of a.default.elements(t))if(l.localName==="pic")return this.parsePicture(l);return null}parsePicture(s){var t={type:r.DomType.Image,src:"",cssStyle:{}},l=a.default.element(s,"blipFill"),b=a.default.element(l,"blip");t.src=a.default.attr(b,"embed");var k=a.default.element(s,"spPr"),E=a.default.element(k,"xfrm");for(var _ of(t.cssStyle.position="relative",a.default.elements(E)))switch(_.localName){case"ext":t.cssStyle.width=a.default.lengthAttr(_,"cx",h.LengthUsage.Emu),t.cssStyle.height=a.default.lengthAttr(_,"cy",h.LengthUsage.Emu);break;case"off":t.cssStyle.left=a.default.lengthAttr(_,"x",h.LengthUsage.Emu),t.cssStyle.top=a.default.lengthAttr(_,"y",h.LengthUsage.Emu)}return t}parseTable(s){var t={type:r.DomType.Table,children:[]};return P.foreach(s,l=>{switch(l.localName){case"tr":t.children.push(this.parseTableRow(l));break;case"tblGrid":t.columns=this.parseTableColumns(l);break;case"tblPr":this.parseTableProperties(l,t)}}),t}parseTableColumns(s){var t=[];return P.foreach(s,l=>{l.localName==="gridCol"&&t.push({width:a.default.lengthAttr(l,"w")})}),t}parseTableProperties(s,t){switch(t.cssStyle={},t.cellStyle={},this.parseDefaultProperties(s,t.cssStyle,t.cellStyle,l=>{switch(l.localName){case"tblStyle":t.styleName=a.default.attr(l,"val");break;case"tblLook":t.className=n.classNameOftblLook(l);break;case"tblpPr":this.parseTablePosition(l,t);break;case"tblStyleColBandSize":t.colBandSize=a.default.intAttr(l,"val");break;case"tblStyleRowBandSize":t.rowBandSize=a.default.intAttr(l,"val");break;default:return!1}return!0}),t.cssStyle["text-align"]){case"center":delete t.cssStyle["text-align"],t.cssStyle["margin-left"]="auto",t.cssStyle["margin-right"]="auto";break;case"right":delete t.cssStyle["text-align"],t.cssStyle["margin-left"]="auto"}}parseTablePosition(s,t){var l=a.default.lengthAttr(s,"topFromText"),b=a.default.lengthAttr(s,"bottomFromText"),k=a.default.lengthAttr(s,"rightFromText"),E=a.default.lengthAttr(s,"leftFromText");t.cssStyle.float="left",t.cssStyle["margin-bottom"]=n.addSize(t.cssStyle["margin-bottom"],b),t.cssStyle["margin-left"]=n.addSize(t.cssStyle["margin-left"],E),t.cssStyle["margin-right"]=n.addSize(t.cssStyle["margin-right"],k),t.cssStyle["margin-top"]=n.addSize(t.cssStyle["margin-top"],l)}parseTableRow(s){var t={type:r.DomType.Row,children:[]};return P.foreach(s,l=>{switch(l.localName){case"tc":t.children.push(this.parseTableCell(l));break;case"trPr":this.parseTableRowProperties(l,t)}}),t}parseTableRowProperties(s,t){t.cssStyle=this.parseDefaultProperties(s,{},null,l=>{switch(l.localName){case"cnfStyle":t.className=n.classNameOfCnfStyle(l);break;case"tblHeader":t.isHeader=a.default.boolAttr(l,"val");break;default:return!1}return!0})}parseTableCell(s){var t={type:r.DomType.Cell,children:[]};return P.foreach(s,l=>{switch(l.localName){case"tbl":t.children.push(this.parseTable(l));break;case"p":t.children.push(this.parseParagraph(l));break;case"tcPr":this.parseTableCellProperties(l,t)}}),t}parseTableCellProperties(s,t){t.cssStyle=this.parseDefaultProperties(s,{},null,l=>{var b;switch(l.localName){case"gridSpan":t.span=a.default.intAttr(l,"val",null);break;case"vMerge":t.verticalMerge=(b=a.default.attr(l,"val"))!==null&&b!==void 0?b:"continue";break;case"cnfStyle":t.className=n.classNameOfCnfStyle(l);break;default:return!1}return!0})}parseDefaultProperties(s,t=null,l=null,b=null){return t=t||{},P.foreach(s,k=>{if(!(b!=null&&b(k)))switch(k.localName){case"jc":t["text-align"]=n.valueOfJc(k);break;case"textAlignment":t["vertical-align"]=n.valueOfTextAlignment(k);break;case"color":t.color=P.colorAttr(k,"val",null,e.autos.color);break;case"sz":t["font-size"]=t["min-height"]=a.default.lengthAttr(k,"val",h.LengthUsage.FontSize);break;case"shd":t["background-color"]=P.colorAttr(k,"fill",null,e.autos.shd);break;case"highlight":t["background-color"]=P.colorAttr(k,"val",null,e.autos.highlight);break;case"vertAlign":break;case"position":t.verticalAlign=a.default.lengthAttr(k,"val",h.LengthUsage.FontSize);break;case"tcW":if(this.options.ignoreWidth)break;case"tblW":t.width=n.valueOfSize(k,"w");break;case"trHeight":this.parseTrHeight(k,t);break;case"strike":t["text-decoration"]=a.default.boolAttr(k,"val",!0)?"line-through":"none";break;case"b":t["font-weight"]=a.default.boolAttr(k,"val",!0)?"bold":"normal";break;case"i":t["font-style"]=a.default.boolAttr(k,"val",!0)?"italic":"normal";break;case"caps":t["text-transform"]=a.default.boolAttr(k,"val",!0)?"uppercase":"none";break;case"smallCaps":t["text-transform"]=a.default.boolAttr(k,"val",!0)?"lowercase":"none";break;case"u":this.parseUnderline(k,t);break;case"ind":case"tblInd":this.parseIndentation(k,t);break;case"rFonts":this.parseFont(k,t);break;case"tblBorders":this.parseBorderProperties(k,l||t);break;case"tblCellSpacing":t["border-spacing"]=n.valueOfMargin(k),t["border-collapse"]="separate";break;case"pBdr":this.parseBorderProperties(k,t);break;case"bdr":t.border=n.valueOfBorder(k);break;case"tcBorders":this.parseBorderProperties(k,t);break;case"vanish":a.default.boolAttr(k,"val",!0)&&(t.display="none");break;case"kern":case"noWrap":break;case"tblCellMar":case"tcMar":this.parseMarginProperties(k,l||t);break;case"tblLayout":t["table-layout"]=n.valueOfTblLayout(k);break;case"vAlign":t["vertical-align"]=n.valueOfTextAlignment(k);break;case"spacing":s.localName=="pPr"&&this.parseSpacing(k,t);break;case"wordWrap":a.default.boolAttr(k,"val")&&(t["overflow-wrap"]="break-word");break;case"suppressAutoHyphens":t.hyphens=a.default.boolAttr(k,"val",!0)?"none":"auto";break;case"lang":t.$lang=a.default.attr(k,"val");break;case"bCs":case"iCs":case"szCs":case"tabs":case"outlineLvl":case"contextualSpacing":case"tblStyleColBandSize":case"tblStyleRowBandSize":case"webHidden":case"pageBreakBefore":case"suppressLineNumbers":case"keepLines":case"keepNext":case"widowControl":case"bidi":case"rtl":case"noProof":break;default:this.options.debug&&console.warn(`DOCX: Unknown document element: ${s.localName}.${k.localName}`)}}),t}parseUnderline(s,t){var l=a.default.attr(s,"val");if(l!=null){switch(l){case"dash":case"dashDotDotHeavy":case"dashDotHeavy":case"dashedHeavy":case"dashLong":case"dashLongHeavy":case"dotDash":case"dotDotDash":t["text-decoration-style"]="dashed";break;case"dotted":case"dottedHeavy":t["text-decoration-style"]="dotted";break;case"double":t["text-decoration-style"]="double";break;case"single":case"thick":case"words":t["text-decoration"]="underline";break;case"wave":case"wavyDouble":case"wavyHeavy":t["text-decoration-style"]="wavy";break;case"none":t["text-decoration"]="none"}var b=P.colorAttr(s,"color");b&&(t["text-decoration-color"]=b)}}parseFont(s,t){var l=[a.default.attr(s,"ascii"),n.themeValue(s,"asciiTheme")].filter(b=>b).join(", ");l.length>0&&(t["font-family"]=l)}parseIndentation(s,t){var l=a.default.lengthAttr(s,"firstLine"),b=a.default.lengthAttr(s,"hanging"),k=a.default.lengthAttr(s,"left"),E=a.default.lengthAttr(s,"start"),_=a.default.lengthAttr(s,"right"),C=a.default.lengthAttr(s,"end");l&&(t["text-indent"]=l),b&&(t["text-indent"]=`-${b}`),(k||E)&&(t["margin-left"]=k||E),(_||C)&&(t["margin-right"]=_||C)}parseSpacing(s,t){var l=a.default.lengthAttr(s,"before"),b=a.default.lengthAttr(s,"after"),k=a.default.intAttr(s,"line",null),E=a.default.attr(s,"lineRule");if(l&&(t["margin-top"]=l),b&&(t["margin-bottom"]=b),k!==null)switch(E){case"auto":t["line-height"]=`${(k/240).toFixed(2)}`;break;case"atLeast":t["line-height"]=`calc(100% + ${k/20}pt)`;break;default:t["line-height"]=t["min-height"]=k/20+"pt"}}parseMarginProperties(s,t){P.foreach(s,l=>{switch(l.localName){case"left":t["padding-left"]=n.valueOfMargin(l);break;case"right":t["padding-right"]=n.valueOfMargin(l);break;case"top":t["padding-top"]=n.valueOfMargin(l);break;case"bottom":t["padding-bottom"]=n.valueOfMargin(l)}})}parseTrHeight(s,t){a.default.attr(s,"hRule"),t.height=a.default.lengthAttr(s,"val")}parseBorderProperties(s,t){P.foreach(s,l=>{switch(l.localName){case"start":case"left":t["border-left"]=n.valueOfBorder(l);break;case"end":case"right":t["border-right"]=n.valueOfBorder(l);break;case"top":t["border-top"]=n.valueOfBorder(l);break;case"bottom":t["border-bottom"]=n.valueOfBorder(l)}})}};const w=["black","blue","cyan","darkBlue","darkCyan","darkGray","darkGreen","darkMagenta","darkRed","darkYellow","green","lightGray","magenta","none","red","white","yellow"];class P{static foreach(t,l){for(var b=0;b<t.childNodes.length;b++){let k=t.childNodes[b];k.nodeType==Node.ELEMENT_NODE&&l(k)}}static colorAttr(t,l,b=null,k="black"){var E=a.default.attr(t,l);if(E)return E=="auto"?k:w.includes(E)?E:`#${E}`;var _=a.default.attr(t,"themeColor");return _?`var(--docx-${_}-color)`:b}static sizeValue(t,l=h.LengthUsage.Dxa){return(0,h.convertLength)(t.textContent,l)}}class n{static themeValue(t,l){var b=a.default.attr(t,l);return b?`var(--docx-${b}-font)`:null}static valueOfSize(t,l){var b=h.LengthUsage.Dxa;switch(a.default.attr(t,"type")){case"dxa":break;case"pct":b=h.LengthUsage.Percent;break;case"auto":return"auto"}return a.default.lengthAttr(t,l,b)}static valueOfMargin(t){return a.default.lengthAttr(t,"w")}static valueOfBorder(t){if(a.default.attr(t,"val")=="nil")return"none";var l=P.colorAttr(t,"color");return`${a.default.lengthAttr(t,"sz",h.LengthUsage.Border)} solid ${l=="auto"?e.autos.borderColor:l}`}static valueOfTblLayout(t){return a.default.attr(t,"val")=="fixed"?"fixed":"auto"}static classNameOfCnfStyle(t){const l=a.default.attr(t,"val");return["first-row","last-row","first-col","last-col","odd-col","even-col","odd-row","even-row","ne-cell","nw-cell","se-cell","sw-cell"].filter((b,k)=>l[k]=="1").join(" ")}static valueOfJc(t){var l=a.default.attr(t,"val");switch(l){case"start":case"left":return"left";case"center":return"center";case"end":case"right":return"right";case"both":return"justify"}return l}static valueOfVertAlign(t,l=!1){var b=a.default.attr(t,"val");switch(b){case"subscript":return"sub";case"superscript":return l?"sup":"super"}return l?null:b}static valueOfTextAlignment(t){var l=a.default.attr(t,"val");switch(l){case"auto":case"baseline":return"baseline";case"top":return"top";case"center":return"middle";case"bottom":return"bottom"}return l}static addSize(t,l){return t==null?l:l==null?t:`calc(${t} + ${l})`}static classNameOftblLook(t){const l=a.default.hexAttr(t,"val",0);let b="";return(a.default.boolAttr(t,"firstRow")||32&l)&&(b+=" first-row"),(a.default.boolAttr(t,"lastRow")||64&l)&&(b+=" last-row"),(a.default.boolAttr(t,"firstColumn")||128&l)&&(b+=" first-col"),(a.default.boolAttr(t,"lastColumn")||256&l)&&(b+=" last-col"),(a.default.boolAttr(t,"noHBand")||512&l)&&(b+=" no-hband"),(a.default.boolAttr(t,"noVBand")||1024&l)&&(b+=" no-vband"),b.trim()}}},162:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.CorePropsPart=void 0;const r=u(530),m=u(614);class f extends r.Part{parseXml(i){this.props=(0,m.parseCoreProps)(i,this._package.xmlParser)}}e.CorePropsPart=f},614:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseCoreProps=void 0,e.parseCoreProps=function(u,r){const m={};for(let f of r.elements(u))switch(f.localName){case"title":m.title=f.textContent;break;case"description":m.description=f.textContent;break;case"subject":m.subject=f.textContent;break;case"creator":m.creator=f.textContent;break;case"keywords":m.keywords=f.textContent;break;case"language":m.language=f.textContent;break;case"lastModifiedBy":m.lastModifiedBy=f.textContent;break;case"revision":f.textContent&&(m.revision=parseInt(f.textContent))}return m}},177:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.CustomPropsPart=void 0;const r=u(530),m=u(821);class f extends r.Part{parseXml(i){this.props=(0,m.parseCustomProps)(i,this._package.xmlParser)}}e.CustomPropsPart=f},821:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseCustomProps=void 0,e.parseCustomProps=function(u,r){return r.elements(u,"property").map(m=>{const f=m.firstChild;return{formatId:r.attr(m,"fmtid"),name:r.attr(m,"name"),type:f.nodeName,value:f.textContent}})}},665:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.ExtendedPropsPart=void 0;const r=u(530),m=u(668);class f extends r.Part{parseXml(i){this.props=(0,m.parseExtendedProps)(i,this._package.xmlParser)}}e.ExtendedPropsPart=f},668:(v,e)=>{function u(r){if(r!==void 0)return parseInt(r)}Object.defineProperty(e,"__esModule",{value:!0}),e.parseExtendedProps=void 0,e.parseExtendedProps=function(r,m){const f={};for(let a of m.elements(r))switch(a.localName){case"Template":f.template=a.textContent;break;case"Pages":f.pages=u(a.textContent);break;case"Words":f.words=u(a.textContent);break;case"Characters":f.characters=u(a.textContent);break;case"Application":f.application=a.textContent;break;case"Lines":f.lines=u(a.textContent);break;case"Paragraphs":f.paragraphs=u(a.textContent);break;case"Company":f.company=a.textContent;break;case"AppVersion":f.appVersion=a.textContent}return f}},172:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseBookmarkEnd=e.parseBookmarkStart=void 0;const r=u(120);e.parseBookmarkStart=function(m,f){return{type:r.DomType.BookmarkStart,id:f.attr(m,"id"),name:f.attr(m,"name"),colFirst:f.intAttr(m,"colFirst"),colLast:f.intAttr(m,"colLast")}},e.parseBookmarkEnd=function(m,f){return{type:r.DomType.BookmarkEnd,id:f.attr(m,"id")}}},191:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseBorders=e.parseBorder=void 0;const r=u(149);function m(f,a){return{type:a.attr(f,"val"),color:a.attr(f,"color"),size:a.lengthAttr(f,"sz",r.LengthUsage.Border),offset:a.lengthAttr(f,"space",r.LengthUsage.Point),frame:a.boolAttr(f,"frame"),shadow:a.boolAttr(f,"shadow")}}e.parseBorder=m,e.parseBorders=function(f,a){var i={};for(let y of a.elements(f))switch(y.localName){case"left":i.left=m(y,a);break;case"top":i.top=m(y,a);break;case"right":i.right=m(y,a);break;case"bottom":i.bottom=m(y,a)}return i}},149:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseCommonProperty=e.convertPercentage=e.convertBoolean=e.convertLength=e.LengthUsage=e.ns=void 0,e.ns={wordml:"http://schemas.openxmlformats.org/wordprocessingml/2006/main",drawingml:"http://schemas.openxmlformats.org/drawingml/2006/main",picture:"http://schemas.openxmlformats.org/drawingml/2006/picture",compatibility:"http://schemas.openxmlformats.org/markup-compatibility/2006",math:"http://schemas.openxmlformats.org/officeDocument/2006/math"},e.LengthUsage={Dxa:{mul:.05,unit:"pt"},Emu:{mul:7874015748031496e-20,unit:"pt"},FontSize:{mul:.5,unit:"pt"},Border:{mul:.125,unit:"pt"},Point:{mul:1,unit:"pt"},Percent:{mul:.02,unit:"%"},LineHeight:{mul:.004166666666666667,unit:""},VmlEmu:{mul:7874015748031496e-20,unit:""}},e.convertLength=function(u,r=e.LengthUsage.Dxa){return u==null||/.+(p[xt]|[%])$/.test(u)?u:`${(parseInt(u)*r.mul).toFixed(2)}${r.unit}`},e.convertBoolean=function(u,r=!1){switch(u){case"1":case"on":case"true":return!0;case"0":case"off":case"false":return!1;default:return r}},e.convertPercentage=function(u){return u?parseInt(u)/100:null},e.parseCommonProperty=function(u,r,m){if(u.namespaceURI!=e.ns.wordml)return!1;switch(u.localName){case"color":r.color=m.attr(u,"val");break;case"sz":r.fontSize=m.lengthAttr(u,"val",e.LengthUsage.FontSize);break;default:return!1}return!0}},448:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.DocumentPart=void 0;const r=u(530);class m extends r.Part{constructor(a,i,y){super(a,i),this._documentParser=y}parseXml(a){this.body=this._documentParser.parseDocumentFile(a)}}e.DocumentPart=m},120:(v,e)=>{var u;Object.defineProperty(e,"__esModule",{value:!0}),e.OpenXmlElementBase=e.DomType=void 0,function(r){r.Document="document",r.Paragraph="paragraph",r.Run="run",r.Break="break",r.NoBreakHyphen="noBreakHyphen",r.Table="table",r.Row="row",r.Cell="cell",r.Hyperlink="hyperlink",r.Drawing="drawing",r.Image="image",r.Text="text",r.Tab="tab",r.Symbol="symbol",r.BookmarkStart="bookmarkStart",r.BookmarkEnd="bookmarkEnd",r.Footer="footer",r.Header="header",r.FootnoteReference="footnoteReference",r.EndnoteReference="endnoteReference",r.Footnote="footnote",r.Endnote="endnote",r.SimpleField="simpleField",r.ComplexField="complexField",r.Instruction="instruction",r.VmlPicture="vmlPicture",r.MmlMath="mmlMath",r.MmlMathParagraph="mmlMathParagraph",r.MmlFraction="mmlFraction",r.MmlFunction="mmlFunction",r.MmlFunctionName="mmlFunctionName",r.MmlNumerator="mmlNumerator",r.MmlDenominator="mmlDenominator",r.MmlRadical="mmlRadical",r.MmlBase="mmlBase",r.MmlDegree="mmlDegree",r.MmlSuperscript="mmlSuperscript",r.MmlSubscript="mmlSubscript",r.MmlPreSubSuper="mmlPreSubSuper",r.MmlSubArgument="mmlSubArgument",r.MmlSuperArgument="mmlSuperArgument",r.MmlNary="mmlNary",r.MmlDelimiter="mmlDelimiter",r.MmlRun="mmlRun",r.MmlEquationArray="mmlEquationArray",r.MmlLimit="mmlLimit",r.MmlLimitLower="mmlLimitLower",r.MmlMatrix="mmlMatrix",r.MmlMatrixRow="mmlMatrixRow",r.MmlBox="mmlBox",r.MmlBar="mmlBar",r.MmlGroupChar="mmlGroupChar",r.VmlElement="vmlElement",r.Inserted="inserted",r.Deleted="deleted",r.DeletedText="deletedText"}(u||(e.DomType=u={})),e.OpenXmlElementBase=class{constructor(){this.children=[],this.cssStyle={}}}},931:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseLineSpacing=void 0,e.parseLineSpacing=function(u,r){return{before:r.lengthAttr(u,"before"),after:r.lengthAttr(u,"after"),line:r.intAttr(u,"line"),lineRule:r.attr(u,"lineRule")}}},109:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseNumbering=e.parseTabs=e.parseParagraphProperty=e.parseParagraphProperties=void 0;const r=u(149),m=u(59),f=u(931),a=u(488);function i(d,p,g){if(d.namespaceURI!=r.ns.wordml)return!1;if((0,r.parseCommonProperty)(d,p,g))return!0;switch(d.localName){case"tabs":p.tabs=y(d,g);break;case"sectPr":p.sectionProps=(0,m.parseSectionProperties)(d,g);break;case"numPr":p.numbering=h(d,g);break;case"spacing":return p.lineSpacing=(0,f.parseLineSpacing)(d,g),!1;case"textAlignment":return p.textAlignment=g.attr(d,"val"),!1;case"keepNext":p.keepLines=g.boolAttr(d,"val",!0);break;case"keepNext":p.keepNext=g.boolAttr(d,"val",!0);break;case"pageBreakBefore":p.pageBreakBefore=g.boolAttr(d,"val",!0);break;case"outlineLvl":p.outlineLevel=g.intAttr(d,"val");break;case"pStyle":p.styleName=g.attr(d,"val");break;case"rPr":p.runProps=(0,a.parseRunProperties)(d,g);break;default:return!1}return!0}function y(d,p){return p.elements(d,"tab").map(g=>({position:p.lengthAttr(g,"pos"),leader:p.attr(g,"leader"),style:p.attr(g,"val")}))}function h(d,p){var g={};for(let w of p.elements(d))switch(w.localName){case"numId":g.id=p.attr(w,"val");break;case"ilvl":g.level=p.intAttr(w,"val")}return g}e.parseParagraphProperties=function(d,p){let g={};for(let w of p.elements(d))i(w,g,p);return g},e.parseParagraphProperty=i,e.parseTabs=y,e.parseNumbering=h},488:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseRunProperty=e.parseRunProperties=void 0;const r=u(149);function m(f,a,i){return!!(0,r.parseCommonProperty)(f,a,i)}e.parseRunProperties=function(f,a){let i={};for(let y of a.elements(f))m(y,i,a);return i},e.parseRunProperty=m},59:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseSectionProperties=e.SectionType=void 0;const r=u(472),m=u(191);var f;function a(h,d){return{numberOfColumns:d.intAttr(h,"num"),space:d.lengthAttr(h,"space"),separator:d.boolAttr(h,"sep"),equalWidth:d.boolAttr(h,"equalWidth",!0),columns:d.elements(h,"col").map(p=>({width:d.lengthAttr(p,"w"),space:d.lengthAttr(p,"space")}))}}function i(h,d){return{chapSep:d.attr(h,"chapSep"),chapStyle:d.attr(h,"chapStyle"),format:d.attr(h,"fmt"),start:d.intAttr(h,"start")}}function y(h,d){return{id:d.attr(h,"id"),type:d.attr(h,"type")}}(function(h){h.Continuous="continuous",h.NextPage="nextPage",h.NextColumn="nextColumn",h.EvenPage="evenPage",h.OddPage="oddPage"})(f||(e.SectionType=f={})),e.parseSectionProperties=function(h,d=r.default){var p,g,w={};for(let P of d.elements(h))switch(P.localName){case"pgSz":w.pageSize={width:d.lengthAttr(P,"w"),height:d.lengthAttr(P,"h"),orientation:d.attr(P,"orient")};break;case"type":w.type=d.attr(P,"val");break;case"pgMar":w.pageMargins={left:d.lengthAttr(P,"left"),right:d.lengthAttr(P,"right"),top:d.lengthAttr(P,"top"),bottom:d.lengthAttr(P,"bottom"),header:d.lengthAttr(P,"header"),footer:d.lengthAttr(P,"footer"),gutter:d.lengthAttr(P,"gutter")};break;case"cols":w.columns=a(P,d);break;case"headerReference":((p=w.headerRefs)!==null&&p!==void 0?p:w.headerRefs=[]).push(y(P,d));break;case"footerReference":((g=w.footerRefs)!==null&&g!==void 0?g:w.footerRefs=[]).push(y(P,d));break;case"titlePg":w.titlePage=d.boolAttr(P,"val",!0);break;case"pgBorders":w.pageBorders=(0,m.parseBorders)(P,d);break;case"pgNumType":w.pageNumber=i(P,d)}return w}},667:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.renderAsync=e.praseAsync=e.defaultOptions=void 0;const r=u(213),m=u(168),f=u(932);e.defaultOptions={ignoreHeight:!1,ignoreWidth:!1,ignoreFonts:!1,breakPages:!0,debug:!1,experimental:!1,className:"docx",inWrapper:!0,trimXmlDeclaration:!0,ignoreLastRenderedPageBreak:!0,renderHeaders:!0,renderFooters:!0,renderFootnotes:!0,renderEndnotes:!0,useBase64URL:!1,useMathMLPolyfill:!1,renderChanges:!1},e.praseAsync=function(a,i=null){const y=Object.assign(Object.assign({},e.defaultOptions),i);return r.WordDocument.load(a,new m.DocumentParser(y),y)},e.renderAsync=async function(a,i,y=null,h=null){const d=Object.assign(Object.assign({},e.defaultOptions),h),p=new f.HtmlRenderer(window.document),g=await r.WordDocument.load(a,new m.DocumentParser(d),d);return p.render(g,i,y,d),g}},380:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.FontTablePart=void 0;const r=u(530),m=u(512);class f extends r.Part{parseXml(i){this.fonts=(0,m.parseFonts)(i,this._package.xmlParser)}}e.FontTablePart=f},512:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseEmbedFontRef=e.parseFont=e.parseFonts=void 0;const u={embedRegular:"regular",embedBold:"bold",embedItalic:"italic",embedBoldItalic:"boldItalic"};function r(f,a){let i={name:a.attr(f,"name"),embedFontRefs:[]};for(let y of a.elements(f))switch(y.localName){case"family":i.family=a.attr(y,"val");break;case"altName":i.altName=a.attr(y,"val");break;case"embedRegular":case"embedBold":case"embedItalic":case"embedBoldItalic":i.embedFontRefs.push(m(y,a))}return i}function m(f,a){return{id:a.attr(f,"id"),key:a.attr(f,"fontKey"),type:u[f.localName]}}e.parseFonts=function(f,a){return a.elements(f).map(i=>r(i,a))},e.parseFont=r,e.parseEmbedFontRef=m},984:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.WmlFooter=e.WmlHeader=void 0;const r=u(120);class m extends r.OpenXmlElementBase{constructor(){super(...arguments),this.type=r.DomType.Header}}e.WmlHeader=m;class f extends r.OpenXmlElementBase{constructor(){super(...arguments),this.type=r.DomType.Footer}}e.WmlFooter=f},985:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.FooterPart=e.HeaderPart=e.BaseHeaderFooterPart=void 0;const r=u(530),m=u(984);class f extends r.Part{constructor(i,y,h){super(i,y),this._documentParser=h}parseXml(i){this.rootElement=this.createRootElement(),this.rootElement.children=this._documentParser.parseBodyElements(i)}}e.BaseHeaderFooterPart=f,e.HeaderPart=class extends f{createRootElement(){return new m.WmlHeader}},e.FooterPart=class extends f{createRootElement(){return new m.WmlFooter}}},932:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.HtmlRenderer=void 0;const r=u(120),m=u(593),f=u(630),a=u(438),i="http://www.w3.org/1998/Math/MathML";function y(n,s,t){return d(void 0,n,s,t)}function h(n,s,t){return d("http://www.w3.org/2000/svg",n,s,t)}function d(n,s,t,l){var b=n?document.createElementNS(n,s):document.createElement(s);return Object.assign(b,t),l&&g(b,l),b}function p(n){n.innerHTML=""}function g(n,s){s.forEach(t=>n.appendChild((0,m.isString)(t)?document.createTextNode(t):t))}function w(n){return y("style",{innerHTML:n})}function P(n,s){n.appendChild(document.createComment(s))}e.HtmlRenderer=class{constructor(n){this.htmlDocument=n,this.className="docx",this.styleMap={},this.currentPart=null,this.tableVerticalMerges=[],this.currentVerticalMerge=null,this.tableCellPositions=[],this.currentCellPosition=null,this.footnoteMap={},this.endnoteMap={},this.currentEndnoteIds=[],this.usedHederFooterParts=[],this.currentTabs=[],this.tabsTimeout=0,this.createElement=y}render(n,s,t=null,l){var b;this.document=n,this.options=l,this.className=l.className,this.rootSelector=l.inWrapper?`.${this.className}-wrapper`:":root",this.styleMap=null,p(t=t||s),p(s),P(t,"docxjs library predefined styles"),t.appendChild(this.renderDefaultStyle()),!window.MathMLElement&&l.useMathMLPolyfill&&(P(t,"docxjs mathml polyfill styles"),t.appendChild(w(a.default))),n.themePart&&(P(t,"docxjs document theme values"),this.renderTheme(n.themePart,t)),n.stylesPart!=null&&(this.styleMap=this.processStyles(n.stylesPart.styles),P(t,"docxjs document styles"),t.appendChild(this.renderStyles(n.stylesPart.styles))),n.numberingPart&&(this.prodessNumberings(n.numberingPart.domNumberings),P(t,"docxjs document numbering styles"),t.appendChild(this.renderNumbering(n.numberingPart.domNumberings,t))),n.footnotesPart&&(this.footnoteMap=(0,m.keyBy)(n.footnotesPart.notes,E=>E.id)),n.endnotesPart&&(this.endnoteMap=(0,m.keyBy)(n.endnotesPart.notes,E=>E.id)),n.settingsPart&&(this.defaultTabSize=(b=n.settingsPart.settings)===null||b===void 0?void 0:b.defaultTabStop),!l.ignoreFonts&&n.fontTablePart&&this.renderFontTable(n.fontTablePart,t);var k=this.renderSections(n.documentPart.body);this.options.inWrapper?s.appendChild(this.renderWrapper(k)):g(s,k),this.refreshTabStops()}renderTheme(n,s){var t,l;const b={},k=(t=n.theme)===null||t===void 0?void 0:t.fontScheme;k&&(k.majorFont&&(b["--docx-majorHAnsi-font"]=k.majorFont.latinTypeface),k.minorFont&&(b["--docx-minorHAnsi-font"]=k.minorFont.latinTypeface));const E=(l=n.theme)===null||l===void 0?void 0:l.colorScheme;if(E)for(let[C,o]of Object.entries(E.colors))b[`--docx-${C}-color`]=`#${o}`;const _=this.styleToString(`.${this.className}`,b);s.appendChild(w(_))}renderFontTable(n,s){for(let t of n.fonts)for(let l of t.embedFontRefs)this.document.loadFont(l.id,l.key).then(b=>{const k={"font-family":t.name,src:`url(${b})`};l.type!="bold"&&l.type!="boldItalic"||(k["font-weight"]="bold"),l.type!="italic"&&l.type!="boldItalic"||(k["font-style"]="italic"),P(s,`docxjs ${t.name} font`);const E=this.styleToString("@font-face",k);s.appendChild(w(E)),this.refreshTabStops()})}processStyleName(n){return n?`${this.className}_${(0,m.escapeClassName)(n)}`:this.className}processStyles(n){const s=(0,m.keyBy)(n.filter(l=>l.id!=null),l=>l.id);for(const l of n.filter(b=>b.basedOn)){var t=s[l.basedOn];if(t){l.paragraphProps=(0,m.mergeDeep)(l.paragraphProps,t.paragraphProps),l.runProps=(0,m.mergeDeep)(l.runProps,t.runProps);for(const b of t.styles){const k=l.styles.find(E=>E.target==b.target);k?this.copyStyleProperties(b.values,k.values):l.styles.push(Object.assign(Object.assign({},b),{values:Object.assign({},b.values)}))}}else this.options.debug&&console.warn(`Can't find base style ${l.basedOn}`)}for(let l of n)l.cssName=this.processStyleName(l.id);return s}prodessNumberings(n){var s;for(let t of n.filter(l=>l.pStyleName)){const l=this.findStyle(t.pStyleName);!((s=l==null?void 0:l.paragraphProps)===null||s===void 0)&&s.numbering&&(l.paragraphProps.numbering.level=t.level)}}processElement(n){if(n.children)for(var s of n.children)s.parent=n,s.type==r.DomType.Table?this.processTable(s):this.processElement(s)}processTable(n){for(var s of n.children)for(var t of s.children)t.cssStyle=this.copyStyleProperties(n.cellStyle,t.cssStyle,["border-left","border-right","border-top","border-bottom","padding-left","padding-right","padding-top","padding-bottom"]),this.processElement(t)}copyStyleProperties(n,s,t=null){if(!n)return s;for(var l of(s==null&&(s={}),t==null&&(t=Object.getOwnPropertyNames(n)),t))n.hasOwnProperty(l)&&!s.hasOwnProperty(l)&&(s[l]=n[l]);return s}createSection(n,s){var t=this.createElement("section",{className:n});return s&&(s.pageMargins&&(t.style.paddingLeft=s.pageMargins.left,t.style.paddingRight=s.pageMargins.right,t.style.paddingTop=s.pageMargins.top,t.style.paddingBottom=s.pageMargins.bottom),s.pageSize&&(this.options.ignoreWidth||(t.style.width=s.pageSize.width),this.options.ignoreHeight||(t.style.minHeight=s.pageSize.height)),s.columns&&s.columns.numberOfColumns&&(t.style.columnCount=`${s.columns.numberOfColumns}`,t.style.columnGap=s.columns.space,s.columns.separator&&(t.style.columnRule="1px solid black"))),t}renderSections(n){const s=[];this.processElement(n);const t=this.splitBySection(n.children);let l=null;for(let k=0,E=t.length;k<E;k++){this.currentFootnoteIds=[];const _=t[k],C=_.sectProps||n.props,o=this.createSection(this.className,C);this.renderStyleValues(n.cssStyle,o),this.options.renderHeaders&&this.renderHeaderFooter(C.headerRefs,C,s.length,l!=C,o);var b=this.createElement("article");this.renderElements(_.elements,b),o.appendChild(b),this.options.renderFootnotes&&this.renderNotes(this.currentFootnoteIds,this.footnoteMap,o),this.options.renderEndnotes&&k==E-1&&this.renderNotes(this.currentEndnoteIds,this.endnoteMap,o),this.options.renderFooters&&this.renderHeaderFooter(C.footerRefs,C,s.length,l!=C,o),s.push(o),l=C}return s}renderHeaderFooter(n,s,t,l,b){var k,E;if(n){var _=(E=(k=s.titlePage&&l?n.find(o=>o.type=="first"):null)!==null&&k!==void 0?k:t%2==1?n.find(o=>o.type=="even"):null)!==null&&E!==void 0?E:n.find(o=>o.type=="default"),C=_&&this.document.findPartByRelId(_.id,this.document.documentPart);C&&(this.currentPart=C,this.usedHederFooterParts.includes(C.path)||(this.processElement(C.rootElement),this.usedHederFooterParts.push(C.path)),this.renderElements([C.rootElement],b),this.currentPart=null)}}isPageBreakElement(n){return n.type==r.DomType.Break&&(n.break=="lastRenderedPageBreak"?!this.options.ignoreLastRenderedPageBreak:n.break=="page")}splitBySection(n){var s,t={sectProps:null,elements:[]},l=[t];for(let R of n){if(R.type==r.DomType.Paragraph){const V=this.findStyle(R.styleName);!((s=V==null?void 0:V.paragraphProps)===null||s===void 0)&&s.pageBreakBefore&&(t.sectProps=b,t={sectProps:null,elements:[]},l.push(t))}if(t.elements.push(R),R.type==r.DomType.Paragraph){const V=R;var b=V.sectionProps,k=-1,E=-1;if(this.options.breakPages&&V.children&&(k=V.children.findIndex(F=>{var q,W;return(E=(W=(q=F.children)===null||q===void 0?void 0:q.findIndex(this.isPageBreakElement.bind(this)))!==null&&W!==void 0?W:-1)!=-1})),(b||k!=-1)&&(t.sectProps=b,t={sectProps:null,elements:[]},l.push(t)),k!=-1){let F=V.children[k],q=E<F.children.length-1;if(k<V.children.length-1||q){var _=R.children,C=Object.assign(Object.assign({},R),{children:_.slice(k)});if(R.children=_.slice(0,k),t.elements.push(C),q){let W=F.children,Y=Object.assign(Object.assign({},F),{children:W.slice(0,E)});R.children.push(Y),F.children=W.slice(E)}}}}}let o=null;for(let R=l.length-1;R>=0;R--)l[R].sectProps==null?l[R].sectProps=o:o=l[R].sectProps;return l}renderWrapper(n){return this.createElement("div",{className:`${this.className}-wrapper`},n)}renderDefaultStyle(){var n=this.className;return w(`
.${n}-wrapper { background: gray; padding: 30px; padding-bottom: 0px; display: flex; flex-flow: column; align-items: center; }
.${n}-wrapper>section.${n} { background: white; box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); margin-bottom: 30px; }
.${n} { color: black; hyphens: auto; }
section.${n} { box-sizing: border-box; display: flex; flex-flow: column nowrap; position: relative; overflow: hidden; }
section.${n}>article { margin-bottom: auto; z-index: 1; }
section.${n}>footer { z-index: 1; }
.${n} table { border-collapse: collapse; }
.${n} table td, .${n} table th { vertical-align: top; }
.${n} p { margin: 0pt; min-height: 1em; }
.${n} span { white-space: pre-wrap; overflow-wrap: break-word; }
.${n} a { color: inherit; text-decoration: inherit; }
`)}renderNumbering(n,s){var t="",l=[];for(var b of n){var k=`p.${this.numberingClass(b.id,b.level)}`,E="none";if(b.bullet){let _=`--${this.className}-${b.bullet.src}`.toLowerCase();t+=this.styleToString(`${k}:before`,{content:"' '",display:"inline-block",background:`var(${_})`},b.bullet.style),this.document.loadNumberingImage(b.bullet.src).then(C=>{var o=`${this.rootSelector} { ${_}: url(${C}) }`;s.appendChild(w(o))})}else if(b.levelText){let _=this.numberingCounter(b.id,b.level);const C=_+" "+(b.start-1);b.level>0&&(t+=this.styleToString(`p.${this.numberingClass(b.id,b.level-1)}`,{"counter-reset":C})),l.push(C),t+=this.styleToString(`${k}:before`,Object.assign({content:this.levelTextToContent(b.levelText,b.suff,b.id,this.numFormatToCssValue(b.format)),"counter-increment":_},b.rStyle))}else E=this.numFormatToCssValue(b.format);t+=this.styleToString(k,Object.assign({display:"list-item","list-style-position":"inside","list-style-type":E},b.pStyle))}return l.length>0&&(t+=this.styleToString(this.rootSelector,{"counter-reset":l.join(" ")})),w(t)}renderStyles(n){var s,t="";const l=this.styleMap,b=(0,m.keyBy)(n.filter(C=>C.isDefault),C=>C.target);for(const C of n){var k=C.styles;if(C.linked){var E=C.linked&&l[C.linked];E?k=k.concat(E.styles):this.options.debug&&console.warn(`Can't find linked style ${C.linked}`)}for(const o of k){var _=`${(s=C.target)!==null&&s!==void 0?s:""}.${C.cssName}`;C.target!=o.target&&(_+=` ${o.target}`),b[C.target]==C&&(_=`.${this.className} ${C.target}, `+_),t+=this.styleToString(_,o.values)}}return w(t)}renderNotes(n,s,t){var l=n.map(k=>s[k]).filter(k=>k);if(l.length>0){var b=this.createElement("ol",null,this.renderElements(l));t.appendChild(b)}}renderElement(n){switch(n.type){case r.DomType.Paragraph:return this.renderParagraph(n);case r.DomType.BookmarkStart:return this.renderBookmarkStart(n);case r.DomType.BookmarkEnd:return null;case r.DomType.Run:return this.renderRun(n);case r.DomType.Table:return this.renderTable(n);case r.DomType.Row:return this.renderTableRow(n);case r.DomType.Cell:return this.renderTableCell(n);case r.DomType.Hyperlink:return this.renderHyperlink(n);case r.DomType.Drawing:return this.renderDrawing(n);case r.DomType.Image:return this.renderImage(n);case r.DomType.Text:case r.DomType.Text:return this.renderText(n);case r.DomType.DeletedText:return this.renderDeletedText(n);case r.DomType.Tab:return this.renderTab(n);case r.DomType.Symbol:return this.renderSymbol(n);case r.DomType.Break:return this.renderBreak(n);case r.DomType.Footer:return this.renderContainer(n,"footer");case r.DomType.Header:return this.renderContainer(n,"header");case r.DomType.Footnote:case r.DomType.Endnote:return this.renderContainer(n,"li");case r.DomType.FootnoteReference:return this.renderFootnoteReference(n);case r.DomType.EndnoteReference:return this.renderEndnoteReference(n);case r.DomType.NoBreakHyphen:return this.createElement("wbr");case r.DomType.VmlPicture:return this.renderVmlPicture(n);case r.DomType.VmlElement:return this.renderVmlElement(n);case r.DomType.MmlMath:return this.renderContainerNS(n,i,"math",{xmlns:i});case r.DomType.MmlMathParagraph:return this.renderContainer(n,"span");case r.DomType.MmlFraction:return this.renderContainerNS(n,i,"mfrac");case r.DomType.MmlBase:return this.renderContainerNS(n,i,n.parent.type==r.DomType.MmlMatrixRow?"mtd":"mrow");case r.DomType.MmlNumerator:case r.DomType.MmlDenominator:case r.DomType.MmlFunction:case r.DomType.MmlLimit:case r.DomType.MmlBox:return this.renderContainerNS(n,i,"mrow");case r.DomType.MmlGroupChar:return this.renderMmlGroupChar(n);case r.DomType.MmlLimitLower:return this.renderContainerNS(n,i,"munder");case r.DomType.MmlMatrix:return this.renderContainerNS(n,i,"mtable");case r.DomType.MmlMatrixRow:return this.renderContainerNS(n,i,"mtr");case r.DomType.MmlRadical:return this.renderMmlRadical(n);case r.DomType.MmlSuperscript:return this.renderContainerNS(n,i,"msup");case r.DomType.MmlSubscript:return this.renderContainerNS(n,i,"msub");case r.DomType.MmlDegree:case r.DomType.MmlSuperArgument:case r.DomType.MmlSubArgument:return this.renderContainerNS(n,i,"mn");case r.DomType.MmlFunctionName:return this.renderContainerNS(n,i,"ms");case r.DomType.MmlDelimiter:return this.renderMmlDelimiter(n);case r.DomType.MmlRun:return this.renderMmlRun(n);case r.DomType.MmlNary:return this.renderMmlNary(n);case r.DomType.MmlPreSubSuper:return this.renderMmlPreSubSuper(n);case r.DomType.MmlBar:return this.renderMmlBar(n);case r.DomType.MmlEquationArray:return this.renderMllList(n);case r.DomType.Inserted:return this.renderInserted(n);case r.DomType.Deleted:return this.renderDeleted(n)}return null}renderChildren(n,s){return this.renderElements(n.children,s)}renderElements(n,s){if(n==null)return null;var t=n.flatMap(l=>this.renderElement(l)).filter(l=>l!=null);return s&&g(s,t),t}renderContainer(n,s,t){return this.createElement(s,t,this.renderChildren(n))}renderContainerNS(n,s,t,l){return d(s,t,l,this.renderChildren(n))}renderParagraph(n){var s,t,l,b,k=this.createElement("p");const E=this.findStyle(n.styleName);(s=n.tabs)!==null&&s!==void 0||(n.tabs=(t=E==null?void 0:E.paragraphProps)===null||t===void 0?void 0:t.tabs),this.renderClass(n,k),this.renderChildren(n,k),this.renderStyleValues(n.cssStyle,k),this.renderCommonProperties(k.style,n);const _=(l=n.numbering)!==null&&l!==void 0?l:(b=E==null?void 0:E.paragraphProps)===null||b===void 0?void 0:b.numbering;return _&&k.classList.add(this.numberingClass(_.id,_.level)),k}renderRunProperties(n,s){this.renderCommonProperties(n,s)}renderCommonProperties(n,s){s!=null&&(s.color&&(n.color=s.color),s.fontSize&&(n["font-size"]=s.fontSize))}renderHyperlink(n){var s=this.createElement("a");if(this.renderChildren(n,s),this.renderStyleValues(n.cssStyle,s),n.href)s.href=n.href;else if(n.id){const t=this.document.documentPart.rels.find(l=>l.id==n.id&&l.targetMode==="External");s.href=t==null?void 0:t.target}return s}renderDrawing(n){var s=this.createElement("div");return s.style.display="inline-block",s.style.position="relative",s.style.textIndent="0px",this.renderChildren(n,s),this.renderStyleValues(n.cssStyle,s),s}renderImage(n){let s=this.createElement("img");return this.renderStyleValues(n.cssStyle,s),this.document&&this.document.loadDocumentImage(n.src,this.currentPart).then(t=>{s.src=t}),s}renderText(n){return this.htmlDocument.createTextNode(n.text)}renderDeletedText(n){return this.options.renderEndnotes?this.htmlDocument.createTextNode(n.text):null}renderBreak(n){return n.break=="textWrapping"?this.createElement("br"):null}renderInserted(n){return this.options.renderChanges?this.renderContainer(n,"ins"):this.renderChildren(n)}renderDeleted(n){return this.options.renderChanges?this.renderContainer(n,"del"):null}renderSymbol(n){var s=this.createElement("span");return s.style.fontFamily=n.font,s.innerHTML=`&#x${n.char};`,s}renderFootnoteReference(n){var s=this.createElement("sup");return this.currentFootnoteIds.push(n.id),s.textContent=`${this.currentFootnoteIds.length}`,s}renderEndnoteReference(n){var s=this.createElement("sup");return this.currentEndnoteIds.push(n.id),s.textContent=`${this.currentEndnoteIds.length}`,s}renderTab(n){var s,t=this.createElement("span");if(t.innerHTML="&emsp;",this.options.experimental){t.className=this.tabStopClass();var l=(s=function(b,k){for(var E=b.parent;E!=null&&E.type!=k;)E=E.parent;return E}(n,r.DomType.Paragraph))===null||s===void 0?void 0:s.tabs;this.currentTabs.push({stops:l,span:t})}return t}renderBookmarkStart(n){var s=this.createElement("span");return s.id=n.name,s}renderRun(n){if(n.fieldRun)return null;const s=this.createElement("span");if(n.id&&(s.id=n.id),this.renderClass(n,s),this.renderStyleValues(n.cssStyle,s),n.verticalAlign){const t=this.createElement(n.verticalAlign);this.renderChildren(n,t),s.appendChild(t)}else this.renderChildren(n,s);return s}renderTable(n){let s=this.createElement("table");return this.tableCellPositions.push(this.currentCellPosition),this.tableVerticalMerges.push(this.currentVerticalMerge),this.currentVerticalMerge={},this.currentCellPosition={col:0,row:0},n.columns&&s.appendChild(this.renderTableColumns(n.columns)),this.renderClass(n,s),this.renderChildren(n,s),this.renderStyleValues(n.cssStyle,s),this.currentVerticalMerge=this.tableVerticalMerges.pop(),this.currentCellPosition=this.tableCellPositions.pop(),s}renderTableColumns(n){let s=this.createElement("colgroup");for(let t of n){let l=this.createElement("col");t.width&&(l.style.width=t.width),s.appendChild(l)}return s}renderTableRow(n){let s=this.createElement("tr");return this.currentCellPosition.col=0,this.renderClass(n,s),this.renderChildren(n,s),this.renderStyleValues(n.cssStyle,s),this.currentCellPosition.row++,s}renderTableCell(n){let s=this.createElement("td");const t=this.currentCellPosition.col;return n.verticalMerge?n.verticalMerge=="restart"?(this.currentVerticalMerge[t]=s,s.rowSpan=1):this.currentVerticalMerge[t]&&(this.currentVerticalMerge[t].rowSpan+=1,s.style.display="none"):this.currentVerticalMerge[t]=null,this.renderClass(n,s),this.renderChildren(n,s),this.renderStyleValues(n.cssStyle,s),n.span&&(s.colSpan=n.span),this.currentCellPosition.col+=s.colSpan,s}renderVmlPicture(n){var s=y("div");return this.renderChildren(n,s),s}renderVmlElement(n){var s,t,l=h("svg");l.setAttribute("style",n.cssStyleText);const b=this.renderVmlChildElement(n);return!((s=n.imageHref)===null||s===void 0)&&s.id&&((t=this.document)===null||t===void 0||t.loadDocumentImage(n.imageHref.id,this.currentPart).then(k=>b.setAttribute("href",k))),l.appendChild(b),requestAnimationFrame(()=>{const k=l.firstElementChild.getBBox();l.setAttribute("width",`${Math.ceil(k.x+k.width)}`),l.setAttribute("height",`${Math.ceil(k.y+k.height)}`)}),l}renderVmlChildElement(n){const s=h(n.tagName);Object.entries(n.attrs).forEach(([t,l])=>s.setAttribute(t,l));for(let t of n.children)t.type==r.DomType.VmlElement?s.appendChild(this.renderVmlChildElement(t)):s.appendChild(...(0,m.asArray)(this.renderElement(t)));return s}renderMmlRadical(n){var s;const t=n.children.find(b=>b.type==r.DomType.MmlBase);if(!((s=n.props)===null||s===void 0)&&s.hideDegree)return d(i,"msqrt",null,this.renderElements([t]));const l=n.children.find(b=>b.type==r.DomType.MmlDegree);return d(i,"mroot",null,this.renderElements([t,l]))}renderMmlDelimiter(n){var s,t;const l=[];return l.push(d(i,"mo",null,[(s=n.props.beginChar)!==null&&s!==void 0?s:"("])),l.push(...this.renderElements(n.children)),l.push(d(i,"mo",null,[(t=n.props.endChar)!==null&&t!==void 0?t:")"])),d(i,"mrow",null,l)}renderMmlNary(n){var s,t;const l=[],b=(0,m.keyBy)(n.children,R=>R.type),k=b[r.DomType.MmlSuperArgument],E=b[r.DomType.MmlSubArgument],_=k?d(i,"mo",null,(0,m.asArray)(this.renderElement(k))):null,C=E?d(i,"mo",null,(0,m.asArray)(this.renderElement(E))):null,o=d(i,"mo",null,[(t=(s=n.props)===null||s===void 0?void 0:s.char)!==null&&t!==void 0?t:"∫"]);return _||C?l.push(d(i,"munderover",null,[o,C,_])):_?l.push(d(i,"mover",null,[o,_])):C?l.push(d(i,"munder",null,[o,C])):l.push(o),l.push(...this.renderElements(b[r.DomType.MmlBase].children)),d(i,"mrow",null,l)}renderMmlPreSubSuper(n){const s=[],t=(0,m.keyBy)(n.children,C=>C.type),l=t[r.DomType.MmlSuperArgument],b=t[r.DomType.MmlSubArgument],k=l?d(i,"mo",null,(0,m.asArray)(this.renderElement(l))):null,E=b?d(i,"mo",null,(0,m.asArray)(this.renderElement(b))):null,_=d(i,"mo",null);return s.push(d(i,"msubsup",null,[_,E,k])),s.push(...this.renderElements(t[r.DomType.MmlBase].children)),d(i,"mrow",null,s)}renderMmlGroupChar(n){const s=n.props.verticalJustification==="bot"?"mover":"munder",t=this.renderContainerNS(n,i,s);return n.props.char&&t.appendChild(d(i,"mo",null,[n.props.char])),t}renderMmlBar(n){const s=this.renderContainerNS(n,i,"mrow");switch(n.props.position){case"top":s.style.textDecoration="overline";break;case"bottom":s.style.textDecoration="underline"}return s}renderMmlRun(n){const s=d(i,"ms");return this.renderClass(n,s),this.renderStyleValues(n.cssStyle,s),this.renderChildren(n,s),s}renderMllList(n){const s=d(i,"mtable");this.renderClass(n,s),this.renderStyleValues(n.cssStyle,s),this.renderChildren(n);for(let t of this.renderChildren(n))s.appendChild(d(i,"mtr",null,[d(i,"mtd",null,[t])]));return s}renderStyleValues(n,s){for(let t in n)t.startsWith("$")?s.setAttribute(t.slice(1),n[t]):s.style[t]=n[t]}renderClass(n,s){n.className&&(s.className=n.className),n.styleName&&s.classList.add(this.processStyleName(n.styleName))}findStyle(n){var s;return n&&((s=this.styleMap)===null||s===void 0?void 0:s[n])}numberingClass(n,s){return`${this.className}-num-${n}-${s}`}tabStopClass(){return`${this.className}-tab-stop`}styleToString(n,s,t=null){let l=`${n} {\r
`;for(const b in s)b.startsWith("$")||(l+=` ${b}: ${s[b]};\r
`);return t&&(l+=t),l+`}\r
`}numberingCounter(n,s){return`${this.className}-num-${n}-${s}`}levelTextToContent(n,s,t,l){var b;return`"${n.replace(/%\d*/g,k=>{let E=parseInt(k.substring(1),10)-1;return`"counter(${this.numberingCounter(t,E)}, ${l})"`})}${(b={tab:"\\9",space:"\\a0"}[s])!==null&&b!==void 0?b:""}"`}numFormatToCssValue(n){var s;return(s={none:"none",bullet:"disc",decimal:"decimal",lowerLetter:"lower-alpha",upperLetter:"upper-alpha",lowerRoman:"lower-roman",upperRoman:"upper-roman",decimalZero:"decimal-leading-zero",aiueo:"katakana",aiueoFullWidth:"katakana",chineseCounting:"simp-chinese-informal",chineseCountingThousand:"simp-chinese-informal",chineseLegalSimplified:"simp-chinese-formal",chosung:"hangul-consonant",ideographDigital:"cjk-ideographic",ideographTraditional:"cjk-heavenly-stem",ideographLegalTraditional:"trad-chinese-formal",ideographZodiac:"cjk-earthly-branch",iroha:"katakana-iroha",irohaFullWidth:"katakana-iroha",japaneseCounting:"japanese-informal",japaneseDigitalTenThousand:"cjk-decimal",japaneseLegal:"japanese-formal",thaiNumbers:"thai",koreanCounting:"korean-hangul-formal",koreanDigital:"korean-hangul-formal",koreanDigital2:"korean-hanja-informal",hebrew1:"hebrew",hebrew2:"hebrew",hindiNumbers:"devanagari",ganada:"hangul",taiwaneseCounting:"cjk-ideographic",taiwaneseCountingThousand:"cjk-ideographic",taiwaneseDigital:"cjk-decimal"}[n])!==null&&s!==void 0?s:n}refreshTabStops(){this.options.experimental&&(clearTimeout(this.tabsTimeout),this.tabsTimeout=setTimeout(()=>{const n=(0,f.computePixelToPoint)();for(let s of this.currentTabs)(0,f.updateTabStop)(s.span,s.stops,this.defaultTabSize,n)},500))}}},630:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.updateTabStop=e.computePixelToPoint=void 0;const u={pos:0,leader:"none",style:"left"};function r(m){return parseFloat(m)}e.computePixelToPoint=function(m=document.body){const f=document.createElement("div");f.style.width="100pt",m.appendChild(f);const a=100/f.offsetWidth;return m.removeChild(f),a},e.updateTabStop=function(m,f,a,i=.75){const y=m.closest("p"),h=m.getBoundingClientRect(),d=y.getBoundingClientRect(),p=getComputedStyle(y),g=(f==null?void 0:f.length)>0?f.map(_=>({pos:r(_.position),leader:_.leader,style:_.style})).sort((_,C)=>_.pos-C.pos):[u],w=g[g.length-1],P=d.width*i,n=r(a);let s=w.pos+n;if(s<P)for(;s<P&&g.length<50;s+=n)g.push(Object.assign(Object.assign({},u),{pos:s}));const t=parseFloat(p.marginLeft),l=d.left+t,b=(h.left-l)*i,k=g.find(_=>_.style!="clear"&&_.pos>b);if(k==null)return;let E=1;if(k.style=="right"||k.style=="center"){const _=Array.from(y.querySelectorAll(`.${m.className}`)),C=_.indexOf(m)+1,o=document.createRange();o.setStart(m,1),C<_.length?o.setEndBefore(_[C]):o.setEndAfter(y);const R=k.style=="center"?.5:1,V=o.getBoundingClientRect(),F=V.left+R*V.width-(d.left-t);E=k.pos-F*i}else E=k.pos-b;switch(m.innerHTML="&nbsp;",m.style.textDecoration="inherit",m.style.wordSpacing=`${E.toFixed(0)}pt`,k.leader){case"dot":case"middleDot":m.style.textDecoration="underline",m.style.textDecorationStyle="dotted";break;case"hyphen":case"heavy":case"underscore":m.style.textDecoration="underline"}}},881:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.WmlEndnote=e.WmlFootnote=e.WmlBaseNote=void 0;const r=u(120);class m{}e.WmlBaseNote=m,e.WmlFootnote=class extends m{constructor(){super(...arguments),this.type=r.DomType.Footnote}},e.WmlEndnote=class extends m{constructor(){super(...arguments),this.type=r.DomType.Endnote}}},735:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.EndnotesPart=e.FootnotesPart=e.BaseNotePart=void 0;const r=u(530),m=u(881);class f extends r.Part{constructor(i,y,h){super(i,y),this._documentParser=h}}e.BaseNotePart=f,e.FootnotesPart=class extends f{constructor(a,i,y){super(a,i,y)}parseXml(a){this.notes=this._documentParser.parseNotes(a,"footnote",m.WmlFootnote)}},e.EndnotesPart=class extends f{constructor(a,i,y){super(a,i,y)}parseXml(a){this.notes=this._documentParser.parseNotes(a,"endnote",m.WmlEndnote)}}},527:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.NumberingPart=void 0;const r=u(530),m=u(682);class f extends r.Part{constructor(i,y,h){super(i,y),this._documentParser=h}parseXml(i){Object.assign(this,(0,m.parseNumberingPart)(i,this._package.xmlParser)),this.domNumberings=this._documentParser.parseNumberingFile(i)}}e.NumberingPart=f},682:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseNumberingBulletPicture=e.parseNumberingLevelOverrride=e.parseNumberingLevel=e.parseAbstractNumbering=e.parseNumbering=e.parseNumberingPart=void 0;const r=u(109),m=u(488);function f(d,p){let g={id:p.attr(d,"numId"),overrides:[]};for(let w of p.elements(d))switch(w.localName){case"abstractNumId":g.abstractId=p.attr(w,"val");break;case"lvlOverride":g.overrides.push(y(w,p))}return g}function a(d,p){let g={id:p.attr(d,"abstractNumId"),levels:[]};for(let w of p.elements(d))switch(w.localName){case"name":g.name=p.attr(w,"val");break;case"multiLevelType":g.multiLevelType=p.attr(w,"val");break;case"numStyleLink":g.numberingStyleLink=p.attr(w,"val");break;case"styleLink":g.styleLink=p.attr(w,"val");break;case"lvl":g.levels.push(i(w,p))}return g}function i(d,p){let g={level:p.intAttr(d,"ilvl")};for(let w of p.elements(d))switch(w.localName){case"start":g.start=p.attr(w,"val");break;case"lvlRestart":g.restart=p.intAttr(w,"val");break;case"numFmt":g.format=p.attr(w,"val");break;case"lvlText":g.text=p.attr(w,"val");break;case"lvlJc":g.justification=p.attr(w,"val");break;case"lvlPicBulletId":g.bulletPictureId=p.attr(w,"val");break;case"pStyle":g.paragraphStyle=p.attr(w,"val");break;case"pPr":g.paragraphProps=(0,r.parseParagraphProperties)(w,p);break;case"rPr":g.runProps=(0,m.parseRunProperties)(w,p)}return g}function y(d,p){let g={level:p.intAttr(d,"ilvl")};for(let w of p.elements(d))switch(w.localName){case"startOverride":g.start=p.intAttr(w,"val");break;case"lvl":g.numberingLevel=i(w,p)}return g}function h(d,p){var g=p.element(d,"pict"),w=g&&p.element(g,"shape"),P=w&&p.element(w,"imagedata");return P?{id:p.attr(d,"numPicBulletId"),referenceId:p.attr(P,"id"),style:p.attr(w,"style")}:null}e.parseNumberingPart=function(d,p){let g={numberings:[],abstractNumberings:[],bulletPictures:[]};for(let w of p.elements(d))switch(w.localName){case"num":g.numberings.push(f(w,p));break;case"abstractNum":g.abstractNumberings.push(a(w,p));break;case"numPicBullet":g.bulletPictures.push(h(w,p))}return g},e.parseNumbering=f,e.parseAbstractNumbering=a,e.parseNumberingLevel=i,e.parseNumberingLevelOverrride=y,e.parseNumberingBulletPicture=h},472:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.XmlParser=e.serializeXmlString=e.parseXmlString=void 0;const r=u(149);e.parseXmlString=function(a,i=!1){var y;i&&(a=a.replace(/<[?].*[?]>/,"")),a=(y=a).charCodeAt(0)===65279?y.substring(1):y;const h=new DOMParser().parseFromString(a,"application/xml"),d=(p=h.getElementsByTagName("parsererror")[0])===null||p===void 0?void 0:p.textContent;var p;if(d)throw new Error(d);return h},e.serializeXmlString=function(a){return new XMLSerializer().serializeToString(a)};class m{elements(i,y=null){const h=[];for(let d=0,p=i.childNodes.length;d<p;d++){let g=i.childNodes.item(d);g.nodeType!=1||y!=null&&g.localName!=y||h.push(g)}return h}element(i,y){for(let h=0,d=i.childNodes.length;h<d;h++){let p=i.childNodes.item(h);if(p.nodeType==1&&p.localName==y)return p}return null}elementAttr(i,y,h){var d=this.element(i,y);return d?this.attr(d,h):void 0}attrs(i){return Array.from(i.attributes)}attr(i,y){for(let h=0,d=i.attributes.length;h<d;h++){let p=i.attributes.item(h);if(p.localName==y)return p.value}return null}intAttr(i,y,h=null){var d=this.attr(i,y);return d?parseInt(d):h}hexAttr(i,y,h=null){var d=this.attr(i,y);return d?parseInt(d,16):h}floatAttr(i,y,h=null){var d=this.attr(i,y);return d?parseFloat(d):h}boolAttr(i,y,h=null){return(0,r.convertBoolean)(this.attr(i,y),h)}lengthAttr(i,y,h=r.LengthUsage.Dxa){return(0,r.convertLength)(this.attr(i,y),h)}}e.XmlParser=m;const f=new m;e.default=f},287:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.SettingsPart=void 0;const r=u(530),m=u(846);class f extends r.Part{constructor(i,y){super(i,y)}parseXml(i){this.settings=(0,m.parseSettings)(i,this._package.xmlParser)}}e.SettingsPart=f},846:(v,e)=>{function u(r,m){var f={defaultNoteIds:[]};for(let a of m.elements(r))switch(a.localName){case"numFmt":f.nummeringFormat=m.attr(a,"val");break;case"footnote":case"endnote":f.defaultNoteIds.push(m.attr(a,"id"))}return f}Object.defineProperty(e,"__esModule",{value:!0}),e.parseNoteProperties=e.parseSettings=void 0,e.parseSettings=function(r,m){var f={};for(let a of m.elements(r))switch(a.localName){case"defaultTabStop":f.defaultTabStop=m.lengthAttr(a,"val");break;case"footnotePr":f.footnoteProps=u(a,m);break;case"endnotePr":f.endnoteProps=u(a,m);break;case"autoHyphenation":f.autoHyphenation=m.boolAttr(a,"val")}return f},e.parseNoteProperties=u},240:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.StylesPart=void 0;const r=u(530);class m extends r.Part{constructor(a,i,y){super(a,i),this._documentParser=y}parseXml(a){this.styles=this._documentParser.parseStylesFile(a)}}e.StylesPart=m},893:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.ThemePart=void 0;const r=u(530),m=u(55);class f extends r.Part{constructor(i,y){super(i,y)}parseXml(i){this.theme=(0,m.parseTheme)(i,this._package.xmlParser)}}e.ThemePart=f},55:(v,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseFontInfo=e.parseFontScheme=e.parseColorScheme=e.parseTheme=e.DmlTheme=void 0;class u{}function r(a,i){var y={name:i.attr(a,"name"),colors:{}};for(let p of i.elements(a)){var h=i.element(p,"srgbClr"),d=i.element(p,"sysClr");h?y.colors[p.localName]=i.attr(h,"val"):d&&(y.colors[p.localName]=i.attr(d,"lastClr"))}return y}function m(a,i){var y={name:i.attr(a,"name")};for(let h of i.elements(a))switch(h.localName){case"majorFont":y.majorFont=f(h,i);break;case"minorFont":y.minorFont=f(h,i)}return y}function f(a,i){return{latinTypeface:i.elementAttr(a,"latin","typeface"),eaTypeface:i.elementAttr(a,"ea","typeface"),csTypeface:i.elementAttr(a,"cs","typeface")}}e.DmlTheme=u,e.parseTheme=function(a,i){var y=new u,h=i.element(a,"themeElements");for(let d of i.elements(h))switch(d.localName){case"clrScheme":y.colorScheme=r(d,i);break;case"fontScheme":y.fontScheme=m(d,i)}return y},e.parseColorScheme=r,e.parseFontScheme=m,e.parseFontInfo=f},593:(v,e)=>{function u(r){return r&&typeof r=="object"&&!Array.isArray(r)}Object.defineProperty(e,"__esModule",{value:!0}),e.asArray=e.formatCssRules=e.parseCssRules=e.mergeDeep=e.isString=e.isObject=e.blobToBase64=e.keyBy=e.resolvePath=e.splitPath=e.escapeClassName=void 0,e.escapeClassName=function(r){return r==null?void 0:r.replace(/[ .]+/g,"-").replace(/[&]+/g,"and").toLowerCase()},e.splitPath=function(r){let m=r.lastIndexOf("/")+1;return[m==0?"":r.substring(0,m),m==0?r:r.substring(m)]},e.resolvePath=function(r,m){try{const f="http://docx/";return new URL(r,f+m).toString().substring(f.length)}catch{return`${m}${r}`}},e.keyBy=function(r,m){return r.reduce((f,a)=>(f[m(a)]=a,f),{})},e.blobToBase64=function(r){return new Promise((m,f)=>{const a=new FileReader;a.onloadend=()=>m(a.result),a.onerror=()=>f(),a.readAsDataURL(r)})},e.isObject=u,e.isString=function(r){return typeof r=="string"||r instanceof String},e.mergeDeep=function r(m,...f){var a;if(!f.length)return m;const i=f.shift();if(u(m)&&u(i))for(const y in i)u(i[y])?r((a=m[y])!==null&&a!==void 0?a:m[y]={},i[y]):m[y]=i[y];return r(m,...f)},e.parseCssRules=function(r){const m={};for(const f of r.split(";")){const[a,i]=f.split(":");m[a]=i}return m},e.formatCssRules=function(r){return Object.entries(r).map((m,f)=>`${m}: ${f}`).join(";")},e.asArray=function(r){return Array.isArray(r)?r:[r]}},320:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseVmlElement=e.VmlElement=void 0;const r=u(149),m=u(120),f=u(472);class a extends m.OpenXmlElementBase{constructor(){super(...arguments),this.type=m.DomType.VmlElement,this.attrs={}}}function i(h){var d;return{stroke:f.default.attr(h,"color"),"stroke-width":(d=f.default.lengthAttr(h,"weight",r.LengthUsage.Emu))!==null&&d!==void 0?d:"1px"}}function y(h){return h.split(",")}e.VmlElement=a,e.parseVmlElement=function h(d,p){var g=new a;switch(d.localName){case"rect":g.tagName="rect",Object.assign(g.attrs,{width:"100%",height:"100%"});break;case"oval":g.tagName="ellipse",Object.assign(g.attrs,{cx:"50%",cy:"50%",rx:"50%",ry:"50%"});break;case"line":g.tagName="line";break;case"shape":g.tagName="g";break;case"textbox":g.tagName="foreignObject",Object.assign(g.attrs,{width:"100%",height:"100%"});break;default:return null}for(const w of f.default.attrs(d))switch(w.localName){case"style":g.cssStyleText=w.value;break;case"fillcolor":g.attrs.fill=w.value;break;case"from":const[P,n]=y(w.value);Object.assign(g.attrs,{x1:P,y1:n});break;case"to":const[s,t]=y(w.value);Object.assign(g.attrs,{x2:s,y2:t})}for(const w of f.default.elements(d))switch(w.localName){case"stroke":Object.assign(g.attrs,i(w));break;case"fill":Object.assign(g.attrs,{});break;case"imagedata":g.tagName="image",Object.assign(g.attrs,{width:"100%",height:"100%"}),g.imageHref={id:f.default.attr(w,"id"),title:f.default.attr(w,"title")};break;case"txbxContent":g.children.push(...p.parseBodyElements(w));break;default:const P=h(w,p);P&&g.children.push(P)}return g}},213:(v,e,u)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.deobfuscate=e.WordDocument=void 0;const r=u(461),m=u(380),f=u(522),a=u(448),i=u(593),y=u(527),h=u(240),d=u(985),p=u(665),g=u(162),w=u(893),P=u(735),n=u(287),s=u(177),t=[{type:r.RelationshipTypes.OfficeDocument,target:"word/document.xml"},{type:r.RelationshipTypes.ExtendedProperties,target:"docProps/app.xml"},{type:r.RelationshipTypes.CoreProperties,target:"docProps/core.xml"},{type:r.RelationshipTypes.CustomProperties,target:"docProps/custom.xml"}];class l{constructor(){this.parts=[],this.partsMap={}}static async load(E,_,C){var o=new l;return o._options=C,o._parser=_,o._package=await f.OpenXmlPackage.load(E,C),o.rels=await o._package.loadRelationships(),await Promise.all(t.map(R=>{var V;const F=(V=o.rels.find(q=>q.type===R.type))!==null&&V!==void 0?V:R;return o.loadRelationshipPart(F.target,F.type)})),o}save(E="blob"){return this._package.save(E)}async loadRelationshipPart(E,_){var C;if(this.partsMap[E])return this.partsMap[E];if(!this._package.get(E))return null;let o=null;switch(_){case r.RelationshipTypes.OfficeDocument:this.documentPart=o=new a.DocumentPart(this._package,E,this._parser);break;case r.RelationshipTypes.FontTable:this.fontTablePart=o=new m.FontTablePart(this._package,E);break;case r.RelationshipTypes.Numbering:this.numberingPart=o=new y.NumberingPart(this._package,E,this._parser);break;case r.RelationshipTypes.Styles:this.stylesPart=o=new h.StylesPart(this._package,E,this._parser);break;case r.RelationshipTypes.Theme:this.themePart=o=new w.ThemePart(this._package,E);break;case r.RelationshipTypes.Footnotes:this.footnotesPart=o=new P.FootnotesPart(this._package,E,this._parser);break;case r.RelationshipTypes.Endnotes:this.endnotesPart=o=new P.EndnotesPart(this._package,E,this._parser);break;case r.RelationshipTypes.Footer:o=new d.FooterPart(this._package,E,this._parser);break;case r.RelationshipTypes.Header:o=new d.HeaderPart(this._package,E,this._parser);break;case r.RelationshipTypes.CoreProperties:this.corePropsPart=o=new g.CorePropsPart(this._package,E);break;case r.RelationshipTypes.ExtendedProperties:this.extendedPropsPart=o=new p.ExtendedPropsPart(this._package,E);break;case r.RelationshipTypes.CustomProperties:o=new s.CustomPropsPart(this._package,E);break;case r.RelationshipTypes.Settings:this.settingsPart=o=new n.SettingsPart(this._package,E)}if(o==null)return Promise.resolve(null);if(this.partsMap[E]=o,this.parts.push(o),await o.load(),((C=o.rels)===null||C===void 0?void 0:C.length)>0){const[R]=(0,i.splitPath)(o.path);await Promise.all(o.rels.map(V=>this.loadRelationshipPart((0,i.resolvePath)(V.target,R),V.type)))}return o}async loadDocumentImage(E,_){const C=await this.loadResource(_??this.documentPart,E,"blob");return this.blobToURL(C)}async loadNumberingImage(E){const _=await this.loadResource(this.numberingPart,E,"blob");return this.blobToURL(_)}async loadFont(E,_){const C=await this.loadResource(this.fontTablePart,E,"uint8array");return C&&this.blobToURL(new Blob([b(C,_)]))}blobToURL(E){return E?this._options.useBase64URL?(0,i.blobToBase64)(E):URL.createObjectURL(E):null}findPartByRelId(E,_=null){var C,o=((C=_.rels)!==null&&C!==void 0?C:this.rels).find(V=>V.id==E);const R=_?(0,i.splitPath)(_.path)[0]:"";return o?this.partsMap[(0,i.resolvePath)(o.target,R)]:null}getPathById(E,_){const C=E.rels.find(R=>R.id==_),[o]=(0,i.splitPath)(E.path);return C?(0,i.resolvePath)(C.target,o):null}loadResource(E,_,C){const o=this.getPathById(E,_);return o?this._package.load(o,C):Promise.resolve(null)}}function b(k,E){const _=E.replace(/{|}|-/g,""),C=new Array(16);for(let o=0;o<16;o++)C[16-o-1]=parseInt(_.substr(2*o,2),16);for(let o=0;o<32;o++)k[o]=k[o]^C[o%16];return k}e.WordDocument=l,e.deobfuscate=b},583:v=>{v.exports="data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 20 100%27 preserveAspectRatio=%27none%27%3E%3Cpath d=%27m0,75 l5,0 l5,25 l10,-100%27 stroke=%27black%27 fill=%27none%27 vector-effect=%27non-scaling-stroke%27/%3E%3C/svg%3E"},626:v=>{v.exports=T}},B={};function S(v){var e=B[v];if(e!==void 0)return e.exports;var u=B[v]={id:v,exports:{}};return L[v](u,u.exports,S),u.exports}return S.m=L,S.n=v=>{var e=v&&v.__esModule?()=>v.default:()=>v;return S.d(e,{a:e}),e},S.d=(v,e)=>{for(var u in e)S.o(e,u)&&!S.o(v,u)&&Object.defineProperty(v,u,{enumerable:!0,get:e[u]})},S.o=(v,e)=>Object.prototype.hasOwnProperty.call(v,e),S.r=v=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(v,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(v,"__esModule",{value:!0})},S.b=document.baseURI||self.location.href,S(667)})())})(Ce);var Ne=Ce.exports;const Oe={ignoreLastRenderedPageBreak:!1};function Re(ne,ce={}){return typeof ne=="string"?ze(ne,ce):Promise.resolve(ne)}function ze(ne,ce){return fetch(ne,ce).then(T=>T.status!==200?Promise.reject(T):T)}async function Me(ne){let ce;return ne instanceof Blob?ce=ne:ne instanceof Response?ce=await ne.blob():ne instanceof ArrayBuffer&&(ce=new Blob([ne])),ce}function Ie(ne,ce,T={}){if(!ne)return ce.innerHTML="",Promise.resolve();let L;return ne instanceof Blob?L=ne:ne instanceof Response?L=ne.blob():ne instanceof ArrayBuffer&&(L=new Blob([ne])),Ne.renderAsync(L,ce,ce,{...Oe,...T})}const je={getData:Re,render:Ie,getBlob:Me};export{je as d};