!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.htmlDocx=t()}}(function(){var define,module,exports;return function t(e,r,n){function i(o,s){if(!r[o]){if(!e[o]){var u="function"==typeof require&&require;if(!s&&u)return u(o,!0);if(a)return a(o,!0);throw new Error("Cannot find module '"+o+"'")}var l=r[o]={exports:{}};e[o][0].call(l.exports,function(t){var r=e[o][1][t];return i(r||t)},l,l.exports,t,e,r,n)}return r[o].exports}for(var a="function"==typeof require&&require,o=0;o * @license MIT */ var n=t("base64-js"),i=t("ieee754"),a=t("is-array");r.Buffer=s,r.SlowBuffer=s,r.INSPECT_MAX_BYTES=50,s.poolSize=8192;var o=1073741823;function s(t,e,r){if(!(this instanceof s))return new s(t,e,r);var n,i,u,l=typeof t;if("number"===l)n=t>0?t>>>0:0;else if("string"===l)"base64"===e&&(t=function(t){t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(k,"");for(;t.length%4!=0;)t+="=";return t}(t)),n=s.byteLength(t,e);else{if("object"!==l||null===t)throw new TypeError("must start with number, buffer, array or string");"Buffer"===t.type&&a(t.data)&&(t=t.data),n=+t.length>0?Math.floor(+t.length):0}if(this.length>o)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o.toString(16)+" bytes");if(s.TYPED_ARRAY_SUPPORT?i=s._augment(new Uint8Array(n)):((i=this).length=n,i._isBuffer=!0),s.TYPED_ARRAY_SUPPORT&&"number"==typeof t.byteLength)i._set(t);else if(function(t){return a(t)||s.isBuffer(t)||t&&"object"==typeof t&&"number"==typeof t.length}(t))if(s.isBuffer(t))for(u=0;un)&&(r=n);for(var i="",a=e;ar)throw new RangeError("Trying to access beyond buffer length")}function _(t,e,r,n,i,a){if(!s.isBuffer(t))throw new TypeError("buffer must be a Buffer instance");if(e>i||et.length)throw new TypeError("index out of range")}function g(t,e,r,n){e<0&&(e=65535+e+1);for(var i=0,a=Math.min(t.length-r,2);i>>8*(n?i:1-i)}function b(t,e,r,n){e<0&&(e=4294967295+e+1);for(var i=0,a=Math.min(t.length-r,4);i>>8*(n?i:3-i)&255}function w(t,e,r,n,i,a){if(e>i||et.length)throw new TypeError("index out of range")}function y(t,e,r,n,a){return a||w(t,e,r,4,3.4028234663852886e38,-3.4028234663852886e38),i.write(t,e,r,n,23,4),r+4}function v(t,e,r,n,a){return a||w(t,e,r,8,1.7976931348623157e308,-1.7976931348623157e308),i.write(t,e,r,n,52,8),r+8}s.TYPED_ARRAY_SUPPORT=function(){try{var t=new ArrayBuffer(0),e=new Uint8Array(t);return e.foo=function(){return 42},42===e.foo()&&"function"==typeof e.subarray&&0===new Uint8Array(1).subarray(1,1).byteLength}catch(t){return!1}}(),s.isBuffer=function(t){return!(null==t||!t._isBuffer)},s.compare=function(t,e){if(!s.isBuffer(t)||!s.isBuffer(e))throw new TypeError("Arguments must be Buffers");for(var r=t.length,n=e.length,i=0,a=Math.min(r,n);i>>1;break;case"utf8":case"utf-8":r=A(t).length;break;case"base64":r=z(t).length;break;default:r=t.length}return r},s.prototype.length=void 0,s.prototype.parent=void 0,s.prototype.toString=function(t,e,r){var n=!1;if(t||(t="utf8"),(e>>>=0)<0&&(e=0),(r=void 0===r||r===1/0?this.length:r>>>0)>this.length&&(r=this.length),r<=e)return"";for(;;)switch(t){case"hex":return c(this,e,r);case"utf8":case"utf-8":return h(this,e,r);case"ascii":return f(this,e,r);case"binary":return d(this,e,r);case"base64":return l(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return p(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}},s.prototype.equals=function(t){if(!s.isBuffer(t))throw new TypeError("Argument must be a Buffer");return 0===s.compare(this,t)},s.prototype.inspect=function(){var t="",e=r.INSPECT_MAX_BYTES;return this.length>0&&(t=this.toString("hex",0,e).match(/.{2}/g).join(" "),this.length>e&&(t+=" ... ")),""},s.prototype.compare=function(t){if(!s.isBuffer(t))throw new TypeError("Argument must be a Buffer");return s.compare(this,t)},s.prototype.get=function(t){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(t)},s.prototype.set=function(t,e){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(t,e)},s.prototype.write=function(t,e,r,n){if(isFinite(e))isFinite(r)||(n=r,r=void 0);else{var i=n;n=e,e=r,r=i}e=Number(e)||0;var a,o=this.length-e;switch(r?(r=Number(r))>o&&(r=o):r=o,n=String(n||"utf8").toLowerCase()){case"hex":a=function(t,e,r,n){r=Number(r)||0;var i=t.length-r;n?(n=Number(n))>i&&(n=i):n=i;var a=e.length;if(a%2!=0)throw new Error("Invalid hex string");n>a/2&&(n=a/2);for(var o=0;o>8,n=e%256,i.push(n),i.push(r);return i}(e),t,r,n,2)}(this,t,e,r);break;default:throw new TypeError("Unknown encoding: "+n)}return a},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},s.prototype.slice=function(t,e){var r=this.length;if((t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e>>=0,r||_(this,t,e,1,255,0),s.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=t,e+1},s.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8):g(this,t,e,!0),e+2},s.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t):g(this,t,e,!1),e+2},s.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=t):b(this,t,e,!0),e+4},s.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t):b(this,t,e,!1),e+4},s.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,1,127,-128),s.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=t,e+1},s.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8):g(this,t,e,!0),e+2},s.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t):g(this,t,e,!1),e+2},s.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,4,2147483647,-2147483648),s.TYPED_ARRAY_SUPPORT?(this[e]=t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):b(this,t,e,!0),e+4},s.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||_(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),s.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t):b(this,t,e,!1),e+4},s.prototype.writeFloatLE=function(t,e,r){return y(this,t,e,!0,r)},s.prototype.writeFloatBE=function(t,e,r){return y(this,t,e,!1,r)},s.prototype.writeDoubleLE=function(t,e,r){return v(this,t,e,!0,r)},s.prototype.writeDoubleBE=function(t,e,r){return v(this,t,e,!1,r)},s.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e||(e=0),n!==r&&0!==t.length&&0!==this.length){if(n=t.length)throw new TypeError("targetStart out of bounds");if(r<0||r>=this.length)throw new TypeError("sourceStart out of bounds");if(n<0||n>this.length)throw new TypeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e=this.length)throw new TypeError("start out of bounds");if(r<0||r>this.length)throw new TypeError("end out of bounds");var n;if("number"==typeof t)for(n=e;n=55296&&n<=57343&&r++;for(var a=encodeURIComponent(t.slice(i,r+1)).substr(1).split("%"),o=0;o=e.length||a>=t.length);a++)e[a+r]=t[a];return a}function C(t){try{return decodeURIComponent(t)}catch(t){return String.fromCharCode(65533)}}},{"base64-js":2,ieee754:3,"is-array":4}],2:[function(t,e,r){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(t){"use strict";var e="undefined"!=typeof Uint8Array?Uint8Array:Array,r="+".charCodeAt(0),i="/".charCodeAt(0),a="0".charCodeAt(0),o="a".charCodeAt(0),s="A".charCodeAt(0);function u(t){var e=t.charCodeAt(0);return e===r?62:e===i?63:e0)throw new Error("Invalid string. Length must be a multiple of 4");var l=t.length;o="="===t.charAt(l-2)?2:"="===t.charAt(l-1)?1:0,s=new e(3*t.length/4-o),i=o>0?t.length-4:t.length;var h=0;function f(t){s[h++]=t}for(r=0,n=0;r>16),f((65280&a)>>8),f(255&a);return 2===o?f(255&(a=u(t.charAt(r))<<2|u(t.charAt(r+1))>>4)):1===o&&(f((a=u(t.charAt(r))<<10|u(t.charAt(r+1))<<4|u(t.charAt(r+2))>>2)>>8&255),f(255&a)),s},t.fromByteArray=function(t){var e,r,i,a,o=t.length%3,s="";function u(t){return n.charAt(t)}for(e=0,i=t.length-o;e>18&63)+u(a>>12&63)+u(a>>6&63)+u(63&a);switch(o){case 1:s+=u((r=t[t.length-1])>>2),s+=u(r<<4&63),s+="==";break;case 2:s+=u((r=(t[t.length-2]<<8)+t[t.length-1])>>10),s+=u(r>>4&63),s+=u(r<<2&63),s+="="}return s}}(void 0===r?this.base64js={}:r)},{}],3:[function(t,e,r){r.read=function(t,e,r,n,i){var a,o,s=8*i-n-1,u=(1<>1,h=-7,f=r?i-1:0,d=r?-1:1,c=t[e+f];for(f+=d,a=c&(1<<-h)-1,c>>=-h,h+=s;h>0;a=256*a+t[e+f],f+=d,h-=8);for(o=a&(1<<-h)-1,a>>=-h,h+=n;h>0;o=256*o+t[e+f],f+=d,h-=8);if(0===a)a=1-l;else{if(a===u)return o?NaN:1/0*(c?-1:1);o+=Math.pow(2,n),a-=l}return(c?-1:1)*o*Math.pow(2,a-n)},r.write=function(t,e,r,n,i,a){var o,s,u,l=8*a-i-1,h=(1<>1,d=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,c=n?0:a-1,p=n?1:-1,m=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,o=h):(o=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-o))<1&&(o--,u*=2),(e+=o+f>=1?d/u:d*Math.pow(2,1-f))*u>=2&&(o++,u/=2),o+f>=h?(s=0,o=h):o+f>=1?(s=(e*u-1)*Math.pow(2,i),o+=f):(s=e*Math.pow(2,f-1)*Math.pow(2,i),o=0));i>=8;t[r+c]=255&s,c+=p,s/=256,i-=8);for(o=o<0;t[r+c]=255&o,c+=p,o/=256,l-=8);t[r+c-p]|=128*m}},{}],4:[function(t,e,r){var n=Array.isArray,i=Object.prototype.toString;e.exports=n||function(t){return!!t&&"[object Array]"==i.call(t)}},{}],5:[function(t,e,r){"use strict";var n=t("./dataReader");function i(t){if(t){this.data=t,this.length=this.data.length,this.index=0,this.zero=0;for(var e=0;e=0;--a)if(this.data[a]===e&&this.data[a+1]===r&&this.data[a+2]===n&&this.data[a+3]===i)return a-this.zero;return-1},i.prototype.readData=function(t){if(this.checkOffset(t),0===t)return[];var e=this.data.slice(this.zero+this.index,this.zero+this.index+t);return this.index+=t,e},e.exports=i},{"./dataReader":10}],6:[function(t,e,r){"use strict";var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";r.encode=function(t,e){for(var r,i,a,o,s,u,l,h="",f=0;f>2,s=(3&r)<<4|(i=t.charCodeAt(f++))>>4,u=(15&i)<<2|(a=t.charCodeAt(f++))>>6,l=63&a,isNaN(i)?u=l=64:isNaN(a)&&(l=64),h=h+n.charAt(o)+n.charAt(s)+n.charAt(u)+n.charAt(l);return h},r.decode=function(t,e){var r,i,a,o,s,u,l="",h=0;for(t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");h>4,i=(15&o)<<4|(s=n.indexOf(t.charAt(h++)))>>2,a=(3&s)<<6|(u=n.indexOf(t.charAt(h++))),l+=String.fromCharCode(r),64!=s&&(l+=String.fromCharCode(i)),64!=u&&(l+=String.fromCharCode(a));return l}},{}],7:[function(t,e,r){"use strict";function n(){this.compressedSize=0,this.uncompressedSize=0,this.crc32=0,this.compressionMethod=null,this.compressedContent=null}n.prototype={getContent:function(){return null},getCompressedContent:function(){return null}},e.exports=n},{}],8:[function(t,e,r){"use strict";r.STORE={magic:"\0\0",compress:function(t,e){return t},uncompress:function(t){return t},compressInputType:null,uncompressInputType:null},r.DEFLATE=t("./flate")},{"./flate":13}],9:[function(t,e,r){"use strict";var n=t("./utils"),i=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];e.exports=function(t,e){if(void 0===t||!t.length)return 0;var r="string"!==n.getTypeOf(t);void 0===e&&(e=0);var a=0;e^=-1;for(var o=0,s=t.length;o>>8^i[255&(e^a)];return-1^e}},{"./utils":26}],10:[function(t,e,r){"use strict";var n=t("./utils");function i(t){this.data=null,this.length=0,this.index=0,this.zero=0}i.prototype={checkOffset:function(t){this.checkIndex(this.index+t)},checkIndex:function(t){if(this.length=this.index;e--)r=(r<<8)+this.byteAt(e);return this.index+=t,r},readString:function(t){return n.transformTo("string",this.readData(t))},readData:function(t){},lastIndexOfSignature:function(t){},readDate:function(){var t=this.readInt(4);return new Date(1980+(t>>25&127),(t>>21&15)-1,t>>16&31,t>>11&31,t>>5&63,(31&t)<<1)}},e.exports=i},{"./utils":26}],11:[function(t,e,r){"use strict";r.base64=!1,r.binary=!1,r.dir=!1,r.createFolders=!1,r.date=null,r.compression=null,r.compressionOptions=null,r.comment=null,r.unixPermissions=null,r.dosPermissions=null},{}],12:[function(t,e,r){"use strict";var n=t("./utils");r.string2binary=function(t){return n.string2binary(t)},r.string2Uint8Array=function(t){return n.transformTo("uint8array",t)},r.uint8Array2String=function(t){return n.transformTo("string",t)},r.string2Blob=function(t){var e=n.transformTo("arraybuffer",t);return n.arrayBuffer2Blob(e)},r.arrayBuffer2Blob=function(t){return n.arrayBuffer2Blob(t)},r.transformTo=function(t,e){return n.transformTo(t,e)},r.getTypeOf=function(t){return n.getTypeOf(t)},r.checkSupport=function(t){return n.checkSupport(t)},r.MAX_VALUE_16BITS=n.MAX_VALUE_16BITS,r.MAX_VALUE_32BITS=n.MAX_VALUE_32BITS,r.pretty=function(t){return n.pretty(t)},r.findCompression=function(t){return n.findCompression(t)},r.isRegExp=function(t){return n.isRegExp(t)}},{"./utils":26}],13:[function(t,e,r){"use strict";var n="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,i=t("pako");r.uncompressInputType=n?"uint8array":"array",r.compressInputType=n?"uint8array":"array",r.magic="\b\0",r.compress=function(t,e){return i.deflateRaw(t,{level:e.level||-1})},r.uncompress=function(t){return i.inflateRaw(t)}},{pako:29}],14:[function(t,e,r){"use strict";var n=t("./base64");function i(t,e){if(!(this instanceof i))return new i(t,e);this.files={},this.comment=null,this.root="",t&&this.load(t,e),this.clone=function(){var t=new i;for(var e in this)"function"!=typeof this[e]&&(t[e]=this[e]);return t}}i.prototype=t("./object"),i.prototype.load=t("./load"),i.support=t("./support"),i.defaults=t("./defaults"),i.utils=t("./deprecatedPublicUtils"),i.base64={encode:function(t){return n.encode(t)},decode:function(t){return n.decode(t)}},i.compressions=t("./compressions"),e.exports=i},{"./base64":6,"./compressions":8,"./defaults":11,"./deprecatedPublicUtils":12,"./load":15,"./object":18,"./support":22}],15:[function(t,e,r){"use strict";var n=t("./base64"),i=t("./utf8"),a=t("./utils"),o=t("./zipEntries");e.exports=function(t,e){var r,s,u,l;for((e=a.extend(e||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:i.utf8decode})).base64&&(t=n.decode(t)),r=(s=new o(t,e)).files,u=0;u>>=8;return n},y=function(t,e,r){var n,a=i.getTypeOf(e);if("string"==typeof(r=function(t){return!0!==(t=t||{}).base64||null!==t.binary&&void 0!==t.binary||(t.binary=!0),(t=i.extend(t,s)).date=t.date||new Date,null!==t.compression&&(t.compression=t.compression.toUpperCase()),t}(r)).unixPermissions&&(r.unixPermissions=parseInt(r.unixPermissions,8)),r.unixPermissions&&16384&r.unixPermissions&&(r.dir=!0),r.dosPermissions&&16&r.dosPermissions&&(r.dir=!0),r.dir&&(t=x(t)),r.createFolders&&(n=v(t))&&k.call(this,n,!0),r.dir||null==e)r.base64=!1,r.binary=!1,e=null,a=null;else if("string"===a)r.binary&&!r.base64&&!0!==r.optimizedBinaryString&&(e=i.string2binary(e));else{if(r.base64=!1,r.binary=!0,!(a||e instanceof h))throw new Error("The data of '"+t+"' is in an unsupported format !");"arraybuffer"===a&&(e=i.transformTo("uint8array",e))}var o=new b(t,e,r);return this.files[t]=o,o},v=function(t){"/"==t.slice(-1)&&(t=t.substring(0,t.length-1));var e=t.lastIndexOf("/");return e>0?t.substring(0,e):""},x=function(t){return"/"!=t.slice(-1)&&(t+="/"),t},k=function(t,e){return e=void 0!==e&&e,t=x(t),this.files[t]||y.call(this,t,null,{dir:!0,createFolders:e}),this.files[t]},E=function(t,e,r){var n,o=new h;return t._data instanceof h?(o.uncompressedSize=t._data.uncompressedSize,o.crc32=t._data.crc32,0===o.uncompressedSize||t.dir?(e=l.STORE,o.compressedContent="",o.crc32=0):t._data.compressionMethod===e.magic?o.compressedContent=t._data.getCompressedContent():(n=t._data.getContent(),o.compressedContent=e.compress(i.transformTo(e.compressInputType,n),r))):((n=_(t))&&0!==n.length&&!t.dir||(e=l.STORE,n=""),o.uncompressedSize=n.length,o.crc32=a(n),o.compressedContent=e.compress(i.transformTo(e.compressInputType,n),r)),o.compressedSize=o.compressedContent.length,o.compressionMethod=e.magic,o},A=function(t,e,r,n,s,u){r.compressedContent;var l,h,f,c,p=u!==d.utf8encode,m=i.transformTo("string",u(e.name)),_=i.transformTo("string",d.utf8encode(e.name)),g=e.comment||"",b=i.transformTo("string",u(g)),y=i.transformTo("string",d.utf8encode(g)),v=_.length!==e.name.length,x=y.length!==g.length,k=e.options,E="",A="",z="";f=e._initialMetadata.dir!==e.dir?e.dir:k.dir,c=e._initialMetadata.date!==e.date?e.date:k.date;var I,C,S=0,B=0;f&&(S|=16),"UNIX"===s?(B=798,S|=(I=e.unixPermissions,C=I,I||(C=f?16893:33204),(65535&C)<<16)):(B=20,S|=63&(e.dosPermissions||0)),l=c.getHours(),l<<=6,l|=c.getMinutes(),l<<=5,l|=c.getSeconds()/2,h=c.getFullYear()-1980,h<<=4,h|=c.getMonth()+1,h<<=5,h|=c.getDate(),v&&(A=w(1,1)+w(a(m),4)+_,E+="up"+w(A.length,2)+A),x&&(z=w(1,1)+w(this.crc32(b),4)+y,E+="uc"+w(z.length,2)+z);var R="";return R+="\n\0",R+=p||!v&&!x?"\0\0":"\0\b",R+=r.compressionMethod,R+=w(l,2),R+=w(h,2),R+=w(r.crc32,4),R+=w(r.compressedSize,4),R+=w(r.uncompressedSize,4),R+=w(m.length,2),R+=w(E.length,2),{fileRecord:o.LOCAL_FILE_HEADER+R+m+E,dirRecord:o.CENTRAL_FILE_HEADER+w(B,2)+R+w(b.length,2)+"\0\0\0\0"+w(S,4)+w(n,4)+m+E+b,compressedObject:r}},z={load:function(t,e){throw new Error("Load method is not defined. Is the file jszip-load.js included ?")},filter:function(t){var e,r,n,a,o=[];for(e in this.files)this.files.hasOwnProperty(e)&&(n=this.files[e],a=new b(n.name,n._data,i.extend(n.options)),r=e.slice(this.root.length,e.length),e.slice(0,this.root.length)===this.root&&t(r,a)&&o.push(a));return o},file:function(t,e,r){if(1===arguments.length){if(i.isRegExp(t)){var n=t;return this.filter(function(t,e){return!e.dir&&n.test(t)})}return this.filter(function(e,r){return!r.dir&&e===t})[0]||null}return t=this.root+t,y.call(this,t,e,r),this},folder:function(t){if(!t)return this;if(i.isRegExp(t))return this.filter(function(e,r){return r.dir&&t.test(e)});var e=this.root+t,r=k.call(this,e),n=this.clone();return n.root=r.name,n},remove:function(t){t=this.root+t;var e=this.files[t];if(e||("/"!=t.slice(-1)&&(t+="/"),e=this.files[t]),e&&!e.dir)delete this.files[t];else for(var r=this.filter(function(e,r){return r.name.slice(0,t.length)===t}),n=0;n=252?6:s>=248?5:s>=240?4:s>=224?3:s>=192?2:1;o[254]=o[254]=1;var u=function(t,e){var r;for((e=e||t.length)>t.length&&(e=t.length),r=e-1;r>=0&&128==(192&t[r]);)r--;return r<0?e:0===r?e:r+o[t[r]]>e?r:e},l=function(t){var e,r,i,a,s=t.length,u=new Array(2*s);for(r=0,e=0;e4)u[r++]=65533,e+=a-1;else{for(i&=2===a?31:3===a?15:7;a>1&&e1?u[r++]=65533:i<65536?u[r++]=i:(i-=65536,u[r++]=55296|i>>10&1023,u[r++]=56320|1023&i)}return u.length!==r&&(u.subarray?u=u.subarray(0,r):u.length=r),n.applyFromCharCode(u)};r.utf8encode=function(t){return i.nodebuffer?a(t,"utf-8"):function(t){var e,r,n,a,o,s=t.length,u=0;for(a=0;a>>6,e[o++]=128|63&r):r<65536?(e[o++]=224|r>>>12,e[o++]=128|r>>>6&63,e[o++]=128|63&r):(e[o++]=240|r>>>18,e[o++]=128|r>>>12&63,e[o++]=128|r>>>6&63,e[o++]=128|63&r);return e}(t)},r.utf8decode=function(t){if(i.nodebuffer)return n.transformTo("nodebuffer",t).toString("utf-8");for(var e=[],r=0,a=(t=n.transformTo(i.uint8array?"uint8array":"array",t)).length;r1;)try{"array"===o||"nodebuffer"===o?n.push(String.fromCharCode.apply(null,t.slice(s,Math.min(s+e,i)))):n.push(String.fromCharCode.apply(null,t.subarray(s,Math.min(s+e,i)))),s+=e}catch(t){e=Math.floor(e/2)}return n.join("")}function l(t,e){for(var r=0;r1)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var t,e;for(t=0;t0)this.isSignature(e,u.CENTRAL_FILE_HEADER)||(this.reader.zero=n);else if(n<0)throw new Error("Corrupted zip: missing "+Math.abs(n)+" bytes.")},prepareReader:function(t){var e=s.getTypeOf(t);if(s.checkSupport(e),"string"!==e||h.uint8array)if("nodebuffer"===e)this.reader=new i(t);else if(h.uint8array)this.reader=new a(s.transformTo("uint8array",t));else{if(!h.array)throw new Error("Unexpected error: unsupported type '"+e+"'");this.reader=new o(s.transformTo("array",t))}else this.reader=new n(t,this.loadOptions.optimizedBinaryString)},load:function(t){this.prepareReader(t),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},e.exports=f},{"./arrayReader":5,"./nodeBufferReader":17,"./object":18,"./signature":19,"./stringReader":20,"./support":22,"./uint8ArrayReader":23,"./utils":26,"./zipEntry":28}],28:[function(t,e,r){"use strict";var n=t("./stringReader"),i=t("./utils"),a=t("./compressedObject"),o=t("./object"),s=t("./support");function u(t,e){this.options=t,this.loadOptions=e}u.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},prepareCompressedContent:function(t,e,r){return function(){var n=t.index;t.setIndex(e);var i=t.readData(r);return t.setIndex(n),i}},prepareContent:function(t,e,r,n,a){return function(){var t=i.transformTo(n.uncompressInputType,this.getCompressedContent()),e=n.uncompress(t);if(e.length!==a)throw new Error("Bug : uncompressed data size mismatch");return e}},readLocalPart:function(t){var e,r;if(t.skip(22),this.fileNameLength=t.readInt(2),r=t.readInt(2),this.fileName=t.readData(this.fileNameLength),t.skip(r),-1==this.compressedSize||-1==this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize == -1 || uncompressedSize == -1)");if(null===(e=i.findCompression(this.compressionMethod)))throw new Error("Corrupted zip : compression "+i.pretty(this.compressionMethod)+" unknown (inner file : "+i.transformTo("string",this.fileName)+")");if(this.decompressed=new a,this.decompressed.compressedSize=this.compressedSize,this.decompressed.uncompressedSize=this.uncompressedSize,this.decompressed.crc32=this.crc32,this.decompressed.compressionMethod=this.compressionMethod,this.decompressed.getCompressedContent=this.prepareCompressedContent(t,t.index,this.compressedSize,e),this.decompressed.getContent=this.prepareContent(t,t.index,this.compressedSize,e,this.uncompressedSize),this.loadOptions.checkCRC32&&(this.decompressed=i.transformTo("string",this.decompressed.getContent()),o.crc32(this.decompressed)!==this.crc32))throw new Error("Corrupted zip : CRC32 mismatch")},readCentralPart:function(t){if(this.versionMadeBy=t.readInt(2),this.versionNeeded=t.readInt(2),this.bitFlag=t.readInt(2),this.compressionMethod=t.readString(2),this.date=t.readDate(),this.crc32=t.readInt(4),this.compressedSize=t.readInt(4),this.uncompressedSize=t.readInt(4),this.fileNameLength=t.readInt(2),this.extraFieldsLength=t.readInt(2),this.fileCommentLength=t.readInt(2),this.diskNumberStart=t.readInt(2),this.internalFileAttributes=t.readInt(2),this.externalFileAttributes=t.readInt(4),this.localHeaderOffset=t.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");this.fileName=t.readData(this.fileNameLength),this.readExtraFields(t),this.parseZIP64ExtraField(t),this.fileComment=t.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var t=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0===t&&(this.dosPermissions=63&this.externalFileAttributes),3===t&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(t){if(this.extraFields[1]){var e=new n(this.extraFields[1].value);this.uncompressedSize===i.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===i.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===i.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===i.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},readExtraFields:function(t){var e,r,n,i=t.index;for(this.extraFields=this.extraFields||{};t.index0?e.windowBits=-e.windowBits:e.gzip&&e.windowBits>0&&e.windowBits<16&&(e.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new s,this.strm.avail_out=0;var r=n.deflateInit2(this.strm,e.level,e.method,e.windowBits,e.memLevel,e.strategy);if(r!==l)throw new Error(o[r]);if(e.header&&n.deflateSetHeader(this.strm,e.header),e.dictionary){var p;if(p="string"==typeof e.dictionary?a.string2buf(e.dictionary):"[object ArrayBuffer]"===u.call(e.dictionary)?new Uint8Array(e.dictionary):e.dictionary,(r=n.deflateSetDictionary(this.strm,p))!==l)throw new Error(o[r]);this._dict_set=!0}}function p(t,e){var r=new c(e);if(r.push(t,!0),r.err)throw r.msg;return r.result}c.prototype.push=function(t,e){var r,o,s=this.strm,h=this.options.chunkSize;if(this.ended)return!1;o=e===~~e?e:!0===e?4:0,"string"==typeof t?s.input=a.string2buf(t):"[object ArrayBuffer]"===u.call(t)?s.input=new Uint8Array(t):s.input=t,s.next_in=0,s.avail_in=s.input.length;do{if(0===s.avail_out&&(s.output=new i.Buf8(h),s.next_out=0,s.avail_out=h),1!==(r=n.deflate(s,o))&&r!==l)return this.onEnd(r),this.ended=!0,!1;0!==s.avail_out&&(0!==s.avail_in||4!==o&&2!==o)||("string"===this.options.to?this.onData(a.buf2binstring(i.shrinkBuf(s.output,s.next_out))):this.onData(i.shrinkBuf(s.output,s.next_out)))}while((s.avail_in>0||0===s.avail_out)&&1!==r);return 4===o?(r=n.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===l):2!==o||(this.onEnd(l),s.avail_out=0,!0)},c.prototype.onData=function(t){this.chunks.push(t)},c.prototype.onEnd=function(t){t===l&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg},r.Deflate=c,r.deflate=p,r.deflateRaw=function(t,e){return(e=e||{}).raw=!0,p(t,e)},r.gzip=function(t,e){return(e=e||{}).gzip=!0,p(t,e)}},{"./utils/common":32,"./utils/strings":33,"./zlib/deflate":37,"./zlib/messages":42,"./zlib/zstream":44}],31:[function(t,e,r){"use strict";var n=t("./zlib/inflate"),i=t("./utils/common"),a=t("./utils/strings"),o=t("./zlib/constants"),s=t("./zlib/messages"),u=t("./zlib/zstream"),l=t("./zlib/gzheader"),h=Object.prototype.toString;function f(t){if(!(this instanceof f))return new f(t);this.options=i.assign({chunkSize:16384,windowBits:0,to:""},t||{});var e=this.options;e.raw&&e.windowBits>=0&&e.windowBits<16&&(e.windowBits=-e.windowBits,0===e.windowBits&&(e.windowBits=-15)),!(e.windowBits>=0&&e.windowBits<16)||t&&t.windowBits||(e.windowBits+=32),e.windowBits>15&&e.windowBits<48&&0==(15&e.windowBits)&&(e.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new u,this.strm.avail_out=0;var r=n.inflateInit2(this.strm,e.windowBits);if(r!==o.Z_OK)throw new Error(s[r]);this.header=new l,n.inflateGetHeader(this.strm,this.header)}function d(t,e){var r=new f(e);if(r.push(t,!0),r.err)throw r.msg;return r.result}f.prototype.push=function(t,e){var r,s,u,l,f,d,c=this.strm,p=this.options.chunkSize,m=this.options.dictionary,_=!1;if(this.ended)return!1;s=e===~~e?e:!0===e?o.Z_FINISH:o.Z_NO_FLUSH,"string"==typeof t?c.input=a.binstring2buf(t):"[object ArrayBuffer]"===h.call(t)?c.input=new Uint8Array(t):c.input=t,c.next_in=0,c.avail_in=c.input.length;do{if(0===c.avail_out&&(c.output=new i.Buf8(p),c.next_out=0,c.avail_out=p),(r=n.inflate(c,o.Z_NO_FLUSH))===o.Z_NEED_DICT&&m&&(d="string"==typeof m?a.string2buf(m):"[object ArrayBuffer]"===h.call(m)?new Uint8Array(m):m,r=n.inflateSetDictionary(this.strm,d)),r===o.Z_BUF_ERROR&&!0===_&&(r=o.Z_OK,_=!1),r!==o.Z_STREAM_END&&r!==o.Z_OK)return this.onEnd(r),this.ended=!0,!1;c.next_out&&(0!==c.avail_out&&r!==o.Z_STREAM_END&&(0!==c.avail_in||s!==o.Z_FINISH&&s!==o.Z_SYNC_FLUSH)||("string"===this.options.to?(u=a.utf8border(c.output,c.next_out),l=c.next_out-u,f=a.buf2string(c.output,u),c.next_out=l,c.avail_out=p-l,l&&i.arraySet(c.output,c.output,u,l,0),this.onData(f)):this.onData(i.shrinkBuf(c.output,c.next_out)))),0===c.avail_in&&0===c.avail_out&&(_=!0)}while((c.avail_in>0||0===c.avail_out)&&r!==o.Z_STREAM_END);return r===o.Z_STREAM_END&&(s=o.Z_FINISH),s===o.Z_FINISH?(r=n.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===o.Z_OK):s!==o.Z_SYNC_FLUSH||(this.onEnd(o.Z_OK),c.avail_out=0,!0)},f.prototype.onData=function(t){this.chunks.push(t)},f.prototype.onEnd=function(t){t===o.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg},r.Inflate=f,r.inflate=d,r.inflateRaw=function(t,e){return(e=e||{}).raw=!0,d(t,e)},r.ungzip=d},{"./utils/common":32,"./utils/strings":33,"./zlib/constants":35,"./zlib/gzheader":38,"./zlib/inflate":40,"./zlib/messages":42,"./zlib/zstream":44}],32:[function(t,e,r){"use strict";var n="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;r.assign=function(t){for(var e=Array.prototype.slice.call(arguments,1);e.length;){var r=e.shift();if(r){if("object"!=typeof r)throw new TypeError(r+"must be non-object");for(var n in r)r.hasOwnProperty(n)&&(t[n]=r[n])}}return t},r.shrinkBuf=function(t,e){return t.length===e?t:t.subarray?t.subarray(0,e):(t.length=e,t)};var i={arraySet:function(t,e,r,n,i){if(e.subarray&&t.subarray)t.set(e.subarray(r,r+n),i);else for(var a=0;a=252?6:s>=248?5:s>=240?4:s>=224?3:s>=192?2:1;function u(t,e){if(e<65537&&(t.subarray&&a||!t.subarray&&i))return String.fromCharCode.apply(null,n.shrinkBuf(t,e));for(var r="",o=0;o>>6,e[o++]=128|63&r):r<65536?(e[o++]=224|r>>>12,e[o++]=128|r>>>6&63,e[o++]=128|63&r):(e[o++]=240|r>>>18,e[o++]=128|r>>>12&63,e[o++]=128|r>>>6&63,e[o++]=128|63&r);return e},r.buf2binstring=function(t){return u(t,t.length)},r.binstring2buf=function(t){for(var e=new n.Buf8(t.length),r=0,i=e.length;r4)l[n++]=65533,r+=a-1;else{for(i&=2===a?31:3===a?15:7;a>1&&r1?l[n++]=65533:i<65536?l[n++]=i:(i-=65536,l[n++]=55296|i>>10&1023,l[n++]=56320|1023&i)}return u(l,n)},r.utf8border=function(t,e){var r;for((e=e||t.length)>t.length&&(e=t.length),r=e-1;r>=0&&128==(192&t[r]);)r--;return r<0?e:0===r?e:r+o[t[r]]>e?r:e}},{"./common":32}],34:[function(t,e,r){"use strict";e.exports=function(t,e,r,n){for(var i=65535&t|0,a=t>>>16&65535|0,o=0;0!==r;){r-=o=r>2e3?2e3:r;do{a=a+(i=i+e[n++]|0)|0}while(--o);i%=65521,a%=65521}return i|a<<16|0}},{}],35:[function(t,e,r){"use strict";e.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}},{}],36:[function(t,e,r){"use strict";var n=function(){for(var t,e=[],r=0;r<256;r++){t=r;for(var n=0;n<8;n++)t=1&t?3988292384^t>>>1:t>>>1;e[r]=t}return e}();e.exports=function(t,e,r,i){var a=n,o=i+r;t^=-1;for(var s=i;s>>8^a[255&(t^e[s])];return-1^t}},{}],37:[function(t,e,r){"use strict";var n,i=t("../utils/common"),a=t("./trees"),o=t("./adler32"),s=t("./crc32"),u=t("./messages"),l=0,h=1,f=3,d=4,c=5,p=0,m=1,_=-2,g=-3,b=-5,w=-1,y=1,v=2,x=3,k=4,E=0,A=2,z=8,I=9,C=15,S=8,B=286,R=30,T=19,O=2*B+1,L=15,D=3,U=258,j=U+D+1,P=32,N=42,F=69,Z=73,M=91,Y=103,W=113,H=666,V=1,G=2,X=3,K=4,J=3;function q(t,e){return t.msg=u[e],e}function $(t){return(t<<1)-(t>4?9:0)}function Q(t){for(var e=t.length;--e>=0;)t[e]=0}function tt(t){var e=t.state,r=e.pending;r>t.avail_out&&(r=t.avail_out),0!==r&&(i.arraySet(t.output,e.pending_buf,e.pending_out,r,t.next_out),t.next_out+=r,e.pending_out+=r,t.total_out+=r,t.avail_out-=r,e.pending-=r,0===e.pending&&(e.pending_out=0))}function et(t,e){a._tr_flush_block(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,e),t.block_start=t.strstart,tt(t.strm)}function rt(t,e){t.pending_buf[t.pending++]=e}function nt(t,e){t.pending_buf[t.pending++]=e>>>8&255,t.pending_buf[t.pending++]=255&e}function it(t,e){var r,n,i=t.max_chain_length,a=t.strstart,o=t.prev_length,s=t.nice_match,u=t.strstart>t.w_size-j?t.strstart-(t.w_size-j):0,l=t.window,h=t.w_mask,f=t.prev,d=t.strstart+U,c=l[a+o-1],p=l[a+o];t.prev_length>=t.good_match&&(i>>=2),s>t.lookahead&&(s=t.lookahead);do{if(l[(r=e)+o]===p&&l[r+o-1]===c&&l[r]===l[a]&&l[++r]===l[a+1]){a+=2,r++;do{}while(l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&l[++a]===l[++r]&&ao){if(t.match_start=e,o=n,n>=s)break;c=l[a+o-1],p=l[a+o]}}}while((e=f[e&h])>u&&0!=--i);return o<=t.lookahead?o:t.lookahead}function at(t){var e,r,n,a,u,l,h,f,d,c,p=t.w_size;do{if(a=t.window_size-t.lookahead-t.strstart,t.strstart>=p+(p-j)){i.arraySet(t.window,t.window,p,p,0),t.match_start-=p,t.strstart-=p,t.block_start-=p,e=r=t.hash_size;do{n=t.head[--e],t.head[e]=n>=p?n-p:0}while(--r);e=r=p;do{n=t.prev[--e],t.prev[e]=n>=p?n-p:0}while(--r);a+=p}if(0===t.strm.avail_in)break;if(l=t.strm,h=t.window,f=t.strstart+t.lookahead,d=a,c=void 0,(c=l.avail_in)>d&&(c=d),r=0===c?0:(l.avail_in-=c,i.arraySet(h,l.input,l.next_in,c,f),1===l.state.wrap?l.adler=o(l.adler,h,c,f):2===l.state.wrap&&(l.adler=s(l.adler,h,c,f)),l.next_in+=c,l.total_in+=c,c),t.lookahead+=r,t.lookahead+t.insert>=D)for(u=t.strstart-t.insert,t.ins_h=t.window[u],t.ins_h=(t.ins_h<=D&&(t.ins_h=(t.ins_h<=D)if(n=a._tr_tally(t,t.strstart-t.match_start,t.match_length-D),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=D){t.match_length--;do{t.strstart++,t.ins_h=(t.ins_h<=D&&(t.ins_h=(t.ins_h<4096)&&(t.match_length=D-1)),t.prev_length>=D&&t.match_length<=t.prev_length){i=t.strstart+t.lookahead-D,n=a._tr_tally(t,t.strstart-1-t.prev_match,t.prev_length-D),t.lookahead-=t.prev_length-1,t.prev_length-=2;do{++t.strstart<=i&&(t.ins_h=(t.ins_h<15&&(s=2,n-=16),a<1||a>I||r!==z||n<8||n>15||e<0||e>9||o<0||o>k)return q(t,_);8===n&&(n=9);var u=new function(){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=z,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 i.Buf16(2*O),this.dyn_dtree=new i.Buf16(2*(2*R+1)),this.bl_tree=new i.Buf16(2*(2*T+1)),Q(this.dyn_ltree),Q(this.dyn_dtree),Q(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i.Buf16(L+1),this.heap=new i.Buf16(2*B+1),Q(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i.Buf16(2*B+1),Q(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};return t.state=u,u.strm=t,u.wrap=s,u.gzhead=null,u.w_bits=n,u.w_size=1<>1,u.l_buf=3*u.lit_bufsize,u.level=e,u.strategy=o,u.method=r,ht(t)}n=[new ut(0,0,0,0,function(t,e){var r=65535;for(r>t.pending_buf_size-5&&(r=t.pending_buf_size-5);;){if(t.lookahead<=1){if(at(t),0===t.lookahead&&e===l)return V;if(0===t.lookahead)break}t.strstart+=t.lookahead,t.lookahead=0;var n=t.block_start+r;if((0===t.strstart||t.strstart>=n)&&(t.lookahead=t.strstart-n,t.strstart=n,et(t,!1),0===t.strm.avail_out))return V;if(t.strstart-t.block_start>=t.w_size-j&&(et(t,!1),0===t.strm.avail_out))return V}return t.insert=0,e===d?(et(t,!0),0===t.strm.avail_out?X:K):(t.strstart>t.block_start&&(et(t,!1),t.strm.avail_out),V)}),new ut(4,4,8,4,ot),new ut(4,5,16,8,ot),new ut(4,6,32,32,ot),new ut(4,4,16,16,st),new ut(8,16,32,32,st),new ut(8,16,128,128,st),new ut(8,32,128,256,st),new ut(32,128,258,1024,st),new ut(32,258,258,4096,st)],r.deflateInit=function(t,e){return ft(t,e,z,C,S,E)},r.deflateInit2=ft,r.deflateReset=ht,r.deflateResetKeep=lt,r.deflateSetHeader=function(t,e){return t&&t.state?2!==t.state.wrap?_:(t.state.gzhead=e,p):_},r.deflate=function(t,e){var r,i,o,u;if(!t||!t.state||e>c||e<0)return t?q(t,_):_;if(i=t.state,!t.output||!t.input&&0!==t.avail_in||i.status===H&&e!==d)return q(t,0===t.avail_out?b:_);if(i.strm=t,r=i.last_flush,i.last_flush=e,i.status===N)if(2===i.wrap)t.adler=0,rt(i,31),rt(i,139),rt(i,8),i.gzhead?(rt(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),rt(i,255&i.gzhead.time),rt(i,i.gzhead.time>>8&255),rt(i,i.gzhead.time>>16&255),rt(i,i.gzhead.time>>24&255),rt(i,9===i.level?2:i.strategy>=v||i.level<2?4:0),rt(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(rt(i,255&i.gzhead.extra.length),rt(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(t.adler=s(t.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=F):(rt(i,0),rt(i,0),rt(i,0),rt(i,0),rt(i,0),rt(i,9===i.level?2:i.strategy>=v||i.level<2?4:0),rt(i,J),i.status=W);else{var g=z+(i.w_bits-8<<4)<<8;g|=(i.strategy>=v||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(g|=P),g+=31-g%31,i.status=W,nt(i,g),0!==i.strstart&&(nt(i,t.adler>>>16),nt(i,65535&t.adler)),t.adler=1}if(i.status===F)if(i.gzhead.extra){for(o=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>o&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),tt(t),o=i.pending,i.pending!==i.pending_buf_size));)rt(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>o&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=Z)}else i.status=Z;if(i.status===Z)if(i.gzhead.name){o=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>o&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),tt(t),o=i.pending,i.pending===i.pending_buf_size)){u=1;break}u=i.gzindexo&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),0===u&&(i.gzindex=0,i.status=M)}else i.status=M;if(i.status===M)if(i.gzhead.comment){o=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>o&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),tt(t),o=i.pending,i.pending===i.pending_buf_size)){u=1;break}u=i.gzindexo&&(t.adler=s(t.adler,i.pending_buf,i.pending-o,o)),0===u&&(i.status=Y)}else i.status=Y;if(i.status===Y&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&tt(t),i.pending+2<=i.pending_buf_size&&(rt(i,255&t.adler),rt(i,t.adler>>8&255),t.adler=0,i.status=W)):i.status=W),0!==i.pending){if(tt(t),0===t.avail_out)return i.last_flush=-1,p}else if(0===t.avail_in&&$(e)<=$(r)&&e!==d)return q(t,b);if(i.status===H&&0!==t.avail_in)return q(t,b);if(0!==t.avail_in||0!==i.lookahead||e!==l&&i.status!==H){var w=i.strategy===v?function(t,e){for(var r;;){if(0===t.lookahead&&(at(t),0===t.lookahead)){if(e===l)return V;break}if(t.match_length=0,r=a._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,r&&(et(t,!1),0===t.strm.avail_out))return V}return t.insert=0,e===d?(et(t,!0),0===t.strm.avail_out?X:K):t.last_lit&&(et(t,!1),0===t.strm.avail_out)?V:G}(i,e):i.strategy===x?function(t,e){for(var r,n,i,o,s=t.window;;){if(t.lookahead<=U){if(at(t),t.lookahead<=U&&e===l)return V;if(0===t.lookahead)break}if(t.match_length=0,t.lookahead>=D&&t.strstart>0&&(n=s[i=t.strstart-1])===s[++i]&&n===s[++i]&&n===s[++i]){o=t.strstart+U;do{}while(n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&it.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=D?(r=a._tr_tally(t,1,t.match_length-D),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(r=a._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),r&&(et(t,!1),0===t.strm.avail_out))return V}return t.insert=0,e===d?(et(t,!0),0===t.strm.avail_out?X:K):t.last_lit&&(et(t,!1),0===t.strm.avail_out)?V:G}(i,e):n[i.level].func(i,e);if(w!==X&&w!==K||(i.status=H),w===V||w===X)return 0===t.avail_out&&(i.last_flush=-1),p;if(w===G&&(e===h?a._tr_align(i):e!==c&&(a._tr_stored_block(i,0,0,!1),e===f&&(Q(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),tt(t),0===t.avail_out))return i.last_flush=-1,p}return e!==d?p:i.wrap<=0?m:(2===i.wrap?(rt(i,255&t.adler),rt(i,t.adler>>8&255),rt(i,t.adler>>16&255),rt(i,t.adler>>24&255),rt(i,255&t.total_in),rt(i,t.total_in>>8&255),rt(i,t.total_in>>16&255),rt(i,t.total_in>>24&255)):(nt(i,t.adler>>>16),nt(i,65535&t.adler)),tt(t),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?p:m)},r.deflateEnd=function(t){var e;return t&&t.state?(e=t.state.status)!==N&&e!==F&&e!==Z&&e!==M&&e!==Y&&e!==W&&e!==H?q(t,_):(t.state=null,e===W?q(t,g):p):_},r.deflateSetDictionary=function(t,e){var r,n,a,s,u,l,h,f,d=e.length;if(!t||!t.state)return _;if(2===(s=(r=t.state).wrap)||1===s&&r.status!==N||r.lookahead)return _;for(1===s&&(t.adler=o(t.adler,e,d,0)),r.wrap=0,d>=r.w_size&&(0===s&&(Q(r.head),r.strstart=0,r.block_start=0,r.insert=0),f=new i.Buf8(r.w_size),i.arraySet(f,e,d-r.w_size,r.w_size,0),e=f,d=r.w_size),u=t.avail_in,l=t.next_in,h=t.input,t.avail_in=d,t.next_in=0,t.input=e,at(r);r.lookahead>=D;){n=r.strstart,a=r.lookahead-(D-1);do{r.ins_h=(r.ins_h<>>=y=w>>>24,p-=y,0===(y=w>>>16&255))z[a++]=65535&w;else{if(!(16&y)){if(0==(64&y)){w=m[(65535&w)+(c&(1<>>=y,p-=y),p<15&&(c+=A[n++]<>>=y=w>>>24,p-=y,!(16&(y=w>>>16&255))){if(0==(64&y)){w=_[(65535&w)+(c&(1<u){t.msg="invalid distance too far back",r.mode=30;break t}if(c>>>=y,p-=y,x>(y=a-o)){if((y=x-y)>h&&r.sane){t.msg="invalid distance too far back",r.mode=30;break t}if(k=0,E=d,0===f){if(k+=l-y,y2;)z[a++]=E[k++],z[a++]=E[k++],z[a++]=E[k++],v-=3;v&&(z[a++]=E[k++],v>1&&(z[a++]=E[k++]))}else{k=a-x;do{z[a++]=z[k++],z[a++]=z[k++],z[a++]=z[k++],v-=3}while(v>2);v&&(z[a++]=z[k++],v>1&&(z[a++]=z[k++]))}break}}break}}while(n>3,c&=(1<<(p-=v<<3))-1,t.next_in=n,t.next_out=a,t.avail_in=n>>24&255)+(t>>>8&65280)+((65280&t)<<8)+((255&t)<<24)}function it(t){var e;return t&&t.state?(e=t.state,t.total_in=t.total_out=e.total=0,t.msg="",e.wrap&&(t.adler=1&e.wrap),e.mode=x,e.last=0,e.havedict=0,e.dmax=32768,e.head=null,e.hold=0,e.bits=0,e.lencode=e.lendyn=new n.Buf32(tt),e.distcode=e.distdyn=new n.Buf32(et),e.sane=1,e.back=-1,p):g}function at(t){var e;return t&&t.state?((e=t.state).wsize=0,e.whave=0,e.wnext=0,it(t)):g}function ot(t,e){var r,n;return t&&t.state?(n=t.state,e<0?(r=0,e=-e):(r=1+(e>>4),e<48&&(e&=15)),e&&(e<8||e>15)?g:(null!==n.window&&n.wbits!==e&&(n.window=null),n.wrap=r,n.wbits=e,at(t))):g}function st(t,e){var r,i;return t?(i=new function(){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 n.Buf16(320),this.work=new n.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0},t.state=i,i.window=null,(r=ot(t,e))!==p&&(t.state=null),r):g}var ut,lt,ht=!0;function ft(t){if(ht){var e;for(ut=new n.Buf32(512),lt=new n.Buf32(32),e=0;e<144;)t.lens[e++]=8;for(;e<256;)t.lens[e++]=9;for(;e<280;)t.lens[e++]=7;for(;e<288;)t.lens[e++]=8;for(s(l,t.lens,0,288,ut,0,t.work,{bits:9}),e=0;e<32;)t.lens[e++]=5;s(h,t.lens,0,32,lt,0,t.work,{bits:5}),ht=!1}t.lencode=ut,t.lenbits=9,t.distcode=lt,t.distbits=5}function dt(t,e,r,i){var a,o=t.state;return null===o.window&&(o.wsize=1<=o.wsize?(n.arraySet(o.window,e,r-o.wsize,o.wsize,0),o.wnext=0,o.whave=o.wsize):((a=o.wsize-o.wnext)>i&&(a=i),n.arraySet(o.window,e,r-i,a,o.wnext),(i-=a)?(n.arraySet(o.window,e,r-i,i,0),o.wnext=i,o.whave=o.wsize):(o.wnext+=a,o.wnext===o.wsize&&(o.wnext=0),o.whave>>8&255,r.check=a(r.check,It,2,0),st=0,ut=0,r.mode=k;break}if(r.flags=0,r.head&&(r.head.done=!1),!(1&r.wrap)||(((255&st)<<8)+(st>>8))%31){t.msg="incorrect header check",r.mode=q;break}if((15&st)!==v){t.msg="unknown compression method",r.mode=q;break}if(ut-=4,xt=8+(15&(st>>>=4)),0===r.wbits)r.wbits=xt;else if(xt>r.wbits){t.msg="invalid window size",r.mode=q;break}r.dmax=1<>8&1),512&r.flags&&(It[0]=255&st,It[1]=st>>>8&255,r.check=a(r.check,It,2,0)),st=0,ut=0,r.mode=E;case E:for(;ut<32;){if(0===at)break t;at--,st+=tt[rt++]<>>8&255,It[2]=st>>>16&255,It[3]=st>>>24&255,r.check=a(r.check,It,4,0)),st=0,ut=0,r.mode=A;case A:for(;ut<16;){if(0===at)break t;at--,st+=tt[rt++]<>8),512&r.flags&&(It[0]=255&st,It[1]=st>>>8&255,r.check=a(r.check,It,2,0)),st=0,ut=0,r.mode=z;case z:if(1024&r.flags){for(;ut<16;){if(0===at)break t;at--,st+=tt[rt++]<>>8&255,r.check=a(r.check,It,2,0)),st=0,ut=0}else r.head&&(r.head.extra=null);r.mode=I;case I:if(1024&r.flags&&((ct=r.length)>at&&(ct=at),ct&&(r.head&&(xt=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),n.arraySet(r.head.extra,tt,rt,ct,xt)),512&r.flags&&(r.check=a(r.check,tt,ct,rt)),at-=ct,rt+=ct,r.length-=ct),r.length))break t;r.length=0,r.mode=C;case C:if(2048&r.flags){if(0===at)break t;ct=0;do{xt=tt[rt+ct++],r.head&&xt&&r.length<65536&&(r.head.name+=String.fromCharCode(xt))}while(xt&&ct>9&1,r.head.done=!0),t.adler=r.check=0,r.mode=O;break;case R:for(;ut<32;){if(0===at)break t;at--,st+=tt[rt++]<>>=7&ut,ut-=7&ut,r.mode=X;break}for(;ut<3;){if(0===at)break t;at--,st+=tt[rt++]<>>=1)){case 0:r.mode=D;break;case 1:if(ft(r),r.mode=Z,e===c){st>>>=2,ut-=2;break t}break;case 2:r.mode=P;break;case 3:t.msg="invalid block type",r.mode=q}st>>>=2,ut-=2;break;case D:for(st>>>=7&ut,ut-=7&ut;ut<32;){if(0===at)break t;at--,st+=tt[rt++]<>>16^65535)){t.msg="invalid stored block lengths",r.mode=q;break}if(r.length=65535&st,st=0,ut=0,r.mode=U,e===c)break t;case U:r.mode=j;case j:if(ct=r.length){if(ct>at&&(ct=at),ct>ot&&(ct=ot),0===ct)break t;n.arraySet(et,tt,rt,ct,it),at-=ct,rt+=ct,ot-=ct,it+=ct,r.length-=ct;break}r.mode=O;break;case P:for(;ut<14;){if(0===at)break t;at--,st+=tt[rt++]<>>=5,ut-=5,r.ndist=1+(31&st),st>>>=5,ut-=5,r.ncode=4+(15&st),st>>>=4,ut-=4,r.nlen>286||r.ndist>30){t.msg="too many length or distance symbols",r.mode=q;break}r.have=0,r.mode=N;case N:for(;r.have>>=3,ut-=3}for(;r.have<19;)r.lens[Ct[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,Et={bits:r.lenbits},kt=s(u,r.lens,0,19,r.lencode,0,r.work,Et),r.lenbits=Et.bits,kt){t.msg="invalid code lengths set",r.mode=q;break}r.have=0,r.mode=F;case F:for(;r.have>>16&255,bt=65535&zt,!((_t=zt>>>24)<=ut);){if(0===at)break t;at--,st+=tt[rt++]<>>=_t,ut-=_t,r.lens[r.have++]=bt;else{if(16===bt){for(At=_t+2;ut>>=_t,ut-=_t,0===r.have){t.msg="invalid bit length repeat",r.mode=q;break}xt=r.lens[r.have-1],ct=3+(3&st),st>>>=2,ut-=2}else if(17===bt){for(At=_t+3;ut>>=_t)),st>>>=3,ut-=3}else{for(At=_t+7;ut>>=_t)),st>>>=7,ut-=7}if(r.have+ct>r.nlen+r.ndist){t.msg="invalid bit length repeat",r.mode=q;break}for(;ct--;)r.lens[r.have++]=xt}}if(r.mode===q)break;if(0===r.lens[256]){t.msg="invalid code -- missing end-of-block",r.mode=q;break}if(r.lenbits=9,Et={bits:r.lenbits},kt=s(l,r.lens,0,r.nlen,r.lencode,0,r.work,Et),r.lenbits=Et.bits,kt){t.msg="invalid literal/lengths set",r.mode=q;break}if(r.distbits=6,r.distcode=r.distdyn,Et={bits:r.distbits},kt=s(h,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,Et),r.distbits=Et.bits,kt){t.msg="invalid distances set",r.mode=q;break}if(r.mode=Z,e===c)break t;case Z:r.mode=M;case M:if(at>=6&&ot>=258){t.next_out=it,t.avail_out=ot,t.next_in=rt,t.avail_in=at,r.hold=st,r.bits=ut,o(t,ht),it=t.next_out,et=t.output,ot=t.avail_out,rt=t.next_in,tt=t.input,at=t.avail_in,st=r.hold,ut=r.bits,r.mode===O&&(r.back=-1);break}for(r.back=0;gt=(zt=r.lencode[st&(1<>>16&255,bt=65535&zt,!((_t=zt>>>24)<=ut);){if(0===at)break t;at--,st+=tt[rt++]<>wt)])>>>16&255,bt=65535&zt,!(wt+(_t=zt>>>24)<=ut);){if(0===at)break t;at--,st+=tt[rt++]<>>=wt,ut-=wt,r.back+=wt}if(st>>>=_t,ut-=_t,r.back+=_t,r.length=bt,0===gt){r.mode=G;break}if(32>){r.back=-1,r.mode=O;break}if(64>){t.msg="invalid literal/length code",r.mode=q;break}r.extra=15>,r.mode=Y;case Y:if(r.extra){for(At=r.extra;ut>>=r.extra,ut-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=W;case W:for(;gt=(zt=r.distcode[st&(1<>>16&255,bt=65535&zt,!((_t=zt>>>24)<=ut);){if(0===at)break t;at--,st+=tt[rt++]<>wt)])>>>16&255,bt=65535&zt,!(wt+(_t=zt>>>24)<=ut);){if(0===at)break t;at--,st+=tt[rt++]<>>=wt,ut-=wt,r.back+=wt}if(st>>>=_t,ut-=_t,r.back+=_t,64>){t.msg="invalid distance code",r.mode=q;break}r.offset=bt,r.extra=15>,r.mode=H;case H:if(r.extra){for(At=r.extra;ut>>=r.extra,ut-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){t.msg="invalid distance too far back",r.mode=q;break}r.mode=V;case V:if(0===ot)break t;if(ct=ht-ot,r.offset>ct){if((ct=r.offset-ct)>r.whave&&r.sane){t.msg="invalid distance too far back",r.mode=q;break}ct>r.wnext?(ct-=r.wnext,pt=r.wsize-ct):pt=r.wnext-ct,ct>r.length&&(ct=r.length),mt=r.window}else mt=et,pt=it-r.offset,ct=r.length;ct>ot&&(ct=ot),ot-=ct,r.length-=ct;do{et[it++]=mt[pt++]}while(--ct);0===r.length&&(r.mode=M);break;case G:if(0===ot)break t;et[it++]=r.length,ot--,r.mode=M;break;case X:if(r.wrap){for(;ut<32;){if(0===at)break t;at--,st|=tt[rt++]<=1&&0===D[z];z--);if(I>z&&(I=z),0===z)return l[h++]=20971520,l[h++]=20971520,d.bits=1,0;for(A=1;A0&&(0===t||1!==z))return-1;for(U[1]=0,k=1;k<15;k++)U[k+1]=U[k]+D[k];for(E=0;E852||2===t&&R>592)return 1;for(;;){0,w=k-S,f[E]b?(y=j[P+f[E]],v=O[L+f[E]]):(y=96,v=0),c=1<>S)+(p-=c)]=w<<24|y<<16|v|0}while(0!==p);for(c=1<>=1;if(0!==c?(T&=c-1,T+=c):T=0,E++,0==--D[k]){if(k===z)break;k=e[r+f[E]]}if(k>I&&(T&_)!==m){for(0===S&&(S=I),g+=A,B=1<<(C=k-S);C+S852||2===t&&R>592)return 1;l[m=T&_]=I<<24|C<<16|g-h|0}}return 0!==T&&(l[g+T]=k-S<<24|64<<16|0),d.bits=I,0}},{"../utils/common":32}],42:[function(t,e,r){"use strict";e.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"}},{}],43:[function(t,e,r){"use strict";var n=t("../utils/common"),i=4,a=0,o=1,s=2;function u(t){for(var e=t.length;--e>=0;)t[e]=0}var l=0,h=1,f=2,d=29,c=256,p=c+1+d,m=30,_=19,g=2*p+1,b=15,w=16,y=7,v=256,x=16,k=17,E=18,A=[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],z=[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],I=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],C=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S=new Array(2*(p+2));u(S);var B=new Array(2*m);u(B);var R=new Array(512);u(R);var T=new Array(256);u(T);var O=new Array(d);u(O);var L,D,U,j=new Array(m);function P(t,e,r,n,i){this.static_tree=t,this.extra_bits=e,this.extra_base=r,this.elems=n,this.max_length=i,this.has_stree=t&&t.length}function N(t,e){this.dyn_tree=t,this.max_code=0,this.stat_desc=e}function F(t){return t<256?R[t]:R[256+(t>>>7)]}function Z(t,e){t.pending_buf[t.pending++]=255&e,t.pending_buf[t.pending++]=e>>>8&255}function M(t,e,r){t.bi_valid>w-r?(t.bi_buf|=e<>w-t.bi_valid,t.bi_valid+=r-w):(t.bi_buf|=e<>>=1,r<<=1}while(--e>0);return r>>>1}function H(t,e,r){var n,i,a=new Array(b+1),o=0;for(n=1;n<=b;n++)a[n]=o=o+r[n-1]<<1;for(i=0;i<=e;i++){var s=t[2*i+1];0!==s&&(t[2*i]=W(a[s]++,s))}}function V(t){var e;for(e=0;e8?Z(t,t.bi_buf):t.bi_valid>0&&(t.pending_buf[t.pending++]=t.bi_buf),t.bi_buf=0,t.bi_valid=0}function X(t,e,r,n){var i=2*e,a=2*r;return t[i]>1;r>=1;r--)K(t,a,r);i=u;do{r=t.heap[1],t.heap[1]=t.heap[t.heap_len--],K(t,a,1),n=t.heap[1],t.heap[--t.heap_max]=r,t.heap[--t.heap_max]=n,a[2*i]=a[2*r]+a[2*n],t.depth[i]=(t.depth[r]>=t.depth[n]?t.depth[r]:t.depth[n])+1,a[2*r+1]=a[2*n+1]=i,t.heap[1]=i++,K(t,a,1)}while(t.heap_len>=2);t.heap[--t.heap_max]=t.heap[1],function(t,e){var r,n,i,a,o,s,u=e.dyn_tree,l=e.max_code,h=e.stat_desc.static_tree,f=e.stat_desc.has_stree,d=e.stat_desc.extra_bits,c=e.stat_desc.extra_base,p=e.stat_desc.max_length,m=0;for(a=0;a<=b;a++)t.bl_count[a]=0;for(u[2*t.heap[t.heap_max]+1]=0,r=t.heap_max+1;rp&&(a=p,m++),u[2*n+1]=a,n>l||(t.bl_count[a]++,o=0,n>=c&&(o=d[n-c]),s=u[2*n],t.opt_len+=s*(a+o),f&&(t.static_len+=s*(h[2*n+1]+o)));if(0!==m){do{for(a=p-1;0===t.bl_count[a];)a--;t.bl_count[a]--,t.bl_count[a+1]+=2,t.bl_count[p]--,m-=2}while(m>0);for(a=p;0!==a;a--)for(n=t.bl_count[a];0!==n;)(i=t.heap[--r])>l||(u[2*i+1]!==a&&(t.opt_len+=(a-u[2*i+1])*u[2*i],u[2*i+1]=a),n--)}}(t,e),H(a,l,t.bl_count)}function $(t,e,r){var n,i,a=-1,o=e[1],s=0,u=7,l=4;for(0===o&&(u=138,l=3),e[2*(r+1)+1]=65535,n=0;n<=r;n++)i=o,o=e[2*(n+1)+1],++s>=7;n0?(t.strm.data_type===s&&(t.strm.data_type=function(t){var e,r=4093624447;for(e=0;e<=31;e++,r>>>=1)if(1&r&&0!==t.dyn_ltree[2*e])return a;if(0!==t.dyn_ltree[18]||0!==t.dyn_ltree[20]||0!==t.dyn_ltree[26])return o;for(e=32;e=3&&0===t.bl_tree[2*C[e]+1];e--);return t.opt_len+=3*(e+1)+5+5+4,e}(t),u=t.opt_len+3+7>>>3,(l=t.static_len+3+7>>>3)<=u&&(u=l)):u=l=r+5,r+4<=u&&-1!==e?et(t,e,r,n):t.strategy===i||l===u?(M(t,(h<<1)+(n?1:0),3),J(t,S,B)):(M(t,(f<<1)+(n?1:0),3),function(t,e,r,n){var i;for(M(t,e-257,5),M(t,r-1,5),M(t,n-4,4),i=0;i>>8&255,t.pending_buf[t.d_buf+2*t.last_lit+1]=255&e,t.pending_buf[t.l_buf+t.last_lit]=255&r,t.last_lit++,0===e?t.dyn_ltree[2*r]++:(t.matches++,e--,t.dyn_ltree[2*(T[r]+c+1)]++,t.dyn_dtree[2*F(e)]++),t.last_lit===t.lit_bufsize-1},r._tr_align=function(t){M(t,h<<1,3),Y(t,v,S),function(t){16===t.bi_valid?(Z(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):t.bi_valid>=8&&(t.pending_buf[t.pending++]=255&t.bi_buf,t.bi_buf>>=8,t.bi_valid-=8)}(t)}},{"../utils/common":32}],44:[function(t,e,r){"use strict";e.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}},{}],45:[function(t,e,r){var n=t("lodash._root"),i=1/0,a="[object Symbol]",o=/[&<>"'`]/g,s=RegExp(o.source),u={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"};function l(t){return u[t]}var h=Object.prototype.toString,f=n.Symbol,d=f?f.prototype:void 0,c=f?d.toString:void 0;function p(t){if("string"==typeof t)return t;if(null==t)return"";if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&h.call(t)==a}(t))return f?c.call(t):"";var e=t+"";return"0"==e&&1/t==-i?"-0":e}e.exports=function(t){return(t=p(t))&&s.test(t)?t.replace(o,l):t}},{"lodash._root":46}],46:[function(t,e,r){(function(t){var n={function:!0,object:!0},i=n[typeof r]&&r&&!r.nodeType?r:void 0,a=n[typeof e]&&e&&!e.nodeType?e:void 0,o=f(i&&a&&"object"==typeof t&&t),s=f(n[typeof self]&&self),u=f(n[typeof window]&&window),l=f(n[typeof this]&&this),h=o||u!==(l&&l.window)&&u||s||l||Function("return this")();function f(t){return t&&t.Object===Object?t:null}e.exports=h}).call(this,"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],47:[function(t,e,r){var n=t("lodash._arraycopy"),i=t("lodash._arrayeach"),a=t("lodash._createassigner"),o=t("lodash.isarguments"),s=t("lodash.isarray"),u=t("lodash.isplainobject"),l=t("lodash.istypedarray"),h=t("lodash.keys"),f=t("lodash.toplainobject");var d=9007199254740991;var c,p=(c="length",function(t){return null==t?void 0:t[c]});function m(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=d}(p(t))}var _=a(function t(e,r,a,d,c){if(_=typeof(p=e),!p||"object"!=_&&"function"!=_)return e;var p,_,g=m(r)&&(s(r)||l(r)),b=g?void 0:h(r);return i(b||r,function(i,h){if(b&&(i=r[h=i]),function(t){return!!t&&"object"==typeof t}(i))d||(d=[]),c||(c=[]),function(t,e,r,i,a,h,d){for(var c=h.length,p=e[r];c--;)if(h[c]==p)return void(t[r]=d[c]);var _=t[r],g=a?a(_,p,r,t,e):void 0,b=void 0===g;b&&(g=p,m(p)&&(s(p)||l(p))?g=s(_)?_:m(_)?n(_):[]:u(p)||o(p)?g=o(_)?f(_):u(_)?_:{}:b=!1),h.push(p),d.push(g),b?t[r]=i(g,p,a,h,d):(g==g?g!==_:_==_)&&(t[r]=g)}(e,r,h,t,a,d,c);else{var p=e[h],_=a?a(p,i,h,e,r):void 0,w=void 0===_;w&&(_=i),void 0===_&&(!g||h in e)||!w&&(_==_?_===p:p!=p)||(e[h]=_)}}),e});e.exports=_},{"lodash._arraycopy":48,"lodash._arrayeach":49,"lodash._createassigner":50,"lodash.isarguments":55,"lodash.isarray":56,"lodash.isplainobject":57,"lodash.istypedarray":59,"lodash.keys":60,"lodash.toplainobject":62}],48:[function(t,e,r){e.exports=function(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r2?r[o-2]:void 0,u=o>2?r[2]:void 0,l=o>1?r[o-1]:void 0;for("function"==typeof s?(s=n(s,l,5),o-=2):o-=(s="function"==typeof l?l:void 0)?1:0,u&&i(r[0],r[1],u)&&(s=o<3?void 0:s,o=1);++a-1&&t%1==0&&t<=i}(o(t))}e.exports=function(t,e,r){if(!function(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}(r))return!1;var a=typeof e;if("number"==a?s(r)&&function(t,e){return t="number"==typeof t||n.test(t)?+t:-1,e=null==e?i:e,t>-1&&t%1==0&&t-1&&t%1==0&&t<=n}(d(t))&&!function(t){var e=function(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}(t)?l.call(t):"";return e==a||e==o}(t)}(t)}(t)&&u.call(t,"callee")&&(!h.call(t,"callee")||l.call(t)==i)}},{}],56:[function(t,e,r){var n="[object Function]",i=/^\[object .+?Constructor\]$/;function a(t){return!!t&&"object"==typeof t}var o,s,u=Object.prototype,l=Function.prototype.toString,h=u.hasOwnProperty,f=u.toString,d=RegExp("^"+l.call(h).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),c=(o=Array,function(t){return null!=t&&(function(t){return function(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}(t)&&f.call(t)==n}(t)?d.test(l.call(t)):a(t)&&i.test(t))}(s=null==o?void 0:o["isArray"])?s:void 0),p=9007199254740991;var m=c||function(t){return a(t)&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=p}(t.length)&&"[object Array]"==f.call(t)};e.exports=m},{}],57:[function(t,e,r){var n=t("lodash._basefor"),i=t("lodash.isarguments"),a=t("lodash.keysin"),o="[object Object]";var s=Object.prototype,u=s.hasOwnProperty,l=s.toString;e.exports=function(t){var e,r;return!(!function(t){return!!t&&"object"==typeof t}(t)||l.call(t)!=o||i(t)||!(u.call(t,"constructor")||"function"!=typeof(e=t.constructor)||e instanceof e))&&(n(t,function(t,e){r=e},a),void 0===r||u.call(t,r))}},{"lodash._basefor":58,"lodash.isarguments":55,"lodash.keysin":61}],58:[function(t,e,r){var n,i=function(t,e,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var u=o[n?s:++i];if(!1===e(a[u],u,a))break}return t};e.exports=i},{}],59:[function(t,e,r){var n=9007199254740991,i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1;var a=Object.prototype.toString;e.exports=function(t){return function(t){return!!t&&"object"==typeof t}(t)&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=n}(t.length)&&!!i[a.call(t)]}},{}],60:[function(t,e,r){var n=t("lodash._getnative"),i=t("lodash.isarguments"),a=t("lodash.isarray"),o=/^\d+$/,s=Object.prototype.hasOwnProperty,u=n(Object,"keys"),l=9007199254740991;var h,f=(h="length",function(t){return null==t?void 0:t[h]});function d(t,e){return t="number"==typeof t||o.test(t)?+t:-1,e=null==e?l:e,t>-1&&t%1==0&&t-1&&t%1==0&&t<=l}function p(t){for(var e=function(t){if(null==t)return[];m(t)||(t=Object(t));var e=t.length;e=e&&c(e)&&(a(t)||i(t))&&e||0;var r=t.constructor,n=-1,o="function"==typeof r&&r.prototype===t,u=Array(e),l=e>0;for(;++n-1&&t%1==0&&t-1&&t%1==0&&t<=s}(a)&&(i(t)||n(t))&&a||0;for(var l=t.constructor,h=-1,f="function"==typeof l&&l.prototype===t,d=Array(a),c=a>0;++h\n\n \n \n \n \n \n \n \n\n';return __p}},{"lodash.escape":45}],67:[function(_dereq_,module,exports){var _={escape:_dereq_("lodash.escape")};module.exports=function(obj){var __t,__p="",__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,"")};with(obj||{})__p+='MIME-Version: 1.0\nContent-Type: multipart/related;\n type="text/html";\n boundary="----=mhtDocumentPart"\n\n\n------=mhtDocumentPart\nContent-Type: text/html;\n charset="utf-8"\nContent-Transfer-Encoding: quoted-printable\nContent-Location: file:///C:/fake/document.html\n\n'+(null==(__t=htmlSource)?"":__t)+"\n\n"+(null==(__t=contentParts)?"":__t)+"\n\n------=mhtDocumentPart--\n";return __p}},{"lodash.escape":45}],68:[function(_dereq_,module,exports){var _={escape:_dereq_("lodash.escape")};module.exports=function(obj){var __t,__p="",__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,"")};with(obj||{})__p+="------=mhtDocumentPart\nContent-Type: "+(null==(__t=contentType)?"":__t)+"\nContent-Transfer-Encoding: "+(null==(__t=contentEncoding)?"":__t)+"\nContent-Location: "+(null==(__t=contentLocation)?"":__t)+"\n\n"+(null==(__t=encodedContent)?"":__t)+"\n";return __p}},{"lodash.escape":45}],69:[function(t,e,r){var n,i;n=t("./templates/mht_document"),i=t("./templates/mht_part"),e.exports={getMHTdocument:function(t){var e,r;return t=(r=this._prepareImageParts(t)).htmlSource,e=r.imageContentParts,t=t.replace(/\=/g,"=3D"),n({htmlSource:t,contentParts:e.join("\n")})},_prepareImageParts:function(t){var e,r,n;if(e=[],n=/"data:(\w+\/\w+);(\w+),(\S+)"/g,r=function(t,r,n,a){var o;return o="file:///C:/fake/image"+e.length+"."+r.split("/")[1],e.push(i({contentType:r,contentEncoding:n,contentLocation:o,encodedContent:a})),'"'+o+'"'},"string"==typeof t)return/