feffery_utils_components 0.2.0-rc24 → 0.2.0-rc25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. package/DESCRIPTION +1 -1
  2. package/MANIFEST.in +1 -1
  3. package/Project.toml +1 -1
  4. package/README.md +1 -1
  5. package/feffery_utils_components/FefferyDiv.py +12 -3
  6. package/feffery_utils_components/FefferyMotion.py +9 -3
  7. package/feffery_utils_components/__init__.py +23 -1
  8. package/feffery_utils_components/async-feffery_animated_3d_background_p5.js +3 -1
  9. package/feffery_utils_components/async-feffery_animated_3d_background_p5.js.map +1 -0
  10. package/feffery_utils_components/async-feffery_animated_3d_background_three.js +3 -1
  11. package/feffery_utils_components/async-feffery_animated_3d_background_three.js.map +1 -0
  12. package/feffery_utils_components/async-feffery_animated_image.js +4 -1
  13. package/feffery_utils_components/async-feffery_animated_image.js.map +1 -0
  14. package/feffery_utils_components/async-feffery_aplayer.js +3 -1
  15. package/feffery_utils_components/async-feffery_aplayer.js.map +1 -0
  16. package/feffery_utils_components/async-feffery_auto_animate.js +3 -1
  17. package/feffery_utils_components/async-feffery_auto_animate.js.map +1 -0
  18. package/feffery_utils_components/async-feffery_auto_fit.js +3 -1
  19. package/feffery_utils_components/async-feffery_auto_fit.js.map +1 -0
  20. package/feffery_utils_components/async-feffery_burger.js +3 -1
  21. package/feffery_utils_components/async-feffery_burger.js.map +1 -0
  22. package/feffery_utils_components/async-feffery_captcha.js +3 -1
  23. package/feffery_utils_components/async-feffery_captcha.js.map +1 -0
  24. package/feffery_utils_components/async-feffery_color_pickers.js +4 -1
  25. package/feffery_utils_components/async-feffery_color_pickers.js.map +1 -0
  26. package/feffery_utils_components/async-feffery_dom2image.js +4 -4
  27. package/feffery_utils_components/async-feffery_dom2image.js.map +1 -0
  28. package/feffery_utils_components/async-feffery_dplayer.js +4 -1
  29. package/feffery_utils_components/async-feffery_dplayer.js.map +1 -0
  30. package/feffery_utils_components/async-feffery_emoji_picker.js +4 -1
  31. package/feffery_utils_components/async-feffery_emoji_picker.js.map +1 -0
  32. package/feffery_utils_components/async-feffery_excel_preview.js +4 -1
  33. package/feffery_utils_components/async-feffery_excel_preview.js.map +1 -0
  34. package/feffery_utils_components/async-feffery_extra_spinner.js +4 -1
  35. package/feffery_utils_components/async-feffery_extra_spinner.js.map +1 -0
  36. package/feffery_utils_components/async-feffery_fancy_button.js +3 -1
  37. package/feffery_utils_components/async-feffery_fancy_button.js.map +1 -0
  38. package/feffery_utils_components/async-feffery_grid.js +3 -1
  39. package/feffery_utils_components/async-feffery_grid.js.map +1 -0
  40. package/feffery_utils_components/async-feffery_http_requests.js +4 -1
  41. package/feffery_utils_components/async-feffery_http_requests.js.map +1 -0
  42. package/feffery_utils_components/async-feffery_image_cropper.js +4 -1
  43. package/feffery_utils_components/async-feffery_image_cropper.js.map +1 -0
  44. package/feffery_utils_components/async-feffery_json_viewer.js +3 -1
  45. package/feffery_utils_components/async-feffery_json_viewer.js.map +1 -0
  46. package/feffery_utils_components/async-feffery_local_large_storage.js +4 -1
  47. package/feffery_utils_components/async-feffery_local_large_storage.js.map +1 -0
  48. package/feffery_utils_components/async-feffery_markdown_editor.js +3 -3
  49. package/feffery_utils_components/async-feffery_markdown_editor.js.map +1 -0
  50. package/feffery_utils_components/async-feffery_motion.js +3 -1
  51. package/feffery_utils_components/async-feffery_motion.js.map +1 -0
  52. package/feffery_utils_components/async-feffery_music_player.js +4 -1
  53. package/feffery_utils_components/async-feffery_music_player.js.map +1 -0
  54. package/feffery_utils_components/async-feffery_photo_sphere_viewer.js +4 -1
  55. package/feffery_utils_components/async-feffery_photo_sphere_viewer.js.map +1 -0
  56. package/feffery_utils_components/async-feffery_resizable.js +3 -1
  57. package/feffery_utils_components/async-feffery_resizable.js.map +1 -0
  58. package/feffery_utils_components/async-feffery_rich_text_editor.js +4 -4
  59. package/feffery_utils_components/async-feffery_rich_text_editor.js.map +1 -0
  60. package/feffery_utils_components/async-feffery_rnd.js +3 -1
  61. package/feffery_utils_components/async-feffery_rnd.js.map +1 -0
  62. package/feffery_utils_components/async-feffery_seamless_scroll.js +3 -1
  63. package/feffery_utils_components/async-feffery_seamless_scroll.js.map +1 -0
  64. package/feffery_utils_components/async-feffery_shortcut_panel.js +32 -29
  65. package/feffery_utils_components/async-feffery_shortcut_panel.js.map +1 -0
  66. package/feffery_utils_components/async-feffery_slider_captcha.js +4 -1
  67. package/feffery_utils_components/async-feffery_slider_captcha.js.map +1 -0
  68. package/feffery_utils_components/async-feffery_sortable.js +3 -1
  69. package/feffery_utils_components/async-feffery_sortable.js.map +1 -0
  70. package/feffery_utils_components/async-feffery_vditor.js +4 -1
  71. package/feffery_utils_components/async-feffery_vditor.js.map +1 -0
  72. package/feffery_utils_components/async-feffery_word_preview.js +4 -1
  73. package/feffery_utils_components/async-feffery_word_preview.js.map +1 -0
  74. package/feffery_utils_components/async-fuc-shared.js +4 -135
  75. package/feffery_utils_components/async-fuc-shared.js.map +1 -0
  76. package/feffery_utils_components/feffery_utils_components.min.js +27 -30
  77. package/feffery_utils_components/feffery_utils_components.min.js.map +1 -0
  78. package/feffery_utils_components/metadata.json +85 -0
  79. package/feffery_utils_components/package-info.json +1 -1
  80. package/package.json +1 -1
  81. package/src/lib/components/animations/FefferyMotion.react.js +12 -0
  82. package/src/lib/components/container/FefferyDiv.react.js +115 -55
  83. package/src/lib/fragments/animations/FefferyMotion.react.js +30 -23
  84. package/tests/MotionTest/app.py +50 -0
  85. package/usage.py +25 -25
  86. package/webpack.config.js +3 -11
@@ -1 +1,4 @@
1
- (window.webpackJsonpfeffery_utils_components=window.webpackJsonpfeffery_utils_components||[]).push([[33],{518:function(e,t,r){r.r(t);function n(e){var t=e.id,r=e.style,n=e.className,a=e.src,e=e.loading_state,i=Object(s.useRef)(null);return Object(s.useEffect)(function(){var e;if(i.current)return(e=o.a.init(i.current,{})).preview(a).then(function(e){}).catch(function(e){}),function(){e.destroy()}},[a]),React.createElement("div",{id:t,className:Object(c.isString)(n)?n:n?Object(l.a)(n):void 0,style:r,ref:i,"data-dash-is-loading":e&&e.is_loading||void 0})}var o=r(889),s=r(1),l=(r(904),r(63)),c=r(25),r=r(227);(t.default=n).defaultProps=r.b,n.propTypes=r.c},559:function(e,t,r){var n=r(578),a=Object.keys||function(e){var t,r=[];for(t in e)r.push(t);return r},e=(e.exports=u,Object.create(r(570))),i=(e.inherits=r(566),r(655)),o=r(599);e.inherits(u,i);for(var s=a(o.prototype),l=0;l<s.length;l++){var c=s[l];u.prototype[c]||(u.prototype[c]=o.prototype[c])}function u(e){if(!(this instanceof u))return new u(e);i.call(this,e),o.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",h)}function h(){this.allowHalfOpen||this._writableState.ended||n.nextTick(d,this)}function d(e){e.end()}Object.defineProperty(u.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(u.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),u.prototype._destroy=function(e,t){this.push(null),this.end(),n.nextTick(t,e)}},566:function(e,t){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){var r;t&&(e.super_=t,(r=function(){}).prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e)}},570:function(e,t,r){function n(e){return Object.prototype.toString.call(e)}t.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===n(e)},t.isBoolean=function(e){return"boolean"==typeof e},t.isNull=function(e){return null===e},t.isNullOrUndefined=function(e){return null==e},t.isNumber=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=function(e){return void 0===e},t.isRegExp=function(e){return"[object RegExp]"===n(e)},t.isObject=function(e){return"object"==typeof e&&null!==e},t.isDate=function(e){return"[object Date]"===n(e)},t.isError=function(e){return"[object Error]"===n(e)||e instanceof Error},t.isFunction=function(e){return"function"==typeof e},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(557).Buffer.isBuffer},577:function(e,t,r){var n="object"==typeof Reflect?Reflect:null,l=n&&"function"==typeof n.apply?n.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)},a=n&&"function"==typeof n.ownKeys?n.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)},i=Number.isNaN||function(e){return e!=e};function o(){o.init.call(this)}e.exports=o,e.exports.once=function(a,i){return new Promise(function(e,t){function r(e){a.removeListener(i,n),t(e)}function n(){"function"==typeof a.removeListener&&a.removeListener("error",r),e([].slice.call(arguments))}g(a,i,n,{once:!0}),"error"!==i&&"function"==typeof a.on&&g(a,"error",r,{once:!0})})},(o.EventEmitter=o).prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var s=10;function c(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function u(e){return void 0===e._maxListeners?o.defaultMaxListeners:e._maxListeners}function h(e,t,r,n){var a,i;return c(r),void 0===(a=e._events)?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,r.listener||r),a=e._events),i=a[t]),void 0===i?(i=a[t]=r,++e._eventsCount):("function"==typeof i?i=a[t]=n?[r,i]:[i,r]:n?i.unshift(r):i.push(r),0<(a=u(e))&&i.length>a&&!i.warned&&(i.warned=!0,(n=new Error("Possible EventEmitter memory leak detected. "+i.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit")).name="MaxListenersExceededWarning",n.emitter=e,n.type=t,n.count=i.length,console)&&console.warn&&console.warn(n)),e}function d(e,t,r){e={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},t=function(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}.bind(e);return t.listener=r,e.wrapFn=t}function f(e,t,r){e=e._events;if(void 0===e)return[];e=e[t];{if(void 0===e)return[];if("function"==typeof e)return r?[e.listener||e]:[e];if(r){for(var n=e,a=new Array(n.length),i=0;i<a.length;++i)a[i]=n[i].listener||n[i];return a}return m(e,e.length)}}function p(e){var t=this._events;if(void 0!==t){t=t[e];if("function"==typeof t)return 1;if(void 0!==t)return t.length}return 0}function m(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function g(r,n,a,i){if("function"==typeof r.on)i.once?r.once(n,a):r.on(n,a);else{if("function"!=typeof r.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof r);r.addEventListener(n,function e(t){i.once&&r.removeEventListener(n,e),a(t)})}}Object.defineProperty(o,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||i(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),o.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},o.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||i(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},o.prototype.getMaxListeners=function(){return u(this)},o.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n="error"===e,a=this._events;if(void 0!==a)n=n&&void 0===a.error;else if(!n)return!1;if(n){if((i=0<t.length?t[0]:i)instanceof Error)throw i;n=new Error("Unhandled error."+(i?" ("+i.message+")":""));throw n.context=i,n}var i=a[e];if(void 0===i)return!1;if("function"==typeof i)l(i,this,t);else for(var o=i.length,s=m(i,o),r=0;r<o;++r)l(s[r],this,t);return!0},o.prototype.on=o.prototype.addListener=function(e,t){return h(this,e,t,!1)},o.prototype.prependListener=function(e,t){return h(this,e,t,!0)},o.prototype.once=function(e,t){return c(t),this.on(e,d(this,e,t)),this},o.prototype.prependOnceListener=function(e,t){return c(t),this.prependListener(e,d(this,e,t)),this},o.prototype.off=o.prototype.removeListener=function(e,t){var r,n,a,i,o;if(c(t),void 0!==(n=this._events)&&void 0!==(r=n[e]))if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(a=-1,i=r.length-1;0<=i;i--)if(r[i]===t||r[i].listener===t){o=r[i].listener,a=i;break}if(a<0)return this;if(0===a)r.shift();else{var s=r;var l=a;for(;l+1<s.length;l++)s[l]=s[l+1];s.pop()}1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,o||t)}return this},o.prototype.removeAllListeners=function(e){var t,r;if(void 0!==(r=this._events))if(void 0===r.removeListener)0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]);else if(0===arguments.length){for(var n,a=Object.keys(r),i=0;i<a.length;++i)"removeListener"!==(n=a[i])&&this.removeAllListeners(n);this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0}else if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(i=t.length-1;0<=i;i--)this.removeListener(e,t[i]);return this},o.prototype.listeners=function(e){return f(this,e,!0)},o.prototype.rawListeners=function(e){return f(this,e,!1)},o.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},o.prototype.listenerCount=p,o.prototype.eventNames=function(){return 0<this._eventsCount?a(this._events):[]}},578:function(e,t,r){!function(s){void 0===s||!s.version||0===s.version.indexOf("v0.")||0===s.version.indexOf("v1.")&&0!==s.version.indexOf("v1.8.")?e.exports={nextTick:function(e,t,r,n){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var a,i,o=arguments.length;switch(o){case 0:case 1:return s.nextTick(e);case 2:return s.nextTick(function(){e.call(null,t)});case 3:return s.nextTick(function(){e.call(null,t,r)});case 4:return s.nextTick(function(){e.call(null,t,r,n)});default:for(a=new Array(o-1),i=0;i<a.length;)a[i++]=arguments[i];return s.nextTick(function(){e.apply(null,a)})}}}:e.exports=s}.call(this,r(318))},597:function(e,t,r){(((t=e.exports=r(655)).Stream=t).Readable=t).Writable=r(599),t.Duplex=r(559),t.Transform=r(659),t.PassThrough=r(897)},598:function(e,t,r){var n=r(557),a=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=n:(i(n,t),t.Buffer=o),i(a,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");e=a(e);return void 0!==t?"string"==typeof r?e.fill(t,r):e.fill(t):e.fill(0),e},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},599:function(c,e,k){!function(e,t,r){var m=k(578);function u(a){var i=this;this.next=null,this.entry=null,this.finish=function(){var e=i,t=a,r=e.entry;for(e.entry=null;r;){var n=r.callback;t.pendingcb--,n(void 0),r=r.next}t.corkedRequestsFree.next=e}}c.exports=s;var i,n,h=!e.browser&&-1<["v0.10","v0.9."].indexOf(e.version.slice(0,5))?t:m.nextTick,e=(s.WritableState=o,Object.create(k(570))),t=(e.inherits=k(566),{deprecate:k(895)}),a=k(656),g=k(598).Buffer,y=(void 0!==r?r:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},r=k(657);function b(){}function o(e,c){i=i||k(559),e=e||{};var t=c instanceof i,r=(this.objectMode=!!e.objectMode,t&&(this.objectMode=this.objectMode||!!e.writableObjectMode),e.highWaterMark),n=e.writableHighWaterMark,a=this.objectMode?16:16384,r=(this.highWaterMark=r||0===r?r:t&&(n||0===n)?n:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,(this.destroyed=!1)===e.decodeStrings);this.decodeStrings=!r,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){var t,r,n,a,i,o,s,l;e=e,o=(t=c)._writableState,s=o.sync,l=o.writecb,(i=o).writing=!1,i.writecb=null,i.length-=i.writelen,i.writelen=0,e?(i=t,n=s,e=e,a=l,--(r=o).pendingcb,n?(m.nextTick(a,e),m.nextTick(w,i,r),i._writableState.errorEmitted=!0,i.emit("error",e)):(a(e),i._writableState.errorEmitted=!0,i.emit("error",e),w(i,r))):((n=p(o))||o.corked||o.bufferProcessing||!o.bufferedRequest||f(t,o),s?h(d,t,o,n,l):d(t,o,n,l))},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new u(this)}function s(e){if(i=i||k(559),!(n.call(s,this)||this instanceof i))return new s(e);this._writableState=new o(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final)&&(this._final=e.final),a.call(this)}function v(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function d(e,t,r,n){var a;r||(r=e,0===(a=t).length&&a.needDrain&&(a.needDrain=!1,r.emit("drain"))),t.pendingcb--,n(),w(e,t)}function f(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,a=new Array(n),n=t.corkedRequestsFree;n.entry=r;for(var i=0,o=!0;r;)(a[i]=r).isBuf||(o=!1),r=r.next,i+=1;a.allBuffers=o,v(e,t,!0,t.length,a,"",n.finish),t.pendingcb++,t.lastBufferedRequest=null,n.next?(t.corkedRequestsFree=n.next,n.next=null):t.corkedRequestsFree=new u(t),t.bufferedRequestCount=0}else{for(;r;){var s=r.chunk,l=r.encoding,c=r.callback;if(v(e,t,!1,t.objectMode?1:s.length,s,l,c),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function p(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function l(t,r){t._final(function(e){r.pendingcb--,e&&t.emit("error",e),r.prefinished=!0,t.emit("prefinish"),w(t,r)})}function w(e,t){var r,n,a=p(t);return a&&(r=e,(n=t).prefinished||n.finalCalled||("function"==typeof r._final?(n.pendingcb++,n.finalCalled=!0,m.nextTick(l,r,n)):(n.prefinished=!0,r.emit("prefinish"))),0===t.pendingcb)&&(t.finished=!0,e.emit("finish")),a}e.inherits(s,a),o.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t};try{Object.defineProperty(o.prototype,"buffer",{get:t.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(n=Function.prototype[Symbol.hasInstance],Object.defineProperty(s,Symbol.hasInstance,{value:function(e){return!!n.call(this,e)||this===s&&e&&e._writableState instanceof o}})):n=function(e){return e instanceof this},s.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},s.prototype.write=function(e,t,r){var n,a,i,o,s,l,c,u,h,d=this._writableState,f=!1,p=!d.objectMode&&(p=e,g.isBuffer(p)||p instanceof y);return p&&!g.isBuffer(e)&&(h=e,e=g.from(h)),"function"==typeof t&&(r=t,t=null),t=p?"buffer":t||d.defaultEncoding,"function"!=typeof r&&(r=b),d.ended?(h=this,c=r,u=new Error("write after end"),h.emit("error",u),m.nextTick(c,u)):(p||(c=this,u=d,o=r,l=!(s=!0),null===(i=e)?l=new TypeError("May not write null values to stream"):"string"==typeof i||void 0===i||u.objectMode||(l=new TypeError("Invalid non-string/buffer chunk")),l&&(c.emit("error",l),m.nextTick(o,l),s=!1),s))&&(d.pendingcb++,i=this,o=d,l=e,s=t,d=r,(e=p)||(a=l,n=s,a=o.objectMode||!1===o.decodeStrings||"string"!=typeof a?a:g.from(a,n),l!==a&&(e=!0,s="buffer",l=a)),n=o.objectMode?1:l.length,o.length+=n,(a=o.length<o.highWaterMark)||(o.needDrain=!0),o.writing||o.corked?(t=o.lastBufferedRequest,o.lastBufferedRequest={chunk:l,encoding:s,isBuf:e,callback:d,next:null},t?t.next=o.lastBufferedRequest:o.bufferedRequest=o.lastBufferedRequest,o.bufferedRequestCount+=1):v(i,o,!1,n,l,s,d),f=a),f},s.prototype.cork=function(){this._writableState.corked++},s.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||f(this,e))},s.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),-1<["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase()))return this._writableState.defaultEncoding=e,this;throw new TypeError("Unknown encoding: "+e)},Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),s.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},s.prototype._writev=null,s.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,t=e=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||(e=this,t=r,(r=n).ending=!0,w(e,r),t&&(r.finished?m.nextTick(t):e.once("finish",t)),e.writable=!(r.ended=!0))},Object.defineProperty(s.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),s.prototype.destroy=r.destroy,s.prototype._undestroy=r.undestroy,s.prototype._destroy=function(e,t){this.end(),t(e)}}.call(this,k(318),k(563).setImmediate,k(32))},655:function(O,e,N){!function(e,g){var y=N(578);O.exports=a;function b(e,t){return e.listeners(t).length}var i,o,v=N(891),r=(a.ReadableState=n,N(577).EventEmitter,N(656)),h=N(598).Buffer,d=(void 0!==e?e:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},e=Object.create(N(570)),t=(e.inherits=N(566),N(892)),w=void 0,w=t&&t.debuglog?t.debuglog("stream"):function(){},s=N(893),t=N(657),l=(e.inherits(a,r),["error","close","destroy","pause","resume"]);function n(e,t){e=e||{};var t=t instanceof(i=i||N(559)),r=(this.objectMode=!!e.objectMode,t&&(this.objectMode=this.objectMode||!!e.readableObjectMode),e.highWaterMark),n=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:t&&(n||0===n)?n:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new s,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(o=o||N(658).StringDecoder,this.decoder=new o(e.encoding),this.encoding=e.encoding)}function a(e){if(i=i||N(559),!(this instanceof a))return new a(e);this._readableState=new n(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy)&&(this._destroy=e.destroy),r.call(this)}function c(e,t,r,n,a){var i,o,s,l,c,u=e._readableState;return null===t?(u.reading=!1,s=e,(l=u).ended||(l.decoder&&(c=l.decoder.end())&&c.length&&(l.buffer.push(c),l.length+=l.objectMode?1:c.length),l.ended=!0,p(s))):(a||(c=u,s=l=t,i=o=h.isBuffer(s)||s instanceof d||"string"==typeof l||void 0===l||c.objectMode?o:new TypeError("Invalid non-string/buffer chunk")),i?e.emit("error",i):u.objectMode||t&&0<t.length?("string"==typeof t||u.objectMode||Object.getPrototypeOf(t)===h.prototype||(a=t,t=h.from(a)),n?u.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):f(e,u,t,!0):u.ended?e.emit("error",new Error("stream.push() after EOF")):(u.reading=!1,!u.decoder||r||(t=u.decoder.write(t),u.objectMode)||0!==t.length?f(e,u,t,!1):k(e,u))):n||(u.reading=!1)),!u.ended&&(u.needReadable||u.length<u.highWaterMark||0===u.length)}function f(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&p(e)),k(e,t)}function u(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?(t.flowing&&t.length?t.buffer.head.data:t).length:(e>t.highWaterMark&&(t.highWaterMark=(8388608<=(r=e)?r=8388608:(r--,r=(r=(r=(r=(r|=r>>>1)|r>>>2)|r>>>4)|r>>>8)|r>>>16,r++),r)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0));var r}function p(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(w("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?y.nextTick(m,e):m(e))}function m(e){w("emit readable"),e.emit("readable"),C(e)}function k(e,t){t.readingMore||(t.readingMore=!0,y.nextTick(_,e,t))}function _(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(w("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function S(e){w("readable nexttick read 0"),e.read(0)}function x(e,t){t.reading||(w("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),C(e),t.flowing&&!t.reading&&e.read(0)}function C(e){var t=e._readableState;for(w("flow",t.flowing);t.flowing&&null!==e.read(););}function E(e,t){return 0===t.length?null:(t.objectMode?a=t.buffer.shift():!e||e>=t.length?(a=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):(e=e,r=t.buffer,t=t.decoder,e<r.head.data.length?(n=r.head.data.slice(0,e),r.head.data=r.head.data.slice(e)):n=e===r.head.data.length?r.shift():(t?(e,t)=>{var r=t.head,n=1,a=r.data;for(e-=a.length;r=r.next;){var i=r.data,o=e>i.length?i.length:e;if(a+=o===i.length?i:i.slice(0,e),0==(e-=o)){o===i.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r).data=i.slice(o);break}++n}return t.length-=n,a}:(e,t)=>{var r=h.allocUnsafe(e),n=t.head,a=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var i=n.data,o=e>i.length?i.length:e;if(i.copy(r,r.length-e,0,o),0==(e-=o)){o===i.length?(++a,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n).data=i.slice(o);break}++a}return t.length-=a,r})(e,r),a=n),a);var r,n,a}function P(e){var t=e._readableState;if(0<t.length)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,y.nextTick(T,t,e))}function T(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function A(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}Object.defineProperty(a.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),a.prototype.destroy=t.destroy,a.prototype._undestroy=t.undestroy,a.prototype._destroy=function(e,t){this.push(null),t(e)},a.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=h.from(e,t),t=""),r=!0),c(this,e,t,!1,r)},a.prototype.unshift=function(e){return c(this,e,null,!0,!1)},a.prototype.isPaused=function(){return!1===this._readableState.flowing},a.prototype.setEncoding=function(e){return o=o||N(658).StringDecoder,this._readableState.decoder=new o(e),this._readableState.encoding=e,this},a.prototype.read=function(e){w("read",e),e=parseInt(e,10);var t,r=this._readableState,n=e;return 0!==e&&(r.emittedReadable=!1),0===e&&r.needReadable&&(r.length>=r.highWaterMark||r.ended)?(w("read: emitReadable",r.length,r.ended),(0===r.length&&r.ended?P:p)(this),null):0===(e=u(e,r))&&r.ended?(0===r.length&&P(this),null):(t=r.needReadable,w("need readable",t),(0===r.length||r.length-e<r.highWaterMark)&&w("length less than watermark",t=!0),r.ended||r.reading?w("reading or ended",t=!1):t&&(w("do read"),r.reading=!0,r.sync=!0,0===r.length&&(r.needReadable=!0),this._read(r.highWaterMark),r.sync=!1,r.reading||(e=u(n,r))),null===(t=0<e?E(e,r):null)?(r.needReadable=!0,e=0):r.length-=e,0===r.length&&(r.ended||(r.needReadable=!0),n!==e)&&r.ended&&P(this),null!==t&&this.emit("data",t),t)},a.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},a.prototype.pipe=function(n,e){var a=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=n;break;case 1:i.pipes=[i.pipes,n];break;default:i.pipes.push(n)}i.pipesCount+=1,w("pipe count=%d opts=%j",i.pipesCount,e);e=e&&!1===e.end||n===g.stdout||n===g.stderr?m:o;function o(){w("onend"),n.end()}i.endEmitted?y.nextTick(e):a.once("end",e),n.on("unpipe",function e(t,r){w("onunpipe"),t===a&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,w("cleanup"),n.removeListener("close",f),n.removeListener("finish",p),n.removeListener("drain",l),n.removeListener("error",d),n.removeListener("unpipe",e),a.removeListener("end",o),a.removeListener("end",m),a.removeListener("data",h),c=!0,!i.awaitDrain||n._writableState&&!n._writableState.needDrain||l())});t=a;var t,r,s,l=function(){var e=t._readableState;w("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&b(t,"data")&&(e.flowing=!0,C(t))},c=(n.on("drain",l),!1),u=!1;function h(e){w("ondata"),(u=!1)!==n.write(e)||u||((1===i.pipesCount&&i.pipes===n||1<i.pipesCount&&-1!==A(i.pipes,n))&&!c&&(w("false write response, pause",i.awaitDrain),i.awaitDrain++,u=!0),a.pause())}function d(e){w("onerror",e),m(),n.removeListener("error",d),0===b(n,"error")&&n.emit("error",e)}function f(){n.removeListener("finish",p),m()}function p(){w("onfinish"),n.removeListener("close",f),m()}function m(){w("unpipe"),a.unpipe(n)}return a.on("data",h),e="error",s=d,"function"==typeof(r=n).prependListener?r.prependListener(e,s):r._events&&r._events[e]?v(r._events[e])?r._events[e].unshift(s):r._events[e]=[s,r._events[e]]:r.on(e,s),n.once("close",f),n.once("finish",p),n.emit("pipe",a),i.flowing||(w("pipe resume"),a.resume()),n},a.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0!==t.pipesCount)if(1===t.pipesCount)e&&e!==t.pipes||(e=e||t.pipes,t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r));else if(e){var n=A(t.pipes,e);-1!==n&&(t.pipes.splice(n,1),--t.pipesCount,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r))}else{var a=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)a[o].emit("unpipe",this,{hasUnpiped:!1})}return this},a.prototype.addListener=a.prototype.on=function(e,t){t=r.prototype.on.call(this,e,t);return"data"===e?!1!==this._readableState.flowing&&this.resume():"readable"!==e||(e=this._readableState).endEmitted||e.readableListening||(e.readableListening=e.needReadable=!0,e.emittedReadable=!1,e.reading?e.length&&p(this):y.nextTick(S,this)),t},a.prototype.resume=function(){var e,t=this._readableState;return t.flowing||(w("resume"),t.flowing=!0,e=this,(t=t).resumeScheduled||(t.resumeScheduled=!0,y.nextTick(x,e,t))),this},a.prototype.pause=function(){return w("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(w("pause"),this._readableState.flowing=!1,this.emit("pause")),this},a.prototype.wrap=function(t){var e,r=this,n=this._readableState,a=!1;for(e in t.on("end",function(){var e;w("wrapped end"),n.decoder&&!n.ended&&(e=n.decoder.end())&&e.length&&r.push(e),r.push(null)}),t.on("data",function(e){w("wrapped data"),n.decoder&&(e=n.decoder.write(e)),n.objectMode&&null==e||(n.objectMode||e&&e.length)&&!r.push(e)&&(a=!0,t.pause())}),t)void 0===this[e]&&"function"==typeof t[e]&&(this[e]=(e=>function(){return t[e].apply(t,arguments)})(e));for(var i=0;i<l.length;i++)t.on(l[i],this.emit.bind(this,l[i]));return this._read=function(e){w("wrapped _read",e),a&&(a=!1,t.resume())},this},Object.defineProperty(a.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),a._fromList=E}.call(this,N(32),N(318))},656:function(e,t,r){e.exports=r(577).EventEmitter},657:function(e,t,r){var i=r(578);function o(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,a=this._writableState&&this._writableState.destroyed;return n||a?t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.nextTick(o,this,e)):i.nextTick(o,this,e)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,i.nextTick(o,r,e)):i.nextTick(o,r,e):t&&t(e)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},658:function(e,t,r){var n=r(896).Buffer,a=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(e){var t;switch(this.encoding=(e=>{var t=(e=>{if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}})(e);if("string"==typeof t||n.isEncoding!==a&&a(e))return t||e;throw new Error("Unknown encoding: "+e)})(e),this.encoding){case"utf16le":this.text=l,this.end=c,t=4;break;case"utf8":this.fillLast=o,t=4;break;case"base64":this.text=u,this.end=h,t=3;break;default:return this.write=d,void(this.end=f)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function o(e){var t,r=this.lastTotal-this.lastNeed,n=(t=this,128!=(192&(n=e)[0])?(t.lastNeed=0,"�"):1<t.lastNeed&&1<n.length?128!=(192&n[1])?(t.lastNeed=1,"�"):2<t.lastNeed&&2<n.length&&128!=(192&n[2])?(t.lastNeed=2,"�"):void 0:void 0);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,r,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,r,0,e.length),void(this.lastNeed-=e.length))}function l(e,t){if((e.length-t)%2!=0)return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1);t=e.toString("utf16le",t);if(t){var r=t.charCodeAt(t.length-1);if(55296<=r&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],t.slice(0,-1)}return t}function c(e){var t,e=e&&e.length?this.write(e):"";return this.lastNeed?(t=this.lastTotal-this.lastNeed,e+this.lastChar.toString("utf16le",0,t)):e}function u(e,t){var r=(e.length-t)%3;return 0==r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1==r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function h(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function d(e){return e.toString(this.encoding)}function f(e){return e&&e.length?this.write(e):""}(t.StringDecoder=i).prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},i.prototype.end=function(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+"�":e},i.prototype.text=function(e,t){r=this,i=t;var r,n,a,i=(a=(o=e).length-1)<i?0:0<=(n=s(o[a]))?(0<n&&(r.lastNeed=n-1),n):--a<i||-2===n?0:0<=(n=s(o[a]))?(0<n&&(r.lastNeed=n-2),n):!(--a<i||-2===n)&&0<=(n=s(o[a]))?(0<n&&(2===n?n=0:r.lastNeed=n-3),n):0;if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=i;var o=e.length-(i-this.lastNeed);return e.copy(this.lastChar,0,o),e.toString("utf8",t,o)},i.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},659:function(e,t,r){e.exports=a;var n=r(559),e=Object.create(r(570));function a(e){if(!(this instanceof a))return new a(e);n.call(this,e),this._transformState={afterTransform:function(e,t){var r=this._transformState,n=(r.transforming=!1,r.writecb);if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,(r.writecb=null)!=t&&this.push(t),n(e),(r=this._readableState).reading=!1,(r.needReadable||r.length<r.highWaterMark)&&this._read(r.highWaterMark)}.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush)&&(this._flush=e.flush),this.on("prefinish",i)}function i(){var r=this;"function"==typeof this._flush?this._flush(function(e,t){o(r,e,t)}):o(this,null,null)}function o(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");e.push(null)}e.inherits=r(566),e.inherits(a,n),a.prototype.push=function(e,t){return this._transformState.needTransform=!1,n.prototype.push.call(this,e,t)},a.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},a.prototype._write=function(e,t,r){var n=this._transformState;n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming&&(r=this._readableState,n.needTransform||r.needReadable||r.length<r.highWaterMark)&&this._read(r.highWaterMark)},a.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},a.prototype._destroy=function(e,t){var r=this;n.prototype._destroy.call(this,e,function(e){t(e),r.emit("close")})}},660:function(e,T,A){!function(o){var t=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},s=/%[sdj%]/g;T.format=function(e){if(!w(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(l(arguments[r]));return t.join(" ")}for(var r=1,n=arguments,a=n.length,i=String(e).replace(s,function(e){if("%%"===e)return"%";if(a<=r)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}}),o=n[r];r<a;o=n[++r])b(o)||!c(o)?i+=" "+o:i+=" "+l(o);return i},T.deprecate=function(e,t){var r;return void 0!==o&&!0===o.noDeprecation?e:void 0===o?function(){return T.deprecate(e,t).apply(this,arguments)}:(r=!1,function(){if(!r){if(o.throwDeprecation)throw new Error(t);o.traceDeprecation?console.trace(t):console.error(t),r=!0}return e.apply(this,arguments)})};var e,n={};function l(e,t){var r={seen:[],stylize:i};return 3<=arguments.length&&(r.depth=arguments[2]),4<=arguments.length&&(r.colors=arguments[3]),y(t)?r.showHidden=t:t&&T._extend(r,t),k(r.showHidden)&&(r.showHidden=!1),k(r.depth)&&(r.depth=2),k(r.colors)&&(r.colors=!1),k(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=a),f(r,e,r.depth)}function a(e,t){t=l.styles[t];return t?"["+l.colors[t][0]+"m"+e+"["+l.colors[t][1]+"m":e}function i(e,t){return e}function f(t,r,n){if(t.customInspect&&r&&C(r.inspect)&&r.inspect!==T.inspect&&(!r.constructor||r.constructor.prototype!==r))return w(e=r.inspect(n,t))?e:f(t,e,n);e=t;var e,a=k(o=r)?e.stylize("undefined","undefined"):w(o)?(a="'"+JSON.stringify(o).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'",e.stylize(a,"string")):v(o)?e.stylize(""+o,"number"):y(o)?e.stylize(""+o,"boolean"):b(o)?e.stylize("null","null"):void 0;if(a)return a;var i,o=Object.keys(r),s=(i={},o.forEach(function(e,t){i[e]=!0}),i);if(t.showHidden&&(o=Object.getOwnPropertyNames(r)),x(r)&&(0<=o.indexOf("message")||0<=o.indexOf("description")))return p(r);if(0===o.length){if(C(r))return u=r.name?": "+r.name:"",t.stylize("[Function"+u+"]","special");if(_(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(S(r))return t.stylize(Date.prototype.toString.call(r),"date");if(x(r))return p(r)}var l,c,u="",h=!1,d=["{","}"];return g(r)&&(h=!0,d=["[","]"]),C(r)&&(u=" [Function"+(r.name?": "+r.name:"")+"]"),_(r)&&(u=" "+RegExp.prototype.toString.call(r)),S(r)&&(u=" "+Date.prototype.toUTCString.call(r)),x(r)&&(u=" "+p(r)),0!==o.length||h&&0!=r.length?n<0?_(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),o=h?((t,r,n,a,e)=>{for(var i=[],o=0,s=r.length;o<s;++o)E(r,String(o))?i.push(m(t,r,n,a,String(o),!0)):i.push("");return e.forEach(function(e){e.match(/^\d+$/)||i.push(m(t,r,n,a,e,!0))}),i})(t,r,n,s,o):o.map(function(e){return m(t,r,n,s,e,h)}),t.seen.pop(),l=u,c=d,60<(o=o).reduce(function(e,t){return t.indexOf("\n"),e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)?c[0]+(""===l?"":l+"\n ")+" "+o.join(",\n ")+" "+c[1]:c[0]+l+" "+o.join(", ")+" "+c[1]):d[0]+u+d[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function m(e,t,r,n,a,i){var o,s;if((t=Object.getOwnPropertyDescriptor(t,a)||{value:t[a]}).get?s=t.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):t.set&&(s=e.stylize("[Setter]","special")),E(n,a)||(o="["+a+"]"),s||(e.seen.indexOf(t.value)<0?-1<(s=f(e,t.value,b(r)?null:r-1)).indexOf("\n")&&(s=i?s.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n")):s=e.stylize("[Circular]","special")),k(o)){if(i&&a.match(/^\d+$/))return s;o=(o=JSON.stringify(""+a)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),e.stylize(o,"string"))}return o+": "+s}function g(e){return Array.isArray(e)}function y(e){return"boolean"==typeof e}function b(e){return null===e}function v(e){return"number"==typeof e}function w(e){return"string"==typeof e}function k(e){return void 0===e}function _(e){return c(e)&&"[object RegExp]"===r(e)}function c(e){return"object"==typeof e&&null!==e}function S(e){return c(e)&&"[object Date]"===r(e)}function x(e){return c(e)&&("[object Error]"===r(e)||e instanceof Error)}function C(e){return"function"==typeof e}function r(e){return Object.prototype.toString.call(e)}function u(e){return e<10?"0"+e.toString(10):e.toString(10)}T.debuglog=function(t){var r;return k(e)&&(e=o.env.NODE_DEBUG||""),t=t.toUpperCase(),n[t]||(new RegExp("\\b"+t+"\\b","i").test(e)?(r=o.pid,n[t]=function(){var e=T.format.apply(T,arguments);console.error("%s %d: %s",t,r,e)}):n[t]=function(){}),n[t]},(T.inspect=l).colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},l.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},T.isArray=g,T.isBoolean=y,T.isNull=b,T.isNullOrUndefined=function(e){return null==e},T.isNumber=v,T.isString=w,T.isSymbol=function(e){return"symbol"==typeof e},T.isUndefined=k,T.isRegExp=_,T.isObject=c,T.isDate=S,T.isError=x,T.isFunction=C,T.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},T.isBuffer=A(902);var h=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function E(e,t){return Object.prototype.hasOwnProperty.call(e,t)}T.log=function(){var e,t;console.log("%s - %s",(e=new Date,t=[u(e.getHours()),u(e.getMinutes()),u(e.getSeconds())].join(":"),[e.getDate(),h[e.getMonth()],t].join(" ")),T.format.apply(T,arguments))},T.inherits=A(903),T._extend=function(e,t){if(t&&c(t))for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var d="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function P(e,t){var r;return e||((r=new Error("Promise was rejected with a falsy value")).reason=e,e=r),t(e)}T.promisify=function(i){if("function"!=typeof i)throw new TypeError('The "original" argument must be of type Function');if(d&&i[d]){var e;if("function"!=typeof(e=i[d]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,d,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var r,n,e=new Promise(function(e,t){r=e,n=t}),t=[],a=0;a<arguments.length;a++)t.push(arguments[a]);t.push(function(e,t){e?n(e):r(t)});try{i.apply(this,t)}catch(e){n(e)}return e}return Object.setPrototypeOf(e,Object.getPrototypeOf(i)),d&&Object.defineProperty(e,d,{value:e,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(e,t(i))},T.promisify.custom=d,T.callbackify=function(i){if("function"!=typeof i)throw new TypeError('The "original" argument must be of type Function');function e(){for(var e=[],t=0;t<arguments.length;t++)e.push(arguments[t]);var r=e.pop();if("function"!=typeof r)throw new TypeError("The last argument must be of type Function");function n(){return r.apply(a,arguments)}var a=this;i.apply(this,e).then(function(e){o.nextTick(n,null,e)},function(e){o.nextTick(P,e,n)})}return Object.setPrototypeOf(e,Object.getPrototypeOf(i)),Object.defineProperties(e,t(i)),e}}.call(this,A(318))},889:function(e,kl,_l){!function(e,R,j,I){_l.d(kl,"a",function(){return vl});var L=_l(890),z=_l.n(L),L=_l(577),F=_l.n(L),L=_l(557),U=_l.n(L),L=_l(660),W=_l.n(L);function H(t,e){var r,n=Object.keys(t);return Object.getOwnPropertySymbols&&(r=Object.getOwnPropertySymbols(t),e&&(r=r.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),n.push.apply(n,r)),n}function S(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?H(Object(r),!0).forEach(function(e){Z(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):H(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function Z(e,t,r){(t=ee(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}function q(e){return(e=>{if(Array.isArray(e))return J(e)})(e)||(()=>{if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)})()||K(e)||(()=>{throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")})()}function V(e,t){return(e=>{if(Array.isArray(e))return e})(e)||((e,t)=>{var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,s=[],l=!0,c=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw a}}return s}})(e,t)||K(e,t)||(()=>{throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")})()}function t(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&X(e,t)}function X(e,t){return(X=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function r(r){var n=(()=>{if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}})();return function(){var e,t=G(r),t=(e=n?(e=G(this).constructor,Reflect.construct(t,arguments,e)):t.apply(this,arguments),this);if(!e||"object"!==te(e)&&"function"!=typeof e){if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");if(void 0===(e=t))throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return e}}function G(e){return(G=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function x(e,t){var r,n,a,i,o="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(o)return a=!(n=!0),{s:function(){o=o.call(e)},n:function(){var e=o.next();return n=e.done,e},e:function(e){a=!0,r=e},f:function(){try{n||null==o.return||o.return()}finally{if(a)throw r}}};if(Array.isArray(e)||(o=K(e))||t&&e&&"number"==typeof e.length)return o&&(e=o),i=0,{s:t=function(){},n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:t};throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function K(e,t){var r;if(e)return"string"==typeof e?J(e,t):"Map"===(r="Object"===(r=Object.prototype.toString.call(e).slice(8,-1))&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?J(e,t):void 0}function J(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function P(){P=function(){return o};var l,o={},e=Object.prototype,c=e.hasOwnProperty,u=Object.defineProperty||function(e,t,r){e[t]=r.value},t="function"==typeof Symbol?Symbol:{},n=t.iterator||"@@iterator",r=t.asyncIterator||"@@asyncIterator",a=t.toStringTag||"@@toStringTag";function i(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{i({},"")}catch(l){i=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var a,i,o,s,t=t&&t.prototype instanceof g?t:g,t=Object.create(t.prototype),n=new C(n||[]);return u(t,"_invoke",{value:(a=e,i=r,o=n,s=d,function(e,t){if(s===f)throw new Error("Generator is already running");if(s===p){if("throw"===e)throw t;return{value:l,done:!0}}for(o.method=e,o.arg=t;;){var r=o.delegate;if(r){r=function e(t,r){var n=r.method,a=t.iterator[n];if(a===l)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=l,e(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;n=h(a,t.iterator,r.arg);if("throw"===n.type)return r.method="throw",r.arg=n.arg,r.delegate=null,m;a=n.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=l),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}(r,o);if(r){if(r===m)continue;return r}}if("next"===o.method)o.sent=o._sent=o.arg;else if("throw"===o.method){if(s===d)throw s=p,o.arg;o.dispatchException(o.arg)}else"return"===o.method&&o.abrupt("return",o.arg);s=f;r=h(a,i,o);if("normal"===r.type){if(s=o.done?p:"suspendedYield",r.arg===m)continue;return{value:r.arg,done:o.done}}"throw"===r.type&&(s=p,o.method="throw",o.arg=r.arg)}})}),t}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}o.wrap=s;var d="suspendedStart",f="executing",p="completed",m={};function g(){}function y(){}function b(){}var t={},v=(i(t,n,function(){return this}),Object.getPrototypeOf),v=v&&v(v(E([]))),w=(v&&v!==e&&c.call(v,n)&&(t=v),b.prototype=g.prototype=Object.create(t));function k(e){["next","throw","return"].forEach(function(t){i(e,t,function(e){return this._invoke(t,e)})})}function _(o,s){var t;u(this,"_invoke",{value:function(r,n){function e(){return new s(function(e,t){!function t(e,r,n,a){var i,e=h(o[e],o,r);if("throw"!==e.type)return(r=(i=e.arg).value)&&"object"==te(r)&&c.call(r,"__await")?s.resolve(r.__await).then(function(e){t("next",e,n,a)},function(e){t("throw",e,n,a)}):s.resolve(r).then(function(e){i.value=e,n(i)},function(e){return t("throw",e,n,a)});a(e.arg)}(r,n,e,t)})}return t=t?t.then(e,e):e()}})}function S(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function x(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function C(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(S,this),this.reset(!0)}function E(t){if(t||""===t){var r,e=t[n];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return r=-1,(e=function e(){for(;++r<t.length;)if(c.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=l,e.done=!0,e}).next=e}throw new TypeError(te(t)+" is not iterable")}return u(w,"constructor",{value:y.prototype=b,configurable:!0}),u(b,"constructor",{value:y,configurable:!0}),y.displayName=i(b,a,"GeneratorFunction"),o.isGeneratorFunction=function(e){e="function"==typeof e&&e.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},o.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,i(e,a,"GeneratorFunction")),e.prototype=Object.create(w),e},o.awrap=function(e){return{__await:e}},k(_.prototype),i(_.prototype,r,function(){return this}),o.AsyncIterator=_,o.async=function(e,t,r,n,a){void 0===a&&(a=Promise);var i=new _(s(e,t,r,n),a);return o.isGeneratorFunction(t)?i:i.next().then(function(e){return e.done?e.value:i.next()})},k(w),i(w,a,"Generator"),i(w,n,function(){return this}),i(w,"toString",function(){return"[object Generator]"}),o.keys=function(e){var t,r=Object(e),n=[];for(t in r)n.push(t);return n.reverse(),function e(){for(;n.length;){var t=n.pop();if(t in r)return e.value=t,e.done=!1,e}return e.done=!0,e}},o.values=E,C.prototype={constructor:C,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=l,this.done=!1,this.delegate=null,this.method="next",this.arg=l,this.tryEntries.forEach(x),!e)for(var t in this)"t"===t.charAt(0)&&c.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=l)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(r){if(this.done)throw r;var n=this;function e(e,t){return i.type="throw",i.arg=r,n.next=e,t&&(n.method="next",n.arg=l),!!t}for(var t=this.tryEntries.length-1;0<=t;--t){var a=this.tryEntries[t],i=a.completion;if("root"===a.tryLoc)return e("end");if(a.tryLoc<=this.prev){var o=c.call(a,"catchLoc"),s=c.call(a,"finallyLoc");if(o&&s){if(this.prev<a.catchLoc)return e(a.catchLoc,!0);if(this.prev<a.finallyLoc)return e(a.finallyLoc)}else if(o){if(this.prev<a.catchLoc)return e(a.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return e(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;0<=r;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&c.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var a=n;break}}var i=(a=a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc?null:a)?a.completion:{};return i.type=e,i.arg=t,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),x(r),m}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var r,n,a=this.tryEntries[t];if(a.tryLoc===e)return"throw"===(r=a.completion).type&&(n=r.arg,x(a)),n}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:E(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=l),m}},o}function Y(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){return r(e)}s.done?t(l):Promise.resolve(l).then(n,a)}function $(s){return function(){var e=this,o=arguments;return new Promise(function(t,r){var n=s.apply(e,o);function a(e){Y(n,t,r,a,i,"next",e)}function i(e){Y(n,t,r,a,i,"throw",e)}a(void 0)})}}function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,ee(n.key),n)}}function a(e,t,r){return t&&Q(e.prototype,t),r&&Q(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function ee(e){e=(e=>{if("object"!==te(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0===t)return String(e);if("object"!==te(t=t.call(e,"string")))return t;throw new TypeError("@@toPrimitive must return a primitive value.")})(e);return"symbol"===te(e)?e:String(e)}function te(e){return(te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}void 0===window.setImmediate&&(window.setImmediate=function(e){for(var t=arguments.length,r=new Array(1<t?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];setTimeout(function(){return e(r)})});var re,ne,ae,ie,oe,M="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},L={},se={},f={},le={exports:{}},ce={exports:{}};function ue(){return re||(re=1,void 0===R||!R.version||0===R.version.indexOf("v0.")||0===R.version.indexOf("v1.")&&0!==R.version.indexOf("v1.8.")?ce.exports={nextTick:function(e,t,r,n){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var a,i,o=arguments.length;switch(o){case 0:case 1:return R.nextTick(e);case 2:return R.nextTick(function(){e.call(null,t)});case 3:return R.nextTick(function(){e.call(null,t,r)});case 4:return R.nextTick(function(){e.call(null,t,r,n)});default:for(a=new Array(o-1),i=0;i<a.length;)a[i++]=arguments[i];return R.nextTick(function(){e.apply(null,a)})}}}:ce.exports=R),ce.exports}function he(){return oe?ie:(oe=1,ie=z.a)}var de,fe={exports:{}};function pe(){return de||(de=1,n=(r=fe).exports,a=U.a,(i=a.Buffer).from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?r.exports=a:(e(a,n),n.Buffer=t),e(i,t),t.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},t.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");e=i(e);return void 0!==t?"string"==typeof r?e.fill(t,r):e.fill(t):e.fill(0),e},t.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},t.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a.SlowBuffer(e)}),fe.exports;function e(e,t){for(var r in e)t[r]=e[r]}function t(e,t,r){return i(e,t,r)}var r,n,a,i}var me,i={};function ge(){return me||(me=1,i.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===t(e)},i.isBoolean=function(e){return"boolean"==typeof e},i.isNull=function(e){return null===e},i.isNullOrUndefined=function(e){return null==e},i.isNumber=function(e){return"number"==typeof e},i.isString=function(e){return"string"==typeof e},i.isSymbol=function(e){return"symbol"==te(e)},i.isUndefined=function(e){return void 0===e},i.isRegExp=function(e){return"[object RegExp]"===t(e)},i.isObject=function(e){return"object"==te(e)&&null!==e},i.isDate=function(e){return"[object Date]"===t(e)},i.isError=function(e){return"[object Error]"===t(e)||e instanceof Error},i.isFunction=function(e){return"function"==typeof e},i.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==te(e)||void 0===e},i.isBuffer=U.a.Buffer.isBuffer),i;function t(e){return Object.prototype.toString.call(e)}}var ye,be,ve={exports:{}},we={exports:{}};function ke(){if(!be){be=1;try{var e=_l(660);if("function"!=typeof e.inherits)throw"";ve.exports=e.inherits}catch(e){ve.exports=(ye||(ye=1,"function"==typeof Object.create?we.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:we.exports=function(e,t){var r;t&&(e.super_=t,(r=function(){}).prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e)}),we.exports)}}return ve.exports}var _e,Se,xe,Ce,Ee,Pe,Te,Ae,Oe,Ne={exports:{}};function Re(){if(xe)return Se;xe=1;var i=ue();function o(e,t){e.emit("error",t)}return Se={destroy:function(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,a=this._writableState&&this._writableState.destroyed;return n||a?t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.nextTick(o,this,e)):i.nextTick(o,this,e)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,i.nextTick(o,r,e)):i.nextTick(o,r,e):t&&t(e)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}}function Me(){if(!Te){Te=1;var m=ue();Pe=s;var i,u=!R.browser&&-1<["v0.10","v0.9."].indexOf(R.version.slice(0,5))?j:m.nextTick,e=(s.WritableState=o,Object.create(ge()));e.inherits=ke();var t,r={deprecate:Ee?Ce:(Ee=1,Ce=W.a.deprecate)},n=he(),g=pe().Buffer,y=(void 0!==M?M:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},a=Re();e.inherits(s,n),o.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t};try{Object.defineProperty(o.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(t=Function.prototype[Symbol.hasInstance],Object.defineProperty(s,Symbol.hasInstance,{value:function(e){return!!t.call(this,e)||this===s&&e&&e._writableState instanceof o}})):t=function(e){return e instanceof this},s.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},s.prototype.write=function(e,t,r){var n,a,i,o,s,l,c,u,h,d=this._writableState,f=!1,p=!d.objectMode&&(p=e,g.isBuffer(p)||p instanceof y);return p&&!g.isBuffer(e)&&(h=e,e=g.from(h)),"function"==typeof t&&(r=t,t=null),t=p?"buffer":t||d.defaultEncoding,"function"!=typeof r&&(r=b),d.ended?(h=this,c=r,u=new Error("write after end"),h.emit("error",u),m.nextTick(c,u)):(p||(c=this,u=d,o=r,l=!(s=!0),null===(i=e)?l=new TypeError("May not write null values to stream"):"string"==typeof i||void 0===i||u.objectMode||(l=new TypeError("Invalid non-string/buffer chunk")),l&&(c.emit("error",l),m.nextTick(o,l),s=!1),s))&&(d.pendingcb++,i=this,o=d,l=e,s=t,d=r,(e=p)||(a=l,n=s,a=o.objectMode||!1===o.decodeStrings||"string"!=typeof a?a:g.from(a,n),l!==a&&(e=!0,s="buffer",l=a)),n=o.objectMode?1:l.length,o.length+=n,(a=o.length<o.highWaterMark)||(o.needDrain=!0),o.writing||o.corked?(t=o.lastBufferedRequest,o.lastBufferedRequest={chunk:l,encoding:s,isBuf:e,callback:d,next:null},t?t.next=o.lastBufferedRequest:o.bufferedRequest=o.lastBufferedRequest,o.bufferedRequestCount+=1):v(i,o,!1,n,l,s,d),f=a),f},s.prototype.cork=function(){this._writableState.corked++},s.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||f(this,e))},s.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),-1<["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase()))return this._writableState.defaultEncoding=e,this;throw new TypeError("Unknown encoding: "+e)},Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),s.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},s.prototype._writev=null,s.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,t=e=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||(e=this,t=r,(r=n).ending=!0,w(e,r),t&&(r.finished?m.nextTick(t):e.once("finish",t)),e.writable=!(r.ended=!0))},Object.defineProperty(s.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),s.prototype.destroy=a.destroy,s.prototype._undestroy=a.undestroy,s.prototype._destroy=function(e,t){this.end(),t(e)}}return Pe;function h(a){var i=this;this.next=null,this.entry=null,this.finish=function(){var e=i,t=a,r=e.entry;for(e.entry=null;r;){var n=r.callback;t.pendingcb--,n(void 0),r=r.next}t.corkedRequestsFree.next=e}}function b(){}function o(e,c){i=i||Be(),e=e||{};var t=c instanceof i,r=(this.objectMode=!!e.objectMode,t&&(this.objectMode=this.objectMode||!!e.writableObjectMode),e.highWaterMark),n=e.writableHighWaterMark,a=this.objectMode?16:16384,r=(this.highWaterMark=r||0===r?r:t&&(n||0===n)?n:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,(this.destroyed=!1)===e.decodeStrings);this.decodeStrings=!r,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){var t,r,n,a,i,o,s,l;e=e,o=(t=c)._writableState,s=o.sync,l=o.writecb,(i=o).writing=!1,i.writecb=null,i.length-=i.writelen,i.writelen=0,e?(i=t,n=s,e=e,a=l,--(r=o).pendingcb,n?(m.nextTick(a,e),m.nextTick(w,i,r),i._writableState.errorEmitted=!0,i.emit("error",e)):(a(e),i._writableState.errorEmitted=!0,i.emit("error",e),w(i,r))):((n=p(o))||o.corked||o.bufferProcessing||!o.bufferedRequest||f(t,o),s?u(d,t,o,n,l):d(t,o,n,l))},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new h(this)}function s(e){if(i=i||Be(),!(t.call(s,this)||this instanceof i))return new s(e);this._writableState=new o(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final)&&(this._final=e.final),n.call(this)}function v(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function d(e,t,r,n){var a;r||(r=e,0===(a=t).length&&a.needDrain&&(a.needDrain=!1,r.emit("drain"))),t.pendingcb--,n(),w(e,t)}function f(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,a=new Array(n),n=t.corkedRequestsFree;n.entry=r;for(var i=0,o=!0;r;)(a[i]=r).isBuf||(o=!1),r=r.next,i+=1;a.allBuffers=o,v(e,t,!0,t.length,a,"",n.finish),t.pendingcb++,t.lastBufferedRequest=null,n.next?(t.corkedRequestsFree=n.next,n.next=null):t.corkedRequestsFree=new h(t),t.bufferedRequestCount=0}else{for(;r;){var s=r.chunk,l=r.encoding,c=r.callback;if(v(e,t,!1,t.objectMode?1:s.length,s,l,c),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function p(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function l(t,r){t._final(function(e){r.pendingcb--,e&&t.emit("error",e),r.prefinished=!0,t.emit("prefinish"),w(t,r)})}function w(e,t){var r,n,a=p(t);return a&&(r=e,(n=t).prefinished||n.finalCalled||("function"==typeof r._final?(n.pendingcb++,n.finalCalled=!0,m.nextTick(l,r,n)):(n.prefinished=!0,r.emit("prefinish"))),0===t.pendingcb)&&(t.finished=!0,e.emit("finish")),a}}function Be(){if(!Oe){Oe=1;var r=ue(),e=Object.keys||function(e){var t,r=[];for(t in e)r.push(t);return r},t=(Ae=l,Object.create(ge())),n=(t.inherits=ke(),qe()),a=Me();t.inherits(l,n);for(var i=e(a.prototype),o=0;o<i.length;o++){var s=i[o];l.prototype[s]||(l.prototype[s]=a.prototype[s])}Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),l.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}}return Ae;function l(e){if(!(this instanceof l))return new l(e);n.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",c)}function c(){this.allowHalfOpen||this._writableState.ended||r.nextTick(u,this)}function u(e){e.end()}}var De,je,Ie,Le,ze,Fe,Ue,We,He={};function Ze(){var r,n;return De||(De=1,r=pe().Buffer,n=r.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}},(He.StringDecoder=e).prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},e.prototype.end=function(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+"�":e},e.prototype.text=function(e,t){r=this,i=t;var r,n,a,i=(a=(o=e).length-1)<i?0:0<=(n=s(o[a]))?(0<n&&(r.lastNeed=n-1),n):--a<i||-2===n?0:0<=(n=s(o[a]))?(0<n&&(r.lastNeed=n-2),n):!(--a<i||-2===n)&&0<=(n=s(o[a]))?(0<n&&(2===n?n=0:r.lastNeed=n-3),n):0;if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=i;var o=e.length-(i-this.lastNeed);return e.copy(this.lastChar,0,o),e.toString("utf8",t,o)},e.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}),He;function e(e){var t;switch(this.encoding=(e=>{var t=(e=>{if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}})(e);if("string"==typeof t||r.isEncoding!==n&&n(e))return t||e;throw new Error("Unknown encoding: "+e)})(e),this.encoding){case"utf16le":this.text=i,this.end=o,t=4;break;case"utf8":this.fillLast=a,t=4;break;case"base64":this.text=l,this.end=c,t=3;break;default:return this.write=u,void(this.end=h)}this.lastNeed=0,this.lastTotal=0,this.lastChar=r.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function a(e){var t,r=this.lastTotal-this.lastNeed,n=(t=this,128!=(192&(n=e)[0])?(t.lastNeed=0,"�"):1<t.lastNeed&&1<n.length?128!=(192&n[1])?(t.lastNeed=1,"�"):2<t.lastNeed&&2<n.length&&128!=(192&n[2])?(t.lastNeed=2,"�"):void 0:void 0);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,r,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,r,0,e.length),void(this.lastNeed-=e.length))}function i(e,t){if((e.length-t)%2!=0)return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1);t=e.toString("utf16le",t);if(t){var r=t.charCodeAt(t.length-1);if(55296<=r&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],t.slice(0,-1)}return t}function o(e){var t,e=e&&e.length?this.write(e):"";return this.lastNeed?(t=this.lastTotal-this.lastNeed,e+this.lastChar.toString("utf16le",0,t)):e}function l(e,t){var r=(e.length-t)%3;return 0==r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1==r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function c(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function u(e){return e.toString(this.encoding)}function h(e){return e&&e.length?this.write(e):""}}function qe(){var g,i,y,b,r,h,d,e,v,o,s,t,l,n,c;return Ie||(Ie=1,g=ue(),je=f,y=(()=>{if(ae)return ne;ae=1;var t={}.toString;return ne=Array.isArray||function(e){return"[object Array]"==t.call(e)}})(),f.ReadableState=u,F.a.EventEmitter,b=function(e,t){return e.listeners(t).length},r=he(),h=pe().Buffer,d=(void 0!==M?M:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},(e=Object.create(ge())).inherits=ke(),t=W.a,v=void 0,v=t&&t.debuglog?t.debuglog("stream"):function(){},_e||(_e=1,t=Ne,l=pe().Buffer,n=W.a,t.exports=(a.prototype.push=function(e){e={data:e,next:null};0<this.length?this.tail.next=e:this.head=e,this.tail=e,++this.length},a.prototype.unshift=function(e){e={data:e,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},a.prototype.shift=function(){var e;if(0!==this.length)return e=this.head.data,1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e},a.prototype.clear=function(){this.head=this.tail=null,this.length=0},a.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},a.prototype.concat=function(e){if(0===this.length)return l.alloc(0);for(var t,r=l.allocUnsafe(e>>>0),n=this.head,a=0;n;)t=a,n.data.copy(r,t),a+=n.data.length,n=n.next;return r},a),n&&n.inspect&&n.inspect.custom&&(t.exports.prototype[n.inspect.custom]=function(){var e=n.inspect({length:this.length});return this.constructor.name+" "+e})),s=Ne.exports,t=Re(),e.inherits(f,r),c=["error","close","destroy","pause","resume"],Object.defineProperty(f.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),f.prototype.destroy=t.destroy,f.prototype._undestroy=t.undestroy,f.prototype._destroy=function(e,t){this.push(null),t(e)},f.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=h.from(e,t),t=""),r=!0),p(this,e,t,!1,r)},f.prototype.unshift=function(e){return p(this,e,null,!0,!1)},f.prototype.isPaused=function(){return!1===this._readableState.flowing},f.prototype.setEncoding=function(e){return o=o||Ze().StringDecoder,this._readableState.decoder=new o(e),this._readableState.encoding=e,this},f.prototype.read=function(e){v("read",e),e=parseInt(e,10);var t,r=this._readableState,n=e;return 0!==e&&(r.emittedReadable=!1),0===e&&r.needReadable&&(r.length>=r.highWaterMark||r.ended)?(v("read: emitReadable",r.length,r.ended),(0===r.length&&r.ended?A:k)(this),null):0===(e=w(e,r))&&r.ended?(0===r.length&&A(this),null):(t=r.needReadable,v("need readable",t),(0===r.length||r.length-e<r.highWaterMark)&&v("length less than watermark",t=!0),r.ended||r.reading?v("reading or ended",t=!1):t&&(v("do read"),r.reading=!0,r.sync=!0,0===r.length&&(r.needReadable=!0),this._read(r.highWaterMark),r.sync=!1,r.reading||(e=w(n,r))),null===(t=0<e?T(e,r):null)?(r.needReadable=!0,e=0):r.length-=e,0===r.length&&(r.ended||(r.needReadable=!0),n!==e)&&r.ended&&A(this),null!==t&&this.emit("data",t),t)},f.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},f.prototype.pipe=function(n,e){var a=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=n;break;case 1:i.pipes=[i.pipes,n];break;default:i.pipes.push(n)}i.pipesCount+=1,v("pipe count=%d opts=%j",i.pipesCount,e);e=e&&!1===e.end||n===R.stdout||n===R.stderr?m:o;function o(){v("onend"),n.end()}i.endEmitted?g.nextTick(e):a.once("end",e),n.on("unpipe",function e(t,r){v("onunpipe"),t===a&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,v("cleanup"),n.removeListener("close",f),n.removeListener("finish",p),n.removeListener("drain",l),n.removeListener("error",d),n.removeListener("unpipe",e),a.removeListener("end",o),a.removeListener("end",m),a.removeListener("data",h),c=!0,!i.awaitDrain||n._writableState&&!n._writableState.needDrain||l())});t=a;var t,r,s,l=function(){var e=t._readableState;v("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&b(t,"data")&&(e.flowing=!0,P(t))},c=(n.on("drain",l),!1),u=!1;function h(e){v("ondata"),(u=!1)!==n.write(e)||u||((1===i.pipesCount&&i.pipes===n||1<i.pipesCount&&-1!==N(i.pipes,n))&&!c&&(v("false write response, pause",i.awaitDrain),i.awaitDrain++,u=!0),a.pause())}function d(e){v("onerror",e),m(),n.removeListener("error",d),0===b(n,"error")&&n.emit("error",e)}function f(){n.removeListener("finish",p),m()}function p(){v("onfinish"),n.removeListener("close",f),m()}function m(){v("unpipe"),a.unpipe(n)}return a.on("data",h),e="error",s=d,"function"==typeof(r=n).prependListener?r.prependListener(e,s):r._events&&r._events[e]?y(r._events[e])?r._events[e].unshift(s):r._events[e]=[s,r._events[e]]:r.on(e,s),n.once("close",f),n.once("finish",p),n.emit("pipe",a),i.flowing||(v("pipe resume"),a.resume()),n},f.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0!==t.pipesCount)if(1===t.pipesCount)e&&e!==t.pipes||(e=e||t.pipes,t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r));else if(e){var n=N(t.pipes,e);-1!==n&&(t.pipes.splice(n,1),--t.pipesCount,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r))}else{var a=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)a[o].emit("unpipe",this,{hasUnpiped:!1})}return this},f.prototype.addListener=f.prototype.on=function(e,t){t=r.prototype.on.call(this,e,t);return"data"===e?!1!==this._readableState.flowing&&this.resume():"readable"!==e||(e=this._readableState).endEmitted||e.readableListening||(e.readableListening=e.needReadable=!0,e.emittedReadable=!1,e.reading?e.length&&k(this):g.nextTick(C,this)),t},f.prototype.resume=function(){var e,t=this._readableState;return t.flowing||(v("resume"),t.flowing=!0,e=this,(t=t).resumeScheduled||(t.resumeScheduled=!0,g.nextTick(E,e,t))),this},f.prototype.pause=function(){return v("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(v("pause"),this._readableState.flowing=!1,this.emit("pause")),this},f.prototype.wrap=function(t){var e,r=this,n=this._readableState,a=!1;for(e in t.on("end",function(){var e;v("wrapped end"),n.decoder&&!n.ended&&(e=n.decoder.end())&&e.length&&r.push(e),r.push(null)}),t.on("data",function(e){v("wrapped data"),n.decoder&&(e=n.decoder.write(e)),n.objectMode&&null==e||(n.objectMode||e&&e.length)&&!r.push(e)&&(a=!0,t.pause())}),t)void 0===this[e]&&"function"==typeof t[e]&&(this[e]=(e=>function(){return t[e].apply(t,arguments)})(e));for(var i=0;i<c.length;i++)t.on(c[i],this.emit.bind(this,c[i]));return this._read=function(e){v("wrapped _read",e),a&&(a=!1,t.resume())},this},Object.defineProperty(f.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),f._fromList=T),je;function a(){if(!(this instanceof a))throw new TypeError("Cannot call a class as a function");this.head=null,this.tail=null,this.length=0}function u(e,t){e=e||{};var t=t instanceof(i=i||Be()),r=(this.objectMode=!!e.objectMode,t&&(this.objectMode=this.objectMode||!!e.readableObjectMode),e.highWaterMark),n=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:t&&(n||0===n)?n:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new s,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(o=o||Ze().StringDecoder,this.decoder=new o(e.encoding),this.encoding=e.encoding)}function f(e){if(i=i||Be(),!(this instanceof f))return new f(e);this._readableState=new u(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy)&&(this._destroy=e.destroy),r.call(this)}function p(e,t,r,n,a){var i,o,s,l,c,u=e._readableState;return null===t?(u.reading=!1,s=e,(l=u).ended||(l.decoder&&(c=l.decoder.end())&&c.length&&(l.buffer.push(c),l.length+=l.objectMode?1:c.length),l.ended=!0,k(s))):(a||(c=u,s=l=t,i=o=h.isBuffer(s)||s instanceof d||"string"==typeof l||void 0===l||c.objectMode?o:new TypeError("Invalid non-string/buffer chunk")),i?e.emit("error",i):u.objectMode||t&&0<t.length?("string"==typeof t||u.objectMode||Object.getPrototypeOf(t)===h.prototype||(a=t,t=h.from(a)),n?u.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):m(e,u,t,!0):u.ended?e.emit("error",new Error("stream.push() after EOF")):(u.reading=!1,!u.decoder||r||(t=u.decoder.write(t),u.objectMode)||0!==t.length?m(e,u,t,!1):S(e,u))):n||(u.reading=!1)),!u.ended&&(u.needReadable||u.length<u.highWaterMark||0===u.length)}function m(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&k(e)),S(e,t)}function w(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?(t.flowing&&t.length?t.buffer.head.data:t).length:(e>t.highWaterMark&&(t.highWaterMark=(8388608<=(r=e)?r=8388608:(r--,r=(r=(r=(r=(r|=r>>>1)|r>>>2)|r>>>4)|r>>>8)|r>>>16,r++),r)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0));var r}function k(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(v("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?g.nextTick(_,e):_(e))}function _(e){v("emit readable"),e.emit("readable"),P(e)}function S(e,t){t.readingMore||(t.readingMore=!0,g.nextTick(x,e,t))}function x(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(v("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function C(e){v("readable nexttick read 0"),e.read(0)}function E(e,t){t.reading||(v("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),P(e),t.flowing&&!t.reading&&e.read(0)}function P(e){var t=e._readableState;for(v("flow",t.flowing);t.flowing&&null!==e.read(););}function T(e,t){return 0===t.length?null:(t.objectMode?a=t.buffer.shift():!e||e>=t.length?(a=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):(e=e,r=t.buffer,t=t.decoder,e<r.head.data.length?(n=r.head.data.slice(0,e),r.head.data=r.head.data.slice(e)):n=e===r.head.data.length?r.shift():(t?(e,t)=>{var r=t.head,n=1,a=r.data;for(e-=a.length;r=r.next;){var i=r.data,o=e>i.length?i.length:e;if(a+=o===i.length?i:i.slice(0,e),0==(e-=o)){o===i.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r).data=i.slice(o);break}++n}return t.length-=n,a}:(e,t)=>{var r=h.allocUnsafe(e),n=t.head,a=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var i=n.data,o=e>i.length?i.length:e;if(i.copy(r,r.length-e,0,o),0==(e-=o)){o===i.length?(++a,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n).data=i.slice(o);break}++a}return t.length-=a,r})(e,r),a=n),a);var r,n,a}function A(e){var t=e._readableState;if(0<t.length)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,g.nextTick(O,t,e))}function O(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function N(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}}function Ve(){var n,e;return ze||(ze=1,Le=t,n=Be(),(e=Object.create(ge())).inherits=ke(),e.inherits(t,n),t.prototype.push=function(e,t){return this._transformState.needTransform=!1,n.prototype.push.call(this,e,t)},t.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},t.prototype._write=function(e,t,r){var n=this._transformState;n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming&&(r=this._readableState,n.needTransform||r.needReadable||r.length<r.highWaterMark)&&this._read(r.highWaterMark)},t.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},t.prototype._destroy=function(e,t){var r=this;n.prototype._destroy.call(this,e,function(e){t(e),r.emit("close")})}),Le;function t(e){if(!(this instanceof t))return new t(e);n.call(this,e),this._transformState={afterTransform:function(e,t){var r=this._transformState,n=(r.transforming=!1,r.writecb);if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,(r.writecb=null)!=t&&this.push(t),n(e),(r=this._readableState).reading=!1,(r.needReadable||r.length<r.highWaterMark)&&this._read(r.highWaterMark)}.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush)&&(this._flush=e.flush),this.on("prefinish",r)}function r(){var r=this;"function"==typeof this._flush?this._flush(function(e,t){a(r,e,t)}):a(this,null,null)}function a(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");e.push(null)}}function Xe(){return We||(We=1,n=(e=le).exports,a=z.a,"disable"===R.env.READABLE_STREAM&&a?(e.exports=a,(n=e.exports=a.Readable).Readable=a.Readable,n.Writable=a.Writable,n.Duplex=a.Duplex,n.Transform=a.Transform,n.PassThrough=a.PassThrough,n.Stream=a):((n=e.exports=qe()).Stream=a||n,(n.Readable=n).Writable=Me(),n.Duplex=Be(),n.Transform=Ve(),n.PassThrough=(Ue||(Ue=1,Fe=t,r=Ve(),(e=Object.create(ge())).inherits=ke(),e.inherits(t,r),t.prototype._transform=function(e,t,r){r(null,e)}),Fe))),le.exports;function t(e){if(!(this instanceof t))return new t(e);r.call(this,e)}var r,e,n,a}if(f.base64=!0,f.array=!0,f.string=!0,f.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,f.nodebuffer=void 0!==I,f.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)f.blob=!1;else{e=new ArrayBuffer(0);try{f.blob=0===new Blob([e],{type:"application/zip"}).size}catch(Li){try{var Ge=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);Ge.append(e),f.blob=0===Ge.getBlob("application/zip").size}catch(Li){f.blob=!1}}}try{f.nodestream=!!Xe().Readable}catch(Li){f.nodestream=!1}var Ke,Je={};function Ye(){var h,u,d;return Ke||(Ke=1,h=s(),u=f,d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",Je.encode=function(e){for(var t,r,n,a,i,o,s=[],l=0,c=e.length,u="string"!==h.getTypeOf(e);l<e.length;)o=c-l,n=u?(t=e[l++],r=l<c?e[l++]:0,l<c?e[l++]:0):(t=e.charCodeAt(l++),r=l<c?e.charCodeAt(l++):0,l<c?e.charCodeAt(l++):0),a=(3&t)<<4|r>>4,i=1<o?(15&r)<<2|n>>6:64,o=2<o?63&n:64,s.push(d.charAt(t>>2)+d.charAt(a)+d.charAt(i)+d.charAt(o));return s.join("")},Je.decode=function(e){var t,r,n,a,i,o=0,s=0;if("data:"===e.substr(0,5))throw new Error("Invalid base64 input, it looks like a data url.");var l,c=3*(e=e.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(e.charAt(e.length-1)===d.charAt(64)&&c--,e.charAt(e.length-2)===d.charAt(64)&&c--,c%1!=0)throw new Error("Invalid base64 input, bad content length.");for(l=new(u.uint8array?Uint8Array:Array)(0|c);o<e.length;)t=d.indexOf(e.charAt(o++))<<2|(a=d.indexOf(e.charAt(o++)))>>4,r=(15&a)<<4|(a=d.indexOf(e.charAt(o++)))>>2,n=(3&a)<<6|(i=d.indexOf(e.charAt(o++))),l[s++]=t,64!==a&&(l[s++]=r),64!==i&&(l[s++]=n);return l}),Je}var $e,Qe,et,tt,rt,l,nt,at,it,ot,o,st,lt,ct,ut,ht,dt,ft,pt,mt={isNode:void 0!==I,newBufferFrom:function(e,t){if(I.from&&I.from!==Uint8Array.from)return I.from(e,t);if("number"==typeof e)throw new Error('The "data" argument must not be a number');return new I(e,t)},allocBuffer:function(e){return I.alloc?I.alloc(e):((e=new I(e)).fill(0),e)},isBuffer:function(e){return I.isBuffer(e)},isStream:function(e){return e&&"function"==typeof e.on&&"function"==typeof e.pause&&"function"==typeof e.resume}},gt={Promise:"undefined"!=typeof Promise?Promise:(c||(c=1,rt=(()=>{if(Qe)return $e;Qe=1;var n,e,t,r,a=M.MutationObserver||M.WebKitMutationObserver,i=R.browser?a?(e=0,a=new a(s),t=M.document.createTextNode(""),a.observe(t,{characterData:!0}),function(){t.data=e=++e%2}):M.setImmediate||void 0===M.MessageChannel?"document"in M&&"onreadystatechange"in M.document.createElement("script")?function(){var e=M.document.createElement("script");e.onreadystatechange=function(){s(),e.onreadystatechange=null,e.parentNode.removeChild(e),e=null},M.document.documentElement.appendChild(e)}:function(){setTimeout(s,0)}:((r=new M.MessageChannel).port1.onmessage=s,function(){r.port2.postMessage(0)}):function(){R.nextTick(s)},o=[];function s(){var e,t;n=!0;for(var r=o.length;r;){for(t=o,o=[],e=-1;++e<r;)t[e]();r=o.length}n=!1}return $e=function(e){1!==o.push(e)||n||i()}})(),l={},nt=["REJECTED"],at=["FULFILLED"],it=["PENDING"],R.browser||(ot=["UNHANDLED"]),(et=bt).prototype.finally=function(t){var r;return"function"!=typeof t?this:(r=this.constructor,this.then(function(e){return r.resolve(t()).then(function(){return e})},function(e){return r.resolve(t()).then(function(){throw e})}))},bt.prototype.catch=function(e){return this.then(null,e)},bt.prototype.then=function(e,t){var r;return"function"!=typeof e&&this.state===at||"function"!=typeof t&&this.state===nt?this:(r=new this.constructor(yt),R.browser||this.handled===ot&&(this.handled=null),this.state!==it?wt(r,this.state===at?e:t,this.outcome):this.queue.push(new vt(r,e,t)),r)},vt.prototype.callFulfilled=function(e){l.resolve(this.promise,e)},vt.prototype.otherCallFulfilled=function(e){wt(this.promise,this.onFulfilled,e)},vt.prototype.callRejected=function(e){l.reject(this.promise,e)},vt.prototype.otherCallRejected=function(e){wt(this.promise,this.onRejected,e)},l.resolve=function(e,t){var r=St(kt,t);if("error"===r.status)return l.reject(e,r.value);r=r.value;if(r)_t(e,r);else{e.state=at,e.outcome=t;for(var n=-1,a=e.queue.length;++n<a;)e.queue[n].callFulfilled(t)}return e},l.reject=function(e,t){e.state=nt,e.outcome=t,R.browser||e.handled===ot&&rt(function(){e.handled===ot&&R.emit("unhandledRejection",t,e)});for(var r=-1,n=e.queue.length;++r<n;)e.queue[r].callRejected(t);return e},bt.resolve=function(e){return e instanceof this?e:l.resolve(new this(yt),e)},bt.reject=function(e){var t=new this(yt);return l.reject(t,e)},bt.all=function(e){var r=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,a=!1;if(!n)return this.resolve([]);for(var i=new Array(n),o=0,t=-1,s=new this(yt);++t<n;)((e,t)=>{r.resolve(e).then(function(e){i[t]=e,++o!==n||a||(a=!0,l.resolve(s,i))},function(e){a||(a=!0,l.reject(s,e))})})(e[t],t);return s},bt.race=function(e){if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var t=e.length,r=!1;if(!t)return this.resolve([]);for(var n,a=-1,i=new this(yt);++a<t;)n=e[a],this.resolve(n).then(function(e){r||(r=!0,l.resolve(i,e))},function(e){r||(r=!0,l.reject(i,e))});return i}),et)};function yt(){}function bt(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=it,this.queue=[],this.outcome=void 0,R.browser||(this.handled=ot),e!==yt&&_t(this,e)}function vt(e,t,r){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof r&&(this.onRejected=r,this.callRejected=this.otherCallRejected)}function wt(t,r,n){rt(function(){var e;try{e=r(n)}catch(e){return l.reject(t,e)}e===t?l.reject(t,new TypeError("Cannot resolve promise with itself")):l.resolve(t,e)})}function kt(e){var t=e&&e.then;if(e&&("object"==te(e)||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function _t(t,e){var r=!1;function n(e){r||(r=!0,l.reject(t,e))}function a(e){r||(r=!0,l.resolve(t,e))}var i=St(function(){e(a,n)});"error"===i.status&&n(i.value)}function St(e,t){var r={};try{r.value=e(t),r.status="success"}catch(e){r.status="error",r.value=e}return r}function s(){return tt||(tt=1,s=se,l=f,c=Ye(),n=mt,u=gt,s.newBlob=function(t,r){s.checkSupport("blob");try{return new Blob([t],{type:r})}catch(e){try{var n=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return n.append(t),n.getBlob(r)}catch(e){throw new Error("Bug : can't construct the Blob.")}}},a={stringifyByChunk:function(e,t,r){var n=[],a=0,i=e.length;if(i<=r)return String.fromCharCode.apply(null,e);for(;a<i;)n.push("array"===t||"nodebuffer"===t?String.fromCharCode.apply(null,e.slice(a,Math.min(a+r,i))):String.fromCharCode.apply(null,e.subarray(a,Math.min(a+r,i)))),a+=r;return n.join("")},stringifyByChar:function(e){for(var t="",r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return t},applyCanBeUsed:{uint8array:(()=>{try{return l.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(e){return!1}})(),nodebuffer:(()=>{try{return l.nodebuffer&&1===String.fromCharCode.apply(null,n.allocBuffer(1)).length}catch(e){return!1}})()}},s.applyFromCharCode=t,(i={}).string={string:e,array:function(e){return o(e,new Array(e.length))},arraybuffer:function(e){return i.string.uint8array(e).buffer},uint8array:function(e){return o(e,new Uint8Array(e.length))},nodebuffer:function(e){return o(e,n.allocBuffer(e.length))}},i.array={string:t,array:e,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return n.newBufferFrom(e)}},i.arraybuffer={string:function(e){return t(new Uint8Array(e))},array:function(e){return r(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:e,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return n.newBufferFrom(new Uint8Array(e))}},i.uint8array={string:t,array:function(e){return r(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:e,nodebuffer:function(e){return n.newBufferFrom(e)}},i.nodebuffer={string:t,array:function(e){return r(e,new Array(e.length))},arraybuffer:function(e){return i.nodebuffer.uint8array(e).buffer},uint8array:function(e){return r(e,new Uint8Array(e.length))},nodebuffer:e},s.transformTo=function(e,t){if(t=t||"",!e)return t;s.checkSupport(e);var r=s.getTypeOf(t);return i[r][e](t)},s.resolve=function(e){for(var t=e.split("/"),r=[],n=0;n<t.length;n++){var a=t[n];"."===a||""===a&&0!==n&&n!==t.length-1||(".."===a?r.pop():r.push(a))}return r.join("/")},s.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":l.nodebuffer&&n.isBuffer(e)?"nodebuffer":l.uint8array&&e instanceof Uint8Array?"uint8array":l.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},s.checkSupport=function(e){if(!l[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},s.MAX_VALUE_16BITS=65535,s.MAX_VALUE_32BITS=-1,s.pretty=function(e){for(var t,r="",n=0;n<(e||"").length;n++)r+="\\x"+((t=e.charCodeAt(n))<16?"0":"")+t.toString(16).toUpperCase();return r},s.delay=function(e,t,r){j(function(){e.apply(r||null,t||[])})},s.inherits=function(e,t){function r(){}r.prototype=t.prototype,e.prototype=new r},s.extend=function(){for(var e,t={},r=0;r<arguments.length;r++)for(e in arguments[r])Object.prototype.hasOwnProperty.call(arguments[r],e)&&void 0===t[e]&&(t[e]=arguments[r][e]);return t},s.prepareContent=function(r,e,n,a,i){return u.Promise.resolve(e).then(function(n){return l.blob&&(n instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(n)))&&"undefined"!=typeof FileReader?new u.Promise(function(t,r){var e=new FileReader;e.onload=function(e){t(e.target.result)},e.onerror=function(e){r(e.target.error)},e.readAsArrayBuffer(n)}):n}).then(function(e){var t=s.getTypeOf(e);return t?("arraybuffer"===t?e=s.transformTo("uint8array",e):"string"===t&&(i?e=c.decode(e):n&&!0!==a&&(e=o(t=e,new(l.uint8array?Uint8Array:Array)(t.length)))),e):u.Promise.reject(new Error("Can't read the data of '"+r+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}),se;function e(e){return e}function o(e,t){for(var r=0;r<e.length;++r)t[r]=255&e.charCodeAt(r);return t}function t(e){var t=65536,r=s.getTypeOf(e),n=!0;if("uint8array"===r?n=a.applyCanBeUsed.uint8array:"nodebuffer"===r&&(n=a.applyCanBeUsed.nodebuffer),n)for(;1<t;)try{return a.stringifyByChunk(e,r,t)}catch(e){t=Math.floor(t/2)}return a.stringifyByChar(e)}function r(e,t){for(var r=0;r<e.length;r++)t[r]=e[r];return t}var s,l,c,n,u,a,i}function xt(e){this.name=e||"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}function Ct(e){delete ht[e]}function Et(e){if(dt)setTimeout(Et,0,e);else{var t=ht[e];if(t){dt=!0;try{var r=t.callback,n=t.args;switch(n.length){case 0:r();break;case 1:r(n[0]);break;case 2:r(n[0],n[1]);break;case 3:r(n[0],n[1],n[2]);break;default:r.apply(void 0,n)}}finally{Ct(e),dt=!1}}}}(o="undefined"==typeof self?M:self).setImmediate||(ut=1,dt=!(ht={}),ft=o.document,e=(e=Object.getPrototypeOf&&Object.getPrototypeOf(o))&&e.setTimeout?e:o,pt="[object process]"==={}.toString.call(o.process)?function(e){R.nextTick(function(){Et(e)})}:(()=>{var e,t;if(o.postMessage&&!o.importScripts)return e=!0,t=o.onmessage,o.onmessage=function(){e=!1},o.postMessage("","*"),o.onmessage=t,e})()?(ct="setImmediate$"+Math.random()+"$",Ge=function(e){e.source===o&&"string"==typeof e.data&&0===e.data.indexOf(ct)&&Et(+e.data.slice(ct.length))},o.addEventListener?o.addEventListener("message",Ge,!1):o.attachEvent("onmessage",Ge),function(e){o.postMessage(ct+e,"*")}):o.MessageChannel?((lt=new MessageChannel).port1.onmessage=function(e){Et(e.data)},function(e){lt.port2.postMessage(e)}):ft&&"onreadystatechange"in ft.createElement("script")?(st=ft.documentElement,function(e){var t=ft.createElement("script");t.onreadystatechange=function(){Et(e),t.onreadystatechange=null,st.removeChild(t),t=null},st.appendChild(t)}):function(e){setTimeout(Et,0,e)},e.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];return ht[ut]={callback:e,args:t},pt(ut),ut++},e.clearImmediate=Ct),xt.prototype={push:function(e){this.emit("data",e)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},on:function(e,t){return this._listeners[e].push(t),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(e,t){if(this._listeners[e])for(var r=0;r<this._listeners[e].length;r++)this._listeners[e][r].call(this,t)},pipe:function(e){return e.registerPrevious(this)},registerPrevious:function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",function(e){t.processChunk(e)}),e.on("end",function(){t.end()}),e.on("error",function(e){t.error(e)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){var e;return!(!this.isPaused||this.isFinished||(e=this.isPaused=!1,this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),e))},flush:function(){},processChunk:function(e){this.push(e)},withStreamInfo:function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var e in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},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 e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e}};for(var c=xt,Pt=L,Tt=s(),At=f,Ot=mt,Nt=c,Rt=new Array(256),Mt=0;Mt<256;Mt++)Rt[Mt]=252<=Mt?6:248<=Mt?5:240<=Mt?4:224<=Mt?3:192<=Mt?2:1;function Bt(){Nt.call(this,"utf-8 decode"),this.leftOver=null}function Dt(){Nt.call(this,"utf-8 encode")}Rt[254]=Rt[254]=1,Pt.utf8encode=function(e){if(At.nodebuffer)return Ot.newBufferFrom(e,"utf-8");for(var t,r,n,a,i=e,o=i.length,s=0,l=0;l<o;l++)55296==(64512&(r=i.charCodeAt(l)))&&l+1<o&&56320==(64512&(n=i.charCodeAt(l+1)))&&(r=65536+(r-55296<<10)+(n-56320),l++),s+=r<128?1:r<2048?2:r<65536?3:4;for(t=new(At.uint8array?Uint8Array:Array)(s),l=a=0;a<s;l++)55296==(64512&(r=i.charCodeAt(l)))&&l+1<o&&56320==(64512&(n=i.charCodeAt(l+1)))&&(r=65536+(r-55296<<10)+(n-56320),l++),r<128?t[a++]=r:(r<2048?t[a++]=192|r>>>6:(r<65536?t[a++]=224|r>>>12:(t[a++]=240|r>>>18,t[a++]=128|r>>>12&63),t[a++]=128|r>>>6&63),t[a++]=128|63&r);return t},Pt.utf8decode=function(e){if(At.nodebuffer)return Tt.transformTo("nodebuffer",e).toString("utf-8");for(var t,r,n=e=Tt.transformTo(At.uint8array?"uint8array":"array",e),a=n.length,i=new Array(2*a),o=0,s=0;s<a;)if((t=n[s++])<128)i[o++]=t;else if(4<(r=Rt[t]))i[o++]=65533,s+=r-1;else{for(t&=2===r?31:3===r?15:7;1<r&&s<a;)t=t<<6|63&n[s++],r--;1<r?i[o++]=65533:t<65536?i[o++]=t:(t-=65536,i[o++]=55296|t>>10&1023,i[o++]=56320|1023&t)}return i.length!==o&&(i.subarray?i=i.subarray(0,o):i.length=o),Tt.applyFromCharCode(i)},Tt.inherits(Bt,Nt),Bt.prototype.processChunk=function(e){var t=Tt.transformTo(At.uint8array?"uint8array":"array",e.data),r=(this.leftOver&&this.leftOver.length&&(At.uint8array?(r=t,(t=new Uint8Array(r.length+this.leftOver.length)).set(this.leftOver,0),t.set(r,this.leftOver.length)):t=this.leftOver.concat(t),this.leftOver=null),((e,t)=>{for(var r=(t=(t=t||e.length)>e.length?e.length:t)-1;0<=r&&128==(192&e[r]);)r--;return!(r<0||0===r)&&r+Rt[e[r]]>t?r:t})(t)),n=t;r!==t.length&&(At.uint8array?(n=t.subarray(0,r),this.leftOver=t.subarray(r,t.length)):(n=t.slice(0,r),this.leftOver=t.slice(r,t.length))),this.push({data:Pt.utf8decode(n),meta:e.meta})},Bt.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:Pt.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},Pt.Utf8DecodeWorker=Bt,Tt.inherits(Dt,Nt),Dt.prototype.processChunk=function(e){this.push({data:Pt.utf8encode(e.data),meta:e.meta})},Pt.Utf8EncodeWorker=Dt;var jt=c,It=s();function Lt(e){jt.call(this,"ConvertWorker to "+e),this.destType=e}It.inherits(Lt,jt),Lt.prototype.processChunk=function(e){this.push({data:It.transformTo(this.destType,e.data),meta:e.meta})};var zt,Ft,e=Lt,Ut=s(),Wt=e,Ht=c,Zt=Ye(),qt=gt,Vt=null;if(f.nodestream)try{Vt=(()=>{if(Ft)return zt;Ft=1;var a=Xe().Readable;function e(e,t,r){a.call(this,t),this._helper=e;var n=this;e.on("data",function(e,t){n.push(e)||n._helper.pause(),r&&r(t)}).on("error",function(e){n.emit("error",e)}).on("end",function(){n.push(null)})}return s().inherits(e,a),e.prototype._read=function(){this._helper.resume()},zt=e})()}catch(Li){}function Xt(e,t,r){var n=t;switch(t){case"blob":case"arraybuffer":n="uint8array";break;case"base64":n="string"}try{this._internalType=n,this._outputType=t,this._mimeType=r,Ut.checkSupport(n),this._worker=e.pipe(new Wt(n)),e.lock()}catch(e){this._worker=new Ht("error"),this._worker.error(e)}}Xt.prototype={accumulate:function(e){return s=this,l=e,new qt.Promise(function(t,r){var n=[],a=s._internalType,i=s._outputType,o=s._mimeType;s.on("data",function(e,t){n.push(e),l&&l(t)}).on("error",function(e){n=[],r(e)}).on("end",function(){try{var e=((e,t,r)=>{switch(e){case"blob":return Ut.newBlob(Ut.transformTo("arraybuffer",t),r);case"base64":return Zt.encode(t);default:return Ut.transformTo(e,t)}})(i,((e,t)=>{for(var r=0,n=null,a=0,i=0;i<t.length;i++)a+=t[i].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(n=new Uint8Array(a),i=0;i<t.length;i++)n.set(t[i],r),r+=t[i].length;return n;case"nodebuffer":return I.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}})(a,n),o);t(e)}catch(e){r(e)}n=[]}).resume()});var s,l},on:function(e,t){var r=this;return"data"===e?this._worker.on(e,function(e){t.call(r,e.data,e.meta)}):this._worker.on(e,function(){Ut.delay(t,arguments,r)}),this},resume:function(){return Ut.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(e){if(Ut.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw new Error(this._outputType+" is not supported by this method");return new Vt(this,{objectMode:"nodebuffer"!==this._outputType},e)}};var e=Xt,Gt={base64:!1,binary:!1,dir:!1,createFolders:!0,date:null,compression:null,compressionOptions:null,comment:null,unixPermissions:null,dosPermissions:null},Kt=s(),Jt=c;function Yt(e){Jt.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then(function(e){t.dataIsReady=!0,t.data=e,t.max=e&&e.length||0,t.type=Kt.getTypeOf(e),t.isPaused||t._tickAndRepeat()},function(e){t.error(e)})}Kt.inherits(Yt,Jt),Yt.prototype.cleanUp=function(){Jt.prototype.cleanUp.call(this),this.data=null},Yt.prototype.resume=function(){return!!Jt.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,Kt.delay(this._tickAndRepeat,[],this)),!0)},Yt.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished)||(Kt.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0)},Yt.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=null,t=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":e=this.data.substring(this.index,t);break;case"uint8array":e=this.data.subarray(this.index,t);break;case"array":case"nodebuffer":e=this.data.slice(this.index,t)}return this.index=t,this.push({data:e,meta:{percent:this.max?this.index/this.max*100:0}})};function $t(e,t){return void 0!==e&&e.length?("string"!==Qt.getTypeOf(e)?(e,t,r)=>{var n=er,a=0+r;e^=-1;for(var i=0;i<a;i++)e=e>>>8^n[255&(e^t[i])];return-1^e}:(e,t,r)=>{var n=er,a=0+r;e^=-1;for(var i=0;i<a;i++)e=e>>>8^n[255&(e^t.charCodeAt(i))];return-1^e})(0|t,e,e.length):0}var u=Yt,Qt=s(),er=(()=>{for(var e=[],t=0;t<256;t++){for(var r=t,n=0;n<8;n++)r=1&r?3988292384^r>>>1:r>>>1;e[t]=r}return e})(),tr=c,rr=$t;function nr(){tr.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}s().inherits(nr,tr),nr.prototype.processChunk=function(e){this.streamInfo.crc32=rr(e.data,this.streamInfo.crc32||0),this.push(e)};var ar=nr,ir=s(),or=c;function sr(e){or.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}ir.inherits(sr,or),sr.prototype.processChunk=function(e){var t;e&&(t=this.streamInfo[this.propName]||0,this.streamInfo[this.propName]=t+e.data.length),or.prototype.processChunk.call(this,e)};var lr=gt,cr=u,ur=ar,hr=sr;function dr(e,t,r,n,a){this.compressedSize=e,this.uncompressedSize=t,this.crc32=r,this.compression=n,this.compressedContent=a}dr.prototype={getContentWorker:function(){var e=new cr(lr.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new hr("data_length")),t=this;return e.on("end",function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),e},getCompressedWorker:function(){return new cr(lr.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},dr.createWorkerFrom=function(e,t,r){return e.pipe(new ur).pipe(new hr("uncompressedSize")).pipe(t.compressWorker(r)).pipe(new hr("compressedSize")).withStreamInfo("compression",t)};function fr(e,t,r){this.name=e,this.dir=r.dir,this.date=r.date,this.comment=r.comment,this.unixPermissions=r.unixPermissions,this.dosPermissions=r.dosPermissions,this._data=t,this._dataBinary=r.binary,this.options={compression:r.compression,compressionOptions:r.compressionOptions}}var ir=dr,pr=e,mr=u,gr=L,yr=ir,br=c;fr.prototype={internalStream:function(e){var t=null,r="string";try{if(!e)throw new Error("No output type specified.");var n="string"===(r=e.toLowerCase())||"text"===r,a=("binarystring"!==r&&"text"!==r||(r="string"),t=this._decompressWorker(),!this._dataBinary);a&&!n&&(t=t.pipe(new gr.Utf8EncodeWorker)),!a&&n&&(t=t.pipe(new gr.Utf8DecodeWorker))}catch(e){(t=new br("error")).error(e)}return new pr(t,r,"")},async:function(e,t){return this.internalStream(e).accumulate(t)},nodeStream:function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},_compressWorker:function(e,t){var r;return this._data instanceof yr&&this._data.compression.magic===e.magic?this._data.getCompressedWorker():(r=this._decompressWorker(),this._dataBinary||(r=r.pipe(new gr.Utf8EncodeWorker)),yr.createWorkerFrom(r,e,t))},_decompressWorker:function(){return this._data instanceof yr?this._data.getContentWorker():this._data instanceof br?this._data:new mr(this._data)}};for(var vr=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],wr=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},kr=0;kr<vr.length;kr++)fr.prototype[vr[kr]]=wr;var h,_r,Sr,u=fr,d={},xr={},Cr={},Er={},p=(h=Er,p="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array,h.assign=function(e){for(var t,r,n=Array.prototype.slice.call(arguments,1);n.length;){var a=n.shift();if(a){if("object"!=te(a))throw new TypeError(a+"must be non-object");for(var i in a)t=a,r=i,Object.prototype.hasOwnProperty.call(t,r)&&(e[i]=a[i])}}return e},h.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)},_r={arraySet:function(e,t,r,n,a){if(t.subarray&&e.subarray)e.set(t.subarray(r,r+n),a);else for(var i=0;i<n;i++)e[a+i]=t[r+i]},flattenChunks:function(e){for(var t,r,n,a=0,i=0,o=e.length;i<o;i++)a+=e[i].length;for(n=new Uint8Array(a),i=t=0,o=e.length;i<o;i++)r=e[i],n.set(r,t),t+=r.length;return n}},Sr={arraySet:function(e,t,r,n,a){for(var i=0;i<n;i++)e[a+i]=t[r+i]},flattenChunks:function(e){return[].concat.apply([],e)}},h.setTyped=function(e){e?(h.Buf8=Uint8Array,h.Buf16=Uint16Array,h.Buf32=Int32Array,h.assign(h,_r)):(h.Buf8=Array,h.Buf16=Array,h.Buf32=Array,h.assign(h,Sr))},h.setTyped(p),{}),m={},g={},Pr=Er;function Tr(e){for(var t=e.length;0<=--t;)e[t]=0}var Ar=[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],Or=[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],Nr=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],Rr=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],Mr=new Array(576),Br=(Tr(Mr),new Array(60)),Dr=(Tr(Br),new Array(512)),jr=(Tr(Dr),new Array(256)),Ir=(Tr(jr),new Array(29));Tr(Ir);var Lr,zr,Fr,Ur=new Array(30);function Wr(e,t,r,n,a){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=a,this.has_stree=e&&e.length}function Hr(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function Zr(e){return e<256?Dr[e]:Dr[256+(e>>>7)]}function qr(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function Vr(e,t,r){e.bi_valid>16-r?(e.bi_buf|=t<<e.bi_valid&65535,qr(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=r-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}function Xr(e,t,r){Vr(e,r[2*t],r[2*t+1])}function Gr(e,t){for(var r=0;r|=1&e,e>>>=1,r<<=1,0<--t;);return r>>>1}function Kr(e,t,r){for(var n,a=new Array(16),i=0,o=1;o<=15;o++)a[o]=i=i+r[o-1]<<1;for(n=0;n<=t;n++){var s=e[2*n+1];0!==s&&(e[2*n]=Gr(a[s]++,s))}}function Jr(e){for(var t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function Yr(e){8<e.bi_valid?qr(e,e.bi_buf):0<e.bi_valid&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function $r(e,t,r,n){var a=2*t,i=2*r;return e[a]<e[i]||e[a]===e[i]&&n[t]<=n[r]}function Qr(e,t,r){for(var n=e.heap[r],a=r<<1;a<=e.heap_len&&(a<e.heap_len&&$r(t,e.heap[a+1],e.heap[a],e.depth)&&a++,!$r(t,n,e.heap[a],e.depth));)e.heap[r]=e.heap[a],r=a,a<<=1;e.heap[r]=n}function en(e,t,r){var n,a,i,o,s=0;if(0!==e.last_lit)for(;n=e.pending_buf[e.d_buf+2*s]<<8|e.pending_buf[e.d_buf+2*s+1],a=e.pending_buf[e.l_buf+s],s++,0==n?Xr(e,a,t):(Xr(e,(i=jr[a])+256+1,t),0!==(o=Ar[i])&&Vr(e,a-=Ir[i],o),Xr(e,i=Zr(--n),r),0!==(o=Or[i])&&Vr(e,n-=Ur[i],o)),s<e.last_lit;);Xr(e,256,t)}function tn(e,t){var r,n,a,i=t.dyn_tree,o=t.stat_desc.static_tree,s=t.stat_desc.has_stree,l=t.stat_desc.elems,c=-1;for(e.heap_len=0,e.heap_max=573,r=0;r<l;r++)0!==i[2*r]?(e.heap[++e.heap_len]=c=r,e.depth[r]=0):i[2*r+1]=0;for(;e.heap_len<2;)i[2*(a=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[a]=0,e.opt_len--,s&&(e.static_len-=o[2*a+1]);for(t.max_code=c,r=e.heap_len>>1;1<=r;r--)Qr(e,i,r);for(a=l;r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Qr(e,i,1),n=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=n,i[2*a]=i[2*r]+i[2*n],e.depth[a]=(e.depth[r]>=e.depth[n]?e.depth[r]:e.depth[n])+1,i[2*r+1]=i[2*n+1]=a,e.heap[1]=a++,Qr(e,i,1),2<=e.heap_len;);e.heap[--e.heap_max]=e.heap[1];for(var u,h,d,f,p,m=e,g=t.dyn_tree,y=t.max_code,b=t.stat_desc.static_tree,v=t.stat_desc.has_stree,w=t.stat_desc.extra_bits,k=t.stat_desc.extra_base,_=t.stat_desc.max_length,S=0,x=0;x<=15;x++)m.bl_count[x]=0;for(g[2*m.heap[m.heap_max]+1]=0,u=m.heap_max+1;u<573;u++)(x=g[2*g[2*(h=m.heap[u])+1]+1]+1)>_&&(x=_,S++),g[2*h+1]=x,y<h||(m.bl_count[x]++,f=0,k<=h&&(f=w[h-k]),p=g[2*h],m.opt_len+=p*(x+f),v&&(m.static_len+=p*(b[2*h+1]+f)));if(0!==S){do{for(x=_-1;0===m.bl_count[x];)x--}while(m.bl_count[x]--,m.bl_count[x+1]+=2,m.bl_count[_]--,0<(S-=2));for(x=_;0!==x;x--)for(h=m.bl_count[x];0!==h;)(d=m.heap[--u])>y||(g[2*d+1]!==x&&(m.opt_len+=(x-g[2*d+1])*g[2*d],g[2*d+1]=x),h--)}Kr(i,c,e.bl_count)}function rn(e,t,r){var n,a,i=-1,o=t[1],s=0,l=7,c=4;for(0===o&&(l=138,c=3),t[2*(r+1)+1]=65535,n=0;n<=r;n++)a=o,o=t[2*(n+1)+1],++s<l&&a===o||(s<c?e.bl_tree[2*a]+=s:0!==a?(a!==i&&e.bl_tree[2*a]++,e.bl_tree[32]++):s<=10?e.bl_tree[34]++:e.bl_tree[36]++,i=a,c=(s=0)===o?(l=138,3):a===o?(l=6,3):(l=7,4))}function nn(e,t,r){var n,a,i=-1,o=t[1],s=0,l=7,c=4;for(0===o&&(l=138,c=3),n=0;n<=r;n++)if(a=o,o=t[2*(n+1)+1],!(++s<l&&a===o)){if(s<c)for(;Xr(e,a,e.bl_tree),0!=--s;);else 0!==a?(a!==i&&(Xr(e,a,e.bl_tree),s--),Xr(e,16,e.bl_tree),Vr(e,s-3,2)):s<=10?(Xr(e,17,e.bl_tree),Vr(e,s-3,3)):(Xr(e,18,e.bl_tree),Vr(e,s-11,7));i=a,c=(s=0)===o?(l=138,3):a===o?(l=6,3):(l=7,4)}}Tr(Ur);var an=!1;function on(e,t,r,n){Vr(e,0+(n?1:0),3),n=t,t=r,Yr(r=e),qr(r,t),qr(r,~t),Pr.arraySet(r.pending_buf,r.window,n,t,r.pending),r.pending+=t}g._tr_init=function(e){if(!an){for(var t,r,n,a=new Array(16),i=0,o=0;o<28;o++)for(Ir[o]=i,t=0;t<1<<Ar[o];t++)jr[i++]=o;for(jr[i-1]=o,o=n=0;o<16;o++)for(Ur[o]=n,t=0;t<1<<Or[o];t++)Dr[n++]=o;for(n>>=7;o<30;o++)for(Ur[o]=n<<7,t=0;t<1<<Or[o]-7;t++)Dr[256+n++]=o;for(r=0;r<=15;r++)a[r]=0;for(t=0;t<=143;)Mr[2*t+1]=8,t++,a[8]++;for(;t<=255;)Mr[2*t+1]=9,t++,a[9]++;for(;t<=279;)Mr[2*t+1]=7,t++,a[7]++;for(;t<=287;)Mr[2*t+1]=8,t++,a[8]++;for(Kr(Mr,287,a),t=0;t<30;t++)Br[2*t+1]=5,Br[2*t]=Gr(t,5);Lr=new Wr(Mr,Ar,257,286,15),zr=new Wr(Br,Or,0,30,15),Fr=new Wr(new Array(0),Nr,0,19,7),an=!0}e.l_desc=new Hr(e.dyn_ltree,Lr),e.d_desc=new Hr(e.dyn_dtree,zr),e.bl_desc=new Hr(e.bl_tree,Fr),e.bi_buf=0,e.bi_valid=0,Jr(e)},g._tr_stored_block=on,g._tr_flush_block=function(e,t,r,n){var a,i,o,s=0;if(0<e.level?(2===e.strm.data_type&&(e.strm.data_type=(e=>{for(var t=4093624447,r=0;r<=31;r++,t>>>=1)if(1&t&&0!==e.dyn_ltree[2*r])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(r=32;r<256;r++)if(0!==e.dyn_ltree[2*r])return 1;return 0})(e)),tn(e,e.l_desc),tn(e,e.d_desc),s=(e=>{var t;for(rn(e,e.dyn_ltree,e.l_desc.max_code),rn(e,e.dyn_dtree,e.d_desc.max_code),tn(e,e.bl_desc),t=18;3<=t&&0===e.bl_tree[2*Rr[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t})(e),(i=e.static_len+3+7>>>3)<=(a=e.opt_len+3+7>>>3)&&(a=i)):a=i=r+5,r+4<=a&&-1!==t)on(e,t,r,n);else if(4===e.strategy||i===a)Vr(e,2+(n?1:0),3),en(e,Mr,Br);else{Vr(e,4+(n?1:0),3);var l=e,c=(t=e.l_desc.max_code+1,r=e.d_desc.max_code+1,s+1);for(Vr(l,t-257,5),Vr(l,r-1,5),Vr(l,c-4,4),o=0;o<c;o++)Vr(l,l.bl_tree[2*Rr[o]+1],3);nn(l,l.dyn_ltree,t-1),nn(l,l.dyn_dtree,r-1),en(e,e.dyn_ltree,e.dyn_dtree)}Jr(e),n&&Yr(e)},g._tr_tally=function(e,t,r){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&r,e.last_lit++,0===t?e.dyn_ltree[2*r]++:(e.matches++,t--,e.dyn_ltree[2*(jr[r]+256+1)]++,e.dyn_dtree[2*Zr(t)]++),e.last_lit===e.lit_bufsize-1},g._tr_align=function(e){Vr(e,2,3),Xr(e,256,Mr),16===(e=e).bi_valid?(qr(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):8<=e.bi_valid&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)};function sn(e,t,r,n){for(var a=65535&e|0,i=e>>>16&65535|0,o=0;0!==r;){for(r-=o=2e3<r?2e3:r;i=i+(a=a+t[n++]|0)|0,--o;);a%=65521,i%=65521}return a|i<<16|0}function ln(e,t,r,n){var a=un,i=n+r;e^=-1;for(var o=n;o<i;o++)e=e>>>8^a[255&(e^t[o])];return-1^e}var cn,un=(()=>{for(var e=[],t=0;t<256;t++){for(var r=t,n=0;n<8;n++)r=1&r?3988292384^r>>>1:r>>>1;e[t]=r}return e})(),hn={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"},y=Er,dn=g,fn=sn,pn=ln,mn=hn,gn=258,yn=262;function bn(e,t){return e.msg=mn[t],t}function vn(e){return(e<<1)-(4<e?9:0)}function wn(e){for(var t=e.length;0<=--t;)e[t]=0}function kn(e){var t=e.state,r=t.pending;0!==(r=e.avail_out<r?e.avail_out:r)&&(y.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,0===t.pending)&&(t.pending_out=0)}function b(e,t){dn._tr_flush_block(e,0<=e.block_start?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,kn(e.strm)}function v(e,t){e.pending_buf[e.pending++]=t}function _n(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function Sn(e,t){var r,n,a=e.max_chain_length,i=e.strstart,o=e.prev_length,s=e.nice_match,l=e.w_size-yn<e.strstart?e.strstart-(e.w_size-yn):0,c=e.window,u=e.w_mask,h=e.prev,d=e.strstart+gn,f=c[i+o-1],p=c[i+o];e.good_match<=e.prev_length&&(a>>=2),e.lookahead<s&&(s=e.lookahead);do{if(c[(r=t)+o]===p&&c[r+o-1]===f&&c[r]===c[i]&&c[++r]===c[i+1]){for(i+=2,r++;c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&i<d;);if(n=gn-(d-i),i=d-gn,o<n){if(e.match_start=t,s<=(o=n))break;f=c[i+o-1],p=c[i+o]}}}while((t=h[t&u])>l&&0!=--a);return o<=e.lookahead?o:e.lookahead}function xn(e){var t,r,n,a,i,o,s,l,c,u=e.w_size;do{if(l=e.window_size-e.lookahead-e.strstart,u+(u-yn)<=e.strstart){for(y.arraySet(e.window,e.window,u,u,0),e.match_start-=u,e.strstart-=u,e.block_start-=u,t=r=e.hash_size;n=e.head[--t],e.head[t]=u<=n?n-u:0,--r;);for(t=r=u;n=e.prev[--t],e.prev[t]=u<=n?n-u:0,--r;);l+=u}if(0===e.strm.avail_in)break;if(o=e.window,s=e.strstart+e.lookahead,l=l,c=void 0,r=0===(c=(c=(i=e.strm).avail_in)>l?l:c)?0:(i.avail_in-=c,y.arraySet(o,i.input,i.next_in,c,s),1===i.state.wrap?i.adler=fn(i.adler,o,c,s):2===i.state.wrap&&(i.adler=pn(i.adler,o,c,s)),i.next_in+=c,i.total_in+=c,c),e.lookahead+=r,3<=e.lookahead+e.insert)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+3-1])&e.hash_mask,e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<yn&&0!==e.strm.avail_in)}function Cn(e,t){for(var r,n;;){if(e.lookahead<yn){if(xn(e),e.lookahead<yn&&0===t)return 1;if(0===e.lookahead)break}if(r=0,3<=e.lookahead&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==r&&e.strstart-r<=e.w_size-yn&&(e.match_length=Sn(e,r)),3<=e.match_length)if(n=dn._tr_tally(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&3<=e.lookahead){for(e.match_length--;e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart,0!=--e.match_length;);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=dn._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(b(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,4===t?(b(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(b(e,!1),0===e.strm.avail_out)?1:2}function En(e,t){for(var r,n,a;;){if(e.lookahead<yn){if(xn(e),e.lookahead<yn&&0===t)return 1;if(0===e.lookahead)break}if(r=0,3<=e.lookahead&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==r&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-yn&&(e.match_length=Sn(e,r),e.match_length<=5)&&(1===e.strategy||3===e.match_length&&4096<e.strstart-e.match_start)&&(e.match_length=2),3<=e.prev_length&&e.match_length<=e.prev_length){for(a=e.strstart+e.lookahead-3,n=dn._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;++e.strstart<=a&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!=--e.prev_length;);if(e.match_available=0,e.match_length=2,e.strstart++,n&&(b(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((n=dn._tr_tally(e,0,e.window[e.strstart-1]))&&b(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=dn._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,4===t?(b(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(b(e,!1),0===e.strm.avail_out)?1:2}function Pn(e,t,r,n,a){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=a}function Tn(){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=8,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 y.Buf16(1146),this.dyn_dtree=new y.Buf16(122),this.bl_tree=new y.Buf16(78),wn(this.dyn_ltree),wn(this.dyn_dtree),wn(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new y.Buf16(16),this.heap=new y.Buf16(573),wn(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new y.Buf16(573),wn(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 An(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=2,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?42:113,e.adler=2===t.wrap?0:1,t.last_flush=0,dn._tr_init(t),0):bn(e,-2)}function On(e){var t=An(e);return 0===t&&((e=e.state).window_size=2*e.w_size,wn(e.head),e.max_lazy_match=cn[e.level].max_lazy,e.good_match=cn[e.level].good_length,e.nice_match=cn[e.level].nice_length,e.max_chain_length=cn[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=2,e.match_available=0,e.ins_h=0),t}function Nn(e,t,r,n,a,i){if(!e)return-2;var o=1;if(-1===t&&(t=6),n<0?(o=0,n=-n):15<n&&(o=2,n-=16),a<1||9<a||8!==r||n<8||15<n||t<0||9<t||i<0||4<i)return bn(e,-2);8===n&&(n=9);var s=new Tn;return(e.state=s).strm=e,s.wrap=o,s.gzhead=null,s.w_bits=n,s.w_size=1<<s.w_bits,s.w_mask=s.w_size-1,s.hash_bits=a+7,s.hash_size=1<<s.hash_bits,s.hash_mask=s.hash_size-1,s.hash_shift=~~((s.hash_bits+3-1)/3),s.window=new y.Buf8(2*s.w_size),s.head=new y.Buf16(s.hash_size),s.prev=new y.Buf16(s.w_size),s.lit_bufsize=1<<a+6,s.pending_buf_size=4*s.lit_bufsize,s.pending_buf=new y.Buf8(s.pending_buf_size),s.d_buf=+s.lit_bufsize,s.l_buf=3*s.lit_bufsize,s.level=t,s.strategy=i,s.method=r,On(e)}cn=[new Pn(0,0,0,0,function(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(xn(e),0===e.lookahead&&0===t)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,b(e,!1),0===e.strm.avail_out))return 1;if(e.w_size-yn<=e.strstart-e.block_start&&(b(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(b(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(b(e,!1),e.strm.avail_out),1)}),new Pn(4,4,8,4,Cn),new Pn(4,5,16,8,Cn),new Pn(4,6,32,32,Cn),new Pn(4,4,16,16,En),new Pn(8,16,32,32,En),new Pn(8,16,128,128,En),new Pn(8,32,128,256,En),new Pn(32,128,258,1024,En),new Pn(32,258,258,4096,En)],m.deflateInit=function(e,t){return Nn(e,t,8,15,8,0)},m.deflateInit2=Nn,m.deflateReset=On,m.deflateResetKeep=An,m.deflateSetHeader=function(e,t){return!e||!e.state||2!==e.state.wrap?-2:(e.state.gzhead=t,0)},m.deflate=function(e,t){var r,n,a,i;if(!e||!e.state||5<t||t<0)return e?bn(e,-2):-2;if(n=e.state,!e.output||!e.input&&0!==e.avail_in||666===n.status&&4!==t)return bn(e,0===e.avail_out?-5:-2);if(n.strm=e,r=n.last_flush,n.last_flush=t,42===n.status&&(2===n.wrap?(e.adler=0,v(n,31),v(n,139),v(n,8),n.gzhead?(v(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),v(n,255&n.gzhead.time),v(n,n.gzhead.time>>8&255),v(n,n.gzhead.time>>16&255),v(n,n.gzhead.time>>24&255),v(n,9===n.level?2:2<=n.strategy||n.level<2?4:0),v(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(v(n,255&n.gzhead.extra.length),v(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=pn(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69):(v(n,0),v(n,0),v(n,0),v(n,0),v(n,0),v(n,9===n.level?2:2<=n.strategy||n.level<2?4:0),v(n,3),n.status=113)):(o=8+(n.w_bits-8<<4)<<8,o|=(2<=n.strategy||n.level<2?0:n.level<6?1:6===n.level?2:3)<<6,0!==n.strstart&&(o|=32),o+=31-o%31,n.status=113,_n(n,o),0!==n.strstart&&(_n(n,e.adler>>>16),_n(n,65535&e.adler)),e.adler=1)),69===n.status)if(n.gzhead.extra){for(a=n.pending;n.gzindex<(65535&n.gzhead.extra.length)&&(n.pending!==n.pending_buf_size||(n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),kn(e),a=n.pending,n.pending!==n.pending_buf_size));)v(n,255&n.gzhead.extra[n.gzindex]),n.gzindex++;n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=73)}else n.status=73;if(73===n.status)if(n.gzhead.name){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),kn(e),a=n.pending,n.pending===n.pending_buf_size)){i=1;break}}while(i=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0,v(n,i),0!==i);n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),0===i&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),kn(e),a=n.pending,n.pending===n.pending_buf_size)){i=1;break}}while(i=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0,v(n,i),0!==i);n.gzhead.hcrc&&n.pending>a&&(e.adler=pn(e.adler,n.pending_buf,n.pending-a,a)),0===i&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&kn(e),n.pending+2<=n.pending_buf_size&&(v(n,255&e.adler),v(n,e.adler>>8&255),e.adler=0,n.status=113)):n.status=113),0!==n.pending){if(kn(e),0===e.avail_out)return n.last_flush=-1,0}else if(0===e.avail_in&&vn(t)<=vn(r)&&4!==t)return bn(e,-5);if(666===n.status&&0!==e.avail_in)return bn(e,-5);if(0!==e.avail_in||0!==n.lookahead||0!==t&&666!==n.status){var o=2===n.strategy?((e,t)=>{for(var r;;){if(0===e.lookahead&&(xn(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,r=dn._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(b(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(b(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(b(e,!1),0===e.strm.avail_out)?1:2})(n,t):3===n.strategy?((e,t)=>{for(var r,n,a,i,o=e.window;;){if(e.lookahead<=gn){if(xn(e),e.lookahead<=gn&&0===t)return 1;if(0===e.lookahead)break}if(e.match_length=0,3<=e.lookahead&&0<e.strstart&&(n=o[a=e.strstart-1])===o[++a]&&n===o[++a]&&n===o[++a]){for(i=e.strstart+gn;n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&a<i;);e.match_length=gn-(i-a),e.lookahead<e.match_length&&(e.match_length=e.lookahead)}if(3<=e.match_length?(r=dn._tr_tally(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=dn._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(b(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(b(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(b(e,!1),0===e.strm.avail_out)?1:2})(n,t):cn[n.level].func(n,t);if(3!==o&&4!==o||(n.status=666),1===o||3===o)return 0===e.avail_out&&(n.last_flush=-1),0;if(2===o&&(1===t?dn._tr_align(n):5!==t&&(dn._tr_stored_block(n,0,0,!1),3===t)&&(wn(n.head),0===n.lookahead)&&(n.strstart=0,n.block_start=0,n.insert=0),kn(e),0===e.avail_out))return n.last_flush=-1,0}return 4!==t||!(n.wrap<=0)&&(2===n.wrap?(v(n,255&e.adler),v(n,e.adler>>8&255),v(n,e.adler>>16&255),v(n,e.adler>>24&255),v(n,255&e.total_in),v(n,e.total_in>>8&255),v(n,e.total_in>>16&255),v(n,e.total_in>>24&255)):(_n(n,e.adler>>>16),_n(n,65535&e.adler)),kn(e),0<n.wrap&&(n.wrap=-n.wrap),0!==n.pending)?0:1},m.deflateEnd=function(e){var t;return e&&e.state?42!==(t=e.state.status)&&69!==t&&73!==t&&91!==t&&103!==t&&113!==t&&666!==t?bn(e,-2):(e.state=null,113===t?bn(e,-3):0):-2},m.deflateSetDictionary=function(e,t){var r,n,a,i,o,s,l,c=t.length;if(!e||!e.state)return-2;if(2===(i=(r=e.state).wrap)||1===i&&42!==r.status||r.lookahead)return-2;for(1===i&&(e.adler=fn(e.adler,t,c,0)),r.wrap=0,r.w_size<=c&&(0===i&&(wn(r.head),r.strstart=0,r.block_start=0,r.insert=0),l=new y.Buf8(r.w_size),y.arraySet(l,t,c-r.w_size,r.w_size,0),t=l,c=r.w_size),l=e.avail_in,o=e.next_in,s=e.input,e.avail_in=c,e.next_in=0,e.input=t,xn(r);3<=r.lookahead;){for(n=r.strstart,a=r.lookahead-2;r.ins_h=(r.ins_h<<r.hash_shift^r.window[n+3-1])&r.hash_mask,r.prev[n&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=n,n++,--a;);r.strstart=n,r.lookahead=2,xn(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=o,e.input=s,e.avail_in=l,r.wrap=i,0},m.deflateInfo="pako deflate (from Nodeca project)";var g={},Rn=Er,Mn=!0,Bn=!0;try{String.fromCharCode.apply(null,[0])}catch(Li){Mn=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(Li){Bn=!1}for(var Dn=new Rn.Buf8(256),jn=0;jn<256;jn++)Dn[jn]=252<=jn?6:248<=jn?5:240<=jn?4:224<=jn?3:192<=jn?2:1;function In(e,t){if(t<65534&&(e.subarray&&Bn||!e.subarray&&Mn))return String.fromCharCode.apply(null,Rn.shrinkBuf(e,t));for(var r="",n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r}Dn[254]=Dn[254]=1,g.string2buf=function(e){for(var t,r,n,a,i=e.length,o=0,s=0;s<i;s++)55296==(64512&(r=e.charCodeAt(s)))&&s+1<i&&56320==(64512&(n=e.charCodeAt(s+1)))&&(r=65536+(r-55296<<10)+(n-56320),s++),o+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Rn.Buf8(o),s=a=0;a<o;s++)55296==(64512&(r=e.charCodeAt(s)))&&s+1<i&&56320==(64512&(n=e.charCodeAt(s+1)))&&(r=65536+(r-55296<<10)+(n-56320),s++),r<128?t[a++]=r:(r<2048?t[a++]=192|r>>>6:(r<65536?t[a++]=224|r>>>12:(t[a++]=240|r>>>18,t[a++]=128|r>>>12&63),t[a++]=128|r>>>6&63),t[a++]=128|63&r);return t},g.buf2binstring=function(e){return In(e,e.length)},g.binstring2buf=function(e){for(var t=new Rn.Buf8(e.length),r=0,n=t.length;r<n;r++)t[r]=e.charCodeAt(r);return t},g.buf2string=function(e,t){for(var r,n,a=t||e.length,i=new Array(2*a),o=0,s=0;s<a;)if((r=e[s++])<128)i[o++]=r;else if(4<(n=Dn[r]))i[o++]=65533,s+=n-1;else{for(r&=2===n?31:3===n?15:7;1<n&&s<a;)r=r<<6|63&e[s++],n--;1<n?i[o++]=65533:r<65536?i[o++]=r:(r-=65536,i[o++]=55296|r>>10&1023,i[o++]=56320|1023&r)}return In(i,o)},g.utf8border=function(e,t){for(var r=(t=(t=t||e.length)>e.length?e.length:t)-1;0<=r&&128==(192&e[r]);)r--;return!(r<0||0===r)&&r+Dn[e[r]]>t?r:t};function Ln(){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}var zn=m,Fn=Er,Un=g,Wn=hn,Hn=Ln,Zn=Object.prototype.toString;function qn(e){if(!(this instanceof qn))return new qn(e);this.options=Fn.assign({level:-1,method:8,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,to:""},e||{});var e=this.options,t=(e.raw&&0<e.windowBits?e.windowBits=-e.windowBits:e.gzip&&0<e.windowBits&&e.windowBits<16&&(e.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Hn,this.strm.avail_out=0,zn.deflateInit2(this.strm,e.level,e.method,e.windowBits,e.memLevel,e.strategy));if(0!==t)throw new Error(Wn[t]);if(e.header&&zn.deflateSetHeader(this.strm,e.header),e.dictionary){e="string"==typeof e.dictionary?Un.string2buf(e.dictionary):"[object ArrayBuffer]"===Zn.call(e.dictionary)?new Uint8Array(e.dictionary):e.dictionary;if(0!==(t=zn.deflateSetDictionary(this.strm,e)))throw new Error(Wn[t]);this._dict_set=!0}}function Vn(e,t){t=new qn(t);if(t.push(e,!0),t.err)throw t.msg||Wn[t.err];return t.result}qn.prototype.push=function(e,t){var r,n,a=this.strm,i=this.options.chunkSize;if(this.ended)return!1;n=t===~~t?t:!0===t?4:0,"string"==typeof e?a.input=Un.string2buf(e):"[object ArrayBuffer]"===Zn.call(e)?a.input=new Uint8Array(e):a.input=e,a.next_in=0,a.avail_in=a.input.length;do{if(0===a.avail_out&&(a.output=new Fn.Buf8(i),a.next_out=0,a.avail_out=i),1!==(r=zn.deflate(a,n))&&0!==r)return this.onEnd(r),!(this.ended=!0)}while(0!==a.avail_out&&(0!==a.avail_in||4!==n&&2!==n)||("string"===this.options.to?this.onData(Un.buf2binstring(Fn.shrinkBuf(a.output,a.next_out))):this.onData(Fn.shrinkBuf(a.output,a.next_out))),(0<a.avail_in||0===a.avail_out)&&1!==r);return 4===n?(r=zn.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,0===r):2!==n||(this.onEnd(0),!(a.avail_out=0))},qn.prototype.onData=function(e){this.chunks.push(e)},qn.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=Fn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},p.Deflate=qn,p.deflate=Vn,p.deflateRaw=function(e,t){return(t=t||{}).raw=!0,Vn(e,t)},p.gzip=function(e,t){return(t=t||{}).gzip=!0,Vn(e,t)};function Xn(e,t,r,n,a,i,o,s){for(var l,c,u,h,d,f,p,m,g,y=s.bits,b=0,v=0,w=0,k=0,_=0,S=0,x=0,C=0,E=0,P=0,T=null,A=0,O=new Gn.Buf16(16),N=new Gn.Buf16(16),R=null,M=0,b=0;b<=15;b++)O[b]=0;for(v=0;v<n;v++)O[t[r+v]]++;for(_=y,k=15;1<=k&&0===O[k];k--);if(k<_&&(_=k),0===k)a[i++]=20971520,a[i++]=20971520,s.bits=1;else{for(w=1;w<k&&0===O[w];w++);for(_<w&&(_=w),b=C=1;b<=15;b++)if((C=(C<<1)-O[b])<0)return-1;if(0<C&&(0===e||1!==k))return-1;for(N[1]=0,b=1;b<15;b++)N[b+1]=N[b]+O[b];for(v=0;v<n;v++)0!==t[r+v]&&(o[N[t[r+v]]++]=v);if(f=0===e?(T=R=o,19):1===e?(T=Kn,A-=257,R=Jn,M-=257,256):(T=Yn,R=$n,-1),b=w,d=i,x=v=P=0,u=-1,h=(E=1<<(S=_))-1,1===e&&852<E||2===e&&592<E)return 1;for(;;){for(g=o[v]<f?(m=0,o[v]):o[v]>f?(m=R[M+o[v]],T[A+o[v]]):(m=96,0),l=1<<(p=b-x),w=c=1<<S;a[d+(P>>x)+(c-=l)]=p<<24|m<<16|g|0,0!==c;);for(l=1<<b-1;P&l;)l>>=1;if(0!==l?P=(P&l-1)+l:P=0,v++,0==--O[b]){if(b===k)break;b=t[r+o[v]]}if(_<b&&(P&h)!==u){for(d+=w,C=1<<(S=b-(x=0===x?_:x));S+x<k&&!((C-=O[S+x])<=0);)S++,C<<=1;if(E+=1<<S,1===e&&852<E||2===e&&592<E)return 1;a[u=P&h]=_<<24|S<<16|d-i|0}}0!==P&&(a[d+P]=b-x<<24|64<<16|0),s.bits=_}return 0}var m={},w={},Gn=Er,Kn=[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],Jn=[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],Yn=[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],$n=[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],Qn=Er,ea=sn,ta=ln;function ra(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function na(){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 Qn.Buf16(320),this.work=new Qn.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function aa(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Qn.Buf32(852),t.distcode=t.distdyn=new Qn.Buf32(592),t.sane=1,t.back=-1,0):-2}function ia(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,aa(e)):-2}function oa(e,t){var r,n;return!e||!e.state||(n=e.state,t<0?(r=0,t=-t):(r=1+(t>>4),t<48&&(t&=15)),t&&(t<8||15<t))?-2:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,ia(e))}function sa(e,t){var r;return e?(r=new na,(e.state=r).window=null,0!==(r=oa(e,t))&&(e.state=null),r):-2}var la,ca,ua=!0;function ha(e,t,r,n){var a,e=e.state;return null===e.window&&(e.wsize=1<<e.wbits,e.wnext=0,e.whave=0,e.window=new Qn.Buf8(e.wsize)),e.wsize<=n?(Qn.arraySet(e.window,t,r-e.wsize,e.wsize,0),e.wnext=0,e.whave=e.wsize):((a=e.wsize-e.wnext)>n&&(a=n),Qn.arraySet(e.window,t,r-n,a,e.wnext),(n-=a)?(Qn.arraySet(e.window,t,r-n,n,0),e.wnext=n,e.whave=e.wsize):(e.wnext+=a,e.wnext===e.wsize&&(e.wnext=0),e.whave<e.wsize&&(e.whave+=a))),0}w.inflateReset=ia,w.inflateReset2=oa,w.inflateResetKeep=aa,w.inflateInit=function(e){return sa(e,15)},w.inflateInit2=sa,w.inflate=function(e,j){var t,r,I,n,a,i,o,s,l,L,c,u,z,F,h,d,f,p,U,W,m,g,y,b,v=0,w=new Qn.Buf8(4),H=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return-2;12===(t=e.state).mode&&(t.mode=13),a=e.next_out,I=e.output,n=e.next_in,r=e.input,s=t.hold,l=t.bits,L=i=e.avail_in,c=o=e.avail_out,g=0;e:for(;;)switch(t.mode){case 1:if(0===t.wrap)t.mode=13;else{for(;l<16;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(2&t.wrap&&35615===s)w[t.check=0]=255&s,w[1]=s>>>8&255,t.check=ta(t.check,w,2,0),l=s=0,t.mode=2;else if(t.flags=0,t.head&&(t.head.done=!1),!(1&t.wrap)||(((255&s)<<8)+(s>>8))%31)e.msg="incorrect header check",t.mode=30;else if(8!=(15&s))e.msg="unknown compression method",t.mode=30;else{if(l-=4,m=8+(15&(s>>>=4)),0===t.wbits)t.wbits=m;else if(m>t.wbits){e.msg="invalid window size",t.mode=30;break}t.dmax=1<<m,e.adler=t.check=1,t.mode=512&s?10:12,l=s=0}}break;case 2:for(;l<16;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(t.flags=s,8!=(255&t.flags)){e.msg="unknown compression method",t.mode=30;break}if(57344&t.flags){e.msg="unknown header flags set",t.mode=30;break}t.head&&(t.head.text=s>>8&1),512&t.flags&&(w[0]=255&s,w[1]=s>>>8&255,t.check=ta(t.check,w,2,0)),l=s=0,t.mode=3;case 3:for(;l<32;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.head&&(t.head.time=s),512&t.flags&&(w[0]=255&s,w[1]=s>>>8&255,w[2]=s>>>16&255,w[3]=s>>>24&255,t.check=ta(t.check,w,4,0)),l=s=0,t.mode=4;case 4:for(;l<16;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.head&&(t.head.xflags=255&s,t.head.os=s>>8),512&t.flags&&(w[0]=255&s,w[1]=s>>>8&255,t.check=ta(t.check,w,2,0)),l=s=0,t.mode=5;case 5:if(1024&t.flags){for(;l<16;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.length=s,t.head&&(t.head.extra_len=s),512&t.flags&&(w[0]=255&s,w[1]=s>>>8&255,t.check=ta(t.check,w,2,0)),l=s=0}else t.head&&(t.head.extra=null);t.mode=6;case 6:if(1024&t.flags&&((u=(u=t.length)>i?i:u)&&(t.head&&(m=t.head.extra_len-t.length,t.head.extra||(t.head.extra=new Array(t.head.extra_len)),Qn.arraySet(t.head.extra,r,n,u,m)),512&t.flags&&(t.check=ta(t.check,r,u,n)),i-=u,n+=u,t.length-=u),t.length))break e;t.length=0,t.mode=7;case 7:if(2048&t.flags){if(0===i)break e;for(u=0;m=r[n+u++],t.head&&m&&t.length<65536&&(t.head.name+=String.fromCharCode(m)),m&&u<i;);if(512&t.flags&&(t.check=ta(t.check,r,u,n)),i-=u,n+=u,m)break e}else t.head&&(t.head.name=null);t.length=0,t.mode=8;case 8:if(4096&t.flags){if(0===i)break e;for(u=0;m=r[n+u++],t.head&&m&&t.length<65536&&(t.head.comment+=String.fromCharCode(m)),m&&u<i;);if(512&t.flags&&(t.check=ta(t.check,r,u,n)),i-=u,n+=u,m)break e}else t.head&&(t.head.comment=null);t.mode=9;case 9:if(512&t.flags){for(;l<16;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(s!==(65535&t.check)){e.msg="header crc mismatch",t.mode=30;break}l=s=0}t.head&&(t.head.hcrc=t.flags>>9&1,t.head.done=!0),e.adler=t.check=0,t.mode=12;break;case 10:for(;l<32;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}e.adler=t.check=ra(s),l=s=0,t.mode=11;case 11:if(0===t.havedict)return e.next_out=a,e.avail_out=o,e.next_in=n,e.avail_in=i,t.hold=s,t.bits=l,2;e.adler=t.check=1,t.mode=12;case 12:if(5===j||6===j)break e;case 13:if(t.last)s>>>=7&l,l-=7&l,t.mode=27;else{for(;l<3;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}switch(t.last=1&s,--l,3&(s>>>=1)){case 0:t.mode=14;break;case 1:k=_=void 0;var k,_=t;if(ua){for(la=new Qn.Buf32(512),ca=new Qn.Buf32(32),k=0;k<144;)_.lens[k++]=8;for(;k<256;)_.lens[k++]=9;for(;k<280;)_.lens[k++]=7;for(;k<288;)_.lens[k++]=8;for(Xn(1,_.lens,0,288,la,0,_.work,{bits:9}),k=0;k<32;)_.lens[k++]=5;Xn(2,_.lens,0,32,ca,0,_.work,{bits:5}),ua=!1}if(_.lencode=la,_.lenbits=9,_.distcode=ca,_.distbits=5,t.mode=20,6!==j)break;s>>>=2,l-=2;break e;case 2:t.mode=17;break;case 3:e.msg="invalid block type",t.mode=30}s>>>=2,l-=2}break;case 14:for(s>>>=7&l,l-=7&l;l<32;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if((65535&s)!=(s>>>16^65535)){e.msg="invalid stored block lengths",t.mode=30;break}if(t.length=65535&s,l=s=0,t.mode=15,6===j)break e;case 15:t.mode=16;case 16:if(u=t.length){if(0===(u=o<(u=i<u?i:u)?o:u))break e;Qn.arraySet(I,r,n,u,a),i-=u,n+=u,o-=u,a+=u,t.length-=u}else t.mode=12;break;case 17:for(;l<14;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(t.nlen=257+(31&s),s>>>=5,l-=5,t.ndist=1+(31&s),s>>>=5,l-=5,t.ncode=4+(15&s),s>>>=4,l-=4,286<t.nlen||30<t.ndist){e.msg="too many length or distance symbols",t.mode=30;break}t.have=0,t.mode=18;case 18:for(;t.have<t.ncode;){for(;l<3;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.lens[H[t.have++]]=7&s,s>>>=3,l-=3}for(;t.have<19;)t.lens[H[t.have++]]=0;if(t.lencode=t.lendyn,t.lenbits=7,y={bits:t.lenbits},g=Xn(0,t.lens,0,19,t.lencode,0,t.work,y),t.lenbits=y.bits,g){e.msg="invalid code lengths set",t.mode=30;break}t.have=0,t.mode=19;case 19:for(;t.have<t.nlen+t.ndist;){for(;d=(v=t.lencode[s&(1<<t.lenbits)-1])>>>16&255,f=65535&v,!((h=v>>>24)<=l);){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(f<16)s>>>=h,l-=h,t.lens[t.have++]=f;else{if(16===f){for(b=h+2;l<b;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(s>>>=h,l-=h,0===t.have){e.msg="invalid bit length repeat",t.mode=30;break}m=t.lens[t.have-1],u=3+(3&s),s>>>=2,l-=2}else if(17===f){for(b=h+3;l<b;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}m=0,u=3+(7&(s>>>=h)),s>>>=3,l=l-h-3}else{for(b=h+7;l<b;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}m=0,u=11+(127&(s>>>=h)),s>>>=7,l=l-h-7}if(t.have+u>t.nlen+t.ndist){e.msg="invalid bit length repeat",t.mode=30;break}for(;u--;)t.lens[t.have++]=m}}if(30===t.mode)break;if(0===t.lens[256]){e.msg="invalid code -- missing end-of-block",t.mode=30;break}if(t.lenbits=9,y={bits:t.lenbits},g=Xn(1,t.lens,0,t.nlen,t.lencode,0,t.work,y),t.lenbits=y.bits,g){e.msg="invalid literal/lengths set",t.mode=30;break}if(t.distbits=6,t.distcode=t.distdyn,y={bits:t.distbits},g=Xn(2,t.lens,t.nlen,t.ndist,t.distcode,0,t.work,y),t.distbits=y.bits,g){e.msg="invalid distances set",t.mode=30;break}if(t.mode=20,6===j)break e;case 20:t.mode=21;case 21:if(6<=i&&258<=o){e.next_out=a,e.avail_out=o,e.next_in=n,e.avail_in=i,t.hold=s,t.bits=l,M=q=T=P=E=C=x=S=ne=re=te=ee=D=B=Q=$=Y=J=K=G=X=R=V=N=O=Z=A=void 0;var S,x,C,E,P,T,A=e,Z=c,O=A.state,N=A.next_in,q=A.input,V=N+(A.avail_in-5),R=A.next_out,M=A.output,X=R-(Z-A.avail_out),G=R+(A.avail_out-257),K=O.dmax,J=O.wsize,Y=O.whave,$=O.wnext,Q=O.window,B=O.hold,D=O.bits,ee=O.lencode,te=O.distcode,re=(1<<O.lenbits)-1,ne=(1<<O.distbits)-1;t:do{for(D<15&&(B+=q[N++]<<D,D+=8,B+=q[N++]<<D,D+=8),S=ee[B&re];;){if(B>>>=x=S>>>24,D-=x,0==(x=S>>>16&255))M[R++]=65535&S;else{if(!(16&x)){if(0==(64&x)){S=ee[(65535&S)+(B&(1<<x)-1)];continue}if(32&x){O.mode=12;break t}A.msg="invalid literal/length code",O.mode=30;break t}for(C=65535&S,(x&=15)&&(D<x&&(B+=q[N++]<<D,D+=8),C+=B&(1<<x)-1,B>>>=x,D-=x),D<15&&(B+=q[N++]<<D,D+=8,B+=q[N++]<<D,D+=8),S=te[B&ne];;){if(B>>>=x=S>>>24,D-=x,!(16&(x=S>>>16&255))){if(0==(64&x)){S=te[(65535&S)+(B&(1<<x)-1)];continue}A.msg="invalid distance code",O.mode=30;break t}if(E=65535&S,D<(x&=15)&&(B+=q[N++]<<D,(D+=8)<x)&&(B+=q[N++]<<D,D+=8),(E+=B&(1<<x)-1)>K){A.msg="invalid distance too far back",O.mode=30;break t}if(B>>>=x,D-=x,E>(x=R-X)){if((x=E-x)>Y&&O.sane){A.msg="invalid distance too far back",O.mode=30;break t}if(T=Q,(P=0)===$){if(P+=J-x,x<C){for(C-=x;M[R++]=Q[P++],--x;);P=R-E,T=M}}else if($<x){if(P+=J+$-x,(x-=$)<C){for(C-=x;M[R++]=Q[P++],--x;);if(P=0,$<C){for(C-=x=$;M[R++]=Q[P++],--x;);P=R-E,T=M}}}else if(P+=$-x,x<C){for(C-=x;M[R++]=Q[P++],--x;);P=R-E,T=M}for(;2<C;)M[R++]=T[P++],M[R++]=T[P++],M[R++]=T[P++],C-=3;C&&(M[R++]=T[P++],1<C)&&(M[R++]=T[P++])}else{for(P=R-E;M[R++]=M[P++],M[R++]=M[P++],M[R++]=M[P++],2<(C-=3););C&&(M[R++]=M[P++],1<C)&&(M[R++]=M[P++])}break}}break}}while(N<V&&R<G);N-=C=D>>3,B&=(1<<(D-=C<<3))-1,A.next_in=N,A.next_out=R,A.avail_in=N<V?V-N+5:5-(N-V),A.avail_out=R<G?G-R+257:257-(R-G),O.hold=B,O.bits=D,a=e.next_out,I=e.output,o=e.avail_out,n=e.next_in,r=e.input,i=e.avail_in,s=t.hold,l=t.bits,12===t.mode&&(t.back=-1);break}for(t.back=0;d=(v=t.lencode[s&(1<<t.lenbits)-1])>>>16&255,f=65535&v,!((h=v>>>24)<=l);){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(d&&0==(240&d)){for(p=h,U=d,W=f;d=(v=t.lencode[W+((s&(1<<p+U)-1)>>p)])>>>16&255,f=65535&v,!(p+(h=v>>>24)<=l);){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}s>>>=p,l-=p,t.back+=p}if(s>>>=h,l-=h,t.back+=h,t.length=f,0===d){t.mode=26;break}if(32&d){t.back=-1,t.mode=12;break}if(64&d){e.msg="invalid literal/length code",t.mode=30;break}t.extra=15&d,t.mode=22;case 22:if(t.extra){for(b=t.extra;l<b;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.length+=s&(1<<t.extra)-1,s>>>=t.extra,l-=t.extra,t.back+=t.extra}t.was=t.length,t.mode=23;case 23:for(;d=(v=t.distcode[s&(1<<t.distbits)-1])>>>16&255,f=65535&v,!((h=v>>>24)<=l);){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(0==(240&d)){for(p=h,U=d,W=f;d=(v=t.distcode[W+((s&(1<<p+U)-1)>>p)])>>>16&255,f=65535&v,!(p+(h=v>>>24)<=l);){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}s>>>=p,l-=p,t.back+=p}if(s>>>=h,l-=h,t.back+=h,64&d){e.msg="invalid distance code",t.mode=30;break}t.offset=f,t.extra=15&d,t.mode=24;case 24:if(t.extra){for(b=t.extra;l<b;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}t.offset+=s&(1<<t.extra)-1,s>>>=t.extra,l-=t.extra,t.back+=t.extra}if(t.offset>t.dmax){e.msg="invalid distance too far back",t.mode=30;break}t.mode=25;case 25:if(0===o)break e;if(t.offset>(u=c-o)){if((u=t.offset-u)>t.whave&&t.sane){e.msg="invalid distance too far back",t.mode=30;break}z=u>t.wnext?(u-=t.wnext,t.wsize-u):t.wnext-u,u>t.length&&(u=t.length),F=t.window}else F=I,z=a-t.offset,u=t.length;for(o-=u=o<u?o:u,t.length-=u;I[a++]=F[z++],--u;);0===t.length&&(t.mode=21);break;case 26:if(0===o)break e;I[a++]=t.length,o--,t.mode=21;break;case 27:if(t.wrap){for(;l<32;){if(0===i)break e;i--,s|=r[n++]<<l,l+=8}if(c-=o,e.total_out+=c,t.total+=c,c&&(e.adler=t.check=(t.flags?ta:ea)(t.check,I,c,a-c)),c=o,(t.flags?s:ra(s))!==t.check){e.msg="incorrect data check",t.mode=30;break}l=s=0}t.mode=28;case 28:if(t.wrap&&t.flags){for(;l<32;){if(0===i)break e;i--,s+=r[n++]<<l,l+=8}if(s!==(4294967295&t.total)){e.msg="incorrect length check",t.mode=30;break}l=s=0}t.mode=29;case 29:g=1;break e;case 30:g=-3;break e;case 31:return-4;default:return-2}return e.next_out=a,e.avail_out=o,e.next_in=n,e.avail_in=i,t.hold=s,t.bits=l,(t.wsize||c!==e.avail_out&&t.mode<30&&(t.mode<27||4!==j))&&ha(e,e.output,e.next_out,c-e.avail_out),c-=e.avail_out,e.total_in+=L-=e.avail_in,e.total_out+=c,t.total+=c,t.wrap&&c&&(e.adler=t.check=(t.flags?ta:ea)(t.check,I,c,e.next_out-c)),e.data_type=t.bits+(t.last?64:0)+(12===t.mode?128:0)+(20===t.mode||15===t.mode?256:0),g=(0==L&&0===c||4===j)&&0===g?-5:g},w.inflateEnd=function(e){var t;return e&&e.state?((t=e.state).window&&(t.window=null),e.state=null,0):-2},w.inflateGetHeader=function(e,t){return!e||!e.state||0==(2&(e=e.state).wrap)?-2:((e.head=t).done=!1,0)},w.inflateSetDictionary=function(e,t){var r,n=t.length;return!e||!e.state||0!==(r=e.state).wrap&&11!==r.mode?-2:11===r.mode&&ea(1,t,n,0)!==r.check?-3:ha(e,t,n,n)?(r.mode=31,-4):(r.havedict=1,0)},w.inflateInfo="pako inflate (from Nodeca project)";function da(){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}var fa={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},pa=w,ma=Er,ga=g,k=fa,ya=hn,ba=Ln,va=Object.prototype.toString;function wa(e){if(!(this instanceof wa))return new wa(e);this.options=ma.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options,e=(t.raw&&0<=t.windowBits&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits)&&(t.windowBits=-15),!(0<=t.windowBits&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),15<t.windowBits&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ba,this.strm.avail_out=0,pa.inflateInit2(this.strm,t.windowBits));if(e!==k.Z_OK)throw new Error(ya[e]);if(this.header=new da,pa.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=ga.string2buf(t.dictionary):"[object ArrayBuffer]"===va.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw)&&(e=pa.inflateSetDictionary(this.strm,t.dictionary))!==k.Z_OK)throw new Error(ya[e])}function ka(e,t){t=new wa(t);if(t.push(e,!0),t.err)throw t.msg||ya[t.err];return t.result}wa.prototype.push=function(e,t){var r,n,a,i,o,s=this.strm,l=this.options.chunkSize,c=this.options.dictionary,u=!1;if(this.ended)return!1;n=t===~~t?t:!0===t?k.Z_FINISH:k.Z_NO_FLUSH,"string"==typeof e?s.input=ga.binstring2buf(e):"[object ArrayBuffer]"===va.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;do{if(0===s.avail_out&&(s.output=new ma.Buf8(l),s.next_out=0,s.avail_out=l),(r=(r=pa.inflate(s,k.Z_NO_FLUSH))===k.Z_NEED_DICT&&c?pa.inflateSetDictionary(this.strm,c):r)===k.Z_BUF_ERROR&&!0===u&&(r=k.Z_OK,u=!1),r!==k.Z_STREAM_END&&r!==k.Z_OK)return this.onEnd(r),!(this.ended=!0)}while(!s.next_out||0!==s.avail_out&&r!==k.Z_STREAM_END&&(0!==s.avail_in||n!==k.Z_FINISH&&n!==k.Z_SYNC_FLUSH)||("string"===this.options.to?(a=ga.utf8border(s.output,s.next_out),i=s.next_out-a,o=ga.buf2string(s.output,a),s.next_out=i,s.avail_out=l-i,i&&ma.arraySet(s.output,s.output,a,i,0),this.onData(o)):this.onData(ma.shrinkBuf(s.output,s.next_out))),0===s.avail_in&&0===s.avail_out&&(u=!0),(0<s.avail_in||0===s.avail_out)&&r!==k.Z_STREAM_END);return(n=r===k.Z_STREAM_END?k.Z_FINISH:n)===k.Z_FINISH?(r=pa.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===k.Z_OK):n!==k.Z_SYNC_FLUSH||(this.onEnd(k.Z_OK),!(s.avail_out=0))},wa.prototype.onData=function(e){this.chunks.push(e)},wa.prototype.onEnd=function(e){e===k.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=ma.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},m.Inflate=wa,m.inflate=ka,m.inflateRaw=function(e,t){return(t=t||{}).raw=!0,ka(e,t)},m.ungzip=ka;var w={},g=((0,Er.assign)(w,p,m,fa),"undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array),_a=w,Sa=s(),xa=c,Ca=g?"uint8array":"array";function Ea(e,t){xa.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}Cr.magic="\b\0",Sa.inherits(Ea,xa),Ea.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push(Sa.transformTo(Ca,e.data),!1)},Ea.prototype.flush=function(){xa.prototype.flush.call(this),null===this._pako&&this._createPako(),this._pako.push([],!0)},Ea.prototype.cleanUp=function(){xa.prototype.cleanUp.call(this),this._pako=null},Ea.prototype._createPako=function(){this._pako=new _a[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var t=this;this._pako.onData=function(e){t.push({data:e,meta:t.meta})}},Cr.compressWorker=function(e){return new Ea("Deflate",e)},Cr.uncompressWorker=function(){return new Ea("Inflate",{})};function _(e,t){for(var r="",n=0;n<t;n++)r+=String.fromCharCode(255&e),e>>>=8;return r}function Pa(e,t,r,n,a,i){var o=e.file,s=e.compression,l=i!==Na.utf8encode,c=Aa.transformTo("string",i(o.name)),u=Aa.transformTo("string",Na.utf8encode(o.name)),h=o.comment,i=Aa.transformTo("string",i(h)),d=Aa.transformTo("string",Na.utf8encode(h)),f=u.length!==o.name.length,h=d.length!==h.length,p="",m=o.dir,g=o.date,y={crc32:0,compressedSize:0,uncompressedSize:0},r=(t&&!r||(y.crc32=e.crc32,y.compressedSize=e.compressedSize,y.uncompressedSize=e.uncompressedSize),0);return t&&(r|=8),l||!f&&!h||(r|=2048),t=e=0,m&&(e|=16),"UNIX"===a?(t=798,e|=(65535&((l=o.unixPermissions)?l:m?16893:33204))<<16):(t=20,e|=63&(o.dosPermissions||0)),a=g.getUTCHours(),a=(a=((a<<=6)|g.getUTCMinutes())<<5)|g.getUTCSeconds()/2,l=g.getUTCFullYear()-1980,l=(l=((l<<=4)|g.getUTCMonth()+1)<<5)|g.getUTCDate(),f&&(m=_(1,1)+_(Ra(c),4)+u,p+="up"+_(m.length,2)+m),h&&(o=_(1,1)+_(Ra(i),4)+d,p+="uc"+_(o.length,2)+o),g="",g=(g=(g=(g=(g=(g=(g=(g=(g=(g+="\n\0")+_(r,2))+s.magic)+_(a,2))+_(l,2))+_(y.crc32,4))+_(y.compressedSize,4))+_(y.uncompressedSize,4))+_(c.length,2))+_(p.length,2),{fileRecord:Ma.LOCAL_FILE_HEADER+g+c+p,dirRecord:Ma.CENTRAL_FILE_HEADER+_(t,2)+g+_(i.length,2)+"\0\0\0\0"+_(e,4)+_(n,4)+c+p+i}}var Ta=c,hn=(xr.STORE={magic:"\0\0",compressWorker:function(){return new Ta("STORE compression")},uncompressWorker:function(){return new Ta("STORE decompression")}},xr.DEFLATE=Cr,{LOCAL_FILE_HEADER:"PK",CENTRAL_FILE_HEADER:"PK",CENTRAL_DIRECTORY_END:"PK",ZIP64_CENTRAL_DIRECTORY_LOCATOR:"PK",ZIP64_CENTRAL_DIRECTORY_END:"PK",DATA_DESCRIPTOR:"PK\b"}),Aa=s(),Oa=c,Na=L,Ra=$t,Ma=hn;function Ba(e,t,r,n){Oa.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=r,this.encodeFileName=n,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}Aa.inherits(Ba,Oa),Ba.prototype.push=function(e){var t=e.meta.percent||0,r=this.entriesCount,n=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,Oa.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:r?(t+100*(r-n-1))/r:100}}))},Ba.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;t?(e=Pa(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName),this.push({data:e.fileRecord,meta:{percent:0}})):this.accumulate=!0},Ba.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,r=Pa(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(r.dirRecord),t)this.push({data:Ma.DATA_DESCRIPTOR+_((t=e).crc32,4)+_(t.compressedSize,4)+_(t.uncompressedSize,4),meta:{percent:100}});else for(this.push({data:r.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},Ba.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var r=this.bytesWritten-e,r=((e,t,r,n,a)=>(a=Aa.transformTo("string",a(n)),Ma.CENTRAL_DIRECTORY_END+"\0\0\0\0"+_(e,2)+_(e,2)+_(t,4)+_(r,4)+_(a.length,2)+a))(this.dirRecords.length,r,e,this.zipComment,this.encodeFileName);this.push({data:r,meta:{percent:100}})},Ba.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},Ba.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",function(e){t.processChunk(e)}),e.on("end",function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()}),e.on("error",function(e){t.error(e)}),this},Ba.prototype.resume=function(){return!!Oa.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},Ba.prototype.error=function(e){var t=this._sources;if(!Oa.prototype.error.call(this,e))return!1;for(var r=0;r<t.length;r++)try{t[r].error(e)}catch(e){}return!0},Ba.prototype.lock=function(){Oa.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()};var Da=xr,ja=Ba,Er=(d.generateWorker=function(e,o,t){var s=new ja(o.streamFiles,t,o.platform,o.encodeFileName),l=0;try{e.forEach(function(e,t){l++;var r=((e,t)=>{if(t=Da[e=e||t])return t;throw new Error(e+" is not a valid compression method !")})(t.options.compression,o.compression),n=t.options.compressionOptions||o.compressionOptions||{},a=t.dir,i=t.date;t._compressWorker(r,n).withStreamInfo("file",{name:e,dir:a,date:i,comment:t.comment||"",unixPermissions:t.unixPermissions,dosPermissions:t.dosPermissions}).pipe(s)}),s.entriesCount=l}catch(e){s.error(e)}return s},s()),Ia=c;function La(e,t){Ia.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}Er.inherits(La,Ia),La.prototype._bindStream=function(e){var t=this;(this._stream=e).pause(),e.on("data",function(e){t.push({data:e,meta:{percent:0}})}).on("error",function(e){t.isPaused?this.generatedError=e:t.error(e)}).on("end",function(){t.isPaused?t._upstreamEnded=!0:t.end()})},La.prototype.pause=function(){return!!Ia.prototype.pause.call(this)&&(this._stream.pause(),!0)},La.prototype.resume=function(){return!!Ia.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)};function za(e){var t=(e="/"===e.slice(-1)?e.substring(0,e.length-1):e).lastIndexOf("/");return 0<t?e.substring(0,t):""}function Fa(e,t){return t=void 0!==t?t:qa.createFolders,e=$a(e),this.files[e]||Ya.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]}var p=La,Ua=L,Wa=s(),Ha=c,Za=e,qa=Gt,Va=ir,Xa=u,Ga=d,Ka=mt,Ja=p,Ya=function(e,t,r){var n=Wa.getTypeOf(t),a=Wa.extend(r||{},qa),i=(a.date=a.date||new Date,null!==a.compression&&(a.compression=a.compression.toUpperCase()),"string"==typeof a.unixPermissions&&(a.unixPermissions=parseInt(a.unixPermissions,8)),a.unixPermissions&&16384&a.unixPermissions&&(a.dir=!0),a.dosPermissions&&16&a.dosPermissions&&(a.dir=!0),a.dir&&(e=$a(e)),a.createFolders&&(i=za(e))&&Fa.call(this,i,!0),"string"===n&&!1===a.binary&&!1===a.base64),r=(r&&void 0!==r.binary||(a.binary=!i),(t instanceof Va&&0===t.uncompressedSize||a.dir||!t||0===t.length)&&(a.base64=!1,a.binary=!0,t="",a.compression="STORE"),n=t instanceof Va||t instanceof Ha?t:Ka.isNode&&Ka.isStream(t)?new Ja(e,t):Wa.prepareContent(e,t,a.binary,a.optimizedBinaryString,a.base64),new Xa(e,n,a));this.files[e]=r},$a=function(e){return"/"!==e.slice(-1)&&(e+="/"),e};function Qa(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var m={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(e){var t,r,n;for(t in this.files)n=this.files[t],(r=t.slice(this.root.length,t.length))&&t.slice(0,this.root.length)===this.root&&e(r,n)},filter:function(r){var n=[];return this.forEach(function(e,t){r(e,t)&&n.push(t)}),n},file:function(e,t,r){var n,a;return 1===arguments.length?Qa(e)?(n=e,this.filter(function(e,t){return!t.dir&&n.test(e)})):(a=this.files[this.root+e])&&!a.dir?a:null:(e=this.root+e,Ya.call(this,e,t,r),this)},folder:function(r){var e,t;return r?Qa(r)?this.filter(function(e,t){return t.dir&&r.test(e)}):(e=this.root+r,e=Fa.call(this,e),(t=this.clone()).root=e.name,t):this},remove:function(r){r=this.root+r;var e=this.files[r];if(e||("/"!==r.slice(-1)&&(r+="/"),e=this.files[r]),e&&!e.dir)delete this.files[r];else for(var t=this.filter(function(e,t){return t.name.slice(0,r.length)===r}),n=0;n<t.length;n++)delete this.files[t[n].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(e){var t={};try{if((t=Wa.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:Ua.utf8encode})).type=t.type.toLowerCase(),t.compression=t.compression.toUpperCase(),"binarystring"===t.type&&(t.type="string"),!t.type)throw new Error("No output type specified.");Wa.checkSupport(t.type),"darwin"!==t.platform&&"freebsd"!==t.platform&&"linux"!==t.platform&&"sunos"!==t.platform||(t.platform="UNIX"),"win32"===t.platform&&(t.platform="DOS");var r=t.comment||this.comment||"",n=Ga.generateWorker(this,t,r)}catch(e){(n=new Ha("error")).error(e)}return new Za(n,t.type||"string",t.mimeType)},generateAsync:function(e,t){return this.generateInternalStream(e).accumulate(t)},generateNodeStream:function(e,t){return(e=e||{}).type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)}},ei=s();function ti(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}ti.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 t,r=0;for(this.checkOffset(e),t=this.index+e-1;t>=this.index;t--)r=(r<<8)+this.byteAt(t);return this.index+=e,r},readString:function(e){return ei.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))}};var fa=ti,ri=fa;function ni(e){ri.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=255&e[t]}s().inherits(ni,ri),ni.prototype.byteAt=function(e){return this.data[this.zero+e]},ni.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),a=e.charCodeAt(3),i=this.length-4;0<=i;--i)if(this.data[i]===t&&this.data[i+1]===r&&this.data[i+2]===n&&this.data[i+3]===a)return i-this.zero;return-1},ni.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),e=e.charCodeAt(3),a=this.readData(4);return t===a[0]&&r===a[1]&&n===a[2]&&e===a[3]},ni.prototype.readData=function(e){var t;return this.checkOffset(e),0===e?[]:(t=this.data.slice(this.zero+this.index,this.zero+this.index+e),this.index+=e,t)};var w=ni,ai=fa;function ii(e){ai.call(this,e)}s().inherits(ii,ai),ii.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},ii.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},ii.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},ii.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};var g=ii,oi=w;function si(e){oi.call(this,e)}s().inherits(si,oi),si.prototype.readData=function(e){var t;return this.checkOffset(e),0===e?new Uint8Array(0):(t=this.data.subarray(this.zero+this.index,this.zero+this.index+e),this.index+=e,t)};var Cr=si,li=Cr;function ci(e){li.call(this,e)}s().inherits(ci,li),ci.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};function ui(e){var t=hi.getTypeOf(e);return hi.checkSupport(t),"string"!==t||di.uint8array?"nodebuffer"===t?new mi(e):di.uint8array?new gi(hi.transformTo("uint8array",e)):new fi(hi.transformTo("array",e)):new pi(e)}var Er=ci,hi=s(),di=f,fi=w,pi=g,mi=Er,gi=Cr,yi=ui,bi=s(),vi=ir,wi=$t,ki=L,_i=xr,Si=f;function xi(e,t){this.options=e,this.loadOptions=t}xi.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},readLocalPart:function(e){var t;if(e.skip(22),this.fileNameLength=e.readInt(2),t=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(t),-1===this.compressedSize||-1===this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(null===(t=(e=>{for(var t in _i)if(Object.prototype.hasOwnProperty.call(_i,t)&&_i[t].magic===e)return _i[t];return null})(this.compressionMethod)))throw new Error("Corrupted zip : compression "+bi.pretty(this.compressionMethod)+" unknown (inner file : "+bi.transformTo("string",this.fileName)+")");this.decompressed=new vi(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},readCentralPart:function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0==e&&(this.dosPermissions=63&this.externalFileAttributes),3==e&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(){var e;this.extraFields[1]&&(e=yi(this.extraFields[1].value),this.uncompressedSize===bi.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===bi.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===bi.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===bi.MAX_VALUE_32BITS)&&(this.diskNumberStart=e.readInt(4))},readExtraFields:function(e){var t,r,n,a=e.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});e.index+4<a;)t=e.readInt(2),r=e.readInt(2),n=e.readData(r),this.extraFields[t]={id:t,length:r,value:n};e.setIndex(a)},handleUTF8:function(){var e,t=Si.uint8array?"uint8array":"array";this.useUTF8()?(this.fileNameStr=ki.utf8decode(this.fileName),this.fileCommentStr=ki.utf8decode(this.fileComment)):(null!==(e=this.findExtraFieldUnicodePath())?this.fileNameStr=e:(e=bi.transformTo(t,this.fileName),this.fileNameStr=this.loadOptions.decodeFileName(e)),null!==(e=this.findExtraFieldUnicodeComment())?this.fileCommentStr=e:(e=bi.transformTo(t,this.fileComment),this.fileCommentStr=this.loadOptions.decodeFileName(e)))},findExtraFieldUnicodePath:function(){var e,t=this.extraFields[28789];return!t||1!==(e=yi(t.value)).readInt(1)||wi(this.fileName)!==e.readInt(4)?null:ki.utf8decode(e.readData(t.length-5))},findExtraFieldUnicodeComment:function(){var e,t=this.extraFields[25461];return!t||1!==(e=yi(t.value)).readInt(1)||wi(this.fileComment)!==e.readInt(4)?null:ki.utf8decode(e.readData(t.length-5))}};var c=xi,Ci=ui,Ei=s(),Pi=hn,Ti=c,Ai=f;function Oi(e){this.files=[],this.loadOptions=e}Oi.prototype={checkSignature:function(e){var t;if(!this.reader.readAndCheckSignature(e))throw this.reader.index-=4,t=this.reader.readString(4),new Error("Corrupted zip or bug: unexpected signature ("+Ei.pretty(t)+", expected "+Ei.pretty(e)+")")},isSignature:function(e,t){var r=this.reader.index,e=(this.reader.setIndex(e),this.reader.readString(4)===t);return this.reader.setIndex(r),e},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 e=this.reader.readData(this.zipCommentLength),t=Ai.uint8array?"uint8array":"array",t=Ei.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(t)},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 e,t,r,n=this.zip64EndOfCentralSize-44;0<n;)e=this.reader.readInt(2),t=this.reader.readInt(4),r=this.reader.readData(t),this.zip64ExtensibleData[e]={id:e,length:t,value:r}},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(){for(var e,t=0;t<this.files.length;t++)e=this.files[t],this.reader.setIndex(e.localHeaderOffset),this.checkSignature(Pi.LOCAL_FILE_HEADER),e.readLocalPart(this.reader),e.handleUTF8(),e.processAttributes()},readCentralDir:function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(Pi.CENTRAL_FILE_HEADER);)(e=new Ti({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var e=this.reader.lastIndexOfSignature(Pi.CENTRAL_DIRECTORY_END);if(e<0)throw this.isSignature(0,Pi.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(e);var t=e;if(this.checkSignature(Pi.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===Ei.MAX_VALUE_16BITS||this.diskWithCentralDirStart===Ei.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===Ei.MAX_VALUE_16BITS||this.centralDirRecords===Ei.MAX_VALUE_16BITS||this.centralDirSize===Ei.MAX_VALUE_32BITS||this.centralDirOffset===Ei.MAX_VALUE_32BITS){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(Pi.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(Pi.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,Pi.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(Pi.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(Pi.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}e=this.centralDirOffset+this.centralDirSize,e=t-(e=this.zip64?e+20+(12+this.zip64EndOfCentralSize):e);if(0<e)this.isSignature(t,Pi.CENTRAL_FILE_HEADER)||(this.reader.zero=e);else if(e<0)throw new Error("Corrupted zip: missing "+Math.abs(e)+" bytes.")},prepareReader:function(e){this.reader=Ci(e)},load:function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}};var e=Oi,Ni=s(),Ri=gt,Mi=L,Bi=e,Di=ar,ji=mt;function Ii(){if(!(this instanceof Ii))return new Ii;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 e,t=new Ii;for(e in this)"function"!=typeof this[e]&&(t[e]=this[e]);return t}}(Ii.prototype=m).loadAsync=function(e,o){var s=this;return o=Ni.extend(o||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:Mi.utf8decode}),ji.isNode&&ji.isStream(e)?Ri.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):Ni.prepareContent("the loaded zip file",e,!0,o.optimizedBinaryString,o.base64).then(function(e){var t=new Bi(o);return t.load(e),t}).then(function(e){var t=[Ri.Promise.resolve(e)],r=e.files;if(o.checkCRC32)for(var n=0;n<r.length;n++)t.push((n=>new Ri.Promise(function(e,t){var r=n.decompressed.getContentWorker().pipe(new Di);r.on("error",function(e){t(e)}).on("end",function(){r.streamInfo.crc32!==n.decompressed.crc32?t(new Error("Corrupted zip : CRC32 mismatch")):e()}).resume()}))(r[n]));return Ri.Promise.all(t)}).then(function(e){for(var e=e.shift(),t=e.files,r=0;r<t.length;r++){var n=t[r],a=n.fileNameStr,i=Ni.resolve(n.fileNameStr);s.file(i,n.decompressed,{binary:!0,optimizedBinaryString:!0,date:n.date,dir:n.dir,comment:n.fileCommentStr.length?n.fileCommentStr:null,unixPermissions:n.unixPermissions,dosPermissions:n.dosPermissions,createFolders:o.createFolders}),n.dir||(s.file(i).unsafeOriginalName=a)}return e.zipComment.length&&(s.comment=e.zipComment),s})},Ii.support=f,Ii.defaults=Gt,Ii.version="3.10.1",Ii.loadAsync=function(e,t){return(new Ii).loadAsync(e,t)},Ii.external=gt;var C,Li,zi=(Li=Ii).__esModule&&Object.prototype.hasOwnProperty.call(Li,"default")?Li.default:Li,Fi=((u=C=C||{}).OfficeDocument="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",u.FontTable="http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",u.Image="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",u.Numbering="http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering",u.Styles="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",u.StylesWithEffects="http://schemas.microsoft.com/office/2007/relationships/stylesWithEffects",u.Theme="http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",u.Settings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings",u.WebSettings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings",u.Hyperlink="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",u.Footnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes",u.Endnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/endnotes",u.Footer="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer",u.Header="http://schemas.openxmlformats.org/officeDocument/2006/relationships/header",u.ExtendedProperties="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",u.CoreProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",u.CustomProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/custom-properties",u.Comments="http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",u.CommentsExtended="http://schemas.microsoft.com/office/2011/relationships/commentsExtended","http://schemas.openxmlformats.org/wordprocessingml/2006/main"),E={Dxa:{mul:.05,unit:"pt"},Emu:{mul:1/12700,unit:"pt"},FontSize:{mul:.5,unit:"pt"},Border:{mul:.125,unit:"pt"},Point:{mul:1,unit:"pt"},Percent:{mul:.02,unit:"%"},LineHeight:{mul:1/240,unit:""},VmlEmu:{mul:1/12700,unit:""}};function Ui(e,t){t=1<arguments.length&&void 0!==t?t:E.Dxa;return null==e||/.+(p[xt]|[%])$/.test(e)?e:"".concat((parseInt(e)*t.mul).toFixed(2)).concat(t.unit)}function Wi(e,t,r){if(e.namespaceURI==Fi){switch(e.localName){case"color":t.color=r.attr(e,"val");break;case"sz":t.fontSize=r.lengthAttr(e,"val",E.FontSize);break;default:return}return 1}}a(Xi,[{key:"elements",value:function(e){for(var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,r=[],n=0,a=e.childNodes.length;n<a;n++){var i=e.childNodes.item(n);1!=i.nodeType||null!=t&&i.localName!=t||r.push(i)}return r}},{key:"element",value:function(e,t){for(var r=0,n=e.childNodes.length;r<n;r++){var a=e.childNodes.item(r);if(1==a.nodeType&&a.localName==t)return a}return null}},{key:"elementAttr",value:function(e,t,r){e=this.element(e,t);return e?this.attr(e,r):void 0}},{key:"attrs",value:function(e){return Array.from(e.attributes)}},{key:"attr",value:function(e,t){for(var r=0,n=e.attributes.length;r<n;r++){var a=e.attributes.item(r);if(a.localName==t)return a.value}return null}},{key:"intAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,e=this.attr(e,t);return e?parseInt(e):r}},{key:"hexAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,e=this.attr(e,t);return e?parseInt(e,16):r}},{key:"floatAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,e=this.attr(e,t);return e?parseFloat(e):r}},{key:"boolAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return function(e,t){var r=1<arguments.length&&void 0!==t&&t;switch(e){case"1":case"on":case"true":return!0;case"0":case"off":case"false":return!1;default:return r}}(this.attr(e,t),r)}},{key:"lengthAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:E.Dxa;return Ui(this.attr(e,t),r)}}]);var Hi,Zi=Xi,T=new Zi,d=(a(Vi,[{key:"load",value:(Hi=$(P().mark(function e(){var t;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._package.loadRelationships(this.path);case 2:return this.rels=e.sent,e.next=5,this._package.load(this.path);case 5:t=e.sent,t=this._package.parseXmlDocument(t),this._package.options.keepOrigin&&(this._xmlDocument=t),this.parseXml(t.firstElementChild);case 8:case"end":return e.stop()}},e,this)})),function(){return Hi.apply(this,arguments)})},{key:"save",value:function(){var e;this._package.update(this.path,(e=this._xmlDocument,(new XMLSerializer).serializeToString(e)))}},{key:"parseXml",value:function(e){}}]),Vi),qi={embedRegular:"regular",embedBold:"bold",embedItalic:"italic",embedBoldItalic:"boldItalic"};function Vi(e,t){n(this,Vi),this._package=e,this.path=t}function Xi(){n(this,Xi)}t(Ji,d),Gi=r(Ji),a(Ji,[{key:"parseXml",value:function(e){var c;this.fonts=(c=this._package.xmlParser).elements(e).map(function(e){var t,r,n,a=e,i=c,o={name:i.attr(a,"name"),embedFontRefs:[]},s=x(i.elements(a));try{for(s.s();!(t=s.n()).done;){var l=t.value;switch(l.localName){case"family":o.family=i.attr(l,"val");break;case"altName":o.altName=i.attr(l,"val");break;case"embedRegular":case"embedBold":case"embedItalic":case"embedBoldItalic":o.embedFontRefs.push((r=l,{id:(n=i).attr(r,"id"),key:n.attr(r,"fontKey"),type:qi[r.localName]}))}}}catch(a){s.e(a)}finally{s.f()}return o})}}]);var Gi,Ki=Ji;function Ji(){return n(this,Ji),Gi.apply(this,arguments)}function Yi(e){var t=e.lastIndexOf("/")+1;return[0==t?"":e.substring(0,t),0==t?e:e.substring(t)]}function $i(e,t){try{var r="http://docx/";return new URL(e,r+t).toString().substring(r.length)}catch(r){return"".concat(t).concat(e)}}function Qi(e,r){return e.reduce(function(e,t){return e[r(t)]=t,e},{})}function eo(e){return e&&"object"==te(e)&&!Array.isArray(e)}function to(e){for(var t=arguments.length,r=new Array(1<t?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(!r.length)return e;var a,i=r.shift();if(eo(e)&&eo(i))for(var o in i)eo(i[o])?to(null!=(a=e[o])?a:e[o]={},i[o]):e[o]=i[o];return to.apply(void 0,[e].concat(r))}function ro(e){return Array.isArray(e)?e:[e]}a(co,[{key:"get",value:function(e){var t,e=(e=e).startsWith("/")?e.substr(1):e;return null!=(t=this._zip.files[e])?t:this._zip.files[e.replace(/\//g,"\\")]}},{key:"update",value:function(e,t){this._zip.file(e,t)}},{key:"save",value:function(){return this._zip.generateAsync({type:0<arguments.length&&void 0!==arguments[0]?arguments[0]:"blob"})}},{key:"load",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"string";return null!=(e=null==(e=this.get(e))?void 0:e.async(t))?e:Promise.resolve(null)}},{key:"loadRelationships",value:(io=$(P().mark(function e(){var t,r,n,a,i=arguments;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="_rels/.rels",null!=(n=0<i.length&&void 0!==i[0]?i[0]:null)&&(n=Yi(n),n=V(n,2),r=n[0],n=n[1],t="".concat(r,"_rels/").concat(n,".rels")),e.next=5,this.load(t);case 5:return r=e.sent,e.abrupt("return",r?(n=this.parseXmlDocument(r).firstElementChild,(a=this.xmlParser).elements(n).map(function(e){return{id:a.attr(e,"Id"),type:a.attr(e,"Type"),target:a.attr(e,"Target"),targetMode:a.attr(e,"TargetMode")}})):null);case 7:case"end":return e.stop()}},e,this)})),function(){return io.apply(this,arguments)})},{key:"parseXmlDocument",value:function(e){return function(e,t){e=65279===(t=e=1<arguments.length&&void 0!==t&&t?e.replace(/<[?].*[?]>/,""):e).charCodeAt(0)?t.substring(1):t;t=(new DOMParser).parseFromString(e,"application/xml"),e=null==(e=t.getElementsByTagName("parsererror")[0])?void 0:e.textContent;if(e)throw new Error(e);return t}(e,this.options.trimXmlDeclaration)}}],[{key:"load",value:(ao=$(P().mark(function e(t,r){var n;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,zi.loadAsync(t);case 2:return n=e.sent,e.abrupt("return",new co(n,r));case 4:case"end":return e.stop()}},e)})),function(e,t){return ao.apply(this,arguments)})}]);var A,no,ao,io,oo=co,so=(t(lo,d),no=r(lo),a(lo,[{key:"parseXml",value:function(e){this.body=this._documentParser.parseDocumentFile(e)}}]),lo);function lo(e,t,r){return n(this,lo),(e=no.call(this,e,t))._documentParser=r,e}function co(e,t){n(this,co),this._zip=e,this.options=t,this.xmlParser=new Zi}function uo(e,t){return{type:t.attr(e,"val"),color:t.attr(e,"color"),size:t.lengthAttr(e,"sz",E.Border),offset:t.lengthAttr(e,"space",E.Point),frame:t.boolAttr(e,"frame"),shadow:t.boolAttr(e,"shadow")}}function ho(e,t){var r,n,a,i,o,s=1<arguments.length&&void 0!==t?t:T,l={},c=x(s.elements(e));try{for(c.s();!(a=c.n()).done;){var u=a.value;switch(u.localName){case"pgSz":l.pageSize={width:s.lengthAttr(u,"w"),height:s.lengthAttr(u,"h"),orientation:s.attr(u,"orient")};break;case"type":l.type=s.attr(u,"val");break;case"pgMar":l.pageMargins={left:s.lengthAttr(u,"left"),right:s.lengthAttr(u,"right"),top:s.lengthAttr(u,"top"),bottom:s.lengthAttr(u,"bottom"),header:s.lengthAttr(u,"header"),footer:s.lengthAttr(u,"footer"),gutter:s.lengthAttr(u,"gutter")};break;case"cols":l.columns=((e,t)=>({numberOfColumns:t.intAttr(e,"num"),space:t.lengthAttr(e,"space"),separator:t.boolAttr(e,"sep"),equalWidth:t.boolAttr(e,"equalWidth",!0),columns:t.elements(e,"col").map(function(e){return{width:t.lengthAttr(e,"w"),space:t.lengthAttr(e,"space")}})}))(u,s);break;case"headerReference":(null!=(r=l.headerRefs)?r:l.headerRefs=[]).push(fo(u,s));break;case"footerReference":(null!=(n=l.footerRefs)?n:l.footerRefs=[]).push(fo(u,s));break;case"titlePg":l.titlePage=s.boolAttr(u,"val",!0);break;case"pgBorders":l.pageBorders=((e,t)=>{var r,n={},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"left":n.left=uo(i,t);break;case"top":n.top=uo(i,t);break;case"right":n.right=uo(i,t);break;case"bottom":n.bottom=uo(i,t)}}}catch(e){a.e(e)}finally{a.f()}return n})(u,s);break;case"pgNumType":l.pageNumber=(i=u,{chapSep:(o=s).attr(i,"chapSep"),chapStyle:o.attr(i,"chapStyle"),format:o.attr(i,"fmt"),start:o.intAttr(i,"start")})}}}catch(e){c.e(e)}finally{c.f()}return l}function fo(e,t){return{id:t.attr(e,"id"),type:t.attr(e,"type")}}function po(e,t){var r,n={},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;)Wi(r.value,n,t)}catch(e){a.e(e)}finally{a.f()}return n}function mo(e,t){var r,n={},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;)go(r.value,n,t)}catch(e){a.e(e)}finally{a.f()}return n}function go(i,e,t){if(i.namespaceURI==Fi){var r,n,a;if(!Wi(i,e,t))switch(i.localName){case"tabs":e.tabs=(a=t).elements(i,"tab").map(function(e){return{position:a.lengthAttr(e,"pos"),leader:a.attr(e,"leader"),style:a.attr(e,"val")}});break;case"sectPr":e.sectionProps=ho(i,t);break;case"numPr":e.numbering=(e=>{var t,r={},n=x(e.elements(i));try{for(n.s();!(t=n.n()).done;){var a=t.value;switch(a.localName){case"numId":r.id=e.attr(a,"val");break;case"ilvl":r.level=e.intAttr(a,"val")}}}catch(e){n.e(e)}finally{n.f()}return r})(t);break;case"spacing":return e.lineSpacing=(r=i,{before:(n=t).lengthAttr(r,"before"),after:n.lengthAttr(r,"after"),line:n.intAttr(r,"line"),lineRule:n.attr(r,"lineRule")}),0;case"textAlignment":return e.textAlignment=t.attr(i,"val"),0;case"keepLines":e.keepLines=t.boolAttr(i,"val",!0);break;case"keepNext":e.keepNext=t.boolAttr(i,"val",!0);break;case"pageBreakBefore":e.pageBreakBefore=t.boolAttr(i,"val",!0);break;case"outlineLvl":e.outlineLevel=t.intAttr(i,"val");break;case"pStyle":e.styleName=t.attr(i,"val");break;case"rPr":e.runProps=po(i,t);break;default:return}return 1}}function yo(e,t){var r,n={id:t.attr(e,"numId"),overrides:[]},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"abstractNumId":n.abstractId=t.attr(i,"val");break;case"lvlOverride":n.overrides.push(((e,t)=>{var r,n={level:t.intAttr(e,"ilvl")},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"startOverride":n.start=t.intAttr(i,"val");break;case"lvl":n.numberingLevel=bo(i,t)}}}catch(e){a.e(e)}finally{a.f()}return n})(i,t))}}}catch(e){a.e(e)}finally{a.f()}return n}function bo(e,t){var r,n={level:t.intAttr(e,"ilvl")},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"start":n.start=t.attr(i,"val");break;case"lvlRestart":n.restart=t.intAttr(i,"val");break;case"numFmt":n.format=t.attr(i,"val");break;case"lvlText":n.text=t.attr(i,"val");break;case"lvlJc":n.justification=t.attr(i,"val");break;case"lvlPicBulletId":n.bulletPictureId=t.attr(i,"val");break;case"pStyle":n.paragraphStyle=t.attr(i,"val");break;case"pPr":n.paragraphProps=mo(i,t);break;case"rPr":n.runProps=po(i,t)}}}catch(e){a.e(e)}finally{a.f()}return n}t(xo,d),wo=r(xo),a(xo,[{key:"parseXml",value:function(c){Object.assign(this,(e=>{var t,r,n,a,i,o={numberings:[],abstractNumberings:[],bulletPictures:[]},s=x(e.elements(c));try{for(s.s();!(t=s.n()).done;){var l=t.value;switch(l.localName){case"num":o.numberings.push(yo(l,e));break;case"abstractNum":o.abstractNumberings.push(((e,t)=>{var r,n={id:t.attr(e,"abstractNumId"),levels:[]},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"name":n.name=t.attr(i,"val");break;case"multiLevelType":n.multiLevelType=t.attr(i,"val");break;case"numStyleLink":n.numberingStyleLink=t.attr(i,"val");break;case"styleLink":n.styleLink=t.attr(i,"val");break;case"lvl":n.levels.push(bo(i,t))}}}catch(e){a.e(e)}finally{a.f()}return n})(l,e));break;case"numPicBullet":o.bulletPictures.push((r=l,i=a=void 0,a=(n=e).element(r,"pict"),(i=(a=a&&n.element(a,"shape"))&&n.element(a,"imagedata"))?{id:n.attr(r,"numPicBulletId"),referenceId:n.attr(i,"id"),style:n.attr(a,"style")}:null))}}}catch(e){s.e(e)}finally{s.f()}return o})(this._package.xmlParser)),this.domNumberings=this._documentParser.parseNumberingFile(c)}}]);var vo,wo,ko=xo,_o=(t(So,d),vo=r(So),a(So,[{key:"parseXml",value:function(e){this.styles=this._documentParser.parseStylesFile(e)}}]),So);function So(e,t,r){return n(this,So),(e=vo.call(this,e,t))._documentParser=r,e}function xo(e,t,r){return n(this,xo),(e=wo.call(this,e,t))._documentParser=r,e}(p=A=A||{}).Document="document",p.Paragraph="paragraph",p.Run="run",p.Break="break",p.NoBreakHyphen="noBreakHyphen",p.Table="table",p.Row="row",p.Cell="cell",p.Hyperlink="hyperlink",p.SmartTag="smartTag",p.Drawing="drawing",p.Image="image",p.Text="text",p.Tab="tab",p.Symbol="symbol",p.BookmarkStart="bookmarkStart",p.BookmarkEnd="bookmarkEnd",p.Footer="footer",p.Header="header",p.FootnoteReference="footnoteReference",p.EndnoteReference="endnoteReference",p.Footnote="footnote",p.Endnote="endnote",p.SimpleField="simpleField",p.ComplexField="complexField",p.Instruction="instruction",p.VmlPicture="vmlPicture",p.MmlMath="mmlMath",p.MmlMathParagraph="mmlMathParagraph",p.MmlFraction="mmlFraction",p.MmlFunction="mmlFunction",p.MmlFunctionName="mmlFunctionName",p.MmlNumerator="mmlNumerator",p.MmlDenominator="mmlDenominator",p.MmlRadical="mmlRadical",p.MmlBase="mmlBase",p.MmlDegree="mmlDegree",p.MmlSuperscript="mmlSuperscript",p.MmlSubscript="mmlSubscript",p.MmlPreSubSuper="mmlPreSubSuper",p.MmlSubArgument="mmlSubArgument",p.MmlSuperArgument="mmlSuperArgument",p.MmlNary="mmlNary",p.MmlDelimiter="mmlDelimiter",p.MmlRun="mmlRun",p.MmlEquationArray="mmlEquationArray",p.MmlLimit="mmlLimit",p.MmlLimitLower="mmlLimitLower",p.MmlMatrix="mmlMatrix",p.MmlMatrixRow="mmlMatrixRow",p.MmlBox="mmlBox",p.MmlBar="mmlBar",p.MmlGroupChar="mmlGroupChar",p.VmlElement="vmlElement",p.Inserted="inserted",p.Deleted="deleted",p.DeletedText="deletedText",p.Comment="comment",p.CommentReference="commentReference",p.CommentRangeStart="commentRangeStart",p.CommentRangeEnd="commentRangeEnd";var Co,Eo,Po,To,Ao,fa=a(function e(){n(this,e),this.children=[],this.cssStyle={}}),Oo=(t(Lo,fa),Ao=r(Lo),a(Lo)),No=(t(Io,fa),To=r(Io),a(Io)),w=(t(jo,d),Po=r(jo),a(jo,[{key:"parseXml",value:function(e){this.rootElement=this.createRootElement(),this.rootElement.children=this._documentParser.parseBodyElements(e)}}]),jo),Ro=(t(Do,w),Eo=r(Do),a(Do,[{key:"createRootElement",value:function(){return new Oo}}]),Do),Mo=(t(Bo,w),Co=r(Bo),a(Bo,[{key:"createRootElement",value:function(){return new No}}]),Bo);function Bo(){return n(this,Bo),Co.apply(this,arguments)}function Do(){return n(this,Do),Eo.apply(this,arguments)}function jo(e,t,r){return n(this,jo),(e=Po.call(this,e,t))._documentParser=r,e}function Io(){var e;return n(this,Io),(e=To.apply(this,arguments)).type=A.Footer,e}function Lo(){var e;return n(this,Lo),(e=Ao.apply(this,arguments)).type=A.Header,e}function zo(e){if(void 0!==e)return parseInt(e)}t(Vo,d),Uo=r(Vo),a(Vo,[{key:"parseXml",value:function(i){this.props=(e=>{var t,r={},n=x(e.elements(i));try{for(n.s();!(t=n.n()).done;){var a=t.value;switch(a.localName){case"Template":r.template=a.textContent;break;case"Pages":r.pages=zo(a.textContent);break;case"Words":r.words=zo(a.textContent);break;case"Characters":r.characters=zo(a.textContent);break;case"Application":r.application=a.textContent;break;case"Lines":r.lines=zo(a.textContent);break;case"Paragraphs":r.paragraphs=zo(a.textContent);break;case"Company":r.company=a.textContent;break;case"AppVersion":r.appVersion=a.textContent}}}catch(e){n.e(e)}finally{n.f()}return r})(this._package.xmlParser)}}]);var Fo,Uo,Wo=Vo,Ho=(t(qo,d),Fo=r(qo),a(qo,[{key:"parseXml",value:function(i){this.props=(e=>{var t,r={},n=x(e.elements(i));try{for(n.s();!(t=n.n()).done;){var a=t.value;switch(a.localName){case"title":r.title=a.textContent;break;case"description":r.description=a.textContent;break;case"subject":r.subject=a.textContent;break;case"creator":r.creator=a.textContent;break;case"keywords":r.keywords=a.textContent;break;case"language":r.language=a.textContent;break;case"lastModifiedBy":r.lastModifiedBy=a.textContent;break;case"revision":a.textContent&&(r.revision=parseInt(a.textContent))}}}catch(e){n.e(e)}finally{n.f()}return r})(this._package.xmlParser)}}]),qo),Zo=a(function e(){n(this,e)});function qo(){return n(this,qo),Fo.apply(this,arguments)}function Vo(){return n(this,Vo),Uo.apply(this,arguments)}function Xo(e,t){return{latinTypeface:t.elementAttr(e,"latin","typeface"),eaTypeface:t.elementAttr(e,"ea","typeface"),csTypeface:t.elementAttr(e,"cs","typeface")}}t(us,d),Qo=r(us),a(us,[{key:"parseXml",value:function(e){this.theme=((e,t)=>{var r,n=new Zo,a=t.element(e,"themeElements"),i=x(t.elements(a));try{for(i.s();!(r=i.n()).done;){var o=r.value;switch(o.localName){case"clrScheme":n.colorScheme=((e,t)=>{var r,n={name:t.attr(e,"name"),colors:{}},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value,o=t.element(i,"srgbClr"),s=t.element(i,"sysClr");o?n.colors[i.localName]=t.attr(o,"val"):s&&(n.colors[i.localName]=t.attr(s,"lastClr"))}}catch(e){a.e(e)}finally{a.f()}return n})(o,t);break;case"fontScheme":n.fontScheme=((e,t)=>{var r,n={name:t.attr(e,"name")},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"majorFont":n.majorFont=Xo(i,t);break;case"minorFont":n.minorFont=Xo(i,t)}}}catch(e){a.e(e)}finally{a.f()}return n})(o,t)}}}catch(e){i.e(e)}finally{i.f()}return n})(e,this._package.xmlParser)}}]);var Go,Ko,Jo,Yo,$o,Qo,es=us,g=a(function e(){n(this,e)}),ts=(t(cs,g),$o=r(cs),a(cs)),rs=(t(ls,g),Yo=r(ls),a(ls)),Er=(t(ss,d),Jo=r(ss),a(ss)),ns=(t(os,Er),Ko=r(os),a(os,[{key:"parseXml",value:function(e){this.notes=this._documentParser.parseNotes(e,"footnote",ts)}}]),os),as=(t(is,Er),Go=r(is),a(is,[{key:"parseXml",value:function(e){this.notes=this._documentParser.parseNotes(e,"endnote",rs)}}]),is);function is(e,t,r){return n(this,is),Go.call(this,e,t,r)}function os(e,t,r){return n(this,os),Ko.call(this,e,t,r)}function ss(e,t,r){return n(this,ss),(e=Jo.call(this,e,t))._documentParser=r,e}function ls(){var e;return n(this,ls),(e=Yo.apply(this,arguments)).type=A.Endnote,e}function cs(){var e;return n(this,cs),(e=$o.apply(this,arguments)).type=A.Footnote,e}function us(e,t){return n(this,us),Qo.call(this,e,t)}function hs(e,t){var r,n={defaultNoteIds:[]},a=x(t.elements(e));try{for(a.s();!(r=a.n()).done;){var i=r.value;switch(i.localName){case"numFmt":n.nummeringFormat=t.attr(i,"val");break;case"footnote":case"endnote":n.defaultNoteIds.push(t.attr(i,"id"))}}}catch(e){a.e(e)}finally{a.f()}return n}t(Ns,d),ws=r(Ns),a(Ns,[{key:"parseXml",value:function(i){this.settings=(e=>{var t,r={},n=x(e.elements(i));try{for(n.s();!(t=n.n()).done;){var a=t.value;switch(a.localName){case"defaultTabStop":r.defaultTabStop=e.lengthAttr(a,"val");break;case"footnotePr":r.footnoteProps=hs(a,e);break;case"endnotePr":r.endnoteProps=hs(a,e);break;case"autoHyphenation":r.autoHyphenation=e.boolAttr(a,"val")}}}catch(e){n.e(e)}finally{n.f()}return r})(this._package.xmlParser)}}]);var ds,fs,ps,ms,gs,ys,bs,vs,ws,ks=Ns,_s=(t(Os,d),vs=r(Os),a(Os,[{key:"parseXml",value:function(e){var r;this.props=(r=this._package.xmlParser).elements(e,"property").map(function(e){var t=e.firstChild;return{formatId:r.attr(e,"fmtid"),name:r.attr(e,"name"),type:t.nodeName,value:t.textContent}})}}]),Os),Ss=(t(As,d),bs=r(As),a(As,[{key:"parseXml",value:function(e){this.comments=this._documentParser.parseComments(e),this.commentMap=Qi(this.comments,function(e){return e.id})}}]),As),xs=(t(Ts,d),ys=r(Ts),a(Ts,[{key:"parseXml",value:function(e){var t,r=this._package.xmlParser,n=x(r.elements(e,"commentEx"));try{for(n.s();!(t=n.n()).done;){var a=t.value;this.comments.push({paraId:r.attr(a,"paraId"),paraIdParent:r.attr(a,"paraIdParent"),done:r.boolAttr(a,"done")})}}catch(e){n.e(e)}finally{n.f()}this.commentMap=Qi(this.comments,function(e){return e.paraId})}}]),Ts),Cs=[{type:C.OfficeDocument,target:"word/document.xml"},{type:C.ExtendedProperties,target:"docProps/app.xml"},{type:C.CoreProperties,target:"docProps/core.xml"},{type:C.CustomProperties,target:"docProps/custom.xml"}],Es=(a(Ps,[{key:"save",value:function(){return this._package.save(0<arguments.length&&void 0!==arguments[0]?arguments[0]:"blob")}},{key:"loadRelationshipPart",value:(gs=$(P().mark(function e(t,r){var n,a,i,o=this;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.partsMap[t])return e.abrupt("return",this.partsMap[t]);e.next=2;break;case 2:if(this._package.get(t)){e.next=4;break}return e.abrupt("return",null);case 4:n=null,e.t0=r,e.next=e.t0===C.OfficeDocument?8:e.t0===C.FontTable?10:e.t0===C.Numbering?12:e.t0===C.Styles?14:e.t0===C.Theme?16:e.t0===C.Footnotes?18:e.t0===C.Endnotes?20:e.t0===C.Footer?22:e.t0===C.Header?24:e.t0===C.CoreProperties?26:e.t0===C.ExtendedProperties?28:e.t0===C.CustomProperties?30:e.t0===C.Settings?32:e.t0===C.Comments?34:e.t0===C.CommentsExtended?36:37;break;case 8:return this.documentPart=n=new so(this._package,t,this._parser),e.abrupt("break",37);case 10:return this.fontTablePart=n=new Ki(this._package,t),e.abrupt("break",37);case 12:return this.numberingPart=n=new ko(this._package,t,this._parser),e.abrupt("break",37);case 14:return this.stylesPart=n=new _o(this._package,t,this._parser),e.abrupt("break",37);case 16:return this.themePart=n=new es(this._package,t),e.abrupt("break",37);case 18:return this.footnotesPart=n=new ns(this._package,t,this._parser),e.abrupt("break",37);case 20:return this.endnotesPart=n=new as(this._package,t,this._parser),e.abrupt("break",37);case 22:return n=new Mo(this._package,t,this._parser),e.abrupt("break",37);case 24:return n=new Ro(this._package,t,this._parser),e.abrupt("break",37);case 26:return this.corePropsPart=n=new Ho(this._package,t),e.abrupt("break",37);case 28:return this.extendedPropsPart=n=new Wo(this._package,t),e.abrupt("break",37);case 30:return n=new _s(this._package,t),e.abrupt("break",37);case 32:return this.settingsPart=n=new ks(this._package,t),e.abrupt("break",37);case 34:return this.commentsPart=n=new Ss(this._package,t,this._parser),e.abrupt("break",37);case 36:this.commentsExtendedPart=n=new xs(this._package,t);case 37:if(null==n)return e.abrupt("return",Promise.resolve(null));e.next=39;break;case 39:return this.partsMap[t]=n,this.parts.push(n),e.next=43,n.load();case 43:if(0<(null==(a=n.rels)?void 0:a.length))return a=Yi(n.path),a=V(a,1),i=a[0],e.next=47,Promise.all(n.rels.map(function(e){return o.loadRelationshipPart($i(e.target,i),e.type)}));e.next=47;break;case 47:return e.abrupt("return",n);case 48:case"end":return e.stop()}},e,this)})),function(e,t){return gs.apply(this,arguments)})},{key:"loadDocumentImage",value:(ms=$(P().mark(function e(t,r){var n;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(null!=r?r:this.documentPart,t,"blob");case 2:return n=e.sent,e.abrupt("return",this.blobToURL(n));case 4:case"end":return e.stop()}},e,this)})),function(e,t){return ms.apply(this,arguments)})},{key:"loadNumberingImage",value:(ps=$(P().mark(function e(t){var r;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(this.numberingPart,t,"blob");case 2:return r=e.sent,e.abrupt("return",this.blobToURL(r));case 4:case"end":return e.stop()}},e,this)})),function(e){return ps.apply(this,arguments)})},{key:"loadFont",value:(fs=$(P().mark(function e(t,r){var n;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(this.fontTablePart,t,"uint8array");case 2:return n=e.sent,e.abrupt("return",n&&this.blobToURL(new Blob([((e,t)=>{for(var r=t.replace(/{|}|-/g,""),n=new Array(16),a=0;a<16;a++)n[16-a-1]=parseInt(r.substr(2*a,2),16);for(var i=0;i<32;i++)e[i]=e[i]^n[i%16];return e})(n,r)])));case 4:case"end":return e.stop()}},e,this)})),function(e,t){return fs.apply(this,arguments)})},{key:"blobToURL",value:function(e){return e?this._options.useBase64URL?(n=e,new Promise(function(e,t){var r=new FileReader;r.onloadend=function(){return e(r.result)},r.onerror=function(){return t()},r.readAsDataURL(n)})):URL.createObjectURL(e):null;var n}},{key:"findPartByRelId",value:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,r=(null!=(r=e.rels)?r:this.rels).find(function(e){return e.id==t}),e=e?Yi(e.path)[0]:"";return r?this.partsMap[$i(r.target,e)]:null}},{key:"getPathById",value:function(e,t){var r=e.rels.find(function(e){return e.id==t}),e=V(Yi(e.path),1)[0];return r?$i(r.target,e):null}},{key:"loadResource",value:function(e,t,r){e=this.getPathById(e,t);return e?this._package.load(e,r):Promise.resolve(null)}}],[{key:"load",value:(ds=$(P().mark(function e(t,r,n){var a;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return(a=new Ps)._options=n,a._parser=r,e.next=5,oo.load(t,n);case 5:return a._package=e.sent,e.next=8,a._package.loadRelationships();case 8:return a.rels=e.sent,e.next=11,Promise.all(Cs.map(function(t){var e=null!=(e=a.rels.find(function(e){return e.type===t.type}))?e:t;return a.loadRelationshipPart(e.target,e.type)}));case 11:return e.abrupt("return",a);case 12:case"end":return e.stop()}},e)})),function(e,t,r){return ds.apply(this,arguments)})}]),Ps);function Ps(){n(this,Ps),this.parts=[],this.partsMap={}}function Ts(e,t){return n(this,Ts),(e=ys.call(this,e,t)).comments=[],e}function As(e,t,r){return n(this,As),(e=bs.call(this,e,t))._documentParser=r,e}function Os(){return n(this,Os),vs.apply(this,arguments)}function Ns(e,t){return n(this,Ns),ws.call(this,e,t)}t(Bs,fa),Rs=r(Bs);var Rs,Ms=a(Bs);function Bs(){var e;return n(this,Bs),(e=Rs.apply(this,arguments)).type=A.VmlElement,e.attrs={},e}function Ds(e,t){var r,n=new Ms;switch(e.localName){case"rect":n.tagName="rect",Object.assign(n.attrs,{width:"100%",height:"100%"});break;case"oval":n.tagName="ellipse",Object.assign(n.attrs,{cx:"50%",cy:"50%",rx:"50%",ry:"50%"});break;case"line":n.tagName="line";break;case"shape":n.tagName="g";break;case"textbox":n.tagName="foreignObject",Object.assign(n.attrs,{width:"100%",height:"100%"});break;default:return null}var a,i=x(T.attrs(e));try{for(i.s();!(a=i.n()).done;){var o=a.value;switch(o.localName){case"style":n.cssStyleText=o.value;break;case"fillcolor":n.attrs.fill=o.value;break;case"from":var s=V(js(o.value),2),l=s[0],c=s[1];Object.assign(n.attrs,{x1:l,y1:c});break;case"to":var u=V(js(o.value),2),h=u[0],d=u[1];Object.assign(n.attrs,{x2:h,y2:d})}}}catch(e){i.e(e)}finally{i.f()}var f,p,m=x(T.elements(e));try{for(m.s();!(f=m.n()).done;){var g=f.value;switch(g.localName){case"stroke":Object.assign(n.attrs,(p=g,{stroke:T.attr(p,"color"),"stroke-width":null!=(p=T.lengthAttr(p,"weight",E.Emu))?p:"1px"}));break;case"fill":Object.assign(n.attrs,{});break;case"imagedata":n.tagName="image",Object.assign(n.attrs,{width:"100%",height:"100%"}),n.imageHref={id:T.attr(g,"id"),title:T.attr(g,"title")};break;case"txbxContent":(r=n.children).push.apply(r,q(t.parseBodyElements(g)));break;default:var y=Ds(g,t);y&&n.children.push(y)}}}catch(e){m.e(e)}finally{m.f()}return n}function js(e){return e.split(",")}t(rl,fa),Fs=r(rl);var Is,Ls,zs,Fs,Us=a(rl),Ws=(t(tl,fa),zs=r(tl),a(tl)),Hs=(t(el,fa),Ls=r(el),a(el)),Zs=(t(Qs,fa),Is=r(Qs),a(Qs)),qs=[],Vs={oMath:A.MmlMath,oMathPara:A.MmlMathParagraph,f:A.MmlFraction,func:A.MmlFunction,fName:A.MmlFunctionName,num:A.MmlNumerator,den:A.MmlDenominator,rad:A.MmlRadical,deg:A.MmlDegree,e:A.MmlBase,sSup:A.MmlSuperscript,sSub:A.MmlSubscript,sPre:A.MmlPreSubSuper,sup:A.MmlSuperArgument,sub:A.MmlSubArgument,d:A.MmlDelimiter,nary:A.MmlNary,eqArr:A.MmlEquationArray,lim:A.MmlLimit,limLow:A.MmlLimitLower,m:A.MmlMatrix,mr:A.MmlMatrixRow,box:A.MmlBox,bar:A.MmlBar,groupChr:A.MmlGroupChar},Xs=(a($s,[{key:"parseNotes",value:function(e,t,r){var n,a=[],i=x(T.elements(e,t));try{for(i.s();!(n=i.n()).done;){var o=n.value,s=new r;s.id=T.attr(o,"id"),s.noteType=T.attr(o,"type"),s.children=this.parseBodyElements(o),a.push(s)}}catch(e){i.e(e)}finally{i.f()}return a}},{key:"parseComments",value:function(e){var t,r=[],n=x(T.elements(e,"comment"));try{for(n.s();!(t=n.n()).done;){var a=t.value,i=new Us;i.id=T.attr(a,"id"),i.author=T.attr(a,"author"),i.initials=T.attr(a,"initials"),i.date=T.attr(a,"date"),i.children=this.parseBodyElements(a),r.push(i)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"parseDocumentFile",value:function(e){var t=T.element(e,"body"),e=T.element(e,"background"),r=T.element(t,"sectPr");return{type:A.Document,children:this.parseBodyElements(t),props:r?ho(r,T):{},cssStyle:e?this.parseBackground(e):{}}}},{key:"parseBackground",value:function(e){var t={},e=O.colorAttr(e,"color");return e&&(t["background-color"]=e),t}},{key:"parseBodyElements",value:function(e){var t,r=this,n=[],a=x(T.elements(e));try{for(a.s();!(t=a.n()).done;){var i=t.value;switch(i.localName){case"p":n.push(this.parseParagraph(i));break;case"tbl":n.push(this.parseTable(i));break;case"sdt":n.push.apply(n,q(this.parseSdt(i,function(e){return r.parseBodyElements(e)})))}}}catch(e){a.e(e)}finally{a.f()}return n}},{key:"parseStylesFile",value:function(e){var t=this,r=[];return O.foreach(e,function(e){switch(e.localName){case"style":r.push(t.parseStyle(e));break;case"docDefaults":r.push(t.parseDefaultStyles(e))}}),r}},{key:"parseDefaultStyles",value:function(e){var r=this,n={id:null,name:null,target:null,basedOn:null,styles:[]};return O.foreach(e,function(e){switch(e.localName){case"rPrDefault":var t=T.element(e,"rPr");t&&n.styles.push({target:"span",values:r.parseDefaultProperties(t,{})});break;case"pPrDefault":t=T.element(e,"pPr");t&&n.styles.push({target:"p",values:r.parseDefaultProperties(t,{})})}}),n}},{key:"parseStyle",value:function(e){var a=this,i={id:T.attr(e,"styleId"),isDefault:T.boolAttr(e,"default"),name:null,target:null,basedOn:null,styles:[],linked:null};switch(T.attr(e,"type")){case"paragraph":i.target="p";break;case"table":i.target="table";break;case"character":i.target="span"}return O.foreach(e,function(e){switch(e.localName){case"basedOn":i.basedOn=T.attr(e,"val");break;case"name":i.name=T.attr(e,"val");break;case"link":i.linked=T.attr(e,"val");break;case"next":i.next=T.attr(e,"val");break;case"aliases":i.aliases=T.attr(e,"val").split(",");break;case"pPr":i.styles.push({target:"p",values:a.parseDefaultProperties(e,{})}),i.paragraphProps=mo(e,T);break;case"rPr":i.styles.push({target:"span",values:a.parseDefaultProperties(e,{})}),i.runProps=po(e,T);break;case"tblPr":case"tcPr":i.styles.push({target:"td",values:a.parseDefaultProperties(e,{})});break;case"tblStylePr":var t,r=x(a.parseTableStyle(e));try{for(r.s();!(t=r.n()).done;){var n=t.value;i.styles.push(n)}}catch(e){r.e(e)}finally{r.f()}break;case"rsid":case"qFormat":case"hidden":case"semiHidden":case"unhideWhenUsed":case"autoRedefine":case"uiPriority":break;default:a.options.debug&&console.warn("DOCX: Unknown style element: ".concat(e.localName))}}),i}},{key:"parseTableStyle",value:function(e){var t=this,r=[],n=T.attr(e,"type"),a="",i="";switch(n){case"firstRow":i=".first-row",a="tr.first-row td";break;case"lastRow":i=".last-row",a="tr.last-row td";break;case"firstCol":i=".first-col",a="td.first-col";break;case"lastCol":i=".last-col",a="td.last-col";break;case"band1Vert":i=":not(.no-vband)",a="td.odd-col";break;case"band2Vert":i=":not(.no-vband)",a="td.even-col";break;case"band1Horz":i=":not(.no-hband)",a="tr.odd-row";break;case"band2Horz":i=":not(.no-hband)",a="tr.even-row";break;default:return[]}return O.foreach(e,function(e){switch(e.localName){case"pPr":r.push({target:"".concat(a," p"),mod:i,values:t.parseDefaultProperties(e,{})});break;case"rPr":r.push({target:"".concat(a," span"),mod:i,values:t.parseDefaultProperties(e,{})});break;case"tblPr":case"tcPr":r.push({target:a,mod:i,values:t.parseDefaultProperties(e,{})})}}),r}},{key:"parseNumberingFile",value:function(e){var n=this,a=[],i={},o=[];return O.foreach(e,function(e){switch(e.localName){case"abstractNum":n.parseAbstractNumbering(e,o).forEach(function(e){return a.push(e)});break;case"numPicBullet":o.push(n.parseNumberingPicBullet(e));break;case"num":var t=T.attr(e,"numId"),r=T.elementAttr(e,"abstractNumId","val");i[r]=t}}),a.forEach(function(e){return e.id=i[e.id]}),a}},{key:"parseNumberingPicBullet",value:function(e){var t=T.element(e,"pict"),t=t&&T.element(t,"shape"),r=t&&T.element(t,"imagedata");return r?{id:T.intAttr(e,"numPicBulletId"),src:T.attr(r,"id"),style:T.attr(t,"style")}:null}},{key:"parseAbstractNumbering",value:function(e,t){var r=this,n=[],a=T.attr(e,"abstractNumId");return O.foreach(e,function(e){"lvl"===e.localName&&n.push(r.parseNumberingLevel(a,e,t))}),n}},{key:"parseNumberingLevel",value:function(e,t,r){var n=this,a={id:e,level:T.intAttr(t,"ilvl"),start:1,pStyleName:void 0,pStyle:{},rStyle:{},suff:"tab"};return O.foreach(t,function(e){switch(e.localName){case"start":a.start=T.intAttr(e,"val");break;case"pPr":n.parseDefaultProperties(e,a.pStyle);break;case"rPr":n.parseDefaultProperties(e,a.rStyle);break;case"lvlPicBulletId":var t=T.intAttr(e,"val");a.bullet=r.find(function(e){return(null==e?void 0:e.id)==t});break;case"lvlText":a.levelText=T.attr(e,"val");break;case"pStyle":a.pStyleName=T.attr(e,"val");break;case"numFmt":a.format=T.attr(e,"val");break;case"suff":a.suff=T.attr(e,"val")}}),a}},{key:"parseSdt",value:function(e,t){e=T.element(e,"sdtContent");return e?t(e):[]}},{key:"parseInserted",value:function(e,t){return{type:A.Inserted,children:null!=(e=null==(t=t(e))?void 0:t.children)?e:[]}}},{key:"parseDeleted",value:function(e,t){return{type:A.Deleted,children:null!=(e=null==(t=t(e))?void 0:t.children)?e:[]}}},{key:"parseParagraph",value:function(e){var t,r,n,a,i=this,o={type:A.Paragraph,children:[]},s=x(T.elements(e));try{for(s.s();!(a=s.n()).done;){var l=a.value;switch(l.localName){case"pPr":this.parseParagraphProperties(l,o);break;case"r":o.children.push(this.parseRun(l,o));break;case"hyperlink":o.children.push(this.parseHyperlink(l,o));break;case"smartTag":o.children.push(this.parseSmartTag(l,o));break;case"bookmarkStart":o.children.push((r=l,n=T,{type:A.BookmarkStart,id:n.attr(r,"id"),name:n.attr(r,"name"),colFirst:n.intAttr(r,"colFirst"),colLast:n.intAttr(r,"colLast")}));break;case"bookmarkEnd":o.children.push({type:A.BookmarkEnd,id:T.attr(l,"id")});break;case"commentRangeStart":o.children.push(new Hs(T.attr(l,"id")));break;case"commentRangeEnd":o.children.push(new Zs(T.attr(l,"id")));break;case"oMath":case"oMathPara":o.children.push(this.parseMathElement(l));break;case"sdt":(t=o.children).push.apply(t,q(this.parseSdt(l,function(e){return i.parseParagraph(e).children})));break;case"ins":o.children.push(this.parseInserted(l,function(e){return i.parseParagraph(e)}));break;case"del":o.children.push(this.parseDeleted(l,function(e){return i.parseParagraph(e)}))}}}catch(e){s.e(e)}finally{s.f()}return o}},{key:"parseParagraphProperties",value:function(e,t){var r=this;this.parseDefaultProperties(e,t.cssStyle={},null,function(e){if(!go(e,t,T))switch(e.localName){case"pStyle":t.styleName=T.attr(e,"val");break;case"cnfStyle":t.className=N.classNameOfCnfStyle(e);break;case"framePr":r.parseFrame(e,t);break;case"rPr":break;default:return!1}return!0})}},{key:"parseFrame",value:function(e,t){"drop"==T.attr(e,"dropCap")&&(t.cssStyle.float="left")}},{key:"parseHyperlink",value:function(e,t){var r=this,n={type:A.Hyperlink,parent:t,children:[]},t=T.attr(e,"anchor"),a=T.attr(e,"id");return t&&(n.href="#"+t),a&&(n.id=a),O.foreach(e,function(e){"r"===e.localName&&n.children.push(r.parseRun(e,n))}),n}},{key:"parseSmartTag",value:function(e,t){var r=this,n={type:A.SmartTag,parent:t,children:[]},t=T.attr(e,"uri"),a=T.attr(e,"element");return t&&(n.uri=t),a&&(n.element=a),O.foreach(e,function(e){"r"===e.localName&&n.children.push(r.parseRun(e,n))}),n}},{key:"parseRun",value:function(e,t){var r=this,n={type:A.Run,parent:t,children:[]};return O.foreach(e,function(e){switch((e=r.checkAlternateContent(e)).localName){case"t":n.children.push({type:A.Text,text:e.textContent});break;case"delText":n.children.push({type:A.DeletedText,text:e.textContent});break;case"commentReference":n.children.push(new Ws(T.attr(e,"id")));break;case"fldSimple":n.children.push({type:A.SimpleField,instruction:T.attr(e,"instr"),lock:T.boolAttr(e,"lock",!1),dirty:T.boolAttr(e,"dirty",!1)});break;case"instrText":n.fieldRun=!0,n.children.push({type:A.Instruction,text:e.textContent});break;case"fldChar":n.fieldRun=!0,n.children.push({type:A.ComplexField,charType:T.attr(e,"fldCharType"),lock:T.boolAttr(e,"lock",!1),dirty:T.boolAttr(e,"dirty",!1)});break;case"noBreakHyphen":n.children.push({type:A.NoBreakHyphen});break;case"br":n.children.push({type:A.Break,break:T.attr(e,"type")||"textWrapping"});break;case"lastRenderedPageBreak":n.children.push({type:A.Break,break:"lastRenderedPageBreak"});break;case"sym":n.children.push({type:A.Symbol,font:T.attr(e,"font"),char:T.attr(e,"char")});break;case"tab":n.children.push({type:A.Tab});break;case"footnoteReference":n.children.push({type:A.FootnoteReference,id:T.attr(e,"id")});break;case"endnoteReference":n.children.push({type:A.EndnoteReference,id:T.attr(e,"id")});break;case"drawing":var t=r.parseDrawing(e);t&&(n.children=[t]);break;case"pict":n.children.push(r.parseVmlPicture(e));break;case"rPr":r.parseRunProperties(e,n)}}),n}},{key:"parseMathElement",value:function(e){var t,r="".concat(e.localName,"Pr"),n={type:Vs[e.localName],children:[]},a=x(T.elements(e));try{for(a.s();!(t=a.n()).done;){var i,o=t.value;Vs[o.localName]?n.children.push(this.parseMathElement(o)):"r"==o.localName?((i=this.parseRun(o)).type=A.MmlRun,n.children.push(i)):o.localName==r&&(n.props=this.parseMathProperies(o))}}catch(e){a.e(e)}finally{a.f()}return n}},{key:"parseMathProperies",value:function(e){var t,r={},n=x(T.elements(e));try{for(n.s();!(t=n.n()).done;){var a=t.value;switch(a.localName){case"chr":r.char=T.attr(a,"val");break;case"vertJc":r.verticalJustification=T.attr(a,"val");break;case"pos":r.position=T.attr(a,"val");break;case"degHide":r.hideDegree=T.boolAttr(a,"val");break;case"begChr":r.beginChar=T.attr(a,"val");break;case"endChr":r.endChar=T.attr(a,"val")}}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"parseRunProperties",value:function(e,t){this.parseDefaultProperties(e,t.cssStyle={},null,function(e){switch(e.localName){case"rStyle":t.styleName=T.attr(e,"val");break;case"vertAlign":t.verticalAlign=N.valueOfVertAlign(e,!0);break;default:return!1}return!0})}},{key:"parseVmlPicture",value:function(e){var t,r={type:A.VmlPicture,children:[]},n=x(T.elements(e));try{for(n.s();!(t=n.n()).done;){var a=Ds(t.value,this);a&&r.children.push(a)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"checkAlternateContent",value:function(e){if("AlternateContent"!=e.localName)return e;var t=T.element(e,"Choice");if(t){var r=T.attr(t,"Requires"),r=e.lookupNamespaceURI(r);if(qs.includes(r))return t.firstElementChild}return null==(r=T.element(e,"Fallback"))?void 0:r.firstElementChild}},{key:"parseDrawing",value:function(e){var t,r=x(T.elements(e));try{for(r.s();!(t=r.n()).done;){var n=t.value;switch(n.localName){case"inline":case"anchor":return this.parseDrawingWrapper(n)}}}catch(e){r.e(e)}finally{r.f()}}},{key:"parseDrawingWrapper",value:function(e){var t={type:A.Drawing,children:[],cssStyle:{}},r="anchor"==e.localName,n=null,a=T.boolAttr(e,"simplePos");T.boolAttr(e,"behindDoc");var i,o={relative:"page",align:"left",offset:"0"},s={relative:"page",align:"top",offset:"0"},l=x(T.elements(e));try{for(l.s();!(i=l.n()).done;){var c,u,h,d,f=i.value;switch(f.localName){case"simplePos":a&&(o.offset=T.lengthAttr(f,"x",E.Emu),s.offset=T.lengthAttr(f,"y",E.Emu));break;case"extent":t.cssStyle.width=T.lengthAttr(f,"cx",E.Emu),t.cssStyle.height=T.lengthAttr(f,"cy",E.Emu);break;case"positionH":case"positionV":a||(u="positionH"==f.localName?o:s,h=T.element(f,"align"),d=T.element(f,"posOffset"),u.relative=null!=(c=T.attr(f,"relativeFrom"))?c:u.relative,h&&(u.align=h.textContent),d&&(u.offset=O.sizeValue(d,E.Emu)));break;case"wrapTopAndBottom":n="wrapTopAndBottom";break;case"wrapNone":n="wrapNone";break;case"graphic":var p=this.parseGraphic(f);p&&t.children.push(p)}}}catch(e){l.e(e)}finally{l.f()}return"wrapTopAndBottom"==n?(t.cssStyle.display="block",o.align&&(t.cssStyle["text-align"]=o.align,t.cssStyle.width="100%")):"wrapNone"==n?(t.cssStyle.display="block",t.cssStyle.position="relative",t.cssStyle.width="0px",t.cssStyle.height="0px",o.offset&&(t.cssStyle.left=o.offset),s.offset&&(t.cssStyle.top=s.offset)):!r||"left"!=o.align&&"right"!=o.align||(t.cssStyle.float=o.align),t}},{key:"parseGraphic",value:function(e){var t,r=T.element(e,"graphicData"),n=x(T.elements(r));try{for(n.s();!(t=n.n()).done;){var a=t.value;if("pic"===a.localName)return this.parsePicture(a)}}catch(e){n.e(e)}finally{n.f()}return null}},{key:"parsePicture",value:function(e){var t={type:A.Image,src:"",cssStyle:{}},r=T.element(e,"blipFill"),r=T.element(r,"blip");t.src=T.attr(r,"embed");var n,r=T.element(e,"spPr"),r=T.element(r,"xfrm"),a=x((t.cssStyle.position="relative",T.elements(r)));try{for(a.s();!(n=a.n()).done;){var i=n.value;switch(i.localName){case"ext":t.cssStyle.width=T.lengthAttr(i,"cx",E.Emu),t.cssStyle.height=T.lengthAttr(i,"cy",E.Emu);break;case"off":t.cssStyle.left=T.lengthAttr(i,"x",E.Emu),t.cssStyle.top=T.lengthAttr(i,"y",E.Emu)}}}catch(e){a.e(e)}finally{a.f()}return t}},{key:"parseTable",value:function(e){var t=this,r={type:A.Table,children:[]};return O.foreach(e,function(e){switch(e.localName){case"tr":r.children.push(t.parseTableRow(e));break;case"tblGrid":r.columns=t.parseTableColumns(e);break;case"tblPr":t.parseTableProperties(e,r)}}),r}},{key:"parseTableColumns",value:function(e){var t=[];return O.foreach(e,function(e){"gridCol"===e.localName&&t.push({width:T.lengthAttr(e,"w")})}),t}},{key:"parseTableProperties",value:function(e,t){var r=this;switch(t.cssStyle={},t.cellStyle={},this.parseDefaultProperties(e,t.cssStyle,t.cellStyle,function(e){switch(e.localName){case"tblStyle":t.styleName=T.attr(e,"val");break;case"tblLook":t.className=N.classNameOftblLook(e);break;case"tblpPr":r.parseTablePosition(e,t);break;case"tblStyleColBandSize":t.colBandSize=T.intAttr(e,"val");break;case"tblStyleRowBandSize":t.rowBandSize=T.intAttr(e,"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"}}},{key:"parseTablePosition",value:function(e,t){var r=T.lengthAttr(e,"topFromText"),n=T.lengthAttr(e,"bottomFromText"),a=T.lengthAttr(e,"rightFromText"),e=T.lengthAttr(e,"leftFromText");t.cssStyle.float="left",t.cssStyle["margin-bottom"]=N.addSize(t.cssStyle["margin-bottom"],n),t.cssStyle["margin-left"]=N.addSize(t.cssStyle["margin-left"],e),t.cssStyle["margin-right"]=N.addSize(t.cssStyle["margin-right"],a),t.cssStyle["margin-top"]=N.addSize(t.cssStyle["margin-top"],r)}},{key:"parseTableRow",value:function(e){var t=this,r={type:A.Row,children:[]};return O.foreach(e,function(e){switch(e.localName){case"tc":r.children.push(t.parseTableCell(e));break;case"trPr":t.parseTableRowProperties(e,r)}}),r}},{key:"parseTableRowProperties",value:function(e,t){t.cssStyle=this.parseDefaultProperties(e,{},null,function(e){switch(e.localName){case"cnfStyle":t.className=N.classNameOfCnfStyle(e);break;case"tblHeader":t.isHeader=T.boolAttr(e,"val");break;default:return!1}return!0})}},{key:"parseTableCell",value:function(e){var t=this,r={type:A.Cell,children:[]};return O.foreach(e,function(e){switch(e.localName){case"tbl":r.children.push(t.parseTable(e));break;case"p":r.children.push(t.parseParagraph(e));break;case"tcPr":t.parseTableCellProperties(e,r)}}),r}},{key:"parseTableCellProperties",value:function(e,r){r.cssStyle=this.parseDefaultProperties(e,{},null,function(e){var t;switch(e.localName){case"gridSpan":r.span=T.intAttr(e,"val",null);break;case"vMerge":r.verticalMerge=null!=(t=T.attr(e,"val"))?t:"continue";break;case"cnfStyle":r.className=N.classNameOfCnfStyle(e);break;default:return!1}return!0})}},{key:"parseDefaultProperties",value:function(t){var r=this,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,a=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null,n=n||{};return O.foreach(t,function(e){if(null==i||!i(e))switch(e.localName){case"jc":n["text-align"]=N.valueOfJc(e);break;case"textAlignment":n["vertical-align"]=N.valueOfTextAlignment(e);break;case"color":n.color=O.colorAttr(e,"val",null,"black");break;case"sz":n["font-size"]=n["min-height"]=T.lengthAttr(e,"val",E.FontSize);break;case"shd":n["background-color"]=O.colorAttr(e,"fill",null,"inherit");break;case"highlight":n["background-color"]=O.colorAttr(e,"val",null,"transparent");break;case"vertAlign":break;case"position":n.verticalAlign=T.lengthAttr(e,"val",E.FontSize);break;case"tcW":if(r.options.ignoreWidth)break;case"tblW":n.width=N.valueOfSize(e,"w");break;case"trHeight":r.parseTrHeight(e,n);break;case"strike":n["text-decoration"]=T.boolAttr(e,"val",!0)?"line-through":"none";break;case"b":n["font-weight"]=T.boolAttr(e,"val",!0)?"bold":"normal";break;case"i":n["font-style"]=T.boolAttr(e,"val",!0)?"italic":"normal";break;case"caps":n["text-transform"]=T.boolAttr(e,"val",!0)?"uppercase":"none";break;case"smallCaps":n["font-variant"]=T.boolAttr(e,"val",!0)?"small-caps":"none";break;case"u":r.parseUnderline(e,n);break;case"ind":case"tblInd":r.parseIndentation(e,n);break;case"rFonts":r.parseFont(e,n);break;case"tblBorders":r.parseBorderProperties(e,a||n);break;case"tblCellSpacing":n["border-spacing"]=N.valueOfMargin(e),n["border-collapse"]="separate";break;case"pBdr":r.parseBorderProperties(e,n);break;case"bdr":n.border=N.valueOfBorder(e);break;case"tcBorders":r.parseBorderProperties(e,n);break;case"vanish":T.boolAttr(e,"val",!0)&&(n.display="none");break;case"kern":case"noWrap":break;case"tblCellMar":case"tcMar":r.parseMarginProperties(e,a||n);break;case"tblLayout":n["table-layout"]=N.valueOfTblLayout(e);break;case"vAlign":n["vertical-align"]=N.valueOfTextAlignment(e);break;case"spacing":"pPr"==t.localName&&r.parseSpacing(e,n);break;case"wordWrap":T.boolAttr(e,"val")&&(n["overflow-wrap"]="break-word");break;case"suppressAutoHyphens":n.hyphens=T.boolAttr(e,"val",!0)?"none":"auto";break;case"lang":n.$lang=T.attr(e,"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:r.options.debug&&console.warn("DOCX: Unknown document element: ".concat(t.localName,".").concat(e.localName))}}),n}},{key:"parseUnderline",value:function(e,t){var r=T.attr(e,"val");if(null!=r){switch(r){case"dash":case"dashDotDotHeavy":case"dashDotHeavy":case"dashedHeavy":case"dashLong":case"dashLongHeavy":case"dotDash":case"dotDotDash":t["text-decoration"]="underline dashed";break;case"dotted":case"dottedHeavy":t["text-decoration"]="underline dotted";break;case"double":t["text-decoration"]="underline double";break;case"single":case"thick":case"words":t["text-decoration"]="underline";break;case"wave":case"wavyDouble":case"wavyHeavy":t["text-decoration"]="underline wavy";break;case"none":t["text-decoration"]="none"}r=O.colorAttr(e,"color");r&&(t["text-decoration-color"]=r)}}},{key:"parseFont",value:function(e,t){e=[T.attr(e,"ascii"),N.themeValue(e,"asciiTheme")].filter(function(e){return e}).join(", ");0<e.length&&(t["font-family"]=e)}},{key:"parseIndentation",value:function(e,t){var r=T.lengthAttr(e,"firstLine"),n=T.lengthAttr(e,"hanging"),a=T.lengthAttr(e,"left"),i=T.lengthAttr(e,"start"),o=T.lengthAttr(e,"right"),e=T.lengthAttr(e,"end");r&&(t["text-indent"]=r),n&&(t["text-indent"]="-".concat(n)),(a||i)&&(t["margin-left"]=a||i),(o||e)&&(t["margin-right"]=o||e)}},{key:"parseSpacing",value:function(e,t){var r=T.lengthAttr(e,"before"),n=T.lengthAttr(e,"after"),a=T.intAttr(e,"line",null),e=T.attr(e,"lineRule");if(r&&(t["margin-top"]=r),n&&(t["margin-bottom"]=n),null!==a)switch(e){case"auto":t["line-height"]="".concat((a/240).toFixed(2));break;case"atLeast":t["line-height"]="calc(100% + ".concat(a/20,"pt)");break;default:t["line-height"]=t["min-height"]=a/20+"pt"}}},{key:"parseMarginProperties",value:function(e,t){O.foreach(e,function(e){switch(e.localName){case"left":t["padding-left"]=N.valueOfMargin(e);break;case"right":t["padding-right"]=N.valueOfMargin(e);break;case"top":t["padding-top"]=N.valueOfMargin(e);break;case"bottom":t["padding-bottom"]=N.valueOfMargin(e)}})}},{key:"parseTrHeight",value:function(e,t){T.attr(e,"hRule"),t.height=T.lengthAttr(e,"val")}},{key:"parseBorderProperties",value:function(e,t){O.foreach(e,function(e){switch(e.localName){case"start":case"left":t["border-left"]=N.valueOfBorder(e);break;case"end":case"right":t["border-right"]=N.valueOfBorder(e);break;case"top":t["border-top"]=N.valueOfBorder(e);break;case"bottom":t["border-bottom"]=N.valueOfBorder(e)}})}}]),$s),Gs=["black","blue","cyan","darkBlue","darkCyan","darkGray","darkGreen","darkMagenta","darkRed","darkYellow","green","lightGray","magenta","none","red","white","yellow"],O=(a(Ys,null,[{key:"foreach",value:function(e,t){for(var r=0;r<e.childNodes.length;r++){var n=e.childNodes[r];n.nodeType==Node.ELEMENT_NODE&&t(n)}}},{key:"colorAttr",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,n=3<arguments.length&&void 0!==arguments[3]?arguments[3]:"black",t=T.attr(e,t);return t?"auto"==t?n:Gs.includes(t)?t:"#".concat(t):(n=T.attr(e,"themeColor"))?"var(--docx-".concat(n,"-color)"):r}},{key:"sizeValue",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:E.Dxa;return Ui(e.textContent,t)}}]),Ys),N=(a(Js,null,[{key:"themeValue",value:function(e,t){e=T.attr(e,t);return e?"var(--docx-".concat(e,"-font)"):null}},{key:"valueOfSize",value:function(e,t){var r=E.Dxa;switch(T.attr(e,"type")){case"dxa":break;case"pct":r=E.Percent;break;case"auto":return"auto"}return T.lengthAttr(e,t,r)}},{key:"valueOfMargin",value:function(e){return T.lengthAttr(e,"w")}},{key:"valueOfBorder",value:function(e){var t;return"nil"==T.attr(e,"val")?"none":(t=O.colorAttr(e,"color"),"".concat(T.lengthAttr(e,"sz",E.Border)," solid ").concat("auto"==t?"black":t))}},{key:"valueOfTblLayout",value:function(e){return"fixed"==T.attr(e,"val")?"fixed":"auto"}},{key:"classNameOfCnfStyle",value:function(e){var r=T.attr(e,"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(function(e,t){return"1"==r[t]}).join(" ")}},{key:"valueOfJc",value:function(e){e=T.attr(e,"val");switch(e){case"start":case"left":return"left";case"center":return"center";case"end":case"right":return"right";case"both":return"justify"}return e}},{key:"valueOfVertAlign",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1],e=T.attr(e,"val");switch(e){case"subscript":return"sub";case"superscript":return t?"sup":"super"}return t?null:e}},{key:"valueOfTextAlignment",value:function(e){e=T.attr(e,"val");switch(e){case"auto":case"baseline":return"baseline";case"top":return"top";case"center":return"middle";case"bottom":return"bottom"}return e}},{key:"addSize",value:function(e,t){return null==e?t:null==t?e:"calc(".concat(e," + ").concat(t,")")}},{key:"classNameOftblLook",value:function(e){var t=T.hexAttr(e,"val",0),r="";return(T.boolAttr(e,"firstRow")||32&t)&&(r+=" first-row"),(T.boolAttr(e,"lastRow")||64&t)&&(r+=" last-row"),(T.boolAttr(e,"firstColumn")||128&t)&&(r+=" first-col"),(T.boolAttr(e,"lastColumn")||256&t)&&(r+=" last-col"),(T.boolAttr(e,"noHBand")||512&t)&&(r+=" no-hband"),(T.boolAttr(e,"noVBand")||1024&t)&&(r+=" no-vband"),r.trim()}}]),Js),Ks={pos:0,leader:"none",style:"left"};function Js(){n(this,Js)}function Ys(){n(this,Ys)}function $s(e){n(this,$s),this.options=S({ignoreWidth:!1,debug:!1},e)}function Qs(e){var t;return n(this,Qs),(t=Is.call(this)).id=e,t.type=A.CommentRangeEnd,t}function el(e){var t;return n(this,el),(t=Ls.call(this)).id=e,t.type=A.CommentRangeStart,t}function tl(e){var t;return n(this,tl),(t=zs.call(this)).id=e,t.type=A.CommentReference,t}function rl(){var e;return n(this,rl),(e=Fs.apply(this,arguments)).type=A.Comment,e}function nl(e){return parseFloat(e)}var B="http://www.w3.org/1998/Math/MathML",al=(a(il,[{key:"render",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,n=3<arguments.length?arguments[3]:void 0,a=(this.document=e,this.options=n,this.className=n.className,this.rootSelector=n.inWrapper?".".concat(this.className,"-wrapper"):":root",this.styleMap=null,this.tasks=[],this.options.renderComments&&globalThis.Highlight&&(this.commentHighlight=new Highlight),ll(r=r||t),ll(t),hl(r,"docxjs library predefined styles"),r.appendChild(this.renderDefaultStyle()),e.themePart&&(hl(r,"docxjs document theme values"),this.renderTheme(e.themePart,r)),null!=e.stylesPart&&(this.styleMap=this.processStyles(e.stylesPart.styles),hl(r,"docxjs document styles"),r.appendChild(this.renderStyles(e.stylesPart.styles))),e.numberingPart&&(this.prodessNumberings(e.numberingPart.domNumberings),hl(r,"docxjs document numbering styles"),r.appendChild(this.renderNumbering(e.numberingPart.domNumberings,r))),e.footnotesPart&&(this.footnoteMap=Qi(e.footnotesPart.notes,function(e){return e.id})),e.endnotesPart&&(this.endnoteMap=Qi(e.endnotesPart.notes,function(e){return e.id})),e.settingsPart&&(this.defaultTabSize=null==(a=e.settingsPart.settings)?void 0:a.defaultTabStop),!n.ignoreFonts&&e.fontTablePart&&this.renderFontTable(e.fontTablePart,r),this.renderSections(e.documentPart.body));this.options.inWrapper?t.appendChild(this.renderWrapper(a)):cl(t,a),this.commentHighlight&&n.renderComments&&CSS.highlights.set("".concat(this.className,"-comments"),this.commentHighlight),this.refreshTabStops(),this.postRenderTasks.forEach(function(e){return e()})}},{key:"renderTheme",value:function(e,t){var r={},n=null==(n=e.theme)?void 0:n.fontScheme,e=(n&&(n.majorFont&&(r["--docx-majorHAnsi-font"]=n.majorFont.latinTypeface),n.minorFont)&&(r["--docx-minorHAnsi-font"]=n.minorFont.latinTypeface),null==(n=e.theme)?void 0:n.colorScheme);if(e)for(var a=0,i=Object.entries(e.colors);a<i.length;a++){var o=V(i[a],2),s=o[0],o=o[1];r["--docx-".concat(s,"-color")]="#".concat(o)}n=this.styleToString(".".concat(this.className),r);t.appendChild(ul(n))}},{key:"renderFontTable",value:function(e,n){var a,i=this,t=x(e.fonts);try{var r=function(){var e,r=a.value,t=x(r.embedFontRefs);try{for(t.s();!(e=t.n()).done;)(()=>{var t=e.value;i.tasks.push(i.document.loadFont(t.id,t.key).then(function(e){e={"font-family":r.name,src:"url(".concat(e,")")},"bold"!=t.type&&"boldItalic"!=t.type||(e["font-weight"]="bold"),"italic"!=t.type&&"boldItalic"!=t.type||(e["font-style"]="italic"),hl(n,"docxjs ".concat(r.name," font")),e=i.styleToString("@font-face",e);n.appendChild(ul(e)),i.refreshTabStops()}))})()}catch(e){t.e(e)}finally{t.f()}};for(t.s();!(a=t.n()).done;)r()}catch(e){t.e(e)}finally{t.f()}}},{key:"processStyleName",value:function(e){return e?"".concat(this.className,"_").concat(null==e?void 0:e.replace(/[ .]+/g,"-").replace(/[&]+/g,"and").toLowerCase()):this.className}},{key:"processStyles",value:function(e){var t,r=this,n=Qi(e.filter(function(e){return null!=e.id}),function(e){return e.id}),a=x(e.filter(function(e){return e.basedOn}));try{for(a.s();!(t=a.n()).done;){var i=t.value,o=n[i.basedOn];if(o){i.paragraphProps=to(i.paragraphProps,o.paragraphProps),i.runProps=to(i.runProps,o.runProps);var s,l=x(o.styles);try{for(l.s();!(s=l.n()).done;)(()=>{var t=s.value,e=i.styles.find(function(e){return e.target==t.target});e?r.copyStyleProperties(t.values,e.values):i.styles.push(S(S({},t),{},{values:S({},t.values)}))})()}catch(e){l.e(e)}finally{l.f()}}else this.options.debug&&console.warn("Can't find base style ".concat(i.basedOn))}}catch(e){a.e(e)}finally{a.f()}var c,u=x(e);try{for(u.s();!(c=u.n()).done;){var h=c.value;h.cssName=this.processStyleName(h.id)}}catch(e){u.e(e)}finally{u.f()}return n}},{key:"prodessNumberings",value:function(e){var t,r=x(e.filter(function(e){return e.pStyleName}));try{for(r.s();!(t=r.n()).done;){var n,a=t.value,i=this.findStyle(a.pStyleName);null!=i&&null!=(n=i.paragraphProps)&&n.numbering&&(i.paragraphProps.numbering.level=a.level)}}catch(e){r.e(e)}finally{r.f()}}},{key:"processElement",value:function(e){if(e.children){var t,r=x(e.children);try{for(r.s();!(t=r.n()).done;){var n=t.value;n.parent=e,n.type==A.Table?this.processTable(n):this.processElement(n)}}catch(e){r.e(e)}finally{r.f()}}}},{key:"processTable",value:function(e){var t,r=x(e.children);try{for(r.s();!(t=r.n()).done;){var n,a=x(t.value.children);try{for(a.s();!(n=a.n()).done;){var i=n.value;i.cssStyle=this.copyStyleProperties(e.cellStyle,i.cssStyle,["border-left","border-right","border-top","border-bottom","padding-left","padding-right","padding-top","padding-bottom"]),this.processElement(i)}}catch(e){a.e(e)}finally{a.f()}}}catch(e){r.e(e)}finally{r.f()}}},{key:"copyStyleProperties",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(e){var n,a=x((null==t&&(t={}),r=null==r?Object.getOwnPropertyNames(e):r));try{for(a.s();!(n=a.n()).done;){var i=n.value;e.hasOwnProperty(i)&&!t.hasOwnProperty(i)&&(t[i]=e[i])}}catch(e){a.e(e)}finally{a.f()}}return t}},{key:"createPageElement",value:function(e,t){e=this.createElement("section",{className:e});return t&&(t.pageMargins&&(e.style.paddingLeft=t.pageMargins.left,e.style.paddingRight=t.pageMargins.right,e.style.paddingTop=t.pageMargins.top,e.style.paddingBottom=t.pageMargins.bottom),t.pageSize)&&(this.options.ignoreWidth||(e.style.width=t.pageSize.width),this.options.ignoreHeight||(e.style.minHeight=t.pageSize.height)),e}},{key:"createSectionContent",value:function(e){var t=this.createElement("article");return e.columns&&e.columns.numberOfColumns&&(t.style.columnCount="".concat(e.columns.numberOfColumns),t.style.columnGap=e.columns.space,e.columns.separator)&&(t.style.columnRule="1px solid black"),t}},{key:"renderSections",value:function(e){var t=[];this.processElement(e);for(var r=this.splitBySection(e.children,e.props),n=this.groupByPageBreaks(r),a=null,i=0,o=n.length;i<o;i++){this.currentFootnoteIds=[];var s=n[i][0].sectProps,l=this.createPageElement(this.className,s);this.renderStyleValues(e.cssStyle,l),this.options.renderHeaders&&this.renderHeaderFooter(s.headerRefs,s,t.length,a!=s,l);var c,u=x(n[i]);try{for(u.s();!(c=u.n()).done;){var h=c.value,d=this.createSectionContent(h.sectProps);this.renderElements(h.elements,d),l.appendChild(d),s=h.sectProps}}catch(e){u.e(e)}finally{u.f()}this.options.renderFootnotes&&this.renderNotes(this.currentFootnoteIds,this.footnoteMap,l),this.options.renderEndnotes&&i==o-1&&this.renderNotes(this.currentEndnoteIds,this.endnoteMap,l),this.options.renderFooters&&this.renderHeaderFooter(s.footerRefs,s,t.length,a!=s,l),t.push(l),a=s}return t}},{key:"renderHeaderFooter",value:function(e,t,r,n,a){e&&(n=(r=null!=(n=null!=(n=t.titlePage&&n?e.find(function(e){return"first"==e.type}):null)?n:r%2==1?e.find(function(e){return"even"==e.type}):null)?n:e.find(function(e){return"default"==e.type}))&&this.document.findPartByRelId(r.id,this.document.documentPart))&&(this.currentPart=n,this.usedHederFooterParts.includes(n.path)||(this.processElement(n.rootElement),this.usedHederFooterParts.push(n.path)),e=V(this.renderElements([n.rootElement],a),1)[0],null!=t&&t.pageMargins&&(n.rootElement.type===A.Header?(e.style.marginTop="calc(".concat(t.pageMargins.header," - ").concat(t.pageMargins.top,")"),e.style.minHeight="calc(".concat(t.pageMargins.top," - ").concat(t.pageMargins.header,")")):n.rootElement.type===A.Footer&&(e.style.marginBottom="calc(".concat(t.pageMargins.footer," - ").concat(t.pageMargins.bottom,")"),e.style.minHeight="calc(".concat(t.pageMargins.bottom," - ").concat(t.pageMargins.footer,")"))),this.currentPart=null)}},{key:"isPageBreakElement",value:function(e){return e.type==A.Break&&("lastRenderedPageBreak"==e.break?!this.options.ignoreLastRenderedPageBreak:"page"==e.break)}},{key:"isPageBreakSection",value:function(e,t){var r;return!(!e||!t||(null==(r=e.pageSize)?void 0:r.orientation)==(null==(r=t.pageSize)?void 0:r.orientation)&&(null==(r=e.pageSize)?void 0:r.width)==(null==(r=t.pageSize)?void 0:r.width)&&(null==(r=e.pageSize)?void 0:r.height)==(null==(e=t.pageSize)?void 0:e.height))}},{key:"splitBySection",value:function(e,t){var r,n=this,a={sectProps:null,elements:[],pageBreak:!1},i=[a],o=x(e);try{for(o.s();!(r=o.n()).done;){var s,l,c,u,h,d,f,p,m,g,y,b,v=r.value;v.type==A.Paragraph&&null!=(l=this.findStyle(v.styleName))&&null!=(s=l.paragraphProps)&&s.pageBreakBefore&&(a.sectProps=u,a.pageBreak=!0,i.push(a={sectProps:null,elements:[],pageBreak:!1})),a.elements.push(v),v.type==A.Paragraph&&(u=(c=v).sectionProps,d=h=-1,this.options.breakPages&&c.children&&(h=c.children.findIndex(function(e){return-1!=(d=null!=(e=null==(e=e.children)?void 0:e.findIndex(n.isPageBreakElement.bind(n)))?e:-1)})),!u&&-1==h||(a.sectProps=u,a.pageBreak=-1!=h,i.push(a={sectProps:null,elements:[],pageBreak:!1})),-1!=h)&&(f=c.children[h],p=d<f.children.length-1,h<c.children.length-1||p)&&(m=v.children,g=S(S({},v),{},{children:m.slice(h)}),v.children=m.slice(0,h),a.elements.push(g),p)&&(y=f.children,b=S(S({},f),{},{children:y.slice(0,d)}),v.children.push(b),f.children=y.slice(d))}}catch(e){o.e(e)}finally{o.f()}for(var w,k=null,_=i.length-1;0<=_;_--)null==i[_].sectProps?i[_].sectProps=null!=(w=k)?w:t:k=i[_].sectProps;return i}},{key:"groupByPageBreaks",value:function(e){var t,r,n=[],a=[n],i=x(e);try{for(i.s();!(r=i.n()).done;){var o=r.value;n.push(o),(this.options.ignoreLastRenderedPageBreak||o.pageBreak||this.isPageBreakSection(t,o.sectProps))&&a.push(n=[]),t=o.sectProps}}catch(e){i.e(e)}finally{i.f()}return a.filter(function(e){return 0<e.length})}},{key:"renderWrapper",value:function(e){return this.createElement("div",{className:"".concat(this.className,"-wrapper")},e)}},{key:"renderDefaultStyle",value:function(){var e=this.className,t="\n.".concat(e,"-wrapper { background: gray; padding: 30px; padding-bottom: 0px; display: flex; flex-flow: column; align-items: center; } \n.").concat(e,"-wrapper>section.").concat(e," { background: white; box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); margin-bottom: 30px; }\n.").concat(e," { color: black; hyphens: auto; text-underline-position: from-font; }\nsection.").concat(e," { box-sizing: border-box; display: flex; flex-flow: column nowrap; position: relative; overflow: hidden; }\nsection.").concat(e,">article { margin-bottom: auto; z-index: 1; }\nsection.").concat(e,">footer { z-index: 1; }\n.").concat(e," table { border-collapse: collapse; }\n.").concat(e," table td, .").concat(e," table th { vertical-align: top; }\n.").concat(e," p { margin: 0pt; min-height: 1em; }\n.").concat(e," span { white-space: pre-wrap; overflow-wrap: break-word; }\n.").concat(e," a { color: inherit; text-decoration: inherit; }\n.").concat(e," svg { fill: transparent; }\n");return this.options.renderComments&&(t+="\n.".concat(e,"-comment-ref { cursor: default; }\n.").concat(e,"-comment-popover { display: none; z-index: 1000; padding: 0.5rem; background: white; position: absolute; box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.25); width: 30ch; }\n.").concat(e,"-comment-ref:hover~.").concat(e,"-comment-popover { display: block; }\n.").concat(e,"-comment-author,.").concat(e,"-comment-date { font-size: 0.875rem; color: #888; }\n")),ul(t)}},{key:"renderNumbering",value:function(e,n){var a,i=this,o="",s=[],t=x(e);try{var l,c,u;for(t.s();!(a=t.n()).done;)(()=>{var t,e,r;l=a.value,c="p.".concat(i.numberingClass(l.id,l.level)),u="none",l.bullet?(t="--".concat(i.className,"-").concat(l.bullet.src).toLowerCase(),o+=i.styleToString("".concat(c,":before"),{content:"' '",display:"inline-block",background:"var(".concat(t,")")},l.bullet.style),i.tasks.push(i.document.loadNumberingImage(l.bullet.src).then(function(e){e="".concat(i.rootSelector," { ").concat(t,": url(").concat(e,") }");n.appendChild(ul(e))}))):l.levelText?(r=(e=i.numberingCounter(l.id,l.level))+" "+(l.start-1),0<l.level&&(o+=i.styleToString("p.".concat(i.numberingClass(l.id,l.level-1)),{"counter-reset":r})),s.push(r),o+=i.styleToString("".concat(c,":before"),S({content:i.levelTextToContent(l.levelText,l.suff,l.id,i.numFormatToCssValue(l.format)),"counter-increment":e},l.rStyle))):u=i.numFormatToCssValue(l.format),o+=i.styleToString(c,S({display:"list-item","list-style-position":"inside","list-style-type":u},l.pStyle))})()}catch(e){t.e(e)}finally{t.f()}return 0<s.length&&(o+=this.styleToString(this.rootSelector,{"counter-reset":s.join(" ")})),ul(o)}},{key:"renderStyles",value:function(e){var t,r="",n=this.styleMap,a=Qi(e.filter(function(e){return e.isDefault}),function(e){return e.target}),i=x(e);try{for(i.s();!(t=i.n()).done;){var o,s=t.value,l=s.styles;s.linked&&((o=s.linked&&n[s.linked])?l=l.concat(o.styles):this.options.debug&&console.warn("Can't find linked style ".concat(s.linked)));var c,u=x(l);try{for(u.s();!(c=u.n()).done;){var h,d=c.value,f="".concat(null!=(h=s.target)?h:"",".").concat(s.cssName);s.target!=d.target&&(f+=" ".concat(d.target)),a[s.target]==s&&(f=".".concat(this.className," ").concat(s.target,", ")+f),r+=this.styleToString(f,d.values)}}catch(e){u.e(e)}finally{u.f()}}}catch(e){i.e(e)}finally{i.f()}return ul(r)}},{key:"renderNotes",value:function(e,t,r){var e=e.map(function(e){return t[e]}).filter(function(e){return e});0<e.length&&(e=this.createElement("ol",null,this.renderElements(e)),r.appendChild(e))}},{key:"renderElement",value:function(e){switch(e.type){case A.Paragraph:return this.renderParagraph(e);case A.BookmarkStart:return this.renderBookmarkStart(e);case A.BookmarkEnd:return null;case A.Run:return this.renderRun(e);case A.Table:return this.renderTable(e);case A.Row:return this.renderTableRow(e);case A.Cell:return this.renderTableCell(e);case A.Hyperlink:return this.renderHyperlink(e);case A.SmartTag:return this.renderSmartTag(e);case A.Drawing:return this.renderDrawing(e);case A.Image:return this.renderImage(e);case A.Text:case A.Text:return this.renderText(e);case A.DeletedText:return this.renderDeletedText(e);case A.Tab:return this.renderTab(e);case A.Symbol:return this.renderSymbol(e);case A.Break:return this.renderBreak(e);case A.Footer:return this.renderContainer(e,"footer");case A.Header:return this.renderContainer(e,"header");case A.Footnote:case A.Endnote:return this.renderContainer(e,"li");case A.FootnoteReference:return this.renderFootnoteReference(e);case A.EndnoteReference:return this.renderEndnoteReference(e);case A.NoBreakHyphen:return this.createElement("wbr");case A.VmlPicture:return this.renderVmlPicture(e);case A.VmlElement:return this.renderVmlElement(e);case A.MmlMath:return this.renderContainerNS(e,B,"math",{xmlns:B});case A.MmlMathParagraph:return this.renderContainer(e,"span");case A.MmlFraction:return this.renderContainerNS(e,B,"mfrac");case A.MmlBase:return this.renderContainerNS(e,B,e.parent.type==A.MmlMatrixRow?"mtd":"mrow");case A.MmlNumerator:case A.MmlDenominator:case A.MmlFunction:case A.MmlLimit:case A.MmlBox:return this.renderContainerNS(e,B,"mrow");case A.MmlGroupChar:return this.renderMmlGroupChar(e);case A.MmlLimitLower:return this.renderContainerNS(e,B,"munder");case A.MmlMatrix:return this.renderContainerNS(e,B,"mtable");case A.MmlMatrixRow:return this.renderContainerNS(e,B,"mtr");case A.MmlRadical:return this.renderMmlRadical(e);case A.MmlSuperscript:return this.renderContainerNS(e,B,"msup");case A.MmlSubscript:return this.renderContainerNS(e,B,"msub");case A.MmlDegree:case A.MmlSuperArgument:case A.MmlSubArgument:return this.renderContainerNS(e,B,"mn");case A.MmlFunctionName:return this.renderContainerNS(e,B,"ms");case A.MmlDelimiter:return this.renderMmlDelimiter(e);case A.MmlRun:return this.renderMmlRun(e);case A.MmlNary:return this.renderMmlNary(e);case A.MmlPreSubSuper:return this.renderMmlPreSubSuper(e);case A.MmlBar:return this.renderMmlBar(e);case A.MmlEquationArray:return this.renderMllList(e);case A.Inserted:return this.renderInserted(e);case A.Deleted:return this.renderDeleted(e);case A.CommentRangeStart:return this.renderCommentRangeStart(e);case A.CommentRangeEnd:return this.renderCommentRangeEnd(e);case A.CommentReference:return this.renderCommentReference(e)}return null}},{key:"renderChildren",value:function(e,t){return this.renderElements(e.children,t)}},{key:"renderElements",value:function(e,t){var r=this;return null==e?null:(e=e.flatMap(function(e){return r.renderElement(e)}).filter(function(e){return null!=e}),t&&cl(t,e),e)}},{key:"renderContainer",value:function(e,t,r){return this.createElement(t,r,this.renderChildren(e))}},{key:"renderContainerNS",value:function(e,t,r,n){return D(t,r,n,this.renderChildren(e))}},{key:"renderParagraph",value:function(e){var t=this.createElement("p"),r=this.findStyle(e.styleName),n=(null==e.tabs&&(e.tabs=null==r||null==(n=r.paragraphProps)?void 0:n.tabs),this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),this.renderCommonProperties(t.style,e),null!=(n=e.numbering)?n:null==r||null==(e=r.paragraphProps)?void 0:e.numbering);return n&&t.classList.add(this.numberingClass(n.id,n.level)),t}},{key:"renderRunProperties",value:function(e,t){this.renderCommonProperties(e,t)}},{key:"renderCommonProperties",value:function(e,t){null!=t&&(t.color&&(e.color=t.color),t.fontSize)&&(e["font-size"]=t.fontSize)}},{key:"renderHyperlink",value:function(t){var e,r=this.createElement("a");return this.renderChildren(t,r),this.renderStyleValues(t.cssStyle,r),t.href?r.href=t.href:t.id&&(e=this.document.documentPart.rels.find(function(e){return e.id==t.id&&"External"===e.targetMode}),r.href=null==e?void 0:e.target),r}},{key:"renderSmartTag",value:function(e){var t=this.createElement("span");return this.renderChildren(e,t),t}},{key:"renderCommentRangeStart",value:function(e){var t,r,n;return this.options.renderComments?(r=new Range,null!=(t=this.commentHighlight)&&t.add(r),n=this.htmlDocument.createComment("start of comment #".concat(e.id)),this.later(function(){return r.setStart(n,0)}),this.commentMap[e.id]=r,n):null}},{key:"renderCommentRangeEnd",value:function(e){var t,r;return this.options.renderComments?(t=this.commentMap[e.id],r=this.htmlDocument.createComment("end of comment #".concat(e.id)),this.later(function(){return null==t?void 0:t.setEnd(r,0)}),r):null}},{key:"renderCommentReference",value:function(e){var t,r,n;return this.options.renderComments&&(t=null==(t=this.document.commentsPart)?void 0:t.commentMap[e.id])?(e=new DocumentFragment,r=ol("span",{className:"".concat(this.className,"-comment-ref")},["💬"]),n=ol("div",{className:"".concat(this.className,"-comment-popover")}),this.renderCommentContent(t,n),e.appendChild(this.htmlDocument.createComment("comment #".concat(t.id," by ").concat(t.author," on ").concat(t.date))),e.appendChild(r),e.appendChild(n),e):null}},{key:"renderCommentContent",value:function(e,t){t.appendChild(ol("div",{className:"".concat(this.className,"-comment-author")},[e.author])),t.appendChild(ol("div",{className:"".concat(this.className,"-comment-date")},[new Date(e.date).toLocaleString()])),this.renderChildren(e,t)}},{key:"renderDrawing",value:function(e){var t=this.createElement("div");return t.style.display="inline-block",t.style.position="relative",t.style.textIndent="0px",this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),t}},{key:"renderImage",value:function(e){var t=this.createElement("img");return this.renderStyleValues(e.cssStyle,t),this.document&&this.tasks.push(this.document.loadDocumentImage(e.src,this.currentPart).then(function(e){t.src=e})),t}},{key:"renderText",value:function(e){return this.htmlDocument.createTextNode(e.text)}},{key:"renderDeletedText",value:function(e){return this.options.renderEndnotes?this.htmlDocument.createTextNode(e.text):null}},{key:"renderBreak",value:function(e){return"textWrapping"==e.break?this.createElement("br"):null}},{key:"renderInserted",value:function(e){return this.options.renderChanges?this.renderContainer(e,"ins"):this.renderChildren(e)}},{key:"renderDeleted",value:function(e){return this.options.renderChanges?this.renderContainer(e,"del"):null}},{key:"renderSymbol",value:function(e){var t=this.createElement("span");return t.style.fontFamily=e.font,t.innerHTML="&#x".concat(e.char,";"),t}},{key:"renderFootnoteReference",value:function(e){var t=this.createElement("sup");return this.currentFootnoteIds.push(e.id),t.textContent="".concat(this.currentFootnoteIds.length),t}},{key:"renderEndnoteReference",value:function(e){var t=this.createElement("sup");return this.currentEndnoteIds.push(e.id),t.textContent="".concat(this.currentEndnoteIds.length),t}},{key:"renderTab",value:function(r){var e,t=this.createElement("span");return t.innerHTML="&emsp;",this.options.experimental&&(t.className=this.tabStopClass(),e=null==(e=(e=>{for(var t=r.parent;null!=t&&t.type!=e;)t=t.parent;return t})(A.Paragraph))?void 0:e.tabs,this.currentTabs.push({stops:e,span:t})),t}},{key:"renderBookmarkStart",value:function(e){var t=this.createElement("span");return t.id=e.name,t}},{key:"renderRun",value:function(e){var t,r;return e.fieldRun?null:(t=this.createElement("span"),e.id&&(t.id=e.id),this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),e.verticalAlign?(r=this.createElement(e.verticalAlign),this.renderChildren(e,r),t.appendChild(r)):this.renderChildren(e,t),t)}},{key:"renderTable",value:function(e){var t=this.createElement("table");return this.tableCellPositions.push(this.currentCellPosition),this.tableVerticalMerges.push(this.currentVerticalMerge),this.currentVerticalMerge={},this.currentCellPosition={col:0,row:0},e.columns&&t.appendChild(this.renderTableColumns(e.columns)),this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),this.currentVerticalMerge=this.tableVerticalMerges.pop(),this.currentCellPosition=this.tableCellPositions.pop(),t}},{key:"renderTableColumns",value:function(e){var t,r=this.createElement("colgroup"),n=x(e);try{for(n.s();!(t=n.n()).done;){var a=t.value,i=this.createElement("col");a.width&&(i.style.width=a.width),r.appendChild(i)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"renderTableRow",value:function(e){var t=this.createElement("tr");return this.currentCellPosition.col=0,this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),this.currentCellPosition.row++,t}},{key:"renderTableCell",value:function(e){var t=this.createElement("td"),r=this.currentCellPosition.col;return e.verticalMerge?"restart"==e.verticalMerge?(this.currentVerticalMerge[r]=t).rowSpan=1:this.currentVerticalMerge[r]&&(this.currentVerticalMerge[r].rowSpan+=1,t.style.display="none"):this.currentVerticalMerge[r]=null,this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),e.span&&(t.colSpan=e.span),this.currentCellPosition.col+=t.colSpan,t}},{key:"renderVmlPicture",value:function(e){var t=ol("div");return this.renderChildren(e,t),t}},{key:"renderVmlElement",value:function(e){var t,r=sl("svg"),n=(r.setAttribute("style",e.cssStyleText),this.renderVmlChildElement(e));return null!=(t=e.imageHref)&&t.id&&this.tasks.push(null==(t=this.document)?void 0:t.loadDocumentImage(e.imageHref.id,this.currentPart).then(function(e){return n.setAttribute("href",e)})),r.appendChild(n),requestAnimationFrame(function(){var e=r.firstElementChild.getBBox();r.setAttribute("width","".concat(Math.ceil(e.x+e.width))),r.setAttribute("height","".concat(Math.ceil(e.y+e.height)))}),r}},{key:"renderVmlChildElement",value:function(e){var r=sl(e.tagName);Object.entries(e.attrs).forEach(function(e){var e=V(e,2),t=e[0];return r.setAttribute(t,e[1])});var t,n=x(e.children);try{for(n.s();!(t=n.n()).done;){var a=t.value;a.type==A.VmlElement?r.appendChild(this.renderVmlChildElement(a)):r.appendChild.apply(r,q(ro(this.renderElement(a))))}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"renderMmlRadical",value:function(e){var t,r=e.children.find(function(e){return e.type==A.MmlBase});return null!=(t=e.props)&&t.hideDegree?D(B,"msqrt",null,this.renderElements([r])):(t=e.children.find(function(e){return e.type==A.MmlDegree}),D(B,"mroot",null,this.renderElements([r,t])))}},{key:"renderMmlDelimiter",value:function(e){var t,r=[];return r.push(D(B,"mo",null,[null!=(t=e.props.beginChar)?t:"("])),r.push.apply(r,q(this.renderElements(e.children))),r.push(D(B,"mo",null,[null!=(t=e.props.endChar)?t:")"])),D(B,"mrow",null,r)}},{key:"renderMmlNary",value:function(e){var t=[],r=Qi(e.children,function(e){return e.type}),n=r[A.MmlSuperArgument],a=r[A.MmlSubArgument],n=n?D(B,"mo",null,ro(this.renderElement(n))):null,a=a?D(B,"mo",null,ro(this.renderElement(a))):null,e=D(B,"mo",null,[null!=(e=null==(e=e.props)?void 0:e.char)?e:"∫"]);return t.push(n||a?D(B,"munderover",null,[e,a,n]):n?D(B,"mover",null,[e,n]):a?D(B,"munder",null,[e,a]):e),t.push.apply(t,q(this.renderElements(r[A.MmlBase].children))),D(B,"mrow",null,t)}},{key:"renderMmlPreSubSuper",value:function(e){var t=[],e=Qi(e.children,function(e){return e.type}),r=e[A.MmlSuperArgument],n=e[A.MmlSubArgument],r=r?D(B,"mo",null,ro(this.renderElement(r))):null,n=n?D(B,"mo",null,ro(this.renderElement(n))):null,a=D(B,"mo",null);return t.push(D(B,"msubsup",null,[a,n,r])),t.push.apply(t,q(this.renderElements(e[A.MmlBase].children))),D(B,"mrow",null,t)}},{key:"renderMmlGroupChar",value:function(e){var t="bot"===e.props.verticalJustification?"mover":"munder",t=this.renderContainerNS(e,B,t);return e.props.char&&t.appendChild(D(B,"mo",null,[e.props.char])),t}},{key:"renderMmlBar",value:function(e){var t=this.renderContainerNS(e,B,"mrow");switch(e.props.position){case"top":t.style.textDecoration="overline";break;case"bottom":t.style.textDecoration="underline"}return t}},{key:"renderMmlRun",value:function(e){var t=D(B,"ms");return this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),this.renderChildren(e,t),t}},{key:"renderMllList",value:function(e){var t=D(B,"mtable");this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),this.renderChildren(e);var r,n=x(this.renderChildren(e));try{for(n.s();!(r=n.n()).done;){var a=r.value;t.appendChild(D(B,"mtr",null,[D(B,"mtd",null,[a])]))}}catch(e){n.e(e)}finally{n.f()}return t}},{key:"renderStyleValues",value:function(e,t){for(var r in e)r.startsWith("$")?t.setAttribute(r.slice(1),e[r]):t.style[r]=e[r]}},{key:"renderClass",value:function(e,t){e.className&&(t.className=e.className),e.styleName&&t.classList.add(this.processStyleName(e.styleName))}},{key:"findStyle",value:function(e){var t;return e&&(null==(t=this.styleMap)?void 0:t[e])}},{key:"numberingClass",value:function(e,t){return"".concat(this.className,"-num-").concat(e,"-").concat(t)}},{key:"tabStopClass",value:function(){return"".concat(this.className,"-tab-stop")}},{key:"styleToString",value:function(e,t){var r,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,a="".concat(e," {\r\n");for(r in t)r.startsWith("$")||(a+=" ".concat(r,": ").concat(t[r],";\r\n"));return n&&(a+=n),a+"}\r\n"}},{key:"numberingCounter",value:function(e,t){return"".concat(this.className,"-num-").concat(e,"-").concat(t)}},{key:"levelTextToContent",value:function(e,t,r,n){var a=this;return'"'.concat(e.replace(/%\d*/g,function(e){e=parseInt(e.substring(1),10)-1;return'"counter('.concat(a.numberingCounter(r,e),", ").concat(n,')"')})).concat(null!=(e={tab:"\\9",space:"\\a0"}[t])?e:"",'"')}},{key:"numFormatToCssValue",value:function(e){var t;return null!=(t={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"}[e])?t:e}},{key:"refreshTabStops",value:function(){var a=this;this.options.experimental&&(clearTimeout(this.tabsTimeout),this.tabsTimeout=setTimeout(function(){var e,t=function(e){var e=0<arguments.length&&void 0!==e?e:document.body,t=document.createElement("div"),r=(t.style.width="100pt",e.appendChild(t),100/t.offsetWidth);return e.removeChild(t),r}(),r=x(a.currentTabs);try{for(r.s();!(e=r.n()).done;){var n=e.value;!function(e,t,r,n){var n=3<arguments.length&&void 0!==n?n:.75,a=e.closest("p"),i=e.getBoundingClientRect(),o=a.getBoundingClientRect(),s=getComputedStyle(a),l=0<(null==t?void 0:t.length)?t.map(function(e){return{pos:nl(e.position),leader:e.leader,style:e.style}}).sort(function(e,t){return e.pos-t.pos}):[Ks],t=l[l.length-1],c=o.width*n,u=nl(r),h=t.pos+u;if(h<c)for(;h<c&&l.length<50;h+=u)l.push(S(S({},Ks),{},{pos:h}));var r=parseFloat(s.marginLeft),t=o.left+r,d=(i.left-t)*n;if(null!=(s=l.find(function(e){return"clear"!=e.style&&e.pos>d}))){var f,p,i=1;switch(i="right"==s.style||"center"==s.style?(p=(t=Array.from(a.querySelectorAll(".".concat(e.className)))).indexOf(e)+1,(f=document.createRange()).setStart(e,1),p<t.length?f.setEndBefore(t[p]):f.setEndAfter(a),t="center"==s.style?.5:1,a=(p=f.getBoundingClientRect()).left+t*p.width-(o.left-r),s.pos-a*n):s.pos-d,e.innerHTML="&nbsp;",e.style.textDecoration="inherit",e.style.wordSpacing="".concat(i.toFixed(0),"pt"),s.leader){case"dot":case"middleDot":e.style.textDecoration="underline",e.style.textDecorationStyle="dotted";break;case"hyphen":case"heavy":case"underscore":e.style.textDecoration="underline"}}}(n.span,n.stops,a.defaultTabSize,t)}}catch(e){r.e(e)}finally{r.f()}},500))}},{key:"later",value:function(e){this.postRenderTasks.push(e)}}]),il);function il(e){n(this,il),this.htmlDocument=e,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.commentMap={},this.tasks=[],this.postRenderTasks=[],this.createElement=ol}function ol(e,t,r){return D(void 0,e,t,r)}function sl(e,t,r){return D("http://www.w3.org/2000/svg",e,t,r)}function D(e,t,r,n){e=e?document.createElementNS(e,t):document.createElement(t);return Object.assign(e,r),n&&cl(e,n),e}function ll(e){e.innerHTML=""}function cl(t,e){e.forEach(function(e){return t.appendChild("string"==typeof e||e instanceof String?document.createTextNode(e):e)})}function ul(e){return ol("style",{innerHTML:e})}function hl(e,t){e.appendChild(document.createComment(t))}var dl={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,renderChanges:!1,renderComments:!1};function fl(){return(fl=$(P().mark(function e(n,a,i,o){var s;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:e.next=2;var t=n,r=o;return r=S(S({},dl),r),Es.load(t,new Xs(r),r);case 2:return s=e.sent,e.next=5,(()=>{var a=$(P().mark(function e(t,r,n,a){var i,o;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=S(S({},dl),a),o=new al(window.document),e.abrupt("return",(o.render(t,r,n,i),Promise.allSettled(o.tasks)));case 2:case"end":return e.stop()}},e)}));return function(e,t,r,n){return a.apply(this,arguments)}})()(s,a,i,o);case 5:return e.abrupt("return",s);case 6:case"end":return e.stop()}},e)}))).apply(this,arguments)}var pl,ml={ignoreLastRenderedPageBreak:!1},gl={getData:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e?fetch(e,t).then(function(e){return 200!==e.status?Promise.reject(e):e}):Promise.resolve(e)},render:function(e,t){var r,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};return e?(e instanceof Blob?r=e:e instanceof Response?r=e.blob():e instanceof ArrayBuffer&&(r=new Blob([e])),function(){return fl.apply(this,arguments)}(r,t,t,S(S({},ml),n))):(t.innerHTML="",Promise.resolve())},getBlob:(pl=$(P().mark(function e(t){var r;return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:t instanceof Blob?(r=t,e.next=11):e.next=4;break;case 4:if(t instanceof Response)return e.next=7,t.blob();e.next=10;break;case 7:r=e.sent,e.next=11;break;case 10:t instanceof ArrayBuffer&&(r=new Blob([t]));case 11:return e.abrupt("return",r);case 12:case"end":return e.stop()}},e)})),function(e){return pl.apply(this,arguments)})};function yl(){return(yl=$(P().mark(function e(a,i){return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i&&(i instanceof ArrayBuffer&&(i=new Blob([i])),t=a,r=URL.createObjectURL(i),n=void 0,(n=document.createElement("a")).download=t,n.style.display="none",n.href=r,document.body.appendChild(n),n.click(),document.body.removeChild(n));case 1:case"end":return e.stop()}var t,r,n},e)}))).apply(this,arguments)}a(wl,[{key:"createWrapper",value:function(){this.wrapper=document.createElement("div"),this.wrapper.className="vue-office-docx",this.wrapperMain=document.createElement("div"),this.wrapperMain.className="vue-office-docx-main",this.wrapper.appendChild(this.wrapperMain),this.container.appendChild(this.wrapper)}},{key:"setOptions",value:function(e){this.options=e}},{key:"setRequestOptions",value:function(e){this.requestOptions=e}},{key:"preview",value:function(e){var a=this;return new Promise(function(r,n){var t;gl.getData(e,a.requestOptions).then((t=$(P().mark(function e(t){return P().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,gl.getBlob(t);case 2:a.fileData=e.sent,gl.render(a.fileData,a.wrapperMain,a.options).then(function(){r()}).catch(function(e){gl.render("",a.wrapperMain,a.options),n(e)});case 4:case"end":return e.stop()}},e)})),function(e){return t.apply(this,arguments)})).catch(function(e){gl.render("",a.wrapperMain,a.options),n(e)})})}},{key:"save",value:function(e){!function(){yl.apply(this,arguments)}(e||"js-preview-docx-".concat((new Date).getTime(),".docx"),this.fileData)}},{key:"destroy",value:function(){this.container.removeChild(this.wrapper),this.container=null,this.wrapper=null,this.wrapperMain=null,this.options=null,this.requestOptions=null}}]);var bl=wl,vl={init:function(e,t,r){return new bl(e,t,r)}};function wl(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};n(this,wl),Z(this,"container",null),Z(this,"wrapper",null),Z(this,"wrapperMain",null),Z(this,"options",{}),Z(this,"requestOptions",{}),Z(this,"fileData",null),this.container=e,this.options=t,this.requestOptions=r,this.createWrapper()}}.call(this,_l(32),_l(318),_l(563).setImmediate,_l(557).Buffer)},890:function(e,t,r){e.exports=n;var u=r(577).EventEmitter;function n(){u.call(this)}r(566)(n,u),n.Readable=r(597),n.Writable=r(898),n.Duplex=r(899),n.Transform=r(900),n.PassThrough=r(901),(n.Stream=n).prototype.pipe=function(t,e){var r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function a(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",a),t._isStdio||e&&!1===e.end||(r.on("end",o),r.on("close",s));var i=!1;function o(){i||(i=!0,t.end())}function s(){i||(i=!0,"function"==typeof t.destroy&&t.destroy())}function l(e){if(c(),0===u.listenerCount(this,"error"))throw e}function c(){r.removeListener("data",n),t.removeListener("drain",a),r.removeListener("end",o),r.removeListener("close",s),r.removeListener("error",l),t.removeListener("error",l),r.removeListener("end",c),r.removeListener("close",c),t.removeListener("close",c)}return r.on("error",l),t.on("error",l),r.on("end",c),r.on("close",c),t.on("close",c),t.emit("pipe",r),t}},891:function(e,t){var r={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==r.call(e)}},892:function(e,t){},893:function(e,t,r){var i=r(598).Buffer,n=r(894);function a(){if(!(this instanceof a))throw new TypeError("Cannot call a class as a function");this.head=null,this.tail=null,this.length=0}e.exports=(a.prototype.push=function(e){e={data:e,next:null};0<this.length?this.tail.next=e:this.head=e,this.tail=e,++this.length},a.prototype.unshift=function(e){e={data:e,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},a.prototype.shift=function(){var e;if(0!==this.length)return e=this.head.data,1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e},a.prototype.clear=function(){this.head=this.tail=null,this.length=0},a.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},a.prototype.concat=function(e){if(0===this.length)return i.alloc(0);for(var t,r=i.allocUnsafe(e>>>0),n=this.head,a=0;n;)t=a,n.data.copy(r,t),a+=n.data.length,n=n.next;return r},a),n&&n.inspect&&n.inspect.custom&&(e.exports.prototype[n.inspect.custom]=function(){var e=n.inspect({length:this.length});return this.constructor.name+" "+e})},894:function(e,t){},895:function(e,t,r){!function(r){function n(e){try{if(!r.localStorage)return}catch(e){return}var t=r.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){var r;return n("noDeprecation")?e:(r=!1,function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)})}}.call(this,r(32))},896:function(e,t,r){var n=r(557),a=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=n:(i(n,t),t.Buffer=o),o.prototype=Object.create(a.prototype),i(a,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");e=a(e);return void 0!==t?"string"==typeof r?e.fill(t,r):e.fill(t):e.fill(0),e},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},897:function(e,t,r){e.exports=a;var n=r(659),e=Object.create(r(570));function a(e){if(!(this instanceof a))return new a(e);n.call(this,e)}e.inherits=r(566),e.inherits(a,n),a.prototype._transform=function(e,t,r){r(null,e)}},898:function(e,t,r){e.exports=r(599)},899:function(e,t,r){e.exports=r(559)},900:function(e,t,r){e.exports=r(597).Transform},901:function(e,t,r){e.exports=r(597).PassThrough},902:function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},903:function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;function r(){}r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},904:function(e,t,r){var n=r(905);"string"==typeof n&&(n=[[e.i,n,""]]);r(91)(n,{insertAt:"top",hmr:!0,transform:void 0,insertInto:void 0}),n.locals&&(e.exports=n.locals)},905:function(e,t,r){(t=r(90)(!1)).push([e.i,".vue-office-docx {\n height: 100%;\n overflow-y: auto;\n}\n.vue-office-docx .docx-wrapper > section.docx {\n margin-bottom: 5px;\n}\n@media screen and (max-width: 800px) {\n .vue-office-docx .docx-wrapper {\n padding: 10px;\n }\n .vue-office-docx .docx-wrapper > section.docx {\n padding: 10px!important;\n width: 100% !important;\n }\n}\n",""]),e.exports=t}}]);
1
+ /*! For license information please see async-feffery_word_preview.js.LICENSE.txt */
2
+ (window.webpackJsonpfeffery_utils_components=window.webpackJsonpfeffery_utils_components||[]).push([[33],{518:function(e,t,r){"use strict";r.r(t);var n=r(889),i=r(1),a=(r(904),r(63)),o=r(25),s=r(227),l=function(e){var t=e.id,r=e.style,s=e.className,l=e.src,u=(e.setProps,e.loading_state),c=Object(i.useRef)(null);return Object(i.useEffect)((function(){if(c.current){var e=n.a.init(c.current,{});return e.preview(l).then((function(e){})).catch((function(e){})),function(){e.destroy()}}}),[l]),React.createElement("div",{id:t,className:Object(o.isString)(s)?s:s?Object(a.a)(s):void 0,style:r,ref:c,"data-dash-is-loading":u&&u.is_loading||void 0})};t.default=l,l.defaultProps=s.b,l.propTypes=s.c},559:function(e,t,r){"use strict";var n=r(578),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=h;var a=Object.create(r(570));a.inherits=r(566);var o=r(655),s=r(599);a.inherits(h,o);for(var l=i(s.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=s.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);o.call(this,e),s.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||n.nextTick(d,this)}function d(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),n.nextTick(t,e)}},566:function(e,t){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},570:function(e,t,r){function n(e){return Object.prototype.toString.call(e)}t.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===n(e)},t.isBoolean=function(e){return"boolean"==typeof e},t.isNull=function(e){return null===e},t.isNullOrUndefined=function(e){return null==e},t.isNumber=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=function(e){return void 0===e},t.isRegExp=function(e){return"[object RegExp]"===n(e)},t.isObject=function(e){return"object"==typeof e&&null!==e},t.isDate=function(e){return"[object Date]"===n(e)},t.isError=function(e){return"[object Error]"===n(e)||e instanceof Error},t.isFunction=function(e){return"function"==typeof e},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(557).Buffer.isBuffer},577:function(e,t,r){"use strict";var n,i="object"==typeof Reflect?Reflect:null,a=i&&"function"==typeof i.apply?i.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};n=i&&"function"==typeof i.ownKeys?i.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function s(){s.init.call(this)}e.exports=s,e.exports.once=function(e,t){return new Promise((function(r,n){function i(r){e.removeListener(t,a),n(r)}function a(){"function"==typeof e.removeListener&&e.removeListener("error",i),r([].slice.call(arguments))}v(e,t,a,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&v(e,"error",t,r)}(e,i,{once:!0})}))},s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var l=10;function u(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function c(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function h(e,t,r,n){var i,a,o,s;if(u(r),void 0===(a=e._events)?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),a=e._events),o=a[t]),void 0===o)o=a[t]=r,++e._eventsCount;else if("function"==typeof o?o=a[t]=n?[r,o]:[o,r]:n?o.unshift(r):o.push(r),(i=c(e))>0&&o.length>i&&!o.warned){o.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=o.length,s=l,console&&console.warn&&console.warn(s)}return e}function f(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function d(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=f.bind(n);return i.listener=r,n.wrapFn=i,i}function p(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?function(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(i):g(i,i.length)}function m(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function g(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function v(e,t,r,n){if("function"==typeof e.on)n.once?e.once(t,r):e.on(t,r);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function i(a){n.once&&e.removeEventListener(t,i),r(a)}))}}Object.defineProperty(s,"defaultMaxListeners",{enumerable:!0,get:function(){return l},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");l=e}}),s.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return c(this)},s.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n="error"===e,i=this._events;if(void 0!==i)n=n&&void 0===i.error;else if(!n)return!1;if(n){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var l=i[e];if(void 0===l)return!1;if("function"==typeof l)a(l,this,t);else{var u=l.length,c=g(l,u);for(r=0;r<u;++r)a(c[r],this,t)}return!0},s.prototype.addListener=function(e,t){return h(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return h(this,e,t,!0)},s.prototype.once=function(e,t){return u(t),this.on(e,d(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return u(t),this.prependListener(e,d(this,e,t)),this},s.prototype.removeListener=function(e,t){var r,n,i,a,o;if(u(t),void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(i=-1,a=r.length-1;a>=0;a--)if(r[a]===t||r[a].listener===t){o=r[a].listener,i=a;break}if(i<0)return this;0===i?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,i),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,o||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){var i,a=Object.keys(r);for(n=0;n<a.length;++n)"removeListener"!==(i=a[n])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return p(this,e,!0)},s.prototype.rawListeners=function(e){return p(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):m.call(e,t)},s.prototype.listenerCount=m,s.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},578:function(e,t,r){"use strict";(function(t){void 0===t||!t.version||0===t.version.indexOf("v0.")||0===t.version.indexOf("v1.")&&0!==t.version.indexOf("v1.8.")?e.exports={nextTick:function(e,r,n,i){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var a,o,s=arguments.length;switch(s){case 0:case 1:return t.nextTick(e);case 2:return t.nextTick((function(){e.call(null,r)}));case 3:return t.nextTick((function(){e.call(null,r,n)}));case 4:return t.nextTick((function(){e.call(null,r,n,i)}));default:for(a=new Array(s-1),o=0;o<a.length;)a[o++]=arguments[o];return t.nextTick((function(){e.apply(null,a)}))}}}:e.exports=t}).call(this,r(318))},597:function(e,t,r){(t=e.exports=r(655)).Stream=t,t.Readable=t,t.Writable=r(599),t.Duplex=r(559),t.Transform=r(659),t.PassThrough=r(897)},598:function(e,t,r){var n=r(557),i=n.Buffer;function a(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(a(n,t),t.Buffer=o),a(i,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},599:function(e,t,r){"use strict";(function(t,n,i){var a=r(578);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=y;var s,l=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?n:a.nextTick;y.WritableState=v;var u=Object.create(r(570));u.inherits=r(566);var c={deprecate:r(895)},h=r(656),f=r(598).Buffer,d=(void 0!==i?i:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var p,m=r(657);function g(){}function v(e,t){s=s||r(559),e=e||{};var n=t instanceof s;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,u=e.writableHighWaterMark,c=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(u||0===u)?u:c,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var h=!1===e.decodeStrings;this.decodeStrings=!h,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,i){--t.pendingcb,r?(a.nextTick(i,n),a.nextTick(x,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(i(n),e._writableState.errorEmitted=!0,e.emit("error",n),x(e,t))}(e,r,n,t,i);else{var o=_(r);o||r.corked||r.bufferProcessing||!r.bufferedRequest||k(e,r),n?l(w,e,r,o,i):w(e,r,o,i)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function y(e){if(s=s||r(559),!(p.call(y,this)||this instanceof s))return new y(e);this._writableState=new v(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function b(e,t,r,n,i,a,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(i,t.onwrite):e._write(i,a,t.onwrite),t.sync=!1}function w(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),x(e,t)}function k(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,l=!0;r;)i[s]=r,r.isBuf||(l=!1),r=r.next,s+=1;i.allBuffers=l,b(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,c=r.encoding,h=r.callback;if(b(e,t,!1,t.objectMode?1:u.length,u,c,h),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function _(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function S(e,t){e._final((function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),x(e,t)}))}function x(e,t){var r=_(t);return r&&(!function(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,a.nextTick(S,e,t)):(t.prefinished=!0,e.emit("prefinish")))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}u.inherits(y,h),v.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(v.prototype,"buffer",{get:c.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(p=Function.prototype[Symbol.hasInstance],Object.defineProperty(y,Symbol.hasInstance,{value:function(e){return!!p.call(this,e)||this===y&&(e&&e._writableState instanceof v)}})):p=function(e){return e instanceof this},y.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},y.prototype.write=function(e,t,r){var n,i=this._writableState,o=!1,s=!i.objectMode&&(n=e,f.isBuffer(n)||n instanceof d);return s&&!f.isBuffer(e)&&(e=function(e){return f.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=i.defaultEncoding),"function"!=typeof r&&(r=g),i.ended?function(e,t){var r=new Error("write after end");e.emit("error",r),a.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var i=!0,o=!1;return null===r?o=new TypeError("May not write null values to stream"):"string"==typeof r||void 0===r||t.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(e.emit("error",o),a.nextTick(n,o),i=!1),i}(this,i,e,r))&&(i.pendingcb++,o=function(e,t,r,n,i,a){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,r));return t}(t,n,i);n!==o&&(r=!0,i="buffer",n=o)}var s=t.objectMode?1:n.length;t.length+=s;var l=t.length<t.highWaterMark;l||(t.needDrain=!0);if(t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:a,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else b(e,t,!1,s,n,i,a);return l}(this,i,s,e,t,r)),o},y.prototype.cork=function(){this._writableState.corked++},y.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||k(this,e))},y.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(y.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),y.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},y.prototype._writev=null,y.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||function(e,t,r){t.ending=!0,x(e,t),r&&(t.finished?a.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r)},Object.defineProperty(y.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),y.prototype.destroy=m.destroy,y.prototype._undestroy=m.undestroy,y.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,r(318),r(563).setImmediate,r(32))},655:function(e,t,r){"use strict";(function(t,n){var i=r(578);e.exports=b;var a,o=r(891);b.ReadableState=y;r(577).EventEmitter;var s=function(e,t){return e.listeners(t).length},l=r(656),u=r(598).Buffer,c=(void 0!==t?t:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var h=Object.create(r(570));h.inherits=r(566);var f=r(892),d=void 0;d=f&&f.debuglog?f.debuglog("stream"):function(){};var p,m=r(893),g=r(657);h.inherits(b,l);var v=["error","close","destroy","pause","resume"];function y(e,t){e=e||{};var n=t instanceof(a=a||r(559));this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(o||0===o)?o:s,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new m,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(p||(p=r(658).StringDecoder),this.decoder=new p(e.encoding),this.encoding=e.encoding)}function b(e){if(a=a||r(559),!(this instanceof b))return new b(e);this._readableState=new y(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),l.call(this)}function w(e,t,r,n,i){var a,o=e._readableState;null===t?(o.reading=!1,function(e,t){if(t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,S(e)}(e,o)):(i||(a=function(e,t){var r;n=t,u.isBuffer(n)||n instanceof c||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var n;return r}(o,t)),a?e.emit("error",a):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===u.prototype||(t=function(e){return u.from(e)}(t)),n?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):k(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?k(e,o,t,!1):C(e,o)):k(e,o,t,!1))):n||(o.reading=!1));return function(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}(o)}function k(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&S(e)),C(e,t)}Object.defineProperty(b.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),b.prototype.destroy=g.destroy,b.prototype._undestroy=g.undestroy,b.prototype._destroy=function(e,t){this.push(null),t(e)},b.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=u.from(e,t),t=""),r=!0),w(this,e,t,!1,r)},b.prototype.unshift=function(e){return w(this,e,null,!0,!1)},b.prototype.isPaused=function(){return!1===this._readableState.flowing},b.prototype.setEncoding=function(e){return p||(p=r(658).StringDecoder),this._readableState.decoder=new p(e),this._readableState.encoding=e,this};function _(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=function(e){return e>=8388608?e=8388608:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function S(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(d("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(x,e):x(e))}function x(e){d("emit readable"),e.emit("readable"),A(e)}function C(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(E,e,t))}function E(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(d("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function P(e){d("readable nexttick read 0"),e.read(0)}function T(e,t){t.reading||(d("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),A(e),t.flowing&&!t.reading&&e.read(0)}function A(e){var t=e._readableState;for(d("flow",t.flowing);t.flowing&&null!==e.read(););}function N(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var n;e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?function(e,t){var r=t.head,n=1,i=r.data;e-=i.length;for(;r=r.next;){var a=r.data,o=e>a.length?a.length:e;if(o===a.length?i+=a:i+=a.slice(0,e),0===(e-=o)){o===a.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=a.slice(o));break}++n}return t.length-=n,i}(e,t):function(e,t){var r=u.allocUnsafe(e),n=t.head,i=1;n.data.copy(r),e-=n.data.length;for(;n=n.next;){var a=n.data,o=e>a.length?a.length:e;if(a.copy(r,r.length-e,0,o),0===(e-=o)){o===a.length?(++i,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=a.slice(o));break}++i}return t.length-=i,r}(e,t);return n}(e,t.buffer,t.decoder),r);var r}function O(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick(R,t,e))}function R(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function M(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}b.prototype.read=function(e){d("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return d("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?O(this):S(this),null;if(0===(e=_(e,t))&&t.ended)return 0===t.length&&O(this),null;var n,i=t.needReadable;return d("need readable",i),(0===t.length||t.length-e<t.highWaterMark)&&d("length less than watermark",i=!0),t.ended||t.reading?d("reading or ended",i=!1):i&&(d("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=_(r,t))),null===(n=e>0?N(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&O(this)),null!==n&&this.emit("data",n),n},b.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},b.prototype.pipe=function(e,t){var r=this,a=this._readableState;switch(a.pipesCount){case 0:a.pipes=e;break;case 1:a.pipes=[a.pipes,e];break;default:a.pipes.push(e)}a.pipesCount+=1,d("pipe count=%d opts=%j",a.pipesCount,t);var l=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?c:b;function u(t,n){d("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,d("cleanup"),e.removeListener("close",v),e.removeListener("finish",y),e.removeListener("drain",h),e.removeListener("error",g),e.removeListener("unpipe",u),r.removeListener("end",c),r.removeListener("end",b),r.removeListener("data",m),f=!0,!a.awaitDrain||e._writableState&&!e._writableState.needDrain||h())}function c(){d("onend"),e.end()}a.endEmitted?i.nextTick(l):r.once("end",l),e.on("unpipe",u);var h=function(e){return function(){var t=e._readableState;d("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&s(e,"data")&&(t.flowing=!0,A(e))}}(r);e.on("drain",h);var f=!1;var p=!1;function m(t){d("ondata"),p=!1,!1!==e.write(t)||p||((1===a.pipesCount&&a.pipes===e||a.pipesCount>1&&-1!==M(a.pipes,e))&&!f&&(d("false write response, pause",a.awaitDrain),a.awaitDrain++,p=!0),r.pause())}function g(t){d("onerror",t),b(),e.removeListener("error",g),0===s(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",y),b()}function y(){d("onfinish"),e.removeListener("close",v),b()}function b(){d("unpipe"),r.unpipe(e)}return r.on("data",m),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",g),e.once("close",v),e.once("finish",y),e.emit("pipe",r),a.flowing||(d("pipe resume"),r.resume()),e},b.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var a=0;a<i;a++)n[a].emit("unpipe",this,{hasUnpiped:!1});return this}var o=M(t.pipes,e);return-1===o||(t.pipes.splice(o,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},b.prototype.on=function(e,t){var r=l.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var n=this._readableState;n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&S(this):i.nextTick(P,this))}return r},b.prototype.addListener=b.prototype.on,b.prototype.resume=function(){var e=this._readableState;return e.flowing||(d("resume"),e.flowing=!0,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(T,e,t))}(this,e)),this},b.prototype.pause=function(){return d("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(d("pause"),this._readableState.flowing=!1,this.emit("pause")),this},b.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(d("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){(d("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a<v.length;a++)e.on(v[a],this.emit.bind(this,v[a]));return this._read=function(t){d("wrapped _read",t),n&&(n=!1,e.resume())},this},Object.defineProperty(b.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),b._fromList=N}).call(this,r(32),r(318))},656:function(e,t,r){e.exports=r(577).EventEmitter},657:function(e,t,r){"use strict";var n=r(578);function i(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,a=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return a||o?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,n.nextTick(i,this,e)):n.nextTick(i,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,n.nextTick(i,r,e)):n.nextTick(i,r,e):t&&t(e)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},658:function(e,t,r){"use strict";var n=r(896).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function a(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=l,this.end=u,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=c,this.end=h,t=3;break;default:return this.write=f,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function o(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function l(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function u(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function c(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function h(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function f(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.StringDecoder=a,a.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},a.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t},a.prototype.text=function(e,t){var r=function(e,t,r){var n=t.length-1;if(n<r)return 0;var i=o(t[n]);if(i>=0)return i>0&&(e.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if((i=o(t[n]))>=0)return i>0&&(e.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if((i=o(t[n]))>=0)return i>0&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},659:function(e,t,r){"use strict";e.exports=o;var n=r(559),i=Object.create(r(570));function a(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function o(e){if(!(this instanceof o))return new o(e);n.call(this,e),this._transformState={afterTransform:a.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",s)}function s(){var e=this;"function"==typeof this._flush?this._flush((function(t,r){l(e,t,r)})):l(this,null,null)}function l(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=r(566),i.inherits(o,n),o.prototype.push=function(e,t){return this._transformState.needTransform=!1,n.prototype.push.call(this,e,t)},o.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},o.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},o.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},o.prototype._destroy=function(e,t){var r=this;n.prototype._destroy.call(this,e,(function(e){t(e),r.emit("close")}))}},660:function(e,t,r){(function(e){var n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},i=/%[sdj%]/g;t.format=function(e){if(!v(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(s(arguments[r]));return t.join(" ")}r=1;for(var n=arguments,a=n.length,o=String(e).replace(i,(function(e){if("%%"===e)return"%";if(r>=a)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),l=n[r];r<a;l=n[++r])m(l)||!w(l)?o+=" "+l:o+=" "+s(l);return o},t.deprecate=function(r,n){if(void 0!==e&&!0===e.noDeprecation)return r;if(void 0===e)return function(){return t.deprecate(r,n).apply(this,arguments)};var i=!1;return function(){if(!i){if(e.throwDeprecation)throw new Error(n);e.traceDeprecation?console.trace(n):console.error(n),i=!0}return r.apply(this,arguments)}};var a,o={};function s(e,r){var n={seen:[],stylize:u};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),p(r)?n.showHidden=r:r&&t._extend(n,r),y(n.showHidden)&&(n.showHidden=!1),y(n.depth)&&(n.depth=2),y(n.colors)&&(n.colors=!1),y(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=l),c(n,e,n.depth)}function l(e,t){var r=s.styles[t];return r?"["+s.colors[r][0]+"m"+e+"["+s.colors[r][1]+"m":e}function u(e,t){return e}function c(e,r,n){if(e.customInspect&&r&&S(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return v(i)||(i=c(e,i,n)),i}var a=function(e,t){if(y(t))return e.stylize("undefined","undefined");if(v(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(g(t))return e.stylize(""+t,"number");if(p(t))return e.stylize(""+t,"boolean");if(m(t))return e.stylize("null","null")}(e,r);if(a)return a;var o=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(o);if(e.showHidden&&(o=Object.getOwnPropertyNames(r)),_(r)&&(o.indexOf("message")>=0||o.indexOf("description")>=0))return h(r);if(0===o.length){if(S(r)){var l=r.name?": "+r.name:"";return e.stylize("[Function"+l+"]","special")}if(b(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(k(r))return e.stylize(Date.prototype.toString.call(r),"date");if(_(r))return h(r)}var u,w="",x=!1,C=["{","}"];(d(r)&&(x=!0,C=["[","]"]),S(r))&&(w=" [Function"+(r.name?": "+r.name:"")+"]");return b(r)&&(w=" "+RegExp.prototype.toString.call(r)),k(r)&&(w=" "+Date.prototype.toUTCString.call(r)),_(r)&&(w=" "+h(r)),0!==o.length||x&&0!=r.length?n<0?b(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),u=x?function(e,t,r,n,i){for(var a=[],o=0,s=t.length;o<s;++o)T(t,String(o))?a.push(f(e,t,r,n,String(o),!0)):a.push("");return i.forEach((function(i){i.match(/^\d+$/)||a.push(f(e,t,r,n,i,!0))})),a}(e,r,n,s,o):o.map((function(t){return f(e,r,n,s,t,x)})),e.seen.pop(),function(e,t,r){if(e.reduce((function(e,t){return t.indexOf("\n")>=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(u,w,C)):C[0]+w+C[1]}function h(e){return"["+Error.prototype.toString.call(e)+"]"}function f(e,t,r,n,i,a){var o,s,l;if((l=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(s=e.stylize("[Setter]","special")),T(n,i)||(o="["+i+"]"),s||(e.seen.indexOf(l.value)<0?(s=m(r)?c(e,l.value,null):c(e,l.value,r-1)).indexOf("\n")>-1&&(s=a?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),y(o)){if(a&&i.match(/^\d+$/))return s;(o=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string"))}return o+": "+s}function d(e){return Array.isArray(e)}function p(e){return"boolean"==typeof e}function m(e){return null===e}function g(e){return"number"==typeof e}function v(e){return"string"==typeof e}function y(e){return void 0===e}function b(e){return w(e)&&"[object RegExp]"===x(e)}function w(e){return"object"==typeof e&&null!==e}function k(e){return w(e)&&"[object Date]"===x(e)}function _(e){return w(e)&&("[object Error]"===x(e)||e instanceof Error)}function S(e){return"function"==typeof e}function x(e){return Object.prototype.toString.call(e)}function C(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(y(a)&&(a=e.env.NODE_DEBUG||""),r=r.toUpperCase(),!o[r])if(new RegExp("\\b"+r+"\\b","i").test(a)){var n=e.pid;o[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else o[r]=function(){};return o[r]},t.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=d,t.isBoolean=p,t.isNull=m,t.isNullOrUndefined=function(e){return null==e},t.isNumber=g,t.isString=v,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=y,t.isRegExp=b,t.isObject=w,t.isDate=k,t.isError=_,t.isFunction=S,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(902);var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(){var e=new Date,t=[C(e.getHours()),C(e.getMinutes()),C(e.getSeconds())].join(":");return[e.getDate(),E[e.getMonth()],t].join(" ")}function T(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",P(),t.format.apply(t,arguments))},t.inherits=r(903),t._extend=function(e,t){if(!t||!w(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var A="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function N(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(A&&e[A]){var t;if("function"!=typeof(t=e[A]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,A,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),i=[],a=0;a<arguments.length;a++)i.push(arguments[a]);i.push((function(e,n){e?r(e):t(n)}));try{e.apply(this,i)}catch(e){r(e)}return n}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),A&&Object.defineProperty(t,A,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,n(e))},t.promisify.custom=A,t.callbackify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');function r(){for(var r=[],n=0;n<arguments.length;n++)r.push(arguments[n]);var i=r.pop();if("function"!=typeof i)throw new TypeError("The last argument must be of type Function");var a=this,o=function(){return i.apply(a,arguments)};t.apply(this,r).then((function(t){e.nextTick(o,null,t)}),(function(t){e.nextTick(N,t,o)}))}return Object.setPrototypeOf(r,Object.getPrototypeOf(t)),Object.defineProperties(r,n(t)),r}}).call(this,r(318))},889:function(e,t,r){"use strict";(function(e,n,i,a){r.d(t,"a",(function(){return Cs}));var o=r(890),s=r.n(o),l=r(577),u=r.n(l),c=r(557),h=r.n(c),f=r(660),d=r.n(f);function p(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function m(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p(Object(r),!0).forEach((function(t){g(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function g(e,t,r){return(t=M(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function v(e){return function(e){if(Array.isArray(e))return E(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||C(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){u=!0,i=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||C(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function b(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&w(e,t)}function w(e,t){return(w=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=S(e);if(t){var i=S(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return _(this,r)}}function _(e,t){if(t&&("object"===B(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function S(e){return(S=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function x(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=C(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||null==r.return||r.return()}finally{if(s)throw a}}}}function C(e,t){if(e){if("string"==typeof e)return E(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?E(e,t):void 0}}function E(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function P(){P=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,i=Object.defineProperty||function(e,t,r){e[t]=r.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",s=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,r){return e[t]=r}}function c(e,t,r,n){var a=t&&t.prototype instanceof g?t:g,o=Object.create(a.prototype),s=new N(n||[]);return i(o,"_invoke",{value:C(e,r,s)}),o}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=c;var f="suspendedStart",d="executing",p="completed",m={};function g(){}function v(){}function y(){}var b={};u(b,o,(function(){return this}));var w=Object.getPrototypeOf,k=w&&w(w(O([])));k&&k!==r&&n.call(k,o)&&(b=k);var _=y.prototype=g.prototype=Object.create(b);function S(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){function r(i,a,o,s){var l=h(e[i],e,a);if("throw"!==l.type){var u=l.arg,c=u.value;return c&&"object"==B(c)&&n.call(c,"__await")?t.resolve(c.__await).then((function(e){r("next",e,o,s)}),(function(e){r("throw",e,o,s)})):t.resolve(c).then((function(e){u.value=e,o(u)}),(function(e){return r("throw",e,o,s)}))}s(l.arg)}var a;i(this,"_invoke",{value:function(e,n){function i(){return new t((function(t,i){r(e,n,t,i)}))}return a=a?a.then(i,i):i()}})}function C(t,r,n){var i=f;return function(a,o){if(i===d)throw new Error("Generator is already running");if(i===p){if("throw"===a)throw o;return{value:e,done:!0}}for(n.method=a,n.arg=o;;){var s=n.delegate;if(s){var l=E(s,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(i===f)throw i=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);i=d;var u=h(t,r,n);if("normal"===u.type){if(i=n.done?p:"suspendedYield",u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(i=p,n.method="throw",n.arg=u.arg)}}}function E(t,r){var n=r.method,i=t.iterator[n];if(i===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,E(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=h(i,t.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var o=a.arg;return o?o.done?(r[t.resultName]=o.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,m):o:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function T(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function A(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function N(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(T,this),this.reset(!0)}function O(t){if(t||""===t){var r=t[o];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var i=-1,a=function r(){for(;++i<t.length;)if(n.call(t,i))return r.value=t[i],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}throw new TypeError(B(t)+" is not iterable")}return v.prototype=y,i(_,"constructor",{value:y,configurable:!0}),i(y,"constructor",{value:v,configurable:!0}),v.displayName=u(y,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===v||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,y):(e.__proto__=y,u(e,l,"GeneratorFunction")),e.prototype=Object.create(_),e},t.awrap=function(e){return{__await:e}},S(x.prototype),u(x.prototype,s,(function(){return this})),t.AsyncIterator=x,t.async=function(e,r,n,i,a){void 0===a&&(a=Promise);var o=new x(c(e,r,n,i),a);return t.isGeneratorFunction(r)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},S(_),u(_,l,"Generator"),u(_,o,(function(){return this})),u(_,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=O,N.prototype={constructor:N,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(A),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function i(n,i){return s.type="throw",s.arg=t,r.next=n,i&&(r.method="next",r.arg=e),!!i}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],s=o.completion;if("root"===o.tryLoc)return i("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),u=n.call(o,"finallyLoc");if(l&&u){if(this.prev<o.catchLoc)return i(o.catchLoc,!0);if(this.prev<o.finallyLoc)return i(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return i(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return i(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var o=a?a.completion:{};return o.type=e,o.arg=t,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var i=n.arg;A(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:O(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),m}},t}function T(e,t,r,n,i,a,o){try{var s=e[a](o),l=s.value}catch(e){return void r(e)}s.done?t(l):Promise.resolve(l).then(n,i)}function A(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){T(a,n,i,o,s,"next",e)}function s(e){T(a,n,i,o,s,"throw",e)}o(void 0)}))}}function N(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,M(n.key),n)}}function R(e,t,r){return t&&O(e.prototype,t),r&&O(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function M(e){var t=function(e,t){if("object"!==B(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!==B(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===B(t)?t:String(t)}function B(e){return(B="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}void 0===window.setImmediate&&(window.setImmediate=function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];setTimeout((function(){return e(r)}))});var D="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};var j,L,I,z,F,U={},W={},H={},Z={exports:{}},q={exports:{}};function V(){return j||(j=1,void 0===n||!n.version||0===n.version.indexOf("v0.")||0===n.version.indexOf("v1.")&&0!==n.version.indexOf("v1.8.")?q.exports={nextTick:function(e,t,r,i){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var a,o,s=arguments.length;switch(s){case 0:case 1:return n.nextTick(e);case 2:return n.nextTick((function(){e.call(null,t)}));case 3:return n.nextTick((function(){e.call(null,t,r)}));case 4:return n.nextTick((function(){e.call(null,t,r,i)}));default:for(a=new Array(s-1),o=0;o<a.length;)a[o++]=arguments[o];return n.nextTick((function(){e.apply(null,a)}))}}}:q.exports=n),q.exports}function X(){return F?z:(F=1,z=s.a)}var G,K={exports:{}};function J(){return G||(G=1,function(e,t){var r=h.a,n=r.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return n(e,t,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a),i(n,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return n(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var i=n(e);return void 0!==t?"string"==typeof r?i.fill(t,r):i.fill(t):i.fill(0),i},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}}(K,K.exports)),K.exports}var Y,$={};function Q(){if(Y)return $;function e(e){return Object.prototype.toString.call(e)}return Y=1,$.isArray=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===e(t)},$.isBoolean=function(e){return"boolean"==typeof e},$.isNull=function(e){return null===e},$.isNullOrUndefined=function(e){return null==e},$.isNumber=function(e){return"number"==typeof e},$.isString=function(e){return"string"==typeof e},$.isSymbol=function(e){return"symbol"==B(e)},$.isUndefined=function(e){return void 0===e},$.isRegExp=function(t){return"[object RegExp]"===e(t)},$.isObject=function(e){return"object"==B(e)&&null!==e},$.isDate=function(t){return"[object Date]"===e(t)},$.isError=function(t){return"[object Error]"===e(t)||t instanceof Error},$.isFunction=function(e){return"function"==typeof e},$.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==B(e)||void 0===e},$.isBuffer=h.a.Buffer.isBuffer,$}var ee,te,re={exports:{}},ne={exports:{}};function ie(){if(te)return re.exports;te=1;try{var e=r(660);if("function"!=typeof e.inherits)throw"";re.exports=e.inherits}catch(e){re.exports=(ee||(ee=1,"function"==typeof Object.create?ne.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:ne.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}),ne.exports)}return re.exports}var ae,oe,se,le,ue,ce,he,fe,de,pe={exports:{}};function me(){return ae||(ae=1,e=pe,t=J().Buffer,r=d.a,e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return t.alloc(0);for(var r,n,i=t.allocUnsafe(e>>>0),a=this.head,o=0;a;)r=i,n=o,a.data.copy(r,n),o+=a.data.length,a=a.next;return i},e}(),r&&r.inspect&&r.inspect.custom&&(e.exports.prototype[r.inspect.custom]=function(){var e=r.inspect({length:this.length});return this.constructor.name+" "+e})),pe.exports;var e,t,r}function ge(){if(se)return oe;se=1;var e=V();function t(e,t){e.emit("error",t)}return oe={destroy:function(r,n){var i=this,a=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return a||o?(n?n(r):r&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,e.nextTick(t,this,r)):e.nextTick(t,this,r)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(r||null,(function(r){!n&&r?i._writableState?i._writableState.errorEmitted||(i._writableState.errorEmitted=!0,e.nextTick(t,i,r)):e.nextTick(t,i,r):n&&n(r)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}}function ve(){if(he)return ce;he=1;var e=V();function t(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(void 0),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}ce=g;var r,a=!n.browser&&["v0.10","v0.9."].indexOf(n.version.slice(0,5))>-1?i:e.nextTick;g.WritableState=m;var o=Object.create(Q());o.inherits=ie();var s,l={deprecate:ue?le:(ue=1,le=d.a.deprecate)},u=X(),c=J().Buffer,h=(void 0!==D?D:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},f=ge();function p(){}function m(n,i){r=r||ye(),n=n||{};var o=i instanceof r;this.objectMode=!!n.objectMode,o&&(this.objectMode=this.objectMode||!!n.writableObjectMode);var s=n.highWaterMark,l=n.writableHighWaterMark,u=this.objectMode?16:16384;this.highWaterMark=s||0===s?s:o&&(l||0===l)?l:u,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===n.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=n.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,r){var n=t._writableState,i=n.sync,o=n.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(n),r)!function(t,r,n,i,a){--r.pendingcb,n?(e.nextTick(a,i),e.nextTick(_,t,r),t._writableState.errorEmitted=!0,t.emit("error",i)):(a(i),t._writableState.errorEmitted=!0,t.emit("error",i),_(t,r))}(t,n,i,r,o);else{var s=w(n);s||n.corked||n.bufferProcessing||!n.bufferedRequest||b(t,n),i?a(y,t,n,s,o):y(t,n,s,o)}}(i,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}function g(e){if(r=r||ye(),!(s.call(g,this)||this instanceof r))return new g(e);this._writableState=new m(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),u.call(this)}function v(e,t,r,n,i,a,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(i,t.onwrite):e._write(i,a,t.onwrite),t.sync=!1}function y(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),_(e,t)}function b(e,r){r.bufferProcessing=!0;var n=r.bufferedRequest;if(e._writev&&n&&n.next){var i=r.bufferedRequestCount,a=new Array(i),o=r.corkedRequestsFree;o.entry=n;for(var s=0,l=!0;n;)a[s]=n,n.isBuf||(l=!1),n=n.next,s+=1;a.allBuffers=l,v(e,r,!0,r.length,a,"",o.finish),r.pendingcb++,r.lastBufferedRequest=null,o.next?(r.corkedRequestsFree=o.next,o.next=null):r.corkedRequestsFree=new t(r),r.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback;if(v(e,r,!1,r.objectMode?1:u.length,u,c,h),n=n.next,r.bufferedRequestCount--,r.writing)break}null===n&&(r.lastBufferedRequest=null)}r.bufferedRequest=n,r.bufferProcessing=!1}function w(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function k(e,t){e._final((function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),_(e,t)}))}function _(t,r){var n=w(r);return n&&(function(t,r){r.prefinished||r.finalCalled||("function"==typeof t._final?(r.pendingcb++,r.finalCalled=!0,e.nextTick(k,t,r)):(r.prefinished=!0,t.emit("prefinish")))}(t,r),0===r.pendingcb&&(r.finished=!0,t.emit("finish"))),n}return o.inherits(g,u),m.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(m.prototype,"buffer",{get:l.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(g,Symbol.hasInstance,{value:function(e){return!!s.call(this,e)||this===g&&e&&e._writableState instanceof m}})):s=function(e){return e instanceof this},g.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},g.prototype.write=function(t,r,n){var i,a=this._writableState,o=!1,s=!a.objectMode&&(i=t,c.isBuffer(i)||i instanceof h);return s&&!c.isBuffer(t)&&(t=function(e){return c.from(e)}(t)),"function"==typeof r&&(n=r,r=null),s?r="buffer":r||(r=a.defaultEncoding),"function"!=typeof n&&(n=p),a.ended?function(t,r){var n=new Error("write after end");t.emit("error",n),e.nextTick(r,n)}(this,n):(s||function(t,r,n,i){var a=!0,o=!1;return null===n?o=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||r.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(t.emit("error",o),e.nextTick(i,o),a=!1),a}(this,a,t,n))&&(a.pendingcb++,o=function(e,t,r,n,i,a){if(!r){var o=function(e,t,r){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=c.from(t,r)),t}(t,n,i);n!==o&&(r=!0,i="buffer",n=o)}var s=t.objectMode?1:n.length;t.length+=s;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:a,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else v(e,t,!1,s,n,i,a);return l}(this,a,s,t,r,n)),o},g.prototype.cork=function(){this._writableState.corked++},g.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||b(this,e))},g.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(g.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),g.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},g.prototype._writev=null,g.prototype.end=function(t,r,n){var i=this._writableState;"function"==typeof t?(n=t,t=null,r=null):"function"==typeof r&&(n=r,r=null),null!=t&&this.write(t,r),i.corked&&(i.corked=1,this.uncork()),i.ending||function(t,r,n){r.ending=!0,_(t,r),n&&(r.finished?e.nextTick(n):t.once("finish",n)),r.ended=!0,t.writable=!1}(this,i,n)},Object.defineProperty(g.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),g.prototype.destroy=f.destroy,g.prototype._undestroy=f.undestroy,g.prototype._destroy=function(e,t){this.end(),t(e)},ce}function ye(){if(de)return fe;de=1;var e=V(),t=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};fe=l;var r=Object.create(Q());r.inherits=ie();var n=Ae(),i=ve();r.inherits(l,n);for(var a=t(i.prototype),o=0;o<a.length;o++){var s=a[o];l.prototype[s]||(l.prototype[s]=i.prototype[s])}function l(e){if(!(this instanceof l))return new l(e);n.call(this,e),i.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",u)}function u(){this.allowHalfOpen||this._writableState.ended||e.nextTick(c,this)}function c(e){e.end()}return Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),l.prototype._destroy=function(t,r){this.push(null),this.end(),e.nextTick(r,t)},fe}var be,we,ke,_e,Se,xe,Ce,Ee,Pe={};function Te(){if(be)return Pe;be=1;var e=J().Buffer,t=e.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(r){var n;switch(this.encoding=function(r){var n=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(r);if("string"!=typeof n&&(e.isEncoding===t||!t(r)))throw new Error("Unknown encoding: "+r);return n||r}(r),this.encoding){case"utf16le":this.text=a,this.end=o,n=4;break;case"utf8":this.fillLast=i,n=4;break;case"base64":this.text=s,this.end=l,n=3;break;default:return this.write=u,void(this.end=c)}this.lastNeed=0,this.lastTotal=0,this.lastChar=e.allocUnsafe(n)}function n(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function i(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function a(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function o(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function s(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function l(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function u(e){return e.toString(this.encoding)}function c(e){return e&&e.length?this.write(e):""}return Pe.StringDecoder=r,r.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},r.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t},r.prototype.text=function(e,t){var r=function(e,t,r){var i=t.length-1;if(i<r)return 0;var a=n(t[i]);return a>=0?(a>0&&(e.lastNeed=a-1),a):--i<r||-2===a?0:(a=n(t[i]))>=0?(a>0&&(e.lastNeed=a-2),a):--i<r||-2===a?0:(a=n(t[i]))>=0?(a>0&&(2===a?a=0:e.lastNeed=a-3),a):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var i=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,i),e.toString("utf8",t,i)},r.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length},Pe}function Ae(){if(ke)return we;ke=1;var e=V();we=y;var t,r=function(){if(I)return L;I=1;var e={}.toString;return L=Array.isArray||function(t){return"[object Array]"==e.call(t)}}();y.ReadableState=v,u.a.EventEmitter;var i=function(e,t){return e.listeners(t).length},a=X(),o=J().Buffer,s=(void 0!==D?D:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){},l=Object.create(Q());l.inherits=ie();var c=d.a,h=void 0;h=c&&c.debuglog?c.debuglog("stream"):function(){};var f,p=me(),m=ge();l.inherits(y,a);var g=["error","close","destroy","pause","resume"];function v(e,r){e=e||{};var n=r instanceof(t=t||ye());this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,a=e.readableHighWaterMark,o=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(a||0===a)?a:o,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=Te().StringDecoder),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function y(e){if(t=t||ye(),!(this instanceof y))return new y(e);this._readableState=new v(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),a.call(this)}function b(e,t,r,n,i){var a,l=e._readableState;return null===t?(l.reading=!1,function(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,S(e)}}(e,l)):(i||(a=function(e,t){var r,n;return n=t,o.isBuffer(n)||n instanceof s||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk")),r}(l,t)),a?e.emit("error",a):l.objectMode||t&&t.length>0?("string"==typeof t||l.objectMode||Object.getPrototypeOf(t)===o.prototype||(t=function(e){return o.from(e)}(t)),n?l.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):w(e,l,t,!0):l.ended?e.emit("error",new Error("stream.push() after EOF")):(l.reading=!1,l.decoder&&!r?(t=l.decoder.write(t),l.objectMode||0!==t.length?w(e,l,t,!1):C(e,l)):w(e,l,t,!1))):n||(l.reading=!1)),function(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}(l)}function w(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&S(e)),C(e,t)}Object.defineProperty(y.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),y.prototype.destroy=m.destroy,y.prototype._undestroy=m.undestroy,y.prototype._destroy=function(e,t){this.push(null),t(e)},y.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=o.from(e,t),t=""),r=!0),b(this,e,t,!1,r)},y.prototype.unshift=function(e){return b(this,e,null,!0,!1)},y.prototype.isPaused=function(){return!1===this._readableState.flowing},y.prototype.setEncoding=function(e){return f||(f=Te().StringDecoder),this._readableState.decoder=new f(e),this._readableState.encoding=e,this};var k=8388608;function _(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=function(e){return e>=k?e=k:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function S(t){var r=t._readableState;r.needReadable=!1,r.emittedReadable||(h("emitReadable",r.flowing),r.emittedReadable=!0,r.sync?e.nextTick(x,t):x(t))}function x(e){h("emit readable"),e.emit("readable"),A(e)}function C(t,r){r.readingMore||(r.readingMore=!0,e.nextTick(E,t,r))}function E(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(h("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function P(e){h("readable nexttick read 0"),e.read(0)}function T(e,t){t.reading||(h("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),A(e),t.flowing&&!t.reading&&e.read(0)}function A(e){var t=e._readableState;for(h("flow",t.flowing);t.flowing&&null!==e.read(););}function N(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?function(e,t){var r=t.head,n=1,i=r.data;for(e-=i.length;r=r.next;){var a=r.data,o=e>a.length?a.length:e;if(o===a.length?i+=a:i+=a.slice(0,e),0==(e-=o)){o===a.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=a.slice(o));break}++n}return t.length-=n,i}(e,t):function(e,t){var r=o.allocUnsafe(e),n=t.head,i=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var a=n.data,s=e>a.length?a.length:e;if(a.copy(r,r.length-e,0,s),0==(e-=s)){s===a.length?(++i,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=a.slice(s));break}++i}return t.length-=i,r}(e,t),n}(e,t.buffer,t.decoder),r);var r}function O(t){var r=t._readableState;if(r.length>0)throw new Error('"endReadable()" called on non-empty stream');r.endEmitted||(r.ended=!0,e.nextTick(R,r,t))}function R(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function M(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}return y.prototype.read=function(e){h("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return h("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?O(this):S(this),null;if(0===(e=_(e,t))&&t.ended)return 0===t.length&&O(this),null;var n,i=t.needReadable;return h("need readable",i),(0===t.length||t.length-e<t.highWaterMark)&&h("length less than watermark",i=!0),t.ended||t.reading?h("reading or ended",i=!1):i&&(h("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=_(r,t))),null===(n=e>0?N(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&O(this)),null!==n&&this.emit("data",n),n},y.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},y.prototype.pipe=function(t,a){var o=this,s=this._readableState;switch(s.pipesCount){case 0:s.pipes=t;break;case 1:s.pipes=[s.pipes,t];break;default:s.pipes.push(t)}s.pipesCount+=1,h("pipe count=%d opts=%j",s.pipesCount,a);var l=a&&!1===a.end||t===n.stdout||t===n.stderr?y:u;function u(){h("onend"),t.end()}s.endEmitted?e.nextTick(l):o.once("end",l),t.on("unpipe",(function e(r,n){h("onunpipe"),r===o&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,h("cleanup"),t.removeListener("close",g),t.removeListener("finish",v),t.removeListener("drain",c),t.removeListener("error",m),t.removeListener("unpipe",e),o.removeListener("end",u),o.removeListener("end",y),o.removeListener("data",p),f=!0,!s.awaitDrain||t._writableState&&!t._writableState.needDrain||c())}));var c=function(e){return function(){var t=e._readableState;h("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&i(e,"data")&&(t.flowing=!0,A(e))}}(o);t.on("drain",c);var f=!1,d=!1;function p(e){h("ondata"),d=!1,!1!==t.write(e)||d||((1===s.pipesCount&&s.pipes===t||s.pipesCount>1&&-1!==M(s.pipes,t))&&!f&&(h("false write response, pause",s.awaitDrain),s.awaitDrain++,d=!0),o.pause())}function m(e){h("onerror",e),y(),t.removeListener("error",m),0===i(t,"error")&&t.emit("error",e)}function g(){t.removeListener("finish",v),y()}function v(){h("onfinish"),t.removeListener("close",g),y()}function y(){h("unpipe"),o.unpipe(t)}return o.on("data",p),function(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?r(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}(t,"error",m),t.once("close",g),t.once("finish",v),t.emit("pipe",o),s.flowing||(h("pipe resume"),o.resume()),t},y.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var a=0;a<i;a++)n[a].emit("unpipe",this,{hasUnpiped:!1});return this}var o=M(t.pipes,e);return-1===o||(t.pipes.splice(o,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},y.prototype.on=function(t,r){var n=a.prototype.on.call(this,t,r);if("data"===t)!1!==this._readableState.flowing&&this.resume();else if("readable"===t){var i=this._readableState;i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.emittedReadable=!1,i.reading?i.length&&S(this):e.nextTick(P,this))}return n},y.prototype.addListener=y.prototype.on,y.prototype.resume=function(){var t=this._readableState;return t.flowing||(h("resume"),t.flowing=!0,function(t,r){r.resumeScheduled||(r.resumeScheduled=!0,e.nextTick(T,t,r))}(this,t)),this},y.prototype.pause=function(){return h("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(h("pause"),this._readableState.flowing=!1,this.emit("pause")),this},y.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",(function(){if(h("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){h("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a<g.length;a++)e.on(g[a],this.emit.bind(this,g[a]));return this._read=function(t){h("wrapped _read",t),n&&(n=!1,e.resume())},this},Object.defineProperty(y.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),y._fromList=N,we}function Ne(){if(Se)return _e;Se=1,_e=n;var e=ye(),t=Object.create(Q());function r(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function n(t){if(!(this instanceof n))return new n(t);e.call(this,t),this._transformState={afterTransform:r.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",i)}function i(){var e=this;"function"==typeof this._flush?this._flush((function(t,r){a(e,t,r)})):a(this,null,null)}function a(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}return t.inherits=ie(),t.inherits(n,e),n.prototype.push=function(t,r){return this._transformState.needTransform=!1,e.prototype.push.call(this,t,r)},n.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},n.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},n.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},n.prototype._destroy=function(t,r){var n=this;e.prototype._destroy.call(this,t,(function(e){r(e),n.emit("close")}))},_e}function Oe(){return Ee||(Ee=1,e=Z,t=Z.exports,r=s.a,"disable"===n.env.READABLE_STREAM&&r?(e.exports=r,(t=e.exports=r.Readable).Readable=r.Readable,t.Writable=r.Writable,t.Duplex=r.Duplex,t.Transform=r.Transform,t.PassThrough=r.PassThrough,t.Stream=r):((t=e.exports=Ae()).Stream=r||t,t.Readable=t,t.Writable=ve(),t.Duplex=ye(),t.Transform=Ne(),t.PassThrough=function(){if(Ce)return xe;Ce=1,xe=r;var e=Ne(),t=Object.create(Q());function r(t){if(!(this instanceof r))return new r(t);e.call(this,t)}return t.inherits=ie(),t.inherits(r,e),r.prototype._transform=function(e,t,r){r(null,e)},xe}())),Z.exports;var e,t,r}if(H.base64=!0,H.array=!0,H.string=!0,H.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,H.nodebuffer=void 0!==a,H.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)H.blob=!1;else{var Re=new ArrayBuffer(0);try{H.blob=0===new Blob([Re],{type:"application/zip"}).size}catch(Ta){try{var Me=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);Me.append(Re),H.blob=0===Me.getBlob("application/zip").size}catch(Ta){H.blob=!1}}}try{H.nodestream=!!Oe().Readable}catch(Ta){H.nodestream=!1}var Be,De={};function je(){if(Be)return De;Be=1;var e=Ze(),t=H,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";return De.encode=function(t){for(var n,i,a,o,s,l,u,c=[],h=0,f=t.length,d=f,p="string"!==e.getTypeOf(t);h<t.length;)d=f-h,p?(n=t[h++],i=h<f?t[h++]:0,a=h<f?t[h++]:0):(n=t.charCodeAt(h++),i=h<f?t.charCodeAt(h++):0,a=h<f?t.charCodeAt(h++):0),o=n>>2,s=(3&n)<<4|i>>4,l=d>1?(15&i)<<2|a>>6:64,u=d>2?63&a:64,c.push(r.charAt(o)+r.charAt(s)+r.charAt(l)+r.charAt(u));return c.join("")},De.decode=function(e){var n,i,a,o,s,l,u=0,c=0;if("data:"===e.substr(0,5))throw new Error("Invalid base64 input, it looks like a data url.");var h,f=3*(e=e.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(e.charAt(e.length-1)===r.charAt(64)&&f--,e.charAt(e.length-2)===r.charAt(64)&&f--,f%1!=0)throw new Error("Invalid base64 input, bad content length.");for(h=t.uint8array?new Uint8Array(0|f):new Array(0|f);u<e.length;)n=r.indexOf(e.charAt(u++))<<2|(o=r.indexOf(e.charAt(u++)))>>4,i=(15&o)<<4|(s=r.indexOf(e.charAt(u++)))>>2,a=(3&s)<<6|(l=r.indexOf(e.charAt(u++))),h[c++]=n,64!==s&&(h[c++]=i),64!==l&&(h[c++]=a);return h},De}var Le,Ie,ze,Fe,Ue,We={isNode:void 0!==a,newBufferFrom:function(e,t){if(a.from&&a.from!==Uint8Array.from)return a.from(e,t);if("number"==typeof e)throw new Error('The "data" argument must not be a number');return new a(e,t)},allocBuffer:function(e){if(a.alloc)return a.alloc(e);var t=new a(e);return t.fill(0),t},isBuffer:function(e){return a.isBuffer(e)},isStream:function(e){return e&&"function"==typeof e.on&&"function"==typeof e.pause&&"function"==typeof e.resume}},He={Promise:"undefined"!=typeof Promise?Promise:function(){if(Fe)return ze;Fe=1;var e=function(){if(Ie)return Le;Ie=1;var e,t,r=D.MutationObserver||D.WebKitMutationObserver;if(n.browser)if(r){var i=0,a=new r(u),o=D.document.createTextNode("");a.observe(o,{characterData:!0}),e=function(){o.data=i=++i%2}}else if(D.setImmediate||void 0===D.MessageChannel)e="document"in D&&"onreadystatechange"in D.document.createElement("script")?function(){var e=D.document.createElement("script");e.onreadystatechange=function(){u(),e.onreadystatechange=null,e.parentNode.removeChild(e),e=null},D.document.documentElement.appendChild(e)}:function(){setTimeout(u,0)};else{var s=new D.MessageChannel;s.port1.onmessage=u,e=function(){s.port2.postMessage(0)}}else e=function(){n.nextTick(u)};var l=[];function u(){var e,r;t=!0;for(var n=l.length;n;){for(r=l,l=[],e=-1;++e<n;)r[e]();n=l.length}t=!1}return Le=function(r){1!==l.push(r)||t||e()}}();function t(){}var r={},i=["REJECTED"],a=["FULFILLED"],o=["PENDING"];if(!n.browser)var s=["UNHANDLED"];function l(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=o,this.queue=[],this.outcome=void 0,n.browser||(this.handled=s),e!==t&&f(this,e)}function u(e,t,r){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof r&&(this.onRejected=r,this.callRejected=this.otherCallRejected)}function c(t,n,i){e((function(){var e;try{e=n(i)}catch(e){return r.reject(t,e)}e===t?r.reject(t,new TypeError("Cannot resolve promise with itself")):r.resolve(t,e)}))}function h(e){var t=e&&e.then;if(e&&("object"==B(e)||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function f(e,t){var n=!1;function i(t){n||(n=!0,r.reject(e,t))}function a(t){n||(n=!0,r.resolve(e,t))}var o=d((function(){t(a,i)}));"error"===o.status&&i(o.value)}function d(e,t){var r={};try{r.value=e(t),r.status="success"}catch(e){r.status="error",r.value=e}return r}return ze=l,l.prototype.finally=function(e){if("function"!=typeof e)return this;var t=this.constructor;return this.then((function(r){return t.resolve(e()).then((function(){return r}))}),(function(r){return t.resolve(e()).then((function(){throw r}))}))},l.prototype.catch=function(e){return this.then(null,e)},l.prototype.then=function(e,r){if("function"!=typeof e&&this.state===a||"function"!=typeof r&&this.state===i)return this;var l=new this.constructor(t);return n.browser||this.handled===s&&(this.handled=null),this.state!==o?c(l,this.state===a?e:r,this.outcome):this.queue.push(new u(l,e,r)),l},u.prototype.callFulfilled=function(e){r.resolve(this.promise,e)},u.prototype.otherCallFulfilled=function(e){c(this.promise,this.onFulfilled,e)},u.prototype.callRejected=function(e){r.reject(this.promise,e)},u.prototype.otherCallRejected=function(e){c(this.promise,this.onRejected,e)},r.resolve=function(e,t){var n=d(h,t);if("error"===n.status)return r.reject(e,n.value);var i=n.value;if(i)f(e,i);else{e.state=a,e.outcome=t;for(var o=-1,s=e.queue.length;++o<s;)e.queue[o].callFulfilled(t)}return e},r.reject=function(t,r){t.state=i,t.outcome=r,n.browser||t.handled===s&&e((function(){t.handled===s&&n.emit("unhandledRejection",r,t)}));for(var a=-1,o=t.queue.length;++a<o;)t.queue[a].callRejected(r);return t},l.resolve=function(e){return e instanceof this?e:r.resolve(new this(t),e)},l.reject=function(e){var n=new this(t);return r.reject(n,e)},l.all=function(e){var n=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var i=e.length,a=!1;if(!i)return this.resolve([]);for(var o=new Array(i),s=0,l=-1,u=new this(t);++l<i;)c(e[l],l);return u;function c(e,t){n.resolve(e).then((function(e){o[t]=e,++s!==i||a||(a=!0,r.resolve(u,o))}),(function(e){a||(a=!0,r.reject(u,e))}))}},l.race=function(e){if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,i=!1;if(!n)return this.resolve([]);for(var a,o=-1,s=new this(t);++o<n;)a=e[o],this.resolve(a).then((function(e){i||(i=!0,r.resolve(s,e))}),(function(e){i||(i=!0,r.reject(s,e))}));return s},ze}()};function Ze(){return Ue||(Ue=1,function(e){var t=H,r=je(),n=We,a=He;function o(e){return e}function s(e,t){for(var r=0;r<e.length;++r)t[r]=255&e.charCodeAt(r);return t}e.newBlob=function(t,r){e.checkSupport("blob");try{return new Blob([t],{type:r})}catch(e){try{var n=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return n.append(t),n.getBlob(r)}catch(e){throw new Error("Bug : can't construct the Blob.")}}};var l={stringifyByChunk:function(e,t,r){var n=[],i=0,a=e.length;if(a<=r)return String.fromCharCode.apply(null,e);for(;i<a;)"array"===t||"nodebuffer"===t?n.push(String.fromCharCode.apply(null,e.slice(i,Math.min(i+r,a)))):n.push(String.fromCharCode.apply(null,e.subarray(i,Math.min(i+r,a)))),i+=r;return n.join("")},stringifyByChar:function(e){for(var t="",r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return t},applyCanBeUsed:{uint8array:function(){try{return t.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(e){return!1}}(),nodebuffer:function(){try{return t.nodebuffer&&1===String.fromCharCode.apply(null,n.allocBuffer(1)).length}catch(e){return!1}}()}};function u(t){var r=65536,n=e.getTypeOf(t),i=!0;if("uint8array"===n?i=l.applyCanBeUsed.uint8array:"nodebuffer"===n&&(i=l.applyCanBeUsed.nodebuffer),i)for(;r>1;)try{return l.stringifyByChunk(t,n,r)}catch(e){r=Math.floor(r/2)}return l.stringifyByChar(t)}function c(e,t){for(var r=0;r<e.length;r++)t[r]=e[r];return t}e.applyFromCharCode=u;var h={};h.string={string:o,array:function(e){return s(e,new Array(e.length))},arraybuffer:function(e){return h.string.uint8array(e).buffer},uint8array:function(e){return s(e,new Uint8Array(e.length))},nodebuffer:function(e){return s(e,n.allocBuffer(e.length))}},h.array={string:u,array:o,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return n.newBufferFrom(e)}},h.arraybuffer={string:function(e){return u(new Uint8Array(e))},array:function(e){return c(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:o,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return n.newBufferFrom(new Uint8Array(e))}},h.uint8array={string:u,array:function(e){return c(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:o,nodebuffer:function(e){return n.newBufferFrom(e)}},h.nodebuffer={string:u,array:function(e){return c(e,new Array(e.length))},arraybuffer:function(e){return h.nodebuffer.uint8array(e).buffer},uint8array:function(e){return c(e,new Uint8Array(e.length))},nodebuffer:o},e.transformTo=function(t,r){if(r||(r=""),!t)return r;e.checkSupport(t);var n=e.getTypeOf(r);return h[n][t](r)},e.resolve=function(e){for(var t=e.split("/"),r=[],n=0;n<t.length;n++){var i=t[n];"."===i||""===i&&0!==n&&n!==t.length-1||(".."===i?r.pop():r.push(i))}return r.join("/")},e.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":t.nodebuffer&&n.isBuffer(e)?"nodebuffer":t.uint8array&&e instanceof Uint8Array?"uint8array":t.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},e.checkSupport=function(e){if(!t[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},e.MAX_VALUE_16BITS=65535,e.MAX_VALUE_32BITS=-1,e.pretty=function(e){var t,r,n="";for(r=0;r<(e||"").length;r++)n+="\\x"+((t=e.charCodeAt(r))<16?"0":"")+t.toString(16).toUpperCase();return n},e.delay=function(e,t,r){i((function(){e.apply(r||null,t||[])}))},e.inherits=function(e,t){var r=function(){};r.prototype=t.prototype,e.prototype=new r},e.extend=function(){var e,t,r={};for(e=0;e<arguments.length;e++)for(t in arguments[e])Object.prototype.hasOwnProperty.call(arguments[e],t)&&void 0===r[t]&&(r[t]=arguments[e][t]);return r},e.prepareContent=function(n,i,o,l,u){return a.Promise.resolve(i).then((function(e){return t.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new a.Promise((function(t,r){var n=new FileReader;n.onload=function(e){t(e.target.result)},n.onerror=function(e){r(e.target.error)},n.readAsArrayBuffer(e)})):e})).then((function(i){var c,h=e.getTypeOf(i);return h?("arraybuffer"===h?i=e.transformTo("uint8array",i):"string"===h&&(u?i=r.decode(i):o&&!0!==l&&(i=s(c=i,t.uint8array?new Uint8Array(c.length):new Array(c.length)))),i):a.Promise.reject(new Error("Can't read the data of '"+n+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))}))}}(W)),W}function qe(e){this.name=e||"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}!function(e,t){if(!e.setImmediate){var r,i,a,o,s,l=1,u={},c=!1,h=e.document,f=Object.getPrototypeOf&&Object.getPrototypeOf(e);f=f&&f.setTimeout?f:e,"[object process]"==={}.toString.call(e.process)?r=function(e){n.nextTick((function(){p(e)}))}:function(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}()?(o="setImmediate$"+Math.random()+"$",s=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(o)&&p(+t.data.slice(o.length))},e.addEventListener?e.addEventListener("message",s,!1):e.attachEvent("onmessage",s),r=function(t){e.postMessage(o+t,"*")}):e.MessageChannel?((a=new MessageChannel).port1.onmessage=function(e){p(e.data)},r=function(e){a.port2.postMessage(e)}):h&&"onreadystatechange"in h.createElement("script")?(i=h.documentElement,r=function(e){var t=h.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,i.removeChild(t),t=null},i.appendChild(t)}):r=function(e){setTimeout(p,0,e)},f.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n<t.length;n++)t[n]=arguments[n+1];var i={callback:e,args:t};return u[l]=i,r(l),l++},f.clearImmediate=d}function d(e){delete u[e]}function p(e){if(c)setTimeout(p,0,e);else{var t=u[e];if(t){c=!0;try{!function(e){var t=e.callback,r=e.args;switch(r.length){case 0:t();break;case 1:t(r[0]);break;case 2:t(r[0],r[1]);break;case 3:t(r[0],r[1],r[2]);break;default:t.apply(void 0,r)}}(t)}finally{d(e),c=!1}}}}}("undefined"==typeof self?D:self),qe.prototype={push:function(e){this.emit("data",e)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},on:function(e,t){return this._listeners[e].push(t),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(e,t){if(this._listeners[e])for(var r=0;r<this._listeners[e].length;r++)this._listeners[e][r].call(this,t)},pipe:function(e){return e.registerPrevious(this)},registerPrevious:function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.end()})),e.on("error",(function(e){t.error(e)})),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;this.isPaused=!1;var e=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},flush:function(){},processChunk:function(e){this.push(e)},withStreamInfo:function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var e in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},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 e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e}};var Ve=qe;!function(e){for(var t=Ze(),r=H,n=We,i=Ve,a=new Array(256),o=0;o<256;o++)a[o]=o>=252?6:o>=248?5:o>=240?4:o>=224?3:o>=192?2:1;function s(){i.call(this,"utf-8 decode"),this.leftOver=null}function l(){i.call(this,"utf-8 encode")}a[254]=a[254]=1,e.utf8encode=function(e){return r.nodebuffer?n.newBufferFrom(e,"utf-8"):function(e){var t,n,i,a,o,s=e.length,l=0;for(a=0;a<s;a++)55296==(64512&(n=e.charCodeAt(a)))&&a+1<s&&56320==(64512&(i=e.charCodeAt(a+1)))&&(n=65536+(n-55296<<10)+(i-56320),a++),l+=n<128?1:n<2048?2:n<65536?3:4;for(t=r.uint8array?new Uint8Array(l):new Array(l),o=0,a=0;o<l;a++)55296==(64512&(n=e.charCodeAt(a)))&&a+1<s&&56320==(64512&(i=e.charCodeAt(a+1)))&&(n=65536+(n-55296<<10)+(i-56320),a++),n<128?t[o++]=n:n<2048?(t[o++]=192|n>>>6,t[o++]=128|63&n):n<65536?(t[o++]=224|n>>>12,t[o++]=128|n>>>6&63,t[o++]=128|63&n):(t[o++]=240|n>>>18,t[o++]=128|n>>>12&63,t[o++]=128|n>>>6&63,t[o++]=128|63&n);return t}(e)},e.utf8decode=function(e){return r.nodebuffer?t.transformTo("nodebuffer",e).toString("utf-8"):function(e){var r,n,i,o,s=e.length,l=new Array(2*s);for(n=0,r=0;r<s;)if((i=e[r++])<128)l[n++]=i;else if((o=a[i])>4)l[n++]=65533,r+=o-1;else{for(i&=2===o?31:3===o?15:7;o>1&&r<s;)i=i<<6|63&e[r++],o--;o>1?l[n++]=65533:i<65536?l[n++]=i:(i-=65536,l[n++]=55296|i>>10&1023,l[n++]=56320|1023&i)}return l.length!==n&&(l.subarray?l=l.subarray(0,n):l.length=n),t.applyFromCharCode(l)}(e=t.transformTo(r.uint8array?"uint8array":"array",e))},t.inherits(s,i),s.prototype.processChunk=function(n){var i=t.transformTo(r.uint8array?"uint8array":"array",n.data);if(this.leftOver&&this.leftOver.length){if(r.uint8array){var o=i;(i=new Uint8Array(o.length+this.leftOver.length)).set(this.leftOver,0),i.set(o,this.leftOver.length)}else i=this.leftOver.concat(i);this.leftOver=null}var s=function(e,t){var r;for((t=t||e.length)>e.length&&(t=e.length),r=t-1;r>=0&&128==(192&e[r]);)r--;return r<0||0===r?t:r+a[e[r]]>t?r:t}(i),l=i;s!==i.length&&(r.uint8array?(l=i.subarray(0,s),this.leftOver=i.subarray(s,i.length)):(l=i.slice(0,s),this.leftOver=i.slice(s,i.length))),this.push({data:e.utf8decode(l),meta:n.meta})},s.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:e.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},e.Utf8DecodeWorker=s,t.inherits(l,i),l.prototype.processChunk=function(t){this.push({data:e.utf8encode(t.data),meta:t.meta})},e.Utf8EncodeWorker=l}(U);var Xe=Ve,Ge=Ze();function Ke(e){Xe.call(this,"ConvertWorker to "+e),this.destType=e}Ge.inherits(Ke,Xe),Ke.prototype.processChunk=function(e){this.push({data:Ge.transformTo(this.destType,e.data),meta:e.meta})};var Je,Ye,$e=Ke,Qe=Ze(),et=$e,tt=Ve,rt=je(),nt=He,it=null;if(H.nodestream)try{it=function(){if(Ye)return Je;Ye=1;var e=Oe().Readable;function t(t,r,n){e.call(this,r),this._helper=t;var i=this;t.on("data",(function(e,t){i.push(e)||i._helper.pause(),n&&n(t)})).on("error",(function(e){i.emit("error",e)})).on("end",(function(){i.push(null)}))}return Ze().inherits(t,e),t.prototype._read=function(){this._helper.resume()},Je=t}()}catch(Ta){}function at(e,t,r){var n=t;switch(t){case"blob":case"arraybuffer":n="uint8array";break;case"base64":n="string"}try{this._internalType=n,this._outputType=t,this._mimeType=r,Qe.checkSupport(n),this._worker=e.pipe(new et(n)),e.lock()}catch(e){this._worker=new tt("error"),this._worker.error(e)}}at.prototype={accumulate:function(e){return function(e,t){return new nt.Promise((function(r,n){var i=[],o=e._internalType,s=e._outputType,l=e._mimeType;e.on("data",(function(e,r){i.push(e),t&&t(r)})).on("error",(function(e){i=[],n(e)})).on("end",(function(){try{var e=function(e,t,r){switch(e){case"blob":return Qe.newBlob(Qe.transformTo("arraybuffer",t),r);case"base64":return rt.encode(t);default:return Qe.transformTo(e,t)}}(s,function(e,t){var r,n=0,i=null,o=0;for(r=0;r<t.length;r++)o+=t[r].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(i=new Uint8Array(o),r=0;r<t.length;r++)i.set(t[r],n),n+=t[r].length;return i;case"nodebuffer":return a.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}}(o,i),l);r(e)}catch(e){n(e)}i=[]})).resume()}))}(this,e)},on:function(e,t){var r=this;return"data"===e?this._worker.on(e,(function(e){t.call(r,e.data,e.meta)})):this._worker.on(e,(function(){Qe.delay(t,arguments,r)})),this},resume:function(){return Qe.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(e){if(Qe.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw new Error(this._outputType+" is not supported by this method");return new it(this,{objectMode:"nodebuffer"!==this._outputType},e)}};var ot=at,st={base64:!1,binary:!1,dir:!1,createFolders:!0,date:null,compression:null,compressionOptions:null,comment:null,unixPermissions:null,dosPermissions:null},lt=Ze(),ut=Ve;function ct(e){ut.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then((function(e){t.dataIsReady=!0,t.data=e,t.max=e&&e.length||0,t.type=lt.getTypeOf(e),t.isPaused||t._tickAndRepeat()}),(function(e){t.error(e)}))}lt.inherits(ct,ut),ct.prototype.cleanUp=function(){ut.prototype.cleanUp.call(this),this.data=null},ct.prototype.resume=function(){return!!ut.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,lt.delay(this._tickAndRepeat,[],this)),!0)},ct.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(lt.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},ct.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=null,t=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":e=this.data.substring(this.index,t);break;case"uint8array":e=this.data.subarray(this.index,t);break;case"array":case"nodebuffer":e=this.data.slice(this.index,t)}return this.index=t,this.push({data:e,meta:{percent:this.max?this.index/this.max*100:0}})};var ht=ct,ft=Ze(),dt=function(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[r]=e}return t}(),pt=function(e,t){return void 0!==e&&e.length?"string"!==ft.getTypeOf(e)?function(e,t,r,n){var i=dt,a=0+r;e^=-1;for(var o=0;o<a;o++)e=e>>>8^i[255&(e^t[o])];return-1^e}(0|t,e,e.length):function(e,t,r,n){var i=dt,a=0+r;e^=-1;for(var o=0;o<a;o++)e=e>>>8^i[255&(e^t.charCodeAt(o))];return-1^e}(0|t,e,e.length):0},mt=Ve,gt=pt;function vt(){mt.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}Ze().inherits(vt,mt),vt.prototype.processChunk=function(e){this.streamInfo.crc32=gt(e.data,this.streamInfo.crc32||0),this.push(e)};var yt=vt,bt=Ze(),wt=Ve;function kt(e){wt.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}bt.inherits(kt,wt),kt.prototype.processChunk=function(e){if(e){var t=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=t+e.data.length}wt.prototype.processChunk.call(this,e)};var _t=He,St=ht,xt=yt,Ct=kt;function Et(e,t,r,n,i){this.compressedSize=e,this.uncompressedSize=t,this.crc32=r,this.compression=n,this.compressedContent=i}Et.prototype={getContentWorker:function(){var e=new St(_t.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new Ct("data_length")),t=this;return e.on("end",(function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")})),e},getCompressedWorker:function(){return new St(_t.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},Et.createWorkerFrom=function(e,t,r){return e.pipe(new xt).pipe(new Ct("uncompressedSize")).pipe(t.compressWorker(r)).pipe(new Ct("compressedSize")).withStreamInfo("compression",t)};var Pt=Et,Tt=ot,At=ht,Nt=U,Ot=Pt,Rt=Ve,Mt=function(e,t,r){this.name=e,this.dir=r.dir,this.date=r.date,this.comment=r.comment,this.unixPermissions=r.unixPermissions,this.dosPermissions=r.dosPermissions,this._data=t,this._dataBinary=r.binary,this.options={compression:r.compression,compressionOptions:r.compressionOptions}};Mt.prototype={internalStream:function(e){var t=null,r="string";try{if(!e)throw new Error("No output type specified.");var n="string"===(r=e.toLowerCase())||"text"===r;"binarystring"!==r&&"text"!==r||(r="string"),t=this._decompressWorker();var i=!this._dataBinary;i&&!n&&(t=t.pipe(new Nt.Utf8EncodeWorker)),!i&&n&&(t=t.pipe(new Nt.Utf8DecodeWorker))}catch(e){(t=new Rt("error")).error(e)}return new Tt(t,r,"")},async:function(e,t){return this.internalStream(e).accumulate(t)},nodeStream:function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},_compressWorker:function(e,t){if(this._data instanceof Ot&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var r=this._decompressWorker();return this._dataBinary||(r=r.pipe(new Nt.Utf8EncodeWorker)),Ot.createWorkerFrom(r,e,t)},_decompressWorker:function(){return this._data instanceof Ot?this._data.getContentWorker():this._data instanceof Rt?this._data:new At(this._data)}};for(var Bt=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],Dt=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},jt=0;jt<Bt.length;jt++)Mt.prototype[Bt[jt]]=Dt;var Lt=Mt,It={},zt={},Ft={},Ut={};!function(e){var t="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function r(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var n=t.shift();if(n){if("object"!=B(n))throw new TypeError(n+"must be non-object");for(var i in n)r(n,i)&&(e[i]=n[i])}}return e},e.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var n={arraySet:function(e,t,r,n,i){if(t.subarray&&e.subarray)e.set(t.subarray(r,r+n),i);else for(var a=0;a<n;a++)e[i+a]=t[r+a]},flattenChunks:function(e){var t,r,n,i,a,o;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(o=new Uint8Array(n),i=0,t=0,r=e.length;t<r;t++)a=e[t],o.set(a,i),i+=a.length;return o}},i={arraySet:function(e,t,r,n,i){for(var a=0;a<n;a++)e[i+a]=t[r+a]},flattenChunks:function(e){return[].concat.apply([],e)}};e.setTyped=function(t){t?(e.Buf8=Uint8Array,e.Buf16=Uint16Array,e.Buf32=Int32Array,e.assign(e,n)):(e.Buf8=Array,e.Buf16=Array,e.Buf32=Array,e.assign(e,i))},e.setTyped(t)}(Ut);var Wt={},Ht={},Zt={},qt=Ut;function Vt(e){for(var t=e.length;--t>=0;)e[t]=0}var Xt=[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],Gt=[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],Kt=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],Jt=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],Yt=new Array(576);Vt(Yt);var $t=new Array(60);Vt($t);var Qt=new Array(512);Vt(Qt);var er=new Array(256);Vt(er);var tr=new Array(29);Vt(tr);var rr,nr,ir,ar=new Array(30);function or(e,t,r,n,i){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=i,this.has_stree=e&&e.length}function sr(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function lr(e){return e<256?Qt[e]:Qt[256+(e>>>7)]}function ur(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function cr(e,t,r){e.bi_valid>16-r?(e.bi_buf|=t<<e.bi_valid&65535,ur(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=r-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}function hr(e,t,r){cr(e,r[2*t],r[2*t+1])}function fr(e,t){var r=0;do{r|=1&e,e>>>=1,r<<=1}while(--t>0);return r>>>1}function dr(e,t,r){var n,i,a=new Array(16),o=0;for(n=1;n<=15;n++)a[n]=o=o+r[n-1]<<1;for(i=0;i<=t;i++){var s=e[2*i+1];0!==s&&(e[2*i]=fr(a[s]++,s))}}function pr(e){var t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function mr(e){e.bi_valid>8?ur(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function gr(e,t,r,n){var i=2*t,a=2*r;return e[i]<e[a]||e[i]===e[a]&&n[t]<=n[r]}function vr(e,t,r){for(var n=e.heap[r],i=r<<1;i<=e.heap_len&&(i<e.heap_len&&gr(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!gr(t,n,e.heap[i],e.depth));)e.heap[r]=e.heap[i],r=i,i<<=1;e.heap[r]=n}function yr(e,t,r){var n,i,a,o,s=0;if(0!==e.last_lit)do{n=e.pending_buf[e.d_buf+2*s]<<8|e.pending_buf[e.d_buf+2*s+1],i=e.pending_buf[e.l_buf+s],s++,0===n?hr(e,i,t):(hr(e,(a=er[i])+256+1,t),0!==(o=Xt[a])&&cr(e,i-=tr[a],o),hr(e,a=lr(--n),r),0!==(o=Gt[a])&&cr(e,n-=ar[a],o))}while(s<e.last_lit);hr(e,256,t)}function br(e,t){var r,n,i,a=t.dyn_tree,o=t.stat_desc.static_tree,s=t.stat_desc.has_stree,l=t.stat_desc.elems,u=-1;for(e.heap_len=0,e.heap_max=573,r=0;r<l;r++)0!==a[2*r]?(e.heap[++e.heap_len]=u=r,e.depth[r]=0):a[2*r+1]=0;for(;e.heap_len<2;)a[2*(i=e.heap[++e.heap_len]=u<2?++u:0)]=1,e.depth[i]=0,e.opt_len--,s&&(e.static_len-=o[2*i+1]);for(t.max_code=u,r=e.heap_len>>1;r>=1;r--)vr(e,a,r);i=l;do{r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],vr(e,a,1),n=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=n,a[2*i]=a[2*r]+a[2*n],e.depth[i]=(e.depth[r]>=e.depth[n]?e.depth[r]:e.depth[n])+1,a[2*r+1]=a[2*n+1]=i,e.heap[1]=i++,vr(e,a,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var r,n,i,a,o,s,l=t.dyn_tree,u=t.max_code,c=t.stat_desc.static_tree,h=t.stat_desc.has_stree,f=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,p=t.stat_desc.max_length,m=0;for(a=0;a<=15;a++)e.bl_count[a]=0;for(l[2*e.heap[e.heap_max]+1]=0,r=e.heap_max+1;r<573;r++)(a=l[2*l[2*(n=e.heap[r])+1]+1]+1)>p&&(a=p,m++),l[2*n+1]=a,n>u||(e.bl_count[a]++,o=0,n>=d&&(o=f[n-d]),s=l[2*n],e.opt_len+=s*(a+o),h&&(e.static_len+=s*(c[2*n+1]+o)));if(0!==m){do{for(a=p-1;0===e.bl_count[a];)a--;e.bl_count[a]--,e.bl_count[a+1]+=2,e.bl_count[p]--,m-=2}while(m>0);for(a=p;0!==a;a--)for(n=e.bl_count[a];0!==n;)(i=e.heap[--r])>u||(l[2*i+1]!==a&&(e.opt_len+=(a-l[2*i+1])*l[2*i],l[2*i+1]=a),n--)}}(e,t),dr(a,u,e.bl_count)}function wr(e,t,r){var n,i,a=-1,o=t[1],s=0,l=7,u=4;for(0===o&&(l=138,u=3),t[2*(r+1)+1]=65535,n=0;n<=r;n++)i=o,o=t[2*(n+1)+1],++s<l&&i===o||(s<u?e.bl_tree[2*i]+=s:0!==i?(i!==a&&e.bl_tree[2*i]++,e.bl_tree[32]++):s<=10?e.bl_tree[34]++:e.bl_tree[36]++,s=0,a=i,0===o?(l=138,u=3):i===o?(l=6,u=3):(l=7,u=4))}function kr(e,t,r){var n,i,a=-1,o=t[1],s=0,l=7,u=4;for(0===o&&(l=138,u=3),n=0;n<=r;n++)if(i=o,o=t[2*(n+1)+1],!(++s<l&&i===o)){if(s<u)do{hr(e,i,e.bl_tree)}while(0!=--s);else 0!==i?(i!==a&&(hr(e,i,e.bl_tree),s--),hr(e,16,e.bl_tree),cr(e,s-3,2)):s<=10?(hr(e,17,e.bl_tree),cr(e,s-3,3)):(hr(e,18,e.bl_tree),cr(e,s-11,7));s=0,a=i,0===o?(l=138,u=3):i===o?(l=6,u=3):(l=7,u=4)}}Vt(ar);var _r=!1;function Sr(e,t,r,n){cr(e,0+(n?1:0),3),function(e,t,r,n){mr(e),ur(e,r),ur(e,~r),qt.arraySet(e.pending_buf,e.window,t,r,e.pending),e.pending+=r}(e,t,r)}Zt._tr_init=function(e){_r||(function(){var e,t,r,n,i,a=new Array(16);for(r=0,n=0;n<28;n++)for(tr[n]=r,e=0;e<1<<Xt[n];e++)er[r++]=n;for(er[r-1]=n,i=0,n=0;n<16;n++)for(ar[n]=i,e=0;e<1<<Gt[n];e++)Qt[i++]=n;for(i>>=7;n<30;n++)for(ar[n]=i<<7,e=0;e<1<<Gt[n]-7;e++)Qt[256+i++]=n;for(t=0;t<=15;t++)a[t]=0;for(e=0;e<=143;)Yt[2*e+1]=8,e++,a[8]++;for(;e<=255;)Yt[2*e+1]=9,e++,a[9]++;for(;e<=279;)Yt[2*e+1]=7,e++,a[7]++;for(;e<=287;)Yt[2*e+1]=8,e++,a[8]++;for(dr(Yt,287,a),e=0;e<30;e++)$t[2*e+1]=5,$t[2*e]=fr(e,5);rr=new or(Yt,Xt,257,286,15),nr=new or($t,Gt,0,30,15),ir=new or(new Array(0),Kt,0,19,7)}(),_r=!0),e.l_desc=new sr(e.dyn_ltree,rr),e.d_desc=new sr(e.dyn_dtree,nr),e.bl_desc=new sr(e.bl_tree,ir),e.bi_buf=0,e.bi_valid=0,pr(e)},Zt._tr_stored_block=Sr,Zt._tr_flush_block=function(e,t,r,n){var i,a,o=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,r=4093624447;for(t=0;t<=31;t++,r>>>=1)if(1&r&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<256;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),br(e,e.l_desc),br(e,e.d_desc),o=function(e){var t;for(wr(e,e.dyn_ltree,e.l_desc.max_code),wr(e,e.dyn_dtree,e.d_desc.max_code),br(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*Jt[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),i=e.opt_len+3+7>>>3,(a=e.static_len+3+7>>>3)<=i&&(i=a)):i=a=r+5,r+4<=i&&-1!==t?Sr(e,t,r,n):4===e.strategy||a===i?(cr(e,2+(n?1:0),3),yr(e,Yt,$t)):(cr(e,4+(n?1:0),3),function(e,t,r,n){var i;for(cr(e,t-257,5),cr(e,r-1,5),cr(e,n-4,4),i=0;i<n;i++)cr(e,e.bl_tree[2*Jt[i]+1],3);kr(e,e.dyn_ltree,t-1),kr(e,e.dyn_dtree,r-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,o+1),yr(e,e.dyn_ltree,e.dyn_dtree)),pr(e),n&&mr(e)},Zt._tr_tally=function(e,t,r){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&r,e.last_lit++,0===t?e.dyn_ltree[2*r]++:(e.matches++,t--,e.dyn_ltree[2*(er[r]+256+1)]++,e.dyn_dtree[2*lr(t)]++),e.last_lit===e.lit_bufsize-1},Zt._tr_align=function(e){cr(e,2,3),hr(e,256,Yt),function(e){16===e.bi_valid?(ur(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)};var xr,Cr=function(e,t,r,n){for(var i=65535&e|0,a=e>>>16&65535|0,o=0;0!==r;){r-=o=r>2e3?2e3:r;do{a=a+(i=i+t[n++]|0)|0}while(--o);i%=65521,a%=65521}return i|a<<16|0},Er=function(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[r]=e}return t}(),Pr=function(e,t,r,n){var i=Er,a=n+r;e^=-1;for(var o=n;o<a;o++)e=e>>>8^i[255&(e^t[o])];return-1^e},Tr={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"},Ar=Ut,Nr=Zt,Or=Cr,Rr=Pr,Mr=Tr,Br=258,Dr=262;function jr(e,t){return e.msg=Mr[t],t}function Lr(e){return(e<<1)-(e>4?9:0)}function Ir(e){for(var t=e.length;--t>=0;)e[t]=0}function zr(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),0!==r&&(Ar.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,0===t.pending&&(t.pending_out=0))}function Fr(e,t){Nr._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,zr(e.strm)}function Ur(e,t){e.pending_buf[e.pending++]=t}function Wr(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function Hr(e,t){var r,n,i=e.max_chain_length,a=e.strstart,o=e.prev_length,s=e.nice_match,l=e.strstart>e.w_size-Dr?e.strstart-(e.w_size-Dr):0,u=e.window,c=e.w_mask,h=e.prev,f=e.strstart+Br,d=u[a+o-1],p=u[a+o];e.prev_length>=e.good_match&&(i>>=2),s>e.lookahead&&(s=e.lookahead);do{if(u[(r=t)+o]===p&&u[r+o-1]===d&&u[r]===u[a]&&u[++r]===u[a+1]){a+=2,r++;do{}while(u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&u[++a]===u[++r]&&a<f);if(n=Br-(f-a),a=f-Br,n>o){if(e.match_start=t,o=n,n>=s)break;d=u[a+o-1],p=u[a+o]}}}while((t=h[t&c])>l&&0!=--i);return o<=e.lookahead?o:e.lookahead}function Zr(e){var t,r,n,i,a,o,s,l,u,c,h=e.w_size;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=h+(h-Dr)){Ar.arraySet(e.window,e.window,h,h,0),e.match_start-=h,e.strstart-=h,e.block_start-=h,t=r=e.hash_size;do{n=e.head[--t],e.head[t]=n>=h?n-h:0}while(--r);t=r=h;do{n=e.prev[--t],e.prev[t]=n>=h?n-h:0}while(--r);i+=h}if(0===e.strm.avail_in)break;if(o=e.strm,s=e.window,l=e.strstart+e.lookahead,u=i,c=void 0,(c=o.avail_in)>u&&(c=u),r=0===c?0:(o.avail_in-=c,Ar.arraySet(s,o.input,o.next_in,c,l),1===o.state.wrap?o.adler=Or(o.adler,s,c,l):2===o.state.wrap&&(o.adler=Rr(o.adler,s,c,l)),o.next_in+=c,o.total_in+=c,c),e.lookahead+=r,e.lookahead+e.insert>=3)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+3-1])&e.hash_mask,e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<Dr&&0!==e.strm.avail_in)}function qr(e,t){for(var r,n;;){if(e.lookahead<Dr){if(Zr(e),e.lookahead<Dr&&0===t)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=3&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==r&&e.strstart-r<=e.w_size-Dr&&(e.match_length=Hr(e,r)),e.match_length>=3)if(n=Nr._tr_tally(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=Nr._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(Fr(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,4===t?(Fr(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Fr(e,!1),0===e.strm.avail_out)?1:2}function Vr(e,t){for(var r,n,i;;){if(e.lookahead<Dr){if(Zr(e),e.lookahead<Dr&&0===t)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=3&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==r&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-Dr&&(e.match_length=Hr(e,r),e.match_length<=5&&(1===e.strategy||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-3,n=Nr._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=i&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,n&&(Fr(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((n=Nr._tr_tally(e,0,e.window[e.strstart-1]))&&Fr(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=Nr._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,4===t?(Fr(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Fr(e,!1),0===e.strm.avail_out)?1:2}function Xr(e,t,r,n,i){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=i}function Gr(){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=8,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 Ar.Buf16(1146),this.dyn_dtree=new Ar.Buf16(122),this.bl_tree=new Ar.Buf16(78),Ir(this.dyn_ltree),Ir(this.dyn_dtree),Ir(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Ar.Buf16(16),this.heap=new Ar.Buf16(573),Ir(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Ar.Buf16(573),Ir(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 Kr(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=2,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?42:113,e.adler=2===t.wrap?0:1,t.last_flush=0,Nr._tr_init(t),0):jr(e,-2)}function Jr(e){var t,r=Kr(e);return 0===r&&((t=e.state).window_size=2*t.w_size,Ir(t.head),t.max_lazy_match=xr[t.level].max_lazy,t.good_match=xr[t.level].good_length,t.nice_match=xr[t.level].nice_length,t.max_chain_length=xr[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=2,t.match_available=0,t.ins_h=0),r}function Yr(e,t,r,n,i,a){if(!e)return-2;var o=1;if(-1===t&&(t=6),n<0?(o=0,n=-n):n>15&&(o=2,n-=16),i<1||i>9||8!==r||n<8||n>15||t<0||t>9||a<0||a>4)return jr(e,-2);8===n&&(n=9);var s=new Gr;return e.state=s,s.strm=e,s.wrap=o,s.gzhead=null,s.w_bits=n,s.w_size=1<<s.w_bits,s.w_mask=s.w_size-1,s.hash_bits=i+7,s.hash_size=1<<s.hash_bits,s.hash_mask=s.hash_size-1,s.hash_shift=~~((s.hash_bits+3-1)/3),s.window=new Ar.Buf8(2*s.w_size),s.head=new Ar.Buf16(s.hash_size),s.prev=new Ar.Buf16(s.w_size),s.lit_bufsize=1<<i+6,s.pending_buf_size=4*s.lit_bufsize,s.pending_buf=new Ar.Buf8(s.pending_buf_size),s.d_buf=1*s.lit_bufsize,s.l_buf=3*s.lit_bufsize,s.level=t,s.strategy=a,s.method=r,Jr(e)}xr=[new Xr(0,0,0,0,(function(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(Zr(e),0===e.lookahead&&0===t)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,Fr(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-Dr&&(Fr(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Fr(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(Fr(e,!1),e.strm.avail_out),1)})),new Xr(4,4,8,4,qr),new Xr(4,5,16,8,qr),new Xr(4,6,32,32,qr),new Xr(4,4,16,16,Vr),new Xr(8,16,32,32,Vr),new Xr(8,16,128,128,Vr),new Xr(8,32,128,256,Vr),new Xr(32,128,258,1024,Vr),new Xr(32,258,258,4096,Vr)],Ht.deflateInit=function(e,t){return Yr(e,t,8,15,8,0)},Ht.deflateInit2=Yr,Ht.deflateReset=Jr,Ht.deflateResetKeep=Kr,Ht.deflateSetHeader=function(e,t){return e&&e.state?2!==e.state.wrap?-2:(e.state.gzhead=t,0):-2},Ht.deflate=function(e,t){var r,n,i,a;if(!e||!e.state||t>5||t<0)return e?jr(e,-2):-2;if(n=e.state,!e.output||!e.input&&0!==e.avail_in||666===n.status&&4!==t)return jr(e,0===e.avail_out?-5:-2);if(n.strm=e,r=n.last_flush,n.last_flush=t,42===n.status)if(2===n.wrap)e.adler=0,Ur(n,31),Ur(n,139),Ur(n,8),n.gzhead?(Ur(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),Ur(n,255&n.gzhead.time),Ur(n,n.gzhead.time>>8&255),Ur(n,n.gzhead.time>>16&255),Ur(n,n.gzhead.time>>24&255),Ur(n,9===n.level?2:n.strategy>=2||n.level<2?4:0),Ur(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(Ur(n,255&n.gzhead.extra.length),Ur(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=Rr(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69):(Ur(n,0),Ur(n,0),Ur(n,0),Ur(n,0),Ur(n,0),Ur(n,9===n.level?2:n.strategy>=2||n.level<2?4:0),Ur(n,3),n.status=113);else{var o=8+(n.w_bits-8<<4)<<8;o|=(n.strategy>=2||n.level<2?0:n.level<6?1:6===n.level?2:3)<<6,0!==n.strstart&&(o|=32),o+=31-o%31,n.status=113,Wr(n,o),0!==n.strstart&&(Wr(n,e.adler>>>16),Wr(n,65535&e.adler)),e.adler=1}if(69===n.status)if(n.gzhead.extra){for(i=n.pending;n.gzindex<(65535&n.gzhead.extra.length)&&(n.pending!==n.pending_buf_size||(n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),zr(e),i=n.pending,n.pending!==n.pending_buf_size));)Ur(n,255&n.gzhead.extra[n.gzindex]),n.gzindex++;n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=73)}else n.status=73;if(73===n.status)if(n.gzhead.name){i=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),zr(e),i=n.pending,n.pending===n.pending_buf_size)){a=1;break}a=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0,Ur(n,a)}while(0!==a);n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),0===a&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){i=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),zr(e),i=n.pending,n.pending===n.pending_buf_size)){a=1;break}a=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0,Ur(n,a)}while(0!==a);n.gzhead.hcrc&&n.pending>i&&(e.adler=Rr(e.adler,n.pending_buf,n.pending-i,i)),0===a&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&zr(e),n.pending+2<=n.pending_buf_size&&(Ur(n,255&e.adler),Ur(n,e.adler>>8&255),e.adler=0,n.status=113)):n.status=113),0!==n.pending){if(zr(e),0===e.avail_out)return n.last_flush=-1,0}else if(0===e.avail_in&&Lr(t)<=Lr(r)&&4!==t)return jr(e,-5);if(666===n.status&&0!==e.avail_in)return jr(e,-5);if(0!==e.avail_in||0!==n.lookahead||0!==t&&666!==n.status){var s=2===n.strategy?function(e,t){for(var r;;){if(0===e.lookahead&&(Zr(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,r=Nr._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(Fr(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Fr(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Fr(e,!1),0===e.strm.avail_out)?1:2}(n,t):3===n.strategy?function(e,t){for(var r,n,i,a,o=e.window;;){if(e.lookahead<=Br){if(Zr(e),e.lookahead<=Br&&0===t)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&(n=o[i=e.strstart-1])===o[++i]&&n===o[++i]&&n===o[++i]){a=e.strstart+Br;do{}while(n===o[++i]&&n===o[++i]&&n===o[++i]&&n===o[++i]&&n===o[++i]&&n===o[++i]&&n===o[++i]&&n===o[++i]&&i<a);e.match_length=Br-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(r=Nr._tr_tally(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=Nr._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(Fr(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Fr(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Fr(e,!1),0===e.strm.avail_out)?1:2}(n,t):xr[n.level].func(n,t);if(3!==s&&4!==s||(n.status=666),1===s||3===s)return 0===e.avail_out&&(n.last_flush=-1),0;if(2===s&&(1===t?Nr._tr_align(n):5!==t&&(Nr._tr_stored_block(n,0,0,!1),3===t&&(Ir(n.head),0===n.lookahead&&(n.strstart=0,n.block_start=0,n.insert=0))),zr(e),0===e.avail_out))return n.last_flush=-1,0}return 4!==t?0:n.wrap<=0?1:(2===n.wrap?(Ur(n,255&e.adler),Ur(n,e.adler>>8&255),Ur(n,e.adler>>16&255),Ur(n,e.adler>>24&255),Ur(n,255&e.total_in),Ur(n,e.total_in>>8&255),Ur(n,e.total_in>>16&255),Ur(n,e.total_in>>24&255)):(Wr(n,e.adler>>>16),Wr(n,65535&e.adler)),zr(e),n.wrap>0&&(n.wrap=-n.wrap),0!==n.pending?0:1)},Ht.deflateEnd=function(e){var t;return e&&e.state?42!==(t=e.state.status)&&69!==t&&73!==t&&91!==t&&103!==t&&113!==t&&666!==t?jr(e,-2):(e.state=null,113===t?jr(e,-3):0):-2},Ht.deflateSetDictionary=function(e,t){var r,n,i,a,o,s,l,u,c=t.length;if(!e||!e.state)return-2;if(2===(a=(r=e.state).wrap)||1===a&&42!==r.status||r.lookahead)return-2;for(1===a&&(e.adler=Or(e.adler,t,c,0)),r.wrap=0,c>=r.w_size&&(0===a&&(Ir(r.head),r.strstart=0,r.block_start=0,r.insert=0),u=new Ar.Buf8(r.w_size),Ar.arraySet(u,t,c-r.w_size,r.w_size,0),t=u,c=r.w_size),o=e.avail_in,s=e.next_in,l=e.input,e.avail_in=c,e.next_in=0,e.input=t,Zr(r);r.lookahead>=3;){n=r.strstart,i=r.lookahead-2;do{r.ins_h=(r.ins_h<<r.hash_shift^r.window[n+3-1])&r.hash_mask,r.prev[n&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=n,n++}while(--i);r.strstart=n,r.lookahead=2,Zr(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=s,e.input=l,e.avail_in=o,r.wrap=a,0},Ht.deflateInfo="pako deflate (from Nodeca project)";var $r={},Qr=Ut,en=!0,tn=!0;try{String.fromCharCode.apply(null,[0])}catch(Ta){en=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(Ta){tn=!1}for(var rn=new Qr.Buf8(256),nn=0;nn<256;nn++)rn[nn]=nn>=252?6:nn>=248?5:nn>=240?4:nn>=224?3:nn>=192?2:1;function an(e,t){if(t<65534&&(e.subarray&&tn||!e.subarray&&en))return String.fromCharCode.apply(null,Qr.shrinkBuf(e,t));for(var r="",n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r}rn[254]=rn[254]=1,$r.string2buf=function(e){var t,r,n,i,a,o=e.length,s=0;for(i=0;i<o;i++)55296==(64512&(r=e.charCodeAt(i)))&&i+1<o&&56320==(64512&(n=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(n-56320),i++),s+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Qr.Buf8(s),a=0,i=0;a<s;i++)55296==(64512&(r=e.charCodeAt(i)))&&i+1<o&&56320==(64512&(n=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(n-56320),i++),r<128?t[a++]=r:r<2048?(t[a++]=192|r>>>6,t[a++]=128|63&r):r<65536?(t[a++]=224|r>>>12,t[a++]=128|r>>>6&63,t[a++]=128|63&r):(t[a++]=240|r>>>18,t[a++]=128|r>>>12&63,t[a++]=128|r>>>6&63,t[a++]=128|63&r);return t},$r.buf2binstring=function(e){return an(e,e.length)},$r.binstring2buf=function(e){for(var t=new Qr.Buf8(e.length),r=0,n=t.length;r<n;r++)t[r]=e.charCodeAt(r);return t},$r.buf2string=function(e,t){var r,n,i,a,o=t||e.length,s=new Array(2*o);for(n=0,r=0;r<o;)if((i=e[r++])<128)s[n++]=i;else if((a=rn[i])>4)s[n++]=65533,r+=a-1;else{for(i&=2===a?31:3===a?15:7;a>1&&r<o;)i=i<<6|63&e[r++],a--;a>1?s[n++]=65533:i<65536?s[n++]=i:(i-=65536,s[n++]=55296|i>>10&1023,s[n++]=56320|1023&i)}return an(s,n)},$r.utf8border=function(e,t){var r;for((t=t||e.length)>e.length&&(t=e.length),r=t-1;r>=0&&128==(192&e[r]);)r--;return r<0||0===r?t:r+rn[e[r]]>t?r:t};var on=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},sn=Ht,ln=Ut,un=$r,cn=Tr,hn=on,fn=Object.prototype.toString;function dn(e){if(!(this instanceof dn))return new dn(e);this.options=ln.assign({level:-1,method:8,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new hn,this.strm.avail_out=0;var r=sn.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(0!==r)throw new Error(cn[r]);if(t.header&&sn.deflateSetHeader(this.strm,t.header),t.dictionary){var n;if(n="string"==typeof t.dictionary?un.string2buf(t.dictionary):"[object ArrayBuffer]"===fn.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,0!==(r=sn.deflateSetDictionary(this.strm,n)))throw new Error(cn[r]);this._dict_set=!0}}function pn(e,t){var r=new dn(t);if(r.push(e,!0),r.err)throw r.msg||cn[r.err];return r.result}dn.prototype.push=function(e,t){var r,n,i=this.strm,a=this.options.chunkSize;if(this.ended)return!1;n=t===~~t?t:!0===t?4:0,"string"==typeof e?i.input=un.string2buf(e):"[object ArrayBuffer]"===fn.call(e)?i.input=new Uint8Array(e):i.input=e,i.next_in=0,i.avail_in=i.input.length;do{if(0===i.avail_out&&(i.output=new ln.Buf8(a),i.next_out=0,i.avail_out=a),1!==(r=sn.deflate(i,n))&&0!==r)return this.onEnd(r),this.ended=!0,!1;0!==i.avail_out&&(0!==i.avail_in||4!==n&&2!==n)||("string"===this.options.to?this.onData(un.buf2binstring(ln.shrinkBuf(i.output,i.next_out))):this.onData(ln.shrinkBuf(i.output,i.next_out)))}while((i.avail_in>0||0===i.avail_out)&&1!==r);return 4===n?(r=sn.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,0===r):2!==n||(this.onEnd(0),i.avail_out=0,!0)},dn.prototype.onData=function(e){this.chunks.push(e)},dn.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=ln.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},Wt.Deflate=dn,Wt.deflate=pn,Wt.deflateRaw=function(e,t){return(t=t||{}).raw=!0,pn(e,t)},Wt.gzip=function(e,t){return(t=t||{}).gzip=!0,pn(e,t)};var mn={},gn={},vn=Ut,yn=[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],bn=[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],wn=[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],kn=[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],_n=Ut,Sn=Cr,xn=Pr,Cn=function(e,t){var r,n,i,a,o,s,l,u,c,h,f,d,p,m,g,v,y,b,w,k,_,S,x,C,E;r=e.state,n=e.next_in,C=e.input,i=n+(e.avail_in-5),a=e.next_out,E=e.output,o=a-(t-e.avail_out),s=a+(e.avail_out-257),l=r.dmax,u=r.wsize,c=r.whave,h=r.wnext,f=r.window,d=r.hold,p=r.bits,m=r.lencode,g=r.distcode,v=(1<<r.lenbits)-1,y=(1<<r.distbits)-1;e:do{p<15&&(d+=C[n++]<<p,p+=8,d+=C[n++]<<p,p+=8),b=m[d&v];t:for(;;){if(d>>>=w=b>>>24,p-=w,0==(w=b>>>16&255))E[a++]=65535&b;else{if(!(16&w)){if(0==(64&w)){b=m[(65535&b)+(d&(1<<w)-1)];continue t}if(32&w){r.mode=12;break e}e.msg="invalid literal/length code",r.mode=30;break e}k=65535&b,(w&=15)&&(p<w&&(d+=C[n++]<<p,p+=8),k+=d&(1<<w)-1,d>>>=w,p-=w),p<15&&(d+=C[n++]<<p,p+=8,d+=C[n++]<<p,p+=8),b=g[d&y];r:for(;;){if(d>>>=w=b>>>24,p-=w,!(16&(w=b>>>16&255))){if(0==(64&w)){b=g[(65535&b)+(d&(1<<w)-1)];continue r}e.msg="invalid distance code",r.mode=30;break e}if(_=65535&b,p<(w&=15)&&(d+=C[n++]<<p,(p+=8)<w&&(d+=C[n++]<<p,p+=8)),(_+=d&(1<<w)-1)>l){e.msg="invalid distance too far back",r.mode=30;break e}if(d>>>=w,p-=w,_>(w=a-o)){if((w=_-w)>c&&r.sane){e.msg="invalid distance too far back",r.mode=30;break e}if(S=0,x=f,0===h){if(S+=u-w,w<k){k-=w;do{E[a++]=f[S++]}while(--w);S=a-_,x=E}}else if(h<w){if(S+=u+h-w,(w-=h)<k){k-=w;do{E[a++]=f[S++]}while(--w);if(S=0,h<k){k-=w=h;do{E[a++]=f[S++]}while(--w);S=a-_,x=E}}}else if(S+=h-w,w<k){k-=w;do{E[a++]=f[S++]}while(--w);S=a-_,x=E}for(;k>2;)E[a++]=x[S++],E[a++]=x[S++],E[a++]=x[S++],k-=3;k&&(E[a++]=x[S++],k>1&&(E[a++]=x[S++]))}else{S=a-_;do{E[a++]=E[S++],E[a++]=E[S++],E[a++]=E[S++],k-=3}while(k>2);k&&(E[a++]=E[S++],k>1&&(E[a++]=E[S++]))}break}}break}}while(n<i&&a<s);n-=k=p>>3,d&=(1<<(p-=k<<3))-1,e.next_in=n,e.next_out=a,e.avail_in=n<i?i-n+5:5-(n-i),e.avail_out=a<s?s-a+257:257-(a-s),r.hold=d,r.bits=p},En=function(e,t,r,n,i,a,o,s){var l,u,c,h,f,d,p,m,g,v=s.bits,y=0,b=0,w=0,k=0,_=0,S=0,x=0,C=0,E=0,P=0,T=null,A=0,N=new vn.Buf16(16),O=new vn.Buf16(16),R=null,M=0;for(y=0;y<=15;y++)N[y]=0;for(b=0;b<n;b++)N[t[r+b]]++;for(_=v,k=15;k>=1&&0===N[k];k--);if(_>k&&(_=k),0===k)return i[a++]=20971520,i[a++]=20971520,s.bits=1,0;for(w=1;w<k&&0===N[w];w++);for(_<w&&(_=w),C=1,y=1;y<=15;y++)if(C<<=1,(C-=N[y])<0)return-1;if(C>0&&(0===e||1!==k))return-1;for(O[1]=0,y=1;y<15;y++)O[y+1]=O[y]+N[y];for(b=0;b<n;b++)0!==t[r+b]&&(o[O[t[r+b]]++]=b);if(0===e?(T=R=o,d=19):1===e?(T=yn,A-=257,R=bn,M-=257,d=256):(T=wn,R=kn,d=-1),P=0,b=0,y=w,f=a,S=_,x=0,c=-1,h=(E=1<<_)-1,1===e&&E>852||2===e&&E>592)return 1;for(;;){p=y-x,o[b]<d?(m=0,g=o[b]):o[b]>d?(m=R[M+o[b]],g=T[A+o[b]]):(m=96,g=0),l=1<<y-x,w=u=1<<S;do{i[f+(P>>x)+(u-=l)]=p<<24|m<<16|g|0}while(0!==u);for(l=1<<y-1;P&l;)l>>=1;if(0!==l?(P&=l-1,P+=l):P=0,b++,0==--N[y]){if(y===k)break;y=t[r+o[b]]}if(y>_&&(P&h)!==c){for(0===x&&(x=_),f+=w,C=1<<(S=y-x);S+x<k&&!((C-=N[S+x])<=0);)S++,C<<=1;if(E+=1<<S,1===e&&E>852||2===e&&E>592)return 1;i[c=P&h]=_<<24|S<<16|f-a|0}}return 0!==P&&(i[f+P]=y-x<<24|64<<16|0),s.bits=_,0};function Pn(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function Tn(){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}function An(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new _n.Buf32(852),t.distcode=t.distdyn=new _n.Buf32(592),t.sane=1,t.back=-1,0):-2}function Nn(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,An(e)):-2}function On(e,t){var r,n;return e&&e.state?(n=e.state,t<0?(r=0,t=-t):(r=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?-2:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,Nn(e))):-2}function Rn(e,t){var r,n;return e?(n=new Tn,e.state=n,n.window=null,0!==(r=On(e,t))&&(e.state=null),r):-2}var Mn,Bn,Dn=!0;function jn(e){if(Dn){var t;for(Mn=new _n.Buf32(512),Bn=new _n.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(En(1,e.lens,0,288,Mn,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;En(2,e.lens,0,32,Bn,0,e.work,{bits:5}),Dn=!1}e.lencode=Mn,e.lenbits=9,e.distcode=Bn,e.distbits=5}function Ln(e,t,r,n){var i,a=e.state;return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new _n.Buf8(a.wsize)),n>=a.wsize?(_n.arraySet(a.window,t,r-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):((i=a.wsize-a.wnext)>n&&(i=n),_n.arraySet(a.window,t,r-n,i,a.wnext),(n-=i)?(_n.arraySet(a.window,t,r-n,n,0),a.wnext=n,a.whave=a.wsize):(a.wnext+=i,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=i))),0}gn.inflateReset=Nn,gn.inflateReset2=On,gn.inflateResetKeep=An,gn.inflateInit=function(e){return Rn(e,15)},gn.inflateInit2=Rn,gn.inflate=function(e,t){var r,n,i,a,o,s,l,u,c,h,f,d,p,m,g,v,y,b,w,k,_,S,x,C,E=0,P=new _n.Buf8(4),T=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return-2;12===(r=e.state).mode&&(r.mode=13),o=e.next_out,i=e.output,l=e.avail_out,a=e.next_in,n=e.input,s=e.avail_in,u=r.hold,c=r.bits,h=s,f=l,S=0;e:for(;;)switch(r.mode){case 1:if(0===r.wrap){r.mode=13;break}for(;c<16;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(2&r.wrap&&35615===u){r.check=0,P[0]=255&u,P[1]=u>>>8&255,r.check=xn(r.check,P,2,0),u=0,c=0,r.mode=2;break}if(r.flags=0,r.head&&(r.head.done=!1),!(1&r.wrap)||(((255&u)<<8)+(u>>8))%31){e.msg="incorrect header check",r.mode=30;break}if(8!=(15&u)){e.msg="unknown compression method",r.mode=30;break}if(c-=4,_=8+(15&(u>>>=4)),0===r.wbits)r.wbits=_;else if(_>r.wbits){e.msg="invalid window size",r.mode=30;break}r.dmax=1<<_,e.adler=r.check=1,r.mode=512&u?10:12,u=0,c=0;break;case 2:for(;c<16;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(r.flags=u,8!=(255&r.flags)){e.msg="unknown compression method",r.mode=30;break}if(57344&r.flags){e.msg="unknown header flags set",r.mode=30;break}r.head&&(r.head.text=u>>8&1),512&r.flags&&(P[0]=255&u,P[1]=u>>>8&255,r.check=xn(r.check,P,2,0)),u=0,c=0,r.mode=3;case 3:for(;c<32;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.head&&(r.head.time=u),512&r.flags&&(P[0]=255&u,P[1]=u>>>8&255,P[2]=u>>>16&255,P[3]=u>>>24&255,r.check=xn(r.check,P,4,0)),u=0,c=0,r.mode=4;case 4:for(;c<16;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.head&&(r.head.xflags=255&u,r.head.os=u>>8),512&r.flags&&(P[0]=255&u,P[1]=u>>>8&255,r.check=xn(r.check,P,2,0)),u=0,c=0,r.mode=5;case 5:if(1024&r.flags){for(;c<16;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.length=u,r.head&&(r.head.extra_len=u),512&r.flags&&(P[0]=255&u,P[1]=u>>>8&255,r.check=xn(r.check,P,2,0)),u=0,c=0}else r.head&&(r.head.extra=null);r.mode=6;case 6:if(1024&r.flags&&((d=r.length)>s&&(d=s),d&&(r.head&&(_=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),_n.arraySet(r.head.extra,n,a,d,_)),512&r.flags&&(r.check=xn(r.check,n,d,a)),s-=d,a+=d,r.length-=d),r.length))break e;r.length=0,r.mode=7;case 7:if(2048&r.flags){if(0===s)break e;d=0;do{_=n[a+d++],r.head&&_&&r.length<65536&&(r.head.name+=String.fromCharCode(_))}while(_&&d<s);if(512&r.flags&&(r.check=xn(r.check,n,d,a)),s-=d,a+=d,_)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=8;case 8:if(4096&r.flags){if(0===s)break e;d=0;do{_=n[a+d++],r.head&&_&&r.length<65536&&(r.head.comment+=String.fromCharCode(_))}while(_&&d<s);if(512&r.flags&&(r.check=xn(r.check,n,d,a)),s-=d,a+=d,_)break e}else r.head&&(r.head.comment=null);r.mode=9;case 9:if(512&r.flags){for(;c<16;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(u!==(65535&r.check)){e.msg="header crc mismatch",r.mode=30;break}u=0,c=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=12;break;case 10:for(;c<32;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}e.adler=r.check=Pn(u),u=0,c=0,r.mode=11;case 11:if(0===r.havedict)return e.next_out=o,e.avail_out=l,e.next_in=a,e.avail_in=s,r.hold=u,r.bits=c,2;e.adler=r.check=1,r.mode=12;case 12:if(5===t||6===t)break e;case 13:if(r.last){u>>>=7&c,c-=7&c,r.mode=27;break}for(;c<3;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}switch(r.last=1&u,c-=1,3&(u>>>=1)){case 0:r.mode=14;break;case 1:if(jn(r),r.mode=20,6===t){u>>>=2,c-=2;break e}break;case 2:r.mode=17;break;case 3:e.msg="invalid block type",r.mode=30}u>>>=2,c-=2;break;case 14:for(u>>>=7&c,c-=7&c;c<32;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if((65535&u)!=(u>>>16^65535)){e.msg="invalid stored block lengths",r.mode=30;break}if(r.length=65535&u,u=0,c=0,r.mode=15,6===t)break e;case 15:r.mode=16;case 16:if(d=r.length){if(d>s&&(d=s),d>l&&(d=l),0===d)break e;_n.arraySet(i,n,a,d,o),s-=d,a+=d,l-=d,o+=d,r.length-=d;break}r.mode=12;break;case 17:for(;c<14;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(r.nlen=257+(31&u),u>>>=5,c-=5,r.ndist=1+(31&u),u>>>=5,c-=5,r.ncode=4+(15&u),u>>>=4,c-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=30;break}r.have=0,r.mode=18;case 18:for(;r.have<r.ncode;){for(;c<3;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.lens[T[r.have++]]=7&u,u>>>=3,c-=3}for(;r.have<19;)r.lens[T[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,x={bits:r.lenbits},S=En(0,r.lens,0,19,r.lencode,0,r.work,x),r.lenbits=x.bits,S){e.msg="invalid code lengths set",r.mode=30;break}r.have=0,r.mode=19;case 19:for(;r.have<r.nlen+r.ndist;){for(;v=(E=r.lencode[u&(1<<r.lenbits)-1])>>>16&255,y=65535&E,!((g=E>>>24)<=c);){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(y<16)u>>>=g,c-=g,r.lens[r.have++]=y;else{if(16===y){for(C=g+2;c<C;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(u>>>=g,c-=g,0===r.have){e.msg="invalid bit length repeat",r.mode=30;break}_=r.lens[r.have-1],d=3+(3&u),u>>>=2,c-=2}else if(17===y){for(C=g+3;c<C;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}c-=g,_=0,d=3+(7&(u>>>=g)),u>>>=3,c-=3}else{for(C=g+7;c<C;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}c-=g,_=0,d=11+(127&(u>>>=g)),u>>>=7,c-=7}if(r.have+d>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=30;break}for(;d--;)r.lens[r.have++]=_}}if(30===r.mode)break;if(0===r.lens[256]){e.msg="invalid code -- missing end-of-block",r.mode=30;break}if(r.lenbits=9,x={bits:r.lenbits},S=En(1,r.lens,0,r.nlen,r.lencode,0,r.work,x),r.lenbits=x.bits,S){e.msg="invalid literal/lengths set",r.mode=30;break}if(r.distbits=6,r.distcode=r.distdyn,x={bits:r.distbits},S=En(2,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,x),r.distbits=x.bits,S){e.msg="invalid distances set",r.mode=30;break}if(r.mode=20,6===t)break e;case 20:r.mode=21;case 21:if(s>=6&&l>=258){e.next_out=o,e.avail_out=l,e.next_in=a,e.avail_in=s,r.hold=u,r.bits=c,Cn(e,f),o=e.next_out,i=e.output,l=e.avail_out,a=e.next_in,n=e.input,s=e.avail_in,u=r.hold,c=r.bits,12===r.mode&&(r.back=-1);break}for(r.back=0;v=(E=r.lencode[u&(1<<r.lenbits)-1])>>>16&255,y=65535&E,!((g=E>>>24)<=c);){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(v&&0==(240&v)){for(b=g,w=v,k=y;v=(E=r.lencode[k+((u&(1<<b+w)-1)>>b)])>>>16&255,y=65535&E,!(b+(g=E>>>24)<=c);){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}u>>>=b,c-=b,r.back+=b}if(u>>>=g,c-=g,r.back+=g,r.length=y,0===v){r.mode=26;break}if(32&v){r.back=-1,r.mode=12;break}if(64&v){e.msg="invalid literal/length code",r.mode=30;break}r.extra=15&v,r.mode=22;case 22:if(r.extra){for(C=r.extra;c<C;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.length+=u&(1<<r.extra)-1,u>>>=r.extra,c-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=23;case 23:for(;v=(E=r.distcode[u&(1<<r.distbits)-1])>>>16&255,y=65535&E,!((g=E>>>24)<=c);){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(0==(240&v)){for(b=g,w=v,k=y;v=(E=r.distcode[k+((u&(1<<b+w)-1)>>b)])>>>16&255,y=65535&E,!(b+(g=E>>>24)<=c);){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}u>>>=b,c-=b,r.back+=b}if(u>>>=g,c-=g,r.back+=g,64&v){e.msg="invalid distance code",r.mode=30;break}r.offset=y,r.extra=15&v,r.mode=24;case 24:if(r.extra){for(C=r.extra;c<C;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}r.offset+=u&(1<<r.extra)-1,u>>>=r.extra,c-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=30;break}r.mode=25;case 25:if(0===l)break e;if(d=f-l,r.offset>d){if((d=r.offset-d)>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=30;break}d>r.wnext?(d-=r.wnext,p=r.wsize-d):p=r.wnext-d,d>r.length&&(d=r.length),m=r.window}else m=i,p=o-r.offset,d=r.length;d>l&&(d=l),l-=d,r.length-=d;do{i[o++]=m[p++]}while(--d);0===r.length&&(r.mode=21);break;case 26:if(0===l)break e;i[o++]=r.length,l--,r.mode=21;break;case 27:if(r.wrap){for(;c<32;){if(0===s)break e;s--,u|=n[a++]<<c,c+=8}if(f-=l,e.total_out+=f,r.total+=f,f&&(e.adler=r.check=r.flags?xn(r.check,i,f,o-f):Sn(r.check,i,f,o-f)),f=l,(r.flags?u:Pn(u))!==r.check){e.msg="incorrect data check",r.mode=30;break}u=0,c=0}r.mode=28;case 28:if(r.wrap&&r.flags){for(;c<32;){if(0===s)break e;s--,u+=n[a++]<<c,c+=8}if(u!==(4294967295&r.total)){e.msg="incorrect length check",r.mode=30;break}u=0,c=0}r.mode=29;case 29:S=1;break e;case 30:S=-3;break e;case 31:return-4;default:return-2}return e.next_out=o,e.avail_out=l,e.next_in=a,e.avail_in=s,r.hold=u,r.bits=c,(r.wsize||f!==e.avail_out&&r.mode<30&&(r.mode<27||4!==t))&&Ln(e,e.output,e.next_out,f-e.avail_out),h-=e.avail_in,f-=e.avail_out,e.total_in+=h,e.total_out+=f,r.total+=f,r.wrap&&f&&(e.adler=r.check=r.flags?xn(r.check,i,f,e.next_out-f):Sn(r.check,i,f,e.next_out-f)),e.data_type=r.bits+(r.last?64:0)+(12===r.mode?128:0)+(20===r.mode||15===r.mode?256:0),(0===h&&0===f||4===t)&&0===S&&(S=-5),S},gn.inflateEnd=function(e){if(!e||!e.state)return-2;var t=e.state;return t.window&&(t.window=null),e.state=null,0},gn.inflateGetHeader=function(e,t){var r;return e&&e.state?0==(2&(r=e.state).wrap)?-2:(r.head=t,t.done=!1,0):-2},gn.inflateSetDictionary=function(e,t){var r,n=t.length;return e&&e.state?0!==(r=e.state).wrap&&11!==r.mode?-2:11===r.mode&&Sn(1,t,n,0)!==r.check?-3:Ln(e,t,n,n)?(r.mode=31,-4):(r.havedict=1,0):-2},gn.inflateInfo="pako inflate (from Nodeca project)";var In={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},zn=gn,Fn=Ut,Un=$r,Wn=In,Hn=Tr,Zn=on,qn=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},Vn=Object.prototype.toString;function Xn(e){if(!(this instanceof Xn))return new Xn(e);this.options=Fn.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Zn,this.strm.avail_out=0;var r=zn.inflateInit2(this.strm,t.windowBits);if(r!==Wn.Z_OK)throw new Error(Hn[r]);if(this.header=new qn,zn.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=Un.string2buf(t.dictionary):"[object ArrayBuffer]"===Vn.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=zn.inflateSetDictionary(this.strm,t.dictionary))!==Wn.Z_OK))throw new Error(Hn[r])}function Gn(e,t){var r=new Xn(t);if(r.push(e,!0),r.err)throw r.msg||Hn[r.err];return r.result}Xn.prototype.push=function(e,t){var r,n,i,a,o,s=this.strm,l=this.options.chunkSize,u=this.options.dictionary,c=!1;if(this.ended)return!1;n=t===~~t?t:!0===t?Wn.Z_FINISH:Wn.Z_NO_FLUSH,"string"==typeof e?s.input=Un.binstring2buf(e):"[object ArrayBuffer]"===Vn.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;do{if(0===s.avail_out&&(s.output=new Fn.Buf8(l),s.next_out=0,s.avail_out=l),(r=zn.inflate(s,Wn.Z_NO_FLUSH))===Wn.Z_NEED_DICT&&u&&(r=zn.inflateSetDictionary(this.strm,u)),r===Wn.Z_BUF_ERROR&&!0===c&&(r=Wn.Z_OK,c=!1),r!==Wn.Z_STREAM_END&&r!==Wn.Z_OK)return this.onEnd(r),this.ended=!0,!1;s.next_out&&(0!==s.avail_out&&r!==Wn.Z_STREAM_END&&(0!==s.avail_in||n!==Wn.Z_FINISH&&n!==Wn.Z_SYNC_FLUSH)||("string"===this.options.to?(i=Un.utf8border(s.output,s.next_out),a=s.next_out-i,o=Un.buf2string(s.output,i),s.next_out=a,s.avail_out=l-a,a&&Fn.arraySet(s.output,s.output,i,a,0),this.onData(o)):this.onData(Fn.shrinkBuf(s.output,s.next_out)))),0===s.avail_in&&0===s.avail_out&&(c=!0)}while((s.avail_in>0||0===s.avail_out)&&r!==Wn.Z_STREAM_END);return r===Wn.Z_STREAM_END&&(n=Wn.Z_FINISH),n===Wn.Z_FINISH?(r=zn.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===Wn.Z_OK):n!==Wn.Z_SYNC_FLUSH||(this.onEnd(Wn.Z_OK),s.avail_out=0,!0)},Xn.prototype.onData=function(e){this.chunks.push(e)},Xn.prototype.onEnd=function(e){e===Wn.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=Fn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},mn.Inflate=Xn,mn.inflate=Gn,mn.inflateRaw=function(e,t){return(t=t||{}).raw=!0,Gn(e,t)},mn.ungzip=Gn;var Kn={};(0,Ut.assign)(Kn,Wt,mn,In);var Jn="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,Yn=Kn,$n=Ze(),Qn=Ve,ei=Jn?"uint8array":"array";function ti(e,t){Qn.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}Ft.magic="\b\0",$n.inherits(ti,Qn),ti.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push($n.transformTo(ei,e.data),!1)},ti.prototype.flush=function(){Qn.prototype.flush.call(this),null===this._pako&&this._createPako(),this._pako.push([],!0)},ti.prototype.cleanUp=function(){Qn.prototype.cleanUp.call(this),this._pako=null},ti.prototype._createPako=function(){this._pako=new Yn[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var e=this;this._pako.onData=function(t){e.push({data:t,meta:e.meta})}},Ft.compressWorker=function(e){return new ti("Deflate",e)},Ft.uncompressWorker=function(){return new ti("Inflate",{})};var ri=Ve;zt.STORE={magic:"\0\0",compressWorker:function(){return new ri("STORE compression")},uncompressWorker:function(){return new ri("STORE decompression")}},zt.DEFLATE=Ft;var ni={LOCAL_FILE_HEADER:"PK",CENTRAL_FILE_HEADER:"PK",CENTRAL_DIRECTORY_END:"PK",ZIP64_CENTRAL_DIRECTORY_LOCATOR:"PK",ZIP64_CENTRAL_DIRECTORY_END:"PK",DATA_DESCRIPTOR:"PK\b"},ii=Ze(),ai=Ve,oi=U,si=pt,li=ni,ui=function(e,t){var r,n="";for(r=0;r<t;r++)n+=String.fromCharCode(255&e),e>>>=8;return n},ci=function(e,t,r,n,i,a){var o,s,l=e.file,u=e.compression,c=a!==oi.utf8encode,h=ii.transformTo("string",a(l.name)),f=ii.transformTo("string",oi.utf8encode(l.name)),d=l.comment,p=ii.transformTo("string",a(d)),m=ii.transformTo("string",oi.utf8encode(d)),g=f.length!==l.name.length,v=m.length!==d.length,y="",b="",w="",k=l.dir,_=l.date,S={crc32:0,compressedSize:0,uncompressedSize:0};t&&!r||(S.crc32=e.crc32,S.compressedSize=e.compressedSize,S.uncompressedSize=e.uncompressedSize);var x=0;t&&(x|=8),c||!g&&!v||(x|=2048);var C,E,P=0,T=0;k&&(P|=16),"UNIX"===i?(T=798,P|=(E=C=l.unixPermissions,C||(E=k?16893:33204),(65535&E)<<16)):(T=20,P|=63&(l.dosPermissions||0)),o=_.getUTCHours(),o<<=6,o|=_.getUTCMinutes(),o<<=5,o|=_.getUTCSeconds()/2,s=_.getUTCFullYear()-1980,s<<=4,s|=_.getUTCMonth()+1,s<<=5,s|=_.getUTCDate(),g&&(b=ui(1,1)+ui(si(h),4)+f,y+="up"+ui(b.length,2)+b),v&&(w=ui(1,1)+ui(si(p),4)+m,y+="uc"+ui(w.length,2)+w);var A="";return A+="\n\0",A+=ui(x,2),A+=u.magic,A+=ui(o,2),A+=ui(s,2),A+=ui(S.crc32,4),A+=ui(S.compressedSize,4),A+=ui(S.uncompressedSize,4),A+=ui(h.length,2),A+=ui(y.length,2),{fileRecord:li.LOCAL_FILE_HEADER+A+h+y,dirRecord:li.CENTRAL_FILE_HEADER+ui(T,2)+A+ui(p.length,2)+"\0\0\0\0"+ui(P,4)+ui(n,4)+h+y+p}},hi=function(e){return li.DATA_DESCRIPTOR+ui(e.crc32,4)+ui(e.compressedSize,4)+ui(e.uncompressedSize,4)};function fi(e,t,r,n){ai.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=r,this.encodeFileName=n,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}ii.inherits(fi,ai),fi.prototype.push=function(e){var t=e.meta.percent||0,r=this.entriesCount,n=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,ai.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:r?(t+100*(r-n-1))/r:100}}))},fi.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var r=ci(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:r.fileRecord,meta:{percent:0}})}else this.accumulate=!0},fi.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,r=ci(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(r.dirRecord),t)this.push({data:hi(e),meta:{percent:100}});else for(this.push({data:r.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},fi.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var r=this.bytesWritten-e,n=function(e,t,r,n,i){var a=ii.transformTo("string",i(n));return li.CENTRAL_DIRECTORY_END+"\0\0\0\0"+ui(e,2)+ui(e,2)+ui(t,4)+ui(r,4)+ui(a.length,2)+a}(this.dirRecords.length,r,e,this.zipComment,this.encodeFileName);this.push({data:n,meta:{percent:100}})},fi.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},fi.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()})),e.on("error",(function(e){t.error(e)})),this},fi.prototype.resume=function(){return!!ai.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},fi.prototype.error=function(e){var t=this._sources;if(!ai.prototype.error.call(this,e))return!1;for(var r=0;r<t.length;r++)try{t[r].error(e)}catch(e){}return!0},fi.prototype.lock=function(){ai.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()};var di=zt,pi=fi;It.generateWorker=function(e,t,r){var n=new pi(t.streamFiles,r,t.platform,t.encodeFileName),i=0;try{e.forEach((function(e,r){i++;var a=function(e,t){var r=e||t,n=di[r];if(!n)throw new Error(r+" is not a valid compression method !");return n}(r.options.compression,t.compression),o=r.options.compressionOptions||t.compressionOptions||{},s=r.dir,l=r.date;r._compressWorker(a,o).withStreamInfo("file",{name:e,dir:s,date:l,comment:r.comment||"",unixPermissions:r.unixPermissions,dosPermissions:r.dosPermissions}).pipe(n)})),n.entriesCount=i}catch(e){n.error(e)}return n};var mi=Ze(),gi=Ve;function vi(e,t){gi.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}mi.inherits(vi,gi),vi.prototype._bindStream=function(e){var t=this;this._stream=e,e.pause(),e.on("data",(function(e){t.push({data:e,meta:{percent:0}})})).on("error",(function(e){t.isPaused?this.generatedError=e:t.error(e)})).on("end",(function(){t.isPaused?t._upstreamEnded=!0:t.end()}))},vi.prototype.pause=function(){return!!gi.prototype.pause.call(this)&&(this._stream.pause(),!0)},vi.prototype.resume=function(){return!!gi.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)};var yi=vi,bi=U,wi=Ze(),ki=Ve,_i=ot,Si=st,xi=Pt,Ci=Lt,Ei=It,Pi=We,Ti=yi,Ai=function(e,t,r){var n,i=wi.getTypeOf(t),a=wi.extend(r||{},Si);a.date=a.date||new Date,null!==a.compression&&(a.compression=a.compression.toUpperCase()),"string"==typeof a.unixPermissions&&(a.unixPermissions=parseInt(a.unixPermissions,8)),a.unixPermissions&&16384&a.unixPermissions&&(a.dir=!0),a.dosPermissions&&16&a.dosPermissions&&(a.dir=!0),a.dir&&(e=Oi(e)),a.createFolders&&(n=Ni(e))&&Ri.call(this,n,!0);var o="string"===i&&!1===a.binary&&!1===a.base64;r&&void 0!==r.binary||(a.binary=!o),(t instanceof xi&&0===t.uncompressedSize||a.dir||!t||0===t.length)&&(a.base64=!1,a.binary=!0,t="",a.compression="STORE",i="string");var s;s=t instanceof xi||t instanceof ki?t:Pi.isNode&&Pi.isStream(t)?new Ti(e,t):wi.prepareContent(e,t,a.binary,a.optimizedBinaryString,a.base64);var l=new Ci(e,s,a);this.files[e]=l},Ni=function(e){"/"===e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return t>0?e.substring(0,t):""},Oi=function(e){return"/"!==e.slice(-1)&&(e+="/"),e},Ri=function(e,t){return t=void 0!==t?t:Si.createFolders,e=Oi(e),this.files[e]||Ai.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]};function Mi(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var Bi={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(e){var t,r,n;for(t in this.files)n=this.files[t],(r=t.slice(this.root.length,t.length))&&t.slice(0,this.root.length)===this.root&&e(r,n)},filter:function(e){var t=[];return this.forEach((function(r,n){e(r,n)&&t.push(n)})),t},file:function(e,t,r){if(1===arguments.length){if(Mi(e)){var n=e;return this.filter((function(e,t){return!t.dir&&n.test(e)}))}var i=this.files[this.root+e];return i&&!i.dir?i:null}return e=this.root+e,Ai.call(this,e,t,r),this},folder:function(e){if(!e)return this;if(Mi(e))return this.filter((function(t,r){return r.dir&&e.test(t)}));var t=this.root+e,r=Ri.call(this,t),n=this.clone();return n.root=r.name,n},remove:function(e){e=this.root+e;var t=this.files[e];if(t||("/"!==e.slice(-1)&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var r=this.filter((function(t,r){return r.name.slice(0,e.length)===e})),n=0;n<r.length;n++)delete this.files[r[n].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(e){var t,r={};try{if((r=wi.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:bi.utf8encode})).type=r.type.toLowerCase(),r.compression=r.compression.toUpperCase(),"binarystring"===r.type&&(r.type="string"),!r.type)throw new Error("No output type specified.");wi.checkSupport(r.type),"darwin"!==r.platform&&"freebsd"!==r.platform&&"linux"!==r.platform&&"sunos"!==r.platform||(r.platform="UNIX"),"win32"===r.platform&&(r.platform="DOS");var n=r.comment||this.comment||"";t=Ei.generateWorker(this,r,n)}catch(e){(t=new ki("error")).error(e)}return new _i(t,r.type||"string",r.mimeType)},generateAsync:function(e,t){return this.generateInternalStream(e).accumulate(t)},generateNodeStream:function(e,t){return(e=e||{}).type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)}},Di=Ze();function ji(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}ji.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 t,r=0;for(this.checkOffset(e),t=this.index+e-1;t>=this.index;t--)r=(r<<8)+this.byteAt(t);return this.index+=e,r},readString:function(e){return Di.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))}};var Li=ji,Ii=Li;function zi(e){Ii.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=255&e[t]}Ze().inherits(zi,Ii),zi.prototype.byteAt=function(e){return this.data[this.zero+e]},zi.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),i=e.charCodeAt(3),a=this.length-4;a>=0;--a)if(this.data[a]===t&&this.data[a+1]===r&&this.data[a+2]===n&&this.data[a+3]===i)return a-this.zero;return-1},zi.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),i=e.charCodeAt(3),a=this.readData(4);return t===a[0]&&r===a[1]&&n===a[2]&&i===a[3]},zi.prototype.readData=function(e){if(this.checkOffset(e),0===e)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};var Fi=zi,Ui=Li;function Wi(e){Ui.call(this,e)}Ze().inherits(Wi,Ui),Wi.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},Wi.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},Wi.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},Wi.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};var Hi=Wi,Zi=Fi;function qi(e){Zi.call(this,e)}Ze().inherits(qi,Zi),qi.prototype.readData=function(e){if(this.checkOffset(e),0===e)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};var Vi=qi,Xi=Vi;function Gi(e){Xi.call(this,e)}Ze().inherits(Gi,Xi),Gi.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};var Ki=Gi,Ji=Ze(),Yi=H,$i=Fi,Qi=Hi,ea=Ki,ta=Vi,ra=function(e){var t=Ji.getTypeOf(e);return Ji.checkSupport(t),"string"!==t||Yi.uint8array?"nodebuffer"===t?new ea(e):Yi.uint8array?new ta(Ji.transformTo("uint8array",e)):new $i(Ji.transformTo("array",e)):new Qi(e)},na=ra,ia=Ze(),aa=Pt,oa=pt,sa=U,la=zt,ua=H;function ca(e,t){this.options=e,this.loadOptions=t}ca.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},readLocalPart:function(e){var t,r;if(e.skip(22),this.fileNameLength=e.readInt(2),r=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(r),-1===this.compressedSize||-1===this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(null===(t=function(e){for(var t in la)if(Object.prototype.hasOwnProperty.call(la,t)&&la[t].magic===e)return la[t];return null}(this.compressionMethod)))throw new Error("Corrupted zip : compression "+ia.pretty(this.compressionMethod)+" unknown (inner file : "+ia.transformTo("string",this.fileName)+")");this.decompressed=new aa(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},readCentralPart:function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0===e&&(this.dosPermissions=63&this.externalFileAttributes),3===e&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var e=na(this.extraFields[1].value);this.uncompressedSize===ia.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===ia.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===ia.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===ia.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},readExtraFields:function(e){var t,r,n,i=e.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});e.index+4<i;)t=e.readInt(2),r=e.readInt(2),n=e.readData(r),this.extraFields[t]={id:t,length:r,value:n};e.setIndex(i)},handleUTF8:function(){var e=ua.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=sa.utf8decode(this.fileName),this.fileCommentStr=sa.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var r=ia.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(r)}var n=this.findExtraFieldUnicodeComment();if(null!==n)this.fileCommentStr=n;else{var i=ia.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(i)}}},findExtraFieldUnicodePath:function(){var e=this.extraFields[28789];if(e){var t=na(e.value);return 1!==t.readInt(1)||oa(this.fileName)!==t.readInt(4)?null:sa.utf8decode(t.readData(e.length-5))}return null},findExtraFieldUnicodeComment:function(){var e=this.extraFields[25461];if(e){var t=na(e.value);return 1!==t.readInt(1)||oa(this.fileComment)!==t.readInt(4)?null:sa.utf8decode(t.readData(e.length-5))}return null}};var ha=ca,fa=ra,da=Ze(),pa=ni,ma=ha,ga=H;function va(e){this.files=[],this.loadOptions=e}va.prototype={checkSignature:function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+da.pretty(t)+", expected "+da.pretty(e)+")")}},isSignature:function(e,t){var r=this.reader.index;this.reader.setIndex(e);var n=this.reader.readString(4)===t;return this.reader.setIndex(r),n},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 e=this.reader.readData(this.zipCommentLength),t=ga.uint8array?"uint8array":"array",r=da.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(r)},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 e,t,r,n=this.zip64EndOfCentralSize-44;0<n;)e=this.reader.readInt(2),t=this.reader.readInt(4),r=this.reader.readData(t),this.zip64ExtensibleData[e]={id:e,length:t,value:r}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(pa.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},readCentralDir:function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(pa.CENTRAL_FILE_HEADER);)(e=new ma({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var e=this.reader.lastIndexOfSignature(pa.CENTRAL_DIRECTORY_END);if(e<0)throw this.isSignature(0,pa.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(e);var t=e;if(this.checkSignature(pa.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===da.MAX_VALUE_16BITS||this.diskWithCentralDirStart===da.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===da.MAX_VALUE_16BITS||this.centralDirRecords===da.MAX_VALUE_16BITS||this.centralDirSize===da.MAX_VALUE_32BITS||this.centralDirOffset===da.MAX_VALUE_32BITS){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(pa.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(pa.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,pa.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(pa.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(pa.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var r=this.centralDirOffset+this.centralDirSize;this.zip64&&(r+=20,r+=12+this.zip64EndOfCentralSize);var n=t-r;if(n>0)this.isSignature(t,pa.CENTRAL_FILE_HEADER)||(this.reader.zero=n);else if(n<0)throw new Error("Corrupted zip: missing "+Math.abs(n)+" bytes.")},prepareReader:function(e){this.reader=fa(e)},load:function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}};var ya=va,ba=Ze(),wa=He,ka=U,_a=ya,Sa=yt,xa=We;function Ca(e){return new wa.Promise((function(t,r){var n=e.decompressed.getContentWorker().pipe(new Sa);n.on("error",(function(e){r(e)})).on("end",(function(){n.streamInfo.crc32!==e.decompressed.crc32?r(new Error("Corrupted zip : CRC32 mismatch")):t()})).resume()}))}function Ea(){if(!(this instanceof Ea))return new Ea;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 e=new Ea;for(var t in this)"function"!=typeof this[t]&&(e[t]=this[t]);return e}}Ea.prototype=Bi,Ea.prototype.loadAsync=function(e,t){var r=this;return t=ba.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:ka.utf8decode}),xa.isNode&&xa.isStream(e)?wa.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):ba.prepareContent("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then((function(e){var r=new _a(t);return r.load(e),r})).then((function(e){var r=[wa.Promise.resolve(e)],n=e.files;if(t.checkCRC32)for(var i=0;i<n.length;i++)r.push(Ca(n[i]));return wa.Promise.all(r)})).then((function(e){for(var n=e.shift(),i=n.files,a=0;a<i.length;a++){var o=i[a],s=o.fileNameStr,l=ba.resolve(o.fileNameStr);r.file(l,o.decompressed,{binary:!0,optimizedBinaryString:!0,date:o.date,dir:o.dir,comment:o.fileCommentStr.length?o.fileCommentStr:null,unixPermissions:o.unixPermissions,dosPermissions:o.dosPermissions,createFolders:t.createFolders}),o.dir||(r.file(l).unsafeOriginalName=s)}return n.zipComment.length&&(r.comment=n.zipComment),r}))},Ea.support=H,Ea.defaults=st,Ea.version="3.10.1",Ea.loadAsync=function(e,t){return(new Ea).loadAsync(e,t)},Ea.external=He;var Pa,Ta,Aa=(Ta=Ea)&&Ta.__esModule&&Object.prototype.hasOwnProperty.call(Ta,"default")?Ta.default:Ta;!function(e){e.OfficeDocument="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",e.FontTable="http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",e.Image="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",e.Numbering="http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering",e.Styles="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",e.StylesWithEffects="http://schemas.microsoft.com/office/2007/relationships/stylesWithEffects",e.Theme="http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",e.Settings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings",e.WebSettings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings",e.Hyperlink="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",e.Footnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes",e.Endnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/endnotes",e.Footer="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer",e.Header="http://schemas.openxmlformats.org/officeDocument/2006/relationships/header",e.ExtendedProperties="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",e.CoreProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",e.CustomProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/custom-properties",e.Comments="http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",e.CommentsExtended="http://schemas.microsoft.com/office/2011/relationships/commentsExtended"}(Pa||(Pa={}));var Na="http://schemas.openxmlformats.org/wordprocessingml/2006/main",Oa={Dxa:{mul:.05,unit:"pt"},Emu:{mul:1/12700,unit:"pt"},FontSize:{mul:.5,unit:"pt"},Border:{mul:.125,unit:"pt"},Point:{mul:1,unit:"pt"},Percent:{mul:.02,unit:"%"},LineHeight:{mul:1/240,unit:""},VmlEmu:{mul:1/12700,unit:""}};function Ra(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Oa.Dxa;return null==e||/.+(p[xt]|[%])$/.test(e)?e:"".concat((parseInt(e)*t.mul).toFixed(2)).concat(t.unit)}function Ma(e,t,r){if(e.namespaceURI!=Na)return!1;switch(e.localName){case"color":t.color=r.attr(e,"val");break;case"sz":t.fontSize=r.lengthAttr(e,"val",Oa.FontSize);break;default:return!1}return!0}var Ba=function(){function e(){N(this,e)}return R(e,[{key:"elements",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=[],n=0,i=e.childNodes.length;n<i;n++){var a=e.childNodes.item(n);1!=a.nodeType||null!=t&&a.localName!=t||r.push(a)}return r}},{key:"element",value:function(e,t){for(var r=0,n=e.childNodes.length;r<n;r++){var i=e.childNodes.item(r);if(1==i.nodeType&&i.localName==t)return i}return null}},{key:"elementAttr",value:function(e,t,r){var n=this.element(e,t);return n?this.attr(n,r):void 0}},{key:"attrs",value:function(e){return Array.from(e.attributes)}},{key:"attr",value:function(e,t){for(var r=0,n=e.attributes.length;r<n;r++){var i=e.attributes.item(r);if(i.localName==t)return i.value}return null}},{key:"intAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.attr(e,t);return n?parseInt(n):r}},{key:"hexAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.attr(e,t);return n?parseInt(n,16):r}},{key:"floatAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.attr(e,t);return n?parseFloat(n):r}},{key:"boolAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];switch(e){case"1":case"on":case"true":return!0;case"0":case"off":case"false":return!1;default:return t}}(this.attr(e,t),r)}},{key:"lengthAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Oa.Dxa;return Ra(this.attr(e,t),r)}}]),e}(),Da=new Ba,ja=function(){function e(t,r){N(this,e),this._package=t,this.path=r}var t;return R(e,[{key:"load",value:(t=A(P().mark((function e(){var t,r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._package.loadRelationships(this.path);case 2:return this.rels=e.sent,e.next=5,this._package.load(this.path);case 5:t=e.sent,r=this._package.parseXmlDocument(t),this._package.options.keepOrigin&&(this._xmlDocument=r),this.parseXml(r.firstElementChild);case 8:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"save",value:function(){var e;this._package.update(this.path,(e=this._xmlDocument,(new XMLSerializer).serializeToString(e)))}},{key:"parseXml",value:function(e){}}]),e}(),La={embedRegular:"regular",embedBold:"bold",embedItalic:"italic",embedBoldItalic:"boldItalic"};function Ia(e,t){return{id:t.attr(e,"id"),key:t.attr(e,"fontKey"),type:La[e.localName]}}var za=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"parseXml",value:function(e){this.fonts=function(e,t){return t.elements(e).map((function(e){return function(e,t){var r,n={name:t.attr(e,"name"),embedFontRefs:[]},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"family":n.family=t.attr(a,"val");break;case"altName":n.altName=t.attr(a,"val");break;case"embedRegular":case"embedBold":case"embedItalic":case"embedBoldItalic":n.embedFontRefs.push(Ia(a,t))}}}catch(e){i.e(e)}finally{i.f()}return n}(e,t)}))}(e,this._package.xmlParser)}}]),r}(ja);function Fa(e){var t=e.lastIndexOf("/")+1;return[0==t?"":e.substring(0,t),0==t?e:e.substring(t)]}function Ua(e,t){try{var r="http://docx/";return new URL(e,r+t).toString().substring(r.length)}catch(r){return"".concat(t).concat(e)}}function Wa(e,t){return e.reduce((function(e,r){return e[t(r)]=r,e}),{})}function Ha(e){return e&&"object"==B(e)&&!Array.isArray(e)}function Za(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(!r.length)return e;var i=r.shift();if(Ha(e)&&Ha(i))for(var a in i)if(Ha(i[a])){var o;Za(null!==(o=e[a])&&void 0!==o?o:e[a]={},i[a])}else e[a]=i[a];return Za.apply(void 0,[e].concat(r))}function qa(e){return Array.isArray(e)?e:[e]}var Va,Xa,Ga=function(){function e(t,r){N(this,e),this._zip=t,this.options=r,this.xmlParser=new Ba}var t,r;return R(e,[{key:"get",value:function(e){var t,r=function(e){return e.startsWith("/")?e.substr(1):e}(e);return null!==(t=this._zip.files[r])&&void 0!==t?t:this._zip.files[r.replace(/\//g,"\\")]}},{key:"update",value:function(e,t){this._zip.file(e,t)}},{key:"save",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"blob";return this._zip.generateAsync({type:e})}},{key:"load",value:function(e){var t,r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"string";return null!==(t=null===(r=this.get(e))||void 0===r?void 0:r.async(n))&&void 0!==t?t:Promise.resolve(null)}},{key:"loadRelationships",value:(r=A(P().mark((function e(){var t,r,n,i,a,o,s,l,u,c=arguments;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=c.length>0&&void 0!==c[0]?c[0]:null,r="_rels/.rels",null!=t&&(n=Fa(t),i=y(n,2),a=i[0],o=i[1],r="".concat(a,"_rels/").concat(o,".rels")),e.next=5,this.load(r);case 5:return s=e.sent,e.abrupt("return",s?(l=this.parseXmlDocument(s).firstElementChild,(u=this.xmlParser).elements(l).map((function(e){return{id:u.attr(e,"Id"),type:u.attr(e,"Type"),target:u.attr(e,"Target"),targetMode:u.attr(e,"TargetMode")}}))):null);case 7:case"end":return e.stop()}}),e,this)}))),function(){return r.apply(this,arguments)})},{key:"parseXmlDocument",value:function(e){return function(e){var t,r,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];n&&(e=e.replace(/<[?].*[?]>/,"")),e=65279===(r=e).charCodeAt(0)?r.substring(1):r;var i=(new DOMParser).parseFromString(e,"application/xml"),a=null===(t=i.getElementsByTagName("parsererror")[0])||void 0===t?void 0:t.textContent;if(a)throw new Error(a);return i}(e,this.options.trimXmlDeclaration)}}],[{key:"load",value:(t=A(P().mark((function t(r,n){var i;return P().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Aa.loadAsync(r);case 2:return i=t.sent,t.abrupt("return",new e(i,n));case 4:case"end":return t.stop()}}),t)}))),function(e,r){return t.apply(this,arguments)})}]),e}(),Ka=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r,[{key:"parseXml",value:function(e){this.body=this._documentParser.parseDocumentFile(e)}}]),r}(ja);function Ja(e,t){return{type:t.attr(e,"val"),color:t.attr(e,"color"),size:t.lengthAttr(e,"sz",Oa.Border),offset:t.lengthAttr(e,"space",Oa.Point),frame:t.boolAttr(e,"frame"),shadow:t.boolAttr(e,"shadow")}}function Ya(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"left":n.left=Ja(a,t);break;case"top":n.top=Ja(a,t);break;case"right":n.right=Ja(a,t);break;case"bottom":n.bottom=Ja(a,t)}}}catch(e){i.e(e)}finally{i.f()}return n}function $a(e){var t,r,n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Da,a={},o=x(i.elements(e));try{for(o.s();!(n=o.n()).done;){var s=n.value;switch(s.localName){case"pgSz":a.pageSize={width:i.lengthAttr(s,"w"),height:i.lengthAttr(s,"h"),orientation:i.attr(s,"orient")};break;case"type":a.type=i.attr(s,"val");break;case"pgMar":a.pageMargins={left:i.lengthAttr(s,"left"),right:i.lengthAttr(s,"right"),top:i.lengthAttr(s,"top"),bottom:i.lengthAttr(s,"bottom"),header:i.lengthAttr(s,"header"),footer:i.lengthAttr(s,"footer"),gutter:i.lengthAttr(s,"gutter")};break;case"cols":a.columns=Qa(s,i);break;case"headerReference":(null!==(t=a.headerRefs)&&void 0!==t?t:a.headerRefs=[]).push(to(s,i));break;case"footerReference":(null!==(r=a.footerRefs)&&void 0!==r?r:a.footerRefs=[]).push(to(s,i));break;case"titlePg":a.titlePage=i.boolAttr(s,"val",!0);break;case"pgBorders":a.pageBorders=Ya(s,i);break;case"pgNumType":a.pageNumber=eo(s,i)}}}catch(e){o.e(e)}finally{o.f()}return a}function Qa(e,t){return{numberOfColumns:t.intAttr(e,"num"),space:t.lengthAttr(e,"space"),separator:t.boolAttr(e,"sep"),equalWidth:t.boolAttr(e,"equalWidth",!0),columns:t.elements(e,"col").map((function(e){return{width:t.lengthAttr(e,"w"),space:t.lengthAttr(e,"space")}}))}}function eo(e,t){return{chapSep:t.attr(e,"chapSep"),chapStyle:t.attr(e,"chapStyle"),format:t.attr(e,"fmt"),start:t.intAttr(e,"start")}}function to(e,t){return{id:t.attr(e,"id"),type:t.attr(e,"type")}}function ro(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){no(r.value,n,t)}}catch(e){i.e(e)}finally{i.f()}return n}function no(e,t,r){return!!Ma(e,t,r)}function io(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){ao(r.value,n,t)}}catch(e){i.e(e)}finally{i.f()}return n}function ao(e,t,r){if(e.namespaceURI!=Na)return!1;if(Ma(e,t,r))return!0;switch(e.localName){case"tabs":t.tabs=function(e,t){return t.elements(e,"tab").map((function(e){return{position:t.lengthAttr(e,"pos"),leader:t.attr(e,"leader"),style:t.attr(e,"val")}}))}(e,r);break;case"sectPr":t.sectionProps=$a(e,r);break;case"numPr":t.numbering=function(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"numId":n.id=t.attr(a,"val");break;case"ilvl":n.level=t.intAttr(a,"val")}}}catch(e){i.e(e)}finally{i.f()}return n}(e,r);break;case"spacing":return t.lineSpacing=function(e,t){return{before:t.lengthAttr(e,"before"),after:t.lengthAttr(e,"after"),line:t.intAttr(e,"line"),lineRule:t.attr(e,"lineRule")}}(e,r),!1;case"textAlignment":return t.textAlignment=r.attr(e,"val"),!1;case"keepLines":t.keepLines=r.boolAttr(e,"val",!0);break;case"keepNext":t.keepNext=r.boolAttr(e,"val",!0);break;case"pageBreakBefore":t.pageBreakBefore=r.boolAttr(e,"val",!0);break;case"outlineLvl":t.outlineLevel=r.intAttr(e,"val");break;case"pStyle":t.styleName=r.attr(e,"val");break;case"rPr":t.runProps=ro(e,r);break;default:return!1}return!0}function oo(e,t){var r,n={id:t.attr(e,"numId"),overrides:[]},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"abstractNumId":n.abstractId=t.attr(a,"val");break;case"lvlOverride":n.overrides.push(uo(a,t))}}}catch(e){i.e(e)}finally{i.f()}return n}function so(e,t){var r,n={id:t.attr(e,"abstractNumId"),levels:[]},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"name":n.name=t.attr(a,"val");break;case"multiLevelType":n.multiLevelType=t.attr(a,"val");break;case"numStyleLink":n.numberingStyleLink=t.attr(a,"val");break;case"styleLink":n.styleLink=t.attr(a,"val");break;case"lvl":n.levels.push(lo(a,t))}}}catch(e){i.e(e)}finally{i.f()}return n}function lo(e,t){var r,n={level:t.intAttr(e,"ilvl")},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"start":n.start=t.attr(a,"val");break;case"lvlRestart":n.restart=t.intAttr(a,"val");break;case"numFmt":n.format=t.attr(a,"val");break;case"lvlText":n.text=t.attr(a,"val");break;case"lvlJc":n.justification=t.attr(a,"val");break;case"lvlPicBulletId":n.bulletPictureId=t.attr(a,"val");break;case"pStyle":n.paragraphStyle=t.attr(a,"val");break;case"pPr":n.paragraphProps=io(a,t);break;case"rPr":n.runProps=ro(a,t)}}}catch(e){i.e(e)}finally{i.f()}return n}function uo(e,t){var r,n={level:t.intAttr(e,"ilvl")},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"startOverride":n.start=t.intAttr(a,"val");break;case"lvl":n.numberingLevel=lo(a,t)}}}catch(e){i.e(e)}finally{i.f()}return n}function co(e,t){var r=t.element(e,"pict"),n=r&&t.element(r,"shape"),i=n&&t.element(n,"imagedata");return i?{id:t.attr(e,"numPicBulletId"),referenceId:t.attr(i,"id"),style:t.attr(n,"style")}:null}!function(e){e.Continuous="continuous",e.NextPage="nextPage",e.NextColumn="nextColumn",e.EvenPage="evenPage",e.OddPage="oddPage"}(Va||(Va={}));var ho=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r,[{key:"parseXml",value:function(e){Object.assign(this,function(e,t){var r,n={numberings:[],abstractNumberings:[],bulletPictures:[]},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"num":n.numberings.push(oo(a,t));break;case"abstractNum":n.abstractNumberings.push(so(a,t));break;case"numPicBullet":n.bulletPictures.push(co(a,t))}}}catch(e){i.e(e)}finally{i.f()}return n}(e,this._package.xmlParser)),this.domNumberings=this._documentParser.parseNumberingFile(e)}}]),r}(ja),fo=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r,[{key:"parseXml",value:function(e){this.styles=this._documentParser.parseStylesFile(e)}}]),r}(ja);!function(e){e.Document="document",e.Paragraph="paragraph",e.Run="run",e.Break="break",e.NoBreakHyphen="noBreakHyphen",e.Table="table",e.Row="row",e.Cell="cell",e.Hyperlink="hyperlink",e.SmartTag="smartTag",e.Drawing="drawing",e.Image="image",e.Text="text",e.Tab="tab",e.Symbol="symbol",e.BookmarkStart="bookmarkStart",e.BookmarkEnd="bookmarkEnd",e.Footer="footer",e.Header="header",e.FootnoteReference="footnoteReference",e.EndnoteReference="endnoteReference",e.Footnote="footnote",e.Endnote="endnote",e.SimpleField="simpleField",e.ComplexField="complexField",e.Instruction="instruction",e.VmlPicture="vmlPicture",e.MmlMath="mmlMath",e.MmlMathParagraph="mmlMathParagraph",e.MmlFraction="mmlFraction",e.MmlFunction="mmlFunction",e.MmlFunctionName="mmlFunctionName",e.MmlNumerator="mmlNumerator",e.MmlDenominator="mmlDenominator",e.MmlRadical="mmlRadical",e.MmlBase="mmlBase",e.MmlDegree="mmlDegree",e.MmlSuperscript="mmlSuperscript",e.MmlSubscript="mmlSubscript",e.MmlPreSubSuper="mmlPreSubSuper",e.MmlSubArgument="mmlSubArgument",e.MmlSuperArgument="mmlSuperArgument",e.MmlNary="mmlNary",e.MmlDelimiter="mmlDelimiter",e.MmlRun="mmlRun",e.MmlEquationArray="mmlEquationArray",e.MmlLimit="mmlLimit",e.MmlLimitLower="mmlLimitLower",e.MmlMatrix="mmlMatrix",e.MmlMatrixRow="mmlMatrixRow",e.MmlBox="mmlBox",e.MmlBar="mmlBar",e.MmlGroupChar="mmlGroupChar",e.VmlElement="vmlElement",e.Inserted="inserted",e.Deleted="deleted",e.DeletedText="deletedText",e.Comment="comment",e.CommentReference="commentReference",e.CommentRangeStart="commentRangeStart",e.CommentRangeEnd="commentRangeEnd"}(Xa||(Xa={}));var po=R((function e(){N(this,e),this.children=[],this.cssStyle={}})),mo=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.Header,e}return R(r)}(po),go=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.Footer,e}return R(r)}(po),vo=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r,[{key:"parseXml",value:function(e){this.rootElement=this.createRootElement(),this.rootElement.children=this._documentParser.parseBodyElements(e)}}]),r}(ja),yo=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"createRootElement",value:function(){return new mo}}]),r}(vo),bo=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"createRootElement",value:function(){return new go}}]),r}(vo);function wo(e){if(void 0!==e)return parseInt(e)}var ko=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"parseXml",value:function(e){this.props=function(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"Template":n.template=a.textContent;break;case"Pages":n.pages=wo(a.textContent);break;case"Words":n.words=wo(a.textContent);break;case"Characters":n.characters=wo(a.textContent);break;case"Application":n.application=a.textContent;break;case"Lines":n.lines=wo(a.textContent);break;case"Paragraphs":n.paragraphs=wo(a.textContent);break;case"Company":n.company=a.textContent;break;case"AppVersion":n.appVersion=a.textContent}}}catch(e){i.e(e)}finally{i.f()}return n}(e,this._package.xmlParser)}}]),r}(ja),_o=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"parseXml",value:function(e){this.props=function(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"title":n.title=a.textContent;break;case"description":n.description=a.textContent;break;case"subject":n.subject=a.textContent;break;case"creator":n.creator=a.textContent;break;case"keywords":n.keywords=a.textContent;break;case"language":n.language=a.textContent;break;case"lastModifiedBy":n.lastModifiedBy=a.textContent;break;case"revision":a.textContent&&(n.revision=parseInt(a.textContent))}}}catch(e){i.e(e)}finally{i.f()}return n}(e,this._package.xmlParser)}}]),r}(ja),So=R((function e(){N(this,e)}));function xo(e,t){var r,n={name:t.attr(e,"name"),colors:{}},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value,o=t.element(a,"srgbClr"),s=t.element(a,"sysClr");o?n.colors[a.localName]=t.attr(o,"val"):s&&(n.colors[a.localName]=t.attr(s,"lastClr"))}}catch(e){i.e(e)}finally{i.f()}return n}function Co(e,t){var r,n={name:t.attr(e,"name")},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"majorFont":n.majorFont=Eo(a,t);break;case"minorFont":n.minorFont=Eo(a,t)}}}catch(e){i.e(e)}finally{i.f()}return n}function Eo(e,t){return{latinTypeface:t.elementAttr(e,"latin","typeface"),eaTypeface:t.elementAttr(e,"ea","typeface"),csTypeface:t.elementAttr(e,"cs","typeface")}}var Po=function(e){b(r,e);var t=k(r);function r(e,n){return N(this,r),t.call(this,e,n)}return R(r,[{key:"parseXml",value:function(e){this.theme=function(e,t){var r,n=new So,i=t.element(e,"themeElements"),a=x(t.elements(i));try{for(a.s();!(r=a.n()).done;){var o=r.value;switch(o.localName){case"clrScheme":n.colorScheme=xo(o,t);break;case"fontScheme":n.fontScheme=Co(o,t)}}}catch(e){a.e(e)}finally{a.f()}return n}(e,this._package.xmlParser)}}]),r}(ja),To=R((function e(){N(this,e)})),Ao=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.Footnote,e}return R(r)}(To),No=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.Endnote,e}return R(r)}(To),Oo=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r)}(ja),Ro=function(e){b(r,e);var t=k(r);function r(e,n,i){return N(this,r),t.call(this,e,n,i)}return R(r,[{key:"parseXml",value:function(e){this.notes=this._documentParser.parseNotes(e,"footnote",Ao)}}]),r}(Oo),Mo=function(e){b(r,e);var t=k(r);function r(e,n,i){return N(this,r),t.call(this,e,n,i)}return R(r,[{key:"parseXml",value:function(e){this.notes=this._documentParser.parseNotes(e,"endnote",No)}}]),r}(Oo);function Bo(e,t){var r,n={defaultNoteIds:[]},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"numFmt":n.nummeringFormat=t.attr(a,"val");break;case"footnote":case"endnote":n.defaultNoteIds.push(t.attr(a,"id"))}}}catch(e){i.e(e)}finally{i.f()}return n}var Do=function(e){b(r,e);var t=k(r);function r(e,n){return N(this,r),t.call(this,e,n)}return R(r,[{key:"parseXml",value:function(e){this.settings=function(e,t){var r,n={},i=x(t.elements(e));try{for(i.s();!(r=i.n()).done;){var a=r.value;switch(a.localName){case"defaultTabStop":n.defaultTabStop=t.lengthAttr(a,"val");break;case"footnotePr":n.footnoteProps=Bo(a,t);break;case"endnotePr":n.endnoteProps=Bo(a,t);break;case"autoHyphenation":n.autoHyphenation=t.boolAttr(a,"val")}}}catch(e){i.e(e)}finally{i.f()}return n}(e,this._package.xmlParser)}}]),r}(ja),jo=function(e){b(r,e);var t=k(r);function r(){return N(this,r),t.apply(this,arguments)}return R(r,[{key:"parseXml",value:function(e){this.props=function(e,t){return t.elements(e,"property").map((function(e){var r=e.firstChild;return{formatId:t.attr(e,"fmtid"),name:t.attr(e,"name"),type:r.nodeName,value:r.textContent}}))}(e,this._package.xmlParser)}}]),r}(ja),Lo=function(e){b(r,e);var t=k(r);function r(e,n,i){var a;return N(this,r),(a=t.call(this,e,n))._documentParser=i,a}return R(r,[{key:"parseXml",value:function(e){this.comments=this._documentParser.parseComments(e),this.commentMap=Wa(this.comments,(function(e){return e.id}))}}]),r}(ja),Io=function(e){b(r,e);var t=k(r);function r(e,n){var i;return N(this,r),(i=t.call(this,e,n)).comments=[],i}return R(r,[{key:"parseXml",value:function(e){var t,r=this._package.xmlParser,n=x(r.elements(e,"commentEx"));try{for(n.s();!(t=n.n()).done;){var i=t.value;this.comments.push({paraId:r.attr(i,"paraId"),paraIdParent:r.attr(i,"paraIdParent"),done:r.boolAttr(i,"done")})}}catch(e){n.e(e)}finally{n.f()}this.commentMap=Wa(this.comments,(function(e){return e.paraId}))}}]),r}(ja),zo=[{type:Pa.OfficeDocument,target:"word/document.xml"},{type:Pa.ExtendedProperties,target:"docProps/app.xml"},{type:Pa.CoreProperties,target:"docProps/core.xml"},{type:Pa.CustomProperties,target:"docProps/custom.xml"}],Fo=function(){function e(){N(this,e),this.parts=[],this.partsMap={}}var t,r,n,i,a;return R(e,[{key:"save",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"blob";return this._package.save(e)}},{key:"loadRelationshipPart",value:(a=A(P().mark((function e(t,r){var n,i,a,o,s,l=this;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.partsMap[t]){e.next=2;break}return e.abrupt("return",this.partsMap[t]);case 2:if(this._package.get(t)){e.next=4;break}return e.abrupt("return",null);case 4:i=null,e.t0=r,e.next=e.t0===Pa.OfficeDocument?8:e.t0===Pa.FontTable?10:e.t0===Pa.Numbering?12:e.t0===Pa.Styles?14:e.t0===Pa.Theme?16:e.t0===Pa.Footnotes?18:e.t0===Pa.Endnotes?20:e.t0===Pa.Footer?22:e.t0===Pa.Header?24:e.t0===Pa.CoreProperties?26:e.t0===Pa.ExtendedProperties?28:e.t0===Pa.CustomProperties?30:e.t0===Pa.Settings?32:e.t0===Pa.Comments?34:e.t0===Pa.CommentsExtended?36:37;break;case 8:return this.documentPart=i=new Ka(this._package,t,this._parser),e.abrupt("break",37);case 10:return this.fontTablePart=i=new za(this._package,t),e.abrupt("break",37);case 12:return this.numberingPart=i=new ho(this._package,t,this._parser),e.abrupt("break",37);case 14:return this.stylesPart=i=new fo(this._package,t,this._parser),e.abrupt("break",37);case 16:return this.themePart=i=new Po(this._package,t),e.abrupt("break",37);case 18:return this.footnotesPart=i=new Ro(this._package,t,this._parser),e.abrupt("break",37);case 20:return this.endnotesPart=i=new Mo(this._package,t,this._parser),e.abrupt("break",37);case 22:return i=new bo(this._package,t,this._parser),e.abrupt("break",37);case 24:return i=new yo(this._package,t,this._parser),e.abrupt("break",37);case 26:return this.corePropsPart=i=new _o(this._package,t),e.abrupt("break",37);case 28:return this.extendedPropsPart=i=new ko(this._package,t),e.abrupt("break",37);case 30:return i=new jo(this._package,t),e.abrupt("break",37);case 32:return this.settingsPart=i=new Do(this._package,t),e.abrupt("break",37);case 34:return this.commentsPart=i=new Lo(this._package,t,this._parser),e.abrupt("break",37);case 36:this.commentsExtendedPart=i=new Io(this._package,t);case 37:if(null!=i){e.next=39;break}return e.abrupt("return",Promise.resolve(null));case 39:return this.partsMap[t]=i,this.parts.push(i),e.next=43,i.load();case 43:if(!((null===(n=i.rels)||void 0===n?void 0:n.length)>0)){e.next=47;break}return a=Fa(i.path),o=y(a,1),s=o[0],e.next=47,Promise.all(i.rels.map((function(e){return l.loadRelationshipPart(Ua(e.target,s),e.type)})));case 47:return e.abrupt("return",i);case 48:case"end":return e.stop()}}),e,this)}))),function(e,t){return a.apply(this,arguments)})},{key:"loadDocumentImage",value:(i=A(P().mark((function e(t,r){var n;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(null!=r?r:this.documentPart,t,"blob");case 2:return n=e.sent,e.abrupt("return",this.blobToURL(n));case 4:case"end":return e.stop()}}),e,this)}))),function(e,t){return i.apply(this,arguments)})},{key:"loadNumberingImage",value:(n=A(P().mark((function e(t){var r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(this.numberingPart,t,"blob");case 2:return r=e.sent,e.abrupt("return",this.blobToURL(r));case 4:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"loadFont",value:(r=A(P().mark((function e(t,r){var n;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.loadResource(this.fontTablePart,t,"uint8array");case 2:return n=e.sent,e.abrupt("return",n?this.blobToURL(new Blob([Uo(n,r)])):n);case 4:case"end":return e.stop()}}),e,this)}))),function(e,t){return r.apply(this,arguments)})},{key:"blobToURL",value:function(e){return e?this._options.useBase64URL?function(e){return new Promise((function(t,r){var n=new FileReader;n.onloadend=function(){return t(n.result)},n.onerror=function(){return r()},n.readAsDataURL(e)}))}(e):URL.createObjectURL(e):null}},{key:"findPartByRelId",value:function(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=(null!==(t=r.rels)&&void 0!==t?t:this.rels).find((function(t){return t.id==e})),i=r?Fa(r.path)[0]:"";return n?this.partsMap[Ua(n.target,i)]:null}},{key:"getPathById",value:function(e,t){var r=e.rels.find((function(e){return e.id==t})),n=y(Fa(e.path),1)[0];return r?Ua(r.target,n):null}},{key:"loadResource",value:function(e,t,r){var n=this.getPathById(e,t);return n?this._package.load(n,r):Promise.resolve(null)}}],[{key:"load",value:(t=A(P().mark((function t(r,n,i){var a;return P().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(a=new e)._options=i,a._parser=n,t.next=5,Ga.load(r,i);case 5:return a._package=t.sent,t.next=8,a._package.loadRelationships();case 8:return a.rels=t.sent,t.next=11,Promise.all(zo.map((function(e){var t,r=null!==(t=a.rels.find((function(t){return t.type===e.type})))&&void 0!==t?t:e;return a.loadRelationshipPart(r.target,r.type)})));case 11:return t.abrupt("return",a);case 12:case"end":return t.stop()}}),t)}))),function(e,r,n){return t.apply(this,arguments)})}]),e}();function Uo(e,t){for(var r=t.replace(/{|}|-/g,""),n=new Array(16),i=0;i<16;i++)n[16-i-1]=parseInt(r.substr(2*i,2),16);for(var a=0;a<32;a++)e[a]=e[a]^n[a%16];return e}function Wo(e,t){return{type:Xa.BookmarkEnd,id:t.attr(e,"id")}}var Ho=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.VmlElement,e.attrs={},e}return R(r)}(po);function Zo(e,t){var r,n=new Ho;switch(e.localName){case"rect":n.tagName="rect",Object.assign(n.attrs,{width:"100%",height:"100%"});break;case"oval":n.tagName="ellipse",Object.assign(n.attrs,{cx:"50%",cy:"50%",rx:"50%",ry:"50%"});break;case"line":n.tagName="line";break;case"shape":n.tagName="g";break;case"textbox":n.tagName="foreignObject",Object.assign(n.attrs,{width:"100%",height:"100%"});break;default:return null}var i,a=x(Da.attrs(e));try{for(a.s();!(i=a.n()).done;){var o=i.value;switch(o.localName){case"style":n.cssStyleText=o.value;break;case"fillcolor":n.attrs.fill=o.value;break;case"from":var s=y(Vo(o.value),2),l=s[0],u=s[1];Object.assign(n.attrs,{x1:l,y1:u});break;case"to":var c=y(Vo(o.value),2),h=c[0],f=c[1];Object.assign(n.attrs,{x2:h,y2:f})}}}catch(e){a.e(e)}finally{a.f()}var d,p=x(Da.elements(e));try{for(p.s();!(d=p.n()).done;){var m=d.value;switch(m.localName){case"stroke":Object.assign(n.attrs,qo(m));break;case"fill":Object.assign(n.attrs,{});break;case"imagedata":n.tagName="image",Object.assign(n.attrs,{width:"100%",height:"100%"}),n.imageHref={id:Da.attr(m,"id"),title:Da.attr(m,"title")};break;case"txbxContent":(r=n.children).push.apply(r,v(t.parseBodyElements(m)));break;default:var g=Zo(m,t);g&&n.children.push(g)}}}catch(e){p.e(e)}finally{p.f()}return n}function qo(e){var t;return{stroke:Da.attr(e,"color"),"stroke-width":null!==(t=Da.lengthAttr(e,"weight",Oa.Emu))&&void 0!==t?t:"1px"}}function Vo(e){return e.split(",")}var Xo=function(e){b(r,e);var t=k(r);function r(){var e;return N(this,r),(e=t.apply(this,arguments)).type=Xa.Comment,e}return R(r)}(po),Go=function(e){b(r,e);var t=k(r);function r(e){var n;return N(this,r),(n=t.call(this)).id=e,n.type=Xa.CommentReference,n}return R(r)}(po),Ko=function(e){b(r,e);var t=k(r);function r(e){var n;return N(this,r),(n=t.call(this)).id=e,n.type=Xa.CommentRangeStart,n}return R(r)}(po),Jo=function(e){b(r,e);var t=k(r);function r(e){var n;return N(this,r),(n=t.call(this)).id=e,n.type=Xa.CommentRangeEnd,n}return R(r)}(po),Yo="inherit",$o="transparent",Qo=[],es={oMath:Xa.MmlMath,oMathPara:Xa.MmlMathParagraph,f:Xa.MmlFraction,func:Xa.MmlFunction,fName:Xa.MmlFunctionName,num:Xa.MmlNumerator,den:Xa.MmlDenominator,rad:Xa.MmlRadical,deg:Xa.MmlDegree,e:Xa.MmlBase,sSup:Xa.MmlSuperscript,sSub:Xa.MmlSubscript,sPre:Xa.MmlPreSubSuper,sup:Xa.MmlSuperArgument,sub:Xa.MmlSubArgument,d:Xa.MmlDelimiter,nary:Xa.MmlNary,eqArr:Xa.MmlEquationArray,lim:Xa.MmlLimit,limLow:Xa.MmlLimitLower,m:Xa.MmlMatrix,mr:Xa.MmlMatrixRow,box:Xa.MmlBox,bar:Xa.MmlBar,groupChr:Xa.MmlGroupChar},ts=function(){function e(t){N(this,e),this.options=m({ignoreWidth:!1,debug:!1},t)}return R(e,[{key:"parseNotes",value:function(e,t,r){var n,i=[],a=x(Da.elements(e,t));try{for(a.s();!(n=a.n()).done;){var o=n.value,s=new r;s.id=Da.attr(o,"id"),s.noteType=Da.attr(o,"type"),s.children=this.parseBodyElements(o),i.push(s)}}catch(e){a.e(e)}finally{a.f()}return i}},{key:"parseComments",value:function(e){var t,r=[],n=x(Da.elements(e,"comment"));try{for(n.s();!(t=n.n()).done;){var i=t.value,a=new Xo;a.id=Da.attr(i,"id"),a.author=Da.attr(i,"author"),a.initials=Da.attr(i,"initials"),a.date=Da.attr(i,"date"),a.children=this.parseBodyElements(i),r.push(a)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"parseDocumentFile",value:function(e){var t=Da.element(e,"body"),r=Da.element(e,"background"),n=Da.element(t,"sectPr");return{type:Xa.Document,children:this.parseBodyElements(t),props:n?$a(n,Da):{},cssStyle:r?this.parseBackground(r):{}}}},{key:"parseBackground",value:function(e){var t={},r=ns.colorAttr(e,"color");return r&&(t["background-color"]=r),t}},{key:"parseBodyElements",value:function(e){var t,r=this,n=[],i=x(Da.elements(e));try{for(i.s();!(t=i.n()).done;){var a=t.value;switch(a.localName){case"p":n.push(this.parseParagraph(a));break;case"tbl":n.push(this.parseTable(a));break;case"sdt":n.push.apply(n,v(this.parseSdt(a,(function(e){return r.parseBodyElements(e)}))))}}}catch(e){i.e(e)}finally{i.f()}return n}},{key:"parseStylesFile",value:function(e){var t=this,r=[];return ns.foreach(e,(function(e){switch(e.localName){case"style":r.push(t.parseStyle(e));break;case"docDefaults":r.push(t.parseDefaultStyles(e))}})),r}},{key:"parseDefaultStyles",value:function(e){var t=this,r={id:null,name:null,target:null,basedOn:null,styles:[]};return ns.foreach(e,(function(e){switch(e.localName){case"rPrDefault":var n=Da.element(e,"rPr");n&&r.styles.push({target:"span",values:t.parseDefaultProperties(n,{})});break;case"pPrDefault":var i=Da.element(e,"pPr");i&&r.styles.push({target:"p",values:t.parseDefaultProperties(i,{})})}})),r}},{key:"parseStyle",value:function(e){var t=this,r={id:Da.attr(e,"styleId"),isDefault:Da.boolAttr(e,"default"),name:null,target:null,basedOn:null,styles:[],linked:null};switch(Da.attr(e,"type")){case"paragraph":r.target="p";break;case"table":r.target="table";break;case"character":r.target="span"}return ns.foreach(e,(function(e){switch(e.localName){case"basedOn":r.basedOn=Da.attr(e,"val");break;case"name":r.name=Da.attr(e,"val");break;case"link":r.linked=Da.attr(e,"val");break;case"next":r.next=Da.attr(e,"val");break;case"aliases":r.aliases=Da.attr(e,"val").split(",");break;case"pPr":r.styles.push({target:"p",values:t.parseDefaultProperties(e,{})}),r.paragraphProps=io(e,Da);break;case"rPr":r.styles.push({target:"span",values:t.parseDefaultProperties(e,{})}),r.runProps=ro(e,Da);break;case"tblPr":case"tcPr":r.styles.push({target:"td",values:t.parseDefaultProperties(e,{})});break;case"tblStylePr":var n,i=x(t.parseTableStyle(e));try{for(i.s();!(n=i.n()).done;){var a=n.value;r.styles.push(a)}}catch(e){i.e(e)}finally{i.f()}break;case"rsid":case"qFormat":case"hidden":case"semiHidden":case"unhideWhenUsed":case"autoRedefine":case"uiPriority":break;default:t.options.debug&&console.warn("DOCX: Unknown style element: ".concat(e.localName))}})),r}},{key:"parseTableStyle",value:function(e){var t=this,r=[],n=Da.attr(e,"type"),i="",a="";switch(n){case"firstRow":a=".first-row",i="tr.first-row td";break;case"lastRow":a=".last-row",i="tr.last-row td";break;case"firstCol":a=".first-col",i="td.first-col";break;case"lastCol":a=".last-col",i="td.last-col";break;case"band1Vert":a=":not(.no-vband)",i="td.odd-col";break;case"band2Vert":a=":not(.no-vband)",i="td.even-col";break;case"band1Horz":a=":not(.no-hband)",i="tr.odd-row";break;case"band2Horz":a=":not(.no-hband)",i="tr.even-row";break;default:return[]}return ns.foreach(e,(function(e){switch(e.localName){case"pPr":r.push({target:"".concat(i," p"),mod:a,values:t.parseDefaultProperties(e,{})});break;case"rPr":r.push({target:"".concat(i," span"),mod:a,values:t.parseDefaultProperties(e,{})});break;case"tblPr":case"tcPr":r.push({target:i,mod:a,values:t.parseDefaultProperties(e,{})})}})),r}},{key:"parseNumberingFile",value:function(e){var t=this,r=[],n={},i=[];return ns.foreach(e,(function(e){switch(e.localName){case"abstractNum":t.parseAbstractNumbering(e,i).forEach((function(e){return r.push(e)}));break;case"numPicBullet":i.push(t.parseNumberingPicBullet(e));break;case"num":var a=Da.attr(e,"numId"),o=Da.elementAttr(e,"abstractNumId","val");n[o]=a}})),r.forEach((function(e){return e.id=n[e.id]})),r}},{key:"parseNumberingPicBullet",value:function(e){var t=Da.element(e,"pict"),r=t&&Da.element(t,"shape"),n=r&&Da.element(r,"imagedata");return n?{id:Da.intAttr(e,"numPicBulletId"),src:Da.attr(n,"id"),style:Da.attr(r,"style")}:null}},{key:"parseAbstractNumbering",value:function(e,t){var r=this,n=[],i=Da.attr(e,"abstractNumId");return ns.foreach(e,(function(e){"lvl"===e.localName&&n.push(r.parseNumberingLevel(i,e,t))})),n}},{key:"parseNumberingLevel",value:function(e,t,r){var n=this,i={id:e,level:Da.intAttr(t,"ilvl"),start:1,pStyleName:void 0,pStyle:{},rStyle:{},suff:"tab"};return ns.foreach(t,(function(e){switch(e.localName){case"start":i.start=Da.intAttr(e,"val");break;case"pPr":n.parseDefaultProperties(e,i.pStyle);break;case"rPr":n.parseDefaultProperties(e,i.rStyle);break;case"lvlPicBulletId":var t=Da.intAttr(e,"val");i.bullet=r.find((function(e){return(null==e?void 0:e.id)==t}));break;case"lvlText":i.levelText=Da.attr(e,"val");break;case"pStyle":i.pStyleName=Da.attr(e,"val");break;case"numFmt":i.format=Da.attr(e,"val");break;case"suff":i.suff=Da.attr(e,"val")}})),i}},{key:"parseSdt",value:function(e,t){var r=Da.element(e,"sdtContent");return r?t(r):[]}},{key:"parseInserted",value:function(e,t){var r,n;return{type:Xa.Inserted,children:null!==(r=null===(n=t(e))||void 0===n?void 0:n.children)&&void 0!==r?r:[]}}},{key:"parseDeleted",value:function(e,t){var r,n;return{type:Xa.Deleted,children:null!==(r=null===(n=t(e))||void 0===n?void 0:n.children)&&void 0!==r?r:[]}}},{key:"parseParagraph",value:function(e){var t,r,n,i,a=this,o={type:Xa.Paragraph,children:[]},s=x(Da.elements(e));try{for(s.s();!(i=s.n()).done;){var l=i.value;switch(l.localName){case"pPr":this.parseParagraphProperties(l,o);break;case"r":o.children.push(this.parseRun(l,o));break;case"hyperlink":o.children.push(this.parseHyperlink(l,o));break;case"smartTag":o.children.push(this.parseSmartTag(l,o));break;case"bookmarkStart":o.children.push((r=l,n=Da,{type:Xa.BookmarkStart,id:n.attr(r,"id"),name:n.attr(r,"name"),colFirst:n.intAttr(r,"colFirst"),colLast:n.intAttr(r,"colLast")}));break;case"bookmarkEnd":o.children.push(Wo(l,Da));break;case"commentRangeStart":o.children.push(new Ko(Da.attr(l,"id")));break;case"commentRangeEnd":o.children.push(new Jo(Da.attr(l,"id")));break;case"oMath":case"oMathPara":o.children.push(this.parseMathElement(l));break;case"sdt":(t=o.children).push.apply(t,v(this.parseSdt(l,(function(e){return a.parseParagraph(e).children}))));break;case"ins":o.children.push(this.parseInserted(l,(function(e){return a.parseParagraph(e)})));break;case"del":o.children.push(this.parseDeleted(l,(function(e){return a.parseParagraph(e)})))}}}catch(e){s.e(e)}finally{s.f()}return o}},{key:"parseParagraphProperties",value:function(e,t){var r=this;this.parseDefaultProperties(e,t.cssStyle={},null,(function(e){if(ao(e,t,Da))return!0;switch(e.localName){case"pStyle":t.styleName=Da.attr(e,"val");break;case"cnfStyle":t.className=is.classNameOfCnfStyle(e);break;case"framePr":r.parseFrame(e,t);break;case"rPr":break;default:return!1}return!0}))}},{key:"parseFrame",value:function(e,t){"drop"==Da.attr(e,"dropCap")&&(t.cssStyle.float="left")}},{key:"parseHyperlink",value:function(e,t){var r=this,n={type:Xa.Hyperlink,parent:t,children:[]},i=Da.attr(e,"anchor"),a=Da.attr(e,"id");return i&&(n.href="#"+i),a&&(n.id=a),ns.foreach(e,(function(e){"r"===e.localName&&n.children.push(r.parseRun(e,n))})),n}},{key:"parseSmartTag",value:function(e,t){var r=this,n={type:Xa.SmartTag,parent:t,children:[]},i=Da.attr(e,"uri"),a=Da.attr(e,"element");return i&&(n.uri=i),a&&(n.element=a),ns.foreach(e,(function(e){"r"===e.localName&&n.children.push(r.parseRun(e,n))})),n}},{key:"parseRun",value:function(e,t){var r=this,n={type:Xa.Run,parent:t,children:[]};return ns.foreach(e,(function(e){switch((e=r.checkAlternateContent(e)).localName){case"t":n.children.push({type:Xa.Text,text:e.textContent});break;case"delText":n.children.push({type:Xa.DeletedText,text:e.textContent});break;case"commentReference":n.children.push(new Go(Da.attr(e,"id")));break;case"fldSimple":n.children.push({type:Xa.SimpleField,instruction:Da.attr(e,"instr"),lock:Da.boolAttr(e,"lock",!1),dirty:Da.boolAttr(e,"dirty",!1)});break;case"instrText":n.fieldRun=!0,n.children.push({type:Xa.Instruction,text:e.textContent});break;case"fldChar":n.fieldRun=!0,n.children.push({type:Xa.ComplexField,charType:Da.attr(e,"fldCharType"),lock:Da.boolAttr(e,"lock",!1),dirty:Da.boolAttr(e,"dirty",!1)});break;case"noBreakHyphen":n.children.push({type:Xa.NoBreakHyphen});break;case"br":n.children.push({type:Xa.Break,break:Da.attr(e,"type")||"textWrapping"});break;case"lastRenderedPageBreak":n.children.push({type:Xa.Break,break:"lastRenderedPageBreak"});break;case"sym":n.children.push({type:Xa.Symbol,font:Da.attr(e,"font"),char:Da.attr(e,"char")});break;case"tab":n.children.push({type:Xa.Tab});break;case"footnoteReference":n.children.push({type:Xa.FootnoteReference,id:Da.attr(e,"id")});break;case"endnoteReference":n.children.push({type:Xa.EndnoteReference,id:Da.attr(e,"id")});break;case"drawing":var t=r.parseDrawing(e);t&&(n.children=[t]);break;case"pict":n.children.push(r.parseVmlPicture(e));break;case"rPr":r.parseRunProperties(e,n)}})),n}},{key:"parseMathElement",value:function(e){var t,r="".concat(e.localName,"Pr"),n={type:es[e.localName],children:[]},i=x(Da.elements(e));try{for(i.s();!(t=i.n()).done;){var a=t.value;if(es[a.localName])n.children.push(this.parseMathElement(a));else if("r"==a.localName){var o=this.parseRun(a);o.type=Xa.MmlRun,n.children.push(o)}else a.localName==r&&(n.props=this.parseMathProperies(a))}}catch(e){i.e(e)}finally{i.f()}return n}},{key:"parseMathProperies",value:function(e){var t,r={},n=x(Da.elements(e));try{for(n.s();!(t=n.n()).done;){var i=t.value;switch(i.localName){case"chr":r.char=Da.attr(i,"val");break;case"vertJc":r.verticalJustification=Da.attr(i,"val");break;case"pos":r.position=Da.attr(i,"val");break;case"degHide":r.hideDegree=Da.boolAttr(i,"val");break;case"begChr":r.beginChar=Da.attr(i,"val");break;case"endChr":r.endChar=Da.attr(i,"val")}}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"parseRunProperties",value:function(e,t){this.parseDefaultProperties(e,t.cssStyle={},null,(function(e){switch(e.localName){case"rStyle":t.styleName=Da.attr(e,"val");break;case"vertAlign":t.verticalAlign=is.valueOfVertAlign(e,!0);break;default:return!1}return!0}))}},{key:"parseVmlPicture",value:function(e){var t,r={type:Xa.VmlPicture,children:[]},n=x(Da.elements(e));try{for(n.s();!(t=n.n()).done;){var i=Zo(t.value,this);i&&r.children.push(i)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"checkAlternateContent",value:function(e){var t;if("AlternateContent"!=e.localName)return e;var r=Da.element(e,"Choice");if(r){var n=Da.attr(r,"Requires"),i=e.lookupNamespaceURI(n);if(Qo.includes(i))return r.firstElementChild}return null===(t=Da.element(e,"Fallback"))||void 0===t?void 0:t.firstElementChild}},{key:"parseDrawing",value:function(e){var t,r=x(Da.elements(e));try{for(r.s();!(t=r.n()).done;){var n=t.value;switch(n.localName){case"inline":case"anchor":return this.parseDrawingWrapper(n)}}}catch(e){r.e(e)}finally{r.f()}}},{key:"parseDrawingWrapper",value:function(e){var t={type:Xa.Drawing,children:[],cssStyle:{}},r="anchor"==e.localName,n=null,i=Da.boolAttr(e,"simplePos");Da.boolAttr(e,"behindDoc");var a,o={relative:"page",align:"left",offset:"0"},s={relative:"page",align:"top",offset:"0"},l=x(Da.elements(e));try{for(l.s();!(a=l.n()).done;){var u=a.value;switch(u.localName){case"simplePos":i&&(o.offset=Da.lengthAttr(u,"x",Oa.Emu),s.offset=Da.lengthAttr(u,"y",Oa.Emu));break;case"extent":t.cssStyle.width=Da.lengthAttr(u,"cx",Oa.Emu),t.cssStyle.height=Da.lengthAttr(u,"cy",Oa.Emu);break;case"positionH":case"positionV":if(!i){var c,h="positionH"==u.localName?o:s,f=Da.element(u,"align"),d=Da.element(u,"posOffset");h.relative=null!==(c=Da.attr(u,"relativeFrom"))&&void 0!==c?c:h.relative,f&&(h.align=f.textContent),d&&(h.offset=ns.sizeValue(d,Oa.Emu))}break;case"wrapTopAndBottom":n="wrapTopAndBottom";break;case"wrapNone":n="wrapNone";break;case"graphic":var p=this.parseGraphic(u);p&&t.children.push(p)}}}catch(e){l.e(e)}finally{l.f()}return"wrapTopAndBottom"==n?(t.cssStyle.display="block",o.align&&(t.cssStyle["text-align"]=o.align,t.cssStyle.width="100%")):"wrapNone"==n?(t.cssStyle.display="block",t.cssStyle.position="relative",t.cssStyle.width="0px",t.cssStyle.height="0px",o.offset&&(t.cssStyle.left=o.offset),s.offset&&(t.cssStyle.top=s.offset)):!r||"left"!=o.align&&"right"!=o.align||(t.cssStyle.float=o.align),t}},{key:"parseGraphic",value:function(e){var t,r=Da.element(e,"graphicData"),n=x(Da.elements(r));try{for(n.s();!(t=n.n()).done;){var i=t.value;if("pic"===i.localName)return this.parsePicture(i)}}catch(e){n.e(e)}finally{n.f()}return null}},{key:"parsePicture",value:function(e){var t={type:Xa.Image,src:"",cssStyle:{}},r=Da.element(e,"blipFill"),n=Da.element(r,"blip");t.src=Da.attr(n,"embed");var i,a=Da.element(e,"spPr"),o=Da.element(a,"xfrm"),s=x((t.cssStyle.position="relative",Da.elements(o)));try{for(s.s();!(i=s.n()).done;){var l=i.value;switch(l.localName){case"ext":t.cssStyle.width=Da.lengthAttr(l,"cx",Oa.Emu),t.cssStyle.height=Da.lengthAttr(l,"cy",Oa.Emu);break;case"off":t.cssStyle.left=Da.lengthAttr(l,"x",Oa.Emu),t.cssStyle.top=Da.lengthAttr(l,"y",Oa.Emu)}}}catch(e){s.e(e)}finally{s.f()}return t}},{key:"parseTable",value:function(e){var t=this,r={type:Xa.Table,children:[]};return ns.foreach(e,(function(e){switch(e.localName){case"tr":r.children.push(t.parseTableRow(e));break;case"tblGrid":r.columns=t.parseTableColumns(e);break;case"tblPr":t.parseTableProperties(e,r)}})),r}},{key:"parseTableColumns",value:function(e){var t=[];return ns.foreach(e,(function(e){"gridCol"===e.localName&&t.push({width:Da.lengthAttr(e,"w")})})),t}},{key:"parseTableProperties",value:function(e,t){var r=this;switch(t.cssStyle={},t.cellStyle={},this.parseDefaultProperties(e,t.cssStyle,t.cellStyle,(function(e){switch(e.localName){case"tblStyle":t.styleName=Da.attr(e,"val");break;case"tblLook":t.className=is.classNameOftblLook(e);break;case"tblpPr":r.parseTablePosition(e,t);break;case"tblStyleColBandSize":t.colBandSize=Da.intAttr(e,"val");break;case"tblStyleRowBandSize":t.rowBandSize=Da.intAttr(e,"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"}}},{key:"parseTablePosition",value:function(e,t){var r=Da.lengthAttr(e,"topFromText"),n=Da.lengthAttr(e,"bottomFromText"),i=Da.lengthAttr(e,"rightFromText"),a=Da.lengthAttr(e,"leftFromText");t.cssStyle.float="left",t.cssStyle["margin-bottom"]=is.addSize(t.cssStyle["margin-bottom"],n),t.cssStyle["margin-left"]=is.addSize(t.cssStyle["margin-left"],a),t.cssStyle["margin-right"]=is.addSize(t.cssStyle["margin-right"],i),t.cssStyle["margin-top"]=is.addSize(t.cssStyle["margin-top"],r)}},{key:"parseTableRow",value:function(e){var t=this,r={type:Xa.Row,children:[]};return ns.foreach(e,(function(e){switch(e.localName){case"tc":r.children.push(t.parseTableCell(e));break;case"trPr":t.parseTableRowProperties(e,r)}})),r}},{key:"parseTableRowProperties",value:function(e,t){t.cssStyle=this.parseDefaultProperties(e,{},null,(function(e){switch(e.localName){case"cnfStyle":t.className=is.classNameOfCnfStyle(e);break;case"tblHeader":t.isHeader=Da.boolAttr(e,"val");break;default:return!1}return!0}))}},{key:"parseTableCell",value:function(e){var t=this,r={type:Xa.Cell,children:[]};return ns.foreach(e,(function(e){switch(e.localName){case"tbl":r.children.push(t.parseTable(e));break;case"p":r.children.push(t.parseParagraph(e));break;case"tcPr":t.parseTableCellProperties(e,r)}})),r}},{key:"parseTableCellProperties",value:function(e,t){t.cssStyle=this.parseDefaultProperties(e,{},null,(function(e){var r;switch(e.localName){case"gridSpan":t.span=Da.intAttr(e,"val",null);break;case"vMerge":t.verticalMerge=null!==(r=Da.attr(e,"val"))&&void 0!==r?r:"continue";break;case"cnfStyle":t.className=is.classNameOfCnfStyle(e);break;default:return!1}return!0}))}},{key:"parseDefaultProperties",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return r=r||{},ns.foreach(e,(function(a){if(null==i||!i(a))switch(a.localName){case"jc":r["text-align"]=is.valueOfJc(a);break;case"textAlignment":r["vertical-align"]=is.valueOfTextAlignment(a);break;case"color":r.color=ns.colorAttr(a,"val",null,"black");break;case"sz":r["font-size"]=r["min-height"]=Da.lengthAttr(a,"val",Oa.FontSize);break;case"shd":r["background-color"]=ns.colorAttr(a,"fill",null,Yo);break;case"highlight":r["background-color"]=ns.colorAttr(a,"val",null,$o);break;case"vertAlign":break;case"position":r.verticalAlign=Da.lengthAttr(a,"val",Oa.FontSize);break;case"tcW":if(t.options.ignoreWidth)break;case"tblW":r.width=is.valueOfSize(a,"w");break;case"trHeight":t.parseTrHeight(a,r);break;case"strike":r["text-decoration"]=Da.boolAttr(a,"val",!0)?"line-through":"none";break;case"b":r["font-weight"]=Da.boolAttr(a,"val",!0)?"bold":"normal";break;case"i":r["font-style"]=Da.boolAttr(a,"val",!0)?"italic":"normal";break;case"caps":r["text-transform"]=Da.boolAttr(a,"val",!0)?"uppercase":"none";break;case"smallCaps":r["font-variant"]=Da.boolAttr(a,"val",!0)?"small-caps":"none";break;case"u":t.parseUnderline(a,r);break;case"ind":case"tblInd":t.parseIndentation(a,r);break;case"rFonts":t.parseFont(a,r);break;case"tblBorders":t.parseBorderProperties(a,n||r);break;case"tblCellSpacing":r["border-spacing"]=is.valueOfMargin(a),r["border-collapse"]="separate";break;case"pBdr":t.parseBorderProperties(a,r);break;case"bdr":r.border=is.valueOfBorder(a);break;case"tcBorders":t.parseBorderProperties(a,r);break;case"vanish":Da.boolAttr(a,"val",!0)&&(r.display="none");break;case"kern":case"noWrap":break;case"tblCellMar":case"tcMar":t.parseMarginProperties(a,n||r);break;case"tblLayout":r["table-layout"]=is.valueOfTblLayout(a);break;case"vAlign":r["vertical-align"]=is.valueOfTextAlignment(a);break;case"spacing":"pPr"==e.localName&&t.parseSpacing(a,r);break;case"wordWrap":Da.boolAttr(a,"val")&&(r["overflow-wrap"]="break-word");break;case"suppressAutoHyphens":r.hyphens=Da.boolAttr(a,"val",!0)?"none":"auto";break;case"lang":r.$lang=Da.attr(a,"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:t.options.debug&&console.warn("DOCX: Unknown document element: ".concat(e.localName,".").concat(a.localName))}})),r}},{key:"parseUnderline",value:function(e,t){var r=Da.attr(e,"val");if(null!=r){switch(r){case"dash":case"dashDotDotHeavy":case"dashDotHeavy":case"dashedHeavy":case"dashLong":case"dashLongHeavy":case"dotDash":case"dotDotDash":t["text-decoration"]="underline dashed";break;case"dotted":case"dottedHeavy":t["text-decoration"]="underline dotted";break;case"double":t["text-decoration"]="underline double";break;case"single":case"thick":case"words":t["text-decoration"]="underline";break;case"wave":case"wavyDouble":case"wavyHeavy":t["text-decoration"]="underline wavy";break;case"none":t["text-decoration"]="none"}var n=ns.colorAttr(e,"color");n&&(t["text-decoration-color"]=n)}}},{key:"parseFont",value:function(e,t){var r=[Da.attr(e,"ascii"),is.themeValue(e,"asciiTheme")].filter((function(e){return e})).join(", ");r.length>0&&(t["font-family"]=r)}},{key:"parseIndentation",value:function(e,t){var r=Da.lengthAttr(e,"firstLine"),n=Da.lengthAttr(e,"hanging"),i=Da.lengthAttr(e,"left"),a=Da.lengthAttr(e,"start"),o=Da.lengthAttr(e,"right"),s=Da.lengthAttr(e,"end");r&&(t["text-indent"]=r),n&&(t["text-indent"]="-".concat(n)),(i||a)&&(t["margin-left"]=i||a),(o||s)&&(t["margin-right"]=o||s)}},{key:"parseSpacing",value:function(e,t){var r=Da.lengthAttr(e,"before"),n=Da.lengthAttr(e,"after"),i=Da.intAttr(e,"line",null),a=Da.attr(e,"lineRule");if(r&&(t["margin-top"]=r),n&&(t["margin-bottom"]=n),null!==i)switch(a){case"auto":t["line-height"]="".concat((i/240).toFixed(2));break;case"atLeast":t["line-height"]="calc(100% + ".concat(i/20,"pt)");break;default:t["line-height"]=t["min-height"]=i/20+"pt"}}},{key:"parseMarginProperties",value:function(e,t){ns.foreach(e,(function(e){switch(e.localName){case"left":t["padding-left"]=is.valueOfMargin(e);break;case"right":t["padding-right"]=is.valueOfMargin(e);break;case"top":t["padding-top"]=is.valueOfMargin(e);break;case"bottom":t["padding-bottom"]=is.valueOfMargin(e)}}))}},{key:"parseTrHeight",value:function(e,t){Da.attr(e,"hRule"),t.height=Da.lengthAttr(e,"val")}},{key:"parseBorderProperties",value:function(e,t){ns.foreach(e,(function(e){switch(e.localName){case"start":case"left":t["border-left"]=is.valueOfBorder(e);break;case"end":case"right":t["border-right"]=is.valueOfBorder(e);break;case"top":t["border-top"]=is.valueOfBorder(e);break;case"bottom":t["border-bottom"]=is.valueOfBorder(e)}}))}}]),e}(),rs=["black","blue","cyan","darkBlue","darkCyan","darkGray","darkGreen","darkMagenta","darkRed","darkYellow","green","lightGray","magenta","none","red","white","yellow"],ns=function(){function e(){N(this,e)}return R(e,null,[{key:"foreach",value:function(e,t){for(var r=0;r<e.childNodes.length;r++){var n=e.childNodes[r];n.nodeType==Node.ELEMENT_NODE&&t(n)}}},{key:"colorAttr",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"black",i=Da.attr(e,t);if(i)return"auto"==i?n:rs.includes(i)?i:"#".concat(i);var a=Da.attr(e,"themeColor");return a?"var(--docx-".concat(a,"-color)"):r}},{key:"sizeValue",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Oa.Dxa;return Ra(e.textContent,t)}}]),e}(),is=function(){function e(){N(this,e)}return R(e,null,[{key:"themeValue",value:function(e,t){var r=Da.attr(e,t);return r?"var(--docx-".concat(r,"-font)"):null}},{key:"valueOfSize",value:function(e,t){var r=Oa.Dxa;switch(Da.attr(e,"type")){case"dxa":break;case"pct":r=Oa.Percent;break;case"auto":return"auto"}return Da.lengthAttr(e,t,r)}},{key:"valueOfMargin",value:function(e){return Da.lengthAttr(e,"w")}},{key:"valueOfBorder",value:function(e){if("nil"==Da.attr(e,"val"))return"none";var t=ns.colorAttr(e,"color");return"".concat(Da.lengthAttr(e,"sz",Oa.Border)," solid ").concat("auto"==t?"black":t)}},{key:"valueOfTblLayout",value:function(e){return"fixed"==Da.attr(e,"val")?"fixed":"auto"}},{key:"classNameOfCnfStyle",value:function(e){var t=Da.attr(e,"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((function(e,r){return"1"==t[r]})).join(" ")}},{key:"valueOfJc",value:function(e){var t=Da.attr(e,"val");switch(t){case"start":case"left":return"left";case"center":return"center";case"end":case"right":return"right";case"both":return"justify"}return t}},{key:"valueOfVertAlign",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=Da.attr(e,"val");switch(r){case"subscript":return"sub";case"superscript":return t?"sup":"super"}return t?null:r}},{key:"valueOfTextAlignment",value:function(e){var t=Da.attr(e,"val");switch(t){case"auto":case"baseline":return"baseline";case"top":return"top";case"center":return"middle";case"bottom":return"bottom"}return t}},{key:"addSize",value:function(e,t){return null==e?t:null==t?e:"calc(".concat(e," + ").concat(t,")")}},{key:"classNameOftblLook",value:function(e){var t=Da.hexAttr(e,"val",0),r="";return(Da.boolAttr(e,"firstRow")||32&t)&&(r+=" first-row"),(Da.boolAttr(e,"lastRow")||64&t)&&(r+=" last-row"),(Da.boolAttr(e,"firstColumn")||128&t)&&(r+=" first-col"),(Da.boolAttr(e,"lastColumn")||256&t)&&(r+=" last-col"),(Da.boolAttr(e,"noHBand")||512&t)&&(r+=" no-hband"),(Da.boolAttr(e,"noVBand")||1024&t)&&(r+=" no-vband"),r.trim()}}]),e}(),as={pos:0,leader:"none",style:"left"};function os(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.75,i=e.closest("p"),a=e.getBoundingClientRect(),o=i.getBoundingClientRect(),s=getComputedStyle(i),l=(null==t?void 0:t.length)>0?t.map((function(e){return{pos:ss(e.position),leader:e.leader,style:e.style}})).sort((function(e,t){return e.pos-t.pos})):[as],u=l[l.length-1],c=o.width*n,h=ss(r),f=u.pos+h;if(f<c)for(;f<c&&l.length<50;f+=h)l.push(m(m({},as),{},{pos:f}));var d=parseFloat(s.marginLeft),p=o.left+d,g=(a.left-p)*n,v=l.find((function(e){return"clear"!=e.style&&e.pos>g}));if(null!=v){var y=1;if("right"==v.style||"center"==v.style){var b=Array.from(i.querySelectorAll(".".concat(e.className))),w=b.indexOf(e)+1,k=document.createRange();k.setStart(e,1),w<b.length?k.setEndBefore(b[w]):k.setEndAfter(i);var _="center"==v.style?.5:1,S=k.getBoundingClientRect(),x=S.left+_*S.width-(o.left-d);y=v.pos-x*n}else y=v.pos-g;switch(e.innerHTML="&nbsp;",e.style.textDecoration="inherit",e.style.wordSpacing="".concat(y.toFixed(0),"pt"),v.leader){case"dot":case"middleDot":e.style.textDecoration="underline",e.style.textDecorationStyle="dotted";break;case"hyphen":case"heavy":case"underscore":e.style.textDecoration="underline"}}}function ss(e){return parseFloat(e)}var ls="http://www.w3.org/1998/Math/MathML",us=function(){function e(t){N(this,e),this.htmlDocument=t,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.commentMap={},this.tasks=[],this.postRenderTasks=[],this.createElement=cs}return R(e,[{key:"render",value:function(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3?arguments[3]:void 0;this.document=e,this.options=i,this.className=i.className,this.rootSelector=i.inWrapper?".".concat(this.className,"-wrapper"):":root",this.styleMap=null,this.tasks=[],this.options.renderComments&&globalThis.Highlight&&(this.commentHighlight=new Highlight),ds(n=n||t),ds(t),gs(n,"docxjs library predefined styles"),n.appendChild(this.renderDefaultStyle()),e.themePart&&(gs(n,"docxjs document theme values"),this.renderTheme(e.themePart,n)),null!=e.stylesPart&&(this.styleMap=this.processStyles(e.stylesPart.styles),gs(n,"docxjs document styles"),n.appendChild(this.renderStyles(e.stylesPart.styles))),e.numberingPart&&(this.prodessNumberings(e.numberingPart.domNumberings),gs(n,"docxjs document numbering styles"),n.appendChild(this.renderNumbering(e.numberingPart.domNumberings,n))),e.footnotesPart&&(this.footnoteMap=Wa(e.footnotesPart.notes,(function(e){return e.id}))),e.endnotesPart&&(this.endnoteMap=Wa(e.endnotesPart.notes,(function(e){return e.id}))),e.settingsPart&&(this.defaultTabSize=null===(r=e.settingsPart.settings)||void 0===r?void 0:r.defaultTabStop),!i.ignoreFonts&&e.fontTablePart&&this.renderFontTable(e.fontTablePart,n);var a=this.renderSections(e.documentPart.body);this.options.inWrapper?t.appendChild(this.renderWrapper(a)):ps(t,a),this.commentHighlight&&i.renderComments&&CSS.highlights.set("".concat(this.className,"-comments"),this.commentHighlight),this.refreshTabStops(),this.postRenderTasks.forEach((function(e){return e()}))}},{key:"renderTheme",value:function(e,t){var r,n,i={},a=null===(r=e.theme)||void 0===r?void 0:r.fontScheme;a&&(a.majorFont&&(i["--docx-majorHAnsi-font"]=a.majorFont.latinTypeface),a.minorFont&&(i["--docx-minorHAnsi-font"]=a.minorFont.latinTypeface));var o=null===(n=e.theme)||void 0===n?void 0:n.colorScheme;if(o)for(var s=0,l=Object.entries(o.colors);s<l.length;s++){var u=y(l[s],2),c=u[0],h=u[1];i["--docx-".concat(c,"-color")]="#".concat(h)}var f=this.styleToString(".".concat(this.className),i);t.appendChild(ms(f))}},{key:"renderFontTable",value:function(e,t){var r,n=this,i=x(e.fonts);try{var a=function(){var e,i=r.value,a=x(i.embedFontRefs);try{var o=function(){var r=e.value;n.tasks.push(n.document.loadFont(r.id,r.key).then((function(e){var a={"font-family":i.name,src:"url(".concat(e,")")};"bold"!=r.type&&"boldItalic"!=r.type||(a["font-weight"]="bold"),"italic"!=r.type&&"boldItalic"!=r.type||(a["font-style"]="italic"),gs(t,"docxjs ".concat(i.name," font"));var o=n.styleToString("@font-face",a);t.appendChild(ms(o)),n.refreshTabStops()})))};for(a.s();!(e=a.n()).done;)o()}catch(e){a.e(e)}finally{a.f()}};for(i.s();!(r=i.n()).done;)a()}catch(e){i.e(e)}finally{i.f()}}},{key:"processStyleName",value:function(e){return e?"".concat(this.className,"_").concat(function(e){return null==e?void 0:e.replace(/[ .]+/g,"-").replace(/[&]+/g,"and").toLowerCase()}(e)):this.className}},{key:"processStyles",value:function(e){var t,r=this,n=Wa(e.filter((function(e){return null!=e.id})),(function(e){return e.id})),i=x(e.filter((function(e){return e.basedOn})));try{for(i.s();!(t=i.n()).done;){var a=t.value,o=n[a.basedOn];if(o){a.paragraphProps=Za(a.paragraphProps,o.paragraphProps),a.runProps=Za(a.runProps,o.runProps);var s,l=x(o.styles);try{var u=function(){var e=s.value,t=a.styles.find((function(t){return t.target==e.target}));t?r.copyStyleProperties(e.values,t.values):a.styles.push(m(m({},e),{},{values:m({},e.values)}))};for(l.s();!(s=l.n()).done;)u()}catch(e){l.e(e)}finally{l.f()}}else this.options.debug&&console.warn("Can't find base style ".concat(a.basedOn))}}catch(e){i.e(e)}finally{i.f()}var c,h=x(e);try{for(h.s();!(c=h.n()).done;){var f=c.value;f.cssName=this.processStyleName(f.id)}}catch(e){h.e(e)}finally{h.f()}return n}},{key:"prodessNumberings",value:function(e){var t,r=x(e.filter((function(e){return e.pStyleName})));try{for(r.s();!(t=r.n()).done;){var n,i=t.value,a=this.findStyle(i.pStyleName);(null==a||null===(n=a.paragraphProps)||void 0===n?void 0:n.numbering)&&(a.paragraphProps.numbering.level=i.level)}}catch(e){r.e(e)}finally{r.f()}}},{key:"processElement",value:function(e){if(e.children){var t,r=x(e.children);try{for(r.s();!(t=r.n()).done;){var n=t.value;n.parent=e,n.type==Xa.Table?this.processTable(n):this.processElement(n)}}catch(e){r.e(e)}finally{r.f()}}}},{key:"processTable",value:function(e){var t,r=x(e.children);try{for(r.s();!(t=r.n()).done;){var n,i=x(t.value.children);try{for(i.s();!(n=i.n()).done;){var a=n.value;a.cssStyle=this.copyStyleProperties(e.cellStyle,a.cssStyle,["border-left","border-right","border-top","border-bottom","padding-left","padding-right","padding-top","padding-bottom"]),this.processElement(a)}}catch(e){i.e(e)}finally{i.f()}}}catch(e){r.e(e)}finally{r.f()}}},{key:"copyStyleProperties",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!e)return t;var n,i=x((null==t&&(t={}),null==r&&(r=Object.getOwnPropertyNames(e)),r));try{for(i.s();!(n=i.n()).done;){var a=n.value;e.hasOwnProperty(a)&&!t.hasOwnProperty(a)&&(t[a]=e[a])}}catch(e){i.e(e)}finally{i.f()}return t}},{key:"createPageElement",value:function(e,t){var r=this.createElement("section",{className:e});return t&&(t.pageMargins&&(r.style.paddingLeft=t.pageMargins.left,r.style.paddingRight=t.pageMargins.right,r.style.paddingTop=t.pageMargins.top,r.style.paddingBottom=t.pageMargins.bottom),t.pageSize&&(this.options.ignoreWidth||(r.style.width=t.pageSize.width),this.options.ignoreHeight||(r.style.minHeight=t.pageSize.height))),r}},{key:"createSectionContent",value:function(e){var t=this.createElement("article");return e.columns&&e.columns.numberOfColumns&&(t.style.columnCount="".concat(e.columns.numberOfColumns),t.style.columnGap=e.columns.space,e.columns.separator&&(t.style.columnRule="1px solid black")),t}},{key:"renderSections",value:function(e){var t=[];this.processElement(e);for(var r=this.splitBySection(e.children,e.props),n=this.groupByPageBreaks(r),i=null,a=0,o=n.length;a<o;a++){this.currentFootnoteIds=[];var s=n[a][0].sectProps,l=this.createPageElement(this.className,s);this.renderStyleValues(e.cssStyle,l),this.options.renderHeaders&&this.renderHeaderFooter(s.headerRefs,s,t.length,i!=s,l);var u,c=x(n[a]);try{for(c.s();!(u=c.n()).done;){var h=u.value,f=this.createSectionContent(h.sectProps);this.renderElements(h.elements,f),l.appendChild(f),s=h.sectProps}}catch(e){c.e(e)}finally{c.f()}this.options.renderFootnotes&&this.renderNotes(this.currentFootnoteIds,this.footnoteMap,l),this.options.renderEndnotes&&a==o-1&&this.renderNotes(this.currentEndnoteIds,this.endnoteMap,l),this.options.renderFooters&&this.renderHeaderFooter(s.footerRefs,s,t.length,i!=s,l),t.push(l),i=s}return t}},{key:"renderHeaderFooter",value:function(e,t,r,n,i){if(e){var a,o,s=null!==(a=null!==(o=t.titlePage&&n?e.find((function(e){return"first"==e.type})):null)&&void 0!==o?o:r%2==1?e.find((function(e){return"even"==e.type})):null)&&void 0!==a?a:e.find((function(e){return"default"==e.type})),l=s&&this.document.findPartByRelId(s.id,this.document.documentPart);if(l){this.currentPart=l,this.usedHederFooterParts.includes(l.path)||(this.processElement(l.rootElement),this.usedHederFooterParts.push(l.path));var u=y(this.renderElements([l.rootElement],i),1)[0];null!=t&&t.pageMargins&&(l.rootElement.type===Xa.Header?(u.style.marginTop="calc(".concat(t.pageMargins.header," - ").concat(t.pageMargins.top,")"),u.style.minHeight="calc(".concat(t.pageMargins.top," - ").concat(t.pageMargins.header,")")):l.rootElement.type===Xa.Footer&&(u.style.marginBottom="calc(".concat(t.pageMargins.footer," - ").concat(t.pageMargins.bottom,")"),u.style.minHeight="calc(".concat(t.pageMargins.bottom," - ").concat(t.pageMargins.footer,")"))),this.currentPart=null}}}},{key:"isPageBreakElement",value:function(e){return e.type==Xa.Break&&("lastRenderedPageBreak"==e.break?!this.options.ignoreLastRenderedPageBreak:"page"==e.break)}},{key:"isPageBreakSection",value:function(e,t){var r,n,i,a,o,s;return!(!e||!t||(null===(r=e.pageSize)||void 0===r?void 0:r.orientation)==(null===(n=t.pageSize)||void 0===n?void 0:n.orientation)&&(null===(i=e.pageSize)||void 0===i?void 0:i.width)==(null===(a=t.pageSize)||void 0===a?void 0:a.width)&&(null===(o=e.pageSize)||void 0===o?void 0:o.height)==(null===(s=t.pageSize)||void 0===s?void 0:s.height))}},{key:"splitBySection",value:function(e,t){var r,n=this,i={sectProps:null,elements:[],pageBreak:!1},a=[i],o=x(e);try{for(o.s();!(r=o.n()).done;){var s=r.value;if(s.type==Xa.Paragraph){var l,u=this.findStyle(s.styleName);(null==u||null===(l=u.paragraphProps)||void 0===l?void 0:l.pageBreakBefore)&&(i.sectProps=h,i.pageBreak=!0,i={sectProps:null,elements:[],pageBreak:!1},a.push(i))}if(i.elements.push(s),s.type==Xa.Paragraph){var c=s,h=c.sectionProps,f=-1,d=-1;if(this.options.breakPages&&c.children&&(f=c.children.findIndex((function(e){var t,r;return-1!=(d=null!==(t=null===(r=e.children)||void 0===r?void 0:r.findIndex(n.isPageBreakElement.bind(n)))&&void 0!==t?t:-1)}))),(h||-1!=f)&&(i.sectProps=h,i.pageBreak=-1!=f,i={sectProps:null,elements:[],pageBreak:!1},a.push(i)),-1!=f){var p=c.children[f],g=d<p.children.length-1;if(f<c.children.length-1||g){var v=s.children,y=m(m({},s),{},{children:v.slice(f)});if(s.children=v.slice(0,f),i.elements.push(y),g){var b=p.children,w=m(m({},p),{},{children:b.slice(0,d)});s.children.push(w),p.children=b.slice(d)}}}}}}catch(e){o.e(e)}finally{o.f()}for(var k=null,_=a.length-1;_>=0;_--){var S;null==a[_].sectProps?a[_].sectProps=null!==(S=k)&&void 0!==S?S:t:k=a[_].sectProps}return a}},{key:"groupByPageBreaks",value:function(e){var t,r,n=[],i=[n],a=x(e);try{for(a.s();!(r=a.n()).done;){var o=r.value;n.push(o),(this.options.ignoreLastRenderedPageBreak||o.pageBreak||this.isPageBreakSection(t,o.sectProps))&&i.push(n=[]),t=o.sectProps}}catch(e){a.e(e)}finally{a.f()}return i.filter((function(e){return e.length>0}))}},{key:"renderWrapper",value:function(e){return this.createElement("div",{className:"".concat(this.className,"-wrapper")},e)}},{key:"renderDefaultStyle",value:function(){var e=this.className,t="\n.".concat(e,"-wrapper { background: gray; padding: 30px; padding-bottom: 0px; display: flex; flex-flow: column; align-items: center; } \n.").concat(e,"-wrapper>section.").concat(e," { background: white; box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); margin-bottom: 30px; }\n.").concat(e," { color: black; hyphens: auto; text-underline-position: from-font; }\nsection.").concat(e," { box-sizing: border-box; display: flex; flex-flow: column nowrap; position: relative; overflow: hidden; }\nsection.").concat(e,">article { margin-bottom: auto; z-index: 1; }\nsection.").concat(e,">footer { z-index: 1; }\n.").concat(e," table { border-collapse: collapse; }\n.").concat(e," table td, .").concat(e," table th { vertical-align: top; }\n.").concat(e," p { margin: 0pt; min-height: 1em; }\n.").concat(e," span { white-space: pre-wrap; overflow-wrap: break-word; }\n.").concat(e," a { color: inherit; text-decoration: inherit; }\n.").concat(e," svg { fill: transparent; }\n");return this.options.renderComments&&(t+="\n.".concat(e,"-comment-ref { cursor: default; }\n.").concat(e,"-comment-popover { display: none; z-index: 1000; padding: 0.5rem; background: white; position: absolute; box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.25); width: 30ch; }\n.").concat(e,"-comment-ref:hover~.").concat(e,"-comment-popover { display: block; }\n.").concat(e,"-comment-author,.").concat(e,"-comment-date { font-size: 0.875rem; color: #888; }\n")),ms(t)}},{key:"renderNumbering",value:function(e,t){var r,n=this,i="",a=[],o=x(e);try{var s,l,u,c=function(){if(s=r.value,l="p.".concat(n.numberingClass(s.id,s.level)),u="none",s.bullet){var e="--".concat(n.className,"-").concat(s.bullet.src).toLowerCase();i+=n.styleToString("".concat(l,":before"),{content:"' '",display:"inline-block",background:"var(".concat(e,")")},s.bullet.style),n.tasks.push(n.document.loadNumberingImage(s.bullet.src).then((function(r){var i="".concat(n.rootSelector," { ").concat(e,": url(").concat(r,") }");t.appendChild(ms(i))})))}else if(s.levelText){var o=n.numberingCounter(s.id,s.level),c=o+" "+(s.start-1);s.level>0&&(i+=n.styleToString("p.".concat(n.numberingClass(s.id,s.level-1)),{"counter-reset":c})),a.push(c),i+=n.styleToString("".concat(l,":before"),m({content:n.levelTextToContent(s.levelText,s.suff,s.id,n.numFormatToCssValue(s.format)),"counter-increment":o},s.rStyle))}else u=n.numFormatToCssValue(s.format);i+=n.styleToString(l,m({display:"list-item","list-style-position":"inside","list-style-type":u},s.pStyle))};for(o.s();!(r=o.n()).done;)c()}catch(e){o.e(e)}finally{o.f()}return a.length>0&&(i+=this.styleToString(this.rootSelector,{"counter-reset":a.join(" ")})),ms(i)}},{key:"renderStyles",value:function(e){var t,r="",n=this.styleMap,i=Wa(e.filter((function(e){return e.isDefault})),(function(e){return e.target})),a=x(e);try{for(a.s();!(t=a.n()).done;){var o=t.value,s=o.styles;if(o.linked){var l=o.linked&&n[o.linked];l?s=s.concat(l.styles):this.options.debug&&console.warn("Can't find linked style ".concat(o.linked))}var u,c=x(s);try{for(c.s();!(u=c.n()).done;){var h,f=u.value,d="".concat(null!==(h=o.target)&&void 0!==h?h:"",".").concat(o.cssName);o.target!=f.target&&(d+=" ".concat(f.target)),i[o.target]==o&&(d=".".concat(this.className," ").concat(o.target,", ")+d),r+=this.styleToString(d,f.values)}}catch(e){c.e(e)}finally{c.f()}}}catch(e){a.e(e)}finally{a.f()}return ms(r)}},{key:"renderNotes",value:function(e,t,r){var n=e.map((function(e){return t[e]})).filter((function(e){return e}));if(n.length>0){var i=this.createElement("ol",null,this.renderElements(n));r.appendChild(i)}}},{key:"renderElement",value:function(e){switch(e.type){case Xa.Paragraph:return this.renderParagraph(e);case Xa.BookmarkStart:return this.renderBookmarkStart(e);case Xa.BookmarkEnd:return null;case Xa.Run:return this.renderRun(e);case Xa.Table:return this.renderTable(e);case Xa.Row:return this.renderTableRow(e);case Xa.Cell:return this.renderTableCell(e);case Xa.Hyperlink:return this.renderHyperlink(e);case Xa.SmartTag:return this.renderSmartTag(e);case Xa.Drawing:return this.renderDrawing(e);case Xa.Image:return this.renderImage(e);case Xa.Text:case Xa.Text:return this.renderText(e);case Xa.DeletedText:return this.renderDeletedText(e);case Xa.Tab:return this.renderTab(e);case Xa.Symbol:return this.renderSymbol(e);case Xa.Break:return this.renderBreak(e);case Xa.Footer:return this.renderContainer(e,"footer");case Xa.Header:return this.renderContainer(e,"header");case Xa.Footnote:case Xa.Endnote:return this.renderContainer(e,"li");case Xa.FootnoteReference:return this.renderFootnoteReference(e);case Xa.EndnoteReference:return this.renderEndnoteReference(e);case Xa.NoBreakHyphen:return this.createElement("wbr");case Xa.VmlPicture:return this.renderVmlPicture(e);case Xa.VmlElement:return this.renderVmlElement(e);case Xa.MmlMath:return this.renderContainerNS(e,ls,"math",{xmlns:ls});case Xa.MmlMathParagraph:return this.renderContainer(e,"span");case Xa.MmlFraction:return this.renderContainerNS(e,ls,"mfrac");case Xa.MmlBase:return this.renderContainerNS(e,ls,e.parent.type==Xa.MmlMatrixRow?"mtd":"mrow");case Xa.MmlNumerator:case Xa.MmlDenominator:case Xa.MmlFunction:case Xa.MmlLimit:case Xa.MmlBox:return this.renderContainerNS(e,ls,"mrow");case Xa.MmlGroupChar:return this.renderMmlGroupChar(e);case Xa.MmlLimitLower:return this.renderContainerNS(e,ls,"munder");case Xa.MmlMatrix:return this.renderContainerNS(e,ls,"mtable");case Xa.MmlMatrixRow:return this.renderContainerNS(e,ls,"mtr");case Xa.MmlRadical:return this.renderMmlRadical(e);case Xa.MmlSuperscript:return this.renderContainerNS(e,ls,"msup");case Xa.MmlSubscript:return this.renderContainerNS(e,ls,"msub");case Xa.MmlDegree:case Xa.MmlSuperArgument:case Xa.MmlSubArgument:return this.renderContainerNS(e,ls,"mn");case Xa.MmlFunctionName:return this.renderContainerNS(e,ls,"ms");case Xa.MmlDelimiter:return this.renderMmlDelimiter(e);case Xa.MmlRun:return this.renderMmlRun(e);case Xa.MmlNary:return this.renderMmlNary(e);case Xa.MmlPreSubSuper:return this.renderMmlPreSubSuper(e);case Xa.MmlBar:return this.renderMmlBar(e);case Xa.MmlEquationArray:return this.renderMllList(e);case Xa.Inserted:return this.renderInserted(e);case Xa.Deleted:return this.renderDeleted(e);case Xa.CommentRangeStart:return this.renderCommentRangeStart(e);case Xa.CommentRangeEnd:return this.renderCommentRangeEnd(e);case Xa.CommentReference:return this.renderCommentReference(e)}return null}},{key:"renderChildren",value:function(e,t){return this.renderElements(e.children,t)}},{key:"renderElements",value:function(e,t){var r=this;if(null==e)return null;var n=e.flatMap((function(e){return r.renderElement(e)})).filter((function(e){return null!=e}));return t&&ps(t,n),n}},{key:"renderContainer",value:function(e,t,r){return this.createElement(t,r,this.renderChildren(e))}},{key:"renderContainerNS",value:function(e,t,r,n){return fs(t,r,n,this.renderChildren(e))}},{key:"renderParagraph",value:function(e){var t,r,n,i,a=this.createElement("p"),o=this.findStyle(e.styleName);null!==(t=e.tabs)&&void 0!==t||(e.tabs=null==o||null===(r=o.paragraphProps)||void 0===r?void 0:r.tabs),this.renderClass(e,a),this.renderChildren(e,a),this.renderStyleValues(e.cssStyle,a),this.renderCommonProperties(a.style,e);var s=null!==(n=e.numbering)&&void 0!==n?n:null==o||null===(i=o.paragraphProps)||void 0===i?void 0:i.numbering;return s&&a.classList.add(this.numberingClass(s.id,s.level)),a}},{key:"renderRunProperties",value:function(e,t){this.renderCommonProperties(e,t)}},{key:"renderCommonProperties",value:function(e,t){null!=t&&(t.color&&(e.color=t.color),t.fontSize&&(e["font-size"]=t.fontSize))}},{key:"renderHyperlink",value:function(e){var t=this.createElement("a");if(this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),e.href)t.href=e.href;else if(e.id){var r=this.document.documentPart.rels.find((function(t){return t.id==e.id&&"External"===t.targetMode}));t.href=null==r?void 0:r.target}return t}},{key:"renderSmartTag",value:function(e){var t=this.createElement("span");return this.renderChildren(e,t),t}},{key:"renderCommentRangeStart",value:function(e){var t;if(!this.options.renderComments)return null;var r=new Range;null===(t=this.commentHighlight)||void 0===t||t.add(r);var n=this.htmlDocument.createComment("start of comment #".concat(e.id));return this.later((function(){return r.setStart(n,0)})),this.commentMap[e.id]=r,n}},{key:"renderCommentRangeEnd",value:function(e){if(!this.options.renderComments)return null;var t=this.commentMap[e.id],r=this.htmlDocument.createComment("end of comment #".concat(e.id));return this.later((function(){return null==t?void 0:t.setEnd(r,0)})),r}},{key:"renderCommentReference",value:function(e){var t;if(!this.options.renderComments)return null;var r=null===(t=this.document.commentsPart)||void 0===t?void 0:t.commentMap[e.id];if(!r)return null;var n=new DocumentFragment,i=cs("span",{className:"".concat(this.className,"-comment-ref")},["💬"]),a=cs("div",{className:"".concat(this.className,"-comment-popover")});return this.renderCommentContent(r,a),n.appendChild(this.htmlDocument.createComment("comment #".concat(r.id," by ").concat(r.author," on ").concat(r.date))),n.appendChild(i),n.appendChild(a),n}},{key:"renderCommentContent",value:function(e,t){t.appendChild(cs("div",{className:"".concat(this.className,"-comment-author")},[e.author])),t.appendChild(cs("div",{className:"".concat(this.className,"-comment-date")},[new Date(e.date).toLocaleString()])),this.renderChildren(e,t)}},{key:"renderDrawing",value:function(e){var t=this.createElement("div");return t.style.display="inline-block",t.style.position="relative",t.style.textIndent="0px",this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),t}},{key:"renderImage",value:function(e){var t=this.createElement("img");return this.renderStyleValues(e.cssStyle,t),this.document&&this.tasks.push(this.document.loadDocumentImage(e.src,this.currentPart).then((function(e){t.src=e}))),t}},{key:"renderText",value:function(e){return this.htmlDocument.createTextNode(e.text)}},{key:"renderDeletedText",value:function(e){return this.options.renderEndnotes?this.htmlDocument.createTextNode(e.text):null}},{key:"renderBreak",value:function(e){return"textWrapping"==e.break?this.createElement("br"):null}},{key:"renderInserted",value:function(e){return this.options.renderChanges?this.renderContainer(e,"ins"):this.renderChildren(e)}},{key:"renderDeleted",value:function(e){return this.options.renderChanges?this.renderContainer(e,"del"):null}},{key:"renderSymbol",value:function(e){var t=this.createElement("span");return t.style.fontFamily=e.font,t.innerHTML="&#x".concat(e.char,";"),t}},{key:"renderFootnoteReference",value:function(e){var t=this.createElement("sup");return this.currentFootnoteIds.push(e.id),t.textContent="".concat(this.currentFootnoteIds.length),t}},{key:"renderEndnoteReference",value:function(e){var t=this.createElement("sup");return this.currentEndnoteIds.push(e.id),t.textContent="".concat(this.currentEndnoteIds.length),t}},{key:"renderTab",value:function(e){var t=this.createElement("span");if(t.innerHTML="&emsp;",this.options.experimental){var r;t.className=this.tabStopClass();var n=null===(r=function(e,t){for(var r=e.parent;null!=r&&r.type!=t;)r=r.parent;return r}(e,Xa.Paragraph))||void 0===r?void 0:r.tabs;this.currentTabs.push({stops:n,span:t})}return t}},{key:"renderBookmarkStart",value:function(e){var t=this.createElement("span");return t.id=e.name,t}},{key:"renderRun",value:function(e){if(e.fieldRun)return null;var t=this.createElement("span");if(e.id&&(t.id=e.id),this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),e.verticalAlign){var r=this.createElement(e.verticalAlign);this.renderChildren(e,r),t.appendChild(r)}else this.renderChildren(e,t);return t}},{key:"renderTable",value:function(e){var t=this.createElement("table");return this.tableCellPositions.push(this.currentCellPosition),this.tableVerticalMerges.push(this.currentVerticalMerge),this.currentVerticalMerge={},this.currentCellPosition={col:0,row:0},e.columns&&t.appendChild(this.renderTableColumns(e.columns)),this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),this.currentVerticalMerge=this.tableVerticalMerges.pop(),this.currentCellPosition=this.tableCellPositions.pop(),t}},{key:"renderTableColumns",value:function(e){var t,r=this.createElement("colgroup"),n=x(e);try{for(n.s();!(t=n.n()).done;){var i=t.value,a=this.createElement("col");i.width&&(a.style.width=i.width),r.appendChild(a)}}catch(e){n.e(e)}finally{n.f()}return r}},{key:"renderTableRow",value:function(e){var t=this.createElement("tr");return this.currentCellPosition.col=0,this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),this.currentCellPosition.row++,t}},{key:"renderTableCell",value:function(e){var t=this.createElement("td"),r=this.currentCellPosition.col;return e.verticalMerge?"restart"==e.verticalMerge?(this.currentVerticalMerge[r]=t,t.rowSpan=1):this.currentVerticalMerge[r]&&(this.currentVerticalMerge[r].rowSpan+=1,t.style.display="none"):this.currentVerticalMerge[r]=null,this.renderClass(e,t),this.renderChildren(e,t),this.renderStyleValues(e.cssStyle,t),e.span&&(t.colSpan=e.span),this.currentCellPosition.col+=t.colSpan,t}},{key:"renderVmlPicture",value:function(e){var t=cs("div");return this.renderChildren(e,t),t}},{key:"renderVmlElement",value:function(e){var t,r,n=hs("svg");n.setAttribute("style",e.cssStyleText);var i=this.renderVmlChildElement(e);return null!==(t=e.imageHref)&&void 0!==t&&t.id&&this.tasks.push(null===(r=this.document)||void 0===r?void 0:r.loadDocumentImage(e.imageHref.id,this.currentPart).then((function(e){return i.setAttribute("href",e)}))),n.appendChild(i),requestAnimationFrame((function(){var e=n.firstElementChild.getBBox();n.setAttribute("width","".concat(Math.ceil(e.x+e.width))),n.setAttribute("height","".concat(Math.ceil(e.y+e.height)))})),n}},{key:"renderVmlChildElement",value:function(e){var t=hs(e.tagName);Object.entries(e.attrs).forEach((function(e){var r=y(e,2),n=r[0],i=r[1];return t.setAttribute(n,i)}));var r,n=x(e.children);try{for(n.s();!(r=n.n()).done;){var i=r.value;i.type==Xa.VmlElement?t.appendChild(this.renderVmlChildElement(i)):t.appendChild.apply(t,v(qa(this.renderElement(i))))}}catch(e){n.e(e)}finally{n.f()}return t}},{key:"renderMmlRadical",value:function(e){var t,r=e.children.find((function(e){return e.type==Xa.MmlBase}));if(null!==(t=e.props)&&void 0!==t&&t.hideDegree)return fs(ls,"msqrt",null,this.renderElements([r]));var n=e.children.find((function(e){return e.type==Xa.MmlDegree}));return fs(ls,"mroot",null,this.renderElements([r,n]))}},{key:"renderMmlDelimiter",value:function(e){var t,r,n=[];return n.push(fs(ls,"mo",null,[null!==(t=e.props.beginChar)&&void 0!==t?t:"("])),n.push.apply(n,v(this.renderElements(e.children))),n.push(fs(ls,"mo",null,[null!==(r=e.props.endChar)&&void 0!==r?r:")"])),fs(ls,"mrow",null,n)}},{key:"renderMmlNary",value:function(e){var t,r,n=[],i=Wa(e.children,(function(e){return e.type})),a=i[Xa.MmlSuperArgument],o=i[Xa.MmlSubArgument],s=a?fs(ls,"mo",null,qa(this.renderElement(a))):null,l=o?fs(ls,"mo",null,qa(this.renderElement(o))):null,u=fs(ls,"mo",null,[null!==(t=null===(r=e.props)||void 0===r?void 0:r.char)&&void 0!==t?t:"∫"]);return s||l?n.push(fs(ls,"munderover",null,[u,l,s])):s?n.push(fs(ls,"mover",null,[u,s])):l?n.push(fs(ls,"munder",null,[u,l])):n.push(u),n.push.apply(n,v(this.renderElements(i[Xa.MmlBase].children))),fs(ls,"mrow",null,n)}},{key:"renderMmlPreSubSuper",value:function(e){var t=[],r=Wa(e.children,(function(e){return e.type})),n=r[Xa.MmlSuperArgument],i=r[Xa.MmlSubArgument],a=n?fs(ls,"mo",null,qa(this.renderElement(n))):null,o=i?fs(ls,"mo",null,qa(this.renderElement(i))):null,s=fs(ls,"mo",null);return t.push(fs(ls,"msubsup",null,[s,o,a])),t.push.apply(t,v(this.renderElements(r[Xa.MmlBase].children))),fs(ls,"mrow",null,t)}},{key:"renderMmlGroupChar",value:function(e){var t="bot"===e.props.verticalJustification?"mover":"munder",r=this.renderContainerNS(e,ls,t);return e.props.char&&r.appendChild(fs(ls,"mo",null,[e.props.char])),r}},{key:"renderMmlBar",value:function(e){var t=this.renderContainerNS(e,ls,"mrow");switch(e.props.position){case"top":t.style.textDecoration="overline";break;case"bottom":t.style.textDecoration="underline"}return t}},{key:"renderMmlRun",value:function(e){var t=fs(ls,"ms");return this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),this.renderChildren(e,t),t}},{key:"renderMllList",value:function(e){var t=fs(ls,"mtable");this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),this.renderChildren(e);var r,n=x(this.renderChildren(e));try{for(n.s();!(r=n.n()).done;){var i=r.value;t.appendChild(fs(ls,"mtr",null,[fs(ls,"mtd",null,[i])]))}}catch(e){n.e(e)}finally{n.f()}return t}},{key:"renderStyleValues",value:function(e,t){for(var r in e)r.startsWith("$")?t.setAttribute(r.slice(1),e[r]):t.style[r]=e[r]}},{key:"renderClass",value:function(e,t){e.className&&(t.className=e.className),e.styleName&&t.classList.add(this.processStyleName(e.styleName))}},{key:"findStyle",value:function(e){var t;return e&&(null===(t=this.styleMap)||void 0===t?void 0:t[e])}},{key:"numberingClass",value:function(e,t){return"".concat(this.className,"-num-").concat(e,"-").concat(t)}},{key:"tabStopClass",value:function(){return"".concat(this.className,"-tab-stop")}},{key:"styleToString",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n="".concat(e," {\r\n");for(var i in t)i.startsWith("$")||(n+=" ".concat(i,": ").concat(t[i],";\r\n"));return r&&(n+=r),n+"}\r\n"}},{key:"numberingCounter",value:function(e,t){return"".concat(this.className,"-num-").concat(e,"-").concat(t)}},{key:"levelTextToContent",value:function(e,t,r,n){var i,a=this;return'"'.concat(e.replace(/%\d*/g,(function(e){var t=parseInt(e.substring(1),10)-1;return'"counter('.concat(a.numberingCounter(r,t),", ").concat(n,')"')}))).concat(null!==(i={tab:"\\9",space:"\\a0"}[t])&&void 0!==i?i:"",'"')}},{key:"numFormatToCssValue",value:function(e){var t;return null!==(t={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"}[e])&&void 0!==t?t:e}},{key:"refreshTabStops",value:function(){var e=this;this.options.experimental&&(clearTimeout(this.tabsTimeout),this.tabsTimeout=setTimeout((function(){var t,r=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body,t=document.createElement("div");t.style.width="100pt",e.appendChild(t);var r=100/t.offsetWidth;return e.removeChild(t),r}(),n=x(e.currentTabs);try{for(n.s();!(t=n.n()).done;){var i=t.value;os(i.span,i.stops,e.defaultTabSize,r)}}catch(e){n.e(e)}finally{n.f()}}),500))}},{key:"later",value:function(e){this.postRenderTasks.push(e)}}]),e}();function cs(e,t,r){return fs(void 0,e,t,r)}function hs(e,t,r){return fs("http://www.w3.org/2000/svg",e,t,r)}function fs(e,t,r,n){var i=e?document.createElementNS(e,t):document.createElement(t);return Object.assign(i,r),n&&ps(i,n),i}function ds(e){e.innerHTML=""}function ps(e,t){t.forEach((function(t){return e.appendChild("string"==typeof(r=t)||r instanceof String?document.createTextNode(t):t);var r}))}function ms(e){return cs("style",{innerHTML:e})}function gs(e,t){e.appendChild(document.createComment(t))}var vs={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,renderChanges:!1,renderComments:!1};function ys(e,t,r,n){return bs.apply(this,arguments)}function bs(){return(bs=A(P().mark((function e(t,r,n,i){var a;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,function(e,t){var r=m(m({},vs),t);return Fo.load(e,new ts(r),r)}(t,i);case 2:return a=e.sent,e.next=5,function(){var e=A(P().mark((function e(t,r,n,i){var a,o;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=m(m({},vs),i),o=new us(window.document),e.abrupt("return",(o.render(t,r,n,a),Promise.allSettled(o.tasks)));case 2:case"end":return e.stop()}}),e)})));return function(t,r,n,i){return e.apply(this,arguments)}}()(a,r,n,i);case 5:return e.abrupt("return",a);case 6:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var ws,ks={ignoreLastRenderedPageBreak:!1},_s={getData:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e?function(e,t){return fetch(e,t).then((function(e){return 200!==e.status?Promise.reject(e):e}))}(e,t):Promise.resolve(e)},render:function(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e?(e instanceof Blob?r=e:e instanceof Response?r=e.blob():e instanceof ArrayBuffer&&(r=new Blob([e])),ys(r,t,t,m(m({},ks),n))):(t.innerHTML="",Promise.resolve())},getBlob:(ws=A(P().mark((function e(t){var r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(t instanceof Blob)){e.next=4;break}r=t,e.next=11;break;case 4:if(!(t instanceof Response)){e.next=10;break}return e.next=7,t.blob();case 7:r=e.sent,e.next=11;break;case 10:t instanceof ArrayBuffer&&(r=new Blob([t]));case 11:return e.abrupt("return",r);case 12:case"end":return e.stop()}}),e)}))),function(e){return ws.apply(this,arguments)})};function Ss(){return(Ss=A(P().mark((function e(t,r){return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r&&(r instanceof ArrayBuffer&&(r=new Blob([r])),function(e,t){var r=document.createElement("a");r.download=e,r.style.display="none",r.href=t,document.body.appendChild(r),r.click(),document.body.removeChild(r)}(t,URL.createObjectURL(r)));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var xs=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};N(this,e),g(this,"container",null),g(this,"wrapper",null),g(this,"wrapperMain",null),g(this,"options",{}),g(this,"requestOptions",{}),g(this,"fileData",null),this.container=t,this.options=r,this.requestOptions=n,this.createWrapper()}return R(e,[{key:"createWrapper",value:function(){this.wrapper=document.createElement("div"),this.wrapper.className="vue-office-docx",this.wrapperMain=document.createElement("div"),this.wrapperMain.className="vue-office-docx-main",this.wrapper.appendChild(this.wrapperMain),this.container.appendChild(this.wrapper)}},{key:"setOptions",value:function(e){this.options=e}},{key:"setRequestOptions",value:function(e){this.requestOptions=e}},{key:"preview",value:function(e){var t=this;return new Promise((function(r,n){_s.getData(e,t.requestOptions).then(function(){var e=A(P().mark((function e(i){return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,_s.getBlob(i);case 2:t.fileData=e.sent,_s.render(t.fileData,t.wrapperMain,t.options).then((function(){r()})).catch((function(e){_s.render("",t.wrapperMain,t.options),n(e)}));case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){_s.render("",t.wrapperMain,t.options),n(e)}))}))}},{key:"save",value:function(e){!function(e,t){Ss.apply(this,arguments)}(e||"js-preview-docx-".concat((new Date).getTime(),".docx"),this.fileData)}},{key:"destroy",value:function(){this.container.removeChild(this.wrapper),this.container=null,this.wrapper=null,this.wrapperMain=null,this.options=null,this.requestOptions=null}}]),e}(),Cs={init:function(e,t,r){return new xs(e,t,r)}}}).call(this,r(32),r(318),r(563).setImmediate,r(557).Buffer)},890:function(e,t,r){e.exports=i;var n=r(577).EventEmitter;function i(){n.call(this)}r(566)(i,n),i.Readable=r(597),i.Writable=r(898),i.Duplex=r(899),i.Transform=r(900),i.PassThrough=r(901),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function a(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",a),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",l));var o=!1;function s(){o||(o=!0,e.end())}function l(){o||(o=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){if(c(),0===n.listenerCount(this,"error"))throw e}function c(){r.removeListener("data",i),e.removeListener("drain",a),r.removeListener("end",s),r.removeListener("close",l),r.removeListener("error",u),e.removeListener("error",u),r.removeListener("end",c),r.removeListener("close",c),e.removeListener("close",c)}return r.on("error",u),e.on("error",u),r.on("end",c),r.on("close",c),e.on("close",c),e.emit("pipe",r),e}},891:function(e,t){var r={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==r.call(e)}},892:function(e,t){},893:function(e,t,r){"use strict";var n=r(598).Buffer,i=r(894);e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return n.alloc(0);for(var t,r,i,a=n.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=a,i=s,t.copy(r,i),s+=o.data.length,o=o.next;return a},e}(),i&&i.inspect&&i.inspect.custom&&(e.exports.prototype[i.inspect.custom]=function(){var e=i.inspect({length:this.length});return this.constructor.name+" "+e})},894:function(e,t){},895:function(e,t,r){(function(t){function r(e){try{if(!t.localStorage)return!1}catch(e){return!1}var r=t.localStorage[e];return null!=r&&"true"===String(r).toLowerCase()}e.exports=function(e,t){if(r("noDeprecation"))return e;var n=!1;return function(){if(!n){if(r("throwDeprecation"))throw new Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),n=!0}return e.apply(this,arguments)}}}).call(this,r(32))},896:function(e,t,r){var n=r(557),i=n.Buffer;function a(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(a(n,t),t.Buffer=o),o.prototype=Object.create(i.prototype),a(i,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},897:function(e,t,r){"use strict";e.exports=a;var n=r(659),i=Object.create(r(570));function a(e){if(!(this instanceof a))return new a(e);n.call(this,e)}i.inherits=r(566),i.inherits(a,n),a.prototype._transform=function(e,t,r){r(null,e)}},898:function(e,t,r){e.exports=r(599)},899:function(e,t,r){e.exports=r(559)},900:function(e,t,r){e.exports=r(597).Transform},901:function(e,t,r){e.exports=r(597).PassThrough},902:function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},903:function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},904:function(e,t,r){var n=r(905);"string"==typeof n&&(n=[[e.i,n,""]]);var i={insertAt:"top",hmr:!0,transform:void 0,insertInto:void 0};r(91)(n,i);n.locals&&(e.exports=n.locals)},905:function(e,t,r){(t=r(90)(!1)).push([e.i,".vue-office-docx {\n height: 100%;\n overflow-y: auto;\n}\n.vue-office-docx .docx-wrapper > section.docx {\n margin-bottom: 5px;\n}\n@media screen and (max-width: 800px) {\n .vue-office-docx .docx-wrapper {\n padding: 10px;\n }\n .vue-office-docx .docx-wrapper > section.docx {\n padding: 10px!important;\n width: 100% !important;\n }\n}\n",""]),e.exports=t}}]);
3
+ //# sourceMappingURL=async-feffery_word_preview.js.map
4
+ //# sourceMappingURL=async-feffery_word_preview.js.map