chunk-c8c30b7e.3b7ed509.js 486 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-c8c30b7e"],{"07ac":function(e,t,r){var n=r("23e7"),i=r("6f53").values;n({target:"Object",stat:!0},{values:function(e){return i(e)}})},2639:function(e,t,r){e.exports=function(){return new Worker(r.p+"b5e2e7049ab3209c5c5e.worker.js")}},"26a4":function(e,t,r){},4383:function(module,exports,__webpack_require__){(function(Buffer,process,global){
  2. /**
  3. * @licstart The following is the entire license notice for the
  4. * Javascript code in this page
  5. *
  6. * Copyright 2020 Mozilla Foundation
  7. *
  8. * Licensed under the Apache License, Version 2.0 (the "License");
  9. * you may not use this file except in compliance with the License.
  10. * You may obtain a copy of the License at
  11. *
  12. * http://www.apache.org/licenses/LICENSE-2.0
  13. *
  14. * Unless required by applicable law or agreed to in writing, software
  15. * distributed under the License is distributed on an "AS IS" BASIS,
  16. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  17. * See the License for the specific language governing permissions and
  18. * limitations under the License.
  19. *
  20. * @licend The above is the entire license notice for the
  21. * Javascript code in this page
  22. */
  23. var p;p=function(){return q=[function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"addLinkAttributes",{enumerable:!0,get:function(){return o.addLinkAttributes}}),Object.defineProperty(t,"getFilenameFromUrl",{enumerable:!0,get:function(){return o.getFilenameFromUrl}}),Object.defineProperty(t,"LinkTarget",{enumerable:!0,get:function(){return o.LinkTarget}}),Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return o.loadScript}}),Object.defineProperty(t,"PDFDateString",{enumerable:!0,get:function(){return o.PDFDateString}}),Object.defineProperty(t,"RenderingCancelledException",{enumerable:!0,get:function(){return o.RenderingCancelledException}}),Object.defineProperty(t,"build",{enumerable:!0,get:function(){return s.build}}),Object.defineProperty(t,"getDocument",{enumerable:!0,get:function(){return s.getDocument}}),Object.defineProperty(t,"LoopbackPort",{enumerable:!0,get:function(){return s.LoopbackPort}}),Object.defineProperty(t,"PDFDataRangeTransport",{enumerable:!0,get:function(){return s.PDFDataRangeTransport}}),Object.defineProperty(t,"PDFWorker",{enumerable:!0,get:function(){return s.PDFWorker}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return s.version}}),Object.defineProperty(t,"CMapCompressionType",{enumerable:!0,get:function(){return u.CMapCompressionType}}),Object.defineProperty(t,"createObjectURL",{enumerable:!0,get:function(){return u.createObjectURL}}),Object.defineProperty(t,"createPromiseCapability",{enumerable:!0,get:function(){return u.createPromiseCapability}}),Object.defineProperty(t,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return u.createValidAbsoluteUrl}}),Object.defineProperty(t,"InvalidPDFException",{enumerable:!0,get:function(){return u.InvalidPDFException}}),Object.defineProperty(t,"MissingPDFException",{enumerable:!0,get:function(){return u.MissingPDFException}}),Object.defineProperty(t,"OPS",{enumerable:!0,get:function(){return u.OPS}}),Object.defineProperty(t,"PasswordResponses",{enumerable:!0,get:function(){return u.PasswordResponses}}),Object.defineProperty(t,"PermissionFlag",{enumerable:!0,get:function(){return u.PermissionFlag}}),Object.defineProperty(t,"removeNullCharacters",{enumerable:!0,get:function(){return u.removeNullCharacters}}),Object.defineProperty(t,"shadow",{enumerable:!0,get:function(){return u.shadow}}),Object.defineProperty(t,"UnexpectedResponseException",{enumerable:!0,get:function(){return u.UnexpectedResponseException}}),Object.defineProperty(t,"UNSUPPORTED_FEATURES",{enumerable:!0,get:function(){return u.UNSUPPORTED_FEATURES}}),Object.defineProperty(t,"Util",{enumerable:!0,get:function(){return u.Util}}),Object.defineProperty(t,"VerbosityLevel",{enumerable:!0,get:function(){return u.VerbosityLevel}}),Object.defineProperty(t,"AnnotationLayer",{enumerable:!0,get:function(){return l.AnnotationLayer}}),Object.defineProperty(t,"apiCompatibilityParams",{enumerable:!0,get:function(){return c.apiCompatibilityParams}}),Object.defineProperty(t,"GlobalWorkerOptions",{enumerable:!0,get:function(){return h.GlobalWorkerOptions}}),Object.defineProperty(t,"renderTextLayer",{enumerable:!0,get:function(){return f.renderTextLayer}}),Object.defineProperty(t,"SVGGraphics",{enumerable:!0,get:function(){return d.SVGGraphics}});var n,i,a,o=r(1),s=r(202),u=r(5),l=r(216),c=r(206),h=r(209),f=r(217),d=r(218);r(7).isNodeJS?(n=r(219).PDFNodeStream,(0,s.setPDFNetworkStreamFactory)((function(e){return new n(e)}))):(i=r(222).PDFNetworkStream,(0,o.isFetchSupported)()&&(a=r(223).PDFFetchStream),(0,s.setPDFNetworkStreamFactory)((function(e){return new(a&&(0,o.isValidFetchUrl)(e.url)?a:i)(e)})))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addLinkAttributes=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},r=t.url,n=t.target,i=t.rel;t=t.enabled,t=void 0===t||t;(0,a.assert)(r&&"string"==typeof r,'addLinkAttributes: A valid "url" parameter must provided.'),r=(0,a.removeNullCharacters)(r),t?e.href=e.title=r:(e.href="",e.title="Disabled: ".concat(r),e.onclick=function(){return!1});var o="";switch(n){case S.NONE:break;case S.SELF:o="_self";break;case S.BLANK:o="_blank";break;case S.PARENT:o="_parent";break;case S.TOP:o="_top"}e.target=o,e.rel="string"==typeof i?i:m},t.getFilenameFromUrl=function(e){var t=e.indexOf("#"),r=e.indexOf("?");r=Math.min(0<t?t:e.length,0<r?r:e.length);return e.substring(e.lastIndexOf("/",r)+1,r)},t.isFetchSupported=k,t.isValidFetchUrl=x,t.loadScript=function(e){return new Promise((function(t,r){var n=document.createElement("script");n.src=e,n.onload=t,n.onerror=function(){r(new Error("Cannot load script at: ".concat(n.src)))},(document.head||document.documentElement).appendChild(n)}))},t.deprecated=function(e){},t.PDFDateString=t.StatTimer=t.DOMSVGFactory=t.DOMCMapReaderFactory=t.BaseCMapReaderFactory=t.DOMCanvasFactory=t.BaseCanvasFactory=t.DEFAULT_LINK_REL=t.LinkTarget=t.RenderingCancelledException=t.PageViewport=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5);function o(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return s(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function s(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 u(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function l(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){u(a,n,i,o,s,"next",e)}function s(e){u(a,n,i,o,s,"throw",e)}o(void 0)}))}}function c(e){return(c="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)}function h(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}}),t&&f(e,t)}function f(e,t){return(f=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function d(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=p(t);return e=r?(e=p(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==c(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function p(e){return(p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(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,n.key,n)}}function y(e,t,r){return t&&g(e.prototype,t),r&&g(e,r),e}var m="noopener noreferrer nofollow";t.DEFAULT_LINK_REL=m;var b="http://www.w3.org/2000/svg",_=function(){function e(){v(this,e),this.constructor===e&&(0,a.unreachable)("Cannot initialize BaseCanvasFactory.")}return y(e,[{key:"create",value:function(e,t){(0,a.unreachable)("Abstract method `create` called.")}},{key:"reset",value:function(e,t,r){if(!e.canvas)throw new Error("Canvas is not specified");if(t<=0||r<=0)throw new Error("Invalid canvas size");e.canvas.width=t,e.canvas.height=r}},{key:"destroy",value:function(e){if(!e.canvas)throw new Error("Canvas is not specified");e.canvas.width=0,e.canvas.height=0,e.canvas=null,e.context=null}}]),e}();t.BaseCanvasFactory=_,t.DOMCanvasFactory=function(){h(t,_);var e=d(t);function t(){var r=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).ownerDocument,n=void 0===r?globalThis.document:r;return v(this,t),(r=e.call(this))._document=n,r}return y(t,[{key:"create",value:function(e,t){if(e<=0||t<=0)throw new Error("Invalid canvas size");var r=this._document.createElement("canvas"),n=r.getContext("2d");return r.width=e,r.height=t,{canvas:r,context:n}}}]),t}();var w=function(){function e(t){var r=t.baseUrl;r=void 0===r?null:r,t=t.isCompressed,t=void 0!==t&&t;v(this,e),this.constructor===e&&(0,a.unreachable)("Cannot initialize BaseCMapReaderFactory."),this.baseUrl=r,this.isCompressed=t}var t;return y(e,[{key:"fetch",value:(t=l(i.default.mark((function e(t){var r,n,o,s=this;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=t.name,this.baseUrl){e.next=3;break}throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');case 3:if(r){e.next=5;break}throw new Error("CMap name must be specified.");case 5:return n=this.baseUrl+r+(this.isCompressed?".bcmap":""),o=this.isCompressed?a.CMapCompressionType.BINARY:a.CMapCompressionType.NONE,e.abrupt("return",this._fetchData(n,o).catch((function(e){throw new Error("Unable to load ".concat(s.isCompressed?"binary ":"","CMap at: ").concat(n))})));case 8:case"end":return e.stop()}}),e,this)}))),function(e){return t.apply(this,arguments)})},{key:"_fetchData",value:function(e,t){(0,a.unreachable)("Abstract method `_fetchData` called.")}}]),e}();t.BaseCMapReaderFactory=w,t.DOMCMapReaderFactory=function(){h(t,w);var e=d(t);function t(){return v(this,t),e.apply(this,arguments)}return y(t,[{key:"_fetchData",value:function(e,t){var r=this;return k()&&x(e,document.baseURI)?fetch(e).then(function(){var e=l(i.default.mark((function e(n){var o;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n.ok){e.next=2;break}throw new Error(n.statusText);case 2:if(r.isCompressed)return e.t0=Uint8Array,e.next=6,n.arrayBuffer();e.next=10;break;case 6:e.t1=e.sent,o=new e.t0(e.t1),e.next=15;break;case 10:return e.t2=a.stringToBytes,e.next=13,n.text();case 13:e.t3=e.sent,o=(0,e.t2)(e.t3);case 15:return e.abrupt("return",{cMapData:o,compressionType:t});case 16:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()):new Promise((function(n,i){var o=new XMLHttpRequest;o.open("GET",e,!0),r.isCompressed&&(o.responseType="arraybuffer"),o.onreadystatechange=function(){if(o.readyState===XMLHttpRequest.DONE){var e;if((200===o.status||0===o.status)&&(r.isCompressed&&o.response?e=new Uint8Array(o.response):!r.isCompressed&&o.responseText&&(e=(0,a.stringToBytes)(o.responseText)),e))return void n({cMapData:e,compressionType:t});i(new Error(o.statusText))}},o.send(null)}))}}]),t}(),t.DOMSVGFactory=function(){function e(){v(this,e)}return y(e,[{key:"create",value:function(e,t){(0,a.assert)(0<e&&0<t,"Invalid SVG dimensions");var r=document.createElementNS(b,"svg:svg");return r.setAttribute("version","1.1"),r.setAttribute("width",e+"px"),r.setAttribute("height",t+"px"),r.setAttribute("preserveAspectRatio","none"),r.setAttribute("viewBox","0 0 "+e+" "+t),r}},{key:"createElement",value:function(e){return(0,a.assert)("string"==typeof e,"Invalid SVG element type"),document.createElementNS(b,e)}}]),e}(),t.PageViewport=function(){function e(t){var r=t.viewBox,n=t.scale,i=t.rotation,a=t.offsetX,o=void 0===a?0:a,s=t.offsetY,u=void 0===s?0:s;a=t.dontFlip,s=void 0!==a&&a;v(this,e),this.viewBox=r,this.scale=n,this.rotation=i,this.offsetX=o,this.offsetY=u;var l,c,h,f,d,p,g;t=(r[2]+r[0])/2,a=(r[3]+r[1])/2;switch(i=(i%=360)<0?i+360:i){case 180:l=-1,h=c=0,f=1;break;case 90:h=c=1,f=l=0;break;case 270:h=c=-1,f=l=0;break;case 0:h=c=0,f=-(l=1);break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}s&&(h=-h,f=-f),r=0===l?(d=Math.abs(a-r[1])*n+o,p=Math.abs(t-r[0])*n+u,g=Math.abs(r[3]-r[1])*n,Math.abs(r[2]-r[0])*n):(d=Math.abs(t-r[0])*n+o,p=Math.abs(a-r[1])*n+u,g=Math.abs(r[2]-r[0])*n,Math.abs(r[3]-r[1])*n),this.transform=[l*n,c*n,h*n,f*n,d-l*n*t-h*n*a,p-c*n*t-f*n*a],this.width=g,this.height=r}return y(e,[{key:"clone",value:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},r=t.scale,n=void 0===r?this.scale:r,i=t.rotation,a=void 0===i?this.rotation:i;r=t.offsetX,i=void 0===r?this.offsetX:r,r=t.offsetY,r=void 0===r?this.offsetY:r,t=t.dontFlip,t=void 0!==t&&t;return new e({viewBox:this.viewBox.slice(),scale:n,rotation:a,offsetX:i,offsetY:r,dontFlip:t})}},{key:"convertToViewportPoint",value:function(e,t){return a.Util.applyTransform([e,t],this.transform)}},{key:"convertToViewportRectangle",value:function(e){var t=a.Util.applyTransform([e[0],e[1]],this.transform);e=a.Util.applyTransform([e[2],e[3]],this.transform);return[t[0],t[1],e[0],e[1]]}},{key:"convertToPdfPoint",value:function(e,t){return a.Util.applyInverseTransform([e,t],this.transform)}}]),e}(),t.RenderingCancelledException=function(){h(t,a.BaseException);var e=d(t);function t(r,n){return v(this,t),(r=e.call(this,r)).type=n,r}return t}();var A,S={NONE:0,SELF:1,BLANK:2,PARENT:3,TOP:4};function k(){return"undefined"!=typeof fetch&&"undefined"!=typeof Response&&"body"in Response.prototype&&"undefined"!=typeof ReadableStream}function x(e,t){try{var r=(t?new URL(e,t):new URL(e)).protocol;return"http:"===r||"https:"===r}catch(e){return!1}}t.LinkTarget=S,t.StatTimer=function(){function e(){v(this,e),this.started=Object.create(null),this.times=[]}return y(e,[{key:"time",value:function(e){e in this.started&&(0,a.warn)("Timer is already running for ".concat(e)),this.started[e]=Date.now()}},{key:"timeEnd",value:function(e){e in this.started||(0,a.warn)("Timer has not been started for ".concat(e)),this.times.push({name:e,start:this.started[e],end:Date.now()}),delete this.started[e]}},{key:"toString",value:function(){var e,t=[],r=0,n=o(this.times);try{for(n.s();!(e=n.n()).done;){var i=e.value.name;i.length>r&&(r=i.length)}}catch(e){n.e(e)}finally{n.f()}var a,s=o(this.times);try{for(s.s();!(a=s.n()).done;){var u=a.value,l=u.end-u.start;t.push("".concat(u.name.padEnd(r)," ").concat(l,"ms\n"))}}catch(e){s.e(e)}finally{s.f()}return t.join("")}}]),e}(),t.PDFDateString=function(){function e(){v(this,e)}return y(e,null,[{key:"toDateObject",value:function(e){if(!e||!(0,a.isString)(e))return null;var t=(A=A||new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?")).exec(e);if(!t)return null;var r=parseInt(t[1],10),n=1<=(n=parseInt(t[2],10))&&n<=12?n-1:0,i=1<=(i=parseInt(t[3],10))&&i<=31?i:1,o=0<=(o=parseInt(t[4],10))&&o<=23?o:0,s=0<=(s=parseInt(t[5],10))&&s<=59?s:0,u=0<=(u=parseInt(t[6],10))&&u<=59?u:0,l=t[7]||"Z";e=0<=(e=parseInt(t[8],10))&&e<=23?e:0,t=0<=(t=parseInt(t[9],10)||0)&&t<=59?t:0;return"-"===l?(o+=e,s+=t):"+"===l&&(o-=e,s-=t),new Date(Date.UTC(r,n,i,o,s,u))}}]),e}()},function(e,t,r){"use strict";e.exports=r(3)},function(e,t,r){"use strict";(function(t){function r(e){return(r="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)}t=function(e){var t,n=Object.prototype,i=n.hasOwnProperty,a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",s=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function l(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{l({},"")}catch(n){l=function(e,t,r){return e[t]=r}}function c(e,r,n,i){var a,o,s,u;r=r&&r.prototype instanceof y?r:y,r=Object.create(r.prototype),i=new P(i||[]);return r._invoke=(a=e,o=n,s=i,u=f,function(e,r){if(u===p)throw new Error("Generator is already running");if(u===v){if("throw"===e)throw r;return T()}for(s.method=e,s.arg=r;;){var n=s.delegate;if(n){var i=function e(r,n){var i=r.iterator[n.method];if(i===t){if(n.delegate=null,"throw"===n.method){if(r.iterator.return&&(n.method="return",n.arg=t,e(r,n),"throw"===n.method))return g;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}if(i=h(i,r.iterator,n.arg),"throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,g;i=i.arg;return i?i.done?(n[r.resultName]=i.value,n.next=r.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}(n,s);if(i){if(i===g)continue;return i}}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if(u===f)throw u=v,s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);if(u=p,i=h(a,o,s),"normal"===i.type){if(u=s.done?v:d,i.arg!==g)return{value:i.arg,done:s.done}}else"throw"===i.type&&(u=v,s.method="throw",s.arg=i.arg)}}),r}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var f="suspendedStart",d="suspendedYield",p="executing",v="completed",g={};function y(){}function m(){}function b(){}var _={};_[o]=function(){return this},a=Object.getPrototypeOf,a=a&&a(a(C([]))),a&&a!==n&&i.call(a,o)&&(_=a);var w=b.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){l(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){var n;this._invoke=function(a,o){function s(){return new t((function(n,s){!function n(a,o,s,u){if(a=h(e[a],e,o),"throw"!==a.type){var l=a.arg;o=l.value;return o&&"object"===r(o)&&i.call(o,"__await")?t.resolve(o.__await).then((function(e){n("next",e,s,u)}),(function(e){n("throw",e,s,u)})):t.resolve(o).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,u)}))}u(a.arg)}(a,o,n,s)}))}return n=n?n.then(s,s):s()}}function k(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 P(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function C(e){if(e){var r=e[o];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1;r=function r(){for(;++n<e.length;)if(i.call(e,n))return r.value=e[n],r.done=!1,r;return r.value=t,r.done=!0,r};return r.next=r}}return{next:T}}function T(){return{value:t,done:!0}}return((m.prototype=w.constructor=b).constructor=m).displayName=l(b,u,"GeneratorFunction"),e.isGeneratorFunction=function(e){return e="function"==typeof e&&e.constructor,!!e&&(e===m||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,l(e,u,"GeneratorFunction")),e.prototype=Object.create(w),e},e.awrap=function(e){return{__await:e}},A(S.prototype),S.prototype[s]=function(){return this},e.AsyncIterator=S,e.async=function(t,r,n,i,a){void 0===a&&(a=Promise);var o=new S(c(t,r,n,i),a);return e.isGeneratorFunction(r)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},A(w),l(w,u,"Generator"),w[o]=function(){return this},w.toString=function(){return"[object Generator]"},e.keys=function(e){var t,r=[];for(t in e)r.push(t);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=C,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(x),!e)for(var r in this)"t"===r.charAt(0)&&i.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,i){return s.type="throw",s.arg=e,r.next=n,i&&(r.method="next",r.arg=t),!!i}for(var a=this.tryEntries.length-1;0<=a;--a){var o=this.tryEntries[a],s=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var u=i.call(o,"catchLoc"),l=i.call(o,"finallyLoc");if(u&&l){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(u){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.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&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var a=n;break}}var o=(a=a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc?null:a)?a.completion:{};return o.type=e,o.arg=t,a?(this.method="next",this.next=a.finallyLoc,g):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),g},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),g}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n,i=r.completion;return"throw"===i.type&&(n=i.arg,x(r)),n}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),g}},e}("object"===r(t)?t.exports:{});try{regeneratorRuntime=t}catch(e){Function("r","regeneratorRuntime = r")(t)}}).call(this,r(4)(e))},function(e,t,r){"use strict";e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,r){"use strict";function n(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,n.key,n)}}function i(e){return(i="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)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(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}}),t&&s(e,t)}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=l(t);return e=r?(e=l(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==i(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.arrayByteLength=_,t.arraysToBytes=function(e){var t=e.length;if(1===t&&e[0]instanceof Uint8Array)return e[0];for(var r=0,n=0;n<t;n++)r+=_(e[n]);for(var i=0,a=new Uint8Array(r),o=0;o<t;o++){var s=e[o],u=(s=s instanceof Uint8Array?s:"string"==typeof s?b(s):new Uint8Array(s)).byteLength;a.set(s,i),i+=u}return a},t.assert=p,t.bytesToString=function(e){p(null!==e&&"object"===i(e)&&void 0!==e.length,"Invalid argument for bytesToString");var t=e.length;if(t<8192)return String.fromCharCode.apply(null,e);for(var r=[],n=0;n<t;n+=8192){var a=Math.min(n+8192,t);a=e.subarray(n,a);r.push(String.fromCharCode.apply(null,a))}return r.join("")},t.createPromiseCapability=function(){var e=Object.create(null),t=!1;return Object.defineProperty(e,"settled",{get:function(){return t}}),e.promise=new Promise((function(r,n){e.resolve=function(e){t=!0,r(e)},e.reject=function(e){t=!0,n(e)}})),e},t.escapeString=function(e){return e.replace(/([\(\)\\])/g,"\\$1")},t.getModificationDate=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:new Date(Date.now());return[e.getUTCFullYear().toString(),(e.getUTCMonth()+1).toString().padStart(2,"0"),(e.getUTCDate()+1).toString().padStart(2,"0"),e.getUTCHours().toString().padStart(2,"0"),e.getUTCMinutes().toString().padStart(2,"0"),e.getUTCSeconds().toString().padStart(2,"0")].join("")},t.getVerbosityLevel=function(){return h},t.info=function(e){c.INFOS},t.isArrayBuffer=function(e){return"object"===i(e)&&null!==e&&void 0!==e.byteLength},t.isArrayEqual=function(e,t){return e.length===t.length&&e.every((function(e,r){return e===t[r]}))},t.isBool=function(e){return"boolean"==typeof e},t.isNum=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSameOrigin=function(e,t){var r;try{if(!(r=new URL(e)).origin||"null"===r.origin)return!1}catch(e){return!1}return t=new URL(t,r),r.origin===t.origin},t.createValidAbsoluteUrl=function(e,t){if(!e)return null;try{var r=t?new URL(e,t):new URL(e);if(function(e){if(!e)return!1;switch(e.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}(r))return r}catch(e){}return null},t.removeNullCharacters=function(e){return"string"==typeof e?e.replace(m,""):(f(),e)},t.setVerbosityLevel=function(e){Number.isInteger(e)&&(h=e)},t.shadow=v,t.string32=function(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,255&e)},t.stringToBytes=b,t.stringToPDFString=function(e){var t=e.length,r=[];if("þ"===e[0]&&"ÿ"===e[1])for(var n=2;n<t;n+=2)r.push(String.fromCharCode(e.charCodeAt(n)<<8|e.charCodeAt(n+1)));else if("ÿ"===e[0]&&"þ"===e[1])for(var i=2;i<t;i+=2)r.push(String.fromCharCode(e.charCodeAt(i+1)<<8|e.charCodeAt(i)));else for(var a=0;a<t;++a){var o=S[e.charCodeAt(a)];r.push(o?String.fromCharCode(o):e.charAt(a))}return r.join("")},t.stringToUTF8String=function(e){return decodeURIComponent(escape(e))},t.utf8StringToString=function(e){return unescape(encodeURIComponent(e))},t.warn=f,t.unreachable=d,t.IsEvalSupportedCached=t.IsLittleEndianCached=t.createObjectURL=t.FormatError=t.Util=t.UnknownErrorException=t.UnexpectedResponseException=t.TextRenderingMode=t.StreamType=t.PermissionFlag=t.PasswordResponses=t.PasswordException=t.MissingPDFException=t.InvalidPDFException=t.AbortException=t.CMapCompressionType=t.ImageKind=t.FontType=t.AnnotationType=t.AnnotationStateModelType=t.AnnotationReviewState=t.AnnotationReplyType=t.AnnotationMarkedState=t.AnnotationFlag=t.AnnotationFieldFlag=t.AnnotationBorderStyleType=t.UNSUPPORTED_FEATURES=t.VerbosityLevel=t.OPS=t.IDENTITY_MATRIX=t.FONT_IDENTITY_MATRIX=t.BaseException=void 0,r(6),t.IDENTITY_MATRIX=[1,0,0,1,0,0],t.FONT_IDENTITY_MATRIX=[.001,0,0,.001,0,0],t.PermissionFlag={PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048},t.TextRenderingMode={FILL:0,STROKE:1,FILL_STROKE:2,INVISIBLE:3,FILL_ADD_TO_PATH:4,STROKE_ADD_TO_PATH:5,FILL_STROKE_ADD_TO_PATH:6,ADD_TO_PATH:7,FILL_STROKE_MASK:3,ADD_TO_PATH_FLAG:4},t.ImageKind={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3},t.AnnotationType={TEXT:1,LINK:2,FREETEXT:3,LINE:4,SQUARE:5,CIRCLE:6,POLYGON:7,POLYLINE:8,HIGHLIGHT:9,UNDERLINE:10,SQUIGGLY:11,STRIKEOUT:12,STAMP:13,CARET:14,INK:15,POPUP:16,FILEATTACHMENT:17,SOUND:18,MOVIE:19,WIDGET:20,SCREEN:21,PRINTERMARK:22,TRAPNET:23,WATERMARK:24,THREED:25,REDACT:26},t.AnnotationStateModelType={MARKED:"Marked",REVIEW:"Review"},t.AnnotationMarkedState={MARKED:"Marked",UNMARKED:"Unmarked"},t.AnnotationReviewState={ACCEPTED:"Accepted",REJECTED:"Rejected",CANCELLED:"Cancelled",COMPLETED:"Completed",NONE:"None"},t.AnnotationReplyType={GROUP:"Group",REPLY:"R"},t.AnnotationFlag={INVISIBLE:1,HIDDEN:2,PRINT:4,NOZOOM:8,NOROTATE:16,NOVIEW:32,READONLY:64,LOCKED:128,TOGGLENOVIEW:256,LOCKEDCONTENTS:512},t.AnnotationFieldFlag={READONLY:1,REQUIRED:2,NOEXPORT:4,MULTILINE:4096,PASSWORD:8192,NOTOGGLETOOFF:16384,RADIO:32768,PUSHBUTTON:65536,COMBO:131072,EDIT:262144,SORT:524288,FILESELECT:1048576,MULTISELECT:2097152,DONOTSPELLCHECK:4194304,DONOTSCROLL:8388608,COMB:16777216,RICHTEXT:33554432,RADIOSINUNISON:33554432,COMMITONSELCHANGE:67108864},t.AnnotationBorderStyleType={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5},t.StreamType={UNKNOWN:"UNKNOWN",FLATE:"FLATE",LZW:"LZW",DCT:"DCT",JPX:"JPX",JBIG:"JBIG",A85:"A85",AHX:"AHX",CCF:"CCF",RLX:"RLX"},t.FontType={UNKNOWN:"UNKNOWN",TYPE1:"TYPE1",TYPE1C:"TYPE1C",CIDFONTTYPE0:"CIDFONTTYPE0",CIDFONTTYPE0C:"CIDFONTTYPE0C",TRUETYPE:"TRUETYPE",CIDFONTTYPE2:"CIDFONTTYPE2",TYPE3:"TYPE3",OPENTYPE:"OPENTYPE",TYPE0:"TYPE0",MMTYPE1:"MMTYPE1"};var c={ERRORS:0,WARNINGS:1,INFOS:5};t.VerbosityLevel=c,t.CMapCompressionType={NONE:0,BINARY:1,STREAM:2},t.OPS={dependency:1,setLineWidth:2,setLineCap:3,setLineJoin:4,setMiterLimit:5,setDash:6,setRenderingIntent:7,setFlatness:8,setGState:9,save:10,restore:11,transform:12,moveTo:13,lineTo:14,curveTo:15,curveTo2:16,curveTo3:17,closePath:18,rectangle:19,stroke:20,closeStroke:21,fill:22,eoFill:23,fillStroke:24,eoFillStroke:25,closeFillStroke:26,closeEOFillStroke:27,endPath:28,clip:29,eoClip:30,beginText:31,endText:32,setCharSpacing:33,setWordSpacing:34,setHScale:35,setLeading:36,setFont:37,setTextRenderingMode:38,setTextRise:39,moveText:40,setLeadingMoveText:41,setTextMatrix:42,nextLine:43,showText:44,showSpacedText:45,nextLineShowText:46,nextLineSetSpacingShowText:47,setCharWidth:48,setCharWidthAndBounds:49,setStrokeColorSpace:50,setFillColorSpace:51,setStrokeColor:52,setStrokeColorN:53,setFillColor:54,setFillColorN:55,setStrokeGray:56,setFillGray:57,setStrokeRGBColor:58,setFillRGBColor:59,setStrokeCMYKColor:60,setFillCMYKColor:61,shadingFill:62,beginInlineImage:63,beginImageData:64,endInlineImage:65,paintXObject:66,markPoint:67,markPointProps:68,beginMarkedContent:69,beginMarkedContentProps:70,endMarkedContent:71,beginCompat:72,endCompat:73,paintFormXObjectBegin:74,paintFormXObjectEnd:75,beginGroup:76,endGroup:77,beginAnnotations:78,endAnnotations:79,beginAnnotation:80,endAnnotation:81,paintJpegXObject:82,paintImageMaskXObject:83,paintImageMaskXObjectGroup:84,paintImageXObject:85,paintInlineImageXObject:86,paintInlineImageXObjectGroup:87,paintImageXObjectRepeat:88,paintImageMaskXObjectRepeat:89,paintSolidColorImageMask:90,constructPath:91},t.UNSUPPORTED_FEATURES={unknown:"unknown",forms:"forms",javaScript:"javaScript",smask:"smask",shadingPattern:"shadingPattern",font:"font",errorTilingPattern:"errorTilingPattern",errorExtGState:"errorExtGState",errorXObject:"errorXObject",errorFontLoadType3:"errorFontLoadType3",errorFontState:"errorFontState",errorFontMissing:"errorFontMissing",errorFontTranslate:"errorFontTranslate",errorColorSpace:"errorColorSpace",errorOperatorList:"errorOperatorList",errorFontToUnicode:"errorFontToUnicode",errorFontLoadNative:"errorFontLoadNative",errorFontGetPath:"errorFontGetPath",errorMarkedContent:"errorMarkedContent"},t.PasswordResponses={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};var h=c.WARNINGS;function f(e){c.WARNINGS}function d(e){throw new Error(e)}function p(e,t){e||d(t)}function v(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!1}),r}var g=(y.prototype=new Error,y.constructor=y);function y(e){this.constructor===y&&d("Cannot initialize BaseException."),this.message=e,this.name=this.constructor.name}t.BaseException=g,t.PasswordException=function(){o(t,g);var e=u(t);function t(r,n){return a(this,t),(r=e.call(this,r)).code=n,r}return t}(),t.UnknownErrorException=function(){o(t,g);var e=u(t);function t(r,n){return a(this,t),(r=e.call(this,r)).details=n,r}return t}(),t.InvalidPDFException=function(){o(t,g);var e=u(t);function t(){return a(this,t),e.apply(this,arguments)}return t}(),t.MissingPDFException=function(){o(t,g);var e=u(t);function t(){return a(this,t),e.apply(this,arguments)}return t}(),t.UnexpectedResponseException=function(){o(t,g);var e=u(t);function t(r,n){return a(this,t),(r=e.call(this,r)).status=n,r}return t}(),t.FormatError=function(){o(t,g);var e=u(t);function t(){return a(this,t),e.apply(this,arguments)}return t}(),t.AbortException=function(){o(t,g);var e=u(t);function t(){return a(this,t),e.apply(this,arguments)}return t}();var m=/\x00/g;function b(e){p("string"==typeof e,"Invalid argument for stringToBytes");for(var t=e.length,r=new Uint8Array(t),n=0;n<t;++n)r[n]=255&e.charCodeAt(n);return r}function _(e){return void 0!==e.length?e.length:(p(void 0!==e.byteLength,"arrayByteLength - invalid argument."),e.byteLength)}t.IsLittleEndianCached={get value(){return v(this,"value",((e=new Uint8Array(4))[0]=1)===new Uint32Array(e.buffer,0,1)[0]);var e}},t.IsEvalSupportedCached={get value(){return v(this,"value",function(){try{return new Function(""),!0}catch(e){return!1}}())}};var w=["rgb(",0,",",0,",",0,")"];t.Util=function(){function e(){a(this,e)}var t,r,i;return t=e,i=[{key:"makeCssRgb",value:function(e,t,r){return w[1]=e,w[3]=t,w[5]=r,w.join("")}},{key:"transform",value:function(e,t){return[e[0]*t[0]+e[2]*t[1],e[1]*t[0]+e[3]*t[1],e[0]*t[2]+e[2]*t[3],e[1]*t[2]+e[3]*t[3],e[0]*t[4]+e[2]*t[5]+e[4],e[1]*t[4]+e[3]*t[5]+e[5]]}},{key:"applyTransform",value:function(e,t){return[e[0]*t[0]+e[1]*t[2]+t[4],e[0]*t[1]+e[1]*t[3]+t[5]]}},{key:"applyInverseTransform",value:function(e,t){var r=t[0]*t[3]-t[1]*t[2];return[(e[0]*t[3]-e[1]*t[2]+t[2]*t[5]-t[4]*t[3])/r,(-e[0]*t[1]+e[1]*t[0]+t[4]*t[1]-t[5]*t[0])/r]}},{key:"getAxialAlignedBoundingBox",value:function(t,r){var n=e.applyTransform(t,r),i=e.applyTransform(t.slice(2,4),r),a=e.applyTransform([t[0],t[3]],r);r=e.applyTransform([t[2],t[1]],r);return[Math.min(n[0],i[0],a[0],r[0]),Math.min(n[1],i[1],a[1],r[1]),Math.max(n[0],i[0],a[0],r[0]),Math.max(n[1],i[1],a[1],r[1])]}},{key:"inverseTransform",value:function(e){var t=e[0]*e[3]-e[1]*e[2];return[e[3]/t,-e[1]/t,-e[2]/t,e[0]/t,(e[2]*e[5]-e[4]*e[3])/t,(e[4]*e[1]-e[5]*e[0])/t]}},{key:"apply3dTransform",value:function(e,t){return[e[0]*t[0]+e[1]*t[1]+e[2]*t[2],e[3]*t[0]+e[4]*t[1]+e[5]*t[2],e[6]*t[0]+e[7]*t[1]+e[8]*t[2]]}},{key:"singularValueDecompose2dScale",value:function(e){var t=[e[0],e[2],e[1],e[3]],r=e[0]*t[0]+e[1]*t[2],n=e[0]*t[1]+e[1]*t[3],i=e[2]*t[0]+e[3]*t[2];e=e[2]*t[1]+e[3]*t[3],t=(r+e)/2,i=Math.sqrt((r+e)*(r+e)-4*(r*e-i*n))/2,n=t-i||1;return[Math.sqrt(t+i||1),Math.sqrt(n)]}},{key:"normalizeRect",value:function(e){var t=e.slice(0);return e[0]>e[2]&&(t[0]=e[2],t[2]=e[0]),e[1]>e[3]&&(t[1]=e[3],t[3]=e[1]),t}},{key:"intersect",value:function(t,r){function n(e,t){return e-t}var i=[t[0],t[2],r[0],r[2]].sort(n),a=[t[1],t[3],r[1],r[3]].sort(n),o=[];return t=e.normalizeRect(t),r=e.normalizeRect(r),i[0]===t[0]&&i[1]===r[0]||i[0]===r[0]&&i[1]===t[0]?(o[0]=i[1],o[2]=i[2],a[0]===t[1]&&a[1]===r[1]||a[0]===r[1]&&a[1]===t[1]?(o[1]=a[1],o[3]=a[2],o):null):null}}],(r=null)&&n(t.prototype,r),i&&n(t,i),e}();var A,S=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,728,711,710,729,733,731,730,732,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8226,8224,8225,8230,8212,8211,402,8260,8249,8250,8722,8240,8222,8220,8221,8216,8217,8218,8482,64257,64258,321,338,352,376,381,305,322,339,353,382,0,8364];A="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r=function(e,t){if(!(2<arguments.length&&void 0!==arguments[2]&&arguments[2])&&URL.createObjectURL){var r=new Blob([e],{type:t});return URL.createObjectURL(r)}for(var n="data:".concat(t,";base64,"),i=0,a=e.length;i<a;i+=3){var o=255&e[i],s=255&e[i+1],u=255&e[i+2];n+=A[o>>2]+A[(3&o)<<4|s>>4]+A[i+1<a?(15&s)<<2|u>>6:64]+A[i+2<a?63&u:64]}return n};t.createObjectURL=r},function(e,t,r){"use strict";var n,i,a,o,s,u,l,c=r(7);function h(e){return(h="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)}"undefined"!=typeof globalThis&&globalThis._pdfjsCompatibilityChecked||("undefined"!=typeof globalThis&&globalThis.Math===Math||(globalThis=r(8)),globalThis._pdfjsCompatibilityChecked=!0,n="object"===("undefined"==typeof window?"undefined":h(window))&&"object"===("undefined"==typeof document?"undefined":h(document)),s="undefined"!=typeof navigator&&navigator.userAgent||"",i=/Trident/.test(s),!globalThis.btoa&&c.isNodeJS&&(globalThis.btoa=function(e){return Buffer.from(e,"binary").toString("base64")}),!globalThis.atob&&c.isNodeJS&&(globalThis.atob=function(e){return Buffer.from(e,"base64").toString("binary")}),n&&void 0===Element.prototype.remove&&(Element.prototype.remove=function(){this.parentNode&&this.parentNode.removeChild(this)}),n&&!c.isNodeJS&&((s=document.createElement("div")).classList.add("testOne","testTwo"),!0===s.classList.contains("testOne")&&!0===s.classList.contains("testTwo")||(u=DOMTokenList.prototype.add,l=DOMTokenList.prototype.remove,DOMTokenList.prototype.add=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];for(var n=0,i=t;n<i.length;n++){var a=i[n];u.call(this,a)}},DOMTokenList.prototype.remove=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];for(var n=0,i=t;n<i.length;n++){var a=i[n];l.call(this,a)}})),n&&!c.isNodeJS&&!1!==document.createElement("div").classList.toggle("test",0)&&(DOMTokenList.prototype.toggle=function(e){var t=1<arguments.length?!!arguments[1]:!this.contains(e);return this[t?"add":"remove"](e),t}),n&&i&&(a=window.history.pushState,o=window.history.replaceState,window.history.pushState=function(e,t,r){a.apply(this,void 0===r?[e,t]:[e,t,r])},window.history.replaceState=function(e,t,r){o.apply(this,void 0===r?[e,t]:[e,t,r])}),String.prototype.startsWith||r(53),String.prototype.endsWith||r(64),String.prototype.includes||r(66),Array.prototype.includes||r(68),Array.from||r(76),Object.assign||r(98),Object.fromEntries||r(101),Math.log2||(Math.log2=r(105)),Number.isNaN||(Number.isNaN=r(107)),Number.isInteger||(Number.isInteger=r(109)),Uint8Array.prototype.slice||r(112),globalThis.Promise&&globalThis.Promise.allSettled||(globalThis.Promise=r(117)),globalThis.URL=r(138),function(){var e=!1;if("undefined"!=typeof ReadableStream)try{new ReadableStream({start:function(e){e.close()}}),e=!0}catch(e){}e||(globalThis.ReadableStream=r(145).ReadableStream)}(),globalThis.Map&&globalThis.Map.prototype.entries||(globalThis.Map=r(146)),globalThis.Set&&globalThis.Set.prototype.entries||(globalThis.Set=r(153)),globalThis.WeakMap||(globalThis.WeakMap=r(155)),globalThis.WeakSet||(globalThis.WeakSet=r(161)),String.prototype.codePointAt||r(163),String.fromCodePoint||(String.fromCodePoint=r(165)),globalThis.Symbol||r(167),String.prototype.padStart||r(190),String.prototype.padEnd||r(195),Object.values||(Object.values=r(197)),Object.entries||(Object.entries=r(200)))},function(e,t,r){"use strict";function n(e){return(n="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)}Object.defineProperty(t,"__esModule",{value:!0});var i=!("object"!==((t.isNodeJS=void 0)===process?"undefined":n(process))||process+""!="[object process]"||process.versions.nw||process.versions.electron&&process.type&&"browser"!==process.type);t.isNodeJS=i},function(e,t,r){r(9),e.exports=r(11)},function(e,t,r){r(10)({global:!0},{globalThis:r(11)})},function(e,t,r){var n=r(11),i=r(12).f,a=r(26),o=r(29),s=r(30),u=r(40),l=r(52);e.exports=function(e,t){var r,c,h,f=e.target,d=e.global,p=e.stat,v=d?n:p?n[f]||s(f,{}):(n[f]||{}).prototype;if(v)for(r in t){if(c=t[r],h=e.noTargetGet?(h=i(v,r))&&h.value:v[r],!l(d?r:f+(p?".":"#")+r,e.forced)&&void 0!==h){if(typeof c==typeof h)continue;u(c,h)}(e.sham||h&&h.sham)&&a(c,"sham",!0),o(v,r,c,e)}}},function(e,t){function r(e){return e&&e.Math==Math&&e}e.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof global&&global)||Function("return this")()},function(e,t,r){var n=r(13),i=r(15),a=r(16),o=r(17),s=r(21),u=r(23),l=r(24),c=Object.getOwnPropertyDescriptor;t.f=n?c:function(e,t){if(e=o(e),t=s(t,!0),l)try{return c(e,t)}catch(e){}if(u(e,t))return a(!i.f.call(e,t),e[t])}},function(e,t,r){r=r(14),e.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,r){"use strict";var n={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,a=i&&!n.call({1:2},1);t.f=a?function(e){return e=i(this,e),!!e&&e.enumerable}:n},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,r){var n=r(18),i=r(20);e.exports=function(e){return n(i(e))}},function(e,t,r){var n=r(14),i=r(19),a="".split;e.exports=n((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==i(e)?a.call(e,""):Object(e)}:Object},function(e,t){var r={}.toString;e.exports=function(e){return r.call(e).slice(8,-1)}},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,r){var n=r(22);e.exports=function(e,t){if(!n(e))return e;var r,i;if(t&&"function"==typeof(r=e.toString)&&!n(i=r.call(e)))return i;if("function"==typeof(r=e.valueOf)&&!n(i=r.call(e)))return i;if(!t&&"function"==typeof(r=e.toString)&&!n(i=r.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t){var r={}.hasOwnProperty;e.exports=function(e,t){return r.call(e,t)}},function(e,t,r){var n=r(13),i=r(14),a=r(25);e.exports=!n&&!i((function(){return 7!=Object.defineProperty(a("div"),"a",{get:function(){return 7}}).a}))},function(e,t,r){var n=r(11),i=(r=r(22),n.document),a=r(i)&&r(i.createElement);e.exports=function(e){return a?i.createElement(e):{}}},function(e,t,r){var n=r(13),i=r(27),a=r(16);e.exports=n?function(e,t,r){return i.f(e,t,a(1,r))}:function(e,t,r){return e[t]=r,e}},function(e,t,r){var n=r(13),i=r(24),a=r(28),o=r(21),s=Object.defineProperty;t.f=n?s:function(e,t,r){if(a(e),t=o(t,!0),a(r),i)try{return s(e,t,r)}catch(e){}if("get"in r||"set"in r)throw TypeError("Accessors not supported");return"value"in r&&(e[t]=r.value),e}},function(e,t,r){var n=r(22);e.exports=function(e){if(!n(e))throw TypeError(String(e)+" is not an object");return e}},function(e,t,r){var n=r(11),i=r(26),a=r(23),o=r(30),s=r(31),u=(r=r(33),r.get),l=r.enforce,c=String(String).split("String");(e.exports=function(e,t,r,s){var u=!!s&&!!s.unsafe,h=!!s&&!!s.enumerable;s=!!s&&!!s.noTargetGet;"function"==typeof r&&("string"!=typeof t||a(r,"name")||i(r,"name",t),l(r).source=c.join("string"==typeof t?t:"")),e!==n?(u?!s&&e[t]&&(h=!0):delete e[t],h?e[t]=r:i(e,t,r)):h?e[t]=r:o(t,r)})(Function.prototype,"toString",(function(){return"function"==typeof this&&u(this).source||s(this)}))},function(e,t,r){var n=r(11),i=r(26);e.exports=function(t,r){try{i(n,t,r)}catch(e){n[t]=r}return r}},function(e,t,r){r=r(32);var n=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(e){return n.call(e)}),e.exports=r.inspectSource},function(e,t,r){var n=r(11),i=r(30);r="__core-js_shared__",r=n[r]||i(r,{});e.exports=r},function(e,t,r){var n,i,a,o,s,u,l,c,h=r(34),f=r(11),d=r(22),p=r(26),v=r(23),g=r(35);r=r(39),f=f.WeakMap;l=h?(n=new f,i=n.get,a=n.has,o=n.set,s=function(e,t){return o.call(n,e,t),t},u=function(e){return i.call(n,e)||{}},function(e){return a.call(n,e)}):(r[c=g("state")]=!0,s=function(e,t){return p(e,c,t),t},u=function(e){return v(e,c)?e[c]:{}},function(e){return v(e,c)}),e.exports={set:s,get:u,has:l,enforce:function(e){return l(e)?u(e):s(e,{})},getterFor:function(e){return function(t){var r;if(!d(t)||(r=u(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return r}}}},function(e,t,r){var n=r(11);r=r(31),n=n.WeakMap;e.exports="function"==typeof n&&/native code/.test(r(n))},function(e,t,r){var n=r(36),i=r(38),a=n("keys");e.exports=function(e){return a[e]||(a[e]=i(e))}},function(e,t,r){var n=r(37),i=r(32);(e.exports=function(e,t){return i[e]||(i[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.6.5",mode:n?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},function(e,t){e.exports=!1},function(e,t){var r=0,n=Math.random();e.exports=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++r+n).toString(36)}},function(e,t){e.exports={}},function(e,t,r){var n=r(23),i=r(41),a=r(12),o=r(27);e.exports=function(e,t){for(var r=i(t),s=o.f,u=a.f,l=0;l<r.length;l++){var c=r[l];n(e,c)||s(e,c,u(t,c))}}},function(e,t,r){var n=r(42),i=r(44),a=r(51),o=r(28);e.exports=n("Reflect","ownKeys")||function(e){var t=i.f(o(e)),r=a.f;return r?t.concat(r(e)):t}},function(e,t,r){function n(e){return"function"==typeof e?e:void 0}var i=r(43),a=r(11);e.exports=function(e,t){return arguments.length<2?n(i[e])||n(a[e]):i[e]&&i[e][t]||a[e]&&a[e][t]}},function(e,t,r){r=r(11),e.exports=r},function(e,t,r){var n=r(45),i=r(50).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return n(e,i)}},function(e,t,r){var n=r(23),i=r(17),a=r(46).indexOf,o=r(39);e.exports=function(e,t){var r,s=i(e),u=0,l=[];for(r in s)!n(o,r)&&n(s,r)&&l.push(r);for(;t.length>u;)n(s,r=t[u++])&&(~a(l,r)||l.push(r));return l}},function(e,t,r){var n=r(17),i=r(47),a=r(49);r=function(e){return function(t,r,o){var s,u=n(t),l=i(u.length),c=a(o,l);if(e&&r!=r){for(;c<l;)if((s=u[c++])!=s)return!0}else for(;c<l;c++)if((e||c in u)&&u[c]===r)return e||c||0;return!e&&-1}};e.exports={includes:r(!0),indexOf:r(!1)}},function(e,t,r){var n=r(48),i=Math.min;e.exports=function(e){return 0<e?i(n(e),9007199254740991):0}},function(e,t){var r=Math.ceil,n=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(0<e?n:r)(e)}},function(e,t,r){var n=r(48),i=Math.max,a=Math.min;e.exports=function(e,t){return e=n(e),e<0?i(e+t,0):a(e,t)}},function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,r){var n=r(14),i=/#|\.prototype\./,a=(r=function(e,t){return e=o[a(e)],e==u||e!=s&&("function"==typeof t?n(t):!!t)},r.normalize=function(e){return String(e).replace(i,".").toLowerCase()}),o=r.data={},s=r.NATIVE="N",u=r.POLYFILL="P";e.exports=r},function(e,t,r){r(54),r=r(61),e.exports=r("String","startsWith")},function(e,t,r){"use strict";var n=r(10),i=r(12).f,a=r(47),o=r(55),s=r(20),u=r(60),l=(r=r(37),"".startsWith),c=Math.min;u=u("startsWith");n({target:"String",proto:!0,forced:!(!r&&!u&&(i=i(String.prototype,"startsWith"))&&!i.writable)&&!u},{startsWith:function(e){var t=String(s(this));o(e);var r=a(c(1<arguments.length?arguments[1]:void 0,t.length));e=String(e);return l?l.call(t,e,r):t.slice(r,r+e.length)===e}})},function(e,t,r){var n=r(56);e.exports=function(e){if(n(e))throw TypeError("The method doesn't accept regular expressions");return e}},function(e,t,r){var n=r(22),i=r(19),a=r(57)("match");e.exports=function(e){var t;return n(e)&&(void 0!==(t=e[a])?!!t:"RegExp"==i(e))}},function(e,t,r){var n=r(11),i=r(36),a=r(23),o=r(38),s=r(58),u=(r=r(59),i("wks")),l=n.Symbol,c=r?l:l&&l.withoutSetter||o;e.exports=function(e){return a(u,e)||(s&&a(l,e)?u[e]=l[e]:u[e]=c("Symbol."+e)),u[e]}},function(e,t,r){r=r(14),e.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},function(e,t,r){r=r(58),e.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},function(e,t,r){var n=r(57)("match");e.exports=function(t){var r=/./;try{"/./"[t](r)}catch(e){try{return r[n]=!1,"/./"[t](r)}catch(e){}}return!1}},function(e,t,r){var n=r(11),i=r(62),a=Function.call;e.exports=function(e,t,r){return i(a,n[e].prototype[t],r)}},function(e,t,r){var n=r(63);e.exports=function(e,t,r){if(n(e),void 0===t)return e;switch(r){case 0:return function(){return e.call(t)};case 1:return function(r){return e.call(t,r)};case 2:return function(r,n){return e.call(t,r,n)};case 3:return function(r,n,i){return e.call(t,r,n,i)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function");return e}},function(e,t,r){r(65),r=r(61),e.exports=r("String","endsWith")},function(e,t,r){"use strict";var n=r(10),i=r(12).f,a=r(47),o=r(55),s=r(20),u=r(60),l=(r=r(37),"".endsWith),c=Math.min;u=u("endsWith");n({target:"String",proto:!0,forced:!(!r&&!u&&(i=i(String.prototype,"endsWith"))&&!i.writable)&&!u},{endsWith:function(e){var t=String(s(this));o(e);var r=1<arguments.length?arguments[1]:void 0,n=a(t.length);n=void 0===r?n:c(a(r),n),e=String(e);return l?l.call(t,e,n):t.slice(n-e.length,n)===e}})},function(e,t,r){r(67),r=r(61),e.exports=r("String","includes")},function(e,t,r){"use strict";var n=r(10),i=r(55),a=r(20);n({target:"String",proto:!0,forced:!r(60)("includes")},{includes:function(e){return!!~String(a(this)).indexOf(i(e),1<arguments.length?arguments[1]:void 0)}})},function(e,t,r){r(69),r=r(61),e.exports=r("Array","includes")},function(e,t,r){"use strict";var n=r(10),i=r(46).includes,a=r(70);n({target:"Array",proto:!0,forced:!r(75)("indexOf",{ACCESSORS:!0,1:0})},{includes:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}}),a("includes")},function(e,t,r){var n=r(57),i=r(71),a=(r=r(27),n("unscopables")),o=Array.prototype;null==o[a]&&r.f(o,a,{configurable:!0,value:i(null)}),e.exports=function(e){o[a][e]=!0}},function(e,t,r){function n(){}function i(e){return"<script>"+e+"</"+d+">"}var a,o=r(28),s=r(72),u=r(50),l=r(39),c=r(74),h=r(25),f=(r=r(35),"prototype"),d="script",p=r("IE_PROTO"),v=function(){try{a=document.domain&&new ActiveXObject("htmlfile")}catch(e){}var e;v=a?function(e){e.write(i("")),e.close();var t=e.parentWindow.Object;return e=null,t}(a):((e=h("iframe")).style.display="none",c.appendChild(e),e.src=String("javascript:"),(e=e.contentWindow.document).open(),e.write(i("document.F=Object")),e.close(),e.F);for(var t=u.length;t--;)delete v[f][u[t]];return v()};l[p]=!0,e.exports=Object.create||function(e,t){var r;return null!==e?(n[f]=o(e),r=new n,n[f]=null,r[p]=e):r=v(),void 0===t?r:s(r,t)}},function(e,t,r){var n=r(13),i=r(27),a=r(28),o=r(73);e.exports=n?Object.defineProperties:function(e,t){a(e);for(var r,n=o(t),s=n.length,u=0;u<s;)i.f(e,r=n[u++],t[r]);return e}},function(e,t,r){var n=r(45),i=r(50);e.exports=Object.keys||function(e){return n(e,i)}},function(e,t,r){r=r(42),e.exports=r("document","documentElement")},function(e,t,r){function n(e){throw e}var i=r(13),a=r(14),o=r(23),s=Object.defineProperty,u={};e.exports=function(e,t){if(o(u,e))return u[e];var r=[][e],l=!!o(t=t||{},"ACCESSORS")&&t.ACCESSORS,c=o(t,0)?t[0]:n,h=o(t,1)?t[1]:void 0;return u[e]=!!r&&!a((function(){if(l&&!i)return!0;var e={length:-1};l?s(e,1,{enumerable:!0,get:n}):e[1]=1,r.call(e,c,h)}))}},function(e,t,r){r(77),r(89),r=r(43),e.exports=r.Array.from},function(e,t,r){"use strict";var n=r(78).charAt,i=r(33),a=(r=r(79),"String Iterator"),o=i.set,s=i.getterFor(a);r(String,"String",(function(e){o(this,{type:a,string:String(e),index:0})}),(function(){var e=s(this),t=e.string,r=e.index;return r>=t.length?{value:void 0,done:!0}:(r=n(t,r),e.index+=r.length,{value:r,done:!1})}))},function(e,t,r){var n=r(48),i=r(20);r=function(e){return function(t,r){var a,o=String(i(t)),s=n(r);t=o.length;return s<0||t<=s?e?"":void 0:(r=o.charCodeAt(s))<55296||56319<r||s+1===t||(a=o.charCodeAt(s+1))<56320||57343<a?e?o.charAt(s):r:e?o.slice(s,s+2):a-56320+(r-55296<<10)+65536}};e.exports={codeAt:r(!1),charAt:r(!0)}},function(e,t,r){"use strict";function n(){return this}var i=r(10),a=r(80),o=r(82),s=r(87),u=r(85),l=r(26),c=r(29),h=r(57),f=r(37),d=r(86),p=(r=r(81),r.IteratorPrototype),v=r.BUGGY_SAFARI_ITERATORS,g=h("iterator"),y="values",m="entries";e.exports=function(e,t,r,h,b,_,w){function A(e){if(e===b&&R)return R;if(!v&&e in C)return C[e];switch(e){case"keys":case y:case m:return function(){return new r(this,e)}}return function(){return new r(this)}}a(r,t,h);var S,k,x=t+" Iterator",P=!1,C=e.prototype,T=C[g]||C["@@iterator"]||b&&C[b],R=!v&&T||A(b);h="Array"==t&&C.entries||T;if(h&&(e=o(h.call(new e)),p!==Object.prototype&&e.next&&(f||o(e)===p||(s?s(e,p):"function"!=typeof e[g]&&l(e,g,n)),u(e,x,!0,!0),f&&(d[x]=n))),b==y&&T&&T.name!==y&&(P=!0,R=function(){return T.call(this)}),f&&!w||C[g]===R||l(C,g,R),d[t]=R,b)if(S={values:A(y),keys:_?R:A("keys"),entries:A(m)},w)for(k in S)!v&&!P&&k in C||c(C,k,S[k]);else i({target:t,proto:!0,forced:v||P},S);return S}},function(e,t,r){"use strict";function n(){return this}var i=r(81).IteratorPrototype,a=r(71),o=r(16),s=r(85),u=r(86);e.exports=function(e,t,r){return t+=" Iterator",e.prototype=a(i,{next:o(1,r)}),s(e,t,!1,!0),u[t]=n,e}},function(e,t,r){"use strict";var n,i=r(82),a=r(26),o=r(23),s=r(57),u=r(37),l=s("iterator");r=!1;[].keys&&("next"in(s=[].keys())?(s=i(i(s)))!==Object.prototype&&(n=s):r=!0),null==n&&(n={}),u||o(n,l)||a(n,l,(function(){return this})),e.exports={IteratorPrototype:n,BUGGY_SAFARI_ITERATORS:r}},function(e,t,r){var n=r(23),i=r(83),a=r(35),o=(r=r(84),a("IE_PROTO")),s=Object.prototype;e.exports=r?Object.getPrototypeOf:function(e){return e=i(e),n(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,r){var n=r(20);e.exports=function(e){return Object(n(e))}},function(e,t,r){r=r(14),e.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},function(e,t,r){var n=r(27).f,i=r(23),a=r(57)("toStringTag");e.exports=function(e,t,r){e&&!i(e=r?e:e.prototype,a)&&n(e,a,{configurable:!0,value:t})}},function(e,t){e.exports={}},function(e,t,r){var n=r(28),i=r(88);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(r,[]),t=r instanceof Array}catch(r){}return function(r,a){return n(r),i(a),t?e.call(r,a):r.__proto__=a,r}}():void 0)},function(e,t,r){var n=r(22);e.exports=function(e){if(!n(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},function(e,t,r){var n=r(10),i=r(90);n({target:"Array",stat:!0,forced:!r(97)((function(e){Array.from(e)}))},{from:i})},function(e,t,r){"use strict";var n=r(62),i=r(83),a=r(91),o=r(92),s=r(47),u=r(93),l=r(94);e.exports=function(e){var t,r,c,h,f,d,p=i(e),v="function"==typeof this?this:Array,g=arguments.length,y=1<g?arguments[1]:void 0,m=void 0!==y,b=(e=l(p),0);if(m&&(y=n(y,2<g?arguments[2]:void 0,2)),null==e||v==Array&&o(e))for(r=new v(t=s(p.length));b<t;b++)d=m?y(p[b],b):p[b],u(r,b,d);else for(f=(h=e.call(p)).next,r=new v;!(c=f.call(h)).done;b++)d=m?a(h,y,[c.value,b],!0):c.value,u(r,b,d);return r.length=b,r}},function(e,t,r){var n=r(28);e.exports=function(e,t,r,i){try{return i?t(n(r)[0],r[1]):t(r)}catch(t){throw r=e.return,void 0!==r&&n(r.call(e)),t}}},function(e,t,r){var n=r(57),i=r(86),a=n("iterator"),o=Array.prototype;e.exports=function(e){return void 0!==e&&(i.Array===e||o[a]===e)}},function(e,t,r){"use strict";var n=r(21),i=r(27),a=r(16);e.exports=function(e,t,r){t=n(t),t in e?i.f(e,t,a(0,r)):e[t]=r}},function(e,t,r){var n=r(95),i=r(86),a=r(57)("iterator");e.exports=function(e){if(null!=e)return e[a]||e["@@iterator"]||i[n(e)]}},function(e,t,r){var n=r(96),i=r(19),a=r(57)("toStringTag"),o="Arguments"==i(function(){return arguments}());e.exports=n?i:function(e){var t;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(e=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),a))?e:o?i(t):"Object"==(e=i(t))&&"function"==typeof t.callee?"Arguments":e}},function(e,t,r){var n={};n[r(57)("toStringTag")]="z",e.exports="[object z]"===String(n)},function(e,t,r){var n=r(57)("iterator"),i=!1;try{var a=0,o={next:function(){return{done:!!a++}},return:function(){i=!0}};o[n]=function(){return this},Array.from(o,(function(){throw 2}))}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var r=!1;try{var a={};a[n]=function(){return{next:function(){return{done:r=!0}}}},e(a)}catch(e){}return r}},function(e,t,r){r(99),r=r(43),e.exports=r.Object.assign},function(e,t,r){var n=r(10);r=r(100);n({target:"Object",stat:!0,forced:Object.assign!==r},{assign:r})},function(e,t,r){"use strict";var n=r(13),i=r(14),a=r(73),o=r(51),s=r(15),u=r(83),l=r(18),c=Object.assign,h=Object.defineProperty;e.exports=!c||i((function(){if(n&&1!==c({b:1},c(h({},"a",{enumerable:!0,get:function(){h(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},r=Symbol(),i="abcdefghijklmnopqrst";return e[r]=7,i.split("").forEach((function(e){t[e]=e})),7!=c({},e)[r]||a(c({},t)).join("")!=i}))?function(e,t){for(var r=u(e),i=arguments.length,c=1,h=o.f,f=s.f;c<i;)for(var d,p=l(arguments[c++]),v=h?a(p).concat(h(p)):a(p),g=v.length,y=0;y<g;)d=v[y++],n&&!f.call(p,d)||(r[d]=p[d]);return r}:c},function(e,t,r){r(102),r(103),r=r(43),e.exports=r.Object.fromEntries},function(e,t,r){"use strict";var n=r(17),i=r(70),a=r(86),o=r(33),s=(r=r(79),"Array Iterator"),u=o.set,l=o.getterFor(s);e.exports=r(Array,"Array",(function(e,t){u(this,{type:s,target:n(e),index:0,kind:t})}),(function(){var e=l(this),t=e.target,r=e.kind,n=e.index++;return!t||n>=t.length?{value:e.target=void 0,done:!0}:"keys"==r?{value:n,done:!1}:"values"==r?{value:t[n],done:!1}:{value:[n,t[n]],done:!1}}),"values"),a.Arguments=a.Array,i("keys"),i("values"),i("entries")},function(e,t,r){var n=r(10),i=r(104),a=r(93);n({target:"Object",stat:!0},{fromEntries:function(e){var t={};return i(e,(function(e,r){a(t,e,r)}),void 0,!0),t}})},function(e,t,r){function n(e,t){this.stopped=e,this.result=t}var i=r(28),a=r(92),o=r(47),s=r(62),u=r(94),l=r(91);(e.exports=function(e,t,r,c,h){var f,d,p,v,g,y,m=s(t,r,c?2:1);if(h)f=e;else{if("function"!=typeof(h=u(e)))throw TypeError("Target is not iterable");if(a(h)){for(d=0,p=o(e.length);d<p;d++)if((v=c?m(i(y=e[d])[0],y[1]):m(e[d]))&&v instanceof n)return v;return new n(!1)}f=h.call(e)}for(g=f.next;!(y=g.call(f)).done;)if("object"==typeof(v=l(f,m,y.value,c))&&v&&v instanceof n)return v;return new n(!1)}).stop=function(e){return new n(!0,e)}},function(e,t,r){r(106),r=r(43),e.exports=r.Math.log2},function(e,t,r){r=r(10);var n=Math.log,i=Math.LN2;r({target:"Math",stat:!0},{log2:function(e){return n(e)/i}})},function(e,t,r){r(108),r=r(43),e.exports=r.Number.isNaN},function(e,t,r){r(10)({target:"Number",stat:!0},{isNaN:function(e){return e!=e}})},function(e,t,r){r(110),r=r(43),e.exports=r.Number.isInteger},function(e,t,r){r(10)({target:"Number",stat:!0},{isInteger:r(111)})},function(e,t,r){var n=r(22),i=Math.floor;e.exports=function(e){return!n(e)&&isFinite(e)&&i(e)===e}},function(e,t,r){r(113)},function(e,t,r){"use strict";var n=r(114),i=r(116),a=(r=r(14),n.aTypedArray),o=n.aTypedArrayConstructor,s=(n=n.exportTypedArrayMethod,[].slice);n("slice",(function(e,t){for(var r=s.call(a(this),e,t),n=(t=i(this,this.constructor),0),u=r.length,l=new(o(t))(u);n<u;)l[n]=r[n++];return l}),r((function(){new Int8Array(1).slice()})))},function(e,t,r){"use strict";function n(e){return u(e)&&l(P,c(e))}var i,a=r(115),o=r(13),s=r(11),u=r(22),l=r(23),c=r(95),h=r(26),f=r(29),d=r(27).f,p=r(82),v=r(87),g=r(57),y=r(38),m=s.Int8Array,b=m&&m.prototype,_=s.Uint8ClampedArray,w=(r=_&&_.prototype,m&&p(m)),A=b&&p(b),S=(_=Object.prototype,_.isPrototypeOf),k=(g=g("toStringTag"),y("TYPED_ARRAY_TAG")),x=a&&!!v&&"Opera"!==c(s.opera),P=(a=!1,{Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8});for(i in P)s[i]||(x=!1);if((!x||"function"!=typeof w||w===Function.prototype)&&(w=function(){throw TypeError("Incorrect invocation")},x))for(i in P)s[i]&&v(s[i],w);if((!x||!A||A===_)&&(A=w.prototype,x))for(i in P)s[i]&&v(s[i].prototype,A);if(x&&p(r)!==A&&v(r,A),o&&!l(A,g))for(i in a=!0,d(A,g,{get:function(){return u(this)?this[k]:void 0}}),P)s[i]&&h(s[i],k,i);e.exports={NATIVE_ARRAY_BUFFER_VIEWS:x,TYPED_ARRAY_TAG:a&&k,aTypedArray:function(e){if(n(e))return e;throw TypeError("Target is not a typed array")},aTypedArrayConstructor:function(e){if(v){if(S.call(w,e))return e}else for(var t in P)if(l(P,i)&&(t=s[t],t&&(e===t||S.call(t,e))))return e;throw TypeError("Target is not a typed array constructor")},exportTypedArrayMethod:function(e,t,r){if(o){if(r)for(var n in P)n=s[n],n&&l(n.prototype,e)&&delete n.prototype[e];A[e]&&!r||f(A,e,!r&&x&&b[e]||t)}},exportTypedArrayStaticMethod:function(e,t,r){var n,i;if(o){if(v){if(r)for(n in P)(i=s[n])&&l(i,e)&&delete i[e];if(w[e]&&!r)return;try{return f(w,e,!r&&x&&m[e]||t)}catch(e){}}for(n in P)!(i=s[n])||i[e]&&!r||f(i,e,t)}},isView:function(e){return e=c(e),"DataView"===e||l(P,e)},isTypedArray:n,TypedArray:w,TypedArrayPrototype:A}},function(e,t){e.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},function(e,t,r){var n=r(28),i=r(63),a=r(57)("species");e.exports=function(e,t){var r;e=n(e).constructor;return void 0===e||null==(r=n(e)[a])?t:i(r)}},function(e,t,r){r(118),r(77),r(120),r(122),r(136),r(137),r=r(43),e.exports=r.Promise},function(e,t,r){var n=r(96),i=r(29);r=r(119);n||i(Object.prototype,"toString",r,{unsafe:!0})},function(e,t,r){"use strict";var n=r(96),i=r(95);e.exports=n?{}.toString:function(){return"[object "+i(this)+"]"}},function(e,t,r){var n,i=r(11),a=r(121),o=r(102),s=r(26),u=(r=r(57),r("iterator")),l=r("toStringTag"),c=o.values;for(n in a){var h=i[n],f=h&&h.prototype;if(f){if(f[u]!==c)try{s(f,u,c)}catch(e){f[u]=c}if(f[l]||s(f,l,n),a[n])for(var d in o)if(f[d]!==o[d])try{s(f,d,o[d])}catch(e){f[d]=o[d]}}}},function(e,t){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(e,t,r){"use strict";function n(e){var t;return!(!w(e)||"function"!=typeof(t=e.then))&&t}function i(e,t,r){var i;t.notified||(t.notified=!0,i=t.reactions,E((function(){for(var a=t.value,o=1==t.state,s=0;i.length>s;){var u,l,c,h=i[s++],f=o?h.ok:h.fail,d=h.resolve,p=h.reject,v=h.domain;try{f?(o||(2===t.rejection&&re(e,t),t.rejection=1),!0===f?u=a:(v&&v.enter(),u=f(a),v&&(v.exit(),c=!0)),u===h.promise?p(H("Promise-chain cycle")):(l=n(u))?l.call(u,d,p):d(u)):p(a)}catch(a){v&&!c&&v.exit(),p(a)}}t.reactions=[],t.notified=!1,r&&!t.rejection&&ee(e,t)})))}function a(e,t,r){var n;$?((n=G.createEvent("Event")).promise=t,n.reason=r,n.initEvent(e,!1,!0),p.dispatchEvent(n)):n={promise:t,reason:r},(t=p["on"+e])?t(n):e===Z&&L("Unhandled promise rejection",r)}function o(e,t,r,n){return function(i){e(t,r,i,n)}}function s(e,t,r,n){t.done||(t.done=!0,(t=n||t).value=r,t.state=2,i(e,t,!0))}var u,l,c,h,f=r(10),d=r(37),p=r(11),v=r(42),g=r(123),y=r(29),m=r(124),b=r(85),_=r(125),w=r(22),A=r(63),S=r(126),k=r(19),x=r(31),P=r(104),C=r(97),T=r(116),R=r(127).set,E=r(130),O=r(131),L=r(133),I=r(132),F=r(134),M=r(33),N=r(52),D=r(57),j=r(135),U=D("species"),q="Promise",B=M.get,W=M.set,V=M.getterFor(q),z=g,H=p.TypeError,G=p.document,Y=p.process,X=v("fetch"),Q=I.f,K=Q,J="process"==k(Y),$=!!(G&&G.createEvent&&p.dispatchEvent),Z="unhandledrejection",ee=(N=N(q,(function(){if(x(z)===String(z)){if(66===j)return!0;if(!J&&"function"!=typeof PromiseRejectionEvent)return!0}if(d&&!z.prototype.finally)return!0;if(51<=j&&/native code/.test(z))return!1;function e(e){e((function(){}),(function(){}))}var t=z.resolve(1);return(t.constructor={})[U]=e,!(t.then((function(){}))instanceof e)})),C=N||!C((function(e){z.all(e).catch((function(){}))})),function(e,t){R.call(p,(function(){var r,n=t.value,i=te(t);if(i&&(r=F((function(){J?Y.emit("unhandledRejection",n,e):a(Z,e,n)})),t.rejection=J||te(t)?2:1,r.error))throw r.value}))}),te=function(e){return 1!==e.rejection&&!e.parent},re=function(e,t){R.call(p,(function(){J?Y.emit("rejectionHandled",e):a("rejectionhandled",e,t.value)}))},ne=function(e,t,r,a){if(!t.done){t.done=!0,a&&(t=a);try{if(e===r)throw H("Promise can't be resolved itself");var u=n(r);u?E((function(){var n={done:!1};try{u.call(r,o(ne,e,n,t),o(s,e,n,t))}catch(r){s(e,n,r,t)}})):(t.value=r,t.state=1,i(e,t,!1))}catch(r){s(e,{done:!1},r,t)}}};N&&(z=function(e){S(this,z,q),A(e),u.call(this);var t=B(this);try{e(o(ne,this,t),o(s,this,t))}catch(e){s(this,t,e)}},(u=function(e){W(this,{type:q,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=m(z.prototype,{then:function(e,t){var r=V(this),n=Q(T(this,z));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=J?Y.domain:void 0,r.parent=!0,r.reactions.push(n),0!=r.state&&i(this,r,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),l=function(){var e=new u,t=B(e);this.promise=e,this.resolve=o(ne,e,t),this.reject=o(s,e,t)},I.f=Q=function(e){return e===z||e===c?new l:K(e)},d||"function"!=typeof g||(h=g.prototype.then,y(g.prototype,"then",(function(e,t){var r=this;return new z((function(e,t){h.call(r,e,t)})).then(e,t)}),{unsafe:!0}),"function"==typeof X&&f({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return O(z,X.apply(p,arguments))}}))),f({global:!0,wrap:!0,forced:N},{Promise:z}),b(z,q,!1,!0),_(q),c=v(q),f({target:q,stat:!0,forced:N},{reject:function(e){var t=Q(this);return t.reject.call(void 0,e),t.promise}}),f({target:q,stat:!0,forced:d||N},{resolve:function(e){return O(d&&this===c?z:this,e)}}),f({target:q,stat:!0,forced:C},{all:function(e){var t=this,r=Q(t),n=r.resolve,i=r.reject,a=F((function(){var r=A(t.resolve),a=[],o=0,s=1;P(e,(function(e){var u=o++,l=!1;a.push(void 0),s++,r.call(t,e).then((function(e){l||(l=!0,a[u]=e,--s||n(a))}),i)})),--s||n(a)}));return a.error&&i(a.value),r.promise},race:function(e){var t=this,r=Q(t),n=r.reject,i=F((function(){var i=A(t.resolve);P(e,(function(e){i.call(t,e).then(r.resolve,n)}))}));return i.error&&n(i.value),r.promise}})},function(e,t,r){r=r(11),e.exports=r.Promise},function(e,t,r){var n=r(29);e.exports=function(e,t,r){for(var i in t)n(e,i,t[i],r);return e}},function(e,t,r){"use strict";var n=r(42),i=r(27),a=r(57),o=r(13),s=a("species");e.exports=function(e){var t=n(e);e=i.f;o&&t&&!t[s]&&e(t,s,{configurable:!0,get:function(){return this}})}},function(e,t){e.exports=function(e,t,r){if(!(e instanceof t))throw TypeError("Incorrect "+(r?r+" ":"")+"invocation");return e}},function(e,t,r){function n(e){var t;w.hasOwnProperty(e)&&(t=w[e],delete w[e],t())}function i(e){return function(){n(e)}}function a(e){n(e.data)}var o,s=r(11),u=r(14),l=r(19),c=r(62),h=r(74),f=r(25),d=r(128),p=s.location,v=s.setImmediate,g=s.clearImmediate,y=s.process,m=s.MessageChannel,b=s.Dispatch,_=0,w={},A="onreadystatechange";r=function(e){s.postMessage(e+"",p.protocol+"//"+p.host)};v&&g||(v=function(e){for(var t=[],r=1;r<arguments.length;)t.push(arguments[r++]);return w[++_]=function(){("function"==typeof e?e:Function(e)).apply(void 0,t)},o(_),_},g=function(e){delete w[e]},"process"==l(y)?o=function(e){y.nextTick(i(e))}:b&&b.now?o=function(e){b.now(i(e))}:m&&!d?(m=(d=new m).port2,d.port1.onmessage=a,o=c(m.postMessage,m,1)):!s.addEventListener||"function"!=typeof postMessage||s.importScripts||u(r)||"file:"===p.protocol?o=A in f("script")?function(e){h.appendChild(f("script"))[A]=function(){h.removeChild(this),n(e)}}:function(e){setTimeout(i(e),0)}:(o=r,s.addEventListener("message",a,!1))),e.exports={set:v,clear:g}},function(e,t,r){r=r(129),e.exports=/(iphone|ipod|ipad).*applewebkit/i.test(r)},function(e,t,r){r=r(42),e.exports=r("navigator","userAgent")||""},function(e,t,r){var n,i,a,o,s,u,l,c,h=r(11),f=r(12).f,d=r(19),p=r(127).set,v=r(128),g=h.MutationObserver||h.WebKitMutationObserver,y=h.process,m=(r=h.Promise,"process"==d(y));f=f(h,"queueMicrotask"),f=f&&f.value;f||(n=function(){var e,t;for(m&&(e=y.domain)&&e.exit();i;){t=i.fn,i=i.next;try{t()}catch(e){throw i?o():a=void 0,e}}a=void 0,e&&e.enter()},o=m?function(){y.nextTick(n)}:g&&!v?(s=!0,u=document.createTextNode(""),new g(n).observe(u,{characterData:!0}),function(){u.data=s=!s}):r&&r.resolve?(l=r.resolve(void 0),c=l.then,function(){c.call(l,n)}):function(){p.call(h,n)}),e.exports=f||function(e){e={fn:e,next:void 0},a&&(a.next=e),i||(i=e,o()),a=e}},function(e,t,r){var n=r(28),i=r(22),a=r(132);e.exports=function(e,t){return n(e),i(t)&&t.constructor===e?t:(e=a.f(e),(0,e.resolve)(t),e.promise)}},function(e,t,r){"use strict";function n(e){var t,r;this.promise=new e((function(e,n){if(void 0!==t||void 0!==r)throw TypeError("Bad Promise constructor");t=e,r=n})),this.resolve=i(t),this.reject=i(r)}var i=r(63);e.exports.f=function(e){return new n(e)}},function(e,t,r){var n=r(11);e.exports=function(e,t){var r=n.console;r&&r.error&&(1===arguments.length?r.error(e):r.error(e,t))}},function(e,t){e.exports=function(e){try{return{error:!1,value:e()}}catch(e){return{error:!0,value:e}}}},function(e,t,r){var n,i,a=r(11);r=r(129),a=a.process,a=a&&a.versions,a=a&&a.v8;a?i=(n=a.split("."))[0]+n[1]:r&&(!(n=r.match(/Edge\/(\d+)/))||74<=n[1])&&(n=r.match(/Chrome\/(\d+)/))&&(i=n[1]),e.exports=i&&+i},function(e,t,r){"use strict";var n=r(10),i=r(63),a=r(132),o=r(134),s=r(104);n({target:"Promise",stat:!0},{allSettled:function(e){var t=this,r=a.f(t),n=r.resolve,u=r.reject,l=o((function(){var r=i(t.resolve),a=[],o=0,u=1;s(e,(function(e){var i=o++,s=!1;a.push(void 0),u++,r.call(t,e).then((function(e){s||(s=!0,a[i]={status:"fulfilled",value:e},--u||n(a))}),(function(e){s||(s=!0,a[i]={status:"rejected",reason:e},--u||n(a))}))})),--u||n(a)}));return l.error&&u(l.value),r.promise}})},function(e,t,r){"use strict";var n=r(10),i=r(37),a=r(123),o=r(14),s=r(42),u=r(116),l=r(131);r=r(29);n({target:"Promise",proto:!0,real:!0,forced:!!a&&o((function(){a.prototype.finally.call({then:function(){}},(function(){}))}))},{finally:function(e){var t=u(this,s("Promise")),r="function"==typeof e;return this.then(r?function(r){return l(t,e()).then((function(){return r}))}:e,r?function(r){return l(t,e()).then((function(){throw r}))}:e)}}),i||"function"!=typeof a||a.prototype.finally||r(a.prototype,"finally",s("Promise").prototype.finally)},function(e,t,r){r(139),r(144),r(142),r=r(43),e.exports=r.URL},function(e,t,r){"use strict";function n(e,t){var r,n,i;if("["==t.charAt(0))return"]"==t.charAt(t.length-1)&&(r=K(t.slice(1,-1)))?void(e.host=r):N;if(ne(e))return t=x(t),H.test(t)||null===(r=Q(t))?N:void(e.host=r);if(G.test(t))return N;for(r="",n=S(t),i=0;i<n.length;i++)r+=te(n[i],J);e.host=r}function i(e){var t,r,n,i;if("number"==typeof e){for(t=[],r=0;r<4;r++)t.unshift(e%256),e=I(e/256);return t.join(".")}if("object"!=typeof e)return e;for(t="",n=function(e){for(var t=null,r=1,n=null,i=0,a=0;a<8;a++)0!==e[a]?(r<i&&(t=n,r=i),n=null,i=0):(null===n&&(n=a),++i);return r<i&&(t=n,r=i),t}(e),r=0;r<8;r++)i&&0===e[r]||(i=i&&!1,n===r?(t+=r?":":"::",i=!0):(t+=e[r].toString(16),r<7&&(t+=":")));return"["+t+"]"}function a(e){return""!=e.username||""!=e.password}function o(e){return!e.host||e.cannotBeABaseURL||"file"==e.scheme}function s(e,t){return 2==e.length&&j.test(e.charAt(0))&&(":"==(e=e.charAt(1))||!t&&"|"==e)}function u(e){var t;return 1<e.length&&s(e.slice(0,2))&&(2==e.length||"/"===(t=e.charAt(2))||"\\"===t||"?"===t||"#"===t)}function l(e){var t=e.path,r=t.length;!r||"file"==e.scheme&&1==r&&s(t[0],!0)||t.pop()}function c(e,t,r,i){var o,c,f,d=r||ie,p=0,v="",g=!1,y=!1,m=!1;for(r||(e.scheme="",e.username="",e.password="",e.host=null,e.port=null,e.path=[],e.query=null,e.fragment=null,e.cannotBeABaseURL=!1,t=t.replace(Y,"")),t=t.replace(X,""),o=S(t);p<=o.length;){switch(c=o[p],d){case ie:if(!c||!j.test(c)){if(r)return M;d=oe;continue}v+=c.toLowerCase(),d=ae;break;case ae:if(c&&(U.test(c)||"+"==c||"-"==c||"."==c))v+=c.toLowerCase();else{if(":"!=c){if(r)return M;v="",d=oe,p=0;continue}if(r&&(ne(e)!=w(re,v)||"file"==v&&(a(e)||null!==e.port)||"file"==e.scheme&&!e.host))return;if(e.scheme=v,r)return void(ne(e)&&re[e.scheme]==e.port&&(e.port=null));v="","file"==e.scheme?d=ye:ne(e)&&i&&i.scheme==e.scheme?d=se:ne(e)?d=he:"/"==o[p+1]?(d=ue,p++):(e.cannotBeABaseURL=!0,e.path.push(""),d=Ae)}break;case oe:if(!i||i.cannotBeABaseURL&&"#"!=c)return M;if(i.cannotBeABaseURL&&"#"==c){e.scheme=i.scheme,e.path=i.path.slice(),e.query=i.query,e.fragment="",e.cannotBeABaseURL=!0,d=ke;break}d="file"==i.scheme?ye:le;continue;case se:if("/"!=c||"/"!=o[p+1]){d=le;continue}d=fe,p++;break;case ue:if("/"==c){d=de;break}d=we;continue;case le:if(e.scheme=i.scheme,c==h)e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query=i.query;else if("/"==c||"\\"==c&&ne(e))d=ce;else if("?"==c)e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query="",d=Se;else{if("#"!=c){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.path.pop(),d=we;continue}e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query=i.query,e.fragment="",d=ke}break;case ce:if(!ne(e)||"/"!=c&&"\\"!=c){if("/"!=c){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,d=we;continue}d=de}else d=fe;break;case he:if(d=fe,"/"!=c||"/"!=v.charAt(p+1))continue;p++;break;case fe:if("/"==c||"\\"==c)break;d=de;continue;case de:if("@"==c){g&&(v="%40"+v);g=!0;for(var b=S(v),_=0;_<b.length;_++){var A=b[_];":"!=A||m?(A=te(A,ee),m?e.password+=A:e.username+=A):m=!0}v=""}else if(c==h||"/"==c||"?"==c||"#"==c||"\\"==c&&ne(e)){if(g&&""==v)return"Invalid authority";p-=S(v).length+1,v="",d=pe}else v+=c;break;case pe:case ve:if(r&&"file"==e.scheme){d=be;continue}if(":"!=c||y){if(c==h||"/"==c||"?"==c||"#"==c||"\\"==c&&ne(e)){if(ne(e)&&""==v)return N;if(r&&""==v&&(a(e)||null!==e.port))return;if(f=n(e,v))return f;if(v="",d=_e,r)return;continue}"["==c?y=!0:"]"==c&&(y=!1),v+=c}else{if(""==v)return N;if(f=n(e,v))return f;if(v="",d=ge,r==ve)return}break;case ge:if(!q.test(c)){if(c==h||"/"==c||"?"==c||"#"==c||"\\"==c&&ne(e)||r){if(""!=v){var k=parseInt(v,10);if(65535<k)return D;e.port=ne(e)&&k===re[e.scheme]?null:k,v=""}if(r)return;d=_e;continue}return D}v+=c;break;case ye:if(e.scheme="file","/"==c||"\\"==c)d=me;else{if(!i||"file"!=i.scheme){d=we;continue}if(c==h)e.host=i.host,e.path=i.path.slice(),e.query=i.query;else if("?"==c)e.host=i.host,e.path=i.path.slice(),e.query="",d=Se;else{if("#"!=c){u(o.slice(p).join(""))||(e.host=i.host,e.path=i.path.slice(),l(e)),d=we;continue}e.host=i.host,e.path=i.path.slice(),e.query=i.query,e.fragment="",d=ke}}break;case me:if("/"==c||"\\"==c){d=be;break}i&&"file"==i.scheme&&!u(o.slice(p).join(""))&&(s(i.path[0],!0)?e.path.push(i.path[0]):e.host=i.host),d=we;continue;case be:if(c==h||"/"==c||"\\"==c||"?"==c||"#"==c){if(!r&&s(v))d=we;else if(""==v){if(e.host="",r)return;d=_e}else{if(f=n(e,v))return f;if("localhost"==e.host&&(e.host=""),r)return;v="",d=_e}continue}v+=c;break;case _e:if(ne(e)){if(d=we,"/"!=c&&"\\"!=c)continue}else if(r||"?"!=c)if(r||"#"!=c){if(c!=h&&(d=we,"/"!=c))continue}else e.fragment="",d=ke;else e.query="",d=Se;break;case we:if(c==h||"/"==c||"\\"==c&&ne(e)||!r&&("?"==c||"#"==c)){if(".."===(k=(k=v).toLowerCase())||"%2e."===k||".%2e"===k||"%2e%2e"===k?(l(e),"/"==c||"\\"==c&&ne(e)||e.path.push("")):"."===(k=v)||"%2e"===k.toLowerCase()?"/"==c||"\\"==c&&ne(e)||e.path.push(""):("file"==e.scheme&&!e.path.length&&s(v)&&(e.host&&(e.host=""),v=v.charAt(0)+":"),e.path.push(v)),v="","file"==e.scheme&&(c==h||"?"==c||"#"==c))for(;1<e.path.length&&""===e.path[0];)e.path.shift();"?"==c?(e.query="",d=Se):"#"==c&&(e.fragment="",d=ke)}else v+=te(c,Z);break;case Ae:"?"==c?(e.query="",d=Se):"#"==c?(e.fragment="",d=ke):c!=h&&(e.path[0]+=te(c,J));break;case Se:r||"#"!=c?c!=h&&("'"==c&&ne(e)?e.query+="%27":e.query+="#"==c?"%23":te(c,J)):(e.fragment="",d=ke);break;case ke:c!=h&&(e.fragment+=te(c,$))}p++}}r(77);var h,f,d,p=r(10),v=r(13),g=r(140),y=r(11),m=r(72),b=r(29),_=r(126),w=r(23),A=r(100),S=r(90),k=r(78).codeAt,x=r(141),P=r(85),C=r(142),T=(r=r(33),y.URL),R=C.URLSearchParams,E=C.getState,O=r.set,L=r.getterFor("URL"),I=Math.floor,F=Math.pow,M="Invalid scheme",N="Invalid host",D="Invalid port",j=/[A-Za-z]/,U=/[\d+-.A-Za-z]/,q=/\d/,B=/^(0x|0X)/,W=/^[0-7]+$/,V=/^\d+$/,z=/^[\dA-Fa-f]+$/,H=/[\u0000\u0009\u000A\u000D #%/:?@[\\]]/,G=/[\u0000\u0009\u000A\u000D #/:?@[\\]]/,Y=/^[\u0000-\u001F ]+|[\u0000-\u001F ]+$/g,X=/[\u0009\u000A\u000D]/g,Q=function(e){var t,r,n,i,a,o,s,u=e.split(".");if(u.length&&""==u[u.length-1]&&u.pop(),4<(t=u.length))return e;for(r=[],n=0;n<t;n++){if(""==(i=u[n]))return e;if(a=10,1<i.length&&"0"==i.charAt(0)&&(a=B.test(i)?16:8,i=i.slice(8==a?1:2)),""===i)o=0;else{if(!(10==a?V:8==a?W:z).test(i))return e;o=parseInt(i,a)}r.push(o)}for(n=0;n<t;n++)if(o=r[n],n==t-1){if(o>=F(256,5-t))return null}else if(255<o)return null;for(s=r.pop(),n=0;n<r.length;n++)s+=r[n]*F(256,3-n);return s},K=function(e){function t(){return e.charAt(f)}var r,n,i,a,o,s,u,l=[0,0,0,0,0,0,0,0],c=0,h=null,f=0;if(":"==t()){if(":"!=e.charAt(1))return;f+=2,h=++c}for(;t();){if(8==c)return;if(":"!=t()){for(r=n=0;n<4&&z.test(t());)r=16*r+parseInt(t(),16),f++,n++;if("."==t()){if(0==n)return;if(f-=n,6<c)return;for(i=0;t();){if(a=null,0<i){if(!("."==t()&&i<4))return;f++}if(!q.test(t()))return;for(;q.test(t());){if(o=parseInt(t(),10),null===a)a=o;else{if(0==a)return;a=10*a+o}if(255<a)return;f++}l[c]=256*l[c]+a,2!=++i&&4!=i||c++}if(4!=i)return;break}if(":"==t()){if(f++,!t())return}else if(t())return;l[c++]=r}else{if(null!==h)return;f++,h=++c}}if(null!==h)for(s=c-h,c=7;0!=c&&0<s;)u=l[c],l[c--]=l[h+s-1],l[h+--s]=u;else if(8!=c)return;return l},J={},$=A({},J,{" ":1,'"':1,"<":1,">":1,"`":1}),Z=A({},$,{"#":1,"?":1,"{":1,"}":1}),ee=A({},Z,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),te=function(e,t){var r=k(e,0);return 32<r&&r<127&&!w(t,e)?e:encodeURIComponent(e)},re={ftp:21,file:null,http:80,https:443,ws:80,wss:443},ne=function(e){return w(re,e.scheme)},ie={},ae={},oe={},se={},ue={},le={},ce={},he={},fe={},de={},pe={},ve={},ge={},ye={},me={},be={},_e={},we={},Ae={},Se={},ke={},xe=function(e){var t,r=_(this,xe,"URL"),n=1<arguments.length?arguments[1]:void 0,i=(e=String(e),O(r,{type:"URL"}));if(void 0!==n)if(n instanceof xe)t=L(n);else if(o=c(t={},String(n)))throw TypeError(o);if(o=c(i,e,null,t))throw TypeError(o);var a=i.searchParams=new R,o=E(a);o.updateSearchParams(i.query),o.updateURL=function(){i.query=String(a)||null},v||(r.href=Pe.call(r),r.origin=Ce.call(r),r.protocol=Te.call(r),r.username=Re.call(r),r.password=Ee.call(r),r.host=Oe.call(r),r.hostname=Le.call(r),r.port=Ie.call(r),r.pathname=Fe.call(r),r.search=Me.call(r),r.searchParams=Ne.call(r),r.hash=De.call(r))},Pe=(r=xe.prototype,function(){var e=L(this),t=e.scheme,r=e.username,n=e.password,o=e.host,s=e.port,u=e.path,l=e.query,c=e.fragment,h=t+":";return null!==o?(h+="//",a(e)&&(h+=r+(n?":"+n:"")+"@"),h+=i(o),null!==s&&(h+=":"+s)):"file"==t&&(h+="//"),h+=e.cannotBeABaseURL?u[0]:u.length?"/"+u.join("/"):"",null!==l&&(h+="?"+l),null!==c&&(h+="#"+c),h}),Ce=function(){var e=L(this),t=e.scheme,r=e.port;if("blob"==t)try{return new URL(t.path[0]).origin}catch(e){return"null"}return"file"!=t&&ne(e)?t+"://"+i(e.host)+(null!==r?":"+r:""):"null"},Te=function(){return L(this).scheme+":"},Re=function(){return L(this).username},Ee=function(){return L(this).password},Oe=function(){var e=L(this),t=e.host;e=e.port;return null===t?"":null===e?i(t):i(t)+":"+e},Le=function(){var e=L(this).host;return null===e?"":i(e)},Ie=function(){var e=L(this).port;return null===e?"":String(e)},Fe=function(){var e=L(this),t=e.path;return e.cannotBeABaseURL?t[0]:t.length?"/"+t.join("/"):""},Me=function(){var e=L(this).query;return e?"?"+e:""},Ne=function(){return L(this).searchParams},De=function(){var e=L(this).fragment;return e?"#"+e:""};A=function(e,t){return{get:e,set:t,configurable:!0,enumerable:!0}};v&&m(r,{href:A(Pe,(function(e){var t=L(this);e=String(e),e=c(t,e);if(e)throw TypeError(e);E(t.searchParams).updateSearchParams(t.query)})),origin:A(Ce),protocol:A(Te,(function(e){var t=L(this);c(t,String(e)+":",ie)})),username:A(Re,(function(e){var t=L(this),r=S(String(e));if(!o(t)){t.username="";for(var n=0;n<r.length;n++)t.username+=te(r[n],ee)}})),password:A(Ee,(function(e){var t=L(this),r=S(String(e));if(!o(t)){t.password="";for(var n=0;n<r.length;n++)t.password+=te(r[n],ee)}})),host:A(Oe,(function(e){var t=L(this);t.cannotBeABaseURL||c(t,String(e),pe)})),hostname:A(Le,(function(e){var t=L(this);t.cannotBeABaseURL||c(t,String(e),ve)})),port:A(Ie,(function(e){var t=L(this);o(t)||(""==(e=String(e))?t.port=null:c(t,e,ge))})),pathname:A(Fe,(function(e){var t=L(this);t.cannotBeABaseURL||(t.path=[],c(t,e+"",_e))})),search:A(Me,(function(e){var t=L(this);""==(e=String(e))?t.query=null:("?"==e.charAt(0)&&(e=e.slice(1)),t.query="",c(t,e,Se)),E(t.searchParams).updateSearchParams(t.query)})),searchParams:A(Ne),hash:A(De,(function(e){var t=L(this);""!=(e=String(e))?("#"==e.charAt(0)&&(e=e.slice(1)),t.fragment="",c(t,e,ke)):t.fragment=null}))}),b(r,"toJSON",(function(){return Pe.call(this)}),{enumerable:!0}),b(r,"toString",(function(){return Pe.call(this)}),{enumerable:!0}),T&&(f=T.createObjectURL,d=T.revokeObjectURL,f&&b(xe,"createObjectURL",(function(e){return f.apply(T,arguments)})),d&&b(xe,"revokeObjectURL",(function(e){return d.apply(T,arguments)}))),P(xe,"URL"),p({global:!0,forced:!g,sham:!v},{URL:xe})},function(e,t,r){var n=r(14),i=r(57),a=r(37),o=i("iterator");e.exports=!n((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,r="";return e.pathname="c%20d",t.forEach((function(e,n){t.delete("b"),r+=n+e})),a&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[o]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==r||"x"!==new URL("http://x",void 0).host}))},function(e,t,r){"use strict";function n(e){return e+22+75*(e<26)}function i(e){var t,r=[],i=(e=function(e){for(var t=[],r=0,n=e.length;r<n;){var i,a=e.charCodeAt(r++);55296<=a&&a<=56319&&r<n?56320==(64512&(i=e.charCodeAt(r++)))?t.push(((1023&a)<<10)+(1023&i)+65536):(t.push(a),r--):t.push(a)}return t}(e)).length,o=128,s=0,h=72;for(v=0;v<e.length;v++)(t=e[v])<128&&r.push(c(t));var f=r.length,d=f;for(f&&r.push("-");d<i;){for(var p=a,v=0;v<e.length;v++)o<=(t=e[v])&&t<p&&(p=t);var g=d+1;if(p-o>l((a-s)/g))throw RangeError(u);for(s+=(p-o)*g,o=p,v=0;v<e.length;v++){if((t=e[v])<o&&++s>a)throw RangeError(u);if(t==o){for(var y=s,m=36;;m+=36){var b=m<=h?1:h+26<=m?26:m-h;if(y<b)break;var _=y-b,w=36-b;r.push(c(n(b+_%w))),y=l(_/w)}r.push(c(n(y))),h=function(e,t,r){var n=0;for(e=r?l(e/700):e>>1,e+=l(e/t);455<e;n+=36)e=l(e/35);return l(n+36*e/(e+38))}(s,g,d==f),s=0,++d}}++s,++o}return r.join("")}var a=2147483647,o=/[^\0-\u007E]/,s=/[.\u3002\uFF0E\uFF61]/g,u="Overflow: input needs wider integers to process",l=Math.floor,c=String.fromCharCode;e.exports=function(e){for(var t,r=[],n=e.toLowerCase().replace(s,".").split("."),a=0;a<n.length;a++)t=n[a],r.push(o.test(t)?"xn--"+i(t):t);return r.join(".")}},function(e,t,r){"use strict";function n(t){try{return decodeURIComponent(t)}catch(e){return t}}function i(e){var t,r=e.replace(M," "),i=4;try{return decodeURIComponent(r)}catch(e){for(;i;)r=r.replace((t=i--,N[t-1]||(N[t-1]=RegExp("((?:%[\\da-f]{2}){"+t+"})","gi"))),n);return r}}function a(e){return j[e]}function o(e){return encodeURIComponent(e).replace(D,a)}function s(e,t){if(t)for(var r,n=t.split("&"),a=0;a<n.length;)(r=n[a++]).length&&(r=r.split("="),e.push({key:i(r.shift()),value:i(r.join("="))}))}function u(e){this.entries.length=0,s(this.entries,e)}function l(e,t){if(e<t)throw TypeError("Not enough arguments")}r(102);var c=r(10),h=r(42),f=r(140),d=r(29),p=r(124),v=r(85),g=r(80),y=r(33),m=r(126),b=r(23),_=r(62),w=r(95),A=r(28),S=r(22),k=r(71),x=r(16),P=r(143),C=r(94),T=(r=r(57),h("fetch")),R=h("Headers"),E=(r=r("iterator"),"URLSearchParams"),O=E+"Iterator",L=y.set,I=y.getterFor(E),F=y.getterFor(O),M=/\+/g,N=Array(4),D=/[!'()~]|%20/g,j={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},U=g((function(e,t){L(this,{type:O,iterator:P(I(e).entries),kind:t})}),"Iterator",(function(){var e=F(this),t=e.kind,r=e.iterator.next();e=r.value;return r.done||(r.value="keys"===t?e.key:"values"===t?e.value:[e.key,e.value]),r})),q=function(){m(this,q,E);var e,t,r,n,i,a,o,l,c=0<arguments.length?arguments[0]:void 0,h=[];if(L(this,{type:E,entries:h,updateURL:function(){},updateSearchParams:u}),void 0!==c)if(S(c))if("function"==typeof(e=C(c)))for(r=(t=e.call(c)).next;!(a=r.call(t)).done;){if((a=(i=(n=P(A(a.value))).next).call(n)).done||(o=i.call(n)).done||!i.call(n).done)throw TypeError("Expected sequence with length 2");h.push({key:a.value+"",value:o.value+""})}else for(l in c)b(c,l)&&h.push({key:l,value:c[l]+""});else s(h,"string"==typeof c?"?"===c.charAt(0)?c.slice(1):c:c+"")};g=q.prototype;p(g,{append:function(e,t){l(arguments.length,2);var r=I(this);r.entries.push({key:e+"",value:t+""}),r.updateURL()},delete:function(e){l(arguments.length,1);for(var t=I(this),r=t.entries,n=e+"",i=0;i<r.length;)r[i].key===n?r.splice(i,1):i++;t.updateURL()},get:function(e){l(arguments.length,1);for(var t=I(this).entries,r=e+"",n=0;n<t.length;n++)if(t[n].key===r)return t[n].value;return null},getAll:function(e){l(arguments.length,1);for(var t=I(this).entries,r=e+"",n=[],i=0;i<t.length;i++)t[i].key===r&&n.push(t[i].value);return n},has:function(e){l(arguments.length,1);for(var t=I(this).entries,r=e+"",n=0;n<t.length;)if(t[n++].key===r)return!0;return!1},set:function(e,t){l(arguments.length,1);for(var r,n=I(this),i=n.entries,a=!1,o=e+"",s=t+"",u=0;u<i.length;u++)(r=i[u]).key===o&&(a?i.splice(u--,1):(a=!0,r.value=s));a||i.push({key:o,value:s}),n.updateURL()},sort:function(){for(var e,t,r=I(this),n=r.entries,i=n.slice(),a=n.length=0;a<i.length;a++){for(e=i[a],t=0;t<a;t++)if(n[t].key>e.key){n.splice(t,0,e);break}t===a&&n.push(e)}r.updateURL()},forEach:function(e){for(var t,r=I(this).entries,n=_(e,1<arguments.length?arguments[1]:void 0,3),i=0;i<r.length;)n((t=r[i++]).value,t.key,this)},keys:function(){return new U(this,"keys")},values:function(){return new U(this,"values")},entries:function(){return new U(this,"entries")}},{enumerable:!0}),d(g,r,g.entries),d(g,"toString",(function(){for(var e,t=I(this).entries,r=[],n=0;n<t.length;)e=t[n++],r.push(o(e.key)+"="+o(e.value));return r.join("&")}),{enumerable:!0}),v(q,E),c({global:!0,forced:!f},{URLSearchParams:q}),f||"function"!=typeof T||"function"!=typeof R||c({global:!0,enumerable:!0,forced:!0},{fetch:function(e){var t,r,n=[e];return 1<arguments.length&&(S(t=arguments[1])&&(r=t.body,w(r)===E&&((e=t.headers?new R(t.headers):new R).has("content-type")||e.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"),t=k(t,{body:x(0,String(r)),headers:x(0,e)}))),n.push(t)),T.apply(this,n)}}),e.exports={URLSearchParams:q,getState:I}},function(e,t,r){var n=r(28),i=r(94);e.exports=function(e){var t=i(e);if("function"!=typeof t)throw TypeError(String(e)+" is not iterable");return n(t.call(e))}},function(e,t,r){"use strict";r(10)({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return URL.prototype.toString.call(this)}})},function(e,t,r){!function(e){"use strict";var t="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?Symbol:function(e){return"Symbol("+e+")"};function r(){}var n=Number.isNaN||function(e){return e!==e},i=r;function a(e){return"object"===typeof e&&null!==e||"function"===typeof e}function o(e){return e.slice()}function s(e,t,r,n,i){new Uint8Array(e).set(new Uint8Array(r,n,i),t)}function u(e){return!1!==l(e)&&e!==1/0}function l(e){return"number"===typeof e&&(!n(e)&&!(e<0))}function c(e,t,r){if("function"!==typeof e)throw new TypeError("Argument is not a function");return Function.prototype.apply.call(e,t,r)}function h(e,t,r,n){var i=e[t];if(void 0!==i){if("function"!==typeof i)throw new TypeError(i+" is not a method");switch(r){case 0:return function(){return d(i,e,n)};case 1:return function(t){var r=[t].concat(n);return d(i,e,r)}}}return function(){return S(void 0)}}function f(e,t,r){var n=e[t];if(void 0!==n)return c(n,e,r)}function d(e,t,r){try{return S(c(e,t,r))}catch(e){return k(e)}}function p(e){return e}function v(e){return!1}function g(e){if(e=Number(e),n(e)||e<0)throw new RangeError("highWaterMark property of a queuing strategy must be non-negative and non-NaN");return e}function y(e){if(void 0===e)return function(){return 1};if("function"!==typeof e)throw new TypeError("size property of a queuing strategy must be a function");return function(t){return e(t)}}var m=Promise,b=Promise.prototype.then,_=Promise.resolve.bind(m),w=Promise.reject.bind(m);function A(e){return new m(e)}function S(e){return _(e)}function k(e){return w(e)}function x(e,t,r){return b.call(e,t,r)}function P(e,t,r){x(x(e,t,r),void 0,i)}function C(e,t){P(e,t)}function T(e,t){P(e,void 0,t)}function R(e,t,r){return x(e,t,r)}function E(e){x(e,void 0,i)}var O=16384,L=function(){function e(){this._cursor=0,this._size=0,this._front={_elements:[],_next:void 0},this._back=this._front,this._cursor=0,this._size=0}return Object.defineProperty(e.prototype,"length",{get:function(){return this._size},enumerable:!0,configurable:!0}),e.prototype.push=function(e){var t=this._back,r=t;t._elements.length===O-1&&(r={_elements:[],_next:void 0}),t._elements.push(e),r!==t&&(this._back=r,t._next=r),++this._size},e.prototype.shift=function(){var e=this._front,t=e,r=this._cursor,n=r+1,i=e._elements,a=i[r];return n===O&&(t=e._next,n=0),--this._size,this._cursor=n,e!==t&&(this._front=t),i[r]=void 0,a},e.prototype.forEach=function(e){var t=this._cursor,r=this._front,n=r._elements;while(t!==n.length||void 0!==r._next){if(t===n.length&&(r=r._next,n=r._elements,t=0,0===n.length))break;e(n[t]),++t}},e.prototype.peek=function(){var e=this._front,t=this._cursor;return e._elements[t]},e}();function I(e,t,r){var n=null;!0===r&&(n=Object.prototype);var i=Object.create(n);return i.value=e,i.done=t,i}function F(e,t){e._forAuthorCode=!0,e._ownerReadableStream=t,t._reader=e,"readable"===t._state?j(e):"closed"===t._state?q(e):U(e,t._storedError)}function M(e,t){var r=e._ownerReadableStream;return Nr(r,t)}function N(e){"readable"===e._ownerReadableStream._state?B(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):W(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),e._ownerReadableStream._reader=void 0,e._ownerReadableStream=void 0}function D(e){return new TypeError("Cannot "+e+" a stream using a released reader")}function j(e){e._closedPromise=A((function(t,r){e._closedPromise_resolve=t,e._closedPromise_reject=r}))}function U(e,t){j(e),B(e,t)}function q(e){j(e),V(e)}function B(e,t){E(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0}function W(e,t){U(e,t)}function V(e){e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0}var z=t("[[CancelSteps]]"),H=t("[[PullSteps]]");function G(e,t){void 0===t&&(t=!1);var r=new Z(e);return r._forAuthorCode=t,r}function Y(e){var t=A((function(t,r){var n={_resolve:t,_reject:r};e._reader._readRequests.push(n)}));return t}function X(e,t,r){var n=e._reader,i=n._readRequests.shift();i._resolve(I(t,r,n._forAuthorCode))}function Q(e){return e._reader._readRequests.length}function K(e){var t=e._reader;return void 0!==t&&!!ee(t)}var J,$,Z=function(){function e(e){if(!1===Fr(e))throw new TypeError("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(!0===Mr(e))throw new TypeError("This stream has already been locked for exclusive reading by another reader");F(this,e),this._readRequests=new L}return Object.defineProperty(e.prototype,"closed",{get:function(){return ee(this)?this._closedPromise:k(re("closed"))},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return ee(this)?void 0===this._ownerReadableStream?k(D("cancel")):M(this,e):k(re("cancel"))},e.prototype.read=function(){return ee(this)?void 0===this._ownerReadableStream?k(D("read from")):te(this):k(re("read"))},e.prototype.releaseLock=function(){if(!ee(this))throw re("releaseLock");if(void 0!==this._ownerReadableStream){if(this._readRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");N(this)}},e}();function ee(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readRequests")}function te(e){var t=e._ownerReadableStream;return t._disturbed=!0,"closed"===t._state?S(I(void 0,!0,e._forAuthorCode)):"errored"===t._state?k(t._storedError):t._readableStreamController[H]()}function re(e){return new TypeError("ReadableStreamDefaultReader.prototype."+e+" can only be used on a ReadableStreamDefaultReader")}"symbol"===typeof t.asyncIterator&&(J={},J[t.asyncIterator]=function(){return this},$=J,Object.defineProperty($,t.asyncIterator,{enumerable:!1}));var ne={next:function(){if(!1===ae(this))return k(oe("next"));var e=this._asyncIteratorReader;return void 0===e._ownerReadableStream?k(D("iterate")):R(te(e),(function(t){var r=t.done;r&&N(e);var n=t.value;return I(n,r,!0)}))},return:function(e){if(!1===ae(this))return k(oe("next"));var t=this._asyncIteratorReader;if(void 0===t._ownerReadableStream)return k(D("finish iterating"));if(t._readRequests.length>0)return k(new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled"));if(!1===this._preventCancel){var r=M(t,e);return N(t),R(r,(function(){return I(e,!0,!0)}))}return N(t),S(I(e,!0,!0))}};function ie(e,t){void 0===t&&(t=!1);var r=G(e),n=Object.create(ne);return n._asyncIteratorReader=r,n._preventCancel=Boolean(t),n}function ae(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_asyncIteratorReader")}function oe(e){return new TypeError("ReadableStreamAsyncIterator."+e+" can only be used on a ReadableSteamAsyncIterator")}function se(e){var t=e._queue.shift();return e._queueTotalSize-=t.size,e._queueTotalSize<0&&(e._queueTotalSize=0),t.value}function ue(e,t,r){if(r=Number(r),!u(r))throw new RangeError("Size must be a finite, non-NaN, non-negative number.");e._queue.push({value:t,size:r}),e._queueTotalSize+=r}function le(e){var t=e._queue.peek();return t.value}function ce(e){e._queue=new L,e._queueTotalSize=0}void 0!==$&&Object.setPrototypeOf(ne,$),Object.defineProperty(ne,"next",{enumerable:!1}),Object.defineProperty(ne,"return",{enumerable:!1});var he=t("[[AbortSteps]]"),fe=t("[[ErrorSteps]]"),de=function(){function e(e,t){void 0===e&&(e={}),void 0===t&&(t={}),ge(this);var r=t.size,n=t.highWaterMark,i=e.type;if(void 0!==i)throw new RangeError("Invalid type is specified");var a=y(r);void 0===n&&(n=1),n=g(n),Xe(this,e,n,a)}return Object.defineProperty(e.prototype,"locked",{get:function(){if(!1===ye(this))throw ot("locked");return me(this)},enumerable:!0,configurable:!0}),e.prototype.abort=function(e){return!1===ye(this)?k(ot("abort")):!0===me(this)?k(new TypeError("Cannot abort a stream that already has a writer")):be(this,e)},e.prototype.close=function(){return!1===ye(this)?k(ot("close")):!0===me(this)?k(new TypeError("Cannot close a stream that already has a writer")):!0===Re(this)?k(new TypeError("Cannot close an already-closing stream")):_e(this)},e.prototype.getWriter=function(){if(!1===ye(this))throw ot("getWriter");return pe(this)},e}();function pe(e){return new Me(e)}function ve(e,t,r,n,i,a){void 0===i&&(i=1),void 0===a&&(a=function(){return 1});var o=Object.create(de.prototype);ge(o);var s=Object.create(He.prototype);return Ye(o,s,e,t,r,n,i,a),o}function ge(e){e._state="writable",e._storedError=void 0,e._writer=void 0,e._writableStreamController=void 0,e._writeRequests=new L,e._inFlightWriteRequest=void 0,e._closeRequest=void 0,e._inFlightCloseRequest=void 0,e._pendingAbortRequest=void 0,e._backpressure=!1}function ye(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_writableStreamController")}function me(e){return void 0!==e._writer}function be(e,t){var r=e._state;if("closed"===r||"errored"===r)return S(void 0);if(void 0!==e._pendingAbortRequest)return e._pendingAbortRequest._promise;var n=!1;"erroring"===r&&(n=!0,t=void 0);var i=A((function(r,i){e._pendingAbortRequest={_promise:void 0,_resolve:r,_reject:i,_reason:t,_wasAlreadyErroring:n}}));return e._pendingAbortRequest._promise=i,!1===n&&Se(e,t),i}function _e(e){var t=e._state;if("closed"===t||"errored"===t)return k(new TypeError("The stream (in "+t+" state) is not in the writable state and cannot be closed"));var r=A((function(t,r){var n={_resolve:t,_reject:r};e._closeRequest=n})),n=e._writer;return void 0!==n&&!0===e._backpressure&&"writable"===t&&wt(n),Ke(e._writableStreamController),r}function we(e){var t=A((function(t,r){var n={_resolve:t,_reject:r};e._writeRequests.push(n)}));return t}function Ae(e,t){var r=e._state;"writable"!==r?ke(e):Se(e,t)}function Se(e,t){var r=e._writableStreamController;e._state="erroring",e._storedError=t;var n=e._writer;void 0!==n&&Be(n,t),!1===Ee(e)&&!0===r._started&&ke(e)}function ke(e){e._state="errored",e._writableStreamController[fe]();var t=e._storedError;if(e._writeRequests.forEach((function(e){e._reject(t)})),e._writeRequests=new L,void 0!==e._pendingAbortRequest){var r=e._pendingAbortRequest;if(e._pendingAbortRequest=void 0,!0===r._wasAlreadyErroring)return r._reject(t),void Ie(e);var n=e._writableStreamController[he](r._reason);P(n,(function(){r._resolve(),Ie(e)}),(function(t){r._reject(t),Ie(e)}))}else Ie(e)}function xe(e){e._inFlightWriteRequest._resolve(void 0),e._inFlightWriteRequest=void 0}function Pe(e,t){e._inFlightWriteRequest._reject(t),e._inFlightWriteRequest=void 0,Ae(e,t)}function Ce(e){e._inFlightCloseRequest._resolve(void 0),e._inFlightCloseRequest=void 0;var t=e._state;"erroring"===t&&(e._storedError=void 0,void 0!==e._pendingAbortRequest&&(e._pendingAbortRequest._resolve(),e._pendingAbortRequest=void 0)),e._state="closed";var r=e._writer;void 0!==r&&pt(r)}function Te(e,t){e._inFlightCloseRequest._reject(t),e._inFlightCloseRequest=void 0,void 0!==e._pendingAbortRequest&&(e._pendingAbortRequest._reject(t),e._pendingAbortRequest=void 0),Ae(e,t)}function Re(e){return void 0!==e._closeRequest||void 0!==e._inFlightCloseRequest}function Ee(e){return void 0!==e._inFlightWriteRequest||void 0!==e._inFlightCloseRequest}function Oe(e){e._inFlightCloseRequest=e._closeRequest,e._closeRequest=void 0}function Le(e){e._inFlightWriteRequest=e._writeRequests.shift()}function Ie(e){void 0!==e._closeRequest&&(e._closeRequest._reject(e._storedError),e._closeRequest=void 0);var t=e._writer;void 0!==t&&ft(t,e._storedError)}function Fe(e,t){var r=e._writer;void 0!==r&&t!==e._backpressure&&(!0===t?bt(r):wt(r)),e._backpressure=t}var Me=function(){function e(e){if(!1===ye(e))throw new TypeError("WritableStreamDefaultWriter can only be constructed with a WritableStream instance");if(!0===me(e))throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=e,e._writer=this;var t=e._state;if("writable"===t)!1===Re(e)&&!0===e._backpressure?vt(this):yt(this),lt(this);else if("erroring"===t)gt(this,e._storedError),lt(this);else if("closed"===t)yt(this),ht(this);else{var r=e._storedError;gt(this,r),ct(this,r)}}return Object.defineProperty(e.prototype,"closed",{get:function(){return!1===Ne(this)?k(st("closed")):this._closedPromise},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Ne(this))throw st("desiredSize");if(void 0===this._ownerWritableStream)throw ut("desiredSize");return We(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"ready",{get:function(){return!1===Ne(this)?k(st("ready")):this._readyPromise},enumerable:!0,configurable:!0}),e.prototype.abort=function(e){return!1===Ne(this)?k(st("abort")):void 0===this._ownerWritableStream?k(ut("abort")):De(this,e)},e.prototype.close=function(){if(!1===Ne(this))return k(st("close"));var e=this._ownerWritableStream;return void 0===e?k(ut("close")):!0===Re(e)?k(new TypeError("Cannot close an already-closing stream")):je(this)},e.prototype.releaseLock=function(){if(!1===Ne(this))throw st("releaseLock");var e=this._ownerWritableStream;void 0!==e&&Ve(this)},e.prototype.write=function(e){return!1===Ne(this)?k(st("write")):void 0===this._ownerWritableStream?k(ut("write to")):ze(this,e)},e}();function Ne(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_ownerWritableStream")}function De(e,t){var r=e._ownerWritableStream;return be(r,t)}function je(e){var t=e._ownerWritableStream;return _e(t)}function Ue(e){var t=e._ownerWritableStream,r=t._state;return!0===Re(t)||"closed"===r?S(void 0):"errored"===r?k(t._storedError):je(e)}function qe(e,t){"pending"===e._closedPromiseState?ft(e,t):dt(e,t)}function Be(e,t){"pending"===e._readyPromiseState?mt(e,t):_t(e,t)}function We(e){var t=e._ownerWritableStream,r=t._state;return"errored"===r||"erroring"===r?null:"closed"===r?0:$e(t._writableStreamController)}function Ve(e){var t=e._ownerWritableStream,r=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");Be(e,r),qe(e,r),t._writer=void 0,e._ownerWritableStream=void 0}function ze(e,t){var r=e._ownerWritableStream,n=r._writableStreamController,i=Je(n,t);if(r!==e._ownerWritableStream)return k(ut("write to"));var a=r._state;if("errored"===a)return k(r._storedError);if(!0===Re(r)||"closed"===a)return k(new TypeError("The stream is closing or closed and cannot be written to"));if("erroring"===a)return k(r._storedError);var o=we(r);return Ze(n,t,i),o}var He=function(){function e(){throw new TypeError("WritableStreamDefaultController cannot be constructed explicitly")}return e.prototype.error=function(e){if(!1===Ge(this))throw new TypeError("WritableStreamDefaultController.prototype.error can only be used on a WritableStreamDefaultController");var t=this._controlledWritableStream._state;"writable"===t&&at(this,e)},e.prototype[he]=function(e){var t=this._abortAlgorithm(e);return Qe(this),t},e.prototype[fe]=function(){ce(this)},e}();function Ge(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledWritableStream")}function Ye(e,t,r,n,i,a,o,s){t._controlledWritableStream=e,e._writableStreamController=t,t._queue=void 0,t._queueTotalSize=void 0,ce(t),t._started=!1,t._strategySizeAlgorithm=s,t._strategyHWM=o,t._writeAlgorithm=n,t._closeAlgorithm=i,t._abortAlgorithm=a;var u=it(t);Fe(e,u);var l=r(),c=S(l);P(c,(function(){t._started=!0,et(t)}),(function(r){t._started=!0,Ae(e,r)}))}function Xe(e,t,r,n){var i=Object.create(He.prototype);function a(){return f(t,"start",[i])}var o=h(t,"write",1,[i]),s=h(t,"close",0,[]),u=h(t,"abort",1,[]);Ye(e,i,a,o,s,u,r,n)}function Qe(e){e._writeAlgorithm=void 0,e._closeAlgorithm=void 0,e._abortAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function Ke(e){ue(e,"close",0),et(e)}function Je(e,t){try{return e._strategySizeAlgorithm(t)}catch(t){return tt(e,t),1}}function $e(e){return e._strategyHWM-e._queueTotalSize}function Ze(e,t,r){var n={chunk:t};try{ue(e,n,r)}catch(t){return void tt(e,t)}var i=e._controlledWritableStream;if(!1===Re(i)&&"writable"===i._state){var a=it(e);Fe(i,a)}et(e)}function et(e){var t=e._controlledWritableStream;if(!1!==e._started&&void 0===t._inFlightWriteRequest){var r=t._state;if("erroring"!==r){if(0!==e._queue.length){var n=le(e);"close"===n?rt(e):nt(e,n.chunk)}}else ke(t)}}function tt(e,t){"writable"===e._controlledWritableStream._state&&at(e,t)}function rt(e){var t=e._controlledWritableStream;Oe(t),se(e);var r=e._closeAlgorithm();Qe(e),P(r,(function(){Ce(t)}),(function(e){Te(t,e)}))}function nt(e,t){var r=e._controlledWritableStream;Le(r);var n=e._writeAlgorithm(t);P(n,(function(){xe(r);var t=r._state;if(se(e),!1===Re(r)&&"writable"===t){var n=it(e);Fe(r,n)}et(e)}),(function(t){"writable"===r._state&&Qe(e),Pe(r,t)}))}function it(e){var t=$e(e);return t<=0}function at(e,t){var r=e._controlledWritableStream;Qe(e),Se(r,t)}function ot(e){return new TypeError("WritableStream.prototype."+e+" can only be used on a WritableStream")}function st(e){return new TypeError("WritableStreamDefaultWriter.prototype."+e+" can only be used on a WritableStreamDefaultWriter")}function ut(e){return new TypeError("Cannot "+e+" a stream using a released writer")}function lt(e){e._closedPromise=A((function(t,r){e._closedPromise_resolve=t,e._closedPromise_reject=r,e._closedPromiseState="pending"}))}function ct(e,t){lt(e),ft(e,t)}function ht(e){lt(e),pt(e)}function ft(e,t){E(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="rejected"}function dt(e,t){ct(e,t)}function pt(e){e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="resolved"}function vt(e){e._readyPromise=A((function(t,r){e._readyPromise_resolve=t,e._readyPromise_reject=r})),e._readyPromiseState="pending"}function gt(e,t){vt(e),mt(e,t)}function yt(e){vt(e),wt(e)}function mt(e,t){E(e._readyPromise),e._readyPromise_reject(t),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="rejected"}function bt(e){vt(e)}function _t(e,t){gt(e,t)}function wt(e){e._readyPromise_resolve(void 0),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="fulfilled"}function At(e){if("object"!==typeof e||null===e)return!1;try{return"boolean"===typeof e.aborted}catch(e){return!1}}var St="undefined"!==typeof DOMException?DOMException:void 0;function kt(e){if("function"!==typeof e&&"object"!==typeof e)return!1;try{return new e,!0}catch(e){return!1}}function xt(){var e=function(e,t){this.message=e||"",this.name=t||"Error",Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)};return e.prototype=Object.create(Error.prototype),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,configurable:!0}),e}var Pt=kt(St)?St:xt();function Ct(e,t,n,i,a,o){var s=G(e),u=pe(t);e._disturbed=!0;var l=!1,c=S(void 0);return A((function(h,f){var d;if(void 0!==o){if(d=function(){var r=new Pt("Aborted","AbortError"),n=[];!1===i&&n.push((function(){return"writable"===t._state?be(t,r):S(void 0)})),!1===a&&n.push((function(){return"readable"===e._state?Nr(e,r):S(void 0)})),_((function(){return Promise.all(n.map((function(e){return e()})))}),!0,r)},!0===o.aborted)return void d();o.addEventListener("abort",d)}function p(){return A((function(e,t){function r(n){n?e():x(v(),r,t)}r(!1)}))}function v(){return!0===l?S(!0):x(u._readyPromise,(function(){return x(te(s),(function(e){return!0===e.done||(c=x(ze(u,e.value),void 0,r),!1)}))}))}if(m(e,s._closedPromise,(function(e){!1===i?_((function(){return be(t,e)}),!0,e):w(!0,e)})),m(t,u._closedPromise,(function(t){!1===a?_((function(){return Nr(e,t)}),!0,t):w(!0,t)})),b(e,s._closedPromise,(function(){!1===n?_((function(){return Ue(u)})):w()})),!0===Re(t)||"closed"===t._state){var g=new TypeError("the destination writable stream closed before all data could be piped to it");!1===a?_((function(){return Nr(e,g)}),!0,g):w(!0,g)}function y(){var e=c;return x(c,(function(){return e!==c?y():void 0}))}function m(e,t,r){"errored"===e._state?r(e._storedError):T(t,r)}function b(e,t,r){"closed"===e._state?r():C(t,r)}function _(e,r,n){function i(){P(e(),(function(){return k(r,n)}),(function(e){return k(!0,e)}))}!0!==l&&(l=!0,"writable"===t._state&&!1===Re(t)?C(y(),i):i())}function w(e,r){!0!==l&&(l=!0,"writable"===t._state&&!1===Re(t)?C(y(),(function(){return k(e,r)})):k(e,r))}function k(e,t){Ve(u),N(s),void 0!==o&&o.removeEventListener("abort",d),e?f(t):h(void 0)}E(p())}))}var Tt=function(){function e(){throw new TypeError}return Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Rt(this))throw Bt("desiredSize");return Nt(this)},enumerable:!0,configurable:!0}),e.prototype.close=function(){if(!1===Rt(this))throw Bt("close");if(!1===jt(this))throw new TypeError("The stream is not in a state that permits close");It(this)},e.prototype.enqueue=function(e){if(!1===Rt(this))throw Bt("enqueue");if(!1===jt(this))throw new TypeError("The stream is not in a state that permits enqueue");return Ft(this,e)},e.prototype.error=function(e){if(!1===Rt(this))throw Bt("error");Mt(this,e)},e.prototype[z]=function(e){ce(this);var t=this._cancelAlgorithm(e);return Lt(this),t},e.prototype[H]=function(){var e=this._controlledReadableStream;if(this._queue.length>0){var t=se(this);return!0===this._closeRequested&&0===this._queue.length?(Lt(this),Dr(e)):Et(this),S(I(t,!1,e._reader._forAuthorCode))}var r=Y(e);return Et(this),r},e}();function Rt(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledReadableStream")}function Et(e){var t=Ot(e);if(!1!==t)if(!0!==e._pulling){e._pulling=!0;var r=e._pullAlgorithm();P(r,(function(){e._pulling=!1,!0===e._pullAgain&&(e._pullAgain=!1,Et(e))}),(function(t){Mt(e,t)}))}else e._pullAgain=!0}function Ot(e){var t=e._controlledReadableStream;if(!1===jt(e))return!1;if(!1===e._started)return!1;if(!0===Mr(t)&&Q(t)>0)return!0;var r=Nt(e);return r>0}function Lt(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function It(e){var t=e._controlledReadableStream;e._closeRequested=!0,0===e._queue.length&&(Lt(e),Dr(t))}function Ft(e,t){var r=e._controlledReadableStream;if(!0===Mr(r)&&Q(r)>0)X(r,t,!1);else{var n=void 0;try{n=e._strategySizeAlgorithm(t)}catch(t){throw Mt(e,t),t}try{ue(e,t,n)}catch(t){throw Mt(e,t),t}}Et(e)}function Mt(e,t){var r=e._controlledReadableStream;"readable"===r._state&&(ce(e),Lt(e),jr(r,t))}function Nt(e){var t=e._controlledReadableStream,r=t._state;return"errored"===r?null:"closed"===r?0:e._strategyHWM-e._queueTotalSize}function Dt(e){return!0!==Ot(e)}function jt(e){var t=e._controlledReadableStream._state;return!1===e._closeRequested&&"readable"===t}function Ut(e,t,r,n,i,a,o){t._controlledReadableStream=e,t._queue=void 0,t._queueTotalSize=void 0,ce(t),t._started=!1,t._closeRequested=!1,t._pullAgain=!1,t._pulling=!1,t._strategySizeAlgorithm=o,t._strategyHWM=a,t._pullAlgorithm=n,t._cancelAlgorithm=i,e._readableStreamController=t;var s=r();P(S(s),(function(){t._started=!0,Et(t)}),(function(e){Mt(t,e)}))}function qt(e,t,r,n){var i=Object.create(Tt.prototype);function a(){return f(t,"start",[i])}var o=h(t,"pull",0,[i]),s=h(t,"cancel",1,[]);Ut(e,i,a,o,s,r,n)}function Bt(e){return new TypeError("ReadableStreamDefaultController.prototype."+e+" can only be used on a ReadableStreamDefaultController")}function Wt(e,t){var r,n,i,a,s,u=G(e),l=!1,c=!1,h=!1,f=A((function(e){s=e}));function d(){if(!0===l)return S(void 0);l=!0;var e=R(te(u),(function(e){l=!1;var t=e.done;if(!0===t)return!1===c&&It(i._readableStreamController),void(!1===h&&It(a._readableStreamController));var r=e.value,n=r,o=r;!1===c&&Ft(i._readableStreamController,n),!1===h&&Ft(a._readableStreamController,o)}));return E(e),S(void 0)}function p(t){if(c=!0,r=t,!0===h){var i=o([r,n]),a=Nr(e,i);s(a)}return f}function v(t){if(h=!0,n=t,!0===c){var i=o([r,n]),a=Nr(e,i);s(a)}return f}function g(){}return i=Lr(g,d,p),a=Lr(g,d,v),T(u._closedPromise,(function(e){Mt(i._readableStreamController,e),Mt(a._readableStreamController,e)})),[i,a]}var Vt=Number.isInteger||function(e){return"number"===typeof e&&isFinite(e)&&Math.floor(e)===e},zt=function(){function e(){throw new TypeError("ReadableStreamBYOBRequest cannot be used directly")}return Object.defineProperty(e.prototype,"view",{get:function(){if(!1===Yt(this))throw _r("view");return this._view},enumerable:!0,configurable:!0}),e.prototype.respond=function(e){if(!1===Yt(this))throw _r("respond");if(void 0===this._associatedReadableByteStreamController)throw new TypeError("This BYOB request has been invalidated");v(this._view.buffer),vr(this._associatedReadableByteStreamController,e)},e.prototype.respondWithNewView=function(e){if(!1===Yt(this))throw _r("respond");if(void 0===this._associatedReadableByteStreamController)throw new TypeError("This BYOB request has been invalidated");if(!ArrayBuffer.isView(e))throw new TypeError("You can only respond with array buffer views");v(e.buffer),gr(this._associatedReadableByteStreamController,e)},e}(),Ht=function(){function e(){throw new TypeError("ReadableByteStreamController constructor cannot be used directly")}return Object.defineProperty(e.prototype,"byobRequest",{get:function(){if(!1===Gt(this))throw wr("byobRequest");if(void 0===this._byobRequest&&this._pendingPullIntos.length>0){var e=this._pendingPullIntos.peek(),t=new Uint8Array(e.buffer,e.byteOffset+e.bytesFilled,e.byteLength-e.bytesFilled),r=Object.create(zt.prototype);br(r,this,t),this._byobRequest=r}return this._byobRequest},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Gt(this))throw wr("desiredSize");return pr(this)},enumerable:!0,configurable:!0}),e.prototype.close=function(){if(!1===Gt(this))throw wr("close");if(!0===this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");var e=this._controlledReadableByteStream._state;if("readable"!==e)throw new TypeError("The stream (in "+e+" state) is not in the readable state and cannot be closed");hr(this)},e.prototype.enqueue=function(e){if(!1===Gt(this))throw wr("enqueue");if(!0===this._closeRequested)throw new TypeError("stream is closed or draining");var t=this._controlledReadableByteStream._state;if("readable"!==t)throw new TypeError("The stream (in "+t+" state) is not in the readable state and cannot be enqueued to");if(!ArrayBuffer.isView(e))throw new TypeError("You can only enqueue array buffer views when using a ReadableByteStreamController");v(e.buffer),fr(this,e)},e.prototype.error=function(e){if(!1===Gt(this))throw wr("error");dr(this,e)},e.prototype[z]=function(e){if(this._pendingPullIntos.length>0){var t=this._pendingPullIntos.peek();t.bytesFilled=0}ce(this);var r=this._cancelAlgorithm(e);return cr(this),r},e.prototype[H]=function(){var e=this._controlledReadableByteStream;if(this._queueTotalSize>0){var t=this._queue.shift();this._queueTotalSize-=t.byteLength,tr(this);var r=void 0;try{r=new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}catch(e){return k(e)}return S(I(r,!1,e._reader._forAuthorCode))}var n=this._autoAllocateChunkSize;if(void 0!==n){var i=void 0;try{i=new ArrayBuffer(n)}catch(e){return k(e)}var a={buffer:i,byteOffset:0,byteLength:n,bytesFilled:0,elementSize:1,ctor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(a)}var o=Y(e);return Xt(this),o},e}();function Gt(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledReadableByteStream")}function Yt(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_associatedReadableByteStreamController")}function Xt(e){var t=lr(e);if(!1!==t)if(!0!==e._pulling){e._pulling=!0;var r=e._pullAlgorithm();P(r,(function(){e._pulling=!1,!0===e._pullAgain&&(e._pullAgain=!1,Xt(e))}),(function(t){dr(e,t)}))}else e._pullAgain=!0}function Qt(e){rr(e),e._pendingPullIntos=new L}function Kt(e,t){var r=!1;"closed"===e._state&&(r=!0);var n=Jt(t);"default"===t.readerType?X(e,n,r):kr(e,n,r)}function Jt(e){var t=e.bytesFilled,r=e.elementSize;return new e.ctor(e.buffer,e.byteOffset,t/r)}function $t(e,t,r,n){e._queue.push({buffer:t,byteOffset:r,byteLength:n}),e._queueTotalSize+=n}function Zt(e,t){var r=t.elementSize,n=t.bytesFilled-t.bytesFilled%r,i=Math.min(e._queueTotalSize,t.byteLength-t.bytesFilled),a=t.bytesFilled+i,o=a-a%r,u=i,l=!1;o>n&&(u=o-t.bytesFilled,l=!0);var c=e._queue;while(u>0){var h=c.peek(),f=Math.min(u,h.byteLength),d=t.byteOffset+t.bytesFilled;s(t.buffer,d,h.buffer,h.byteOffset,f),h.byteLength===f?c.shift():(h.byteOffset+=f,h.byteLength-=f),e._queueTotalSize-=f,er(e,f,t),u-=f}return l}function er(e,t,r){rr(e),r.bytesFilled+=t}function tr(e){0===e._queueTotalSize&&!0===e._closeRequested?(cr(e),Dr(e._controlledReadableByteStream)):Xt(e)}function rr(e){void 0!==e._byobRequest&&(e._byobRequest._associatedReadableByteStreamController=void 0,e._byobRequest._view=void 0,e._byobRequest=void 0)}function nr(e){while(e._pendingPullIntos.length>0){if(0===e._queueTotalSize)return;var t=e._pendingPullIntos.peek();!0===Zt(e,t)&&(ur(e),Kt(e._controlledReadableByteStream,t))}}function ir(e,t){var r=e._controlledReadableByteStream,n=1;t.constructor!==DataView&&(n=t.constructor.BYTES_PER_ELEMENT);var i=t.constructor,a=p(t.buffer),o={buffer:a,byteOffset:t.byteOffset,byteLength:t.byteLength,bytesFilled:0,elementSize:n,ctor:i,readerType:"byob"};if(e._pendingPullIntos.length>0)return e._pendingPullIntos.push(o),Sr(r);if("closed"===r._state){var s=new i(o.buffer,o.byteOffset,0);return S(I(s,!0,r._reader._forAuthorCode))}if(e._queueTotalSize>0){if(!0===Zt(e,o)){var u=Jt(o);return tr(e),S(I(u,!1,r._reader._forAuthorCode))}if(!0===e._closeRequested){var l=new TypeError("Insufficient bytes to fill elements in the given buffer");return dr(e,l),k(l)}}e._pendingPullIntos.push(o);var c=Sr(r);return Xt(e),c}function ar(e,t){t.buffer=p(t.buffer);var r=e._controlledReadableByteStream;if(!0===Pr(r))while(xr(r)>0){var n=ur(e);Kt(r,n)}}function or(e,t,r){if(r.bytesFilled+t>r.byteLength)throw new RangeError("bytesWritten out of range");if(er(e,t,r),!(r.bytesFilled<r.elementSize)){ur(e);var n=r.bytesFilled%r.elementSize;if(n>0){var i=r.byteOffset+r.bytesFilled,a=r.buffer.slice(i-n,i);$t(e,a,0,a.byteLength)}r.buffer=p(r.buffer),r.bytesFilled-=n,Kt(e._controlledReadableByteStream,r),nr(e)}}function sr(e,t){var r=e._pendingPullIntos.peek(),n=e._controlledReadableByteStream;if("closed"===n._state){if(0!==t)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");ar(e,r)}else or(e,t,r);Xt(e)}function ur(e){var t=e._pendingPullIntos.shift();return rr(e),t}function lr(e){var t=e._controlledReadableByteStream;if("readable"!==t._state)return!1;if(!0===e._closeRequested)return!1;if(!1===e._started)return!1;if(!0===K(t)&&Q(t)>0)return!0;if(!0===Pr(t)&&xr(t)>0)return!0;var r=pr(e);return r>0}function cr(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0}function hr(e){var t=e._controlledReadableByteStream;if(e._queueTotalSize>0)e._closeRequested=!0;else{if(e._pendingPullIntos.length>0){var r=e._pendingPullIntos.peek();if(r.bytesFilled>0){var n=new TypeError("Insufficient bytes to fill elements in the given buffer");throw dr(e,n),n}}cr(e),Dr(t)}}function fr(e,t){var r=e._controlledReadableByteStream,n=t.buffer,i=t.byteOffset,a=t.byteLength,o=p(n);if(!0===K(r))if(0===Q(r))$t(e,o,i,a);else{var s=new Uint8Array(o,i,a);X(r,s,!1)}else!0===Pr(r)?($t(e,o,i,a),nr(e)):$t(e,o,i,a);Xt(e)}function dr(e,t){var r=e._controlledReadableByteStream;"readable"===r._state&&(Qt(e),ce(e),cr(e),jr(r,t))}function pr(e){var t=e._controlledReadableByteStream,r=t._state;return"errored"===r?null:"closed"===r?0:e._strategyHWM-e._queueTotalSize}function vr(e,t){if(t=Number(t),!1===u(t))throw new RangeError("bytesWritten must be a finite");sr(e,t)}function gr(e,t){var r=e._pendingPullIntos.peek();if(r.byteOffset+r.bytesFilled!==t.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(r.byteLength!==t.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");r.buffer=t.buffer,sr(e,t.byteLength)}function yr(e,t,r,n,i,a,o){t._controlledReadableByteStream=e,t._pullAgain=!1,t._pulling=!1,t._byobRequest=void 0,t._queue=t._queueTotalSize=void 0,ce(t),t._closeRequested=!1,t._started=!1,t._strategyHWM=g(a),t._pullAlgorithm=n,t._cancelAlgorithm=i,t._autoAllocateChunkSize=o,t._pendingPullIntos=new L,e._readableStreamController=t;var s=r();P(S(s),(function(){t._started=!0,Xt(t)}),(function(e){dr(t,e)}))}function mr(e,t,r){var n=Object.create(Ht.prototype);function i(){return f(t,"start",[n])}var a=h(t,"pull",0,[n]),o=h(t,"cancel",1,[]),s=t.autoAllocateChunkSize;if(void 0!==s&&(s=Number(s),!1===Vt(s)||s<=0))throw new RangeError("autoAllocateChunkSize must be a positive integer");yr(e,n,i,a,o,r,s)}function br(e,t,r){e._associatedReadableByteStreamController=t,e._view=r}function _r(e){return new TypeError("ReadableStreamBYOBRequest.prototype."+e+" can only be used on a ReadableStreamBYOBRequest")}function wr(e){return new TypeError("ReadableByteStreamController.prototype."+e+" can only be used on a ReadableByteStreamController")}function Ar(e,t){void 0===t&&(t=!1);var r=new Cr(e);return r._forAuthorCode=t,r}function Sr(e){var t=A((function(t,r){var n={_resolve:t,_reject:r};e._reader._readIntoRequests.push(n)}));return t}function kr(e,t,r){var n=e._reader,i=n._readIntoRequests.shift();i._resolve(I(t,r,n._forAuthorCode))}function xr(e){return e._reader._readIntoRequests.length}function Pr(e){var t=e._reader;return void 0!==t&&!!Tr(t)}var Cr=function(){function e(e){if(!Fr(e))throw new TypeError("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(!1===Gt(e._readableStreamController))throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");if(Mr(e))throw new TypeError("This stream has already been locked for exclusive reading by another reader");F(this,e),this._readIntoRequests=new L}return Object.defineProperty(e.prototype,"closed",{get:function(){return Tr(this)?this._closedPromise:k(Er("closed"))},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return Tr(this)?void 0===this._ownerReadableStream?k(D("cancel")):M(this,e):k(Er("cancel"))},e.prototype.read=function(e){return Tr(this)?void 0===this._ownerReadableStream?k(D("read from")):ArrayBuffer.isView(e)?(v(e.buffer),0===e.byteLength?k(new TypeError("view must have non-zero byteLength")):Rr(this,e)):k(new TypeError("view must be an array buffer view")):k(Er("read"))},e.prototype.releaseLock=function(){if(!Tr(this))throw Er("releaseLock");if(void 0!==this._ownerReadableStream){if(this._readIntoRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");N(this)}},e}();function Tr(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readIntoRequests")}function Rr(e,t){var r=e._ownerReadableStream;return r._disturbed=!0,"errored"===r._state?k(r._storedError):ir(r._readableStreamController,t)}function Er(e){return new TypeError("ReadableStreamBYOBReader.prototype."+e+" can only be used on a ReadableStreamBYOBReader")}var Or=function(){function e(e,t){void 0===e&&(e={}),void 0===t&&(t={}),Ir(this);var r=t.size,n=t.highWaterMark,i=e.type,a=String(i);if("bytes"===a){if(void 0!==r)throw new RangeError("The strategy for a byte stream cannot have a size function");void 0===n&&(n=0),n=g(n),mr(this,e,n)}else{if(void 0!==i)throw new RangeError("Invalid type is specified");var o=y(r);void 0===n&&(n=1),n=g(n),qt(this,e,n,o)}}return Object.defineProperty(e.prototype,"locked",{get:function(){if(!1===Fr(this))throw Ur("locked");return Mr(this)},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return!1===Fr(this)?k(Ur("cancel")):!0===Mr(this)?k(new TypeError("Cannot cancel a stream that already has a reader")):Nr(this,e)},e.prototype.getReader=function(e){var t=(void 0===e?{}:e).mode;if(!1===Fr(this))throw Ur("getReader");if(void 0===t)return G(this,!0);if(t=String(t),"byob"===t)return Ar(this,!0);throw new RangeError("Invalid mode is specified")},e.prototype.pipeThrough=function(e,t){var r=e.writable,n=e.readable,i=void 0===t?{}:t,a=i.preventClose,o=i.preventAbort,s=i.preventCancel,u=i.signal;if(!1===Fr(this))throw Ur("pipeThrough");if(!1===ye(r))throw new TypeError("writable argument to pipeThrough must be a WritableStream");if(!1===Fr(n))throw new TypeError("readable argument to pipeThrough must be a ReadableStream");if(a=Boolean(a),o=Boolean(o),s=Boolean(s),void 0!==u&&!At(u))throw new TypeError("ReadableStream.prototype.pipeThrough's signal option must be an AbortSignal");if(!0===Mr(this))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(!0===me(r))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");var l=Ct(this,r,a,o,s,u);return E(l),n},e.prototype.pipeTo=function(e,t){var r=void 0===t?{}:t,n=r.preventClose,i=r.preventAbort,a=r.preventCancel,o=r.signal;return!1===Fr(this)?k(Ur("pipeTo")):!1===ye(e)?k(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream")):(n=Boolean(n),i=Boolean(i),a=Boolean(a),void 0===o||At(o)?!0===Mr(this)?k(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):!0===me(e)?k(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):Ct(this,e,n,i,a,o):k(new TypeError("ReadableStream.prototype.pipeTo's signal option must be an AbortSignal")))},e.prototype.tee=function(){if(!1===Fr(this))throw Ur("tee");var e=Wt(this);return o(e)},e.prototype.getIterator=function(e){var t=(void 0===e?{}:e).preventCancel,r=void 0!==t&&t;if(!1===Fr(this))throw Ur("getIterator");return ie(this,r)},e}();function Lr(e,t,r,n,i){void 0===n&&(n=1),void 0===i&&(i=function(){return 1});var a=Object.create(Or.prototype);Ir(a);var o=Object.create(Tt.prototype);return Ut(a,o,e,t,r,n,i),a}function Ir(e){e._state="readable",e._reader=void 0,e._storedError=void 0,e._disturbed=!1}function Fr(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readableStreamController")}function Mr(e){return void 0!==e._reader}function Nr(e,t){if(e._disturbed=!0,"closed"===e._state)return S(void 0);if("errored"===e._state)return k(e._storedError);Dr(e);var n=e._readableStreamController[z](t);return R(n,r)}function Dr(e){e._state="closed";var t=e._reader;void 0!==t&&(ee(t)&&(t._readRequests.forEach((function(e){e._resolve(I(void 0,!0,t._forAuthorCode))})),t._readRequests=new L),V(t))}function jr(e,t){e._state="errored",e._storedError=t;var r=e._reader;void 0!==r&&(ee(r)?(r._readRequests.forEach((function(e){e._reject(t)})),r._readRequests=new L):(r._readIntoRequests.forEach((function(e){e._reject(t)})),r._readIntoRequests=new L),B(r,t))}function Ur(e){return new TypeError("ReadableStream.prototype."+e+" can only be used on a ReadableStream")}"symbol"===typeof t.asyncIterator&&Object.defineProperty(Or.prototype,t.asyncIterator,{value:Or.prototype.getIterator,enumerable:!1,writable:!0,configurable:!0});var qr=function(){function e(e){var t=e.highWaterMark;this.highWaterMark=t}return e.prototype.size=function(e){return e.byteLength},e}(),Br=function(){function e(e){var t=e.highWaterMark;this.highWaterMark=t}return e.prototype.size=function(){return 1},e}(),Wr=function(){function e(e,t,r){void 0===e&&(e={}),void 0===t&&(t={}),void 0===r&&(r={});var n=t.size,i=t.highWaterMark,a=r.size,o=r.highWaterMark,s=e.writableType;if(void 0!==s)throw new RangeError("Invalid writable type specified");var u=y(n);void 0===i&&(i=1),i=g(i);var l=e.readableType;if(void 0!==l)throw new RangeError("Invalid readable type specified");var c,h=y(a);void 0===o&&(o=0),o=g(o);var d=A((function(e){c=e}));Vr(this,d,i,u,o,h),Jr(this,e);var p=f(e,"start",[this._transformStreamController]);c(p)}return Object.defineProperty(e.prototype,"readable",{get:function(){if(!1===zr(this))throw ln("readable");return this._readable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"writable",{get:function(){if(!1===zr(this))throw ln("writable");return this._writable},enumerable:!0,configurable:!0}),e}();function Vr(e,t,r,n,i,a){function o(){return t}function s(t){return nn(e,t)}function u(t){return an(e,t)}function l(){return on(e)}function c(){return sn(e)}function h(t){return Gr(e,t),S(void 0)}e._writable=ve(o,s,l,u,r,n),e._readable=Lr(o,c,h,i,a),e._backpressure=void 0,e._backpressureChangePromise=void 0,e._backpressureChangePromise_resolve=void 0,Yr(e,!0),e._transformStreamController=void 0}function zr(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_transformStreamController")}function Hr(e,t){Mt(e._readable._readableStreamController,t),Gr(e,t)}function Gr(e,t){$r(e._transformStreamController),tt(e._writable._writableStreamController,t),!0===e._backpressure&&Yr(e,!1)}function Yr(e,t){void 0!==e._backpressureChangePromise&&e._backpressureChangePromise_resolve(),e._backpressureChangePromise=A((function(t){e._backpressureChangePromise_resolve=t})),e._backpressure=t}var Xr=function(){function e(){throw new TypeError("TransformStreamDefaultController instances cannot be created directly")}return Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Qr(this))throw un("desiredSize");var e=this._controlledTransformStream._readable._readableStreamController;return Nt(e)},enumerable:!0,configurable:!0}),e.prototype.enqueue=function(e){if(!1===Qr(this))throw un("enqueue");Zr(this,e)},e.prototype.error=function(e){if(!1===Qr(this))throw un("error");en(this,e)},e.prototype.terminate=function(){if(!1===Qr(this))throw un("terminate");rn(this)},e}();function Qr(e){return!!a(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledTransformStream")}function Kr(e,t,r,n){t._controlledTransformStream=e,e._transformStreamController=t,t._transformAlgorithm=r,t._flushAlgorithm=n}function Jr(e,t){var r=Object.create(Xr.prototype),n=function(e){try{return Zr(r,e),S(void 0)}catch(e){return k(e)}},i=t.transform;if(void 0!==i){if("function"!==typeof i)throw new TypeError("transform is not a method");n=function(e){return d(i,t,[e,r])}}var a=h(t,"flush",0,[r]);Kr(e,r,n,a)}function $r(e){e._transformAlgorithm=void 0,e._flushAlgorithm=void 0}function Zr(e,t){var r=e._controlledTransformStream,n=r._readable._readableStreamController;if(!1===jt(n))throw new TypeError("Readable side is not in a state that permits enqueue");try{Ft(n,t)}catch(e){throw Gr(r,e),r._readable._storedError}var i=Dt(n);i!==r._backpressure&&Yr(r,!0)}function en(e,t){Hr(e._controlledTransformStream,t)}function tn(e,t){var r=e._transformAlgorithm(t);return R(r,void 0,(function(t){throw Hr(e._controlledTransformStream,t),t}))}function rn(e){var t=e._controlledTransformStream,r=t._readable._readableStreamController;!0===jt(r)&&It(r);var n=new TypeError("TransformStream terminated");Gr(t,n)}function nn(e,t){var r=e._transformStreamController;if(!0===e._backpressure){var n=e._backpressureChangePromise;return R(n,(function(){var n=e._writable,i=n._state;if("erroring"===i)throw n._storedError;return tn(r,t)}))}return tn(r,t)}function an(e,t){return Hr(e,t),S(void 0)}function on(e){var t=e._readable,r=e._transformStreamController,n=r._flushAlgorithm();return $r(r),R(n,(function(){if("errored"===t._state)throw t._storedError;var e=t._readableStreamController;!0===jt(e)&&It(e)}),(function(r){throw Hr(e,r),t._storedError}))}function sn(e){return Yr(e,!1),e._backpressureChangePromise}function un(e){return new TypeError("TransformStreamDefaultController.prototype."+e+" can only be used on a TransformStreamDefaultController")}function ln(e){return new TypeError("TransformStream.prototype."+e+" can only be used on a TransformStream")}e.ByteLengthQueuingStrategy=qr,e.CountQueuingStrategy=Br,e.ReadableStream=Or,e.TransformStream=Wr,e.WritableStream=de,Object.defineProperty(e,"__esModule",{value:!0})}(t)},function(e,t,r){r(147),r(118),r(77),r(120),r=r(43),e.exports=r.Map},function(e,t,r){"use strict";var n=r(148);r=r(152);e.exports=n("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),r)},function(e,t,r){"use strict";var n=r(10),i=r(11),a=r(52),o=r(29),s=r(149),u=r(104),l=r(126),c=r(22),h=r(14),f=r(97),d=r(85),p=r(151);e.exports=function(e,t,r){function v(e){var t=x[e];o(x,e,"add"==e?function(e){return t.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(A&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return A&&!c(e)?void 0:t.call(this,0===e?0:e)}:"has"==e?function(e){return!(A&&!c(e))&&t.call(this,0===e?0:e)}:function(e,r){return t.call(this,0===e?0:e,r),this})}var g,y,m,b,_,w=-1!==e.indexOf("Map"),A=-1!==e.indexOf("Weak"),S=w?"set":"add",k=i[e],x=k&&k.prototype,P=k,C={};return a(e,"function"!=typeof k||!(A||x.forEach&&!h((function(){(new k).entries().next()}))))?(P=r.getConstructor(t,e,w,S),s.REQUIRED=!0):a(e,!0)&&(y=(g=new P)[S](A?{}:-0,1)!=g,m=h((function(){g.has(1)})),b=f((function(e){new k(e)})),_=!A&&h((function(){for(var e=new k,t=5;t--;)e[S](t,t);return!e.has(-0)})),b||(((P=t((function(t,r){return l(t,P,e),t=p(new k,t,P),null!=r&&u(r,t[S],t,w),t}))).prototype=x).constructor=P),(m||_)&&(v("delete"),v("has"),w&&v("get")),(_||y)&&v(S),A&&x.clear&&delete x.clear),C[e]=P,n({global:!0,forced:P!=k},C),d(P,e),A||r.setStrong(P,e,w),P}},function(e,t,r){function n(e){s(e,c,{value:{objectID:"O"+ ++h,weakData:{}}})}var i=r(39),a=r(22),o=r(23),s=r(27).f,u=r(38),l=r(150),c=u("meta"),h=0,f=Object.isExtensible||function(){return!0},d=e.exports={REQUIRED:!1,fastKey:function(e,t){if(!a(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!o(e,c)){if(!f(e))return"F";if(!t)return"E";n(e)}return e[c].objectID},getWeakData:function(e,t){if(!o(e,c)){if(!f(e))return!0;if(!t)return!1;n(e)}return e[c].weakData},onFreeze:function(e){return l&&d.REQUIRED&&f(e)&&!o(e,c)&&n(e),e}};i[c]=!0},function(e,t,r){r=r(14),e.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},function(e,t,r){var n=r(22),i=r(87);e.exports=function(e,t,r){var a,o;return i&&"function"==typeof(a=t.constructor)&&a!==r&&n(o=a.prototype)&&o!==r.prototype&&i(e,o),e}},function(e,t,r){"use strict";var n=r(27).f,i=r(71),a=r(124),o=r(62),s=r(126),u=r(104),l=r(79),c=r(125),h=r(13),f=r(149).fastKey,d=(r=r(33),r.set),p=r.getterFor;e.exports={getConstructor:function(e,t,r,l){function c(e,t,r){var n,i=g(e),a=y(e,t);return a?a.value=r:(i.last=a={index:n=f(t,!0),key:t,value:r,previous:r=i.last,next:void 0,removed:!1},i.first||(i.first=a),r&&(r.next=a),h?i.size++:e.size++,"F"!==n&&(i.index[n]=a)),e}var v=e((function(e,n){s(e,v,t),d(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),h||(e.size=0),null!=n&&u(n,e[l],e,r)})),g=p(t),y=function(e,t){var r,n=g(e);e=f(t);if("F"!==e)return n.index[e];for(r=n.first;r;r=r.next)if(r.key==t)return r};return a(v.prototype,{clear:function(){for(var e=g(this),t=e.index,r=e.first;r;)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete t[r.index],r=r.next;e.first=e.last=void 0,h?e.size=0:this.size=0},delete:function(e){var t,r=g(this),n=y(this,e);return n&&(t=n.next,e=n.previous,delete r.index[n.index],n.removed=!0,e&&(e.next=t),t&&(t.previous=e),r.first==n&&(r.first=t),r.last==n&&(r.last=e),h?r.size--:this.size--),!!n},forEach:function(e){for(var t,r=g(this),n=o(e,1<arguments.length?arguments[1]:void 0,3);t=t?t.next:r.first;)for(n(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!y(this,e)}}),a(v.prototype,r?{get:function(e){return e=y(this,e),e&&e.value},set:function(e,t){return c(this,0===e?0:e,t)}}:{add:function(e){return c(this,e=0===e?0:e,e)}}),h&&n(v.prototype,"size",{get:function(){return g(this).size}}),v},setStrong:function(e,t,r){var n=t+" Iterator",i=p(t),a=p(n);l(e,t,(function(e,t){d(this,{type:n,target:e,state:i(e),kind:t,last:void 0})}),(function(){for(var e=a(this),t=e.kind,r=e.last;r&&r.removed;)r=r.previous;return e.target&&(e.last=r=r?r.next:e.state.first)?"keys"==t?{value:r.key,done:!1}:"values"==t?{value:r.value,done:!1}:{value:[r.key,r.value],done:!1}:{value:e.target=void 0,done:!0}}),r?"entries":"values",!r,!0),c(t)}}},function(e,t,r){r(154),r(118),r(77),r(120),r=r(43),e.exports=r.Set},function(e,t,r){"use strict";var n=r(148);r=r(152);e.exports=n("Set",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),r)},function(e,t,r){r(118),r(156),r(120),r=r(43),e.exports=r.WeakMap},function(e,t,r){"use strict";var n,i,a,o,s,u=r(11),l=r(124),c=r(149),h=r(148),f=r(157),d=r(22),p=r(33).enforce,v=r(34),g=(r=!u.ActiveXObject&&"ActiveXObject"in u,Object.isExtensible);u=function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},h=e.exports=h("WeakMap",u,f);v&&r&&(n=f.getConstructor(u,"WeakMap",!0),c.REQUIRED=!0,h=h.prototype,i=h.delete,a=h.has,o=h.get,s=h.set,l(h,{delete:function(e){if(!d(e)||g(e))return i.call(this,e);var t=p(this);return t.frozen||(t.frozen=new n),i.call(this,e)||t.frozen.delete(e)},has:function(e){if(!d(e)||g(e))return a.call(this,e);var t=p(this);return t.frozen||(t.frozen=new n),a.call(this,e)||t.frozen.has(e)},get:function(e){if(!d(e)||g(e))return o.call(this,e);var t=p(this);return t.frozen||(t.frozen=new n),a.call(this,e)?o.call(this,e):t.frozen.get(e)},set:function(e,t){var r;return d(e)&&!g(e)?((r=p(this)).frozen||(r.frozen=new n),a.call(this,e)?s.call(this,e,t):r.frozen.set(e,t)):s.call(this,e,t),this}}))},function(e,t,r){"use strict";function n(e){return e.frozen||(e.frozen=new m)}function i(e,t){return v(e.entries,(function(e){return e[0]===t}))}var a=r(124),o=r(149).getWeakData,s=r(28),u=r(22),l=r(126),c=r(104),h=r(158),f=r(23),d=(r=r(33),r.set),p=r.getterFor,v=h.find,g=h.findIndex,y=0,m=function(){this.entries=[]};m.prototype={get:function(e){if(e=i(this,e),e)return e[1]},has:function(e){return!!i(this,e)},set:function(e,t){var r=i(this,e);r?r[1]=t:this.entries.push([e,t])},delete:function(e){var t=g(this.entries,(function(t){return t[0]===e}));return~t&&this.entries.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,r,i){function h(e,t,r){var i=g(e),a=o(s(t),!0);return!0===a?n(i).set(t,r):a[i.id]=r,e}var v=e((function(e,n){l(e,v,t),d(e,{type:t,id:y++,frozen:void 0}),null!=n&&c(n,e[i],e,r)})),g=p(t);return a(v.prototype,{delete:function(e){var t=g(this);if(!u(e))return!1;var r=o(e);return!0===r?n(t).delete(e):r&&f(r,t.id)&&delete r[t.id]},has:function(e){var t=g(this);if(!u(e))return!1;var r=o(e);return!0===r?n(t).has(e):r&&f(r,t.id)}}),a(v.prototype,r?{get:function(e){var t=g(this);if(u(e)){var r=o(e);return!0===r?n(t).get(e):r?r[t.id]:void 0}},set:function(e,t){return h(this,e,t)}}:{add:function(e){return h(this,e,!0)}}),v}}},function(e,t,r){var n=r(62),i=r(18),a=r(83),o=r(47),s=r(159),u=[].push;r=function(e){var t=1==e,r=2==e,l=3==e,c=4==e,h=6==e,f=5==e||h;return function(d,p,v,g){for(var y,m,b=a(d),_=i(b),w=n(p,v,3),A=o(_.length),S=0,k=(g=g||s,t?g(d,A):r?g(d,0):void 0);S<A;S++)if((f||S in _)&&(m=w(y=_[S],S,b),e))if(t)k[S]=m;else if(m)switch(e){case 3:return!0;case 5:return y;case 6:return S;case 2:u.call(k,y)}else if(c)return!1;return h?-1:l||c?c:k}};e.exports={forEach:r(0),map:r(1),filter:r(2),some:r(3),every:r(4),find:r(5),findIndex:r(6)}},function(e,t,r){var n=r(22),i=r(160),a=r(57)("species");e.exports=function(e,t){var r;return new(void 0===(r=i(e)&&("function"==typeof(r=e.constructor)&&(r===Array||i(r.prototype))||n(r)&&null===(r=r[a]))?void 0:r)?Array:r)(0===t?0:t)}},function(e,t,r){var n=r(19);e.exports=Array.isArray||function(e){return"Array"==n(e)}},function(e,t,r){r(118),r(162),r(120),r=r(43),e.exports=r.WeakSet},function(e,t,r){"use strict";r(148)("WeakSet",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),r(157))},function(e,t,r){r(164),r=r(61),e.exports=r("String","codePointAt")},function(e,t,r){"use strict";var n=r(10),i=r(78).codeAt;n({target:"String",proto:!0},{codePointAt:function(e){return i(this,e)}})},function(e,t,r){r(166),r=r(43),e.exports=r.String.fromCodePoint},function(e,t,r){var n=r(10),i=r(49),a=String.fromCharCode;r=String.fromCodePoint;n({target:"String",stat:!0,forced:!!r&&1!=r.length},{fromCodePoint:function(e){for(var t,r=[],n=arguments.length,o=0;o<n;){if(t=+arguments[o++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");r.push(t<65536?a(t):a(55296+((t-=65536)>>10),t%1024+56320))}return r.join("")}})},function(e,t,r){r(168),r(118),r(170),r(174),r(175),r(176),r(177),r(178),r(179),r(180),r(181),r(182),r(183),r(184),r(185),r(186),r(187),r(188),r(189),r=r(43),e.exports=r.Symbol},function(e,t,r){"use strict";var n=r(10),i=r(14),a=r(160),o=r(22),s=r(83),u=r(47),l=r(93),c=r(159),h=r(169),f=r(57),d=(r=r(135),f("isConcatSpreadable")),p=9007199254740991,v="Maximum allowed index exceeded";i=51<=r||!i((function(){var e=[];return e[d]=!1,e.concat()[0]!==e})),h=h("concat");n({target:"Array",proto:!0,forced:!i||!h},{concat:function(e){for(var t,r,n,i=s(this),h=c(i,0),f=0,g=-1,y=arguments.length;g<y;g++)if(function(e){if(!o(e))return!1;var t=e[d];return void 0!==t?!!t:a(e)}(n=-1===g?i:arguments[g])){if(r=u(n.length),p<f+r)throw TypeError(v);for(t=0;t<r;t++,f++)t in n&&l(h,f,n[t])}else{if(p<=f)throw TypeError(v);l(h,f++,n)}return h.length=f,h}})},function(e,t,r){var n=r(14),i=r(57),a=r(135),o=i("species");e.exports=function(e){return 51<=a||!n((function(){var t=[];return(t.constructor={})[o]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},function(e,t,r){"use strict";function n(e,t){var r=Z[e]=w(Y[V]);return z(r,{type:W,tag:e,description:t}),l||(r.description=t),r}function i(e,t){g(e);var r=m(t);t=A(r).concat(ue(r));return q(t,(function(t){l&&!se.call(r,t)||oe(e,t,r[t])})),e}var a=r(10),o=r(11),s=r(42),u=r(37),l=r(13),c=r(58),h=r(59),f=r(14),d=r(23),p=r(160),v=r(22),g=r(28),y=r(83),m=r(17),b=r(21),_=r(16),w=r(71),A=r(73),S=r(44),k=r(171),x=r(51),P=r(12),C=r(27),T=r(15),R=r(26),E=r(29),O=r(36),L=r(35),I=r(39),F=r(38),M=r(57),N=r(172),D=r(173),j=r(85),U=r(33),q=r(158).forEach,B=L("hidden"),W="Symbol",V="prototype",z=(L=M("toPrimitive"),U.set),H=U.getterFor(W),G=Object[V],Y=o.Symbol,X=s("JSON","stringify"),Q=P.f,K=C.f,J=k.f,$=T.f,Z=O("symbols"),ee=O("op-symbols"),te=O("string-to-symbol-registry"),re=O("symbol-to-string-registry"),ne=(O=O("wks"),o=o.QObject,!o||!o[V]||!o[V].findChild),ie=l&&f((function(){return 7!=w(K({},"a",{get:function(){return K(this,"a",{value:7}).a}})).a}))?function(e,t,r){var n=Q(G,t);n&&delete G[t],K(e,t,r),n&&e!==G&&K(G,t,n)}:K,ae=h?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof Y},oe=function(e,t,r){return e===G&&oe(ee,t,r),g(e),t=b(t,!0),g(r),d(Z,t)?(r.enumerable?(d(e,B)&&e[B][t]&&(e[B][t]=!1),r=w(r,{enumerable:_(0,!1)})):(d(e,B)||K(e,B,_(1,{})),e[B][t]=!0),ie(e,t,r)):K(e,t,r)},se=function(e){var t=b(e,!0);e=$.call(this,t);return!(this===G&&d(Z,t)&&!d(ee,t))&&(!(e||!d(this,t)||!d(Z,t)||d(this,B)&&this[B][t])||e)},ue=(o=function(e,t){var r=m(e);e=b(t,!0);if(r!==G||!d(Z,e)||d(ee,e))return t=Q(r,e),!t||!d(Z,e)||d(r,B)&&r[B][e]||(t.enumerable=!0),t},h=function(e){e=J(m(e));var t=[];return q(e,(function(e){d(Z,e)||d(I,e)||t.push(e)})),t},function(e){var t=e===G,r=(e=J(t?ee:m(e)),[]);return q(e,(function(e){!d(Z,e)||t&&!d(G,e)||r.push(Z[e])})),r});c||(E((Y=function(){if(this instanceof Y)throw TypeError("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,t=F(e),r=function(e){this===G&&r.call(ee,e),d(this,B)&&d(this[B],t)&&(this[B][t]=!1),ie(this,t,_(1,e))};return l&&ne&&ie(G,t,{configurable:!0,set:r}),n(t,e)})[V],"toString",(function(){return H(this).tag})),E(Y,"withoutSetter",(function(e){return n(F(e),e)})),T.f=se,C.f=oe,P.f=o,S.f=k.f=h,x.f=ue,N.f=function(e){return n(M(e),e)},l&&(K(Y[V],"description",{configurable:!0,get:function(){return H(this).description}}),u||E(G,"propertyIsEnumerable",se,{unsafe:!0}))),a({global:!0,wrap:!0,forced:!c,sham:!c},{Symbol:Y}),q(A(O),(function(e){D(e)})),a({target:W,stat:!0,forced:!c},{for:function(e){var t=String(e);return d(te,t)?te[t]:(e=Y(t),te[t]=e,re[e]=t,e)},keyFor:function(e){if(!ae(e))throw TypeError(e+" is not a symbol");if(d(re,e))return re[e]},useSetter:function(){ne=!0},useSimple:function(){ne=!1}}),a({target:"Object",stat:!0,forced:!c,sham:!l},{create:function(e,t){return void 0===t?w(e):i(w(e),t)},defineProperty:oe,defineProperties:i,getOwnPropertyDescriptor:o}),a({target:"Object",stat:!0,forced:!c},{getOwnPropertyNames:h,getOwnPropertySymbols:ue}),a({target:"Object",stat:!0,forced:f((function(){x.f(1)}))},{getOwnPropertySymbols:function(e){return x.f(y(e))}}),X&&a({target:"JSON",stat:!0,forced:!c||f((function(){var e=Y();return"[null]"!=X([e])||"{}"!=X({a:e})||"{}"!=X(Object(e))}))},{stringify:function(e,t,r){for(var n,i=[e],a=1;a<arguments.length;)i.push(arguments[a++]);if((v(n=t)||void 0!==e)&&!ae(e))return p(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!ae(t))return t}),i[1]=t,X.apply(null,i)}}),Y[V][L]||R(Y[V],L,Y[V].valueOf),j(Y,W),I[B]=!0},function(e,t,r){var n=r(17),i=r(44).f,a={}.toString,o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return o&&"[object Window]"==a.call(e)?function(e){try{return i(e)}catch(e){return o.slice()}}(e):i(n(e))}},function(e,t,r){r=r(57),t.f=r},function(e,t,r){var n=r(43),i=r(23),a=r(172),o=r(27).f;e.exports=function(e){var t=n.Symbol||(n.Symbol={});i(t,e)||o(t,e,{value:a.f(e)})}},function(e,t,r){r(173)("asyncIterator")},function(e,t,r){"use strict";var n,i,a,o,s,u=r(10),l=r(13),c=r(11),h=r(23),f=r(22),d=r(27).f,p=(r=r(40),c.Symbol);!l||"function"!=typeof p||"description"in p.prototype&&void 0===p().description||(n={},r(i=function(){var e=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),t=this instanceof i?new p(e):void 0===e?p():p(e);return""===e&&(n[t]=!0),t},p),(r=i.prototype=p.prototype).constructor=i,a=r.toString,o="Symbol(test)"==String(p("test")),s=/^Symbol\((.*)\)[^)]+$/,d(r,"description",{configurable:!0,get:function(){var e=f(this)?this.valueOf():this,t=a.call(e);return h(n,e)?"":(t=o?t.slice(7,-1):t.replace(s,"$1"),""===t?void 0:t)}}),u({global:!0,forced:!0},{Symbol:i}))},function(e,t,r){r(173)("hasInstance")},function(e,t,r){r(173)("isConcatSpreadable")},function(e,t,r){r(173)("iterator")},function(e,t,r){r(173)("match")},function(e,t,r){r(173)("matchAll")},function(e,t,r){r(173)("replace")},function(e,t,r){r(173)("search")},function(e,t,r){r(173)("species")},function(e,t,r){r(173)("split")},function(e,t,r){r(173)("toPrimitive")},function(e,t,r){r(173)("toStringTag")},function(e,t,r){r(173)("unscopables")},function(e,t,r){r(85)(Math,"Math",!0)},function(e,t,r){var n=r(11);r(85)(n.JSON,"JSON",!0)},function(e,t,r){r(191),r=r(61),e.exports=r("String","padStart")},function(e,t,r){"use strict";var n=r(10),i=r(192).start;n({target:"String",proto:!0,forced:r(194)},{padStart:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}})},function(e,t,r){var n=r(47),i=r(193),a=r(20),o=Math.ceil;r=function(e){return function(t,r,s){var u=String(a(t));t=u.length,s=void 0===s?" ":String(s),r=n(r);return r<=t||""==s?u:((s=i.call(s,o((t=r-t)/s.length))).length>t&&(s=s.slice(0,t)),e?u+s:s+u)}};e.exports={start:r(!1),end:r(!0)}},function(e,t,r){"use strict";var n=r(48),i=r(20);e.exports="".repeat||function(e){var t=String(i(this)),r="",a=n(e);if(a<0||a==1/0)throw RangeError("Wrong number of repetitions");for(;0<a;(a>>>=1)&&(t+=t))1&a&&(r+=t);return r}},function(e,t,r){r=r(129),e.exports=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(r)},function(e,t,r){r(196),r=r(61),e.exports=r("String","padEnd")},function(e,t,r){"use strict";var n=r(10),i=r(192).end;n({target:"String",proto:!0,forced:r(194)},{padEnd:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}})},function(e,t,r){r(198),r=r(43),e.exports=r.Object.values},function(e,t,r){var n=r(10),i=r(199).values;n({target:"Object",stat:!0},{values:function(e){return i(e)}})},function(e,t,r){var n=r(13),i=r(73),a=r(17),o=r(15).f;r=function(e){return function(t){for(var r,s=a(t),u=i(s),l=u.length,c=0,h=[];c<l;)r=u[c++],n&&!o.call(s,r)||h.push(e?[r,s[r]]:s[r]);return h}};e.exports={entries:r(!0),values:r(!1)}},function(e,t,r){r(201),r=r(43),e.exports=r.Object.entries},function(e,t,r){var n=r(10),i=r(199).entries;n({target:"Object",stat:!0},{entries:function(e){return i(e)}})},function(module,exports,__w_pdfjs_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.getDocument=getDocument,exports.setPDFNetworkStreamFactory=setPDFNetworkStreamFactory,exports.build=exports.version=exports.PDFPageProxy=exports.PDFDocumentProxy=exports.PDFWorker=exports.PDFDataRangeTransport=exports.LoopbackPort=void 0;var _regenerator=_interopRequireDefault(__w_pdfjs_require__(2)),_util=__w_pdfjs_require__(5),_display_utils=__w_pdfjs_require__(1),_font_loader=__w_pdfjs_require__(203),_node_utils=__w_pdfjs_require__(204),_annotation_storage=__w_pdfjs_require__(205),_api_compatibility=__w_pdfjs_require__(206),_canvas=__w_pdfjs_require__(207),_worker_options=__w_pdfjs_require__(209),_is_node=__w_pdfjs_require__(7),_message_handler=__w_pdfjs_require__(210),_metadata=__w_pdfjs_require__(211),_optional_content_config=__w_pdfjs_require__(213),_transport_stream=__w_pdfjs_require__(214),_webgl=__w_pdfjs_require__(215);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function asyncGeneratorStep(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function _asyncToGenerator(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){asyncGeneratorStep(a,n,i,o,s,"next",e)}function s(e){asyncGeneratorStep(a,n,i,o,s,"throw",e)}o(void 0)}))}}function _toConsumableArray(e){return _arrayWithoutHoles(e)||_iterableToArray(e)||_unsupportedIterableToArray(e)||_nonIterableSpread()}function _nonIterableSpread(){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 _iterableToArray(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}function _arrayWithoutHoles(e){if(Array.isArray(e))return _arrayLikeToArray(e)}function _createForOfIteratorHelper(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=_unsupportedIterableToArray(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(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,n.key,n)}}function _createClass(e,t,r){return t&&_defineProperties(e.prototype,t),r&&_defineProperties(e,r),e}function _slicedToArray(e,t){return _arrayWithHoles(e)||_iterableToArrayLimit(e,t)||_unsupportedIterableToArray(e,t)||_nonIterableRest()}function _nonIterableRest(){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 _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(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 _iterableToArrayLimit(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}function _arrayWithHoles(e){if(Array.isArray(e))return e}function _typeof(e){return(_typeof="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)}var DEFAULT_RANGE_CHUNK_SIZE=65536,RENDERING_CANCELLED_TIMEOUT=100,DefaultCanvasFactory=_is_node.isNodeJS?_node_utils.NodeCanvasFactory:_display_utils.DOMCanvasFactory,DefaultCMapReaderFactory=_is_node.isNodeJS?_node_utils.NodeCMapReaderFactory:_display_utils.DOMCMapReaderFactory,createPDFNetworkStream;function setPDFNetworkStreamFactory(e){createPDFNetworkStream=e}function getDocument(e){var t,r=new PDFDocumentLoadingTask;if("string"==typeof e)t={url:e};else if((0,_util.isArrayBuffer)(e))t={data:e};else if(e instanceof PDFDataRangeTransport)t={range:e};else{if("object"!==_typeof(e))throw new Error("Invalid parameter in getDocument, need either Uint8Array, string or a parameter object");if(!e.url&&!e.data&&!e.range)throw new Error("Invalid parameter object: need either .data, .range or .url");t=e}var n,i=Object.create(null),a=null,o=null;for(n in t)if("url"!==n||"undefined"==typeof window)if("range"!==n)if("worker"!==n)if("data"!==n||t[n]instanceof Uint8Array)i[n]=t[n];else{var s=t[n];if("string"==typeof s)i[n]=(0,_util.stringToBytes)(s);else if("object"!==_typeof(s)||null===s||isNaN(s.length)){if(!(0,_util.isArrayBuffer)(s))throw new Error("Invalid PDF binary data: either typed array, string or array-like object is expected in the data property.");i[n]=new Uint8Array(s)}else i[n]=new Uint8Array(s)}else o=t[n];else a=t[n];else i[n]=new URL(t[n],window.location).href;i.rangeChunkSize=i.rangeChunkSize||DEFAULT_RANGE_CHUNK_SIZE,i.CMapReaderFactory=i.CMapReaderFactory||DefaultCMapReaderFactory,i.ignoreErrors=!0!==i.stopAtErrors,i.fontExtraProperties=!0===i.fontExtraProperties,i.pdfBug=!0===i.pdfBug,Number.isInteger(i.maxImageSize)||(i.maxImageSize=-1),"boolean"!=typeof i.isEvalSupported&&(i.isEvalSupported=!0),"boolean"!=typeof i.disableFontFace&&(i.disableFontFace=_api_compatibility.apiCompatibilityParams.disableFontFace||!1),void 0===i.ownerDocument&&(i.ownerDocument=globalThis.document),"boolean"!=typeof i.disableRange&&(i.disableRange=!1),"boolean"!=typeof i.disableStream&&(i.disableStream=!1),"boolean"!=typeof i.disableAutoFetch&&(i.disableAutoFetch=!1),(0,_util.setVerbosityLevel)(i.verbosity),o||(e={verbosity:i.verbosity,port:_worker_options.GlobalWorkerOptions.workerPort},o=e.port?PDFWorker.fromPort(e):new PDFWorker(e),r._worker=o);var u=r.docId;return o.promise.then((function(){if(r.destroyed)throw new Error("Loading aborted");var e=_fetchDocument(o,i,a,u),t=new Promise((function(e){var t;a?t=new _transport_stream.PDFDataTransportStream({length:i.length,initialData:i.initialData,progressiveDone:i.progressiveDone,disableRange:i.disableRange,disableStream:i.disableStream},a):i.data||(t=createPDFNetworkStream({url:i.url,length:i.length,httpHeaders:i.httpHeaders,withCredentials:i.withCredentials,rangeChunkSize:i.rangeChunkSize,disableRange:i.disableRange,disableStream:i.disableStream})),e(t)}));return Promise.all([e,t]).then((function(e){var t=_slicedToArray(e,2);e=t[0],t=t[1];if(r.destroyed)throw new Error("Loading aborted");e=new _message_handler.MessageHandler(u,e,o.port),e.postMessageTransfers=o.postMessageTransfers,t=new WorkerTransport(e,r,t,i),r._transport=t,e.send("Ready",null)}))})).catch(r._capability.reject),r}function _fetchDocument(e,t,r,n){return e.destroyed?Promise.reject(new Error("Worker was destroyed")):(r&&(t.length=r.length,t.initialData=r.initialData,t.progressiveDone=r.progressiveDone),e.messageHandler.sendWithPromise("GetDocRequest",{docId:n,apiVersion:"2.6.347",source:{data:t.data,url:t.url,password:t.password,disableAutoFetch:t.disableAutoFetch,rangeChunkSize:t.rangeChunkSize,length:t.length},maxImageSize:t.maxImageSize,disableFontFace:t.disableFontFace,postMessageTransfers:e.postMessageTransfers,docBaseUrl:t.docBaseUrl,ignoreErrors:t.ignoreErrors,isEvalSupported:t.isEvalSupported,fontExtraProperties:t.fontExtraProperties}).then((function(t){if(e.destroyed)throw new Error("Worker was destroyed");return t})))}var PDFDocumentLoadingTask=(_wa=0,function(){function e(){_classCallCheck(this,e),this._capability=(0,_util.createPromiseCapability)(),this._transport=null,this._worker=null,this.docId="d"+_wa++,this.destroyed=!1,this.onPassword=null,this.onProgress=null,this.onUnsupportedFeature=null}return _createClass(e,[{key:"destroy",value:function(){var e=this;return this.destroyed=!0,(this._transport?this._transport.destroy():Promise.resolve()).then((function(){e._transport=null,e._worker&&(e._worker.destroy(),e._worker=null)}))}},{key:"promise",get:function(){return this._capability.promise}}]),e}()),_wa,PDFDataRangeTransport=function(){function e(t,r){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2];_classCallCheck(this,e),this.length=t,this.initialData=r,this.progressiveDone=n,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=(0,_util.createPromiseCapability)()}return _createClass(e,[{key:"addRangeListener",value:function(e){this._rangeListeners.push(e)}},{key:"addProgressListener",value:function(e){this._progressListeners.push(e)}},{key:"addProgressiveReadListener",value:function(e){this._progressiveReadListeners.push(e)}},{key:"addProgressiveDoneListener",value:function(e){this._progressiveDoneListeners.push(e)}},{key:"onDataRange",value:function(e,t){var r,n=_createForOfIteratorHelper(this._rangeListeners);try{for(n.s();!(r=n.n()).done;)(0,r.value)(e,t)}catch(e){n.e(e)}finally{n.f()}}},{key:"onDataProgress",value:function(e,t){var r=this;this._readyCapability.promise.then((function(){var n,i=_createForOfIteratorHelper(r._progressListeners);try{for(i.s();!(n=i.n()).done;)(0,n.value)(e,t)}catch(n){i.e(n)}finally{i.f()}}))}},{key:"onDataProgressiveRead",value:function(e){var t=this;this._readyCapability.promise.then((function(){var r,n=_createForOfIteratorHelper(t._progressiveReadListeners);try{for(n.s();!(r=n.n()).done;)(0,r.value)(e)}catch(r){n.e(r)}finally{n.f()}}))}},{key:"onDataProgressiveDone",value:function(){var e=this;this._readyCapability.promise.then((function(){var t,r=_createForOfIteratorHelper(e._progressiveDoneListeners);try{for(r.s();!(t=r.n()).done;)(0,t.value)()}catch(t){r.e(t)}finally{r.f()}}))}},{key:"transportReady",value:function(){this._readyCapability.resolve()}},{key:"requestDataRange",value:function(e,t){(0,_util.unreachable)("Abstract method PDFDataRangeTransport.requestDataRange")}},{key:"abort",value:function(){}}]),e}();exports.PDFDataRangeTransport=PDFDataRangeTransport;var PDFDocumentProxy=function(){function e(t,r){_classCallCheck(this,e),this._pdfInfo=t,this._transport=r}return _createClass(e,[{key:"getPage",value:function(e){return this._transport.getPage(e)}},{key:"getPageIndex",value:function(e){return this._transport.getPageIndex(e)}},{key:"getDestinations",value:function(){return this._transport.getDestinations()}},{key:"getDestination",value:function(e){return this._transport.getDestination(e)}},{key:"getPageLabels",value:function(){return this._transport.getPageLabels()}},{key:"getPageLayout",value:function(){return this._transport.getPageLayout()}},{key:"getPageMode",value:function(){return this._transport.getPageMode()}},{key:"getViewerPreferences",value:function(){return this._transport.getViewerPreferences()}},{key:"getOpenAction",value:function(){return this._transport.getOpenAction()}},{key:"getAttachments",value:function(){return this._transport.getAttachments()}},{key:"getJavaScript",value:function(){return this._transport.getJavaScript()}},{key:"getOutline",value:function(){return this._transport.getOutline()}},{key:"getOptionalContentConfig",value:function(){return this._transport.getOptionalContentConfig()}},{key:"getPermissions",value:function(){return this._transport.getPermissions()}},{key:"getMetadata",value:function(){return this._transport.getMetadata()}},{key:"getData",value:function(){return this._transport.getData()}},{key:"getDownloadInfo",value:function(){return this._transport.downloadInfoCapability.promise}},{key:"getStats",value:function(){return this._transport.getStats()}},{key:"cleanup",value:function(){return this._transport.startCleanup()}},{key:"destroy",value:function(){return this.loadingTask.destroy()}},{key:"saveDocument",value:function(e){return this._transport.saveDocument(e)}},{key:"annotationStorage",get:function(){return(0,_util.shadow)(this,"annotationStorage",new _annotation_storage.AnnotationStorage)}},{key:"numPages",get:function(){return this._pdfInfo.numPages}},{key:"fingerprint",get:function(){return this._pdfInfo.fingerprint}},{key:"loadingParams",get:function(){return this._transport.loadingParams}},{key:"loadingTask",get:function(){return this._transport.loadingTask}}]),e}();exports.PDFDocumentProxy=PDFDocumentProxy;var PDFPageProxy=function(){function e(t,r,n,i){var a=4<arguments.length&&void 0!==arguments[4]&&arguments[4];_classCallCheck(this,e),this._pageIndex=t,this._pageInfo=r,this._ownerDocument=i,this._transport=n,this._stats=a?new _display_utils.StatTimer:null,this._pdfBug=a,this.commonObjs=n.commonObjs,this.objs=new PDFObjects,this.cleanupAfterRender=!1,this.pendingCleanup=!1,this._intentStates=new Map,this.destroyed=!1}return _createClass(e,[{key:"getViewport",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.scale,r=e.rotation,n=void 0===r?this.rotate:r,i=e.offsetX;r=e.offsetY,e=e.dontFlip;return new _display_utils.PageViewport({viewBox:this.view,scale:t,rotation:n,offsetX:void 0===i?0:i,offsetY:void 0===r?0:r,dontFlip:void 0!==e&&e})}},{key:"getAnnotations",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).intent;e=void 0===e?null:e;return this.annotationsPromise&&this.annotationsIntent===e||(this.annotationsPromise=this._transport.getAnnotations(this._pageIndex,e),this.annotationsIntent=e),this.annotationsPromise}},{key:"render",value:function(e){var t=this,r=e.canvasContext,n=e.viewport,i=e.intent,a=void 0===i?"display":i,o=e.enableWebGL,s=void 0!==o&&o,u=e.renderInteractiveForms,l=void 0!==u&&u,c=e.transform,h=void 0===c?null:c;i=e.imageLayer,o=void 0===i?null:i,u=e.canvasFactory,c=void 0===u?null:u,i=e.background,u=void 0===i?null:i,i=e.annotationStorage,i=void 0===i?null:i,e=e.optionalContentConfigPromise,e=void 0===e?null:e;this._stats&&this._stats.time("Overall");var f="print"===a?"print":"display";this.pendingCleanup=!1;e=e||this._transport.getOptionalContentConfig();var d=this._intentStates.get(f);function p(e){var r=d.renderTasks.indexOf(v);0<=r&&d.renderTasks.splice(r,1),!t.cleanupAfterRender&&"print"!=f||(t.pendingCleanup=!0),t._tryCleanup(),e?(v.capability.reject(e),t._abortOperatorList({intentState:d,reason:e})):v.capability.resolve(),t._stats&&(t._stats.timeEnd("Rendering"),t._stats.timeEnd("Overall"))}d||(d=Object.create(null),this._intentStates.set(f,d)),d.streamReaderCancelTimeout&&(clearTimeout(d.streamReaderCancelTimeout),d.streamReaderCancelTimeout=null),c=c||new DefaultCanvasFactory({ownerDocument:this._ownerDocument}),s=new _webgl.WebGLContext({enable:s}),d.displayReadyCapability||(d.displayReadyCapability=(0,_util.createPromiseCapability)(),d.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:f,renderInteractiveForms:!0===l,annotationStorage:i&&i.getAll()||null}));var v=new InternalRenderTask({callback:p,params:{canvasContext:r,viewport:n,transform:h,imageLayer:o,background:u},objs:this.objs,commonObjs:this.commonObjs,operatorList:d.operatorList,pageIndex:this._pageIndex,canvasFactory:c,webGLContext:s,useRequestAnimationFrame:"print"!=f,pdfBug:this._pdfBug});return d.renderTasks||(d.renderTasks=[]),d.renderTasks.push(v),s=v.task,Promise.all([d.displayReadyCapability.promise,e]).then((function(e){var r=_slicedToArray(e,2);e=r[0],r=r[1];t.pendingCleanup?p():(t._stats&&t._stats.time("Rendering"),v.initializeGraphics({transparency:e,optionalContentConfig:r}),v.operatorListChanged())})).catch(p),s}},{key:"getOperatorList",value:function(){var e,t="oplist",r=this._intentStates.get(t);return r||(r=Object.create(null),this._intentStates.set(t,r)),r.opListReadCapability||((e=Object.create(null)).operatorListChanged=function(){var t;r.operatorList.lastChunk&&(r.opListReadCapability.resolve(r.operatorList),0<=(t=r.renderTasks.indexOf(e))&&r.renderTasks.splice(t,1))},r.opListReadCapability=(0,_util.createPromiseCapability)(),r.renderTasks=[],r.renderTasks.push(e),r.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:t})),r.opListReadCapability.promise}},{key:"streamTextContent",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.normalizeWhitespace;e=e.disableCombineTextItems;return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,normalizeWhitespace:!0===(void 0!==t&&t),combineTextItems:!0!==(void 0!==e&&e)},{highWaterMark:100,size:function(e){return e.items.length}})}},{key:"getTextContent",value:function(){var e=this.streamTextContent(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{});return new Promise((function(t,r){var n=e.getReader(),i={items:[],styles:Object.create(null)};!function e(){n.read().then((function(r){var n=r.value;r.done?t(i):(Object.assign(i.styles,n.styles),(r=i.items).push.apply(r,_toConsumableArray(n.items)),e())}),r)}()}))}},{key:"_destroy",value:function(){this.destroyed=!0,this._transport.pageCache[this._pageIndex]=null;var e,t=[],r=_createForOfIteratorHelper(this._intentStates);try{for(r.s();!(e=r.n()).done;){var n=_slicedToArray(e.value,2),i=n[0],a=n[1];if(this._abortOperatorList({intentState:a,reason:new Error("Page was destroyed."),force:!0}),"oplist"!==i){var o,s=_createForOfIteratorHelper(a.renderTasks);try{for(s.s();!(o=s.n()).done;){var u=o.value;t.push(u.completed),u.cancel()}}catch(e){s.e(e)}finally{s.f()}}}}catch(e){r.e(e)}finally{r.f()}return this.objs.clear(),this.annotationsPromise=null,this.pendingCleanup=!1,Promise.all(t)}},{key:"cleanup",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];return this.pendingCleanup=!0,this._tryCleanup(e)}},{key:"_tryCleanup",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];if(!this.pendingCleanup)return!1;var t,r=_createForOfIteratorHelper(this._intentStates.values());try{for(r.s();!(t=r.n()).done;){var n=t.value,i=n.renderTasks,a=n.operatorList;if(0!==i.length||!a.lastChunk)return!1}}catch(e){r.e(e)}finally{r.f()}return this._intentStates.clear(),this.objs.clear(),this.annotationsPromise=null,e&&this._stats&&(this._stats=new _display_utils.StatTimer),!(this.pendingCleanup=!1)}},{key:"_startRenderPage",value:function(e,t){t=this._intentStates.get(t),t&&(this._stats&&this._stats.timeEnd("Page Request"),t.displayReadyCapability&&t.displayReadyCapability.resolve(e))}},{key:"_renderPageChunk",value:function(e,t){for(var r=0,n=e.length;r<n;r++)t.operatorList.fnArray.push(e.fnArray[r]),t.operatorList.argsArray.push(e.argsArray[r]);t.operatorList.lastChunk=e.lastChunk;for(var i=0;i<t.renderTasks.length;i++)t.renderTasks[i].operatorListChanged();e.lastChunk&&this._tryCleanup()}},{key:"_pumpOperatorList",value:function(e){var t=this;(0,_util.assert)(e.intent,'PDFPageProxy._pumpOperatorList: Expected "intent" argument.');var r=this._transport.messageHandler.sendWithStream("GetOperatorList",e).getReader(),n=this._intentStates.get(e.intent);n.streamReader=r,function e(){r.read().then((function(r){var i=r.value;r.done?n.streamReader=null:t._transport.destroyed||(t._renderPageChunk(i,n),e())}),(function(e){if(n.streamReader=null,!t._transport.destroyed){if(n.operatorList){n.operatorList.lastChunk=!0;for(var r=0;r<n.renderTasks.length;r++)n.renderTasks[r].operatorListChanged();t._tryCleanup()}if(n.displayReadyCapability)n.displayReadyCapability.reject(e);else{if(!n.opListReadCapability)throw e;n.opListReadCapability.reject(e)}}}))}()}},{key:"_abortOperatorList",value:function(e){var t=this,r=e.intentState,n=e.reason;e=e.force,e=void 0!==e&&e;if((0,_util.assert)(n instanceof Error||"object"===_typeof(n)&&null!==n,'PDFPageProxy._abortOperatorList: Expected "reason" argument.'),r.streamReader){if(!e){if(0!==r.renderTasks.length)return;if(n instanceof _display_utils.RenderingCancelledException)return void(r.streamReaderCancelTimeout=setTimeout((function(){t._abortOperatorList({intentState:r,reason:n,force:!0}),r.streamReaderCancelTimeout=null}),RENDERING_CANCELLED_TIMEOUT))}if(r.streamReader.cancel(new _util.AbortException(n&&n.message)),r.streamReader=null,!this._transport.destroyed){var i,a=_createForOfIteratorHelper(this._intentStates);try{for(a.s();!(i=a.n()).done;){var o=_slicedToArray(i.value,2),s=o[0];if(o[1]===r){this._intentStates.delete(s);break}}}catch(e){a.e(e)}finally{a.f()}this.cleanup()}}}},{key:"pageNumber",get:function(){return this._pageIndex+1}},{key:"rotate",get:function(){return this._pageInfo.rotate}},{key:"ref",get:function(){return this._pageInfo.ref}},{key:"userUnit",get:function(){return this._pageInfo.userUnit}},{key:"view",get:function(){return this._pageInfo.view}},{key:"stats",get:function(){return this._stats}}]),e}();exports.PDFPageProxy=PDFPageProxy;var LoopbackPort=function(){function e(){var t=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];_classCallCheck(this,e),this._listeners=[],this._defer=t,this._deferred=Promise.resolve(void 0)}return _createClass(e,[{key:"postMessage",value:function(e,t){var r,n,i=this;this._defer?(r=new WeakMap,n={data:function e(n){if("object"!==_typeof(n)||null===n)return n;if(r.has(n))return r.get(n);var i,a;if((i=n.buffer)&&(0,_util.isArrayBuffer)(i)){var o=t&&t.includes(i)?new n.constructor(i,n.byteOffset,n.byteLength):new n.constructor(n);return r.set(n,o),o}for(a in o=Array.isArray(n)?[]:{},r.set(n,o),n){for(var s=void 0,u=n;!(s=Object.getOwnPropertyDescriptor(u,a));)u=Object.getPrototypeOf(u);if(void 0!==s.value)if("function"!=typeof s.value)o[a]=e(s.value);else if(n.hasOwnProperty&&n.hasOwnProperty(a))throw new Error("LoopbackPort.postMessage - cannot clone: ".concat(n[a]))}return o}(e)},this._deferred.then((function(){i._listeners.forEach((function(e){e.call(i,n)}))}))):this._listeners.forEach((function(t){t.call(i,{data:e})}))}},{key:"addEventListener",value:function(e,t){this._listeners.push(t)}},{key:"removeEventListener",value:function(e,t){t=this._listeners.indexOf(t),this._listeners.splice(t,1)}},{key:"terminate",value:function(){this._listeners.length=0}}]),e}();exports.LoopbackPort=LoopbackPort;var PDFWorker=function PDFWorkerClosure(){var pdfWorkerPorts=new WeakMap,isWorkerDisabled=!1,fallbackWorkerSrc,nextFakeWorkerId=0,fakeWorkerCapability,pdfjsFilePath;function _getWorkerSrc(){if(_worker_options.GlobalWorkerOptions.workerSrc)return _worker_options.GlobalWorkerOptions.workerSrc;if(void 0!==fallbackWorkerSrc)return _is_node.isNodeJS||(0,_display_utils.deprecated)('No "GlobalWorkerOptions.workerSrc" specified.'),fallbackWorkerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}function getMainThreadWorkerMessageHandler(){var e;try{e=globalThis.pdfjsWorker&&globalThis.pdfjsWorker.WorkerMessageHandler}catch(e){}return e||null}function setupFakeWorkerGlobal(){if(fakeWorkerCapability)return fakeWorkerCapability.promise;fakeWorkerCapability=(0,_util.createPromiseCapability)();var loader=function(){var _ref12=_asyncToGenerator(_regenerator.default.mark((function _callee(){var mainWorkerMessageHandler,worker;return _regenerator.default.wrap((function _callee$(_context){for(;;)switch(_context.prev=_context.next){case 0:if(mainWorkerMessageHandler=getMainThreadWorkerMessageHandler(),mainWorkerMessageHandler)return _context.abrupt("return",mainWorkerMessageHandler);_context.next=3;break;case 3:if(_is_node.isNodeJS)return worker=eval("require")(_getWorkerSrc()),_context.abrupt("return",worker.WorkerMessageHandler);_context.next=6;break;case 6:return _context.next=8,(0,_display_utils.loadScript)(_getWorkerSrc());case 8:return _context.abrupt("return",window.pdfjsWorker.WorkerMessageHandler);case 9:case"end":return _context.stop()}}),_callee)})));return function(){return _ref12.apply(this,arguments)}}();return loader().then(fakeWorkerCapability.resolve,fakeWorkerCapability.reject),fakeWorkerCapability.promise}function createCDNWrapper(e){return URL.createObjectURL(new Blob(["importScripts('"+e+"');"]))}_is_node.isNodeJS?(isWorkerDisabled=!0,fallbackWorkerSrc="./pdf.worker.js"):"object"===("undefined"==typeof document?"undefined":_typeof(document))&&"currentScript"in document&&(pdfjsFilePath=document.currentScript&&document.currentScript.src,pdfjsFilePath&&(fallbackWorkerSrc=pdfjsFilePath.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2")));var PDFWorker=function(){function e(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},r=t.name,n=void 0===r?null:r;r=t.port,r=void 0===r?null:r,t=t.verbosity,t=void 0===t?(0,_util.getVerbosityLevel)():t;if(_classCallCheck(this,e),r&&pdfWorkerPorts.has(r))throw new Error("Cannot use more than one PDFWorker per port");if(this.name=n,this.destroyed=!1,this.postMessageTransfers=!0,this.verbosity=t,this._readyCapability=(0,_util.createPromiseCapability)(),this._port=null,this._webWorker=null,this._messageHandler=null,r)return pdfWorkerPorts.set(r,this),void this._initializeFromPort(r);this._initialize()}return _createClass(e,[{key:"_initializeFromPort",value:function(e){this._port=e,this._messageHandler=new _message_handler.MessageHandler("main","worker",e),this._messageHandler.on("ready",(function(){})),this._readyCapability.resolve()}},{key:"_initialize",value:function(){var e=this;if("undefined"!=typeof Worker&&!isWorkerDisabled&&!getMainThreadWorkerMessageHandler()){var t=_getWorkerSrc();try{(0,_util.isSameOrigin)(window.location.href,t)||(t=createCDNWrapper(new URL(t,window.location).href));var r=new Worker(t),n=new _message_handler.MessageHandler("main","worker",r),i=function(){r.removeEventListener("error",a),n.destroy(),r.terminate(),e.destroyed?e._readyCapability.reject(new Error("Worker was destroyed")):e._setupFakeWorker()},a=function(){e._webWorker||i()};r.addEventListener("error",a),n.on("test",(function(t){r.removeEventListener("error",a),e.destroyed?i():t?(e._messageHandler=n,e._port=r,e._webWorker=r,t.supportTransfers||(e.postMessageTransfers=!1),e._readyCapability.resolve(),n.send("configure",{verbosity:e.verbosity})):(e._setupFakeWorker(),n.destroy(),r.terminate())})),n.on("ready",(function(t){if(r.removeEventListener("error",a),e.destroyed)i();else try{o()}catch(t){e._setupFakeWorker()}}));var o=function(){var r=new Uint8Array([e.postMessageTransfers?255:0]);try{n.send("test",r,[r.buffer])}catch(t){(0,_util.warn)("Cannot use postMessage transfers."),r[0]=0,n.send("test",r)}};return void o()}catch(t){(0,_util.info)("The worker has been disabled.")}}this._setupFakeWorker()}},{key:"_setupFakeWorker",value:function(){var e=this;isWorkerDisabled||((0,_util.warn)("Setting up fake worker."),isWorkerDisabled=!0),setupFakeWorkerGlobal().then((function(t){var r,n,i;e.destroyed?e._readyCapability.reject(new Error("Worker was destroyed")):(i=new LoopbackPort,e._port=i,r="fake"+nextFakeWorkerId++,n=new _message_handler.MessageHandler(r+"_worker",r,i),t.setup(n,i),i=new _message_handler.MessageHandler(r,r+"_worker",i),e._messageHandler=i,e._readyCapability.resolve(),i.send("configure",{verbosity:e.verbosity}))})).catch((function(t){e._readyCapability.reject(new Error('Setting up fake worker failed: "'.concat(t.message,'".')))}))}},{key:"destroy",value:function(){this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),pdfWorkerPorts.delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}},{key:"promise",get:function(){return this._readyCapability.promise}},{key:"port",get:function(){return this._port}},{key:"messageHandler",get:function(){return this._messageHandler}}],[{key:"fromPort",value:function(t){if(!t||!t.port)throw new Error("PDFWorker.fromPort - invalid method signature.");return pdfWorkerPorts.has(t.port)?pdfWorkerPorts.get(t.port):new e(t)}},{key:"getWorkerSrc",value:function(){return _getWorkerSrc()}}]),e}();return PDFWorker}();exports.PDFWorker=PDFWorker;var WorkerTransport=function(){function e(t,r,n,i){_classCallCheck(this,e),this.messageHandler=t,this.loadingTask=r,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({docId:r.docId,onUnsupportedFeature:this._onUnsupportedFeature.bind(this),ownerDocument:i.ownerDocument}),this._params=i,this.CMapReaderFactory=new i.CMapReaderFactory({baseUrl:i.cMapUrl,isCompressed:i.cMapPacked}),this.destroyed=!1,this.destroyCapability=null,this._passwordCapability=null,this._networkStream=n,this._fullReader=null,this._lastProgress=null,this.pageCache=[],this.pagePromises=[],this.downloadInfoCapability=(0,_util.createPromiseCapability)(),this.setupMessageHandler()}return _createClass(e,[{key:"destroy",value:function(){var e=this;if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=(0,_util.createPromiseCapability)(),this._passwordCapability&&this._passwordCapability.reject(new Error("Worker was destroyed during onPassword callback"));var t=[];this.pageCache.forEach((function(e){e&&t.push(e._destroy())})),this.pageCache.length=0,this.pagePromises.length=0;var r=this.messageHandler.sendWithPromise("Terminate",null);return t.push(r),Promise.all(t).then((function(){e.fontLoader.clear(),e._networkStream&&e._networkStream.cancelAllRequests(new _util.AbortException("Worker was terminated.")),e.messageHandler&&(e.messageHandler.destroy(),e.messageHandler=null),e.destroyCapability.resolve()}),this.destroyCapability.reject),this.destroyCapability.promise}},{key:"setupMessageHandler",value:function(){var e=this,t=this.messageHandler,r=this.loadingTask;t.on("GetReader",(function(t,r){(0,_util.assert)(e._networkStream,"GetReader - no `IPDFStream` instance available."),e._fullReader=e._networkStream.getFullReader(),e._fullReader.onProgress=function(t){e._lastProgress={loaded:t.loaded,total:t.total}},r.onPull=function(){e._fullReader.read().then((function(e){var t=e.value;e.done?r.close():((0,_util.assert)((0,_util.isArrayBuffer)(t),"GetReader - expected an ArrayBuffer."),r.enqueue(new Uint8Array(t),1,[t]))})).catch((function(e){r.error(e)}))},r.onCancel=function(t){e._fullReader.cancel(t),r.ready.catch((function(t){if(!e.destroyed)throw t}))}})),t.on("ReaderHeadersReady",(function(t){var n=(0,_util.createPromiseCapability)(),i=e._fullReader;return i.headersReady.then((function(){i.isStreamingSupported&&i.isRangeSupported||(e._lastProgress&&r.onProgress&&r.onProgress(e._lastProgress),i.onProgress=function(e){r.onProgress&&r.onProgress({loaded:e.loaded,total:e.total})}),n.resolve({isStreamingSupported:i.isStreamingSupported,isRangeSupported:i.isRangeSupported,contentLength:i.contentLength})}),n.reject),n.promise})),t.on("GetRangeReader",(function(t,r){(0,_util.assert)(e._networkStream,"GetRangeReader - no `IPDFStream` instance available.");var n=e._networkStream.getRangeReader(t.begin,t.end);n?(r.onPull=function(){n.read().then((function(e){var t=e.value;e.done?r.close():((0,_util.assert)((0,_util.isArrayBuffer)(t),"GetRangeReader - expected an ArrayBuffer."),r.enqueue(new Uint8Array(t),1,[t]))})).catch((function(e){r.error(e)}))},r.onCancel=function(t){n.cancel(t),r.ready.catch((function(t){if(!e.destroyed)throw t}))}):r.close()})),t.on("GetDoc",(function(t){t=t.pdfInfo,e._numPages=t.numPages,r._capability.resolve(new PDFDocumentProxy(t,e))})),t.on("DocException",(function(e){var t;switch(e.name){case"PasswordException":t=new _util.PasswordException(e.message,e.code);break;case"InvalidPDFException":t=new _util.InvalidPDFException(e.message);break;case"MissingPDFException":t=new _util.MissingPDFException(e.message);break;case"UnexpectedResponseException":t=new _util.UnexpectedResponseException(e.message,e.status);break;case"UnknownErrorException":t=new _util.UnknownErrorException(e.message,e.details)}t instanceof Error||(0,_util.warn)("DocException - expected a valid Error."),r._capability.reject(t)})),t.on("PasswordRequest",(function(t){if(e._passwordCapability=(0,_util.createPromiseCapability)(),r.onPassword)try{r.onPassword((function(t){e._passwordCapability.resolve({password:t})}),t.code)}catch(t){e._passwordCapability.reject(t)}else e._passwordCapability.reject(new _util.PasswordException(t.message,t.code));return e._passwordCapability.promise})),t.on("DataLoaded",(function(t){r.onProgress&&r.onProgress({loaded:t.length,total:t.length}),e.downloadInfoCapability.resolve(t)})),t.on("StartRenderPage",(function(t){e.destroyed||e.pageCache[t.pageIndex]._startRenderPage(t.transparency,t.intent)})),t.on("commonobj",(function(r){if(!e.destroyed){r=_slicedToArray(r,3);var n=r[0],i=r[1],a=r[2];if(!e.commonObjs.has(n))switch(i){case"Font":var o=e._params;if("error"in a){var s=a.error;(0,_util.warn)("Error during font loading: ".concat(s)),e.commonObjs.resolve(n,s);break}s=null,o.pdfBug&&globalThis.FontInspector&&globalThis.FontInspector.enabled&&(s={registerFont:function(e,t){globalThis.FontInspector.fontAdded(e,t)}});var u=new _font_loader.FontFaceObject(a,{isEvalSupported:o.isEvalSupported,disableFontFace:o.disableFontFace,ignoreErrors:o.ignoreErrors,onUnsupportedFeature:e._onUnsupportedFeature.bind(e),fontRegistry:s});e.fontLoader.bind(u).catch((function(e){return t.sendWithPromise("FontFallback",{id:n})})).finally((function(){!o.fontExtraProperties&&u.data&&(u.data=null),e.commonObjs.resolve(n,u)}));break;case"FontPath":case"Image":e.commonObjs.resolve(n,a);break;default:throw new Error("Got unknown common object type ".concat(i))}}})),t.on("obj",(function(t){if(!e.destroyed){var r=_slicedToArray(t,4),n=r[0],i=r[1];t=r[2],r=r[3],i=e.pageCache[i];if(!i.objs.has(n)){if("Image"!==t)throw new Error("Got unknown object type ".concat(t));i.objs.resolve(n,r),r&&"data"in r&&8e6<r.data.length&&(i.cleanupAfterRender=!0)}}})),t.on("DocProgress",(function(t){e.destroyed||r.onProgress&&r.onProgress({loaded:t.loaded,total:t.total})})),t.on("UnsupportedFeature",this._onUnsupportedFeature.bind(this)),t.on("FetchBuiltInCMap",(function(t,r){var n;e.destroyed?r.error(new Error("Worker was destroyed")):(n=!1,r.onPull=function(){n?r.close():(n=!0,e.CMapReaderFactory.fetch(t).then((function(e){r.enqueue(e,1,[e.cMapData.buffer])})).catch((function(e){r.error(e)})))})}))}},{key:"_onUnsupportedFeature",value:function(e){e=e.featureId,this.destroyed||this.loadingTask.onUnsupportedFeature&&this.loadingTask.onUnsupportedFeature(e)}},{key:"getData",value:function(){return this.messageHandler.sendWithPromise("GetData",null)}},{key:"getPage",value:function(e){var t=this;if(!Number.isInteger(e)||e<=0||e>this._numPages)return Promise.reject(new Error("Invalid page request"));var r=e-1;return r in this.pagePromises?this.pagePromises[r]:(e=this.messageHandler.sendWithPromise("GetPage",{pageIndex:r}).then((function(e){if(t.destroyed)throw new Error("Transport destroyed");return e=new PDFPageProxy(r,e,t,t._params.ownerDocument,t._params.pdfBug),t.pageCache[r]=e})),this.pagePromises[r]=e)}},{key:"getPageIndex",value:function(e){return this.messageHandler.sendWithPromise("GetPageIndex",{ref:e}).catch((function(e){return Promise.reject(new Error(e))}))}},{key:"getAnnotations",value:function(e,t){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:e,intent:t})}},{key:"saveDocument",value:function(e){return this.messageHandler.sendWithPromise("SaveDocument",{numPages:this._numPages,annotationStorage:e&&e.getAll()||null,filename:this._fullReader?this._fullReader.filename:null}).finally((function(){e&&e.resetModified()}))}},{key:"getDestinations",value:function(){return this.messageHandler.sendWithPromise("GetDestinations",null)}},{key:"getDestination",value:function(e){return"string"!=typeof e?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:e})}},{key:"getPageLabels",value:function(){return this.messageHandler.sendWithPromise("GetPageLabels",null)}},{key:"getPageLayout",value:function(){return this.messageHandler.sendWithPromise("GetPageLayout",null)}},{key:"getPageMode",value:function(){return this.messageHandler.sendWithPromise("GetPageMode",null)}},{key:"getViewerPreferences",value:function(){return this.messageHandler.sendWithPromise("GetViewerPreferences",null)}},{key:"getOpenAction",value:function(){return this.messageHandler.sendWithPromise("GetOpenAction",null)}},{key:"getAttachments",value:function(){return this.messageHandler.sendWithPromise("GetAttachments",null)}},{key:"getJavaScript",value:function(){return this.messageHandler.sendWithPromise("GetJavaScript",null)}},{key:"getOutline",value:function(){return this.messageHandler.sendWithPromise("GetOutline",null)}},{key:"getOptionalContentConfig",value:function(){return this.messageHandler.sendWithPromise("GetOptionalContentConfig",null).then((function(e){return new _optional_content_config.OptionalContentConfig(e)}))}},{key:"getPermissions",value:function(){return this.messageHandler.sendWithPromise("GetPermissions",null)}},{key:"getMetadata",value:function(){var e=this;return this.messageHandler.sendWithPromise("GetMetadata",null).then((function(t){return{info:t[0],metadata:t[1]?new _metadata.Metadata(t[1]):null,contentDispositionFilename:e._fullReader?e._fullReader.filename:null}}))}},{key:"getStats",value:function(){return this.messageHandler.sendWithPromise("GetStats",null)}},{key:"startCleanup",value:function(){var e=this;return this.messageHandler.sendWithPromise("Cleanup",null).then((function(){for(var t=0,r=e.pageCache.length;t<r;t++){var n=e.pageCache[t];if(n&&!n.cleanup())throw new Error("startCleanup: Page ".concat(t+1," is currently rendering."))}e.commonObjs.clear(),e.fontLoader.clear()}))}},{key:"loadingParams",get:function(){var e=this._params;return(0,_util.shadow)(this,"loadingParams",{disableAutoFetch:e.disableAutoFetch,disableFontFace:e.disableFontFace})}}]),e}(),PDFObjects=function(){function e(){_classCallCheck(this,e),this._objs=Object.create(null)}return _createClass(e,[{key:"_ensureObj",value:function(e){return this._objs[e]||(this._objs[e]={capability:(0,_util.createPromiseCapability)(),data:null,resolved:!1})}},{key:"get",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;if(t)return this._ensureObj(e).capability.promise.then(t),null;if(t=this._objs[e],!t||!t.resolved)throw new Error("Requesting object that isn't resolved yet ".concat(e,"."));return t.data}},{key:"has",value:function(e){return e=this._objs[e],!!e&&e.resolved}},{key:"resolve",value:function(e,t){e=this._ensureObj(e),e.resolved=!0,e.data=t,e.capability.resolve(t)}},{key:"clear",value:function(){this._objs=Object.create(null)}}]),e}(),RenderTask=function(){function e(t){_classCallCheck(this,e),this._internalRenderTask=t,this.onContinue=null}return _createClass(e,[{key:"cancel",value:function(){this._internalRenderTask.cancel()}},{key:"promise",get:function(){return this._internalRenderTask.capability.promise}}]),e}(),InternalRenderTask=(pFa=new WeakSet,function(){function e(t){var r=t.callback,n=t.params,i=t.objs,a=t.commonObjs,o=t.operatorList,s=t.pageIndex,u=t.canvasFactory,l=t.webGLContext,c=t.useRequestAnimationFrame;c=void 0!==c&&c,t=t.pdfBug,t=void 0!==t&&t;_classCallCheck(this,e),this.callback=r,this.params=n,this.objs=i,this.commonObjs=a,this.operatorListIdx=null,this.operatorList=o,this._pageIndex=s,this.canvasFactory=u,this.webGLContext=l,this._pdfBug=t,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=!0===c&&"undefined"!=typeof window,this.cancelled=!1,this.capability=(0,_util.createPromiseCapability)(),this.task=new RenderTask(this),this._continueBound=this._continue.bind(this),this._scheduleNextBound=this._scheduleNext.bind(this),this._nextBound=this._next.bind(this),this._canvas=n.canvasContext.canvas}var t;return _createClass(e,[{key:"initializeGraphics",value:function(e){var t=e.transparency,r=void 0!==t&&t,n=e.optionalContentConfig;if(!this.cancelled){if(this._canvas){if(pFa.has(this._canvas))throw new Error("Cannot use the same canvas during multiple render() operations. Use different canvas or ensure previous operations were cancelled or completed.");pFa.add(this._canvas)}this._pdfBug&&globalThis.StepperManager&&globalThis.StepperManager.enabled&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());var i=this.params,a=i.canvasContext,o=i.viewport;t=i.transform,e=i.imageLayer,i=i.background;this.gfx=new _canvas.CanvasGraphics(a,this.commonObjs,this.objs,this.canvasFactory,this.webGLContext,e,n),this.gfx.beginDrawing({transform:t,viewport:o,transparency:r,background:i}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback&&this.graphicsReadyCallback()}}},{key:"cancel",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;this.running=!1,this.cancelled=!0,this.gfx&&this.gfx.endDrawing(),this._canvas&&pFa.delete(this._canvas),this.callback(e||new _display_utils.RenderingCancelledException("Rendering cancelled, page ".concat(this._pageIndex+1),"canvas"))}},{key:"operatorListChanged",value:function(){this.graphicsReady?(this.stepper&&this.stepper.updateOperatorList(this.operatorList),this.running||this._continue()):this.graphicsReadyCallback||(this.graphicsReadyCallback=this._continueBound)}},{key:"_continue",value:function(){this.running=!0,this.cancelled||(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}},{key:"_scheduleNext",value:function(){var e=this;this._useRequestAnimationFrame?window.requestAnimationFrame((function(){e._nextBound().catch(e.cancel.bind(e))})):Promise.resolve().then(this._nextBound).catch(this.cancel.bind(this))}},{key:"_next",value:(t=_asyncToGenerator(_regenerator.default.mark((function e(){return _regenerator.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this.cancelled)return e.abrupt("return");e.next=2;break;case 2:this.operatorListIdx=this.gfx.executeOperatorList(this.operatorList,this.operatorListIdx,this._continueBound,this.stepper),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),this._canvas&&pFa.delete(this._canvas),this.callback()));case 4:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"completed",get:function(){return this.capability.promise.catch((function(){}))}}]),e}()),pFa,version="2.6.347";exports.version=version;var build="3be9c65f";exports.build=build},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FontLoader=t.FontFaceObject=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5);function o(e){return(o="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)}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=l(t);return e=r?(e=l(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==o(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f(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,n.key,n)}}function d(e,t,r){return t&&f(e.prototype,t),r&&f(e,r),e}var p=function(){function e(t){var r=t.docId,n=t.onUnsupportedFeature;t=t.ownerDocument,t=void 0===t?globalThis.document:t;h(this,e),this.constructor===e&&(0,a.unreachable)("Cannot initialize BaseFontLoader."),this.docId=r,this._onUnsupportedFeature=n,this._document=t,this.nativeFontFaces=[],this.styleElement=null}var t,r;return d(e,[{key:"addNativeFontFace",value:function(e){this.nativeFontFaces.push(e),this._document.fonts.add(e)}},{key:"insertRule",value:function(e){var t=this.styleElement;t||((t=this.styleElement=this._document.createElement("style")).id="PDFJS_FONT_STYLE_TAG_".concat(this.docId),this._document.documentElement.getElementsByTagName("head")[0].appendChild(t)),t=t.sheet,t.insertRule(e,t.cssRules.length)}},{key:"clear",value:function(){var e=this;this.nativeFontFaces.forEach((function(t){e._document.fonts.delete(t)})),this.nativeFontFaces.length=0,this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}},{key:"bind",value:(t=i.default.mark((function e(t){var r,n,o=this;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.attached||t.missingFile)return e.abrupt("return");e.next=2;break;case 2:if(t.attached=!0,!this.isFontLoadingAPISupported){e.next=19;break}if(r=t.createNativeFontFace())return this.addNativeFontFace(r),e.prev=7,e.next=10,r.loaded;e.next=18;break;case 10:e.next=18;break;case 12:throw e.prev=12,e.t0=e.catch(7),this._onUnsupportedFeature({featureId:a.UNSUPPORTED_FEATURES.errorFontLoadNative}),(0,a.warn)("Failed to load font '".concat(r.family,"': '").concat(e.t0,"'.")),t.disableFontFace=!0,e.t0;case 18:return e.abrupt("return");case 19:if(!(n=t.createFontFaceRule())){e.next=26;break}if(this.insertRule(n),this.isSyncFontLoadingSupported)return e.abrupt("return");e.next=24;break;case 24:return e.next=26,new Promise((function(e){e=o._queueLoadingCallback(e),o._prepareFontLoadEvent([n],[t],e)}));case 26:case"end":return e.stop()}}),e,this,[[7,12]])})),r=function(){var e=this,r=arguments;return new Promise((function(n,i){var a=t.apply(e,r);function o(e){c(a,n,i,o,s,"next",e)}function s(e){c(a,n,i,o,s,"throw",e)}o(void 0)}))},function(e){return r.apply(this,arguments)})},{key:"_queueLoadingCallback",value:function(e){(0,a.unreachable)("Abstract method `_queueLoadingCallback`.")}},{key:"_prepareFontLoadEvent",value:function(e,t,r){(0,a.unreachable)("Abstract method `_prepareFontLoadEvent`.")}},{key:"isFontLoadingAPISupported",get:function(){var e=void 0!==this._document&&!!this._document.fonts;return(0,a.shadow)(this,"isFontLoadingAPISupported",e)}},{key:"isSyncFontLoadingSupported",get:function(){(0,a.unreachable)("Abstract method `isSyncFontLoadingSupported`.")}},{key:"_loadTestFont",get:function(){(0,a.unreachable)("Abstract method `_loadTestFont`.")}}]),e}();t.FontLoader=void 0,t.FontLoader=function(){!function(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}}),t&&s(e,t)}(t,p);var e=u(t);function t(r){return h(this,t),(r=e.call(this,r)).loadingContext={requests:[],nextRequestId:0},r.loadTestFontId=0,r}return d(t,[{key:"_queueLoadingCallback",value:function(e){var t=this.loadingContext,r={id:"pdfjs-font-loading-".concat(t.nextRequestId++),done:!1,complete:function(){for((0,a.assert)(!r.done,"completeRequest() cannot be called twice."),r.done=!0;0<t.requests.length&&t.requests[0].done;){var e=t.requests.shift();setTimeout(e.callback,0)}},callback:e};return t.requests.push(r),r}},{key:"_prepareFontLoadEvent",value:function(e,t,r){var n=this;function i(e,t){return e.charCodeAt(t)<<24|e.charCodeAt(t+1)<<16|e.charCodeAt(t+2)<<8|255&e.charCodeAt(t+3)}function o(e,t,r,n){return e.substring(0,t)+n+e.substring(t+r)}var s=this._document.createElement("canvas");s.width=1,s.height=1;var u=s.getContext("2d"),l=0;function c(e,t){if(30<++l)return(0,a.warn)("Load test font never loaded."),void t();u.font="30px "+e,u.fillText(".",0,20),0<u.getImageData(0,0,1,1).data[3]?t():setTimeout(c.bind(null,e,t))}for(var h="lt".concat(Date.now()).concat(this.loadTestFontId++),f=(s=this._loadTestFont,i(s=o(s,976,h.length,h),16)),d=0,p=h.length-3;d<p;d+=4)f=f-1482184792+i(h,d)|0;d<h.length&&(f=f-1482184792+i(h+"XXX",d)|0),s=o(s,16,4,(0,a.string32)(f)),s="url(data:font/opentype;base64,".concat(btoa(s),");"),s='@font-face {font-family:"'.concat(h,'";src:').concat(s,"}"),this.insertRule(s);var v=[];for(d=0,p=t.length;d<p;d++)v.push(t[d].loadedName);v.push(h);var g=this._document.createElement("div");for(g.style.visibility="hidden",g.style.width=g.style.height="10px",g.style.position="absolute",g.style.top=g.style.left="0px",d=0,p=v.length;d<p;++d){var y=this._document.createElement("span");y.textContent="Hi",y.style.fontFamily=v[d],g.appendChild(y)}this._document.body.appendChild(g),c(h,(function(){n._document.body.removeChild(g),r.complete()}))}},{key:"isSyncFontLoadingSupported",get:function(){var e,t=!1;return("undefined"==typeof navigator||(e=/Mozilla\/5.0.*?rv:(\d+).*? Gecko/.exec(navigator.userAgent))&&14<=e[1])&&(t=!0),(0,a.shadow)(this,"isSyncFontLoadingSupported",t)}},{key:"_loadTestFont",get:function(){return(0,a.shadow)(this,"_loadTestFont",atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="))}}]),t}(),t.FontFaceObject=function(){function e(t,r){var n,i=r.isEvalSupported,a=void 0===i||i,o=r.disableFontFace,s=void 0!==o&&o;i=r.ignoreErrors,o=void 0!==i&&i,i=r.onUnsupportedFeature,i=void 0===i?null:i,r=r.fontRegistry,r=void 0===r?null:r;for(n in h(this,e),this.compiledGlyphs=Object.create(null),t)this[n]=t[n];this.isEvalSupported=!1!==a,this.disableFontFace=!0===s,this.ignoreErrors=!0===o,this._onUnsupportedFeature=i,this.fontRegistry=r}return d(e,[{key:"createNativeFontFace",value:function(){if(!this.data||this.disableFontFace)return null;var e=new FontFace(this.loadedName,this.data,{});return this.fontRegistry&&this.fontRegistry.registerFont(this),e}},{key:"createFontFaceRule",value:function(){if(!this.data||this.disableFontFace)return null;var e=(0,a.bytesToString)(new Uint8Array(this.data)),t="url(data:".concat(this.mimetype,";base64,").concat(btoa(e),");");e='@font-face {font-family:"'.concat(this.loadedName,'";src:').concat(t,"}");return this.fontRegistry&&this.fontRegistry.registerFont(this,t),e}},{key:"getPathGenerator",value:function(e,t){if(void 0!==this.compiledGlyphs[t])return this.compiledGlyphs[t];var r,n;try{r=e.get(this.loadedName+"_path_"+t)}catch(e){if(!this.ignoreErrors)throw e;return this._onUnsupportedFeature&&this._onUnsupportedFeature({featureId:a.UNSUPPORTED_FEATURES.errorFontGetPath}),(0,a.warn)('getPathGenerator - ignoring character: "'.concat(e,'".')),this.compiledGlyphs[t]=function(e,t){}}if(this.isEvalSupported&&a.IsEvalSupportedCached.value){for(var i,o="",s=0,u=r.length;s<u;s++)i=void 0!==(n=r[s]).args?n.args.join(","):"",o+="c."+n.cmd+"("+i+");\n";return this.compiledGlyphs[t]=new Function("c","size",o)}return this.compiledGlyphs[t]=function(e,t){for(var i=0,a=r.length;i<a;i++)"scale"===(n=r[i]).cmd&&(n.args=[t,-t]),e[n.cmd].apply(e,n.args)}}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NodeCMapReaderFactory=t.NodeCanvasFactory=void 0;var n=r(1),i=r(7),a=r(5);function o(e){return(o="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)}function s(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,n.key,n)}}function u(e,t,r){return t&&s(e.prototype,t),r&&s(e,r),e}function l(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}}),t&&c(e,t)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=f(t);return e=r?(e=f(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==o(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function d(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.NodeCanvasFactory=function e(){d(this,e),(0,a.unreachable)("Not implemented: NodeCanvasFactory")},t.NodeCMapReaderFactory=function e(){d(this,e),(0,a.unreachable)("Not implemented: NodeCMapReaderFactory")},i.isNodeJS&&(t.NodeCanvasFactory=function(){l(t,n.BaseCanvasFactory);var e=h(t);function t(){return d(this,t),e.apply(this,arguments)}return u(t,[{key:"create",value:function(e,t){if(e<=0||t<=0)throw new Error("Invalid canvas size");return t=__webpack_require__(19).createCanvas(e,t),{canvas:t,context:t.getContext("2d")}}}]),t}(),t.NodeCMapReaderFactory=function(){l(t,n.BaseCMapReaderFactory);var e=h(t);function t(){return d(this,t),e.apply(this,arguments)}return u(t,[{key:"_fetchData",value:function(e,t){return new Promise((function(r,n){__webpack_require__(18).readFile(e,(function(e,i){!e&&i?r({cMapData:new Uint8Array(i),compressionType:t}):n(new Error(e))}))}))}}]),t}())},function(e,t,r){"use strict";function n(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,n.key,n)}}Object.defineProperty(t,"__esModule",{value:!0}),t.AnnotationStorage=void 0,t.AnnotationStorage=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._storage=new Map,this._modified=!1,this.onSetModified=null,this.onResetModified=null}var t,r,i;return t=e,(r=[{key:"getOrCreateValue",value:function(e,t){return this._storage.has(e)?this._storage.get(e):(this._storage.set(e,t),t)}},{key:"setValue",value:function(e,t){this._storage.get(e)!==t&&this._setModified(),this._storage.set(e,t)}},{key:"getAll",value:function(){return 0===this._storage.size?null:Object.fromEntries(this._storage)}},{key:"_setModified",value:function(){this._modified||(this._modified=!0,"function"==typeof this.onSetModified&&this.onSetModified())}},{key:"resetModified",value:function(){this._modified&&(this._modified=!1,"function"==typeof this.onResetModified&&this.onResetModified())}},{key:"size",get:function(){return this._storage.size}}])&&n(t.prototype,r),i&&n(t,i),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.apiCompatibilityParams=void 0;var n=r(7);r=Object.create(null);n.isNodeJS&&(r.disableFontFace=!0),r=Object.freeze(r),t.apiCompatibilityParams=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CanvasGraphics=void 0;var n=r(5),i=r(208);function a(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return o(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,s=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw i}}}}function o(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 s(e){e.mozCurrentTransform||(e._originalSave=e.save,e._originalRestore=e.restore,e._originalRotate=e.rotate,e._originalScale=e.scale,e._originalTranslate=e.translate,e._originalTransform=e.transform,e._originalSetTransform=e.setTransform,e._transformMatrix=e._transformMatrix||[1,0,0,1,0,0],e._transformStack=[],Object.defineProperty(e,"mozCurrentTransform",{get:function(){return this._transformMatrix}}),Object.defineProperty(e,"mozCurrentTransformInverse",{get:function(){var e=this._transformMatrix,t=e[0],r=e[1],n=e[2],i=e[3],a=e[4],o=e[5],s=t*i-r*n;e=r*n-t*i;return[i/s,r/e,n/e,t/s,(i*a-n*o)/e,(r*a-t*o)/s]}}),e.save=function(){var e=this._transformMatrix;this._transformStack.push(e),this._transformMatrix=e.slice(0,6),this._originalSave()},e.restore=function(){var e=this._transformStack.pop();e&&(this._transformMatrix=e,this._originalRestore())},e.translate=function(e,t){var r=this._transformMatrix;r[4]=r[0]*e+r[2]*t+r[4],r[5]=r[1]*e+r[3]*t+r[5],this._originalTranslate(e,t)},e.scale=function(e,t){var r=this._transformMatrix;r[0]=r[0]*e,r[1]=r[1]*e,r[2]=r[2]*t,r[3]=r[3]*t,this._originalScale(e,t)},e.transform=function(t,r,n,i,a,o){var s=this._transformMatrix;this._transformMatrix=[s[0]*t+s[2]*r,s[1]*t+s[3]*r,s[0]*n+s[2]*i,s[1]*n+s[3]*i,s[0]*a+s[2]*o+s[4],s[1]*a+s[3]*o+s[5]],e._originalTransform(t,r,n,i,a,o)},e.setTransform=function(t,r,n,i,a,o){this._transformMatrix=[t,r,n,i,a,o],e._originalSetTransform(t,r,n,i,a,o)},e.rotate=function(e){var t=Math.cos(e),r=Math.sin(e),n=this._transformMatrix;this._transformMatrix=[n[0]*t+n[2]*r,n[1]*t+n[3]*r,n[0]*-r+n[2]*t,n[1]*-r+n[3]*t,n[4],n[5]],this._originalRotate(e)})}var u=(l.prototype={getCanvas:function(e,t,r,n){var i;return void 0!==this.cache[e]?(i=this.cache[e],this.canvasFactory.reset(i,t,r),i.context.setTransform(1,0,0,1,0,0)):(i=this.canvasFactory.create(t,r),this.cache[e]=i),n&&s(i.context),i},clear:function(){for(var e in this.cache){var t=this.cache[e];this.canvasFactory.destroy(t),delete this.cache[e]}}},l);function l(e){this.canvasFactory=e,this.cache=Object.create(null)}var c=(h.prototype={clone:function(){return Object.create(this)},setCurrentPoint:function(e,t){this.x=e,this.y=t}},h);function h(){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=n.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=n.FONT_IDENTITY_MATRIX,this.leading=0,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRenderingMode=n.TextRenderingMode.FILL,this.textRise=0,this.fillColor="#000000",this.strokeColor="#000000",this.patternFill=!1,this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.activeSMask=null,this.resumeSMaskCtx=null,this.transferMaps=null}r=function(){function e(e,t,r,n,i,a,o){this.ctx=e,this.current=new c,this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=t,this.objs=r,this.canvasFactory=n,this.webGLContext=i,this.imageLayer=a,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.contentVisible=!0,this.markedContentStack=[],this.optionalContentConfig=o,this.cachedCanvases=new u(this.canvasFactory),e&&s(e),this._cachedGetSinglePixelWidth=null}function t(e,t,r){var i=2<arguments.length&&void 0!==r?r:null;if("undefined"!=typeof ImageData&&t instanceof ImageData)e.putImageData(t,0,0);else{r=t.height;var a,o,s,u,l,c=t.width,h=r%16,f=(r-h)/16,d=0==h?f:1+f,p=e.createImageData(c,16),v=0,g=t.data,y=p.data;if(i)switch(i.length){case 1:o=i[0],s=i[0],u=i[0],l=i[0];break;case 4:o=i[0],s=i[1],u=i[2],l=i[3]}if(t.kind===n.ImageKind.GRAYSCALE_1BPP){var m=g.byteLength,b=new Uint32Array(y.buffer,0,y.byteLength>>2),_=b.length,w=c+7>>3,A=4294967295,S=n.IsLittleEndianCached.value?4278190080:255;for(l&&255===l[0]&&0===l[255]&&(A=(r=[S,A])[0],S=r[1]),I=0;I<d;I++){for(N=I<f?16:h,O=a=0;O<N;O++){for(var k=m-v,x=0,P=w<k?c:8*k-7,C=-8&P,T=0,R=0;x<C;x+=8)R=g[v++],b[a++]=128&R?A:S,b[a++]=64&R?A:S,b[a++]=32&R?A:S,b[a++]=16&R?A:S,b[a++]=8&R?A:S,b[a++]=4&R?A:S,b[a++]=2&R?A:S,b[a++]=1&R?A:S;for(;x<P;x++)0===T&&(R=g[v++],T=128),b[a++]=R&T?A:S,T>>=1}for(;a<_;)b[a++]=0;e.putImageData(p,0,16*I)}}else if(t.kind===n.ImageKind.RGBA_32BPP){for(var E=!!(o||s||u),O=0,L=16*c*4,I=0;I<f;I++){if(y.set(g.subarray(v,v+L)),v+=L,E)for(var F=0;F<L;F+=4)o&&(y[F+0]=o[y[F+0]]),s&&(y[F+1]=s[y[F+1]]),u&&(y[F+2]=u[y[F+2]]);e.putImageData(p,0,O),O+=16}if(I<d){if(y.set(g.subarray(v,v+(L=c*h*4))),E)for(var M=0;M<L;M+=4)o&&(y[M+0]=o[y[M+0]]),s&&(y[M+1]=s[y[M+1]]),u&&(y[M+2]=u[y[M+2]]);e.putImageData(p,0,O)}}else{if(t.kind!==n.ImageKind.RGB_24BPP)throw new Error("bad image kind: ".concat(t.kind));var N,D=!!(o||s||u);for(L=c*(N=16),I=0;I<d;I++){for(a=0,O=L=f<=I?c*(N=h):L;O--;)y[a++]=g[v++],y[a++]=g[v++],y[a++]=g[v++],y[a++]=255;if(D)for(var j=0;j<a;j+=4)o&&(y[j+0]=o[y[j+0]]),s&&(y[j+1]=s[y[j+1]]),u&&(y[j+2]=u[y[j+2]]);e.putImageData(p,0,16*I)}}}}function r(e,t){for(var r=t.height,n=t.width,i=r%16,a=(r-i)/16,o=0==i?a:1+a,s=e.createImageData(n,16),u=0,l=t.data,c=s.data,h=0;h<o;h++){for(var f=h<a?16:i,d=3,p=0;p<f;p++)for(var v,g=0,y=0;y<n;y++)g||(v=l[u++],g=128),c[d]=v&g?0:255,d+=4,g>>=1;e.putImageData(s,0,16*h)}}function o(e,t){for(var r=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font"],n=0,i=r.length;n<i;n++){var a=r[n];void 0!==e[a]&&(t[a]=e[a])}void 0!==e.setLineDash&&(t.setLineDash(e.getLineDash()),t.lineDashOffset=e.lineDashOffset)}function l(e){e.strokeStyle="#000000",e.fillStyle="#000000",e.fillRule="nonzero",e.globalAlpha=1,e.lineWidth=1,e.lineCap="butt",e.lineJoin="miter",e.miterLimit=10,e.globalCompositeOperation="source-over",e.font="10px sans-serif",void 0!==e.setLineDash&&(e.setLineDash([]),e.lineDashOffset=0)}function h(e,t,r){for(var n=e.length,i=3;i<n;i+=4){var a=r?r[e[i]]:e[i];t[i]=t[i]*a*(1/255)|0}}function f(e,t,r){for(var n=e.length,i=3;i<n;i+=4){var a=77*e[i-3]+152*e[i-2]+28*e[i-1];t[i]=r?t[i]*r[a>>8]>>8:t[i]*a>>16}}function d(e,t,r,n,i,a,o){for(var s=!!a,u=s?a[0]:0,l=s?a[1]:0,c=s?a[2]:0,d="Luminosity"===i?f:h,p=Math.min(n,Math.ceil(1048576/r)),v=0;v<n;v+=p){var g=Math.min(p,n-v),y=e.getImageData(0,v,r,g);g=t.getImageData(0,v,r,g);s&&function(e,t,r,n){for(var i=e.length,a=3;a<i;a+=4){var o,s=e[a];0===s?(e[a-3]=t,e[a-2]=r,e[a-1]=n):s<255&&(e[a-3]=e[a-3]*s+t*(o=255-s)>>8,e[a-2]=e[a-2]*s+r*o>>8,e[a-1]=e[a-1]*s+n*o>>8)}}(y.data,u,l,c),d(y.data,g.data,o),e.putImageData(g,0,v)}}function p(e,t,r,n){var i=t.canvas,a=t.context;e.setTransform(t.scaleX,0,0,t.scaleY,t.offsetX,t.offsetY);var o=t.backdrop||null;if(!t.transferMap&&n.isEnabled)return n=n.composeSMask({layer:r.canvas,mask:i,properties:{subtype:t.subtype,backdrop:o}}),e.setTransform(1,0,0,1,0,0),void e.drawImage(n,t.offsetX,t.offsetY);d(a,r,i.width,i.height,t.subtype,o,t.transferMap),e.drawImage(i,0,0)}var v,g=["butt","round","square"],y=["miter","round","bevel"],m={},b={};for(v in e.prototype={beginDrawing:function(e){var t=e.transform,r=e.viewport,n=e.transparency,i=void 0!==n&&n,a=e.background;n=void 0===a?null:a,e=this.ctx.canvas.width,a=this.ctx.canvas.height;this.ctx.save(),this.ctx.fillStyle=n||"rgb(255, 255, 255)",this.ctx.fillRect(0,0,e,a),this.ctx.restore(),i&&(a=this.cachedCanvases.getCanvas("transparent",e,a,!0),this.compositeCtx=this.ctx,this.transparentCanvas=a.canvas,this.ctx=a.context,this.ctx.save(),this.ctx.transform.apply(this.ctx,this.compositeCtx.mozCurrentTransform)),this.ctx.save(),l(this.ctx),t&&this.ctx.transform.apply(this.ctx,t),this.ctx.transform.apply(this.ctx,r.transform),this.baseTransform=this.ctx.mozCurrentTransform.slice(),this.imageLayer&&this.imageLayer.beginLayout()},executeOperatorList:function(e,t,r,i){var o=e.argsArray,s=e.fnArray,u=t||0,l=o.length;if(l===u)return u;for(var c,h=10<l-u&&"function"==typeof r,f=h?Date.now()+15:0,d=0,p=this.commonObjs,v=this.objs;;){if(void 0!==i&&u===i.nextBreakPoint)return i.breakIt(u,r),u;if((c=s[u])!==n.OPS.dependency)this[c].apply(this,o[u]);else{var g,y=a(o[u]);try{for(y.s();!(g=y.n()).done;){var m=g.value,b=m.startsWith("g_")?p:v;if(!b.has(m))return b.get(m,r),u}}catch(e){y.e(e)}finally{y.f()}}if(++u===l)return u;if(h&&10<++d){if(Date.now()>f)return r(),u;d=0}}},endDrawing:function(){null!==this.current.activeSMask&&this.endSMaskGroup(),this.ctx.restore(),this.transparentCanvas&&(this.ctx=this.compositeCtx,this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.drawImage(this.transparentCanvas,0,0),this.ctx.restore(),this.transparentCanvas=null),this.cachedCanvases.clear(),this.webGLContext.clear(),this.imageLayer&&this.imageLayer.endLayout()},setLineWidth:function(e){this.current.lineWidth=e,this.ctx.lineWidth=e},setLineCap:function(e){this.ctx.lineCap=g[e]},setLineJoin:function(e){this.ctx.lineJoin=y[e]},setMiterLimit:function(e){this.ctx.miterLimit=e},setDash:function(e,t){var r=this.ctx;void 0!==r.setLineDash&&(r.setLineDash(e),r.lineDashOffset=t)},setRenderingIntent:function(e){},setFlatness:function(e){},setGState:function(e){for(var t=0,r=e.length;t<r;t++){var n=e[t],i=n[0],a=n[1];switch(i){case"LW":this.setLineWidth(a);break;case"LC":this.setLineCap(a);break;case"LJ":this.setLineJoin(a);break;case"ML":this.setMiterLimit(a);break;case"D":this.setDash(a[0],a[1]);break;case"RI":this.setRenderingIntent(a);break;case"FL":this.setFlatness(a);break;case"Font":this.setFont(a[0],a[1]);break;case"CA":this.current.strokeAlpha=n[1];break;case"ca":this.current.fillAlpha=n[1],this.ctx.globalAlpha=n[1];break;case"BM":this.ctx.globalCompositeOperation=a;break;case"SMask":this.current.activeSMask&&(0<this.stateStack.length&&this.stateStack[this.stateStack.length-1].activeSMask===this.current.activeSMask?this.suspendSMaskGroup():this.endSMaskGroup()),this.current.activeSMask=a?this.tempSMask:null,this.current.activeSMask&&this.beginSMaskGroup(),this.tempSMask=null;break;case"TR":this.current.transferMaps=a}}},beginSMaskGroup:function(){var e=this.current.activeSMask,t=e.canvas.width,r=e.canvas.height,n="smaskGroupAt"+this.groupLevel;n=this.cachedCanvases.getCanvas(n,t,r,!0),t=this.ctx,r=t.mozCurrentTransform;this.ctx.save(),n=n.context,n.scale(1/e.scaleX,1/e.scaleY),n.translate(-e.offsetX,-e.offsetY),n.transform.apply(n,r),e.startTransformInverse=n.mozCurrentTransformInverse,o(t,n),this.ctx=n,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(t),this.groupLevel++},suspendSMaskGroup:function(){var e=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),p(this.ctx,this.current.activeSMask,e,this.webGLContext),this.ctx.restore(),this.ctx.save(),o(e,this.ctx),this.current.resumeSMaskCtx=e;var t=n.Util.transform(this.current.activeSMask.startTransformInverse,e.mozCurrentTransform);this.ctx.transform.apply(this.ctx,t),e.save(),e.setTransform(1,0,0,1,0,0),e.clearRect(0,0,e.canvas.width,e.canvas.height),e.restore()},resumeSMaskGroup:function(){var e=this.current.resumeSMaskCtx,t=this.ctx;this.ctx=e,this.groupStack.push(t),this.groupLevel++},endSMaskGroup:function(){var e=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),p(this.ctx,this.current.activeSMask,e,this.webGLContext),this.ctx.restore(),o(e,this.ctx),e=n.Util.transform(this.current.activeSMask.startTransformInverse,e.mozCurrentTransform),this.ctx.transform.apply(this.ctx,e)},save:function(){this.ctx.save();var e=this.current;this.stateStack.push(e),this.current=e.clone(),this.current.resumeSMaskCtx=null},restore:function(){this.current.resumeSMaskCtx&&this.resumeSMaskGroup(),null===this.current.activeSMask||0!==this.stateStack.length&&this.stateStack[this.stateStack.length-1].activeSMask===this.current.activeSMask||this.endSMaskGroup(),0!==this.stateStack.length&&(this.current=this.stateStack.pop(),this.ctx.restore(),this.pendingClip=null,this._cachedGetSinglePixelWidth=null)},transform:function(e,t,r,n,i,a){this.ctx.transform(e,t,r,n,i,a),this._cachedGetSinglePixelWidth=null},constructPath:function(e,t){for(var r=this.ctx,i=this.current,a=i.x,o=i.y,s=0,u=0,l=e.length;s<l;s++)switch(0|e[s]){case n.OPS.rectangle:a=t[u++],o=t[u++];var c=t[u++],h=t[u++];c=a+(c=0===c&&r.lineWidth<this.getSinglePixelWidth()?this.getSinglePixelWidth():c),h=o+(h=0===h&&r.lineWidth<this.getSinglePixelWidth()?this.getSinglePixelWidth():h);r.moveTo(a,o),r.lineTo(c,o),r.lineTo(c,h),r.lineTo(a,h),r.lineTo(a,o),r.closePath();break;case n.OPS.moveTo:a=t[u++],o=t[u++],r.moveTo(a,o);break;case n.OPS.lineTo:a=t[u++],o=t[u++],r.lineTo(a,o);break;case n.OPS.curveTo:a=t[u+4],o=t[u+5],r.bezierCurveTo(t[u],t[u+1],t[u+2],t[u+3],a,o),u+=6;break;case n.OPS.curveTo2:r.bezierCurveTo(a,o,t[u],t[u+1],t[u+2],t[u+3]),a=t[u+2],o=t[u+3],u+=4;break;case n.OPS.curveTo3:a=t[u+2],o=t[u+3],r.bezierCurveTo(t[u],t[u+1],a,o,a,o),u+=4;break;case n.OPS.closePath:r.closePath()}i.setCurrentPoint(a,o)},closePath:function(){this.ctx.closePath()},stroke:function(e){e=void 0===e||e;var t,r=this.ctx,i=this.current.strokeColor;r.globalAlpha=this.current.strokeAlpha,this.contentVisible&&(i&&i.hasOwnProperty("type")&&"Pattern"===i.type?(r.save(),t=r.mozCurrentTransform,t=n.Util.singularValueDecompose2dScale(t)[0],r.strokeStyle=i.getPattern(r,this),r.lineWidth=Math.max(.65*this.getSinglePixelWidth(),this.current.lineWidth*t),r.stroke(),r.restore()):(r.lineWidth=Math.max(.65*this.getSinglePixelWidth(),this.current.lineWidth),r.stroke())),e&&this.consumePath(),r.globalAlpha=this.current.fillAlpha},closeStroke:function(){this.closePath(),this.stroke()},fill:function(e){e=void 0===e||e;var t=this.ctx,r=this.current.fillColor,n=!1;this.current.patternFill&&(t.save(),this.baseTransform&&t.setTransform.apply(t,this.baseTransform),t.fillStyle=r.getPattern(t,this),n=!0),this.contentVisible&&(this.pendingEOFill?(t.fill("evenodd"),this.pendingEOFill=!1):t.fill()),n&&t.restore(),e&&this.consumePath()},eoFill:function(){this.pendingEOFill=!0,this.fill()},fillStroke:function(){this.fill(!1),this.stroke(!1),this.consumePath()},eoFillStroke:function(){this.pendingEOFill=!0,this.fillStroke()},closeFillStroke:function(){this.closePath(),this.fillStroke()},closeEOFillStroke:function(){this.pendingEOFill=!0,this.closePath(),this.fillStroke()},endPath:function(){this.consumePath()},clip:function(){this.pendingClip=m},eoClip:function(){this.pendingClip=b},beginText:function(){this.current.textMatrix=n.IDENTITY_MATRIX,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0},endText:function(){var e=this.pendingTextPaths,t=this.ctx;if(void 0!==e){t.save(),t.beginPath();for(var r=0;r<e.length;r++){var n=e[r];t.setTransform.apply(t,n.transform),t.translate(n.x,n.y),n.addToPath(t,n.fontSize)}t.restore(),t.clip(),t.beginPath(),delete this.pendingTextPaths}else t.beginPath()},setCharSpacing:function(e){this.current.charSpacing=e},setWordSpacing:function(e){this.current.wordSpacing=e},setHScale:function(e){this.current.textHScale=e/100},setLeading:function(e){this.current.leading=-e},setFont:function(e,t){var r,i=this.commonObjs.get(e),a=this.current;if(!i)throw new Error("Can't find font for ".concat(e));a.fontMatrix=i.fontMatrix||n.FONT_IDENTITY_MATRIX,0!==a.fontMatrix[0]&&0!==a.fontMatrix[3]||(0,n.warn)("Invalid font matrix for font "+e),t<0?(t=-t,a.fontDirection=-1):a.fontDirection=1,this.current.font=i,this.current.fontSize=t,i.isType3Font||(r=i.loadedName||"sans-serif",e="normal",i.black?e="900":i.bold&&(e="bold"),a=i.italic?"italic":"normal",r='"'.concat(r,'", ').concat(i.fallbackName),(i=t)<16?i=16:100<t&&(i=100),this.current.fontSizeScale=t/i,this.ctx.font="".concat(a," ").concat(e," ").concat(i,"px ").concat(r))},setTextRenderingMode:function(e){this.current.textRenderingMode=e},setTextRise:function(e){this.current.textRise=e},moveText:function(e,t){this.current.x=this.current.lineX+=e,this.current.y=this.current.lineY+=t},setLeadingMoveText:function(e,t){this.setLeading(-t),this.moveText(e,t)},setTextMatrix:function(e,t,r,n,i,a){this.current.textMatrix=[e,t,r,n,i,a],this.current.textMatrixScale=Math.sqrt(e*e+t*t),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0},nextLine:function(){this.moveText(0,this.current.leading)},paintChar:function(e,t,r,i){var a,o=this.ctx,s=this.current,u=s.font,l=s.textRenderingMode,c=s.fontSize/s.fontSizeScale,h=l&n.TextRenderingMode.FILL_STROKE_MASK;l=!!(l&n.TextRenderingMode.ADD_TO_PATH_FLAG),s=s.patternFill&&!u.missingFile;(u.disableFontFace||l||s)&&(a=u.getPathGenerator(this.commonObjs,e)),u.disableFontFace||s?(o.save(),o.translate(t,r),o.beginPath(),a(o,c),i&&o.setTransform.apply(o,i),h!==n.TextRenderingMode.FILL&&h!==n.TextRenderingMode.FILL_STROKE||o.fill(),h!==n.TextRenderingMode.STROKE&&h!==n.TextRenderingMode.FILL_STROKE||o.stroke(),o.restore()):(h!==n.TextRenderingMode.FILL&&h!==n.TextRenderingMode.FILL_STROKE||o.fillText(e,t,r),h!==n.TextRenderingMode.STROKE&&h!==n.TextRenderingMode.FILL_STROKE||o.strokeText(e,t,r)),l&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:o.mozCurrentTransform,x:t,y:r,fontSize:c,addToPath:a})},get isFontSubpixelAAEnabled(){var e=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10).context;e.scale(1.5,1),e.fillText("I",0,10);for(var t=e.getImageData(0,0,10,10).data,r=!1,i=3;i<t.length;i+=4)if(0<t[i]&&t[i]<255){r=!0;break}return(0,n.shadow)(this,"isFontSubpixelAAEnabled",r)},showText:function(e){var t=this.current,r=t.font;if(r.isType3Font)return this.showType3Text(e);var i=t.fontSize;if(0!==i){var a,o=this.ctx,s=t.fontSizeScale,u=t.charSpacing,l=t.wordSpacing,c=t.fontDirection,h=t.textHScale*c,f=e.length,d=r.vertical,p=d?1:-1,v=r.defaultVMetrics,g=i*t.fontMatrix[0],y=t.textRenderingMode===n.TextRenderingMode.FILL&&!r.disableFontFace&&!t.patternFill;o.save(),t.patternFill&&(o.save(),m=t.fillColor.getPattern(o,this),a=o.mozCurrentTransform,o.restore(),o.fillStyle=m),o.transform.apply(o,t.textMatrix),o.translate(t.x,t.y+t.textRise),0<c?o.scale(h,-1):o.scale(h,1);var m,b=t.lineWidth,_=t.textMatrixScale;0===_||0===b?(m=t.textRenderingMode&n.TextRenderingMode.FILL_STROKE_MASK)!==n.TextRenderingMode.STROKE&&m!==n.TextRenderingMode.FILL_STROKE||(this._cachedGetSinglePixelWidth=null,b=.65*this.getSinglePixelWidth()):b/=_,1!==s&&(o.scale(s,s),b/=s),o.lineWidth=b;for(var w=0,A=0;A<f;++A){var S,k,x,P,C,T,R,E,O,L=e[A];(0,n.isNum)(L)?w+=p*L*i/1e3:(O=!1,S=(L.isSpace?l:0)+u,x=L.fontChar,k=L.accent,P=L.width,T=d?(T=L.vmetric||v,R=L.vmetric?T[1]:.5*P,E=T[2]*g,P=T?-T[0]:P,C=(R=-R*g)/s,(w+E)/s):(C=w/s,0),r.remeasure&&0<P&&(P<(R=1e3*o.measureText(x).width/i*s)&&this.isFontSubpixelAAEnabled?(E=P/R,O=!0,o.save(),o.scale(E,1),C/=E):P!==R&&(C+=(P-R)/2e3*i/s)),this.contentVisible&&(L.isInFont||r.missingFile)&&(y&&!k?o.fillText(x,C,T):(this.paintChar(x,C,T,a),k&&(x=C+i*k.offset.x/s,T-=i*k.offset.y/s,this.paintChar(k.fontChar,x,T,a)))),w+=d?P*g-S*c:P*g+S*c,O&&o.restore())}d?t.y-=w:t.x+=w*h,o.restore()}},showType3Text:function(e){var t,r=this.ctx,i=this.current,a=i.font,o=i.fontSize,s=i.fontDirection,u=a.vertical?1:-1,l=i.charSpacing,c=i.wordSpacing,h=i.textHScale*s,f=i.fontMatrix||n.FONT_IDENTITY_MATRIX,d=e.length;if(i.textRenderingMode!==n.TextRenderingMode.INVISIBLE&&0!==o){for(this._cachedGetSinglePixelWidth=null,r.save(),r.transform.apply(r,i.textMatrix),r.translate(i.x,i.y),r.scale(h,s),t=0;t<d;++t){var p,v,g=e[t];(0,n.isNum)(g)?(this.ctx.translate(p=u*g*o/1e3,0),i.x+=p*h):(v=(g.isSpace?c:0)+l,(p=a.charProcOperatorList[g.operatorListId])?(this.contentVisible&&(this.processingType3=g,this.save(),r.scale(o,o),r.transform.apply(r,f),this.executeOperatorList(p),this.restore()),v=n.Util.applyTransform([g.width,0],f)[0]*o+v,r.translate(v,0),i.x+=v*h):(0,n.warn)('Type3 character "'.concat(g.operatorListId,'" is not available.')))}r.restore(),this.processingType3=null}},setCharWidth:function(e,t){},setCharWidthAndBounds:function(e,t,r,n,i,a){this.ctx.rect(r,n,i-r,a-n),this.clip(),this.endPath()},getColorN_Pattern:function(t){var r,n,a=this;return"TilingPattern"===t[0]?(r=t[1],n=this.baseTransform||this.ctx.mozCurrentTransform.slice(),new i.TilingPattern(t,r,this.ctx,{createCanvasGraphics:function(t){return new e(t,a.commonObjs,a.objs,a.canvasFactory,a.webGLContext)}},n)):(0,i.getShadingPatternFromIR)(t)},setStrokeColorN:function(){this.current.strokeColor=this.getColorN_Pattern(arguments)},setFillColorN:function(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0},setStrokeRGBColor:function(e,t,r){r=n.Util.makeCssRgb(e,t,r),this.ctx.strokeStyle=r,this.current.strokeColor=r},setFillRGBColor:function(e,t,r){r=n.Util.makeCssRgb(e,t,r),this.ctx.fillStyle=r,this.current.fillColor=r,this.current.patternFill=!1},shadingFill:function(e){var t,r,a,o,s,u;this.contentVisible&&(r=this.ctx,this.save(),t=(0,i.getShadingPatternFromIR)(e),r.fillStyle=t.getPattern(r,this,!0),(s=r.mozCurrentTransformInverse)?(a=(u=r.canvas).width,o=u.height,e=n.Util.applyTransform([0,0],s),t=n.Util.applyTransform([0,o],s),r=n.Util.applyTransform([a,0],s),u=n.Util.applyTransform([a,o],s),a=Math.min(e[0],t[0],r[0],u[0]),o=Math.min(e[1],t[1],r[1],u[1]),s=Math.max(e[0],t[0],r[0],u[0]),u=Math.max(e[1],t[1],r[1],u[1]),this.ctx.fillRect(a,o,s-a,u-o)):this.ctx.fillRect(-1e10,-1e10,2e10,2e10),this.restore())},beginInlineImage:function(){(0,n.unreachable)("Should not call beginInlineImage")},beginImageData:function(){(0,n.unreachable)("Should not call beginImageData")},paintFormXObjectBegin:function(e,t){var r;this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(e)&&6===e.length&&this.transform.apply(this,e),this.baseTransform=this.ctx.mozCurrentTransform,t&&(r=t[2]-t[0],e=t[3]-t[1],this.ctx.rect(t[0],t[1],r,e),this.clip(),this.endPath()))},paintFormXObjectEnd:function(){this.contentVisible&&(this.restore(),this.baseTransform=this.baseTransformStack.pop())},beginGroup:function(e){if(this.contentVisible){this.save();var t=this.ctx;e.isolated||(0,n.info)("TODO: Support non-isolated groups."),e.knockout&&(0,n.warn)("Knockout groups not supported.");var r=t.mozCurrentTransform;if(e.matrix&&t.transform.apply(t,e.matrix),!e.bbox)throw new Error("Bounding box is required.");var i=n.Util.getAxialAlignedBoundingBox(e.bbox,t.mozCurrentTransform),a=[0,0,t.canvas.width,t.canvas.height],s=(i=n.Util.intersect(i,a)||[0,0,0,0],Math.floor(i[0])),u=Math.floor(i[1]),l=Math.max(Math.ceil(i[2])-s,1),c=Math.max(Math.ceil(i[3])-u,1),h=1;a=1;4096<l&&(h=l/4096,l=4096),4096<c&&(a=c/4096,c=4096),i="groupAt"+this.groupLevel,e.smask&&(i+="_smask_"+this.smaskCounter++%2),l=this.cachedCanvases.getCanvas(i,l,c,!0),c=l.context,c.scale(1/h,1/a),c.translate(-s,-u),c.transform.apply(c,r),e.smask?this.smaskStack.push({canvas:l.canvas,context:c,offsetX:s,offsetY:u,scaleX:h,scaleY:a,subtype:e.smask.subtype,backdrop:e.smask.backdrop,transferMap:e.smask.transferMap||null,startTransformInverse:null}):(t.setTransform(1,0,0,1,0,0),t.translate(s,u),t.scale(h,a)),o(t,c),this.ctx=c,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(t),this.groupLevel++,this.current.activeSMask=null}},endGroup:function(e){var t;this.contentVisible&&(this.groupLevel--,t=this.ctx,this.ctx=this.groupStack.pop(),void 0!==this.ctx.imageSmoothingEnabled?this.ctx.imageSmoothingEnabled=!1:this.ctx.mozImageSmoothingEnabled=!1,e.smask?this.tempSMask=this.smaskStack.pop():this.ctx.drawImage(t.canvas,0,0),this.restore())},beginAnnotations:function(){this.save(),this.baseTransform&&this.ctx.setTransform.apply(this.ctx,this.baseTransform)},endAnnotations:function(){this.restore()},beginAnnotation:function(e,t,r){var n,i;this.save(),l(this.ctx),this.current=new c,Array.isArray(e)&&4===e.length&&(n=e[2]-e[0],i=e[3]-e[1],this.ctx.rect(e[0],e[1],n,i),this.clip(),this.endPath()),this.transform.apply(this,t),this.transform.apply(this,r)},endAnnotation:function(){this.restore()},paintImageMaskXObject:function(e){var t,n,i,a,o,s;this.contentVisible&&(s=this.ctx,t=e.width,n=e.height,i=this.current.fillColor,a=this.current.patternFill,(o=this.processingType3)&&void 0===o.compiled&&(o.compiled=t<=1e3&&n<=1e3?function(e){for(var t,r=e.width,n=e.height,i=r+1,a=new Uint8Array(i*(n+1)),o=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),s=r+7&-8,u=e.data,l=new Uint8Array(s*n),c=0,h=0,f=u.length;h<f;h++)for(var d=128,p=u[h];0<d;)l[c++]=p&d?0:255,d>>=1;var v=0;for(0!==l[c=0]&&(a[0]=1,++v),y=1;y<r;y++)l[c]!==l[c+1]&&(a[y]=l[c]?2:1,++v),c++;for(0!==l[c]&&(a[y]=2,++v),h=1;h<n;h++){t=h*i,l[(c=h*s)-s]!==l[c]&&(a[t]=l[c]?1:8,++v);for(var g=(l[c]?4:0)+(l[c-s]?8:0),y=1;y<r;y++)o[g=(g>>2)+(l[c+1]?4:0)+(l[c-s+1]?8:0)]&&(a[t+y]=o[g],++v),c++;if(l[c-s]!==l[c]&&(a[t+y]=l[c]?2:4,++v),1e3<v)return null}for(t=h*i,0!==l[c=s*(n-1)]&&(a[t]=8,++v),y=1;y<r;y++)l[c]!==l[c+1]&&(a[t+y]=l[c]?4:8,++v),c++;if(0!==l[c]&&(a[t+y]=4,++v),1e3<v)return null;var m=new Int32Array([0,i,-1,0,-i,0,0,0,1]),b=[];for(h=0;v&&h<=n;h++){for(var _=h*i,w=_+r;_<w&&!a[_];)_++;if(_!==w){var A,S=[_%i,h],k=a[_],x=_;do{for(var P=m[k];!a[_+=P];);}while(5!==(A=a[_])&&10!==A?(k=A,a[_]=0):a[_]&=(k=A&51*k>>4)>>2|k<<2,S.push(_%i),S.push(_/i|0),a[_]||--v,x!==_);b.push(S),--h}}return function(e){e.save(),e.scale(1/r,-1/n),e.translate(0,-n),e.beginPath();for(var t=0,i=b.length;t<i;t++){var a=b[t];e.moveTo(a[0],a[1]);for(var o=2,s=a.length;o<s;o+=2)e.lineTo(a[o],a[o+1])}e.fill(),e.beginPath(),e.restore()}}({data:e.data,width:t,height:n}):null),o&&o.compiled?o.compiled(s):((s=(o=this.cachedCanvases.getCanvas("maskCanvas",t,n)).context).save(),r(s,e),s.globalCompositeOperation="source-in",s.fillStyle=a?i.getPattern(s,this):i,s.fillRect(0,0,t,n),s.restore(),this.paintInlineImageXObject(o.canvas)))},paintImageMaskXObjectRepeat:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0,a=4<arguments.length?arguments[4]:void 0,o=5<arguments.length?arguments[5]:void 0;if(this.contentVisible){var s=e.width,u=e.height,l=this.current.fillColor,c=this.current.patternFill,h=this.cachedCanvases.getCanvas("maskCanvas",s,u),f=h.context;f.save(),r(f,e),f.globalCompositeOperation="source-in",f.fillStyle=c?l.getPattern(f,this):l,f.fillRect(0,0,s,u),f.restore();for(var d=this.ctx,p=0,v=o.length;p<v;p+=2)d.save(),d.transform(t,n,i,a,o[p],o[p+1]),d.scale(1,-1),d.drawImage(h.canvas,0,0,s,u,0,-1,1,1),d.restore()}},paintImageMaskXObjectGroup:function(e){if(this.contentVisible)for(var t=this.ctx,n=this.current.fillColor,i=this.current.patternFill,a=0,o=e.length;a<o;a++){var s=e[a],u=s.width,l=s.height,c=this.cachedCanvases.getCanvas("maskCanvas",u,l),h=c.context;h.save(),r(h,s),h.globalCompositeOperation="source-in",h.fillStyle=i?n.getPattern(h,this):n,h.fillRect(0,0,u,l),h.restore(),t.save(),t.transform.apply(t,s.transform),t.scale(1,-1),t.drawImage(c.canvas,0,0,u,l,0,-1,1,1),t.restore()}},paintImageXObject:function(e){this.contentVisible&&((e=(e.startsWith("g_")?this.commonObjs:this.objs).get(e))?this.paintInlineImageXObject(e):(0,n.warn)("Dependent image isn't ready yet"))},paintImageXObjectRepeat:function(e,t,r,i){if(this.contentVisible)if(e=(e.startsWith("g_")?this.commonObjs:this.objs).get(e),e){for(var a=e.width,o=e.height,s=[],u=0,l=i.length;u<l;u+=2)s.push({transform:[t,0,0,r,i[u],i[u+1]],x:0,y:0,w:a,h:o});this.paintInlineImageXObjectGroup(e,s)}else(0,n.warn)("Dependent image isn't ready yet")},paintInlineImageXObject:function(e){if(this.contentVisible){var r=e.width,n=e.height,i=this.ctx;this.save(),i.scale(1/r,-1/n);for(var a,o,s=i.mozCurrentTransformInverse,u=s[0],l=s[1],c=Math.max(Math.sqrt(u*u+l*l),1),h=(u=s[2],l=s[3],Math.max(Math.sqrt(u*u+l*l),1)),f="function"==typeof HTMLElement&&e instanceof HTMLElement||!e.data?e:(t(o=(a=this.cachedCanvases.getCanvas("inlineImage",r,n)).context,e,this.current.transferMaps),a.canvas),d=r,p=n,v="prescale1";2<c&&1<d||2<h&&1<p;){var g=d,y=p;2<c&&1<d&&(c/=d/(g=Math.ceil(d/2))),2<h&&1<p&&(h/=p/(y=Math.ceil(p/2))),(o=(a=this.cachedCanvases.getCanvas(v,g,y)).context).clearRect(0,0,g,y),o.drawImage(f,0,0,d,p,0,0,g,y),f=a.canvas,d=g,p=y,v="prescale1"===v?"prescale2":"prescale1"}i.drawImage(f,0,0,d,p,0,-n,r,n),this.imageLayer&&(i=this.getCanvasPosition(0,-n),this.imageLayer.appendImage({imgData:e,left:i[0],top:i[1],width:r/s[0],height:n/s[3]})),this.restore()}},paintInlineImageXObjectGroup:function(e,r){if(this.contentVisible){var n=this.ctx,i=e.width,a=e.height,o=this.cachedCanvases.getCanvas("inlineImage",i,a);t(o.context,e,this.current.transferMaps);for(var s=0,u=r.length;s<u;s++){var l=r[s];n.save(),n.transform.apply(n,l.transform),n.scale(1,-1),n.drawImage(o.canvas,l.x,l.y,l.w,l.h,0,-1,1,1),this.imageLayer&&(l=this.getCanvasPosition(l.x,l.y),this.imageLayer.appendImage({imgData:e,left:l[0],top:l[1],width:i,height:a})),n.restore()}}},paintSolidColorImageMask:function(){this.contentVisible&&this.ctx.fillRect(0,0,1,1)},markPoint:function(e){},markPointProps:function(e,t){},beginMarkedContent:function(e){this.markedContentStack.push({visible:!0})},beginMarkedContentProps:function(e,t){"OC"===e?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(t)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()},endMarkedContent:function(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()},beginCompat:function(){},endCompat:function(){},consumePath:function(){var e=this.ctx;this.pendingClip&&(this.pendingClip===b?e.clip("evenodd"):e.clip(),this.pendingClip=null),e.beginPath()},getSinglePixelWidth:function(e){var t;return null===this._cachedGetSinglePixelWidth&&(t=this.ctx.mozCurrentTransformInverse,this._cachedGetSinglePixelWidth=Math.sqrt(Math.max(t[0]*t[0]+t[1]*t[1],t[2]*t[2]+t[3]*t[3]))),this._cachedGetSinglePixelWidth},getCanvasPosition:function(e,t){var r=this.ctx.mozCurrentTransform;return[r[0]*e+r[2]*t+r[4],r[1]*e+r[3]*t+r[5]]},isContentVisible:function(){for(var e=this.markedContentStack.length-1;0<=e;e--)if(!this.markedContentStack[e].visible)return!1;return!0}},n.OPS)e.prototype[n.OPS[v]]=e.prototype[v];return e}(),t.CanvasGraphics=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getShadingPatternFromIR=function(e){var t=i[e[0]];if(t)return t.fromIR(e);throw new Error("Unknown IR type: ".concat(e[0]))},t.TilingPattern=void 0;var n=r(5),i={};function a(e,t){var r,n,i;t&&"undefined"!=typeof Path2D&&(r=t[2]-t[0],n=t[3]-t[1],(i=new Path2D).rect(t[0],t[1],r,n),e.clip(i))}i.RadialAxial={fromIR:function(e){var t=e[1],r=e[2],n=e[3],i=e[4],o=e[5],s=e[6],u=e[7];return{type:"Pattern",getPattern:function(e){var l;a(e,r),"axial"===t?l=e.createLinearGradient(i[0],i[1],o[0],o[1]):"radial"===t&&(l=e.createRadialGradient(i[0],i[1],s,o[0],o[1],u));for(var c=0,h=n.length;c<h;++c){var f=n[c];l.addColorStop(f[0],f[1])}return l}}}};var o=function(e,t,r,n,i,a,o,u){var l,c=Math.floor(e[0]),h=Math.floor(e[1]),f=Math.ceil(e[2])-c,d=Math.ceil(e[3])-h,p=(e=Math.min(Math.ceil(Math.abs(f*t[0]*1.1)),3e3),t=Math.min(Math.ceil(Math.abs(d*t[1]*1.1)),3e3),{coords:r,colors:n,offsetX:-c,offsetY:-h,scaleX:1/(f/=e),scaleY:1/(d/=t)});r=e+4,n=t+4;if(u.isEnabled)l=u.drawFigures({width:e,height:t,backgroundColor:a,figures:i,context:p}),(v=o.getCanvas("mesh",r,n,!1)).context.drawImage(l,2,2),l=v.canvas;else{n=(v=o.getCanvas("mesh",r,n,!1)).context;var v,g=n.createImageData(e,t);if(a)for(var y=g.data,m=0,b=y.length;m<b;m+=4)y[m]=a[0],y[m+1]=a[1],y[m+2]=a[2],y[m+3]=255;for(m=0;m<i.length;m++)!function(e,t,r){var n,i=t.coords,a=t.colors;switch(t.type){case"lattice":for(var o=t.verticesPerRow,u=Math.floor(i.length/o)-1,l=o-1,c=0;c<u;c++)for(var h=c*o,f=0;f<l;f++,h++)s(e,r,i[h],i[h+1],i[h+o],a[h],a[h+1],a[h+o]),s(e,r,i[h+o+1],i[h+1],i[h+o],a[h+o+1],a[h+1],a[h+o]);break;case"triangles":for(c=0,n=i.length;c<n;c+=3)s(e,r,i[c],i[c+1],i[c+2],a[c],a[c+1],a[c+2]);break;default:throw new Error("illegal figure")}}(g,i[m],p);n.putImageData(g,2,2),l=v.canvas}return{canvas:l,offsetX:c-2*f,offsetY:h-2*d,scaleX:f,scaleY:d}};function s(e,t,r,n,i,a,o,s){var u,l=t.coords,c=t.colors,h=e.data,f=4*e.width;l[r+1]>l[n+1]&&(u=r,r=n,n=u,u=a,a=o,o=u),l[n+1]>l[i+1]&&(u=n,n=i,i=u,u=o,o=s,s=u),l[r+1]>l[n+1]&&(u=r,r=n,n=u,u=a,a=o,o=u);var d=(l[r]+t.offsetX)*t.scaleX,p=(l[r+1]+t.offsetY)*t.scaleY,v=(l[n]+t.offsetX)*t.scaleX,g=(l[n+1]+t.offsetY)*t.scaleY,y=(l[i]+t.offsetX)*t.scaleX,m=(l[i+1]+t.offsetY)*t.scaleY;if(!(m<=p))for(var b,_,w,A,S,k=c[a],x=c[a+1],P=c[a+2],C=c[o],T=c[o+1],R=c[o+2],E=c[s],O=c[s+1],L=c[s+2],I=(s=Math.round(p),Math.round(m)),F=s;F<=I;F++){S=F<g?(b=void 0,_=d-(d-v)*(b=F<p?0:p==g?1:(p-F)/(p-g)),w=k-(k-C)*b,A=x-(x-T)*b,P-(P-R)*b):(q=void 0,_=v-(v-y)*(q=m<F?1:g==m?0:(g-F)/(g-m)),w=C-(C-E)*q,A=T-(T-O)*q,R-(R-L)*q);for(var M=void 0,N=d-(d-y)*(M=F<p?0:m<F?1:(p-F)/(p-m)),D=k-(k-E)*M,j=x-(x-O)*M,U=P-(P-L)*M,q=Math.round(Math.min(_,N)),B=Math.round(Math.max(_,N)),W=f*F+4*q,V=q;V<=B;V++)(M=(_-V)/(_-N))<0?M=0:1<M&&(M=1),h[W++]=w-(w-D)*M|0,h[W++]=A-(A-j)*M|0,h[W++]=S-(S-U)*M|0,h[W++]=255}}i.Mesh={fromIR:function(e){var t=e[2],r=e[3],i=e[4],s=e[5],u=e[6],l=e[7],c=e[8];return{type:"Pattern",getPattern:function(e,h,f){var d;a(e,l),f?p=n.Util.singularValueDecompose2dScale(e.mozCurrentTransform):(p=n.Util.singularValueDecompose2dScale(h.baseTransform),u&&(d=n.Util.singularValueDecompose2dScale(u),p=[p[0]*d[0],p[1]*d[1]]));var p=o(s,p,t,r,i,f?null:c,h.cachedCanvases,h.webGLContext);return f||(e.setTransform.apply(e,h.baseTransform),u&&e.transform.apply(e,u)),e.translate(p.offsetX,p.offsetY),e.scale(p.scaleX,p.scaleY),e.createPattern(p.canvas,"no-repeat")}}}},i.Dummy={fromIR:function(){return{type:"Pattern",getPattern:function(){return"hotpink"}}}},r=function(){var e=1,t=2;function r(e,t,r,n,i){this.operatorList=e[2],this.matrix=e[3]||[1,0,0,1,0,0],this.bbox=e[4],this.xstep=e[5],this.ystep=e[6],this.paintType=e[7],this.tilingType=e[8],this.color=t,this.canvasGraphicsFactory=n,this.baseTransform=i,this.type="Pattern",this.ctx=r}return r.prototype={createPatternCanvas:function(e){var t=this.operatorList,r=this.bbox,i=this.xstep,a=this.ystep,o=this.paintType,s=this.tilingType,u=this.color,l=this.canvasGraphicsFactory;(0,n.info)("TilingType: "+s);var c=r[0],h=r[1],f=r[2],d=r[3],p=n.Util.singularValueDecompose2dScale(this.matrix);s=n.Util.singularValueDecompose2dScale(this.baseTransform),p=[p[0]*s[0],p[1]*s[1]],s=this.getSizeAndScale(i,this.ctx.canvas.width,p[0]),i=this.getSizeAndScale(a,this.ctx.canvas.height,p[1]),a=e.cachedCanvases.getCanvas("pattern",s.size,i.size,!0),p=a.context,p=l.createCanvasGraphics(p);return p.groupLevel=e.groupLevel,this.setFillAndStrokeStyleToContext(p,o,u),p.transform(s.scale,0,0,i.scale,0,0),p.transform(1,0,0,1,-c,-h),this.clipBbox(p,r,c,h,f,d),p.executeOperatorList(t),this.ctx.transform(1,0,0,1,c,h),this.ctx.scale(1/s.scale,1/i.scale),a.canvas},getSizeAndScale:function(e,t,r){e=Math.abs(e);var n=Math.max(3e3,t);t=Math.ceil(e*r);return n<=t?t=n:r=t/e,{scale:r,size:t}},clipBbox:function(e,t,r,n,i,a){Array.isArray(t)&&4===t.length&&(e.ctx.rect(r,n,i-r,a-n),e.clip(),e.endPath())},setFillAndStrokeStyleToContext:function(r,i,a){var o=r.ctx,s=r.current;switch(i){case e:var u=this.ctx;o.fillStyle=u.fillStyle,o.strokeStyle=u.strokeStyle,s.fillColor=u.fillStyle,s.strokeColor=u.strokeStyle;break;case t:u=n.Util.makeCssRgb(a[0],a[1],a[2]),o.fillStyle=u,o.strokeStyle=u,s.fillColor=u,s.strokeColor=u;break;default:throw new n.FormatError("Unsupported paint type: ".concat(i))}},getPattern:function(e,t){return(e=this.ctx).setTransform.apply(e,this.baseTransform),e.transform.apply(e,this.matrix),t=this.createPatternCanvas(t),e.createPattern(t,"repeat")}},r}(),t.TilingPattern=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GlobalWorkerOptions=void 0;var n=Object.create(null);(t.GlobalWorkerOptions=n).workerPort=void 0===n.workerPort?null:n.workerPort,n.workerSrc=void 0===n.workerSrc?"":n.workerSrc},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessageHandler=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5);function o(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function s(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,n.key,n)}}function u(e){return(u="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)}var l={UNKNOWN:0,DATA:1,ERROR:2},c=1,h=2,f=3,d=4,p=5,v=6,g=7,y=8;function m(e){if("object"!==u(e)||null===e)return e;switch(e.name){case"AbortException":return new a.AbortException(e.message);case"MissingPDFException":return new a.MissingPDFException(e.message);case"UnexpectedResponseException":return new a.UnexpectedResponseException(e.message,e.status);case"UnknownErrorException":return new a.UnknownErrorException(e.message,e.details);default:return new a.UnknownErrorException(e.message,e.toString())}}t.MessageHandler=function(){function e(t,r,n){var i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.sourceName=t,this.targetName=r,this.comObj=n,this.callbackId=1,this.streamId=1,this.postMessageTransfers=!0,this.streamSinks=Object.create(null),this.streamControllers=Object.create(null),this.callbackCapabilities=Object.create(null),this.actionHandler=Object.create(null),this._onComObjOnMessage=function(e){var t=e.data;if(t.targetName===i.sourceName)if(t.stream)i._processStreamMessage(t);else if(t.callback){var r=t.callbackId;e=i.callbackCapabilities[r];if(!e)throw new Error("Cannot resolve callback ".concat(r));if(delete i.callbackCapabilities[r],t.callback===l.DATA)e.resolve(t.data);else{if(t.callback!==l.ERROR)throw new Error("Unexpected callback case");e.reject(m(t.reason))}}else{var a,o,s=i.actionHandler[t.action];if(!s)throw new Error("Unknown action from worker: ".concat(t.action));t.callbackId?(a=i.sourceName,o=t.sourceName,new Promise((function(e){e(s(t.data))})).then((function(e){n.postMessage({sourceName:a,targetName:o,callback:l.DATA,callbackId:t.callbackId,data:e})}),(function(e){n.postMessage({sourceName:a,targetName:o,callback:l.ERROR,callbackId:t.callbackId,reason:m(e)})}))):t.streamId?i._createStreamSink(t):s(t.data)}},n.addEventListener("message",this._onComObjOnMessage)}var t,r,n,u,b;return t=e,(r=[{key:"on",value:function(e,t){var r=this.actionHandler;if(r[e])throw new Error('There is already an actionName called "'.concat(e,'"'));r[e]=t}},{key:"send",value:function(e,t,r){this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,data:t},r)}},{key:"sendWithPromise",value:function(e,t,r){var n=this.callbackId++,i=(0,a.createPromiseCapability)();this.callbackCapabilities[n]=i;try{this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,callbackId:n,data:t},r)}catch(e){i.reject(e)}return i.promise}},{key:"sendWithStream",value:function(e,t,r,n){var i=this,o=this.streamId++,s=this.sourceName,u=this.targetName,l=this.comObj;return new ReadableStream({start:function(r){var l=(0,a.createPromiseCapability)();return i.streamControllers[o]={controller:r,startCall:l,pullCall:null,cancelCall:null,isClosed:!1},i._postMessage({sourceName:s,targetName:u,action:e,streamId:o,data:t,desiredSize:r.desiredSize},n),l.promise},pull:function(e){var t=(0,a.createPromiseCapability)();return i.streamControllers[o].pullCall=t,l.postMessage({sourceName:s,targetName:u,stream:v,streamId:o,desiredSize:e.desiredSize}),t.promise},cancel:function(e){(0,a.assert)(e instanceof Error,"cancel must have a valid reason");var t=(0,a.createPromiseCapability)();return i.streamControllers[o].cancelCall=t,i.streamControllers[o].isClosed=!0,l.postMessage({sourceName:s,targetName:u,stream:c,streamId:o,reason:m(e)}),t.promise}},r)}},{key:"_createStreamSink",value:function(e){var t=this,r=this.actionHandler[e.action],n=e.streamId,i=this.sourceName,o=e.sourceName,s=this.comObj,u={enqueue:function(e){var r,s=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,u=2<arguments.length?arguments[2]:void 0;this.isCancelled||(r=this.desiredSize,this.desiredSize-=s,0<r&&this.desiredSize<=0&&(this.sinkCapability=(0,a.createPromiseCapability)(),this.ready=this.sinkCapability.promise),t._postMessage({sourceName:i,targetName:o,stream:d,streamId:n,chunk:e},u))},close:function(){this.isCancelled||(this.isCancelled=!0,s.postMessage({sourceName:i,targetName:o,stream:f,streamId:n}),delete t.streamSinks[n])},error:function(e){(0,a.assert)(e instanceof Error,"error must have a valid reason"),this.isCancelled||(this.isCancelled=!0,s.postMessage({sourceName:i,targetName:o,stream:p,streamId:n,reason:m(e)}))},sinkCapability:(0,a.createPromiseCapability)(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:e.desiredSize,ready:null};u.sinkCapability.resolve(),u.ready=u.sinkCapability.promise,this.streamSinks[n]=u,new Promise((function(t){t(r(e.data,u))})).then((function(){s.postMessage({sourceName:i,targetName:o,stream:y,streamId:n,success:!0})}),(function(e){s.postMessage({sourceName:i,targetName:o,stream:y,streamId:n,reason:m(e)})}))}},{key:"_processStreamMessage",value:function(e){var t=e.streamId,r=this.sourceName,n=e.sourceName,i=this.comObj;switch(e.stream){case y:e.success?this.streamControllers[t].startCall.resolve():this.streamControllers[t].startCall.reject(m(e.reason));break;case g:e.success?this.streamControllers[t].pullCall.resolve():this.streamControllers[t].pullCall.reject(m(e.reason));break;case v:if(!this.streamSinks[t]){i.postMessage({sourceName:r,targetName:n,stream:g,streamId:t,success:!0});break}this.streamSinks[t].desiredSize<=0&&0<e.desiredSize&&this.streamSinks[t].sinkCapability.resolve(),this.streamSinks[t].desiredSize=e.desiredSize;var o=this.streamSinks[e.streamId].onPull;new Promise((function(e){e(o&&o())})).then((function(){i.postMessage({sourceName:r,targetName:n,stream:g,streamId:t,success:!0})}),(function(e){i.postMessage({sourceName:r,targetName:n,stream:g,streamId:t,reason:m(e)})}));break;case d:if((0,a.assert)(this.streamControllers[t],"enqueue should have stream controller"),this.streamControllers[t].isClosed)break;this.streamControllers[t].controller.enqueue(e.chunk);break;case f:if((0,a.assert)(this.streamControllers[t],"close should have stream controller"),this.streamControllers[t].isClosed)break;this.streamControllers[t].isClosed=!0,this.streamControllers[t].controller.close(),this._deleteStreamController(t);break;case p:(0,a.assert)(this.streamControllers[t],"error should have stream controller"),this.streamControllers[t].controller.error(m(e.reason)),this._deleteStreamController(t);break;case h:e.success?this.streamControllers[t].cancelCall.resolve():this.streamControllers[t].cancelCall.reject(m(e.reason)),this._deleteStreamController(t);break;case c:if(!this.streamSinks[t])break;var s=this.streamSinks[e.streamId].onCancel;new Promise((function(t){t(s&&s(m(e.reason)))})).then((function(){i.postMessage({sourceName:r,targetName:n,stream:h,streamId:t,success:!0})}),(function(e){i.postMessage({sourceName:r,targetName:n,stream:h,streamId:t,reason:m(e)})})),this.streamSinks[t].sinkCapability.reject(m(e.reason)),this.streamSinks[t].isCancelled=!0,delete this.streamSinks[t];break;default:throw new Error("Unexpected stream case")}}},{key:"_deleteStreamController",value:(u=i.default.mark((function e(t){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.allSettled([this.streamControllers[t].startCall,this.streamControllers[t].pullCall,this.streamControllers[t].cancelCall].map((function(e){return e&&e.promise})));case 2:delete this.streamControllers[t];case 3:case"end":return e.stop()}}),e,this)})),b=function(){var e=this,t=arguments;return new Promise((function(r,n){var i=u.apply(e,t);function a(e){o(i,r,n,a,s,"next",e)}function s(e){o(i,r,n,a,s,"throw",e)}a(void 0)}))},function(e){return b.apply(this,arguments)})},{key:"_postMessage",value:function(e,t){t&&this.postMessageTransfers?this.comObj.postMessage(e,t):this.comObj.postMessage(e)}},{key:"destroy",value:function(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}])&&s(t.prototype,r),n&&s(t,n),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Metadata=void 0;var n=r(5),i=r(212);function a(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,n.key,n)}}t.Metadata=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),(0,n.assert)("string"==typeof t,"Metadata: input is not a string"),t=this._repair(t),t=(new i.SimpleXMLParser).parseFromString(t),this._metadataMap=new Map,t&&this._parse(t)}var t,r,o;return t=e,(r=[{key:"_repair",value:function(e){return e.replace(/^[^<]+/,"").replace(/>\\376\\377([^<]+)/g,(function(e,t){for(var r=t.replace(/\\([0-3])([0-7])([0-7])/g,(function(e,t,r,n){return String.fromCharCode(64*t+8*r+ +n)})).replace(/&(amp|apos|gt|lt|quot);/g,(function(e,t){switch(t){case"amp":return"&";case"apos":return"'";case"gt":return">";case"lt":return"<";case"quot":return'"'}throw new Error("_repair: ".concat(t," isn't defined."))})),n="",i=0,a=r.length;i<a;i+=2){var o=256*r.charCodeAt(i)+r.charCodeAt(i+1);n+=32<=o&&o<127&&60!==o&&62!==o&&38!==o?String.fromCharCode(o):"&#x"+(65536+o).toString(16).substring(1)+";"}return">"+n}))}},{key:"_parse",value:function(e){var t=e.documentElement;if("rdf:rdf"!==t.nodeName.toLowerCase())for(t=t.firstChild;t&&"rdf:rdf"!==t.nodeName.toLowerCase();)t=t.nextSibling;if(e=t?t.nodeName.toLowerCase():null,t&&"rdf:rdf"===e&&t.hasChildNodes())for(var r=t.childNodes,n=0,i=r.length;n<i;n++){var a=r[n];if("rdf:description"===a.nodeName.toLowerCase())for(var o,s,u=0,l=a.childNodes.length;u<l;u++)"#text"!==a.childNodes[u].nodeName.toLowerCase()&&(s=(o=a.childNodes[u]).nodeName.toLowerCase(),this._metadataMap.set(s,o.textContent.trim()))}}},{key:"get",value:function(e){return this._metadataMap.has(e)?this._metadataMap.get(e):null}},{key:"getAll",value:function(){return Object.fromEntries(this._metadataMap)}},{key:"has",value:function(e){return this._metadataMap.has(e)}}])&&a(t.prototype,r),o&&a(t,o),e}()},function(e,t,r){"use strict";function n(e){return(n="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)}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}(e,t)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?a(e,t):void 0}}(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 a(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 o(e,t,r){return(o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,r){if(e=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=l(e)););return e}(e,t),e)return t=Object.getOwnPropertyDescriptor(e,t),t.get?t.get.call(r):t.value})(e,t,r||e)}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,i=l(t);return e=r?(e=l(this).constructor,Reflect.construct(i,arguments,e)):i.apply(this,arguments),i=this,!(e=e)||"object"!==n(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(i):e}}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(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,n.key,n)}}function f(e,t,r){return t&&h(e.prototype,t),r&&h(e,r),e}Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleXMLParser=void 0;var d={NoError:0,EndOfDocument:-1,UnterminatedCdat:-2,UnterminatedXmlDeclaration:-3,UnterminatedDoctypeDeclaration:-4,UnterminatedComment:-5,MalformedElement:-6,OutOfMemory:-7,UnterminatedAttributeValue:-8,UnterminatedElement:-9,ElementNeverBegun:-10};function p(e,t){return t=e[t]," "===t||"\n"===t||"\r"===t||"\t"===t}var v=function(){function e(){c(this,e)}return f(e,[{key:"_resolveEntities",value:function(e){var t=this;return e.replace(/&([^;]+);/g,(function(e,r){if("#x"===r.substring(0,2))return String.fromCharCode(parseInt(r.substring(2),16));if("#"===r.substring(0,1))return String.fromCharCode(parseInt(r.substring(1),10));switch(r){case"lt":return"<";case"gt":return">";case"amp":return"&";case"quot":return'"'}return t.onResolveEntity(r)}))}},{key:"_parseContent",value:function(e,t){var r=[],n=t;function i(){for(;n<e.length&&p(e,n);)++n}for(;n<e.length&&!p(e,n)&&">"!==e[n]&&"/"!==e[n];)++n;var a=e.substring(t,n);for(i();n<e.length&&">"!==e[n]&&"/"!==e[n]&&"?"!==e[n];){i();for(var o,s="";n<e.length&&!p(e,n)&&"="!==e[n];)s+=e[n],++n;if(i(),"="!==e[n])return null;++n,i();var u=e[n];if('"'!==u&&"'"!==u)return null;if(u=e.indexOf(u,++n),u<0)return null;o=e.substring(n,u),r.push({name:s,value:this._resolveEntities(o)}),n=u+1,i()}return{name:a,attributes:r,parsed:n-t}}},{key:"_parseProcessingInstruction",value:function(e,t){for(var r=t;r<e.length&&!p(e,r)&&">"!==e[r]&&"/"!==e[r];)++r;var n=e.substring(t,r);!function(){for(;r<e.length&&p(e,r);)++r}();for(var i=r;r<e.length&&("?"!==e[r]||">"!==e[r+1]);)++r;return{name:n,value:e.substring(i,r),parsed:r-t}}},{key:"parseXml",value:function(e){for(var t=0;t<e.length;){var r=t;if("<"===e[t]){var n=void 0;switch(e[++r]){case"/":if(++r,(n=e.indexOf(">",r))<0)return void this.onError(d.UnterminatedElement);this.onEndElement(e.substring(r,n)),r=n+1;break;case"?":++r;var i=this._parseProcessingInstruction(e,r);if("?>"!==e.substring(r+i.parsed,r+i.parsed+2))return void this.onError(d.UnterminatedXmlDeclaration);this.onPi(i.name,i.value),r+=i.parsed+2;break;case"!":if("--"===e.substring(r+1,r+3)){if((n=e.indexOf("--\x3e",r+3))<0)return void this.onError(d.UnterminatedComment);this.onComment(e.substring(r+3,n)),r=n+3}else if("[CDATA["===e.substring(r+1,r+8)){if((n=e.indexOf("]]>",r+8))<0)return void this.onError(d.UnterminatedCdat);this.onCdata(e.substring(r+8,n)),r=n+3}else{if("DOCTYPE"!==e.substring(r+1,r+8))return void this.onError(d.MalformedElement);var a=e.indexOf("[",r+8),o=!1;if((n=e.indexOf(">",r+8))<0)return void this.onError(d.UnterminatedDoctypeDeclaration);if(0<a&&a<n){if((n=e.indexOf("]>",r+8))<0)return void this.onError(d.UnterminatedDoctypeDeclaration);o=!0}a=e.substring(r+8,n+(o?1:0)),this.onDoctype(a),r=n+(o?2:1)}break;default:if(a=this._parseContent(e,r),null===a)return void this.onError(d.MalformedElement);if(o=!1,"/>"===e.substring(r+a.parsed,r+a.parsed+2))o=!0;else if(">"!==e.substring(r+a.parsed,r+a.parsed+1))return void this.onError(d.UnterminatedElement);this.onBeginElement(a.name,a.attributes,o),r+=a.parsed+(o?2:1)}}else{for(;r<e.length&&"<"!==e[r];)r++;var s=e.substring(t,r);this.onText(this._resolveEntities(s))}t=r}}},{key:"onResolveEntity",value:function(e){return"&".concat(e,";")}},{key:"onPi",value:function(e,t){}},{key:"onComment",value:function(e){}},{key:"onCdata",value:function(e){}},{key:"onDoctype",value:function(e){}},{key:"onText",value:function(e){}},{key:"onBeginElement",value:function(e,t,r){}},{key:"onEndElement",value:function(e){}},{key:"onError",value:function(e){}}]),e}(),g=function(){function e(t,r){c(this,e),this.nodeName=t,this.nodeValue=r,Object.defineProperty(this,"parentNode",{value:null,writable:!0})}return f(e,[{key:"hasChildNodes",value:function(){return this.childNodes&&0<this.childNodes.length}},{key:"firstChild",get:function(){return this.childNodes&&this.childNodes[0]}},{key:"nextSibling",get:function(){var e=this.parentNode.childNodes;if(e){var t=e.indexOf(this);if(-1!==t)return e[t+1]}}},{key:"textContent",get:function(){return this.childNodes?this.childNodes.map((function(e){return e.textContent})).join(""):this.nodeValue||""}}]),e}();t.SimpleXMLParser=function(){!function(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}}),t&&s(e,t)}(t,v);var e=u(t);function t(){var r;return c(this,t),(r=e.call(this))._currentFragment=null,r._stack=null,r._errorCode=d.NoError,r}return f(t,[{key:"parseFromString",value:function(e){if(this._currentFragment=[],this._stack=[],this._errorCode=d.NoError,this.parseXml(e),this._errorCode===d.NoError&&(e=i(this._currentFragment,1)[0],e))return{documentElement:e}}},{key:"onResolveEntity",value:function(e){return"apos"===e?"'":o(l(t.prototype),"onResolveEntity",this).call(this,e)}},{key:"onText",value:function(e){!function(e){for(var t=0,r=e.length;t<r;t++)if(!p(e,t))return;return 1}(e)&&(e=new g("#text",e),this._currentFragment.push(e))}},{key:"onCdata",value:function(e){e=new g("#text",e),this._currentFragment.push(e)}},{key:"onBeginElement",value:function(e,t,r){e=new g(e),e.childNodes=[],this._currentFragment.push(e),r||(this._stack.push(this._currentFragment),this._currentFragment=e.childNodes)}},{key:"onEndElement",value:function(e){this._currentFragment=this._stack.pop()||[];var t=this._currentFragment[this._currentFragment.length-1];if(t)for(var r=0,n=t.childNodes.length;r<n;r++)t.childNodes[r].parentNode=t}},{key:"onError",value:function(e){this._errorCode=e}}]),t}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OptionalContentConfig=void 0;var n=r(5);function i(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return a(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?a(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,o=!0,s=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return o=e.done,e},e:function(e){s=!0,i=e},f:function(){try{o||null==r.return||r.return()}finally{if(s)throw i}}}}function a(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 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,n.key,n)}}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var u=function e(t,r){s(this,e),this.visible=!0,this.name=t,this.intent=r};t.OptionalContentConfig=function(){function e(t){if(s(this,e),this.name=null,this.creator=null,this._order=null,this._groups=new Map,null!==t){this.name=t.name,this.creator=t.creator,this._order=t.order;var r,n=i(t.groups);try{for(n.s();!(r=n.n()).done;){var a=r.value;this._groups.set(a.id,new u(a.name,a.intent))}}catch(t){n.e(t)}finally{n.f()}if("OFF"===t.baseState){var o,l=i(this._groups);try{for(l.s();!(o=l.n()).done;)o.value.visible=!1}catch(t){l.e(t)}finally{l.f()}}var c,h=i(t.on);try{for(h.s();!(c=h.n()).done;){var f=c.value;this._groups.get(f).visible=!0}}catch(t){h.e(t)}finally{h.f()}var d,p=i(t.off);try{for(p.s();!(d=p.n()).done;){var v=d.value;this._groups.get(v).visible=!1}}catch(t){p.e(t)}finally{p.f()}}}var t,r,a;return t=e,(r=[{key:"isVisible",value:function(e){if("OCG"===e.type)return this._groups.has(e.id)?this._groups.get(e.id).visible:((0,n.warn)("Optional content group not found: ".concat(e.id)),!0);if("OCMD"!==e.type)return(0,n.warn)("Unknown group type ".concat(e.type,".")),!0;if(e.expression&&(0,n.warn)("Visibility expression not supported yet."),!e.policy||"AnyOn"===e.policy){var t,r=i(e.ids);try{for(r.s();!(t=r.n()).done;){var a=t.value;if(!this._groups.has(a))return(0,n.warn)("Optional content group not found: ".concat(a)),!0;if(this._groups.get(a).visible)return!0}}catch(e){r.e(e)}finally{r.f()}return!1}if("AllOn"===e.policy){var o,s=i(e.ids);try{for(s.s();!(o=s.n()).done;){var u=o.value;if(!this._groups.has(u))return(0,n.warn)("Optional content group not found: ".concat(u)),!0;if(!this._groups.get(u).visible)return!1}}catch(e){s.e(e)}finally{s.f()}return!0}if("AnyOff"===e.policy){var l,c=i(e.ids);try{for(c.s();!(l=c.n()).done;){var h=l.value;if(!this._groups.has(h))return(0,n.warn)("Optional content group not found: ".concat(h)),!0;if(!this._groups.get(h).visible)return!0}}catch(e){c.e(e)}finally{c.f()}return!1}if("AllOff"!==e.policy)return(0,n.warn)("Unknown optional content policy ".concat(e.policy,".")),!0;var f,d=i(e.ids);try{for(d.s();!(f=d.n()).done;){var p=f.value;if(!this._groups.has(p))return(0,n.warn)("Optional content group not found: ".concat(p)),!0;if(this._groups.get(p).visible)return!1}}catch(e){d.e(e)}finally{d.f()}return!0}},{key:"setVisibility",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];this._groups.has(e)?this._groups.get(e).visible=!!t:(0,n.warn)("Optional content group not found: ".concat(e))}},{key:"getOrder",value:function(){return this._groups.size?this._order?this._order.slice():Array.from(this._groups.keys()):null}},{key:"getGroups",value:function(){return this._groups.size?Object.fromEntries(this._groups):null}},{key:"getGroup",value:function(e){return this._groups.get(e)||null}}])&&o(t.prototype,r),a&&o(t,a),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFDataTransportStream=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5);function o(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function s(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function s(e){o(a,n,i,s,u,"next",e)}function u(e){o(a,n,i,s,u,"throw",e)}s(void 0)}))}}function u(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return l(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function l(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 c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(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,n.key,n)}}function f(e,t,r){return t&&h(e.prototype,t),r&&h(e,r),e}t.PDFDataTransportStream=function(){function e(t,r){var n=this;c(this,e),(0,a.assert)(r,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=t.progressiveDone||!1;var i=t.initialData;i&&0<i.length&&(i=new Uint8Array(i).buffer,this._queuedChunks.push(i)),this._pdfDataRangeTransport=r,this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._contentLength=t.length,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((function(e,t){n._onReceiveData({begin:e,chunk:t})})),this._pdfDataRangeTransport.addProgressListener((function(e,t){n._onProgress({loaded:e,total:t})})),this._pdfDataRangeTransport.addProgressiveReadListener((function(e){n._onReceiveData({chunk:e})})),this._pdfDataRangeTransport.addProgressiveDoneListener((function(){n._onProgressiveDone()})),this._pdfDataRangeTransport.transportReady()}return f(e,[{key:"_onReceiveData",value:function(e){var t,r=new Uint8Array(e.chunk).buffer;void 0===e.begin?this._fullRequestReader?this._fullRequestReader._enqueue(r):this._queuedChunks.push(r):(t=this._rangeReaders.some((function(t){return t._begin===e.begin&&(t._enqueue(r),!0)})),(0,a.assert)(t,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found."))}},{key:"_onProgress",value:function(e){var t;void 0===e.total?(t=this._rangeReaders[0])&&t.onProgress&&t.onProgress({loaded:e.loaded}):(t=this._fullRequestReader)&&t.onProgress&&t.onProgress({loaded:e.loaded,total:e.total})}},{key:"_onProgressiveDone",value:function(){this._fullRequestReader&&this._fullRequestReader.progressiveDone(),this._progressiveDone=!0}},{key:"_removeRangeReader",value:function(e){e=this._rangeReaders.indexOf(e),0<=e&&this._rangeReaders.splice(e,1)}},{key:"getFullReader",value:function(){(0,a.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");var e=this._queuedChunks;return this._queuedChunks=null,new d(this,e,this._progressiveDone)}},{key:"getRangeReader",value:function(e,t){if(t<=this._progressiveDataLength)return null;var r=new p(this,e,t);return this._pdfDataRangeTransport.requestDataRange(e,t),this._rangeReaders.push(r),r}},{key:"cancelAllRequests",value:function(e){this._fullRequestReader&&this._fullRequestReader.cancel(e),this._rangeReaders.slice(0).forEach((function(t){t.cancel(e)})),this._pdfDataRangeTransport.abort()}},{key:"_progressiveDataLength",get:function(){return this._fullRequestReader?this._fullRequestReader._loaded:0}}]),e}();var d=function(){function e(t,r){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2];c(this,e),this._stream=t,this._done=n||!1,this._filename=null,this._queuedChunks=r||[],this._loaded=0;var i,a=u(this._queuedChunks);try{for(a.s();!(i=a.n()).done;){var o=i.value;this._loaded+=o.byteLength}}catch(t){a.e(t)}finally{a.f()}this._requests=[],this._headersReady=Promise.resolve(),(t._fullRequestReader=this).onProgress=null}var t;return f(e,[{key:"_enqueue",value:function(e){this._done||(0<this._requests.length?this._requests.shift().resolve({value:e,done:!1}):this._queuedChunks.push(e),this._loaded+=e.byteLength)}},{key:"read",value:(t=s(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(0<this._queuedChunks.length)return t=this._queuedChunks.shift(),e.abrupt("return",{value:t,done:!1});e.next=3;break;case 3:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=5;break;case 5:return t=(0,a.createPromiseCapability)(),this._requests.push(t),e.abrupt("return",t.promise);case 8:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._done=!0,this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[]}},{key:"progressiveDone",value:function(){this._done||(this._done=!0)}},{key:"headersReady",get:function(){return this._headersReady}},{key:"filename",get:function(){return this._filename}},{key:"isRangeSupported",get:function(){return this._stream._isRangeSupported}},{key:"isStreamingSupported",get:function(){return this._stream._isStreamingSupported}},{key:"contentLength",get:function(){return this._stream._contentLength}}]),e}(),p=function(){function e(t,r,n){c(this,e),this._stream=t,this._begin=r,this._end=n,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}var t;return f(e,[{key:"_enqueue",value:function(e){this._done||(0===this._requests.length?this._queuedChunk=e:(this._requests.shift().resolve({value:e,done:!1}),this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[]),this._done=!0,this._stream._removeRangeReader(this))}},{key:"read",value:(t=s(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this._queuedChunk)return t=this._queuedChunk,this._queuedChunk=null,e.abrupt("return",{value:t,done:!1});e.next=4;break;case 4:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=6;break;case 6:return t=(0,a.createPromiseCapability)(),this._requests.push(t),e.abrupt("return",t.promise);case 9:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._done=!0,this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[],this._stream._removeRangeReader(this)}},{key:"isStreamingSupported",get:function(){return!1}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebGLContext=void 0;var n=r(5);function i(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,n.key,n)}}t.WebGLContext=function(){function e(t){t=t.enable,t=void 0!==t&&t,function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._enabled=!0===t}var t,r,a;return t=e,(r=[{key:"composeSMask",value:function(e){var t=e.layer,r=e.mask;e=e.properties;return d.composeSMask(t,r,e)}},{key:"drawFigures",value:function(e){var t=e.width,r=e.height,n=e.backgroundColor,i=e.figures;e=e.context;return d.drawFigures(t,r,n,i,e)}},{key:"clear",value:function(){d.cleanup()}},{key:"isEnabled",get:function(){var e=(e=this._enabled)&&d.tryInitGL();return(0,n.shadow)(this,"isEnabled",e)}}])&&i(t.prototype,r),a&&i(t,a),e}();var a,o,s,u,l,c,h,f,d=(s=" attribute vec2 a_position; attribute vec2 a_texCoord; uniform vec2 u_resolution; varying vec2 v_texCoord; void main() { vec2 clipSpace = (a_position / u_resolution) * 2.0 - 1.0; gl_Position = vec4(clipSpace * vec2(1, -1), 0, 1); v_texCoord = a_texCoord; } ",u=" precision mediump float; uniform vec4 u_backdrop; uniform int u_subtype; uniform sampler2D u_image; uniform sampler2D u_mask; varying vec2 v_texCoord; void main() { vec4 imageColor = texture2D(u_image, v_texCoord); vec4 maskColor = texture2D(u_mask, v_texCoord); if (u_backdrop.a > 0.0) { maskColor.rgb = maskColor.rgb * maskColor.a + u_backdrop.rgb * (1.0 - maskColor.a); } float lum; if (u_subtype == 0) { lum = maskColor.a; } else { lum = maskColor.r * 0.3 + maskColor.g * 0.59 + maskColor.b * 0.11; } imageColor.a *= lum; imageColor.rgb *= imageColor.a; gl_FragColor = imageColor; } ",c=" attribute vec2 a_position; attribute vec3 a_color; uniform vec2 u_resolution; uniform vec2 u_scale; uniform vec2 u_offset; varying vec4 v_color; void main() { vec2 position = (a_position + u_offset) * u_scale; vec2 clipSpace = (position / u_resolution) * 2.0 - 1.0; gl_Position = vec4(clipSpace * vec2(1, -1), 0, 1); v_color = vec4(a_color / 255.0, 1.0); } ",h=" precision mediump float; varying vec4 v_color; void main() { gl_FragColor = v_color; } ",f=l=null,{tryInitGL:function(){try{return b(),!!a}catch(e){}return!1},composeSMask:function(e,t,r){var n=e.width,i=e.height;l||function(){var e;b(),c=o,e=a,a=o=null;var t=y(e,[v(e,s),g(e,u)]);e.useProgram(t);var r={};r.gl=e,r.canvas=c,r.resolutionLocation=e.getUniformLocation(t,"u_resolution"),r.positionLocation=e.getAttribLocation(t,"a_position"),r.backdropLocation=e.getUniformLocation(t,"u_backdrop"),r.subtypeLocation=e.getUniformLocation(t,"u_subtype");var n=e.getAttribLocation(t,"a_texCoord"),i=e.getUniformLocation(t,"u_image"),c=e.getUniformLocation(t,"u_mask");t=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,t),e.bufferData(e.ARRAY_BUFFER,new Float32Array([0,0,1,0,0,1,0,1,1,0,1,1]),e.STATIC_DRAW),e.enableVertexAttribArray(n),e.vertexAttribPointer(n,2,e.FLOAT,!1,0,0),e.uniform1i(i,0),e.uniform1i(c,1),l=r}();var c=l,h=c.canvas,f=c.gl;return h.width=n,h.height=i,f.viewport(0,0,f.drawingBufferWidth,f.drawingBufferHeight),f.uniform2f(c.resolutionLocation,n,i),r.backdrop?f.uniform4f(c.resolutionLocation,r.backdrop[0],r.backdrop[1],r.backdrop[2],1):f.uniform4f(c.resolutionLocation,0,0,0,0),f.uniform1i(c.subtypeLocation,"Luminosity"===r.subtype?1:0),r=m(f,e,f.TEXTURE0),e=m(f,t,f.TEXTURE1),t=f.createBuffer(),f.bindBuffer(f.ARRAY_BUFFER,t),f.bufferData(f.ARRAY_BUFFER,new Float32Array([0,0,n,0,0,i,0,i,n,0,n,i]),f.STATIC_DRAW),f.enableVertexAttribArray(c.positionLocation),f.vertexAttribPointer(c.positionLocation,2,f.FLOAT,!1,0,0),f.clearColor(0,0,0,0),f.enable(f.BLEND),f.blendFunc(f.ONE,f.ONE_MINUS_SRC_ALPHA),f.clear(f.COLOR_BUFFER_BIT),f.drawArrays(f.TRIANGLES,0,6),f.flush(),f.deleteTexture(r),f.deleteTexture(e),f.deleteBuffer(t),h},drawFigures:function(e,t,r,n,i){f||function(){var e,t;b(),e=o,t=a,a=o=null;var r=y(t,[v(t,c),g(t,h)]);t.useProgram(r);var n={};n.gl=t,n.canvas=e,n.resolutionLocation=t.getUniformLocation(r,"u_resolution"),n.scaleLocation=t.getUniformLocation(r,"u_scale"),n.offsetLocation=t.getUniformLocation(r,"u_offset"),n.positionLocation=t.getAttribLocation(r,"a_position"),n.colorLocation=t.getAttribLocation(r,"a_color"),f=n}();var s=f,u=s.canvas,l=s.gl;u.width=e,u.height=t,l.viewport(0,0,l.drawingBufferWidth,l.drawingBufferHeight),l.uniform2f(s.resolutionLocation,e,t);for(var d=0,p=0,m=n.length;p<m;p++)switch(n[p].type){case"lattice":d+=((E=n[p].coords.length/n[p].verticesPerRow|0)-1)*(n[p].verticesPerRow-1)*6;break;case"triangles":d+=n[p].coords.length}var _=new Float32Array(2*d),w=new Uint8Array(3*d),A=i.coords,S=i.colors,k=0,x=0;for(p=0,m=n.length;p<m;p++){var P=n[p],C=P.coords,T=P.colors;switch(P.type){case"lattice":for(var R=P.verticesPerRow,E=C.length/R|0,O=1;O<E;O++)for(var L=O*R+1,I=1;I<R;I++,L++)_[k]=A[C[L-R-1]],_[k+1]=A[C[L-R-1]+1],_[k+2]=A[C[L-R]],_[k+3]=A[C[L-R]+1],_[k+4]=A[C[L-1]],_[k+5]=A[C[L-1]+1],w[x]=S[T[L-R-1]],w[x+1]=S[T[L-R-1]+1],w[x+2]=S[T[L-R-1]+2],w[x+3]=S[T[L-R]],w[x+4]=S[T[L-R]+1],w[x+5]=S[T[L-R]+2],w[x+6]=S[T[L-1]],w[x+7]=S[T[L-1]+1],w[x+8]=S[T[L-1]+2],_[k+6]=_[k+2],_[k+7]=_[k+3],_[k+8]=_[k+4],_[k+9]=_[k+5],_[k+10]=A[C[L]],_[k+11]=A[C[L]+1],w[x+9]=w[x+3],w[x+10]=w[x+4],w[x+11]=w[x+5],w[x+12]=w[x+6],w[x+13]=w[x+7],w[x+14]=w[x+8],w[x+15]=S[T[L]],w[x+16]=S[T[L]+1],w[x+17]=S[T[L]+2],k+=12,x+=18;break;case"triangles":for(var F=0,M=C.length;F<M;F++)_[k]=A[C[F]],_[k+1]=A[C[F]+1],w[x]=S[T[F]],w[x+1]=S[T[F]+1],w[x+2]=S[T[F]+2],k+=2,x+=3}}return r?l.clearColor(r[0]/255,r[1]/255,r[2]/255,1):l.clearColor(0,0,0,0),l.clear(l.COLOR_BUFFER_BIT),t=l.createBuffer(),l.bindBuffer(l.ARRAY_BUFFER,t),l.bufferData(l.ARRAY_BUFFER,_,l.STATIC_DRAW),l.enableVertexAttribArray(s.positionLocation),l.vertexAttribPointer(s.positionLocation,2,l.FLOAT,!1,0,0),r=l.createBuffer(),l.bindBuffer(l.ARRAY_BUFFER,r),l.bufferData(l.ARRAY_BUFFER,w,l.STATIC_DRAW),l.enableVertexAttribArray(s.colorLocation),l.vertexAttribPointer(s.colorLocation,3,l.UNSIGNED_BYTE,!1,0,0),l.uniform2f(s.scaleLocation,i.scaleX,i.scaleY),l.uniform2f(s.offsetLocation,i.offsetX,i.offsetY),l.drawArrays(l.TRIANGLES,0,d),l.flush(),l.deleteBuffer(t),l.deleteBuffer(r),u},cleanup:function(){l&&l.canvas&&(l.canvas.width=0,l.canvas.height=0),f&&f.canvas&&(f.canvas.width=0,f.canvas.height=0),f=l=null}});function p(e,t,r){if(r=e.createShader(r),e.shaderSource(r,t),e.compileShader(r),e.getShaderParameter(r,e.COMPILE_STATUS))return r;throw r=e.getShaderInfoLog(r),new Error("Error during shader compilation: "+r)}function v(e,t){return p(e,t,e.VERTEX_SHADER)}function g(e,t){return p(e,t,e.FRAGMENT_SHADER)}function y(e,t){for(var r=e.createProgram(),n=0,i=t.length;n<i;++n)e.attachShader(r,t[n]);if(e.linkProgram(r),e.getProgramParameter(r,e.LINK_STATUS))return r;var a=e.getProgramInfoLog(r);throw new Error("Error during program linking: "+a)}function m(e,t,r){return e.activeTexture(r),r=e.createTexture(),e.bindTexture(e.TEXTURE_2D,r),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.NEAREST),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.NEAREST),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),r}function b(){a||(o=document.createElement("canvas"),a=o.getContext("webgl",{premultipliedalpha:!1}))}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnnotationLayer=void 0;var n=r(1),i=r(5),a=r(205);function o(e,t,r){return(o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,r){if(e=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=p(e)););return e}(e,t),e)return t=Object.getOwnPropertyDescriptor(e,t),t.get?t.get.call(r):t.value})(e,t,r||e)}function s(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return u(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function u(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 l(e){return(l="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)}function c(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}}),t&&h(e,t)}function h(e,t){return(h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=p(t);return e=r?(e=p(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==l(e)&&"function"!=typeof e?d(n):e}}function d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function p(e){return(p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(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,n.key,n)}}function y(e,t,r){return t&&g(e.prototype,t),r&&g(e,r),e}var m=function(){function e(){v(this,e)}return y(e,null,[{key:"create",value:function(e){switch(e.data.annotationType){case i.AnnotationType.LINK:return new _(e);case i.AnnotationType.TEXT:return new w(e);case i.AnnotationType.WIDGET:switch(e.data.fieldType){case"Tx":return new S(e);case"Btn":return e.data.radioButton?new x(e):new(e.data.checkBox?k:P)(e);case"Ch":return new C(e)}return new A(e);case i.AnnotationType.POPUP:return new T(e);case i.AnnotationType.FREETEXT:return new E(e);case i.AnnotationType.LINE:return new O(e);case i.AnnotationType.SQUARE:return new L(e);case i.AnnotationType.CIRCLE:return new I(e);case i.AnnotationType.POLYLINE:return new F(e);case i.AnnotationType.CARET:return new N(e);case i.AnnotationType.INK:return new D(e);case i.AnnotationType.POLYGON:return new M(e);case i.AnnotationType.HIGHLIGHT:return new j(e);case i.AnnotationType.UNDERLINE:return new U(e);case i.AnnotationType.SQUIGGLY:return new q(e);case i.AnnotationType.STRIKEOUT:return new B(e);case i.AnnotationType.STAMP:return new W(e);case i.AnnotationType.FILEATTACHMENT:return new V(e);default:return new b(e)}}}]),e}(),b=function(){function e(t){var r=1<arguments.length&&void 0!==arguments[1]&&arguments[1],n=2<arguments.length&&void 0!==arguments[2]&&arguments[2];v(this,e),this.isRenderable=r,this.data=t.data,this.layer=t.layer,this.page=t.page,this.viewport=t.viewport,this.linkService=t.linkService,this.downloadManager=t.downloadManager,this.imageResourcesPath=t.imageResourcesPath,this.renderInteractiveForms=t.renderInteractiveForms,this.svgFactory=t.svgFactory,this.annotationStorage=t.annotationStorage,r&&(this.container=this._createContainer(n))}return y(e,[{key:"_createContainer",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=this.data,r=this.page,n=this.viewport,a=document.createElement("section"),o=t.rect[2]-t.rect[0],s=t.rect[3]-t.rect[1];if(a.setAttribute("data-annotation-id",t.id),r=i.Util.normalizeRect([t.rect[0],r.view[3]-t.rect[1]+r.view[1],t.rect[2],r.view[3]-t.rect[3]+r.view[1]]),a.style.transform="matrix(".concat(n.transform.join(","),")"),a.style.transformOrigin="-".concat(r[0],"px -").concat(r[1],"px"),!e&&0<t.borderStyle.width){switch(a.style.borderWidth="".concat(t.borderStyle.width,"px"),t.borderStyle.style!==i.AnnotationBorderStyleType.UNDERLINE&&(o-=2*t.borderStyle.width,s-=2*t.borderStyle.width),n=t.borderStyle.horizontalCornerRadius,e=t.borderStyle.verticalCornerRadius,(0<n||0<e)&&(e="".concat(n,"px / ").concat(e,"px"),a.style.borderRadius=e),t.borderStyle.style){case i.AnnotationBorderStyleType.SOLID:a.style.borderStyle="solid";break;case i.AnnotationBorderStyleType.DASHED:a.style.borderStyle="dashed";break;case i.AnnotationBorderStyleType.BEVELED:(0,i.warn)("Unimplemented border style: beveled");break;case i.AnnotationBorderStyleType.INSET:(0,i.warn)("Unimplemented border style: inset");break;case i.AnnotationBorderStyleType.UNDERLINE:a.style.borderBottomStyle="solid"}t.color?a.style.borderColor=i.Util.makeCssRgb(0|t.color[0],0|t.color[1],0|t.color[2]):a.style.borderWidth=0}return a.style.left="".concat(r[0],"px"),a.style.top="".concat(r[1],"px"),a.style.width="".concat(o,"px"),a.style.height="".concat(s,"px"),a}},{key:"_createPopup",value:function(e,t,r){t||((t=document.createElement("div")).style.height=e.style.height,t.style.width=e.style.width,e.appendChild(t)),r=new R({container:e,trigger:t,color:r.color,title:r.title,modificationDate:r.modificationDate,contents:r.contents,hideWrapper:!0}).render(),r.style.left=e.style.width,e.appendChild(r)}},{key:"render",value:function(){(0,i.unreachable)("Abstract method `AnnotationElement.render` called")}}]),e}(),_=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.url||r.data.dest||r.data.action);return e.call(this,r,n)}return y(t,[{key:"render",value:function(){this.container.className="linkAnnotation";var e=this.data,t=this.linkService,r=document.createElement("a");return e.url?(0,n.addLinkAttributes)(r,{url:e.url,target:e.newWindow?n.LinkTarget.BLANK:t.externalLinkTarget,rel:t.externalLinkRel,enabled:t.externalLinkEnabled}):e.action?this._bindNamedAction(r,e.action):this._bindLink(r,e.dest),this.container.appendChild(r),this.container}},{key:"_bindLink",value:function(e,t){var r=this;e.href=this.linkService.getDestinationHash(t),e.onclick=function(){return t&&r.linkService.navigateTo(t),!1},t&&(e.className="internalLink")}},{key:"_bindNamedAction",value:function(e,t){var r=this;e.href=this.linkService.getAnchorUrl(""),e.onclick=function(){return r.linkService.executeNamedAction(t),!1},e.className="internalLink"}}]),t}(),w=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n)}return y(t,[{key:"render",value:function(){this.container.className="textAnnotation";var e=document.createElement("img");return e.style.height=this.container.style.height,e.style.width=this.container.style.width,e.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",e.alt="[{{type}} Annotation]",e.dataset.l10nId="text_annotation_type",e.dataset.l10nArgs=JSON.stringify({type:this.data.name}),this.data.hasPopup||this._createPopup(this.container,e,this.data),this.container.appendChild(e),this.container}}]),t}(),A=function(){c(t,b);var e=f(t);function t(){return v(this,t),e.apply(this,arguments)}return y(t,[{key:"render",value:function(){return this.container}}]),t}(),S=function(){c(t,A);var e=f(t);function t(r){v(this,t);var n=r.renderInteractiveForms||!r.data.hasAppearance&&!!r.data.fieldValue;return e.call(this,r,n)}return y(t,[{key:"render",value:function(){var e=this.annotationStorage,t=this.data.id;this.container.className="textWidgetAnnotation";var r,n,i=null;return this.renderInteractiveForms?(r=e.getOrCreateValue(t,this.data.fieldValue),this.data.multiLine?(i=document.createElement("textarea")).textContent=r:((i=document.createElement("input")).type="text",i.setAttribute("value",r)),i.addEventListener("input",(function(r){e.setValue(t,r.target.value)})),i.disabled=this.data.readOnly,i.name=this.data.fieldName,null!==this.data.maxLen&&(i.maxLength=this.data.maxLen),this.data.comb&&(n=(this.data.rect[2]-this.data.rect[0])/this.data.maxLen,i.classList.add("comb"),i.style.letterSpacing="calc(".concat(n,"px - 1ch)"))):((i=document.createElement("div")).textContent=this.data.fieldValue,i.style.verticalAlign="middle",i.style.display="table-cell",n=null,this.data.fontRefName&&this.page.commonObjs.has(this.data.fontRefName)&&(n=this.page.commonObjs.get(this.data.fontRefName)),this._setTextStyle(i,n)),null!==this.data.textAlignment&&(i.style.textAlign=["left","center","right"][this.data.textAlignment]),this.container.appendChild(i),this.container}},{key:"_setTextStyle",value:function(e,t){var r=e.style;r.fontSize="".concat(this.data.fontSize,"px"),r.direction=this.data.fontDirection<0?"rtl":"ltr",t&&(e="normal",t.black?e="900":t.bold&&(e="bold"),r.fontWeight=e,r.fontStyle=t.italic?"italic":"normal",e=t.loadedName?'"'.concat(t.loadedName,'", '):"",t=t.fallbackName||"Helvetica, sans-serif",r.fontFamily=e+t)}}]),t}(),k=function(){c(t,A);var e=f(t);function t(r){return v(this,t),e.call(this,r,r.renderInteractiveForms)}return y(t,[{key:"render",value:function(){var e=this.annotationStorage,t=this.data,r=t.id,n=e.getOrCreateValue(r,t.fieldValue&&"Off"!==t.fieldValue);this.container.className="buttonWidgetAnnotation checkBox";var i=document.createElement("input");return i.disabled=t.readOnly,i.type="checkbox",i.name=this.data.fieldName,n&&i.setAttribute("checked",!0),i.addEventListener("change",(function(t){e.setValue(r,t.target.checked)})),this.container.appendChild(i),this.container}}]),t}(),x=function(){c(t,A);var e=f(t);function t(r){return v(this,t),e.call(this,r,r.renderInteractiveForms)}return y(t,[{key:"render",value:function(){this.container.className="buttonWidgetAnnotation radioButton";var e=this.annotationStorage,t=this.data,r=t.id,n=e.getOrCreateValue(r,t.fieldValue===t.buttonValue),i=document.createElement("input");return i.disabled=t.readOnly,i.type="radio",i.name=t.fieldName,n&&i.setAttribute("checked",!0),i.addEventListener("change",(function(t){var n,i=t.target.name,a=s(document.getElementsByName(i));try{for(a.s();!(n=a.n()).done;){var o=n.value;o!==t.target&&e.setValue(o.parentNode.getAttribute("data-annotation-id"),!1)}}catch(t){a.e(t)}finally{a.f()}e.setValue(r,t.target.checked)})),this.container.appendChild(i),this.container}}]),t}(),P=function(){c(t,_);var e=f(t);function t(){return v(this,t),e.apply(this,arguments)}return y(t,[{key:"render",value:function(){var e=o(p(t.prototype),"render",this).call(this);return e.className="buttonWidgetAnnotation pushButton",e}}]),t}(),C=function(){c(t,A);var e=f(t);function t(r){return v(this,t),e.call(this,r,r.renderInteractiveForms)}return y(t,[{key:"render",value:function(){this.container.className="choiceWidgetAnnotation";var e=this.annotationStorage,t=this.data.id;e.getOrCreateValue(t,0<this.data.fieldValue.length?this.data.fieldValue[0]:null);var r=document.createElement("select");r.disabled=this.data.readOnly,r.name=this.data.fieldName,this.data.combo||(r.size=this.data.options.length,this.data.multiSelect&&(r.multiple=!0));var n,i=s(this.data.options);try{for(i.s();!(n=i.n()).done;){var a=n.value,o=document.createElement("option");o.textContent=a.displayValue,o.value=a.exportValue,this.data.fieldValue.includes(a.exportValue)&&o.setAttribute("selected",!0),r.appendChild(o)}}catch(r){i.e(r)}finally{i.f()}return r.addEventListener("input",(function(r){r=r.target.options,r=r[r.selectedIndex].value,e.setValue(t,r)})),this.container.appendChild(r),this.container}}]),t}(),T=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!(!r.data.title&&!r.data.contents);return e.call(this,r,n)}return y(t,[{key:"render",value:function(){if(this.container.className="popupAnnotation",["Line","Square","Circle","PolyLine","Polygon","Ink"].includes(this.data.parentType))return this.container;var e='[data-annotation-id="'.concat(this.data.parentId,'"]'),t=this.layer.querySelector(e);if(!t)return this.container;var r=new R({container:this.container,trigger:t,color:this.data.color,title:this.data.title,modificationDate:this.data.modificationDate,contents:this.data.contents}),n=parseFloat(t.style.left);e=parseFloat(t.style.width);return this.container.style.transformOrigin="-".concat(n+e,"px -").concat(t.style.top),this.container.style.left="".concat(n+e,"px"),this.container.appendChild(r.render()),this.container}}]),t}(),R=function(){function e(t){v(this,e),this.container=t.container,this.trigger=t.trigger,this.color=t.color,this.title=t.title,this.modificationDate=t.modificationDate,this.contents=t.contents,this.hideWrapper=t.hideWrapper||!1,this.pinned=!1}return y(e,[{key:"render",value:function(){var e=document.createElement("div");e.className="popupWrapper",this.hideElement=this.hideWrapper?e:this.container,this.hideElement.setAttribute("hidden",!0);var t=document.createElement("div");t.className="popup";var r,a,o=this.color;o&&(r=.7*(255-o[0])+o[0],a=.7*(255-o[1])+o[1],s=.7*(255-o[2])+o[2],t.style.backgroundColor=i.Util.makeCssRgb(0|r,0|a,0|s));var s=document.createElement("h1");s.textContent=this.title,t.appendChild(s),s=n.PDFDateString.toDateObject(this.modificationDate),s&&((u=document.createElement("span")).textContent="{{date}}, {{time}}",u.dataset.l10nId="annotation_date_string",u.dataset.l10nArgs=JSON.stringify({date:s.toLocaleDateString(),time:s.toLocaleTimeString()}),t.appendChild(u));var u=this._formatContents(this.contents);return t.appendChild(u),this.trigger.addEventListener("click",this._toggle.bind(this)),this.trigger.addEventListener("mouseover",this._show.bind(this,!1)),this.trigger.addEventListener("mouseout",this._hide.bind(this,!1)),t.addEventListener("click",this._hide.bind(this,!0)),e.appendChild(t),e}},{key:"_formatContents",value:function(e){for(var t=document.createElement("p"),r=e.split(/(?:\r\n?|\n)/),n=0,i=r.length;n<i;++n){var a=r[n];t.appendChild(document.createTextNode(a)),n<i-1&&t.appendChild(document.createElement("br"))}return t}},{key:"_toggle",value:function(){this.pinned?this._hide(!0):this._show(!0)}},{key:"_show",value:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0]&&(this.pinned=!0),this.hideElement.hasAttribute("hidden")&&(this.hideElement.removeAttribute("hidden"),this.container.style.zIndex+=1)}},{key:"_hide",value:function(){0<arguments.length&&void 0!==arguments[0]&&!arguments[0]||(this.pinned=!1),this.hideElement.hasAttribute("hidden")||this.pinned||(this.hideElement.setAttribute("hidden",!0),--this.container.style.zIndex)}}]),e}(),E=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="freeTextAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),O=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){this.container.className="lineAnnotation";var e=this.data,t=e.rect[2]-e.rect[0],r=e.rect[3]-e.rect[1];t=this.svgFactory.create(t,r),r=this.svgFactory.createElement("svg:line");return r.setAttribute("x1",e.rect[2]-e.lineCoordinates[0]),r.setAttribute("y1",e.rect[3]-e.lineCoordinates[1]),r.setAttribute("x2",e.rect[2]-e.lineCoordinates[2]),r.setAttribute("y2",e.rect[3]-e.lineCoordinates[3]),r.setAttribute("stroke-width",e.borderStyle.width||1),r.setAttribute("stroke","transparent"),t.appendChild(r),this.container.append(t),this._createPopup(this.container,r,e),this.container}}]),t}(),L=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){this.container.className="squareAnnotation";var e=this.data,t=e.rect[2]-e.rect[0],r=e.rect[3]-e.rect[1],n=this.svgFactory.create(t,r),i=e.borderStyle.width,a=this.svgFactory.createElement("svg:rect");return a.setAttribute("x",i/2),a.setAttribute("y",i/2),a.setAttribute("width",t-i),a.setAttribute("height",r-i),a.setAttribute("stroke-width",i||1),a.setAttribute("stroke","transparent"),a.setAttribute("fill","none"),n.appendChild(a),this.container.append(n),this._createPopup(this.container,a,e),this.container}}]),t}(),I=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){this.container.className="circleAnnotation";var e=this.data,t=e.rect[2]-e.rect[0],r=e.rect[3]-e.rect[1],n=this.svgFactory.create(t,r),i=e.borderStyle.width,a=this.svgFactory.createElement("svg:ellipse");return a.setAttribute("cx",t/2),a.setAttribute("cy",r/2),a.setAttribute("rx",t/2-i/2),a.setAttribute("ry",r/2-i/2),a.setAttribute("stroke-width",i||1),a.setAttribute("stroke","transparent"),a.setAttribute("fill","none"),n.appendChild(a),this.container.append(n),this._createPopup(this.container,a,e),this.container}}]),t}(),F=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return(n=e.call(this,r,n,!0)).containerClassName="polylineAnnotation",n.svgElementName="svg:polyline",n}return y(t,[{key:"render",value:function(){this.container.className=this.containerClassName;var e,t=this.data,r=t.rect[2]-t.rect[0],n=t.rect[3]-t.rect[1],i=(r=this.svgFactory.create(r,n),[]),a=s(t.vertices);try{for(a.s();!(e=a.n()).done;){var o=e.value,u=o.x-t.rect[0],l=t.rect[3]-o.y;i.push(u+","+l)}}catch(e){a.e(e)}finally{a.f()}return i=i.join(" "),n=this.svgFactory.createElement(this.svgElementName),n.setAttribute("points",i),n.setAttribute("stroke-width",t.borderStyle.width||1),n.setAttribute("stroke","transparent"),n.setAttribute("fill","none"),r.appendChild(n),this.container.append(r),this._createPopup(this.container,n,t),this.container}}]),t}(),M=function(){c(t,F);var e=f(t);function t(r){return v(this,t),(r=e.call(this,r)).containerClassName="polygonAnnotation",r.svgElementName="svg:polygon",r}return t}(),N=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="caretAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),D=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return(n=e.call(this,r,n,!0)).containerClassName="inkAnnotation",n.svgElementName="svg:polyline",n}return y(t,[{key:"render",value:function(){this.container.className=this.containerClassName;var e,t=this.data,r=t.rect[2]-t.rect[0],n=t.rect[3]-t.rect[1],i=this.svgFactory.create(r,n),a=s(t.inkLists);try{for(a.s();!(e=a.n()).done;){var o,u=e.value,l=[],c=s(u);try{for(c.s();!(o=c.n()).done;){var h=o.value,f=h.x-t.rect[0],d=t.rect[3]-h.y;l.push("".concat(f,",").concat(d))}}catch(e){c.e(e)}finally{c.f()}l=l.join(" ");var p=this.svgFactory.createElement(this.svgElementName);p.setAttribute("points",l),p.setAttribute("stroke-width",t.borderStyle.width||1),p.setAttribute("stroke","transparent"),p.setAttribute("fill","none"),this._createPopup(this.container,p,t),i.appendChild(p)}}catch(e){a.e(e)}finally{a.f()}return this.container.append(i),this.container}}]),t}(),j=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="highlightAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),U=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="underlineAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),q=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="squigglyAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),B=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="strikeoutAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),W=function(){c(t,b);var e=f(t);function t(r){v(this,t);var n=!!(r.data.hasPopup||r.data.title||r.data.contents);return e.call(this,r,n,!0)}return y(t,[{key:"render",value:function(){return this.container.className="stampAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),t}(),V=function(){c(t,b);var e=f(t);function t(r){v(this,t);var a,o=(a=e.call(this,r,!0)).data.file;r=o.filename,o=o.content;return a.filename=(0,n.getFilenameFromUrl)(r),a.content=o,a.linkService.eventBus&&a.linkService.eventBus.dispatch("fileattachmentannotation",{source:d(a),id:(0,i.stringToPDFString)(r),filename:r,content:o}),a}return y(t,[{key:"render",value:function(){this.container.className="fileAttachmentAnnotation";var e=document.createElement("div");return e.style.height=this.container.style.height,e.style.width=this.container.style.width,e.addEventListener("dblclick",this._download.bind(this)),this.data.hasPopup||!this.data.title&&!this.data.contents||this._createPopup(this.container,e,this.data),this.container.appendChild(e),this.container}},{key:"_download",value:function(){this.downloadManager?this.downloadManager.downloadData(this.content,this.filename,""):(0,i.warn)("Download cannot be started due to unavailable download manager")}}]),t}();t.AnnotationLayer=function(){function e(){v(this,e)}return y(e,null,[{key:"render",value:function(e){var t,r=[],o=[],u=s(e.annotations);try{for(u.s();!(t=u.n()).done;){var l=t.value;l&&(l.annotationType!==i.AnnotationType.POPUP?r:o).push(l)}}catch(e){u.e(e)}finally{u.f()}o.length&&r.push.apply(r,o);for(var c=0,h=r;c<h.length;c++){var f=h[c];f=m.create({data:f,layer:e.div,page:e.page,viewport:e.viewport,linkService:e.linkService,downloadManager:e.downloadManager,imageResourcesPath:e.imageResourcesPath||"",renderInteractiveForms:"boolean"!=typeof e.renderInteractiveForms||e.renderInteractiveForms,svgFactory:new n.DOMSVGFactory,annotationStorage:e.annotationStorage||new a.AnnotationStorage});f.isRenderable&&e.div.appendChild(f.render())}}},{key:"update",value:function(e){var t,r=s(e.annotations);try{for(r.s();!(t=r.n()).done;){var n=t.value,i=e.div.querySelector('[data-annotation-id="'.concat(n.id,'"]'));i&&(i.style.transform="matrix(".concat(e.viewport.transform.join(","),")"))}}catch(e){r.e(e)}finally{r.f()}e.div.removeAttribute("hidden")}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.renderTextLayer=void 0;var n,i=r(5);n=/\S/,c.prototype={get promise(){return this._capability.promise},cancel:function(){this._canceled=!0,this._reader&&(this._reader.cancel(new i.AbortException("TextLayer task cancelled.")),this._reader=null),null!==this._renderTimer&&(clearTimeout(this._renderTimer),this._renderTimer=null),this._capability.reject(new Error("TextLayer task cancelled."))},_processItems:function(e,t){for(var r=0,n=e.length;r<n;r++)this._textContentItemsStr.push(e[r].str),a(this,e[r],t)},_layoutText:function(e){var t,r,n,i=this._textDivProperties.get(e);i.isWhitespace||(t="",0!==i.canvasWidth&&(r=(n=e.style).fontSize,n=n.fontFamily,r===this._layoutTextLastFontSize&&n===this._layoutTextLastFontFamily||(this._layoutTextCtx.font="".concat(r," ").concat(n),this._layoutTextLastFontSize=r,this._layoutTextLastFontFamily=n),0<(n=this._layoutTextCtx.measureText(e.textContent).width)&&(i.scale=i.canvasWidth/n,t="scaleX(".concat(i.scale,")"))),0<(t=0!==i.angle?"rotate(".concat(i.angle,"deg) ").concat(t):t).length&&(this._enhanceTextSelection&&(i.originalTransform=t),e.style.transform=t),this._textDivProperties.set(e,i),this._container.appendChild(e))},_render:function(e){var t=this,r=(0,i.createPromiseCapability)(),n=Object.create(null),a=this._document.createElement("canvas");if(a.mozOpaque=!0,this._layoutTextCtx=a.getContext("2d",{alpha:!1}),this._textContent){a=this._textContent.items;var s=this._textContent.styles;this._processItems(a,s),r.resolve()}else{if(!this._textContentStream)throw new Error('Neither "textContent" nor "textContentStream" parameters specified.');s=function e(){t._reader.read().then((function(i){var a=i.value;i.done?r.resolve():(Object.assign(n,a.styles),t._processItems(a.items,n),e())}),r.reject)},this._reader=this._textContentStream.getReader(),s()}r.promise.then((function(){n=null,e?t._renderTimer=setTimeout((function(){o(t),t._renderTimer=null}),e):o(t)}),this._capability.reject)},expandTextDivs:function(e){if(this._enhanceTextSelection&&this._renderingDone){null!==this._bounds&&(u(this),this._bounds=null);for(var t=[],r=[],n=0,i=this._textDivs.length;n<i;n++){var a=this._textDivs[n],o=this._textDivProperties.get(a);o.isWhitespace||(e?(t.length=0,r.length=0,o.originalTransform&&t.push(o.originalTransform),0<o.paddingTop?(r.push("".concat(o.paddingTop,"px")),t.push("translateY(".concat(-o.paddingTop,"px)"))):r.push(0),0<o.paddingRight?r.push("".concat(o.paddingRight/o.scale,"px")):r.push(0),0<o.paddingBottom?r.push("".concat(o.paddingBottom,"px")):r.push(0),0<o.paddingLeft?(r.push("".concat(o.paddingLeft/o.scale,"px")),t.push("translateX(".concat(-o.paddingLeft/o.scale,"px)"))):r.push(0),a.style.padding=r.join(" "),t.length&&(a.style.transform=t.join(" "))):(a.style.padding=null,a.style.transform=o.originalTransform))}}}},r=function(e){var t=new c({textContent:e.textContent,textContentStream:e.textContentStream,container:e.container,viewport:e.viewport,textDivs:e.textDivs,textContentItemsStr:e.textContentItemsStr,enhanceTextSelection:e.enhanceTextSelection});return t._render(e.timeout),t};function a(e,t,r){var a=document.createElement("span"),o={angle:0,canvasWidth:0,isWhitespace:!1,originalTransform:null,paddingBottom:0,paddingLeft:0,paddingRight:0,paddingTop:0,scale:1};if(e._textDivs.push(a),p=t.str,!n.test(p))return o.isWhitespace=!0,void e._textDivProperties.set(a,o);var s=i.Util.transform(e._viewport.transform,t.transform),u=Math.atan2(s[1],s[0]),l=r[t.fontName];l.vertical&&(u+=Math.PI/2);var c,h=Math.sqrt(s[2]*s[2]+s[3]*s[3]),f=h;l.ascent?f=l.ascent*f:l.descent&&(f=(1+l.descent)*f),p=0===u?(c=s[4],s[5]-f):(c=s[4]+f*Math.sin(u),s[5]-f*Math.cos(u)),a.style.left="".concat(c,"px"),a.style.top="".concat(p,"px"),a.style.fontSize="".concat(h,"px"),a.style.fontFamily=l.fontFamily,a.textContent=t.str,e._fontInspectorEnabled&&(a.dataset.fontName=t.fontName),0!==u&&(o.angle=u*(180/Math.PI));var d,p;r=!1;1<t.str.length?r=!0:t.transform[0]===t.transform[3]||(s=Math.abs(t.transform[0]))!==(f=Math.abs(t.transform[3]))&&1.5<Math.max(s,f)/Math.min(s,f)&&(r=!0),r&&(l.vertical?o.canvasWidth=t.height*e._viewport.scale:o.canvasWidth=t.width*e._viewport.scale),e._textDivProperties.set(a,o),e._textContentStream&&e._layoutText(a),e._enhanceTextSelection&&(r=1,(o=0)!==u&&(r=Math.cos(u),o=Math.sin(u)),t=(l.vertical?t.height:t.width)*e._viewport.scale,h=h,p=0!==u?i.Util.getAxialAlignedBoundingBox([0,0,t,h],d=[r,o,-o,r,c,p]):[c,p,c+t,p+h],e._bounds.push({left:p[0],top:p[1],right:p[2],bottom:p[3],div:a,size:[t,h],m:d}))}function o(e){if(!e._canceled){var t=e._textDivs,r=e._capability,n=t.length;if(1e5<n)return e._renderingDone=!0,void r.resolve();if(!e._textContentStream)for(var i=0;i<n;i++)e._layoutText(t[i]);e._renderingDone=!0,r.resolve()}}function s(e,t,r){for(var n=0,i=0;i<r;i++){var a=e[t++];0<a&&(n=n?Math.min(a,n):a)}return n}function u(e){for(var t=e._bounds,r=e._viewport,n=function(e,t,r){var n=r.map((function(e,t){return{x1:e.left,y1:e.top,x2:e.right,y2:e.bottom,index:t,x1New:void 0,x2New:void 0}}));l(e,n);var i=new Array(r.length);return n.forEach((function(e){var t=e.index;i[t]={left:e.x1New,top:0,right:e.x2New,bottom:0}})),r.map((function(t,r){var a=i[r],o=n[r];o.x1=t.top,o.y1=e-a.right,o.x2=t.bottom,o.y2=e-a.left,o.index=r,o.x1New=void 0,o.x2New=void 0})),l(t,n),n.forEach((function(e){var t=e.index;i[t].top=e.x1New,i[t].bottom=e.x2New})),i}(r.width,r.height,t),a=0;a<n.length;a++){var o,u,c,h,f,d,p=t[a].div,v=e._textDivProperties.get(p);0!==v.angle?(o=n[a],d=t[a],u=d.m,c=u[0],h=u[1],d=[[0,0],[0,d.size[1]],[d.size[0],0],d.size],f=new Float64Array(64),d.forEach((function(e,t){e=i.Util.applyTransform(e,u),f[t+0]=c&&(o.left-e[0])/c,f[t+4]=h&&(o.top-e[1])/h,f[t+8]=c&&(o.right-e[0])/c,f[t+12]=h&&(o.bottom-e[1])/h,f[t+16]=h&&(o.left-e[0])/-h,f[t+20]=c&&(o.top-e[1])/c,f[t+24]=h&&(o.right-e[0])/-h,f[t+28]=c&&(o.bottom-e[1])/c,f[t+32]=c&&(o.left-e[0])/-c,f[t+36]=h&&(o.top-e[1])/-h,f[t+40]=c&&(o.right-e[0])/-c,f[t+44]=h&&(o.bottom-e[1])/-h,f[t+48]=h&&(o.left-e[0])/h,f[t+52]=c&&(o.top-e[1])/-c,f[t+56]=h&&(o.right-e[0])/h,f[t+60]=c&&(o.bottom-e[1])/-c})),d=1+Math.min(Math.abs(c),Math.abs(h)),v.paddingLeft=s(f,32,16)/d,v.paddingTop=s(f,48,16)/d,v.paddingRight=s(f,0,16)/d,v.paddingBottom=s(f,16,16)/d,e._textDivProperties.set(p,v)):(v.paddingLeft=t[a].left-n[a].left,v.paddingTop=t[a].top-n[a].top,v.paddingRight=n[a].right-t[a].right,v.paddingBottom=n[a].bottom-t[a].bottom,e._textDivProperties.set(p,v))}}function l(e,t){t.sort((function(e,t){return e.x1-t.x1||e.index-t.index}));var r=[{start:-1/0,end:1/0,boundary:{x1:-1/0,y1:-1/0,x2:0,y2:1/0,index:-1,x1New:0,x2New:0}}];t.forEach((function(e){for(var t=0;t<r.length&&r[t].end<=e.y1;)t++;for(var n=r.length-1;0<=n&&r[n].start>=e.y2;)n--;for(var i=-1/0,a=t;a<=n;a++){var o,s,u=(s=(o=r[a]).boundary).x2>e.x1?s.index>e.index?s.x1New:e.x1:void 0===s.x2New?(s.x2+e.x1)/2:s.x2New;i<u&&(i=u)}for(e.x1New=i,a=t;a<=n;a++)void 0===(s=(o=r[a]).boundary).x2New?s.x2>e.x1?s.index>e.index&&(s.x2New=s.x2):s.x2New=i:s.x2New>i&&(s.x2New=Math.max(i,s.x2));var l=[],c=null;for(a=t;a<=n;a++){var h=(s=(o=r[a]).boundary).x2>e.x2?s:e;c===h?l[l.length-1].end=o.end:(l.push({start:o.start,end:o.end,boundary:h}),c=h)}for(r[t].start<e.y1&&(l[0].start=e.y1,l.unshift({start:r[t].start,end:e.y1,boundary:r[t].boundary})),e.y2<r[n].end&&(l[l.length-1].end=e.y2,l.push({start:e.y2,end:r[n].end,boundary:r[n].boundary})),a=t;a<=n;a++)if(void 0===(s=(o=r[a]).boundary).x2New){for(var f=!1,d=t-1;!f&&0<=d&&r[d].start>=s.y1;d--)f=r[d].boundary===s;for(d=n+1;!f&&d<r.length&&r[d].end<=s.y2;d++)f=r[d].boundary===s;for(d=0;!f&&d<l.length;d++)f=l[d].boundary===s;f||(s.x2New=i)}Array.prototype.splice.apply(r,[t,n-t+1].concat(l))})),r.forEach((function(t){t=t.boundary,void 0===t.x2New&&(t.x2New=Math.max(e,t.x2))}))}function c(e){var t=this,r=e.textContent,n=e.textContentStream,a=e.container,o=e.viewport,s=e.textDivs,u=e.textContentItemsStr;e=e.enhanceTextSelection;this._textContent=r,this._textContentStream=n,this._container=a,this._document=a.ownerDocument,this._viewport=o,this._textDivs=s||[],this._textContentItemsStr=u||[],this._enhanceTextSelection=!!e,this._fontInspectorEnabled=!(!globalThis.FontInspector||!globalThis.FontInspector.enabled),this._reader=null,this._layoutTextLastFontSize=null,this._layoutTextLastFontFamily=null,this._layoutTextCtx=null,this._textDivProperties=new WeakMap,this._renderingDone=!1,this._canceled=!1,this._capability=(0,i.createPromiseCapability)(),this._renderTimer=null,this._bounds=[],this._capability.promise.finally((function(){t._layoutTextCtx&&(t._layoutTextCtx.canvas.width=0,t._layoutTextCtx.canvas.height=0,t._layoutTextCtx=null)})).catch((function(){}))}t.renderTextLayer=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SVGGraphics=void 0;var n=r(5),i=r(1),a=r(7);function o(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||l(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 s(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}(e,t)||l(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 u(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=l(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function l(e,t){if(e){if("string"==typeof e)return c(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?c(e,t):void 0}}function c(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 h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f(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,n.key,n)}}function d(e,t,r){return t&&f(e.prototype,t),r&&f(e,r),e}function p(e){if(Number.isInteger(e))return e.toString();var t=e.toFixed(10),r=t.length-1;if("0"!==t[r])return t;for(;"0"===t[--r];);return t.substring(0,"."===t[r]?r:r+1)}function v(e){if(0===e[4]&&0===e[5]){if(0===e[1]&&0===e[2])return 1===e[0]&&1===e[3]?"":"scale(".concat(p(e[0])," ").concat(p(e[3]),")");if(e[0]===e[3]&&e[1]===-e[2]){var t=180*Math.acos(e[0])/Math.PI;return"rotate(".concat(p(t),")")}}else if(1===e[0]&&0===e[1]&&0===e[2]&&1===e[3])return"translate(".concat(p(e[4])," ").concat(p(e[5]),")");return"matrix(".concat(p(e[0])," ").concat(p(e[1])," ").concat(p(e[2])," ").concat(p(e[3])," ").concat(p(e[4])," ")+"".concat(p(e[5]),")")}t.SVGGraphics=function(){throw new Error("Not implemented: SVGGraphics")};var g={fontStyle:"normal",fontWeight:"normal",fillColor:"#000000"},y=["butt","round","square"],m=["miter","round","bevel"],b=function(){for(var e=new Uint8Array([137,80,78,71,13,10,26,10]),t=new Int32Array(256),r=0;r<256;r++){for(var i=r,o=0;o<8;o++)i=1&i?3988292384^i>>1&2147483647:i>>1&2147483647;t[r]=i}function s(e,r,n,i){var a=i,o=r.length;n[a]=o>>24&255,n[a+1]=o>>16&255,n[a+2]=o>>8&255,n[a+3]=255&o,n[a+=4]=255&e.charCodeAt(0),n[a+1]=255&e.charCodeAt(1),n[a+2]=255&e.charCodeAt(2),n[a+3]=255&e.charCodeAt(3),n.set(r,a+=4),r=function(e,r,n){for(var i=-1,a=r;a<n;a++){var o=255&(i^e[a]);i=i>>>8^t[o]}return-1^i}(n,i+4,a+=r.length),n[a]=r>>24&255,n[a+1]=r>>16&255,n[a+2]=r>>8&255,n[a+3]=255&r}function u(e){var t=e.length,r=65535,n=Math.ceil(t/r),i=new Uint8Array(2+t+5*n+4),a=0;i[a++]=120,i[a++]=156;for(var o=0;r<t;)i[a++]=0,i[a++]=255,i[a++]=255,i[a++]=0,i[a++]=0,i.set(e.subarray(o,o+r),a),a+=r,o+=r,t-=r;return i[a++]=1,i[a++]=255&t,i[a++]=t>>8&255,i[a++]=255&~t,i[a++]=(65535&~t)>>8&255,i.set(e.subarray(o),a),a+=e.length-o,n=function(e,t,r){for(var n=1,i=0,a=t;a<r;++a)i=(i+(n=(n+(255&e[a]))%65521))%65521;return i<<16|n}(e,0,e.length),i[a++]=n>>24&255,i[a++]=n>>16&255,i[a++]=n>>8&255,i[a++]=255&n,i}function l(t,r,i,o){var l,c,h,f=t.width,d=t.height,p=t.data;switch(r){case n.ImageKind.GRAYSCALE_1BPP:c=0,l=1,h=f+7>>3;break;case n.ImageKind.RGB_24BPP:c=2,l=8,h=3*f;break;case n.ImageKind.RGBA_32BPP:c=6,l=8,h=4*f;break;default:throw new Error("invalid format")}for(var v=new Uint8Array((1+h)*d),g=0,y=0,m=0;m<d;++m)v[g++]=0,v.set(p.subarray(y,y+h),g),y+=h,g+=h;if(r===n.ImageKind.GRAYSCALE_1BPP&&o){g=0;for(var b=0;b<d;b++){g++;for(var _=0;_<h;_++)v[g++]^=255}}var w=new Uint8Array([f>>24&255,f>>16&255,f>>8&255,255&f,d>>24&255,d>>16&255,d>>8&255,255&d,l,c,0,0,0]);t=function(e){if(!a.isNodeJS)return u(e);try{var t=8<=parseInt(process.versions.node)?e:Buffer.from(e),r=__webpack_require__(20).deflateSync(t,{level:9});return r instanceof Uint8Array?r:new Uint8Array(r)}catch(e){(0,n.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+e)}return u(e)}(v),r=e.length+36+w.length+t.length,o=new Uint8Array(r),r=0;return o.set(e,0),s("IHDR",w,o,r+=e.length),s("IDATA",t,o,r+=12+w.length),r+=12+t.length,s("IEND",new Uint8Array(0),o,r),(0,n.createObjectURL)(o,"image/png",i)}return function(e,t,r){return l(e,void 0===e.kind?n.ImageKind.GRAYSCALE_1BPP:e.kind,t,r)}}(),_=function(){function e(){h(this,e),this.fontSizeScale=1,this.fontWeight=g.fontWeight,this.fontSize=0,this.textMatrix=n.IDENTITY_MATRIX,this.fontMatrix=n.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=n.TextRenderingMode.FILL,this.textMatrixScale=1,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRise=0,this.fillColor=g.fillColor,this.strokeColor="#000000",this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.lineJoin="",this.lineCap="",this.miterLimit=0,this.dashArray=[],this.dashPhase=0,this.dependencies=[],this.activeClipUrl=null,this.clipGroup=null,this.maskId=""}return d(e,[{key:"clone",value:function(){return Object.create(this)}},{key:"setCurrentPoint",value:function(e,t){this.x=e,this.y=t}}]),e}(),w=0,A=0,S=0;t.SVGGraphics=function(){function e(t,r){var a,o=2<arguments.length&&void 0!==arguments[2]&&arguments[2];for(a in h(this,e),this.svgFactory=new i.DOMSVGFactory,this.current=new _,this.transformMatrix=n.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=t,this.objs=r,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!o,this._operatorIdMapping=[],n.OPS)this._operatorIdMapping[n.OPS[a]]=a}return d(e,[{key:"save",value:function(){this.transformStack.push(this.transformMatrix);var e=this.current;this.extraStack.push(e),this.current=e.clone()}},{key:"restore",value:function(){this.transformMatrix=this.transformStack.pop(),this.current=this.extraStack.pop(),this.pendingClip=null,this.tgrp=null}},{key:"group",value:function(e){this.save(),this.executeOpTree(e),this.restore()}},{key:"loadDependencies",value:function(e){for(var t=this,r=e.fnArray,i=e.argsArray,a=0,o=r.length;a<o;a++)if(r[a]===n.OPS.dependency){var s,l=u(i[a]);try{for(l.s();!(s=l.n()).done;)!function(){var e=s.value,r=e.startsWith("g_")?t.commonObjs:t.objs,n=new Promise((function(t){r.get(e,t)}));t.current.dependencies.push(n)}()}catch(e){l.e(e)}finally{l.f()}}return Promise.all(this.current.dependencies)}},{key:"transform",value:function(e,t,r,i,a,o){this.transformMatrix=n.Util.transform(this.transformMatrix,[e,t,r,i,a,o]),this.tgrp=null}},{key:"getSVG",value:function(e,t){var r=this;this.viewport=t;var i=this._initialize(t);return this.loadDependencies(e).then((function(){return r.transformMatrix=n.IDENTITY_MATRIX,r.executeOpTree(r.convertOpList(e)),i}))}},{key:"convertOpList",value:function(e){for(var t=this._operatorIdMapping,r=e.argsArray,n=e.fnArray,i=[],a=0,o=n.length;a<o;a++){var s=n[a];i.push({fnId:s,fn:t[s],args:r[a]})}return function(e){var t,r=[],n=[],i=u(e);try{for(i.s();!(t=i.n()).done;){var a=t.value;"save"!==a.fn?"restore"===a.fn?r=n.pop():r.push(a):(r.push({fnId:92,fn:"group",items:[]}),n.push(r),r=r[r.length-1].items)}}catch(e){i.e(e)}finally{i.f()}return r}(i)}},{key:"executeOpTree",value:function(e){var t,r=u(e);try{for(r.s();!(t=r.n()).done;){var i=t.value,a=i.fn,o=i.fnId,s=i.args;switch(0|o){case n.OPS.beginText:this.beginText();break;case n.OPS.dependency:break;case n.OPS.setLeading:this.setLeading(s);break;case n.OPS.setLeadingMoveText:this.setLeadingMoveText(s[0],s[1]);break;case n.OPS.setFont:this.setFont(s);break;case n.OPS.showText:case n.OPS.showSpacedText:this.showText(s[0]);break;case n.OPS.endText:this.endText();break;case n.OPS.moveText:this.moveText(s[0],s[1]);break;case n.OPS.setCharSpacing:this.setCharSpacing(s[0]);break;case n.OPS.setWordSpacing:this.setWordSpacing(s[0]);break;case n.OPS.setHScale:this.setHScale(s[0]);break;case n.OPS.setTextMatrix:this.setTextMatrix(s[0],s[1],s[2],s[3],s[4],s[5]);break;case n.OPS.setTextRise:this.setTextRise(s[0]);break;case n.OPS.setTextRenderingMode:this.setTextRenderingMode(s[0]);break;case n.OPS.setLineWidth:this.setLineWidth(s[0]);break;case n.OPS.setLineJoin:this.setLineJoin(s[0]);break;case n.OPS.setLineCap:this.setLineCap(s[0]);break;case n.OPS.setMiterLimit:this.setMiterLimit(s[0]);break;case n.OPS.setFillRGBColor:this.setFillRGBColor(s[0],s[1],s[2]);break;case n.OPS.setStrokeRGBColor:this.setStrokeRGBColor(s[0],s[1],s[2]);break;case n.OPS.setStrokeColorN:this.setStrokeColorN(s);break;case n.OPS.setFillColorN:this.setFillColorN(s);break;case n.OPS.shadingFill:this.shadingFill(s[0]);break;case n.OPS.setDash:this.setDash(s[0],s[1]);break;case n.OPS.setRenderingIntent:this.setRenderingIntent(s[0]);break;case n.OPS.setFlatness:this.setFlatness(s[0]);break;case n.OPS.setGState:this.setGState(s[0]);break;case n.OPS.fill:this.fill();break;case n.OPS.eoFill:this.eoFill();break;case n.OPS.stroke:this.stroke();break;case n.OPS.fillStroke:this.fillStroke();break;case n.OPS.eoFillStroke:this.eoFillStroke();break;case n.OPS.clip:this.clip("nonzero");break;case n.OPS.eoClip:this.clip("evenodd");break;case n.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case n.OPS.paintImageXObject:this.paintImageXObject(s[0]);break;case n.OPS.paintInlineImageXObject:this.paintInlineImageXObject(s[0]);break;case n.OPS.paintImageMaskXObject:this.paintImageMaskXObject(s[0]);break;case n.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(s[0],s[1]);break;case n.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case n.OPS.closePath:this.closePath();break;case n.OPS.closeStroke:this.closeStroke();break;case n.OPS.closeFillStroke:this.closeFillStroke();break;case n.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case n.OPS.nextLine:this.nextLine();break;case n.OPS.transform:this.transform(s[0],s[1],s[2],s[3],s[4],s[5]);break;case n.OPS.constructPath:this.constructPath(s[0],s[1]);break;case n.OPS.endPath:this.endPath();break;case 92:this.group(i.items);break;default:(0,n.warn)("Unimplemented operator ".concat(a))}}}catch(e){r.e(e)}finally{r.f()}}},{key:"setWordSpacing",value:function(e){this.current.wordSpacing=e}},{key:"setCharSpacing",value:function(e){this.current.charSpacing=e}},{key:"nextLine",value:function(){this.moveText(0,this.current.leading)}},{key:"setTextMatrix",value:function(e,t,r,n,i,a){var o=this.current;o.textMatrix=o.lineMatrix=[e,t,r,n,i,a],o.textMatrixScale=Math.sqrt(e*e+t*t),o.x=o.lineX=0,o.y=o.lineY=0,o.xcoords=[],o.ycoords=[],o.tspan=this.svgFactory.createElement("svg:tspan"),o.tspan.setAttributeNS(null,"font-family",o.fontFamily),o.tspan.setAttributeNS(null,"font-size","".concat(p(o.fontSize),"px")),o.tspan.setAttributeNS(null,"y",p(-o.y)),o.txtElement=this.svgFactory.createElement("svg:text"),o.txtElement.appendChild(o.tspan)}},{key:"beginText",value:function(){var e=this.current;e.x=e.lineX=0,e.y=e.lineY=0,e.textMatrix=n.IDENTITY_MATRIX,e.lineMatrix=n.IDENTITY_MATRIX,e.textMatrixScale=1,e.tspan=this.svgFactory.createElement("svg:tspan"),e.txtElement=this.svgFactory.createElement("svg:text"),e.txtgrp=this.svgFactory.createElement("svg:g"),e.xcoords=[],e.ycoords=[]}},{key:"moveText",value:function(e,t){var r=this.current;r.x=r.lineX+=e,r.y=r.lineY+=t,r.xcoords=[],r.ycoords=[],r.tspan=this.svgFactory.createElement("svg:tspan"),r.tspan.setAttributeNS(null,"font-family",r.fontFamily),r.tspan.setAttributeNS(null,"font-size","".concat(p(r.fontSize),"px")),r.tspan.setAttributeNS(null,"y",p(-r.y))}},{key:"showText",value:function(e){var t=this.current,r=t.font,i=t.fontSize;if(0!==i){var a,o=t.fontSizeScale,s=t.charSpacing,l=t.wordSpacing,c=t.fontDirection,h=t.textHScale*c,f=r.vertical,d=f?1:-1,y=r.defaultVMetrics,m=i*t.fontMatrix[0],b=0,_=u(e);try{for(_.s();!(a=_.n()).done;){var w,A,S,k,x,P,C,T,R=a.value;null!==R?(0,n.isNum)(R)?b+=d*R*i/1e3:(w=(R.isSpace?l:0)+s,A=R.fontChar,T=C=void 0,P=R.width,T=f?(k=void 0,S=R.vmetric||y,k=-(k=R.vmetric?S[1]:.5*P)*m,x=S[2]*m,P=S?-S[0]:P,C=k/o,(b+x)/o):(C=b/o,0),(R.isInFont||r.missingFile)&&(t.xcoords.push(t.x+C),f&&t.ycoords.push(-t.y+T),t.tspan.textContent+=A),b+=f?P*m-w*c:P*m+w*c):b+=c*l}}catch(e){_.e(e)}finally{_.f()}t.tspan.setAttributeNS(null,"x",t.xcoords.map(p).join(" ")),f?t.tspan.setAttributeNS(null,"y",t.ycoords.map(p).join(" ")):t.tspan.setAttributeNS(null,"y",p(-t.y)),f?t.y-=b:t.x+=b*h,t.tspan.setAttributeNS(null,"font-family",t.fontFamily),t.tspan.setAttributeNS(null,"font-size","".concat(p(t.fontSize),"px")),t.fontStyle!==g.fontStyle&&t.tspan.setAttributeNS(null,"font-style",t.fontStyle),t.fontWeight!==g.fontWeight&&t.tspan.setAttributeNS(null,"font-weight",t.fontWeight),e=t.textRenderingMode&n.TextRenderingMode.FILL_STROKE_MASK,e===n.TextRenderingMode.FILL||e===n.TextRenderingMode.FILL_STROKE?(t.fillColor!==g.fillColor&&t.tspan.setAttributeNS(null,"fill",t.fillColor),t.fillAlpha<1&&t.tspan.setAttributeNS(null,"fill-opacity",t.fillAlpha)):t.textRenderingMode===n.TextRenderingMode.ADD_TO_PATH?t.tspan.setAttributeNS(null,"fill","transparent"):t.tspan.setAttributeNS(null,"fill","none"),e!==n.TextRenderingMode.STROKE&&e!==n.TextRenderingMode.FILL_STROKE||(E=1/(t.textMatrixScale||1),this._setStrokeAttributes(t.tspan,E));var E=t.textMatrix;0!==t.textRise&&((E=E.slice())[5]+=t.textRise),t.txtElement.setAttributeNS(null,"transform","".concat(v(E)," scale(").concat(p(h),", -1)")),t.txtElement.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),t.txtElement.appendChild(t.tspan),t.txtgrp.appendChild(t.txtElement),this._ensureTransformGroup().appendChild(t.txtElement)}}},{key:"setLeadingMoveText",value:function(e,t){this.setLeading(-t),this.moveText(e,t)}},{key:"addFontStyle",value:function(e){if(!e.data)throw new Error('addFontStyle: No font data available, ensure that the "fontExtraProperties" API parameter is set.');this.cssStyle||(this.cssStyle=this.svgFactory.createElement("svg:style"),this.cssStyle.setAttributeNS(null,"type","text/css"),this.defs.appendChild(this.cssStyle));var t=(0,n.createObjectURL)(e.data,e.mimetype,this.forceDataSchema);this.cssStyle.textContent+='@font-face { font-family: "'.concat(e.loadedName,'";')+" src: url(".concat(t,"); }\n")}},{key:"setFont",value:function(e){var t=this.current,r=this.commonObjs.get(e[0]),i=e[1];t.font=r,!this.embedFonts||r.missingFile||this.embeddedFonts[r.loadedName]||(this.addFontStyle(r),this.embeddedFonts[r.loadedName]=r),t.fontMatrix=r.fontMatrix||n.FONT_IDENTITY_MATRIX;var a="normal";r.black?a="900":r.bold&&(a="bold"),e=r.italic?"italic":"normal",i<0?(i=-i,t.fontDirection=-1):t.fontDirection=1,t.fontSize=i,t.fontFamily=r.loadedName,t.fontWeight=a,t.fontStyle=e,t.tspan=this.svgFactory.createElement("svg:tspan"),t.tspan.setAttributeNS(null,"y",p(-t.y)),t.xcoords=[],t.ycoords=[]}},{key:"endText",value:function(){var e=this.current;e.textRenderingMode&n.TextRenderingMode.ADD_TO_PATH_FLAG&&e.txtElement&&e.txtElement.hasChildNodes()&&(e.element=e.txtElement,this.clip("nonzero"),this.endPath())}},{key:"setLineWidth",value:function(e){0<e&&(this.current.lineWidth=e)}},{key:"setLineCap",value:function(e){this.current.lineCap=y[e]}},{key:"setLineJoin",value:function(e){this.current.lineJoin=m[e]}},{key:"setMiterLimit",value:function(e){this.current.miterLimit=e}},{key:"setStrokeAlpha",value:function(e){this.current.strokeAlpha=e}},{key:"setStrokeRGBColor",value:function(e,t,r){this.current.strokeColor=n.Util.makeCssRgb(e,t,r)}},{key:"setFillAlpha",value:function(e){this.current.fillAlpha=e}},{key:"setFillRGBColor",value:function(e,t,r){this.current.fillColor=n.Util.makeCssRgb(e,t,r),this.current.tspan=this.svgFactory.createElement("svg:tspan"),this.current.xcoords=[],this.current.ycoords=[]}},{key:"setStrokeColorN",value:function(e){this.current.strokeColor=this._makeColorN_Pattern(e)}},{key:"setFillColorN",value:function(e){this.current.fillColor=this._makeColorN_Pattern(e)}},{key:"shadingFill",value:function(e){var t=this.viewport.width,r=this.viewport.height,i=n.Util.inverseTransform(this.transformMatrix),a=n.Util.applyTransform([0,0],i),o=n.Util.applyTransform([0,r],i),s=n.Util.applyTransform([t,0],i),u=n.Util.applyTransform([t,r],i);t=Math.min(a[0],o[0],s[0],u[0]),r=Math.min(a[1],o[1],s[1],u[1]),i=Math.max(a[0],o[0],s[0],u[0]),s=Math.max(a[1],o[1],s[1],u[1]),u=this.svgFactory.createElement("svg:rect");u.setAttributeNS(null,"x",t),u.setAttributeNS(null,"y",r),u.setAttributeNS(null,"width",i-t),u.setAttributeNS(null,"height",s-r),u.setAttributeNS(null,"fill",this._makeShadingPattern(e)),this.current.fillAlpha<1&&u.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().appendChild(u)}},{key:"_makeColorN_Pattern",value:function(e){return"TilingPattern"===e[0]?this._makeTilingPattern(e):this._makeShadingPattern(e)}},{key:"_makeTilingPattern",value:function(e){var t=e[1],r=e[2],i=e[3]||n.IDENTITY_MATRIX,a=s(e[4],4),u=a[0],l=a[1],c=a[2],h=a[3],f=e[5],d=e[6],p=e[7],v="shading".concat(S++),g=s(n.Util.applyTransform([u,l],i),2);a=g[0],e=g[1],u=s(n.Util.applyTransform([c,h],i),2),l=u[0],g=u[1],c=s(n.Util.singularValueDecompose2dScale(i),2),h=f*c[0],u=d*c[1],f=this.svgFactory.createElement("svg:pattern");return f.setAttributeNS(null,"id",v),f.setAttributeNS(null,"patternUnits","userSpaceOnUse"),f.setAttributeNS(null,"width",h),f.setAttributeNS(null,"height",u),f.setAttributeNS(null,"x","".concat(a)),f.setAttributeNS(null,"y","".concat(e)),d=this.svg,c=this.transformMatrix,h=this.current.fillColor,u=this.current.strokeColor,e=this.svgFactory.create(l-a,g-e),this.svg=e,this.transformMatrix=i,2===p&&(t=n.Util.makeCssRgb.apply(n.Util,o(t)),this.current.fillColor=t,this.current.strokeColor=t),this.executeOpTree(this.convertOpList(r)),this.svg=d,this.transformMatrix=c,this.current.fillColor=h,this.current.strokeColor=u,f.appendChild(e.childNodes[0]),this.defs.appendChild(f),"url(#".concat(v,")")}},{key:"_makeShadingPattern",value:function(e){switch(e[0]){case"RadialAxial":var t="shading".concat(S++),r=e[3];switch(e[1]){case"axial":var i,a=e[4],o=e[5];(i=this.svgFactory.createElement("svg:linearGradient")).setAttributeNS(null,"id",t),i.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),i.setAttributeNS(null,"x1",a[0]),i.setAttributeNS(null,"y1",a[1]),i.setAttributeNS(null,"x2",o[0]),i.setAttributeNS(null,"y2",o[1]);break;case"radial":var s=e[4],l=e[5];a=e[6],o=e[7];(i=this.svgFactory.createElement("svg:radialGradient")).setAttributeNS(null,"id",t),i.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),i.setAttributeNS(null,"cx",l[0]),i.setAttributeNS(null,"cy",l[1]),i.setAttributeNS(null,"r",o),i.setAttributeNS(null,"fx",s[0]),i.setAttributeNS(null,"fy",s[1]),i.setAttributeNS(null,"fr",a);break;default:throw new Error("Unknown RadialAxial type: ".concat(e[1]))}var c,h=u(r);try{for(h.s();!(c=h.n()).done;){var f=c.value,d=this.svgFactory.createElement("svg:stop");d.setAttributeNS(null,"offset",f[0]),d.setAttributeNS(null,"stop-color",f[1]),i.appendChild(d)}}catch(e){h.e(e)}finally{h.f()}return this.defs.appendChild(i),"url(#".concat(t,")");case"Mesh":return(0,n.warn)("Unimplemented pattern Mesh"),null;case"Dummy":return"hotpink";default:throw new Error("Unknown IR type: ".concat(e[0]))}}},{key:"setDash",value:function(e,t){this.current.dashArray=e,this.current.dashPhase=t}},{key:"constructPath",value:function(e,t){var r,i=this.current,a=i.x,o=i.y,s=[],l=0,c=u(e);try{for(c.s();!(r=c.n()).done;)switch(0|r.value){case n.OPS.rectangle:a=t[l++],o=t[l++];var h=t[l++],f=t[l++],d=a+h,v=o+f;s.push("M",p(a),p(o),"L",p(d),p(o),"L",p(d),p(v),"L",p(a),p(v),"Z");break;case n.OPS.moveTo:a=t[l++],o=t[l++],s.push("M",p(a),p(o));break;case n.OPS.lineTo:a=t[l++],o=t[l++],s.push("L",p(a),p(o));break;case n.OPS.curveTo:a=t[l+4],o=t[l+5],s.push("C",p(t[l]),p(t[l+1]),p(t[l+2]),p(t[l+3]),p(a),p(o)),l+=6;break;case n.OPS.curveTo2:s.push("C",p(a),p(o),p(t[l]),p(t[l+1]),p(t[l+2]),p(t[l+3])),a=t[l+2],o=t[l+3],l+=4;break;case n.OPS.curveTo3:a=t[l+2],o=t[l+3],s.push("C",p(t[l]),p(t[l+1]),p(a),p(o),p(a),p(o)),l+=4;break;case n.OPS.closePath:s.push("Z")}}catch(e){c.e(e)}finally{c.f()}s=s.join(" "),i.path&&0<e.length&&e[0]!==n.OPS.rectangle&&e[0]!==n.OPS.moveTo?s=i.path.getAttributeNS(null,"d")+s:(i.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().appendChild(i.path)),i.path.setAttributeNS(null,"d",s),i.path.setAttributeNS(null,"fill","none"),i.element=i.path,i.setCurrentPoint(a,o)}},{key:"endPath",value:function(){var e,t,r,n=this.current;n.path=null,this.pendingClip&&(n.element?(e="clippath".concat(w++),(t=this.svgFactory.createElement("svg:clipPath")).setAttributeNS(null,"id",e),t.setAttributeNS(null,"transform",v(this.transformMatrix)),r=n.element.cloneNode(!0),"evenodd"===this.pendingClip?r.setAttributeNS(null,"clip-rule","evenodd"):r.setAttributeNS(null,"clip-rule","nonzero"),this.pendingClip=null,t.appendChild(r),this.defs.appendChild(t),n.activeClipUrl&&(n.clipGroup=null,this.extraStack.forEach((function(e){e.clipGroup=null})),t.setAttributeNS(null,"clip-path",n.activeClipUrl)),n.activeClipUrl="url(#".concat(e,")"),this.tgrp=null):this.pendingClip=null)}},{key:"clip",value:function(e){this.pendingClip=e}},{key:"closePath",value:function(){var e,t=this.current;t.path&&(e="".concat(t.path.getAttributeNS(null,"d"),"Z"),t.path.setAttributeNS(null,"d",e))}},{key:"setLeading",value:function(e){this.current.leading=-e}},{key:"setTextRise",value:function(e){this.current.textRise=e}},{key:"setTextRenderingMode",value:function(e){this.current.textRenderingMode=e}},{key:"setHScale",value:function(e){this.current.textHScale=e/100}},{key:"setRenderingIntent",value:function(e){}},{key:"setFlatness",value:function(e){}},{key:"setGState",value:function(e){var t,r=u(e);try{for(r.s();!(t=r.n()).done;){var i=s(t.value,2),a=i[0],o=i[1];switch(a){case"LW":this.setLineWidth(o);break;case"LC":this.setLineCap(o);break;case"LJ":this.setLineJoin(o);break;case"ML":this.setMiterLimit(o);break;case"D":this.setDash(o[0],o[1]);break;case"RI":this.setRenderingIntent(o);break;case"FL":this.setFlatness(o);break;case"Font":this.setFont(o);break;case"CA":this.setStrokeAlpha(o);break;case"ca":this.setFillAlpha(o);break;default:(0,n.warn)("Unimplemented graphic state operator ".concat(a))}}}catch(e){r.e(e)}finally{r.f()}}},{key:"fill",value:function(){var e=this.current;e.element&&(e.element.setAttributeNS(null,"fill",e.fillColor),e.element.setAttributeNS(null,"fill-opacity",e.fillAlpha),this.endPath())}},{key:"stroke",value:function(){var e=this.current;e.element&&(this._setStrokeAttributes(e.element),e.element.setAttributeNS(null,"fill","none"),this.endPath())}},{key:"_setStrokeAttributes",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,r=this.current,n=r.dashArray;1!==t&&0<n.length&&(n=n.map((function(e){return t*e}))),e.setAttributeNS(null,"stroke",r.strokeColor),e.setAttributeNS(null,"stroke-opacity",r.strokeAlpha),e.setAttributeNS(null,"stroke-miterlimit",p(r.miterLimit)),e.setAttributeNS(null,"stroke-linecap",r.lineCap),e.setAttributeNS(null,"stroke-linejoin",r.lineJoin),e.setAttributeNS(null,"stroke-width",p(t*r.lineWidth)+"px"),e.setAttributeNS(null,"stroke-dasharray",n.map(p).join(" ")),e.setAttributeNS(null,"stroke-dashoffset",p(t*r.dashPhase)+"px")}},{key:"eoFill",value:function(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fill()}},{key:"fillStroke",value:function(){this.stroke(),this.fill()}},{key:"eoFillStroke",value:function(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fillStroke()}},{key:"closeStroke",value:function(){this.closePath(),this.stroke()}},{key:"closeFillStroke",value:function(){this.closePath(),this.fillStroke()}},{key:"closeEOFillStroke",value:function(){this.closePath(),this.eoFillStroke()}},{key:"paintSolidColorImageMask",value:function(){var e=this.svgFactory.createElement("svg:rect");e.setAttributeNS(null,"x","0"),e.setAttributeNS(null,"y","0"),e.setAttributeNS(null,"width","1px"),e.setAttributeNS(null,"height","1px"),e.setAttributeNS(null,"fill",this.current.fillColor),this._ensureTransformGroup().appendChild(e)}},{key:"paintImageXObject",value:function(e){var t=(e.startsWith("g_")?this.commonObjs:this.objs).get(e);t?this.paintInlineImageXObject(t):(0,n.warn)("Dependent image with object ID ".concat(e," is not ready yet"))}},{key:"paintInlineImageXObject",value:function(e,t){var r=e.width,n=e.height,i=b(e,this.forceDataSchema,!!t);e=this.svgFactory.createElement("svg:rect");e.setAttributeNS(null,"x","0"),e.setAttributeNS(null,"y","0"),e.setAttributeNS(null,"width",p(r)),e.setAttributeNS(null,"height",p(n)),this.current.element=e,this.clip("nonzero"),e=this.svgFactory.createElement("svg:image"),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i),e.setAttributeNS(null,"x","0"),e.setAttributeNS(null,"y",p(-n)),e.setAttributeNS(null,"width",p(r)+"px"),e.setAttributeNS(null,"height",p(n)+"px"),e.setAttributeNS(null,"transform","scale(".concat(p(1/r)," ").concat(p(-1/n),")")),(t||this._ensureTransformGroup()).appendChild(e)}},{key:"paintImageMaskXObject",value:function(e){var t=this.current,r=e.width,n=e.height,i=t.fillColor;t.maskId="mask".concat(A++);var a=this.svgFactory.createElement("svg:mask");a.setAttributeNS(null,"id",t.maskId);var o=this.svgFactory.createElement("svg:rect");o.setAttributeNS(null,"x","0"),o.setAttributeNS(null,"y","0"),o.setAttributeNS(null,"width",p(r)),o.setAttributeNS(null,"height",p(n)),o.setAttributeNS(null,"fill",i),o.setAttributeNS(null,"mask","url(#".concat(t.maskId,")")),this.defs.appendChild(a),this._ensureTransformGroup().appendChild(o),this.paintInlineImageXObject(e,a)}},{key:"paintFormXObjectBegin",value:function(e,t){var r,n;Array.isArray(e)&&6===e.length&&this.transform(e[0],e[1],e[2],e[3],e[4],e[5]),t&&(r=t[2]-t[0],n=t[3]-t[1],(e=this.svgFactory.createElement("svg:rect")).setAttributeNS(null,"x",t[0]),e.setAttributeNS(null,"y",t[1]),e.setAttributeNS(null,"width",p(r)),e.setAttributeNS(null,"height",p(n)),this.current.element=e,this.clip("nonzero"),this.endPath())}},{key:"paintFormXObjectEnd",value:function(){}},{key:"_initialize",value:function(e){var t=this.svgFactory.create(e.width,e.height),r=this.svgFactory.createElement("svg:defs");return t.appendChild(r),this.defs=r,r=this.svgFactory.createElement("svg:g"),r.setAttributeNS(null,"transform",v(e.transform)),t.appendChild(r),this.svg=r,t}},{key:"_ensureClipGroup",value:function(){var e;return this.current.clipGroup||((e=this.svgFactory.createElement("svg:g")).setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.appendChild(e),this.current.clipGroup=e),this.current.clipGroup}},{key:"_ensureTransformGroup",value:function(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",v(this.transformMatrix)),(this.current.activeClipUrl?this._ensureClipGroup():this.svg).appendChild(this.tgrp)),this.tgrp}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFNodeStream=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5),o=r(220);function s(e){return(s="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)}function u(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}}),t&&l(e,t)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=h(t);return e=r?(e=h(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==s(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function f(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function d(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){f(a,n,i,o,s,"next",e)}function s(e){f(a,n,i,o,s,"throw",e)}o(void 0)}))}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function v(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,n.key,n)}}function g(e,t,r){return t&&v(e.prototype,t),r&&v(e,r),e}var y=__webpack_require__(18),m=__webpack_require__(21),b=__webpack_require__(22),_=__webpack_require__(23),w=/^file:\/\/\/[a-zA-Z]:\//;t.PDFNodeStream=function(){function e(t){var r,n;p(this,e),this.source=t,this.url=(r=t.url,"file:"===(n=_.parse(r)).protocol||n.host?n:/^[a-z]:[/\\]/i.test(r)?_.parse("file:///".concat(r)):(n.host||(n.protocol="file:"),n)),this.isHttp="http:"===this.url.protocol||"https:"===this.url.protocol,this.isFsUrl="file:"===this.url.protocol,this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}return g(e,[{key:"getFullReader",value:function(){return(0,a.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=new(this.isFsUrl?C:x)(this),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){return t<=this._progressiveDataLength?null:(t=new(this.isFsUrl?T:P)(this,e,t),this._rangeRequestReaders.push(t),t)}},{key:"cancelAllRequests",value:function(e){this._fullRequestReader&&this._fullRequestReader.cancel(e),this._rangeRequestReaders.slice(0).forEach((function(t){t.cancel(e)}))}},{key:"_progressiveDataLength",get:function(){return this._fullRequestReader?this._fullRequestReader._loaded:0}}]),e}();var A=function(){function e(t){p(this,e),this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null,t=t.source,this._contentLength=t.length,this._loaded=0,this._filename=null,this._disableRange=t.disableRange||!1,this._rangeChunkSize=t.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._readableStream=null,this._readCapability=(0,a.createPromiseCapability)(),this._headersCapability=(0,a.createPromiseCapability)()}var t;return g(e,[{key:"read",value:(t=d(i.default.mark((function e(){var t,r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._readCapability.promise;case 2:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=4;break;case 4:if(this._storedError)throw this._storedError;e.next=6;break;case 6:if(null===(t=this._readableStream.read()))return this._readCapability=(0,a.createPromiseCapability)(),e.abrupt("return",this.read());e.next=10;break;case 10:return this._loaded+=t.length,this.onProgress&&this.onProgress({loaded:this._loaded,total:this._contentLength}),r=new Uint8Array(t).buffer,e.abrupt("return",{value:r,done:!1});case 14:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._readableStream?this._readableStream.destroy(e):this._error(e)}},{key:"_error",value:function(e){this._storedError=e,this._readCapability.resolve()}},{key:"_setReadableStream",value:function(e){var t=this;(this._readableStream=e).on("readable",(function(){t._readCapability.resolve()})),e.on("end",(function(){e.destroy(),t._done=!0,t._readCapability.resolve()})),e.on("error",(function(e){t._error(e)})),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new a.AbortException("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}},{key:"headersReady",get:function(){return this._headersCapability.promise}},{key:"filename",get:function(){return this._filename}},{key:"contentLength",get:function(){return this._contentLength}},{key:"isRangeSupported",get:function(){return this._isRangeSupported}},{key:"isStreamingSupported",get:function(){return this._isStreamingSupported}}]),e}(),S=function(){function e(t){p(this,e),this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=(0,a.createPromiseCapability)(),t=t.source,this._isStreamingSupported=!t.disableStream}var t;return g(e,[{key:"read",value:(t=d(i.default.mark((function e(){var t,r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._readCapability.promise;case 2:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=4;break;case 4:if(this._storedError)throw this._storedError;e.next=6;break;case 6:if(null===(t=this._readableStream.read()))return this._readCapability=(0,a.createPromiseCapability)(),e.abrupt("return",this.read());e.next=10;break;case 10:return this._loaded+=t.length,this.onProgress&&this.onProgress({loaded:this._loaded}),r=new Uint8Array(t).buffer,e.abrupt("return",{value:r,done:!1});case 14:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._readableStream?this._readableStream.destroy(e):this._error(e)}},{key:"_error",value:function(e){this._storedError=e,this._readCapability.resolve()}},{key:"_setReadableStream",value:function(e){var t=this;(this._readableStream=e).on("readable",(function(){t._readCapability.resolve()})),e.on("end",(function(){e.destroy(),t._done=!0,t._readCapability.resolve()})),e.on("error",(function(e){t._error(e)})),this._storedError&&this._readableStream.destroy(this._storedError)}},{key:"isStreamingSupported",get:function(){return this._isStreamingSupported}}]),e}();function k(e,t){return{protocol:e.protocol,auth:e.auth,host:e.hostname,port:e.port,path:e.path,method:"GET",headers:t}}var x=function(){u(t,A);var e=c(t);function t(r){function n(e){if(404===e.statusCode){var t=new a.MissingPDFException('Missing PDF "'.concat(i._url,'".'));return i._storedError=t,void i._headersCapability.reject(t)}function n(e){return i._readableStream.headers[e.toLowerCase()]}i._headersCapability.resolve(),i._setReadableStream(e),t=(0,o.validateRangeRequestCapabilities)({getResponseHeader:n,isHttp:r.isHttp,rangeChunkSize:i._rangeChunkSize,disableRange:i._disableRange}),e=t.allowRangeRequests,t=t.suggestedLength,i._isRangeSupported=e,i._contentLength=t||i._contentLength,i._filename=(0,o.extractFilenameFromHeader)(n)}var i;return p(this,t),(i=e.call(this,r))._request=null,"http:"===i._url.protocol?i._request=m.request(k(i._url,r.httpHeaders),n):i._request=b.request(k(i._url,r.httpHeaders),n),i._request.on("error",(function(e){i._storedError=e,i._headersCapability.reject(e)})),i._request.end(),i}return t}(),P=function(){u(t,S);var e=c(t);function t(r,n,i){var o,s;for(s in p(this,t),(o=e.call(this,r))._httpHeaders={},r.httpHeaders){var u=r.httpHeaders[s];void 0!==u&&(o._httpHeaders[s]=u)}return o._httpHeaders.Range="bytes=".concat(n,"-").concat(i-1),i=function(e){404!==e.statusCode?o._setReadableStream(e):(e=new a.MissingPDFException('Missing PDF "'.concat(o._url,'".')),o._storedError=e)},o._request=null,"http:"===o._url.protocol?o._request=m.request(k(o._url,o._httpHeaders),i):o._request=b.request(k(o._url,o._httpHeaders),i),o._request.on("error",(function(e){o._storedError=e})),o._request.end(),o}return t}(),C=function(){u(t,A);var e=c(t);function t(r){p(this,t);var n=e.call(this,r),i=decodeURIComponent(n._url.path);return w.test(n._url.href)&&(i=i.replace(/^\//,"")),y.lstat(i,(function(e,t){return e?("ENOENT"===e.code&&(e=new a.MissingPDFException('Missing PDF "'.concat(i,'".'))),n._storedError=e,void n._headersCapability.reject(e)):(n._contentLength=t.size,n._setReadableStream(y.createReadStream(i)),void n._headersCapability.resolve())})),n}return t}(),T=function(){u(t,S);var e=c(t);function t(r,n,i){p(this,t);var a=e.call(this,r);r=decodeURIComponent(a._url.path);return w.test(a._url.href)&&(r=r.replace(/^\//,"")),a._setReadableStream(y.createReadStream(r,{start:n,end:i-1})),a}return t}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createResponseStatusError=function(e,t){return 404===e||0===e&&t.startsWith("file:")?new n.MissingPDFException('Missing PDF "'+t+'".'):new n.UnexpectedResponseException("Unexpected server response ("+e+') while retrieving PDF "'+t+'".',e)},t.extractFilenameFromHeader=function(e){if(e=e("Content-Disposition"),e){if(e=(0,i.getFilenameFromContentDispositionHeader)(e),e.includes("%"))try{e=decodeURIComponent(e)}catch(e){}if(/\.pdf$/i.test(e))return e}return null},t.validateRangeRequestCapabilities=function(e){var t=e.getResponseHeader,r=e.isHttp,i=e.rangeChunkSize,a=e.disableRange;(0,n.assert)(0<i,"Range chunk size must be larger than zero");var o={allowRangeRequests:!1,suggestedLength:void 0};e=parseInt(t("Content-Length"),10);return Number.isInteger(e)?((o.suggestedLength=e)<=2*i||!a&&r&&"bytes"===t("Accept-Ranges")&&"identity"===(t("Content-Encoding")||"identity")&&(o.allowRangeRequests=!0),o):o},t.validateResponseStatus=function(e){return 200===e||206===e};var n=r(5),i=r(221)},function(e,t,r){"use strict";function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}}(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 i(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}Object.defineProperty(t,"__esModule",{value:!0}),t.getFilenameFromContentDispositionHeader=function(e){var t=!0,r=a("filename\\*","i").exec(e);if(r){var i=u(r=r[1]);return s(i=c(i=l(i=unescape(i))))}if(r=function(e){for(var t=[],r=a("filename\\*((?!0\\d)\\d+)(\\*?)","ig");null!==(s=r.exec(e));){var i=n(s,4),o=i[1],s=i[2];i=i[3];if((o=parseInt(o,10))in t){if(0===o)break}else t[o]=[s,i]}for(var c=[],h=0;h<t.length&&h in t;++h){var f=n(t[h],2),d=f[0];f=f[1];f=u(f),d&&(f=unescape(f),0===h&&(f=l(f))),c.push(f)}return c.join("")}(e))return s(c(r));if(r=a("filename","i").exec(e))return r=u(r=r[1]),s(r=c(r));function a(e,t){return new RegExp("(?:^|;)\\s*"+e+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',t)}function o(e,r){if(e){if(!/^[\x00-\xFF]+$/.test(r))return r;try{var n=new TextDecoder(e,{fatal:!0}),i=Array.from(r,(function(e){return 255&e.charCodeAt(0)}));r=n.decode(new Uint8Array(i)),t=!1}catch(n){if(/^utf-?8$/i.test(e))try{r=decodeURIComponent(escape(r)),t=!1}catch(n){}}}return r}function s(e){return t&&/[\x80-\xff]/.test(e)&&(e=o("utf-8",e),t&&(e=o("iso-8859-1",e))),e}function u(e){if(e.startsWith('"')){for(var t=e.slice(1).split('\\"'),r=0;r<t.length;++r){var n=t[r].indexOf('"');-1!==n&&(t[r]=t[r].slice(0,n),t.length=r+1),t[r]=t[r].replace(/\\(.)/g,"$1")}e=t.join('"')}return e}function l(e){var t=e.indexOf("'");return-1===t?e:o(e.slice(0,t),e.slice(t+1).replace(/^[^']*'/,""))}function c(e){return!e.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(e)?e:e.replace(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,(function(e,t,r,n){if("q"===r||"Q"===r)return o(t,n=(n=n.replace(/_/g," ")).replace(/=([0-9a-fA-F]{2})/g,(function(e,t){return String.fromCharCode(parseInt(t,16))})));try{n=atob(n)}catch(e){}return o(t,n)}))}return""}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFNetworkStream=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5),o=r(220);function s(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function u(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){s(a,n,i,o,u,"next",e)}function u(e){s(a,n,i,o,u,"throw",e)}o(void 0)}))}}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(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,n.key,n)}}function h(e,t,r){return t&&c(e.prototype,t),r&&c(e,r),e}var f=function(){function e(t,r){l(this,e),this.url=t,r=r||{},this.isHttp=/^https?:/i.test(t),this.httpHeaders=this.isHttp&&r.httpHeaders||{},this.withCredentials=r.withCredentials||!1,this.getXhr=r.getXhr||function(){return new XMLHttpRequest},this.currXhrId=0,this.pendingRequests=Object.create(null)}return h(e,[{key:"requestRange",value:function(e,t,r){var n,i={begin:e,end:t};for(n in r)i[n]=r[n];return this.request(i)}},{key:"requestFull",value:function(e){return this.request(e)}},{key:"request",value:function(e){var t,r=this.getXhr(),n=this.currXhrId++,i=this.pendingRequests[n]={xhr:r};for(t in r.open("GET",this.url),r.withCredentials=this.withCredentials,this.httpHeaders){var a=this.httpHeaders[t];void 0!==a&&r.setRequestHeader(t,a)}return this.isHttp&&"begin"in e&&"end"in e?(r.setRequestHeader("Range","bytes=".concat(e.begin,"-").concat(e.end-1)),i.expectedStatus=206):i.expectedStatus=200,r.responseType="arraybuffer",e.onError&&(r.onerror=function(t){e.onError(r.status)}),r.onreadystatechange=this.onStateChange.bind(this,n),r.onprogress=this.onProgress.bind(this,n),i.onHeadersReceived=e.onHeadersReceived,i.onDone=e.onDone,i.onError=e.onError,i.onProgress=e.onProgress,r.send(null),n}},{key:"onProgress",value:function(e,t){e=this.pendingRequests[e],e&&e.onProgress&&e.onProgress(t)}},{key:"onStateChange",value:function(e,t){var r,n,i=this.pendingRequests[e];i&&(2<=(r=i.xhr).readyState&&i.onHeadersReceived&&(i.onHeadersReceived(),delete i.onHeadersReceived),4===r.readyState&&e in this.pendingRequests&&(delete this.pendingRequests[e],0===r.status&&this.isHttp||(200!==(n=r.status||200)||206!==i.expectedStatus)&&n!==i.expectedStatus?i.onError&&i.onError(r.status):(e="string"!=typeof(e=(e=r).response)?e:(0,a.stringToBytes)(e).buffer,206===n?(n=r.getResponseHeader("Content-Range"),n=/bytes (\d+)-(\d+)\/(\d+)/.exec(n),i.onDone({begin:parseInt(n[1],10),chunk:e})):e?i.onDone({begin:0,chunk:e}):i.onError&&i.onError(r.status))))}},{key:"getRequestXhr",value:function(e){return this.pendingRequests[e].xhr}},{key:"isPendingRequest",value:function(e){return e in this.pendingRequests}},{key:"abortRequest",value:function(e){var t=this.pendingRequests[e].xhr;delete this.pendingRequests[e],t.abort()}}]),e}();t.PDFNetworkStream=function(){function e(t){l(this,e),this._source=t,this._manager=new f(t.url,{httpHeaders:t.httpHeaders,withCredentials:t.withCredentials}),this._rangeChunkSize=t.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}return h(e,[{key:"_onRangeRequestReaderClosed",value:function(e){e=this._rangeRequestReaders.indexOf(e),0<=e&&this._rangeRequestReaders.splice(e,1)}},{key:"getFullReader",value:function(){return(0,a.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new d(this._manager,this._source),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){return t=new p(this._manager,e,t),t.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(t),t}},{key:"cancelAllRequests",value:function(e){this._fullRequestReader&&this._fullRequestReader.cancel(e),this._rangeRequestReaders.slice(0).forEach((function(t){t.cancel(e)}))}}]),e}();var d=function(){function e(t,r){l(this,e),this._manager=t;var n={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=r.url,this._fullRequestId=t.requestFull(n),this._headersReceivedCapability=(0,a.createPromiseCapability)(),this._disableRange=r.disableRange||!1,this._contentLength=r.length,this._rangeChunkSize=r.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),this._isStreamingSupported=!1,this._isRangeSupported=!1,this._cachedChunks=[],this._requests=[],this._done=!1,this._storedError=void 0,this._filename=null,this.onProgress=null}var t;return h(e,[{key:"_onHeadersReceived",value:function(){function e(e){return r.getResponseHeader(e)}var t=this._fullRequestId,r=this._manager.getRequestXhr(t),n=(0,o.validateRangeRequestCapabilities)({getResponseHeader:e,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange}),i=n.allowRangeRequests;n=n.suggestedLength;i&&(this._isRangeSupported=!0),this._contentLength=n||this._contentLength,this._filename=(0,o.extractFilenameFromHeader)(e),this._isRangeSupported&&this._manager.abortRequest(t),this._headersReceivedCapability.resolve()}},{key:"_onDone",value:function(e){e&&(0<this._requests.length?this._requests.shift().resolve({value:e.chunk,done:!1}):this._cachedChunks.push(e.chunk)),this._done=!0,0<this._cachedChunks.length||(this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[])}},{key:"_onError",value:function(e){var t=this._url,r=(0,o.createResponseStatusError)(e,t);this._storedError=r,this._headersReceivedCapability.reject(r),this._requests.forEach((function(e){e.reject(r)})),this._requests=[],this._cachedChunks=[]}},{key:"_onProgress",value:function(e){this.onProgress&&this.onProgress({loaded:e.loaded,total:e.lengthComputable?e.total:this._contentLength})}},{key:"read",value:(t=u(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this._storedError)throw this._storedError;e.next=2;break;case 2:if(0<this._cachedChunks.length)return t=this._cachedChunks.shift(),e.abrupt("return",{value:t,done:!1});e.next=5;break;case 5:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=7;break;case 7:return t=(0,a.createPromiseCapability)(),this._requests.push(t),e.abrupt("return",t.promise);case 10:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._done=!0,this._headersReceivedCapability.reject(e),this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[],this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}},{key:"filename",get:function(){return this._filename}},{key:"isRangeSupported",get:function(){return this._isRangeSupported}},{key:"isStreamingSupported",get:function(){return this._isStreamingSupported}},{key:"contentLength",get:function(){return this._contentLength}},{key:"headersReady",get:function(){return this._headersReceivedCapability.promise}}]),e}(),p=function(){function e(t,r,n){l(this,e),this._manager=t;var i={onDone:this._onDone.bind(this),onProgress:this._onProgress.bind(this)};this._requestId=t.requestRange(r,n,i),this._requests=[],this._queuedChunk=null,this._done=!1,this.onProgress=null,this.onClosed=null}var t;return h(e,[{key:"_close",value:function(){this.onClosed&&this.onClosed(this)}},{key:"_onDone",value:function(e){e=e.chunk,0<this._requests.length?this._requests.shift().resolve({value:e,done:!1}):this._queuedChunk=e,this._done=!0,this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[],this._close()}},{key:"_onProgress",value:function(e){!this.isStreamingSupported&&this.onProgress&&this.onProgress({loaded:e.loaded})}},{key:"read",value:(t=u(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!==this._queuedChunk)return t=this._queuedChunk,this._queuedChunk=null,e.abrupt("return",{value:t,done:!1});e.next=4;break;case 4:if(this._done)return e.abrupt("return",{value:void 0,done:!0});e.next=6;break;case 6:return t=(0,a.createPromiseCapability)(),this._requests.push(t),e.abrupt("return",t.promise);case 9:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._done=!0,this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[],this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}},{key:"isStreamingSupported",get:function(){return!1}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFFetchStream=void 0;var n,i=(n=r(2))&&n.__esModule?n:{default:n},a=r(5),o=r(220);function s(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function u(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){s(a,n,i,o,u,"next",e)}function u(e){s(a,n,i,o,u,"throw",e)}o(void 0)}))}}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(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,n.key,n)}}function h(e,t,r){return t&&c(e.prototype,t),r&&c(e,r),e}function f(e,t,r){return{method:"GET",headers:e,signal:r&&r.signal,mode:"cors",credentials:t?"include":"same-origin",redirect:"follow"}}function d(e){var t,r=new Headers;for(t in e){var n=e[t];void 0!==n&&r.append(t,n)}return r}t.PDFFetchStream=function(){function e(t){l(this,e),this.source=t,this.isHttp=/^https?:/i.test(t.url),this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}return h(e,[{key:"getFullReader",value:function(){return(0,a.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new p(this),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){return t<=this._progressiveDataLength?null:(t=new v(this,e,t),this._rangeRequestReaders.push(t),t)}},{key:"cancelAllRequests",value:function(e){this._fullRequestReader&&this._fullRequestReader.cancel(e),this._rangeRequestReaders.slice(0).forEach((function(t){t.cancel(e)}))}},{key:"_progressiveDataLength",get:function(){return this._fullRequestReader?this._fullRequestReader._loaded:0}}]),e}();var p=function(){function e(t){var r=this;l(this,e),this._stream=t,this._reader=null,this._loaded=0,this._filename=null,t=t.source,this._withCredentials=t.withCredentials||!1,this._contentLength=t.length,this._headersCapability=(0,a.createPromiseCapability)(),this._disableRange=t.disableRange||!1,this._rangeChunkSize=t.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._headers=d(this._stream.httpHeaders);var n=t.url;fetch(n,f(this._headers,this._withCredentials,this._abortController)).then((function(e){if(!(0,o.validateResponseStatus)(e.status))throw(0,o.createResponseStatusError)(e.status,n);function t(t){return e.headers.get(t)}r._reader=e.body.getReader(),r._headersCapability.resolve();var i=(0,o.validateRangeRequestCapabilities)({getResponseHeader:t,isHttp:r._stream.isHttp,rangeChunkSize:r._rangeChunkSize,disableRange:r._disableRange}),s=i.allowRangeRequests;i=i.suggestedLength;r._isRangeSupported=s,r._contentLength=i||r._contentLength,r._filename=(0,o.extractFilenameFromHeader)(t),!r._isStreamingSupported&&r._isRangeSupported&&r.cancel(new a.AbortException("Streaming is disabled."))})).catch(this._headersCapability.reject),this.onProgress=null}var t;return h(e,[{key:"read",value:(t=u(i.default.mark((function e(){var t,r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._headersCapability.promise;case 2:return e.next=4,this._reader.read();case 4:if(r=e.sent,t=r.value,r=r.done)return e.abrupt("return",{value:t,done:r});e.next=9;break;case 9:return this._loaded+=t.byteLength,this.onProgress&&this.onProgress({loaded:this._loaded,total:this._contentLength}),r=new Uint8Array(t).buffer,e.abrupt("return",{value:r,done:!1});case 13:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._reader&&this._reader.cancel(e),this._abortController&&this._abortController.abort()}},{key:"headersReady",get:function(){return this._headersCapability.promise}},{key:"filename",get:function(){return this._filename}},{key:"contentLength",get:function(){return this._contentLength}},{key:"isRangeSupported",get:function(){return this._isRangeSupported}},{key:"isStreamingSupported",get:function(){return this._isStreamingSupported}}]),e}(),v=function(){function e(t,r,n){var i=this;l(this,e),this._stream=t,this._reader=null,this._loaded=0,t=t.source,this._withCredentials=t.withCredentials||!1,this._readCapability=(0,a.createPromiseCapability)(),this._isStreamingSupported=!t.disableStream,"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._headers=d(this._stream.httpHeaders),this._headers.append("Range","bytes=".concat(r,"-").concat(n-1));var s=t.url;fetch(s,f(this._headers,this._withCredentials,this._abortController)).then((function(e){if(!(0,o.validateResponseStatus)(e.status))throw(0,o.createResponseStatusError)(e.status,s);i._readCapability.resolve(),i._reader=e.body.getReader()})).catch((function(e){if(!e||"AbortError"!==e.name)throw e})),this.onProgress=null}var t;return h(e,[{key:"read",value:(t=u(i.default.mark((function e(){var t,r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._readCapability.promise;case 2:return e.next=4,this._reader.read();case 4:if(r=e.sent,t=r.value,r=r.done)return e.abrupt("return",{value:t,done:r});e.next=9;break;case 9:return this._loaded+=t.byteLength,this.onProgress&&this.onProgress({loaded:this._loaded}),r=new Uint8Array(t).buffer,e.abrupt("return",{value:r,done:!1});case 13:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})},{key:"cancel",value:function(e){this._reader&&this._reader.cancel(e),this._abortController&&this._abortController.abort()}},{key:"isStreamingSupported",get:function(){return this._isStreamingSupported}}]),e}()}],r={},s.m=q,s.c=r,s.d=function(e,t,r){s.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},s.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},s.t=function(e,t){if(1&t&&(e=s(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(s.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)s.d(r,n,function(t){return e[t]}.bind(null,n));return r},s.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return s.d(t,"a",t),t},s.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},s.p="",s(s.s=0);function s(e){if(r[e])return r[e].exports;var t=r[e]={i:e,l:!1,exports:{}};return q[e].call(t.exports,t,t.exports,s),t.l=!0,t.exports}var q,r},module.exports=p()}).call(this,__webpack_require__("b639").Buffer,__webpack_require__("4362"),__webpack_require__("c8ba"))},"4b09":function(e,t,r){},"6f53":function(e,t,r){var n=r("83ab"),i=r("df75"),a=r("fc6a"),o=r("d1e7").f;r=function(e){return function(t){for(var r,s=a(t),u=i(s),l=u.length,c=0,h=[];c<l;)r=u[c++],n&&!o.call(s,r)||h.push(e?[r,s[r]]:s[r]);return h}};e.exports={entries:r(!0),values:r(!1)}},"858e":function(e,t,r){"use strict";var n,i,a={props:{initial:{type:Boolean,default:!1}},data:function(){return{size:{width:-1,height:-1}}},methods:{reset:function(){var e=this.$el.firstChild,t=this.$el.lastChild;e.scrollLeft=1e5,e.scrollTop=1e5,t.scrollLeft=1e5,t.scrollTop=1e5},update:function(){this.size.width=this.$el.offsetWidth,this.size.height=this.$el.offsetHeight}},watch:{size:{deep:!0,handler:function(e){this.reset(),this.$emit("resize",{width:this.size.width,height:this.size.height})}}},render:function(e){var t="position: absolute; left: 0; top: 0; right: 0; bottom: 0; overflow: hidden; z-index: -1; visibility: hidden;",r="position: absolute; left: 0; top: 0;";return e("div",{style:t+"animation-name: resizeSensorVisibility;",on:{"~animationstart":this.update}},[e("div",{style:t,on:{scroll:this.update}},[e("div",{style:r+"width: 100000px; height: 100000px;"})]),e("div",{style:t,on:{scroll:this.update}},[e("div",{style:r+"width: 200%; height: 200%;"})])])},beforeDestroy:function(){this.$emit("resize",{width:0,height:0}),this.$emit("resizeSensorBeforeDestroy")},mounted:function(){var e,t;!0===this.initial&&this.$nextTick(this.update),this.$el.offsetParent!==this.$el.parentNode&&(this.$el.parentNode.style.position="relative"),"attachEvent"in this.$el&&!("AnimationEvent"in window)&&(e=function(){this.update(),t()}.bind(this),t=function(){this.$el.detachEvent("onresize",e),this.$off("resizeSensorBeforeDestroy",t)}.bind(this),this.$el.attachEvent("onresize",e),this.$on("resizeSensorBeforeDestroy",t),this.reset())}},o=(r("c0ef"),r("2877")),s=Object(o.a)(a,void 0,void 0,!1,null,null,null).exports,u=function(e){var t=e.createLoadingTask,r=e.PDFJSWrapper;return{createLoadingTask:t,render:function(e){return e("span",{attrs:{style:"position: relative; display: block"}},[e("canvas",{attrs:{style:"display: inline-block; width: 100%; height: 100%; vertical-align: top"},ref:"canvas"}),e("span",{style:"display: inline-block; width: 100%; height: 100%",class:"annotationLayer",ref:"annotationLayer"}),e(s,{props:{initial:!0},on:{resize:this.resize}})])},props:{src:{type:[String,Object,Uint8Array],default:""},page:{type:Number,default:1},rotate:{type:Number}},watch:{src:function(){this.pdf.loadDocument(this.src)},page:function(){this.pdf.loadPage(this.page,this.rotate)},rotate:function(){this.pdf.renderPage(this.rotate)}},methods:{resize:function(e){null===this.$el.parentNode||0===e.width&&0===e.height||(this.$refs.canvas.style.height=this.$refs.canvas.offsetWidth*(this.$refs.canvas.height/this.$refs.canvas.width)+"px",((e=this.pdf.getResolutionScale())<.85||1.15<e)&&this.pdf.renderPage(this.rotate))},print:function(e,t){this.pdf.printPage(e,t)}},mounted:function(){this.pdf=new r(this.$refs.canvas,this.$refs.annotationLayer,this.$emit.bind(this)),this.$on("loaded",(function(){this.pdf.loadPage(this.page,this.rotate)})),this.$on("page-size",(function(e,t){this.$refs.canvas.style.height=this.$refs.canvas.offsetWidth*(t/e)+"px"})),this.pdf.loadDocument(this.src)},destroyed:function(){this.pdf.destroy()}}};u="server"!==Object({NODE_ENV:"production",BASE_URL:"/"}).VUE_ENV?(n=r("a068").default,i=r("4383"),"undefined"!=typeof window&&"Worker"in window&&-1===navigator.appVersion.indexOf("MSIE 10")&&(a=r("2639"),i.GlobalWorkerOptions.workerPort=new a),u(n(i))):u({}),r("f9a3"),u=Object(o.a)(u,void 0,void 0,!1,null,null,null);t.a=u.exports},a068:function(e,t,r){"use strict";r.r(t);var n=r("f8db"),i=Promise.resolve();t.default=function(e){function t(t,r){if("string"==typeof t)n={url:t};else if(t instanceof Uint8Array)n={data:t};else{if("object"!=typeof t||null===t)throw new TypeError("invalid src type");n=Object.assign({},t)}r&&r.withCredentials&&(n.withCredentials=r.withCredentials);var n=e.getDocument(n);return n.__PDFDocumentLoadingTask=!0,r&&r.onPassword&&(n.onPassword=r.onPassword),r&&r.onProgress&&(n.onProgress=r.onProgress),n}return{createLoadingTask:t,PDFJSWrapper:function(r,a,o){var s=null,u=null,l=null,c=!1;function h(){r.getContext("2d").clearRect(0,0,r.width,r.height)}function f(){for(;a.firstChild;)a.removeChild(a.firstChild)}r.getContext("2d").save(),this.destroy=function(){null!==s&&(i=s.destroy(),s=null)},this.getResolutionScale=function(){return r.offsetWidth/r.width},this.printPage=function(e,t){var r,n;function i(){n.parentNode.removeChild(n)}null!==u&&(r=(void 0===e?150:e)/72,n=document.createElement("iframe"),new Promise((function(e,t){n.frameBorder="0",n.scrolling="no",n.width="0px;",n.height="0px;",n.style.cssText="position: absolute; top: 0; left: 0",n.onload=function(){e(this.contentWindow)},window.document.body.appendChild(n)})).then((function(e){return e.document.title="",s.getPage(1).then((function(t){return t=t.getViewport({scale:1}),e.document.head.appendChild(e.document.createElement("style")).textContent="@supports ((size:A4) and (size:1pt 1pt)) {@page { margin: 1pt; size: "+t.width*r/(96/72)+"pt "+t.height*r/(96/72)+"pt; }}@media print {body { margin: 0 }canvas { page-break-before: avoid; page-break-after: always; page-break-inside: avoid }}@media screen {body { margin: 0 }}",e}))})).then((function(e){for(var n=[],a=1;a<=s.numPages;++a)void 0!==t&&-1===t.indexOf(a)||n.push(s.getPage(a).then((function(t){var n=t.getViewport({scale:1}),i=e.document.body.appendChild(e.document.createElement("canvas"));return i.width=n.width*r,i.height=n.height*r,t.render({canvasContext:i.getContext("2d"),transform:[r,0,0,r,0,0],viewport:n,intent:"print"}).promise})));Promise.all(n).then((function(){e.focus(),e.document.queryCommandSupported("print")?e.document.execCommand("print",!1,null):e.print(),i()})).catch((function(e){i(),o("error",e)}))})))},this.renderPage=function(t){if(null!==l)return c?void 0:(c=!0,void l.cancel().catch((function(e){o("error",e)})));var h,d,p,v;null!==u&&(h=(void 0===u.rotate?0:u.rotate)+(void 0===t?0:t),p=r.offsetWidth/u.getViewport({scale:1}).width*(window.devicePixelRatio||1),d=u.getViewport({scale:p,rotation:h}),o("page-size",d.width,d.height,p),r.width=d.width,r.height=d.height,l=u.render({canvasContext:r.getContext("2d"),viewport:d}),a.style.visibility="hidden",f(),p={scrollPageIntoView:function(e){o("link-clicked",e.pageNumber)}},(v=new n.PDFLinkService).setDocument(s),v.setViewer(p),i=i.then(function(){var r=u.getAnnotations({intent:"display"}).then((function(t){e.AnnotationLayer.render({viewport:d.clone({dontFlip:!0}),div:a,annotations:t,page:u,linkService:v,renderInteractiveForms:!1})})),n=l.promise.then((function(){a.style.visibility="",c=!1,l=null})).catch(function(r){if(l=null,r instanceof e.RenderingCancelledException)return c=!1,void this.renderPage(t);o("error",r)}.bind(this));return Promise.all([r,n])}.bind(this)))},this.forEachPage=function(e){var t=s.numPages;!function r(n){s.getPage(n).then(e).then((function(){++n<=t&&r(n)}))}(1)},this.loadPage=function(e,t){(u=null)!==s&&(i=i.then((function(){return s.getPage(e)})).then(function(e){u=e,this.renderPage(t),o("page-loaded",e.pageNumber)}.bind(this)).catch((function(e){h(),f(),o("error",e)})))},this.loadDocument=function(n){if(u=s=null,o("num-pages",void 0),!n)return r.removeAttribute("width"),r.removeAttribute("height"),void f();i=i.then((function(){var r,i;if("object"==typeof(i=n)&&null!==i&&!0===i.__PDFDocumentLoadingTask){if(n.destroyed)return void o("error",new Error("loadingTask has been destroyed"));r=n}else r=t(n,{onPassword:function(t,r){var n;switch(r){case e.PasswordResponses.NEED_PASSWORD:n="NEED_PASSWORD";break;case e.PasswordResponses.INCORRECT_PASSWORD:n="INCORRECT_PASSWORD"}o("password",t,n)},onProgress:function(e){e=e.loaded/e.total,o("progress",Math.min(e,1))}});return r.promise})).then((function(e){o("num-pages",(s=e).numPages),o("loaded")})).catch((function(e){h(),f(),o("error",e)}))},a.style.transformOrigin="0 0"}}}},c0ef:function(e,t,r){"use strict";r("4b09")},ec1b:function(e,t,r){e.exports=function(e){function t(n){if(r[n])return r[n].exports;var i=r[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="/dist/",t(t.s=2)}([function(e,t,r){r=r(4)(r(1),r(5),null,null),e.exports=r.exports},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3);t.default={props:{startVal:{type:Number,required:!1,default:0},endVal:{type:Number,required:!1,default:2017},duration:{type:Number,required:!1,default:3e3},autoplay:{type:Boolean,required:!1,default:!0},decimals:{type:Number,required:!1,default:0,validator:function(e){return 0<=e}},decimal:{type:String,required:!1,default:"."},separator:{type:String,required:!1,default:","},prefix:{type:String,required:!1,default:""},suffix:{type:String,required:!1,default:""},useEasing:{type:Boolean,required:!1,default:!0},easingFn:{type:Function,default:function(e,t,r,n){return r*(1-Math.pow(2,-10*e/n))*1024/1023+t}}},data:function(){return{localStartVal:this.startVal,displayValue:this.formatNumber(this.startVal),printVal:null,paused:!1,localDuration:this.duration,startTime:null,timestamp:null,remaining:null,rAF:null}},computed:{countDown:function(){return this.startVal>this.endVal}},watch:{startVal:function(){this.autoplay&&this.start()},endVal:function(){this.autoplay&&this.start()}},mounted:function(){this.autoplay&&this.start(),this.$emit("mountedCallback")},methods:{start:function(){this.localStartVal=this.startVal,this.startTime=null,this.localDuration=this.duration,this.paused=!1,this.rAF=(0,n.requestAnimationFrame)(this.count)},pauseResume:function(){this.paused?(this.resume(),this.paused=!1):(this.pause(),this.paused=!0)},pause:function(){(0,n.cancelAnimationFrame)(this.rAF)},resume:function(){this.startTime=null,this.localDuration=+this.remaining,this.localStartVal=+this.printVal,(0,n.requestAnimationFrame)(this.count)},reset:function(){(this.startTime=null,n.cancelAnimationFrame)(this.rAF),this.displayValue=this.formatNumber(this.startVal)},count:function(e){this.startTime||(this.startTime=e),e=(this.timestamp=e)-this.startTime,this.remaining=this.localDuration-e,this.useEasing?this.countDown?this.printVal=this.localStartVal-this.easingFn(e,0,this.localStartVal-this.endVal,this.localDuration):this.printVal=this.easingFn(e,this.localStartVal,this.endVal-this.localStartVal,this.localDuration):this.countDown?this.printVal=this.localStartVal-(this.localStartVal-this.endVal)*(e/this.localDuration):this.printVal=this.localStartVal+(this.localStartVal-this.startVal)*(e/this.localDuration),this.countDown?this.printVal=this.printVal<this.endVal?this.endVal:this.printVal:this.printVal=this.printVal>this.endVal?this.endVal:this.printVal,this.displayValue=this.formatNumber(this.printVal),e<this.localDuration?this.rAF=(0,n.requestAnimationFrame)(this.count):this.$emit("callback")},isNumber:function(e){return!isNaN(parseFloat(e))},formatNumber:function(e){e=e.toFixed(this.decimals);e=(e+="").split(".");var t=e[0],r=(e=1<e.length?this.decimal+e[1]:"",/(\d+)(\d{3})/);if(this.separator&&!this.isNumber(this.separator))for(;r.test(t);)t=t.replace(r,"$1"+this.separator+"$2");return this.prefix+t+e+this.suffix}},destroyed:function(){(0,n.cancelAnimationFrame)(this.rAF)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),r=r(0),r=r&&r.__esModule?r:{default:r},t.default=r.default,"undefined"!=typeof window&&window.Vue&&window.Vue.component("count-to",r.default)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=0,i="webkit moz ms o".split(" "),a=void 0,o=void 0;if("undefined"==typeof window)t.requestAnimationFrame=a=function(){},t.cancelAnimationFrame=o=function(){};else{t.requestAnimationFrame=a=window.requestAnimationFrame,t.cancelAnimationFrame=o=window.cancelAnimationFrame;for(var s,u=0;u<i.length&&(!a||!o);u++)s=i[u],t.requestAnimationFrame=a=a||window[s+"RequestAnimationFrame"],t.cancelAnimationFrame=o=o||window[s+"CancelAnimationFrame"]||window[s+"CancelRequestAnimationFrame"];a&&o||(t.requestAnimationFrame=a=function(e){var t=(new Date).getTime(),r=Math.max(0,16-(t-n)),i=window.setTimeout((function(){e(t+r)}),r);return n=t+r,i},t.cancelAnimationFrame=o=function(e){window.clearTimeout(e)})}t.requestAnimationFrame=a,t.cancelAnimationFrame=o},function(e,t){e.exports=function(e,t,r,n){var i,a,o=e=e||{},s=typeof e.default;e="function"==typeof(o="object"==s||"function"==s?(i=e).default:o)?o.options:o;return t&&(e.render=t.render,e.staticRenderFns=t.staticRenderFns),r&&(e._scopeId=r),n&&(a=Object.create(e.computed||null),Object.keys(n).forEach((function(e){var t=n[e];a[e]=function(){return t}})),e.computed=a),{esModule:i,exports:o,options:e}}},function(e,t){e.exports={render:function(){var e=this.$createElement;return(this._self._c||e)("span",[this._v("\n "+this._s(this.displayValue)+"\n")])},staticRenderFns:[]}}])},f8db:function(e,t,r){
  24. /**
  25. * @licstart The following is the entire license notice for the
  26. * Javascript code in this page
  27. *
  28. * Copyright 2020 Mozilla Foundation
  29. *
  30. * Licensed under the Apache License, Version 2.0 (the "License");
  31. * you may not use this file except in compliance with the License.
  32. * You may obtain a copy of the License at
  33. *
  34. * http://www.apache.org/licenses/LICENSE-2.0
  35. *
  36. * Unless required by applicable law or agreed to in writing, software
  37. * distributed under the License is distributed on an "AS IS" BASIS,
  38. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  39. * See the License for the specific language governing permissions and
  40. * limitations under the License.
  41. *
  42. * @licend The above is the entire license notice for the
  43. * Javascript code in this page
  44. */
  45. var n;n=function(){return n={},e.m=t=[function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AnnotationLayerBuilder",{enumerable:!0,get:function(){return n.AnnotationLayerBuilder}}),Object.defineProperty(t,"DefaultAnnotationLayerFactory",{enumerable:!0,get:function(){return n.DefaultAnnotationLayerFactory}}),Object.defineProperty(t,"DefaultTextLayerFactory",{enumerable:!0,get:function(){return i.DefaultTextLayerFactory}}),Object.defineProperty(t,"TextLayerBuilder",{enumerable:!0,get:function(){return i.TextLayerBuilder}}),Object.defineProperty(t,"EventBus",{enumerable:!0,get:function(){return a.EventBus}}),Object.defineProperty(t,"NullL10n",{enumerable:!0,get:function(){return a.NullL10n}}),Object.defineProperty(t,"ProgressBar",{enumerable:!0,get:function(){return a.ProgressBar}}),Object.defineProperty(t,"PDFLinkService",{enumerable:!0,get:function(){return o.PDFLinkService}}),Object.defineProperty(t,"SimpleLinkService",{enumerable:!0,get:function(){return o.SimpleLinkService}}),Object.defineProperty(t,"DownloadManager",{enumerable:!0,get:function(){return s.DownloadManager}}),Object.defineProperty(t,"GenericL10n",{enumerable:!0,get:function(){return u.GenericL10n}}),Object.defineProperty(t,"PDFFindController",{enumerable:!0,get:function(){return l.PDFFindController}}),Object.defineProperty(t,"PDFHistory",{enumerable:!0,get:function(){return c.PDFHistory}}),Object.defineProperty(t,"PDFPageView",{enumerable:!0,get:function(){return h.PDFPageView}}),Object.defineProperty(t,"PDFSinglePageViewer",{enumerable:!0,get:function(){return f.PDFSinglePageViewer}}),Object.defineProperty(t,"PDFViewer",{enumerable:!0,get:function(){return d.PDFViewer}});var n=r(1),i=r(8),a=r(3),o=r(7),s=r(9),u=r(11),l=r(13),c=r(15),h=r(16),f=r(18),d=r(20)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultAnnotationLayerFactory=t.AnnotationLayerBuilder=void 0;var n=r(2),i=r(3),a=r(7);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(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,n.key,n)}}function u(e,t,r){return t&&s(e.prototype,t),r&&s(e,r),e}var l=function(){function e(t){var r=t.pageDiv,n=t.pdfPage,a=t.linkService,s=t.downloadManager,u=t.annotationStorage,l=void 0===u?null:u,c=t.imageResourcesPath;u=void 0===c?"":c,c=t.renderInteractiveForms,c=void 0===c||c,t=t.l10n,t=void 0===t?i.NullL10n:t;o(this,e),this.pageDiv=r,this.pdfPage=n,this.linkService=a,this.downloadManager=s,this.imageResourcesPath=u,this.renderInteractiveForms=c,this.l10n=t,this.annotationStorage=l,this.div=null,this._cancelled=!1}return u(e,[{key:"render",value:function(e){var t=this;return this.pdfPage.getAnnotations({intent:1<arguments.length&&void 0!==arguments[1]?arguments[1]:"display"}).then((function(r){t._cancelled||0!==r.length&&(r={viewport:e.clone({dontFlip:!0}),div:t.div,annotations:r,page:t.pdfPage,imageResourcesPath:t.imageResourcesPath,renderInteractiveForms:t.renderInteractiveForms,linkService:t.linkService,downloadManager:t.downloadManager,annotationStorage:t.annotationStorage},t.div?n.AnnotationLayer.update(r):(t.div=document.createElement("div"),t.div.className="annotationLayer",t.pageDiv.appendChild(t.div),r.div=t.div,n.AnnotationLayer.render(r),t.l10n.translate(t.div)))}))}},{key:"cancel",value:function(){this._cancelled=!0}},{key:"hide",value:function(){this.div&&this.div.setAttribute("hidden","true")}}]),e}();t.AnnotationLayerBuilder=l,t.DefaultAnnotationLayerFactory=function(){function e(){o(this,e)}return u(e,[{key:"createAnnotationLayerBuilder",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]:"",o=!(4<arguments.length&&void 0!==arguments[4])||arguments[4],s=5<arguments.length&&void 0!==arguments[5]?arguments[5]:i.NullL10n;return new l({pageDiv:e,pdfPage:t,imageResourcesPath:n,renderInteractiveForms:o,linkService:new a.SimpleLinkService,l10n:s,annotationStorage:r})}}]),e}()},function(e,t,n){"use strict";var i="undefined"!=typeof window&&window["pdfjs-dist/build/pdf"]?window["pdfjs-dist/build/pdf"]:r("4383");e.exports=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isValidRotation=function(e){return Number.isInteger(e)&&e%90==0},t.isValidScrollMode=function(e){return Number.isInteger(e)&&Object.values(f).includes(e)&&e!==f.UNKNOWN},t.isValidSpreadMode=function(e){return Number.isInteger(e)&&Object.values(d).includes(e)&&e!==d.UNKNOWN},t.isPortraitOrientation=function(e){return e.width<=e.height},t.clamp=_,t.getPDFFileNameFromURL=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"document.pdf";if("string"!=typeof e)return t;if(function(e){for(var t=0,r=e.length;t<r&&""===e[t].trim();)t++;return"data:"===e.substring(t,t+5).toLowerCase()}(e))return t;var r=/[^\/?#=]+\.pdf\b(?!.*\.pdf\b)/i;e=/^(?:(?:[^:]+:)?\/\/[^\/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/.exec(e),e=r.exec(e[1])||r.exec(e[2])||r.exec(e[3]);if(e&&(e=e[0]).includes("%"))try{e=r.exec(decodeURIComponent(e))[0]}catch(e){}return e||t},t.noContextMenuHandler=function(e){e.preventDefault()},t.parseQueryString=function(e){for(var t=e.split("&"),r=Object.create(null),n=0,i=t.length;n<i;++n){var a=t[n].split("="),o=a[0].toLowerCase();a=1<a.length?a[1]:null;r[decodeURIComponent(o)]=decodeURIComponent(a)}return r},t.backtrackBeforeAllVisibleElements=v,t.getVisibleElements=function(e,t){var r=2<arguments.length&&void 0!==arguments[2]&&arguments[2],n=3<arguments.length&&void 0!==arguments[3]&&arguments[3],i=e.scrollTop,a=i+e.clientHeight,o=e.scrollLeft,s=o+e.clientWidth,u=[],l=t.length,c=0===l?0:p(t,n?function(e){return e=(e=e.div).offsetLeft+e.clientLeft+e.clientWidth,o<e}:function(e){return e=(e=e.div).offsetTop+e.clientTop+e.clientHeight,i<e});0<c&&c<l&&!n&&(c=v(c,t,i));for(var h=n?s:-1,f=c;f<l;f++){var d=t[f],g=d.div,y=g.offsetLeft+g.clientLeft,m=g.offsetTop+g.clientTop,b=g.clientWidth,_=g.clientHeight,w=y+b;g=m+_;if(-1===h)a<=g&&(h=g);else if(h<(n?y:m))break;g<=i||a<=m||w<=o||s<=y||(g=Math.max(0,i-m)+Math.max(0,g-a),w=Math.max(0,o-y)+Math.max(0,w-s),b=(_-g)*(b-w)*100/_/b|0,u.push({id:d.id,x:y,y:m,view:d,percent:b}))}return e=u[0],c=u[u.length-1],r&&u.sort((function(e,t){var r=e.percent-t.percent;return.001<Math.abs(r)?-r:e.id-t.id})),{first:e,last:c,views:u}},t.roundToDivide=function(e,t){var r=e%t;return 0==r?e:Math.round(e-r+t)},t.getPageSizeInches=function(e){var t=e.view,r=e.userUnit,n=e.rotate,i=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}(e,t)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(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.")}()}(t,4),a=i[0];e=i[1],t=i[2],i=i[3],n=n%180!=0,a=(t-a)/72*r,r*=(i-e)/72;return{width:n?r:a,height:n?a:r}},t.approximateFraction=function(e){if(Math.floor(e)===e)return[e,1];var t=1/e;if(8<t)return[1,8];if(Math.floor(t)===t)return[1,t];for(var r=1<e?t:e,n=0,i=1,a=1,o=1;;){var s=n+a,u=i+o;if(8<u)break;r<=s/u?(a=s,o=u):(n=s,i=u)}return e=r-n/i<a/o-r?r===e?[n,i]:[i,n]:r===e?[a,o]:[o,a],e},t.getOutputScale=function(e){var t=window.devicePixelRatio||1;e=e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1,e=t/e;return{sx:e,sy:e,scaled:1!=e}},t.scrollIntoView=function(e,t){var r=2<arguments.length&&void 0!==arguments[2]&&arguments[2],n=e.offsetParent;if(n){for(var i=e.offsetTop+e.clientTop,a=e.offsetLeft+e.clientLeft;n.clientHeight===n.scrollHeight&&n.clientWidth===n.scrollWidth||r&&"hidden"===getComputedStyle(n).overflow;)if(n.dataset._scaleY&&(i/=n.dataset._scaleY,a/=n.dataset._scaleX),i+=n.offsetTop,a+=n.offsetLeft,!(n=n.offsetParent))return;t&&(void 0!==t.top&&(i+=t.top),void 0!==t.left&&(a+=t.left,n.scrollLeft=a)),n.scrollTop=i}},t.watchScroll=function(e,t){function r(r){i=i||window.requestAnimationFrame((function(){i=null;var r=e.scrollLeft,a=n.lastX;r!==a&&(n.right=a<r),n.lastX=r,a=e.scrollTop,r=n.lastY,a!==r&&(n.down=r<a),n.lastY=a,t(n)}))}var n={right:!0,down:!0,lastX:e.scrollLeft,lastY:e.scrollTop,_eventHandler:r},i=null;return e.addEventListener("scroll",r,!0),n},t.binarySearchFirstItem=p,t.normalizeWheelEventDirection=g,t.normalizeWheelEventDelta=function(e){var t=g(e);return 0===e.deltaMode?t/=900:1===e.deltaMode&&(t/=30),t},t.waitOnEventOrTimeout=function(e){var t=e.target,r=e.name,n=(e=e.delay,void 0===e?0:e);return new Promise((function(e,i){if("object"!==u(t)||!r||"string"!=typeof r||!(Number.isInteger(n)&&0<=n))throw new Error("waitOnEventOrTimeout - invalid parameters.");function a(n){t instanceof b?t._off(r,o):t.removeEventListener(r,o),l&&clearTimeout(l),e(n)}var o=a.bind(null,y.EVENT);t instanceof b?t._on(r,o):t.addEventListener(r,o);var s=a.bind(null,y.TIMEOUT),l=setTimeout(s,n)}))},t.moveToEndOfArray=function(e,t){for(var r=[],n=e.length,i=0,a=0;a<n;++a)t(e[a])?r.push(e[a]):(e[i]=e[a],++i);for(var o=0;i<n;++o,++i)e[i]=r[o]},t.WaitOnType=t.animationStarted=t.ProgressBar=t.EventBus=t.NullL10n=t.SpreadMode=t.ScrollMode=t.TextLayerMode=t.RendererType=t.PresentationModeState=t.VERTICAL_PADDING=t.SCROLLBAR_PADDING=t.MAX_AUTO_SCALE=t.UNKNOWN_SCALE=t.MAX_SCALE=t.MIN_SCALE=t.DEFAULT_SCALE=t.DEFAULT_SCALE_VALUE=t.CSS_UNITS=t.AutoPrintRegExp=void 0;var n,i=(n=r(4))&&n.__esModule?n:{default:n};function a(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,n.key,n)}}function s(e,t,r){return t&&o(e.prototype,t),r&&o(e,r),e}function u(e){return(u="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)}function l(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 c(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function h(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){c(a,n,i,o,s,"next",e)}function s(e){c(a,n,i,o,s,"throw",e)}o(void 0)}))}}t.CSS_UNITS=96/72,t.DEFAULT_SCALE_VALUE="auto",t.DEFAULT_SCALE=1,t.MIN_SCALE=.1,t.MAX_SCALE=10,t.UNKNOWN_SCALE=0,t.MAX_AUTO_SCALE=1.25,t.SCROLLBAR_PADDING=40,t.VERTICAL_PADDING=5,t.PresentationModeState={UNKNOWN:0,NORMAL:1,CHANGING:2,FULLSCREEN:3},t.RendererType={CANVAS:"canvas",SVG:"svg"},t.TextLayerMode={DISABLE:0,ENABLE:1,ENABLE_ENHANCE:2};var f={UNKNOWN:-1,VERTICAL:0,HORIZONTAL:1,WRAPPED:2};t.ScrollMode=f;var d={UNKNOWN:-1,NONE:0,ODD:1,EVEN:2};function p(e,t){var r=0,n=e.length-1;if(n<0||!t(e[n]))return e.length;if(t(e[r]))return r;for(;r<n;){var i=r+n>>1;t(e[i])?n=i:r=1+i}return r}function v(e,t,r){if(e<2)return e;var n=t[e].div,i=n.offsetTop+n.clientTop;r<=i&&(i=(n=t[e-1].div).offsetTop+n.clientTop);for(var a=e-2;0<=a&&!((n=t[a].div).offsetTop+n.clientTop+n.clientHeight<=i);--a)e=a;return e}function g(e){var t=Math.sqrt(e.deltaX*e.deltaX+e.deltaY*e.deltaY);e=Math.atan2(e.deltaY,e.deltaX);return-.25*Math.PI<e&&e<.75*Math.PI?-t:t}t.SpreadMode=d,t.AutoPrintRegExp=/\bprint\s*\(/,t.NullL10n={getLanguage:function(){return h(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return","en-us");case 1:case"end":return e.stop()}}),e)})))()},getDirection:function(){return h(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return","ltr");case 1:case"end":return e.stop()}}),e)})))()},get:function(e,t,r){return h(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",function(e,t){return t?e.replace(/\{\{\s*(\w+)\s*\}\}/g,(function(e,r){return r in t?t[r]:"{{"+r+"}}"})):e}(r,t));case 1:case"end":return e.stop()}}),e)})))()},translate:function(e){return h(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})))()}};var y={EVENT:"event",TIMEOUT:"timeout"};t.WaitOnType=y;var m=new Promise((function(e){window.requestAnimationFrame(e)}));t.animationStarted=m;var b=function(){function e(t){a(this,e),this._listeners=Object.create(null)}return s(e,[{key:"on",value:function(e,t){this._on(e,t,{external:!0})}},{key:"off",value:function(e,t){this._off(e,t,{external:!0})}},{key:"dispatch",value:function(e){var t,r;e=this._listeners[e];e&&0!==e.length&&(t=Array.prototype.slice.call(arguments,1),e.slice(0).forEach((function(e){var n=e.listener;e.external?(r=r||[]).push(n):n.apply(null,t)})),r&&(r.forEach((function(e){e.apply(null,t)})),r=null))}},{key:"_on",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,n=this._listeners[e];n||(this._listeners[e]=n=[]),n.push({listener:t,external:!0===(r&&r.external)})}},{key:"_off",value:function(e,t){var r=this._listeners[e];if(r)for(var n=0,i=r.length;n<i;n++)if(r[n].listener===t)return void r.splice(n,1)}}]),e}();function _(e,t,r){return Math.min(Math.max(e,t),r)}t.EventBus=b,t.ProgressBar=function(){function e(t){var r=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=r.height,i=r.width;r=r.units;a(this,e),this.visible=!0,this.div=document.querySelector(t+" .progress"),this.bar=this.div.parentNode,this.height=n||100,this.width=i||100,this.units=r||"%",this.div.style.height=this.height+this.units,this.percent=0}return s(e,[{key:"_updateBar",value:function(){if(this._indeterminate)return this.div.classList.add("indeterminate"),void(this.div.style.width=this.width+this.units);this.div.classList.remove("indeterminate");var e=this.width*this._percent/100;this.div.style.width=e+this.units}},{key:"setWidth",value:function(e){!e||0<(e=e.parentNode.offsetWidth-e.offsetWidth)&&(this.bar.style.width="calc(100% - ".concat(e,"px)"))}},{key:"hide",value:function(){this.visible&&(this.visible=!1,this.bar.classList.add("hidden"),document.body.classList.remove("loadingInProgress"))}},{key:"show",value:function(){this.visible||(this.visible=!0,document.body.classList.add("loadingInProgress"),this.bar.classList.remove("hidden"))}},{key:"percent",get:function(){return this._percent},set:function(e){this._indeterminate=isNaN(e),this._percent=_(e,0,100),this._updateBar()}}]),e}()},function(e,t,r){"use strict";e.exports=r(5)},function(e,t,r){"use strict";(function(t){function r(e){return(r="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)}t=function(e){var t,n=Object.prototype,i=n.hasOwnProperty,a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",s=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function l(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{l({},"")}catch(n){l=function(e,t,r){return e[t]=r}}function c(e,r,n,i){var a,o,s,u;r=r&&r.prototype instanceof y?r:y,r=Object.create(r.prototype),i=new P(i||[]);return r._invoke=(a=e,o=n,s=i,u=f,function(e,r){if(u===p)throw new Error("Generator is already running");if(u===v){if("throw"===e)throw r;return T()}for(s.method=e,s.arg=r;;){var n=s.delegate;if(n){var i=function e(r,n){var i=r.iterator[n.method];if(i===t){if(n.delegate=null,"throw"===n.method){if(r.iterator.return&&(n.method="return",n.arg=t,e(r,n),"throw"===n.method))return g;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}if(i=h(i,r.iterator,n.arg),"throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,g;i=i.arg;return i?i.done?(n[r.resultName]=i.value,n.next=r.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}(n,s);if(i){if(i===g)continue;return i}}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if(u===f)throw u=v,s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);if(u=p,i=h(a,o,s),"normal"===i.type){if(u=s.done?v:d,i.arg!==g)return{value:i.arg,done:s.done}}else"throw"===i.type&&(u=v,s.method="throw",s.arg=i.arg)}}),r}function h(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var f="suspendedStart",d="suspendedYield",p="executing",v="completed",g={};function y(){}function m(){}function b(){}var _={};_[o]=function(){return this},a=Object.getPrototypeOf,a=a&&a(a(C([]))),a&&a!==n&&i.call(a,o)&&(_=a);var w=b.prototype=y.prototype=Object.create(_);function A(e){["next","throw","return"].forEach((function(t){l(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){var n;this._invoke=function(a,o){function s(){return new t((function(n,s){!function n(a,o,s,u){if(a=h(e[a],e,o),"throw"!==a.type){var l=a.arg;o=l.value;return o&&"object"===r(o)&&i.call(o,"__await")?t.resolve(o.__await).then((function(e){n("next",e,s,u)}),(function(e){n("throw",e,s,u)})):t.resolve(o).then((function(e){l.value=e,s(l)}),(function(e){return n("throw",e,s,u)}))}u(a.arg)}(a,o,n,s)}))}return n=n?n.then(s,s):s()}}function k(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 P(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function C(e){if(e){var r=e[o];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1;r=function r(){for(;++n<e.length;)if(i.call(e,n))return r.value=e[n],r.done=!1,r;return r.value=t,r.done=!0,r};return r.next=r}}return{next:T}}function T(){return{value:t,done:!0}}return((m.prototype=w.constructor=b).constructor=m).displayName=l(b,u,"GeneratorFunction"),e.isGeneratorFunction=function(e){return e="function"==typeof e&&e.constructor,!!e&&(e===m||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,b):(e.__proto__=b,l(e,u,"GeneratorFunction")),e.prototype=Object.create(w),e},e.awrap=function(e){return{__await:e}},A(S.prototype),S.prototype[s]=function(){return this},e.AsyncIterator=S,e.async=function(t,r,n,i,a){void 0===a&&(a=Promise);var o=new S(c(t,r,n,i),a);return e.isGeneratorFunction(r)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},A(w),l(w,u,"Generator"),w[o]=function(){return this},w.toString=function(){return"[object Generator]"},e.keys=function(e){var t,r=[];for(t in e)r.push(t);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=C,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(x),!e)for(var r in this)"t"===r.charAt(0)&&i.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,i){return s.type="throw",s.arg=e,r.next=n,i&&(r.method="next",r.arg=t),!!i}for(var a=this.tryEntries.length-1;0<=a;--a){var o=this.tryEntries[a],s=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var u=i.call(o,"catchLoc"),l=i.call(o,"finallyLoc");if(u&&l){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(u){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.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&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var a=n;break}}var o=(a=a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc?null:a)?a.completion:{};return o.type=e,o.arg=t,a?(this.method="next",this.next=a.finallyLoc,g):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),g},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),g}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n,i=r.completion;return"throw"===i.type&&(n=i.arg,x(r)),n}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),g}},e}("object"===r(t)?t.exports:{});try{regeneratorRuntime=t}catch(e){Function("r","regeneratorRuntime = r")(t)}}).call(this,r(6)(e))},function(e,t,r){"use strict";e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleLinkService=t.PDFLinkService=void 0;var n=r(3);function i(e){return(i="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)}function a(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,n.key,n)}}function s(e,t,r){return t&&o(e.prototype,t),r&&o(e,r),e}t.PDFLinkService=function(){function e(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},r=t.eventBus,n=t.externalLinkTarget,i=void 0===n?null:n,o=t.externalLinkRel;n=void 0===o?null:o,o=t.externalLinkEnabled,o=void 0===o||o,t=t.ignoreDestinationZoom,t=void 0!==t&&t;a(this,e),this.eventBus=r,this.externalLinkTarget=i,this.externalLinkRel=n,this.externalLinkEnabled=o,this._ignoreDestinationZoom=t,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null,this._pagesRefCache=null}return s(e,[{key:"setDocument",value:function(e){this.baseUrl=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,this.pdfDocument=e,this._pagesRefCache=Object.create(null)}},{key:"setViewer",value:function(e){this.pdfViewer=e}},{key:"setHistory",value:function(e){this.pdfHistory=e}},{key:"navigateTo",value:function(e){function t(e){var n,i=e.namedDest,a=e.explicitDest,o=a[0];if(o instanceof Object){if(null===(n=r._cachedPageNumber(o)))return void r.pdfDocument.getPageIndex(o).then((function(e){r.cachePageRef(e+1,o),t({namedDest:i,explicitDest:a})})).catch((function(){}))}else{if(!Number.isInteger(o))return;n=o+1}!n||n<1||n>r.pagesCount||(r.pdfHistory&&(r.pdfHistory.pushCurrentPosition(),r.pdfHistory.push({namedDest:i,explicitDest:a,pageNumber:n})),r.pdfViewer.scrollPageIntoView({pageNumber:n,destArray:a,ignoreDestinationZoom:r._ignoreDestinationZoom}))}var r=this;new Promise((function(t,n){"string"!=typeof e?t({namedDest:"",explicitDest:e}):r.pdfDocument.getDestination(e).then((function(r){t({namedDest:e,explicitDest:r})}))})).then((function(e){Array.isArray(e.explicitDest)&&t(e)}))}},{key:"getDestinationHash",value:function(e){return"string"==typeof e?this.getAnchorUrl("#"+escape(e)):Array.isArray(e)?(e=JSON.stringify(e),this.getAnchorUrl("#"+escape(e))):this.getAnchorUrl("")}},{key:"getAnchorUrl",value:function(e){return(this.baseUrl||"")+e}},{key:"setHash",value:function(e){var t,r;if(e.includes("=")){var a,o,s,u=(0,n.parseQueryString)(e);"search"in u&&this.eventBus.dispatch("findfromurlhash",{source:this,query:u.search.replace(/"/g,""),phraseSearch:"true"===u.phrase}),"page"in u&&(t=0|u.page||1),"zoom"in u&&(o=(a=u.zoom.split(","))[0],s=parseFloat(o),o.includes("Fit")?"Fit"===o||"FitB"===o?r=[null,{name:o}]:"FitH"===o||"FitBH"===o||"FitV"===o||"FitBV"===o?r=[null,{name:o},1<a.length?0|a[1]:null]:"FitR"===o&&(5!==a.length||(r=[null,{name:o},0|a[1],0|a[2],0|a[3],0|a[4]])):r=[null,{name:"XYZ"},1<a.length?0|a[1]:null,2<a.length?0|a[2]:null,s?s/100:o]),r?this.pdfViewer.scrollPageIntoView({pageNumber:t||this.page,destArray:r,allowNegativeOffset:!0}):t&&(this.page=t),"pagemode"in u&&this.eventBus.dispatch("pagemode",{source:this,mode:u.pagemode}),"nameddest"in u&&this.navigateTo(u.nameddest)}else{r=unescape(e);try{r=JSON.parse(r),Array.isArray(r)||(r=r.toString())}catch(e){}"string"!=typeof r&&!function(e){if(!Array.isArray(e))return!1;var t=e.length;if(t<2)return!1;var r=e[0];if(!("object"===i(r)&&Number.isInteger(r.num)&&Number.isInteger(r.gen)||Number.isInteger(r)&&0<=r))return!1;if(r=e[1],"object"!==i(r)||"string"!=typeof r.name)return!1;var n=!0;switch(r.name){case"XYZ":if(5!==t)return!1;break;case"Fit":case"FitB":return 2===t;case"FitH":case"FitBH":case"FitV":case"FitBV":if(3!==t)return!1;break;case"FitR":if(6!==t)return!1;n=!1;break;default:return!1}for(var a=2;a<t;a++){var o=e[a];if(!("number"==typeof o||n&&null===o))return!1}return!0}(r)||this.navigateTo(r)}}},{key:"executeNamedAction",value:function(e){switch(e){case"GoBack":this.pdfHistory&&this.pdfHistory.back();break;case"GoForward":this.pdfHistory&&this.pdfHistory.forward();break;case"NextPage":this.page<this.pagesCount&&this.page++;break;case"PrevPage":1<this.page&&this.page--;break;case"LastPage":this.page=this.pagesCount;break;case"FirstPage":this.page=1}this.eventBus.dispatch("namedaction",{source:this,action:e})}},{key:"cachePageRef",value:function(e,t){t&&(t=0===t.gen?"".concat(t.num,"R"):"".concat(t.num,"R").concat(t.gen),this._pagesRefCache[t]=e)}},{key:"_cachedPageNumber",value:function(e){return e=0===e.gen?"".concat(e.num,"R"):"".concat(e.num,"R").concat(e.gen),this._pagesRefCache&&this._pagesRefCache[e]||null}},{key:"isPageVisible",value:function(e){return this.pdfViewer.isPageVisible(e)}},{key:"pagesCount",get:function(){return this.pdfDocument?this.pdfDocument.numPages:0}},{key:"page",get:function(){return this.pdfViewer.currentPageNumber},set:function(e){this.pdfViewer.currentPageNumber=e}},{key:"rotation",get:function(){return this.pdfViewer.pagesRotation},set:function(e){this.pdfViewer.pagesRotation=e}}]),e}(),t.SimpleLinkService=function(){function e(){a(this,e),this.externalLinkTarget=null,this.externalLinkRel=null,this.externalLinkEnabled=!0,this._ignoreDestinationZoom=!1}return s(e,[{key:"navigateTo",value:function(e){}},{key:"getDestinationHash",value:function(e){return"#"}},{key:"getAnchorUrl",value:function(e){return"#"}},{key:"setHash",value:function(e){}},{key:"executeNamedAction",value:function(e){}},{key:"cachePageRef",value:function(e,t){}},{key:"isPageVisible",value:function(e){return!0}},{key:"pagesCount",get:function(){return 0}},{key:"page",get:function(){return 0},set:function(e){}},{key:"rotation",get:function(){return 0},set:function(e){}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultTextLayerFactory=t.TextLayerBuilder=void 0;var n=r(2);function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(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,n.key,n)}}function o(e,t,r){return t&&a(e.prototype,t),r&&a(e,r),e}var s=function(){function e(t){var r=t.textLayerDiv,n=t.eventBus,a=t.pageIndex,o=t.viewport,s=t.findController;s=void 0===s?null:s,t=t.enhanceTextSelection,t=void 0!==t&&t;i(this,e),this.textLayerDiv=r,this.eventBus=n,this.textContent=null,this.textContentItemsStr=[],this.textContentStream=null,this.renderingDone=!1,this.pageIdx=a,this.pageNumber=this.pageIdx+1,this.matches=[],this.viewport=o,this.textDivs=[],this.findController=s,this.textLayerRenderTask=null,this.enhanceTextSelection=t,this._onUpdateTextLayerMatches=null,this._bindMouse()}return o(e,[{key:"_finishRendering",value:function(){var e;this.renderingDone=!0,this.enhanceTextSelection||((e=document.createElement("div")).className="endOfContent",this.textLayerDiv.appendChild(e)),this.eventBus.dispatch("textlayerrendered",{source:this,pageNumber:this.pageNumber,numTextDivs:this.textDivs.length})}},{key:"render",value:function(){var e,t=this,r=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0;!this.textContent&&!this.textContentStream||this.renderingDone||(this.cancel(),this.textDivs=[],e=document.createDocumentFragment(),this.textLayerRenderTask=(0,n.renderTextLayer)({textContent:this.textContent,textContentStream:this.textContentStream,container:e,viewport:this.viewport,textDivs:this.textDivs,textContentItemsStr:this.textContentItemsStr,timeout:r,enhanceTextSelection:this.enhanceTextSelection}),this.textLayerRenderTask.promise.then((function(){t.textLayerDiv.appendChild(e),t._finishRendering(),t._updateMatches()}),(function(e){})),this._onUpdateTextLayerMatches||(this._onUpdateTextLayerMatches=function(e){e.pageIndex!==t.pageIdx&&-1!==e.pageIndex||t._updateMatches()},this.eventBus._on("updatetextlayermatches",this._onUpdateTextLayerMatches)))}},{key:"cancel",value:function(){this.textLayerRenderTask&&(this.textLayerRenderTask.cancel(),this.textLayerRenderTask=null),this._onUpdateTextLayerMatches&&(this.eventBus._off("updatetextlayermatches",this._onUpdateTextLayerMatches),this._onUpdateTextLayerMatches=null)}},{key:"setTextContentStream",value:function(e){this.cancel(),this.textContentStream=e}},{key:"setTextContent",value:function(e){this.cancel(),this.textContent=e}},{key:"_convertMatches",value:function(e,t){if(!e)return[];for(var r=this.findController,n=this.textContentItemsStr,i=0,a=0,o=n.length-1,s=r.state.query.length,u=[],l=0,c=e.length;l<c;l++){for(var h=e[l];i!==o&&h>=a+n[i].length;)a+=n[i].length,i++;n.length;var f={begin:{divIdx:i,offset:h-a}};for(h+=t?t[l]:s;i!==o&&h>a+n[i].length;)a+=n[i].length,i++;f.end={divIdx:i,offset:h-a},u.push(f)}return u}},{key:"_renderMatches",value:function(e){if(0!==e.length){var t=this.findController,r=this.pageIdx,n=this.textContentItemsStr,i=this.textDivs,a=r===t.selected.pageIdx,o=t.selected.matchIdx,s=null,u={divIdx:-1,offset:void 0},l=o,c=l+1;if(t.state.highlightAll)l=0,c=e.length;else if(!a)return;for(var h=l;h<c;h++){var f=e[h],d=f.begin,p=f.end,v=(f=a&&h===o,f?" selected":"");if(f&&t.scrollMatchIntoView({element:i[d.divIdx],pageIndex:r,matchIndex:o}),s&&d.divIdx===s.divIdx?b(s.divIdx,s.offset,d.offset):(null!==s&&b(s.divIdx,s.offset,u.offset),m(d)),d.divIdx===p.divIdx)b(d.divIdx,d.offset,p.offset,"highlight"+v);else{b(d.divIdx,d.offset,u.offset,"highlight begin"+v);for(var g=d.divIdx+1,y=p.divIdx;g<y;g++)i[g].className="highlight middle"+v;m(p,"highlight end"+v)}s=p}s&&b(s.divIdx,s.offset,u.offset)}function m(e,t){var r=e.divIdx;i[r].textContent="",b(r,0,e.offset,t)}function b(e,t,r,a){var o=i[e];t=n[e].substring(t,r),r=document.createTextNode(t);if(a)return t=document.createElement("span"),t.className=a,t.appendChild(r),void o.appendChild(t);o.appendChild(r)}}},{key:"_updateMatches",value:function(){if(this.renderingDone){for(var e,t=this.findController,r=this.matches,n=this.pageIdx,i=this.textContentItemsStr,a=this.textDivs,o=-1,s=0,u=r.length;s<u;s++){for(var l=r[s],c=Math.max(o,l.begin.divIdx),h=l.end.divIdx;c<=h;c++){var f=a[c];f.textContent=i[c],f.className=""}o=l.end.divIdx+1}t&&t.highlightMatches&&(e=t.pageMatches[n]||null,n=t.pageMatchesLength[n]||null,this.matches=this._convertMatches(e,n),this._renderMatches(this.matches))}}},{key:"_bindMouse",value:function(){var e=this,t=this.textLayerDiv,r=null;t.addEventListener("mousedown",(function(n){if(e.enhanceTextSelection&&e.textLayerRenderTask)return e.textLayerRenderTask.expandTextDivs(!0),void(r&&(clearTimeout(r),r=null));var i,a=t.querySelector(".endOfContent");a&&(n.target!==t&&"none"!==window.getComputedStyle(a).getPropertyValue("-moz-user-select")&&(i=t.getBoundingClientRect(),i=Math.max(0,(n.pageY-i.top)/i.height),a.style.top=(100*i).toFixed(2)+"%"),a.classList.add("active"))})),t.addEventListener("mouseup",(function(){var n;e.enhanceTextSelection&&e.textLayerRenderTask?r=setTimeout((function(){e.textLayerRenderTask&&e.textLayerRenderTask.expandTextDivs(!1),r=null}),300):(n=t.querySelector(".endOfContent"))&&(n.style.top="",n.classList.remove("active"))}))}}]),e}();t.TextLayerBuilder=s,t.DefaultTextLayerFactory=function(){function e(){i(this,e)}return o(e,[{key:"createTextLayerBuilder",value:function(e,t,r){return new s({textLayerDiv:e,pageIndex:t,viewport:r,enhanceTextSelection:3<arguments.length&&void 0!==arguments[3]&&arguments[3],eventBus:4<arguments.length?arguments[4]:void 0})}}]),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DownloadManager=void 0;var n=r(2),i=r(10);function a(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,n.key,n)}}function o(e,t){var r=document.createElement("a");if(!r.click)throw new Error('DownloadManager: "a.click()" is not supported.');r.href=e,r.target="_parent","download"in r&&(r.download=t),(document.body||document.documentElement).appendChild(r),r.click(),r.remove()}t.DownloadManager=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,r,s;return t=e,(r=[{key:"downloadUrl",value:function(e,t){(0,n.createValidAbsoluteUrl)(e,"http://example.com")&&o(e+"#pdfjs.action=download",t)}},{key:"downloadData",value:function(e,t,r){navigator.msSaveBlob?navigator.msSaveBlob(new Blob([e],{type:r}),t):o((0,n.createObjectURL)(e,r,i.viewerCompatibilityParams.disableCreateObjectURL),t)}},{key:"download",value:function(e,t,r){navigator.msSaveBlob?navigator.msSaveBlob(e,r)||this.downloadUrl(t,r):i.viewerCompatibilityParams.disableCreateObjectURL?this.downloadUrl(t,r):o(URL.createObjectURL(e),r)}}])&&a(t.prototype,r),s&&a(t,s),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.viewerCompatibilityParams=void 0;var n=Object.create(null),i="undefined"!=typeof navigator&&navigator.userAgent||"",a="undefined"!=typeof navigator&&navigator.platform||"",o="undefined"!=typeof navigator&&navigator.maxTouchPoints||1,s=/Android/.test(i),u=/Trident/.test(i);o=/\b(iPad|iPhone|iPod)(?=;)/.test(i)||"MacIntel"===a&&1<o,i=/CriOS/.test(i);(u||i)&&(n.disableCreateObjectURL=!0),(o||s)&&(n.maxCanvasPixels=5242880),n=Object.freeze(n),t.viewerCompatibilityParams=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GenericL10n=void 0;var n,i=(n=r(4))&&n.__esModule?n:{default:n};function a(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function o(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var o=e.apply(t,r);function s(e){a(o,n,i,s,u,"next",e)}function u(e){a(o,n,i,s,u,"throw",e)}s(void 0)}))}}function s(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,n.key,n)}}r(12);var u=document.webL10n;t.GenericL10n=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._lang=t,this._ready=new Promise((function(e,r){u.setLanguage(t,(function(){e(u)}))}))}var t,r,n,a,l,c,h;return t=e,(r=[{key:"getLanguage",value:(h=o(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return t=e.sent,e.abrupt("return",t.getLanguage());case 4:case"end":return e.stop()}}),e,this)}))),function(){return h.apply(this,arguments)})},{key:"getDirection",value:(c=o(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return t=e.sent,e.abrupt("return",t.getDirection());case 4:case"end":return e.stop()}}),e,this)}))),function(){return c.apply(this,arguments)})},{key:"get",value:(l=o(i.default.mark((function e(t,r,n){var a;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return a=e.sent,e.abrupt("return",a.get(t,r,n));case 4:case"end":return e.stop()}}),e,this)}))),function(e,t,r){return l.apply(this,arguments)})},{key:"translate",value:(a=o(i.default.mark((function e(t){var r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return r=e.sent,e.abrupt("return",r.translate(t));case 4:case"end":return e.stop()}}),e,this)}))),function(e){return a.apply(this,arguments)})}])&&s(t.prototype,r),n&&s(t,n),e}()},function(e,t,r){"use strict";function n(e,t,r){t=t||function(e){},r=r||function(){};var n=new XMLHttpRequest;n.open("GET",e,g),n.overrideMimeType&&n.overrideMimeType("text/plain; charset=utf-8"),n.onreadystatechange=function(){4==n.readyState&&(200==n.status||0===n.status?t(n.responseText):r())},n.onerror=r,n.ontimeout=r;try{n.send(null)}catch(e){r()}}function i(e,t,r,i){var a=e.replace(/[^\/]*$/,"")||"./";function o(e,r){var i={},o=/^\s*|\s*$/,s=/^\s*#|^\s*$/,u=/^\s*\[(.*)\]\s*$/,l=/^\s*@import\s+url\((.*)\)\s*$/i,c=/^([^=\s]*)\s*=\s*(.+)$/;function h(e,r,f){var d=e.replace(o,"").split(/[\r\n]+/),p="*",v=t.split("-",1)[0],g=!1,y="";!function e(){for(;;){if(!d.length)return void f();var o=d.shift();if(!s.test(o)){if(r){if(y=u.exec(o)){p=y[1].toLowerCase(),g="*"!==p&&p!==t&&p!==v;continue}if(g)continue;if(y=l.exec(o))return void function(e,t){n(e,(function(e){h(e,!1,t)}),(function(){t()}))}(a+y[1],e)}(o=o.match(c))&&3==o.length&&(i[o[1]]=(o=o[2]).lastIndexOf("\\")<0?o:o.replace(/\\\\/g,"\\").replace(/\\n/g,"\n").replace(/\\r/g,"\r").replace(/\\t/g,"\t").replace(/\\b/g,"\b").replace(/\\f/g,"\f").replace(/\\{/g,"{").replace(/\\}/g,"}").replace(/\\"/g,'"').replace(/\\'/g,"'"))}}}()}h(e,!0,(function(){r(i)}))}n(e,(function(e){h+=e,o(e,(function(e){for(var t in e){var n,i=t.lastIndexOf(".");i=0<i?(n=t.substring(0,i),t.substring(i+1)):(n=t,f);c[n]||(c[n]={}),c[n][i]=e[t]}r&&r()}))}),i)}function a(e,t){e=e&&e.toLowerCase(),t=t||function(){},c={},d=h="",d=e;var r=l.querySelectorAll('link[type="application/l10n"]'),n=r.length;if(0!==n)for(var a,o=0,s=function(){n<=++o&&(t(),v="complete")},u=0;u<n;u++)new y(r[u]).load(e,s);else{var f=(a=l.querySelector('script[type="application/l10n"]'))?JSON.parse(a.innerHTML):null;if(f&&f.locales&&f.default_locale){if(!(c=f.locales[e])){var p,g=f.default_locale.toLowerCase();for(p in f.locales){if((p=p.toLowerCase())===e){c=f.locales[e];break}p===g&&(c=f.locales[g])}}t()}v="complete"}function y(e){var t=e.href;this.load=function(e,r){i(t,e,r,(function(){d="",r()}))}}}function o(e,t,r){var n=c[e];if(!n){if(!r)return null;n=r}var i,a={};for(i in n){var o=n[i];o=function(e,t){return e.replace(/\{\{\s*(.+?)\s*\}\}/g,(function(e,r){return t&&r in t?t[r]:r in c?c[r]:e}))}(o=function(e,t,r,n){var i=/\{\[\s*([a-zA-Z]+)\(([a-zA-Z]+)\)\s*\]\}/.exec(e);if(!i||!i.length)return e;var a,o=i[1];i=i[2];return t&&i in t?a=t[i]:i in c&&(a=c[i]),o in p&&(o=p[o],e=o(e,a,r,n)),e}(o,t,e,i),t),a[i]=o}return a}function s(e){var t=function(e){if(!e)return{};var t=e.getAttribute("data-l10n-id"),r=e.getAttribute("data-l10n-args");e={};if(r)try{e=JSON.parse(r)}catch(e){}return{id:t,args:e}}(e);if(t.id){var r=o(t.id,t.args);if(r){if(r[f]){if(0===function(e){if(e.children)return e.children.length;if(void 0!==e.childElementCount)return e.childElementCount;for(var t=0,r=0;r<e.childNodes.length;r++)t+=1===e.nodeType?1:0;return t}(e))e[f]=r[f];else{for(var n=e.childNodes,i=!1,a=0,s=n.length;a<s;a++)3===n[a].nodeType&&/\S/.test(n[a].nodeValue)&&(i?n[a].nodeValue="":(n[a].nodeValue=r[f],i=!0));i||(t=l.createTextNode(r[f]),e.insertBefore(t,e.firstChild))}delete r[f]}for(var u in r)e[u]=r[u]}}}var u,l,c,h,f,d,p,v,g;document.webL10n=(u=window,l=document,c={},f="textContent",v="loading",g=!(d=h=""),(p={}).plural=function(e,t,r,n){var i=parseFloat(t);if(isNaN(i))return e;if(n!=f)return e;function a(e,t){return-1!==t.indexOf(e)}function o(e,t,r){return t<=e&&e<=r}p._pluralRules||(p._pluralRules=(t={0:function(e){return"other"},1:function(e){return o(e%100,3,10)?"few":0===e?"zero":o(e%100,11,99)?"many":2==e?"two":1==e?"one":"other"},2:function(e){return 0!==e&&e%10==0?"many":2==e?"two":1==e?"one":"other"},3:function(e){return 1==e?"one":"other"},4:function(e){return o(e,0,1)?"one":"other"},5:function(e){return o(e,0,2)&&2!=e?"one":"other"},6:function(e){return 0===e?"zero":e%10==1&&e%100!=11?"one":"other"},7:function(e){return 2==e?"two":1==e?"one":"other"},8:function(e){return o(e,3,6)?"few":o(e,7,10)?"many":2==e?"two":1==e?"one":"other"},9:function(e){return 0===e||1!=e&&o(e%100,1,19)?"few":1==e?"one":"other"},10:function(e){return o(e%10,2,9)&&!o(e%100,11,19)?"few":e%10!=1||o(e%100,11,19)?"other":"one"},11:function(e){return o(e%10,2,4)&&!o(e%100,12,14)?"few":e%10==0||o(e%10,5,9)||o(e%100,11,14)?"many":e%10==1&&e%100!=11?"one":"other"},12:function(e){return o(e,2,4)?"few":1==e?"one":"other"},13:function(e){return o(e%10,2,4)&&!o(e%100,12,14)?"few":1!=e&&o(e%10,0,1)||o(e%10,5,9)||o(e%100,12,14)?"many":1==e?"one":"other"},14:function(e){return o(e%100,3,4)?"few":e%100==2?"two":e%100==1?"one":"other"},15:function(e){return 0===e||o(e%100,2,10)?"few":o(e%100,11,19)?"many":1==e?"one":"other"},16:function(e){return e%10==1&&11!=e?"one":"other"},17:function(e){return 3==e?"few":0===e?"zero":6==e?"many":2==e?"two":1==e?"one":"other"},18:function(e){return 0===e?"zero":o(e,0,2)&&0!==e&&2!=e?"one":"other"},19:function(e){return o(e,2,10)?"few":o(e,0,1)?"one":"other"},20:function(e){return!o(e%10,3,4)&&e%10!=9||o(e%100,10,19)||o(e%100,70,79)||o(e%100,90,99)?e%1e6==0&&0!==e?"many":e%10!=2||a(e%100,[12,72,92])?e%10!=1||a(e%100,[11,71,91])?"other":"one":"two":"few"},21:function(e){return 0===e?"zero":1==e?"one":"other"},22:function(e){return o(e,0,1)||o(e,11,99)?"one":"other"},23:function(e){return o(e%10,1,2)||e%20==0?"one":"other"},24:function(e){return o(e,3,10)||o(e,13,19)?"few":a(e,[2,12])?"two":a(e,[1,11])?"one":"other"}},(s={af:3,ak:4,am:4,ar:1,asa:3,az:0,be:11,bem:3,bez:3,bg:3,bh:4,bm:0,bn:3,bo:0,br:20,brx:3,bs:11,ca:3,cgg:3,chr:3,cs:12,cy:17,da:3,de:3,dv:3,dz:0,ee:3,el:3,en:3,eo:3,es:3,et:3,eu:3,fa:0,ff:5,fi:3,fil:4,fo:3,fr:5,fur:3,fy:3,ga:8,gd:24,gl:3,gsw:3,gu:3,guw:4,gv:23,ha:3,haw:3,he:2,hi:4,hr:11,hu:0,id:0,ig:0,ii:0,is:3,it:3,iu:7,ja:0,jmc:3,jv:0,ka:0,kab:5,kaj:3,kcg:3,kde:0,kea:0,kk:3,kl:3,km:0,kn:0,ko:0,ksb:3,ksh:21,ku:3,kw:7,lag:18,lb:3,lg:3,ln:4,lo:0,lt:10,lv:6,mas:3,mg:4,mk:16,ml:3,mn:3,mo:9,mr:3,ms:0,mt:15,my:0,nah:3,naq:7,nb:3,nd:3,ne:3,nl:3,nn:3,no:3,nr:3,nso:4,ny:3,nyn:3,om:3,or:3,pa:3,pap:3,pl:13,ps:3,pt:3,rm:3,ro:9,rof:3,ru:11,rwk:3,sah:0,saq:3,se:7,seh:3,ses:0,sg:0,sh:11,shi:19,sk:12,sl:14,sma:7,smi:7,smj:7,smn:7,sms:7,sn:3,so:3,sq:3,sr:11,ss:3,ssy:3,st:3,sv:3,sw:3,syr:3,ta:3,te:3,teo:3,th:0,ti:4,tig:3,tk:3,tl:4,tn:3,to:0,tr:0,ts:3,tzm:22,uk:11,ur:3,ve:3,vi:0,vun:3,wa:4,wae:3,wo:0,xh:3,xog:3,yo:0,zh:0,zu:3}[(s=d).replace(/-.*$/,"")])in t?t[s]:function(){return"other"}));var s="["+p._pluralRules(i)+"]";return 0===i&&r+"[zero]"in c?e=c[r+"[zero]"][n]:1==i&&r+"[one]"in c?e=c[r+"[one]"][n]:2==i&&r+"[two]"in c?e=c[r+"[two]"][n]:r+s in c?e=c[r+s][n]:r+"[other]"in c&&(e=c[r+"[other]"][n]),e},{get:function(e,t,r){var n=e.lastIndexOf("."),i=f;0<n&&(i=e.substring(n+1),e=e.substring(0,n)),r&&((a={})[i]=r);var a=o(e,t,a);return a&&i in a?a[i]:"{{"+e+"}}"},getData:function(){return c},getText:function(){return h},getLanguage:function(){return d},setLanguage:function(e,t){a(e,(function(){t&&t()}))},getDirection:function(){var e=d.split("-",1)[0];return 0<=["ar","he","fa","ps","ur"].indexOf(e)?"rtl":"ltr"},translate:function(e){e=e||l.documentElement;for(var t,r=(t=e)?t.querySelectorAll("*[data-l10n-id]"):[],n=r.length,i=0;i<n;i++)s(r[i]);s(e)},getReadyState:function(){return v},ready:function(e){e&&("complete"==v||"interactive"==v?u.setTimeout((function(){e()})):l.addEventListener&&l.addEventListener("localized",(function t(){l.removeEventListener("localized",t),e()})))}})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFFindController=t.FindState=void 0;var n=r(2),i=r(14),a=r(3);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,n.key,n)}}var s={FOUND:0,NOT_FOUND:1,WRAPPED:2,PENDING:3};t.FindState=s;var u={"‘":"'","’":"'","‚":"'","‛":"'","“":'"',"”":'"',"„":'"',"‟":'"',"¼":"1/4","½":"1/2","¾":"3/4"},l=null;function c(e){var t;return l||(t=Object.keys(u).join(""),l=new RegExp("[".concat(t,"]"),"g")),e.replace(l,(function(e){return u[e]}))}t.PDFFindController=function(){function e(t){var r=t.linkService;t=t.eventBus;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._linkService=r,this._eventBus=t,this._reset(),t._on("findbarclose",this._onFindBarClose.bind(this))}var t,r,u;return t=e,(r=[{key:"setDocument",value:function(e){this._pdfDocument&&this._reset(),e&&(this._pdfDocument=e,this._firstPageCapability.resolve())}},{key:"executeCommand",value:function(e,t){var r,n=this;t&&(r=this._pdfDocument,null!==this._state&&!this._shouldDirtyMatch(e,t)||(this._dirtyMatch=!0),this._state=t,"findhighlightallchange"!==e&&this._updateUIState(s.PENDING),this._firstPageCapability.promise.then((function(){var t,i;!n._pdfDocument||r&&n._pdfDocument!==r||(n._extractText(),t=!n._highlightMatches,i=!!n._findTimeout,n._findTimeout&&(clearTimeout(n._findTimeout),n._findTimeout=null),"find"===e?n._findTimeout=setTimeout((function(){n._nextMatch(),n._findTimeout=null}),250):n._dirtyMatch?n._nextMatch():"findagain"===e?(n._nextMatch(),t&&n._state.highlightAll&&n._updateAllPages()):"findhighlightallchange"===e?(i?n._nextMatch():n._highlightMatches=!0,n._updateAllPages()):n._nextMatch())})))}},{key:"scrollMatchIntoView",value:function(e){var t=e.element,r=void 0===t?null:t;t=e.pageIndex,t=void 0===t?-1:t,e=e.matchIndex,e=void 0===e?-1:e;this._scrollMatches&&r&&-1!==e&&e===this._selected.matchIdx&&-1!==t&&t===this._selected.pageIdx&&(this._scrollMatches=!1,a.scrollIntoView)(r,{top:-50,left:-400},!0)}},{key:"_reset",value:function(){this._highlightMatches=!1,this._scrollMatches=!1,this._pdfDocument=null,this._pageMatches=[],this._pageMatchesLength=[],this._state=null,this._selected={pageIdx:-1,matchIdx:-1},this._offset={pageIdx:null,matchIdx:null,wrapped:!1},this._extractTextPromises=[],this._pageContents=[],this._matchesCountTotal=0,this._pagesToSearch=null,this._pendingFindMatches=Object.create(null),this._resumePageIdx=null,this._dirtyMatch=!1,clearTimeout(this._findTimeout),this._findTimeout=null,this._firstPageCapability=(0,n.createPromiseCapability)()}},{key:"_shouldDirtyMatch",value:function(e,t){if(t.query!==this._state.query)return!0;switch(e){case"findagain":var r=this._selected.pageIdx+1,n=this._linkService;return 1<=r&&r<=n.pagesCount&&r!==n.page&&!n.isPageVisible(r);case"findhighlightallchange":return!1}return!0}},{key:"_prepareMatches",value:function(e,t,r){e.sort((function(e,t){return e.match===t.match?e.matchLength-t.matchLength:e.match-t.match}));for(var n=0,i=e.length;n<i;n++)!function(t){var r=e[t],n=e[t+1];if(t<e.length-1&&r.match===n.match)return r.skipped=!0;for(var i=t-1;0<=i;i--){var a=e[i];if(!a.skipped){if(a.match+a.matchLength<r.match)break;if(a.match+a.matchLength>=r.match+r.matchLength)return r.skipped=!0}}}(n)&&(t.push(e[n].match),r.push(e[n].matchLength))}},{key:"_isEntireWord",value:function(e,t,r){if(0<t){var n=e.charCodeAt(t),a=e.charCodeAt(t-1);if((0,i.getCharacterType)(n)===(0,i.getCharacterType)(a))return!1}return t=t+r-1,!(t<e.length-1&&(r=e.charCodeAt(t),t=e.charCodeAt(1+t),(0,i.getCharacterType)(r)===(0,i.getCharacterType)(t)))}},{key:"_calculatePhraseMatch",value:function(e,t,r,n){for(var i=[],a=e.length,o=-a;-1!==(o=r.indexOf(e,o+a));)n&&!this._isEntireWord(r,o,a)||i.push(o);this._pageMatches[t]=i}},{key:"_calculateWordMatch",value:function(e,t,r,n){for(var i=[],a=e.match(/\S+/g),o=0,s=a.length;o<s;o++)for(var u=a[o],l=u.length,c=-l;-1!==(c=r.indexOf(u,c+l));)n&&!this._isEntireWord(r,c,l)||i.push({match:c,matchLength:l,skipped:!1});this._pageMatchesLength[t]=[],this._pageMatches[t]=[],this._prepareMatches(i,this._pageMatches[t],this._pageMatchesLength[t])}},{key:"_calculateMatch",value:function(e){var t=this._pageContents[e],r=this._query,n=this._state,i=n.caseSensitive,a=n.entireWord;n=n.phraseSearch;0!==r.length&&(i||(t=t.toLowerCase(),r=r.toLowerCase()),n?this._calculatePhraseMatch(r,e,t,a):this._calculateWordMatch(r,e,t,a),this._state.highlightAll&&this._updatePage(e),this._resumePageIdx===e&&(this._resumePageIdx=null,this._nextPageMatch()),0<(e=this._pageMatches[e].length)&&(this._matchesCountTotal+=e,this._updateUIResultsCount()))}},{key:"_extractText",value:function(){var e=this;if(!(0<this._extractTextPromises.length))for(var t=Promise.resolve(),r=0,i=this._linkService.pagesCount;r<i;r++)!function(r){var i=(0,n.createPromiseCapability)();e._extractTextPromises[r]=i.promise,t=t.then((function(){return e._pdfDocument.getPage(r+1).then((function(e){return e.getTextContent({normalizeWhitespace:!0})})).then((function(t){for(var n=t.items,a=[],o=0,s=n.length;o<s;o++)a.push(n[o].str);e._pageContents[r]=c(a.join("")),i.resolve(r)}),(function(t){e._pageContents[r]="",i.resolve(r)}))}))}(r)}},{key:"_updatePage",value:function(e){this._scrollMatches&&this._selected.pageIdx===e&&(this._linkService.page=e+1),this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:e})}},{key:"_updateAllPages",value:function(){this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:-1})}},{key:"_nextMatch",value:function(){var e=this,t=this._state.findPrevious,r=this._linkService.page-1,n=this._linkService.pagesCount;if(this._highlightMatches=!0,this._dirtyMatch){this._dirtyMatch=!1,this._selected.pageIdx=this._selected.matchIdx=-1,this._offset.pageIdx=r,this._offset.matchIdx=null,this._offset.wrapped=!1,this._resumePageIdx=null,this._pageMatches.length=0,this._pageMatchesLength.length=0,this._matchesCountTotal=0,this._updateAllPages();for(var i=0;i<n;i++)!0!==this._pendingFindMatches[i]&&(this._pendingFindMatches[i]=!0,this._extractTextPromises[i].then((function(t){delete e._pendingFindMatches[t],e._calculateMatch(t)})))}if(""!==this._query){if(!this._resumePageIdx){var a=this._offset;if(this._pagesToSearch=n,null!==a.matchIdx){if(r=this._pageMatches[a.pageIdx].length,!t&&a.matchIdx+1<r||t&&0<a.matchIdx)return a.matchIdx=t?a.matchIdx-1:a.matchIdx+1,void this._updateMatch(!0);this._advanceOffsetPage(t)}this._nextPageMatch()}}else this._updateUIState(s.FOUND)}},{key:"_matchesReady",value:function(e){var t=this._offset,r=e.length;e=this._state.findPrevious;return r?(t.matchIdx=e?r-1:0,this._updateMatch(!0),!0):(this._advanceOffsetPage(e),!!(t.wrapped&&(t.matchIdx=null,this._pagesToSearch<0))&&(this._updateMatch(!1),!0))}},{key:"_nextPageMatch",value:function(){this._resumePageIdx;var e=null;do{var t=this._offset.pageIdx;if(!(e=this._pageMatches[t])){this._resumePageIdx=t;break}}while(!this._matchesReady(e))}},{key:"_advanceOffsetPage",value:function(e){var t=this._offset,r=this._linkService.pagesCount;t.pageIdx=e?t.pageIdx-1:t.pageIdx+1,t.matchIdx=null,this._pagesToSearch--,(t.pageIdx>=r||t.pageIdx<0)&&(t.pageIdx=e?r-1:0,t.wrapped=!0)}},{key:"_updateMatch",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=s.NOT_FOUND,r=this._offset.wrapped;this._offset.wrapped=!1,e&&(e=this._selected.pageIdx,this._selected.pageIdx=this._offset.pageIdx,this._selected.matchIdx=this._offset.matchIdx,t=r?s.WRAPPED:s.FOUND,-1!==e&&e!==this._selected.pageIdx&&this._updatePage(e)),this._updateUIState(t,this._state.findPrevious),-1!==this._selected.pageIdx&&(this._scrollMatches=!0,this._updatePage(this._selected.pageIdx))}},{key:"_onFindBarClose",value:function(e){var t=this,r=this._pdfDocument;this._firstPageCapability.promise.then((function(){!t._pdfDocument||r&&t._pdfDocument!==r||(t._findTimeout&&(clearTimeout(t._findTimeout),t._findTimeout=null),t._resumePageIdx&&(t._resumePageIdx=null,t._dirtyMatch=!0),t._updateUIState(s.FOUND),t._highlightMatches=!1,t._updateAllPages())}))}},{key:"_requestMatchesCount",value:function(){var e=this._selected,t=e.pageIdx,r=e.matchIdx,n=0;e=this._matchesCountTotal;if(-1!==r){for(var i=0;i<t;i++)n+=this._pageMatches[i]&&this._pageMatches[i].length||0;n+=r+1}return{current:n=n<1||e<n?e=0:n,total:e}}},{key:"_updateUIResultsCount",value:function(){this._eventBus.dispatch("updatefindmatchescount",{source:this,matchesCount:this._requestMatchesCount()})}},{key:"_updateUIState",value:function(e,t){this._eventBus.dispatch("updatefindcontrolstate",{source:this,state:e,previous:t,matchesCount:this._requestMatchesCount(),rawQuery:this._state?this._state.query:null})}},{key:"highlightMatches",get:function(){return this._highlightMatches}},{key:"pageMatches",get:function(){return this._pageMatches}},{key:"pageMatchesLength",get:function(){return this._pageMatchesLength}},{key:"selected",get:function(){return this._selected}},{key:"state",get:function(){return this._state}},{key:"_query",get:function(){return this._state.query!==this._rawQuery&&(this._rawQuery=this._state.query,this._normalizedQuery=c(this._state.query)),this._normalizedQuery}}])&&o(t.prototype,r),u&&o(t,u),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCharacterType=function(e){return e<11904?0==(65408&e)?function(e){return 32===e||9===e||13===e||10===e}(e)?n.SPACE:function(e){return 97<=e&&e<=122||65<=e&&e<=90}(e)||function(e){return 48<=e&&e<=57}(e)||95===e?n.ALPHA_LETTER:n.PUNCT:3584==(65408&e)?n.THAI_LETTER:160===e?n.SPACE:n.ALPHA_LETTER:function(e){return 13312<=e&&e<=40959||63744<=e&&e<=64255}(e)?n.HAN_LETTER:function(e){return 12448<=e&&e<=12543}(e)?n.KATAKANA_LETTER:function(e){return 12352<=e&&e<=12447}(e)?n.HIRAGANA_LETTER:function(e){return 65376<=e&&e<=65439}(e)?n.HALFWIDTH_KATAKANA_LETTER:n.ALPHA_LETTER},t.CharacterType=void 0;var n={SPACE:0,ALPHA_LETTER:1,PUNCT:2,HAN_LETTER:3,KATAKANA_LETTER:4,HIRAGANA_LETTER:5,HALFWIDTH_KATAKANA_LETTER:6,THAI_LETTER:7};t.CharacterType=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isDestHashesEqual=l,t.isDestArraysEqual=c,t.PDFHistory=void 0;var n=r(3);function i(e){return(i="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)}function a(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}(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 o(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 s(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,n.key,n)}}function u(){return document.location.hash}function l(e,t){return"string"==typeof e&&"string"==typeof t&&(e===t||(0,n.parseQueryString)(e).nameddest===t)}function c(e,t){if(!Array.isArray(e)||!Array.isArray(t))return!1;if(e.length!==t.length)return!1;for(var r=0,n=e.length;r<n;r++)if(!function e(t,r){if(i(t)===i(r)&&!Array.isArray(t)&&!Array.isArray(r)){if(null===t||"object"!==i(t)||null===r)return t===r||Number.isNaN(t)&&Number.isNaN(r);if(Object.keys(t).length===Object.keys(r).length){for(var n in t)if(!e(t[n],r[n]))return;return 1}}}(e[r],t[r]))return!1;return!0}t.PDFHistory=function(){function e(t){var r=this,n=t.linkService;t=t.eventBus;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.linkService=n,this.eventBus=t,this._initialized=!1,this._fingerprint="",this.reset(),this._boundEvents=null,this._isViewerInPresentationMode=!1,this.eventBus._on("presentationmodechanged",(function(e){r._isViewerInPresentationMode=e.active||e.switchInProgress})),this.eventBus._on("pagesinit",(function(){function e(t){r.eventBus._off("pagesloaded",e),r._isPagesLoaded=!!t.pagesCount}r._isPagesLoaded=!1,r.eventBus._on("pagesloaded",e)}))}var t,r,o;return t=e,(r=[{key:"initialize",value:function(e){var t=e.fingerprint,r=e.resetHistory,n=void 0!==r&&r,i=e.updateUrl;r=void 0!==i&&i;if(t&&"string"==typeof t){if(this._initialized&&this.reset(),e=""!==this._fingerprint&&this._fingerprint!==t,this._fingerprint=t,this._updateUrl=!0===r,this._initialized=!0,this._bindEvents(),i=window.history.state,this._popStateInProgress=!1,this._blockHashChange=0,this._currentHash=u(),this._numPositionUpdates=0,this._uid=this._maxUid=0,this._destination=null,this._position=null,!this._isValidState(i,!0)||n){var a=this._parseCurrentHash(!0);t=a.hash,r=a.page,a=a.rotation;return!t||e||n?void this._pushOrReplaceState(null,!0):void this._pushOrReplaceState({hash:t,page:r,rotation:a},!0)}a=i.destination,this._updateInternalState(a,i.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),void 0!==a.rotation&&(this._initialRotation=a.rotation),a.dest?(this._initialBookmark=JSON.stringify(a.dest),this._destination.page=null):a.hash?this._initialBookmark=a.hash:a.page&&(this._initialBookmark="page=".concat(a.page))}}},{key:"reset",value:function(){this._initialized&&(this._pageHide(),this._initialized=!1,this._unbindEvents()),this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._initialBookmark=null,this._initialRotation=null}},{key:"push",value:function(e){var t=this,r=e.namedDest,n=void 0===r?null:r,i=e.explicitDest;r=e.pageNumber;if(this._initialized&&(!n||"string"==typeof n)&&Array.isArray(i)&&(Number.isInteger(r)&&0<r&&r<=this.linkService.pagesCount||null===r&&!this._destination)&&(e=n||JSON.stringify(i),e)){if(n=!1,this._destination&&(l(this._destination.hash,e)||c(this._destination.dest,i))){if(this._destination.page)return;n=!0}this._popStateInProgress&&!n||(this._pushOrReplaceState({dest:i,hash:e,page:r,rotation:this.linkService.rotation},n),this._popStateInProgress||(this._popStateInProgress=!0,Promise.resolve().then((function(){t._popStateInProgress=!1}))))}}},{key:"pushCurrentPosition",value:function(){this._initialized&&!this._popStateInProgress&&this._tryPushCurrentPosition()}},{key:"back",value:function(){var e;this._initialized&&!this._popStateInProgress&&(e=window.history.state,this._isValidState(e)&&0<e.uid&&window.history.back())}},{key:"forward",value:function(){var e;this._initialized&&!this._popStateInProgress&&(e=window.history.state,this._isValidState(e)&&e.uid<this._maxUid&&window.history.forward())}},{key:"_pushOrReplaceState",value:function(e){var t,r,n=1<arguments.length&&void 0!==arguments[1]&&arguments[1]||!this._destination,i={fingerprint:this._fingerprint,uid:n?this._uid:this._uid+1,destination:e};this._updateInternalState(e,i.uid),this._updateUrl&&e&&e.hash&&((r=document.location.href.split("#")[0]).startsWith("file://")||(t="".concat(r,"#").concat(e.hash))),n?window.history.replaceState(i,"",t):(this._maxUid=this._uid,window.history.pushState(i,"",t))}},{key:"_tryPushCurrentPosition",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];if(this._position){var t=this._position;if(e&&((t=Object.assign(Object.create(null),this._position)).temporary=!0),this._destination){if(this._destination.temporary)this._pushOrReplaceState(t,!0);else if(this._destination.hash!==t.hash&&(this._destination.page||!(this._numPositionUpdates<=50))){if(e=!1,this._destination.page>=t.first&&this._destination.page<=t.page){if(this._destination.dest||!this._destination.first)return;e=!0}this._pushOrReplaceState(t,e)}}else this._pushOrReplaceState(t)}}},{key:"_isValidState",value:function(e){if(!e)return!1;if(e.fingerprint!==this._fingerprint){if(!(1<arguments.length&&void 0!==arguments[1]&&arguments[1]))return!1;if("string"!=typeof e.fingerprint||e.fingerprint.length!==this._fingerprint.length)return!1;var t=a(performance.getEntriesByType("navigation"),1)[0];if(!t||"reload"!==t.type)return!1}return!(!Number.isInteger(e.uid)||e.uid<0)&&null!==e.destination&&"object"===i(e.destination)}},{key:"_updateInternalState",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]&&arguments[2];this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),r&&e&&e.temporary&&delete e.temporary,this._destination=e,this._uid=t,this._numPositionUpdates=0}},{key:"_parseCurrentHash",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=unescape(u()).substring(1),r=(0,n.parseQueryString)(t),i=r.nameddest||"";r=0|r.page;return{hash:t,page:r=!(Number.isInteger(r)&&0<r&&r<=this.linkService.pagesCount)||e&&0<i.length?null:r,rotation:this.linkService.rotation}}},{key:"_updateViewarea",value:function(e){var t=this;e=e.location;this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._position={hash:this._isViewerInPresentationMode?"page=".concat(e.pageNumber):e.pdfOpenParams.substring(1),page:this.linkService.page,first:e.pageNumber,rotation:e.rotation},this._popStateInProgress||(this._isPagesLoaded&&this._destination&&!this._destination.page&&this._numPositionUpdates++,this._updateViewareaTimeout=setTimeout((function(){t._popStateInProgress||t._tryPushCurrentPosition(!0),t._updateViewareaTimeout=null}),1e3))}},{key:"_popState",value:function(e){var t,r=this,i=e.state,a=u();e=this._currentHash!==a;this._currentHash=a,i?this._isValidState(i)&&(this._popStateInProgress=!0,e&&(this._blockHashChange++,(0,n.waitOnEventOrTimeout)({target:window,name:"hashchange",delay:1e3}).then((function(){r._blockHashChange--}))),t=i.destination,this._updateInternalState(t,i.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),(0,n.isValidRotation)(t.rotation)&&(this.linkService.rotation=t.rotation),t.dest?this.linkService.navigateTo(t.dest):t.hash?this.linkService.setHash(t.hash):t.page&&(this.linkService.page=t.page),Promise.resolve().then((function(){r._popStateInProgress=!1}))):(this._uid++,i=(e=this._parseCurrentHash()).hash,t=e.page,e=e.rotation,this._pushOrReplaceState({hash:i,page:t,rotation:e},!0))}},{key:"_pageHide",value:function(){this._destination&&!this._destination.temporary||this._tryPushCurrentPosition()}},{key:"_bindEvents",value:function(){this._boundEvents||(this._boundEvents={updateViewarea:this._updateViewarea.bind(this),popState:this._popState.bind(this),pageHide:this._pageHide.bind(this)},this.eventBus._on("updateviewarea",this._boundEvents.updateViewarea),window.addEventListener("popstate",this._boundEvents.popState),window.addEventListener("pagehide",this._boundEvents.pageHide))}},{key:"_unbindEvents",value:function(){this._boundEvents&&(this.eventBus._off("updateviewarea",this._boundEvents.updateViewarea),window.removeEventListener("popstate",this._boundEvents.popState),window.removeEventListener("pagehide",this._boundEvents.pageHide),this._boundEvents=null)}},{key:"popStateInProgress",get:function(){return this._initialized&&(this._popStateInProgress||0<this._blockHashChange)}},{key:"initialBookmark",get:function(){return this._initialized?this._initialBookmark:null}},{key:"initialRotation",get:function(){return this._initialized?this._initialRotation:null}}])&&s(t.prototype,r),o&&s(t,o),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFPageView=void 0;var n,i=(n=r(4))&&n.__esModule?n:{default:n},a=r(3),o=r(2),s=r(17);function u(e,t,r,n,i,a,o){try{var s=e[a](o),u=s.value}catch(e){return void r(e)}s.done?t(u):Promise.resolve(u).then(n,i)}function l(e){return function(){var t=this,r=arguments;return new Promise((function(n,i){var a=e.apply(t,r);function o(e){u(a,n,i,o,s,"next",e)}function s(e){u(a,n,i,o,s,"throw",e)}o(void 0)}))}}function c(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,n.key,n)}}var h=r(10).viewerCompatibilityParams.maxCanvasPixels||16777216;t.PDFPageView=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var r=t.container,n=t.defaultViewport;this.id=t.id,this.renderingId="page"+this.id,this.pdfPage=null,this.pageLabel=null,this.rotation=0,this.scale=t.scale||a.DEFAULT_SCALE,this.viewport=n,this.pdfPageRotate=n.rotation,this._annotationStorage=t.annotationStorage||null,this._optionalContentConfigPromise=t.optionalContentConfigPromise||null,this.hasRestrictedScaling=!1,this.textLayerMode=Number.isInteger(t.textLayerMode)?t.textLayerMode:a.TextLayerMode.ENABLE,this.imageResourcesPath=t.imageResourcesPath||"",this.renderInteractiveForms="boolean"!=typeof t.renderInteractiveForms||t.renderInteractiveForms,this.useOnlyCssZoom=t.useOnlyCssZoom||!1,this.maxCanvasPixels=t.maxCanvasPixels||h,this.eventBus=t.eventBus,this.renderingQueue=t.renderingQueue,this.textLayerFactory=t.textLayerFactory,this.annotationLayerFactory=t.annotationLayerFactory,this.renderer=t.renderer||a.RendererType.CANVAS,this.enableWebGL=t.enableWebGL||!1,this.l10n=t.l10n||a.NullL10n,this.paintTask=null,this.paintedViewportMap=new WeakMap,this.renderingState=s.RenderingStates.INITIAL,this.resume=null,this.error=null,this.annotationLayer=null,this.textLayer=null,this.zoomLayer=null,t=document.createElement("div"),t.className="page",t.style.width=Math.floor(this.viewport.width)+"px",t.style.height=Math.floor(this.viewport.height)+"px",t.setAttribute("data-page-number",this.id),this.div=t,r.appendChild(t)}var t,r,n,u;return t=e,(r=[{key:"setPdfPage",value:function(e){this.pdfPage=e,this.pdfPageRotate=e.rotate;var t=(this.rotation+this.pdfPageRotate)%360;this.viewport=e.getViewport({scale:this.scale*a.CSS_UNITS,rotation:t}),this.stats=e.stats,this.reset()}},{key:"destroy",value:function(){this.reset(),this.pdfPage&&this.pdfPage.cleanup()}},{key:"_renderAnnotationLayer",value:(u=l(i.default.mark((function e(){var t;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=null,e.prev=1,e.next=4,this.annotationLayer.render(this.viewport,"display");case 4:e.next=9;break;case 6:e.prev=6,e.t0=e.catch(1),t=e.t0;case 9:return e.prev=9,this.eventBus.dispatch("annotationlayerrendered",{source:this,pageNumber:this.id,error:t}),e.finish(9);case 12:case"end":return e.stop()}}),e,this,[[1,6,9,12]])}))),function(){return u.apply(this,arguments)})},{key:"_resetZoomLayer",value:function(){var e,t=0<arguments.length&&void 0!==arguments[0]&&arguments[0];this.zoomLayer&&(e=this.zoomLayer.firstChild,this.paintedViewportMap.delete(e),e.width=0,e.height=0,t&&this.zoomLayer.remove(),this.zoomLayer=null)}},{key:"reset",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=1<arguments.length&&void 0!==arguments[1]&&arguments[1];this.cancelRendering(t),this.renderingState=s.RenderingStates.INITIAL;var r=this.div;r.style.width=Math.floor(this.viewport.width)+"px",r.style.height=Math.floor(this.viewport.height)+"px";for(var n=r.childNodes,i=e&&this.zoomLayer||null,a=t&&this.annotationLayer&&this.annotationLayer.div||null,o=n.length-1;0<=o;o--){var u=n[o];i!==u&&a!==u&&r.removeChild(u)}r.removeAttribute("data-loaded"),a?this.annotationLayer.hide():this.annotationLayer&&(this.annotationLayer.cancel(),this.annotationLayer=null),i||(this.canvas&&(this.paintedViewportMap.delete(this.canvas),this.canvas.width=0,this.canvas.height=0,delete this.canvas),this._resetZoomLayer()),this.svg&&(this.paintedViewportMap.delete(this.svg),delete this.svg),this.loadingIconDiv=document.createElement("div"),this.loadingIconDiv.className="loadingIcon",r.appendChild(this.loadingIconDiv)}},{key:"update",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(this.scale=e||this.scale,void 0!==t&&(this.rotation=t),r instanceof Promise&&(this._optionalContentConfigPromise=r),t=(this.rotation+this.pdfPageRotate)%360,this.viewport=this.viewport.clone({scale:this.scale*a.CSS_UNITS,rotation:t}),this.svg)return this.cssTransform(this.svg,!0),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now()});if(r=!1,this.canvas&&0<this.maxCanvasPixels&&(t=this.outputScale,(Math.floor(this.viewport.width)*t.sx|0)*(Math.floor(this.viewport.height)*t.sy|0)>this.maxCanvasPixels&&(r=!0)),this.canvas){if(this.useOnlyCssZoom||this.hasRestrictedScaling&&r)return this.cssTransform(this.canvas,!0),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now()});this.zoomLayer||this.canvas.hasAttribute("hidden")||(this.zoomLayer=this.canvas.parentNode,this.zoomLayer.style.position="absolute")}this.zoomLayer&&this.cssTransform(this.zoomLayer.firstChild),this.reset(!0,!0)}},{key:"cancelRendering",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];this.paintTask&&(this.paintTask.cancel(),this.paintTask=null),this.resume=null,this.textLayer&&(this.textLayer.cancel(),this.textLayer=null),!e&&this.annotationLayer&&(this.annotationLayer.cancel(),this.annotationLayer=null)}},{key:"cssTransform",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1],r=this.viewport.width,n=this.viewport.height,i=this.div;e.style.width=e.parentNode.style.width=i.style.width=Math.floor(r)+"px",e.style.height=e.parentNode.style.height=i.style.height=Math.floor(n)+"px";var a=this.viewport.rotation-this.paintedViewportMap.get(e).rotation,o=Math.abs(a),s=1;i=1;if(90!==o&&270!==o||(s=n/r,i=r/n),e.style.transform="rotate("+a+"deg) scale("+s+","+i+")",this.textLayer){a=this.textLayer.viewport,s=this.viewport.rotation-a.rotation,i=Math.abs(s),s=r/a.width,90!==i&&270!==i||(s=r/a.height);var u,l,c=this.textLayer.textLayerDiv;switch(i){case 0:u=l=0;break;case 90:u=0,l="-"+c.style.height;break;case 180:u="-"+c.style.width,l="-"+c.style.height;break;case 270:u="-"+c.style.width,l=0}c.style.transform="rotate("+i+"deg) scale("+s+", "+s+") translate("+u+", "+l+")",c.style.transformOrigin="0% 0%"}t&&this.annotationLayer&&this._renderAnnotationLayer()}},{key:"getPagePoint",value:function(e,t){return this.viewport.convertToPdfPoint(e,t)}},{key:"draw",value:function(){var e=this;this.renderingState!==s.RenderingStates.INITIAL&&this.reset();var t=this.div,r=this.pdfPage;if(!r)return this.renderingState=s.RenderingStates.FINISHED,this.loadingIconDiv&&(t.removeChild(this.loadingIconDiv),delete this.loadingIconDiv),Promise.reject(new Error("pdfPage is not loaded"));this.renderingState=s.RenderingStates.RUNNING;var n=document.createElement("div");n.style.width=t.style.width,n.style.height=t.style.height,n.classList.add("canvasWrapper"),this.annotationLayer&&this.annotationLayer.div?t.insertBefore(n,this.annotationLayer.div):t.appendChild(n);var u=null;this.textLayerMode!==a.TextLayerMode.DISABLE&&this.textLayerFactory&&((c=document.createElement("div")).className="textLayer",c.style.width=n.style.width,c.style.height=n.style.height,this.annotationLayer&&this.annotationLayer.div?t.insertBefore(c,this.annotationLayer.div):t.appendChild(c),u=this.textLayerFactory.createTextLayerBuilder(c,this.id-1,this.viewport,this.textLayerMode===a.TextLayerMode.ENABLE_ENHANCE,this.eventBus)),this.textLayer=u;var c=null;this.renderingQueue&&(c=function(t){if(!e.renderingQueue.isHighestPriority(e))return e.renderingState=s.RenderingStates.PAUSED,void(e.resume=function(){e.renderingState=s.RenderingStates.RUNNING,t()});t()});var h=function(){var n=l(i.default.mark((function n(a){return i.default.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(f===e.paintTask&&(e.paintTask=null),a instanceof o.RenderingCancelledException)return e.error=null,n.abrupt("return");n.next=4;break;case 4:if(e.renderingState=s.RenderingStates.FINISHED,e.loadingIconDiv&&(t.removeChild(e.loadingIconDiv),delete e.loadingIconDiv),e._resetZoomLayer(!0),e.error=a,e.stats=r.stats,e.eventBus.dispatch("pagerendered",{source:e,pageNumber:e.id,cssTransform:!1,timestamp:performance.now()}),a)throw a;n.next=12;break;case 12:case"end":return n.stop()}}),n)})));return function(e){return n.apply(this,arguments)}}(),f=this.renderer===a.RendererType.SVG?this.paintOnSvg(n):this.paintOnCanvas(n);return f.onRenderContinue=c,c=(this.paintTask=f).promise.then((function(){return h(null).then((function(){var e;u&&(e=r.streamTextContent({normalizeWhitespace:!0}),u.setTextContentStream(e),u.render())}))}),(function(e){return h(e)})),this.annotationLayerFactory&&(this.annotationLayer||(this.annotationLayer=this.annotationLayerFactory.createAnnotationLayerBuilder(t,r,this._annotationStorage,this.imageResourcesPath,this.renderInteractiveForms,this.l10n)),this._renderAnnotationLayer()),t.setAttribute("data-loaded",!0),this.eventBus.dispatch("pagerender",{source:this,pageNumber:this.id}),c}},{key:"paintOnCanvas",value:function(e){var t=(0,o.createPromiseCapability)(),r={promise:t.promise,onRenderContinue:function(e){e()},cancel:function(){d.cancel()}},n=this.viewport,i=document.createElement("canvas");function s(){u&&(i.removeAttribute("hidden"),u=!1)}this.l10n.get("page_canvas",{page:this.id},"Page {{page}}").then((function(e){i.setAttribute("aria-label",e)})),i.setAttribute("hidden","hidden");var u=!0;e.appendChild(i),(this.canvas=i).mozOpaque=!0;var l=i.getContext("2d",{alpha:!1}),c=(0,a.getOutputScale)(l);this.outputScale=c,this.useOnlyCssZoom&&(e=n.clone({scale:a.CSS_UNITS}),c.sx*=e.width/n.width,c.sy*=e.height/n.height,c.scaled=!0),0<this.maxCanvasPixels&&(h=n.width*n.height,f=Math.sqrt(this.maxCanvasPixels/h),c.sx>f||c.sy>f?(c.sx=f,c.sy=f,c.scaled=!0,this.hasRestrictedScaling=!0):this.hasRestrictedScaling=!1);var h=(0,a.approximateFraction)(c.sx),f=(0,a.approximateFraction)(c.sy);i.width=(0,a.roundToDivide)(n.width*c.sx,h[0]),i.height=(0,a.roundToDivide)(n.height*c.sy,f[0]),i.style.width=(0,a.roundToDivide)(n.width,h[1])+"px",i.style.height=(0,a.roundToDivide)(n.height,f[1])+"px",this.paintedViewportMap.set(i,n);c={canvasContext:l,transform:c.scaled?[c.sx,0,0,c.sy,0,0]:null,viewport:this.viewport,enableWebGL:this.enableWebGL,renderInteractiveForms:this.renderInteractiveForms,optionalContentConfigPromise:this._optionalContentConfigPromise};var d=this.pdfPage.render(c);return d.onContinue=function(e){s(),r.onRenderContinue?r.onRenderContinue(e):e()},d.promise.then((function(){s(),t.resolve(void 0)}),(function(e){s(),t.reject(e)})),r}},{key:"paintOnSvg",value:function(e){function t(){if(n)throw new o.RenderingCancelledException("Rendering cancelled, page ".concat(r.id),"svg")}var r=this,n=!1,i=this.pdfPage,u=this.viewport.clone({scale:a.CSS_UNITS});return{promise:i.getOperatorList().then((function(n){return t(),new o.SVGGraphics(i.commonObjs,i.objs).getSVG(n,u).then((function(n){t(),r.svg=n,r.paintedViewportMap.set(n,u),n.style.width=e.style.width,n.style.height=e.style.height,r.renderingState=s.RenderingStates.FINISHED,e.appendChild(n)}))})),onRenderContinue:function(e){e()},cancel:function(){n=!0}}}},{key:"setPageLabel",value:function(e){this.pageLabel="string"==typeof e?e:null,null!==this.pageLabel?this.div.setAttribute("data-page-label",this.pageLabel):this.div.removeAttribute("data-page-label")}},{key:"width",get:function(){return this.viewport.width}},{key:"height",get:function(){return this.viewport.height}}])&&c(t.prototype,r),n&&c(t,n),e}()},function(e,t,r){"use strict";function n(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,n.key,n)}}Object.defineProperty(t,"__esModule",{value:!0}),t.PDFRenderingQueue=t.RenderingStates=void 0;var i={INITIAL:0,RUNNING:1,PAUSED:2,FINISHED:3};t.RenderingStates=i,t.PDFRenderingQueue=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.pdfViewer=null,this.pdfThumbnailViewer=null,this.onIdle=null,this.highestPriorityPage=null,this.idleTimeout=null,this.printing=!1,this.isThumbnailViewEnabled=!1}var t,r,a;return t=e,(r=[{key:"setViewer",value:function(e){this.pdfViewer=e}},{key:"setThumbnailViewer",value:function(e){this.pdfThumbnailViewer=e}},{key:"isHighestPriority",value:function(e){return this.highestPriorityPage===e.renderingId}},{key:"renderHighestPriority",value:function(e){this.idleTimeout&&(clearTimeout(this.idleTimeout),this.idleTimeout=null),this.pdfViewer.forceRendering(e)||this.pdfThumbnailViewer&&this.isThumbnailViewEnabled&&this.pdfThumbnailViewer.forceRendering()||this.printing||this.onIdle&&(this.idleTimeout=setTimeout(this.onIdle.bind(this),3e4))}},{key:"getHighestPriority",value:function(e,t,r){var n=e.views,i=n.length;if(0===i)return null;for(var a=0;a<i;++a){var o=n[a].view;if(!this.isViewFinished(o))return o}if(r){if(r=e.last.id,t[r]&&!this.isViewFinished(t[r]))return t[r]}else if(e=e.first.id-2,t[e]&&!this.isViewFinished(t[e]))return t[e];return null}},{key:"isViewFinished",value:function(e){return e.renderingState===i.FINISHED}},{key:"renderView",value:function(e){var t=this;switch(e.renderingState){case i.FINISHED:return!1;case i.PAUSED:this.highestPriorityPage=e.renderingId,e.resume();break;case i.RUNNING:this.highestPriorityPage=e.renderingId;break;case i.INITIAL:this.highestPriorityPage=e.renderingId,e.draw().finally((function(){t.renderHighestPriority()})).catch((function(e){}))}return!0}}])&&n(t.prototype,r),a&&n(t,a),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFSinglePageViewer=void 0;var n=r(19),i=r(2);function a(e){return(a="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)}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,n.key,n)}}function s(e,t,r){return(s="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,r){if(e=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=c(e)););return e}(e,t),e)return t=Object.getOwnPropertyDescriptor(e,t),t.get?t.get.call(r):t.value})(e,t,r||e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=c(t);return e=r?(e=c(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==a(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}t.PDFSinglePageViewer=function(){!function(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}}),t&&u(e,t)}(h,n.BaseViewer);var e,t,r,a=l(h);function h(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,h),(t=a.call(this,e)).eventBus._on("pagesinit",(function(e){t._ensurePageViewVisible()})),t}return e=h,(t=[{key:"_resetView",value:function(){s(c(h.prototype),"_resetView",this).call(this),this._previousPageNumber=1,this._shadowViewer=document.createDocumentFragment(),this._updateScrollDown=null}},{key:"_ensurePageViewVisible",value:function(){var e=this._pages[this._currentPageNumber-1],t=this._pages[this._previousPageNumber-1],r=this.viewer.childNodes;switch(r.length){case 0:this.viewer.appendChild(e.div);break;case 1:if(r[0]!==t.div)throw new Error("_ensurePageViewVisible: Unexpected previously visible page.");if(e===t)break;this._shadowViewer.appendChild(t.div),this.viewer.appendChild(e.div),this.container.scrollTop=0;break;default:throw new Error("_ensurePageViewVisible: Only one page should be visible at a time.")}this._previousPageNumber=this._currentPageNumber}},{key:"_scrollUpdate",value:function(){this._updateScrollDown&&this._updateScrollDown(),s(c(h.prototype),"_scrollUpdate",this).call(this)}},{key:"_scrollIntoView",value:function(e){var t=this,r=e.pageDiv,n=e.pageSpot;n=void 0===n?null:n,e=e.pageNumber,e=void 0===e?null:e;e&&this._setCurrentPageNumber(e);var i=this._currentPageNumber>=this._previousPageNumber;this._ensurePageViewVisible(),this.update(),s(c(h.prototype),"_scrollIntoView",this).call(this,{pageDiv:r,pageSpot:n,pageNumber:e}),this._updateScrollDown=function(){t.scroll.down=i,t._updateScrollDown=null}}},{key:"_getVisiblePages",value:function(){return this._getCurrentVisiblePage()}},{key:"_updateHelper",value:function(e){}},{key:"_updateScrollMode",value:function(){}},{key:"_updateSpreadMode",value:function(){}},{key:"_viewerElement",get:function(){return(0,i.shadow)(this,"_viewerElement",this._shadowViewer)}},{key:"_isScrollModeHorizontal",get:function(){return(0,i.shadow)(this,"_isScrollModeHorizontal",!1)}}])&&o(e.prototype,t),r&&o(e,r),h}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseViewer=void 0;var n=r(3),i=r(17),a=r(1),o=r(2),s=r(16),u=r(7),l=r(8);function c(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return h(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?h(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function h(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 f(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,n.key,n)}}function d(e){var t=[];this.push=function(r){var n=t.indexOf(r);0<=n&&t.splice(n,1),t.push(r),t.length>e&&t.shift().destroy()},this.resize=function(r,i){if(e=r,i){for(var a=new Set,o=0,s=i.length;o<s;++o)a.add(i[o].id);(0,n.moveToEndOfArray)(t,(function(e){return a.has(e.id)}))}for(;t.length>e;)t.shift().destroy()}}t.BaseViewer=function(){function e(t){var r=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.constructor===e)throw new Error("Cannot initialize BaseViewer.");if(this._name=this.constructor.name,this.container=t.container,this.viewer=t.viewer||t.container.firstElementChild,!(this.container instanceof HTMLDivElement&&this.viewer instanceof HTMLDivElement))throw new Error("Invalid `container` and/or `viewer` option.");this.eventBus=t.eventBus,this.linkService=t.linkService||new u.SimpleLinkService,this.downloadManager=t.downloadManager||null,this.findController=t.findController||null,this.removePageBorders=t.removePageBorders||!1,this.textLayerMode=Number.isInteger(t.textLayerMode)?t.textLayerMode:n.TextLayerMode.ENABLE,this.imageResourcesPath=t.imageResourcesPath||"",this.renderInteractiveForms="boolean"!=typeof t.renderInteractiveForms||t.renderInteractiveForms,this.enablePrintAutoRotate=t.enablePrintAutoRotate||!1,this.renderer=t.renderer||n.RendererType.CANVAS,this.enableWebGL=t.enableWebGL||!1,this.useOnlyCssZoom=t.useOnlyCssZoom||!1,this.maxCanvasPixels=t.maxCanvasPixels,this.l10n=t.l10n||n.NullL10n,this.defaultRenderingQueue=!t.renderingQueue,this.defaultRenderingQueue?(this.renderingQueue=new i.PDFRenderingQueue,this.renderingQueue.setViewer(this)):this.renderingQueue=t.renderingQueue,this.scroll=(0,n.watchScroll)(this.container,this._scrollUpdate.bind(this)),this.presentationModeState=n.PresentationModeState.UNKNOWN,this._onBeforeDraw=this._onAfterDraw=null,this._resetView(),this.removePageBorders&&this.viewer.classList.add("removePageBorders"),Promise.resolve().then((function(){r.eventBus.dispatch("baseviewerinit",{source:r})}))}var t,r,h;return t=e,(r=[{key:"getPageView",value:function(e){return this._pages[e]}},{key:"_setCurrentPageNumber",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1];return this._currentPageNumber===e?(t&&this._resetCurrentPageView(),!0):0<e&&e<=this.pagesCount&&(this._currentPageNumber=e,this.eventBus.dispatch("pagechanging",{source:this,pageNumber:e,pageLabel:this._pageLabels&&this._pageLabels[e-1]}),t&&this._resetCurrentPageView(),!0)}},{key:"_onePageRenderedOrForceFetch",value:function(){return this.container.offsetParent&&0!==this._getVisiblePages().views.length?this._onePageRenderedCapability.promise:Promise.resolve()}},{key:"setDocument",value:function(e){var t,r,i,a,o=this;this.pdfDocument&&(this._cancelRendering(),this._resetView(),this.findController&&this.findController.setDocument(null)),(this.pdfDocument=e)&&(t=e.numPages,r=e.getPage(1),i=e.annotationStorage,a=e.getOptionalContentConfig(),this._pagesCapability.promise.then((function(){o.eventBus.dispatch("pagesloaded",{source:o,pagesCount:t})})),this._onBeforeDraw=function(e){e=o._pages[e.pageNumber-1],e&&o._buffer.push(e)},this.eventBus._on("pagerender",this._onBeforeDraw),this._onAfterDraw=function(e){e.cssTransform||o._onePageRenderedCapability.settled||(o._onePageRenderedCapability.resolve(),o.eventBus._off("pagerendered",o._onAfterDraw),o._onAfterDraw=null)},this.eventBus._on("pagerendered",this._onAfterDraw),r.then((function(r){o._firstPageCapability.resolve(r),o._optionalContentConfigPromise=a;for(var u=o.currentScale,l=r.getViewport({scale:u*n.CSS_UNITS}),c=o.textLayerMode!==n.TextLayerMode.DISABLE?o:null,h=1;h<=t;++h){var f=new s.PDFPageView({container:o._viewerElement,eventBus:o.eventBus,id:h,scale:u,defaultViewport:l.clone(),annotationStorage:i,optionalContentConfigPromise:a,renderingQueue:o.renderingQueue,textLayerFactory:c,textLayerMode:o.textLayerMode,annotationLayerFactory:o,imageResourcesPath:o.imageResourcesPath,renderInteractiveForms:o.renderInteractiveForms,renderer:o.renderer,enableWebGL:o.enableWebGL,useOnlyCssZoom:o.useOnlyCssZoom,maxCanvasPixels:o.maxCanvasPixels,l10n:o.l10n});o._pages.push(f)}var d=o._pages[0];d&&(d.setPdfPage(r),o.linkService.cachePageRef(1,r.ref)),o._spreadMode!==n.SpreadMode.NONE&&o._updateSpreadMode(),o._onePageRenderedOrForceFetch().then((function(){if(o.findController&&o.findController.setDocument(e),e.loadingParams.disableAutoFetch||7500<t)o._pagesCapability.resolve();else{var r=t-1;if(r<=0)o._pagesCapability.resolve();else for(var n=2;n<=t;++n)!function(t){e.getPage(t).then((function(e){var n=o._pages[t-1];n.pdfPage||n.setPdfPage(e),o.linkService.cachePageRef(t,e.ref),0==--r&&o._pagesCapability.resolve()}),(function(e){0==--r&&o._pagesCapability.resolve()}))}(n)}})),o.eventBus.dispatch("pagesinit",{source:o}),o.defaultRenderingQueue&&o.update()})).catch((function(e){})))}},{key:"setPageLabels",value:function(e){if(this.pdfDocument){e&&Array.isArray(e)&&this.pdfDocument.numPages===e.length?this._pageLabels=e:this._pageLabels=null;for(var t=0,r=this._pages.length;t<r;t++){var n=this._pages[t],i=this._pageLabels&&this._pageLabels[t];n.setPageLabel(i)}}}},{key:"_resetView",value:function(){this._pages=[],this._currentPageNumber=1,this._currentScale=n.UNKNOWN_SCALE,this._currentScaleValue=null,this._pageLabels=null,this._buffer=new d(10),this._location=null,this._pagesRotation=0,this._optionalContentConfigPromise=null,this._pagesRequests=new WeakMap,this._firstPageCapability=(0,o.createPromiseCapability)(),this._onePageRenderedCapability=(0,o.createPromiseCapability)(),this._pagesCapability=(0,o.createPromiseCapability)(),this._scrollMode=n.ScrollMode.VERTICAL,this._spreadMode=n.SpreadMode.NONE,this._onBeforeDraw&&(this.eventBus._off("pagerender",this._onBeforeDraw),this._onBeforeDraw=null),this._onAfterDraw&&(this.eventBus._off("pagerendered",this._onAfterDraw),this._onAfterDraw=null),this.viewer.textContent="",this._updateScrollMode()}},{key:"_scrollUpdate",value:function(){0!==this.pagesCount&&this.update()}},{key:"_scrollIntoView",value:function(e){var t=e.pageDiv,r=e.pageSpot;e=e.pageNumber;(0,n.scrollIntoView)(t,void 0===r?null:r)}},{key:"_setScaleUpdatePages",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]&&arguments[2],n=3<arguments.length&&void 0!==arguments[3]&&arguments[3];if(this._currentScaleValue=t.toString(),i=this._currentScale,(a=e)===i||Math.abs(a-i)<1e-15)n&&this.eventBus.dispatch("scalechanging",{source:this,scale:e,presetValue:t});else{for(var i,a,o,s=0,u=this._pages.length;s<u;s++)this._pages[s].update(e);this._currentScale=e,r||(r=this._currentPageNumber,!this._location||this.isInPresentationMode||this.isChangingPresentationMode||(r=this._location.pageNumber,o=[null,{name:"XYZ"},this._location.left,this._location.top,null]),this.scrollPageIntoView({pageNumber:r,destArray:o,allowNegativeOffset:!0})),this.eventBus.dispatch("scalechanging",{source:this,scale:e,presetValue:n?t:void 0}),this.defaultRenderingQueue&&this.update()}}},{key:"_setScale",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1];if(0<(c=parseFloat(e)))this._setScaleUpdatePages(c,e,t,!1);else{var r=this._pages[this._currentPageNumber-1];if(r){var i=this.isInPresentationMode||this.removePageBorders,a=i?0:n.SCROLLBAR_PADDING,o=i?0:n.VERTICAL_PADDING;!i&&this._isScrollModeHorizontal&&(a=(i=[o,a])[0],o=i[1]);var s=(this.container.clientWidth-a)/r.width*r.scale,u=(this.container.clientHeight-o)/r.height*r.scale;switch(e){case"page-actual":c=1;break;case"page-width":c=s;break;case"page-height":c=u;break;case"page-fit":c=Math.min(s,u);break;case"auto":var l=(0,n.isPortraitOrientation)(r)?s:Math.min(u,s),c=Math.min(n.MAX_AUTO_SCALE,l);break;default:return}this._setScaleUpdatePages(c,e,t,!0)}}}},{key:"_resetCurrentPageView",value:function(){this.isInPresentationMode&&this._setScale(this._currentScaleValue,!0);var e=this._pages[this._currentPageNumber-1];this._scrollIntoView({pageDiv:e.div})}},{key:"scrollPageIntoView",value:function(e){var t=e.pageNumber,r=e.destArray,i=void 0===r?null:r,a=e.allowNegativeOffset,o=void 0!==a&&a;r=e.ignoreDestinationZoom,a=void 0!==r&&r;if(this.pdfDocument&&(e=Number.isInteger(t)&&this._pages[t-1],e))if(!this.isInPresentationMode&&i){var s=0,u=0,l=0,c=0,h=(r=e.rotation%180!=0,(r?e.height:e.width)/e.scale/n.CSS_UNITS),f=(r?e.width:e.height)/e.scale/n.CSS_UNITS,d=0;switch(i[1].name){case"XYZ":s=i[2],u=i[3],d=i[4],s=null!==s?s:0,u=null!==u?u:f;break;case"Fit":case"FitB":d="page-fit";break;case"FitH":case"FitBH":d="page-width",null===(u=i[2])&&this._location&&(s=this._location.left,u=this._location.top);break;case"FitV":case"FitBV":s=i[2],l=h,c=f,d="page-height";break;case"FitR":s=i[2],u=i[3],l=i[4]-s,c=i[5]-u;var p=this.removePageBorders?0:n.SCROLLBAR_PADDING,v=this.removePageBorders?0:n.VERTICAL_PADDING;p=(this.container.clientWidth-p)/l/n.CSS_UNITS,v=(this.container.clientHeight-v)/c/n.CSS_UNITS,d=Math.min(Math.abs(p),Math.abs(v));break;default:return}a||(d&&d!==this._currentScale?this.currentScaleValue=d:this._currentScale===n.UNKNOWN_SCALE&&(this.currentScaleValue=n.DEFAULT_SCALE_VALUE)),"page-fit"!==d||i[4]?(r=[e.viewport.convertToViewportPoint(s,u),e.viewport.convertToViewportPoint(s+l,u+c)],a=Math.min(r[0][0],r[1][0]),r=Math.min(r[0][1],r[1][1]),o||(a=Math.max(a,0),r=Math.max(r,0)),this._scrollIntoView({pageDiv:e.div,pageSpot:{left:a,top:r},pageNumber:t})):this._scrollIntoView({pageDiv:e.div,pageNumber:t})}else this._setCurrentPageNumber(t,!0)}},{key:"_updateLocation",value:function(e){var t=this._currentScale,r=this._currentScaleValue,n=parseFloat(r)===t?Math.round(1e4*t)/100:r,i=e.id,a="#page="+i;a+="&zoom="+n,t=this._pages[i-1],r=this.container,r=t.getPagePoint(r.scrollLeft-e.x,r.scrollTop-e.y),e=Math.round(r[0]),r=Math.round(r[1]),this._location={pageNumber:i,scale:n,top:r,left:e,rotation:this._pagesRotation,pdfOpenParams:a+=","+e+","+r}}},{key:"_updateHelper",value:function(e){throw new Error("Not implemented: _updateHelper")}},{key:"update",value:function(){var e=this._getVisiblePages(),t=e.views,r=t.length;0!==r&&(r=Math.max(10,2*r+1),this._buffer.resize(r,t),this.renderingQueue.renderHighestPriority(e),this._updateHelper(t),this._updateLocation(e.first),this.eventBus.dispatch("updateviewarea",{source:this,location:this._location}))}},{key:"containsElement",value:function(e){return this.container.contains(e)}},{key:"focus",value:function(){this.container.focus()}},{key:"_getCurrentVisiblePage",value:function(){if(!this.pagesCount)return{views:[]};var e=this._pages[this._currentPageNumber-1],t=e.div;e={id:e.id,x:t.offsetLeft+t.clientLeft,y:t.offsetTop+t.clientTop,view:e};return{first:e,last:e,views:[e]}}},{key:"_getVisiblePages",value:function(){return(0,n.getVisibleElements)(this.container,this._pages,!0,this._isScrollModeHorizontal)}},{key:"isPageVisible",value:function(e){return!!this.pdfDocument&&!(e<1||e>this.pagesCount)&&this._getVisiblePages().views.some((function(t){return t.id===e}))}},{key:"cleanup",value:function(){for(var e=0,t=this._pages.length;e<t;e++)this._pages[e]&&this._pages[e].renderingState!==i.RenderingStates.FINISHED&&this._pages[e].reset()}},{key:"_cancelRendering",value:function(){for(var e=0,t=this._pages.length;e<t;e++)this._pages[e]&&this._pages[e].cancelRendering()}},{key:"_ensurePdfPageLoaded",value:function(e){var t=this;if(e.pdfPage)return Promise.resolve(e.pdfPage);if(this._pagesRequests.has(e))return this._pagesRequests.get(e);var r=this.pdfDocument.getPage(e.id).then((function(r){return e.pdfPage||e.setPdfPage(r),t._pagesRequests.delete(e),r})).catch((function(r){t._pagesRequests.delete(e)}));return this._pagesRequests.set(e,r),r}},{key:"forceRendering",value:function(e){var t=this,r=e||this._getVisiblePages(),n=(e=this._isScrollModeHorizontal?this.scroll.right:this.scroll.down,this.renderingQueue.getHighestPriority(r,this._pages,e));return!!n&&(this._ensurePdfPageLoaded(n).then((function(){t.renderingQueue.renderView(n)})),!0)}},{key:"createTextLayerBuilder",value:function(e,t,r){var n=3<arguments.length&&void 0!==arguments[3]&&arguments[3];return new l.TextLayerBuilder({textLayerDiv:e,eventBus:4<arguments.length?arguments[4]:void 0,pageIndex:t,viewport:r,findController:this.isInPresentationMode?null:this.findController,enhanceTextSelection:!this.isInPresentationMode&&n})}},{key:"createAnnotationLayerBuilder",value:function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,i=3<arguments.length&&void 0!==arguments[3]?arguments[3]:"",o=4<arguments.length&&void 0!==arguments[4]&&arguments[4],s=5<arguments.length&&void 0!==arguments[5]?arguments[5]:n.NullL10n;return new a.AnnotationLayerBuilder({pageDiv:e,pdfPage:t,annotationStorage:r,imageResourcesPath:i,renderInteractiveForms:o,linkService:this.linkService,downloadManager:this.downloadManager,l10n:s})}},{key:"getPagesOverview",value:function(){var e=this._pages.map((function(e){return e=e.pdfPage.getViewport({scale:1}),{width:e.width,height:e.height,rotation:e.rotation}}));return this.enablePrintAutoRotate?e.map((function(e){return(0,n.isPortraitOrientation)(e)?e:{width:e.height,height:e.width,rotation:(e.rotation+90)%360}})):e}},{key:"_updateScrollMode",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=this._scrollMode,r=this.viewer;r.classList.toggle("scrollHorizontal",t===n.ScrollMode.HORIZONTAL),r.classList.toggle("scrollWrapped",t===n.ScrollMode.WRAPPED),this.pdfDocument&&e&&(this._currentScaleValue&&isNaN(this._currentScaleValue)&&this._setScale(this._currentScaleValue,!0),this._setCurrentPageNumber(e,!0),this.update())}},{key:"_updateSpreadMode",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;if(this.pdfDocument){var t=this.viewer,r=this._pages;if(t.textContent="",this._spreadMode===n.SpreadMode.NONE)for(var i=0,a=r.length;i<a;++i)t.appendChild(r[i].div);else for(var o=this._spreadMode-1,s=null,u=0,l=r.length;u<l;++u)null===s?((s=document.createElement("div")).className="spread",t.appendChild(s)):u%2==o&&(s=s.cloneNode(!1),t.appendChild(s)),s.appendChild(r[u].div);e&&(this._setCurrentPageNumber(e,!0),this.update())}}},{key:"pagesCount",get:function(){return this._pages.length}},{key:"pageViewsReady",get:function(){return!!this._pagesCapability.settled&&this._pages.every((function(e){return e&&e.pdfPage}))}},{key:"currentPageNumber",get:function(){return this._currentPageNumber},set:function(e){if(!Number.isInteger(e))throw new Error("Invalid page number.");this.pdfDocument&&this._setCurrentPageNumber(e,!0)}},{key:"currentPageLabel",get:function(){return this._pageLabels&&this._pageLabels[this._currentPageNumber-1]},set:function(e){var t;this.pdfDocument&&(t=0|e,!this._pageLabels||0<=(e=this._pageLabels.indexOf(e))&&(t=e+1),this._setCurrentPageNumber(t,!0))}},{key:"currentScale",get:function(){return this._currentScale!==n.UNKNOWN_SCALE?this._currentScale:n.DEFAULT_SCALE},set:function(e){if(isNaN(e))throw new Error("Invalid numeric scale.");this.pdfDocument&&this._setScale(e,!1)}},{key:"currentScaleValue",get:function(){return this._currentScaleValue},set:function(e){this.pdfDocument&&this._setScale(e,!1)}},{key:"pagesRotation",get:function(){return this._pagesRotation},set:function(e){if(!(0,n.isValidRotation)(e))throw new Error("Invalid pages rotation angle.");if(this.pdfDocument&&this._pagesRotation!==e){this._pagesRotation=e;for(var t=this._currentPageNumber,r=0,i=this._pages.length;r<i;r++){var a=this._pages[r];a.update(a.scale,e)}this._currentScaleValue&&this._setScale(this._currentScaleValue,!0),this.eventBus.dispatch("rotationchanging",{source:this,pagesRotation:e,pageNumber:t}),this.defaultRenderingQueue&&this.update()}}},{key:"firstPagePromise",get:function(){return this.pdfDocument?this._firstPageCapability.promise:null}},{key:"onePageRendered",get:function(){return this.pdfDocument?this._onePageRenderedCapability.promise:null}},{key:"pagesPromise",get:function(){return this.pdfDocument?this._pagesCapability.promise:null}},{key:"_viewerElement",get:function(){throw new Error("Not implemented: _viewerElement")}},{key:"_isScrollModeHorizontal",get:function(){return!this.isInPresentationMode&&this._scrollMode===n.ScrollMode.HORIZONTAL}},{key:"isInPresentationMode",get:function(){return this.presentationModeState===n.PresentationModeState.FULLSCREEN}},{key:"isChangingPresentationMode",get:function(){return this.presentationModeState===n.PresentationModeState.CHANGING}},{key:"isHorizontalScrollbarEnabled",get:function(){return!this.isInPresentationMode&&this.container.scrollWidth>this.container.clientWidth}},{key:"isVerticalScrollbarEnabled",get:function(){return!this.isInPresentationMode&&this.container.scrollHeight>this.container.clientHeight}},{key:"hasEqualPageSizes",get:function(){for(var e=this._pages[0],t=1,r=this._pages.length;t<r;++t){var n=this._pages[t];if(n.width!==e.width||n.height!==e.height)return!1}return!0}},{key:"optionalContentConfigPromise",get:function(){return this.pdfDocument?this._optionalContentConfigPromise||this.pdfDocument.getOptionalContentConfig():Promise.resolve(null)},set:function(e){if(!(e instanceof Promise))throw new Error("Invalid optionalContentConfigPromise: ".concat(e));if(this.pdfDocument&&this._optionalContentConfigPromise){this._optionalContentConfigPromise=e;var t,r=c(this._pages);try{for(r.s();!(t=r.n()).done;){var n=t.value;n.update(n.scale,n.rotation,e)}}catch(e){r.e(e)}finally{r.f()}this.update(),this.eventBus.dispatch("optionalcontentconfigchanged",{source:this,promise:e})}}},{key:"scrollMode",get:function(){return this._scrollMode},set:function(e){if(this._scrollMode!==e){if(!(0,n.isValidScrollMode)(e))throw new Error("Invalid scroll mode: ".concat(e));this._scrollMode=e,this.eventBus.dispatch("scrollmodechanged",{source:this,mode:e}),this._updateScrollMode(this._currentPageNumber)}}},{key:"spreadMode",get:function(){return this._spreadMode},set:function(e){if(this._spreadMode!==e){if(!(0,n.isValidSpreadMode)(e))throw new Error("Invalid spread mode: ".concat(e));this._spreadMode=e,this.eventBus.dispatch("spreadmodechanged",{source:this,mode:e}),this._updateSpreadMode(this._currentPageNumber)}}}])&&f(t.prototype,r),h&&f(t,h),e}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFViewer=void 0;var n=r(19),i=r(2);function a(e){return(a="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)}function o(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return s(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(r="Object"===r&&e.constructor?e.constructor.name:r)||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0;t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},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.")}var i,a=!0,o=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){o=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(o)throw i}}}}function s(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 u(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,n.key,n)}}function l(e,t,r){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,r){if(e=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=f(e)););return e}(e,t),e)return t=Object.getOwnPropertyDescriptor(e,t),t.get?t.get.call(r):t.value})(e,t,r||e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var e,n=f(t);return e=r?(e=f(this).constructor,Reflect.construct(n,arguments,e)):n.apply(this,arguments),n=this,!(e=e)||"object"!==a(e)&&"function"!=typeof e?function(e){if(void 0!==e)return e;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(n):e}}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}t.PDFViewer=function(){!function(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}}),t&&c(e,t)}(s,n.BaseViewer);var e,t,r,a=h(s);function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),a.apply(this,arguments)}return e=s,(t=[{key:"_scrollIntoView",value:function(e){var t,r=e.pageDiv,n=e.pageSpot,i=void 0===n?null:n,a=e.pageNumber,o=void 0===a?null:a;i||this.isInPresentationMode||(n=(t=r.offsetLeft+r.clientLeft)+r.clientWidth,a=(e=this.container).scrollLeft,e=e.clientWidth,(this._isScrollModeHorizontal||t<a||a+e<n)&&(i={left:0,top:0})),l(f(s.prototype),"_scrollIntoView",this).call(this,{pageDiv:r,pageSpot:i,pageNumber:o})}},{key:"_getVisiblePages",value:function(){return this.isInPresentationMode?this._getCurrentVisiblePage():l(f(s.prototype),"_getVisiblePages",this).call(this)}},{key:"_updateHelper",value:function(e){if(!this.isInPresentationMode){var t,r=this._currentPageNumber,n=!1,i=o(e);try{for(i.s();!(t=i.n()).done;){var a=t.value;if(a.percent<100)break;if(a.id===r){n=!0;break}}}catch(e){i.e(e)}finally{i.f()}n||(r=e[0].id),this._setCurrentPageNumber(r)}}},{key:"_viewerElement",get:function(){return(0,i.shadow)(this,"_viewerElement",this.viewer)}}])&&u(e.prototype,t),r&&u(e,r),s}()}],e.c=n,e.d=function(t,r,n){e.o(t,r)||Object.defineProperty(t,r,{enumerable:!0,get:n})},e.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},e.t=function(t,r){if(1&r&&(t=e(t)),8&r)return t;if(4&r&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(e.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&r&&"string"!=typeof t)for(var i in t)e.d(n,i,function(e){return t[e]}.bind(null,i));return n},e.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(r,"a",r),r},e.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},e.p="",e(e.s=0);function e(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var t,n},e.exports=n()},f9a3:function(e,t,r){"use strict";r("26a4")}}]);