@drayman/elements 1.24.0 → 1.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/README.md +2 -4
  2. package/dist/button/3rdpartylicenses.txt +3 -45
  3. package/dist/button/main.js +1 -1
  4. package/dist/button/polyfills.js +1 -1
  5. package/dist/calendar/3rdpartylicenses.txt +3 -52
  6. package/dist/calendar/main.js +1 -1
  7. package/dist/calendar/polyfills.js +1 -1
  8. package/dist/calendar/styles.css +1 -1
  9. package/dist/checkbox/3rdpartylicenses.txt +3 -30
  10. package/dist/checkbox/main.js +1 -1
  11. package/dist/checkbox/polyfills.js +1 -1
  12. package/dist/claviz-charts/3rdpartylicenses.txt +1 -28
  13. package/dist/claviz-charts/main.js +1 -1
  14. package/dist/claviz-charts/polyfills.js +1 -1
  15. package/dist/code-editor/3rdpartylicenses.txt +2 -139
  16. package/dist/code-editor/main.js +1 -1
  17. package/dist/code-editor/polyfills.js +1 -1
  18. package/dist/datepicker/3rdpartylicenses.txt +3 -91
  19. package/dist/datepicker/main.js +1 -1
  20. package/dist/datepicker/polyfills.js +1 -1
  21. package/dist/file-uploader/3rdpartylicenses.txt +1 -28
  22. package/dist/file-uploader/main.js +1 -1
  23. package/dist/file-uploader/polyfills.js +1 -1
  24. package/dist/{jsondiffpatch → gauge}/3rdpartylicenses.txt +15 -38
  25. package/dist/gauge/main.js +1 -0
  26. package/dist/gauge/polyfills.js +1 -0
  27. package/dist/grid/3rdpartylicenses.txt +3 -45
  28. package/dist/grid/main.js +1 -1
  29. package/dist/grid/polyfills.js +1 -1
  30. package/dist/menu/3rdpartylicenses.txt +3 -45
  31. package/dist/menu/main.js +1 -1
  32. package/dist/menu/polyfills.js +1 -1
  33. package/dist/nebula/3rdpartylicenses.txt +24 -62
  34. package/dist/nebula/main.js +1 -1
  35. package/dist/nebula/polyfills.js +1 -1
  36. package/dist/ngx-charts/3rdpartylicenses.txt +2 -44
  37. package/dist/ngx-charts/main.js +1 -1
  38. package/dist/ngx-charts/polyfills.js +1 -1
  39. package/dist/ngx-graph/3rdpartylicenses.txt +3 -69
  40. package/dist/ngx-graph/main.js +1 -1
  41. package/dist/ngx-graph/polyfills.js +1 -1
  42. package/dist/number-field/3rdpartylicenses.txt +3 -30
  43. package/dist/number-field/main.js +1 -1
  44. package/dist/number-field/polyfills.js +1 -1
  45. package/dist/pdf-viewer/3rdpartylicenses.txt +26 -12
  46. package/dist/pdf-viewer/main.js +1 -1
  47. package/dist/pdf-viewer/polyfills.js +1 -1
  48. package/dist/radio-group/3rdpartylicenses.txt +3 -52
  49. package/dist/radio-group/main.js +1 -1
  50. package/dist/radio-group/polyfills.js +1 -1
  51. package/dist/select/3rdpartylicenses.txt +3 -30
  52. package/dist/select/main.js +1 -1
  53. package/dist/select/polyfills.js +1 -1
  54. package/dist/table/3rdpartylicenses.txt +3 -91
  55. package/dist/table/main.js +1 -1
  56. package/dist/table/polyfills.js +1 -1
  57. package/dist/text-field/3rdpartylicenses.txt +3 -45
  58. package/dist/text-field/main.js +1 -1
  59. package/dist/text-field/polyfills.js +1 -1
  60. package/dist/textarea-field/3rdpartylicenses.txt +3 -30
  61. package/dist/textarea-field/main.js +1 -1
  62. package/dist/textarea-field/polyfills.js +1 -1
  63. package/dist/timepicker/3rdpartylicenses.txt +3 -67
  64. package/dist/timepicker/main.js +1 -1
  65. package/dist/timepicker/polyfills.js +1 -1
  66. package/dist/types/checkbox/src/app/models/checkbox-options.d.ts +0 -0
  67. package/dist/types/claviz-charts/src/app/models/claviz-charts-options.d.ts +0 -0
  68. package/dist/types/datepicker/src/app/models/datepicker-options.d.ts +0 -0
  69. package/dist/types/file-uploader/src/app/models/file-uploader-options.d.ts +0 -0
  70. package/dist/types/gauge/src/app/models/gauge-options.d.ts +87 -0
  71. package/dist/types/menu/src/app/models/menu-options.d.ts +0 -0
  72. package/dist/types/nebula/src/app/models/nebula-options.d.ts +0 -0
  73. package/dist/types/ngx-charts/src/app/models/ngx-charts-options.d.ts +0 -0
  74. package/dist/types/ngx-graph/src/app/models/ngx-graph-options.d.ts +0 -0
  75. package/dist/types/number-field/src/app/models/number-field-options.d.ts +0 -0
  76. package/dist/types/pdf-viewer/src/app/models/pdf-viewer-options.d.ts +0 -0
  77. package/dist/types/radio-group/src/app/models/radio-group-options.d.ts +0 -0
  78. package/dist/types/select/src/app/models/select-options.d.ts +0 -0
  79. package/dist/types/shared/models/autocomplete-options-base.d.ts +0 -0
  80. package/dist/types/shared/models/button-options-base.d.ts +0 -0
  81. package/dist/types/shared/models/button-options.d.ts +0 -0
  82. package/dist/types/shared/models/field-options-base.d.ts +0 -0
  83. package/dist/types/shared/models/input-field-options-base.d.ts +0 -0
  84. package/dist/types/shared/models/input-mask-options-base.d.ts +0 -0
  85. package/dist/types/table/src/app/models/table-options.d.ts +0 -0
  86. package/dist/types/text-field/src/app/models/text-field-options.d.ts +0 -0
  87. package/dist/types/textarea-field/src/app/models/textarea-field-options.d.ts +0 -0
  88. package/dist/types/timepicker/src/app/models/timepicker-options.d.ts +0 -0
  89. package/dist/types/youtube-player/src/app/models/youtube-player-options.d.ts +0 -0
  90. package/dist/youtube-player/3rdpartylicenses.txt +2 -29
  91. package/dist/youtube-player/main.js +1 -1
  92. package/dist/youtube-player/polyfills.js +1 -1
  93. package/package.json +188 -183
  94. package/types/index.d.ts +35 -0
  95. package/dist/jsondiffpatch/favicon.ico +0 -0
  96. package/dist/jsondiffpatch/main.js +0 -1
  97. package/dist/jsondiffpatch/polyfills.js +0 -1
  98. package/dist/monaco-editor/3rdpartylicenses.txt +0 -406
  99. package/dist/monaco-editor/favicon.ico +0 -0
  100. package/dist/monaco-editor/main.js +0 -1
  101. package/dist/monaco-editor/polyfills.js +0 -1
  102. package/dist/monaco-editor/styles.css +0 -1
  103. package/dist/picasso/3rdpartylicenses.txt +0 -465
  104. package/dist/picasso/favicon.ico +0 -0
  105. package/dist/picasso/main.js +0 -1
  106. package/dist/picasso/polyfills.js +0 -1
  107. package/dist/picasso/styles.css +0 -0
  108. package/dist/pivot-grid/3rdpartylicenses.txt +0 -418
  109. package/dist/pivot-grid/main.js +0 -1
  110. package/dist/pivot-grid/polyfills.js +0 -1
  111. package/dist/pivot-grid/styles.css +0 -0
  112. package/dist/types/picasso/src/app/models/picasso-options.d.ts +0 -3
  113. package/dist/types/pivot-grid/src/app/models/pivot-grid-options.d.ts +0 -62
  114. /package/dist/{pivot-grid → gauge}/favicon.ico +0 -0
  115. /package/dist/{jsondiffpatch → gauge}/styles.css +0 -0
@@ -1 +1 @@
1
- !function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,(function(t){return e[t]}).bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}({0:function(e,t,n){e.exports=n("zUnb")},1:function(e,t){},2:function(e,t){},3:function(e,t){},4:function(e,t){},5:function(e,t){},LFh5:function(module,exports,__webpack_require__){var factory;factory=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,(function(t){return e[t]}).bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"addLinkAttributes",{enumerable:!0,get:function(){return r.addLinkAttributes}}),Object.defineProperty(t,"getFilenameFromUrl",{enumerable:!0,get:function(){return r.getFilenameFromUrl}}),Object.defineProperty(t,"LinkTarget",{enumerable:!0,get:function(){return r.LinkTarget}}),Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return r.loadScript}}),Object.defineProperty(t,"PDFDateString",{enumerable:!0,get:function(){return r.PDFDateString}}),Object.defineProperty(t,"RenderingCancelledException",{enumerable:!0,get:function(){return r.RenderingCancelledException}}),Object.defineProperty(t,"build",{enumerable:!0,get:function(){return i.build}}),Object.defineProperty(t,"getDocument",{enumerable:!0,get:function(){return i.getDocument}}),Object.defineProperty(t,"LoopbackPort",{enumerable:!0,get:function(){return i.LoopbackPort}}),Object.defineProperty(t,"PDFDataRangeTransport",{enumerable:!0,get:function(){return i.PDFDataRangeTransport}}),Object.defineProperty(t,"PDFWorker",{enumerable:!0,get:function(){return i.PDFWorker}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return i.version}}),Object.defineProperty(t,"CMapCompressionType",{enumerable:!0,get:function(){return o.CMapCompressionType}}),Object.defineProperty(t,"createObjectURL",{enumerable:!0,get:function(){return o.createObjectURL}}),Object.defineProperty(t,"createPromiseCapability",{enumerable:!0,get:function(){return o.createPromiseCapability}}),Object.defineProperty(t,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return o.createValidAbsoluteUrl}}),Object.defineProperty(t,"InvalidPDFException",{enumerable:!0,get:function(){return o.InvalidPDFException}}),Object.defineProperty(t,"MissingPDFException",{enumerable:!0,get:function(){return o.MissingPDFException}}),Object.defineProperty(t,"OPS",{enumerable:!0,get:function(){return o.OPS}}),Object.defineProperty(t,"PasswordResponses",{enumerable:!0,get:function(){return o.PasswordResponses}}),Object.defineProperty(t,"PermissionFlag",{enumerable:!0,get:function(){return o.PermissionFlag}}),Object.defineProperty(t,"removeNullCharacters",{enumerable:!0,get:function(){return o.removeNullCharacters}}),Object.defineProperty(t,"shadow",{enumerable:!0,get:function(){return o.shadow}}),Object.defineProperty(t,"UnexpectedResponseException",{enumerable:!0,get:function(){return o.UnexpectedResponseException}}),Object.defineProperty(t,"UNSUPPORTED_FEATURES",{enumerable:!0,get:function(){return o.UNSUPPORTED_FEATURES}}),Object.defineProperty(t,"Util",{enumerable:!0,get:function(){return o.Util}}),Object.defineProperty(t,"VerbosityLevel",{enumerable:!0,get:function(){return o.VerbosityLevel}}),Object.defineProperty(t,"AnnotationLayer",{enumerable:!0,get:function(){return s.AnnotationLayer}}),Object.defineProperty(t,"apiCompatibilityParams",{enumerable:!0,get:function(){return a.apiCompatibilityParams}}),Object.defineProperty(t,"GlobalWorkerOptions",{enumerable:!0,get:function(){return l.GlobalWorkerOptions}}),Object.defineProperty(t,"renderTextLayer",{enumerable:!0,get:function(){return u.renderTextLayer}}),Object.defineProperty(t,"SVGGraphics",{enumerable:!0,get:function(){return c.SVGGraphics}});var r=n(1),i=n(198),o=n(5),s=n(209),a=n(200),l=n(203),u=n(210),c=n(211);if(n(7).isNodeJS){var h=n(212).PDFNodeStream;(0,i.setPDFNetworkStreamFactory)((function(e){return new h(e)}))}else{var d,f=n(215).PDFNetworkStream;(0,r.isFetchSupported)()&&(d=n(216).PDFFetchStream),(0,i.setPDFNetworkStreamFactory)((function(e){return d&&(0,r.isValidFetchUrl)(e.url)?new d(e):new f(e)}))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addLinkAttributes=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.url,r=t.target,i=t.rel,s=t.enabled,a=void 0===s||s;(0,o.assert)(n&&"string"==typeof n,'addLinkAttributes: A valid "url" parameter must provided.');var l=(0,o.removeNullCharacters)(n);a?e.href=e.title=l:(e.href="",e.title="Disabled: ".concat(l),e.onclick=function(){return!1});var u="";switch(r){case b.NONE:break;case b.SELF:u="_self";break;case b.BLANK:u="_blank";break;case b.PARENT:u="_parent";break;case b.TOP:u="_top"}e.target=u,e.rel="string"==typeof i?i:m},t.getFilenameFromUrl=function(e){var t=e.indexOf("#"),n=e.indexOf("?"),r=Math.min(t>0?t:e.length,n>0?n:e.length);return e.substring(e.lastIndexOf("/",r)+1,r)},t.isFetchSupported=w,t.isValidFetchUrl=A,t.loadScript=function(e){return new Promise((function(t,n){var r=document.createElement("script");r.src=e,r.onload=t,r.onerror=function(){n(new Error("Cannot load script at: ".concat(r.src)))},(document.head||document.documentElement).appendChild(r)}))},t.deprecated=function(e){console.log("Deprecated API usage: "+e)},t.PDFDateString=t.StatTimer=t.DOMSVGFactory=t.DOMCMapReaderFactory=t.DOMCanvasFactory=t.DEFAULT_LINK_REL=t.LinkTarget=t.RenderingCancelledException=t.PageViewport=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5);function s(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){l=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(l)throw o}}}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}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 u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e,t){return!t||"object"!==l(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function d(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function f(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){d(o,r,i,s,a,"next",e)}function a(e){d(o,r,i,s,a,"throw",e)}s(void 0)}))}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e}var m="noopener noreferrer nofollow";t.DEFAULT_LINK_REL=m;var v="http://www.w3.org/2000/svg";t.DOMCanvasFactory=function(){function e(){p(this,e)}return y(e,[{key:"create",value:function(e,t){if(e<=0||t<=0)throw new Error("Invalid canvas size");var n=document.createElement("canvas"),r=n.getContext("2d");return n.width=e,n.height=t,{canvas:n,context:r}}},{key:"reset",value:function(e,t,n){if(!e.canvas)throw new Error("Canvas is not specified");if(t<=0||n<=0)throw new Error("Invalid canvas size");e.canvas.width=t,e.canvas.height=n}},{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.DOMCMapReaderFactory=function(){function e(t){var n=t.baseUrl,r=void 0===n?null:n,i=t.isCompressed,o=void 0!==i&&i;p(this,e),this.baseUrl=r,this.isCompressed=o}return y(e,[{key:"fetch",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(){var e=f(i.default.mark((function e(t){var n,r,s,a=this;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=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(n){e.next=5;break}throw new Error("CMap name must be specified.");case 5:if(r=this.baseUrl+n+(this.isCompressed?".bcmap":""),s=this.isCompressed?o.CMapCompressionType.BINARY:o.CMapCompressionType.NONE,!w()||!A(r,document.baseURI)){e.next=9;break}return e.abrupt("return",fetch(r).then(function(){var e=f(i.default.mark((function e(t){var n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.ok){e.next=2;break}throw new Error(t.statusText);case 2:if(!a.isCompressed){e.next=10;break}return e.t0=Uint8Array,e.next=6,t.arrayBuffer();case 6:e.t1=e.sent,n=new e.t0(e.t1),e.next=15;break;case 10:return e.t2=o.stringToBytes,e.next=13,t.text();case 13:e.t3=e.sent,n=(0,e.t2)(e.t3);case 15:return e.abrupt("return",{cMapData:n,compressionType:s});case 16:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){throw new Error("Unable to load ".concat(a.isCompressed?"binary ":"")+"CMap at: ".concat(r))})));case 9:return e.abrupt("return",new Promise((function(e,t){var n=new XMLHttpRequest;n.open("GET",r,!0),a.isCompressed&&(n.responseType="arraybuffer"),n.onreadystatechange=function(){if(n.readyState===XMLHttpRequest.DONE){var r;if((200===n.status||0===n.status)&&(a.isCompressed&&n.response?r=new Uint8Array(n.response):!a.isCompressed&&n.responseText&&(r=(0,o.stringToBytes)(n.responseText)),r))return void e({cMapData:r,compressionType:s});t(new Error(n.statusText))}},n.send(null)})).catch((function(e){throw new Error("Unable to load ".concat(a.isCompressed?"binary ":"")+"CMap at: ".concat(r))})));case 10:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}())}]),e}(),t.DOMSVGFactory=function(){function e(){p(this,e)}return y(e,[{key:"create",value:function(e,t){(0,o.assert)(e>0&&t>0,"Invalid SVG dimensions");var n=document.createElementNS(v,"svg:svg");return n.setAttribute("version","1.1"),n.setAttribute("width",e+"px"),n.setAttribute("height",t+"px"),n.setAttribute("preserveAspectRatio","none"),n.setAttribute("viewBox","0 0 "+e+" "+t),n}},{key:"createElement",value:function(e){return(0,o.assert)("string"==typeof e,"Invalid SVG element type"),document.createElementNS(v,e)}}]),e}(),t.PageViewport=function(){function e(t){var n=t.viewBox,r=t.scale,i=t.rotation,o=t.offsetX,s=void 0===o?0:o,a=t.offsetY,l=void 0===a?0:a,u=t.dontFlip,c=void 0!==u&&u;p(this,e),this.viewBox=n,this.scale=r,this.rotation=i,this.offsetX=s,this.offsetY=l;var h,d,f,g,y,m,v,_,b=(n[2]+n[0])/2,w=(n[3]+n[1])/2;switch(i=(i%=360)<0?i+360:i){case 180:h=-1,d=0,f=0,g=1;break;case 90:h=0,d=1,f=1,g=0;break;case 270:h=0,d=-1,f=-1,g=0;break;case 0:h=1,d=0,f=0,g=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}c&&(f=-f,g=-g),0===h?(y=Math.abs(w-n[1])*r+s,m=Math.abs(b-n[0])*r+l,v=Math.abs(n[3]-n[1])*r,_=Math.abs(n[2]-n[0])*r):(y=Math.abs(b-n[0])*r+s,m=Math.abs(w-n[1])*r+l,v=Math.abs(n[2]-n[0])*r,_=Math.abs(n[3]-n[1])*r),this.transform=[h*r,d*r,f*r,g*r,y-h*r*b-f*r*w,m-d*r*b-g*r*w],this.width=v,this.height=_}return y(e,[{key:"clone",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.scale,r=void 0===n?this.scale:n,i=t.rotation,o=void 0===i?this.rotation:i,s=t.offsetX,a=void 0===s?this.offsetX:s,l=t.offsetY,u=void 0===l?this.offsetY:l,c=t.dontFlip,h=void 0!==c&&c;return new e({viewBox:this.viewBox.slice(),scale:r,rotation:o,offsetX:a,offsetY:u,dontFlip:h})}},{key:"convertToViewportPoint",value:function(e,t){return o.Util.applyTransform([e,t],this.transform)}},{key:"convertToViewportRectangle",value:function(e){var t=o.Util.applyTransform([e[0],e[1]],this.transform),n=o.Util.applyTransform([e[2],e[3]],this.transform);return[t[0],t[1],n[0],n[1]]}},{key:"convertToPdfPoint",value:function(e,t){return o.Util.applyInverseTransform([e,t],this.transform)}}]),e}(),t.RenderingCancelledException=function(e){!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)}(i,e);var t,n,r=(t=i,n=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}}(),function(){var e,r=h(t);if(n){var i=h(this).constructor;e=Reflect.construct(r,arguments,i)}else e=r.apply(this,arguments);return c(this,e)});function i(e,t){var n;return p(this,i),(n=r.call(this,e)).type=t,n}return i}(o.BaseException);var _,b={NONE:0,SELF:1,BLANK:2,PARENT:3,TOP:4};function w(){return"undefined"!=typeof fetch&&"undefined"!=typeof Response&&"body"in Response.prototype&&"undefined"!=typeof ReadableStream}function A(e,t){try{var n=(t?new URL(e,t):new URL(e)).protocol;return"http:"===n||"https:"===n}catch(r){return!1}}t.LinkTarget=b,t.StatTimer=function(){function e(){p(this,e),this.started=Object.create(null),this.times=[]}return y(e,[{key:"time",value:function(e){e in this.started&&(0,o.warn)("Timer is already running for ".concat(e)),this.started[e]=Date.now()}},{key:"timeEnd",value:function(e){e in this.started||(0,o.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=[],n=0,r=s(this.times);try{for(r.s();!(e=r.n()).done;){var i=e.value.name;i.length>n&&(n=i.length)}}catch(c){r.e(c)}finally{r.f()}var o,a=s(this.times);try{for(a.s();!(o=a.n()).done;){var l=o.value,u=l.end-l.start;t.push("".concat(l.name.padEnd(n)," ").concat(u,"ms\n"))}}catch(c){a.e(c)}finally{a.f()}return t.join("")}}]),e}(),t.PDFDateString=function(){function e(){p(this,e)}return y(e,null,[{key:"toDateObject",value:function(e){if(!e||!(0,o.isString)(e))return null;_||(_=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"));var t=_.exec(e);if(!t)return null;var n=parseInt(t[1],10),r=parseInt(t[2],10);r=r>=1&&r<=12?r-1:0;var i=parseInt(t[3],10);i=i>=1&&i<=31?i:1;var s=parseInt(t[4],10);s=s>=0&&s<=23?s:0;var a=parseInt(t[5],10);a=a>=0&&a<=59?a:0;var l=parseInt(t[6],10);l=l>=0&&l<=59?l:0;var u=t[7]||"Z",c=parseInt(t[8],10);c=c>=0&&c<=23?c:0;var h=parseInt(t[9],10)||0;return h=h>=0&&h<=59?h:0,"-"===u?(s+=c,a+=h):"+"===u&&(s-=c,a-=h),new Date(Date.UTC(n,r,i,s,a,l))}}]),e}()},function(e,t,n){"use strict";e.exports=n(3)},function(e,t,n){"use strict";(function(e){function t(e){return(t="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 n=function(e){var n,r=Object.prototype,i=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",l=o.toStringTag||"@@toStringTag";function u(e,t,n,r){var i=Object.create((t&&t.prototype instanceof y?t:y).prototype),o=new E(r||[]);return i._invoke=function(e,t,n){var r=h;return function(i,o){if(r===f)throw new Error("Generator is already running");if(r===p){if("throw"===i)throw o;return R()}for(n.method=i,n.arg=o;;){var s=n.delegate;if(s){var a=x(s,n);if(a){if(a===g)continue;return a}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===h)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=f;var l=c(e,t,n);if("normal"===l.type){if(r=n.done?p:d,l.arg===g)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(r=p,n.method="throw",n.arg=l.arg)}}}(e,n,o),i}function c(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(r){return{type:"throw",arg:r}}}e.wrap=u;var h="suspendedStart",d="suspendedYield",f="executing",p="completed",g={};function y(){}function m(){}function v(){}var _={};_[s]=function(){return this};var b=Object.getPrototypeOf,w=b&&b(b(T([])));w&&w!==r&&i.call(w,s)&&(_=w);var A=v.prototype=y.prototype=Object.create(_);function S(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function k(e,n){var r;this._invoke=function(o,s){function a(){return new n((function(r,a){!function r(o,s,a,l){var u=c(e[o],e,s);if("throw"!==u.type){var h=u.arg,d=h.value;return d&&"object"===t(d)&&i.call(d,"__await")?n.resolve(d.__await).then((function(e){r("next",e,a,l)}),(function(e){r("throw",e,a,l)})):n.resolve(d).then((function(e){h.value=e,a(h)}),(function(e){return r("throw",e,a,l)}))}l(u.arg)}(o,s,r,a)}))}return r=r?r.then(a,a):a()}}function x(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,x(e,t),"throw"===t.method))return g;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var i=c(r,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,g;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,g):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,g)}function C(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 P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function T(e){if(e){var t=e[s];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(i.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=n,t.done=!0,t};return o.next=o}}return{next:R}}function R(){return{value:n,done:!0}}return m.prototype=A.constructor=v,v.constructor=m,v[l]=m.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===m||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,l in e||(e[l]="GeneratorFunction")),e.prototype=Object.create(A),e},e.awrap=function(e){return{__await:e}},S(k.prototype),k.prototype[a]=function(){return this},e.AsyncIterator=k,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var s=new k(u(t,n,r,i),o);return e.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},S(A),A[l]="Generator",A[s]=function(){return this},A.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=T,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(P),!e)for(var t in this)"t"===t.charAt(0)&&i.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=n)},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 t=this;function r(r,i){return a.type="throw",a.arg=e,t.next=r,i&&(t.method="next",t.arg=n),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],a=s.completion;if("root"===s.tryLoc)return r("end");if(s.tryLoc<=this.prev){var l=i.call(s,"catchLoc"),u=i.call(s,"finallyLoc");if(l&&u){if(this.prev<s.catchLoc)return r(s.catchLoc,!0);if(this.prev<s.finallyLoc)return r(s.finallyLoc)}else if(l){if(this.prev<s.catchLoc)return r(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return r(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=e,s.arg=t,o?(this.method="next",this.next=o.finallyLoc,g):this.complete(s)},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;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;P(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:T(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),g}},e}("object"===t(e)?e.exports:{});try{regeneratorRuntime=n}catch(r){Function("r","regeneratorRuntime = r")(n)}}).call(this,n(4)(e))},function(e,t,n){"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,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}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 o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(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&&(Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function a(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=u(e);if(t){var i=u(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return l(this,n)}}function l(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=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 n=0,r=0;r<t;r++)n+=_(e[r]);for(var i=0,o=new Uint8Array(n),s=0;s<t;s++){var a=e[s];a instanceof Uint8Array||(a="string"==typeof a?v(a):new Uint8Array(a));var l=a.byteLength;o.set(a,i),i+=l}return o},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,n=8192;if(t<n)return String.fromCharCode.apply(null,e);for(var r=[],o=0;o<t;o+=n){var s=Math.min(o+n,t),a=e.subarray(o,s);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(n,r){e.resolve=function(e){t=!0,n(e)},e.reject=function(e){t=!0,r(e)}})),e},t.getVerbosityLevel=function(){return h},t.info=function(e){h>=c.INFOS&&console.log("Info: ".concat(e))},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,n){return e===t[n]}))},t.isBool=function(e){return"boolean"==typeof e},t.isEmptyObj=function(e){for(var t in e)return!1;return!0},t.isNum=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSameOrigin=function(e,t){var n;try{if(!(n=new URL(e)).origin||"null"===n.origin)return!1}catch(i){return!1}var r=new URL(t,n);return n.origin===r.origin},t.createValidAbsoluteUrl=function(e,t){if(!e)return null;try{var n=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}}(n))return n}catch(r){}return null},t.removeNullCharacters=function(e){return"string"!=typeof e?(d("The argument for removeNullCharacters must be a string."),e):e.replace(m,"")},t.setVerbosityLevel=function(e){Number.isInteger(e)&&(h=e)},t.shadow=g,t.string32=function(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,255&e)},t.stringToBytes=v,t.stringToPDFString=function(e){var t=e.length,n=[];if("\xfe"===e[0]&&"\xff"===e[1])for(var r=2;r<t;r+=2)n.push(String.fromCharCode(e.charCodeAt(r)<<8|e.charCodeAt(r+1)));else if("\xff"===e[0]&&"\xfe"===e[1])for(var i=2;i<t;i+=2)n.push(String.fromCharCode(e.charCodeAt(i+1)<<8|e.charCodeAt(i)));else for(var o=0;o<t;++o){var s=A[e.charCodeAt(o)];n.push(s?String.fromCharCode(s):e.charAt(o))}return n.join("")},t.stringToUTF8String=function(e){return decodeURIComponent(escape(e))},t.utf8StringToString=function(e){return unescape(encodeURIComponent(e))},t.warn=d,t.unreachable=f,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,n(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"},t.PasswordResponses={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};var h=c.WARNINGS;function d(e){h>=c.WARNINGS&&console.log("Warning: ".concat(e))}function f(e){throw new Error(e)}function p(e,t){e||f(t)}function g(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!1}),n}var y=function(){function e(t){this.constructor===e&&f("Cannot initialize BaseException."),this.message=t,this.name=this.constructor.name}return e.prototype=new Error,e.constructor=e,e}();t.BaseException=y,t.PasswordException=function(e){s(n,e);var t=a(n);function n(e,r){var i;return o(this,n),(i=t.call(this,e)).code=r,i}return n}(y),t.UnknownErrorException=function(e){s(n,e);var t=a(n);function n(e,r){var i;return o(this,n),(i=t.call(this,e)).details=r,i}return n}(y),t.InvalidPDFException=function(e){s(n,e);var t=a(n);function n(){return o(this,n),t.apply(this,arguments)}return n}(y),t.MissingPDFException=function(e){s(n,e);var t=a(n);function n(){return o(this,n),t.apply(this,arguments)}return n}(y),t.UnexpectedResponseException=function(e){s(n,e);var t=a(n);function n(e,r){var i;return o(this,n),(i=t.call(this,e)).status=r,i}return n}(y),t.FormatError=function(e){s(n,e);var t=a(n);function n(){return o(this,n),t.apply(this,arguments)}return n}(y),t.AbortException=function(e){s(n,e);var t=a(n);function n(){return o(this,n),t.apply(this,arguments)}return n}(y);var m=/\x00/g;function v(e){p("string"==typeof e,"Invalid argument for stringToBytes");for(var t=e.length,n=new Uint8Array(t),r=0;r<t;++r)n[r]=255&e.charCodeAt(r);return n}function _(e){return void 0!==e.length?e.length:(p(void 0!==e.byteLength,"arrayByteLength - invalid argument."),e.byteLength)}t.IsLittleEndianCached={get value(){return g(this,"value",((e=new Uint8Array(4))[0]=1,1===new Uint32Array(e.buffer,0,1)[0]));var e}},t.IsEvalSupportedCached={get value(){return g(this,"value",function(){try{return new Function(""),!0}catch(e){return!1}}())}};var b=["rgb(",0,",",0,",",0,")"];t.Util=function(){function e(){o(this,e)}var t,n;return t=e,(n=[{key:"makeCssRgb",value:function(e,t,n){return b[1]=e,b[3]=t,b[5]=n,b.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 n=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])/n,(-e[0]*t[1]+e[1]*t[0]+t[4]*t[1]-t[5]*t[0])/n]}},{key:"getAxialAlignedBoundingBox",value:function(t,n){var r=e.applyTransform(t,n),i=e.applyTransform(t.slice(2,4),n),o=e.applyTransform([t[0],t[3]],n),s=e.applyTransform([t[2],t[1]],n);return[Math.min(r[0],i[0],o[0],s[0]),Math.min(r[1],i[1],o[1],s[1]),Math.max(r[0],i[0],o[0],s[0]),Math.max(r[1],i[1],o[1],s[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]],n=e[0]*t[0]+e[1]*t[2],r=e[2]*t[1]+e[3]*t[3],i=(n+r)/2,o=Math.sqrt((n+r)*(n+r)-4*(n*r-(e[2]*t[0]+e[3]*t[2])*(e[0]*t[1]+e[1]*t[3])))/2,s=i-o||1;return[Math.sqrt(i+o||1),Math.sqrt(s)]}},{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,n){function r(e,t){return e-t}var i=[t[0],t[2],n[0],n[2]].sort(r),o=[t[1],t[3],n[1],n[3]].sort(r),s=[];return t=e.normalizeRect(t),n=e.normalizeRect(n),i[0]===t[0]&&i[1]===n[0]||i[0]===n[0]&&i[1]===t[0]?(s[0]=i[1],s[2]=i[2],o[0]===t[1]&&o[1]===n[1]||o[0]===n[1]&&o[1]===t[1]?(s[1]=o[1],s[3]=o[2],s):null):null}}])&&r(t,n),e}();var w,A=[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],S=(w="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!n&&URL.createObjectURL){var r=new Blob([e],{type:t});return URL.createObjectURL(r)}for(var i="data:".concat(t,";base64,"),o=0,s=e.length;o<s;o+=3){var a=255&e[o],l=255&e[o+1],u=255&e[o+2],c=a>>2,h=(3&a)<<4|l>>4,d=o+1<s?(15&l)<<2|u>>6:64,f=o+2<s?63&u:64;i+=w[c]+w[h]+w[d]+w[f]}return i});t.createObjectURL=S},function(e,t,n){"use strict";var r=n(7);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)}if("undefined"==typeof globalThis||!globalThis._pdfjsCompatibilityChecked){"undefined"!=typeof globalThis&&globalThis.Math===Math||(globalThis=n(8)),globalThis._pdfjsCompatibilityChecked=!0;var o="object"===("undefined"==typeof window?"undefined":i(window))&&"object"===("undefined"==typeof document?"undefined":i(document)),s="undefined"!=typeof navigator&&navigator.userAgent||"",a=/Trident/.test(s);!globalThis.btoa&&r.isNodeJS&&(globalThis.btoa=function(e){return Buffer.from(e,"binary").toString("base64")}),!globalThis.atob&&r.isNodeJS&&(globalThis.atob=function(e){return Buffer.from(e,"base64").toString("binary")}),o&&void 0===Element.prototype.remove&&(Element.prototype.remove=function(){this.parentNode&&this.parentNode.removeChild(this)}),function(){if(o&&!r.isNodeJS){var e=document.createElement("div");if(e.classList.add("testOne","testTwo"),!0!==e.classList.contains("testOne")||!0!==e.classList.contains("testTwo")){var t=DOMTokenList.prototype.add,n=DOMTokenList.prototype.remove;DOMTokenList.prototype.add=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];for(var i=0,o=n;i<o.length;i++){var s=o[i];t.call(this,s)}},DOMTokenList.prototype.remove=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];for(var i=0,o=t;i<o.length;i++){var s=o[i];n.call(this,s)}}}}}(),o&&!r.isNodeJS&&!1!==document.createElement("div").classList.toggle("test",0)&&(DOMTokenList.prototype.toggle=function(e){var t=arguments.length>1?!!arguments[1]:!this.contains(e);return this[t?"add":"remove"](e),t}),function(){if(o&&a){var e=window.history.pushState,t=window.history.replaceState;window.history.pushState=function(t,n,r){e.apply(this,void 0===r?[t,n]:[t,n,r])},window.history.replaceState=function(e,n,r){t.apply(this,void 0===r?[e,n]:[e,n,r])}}}(),String.prototype.startsWith||n(53),String.prototype.endsWith||n(64),String.prototype.includes||n(66),Array.prototype.includes||n(68),Array.from||n(76),Object.assign||n(98),Math.log2||(Math.log2=n(101)),Number.isNaN||(Number.isNaN=n(103)),Number.isInteger||(Number.isInteger=n(105)),Uint8Array.prototype.slice||n(108),globalThis.Promise&&globalThis.Promise.allSettled||(globalThis.Promise=n(113)),globalThis.URL=n(136),function(){var e=!1;if("undefined"!=typeof ReadableStream)try{new ReadableStream({start:function(e){e.close()}}),e=!0}catch(t){}e||(globalThis.ReadableStream=n(143).ReadableStream)}(),globalThis.Map&&globalThis.Map.prototype.entries||(globalThis.Map=n(144)),globalThis.Set&&globalThis.Set.prototype.entries||(globalThis.Set=n(151)),globalThis.WeakMap||(globalThis.WeakMap=n(153)),globalThis.WeakSet||(globalThis.WeakSet=n(159)),String.prototype.codePointAt||n(161),String.fromCodePoint||(String.fromCodePoint=n(163)),globalThis.Symbol||n(165),String.prototype.padStart||n(188),String.prototype.padEnd||n(193),Object.values||(Object.values=n(195))}},function(e,t,n){"use strict";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)}Object.defineProperty(t,"__esModule",{value:!0}),t.isNodeJS=void 0;var i="object"===("undefined"==typeof process?"undefined":r(process))&&process+""=="[object process]"&&!process.versions.nw&&!process.versions.electron;t.isNodeJS=i},function(e,t,n){n(9),e.exports=n(11)},function(e,t,n){n(10)({global:!0},{globalThis:n(11)})},function(e,t,n){var r=n(11),i=n(12).f,o=n(26),s=n(29),a=n(30),l=n(40),u=n(52);e.exports=function(e,t){var n,c,h,d,f,p=e.target,g=e.global,y=e.stat;if(n=g?r:y?r[p]||a(p,{}):(r[p]||{}).prototype)for(c in t){if(d=t[c],h=e.noTargetGet?(f=i(n,c))&&f.value:n[c],!u(g?c:p+(y?".":"#")+c,e.forced)&&void 0!==h){if(typeof d==typeof h)continue;l(d,h)}(e.sham||h&&h.sham)&&o(d,"sham",!0),s(n,c,d,e)}}},function(e,t){var n=function(e){return e&&e.Math==Math&&e};e.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof global&&global)||Function("return this")()},function(e,t,n){var r=n(13),i=n(15),o=n(16),s=n(17),a=n(21),l=n(23),u=n(24),c=Object.getOwnPropertyDescriptor;t.f=r?c:function(e,t){if(e=s(e),t=a(t,!0),u)try{return c(e,t)}catch(n){}if(l(e,t))return o(!i.f.call(e,t),e[t])}},function(e,t,n){var r=n(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(t){return!0}}},function(e,t,n){"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,o=i&&!r.call({1:2},1);t.f=o?function(e){var t=i(this,e);return!!t&&t.enumerable}:r},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var r=n(18),i=n(20);e.exports=function(e){return r(i(e))}},function(e,t,n){var r=n(14),i=n(19),o="".split;e.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==i(e)?o.call(e,""):Object(e)}:Object},function(e,t){var n={}.toString;e.exports=function(e){return n.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,n){var r=n(22);e.exports=function(e,t){if(!r(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!r(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!r(i=n.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 n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var r=n(13),i=n(14),o=n(25);e.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},function(e,t,n){var r=n(11),i=n(22),o=r.document,s=i(o)&&i(o.createElement);e.exports=function(e){return s?o.createElement(e):{}}},function(e,t,n){var r=n(13),i=n(27),o=n(16);e.exports=r?function(e,t,n){return i.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(13),i=n(24),o=n(28),s=n(21),a=Object.defineProperty;t.f=r?a:function(e,t,n){if(o(e),t=s(t,!0),o(n),i)try{return a(e,t,n)}catch(r){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){var r=n(22);e.exports=function(e){if(!r(e))throw TypeError(String(e)+" is not an object");return e}},function(e,t,n){var r=n(11),i=n(26),o=n(23),s=n(30),a=n(31),l=n(33),u=l.get,c=l.enforce,h=String(String).split("String");(e.exports=function(e,t,n,a){var l=!!a&&!!a.unsafe,u=!!a&&!!a.enumerable,d=!!a&&!!a.noTargetGet;"function"==typeof n&&("string"!=typeof t||o(n,"name")||i(n,"name",t),c(n).source=h.join("string"==typeof t?t:"")),e!==r?(l?!d&&e[t]&&(u=!0):delete e[t],u?e[t]=n:i(e,t,n)):u?e[t]=n:s(t,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&u(this).source||a(this)}))},function(e,t,n){var r=n(11),i=n(26);e.exports=function(e,t){try{i(r,e,t)}catch(n){r[e]=t}return t}},function(e,t,n){var r=n(32),i=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(e){return i.call(e)}),e.exports=r.inspectSource},function(e,t,n){var r=n(11),i=n(30),o="__core-js_shared__",s=r[o]||i(o,{});e.exports=s},function(e,t,n){var r,i,o,s=n(34),a=n(11),l=n(22),u=n(26),c=n(23),h=n(35),d=n(39);if(s){var f=new(0,a.WeakMap),p=f.get,g=f.has,y=f.set;r=function(e,t){return y.call(f,e,t),t},i=function(e){return p.call(f,e)||{}},o=function(e){return g.call(f,e)}}else{var m=h("state");d[m]=!0,r=function(e,t){return u(e,m,t),t},i=function(e){return c(e,m)?e[m]:{}},o=function(e){return c(e,m)}}e.exports={set:r,get:i,has:o,enforce:function(e){return o(e)?i(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!l(t)||(n=i(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}}},function(e,t,n){var r=n(11),i=n(31),o=r.WeakMap;e.exports="function"==typeof o&&/native code/.test(i(o))},function(e,t,n){var r=n(36),i=n(38),o=r("keys");e.exports=function(e){return o[e]||(o[e]=i(e))}},function(e,t,n){var r=n(37),i=n(32);(e.exports=function(e,t){return i[e]||(i[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.6.5",mode:r?"pure":"global",copyright:"\xa9 2020 Denis Pushkarev (zloirock.ru)"})},function(e,t){e.exports=!1},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++n+r).toString(36)}},function(e,t){e.exports={}},function(e,t,n){var r=n(23),i=n(41),o=n(12),s=n(27);e.exports=function(e,t){for(var n=i(t),a=s.f,l=o.f,u=0;u<n.length;u++){var c=n[u];r(e,c)||a(e,c,l(t,c))}}},function(e,t,n){var r=n(42),i=n(44),o=n(51),s=n(28);e.exports=r("Reflect","ownKeys")||function(e){var t=i.f(s(e)),n=o.f;return n?t.concat(n(e)):t}},function(e,t,n){var r=n(43),i=n(11),o=function(e){return"function"==typeof e?e:void 0};e.exports=function(e,t){return arguments.length<2?o(r[e])||o(i[e]):r[e]&&r[e][t]||i[e]&&i[e][t]}},function(e,t,n){var r=n(11);e.exports=r},function(e,t,n){var r=n(45),i=n(50).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},function(e,t,n){var r=n(23),i=n(17),o=n(46).indexOf,s=n(39);e.exports=function(e,t){var n,a=i(e),l=0,u=[];for(n in a)!r(s,n)&&r(a,n)&&u.push(n);for(;t.length>l;)r(a,n=t[l++])&&(~o(u,n)||u.push(n));return u}},function(e,t,n){var r=n(17),i=n(47),o=n(49),s=function(e){return function(t,n,s){var a,l=r(t),u=i(l.length),c=o(s,u);if(e&&n!=n){for(;u>c;)if((a=l[c++])!=a)return!0}else for(;u>c;c++)if((e||c in l)&&l[c]===n)return e||c||0;return!e&&-1}};e.exports={includes:s(!0),indexOf:s(!1)}},function(e,t,n){var r=n(48),i=Math.min;e.exports=function(e){return e>0?i(r(e),9007199254740991):0}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){var r=n(48),i=Math.max,o=Math.min;e.exports=function(e,t){var n=r(e);return n<0?i(n+t,0):o(n,t)}},function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var r=n(14),i=/#|\.prototype\./,o=function(e,t){var n=a[s(e)];return n==u||n!=l&&("function"==typeof t?r(t):!!t)},s=o.normalize=function(e){return String(e).replace(i,".").toLowerCase()},a=o.data={},l=o.NATIVE="N",u=o.POLYFILL="P";e.exports=o},function(e,t,n){n(54);var r=n(61);e.exports=r("String","startsWith")},function(e,t,n){"use strict";var r,i=n(10),o=n(12).f,s=n(47),a=n(55),l=n(20),u=n(60),c=n(37),h="".startsWith,d=Math.min,f=u("startsWith");i({target:"String",proto:!0,forced:!(!c&&!f&&(r=o(String.prototype,"startsWith"),r&&!r.writable)||f)},{startsWith:function(e){var t=String(l(this));a(e);var n=s(d(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return h?h.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){var r=n(56);e.exports=function(e){if(r(e))throw TypeError("The method doesn't accept regular expressions");return e}},function(e,t,n){var r=n(22),i=n(19),o=n(57)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[o])?!!t:"RegExp"==i(e))}},function(e,t,n){var r=n(11),i=n(36),o=n(23),s=n(38),a=n(58),l=n(59),u=i("wks"),c=r.Symbol,h=l?c:c&&c.withoutSetter||s;e.exports=function(e){return o(u,e)||(u[e]=a&&o(c,e)?c[e]:h("Symbol."+e)),u[e]}},function(e,t,n){var r=n(14);e.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},function(e,t,n){var r=n(58);e.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},function(e,t,n){var r=n(57)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,"/./"[e](t)}catch(i){}}return!1}},function(e,t,n){var r=n(11),i=n(62),o=Function.call;e.exports=function(e,t,n){return i(o,r[e].prototype[t],n)}},function(e,t,n){var r=n(63);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,i){return e.call(t,n,r,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,n){n(65);var r=n(61);e.exports=r("String","endsWith")},function(e,t,n){"use strict";var r,i=n(10),o=n(12).f,s=n(47),a=n(55),l=n(20),u=n(60),c=n(37),h="".endsWith,d=Math.min,f=u("endsWith");i({target:"String",proto:!0,forced:!(!c&&!f&&(r=o(String.prototype,"endsWith"),r&&!r.writable)||f)},{endsWith:function(e){var t=String(l(this));a(e);var n=arguments.length>1?arguments[1]:void 0,r=s(t.length),i=void 0===n?r:d(s(n),r),o=String(e);return h?h.call(t,o,i):t.slice(i-o.length,i)===o}})},function(e,t,n){n(67);var r=n(61);e.exports=r("String","includes")},function(e,t,n){"use strict";var r=n(10),i=n(55),o=n(20);r({target:"String",proto:!0,forced:!n(60)("includes")},{includes:function(e){return!!~String(o(this)).indexOf(i(e),arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){n(69);var r=n(61);e.exports=r("Array","includes")},function(e,t,n){"use strict";var r=n(10),i=n(46).includes,o=n(70);r({target:"Array",proto:!0,forced:!n(75)("indexOf",{ACCESSORS:!0,1:0})},{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("includes")},function(e,t,n){var r=n(57),i=n(71),o=n(27),s=r("unscopables"),a=Array.prototype;null==a[s]&&o.f(a,s,{configurable:!0,value:i(null)}),e.exports=function(e){a[s][e]=!0}},function(e,t,n){var r,i=n(28),o=n(72),s=n(50),a=n(39),l=n(74),u=n(25),c=n(35)("IE_PROTO"),h=function(){},d=function(e){return"<script>"+e+"<\/script>"},f=function(){try{r=document.domain&&new ActiveXObject("htmlfile")}catch(i){}var e,t;f=r?function(e){e.write(d("")),e.close();var t=e.parentWindow.Object;return e=null,t}(r):((t=u("iframe")).style.display="none",l.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(d("document.F=Object")),e.close(),e.F);for(var n=s.length;n--;)delete f.prototype[s[n]];return f()};a[c]=!0,e.exports=Object.create||function(e,t){var n;return null!==e?(h.prototype=i(e),n=new h,h.prototype=null,n[c]=e):n=f(),void 0===t?n:o(n,t)}},function(e,t,n){var r=n(13),i=n(27),o=n(28),s=n(73);e.exports=r?Object.defineProperties:function(e,t){o(e);for(var n,r=s(t),a=r.length,l=0;a>l;)i.f(e,n=r[l++],t[n]);return e}},function(e,t,n){var r=n(45),i=n(50);e.exports=Object.keys||function(e){return r(e,i)}},function(e,t,n){var r=n(42);e.exports=r("document","documentElement")},function(e,t,n){var r=n(13),i=n(14),o=n(23),s=Object.defineProperty,a={},l=function(e){throw e};e.exports=function(e,t){if(o(a,e))return a[e];t||(t={});var n=[][e],u=!!o(t,"ACCESSORS")&&t.ACCESSORS,c=o(t,0)?t[0]:l,h=o(t,1)?t[1]:void 0;return a[e]=!!n&&!i((function(){if(u&&!r)return!0;var e={length:-1};u?s(e,1,{enumerable:!0,get:l}):e[1]=1,n.call(e,c,h)}))}},function(e,t,n){n(77),n(89);var r=n(43);e.exports=r.Array.from},function(e,t,n){"use strict";var r=n(78).charAt,i=n(33),o=n(79),s="String Iterator",a=i.set,l=i.getterFor(s);o(String,"String",(function(e){a(this,{type:s,string:String(e),index:0})}),(function(){var e,t=l(this),n=t.string,i=t.index;return i>=n.length?{value:void 0,done:!0}:(e=r(n,i),t.index+=e.length,{value:e,done:!1})}))},function(e,t,n){var r=n(48),i=n(20),o=function(e){return function(t,n){var o,s,a=String(i(t)),l=r(n),u=a.length;return l<0||l>=u?e?"":void 0:(o=a.charCodeAt(l))<55296||o>56319||l+1===u||(s=a.charCodeAt(l+1))<56320||s>57343?e?a.charAt(l):o:e?a.slice(l,l+2):s-56320+(o-55296<<10)+65536}};e.exports={codeAt:o(!1),charAt:o(!0)}},function(e,t,n){"use strict";var r=n(10),i=n(80),o=n(82),s=n(87),a=n(85),l=n(26),u=n(29),c=n(57),h=n(37),d=n(86),f=n(81),p=f.IteratorPrototype,g=f.BUGGY_SAFARI_ITERATORS,y=c("iterator"),m="keys",v="values",_="entries",b=function(){return this};e.exports=function(e,t,n,c,f,w,A){i(n,t,c);var S,k,x,C=function(e){if(e===f&&O)return O;if(!g&&e in T)return T[e];switch(e){case m:case v:case _:return function(){return new n(this,e)}}return function(){return new n(this)}},P=t+" Iterator",E=!1,T=e.prototype,R=T[y]||T["@@iterator"]||f&&T[f],O=!g&&R||C(f),I="Array"==t&&T.entries||R;if(I&&(S=o(I.call(new e)),p!==Object.prototype&&S.next&&(h||o(S)===p||(s?s(S,p):"function"!=typeof S[y]&&l(S,y,b)),a(S,P,!0,!0),h&&(d[P]=b))),f==v&&R&&R.name!==v&&(E=!0,O=function(){return R.call(this)}),h&&!A||T[y]===O||l(T,y,O),d[t]=O,f)if(k={values:C(v),keys:w?O:C(m),entries:C(_)},A)for(x in k)(g||E||!(x in T))&&u(T,x,k[x]);else r({target:t,proto:!0,forced:g||E},k);return k}},function(e,t,n){"use strict";var r=n(81).IteratorPrototype,i=n(71),o=n(16),s=n(85),a=n(86),l=function(){return this};e.exports=function(e,t,n){var u=t+" Iterator";return e.prototype=i(r,{next:o(1,n)}),s(e,u,!1,!0),a[u]=l,e}},function(e,t,n){"use strict";var r,i,o,s=n(82),a=n(26),l=n(23),u=n(57),c=n(37),h=u("iterator"),d=!1;[].keys&&("next"in(o=[].keys())?(i=s(s(o)))!==Object.prototype&&(r=i):d=!0),null==r&&(r={}),c||l(r,h)||a(r,h,(function(){return this})),e.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:d}},function(e,t,n){var r=n(23),i=n(83),o=n(35),s=n(84),a=o("IE_PROTO"),l=Object.prototype;e.exports=s?Object.getPrototypeOf:function(e){return e=i(e),r(e,a)?e[a]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?l:null}},function(e,t,n){var r=n(20);e.exports=function(e){return Object(r(e))}},function(e,t,n){var r=n(14);e.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},function(e,t,n){var r=n(27).f,i=n(23),o=n(57)("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,o)&&r(e,o,{configurable:!0,value:t})}},function(e,t){e.exports={}},function(e,t,n){var r=n(28),i=n(88);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(n,[]),t=n instanceof Array}catch(o){}return function(n,o){return r(n),i(o),t?e.call(n,o):n.__proto__=o,n}}():void 0)},function(e,t,n){var r=n(22);e.exports=function(e){if(!r(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},function(e,t,n){var r=n(10),i=n(90);r({target:"Array",stat:!0,forced:!n(97)((function(e){Array.from(e)}))},{from:i})},function(e,t,n){"use strict";var r=n(62),i=n(83),o=n(91),s=n(92),a=n(47),l=n(93),u=n(94);e.exports=function(e){var t,n,c,h,d,f,p=i(e),g="function"==typeof this?this:Array,y=arguments.length,m=y>1?arguments[1]:void 0,v=void 0!==m,_=u(p),b=0;if(v&&(m=r(m,y>2?arguments[2]:void 0,2)),null==_||g==Array&&s(_))for(n=new g(t=a(p.length));t>b;b++)f=v?m(p[b],b):p[b],l(n,b,f);else for(d=(h=_.call(p)).next,n=new g;!(c=d.call(h)).done;b++)f=v?o(h,m,[c.value,b],!0):c.value,l(n,b,f);return n.length=b,n}},function(e,t,n){var r=n(28);e.exports=function(e,t,n,i){try{return i?t(r(n)[0],n[1]):t(n)}catch(s){var o=e.return;throw void 0!==o&&r(o.call(e)),s}}},function(e,t,n){var r=n(57),i=n(86),o=r("iterator"),s=Array.prototype;e.exports=function(e){return void 0!==e&&(i.Array===e||s[o]===e)}},function(e,t,n){"use strict";var r=n(21),i=n(27),o=n(16);e.exports=function(e,t,n){var s=r(t);s in e?i.f(e,s,o(0,n)):e[s]=n}},function(e,t,n){var r=n(95),i=n(86),o=n(57)("iterator");e.exports=function(e){if(null!=e)return e[o]||e["@@iterator"]||i[r(e)]}},function(e,t,n){var r=n(96),i=n(19),o=n(57)("toStringTag"),s="Arguments"==i(function(){return arguments}());e.exports=r?i:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(n){}}(t=Object(e),o))?n:s?i(t):"Object"==(r=i(t))&&"function"==typeof t.callee?"Arguments":r}},function(e,t,n){var r={};r[n(57)("toStringTag")]="z",e.exports="[object z]"===String(r)},function(e,t,n){var r=n(57)("iterator"),i=!1;try{var o=0,s={next:function(){return{done:!!o++}},return:function(){i=!0}};s[r]=function(){return this},Array.from(s,(function(){throw 2}))}catch(a){}e.exports=function(e,t){if(!t&&!i)return!1;var n=!1;try{var o={};o[r]=function(){return{next:function(){return{done:n=!0}}}},e(o)}catch(a){}return n}},function(e,t,n){n(99);var r=n(43);e.exports=r.Object.assign},function(e,t,n){var r=n(10),i=n(100);r({target:"Object",stat:!0,forced:Object.assign!==i},{assign:i})},function(e,t,n){"use strict";var r=n(13),i=n(14),o=n(73),s=n(51),a=n(15),l=n(83),u=n(18),c=Object.assign,h=Object.defineProperty;e.exports=!c||i((function(){if(r&&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={},n=Symbol(),i="abcdefghijklmnopqrst";return e[n]=7,i.split("").forEach((function(e){t[e]=e})),7!=c({},e)[n]||o(c({},t)).join("")!=i}))?function(e,t){for(var n=l(e),i=arguments.length,c=1,h=s.f,d=a.f;i>c;)for(var f,p=u(arguments[c++]),g=h?o(p).concat(h(p)):o(p),y=g.length,m=0;y>m;)f=g[m++],r&&!d.call(p,f)||(n[f]=p[f]);return n}:c},function(e,t,n){n(102);var r=n(43);e.exports=r.Math.log2},function(e,t,n){var r=n(10),i=Math.log,o=Math.LN2;r({target:"Math",stat:!0},{log2:function(e){return i(e)/o}})},function(e,t,n){n(104);var r=n(43);e.exports=r.Number.isNaN},function(e,t,n){n(10)({target:"Number",stat:!0},{isNaN:function(e){return e!=e}})},function(e,t,n){n(106);var r=n(43);e.exports=r.Number.isInteger},function(e,t,n){n(10)({target:"Number",stat:!0},{isInteger:n(107)})},function(e,t,n){var r=n(22),i=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&i(e)===e}},function(e,t,n){n(109)},function(e,t,n){"use strict";var r=n(110),i=n(112),o=n(14),s=r.aTypedArray,a=r.aTypedArrayConstructor,l=[].slice;(0,r.exportTypedArrayMethod)("slice",(function(e,t){for(var n=l.call(s(this),e,t),r=i(this,this.constructor),o=0,u=n.length,c=new(a(r))(u);u>o;)c[o]=n[o++];return c}),o((function(){new Int8Array(1).slice()})))},function(e,t,n){"use strict";var r,i=n(111),o=n(13),s=n(11),a=n(22),l=n(23),u=n(95),c=n(26),h=n(29),d=n(27).f,f=n(82),p=n(87),g=n(57),y=n(38),m=s.Int8Array,v=m&&m.prototype,_=s.Uint8ClampedArray,b=_&&_.prototype,w=m&&f(m),A=v&&f(v),S=Object.prototype,k=S.isPrototypeOf,x=g("toStringTag"),C=y("TYPED_ARRAY_TAG"),P=i&&!!p&&"Opera"!==u(s.opera),E=!1,T={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},R=function(e){return a(e)&&l(T,u(e))};for(r in T)s[r]||(P=!1);if((!P||"function"!=typeof w||w===Function.prototype)&&(w=function(){throw TypeError("Incorrect invocation")},P))for(r in T)s[r]&&p(s[r],w);if((!P||!A||A===S)&&(A=w.prototype,P))for(r in T)s[r]&&p(s[r].prototype,A);if(P&&f(b)!==A&&p(b,A),o&&!l(A,x))for(r in E=!0,d(A,x,{get:function(){return a(this)?this[C]:void 0}}),T)s[r]&&c(s[r],C,r);e.exports={NATIVE_ARRAY_BUFFER_VIEWS:P,TYPED_ARRAY_TAG:E&&C,aTypedArray:function(e){if(R(e))return e;throw TypeError("Target is not a typed array")},aTypedArrayConstructor:function(e){if(p){if(k.call(w,e))return e}else for(var t in T)if(l(T,r)){var n=s[t];if(n&&(e===n||k.call(n,e)))return e}throw TypeError("Target is not a typed array constructor")},exportTypedArrayMethod:function(e,t,n){if(o){if(n)for(var r in T){var i=s[r];i&&l(i.prototype,e)&&delete i.prototype[e]}A[e]&&!n||h(A,e,n?t:P&&v[e]||t)}},exportTypedArrayStaticMethod:function(e,t,n){var r,i;if(o){if(p){if(n)for(r in T)(i=s[r])&&l(i,e)&&delete i[e];if(w[e]&&!n)return;try{return h(w,e,n?t:P&&m[e]||t)}catch(a){}}for(r in T)!(i=s[r])||i[e]&&!n||h(i,e,t)}},isView:function(e){var t=u(e);return"DataView"===t||l(T,t)},isTypedArray:R,TypedArray:w,TypedArrayPrototype:A}},function(e,t){e.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},function(e,t,n){var r=n(28),i=n(63),o=n(57)("species");e.exports=function(e,t){var n,s=r(e).constructor;return void 0===s||null==(n=r(s)[o])?t:i(n)}},function(e,t,n){n(114),n(77),n(116),n(119),n(134),n(135);var r=n(43);e.exports=r.Promise},function(e,t,n){var r=n(96),i=n(29),o=n(115);r||i(Object.prototype,"toString",o,{unsafe:!0})},function(e,t,n){"use strict";var r=n(96),i=n(95);e.exports=r?{}.toString:function(){return"[object "+i(this)+"]"}},function(e,t,n){var r=n(11),i=n(117),o=n(118),s=n(26),a=n(57),l=a("iterator"),u=a("toStringTag"),c=o.values;for(var h in i){var d=r[h],f=d&&d.prototype;if(f){if(f[l]!==c)try{s(f,l,c)}catch(g){f[l]=c}if(f[u]||s(f,u,h),i[h])for(var p in o)if(f[p]!==o[p])try{s(f,p,o[p])}catch(g){f[p]=o[p]}}}},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,n){"use strict";var r=n(17),i=n(70),o=n(86),s=n(33),a=n(79),l="Array Iterator",u=s.set,c=s.getterFor(l);e.exports=a(Array,"Array",(function(e,t){u(this,{type:l,target:r(e),index:0,kind:t})}),(function(){var e=c(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},function(e,t,n){"use strict";var r,i,o,s,a=n(10),l=n(37),u=n(11),c=n(42),h=n(120),d=n(29),f=n(121),p=n(85),g=n(122),y=n(22),m=n(63),v=n(123),_=n(19),b=n(31),w=n(124),A=n(97),S=n(112),k=n(125).set,x=n(128),C=n(129),P=n(131),E=n(130),T=n(132),R=n(33),O=n(52),I=n(57),L=n(133),M=I("species"),N="Promise",D=R.get,F=R.set,j=R.getterFor(N),B=h,q=u.TypeError,V=u.document,U=u.process,H=c("fetch"),W=E.f,z=W,G="process"==_(U),Q=!!(V&&V.createEvent&&u.dispatchEvent),Y="unhandledrejection",K=O(N,(function(){if(b(B)===String(B)){if(66===L)return!0;if(!G&&"function"!=typeof PromiseRejectionEvent)return!0}if(l&&!B.prototype.finally)return!0;if(L>=51&&/native code/.test(B))return!1;var e=B.resolve(1),t=function(e){e((function(){}),(function(){}))};return(e.constructor={})[M]=t,!(e.then((function(){}))instanceof t)})),X=K||!A((function(e){B.all(e).catch((function(){}))})),Z=function(e){var t;return!(!y(e)||"function"!=typeof(t=e.then))&&t},J=function(e,t,n){if(!t.notified){t.notified=!0;var r=t.reactions;x((function(){for(var i=t.value,o=1==t.state,s=0;r.length>s;){var a,l,u,c=r[s++],h=o?c.ok:c.fail,d=c.resolve,f=c.reject,p=c.domain;try{h?(o||(2===t.rejection&&ne(e,t),t.rejection=1),!0===h?a=i:(p&&p.enter(),a=h(i),p&&(p.exit(),u=!0)),a===c.promise?f(q("Promise-chain cycle")):(l=Z(a))?l.call(a,d,f):d(a)):f(i)}catch(g){p&&!u&&p.exit(),f(g)}}t.reactions=[],t.notified=!1,n&&!t.rejection&&ee(e,t)}))}},$=function(e,t,n){var r,i;Q?((r=V.createEvent("Event")).promise=t,r.reason=n,r.initEvent(e,!1,!0),u.dispatchEvent(r)):r={promise:t,reason:n},(i=u["on"+e])?i(r):e===Y&&P("Unhandled promise rejection",n)},ee=function(e,t){k.call(u,(function(){var n,r=t.value;if(te(t)&&(n=T((function(){G?U.emit("unhandledRejection",r,e):$(Y,e,r)})),t.rejection=G||te(t)?2:1,n.error))throw n.value}))},te=function(e){return 1!==e.rejection&&!e.parent},ne=function(e,t){k.call(u,(function(){G?U.emit("rejectionHandled",e):$("rejectionhandled",e,t.value)}))},re=function(e,t,n,r){return function(i){e(t,n,i,r)}},ie=function(e,t,n,r){t.done||(t.done=!0,r&&(t=r),t.value=n,t.state=2,J(e,t,!0))},oe=function(e,t,n,r){if(!t.done){t.done=!0,r&&(t=r);try{if(e===n)throw q("Promise can't be resolved itself");var i=Z(n);i?x((function(){var r={done:!1};try{i.call(n,re(oe,e,r,t),re(ie,e,r,t))}catch(o){ie(e,r,o,t)}})):(t.value=n,t.state=1,J(e,t,!1))}catch(o){ie(e,{done:!1},o,t)}}};K&&(B=function(e){v(this,B,N),m(e),r.call(this);var t=D(this);try{e(re(oe,this,t),re(ie,this,t))}catch(n){ie(this,t,n)}},(r=function(e){F(this,{type:N,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=f(B.prototype,{then:function(e,t){var n=j(this),r=W(S(this,B));return r.ok="function"!=typeof e||e,r.fail="function"==typeof t&&t,r.domain=G?U.domain:void 0,n.parent=!0,n.reactions.push(r),0!=n.state&&J(this,n,!1),r.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new r,t=D(e);this.promise=e,this.resolve=re(oe,e,t),this.reject=re(ie,e,t)},E.f=W=function(e){return e===B||e===o?new i(e):z(e)},l||"function"!=typeof h||(s=h.prototype.then,d(h.prototype,"then",(function(e,t){var n=this;return new B((function(e,t){s.call(n,e,t)})).then(e,t)}),{unsafe:!0}),"function"==typeof H&&a({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return C(B,H.apply(u,arguments))}}))),a({global:!0,wrap:!0,forced:K},{Promise:B}),p(B,N,!1,!0),g(N),o=c(N),a({target:N,stat:!0,forced:K},{reject:function(e){var t=W(this);return t.reject.call(void 0,e),t.promise}}),a({target:N,stat:!0,forced:l||K},{resolve:function(e){return C(l&&this===o?B:this,e)}}),a({target:N,stat:!0,forced:X},{all:function(e){var t=this,n=W(t),r=n.resolve,i=n.reject,o=T((function(){var n=m(t.resolve),o=[],s=0,a=1;w(e,(function(e){var l=s++,u=!1;o.push(void 0),a++,n.call(t,e).then((function(e){u||(u=!0,o[l]=e,--a||r(o))}),i)})),--a||r(o)}));return o.error&&i(o.value),n.promise},race:function(e){var t=this,n=W(t),r=n.reject,i=T((function(){var i=m(t.resolve);w(e,(function(e){i.call(t,e).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},function(e,t,n){var r=n(11);e.exports=r.Promise},function(e,t,n){var r=n(29);e.exports=function(e,t,n){for(var i in t)r(e,i,t[i],n);return e}},function(e,t,n){"use strict";var r=n(42),i=n(27),o=n(57),s=n(13),a=o("species");e.exports=function(e){var t=r(e);s&&t&&!t[a]&&(0,i.f)(t,a,{configurable:!0,get:function(){return this}})}},function(e,t){e.exports=function(e,t,n){if(!(e instanceof t))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return e}},function(e,t,n){var r=n(28),i=n(92),o=n(47),s=n(62),a=n(94),l=n(91),u=function(e,t){this.stopped=e,this.result=t};(e.exports=function(e,t,n,c,h){var d,f,p,g,y,m,v,_=s(t,n,c?2:1);if(h)d=e;else{if("function"!=typeof(f=a(e)))throw TypeError("Target is not iterable");if(i(f)){for(p=0,g=o(e.length);g>p;p++)if((y=c?_(r(v=e[p])[0],v[1]):_(e[p]))&&y instanceof u)return y;return new u(!1)}d=f.call(e)}for(m=d.next;!(v=m.call(d)).done;)if("object"==typeof(y=l(d,_,v.value,c))&&y&&y instanceof u)return y;return new u(!1)}).stop=function(e){return new u(!0,e)}},function(e,t,n){var r,i,o,s=n(11),a=n(14),l=n(19),u=n(62),c=n(74),h=n(25),d=n(126),f=s.location,p=s.setImmediate,g=s.clearImmediate,y=s.process,m=s.MessageChannel,v=s.Dispatch,_=0,b={},w=function(e){if(b.hasOwnProperty(e)){var t=b[e];delete b[e],t()}},A=function(e){return function(){w(e)}},S=function(e){w(e.data)},k=function(e){s.postMessage(e+"",f.protocol+"//"+f.host)};p&&g||(p=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return b[++_]=function(){("function"==typeof e?e:Function(e)).apply(void 0,t)},r(_),_},g=function(e){delete b[e]},"process"==l(y)?r=function(e){y.nextTick(A(e))}:v&&v.now?r=function(e){v.now(A(e))}:m&&!d?(o=(i=new m).port2,i.port1.onmessage=S,r=u(o.postMessage,o,1)):!s.addEventListener||"function"!=typeof postMessage||s.importScripts||a(k)||"file:"===f.protocol?r="onreadystatechange"in h("script")?function(e){c.appendChild(h("script")).onreadystatechange=function(){c.removeChild(this),w(e)}}:function(e){setTimeout(A(e),0)}:(r=k,s.addEventListener("message",S,!1))),e.exports={set:p,clear:g}},function(e,t,n){var r=n(127);e.exports=/(iphone|ipod|ipad).*applewebkit/i.test(r)},function(e,t,n){var r=n(42);e.exports=r("navigator","userAgent")||""},function(e,t,n){var r,i,o,s,a,l,u,c,h=n(11),d=n(12).f,f=n(19),p=n(125).set,g=n(126),y=h.MutationObserver||h.WebKitMutationObserver,m=h.process,v=h.Promise,_="process"==f(m),b=d(h,"queueMicrotask"),w=b&&b.value;w||(r=function(){var e,t;for(_&&(e=m.domain)&&e.exit();i;){t=i.fn,i=i.next;try{t()}catch(n){throw i?s():o=void 0,n}}o=void 0,e&&e.enter()},_?s=function(){m.nextTick(r)}:y&&!g?(a=!0,l=document.createTextNode(""),new y(r).observe(l,{characterData:!0}),s=function(){l.data=a=!a}):v&&v.resolve?(u=v.resolve(void 0),c=u.then,s=function(){c.call(u,r)}):s=function(){p.call(h,r)}),e.exports=w||function(e){var t={fn:e,next:void 0};o&&(o.next=t),i||(i=t,s()),o=t}},function(e,t,n){var r=n(28),i=n(22),o=n(130);e.exports=function(e,t){if(r(e),i(t)&&t.constructor===e)return t;var n=o.f(e);return(0,n.resolve)(t),n.promise}},function(e,t,n){"use strict";var r=n(63),i=function(e){var t,n;this.promise=new e((function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r})),this.resolve=r(t),this.reject=r(n)};e.exports.f=function(e){return new i(e)}},function(e,t,n){var r=n(11);e.exports=function(e,t){var n=r.console;n&&n.error&&(1===arguments.length?n.error(e):n.error(e,t))}},function(e,t){e.exports=function(e){try{return{error:!1,value:e()}}catch(t){return{error:!0,value:t}}}},function(e,t,n){var r,i,o=n(11),s=n(127),a=o.process,l=a&&a.versions,u=l&&l.v8;u?i=(r=u.split("."))[0]+r[1]:s&&(!(r=s.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/))&&(i=r[1]),e.exports=i&&+i},function(e,t,n){"use strict";var r=n(10),i=n(63),o=n(130),s=n(132),a=n(124);r({target:"Promise",stat:!0},{allSettled:function(e){var t=this,n=o.f(t),r=n.resolve,l=n.reject,u=s((function(){var n=i(t.resolve),o=[],s=0,l=1;a(e,(function(e){var i=s++,a=!1;o.push(void 0),l++,n.call(t,e).then((function(e){a||(a=!0,o[i]={status:"fulfilled",value:e},--l||r(o))}),(function(e){a||(a=!0,o[i]={status:"rejected",reason:e},--l||r(o))}))})),--l||r(o)}));return u.error&&l(u.value),n.promise}})},function(e,t,n){"use strict";var r=n(10),i=n(37),o=n(120),s=n(14),a=n(42),l=n(112),u=n(129),c=n(29);r({target:"Promise",proto:!0,real:!0,forced:!!o&&s((function(){o.prototype.finally.call({then:function(){}},(function(){}))}))},{finally:function(e){var t=l(this,a("Promise")),n="function"==typeof e;return this.then(n?function(n){return u(t,e()).then((function(){return n}))}:e,n?function(n){return u(t,e()).then((function(){throw n}))}:e)}}),i||"function"!=typeof o||o.prototype.finally||c(o.prototype,"finally",a("Promise").prototype.finally)},function(e,t,n){n(137),n(142),n(140);var r=n(43);e.exports=r.URL},function(e,t,n){"use strict";n(77);var r,i=n(10),o=n(13),s=n(138),a=n(11),l=n(72),u=n(29),c=n(123),h=n(23),d=n(100),f=n(90),p=n(78).codeAt,g=n(139),y=n(85),m=n(140),v=n(33),_=a.URL,b=m.URLSearchParams,w=m.getState,A=v.set,S=v.getterFor("URL"),k=Math.floor,x=Math.pow,C="Invalid scheme",P="Invalid host",E="Invalid port",T=/[A-Za-z]/,R=/[\d+-.A-Za-z]/,O=/\d/,I=/^(0x|0X)/,L=/^[0-7]+$/,M=/^\d+$/,N=/^[\dA-Fa-f]+$/,D=/[\u0000\u0009\u000A\u000D #%/:?@[\\]]/,F=/[\u0000\u0009\u000A\u000D #/:?@[\\]]/,j=/^[\u0000-\u001F ]+|[\u0000-\u001F ]+$/g,B=/[\u0009\u000A\u000D]/g,q=function(e,t){var n,r,i;if("["==t.charAt(0)){if("]"!=t.charAt(t.length-1))return P;if(!(n=U(t.slice(1,-1))))return P;e.host=n}else if(X(e)){if(t=g(t),D.test(t))return P;if(null===(n=V(t)))return P;e.host=n}else{if(F.test(t))return P;for(n="",r=f(t),i=0;i<r.length;i++)n+=Y(r[i],W);e.host=n}},V=function(e){var t,n,r,i,o,s,a,l=e.split(".");if(l.length&&""==l[l.length-1]&&l.pop(),(t=l.length)>4)return e;for(n=[],r=0;r<t;r++){if(""==(i=l[r]))return e;if(o=10,i.length>1&&"0"==i.charAt(0)&&(o=I.test(i)?16:8,i=i.slice(8==o?1:2)),""===i)s=0;else{if(!(10==o?M:8==o?L:N).test(i))return e;s=parseInt(i,o)}n.push(s)}for(r=0;r<t;r++)if(s=n[r],r==t-1){if(s>=x(256,5-t))return null}else if(s>255)return null;for(a=n.pop(),r=0;r<n.length;r++)a+=n[r]*x(256,3-r);return a},U=function(e){var t,n,r,i,o,s,a,l=[0,0,0,0,0,0,0,0],u=0,c=null,h=0,d=function(){return e.charAt(h)};if(":"==d()){if(":"!=e.charAt(1))return;h+=2,c=++u}for(;d();){if(8==u)return;if(":"!=d()){for(t=n=0;n<4&&N.test(d());)t=16*t+parseInt(d(),16),h++,n++;if("."==d()){if(0==n)return;if(h-=n,u>6)return;for(r=0;d();){if(i=null,r>0){if(!("."==d()&&r<4))return;h++}if(!O.test(d()))return;for(;O.test(d());){if(o=parseInt(d(),10),null===i)i=o;else{if(0==i)return;i=10*i+o}if(i>255)return;h++}l[u]=256*l[u]+i,2!=++r&&4!=r||u++}if(4!=r)return;break}if(":"==d()){if(h++,!d())return}else if(d())return;l[u++]=t}else{if(null!==c)return;h++,c=++u}}if(null!==c)for(s=u-c,u=7;0!=u&&s>0;)a=l[u],l[u--]=l[c+s-1],l[c+--s]=a;else if(8!=u)return;return l},H=function(e){var t,n,r,i;if("number"==typeof e){for(t=[],n=0;n<4;n++)t.unshift(e%256),e=k(e/256);return t.join(".")}if("object"==typeof e){for(t="",r=function(e){for(var t=null,n=1,r=null,i=0,o=0;o<8;o++)0!==e[o]?(i>n&&(t=r,n=i),r=null,i=0):(null===r&&(r=o),++i);return i>n&&(t=r,n=i),t}(e),n=0;n<8;n++)i&&0===e[n]||(i&&(i=!1),r===n?(t+=n?":":"::",i=!0):(t+=e[n].toString(16),n<7&&(t+=":")));return"["+t+"]"}return e},W={},z=d({},W,{" ":1,'"':1,"<":1,">":1,"`":1}),G=d({},z,{"#":1,"?":1,"{":1,"}":1}),Q=d({},G,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),Y=function(e,t){var n=p(e,0);return n>32&&n<127&&!h(t,e)?e:encodeURIComponent(e)},K={ftp:21,file:null,http:80,https:443,ws:80,wss:443},X=function(e){return h(K,e.scheme)},Z=function(e){return""!=e.username||""!=e.password},J=function(e){return!e.host||e.cannotBeABaseURL||"file"==e.scheme},$=function(e,t){var n;return 2==e.length&&T.test(e.charAt(0))&&(":"==(n=e.charAt(1))||!t&&"|"==n)},ee=function(e){var t;return e.length>1&&$(e.slice(0,2))&&(2==e.length||"/"===(t=e.charAt(2))||"\\"===t||"?"===t||"#"===t)},te=function(e){var t=e.path,n=t.length;!n||"file"==e.scheme&&1==n&&$(t[0],!0)||t.pop()},ne=function(e){return"."===e||"%2e"===e.toLowerCase()},re={},ie={},oe={},se={},ae={},le={},ue={},ce={},he={},de={},fe={},pe={},ge={},ye={},me={},ve={},_e={},be={},we={},Ae={},Se={},ke=function(e,t,n,i){var o,s,a,l,u,c=n||re,d=0,p="",g=!1,y=!1,m=!1;for(n||(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(j,"")),t=t.replace(B,""),o=f(t);d<=o.length;){switch(s=o[d],c){case re:if(!s||!T.test(s)){if(n)return C;c=oe;continue}p+=s.toLowerCase(),c=ie;break;case ie:if(s&&(R.test(s)||"+"==s||"-"==s||"."==s))p+=s.toLowerCase();else{if(":"!=s){if(n)return C;p="",c=oe,d=0;continue}if(n&&(X(e)!=h(K,p)||"file"==p&&(Z(e)||null!==e.port)||"file"==e.scheme&&!e.host))return;if(e.scheme=p,n)return void(X(e)&&K[e.scheme]==e.port&&(e.port=null));p="","file"==e.scheme?c=ye:X(e)&&i&&i.scheme==e.scheme?c=se:X(e)?c=ce:"/"==o[d+1]?(c=ae,d++):(e.cannotBeABaseURL=!0,e.path.push(""),c=we)}break;case oe:if(!i||i.cannotBeABaseURL&&"#"!=s)return C;if(i.cannotBeABaseURL&&"#"==s){e.scheme=i.scheme,e.path=i.path.slice(),e.query=i.query,e.fragment="",e.cannotBeABaseURL=!0,c=Se;break}c="file"==i.scheme?ye:le;continue;case se:if("/"!=s||"/"!=o[d+1]){c=le;continue}c=he,d++;break;case ae:if("/"==s){c=de;break}c=be;continue;case le:if(e.scheme=i.scheme,s==r)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("/"==s||"\\"==s&&X(e))c=ue;else if("?"==s)e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query="",c=Ae;else{if("#"!=s){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.path.pop(),c=be;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="",c=Se}break;case ue:if(!X(e)||"/"!=s&&"\\"!=s){if("/"!=s){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,c=be;continue}c=de}else c=he;break;case ce:if(c=he,"/"!=s||"/"!=p.charAt(d+1))continue;d++;break;case he:if("/"!=s&&"\\"!=s){c=de;continue}break;case de:if("@"==s){g&&(p="%40"+p),g=!0,a=f(p);for(var v=0;v<a.length;v++){var _=a[v];if(":"!=_||m){var b=Y(_,Q);m?e.password+=b:e.username+=b}else m=!0}p=""}else if(s==r||"/"==s||"?"==s||"#"==s||"\\"==s&&X(e)){if(g&&""==p)return"Invalid authority";d-=f(p).length+1,p="",c=fe}else p+=s;break;case fe:case pe:if(n&&"file"==e.scheme){c=ve;continue}if(":"!=s||y){if(s==r||"/"==s||"?"==s||"#"==s||"\\"==s&&X(e)){if(X(e)&&""==p)return P;if(n&&""==p&&(Z(e)||null!==e.port))return;if(l=q(e,p))return l;if(p="",c=_e,n)return;continue}"["==s?y=!0:"]"==s&&(y=!1),p+=s}else{if(""==p)return P;if(l=q(e,p))return l;if(p="",c=ge,n==pe)return}break;case ge:if(!O.test(s)){if(s==r||"/"==s||"?"==s||"#"==s||"\\"==s&&X(e)||n){if(""!=p){var w=parseInt(p,10);if(w>65535)return E;e.port=X(e)&&w===K[e.scheme]?null:w,p=""}if(n)return;c=_e;continue}return E}p+=s;break;case ye:if(e.scheme="file","/"==s||"\\"==s)c=me;else{if(!i||"file"!=i.scheme){c=be;continue}if(s==r)e.host=i.host,e.path=i.path.slice(),e.query=i.query;else if("?"==s)e.host=i.host,e.path=i.path.slice(),e.query="",c=Ae;else{if("#"!=s){ee(o.slice(d).join(""))||(e.host=i.host,e.path=i.path.slice(),te(e)),c=be;continue}e.host=i.host,e.path=i.path.slice(),e.query=i.query,e.fragment="",c=Se}}break;case me:if("/"==s||"\\"==s){c=ve;break}i&&"file"==i.scheme&&!ee(o.slice(d).join(""))&&($(i.path[0],!0)?e.path.push(i.path[0]):e.host=i.host),c=be;continue;case ve:if(s==r||"/"==s||"\\"==s||"?"==s||"#"==s){if(!n&&$(p))c=be;else if(""==p){if(e.host="",n)return;c=_e}else{if(l=q(e,p))return l;if("localhost"==e.host&&(e.host=""),n)return;p="",c=_e}continue}p+=s;break;case _e:if(X(e)){if(c=be,"/"!=s&&"\\"!=s)continue}else if(n||"?"!=s)if(n||"#"!=s){if(s!=r&&(c=be,"/"!=s))continue}else e.fragment="",c=Se;else e.query="",c=Ae;break;case be:if(s==r||"/"==s||"\\"==s&&X(e)||!n&&("?"==s||"#"==s)){if(".."===(u=(u=p).toLowerCase())||"%2e."===u||".%2e"===u||"%2e%2e"===u?(te(e),"/"==s||"\\"==s&&X(e)||e.path.push("")):ne(p)?"/"==s||"\\"==s&&X(e)||e.path.push(""):("file"==e.scheme&&!e.path.length&&$(p)&&(e.host&&(e.host=""),p=p.charAt(0)+":"),e.path.push(p)),p="","file"==e.scheme&&(s==r||"?"==s||"#"==s))for(;e.path.length>1&&""===e.path[0];)e.path.shift();"?"==s?(e.query="",c=Ae):"#"==s&&(e.fragment="",c=Se)}else p+=Y(s,G);break;case we:"?"==s?(e.query="",c=Ae):"#"==s?(e.fragment="",c=Se):s!=r&&(e.path[0]+=Y(s,W));break;case Ae:n||"#"!=s?s!=r&&("'"==s&&X(e)?e.query+="%27":e.query+="#"==s?"%23":Y(s,W)):(e.fragment="",c=Se);break;case Se:s!=r&&(e.fragment+=Y(s,z))}d++}},xe=function(e){var t,n,r=c(this,xe,"URL"),i=arguments.length>1?arguments[1]:void 0,s=String(e),a=A(r,{type:"URL"});if(void 0!==i)if(i instanceof xe)t=S(i);else if(n=ke(t={},String(i)))throw TypeError(n);if(n=ke(a,s,null,t))throw TypeError(n);var l=a.searchParams=new b,u=w(l);u.updateSearchParams(a.query),u.updateURL=function(){a.query=String(l)||null},o||(r.href=Pe.call(r),r.origin=Ee.call(r),r.protocol=Te.call(r),r.username=Re.call(r),r.password=Oe.call(r),r.host=Ie.call(r),r.hostname=Le.call(r),r.port=Me.call(r),r.pathname=Ne.call(r),r.search=De.call(r),r.searchParams=Fe.call(r),r.hash=je.call(r))},Ce=xe.prototype,Pe=function(){var e=S(this),t=e.scheme,n=e.username,r=e.password,i=e.host,o=e.port,s=e.path,a=e.query,l=e.fragment,u=t+":";return null!==i?(u+="//",Z(e)&&(u+=n+(r?":"+r:"")+"@"),u+=H(i),null!==o&&(u+=":"+o)):"file"==t&&(u+="//"),u+=e.cannotBeABaseURL?s[0]:s.length?"/"+s.join("/"):"",null!==a&&(u+="?"+a),null!==l&&(u+="#"+l),u},Ee=function(){var e=S(this),t=e.scheme,n=e.port;if("blob"==t)try{return new URL(t.path[0]).origin}catch(r){return"null"}return"file"!=t&&X(e)?t+"://"+H(e.host)+(null!==n?":"+n:""):"null"},Te=function(){return S(this).scheme+":"},Re=function(){return S(this).username},Oe=function(){return S(this).password},Ie=function(){var e=S(this),t=e.host,n=e.port;return null===t?"":null===n?H(t):H(t)+":"+n},Le=function(){var e=S(this).host;return null===e?"":H(e)},Me=function(){var e=S(this).port;return null===e?"":String(e)},Ne=function(){var e=S(this),t=e.path;return e.cannotBeABaseURL?t[0]:t.length?"/"+t.join("/"):""},De=function(){var e=S(this).query;return e?"?"+e:""},Fe=function(){return S(this).searchParams},je=function(){var e=S(this).fragment;return e?"#"+e:""},Be=function(e,t){return{get:e,set:t,configurable:!0,enumerable:!0}};if(o&&l(Ce,{href:Be(Pe,(function(e){var t=S(this),n=String(e),r=ke(t,n);if(r)throw TypeError(r);w(t.searchParams).updateSearchParams(t.query)})),origin:Be(Ee),protocol:Be(Te,(function(e){var t=S(this);ke(t,String(e)+":",re)})),username:Be(Re,(function(e){var t=S(this),n=f(String(e));if(!J(t)){t.username="";for(var r=0;r<n.length;r++)t.username+=Y(n[r],Q)}})),password:Be(Oe,(function(e){var t=S(this),n=f(String(e));if(!J(t)){t.password="";for(var r=0;r<n.length;r++)t.password+=Y(n[r],Q)}})),host:Be(Ie,(function(e){var t=S(this);t.cannotBeABaseURL||ke(t,String(e),fe)})),hostname:Be(Le,(function(e){var t=S(this);t.cannotBeABaseURL||ke(t,String(e),pe)})),port:Be(Me,(function(e){var t=S(this);J(t)||(""==(e=String(e))?t.port=null:ke(t,e,ge))})),pathname:Be(Ne,(function(e){var t=S(this);t.cannotBeABaseURL||(t.path=[],ke(t,e+"",_e))})),search:Be(De,(function(e){var t=S(this);""==(e=String(e))?t.query=null:("?"==e.charAt(0)&&(e=e.slice(1)),t.query="",ke(t,e,Ae)),w(t.searchParams).updateSearchParams(t.query)})),searchParams:Be(Fe),hash:Be(je,(function(e){var t=S(this);""!=(e=String(e))?("#"==e.charAt(0)&&(e=e.slice(1)),t.fragment="",ke(t,e,Se)):t.fragment=null}))}),u(Ce,"toJSON",(function(){return Pe.call(this)}),{enumerable:!0}),u(Ce,"toString",(function(){return Pe.call(this)}),{enumerable:!0}),_){var qe=_.createObjectURL,Ve=_.revokeObjectURL;qe&&u(xe,"createObjectURL",(function(e){return qe.apply(_,arguments)})),Ve&&u(xe,"revokeObjectURL",(function(e){return Ve.apply(_,arguments)}))}y(xe,"URL"),i({global:!0,forced:!s,sham:!o},{URL:xe})},function(e,t,n){var r=n(14),i=n(57),o=n(37),s=i("iterator");e.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t.delete("b"),n+=r+e})),o&&!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[s]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://\u0442\u0435\u0441\u0442").host||"#%D0%B1"!==new URL("http://a#\u0431").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},function(e,t,n){"use strict";var r=2147483647,i=/[^\0-\u007E]/,o=/[.\u3002\uFF0E\uFF61]/g,s="Overflow: input needs wider integers to process",a=Math.floor,l=String.fromCharCode,u=function(e){return e+22+75*(e<26)},c=function(e,t,n){var r=0;for(e=n?a(e/700):e>>1,e+=a(e/t);e>455;r+=36)e=a(e/35);return a(r+36*e/(e+38))},h=function(e){var t,n,i=[],o=(e=function(e){for(var t=[],n=0,r=e.length;n<r;){var i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){var o=e.charCodeAt(n++);56320==(64512&o)?t.push(((1023&i)<<10)+(1023&o)+65536):(t.push(i),n--)}else t.push(i)}return t}(e)).length,h=128,d=0,f=72;for(t=0;t<e.length;t++)(n=e[t])<128&&i.push(l(n));var p=i.length,g=p;for(p&&i.push("-");g<o;){var y=r;for(t=0;t<e.length;t++)(n=e[t])>=h&&n<y&&(y=n);var m=g+1;if(y-h>a((r-d)/m))throw RangeError(s);for(d+=(y-h)*m,h=y,t=0;t<e.length;t++){if((n=e[t])<h&&++d>r)throw RangeError(s);if(n==h){for(var v=d,_=36;;_+=36){var b=_<=f?1:_>=f+26?26:_-f;if(v<b)break;var w=v-b,A=36-b;i.push(l(u(b+w%A))),v=a(w/A)}i.push(l(u(v))),f=c(d,m,g==p),d=0,++g}}++d,++h}return i.join("")};e.exports=function(e){var t,n,r=[],s=e.toLowerCase().replace(o,".").split(".");for(t=0;t<s.length;t++)r.push(i.test(n=s[t])?"xn--"+h(n):n);return r.join(".")}},function(e,t,n){"use strict";n(118);var r=n(10),i=n(42),o=n(138),s=n(29),a=n(121),l=n(85),u=n(80),c=n(33),h=n(123),d=n(23),f=n(62),p=n(95),g=n(28),y=n(22),m=n(71),v=n(16),_=n(141),b=n(94),w=n(57),A=i("fetch"),S=i("Headers"),k=w("iterator"),x="URLSearchParams",C="URLSearchParamsIterator",P=c.set,E=c.getterFor(x),T=c.getterFor(C),R=/\+/g,O=Array(4),I=function(e){return O[e-1]||(O[e-1]=RegExp("((?:%[\\da-f]{2}){"+e+"})","gi"))},L=function(e){try{return decodeURIComponent(e)}catch(t){return e}},M=function(e){var t=e.replace(R," "),n=4;try{return decodeURIComponent(t)}catch(r){for(;n;)t=t.replace(I(n--),L);return t}},N=/[!'()~]|%20/g,D={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},F=function(e){return D[e]},j=function(e){return encodeURIComponent(e).replace(N,F)},B=function(e,t){if(t)for(var n,r,i=t.split("&"),o=0;o<i.length;)(n=i[o++]).length&&(r=n.split("="),e.push({key:M(r.shift()),value:M(r.join("="))}))},q=function(e){this.entries.length=0,B(this.entries,e)},V=function(e,t){if(e<t)throw TypeError("Not enough arguments")},U=u((function(e,t){P(this,{type:C,iterator:_(E(e).entries),kind:t})}),"Iterator",(function(){var e=T(this),t=e.kind,n=e.iterator.next(),r=n.value;return n.done||(n.value="keys"===t?r.key:"values"===t?r.value:[r.key,r.value]),n})),H=function(){h(this,H,x);var e,t,n,r,i,o,s,a,l,u=arguments.length>0?arguments[0]:void 0,c=this,f=[];if(P(c,{type:x,entries:f,updateURL:function(){},updateSearchParams:q}),void 0!==u)if(y(u))if("function"==typeof(e=b(u)))for(n=(t=e.call(u)).next;!(r=n.call(t)).done;){if((s=(o=(i=_(g(r.value))).next).call(i)).done||(a=o.call(i)).done||!o.call(i).done)throw TypeError("Expected sequence with length 2");f.push({key:s.value+"",value:a.value+""})}else for(l in u)d(u,l)&&f.push({key:l,value:u[l]+""});else B(f,"string"==typeof u?"?"===u.charAt(0)?u.slice(1):u:u+"")},W=H.prototype;a(W,{append:function(e,t){V(arguments.length,2);var n=E(this);n.entries.push({key:e+"",value:t+""}),n.updateURL()},delete:function(e){V(arguments.length,1);for(var t=E(this),n=t.entries,r=e+"",i=0;i<n.length;)n[i].key===r?n.splice(i,1):i++;t.updateURL()},get:function(e){V(arguments.length,1);for(var t=E(this).entries,n=e+"",r=0;r<t.length;r++)if(t[r].key===n)return t[r].value;return null},getAll:function(e){V(arguments.length,1);for(var t=E(this).entries,n=e+"",r=[],i=0;i<t.length;i++)t[i].key===n&&r.push(t[i].value);return r},has:function(e){V(arguments.length,1);for(var t=E(this).entries,n=e+"",r=0;r<t.length;)if(t[r++].key===n)return!0;return!1},set:function(e,t){V(arguments.length,1);for(var n,r=E(this),i=r.entries,o=!1,s=e+"",a=t+"",l=0;l<i.length;l++)(n=i[l]).key===s&&(o?i.splice(l--,1):(o=!0,n.value=a));o||i.push({key:s,value:a}),r.updateURL()},sort:function(){var e,t,n,r=E(this),i=r.entries,o=i.slice();for(i.length=0,n=0;n<o.length;n++){for(e=o[n],t=0;t<n;t++)if(i[t].key>e.key){i.splice(t,0,e);break}t===n&&i.push(e)}r.updateURL()},forEach:function(e){for(var t,n=E(this).entries,r=f(e,arguments.length>1?arguments[1]:void 0,3),i=0;i<n.length;)r((t=n[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}),s(W,k,W.entries),s(W,"toString",(function(){for(var e,t=E(this).entries,n=[],r=0;r<t.length;)e=t[r++],n.push(j(e.key)+"="+j(e.value));return n.join("&")}),{enumerable:!0}),l(H,x),r({global:!0,forced:!o},{URLSearchParams:H}),o||"function"!=typeof A||"function"!=typeof S||r({global:!0,enumerable:!0,forced:!0},{fetch:function(e){var t,n,r,i=[e];return arguments.length>1&&(y(t=arguments[1])&&p(n=t.body)===x&&((r=t.headers?new S(t.headers):new S).has("content-type")||r.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"),t=m(t,{body:v(0,String(n)),headers:v(0,r)})),i.push(t)),A.apply(this,i)}}),e.exports={URLSearchParams:H,getState:E}},function(e,t,n){var r=n(28),i=n(94);e.exports=function(e){var t=i(e);if("function"!=typeof t)throw TypeError(String(e)+" is not iterable");return r(t.call(e))}},function(e,t,n){"use strict";n(10)({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return URL.prototype.toString.call(this)}})},function(e,t,n){!function(e){"use strict";var t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol:function(e){return"Symbol("+e+")"};function n(){}var r=Number.isNaN||function(e){return e!=e},i=n;function o(e){return"object"==typeof e&&null!==e||"function"==typeof e}function s(e){return e.slice()}function a(e){return!1!==function(e){return!("number"!=typeof e||r(e)||e<0)}(e)&&e!==1/0}function l(e,t,n){if("function"!=typeof e)throw new TypeError("Argument is not a function");return Function.prototype.apply.call(e,t,n)}function u(e,t,n,r){var i=e[t];if(void 0!==i){if("function"!=typeof i)throw new TypeError(i+" is not a method");switch(n){case 0:return function(){return h(i,e,r)};case 1:return function(t){var n=[t].concat(r);return h(i,e,n)}}}return function(){return _(void 0)}}function c(e,t,n){var r=e[t];if(void 0!==r)return l(r,e,n)}function h(e,t,n){try{return _(l(e,t,n))}catch(r){return b(r)}}function d(e){if(e=Number(e),r(e)||e<0)throw new RangeError("highWaterMark property of a queuing strategy must be non-negative and non-NaN");return e}function f(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 p=Promise,g=Promise.prototype.then,y=Promise.resolve.bind(p),m=Promise.reject.bind(p);function v(e){return new p(e)}function _(e){return y(e)}function b(e){return m(e)}function w(e,t,n){return g.call(e,t,n)}function A(e,t,n){w(w(e,t,n),void 0,i)}function S(e,t){A(e,t)}function k(e,t){A(e,void 0,t)}function x(e,t,n){return w(e,t,n)}function C(e){w(e,void 0,i)}var P=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,n=t;16383===t._elements.length&&(n={_elements:[],_next:void 0}),t._elements.push(e),n!==t&&(this._back=n,t._next=n),++this._size},e.prototype.shift=function(){var e=this._front,t=e,n=this._cursor,r=n+1,i=e._elements,o=i[n];return 16384===r&&(t=e._next,r=0),--this._size,this._cursor=r,e!==t&&(this._front=t),i[n]=void 0,o},e.prototype.forEach=function(e){for(var t=this._cursor,n=this._front,r=n._elements;!(t===r.length&&void 0===n._next||t===r.length&&(t=0,0===(r=(n=n._next)._elements).length));)e(r[t]),++t},e.prototype.peek=function(){return this._front._elements[this._cursor]},e}();function E(e,t,n){var r=null;!0===n&&(r=Object.prototype);var i=Object.create(r);return i.value=e,i.done=t,i}function T(e,t){e._forAuthorCode=!0,e._ownerReadableStream=t,t._reader=e,"readable"===t._state?L(e):"closed"===t._state?function(e){L(e),D(e)}(e):M(e,t._storedError)}function R(e,t){return jt(e._ownerReadableStream,t)}function O(e){"readable"===e._ownerReadableStream._state?N(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):function(e,t){M(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness"))}(e),e._ownerReadableStream._reader=void 0,e._ownerReadableStream=void 0}function I(e){return new TypeError("Cannot "+e+" a stream using a released reader")}function L(e){e._closedPromise=v((function(t,n){e._closedPromise_resolve=t,e._closedPromise_reject=n}))}function M(e,t){L(e),N(e,t)}function N(e,t){C(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0}function D(e){e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0}var F=t("[[CancelSteps]]"),j=t("[[PullSteps]]");function B(e,t){void 0===t&&(t=!1);var n=new G(e);return n._forAuthorCode=t,n}function q(e){return v((function(t,n){e._reader._readRequests.push({_resolve:t,_reject:n})}))}function V(e,t,n){var r=e._reader;r._readRequests.shift()._resolve(E(t,n,r._forAuthorCode))}function U(e){return e._reader._readRequests.length}function H(e){var t=e._reader;return void 0!==t&&!!Q(t)}var W,z,G=function(){function e(e){if(!1===Dt(e))throw new TypeError("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(!0===Ft(e))throw new TypeError("This stream has already been locked for exclusive reading by another reader");T(this,e),this._readRequests=new P}return Object.defineProperty(e.prototype,"closed",{get:function(){return Q(this)?this._closedPromise:b(K("closed"))},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return Q(this)?void 0===this._ownerReadableStream?b(I("cancel")):R(this,e):b(K("cancel"))},e.prototype.read=function(){return Q(this)?void 0===this._ownerReadableStream?b(I("read from")):Y(this):b(K("read"))},e.prototype.releaseLock=function(){if(!Q(this))throw K("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");O(this)}},e}();function Q(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readRequests")}function Y(e){var t=e._ownerReadableStream;return t._disturbed=!0,"closed"===t._state?_(E(void 0,!0,e._forAuthorCode)):"errored"===t._state?b(t._storedError):t._readableStreamController[j]()}function K(e){return new TypeError("ReadableStreamDefaultReader.prototype."+e+" can only be used on a ReadableStreamDefaultReader")}"symbol"==typeof t.asyncIterator&&((W={})[t.asyncIterator]=function(){return this},z=W,Object.defineProperty(z,t.asyncIterator,{enumerable:!1}));var X={next:function(){if(!1===Z(this))return b(J("next"));var e=this._asyncIteratorReader;return void 0===e._ownerReadableStream?b(I("iterate")):x(Y(e),(function(t){var n=t.done;return n&&O(e),E(t.value,n,!0)}))},return:function(e){if(!1===Z(this))return b(J("next"));var t=this._asyncIteratorReader;if(void 0===t._ownerReadableStream)return b(I("finish iterating"));if(t._readRequests.length>0)return b(new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled"));if(!1===this._preventCancel){var n=R(t,e);return O(t),x(n,(function(){return E(e,!0,!0)}))}return O(t),_(E(e,!0,!0))}};function Z(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_asyncIteratorReader")}function J(e){return new TypeError("ReadableStreamAsyncIterator."+e+" can only be used on a ReadableSteamAsyncIterator")}function $(e){var t=e._queue.shift();return e._queueTotalSize-=t.size,e._queueTotalSize<0&&(e._queueTotalSize=0),t.value}function ee(e,t,n){if(!a(n=Number(n)))throw new RangeError("Size must be a finite, non-NaN, non-negative number.");e._queue.push({value:t,size:n}),e._queueTotalSize+=n}function te(e){e._queue=new P,e._queueTotalSize=0}void 0!==z&&Object.setPrototypeOf(X,z),Object.defineProperty(X,"next",{enumerable:!1}),Object.defineProperty(X,"return",{enumerable:!1});var ne=t("[[AbortSteps]]"),re=t("[[ErrorSteps]]"),ie=function(){function e(e,t){void 0===e&&(e={}),void 0===t&&(t={}),se(this);var n=t.size,r=t.highWaterMark;if(void 0!==e.type)throw new RangeError("Invalid type is specified");var i=f(n);void 0===r&&(r=1),function(e,t,n,r){var i=Object.create(Se.prototype);var o=u(t,"write",1,[i]),s=u(t,"close",0,[]),a=u(t,"abort",1,[]);ke(e,i,(function(){return c(t,"start",[i])}),o,s,a,n,r)}(this,e,r=d(r),i)}return Object.defineProperty(e.prototype,"locked",{get:function(){if(!1===ae(this))throw Oe("locked");return le(this)},enumerable:!0,configurable:!0}),e.prototype.abort=function(e){return!1===ae(this)?b(Oe("abort")):!0===le(this)?b(new TypeError("Cannot abort a stream that already has a writer")):ue(this,e)},e.prototype.close=function(){return!1===ae(this)?b(Oe("close")):!0===le(this)?b(new TypeError("Cannot close a stream that already has a writer")):!0===pe(this)?b(new TypeError("Cannot close an already-closing stream")):ce(this)},e.prototype.getWriter=function(){if(!1===ae(this))throw Oe("getWriter");return oe(this)},e}();function oe(e){return new me(e)}function se(e){e._state="writable",e._storedError=void 0,e._writer=void 0,e._writableStreamController=void 0,e._writeRequests=new P,e._inFlightWriteRequest=void 0,e._closeRequest=void 0,e._inFlightCloseRequest=void 0,e._pendingAbortRequest=void 0,e._backpressure=!1}function ae(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_writableStreamController")}function le(e){return void 0!==e._writer}function ue(e,t){var n=e._state;if("closed"===n||"errored"===n)return _(void 0);if(void 0!==e._pendingAbortRequest)return e._pendingAbortRequest._promise;var r=!1;"erroring"===n&&(r=!0,t=void 0);var i=v((function(n,i){e._pendingAbortRequest={_promise:void 0,_resolve:n,_reject:i,_reason:t,_wasAlreadyErroring:r}}));return e._pendingAbortRequest._promise=i,!1===r&&de(e,t),i}function ce(e){var t=e._state;if("closed"===t||"errored"===t)return b(new TypeError("The stream (in "+t+" state) is not in the writable state and cannot be closed"));var n,r=v((function(t,n){e._closeRequest={_resolve:t,_reject:n}})),i=e._writer;return void 0!==i&&!0===e._backpressure&&"writable"===t&&Ue(i),ee(n=e._writableStreamController,"close",0),Pe(n),r}function he(e,t){"writable"!==e._state?fe(e):de(e,t)}function de(e,t){var n=e._writableStreamController;e._state="erroring",e._storedError=t;var r=e._writer;void 0!==r&&be(r,t),!1===function(e){return void 0!==e._inFlightWriteRequest||void 0!==e._inFlightCloseRequest}(e)&&!0===n._started&&fe(e)}function fe(e){e._state="errored",e._writableStreamController[re]();var t=e._storedError;if(e._writeRequests.forEach((function(e){e._reject(t)})),e._writeRequests=new P,void 0!==e._pendingAbortRequest){var n=e._pendingAbortRequest;if(e._pendingAbortRequest=void 0,!0===n._wasAlreadyErroring)return n._reject(t),void ge(e);A(e._writableStreamController[ne](n._reason),(function(){n._resolve(),ge(e)}),(function(t){n._reject(t),ge(e)}))}else ge(e)}function pe(e){return void 0!==e._closeRequest||void 0!==e._inFlightCloseRequest}function ge(e){void 0!==e._closeRequest&&(e._closeRequest._reject(e._storedError),e._closeRequest=void 0);var t=e._writer;void 0!==t&&De(t,e._storedError)}function ye(e,t){var n=e._writer;void 0!==n&&t!==e._backpressure&&(!0===t?function(e){je(e)}(n):Ue(n)),e._backpressure=t}var me=function(){function e(e){if(!1===ae(e))throw new TypeError("WritableStreamDefaultWriter can only be constructed with a WritableStream instance");if(!0===le(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===pe(e)&&!0===e._backpressure?je(this):qe(this),Me(this);else if("erroring"===t)Be(this,e._storedError),Me(this);else if("closed"===t)qe(this),Me(this),Fe(this);else{var n=e._storedError;Be(this,n),Ne(this,n)}}return Object.defineProperty(e.prototype,"closed",{get:function(){return!1===ve(this)?b(Ie("closed")):this._closedPromise},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===ve(this))throw Ie("desiredSize");if(void 0===this._ownerWritableStream)throw Le("desiredSize");return"errored"===(t=(e=this._ownerWritableStream)._state)||"erroring"===t?null:"closed"===t?0:Ce(e._writableStreamController);var e,t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"ready",{get:function(){return!1===ve(this)?b(Ie("ready")):this._readyPromise},enumerable:!0,configurable:!0}),e.prototype.abort=function(e){return!1===ve(this)?b(Ie("abort")):void 0===this._ownerWritableStream?b(Le("abort")):function(e,t){return ue(e._ownerWritableStream,t)}(this,e)},e.prototype.close=function(){if(!1===ve(this))return b(Ie("close"));var e=this._ownerWritableStream;return void 0===e?b(Le("close")):!0===pe(e)?b(new TypeError("Cannot close an already-closing stream")):_e(this)},e.prototype.releaseLock=function(){if(!1===ve(this))throw Ie("releaseLock");void 0!==this._ownerWritableStream&&we(this)},e.prototype.write=function(e){return!1===ve(this)?b(Ie("write")):void 0===this._ownerWritableStream?b(Le("write to")):Ae(this,e)},e}();function ve(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_ownerWritableStream")}function _e(e){return ce(e._ownerWritableStream)}function be(e,t){"pending"===e._readyPromiseState?Ve(e,t):function(e,t){Be(e,t)}(e,t)}function we(e){var t=e._ownerWritableStream,n=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");be(e,n),function(e,t){"pending"===e._closedPromiseState?De(e,t):function(e,t){Ne(e,t)}(e,t)}(e,n),t._writer=void 0,e._ownerWritableStream=void 0}function Ae(e,t){var n=e._ownerWritableStream,r=n._writableStreamController,i=function(e,t){try{return e._strategySizeAlgorithm(t)}catch(n){return Ee(e,n),1}}(r,t);if(n!==e._ownerWritableStream)return b(Le("write to"));var o=n._state;if("errored"===o)return b(n._storedError);if(!0===pe(n)||"closed"===o)return b(new TypeError("The stream is closing or closed and cannot be written to"));if("erroring"===o)return b(n._storedError);var s=function(e){return v((function(t,n){e._writeRequests.push({_resolve:t,_reject:n})}))}(n);return function(e,t,n){var r={chunk:t};try{ee(e,r,n)}catch(o){return void Ee(e,o)}var i=e._controlledWritableStream;!1===pe(i)&&"writable"===i._state&&ye(i,Te(e)),Pe(e)}(r,t,i),s}var Se=function(){function e(){throw new TypeError("WritableStreamDefaultController cannot be constructed explicitly")}return e.prototype.error=function(e){if(0==(!!o(this)&&!!Object.prototype.hasOwnProperty.call(this,"_controlledWritableStream")))throw new TypeError("WritableStreamDefaultController.prototype.error can only be used on a WritableStreamDefaultController");"writable"===this._controlledWritableStream._state&&Re(this,e)},e.prototype[ne]=function(e){var t=this._abortAlgorithm(e);return xe(this),t},e.prototype[re]=function(){te(this)},e}();function ke(e,t,n,r,i,o,s,a){t._controlledWritableStream=e,e._writableStreamController=t,t._queue=void 0,t._queueTotalSize=void 0,te(t),t._started=!1,t._strategySizeAlgorithm=a,t._strategyHWM=s,t._writeAlgorithm=r,t._closeAlgorithm=i,t._abortAlgorithm=o;var l=Te(t);ye(e,l),A(_(n()),(function(){t._started=!0,Pe(t)}),(function(n){t._started=!0,he(e,n)}))}function xe(e){e._writeAlgorithm=void 0,e._closeAlgorithm=void 0,e._abortAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function Ce(e){return e._strategyHWM-e._queueTotalSize}function Pe(e){var t=e._controlledWritableStream;if(!1!==e._started&&void 0===t._inFlightWriteRequest)if("erroring"!==t._state){if(0!==e._queue.length){var n=e._queue.peek().value;"close"===n?function(e){var t=e._controlledWritableStream;(function(e){e._inFlightCloseRequest=e._closeRequest,e._closeRequest=void 0})(t),$(e);var n=e._closeAlgorithm();xe(e),A(n,(function(){!function(e){e._inFlightCloseRequest._resolve(void 0),e._inFlightCloseRequest=void 0,"erroring"===e._state&&(e._storedError=void 0,void 0!==e._pendingAbortRequest&&(e._pendingAbortRequest._resolve(),e._pendingAbortRequest=void 0)),e._state="closed";var t=e._writer;void 0!==t&&Fe(t)}(t)}),(function(e){!function(e,t){e._inFlightCloseRequest._reject(t),e._inFlightCloseRequest=void 0,void 0!==e._pendingAbortRequest&&(e._pendingAbortRequest._reject(t),e._pendingAbortRequest=void 0),he(e,t)}(t,e)}))}(e):function(e,t){var n=e._controlledWritableStream;(function(e){e._inFlightWriteRequest=e._writeRequests.shift()})(n),A(e._writeAlgorithm(t),(function(){!function(e){e._inFlightWriteRequest._resolve(void 0),e._inFlightWriteRequest=void 0}(n);var t=n._state;if($(e),!1===pe(n)&&"writable"===t){var r=Te(e);ye(n,r)}Pe(e)}),(function(t){"writable"===n._state&&xe(e),function(e,t){e._inFlightWriteRequest._reject(t),e._inFlightWriteRequest=void 0,he(e,t)}(n,t)}))}(e,n.chunk)}}else fe(t)}function Ee(e,t){"writable"===e._controlledWritableStream._state&&Re(e,t)}function Te(e){return Ce(e)<=0}function Re(e,t){var n=e._controlledWritableStream;xe(e),de(n,t)}function Oe(e){return new TypeError("WritableStream.prototype."+e+" can only be used on a WritableStream")}function Ie(e){return new TypeError("WritableStreamDefaultWriter.prototype."+e+" can only be used on a WritableStreamDefaultWriter")}function Le(e){return new TypeError("Cannot "+e+" a stream using a released writer")}function Me(e){e._closedPromise=v((function(t,n){e._closedPromise_resolve=t,e._closedPromise_reject=n,e._closedPromiseState="pending"}))}function Ne(e,t){Me(e),De(e,t)}function De(e,t){C(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="rejected"}function Fe(e){e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="resolved"}function je(e){e._readyPromise=v((function(t,n){e._readyPromise_resolve=t,e._readyPromise_reject=n})),e._readyPromiseState="pending"}function Be(e,t){je(e),Ve(e,t)}function qe(e){je(e),Ue(e)}function Ve(e,t){C(e._readyPromise),e._readyPromise_reject(t),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="rejected"}function Ue(e){e._readyPromise_resolve(void 0),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="fulfilled"}function He(e){if("object"!=typeof e||null===e)return!1;try{return"boolean"==typeof e.aborted}catch(W){return!1}}var We,ze="undefined"!=typeof DOMException?DOMException:void 0,Ge=function(e){if("function"!=typeof e&&"object"!=typeof e)return!1;try{return new e,!0}catch(W){return!1}}(ze)?ze:((We=function(e,t){this.message=e||"",this.name=t||"Error",Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}).prototype=Object.create(Error.prototype),Object.defineProperty(We.prototype,"constructor",{value:We,writable:!0,configurable:!0}),We);function Qe(e,t,r,i,o,s){var a=B(e),l=oe(t);e._disturbed=!0;var u=!1,c=_(void 0);return v((function(h,d){var f,p,g;if(void 0!==s){if(f=function(){var n=new Ge("Aborted","AbortError"),r=[];!1===i&&r.push((function(){return"writable"===t._state?ue(t,n):_(void 0)})),!1===o&&r.push((function(){return"readable"===e._state?jt(e,n):_(void 0)})),P((function(){return Promise.all(r.map((function(e){return e()})))}),!0,n)},!0===s.aborted)return void f();s.addEventListener("abort",f)}if(x(e,a._closedPromise,(function(e){!1===i?P((function(){return ue(t,e)}),!0,e):E(!0,e)})),x(t,l._closedPromise,(function(t){!1===o?P((function(){return jt(e,t)}),!0,t):E(!0,t)})),p=a._closedPromise,g=function(){!1===r?P((function(){return function(e){var t=e._ownerWritableStream,n=t._state;return!0===pe(t)||"closed"===n?_(void 0):"errored"===n?b(t._storedError):_e(e)}(l)})):E()},"closed"===e._state?g():S(p,g),!0===pe(t)||"closed"===t._state){var y=new TypeError("the destination writable stream closed before all data could be piped to it");!1===o?P((function(){return jt(e,y)}),!0,y):E(!0,y)}function m(){var e=c;return w(c,(function(){return e!==c?m():void 0}))}function x(e,t,n){"errored"===e._state?n(e._storedError):k(t,n)}function P(e,n,r){function i(){A(e(),(function(){return T(n,r)}),(function(e){return T(!0,e)}))}!0!==u&&(u=!0,"writable"===t._state&&!1===pe(t)?S(m(),i):i())}function E(e,n){!0!==u&&(u=!0,"writable"===t._state&&!1===pe(t)?S(m(),(function(){return T(e,n)})):T(e,n))}function T(e,t){we(l),O(a),void 0!==s&&s.removeEventListener("abort",f),e?d(t):h(void 0)}C(v((function(e,t){!function r(i){i?e():w(!0===u?_(!0):w(l._readyPromise,(function(){return w(Y(a),(function(e){return!0===e.done||(c=w(Ae(l,e.value),void 0,n),!1)}))})),r,t)}(!1)})))}))}var Ye=function(){function e(){throw new TypeError}return Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Ke(this))throw ot("desiredSize");return nt(this)},enumerable:!0,configurable:!0}),e.prototype.close=function(){if(!1===Ke(this))throw ot("close");if(!1===rt(this))throw new TypeError("The stream is not in a state that permits close");$e(this)},e.prototype.enqueue=function(e){if(!1===Ke(this))throw ot("enqueue");if(!1===rt(this))throw new TypeError("The stream is not in a state that permits enqueue");return et(this,e)},e.prototype.error=function(e){if(!1===Ke(this))throw ot("error");tt(this,e)},e.prototype[F]=function(e){te(this);var t=this._cancelAlgorithm(e);return Je(this),t},e.prototype[j]=function(){var e=this._controlledReadableStream;if(this._queue.length>0){var t=$(this);return!0===this._closeRequested&&0===this._queue.length?(Je(this),Bt(e)):Xe(this),_(E(t,!1,e._reader._forAuthorCode))}var n=q(e);return Xe(this),n},e}();function Ke(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledReadableStream")}function Xe(e){!1!==Ze(e)&&(!0!==e._pulling?(e._pulling=!0,A(e._pullAlgorithm(),(function(){e._pulling=!1,!0===e._pullAgain&&(e._pullAgain=!1,Xe(e))}),(function(t){tt(e,t)}))):e._pullAgain=!0)}function Ze(e){var t=e._controlledReadableStream;return!1!==rt(e)&&!1!==e._started&&(!0===Ft(t)&&U(t)>0||nt(e)>0)}function Je(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function $e(e){var t=e._controlledReadableStream;e._closeRequested=!0,0===e._queue.length&&(Je(e),Bt(t))}function et(e,t){var n=e._controlledReadableStream;if(!0===Ft(n)&&U(n)>0)V(n,t,!1);else{var r=void 0;try{r=e._strategySizeAlgorithm(t)}catch(i){throw tt(e,i),i}try{ee(e,t,r)}catch(o){throw tt(e,o),o}}Xe(e)}function tt(e,t){var n=e._controlledReadableStream;"readable"===n._state&&(te(e),Je(e),qt(n,t))}function nt(e){var t=e._controlledReadableStream._state;return"errored"===t?null:"closed"===t?0:e._strategyHWM-e._queueTotalSize}function rt(e){return!1===e._closeRequested&&"readable"===e._controlledReadableStream._state}function it(e,t,n,r,i,o,s){t._controlledReadableStream=e,t._queue=void 0,t._queueTotalSize=void 0,te(t),t._started=!1,t._closeRequested=!1,t._pullAgain=!1,t._pulling=!1,t._strategySizeAlgorithm=s,t._strategyHWM=o,t._pullAlgorithm=r,t._cancelAlgorithm=i,e._readableStreamController=t,A(_(n()),(function(){t._started=!0,Xe(t)}),(function(e){tt(t,e)}))}function ot(e){return new TypeError("ReadableStreamDefaultController.prototype."+e+" can only be used on a ReadableStreamDefaultController")}var st=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},at=function(){function e(){throw new TypeError("ReadableStreamBYOBRequest cannot be used directly")}return Object.defineProperty(e.prototype,"view",{get:function(){if(!1===ct(this))throw xt("view");return this._view},enumerable:!0,configurable:!0}),e.prototype.respond=function(e){if(!1===ct(this))throw xt("respond");if(void 0===this._associatedReadableByteStreamController)throw new TypeError("This BYOB request has been invalidated");!function(e,t){if(!1===a(t=Number(t)))throw new RangeError("bytesWritten must be a finite");bt(e,t)}(this._associatedReadableByteStreamController,e)},e.prototype.respondWithNewView=function(e){if(!1===ct(this))throw xt("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");!function(e,t){var n=e._pendingPullIntos.peek();if(n.byteOffset+n.bytesFilled!==t.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(n.byteLength!==t.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");n.buffer=t.buffer,bt(e,t.byteLength)}(this._associatedReadableByteStreamController,e)},e}(),lt=function(){function e(){throw new TypeError("ReadableByteStreamController constructor cannot be used directly")}return Object.defineProperty(e.prototype,"byobRequest",{get:function(){if(!1===ut(this))throw Ct("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),n=Object.create(at.prototype);(function(e,t,n){e._associatedReadableByteStreamController=t,e._view=n})(n,this,t),this._byobRequest=n}return this._byobRequest},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===ut(this))throw Ct("desiredSize");return kt(this)},enumerable:!0,configurable:!0}),e.prototype.close=function(){if(!1===ut(this))throw Ct("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");!function(e){var t=e._controlledReadableByteStream;if(e._queueTotalSize>0)e._closeRequested=!0;else{if(e._pendingPullIntos.length>0&&e._pendingPullIntos.peek().bytesFilled>0){var n=new TypeError("Insufficient bytes to fill elements in the given buffer");throw St(e,n),n}At(e),Bt(t)}}(this)},e.prototype.enqueue=function(e){if(!1===ut(this))throw Ct("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");!function(e,t){var n=e._controlledReadableByteStream,r=t.byteOffset,i=t.byteLength,o=t.buffer;!0===H(n)?0===U(n)?pt(e,o,r,i):V(n,new Uint8Array(o,r,i),!1):!0===Tt(n)?(pt(e,o,r,i),_t(e)):pt(e,o,r,i),ht(e)}(this,e)},e.prototype.error=function(e){if(!1===ut(this))throw Ct("error");St(this,e)},e.prototype[F]=function(e){this._pendingPullIntos.length>0&&(this._pendingPullIntos.peek().bytesFilled=0),te(this);var t=this._cancelAlgorithm(e);return At(this),t},e.prototype[j]=function(){var e=this._controlledReadableByteStream;if(this._queueTotalSize>0){var t=this._queue.shift();this._queueTotalSize-=t.byteLength,mt(this);var n=void 0;try{n=new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}catch(a){return b(a)}return _(E(n,!1,e._reader._forAuthorCode))}var r=this._autoAllocateChunkSize;if(void 0!==r){var i=void 0;try{i=new ArrayBuffer(r)}catch(l){return b(l)}var o={buffer:i,byteOffset:0,byteLength:r,bytesFilled:0,elementSize:1,ctor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(o)}var s=q(e);return ht(this),s},e}();function ut(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledReadableByteStream")}function ct(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_associatedReadableByteStreamController")}function ht(e){!1!==function(e){var t=e._controlledReadableByteStream;return"readable"===t._state&&!0!==e._closeRequested&&!1!==e._started&&(!0===H(t)&&U(t)>0||!0===Tt(t)&&Et(t)>0||kt(e)>0)}(e)&&(!0!==e._pulling?(e._pulling=!0,A(e._pullAlgorithm(),(function(){e._pulling=!1,!0===e._pullAgain&&(e._pullAgain=!1,ht(e))}),(function(t){St(e,t)}))):e._pullAgain=!0)}function dt(e,t){var n=!1;"closed"===e._state&&(n=!0);var r=ft(t);"default"===t.readerType?V(e,r,n):function(e,t,n){var r=e._reader;r._readIntoRequests.shift()._resolve(E(t,n,r._forAuthorCode))}(e,r,n)}function ft(e){return new e.ctor(e.buffer,e.byteOffset,e.bytesFilled/e.elementSize)}function pt(e,t,n,r){e._queue.push({buffer:t,byteOffset:n,byteLength:r}),e._queueTotalSize+=r}function gt(e,t){var n,r,i,o,s=t.elementSize,a=t.bytesFilled-t.bytesFilled%s,l=Math.min(e._queueTotalSize,t.byteLength-t.bytesFilled),u=t.bytesFilled+l,c=u-u%s,h=l,d=!1;c>a&&(h=c-t.bytesFilled,d=!0);for(var f=e._queue;h>0;){var p=f.peek(),g=Math.min(h,p.byteLength);n=t.byteOffset+t.bytesFilled,r=p.buffer,i=p.byteOffset,o=g,new Uint8Array(t.buffer).set(new Uint8Array(r,i,o),n),p.byteLength===g?f.shift():(p.byteOffset+=g,p.byteLength-=g),e._queueTotalSize-=g,yt(e,g,t),h-=g}return d}function yt(e,t,n){vt(e),n.bytesFilled+=t}function mt(e){0===e._queueTotalSize&&!0===e._closeRequested?(At(e),Bt(e._controlledReadableByteStream)):ht(e)}function vt(e){void 0!==e._byobRequest&&(e._byobRequest._associatedReadableByteStreamController=void 0,e._byobRequest._view=void 0,e._byobRequest=void 0)}function _t(e){for(;e._pendingPullIntos.length>0;){if(0===e._queueTotalSize)return;var t=e._pendingPullIntos.peek();!0===gt(e,t)&&(wt(e),dt(e._controlledReadableByteStream,t))}}function bt(e,t){var n=e._pendingPullIntos.peek();if("closed"===e._controlledReadableByteStream._state){if(0!==t)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");!function(e,t){t.buffer=t.buffer;var n=e._controlledReadableByteStream;if(!0===Tt(n))for(;Et(n)>0;)dt(n,wt(e))}(e,n)}else!function(e,t,n){if(n.bytesFilled+t>n.byteLength)throw new RangeError("bytesWritten out of range");if(yt(e,t,n),!(n.bytesFilled<n.elementSize)){wt(e);var r=n.bytesFilled%n.elementSize;if(r>0){var i=n.byteOffset+n.bytesFilled,o=n.buffer.slice(i-r,i);pt(e,o,0,o.byteLength)}n.buffer=n.buffer,n.bytesFilled-=r,dt(e._controlledReadableByteStream,n),_t(e)}}(e,t,n);ht(e)}function wt(e){var t=e._pendingPullIntos.shift();return vt(e),t}function At(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0}function St(e,t){var n=e._controlledReadableByteStream;"readable"===n._state&&(function(e){vt(e),e._pendingPullIntos=new P}(e),te(e),At(e),qt(n,t))}function kt(e){var t=e._controlledReadableByteStream._state;return"errored"===t?null:"closed"===t?0:e._strategyHWM-e._queueTotalSize}function xt(e){return new TypeError("ReadableStreamBYOBRequest.prototype."+e+" can only be used on a ReadableStreamBYOBRequest")}function Ct(e){return new TypeError("ReadableByteStreamController.prototype."+e+" can only be used on a ReadableByteStreamController")}function Pt(e){return v((function(t,n){e._reader._readIntoRequests.push({_resolve:t,_reject:n})}))}function Et(e){return e._reader._readIntoRequests.length}function Tt(e){var t=e._reader;return void 0!==t&&!!Ot(t)}var Rt=function(){function e(e){if(!Dt(e))throw new TypeError("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(!1===ut(e._readableStreamController))throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");if(Ft(e))throw new TypeError("This stream has already been locked for exclusive reading by another reader");T(this,e),this._readIntoRequests=new P}return Object.defineProperty(e.prototype,"closed",{get:function(){return Ot(this)?this._closedPromise:b(It("closed"))},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return Ot(this)?void 0===this._ownerReadableStream?b(I("cancel")):R(this,e):b(It("cancel"))},e.prototype.read=function(e){return Ot(this)?void 0===this._ownerReadableStream?b(I("read from")):ArrayBuffer.isView(e)?0===e.byteLength?b(new TypeError("view must have non-zero byteLength")):function(e,t){var n=e._ownerReadableStream;return n._disturbed=!0,"errored"===n._state?b(n._storedError):function(e,t){var n=e._controlledReadableByteStream,r=1;t.constructor!==DataView&&(r=t.constructor.BYTES_PER_ELEMENT);var i=t.constructor,o={buffer:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength,bytesFilled:0,elementSize:r,ctor:i,readerType:"byob"};if(e._pendingPullIntos.length>0)return e._pendingPullIntos.push(o),Pt(n);if("closed"===n._state)return _(E(new i(o.buffer,o.byteOffset,0),!0,n._reader._forAuthorCode));if(e._queueTotalSize>0){if(!0===gt(e,o)){var s=ft(o);return mt(e),_(E(s,!1,n._reader._forAuthorCode))}if(!0===e._closeRequested){var a=new TypeError("Insufficient bytes to fill elements in the given buffer");return St(e,a),b(a)}}e._pendingPullIntos.push(o);var l=Pt(n);return ht(e),l}(n._readableStreamController,t)}(this,e):b(new TypeError("view must be an array buffer view")):b(It("read"))},e.prototype.releaseLock=function(){if(!Ot(this))throw It("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");O(this)}},e}();function Ot(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readIntoRequests")}function It(e){return new TypeError("ReadableStreamBYOBReader.prototype."+e+" can only be used on a ReadableStreamBYOBReader")}var Lt=function(){function e(e,t){void 0===e&&(e={}),void 0===t&&(t={}),Nt(this);var n=t.size,r=t.highWaterMark,i=e.type;if("bytes"===String(i)){if(void 0!==n)throw new RangeError("The strategy for a byte stream cannot have a size function");void 0===r&&(r=0),function(e,t,n){var r=Object.create(lt.prototype),i=u(t,"pull",0,[r]),o=u(t,"cancel",1,[]),s=t.autoAllocateChunkSize;if(void 0!==s&&(s=Number(s),!1===st(s)||s<=0))throw new RangeError("autoAllocateChunkSize must be a positive integer");!function(e,t,n,r,i,o,s){t._controlledReadableByteStream=e,t._pullAgain=!1,t._pulling=!1,t._byobRequest=void 0,t._queue=t._queueTotalSize=void 0,te(t),t._closeRequested=!1,t._started=!1,t._strategyHWM=d(o),t._pullAlgorithm=r,t._cancelAlgorithm=i,t._autoAllocateChunkSize=s,t._pendingPullIntos=new P,e._readableStreamController=t,A(_(n()),(function(){t._started=!0,ht(t)}),(function(e){St(t,e)}))}(e,r,(function(){return c(t,"start",[r])}),i,o,n,s)}(this,e,r=d(r))}else{if(void 0!==i)throw new RangeError("Invalid type is specified");var o=f(n);void 0===r&&(r=1),function(e,t,n,r){var i=Object.create(Ye.prototype),o=u(t,"pull",0,[i]),s=u(t,"cancel",1,[]);it(e,i,(function(){return c(t,"start",[i])}),o,s,n,r)}(this,e,r=d(r),o)}}return Object.defineProperty(e.prototype,"locked",{get:function(){if(!1===Dt(this))throw Vt("locked");return Ft(this)},enumerable:!0,configurable:!0}),e.prototype.cancel=function(e){return!1===Dt(this)?b(Vt("cancel")):!0===Ft(this)?b(new TypeError("Cannot cancel a stream that already has a reader")):jt(this,e)},e.prototype.getReader=function(e){var t=(void 0===e?{}:e).mode;if(!1===Dt(this))throw Vt("getReader");if(void 0===t)return B(this,!0);if("byob"===(t=String(t)))return function(e,t){void 0===t&&(t=!1);var n=new Rt(e);return n._forAuthorCode=t,n}(this,!0);throw new RangeError("Invalid mode is specified")},e.prototype.pipeThrough=function(e,t){var n=e.writable,r=e.readable,i=void 0===t?{}:t,o=i.preventClose,s=i.preventAbort,a=i.preventCancel,l=i.signal;if(!1===Dt(this))throw Vt("pipeThrough");if(!1===ae(n))throw new TypeError("writable argument to pipeThrough must be a WritableStream");if(!1===Dt(r))throw new TypeError("readable argument to pipeThrough must be a ReadableStream");if(o=Boolean(o),s=Boolean(s),a=Boolean(a),void 0!==l&&!He(l))throw new TypeError("ReadableStream.prototype.pipeThrough's signal option must be an AbortSignal");if(!0===Ft(this))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(!0===le(n))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");return C(Qe(this,n,o,s,a,l)),r},e.prototype.pipeTo=function(e,t){var n=void 0===t?{}:t,r=n.preventClose,i=n.preventAbort,o=n.preventCancel,s=n.signal;return!1===Dt(this)?b(Vt("pipeTo")):!1===ae(e)?b(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream")):(r=Boolean(r),i=Boolean(i),o=Boolean(o),void 0===s||He(s)?!0===Ft(this)?b(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):!0===le(e)?b(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):Qe(this,e,r,i,o,s):b(new TypeError("ReadableStream.prototype.pipeTo's signal option must be an AbortSignal")))},e.prototype.tee=function(){if(!1===Dt(this))throw Vt("tee");return s(function(e,t){var n,r,i,o,a,l=B(e),u=!1,c=!1,h=!1,d=v((function(e){a=e}));function f(){return!0===u||(u=!0,C(x(Y(l),(function(e){if(u=!1,!0===e.done)return!1===c&&$e(i._readableStreamController),void(!1===h&&$e(o._readableStreamController));var t=e.value,n=t;!1===c&&et(i._readableStreamController,t),!1===h&&et(o._readableStreamController,n)})))),_(void 0)}function p(){}return i=Mt(p,f,(function(t){if(c=!0,n=t,!0===h){var i=s([n,r]),o=jt(e,i);a(o)}return d})),o=Mt(p,f,(function(t){if(h=!0,r=t,!0===c){var i=s([n,r]),o=jt(e,i);a(o)}return d})),k(l._closedPromise,(function(e){tt(i._readableStreamController,e),tt(o._readableStreamController,e)})),[i,o]}(this))},e.prototype.getIterator=function(e){var t=(void 0===e?{}:e).preventCancel,n=void 0!==t&&t;if(!1===Dt(this))throw Vt("getIterator");return function(e,t){void 0===t&&(t=!1);var n=B(e),r=Object.create(X);return r._asyncIteratorReader=n,r._preventCancel=Boolean(t),r}(this,n)},e}();function Mt(e,t,n,r,i){void 0===r&&(r=1),void 0===i&&(i=function(){return 1});var o=Object.create(Lt.prototype);return Nt(o),it(o,Object.create(Ye.prototype),e,t,n,r,i),o}function Nt(e){e._state="readable",e._reader=void 0,e._storedError=void 0,e._disturbed=!1}function Dt(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readableStreamController")}function Ft(e){return void 0!==e._reader}function jt(e,t){return e._disturbed=!0,"closed"===e._state?_(void 0):"errored"===e._state?b(e._storedError):(Bt(e),x(e._readableStreamController[F](t),n))}function Bt(e){e._state="closed";var t=e._reader;void 0!==t&&(Q(t)&&(t._readRequests.forEach((function(e){e._resolve(E(void 0,!0,t._forAuthorCode))})),t._readRequests=new P),D(t))}function qt(e,t){e._state="errored",e._storedError=t;var n=e._reader;void 0!==n&&(Q(n)?(n._readRequests.forEach((function(e){e._reject(t)})),n._readRequests=new P):(n._readIntoRequests.forEach((function(e){e._reject(t)})),n._readIntoRequests=new P),N(n,t))}function Vt(e){return new TypeError("ReadableStream.prototype."+e+" can only be used on a ReadableStream")}"symbol"==typeof t.asyncIterator&&Object.defineProperty(Lt.prototype,t.asyncIterator,{value:Lt.prototype.getIterator,enumerable:!1,writable:!0,configurable:!0});var Ut=function(){function e(e){this.highWaterMark=e.highWaterMark}return e.prototype.size=function(e){return e.byteLength},e}(),Ht=function(){function e(e){this.highWaterMark=e.highWaterMark}return e.prototype.size=function(){return 1},e}(),Wt=function(){function e(e,t,n){void 0===e&&(e={}),void 0===t&&(t={}),void 0===n&&(n={});var r=t.size,i=t.highWaterMark,o=n.size,s=n.highWaterMark;if(void 0!==e.writableType)throw new RangeError("Invalid writable type specified");var a=f(r);if(void 0===i&&(i=1),i=d(i),void 0!==e.readableType)throw new RangeError("Invalid readable type specified");var l,p=f(o);void 0===s&&(s=0),s=d(s),function(e,t,n,r,i,o){function s(){return t}e._writable=function(e,t,n,r,i,o){void 0===i&&(i=1),void 0===o&&(o=function(){return 1});var s=Object.create(ie.prototype);return se(s),ke(s,Object.create(Se.prototype),e,t,n,r,i,o),s}(s,(function(t){return function(e,t){var n=e._transformStreamController;return!0===e._backpressure?x(e._backpressureChangePromise,(function(){var r=e._writable;if("erroring"===r._state)throw r._storedError;return $t(n,t)})):$t(n,t)}(e,t)}),(function(){return function(e){var t=e._readable,n=e._transformStreamController,r=n._flushAlgorithm();return Zt(n),x(r,(function(){if("errored"===t._state)throw t._storedError;var e=t._readableStreamController;!0===rt(e)&&$e(e)}),(function(n){throw Gt(e,n),t._storedError}))}(e)}),(function(t){return function(e,t){return Gt(e,t),_(void 0)}(e,t)}),n,r),e._readable=Mt(s,(function(){return function(e){return Yt(e,!1),e._backpressureChangePromise}(e)}),(function(t){return Qt(e,t),_(void 0)}),i,o),e._backpressure=void 0,e._backpressureChangePromise=void 0,e._backpressureChangePromise_resolve=void 0,Yt(e,!0),e._transformStreamController=void 0}(this,v((function(e){l=e})),i,a,s,p),function(e,t){var n=Object.create(Kt.prototype),r=function(e){try{return Jt(n,e),_(void 0)}catch(t){return b(t)}},i=t.transform;if(void 0!==i){if("function"!=typeof i)throw new TypeError("transform is not a method");r=function(e){return h(i,t,[e,n])}}var o=u(t,"flush",0,[n]);!function(e,t,n,r){t._controlledTransformStream=e,e._transformStreamController=t,t._transformAlgorithm=n,t._flushAlgorithm=r}(e,n,r,o)}(this,e);var g=c(e,"start",[this._transformStreamController]);l(g)}return Object.defineProperty(e.prototype,"readable",{get:function(){if(!1===zt(this))throw tn("readable");return this._readable},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"writable",{get:function(){if(!1===zt(this))throw tn("writable");return this._writable},enumerable:!0,configurable:!0}),e}();function zt(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_transformStreamController")}function Gt(e,t){tt(e._readable._readableStreamController,t),Qt(e,t)}function Qt(e,t){Zt(e._transformStreamController),Ee(e._writable._writableStreamController,t),!0===e._backpressure&&Yt(e,!1)}function Yt(e,t){void 0!==e._backpressureChangePromise&&e._backpressureChangePromise_resolve(),e._backpressureChangePromise=v((function(t){e._backpressureChangePromise_resolve=t})),e._backpressure=t}var Kt=function(){function e(){throw new TypeError("TransformStreamDefaultController instances cannot be created directly")}return Object.defineProperty(e.prototype,"desiredSize",{get:function(){if(!1===Xt(this))throw en("desiredSize");return nt(this._controlledTransformStream._readable._readableStreamController)},enumerable:!0,configurable:!0}),e.prototype.enqueue=function(e){if(!1===Xt(this))throw en("enqueue");Jt(this,e)},e.prototype.error=function(e){if(!1===Xt(this))throw en("error");Gt(this._controlledTransformStream,e)},e.prototype.terminate=function(){if(!1===Xt(this))throw en("terminate");var e,t;!0===rt(t=(e=this._controlledTransformStream)._readable._readableStreamController)&&$e(t),Qt(e,new TypeError("TransformStream terminated"))},e}();function Xt(e){return!!o(e)&&!!Object.prototype.hasOwnProperty.call(e,"_controlledTransformStream")}function Zt(e){e._transformAlgorithm=void 0,e._flushAlgorithm=void 0}function Jt(e,t){var n=e._controlledTransformStream,r=n._readable._readableStreamController;if(!1===rt(r))throw new TypeError("Readable side is not in a state that permits enqueue");try{et(r,t)}catch(i){throw Qt(n,i),n._readable._storedError}(function(e){return!0!==Ze(e)})(r)!==n._backpressure&&Yt(n,!0)}function $t(e,t){return x(e._transformAlgorithm(t),void 0,(function(t){throw Gt(e._controlledTransformStream,t),t}))}function en(e){return new TypeError("TransformStreamDefaultController.prototype."+e+" can only be used on a TransformStreamDefaultController")}function tn(e){return new TypeError("TransformStream.prototype."+e+" can only be used on a TransformStream")}e.ByteLengthQueuingStrategy=Ut,e.CountQueuingStrategy=Ht,e.ReadableStream=Lt,e.TransformStream=Wt,e.WritableStream=ie,Object.defineProperty(e,"__esModule",{value:!0})}(t)},function(e,t,n){n(145),n(114),n(77),n(116);var r=n(43);e.exports=r.Map},function(e,t,n){"use strict";var r=n(146),i=n(150);e.exports=r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},function(e,t,n){"use strict";var r=n(10),i=n(11),o=n(52),s=n(29),a=n(147),l=n(124),u=n(123),c=n(22),h=n(14),d=n(97),f=n(85),p=n(149);e.exports=function(e,t,n){var g=-1!==e.indexOf("Map"),y=-1!==e.indexOf("Weak"),m=g?"set":"add",v=i[e],_=v&&v.prototype,b=v,w={},A=function(e){var t=_[e];s(_,e,"add"==e?function(e){return t.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return y&&!c(e)?void 0:t.call(this,0===e?0:e)}:"has"==e?function(e){return!(y&&!c(e))&&t.call(this,0===e?0:e)}:function(e,n){return t.call(this,0===e?0:e,n),this})};if(o(e,"function"!=typeof v||!(y||_.forEach&&!h((function(){(new v).entries().next()})))))b=n.getConstructor(t,e,g,m),a.REQUIRED=!0;else if(o(e,!0)){var S=new b,k=S[m](y?{}:-0,1)!=S,x=h((function(){S.has(1)})),C=d((function(e){new v(e)})),P=!y&&h((function(){for(var e=new v,t=5;t--;)e[m](t,t);return!e.has(-0)}));C||((b=t((function(t,n){u(t,b,e);var r=p(new v,t,b);return null!=n&&l(n,r[m],r,g),r}))).prototype=_,_.constructor=b),(x||P)&&(A("delete"),A("has"),g&&A("get")),(P||k)&&A(m),y&&_.clear&&delete _.clear}return w[e]=b,r({global:!0,forced:b!=v},w),f(b,e),y||n.setStrong(b,e,g),b}},function(e,t,n){var r=n(39),i=n(22),o=n(23),s=n(27).f,a=n(38),l=n(148),u=a("meta"),c=0,h=Object.isExtensible||function(){return!0},d=function(e){s(e,u,{value:{objectID:"O"+ ++c,weakData:{}}})},f=e.exports={REQUIRED:!1,fastKey:function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!o(e,u)){if(!h(e))return"F";if(!t)return"E";d(e)}return e[u].objectID},getWeakData:function(e,t){if(!o(e,u)){if(!h(e))return!0;if(!t)return!1;d(e)}return e[u].weakData},onFreeze:function(e){return l&&f.REQUIRED&&h(e)&&!o(e,u)&&d(e),e}};r[u]=!0},function(e,t,n){var r=n(14);e.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},function(e,t,n){var r=n(22),i=n(87);e.exports=function(e,t,n){var o,s;return i&&"function"==typeof(o=t.constructor)&&o!==n&&r(s=o.prototype)&&s!==n.prototype&&i(e,s),e}},function(e,t,n){"use strict";var r=n(27).f,i=n(71),o=n(121),s=n(62),a=n(123),l=n(124),u=n(79),c=n(122),h=n(13),d=n(147).fastKey,f=n(33),p=f.set,g=f.getterFor;e.exports={getConstructor:function(e,t,n,u){var c=e((function(e,r){a(e,c,t),p(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),h||(e.size=0),null!=r&&l(r,e[u],e,n)})),f=g(t),y=function(e,t,n){var r,i,o=f(e),s=m(e,t);return s?s.value=n:(o.last=s={index:i=d(t,!0),key:t,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=s),r&&(r.next=s),h?o.size++:e.size++,"F"!==i&&(o.index[i]=s)),e},m=function(e,t){var n,r=f(e),i=d(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return o(c.prototype,{clear:function(){for(var e=f(this),t=e.index,n=e.first;n;)n.removed=!0,n.previous&&(n.previous=n.previous.next=void 0),delete t[n.index],n=n.next;e.first=e.last=void 0,h?e.size=0:this.size=0},delete:function(e){var t=this,n=f(t),r=m(t,e);if(r){var i=r.next,o=r.previous;delete n.index[r.index],r.removed=!0,o&&(o.next=i),i&&(i.previous=o),n.first==r&&(n.first=i),n.last==r&&(n.last=o),h?n.size--:t.size--}return!!r},forEach:function(e){for(var t,n=f(this),r=s(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.next:n.first;)for(r(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!m(this,e)}}),o(c.prototype,n?{get:function(e){var t=m(this,e);return t&&t.value},set:function(e,t){return y(this,0===e?0:e,t)}}:{add:function(e){return y(this,e=0===e?0:e,e)}}),h&&r(c.prototype,"size",{get:function(){return f(this).size}}),c},setStrong:function(e,t,n){var r=t+" Iterator",i=g(t),o=g(r);u(e,t,(function(e,t){p(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){for(var e=o(this),t=e.kind,n=e.last;n&&n.removed;)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),c(t)}}},function(e,t,n){n(152),n(114),n(77),n(116);var r=n(43);e.exports=r.Set},function(e,t,n){"use strict";var r=n(146),i=n(150);e.exports=r("Set",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},function(e,t,n){n(114),n(154),n(116);var r=n(43);e.exports=r.WeakMap},function(e,t,n){"use strict";var r,i=n(11),o=n(121),s=n(147),a=n(146),l=n(155),u=n(22),c=n(33).enforce,h=n(34),d=!i.ActiveXObject&&"ActiveXObject"in i,f=Object.isExtensible,p=function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},g=e.exports=a("WeakMap",p,l);if(h&&d){r=l.getConstructor(p,"WeakMap",!0),s.REQUIRED=!0;var y=g.prototype,m=y.delete,v=y.has,_=y.get,b=y.set;o(y,{delete:function(e){if(u(e)&&!f(e)){var t=c(this);return t.frozen||(t.frozen=new r),m.call(this,e)||t.frozen.delete(e)}return m.call(this,e)},has:function(e){if(u(e)&&!f(e)){var t=c(this);return t.frozen||(t.frozen=new r),v.call(this,e)||t.frozen.has(e)}return v.call(this,e)},get:function(e){if(u(e)&&!f(e)){var t=c(this);return t.frozen||(t.frozen=new r),v.call(this,e)?_.call(this,e):t.frozen.get(e)}return _.call(this,e)},set:function(e,t){if(u(e)&&!f(e)){var n=c(this);n.frozen||(n.frozen=new r),v.call(this,e)?b.call(this,e,t):n.frozen.set(e,t)}else b.call(this,e,t);return this}})}},function(e,t,n){"use strict";var r=n(121),i=n(147).getWeakData,o=n(28),s=n(22),a=n(123),l=n(124),u=n(156),c=n(23),h=n(33),d=h.set,f=h.getterFor,p=u.find,g=u.findIndex,y=0,m=function(e){return e.frozen||(e.frozen=new v)},v=function(){this.entries=[]},_=function(e,t){return p(e.entries,(function(e){return e[0]===t}))};v.prototype={get:function(e){var t=_(this,e);if(t)return t[1]},has:function(e){return!!_(this,e)},set:function(e,t){var n=_(this,e);n?n[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,n,u){var h=e((function(e,r){a(e,h,t),d(e,{type:t,id:y++,frozen:void 0}),null!=r&&l(r,e[u],e,n)})),p=f(t),g=function(e,t,n){var r=p(e),s=i(o(t),!0);return!0===s?m(r).set(t,n):s[r.id]=n,e};return r(h.prototype,{delete:function(e){var t=p(this);if(!s(e))return!1;var n=i(e);return!0===n?m(t).delete(e):n&&c(n,t.id)&&delete n[t.id]},has:function(e){var t=p(this);if(!s(e))return!1;var n=i(e);return!0===n?m(t).has(e):n&&c(n,t.id)}}),r(h.prototype,n?{get:function(e){var t=p(this);if(s(e)){var n=i(e);return!0===n?m(t).get(e):n?n[t.id]:void 0}},set:function(e,t){return g(this,e,t)}}:{add:function(e){return g(this,e,!0)}}),h}}},function(e,t,n){var r=n(62),i=n(18),o=n(83),s=n(47),a=n(157),l=[].push,u=function(e){var t=1==e,n=2==e,u=3==e,c=4==e,h=6==e,d=5==e||h;return function(f,p,g,y){for(var m,v,_=o(f),b=i(_),w=r(p,g,3),A=s(b.length),S=0,k=y||a,x=t?k(f,A):n?k(f,0):void 0;A>S;S++)if((d||S in b)&&(v=w(m=b[S],S,_),e))if(t)x[S]=v;else if(v)switch(e){case 3:return!0;case 5:return m;case 6:return S;case 2:l.call(x,m)}else if(c)return!1;return h?-1:u||c?c:x}};e.exports={forEach:u(0),map:u(1),filter:u(2),some:u(3),every:u(4),find:u(5),findIndex:u(6)}},function(e,t,n){var r=n(22),i=n(158),o=n(57)("species");e.exports=function(e,t){var n;return i(e)&&("function"!=typeof(n=e.constructor)||n!==Array&&!i(n.prototype)?r(n)&&null===(n=n[o])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===t?0:t)}},function(e,t,n){var r=n(19);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){n(114),n(160),n(116);var r=n(43);e.exports=r.WeakSet},function(e,t,n){"use strict";n(146)("WeakSet",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),n(155))},function(e,t,n){n(162);var r=n(61);e.exports=r("String","codePointAt")},function(e,t,n){"use strict";var r=n(10),i=n(78).codeAt;r({target:"String",proto:!0},{codePointAt:function(e){return i(this,e)}})},function(e,t,n){n(164);var r=n(43);e.exports=r.String.fromCodePoint},function(e,t,n){var r=n(10),i=n(49),o=String.fromCharCode,s=String.fromCodePoint;r({target:"String",stat:!0,forced:!!s&&1!=s.length},{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,s=0;r>s;){if(t=+arguments[s++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?o(t):o(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){n(166),n(114),n(168),n(172),n(173),n(174),n(175),n(176),n(177),n(178),n(179),n(180),n(181),n(182),n(183),n(184),n(185),n(186),n(187);var r=n(43);e.exports=r.Symbol},function(e,t,n){"use strict";var r=n(10),i=n(14),o=n(158),s=n(22),a=n(83),l=n(47),u=n(93),c=n(157),h=n(167),d=n(57),f=n(133),p=d("isConcatSpreadable"),g=9007199254740991,y="Maximum allowed index exceeded",m=f>=51||!i((function(){var e=[];return e[p]=!1,e.concat()[0]!==e})),v=h("concat"),_=function(e){if(!s(e))return!1;var t=e[p];return void 0!==t?!!t:o(e)};r({target:"Array",proto:!0,forced:!m||!v},{concat:function(e){var t,n,r,i,o,s=a(this),h=c(s,0),d=0;for(t=-1,r=arguments.length;t<r;t++)if(_(o=-1===t?s:arguments[t])){if(d+(i=l(o.length))>g)throw TypeError(y);for(n=0;n<i;n++,d++)n in o&&u(h,d,o[n])}else{if(d>=g)throw TypeError(y);u(h,d++,o)}return h.length=d,h}})},function(e,t,n){var r=n(14),i=n(57),o=n(133),s=i("species");e.exports=function(e){return o>=51||!r((function(){var t=[];return(t.constructor={})[s]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},function(e,t,n){"use strict";var r=n(10),i=n(11),o=n(42),s=n(37),a=n(13),l=n(58),u=n(59),c=n(14),h=n(23),d=n(158),f=n(22),p=n(28),g=n(83),y=n(17),m=n(21),v=n(16),_=n(71),b=n(73),w=n(44),A=n(169),S=n(51),k=n(12),x=n(27),C=n(15),P=n(26),E=n(29),T=n(36),R=n(35),O=n(39),I=n(38),L=n(57),M=n(170),N=n(171),D=n(85),F=n(33),j=n(156).forEach,B=R("hidden"),q="Symbol",V=L("toPrimitive"),U=F.set,H=F.getterFor(q),W=Object.prototype,z=i.Symbol,G=o("JSON","stringify"),Q=k.f,Y=x.f,K=A.f,X=C.f,Z=T("symbols"),J=T("op-symbols"),$=T("string-to-symbol-registry"),ee=T("symbol-to-string-registry"),te=T("wks"),ne=i.QObject,re=!ne||!ne.prototype||!ne.prototype.findChild,ie=a&&c((function(){return 7!=_(Y({},"a",{get:function(){return Y(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=Q(W,t);r&&delete W[t],Y(e,t,n),r&&e!==W&&Y(W,t,r)}:Y,oe=function(e,t){var n=Z[e]=_(z.prototype);return U(n,{type:q,tag:e,description:t}),a||(n.description=t),n},se=u?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof z},ae=function(e,t,n){e===W&&ae(J,t,n),p(e);var r=m(t,!0);return p(n),h(Z,r)?(n.enumerable?(h(e,B)&&e[B][r]&&(e[B][r]=!1),n=_(n,{enumerable:v(0,!1)})):(h(e,B)||Y(e,B,v(1,{})),e[B][r]=!0),ie(e,r,n)):Y(e,r,n)},le=function(e,t){p(e);var n=y(t),r=b(n).concat(de(n));return j(r,(function(t){a&&!ue.call(n,t)||ae(e,t,n[t])})),e},ue=function(e){var t=m(e,!0),n=X.call(this,t);return!(this===W&&h(Z,t)&&!h(J,t))&&(!(n||!h(this,t)||!h(Z,t)||h(this,B)&&this[B][t])||n)},ce=function(e,t){var n=y(e),r=m(t,!0);if(n!==W||!h(Z,r)||h(J,r)){var i=Q(n,r);return!i||!h(Z,r)||h(n,B)&&n[B][r]||(i.enumerable=!0),i}},he=function(e){var t=K(y(e)),n=[];return j(t,(function(e){h(Z,e)||h(O,e)||n.push(e)})),n},de=function(e){var t=e===W,n=K(t?J:y(e)),r=[];return j(n,(function(e){!h(Z,e)||t&&!h(W,e)||r.push(Z[e])})),r};l||(E((z=function(){if(this instanceof z)throw TypeError("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,t=I(e),n=function(e){this===W&&n.call(J,e),h(this,B)&&h(this[B],t)&&(this[B][t]=!1),ie(this,t,v(1,e))};return a&&re&&ie(W,t,{configurable:!0,set:n}),oe(t,e)}).prototype,"toString",(function(){return H(this).tag})),E(z,"withoutSetter",(function(e){return oe(I(e),e)})),C.f=ue,x.f=ae,k.f=ce,w.f=A.f=he,S.f=de,M.f=function(e){return oe(L(e),e)},a&&(Y(z.prototype,"description",{configurable:!0,get:function(){return H(this).description}}),s||E(W,"propertyIsEnumerable",ue,{unsafe:!0}))),r({global:!0,wrap:!0,forced:!l,sham:!l},{Symbol:z}),j(b(te),(function(e){N(e)})),r({target:q,stat:!0,forced:!l},{for:function(e){var t=String(e);if(h($,t))return $[t];var n=z(t);return $[t]=n,ee[n]=t,n},keyFor:function(e){if(!se(e))throw TypeError(e+" is not a symbol");if(h(ee,e))return ee[e]},useSetter:function(){re=!0},useSimple:function(){re=!1}}),r({target:"Object",stat:!0,forced:!l,sham:!a},{create:function(e,t){return void 0===t?_(e):le(_(e),t)},defineProperty:ae,defineProperties:le,getOwnPropertyDescriptor:ce}),r({target:"Object",stat:!0,forced:!l},{getOwnPropertyNames:he,getOwnPropertySymbols:de}),r({target:"Object",stat:!0,forced:c((function(){S.f(1)}))},{getOwnPropertySymbols:function(e){return S.f(g(e))}}),G&&r({target:"JSON",stat:!0,forced:!l||c((function(){var e=z();return"[null]"!=G([e])||"{}"!=G({a:e})||"{}"!=G(Object(e))}))},{stringify:function(e,t,n){for(var r,i=[e],o=1;arguments.length>o;)i.push(arguments[o++]);if(r=t,(f(t)||void 0!==e)&&!se(e))return d(t)||(t=function(e,t){if("function"==typeof r&&(t=r.call(this,e,t)),!se(t))return t}),i[1]=t,G.apply(null,i)}}),z.prototype[V]||P(z.prototype,V,z.prototype.valueOf),D(z,q),O[B]=!0},function(e,t,n){var r=n(17),i=n(44).f,o={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return s&&"[object Window]"==o.call(e)?function(e){try{return i(e)}catch(t){return s.slice()}}(e):i(r(e))}},function(e,t,n){var r=n(57);t.f=r},function(e,t,n){var r=n(43),i=n(23),o=n(170),s=n(27).f;e.exports=function(e){var t=r.Symbol||(r.Symbol={});i(t,e)||s(t,e,{value:o.f(e)})}},function(e,t,n){n(171)("asyncIterator")},function(e,t,n){"use strict";var r=n(10),i=n(13),o=n(11),s=n(23),a=n(22),l=n(27).f,u=n(40),c=o.Symbol;if(i&&"function"==typeof c&&(!("description"in c.prototype)||void 0!==c().description)){var h={},d=function(){var e=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),t=this instanceof d?new c(e):void 0===e?c():c(e);return""===e&&(h[t]=!0),t};u(d,c);var f=d.prototype=c.prototype;f.constructor=d;var p=f.toString,g="Symbol(test)"==String(c("test")),y=/^Symbol\((.*)\)[^)]+$/;l(f,"description",{configurable:!0,get:function(){var e=a(this)?this.valueOf():this,t=p.call(e);if(s(h,e))return"";var n=g?t.slice(7,-1):t.replace(y,"$1");return""===n?void 0:n}}),r({global:!0,forced:!0},{Symbol:d})}},function(e,t,n){n(171)("hasInstance")},function(e,t,n){n(171)("isConcatSpreadable")},function(e,t,n){n(171)("iterator")},function(e,t,n){n(171)("match")},function(e,t,n){n(171)("matchAll")},function(e,t,n){n(171)("replace")},function(e,t,n){n(171)("search")},function(e,t,n){n(171)("species")},function(e,t,n){n(171)("split")},function(e,t,n){n(171)("toPrimitive")},function(e,t,n){n(171)("toStringTag")},function(e,t,n){n(171)("unscopables")},function(e,t,n){n(85)(Math,"Math",!0)},function(e,t,n){var r=n(11);n(85)(r.JSON,"JSON",!0)},function(e,t,n){n(189);var r=n(61);e.exports=r("String","padStart")},function(e,t,n){"use strict";var r=n(10),i=n(190).start;r({target:"String",proto:!0,forced:n(192)},{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(47),i=n(191),o=n(20),s=Math.ceil,a=function(e){return function(t,n,a){var l,u,c=String(o(t)),h=c.length,d=void 0===a?" ":String(a),f=r(n);return f<=h||""==d?c:((u=i.call(d,s((l=f-h)/d.length))).length>l&&(u=u.slice(0,l)),e?c+u:u+c)}};e.exports={start:a(!1),end:a(!0)}},function(e,t,n){"use strict";var r=n(48),i=n(20);e.exports="".repeat||function(e){var t=String(i(this)),n="",o=r(e);if(o<0||o==1/0)throw RangeError("Wrong number of repetitions");for(;o>0;(o>>>=1)&&(t+=t))1&o&&(n+=t);return n}},function(e,t,n){var r=n(127);e.exports=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(r)},function(e,t,n){n(194);var r=n(61);e.exports=r("String","padEnd")},function(e,t,n){"use strict";var r=n(10),i=n(190).end;r({target:"String",proto:!0,forced:n(192)},{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){n(196);var r=n(43);e.exports=r.Object.values},function(e,t,n){var r=n(10),i=n(197).values;r({target:"Object",stat:!0},{values:function(e){return i(e)}})},function(e,t,n){var r=n(13),i=n(73),o=n(17),s=n(15).f,a=function(e){return function(t){for(var n,a=o(t),l=i(a),u=l.length,c=0,h=[];u>c;)n=l[c++],r&&!s.call(a,n)||h.push(e?[n,a[n]]:a[n]);return h}};e.exports={entries:a(!0),values:a(!1)}},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__(199),_api_compatibility=__w_pdfjs_require__(200),_canvas=__w_pdfjs_require__(201),_worker_options=__w_pdfjs_require__(203),_is_node=__w_pdfjs_require__(7),_message_handler=__w_pdfjs_require__(204),_metadata=__w_pdfjs_require__(205),_transport_stream=__w_pdfjs_require__(207),_webgl=__w_pdfjs_require__(208);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function asyncGeneratorStep(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function _asyncToGenerator(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){asyncGeneratorStep(o,r,i,s,a,"next",e)}function a(e){asyncGeneratorStep(o,r,i,s,a,"throw",e)}s(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 n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=_unsupportedIterableToArray(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),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 n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function _iterableToArrayLimit(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}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,createPDFNetworkStream;function setPDFNetworkStreamFactory(e){createPDFNetworkStream=e}function getDocument(e){var t,n=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 r=Object.create(null),i=null,o=null;for(var s in t)if("url"!==s||"undefined"==typeof window)if("range"!==s)if("worker"!==s)if("data"!==s||t[s]instanceof Uint8Array)r[s]=t[s];else{var a=t[s];if("string"==typeof a)r[s]=(0,_util.stringToBytes)(a);else if("object"!==_typeof(a)||null===a||isNaN(a.length)){if(!(0,_util.isArrayBuffer)(a))throw new Error("Invalid PDF binary data: either typed array, string or array-like object is expected in the data property.");r[s]=new Uint8Array(a)}else r[s]=new Uint8Array(a)}else o=t[s];else i=t[s];else r[s]=new URL(t[s],window.location).href;if(r.rangeChunkSize=r.rangeChunkSize||DEFAULT_RANGE_CHUNK_SIZE,r.CMapReaderFactory=r.CMapReaderFactory||_display_utils.DOMCMapReaderFactory,r.ignoreErrors=!0!==r.stopAtErrors,r.fontExtraProperties=!0===r.fontExtraProperties,r.pdfBug=!0===r.pdfBug,Number.isInteger(r.maxImageSize)||(r.maxImageSize=-1),"boolean"!=typeof r.isEvalSupported&&(r.isEvalSupported=!0),"boolean"!=typeof r.disableFontFace&&(r.disableFontFace=_api_compatibility.apiCompatibilityParams.disableFontFace||!1),"boolean"!=typeof r.disableRange&&(r.disableRange=!1),"boolean"!=typeof r.disableStream&&(r.disableStream=!1),"boolean"!=typeof r.disableAutoFetch&&(r.disableAutoFetch=!1),(0,_util.setVerbosityLevel)(r.verbosity),!o){var l={verbosity:r.verbosity,port:_worker_options.GlobalWorkerOptions.workerPort};o=l.port?PDFWorker.fromPort(l):new PDFWorker(l),n._worker=o}var u=n.docId;return o.promise.then((function(){if(n.destroyed)throw new Error("Loading aborted");var e=_fetchDocument(o,r,i,u),t=new Promise((function(e){var t;i?t=new _transport_stream.PDFDataTransportStream({length:r.length,initialData:r.initialData,progressiveDone:r.progressiveDone,disableRange:r.disableRange,disableStream:r.disableStream},i):r.data||(t=createPDFNetworkStream({url:r.url,length:r.length,httpHeaders:r.httpHeaders,withCredentials:r.withCredentials,rangeChunkSize:r.rangeChunkSize,disableRange:r.disableRange,disableStream:r.disableStream})),e(t)}));return Promise.all([e,t]).then((function(e){var t=_slicedToArray(e,2),i=t[0],s=t[1];if(n.destroyed)throw new Error("Loading aborted");var a=new _message_handler.MessageHandler(u,i,o.port);a.postMessageTransfers=o.postMessageTransfers;var l=new WorkerTransport(a,n,s,r);n._transport=l,a.send("Ready",null)}))})).catch(n._capability.reject),n}function _fetchDocument(e,t,n,r){return e.destroyed?Promise.reject(new Error("Worker was destroyed")):(n&&(t.length=n.length,t.initialData=n.initialData,t.progressiveDone=n.progressiveDone),e.messageHandler.sendWithPromise("GetDocRequest",{docId:r,apiVersion:"2.5.207",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=(nextDocumentId=0,function(){function e(){_classCallCheck(this,e),this._capability=(0,_util.createPromiseCapability)(),this._transport=null,this._worker=null,this.docId="d"+nextDocumentId++,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}()),nextDocumentId,PDFDataRangeTransport=function(){function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];_classCallCheck(this,e),this.length=t,this.initialData=n,this.progressiveDone=r,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 n,r=_createForOfIteratorHelper(this._rangeListeners);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e,t)}catch(i){r.e(i)}finally{r.f()}}},{key:"onDataProgress",value:function(e,t){var n=this;this._readyCapability.promise.then((function(){var r,i=_createForOfIteratorHelper(n._progressListeners);try{for(i.s();!(r=i.n()).done;)(0,r.value)(e,t)}catch(o){i.e(o)}finally{i.f()}}))}},{key:"onDataProgressiveRead",value:function(e){var t=this;this._readyCapability.promise.then((function(){var n,r=_createForOfIteratorHelper(t._progressiveReadListeners);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(i){r.e(i)}finally{r.f()}}))}},{key:"onDataProgressiveDone",value:function(){var e=this;this._readyCapability.promise.then((function(){var t,n=_createForOfIteratorHelper(e._progressiveDoneListeners);try{for(n.s();!(t=n.n()).done;)(0,t.value)()}catch(r){n.e(r)}finally{n.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,n){_classCallCheck(this,e),this._pdfInfo=t,this._transport=n}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:"getOpenActionDestination",value:function(){return(0,_display_utils.deprecated)("getOpenActionDestination, use getOpenAction instead."),this.getOpenAction().then((function(e){return e&&e.dest?e.dest:null}))}},{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:"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:"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,n,r){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];_classCallCheck(this,e),this._pageIndex=t,this._pageInfo=n,this._transport=r,this._stats=i?new _display_utils.StatTimer:null,this._pdfBug=i,this.commonObjs=r.commonObjs,this.objs=new PDFObjects,this.cleanupAfterRender=!1,this.pendingCleanup=!1,this.intentStates=Object.create(null),this.destroyed=!1}return _createClass(e,[{key:"getViewport",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.scale,n=e.rotation,r=void 0===n?this.rotate:n,i=e.offsetX,o=void 0===i?0:i,s=e.offsetY,a=void 0===s?0:s,l=e.dontFlip,u=void 0!==l&&l;return new _display_utils.PageViewport({viewBox:this.view,scale:t,rotation:r,offsetX:o,offsetY:a,dontFlip:u})}},{key:"getAnnotations",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.intent,n=void 0===t?null:t;return this.annotationsPromise&&this.annotationsIntent===n||(this.annotationsPromise=this._transport.getAnnotations(this._pageIndex,n),this.annotationsIntent=n),this.annotationsPromise}},{key:"render",value:function(e){var t=this,n=e.canvasContext,r=e.viewport,i=e.intent,o=void 0===i?"display":i,s=e.enableWebGL,a=void 0!==s&&s,l=e.renderInteractiveForms,u=void 0!==l&&l,c=e.transform,h=void 0===c?null:c,d=e.imageLayer,f=void 0===d?null:d,p=e.canvasFactory,g=void 0===p?null:p,y=e.background,m=void 0===y?null:y;this._stats&&this._stats.time("Overall");var v="print"===o?"print":"display";this.pendingCleanup=!1,this.intentStates[v]||(this.intentStates[v]=Object.create(null));var _=this.intentStates[v];_.streamReaderCancelTimeout&&(clearTimeout(_.streamReaderCancelTimeout),_.streamReaderCancelTimeout=null);var b=g||new _display_utils.DOMCanvasFactory,w=new _webgl.WebGLContext({enable:a});_.displayReadyCapability||(_.displayReadyCapability=(0,_util.createPromiseCapability)(),_.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:v,renderInteractiveForms:!0===u}));var A=function(e){var n=_.renderTasks.indexOf(S);n>=0&&_.renderTasks.splice(n,1),(t.cleanupAfterRender||"print"===v)&&(t.pendingCleanup=!0),t._tryCleanup(),e?(S.capability.reject(e),t._abortOperatorList({intentState:_,reason:e})):S.capability.resolve(),t._stats&&(t._stats.timeEnd("Rendering"),t._stats.timeEnd("Overall"))},S=new InternalRenderTask({callback:A,params:{canvasContext:n,viewport:r,transform:h,imageLayer:f,background:m},objs:this.objs,commonObjs:this.commonObjs,operatorList:_.operatorList,pageIndex:this._pageIndex,canvasFactory:b,webGLContext:w,useRequestAnimationFrame:"print"!==v,pdfBug:this._pdfBug});_.renderTasks||(_.renderTasks=[]),_.renderTasks.push(S);var k=S.task;return _.displayReadyCapability.promise.then((function(e){t.pendingCleanup?A():(t._stats&&t._stats.time("Rendering"),S.initializeGraphics(e),S.operatorListChanged())})).catch(A),k}},{key:"getOperatorList",value:function(){this.intentStates.oplist||(this.intentStates.oplist=Object.create(null));var e,t=this.intentStates.oplist;return t.opListReadCapability||((e={}).operatorListChanged=function(){if(t.operatorList.lastChunk){t.opListReadCapability.resolve(t.operatorList);var n=t.renderTasks.indexOf(e);n>=0&&t.renderTasks.splice(n,1)}},t.opListReadCapability=(0,_util.createPromiseCapability)(),t.renderTasks=[],t.renderTasks.push(e),t.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:"oplist"})),t.opListReadCapability.promise}},{key:"streamTextContent",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.normalizeWhitespace,n=void 0!==t&&t,r=e.disableCombineTextItems,i=void 0!==r&&r,o=100;return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,normalizeWhitespace:!0===n,combineTextItems:!0!==i},{highWaterMark:o,size:function(e){return e.items.length}})}},{key:"getTextContent",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=this.streamTextContent(e);return new Promise((function(e,n){var r=t.getReader(),i={items:[],styles:Object.create(null)};!function t(){r.read().then((function(n){var r,o=n.value;n.done?e(i):(Object.assign(i.styles,o.styles),(r=i.items).push.apply(r,_toConsumableArray(o.items)),t())}),n)}()}))}},{key:"_destroy",value:function(){var e=this;this.destroyed=!0,this._transport.pageCache[this._pageIndex]=null;var t=[];return Object.keys(this.intentStates).forEach((function(n){var r=e.intentStates[n];e._abortOperatorList({intentState:r,reason:new Error("Page was destroyed."),force:!0}),"oplist"!==n&&r.renderTasks.forEach((function(e){var n=e.capability.promise.catch((function(){}));t.push(n),e.cancel()}))})),this.objs.clear(),this.annotationsPromise=null,this.pendingCleanup=!1,Promise.all(t)}},{key:"cleanup",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.pendingCleanup=!0,this._tryCleanup(e)}},{key:"_tryCleanup",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return!(!this.pendingCleanup||Object.keys(this.intentStates).some((function(t){var n=e.intentStates[t];return 0!==n.renderTasks.length||!n.operatorList.lastChunk}))||(Object.keys(this.intentStates).forEach((function(t){delete e.intentStates[t]})),this.objs.clear(),this.annotationsPromise=null,t&&this._stats&&(this._stats=new _display_utils.StatTimer),this.pendingCleanup=!1,0))}},{key:"_startRenderPage",value:function(e,t){var n=this.intentStates[t];n&&(this._stats&&this._stats.timeEnd("Page Request"),n.displayReadyCapability&&n.displayReadyCapability.resolve(e))}},{key:"_renderPageChunk",value:function(e,t){for(var n=0,r=e.length;n<r;n++)t.operatorList.fnArray.push(e.fnArray[n]),t.operatorList.argsArray.push(e.argsArray[n]);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 n=this._transport.messageHandler.sendWithStream("GetOperatorList",e).getReader(),r=this.intentStates[e.intent];r.streamReader=n,function e(){n.read().then((function(n){var i=n.value;n.done?r.streamReader=null:t._transport.destroyed||(t._renderPageChunk(i,r),e())}),(function(e){if(r.streamReader=null,!t._transport.destroyed){if(r.operatorList){r.operatorList.lastChunk=!0;for(var n=0;n<r.renderTasks.length;n++)r.renderTasks[n].operatorListChanged();t._tryCleanup()}if(r.displayReadyCapability)r.displayReadyCapability.reject(e);else{if(!r.opListReadCapability)throw e;r.opListReadCapability.reject(e)}}}))}()}},{key:"_abortOperatorList",value:function(e){var t=this,n=e.intentState,r=e.reason,i=e.force,o=void 0!==i&&i;if((0,_util.assert)(r instanceof Error||"object"===_typeof(r)&&null!==r,'PDFPageProxy._abortOperatorList: Expected "reason" argument.'),n.streamReader){if(!o){if(0!==n.renderTasks.length)return;if(r instanceof _display_utils.RenderingCancelledException)return void(n.streamReaderCancelTimeout=setTimeout((function(){t._abortOperatorList({intentState:n,reason:r,force:!0}),n.streamReaderCancelTimeout=null}),RENDERING_CANCELLED_TIMEOUT))}n.streamReader.cancel(new _util.AbortException(r&&r.message)),n.streamReader=null,this._transport.destroyed||(Object.keys(this.intentStates).some((function(e){return t.intentStates[e]===n&&(delete t.intentStates[e],!0)})),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=!(arguments.length>0&&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 n=this;if(this._defer){var r=new WeakMap,i={data:function e(n){if("object"!==_typeof(n)||null===n)return n;if(r.has(n))return r.get(n);var i,o;if((i=n.buffer)&&(0,_util.isArrayBuffer)(i))return o=t&&t.includes(i)?new n.constructor(i,n.byteOffset,n.byteLength):new n.constructor(n),r.set(n,o),o;for(var s in o=Array.isArray(n)?[]:{},r.set(n,o),n){for(var a=void 0,l=n;!(a=Object.getOwnPropertyDescriptor(l,s));)l=Object.getPrototypeOf(l);if(void 0!==a.value)if("function"!=typeof a.value)o[s]=e(a.value);else if(n.hasOwnProperty&&n.hasOwnProperty(s))throw new Error("LoopbackPort.postMessage - cannot clone: ".concat(n[s]))}return o}(e)};this._deferred.then((function(){n._listeners.forEach((function(e){e.call(n,i)}))}))}else this._listeners.forEach((function(t){t.call(n,{data:e})}))}},{key:"addEventListener",value:function(e,t){this._listeners.push(t)}},{key:"removeEventListener",value:function(e,t){var n=this._listeners.indexOf(t);this._listeners.splice(n,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;if(_is_node.isNodeJS)isWorkerDisabled=!0,fallbackWorkerSrc="./pdf.worker.js";else if("object"===("undefined"==typeof document?"undefined":_typeof(document))&&"currentScript"in document){var pdfjsFilePath=document.currentScript&&document.currentScript.src;pdfjsFilePath&&(fallbackWorkerSrc=pdfjsFilePath.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2"))}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(t){}return e||null}function setupFakeWorkerGlobal(){if(fakeWorkerCapability)return fakeWorkerCapability.promise;fakeWorkerCapability=(0,_util.createPromiseCapability)();var loader=function(){var _ref10=_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){_context.next=3;break}return _context.abrupt("return",mainWorkerMessageHandler);case 3:if(!_is_node.isNodeJS){_context.next=6;break}return worker=eval("require")(_getWorkerSrc()),_context.abrupt("return",worker.WorkerMessageHandler);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 _ref10.apply(this,arguments)}}();return loader().then(fakeWorkerCapability.resolve,fakeWorkerCapability.reject),fakeWorkerCapability.promise}function createCDNWrapper(e){return URL.createObjectURL(new Blob(["importScripts('"+e+"');"]))}var PDFWorker=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.name,r=void 0===n?null:n,i=t.port,o=void 0===i?null:i,s=t.verbosity,a=void 0===s?(0,_util.getVerbosityLevel)():s;if(_classCallCheck(this,e),o&&pdfWorkerPorts.has(o))throw new Error("Cannot use more than one PDFWorker per port");if(this.name=r,this.destroyed=!1,this.postMessageTransfers=!0,this.verbosity=a,this._readyCapability=(0,_util.createPromiseCapability)(),this._port=null,this._webWorker=null,this._messageHandler=null,o)return pdfWorkerPorts.set(o,this),void this._initializeFromPort(o);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 n=new Worker(t),r=new _message_handler.MessageHandler("main","worker",n),i=function(){n.removeEventListener("error",o),r.destroy(),n.terminate(),e.destroyed?e._readyCapability.reject(new Error("Worker was destroyed")):e._setupFakeWorker()},o=function(){e._webWorker||i()};n.addEventListener("error",o),r.on("test",(function(t){n.removeEventListener("error",o),e.destroyed?i():t?(e._messageHandler=r,e._port=n,e._webWorker=n,t.supportTransfers||(e.postMessageTransfers=!1),e._readyCapability.resolve(),r.send("configure",{verbosity:e.verbosity})):(e._setupFakeWorker(),r.destroy(),n.terminate())})),r.on("ready",(function(t){if(n.removeEventListener("error",o),e.destroyed)i();else try{s()}catch(r){e._setupFakeWorker()}}));var s=function(){var t=new Uint8Array([e.postMessageTransfers?255:0]);try{r.send("test",t,[t.buffer])}catch(n){(0,_util.warn)("Cannot use postMessage transfers."),t[0]=0,r.send("test",t)}};return void s()}catch(a){(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){if(e.destroyed)e._readyCapability.reject(new Error("Worker was destroyed"));else{var n=new LoopbackPort;e._port=n;var r="fake"+nextFakeWorkerId++,i=new _message_handler.MessageHandler(r+"_worker",r,n);t.setup(i,n);var o=new _message_handler.MessageHandler(r,r+"_worker",n);e._messageHandler=o,e._readyCapability.resolve(),o.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,n,r,i){_classCallCheck(this,e),this.messageHandler=t,this.loadingTask=n,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({docId:n.docId,onUnsupportedFeature:this._onUnsupportedFeature.bind(this)}),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=r,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 n=this.messageHandler.sendWithPromise("Terminate",null);return t.push(n),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,n=this.loadingTask;t.on("GetReader",(function(t,n){(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}},n.onPull=function(){e._fullReader.read().then((function(e){var t=e.value;e.done?n.close():((0,_util.assert)((0,_util.isArrayBuffer)(t),"GetReader - expected an ArrayBuffer."),n.enqueue(new Uint8Array(t),1,[t]))})).catch((function(e){n.error(e)}))},n.onCancel=function(t){e._fullReader.cancel(t)}})),t.on("ReaderHeadersReady",(function(t){var r=(0,_util.createPromiseCapability)(),i=e._fullReader;return i.headersReady.then((function(){i.isStreamingSupported&&i.isRangeSupported||(e._lastProgress&&n.onProgress&&n.onProgress(e._lastProgress),i.onProgress=function(e){n.onProgress&&n.onProgress({loaded:e.loaded,total:e.total})}),r.resolve({isStreamingSupported:i.isStreamingSupported,isRangeSupported:i.isRangeSupported,contentLength:i.contentLength})}),r.reject),r.promise})),t.on("GetRangeReader",(function(t,n){(0,_util.assert)(e._networkStream,"GetRangeReader - no `IPDFStream` instance available.");var r=e._networkStream.getRangeReader(t.begin,t.end);r?(n.onPull=function(){r.read().then((function(e){var t=e.value;e.done?n.close():((0,_util.assert)((0,_util.isArrayBuffer)(t),"GetRangeReader - expected an ArrayBuffer."),n.enqueue(new Uint8Array(t),1,[t]))})).catch((function(e){n.error(e)}))},n.onCancel=function(e){r.cancel(e)}):n.close()})),t.on("GetDoc",(function(t){var r=t.pdfInfo;e._numPages=r.numPages,n._capability.resolve(new PDFDocumentProxy(r,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)}n._capability.reject(t)})),t.on("PasswordRequest",(function(t){if(e._passwordCapability=(0,_util.createPromiseCapability)(),n.onPassword)try{n.onPassword((function(t){e._passwordCapability.resolve({password:t})}),t.code)}catch(r){e._passwordCapability.reject(r)}else e._passwordCapability.reject(new _util.PasswordException(t.message,t.code));return e._passwordCapability.promise})),t.on("DataLoaded",(function(t){n.onProgress&&n.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(n){if(!e.destroyed){var r=_slicedToArray(n,3),i=r[0],o=r[1],s=r[2];if(!e.commonObjs.has(i))switch(o){case"Font":var a=e._params;if("error"in s){var l=s.error;(0,_util.warn)("Error during font loading: ".concat(l)),e.commonObjs.resolve(i,l);break}var u=null;a.pdfBug&&globalThis.FontInspector&&globalThis.FontInspector.enabled&&(u={registerFont:function(e,t){globalThis.FontInspector.fontAdded(e,t)}});var c=new _font_loader.FontFaceObject(s,{isEvalSupported:a.isEvalSupported,disableFontFace:a.disableFontFace,ignoreErrors:a.ignoreErrors,onUnsupportedFeature:e._onUnsupportedFeature.bind(e),fontRegistry:u});e.fontLoader.bind(c).catch((function(e){return t.sendWithPromise("FontFallback",{id:i})})).finally((function(){!a.fontExtraProperties&&c.data&&(c.data=null),e.commonObjs.resolve(i,c)}));break;case"FontPath":case"FontType3Res":case"Image":e.commonObjs.resolve(i,s);break;default:throw new Error("Got unknown common object type ".concat(o))}}})),t.on("obj",(function(t){if(!e.destroyed){var n=_slicedToArray(t,4),r=n[0],i=n[2],o=n[3],s=e.pageCache[n[1]];if(!s.objs.has(r))switch(i){case"Image":s.objs.resolve(r,o),o&&"data"in o&&o.data.length>8e6&&(s.cleanupAfterRender=!0);break;default:throw new Error("Got unknown object type ".concat(i))}}})),t.on("DocProgress",(function(t){e.destroyed||n.onProgress&&n.onProgress({loaded:t.loaded,total:t.total})})),t.on("UnsupportedFeature",this._onUnsupportedFeature.bind(this)),t.on("FetchBuiltInCMap",(function(t,n){if(e.destroyed)n.error(new Error("Worker was destroyed"));else{var r=!1;n.onPull=function(){r?n.close():(r=!0,e.CMapReaderFactory.fetch(t).then((function(e){n.enqueue(e,1,[e.cMapData.buffer])})).catch((function(e){n.error(e)})))}}}))}},{key:"_onUnsupportedFeature",value:function(e){this.destroyed||this.loadingTask.onUnsupportedFeature&&this.loadingTask.onUnsupportedFeature(e.featureId)}},{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 n=e-1;if(n in this.pagePromises)return this.pagePromises[n];var r=this.messageHandler.sendWithPromise("GetPage",{pageIndex:n}).then((function(e){if(t.destroyed)throw new Error("Transport destroyed");var r=new PDFPageProxy(n,e,t,t._params.pdfBug);return t.pageCache[n]=r,r}));return this.pagePromises[n]=r,r}},{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:"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:"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,n=e.pageCache.length;t<n;t++){var r=e.pageCache[t];if(r&&!r.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]:this._objs[e]={capability:(0,_util.createPromiseCapability)(),data:null,resolved:!1}}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(t)return this._ensureObj(e).capability.promise.then(t),null;var n=this._objs[e];if(!n||!n.resolved)throw new Error("Requesting object that isn't resolved yet ".concat(e,"."));return n.data}},{key:"has",value:function(e){var t=this._objs[e];return!!t&&t.resolved}},{key:"resolve",value:function(e,t){var n=this._ensureObj(e);n.resolved=!0,n.data=t,n.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=(canvasInRendering=new WeakSet,function(){function e(t){var n=t.callback,r=t.params,i=t.objs,o=t.commonObjs,s=t.operatorList,a=t.pageIndex,l=t.canvasFactory,u=t.webGLContext,c=t.useRequestAnimationFrame,h=void 0!==c&&c,d=t.pdfBug,f=void 0!==d&&d;_classCallCheck(this,e),this.callback=n,this.params=r,this.objs=i,this.commonObjs=o,this.operatorListIdx=null,this.operatorList=s,this._pageIndex=a,this.canvasFactory=l,this.webGLContext=u,this._pdfBug=f,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=!0===h&&"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=r.canvasContext.canvas}var t;return _createClass(e,[{key:"initializeGraphics",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(!this.cancelled){if(this._canvas){if(canvasInRendering.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.");canvasInRendering.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 t=this.params,n=t.canvasContext,r=t.viewport,i=t.transform,o=t.imageLayer,s=t.background;this.gfx=new _canvas.CanvasGraphics(n,this.commonObjs,this.objs,this.canvasFactory,this.webGLContext,o),this.gfx.beginDrawing({transform:i,viewport:r,transparency:e,background:s}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback&&this.graphicsReadyCallback()}}},{key:"cancel",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.running=!1,this.cancelled=!0,this.gfx&&this.gfx.endDrawing(),this._canvas&&canvasInRendering.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){e.next=2;break}return e.abrupt("return");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&&canvasInRendering.delete(this._canvas),this.callback()));case 4:case"end":return e.stop()}}),e,this)}))),function(){return t.apply(this,arguments)})}]),e}()),canvasInRendering,version="2.5.207";exports.version=version;var build="0974d605";exports.build=build},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FontLoader=t.FontFaceObject=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5);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 a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t){return!t||"object"!==s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function f(e,t,n){return t&&d(e.prototype,t),n&&d(e,n),e}var p,g=function(){function e(t){var n=t.docId,r=t.onUnsupportedFeature;h(this,e),this.constructor===e&&(0,o.unreachable)("Cannot initialize BaseFontLoader."),this.docId=n,this._onUnsupportedFeature=r,this.nativeFontFaces=[],this.styleElement=null}var t,n;return f(e,[{key:"addNativeFontFace",value:function(e){this.nativeFontFaces.push(e),document.fonts.add(e)}},{key:"insertRule",value:function(e){var t=this.styleElement;t||((t=this.styleElement=document.createElement("style")).id="PDFJS_FONT_STYLE_TAG_".concat(this.docId),document.documentElement.getElementsByTagName("head")[0].appendChild(t));var n=t.sheet;n.insertRule(e,n.cssRules.length)}},{key:"clear",value:function(){this.nativeFontFaces.forEach((function(e){document.fonts.delete(e)})),this.nativeFontFaces.length=0,this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}},{key:"bind",value:(t=i.default.mark((function e(t){var n,r,s=this;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.attached&&!t.missingFile){e.next=2;break}return e.abrupt("return");case 2:if(t.attached=!0,!this.isFontLoadingAPISupported){e.next=19;break}if(!(n=t.createNativeFontFace())){e.next=18;break}return this.addNativeFontFace(n),e.prev=7,e.next=10,n.loaded;case 10:e.next=18;break;case 12:throw e.prev=12,e.t0=e.catch(7),this._onUnsupportedFeature({featureId:o.UNSUPPORTED_FEATURES.errorFontLoadNative}),(0,o.warn)("Failed to load font '".concat(n.family,"': '").concat(e.t0,"'.")),t.disableFontFace=!0,e.t0;case 18:return e.abrupt("return");case 19:if(!(r=t.createFontFaceRule())){e.next=26;break}if(this.insertRule(r),!this.isSyncFontLoadingSupported){e.next=24;break}return e.abrupt("return");case 24:return e.next=26,new Promise((function(e){var n=s._queueLoadingCallback(e);s._prepareFontLoadEvent([r],[t],n)}));case 26:case"end":return e.stop()}}),e,this,[[7,12]])})),n=function(){var e=this,n=arguments;return new Promise((function(r,i){var o=t.apply(e,n);function s(e){c(o,r,i,s,a,"next",e)}function a(e){c(o,r,i,s,a,"throw",e)}s(void 0)}))},function(e){return n.apply(this,arguments)})},{key:"_queueLoadingCallback",value:function(e){(0,o.unreachable)("Abstract method `_queueLoadingCallback`.")}},{key:"_prepareFontLoadEvent",value:function(e,t,n){(0,o.unreachable)("Abstract method `_prepareFontLoadEvent`.")}},{key:"isFontLoadingAPISupported",get:function(){var e="undefined"!=typeof document&&!!document.fonts;return(0,o.shadow)(this,"isFontLoadingAPISupported",e)}},{key:"isSyncFontLoadingSupported",get:function(){(0,o.unreachable)("Abstract method `isSyncFontLoadingSupported`.")}},{key:"_loadTestFont",get:function(){(0,o.unreachable)("Abstract method `_loadTestFont`.")}}]),e}();t.FontLoader=p,t.FontLoader=p=function(e){!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&&a(e,t)}(i,e);var t,n,r=(t=i,n=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}}(),function(){var e,r=u(t);if(n){var i=u(this).constructor;e=Reflect.construct(r,arguments,i)}else e=r.apply(this,arguments);return l(this,e)});function i(e){var t;return h(this,i),(t=r.call(this,e)).loadingContext={requests:[],nextRequestId:0},t.loadTestFontId=0,t}return f(i,[{key:"_queueLoadingCallback",value:function(e){var t=this.loadingContext,n={id:"pdfjs-font-loading-".concat(t.nextRequestId++),done:!1,complete:function(){for((0,o.assert)(!n.done,"completeRequest() cannot be called twice."),n.done=!0;t.requests.length>0&&t.requests[0].done;){var e=t.requests.shift();setTimeout(e.callback,0)}},callback:e};return t.requests.push(n),n}},{key:"_prepareFontLoadEvent",value:function(e,t,n){function r(e,t){return e.charCodeAt(t)<<24|e.charCodeAt(t+1)<<16|e.charCodeAt(t+2)<<8|255&e.charCodeAt(t+3)}function i(e,t,n,r){return e.substring(0,t)+r+e.substring(t+n)}var s,a,l=document.createElement("canvas");l.width=1,l.height=1;var u=l.getContext("2d"),c=0,h="lt".concat(Date.now()).concat(this.loadTestFontId++),d=this._loadTestFont,f=1482184792,p=r(d=i(d,976,h.length,h),16);for(s=0,a=h.length-3;s<a;s+=4)p=p-f+r(h,s)|0;s<h.length&&(p=p-f+r(h+"XXX",s)|0),d=i(d,16,4,(0,o.string32)(p));var g="url(data:font/opentype;base64,".concat(btoa(d),");"),y='@font-face {font-family:"'.concat(h,'";src:').concat(g,"}");this.insertRule(y);var m=[];for(s=0,a=t.length;s<a;s++)m.push(t[s].loadedName);m.push(h);var v=document.createElement("div");for(v.style.visibility="hidden",v.style.width=v.style.height="10px",v.style.position="absolute",v.style.top=v.style.left="0px",s=0,a=m.length;s<a;++s){var _=document.createElement("span");_.textContent="Hi",_.style.fontFamily=m[s],v.appendChild(_)}document.body.appendChild(v),function e(t,n){if(++c>30)return(0,o.warn)("Load test font never loaded."),void n();u.font="30px "+t,u.fillText(".",0,20),u.getImageData(0,0,1,1).data[3]>0?n():setTimeout(e.bind(null,t,n))}(h,(function(){document.body.removeChild(v),n.complete()}))}},{key:"isSyncFontLoadingSupported",get:function(){var e=!1;if("undefined"==typeof navigator)e=!0;else{var t=/Mozilla\/5.0.*?rv:(\d+).*? Gecko/.exec(navigator.userAgent);t&&t[1]>=14&&(e=!0)}return(0,o.shadow)(this,"isSyncFontLoadingSupported",e)}},{key:"_loadTestFont",get:function(){return(0,o.shadow)(this,"_loadTestFont",atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="))}}]),i}(g),t.FontFaceObject=function(){function e(t,n){var r=n.isEvalSupported,i=void 0===r||r,o=n.disableFontFace,s=void 0!==o&&o,a=n.ignoreErrors,l=void 0!==a&&a,u=n.onUnsupportedFeature,c=void 0===u?null:u,d=n.fontRegistry,f=void 0===d?null:d;for(var p in h(this,e),this.compiledGlyphs=Object.create(null),t)this[p]=t[p];this.isEvalSupported=!1!==i,this.disableFontFace=!0===s,this.ignoreErrors=!0===l,this._onUnsupportedFeature=c,this.fontRegistry=f}return f(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,o.bytesToString)(new Uint8Array(this.data)),t="url(data:".concat(this.mimetype,";base64,").concat(btoa(e),");"),n='@font-face {font-family:"'.concat(this.loadedName,'";src:').concat(t,"}");return this.fontRegistry&&this.fontRegistry.registerFont(this,t),n}},{key:"getPathGenerator",value:function(e,t){if(void 0!==this.compiledGlyphs[t])return this.compiledGlyphs[t];var n,r;try{n=e.get(this.loadedName+"_path_"+t)}catch(u){if(!this.ignoreErrors)throw u;return this._onUnsupportedFeature&&this._onUnsupportedFeature({featureId:o.UNSUPPORTED_FEATURES.errorFontGetPath}),(0,o.warn)('getPathGenerator - ignoring character: "'.concat(u,'".')),this.compiledGlyphs[t]=function(e,t){}}if(this.isEvalSupported&&o.IsEvalSupportedCached.value){for(var i,s="",a=0,l=n.length;a<l;a++)i=void 0!==(r=n[a]).args?r.args.join(","):"",s+="c."+r.cmd+"("+i+");\n";return this.compiledGlyphs[t]=new Function("c","size",s)}return this.compiledGlyphs[t]=function(e,t){for(var i=0,o=n.length;i<o;i++)"scale"===(r=n[i]).cmd&&(r.args=[t,-t]),e[r.cmd].apply(e,r.args)}}}]),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.apiCompatibilityParams=void 0;var r=n(7),i=Object.create(null);r.isNodeJS&&(i.disableFontFace=!0);var o=Object.freeze(i);t.apiCompatibilityParams=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CanvasGraphics=void 0;var r=n(5),i=n(202);function o(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw o}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var a=4096,l=.65,u=16;function c(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],n=e[1],r=e[2],i=e[3],o=e[4],s=e[5],a=t*i-n*r,l=n*r-t*i;return[i/a,n/l,r/l,t/a,(i*o-r*s)/l,(n*o-t*s)/a]}}),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 n=this._transformMatrix;n[4]=n[0]*e+n[2]*t+n[4],n[5]=n[1]*e+n[3]*t+n[5],this._originalTranslate(e,t)},e.scale=function(e,t){var n=this._transformMatrix;n[0]=n[0]*e,n[1]=n[1]*e,n[2]=n[2]*t,n[3]=n[3]*t,this._originalScale(e,t)},e.transform=function(t,n,r,i,o,s){var a=this._transformMatrix;this._transformMatrix=[a[0]*t+a[2]*n,a[1]*t+a[3]*n,a[0]*r+a[2]*i,a[1]*r+a[3]*i,a[0]*o+a[2]*s+a[4],a[1]*o+a[3]*s+a[5]],e._originalTransform(t,n,r,i,o,s)},e.setTransform=function(t,n,r,i,o,s){this._transformMatrix=[t,n,r,i,o,s],e._originalSetTransform(t,n,r,i,o,s)},e.rotate=function(e){var t=Math.cos(e),n=Math.sin(e),r=this._transformMatrix;this._transformMatrix=[r[0]*t+r[2]*n,r[1]*t+r[3]*n,r[0]*-n+r[2]*t,r[1]*-n+r[3]*t,r[4],r[5]],this._originalRotate(e)})}var h=function(){function e(e){this.canvasFactory=e,this.cache=Object.create(null)}return e.prototype={getCanvas:function(e,t,n,r){var i;return void 0!==this.cache[e]?(this.canvasFactory.reset(i=this.cache[e],t,n),i.context.setTransform(1,0,0,1,0,0)):(i=this.canvasFactory.create(t,n),this.cache[e]=i),r&&c(i.context),i},clear:function(){for(var e in this.cache)this.canvasFactory.destroy(this.cache[e]),delete this.cache[e]}},e}(),d=function(){function e(){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=r.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=r.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=r.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}return e.prototype={clone:function(){return Object.create(this)},setCurrentPoint:function(e,t){this.x=e,this.y=t}},e}(),f=function(){function e(e,t,n,r,i,o){this.ctx=e,this.current=new d,this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=t,this.objs=n,this.canvasFactory=r,this.webGLContext=i,this.imageLayer=o,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.cachedCanvases=new h(this.canvasFactory),e&&c(e),this._cachedGetSinglePixelWidth=null}function t(e,t){if("undefined"!=typeof ImageData&&t instanceof ImageData)e.putImageData(t,0,0);else{var n,i,o,s,a,l=t.height,c=t.width,h=l%u,d=(l-h)/u,f=0===h?d:d+1,p=e.createImageData(c,u),g=0,y=t.data,m=p.data;if(t.kind===r.ImageKind.GRAYSCALE_1BPP){var v=y.byteLength,_=new Uint32Array(m.buffer,0,m.byteLength>>2),b=_.length,w=c+7>>3,A=4294967295,S=r.IsLittleEndianCached.value?4278190080:255;for(i=0;i<f;i++){for(s=i<d?u:h,n=0,o=0;o<s;o++){for(var k=v-g,x=0,C=k>w?c:8*k-7,P=-8&C,E=0,T=0;x<P;x+=8)T=y[g++],_[n++]=128&T?A:S,_[n++]=64&T?A:S,_[n++]=32&T?A:S,_[n++]=16&T?A:S,_[n++]=8&T?A:S,_[n++]=4&T?A:S,_[n++]=2&T?A:S,_[n++]=1&T?A:S;for(;x<C;x++)0===E&&(T=y[g++],E=128),_[n++]=T&E?A:S,E>>=1}for(;n<b;)_[n++]=0;e.putImageData(p,0,i*u)}}else if(t.kind===r.ImageKind.RGBA_32BPP){for(o=0,a=c*u*4,i=0;i<d;i++)m.set(y.subarray(g,g+a)),g+=a,e.putImageData(p,0,o),o+=u;i<f&&(m.set(y.subarray(g,g+(a=c*h*4))),e.putImageData(p,0,o))}else{if(t.kind!==r.ImageKind.RGB_24BPP)throw new Error("bad image kind: ".concat(t.kind));for(a=c*(s=u),i=0;i<f;i++){for(i>=d&&(a=c*(s=h)),n=0,o=a;o--;)m[n++]=y[g++],m[n++]=y[g++],m[n++]=y[g++],m[n++]=255;e.putImageData(p,0,i*u)}}}}function n(e,t){for(var n=t.height,r=t.width,i=n%u,o=(n-i)/u,s=0===i?o:o+1,a=e.createImageData(r,u),l=0,c=t.data,h=a.data,d=0;d<s;d++){for(var f=d<o?u:i,p=3,g=0;g<f;g++)for(var y=0,m=0;m<r;m++){if(!y){var v=c[l++];y=128}h[p]=v&y?0:255,p+=4,y>>=1}e.putImageData(a,0,d*u)}}function s(e,t){for(var n=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font"],r=0,i=n.length;r<i;r++){var o=n[r];void 0!==e[o]&&(t[o]=e[o])}void 0!==e.setLineDash&&(t.setLineDash(e.getLineDash()),t.lineDashOffset=e.lineDashOffset)}function f(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 p(e,t,n,r){for(var i=e.length,o=3;o<i;o+=4){var s=e[o];if(0===s)e[o-3]=t,e[o-2]=n,e[o-1]=r;else if(s<255){var a=255-s;e[o-3]=e[o-3]*s+t*a>>8,e[o-2]=e[o-2]*s+n*a>>8,e[o-1]=e[o-1]*s+r*a>>8}}}function g(e,t,n){for(var r=e.length,i=3;i<r;i+=4)t[i]=t[i]*(n?n[e[i]]:e[i])*.00392156862745098|0}function y(e,t,n){for(var r=e.length,i=3;i<r;i+=4){var o=77*e[i-3]+152*e[i-2]+28*e[i-1];t[i]=n?t[i]*n[o>>8]>>8:t[i]*o>>16}}function m(e,t,n,r){var i=t.canvas,o=t.context;e.setTransform(t.scaleX,0,0,t.scaleY,t.offsetX,t.offsetY);var s=t.backdrop||null;if(!t.transferMap&&r.isEnabled){var a=r.composeSMask({layer:n.canvas,mask:i,properties:{subtype:t.subtype,backdrop:s}});return e.setTransform(1,0,0,1,0,0),void e.drawImage(a,t.offsetX,t.offsetY)}!function(e,t,n,r,i,o,s){var a,l=!!o,u=l?o[0]:0,c=l?o[1]:0,h=l?o[2]:0;a="Luminosity"===i?y:g;for(var d=Math.min(r,Math.ceil(1048576/n)),f=0;f<r;f+=d){var m=Math.min(d,r-f),v=e.getImageData(0,f,n,m),_=t.getImageData(0,f,n,m);l&&p(v.data,u,c,h),a(v.data,_.data,s),e.putImageData(_,0,f)}}(o,n,i.width,i.height,t.subtype,s,t.transferMap),e.drawImage(i,0,0)}var v=["butt","round","square"],_=["miter","round","bevel"],b={},w={};for(var A in e.prototype={beginDrawing:function(e){var t=e.transform,n=e.viewport,r=e.transparency,i=void 0!==r&&r,o=e.background,s=void 0===o?null:o,a=this.ctx.canvas.width,l=this.ctx.canvas.height;if(this.ctx.save(),this.ctx.fillStyle=s||"rgb(255, 255, 255)",this.ctx.fillRect(0,0,a,l),this.ctx.restore(),i){var u=this.cachedCanvases.getCanvas("transparent",a,l,!0);this.compositeCtx=this.ctx,this.transparentCanvas=u.canvas,this.ctx=u.context,this.ctx.save(),this.ctx.transform.apply(this.ctx,this.compositeCtx.mozCurrentTransform)}this.ctx.save(),f(this.ctx),t&&this.ctx.transform.apply(this.ctx,t),this.ctx.transform.apply(this.ctx,n.transform),this.baseTransform=this.ctx.mozCurrentTransform.slice(),this.imageLayer&&this.imageLayer.beginLayout()},executeOperatorList:function(e,t,n,i){var s=e.argsArray,a=e.fnArray,l=t||0,u=s.length;if(u===l)return l;for(var c,h=u-l>10&&"function"==typeof n,d=h?Date.now()+15:0,f=0,p=this.commonObjs,g=this.objs;;){if(void 0!==i&&l===i.nextBreakPoint)return i.breakIt(l,n),l;if((c=a[l])!==r.OPS.dependency)this[c].apply(this,s[l]);else{var y,m=o(s[l]);try{for(m.s();!(y=m.n()).done;){var v=y.value,_=v.startsWith("g_")?p:g;if(!_.has(v))return _.get(v,n),l}}catch(b){m.e(b)}finally{m.f()}}if(++l===u)return l;if(h&&++f>10){if(Date.now()>d)return n(),l;f=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=v[e]},setLineJoin:function(e){this.ctx.lineJoin=_[e]},setMiterLimit:function(e){this.ctx.miterLimit=e},setDash:function(e,t){var n=this.ctx;void 0!==n.setLineDash&&(n.setLineDash(e),n.lineDashOffset=t)},setRenderingIntent:function(e){},setFlatness:function(e){},setGState:function(e){for(var t=0,n=e.length;t<n;t++){var r=e[t],i=r[1];switch(r[0]){case"LW":this.setLineWidth(i);break;case"LC":this.setLineCap(i);break;case"LJ":this.setLineJoin(i);break;case"ML":this.setMiterLimit(i);break;case"D":this.setDash(i[0],i[1]);break;case"RI":this.setRenderingIntent(i);break;case"FL":this.setFlatness(i);break;case"Font":this.setFont(i[0],i[1]);break;case"CA":this.current.strokeAlpha=r[1];break;case"ca":this.current.fillAlpha=r[1],this.ctx.globalAlpha=r[1];break;case"BM":this.ctx.globalCompositeOperation=i;break;case"SMask":this.current.activeSMask&&(this.stateStack.length>0&&this.stateStack[this.stateStack.length-1].activeSMask===this.current.activeSMask?this.suspendSMaskGroup():this.endSMaskGroup()),this.current.activeSMask=i?this.tempSMask:null,this.current.activeSMask&&this.beginSMaskGroup(),this.tempSMask=null}}},beginSMaskGroup:function(){var e=this.current.activeSMask,t=this.cachedCanvases.getCanvas("smaskGroupAt"+this.groupLevel,e.canvas.width,e.canvas.height,!0),n=this.ctx,r=n.mozCurrentTransform;this.ctx.save();var i=t.context;i.scale(1/e.scaleX,1/e.scaleY),i.translate(-e.offsetX,-e.offsetY),i.transform.apply(i,r),e.startTransformInverse=i.mozCurrentTransformInverse,s(n,i),this.ctx=i,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(n),this.groupLevel++},suspendSMaskGroup:function(){var e=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),m(this.ctx,this.current.activeSMask,e,this.webGLContext),this.ctx.restore(),this.ctx.save(),s(e,this.ctx),this.current.resumeSMaskCtx=e;var t=r.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.ctx;this.ctx=this.current.resumeSMaskCtx,this.groupStack.push(e),this.groupLevel++},endSMaskGroup:function(){var e=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),m(this.ctx,this.current.activeSMask,e,this.webGLContext),this.ctx.restore(),s(e,this.ctx);var t=r.Util.transform(this.current.activeSMask.startTransformInverse,e.mozCurrentTransform);this.ctx.transform.apply(this.ctx,t)},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,n,r,i,o){this.ctx.transform(e,t,n,r,i,o),this._cachedGetSinglePixelWidth=null},constructPath:function(e,t){for(var n=this.ctx,i=this.current,o=i.x,s=i.y,a=0,l=0,u=e.length;a<u;a++)switch(0|e[a]){case r.OPS.rectangle:o=t[l++],s=t[l++];var c=t[l++],h=t[l++];0===c&&(c=this.getSinglePixelWidth()),0===h&&(h=this.getSinglePixelWidth());var d=o+c,f=s+h;this.ctx.moveTo(o,s),this.ctx.lineTo(d,s),this.ctx.lineTo(d,f),this.ctx.lineTo(o,f),this.ctx.lineTo(o,s),this.ctx.closePath();break;case r.OPS.moveTo:o=t[l++],s=t[l++],n.moveTo(o,s);break;case r.OPS.lineTo:o=t[l++],s=t[l++],n.lineTo(o,s);break;case r.OPS.curveTo:n.bezierCurveTo(t[l],t[l+1],t[l+2],t[l+3],o=t[l+4],s=t[l+5]),l+=6;break;case r.OPS.curveTo2:n.bezierCurveTo(o,s,t[l],t[l+1],t[l+2],t[l+3]),o=t[l+2],s=t[l+3],l+=4;break;case r.OPS.curveTo3:n.bezierCurveTo(t[l],t[l+1],o=t[l+2],s=t[l+3],o,s),l+=4;break;case r.OPS.closePath:n.closePath()}i.setCurrentPoint(o,s)},closePath:function(){this.ctx.closePath()},stroke:function(e){e=void 0===e||e;var t=this.ctx,n=this.current.strokeColor;if(t.globalAlpha=this.current.strokeAlpha,n&&n.hasOwnProperty("type")&&"Pattern"===n.type){t.save();var i=r.Util.singularValueDecompose2dScale(t.mozCurrentTransform)[0];t.strokeStyle=n.getPattern(t,this),t.lineWidth=Math.max(this.getSinglePixelWidth()*l,this.current.lineWidth*i),t.stroke(),t.restore()}else t.lineWidth=Math.max(this.getSinglePixelWidth()*l,this.current.lineWidth),t.stroke();e&&this.consumePath(),t.globalAlpha=this.current.fillAlpha},closeStroke:function(){this.closePath(),this.stroke()},fill:function(e){e=void 0===e||e;var t=this.ctx,n=this.current.fillColor,r=!1;this.current.patternFill&&(t.save(),this.baseTransform&&t.setTransform.apply(t,this.baseTransform),t.fillStyle=n.getPattern(t,this),r=!0),this.pendingEOFill?(t.fill("evenodd"),this.pendingEOFill=!1):t.fill(),r&&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=b},eoClip:function(){this.pendingClip=w},beginText:function(){this.current.textMatrix=r.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 n=0;n<e.length;n++){var r=e[n];t.setTransform.apply(t,r.transform),t.translate(r.x,r.y),r.addToPath(t,r.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 n=this.commonObjs.get(e),i=this.current;if(!n)throw new Error("Can't find font for ".concat(e));if(i.fontMatrix=n.fontMatrix?n.fontMatrix:r.FONT_IDENTITY_MATRIX,0!==i.fontMatrix[0]&&0!==i.fontMatrix[3]||(0,r.warn)("Invalid font matrix for font "+e),t<0?(t=-t,i.fontDirection=-1):i.fontDirection=1,this.current.font=n,this.current.fontSize=t,!n.isType3Font){var o="normal";n.black?o="900":n.bold&&(o="bold");var s=n.italic?"italic":"normal",a='"'.concat(n.loadedName||"sans-serif",'", ').concat(n.fallbackName),l=t;t<16?l=16:t>100&&(l=100),this.current.fontSizeScale=t/l,this.ctx.font="".concat(s," ").concat(o," ").concat(l,"px ").concat(a)}},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,n,r,i,o){this.current.textMatrix=[e,t,n,r,i,o],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,n,i){var o,s=this.ctx,a=this.current,l=a.font,u=a.textRenderingMode,c=a.fontSize/a.fontSizeScale,h=u&r.TextRenderingMode.FILL_STROKE_MASK,d=!!(u&r.TextRenderingMode.ADD_TO_PATH_FLAG),f=a.patternFill&&!l.missingFile;(l.disableFontFace||d||f)&&(o=l.getPathGenerator(this.commonObjs,e)),l.disableFontFace||f?(s.save(),s.translate(t,n),s.beginPath(),o(s,c),i&&s.setTransform.apply(s,i),h!==r.TextRenderingMode.FILL&&h!==r.TextRenderingMode.FILL_STROKE||s.fill(),h!==r.TextRenderingMode.STROKE&&h!==r.TextRenderingMode.FILL_STROKE||s.stroke(),s.restore()):(h!==r.TextRenderingMode.FILL&&h!==r.TextRenderingMode.FILL_STROKE||s.fillText(e,t,n),h!==r.TextRenderingMode.STROKE&&h!==r.TextRenderingMode.FILL_STROKE||s.strokeText(e,t,n)),d&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:s.mozCurrentTransform,x:t,y:n,fontSize:c,addToPath:o})},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,n=!1,i=3;i<t.length;i+=4)if(t[i]>0&&t[i]<255){n=!0;break}return(0,r.shadow)(this,"isFontSubpixelAAEnabled",n)},showText:function(e){var t=this.current,n=t.font;if(n.isType3Font)return this.showType3Text(e);var i=t.fontSize;if(0!==i){var o,s=this.ctx,a=t.fontSizeScale,u=t.charSpacing,c=t.wordSpacing,h=t.fontDirection,d=t.textHScale*h,f=e.length,p=n.vertical,g=p?1:-1,y=n.defaultVMetrics,m=i*t.fontMatrix[0],v=t.textRenderingMode===r.TextRenderingMode.FILL&&!n.disableFontFace&&!t.patternFill;if(s.save(),t.patternFill){s.save();var _=t.fillColor.getPattern(s,this);o=s.mozCurrentTransform,s.restore(),s.fillStyle=_}s.transform.apply(s,t.textMatrix),s.translate(t.x,t.y+t.textRise),s.scale(d,h>0?-1:1);var b=t.lineWidth,w=t.textMatrixScale;if(0===w||0===b){var A=t.textRenderingMode&r.TextRenderingMode.FILL_STROKE_MASK;A!==r.TextRenderingMode.STROKE&&A!==r.TextRenderingMode.FILL_STROKE||(this._cachedGetSinglePixelWidth=null,b=this.getSinglePixelWidth()*l)}else b/=w;1!==a&&(s.scale(a,a),b/=a),s.lineWidth=b;var S,k=0;for(S=0;S<f;++S){var x=e[S];if((0,r.isNum)(x))k+=g*x*i/1e3;else{var C,P,E,T,R=!1,O=(x.isSpace?c:0)+u,I=x.fontChar,L=x.accent,M=x.width;if(p?(E=x.vmetric||y,T=x.vmetric?E[1]:.5*M,M=E?-E[0]:M,C=(T=-T*m)/a,P=(k+E[2]*m)/a):(C=k/a,P=0),n.remeasure&&M>0){var N=1e3*s.measureText(I).width/i*a;if(M<N&&this.isFontSubpixelAAEnabled){var D=M/N;R=!0,s.save(),s.scale(D,1),C/=D}else M!==N&&(C+=(M-N)/2e3*i/a)}(x.isInFont||n.missingFile)&&(v&&!L?s.fillText(I,C,P):(this.paintChar(I,C,P,o),L&&this.paintChar(L.fontChar,C+L.offset.x/a,P-L.offset.y/a,o))),k+=p?M*m-O*h:M*m+O*h,R&&s.restore()}}p?t.y-=k:t.x+=k*d,s.restore()}},showType3Text:function(e){var t,n,i,o,s=this.ctx,a=this.current,l=a.font,u=a.fontSize,c=a.fontDirection,h=l.vertical?1:-1,d=a.charSpacing,f=a.wordSpacing,p=a.textHScale*c,g=a.fontMatrix||r.FONT_IDENTITY_MATRIX,y=e.length;if(a.textRenderingMode!==r.TextRenderingMode.INVISIBLE&&0!==u){for(this._cachedGetSinglePixelWidth=null,s.save(),s.transform.apply(s,a.textMatrix),s.translate(a.x,a.y),s.scale(p,c),t=0;t<y;++t)if((0,r.isNum)(n=e[t]))this.ctx.translate(o=h*n*u/1e3,0),a.x+=o*p;else{var m=(n.isSpace?f:0)+d,v=l.charProcOperatorList[n.operatorListId];if(v){this.processingType3=n,this.save(),s.scale(u,u),s.transform.apply(s,g),this.executeOperatorList(v),this.restore();var _=r.Util.applyTransform([n.width,0],g);s.translate(i=_[0]*u+m,0),a.x+=i*p}else(0,r.warn)('Type3 character "'.concat(n.operatorListId,'" is not available.'))}s.restore(),this.processingType3=null}},setCharWidth:function(e,t){},setCharWidthAndBounds:function(e,t,n,r,i,o){this.ctx.rect(n,r,i-n,o-r),this.clip(),this.endPath()},getColorN_Pattern:function(t){var n,r=this;if("TilingPattern"===t[0]){var o=t[1],s=this.baseTransform||this.ctx.mozCurrentTransform.slice();n=new i.TilingPattern(t,o,this.ctx,{createCanvasGraphics:function(t){return new e(t,r.commonObjs,r.objs,r.canvasFactory,r.webGLContext)}},s)}else n=(0,i.getShadingPatternFromIR)(t);return n},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,n){var i=r.Util.makeCssRgb(e,t,n);this.ctx.strokeStyle=i,this.current.strokeColor=i},setFillRGBColor:function(e,t,n){var i=r.Util.makeCssRgb(e,t,n);this.ctx.fillStyle=i,this.current.fillColor=i,this.current.patternFill=!1},shadingFill:function(e){var t=this.ctx;this.save();var n=(0,i.getShadingPatternFromIR)(e);t.fillStyle=n.getPattern(t,this,!0);var o=t.mozCurrentTransformInverse;if(o){var s=t.canvas,a=s.width,l=s.height,u=r.Util.applyTransform([0,0],o),c=r.Util.applyTransform([0,l],o),h=r.Util.applyTransform([a,0],o),d=r.Util.applyTransform([a,l],o),f=Math.min(u[0],c[0],h[0],d[0]),p=Math.min(u[1],c[1],h[1],d[1]),g=Math.max(u[0],c[0],h[0],d[0]),y=Math.max(u[1],c[1],h[1],d[1]);this.ctx.fillRect(f,p,g-f,y-p)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.restore()},beginInlineImage:function(){(0,r.unreachable)("Should not call beginInlineImage")},beginImageData:function(){(0,r.unreachable)("Should not call beginImageData")},paintFormXObjectBegin:function(e,t){this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(e)&&6===e.length&&this.transform.apply(this,e),this.baseTransform=this.ctx.mozCurrentTransform,t&&(this.ctx.rect(t[0],t[1],t[2]-t[0],t[3]-t[1]),this.clip(),this.endPath())},paintFormXObjectEnd:function(){this.restore(),this.baseTransform=this.baseTransformStack.pop()},beginGroup:function(e){this.save();var t=this.ctx;e.isolated||(0,r.info)("TODO: Support non-isolated groups."),e.knockout&&(0,r.warn)("Knockout groups not supported.");var n=t.mozCurrentTransform;if(e.matrix&&t.transform.apply(t,e.matrix),!e.bbox)throw new Error("Bounding box is required.");var i=r.Util.getAxialAlignedBoundingBox(e.bbox,t.mozCurrentTransform);i=r.Util.intersect(i,[0,0,t.canvas.width,t.canvas.height])||[0,0,0,0];var o=Math.floor(i[0]),l=Math.floor(i[1]),u=Math.max(Math.ceil(i[2])-o,1),c=Math.max(Math.ceil(i[3])-l,1),h=1,d=1;u>a&&(h=u/a,u=a),c>a&&(d=c/a,c=a);var f="groupAt"+this.groupLevel;e.smask&&(f+="_smask_"+this.smaskCounter++%2);var p=this.cachedCanvases.getCanvas(f,u,c,!0),g=p.context;g.scale(1/h,1/d),g.translate(-o,-l),g.transform.apply(g,n),e.smask?this.smaskStack.push({canvas:p.canvas,context:g,offsetX:o,offsetY:l,scaleX:h,scaleY:d,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(o,l),t.scale(h,d)),s(t,g),this.ctx=g,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(t),this.groupLevel++,this.current.activeSMask=null},endGroup:function(e){this.groupLevel--;var 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,n){this.save(),f(this.ctx),this.current=new d,Array.isArray(e)&&4===e.length&&(this.ctx.rect(e[0],e[1],e[2]-e[0],e[3]-e[1]),this.clip(),this.endPath()),this.transform.apply(this,t),this.transform.apply(this,n)},endAnnotation:function(){this.restore()},paintImageMaskXObject:function(e){var t=this.ctx,r=e.width,i=e.height,o=this.current.fillColor,s=this.current.patternFill,a=this.processingType3;if(a&&void 0===a.compiled&&(a.compiled=r<=1e3&&i<=1e3?function(e){var t,n,r,i,o=e.width,s=e.height,a=o+1,l=new Uint8Array(a*(s+1)),u=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),c=o+7&-8,h=e.data,d=new Uint8Array(c*s),f=0;for(t=0,i=h.length;t<i;t++)for(var p=128,g=h[t];p>0;)d[f++]=g&p?0:255,p>>=1;var y=0;for(0!==d[f=0]&&(l[0]=1,++y),n=1;n<o;n++)d[f]!==d[f+1]&&(l[n]=d[f]?2:1,++y),f++;for(0!==d[f]&&(l[n]=2,++y),t=1;t<s;t++){r=t*a,d[(f=t*c)-c]!==d[f]&&(l[r]=d[f]?1:8,++y);var m=(d[f]?4:0)+(d[f-c]?8:0);for(n=1;n<o;n++)u[m=(m>>2)+(d[f+1]?4:0)+(d[f-c+1]?8:0)]&&(l[r+n]=u[m],++y),f++;if(d[f-c]!==d[f]&&(l[r+n]=d[f]?2:4,++y),y>1e3)return null}for(r=t*a,0!==d[f=c*(s-1)]&&(l[r]=8,++y),n=1;n<o;n++)d[f]!==d[f+1]&&(l[r+n]=d[f]?4:8,++y),f++;if(0!==d[f]&&(l[r+n]=4,++y),y>1e3)return null;var v=new Int32Array([0,a,-1,0,-a,0,0,0,1]),_=[];for(t=0;y&&t<=s;t++){for(var b=t*a,w=b+o;b<w&&!l[b];)b++;if(b!==w){var A,S=[b%a,t],k=l[b],x=b;do{var C=v[k];do{b+=C}while(!l[b]);5!==(A=l[b])&&10!==A?(k=A,l[b]=0):l[b]&=(k=A&51*k>>4)>>2|k<<2,S.push(b%a),S.push(b/a|0),l[b]||--y}while(x!==b);_.push(S),--t}}return function(e){e.save(),e.scale(1/o,-1/s),e.translate(0,-s),e.beginPath();for(var t=0,n=_.length;t<n;t++){var r=_[t];e.moveTo(r[0],r[1]);for(var i=2,a=r.length;i<a;i+=2)e.lineTo(r[i],r[i+1])}e.fill(),e.beginPath(),e.restore()}}({data:e.data,width:r,height:i}):null),a&&a.compiled)a.compiled(t);else{var l=this.cachedCanvases.getCanvas("maskCanvas",r,i),u=l.context;u.save(),n(u,e),u.globalCompositeOperation="source-in",u.fillStyle=s?o.getPattern(u,this):o,u.fillRect(0,0,r,i),u.restore(),this.paintInlineImageXObject(l.canvas)}},paintImageMaskXObjectRepeat:function(e,t,r,i){var o=e.width,s=e.height,a=this.current.fillColor,l=this.current.patternFill,u=this.cachedCanvases.getCanvas("maskCanvas",o,s),c=u.context;c.save(),n(c,e),c.globalCompositeOperation="source-in",c.fillStyle=l?a.getPattern(c,this):a,c.fillRect(0,0,o,s),c.restore();for(var h=this.ctx,d=0,f=i.length;d<f;d+=2)h.save(),h.transform(t,0,0,r,i[d],i[d+1]),h.scale(1,-1),h.drawImage(u.canvas,0,0,o,s,0,-1,1,1),h.restore()},paintImageMaskXObjectGroup:function(e){for(var t=this.ctx,r=this.current.fillColor,i=this.current.patternFill,o=0,s=e.length;o<s;o++){var a=e[o],l=a.width,u=a.height,c=this.cachedCanvases.getCanvas("maskCanvas",l,u),h=c.context;h.save(),n(h,a),h.globalCompositeOperation="source-in",h.fillStyle=i?r.getPattern(h,this):r,h.fillRect(0,0,l,u),h.restore(),t.save(),t.transform.apply(t,a.transform),t.scale(1,-1),t.drawImage(c.canvas,0,0,l,u,0,-1,1,1),t.restore()}},paintImageXObject:function(e){var t=e.startsWith("g_")?this.commonObjs.get(e):this.objs.get(e);t?this.paintInlineImageXObject(t):(0,r.warn)("Dependent image isn't ready yet")},paintImageXObjectRepeat:function(e,t,n,i){var o=e.startsWith("g_")?this.commonObjs.get(e):this.objs.get(e);if(o){for(var s=o.width,a=o.height,l=[],u=0,c=i.length;u<c;u+=2)l.push({transform:[t,0,0,n,i[u],i[u+1]],x:0,y:0,w:s,h:a});this.paintInlineImageXObjectGroup(o,l)}else(0,r.warn)("Dependent image isn't ready yet")},paintInlineImageXObject:function(e){var n=e.width,r=e.height,i=this.ctx;this.save(),i.scale(1/n,-1/r);var o,s,a=i.mozCurrentTransformInverse,l=a[0],u=a[1],c=Math.max(Math.sqrt(l*l+u*u),1),h=a[2],d=a[3],f=Math.max(Math.sqrt(h*h+d*d),1);if("function"==typeof HTMLElement&&e instanceof HTMLElement||!e.data)o=e;else{var p=(s=this.cachedCanvases.getCanvas("inlineImage",n,r)).context;t(p,e),o=s.canvas}for(var g=n,y=r,m="prescale1";c>2&&g>1||f>2&&y>1;){var v=g,_=y;c>2&&g>1&&(c/=g/(v=Math.ceil(g/2))),f>2&&y>1&&(f/=y/(_=Math.ceil(y/2))),(p=(s=this.cachedCanvases.getCanvas(m,v,_)).context).clearRect(0,0,v,_),p.drawImage(o,0,0,g,y,0,0,v,_),o=s.canvas,g=v,y=_,m="prescale1"===m?"prescale2":"prescale1"}if(i.drawImage(o,0,0,g,y,0,-r,n,r),this.imageLayer){var b=this.getCanvasPosition(0,-r);this.imageLayer.appendImage({imgData:e,left:b[0],top:b[1],width:n/a[0],height:r/a[3]})}this.restore()},paintInlineImageXObjectGroup:function(e,n){var r=this.ctx,i=e.width,o=e.height,s=this.cachedCanvases.getCanvas("inlineImage",i,o);t(s.context,e);for(var a=0,l=n.length;a<l;a++){var u=n[a];if(r.save(),r.transform.apply(r,u.transform),r.scale(1,-1),r.drawImage(s.canvas,u.x,u.y,u.w,u.h,0,-1,1,1),this.imageLayer){var c=this.getCanvasPosition(u.x,u.y);this.imageLayer.appendImage({imgData:e,left:c[0],top:c[1],width:i,height:o})}r.restore()}},paintSolidColorImageMask:function(){this.ctx.fillRect(0,0,1,1)},paintXObject:function(){(0,r.warn)("Unsupported 'paintXObject' command.")},markPoint:function(e){},markPointProps:function(e,t){},beginMarkedContent:function(e){},beginMarkedContentProps:function(e,t){},endMarkedContent:function(){},beginCompat:function(){},endCompat:function(){},consumePath:function(){var e=this.ctx;this.pendingClip&&(this.pendingClip===w?e.clip("evenodd"):e.clip(),this.pendingClip=null),e.beginPath()},getSinglePixelWidth:function(e){if(null===this._cachedGetSinglePixelWidth){var 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]))}return this._cachedGetSinglePixelWidth},getCanvasPosition:function(e,t){var n=this.ctx.mozCurrentTransform;return[n[0]*e+n[2]*t+n[4],n[1]*e+n[3]*t+n[5]]}},r.OPS)e.prototype[r.OPS[A]]=e.prototype[A];return e}();t.CanvasGraphics=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getShadingPatternFromIR=function(e){var t=i[e[0]];if(!t)throw new Error("Unknown IR type: ".concat(e[0]));return t.fromIR(e)},t.TilingPattern=void 0;var r=n(5),i={};function o(e,t){if(t&&"undefined"!=typeof Path2D){var n=t[2]-t[0],r=t[3]-t[1],i=new Path2D;i.rect(t[0],t[1],n,r),e.clip(i)}}i.RadialAxial={fromIR:function(e){var t=e[1],n=e[2],r=e[3],i=e[4],s=e[5],a=e[6],l=e[7];return{type:"Pattern",getPattern:function(e){var u;o(e,n),"axial"===t?u=e.createLinearGradient(i[0],i[1],s[0],s[1]):"radial"===t&&(u=e.createRadialGradient(i[0],i[1],a,s[0],s[1],l));for(var c=0,h=r.length;c<h;++c){var d=r[c];u.addColorStop(d[0],d[1])}return u}}}};var s=function(){function e(e,t,n,r,i,o,s,a){var l,u=t.coords,c=t.colors,h=e.data,d=4*e.width;u[n+1]>u[r+1]&&(l=n,n=r,r=l,l=o,o=s,s=l),u[r+1]>u[i+1]&&(l=r,r=i,i=l,l=s,s=a,a=l),u[n+1]>u[r+1]&&(l=n,n=r,r=l,l=o,o=s,s=l);var f=(u[n]+t.offsetX)*t.scaleX,p=(u[n+1]+t.offsetY)*t.scaleY,g=(u[r]+t.offsetX)*t.scaleX,y=(u[r+1]+t.offsetY)*t.scaleY,m=(u[i]+t.offsetX)*t.scaleX,v=(u[i+1]+t.offsetY)*t.scaleY;if(!(p>=v))for(var _,b,w,A,S,k,x,C,P=c[o],E=c[o+1],T=c[o+2],R=c[s],O=c[s+1],I=c[s+2],L=c[a],M=c[a+1],N=c[a+2],D=Math.round(p),F=Math.round(v),j=D;j<=F;j++){var B,q;if(j<y)_=f-(f-g)*(B=j<p?0:p===y?1:(p-j)/(p-y)),b=P-(P-R)*B,w=E-(E-O)*B,A=T-(T-I)*B;else _=g-(g-m)*(q=j>v?1:y===v?0:(y-j)/(y-v)),b=R-(R-L)*q,w=O-(O-M)*q,A=I-(I-N)*q;var V=void 0;S=f-(f-m)*(V=j<p?0:j>v?1:(p-j)/(p-v)),k=P-(P-L)*V,x=E-(E-M)*V,C=T-(T-N)*V;for(var U=Math.round(Math.min(_,S)),H=Math.round(Math.max(_,S)),W=d*j+4*U,z=U;z<=H;z++)(V=(_-z)/(_-S))<0?V=0:V>1&&(V=1),h[W++]=b-(b-k)*V|0,h[W++]=w-(w-x)*V|0,h[W++]=A-(A-C)*V|0,h[W++]=255}}function t(t,n,r){var i,o,s=n.coords,a=n.colors;switch(n.type){case"lattice":var l=n.verticesPerRow,u=Math.floor(s.length/l)-1,c=l-1;for(i=0;i<u;i++)for(var h=i*l,d=0;d<c;d++,h++)e(t,r,s[h],s[h+1],s[h+l],a[h],a[h+1],a[h+l]),e(t,r,s[h+l+1],s[h+1],s[h+l],a[h+l+1],a[h+1],a[h+l]);break;case"triangles":for(i=0,o=s.length;i<o;i+=3)e(t,r,s[i],s[i+1],s[i+2],a[i],a[i+1],a[i+2]);break;default:throw new Error("illegal figure")}}return function(e,n,r,i,o,s,a,l){var u,c,h,d,f=Math.floor(e[0]),p=Math.floor(e[1]),g=Math.ceil(e[2])-f,y=Math.ceil(e[3])-p,m=Math.min(Math.ceil(Math.abs(g*n[0]*1.1)),3e3),v=Math.min(Math.ceil(Math.abs(y*n[1]*1.1)),3e3),_=g/m,b=y/v,w={coords:r,colors:i,offsetX:-f,offsetY:-p,scaleX:1/_,scaleY:1/b},A=m+4,S=v+4;if(l.isEnabled)u=l.drawFigures({width:m,height:v,backgroundColor:s,figures:o,context:w}),(c=a.getCanvas("mesh",A,S,!1)).context.drawImage(u,2,2),u=c.canvas;else{var k=(c=a.getCanvas("mesh",A,S,!1)).context,x=k.createImageData(m,v);if(s){var C=x.data;for(h=0,d=C.length;h<d;h+=4)C[h]=s[0],C[h+1]=s[1],C[h+2]=s[2],C[h+3]=255}for(h=0;h<o.length;h++)t(x,o[h],w);k.putImageData(x,2,2),u=c.canvas}return{canvas:u,offsetX:f-2*_,offsetY:p-2*b,scaleX:_,scaleY:b}}}();i.Mesh={fromIR:function(e){var t=e[2],n=e[3],i=e[4],a=e[5],l=e[6],u=e[7],c=e[8];return{type:"Pattern",getPattern:function(e,h,d){var f;if(o(e,u),d)f=r.Util.singularValueDecompose2dScale(e.mozCurrentTransform);else if(f=r.Util.singularValueDecompose2dScale(h.baseTransform),l){var p=r.Util.singularValueDecompose2dScale(l);f=[f[0]*p[0],f[1]*p[1]]}var g=s(a,f,t,n,i,d?null:c,h.cachedCanvases,h.webGLContext);return d||(e.setTransform.apply(e,h.baseTransform),l&&e.transform.apply(e,l)),e.translate(g.offsetX,g.offsetY),e.scale(g.scaleX,g.scaleY),e.createPattern(g.canvas,"no-repeat")}}}},i.Dummy={fromIR:function(){return{type:"Pattern",getPattern:function(){return"hotpink"}}}};var a=function(){function e(e,t,n,r,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=r,this.baseTransform=i,this.type="Pattern",this.ctx=n}return e.prototype={createPatternCanvas:function(e){var t=this.operatorList,n=this.bbox,i=this.xstep,o=this.ystep,s=this.paintType,a=this.color,l=this.canvasGraphicsFactory;(0,r.info)("TilingType: "+this.tilingType);var u=n[0],c=n[1],h=n[2],d=n[3],f=r.Util.singularValueDecompose2dScale(this.matrix),p=r.Util.singularValueDecompose2dScale(this.baseTransform),g=[f[0]*p[0],f[1]*p[1]],y=this.getSizeAndScale(i,this.ctx.canvas.width,g[0]),m=this.getSizeAndScale(o,this.ctx.canvas.height,g[1]),v=e.cachedCanvases.getCanvas("pattern",y.size,m.size,!0),_=l.createCanvasGraphics(v.context);return _.groupLevel=e.groupLevel,this.setFillAndStrokeStyleToContext(_,s,a),_.transform(y.scale,0,0,m.scale,0,0),_.transform(1,0,0,1,-u,-c),this.clipBbox(_,n,u,c,h,d),_.executeOperatorList(t),this.ctx.transform(1,0,0,1,u,c),this.ctx.scale(1/y.scale,1/m.scale),v.canvas},getSizeAndScale:function(e,t,n){e=Math.abs(e);var r=Math.max(3e3,t),i=Math.ceil(e*n);return i>=r?i=r:n=i/e,{scale:n,size:i}},clipBbox:function(e,t,n,r,i,o){Array.isArray(t)&&4===t.length&&(e.ctx.rect(n,r,i-n,o-r),e.clip(),e.endPath())},setFillAndStrokeStyleToContext:function(e,t,n){var i=e.ctx,o=e.current;switch(t){case 1:var s=this.ctx;i.fillStyle=s.fillStyle,i.strokeStyle=s.strokeStyle,o.fillColor=s.fillStyle,o.strokeColor=s.strokeStyle;break;case 2:var a=r.Util.makeCssRgb(n[0],n[1],n[2]);i.fillStyle=a,i.strokeStyle=a,o.fillColor=a,o.strokeColor=a;break;default:throw new r.FormatError("Unsupported paint type: ".concat(t))}},getPattern:function(e,t){(e=this.ctx).setTransform.apply(e,this.baseTransform),e.transform.apply(e,this.matrix);var n=this.createPatternCanvas(t);return e.createPattern(n,"repeat")}},e}();t.TilingPattern=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GlobalWorkerOptions=void 0;var r=Object.create(null);t.GlobalWorkerOptions=r,r.workerPort=void 0===r.workerPort?null:r.workerPort,r.workerSrc=void 0===r.workerSrc?"":r.workerSrc},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MessageHandler=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5);function s(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}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 l(e){if("object"!==a(e)||null===e)return e;switch(e.name){case"AbortException":return new o.AbortException(e.message);case"MissingPDFException":return new o.MissingPDFException(e.message);case"UnexpectedResponseException":return new o.UnexpectedResponseException(e.message,e.status);case"UnknownErrorException":return new o.UnknownErrorException(e.message,e.details);default:return new o.UnknownErrorException(e.message,e.toString())}}t.MessageHandler=function(){function e(t,n,r){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=n,this.comObj=r,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 n=t.callbackId,o=i.callbackCapabilities[n];if(!o)throw new Error("Cannot resolve callback ".concat(n));if(delete i.callbackCapabilities[n],1===t.callback)o.resolve(t.data);else{if(2!==t.callback)throw new Error("Unexpected callback case");o.reject(l(t.reason))}}else{var s=i.actionHandler[t.action];if(!s)throw new Error("Unknown action from worker: ".concat(t.action));if(t.callbackId){var a=i.sourceName,u=t.sourceName;new Promise((function(e){e(s(t.data))})).then((function(e){r.postMessage({sourceName:a,targetName:u,callback:1,callbackId:t.callbackId,data:e})}),(function(e){r.postMessage({sourceName:a,targetName:u,callback:2,callbackId:t.callbackId,reason:l(e)})}))}else t.streamId?i._createStreamSink(t):s(t.data)}},r.addEventListener("message",this._onComObjOnMessage)}var t,n,r,a;return t=e,(n=[{key:"on",value:function(e,t){var n=this.actionHandler;if(n[e])throw new Error('There is already an actionName called "'.concat(e,'"'));n[e]=t}},{key:"send",value:function(e,t,n){this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,data:t},n)}},{key:"sendWithPromise",value:function(e,t,n){var r=this.callbackId++,i=(0,o.createPromiseCapability)();this.callbackCapabilities[r]=i;try{this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,callbackId:r,data:t},n)}catch(s){i.reject(s)}return i.promise}},{key:"sendWithStream",value:function(e,t,n,r){var i=this,s=this.streamId++,a=this.sourceName,u=this.targetName,c=this.comObj;return new ReadableStream({start:function(n){var l=(0,o.createPromiseCapability)();return i.streamControllers[s]={controller:n,startCall:l,pullCall:null,cancelCall:null,isClosed:!1},i._postMessage({sourceName:a,targetName:u,action:e,streamId:s,data:t,desiredSize:n.desiredSize},r),l.promise},pull:function(e){var t=(0,o.createPromiseCapability)();return i.streamControllers[s].pullCall=t,c.postMessage({sourceName:a,targetName:u,stream:6,streamId:s,desiredSize:e.desiredSize}),t.promise},cancel:function(e){(0,o.assert)(e instanceof Error,"cancel must have a valid reason");var t=(0,o.createPromiseCapability)();return i.streamControllers[s].cancelCall=t,i.streamControllers[s].isClosed=!0,c.postMessage({sourceName:a,targetName:u,stream:1,streamId:s,reason:l(e)}),t.promise}},n)}},{key:"_createStreamSink",value:function(e){var t=this,n=this.actionHandler[e.action],r=e.streamId,i=this.sourceName,s=e.sourceName,a=this.comObj,u={enqueue:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,a=arguments.length>2?arguments[2]:void 0;if(!this.isCancelled){var l=this.desiredSize;this.desiredSize-=n,l>0&&this.desiredSize<=0&&(this.sinkCapability=(0,o.createPromiseCapability)(),this.ready=this.sinkCapability.promise),t._postMessage({sourceName:i,targetName:s,stream:4,streamId:r,chunk:e},a)}},close:function(){this.isCancelled||(this.isCancelled=!0,a.postMessage({sourceName:i,targetName:s,stream:3,streamId:r}),delete t.streamSinks[r])},error:function(e){(0,o.assert)(e instanceof Error,"error must have a valid reason"),this.isCancelled||(this.isCancelled=!0,a.postMessage({sourceName:i,targetName:s,stream:5,streamId:r,reason:l(e)}))},sinkCapability:(0,o.createPromiseCapability)(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:e.desiredSize,ready:null};u.sinkCapability.resolve(),u.ready=u.sinkCapability.promise,this.streamSinks[r]=u,new Promise((function(t){t(n(e.data,u))})).then((function(){a.postMessage({sourceName:i,targetName:s,stream:8,streamId:r,success:!0})}),(function(e){a.postMessage({sourceName:i,targetName:s,stream:8,streamId:r,reason:l(e)})}))}},{key:"_processStreamMessage",value:function(e){var t=e.streamId,n=this.sourceName,r=e.sourceName,i=this.comObj;switch(e.stream){case 8:e.success?this.streamControllers[t].startCall.resolve():this.streamControllers[t].startCall.reject(l(e.reason));break;case 7:e.success?this.streamControllers[t].pullCall.resolve():this.streamControllers[t].pullCall.reject(l(e.reason));break;case 6:if(!this.streamSinks[t]){i.postMessage({sourceName:n,targetName:r,stream:7,streamId:t,success:!0});break}this.streamSinks[t].desiredSize<=0&&e.desiredSize>0&&this.streamSinks[t].sinkCapability.resolve(),this.streamSinks[t].desiredSize=e.desiredSize;var s=this.streamSinks[e.streamId].onPull;new Promise((function(e){e(s&&s())})).then((function(){i.postMessage({sourceName:n,targetName:r,stream:7,streamId:t,success:!0})}),(function(e){i.postMessage({sourceName:n,targetName:r,stream:7,streamId:t,reason:l(e)})}));break;case 4:if((0,o.assert)(this.streamControllers[t],"enqueue should have stream controller"),this.streamControllers[t].isClosed)break;this.streamControllers[t].controller.enqueue(e.chunk);break;case 3:if((0,o.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 5:(0,o.assert)(this.streamControllers[t],"error should have stream controller"),this.streamControllers[t].controller.error(l(e.reason)),this._deleteStreamController(t);break;case 2:e.success?this.streamControllers[t].cancelCall.resolve():this.streamControllers[t].cancelCall.reject(l(e.reason)),this._deleteStreamController(t);break;case 1:if(!this.streamSinks[t])break;var a=this.streamSinks[e.streamId].onCancel;new Promise((function(t){t(a&&a(l(e.reason)))})).then((function(){i.postMessage({sourceName:n,targetName:r,stream:2,streamId:t,success:!0})}),(function(e){i.postMessage({sourceName:n,targetName:r,stream:2,streamId:t,reason:l(e)})})),this.streamSinks[t].sinkCapability.reject(l(e.reason)),this.streamSinks[t].isCancelled=!0,delete this.streamSinks[t];break;default:throw new Error("Unexpected stream case")}}},{key:"_deleteStreamController",value:(r=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)})),a=function(){var e=this,t=arguments;return new Promise((function(n,i){var o=r.apply(e,t);function a(e){s(o,n,i,a,l,"next",e)}function l(e){s(o,n,i,a,l,"throw",e)}a(void 0)}))},function(e){return a.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)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(t.prototype,n),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Metadata=void 0;var r=n(5),i=n(206);function o(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}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,r.assert)("string"==typeof t,"Metadata: input is not a string"),t=this._repair(t);var n=(new i.SimpleXMLParser).parseFromString(t);this._metadataMap=new Map,n&&this._parse(n)}var t;return(t=[{key:"_repair",value:function(e){return e.replace(/^[^<]+/,"").replace(/>\\376\\377([^<]+)/g,(function(e,t){for(var n=t.replace(/\\([0-3])([0-7])([0-7])/g,(function(e,t,n,r){return String.fromCharCode(64*t+8*n+1*r)})).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."))})),r="",i=0,o=n.length;i<o;i+=2){var s=256*n.charCodeAt(i)+n.charCodeAt(i+1);r+=s>=32&&s<127&&60!==s&&62!==s&&38!==s?String.fromCharCode(s):"&#x"+(65536+s).toString(16).substring(1)+";"}return">"+r}))}},{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;var n=t?t.nodeName.toLowerCase():null;if(t&&"rdf:rdf"===n&&t.hasChildNodes())for(var r=t.childNodes,i=0,o=r.length;i<o;i++){var s=r[i];if("rdf:description"===s.nodeName.toLowerCase())for(var a=0,l=s.childNodes.length;a<l;a++)if("#text"!==s.childNodes[a].nodeName.toLowerCase()){var u=s.childNodes[a],c=u.nodeName.toLowerCase();this._metadataMap.set(c,u.textContent.trim())}}}},{key:"get",value:function(e){return this._metadataMap.has(e)?this._metadataMap.get(e):null}},{key:"getAll",value:function(){var e,t,n=Object.create(null),r=function(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=o(e))){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw s}}}}(this._metadataMap);try{for(r.s();!(e=r.n()).done;){var i=(2,function(e){if(Array.isArray(e))return e}(t=e.value)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),2!==n.length);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(t)||o(t,2)||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.")}());n[i[0]]=i[1]}}catch(s){r.e(s)}finally{r.f()}return n}},{key:"has",value:function(e){return this._metadataMap.has(e)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";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)}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t,n){return(o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=l(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function a(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),e}function d(e,t){var n=e[t];return" "===n||"\n"===n||"\r"===n||"\t"===n}Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleXMLParser=void 0;var f=function(){function e(){u(this,e)}return h(e,[{key:"_resolveEntities",value:function(e){var t=this;return e.replace(/&([^;]+);/g,(function(e,n){if("#x"===n.substring(0,2))return String.fromCharCode(parseInt(n.substring(2),16));if("#"===n.substring(0,1))return String.fromCharCode(parseInt(n.substring(1),10));switch(n){case"lt":return"<";case"gt":return">";case"amp":return"&";case"quot":return'"'}return t.onResolveEntity(n)}))}},{key:"_parseContent",value:function(e,t){var n=[],r=t;function i(){for(;r<e.length&&d(e,r);)++r}for(;r<e.length&&!d(e,r)&&">"!==e[r]&&"/"!==e[r];)++r;var o=e.substring(t,r);for(i();r<e.length&&">"!==e[r]&&"/"!==e[r]&&"?"!==e[r];){i();for(var s,a="";r<e.length&&!d(e,r)&&"="!==e[r];)a+=e[r],++r;if(i(),"="!==e[r])return null;++r,i();var l=e[r];if('"'!==l&&"'"!==l)return null;var u=e.indexOf(l,++r);if(u<0)return null;s=e.substring(r,u),n.push({name:a,value:this._resolveEntities(s)}),r=u+1,i()}return{name:o,attributes:n,parsed:r-t}}},{key:"_parseProcessingInstruction",value:function(e,t){for(var n=t;n<e.length&&!d(e,n)&&">"!==e[n]&&"/"!==e[n];)++n;var r=e.substring(t,n);!function(){for(;n<e.length&&d(e,n);)++n}();for(var i=n;n<e.length&&("?"!==e[n]||">"!==e[n+1]);)++n;return{name:r,value:e.substring(i,n),parsed:n-t}}},{key:"parseXml",value:function(e){for(var t=0;t<e.length;){var n=t;if("<"===e[t]){var r=void 0;switch(e[++n]){case"/":if(++n,(r=e.indexOf(">",n))<0)return void this.onError(-9);this.onEndElement(e.substring(n,r)),n=r+1;break;case"?":++n;var i=this._parseProcessingInstruction(e,n);if("?>"!==e.substring(n+i.parsed,n+i.parsed+2))return void this.onError(-3);this.onPi(i.name,i.value),n+=i.parsed+2;break;case"!":if("--"===e.substring(n+1,n+3)){if((r=e.indexOf("--\x3e",n+3))<0)return void this.onError(-5);this.onComment(e.substring(n+3,r)),n=r+3}else if("[CDATA["===e.substring(n+1,n+8)){if((r=e.indexOf("]]>",n+8))<0)return void this.onError(-2);this.onCdata(e.substring(n+8,r)),n=r+3}else{if("DOCTYPE"!==e.substring(n+1,n+8))return void this.onError(-6);var o=e.indexOf("[",n+8),s=!1;if((r=e.indexOf(">",n+8))<0)return void this.onError(-4);if(o>0&&r>o){if((r=e.indexOf("]>",n+8))<0)return void this.onError(-4);s=!0}var a=e.substring(n+8,r+(s?1:0));this.onDoctype(a),n=r+(s?2:1)}break;default:var l=this._parseContent(e,n);if(null===l)return void this.onError(-6);var u=!1;if("/>"===e.substring(n+l.parsed,n+l.parsed+2))u=!0;else if(">"!==e.substring(n+l.parsed,n+l.parsed+1))return void this.onError(-9);this.onBeginElement(l.name,l.attributes,u),n+=l.parsed+(u?2:1)}}else{for(;n<e.length&&"<"!==e[n];)n++;var c=e.substring(t,n);this.onText(this._resolveEntities(c))}t=n}}},{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,n){}},{key:"onEndElement",value:function(e){}},{key:"onError",value:function(e){}}]),e}(),p=function(){function e(t,n){u(this,e),this.nodeName=t,this.nodeValue=n,Object.defineProperty(this,"parentNode",{value:null,writable:!0})}return h(e,[{key:"hasChildNodes",value:function(){return this.childNodes&&this.childNodes.length>0}},{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(e){!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)}(c,e);var t,n,r=(t=c,n=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}}(),function(){var e,r=l(t);if(n){var i=l(this).constructor;e=Reflect.construct(r,arguments,i)}else e=r.apply(this,arguments);return a(this,e)});function c(){var e;return u(this,c),(e=r.call(this))._currentFragment=null,e._stack=null,e._errorCode=0,e}return h(c,[{key:"parseFromString",value:function(e){if(this._currentFragment=[],this._stack=[],this._errorCode=0,this.parseXml(e),0===this._errorCode){var t=(n=this._currentFragment,1,function(e){if(Array.isArray(e))return e}(n)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),1!==n.length);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(n)||function(e,t){if(e){if("string"==typeof e)return i(e,1);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,1):void 0}}(n)||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.")}())[0];if(t)return{documentElement:t}}var n}},{key:"onResolveEntity",value:function(e){switch(e){case"apos":return"'"}return o(l(c.prototype),"onResolveEntity",this).call(this,e)}},{key:"onText",value:function(e){if(!function(e){for(var t=0,n=e.length;t<n;t++)if(!d(e,t))return!1;return!0}(e)){var t=new p("#text",e);this._currentFragment.push(t)}}},{key:"onCdata",value:function(e){var t=new p("#text",e);this._currentFragment.push(t)}},{key:"onBeginElement",value:function(e,t,n){var r=new p(e);r.childNodes=[],this._currentFragment.push(r),n||(this._stack.push(this._currentFragment),this._currentFragment=r.childNodes)}},{key:"onEndElement",value:function(e){this._currentFragment=this._stack.pop()||[];var t=this._currentFragment[this._currentFragment.length-1];if(t)for(var n=0,r=t.childNodes.length;n<r;n++)t.childNodes[n].parentNode=t}},{key:"onError",value:function(e){this._errorCode=e}}]),c}(f)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFDataTransportStream=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5);function s(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function a(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){s(o,r,i,a,l,"next",e)}function l(e){s(o,r,i,a,l,"throw",e)}a(void 0)}))}}function l(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t,n){return t&&h(e.prototype,t),n&&h(e,n),e}t.PDFDataTransportStream=function(){function e(t,n){var r=this;c(this,e),(0,o.assert)(n,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=t.progressiveDone||!1;var i=t.initialData;if(i&&i.length>0){var s=new Uint8Array(i).buffer;this._queuedChunks.push(s)}this._pdfDataRangeTransport=n,this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._contentLength=t.length,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((function(e,t){r._onReceiveData({begin:e,chunk:t})})),this._pdfDataRangeTransport.addProgressListener((function(e,t){r._onProgress({loaded:e,total:t})})),this._pdfDataRangeTransport.addProgressiveReadListener((function(e){r._onReceiveData({chunk:e})})),this._pdfDataRangeTransport.addProgressiveDoneListener((function(){r._onProgressiveDone()})),this._pdfDataRangeTransport.transportReady()}return d(e,[{key:"_onReceiveData",value:function(e){var t=new Uint8Array(e.chunk).buffer;if(void 0===e.begin)this._fullRequestReader?this._fullRequestReader._enqueue(t):this._queuedChunks.push(t);else{var n=this._rangeReaders.some((function(n){return n._begin===e.begin&&(n._enqueue(t),!0)}));(0,o.assert)(n,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}},{key:"_onProgress",value:function(e){if(void 0===e.total){var t=this._rangeReaders[0];t&&t.onProgress&&t.onProgress({loaded:e.loaded})}else{var n=this._fullRequestReader;n&&n.onProgress&&n.onProgress({loaded:e.loaded,total:e.total})}}},{key:"_onProgressiveDone",value:function(){this._fullRequestReader&&this._fullRequestReader.progressiveDone(),this._progressiveDone=!0}},{key:"_removeRangeReader",value:function(e){var t=this._rangeReaders.indexOf(e);t>=0&&this._rangeReaders.splice(t,1)}},{key:"getFullReader",value:function(){(0,o.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");var e=this._queuedChunks;return this._queuedChunks=null,new f(this,e,this._progressiveDone)}},{key:"getRangeReader",value:function(e,t){if(t<=this._progressiveDataLength)return null;var n=new p(this,e,t);return this._pdfDataRangeTransport.requestDataRange(e,t),this._rangeReaders.push(n),n}},{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 f=function(){function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];c(this,e),this._stream=t,this._done=r||!1,this._filename=null,this._queuedChunks=n||[],this._loaded=0;var i,o=l(this._queuedChunks);try{for(o.s();!(i=o.n()).done;){var s=i.value;this._loaded+=s.byteLength}}catch(a){o.e(a)}finally{o.f()}this._requests=[],this._headersReady=Promise.resolve(),t._fullRequestReader=this,this.onProgress=null}var t;return d(e,[{key:"_enqueue",value:function(e){this._done||(this._requests.length>0?this._requests.shift().resolve({value:e,done:!1}):this._queuedChunks.push(e),this._loaded+=e.byteLength)}},{key:"read",value:(t=a(i.default.mark((function e(){var t,n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(this._queuedChunks.length>0)){e.next=3;break}return t=this._queuedChunks.shift(),e.abrupt("return",{value:t,done:!1});case 3:if(!this._done){e.next=5;break}return e.abrupt("return",{value:void 0,done:!0});case 5:return n=(0,o.createPromiseCapability)(),this._requests.push(n),e.abrupt("return",n.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,n,r){c(this,e),this._stream=t,this._begin=n,this._end=r,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}var t;return d(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=a(i.default.mark((function e(){var t,n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._queuedChunk){e.next=4;break}return t=this._queuedChunk,this._queuedChunk=null,e.abrupt("return",{value:t,done:!1});case 4:if(!this._done){e.next=6;break}return e.abrupt("return",{value:void 0,done:!0});case 6:return n=(0,o.createPromiseCapability)(),this._requests.push(n),e.abrupt("return",n.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,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebGLContext=void 0;var r=n(5);t.WebGLContext=function(){function e(t){var n=t.enable,r=void 0!==n&&n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._enabled=!0===r}var t;return(t=[{key:"composeSMask",value:function(e){return i.composeSMask(e.layer,e.mask,e.properties)}},{key:"drawFigures",value:function(e){return i.drawFigures(e.width,e.height,e.backgroundColor,e.figures,e.context)}},{key:"clear",value:function(){i.cleanup()}},{key:"isEnabled",get:function(){var e=this._enabled;return e&&(e=i.tryInitGL()),(0,r.shadow)(this,"isEnabled",e)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}();var i=function(){function e(e,t,n){var r=e.createShader(n);if(e.shaderSource(r,t),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS)){var i=e.getShaderInfoLog(r);throw new Error("Error during shader compilation: "+i)}return r}function t(t,n){return e(t,n,t.VERTEX_SHADER)}function n(t,n){return e(t,n,t.FRAGMENT_SHADER)}function r(e,t){for(var n=e.createProgram(),r=0,i=t.length;r<i;++r)e.attachShader(n,t[r]);if(e.linkProgram(n),!e.getProgramParameter(n,e.LINK_STATUS)){var o=e.getProgramInfoLog(n);throw new Error("Error during program linking: "+o)}return n}function i(e,t,n){e.activeTexture(n);var r=e.createTexture();return 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}var o,s;function a(){o||(s=document.createElement("canvas"),o=s.getContext("webgl",{premultipliedalpha:!1}))}var l=null,u=null;return{tryInitGL:function(){try{return a(),!!o}catch(e){}return!1},composeSMask:function(e,u,c){var h=e.width,d=e.height;l||function(){var e,i;a(),e=s,s=null,i=o,o=null;var u=r(i,[t(i," 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; } "),n(i," 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; } ")]);i.useProgram(u);var c={};c.gl=i,c.canvas=e,c.resolutionLocation=i.getUniformLocation(u,"u_resolution"),c.positionLocation=i.getAttribLocation(u,"a_position"),c.backdropLocation=i.getUniformLocation(u,"u_backdrop"),c.subtypeLocation=i.getUniformLocation(u,"u_subtype");var h=i.getAttribLocation(u,"a_texCoord"),d=i.getUniformLocation(u,"u_image"),f=i.getUniformLocation(u,"u_mask"),p=i.createBuffer();i.bindBuffer(i.ARRAY_BUFFER,p),i.bufferData(i.ARRAY_BUFFER,new Float32Array([0,0,1,0,0,1,0,1,1,0,1,1]),i.STATIC_DRAW),i.enableVertexAttribArray(h),i.vertexAttribPointer(h,2,i.FLOAT,!1,0,0),i.uniform1i(d,0),i.uniform1i(f,1),l=c}();var f=l,p=f.canvas,g=f.gl;p.width=h,p.height=d,g.viewport(0,0,g.drawingBufferWidth,g.drawingBufferHeight),g.uniform2f(f.resolutionLocation,h,d),c.backdrop?g.uniform4f(f.resolutionLocation,c.backdrop[0],c.backdrop[1],c.backdrop[2],1):g.uniform4f(f.resolutionLocation,0,0,0,0),g.uniform1i(f.subtypeLocation,"Luminosity"===c.subtype?1:0);var y=i(g,e,g.TEXTURE0),m=i(g,u,g.TEXTURE1),v=g.createBuffer();return g.bindBuffer(g.ARRAY_BUFFER,v),g.bufferData(g.ARRAY_BUFFER,new Float32Array([0,0,h,0,0,d,0,d,h,0,h,d]),g.STATIC_DRAW),g.enableVertexAttribArray(f.positionLocation),g.vertexAttribPointer(f.positionLocation,2,g.FLOAT,!1,0,0),g.clearColor(0,0,0,0),g.enable(g.BLEND),g.blendFunc(g.ONE,g.ONE_MINUS_SRC_ALPHA),g.clear(g.COLOR_BUFFER_BIT),g.drawArrays(g.TRIANGLES,0,6),g.flush(),g.deleteTexture(y),g.deleteTexture(m),g.deleteBuffer(v),p},drawFigures:function(e,i,l,c,h){u||function(){var e,i;a(),e=s,s=null,i=o,o=null;var l=r(i,[t(i," 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); } "),n(i," precision mediump float; varying vec4 v_color; void main() { gl_FragColor = v_color; } ")]);i.useProgram(l);var c={};c.gl=i,c.canvas=e,c.resolutionLocation=i.getUniformLocation(l,"u_resolution"),c.scaleLocation=i.getUniformLocation(l,"u_scale"),c.offsetLocation=i.getUniformLocation(l,"u_offset"),c.positionLocation=i.getAttribLocation(l,"a_position"),c.colorLocation=i.getAttribLocation(l,"a_color"),u=c}();var d=u,f=d.canvas,p=d.gl;f.width=e,f.height=i,p.viewport(0,0,p.drawingBufferWidth,p.drawingBufferHeight),p.uniform2f(d.resolutionLocation,e,i);var g,y,m,v=0;for(g=0,y=c.length;g<y;g++)switch(c[g].type){case"lattice":v+=((m=c[g].coords.length/c[g].verticesPerRow|0)-1)*(c[g].verticesPerRow-1)*6;break;case"triangles":v+=c[g].coords.length}var _=new Float32Array(2*v),b=new Uint8Array(3*v),w=h.coords,A=h.colors,S=0,k=0;for(g=0,y=c.length;g<y;g++){var x=c[g],C=x.coords,P=x.colors;switch(x.type){case"lattice":var E=x.verticesPerRow;m=C.length/E|0;for(var T=1;T<m;T++)for(var R=T*E+1,O=1;O<E;O++,R++)_[S]=w[C[R-E-1]],_[S+1]=w[C[R-E-1]+1],_[S+2]=w[C[R-E]],_[S+3]=w[C[R-E]+1],_[S+4]=w[C[R-1]],_[S+5]=w[C[R-1]+1],b[k]=A[P[R-E-1]],b[k+1]=A[P[R-E-1]+1],b[k+2]=A[P[R-E-1]+2],b[k+3]=A[P[R-E]],b[k+4]=A[P[R-E]+1],b[k+5]=A[P[R-E]+2],b[k+6]=A[P[R-1]],b[k+7]=A[P[R-1]+1],b[k+8]=A[P[R-1]+2],_[S+6]=_[S+2],_[S+7]=_[S+3],_[S+8]=_[S+4],_[S+9]=_[S+5],_[S+10]=w[C[R]],_[S+11]=w[C[R]+1],b[k+9]=b[k+3],b[k+10]=b[k+4],b[k+11]=b[k+5],b[k+12]=b[k+6],b[k+13]=b[k+7],b[k+14]=b[k+8],b[k+15]=A[P[R]],b[k+16]=A[P[R]+1],b[k+17]=A[P[R]+2],S+=12,k+=18;break;case"triangles":for(var I=0,L=C.length;I<L;I++)_[S]=w[C[I]],_[S+1]=w[C[I]+1],b[k]=A[P[I]],b[k+1]=A[P[I]+1],b[k+2]=A[P[I]+2],S+=2,k+=3}}l?p.clearColor(l[0]/255,l[1]/255,l[2]/255,1):p.clearColor(0,0,0,0),p.clear(p.COLOR_BUFFER_BIT);var M=p.createBuffer();p.bindBuffer(p.ARRAY_BUFFER,M),p.bufferData(p.ARRAY_BUFFER,_,p.STATIC_DRAW),p.enableVertexAttribArray(d.positionLocation),p.vertexAttribPointer(d.positionLocation,2,p.FLOAT,!1,0,0);var N=p.createBuffer();return p.bindBuffer(p.ARRAY_BUFFER,N),p.bufferData(p.ARRAY_BUFFER,b,p.STATIC_DRAW),p.enableVertexAttribArray(d.colorLocation),p.vertexAttribPointer(d.colorLocation,3,p.UNSIGNED_BYTE,!1,0,0),p.uniform2f(d.scaleLocation,h.scaleX,h.scaleY),p.uniform2f(d.offsetLocation,h.offsetX,h.offsetY),p.drawArrays(p.TRIANGLES,0,v),p.flush(),p.deleteBuffer(M),p.deleteBuffer(N),f},cleanup:function(){l&&l.canvas&&(l.canvas.width=0,l.canvas.height=0),u&&u.canvas&&(u.canvas.width=0,u.canvas.height=0),l=null,u=null}}}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AnnotationLayer=void 0;var r=n(1),i=n(5);function o(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw o}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t,n){return(a="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=f(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}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 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&&(Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==l(t)&&"function"!=typeof t?d(e):t}function d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e}var m=function(){function e(){p(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 b(e);case i.AnnotationType.WIDGET:switch(e.data.fieldType){case"Tx":return new A(e);case"Btn":return e.data.radioButton?new k(e):e.data.checkBox?new S(e):new x(e);case"Ch":return new C(e)}return new w(e);case i.AnnotationType.POPUP:return new P(e);case i.AnnotationType.FREETEXT:return new T(e);case i.AnnotationType.LINE:return new R(e);case i.AnnotationType.SQUARE:return new O(e);case i.AnnotationType.CIRCLE:return new I(e);case i.AnnotationType.POLYLINE:return new L(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 F(e);case i.AnnotationType.UNDERLINE:return new j(e);case i.AnnotationType.SQUIGGLY:return new B(e);case i.AnnotationType.STRIKEOUT:return new q(e);case i.AnnotationType.STAMP:return new V(e);case i.AnnotationType.FILEATTACHMENT:return new U(e);default:return new v(e)}}}]),e}(),v=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];p(this,e),this.isRenderable=n,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,n&&(this.container=this._createContainer(r))}return y(e,[{key:"_createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.data,n=this.page,r=this.viewport,o=document.createElement("section"),s=t.rect[2]-t.rect[0],a=t.rect[3]-t.rect[1];o.setAttribute("data-annotation-id",t.id);var l=i.Util.normalizeRect([t.rect[0],n.view[3]-t.rect[1]+n.view[1],t.rect[2],n.view[3]-t.rect[3]+n.view[1]]);if(o.style.transform="matrix(".concat(r.transform.join(","),")"),o.style.transformOrigin="-".concat(l[0],"px -").concat(l[1],"px"),!e&&t.borderStyle.width>0){o.style.borderWidth="".concat(t.borderStyle.width,"px"),t.borderStyle.style!==i.AnnotationBorderStyleType.UNDERLINE&&(s-=2*t.borderStyle.width,a-=2*t.borderStyle.width);var u=t.borderStyle.horizontalCornerRadius,c=t.borderStyle.verticalCornerRadius;if(u>0||c>0){var h="".concat(u,"px / ").concat(c,"px");o.style.borderRadius=h}switch(t.borderStyle.style){case i.AnnotationBorderStyleType.SOLID:o.style.borderStyle="solid";break;case i.AnnotationBorderStyleType.DASHED:o.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:o.style.borderBottomStyle="solid"}t.color?o.style.borderColor=i.Util.makeCssRgb(0|t.color[0],0|t.color[1],0|t.color[2]):o.style.borderWidth=0}return o.style.left="".concat(l[0],"px"),o.style.top="".concat(l[1],"px"),o.style.width="".concat(s,"px"),o.style.height="".concat(a,"px"),o}},{key:"_createPopup",value:function(e,t,n){t||((t=document.createElement("div")).style.height=e.style.height,t.style.width=e.style.width,e.appendChild(t));var r=new E({container:e,trigger:t,color:n.color,title:n.title,modificationDate:n.modificationDate,contents:n.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(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.url||e.data.dest||e.data.action))}return y(n,[{key:"render",value:function(){this.container.className="linkAnnotation";var e=this.data,t=this.linkService,n=document.createElement("a");return e.url?(0,r.addLinkAttributes)(n,{url:e.url,target:e.newWindow?r.LinkTarget.BLANK:t.externalLinkTarget,rel:t.externalLinkRel,enabled:t.externalLinkEnabled}):e.action?this._bindNamedAction(n,e.action):this._bindLink(n,e.dest),this.container.appendChild(n),this.container}},{key:"_bindLink",value:function(e,t){var n=this;e.href=this.linkService.getDestinationHash(t),e.onclick=function(){return t&&n.linkService.navigateTo(t),!1},t&&(e.className="internalLink")}},{key:"_bindNamedAction",value:function(e,t){var n=this;e.href=this.linkService.getAnchorUrl(""),e.onclick=function(){return n.linkService.executeNamedAction(t),!1},e.className="internalLink"}}]),n}(v),b=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents))}return y(n,[{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}}]),n}(v),w=function(e){u(n,e);var t=c(n);function n(){return p(this,n),t.apply(this,arguments)}return y(n,[{key:"render",value:function(){return this.container}}]),n}(v),A=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,e.renderInteractiveForms||!e.data.hasAppearance&&!!e.data.fieldValue)}return y(n,[{key:"render",value:function(){this.container.className="textWidgetAnnotation";var e=null;if(this.renderInteractiveForms){if(this.data.multiLine?(e=document.createElement("textarea")).textContent=this.data.fieldValue:((e=document.createElement("input")).type="text",e.setAttribute("value",this.data.fieldValue)),e.disabled=this.data.readOnly,e.name=this.data.fieldName,null!==this.data.maxLen&&(e.maxLength=this.data.maxLen),this.data.comb){var t=(this.data.rect[2]-this.data.rect[0])/this.data.maxLen;e.classList.add("comb"),e.style.letterSpacing="calc(".concat(t,"px - 1ch)")}}else{(e=document.createElement("div")).textContent=this.data.fieldValue,e.style.verticalAlign="middle",e.style.display="table-cell";var n=null;this.data.fontRefName&&this.page.commonObjs.has(this.data.fontRefName)&&(n=this.page.commonObjs.get(this.data.fontRefName)),this._setTextStyle(e,n)}return null!==this.data.textAlignment&&(e.style.textAlign=["left","center","right"][this.data.textAlignment]),this.container.appendChild(e),this.container}},{key:"_setTextStyle",value:function(e,t){var n=e.style;if(n.fontSize="".concat(this.data.fontSize,"px"),n.direction=this.data.fontDirection<0?"rtl":"ltr",t){var r="normal";t.black?r="900":t.bold&&(r="bold"),n.fontWeight=r,n.fontStyle=t.italic?"italic":"normal";var i=t.loadedName?'"'.concat(t.loadedName,'", '):"";n.fontFamily=i+(t.fallbackName||"Helvetica, sans-serif")}}}]),n}(w),S=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,e.renderInteractiveForms)}return y(n,[{key:"render",value:function(){this.container.className="buttonWidgetAnnotation checkBox";var e=document.createElement("input");return e.disabled=this.data.readOnly,e.type="checkbox",e.name=this.data.fieldName,this.data.fieldValue&&"Off"!==this.data.fieldValue&&e.setAttribute("checked",!0),this.container.appendChild(e),this.container}}]),n}(w),k=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,e.renderInteractiveForms)}return y(n,[{key:"render",value:function(){this.container.className="buttonWidgetAnnotation radioButton";var e=document.createElement("input");return e.disabled=this.data.readOnly,e.type="radio",e.name=this.data.fieldName,this.data.fieldValue===this.data.buttonValue&&e.setAttribute("checked",!0),this.container.appendChild(e),this.container}}]),n}(w),x=function(e){u(n,e);var t=c(n);function n(){return p(this,n),t.apply(this,arguments)}return y(n,[{key:"render",value:function(){var e=a(f(n.prototype),"render",this).call(this);return e.className="buttonWidgetAnnotation pushButton",e}}]),n}(_),C=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,e.renderInteractiveForms)}return y(n,[{key:"render",value:function(){this.container.className="choiceWidgetAnnotation";var e=document.createElement("select");e.disabled=this.data.readOnly,e.name=this.data.fieldName,this.data.combo||(e.size=this.data.options.length,this.data.multiSelect&&(e.multiple=!0));var t,n=o(this.data.options);try{for(n.s();!(t=n.n()).done;){var r=t.value,i=document.createElement("option");i.textContent=r.displayValue,i.value=r.exportValue,this.data.fieldValue.includes(r.displayValue)&&i.setAttribute("selected",!0),e.appendChild(i)}}catch(s){n.e(s)}finally{n.f()}return this.container.appendChild(e),this.container}}]),n}(w),P=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!(!e.data.title&&!e.data.contents))}return y(n,[{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 n=new E({container:this.container,trigger:t,color:this.data.color,title:this.data.title,modificationDate:this.data.modificationDate,contents:this.data.contents}),r=parseFloat(t.style.left),i=parseFloat(t.style.width);return this.container.style.transformOrigin="-".concat(r+i,"px -").concat(t.style.top),this.container.style.left="".concat(r+i,"px"),this.container.appendChild(n.render()),this.container}}]),n}(v),E=function(){function e(t){p(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 n=this.color;n&&(t.style.backgroundColor=i.Util.makeCssRgb(0|.7*(255-n[0])+n[0],0|.7*(255-n[1])+n[1],0|.7*(255-n[2])+n[2]));var o=document.createElement("h1");o.textContent=this.title,t.appendChild(o);var s=r.PDFDateString.toDateObject(this.modificationDate);if(s){var a=document.createElement("span");a.textContent="{{date}}, {{time}}",a.dataset.l10nId="annotation_date_string",a.dataset.l10nArgs=JSON.stringify({date:s.toLocaleDateString(),time:s.toLocaleTimeString()}),t.appendChild(a)}var l=this._formatContents(this.contents);return t.appendChild(l),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"),n=e.split(/(?:\r\n?|\n)/),r=0,i=n.length;r<i;++r)t.appendChild(document.createTextNode(n[r])),r<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(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];e&&(this.pinned=!0),this.hideElement.hasAttribute("hidden")&&(this.hideElement.removeAttribute("hidden"),this.container.style.zIndex+=1)}},{key:"_hide",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];e&&(this.pinned=!1),this.hideElement.hasAttribute("hidden")||this.pinned||(this.hideElement.setAttribute("hidden",!0),this.container.style.zIndex-=1)}}]),e}(),T=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="freeTextAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),R=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){this.container.className="lineAnnotation";var e=this.data,t=this.svgFactory.create(e.rect[2]-e.rect[0],e.rect[3]-e.rect[1]),n=this.svgFactory.createElement("svg:line");return n.setAttribute("x1",e.rect[2]-e.lineCoordinates[0]),n.setAttribute("y1",e.rect[3]-e.lineCoordinates[1]),n.setAttribute("x2",e.rect[2]-e.lineCoordinates[2]),n.setAttribute("y2",e.rect[3]-e.lineCoordinates[3]),n.setAttribute("stroke-width",e.borderStyle.width||1),n.setAttribute("stroke","transparent"),t.appendChild(n),this.container.append(t),this._createPopup(this.container,n,e),this.container}}]),n}(v),O=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){this.container.className="squareAnnotation";var e=this.data,t=e.rect[2]-e.rect[0],n=e.rect[3]-e.rect[1],r=this.svgFactory.create(t,n),i=e.borderStyle.width,o=this.svgFactory.createElement("svg:rect");return o.setAttribute("x",i/2),o.setAttribute("y",i/2),o.setAttribute("width",t-i),o.setAttribute("height",n-i),o.setAttribute("stroke-width",i||1),o.setAttribute("stroke","transparent"),o.setAttribute("fill","none"),r.appendChild(o),this.container.append(r),this._createPopup(this.container,o,e),this.container}}]),n}(v),I=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){this.container.className="circleAnnotation";var e=this.data,t=e.rect[2]-e.rect[0],n=e.rect[3]-e.rect[1],r=this.svgFactory.create(t,n),i=e.borderStyle.width,o=this.svgFactory.createElement("svg:ellipse");return o.setAttribute("cx",t/2),o.setAttribute("cy",n/2),o.setAttribute("rx",t/2-i/2),o.setAttribute("ry",n/2-i/2),o.setAttribute("stroke-width",i||1),o.setAttribute("stroke","transparent"),o.setAttribute("fill","none"),r.appendChild(o),this.container.append(r),this._createPopup(this.container,o,e),this.container}}]),n}(v),L=function(e){u(n,e);var t=c(n);function n(e){var r;return p(this,n),(r=t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)).containerClassName="polylineAnnotation",r.svgElementName="svg:polyline",r}return y(n,[{key:"render",value:function(){this.container.className=this.containerClassName;var e,t=this.data,n=this.svgFactory.create(t.rect[2]-t.rect[0],t.rect[3]-t.rect[1]),r=[],i=o(t.vertices);try{for(i.s();!(e=i.n()).done;){var s=e.value;r.push(s.x-t.rect[0]+","+(t.rect[3]-s.y))}}catch(l){i.e(l)}finally{i.f()}r=r.join(" ");var a=this.svgFactory.createElement(this.svgElementName);return a.setAttribute("points",r),a.setAttribute("stroke-width",t.borderStyle.width||1),a.setAttribute("stroke","transparent"),a.setAttribute("fill","none"),n.appendChild(a),this.container.append(n),this._createPopup(this.container,a,t),this.container}}]),n}(v),M=function(e){u(n,e);var t=c(n);function n(e){var r;return p(this,n),(r=t.call(this,e)).containerClassName="polygonAnnotation",r.svgElementName="svg:polygon",r}return n}(L),N=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="caretAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),D=function(e){u(n,e);var t=c(n);function n(e){var r;return p(this,n),(r=t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)).containerClassName="inkAnnotation",r.svgElementName="svg:polyline",r}return y(n,[{key:"render",value:function(){this.container.className=this.containerClassName;var e,t=this.data,n=this.svgFactory.create(t.rect[2]-t.rect[0],t.rect[3]-t.rect[1]),r=o(t.inkLists);try{for(r.s();!(e=r.n()).done;){var i,s=[],a=o(e.value);try{for(a.s();!(i=a.n()).done;){var l=i.value,u=t.rect[3]-l.y;s.push("".concat(l.x-t.rect[0],",").concat(u))}}catch(h){a.e(h)}finally{a.f()}s=s.join(" ");var c=this.svgFactory.createElement(this.svgElementName);c.setAttribute("points",s),c.setAttribute("stroke-width",t.borderStyle.width||1),c.setAttribute("stroke","transparent"),c.setAttribute("fill","none"),this._createPopup(this.container,c,t),n.appendChild(c)}}catch(h){r.e(h)}finally{r.f()}return this.container.append(n),this.container}}]),n}(v),F=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="highlightAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),j=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="underlineAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),B=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="squigglyAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),q=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="strikeoutAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),V=function(e){u(n,e);var t=c(n);function n(e){return p(this,n),t.call(this,e,!!(e.data.hasPopup||e.data.title||e.data.contents),!0)}return y(n,[{key:"render",value:function(){return this.container.className="stampAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}]),n}(v),U=function(e){u(n,e);var t=c(n);function n(e){var o;p(this,n);var s=(o=t.call(this,e,!0)).data.file,a=s.filename,l=s.content;return o.filename=(0,r.getFilenameFromUrl)(a),o.content=l,o.linkService.eventBus&&o.linkService.eventBus.dispatch("fileattachmentannotation",{source:d(o),id:(0,i.stringToPDFString)(a),filename:a,content:l}),o}return y(n,[{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")}}]),n}(v);t.AnnotationLayer=function(){function e(){p(this,e)}return y(e,null,[{key:"render",value:function(e){var t,n=[],s=[],a=o(e.annotations);try{for(a.s();!(t=a.n()).done;){var l=t.value;l&&(l.annotationType!==i.AnnotationType.POPUP?n.push(l):s.push(l))}}catch(d){a.e(d)}finally{a.f()}s.length&&n.push.apply(n,s);for(var u=0,c=n;u<c.length;u++){var h=m.create({data:c[u],layer:e.div,page:e.page,viewport:e.viewport,linkService:e.linkService,downloadManager:e.downloadManager,imageResourcesPath:e.imageResourcesPath||"",renderInteractiveForms:e.renderInteractiveForms||!1,svgFactory:new r.DOMSVGFactory});h.isRenderable&&e.div.appendChild(h.render())}}},{key:"update",value:function(e){var t,n=o(e.annotations);try{for(n.s();!(t=n.n()).done;){var r=e.div.querySelector('[data-annotation-id="'.concat(t.value.id,'"]'));r&&(r.style.transform="matrix(".concat(e.viewport.transform.join(","),")"))}}catch(i){n.e(i)}finally{n.f()}e.div.removeAttribute("hidden")}}]),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.renderTextLayer=void 0;var r=n(5),i=function(){var e=/\S/;function t(t,n,i){var o=document.createElement("span"),s={angle:0,canvasWidth:0,isWhitespace:!1,originalTransform:null,paddingBottom:0,paddingLeft:0,paddingRight:0,paddingTop:0,scale:1};if(t._textDivs.push(o),!e.test(n.str))return s.isWhitespace=!0,void t._textDivProperties.set(o,s);var a=r.Util.transform(t._viewport.transform,n.transform),l=Math.atan2(a[1],a[0]),u=i[n.fontName];u.vertical&&(l+=Math.PI/2);var c,h,d=Math.sqrt(a[2]*a[2]+a[3]*a[3]),f=d;u.ascent?f*=u.ascent:u.descent&&(f*=1+u.descent),0===l?(c=a[4],h=a[5]-f):(c=a[4]+f*Math.sin(l),h=a[5]-f*Math.cos(l)),o.style.left="".concat(c,"px"),o.style.top="".concat(h,"px"),o.style.fontSize="".concat(d,"px"),o.style.fontFamily=u.fontFamily,o.textContent=n.str,t._fontInspectorEnabled&&(o.dataset.fontName=n.fontName),0!==l&&(s.angle=l*(180/Math.PI));var p=!1;if(n.str.length>1)p=!0;else if(n.transform[0]!==n.transform[3]){var g=Math.abs(n.transform[0]),y=Math.abs(n.transform[3]);g!==y&&Math.max(g,y)/Math.min(g,y)>1.5&&(p=!0)}if(p&&(s.canvasWidth=u.vertical?n.height*t._viewport.scale:n.width*t._viewport.scale),t._textDivProperties.set(o,s),t._textContentStream&&t._layoutText(o),t._enhanceTextSelection){var m=1,v=0;0!==l&&(m=Math.cos(l),v=Math.sin(l));var _,b,w=(u.vertical?n.height:n.width)*t._viewport.scale,A=d;b=0!==l?r.Util.getAxialAlignedBoundingBox([0,0,w,A],_=[m,v,-v,m,c,h]):[c,h,c+w,h+A],t._bounds.push({left:b[0],top:b[1],right:b[2],bottom:b[3],div:o,size:[w,A],m:_})}}function n(e){if(!e._canceled){var t=e._textDivs,n=e._capability,r=t.length;if(r>1e5)return e._renderingDone=!0,void n.resolve();if(!e._textContentStream)for(var i=0;i<r;i++)e._layoutText(t[i]);e._renderingDone=!0,n.resolve()}}function i(e,t,n){for(var r=0,i=0;i<n;i++){var o=e[t++];o>0&&(r=r?Math.min(o,r):o)}return r}function o(e,t){t.sort((function(e,t){return e.x1-t.x1||e.index-t.index}));var n=[{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<n.length&&n[t].end<=e.y1;)t++;for(var r,i,o=n.length-1;o>=0&&n[o].start>=e.y2;)o--;var s,a,l=-1/0;for(s=t;s<=o;s++){var u;(u=(i=(r=n[s]).boundary).x2>e.x1?i.index>e.index?i.x1New:e.x1:void 0===i.x2New?(i.x2+e.x1)/2:i.x2New)>l&&(l=u)}for(e.x1New=l,s=t;s<=o;s++)void 0===(i=(r=n[s]).boundary).x2New?i.x2>e.x1?i.index>e.index&&(i.x2New=i.x2):i.x2New=l:i.x2New>l&&(i.x2New=Math.max(l,i.x2));var c=[],h=null;for(s=t;s<=o;s++){var d=(i=(r=n[s]).boundary).x2>e.x2?i:e;h===d?c[c.length-1].end=r.end:(c.push({start:r.start,end:r.end,boundary:d}),h=d)}for(n[t].start<e.y1&&(c[0].start=e.y1,c.unshift({start:n[t].start,end:e.y1,boundary:n[t].boundary})),e.y2<n[o].end&&(c[c.length-1].end=e.y2,c.push({start:e.y2,end:n[o].end,boundary:n[o].boundary})),s=t;s<=o;s++)if(void 0===(i=(r=n[s]).boundary).x2New){var f=!1;for(a=t-1;!f&&a>=0&&n[a].start>=i.y1;a--)f=n[a].boundary===i;for(a=o+1;!f&&a<n.length&&n[a].end<=i.y2;a++)f=n[a].boundary===i;for(a=0;!f&&a<c.length;a++)f=c[a].boundary===i;f||(i.x2New=l)}Array.prototype.splice.apply(n,[t,o-t+1].concat(c))})),n.forEach((function(t){var n=t.boundary;void 0===n.x2New&&(n.x2New=Math.max(e,n.x2))}))}function s(e){var t=this,n=e.textContentStream,i=e.container,o=e.viewport,s=e.textDivs,a=e.textContentItemsStr,l=e.enhanceTextSelection;this._textContent=e.textContent,this._textContentStream=n,this._container=i,this._viewport=o,this._textDivs=s||[],this._textContentItemsStr=a||[],this._enhanceTextSelection=!!l,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,r.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(){}))}return s.prototype={get promise(){return this._capability.promise},cancel:function(){this._canceled=!0,this._reader&&(this._reader.cancel(new r.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,n){for(var r=0,i=e.length;r<i;r++)this._textContentItemsStr.push(e[r].str),t(this,e[r],n)},_layoutText:function(e){var t=this._textDivProperties.get(e);if(!t.isWhitespace){var n="";if(0!==t.canvasWidth){var r=e.style,i=r.fontSize,o=r.fontFamily;i===this._layoutTextLastFontSize&&o===this._layoutTextLastFontFamily||(this._layoutTextCtx.font="".concat(i," ").concat(o),this._layoutTextLastFontSize=i,this._layoutTextLastFontFamily=o);var s=this._layoutTextCtx.measureText(e.textContent).width;s>0&&(t.scale=t.canvasWidth/s,n="scaleX(".concat(t.scale,")"))}0!==t.angle&&(n="rotate(".concat(t.angle,"deg) ").concat(n)),n.length>0&&(this._enhanceTextSelection&&(t.originalTransform=n),e.style.transform=n),this._textDivProperties.set(e,t),this._container.appendChild(e)}},_render:function(e){var t=this,i=(0,r.createPromiseCapability)(),o=Object.create(null),s=document.createElement("canvas");if(s.mozOpaque=!0,this._layoutTextCtx=s.getContext("2d",{alpha:!1}),this._textContent)this._processItems(this._textContent.items,this._textContent.styles),i.resolve();else{if(!this._textContentStream)throw new Error('Neither "textContent" nor "textContentStream" parameters specified.');this._reader=this._textContentStream.getReader(),function e(){t._reader.read().then((function(n){var r=n.value;n.done?i.resolve():(Object.assign(o,r.styles),t._processItems(r.items,o),e())}),i.reject)}()}i.promise.then((function(){o=null,e?t._renderTimer=setTimeout((function(){n(t),t._renderTimer=null}),e):n(t)}),this._capability.reject)},expandTextDivs:function(e){if(this._enhanceTextSelection&&this._renderingDone){null!==this._bounds&&(function(e){for(var t=e._bounds,n=e._viewport,s=function(e,t,n){var r=n.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}}));o(e,r);var i=new Array(n.length);return r.forEach((function(e){i[e.index]={left:e.x1New,top:0,right:e.x2New,bottom:0}})),n.map((function(t,n){var o=i[n],s=r[n];s.x1=t.top,s.y1=e-o.right,s.x2=t.bottom,s.y2=e-o.left,s.index=n,s.x1New=void 0,s.x2New=void 0})),o(t,r),r.forEach((function(e){var t=e.index;i[t].top=e.x1New,i[t].bottom=e.x2New})),i}(n.width,n.height,t),a=0;a<s.length;a++){var l=t[a].div,u=e._textDivProperties.get(l);if(0!==u.angle){var c=s[a],h=t[a],d=h.m,f=d[0],p=d[1],g=[[0,0],[0,h.size[1]],[h.size[0],0],h.size],y=new Float64Array(64);g.forEach((function(e,t){var n=r.Util.applyTransform(e,d);y[t+0]=f&&(c.left-n[0])/f,y[t+4]=p&&(c.top-n[1])/p,y[t+8]=f&&(c.right-n[0])/f,y[t+12]=p&&(c.bottom-n[1])/p,y[t+16]=p&&(c.left-n[0])/-p,y[t+20]=f&&(c.top-n[1])/f,y[t+24]=p&&(c.right-n[0])/-p,y[t+28]=f&&(c.bottom-n[1])/f,y[t+32]=f&&(c.left-n[0])/-f,y[t+36]=p&&(c.top-n[1])/-p,y[t+40]=f&&(c.right-n[0])/-f,y[t+44]=p&&(c.bottom-n[1])/-p,y[t+48]=p&&(c.left-n[0])/p,y[t+52]=f&&(c.top-n[1])/-f,y[t+56]=p&&(c.right-n[0])/p,y[t+60]=f&&(c.bottom-n[1])/-f}));var m=1+Math.min(Math.abs(f),Math.abs(p));u.paddingLeft=i(y,32,16)/m,u.paddingTop=i(y,48,16)/m,u.paddingRight=i(y,0,16)/m,u.paddingBottom=i(y,16,16)/m,e._textDivProperties.set(l,u)}else u.paddingLeft=t[a].left-s[a].left,u.paddingTop=t[a].top-s[a].top,u.paddingRight=s[a].right-t[a].right,u.paddingBottom=s[a].bottom-t[a].bottom,e._textDivProperties.set(l,u)}}(this),this._bounds=null);for(var t=[],n=[],s=0,a=this._textDivs.length;s<a;s++){var l=this._textDivs[s],u=this._textDivProperties.get(l);u.isWhitespace||(e?(t.length=0,n.length=0,u.originalTransform&&t.push(u.originalTransform),u.paddingTop>0?(n.push("".concat(u.paddingTop,"px")),t.push("translateY(".concat(-u.paddingTop,"px)"))):n.push(0),n.push(u.paddingRight>0?"".concat(u.paddingRight/u.scale,"px"):0),n.push(u.paddingBottom>0?"".concat(u.paddingBottom,"px"):0),u.paddingLeft>0?(n.push("".concat(u.paddingLeft/u.scale,"px")),t.push("translateX(".concat(-u.paddingLeft/u.scale,"px)"))):n.push(0),l.style.padding=n.join(" "),t.length&&(l.style.transform=t.join(" "))):(l.style.padding=null,l.style.transform=u.originalTransform))}}}},function(e){var t=new s({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}}();t.renderTextLayer=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SVGGraphics=void 0;var r=n(5),i=n(1),o=n(7);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 n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(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 a(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=l(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function l(e,t){if(e){if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(e,t):void 0}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t,n){return t&&h(e.prototype,t),n&&h(e,n),e}var f=function(){throw new Error("Not implemented: SVGGraphics")};t.SVGGraphics=f;var p=function(e){if(Number.isInteger(e))return e.toString();var t=e.toFixed(10),n=t.length-1;if("0"!==t[n])return t;do{n--}while("0"===t[n]);return t.substring(0,"."===t[n]?n:n+1)},g=function(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]),")")},y="normal",m="#000000",v=["butt","round","square"],_=["miter","round","bevel"],b=function(){for(var e=new Uint8Array([137,80,78,71,13,10,26,10]),t=new Int32Array(256),n=0;n<256;n++){for(var i=n,s=0;s<8;s++)i=1&i?3988292384^i>>1&2147483647:i>>1&2147483647;t[n]=i}function a(e,n,r,i){var o=i,s=n.length;r[o]=s>>24&255,r[o+1]=s>>16&255,r[o+2]=s>>8&255,r[o+3]=255&s,r[o+=4]=255&e.charCodeAt(0),r[o+1]=255&e.charCodeAt(1),r[o+2]=255&e.charCodeAt(2),r[o+3]=255&e.charCodeAt(3),r.set(n,o+=4);var a=function(e,n,r){for(var i=-1,o=n;o<r;o++)i=i>>>8^t[255&(i^e[o])];return-1^i}(r,i+4,o+=n.length);r[o]=a>>24&255,r[o+1]=a>>16&255,r[o+2]=a>>8&255,r[o+3]=255&a}function l(e){var t=e.length,n=65535,r=Math.ceil(t/n),i=new Uint8Array(2+t+5*r+4),o=0;i[o++]=120,i[o++]=156;for(var s=0;t>n;)i[o++]=0,i[o++]=255,i[o++]=255,i[o++]=0,i[o++]=0,i.set(e.subarray(s,s+n),o),o+=n,s+=n,t-=n;i[o++]=1,i[o++]=255&t,i[o++]=t>>8&255,i[o++]=255&~t,i[o++]=(65535&~t)>>8&255,i.set(e.subarray(s),o),o+=e.length-s;var a=function(e,t,n){for(var r=1,i=0,o=0;o<n;++o)i=(i+(r=(r+(255&e[o]))%65521))%65521;return i<<16|r}(e,0,e.length);return i[o++]=a>>24&255,i[o++]=a>>16&255,i[o++]=a>>8&255,i[o++]=255&a,i}return function(t,n,i){return function(t,n,i,s){var u,c,h,d=t.width,f=t.height,p=t.data;switch(n){case r.ImageKind.GRAYSCALE_1BPP:c=0,u=1,h=d+7>>3;break;case r.ImageKind.RGB_24BPP:c=2,u=8,h=3*d;break;case r.ImageKind.RGBA_32BPP:c=6,u=8,h=4*d;break;default:throw new Error("invalid format")}for(var g=new Uint8Array((1+h)*f),y=0,m=0,v=0;v<f;++v)g[y++]=0,g.set(p.subarray(m,m+h),y),m+=h,y+=h;if(n===r.ImageKind.GRAYSCALE_1BPP&&s){y=0;for(var _=0;_<f;_++){y++;for(var b=0;b<h;b++)g[y++]^=255}}var w=new Uint8Array([d>>24&255,d>>16&255,d>>8&255,255&d,f>>24&255,f>>16&255,f>>8&255,255&f,u,c,0,0,0]),A=function(e){if(!o.isNodeJS)return l(e);try{var t;t=parseInt(process.versions.node)>=8?e:Buffer.from(e);var n=__webpack_require__(1).deflateSync(t,{level:9});return n instanceof Uint8Array?n:new Uint8Array(n)}catch(i){(0,r.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+i)}return l(e)}(g),S=new Uint8Array(e.length+36+w.length+A.length),k=0;return S.set(e,k),a("IHDR",w,S,k+=e.length),a("IDATA",A,S,k+=12+w.length),k+=12+A.length,a("IEND",new Uint8Array(0),S,k),(0,r.createObjectURL)(S,"image/png",i)}(t,void 0===t.kind?r.ImageKind.GRAYSCALE_1BPP:t.kind,n,i)}}(),w=function(){function e(){c(this,e),this.fontSizeScale=1,this.fontWeight=y,this.fontSize=0,this.textMatrix=r.IDENTITY_MATRIX,this.fontMatrix=r.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=r.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=m,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}(),A=0,S=0,k=0;t.SVGGraphics=f=function(){function e(t,n){var o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];for(var s in c(this,e),this.svgFactory=new i.DOMSVGFactory,this.current=new w,this.transformMatrix=r.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=t,this.objs=n,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!o,this._operatorIdMapping=[],r.OPS)this._operatorIdMapping[r.OPS[s]]=s}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,n=e.fnArray,i=e.argsArray,o=0,s=n.length;o<s;o++)if(n[o]===r.OPS.dependency){var l,u=a(i[o]);try{var c=function(){var e=l.value,n=e.startsWith("g_")?t.commonObjs:t.objs,r=new Promise((function(t){n.get(e,t)}));t.current.dependencies.push(r)};for(u.s();!(l=u.n()).done;)c()}catch(h){u.e(h)}finally{u.f()}}return Promise.all(this.current.dependencies)}},{key:"transform",value:function(e,t,n,i,o,s){this.transformMatrix=r.Util.transform(this.transformMatrix,[e,t,n,i,o,s]),this.tgrp=null}},{key:"getSVG",value:function(e,t){var n=this;this.viewport=t;var i=this._initialize(t);return this.loadDependencies(e).then((function(){return n.transformMatrix=r.IDENTITY_MATRIX,n.executeOpTree(n.convertOpList(e)),i}))}},{key:"convertOpList",value:function(e){for(var t=this._operatorIdMapping,n=e.argsArray,r=e.fnArray,i=[],o=0,s=r.length;o<s;o++){var l=r[o];i.push({fnId:l,fn:t[l],args:n[o]})}return function(e){var t,n=[],r=[],i=a(e);try{for(i.s();!(t=i.n()).done;){var o=t.value;"save"!==o.fn?"restore"===o.fn?n=r.pop():n.push(o):(n.push({fnId:92,fn:"group",items:[]}),r.push(n),n=n[n.length-1].items)}}catch(s){i.e(s)}finally{i.f()}return n}(i)}},{key:"executeOpTree",value:function(e){var t,n=a(e);try{for(n.s();!(t=n.n()).done;){var i=t.value,o=i.fn,s=i.args;switch(0|i.fnId){case r.OPS.beginText:this.beginText();break;case r.OPS.dependency:break;case r.OPS.setLeading:this.setLeading(s);break;case r.OPS.setLeadingMoveText:this.setLeadingMoveText(s[0],s[1]);break;case r.OPS.setFont:this.setFont(s);break;case r.OPS.showText:case r.OPS.showSpacedText:this.showText(s[0]);break;case r.OPS.endText:this.endText();break;case r.OPS.moveText:this.moveText(s[0],s[1]);break;case r.OPS.setCharSpacing:this.setCharSpacing(s[0]);break;case r.OPS.setWordSpacing:this.setWordSpacing(s[0]);break;case r.OPS.setHScale:this.setHScale(s[0]);break;case r.OPS.setTextMatrix:this.setTextMatrix(s[0],s[1],s[2],s[3],s[4],s[5]);break;case r.OPS.setTextRise:this.setTextRise(s[0]);break;case r.OPS.setTextRenderingMode:this.setTextRenderingMode(s[0]);break;case r.OPS.setLineWidth:this.setLineWidth(s[0]);break;case r.OPS.setLineJoin:this.setLineJoin(s[0]);break;case r.OPS.setLineCap:this.setLineCap(s[0]);break;case r.OPS.setMiterLimit:this.setMiterLimit(s[0]);break;case r.OPS.setFillRGBColor:this.setFillRGBColor(s[0],s[1],s[2]);break;case r.OPS.setStrokeRGBColor:this.setStrokeRGBColor(s[0],s[1],s[2]);break;case r.OPS.setStrokeColorN:this.setStrokeColorN(s);break;case r.OPS.setFillColorN:this.setFillColorN(s);break;case r.OPS.shadingFill:this.shadingFill(s[0]);break;case r.OPS.setDash:this.setDash(s[0],s[1]);break;case r.OPS.setRenderingIntent:this.setRenderingIntent(s[0]);break;case r.OPS.setFlatness:this.setFlatness(s[0]);break;case r.OPS.setGState:this.setGState(s[0]);break;case r.OPS.fill:this.fill();break;case r.OPS.eoFill:this.eoFill();break;case r.OPS.stroke:this.stroke();break;case r.OPS.fillStroke:this.fillStroke();break;case r.OPS.eoFillStroke:this.eoFillStroke();break;case r.OPS.clip:this.clip("nonzero");break;case r.OPS.eoClip:this.clip("evenodd");break;case r.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case r.OPS.paintImageXObject:this.paintImageXObject(s[0]);break;case r.OPS.paintInlineImageXObject:this.paintInlineImageXObject(s[0]);break;case r.OPS.paintImageMaskXObject:this.paintImageMaskXObject(s[0]);break;case r.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(s[0],s[1]);break;case r.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case r.OPS.closePath:this.closePath();break;case r.OPS.closeStroke:this.closeStroke();break;case r.OPS.closeFillStroke:this.closeFillStroke();break;case r.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case r.OPS.nextLine:this.nextLine();break;case r.OPS.transform:this.transform(s[0],s[1],s[2],s[3],s[4],s[5]);break;case r.OPS.constructPath:this.constructPath(s[0],s[1]);break;case r.OPS.endPath:this.endPath();break;case 92:this.group(i.items);break;default:(0,r.warn)("Unimplemented operator ".concat(o))}}}catch(l){n.e(l)}finally{n.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,n,r,i,o){var s=this.current;s.textMatrix=s.lineMatrix=[e,t,n,r,i,o],s.textMatrixScale=Math.sqrt(e*e+t*t),s.x=s.lineX=0,s.y=s.lineY=0,s.xcoords=[],s.ycoords=[],s.tspan=this.svgFactory.createElement("svg:tspan"),s.tspan.setAttributeNS(null,"font-family",s.fontFamily),s.tspan.setAttributeNS(null,"font-size","".concat(p(s.fontSize),"px")),s.tspan.setAttributeNS(null,"y",p(-s.y)),s.txtElement=this.svgFactory.createElement("svg:text"),s.txtElement.appendChild(s.tspan)}},{key:"beginText",value:function(){var e=this.current;e.x=e.lineX=0,e.y=e.lineY=0,e.textMatrix=r.IDENTITY_MATRIX,e.lineMatrix=r.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 n=this.current;n.x=n.lineX+=e,n.y=n.lineY+=t,n.xcoords=[],n.ycoords=[],n.tspan=this.svgFactory.createElement("svg:tspan"),n.tspan.setAttributeNS(null,"font-family",n.fontFamily),n.tspan.setAttributeNS(null,"font-size","".concat(p(n.fontSize),"px")),n.tspan.setAttributeNS(null,"y",p(-n.y))}},{key:"showText",value:function(e){var t=this.current,n=t.font,i=t.fontSize;if(0!==i){var o,s=t.fontSizeScale,l=t.charSpacing,u=t.wordSpacing,c=t.fontDirection,h=t.textHScale*c,d=n.vertical,f=d?1:-1,v=n.defaultVMetrics,_=i*t.fontMatrix[0],b=0,w=a(e);try{for(w.s();!(o=w.n()).done;){var A=o.value;if(null!==A)if((0,r.isNum)(A))b+=f*A*i/1e3;else{var S=(A.isSpace?u:0)+l,k=A.fontChar,x=void 0,C=void 0,P=A.width;if(d){var E=void 0,T=A.vmetric||v;E=A.vmetric?T[1]:.5*P,P=T?-T[0]:P,x=(E=-E*_)/s,C=(b+T[2]*_)/s}else x=b/s,C=0;(A.isInFont||n.missingFile)&&(t.xcoords.push(t.x+x),d&&t.ycoords.push(-t.y+C),t.tspan.textContent+=k),b+=d?P*_-S*c:P*_+S*c}else b+=c*u}}catch(I){w.e(I)}finally{w.f()}t.tspan.setAttributeNS(null,"x",t.xcoords.map(p).join(" ")),t.tspan.setAttributeNS(null,"y",d?t.ycoords.map(p).join(" "):p(-t.y)),d?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")),"normal"!==t.fontStyle&&t.tspan.setAttributeNS(null,"font-style",t.fontStyle),t.fontWeight!==y&&t.tspan.setAttributeNS(null,"font-weight",t.fontWeight);var R=t.textRenderingMode&r.TextRenderingMode.FILL_STROKE_MASK;R===r.TextRenderingMode.FILL||R===r.TextRenderingMode.FILL_STROKE?(t.fillColor!==m&&t.tspan.setAttributeNS(null,"fill",t.fillColor),t.fillAlpha<1&&t.tspan.setAttributeNS(null,"fill-opacity",t.fillAlpha)):t.tspan.setAttributeNS(null,"fill",t.textRenderingMode===r.TextRenderingMode.ADD_TO_PATH?"transparent":"none"),(R===r.TextRenderingMode.STROKE||R===r.TextRenderingMode.FILL_STROKE)&&this._setStrokeAttributes(t.tspan,1/(t.textMatrixScale||1));var O=t.textMatrix;0!==t.textRise&&((O=O.slice())[5]+=t.textRise),t.txtElement.setAttributeNS(null,"transform","".concat(g(O)," 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,r.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,n=this.commonObjs.get(e[0]),i=e[1];t.font=n,!this.embedFonts||n.missingFile||this.embeddedFonts[n.loadedName]||(this.addFontStyle(n),this.embeddedFonts[n.loadedName]=n),t.fontMatrix=n.fontMatrix?n.fontMatrix:r.FONT_IDENTITY_MATRIX;var o="normal";n.black?o="900":n.bold&&(o="bold");var s=n.italic?"italic":"normal";i<0?(i=-i,t.fontDirection=-1):t.fontDirection=1,t.fontSize=i,t.fontFamily=n.loadedName,t.fontWeight=o,t.fontStyle=s,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&r.TextRenderingMode.ADD_TO_PATH_FLAG&&e.txtElement&&e.txtElement.hasChildNodes()&&(e.element=e.txtElement,this.clip("nonzero"),this.endPath())}},{key:"setLineWidth",value:function(e){e>0&&(this.current.lineWidth=e)}},{key:"setLineCap",value:function(e){this.current.lineCap=v[e]}},{key:"setLineJoin",value:function(e){this.current.lineJoin=_[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,n){this.current.strokeColor=r.Util.makeCssRgb(e,t,n)}},{key:"setFillAlpha",value:function(e){this.current.fillAlpha=e}},{key:"setFillRGBColor",value:function(e,t,n){this.current.fillColor=r.Util.makeCssRgb(e,t,n),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,n=this.viewport.height,i=r.Util.inverseTransform(this.transformMatrix),o=r.Util.applyTransform([0,0],i),s=r.Util.applyTransform([0,n],i),a=r.Util.applyTransform([t,0],i),l=r.Util.applyTransform([t,n],i),u=Math.min(o[0],s[0],a[0],l[0]),c=Math.min(o[1],s[1],a[1],l[1]),h=Math.max(o[0],s[0],a[0],l[0]),d=Math.max(o[1],s[1],a[1],l[1]),f=this.svgFactory.createElement("svg:rect");f.setAttributeNS(null,"x",u),f.setAttributeNS(null,"y",c),f.setAttributeNS(null,"width",h-u),f.setAttributeNS(null,"height",d-c),f.setAttributeNS(null,"fill",this._makeShadingPattern(e)),this.current.fillAlpha<1&&f.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().appendChild(f)}},{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],n=e[2],i=e[3]||r.IDENTITY_MATRIX,o=s(e[4],4),a=o[0],c=o[1],h=o[2],d=o[3],f=e[5],p=e[6],g=e[7],y="shading".concat(k++),m=s(r.Util.applyTransform([a,c],i),2),v=m[0],_=m[1],b=s(r.Util.applyTransform([h,d],i),2),w=b[0],A=b[1],S=s(r.Util.singularValueDecompose2dScale(i),2),x=f*S[0],C=p*S[1],P=this.svgFactory.createElement("svg:pattern");P.setAttributeNS(null,"id",y),P.setAttributeNS(null,"patternUnits","userSpaceOnUse"),P.setAttributeNS(null,"width",x),P.setAttributeNS(null,"height",C),P.setAttributeNS(null,"x","".concat(v)),P.setAttributeNS(null,"y","".concat(_));var E,T=this.svg,R=this.transformMatrix,O=this.current.fillColor,I=this.current.strokeColor,L=this.svgFactory.create(w-v,A-_);if(this.svg=L,this.transformMatrix=i,2===g){var M=r.Util.makeCssRgb.apply(r.Util,function(e){if(Array.isArray(e))return u(e)}(E=t)||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.")}());this.current.fillColor=M,this.current.strokeColor=M}return this.executeOpTree(this.convertOpList(n)),this.svg=T,this.transformMatrix=R,this.current.fillColor=O,this.current.strokeColor=I,P.appendChild(L.childNodes[0]),this.defs.appendChild(P),"url(#".concat(y,")")}},{key:"_makeShadingPattern",value:function(e){switch(e[0]){case"RadialAxial":var t,n="shading".concat(k++),i=e[3];switch(e[1]){case"axial":var o=e[4],s=e[5];(t=this.svgFactory.createElement("svg:linearGradient")).setAttributeNS(null,"id",n),t.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),t.setAttributeNS(null,"x1",o[0]),t.setAttributeNS(null,"y1",o[1]),t.setAttributeNS(null,"x2",s[0]),t.setAttributeNS(null,"y2",s[1]);break;case"radial":var l=e[4],u=e[5],c=e[6],h=e[7];(t=this.svgFactory.createElement("svg:radialGradient")).setAttributeNS(null,"id",n),t.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),t.setAttributeNS(null,"cx",u[0]),t.setAttributeNS(null,"cy",u[1]),t.setAttributeNS(null,"r",h),t.setAttributeNS(null,"fx",l[0]),t.setAttributeNS(null,"fy",l[1]),t.setAttributeNS(null,"fr",c);break;default:throw new Error("Unknown RadialAxial type: ".concat(e[1]))}var d,f=a(i);try{for(f.s();!(d=f.n()).done;){var p=d.value,g=this.svgFactory.createElement("svg:stop");g.setAttributeNS(null,"offset",p[0]),g.setAttributeNS(null,"stop-color",p[1]),t.appendChild(g)}}catch(y){f.e(y)}finally{f.f()}return this.defs.appendChild(t),"url(#".concat(n,")");case"Mesh":return(0,r.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 n,i=this.current,o=i.x,s=i.y,l=[],u=0,c=a(e);try{for(c.s();!(n=c.n()).done;)switch(0|n.value){case r.OPS.rectangle:o=t[u++],s=t[u++];var h=o+t[u++],d=s+t[u++];l.push("M",p(o),p(s),"L",p(h),p(s),"L",p(h),p(d),"L",p(o),p(d),"Z");break;case r.OPS.moveTo:o=t[u++],s=t[u++],l.push("M",p(o),p(s));break;case r.OPS.lineTo:o=t[u++],s=t[u++],l.push("L",p(o),p(s));break;case r.OPS.curveTo:o=t[u+4],s=t[u+5],l.push("C",p(t[u]),p(t[u+1]),p(t[u+2]),p(t[u+3]),p(o),p(s)),u+=6;break;case r.OPS.curveTo2:l.push("C",p(o),p(s),p(t[u]),p(t[u+1]),p(t[u+2]),p(t[u+3])),o=t[u+2],s=t[u+3],u+=4;break;case r.OPS.curveTo3:o=t[u+2],s=t[u+3],l.push("C",p(t[u]),p(t[u+1]),p(o),p(s),p(o),p(s)),u+=4;break;case r.OPS.closePath:l.push("Z")}}catch(f){c.e(f)}finally{c.f()}l=l.join(" "),i.path&&e.length>0&&e[0]!==r.OPS.rectangle&&e[0]!==r.OPS.moveTo?l=i.path.getAttributeNS(null,"d")+l:(i.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().appendChild(i.path)),i.path.setAttributeNS(null,"d",l),i.path.setAttributeNS(null,"fill","none"),i.element=i.path,i.setCurrentPoint(o,s)}},{key:"endPath",value:function(){var e=this.current;if(e.path=null,this.pendingClip)if(e.element){var t="clippath".concat(A++),n=this.svgFactory.createElement("svg:clipPath");n.setAttributeNS(null,"id",t),n.setAttributeNS(null,"transform",g(this.transformMatrix));var r=e.element.cloneNode(!0);r.setAttributeNS(null,"clip-rule","evenodd"===this.pendingClip?"evenodd":"nonzero"),this.pendingClip=null,n.appendChild(r),this.defs.appendChild(n),e.activeClipUrl&&(e.clipGroup=null,this.extraStack.forEach((function(e){e.clipGroup=null})),n.setAttributeNS(null,"clip-path",e.activeClipUrl)),e.activeClipUrl="url(#".concat(t,")"),this.tgrp=null}else this.pendingClip=null}},{key:"clip",value:function(e){this.pendingClip=e}},{key:"closePath",value:function(){var e=this.current;if(e.path){var t="".concat(e.path.getAttributeNS(null,"d"),"Z");e.path.setAttributeNS(null,"d",t)}}},{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,n=a(e);try{for(n.s();!(t=n.n()).done;){var i=s(t.value,2),o=i[0],l=i[1];switch(o){case"LW":this.setLineWidth(l);break;case"LC":this.setLineCap(l);break;case"LJ":this.setLineJoin(l);break;case"ML":this.setMiterLimit(l);break;case"D":this.setDash(l[0],l[1]);break;case"RI":this.setRenderingIntent(l);break;case"FL":this.setFlatness(l);break;case"Font":this.setFont(l);break;case"CA":this.setStrokeAlpha(l);break;case"ca":this.setFillAlpha(l);break;default:(0,r.warn)("Unimplemented graphic state operator ".concat(o))}}}catch(u){n.e(u)}finally{n.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=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=this.current,r=n.dashArray;1!==t&&r.length>0&&(r=r.map((function(e){return t*e}))),e.setAttributeNS(null,"stroke",n.strokeColor),e.setAttributeNS(null,"stroke-opacity",n.strokeAlpha),e.setAttributeNS(null,"stroke-miterlimit",p(n.miterLimit)),e.setAttributeNS(null,"stroke-linecap",n.lineCap),e.setAttributeNS(null,"stroke-linejoin",n.lineJoin),e.setAttributeNS(null,"stroke-width",p(t*n.lineWidth)+"px"),e.setAttributeNS(null,"stroke-dasharray",r.map(p).join(" ")),e.setAttributeNS(null,"stroke-dashoffset",p(t*n.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=this.objs.get(e);t?this.paintInlineImageXObject(t):(0,r.warn)("Dependent image with object ID ".concat(e," is not ready yet"))}},{key:"paintInlineImageXObject",value:function(e,t){var n=e.width,r=e.height,i=b(e,this.forceDataSchema,!!t),o=this.svgFactory.createElement("svg:rect");o.setAttributeNS(null,"x","0"),o.setAttributeNS(null,"y","0"),o.setAttributeNS(null,"width",p(n)),o.setAttributeNS(null,"height",p(r)),this.current.element=o,this.clip("nonzero");var s=this.svgFactory.createElement("svg:image");s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i),s.setAttributeNS(null,"x","0"),s.setAttributeNS(null,"y",p(-r)),s.setAttributeNS(null,"width",p(n)+"px"),s.setAttributeNS(null,"height",p(r)+"px"),s.setAttributeNS(null,"transform","scale(".concat(p(1/n)," ").concat(p(-1/r),")")),t?t.appendChild(s):this._ensureTransformGroup().appendChild(s)}},{key:"paintImageMaskXObject",value:function(e){var t=this.current,n=e.width,r=e.height,i=t.fillColor;t.maskId="mask".concat(S++);var o=this.svgFactory.createElement("svg:mask");o.setAttributeNS(null,"id",t.maskId);var s=this.svgFactory.createElement("svg:rect");s.setAttributeNS(null,"x","0"),s.setAttributeNS(null,"y","0"),s.setAttributeNS(null,"width",p(n)),s.setAttributeNS(null,"height",p(r)),s.setAttributeNS(null,"fill",i),s.setAttributeNS(null,"mask","url(#".concat(t.maskId,")")),this.defs.appendChild(o),this._ensureTransformGroup().appendChild(s),this.paintInlineImageXObject(e,o)}},{key:"paintFormXObjectBegin",value:function(e,t){if(Array.isArray(e)&&6===e.length&&this.transform(e[0],e[1],e[2],e[3],e[4],e[5]),t){var n=t[2]-t[0],r=t[3]-t[1],i=this.svgFactory.createElement("svg:rect");i.setAttributeNS(null,"x",t[0]),i.setAttributeNS(null,"y",t[1]),i.setAttributeNS(null,"width",p(n)),i.setAttributeNS(null,"height",p(r)),this.current.element=i,this.clip("nonzero"),this.endPath()}}},{key:"paintFormXObjectEnd",value:function(){}},{key:"_initialize",value:function(e){var t=this.svgFactory.create(e.width,e.height),n=this.svgFactory.createElement("svg:defs");t.appendChild(n),this.defs=n;var r=this.svgFactory.createElement("svg:g");return r.setAttributeNS(null,"transform",g(e.transform)),t.appendChild(r),this.svg=r,t}},{key:"_ensureClipGroup",value:function(){if(!this.current.clipGroup){var e=this.svgFactory.createElement("svg:g");e.setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.appendChild(e),this.current.clipGroup=e}return this.current.clipGroup}},{key:"_ensureTransformGroup",value:function(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",g(this.transformMatrix)),this.current.activeClipUrl?this._ensureClipGroup().appendChild(this.tgrp):this.svg.appendChild(this.tgrp)),this.tgrp}}]),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFNodeStream=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5),s=n(213);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 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&&(Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function d(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function f(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){d(o,r,i,s,a,"next",e)}function a(e){d(o,r,i,s,a,"throw",e)}s(void 0)}))}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e}var m=__webpack_require__(2),v=__webpack_require__(3),_=__webpack_require__(4),b=__webpack_require__(5),w=/^file:\/\/\/[a-zA-Z]:\//;t.PDFNodeStream=function(){function e(t){var n,r;p(this,e),this.source=t,this.url="file:"===(r=b.parse(n=t.url)).protocol||r.host?r:/^[a-z]:[/\\]/i.test(n)?b.parse("file:///".concat(n)):(r.host||(r.protocol="file:"),r),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 y(e,[{key:"getFullReader",value:function(){return(0,o.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new P(this):new x(this),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){if(t<=this._progressiveDataLength)return null;var n=this.isFsUrl?new E(this,e,t):new C(this,e,t);return this._rangeRequestReaders.push(n),n}},{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;var n=t.source;this._contentLength=n.length,this._loaded=0,this._filename=null,this._disableRange=n.disableRange||!1,this._rangeChunkSize=n.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),this._isStreamingSupported=!n.disableStream,this._isRangeSupported=!n.disableRange,this._readableStream=null,this._readCapability=(0,o.createPromiseCapability)(),this._headersCapability=(0,o.createPromiseCapability)()}var t;return y(e,[{key:"read",value:(t=f(i.default.mark((function e(){var t,n;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){e.next=4;break}return e.abrupt("return",{value:void 0,done:!0});case 4:if(!this._storedError){e.next=6;break}throw this._storedError;case 6:if(null!==(t=this._readableStream.read())){e.next=10;break}return this._readCapability=(0,o.createPromiseCapability)(),e.abrupt("return",this.read());case 10:return this._loaded+=t.length,this.onProgress&&this.onProgress({loaded:this._loaded,total:this._contentLength}),n=new Uint8Array(t).buffer,e.abrupt("return",{value:n,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,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 o.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,o.createPromiseCapability)(),this._isStreamingSupported=!t.source.disableStream}var t;return y(e,[{key:"read",value:(t=f(i.default.mark((function e(){var t,n;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){e.next=4;break}return e.abrupt("return",{value:void 0,done:!0});case 4:if(!this._storedError){e.next=6;break}throw this._storedError;case 6:if(null!==(t=this._readableStream.read())){e.next=10;break}return this._readCapability=(0,o.createPromiseCapability)(),e.abrupt("return",this.read());case 10:return this._loaded+=t.length,this.onProgress&&this.onProgress({loaded:this._loaded}),n=new Uint8Array(t).buffer,e.abrupt("return",{value:n,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,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(e){l(n,e);var t=u(n);function n(e){var r;p(this,n);var i=function(t){if(404===t.statusCode){var n=new o.MissingPDFException('Missing PDF "'.concat(r._url,'".'));return r._storedError=n,void r._headersCapability.reject(n)}r._headersCapability.resolve(),r._setReadableStream(t);var i=function(e){return r._readableStream.headers[e.toLowerCase()]},a=(0,s.validateRangeRequestCapabilities)({getResponseHeader:i,isHttp:e.isHttp,rangeChunkSize:r._rangeChunkSize,disableRange:r._disableRange}),l=a.suggestedLength;r._isRangeSupported=a.allowRangeRequests,r._contentLength=l||r._contentLength,r._filename=(0,s.extractFilenameFromHeader)(i)};return(r=t.call(this,e))._request=null,r._request="http:"===r._url.protocol?v.request(k(r._url,e.httpHeaders),i):_.request(k(r._url,e.httpHeaders),i),r._request.on("error",(function(e){r._storedError=e,r._headersCapability.reject(e)})),r._request.end(),r}return n}(A),C=function(e){l(n,e);var t=u(n);function n(e,r,i){var s;for(var a in p(this,n),(s=t.call(this,e))._httpHeaders={},e.httpHeaders){var l=e.httpHeaders[a];void 0!==l&&(s._httpHeaders[a]=l)}s._httpHeaders.Range="bytes=".concat(r,"-").concat(i-1);var u=function(e){if(404!==e.statusCode)s._setReadableStream(e);else{var t=new o.MissingPDFException('Missing PDF "'.concat(s._url,'".'));s._storedError=t}};return s._request=null,s._request="http:"===s._url.protocol?v.request(k(s._url,s._httpHeaders),u):_.request(k(s._url,s._httpHeaders),u),s._request.on("error",(function(e){s._storedError=e})),s._request.end(),s}return n}(S),P=function(e){l(n,e);var t=u(n);function n(e){var r;p(this,n),r=t.call(this,e);var i=decodeURIComponent(r._url.path);return w.test(r._url.href)&&(i=i.replace(/^\//,"")),m.lstat(i,(function(e,t){if(e)return"ENOENT"===e.code&&(e=new o.MissingPDFException('Missing PDF "'.concat(i,'".'))),r._storedError=e,void r._headersCapability.reject(e);r._contentLength=t.size,r._setReadableStream(m.createReadStream(i)),r._headersCapability.resolve()})),r}return n}(A),E=function(e){l(n,e);var t=u(n);function n(e,r,i){var o;p(this,n),o=t.call(this,e);var s=decodeURIComponent(o._url.path);return w.test(o._url.href)&&(s=s.replace(/^\//,"")),o._setReadableStream(m.createReadStream(s,{start:r,end:i-1})),o}return n}(S)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createResponseStatusError=function(e,t){return 404===e||0===e&&t.startsWith("file:")?new r.MissingPDFException('Missing PDF "'+t+'".'):new r.UnexpectedResponseException("Unexpected server response ("+e+') while retrieving PDF "'+t+'".',e)},t.extractFilenameFromHeader=function(e){var t=e("Content-Disposition");if(t){var n=(0,i.getFilenameFromContentDispositionHeader)(t);if(n.includes("%"))try{n=decodeURIComponent(n)}catch(r){}if(/\.pdf$/i.test(n))return n}return null},t.validateRangeRequestCapabilities=function(e){var t=e.getResponseHeader,n=e.isHttp,i=e.rangeChunkSize,o=e.disableRange;(0,r.assert)(i>0,"Range chunk size must be larger than zero");var s={allowRangeRequests:!1,suggestedLength:void 0},a=parseInt(t("Content-Length"),10);return Number.isInteger(a)?(s.suggestedLength=a,a<=2*i||o||!n||"bytes"!==t("Accept-Ranges")||"identity"!==(t("Content-Encoding")||"identity")||(s.allowRangeRequests=!0),s):s},t.validateResponseStatus=function(e){return 200===e||206===e};var r=n(5),i=n(214)},function(e,t,n){"use strict";function r(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 n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?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 n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}Object.defineProperty(t,"__esModule",{value:!0}),t.getFilenameFromContentDispositionHeader=function(e){var t=!0,n=s("filename\\*","i").exec(e);if(n){var i=u(n=n[1]);return l(i=h(i=c(i=unescape(i))))}if(n=function(e){for(var t,n=[],i=s("filename\\*((?!0\\d)\\d+)(\\*?)","ig");null!==(t=i.exec(e));){var o=r(t,4),a=o[1],l=o[2],h=o[3];if((a=parseInt(a,10))in n){if(0===a)break}else n[a]=[l,h]}for(var d=[],f=0;f<n.length&&f in n;++f){var p=r(n[f],2),g=p[0],y=p[1];y=u(y),g&&(y=unescape(y),0===f&&(y=c(y))),d.push(y)}return d.join("")}(e))return l(h(n));if(n=s("filename","i").exec(e)){var o=u(n=n[1]);return l(o=h(o))}function s(e,t){return new RegExp("(?:^|;)\\s*"+e+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',t)}function a(e,n){if(e){if(!/^[\x00-\xFF]+$/.test(n))return n;try{var r=new TextDecoder(e,{fatal:!0}),i=Array.from(n,(function(e){return 255&e.charCodeAt(0)}));n=r.decode(new Uint8Array(i)),t=!1}catch(o){if(/^utf-?8$/i.test(e))try{n=decodeURIComponent(escape(n)),t=!1}catch(s){}}}return n}function l(e){return t&&/[\x80-\xff]/.test(e)&&(e=a("utf-8",e),t&&(e=a("iso-8859-1",e))),e}function u(e){if(e.startsWith('"')){for(var t=e.slice(1).split('\\"'),n=0;n<t.length;++n){var r=t[n].indexOf('"');-1!==r&&(t[n]=t[n].slice(0,r),t.length=n+1),t[n]=t[n].replace(/\\(.)/g,"$1")}e=t.join('"')}return e}function c(e){var t=e.indexOf("'");return-1===t?e:a(e.slice(0,t),e.slice(t+1).replace(/^[^']*'/,""))}function h(e){return!e.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(e)?e:e.replace(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,(function(e,t,n,r){if("q"===n||"Q"===n)return a(t,r=(r=r.replace(/_/g," ")).replace(/=([0-9a-fA-F]{2})/g,(function(e,t){return String.fromCharCode(parseInt(t,16))})));try{r=atob(r)}catch(i){}return a(t,r)}))}return""}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFNetworkStream=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5),s=n(213);function a(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){a(o,r,i,s,l,"next",e)}function l(e){a(o,r,i,s,l,"throw",e)}s(void 0)}))}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),e}var d=function(){function e(t,n){u(this,e),this.url=t,n=n||{},this.isHttp=/^https?:/i.test(t),this.httpHeaders=this.isHttp&&n.httpHeaders||{},this.withCredentials=n.withCredentials||!1,this.getXhr=n.getXhr||function(){return new XMLHttpRequest},this.currXhrId=0,this.pendingRequests=Object.create(null)}return h(e,[{key:"requestRange",value:function(e,t,n){var r={begin:e,end:t};for(var i in n)r[i]=n[i];return this.request(r)}},{key:"requestFull",value:function(e){return this.request(e)}},{key:"request",value:function(e){var t=this.getXhr(),n=this.currXhrId++,r=this.pendingRequests[n]={xhr:t};for(var i in t.open("GET",this.url),t.withCredentials=this.withCredentials,this.httpHeaders){var o=this.httpHeaders[i];void 0!==o&&t.setRequestHeader(i,o)}return this.isHttp&&"begin"in e&&"end"in e?(t.setRequestHeader("Range","bytes=".concat(e.begin,"-").concat(e.end-1)),r.expectedStatus=206):r.expectedStatus=200,t.responseType="arraybuffer",e.onError&&(t.onerror=function(n){e.onError(t.status)}),t.onreadystatechange=this.onStateChange.bind(this,n),t.onprogress=this.onProgress.bind(this,n),r.onHeadersReceived=e.onHeadersReceived,r.onDone=e.onDone,r.onError=e.onError,r.onProgress=e.onProgress,t.send(null),n}},{key:"onProgress",value:function(e,t){var n=this.pendingRequests[e];n&&n.onProgress&&n.onProgress(t)}},{key:"onStateChange",value:function(e,t){var n=this.pendingRequests[e];if(n){var r=n.xhr;if(r.readyState>=2&&n.onHeadersReceived&&(n.onHeadersReceived(),delete n.onHeadersReceived),4===r.readyState&&e in this.pendingRequests)if(delete this.pendingRequests[e],0===r.status&&this.isHttp)n.onError&&n.onError(r.status);else{var i=r.status||200;if(200===i&&206===n.expectedStatus||i===n.expectedStatus){var s=function(e){var t=e.response;return"string"!=typeof t?t:(0,o.stringToBytes)(t).buffer}(r);if(206===i){var a=r.getResponseHeader("Content-Range"),l=/bytes (\d+)-(\d+)\/(\d+)/.exec(a);n.onDone({begin:parseInt(l[1],10),chunk:s})}else s?n.onDone({begin:0,chunk:s}):n.onError&&n.onError(r.status)}else n.onError&&n.onError(r.status)}}}},{key:"hasPendingRequests",value:function(){for(var e in this.pendingRequests)return!0;return!1}},{key:"getRequestXhr",value:function(e){return this.pendingRequests[e].xhr}},{key:"isPendingRequest",value:function(e){return e in this.pendingRequests}},{key:"abortAllRequests",value:function(){for(var e in this.pendingRequests)this.abortRequest(0|e)}},{key:"abortRequest",value:function(e){var t=this.pendingRequests[e].xhr;delete this.pendingRequests[e],t.abort()}}]),e}();t.PDFNetworkStream=function(){function e(t){u(this,e),this._source=t,this._manager=new d(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){var t=this._rangeRequestReaders.indexOf(e);t>=0&&this._rangeRequestReaders.splice(t,1)}},{key:"getFullReader",value:function(){return(0,o.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new f(this._manager,this._source),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){var n=new p(this._manager,e,t);return n.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(n),n}},{key:"cancelAllRequests",value:function(e){this._fullRequestReader&&this._fullRequestReader.cancel(e),this._rangeRequestReaders.slice(0).forEach((function(t){t.cancel(e)}))}}]),e}();var f=function(){function e(t,n){u(this,e),this._manager=t;var r={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=n.url,this._fullRequestId=t.requestFull(r),this._headersReceivedCapability=(0,o.createPromiseCapability)(),this._disableRange=n.disableRange||!1,this._contentLength=n.length,this._rangeChunkSize=n.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(){var e=this._fullRequestId,t=this._manager.getRequestXhr(e),n=function(e){return t.getResponseHeader(e)},r=(0,s.validateRangeRequestCapabilities)({getResponseHeader:n,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange}),i=r.suggestedLength;r.allowRangeRequests&&(this._isRangeSupported=!0),this._contentLength=i||this._contentLength,this._filename=(0,s.extractFilenameFromHeader)(n),this._isRangeSupported&&this._manager.abortRequest(e),this._headersReceivedCapability.resolve()}},{key:"_onDone",value:function(e){e&&(this._requests.length>0?this._requests.shift().resolve({value:e.chunk,done:!1}):this._cachedChunks.push(e.chunk)),this._done=!0,this._cachedChunks.length>0||(this._requests.forEach((function(e){e.resolve({value:void 0,done:!0})})),this._requests=[])}},{key:"_onError",value:function(e){var t=(0,s.createResponseStatusError)(e,this._url);this._storedError=t,this._headersReceivedCapability.reject(t),this._requests.forEach((function(e){e.reject(t)})),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=l(i.default.mark((function e(){var t,n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._storedError){e.next=2;break}throw this._storedError;case 2:if(!(this._cachedChunks.length>0)){e.next=5;break}return t=this._cachedChunks.shift(),e.abrupt("return",{value:t,done:!1});case 5:if(!this._done){e.next=7;break}return e.abrupt("return",{value:void 0,done:!0});case 7:return n=(0,o.createPromiseCapability)(),this._requests.push(n),e.abrupt("return",n.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,n,r){u(this,e),this._manager=t;var i={onDone:this._onDone.bind(this),onProgress:this._onProgress.bind(this)};this._requestId=t.requestRange(n,r,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){var t=e.chunk;this._requests.length>0?this._requests.shift().resolve({value:t,done:!1}):this._queuedChunk=t,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=l(i.default.mark((function e(){var t,n;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null===this._queuedChunk){e.next=4;break}return t=this._queuedChunk,this._queuedChunk=null,e.abrupt("return",{value:t,done:!1});case 4:if(!this._done){e.next=6;break}return e.abrupt("return",{value:void 0,done:!0});case 6:return n=(0,o.createPromiseCapability)(),this._requests.push(n),e.abrupt("return",n.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,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFFetchStream=void 0;var r,i=(r=n(2))&&r.__esModule?r:{default:r},o=n(5),s=n(213);function a(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){a(o,r,i,s,l,"next",e)}function l(e){a(o,r,i,s,l,"throw",e)}s(void 0)}))}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),e}function d(e,t,n){return{method:"GET",headers:e,signal:n&&n.signal,mode:"cors",credentials:t?"include":"same-origin",redirect:"follow"}}function f(e){var t=new Headers;for(var n in e){var r=e[n];void 0!==r&&t.append(n,r)}return t}t.PDFFetchStream=function(){function e(t){u(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,o.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new p(this),this._fullRequestReader}},{key:"getRangeReader",value:function(e,t){if(t<=this._progressiveDataLength)return null;var n=new g(this,e,t);return this._rangeRequestReaders.push(n),n}},{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 n=this;u(this,e),this._stream=t,this._reader=null,this._loaded=0,this._filename=null;var r=t.source;this._withCredentials=r.withCredentials||!1,this._contentLength=r.length,this._headersCapability=(0,o.createPromiseCapability)(),this._disableRange=r.disableRange||!1,this._rangeChunkSize=r.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._isStreamingSupported=!r.disableStream,this._isRangeSupported=!r.disableRange,this._headers=f(this._stream.httpHeaders);var i=r.url;fetch(i,d(this._headers,this._withCredentials,this._abortController)).then((function(e){if(!(0,s.validateResponseStatus)(e.status))throw(0,s.createResponseStatusError)(e.status,i);n._reader=e.body.getReader(),n._headersCapability.resolve();var t=function(t){return e.headers.get(t)},r=(0,s.validateRangeRequestCapabilities)({getResponseHeader:t,isHttp:n._stream.isHttp,rangeChunkSize:n._rangeChunkSize,disableRange:n._disableRange}),a=r.suggestedLength;n._isRangeSupported=r.allowRangeRequests,n._contentLength=a||n._contentLength,n._filename=(0,s.extractFilenameFromHeader)(t),!n._isStreamingSupported&&n._isRangeSupported&&n.cancel(new o.AbortException("Streaming is disabled."))})).catch(this._headersCapability.reject),this.onProgress=null}var t;return h(e,[{key:"read",value:(t=l(i.default.mark((function e(){var t,n,r,o;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(n=(t=e.sent).value,!(r=t.done)){e.next=9;break}return e.abrupt("return",{value:n,done:r});case 9:return this._loaded+=n.byteLength,this.onProgress&&this.onProgress({loaded:this._loaded,total:this._contentLength}),o=new Uint8Array(n).buffer,e.abrupt("return",{value:o,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}(),g=function(){function e(t,n,r){var i=this;u(this,e),this._stream=t,this._reader=null,this._loaded=0;var a=t.source;this._withCredentials=a.withCredentials||!1,this._readCapability=(0,o.createPromiseCapability)(),this._isStreamingSupported=!a.disableStream,"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._headers=f(this._stream.httpHeaders),this._headers.append("Range","bytes=".concat(n,"-").concat(r-1));var l=a.url;fetch(l,d(this._headers,this._withCredentials,this._abortController)).then((function(e){if(!(0,s.validateResponseStatus)(e.status))throw(0,s.createResponseStatusError)(e.status,l);i._readCapability.resolve(),i._reader=e.body.getReader()})),this.onProgress=null}var t;return h(e,[{key:"read",value:(t=l(i.default.mark((function e(){var t,n,r,o;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(n=(t=e.sent).value,!(r=t.done)){e.next=9;break}return e.abrupt("return",{value:n,done:r});case 9:return this._loaded+=n.byteLength,this.onProgress&&this.onProgress({loaded:this._loaded}),o=new Uint8Array(n).buffer,e.abrupt("return",{value:o,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}()}])},module.exports=factory()},Voib:function(e,t,n){var r;r=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,(function(t){return e[t]}).bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AnnotationLayerBuilder",{enumerable:!0,get:function(){return r.AnnotationLayerBuilder}}),Object.defineProperty(t,"DefaultAnnotationLayerFactory",{enumerable:!0,get:function(){return r.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 o.EventBus}}),Object.defineProperty(t,"NullL10n",{enumerable:!0,get:function(){return o.NullL10n}}),Object.defineProperty(t,"ProgressBar",{enumerable:!0,get:function(){return o.ProgressBar}}),Object.defineProperty(t,"PDFLinkService",{enumerable:!0,get:function(){return s.PDFLinkService}}),Object.defineProperty(t,"SimpleLinkService",{enumerable:!0,get:function(){return s.SimpleLinkService}}),Object.defineProperty(t,"DownloadManager",{enumerable:!0,get:function(){return a.DownloadManager}}),Object.defineProperty(t,"GenericL10n",{enumerable:!0,get:function(){return l.GenericL10n}}),Object.defineProperty(t,"PDFFindController",{enumerable:!0,get:function(){return u.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 d.PDFSinglePageViewer}}),Object.defineProperty(t,"PDFViewer",{enumerable:!0,get:function(){return f.PDFViewer}});var r=n(1),i=n(8),o=n(3),s=n(7),a=n(9),l=n(11),u=n(13),c=n(15),h=n(16),d=n(18),f=n(20)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultAnnotationLayerFactory=t.AnnotationLayerBuilder=void 0;var r=n(2),i=n(3),o=n(7);function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return t&&a(e.prototype,t),n&&a(e,n),e}var u=function(){function e(t){var n=t.pageDiv,r=t.pdfPage,o=t.linkService,a=t.downloadManager,l=t.imageResourcesPath,u=void 0===l?"":l,c=t.renderInteractiveForms,h=void 0!==c&&c,d=t.l10n,f=void 0===d?i.NullL10n:d;s(this,e),this.pageDiv=n,this.pdfPage=r,this.linkService=o,this.downloadManager=a,this.imageResourcesPath=u,this.renderInteractiveForms=h,this.l10n=f,this.div=null,this._cancelled=!1}return l(e,[{key:"render",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"display";this.pdfPage.getAnnotations({intent:n}).then((function(n){if(!t._cancelled){var i={viewport:e.clone({dontFlip:!0}),div:t.div,annotations:n,page:t.pdfPage,imageResourcesPath:t.imageResourcesPath,renderInteractiveForms:t.renderInteractiveForms,linkService:t.linkService,downloadManager:t.downloadManager};if(t.div)r.AnnotationLayer.update(i);else{if(0===n.length)return;t.div=document.createElement("div"),t.div.className="annotationLayer",t.pageDiv.appendChild(t.div),i.div=t.div,r.AnnotationLayer.render(i),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=u,t.DefaultAnnotationLayerFactory=function(){function e(){s(this,e)}return l(e,[{key:"createAnnotationLayerBuilder",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:i.NullL10n;return new u({pageDiv:e,pdfPage:t,imageResourcesPath:n,renderInteractiveForms:r,linkService:new o.SimpleLinkService,l10n:s})}}]),e}()},function(e,t,r){"use strict";var i;i="undefined"!=typeof window&&window["pdfjs-dist/build/pdf"]?window["pdfjs-dist/build/pdf"]:n("LFh5"),e.exports=i},function(e,t,n){"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(h).includes(e)&&e!==h.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=b,t.getPDFFileNameFromURL=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"document.pdf";if("string"!=typeof e)return t;if(y(e))return console.warn('getPDFFileNameFromURL: ignoring "data:" URL for performance reasons.'),t;var n=/^(?:(?:[^:]+:)?\/\/[^\/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/,r=/[^\/?#=]+\.pdf\b(?!.*\.pdf\b)/i,i=n.exec(e),o=r.exec(i[1])||r.exec(i[2])||r.exec(i[3]);if(o&&(o=o[0]).includes("%"))try{o=r.exec(decodeURIComponent(o))[0]}catch(s){}return o||t},t.noContextMenuHandler=function(e){e.preventDefault()},t.parseQueryString=function(e){for(var t=e.split("&"),n=Object.create(null),r=0,i=t.length;r<i;++r){var o=t[r].split("="),s=o[0].toLowerCase(),a=o.length>1?o[1]:null;n[decodeURIComponent(s)]=decodeURIComponent(a)}return n},t.backtrackBeforeAllVisibleElements=g,t.getVisibleElements=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=e.scrollTop,o=i+e.clientHeight,s=e.scrollLeft,a=s+e.clientWidth;function l(e){var t=e.div;return t.offsetTop+t.clientTop+t.clientHeight>i}function u(e){var t=e.div;return t.offsetLeft+t.clientLeft+t.clientWidth>s}var c=[],h=t.length,d=0===h?0:p(t,r?u:l);d>0&&d<h&&!r&&(d=g(d,t,i));for(var f=r?a:-1,y=d;y<h;y++){var m=t[y],v=m.div,_=v.offsetLeft+v.clientLeft,b=v.offsetTop+v.clientTop,w=v.clientWidth,A=v.clientHeight,S=_+w,k=b+A;if(-1===f)k>=o&&(f=k);else if((r?_:b)>f)break;if(!(k<=i||b>=o||S<=s||_>=a)){var x=Math.max(0,i-b)+Math.max(0,k-o),C=Math.max(0,s-_)+Math.max(0,S-a),P=(A-x)*(w-C)*100/A/w|0;c.push({id:m.id,x:_,y:b,view:m,percent:P})}}var E=c[0],T=c[c.length-1];return n&&c.sort((function(e,t){var n=e.percent-t.percent;return Math.abs(n)>.001?-n:e.id-t.id})),{first:E,last:T,views:c}},t.roundToDivide=function(e,t){var n=e%t;return 0===n?e:Math.round(e-n+t)},t.getPageSizeInches=function(e){var t,n=e.userUnit,r=e.rotate,i=function(e){if(Array.isArray(e))return e}(t=e.view)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),4!==n.length);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(t)||function(e,t){if(e){if("string"==typeof e)return l(e,4);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(e,4):void 0}}(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.")}(),o=r%180!=0,s=(i[2]-i[0])/72*n,a=(i[3]-i[1])/72*n;return{width:o?a:s,height:o?s:a}},t.approximateFraction=function(e){if(Math.floor(e)===e)return[e,1];var t=1/e;if(t>8)return[1,8];if(Math.floor(t)===t)return[1,t];for(var n=e>1?t:e,r=0,i=1,o=1,s=1;;){var a=r+o,l=i+s;if(l>8)break;n<=a/l?(o=a,s=l):(r=a,i=l)}return n-r/i<o/s-n?n===e?[r,i]:[i,r]:n===e?[o,s]:[s,o]},t.getOutputScale=function(e){var t=(window.devicePixelRatio||1)/(e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1);return{sx:t,sy:t,scaled:1!==t}},t.scrollIntoView=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=e.offsetParent;if(r){for(var i=e.offsetTop+e.clientTop,o=e.offsetLeft+e.clientLeft;r.clientHeight===r.scrollHeight&&r.clientWidth===r.scrollWidth||n&&"hidden"===getComputedStyle(r).overflow;)if(r.dataset._scaleY&&(i/=r.dataset._scaleY,o/=r.dataset._scaleX),i+=r.offsetTop,o+=r.offsetLeft,!(r=r.offsetParent))return;t&&(void 0!==t.top&&(i+=t.top),void 0!==t.left&&(r.scrollLeft=o+=t.left)),r.scrollTop=i}else console.error("offsetParent is not set -- cannot scroll")},t.watchScroll=function(e,t){var n=function(n){i||(i=window.requestAnimationFrame((function(){i=null;var n=e.scrollLeft,o=r.lastX;n!==o&&(r.right=n>o),r.lastX=n;var s=e.scrollTop,a=r.lastY;s!==a&&(r.down=s>a),r.lastY=s,t(r)})))},r={right:!0,down:!0,lastX:e.scrollLeft,lastY:e.scrollTop,_eventHandler:n},i=null;return e.addEventListener("scroll",n,!0),r},t.binarySearchFirstItem=p,t.normalizeWheelEventDelta=function(e){var t=Math.sqrt(e.deltaX*e.deltaX+e.deltaY*e.deltaY),n=Math.atan2(e.deltaY,e.deltaX);return-.25*Math.PI<n&&n<.75*Math.PI&&(t=-t),0===e.deltaMode?t/=900:1===e.deltaMode&&(t/=30),t},t.waitOnEventOrTimeout=function(e){var t=e.target,n=e.name,r=e.delay,i=void 0===r?0:r;return new Promise((function(e,r){if("object"!==function(e){return("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)||!n||"string"!=typeof n||!(Number.isInteger(i)&&i>=0))throw new Error("waitOnEventOrTimeout - invalid parameters.");function o(r){t instanceof _?t._off(n,s):t.removeEventListener(n,s),l&&clearTimeout(l),e(r)}var s=o.bind(null,m.EVENT);t instanceof _?t._on(n,s):t.addEventListener(n,s);var a=o.bind(null,m.TIMEOUT),l=setTimeout(a,i)}))},t.moveToEndOfArray=function(e,t){for(var n=[],r=e.length,i=0,o=0;o<r;++o)t(e[o])?n.push(e[o]):(e[i]=e[o],++i);for(var s=0;i<r;++s,++i)e[i]=n[s]},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 r,i=(r=n(4))&&r.__esModule?r:{default:r};function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,n){return t&&s(e.prototype,t),n&&s(e,n),e}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function u(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function c(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function s(e){u(o,r,i,s,a,"next",e)}function a(e){u(o,r,i,s,a,"throw",e)}s(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 h={UNKNOWN:-1,VERTICAL:0,HORIZONTAL:1,WRAPPED:2};t.ScrollMode=h;var d={UNKNOWN:-1,NONE:0,ODD:1,EVEN:2};function f(e,t){return t?e.replace(/\{\{\s*(\w+)\s*\}\}/g,(function(e,n){return n in t?t[n]:"{{"+n+"}}"})):e}function p(e,t){var n=0,r=e.length-1;if(r<0||!t(e[r]))return e.length;if(t(e[n]))return n;for(;n<r;){var i=n+r>>1;t(e[i])?r=i:n=i+1}return n}function g(e,t,n){if(e<2)return e;var r=t[e].div,i=r.offsetTop+r.clientTop;i>=n&&(i=(r=t[e-1].div).offsetTop+r.clientTop);for(var o=e-2;o>=0&&!((r=t[o].div).offsetTop+r.clientTop+r.clientHeight<=i);--o)e=o;return e}function y(e){for(var t=0,n=e.length;t<n&&""===e[t].trim();)t++;return"data:"===e.substring(t,t+5).toLowerCase()}t.SpreadMode=d,t.AutoPrintRegExp=/\bprint\s*\(/,t.NullL10n={getLanguage:function(){return c(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 c(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,n){return c(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",f(n,t));case 1:case"end":return e.stop()}}),e)})))()},translate:function(e){return c(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 m={EVENT:"event",TIMEOUT:"timeout"};t.WaitOnType=m;var v=new Promise((function(e){window.requestAnimationFrame(e)}));t.animationStarted=v;var _=function(){function e(t){o(this,e),this._listeners=Object.create(null)}return a(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=this._listeners[e];if(t&&0!==t.length){var n,r=Array.prototype.slice.call(arguments,1);t.slice(0).forEach((function(e){var t=e.listener;if(e.external)return n||(n=[]),void n.push(t);t.apply(null,r)})),n&&(n.forEach((function(e){e.apply(null,r)})),n=null)}}},{key:"_on",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=this._listeners[e];r||(this._listeners[e]=r=[]),r.push({listener:t,external:!0===(n&&n.external)})}},{key:"_off",value:function(e,t){var n=this._listeners[e];if(n)for(var r=0,i=n.length;r<i;r++)if(n[r].listener===t)return void n.splice(r,1)}}]),e}();function b(e,t,n){return Math.min(Math.max(e,t),n)}t.EventBus=_,t.ProgressBar=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.height,i=n.width,s=n.units;o(this,e),this.visible=!0,this.div=document.querySelector(t+" .progress"),this.bar=this.div.parentNode,this.height=r||100,this.width=i||100,this.units=s||"%",this.div.style.height=this.height+this.units,this.percent=0}return a(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"),this.div.style.width=this.width*this._percent/100+this.units}},{key:"setWidth",value:function(e){if(e){var t=e.parentNode.offsetWidth-e.offsetWidth;t>0&&(this.bar.style.width="calc(100% - ".concat(t,"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=b(e,0,100),this._updateBar()}}]),e}()},function(e,t,n){"use strict";e.exports=n(5)},function(e,t,n){"use strict";(function(e){function t(e){return(t="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 n=function(e){var n,r=Object.prototype,i=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",l=o.toStringTag||"@@toStringTag";function u(e,t,n,r){var i=Object.create((t&&t.prototype instanceof y?t:y).prototype),o=new E(r||[]);return i._invoke=function(e,t,n){var r=h;return function(i,o){if(r===f)throw new Error("Generator is already running");if(r===p){if("throw"===i)throw o;return R()}for(n.method=i,n.arg=o;;){var s=n.delegate;if(s){var a=x(s,n);if(a){if(a===g)continue;return a}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===h)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=f;var l=c(e,t,n);if("normal"===l.type){if(r=n.done?p:d,l.arg===g)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(r=p,n.method="throw",n.arg=l.arg)}}}(e,n,o),i}function c(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(r){return{type:"throw",arg:r}}}e.wrap=u;var h="suspendedStart",d="suspendedYield",f="executing",p="completed",g={};function y(){}function m(){}function v(){}var _={};_[s]=function(){return this};var b=Object.getPrototypeOf,w=b&&b(b(T([])));w&&w!==r&&i.call(w,s)&&(_=w);var A=v.prototype=y.prototype=Object.create(_);function S(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function k(e,n){var r;this._invoke=function(o,s){function a(){return new n((function(r,a){!function r(o,s,a,l){var u=c(e[o],e,s);if("throw"!==u.type){var h=u.arg,d=h.value;return d&&"object"===t(d)&&i.call(d,"__await")?n.resolve(d.__await).then((function(e){r("next",e,a,l)}),(function(e){r("throw",e,a,l)})):n.resolve(d).then((function(e){h.value=e,a(h)}),(function(e){return r("throw",e,a,l)}))}l(u.arg)}(o,s,r,a)}))}return r=r?r.then(a,a):a()}}function x(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,x(e,t),"throw"===t.method))return g;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var i=c(r,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,g;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,g):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,g)}function C(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 P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function T(e){if(e){var t=e[s];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(i.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=n,t.done=!0,t};return o.next=o}}return{next:R}}function R(){return{value:n,done:!0}}return m.prototype=A.constructor=v,v.constructor=m,v[l]=m.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===m||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,l in e||(e[l]="GeneratorFunction")),e.prototype=Object.create(A),e},e.awrap=function(e){return{__await:e}},S(k.prototype),k.prototype[a]=function(){return this},e.AsyncIterator=k,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var s=new k(u(t,n,r,i),o);return e.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},S(A),A[l]="Generator",A[s]=function(){return this},A.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=T,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(P),!e)for(var t in this)"t"===t.charAt(0)&&i.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=n)},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 t=this;function r(r,i){return a.type="throw",a.arg=e,t.next=r,i&&(t.method="next",t.arg=n),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],a=s.completion;if("root"===s.tryLoc)return r("end");if(s.tryLoc<=this.prev){var l=i.call(s,"catchLoc"),u=i.call(s,"finallyLoc");if(l&&u){if(this.prev<s.catchLoc)return r(s.catchLoc,!0);if(this.prev<s.finallyLoc)return r(s.finallyLoc)}else if(l){if(this.prev<s.catchLoc)return r(s.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return r(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=e,s.arg=t,o?(this.method="next",this.next=o.finallyLoc,g):this.complete(s)},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;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;P(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:T(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),g}},e}("object"===t(e)?e.exports:{});try{regeneratorRuntime=n}catch(r){Function("r","regeneratorRuntime = r")(n)}}).call(this,n(6)(e))},function(e,t,n){"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,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleLinkService=t.PDFLinkService=void 0;var r=n(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 o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,n){return t&&s(e.prototype,t),n&&s(e,n),e}t.PDFLinkService=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.eventBus,r=t.externalLinkTarget,i=void 0===r?null:r,s=t.externalLinkRel,a=void 0===s?null:s,l=t.externalLinkEnabled,u=void 0===l||l,c=t.ignoreDestinationZoom,h=void 0!==c&&c;o(this,e),this.eventBus=n,this.externalLinkTarget=i,this.externalLinkRel=a,this.externalLinkEnabled=u,this._ignoreDestinationZoom=h,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null,this._pagesRefCache=null}return a(e,[{key:"setDocument",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.baseUrl=t,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){var t=this;new Promise((function(n,r){"string"!=typeof e?n({namedDest:"",explicitDest:e}):t.pdfDocument.getDestination(e).then((function(t){n({namedDest:e,explicitDest:t})}))})).then((function(n){Array.isArray(n.explicitDest)?function n(r){var i,o=r.namedDest,s=r.explicitDest,a=s[0];if(a instanceof Object){if(null===(i=t._cachedPageNumber(a)))return void t.pdfDocument.getPageIndex(a).then((function(e){t.cachePageRef(e+1,a),n({namedDest:o,explicitDest:s})})).catch((function(){console.error('PDFLinkService.navigateTo: "'.concat(a,'" is not ')+'a valid page reference, for dest="'.concat(e,'".'))}))}else{if(!Number.isInteger(a))return void console.error('PDFLinkService.navigateTo: "'.concat(a,'" is not ')+'a valid destination reference, for dest="'.concat(e,'".'));i=a+1}!i||i<1||i>t.pagesCount?console.error('PDFLinkService.navigateTo: "'.concat(i,'" is not ')+'a valid page number, for dest="'.concat(e,'".')):(t.pdfHistory&&(t.pdfHistory.pushCurrentPosition(),t.pdfHistory.push({namedDest:o,explicitDest:s,pageNumber:i})),t.pdfViewer.scrollPageIntoView({pageNumber:i,destArray:s,ignoreDestinationZoom:t._ignoreDestinationZoom}))}(n):console.error('PDFLinkService.navigateTo: "'.concat(n.explicitDest,'" is')+' not a valid destination array, for dest="'.concat(e,'".'))}))}},{key:"getDestinationHash",value:function(e){if("string"==typeof e)return this.getAnchorUrl("#"+escape(e));if(Array.isArray(e)){var t=JSON.stringify(e);return this.getAnchorUrl("#"+escape(t))}return this.getAnchorUrl("")}},{key:"getAnchorUrl",value:function(e){return(this.baseUrl||"")+e}},{key:"setHash",value:function(e){var t,n;if(e.includes("=")){var o=(0,r.parseQueryString)(e);if("search"in o&&this.eventBus.dispatch("findfromurlhash",{source:this,query:o.search.replace(/"/g,""),phraseSearch:"true"===o.phrase}),"page"in o&&(t=0|o.page||1),"zoom"in o){var s=o.zoom.split(","),a=s[0],l=parseFloat(a);a.includes("Fit")?"Fit"===a||"FitB"===a?n=[null,{name:a}]:"FitH"===a||"FitBH"===a||"FitV"===a||"FitBV"===a?n=[null,{name:a},s.length>1?0|s[1]:null]:"FitR"===a?5!==s.length?console.error('PDFLinkService.setHash: Not enough parameters for "FitR".'):n=[null,{name:a},0|s[1],0|s[2],0|s[3],0|s[4]]:console.error('PDFLinkService.setHash: "'.concat(a,'" is not ')+"a valid zoom value."):n=[null,{name:"XYZ"},s.length>1?0|s[1]:null,s.length>2?0|s[2]:null,l?l/100:a]}n?this.pdfViewer.scrollPageIntoView({pageNumber:t||this.page,destArray:n,allowNegativeOffset:!0}):t&&(this.page=t),"pagemode"in o&&this.eventBus.dispatch("pagemode",{source:this,mode:o.pagemode}),"nameddest"in o&&this.navigateTo(o.nameddest)}else{n=unescape(e);try{n=JSON.parse(n),Array.isArray(n)||(n=n.toString())}catch(u){}if("string"==typeof n||function(e){if(!Array.isArray(e))return!1;var t=e.length;if(t<2)return!1;var n=e[0];if(!("object"===i(n)&&Number.isInteger(n.num)&&Number.isInteger(n.gen)||Number.isInteger(n)&&n>=0))return!1;var r=e[1];if("object"!==i(r)||"string"!=typeof r.name)return!1;var o=!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;o=!1;break;default:return!1}for(var s=2;s<t;s++){var a=e[s];if(!("number"==typeof a||o&&null===a))return!1}return!0}(n))return void this.navigateTo(n);console.error('PDFLinkService.setHash: "'.concat(unescape(e),'" is not ')+"a valid destination.")}}},{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":this.page>1&&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){if(t){var n=0===t.gen?"".concat(t.num,"R"):"".concat(t.num,"R").concat(t.gen);this._pagesRefCache[n]=e}}},{key:"_cachedPageNumber",value:function(e){var t=0===e.gen?"".concat(e.num,"R"):"".concat(e.num,"R").concat(e.gen);return this._pagesRefCache&&this._pagesRefCache[t]||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(){o(this,e),this.externalLinkTarget=null,this.externalLinkRel=null,this.externalLinkEnabled=!0,this._ignoreDestinationZoom=!1}return a(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,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultTextLayerFactory=t.TextLayerBuilder=void 0;var r=n(2);function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function s(e,t,n){return t&&o(e.prototype,t),n&&o(e,n),e}var a=function(){function e(t){var n=t.textLayerDiv,r=t.eventBus,o=t.pageIndex,s=t.viewport,a=t.findController,l=void 0===a?null:a,u=t.enhanceTextSelection,c=void 0!==u&&u;i(this,e),this.textLayerDiv=n,this.eventBus=r,this.textContent=null,this.textContentItemsStr=[],this.textContentStream=null,this.renderingDone=!1,this.pageIdx=o,this.pageNumber=this.pageIdx+1,this.matches=[],this.viewport=s,this.textDivs=[],this.findController=l,this.textLayerRenderTask=null,this.enhanceTextSelection=c,this._onUpdateTextLayerMatches=null,this._bindMouse()}return s(e,[{key:"_finishRendering",value:function(){if(this.renderingDone=!0,!this.enhanceTextSelection){var e=document.createElement("div");e.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=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if((this.textContent||this.textContentStream)&&!this.renderingDone){this.cancel(),this.textDivs=[];var n=document.createDocumentFragment();this.textLayerRenderTask=(0,r.renderTextLayer)({textContent:this.textContent,textContentStream:this.textContentStream,container:n,viewport:this.viewport,textDivs:this.textDivs,textContentItemsStr:this.textContentItemsStr,timeout:t,enhanceTextSelection:this.enhanceTextSelection}),this.textLayerRenderTask.promise.then((function(){e.textLayerDiv.appendChild(n),e._finishRendering(),e._updateMatches()}),(function(e){})),this._onUpdateTextLayerMatches||(this._onUpdateTextLayerMatches=function(t){t.pageIndex!==e.pageIdx&&-1!==t.pageIndex||e._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 n=this.textContentItemsStr,r=0,i=0,o=n.length-1,s=this.findController.state.query.length,a=[],l=0,u=e.length;l<u;l++){for(var c=e[l];r!==o&&c>=i+n[r].length;)i+=n[r].length,r++;r===n.length&&console.error("Could not find a matching mapping");var h={begin:{divIdx:r,offset:c-i}};for(c+=t?t[l]:s;r!==o&&c>i+n[r].length;)i+=n[r].length,r++;h.end={divIdx:r,offset:c-i},a.push(h)}return a}},{key:"_renderMatches",value:function(e){if(0!==e.length){var t=this.findController,n=this.pageIdx,r=this.textContentItemsStr,i=this.textDivs,o=n===t.selected.pageIdx,s=t.selected.matchIdx,a=null,l={divIdx:-1,offset:void 0},u=s,c=u+1;if(t.state.highlightAll)u=0,c=e.length;else if(!o)return;for(var h=u;h<c;h++){var d=e[h],f=d.begin,p=d.end,g=o&&h===s,y=g?" selected":"";if(g&&t.scrollMatchIntoView({element:i[f.divIdx],pageIndex:n,matchIndex:s}),a&&f.divIdx===a.divIdx?b(a.divIdx,a.offset,f.offset):(null!==a&&b(a.divIdx,a.offset,l.offset),_(f)),f.divIdx===p.divIdx)b(f.divIdx,f.offset,p.offset,"highlight"+y);else{b(f.divIdx,f.offset,l.offset,"highlight begin"+y);for(var m=f.divIdx+1,v=p.divIdx;m<v;m++)i[m].className="highlight middle"+y;_(p,"highlight end"+y)}a=p}a&&b(a.divIdx,a.offset,l.offset)}function _(e,t){var n=e.divIdx;i[n].textContent="",b(n,0,e.offset,t)}function b(e,t,n,o){var s=i[e],a=r[e].substring(t,n),l=document.createTextNode(a);if(o){var u=document.createElement("span");return u.className=o,u.appendChild(l),void s.appendChild(u)}s.appendChild(l)}}},{key:"_updateMatches",value:function(){if(this.renderingDone){for(var e=this.findController,t=this.matches,n=this.pageIdx,r=this.textContentItemsStr,i=this.textDivs,o=-1,s=0,a=t.length;s<a;s++){for(var l=t[s],u=Math.max(o,l.begin.divIdx),c=l.end.divIdx;u<=c;u++){var h=i[u];h.textContent=r[u],h.className=""}o=l.end.divIdx+1}e&&e.highlightMatches&&(this.matches=this._convertMatches(e.pageMatches[n]||null,e.pageMatchesLength[n]||null),this._renderMatches(this.matches))}}},{key:"_bindMouse",value:function(){var e=this,t=this.textLayerDiv,n=null;t.addEventListener("mousedown",(function(r){if(e.enhanceTextSelection&&e.textLayerRenderTask)return e.textLayerRenderTask.expandTextDivs(!0),void(n&&(clearTimeout(n),n=null));var i=t.querySelector(".endOfContent");if(i){var o=r.target!==t;if(o=o&&"none"!==window.getComputedStyle(i).getPropertyValue("-moz-user-select")){var s=t.getBoundingClientRect(),a=Math.max(0,(r.pageY-s.top)/s.height);i.style.top=(100*a).toFixed(2)+"%"}i.classList.add("active")}})),t.addEventListener("mouseup",(function(){if(e.enhanceTextSelection&&e.textLayerRenderTask)n=setTimeout((function(){e.textLayerRenderTask&&e.textLayerRenderTask.expandTextDivs(!1),n=null}),300);else{var r=t.querySelector(".endOfContent");r&&(r.style.top="",r.classList.remove("active"))}}))}}]),e}();t.TextLayerBuilder=a,t.DefaultTextLayerFactory=function(){function e(){i(this,e)}return s(e,[{key:"createTextLayerBuilder",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4?arguments[4]:void 0;return new a({textLayerDiv:e,pageIndex:t,viewport:n,enhanceTextSelection:r,eventBus:i})}}]),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DownloadManager=void 0;var r=n(2);var i=n(10).viewerCompatibilityParams.disableCreateObjectURL||!1;function o(e,t){var n=document.createElement("a");if(!n.click)throw new Error('DownloadManager: "a.click()" is not supported.');n.href=e,n.target="_parent","download"in n&&(n.download=t),(document.body||document.documentElement).appendChild(n),n.click(),n.remove()}t.DownloadManager=function(){function e(t){var n=t.disableCreateObjectURL,r=void 0===n?i:n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.disableCreateObjectURL=r}var t;return(t=[{key:"downloadUrl",value:function(e,t){(0,r.createValidAbsoluteUrl)(e,"http://example.com")&&o(e+"#pdfjs.action=download",t)}},{key:"downloadData",value:function(e,t,n){navigator.msSaveBlob?navigator.msSaveBlob(new Blob([e],{type:n}),t):o((0,r.createObjectURL)(e,n,this.disableCreateObjectURL),t)}},{key:"download",value:function(e,t,n){navigator.msSaveBlob?navigator.msSaveBlob(e,n)||this.downloadUrl(t,n):this.disableCreateObjectURL?this.downloadUrl(t,n):o(URL.createObjectURL(e),n)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.viewerCompatibilityParams=void 0;var r=Object.create(null),i="undefined"!=typeof navigator&&navigator.userAgent||"",o="undefined"!=typeof navigator&&navigator.platform||"",s="undefined"!=typeof navigator&&navigator.maxTouchPoints||1,a=/Android/.test(i),l=/Trident/.test(i),u=/\b(iPad|iPhone|iPod)(?=;)/.test(i)||"MacIntel"===o&&s>1,c=/CriOS/.test(i);(l||c)&&(r.disableCreateObjectURL=!0),(u||a)&&(r.maxCanvasPixels=5242880);var h=Object.freeze(r);t.viewerCompatibilityParams=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GenericL10n=void 0;var r,i=(r=n(4))&&r.__esModule?r:{default:r};function o(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}function s(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var s=e.apply(t,n);function a(e){o(s,r,i,a,l,"next",e)}function l(e){o(s,r,i,a,l,"throw",e)}a(void 0)}))}}n(12);var a=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,n){a.setLanguage(t,(function(){e(a)}))}))}var t,n,r,o,l,u;return t=e,(n=[{key:"getLanguage",value:(u=s(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return e.abrupt("return",e.sent.getLanguage());case 4:case"end":return e.stop()}}),e,this)}))),function(){return u.apply(this,arguments)})},{key:"getDirection",value:(l=s(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return e.abrupt("return",e.sent.getDirection());case 4:case"end":return e.stop()}}),e,this)}))),function(){return l.apply(this,arguments)})},{key:"get",value:(o=s(i.default.mark((function e(t,n,r){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return e.abrupt("return",e.sent.get(t,n,r));case 4:case"end":return e.stop()}}),e,this)}))),function(e,t,n){return o.apply(this,arguments)})},{key:"translate",value:(r=s(i.default.mark((function e(t){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready;case 2:return e.abrupt("return",e.sent.translate(t));case 4:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(t.prototype,n),e}()},function(e,t,n){"use strict";document.webL10n=function(e,t,n){var r={},i="",o="textContent",s="",a={},l="loading";function u(e,t,n){t=t||function(e){},n=n||function(){};var r=new XMLHttpRequest;r.open("GET",e,!0),r.overrideMimeType&&r.overrideMimeType("text/plain; charset=utf-8"),r.onreadystatechange=function(){4==r.readyState&&(200==r.status||0===r.status?t(r.responseText):n())},r.onerror=n,r.ontimeout=n;try{r.send(null)}catch(i){n()}}function c(e,t,n){var i=r[e];if(!i){if(console.warn("#"+e+" is undefined."),!n)return null;i=n}var o={};for(var s in i){var a=i[s];a=d(a=h(a,t,e,s),t,e),o[s]=a}return o}function h(e,t,n,i){var o=/\{\[\s*([a-zA-Z]+)\(([a-zA-Z]+)\)\s*\]\}/.exec(e);if(!o||!o.length)return e;var s,l=o[1],u=o[2];return t&&u in t?s=t[u]:u in r&&(s=r[u]),l in a&&(e=(0,a[l])(e,s,n,i)),e}function d(e,t,n){return e.replace(/\{\{\s*(.+?)\s*\}\}/g,(function(e,i){return t&&i in t?t[i]:i in r?r[i]:(console.log("argument {{"+i+"}} for #"+n+" is undefined."),e)}))}function f(e){var n=function(e){if(!e)return{};var t=e.getAttribute("data-l10n-id"),n=e.getAttribute("data-l10n-args"),r={};if(n)try{r=JSON.parse(n)}catch(i){console.warn("could not parse arguments for #"+t)}return{id:t,args:r}}(e);if(n.id){var r=c(n.id,n.args);if(r){if(r[o]){if(0===function(e){if(e.children)return e.children.length;if(void 0!==e.childElementCount)return e.childElementCount;for(var t=0,n=0;n<e.childNodes.length;n++)t+=1===e.nodeType?1:0;return t}(e))e[o]=r[o];else{for(var i=e.childNodes,s=!1,a=0,l=i.length;a<l;a++)3===i[a].nodeType&&/\S/.test(i[a].nodeValue)&&(s?i[a].nodeValue="":(i[a].nodeValue=r[o],s=!0));if(!s){var u=t.createTextNode(r[o]);e.insertBefore(u,e.firstChild)}}delete r[o]}for(var h in r)e[h]=r[h]}else console.warn("#"+n.id+" is undefined.")}}return a.plural=function(e,t,n,i){var l=parseFloat(t);if(isNaN(l))return e;if(i!=o)return e;a._pluralRules||(a._pluralRules=function(e){function t(e,t){return-1!==t.indexOf(e)}function n(e,t,n){return t<=e&&e<=n}var r={0:function(e){return"other"},1:function(e){return n(e%100,3,10)?"few":0===e?"zero":n(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 n(e,0,1)?"one":"other"},5:function(e){return n(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 n(e,3,6)?"few":n(e,7,10)?"many":2==e?"two":1==e?"one":"other"},9:function(e){return 0===e||1!=e&&n(e%100,1,19)?"few":1==e?"one":"other"},10:function(e){return n(e%10,2,9)&&!n(e%100,11,19)?"few":e%10!=1||n(e%100,11,19)?"other":"one"},11:function(e){return n(e%10,2,4)&&!n(e%100,12,14)?"few":e%10==0||n(e%10,5,9)||n(e%100,11,14)?"many":e%10==1&&e%100!=11?"one":"other"},12:function(e){return n(e,2,4)?"few":1==e?"one":"other"},13:function(e){return n(e%10,2,4)&&!n(e%100,12,14)?"few":1!=e&&n(e%10,0,1)||n(e%10,5,9)||n(e%100,12,14)?"many":1==e?"one":"other"},14:function(e){return n(e%100,3,4)?"few":e%100==2?"two":e%100==1?"one":"other"},15:function(e){return 0===e||n(e%100,2,10)?"few":n(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":n(e,0,2)&&0!==e&&2!=e?"one":"other"},19:function(e){return n(e,2,10)?"few":n(e,0,1)?"one":"other"},20:function(e){return!n(e%10,3,4)&&e%10!=9||n(e%100,10,19)||n(e%100,70,79)||n(e%100,90,99)?e%1e6==0&&0!==e?"many":e%10!=2||t(e%100,[12,72,92])?e%10!=1||t(e%100,[11,71,91])?"other":"one":"two":"few"},21:function(e){return 0===e?"zero":1==e?"one":"other"},22:function(e){return n(e,0,1)||n(e,11,99)?"one":"other"},23:function(e){return n(e%10,1,2)||e%20==0?"one":"other"},24:function(e){return n(e,3,10)||n(e,13,19)?"few":t(e,[2,12])?"two":t(e,[1,11])?"one":"other"}},i={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}[e.replace(/-.*$/,"")];return i in r?r[i]:(console.warn("plural form unknown for ["+e+"]"),function(){return"other"})}(s));var u="["+a._pluralRules(l)+"]";return 0===l&&n+"[zero]"in r?e=r[n+"[zero]"][i]:1==l&&n+"[one]"in r?e=r[n+"[one]"][i]:2==l&&n+"[two]"in r?e=r[n+"[two]"][i]:n+u in r?e=r[n+u][i]:n+"[other]"in r&&(e=r[n+"[other]"][i]),e},{get:function(e,t,n){var r,i=e.lastIndexOf("."),s=o;i>0&&(s=e.substring(i+1),e=e.substring(0,i)),n&&((r={})[s]=n);var a=c(e,t,r);return a&&s in a?a[s]:"{{"+e+"}}"},getData:function(){return r},getText:function(){return i},getLanguage:function(){return s},setLanguage:function(e,n){!function(e,n){e&&(e=e.toLowerCase()),n=n||function(){},r={},i="",s="",s=e;var a=t.querySelectorAll('link[type="application/l10n"]'),c=a.length;if(0!==c){var h,d,f=0;d=function(){++f>=c&&(n(),l="complete")};for(var p=0;p<c;p++)new v(a[p]).load(e,d)}else{var g=(h=t.querySelector('script[type="application/l10n"]'))?JSON.parse(h.innerHTML):null;if(g&&g.locales&&g.default_locale){if(console.log("using the embedded JSON directory, early way out"),!(r=g.locales[e])){var y=g.default_locale.toLowerCase();for(var m in g.locales){if((m=m.toLowerCase())===e){r=g.locales[e];break}m===y&&(r=g.locales[y])}}n()}else console.log("no resource to load, early way out");l="complete"}function v(e){var t=e.href;this.load=function(e,n){!function(e,t,n,s){var a=e.replace(/[^\/]*$/,"")||"./";function l(e){return e.lastIndexOf("\\")<0?e:e.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,"'")}u(e,(function(e){i+=e,function(e,i){var s={},c=/^\s*|\s*$/,h=/^\s*#|^\s*$/,d=/^\s*\[(.*)\]\s*$/,f=/^\s*@import\s+url\((.*)\)\s*$/i,p=/^([^=\s]*)\s*=\s*(.+)$/;function g(e,n,r){var i=e.replace(c,"").split(/[\r\n]+/),o="*",u=t.split("-",1)[0],g=!1,m="";!function e(){for(;;){if(!i.length)return void r();var c=i.shift();if(!h.test(c)){if(n){if(m=d.exec(c)){o=m[1].toLowerCase(),g="*"!==o&&o!==t&&o!==u;continue}if(g)continue;if(m=f.exec(c))return void y(a+m[1],e)}var v=c.match(p);v&&3==v.length&&(s[v[1]]=l(v[2]))}}}()}function y(e,t){u(e,(function(e){g(e,!1,t)}),(function(){console.warn(e+" not found."),t()}))}g(e,!0,(function(){!function(e){for(var t in e){var i,s,a=t.lastIndexOf(".");a>0?(i=t.substring(0,a),s=t.substring(a+1)):(i=t,s=o),r[i]||(r[i]={}),r[i][s]=e[t]}n&&n()}(s)}))}(e)}),s)}(t,e,n,(function(){console.warn(t+" not found."),console.warn('"'+e+'" resource not found'),s="",n()}))}}}(e,(function(){n&&n()}))},getDirection:function(){var e=s.split("-",1)[0];return["ar","he","fa","ps","ur"].indexOf(e)>=0?"rtl":"ltr"},translate:function(e){for(var n=function(e){return e?e.querySelectorAll("*[data-l10n-id]"):[]}(e=e||t.documentElement),r=n.length,i=0;i<r;i++)f(n[i]);f(e)},getReadyState:function(){return l},ready:function(n){n&&("complete"==l||"interactive"==l?e.setTimeout((function(){n()})):t.addEventListener&&t.addEventListener("localized",(function e(){t.removeEventListener("localized",e),n()})))}}}(window,document)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFFindController=t.FindState=void 0;var r=n(2),i=n(14),o=n(3);var s={FOUND:0,NOT_FOUND:1,WRAPPED:2,PENDING:3};t.FindState=s;var a={"\u2018":"'","\u2019":"'","\u201a":"'","\u201b":"'","\u201c":'"',"\u201d":'"',"\u201e":'"',"\u201f":'"',"\xbc":"1/4","\xbd":"1/2","\xbe":"3/4"},l=null;function u(e){if(!l){var t=Object.keys(a).join("");l=new RegExp("[".concat(t,"]"),"g")}return e.replace(l,(function(e){return a[e]}))}t.PDFFindController=function(){function e(t){var n=t.linkService,r=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=r,this._reset(),r._on("findbarclose",this._onFindBarClose.bind(this))}var t;return(t=[{key:"setDocument",value:function(e){this._pdfDocument&&this._reset(),e&&(this._pdfDocument=e,this._firstPageCapability.resolve())}},{key:"executeCommand",value:function(e,t){var n=this;if(t){var 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(){if(n._pdfDocument&&(!r||n._pdfDocument===r)){n._extractText();var 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,n=void 0===t?null:t,r=e.pageIndex,i=void 0===r?-1:r,s=e.matchIndex,a=void 0===s?-1:s;this._scrollMatches&&n&&-1!==a&&a===this._selected.matchIdx&&-1!==i&&i===this._selected.pageIdx&&(this._scrollMatches=!1,(0,o.scrollIntoView)(n,{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,r.createPromiseCapability)()}},{key:"_shouldDirtyMatch",value:function(e,t){if(t.query!==this._state.query)return!0;switch(e){case"findagain":var n=this._selected.pageIdx+1,r=this._linkService;return n>=1&&n<=r.pagesCount&&n!==r.page&&!r.isPageVisible(n);case"findhighlightallchange":return!1}return!0}},{key:"_prepareMatches",value:function(e,t,n){function r(t){var n=e[t];if(t<e.length-1&&n.match===e[t+1].match)return n.skipped=!0,!0;for(var r=t-1;r>=0;r--){var i=e[r];if(!i.skipped){if(i.match+i.matchLength<n.match)break;if(i.match+i.matchLength>=n.match+n.matchLength)return n.skipped=!0,!0}}return!1}e.sort((function(e,t){return e.match===t.match?e.matchLength-t.matchLength:e.match-t.match}));for(var i=0,o=e.length;i<o;i++)r(i)||(t.push(e[i].match),n.push(e[i].matchLength))}},{key:"_isEntireWord",value:function(e,t,n){if(t>0){var r=e.charCodeAt(t),o=e.charCodeAt(t-1);if((0,i.getCharacterType)(r)===(0,i.getCharacterType)(o))return!1}var s=t+n-1;if(s<e.length-1){var a=e.charCodeAt(s),l=e.charCodeAt(s+1);if((0,i.getCharacterType)(a)===(0,i.getCharacterType)(l))return!1}return!0}},{key:"_calculatePhraseMatch",value:function(e,t,n,r){for(var i=[],o=e.length,s=-o;-1!==(s=n.indexOf(e,s+o));)r&&!this._isEntireWord(n,s,o)||i.push(s);this._pageMatches[t]=i}},{key:"_calculateWordMatch",value:function(e,t,n,r){for(var i=[],o=e.match(/\S+/g),s=0,a=o.length;s<a;s++)for(var l=o[s],u=l.length,c=-u;-1!==(c=n.indexOf(l,c+u));)r&&!this._isEntireWord(n,c,u)||i.push({match:c,matchLength:u,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],n=this._query,r=this._state,i=r.entireWord,o=r.phraseSearch;if(0!==n.length){r.caseSensitive||(t=t.toLowerCase(),n=n.toLowerCase()),o?this._calculatePhraseMatch(n,e,t,i):this._calculateWordMatch(n,e,t,i),this._state.highlightAll&&this._updatePage(e),this._resumePageIdx===e&&(this._resumePageIdx=null,this._nextPageMatch());var s=this._pageMatches[e].length;s>0&&(this._matchesCountTotal+=s,this._updateUIResultsCount())}}},{key:"_extractText",value:function(){var e=this;if(!(this._extractTextPromises.length>0))for(var t=Promise.resolve(),n=function(n,i){var o=(0,r.createPromiseCapability)();e._extractTextPromises[n]=o.promise,t=t.then((function(){return e._pdfDocument.getPage(n+1).then((function(e){return e.getTextContent({normalizeWhitespace:!0})})).then((function(t){for(var r=t.items,i=[],s=0,a=r.length;s<a;s++)i.push(r[s].str);e._pageContents[n]=u(i.join("")),o.resolve(n)}),(function(t){console.error("Unable to get text content for page ".concat(n+1),t),e._pageContents[n]="",o.resolve(n)}))}))},i=0,o=this._linkService.pagesCount;i<o;i++)n(i)}},{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,n=this._linkService.page-1,r=this._linkService.pagesCount;if(this._highlightMatches=!0,this._dirtyMatch){this._dirtyMatch=!1,this._selected.pageIdx=this._selected.matchIdx=-1,this._offset.pageIdx=n,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<r;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 o=this._offset;if(this._pagesToSearch=r,null!==o.matchIdx){if(!t&&o.matchIdx+1<this._pageMatches[o.pageIdx].length||t&&o.matchIdx>0)return o.matchIdx=t?o.matchIdx-1:o.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,n=e.length,r=this._state.findPrevious;return n?(t.matchIdx=r?n-1:0,this._updateMatch(!0),!0):(this._advanceOffsetPage(r),!!(t.wrapped&&(t.matchIdx=null,this._pagesToSearch<0))&&(this._updateMatch(!1),!0))}},{key:"_nextPageMatch",value:function(){null!==this._resumePageIdx&&console.error("There can only be one pending page.");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,n=this._linkService.pagesCount;t.pageIdx=e?t.pageIdx-1:t.pageIdx+1,t.matchIdx=null,this._pagesToSearch--,(t.pageIdx>=n||t.pageIdx<0)&&(t.pageIdx=e?n-1:0,t.wrapped=!0)}},{key:"_updateMatch",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=s.NOT_FOUND,n=this._offset.wrapped;if(this._offset.wrapped=!1,e){var r=this._selected.pageIdx;this._selected.pageIdx=this._offset.pageIdx,this._selected.matchIdx=this._offset.matchIdx,t=n?s.WRAPPED:s.FOUND,-1!==r&&r!==this._selected.pageIdx&&this._updatePage(r)}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,n=this._pdfDocument;this._firstPageCapability.promise.then((function(){!t._pdfDocument||n&&t._pdfDocument!==n||(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,n=e.matchIdx,r=0,i=this._matchesCountTotal;if(-1!==n){for(var o=0;o<t;o++)r+=this._pageMatches[o]&&this._pageMatches[o].length||0;r+=n+1}return(r<1||r>i)&&(r=i=0),{current:r,total:i}}},{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()})}},{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=u(this._state.query)),this._normalizedQuery}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getCharacterType=function(e){return function(e){return e<11904}(e)?function(e){return 0==(65408&e)}(e)?function(e){return 32===e||9===e||13===e||10===e}(e)?r.SPACE:function(e){return e>=97&&e<=122||e>=65&&e<=90}(e)||function(e){return e>=48&&e<=57}(e)||95===e?r.ALPHA_LETTER:r.PUNCT:function(e){return 3584==(65408&e)}(e)?r.THAI_LETTER:160===e?r.SPACE:r.ALPHA_LETTER:function(e){return e>=13312&&e<=40959||e>=63744&&e<=64255}(e)?r.HAN_LETTER:function(e){return e>=12448&&e<=12543}(e)?r.KATAKANA_LETTER:function(e){return e>=12352&&e<=12447}(e)?r.HIRAGANA_LETTER:function(e){return e>=65376&&e<=65439}(e)?r.HALFWIDTH_KATAKANA_LETTER:r.ALPHA_LETTER},t.CharacterType=void 0;var r={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=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isDestHashesEqual=l,t.isDestArraysEqual=u,t.PDFHistory=void 0;var r=n(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 o(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 n=[],r=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{r||null==a.return||a.return()}finally{if(i)throw o}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(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 s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(){return document.location.hash}function l(e,t){return"string"==typeof e&&"string"==typeof t&&(e===t||(0,r.parseQueryString)(e).nameddest===t)}function u(e,t){function n(e,t){if(i(e)!==i(t))return!1;if(Array.isArray(e)||Array.isArray(t))return!1;if(null!==e&&"object"===i(e)&&null!==t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var r in e)if(!n(e[r],t[r]))return!1;return!0}return e===t||Number.isNaN(e)&&Number.isNaN(t)}if(!Array.isArray(e)||!Array.isArray(t))return!1;if(e.length!==t.length)return!1;for(var r=0,o=e.length;r<o;r++)if(!n(e[r],t[r]))return!1;return!0}t.PDFHistory=function(){function e(t){var n=this,r=t.linkService,i=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=i,this._initialized=!1,this._fingerprint="",this.reset(),this._boundEvents=null,this._isViewerInPresentationMode=!1,this.eventBus._on("presentationmodechanged",(function(e){n._isViewerInPresentationMode=e.active||e.switchInProgress})),this.eventBus._on("pagesinit",(function(){n._isPagesLoaded=!1,n.eventBus._on("pagesloaded",(function e(t){n.eventBus._off("pagesloaded",e),n._isPagesLoaded=!!t.pagesCount}))}))}var t;return(t=[{key:"initialize",value:function(e){var t=e.fingerprint,n=e.resetHistory,r=void 0!==n&&n,i=e.updateUrl,o=void 0!==i&&i;if(t&&"string"==typeof t){this._initialized&&this.reset();var s=""!==this._fingerprint&&this._fingerprint!==t;this._fingerprint=t,this._updateUrl=!0===o,this._initialized=!0,this._bindEvents();var l=window.history.state;if(this._popStateInProgress=!1,this._blockHashChange=0,this._currentHash=a(),this._numPositionUpdates=0,this._uid=this._maxUid=0,this._destination=null,this._position=null,!this._isValidState(l,!0)||r){var u=this._parseCurrentHash(!0),c=u.hash,h=u.page,d=u.rotation;return!c||s||r?void this._pushOrReplaceState(null,!0):void this._pushOrReplaceState({hash:c,page:h,rotation:d},!0)}var f=l.destination;this._updateInternalState(f,l.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),void 0!==f.rotation&&(this._initialRotation=f.rotation),f.dest?(this._initialBookmark=JSON.stringify(f.dest),this._destination.page=null):f.hash?this._initialBookmark=f.hash:f.page&&(this._initialBookmark="page=".concat(f.page))}else console.error('PDFHistory.initialize: The "fingerprint" must be a non-empty string.')}},{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,n=e.namedDest,r=void 0===n?null:n,i=e.explicitDest,o=e.pageNumber;if(this._initialized)if(r&&"string"!=typeof r)console.error("PDFHistory.push: "+'"'.concat(r,'" is not a valid namedDest parameter.'));else if(Array.isArray(i))if(Number.isInteger(o)&&o>0&&o<=this.linkService.pagesCount||null===o&&!this._destination){var s=r||JSON.stringify(i);if(s){var a=!1;if(this._destination&&(l(this._destination.hash,s)||u(this._destination.dest,i))){if(this._destination.page)return;a=!0}this._popStateInProgress&&!a||(this._pushOrReplaceState({dest:i,hash:s,page:o,rotation:this.linkService.rotation},a),this._popStateInProgress||(this._popStateInProgress=!0,Promise.resolve().then((function(){t._popStateInProgress=!1}))))}}else console.error("PDFHistory.push: "+'"'.concat(o,'" is not a valid pageNumber parameter.'));else console.error("PDFHistory.push: "+'"'.concat(i,'" is not a valid explicitDest parameter.'))}},{key:"pushCurrentPosition",value:function(){this._initialized&&!this._popStateInProgress&&this._tryPushCurrentPosition()}},{key:"back",value:function(){if(this._initialized&&!this._popStateInProgress){var e=window.history.state;this._isValidState(e)&&e.uid>0&&window.history.back()}}},{key:"forward",value:function(){if(this._initialized&&!this._popStateInProgress){var e=window.history.state;this._isValidState(e)&&e.uid<this._maxUid&&window.history.forward()}}},{key:"_pushOrReplaceState",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=n||!this._destination,i={fingerprint:this._fingerprint,uid:r?this._uid:this._uid+1,destination:e};if(this._updateInternalState(e,i.uid),this._updateUrl&&e&&e.hash){var o=document.location.href.split("#")[0];o.startsWith("file://")||(t="".concat(o,"#").concat(e.hash))}r?window.history.replaceState(i,"",t):(this._maxUid=this._uid,window.history.pushState(i,"",t))}},{key:"_tryPushCurrentPosition",value:function(){var e=arguments.length>0&&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))){var n=!1;if(this._destination.page>=t.first&&this._destination.page<=t.page){if(this._destination.dest||!this._destination.first)return;n=!0}this._pushOrReplaceState(t,n)}}else this._pushOrReplaceState(t)}}},{key:"_isValidState",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e)return!1;if(e.fingerprint!==this._fingerprint){if(!t)return!1;if("string"!=typeof e.fingerprint||e.fingerprint.length!==this._fingerprint.length)return!1;var n=performance.getEntriesByType("navigation"),r=o(n,1),s=r[0];if(!s||"reload"!==s.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 n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),n&&e&&e.temporary&&delete e.temporary,this._destination=e,this._uid=t,this._numPositionUpdates=0}},{key:"_parseCurrentHash",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=unescape(a()).substring(1),n=(0,r.parseQueryString)(t),i=n.nameddest||"",o=0|n.page;return Number.isInteger(o)&&o>0&&o<=this.linkService.pagesCount&&!(e&&i.length>0)||(o=null),{hash:t,page:o,rotation:this.linkService.rotation}}},{key:"_updateViewarea",value:function(e){var t=this,n=e.location;this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._position={hash:this._isViewerInPresentationMode?"page=".concat(n.pageNumber):n.pdfOpenParams.substring(1),page:this.linkService.page,first:n.pageNumber,rotation:n.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=this,n=e.state,i=a(),o=this._currentHash!==i;if(this._currentHash=i,n){if(this._isValidState(n)){this._popStateInProgress=!0,o&&(this._blockHashChange++,(0,r.waitOnEventOrTimeout)({target:window,name:"hashchange",delay:1e3}).then((function(){t._blockHashChange--})));var s=n.destination;this._updateInternalState(s,n.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),(0,r.isValidRotation)(s.rotation)&&(this.linkService.rotation=s.rotation),s.dest?this.linkService.navigateTo(s.dest):s.hash?this.linkService.setHash(s.hash):s.page&&(this.linkService.page=s.page),Promise.resolve().then((function(){t._popStateInProgress=!1}))}}else{this._uid++;var l=this._parseCurrentHash();this._pushOrReplaceState({hash:l.hash,page:l.page,rotation:l.rotation},!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||this._blockHashChange>0)}},{key:"initialBookmark",get:function(){return this._initialized?this._initialBookmark:null}},{key:"initialRotation",get:function(){return this._initialized?this._initialRotation:null}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFPageView=void 0;var r,i=(r=n(4))&&r.__esModule?r:{default:r},o=n(3),s=n(2),a=n(17);function l(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(u){return void n(u)}a.done?t(l):Promise.resolve(l).then(r,i)}var u=n(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 n=t.container,r=t.defaultViewport;this.id=t.id,this.renderingId="page"+this.id,this.pdfPage=null,this.pageLabel=null,this.rotation=0,this.scale=t.scale||o.DEFAULT_SCALE,this.viewport=r,this.pdfPageRotate=r.rotation,this.hasRestrictedScaling=!1,this.textLayerMode=Number.isInteger(t.textLayerMode)?t.textLayerMode:o.TextLayerMode.ENABLE,this.imageResourcesPath=t.imageResourcesPath||"",this.renderInteractiveForms=t.renderInteractiveForms||!1,this.useOnlyCssZoom=t.useOnlyCssZoom||!1,this.maxCanvasPixels=t.maxCanvasPixels||u,this.eventBus=t.eventBus,this.renderingQueue=t.renderingQueue,this.textLayerFactory=t.textLayerFactory,this.annotationLayerFactory=t.annotationLayerFactory,this.renderer=t.renderer||o.RendererType.CANVAS,this.enableWebGL=t.enableWebGL||!1,this.l10n=t.l10n||o.NullL10n,this.paintTask=null,this.paintedViewportMap=new WeakMap,this.renderingState=a.RenderingStates.INITIAL,this.resume=null,this.error=null,this.annotationLayer=null,this.textLayer=null,this.zoomLayer=null;var i=document.createElement("div");i.className="page",i.style.width=Math.floor(this.viewport.width)+"px",i.style.height=Math.floor(this.viewport.height)+"px",i.setAttribute("data-page-number",this.id),this.div=i,n.appendChild(i)}var t;return(t=[{key:"setPdfPage",value:function(e){this.pdfPage=e,this.pdfPageRotate=e.rotate,this.viewport=e.getViewport({scale:this.scale*o.CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this.stats=e.stats,this.reset()}},{key:"destroy",value:function(){this.reset(),this.pdfPage&&this.pdfPage.cleanup()}},{key:"_resetZoomLayer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.zoomLayer){var t=this.zoomLayer.firstChild;this.paintedViewportMap.delete(t),t.width=0,t.height=0,e&&this.zoomLayer.remove(),this.zoomLayer=null}}},{key:"reset",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.cancelRendering(t),this.renderingState=a.RenderingStates.INITIAL;var n=this.div;n.style.width=Math.floor(this.viewport.width)+"px",n.style.height=Math.floor(this.viewport.height)+"px";for(var r=n.childNodes,i=e&&this.zoomLayer||null,o=t&&this.annotationLayer&&this.annotationLayer.div||null,s=r.length-1;s>=0;s--){var l=r[s];i!==l&&o!==l&&n.removeChild(l)}n.removeAttribute("data-loaded"),o?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",n.appendChild(this.loadingIconDiv)}},{key:"update",value:function(e,t){if(this.scale=e||this.scale,void 0!==t&&(this.rotation=t),this.viewport=this.viewport.clone({scale:this.scale*o.CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this.svg)return this.cssTransform(this.svg,!0),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now()});var n=!1;if(this.canvas&&this.maxCanvasPixels>0){var r=this.outputScale;(Math.floor(this.viewport.width)*r.sx|0)*(Math.floor(this.viewport.height)*r.sy|0)>this.maxCanvasPixels&&(n=!0)}if(this.canvas){if(this.useOnlyCssZoom||this.hasRestrictedScaling&&n)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=arguments.length>0&&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=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=this.viewport.width,r=this.viewport.height,i=this.div;e.style.width=e.parentNode.style.width=i.style.width=Math.floor(n)+"px",e.style.height=e.parentNode.style.height=i.style.height=Math.floor(r)+"px";var o=this.viewport.rotation-this.paintedViewportMap.get(e).rotation,s=Math.abs(o),a=1,l=1;90!==s&&270!==s||(a=r/n,l=n/r);var u="rotate("+o+"deg) scale("+a+","+l+")";if(e.style.transform=u,this.textLayer){var c=this.textLayer.viewport,h=this.viewport.rotation-c.rotation,d=Math.abs(h),f=n/c.width;90!==d&&270!==d||(f=n/c.height);var p,g,y=this.textLayer.textLayerDiv;switch(d){case 0:p=g=0;break;case 90:p=0,g="-"+y.style.height;break;case 180:p="-"+y.style.width,g="-"+y.style.height;break;case 270:p="-"+y.style.width,g=0;break;default:console.error("Bad rotation value.")}y.style.transform="rotate("+d+"deg) scale("+f+", "+f+") translate("+p+", "+g+")",y.style.transformOrigin="0% 0%"}t&&this.annotationLayer&&this.annotationLayer.render(this.viewport,"display")}},{key:"getPagePoint",value:function(e,t){return this.viewport.convertToPdfPoint(e,t)}},{key:"draw",value:function(){var e=this;this.renderingState!==a.RenderingStates.INITIAL&&(console.error("Must be in new state before drawing"),this.reset());var t=this.div,n=this.pdfPage;if(!n)return this.renderingState=a.RenderingStates.FINISHED,this.loadingIconDiv&&(t.removeChild(this.loadingIconDiv),delete this.loadingIconDiv),Promise.reject(new Error("pdfPage is not loaded"));this.renderingState=a.RenderingStates.RUNNING;var r=document.createElement("div");r.style.width=t.style.width,r.style.height=t.style.height,r.classList.add("canvasWrapper"),this.annotationLayer&&this.annotationLayer.div?t.insertBefore(r,this.annotationLayer.div):t.appendChild(r);var u=null;if(this.textLayerMode!==o.TextLayerMode.DISABLE&&this.textLayerFactory){var c=document.createElement("div");c.className="textLayer",c.style.width=r.style.width,c.style.height=r.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===o.TextLayerMode.ENABLE_ENHANCE,this.eventBus)}this.textLayer=u;var h=null;this.renderingQueue&&(h=function(t){if(!e.renderingQueue.isHighestPriority(e))return e.renderingState=a.RenderingStates.PAUSED,void(e.resume=function(){e.renderingState=a.RenderingStates.RUNNING,t()});t()});var d=function(){var r,o=(r=i.default.mark((function r(o){return i.default.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(f===e.paintTask&&(e.paintTask=null),!(o instanceof s.RenderingCancelledException)){r.next=4;break}return e.error=null,r.abrupt("return");case 4:if(e.renderingState=a.RenderingStates.FINISHED,e.loadingIconDiv&&(t.removeChild(e.loadingIconDiv),delete e.loadingIconDiv),e._resetZoomLayer(!0),e.error=o,e.stats=n.stats,e.eventBus.dispatch("pagerendered",{source:e,pageNumber:e.id,cssTransform:!1,timestamp:performance.now()}),!o){r.next=12;break}throw o;case 12:case"end":return r.stop()}}),r)})),function(){var e=this,t=arguments;return new Promise((function(n,i){var o=r.apply(e,t);function s(e){l(o,n,i,s,a,"next",e)}function a(e){l(o,n,i,s,a,"throw",e)}s(void 0)}))});return function(e){return o.apply(this,arguments)}}(),f=this.renderer===o.RendererType.SVG?this.paintOnSvg(r):this.paintOnCanvas(r);f.onRenderContinue=h,this.paintTask=f;var p=f.promise.then((function(){return d(null).then((function(){if(u){var e=n.streamTextContent({normalizeWhitespace:!0});u.setTextContentStream(e),u.render()}}))}),(function(e){return d(e)}));return this.annotationLayerFactory&&(this.annotationLayer||(this.annotationLayer=this.annotationLayerFactory.createAnnotationLayerBuilder(t,n,this.imageResourcesPath,this.renderInteractiveForms,this.l10n)),this.annotationLayer.render(this.viewport,"display")),t.setAttribute("data-loaded",!0),this.eventBus.dispatch("pagerender",{source:this,pageNumber:this.id}),p}},{key:"paintOnCanvas",value:function(e){var t=(0,s.createPromiseCapability)(),n={promise:t.promise,onRenderContinue:function(e){e()},cancel:function(){g.cancel()}},r=this.viewport,i=document.createElement("canvas");this.l10n.get("page_canvas",{page:this.id},"Page {{page}}").then((function(e){i.setAttribute("aria-label",e)})),i.setAttribute("hidden","hidden");var a=!0,l=function(){a&&(i.removeAttribute("hidden"),a=!1)};e.appendChild(i),this.canvas=i,i.mozOpaque=!0;var u=i.getContext("2d",{alpha:!1}),c=(0,o.getOutputScale)(u);if(this.outputScale=c,this.useOnlyCssZoom){var h=r.clone({scale:o.CSS_UNITS});c.sx*=h.width/r.width,c.sy*=h.height/r.height,c.scaled=!0}if(this.maxCanvasPixels>0){var d=Math.sqrt(this.maxCanvasPixels/(r.width*r.height));c.sx>d||c.sy>d?(c.sx=d,c.sy=d,c.scaled=!0,this.hasRestrictedScaling=!0):this.hasRestrictedScaling=!1}var f=(0,o.approximateFraction)(c.sx),p=(0,o.approximateFraction)(c.sy);i.width=(0,o.roundToDivide)(r.width*c.sx,f[0]),i.height=(0,o.roundToDivide)(r.height*c.sy,p[0]),i.style.width=(0,o.roundToDivide)(r.width,f[1])+"px",i.style.height=(0,o.roundToDivide)(r.height,p[1])+"px",this.paintedViewportMap.set(i,r);var g=this.pdfPage.render({canvasContext:u,transform:c.scaled?[c.sx,0,0,c.sy,0,0]:null,viewport:this.viewport,enableWebGL:this.enableWebGL,renderInteractiveForms:this.renderInteractiveForms});return g.onContinue=function(e){l(),n.onRenderContinue?n.onRenderContinue(e):e()},g.promise.then((function(){l(),t.resolve(void 0)}),(function(e){l(),t.reject(e)})),n}},{key:"paintOnSvg",value:function(e){var t=this,n=!1,r=function(){if(n)throw new s.RenderingCancelledException("Rendering cancelled, page ".concat(t.id),"svg")},i=this.pdfPage,l=this.viewport.clone({scale:o.CSS_UNITS});return{promise:i.getOperatorList().then((function(n){return r(),new s.SVGGraphics(i.commonObjs,i.objs).getSVG(n,l).then((function(n){r(),t.svg=n,t.paintedViewportMap.set(n,l),n.style.width=e.style.width,n.style.height=e.style.height,t.renderingState=a.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}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFRenderingQueue=t.RenderingStates=void 0;var r={INITIAL:0,RUNNING:1,PAUSED:2,FINISHED:3};t.RenderingStates=r,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;return(t=[{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,n){var r=e.views,i=r.length;if(0===i)return null;for(var o=0;o<i;++o){var s=r[o].view;if(!this.isViewFinished(s))return s}if(n){var a=e.last.id;if(t[a]&&!this.isViewFinished(t[a]))return t[a]}else{var l=e.first.id-2;if(t[l]&&!this.isViewFinished(t[l]))return t[l]}return null}},{key:"isViewFinished",value:function(e){return e.renderingState===r.FINISHED}},{key:"renderView",value:function(e){var t=this;switch(e.renderingState){case r.FINISHED:return!1;case r.PAUSED:this.highestPriorityPage=e.renderingId,e.resume();break;case r.RUNNING:this.highestPriorityPage=e.renderingId;break;case r.INITIAL:this.highestPriorityPage=e.renderingId,e.draw().finally((function(){t.renderHighestPriority()})).catch((function(e){console.error('renderView: "'.concat(e,'"'))}))}return!0}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFSinglePageViewer=void 0;var r=n(19),i=n(2);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,n){return(s="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=u(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}t.PDFSinglePageViewer=function(e){!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&&a(e,t)}(c,e);var t,n,r,o=(n=c,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}}(),function(){var e,t=u(n);if(r){var i=u(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return l(this,e)});function c(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),(t=o.call(this,e)).eventBus._on("pagesinit",(function(e){t._ensurePageViewVisible()})),t}return(t=[{key:"_resetView",value:function(){s(u(c.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],n=this.viewer.childNodes;switch(n.length){case 0:this.viewer.appendChild(e.div);break;case 1:if(n[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(u(c.prototype),"_scrollUpdate",this).call(this)}},{key:"_scrollIntoView",value:function(e){var t=this,n=e.pageDiv,r=e.pageSpot,i=void 0===r?null:r,o=e.pageNumber,a=void 0===o?null:o;a&&this._setCurrentPageNumber(a);var l=this._currentPageNumber>=this._previousPageNumber;this._ensurePageViewVisible(),this.update(),s(u(c.prototype),"_scrollIntoView",this).call(this,{pageDiv:n,pageSpot:i,pageNumber:a}),this._updateScrollDown=function(){t.scroll.down=l,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)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(c.prototype,t),c}(r.BaseViewer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseViewer=void 0;var r=n(3),i=n(17),o=n(1),s=n(2),a=n(16),l=n(7),u=n(8);function c(e){var t=[];this.push=function(n){var r=t.indexOf(n);r>=0&&t.splice(r,1),t.push(n),t.length>e&&t.shift().destroy()},this.resize=function(n,i){if(e=n,i){for(var o=new Set,s=0,a=i.length;s<a;++s)o.add(i[s].id);(0,r.moveToEndOfArray)(t,(function(e){return o.has(e.id)}))}for(;t.length>e;)t.shift().destroy()}}function h(e,t){return t===e||Math.abs(t-e)<1e-15}t.BaseViewer=function(){function e(t){var n=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.");this._name=this.constructor.name,this.container=t.container,this.viewer=t.viewer||t.container.firstElementChild,this.eventBus=t.eventBus,this.linkService=t.linkService||new l.SimpleLinkService,this.downloadManager=t.downloadManager||null,this.findController=t.findController||null,this.removePageBorders=t.removePageBorders||!1,this.textLayerMode=Number.isInteger(t.textLayerMode)?t.textLayerMode:r.TextLayerMode.ENABLE,this.imageResourcesPath=t.imageResourcesPath||"",this.renderInteractiveForms=t.renderInteractiveForms||!1,this.enablePrintAutoRotate=t.enablePrintAutoRotate||!1,this.renderer=t.renderer||r.RendererType.CANVAS,this.enableWebGL=t.enableWebGL||!1,this.useOnlyCssZoom=t.useOnlyCssZoom||!1,this.maxCanvasPixels=t.maxCanvasPixels,this.l10n=t.l10n||r.NullL10n,this.defaultRenderingQueue=!t.renderingQueue,this.defaultRenderingQueue?(this.renderingQueue=new i.PDFRenderingQueue,this.renderingQueue.setViewer(this)):this.renderingQueue=t.renderingQueue,this.scroll=(0,r.watchScroll)(this.container,this._scrollUpdate.bind(this)),this.presentationModeState=r.PresentationModeState.UNKNOWN,this._onBeforeDraw=this._onAfterDraw=null,this._resetView(),this.removePageBorders&&this.viewer.classList.add("removePageBorders"),Promise.resolve().then((function(){n.eventBus.dispatch("baseviewerinit",{source:n})}))}var t;return(t=[{key:"getPageView",value:function(e){return this._pages[e]}},{key:"_setCurrentPageNumber",value:function(e){var t=arguments.length>1&&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=this;if(this.pdfDocument&&(this._cancelRendering(),this._resetView(),this.findController&&this.findController.setDocument(null)),this.pdfDocument=e,e){var n=e.numPages,i=e.getPage(1);this._pagesCapability.promise.then((function(){t.eventBus.dispatch("pagesloaded",{source:t,pagesCount:n})})),this._onBeforeDraw=function(e){var n=t._pages[e.pageNumber-1];n&&t._buffer.push(n)},this.eventBus._on("pagerender",this._onBeforeDraw),this._onAfterDraw=function(e){e.cssTransform||t._onePageRenderedCapability.settled||(t._onePageRenderedCapability.resolve(),t.eventBus._off("pagerendered",t._onAfterDraw),t._onAfterDraw=null)},this.eventBus._on("pagerendered",this._onAfterDraw),i.then((function(i){t._firstPageCapability.resolve(i);for(var o=t.currentScale,s=i.getViewport({scale:o*r.CSS_UNITS}),l=t.textLayerMode!==r.TextLayerMode.DISABLE?t:null,u=1;u<=n;++u){var c=new a.PDFPageView({container:t._viewerElement,eventBus:t.eventBus,id:u,scale:o,defaultViewport:s.clone(),renderingQueue:t.renderingQueue,textLayerFactory:l,textLayerMode:t.textLayerMode,annotationLayerFactory:t,imageResourcesPath:t.imageResourcesPath,renderInteractiveForms:t.renderInteractiveForms,renderer:t.renderer,enableWebGL:t.enableWebGL,useOnlyCssZoom:t.useOnlyCssZoom,maxCanvasPixels:t.maxCanvasPixels,l10n:t.l10n});t._pages.push(c)}var h=t._pages[0];h&&(h.setPdfPage(i),t.linkService.cachePageRef(1,i.ref)),t._spreadMode!==r.SpreadMode.NONE&&t._updateSpreadMode(),t._onePageRenderedOrForceFetch().then((function(){if(t.findController&&t.findController.setDocument(e),e.loadingParams.disableAutoFetch||n>7500)t._pagesCapability.resolve();else{var r=n-1;if(r<=0)t._pagesCapability.resolve();else for(var i=function(n){e.getPage(n).then((function(e){var i=t._pages[n-1];i.pdfPage||i.setPdfPage(e),t.linkService.cachePageRef(n,e.ref),0==--r&&t._pagesCapability.resolve()}),(function(e){console.error("Unable to get page ".concat(n," to initialize viewer"),e),0==--r&&t._pagesCapability.resolve()}))},o=2;o<=n;++o)i(o)}})),t.eventBus.dispatch("pagesinit",{source:t}),t.defaultRenderingQueue&&t.update()})).catch((function(e){console.error("Unable to initialize viewer",e)}))}}},{key:"setPageLabels",value:function(e){if(this.pdfDocument){e?Array.isArray(e)&&this.pdfDocument.numPages===e.length?this._pageLabels=e:(this._pageLabels=null,console.error("".concat(this._name,".setPageLabels: Invalid page labels."))):this._pageLabels=null;for(var t=0,n=this._pages.length;t<n;t++)this._pages[t].setPageLabel(this._pageLabels&&this._pageLabels[t])}}},{key:"_resetView",value:function(){this._pages=[],this._currentPageNumber=1,this._currentScale=r.UNKNOWN_SCALE,this._currentScaleValue=null,this._pageLabels=null,this._buffer=new c(10),this._location=null,this._pagesRotation=0,this._pagesRequests=new WeakMap,this._firstPageCapability=(0,s.createPromiseCapability)(),this._onePageRenderedCapability=(0,s.createPromiseCapability)(),this._pagesCapability=(0,s.createPromiseCapability)(),this._scrollMode=r.ScrollMode.VERTICAL,this._spreadMode=r.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.pageSpot;(0,r.scrollIntoView)(e.pageDiv,void 0===t?null:t)}},{key:"_setScaleUpdatePages",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(this._currentScaleValue=t.toString(),h(this._currentScale,e))r&&this.eventBus.dispatch("scalechanging",{source:this,scale:e,presetValue:t});else{for(var i=0,o=this._pages.length;i<o;i++)this._pages[i].update(e);if(this._currentScale=e,!n){var s,a=this._currentPageNumber;!this._location||this.isInPresentationMode||this.isChangingPresentationMode||(a=this._location.pageNumber,s=[null,{name:"XYZ"},this._location.left,this._location.top,null]),this.scrollPageIntoView({pageNumber:a,destArray:s,allowNegativeOffset:!0})}this.eventBus.dispatch("scalechanging",{source:this,scale:e,presetValue:r?t:void 0}),this.defaultRenderingQueue&&this.update()}}},{key:"_setScale",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=parseFloat(e);if(n>0)this._setScaleUpdatePages(n,e,t,!1);else{var i=this._pages[this._currentPageNumber-1];if(!i)return;var o=this.isInPresentationMode||this.removePageBorders,s=o?0:r.SCROLLBAR_PADDING,a=o?0:r.VERTICAL_PADDING;if(!o&&this._isScrollModeHorizontal){var l=[a,s];s=l[0],a=l[1]}var u=(this.container.clientWidth-s)/i.width*i.scale,c=(this.container.clientHeight-a)/i.height*i.scale;switch(e){case"page-actual":n=1;break;case"page-width":n=u;break;case"page-height":n=c;break;case"page-fit":n=Math.min(u,c);break;case"auto":var h=(0,r.isPortraitOrientation)(i)?u:Math.min(c,u);n=Math.min(r.MAX_AUTO_SCALE,h);break;default:return void console.error("".concat(this._name,'._setScale: "').concat(e,'" is an unknown zoom value.'))}this._setScaleUpdatePages(n,e,t,!0)}}},{key:"_resetCurrentPageView",value:function(){this.isInPresentationMode&&this._setScale(this._currentScaleValue,!0),this._scrollIntoView({pageDiv:this._pages[this._currentPageNumber-1].div})}},{key:"scrollPageIntoView",value:function(e){var t=e.pageNumber,n=e.destArray,i=void 0===n?null:n,o=e.allowNegativeOffset,s=void 0!==o&&o,a=e.ignoreDestinationZoom,l=void 0!==a&&a;if(this.pdfDocument){var u=Number.isInteger(t)&&this._pages[t-1];if(u)if(!this.isInPresentationMode&&i){var c,h=0,d=0,f=0,p=0,g=u.rotation%180!=0,y=(g?u.height:u.width)/u.scale/r.CSS_UNITS,m=(g?u.width:u.height)/u.scale/r.CSS_UNITS,v=0;switch(i[1].name){case"XYZ":v=i[4],h=null!==(h=i[2])?h:0,d=null!==(d=i[3])?d:m;break;case"Fit":case"FitB":v="page-fit";break;case"FitH":case"FitBH":v="page-width",null===(d=i[2])&&this._location&&(h=this._location.left,d=this._location.top);break;case"FitV":case"FitBV":h=i[2],f=y,p=m,v="page-height";break;case"FitR":f=i[4]-(h=i[2]),c=(this.container.clientHeight-(this.removePageBorders?0:r.VERTICAL_PADDING))/(p=i[5]-(d=i[3]))/r.CSS_UNITS,v=Math.min(Math.abs((this.container.clientWidth-(this.removePageBorders?0:r.SCROLLBAR_PADDING))/f/r.CSS_UNITS),Math.abs(c));break;default:return void console.error("".concat(this._name,".scrollPageIntoView: ")+'"'.concat(i[1].name,'" is not a valid destination type.'))}if(l||(v&&v!==this._currentScale?this.currentScaleValue=v:this._currentScale===r.UNKNOWN_SCALE&&(this.currentScaleValue=r.DEFAULT_SCALE_VALUE)),"page-fit"!==v||i[4]){var _=[u.viewport.convertToViewportPoint(h,d),u.viewport.convertToViewportPoint(h+f,d+p)],b=Math.min(_[0][0],_[1][0]),w=Math.min(_[0][1],_[1][1]);s||(b=Math.max(b,0),w=Math.max(w,0)),this._scrollIntoView({pageDiv:u.div,pageSpot:{left:b,top:w},pageNumber:t})}else this._scrollIntoView({pageDiv:u.div,pageNumber:t})}else this._setCurrentPageNumber(t,!0);else console.error("".concat(this._name,".scrollPageIntoView: ")+'"'.concat(t,'" is not a valid pageNumber parameter.'))}}},{key:"_updateLocation",value:function(e){var t=this._currentScale,n=this._currentScaleValue,r=parseFloat(n)===t?Math.round(1e4*t)/100:n,i=e.id,o="#page="+i;o+="&zoom="+r;var s=this.container,a=this._pages[i-1].getPagePoint(s.scrollLeft-e.x,s.scrollTop-e.y),l=Math.round(a[0]),u=Math.round(a[1]);this._location={pageNumber:i,scale:r,top:u,left:l,rotation:this._pagesRotation,pdfOpenParams:o+=","+l+","+u}}},{key:"_updateHelper",value:function(e){throw new Error("Not implemented: _updateHelper")}},{key:"update",value:function(){var e=this._getVisiblePages(),t=e.views,n=t.length;if(0!==n){var r=Math.max(10,2*n+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,n={id:e.id,x:t.offsetLeft+t.clientLeft,y:t.offsetTop+t.clientTop,view:e};return{first:n,last:n,views:[n]}}},{key:"_getVisiblePages",value:function(){return(0,r.getVisibleElements)(this.container,this._pages,!0,this._isScrollModeHorizontal)}},{key:"isPageVisible",value:function(e){return!!this.pdfDocument&&(e<1||e>this.pagesCount?(console.error("".concat(this._name,'.isPageVisible: "').concat(e,'" is out of bounds.')),!1):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 n=this.pdfDocument.getPage(e.id).then((function(n){return e.pdfPage||e.setPdfPage(n),t._pagesRequests.delete(e),n})).catch((function(n){console.error("Unable to get page for page view",n),t._pagesRequests.delete(e)}));return this._pagesRequests.set(e,n),n}},{key:"forceRendering",value:function(e){var t=this,n=e||this._getVisiblePages(),r=this.renderingQueue.getHighestPriority(n,this._pages,this._isScrollModeHorizontal?this.scroll.right:this.scroll.down);return!!r&&(this._ensurePdfPageLoaded(r).then((function(){t.renderingQueue.renderView(r)})),!0)}},{key:"createTextLayerBuilder",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4?arguments[4]:void 0;return new u.TextLayerBuilder({textLayerDiv:e,eventBus:i,pageIndex:t,viewport:n,findController:this.isInPresentationMode?null:this.findController,enhanceTextSelection:!this.isInPresentationMode&&r})}},{key:"createAnnotationLayerBuilder",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:r.NullL10n;return new o.AnnotationLayerBuilder({pageDiv:e,pdfPage:t,imageResourcesPath:n,renderInteractiveForms:i,linkService:this.linkService,downloadManager:this.downloadManager,l10n:s})}},{key:"getPagesOverview",value:function(){var e=this._pages.map((function(e){var t=e.pdfPage.getViewport({scale:1});return{width:t.width,height:t.height,rotation:t.rotation}}));if(!this.enablePrintAutoRotate)return e;var t=(0,r.isPortraitOrientation)(e[0]);return e.map((function(e){return t===(0,r.isPortraitOrientation)(e)?e:{width:e.height,height:e.width,rotation:(e.rotation+90)%360}}))}},{key:"_updateScrollMode",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this._scrollMode,n=this.viewer;n.classList.toggle("scrollHorizontal",t===r.ScrollMode.HORIZONTAL),n.classList.toggle("scrollWrapped",t===r.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=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(this.pdfDocument){var t=this.viewer,n=this._pages;if(t.textContent="",this._spreadMode===r.SpreadMode.NONE)for(var i=0,o=n.length;i<o;++i)t.appendChild(n[i].div);else for(var s=this._spreadMode-1,a=null,l=0,u=n.length;l<u;++l)null===a?((a=document.createElement("div")).className="spread",t.appendChild(a)):l%2===s&&(a=a.cloneNode(!1),t.appendChild(a)),a.appendChild(n[l].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)||console.error("".concat(this._name,'.currentPageNumber: "').concat(e,'" is not a valid page.')))}},{key:"currentPageLabel",get:function(){return this._pageLabels&&this._pageLabels[this._currentPageNumber-1]},set:function(e){if(this.pdfDocument){var t=0|e;if(this._pageLabels){var n=this._pageLabels.indexOf(e);n>=0&&(t=n+1)}this._setCurrentPageNumber(t,!0)||console.error("".concat(this._name,'.currentPageLabel: "').concat(e,'" is not a valid page.'))}}},{key:"currentScale",get:function(){return this._currentScale!==r.UNKNOWN_SCALE?this._currentScale:r.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,r.isValidRotation)(e))throw new Error("Invalid pages rotation angle.");if(this.pdfDocument&&this._pagesRotation!==e){this._pagesRotation=e;for(var t=this._currentPageNumber,n=0,i=this._pages.length;n<i;n++){var o=this._pages[n];o.update(o.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===r.ScrollMode.HORIZONTAL}},{key:"isInPresentationMode",get:function(){return this.presentationModeState===r.PresentationModeState.FULLSCREEN}},{key:"isChangingPresentationMode",get:function(){return this.presentationModeState===r.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,n=this._pages.length;t<n;++t){var r=this._pages[t];if(r.width!==e.width||r.height!==e.height)return!1}return!0}},{key:"scrollMode",get:function(){return this._scrollMode},set:function(e){if(this._scrollMode!==e){if(!(0,r.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,r.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)}}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PDFViewer=void 0;var r=n(19),i=n(2);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){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t,n){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}t.PDFViewer=function(e){!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)}(d,e);var t,n,r,o=(n=d,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}}(),function(){var e,t=h(n);if(r){var i=h(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return c(this,e)});function d(){return a(this,d),o.apply(this,arguments)}return(t=[{key:"_scrollIntoView",value:function(e){var t=e.pageDiv,n=e.pageSpot,r=void 0===n?null:n,i=e.pageNumber,o=void 0===i?null:i;if(!r&&!this.isInPresentationMode){var s=t.offsetLeft+t.clientLeft,a=this.container,u=a.scrollLeft;(this._isScrollModeHorizontal||s<u||s+t.clientWidth>u+a.clientWidth)&&(r={left:0,top:0})}l(h(d.prototype),"_scrollIntoView",this).call(this,{pageDiv:t,pageSpot:r,pageNumber:o})}},{key:"_getVisiblePages",value:function(){return this.isInPresentationMode?this._getCurrentVisiblePage():l(h(d.prototype),"_getVisiblePages",this).call(this)}},{key:"_updateHelper",value:function(e){if(!this.isInPresentationMode){var t,n=this._currentPageNumber,r=!1,i=function(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw o}}}}(e);try{for(i.s();!(t=i.n()).done;){var o=t.value;if(o.percent<100)break;if(o.id===n){r=!0;break}}}catch(a){i.e(a)}finally{i.f()}r||(n=e[0].id),this._setCurrentPageNumber(n)}}},{key:"_viewerElement",get:function(){return(0,i.shadow)(this,"_viewerElement",this.viewer)}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(d.prototype,t),d}(r.BaseViewer)}])},e.exports=r()},zUnb:function(e,t,n){"use strict";function r(e){return"function"==typeof e}n.r(t);let i=!1;const o={Promise:void 0,set useDeprecatedSynchronousErrorHandling(e){if(e){const e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else i&&console.log("RxJS: Back to a better error behavior. Thank you. <3");i=e},get useDeprecatedSynchronousErrorHandling(){return i}};function s(e){setTimeout(()=>{throw e},0)}const a={closed:!0,next(e){},error(e){if(o.useDeprecatedSynchronousErrorHandling)throw e;s(e)},complete(){}},l=(()=>Array.isArray||(e=>e&&"number"==typeof e.length))();function u(e){return null!==e&&"object"==typeof e}const c=(()=>{function e(e){return Error.call(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((e,t)=>`${t+1}) ${e.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e,this}return e.prototype=Object.create(Error.prototype),e})();let h=(()=>{class e{constructor(e){this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._ctorUnsubscribe=!0,this._unsubscribe=e)}unsubscribe(){let t;if(this.closed)return;let{_parentOrParents:n,_ctorUnsubscribe:i,_unsubscribe:o,_subscriptions:s}=this;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,n instanceof e)n.remove(this);else if(null!==n)for(let e=0;e<n.length;++e)n[e].remove(this);if(r(o)){i&&(this._unsubscribe=void 0);try{o.call(this)}catch(a){t=a instanceof c?d(a.errors):[a]}}if(l(s)){let e=-1,n=s.length;for(;++e<n;){const n=s[e];if(u(n))try{n.unsubscribe()}catch(a){t=t||[],a instanceof c?t=t.concat(d(a.errors)):t.push(a)}}}if(t)throw new c(t)}add(t){let n=t;if(!t)return e.EMPTY;switch(typeof t){case"function":n=new e(t);case"object":if(n===this||n.closed||"function"!=typeof n.unsubscribe)return n;if(this.closed)return n.unsubscribe(),n;if(!(n instanceof e)){const t=n;n=new e,n._subscriptions=[t]}break;default:throw new Error("unrecognized teardown "+t+" added to Subscription.")}let{_parentOrParents:r}=n;if(null===r)n._parentOrParents=this;else if(r instanceof e){if(r===this)return n;n._parentOrParents=[r,this]}else{if(-1!==r.indexOf(this))return n;r.push(this)}const i=this._subscriptions;return null===i?this._subscriptions=[n]:i.push(n),n}remove(e){const t=this._subscriptions;if(t){const n=t.indexOf(e);-1!==n&&t.splice(n,1)}}}return e.EMPTY=function(e){return e.closed=!0,e}(new e),e})();function d(e){return e.reduce((e,t)=>e.concat(t instanceof c?t.errors:t),[])}const f=(()=>"function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random())();class p extends h{constructor(e,t,n){switch(super(),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=a;break;case 1:if(!e){this.destination=a;break}if("object"==typeof e){e instanceof p?(this.syncErrorThrowable=e.syncErrorThrowable,this.destination=e,e.add(this)):(this.syncErrorThrowable=!0,this.destination=new g(this,e));break}default:this.syncErrorThrowable=!0,this.destination=new g(this,e,t,n)}}[f](){return this}static create(e,t,n){const r=new p(e,t,n);return r.syncErrorThrowable=!1,r}next(e){this.isStopped||this._next(e)}error(e){this.isStopped||(this.isStopped=!0,this._error(e))}complete(){this.isStopped||(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe())}_next(e){this.destination.next(e)}_error(e){this.destination.error(e),this.unsubscribe()}_complete(){this.destination.complete(),this.unsubscribe()}_unsubscribeAndRecycle(){const{_parentOrParents:e}=this;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=e,this}}class g extends p{constructor(e,t,n,i){let o;super(),this._parentSubscriber=e;let s=this;r(t)?o=t:t&&(o=t.next,n=t.error,i=t.complete,t!==a&&(s=Object.create(t),r(s.unsubscribe)&&this.add(s.unsubscribe.bind(s)),s.unsubscribe=this.unsubscribe.bind(this))),this._context=s,this._next=o,this._error=n,this._complete=i}next(e){if(!this.isStopped&&this._next){const{_parentSubscriber:t}=this;o.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}}error(e){if(!this.isStopped){const{_parentSubscriber:t}=this,{useDeprecatedSynchronousErrorHandling:n}=o;if(this._error)n&&t.syncErrorThrowable?(this.__tryOrSetError(t,this._error,e),this.unsubscribe()):(this.__tryOrUnsub(this._error,e),this.unsubscribe());else if(t.syncErrorThrowable)n?(t.syncErrorValue=e,t.syncErrorThrown=!0):s(e),this.unsubscribe();else{if(this.unsubscribe(),n)throw e;s(e)}}}complete(){if(!this.isStopped){const{_parentSubscriber:e}=this;if(this._complete){const t=()=>this._complete.call(this._context);o.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,t),this.unsubscribe()):(this.__tryOrUnsub(t),this.unsubscribe())}else this.unsubscribe()}}__tryOrUnsub(e,t){try{e.call(this._context,t)}catch(n){if(this.unsubscribe(),o.useDeprecatedSynchronousErrorHandling)throw n;s(n)}}__tryOrSetError(e,t,n){if(!o.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{t.call(this._context,n)}catch(r){return o.useDeprecatedSynchronousErrorHandling?(e.syncErrorValue=r,e.syncErrorThrown=!0,!0):(s(r),!0)}return!1}_unsubscribe(){const{_parentSubscriber:e}=this;this._context=null,this._parentSubscriber=null,e.unsubscribe()}}const y=(()=>"function"==typeof Symbol&&Symbol.observable||"@@observable")();function m(e){return e}let v=(()=>{class e{constructor(e){this._isScalar=!1,e&&(this._subscribe=e)}lift(t){const n=new e;return n.source=this,n.operator=t,n}subscribe(e,t,n){const{operator:r}=this,i=function(e,t,n){if(e){if(e instanceof p)return e;if(e[f])return e[f]()}return e||t||n?new p(e,t,n):new p(a)}(e,t,n);if(i.add(r?r.call(i,this.source):this.source||o.useDeprecatedSynchronousErrorHandling&&!i.syncErrorThrowable?this._subscribe(i):this._trySubscribe(i)),o.useDeprecatedSynchronousErrorHandling&&i.syncErrorThrowable&&(i.syncErrorThrowable=!1,i.syncErrorThrown))throw i.syncErrorValue;return i}_trySubscribe(e){try{return this._subscribe(e)}catch(t){o.useDeprecatedSynchronousErrorHandling&&(e.syncErrorThrown=!0,e.syncErrorValue=t),function(e){for(;e;){const{closed:t,destination:n,isStopped:r}=e;if(t||r)return!1;e=n&&n instanceof p?n:null}return!0}(e)?e.error(t):console.warn(t)}}forEach(e,t){return new(t=_(t))((t,n)=>{let r;r=this.subscribe(t=>{try{e(t)}catch(i){n(i),r&&r.unsubscribe()}},n,t)})}_subscribe(e){const{source:t}=this;return t&&t.subscribe(e)}[y](){return this}pipe(...e){return 0===e.length?this:(0===(t=e).length?m:1===t.length?t[0]:function(e){return t.reduce((e,t)=>t(e),e)})(this);var t}toPromise(e){return new(e=_(e))((e,t)=>{let n;this.subscribe(e=>n=e,e=>t(e),()=>e(n))})}}return e.create=t=>new e(t),e})();function _(e){if(e||(e=o.Promise||Promise),!e)throw new Error("no Promise impl found");return e}const b=(()=>{function e(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return e.prototype=Object.create(Error.prototype),e})();class w extends h{constructor(e,t){super(),this.subject=e,this.subscriber=t,this.closed=!1}unsubscribe(){if(this.closed)return;this.closed=!0;const e=this.subject,t=e.observers;if(this.subject=null,!t||0===t.length||e.isStopped||e.closed)return;const n=t.indexOf(this.subscriber);-1!==n&&t.splice(n,1)}}class A extends p{constructor(e){super(e),this.destination=e}}let S=(()=>{class e extends v{constructor(){super(),this.observers=[],this.closed=!1,this.isStopped=!1,this.hasError=!1,this.thrownError=null}[f](){return new A(this)}lift(e){const t=new k(this,this);return t.operator=e,t}next(e){if(this.closed)throw new b;if(!this.isStopped){const{observers:t}=this,n=t.length,r=t.slice();for(let i=0;i<n;i++)r[i].next(e)}}error(e){if(this.closed)throw new b;this.hasError=!0,this.thrownError=e,this.isStopped=!0;const{observers:t}=this,n=t.length,r=t.slice();for(let i=0;i<n;i++)r[i].error(e);this.observers.length=0}complete(){if(this.closed)throw new b;this.isStopped=!0;const{observers:e}=this,t=e.length,n=e.slice();for(let r=0;r<t;r++)n[r].complete();this.observers.length=0}unsubscribe(){this.isStopped=!0,this.closed=!0,this.observers=null}_trySubscribe(e){if(this.closed)throw new b;return super._trySubscribe(e)}_subscribe(e){if(this.closed)throw new b;return this.hasError?(e.error(this.thrownError),h.EMPTY):this.isStopped?(e.complete(),h.EMPTY):(this.observers.push(e),new w(this,e))}asObservable(){const e=new v;return e.source=this,e}}return e.create=(e,t)=>new k(e,t),e})();class k extends S{constructor(e,t){super(),this.destination=e,this.source=t}next(e){const{destination:t}=this;t&&t.next&&t.next(e)}error(e){const{destination:t}=this;t&&t.error&&this.destination.error(e)}complete(){const{destination:e}=this;e&&e.complete&&this.destination.complete()}_subscribe(e){const{source:t}=this;return t?this.source.subscribe(e):h.EMPTY}}function x(e){return e&&"function"==typeof e.schedule}function C(e,t){return function(n){if("function"!=typeof e)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return n.lift(new P(e,t))}}class P{constructor(e,t){this.project=e,this.thisArg=t}call(e,t){return t.subscribe(new E(e,this.project,this.thisArg))}}class E extends p{constructor(e,t,n){super(e),this.project=t,this.count=0,this.thisArg=n||this}_next(e){let t;try{t=this.project.call(this.thisArg,e,this.count++)}catch(n){return void this.destination.error(n)}this.destination.next(t)}}const T=e=>t=>{for(let n=0,r=e.length;n<r&&!t.closed;n++)t.next(e[n]);t.complete()};function R(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}const O=R(),I=e=>e&&"number"==typeof e.length&&"function"!=typeof e;function L(e){return!!e&&"function"!=typeof e.subscribe&&"function"==typeof e.then}const M=e=>{if(e&&"function"==typeof e[y])return r=e,e=>{const t=r[y]();if("function"!=typeof t.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return t.subscribe(e)};if(I(e))return T(e);if(L(e))return n=e,e=>(n.then(t=>{e.closed||(e.next(t),e.complete())},t=>e.error(t)).then(null,s),e);if(e&&"function"==typeof e[O])return t=e,e=>{const n=t[O]();for(;;){let t;try{t=n.next()}catch(r){return e.error(r),e}if(t.done){e.complete();break}if(e.next(t.value),e.closed)break}return"function"==typeof n.return&&e.add(()=>{n.return&&n.return()}),e};{const t=u(e)?"an invalid object":`'${e}'`;throw new TypeError(`You provided ${t} where a stream was expected. You can provide an Observable, Promise, Array, or Iterable.`)}var t,n,r};function N(e,t){return new v(n=>{const r=new h;let i=0;return r.add(t.schedule((function(){i!==e.length?(n.next(e[i++]),n.closed||r.add(this.schedule())):n.complete()}))),r})}function D(e,t){return t?function(e,t){if(null!=e){if(function(e){return e&&"function"==typeof e[y]}(e))return function(e,t){return new v(n=>{const r=new h;return r.add(t.schedule(()=>{const i=e[y]();r.add(i.subscribe({next(e){r.add(t.schedule(()=>n.next(e)))},error(e){r.add(t.schedule(()=>n.error(e)))},complete(){r.add(t.schedule(()=>n.complete()))}}))})),r})}(e,t);if(L(e))return function(e,t){return new v(n=>{const r=new h;return r.add(t.schedule(()=>e.then(e=>{r.add(t.schedule(()=>{n.next(e),r.add(t.schedule(()=>n.complete()))}))},e=>{r.add(t.schedule(()=>n.error(e)))}))),r})}(e,t);if(I(e))return N(e,t);if(function(e){return e&&"function"==typeof e[O]}(e)||"string"==typeof e)return function(e,t){if(!e)throw new Error("Iterable cannot be null");return new v(n=>{const r=new h;let i;return r.add(()=>{i&&"function"==typeof i.return&&i.return()}),r.add(t.schedule(()=>{i=e[O](),r.add(t.schedule((function(){if(n.closed)return;let e,t;try{const n=i.next();e=n.value,t=n.done}catch(r){return void n.error(r)}t?n.complete():(n.next(e),this.schedule())})))})),r})}(e,t)}throw new TypeError((null!==e&&typeof e||e)+" is not observable")}(e,t):e instanceof v?e:new v(M(e))}class F extends p{constructor(e){super(),this.parent=e}_next(e){this.parent.notifyNext(e)}_error(e){this.parent.notifyError(e),this.unsubscribe()}_complete(){this.parent.notifyComplete(),this.unsubscribe()}}class j extends p{notifyNext(e){this.destination.next(e)}notifyError(e){this.destination.error(e)}notifyComplete(){this.destination.complete()}}function B(e,t){if(!t.closed)return e instanceof v?e.subscribe(t):M(e)(t)}class q{constructor(e,t=Number.POSITIVE_INFINITY){this.project=e,this.concurrent=t}call(e,t){return t.subscribe(new V(e,this.project,this.concurrent))}}class V extends j{constructor(e,t,n=Number.POSITIVE_INFINITY){super(e),this.project=t,this.concurrent=n,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(e){this.active<this.concurrent?this._tryNext(e):this.buffer.push(e)}_tryNext(e){let t;const n=this.index++;try{t=this.project(e,n)}catch(r){return void this.destination.error(r)}this.active++,this._innerSub(t)}_innerSub(e){const t=new F(this),n=this.destination;n.add(t);const r=B(e,t);r!==t&&n.add(r)}_complete(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}notifyNext(e){this.destination.next(e)}notifyComplete(){const e=this.buffer;this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function U(e,t){return t?N(e,t):new v(T(e))}function H(...e){let t=Number.POSITIVE_INFINITY,n=null,r=e[e.length-1];return x(r)?(n=e.pop(),e.length>1&&"number"==typeof e[e.length-1]&&(t=e.pop())):"number"==typeof r&&(t=e.pop()),null===n&&1===e.length&&e[0]instanceof v?e[0]:function(e=Number.POSITIVE_INFINITY){return function e(t,n,r=Number.POSITIVE_INFINITY){return"function"==typeof n?i=>i.pipe(e((e,r)=>D(t(e,r)).pipe(C((t,i)=>n(e,t,r,i))),r)):("number"==typeof n&&(r=n),e=>e.lift(new q(t,r)))}(m,e)}(t)(U(e,n))}function W(){return function(e){return e.lift(new z(e))}}class z{constructor(e){this.connectable=e}call(e,t){const{connectable:n}=this;n._refCount++;const r=new G(e,n),i=t.subscribe(r);return r.closed||(r.connection=n.connect()),i}}class G extends p{constructor(e,t){super(e),this.connectable=t}_unsubscribe(){const{connectable:e}=this;if(!e)return void(this.connection=null);this.connectable=null;const t=e._refCount;if(t<=0)return void(this.connection=null);if(e._refCount=t-1,t>1)return void(this.connection=null);const{connection:n}=this,r=e._connection;this.connection=null,!r||n&&r!==n||r.unsubscribe()}}class Q extends v{constructor(e,t){super(),this.source=e,this.subjectFactory=t,this._refCount=0,this._isComplete=!1}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){const e=this._subject;return e&&!e.isStopped||(this._subject=this.subjectFactory()),this._subject}connect(){let e=this._connection;return e||(this._isComplete=!1,e=this._connection=new h,e.add(this.source.subscribe(new K(this.getSubject(),this))),e.closed&&(this._connection=null,e=h.EMPTY)),e}refCount(){return W()(this)}}const Y=(()=>{const e=Q.prototype;return{operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:e._subscribe},_isComplete:{value:e._isComplete,writable:!0},getSubject:{value:e.getSubject},connect:{value:e.connect},refCount:{value:e.refCount}}})();class K extends A{constructor(e,t){super(e),this.connectable=t}_error(e){this._unsubscribe(),super._error(e)}_complete(){this.connectable._isComplete=!0,this._unsubscribe(),super._complete()}_unsubscribe(){const e=this.connectable;if(e){this.connectable=null;const t=e._connection;e._refCount=0,e._subject=null,e._connection=null,t&&t.unsubscribe()}}}function X(){return new S}function Z(e){return{toString:e}.toString()}const J="__parameters__";function $(e,t,n){return Z(()=>{const r=function(e){return function(...t){if(e){const n=e(...t);for(const e in n)this[e]=n[e]}}}(t);function i(...e){if(this instanceof i)return r.apply(this,e),this;const t=new i(...e);return n.annotation=t,n;function n(e,n,r){const i=e.hasOwnProperty(J)?e[J]:Object.defineProperty(e,J,{value:[]})[J];for(;i.length<=r;)i.push(null);return(i[r]=i[r]||[]).push(t),e}}return n&&(i.prototype=Object.create(n.prototype)),i.prototype.ngMetadataName=e,i.annotationCls=i,i})}const ee=$("Inject",e=>({token:e})),te=$("Optional"),ne=$("Self"),re=$("SkipSelf");var ie=function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e}({});function oe(e){for(let t in e)if(e[t]===oe)return t;throw Error("Could not find renamed property on target object.")}function se(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function ae(e){return{factory:e.factory,providers:e.providers||[],imports:e.imports||[]}}function le(e){return ue(e,e[he])||ue(e,e[pe])}function ue(e,t){return t&&t.token===e?t:null}function ce(e){return e&&(e.hasOwnProperty(de)||e.hasOwnProperty(ge))?e[de]:null}const he=oe({"\u0275prov":oe}),de=oe({"\u0275inj":oe}),fe=oe({"\u0275provFallback":oe}),pe=oe({ngInjectableDef:oe}),ge=oe({ngInjectorDef:oe});function ye(e){if("string"==typeof e)return e;if(Array.isArray(e))return"["+e.map(ye).join(", ")+"]";if(null==e)return""+e;if(e.overriddenName)return""+e.overriddenName;if(e.name)return""+e.name;const t=e.toString();if(null==t)return""+t;const n=t.indexOf("\n");return-1===n?t:t.substring(0,n)}function me(e,t){return null==e||""===e?null===t?"":t:null==t||""===t?e:e+" "+t}const ve=oe({__forward_ref__:oe});function _e(e){return e.__forward_ref__=_e,e.toString=function(){return ye(this())},e}function be(e){return"function"==typeof(t=e)&&t.hasOwnProperty(ve)&&t.__forward_ref__===_e?e():e;var t}const we="undefined"!=typeof globalThis&&globalThis,Ae="undefined"!=typeof window&&window,Se="undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,ke="undefined"!=typeof global&&global,xe=we||ke||Ae||Se,Ce=oe({"\u0275cmp":oe}),Pe=oe({"\u0275dir":oe}),Ee=oe({"\u0275pipe":oe}),Te=oe({"\u0275mod":oe}),Re=oe({"\u0275loc":oe}),Oe=oe({"\u0275fac":oe}),Ie=oe({__NG_ELEMENT_ID__:oe});class Le{constructor(e,t){this._desc=e,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof t?this.__NG_ELEMENT_ID__=t:void 0!==t&&(this.\u0275prov=se({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}toString(){return"InjectionToken "+this._desc}}const Me=new Le("INJECTOR",-1),Ne={},De=/\n/gm,Fe="__source",je=oe({provide:String,useValue:oe});let Be,qe=void 0;function Ve(e){const t=qe;return qe=e,t}function Ue(e){const t=Be;return Be=e,t}function He(e,t=ie.Default){if(void 0===qe)throw new Error("inject() must be called from an injection context");return null===qe?ze(e,void 0,t):qe.get(e,t&ie.Optional?null:void 0,t)}function We(e,t=ie.Default){return(Be||He)(be(e),t)}function ze(e,t,n){const r=le(e);if(r&&"root"==r.providedIn)return void 0===r.value?r.value=r.factory():r.value;if(n&ie.Optional)return null;if(void 0!==t)return t;throw new Error(`Injector: NOT_FOUND [${ye(e)}]`)}function Ge(e){const t=[];for(let n=0;n<e.length;n++){const r=be(e[n]);if(Array.isArray(r)){if(0===r.length)throw new Error("Arguments array must have arguments.");let e=void 0,n=ie.Default;for(let t=0;t<r.length;t++){const i=r[t];i instanceof te||"Optional"===i.ngMetadataName||i===te?n|=ie.Optional:i instanceof re||"SkipSelf"===i.ngMetadataName||i===re?n|=ie.SkipSelf:i instanceof ne||"Self"===i.ngMetadataName||i===ne?n|=ie.Self:e=i instanceof ee||i===ee?i.token:i}t.push(We(e,n))}else t.push(We(r))}return t}class Qe{get(e,t=Ne){if(t===Ne){const t=new Error(`NullInjectorError: No provider for ${ye(e)}!`);throw t.name="NullInjectorError",t}return t}}class Ye{}function Ke(e,t){e.forEach(e=>Array.isArray(e)?Ke(e,t):t(e))}function Xe(e,t,n){t>=e.length?e.push(n):e.splice(t,0,n)}function Ze(e,t){return t>=e.length-1?e.pop():e.splice(t,1)[0]}var Je=function(e){return e[e.OnPush=0]="OnPush",e[e.Default=1]="Default",e}({}),$e=function(e){return e[e.Emulated=0]="Emulated",e[e.Native=1]="Native",e[e.None=2]="None",e[e.ShadowDom=3]="ShadowDom",e}({});const et={},tt=[];let nt=0;function rt(e){return Z(()=>{const t={},n={type:e.type,providersResolver:null,decls:e.decls,vars:e.vars,factory:null,template:e.template||null,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:t,inputs:null,outputs:null,exportAs:e.exportAs||null,onPush:e.changeDetection===Je.OnPush,directiveDefs:null,pipeDefs:null,selectors:e.selectors||tt,viewQuery:e.viewQuery||null,features:e.features||null,data:e.data||{},encapsulation:e.encapsulation||$e.Emulated,id:"c",styles:e.styles||tt,_:null,setInput:null,schemas:e.schemas||null,tView:null},r=e.directives,i=e.features,o=e.pipes;return n.id+=nt++,n.inputs=lt(e.inputs,t),n.outputs=lt(e.outputs),i&&i.forEach(e=>e(n)),n.directiveDefs=r?()=>("function"==typeof r?r():r).map(it):null,n.pipeDefs=o?()=>("function"==typeof o?o():o).map(ot):null,n})}function it(e){return ut(e)||function(e){return e[Pe]||null}(e)}function ot(e){return function(e){return e[Ee]||null}(e)}const st={};function at(e){const t={type:e.type,bootstrap:e.bootstrap||tt,declarations:e.declarations||tt,imports:e.imports||tt,exports:e.exports||tt,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null};return null!=e.id&&Z(()=>{st[e.id]=e.type}),t}function lt(e,t){if(null==e)return et;const n={};for(const r in e)if(e.hasOwnProperty(r)){let i=e[r],o=i;Array.isArray(i)&&(o=i[1],i=i[0]),n[i]=r,t&&(t[i]=o)}return n}function ut(e){return e[Ce]||null}function ct(e,t){return e.hasOwnProperty(Oe)?e[Oe]:null}function ht(e,t){const n=e[Te]||null;if(!n&&!0===t)throw new Error(`Type ${ye(e)} does not have '\u0275mod' property.`);return n}const dt=20,ft=10;function pt(e){return Array.isArray(e)&&"object"==typeof e[1]}function gt(e){return Array.isArray(e)&&!0===e[1]}function yt(e){return 0!=(8&e.flags)}function mt(e){return 2==(2&e.flags)}function vt(e){return 1==(1&e.flags)}function _t(e){return null!==e.template}function bt(e){return 0!=(512&e[2])}class wt{constructor(e,t,n){this.previousValue=e,this.currentValue=t,this.firstChange=n}isFirstChange(){return this.firstChange}}function At(){return St}function St(e){return e.type.prototype.ngOnChanges&&(e.setInput=xt),kt}function kt(){const e=Ct(this),t=null==e?void 0:e.current;if(t){const n=e.previous;if(n===et)e.previous=t;else for(let e in t)n[e]=t[e];e.current=null,this.ngOnChanges(t)}}function xt(e,t,n,r){const i=Ct(e)||function(e,t){return e.__ngSimpleChanges__=t}(e,{previous:et,current:null}),o=i.current||(i.current={}),s=i.previous,a=this.declaredInputs[n],l=s[a];o[a]=new wt(l&&l.currentValue,t,s===et),e[r]=t}function Ct(e){return e.__ngSimpleChanges__||null}At.ngInherit=!0;let Pt=void 0;function Et(e){return!!e.listen}const Tt={createRenderer:(e,t)=>void 0!==Pt?Pt:"undefined"!=typeof document?document:void 0};function Rt(e){for(;Array.isArray(e);)e=e[0];return e}function Ot(e,t){return Rt(t[e.index])}function It(e,t){return e.data[t+dt]}function Lt(e,t){const n=t[e];return pt(n)?n:n[0]}function Mt(e){const t=function(e){return e.__ngContext__||null}(e);return t?Array.isArray(t)?t:t.lView:null}function Nt(e){return 4==(4&e[2])}function Dt(e){return 128==(128&e[2])}function Ft(e,t){return null===e||null==t?null:e[t]}function jt(e){e[18]=0}function Bt(e,t){e[5]+=t;let n=e,r=e[3];for(;null!==r&&(1===t&&1===n[5]||-1===t&&0===n[5]);)r[5]+=t,n=r,r=r[3]}const qt={lFrame:nn(null),bindingsEnabled:!0,checkNoChangesMode:!1};function Vt(){return qt.bindingsEnabled}function Ut(){return qt.lFrame.lView}function Ht(){return qt.lFrame.tView}function Wt(){return qt.lFrame.previousOrParentTNode}function zt(e,t){qt.lFrame.previousOrParentTNode=e,qt.lFrame.isParent=t}function Gt(){return qt.lFrame.isParent}function Qt(){return qt.checkNoChangesMode}function Yt(e){qt.checkNoChangesMode=e}function Kt(e,t){const n=qt.lFrame;n.bindingIndex=n.bindingRootIndex=e,Xt(t)}function Xt(e){qt.lFrame.currentDirectiveIndex=e}function Zt(){return qt.lFrame.currentQueryIndex}function Jt(e){qt.lFrame.currentQueryIndex=e}function $t(e,t){const n=tn();qt.lFrame=n,n.previousOrParentTNode=t,n.lView=e}function en(e,t){const n=tn(),r=e[1];qt.lFrame=n,n.previousOrParentTNode=t,n.lView=e,n.tView=r,n.contextLView=e,n.bindingIndex=r.bindingStartIndex}function tn(){const e=qt.lFrame,t=null===e?null:e.child;return null===t?nn(e):t}function nn(e){const t={previousOrParentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:0,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null};return null!==e&&(e.child=t),t}function rn(){const e=qt.lFrame;return qt.lFrame=e.parent,e.previousOrParentTNode=null,e.lView=null,e}const on=rn;function sn(){const e=rn();e.isParent=!0,e.tView=null,e.selectedIndex=0,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function an(e){qt.lFrame.selectedIndex=e}function ln(e,t){for(let n=t.directiveStart,r=t.directiveEnd;n<r;n++){const t=e.data[n].type.prototype,{ngAfterContentInit:r,ngAfterContentChecked:i,ngAfterViewInit:o,ngAfterViewChecked:s,ngOnDestroy:a}=t;r&&(e.contentHooks||(e.contentHooks=[])).push(-n,r),i&&((e.contentHooks||(e.contentHooks=[])).push(n,i),(e.contentCheckHooks||(e.contentCheckHooks=[])).push(n,i)),o&&(e.viewHooks||(e.viewHooks=[])).push(-n,o),s&&((e.viewHooks||(e.viewHooks=[])).push(n,s),(e.viewCheckHooks||(e.viewCheckHooks=[])).push(n,s)),null!=a&&(e.destroyHooks||(e.destroyHooks=[])).push(n,a)}}function un(e,t,n){dn(e,t,3,n)}function cn(e,t,n,r){(3&e[2])===n&&dn(e,t,n,r)}function hn(e,t){let n=e[2];(3&n)===t&&(n&=2047,n+=1,e[2]=n)}function dn(e,t,n,r){const i=null!=r?r:-1;let o=0;for(let s=void 0!==r?65535&e[18]:0;s<t.length;s++)if("number"==typeof t[s+1]){if(o=t[s],null!=r&&o>=r)break}else t[s]<0&&(e[18]+=65536),(o<i||-1==i)&&(fn(e,n,t,s),e[18]=(4294901760&e[18])+s+2),s++}function fn(e,t,n,r){const i=n[r]<0,o=n[r+1],s=e[i?-n[r]:n[r]];i?e[2]>>11<e[18]>>16&&(3&e[2])===t&&(e[2]+=2048,o.call(s)):o.call(s)}class pn{constructor(e,t,n){this.factory=e,this.resolving=!1,this.canSeeViewProviders=t,this.injectImpl=n}}function gn(e,t,n){const r=Et(e);let i=0;for(;i<n.length;){const o=n[i];if("number"==typeof o){if(0!==o)break;i++;const s=n[i++],a=n[i++],l=n[i++];r?e.setAttribute(t,a,l,s):t.setAttributeNS(s,a,l)}else{const s=o,a=n[++i];yn(s)?r&&e.setProperty(t,s,a):r?e.setAttribute(t,s,a):t.setAttribute(s,a),i++}}return i}function yn(e){return 64===e.charCodeAt(0)}function mn(e,t){if(null===t||0===t.length);else if(null===e||0===e.length)e=t.slice();else{let n=-1;for(let r=0;r<t.length;r++){const i=t[r];"number"==typeof i?n=i:0===n||vn(e,n,i,null,-1===n||2===n?t[++r]:null)}}return e}function vn(e,t,n,r,i){let o=0,s=e.length;if(-1===t)s=-1;else for(;o<e.length;){const n=e[o++];if("number"==typeof n){if(n===t){s=-1;break}if(n>t){s=o-1;break}}}for(;o<e.length;){const t=e[o];if("number"==typeof t)break;if(t===n){if(null===r)return void(null!==i&&(e[o+1]=i));if(r===e[o+1])return void(e[o+2]=i)}o++,null!==r&&o++,null!==i&&o++}-1!==s&&(e.splice(s,0,t),o=s+1),e.splice(o++,0,n),null!==r&&e.splice(o++,0,r),null!==i&&e.splice(o++,0,i)}function _n(e){return-1!==e}function bn(e){return 32767&e}function wn(e){return e>>16}function An(e,t){let n=wn(e),r=t;for(;n>0;)r=r[15],n--;return r}function Sn(e){return"function"==typeof e?e.name||e.toString():"object"==typeof e&&null!=e&&"function"==typeof e.type?e.type.name||e.type.toString():function(e){return"string"==typeof e?e:null==e?"":""+e}(e)}const kn=(()=>("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(xe))();function xn(e){return{name:"window",target:e.ownerDocument.defaultView}}function Cn(e){return e instanceof Function?e():e}let Pn=!0;function En(e){const t=Pn;return Pn=e,t}let Tn=0;function Rn(e,t){const n=In(e,t);if(-1!==n)return n;const r=t[1];r.firstCreatePass&&(e.injectorIndex=t.length,On(r.data,e),On(t,null),On(r.blueprint,null));const i=Ln(e,t),o=e.injectorIndex;if(_n(i)){const e=bn(i),n=An(i,t),r=n[1].data;for(let i=0;i<8;i++)t[o+i]=n[e+i]|r[e+i]}return t[o+8]=i,o}function On(e,t){e.push(0,0,0,0,0,0,0,0,t)}function In(e,t){return-1===e.injectorIndex||e.parent&&e.parent.injectorIndex===e.injectorIndex||null==t[e.injectorIndex+8]?-1:e.injectorIndex}function Ln(e,t){if(e.parent&&-1!==e.parent.injectorIndex)return e.parent.injectorIndex;let n=t[6],r=1;for(;n&&-1===n.injectorIndex;)n=(t=t[15])?t[6]:null,r++;return n?n.injectorIndex|r<<16:-1}function Mn(e,t,n){!function(e,t,n){let r;"string"==typeof n?r=n.charCodeAt(0)||0:n.hasOwnProperty(Ie)&&(r=n[Ie]),null==r&&(r=n[Ie]=Tn++);const i=255&r,o=1<<i,s=64&i,a=32&i,l=t.data;128&i?s?a?l[e+7]|=o:l[e+6]|=o:a?l[e+5]|=o:l[e+4]|=o:s?a?l[e+3]|=o:l[e+2]|=o:a?l[e+1]|=o:l[e]|=o}(e,t,n)}function Nn(e,t,n,r=ie.Default,i){if(null!==e){const i=function(e){if("string"==typeof e)return e.charCodeAt(0)||0;const t=e.hasOwnProperty(Ie)?e[Ie]:void 0;return"number"==typeof t&&t>0?255&t:t}(n);if("function"==typeof i){$t(t,e);try{const e=i();if(null!=e||r&ie.Optional)return e;throw new Error(`No provider for ${Sn(n)}!`)}finally{on()}}else if("number"==typeof i){if(-1===i)return new Un(e,t);let o=null,s=In(e,t),a=-1,l=r&ie.Host?t[16][6]:null;for((-1===s||r&ie.SkipSelf)&&(a=-1===s?Ln(e,t):t[s+8],Vn(r,!1)?(o=t[1],s=bn(a),t=An(a,t)):s=-1);-1!==s;){a=t[s+8];const e=t[1];if(qn(i,s,e.data)){const e=Fn(s,t,n,o,r,l);if(e!==Dn)return e}Vn(r,t[1].data[s+8]===l)&&qn(i,s,t)?(o=e,s=bn(a),t=An(a,t)):s=-1}}}if(r&ie.Optional&&void 0===i&&(i=null),0==(r&(ie.Self|ie.Host))){const e=t[9],o=Ue(void 0);try{return e?e.get(n,i,r&ie.Optional):ze(n,i,r&ie.Optional)}finally{Ue(o)}}if(r&ie.Optional)return i;throw new Error(`NodeInjector: NOT_FOUND [${Sn(n)}]`)}const Dn={};function Fn(e,t,n,r,i,o){const s=t[1],a=s.data[e+8],l=jn(a,s,n,null==r?mt(a)&&Pn:r!=s&&3===a.type,i&ie.Host&&o===a);return null!==l?Bn(t,s,l,a):Dn}function jn(e,t,n,r,i){const o=e.providerIndexes,s=t.data,a=1048575&o,l=e.directiveStart,u=o>>20,c=i?a+u:e.directiveEnd;for(let h=r?a:a+u;h<c;h++){const e=s[h];if(h<l&&n===e||h>=l&&e.type===n)return h}if(i){const e=s[l];if(e&&_t(e)&&e.type===n)return l}return null}function Bn(e,t,n,r){let i=e[n];const o=t.data;if(i instanceof pn){const s=i;if(s.resolving)throw new Error("Circular dep for "+Sn(o[n]));const a=En(s.canSeeViewProviders);let l;s.resolving=!0,s.injectImpl&&(l=Ue(s.injectImpl)),$t(e,r);try{i=e[n]=s.factory(void 0,o,e,r),t.firstCreatePass&&n>=r.directiveStart&&function(e,t,n){const{ngOnChanges:r,ngOnInit:i,ngDoCheck:o}=t.type.prototype;if(r){const r=St(t);(n.preOrderHooks||(n.preOrderHooks=[])).push(e,r),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(e,r)}i&&(n.preOrderHooks||(n.preOrderHooks=[])).push(0-e,i),o&&((n.preOrderHooks||(n.preOrderHooks=[])).push(e,o),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(e,o))}(n,o[n],t)}finally{s.injectImpl&&Ue(l),En(a),s.resolving=!1,on()}}return i}function qn(e,t,n){const r=64&e,i=32&e;let o;return o=128&e?r?i?n[t+7]:n[t+6]:i?n[t+5]:n[t+4]:r?i?n[t+3]:n[t+2]:i?n[t+1]:n[t],!!(o&1<<e)}function Vn(e,t){return!(e&ie.Self||e&ie.Host&&t)}class Un{constructor(e,t){this._tNode=e,this._lView=t}get(e,t){return Nn(this._tNode,this._lView,e,void 0,t)}}function Hn(e){return e.ngDebugContext}function Wn(e){return e.ngOriginalError}function zn(e,...t){e.error(...t)}class Gn{constructor(){this._console=console}handleError(e){const t=this._findOriginalError(e),n=this._findContext(e),r=function(e){return e.ngErrorLogger||zn}(e);r(this._console,"ERROR",e),t&&r(this._console,"ORIGINAL ERROR",t),n&&r(this._console,"ERROR CONTEXT",n)}_findContext(e){return e?Hn(e)?Hn(e):this._findContext(Wn(e)):null}_findOriginalError(e){let t=Wn(e);for(;t&&Wn(t);)t=Wn(t);return t}}let Qn=!0,Yn=!1;function Kn(){return Yn=!0,Qn}function Xn(e,t){e.__ngContext__=t}function Zn(e){throw new Error("Multiple components match node with tagname "+e.tagName)}function Jn(){throw new Error("Cannot mix multi providers and regular providers")}function $n(e,t,n){let r=e.length;for(;;){const i=e.indexOf(t,n);if(-1===i)return i;if(0===i||e.charCodeAt(i-1)<=32){const n=t.length;if(i+n===r||e.charCodeAt(i+n)<=32)return i}n=i+1}}const er="ng-template";function tr(e,t,n){let r=0;for(;r<e.length;){let i=e[r++];if(n&&"class"===i){if(i=e[r],-1!==$n(i.toLowerCase(),t,0))return!0}else if(1===i){for(;r<e.length&&"string"==typeof(i=e[r++]);)if(i.toLowerCase()===t)return!0;return!1}}return!1}function nr(e){return 0===e.type&&e.tagName!==er}function rr(e,t,n){return t===(0!==e.type||n?e.tagName:er)}function ir(e,t,n){let r=4;const i=e.attrs||[],o=function(e){for(let n=0;n<e.length;n++)if(3===(t=e[n])||4===t||6===t)return n;var t;return e.length}(i);let s=!1;for(let a=0;a<t.length;a++){const l=t[a];if("number"!=typeof l){if(!s)if(4&r){if(r=2|1&r,""!==l&&!rr(e,l,n)||""===l&&1===t.length){if(or(r))return!1;s=!0}}else{const u=8&r?l:t[++a];if(8&r&&null!==e.attrs){if(!tr(e.attrs,u,n)){if(or(r))return!1;s=!0}continue}const c=sr(8&r?"class":l,i,nr(e),n);if(-1===c){if(or(r))return!1;s=!0;continue}if(""!==u){let e;e=c>o?"":i[c+1].toLowerCase();const t=8&r?e:null;if(t&&-1!==$n(t,u,0)||2&r&&u!==e){if(or(r))return!1;s=!0}}}}else{if(!s&&!or(r)&&!or(l))return!1;if(s&&or(l))continue;s=!1,r=l|1&r}}return or(r)||s}function or(e){return 0==(1&e)}function sr(e,t,n,r){if(null===t)return-1;let i=0;if(r||!n){let n=!1;for(;i<t.length;){const r=t[i];if(r===e)return i;if(3===r||6===r)n=!0;else{if(1===r||2===r){let e=t[++i];for(;"string"==typeof e;)e=t[++i];continue}if(4===r)break;if(0===r){i+=4;continue}}i+=n?1:2}return-1}return function(e,t){let n=e.indexOf(4);if(n>-1)for(n++;n<e.length;){const r=e[n];if("number"==typeof r)return-1;if(r===t)return n;n++}return-1}(t,e)}function ar(e,t,n=!1){for(let r=0;r<t.length;r++)if(ir(e,t[r],n))return!0;return!1}function lr(e,t){return e?":not("+t.trim()+")":t}function ur(e){let t=e[0],n=1,r=2,i="",o=!1;for(;n<e.length;){let s=e[n];if("string"==typeof s)if(2&r){const t=e[++n];i+="["+s+(t.length>0?'="'+t+'"':"")+"]"}else 8&r?i+="."+s:4&r&&(i+=" "+s);else""===i||or(s)||(t+=lr(o,i),i=""),r=s,o=o||!or(r);n++}return""!==i&&(t+=lr(o,i)),t}const cr={};function hr(e){const t=e[3];return gt(t)?t[3]:t}function dr(e){return pr(e[13])}function fr(e){return pr(e[4])}function pr(e){for(;null!==e&&!gt(e);)e=e[4];return e}function gr(e,t){const n=e.contentQueries;if(null!==n)for(let r=0;r<n.length;r+=2){const i=n[r],o=n[r+1];if(-1!==o){const n=e.data[o];Jt(i),n.contentQueries(2,t[o],o)}}}function yr(e,t,n){return Et(t)?t.createElement(e,n):null===n?t.createElement(e):t.createElementNS(n,e)}function mr(e,t,n,r,i,o,s,a,l,u){const c=t.blueprint.slice();return c[0]=i,c[2]=140|r,jt(c),c[3]=c[15]=e,c[8]=n,c[10]=s||e&&e[10],c[11]=a||e&&e[11],c[12]=l||e&&e[12]||null,c[9]=u||e&&e[9]||null,c[6]=o,c[16]=2==t.type?e[16]:c,c}function vr(e,t,n,r,i,o){const s=n+dt,a=e.data[s]||function(e,t,n,r,i,o){const s=Wt(),a=Gt(),l=a?s:s&&s.parent,u=e.data[n]=Cr(0,l&&l!==t?l:null,r,n,i,o);return null===e.firstChild&&(e.firstChild=u),s&&(!a||null!=s.child||null===u.parent&&2!==s.type?a||(s.next=u):s.child=u),u}(e,t,s,r,i,o);return zt(a,!0),a}function _r(e,t,n){en(t,t[6]);try{const r=e.viewQuery;null!==r&&zr(1,r,n);const i=e.template;null!==i&&Ar(e,t,i,1,n),e.firstCreatePass&&(e.firstCreatePass=!1),e.staticContentQueries&&gr(e,t),e.staticViewQueries&&zr(2,e.viewQuery,n);const o=e.components;null!==o&&function(e,t){for(let n=0;n<t.length;n++)qr(e,t[n])}(t,o)}catch(r){throw e.firstCreatePass&&(e.incompleteFirstPass=!0),r}finally{t[2]&=-5,sn()}}function br(e,t,n,r){const i=t[2];if(256==(256&i))return;en(t,t[6]);const o=Qt();try{jt(t),qt.lFrame.bindingIndex=e.bindingStartIndex,null!==n&&Ar(e,t,n,2,r);const s=3==(3&i);if(!o)if(s){const n=e.preOrderCheckHooks;null!==n&&un(t,n,null)}else{const n=e.preOrderHooks;null!==n&&cn(t,n,0,null),hn(t,0)}if(function(e){for(let t=dr(e);null!==t;t=fr(t)){if(!t[2])continue;const e=t[9];for(let t=0;t<e.length;t++){const n=e[t],r=n[3];0==(1024&n[2])&&Bt(r,1),n[2]|=1024}}}(t),function(e){for(let t=dr(e);null!==t;t=fr(t))for(let e=ft;e<t.length;e++){const n=t[e],r=n[1];Dt(n)&&br(r,n,r.template,n[8])}}(t),null!==e.contentQueries&&gr(e,t),!o)if(s){const n=e.contentCheckHooks;null!==n&&un(t,n)}else{const n=e.contentHooks;null!==n&&cn(t,n,1),hn(t,1)}!function(e,t){try{const n=e.expandoInstructions;if(null!==n){let r=e.expandoStartIndex,i=-1,o=-1;for(let e=0;e<n.length;e++){const s=n[e];"number"==typeof s?s<=0?(o=0-s,an(o),r+=9+n[++e],i=r):r+=s:(null!==s&&(Kt(r,i),s(2,t[i])),i++)}}}finally{an(-1)}}(e,t);const a=e.components;null!==a&&function(e,t){for(let n=0;n<t.length;n++)Br(e,t[n])}(t,a);const l=e.viewQuery;if(null!==l&&zr(2,l,r),!o)if(s){const n=e.viewCheckHooks;null!==n&&un(t,n)}else{const n=e.viewHooks;null!==n&&cn(t,n,2),hn(t,2)}!0===e.firstUpdatePass&&(e.firstUpdatePass=!1),o||(t[2]&=-73),1024&t[2]&&(t[2]&=-1025,Bt(t[3],-1))}finally{sn()}}function wr(e,t,n,r){const i=t[10],o=!Qt(),s=Nt(t);try{o&&!s&&i.begin&&i.begin(),s&&_r(e,t,r),br(e,t,n,r)}finally{o&&!s&&i.end&&i.end()}}function Ar(e,t,n,r,i){const o=qt.lFrame.selectedIndex;try{an(-1),2&r&&t.length>dt&&function(e,t,n,r){if(!r)if(3==(3&t[2])){const n=e.preOrderCheckHooks;null!==n&&un(t,n,0)}else{const n=e.preOrderHooks;null!==n&&cn(t,n,0,0)}an(0)}(e,t,0,Qt()),n(r,i)}finally{an(o)}}function Sr(e){const t=e.tView;return null===t||t.incompleteFirstPass?e.tView=kr(1,-1,e.template,e.decls,e.vars,e.directiveDefs,e.pipeDefs,e.viewQuery,e.schemas,e.consts):t}function kr(e,t,n,r,i,o,s,a,l,u){const c=dt+r,h=c+i,d=function(e,t){const n=[];for(let r=0;r<t;r++)n.push(r<e?null:cr);return n}(c,h),f="function"==typeof u?u():u;return d[1]={type:e,id:t,blueprint:d,template:n,queries:null,viewQuery:a,node:null,data:d.slice().fill(null,c),bindingStartIndex:c,expandoStartIndex:h,expandoInstructions:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:"function"==typeof o?o():o,pipeRegistry:"function"==typeof s?s():s,firstChild:null,schemas:l,consts:f,incompleteFirstPass:!1}}function xr(e,t,n,r){const i=Qr(t);i.push(n),e.firstCreatePass&&function(e){return e.cleanup||(e.cleanup=[])}(e).push(r,i.length-1)}function Cr(e,t,n,r,i,o){return{type:n,index:r,injectorIndex:t?t.injectorIndex:-1,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,propertyBindings:null,flags:0,providerIndexes:0,tagName:i,attrs:o,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tViews:null,next:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}function Pr(e,t,n){for(let r in e)if(e.hasOwnProperty(r)){const i=e[r];(n=null===n?{}:n).hasOwnProperty(r)?n[r].push(t,i):n[r]=[t,i]}return n}function Er(e,t){const n=e.expandoInstructions;n.push(t.hostBindings),0!==t.hostVars&&n.push(t.hostVars)}function Tr(e,t,n){for(let r=0;r<n;r++)t.push(cr),e.blueprint.push(cr),e.data.push(null)}function Rr(e,t){null!==e.hostBindings&&e.hostBindings(1,t)}function Or(e,t,n){const r=dt-t.index,i=e.data.length-(1048575&t.providerIndexes);(e.expandoInstructions||(e.expandoInstructions=[])).push(r,i,n)}function Ir(e,t){t.flags|=2,(e.components||(e.components=[])).push(t.index)}function Lr(e,t,n){if(n){if(t.exportAs)for(let r=0;r<t.exportAs.length;r++)n[t.exportAs[r]]=e;_t(t)&&(n[""]=e)}}function Mr(e,t,n){e.flags|=1,e.directiveStart=t,e.directiveEnd=t+n,e.providerIndexes=t}function Nr(e,t,n){e.data.push(n);const r=n.factory||(n.factory=ct(n.type)),i=new pn(r,_t(n),null);e.blueprint.push(i),t.push(i)}function Dr(e,t,n){const r=Ot(t,e),i=Sr(n),o=e[10],s=Vr(e,mr(e,i,null,n.onPush?64:16,r,t,o,o.createRenderer(r,n)));e[t.index]=s}function Fr(e,t,n,r,i,o){const s=o[t];if(null!==s){const e=r.setInput;for(let t=0;t<s.length;){const i=s[t++],o=s[t++],a=s[t++];null!==e?r.setInput(n,a,i,o):n[o]=a}}}function jr(e,t){let n=null,r=0;for(;r<t.length;){const i=t[r];if(0!==i)if(5!==i){if("number"==typeof i)break;e.hasOwnProperty(i)&&(null===n&&(n=[]),n.push(i,e[i],t[r+1])),r+=2}else r+=2;else r+=4}return n}function Br(e,t){const n=Lt(t,e);if(Dt(n)){const e=n[1];80&n[2]?br(e,n,e.template,n[8]):n[5]>0&&function e(t){for(let r=dr(t);null!==r;r=fr(r))for(let t=ft;t<r.length;t++){const n=r[t];if(1024&n[2]){const e=n[1];br(e,n,e.template,n[8])}else n[5]>0&&e(n)}const n=t[1].components;if(null!==n)for(let r=0;r<n.length;r++){const i=Lt(n[r],t);Dt(i)&&i[5]>0&&e(i)}}(n)}}function qr(e,t){const n=Lt(t,e),r=n[1];!function(e,t){for(let n=t.length;n<e.blueprint.length;n++)t.push(e.blueprint[n])}(r,n),_r(r,n,n[8])}function Vr(e,t){return e[13]?e[14][4]=t:e[13]=t,e[14]=t,t}function Ur(e){for(;e;){e[2]|=64;const t=hr(e);if(bt(e)&&!t)return e;e=t}return null}function Hr(e,t,n){const r=t[10];r.begin&&r.begin();try{br(e,t,e.template,n)}catch(i){throw Yr(t,i),i}finally{r.end&&r.end()}}function Wr(e){!function(e){for(let t=0;t<e.components.length;t++){const n=e.components[t],r=Mt(n),i=r[1];wr(i,r,i.template,n)}}(e[8])}function zr(e,t,n){Jt(0),t(e,n)}const Gr=(()=>Promise.resolve(null))();function Qr(e){return e[7]||(e[7]=[])}function Yr(e,t){const n=e[9],r=n?n.get(Gn,null):null;r&&r.handleError(t)}function Kr(e,t,n,r,i){for(let o=0;o<n.length;){const s=n[o++],a=n[o++],l=t[s],u=e.data[s];null!==u.setInput?u.setInput(l,i,r,a):l[a]=i}}function Xr(e,t){const n=t[3];return-1===e.index?gt(n)?n:null:n}function Zr(e,t){const n=Xr(e,t);return n?li(t[11],n[7]):null}function Jr(e,t,n,r,i){if(null!=r){let o,s=!1;gt(r)?o=r:pt(r)&&(s=!0,r=r[0]);const a=Rt(r);0===e&&null!==n?null==i?si(t,n,a):oi(t,n,a,i||null):1===e&&null!==n?oi(t,n,a,i||null):2===e?function(e,t,n){const r=li(e,t);r&&function(e,t,n,r){Et(e)?e.removeChild(t,n,r):t.removeChild(n)}(e,r,t,n)}(t,a,s):3===e&&t.destroyNode(a),null!=o&&function(e,t,n,r,i){const o=n[7];o!==Rt(n)&&Jr(t,e,r,o,i);for(let s=ft;s<n.length;s++){const i=n[s];di(i[1],i,e,t,r,o)}}(t,e,o,n,i)}}function $r(e,t,n,r){const i=Zr(e.node,t);i&&di(e,t,t[11],n?1:2,i,r)}function ei(e,t){const n=e[9],r=n.indexOf(t);1024&t[2]&&Bt(t[3],-1),n.splice(r,1)}function ti(e,t){if(e.length<=ft)return;const n=ft+t,r=e[n];if(r){const i=r[17];null!==i&&i!==e&&ei(i,r),t>0&&(e[n-1][4]=r[4]);const o=Ze(e,ft+t);$r(r[1],r,!1,null);const s=o[19];null!==s&&s.detachView(o[1]),r[3]=null,r[4]=null,r[2]&=-129}return r}function ni(e,t){if(!(256&t[2])){const n=t[11];Et(n)&&n.destroyNode&&di(e,t,n,3,null,null),function(e){let t=e[13];if(!t)return ii(e[1],e);for(;t;){let n=null;if(pt(t))n=t[13];else{const e=t[10];e&&(n=e)}if(!n){for(;t&&!t[4]&&t!==e;)pt(t)&&ii(t[1],t),t=ri(t,e);null===t&&(t=e),pt(t)&&ii(t[1],t),n=t&&t[4]}t=n}}(t)}}function ri(e,t){let n;return pt(e)&&(n=e[6])&&2===n.type?Xr(n,e):e[3]===t?null:e[3]}function ii(e,t){if(!(256&t[2])){t[2]&=-129,t[2]|=256,function(e,t){let n;if(null!=e&&null!=(n=e.destroyHooks))for(let r=0;r<n.length;r+=2){const e=t[n[r]];if(!(e instanceof pn)){const t=n[r+1];if(Array.isArray(t))for(let n=0;n<t.length;n+=2)t[n+1].call(e[t[n]]);else t.call(e)}}}(e,t),function(e,t){const n=e.cleanup;if(null!==n){const e=t[7];for(let r=0;r<n.length-1;r+=2)if("string"==typeof n[r]){const i=n[r+1],o="function"==typeof i?i(t):Rt(t[i]),s=e[n[r+2]],a=n[r+3];"boolean"==typeof a?o.removeEventListener(n[r],s,a):a>=0?e[a]():e[-a].unsubscribe(),r+=2}else n[r].call(e[n[r+1]]);t[7]=null}}(e,t);const n=t[6];n&&3===n.type&&Et(t[11])&&t[11].destroy();const r=t[17];if(null!==r&&gt(t[3])){r!==t[3]&&ei(r,t);const n=t[19];null!==n&&n.detachView(e)}}}function oi(e,t,n,r){Et(e)?e.insertBefore(t,n,r):t.insertBefore(n,r,!0)}function si(e,t,n){Et(e)?e.appendChild(t,n):t.appendChild(n)}function ai(e,t,n,r){null!==r?oi(e,t,n,r):si(e,t,n)}function li(e,t){return Et(e)?e.parentNode(t):t.parentNode}function ui(e,t,n,r){const i=function(e,t,n){let r=t.parent;for(;null!=r&&(4===r.type||5===r.type);)r=(t=r).parent;if(null==r){const e=n[6];return 2===e.type?Zr(e,n):n[0]}if(t&&5===t.type&&4&t.flags)return Ot(t,n).parentNode;if(2&r.flags){const t=e.data,n=t[t[r.index].directiveStart].encapsulation;if(n!==$e.ShadowDom&&n!==$e.Native)return null}return Ot(r,n)}(e,r,t);if(null!=i){const e=t[11],o=function(e,t){if(2===e.type){const n=Xr(e,t);return null===n?null:ci(n.indexOf(t,ft)-ft,n)}return 4===e.type||5===e.type?Ot(e,t):null}(r.parent||t[6],t);if(Array.isArray(n))for(let t=0;t<n.length;t++)ai(e,i,n[t],o);else ai(e,i,n,o)}}function ci(e,t){const n=ft+e+1;if(n<t.length){const e=t[n],r=e[1].firstChild;if(null!==r)return function e(t,n){if(null!==n){const r=n.type;if(3===r)return Ot(n,t);if(0===r)return ci(-1,t[n.index]);if(4===r||5===r){const r=n.child;if(null!==r)return e(t,r);{const e=t[n.index];return gt(e)?ci(-1,e):Rt(e)}}{const r=t[16],i=r[6],o=hr(r),s=i.projection[n.projection];return null!=s?e(o,s):e(t,n.next)}}return null}(e,r)}return t[7]}function hi(e,t,n,r,i,o,s){for(;null!=n;){const a=r[n.index],l=n.type;s&&0===t&&(a&&Xn(Rt(a),r),n.flags|=4),64!=(64&n.flags)&&(4===l||5===l?(hi(e,t,n.child,r,i,o,!1),Jr(t,e,i,a,o)):1===l?fi(e,t,r,n,i,o):Jr(t,e,i,a,o)),n=s?n.projectionNext:n.next}}function di(e,t,n,r,i,o){hi(n,r,e.node.child,t,i,o,!1)}function fi(e,t,n,r,i,o){const s=n[16],a=s[6].projection[r.projection];if(Array.isArray(a))for(let l=0;l<a.length;l++)Jr(t,e,i,a[l],o);else hi(e,t,a,s[3],i,o,!0)}function pi(e,t,n){Et(e)?e.setAttribute(t,"style",n):t.style.cssText=n}function gi(e,t,n){Et(e)?""===n?e.removeAttribute(t,"class"):e.setAttribute(t,"class",n):t.className=n}class yi{constructor(e,t){this._lView=e,this._cdRefInjectingView=t,this._appRef=null,this._viewContainerRef=null}get rootNodes(){const e=this._lView;return null==e[0]?function e(t,n,r,i,o=!1){for(;null!==r;){const s=n[r.index];if(null!==s&&i.push(Rt(s)),gt(s))for(let t=ft;t<s.length;t++){const n=s[t],r=n[1].firstChild;null!==r&&e(n[1],n,r,i)}const a=r.type;if(4===a||5===a)e(t,n,r.child,i);else if(1===a){const t=n[16],o=t[6].projection[r.projection];if(Array.isArray(o))i.push(...o);else{const n=hr(t);e(n[1],n,o,i,!0)}}r=o?r.projectionNext:r.next}return i}(e[1],e,e[6].child,[]):[]}get context(){return this._lView[8]}get destroyed(){return 256==(256&this._lView[2])}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._viewContainerRef){const e=this._viewContainerRef.indexOf(this);e>-1&&this._viewContainerRef.detach(e),this._viewContainerRef=null}ni(this._lView[1],this._lView)}onDestroy(e){xr(this._lView[1],this._lView,null,e)}markForCheck(){Ur(this._cdRefInjectingView||this._lView)}detach(){this._lView[2]&=-129}reattach(){this._lView[2]|=128}detectChanges(){Hr(this._lView[1],this._lView,this.context)}checkNoChanges(){!function(e,t,n){Yt(!0);try{Hr(e,t,n)}finally{Yt(!1)}}(this._lView[1],this._lView,this.context)}attachToViewContainerRef(e){if(this._appRef)throw new Error("This view is already attached directly to the ApplicationRef!");this._viewContainerRef=e}detachFromAppRef(){var e;this._appRef=null,di(this._lView[1],e=this._lView,e[11],2,null,null)}attachToAppRef(e){if(this._viewContainerRef)throw new Error("This view is already attached to a ViewContainer!");this._appRef=e}}class mi extends yi{constructor(e){super(e),this._view=e}detectChanges(){Wr(this._view)}checkNoChanges(){!function(e){Yt(!0);try{Wr(e)}finally{Yt(!1)}}(this._view)}get context(){return null}}let vi,_i,bi;function wi(e,t,n){return vi||(vi=class extends e{}),new vi(Ot(t,n))}function Ai(e,t,n,r){return _i||(_i=class extends e{constructor(e,t,n){super(),this._declarationView=e,this._declarationTContainer=t,this.elementRef=n}createEmbeddedView(e){const t=this._declarationTContainer.tViews,n=mr(this._declarationView,t,e,16,null,t.node);n[17]=this._declarationView[this._declarationTContainer.index];const r=this._declarationView[19];return null!==r&&(n[19]=r.createEmbeddedView(t)),_r(t,n,e),new yi(n)}}),0===n.type?new _i(r,n,wi(t,n,r)):null}function Si(e,t,n,r){let i;bi||(bi=class extends e{constructor(e,t,n){super(),this._lContainer=e,this._hostTNode=t,this._hostView=n}get element(){return wi(t,this._hostTNode,this._hostView)}get injector(){return new Un(this._hostTNode,this._hostView)}get parentInjector(){const e=Ln(this._hostTNode,this._hostView),t=An(e,this._hostView),n=function(e,t,n){if(n.parent&&-1!==n.parent.injectorIndex){const e=n.parent.injectorIndex;let t=n.parent;for(;null!=t.parent&&e==t.parent.injectorIndex;)t=t.parent;return t}let r=wn(e),i=t,o=t[6];for(;r>1;)i=i[15],o=i[6],r--;return o}(e,this._hostView,this._hostTNode);return _n(e)&&null!=n?new Un(n,t):new Un(null,this._hostView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){return null!==this._lContainer[8]&&this._lContainer[8][e]||null}get length(){return this._lContainer.length-ft}createEmbeddedView(e,t,n){const r=e.createEmbeddedView(t||{});return this.insert(r,n),r}createComponent(e,t,n,r,i){const o=n||this.parentInjector;if(!i&&null==e.ngModule&&o){const e=o.get(Ye,null);e&&(i=e)}const s=e.create(o,r,void 0,i);return this.insert(s.hostView,t),s}insert(e,t){const n=e._lView,r=n[1];if(e.destroyed)throw new Error("Cannot insert a destroyed View in a ViewContainer!");if(this.allocateContainerIfNeeded(),gt(n[3])){const t=this.indexOf(e);if(-1!==t)this.detach(t);else{const t=n[3],r=new bi(t,t[6],t[3]);r.detach(r.indexOf(e))}}const i=this._adjustIndex(t);return function(e,t,n,r){const i=ft+r,o=n.length;r>0&&(n[i-1][4]=t),r<o-ft?(t[4]=n[i],Xe(n,ft+r,t)):(n.push(t),t[4]=null),t[3]=n;const s=t[17];null!==s&&n!==s&&function(e,t){const n=e[9];t[16]!==t[3][3][16]&&(e[2]=!0),null===n?e[9]=[t]:n.push(t)}(s,t);const a=t[19];null!==a&&a.insertView(e),t[2]|=128}(r,n,this._lContainer,i),$r(r,n,!0,ci(i,this._lContainer)),e.attachToViewContainerRef(this),Xe(this._lContainer[8],i,e),e}move(e,t){if(e.destroyed)throw new Error("Cannot move a destroyed View in a ViewContainer!");return this.insert(e,t)}indexOf(e){const t=this._lContainer[8];return null!==t?t.indexOf(e):-1}remove(e){this.allocateContainerIfNeeded();const t=this._adjustIndex(e,-1),n=ti(this._lContainer,t);n&&(Ze(this._lContainer[8],t),ni(n[1],n))}detach(e){this.allocateContainerIfNeeded();const t=this._adjustIndex(e,-1),n=ti(this._lContainer,t);return n&&null!=Ze(this._lContainer[8],t)?new yi(n):null}_adjustIndex(e,t=0){return null==e?this.length+t:e}allocateContainerIfNeeded(){null===this._lContainer[8]&&(this._lContainer[8]=[])}});const o=r[n.index];if(gt(o))i=o;else{let e;if(4===n.type)e=Rt(o);else if(e=r[11].createComment(""),bt(r)){const t=r[11],i=Ot(n,r);oi(t,li(t,i),e,function(e,t){return Et(e)?e.nextSibling(t):t.nextSibling}(t,i))}else ui(r[1],r,e,n);r[n.index]=i=new Array(o,!0,!1,r,null,0,n,e,null,null),Vr(r,i)}return new bi(i,n,r)}const ki=new Le("Set Injector scope."),xi={},Ci={},Pi=[];let Ei=void 0;function Ti(){return void 0===Ei&&(Ei=new Qe),Ei}function Ri(e,t=null,n=null,r){return new Oi(e,n,t||Ti(),r)}class Oi{constructor(e,t,n,r=null){this.parent=n,this.records=new Map,this.injectorDefTypes=new Set,this.onDestroy=new Set,this._destroyed=!1;const i=[];t&&Ke(t,n=>this.processProvider(n,e,t)),Ke([e],e=>this.processInjectorType(e,[],i)),this.records.set(Me,Li(void 0,this));const o=this.records.get(ki);this.scope=null!=o?o.value:null,this.source=r||("object"==typeof e?null:ye(e))}get destroyed(){return this._destroyed}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{this.onDestroy.forEach(e=>e.ngOnDestroy())}finally{this.records.clear(),this.onDestroy.clear(),this.injectorDefTypes.clear()}}get(e,t=Ne,n=ie.Default){this.assertNotDestroyed();const r=Ve(this);try{if(!(n&ie.SkipSelf)){let t=this.records.get(e);if(void 0===t){const n=("function"==typeof(i=e)||"object"==typeof i&&i instanceof Le)&&le(e);t=n&&this.injectableDefInScope(n)?Li(Ii(e),xi):null,this.records.set(e,t)}if(null!=t)return this.hydrate(e,t)}return(n&ie.Self?Ti():this.parent).get(e,t=n&ie.Optional&&t===Ne?null:t)}catch(o){if("NullInjectorError"===o.name){if((o.ngTempTokenPath=o.ngTempTokenPath||[]).unshift(ye(e)),r)throw o;return function(e,t,n,r){const i=e.ngTempTokenPath;throw t[Fe]&&i.unshift(t[Fe]),e.message=function(e,t,n,r=null){e=e&&"\n"===e.charAt(0)&&"\u0275"==e.charAt(1)?e.substr(2):e;let i=ye(t);if(Array.isArray(t))i=t.map(ye).join(" -> ");else if("object"==typeof t){let e=[];for(let n in t)if(t.hasOwnProperty(n)){let r=t[n];e.push(n+":"+("string"==typeof r?JSON.stringify(r):ye(r)))}i=`{${e.join(", ")}}`}return`${n}${r?"("+r+")":""}[${i}]: ${e.replace(De,"\n ")}`}("\n"+e.message,i,n,r),e.ngTokenPath=i,e.ngTempTokenPath=null,e}(o,e,"R3InjectorError",this.source)}throw o}finally{Ve(r)}var i}_resolveInjectorDefTypes(){this.injectorDefTypes.forEach(e=>this.get(e))}toString(){const e=[];return this.records.forEach((t,n)=>e.push(ye(n))),`R3Injector[${e.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Error("Injector has already been destroyed.")}processInjectorType(e,t,n){if(!(e=be(e)))return!1;let r=ce(e);const i=null==r&&e.ngModule||void 0,o=void 0===i?e:i,s=-1!==n.indexOf(o);if(void 0!==i&&(r=ce(i)),null==r)return!1;if(null!=r.imports&&!s){let e;n.push(o);try{Ke(r.imports,r=>{this.processInjectorType(r,t,n)&&(void 0===e&&(e=[]),e.push(r))})}finally{}if(void 0!==e)for(let t=0;t<e.length;t++){const{ngModule:n,providers:r}=e[t];Ke(r,e=>this.processProvider(e,n,r||Pi))}}this.injectorDefTypes.add(o),this.records.set(o,Li(r.factory,xi));const a=r.providers;if(null!=a&&!s){const t=e;Ke(a,e=>this.processProvider(e,t,a))}return void 0!==i&&void 0!==e.providers}processProvider(e,t,n){let r=Ni(e=be(e))?e:be(e&&e.provide);const i=function(e,t,n){return Mi(e)?Li(void 0,e.useValue):Li(function(e,t,n){let r=void 0;if(Ni(e)){const t=be(e);return ct(t)||Ii(t)}if(Mi(e))r=()=>be(e.useValue);else if((i=e)&&i.useFactory)r=()=>e.useFactory(...Ge(e.deps||[]));else if(function(e){return!(!e||!e.useExisting)}(e))r=()=>We(be(e.useExisting));else{const i=be(e&&(e.useClass||e.provide));if(i||function(e,t,n){let r="";throw e&&t&&(r=` - only instances of Provider and Type are allowed, got: [${t.map(e=>e==n?"?"+n+"?":"...").join(", ")}]`),new Error(`Invalid provider for the NgModule '${ye(e)}'`+r)}(t,n,e),!function(e){return!!e.deps}(e))return ct(i)||Ii(i);r=()=>new i(...Ge(e.deps))}var i;return r}(e,t,n),xi)}(e,t,n);if(Ni(e)||!0!==e.multi){const e=this.records.get(r);e&&void 0!==e.multi&&Jn()}else{let t=this.records.get(r);t?void 0===t.multi&&Jn():(t=Li(void 0,xi,!0),t.factory=()=>Ge(t.multi),this.records.set(r,t)),r=e,t.multi.push(e)}this.records.set(r,i)}hydrate(e,t){var n;return t.value===Ci?function(e){throw new Error("Cannot instantiate cyclic dependency! "+e)}(ye(e)):t.value===xi&&(t.value=Ci,t.value=t.factory()),"object"==typeof t.value&&t.value&&null!==(n=t.value)&&"object"==typeof n&&"function"==typeof n.ngOnDestroy&&this.onDestroy.add(t.value),t.value}injectableDefInScope(e){return!!e.providedIn&&("string"==typeof e.providedIn?"any"===e.providedIn||e.providedIn===this.scope:this.injectorDefTypes.has(e.providedIn))}}function Ii(e){const t=le(e),n=null!==t?t.factory:ct(e);if(null!==n)return n;const r=ce(e);if(null!==r)return r.factory;if(e instanceof Le)throw new Error(`Token ${ye(e)} is missing a \u0275prov definition.`);if(e instanceof Function)return function(e){const t=e.length;if(t>0){const n=function(e,t){const n=[];for(let r=0;r<e;r++)n.push("?");return n}(t);throw new Error(`Can't resolve all parameters for ${ye(e)}: (${n.join(", ")}).`)}const n=function(e){const t=e&&(e[he]||e[pe]||e[fe]&&e[fe]());if(t){const n=function(e){if(e.hasOwnProperty("name"))return e.name;const t=(""+e).match(/^function\s*([^\s(]+)/);return null===t?"":t[1]}(e);return console.warn(`DEPRECATED: DI is instantiating a token "${n}" that inherits its @Injectable decorator but does not provide one itself.\nThis will become an error in a future version of Angular. Please add @Injectable() to the "${n}" class.`),t}return null}(e);return null!==n?()=>n.factory(e):()=>new e}(e);throw new Error("unreachable")}function Li(e,t,n=!1){return{factory:e,value:t,multi:n?[]:void 0}}function Mi(e){return null!==e&&"object"==typeof e&&je in e}function Ni(e){return"function"==typeof e}const Di=function(e,t,n){return function(e,t=null,n=null,r){const i=Ri(e,t,n,r);return i._resolveInjectorDefTypes(),i}({name:n},t,e,n)};let Fi=(()=>{class e{static create(e,t){return Array.isArray(e)?Di(e,t,""):Di(e.providers,e.parent,e.name||"")}}return e.THROW_IF_NOT_FOUND=Ne,e.NULL=new Qe,e.\u0275prov=se({token:e,providedIn:"any",factory:()=>We(Me)}),e.__NG_ELEMENT_ID__=-1,e})();function ji(e,t,n){let r=n?e.styles:null,i=n?e.classes:null,o=0;if(null!==t)for(let s=0;s<t.length;s++){const e=t[s];"number"==typeof e?o=e:1==o?i=me(i,e):2==o&&(r=me(r,e+": "+t[++s]+";"))}n?e.styles=r:e.stylesWithoutHost=r,n?e.classes=i:e.classesWithoutHost=i}let Bi=null;function qi(){if(!Bi){const e=xe.Symbol;if(e&&e.iterator)Bi=e.iterator;else{const e=Object.getOwnPropertyNames(Map.prototype);for(let t=0;t<e.length;++t){const n=e[t];"entries"!==n&&"size"!==n&&Map.prototype[n]===Map.prototype.entries&&(Bi=n)}}}return Bi}function Vi(e){return!!Ui(e)&&(Array.isArray(e)||!(e instanceof Map)&&qi()in e)}function Ui(e){return null!==e&&("function"==typeof e||"object"==typeof e)}function Hi(e,t,n){const r=Ut();return function(e,t,n){return!Object.is(e[t],n)&&(e[t]=n,!0)}(r,qt.lFrame.bindingIndex++,t)&&function(e,t,n,r,i,o,s,a){const l=Ot(t,n);let u,c=t.inputs;var h;null!=c&&(u=c[r])?(Kr(e,n,u,r,i),mt(t)&&function(e,t){const n=Lt(t,e);16&n[2]||(n[2]|=64)}(n,t.index)):3===t.type&&(r="class"===(h=r)?"className":"for"===h?"htmlFor":"formaction"===h?"formAction":"innerHtml"===h?"innerHTML":"readonly"===h?"readOnly":"tabindex"===h?"tabIndex":h,i=null!=s?s(i,t.tagName||"",r):i,Et(o)?o.setProperty(l,r,i):yn(r)||(l.setProperty?l.setProperty(r,i):l[r]=i))}(Ht(),function(){const e=qt.lFrame;return It(e.tView,e.selectedIndex)}(),r,e,t,r[11],n),Hi}function Wi(e,t,n,r,i){const o=i?"class":"style";Kr(e,n,t.inputs[o],o,r)}function zi(e,t,n,r){const i=Ut(),o=Ht(),s=dt+e,a=i[11],l=i[s]=yr(t,a,qt.lFrame.currentNamespace),u=o.firstCreatePass?function(e,t,n,r,i,o,s){const a=t.consts,l=Ft(a,o),u=vr(t,n[6],e,3,i,l);return function(e,t,n,r){let i=!1;if(Vt()){const o=function(e,t,n){const r=e.directiveRegistry;let i=null;if(r)for(let o=0;o<r.length;o++){const s=r[o];ar(n,s.selectors,!1)&&(i||(i=[]),Mn(Rn(n,t),e,s.type),_t(s)?(2&n.flags&&Zn(n),Ir(e,n),i.unshift(s)):i.push(s))}return i}(e,t,n),s=null===r?null:{"":-1};if(null!==o){let r=0;i=!0,Mr(n,e.data.length,o.length);for(let e=0;e<o.length;e++){const t=o[e];t.providersResolver&&t.providersResolver(t)}Or(e,n,o.length);let a=!1,l=!1;for(let i=0;i<o.length;i++){const u=o[i];n.mergedAttrs=mn(n.mergedAttrs,u.hostAttrs),Nr(e,t,u),Lr(e.data.length-1,u,s),null!==u.contentQueries&&(n.flags|=8),null===u.hostBindings&&null===u.hostAttrs&&0===u.hostVars||(n.flags|=128);const c=u.type.prototype;!a&&(c.ngOnChanges||c.ngOnInit||c.ngDoCheck)&&((e.preOrderHooks||(e.preOrderHooks=[])).push(n.index-dt),a=!0),l||!c.ngOnChanges&&!c.ngDoCheck||((e.preOrderCheckHooks||(e.preOrderCheckHooks=[])).push(n.index-dt),l=!0),Er(e,u),r+=u.hostVars}!function(e,t){const n=t.directiveEnd,r=e.data,i=t.attrs,o=[];let s=null,a=null;for(let l=t.directiveStart;l<n;l++){const e=r[l],n=e.inputs,u=null===i||nr(t)?null:jr(n,i);o.push(u),s=Pr(n,l,s),a=Pr(e.outputs,l,a)}null!==s&&(s.hasOwnProperty("class")&&(t.flags|=16),s.hasOwnProperty("style")&&(t.flags|=32)),t.initialInputs=o,t.inputs=s,t.outputs=a}(e,n),Tr(e,t,r)}s&&function(e,t,n){if(t){const r=e.localNames=[];for(let e=0;e<t.length;e+=2){const i=n[t[e+1]];if(null==i)throw new Error(`Export of name '${t[e+1]}' not found!`);r.push(t[e],i)}}}(n,r,s)}n.mergedAttrs=mn(n.mergedAttrs,n.attrs)}(t,n,u,Ft(a,s)),null!==u.attrs&&ji(u,u.attrs,!1),null!==u.mergedAttrs&&ji(u,u.mergedAttrs,!0),null!==t.queries&&t.queries.elementStart(t,u),u}(e,o,i,0,t,n,r):o.data[s];zt(u,!0);const c=u.mergedAttrs;null!==c&&gn(a,l,c);const h=u.classes;null!==h&&gi(a,l,h);const d=u.styles;null!==d&&pi(a,l,d),ui(o,i,l,u),0===qt.lFrame.elementDepthCount&&Xn(l,i),qt.lFrame.elementDepthCount++,vt(u)&&(function(e,t,n){Vt()&&(function(e,t,n,r){const i=n.directiveStart,o=n.directiveEnd;e.firstCreatePass||Rn(n,t),Xn(r,t);const s=n.initialInputs;for(let a=i;a<o;a++){const r=e.data[a],o=_t(r);o&&Dr(t,n,r);const l=Bn(t,e,a,n);Xn(l,t),null!==s&&Fr(0,a-i,l,r,0,s),o&&(Lt(n.index,t)[8]=l)}}(e,t,n,Ot(n,t)),128==(128&n.flags)&&function(e,t,n){const r=n.directiveStart,i=n.directiveEnd,o=e.expandoInstructions,s=e.firstCreatePass,a=n.index-dt,l=qt.lFrame.currentDirectiveIndex;try{an(a);for(let n=r;n<i;n++){const r=e.data[n],i=t[n];Xt(n),null!==r.hostBindings||0!==r.hostVars||null!==r.hostAttrs?Rr(r,i):s&&o.push(null)}}finally{an(-1),Xt(l)}}(e,t,n))}(o,i,u),function(e,t,n){if(yt(t)){const r=t.directiveEnd;for(let i=t.directiveStart;i<r;i++){const t=e.data[i];t.contentQueries&&t.contentQueries(1,n[i],i)}}}(o,u,i)),null!==r&&function(e,t,n=Ot){const r=t.localNames;if(null!==r){let i=t.index+1;for(let o=0;o<r.length;o+=2){const s=r[o+1],a=-1===s?n(t,e):e[s];e[i++]=a}}}(i,u)}function Gi(){let e=Wt();Gt()?qt.lFrame.isParent=!1:(e=e.parent,zt(e,!1));const t=e;qt.lFrame.elementDepthCount--;const n=Ht();n.firstCreatePass&&(ln(n,e),yt(e)&&n.queries.elementEnd(e)),null!=t.classesWithoutHost&&function(e){return 0!=(16&e.flags)}(t)&&Wi(n,t,Ut(),t.classesWithoutHost,!0),null!=t.stylesWithoutHost&&function(e){return 0!=(32&e.flags)}(t)&&Wi(n,t,Ut(),t.stylesWithoutHost,!1)}function Qi(e){return!!e&&"function"==typeof e.then}function Yi(e,t,n=!1,r){const i=Ut(),o=Ht(),s=Wt();return function(e,t,n,r,i,o,s=!1,a){const l=vt(r),u=e.firstCreatePass&&(e.cleanup||(e.cleanup=[])),c=Qr(t);let h=!0;if(3===r.type){const d=Ot(r,t),f=a?a(d):et,p=f.target||d,g=c.length,y=a?e=>a(Rt(e[r.index])).target:r.index;if(Et(n)){let s=null;if(!a&&l&&(s=function(e,t,n,r){const i=e.cleanup;if(null!=i)for(let o=0;o<i.length-1;o+=2){const e=i[o];if(e===n&&i[o+1]===r){const e=t[7],n=i[o+2];return e.length>n?e[n]:null}"string"==typeof e&&(o+=2)}return null}(e,t,i,r.index)),null!==s)(s.__ngLastListenerFn__||s).__ngNextListenerFn__=o,s.__ngLastListenerFn__=o,h=!1;else{o=Xi(r,t,o,!1);const e=n.listen(f.name||p,i,o);c.push(o,e),u&&u.push(i,y,g,g+1)}}else o=Xi(r,t,o,!0),p.addEventListener(i,o,s),c.push(o),u&&u.push(i,y,g,s)}const d=r.outputs;let f;if(h&&null!==d&&(f=d[i])){const e=f.length;if(e)for(let n=0;n<e;n+=2){const e=t[f[n]][f[n+1]].subscribe(o),s=c.length;c.push(o,e),u&&u.push(i,r.index,s,-(s+1))}}}(o,i,i[11],s,e,t,n,r),Yi}function Ki(e,t,n){try{return!1!==t(n)}catch(r){return Yr(e,r),!1}}function Xi(e,t,n,r){return function i(o){if(o===Function)return n;const s=2&e.flags?Lt(e.index,t):t;0==(32&t[2])&&Ur(s);let a=Ki(t,n,o),l=i.__ngNextListenerFn__;for(;l;)a=Ki(t,l,o)&&a,l=l.__ngNextListenerFn__;return r&&!1===a&&(o.preventDefault(),o.returnValue=!1),a}}function Zi(e,t){const n=Mt(e)[1],r=n.data.length-1;ln(n,{directiveStart:r,directiveEnd:r+1})}class Ji{}class $i{resolveComponentFactory(e){throw function(e){const t=Error(`No component factory found for ${ye(e)}. Did you add it to @NgModule.entryComponents?`);return t.ngComponent=e,t}(e)}}let eo=(()=>{class e{}return e.NULL=new $i,e})(),to=(()=>{class e{constructor(e){this.nativeElement=e}}return e.__NG_ELEMENT_ID__=()=>no(e),e})();const no=function(e){return wi(e,Wt(),Ut())};class ro{}var io=function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e}({});let oo=(()=>{class e{}return e.\u0275prov=se({token:e,providedIn:"root",factory:()=>null}),e})();class so{constructor(e){this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")}}const ao=new so("10.1.0");class lo{constructor(){}supports(e){return Vi(e)}create(e){return new co(e)}}const uo=(e,t)=>t;class co{constructor(e){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=e||uo}forEachItem(e){let t;for(t=this._itHead;null!==t;t=t._next)e(t)}forEachOperation(e){let t=this._itHead,n=this._removalsHead,r=0,i=null;for(;t||n;){const o=!n||t&&t.currentIndex<go(n,r,i)?t:n,s=go(o,r,i),a=o.currentIndex;if(o===n)r--,n=n._nextRemoved;else if(t=t._next,null==o.previousIndex)r++;else{i||(i=[]);const e=s-r,t=a-r;if(e!=t){for(let n=0;n<e;n++){const r=n<i.length?i[n]:i[n]=0,o=r+n;t<=o&&o<e&&(i[n]=r+1)}i[o.previousIndex]=t-e}}s!==a&&e(o,s,a)}}forEachPreviousItem(e){let t;for(t=this._previousItHead;null!==t;t=t._nextPrevious)e(t)}forEachAddedItem(e){let t;for(t=this._additionsHead;null!==t;t=t._nextAdded)e(t)}forEachMovedItem(e){let t;for(t=this._movesHead;null!==t;t=t._nextMoved)e(t)}forEachRemovedItem(e){let t;for(t=this._removalsHead;null!==t;t=t._nextRemoved)e(t)}forEachIdentityChange(e){let t;for(t=this._identityChangesHead;null!==t;t=t._nextIdentityChange)e(t)}diff(e){if(null==e&&(e=[]),!Vi(e))throw new Error(`Error trying to diff '${ye(e)}'. Only arrays and iterables are allowed`);return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let t,n,r,i=this._itHead,o=!1;if(Array.isArray(e)){this.length=e.length;for(let t=0;t<this.length;t++)n=e[t],r=this._trackByFn(t,n),null!==i&&Object.is(i.trackById,r)?(o&&(i=this._verifyReinsertion(i,n,r,t)),Object.is(i.item,n)||this._addIdentityChange(i,n)):(i=this._mismatch(i,n,r,t),o=!0),i=i._next}else t=0,function(e,t){if(Array.isArray(e))for(let n=0;n<e.length;n++)t(e[n]);else{const n=e[qi()]();let r;for(;!(r=n.next()).done;)t(r.value)}}(e,e=>{r=this._trackByFn(t,e),null!==i&&Object.is(i.trackById,r)?(o&&(i=this._verifyReinsertion(i,e,r,t)),Object.is(i.item,e)||this._addIdentityChange(i,e)):(i=this._mismatch(i,e,r,t),o=!0),i=i._next,t++}),this.length=t;return this._truncate(i),this.collection=e,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let e,t;for(e=this._previousItHead=this._itHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._additionsHead;null!==e;e=e._nextAdded)e.previousIndex=e.currentIndex;for(this._additionsHead=this._additionsTail=null,e=this._movesHead;null!==e;e=t)e.previousIndex=e.currentIndex,t=e._nextMoved;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(e,t,n,r){let i;return null===e?i=this._itTail:(i=e._prev,this._remove(e)),null!==(e=null===this._linkedRecords?null:this._linkedRecords.get(n,r))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._moveAfter(e,i,r)):null!==(e=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null))?(Object.is(e.item,t)||this._addIdentityChange(e,t),this._reinsertAfter(e,i,r)):e=this._addAfter(new ho(t,n),i,r),e}_verifyReinsertion(e,t,n,r){let i=null===this._unlinkedRecords?null:this._unlinkedRecords.get(n,null);return null!==i?e=this._reinsertAfter(i,e._prev,r):e.currentIndex!=r&&(e.currentIndex=r,this._addToMoves(e,r)),e}_truncate(e){for(;null!==e;){const t=e._next;this._addToRemovals(this._unlink(e)),e=t}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(e,t,n){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(e);const r=e._prevRemoved,i=e._nextRemoved;return null===r?this._removalsHead=i:r._nextRemoved=i,null===i?this._removalsTail=r:i._prevRemoved=r,this._insertAfter(e,t,n),this._addToMoves(e,n),e}_moveAfter(e,t,n){return this._unlink(e),this._insertAfter(e,t,n),this._addToMoves(e,n),e}_addAfter(e,t,n){return this._insertAfter(e,t,n),this._additionsTail=null===this._additionsTail?this._additionsHead=e:this._additionsTail._nextAdded=e,e}_insertAfter(e,t,n){const r=null===t?this._itHead:t._next;return e._next=r,e._prev=t,null===r?this._itTail=e:r._prev=e,null===t?this._itHead=e:t._next=e,null===this._linkedRecords&&(this._linkedRecords=new po),this._linkedRecords.put(e),e.currentIndex=n,e}_remove(e){return this._addToRemovals(this._unlink(e))}_unlink(e){null!==this._linkedRecords&&this._linkedRecords.remove(e);const t=e._prev,n=e._next;return null===t?this._itHead=n:t._next=n,null===n?this._itTail=t:n._prev=t,e}_addToMoves(e,t){return e.previousIndex===t||(this._movesTail=null===this._movesTail?this._movesHead=e:this._movesTail._nextMoved=e),e}_addToRemovals(e){return null===this._unlinkedRecords&&(this._unlinkedRecords=new po),this._unlinkedRecords.put(e),e.currentIndex=null,e._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=e,e._prevRemoved=null):(e._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=e),e}_addIdentityChange(e,t){return e.item=t,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=e:this._identityChangesTail._nextIdentityChange=e,e}}class ho{constructor(e,t){this.item=e,this.trackById=t,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class fo{constructor(){this._head=null,this._tail=null}add(e){null===this._head?(this._head=this._tail=e,e._nextDup=null,e._prevDup=null):(this._tail._nextDup=e,e._prevDup=this._tail,e._nextDup=null,this._tail=e)}get(e,t){let n;for(n=this._head;null!==n;n=n._nextDup)if((null===t||t<=n.currentIndex)&&Object.is(n.trackById,e))return n;return null}remove(e){const t=e._prevDup,n=e._nextDup;return null===t?this._head=n:t._nextDup=n,null===n?this._tail=t:n._prevDup=t,null===this._head}}class po{constructor(){this.map=new Map}put(e){const t=e.trackById;let n=this.map.get(t);n||(n=new fo,this.map.set(t,n)),n.add(e)}get(e,t){const n=this.map.get(e);return n?n.get(e,t):null}remove(e){const t=e.trackById;return this.map.get(t).remove(e)&&this.map.delete(t),e}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function go(e,t,n){const r=e.previousIndex;if(null===r)return r;let i=0;return n&&r<n.length&&(i=n[r]),r+t+i}class yo{constructor(){}supports(e){return e instanceof Map||Ui(e)}create(){return new mo}}class mo{constructor(){this._records=new Map,this._mapHead=null,this._appendAfter=null,this._previousMapHead=null,this._changesHead=null,this._changesTail=null,this._additionsHead=null,this._additionsTail=null,this._removalsHead=null,this._removalsTail=null}get isDirty(){return null!==this._additionsHead||null!==this._changesHead||null!==this._removalsHead}forEachItem(e){let t;for(t=this._mapHead;null!==t;t=t._next)e(t)}forEachPreviousItem(e){let t;for(t=this._previousMapHead;null!==t;t=t._nextPrevious)e(t)}forEachChangedItem(e){let t;for(t=this._changesHead;null!==t;t=t._nextChanged)e(t)}forEachAddedItem(e){let t;for(t=this._additionsHead;null!==t;t=t._nextAdded)e(t)}forEachRemovedItem(e){let t;for(t=this._removalsHead;null!==t;t=t._nextRemoved)e(t)}diff(e){if(e){if(!(e instanceof Map||Ui(e)))throw new Error(`Error trying to diff '${ye(e)}'. Only maps and objects are allowed`)}else e=new Map;return this.check(e)?this:null}onDestroy(){}check(e){this._reset();let t=this._mapHead;if(this._appendAfter=null,this._forEach(e,(e,n)=>{if(t&&t.key===n)this._maybeAddToChanges(t,e),this._appendAfter=t,t=t._next;else{const r=this._getOrCreateRecordForKey(n,e);t=this._insertBeforeOrAppend(t,r)}}),t){t._prev&&(t._prev._next=null),this._removalsHead=t;for(let e=t;null!==e;e=e._nextRemoved)e===this._mapHead&&(this._mapHead=null),this._records.delete(e.key),e._nextRemoved=e._next,e.previousValue=e.currentValue,e.currentValue=null,e._prev=null,e._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(e,t){if(e){const n=e._prev;return t._next=e,t._prev=n,e._prev=t,n&&(n._next=t),e===this._mapHead&&(this._mapHead=t),this._appendAfter=e,e}return this._appendAfter?(this._appendAfter._next=t,t._prev=this._appendAfter):this._mapHead=t,this._appendAfter=t,null}_getOrCreateRecordForKey(e,t){if(this._records.has(e)){const n=this._records.get(e);this._maybeAddToChanges(n,t);const r=n._prev,i=n._next;return r&&(r._next=i),i&&(i._prev=r),n._next=null,n._prev=null,n}const n=new vo(e);return this._records.set(e,n),n.currentValue=t,this._addToAdditions(n),n}_reset(){if(this.isDirty){let e;for(this._previousMapHead=this._mapHead,e=this._previousMapHead;null!==e;e=e._next)e._nextPrevious=e._next;for(e=this._changesHead;null!==e;e=e._nextChanged)e.previousValue=e.currentValue;for(e=this._additionsHead;null!=e;e=e._nextAdded)e.previousValue=e.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(e,t){Object.is(t,e.currentValue)||(e.previousValue=e.currentValue,e.currentValue=t,this._addToChanges(e))}_addToAdditions(e){null===this._additionsHead?this._additionsHead=this._additionsTail=e:(this._additionsTail._nextAdded=e,this._additionsTail=e)}_addToChanges(e){null===this._changesHead?this._changesHead=this._changesTail=e:(this._changesTail._nextChanged=e,this._changesTail=e)}_forEach(e,t){e instanceof Map?e.forEach(t):Object.keys(e).forEach(n=>t(e[n],n))}}class vo{constructor(e){this.key=e,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}let _o=(()=>{class e{constructor(e){this.factories=e}static create(t,n){if(null!=n){const e=n.factories.slice();t=t.concat(e)}return new e(t)}static extend(t){return{provide:e,useFactory:n=>{if(!n)throw new Error("Cannot extend IterableDiffers without a parent injector");return e.create(t,n)},deps:[[e,new re,new te]]}}find(e){const t=this.factories.find(t=>t.supports(e));if(null!=t)return t;throw new Error(`Cannot find a differ supporting object '${e}' of type '${n=e,n.name||typeof n}'`);var n}}return e.\u0275prov=se({token:e,providedIn:"root",factory:()=>new e([new lo])}),e})(),bo=(()=>{class e{constructor(e){this.factories=e}static create(t,n){if(n){const e=n.factories.slice();t=t.concat(e)}return new e(t)}static extend(t){return{provide:e,useFactory:n=>{if(!n)throw new Error("Cannot extend KeyValueDiffers without a parent injector");return e.create(t,n)},deps:[[e,new re,new te]]}}find(e){const t=this.factories.find(t=>t.supports(e));if(t)return t;throw new Error(`Cannot find a differ supporting object '${e}'`)}}return e.\u0275prov=se({token:e,providedIn:"root",factory:()=>new e([new yo])}),e})();const wo=[new yo],Ao=new _o([new lo]),So=new bo(wo);let ko=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>xo(e,to),e})();const xo=function(e,t){return Ai(e,t,Wt(),Ut())};let Co=(()=>{class e{}return e.__NG_ELEMENT_ID__=()=>Po(e,to),e})();const Po=function(e,t){return Si(e,t,Wt(),Ut())},Eo={};class To extends eo{constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){const t=ut(e);return new Io(t,this.ngModule)}}function Ro(e){const t=[];for(let n in e)e.hasOwnProperty(n)&&t.push({propName:e[n],templateName:n});return t}const Oo=new Le("SCHEDULER_TOKEN",{providedIn:"root",factory:()=>kn});class Io extends Ji{constructor(e,t){super(),this.componentDef=e,this.ngModule=t,this.componentType=e.type,this.selector=e.selectors.map(ur).join(","),this.ngContentSelectors=e.ngContentSelectors?e.ngContentSelectors:[],this.isBoundToModule=!!t}get inputs(){return Ro(this.componentDef.inputs)}get outputs(){return Ro(this.componentDef.outputs)}create(e,t,n,r){const i=(r=r||this.ngModule)?function(e,t){return{get:(n,r,i)=>{const o=e.get(n,Eo,i);return o!==Eo||r===Eo?o:t.get(n,r,i)}}}(e,r.injector):e,o=i.get(ro,Tt),s=i.get(oo,null),a=o.createRenderer(null,this.componentDef),l=this.componentDef.selectors[0][0]||"div",u=n?function(e,t,n){if(Et(e))return e.selectRootElement(t,n===$e.ShadowDom);let r="string"==typeof t?e.querySelector(t):t;return r.textContent="",r}(a,n,this.componentDef.encapsulation):yr(l,o.createRenderer(null,this.componentDef),function(e){const t=e.toLowerCase();return"svg"===t?"http://www.w3.org/2000/svg":"math"===t?"http://www.w3.org/1998/MathML/":null}(l)),c=this.componentDef.onPush?576:528,h={components:[],scheduler:kn,clean:Gr,playerHandler:null,flags:0},d=kr(0,-1,null,1,0,null,null,null,null,null),f=mr(null,d,h,c,null,null,o,a,s,i);let p,g;en(f,null);try{const e=function(e,t,n,r,i,o){const s=n[1];n[20]=e;const a=vr(s,null,0,3,null,null),l=a.mergedAttrs=t.hostAttrs;null!==l&&(ji(a,l,!0),null!==e&&(gn(i,e,l),null!==a.classes&&gi(i,e,a.classes),null!==a.styles&&pi(i,e,a.styles)));const u=r.createRenderer(e,t),c=mr(n,Sr(t),null,t.onPush?64:16,n[20],a,r,u,void 0);return s.firstCreatePass&&(Mn(Rn(a,n),s,t.type),Ir(s,a),Mr(a,n.length,1)),Vr(n,c),n[20]=c}(u,this.componentDef,f,o,a);if(u)if(n)gn(a,u,["ng-version",ao.full]);else{const{attrs:e,classes:t}=function(e){const t=[],n=[];let r=1,i=2;for(;r<e.length;){let o=e[r];if("string"==typeof o)2===i?""!==o&&t.push(o,e[++r]):8===i&&n.push(o);else{if(!or(i))break;i=o}r++}return{attrs:t,classes:n}}(this.componentDef.selectors[0]);e&&gn(a,u,e),t&&t.length>0&&gi(a,u,t.join(" "))}if(g=It(d,0),void 0!==t){const e=g.projection=[];for(let n=0;n<this.ngContentSelectors.length;n++){const r=t[n];e.push(null!=r?Array.from(r):null)}}p=function(e,t,n,r,i){const o=n[1],s=function(e,t,n){const r=Wt();e.firstCreatePass&&(n.providersResolver&&n.providersResolver(n),Or(e,r,1),Nr(e,t,n));const i=Bn(t,e,t.length-1,r);Xn(i,t);const o=Ot(r,t);return o&&Xn(o,t),i}(o,n,t);r.components.push(s),e[8]=s,i&&i.forEach(e=>e(s,t)),t.contentQueries&&t.contentQueries(1,s,n.length-1);const a=Wt();if(o.firstCreatePass&&(null!==t.hostBindings||null!==t.hostAttrs)){an(a.index-dt);const e=n[1];Er(e,t),Tr(e,n,t.hostVars),Rr(t,s)}return s}(e,this.componentDef,f,h,[Zi]),_r(d,f,null)}finally{sn()}const y=new Lo(this.componentType,p,wi(to,g,f),f,g);return d.node.child=g,y}}class Lo extends class{}{constructor(e,t,n,r,i){super(),this.location=n,this._rootLView=r,this._tNode=i,this.destroyCbs=[],this.instance=t,this.hostView=this.changeDetectorRef=new mi(r),function(e,t,n,r){let i=e.node;null==i&&(e.node=i=Cr(0,null,2,-1,null,null)),r[6]=i}(r[1],0,0,r),this.componentType=e}get injector(){return new Un(this._tNode,this._rootLView)}destroy(){this.destroyCbs&&(this.destroyCbs.forEach(e=>e()),this.destroyCbs=null,!this.hostView.destroyed&&this.hostView.destroy())}onDestroy(e){this.destroyCbs&&this.destroyCbs.push(e)}}const Mo=void 0;var No=["en",[["a","p"],["AM","PM"],Mo],[["AM","PM"],Mo,Mo],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],Mo,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],Mo,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",Mo,"{1} 'at' {0}",Mo],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function(e){let t=Math.floor(Math.abs(e)),n=e.toString().replace(/^[^.]*\.?/,"").length;return 1===t&&0===n?1:5}];let Do={};function Fo(e){return e in Do||(Do[e]=xe.ng&&xe.ng.common&&xe.ng.common.locales&&xe.ng.common.locales[e]),Do[e]}var jo=function(e){return e[e.LocaleId=0]="LocaleId",e[e.DayPeriodsFormat=1]="DayPeriodsFormat",e[e.DayPeriodsStandalone=2]="DayPeriodsStandalone",e[e.DaysFormat=3]="DaysFormat",e[e.DaysStandalone=4]="DaysStandalone",e[e.MonthsFormat=5]="MonthsFormat",e[e.MonthsStandalone=6]="MonthsStandalone",e[e.Eras=7]="Eras",e[e.FirstDayOfWeek=8]="FirstDayOfWeek",e[e.WeekendRange=9]="WeekendRange",e[e.DateFormat=10]="DateFormat",e[e.TimeFormat=11]="TimeFormat",e[e.DateTimeFormat=12]="DateTimeFormat",e[e.NumberSymbols=13]="NumberSymbols",e[e.NumberFormats=14]="NumberFormats",e[e.CurrencyCode=15]="CurrencyCode",e[e.CurrencySymbol=16]="CurrencySymbol",e[e.CurrencyName=17]="CurrencyName",e[e.Currencies=18]="Currencies",e[e.Directionality=19]="Directionality",e[e.PluralCase=20]="PluralCase",e[e.ExtraData=21]="ExtraData",e}({});const Bo="en-US";let qo=Bo;function Vo(e){var t,n;n="Expected localeId to be defined",null==(t=e)&&function(e,t,n,r){throw new Error("ASSERTION ERROR: "+e+` [Expected=> null != ${t} <=Actual]`)}(n,t),"string"==typeof e&&(qo=e.toLowerCase().replace(/_/g,"-"))}const Uo=new Map;class Ho extends Ye{constructor(e,t){super(),this._parent=t,this._bootstrapComponents=[],this.injector=this,this.destroyCbs=[],this.componentFactoryResolver=new To(this);const n=ht(e),r=e[Re]||null;r&&Vo(r),this._bootstrapComponents=Cn(n.bootstrap),this._r3Injector=Ri(e,t,[{provide:Ye,useValue:this},{provide:eo,useValue:this.componentFactoryResolver}],ye(e)),this._r3Injector._resolveInjectorDefTypes(),this.instance=this.get(e)}get(e,t=Fi.THROW_IF_NOT_FOUND,n=ie.Default){return e===Fi||e===Ye||e===Me?this:this._r3Injector.get(e,t,n)}destroy(){const e=this._r3Injector;!e.destroyed&&e.destroy(),this.destroyCbs.forEach(e=>e()),this.destroyCbs=null}onDestroy(e){this.destroyCbs.push(e)}}class Wo extends class{}{constructor(e){super(),this.moduleType=e,null!==ht(e)&&function e(t){if(null!==t.\u0275mod.id){const e=t.\u0275mod.id;(function(e,t,n){if(t&&t!==n)throw new Error(`Duplicate module registered for ${e} - ${ye(t)} vs ${ye(t.name)}`)})(e,Uo.get(e),t),Uo.set(e,t)}let n=t.\u0275mod.imports;n instanceof Function&&(n=n()),n&&n.forEach(t=>e(t))}(e)}create(e){return new Ho(this.moduleType,e)}}const zo=class extends S{constructor(e=!1){super(),this.__isAsync=e}emit(e){super.next(e)}subscribe(e,t,n){let r,i=e=>null,o=()=>null;e&&"object"==typeof e?(r=this.__isAsync?t=>{setTimeout(()=>e.next(t))}:t=>{e.next(t)},e.error&&(i=this.__isAsync?t=>{setTimeout(()=>e.error(t))}:t=>{e.error(t)}),e.complete&&(o=this.__isAsync?()=>{setTimeout(()=>e.complete())}:()=>{e.complete()})):(r=this.__isAsync?t=>{setTimeout(()=>e(t))}:t=>{e(t)},t&&(i=this.__isAsync?e=>{setTimeout(()=>t(e))}:e=>{t(e)}),n&&(o=this.__isAsync?()=>{setTimeout(()=>n())}:()=>{n()}));const s=super.subscribe(r,i,o);return e instanceof h&&e.add(s),s}};function Go(){return this._results[qi()]()}class Qo{constructor(){this.dirty=!0,this._results=[],this.changes=new zo,this.length=0;const e=qi(),t=Qo.prototype;t[e]||(t[e]=Go)}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,t){return this._results.reduce(e,t)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e){this._results=function e(t,n){void 0===n&&(n=t);for(let r=0;r<t.length;r++){let i=t[r];Array.isArray(i)?(n===t&&(n=t.slice(0,r)),e(i,n)):n!==t&&n.push(i)}return n}(e),this.dirty=!1,this.length=this._results.length,this.last=this._results[this.length-1],this.first=this._results[0]}notifyOnChanges(){this.changes.emit(this)}setDirty(){this.dirty=!0}destroy(){this.changes.complete(),this.changes.unsubscribe()}}class Yo{constructor(e){this.queryList=e,this.matches=null}clone(){return new Yo(this.queryList)}setDirty(){this.queryList.setDirty()}}class Ko{constructor(e=[]){this.queries=e}createEmbeddedView(e){const t=e.queries;if(null!==t){const n=null!==e.contentQueries?e.contentQueries[0]:t.length,r=[];for(let e=0;e<n;e++){const n=t.getByIndex(e);r.push(this.queries[n.indexInDeclarationView].clone())}return new Ko(r)}return null}insertView(e){this.dirtyQueriesWithMatches(e)}detachView(e){this.dirtyQueriesWithMatches(e)}dirtyQueriesWithMatches(e){for(let t=0;t<this.queries.length;t++)null!==os(e,t).matches&&this.queries[t].setDirty()}}class Xo{constructor(e,t,n,r=null){this.predicate=e,this.descendants=t,this.isStatic=n,this.read=r}}class Zo{constructor(e=[]){this.queries=e}elementStart(e,t){for(let n=0;n<this.queries.length;n++)this.queries[n].elementStart(e,t)}elementEnd(e){for(let t=0;t<this.queries.length;t++)this.queries[t].elementEnd(e)}embeddedTView(e){let t=null;for(let n=0;n<this.length;n++){const r=null!==t?t.length:0,i=this.getByIndex(n).embeddedTView(e,r);i&&(i.indexInDeclarationView=n,null!==t?t.push(i):t=[i])}return null!==t?new Zo(t):null}template(e,t){for(let n=0;n<this.queries.length;n++)this.queries[n].template(e,t)}getByIndex(e){return this.queries[e]}get length(){return this.queries.length}track(e){this.queries.push(e)}}class Jo{constructor(e,t=-1){this.metadata=e,this.matches=null,this.indexInDeclarationView=-1,this.crossesNgTemplate=!1,this._appliesToNextNode=!0,this._declarationNodeIndex=t}elementStart(e,t){this.isApplyingToNode(t)&&this.matchTNode(e,t)}elementEnd(e){this._declarationNodeIndex===e.index&&(this._appliesToNextNode=!1)}template(e,t){this.elementStart(e,t)}embeddedTView(e,t){return this.isApplyingToNode(e)?(this.crossesNgTemplate=!0,this.addMatch(-e.index,t),new Jo(this.metadata)):null}isApplyingToNode(e){if(this._appliesToNextNode&&!1===this.metadata.descendants){const t=this._declarationNodeIndex;let n=e.parent;for(;null!==n&&4===n.type&&n.index!==t;)n=n.parent;return t===(null!==n?n.index:-1)}return this._appliesToNextNode}matchTNode(e,t){const n=this.metadata.predicate;if(Array.isArray(n))for(let r=0;r<n.length;r++){const i=n[r];this.matchTNodeWithReadOption(e,t,$o(t,i)),this.matchTNodeWithReadOption(e,t,jn(t,e,i,!1,!1))}else n===ko?0===t.type&&this.matchTNodeWithReadOption(e,t,-1):this.matchTNodeWithReadOption(e,t,jn(t,e,n,!1,!1))}matchTNodeWithReadOption(e,t,n){if(null!==n){const r=this.metadata.read;if(null!==r)if(r===to||r===Co||r===ko&&0===t.type)this.addMatch(t.index,-2);else{const n=jn(t,e,r,!1,!1);null!==n&&this.addMatch(t.index,n)}else this.addMatch(t.index,n)}}addMatch(e,t){null===this.matches?this.matches=[e,t]:this.matches.push(e,t)}}function $o(e,t){const n=e.localNames;if(null!==n)for(let r=0;r<n.length;r+=2)if(n[r]===t)return n[r+1];return null}function es(e,t,n,r){return-1===n?function(e,t){return 3===e.type||4===e.type?wi(to,e,t):0===e.type?Ai(ko,to,e,t):null}(t,e):-2===n?function(e,t,n){return n===to?wi(to,t,e):n===ko?Ai(ko,to,t,e):n===Co?Si(Co,to,t,e):void 0}(e,t,r):Bn(e,e[1],n,t)}function ts(e,t,n,r){const i=t[19].queries[r];if(null===i.matches){const r=e.data,o=n.matches,s=[];for(let e=0;e<o.length;e+=2){const i=o[e];s.push(i<0?null:es(t,r[i],o[e+1],n.metadata.read))}i.matches=s}return i.matches}function ns(e){const t=Ut(),n=Ht(),r=Zt();Jt(r+1);const i=os(n,r);if(e.dirty&&Nt(t)===i.metadata.isStatic){if(null===i.matches)e.reset([]);else{const o=i.crossesNgTemplate?function e(t,n,r,i){const o=t.queries.getByIndex(r),s=o.matches;if(null!==s){const a=ts(t,n,o,r);for(let t=0;t<s.length;t+=2){const r=s[t];if(r>0)i.push(a[t/2]);else{const o=s[t+1],a=n[-r];for(let t=ft;t<a.length;t++){const n=a[t];n[17]===n[3]&&e(n[1],n,o,i)}if(null!==a[9]){const t=a[9];for(let n=0;n<t.length;n++){const r=t[n];e(r[1],r,o,i)}}}}}return i}(n,t,r,[]):ts(n,t,i,r);e.reset(o),e.notifyOnChanges()}return!0}return!1}function rs(e,t,n){!function(e,t,n,r,i,o){e.firstCreatePass&&function(e,t,n){null===e.queries&&(e.queries=new Zo),e.queries.track(new Jo(t,-1))}(e,new Xo(n,r,false,i)),function(e,t){const n=new Qo;xr(e,t,n,n.destroy),null===t[19]&&(t[19]=new Ko),t[19].queries.push(new Yo(n))}(e,t)}(Ht(),Ut(),e,t,n)}function is(){return e=Ut(),t=Zt(),e[19].queries[t].queryList;var e,t}function os(e,t){return e.queries.getByIndex(t)}const ss=new Le("Application Initializer");let as=(()=>{class e{constructor(e){this.appInits=e,this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,t)=>{this.resolve=e,this.reject=t})}runInitializers(){if(this.initialized)return;const e=[],t=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let n=0;n<this.appInits.length;n++){const t=this.appInits[n]();Qi(t)&&e.push(t)}Promise.all(e).then(()=>{t()}).catch(e=>{this.reject(e)}),0===e.length&&t(),this.initialized=!0}}return e.\u0275fac=function(t){return new(t||e)(We(ss,8))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const ls=new Le("AppId"),us={provide:ls,useFactory:function(){return`${cs()}${cs()}${cs()}`},deps:[]};function cs(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const hs=new Le("Platform Initializer"),ds=new Le("Platform ID"),fs=new Le("appBootstrapListener");let ps=(()=>{class e{log(e){console.log(e)}warn(e){console.warn(e)}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const gs=new Le("LocaleId"),ys=new Le("DefaultCurrencyCode");class ms{constructor(e,t){this.ngModuleFactory=e,this.componentFactories=t}}const vs=function(e){return new Wo(e)},_s=vs,bs=function(e){return Promise.resolve(vs(e))},ws=function(e){const t=vs(e),n=Cn(ht(e).declarations).reduce((e,t)=>{const n=ut(t);return n&&e.push(new Io(n)),e},[]);return new ms(t,n)},As=ws,Ss=function(e){return Promise.resolve(ws(e))};let ks=(()=>{class e{constructor(){this.compileModuleSync=_s,this.compileModuleAsync=bs,this.compileModuleAndAllComponentsSync=As,this.compileModuleAndAllComponentsAsync=Ss}clearCache(){}clearCacheFor(e){}getModuleId(e){}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const xs=(()=>Promise.resolve(0))();function Cs(e){"undefined"==typeof Zone?xs.then(()=>{e&&e.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",e)}class Ps{constructor({enableLongStackTrace:e=!1,shouldCoalesceEventChangeDetection:t=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new zo(!1),this.onMicrotaskEmpty=new zo(!1),this.onStable=new zo(!1),this.onError=new zo(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");Zone.assertZonePatched();const n=this;n._nesting=0,n._outer=n._inner=Zone.current,Zone.wtfZoneSpec&&(n._inner=n._inner.fork(Zone.wtfZoneSpec)),Zone.TaskTrackingZoneSpec&&(n._inner=n._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(n._inner=n._inner.fork(Zone.longStackTraceZoneSpec)),n.shouldCoalesceEventChangeDetection=t,n.lastRequestAnimationFrameId=-1,n.nativeRequestAnimationFrame=function(){let e=xe.requestAnimationFrame,t=xe.cancelAnimationFrame;if("undefined"!=typeof Zone&&e&&t){const n=e[Zone.__symbol__("OriginalDelegate")];n&&(e=n);const r=t[Zone.__symbol__("OriginalDelegate")];r&&(t=r)}return{nativeRequestAnimationFrame:e,nativeCancelAnimationFrame:t}}().nativeRequestAnimationFrame,function(e){const t=!!e.shouldCoalesceEventChangeDetection&&e.nativeRequestAnimationFrame&&(()=>{!function(e){-1===e.lastRequestAnimationFrameId&&(e.lastRequestAnimationFrameId=e.nativeRequestAnimationFrame.call(xe,()=>{e.fakeTopEventTask||(e.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{e.lastRequestAnimationFrameId=-1,Os(e),Rs(e)},void 0,()=>{},()=>{})),e.fakeTopEventTask.invoke()}),Os(e))}(e)});e._inner=e._inner.fork({name:"angular",properties:{isAngularZone:!0,maybeDelayChangeDetection:t},onInvokeTask:(n,r,i,o,s,a)=>{try{return Is(e),n.invokeTask(i,o,s,a)}finally{t&&"eventTask"===o.type&&t(),Ls(e)}},onInvoke:(t,n,r,i,o,s,a)=>{try{return Is(e),t.invoke(r,i,o,s,a)}finally{Ls(e)}},onHasTask:(t,n,r,i)=>{t.hasTask(r,i),n===r&&("microTask"==i.change?(e._hasPendingMicrotasks=i.microTask,Os(e),Rs(e)):"macroTask"==i.change&&(e.hasPendingMacrotasks=i.macroTask))},onHandleError:(t,n,r,i)=>(t.handleError(r,i),e.runOutsideAngular(()=>e.onError.emit(i)),!1)})}(n)}static isInAngularZone(){return!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Ps.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}static assertNotInAngularZone(){if(Ps.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}run(e,t,n){return this._inner.run(e,t,n)}runTask(e,t,n,r){const i=this._inner,o=i.scheduleEventTask("NgZoneEvent: "+r,e,Ts,Es,Es);try{return i.runTask(o,t,n)}finally{i.cancelTask(o)}}runGuarded(e,t,n){return this._inner.runGuarded(e,t,n)}runOutsideAngular(e){return this._outer.run(e)}}function Es(){}const Ts={};function Rs(e){if(0==e._nesting&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function Os(e){e.hasPendingMicrotasks=!!(e._hasPendingMicrotasks||e.shouldCoalesceEventChangeDetection&&-1!==e.lastRequestAnimationFrameId)}function Is(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function Ls(e){e._nesting--,Rs(e)}class Ms{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new zo,this.onMicrotaskEmpty=new zo,this.onStable=new zo,this.onError=new zo}run(e,t,n){return e.apply(t,n)}runGuarded(e,t,n){return e.apply(t,n)}runOutsideAngular(e){return e()}runTask(e,t,n,r){return e.apply(t,n)}}let Ns=(()=>{class e{constructor(e){this._ngZone=e,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,this._watchAngularEvents(),e.run(()=>{this.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._didWork=!0,this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{Ps.assertNotInAngularZone(),Cs(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}increasePendingRequestCount(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}decreasePendingRequestCount(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}isStable(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())Cs(()=>{for(;0!==this._callbacks.length;){let e=this._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb(this._didWork)}this._didWork=!1});else{let e=this.getPendingTasks();this._callbacks=this._callbacks.filter(t=>!t.updateCb||!t.updateCb(e)||(clearTimeout(t.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(e=>({source:e.source,creationLocation:e.creationLocation,data:e.data})):[]}addCallback(e,t,n){let r=-1;t&&t>0&&(r=setTimeout(()=>{this._callbacks=this._callbacks.filter(e=>e.timeoutId!==r),e(this._didWork,this.getPendingTasks())},t)),this._callbacks.push({doneCb:e,timeoutId:r,updateCb:n})}whenStable(e,t,n){if(n&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/dist/task-tracking.js" loaded?');this.addCallback(e,t,n),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}findProviders(e,t,n){return[]}}return e.\u0275fac=function(t){return new(t||e)(We(Ps))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})(),Ds=(()=>{class e{constructor(){this._applications=new Map,Bs.addToWindow(this)}registerApplication(e,t){this._applications.set(e,t)}unregisterApplication(e){this._applications.delete(e)}unregisterAllApplications(){this._applications.clear()}getTestability(e){return this._applications.get(e)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(e,t=!0){return Bs.findTestabilityInTree(this,e,t)}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();class Fs{addToWindow(e){}findTestabilityInTree(e,t,n){return null}}let js,Bs=new Fs;const qs=new Le("AllowMultipleToken");function Vs(e,t,n=[]){const r="Platform: "+t,i=new Le(r);return(t=[])=>{let o=Us();if(!o||o.injector.get(qs,!1))if(e)e(n.concat(t).concat({provide:i,useValue:!0}));else{const e=n.concat(t).concat({provide:i,useValue:!0},{provide:ki,useValue:"platform"});!function(e){if(js&&!js.destroyed&&!js.injector.get(qs,!1))throw new Error("There can be only one platform. Destroy the previous one to create a new one.");js=e.get(Hs);const t=e.get(hs,null);t&&t.forEach(e=>e())}(Fi.create({providers:e,name:r}))}return function(e){const t=Us();if(!t)throw new Error("No platform exists!");if(!t.injector.get(e,null))throw new Error("A platform with a different configuration has been created. Please destroy it first.");return t}(i)}}function Us(){return js&&!js.destroyed?js:null}let Hs=(()=>{class e{constructor(e){this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(e,t){const n=function(e,t){let n;return n="noop"===e?new Ms:("zone.js"===e?void 0:e)||new Ps({enableLongStackTrace:Kn(),shouldCoalesceEventChangeDetection:t}),n}(t?t.ngZone:void 0,t&&t.ngZoneEventCoalescing||!1),r=[{provide:Ps,useValue:n}];return n.run(()=>{const t=Fi.create({providers:r,parent:this.injector,name:e.moduleType.name}),i=e.create(t),o=i.injector.get(Gn,null);if(!o)throw new Error("No ErrorHandler. Is platform module (BrowserModule) included?");return i.onDestroy(()=>Gs(this._modules,i)),n.runOutsideAngular(()=>n.onError.subscribe({next:e=>{o.handleError(e)}})),function(e,t,n){try{const r=n();return Qi(r)?r.catch(n=>{throw t.runOutsideAngular(()=>e.handleError(n)),n}):r}catch(r){throw t.runOutsideAngular(()=>e.handleError(r)),r}}(o,n,()=>{const e=i.injector.get(as);return e.runInitializers(),e.donePromise.then(()=>(Vo(i.injector.get(gs,Bo)||Bo),this._moduleDoBootstrap(i),i))})})}bootstrapModule(e,t=[]){const n=Ws({},t);return function(e,t,n){const r=new Wo(n);return Promise.resolve(r)}(0,0,e).then(e=>this.bootstrapModuleFactory(e,n))}_moduleDoBootstrap(e){const t=e.injector.get(zs);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(e=>t.bootstrap(e));else{if(!e.instance.ngDoBootstrap)throw new Error(`The module ${ye(e.instance.constructor)} was bootstrapped, but it does not declare "@NgModule.bootstrap" components nor a "ngDoBootstrap" method. Please define one of these.`);e.instance.ngDoBootstrap(t)}this._modules.push(e)}onDestroy(e){this._destroyListeners.push(e)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Error("The platform has already been destroyed!");this._modules.slice().forEach(e=>e.destroy()),this._destroyListeners.forEach(e=>e()),this._destroyed=!0}get destroyed(){return this._destroyed}}return e.\u0275fac=function(t){return new(t||e)(We(Fi))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();function Ws(e,t){return Array.isArray(t)?t.reduce(Ws,e):Object.assign(Object.assign({},e),t)}let zs=(()=>{class e{constructor(e,t,n,r,i,o){this._zone=e,this._console=t,this._injector=n,this._exceptionHandler=r,this._componentFactoryResolver=i,this._initStatus=o,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._enforceNoNewChanges=!1,this._stable=!0,this.componentTypes=[],this.components=[],this._enforceNoNewChanges=Kn(),this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const s=new v(e=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{e.next(this._stable),e.complete()})}),a=new v(e=>{let t;this._zone.runOutsideAngular(()=>{t=this._zone.onStable.subscribe(()=>{Ps.assertNotInAngularZone(),Cs(()=>{this._stable||this._zone.hasPendingMacrotasks||this._zone.hasPendingMicrotasks||(this._stable=!0,e.next(!0))})})});const n=this._zone.onUnstable.subscribe(()=>{Ps.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{e.next(!1)}))});return()=>{t.unsubscribe(),n.unsubscribe()}});this.isStable=H(s,a.pipe(e=>{return W()((t=X,function(e){let n;n="function"==typeof t?t:function(){return t};const r=Object.create(e,Y);return r.source=e,r.subjectFactory=n,r})(e));var t}))}bootstrap(e,t){if(!this._initStatus.done)throw new Error("Cannot bootstrap as there are still asynchronous initializers running. Bootstrap components in the `ngDoBootstrap` method of the root module.");let n;n=e instanceof Ji?e:this._componentFactoryResolver.resolveComponentFactory(e),this.componentTypes.push(n.componentType);const r=n.isBoundToModule?void 0:this._injector.get(Ye),i=n.create(Fi.NULL,[],t||n.selector,r);i.onDestroy(()=>{this._unloadComponent(i)});const o=i.injector.get(Ns,null);return o&&i.injector.get(Ds).registerApplication(i.location.nativeElement,o),this._loadComponent(i),Kn()&&this._console.log("Angular is running in development mode. Call enableProdMode() to enable production mode."),i}tick(){if(this._runningTick)throw new Error("ApplicationRef.tick is called recursively");try{this._runningTick=!0;for(let e of this._views)e.detectChanges();if(this._enforceNoNewChanges)for(let e of this._views)e.checkNoChanges()}catch(e){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(e))}finally{this._runningTick=!1}}attachView(e){const t=e;this._views.push(t),t.attachToAppRef(this)}detachView(e){const t=e;Gs(this._views,t),t.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e),this._injector.get(fs,[]).concat(this._bootstrapListeners).forEach(t=>t(e))}_unloadComponent(e){this.detachView(e.hostView),Gs(this.components,e)}ngOnDestroy(){this._views.slice().forEach(e=>e.destroy())}get viewCount(){return this._views.length}}return e.\u0275fac=function(t){return new(t||e)(We(Ps),We(ps),We(Fi),We(Gn),We(eo),We(as))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();function Gs(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Qs=Vs(null,"core",[{provide:ds,useValue:"unknown"},{provide:Hs,deps:[Fi]},{provide:Ds,deps:[]},{provide:ps,deps:[]}]),Ys=[{provide:zs,useClass:zs,deps:[Ps,ps,Fi,Gn,eo,as]},{provide:Oo,deps:[Ps],useFactory:function(e){let t=[];return e.onStable.subscribe(()=>{for(;t.length;)t.pop()()}),function(e){t.push(e)}}},{provide:as,useClass:as,deps:[[new te,ss]]},{provide:ks,useClass:ks,deps:[]},us,{provide:_o,useFactory:function(){return Ao},deps:[]},{provide:bo,useFactory:function(){return So},deps:[]},{provide:gs,useFactory:function(e){return Vo(e=e||"undefined"!=typeof $localize&&$localize.locale||Bo),e},deps:[[new ee(gs),new te,new re]]},{provide:ys,useValue:"USD"}];let Ks=(()=>{class e{constructor(e){}}return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)(We(zs))},providers:Ys}),e})();class Xs extends h{constructor(e,t){super()}schedule(e,t=0){return this}}class Zs extends Xs{constructor(e,t){super(e,t),this.scheduler=e,this.work=t,this.pending=!1}schedule(e,t=0){if(this.closed)return this;this.state=e;const n=this.id,r=this.scheduler;return null!=n&&(this.id=this.recycleAsyncId(r,n,t)),this.pending=!0,this.delay=t,this.id=this.id||this.requestAsyncId(r,this.id,t),this}requestAsyncId(e,t,n=0){return setInterval(e.flush.bind(e,this),n)}recycleAsyncId(e,t,n=0){if(null!==n&&this.delay===n&&!1===this.pending)return t;clearInterval(t)}execute(e,t){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const n=this._execute(e,t);if(n)return n;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,t){let n=!1,r=void 0;try{this.work(e)}catch(i){n=!0,r=!!i&&i||new Error(i)}if(n)return this.unsubscribe(),r}_unsubscribe(){const e=this.id,t=this.scheduler,n=t.actions,r=n.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==r&&n.splice(r,1),null!=e&&(this.id=this.recycleAsyncId(t,e,null)),this.delay=null}}class Js extends Zs{constructor(e,t){super(e,t),this.scheduler=e,this.work=t}schedule(e,t=0){return t>0?super.schedule(e,t):(this.delay=t,this.state=e,this.scheduler.flush(this),this)}execute(e,t){return t>0||this.closed?super.execute(e,t):this._execute(e,t)}requestAsyncId(e,t,n=0){return null!==n&&n>0||null===n&&this.delay>0?super.requestAsyncId(e,t,n):e.flush(this)}}let $s=(()=>{class e{constructor(t,n=e.now){this.SchedulerAction=t,this.now=n}schedule(e,t=0,n){return new this.SchedulerAction(this,e).schedule(n,t)}}return e.now=()=>Date.now(),e})();class ea extends $s{constructor(e,t=$s.now){super(e,()=>ea.delegate&&ea.delegate!==this?ea.delegate.now():t()),this.actions=[],this.active=!1,this.scheduled=void 0}schedule(e,t=0,n){return ea.delegate&&ea.delegate!==this?ea.delegate.schedule(e,t,n):super.schedule(e,t,n)}flush(e){const{actions:t}=this;if(this.active)return void t.push(e);let n;this.active=!0;do{if(n=e.execute(e.state,e.delay))break}while(e=t.shift());if(this.active=!1,n){for(;e=t.shift();)e.unsubscribe();throw n}}}class ta extends ea{}const na=new ta(Js),ra=new v(e=>e.complete());let ia=(()=>{class e{constructor(e,t,n){this.kind=e,this.value=t,this.error=n,this.hasValue="N"===e}observe(e){switch(this.kind){case"N":return e.next&&e.next(this.value);case"E":return e.error&&e.error(this.error);case"C":return e.complete&&e.complete()}}do(e,t,n){switch(this.kind){case"N":return e&&e(this.value);case"E":return t&&t(this.error);case"C":return n&&n()}}accept(e,t,n){return e&&"function"==typeof e.next?this.observe(e):this.do(e,t,n)}toObservable(){switch(this.kind){case"N":return function(...e){let t=e[e.length-1];return x(t)?(e.pop(),N(e,t)):U(e)}(this.value);case"E":return e=this.error,new v(t=>t.error(e));case"C":return ra}var e;throw new Error("unexpected notification kind value")}static createNext(t){return void 0!==t?new e("N",t):e.undefinedValueNotification}static createError(t){return new e("E",void 0,t)}static createComplete(){return e.completeNotification}}return e.completeNotification=new e("C"),e.undefinedValueNotification=new e("N",void 0),e})();class oa extends p{constructor(e,t,n=0){super(e),this.scheduler=t,this.delay=n}static dispatch(e){const{notification:t,destination:n}=e;t.observe(n),this.unsubscribe()}scheduleMessage(e){this.destination.add(this.scheduler.schedule(oa.dispatch,this.delay,new sa(e,this.destination)))}_next(e){this.scheduleMessage(ia.createNext(e))}_error(e){this.scheduleMessage(ia.createError(e)),this.unsubscribe()}_complete(){this.scheduleMessage(ia.createComplete()),this.unsubscribe()}}class sa{constructor(e,t){this.notification=e,this.destination=t}}class aa extends S{constructor(e=Number.POSITIVE_INFINITY,t=Number.POSITIVE_INFINITY,n){super(),this.scheduler=n,this._events=[],this._infiniteTimeWindow=!1,this._bufferSize=e<1?1:e,this._windowTime=t<1?1:t,t===Number.POSITIVE_INFINITY?(this._infiniteTimeWindow=!0,this.next=this.nextInfiniteTimeWindow):this.next=this.nextTimeWindow}nextInfiniteTimeWindow(e){const t=this._events;t.push(e),t.length>this._bufferSize&&t.shift(),super.next(e)}nextTimeWindow(e){this._events.push(new la(this._getNow(),e)),this._trimBufferThenGetEvents(),super.next(e)}_subscribe(e){const t=this._infiniteTimeWindow,n=t?this._events:this._trimBufferThenGetEvents(),r=this.scheduler,i=n.length;let o;if(this.closed)throw new b;if(this.isStopped||this.hasError?o=h.EMPTY:(this.observers.push(e),o=new w(this,e)),r&&e.add(e=new oa(e,r)),t)for(let s=0;s<i&&!e.closed;s++)e.next(n[s]);else for(let s=0;s<i&&!e.closed;s++)e.next(n[s].value);return this.hasError?e.error(this.thrownError):this.isStopped&&e.complete(),o}_getNow(){return(this.scheduler||na).now()}_trimBufferThenGetEvents(){const e=this._getNow(),t=this._bufferSize,n=this._windowTime,r=this._events,i=r.length;let o=0;for(;o<i&&!(e-r[o].time<n);)o++;return i>t&&(o=Math.max(o,i-t)),o>0&&r.splice(0,o),r}}class la{constructor(e,t){this.time=e,this.value=t}}class ua{constructor(e){this.project=e}call(e,t){return t.subscribe(new ca(e,this.project))}}class ca extends j{constructor(e,t){super(e),this.project=t,this.index=0}_next(e){let t;const n=this.index++;try{t=this.project(e,n)}catch(r){return void this.destination.error(r)}this._innerSub(t)}_innerSub(e){const t=this.innerSubscription;t&&t.unsubscribe();const n=new F(this),r=this.destination;r.add(n),this.innerSubscription=B(e,n),this.innerSubscription!==n&&r.add(this.innerSubscription)}_complete(){const{innerSubscription:e}=this;e&&!e.closed||super._complete(),this.unsubscribe()}_unsubscribe(){this.innerSubscription=void 0}notifyComplete(){this.innerSubscription=void 0,this.isStopped&&super._complete()}notifyNext(e){this.destination.next(e)}}const ha=(()=>{const e=Element.prototype;return e.matches||e.matchesSelector||e.mozMatchesSelector||e.msMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector})(),da={schedule(e,t){const n=setTimeout(e,t);return()=>clearTimeout(n)},scheduleBeforeRender(e){if("undefined"==typeof window)return da.schedule(e,0);if(void 0===window.requestAnimationFrame)return da.schedule(e,16);const t=window.requestAnimationFrame(e);return()=>window.cancelAnimationFrame(t)}};function fa(e,t,n){let r=n;return function(e){return!!e&&e.nodeType===Node.ELEMENT_NODE}(e)&&t.some((t,n)=>!("*"===t||!function(e,t){return ha.call(e,t)}(e,t)||(r=n,0))),r}class pa{constructor(e,t){this.componentFactory=t.get(eo).resolveComponentFactory(e)}create(e){return new ga(this.componentFactory,e)}}class ga{constructor(e,t){this.componentFactory=e,this.injector=t,this.eventEmitters=new aa(1),this.events=this.eventEmitters.pipe(function e(t,n){return"function"==typeof n?r=>r.pipe(e((e,r)=>D(t(e,r)).pipe(C((t,i)=>n(e,t,r,i))))):e=>e.lift(new ua(t))}(e=>H(...e))),this.componentRef=null,this.inputChanges=null,this.implementsOnChanges=!1,this.scheduledChangeDetectionFn=null,this.scheduledDestroyFn=null,this.initialInputValues=new Map,this.unchangedInputs=new Set,this.ngZone=this.injector.get(Ps),this.elementZone="undefined"==typeof Zone?null:this.ngZone.run(()=>Zone.current)}connect(e){this.runInZone(()=>{if(null!==this.scheduledDestroyFn)return this.scheduledDestroyFn(),void(this.scheduledDestroyFn=null);null===this.componentRef&&this.initializeComponent(e)})}disconnect(){this.runInZone(()=>{null!==this.componentRef&&null===this.scheduledDestroyFn&&(this.scheduledDestroyFn=da.schedule(()=>{null!==this.componentRef&&(this.componentRef.destroy(),this.componentRef=null)},10))})}getInputValue(e){return this.runInZone(()=>null===this.componentRef?this.initialInputValues.get(e):this.componentRef.instance[e])}setInputValue(e,t){this.runInZone(()=>{var n,r;null!==this.componentRef?((n=t)!==(r=this.getInputValue(e))&&(n==n||r==r)||void 0===t&&this.unchangedInputs.has(e))&&(this.recordInputChange(e,t),this.componentRef.instance[e]=t,this.scheduleDetectChanges()):this.initialInputValues.set(e,t)})}initializeComponent(e){const t=Fi.create({providers:[],parent:this.injector}),n=function(e,t){const n=e.childNodes,r=t.map(()=>[]);let i=-1;t.some((e,t)=>"*"===e&&(i=t,!0));for(let o=0,s=n.length;o<s;++o){const e=n[o],s=fa(e,t,i);-1!==s&&r[s].push(e)}return r}(e,this.componentFactory.ngContentSelectors);this.componentRef=this.componentFactory.create(t,n,e),this.implementsOnChanges="function"==typeof this.componentRef.instance.ngOnChanges,this.initializeInputs(),this.initializeOutputs(this.componentRef),this.detectChanges(),this.injector.get(zs).attachView(this.componentRef.hostView)}initializeInputs(){this.componentFactory.inputs.forEach(({propName:e})=>{this.implementsOnChanges&&this.unchangedInputs.add(e),this.initialInputValues.has(e)&&this.setInputValue(e,this.initialInputValues.get(e))}),this.initialInputValues.clear()}initializeOutputs(e){const t=this.componentFactory.outputs.map(({propName:t,templateName:n})=>e.instance[t].pipe(C(e=>({name:n,value:e}))));this.eventEmitters.next(t)}callNgOnChanges(e){if(!this.implementsOnChanges||null===this.inputChanges)return;const t=this.inputChanges;this.inputChanges=null,e.instance.ngOnChanges(t)}scheduleDetectChanges(){this.scheduledChangeDetectionFn||(this.scheduledChangeDetectionFn=da.scheduleBeforeRender(()=>{this.scheduledChangeDetectionFn=null,this.detectChanges()}))}recordInputChange(e,t){if(null!==this.componentRef&&!this.implementsOnChanges)return;null===this.inputChanges&&(this.inputChanges={});const n=this.inputChanges[e];if(n)return void(n.currentValue=t);const r=this.unchangedInputs.has(e);this.unchangedInputs.delete(e);const i=r?void 0:this.getInputValue(e);this.inputChanges[e]=new wt(i,t,r)}detectChanges(){null!==this.componentRef&&(this.callNgOnChanges(this.componentRef),this.componentRef.changeDetectorRef.detectChanges())}runInZone(e){return this.elementZone&&Zone.current!==this.elementZone?this.ngZone.run(e):e()}}class ya extends HTMLElement{constructor(){super(...arguments),this.ngElementEventsSubscription=null}}function ma(e,t){e.forEach(({propName:e})=>{Object.defineProperty(t,e,{get(){return this.ngElementStrategy.getInputValue(e)},set(t){this.ngElementStrategy.setInputValue(e,t)},configurable:!0,enumerable:!0})})}let va=null;function _a(){return va}const ba=new Le("DocumentToken");var wa=function(e){return e[e.Zero=0]="Zero",e[e.One=1]="One",e[e.Two=2]="Two",e[e.Few=3]="Few",e[e.Many=4]="Many",e[e.Other=5]="Other",e}({});class Aa{}let Sa=(()=>{class e extends Aa{constructor(e){super(),this.locale=e}getPluralCategory(e,t){switch(function(e){return function(e){const t=function(e){return e.toLowerCase().replace(/_/g,"-")}(e);let n=Fo(t);if(n)return n;const r=t.split("-")[0];if(n=Fo(r),n)return n;if("en"===r)return No;throw new Error(`Missing locale data for the locale "${e}".`)}(e)[jo.PluralCase]}(t||this.locale)(e)){case wa.Zero:return"zero";case wa.One:return"one";case wa.Two:return"two";case wa.Few:return"few";case wa.Many:return"many";default:return"other"}}}return e.\u0275fac=function(t){return new(t||e)(We(gs))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})(),ka=(()=>{class e{}return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)},providers:[{provide:Aa,useClass:Sa}]}),e})();class xa extends class extends class{}{constructor(){super()}supportsDOMEvents(){return!0}}{static makeCurrent(){var e;e=new xa,va||(va=e)}getProperty(e,t){return e[t]}log(e){window.console&&window.console.log&&window.console.log(e)}logGroup(e){window.console&&window.console.group&&window.console.group(e)}logGroupEnd(){window.console&&window.console.groupEnd&&window.console.groupEnd()}onAndCancel(e,t,n){return e.addEventListener(t,n,!1),()=>{e.removeEventListener(t,n,!1)}}dispatchEvent(e,t){e.dispatchEvent(t)}remove(e){return e.parentNode&&e.parentNode.removeChild(e),e}getValue(e){return e.value}createElement(e,t){return(t=t||this.getDefaultDocument()).createElement(e)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}isShadowRoot(e){return e instanceof DocumentFragment}getGlobalEventTarget(e,t){return"window"===t?window:"document"===t?e:"body"===t?e.body:null}getHistory(){return window.history}getLocation(){return window.location}getBaseHref(e){const t=Pa||(Pa=document.querySelector("base"),Pa)?Pa.getAttribute("href"):null;return null==t?null:(n=t,Ca||(Ca=document.createElement("a")),Ca.setAttribute("href",n),"/"===Ca.pathname.charAt(0)?Ca.pathname:"/"+Ca.pathname);var n}resetBaseElement(){Pa=null}getUserAgent(){return window.navigator.userAgent}performanceNow(){return window.performance&&window.performance.now?window.performance.now():(new Date).getTime()}supportsCookies(){return!0}getCookie(e){return function(e,t){t=encodeURIComponent(t);for(const n of e.split(";")){const e=n.indexOf("="),[r,i]=-1==e?[n,""]:[n.slice(0,e),n.slice(e+1)];if(r.trim()===t)return decodeURIComponent(i)}return null}(document.cookie,e)}}let Ca,Pa=null;const Ea=new Le("TRANSITION_ID"),Ta=[{provide:ss,useFactory:function(e,t,n){return()=>{n.get(as).donePromise.then(()=>{const n=_a();Array.prototype.slice.apply(t.querySelectorAll("style[ng-transition]")).filter(t=>t.getAttribute("ng-transition")===e).forEach(e=>n.remove(e))})}},deps:[Ea,ba,Fi],multi:!0}];class Ra{static init(){var e;e=new Ra,Bs=e}addToWindow(e){xe.getAngularTestability=(t,n=!0)=>{const r=e.findTestabilityInTree(t,n);if(null==r)throw new Error("Could not find testability for element.");return r},xe.getAllAngularTestabilities=()=>e.getAllTestabilities(),xe.getAllAngularRootElements=()=>e.getAllRootElements(),xe.frameworkStabilizers||(xe.frameworkStabilizers=[]),xe.frameworkStabilizers.push(e=>{const t=xe.getAllAngularTestabilities();let n=t.length,r=!1;const i=function(t){r=r||t,n--,0==n&&e(r)};t.forEach((function(e){e.whenStable(i)}))})}findTestabilityInTree(e,t,n){if(null==t)return null;const r=e.getTestability(t);return null!=r?r:n?_a().isShadowRoot(t)?this.findTestabilityInTree(e,t.host,!0):this.findTestabilityInTree(e,t.parentElement,!0):null}}const Oa=new Le("EventManagerPlugins");let Ia=(()=>{class e{constructor(e,t){this._zone=t,this._eventNameToPlugin=new Map,e.forEach(e=>e.manager=this),this._plugins=e.slice().reverse()}addEventListener(e,t,n){return this._findPluginFor(t).addEventListener(e,t,n)}addGlobalEventListener(e,t,n){return this._findPluginFor(t).addGlobalEventListener(e,t,n)}getZone(){return this._zone}_findPluginFor(e){const t=this._eventNameToPlugin.get(e);if(t)return t;const n=this._plugins;for(let r=0;r<n.length;r++){const t=n[r];if(t.supports(e))return this._eventNameToPlugin.set(e,t),t}throw new Error("No event manager plugin found for event "+e)}}return e.\u0275fac=function(t){return new(t||e)(We(Oa),We(Ps))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();class La{constructor(e){this._doc=e}addGlobalEventListener(e,t,n){const r=_a().getGlobalEventTarget(this._doc,e);if(!r)throw new Error(`Unsupported event target ${r} for event ${t}`);return this.addEventListener(r,t,n)}}let Ma=(()=>{class e{constructor(){this._stylesSet=new Set}addStyles(e){const t=new Set;e.forEach(e=>{this._stylesSet.has(e)||(this._stylesSet.add(e),t.add(e))}),this.onStylesAdded(t)}onStylesAdded(e){}getAllStyles(){return Array.from(this._stylesSet)}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})(),Na=(()=>{class e extends Ma{constructor(e){super(),this._doc=e,this._hostNodes=new Set,this._styleNodes=new Set,this._hostNodes.add(e.head)}_addStylesToHost(e,t){e.forEach(e=>{const n=this._doc.createElement("style");n.textContent=e,this._styleNodes.add(t.appendChild(n))})}addHost(e){this._addStylesToHost(this._stylesSet,e),this._hostNodes.add(e)}removeHost(e){this._hostNodes.delete(e)}onStylesAdded(e){this._hostNodes.forEach(t=>this._addStylesToHost(e,t))}ngOnDestroy(){this._styleNodes.forEach(e=>_a().remove(e))}}return e.\u0275fac=function(t){return new(t||e)(We(ba))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const Da={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Fa=/%COMP%/g;function ja(e,t,n){for(let r=0;r<t.length;r++){let i=t[r];Array.isArray(i)?ja(e,i,n):(i=i.replace(Fa,e),n.push(i))}return n}function Ba(e){return t=>{if("__ngUnwrap__"===t)return e;!1===e(t)&&(t.preventDefault(),t.returnValue=!1)}}let qa=(()=>{class e{constructor(e,t,n){this.eventManager=e,this.sharedStylesHost=t,this.appId=n,this.rendererByCompId=new Map,this.defaultRenderer=new Va(e)}createRenderer(e,t){if(!e||!t)return this.defaultRenderer;switch(t.encapsulation){case $e.Emulated:{let n=this.rendererByCompId.get(t.id);return n||(n=new Ua(this.eventManager,this.sharedStylesHost,t,this.appId),this.rendererByCompId.set(t.id,n)),n.applyToHost(e),n}case $e.Native:case $e.ShadowDom:return new Ha(this.eventManager,this.sharedStylesHost,e,t);default:if(!this.rendererByCompId.has(t.id)){const e=ja(t.id,t.styles,[]);this.sharedStylesHost.addStyles(e),this.rendererByCompId.set(t.id,this.defaultRenderer)}return this.defaultRenderer}}begin(){}end(){}}return e.\u0275fac=function(t){return new(t||e)(We(Ia),We(Na),We(ls))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();class Va{constructor(e){this.eventManager=e,this.data=Object.create(null)}destroy(){}createElement(e,t){return t?document.createElementNS(Da[t]||t,e):document.createElement(e)}createComment(e){return document.createComment(e)}createText(e){return document.createTextNode(e)}appendChild(e,t){e.appendChild(t)}insertBefore(e,t,n){e&&e.insertBefore(t,n)}removeChild(e,t){e&&e.removeChild(t)}selectRootElement(e,t){let n="string"==typeof e?document.querySelector(e):e;if(!n)throw new Error(`The selector "${e}" did not match any elements`);return t||(n.textContent=""),n}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,t,n,r){if(r){t=r+":"+t;const i=Da[r];i?e.setAttributeNS(i,t,n):e.setAttribute(t,n)}else e.setAttribute(t,n)}removeAttribute(e,t,n){if(n){const r=Da[n];r?e.removeAttributeNS(r,t):e.removeAttribute(`${n}:${t}`)}else e.removeAttribute(t)}addClass(e,t){e.classList.add(t)}removeClass(e,t){e.classList.remove(t)}setStyle(e,t,n,r){r&io.DashCase?e.style.setProperty(t,n,r&io.Important?"important":""):e.style[t]=n}removeStyle(e,t,n){n&io.DashCase?e.style.removeProperty(t):e.style[t]=""}setProperty(e,t,n){e[t]=n}setValue(e,t){e.nodeValue=t}listen(e,t,n){return"string"==typeof e?this.eventManager.addGlobalEventListener(e,t,Ba(n)):this.eventManager.addEventListener(e,t,Ba(n))}}class Ua extends Va{constructor(e,t,n,r){super(e),this.component=n;const i=ja(r+"-"+n.id,n.styles,[]);t.addStyles(i),this.contentAttr="_ngcontent-%COMP%".replace(Fa,r+"-"+n.id),this.hostAttr="_nghost-%COMP%".replace(Fa,r+"-"+n.id)}applyToHost(e){super.setAttribute(e,this.hostAttr,"")}createElement(e,t){const n=super.createElement(e,t);return super.setAttribute(n,this.contentAttr,""),n}}class Ha extends Va{constructor(e,t,n,r){super(e),this.sharedStylesHost=t,this.hostEl=n,this.component=r,this.shadowRoot=r.encapsulation===$e.ShadowDom?n.attachShadow({mode:"open"}):n.createShadowRoot(),this.sharedStylesHost.addHost(this.shadowRoot);const i=ja(r.id,r.styles,[]);for(let o=0;o<i.length;o++){const e=document.createElement("style");e.textContent=i[o],this.shadowRoot.appendChild(e)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}appendChild(e,t){return super.appendChild(this.nodeOrShadowRoot(e),t)}insertBefore(e,t,n){return super.insertBefore(this.nodeOrShadowRoot(e),t,n)}removeChild(e,t){return super.removeChild(this.nodeOrShadowRoot(e),t)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}}let Wa=(()=>{class e extends La{constructor(e){super(e)}supports(e){return!0}addEventListener(e,t,n){return e.addEventListener(t,n,!1),()=>this.removeEventListener(e,t,n)}removeEventListener(e,t,n){return e.removeEventListener(t,n)}}return e.\u0275fac=function(t){return new(t||e)(We(ba))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const za=["alt","control","meta","shift"],Ga={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qa={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},Ya={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey};let Ka=(()=>{class e extends La{constructor(e){super(e)}supports(t){return null!=e.parseEventName(t)}addEventListener(t,n,r){const i=e.parseEventName(n),o=e.eventCallback(i.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>_a().onAndCancel(t,i.domEventName,o))}static parseEventName(t){const n=t.toLowerCase().split("."),r=n.shift();if(0===n.length||"keydown"!==r&&"keyup"!==r)return null;const i=e._normalizeKey(n.pop());let o="";if(za.forEach(e=>{const t=n.indexOf(e);t>-1&&(n.splice(t,1),o+=e+".")}),o+=i,0!=n.length||0===i.length)return null;const s={};return s.domEventName=r,s.fullKey=o,s}static getEventFullKey(e){let t="",n=function(e){let t=e.key;if(null==t){if(t=e.keyIdentifier,null==t)return"Unidentified";t.startsWith("U+")&&(t=String.fromCharCode(parseInt(t.substring(2),16)),3===e.location&&Qa.hasOwnProperty(t)&&(t=Qa[t]))}return Ga[t]||t}(e);return n=n.toLowerCase()," "===n?n="space":"."===n&&(n="dot"),za.forEach(r=>{r!=n&&(0,Ya[r])(e)&&(t+=r+".")}),t+=n,t}static eventCallback(t,n,r){return i=>{e.getEventFullKey(i)===t&&r.runGuarded(()=>n(i))}}static _normalizeKey(e){switch(e){case"esc":return"escape";default:return e}}}return e.\u0275fac=function(t){return new(t||e)(We(ba))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const Xa=Vs(Qs,"browser",[{provide:ds,useValue:"browser"},{provide:hs,useValue:function(){xa.makeCurrent(),Ra.init()},multi:!0},{provide:ba,useFactory:function(){return function(e){Pt=e}(document),document},deps:[]}]),Za=[[],{provide:ki,useValue:"root"},{provide:Gn,useFactory:function(){return new Gn},deps:[]},{provide:Oa,useClass:Wa,multi:!0,deps:[ba,Ps,ds]},{provide:Oa,useClass:Ka,multi:!0,deps:[ba]},[],{provide:qa,useClass:qa,deps:[Ia,Na,ls]},{provide:ro,useExisting:qa},{provide:Ma,useExisting:Na},{provide:Na,useClass:Na,deps:[ba]},{provide:Ns,useClass:Ns,deps:[Ps]},{provide:Ia,useClass:Ia,deps:[Oa,Ps]},[]];let Ja=(()=>{class e{constructor(e){if(e)throw new Error("BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.")}static withServerTransition(t){return{ngModule:e,providers:[{provide:ls,useValue:t.appId},{provide:Ea,useExisting:ls},Ta]}}}return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)(We(e,12))},providers:Za,imports:[ka,Ks]}),e})();"undefined"!=typeof window&&window;class $a{}const el="*";function tl(e,t=null){return{type:2,steps:e,options:t}}function nl(e){return{type:6,styles:e,offset:null}}function rl(e){Promise.resolve(null).then(e)}class il{constructor(e=0,t=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this.parentPlayer=null,this.totalTime=e+t}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}onStart(e){this._onStartFns.push(e)}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){rl(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){}setPosition(e){}getPosition(){return 0}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(e=>e()),t.length=0}}class ol{constructor(e){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=e;let t=0,n=0,r=0;const i=this.players.length;0==i?rl(()=>this._onFinish()):this.players.forEach(e=>{e.onDone(()=>{++t==i&&this._onFinish()}),e.onDestroy(()=>{++n==i&&this._onDestroy()}),e.onStart(()=>{++r==i&&this._onStart()})}),this.totalTime=this.players.reduce((e,t)=>Math.max(e,t.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this.players.forEach(e=>e.init())}onStart(e){this._onStartFns.push(e)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(e=>e()),this._onStartFns=[])}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(e=>e.play())}pause(){this.players.forEach(e=>e.pause())}restart(){this.players.forEach(e=>e.restart())}finish(){this._onFinish(),this.players.forEach(e=>e.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(e=>e.destroy()),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this.players.forEach(e=>e.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(e){const t=e*this.totalTime;this.players.forEach(e=>{const n=e.totalTime?Math.min(1,t/e.totalTime):1;e.setPosition(n)})}getPosition(){let e=0;return this.players.forEach(t=>{const n=t.getPosition();e=Math.min(n,e)}),e}beforeDestroy(){this.players.forEach(e=>{e.beforeDestroy&&e.beforeDestroy()})}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(e=>e()),t.length=0}}function sl(){return"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)}function al(e){switch(e.length){case 0:return new il;case 1:return e[0];default:return new ol(e)}}function ll(e,t,n,r,i={},o={}){const s=[],a=[];let l=-1,u=null;if(r.forEach(e=>{const n=e.offset,r=n==l,c=r&&u||{};Object.keys(e).forEach(n=>{let r=n,a=e[n];if("offset"!==n)switch(r=t.normalizePropertyName(r,s),a){case"!":a=i[n];break;case el:a=o[n];break;default:a=t.normalizeStyleValue(n,r,a,s)}c[r]=a}),r||a.push(c),u=c,l=n}),s.length){const e="\n - ";throw new Error(`Unable to animate due to the following errors:${e}${s.join(e)}`)}return a}function ul(e,t,n,r){switch(t){case"start":e.onStart(()=>r(n&&cl(n,"start",e)));break;case"done":e.onDone(()=>r(n&&cl(n,"done",e)));break;case"destroy":e.onDestroy(()=>r(n&&cl(n,"destroy",e)))}}function cl(e,t,n){const r=n.totalTime,i=hl(e.element,e.triggerName,e.fromState,e.toState,t||e.phaseName,null==r?e.totalTime:r,!!n.disabled),o=e._data;return null!=o&&(i._data=o),i}function hl(e,t,n,r,i="",o=0,s){return{element:e,triggerName:t,fromState:n,toState:r,phaseName:i,totalTime:o,disabled:!!s}}function dl(e,t,n){let r;return e instanceof Map?(r=e.get(t),r||e.set(t,r=n)):(r=e[t],r||(r=e[t]=n)),r}function fl(e){const t=e.indexOf(":");return[e.substring(1,t),e.substr(t+1)]}let pl=(e,t)=>!1,gl=(e,t)=>!1,yl=(e,t,n)=>[];const ml=sl();(ml||"undefined"!=typeof Element)&&(pl=(e,t)=>e.contains(t),gl=(()=>{if(ml||Element.prototype.matches)return(e,t)=>e.matches(t);{const e=Element.prototype,t=e.matchesSelector||e.mozMatchesSelector||e.msMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector;return t?(e,n)=>t.apply(e,[n]):gl}})(),yl=(e,t,n)=>{let r=[];if(n)r.push(...e.querySelectorAll(t));else{const n=e.querySelector(t);n&&r.push(n)}return r});let vl=null,_l=!1;function bl(e){vl||(vl=("undefined"!=typeof document?document.body:null)||{},_l=!!vl.style&&"WebkitAppearance"in vl.style);let t=!0;return vl.style&&!function(e){return"ebkit"==e.substring(1,6)}(e)&&(t=e in vl.style,!t&&_l)&&(t="Webkit"+e.charAt(0).toUpperCase()+e.substr(1)in vl.style),t}const wl=gl,Al=pl,Sl=yl;function kl(e){const t={};return Object.keys(e).forEach(n=>{const r=n.replace(/([a-z])([A-Z])/g,"$1-$2");t[r]=e[n]}),t}let xl=(()=>{class e{validateStyleProperty(e){return bl(e)}matchesElement(e,t){return wl(e,t)}containsElement(e,t){return Al(e,t)}query(e,t,n){return Sl(e,t,n)}computeStyle(e,t,n){return n||""}animate(e,t,n,r,i,o=[],s){return new il(n,r)}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})(),Cl=(()=>{class e{}return e.NOOP=new xl,e})();const Pl="ng-enter",El="ng-leave",Tl="ng-trigger",Rl=".ng-trigger",Ol="ng-animating",Il=".ng-animating";function Ll(e){if("number"==typeof e)return e;const t=e.match(/^(-?[\.\d]+)(m?s)/);return!t||t.length<2?0:Ml(parseFloat(t[1]),t[2])}function Ml(e,t){switch(t){case"s":return 1e3*e;default:return e}}function Nl(e,t,n){return e.hasOwnProperty("duration")?e:function(e,t,n){let r,i=0,o="";if("string"==typeof e){const n=e.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===n)return t.push(`The provided timing value "${e}" is invalid.`),{duration:0,delay:0,easing:""};r=Ml(parseFloat(n[1]),n[2]);const s=n[3];null!=s&&(i=Ml(parseFloat(s),n[4]));const a=n[5];a&&(o=a)}else r=e;if(!n){let n=!1,o=t.length;r<0&&(t.push("Duration values below 0 are not allowed for this animation step."),n=!0),i<0&&(t.push("Delay values below 0 are not allowed for this animation step."),n=!0),n&&t.splice(o,0,`The provided timing value "${e}" is invalid.`)}return{duration:r,delay:i,easing:o}}(e,t,n)}function Dl(e,t={}){return Object.keys(e).forEach(n=>{t[n]=e[n]}),t}function Fl(e,t,n={}){if(t)for(let r in e)n[r]=e[r];else Dl(e,n);return n}function jl(e,t,n){return n?t+":"+n+";":""}function Bl(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style.item(n);t+=jl(0,r,e.style.getPropertyValue(r))}for(const n in e.style)e.style.hasOwnProperty(n)&&!n.startsWith("_")&&(t+=jl(0,n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),e.style[n]));e.setAttribute("style",t)}function ql(e,t,n){e.style&&(Object.keys(t).forEach(r=>{const i=Yl(r);n&&!n.hasOwnProperty(r)&&(n[r]=e.style[i]),e.style[i]=t[r]}),sl()&&Bl(e))}function Vl(e,t){e.style&&(Object.keys(t).forEach(t=>{const n=Yl(t);e.style[n]=""}),sl()&&Bl(e))}function Ul(e){return Array.isArray(e)?1==e.length?e[0]:tl(e):e}const Hl=new RegExp("{{\\s*(.+?)\\s*}}","g");function Wl(e){let t=[];if("string"==typeof e){let n;for(;n=Hl.exec(e);)t.push(n[1]);Hl.lastIndex=0}return t}function zl(e,t,n){const r=e.toString(),i=r.replace(Hl,(e,r)=>{let i=t[r];return t.hasOwnProperty(r)||(n.push("Please provide a value for the animation param "+r),i=""),i.toString()});return i==r?e:i}function Gl(e){const t=[];let n=e.next();for(;!n.done;)t.push(n.value),n=e.next();return t}const Ql=/-+([a-z0-9])/g;function Yl(e){return e.replace(Ql,(...e)=>e[1].toUpperCase())}function Kl(e,t){return 0===e||0===t}function Xl(e,t,n){const r=Object.keys(n);if(r.length&&t.length){let o=t[0],s=[];if(r.forEach(e=>{o.hasOwnProperty(e)||s.push(e),o[e]=n[e]}),s.length)for(var i=1;i<t.length;i++){let n=t[i];s.forEach((function(t){n[t]=Jl(e,t)}))}}return t}function Zl(e,t,n){switch(t.type){case 7:return e.visitTrigger(t,n);case 0:return e.visitState(t,n);case 1:return e.visitTransition(t,n);case 2:return e.visitSequence(t,n);case 3:return e.visitGroup(t,n);case 4:return e.visitAnimate(t,n);case 5:return e.visitKeyframes(t,n);case 6:return e.visitStyle(t,n);case 8:return e.visitReference(t,n);case 9:return e.visitAnimateChild(t,n);case 10:return e.visitAnimateRef(t,n);case 11:return e.visitQuery(t,n);case 12:return e.visitStagger(t,n);default:throw new Error("Unable to resolve animation metadata node #"+t.type)}}function Jl(e,t){return window.getComputedStyle(e)[t]}const $l="*";function eu(e,t){const n=[];return"string"==typeof e?e.split(/\s*,\s*/).forEach(e=>function(e,t,n){if(":"==e[0]){const r=function(e,t){switch(e){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(e,t)=>parseFloat(t)>parseFloat(e);case":decrement":return(e,t)=>parseFloat(t)<parseFloat(e);default:return t.push(`The transition alias value "${e}" is not supported`),"* => *"}}(e,n);if("function"==typeof r)return void t.push(r);e=r}const r=e.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(null==r||r.length<4)return n.push(`The provided transition expression "${e}" is not supported`),t;const i=r[1],o=r[2],s=r[3];t.push(ru(i,s)),"<"!=o[0]||i==$l&&s==$l||t.push(ru(s,i))}(e,n,t)):n.push(e),n}const tu=new Set(["true","1"]),nu=new Set(["false","0"]);function ru(e,t){const n=tu.has(e)||nu.has(e),r=tu.has(t)||nu.has(t);return(i,o)=>{let s=e==$l||e==i,a=t==$l||t==o;return!s&&n&&"boolean"==typeof i&&(s=i?tu.has(e):nu.has(e)),!a&&r&&"boolean"==typeof o&&(a=o?tu.has(t):nu.has(t)),s&&a}}const iu=new RegExp("s*:selfs*,?","g");function ou(e,t,n){return new su(e).build(t,n)}class su{constructor(e){this._driver=e}build(e,t){const n=new au(t);return this._resetContextStyleTimingState(n),Zl(this,Ul(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector="",e.collectedStyles={},e.collectedStyles[""]={},e.currentTime=0}visitTrigger(e,t){let n=t.queryCount=0,r=t.depCount=0;const i=[],o=[];return"@"==e.name.charAt(0)&&t.errors.push("animation triggers cannot be prefixed with an `@` sign (e.g. trigger('@foo', [...]))"),e.definitions.forEach(e=>{if(this._resetContextStyleTimingState(t),0==e.type){const n=e,r=n.name;r.toString().split(/\s*,\s*/).forEach(e=>{n.name=e,i.push(this.visitState(n,t))}),n.name=r}else if(1==e.type){const i=this.visitTransition(e,t);n+=i.queryCount,r+=i.depCount,o.push(i)}else t.errors.push("only state() and transition() definitions can sit inside of a trigger()")}),{type:7,name:e.name,states:i,transitions:o,queryCount:n,depCount:r,options:null}}visitState(e,t){const n=this.visitStyle(e.styles,t),r=e.options&&e.options.params||null;if(n.containsDynamicStyles){const i=new Set,o=r||{};if(n.styles.forEach(e=>{if(lu(e)){const t=e;Object.keys(t).forEach(e=>{Wl(t[e]).forEach(e=>{o.hasOwnProperty(e)||i.add(e)})})}}),i.size){const n=Gl(i.values());t.errors.push(`state("${e.name}", ...) must define default values for all the following style substitutions: ${n.join(", ")}`)}}return{type:0,name:e.name,style:n,options:r?{params:r}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;const n=Zl(this,Ul(e.animation),t);return{type:1,matchers:eu(e.expr,t.errors),animation:n,queryCount:t.queryCount,depCount:t.depCount,options:uu(e.options)}}visitSequence(e,t){return{type:2,steps:e.steps.map(e=>Zl(this,e,t)),options:uu(e.options)}}visitGroup(e,t){const n=t.currentTime;let r=0;const i=e.steps.map(e=>{t.currentTime=n;const i=Zl(this,e,t);return r=Math.max(r,t.currentTime),i});return t.currentTime=r,{type:3,steps:i,options:uu(e.options)}}visitAnimate(e,t){const n=function(e,t){let n=null;if(e.hasOwnProperty("duration"))n=e;else if("number"==typeof e)return cu(Nl(e,t).duration,0,"");const r=e;if(r.split(/\s+/).some(e=>"{"==e.charAt(0)&&"{"==e.charAt(1))){const e=cu(0,0,"");return e.dynamic=!0,e.strValue=r,e}return n=n||Nl(r,t),cu(n.duration,n.delay,n.easing)}(e.timings,t.errors);let r;t.currentAnimateTimings=n;let i=e.styles?e.styles:nl({});if(5==i.type)r=this.visitKeyframes(i,t);else{let i=e.styles,o=!1;if(!i){o=!0;const e={};n.easing&&(e.easing=n.easing),i=nl(e)}t.currentTime+=n.duration+n.delay;const s=this.visitStyle(i,t);s.isEmptyStep=o,r=s}return t.currentAnimateTimings=null,{type:4,timings:n,style:r,options:null}}visitStyle(e,t){const n=this._makeStyleAst(e,t);return this._validateStyleAst(n,t),n}_makeStyleAst(e,t){const n=[];Array.isArray(e.styles)?e.styles.forEach(e=>{"string"==typeof e?e==el?n.push(e):t.errors.push(`The provided style string value ${e} is not allowed.`):n.push(e)}):n.push(e.styles);let r=!1,i=null;return n.forEach(e=>{if(lu(e)){const t=e,n=t.easing;if(n&&(i=n,delete t.easing),!r)for(let e in t)if(t[e].toString().indexOf("{{")>=0){r=!0;break}}}),{type:6,styles:n,easing:i,offset:e.offset,containsDynamicStyles:r,options:null}}_validateStyleAst(e,t){const n=t.currentAnimateTimings;let r=t.currentTime,i=t.currentTime;n&&i>0&&(i-=n.duration+n.delay),e.styles.forEach(e=>{"string"!=typeof e&&Object.keys(e).forEach(n=>{if(!this._driver.validateStyleProperty(n))return void t.errors.push(`The provided animation property "${n}" is not a supported CSS property for animations`);const o=t.collectedStyles[t.currentQuerySelector],s=o[n];let a=!0;s&&(i!=r&&i>=s.startTime&&r<=s.endTime&&(t.errors.push(`The CSS property "${n}" that exists between the times of "${s.startTime}ms" and "${s.endTime}ms" is also being animated in a parallel animation between the times of "${i}ms" and "${r}ms"`),a=!1),i=s.startTime),a&&(o[n]={startTime:i,endTime:r}),t.options&&function(e,t,n){const r=t.params||{},i=Wl(e);i.length&&i.forEach(e=>{r.hasOwnProperty(e)||n.push(`Unable to resolve the local animation param ${e} in the given list of values`)})}(e[n],t.options,t.errors)})})}visitKeyframes(e,t){const n={type:5,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push("keyframes() must be placed inside of a call to animate()"),n;let r=0;const i=[];let o=!1,s=!1,a=0;const l=e.steps.map(e=>{const n=this._makeStyleAst(e,t);let l=null!=n.offset?n.offset:function(e){if("string"==typeof e)return null;let t=null;if(Array.isArray(e))e.forEach(e=>{if(lu(e)&&e.hasOwnProperty("offset")){const n=e;t=parseFloat(n.offset),delete n.offset}});else if(lu(e)&&e.hasOwnProperty("offset")){const n=e;t=parseFloat(n.offset),delete n.offset}return t}(n.styles),u=0;return null!=l&&(r++,u=n.offset=l),s=s||u<0||u>1,o=o||u<a,a=u,i.push(u),n});s&&t.errors.push("Please ensure that all keyframe offsets are between 0 and 1"),o&&t.errors.push("Please ensure that all keyframe offsets are in order");const u=e.steps.length;let c=0;r>0&&r<u?t.errors.push("Not all style() steps within the declared keyframes() contain offsets"):0==r&&(c=1/(u-1));const h=u-1,d=t.currentTime,f=t.currentAnimateTimings,p=f.duration;return l.forEach((e,r)=>{const o=c>0?r==h?1:c*r:i[r],s=o*p;t.currentTime=d+f.delay+s,f.duration=s,this._validateStyleAst(e,t),e.offset=o,n.styles.push(e)}),n}visitReference(e,t){return{type:8,animation:Zl(this,Ul(e.animation),t),options:uu(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:9,options:uu(e.options)}}visitAnimateRef(e,t){return{type:10,animation:this.visitReference(e.animation,t),options:uu(e.options)}}visitQuery(e,t){const n=t.currentQuerySelector,r=e.options||{};t.queryCount++,t.currentQuery=e;const[i,o]=function(e){const t=!!e.split(/\s*,\s*/).find(e=>":self"==e);return t&&(e=e.replace(iu,"")),[e=e.replace(/@\*/g,Rl).replace(/@\w+/g,e=>".ng-trigger-"+e.substr(1)).replace(/:animating/g,Il),t]}(e.selector);t.currentQuerySelector=n.length?n+" "+i:i,dl(t.collectedStyles,t.currentQuerySelector,{});const s=Zl(this,Ul(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=n,{type:11,selector:i,limit:r.limit||0,optional:!!r.optional,includeSelf:o,animation:s,originalSelector:e.selector,options:uu(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push("stagger() can only be used inside of query()");const n="full"===e.timings?{duration:0,delay:0,easing:"full"}:Nl(e.timings,t.errors,!0);return{type:12,animation:Zl(this,Ul(e.animation),t),timings:n,options:null}}}class au{constructor(e){this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles={},this.options=null}}function lu(e){return!Array.isArray(e)&&"object"==typeof e}function uu(e){var t;return e?(e=Dl(e)).params&&(e.params=(t=e.params)?Dl(t):null):e={},e}function cu(e,t,n){return{duration:e,delay:t,easing:n}}function hu(e,t,n,r,i,o,s=null,a=!1){return{type:1,element:e,keyframes:t,preStyleProps:n,postStyleProps:r,duration:i,delay:o,totalTime:i+o,easing:s,subTimeline:a}}class du{constructor(){this._map=new Map}consume(e){let t=this._map.get(e);return t?this._map.delete(e):t=[],t}append(e,t){let n=this._map.get(e);n||this._map.set(e,n=[]),n.push(...t)}has(e){return this._map.has(e)}clear(){this._map.clear()}}const fu=new RegExp(":enter","g"),pu=new RegExp(":leave","g");function gu(e,t,n,r,i,o={},s={},a,l,u=[]){return(new yu).buildKeyframes(e,t,n,r,i,o,s,a,l,u)}class yu{buildKeyframes(e,t,n,r,i,o,s,a,l,u=[]){l=l||new du;const c=new vu(e,t,l,r,i,u,[]);c.options=a,c.currentTimeline.setStyles([o],null,c.errors,a),Zl(this,n,c);const h=c.timelines.filter(e=>e.containsAnimation());if(h.length&&Object.keys(s).length){const e=h[h.length-1];e.allowOnlyTimelineStyles()||e.setStyles([s],null,c.errors,a)}return h.length?h.map(e=>e.buildKeyframes()):[hu(t,[],[],[],0,0,"",!1)]}visitTrigger(e,t){}visitState(e,t){}visitTransition(e,t){}visitAnimateChild(e,t){const n=t.subInstructions.consume(t.element);if(n){const r=t.createSubContext(e.options),i=t.currentTimeline.currentTime,o=this._visitSubInstructions(n,r,r.options);i!=o&&t.transformIntoNewTimeline(o)}t.previousNode=e}visitAnimateRef(e,t){const n=t.createSubContext(e.options);n.transformIntoNewTimeline(),this.visitReference(e.animation,n),t.transformIntoNewTimeline(n.currentTimeline.currentTime),t.previousNode=e}_visitSubInstructions(e,t,n){let r=t.currentTimeline.currentTime;const i=null!=n.duration?Ll(n.duration):null,o=null!=n.delay?Ll(n.delay):null;return 0!==i&&e.forEach(e=>{const n=t.appendInstructionToTimeline(e,i,o);r=Math.max(r,n.duration+n.delay)}),r}visitReference(e,t){t.updateOptions(e.options,!0),Zl(this,e.animation,t),t.previousNode=e}visitSequence(e,t){const n=t.subContextCount;let r=t;const i=e.options;if(i&&(i.params||i.delay)&&(r=t.createSubContext(i),r.transformIntoNewTimeline(),null!=i.delay)){6==r.previousNode.type&&(r.currentTimeline.snapshotCurrentStyles(),r.previousNode=mu);const e=Ll(i.delay);r.delayNextStep(e)}e.steps.length&&(e.steps.forEach(e=>Zl(this,e,r)),r.currentTimeline.applyStylesToKeyframe(),r.subContextCount>n&&r.transformIntoNewTimeline()),t.previousNode=e}visitGroup(e,t){const n=[];let r=t.currentTimeline.currentTime;const i=e.options&&e.options.delay?Ll(e.options.delay):0;e.steps.forEach(o=>{const s=t.createSubContext(e.options);i&&s.delayNextStep(i),Zl(this,o,s),r=Math.max(r,s.currentTimeline.currentTime),n.push(s.currentTimeline)}),n.forEach(e=>t.currentTimeline.mergeTimelineCollectedStyles(e)),t.transformIntoNewTimeline(r),t.previousNode=e}_visitTiming(e,t){if(e.dynamic){const n=e.strValue;return Nl(t.params?zl(n,t.params,t.errors):n,t.errors)}return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,t){const n=t.currentAnimateTimings=this._visitTiming(e.timings,t),r=t.currentTimeline;n.delay&&(t.incrementTime(n.delay),r.snapshotCurrentStyles());const i=e.style;5==i.type?this.visitKeyframes(i,t):(t.incrementTime(n.duration),this.visitStyle(i,t),r.applyStylesToKeyframe()),t.currentAnimateTimings=null,t.previousNode=e}visitStyle(e,t){const n=t.currentTimeline,r=t.currentAnimateTimings;!r&&n.getCurrentStyleProperties().length&&n.forwardFrame();const i=r&&r.easing||e.easing;e.isEmptyStep?n.applyEmptyStep(i):n.setStyles(e.styles,i,t.errors,t.options),t.previousNode=e}visitKeyframes(e,t){const n=t.currentAnimateTimings,r=t.currentTimeline.duration,i=n.duration,o=t.createSubContext().currentTimeline;o.easing=n.easing,e.styles.forEach(e=>{o.forwardTime((e.offset||0)*i),o.setStyles(e.styles,e.easing,t.errors,t.options),o.applyStylesToKeyframe()}),t.currentTimeline.mergeTimelineCollectedStyles(o),t.transformIntoNewTimeline(r+i),t.previousNode=e}visitQuery(e,t){const n=t.currentTimeline.currentTime,r=e.options||{},i=r.delay?Ll(r.delay):0;i&&(6===t.previousNode.type||0==n&&t.currentTimeline.getCurrentStyleProperties().length)&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=mu);let o=n;const s=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!r.optional,t.errors);t.currentQueryTotal=s.length;let a=null;s.forEach((n,r)=>{t.currentQueryIndex=r;const s=t.createSubContext(e.options,n);i&&s.delayNextStep(i),n===t.element&&(a=s.currentTimeline),Zl(this,e.animation,s),s.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,s.currentTimeline.currentTime)}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(o),a&&(t.currentTimeline.mergeTimelineCollectedStyles(a),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e}visitStagger(e,t){const n=t.parentContext,r=t.currentTimeline,i=e.timings,o=Math.abs(i.duration),s=o*(t.currentQueryTotal-1);let a=o*t.currentQueryIndex;switch(i.duration<0?"reverse":i.easing){case"reverse":a=s-a;break;case"full":a=n.currentStaggerTime}const l=t.currentTimeline;a&&l.delayNextStep(a);const u=l.currentTime;Zl(this,e.animation,t),t.previousNode=e,n.currentStaggerTime=r.currentTime-u+(r.startTime-n.currentTimeline.startTime)}}const mu={};class vu{constructor(e,t,n,r,i,o,s,a){this._driver=e,this.element=t,this.subInstructions=n,this._enterClassName=r,this._leaveClassName=i,this.errors=o,this.timelines=s,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=mu,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=a||new _u(this._driver,t,0),s.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,t){if(!e)return;const n=e;let r=this.options;null!=n.duration&&(r.duration=Ll(n.duration)),null!=n.delay&&(r.delay=Ll(n.delay));const i=n.params;if(i){let e=r.params;e||(e=this.options.params={}),Object.keys(i).forEach(n=>{t&&e.hasOwnProperty(n)||(e[n]=zl(i[n],e,this.errors))})}}_copyOptions(){const e={};if(this.options){const t=this.options.params;if(t){const n=e.params={};Object.keys(t).forEach(e=>{n[e]=t[e]})}}return e}createSubContext(e=null,t,n){const r=t||this.element,i=new vu(this._driver,r,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(r,n||0));return i.previousNode=this.previousNode,i.currentAnimateTimings=this.currentAnimateTimings,i.options=this._copyOptions(),i.updateOptions(e),i.currentQueryIndex=this.currentQueryIndex,i.currentQueryTotal=this.currentQueryTotal,i.parentContext=this,this.subContextCount++,i}transformIntoNewTimeline(e){return this.previousNode=mu,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,t,n){const r={duration:null!=t?t:e.duration,delay:this.currentTimeline.currentTime+(null!=n?n:0)+e.delay,easing:""},i=new bu(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,r,e.stretchStartingKeyframe);return this.timelines.push(i),r}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,t,n,r,i,o){let s=[];if(r&&s.push(this.element),e.length>0){e=(e=e.replace(fu,"."+this._enterClassName)).replace(pu,"."+this._leaveClassName);let t=this._driver.query(this.element,e,1!=n);0!==n&&(t=n<0?t.slice(t.length+n,t.length):t.slice(0,n)),s.push(...t)}return i||0!=s.length||o.push(`\`query("${t}")\` returned zero elements. (Use \`query("${t}", { optional: true })\` if you wish to allow this.)`),s}}class _u{constructor(e,t,n,r){this._driver=e,this.element=t,this.startTime=n,this._elementTimelineStylesLookup=r,this.duration=0,this._previousKeyframe={},this._currentKeyframe={},this._keyframes=new Map,this._styleSummary={},this._pendingStyles={},this._backFill={},this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._localTimelineStyles=Object.create(this._backFill,{}),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(t),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(t,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.getCurrentStyleProperties().length>0;default:return!0}}getCurrentStyleProperties(){return Object.keys(this._currentKeyframe)}get currentTime(){return this.startTime+this.duration}delayNextStep(e){const t=1==this._keyframes.size&&Object.keys(this._pendingStyles).length;this.duration||t?(this.forwardTime(this.currentTime+e),t&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,t){return this.applyStylesToKeyframe(),new _u(this._driver,e,t||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=Object.create(this._backFill,{}),this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,t){this._localTimelineStyles[e]=t,this._globalTimelineStyles[e]=t,this._styleSummary[e]={time:this.currentTime,value:t}}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&(this._previousKeyframe.easing=e),Object.keys(this._globalTimelineStyles).forEach(e=>{this._backFill[e]=this._globalTimelineStyles[e]||el,this._currentKeyframe[e]=el}),this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,t,n,r){t&&(this._previousKeyframe.easing=t);const i=r&&r.params||{},o=function(e,t){const n={};let r;return e.forEach(e=>{"*"===e?(r=r||Object.keys(t),r.forEach(e=>{n[e]=el})):Fl(e,!1,n)}),n}(e,this._globalTimelineStyles);Object.keys(o).forEach(e=>{const t=zl(o[e],i,n);this._pendingStyles[e]=t,this._localTimelineStyles.hasOwnProperty(e)||(this._backFill[e]=this._globalTimelineStyles.hasOwnProperty(e)?this._globalTimelineStyles[e]:el),this._updateStyle(e,t)})}applyStylesToKeyframe(){const e=this._pendingStyles,t=Object.keys(e);0!=t.length&&(this._pendingStyles={},t.forEach(t=>{this._currentKeyframe[t]=e[t]}),Object.keys(this._localTimelineStyles).forEach(e=>{this._currentKeyframe.hasOwnProperty(e)||(this._currentKeyframe[e]=this._localTimelineStyles[e])}))}snapshotCurrentStyles(){Object.keys(this._localTimelineStyles).forEach(e=>{const t=this._localTimelineStyles[e];this._pendingStyles[e]=t,this._updateStyle(e,t)})}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const e=[];for(let t in this._currentKeyframe)e.push(t);return e}mergeTimelineCollectedStyles(e){Object.keys(e._styleSummary).forEach(t=>{const n=this._styleSummary[t],r=e._styleSummary[t];(!n||r.time>n.time)&&this._updateStyle(t,r.value)})}buildKeyframes(){this.applyStylesToKeyframe();const e=new Set,t=new Set,n=1===this._keyframes.size&&0===this.duration;let r=[];this._keyframes.forEach((i,o)=>{const s=Fl(i,!0);Object.keys(s).forEach(n=>{const r=s[n];"!"==r?e.add(n):r==el&&t.add(n)}),n||(s.offset=o/this.duration),r.push(s)});const i=e.size?Gl(e.values()):[],o=t.size?Gl(t.values()):[];if(n){const e=r[0],t=Dl(e);e.offset=0,t.offset=1,r=[e,t]}return hu(this.element,r,i,o,this.duration,this.startTime,this.easing,!1)}}class bu extends _u{constructor(e,t,n,r,i,o,s=!1){super(e,t,o.delay),this.element=t,this.keyframes=n,this.preStyleProps=r,this.postStyleProps=i,this._stretchStartingKeyframe=s,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:t,duration:n,easing:r}=this.timings;if(this._stretchStartingKeyframe&&t){const i=[],o=n+t,s=t/o,a=Fl(e[0],!1);a.offset=0,i.push(a);const l=Fl(e[0],!1);l.offset=wu(s),i.push(l);const u=e.length-1;for(let r=1;r<=u;r++){let s=Fl(e[r],!1);s.offset=wu((t+s.offset*n)/o),i.push(s)}n=o,t=0,r="",e=i}return hu(this.element,e,this.preStyleProps,this.postStyleProps,n,t,r,!0)}}function wu(e,t=3){const n=Math.pow(10,t-1);return Math.round(e*n)/n}class Au{}class Su extends Au{normalizePropertyName(e,t){return Yl(e)}normalizeStyleValue(e,t,n,r){let i="";const o=n.toString().trim();if(ku[t]&&0!==n&&"0"!==n)if("number"==typeof n)i="px";else{const t=n.match(/^[+-]?[\d\.]+([a-z]*)$/);t&&0==t[1].length&&r.push(`Please provide a CSS unit value for ${e}:${n}`)}return o+i}}const ku=(()=>function(e){const t={};return e.forEach(e=>t[e]=!0),t}("width,height,minWidth,minHeight,maxWidth,maxHeight,left,top,bottom,right,fontSize,outlineWidth,outlineOffset,paddingTop,paddingLeft,paddingBottom,paddingRight,marginTop,marginLeft,marginBottom,marginRight,borderRadius,borderWidth,borderTopWidth,borderLeftWidth,borderRightWidth,borderBottomWidth,textIndent,perspective".split(",")))();function xu(e,t,n,r,i,o,s,a,l,u,c,h,d){return{type:0,element:e,triggerName:t,isRemovalTransition:i,fromState:n,fromStyles:o,toState:r,toStyles:s,timelines:a,queriedElements:l,preStyleProps:u,postStyleProps:c,totalTime:h,errors:d}}const Cu={};class Pu{constructor(e,t,n){this._triggerName=e,this.ast=t,this._stateStyles=n}match(e,t,n,r){return function(e,t,n,r,i){return e.some(e=>e(t,n,r,i))}(this.ast.matchers,e,t,n,r)}buildStyles(e,t,n){const r=this._stateStyles["*"],i=this._stateStyles[e],o=r?r.buildStyles(t,n):{};return i?i.buildStyles(t,n):o}build(e,t,n,r,i,o,s,a,l,u){const c=[],h=this.ast.options&&this.ast.options.params||Cu,d=this.buildStyles(n,s&&s.params||Cu,c),f=a&&a.params||Cu,p=this.buildStyles(r,f,c),g=new Set,y=new Map,m=new Map,v="void"===r,_={params:Object.assign(Object.assign({},h),f)},b=u?[]:gu(e,t,this.ast.animation,i,o,d,p,_,l,c);let w=0;if(b.forEach(e=>{w=Math.max(e.duration+e.delay,w)}),c.length)return xu(t,this._triggerName,n,r,v,d,p,[],[],y,m,w,c);b.forEach(e=>{const n=e.element,r=dl(y,n,{});e.preStyleProps.forEach(e=>r[e]=!0);const i=dl(m,n,{});e.postStyleProps.forEach(e=>i[e]=!0),n!==t&&g.add(n)});const A=Gl(g.values());return xu(t,this._triggerName,n,r,v,d,p,b,A,y,m,w)}}class Eu{constructor(e,t){this.styles=e,this.defaultParams=t}buildStyles(e,t){const n={},r=Dl(this.defaultParams);return Object.keys(e).forEach(t=>{const n=e[t];null!=n&&(r[t]=n)}),this.styles.styles.forEach(e=>{if("string"!=typeof e){const i=e;Object.keys(i).forEach(e=>{let o=i[e];o.length>1&&(o=zl(o,r,t)),n[e]=o})}}),n}}class Tu{constructor(e,t){this.name=e,this.ast=t,this.transitionFactories=[],this.states={},t.states.forEach(e=>{this.states[e.name]=new Eu(e.style,e.options&&e.options.params||{})}),Ru(this.states,"true","1"),Ru(this.states,"false","0"),t.transitions.forEach(t=>{this.transitionFactories.push(new Pu(e,t,this.states))}),this.fallbackTransition=new Pu(e,{type:1,animation:{type:2,steps:[],options:null},matchers:[(e,t)=>!0],options:null,queryCount:0,depCount:0},this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,n,r){return this.transitionFactories.find(i=>i.match(e,t,n,r))||null}matchStyles(e,t,n){return this.fallbackTransition.buildStyles(e,t,n)}}function Ru(e,t,n){e.hasOwnProperty(t)?e.hasOwnProperty(n)||(e[n]=e[t]):e.hasOwnProperty(n)&&(e[t]=e[n])}const Ou=new du;class Iu{constructor(e,t,n){this.bodyNode=e,this._driver=t,this._normalizer=n,this._animations={},this._playersById={},this.players=[]}register(e,t){const n=[],r=ou(this._driver,t,n);if(n.length)throw new Error("Unable to build the animation due to the following errors: "+n.join("\n"));this._animations[e]=r}_buildPlayer(e,t,n){const r=e.element,i=ll(0,this._normalizer,0,e.keyframes,t,n);return this._driver.animate(r,i,e.duration,e.delay,e.easing,[],!0)}create(e,t,n={}){const r=[],i=this._animations[e];let o;const s=new Map;if(i?(o=gu(this._driver,t,i,Pl,El,{},{},n,Ou,r),o.forEach(e=>{const t=dl(s,e.element,{});e.postStyleProps.forEach(e=>t[e]=null)})):(r.push("The requested animation doesn't exist or has already been destroyed"),o=[]),r.length)throw new Error("Unable to create the animation due to the following errors: "+r.join("\n"));s.forEach((e,t)=>{Object.keys(e).forEach(n=>{e[n]=this._driver.computeStyle(t,n,el)})});const a=al(o.map(e=>{const t=s.get(e.element);return this._buildPlayer(e,{},t)}));return this._playersById[e]=a,a.onDestroy(()=>this.destroy(e)),this.players.push(a),a}destroy(e){const t=this._getPlayer(e);t.destroy(),delete this._playersById[e];const n=this.players.indexOf(t);n>=0&&this.players.splice(n,1)}_getPlayer(e){const t=this._playersById[e];if(!t)throw new Error("Unable to find the timeline player referenced by "+e);return t}listen(e,t,n,r){const i=hl(t,"","","");return ul(this._getPlayer(e),n,i,r),()=>{}}command(e,t,n,r){if("register"==n)return void this.register(e,r[0]);if("create"==n)return void this.create(e,t,r[0]||{});const i=this._getPlayer(e);switch(n){case"play":i.play();break;case"pause":i.pause();break;case"reset":i.reset();break;case"restart":i.restart();break;case"finish":i.finish();break;case"init":i.init();break;case"setPosition":i.setPosition(parseFloat(r[0]));break;case"destroy":this.destroy(e)}}}const Lu="ng-animate-queued",Mu="ng-animate-disabled",Nu=".ng-animate-disabled",Du=[],Fu={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},ju={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0};class Bu{constructor(e,t=""){this.namespaceId=t;const n=e&&e.hasOwnProperty("value");if(this.value=null!=(r=n?e.value:e)?r:null,n){const t=Dl(e);delete t.value,this.options=t}else this.options={};var r;this.options.params||(this.options.params={})}get params(){return this.options.params}absorbOptions(e){const t=e.params;if(t){const e=this.options.params;Object.keys(t).forEach(n=>{null==e[n]&&(e[n]=t[n])})}}}const qu="void",Vu=new Bu(qu);class Uu{constructor(e,t,n){this.id=e,this.hostElement=t,this._engine=n,this.players=[],this._triggers={},this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,Ku(t,this._hostClassName)}listen(e,t,n,r){if(!this._triggers.hasOwnProperty(t))throw new Error(`Unable to listen on the animation trigger event "${n}" because the animation trigger "${t}" doesn't exist!`);if(null==n||0==n.length)throw new Error(`Unable to listen on the animation trigger "${t}" because the provided event is undefined!`);if("start"!=(i=n)&&"done"!=i)throw new Error(`The provided animation trigger event "${n}" for the animation trigger "${t}" is not supported!`);var i;const o=dl(this._elementListeners,e,[]),s={name:t,phase:n,callback:r};o.push(s);const a=dl(this._engine.statesByElement,e,{});return a.hasOwnProperty(t)||(Ku(e,Tl),Ku(e,"ng-trigger-"+t),a[t]=Vu),()=>{this._engine.afterFlush(()=>{const e=o.indexOf(s);e>=0&&o.splice(e,1),this._triggers[t]||delete a[t]})}}register(e,t){return!this._triggers[e]&&(this._triggers[e]=t,!0)}_getTrigger(e){const t=this._triggers[e];if(!t)throw new Error(`The provided animation trigger "${e}" has not been registered!`);return t}trigger(e,t,n,r=!0){const i=this._getTrigger(t),o=new Wu(this.id,t,e);let s=this._engine.statesByElement.get(e);s||(Ku(e,Tl),Ku(e,"ng-trigger-"+t),this._engine.statesByElement.set(e,s={}));let a=s[t];const l=new Bu(n,this.id);if(!(n&&n.hasOwnProperty("value"))&&a&&l.absorbOptions(a.options),s[t]=l,a||(a=Vu),l.value!==qu&&a.value===l.value){if(!function(e,t){const n=Object.keys(e),r=Object.keys(t);if(n.length!=r.length)return!1;for(let i=0;i<n.length;i++){const r=n[i];if(!t.hasOwnProperty(r)||e[r]!==t[r])return!1}return!0}(a.params,l.params)){const t=[],n=i.matchStyles(a.value,a.params,t),r=i.matchStyles(l.value,l.params,t);t.length?this._engine.reportError(t):this._engine.afterFlush(()=>{Vl(e,n),ql(e,r)})}return}const u=dl(this._engine.playersByElement,e,[]);u.forEach(e=>{e.namespaceId==this.id&&e.triggerName==t&&e.queued&&e.destroy()});let c=i.matchTransition(a.value,l.value,e,l.params),h=!1;if(!c){if(!r)return;c=i.fallbackTransition,h=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:c,fromState:a,toState:l,player:o,isFallbackTransition:h}),h||(Ku(e,Lu),o.onStart(()=>{Xu(e,Lu)})),o.onDone(()=>{let t=this.players.indexOf(o);t>=0&&this.players.splice(t,1);const n=this._engine.playersByElement.get(e);if(n){let e=n.indexOf(o);e>=0&&n.splice(e,1)}}),this.players.push(o),u.push(o),o}deregister(e){delete this._triggers[e],this._engine.statesByElement.forEach((t,n)=>{delete t[e]}),this._elementListeners.forEach((t,n)=>{this._elementListeners.set(n,t.filter(t=>t.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);const t=this._engine.playersByElement.get(e);t&&(t.forEach(e=>e.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,t){const n=this._engine.driver.query(e,Rl,!0);n.forEach(e=>{if(e.__ng_removed)return;const n=this._engine.fetchNamespacesByElement(e);n.size?n.forEach(n=>n.triggerLeaveAnimation(e,t,!1,!0)):this.clearElementCache(e)}),this._engine.afterFlushAnimationsDone(()=>n.forEach(e=>this.clearElementCache(e)))}triggerLeaveAnimation(e,t,n,r){const i=this._engine.statesByElement.get(e);if(i){const o=[];if(Object.keys(i).forEach(t=>{if(this._triggers[t]){const n=this.trigger(e,t,qu,r);n&&o.push(n)}}),o.length)return this._engine.markElementAsRemoved(this.id,e,!0,t),n&&al(o).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){const t=this._elementListeners.get(e);if(t){const n=new Set;t.forEach(t=>{const r=t.name;if(n.has(r))return;n.add(r);const i=this._triggers[r].fallbackTransition,o=this._engine.statesByElement.get(e)[r]||Vu,s=new Bu(qu),a=new Wu(this.id,r,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:r,transition:i,fromState:o,toState:s,player:a,isFallbackTransition:!0})})}}removeNode(e,t){const n=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,!0))return;let r=!1;if(n.totalAnimations){const t=n.players.length?n.playersByQueriedElement.get(e):[];if(t&&t.length)r=!0;else{let t=e;for(;t=t.parentNode;)if(n.statesByElement.get(t)){r=!0;break}}}if(this.prepareLeaveAnimationListeners(e),r)n.markElementAsRemoved(this.id,e,!1,t);else{const r=e.__ng_removed;r&&r!==Fu||(n.afterFlush(()=>this.clearElementCache(e)),n.destroyInnerAnimations(e),n._onRemovalComplete(e,t))}}insertNode(e,t){Ku(e,this._hostClassName)}drainQueuedTransitions(e){const t=[];return this._queue.forEach(n=>{const r=n.player;if(r.destroyed)return;const i=n.element,o=this._elementListeners.get(i);o&&o.forEach(t=>{if(t.name==n.triggerName){const r=hl(i,n.triggerName,n.fromState.value,n.toState.value);r._data=e,ul(n.player,t.phase,r,t.callback)}}),r.markedForDestroy?this._engine.afterFlush(()=>{r.destroy()}):t.push(n)}),this._queue=[],t.sort((e,t)=>{const n=e.transition.ast.depCount,r=t.transition.ast.depCount;return 0==n||0==r?n-r:this._engine.driver.containsElement(e.element,t.element)?1:-1})}destroy(e){this.players.forEach(e=>e.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}elementContainsData(e){let t=!1;return this._elementListeners.has(e)&&(t=!0),t=!!this._queue.find(t=>t.element===e)||t,t}}class Hu{constructor(e,t,n){this.bodyNode=e,this.driver=t,this._normalizer=n,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(e,t)=>{}}_onRemovalComplete(e,t){this.onRemovalComplete(e,t)}get queuedPlayers(){const e=[];return this._namespaceList.forEach(t=>{t.players.forEach(t=>{t.queued&&e.push(t)})}),e}createNamespace(e,t){const n=new Uu(e,t,this);return t.parentNode?this._balanceNamespaceList(n,t):(this.newHostElements.set(t,n),this.collectEnterElement(t)),this._namespaceLookup[e]=n}_balanceNamespaceList(e,t){const n=this._namespaceList.length-1;if(n>=0){let r=!1;for(let i=n;i>=0;i--)if(this.driver.containsElement(this._namespaceList[i].hostElement,t)){this._namespaceList.splice(i+1,0,e),r=!0;break}r||this._namespaceList.splice(0,0,e)}else this._namespaceList.push(e);return this.namespacesByHostElement.set(t,e),e}register(e,t){let n=this._namespaceLookup[e];return n||(n=this.createNamespace(e,t)),n}registerTrigger(e,t,n){let r=this._namespaceLookup[e];r&&r.register(t,n)&&this.totalAnimations++}destroy(e,t){if(!e)return;const n=this._fetchNamespace(e);this.afterFlush(()=>{this.namespacesByHostElement.delete(n.hostElement),delete this._namespaceLookup[e];const t=this._namespaceList.indexOf(n);t>=0&&this._namespaceList.splice(t,1)}),this.afterFlushAnimationsDone(()=>n.destroy(t))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){const t=new Set,n=this.statesByElement.get(e);if(n){const e=Object.keys(n);for(let r=0;r<e.length;r++){const i=n[e[r]].namespaceId;if(i){const e=this._fetchNamespace(i);e&&t.add(e)}}}return t}trigger(e,t,n,r){if(zu(t)){const i=this._fetchNamespace(e);if(i)return i.trigger(t,n,r),!0}return!1}insertNode(e,t,n,r){if(!zu(t))return;const i=t.__ng_removed;if(i&&i.setForRemoval){i.setForRemoval=!1,i.setForMove=!0;const e=this.collectedLeaveElements.indexOf(t);e>=0&&this.collectedLeaveElements.splice(e,1)}if(e){const r=this._fetchNamespace(e);r&&r.insertNode(t,n)}r&&this.collectEnterElement(t)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,t){t?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Ku(e,Mu)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),Xu(e,Mu))}removeNode(e,t,n,r){if(zu(t)){const i=e?this._fetchNamespace(e):null;if(i?i.removeNode(t,r):this.markElementAsRemoved(e,t,!1,r),n){const n=this.namespacesByHostElement.get(t);n&&n.id!==e&&n.removeNode(t,r)}}else this._onRemovalComplete(t,r)}markElementAsRemoved(e,t,n,r){this.collectedLeaveElements.push(t),t.__ng_removed={namespaceId:e,setForRemoval:r,hasAnimation:n,removedBeforeQueried:!1}}listen(e,t,n,r,i){return zu(t)?this._fetchNamespace(e).listen(t,n,r,i):()=>{}}_buildInstruction(e,t,n,r,i){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,n,r,e.fromState.options,e.toState.options,t,i)}destroyInnerAnimations(e){let t=this.driver.query(e,Rl,!0);t.forEach(e=>this.destroyActiveAnimationsForElement(e)),0!=this.playersByQueriedElement.size&&(t=this.driver.query(e,Il,!0),t.forEach(e=>this.finishActiveQueriedAnimationOnElement(e)))}destroyActiveAnimationsForElement(e){const t=this.playersByElement.get(e);t&&t.forEach(e=>{e.queued?e.markedForDestroy=!0:e.destroy()})}finishActiveQueriedAnimationOnElement(e){const t=this.playersByQueriedElement.get(e);t&&t.forEach(e=>e.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return al(this.players).onDone(()=>e());e()})}processLeaveNode(e){const t=e.__ng_removed;if(t&&t.setForRemoval){if(e.__ng_removed=Fu,t.namespaceId){this.destroyInnerAnimations(e);const n=this._fetchNamespace(t.namespaceId);n&&n.clearElementCache(e)}this._onRemovalComplete(e,t.setForRemoval)}this.driver.matchesElement(e,Nu)&&this.markElementAsDisabled(e,!1),this.driver.query(e,Nu,!0).forEach(e=>{this.markElementAsDisabled(e,!1)})}flush(e=-1){let t=[];if(this.newHostElements.size&&(this.newHostElements.forEach((e,t)=>this._balanceNamespaceList(e,t)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let n=0;n<this.collectedEnterElements.length;n++)Ku(this.collectedEnterElements[n],"ng-star-inserted");if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){const n=[];try{t=this._flushAnimations(n,e)}finally{for(let e=0;e<n.length;e++)n[e]()}}else for(let n=0;n<this.collectedLeaveElements.length;n++)this.processLeaveNode(this.collectedLeaveElements[n]);if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(e=>e()),this._flushFns=[],this._whenQuietFns.length){const e=this._whenQuietFns;this._whenQuietFns=[],t.length?al(t).onDone(()=>{e.forEach(e=>e())}):e.forEach(e=>e())}}reportError(e){throw new Error("Unable to process animations due to the following failed trigger transitions\n "+e.join("\n"))}_flushAnimations(e,t){const n=new du,r=[],i=new Map,o=[],s=new Map,a=new Map,l=new Map,u=new Set;this.disabledNodes.forEach(e=>{u.add(e);const t=this.driver.query(e,".ng-animate-queued",!0);for(let n=0;n<t.length;n++)u.add(t[n])});const c=this.bodyNode,h=Array.from(this.statesByElement.keys()),d=Yu(h,this.collectedEnterElements),f=new Map;let p=0;d.forEach((e,t)=>{const n=Pl+p++;f.set(t,n),e.forEach(e=>Ku(e,n))});const g=[],y=new Set,m=new Set;for(let R=0;R<this.collectedLeaveElements.length;R++){const e=this.collectedLeaveElements[R],t=e.__ng_removed;t&&t.setForRemoval&&(g.push(e),y.add(e),t.hasAnimation?this.driver.query(e,".ng-star-inserted",!0).forEach(e=>y.add(e)):m.add(e))}const v=new Map,_=Yu(h,Array.from(y));_.forEach((e,t)=>{const n=El+p++;v.set(t,n),e.forEach(e=>Ku(e,n))}),e.push(()=>{d.forEach((e,t)=>{const n=f.get(t);e.forEach(e=>Xu(e,n))}),_.forEach((e,t)=>{const n=v.get(t);e.forEach(e=>Xu(e,n))}),g.forEach(e=>{this.processLeaveNode(e)})});const b=[],w=[];for(let R=this._namespaceList.length-1;R>=0;R--)this._namespaceList[R].drainQueuedTransitions(t).forEach(e=>{const t=e.player,i=e.element;if(b.push(t),this.collectedEnterElements.length){const e=i.__ng_removed;if(e&&e.setForMove)return void t.destroy()}const u=!c||!this.driver.containsElement(c,i),h=v.get(i),d=f.get(i),p=this._buildInstruction(e,n,d,h,u);if(p.errors&&p.errors.length)w.push(p);else{if(u)return t.onStart(()=>Vl(i,p.fromStyles)),t.onDestroy(()=>ql(i,p.toStyles)),void r.push(t);if(e.isFallbackTransition)return t.onStart(()=>Vl(i,p.fromStyles)),t.onDestroy(()=>ql(i,p.toStyles)),void r.push(t);p.timelines.forEach(e=>e.stretchStartingKeyframe=!0),n.append(i,p.timelines),o.push({instruction:p,player:t,element:i}),p.queriedElements.forEach(e=>dl(s,e,[]).push(t)),p.preStyleProps.forEach((e,t)=>{const n=Object.keys(e);if(n.length){let e=a.get(t);e||a.set(t,e=new Set),n.forEach(t=>e.add(t))}}),p.postStyleProps.forEach((e,t)=>{const n=Object.keys(e);let r=l.get(t);r||l.set(t,r=new Set),n.forEach(e=>r.add(e))})}});if(w.length){const e=[];w.forEach(t=>{e.push(`@${t.triggerName} has failed due to:\n`),t.errors.forEach(t=>e.push(`- ${t}\n`))}),b.forEach(e=>e.destroy()),this.reportError(e)}const A=new Map,S=new Map;o.forEach(e=>{const t=e.element;n.has(t)&&(S.set(t,t),this._beforeAnimationBuild(e.player.namespaceId,e.instruction,A))}),r.forEach(e=>{const t=e.element;this._getPreviousPlayers(t,!1,e.namespaceId,e.triggerName,null).forEach(e=>{dl(A,t,[]).push(e),e.destroy()})});const k=g.filter(e=>Ju(e,a,l)),x=new Map;Qu(x,this.driver,m,l,el).forEach(e=>{Ju(e,a,l)&&k.push(e)});const C=new Map;d.forEach((e,t)=>{Qu(C,this.driver,new Set(e),a,"!")}),k.forEach(e=>{const t=x.get(e),n=C.get(e);x.set(e,Object.assign(Object.assign({},t),n))});const P=[],E=[],T={};o.forEach(e=>{const{element:t,player:o,instruction:s}=e;if(n.has(t)){if(u.has(t))return o.onDestroy(()=>ql(t,s.toStyles)),o.disabled=!0,o.overrideTotalTime(s.totalTime),void r.push(o);let e=T;if(S.size>1){let n=t;const r=[];for(;n=n.parentNode;){const t=S.get(n);if(t){e=t;break}r.push(n)}r.forEach(t=>S.set(t,e))}const n=this._buildAnimation(o.namespaceId,s,A,i,C,x);if(o.setRealPlayer(n),e===T)P.push(o);else{const t=this.playersByElement.get(e);t&&t.length&&(o.parentPlayer=al(t)),r.push(o)}}else Vl(t,s.fromStyles),o.onDestroy(()=>ql(t,s.toStyles)),E.push(o),u.has(t)&&r.push(o)}),E.forEach(e=>{const t=i.get(e.element);if(t&&t.length){const n=al(t);e.setRealPlayer(n)}}),r.forEach(e=>{e.parentPlayer?e.syncPlayerEvents(e.parentPlayer):e.destroy()});for(let R=0;R<g.length;R++){const e=g[R],t=e.__ng_removed;if(Xu(e,El),t&&t.hasAnimation)continue;let n=[];if(s.size){let t=s.get(e);t&&t.length&&n.push(...t);let r=this.driver.query(e,Il,!0);for(let e=0;e<r.length;e++){let t=s.get(r[e]);t&&t.length&&n.push(...t)}}const r=n.filter(e=>!e.destroyed);r.length?Zu(this,e,r):this.processLeaveNode(e)}return g.length=0,P.forEach(e=>{this.players.push(e),e.onDone(()=>{e.destroy();const t=this.players.indexOf(e);this.players.splice(t,1)}),e.play()}),P}elementContainsData(e,t){let n=!1;const r=t.__ng_removed;return r&&r.setForRemoval&&(n=!0),this.playersByElement.has(t)&&(n=!0),this.playersByQueriedElement.has(t)&&(n=!0),this.statesByElement.has(t)&&(n=!0),this._fetchNamespace(e).elementContainsData(t)||n}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,t,n,r,i){let o=[];if(t){const t=this.playersByQueriedElement.get(e);t&&(o=t)}else{const t=this.playersByElement.get(e);if(t){const e=!i||i==qu;t.forEach(t=>{t.queued||(e||t.triggerName==r)&&o.push(t)})}}return(n||r)&&(o=o.filter(e=>!(n&&n!=e.namespaceId||r&&r!=e.triggerName))),o}_beforeAnimationBuild(e,t,n){const r=t.element,i=t.isRemovalTransition?void 0:e,o=t.isRemovalTransition?void 0:t.triggerName;for(const s of t.timelines){const e=s.element,a=e!==r,l=dl(n,e,[]);this._getPreviousPlayers(e,a,i,o,t.toState).forEach(e=>{const t=e.getRealPlayer();t.beforeDestroy&&t.beforeDestroy(),e.destroy(),l.push(e)})}Vl(r,t.fromStyles)}_buildAnimation(e,t,n,r,i,o){const s=t.triggerName,a=t.element,l=[],u=new Set,c=new Set,h=t.timelines.map(t=>{const h=t.element;u.add(h);const d=h.__ng_removed;if(d&&d.removedBeforeQueried)return new il(t.duration,t.delay);const f=h!==a,p=function(e){const t=[];return function e(t,n){for(let r=0;r<t.length;r++){const i=t[r];i instanceof ol?e(i.players,n):n.push(i)}}(e,t),t}((n.get(h)||Du).map(e=>e.getRealPlayer())).filter(e=>!!e.element&&e.element===h),g=i.get(h),y=o.get(h),m=ll(0,this._normalizer,0,t.keyframes,g,y),v=this._buildPlayer(t,m,p);if(t.subTimeline&&r&&c.add(h),f){const t=new Wu(e,s,h);t.setRealPlayer(v),l.push(t)}return v});l.forEach(e=>{dl(this.playersByQueriedElement,e.element,[]).push(e),e.onDone(()=>function(e,t,n){let r;if(e instanceof Map){if(r=e.get(t),r){if(r.length){const e=r.indexOf(n);r.splice(e,1)}0==r.length&&e.delete(t)}}else if(r=e[t],r){if(r.length){const e=r.indexOf(n);r.splice(e,1)}0==r.length&&delete e[t]}return r}(this.playersByQueriedElement,e.element,e))}),u.forEach(e=>Ku(e,Ol));const d=al(h);return d.onDestroy(()=>{u.forEach(e=>Xu(e,Ol)),ql(a,t.toStyles)}),c.forEach(e=>{dl(r,e,[]).push(d)}),d}_buildPlayer(e,t,n){return t.length>0?this.driver.animate(e.element,t,e.duration,e.delay,e.easing,n):new il(e.duration,e.delay)}}class Wu{constructor(e,t,n){this.namespaceId=e,this.triggerName=t,this.element=n,this._player=new il,this._containsRealPlayer=!1,this._queuedCallbacks={},this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(e){this._containsRealPlayer||(this._player=e,Object.keys(this._queuedCallbacks).forEach(t=>{this._queuedCallbacks[t].forEach(n=>ul(e,t,void 0,n))}),this._queuedCallbacks={},this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){const t=this._player;t.triggerCallback&&e.onStart(()=>t.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,t){dl(this._queuedCallbacks,e,[]).push(t)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){const t=this._player;t.triggerCallback&&t.triggerCallback(e)}}function zu(e){return e&&1===e.nodeType}function Gu(e,t){const n=e.style.display;return e.style.display=null!=t?t:"none",n}function Qu(e,t,n,r,i){const o=[];n.forEach(e=>o.push(Gu(e)));const s=[];r.forEach((n,r)=>{const o={};n.forEach(e=>{const n=o[e]=t.computeStyle(r,e,i);n&&0!=n.length||(r.__ng_removed=ju,s.push(r))}),e.set(r,o)});let a=0;return n.forEach(e=>Gu(e,o[a++])),s}function Yu(e,t){const n=new Map;if(e.forEach(e=>n.set(e,[])),0==t.length)return n;const r=new Set(t),i=new Map;return t.forEach(e=>{const t=function e(t){if(!t)return 1;let o=i.get(t);if(o)return o;const s=t.parentNode;return o=n.has(s)?s:r.has(s)?1:e(s),i.set(t,o),o}(e);1!==t&&n.get(t).push(e)}),n}function Ku(e,t){if(e.classList)e.classList.add(t);else{let n=e.$$classes;n||(n=e.$$classes={}),n[t]=!0}}function Xu(e,t){if(e.classList)e.classList.remove(t);else{let n=e.$$classes;n&&delete n[t]}}function Zu(e,t,n){al(n).onDone(()=>e.processLeaveNode(t))}function Ju(e,t,n){const r=n.get(e);if(!r)return!1;let i=t.get(e);return i?r.forEach(e=>i.add(e)):t.set(e,r),n.delete(e),!0}class $u{constructor(e,t,n){this.bodyNode=e,this._driver=t,this._triggerCache={},this.onRemovalComplete=(e,t)=>{},this._transitionEngine=new Hu(e,t,n),this._timelineEngine=new Iu(e,t,n),this._transitionEngine.onRemovalComplete=(e,t)=>this.onRemovalComplete(e,t)}registerTrigger(e,t,n,r,i){const o=e+"-"+r;let s=this._triggerCache[o];if(!s){const e=[],t=ou(this._driver,i,e);if(e.length)throw new Error(`The animation trigger "${r}" has failed to build due to the following errors:\n - ${e.join("\n - ")}`);s=function(e,t){return new Tu(e,t)}(r,t),this._triggerCache[o]=s}this._transitionEngine.registerTrigger(t,r,s)}register(e,t){this._transitionEngine.register(e,t)}destroy(e,t){this._transitionEngine.destroy(e,t)}onInsert(e,t,n,r){this._transitionEngine.insertNode(e,t,n,r)}onRemove(e,t,n,r){this._transitionEngine.removeNode(e,t,r||!1,n)}disableAnimations(e,t){this._transitionEngine.markElementAsDisabled(e,t)}process(e,t,n,r){if("@"==n.charAt(0)){const[e,i]=fl(n);this._timelineEngine.command(e,t,i,r)}else this._transitionEngine.trigger(e,t,n,r)}listen(e,t,n,r,i){if("@"==n.charAt(0)){const[e,r]=fl(n);return this._timelineEngine.listen(e,t,r,i)}return this._transitionEngine.listen(e,t,n,r,i)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}function ec(e,t){let n=null,r=null;return Array.isArray(t)&&t.length?(n=nc(t[0]),t.length>1&&(r=nc(t[t.length-1]))):t&&(n=nc(t)),n||r?new tc(e,n,r):null}let tc=(()=>{class e{constructor(t,n,r){this._element=t,this._startStyles=n,this._endStyles=r,this._state=0;let i=e.initialStylesByElement.get(t);i||e.initialStylesByElement.set(t,i={}),this._initialStyles=i}start(){this._state<1&&(this._startStyles&&ql(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(ql(this._element,this._initialStyles),this._endStyles&&(ql(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(e.initialStylesByElement.delete(this._element),this._startStyles&&(Vl(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Vl(this._element,this._endStyles),this._endStyles=null),ql(this._element,this._initialStyles),this._state=3)}}return e.initialStylesByElement=new WeakMap,e})();function nc(e){let t=null;const n=Object.keys(e);for(let r=0;r<n.length;r++){const i=n[r];rc(i)&&(t=t||{},t[i]=e[i])}return t}function rc(e){return"display"===e||"position"===e}const ic="animation",oc="animationend";class sc{constructor(e,t,n,r,i,o,s){this._element=e,this._name=t,this._duration=n,this._delay=r,this._easing=i,this._fillMode=o,this._onDoneFn=s,this._finished=!1,this._destroyed=!1,this._startTime=0,this._position=0,this._eventFn=e=>this._handleCallback(e)}apply(){!function(e,t){const n=dc(e,"").trim();n.length&&(function(e,t){let n=0;for(let r=0;r<e.length;r++)","===e.charAt(r)&&n++}(n),t=`${n}, ${t}`),hc(e,"",t)}(this._element,`${this._duration}ms ${this._easing} ${this._delay}ms 1 normal ${this._fillMode} ${this._name}`),cc(this._element,this._eventFn,!1),this._startTime=Date.now()}pause(){ac(this._element,this._name,"paused")}resume(){ac(this._element,this._name,"running")}setPosition(e){const t=lc(this._element,this._name);this._position=e*this._duration,hc(this._element,"Delay",`-${this._position}ms`,t)}getPosition(){return this._position}_handleCallback(e){const t=e._ngTestManualTimestamp||Date.now(),n=1e3*parseFloat(e.elapsedTime.toFixed(3));e.animationName==this._name&&Math.max(t-this._startTime,0)>=this._delay&&n>=this._duration&&this.finish()}finish(){this._finished||(this._finished=!0,this._onDoneFn(),cc(this._element,this._eventFn,!0))}destroy(){this._destroyed||(this._destroyed=!0,this.finish(),function(e,t){const n=dc(e,"").split(","),r=uc(n,t);r>=0&&(n.splice(r,1),hc(e,"",n.join(",")))}(this._element,this._name))}}function ac(e,t,n){hc(e,"PlayState",n,lc(e,t))}function lc(e,t){const n=dc(e,"");return n.indexOf(",")>0?uc(n.split(","),t):uc([n],t)}function uc(e,t){for(let n=0;n<e.length;n++)if(e[n].indexOf(t)>=0)return n;return-1}function cc(e,t,n){n?e.removeEventListener(oc,t):e.addEventListener(oc,t)}function hc(e,t,n,r){const i=ic+t;if(null!=r){const t=e.style[i];if(t.length){const e=t.split(",");e[r]=n,n=e.join(",")}}e.style[i]=n}function dc(e,t){return e.style[ic+t]}class fc{constructor(e,t,n,r,i,o,s,a){this.element=e,this.keyframes=t,this.animationName=n,this._duration=r,this._delay=i,this._finalStyles=s,this._specialStyles=a,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this.currentSnapshot={},this._state=0,this.easing=o||"linear",this.totalTime=r+i,this._buildStyler()}onStart(e){this._onStartFns.push(e)}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}destroy(){this.init(),this._state>=4||(this._state=4,this._styler.destroy(),this._flushStartFns(),this._flushDoneFns(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}_flushDoneFns(){this._onDoneFns.forEach(e=>e()),this._onDoneFns=[]}_flushStartFns(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}finish(){this.init(),this._state>=3||(this._state=3,this._styler.finish(),this._flushStartFns(),this._specialStyles&&this._specialStyles.finish(),this._flushDoneFns())}setPosition(e){this._styler.setPosition(e)}getPosition(){return this._styler.getPosition()}hasStarted(){return this._state>=2}init(){this._state>=1||(this._state=1,this._styler.apply(),this._delay&&this._styler.pause())}play(){this.init(),this.hasStarted()||(this._flushStartFns(),this._state=2,this._specialStyles&&this._specialStyles.start()),this._styler.resume()}pause(){this.init(),this._styler.pause()}restart(){this.reset(),this.play()}reset(){this._styler.destroy(),this._buildStyler(),this._styler.apply()}_buildStyler(){this._styler=new sc(this.element,this.animationName,this._duration,this._delay,this.easing,"forwards",()=>this.finish())}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(e=>e()),t.length=0}beforeDestroy(){this.init();const e={};if(this.hasStarted()){const t=this._state>=3;Object.keys(this._finalStyles).forEach(n=>{"offset"!=n&&(e[n]=t?this._finalStyles[n]:Jl(this.element,n))})}this.currentSnapshot=e}}class pc extends il{constructor(e,t){super(),this.element=e,this._startingStyles={},this.__initialized=!1,this._styles=kl(t)}init(){!this.__initialized&&this._startingStyles&&(this.__initialized=!0,Object.keys(this._styles).forEach(e=>{this._startingStyles[e]=this.element.style[e]}),super.init())}play(){this._startingStyles&&(this.init(),Object.keys(this._styles).forEach(e=>this.element.style.setProperty(e,this._styles[e])),super.play())}destroy(){this._startingStyles&&(Object.keys(this._startingStyles).forEach(e=>{const t=this._startingStyles[e];t?this.element.style.setProperty(e,t):this.element.style.removeProperty(e)}),this._startingStyles=null,super.destroy())}}class gc{constructor(){this._count=0,this._head=document.querySelector("head"),this._warningIssued=!1}validateStyleProperty(e){return bl(e)}matchesElement(e,t){return wl(e,t)}containsElement(e,t){return Al(e,t)}query(e,t,n){return Sl(e,t,n)}computeStyle(e,t,n){return window.getComputedStyle(e)[t]}buildKeyframeElement(e,t,n){n=n.map(e=>kl(e));let r=`@keyframes ${t} {\n`,i="";n.forEach(e=>{i=" ";const t=parseFloat(e.offset);r+=`${i}${100*t}% {\n`,i+=" ",Object.keys(e).forEach(t=>{const n=e[t];switch(t){case"offset":return;case"easing":return void(n&&(r+=`${i}animation-timing-function: ${n};\n`));default:return void(r+=`${i}${t}: ${n};\n`)}}),r+=i+"}\n"}),r+="}\n";const o=document.createElement("style");return o.innerHTML=r,o}animate(e,t,n,r,i,o=[],s){s&&this._notifyFaultyScrubber();const a=o.filter(e=>e instanceof fc),l={};Kl(n,r)&&a.forEach(e=>{let t=e.currentSnapshot;Object.keys(t).forEach(e=>l[e]=t[e])});const u=function(e){let t={};return e&&(Array.isArray(e)?e:[e]).forEach(e=>{Object.keys(e).forEach(n=>{"offset"!=n&&"easing"!=n&&(t[n]=e[n])})}),t}(t=Xl(e,t,l));if(0==n)return new pc(e,u);const c="gen_css_kf_"+this._count++,h=this.buildKeyframeElement(e,c,t);document.querySelector("head").appendChild(h);const d=ec(e,t),f=new fc(e,t,c,n,r,i,u,d);return f.onDestroy(()=>{var e;(e=h).parentNode.removeChild(e)}),f}_notifyFaultyScrubber(){this._warningIssued||(console.warn("@angular/animations: please load the web-animations.js polyfill to allow programmatic access...\n"," visit http://bit.ly/IWukam to learn more about using the web-animation-js polyfill."),this._warningIssued=!0)}}class yc{constructor(e,t,n,r){this.element=e,this.keyframes=t,this.options=n,this._specialStyles=r,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this.time=0,this.parentPlayer=null,this.currentSnapshot={},this._duration=n.duration,this._delay=n.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:{},this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_triggerWebAnimation(e,t,n){return e.animate(t,n)}onStart(e){this._onStartFns.push(e)}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){this.domPlayer.currentTime=e*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const e={};this.hasStarted()&&Object.keys(this._finalKeyframe).forEach(t=>{"offset"!=t&&(e[t]=this._finished?this._finalKeyframe[t]:Jl(this.element,t))}),this.currentSnapshot=e}triggerCallback(e){const t="start"==e?this._onStartFns:this._onDoneFns;t.forEach(e=>e()),t.length=0}}class mc{constructor(){this._isNativeImpl=/\{\s*\[native\s+code\]\s*\}/.test(vc().toString()),this._cssKeyframesDriver=new gc}validateStyleProperty(e){return bl(e)}matchesElement(e,t){return wl(e,t)}containsElement(e,t){return Al(e,t)}query(e,t,n){return Sl(e,t,n)}computeStyle(e,t,n){return window.getComputedStyle(e)[t]}overrideWebAnimationsSupport(e){this._isNativeImpl=e}animate(e,t,n,r,i,o=[],s){if(!s&&!this._isNativeImpl)return this._cssKeyframesDriver.animate(e,t,n,r,i,o);const a={duration:n,delay:r,fill:0==r?"both":"forwards"};i&&(a.easing=i);const l={},u=o.filter(e=>e instanceof yc);Kl(n,r)&&u.forEach(e=>{let t=e.currentSnapshot;Object.keys(t).forEach(e=>l[e]=t[e])});const c=ec(e,t=Xl(e,t=t.map(e=>Fl(e,!1)),l));return new yc(e,t,a,c)}}function vc(){return"undefined"!=typeof window&&void 0!==window.document&&Element.prototype.animate||{}}let _c=(()=>{class e extends $a{constructor(e,t){super(),this._nextAnimationId=0,this._renderer=e.createRenderer(t.body,{id:"0",encapsulation:$e.None,styles:[],data:{animation:[]}})}build(e){const t=this._nextAnimationId.toString();this._nextAnimationId++;const n=Array.isArray(e)?tl(e):e;return Ac(this._renderer,null,t,"register",[n]),new bc(t,this._renderer)}}return e.\u0275fac=function(t){return new(t||e)(We(ro),We(ba))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();class bc extends class{}{constructor(e,t){super(),this._id=e,this._renderer=t}create(e,t){return new wc(this._id,e,t||{},this._renderer)}}class wc{constructor(e,t,n,r){this.id=e,this.element=t,this._renderer=r,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",n)}_listen(e,t){return this._renderer.listen(this.element,`@@${this.id}:${e}`,t)}_command(e,...t){return Ac(this._renderer,this.element,this.id,e,t)}onDone(e){this._listen("done",e)}onStart(e){this._listen("start",e)}onDestroy(e){this._listen("destroy",e)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset")}setPosition(e){this._command("setPosition",e)}getPosition(){return 0}}function Ac(e,t,n,r,i){return e.setProperty(t,`@@${n}:${r}`,i)}const Sc="@",kc="@.disabled";let xc=(()=>{class e{constructor(e,t,n){this.delegate=e,this.engine=t,this._zone=n,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),t.onRemovalComplete=(e,t)=>{t&&t.parentNode(e)&&t.removeChild(e.parentNode,e)}}createRenderer(e,t){const n=this.delegate.createRenderer(e,t);if(!(e&&t&&t.data&&t.data.animation)){let e=this._rendererCache.get(n);return e||(e=new Cc("",n,this.engine),this._rendererCache.set(n,e)),e}const r=t.id,i=t.id+"-"+this._currentId;this._currentId++,this.engine.register(i,e);const o=t=>{Array.isArray(t)?t.forEach(o):this.engine.registerTrigger(r,i,e,t.name,t)};return t.data.animation.forEach(o),new Pc(this,i,n,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(e,t,n){e>=0&&e<this._microtaskId?this._zone.run(()=>t(n)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(e=>{const[t,n]=e;t(n)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([t,n]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return e.\u0275fac=function(t){return new(t||e)(We(ro),We($u),We(Ps))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();class Cc{constructor(e,t,n){this.namespaceId=e,this.delegate=t,this.engine=n,this.destroyNode=this.delegate.destroyNode?e=>t.destroyNode(e):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy()}createElement(e,t){return this.delegate.createElement(e,t)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,t){this.delegate.appendChild(e,t),this.engine.onInsert(this.namespaceId,t,e,!1)}insertBefore(e,t,n){this.delegate.insertBefore(e,t,n),this.engine.onInsert(this.namespaceId,t,e,!0)}removeChild(e,t,n){this.engine.onRemove(this.namespaceId,t,this.delegate,n)}selectRootElement(e,t){return this.delegate.selectRootElement(e,t)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,t,n,r){this.delegate.setAttribute(e,t,n,r)}removeAttribute(e,t,n){this.delegate.removeAttribute(e,t,n)}addClass(e,t){this.delegate.addClass(e,t)}removeClass(e,t){this.delegate.removeClass(e,t)}setStyle(e,t,n,r){this.delegate.setStyle(e,t,n,r)}removeStyle(e,t,n){this.delegate.removeStyle(e,t,n)}setProperty(e,t,n){t.charAt(0)==Sc&&t==kc?this.disableAnimations(e,!!n):this.delegate.setProperty(e,t,n)}setValue(e,t){this.delegate.setValue(e,t)}listen(e,t,n){return this.delegate.listen(e,t,n)}disableAnimations(e,t){this.engine.disableAnimations(e,t)}}class Pc extends Cc{constructor(e,t,n,r){super(t,n,r),this.factory=e,this.namespaceId=t}setProperty(e,t,n){t.charAt(0)==Sc?"."==t.charAt(1)&&t==kc?this.disableAnimations(e,n=void 0===n||!!n):this.engine.process(this.namespaceId,e,t.substr(1),n):this.delegate.setProperty(e,t,n)}listen(e,t,n){if(t.charAt(0)==Sc){const r=function(e){switch(e){case"body":return document.body;case"document":return document;case"window":return window;default:return e}}(e);let i=t.substr(1),o="";return i.charAt(0)!=Sc&&([i,o]=function(e){const t=e.indexOf(".");return[e.substring(0,t),e.substr(t+1)]}(i)),this.engine.listen(this.namespaceId,r,i,o,e=>{this.factory.scheduleListenerCallback(e._data||-1,n,e)})}return this.delegate.listen(e,t,n)}}let Ec=(()=>{class e extends $u{constructor(e,t,n){super(e.body,t,n)}}return e.\u0275fac=function(t){return new(t||e)(We(ba),We(Cl),We(Au))},e.\u0275prov=se({token:e,factory:e.\u0275fac}),e})();const Tc=[{provide:Cl,useFactory:function(){return"function"==typeof vc()?new mc:new gc}},{provide:new Le("AnimationModuleType"),useValue:"BrowserAnimations"},{provide:$a,useClass:_c},{provide:Au,useFactory:function(){return new Su}},{provide:$u,useClass:Ec},{provide:ro,useFactory:function(e,t,n){return new xc(e,t,n)},deps:[qa,$u,Ps]}];let Rc=(()=>{class e{}return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)},providers:Tc,imports:[Ja]}),e})();var Oc=n("LFh5"),Ic=n("Voib");const Lc=["pdfViewerContainer"],Mc=function(e){const t=new e.EventBus(!0);var n;return(n=t).on("documentload",()=>{const e=document.createEvent("CustomEvent");e.initCustomEvent("documentload",!0,!0,{}),window.dispatchEvent(e)}),n.on("pagerendered",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("pagerendered",!0,!0,{pageNumber:e.pageNumber,cssTransform:e.cssTransform}),e.source.div.dispatchEvent(t)}),n.on("textlayerrendered",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("textlayerrendered",!0,!0,{pageNumber:e.pageNumber}),e.source.textLayerDiv.dispatchEvent(t)}),n.on("pagechanging",e=>{const t=document.createEvent("UIEvents");t.initEvent("pagechanging",!0,!0),t.pageNumber=e.pageNumber,e.source.container.dispatchEvent(t)}),n.on("pagesinit",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("pagesinit",!0,!0,null),e.source.container.dispatchEvent(t)}),n.on("pagesloaded",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("pagesloaded",!0,!0,{pagesCount:e.pagesCount}),e.source.container.dispatchEvent(t)}),n.on("scalechange",e=>{const t=document.createEvent("UIEvents");t.initEvent("scalechange",!0,!0),t.scale=e.scale,t.presetValue=e.presetValue,e.source.container.dispatchEvent(t)}),n.on("updateviewarea",e=>{const t=document.createEvent("UIEvents");t.initEvent("updateviewarea",!0,!0),t.location=e.location,e.source.container.dispatchEvent(t)}),n.on("find",e=>{if(e.source===window)return;const t=document.createEvent("CustomEvent");t.initCustomEvent("find"+e.type,!0,!0,{query:e.query,phraseSearch:e.phraseSearch,caseSensitive:e.caseSensitive,highlightAll:e.highlightAll,findPrevious:e.findPrevious}),window.dispatchEvent(t)}),n.on("attachmentsloaded",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("attachmentsloaded",!0,!0,{attachmentsCount:e.attachmentsCount}),e.source.container.dispatchEvent(t)}),n.on("sidebarviewchanged",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("sidebarviewchanged",!0,!0,{view:e.view}),e.source.outerContainer.dispatchEvent(t)}),n.on("pagemode",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("pagemode",!0,!0,{mode:e.mode}),e.source.pdfViewer.container.dispatchEvent(t)}),n.on("namedaction",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("namedaction",!0,!0,{action:e.action}),e.source.pdfViewer.container.dispatchEvent(t)}),n.on("presentationmodechanged",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("presentationmodechanged",!0,!0,{active:e.active,switchInProgress:e.switchInProgress}),window.dispatchEvent(t)}),n.on("outlineloaded",e=>{const t=document.createEvent("CustomEvent");t.initCustomEvent("outlineloaded",!0,!0,{outlineCount:e.outlineCount}),e.source.container.dispatchEvent(t)}),t};function Nc(e,t,n){e[t]=n}function Dc(){return"undefined"==typeof window}var Fc,jc=function(e){return e[e.DISABLED=0]="DISABLED",e[e.ENABLED=1]="ENABLED",e[e.ENHANCED=2]="ENHANCED",e}({});let Bc=(()=>{let e=Fc=class{constructor(e){if(this.element=e,this.isVisible=!1,this._cMapsUrl=void 0!==Oc?`https://unpkg.com/pdfjs-dist@${Oc.version}/cmaps/`:null,this._renderText=!0,this._renderTextMode=jc.ENABLED,this._stickToPage=!1,this._originalSize=!0,this._page=1,this._zoom=1,this._zoomScale="page-width",this._rotation=0,this._showAll=!0,this._canAutoResize=!0,this._fitToPage=!1,this._externalLinkTarget="blank",this._showBorders=!1,this.isInitialized=!1,this.afterLoadComplete=new zo,this.pageRendered=new zo,this.pageInitialized=new zo,this.textLayerRendered=new zo,this.onError=new zo,this.onProgress=new zo,this.pageChange=new zo(!0),Dc())return;let t;t=window.hasOwnProperty("pdfWorkerSrc")&&"string"==typeof window.pdfWorkerSrc&&window.pdfWorkerSrc?window.pdfWorkerSrc:`https://cdn.jsdelivr.net/npm/pdfjs-dist@${Oc.version}/es5/build/pdf.worker.js`,Nc(Oc.GlobalWorkerOptions,"workerSrc",t)}set cMapsUrl(e){this._cMapsUrl=e}set page(e){const t=e=parseInt(e,10)||1;this._pdf&&(e=this.getValidPageNumber(e)),this._page=e,t!==e&&this.pageChange.emit(e)}set renderText(e){this._renderText=e}set renderTextMode(e){this._renderTextMode=e}set originalSize(e){this._originalSize=e}set showAll(e){this._showAll=e}set stickToPage(e){this._stickToPage=e}set zoom(e){e<=0||(this._zoom=e)}get zoom(){return this._zoom}set zoomScale(e){this._zoomScale=e}get zoomScale(){return this._zoomScale}set rotation(e){"number"==typeof e&&e%90==0?this._rotation=e:console.warn("Invalid pages rotation angle.")}set externalLinkTarget(e){this._externalLinkTarget=e}set autoresize(e){this._canAutoResize=Boolean(e)}set fitToPage(e){this._fitToPage=Boolean(e)}set showBorders(e){this._showBorders=Boolean(e)}static getLinkTarget(e){switch(e){case"blank":return Oc.LinkTarget.BLANK;case"none":return Oc.LinkTarget.NONE;case"self":return Oc.LinkTarget.SELF;case"parent":return Oc.LinkTarget.PARENT;case"top":return Oc.LinkTarget.TOP}return null}ngAfterViewChecked(){if(this.isInitialized)return;const e=this.pdfViewerContainer.nativeElement.offsetParent;!0!==this.isVisible||null!=e?!1===this.isVisible&&null!=e&&(this.isVisible=!0,setTimeout(()=>{this.ngOnInit(),this.ngOnChanges({src:this.src})})):this.isVisible=!1}ngOnInit(){!Dc()&&this.isVisible&&(this.isInitialized=!0,this.setupMultiPageViewer(),this.setupSinglePageViewer())}ngOnDestroy(){this.clear()}onPageResize(){this._canAutoResize&&this._pdf&&(this.resizeTimeout&&clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(()=>{this.updateSize()},100))}get pdfLinkService(){return this._showAll?this.pdfMultiPageLinkService:this.pdfSinglePageLinkService}get pdfViewer(){return this.getCurrentViewer()}get pdfFindController(){return this._showAll?this.pdfMultiPageFindController:this.pdfSinglePageFindController}ngOnChanges(e){if(!Dc()&&this.isVisible)if("src"in e)this.loadPDF();else if(this._pdf){if("renderText"in e?(this.getCurrentViewer().textLayerMode=this._renderText?this._renderTextMode:jc.DISABLED,this.resetPdfDocument()):"showAll"in e&&this.resetPdfDocument(),"page"in e){const{page:t}=e;if(t.currentValue===this._latestScrolledPage)return;this.getCurrentViewer().scrollPageIntoView({pageNumber:this._page})}this.update()}}updateSize(){const e=this.getCurrentViewer();this._pdf.getPage(e.currentPageNumber).then(t=>{const n=this._rotation||t.rotate,r=t.getViewport({scale:this._zoom,rotation:n}).width*Fc.CSS_UNITS;let i=this._zoom,o=!0;if(!this._originalSize||this._fitToPage&&r>this.pdfViewerContainer.nativeElement.clientWidth){const e=t.getViewport({scale:1,rotation:n});i=this.getScale(e.width,e.height),o=!this._stickToPage}e._setScale(i,o)})}clear(){this.loadingTask&&!this.loadingTask.destroyed&&this.loadingTask.destroy(),this._pdf&&(this._pdf.destroy(),this._pdf=null,this.pdfMultiPageViewer.setDocument(null),this.pdfSinglePageViewer.setDocument(null),this.pdfMultiPageLinkService.setDocument(null,null),this.pdfSinglePageLinkService.setDocument(null,null),this.pdfMultiPageFindController.setDocument(null),this.pdfSinglePageFindController.setDocument(null))}getPDFLinkServiceConfig(){const e={},t=Fc.getLinkTarget(this._externalLinkTarget);return t&&(e.externalLinkTarget=t),e}setupMultiPageViewer(){Nc(Oc,"disableTextLayer",!this._renderText);const e=Mc(Ic);e.on("pagerendered",e=>{this.pageRendered.emit(e)}),e.on("pagesinit",e=>{this.pageInitialized.emit(e)}),e.on("pagechanging",e=>{this.pageScrollTimeout&&clearTimeout(this.pageScrollTimeout),this.pageScrollTimeout=setTimeout(()=>{this._latestScrolledPage=e.pageNumber,this.pageChange.emit(e.pageNumber)},100)}),e.on("textlayerrendered",e=>{this.textLayerRendered.emit(e)}),this.pdfMultiPageLinkService=new Ic.PDFLinkService(Object.assign({eventBus:e},this.getPDFLinkServiceConfig())),this.pdfMultiPageFindController=new Ic.PDFFindController({linkService:this.pdfMultiPageLinkService,eventBus:e});const t={eventBus:e,container:this.element.nativeElement.querySelector("div"),removePageBorders:!this._showBorders,linkService:this.pdfMultiPageLinkService,textLayerMode:this._renderText?this._renderTextMode:jc.DISABLED,findController:this.pdfMultiPageFindController};this.pdfMultiPageViewer=new Ic.PDFViewer(t),this.pdfMultiPageLinkService.setViewer(this.pdfMultiPageViewer),this.pdfMultiPageFindController.setDocument(this._pdf)}setupSinglePageViewer(){Nc(Oc,"disableTextLayer",!this._renderText);const e=Mc(Ic);e.on("pagechanging",e=>{e.pageNumber!==this._page&&(this.page=e.pageNumber)}),e.on("pagerendered",e=>{this.pageRendered.emit(e)}),e.on("pagesinit",e=>{this.pageInitialized.emit(e)}),e.on("textlayerrendered",e=>{this.textLayerRendered.emit(e)}),this.pdfSinglePageLinkService=new Ic.PDFLinkService(Object.assign({eventBus:e},this.getPDFLinkServiceConfig())),this.pdfSinglePageFindController=new Ic.PDFFindController({linkService:this.pdfSinglePageLinkService,eventBus:e});const t={eventBus:e,container:this.element.nativeElement.querySelector("div"),removePageBorders:!this._showBorders,linkService:this.pdfSinglePageLinkService,textLayerMode:this._renderText?this._renderTextMode:jc.DISABLED,findController:this.pdfSinglePageFindController};this.pdfSinglePageViewer=new Ic.PDFSinglePageViewer(t),this.pdfSinglePageLinkService.setViewer(this.pdfSinglePageViewer),this.pdfSinglePageFindController.setDocument(this._pdf),this.pdfSinglePageViewer._currentPageNumber=this._page}getValidPageNumber(e){return e<1?1:e>this._pdf.numPages?this._pdf.numPages:e}getDocumentParams(){const e=typeof this.src;if(!this._cMapsUrl)return this.src;const t={cMapUrl:this._cMapsUrl,cMapPacked:!0};return"string"===e?t.url=this.src:"object"===e&&(void 0!==this.src.byteLength?t.data=this.src:Object.assign(t,this.src)),t}loadPDF(){if(!this.src)return;if(this.lastLoaded===this.src)return void this.update();this.clear(),this.loadingTask=Object(Oc.getDocument)(this.getDocumentParams()),this.loadingTask.onProgress=e=>{this.onProgress.emit(e)};const e=this.src;this.loadingTask.promise.then(t=>{this._pdf=t,this.lastLoaded=e,this.afterLoadComplete.emit(t),this.pdfMultiPageViewer||(this.setupMultiPageViewer(),this.setupSinglePageViewer()),this.resetPdfDocument(),this.update()},e=>{this.onError.emit(e)})}update(){this.page=this._page,this.render()}render(){this._page=this.getValidPageNumber(this._page);const e=this.getCurrentViewer();0===this._rotation&&e.pagesRotation===this._rotation||setTimeout(()=>{e.pagesRotation=this._rotation}),this._stickToPage&&setTimeout(()=>{e.currentPageNumber=this._page}),this.updateSize()}getScale(e,t){const n=this._showBorders?2*Fc.BORDER_WIDTH:0,r=this.pdfViewerContainer.nativeElement.clientWidth-n,i=this.pdfViewerContainer.nativeElement.clientHeight-n;if(0===i||0===t||0===r||0===e)return 1;let o=1;switch(this._zoomScale){case"page-fit":o=Math.min(i/t,r/e);break;case"page-height":o=i/t;break;case"page-width":default:o=r/e}return this._zoom*o/Fc.CSS_UNITS}getCurrentViewer(){return this._showAll?this.pdfMultiPageViewer:this.pdfSinglePageViewer}resetPdfDocument(){this.pdfFindController.setDocument(this._pdf),this._showAll?(this.pdfSinglePageViewer.setDocument(null),this.pdfSinglePageLinkService.setDocument(null),this.pdfMultiPageViewer.setDocument(this._pdf),this.pdfMultiPageLinkService.setDocument(this._pdf,null)):(this.pdfMultiPageViewer.setDocument(null),this.pdfMultiPageLinkService.setDocument(null),this.pdfSinglePageViewer.setDocument(this._pdf),this.pdfSinglePageLinkService.setDocument(this._pdf,null))}};return e.\u0275fac=function(t){return new(t||e)(function(e,t=ie.Default){const n=Ut();return null==n?We(e,t):Nn(Wt(),n,be(e),t)}(to))},e.\u0275cmp=rt({type:e,selectors:[["pdf-viewer"]],viewQuery:function(e,t){var n;1&e&&rs(Lc,!0),2&e&&ns(n=is())&&(t.pdfViewerContainer=n.first)},hostBindings:function(e,t){1&e&&Yi("resize",(function(){return t.onPageResize()}),!1,xn)},inputs:{cMapsUrl:["c-maps-url","cMapsUrl"],page:"page",renderText:["render-text","renderText"],renderTextMode:["render-text-mode","renderTextMode"],originalSize:["original-size","originalSize"],showAll:["show-all","showAll"],stickToPage:["stick-to-page","stickToPage"],zoom:"zoom",zoomScale:["zoom-scale","zoomScale"],rotation:"rotation",externalLinkTarget:["external-link-target","externalLinkTarget"],autoresize:"autoresize",fitToPage:["fit-to-page","fitToPage"],showBorders:["show-borders","showBorders"],src:"src"},outputs:{afterLoadComplete:"after-load-complete",pageRendered:"page-rendered",pageInitialized:"pages-initialized",textLayerRendered:"text-layer-rendered",onError:"error",onProgress:"on-progress",pageChange:"pageChange"},features:[At],decls:3,vars:0,consts:[[1,"ng2-pdf-viewer-container"],["pdfViewerContainer",""],[1,"pdfViewer"]],template:function(e,t){1&e&&(zi(0,"div",0,1),zi(2,"div",2,undefined),Gi(),Gi())},styles:['.ng2-pdf-viewer-container[_ngcontent-%COMP%]{overflow-x:auto;position:relative;height:100%;-webkit-overflow-scrolling:touch}[_nghost-%COMP%] .textLayer{position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden;opacity:.2;line-height:1}[_nghost-%COMP%] .textLayer>span{color:transparent;position:absolute;white-space:pre;cursor:text;transform-origin:0 0}[_nghost-%COMP%] .textLayer .highlight{margin:-1px;padding:1px;background-color:#b400aa;border-radius:4px}[_nghost-%COMP%] .textLayer .highlight.begin{border-radius:4px 0 0 4px}[_nghost-%COMP%] .textLayer .highlight.end{border-radius:0 4px 4px 0}[_nghost-%COMP%] .textLayer .highlight.middle{border-radius:0}[_nghost-%COMP%] .textLayer .highlight.selected{background-color:#006400}[_nghost-%COMP%] .textLayer ::-moz-selection{background:#00f}[_nghost-%COMP%] .textLayer ::selection{background:#00f}[_nghost-%COMP%] .textLayer .endOfContent{display:block;position:absolute;left:0;top:100%;right:0;bottom:0;z-index:-1;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}[_nghost-%COMP%] .textLayer .endOfContent.active{top:0}[_nghost-%COMP%] .annotationLayer section{position:absolute}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.pushButton>a, [_nghost-%COMP%] .annotationLayer .linkAnnotation>a{position:absolute;font-size:1em;top:0;left:0;width:100%;height:100%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.pushButton>a:hover, [_nghost-%COMP%] .annotationLayer .linkAnnotation>a:hover{opacity:.2;background:#ff0;box-shadow:0 2px 10px #ff0}[_nghost-%COMP%] .annotationLayer .textAnnotation img{position:absolute;cursor:pointer}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;padding:0 3px;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;padding:0 3px;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select option{padding:0}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{border-radius:50%}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea{font:message-box;font-size:9px;resize:none}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input[disabled], [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input[disabled], [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input:hover, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:hover, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input:focus, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea:focus{background:0 0;border:1px solid transparent}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select:focus{background:0 0;border:1px solid transparent}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before{background-color:#000;content:"";display:block;position:absolute;height:80%;left:45%;width:1px}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input:checked:before{background-color:#000;content:"";display:block;position:absolute;border-radius:50%;height:50%;left:30%;top:20%;width:50%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before{transform:rotate(45deg)}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after{transform:rotate(-45deg)}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input.comb{font-family:monospace;padding-left:2px;padding-right:0}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input.comb:focus{width:115%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0}[_nghost-%COMP%] .annotationLayer .popupWrapper{position:absolute;width:20em}[_nghost-%COMP%] .annotationLayer .popup{position:absolute;z-index:200;max-width:20em;background-color:#ff9;box-shadow:0 2px 5px #888;border-radius:2px;padding:6px;margin-left:5px;cursor:pointer;font:message-box;font-size:9px;word-wrap:break-word}[_nghost-%COMP%] .annotationLayer .popup>*{font-size:9px}[_nghost-%COMP%] .annotationLayer .popup h1{display:inline-block}[_nghost-%COMP%] .annotationLayer .popup span{display:inline-block;margin-left:5px}[_nghost-%COMP%] .annotationLayer .popup p{border-top:1px solid #333;margin-top:2px;padding-top:2px}[_nghost-%COMP%] .annotationLayer .caretAnnotation, [_nghost-%COMP%] .annotationLayer .circleAnnotation svg ellipse, [_nghost-%COMP%] .annotationLayer .fileAttachmentAnnotation, [_nghost-%COMP%] .annotationLayer .freeTextAnnotation, [_nghost-%COMP%] .annotationLayer .highlightAnnotation, [_nghost-%COMP%] .annotationLayer .inkAnnotation svg polyline, [_nghost-%COMP%] .annotationLayer .lineAnnotation svg line, [_nghost-%COMP%] .annotationLayer .polygonAnnotation svg polygon, [_nghost-%COMP%] .annotationLayer .polylineAnnotation svg polyline, [_nghost-%COMP%] .annotationLayer .squareAnnotation svg rect, [_nghost-%COMP%] .annotationLayer .squigglyAnnotation, [_nghost-%COMP%] .annotationLayer .stampAnnotation, [_nghost-%COMP%] .annotationLayer .strikeoutAnnotation, [_nghost-%COMP%] .annotationLayer .underlineAnnotation{cursor:pointer}[_nghost-%COMP%] .pdfViewer{padding-bottom:10px}[_nghost-%COMP%] .pdfViewer .canvasWrapper{overflow:hidden}[_nghost-%COMP%] .pdfViewer .page{direction:ltr;width:816px;height:1056px;margin:1px auto -8px;position:relative;overflow:visible;border:9px solid rgba(0,0,0,.01);box-sizing:initial;background-clip:content-box;-o-border-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAA6UlEQVR4Xl2Pi2rEMAwE16fm1f7/r14v7w4rI0IzLAF7hLxNevBSEMEF5+OilNCsRd8ZMyn+a4NmsOT8WJw1lFbSYgGFzF2bLFoLjTClWjKKGRWpDYAGXUnZ4uhbBUzF3Oe/GG/ue2fn4GgsyXhNgysV2JnrhKEMg4fEZcALmiKbNhBBRFpSyDOj1G4QOVly6O1FV54ZZq8OVygrciDt6JazRgi1ljTPH0gbrPmHPXAbCiDd4GawIjip1TPh9tt2sz24qaCjr/jAb/GBFTbq9KZ7Ke/Cqt8nayUikZKsWZK7Fe6bg5dOUt8fZHWG2BHc+6EAAAAASUVORK5CYII=) 9 9 repeat;border-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAA6UlEQVR4Xl2Pi2rEMAwE16fm1f7/r14v7w4rI0IzLAF7hLxNevBSEMEF5+OilNCsRd8ZMyn+a4NmsOT8WJw1lFbSYgGFzF2bLFoLjTClWjKKGRWpDYAGXUnZ4uhbBUzF3Oe/GG/ue2fn4GgsyXhNgysV2JnrhKEMg4fEZcALmiKbNhBBRFpSyDOj1G4QOVly6O1FV54ZZq8OVygrciDt6JazRgi1ljTPH0gbrPmHPXAbCiDd4GawIjip1TPh9tt2sz24qaCjr/jAb/GBFTbq9KZ7Ke/Cqt8nayUikZKsWZK7Fe6bg5dOUt8fZHWG2BHc+6EAAAAASUVORK5CYII=) 9 9 repeat;background-color:#fff}[_nghost-%COMP%] .pdfViewer.removePageBorders .page{margin:0 auto 10px;border:none}[_nghost-%COMP%] .pdfViewer.removePageBorders{padding-bottom:0}[_nghost-%COMP%] .pdfViewer.singlePageView{display:inline-block}[_nghost-%COMP%] .pdfViewer.singlePageView .page{margin:0;border:none}[_nghost-%COMP%] .pdfViewer.scrollHorizontal, [_nghost-%COMP%] .pdfViewer.scrollWrapped{margin-left:3.5px;margin-right:3.5px;text-align:center}[_nghost-%COMP%] .spread{margin-left:3.5px;margin-right:3.5px;text-align:center}[_nghost-%COMP%] .pdfViewer.scrollHorizontal, [_nghost-%COMP%] .spread{white-space:nowrap}[_nghost-%COMP%] .pdfViewer.removePageBorders, [_nghost-%COMP%] .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%] .pdfViewer.scrollWrapped .spread{margin-left:0;margin-right:0}[_nghost-%COMP%] .spread .page{display:inline-block;vertical-align:middle;margin-left:-3.5px;margin-right:-3.5px}[_nghost-%COMP%] .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%] .pdfViewer.scrollWrapped .page, [_nghost-%COMP%] .pdfViewer.scrollWrapped .spread{display:inline-block;vertical-align:middle}[_nghost-%COMP%] .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.scrollWrapped .page{margin-left:-3.5px;margin-right:-3.5px}[_nghost-%COMP%] .pdfViewer.removePageBorders .spread .page, [_nghost-%COMP%] .pdfViewer.removePageBorders.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.removePageBorders.scrollWrapped .page{margin-left:5px;margin-right:5px}[_nghost-%COMP%] .pdfViewer .page canvas{margin:0;display:block}[_nghost-%COMP%] .pdfViewer .page canvas[hidden]{display:none}[_nghost-%COMP%] .pdfViewer .page .loadingIcon{position:absolute;display:block;left:0;top:0;right:0;bottom:0;background:url(data:image/gif;base64,R0lGODlhGAAYAPQAAP///wAAAM7Ozvr6+uDg4LCwsOjo6I6OjsjIyJycnNjY2KioqMDAwPLy8nZ2doaGhri4uGhoaAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJBwAAACwAAAAAGAAYAAAFriAgjiQAQWVaDgr5POSgkoTDjFE0NoQ8iw8HQZQTDQjDn4jhSABhAAOhoTqSDg7qSUQwxEaEwwFhXHhHgzOA1xshxAnfTzotGRaHglJqkJcaVEqCgyoCBQkJBQKDDXQGDYaIioyOgYSXA36XIgYMBWRzXZoKBQUMmil0lgalLSIClgBpO0g+s26nUWddXyoEDIsACq5SsTMMDIECwUdJPw0Mzsu0qHYkw72bBmozIQAh+QQJBwAAACwAAAAAGAAYAAAFsCAgjiTAMGVaDgR5HKQwqKNxIKPjjFCk0KNXC6ATKSI7oAhxWIhezwhENTCQEoeGCdWIPEgzESGxEIgGBWstEW4QCGGAIJEoxGmGt5ZkgCRQQHkGd2CESoeIIwoMBQUMP4cNeQQGDYuNj4iSb5WJnmeGng0CDGaBlIQEJziHk3sABidDAHBgagButSKvAAoyuHuUYHgCkAZqebw0AgLBQyyzNKO3byNuoSS8x8OfwIchACH5BAkHAAAALAAAAAAYABgAAAW4ICCOJIAgZVoOBJkkpDKoo5EI43GMjNPSokXCINKJCI4HcCRIQEQvqIOhGhBHhUTDhGo4diOZyFAoKEQDxra2mAEgjghOpCgz3LTBIxJ5kgwMBShACREHZ1V4Kg1rS44pBAgMDAg/Sw0GBAQGDZGTlY+YmpyPpSQDiqYiDQoCliqZBqkGAgKIS5kEjQ21VwCyp76dBHiNvz+MR74AqSOdVwbQuo+abppo10ssjdkAnc0rf8vgl8YqIQAh+QQJBwAAACwAAAAAGAAYAAAFrCAgjiQgCGVaDgZZFCQxqKNRKGOSjMjR0qLXTyciHA7AkaLACMIAiwOC1iAxCrMToHHYjWQiA4NBEA0Q1RpWxHg4cMXxNDk4OBxNUkPAQAEXDgllKgMzQA1pSYopBgonCj9JEA8REQ8QjY+RQJOVl4ugoYssBJuMpYYjDQSliwasiQOwNakALKqsqbWvIohFm7V6rQAGP6+JQLlFg7KDQLKJrLjBKbvAor3IKiEAIfkECQcAAAAsAAAAABgAGAAABbUgII4koChlmhokw5DEoI4NQ4xFMQoJO4uuhignMiQWvxGBIQC+AJBEUyUcIRiyE6CR0CllW4HABxBURTUw4nC4FcWo5CDBRpQaCoF7VjgsyCUDYDMNZ0mHdwYEBAaGMwwHDg4HDA2KjI4qkJKUiJ6faJkiA4qAKQkRB3E0i6YpAw8RERAjA4tnBoMApCMQDhFTuySKoSKMJAq6rD4GzASiJYtgi6PUcs9Kew0xh7rNJMqIhYchACH5BAkHAAAALAAAAAAYABgAAAW0ICCOJEAQZZo2JIKQxqCOjWCMDDMqxT2LAgELkBMZCoXfyCBQiFwiRsGpku0EshNgUNAtrYPT0GQVNRBWwSKBMp98P24iISgNDAS4ipGA6JUpA2WAhDR4eWM/CAkHBwkIDYcGiTOLjY+FmZkNlCN3eUoLDmwlDW+AAwcODl5bYl8wCVYMDw5UWzBtnAANEQ8kBIM0oAAGPgcREIQnVloAChEOqARjzgAQEbczg8YkWJq8nSUhACH5BAkHAAAALAAAAAAYABgAAAWtICCOJGAYZZoOpKKQqDoORDMKwkgwtiwSBBYAJ2owGL5RgxBziQQMgkwoMkhNqAEDARPSaiMDFdDIiRSFQowMXE8Z6RdpYHWnEAWGPVkajPmARVZMPUkCBQkJBQINgwaFPoeJi4GVlQ2Qc3VJBQcLV0ptfAMJBwdcIl+FYjALQgimoGNWIhAQZA4HXSpLMQ8PIgkOSHxAQhERPw7ASTSFyCMMDqBTJL8tf3y2fCEAIfkECQcAAAAsAAAAABgAGAAABa8gII4k0DRlmg6kYZCoOg5EDBDEaAi2jLO3nEkgkMEIL4BLpBAkVy3hCTAQKGAznM0AFNFGBAbj2cA9jQixcGZAGgECBu/9HnTp+FGjjezJFAwFBQwKe2Z+KoCChHmNjVMqA21nKQwJEJRlbnUFCQlFXlpeCWcGBUACCwlrdw8RKGImBwktdyMQEQciB7oACwcIeA4RVwAODiIGvHQKERAjxyMIB5QlVSTLYLZ0sW8hACH5BAkHAAAALAAAAAAYABgAAAW0ICCOJNA0ZZoOpGGQrDoOBCoSxNgQsQzgMZyIlvOJdi+AS2SoyXrK4umWPM5wNiV0UDUIBNkdoepTfMkA7thIECiyRtUAGq8fm2O4jIBgMBA1eAZ6Knx+gHaJR4QwdCMKBxEJRggFDGgQEREPjjAMBQUKIwIRDhBDC2QNDDEKoEkDoiMHDigICGkJBS2dDA6TAAnAEAkCdQ8ORQcHTAkLcQQODLPMIgIJaCWxJMIkPIoAt3EhACH5BAkHAAAALAAAAAAYABgAAAWtICCOJNA0ZZoOpGGQrDoOBCoSxNgQsQzgMZyIlvOJdi+AS2SoyXrK4umWHM5wNiV0UN3xdLiqr+mENcWpM9TIbrsBkEck8oC0DQqBQGGIz+t3eXtob0ZTPgNrIwQJDgtGAgwCWSIMDg4HiiUIDAxFAAoODwxDBWINCEGdSTQkCQcoegADBaQ6MggHjwAFBZUFCm0HB0kJCUy9bAYHCCPGIwqmRq0jySMGmj6yRiEAIfkECQcAAAAsAAAAABgAGAAABbIgII4k0DRlmg6kYZCsOg4EKhLE2BCxDOAxnIiW84l2L4BLZKipBopW8XRLDkeCiAMyMvQAA+uON4JEIo+vqukkKQ6RhLHplVGN+LyKcXA4Dgx5DWwGDXx+gIKENnqNdzIDaiMECwcFRgQCCowiCAcHCZIlCgICVgSfCEMMnA0CXaU2YSQFoQAKUQMMqjoyAglcAAyBAAIMRUYLCUkFlybDeAYJryLNk6xGNCTQXY0juHghACH5BAkHAAAALAAAAAAYABgAAAWzICCOJNA0ZVoOAmkY5KCSSgSNBDE2hDyLjohClBMNij8RJHIQvZwEVOpIekRQJyJs5AMoHA+GMbE1lnm9EcPhOHRnhpwUl3AsknHDm5RN+v8qCAkHBwkIfw1xBAYNgoSGiIqMgJQifZUjBhAJYj95ewIJCQV7KYpzBAkLLQADCHOtOpY5PgNlAAykAEUsQ1wzCgWdCIdeArczBQVbDJ0NAqyeBb64nQAGArBTt8R8mLuyPyEAOwAAAAAAAAAAAA==) center no-repeat}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer{margin-left:0;margin-right:0}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode .pdfViewer .spread{display:block}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode .pdfViewer.removePageBorders .page{margin-left:auto;margin-right:auto}[_nghost-%COMP%] .pdfPresentationMode:-ms-fullscreen .pdfViewer .page{margin-bottom:100%!important}[_nghost-%COMP%] .pdfPresentationMode:-webkit-full-screen .pdfViewer .page{margin-bottom:100%;border:0}[_nghost-%COMP%] .pdfPresentationMode:-moz-full-screen .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode:-webkit-full-screen .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode:fullscreen .pdfViewer .page{margin-bottom:100%;border:0}']}),e.CSS_UNITS=96/72,e.BORDER_WIDTH=9,e})(),qc=(()=>{let e=class{};return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)}}),e})();const Vc=["wrapper"];let Uc=(()=>{class e{constructor(){this.loaded=!1}ngOnInit(){}ngOnChanges(e){}}return e.\u0275fac=function(t){return new(t||e)},e.\u0275cmp=rt({type:e,selectors:[["drayman-pdf-viewer-internal"]],viewQuery:function(e,t){var n;1&e&&rs(Vc,!0),2&e&&ns(n=is())&&(t.wrapper=n.first)},inputs:{src:"src",page:"page"},features:[At],decls:2,vars:6,consts:[[3,"src","page","show-all","original-size","autoresize","fit-to-page","after-load-complete"],["wrapper",""]],template:function(e,t){1&e&&(zi(0,"pdf-viewer",0,1),Yi("after-load-complete",(function(){return t.loaded=!0})),Gi()),2&e&&Hi("src",t.src)("page",t.page)("show-all",!t.page)("original-size",!1)("autoresize",!0)("fit-to-page",!0)},directives:[Bc],styles:["pdf-viewer[_ngcontent-%COMP%]{width:100%;height:100%}"]}),e})(),Hc=(()=>{class e{constructor(e){this.injector=e}ngDoBootstrap(){const e=function(e,t){const n=function(e,t){return t.get(eo).resolveComponentFactory(e).inputs}(e,t.injector),r=t.strategyFactory||new pa(e,t.injector),i=function(e){const t={};return e.forEach(({propName:e,templateName:n})=>{var r;t[(r=n,r.replace(/[A-Z]/g,e=>"-"+e.toLowerCase()))]=e}),t}(n);class o extends ya{constructor(e){super(),this.injector=e}get ngElementStrategy(){if(!this._ngElementStrategy){const e=this._ngElementStrategy=r.create(this.injector||t.injector),i=n.filter(({propName:e})=>this.hasOwnProperty(e)).map(({propName:e})=>[e,this[e]]);this instanceof o?i.forEach(([e])=>delete this[e]):ma(n,this),i.forEach(([t,n])=>e.setInputValue(t,n))}return this._ngElementStrategy}attributeChangedCallback(e,t,n,r){this.ngElementStrategy.setInputValue(i[e],n)}connectedCallback(){let e=!1;this.ngElementStrategy.events&&(this.subscribeToEvents(),e=!0),this.ngElementStrategy.connect(this),e||this.subscribeToEvents()}disconnectedCallback(){this._ngElementStrategy&&this._ngElementStrategy.disconnect(),this.ngElementEventsSubscription&&(this.ngElementEventsSubscription.unsubscribe(),this.ngElementEventsSubscription=null)}subscribeToEvents(){this.ngElementEventsSubscription=this.ngElementStrategy.events.subscribe(e=>{const t=function(e,t,n){if("function"!=typeof CustomEvent){const r=e.createEvent("CustomEvent");return r.initCustomEvent(t,!1,!1,n),r}return new CustomEvent(t,{bubbles:!1,cancelable:!1,detail:n})}(this.ownerDocument,e.name,e.value);this.dispatchEvent(t)})}}return o.observedAttributes=Object.keys(i),Object.defineProperty(o.prototype,"ngElementStrategy",{enumerable:!0}),ma(n,o.prototype),o}(Uc,{injector:this.injector});customElements.define("drayman-pdf-viewer",e)}}return e.\u0275mod=at({type:e}),e.\u0275inj=ae({factory:function(t){return new(t||e)(We(Fi))},imports:[[Ja,Rc,qc]]}),e})();(function(){if(Yn)throw new Error("Cannot enable prod mode after platform setup.");Qn=!1})(),Xa().bootstrapModule(Hc).catch(e=>console.error(e))},zn8P:function(e,t){function n(e){return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}))}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id="zn8P"}});
1
+ (()=>{var __webpack_modules__={36:function(module,__unused_webpack_exports,__webpack_require__){var _asyncToGenerator=__webpack_require__(926).default,z;z=function(){return function(we){var v={};function z(f){if(v[f])return v[f].exports;var H=v[f]={i:f,l:!1,exports:{}};return we[f].call(H.exports,H,H.exports,z),H.l=!0,H.exports}return z.m=we,z.c=v,z.d=function(f,H,N){z.o(f,H)||Object.defineProperty(f,H,{enumerable:!0,get:N})},z.r=function(f){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(f,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(f,"__esModule",{value:!0})},z.t=function(f,H){if(1&H&&(f=z(f)),8&H||4&H&&"object"==typeof f&&f&&f.__esModule)return f;var N=Object.create(null);if(z.r(N),Object.defineProperty(N,"default",{enumerable:!0,value:f}),2&H&&"string"!=typeof f)for(var q in f)z.d(N,q,function(B){return f[B]}.bind(null,q));return N},z.n=function(f){var H=f&&f.__esModule?function(){return f.default}:function(){return f};return z.d(H,"a",H),H},z.o=function(f,H){return Object.prototype.hasOwnProperty.call(f,H)},z.p="",z(z.s=0)}([function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),Object.defineProperty(v,"addLinkAttributes",{enumerable:!0,get:function(){return f.addLinkAttributes}}),Object.defineProperty(v,"getFilenameFromUrl",{enumerable:!0,get:function(){return f.getFilenameFromUrl}}),Object.defineProperty(v,"LinkTarget",{enumerable:!0,get:function(){return f.LinkTarget}}),Object.defineProperty(v,"loadScript",{enumerable:!0,get:function(){return f.loadScript}}),Object.defineProperty(v,"PDFDateString",{enumerable:!0,get:function(){return f.PDFDateString}}),Object.defineProperty(v,"RenderingCancelledException",{enumerable:!0,get:function(){return f.RenderingCancelledException}}),Object.defineProperty(v,"build",{enumerable:!0,get:function(){return H.build}}),Object.defineProperty(v,"getDocument",{enumerable:!0,get:function(){return H.getDocument}}),Object.defineProperty(v,"LoopbackPort",{enumerable:!0,get:function(){return H.LoopbackPort}}),Object.defineProperty(v,"PDFDataRangeTransport",{enumerable:!0,get:function(){return H.PDFDataRangeTransport}}),Object.defineProperty(v,"PDFWorker",{enumerable:!0,get:function(){return H.PDFWorker}}),Object.defineProperty(v,"version",{enumerable:!0,get:function(){return H.version}}),Object.defineProperty(v,"CMapCompressionType",{enumerable:!0,get:function(){return N.CMapCompressionType}}),Object.defineProperty(v,"createObjectURL",{enumerable:!0,get:function(){return N.createObjectURL}}),Object.defineProperty(v,"createPromiseCapability",{enumerable:!0,get:function(){return N.createPromiseCapability}}),Object.defineProperty(v,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return N.createValidAbsoluteUrl}}),Object.defineProperty(v,"InvalidPDFException",{enumerable:!0,get:function(){return N.InvalidPDFException}}),Object.defineProperty(v,"MissingPDFException",{enumerable:!0,get:function(){return N.MissingPDFException}}),Object.defineProperty(v,"OPS",{enumerable:!0,get:function(){return N.OPS}}),Object.defineProperty(v,"PasswordResponses",{enumerable:!0,get:function(){return N.PasswordResponses}}),Object.defineProperty(v,"PermissionFlag",{enumerable:!0,get:function(){return N.PermissionFlag}}),Object.defineProperty(v,"removeNullCharacters",{enumerable:!0,get:function(){return N.removeNullCharacters}}),Object.defineProperty(v,"shadow",{enumerable:!0,get:function(){return N.shadow}}),Object.defineProperty(v,"UnexpectedResponseException",{enumerable:!0,get:function(){return N.UnexpectedResponseException}}),Object.defineProperty(v,"UNSUPPORTED_FEATURES",{enumerable:!0,get:function(){return N.UNSUPPORTED_FEATURES}}),Object.defineProperty(v,"Util",{enumerable:!0,get:function(){return N.Util}}),Object.defineProperty(v,"VerbosityLevel",{enumerable:!0,get:function(){return N.VerbosityLevel}}),Object.defineProperty(v,"AnnotationLayer",{enumerable:!0,get:function(){return q.AnnotationLayer}}),Object.defineProperty(v,"apiCompatibilityParams",{enumerable:!0,get:function(){return B.apiCompatibilityParams}}),Object.defineProperty(v,"GlobalWorkerOptions",{enumerable:!0,get:function(){return j.GlobalWorkerOptions}}),Object.defineProperty(v,"renderTextLayer",{enumerable:!0,get:function(){return k.renderTextLayer}}),Object.defineProperty(v,"SVGGraphics",{enumerable:!0,get:function(){return E.SVGGraphics}});var f=z(1),H=z(5),N=z(2),q=z(16),B=z(7),j=z(10),k=z(17),E=z(18);{const{isNodeJS:_}=z(4);if(_){const b=z(19).PDFNodeStream;(0,H.setPDFNetworkStreamFactory)(A=>new b(A))}else{const b=z(22).PDFNetworkStream;let A;(0,f.isFetchSupported)()&&(A=z(23).PDFFetchStream),(0,H.setPDFNetworkStreamFactory)(x=>A&&(0,f.isValidFetchUrl)(x.url)?new A(x):new b(x))}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.addLinkAttributes=function F(c,{url:d,target:m,rel:D,enabled:I=!0}={}){(0,f.assert)(d&&"string"==typeof d,'addLinkAttributes: A valid "url" parameter must provided.');const W=(0,f.removeNullCharacters)(d);I?c.href=c.title=W:(c.href="",c.title=`Disabled: ${W}`,c.onclick=()=>!1);let G="";switch(m){case R.NONE:break;case R.SELF:G="_self";break;case R.BLANK:G="_blank";break;case R.PARENT:G="_parent";break;case R.TOP:G="_top"}c.target=G,c.rel="string"==typeof D?D:H},v.getFilenameFromUrl=function _(c){const d=c.indexOf("#"),m=c.indexOf("?"),D=Math.min(d>0?d:c.length,m>0?m:c.length);return c.substring(c.lastIndexOf("/",D)+1,D)},v.isFetchSupported=A,v.isValidFetchUrl=x,v.loadScript=function M(c){return new Promise((d,m)=>{const D=document.createElement("script");D.src=c,D.onload=d,D.onerror=function(){m(new Error(`Cannot load script at: ${D.src}`))},(document.head||document.documentElement).appendChild(D)})},v.deprecated=function V(c){console.log("Deprecated API usage: "+c)},v.PDFDateString=v.StatTimer=v.DOMSVGFactory=v.DOMCMapReaderFactory=v.DOMCanvasFactory=v.DEFAULT_LINK_REL=v.LinkTarget=v.RenderingCancelledException=v.PageViewport=void 0;var f=z(2);const H="noopener noreferrer nofollow";v.DEFAULT_LINK_REL=H;const N="http://www.w3.org/2000/svg";v.DOMCanvasFactory=class q{create(d,m){if(d<=0||m<=0)throw new Error("Invalid canvas size");const D=document.createElement("canvas"),I=D.getContext("2d");return D.width=d,D.height=m,{canvas:D,context:I}}reset(d,m,D){if(!d.canvas)throw new Error("Canvas is not specified");if(m<=0||D<=0)throw new Error("Invalid canvas size");d.canvas.width=m,d.canvas.height=D}destroy(d){if(!d.canvas)throw new Error("Canvas is not specified");d.canvas.width=0,d.canvas.height=0,d.canvas=null,d.context=null}},v.DOMCMapReaderFactory=class B{constructor({baseUrl:d=null,isCompressed:m=!1}){this.baseUrl=d,this.isCompressed=m}fetch({name:d}){var m=this;return _asyncToGenerator(function*(){if(!m.baseUrl)throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');if(!d)throw new Error("CMap name must be specified.");const D=m.baseUrl+d+(m.isCompressed?".bcmap":""),I=m.isCompressed?f.CMapCompressionType.BINARY:f.CMapCompressionType.NONE;return A()&&x(D,document.baseURI)?fetch(D).then(function(){var W=_asyncToGenerator(function*(G){if(!G.ok)throw new Error(G.statusText);let Y;return Y=m.isCompressed?new Uint8Array(yield G.arrayBuffer()):(0,f.stringToBytes)(yield G.text()),{cMapData:Y,compressionType:I}});return function(G){return W.apply(this,arguments)}}()).catch(W=>{throw new Error(`Unable to load ${m.isCompressed?"binary ":""}CMap at: ${D}`)}):new Promise((W,G)=>{const Y=new XMLHttpRequest;Y.open("GET",D,!0),m.isCompressed&&(Y.responseType="arraybuffer"),Y.onreadystatechange=()=>{if(Y.readyState===XMLHttpRequest.DONE){if(200===Y.status||0===Y.status){let Z;if(m.isCompressed&&Y.response?Z=new Uint8Array(Y.response):!m.isCompressed&&Y.responseText&&(Z=(0,f.stringToBytes)(Y.responseText)),Z)return void W({cMapData:Z,compressionType:I})}G(new Error(Y.statusText))}},Y.send(null)}).catch(W=>{throw new Error(`Unable to load ${m.isCompressed?"binary ":""}CMap at: ${D}`)})})()}},v.DOMSVGFactory=class j{create(d,m){(0,f.assert)(d>0&&m>0,"Invalid SVG dimensions");const D=document.createElementNS(N,"svg:svg");return D.setAttribute("version","1.1"),D.setAttribute("width",d+"px"),D.setAttribute("height",m+"px"),D.setAttribute("preserveAspectRatio","none"),D.setAttribute("viewBox","0 0 "+d+" "+m),D}createElement(d){return(0,f.assert)("string"==typeof d,"Invalid SVG element type"),document.createElementNS(N,d)}};class k{constructor({viewBox:d,scale:m,rotation:D,offsetX:I=0,offsetY:W=0,dontFlip:G=!1}){this.viewBox=d,this.scale=m,this.rotation=D,this.offsetX=I,this.offsetY=W;const Y=(d[2]+d[0])/2,Z=(d[3]+d[1])/2;let K,ce,U,y,L,P,T,w;switch(D=(D%=360)<0?D+360:D){case 180:K=-1,ce=0,U=0,y=1;break;case 90:K=0,ce=1,U=1,y=0;break;case 270:K=0,ce=-1,U=-1,y=0;break;case 0:K=1,ce=0,U=0,y=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}G&&(U=-U,y=-y),0===K?(L=Math.abs(Z-d[1])*m+I,P=Math.abs(Y-d[0])*m+W,T=Math.abs(d[3]-d[1])*m,w=Math.abs(d[2]-d[0])*m):(L=Math.abs(Y-d[0])*m+I,P=Math.abs(Z-d[1])*m+W,T=Math.abs(d[2]-d[0])*m,w=Math.abs(d[3]-d[1])*m),this.transform=[K*m,ce*m,U*m,y*m,L-K*m*Y-U*m*Z,P-ce*m*Y-y*m*Z],this.width=T,this.height=w}clone({scale:d=this.scale,rotation:m=this.rotation,offsetX:D=this.offsetX,offsetY:I=this.offsetY,dontFlip:W=!1}={}){return new k({viewBox:this.viewBox.slice(),scale:d,rotation:m,offsetX:D,offsetY:I,dontFlip:W})}convertToViewportPoint(d,m){return f.Util.applyTransform([d,m],this.transform)}convertToViewportRectangle(d){const m=f.Util.applyTransform([d[0],d[1]],this.transform),D=f.Util.applyTransform([d[2],d[3]],this.transform);return[m[0],m[1],D[0],D[1]]}convertToPdfPoint(d,m){return f.Util.applyInverseTransform([d,m],this.transform)}}v.PageViewport=k,v.RenderingCancelledException=class E extends f.BaseException{constructor(d,m){super(d),this.type=m}};const R={NONE:0,SELF:1,BLANK:2,PARENT:3,TOP:4};function A(){return"undefined"!=typeof fetch&&"undefined"!=typeof Response&&"body"in Response.prototype&&"undefined"!=typeof ReadableStream}function x(c,d){try{const{protocol:m}=d?new URL(c,d):new URL(c);return"http:"===m||"https:"===m}catch(m){return!1}}let h;v.LinkTarget=R,v.StatTimer=class b{constructor(){this.started=Object.create(null),this.times=[]}time(d){d in this.started&&(0,f.warn)(`Timer is already running for ${d}`),this.started[d]=Date.now()}timeEnd(d){d in this.started||(0,f.warn)(`Timer has not been started for ${d}`),this.times.push({name:d,start:this.started[d],end:Date.now()}),delete this.started[d]}toString(){const d=[];let m=0;for(const D of this.times){const I=D.name;I.length>m&&(m=I.length)}for(const D of this.times){const I=D.end-D.start;d.push(`${D.name.padEnd(m)} ${I}ms\n`)}return d.join("")}},v.PDFDateString=class p{static toDateObject(d){if(!d||!(0,f.isString)(d))return null;h||(h=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"));const m=h.exec(d);if(!m)return null;const D=parseInt(m[1],10);let I=parseInt(m[2],10);I=I>=1&&I<=12?I-1:0;let W=parseInt(m[3],10);W=W>=1&&W<=31?W:1;let G=parseInt(m[4],10);G=G>=0&&G<=23?G:0;let Y=parseInt(m[5],10);Y=Y>=0&&Y<=59?Y:0;let Z=parseInt(m[6],10);Z=Z>=0&&Z<=59?Z:0;const K=m[7]||"Z";let ce=parseInt(m[8],10);ce=ce>=0&&ce<=23?ce:0;let U=parseInt(m[9],10)||0;return U=U>=0&&U<=59?U:0,"-"===K?(G+=ce,Y+=U):"+"===K&&(G-=ce,Y-=U),new Date(Date.UTC(D,I,W,G,Y,Z))}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.arrayByteLength=pe,v.arraysToBytes=function Ae(ue){const ne=ue.length;if(1===ne&&ue[0]instanceof Uint8Array)return ue[0];let ae=0;for(let Je=0;Je<ne;Je++)ae+=pe(ue[Je]);let Pe=0;const Be=new Uint8Array(ae);for(let Je=0;Je<ne;Je++){let Qe=ue[Je];Qe instanceof Uint8Array||(Qe="string"==typeof Qe?ge(Qe):new Uint8Array(Qe));const gt=Qe.byteLength;Be.set(Qe,Pe),Pe+=gt}return Be},v.assert=Z,v.bytesToString=function de(ue){Z(null!==ue&&"object"==typeof ue&&void 0!==ue.length,"Invalid argument for bytesToString");const ne=ue.length;if(ne<8192)return String.fromCharCode.apply(null,ue);const Pe=[];for(let Be=0;Be<ne;Be+=8192){const Je=Math.min(Be+8192,ne),Qe=ue.subarray(Be,Je);Pe.push(String.fromCharCode.apply(null,Qe))}return Pe.join("")},v.createPromiseCapability=function _r(){const ue=Object.create(null);let ne=!1;return Object.defineProperty(ue,"settled",{get:()=>ne}),ue.promise=new Promise(function(ae,Pe){ue.resolve=function(Be){ne=!0,ae(Be)},ue.reject=function(Be){ne=!0,Pe(Be)}}),ue},v.getVerbosityLevel=function I(){return m},v.info=function W(ue){m>=V.INFOS&&console.log(`Info: ${ue}`)},v.isArrayBuffer=function $t(ue){return"object"==typeof ue&&null!==ue&&void 0!==ue.byteLength},v.isArrayEqual=function Nn(ue,ne){return ue.length===ne.length&&ue.every(function(ae,Pe){return ae===ne[Pe]})},v.isBool=function _t(ue){return"boolean"==typeof ue},v.isEmptyObj=function lt(ue){for(const ne in ue)return!1;return!0},v.isNum=function Vt(ue){return"number"==typeof ue},v.isString=function ut(ue){return"string"==typeof ue},v.isSameOrigin=function K(ue,ne){let ae;try{if(ae=new URL(ue),!ae.origin||"null"===ae.origin)return!1}catch(Be){return!1}const Pe=new URL(ne,ae);return ae.origin===Pe.origin},v.createValidAbsoluteUrl=function U(ue,ne){if(!ue)return null;try{const ae=ne?new URL(ue,ne):new URL(ue);if(function ce(ue){if(!ue)return!1;switch(ue.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}(ae))return ae}catch(ae){}return null},v.removeNullCharacters=function le(ue){return"string"!=typeof ue?(G("The argument for removeNullCharacters must be a string."),ue):ue.replace(re,"")},v.setVerbosityLevel=function D(ue){Number.isInteger(ue)&&(m=ue)},v.shadow=y,v.string32=function Ce(ue){return String.fromCharCode(ue>>24&255,ue>>16&255,ue>>8&255,255&ue)},v.stringToBytes=ge,v.stringToPDFString=function Se(ue){const ne=ue.length,ae=[];if("\xfe"===ue[0]&&"\xff"===ue[1])for(let Pe=2;Pe<ne;Pe+=2)ae.push(String.fromCharCode(ue.charCodeAt(Pe)<<8|ue.charCodeAt(Pe+1)));else if("\xff"===ue[0]&&"\xfe"===ue[1])for(let Pe=2;Pe<ne;Pe+=2)ae.push(String.fromCharCode(ue.charCodeAt(Pe+1)<<8|ue.charCodeAt(Pe)));else for(let Pe=0;Pe<ne;++Pe){const Be=be[ue.charCodeAt(Pe)];ae.push(Be?String.fromCharCode(Be):ue.charAt(Pe))}return ae.join("")},v.stringToUTF8String=function Ne(ue){return decodeURIComponent(escape(ue))},v.utf8StringToString=function qe(ue){return unescape(encodeURIComponent(ue))},v.warn=G,v.unreachable=Y,v.IsEvalSupportedCached=v.IsLittleEndianCached=v.createObjectURL=v.FormatError=v.Util=v.UnknownErrorException=v.UnexpectedResponseException=v.TextRenderingMode=v.StreamType=v.PermissionFlag=v.PasswordResponses=v.PasswordException=v.MissingPDFException=v.InvalidPDFException=v.AbortException=v.CMapCompressionType=v.ImageKind=v.FontType=v.AnnotationType=v.AnnotationStateModelType=v.AnnotationReviewState=v.AnnotationReplyType=v.AnnotationMarkedState=v.AnnotationFlag=v.AnnotationFieldFlag=v.AnnotationBorderStyleType=v.UNSUPPORTED_FEATURES=v.VerbosityLevel=v.OPS=v.IDENTITY_MATRIX=v.FONT_IDENTITY_MATRIX=v.BaseException=void 0,z(3),v.IDENTITY_MATRIX=[1,0,0,1,0,0],v.FONT_IDENTITY_MATRIX=[.001,0,0,.001,0,0],v.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},v.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},v.ImageKind={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3},v.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},v.AnnotationStateModelType={MARKED:"Marked",REVIEW:"Review"},v.AnnotationMarkedState={MARKED:"Marked",UNMARKED:"Unmarked"},v.AnnotationReviewState={ACCEPTED:"Accepted",REJECTED:"Rejected",CANCELLED:"Cancelled",COMPLETED:"Completed",NONE:"None"},v.AnnotationReplyType={GROUP:"Group",REPLY:"R"},v.AnnotationFlag={INVISIBLE:1,HIDDEN:2,PRINT:4,NOZOOM:8,NOROTATE:16,NOVIEW:32,READONLY:64,LOCKED:128,TOGGLENOVIEW:256,LOCKEDCONTENTS:512},v.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},v.AnnotationBorderStyleType={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5},v.StreamType={UNKNOWN:"UNKNOWN",FLATE:"FLATE",LZW:"LZW",DCT:"DCT",JPX:"JPX",JBIG:"JBIG",A85:"A85",AHX:"AHX",CCF:"CCF",RLX:"RLX"},v.FontType={UNKNOWN:"UNKNOWN",TYPE1:"TYPE1",TYPE1C:"TYPE1C",CIDFONTTYPE0:"CIDFONTTYPE0",CIDFONTTYPE0C:"CIDFONTTYPE0C",TRUETYPE:"TRUETYPE",CIDFONTTYPE2:"CIDFONTTYPE2",TYPE3:"TYPE3",OPENTYPE:"OPENTYPE",TYPE0:"TYPE0",MMTYPE1:"MMTYPE1"};const V={ERRORS:0,WARNINGS:1,INFOS:5};v.VerbosityLevel=V,v.CMapCompressionType={NONE:0,BINARY:1,STREAM:2},v.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},v.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"},v.PasswordResponses={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};let m=V.WARNINGS;function G(ue){m>=V.WARNINGS&&console.log(`Warning: ${ue}`)}function Y(ue){throw new Error(ue)}function Z(ue,ne){ue||Y(ne)}function y(ue,ne,ae){return Object.defineProperty(ue,ne,{value:ae,enumerable:!0,configurable:!0,writable:!1}),ae}const L=function(){function ne(ae){this.constructor===ne&&Y("Cannot initialize BaseException."),this.message=ae,this.name=this.constructor.name}return ne.prototype=new Error,ne.constructor=ne,ne}();v.BaseException=L,v.PasswordException=class P extends L{constructor(ne,ae){super(ne),this.code=ae}},v.UnknownErrorException=class T extends L{constructor(ne,ae){super(ne),this.details=ae}},v.InvalidPDFException=class w extends L{},v.MissingPDFException=class C extends L{},v.UnexpectedResponseException=class X extends L{constructor(ne,ae){super(ne),this.status=ae}},v.FormatError=class Q extends L{},v.AbortException=class ee extends L{};const re=/\x00/g;function ge(ue){Z("string"==typeof ue,"Invalid argument for stringToBytes");const ne=ue.length,ae=new Uint8Array(ne);for(let Pe=0;Pe<ne;++Pe)ae[Pe]=255&ue.charCodeAt(Pe);return ae}function pe(ue){return void 0!==ue.length?ue.length:(Z(void 0!==ue.byteLength,"arrayByteLength - invalid argument."),ue.byteLength)}v.IsLittleEndianCached={get value(){return y(this,"value",function xe(){const ue=new Uint8Array(4);return ue[0]=1,1===new Uint32Array(ue.buffer,0,1)[0]}())}},v.IsEvalSupportedCached={get value(){return y(this,"value",function ie(){try{return new Function(""),!0}catch(ue){return!1}}())}};const he=["rgb(",0,",",0,",",0,")"];class _e{static makeCssRgb(ne,ae,Pe){return he[1]=ne,he[3]=ae,he[5]=Pe,he.join("")}static transform(ne,ae){return[ne[0]*ae[0]+ne[2]*ae[1],ne[1]*ae[0]+ne[3]*ae[1],ne[0]*ae[2]+ne[2]*ae[3],ne[1]*ae[2]+ne[3]*ae[3],ne[0]*ae[4]+ne[2]*ae[5]+ne[4],ne[1]*ae[4]+ne[3]*ae[5]+ne[5]]}static applyTransform(ne,ae){return[ne[0]*ae[0]+ne[1]*ae[2]+ae[4],ne[0]*ae[1]+ne[1]*ae[3]+ae[5]]}static applyInverseTransform(ne,ae){const Pe=ae[0]*ae[3]-ae[1]*ae[2];return[(ne[0]*ae[3]-ne[1]*ae[2]+ae[2]*ae[5]-ae[4]*ae[3])/Pe,(-ne[0]*ae[1]+ne[1]*ae[0]+ae[4]*ae[1]-ae[5]*ae[0])/Pe]}static getAxialAlignedBoundingBox(ne,ae){const Pe=_e.applyTransform(ne,ae),Be=_e.applyTransform(ne.slice(2,4),ae),Je=_e.applyTransform([ne[0],ne[3]],ae),Qe=_e.applyTransform([ne[2],ne[1]],ae);return[Math.min(Pe[0],Be[0],Je[0],Qe[0]),Math.min(Pe[1],Be[1],Je[1],Qe[1]),Math.max(Pe[0],Be[0],Je[0],Qe[0]),Math.max(Pe[1],Be[1],Je[1],Qe[1])]}static inverseTransform(ne){const ae=ne[0]*ne[3]-ne[1]*ne[2];return[ne[3]/ae,-ne[1]/ae,-ne[2]/ae,ne[0]/ae,(ne[2]*ne[5]-ne[4]*ne[3])/ae,(ne[4]*ne[1]-ne[5]*ne[0])/ae]}static apply3dTransform(ne,ae){return[ne[0]*ae[0]+ne[1]*ae[1]+ne[2]*ae[2],ne[3]*ae[0]+ne[4]*ae[1]+ne[5]*ae[2],ne[6]*ae[0]+ne[7]*ae[1]+ne[8]*ae[2]]}static singularValueDecompose2dScale(ne){const ae=[ne[0],ne[2],ne[1],ne[3]],Pe=ne[0]*ae[0]+ne[1]*ae[2],Qe=ne[2]*ae[1]+ne[3]*ae[3],gt=(Pe+Qe)/2,Ke=Math.sqrt((Pe+Qe)*(Pe+Qe)-4*(Pe*Qe-(ne[2]*ae[0]+ne[3]*ae[2])*(ne[0]*ae[1]+ne[1]*ae[3])))/2,et=gt-Ke||1;return[Math.sqrt(gt+Ke||1),Math.sqrt(et)]}static normalizeRect(ne){const ae=ne.slice(0);return ne[0]>ne[2]&&(ae[0]=ne[2],ae[2]=ne[0]),ne[1]>ne[3]&&(ae[1]=ne[3],ae[3]=ne[1]),ae}static intersect(ne,ae){function Pe(gt,Ke){return gt-Ke}const Be=[ne[0],ne[2],ae[0],ae[2]].sort(Pe),Je=[ne[1],ne[3],ae[1],ae[3]].sort(Pe),Qe=[];return ne=_e.normalizeRect(ne),ae=_e.normalizeRect(ae),Be[0]===ne[0]&&Be[1]===ae[0]||Be[0]===ae[0]&&Be[1]===ne[0]?(Qe[0]=Be[1],Qe[2]=Be[2],Je[0]===ne[1]&&Je[1]===ae[1]||Je[0]===ae[1]&&Je[1]===ne[1]?(Qe[1]=Je[1],Qe[3]=Je[2],Qe):null):null}}v.Util=_e;const be=[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],jt=function(){const ne="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";return function(Pe,Be,Je=!1){if(!Je&&URL.createObjectURL){const gt=new Blob([Pe],{type:Be});return URL.createObjectURL(gt)}let Qe=`data:${Be};base64,`;for(let gt=0,Ke=Pe.length;gt<Ke;gt+=3){const Qn=255&Pe[gt],et=255&Pe[gt+1],ri=255&Pe[gt+2];Qe+=ne[Qn>>2]+ne[(3&Qn)<<4|et>>4]+ne[gt+1<Ke?(15&et)<<2|ri>>6:64]+ne[gt+2<Ke?63&ri:64]}return Qe}}();v.createObjectURL=jt},function(we,v,z){"use strict";z(4)},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.isNodeJS=void 0;const f="object"==typeof process&&process+""=="[object process]"&&!process.versions.nw&&!process.versions.electron;v.isNodeJS=f},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 _util=__w_pdfjs_require__(2),_display_utils=__w_pdfjs_require__(1),_font_loader=__w_pdfjs_require__(6),_api_compatibility=__w_pdfjs_require__(7),_canvas=__w_pdfjs_require__(8),_worker_options=__w_pdfjs_require__(10),_is_node=__w_pdfjs_require__(4),_message_handler=__w_pdfjs_require__(11),_metadata=__w_pdfjs_require__(12),_transport_stream=__w_pdfjs_require__(14),_webgl=__w_pdfjs_require__(15);const DEFAULT_RANGE_CHUNK_SIZE=65536,RENDERING_CANCELLED_TIMEOUT=100;let createPDFNetworkStream;function setPDFNetworkStreamFactory(we){createPDFNetworkStream=we}function getDocument(we){const v=new PDFDocumentLoadingTask;let z;if("string"==typeof we)z={url:we};else if((0,_util.isArrayBuffer)(we))z={data:we};else if(we instanceof PDFDataRangeTransport)z={range:we};else{if("object"!=typeof we)throw new Error("Invalid parameter in getDocument, need either Uint8Array, string or a parameter object");if(!we.url&&!we.data&&!we.range)throw new Error("Invalid parameter object: need either .data, .range or .url");z=we}const f=Object.create(null);let H=null,N=null;for(const B in z)if("url"!==B||"undefined"==typeof window)if("range"!==B)if("worker"!==B)if("data"!==B||z[B]instanceof Uint8Array)f[B]=z[B];else{const j=z[B];if("string"==typeof j)f[B]=(0,_util.stringToBytes)(j);else if("object"!=typeof j||null===j||isNaN(j.length)){if(!(0,_util.isArrayBuffer)(j))throw new Error("Invalid PDF binary data: either typed array, string or array-like object is expected in the data property.");f[B]=new Uint8Array(j)}else f[B]=new Uint8Array(j)}else N=z[B];else H=z[B];else f[B]=new URL(z[B],window.location).href;if(f.rangeChunkSize=f.rangeChunkSize||DEFAULT_RANGE_CHUNK_SIZE,f.CMapReaderFactory=f.CMapReaderFactory||_display_utils.DOMCMapReaderFactory,f.ignoreErrors=!0!==f.stopAtErrors,f.fontExtraProperties=!0===f.fontExtraProperties,f.pdfBug=!0===f.pdfBug,Number.isInteger(f.maxImageSize)||(f.maxImageSize=-1),"boolean"!=typeof f.isEvalSupported&&(f.isEvalSupported=!0),"boolean"!=typeof f.disableFontFace&&(f.disableFontFace=_api_compatibility.apiCompatibilityParams.disableFontFace||!1),"boolean"!=typeof f.disableRange&&(f.disableRange=!1),"boolean"!=typeof f.disableStream&&(f.disableStream=!1),"boolean"!=typeof f.disableAutoFetch&&(f.disableAutoFetch=!1),(0,_util.setVerbosityLevel)(f.verbosity),!N){const B={verbosity:f.verbosity,port:_worker_options.GlobalWorkerOptions.workerPort};N=B.port?PDFWorker.fromPort(B):new PDFWorker(B),v._worker=N}const q=v.docId;return N.promise.then(function(){if(v.destroyed)throw new Error("Loading aborted");const B=_fetchDocument(N,f,H,q),j=new Promise(function(k){let E;H?E=new _transport_stream.PDFDataTransportStream({length:f.length,initialData:f.initialData,progressiveDone:f.progressiveDone,disableRange:f.disableRange,disableStream:f.disableStream},H):f.data||(E=createPDFNetworkStream({url:f.url,length:f.length,httpHeaders:f.httpHeaders,withCredentials:f.withCredentials,rangeChunkSize:f.rangeChunkSize,disableRange:f.disableRange,disableStream:f.disableStream})),k(E)});return Promise.all([B,j]).then(function([k,E]){if(v.destroyed)throw new Error("Loading aborted");const R=new _message_handler.MessageHandler(q,k,N.port);R.postMessageTransfers=N.postMessageTransfers;const F=new WorkerTransport(R,v,E,f);v._transport=F,R.send("Ready",null)})}).catch(v._capability.reject),v}function _fetchDocument(we,v,z,f){return we.destroyed?Promise.reject(new Error("Worker was destroyed")):(z&&(v.length=z.length,v.initialData=z.initialData,v.progressiveDone=z.progressiveDone),we.messageHandler.sendWithPromise("GetDocRequest",{docId:f,apiVersion:"2.5.207",source:{data:v.data,url:v.url,password:v.password,disableAutoFetch:v.disableAutoFetch,rangeChunkSize:v.rangeChunkSize,length:v.length},maxImageSize:v.maxImageSize,disableFontFace:v.disableFontFace,postMessageTransfers:we.postMessageTransfers,docBaseUrl:v.docBaseUrl,ignoreErrors:v.ignoreErrors,isEvalSupported:v.isEvalSupported,fontExtraProperties:v.fontExtraProperties}).then(function(H){if(we.destroyed)throw new Error("Worker was destroyed");return H}))}const PDFDocumentLoadingTask=function(){let v=0;return class z{constructor(){this._capability=(0,_util.createPromiseCapability)(),this._transport=null,this._worker=null,this.docId="d"+v++,this.destroyed=!1,this.onPassword=null,this.onProgress=null,this.onUnsupportedFeature=null}get promise(){return this._capability.promise}destroy(){return this.destroyed=!0,(this._transport?this._transport.destroy():Promise.resolve()).then(()=>{this._transport=null,this._worker&&(this._worker.destroy(),this._worker=null)})}}}();class PDFDataRangeTransport{constructor(v,z,f=!1){this.length=v,this.initialData=z,this.progressiveDone=f,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=(0,_util.createPromiseCapability)()}addRangeListener(v){this._rangeListeners.push(v)}addProgressListener(v){this._progressListeners.push(v)}addProgressiveReadListener(v){this._progressiveReadListeners.push(v)}addProgressiveDoneListener(v){this._progressiveDoneListeners.push(v)}onDataRange(v,z){for(const f of this._rangeListeners)f(v,z)}onDataProgress(v,z){this._readyCapability.promise.then(()=>{for(const f of this._progressListeners)f(v,z)})}onDataProgressiveRead(v){this._readyCapability.promise.then(()=>{for(const z of this._progressiveReadListeners)z(v)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const v of this._progressiveDoneListeners)v()})}transportReady(){this._readyCapability.resolve()}requestDataRange(v,z){(0,_util.unreachable)("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}}exports.PDFDataRangeTransport=PDFDataRangeTransport;class PDFDocumentProxy{constructor(v,z){this._pdfInfo=v,this._transport=z}get numPages(){return this._pdfInfo.numPages}get fingerprint(){return this._pdfInfo.fingerprint}getPage(v){return this._transport.getPage(v)}getPageIndex(v){return this._transport.getPageIndex(v)}getDestinations(){return this._transport.getDestinations()}getDestination(v){return this._transport.getDestination(v)}getPageLabels(){return this._transport.getPageLabels()}getPageLayout(){return this._transport.getPageLayout()}getPageMode(){return this._transport.getPageMode()}getViewerPreferences(){return this._transport.getViewerPreferences()}getOpenAction(){return this._transport.getOpenAction()}getOpenActionDestination(){return(0,_display_utils.deprecated)("getOpenActionDestination, use getOpenAction instead."),this.getOpenAction().then(function(v){return v&&v.dest?v.dest:null})}getAttachments(){return this._transport.getAttachments()}getJavaScript(){return this._transport.getJavaScript()}getOutline(){return this._transport.getOutline()}getPermissions(){return this._transport.getPermissions()}getMetadata(){return this._transport.getMetadata()}getData(){return this._transport.getData()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}getStats(){return this._transport.getStats()}cleanup(){return this._transport.startCleanup()}destroy(){return this.loadingTask.destroy()}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}}exports.PDFDocumentProxy=PDFDocumentProxy;class PDFPageProxy{constructor(v,z,f,H=!1){this._pageIndex=v,this._pageInfo=z,this._transport=f,this._stats=H?new _display_utils.StatTimer:null,this._pdfBug=H,this.commonObjs=f.commonObjs,this.objs=new PDFObjects,this.cleanupAfterRender=!1,this.pendingCleanup=!1,this.intentStates=Object.create(null),this.destroyed=!1}get pageNumber(){return this._pageIndex+1}get rotate(){return this._pageInfo.rotate}get ref(){return this._pageInfo.ref}get userUnit(){return this._pageInfo.userUnit}get view(){return this._pageInfo.view}getViewport({scale:v,rotation:z=this.rotate,offsetX:f=0,offsetY:H=0,dontFlip:N=!1}={}){return new _display_utils.PageViewport({viewBox:this.view,scale:v,rotation:z,offsetX:f,offsetY:H,dontFlip:N})}getAnnotations({intent:v=null}={}){return(!this.annotationsPromise||this.annotationsIntent!==v)&&(this.annotationsPromise=this._transport.getAnnotations(this._pageIndex,v),this.annotationsIntent=v),this.annotationsPromise}render({canvasContext:v,viewport:z,intent:f="display",enableWebGL:H=!1,renderInteractiveForms:N=!1,transform:q=null,imageLayer:B=null,canvasFactory:j=null,background:k=null}){this._stats&&this._stats.time("Overall");const E="print"===f?"print":"display";this.pendingCleanup=!1,this.intentStates[E]||(this.intentStates[E]=Object.create(null));const R=this.intentStates[E];R.streamReaderCancelTimeout&&(clearTimeout(R.streamReaderCancelTimeout),R.streamReaderCancelTimeout=null);const F=j||new _display_utils.DOMCanvasFactory,_=new _webgl.WebGLContext({enable:H});R.displayReadyCapability||(R.displayReadyCapability=(0,_util.createPromiseCapability)(),R.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:E,renderInteractiveForms:!0===N}));const b=M=>{const V=R.renderTasks.indexOf(A);V>=0&&R.renderTasks.splice(V,1),(this.cleanupAfterRender||"print"===E)&&(this.pendingCleanup=!0),this._tryCleanup(),M?(A.capability.reject(M),this._abortOperatorList({intentState:R,reason:M})):A.capability.resolve(),this._stats&&(this._stats.timeEnd("Rendering"),this._stats.timeEnd("Overall"))},A=new InternalRenderTask({callback:b,params:{canvasContext:v,viewport:z,transform:q,imageLayer:B,background:k},objs:this.objs,commonObjs:this.commonObjs,operatorList:R.operatorList,pageIndex:this._pageIndex,canvasFactory:F,webGLContext:_,useRequestAnimationFrame:"print"!==E,pdfBug:this._pdfBug});R.renderTasks||(R.renderTasks=[]),R.renderTasks.push(A);const x=A.task;return R.displayReadyCapability.promise.then(M=>{this.pendingCleanup?b():(this._stats&&this._stats.time("Rendering"),A.initializeGraphics(M),A.operatorListChanged())}).catch(b),x}getOperatorList(){const z="oplist";this.intentStates[z]||(this.intentStates[z]=Object.create(null));const f=this.intentStates[z];let H;return f.opListReadCapability||(H={},H.operatorListChanged=function v(){if(f.operatorList.lastChunk){f.opListReadCapability.resolve(f.operatorList);const N=f.renderTasks.indexOf(H);N>=0&&f.renderTasks.splice(N,1)}},f.opListReadCapability=(0,_util.createPromiseCapability)(),f.renderTasks=[],f.renderTasks.push(H),f.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList({pageIndex:this._pageIndex,intent:z})),f.opListReadCapability.promise}streamTextContent({normalizeWhitespace:v=!1,disableCombineTextItems:z=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,normalizeWhitespace:!0===v,combineTextItems:!0!==z},{highWaterMark:100,size:H=>H.items.length})}getTextContent(v={}){const z=this.streamTextContent(v);return new Promise(function(f,H){const q=z.getReader(),B={items:[],styles:Object.create(null)};!function N(){q.read().then(function({value:j,done:k}){k?f(B):(Object.assign(B.styles,j.styles),B.items.push(...j.items),N())},H)}()})}_destroy(){this.destroyed=!0,this._transport.pageCache[this._pageIndex]=null;const v=[];return Object.keys(this.intentStates).forEach(z=>{const f=this.intentStates[z];this._abortOperatorList({intentState:f,reason:new Error("Page was destroyed."),force:!0}),"oplist"!==z&&f.renderTasks.forEach(function(H){const N=H.capability.promise.catch(function(){});v.push(N),H.cancel()})}),this.objs.clear(),this.annotationsPromise=null,this.pendingCleanup=!1,Promise.all(v)}cleanup(v=!1){return this.pendingCleanup=!0,this._tryCleanup(v)}_tryCleanup(v=!1){return!(!this.pendingCleanup||Object.keys(this.intentStates).some(z=>{const f=this.intentStates[z];return 0!==f.renderTasks.length||!f.operatorList.lastChunk})||(Object.keys(this.intentStates).forEach(z=>{delete this.intentStates[z]}),this.objs.clear(),this.annotationsPromise=null,v&&this._stats&&(this._stats=new _display_utils.StatTimer),this.pendingCleanup=!1,0))}_startRenderPage(v,z){const f=this.intentStates[z];!f||(this._stats&&this._stats.timeEnd("Page Request"),f.displayReadyCapability&&f.displayReadyCapability.resolve(v))}_renderPageChunk(v,z){for(let f=0,H=v.length;f<H;f++)z.operatorList.fnArray.push(v.fnArray[f]),z.operatorList.argsArray.push(v.argsArray[f]);z.operatorList.lastChunk=v.lastChunk;for(let f=0;f<z.renderTasks.length;f++)z.renderTasks[f].operatorListChanged();v.lastChunk&&this._tryCleanup()}_pumpOperatorList(v){(0,_util.assert)(v.intent,'PDFPageProxy._pumpOperatorList: Expected "intent" argument.');const f=this._transport.messageHandler.sendWithStream("GetOperatorList",v).getReader(),H=this.intentStates[v.intent];H.streamReader=f;const N=()=>{f.read().then(({value:q,done:B})=>{B?H.streamReader=null:this._transport.destroyed||(this._renderPageChunk(q,H),N())},q=>{if(H.streamReader=null,!this._transport.destroyed){if(H.operatorList){H.operatorList.lastChunk=!0;for(let B=0;B<H.renderTasks.length;B++)H.renderTasks[B].operatorListChanged();this._tryCleanup()}if(H.displayReadyCapability)H.displayReadyCapability.reject(q);else{if(!H.opListReadCapability)throw q;H.opListReadCapability.reject(q)}}})};N()}_abortOperatorList({intentState:v,reason:z,force:f=!1}){if((0,_util.assert)(z instanceof Error||"object"==typeof z&&null!==z,'PDFPageProxy._abortOperatorList: Expected "reason" argument.'),v.streamReader){if(!f){if(0!==v.renderTasks.length)return;if(z instanceof _display_utils.RenderingCancelledException)return void(v.streamReaderCancelTimeout=setTimeout(()=>{this._abortOperatorList({intentState:v,reason:z,force:!0}),v.streamReaderCancelTimeout=null},RENDERING_CANCELLED_TIMEOUT))}v.streamReader.cancel(new _util.AbortException(z&&z.message)),v.streamReader=null,!this._transport.destroyed&&(Object.keys(this.intentStates).some(H=>this.intentStates[H]===v&&(delete this.intentStates[H],!0)),this.cleanup())}}get stats(){return this._stats}}exports.PDFPageProxy=PDFPageProxy;class LoopbackPort{constructor(v=!0){this._listeners=[],this._defer=v,this._deferred=Promise.resolve(void 0)}postMessage(v,z){if(!this._defer)return void this._listeners.forEach(q=>{q.call(this,{data:v})});const H=new WeakMap,N={data:function f(q){if("object"!=typeof q||null===q)return q;if(H.has(q))return H.get(q);let B,j;if((B=q.buffer)&&(0,_util.isArrayBuffer)(B))return j=z&&z.includes(B)?new q.constructor(B,q.byteOffset,q.byteLength):new q.constructor(q),H.set(q,j),j;j=Array.isArray(q)?[]:{},H.set(q,j);for(const k in q){let E,R=q;for(;!(E=Object.getOwnPropertyDescriptor(R,k));)R=Object.getPrototypeOf(R);if(void 0!==E.value){if("function"==typeof E.value){if(q.hasOwnProperty&&q.hasOwnProperty(k))throw new Error(`LoopbackPort.postMessage - cannot clone: ${q[k]}`);continue}j[k]=f(E.value)}}return j}(v)};this._deferred.then(()=>{this._listeners.forEach(q=>{q.call(this,N)})})}addEventListener(v,z){this._listeners.push(z)}removeEventListener(v,z){const f=this._listeners.indexOf(z);this._listeners.splice(f,1)}terminate(){this._listeners.length=0}}exports.LoopbackPort=LoopbackPort;const PDFWorker=function PDFWorkerClosure(){const pdfWorkerPorts=new WeakMap;let isWorkerDisabled=!1,fallbackWorkerSrc,nextFakeWorkerId=0,fakeWorkerCapability;if(_is_node.isNodeJS)isWorkerDisabled=!0,fallbackWorkerSrc="./pdf.worker.js";else if("object"==typeof document&&"currentScript"in document){const we=document.currentScript&&document.currentScript.src;we&&(fallbackWorkerSrc=we.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2"))}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(){let we;try{we=globalThis.pdfjsWorker&&globalThis.pdfjsWorker.WorkerMessageHandler}catch(v){}return we||null}function setupFakeWorkerGlobal(){if(fakeWorkerCapability)return fakeWorkerCapability.promise;fakeWorkerCapability=(0,_util.createPromiseCapability)();const loader=function(){var _ref2=_asyncToGenerator(function*(){const mainWorkerMessageHandler=getMainThreadWorkerMessageHandler();if(mainWorkerMessageHandler)return mainWorkerMessageHandler;if(_is_node.isNodeJS){const worker=eval("require")(getWorkerSrc());return worker.WorkerMessageHandler}return yield(0,_display_utils.loadScript)(getWorkerSrc()),window.pdfjsWorker.WorkerMessageHandler});return function we(){return _ref2.apply(this,arguments)}}();return loader().then(fakeWorkerCapability.resolve,fakeWorkerCapability.reject),fakeWorkerCapability.promise}function createCDNWrapper(we){return URL.createObjectURL(new Blob(["importScripts('"+we+"');"]))}class PDFWorker{constructor({name:v=null,port:z=null,verbosity:f=(0,_util.getVerbosityLevel)()}={}){if(z&&pdfWorkerPorts.has(z))throw new Error("Cannot use more than one PDFWorker per port");if(this.name=v,this.destroyed=!1,this.postMessageTransfers=!0,this.verbosity=f,this._readyCapability=(0,_util.createPromiseCapability)(),this._port=null,this._webWorker=null,this._messageHandler=null,z)return pdfWorkerPorts.set(z,this),void this._initializeFromPort(z);this._initialize()}get promise(){return this._readyCapability.promise}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(v){this._port=v,this._messageHandler=new _message_handler.MessageHandler("main","worker",v),this._messageHandler.on("ready",function(){}),this._readyCapability.resolve()}_initialize(){if("undefined"!=typeof Worker&&!isWorkerDisabled&&!getMainThreadWorkerMessageHandler()){let v=getWorkerSrc();try{(0,_util.isSameOrigin)(window.location.href,v)||(v=createCDNWrapper(new URL(v,window.location).href));const z=new Worker(v),f=new _message_handler.MessageHandler("main","worker",z),H=()=>{z.removeEventListener("error",N),f.destroy(),z.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},N=()=>{this._webWorker||H()};z.addEventListener("error",N),f.on("test",B=>{z.removeEventListener("error",N),this.destroyed?H():B?(this._messageHandler=f,this._port=z,this._webWorker=z,B.supportTransfers||(this.postMessageTransfers=!1),this._readyCapability.resolve(),f.send("configure",{verbosity:this.verbosity})):(this._setupFakeWorker(),f.destroy(),z.terminate())}),f.on("ready",B=>{if(z.removeEventListener("error",N),this.destroyed)H();else try{q()}catch(j){this._setupFakeWorker()}});const q=()=>{const B=new Uint8Array([this.postMessageTransfers?255:0]);try{f.send("test",B,[B.buffer])}catch(j){(0,_util.warn)("Cannot use postMessage transfers."),B[0]=0,f.send("test",B)}};return void q()}catch(z){(0,_util.info)("The worker has been disabled.")}}this._setupFakeWorker()}_setupFakeWorker(){isWorkerDisabled||((0,_util.warn)("Setting up fake worker."),isWorkerDisabled=!0),setupFakeWorkerGlobal().then(v=>{if(this.destroyed)return void this._readyCapability.reject(new Error("Worker was destroyed"));const z=new LoopbackPort;this._port=z;const f="fake"+nextFakeWorkerId++,H=new _message_handler.MessageHandler(f+"_worker",f,z);v.setup(H,z);const N=new _message_handler.MessageHandler(f,f+"_worker",z);this._messageHandler=N,this._readyCapability.resolve(),N.send("configure",{verbosity:this.verbosity})}).catch(v=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${v.message}".`))})}destroy(){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)}static fromPort(v){if(!v||!v.port)throw new Error("PDFWorker.fromPort - invalid method signature.");return pdfWorkerPorts.has(v.port)?pdfWorkerPorts.get(v.port):new PDFWorker(v)}static getWorkerSrc(){return getWorkerSrc()}}return PDFWorker}();exports.PDFWorker=PDFWorker;class WorkerTransport{constructor(v,z,f,H){this.messageHandler=v,this.loadingTask=z,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({docId:z.docId,onUnsupportedFeature:this._onUnsupportedFeature.bind(this)}),this._params=H,this.CMapReaderFactory=new H.CMapReaderFactory({baseUrl:H.cMapUrl,isCompressed:H.cMapPacked}),this.destroyed=!1,this.destroyCapability=null,this._passwordCapability=null,this._networkStream=f,this._fullReader=null,this._lastProgress=null,this.pageCache=[],this.pagePromises=[],this.downloadInfoCapability=(0,_util.createPromiseCapability)(),this.setupMessageHandler()}destroy(){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"));const v=[];this.pageCache.forEach(function(f){f&&v.push(f._destroy())}),this.pageCache.length=0,this.pagePromises.length=0;const z=this.messageHandler.sendWithPromise("Terminate",null);return v.push(z),Promise.all(v).then(()=>{this.fontLoader.clear(),this._networkStream&&this._networkStream.cancelAllRequests(new _util.AbortException("Worker was terminated.")),this.messageHandler&&(this.messageHandler.destroy(),this.messageHandler=null),this.destroyCapability.resolve()},this.destroyCapability.reject),this.destroyCapability.promise}setupMessageHandler(){const{messageHandler:v,loadingTask:z}=this;v.on("GetReader",(f,H)=>{(0,_util.assert)(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=N=>{this._lastProgress={loaded:N.loaded,total:N.total}},H.onPull=()=>{this._fullReader.read().then(function({value:N,done:q}){q?H.close():((0,_util.assert)((0,_util.isArrayBuffer)(N),"GetReader - expected an ArrayBuffer."),H.enqueue(new Uint8Array(N),1,[N]))}).catch(N=>{H.error(N)})},H.onCancel=N=>{this._fullReader.cancel(N)}}),v.on("ReaderHeadersReady",f=>{const H=(0,_util.createPromiseCapability)(),N=this._fullReader;return N.headersReady.then(()=>{(!N.isStreamingSupported||!N.isRangeSupported)&&(this._lastProgress&&z.onProgress&&z.onProgress(this._lastProgress),N.onProgress=q=>{z.onProgress&&z.onProgress({loaded:q.loaded,total:q.total})}),H.resolve({isStreamingSupported:N.isStreamingSupported,isRangeSupported:N.isRangeSupported,contentLength:N.contentLength})},H.reject),H.promise}),v.on("GetRangeReader",(f,H)=>{(0,_util.assert)(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const N=this._networkStream.getRangeReader(f.begin,f.end);N?(H.onPull=()=>{N.read().then(function({value:q,done:B}){B?H.close():((0,_util.assert)((0,_util.isArrayBuffer)(q),"GetRangeReader - expected an ArrayBuffer."),H.enqueue(new Uint8Array(q),1,[q]))}).catch(q=>{H.error(q)})},H.onCancel=q=>{N.cancel(q)}):H.close()}),v.on("GetDoc",({pdfInfo:f})=>{this._numPages=f.numPages,z._capability.resolve(new PDFDocumentProxy(f,this))}),v.on("DocException",function(f){let H;switch(f.name){case"PasswordException":H=new _util.PasswordException(f.message,f.code);break;case"InvalidPDFException":H=new _util.InvalidPDFException(f.message);break;case"MissingPDFException":H=new _util.MissingPDFException(f.message);break;case"UnexpectedResponseException":H=new _util.UnexpectedResponseException(f.message,f.status);break;case"UnknownErrorException":H=new _util.UnknownErrorException(f.message,f.details)}z._capability.reject(H)}),v.on("PasswordRequest",f=>{if(this._passwordCapability=(0,_util.createPromiseCapability)(),z.onPassword){const H=N=>{this._passwordCapability.resolve({password:N})};try{z.onPassword(H,f.code)}catch(N){this._passwordCapability.reject(N)}}else this._passwordCapability.reject(new _util.PasswordException(f.message,f.code));return this._passwordCapability.promise}),v.on("DataLoaded",f=>{z.onProgress&&z.onProgress({loaded:f.length,total:f.length}),this.downloadInfoCapability.resolve(f)}),v.on("StartRenderPage",f=>{this.destroyed||this.pageCache[f.pageIndex]._startRenderPage(f.transparency,f.intent)}),v.on("commonobj",f=>{if(this.destroyed)return;const[H,N,q]=f;if(!this.commonObjs.has(H))switch(N){case"Font":const B=this._params;if("error"in q){const E=q.error;(0,_util.warn)(`Error during font loading: ${E}`),this.commonObjs.resolve(H,E);break}let j=null;B.pdfBug&&globalThis.FontInspector&&globalThis.FontInspector.enabled&&(j={registerFont(E,R){globalThis.FontInspector.fontAdded(E,R)}});const k=new _font_loader.FontFaceObject(q,{isEvalSupported:B.isEvalSupported,disableFontFace:B.disableFontFace,ignoreErrors:B.ignoreErrors,onUnsupportedFeature:this._onUnsupportedFeature.bind(this),fontRegistry:j});this.fontLoader.bind(k).catch(E=>v.sendWithPromise("FontFallback",{id:H})).finally(()=>{!B.fontExtraProperties&&k.data&&(k.data=null),this.commonObjs.resolve(H,k)});break;case"FontPath":case"FontType3Res":case"Image":this.commonObjs.resolve(H,q);break;default:throw new Error(`Got unknown common object type ${N}`)}}),v.on("obj",f=>{if(this.destroyed)return;const[H,N,q,B]=f,j=this.pageCache[N];if(!j.objs.has(H)){if("Image"!==q)throw new Error(`Got unknown object type ${q}`);{j.objs.resolve(H,B);const k=8e6;B&&"data"in B&&B.data.length>k&&(j.cleanupAfterRender=!0)}}}),v.on("DocProgress",f=>{this.destroyed||z.onProgress&&z.onProgress({loaded:f.loaded,total:f.total})}),v.on("UnsupportedFeature",this._onUnsupportedFeature.bind(this)),v.on("FetchBuiltInCMap",(f,H)=>{if(this.destroyed)return void H.error(new Error("Worker was destroyed"));let N=!1;H.onPull=()=>{N?H.close():(N=!0,this.CMapReaderFactory.fetch(f).then(function(q){H.enqueue(q,1,[q.cMapData.buffer])}).catch(function(q){H.error(q)}))}})}_onUnsupportedFeature({featureId:v}){this.destroyed||this.loadingTask.onUnsupportedFeature&&this.loadingTask.onUnsupportedFeature(v)}getData(){return this.messageHandler.sendWithPromise("GetData",null)}getPage(v){if(!Number.isInteger(v)||v<=0||v>this._numPages)return Promise.reject(new Error("Invalid page request"));const z=v-1;if(z in this.pagePromises)return this.pagePromises[z];const f=this.messageHandler.sendWithPromise("GetPage",{pageIndex:z}).then(H=>{if(this.destroyed)throw new Error("Transport destroyed");const N=new PDFPageProxy(z,H,this,this._params.pdfBug);return this.pageCache[z]=N,N});return this.pagePromises[z]=f,f}getPageIndex(v){return this.messageHandler.sendWithPromise("GetPageIndex",{ref:v}).catch(function(z){return Promise.reject(new Error(z))})}getAnnotations(v,z){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:v,intent:z})}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(v){return"string"!=typeof v?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:v})}getPageLabels(){return this.messageHandler.sendWithPromise("GetPageLabels",null)}getPageLayout(){return this.messageHandler.sendWithPromise("GetPageLayout",null)}getPageMode(){return this.messageHandler.sendWithPromise("GetPageMode",null)}getViewerPreferences(){return this.messageHandler.sendWithPromise("GetViewerPreferences",null)}getOpenAction(){return this.messageHandler.sendWithPromise("GetOpenAction",null)}getAttachments(){return this.messageHandler.sendWithPromise("GetAttachments",null)}getJavaScript(){return this.messageHandler.sendWithPromise("GetJavaScript",null)}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){return this.messageHandler.sendWithPromise("GetMetadata",null).then(v=>({info:v[0],metadata:v[1]?new _metadata.Metadata(v[1]):null,contentDispositionFilename:this._fullReader?this._fullReader.filename:null}))}getStats(){return this.messageHandler.sendWithPromise("GetStats",null)}startCleanup(){return this.messageHandler.sendWithPromise("Cleanup",null).then(()=>{for(let v=0,z=this.pageCache.length;v<z;v++){const f=this.pageCache[v];if(f&&!f.cleanup())throw new Error(`startCleanup: Page ${v+1} is currently rendering.`)}this.commonObjs.clear(),this.fontLoader.clear()})}get loadingParams(){const v=this._params;return(0,_util.shadow)(this,"loadingParams",{disableAutoFetch:v.disableAutoFetch,disableFontFace:v.disableFontFace})}}class PDFObjects{constructor(){this._objs=Object.create(null)}_ensureObj(v){return this._objs[v]?this._objs[v]:this._objs[v]={capability:(0,_util.createPromiseCapability)(),data:null,resolved:!1}}get(v,z=null){if(z)return this._ensureObj(v).capability.promise.then(z),null;const f=this._objs[v];if(!f||!f.resolved)throw new Error(`Requesting object that isn't resolved yet ${v}.`);return f.data}has(v){const z=this._objs[v];return!!z&&z.resolved}resolve(v,z){const f=this._ensureObj(v);f.resolved=!0,f.data=z,f.capability.resolve(z)}clear(){this._objs=Object.create(null)}}class RenderTask{constructor(v){this._internalRenderTask=v,this.onContinue=null}get promise(){return this._internalRenderTask.capability.promise}cancel(){this._internalRenderTask.cancel()}}const InternalRenderTask=function we(){const v=new WeakSet;return class z{constructor({callback:H,params:N,objs:q,commonObjs:B,operatorList:j,pageIndex:k,canvasFactory:E,webGLContext:R,useRequestAnimationFrame:F=!1,pdfBug:_=!1}){this.callback=H,this.params=N,this.objs=q,this.commonObjs=B,this.operatorListIdx=null,this.operatorList=j,this._pageIndex=k,this.canvasFactory=E,this.webGLContext=R,this._pdfBug=_,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=!0===F&&"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}initializeGraphics(H=!1){if(this.cancelled)return;if(this._canvas){if(v.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.");v.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());const{canvasContext:N,viewport:q,transform:B,imageLayer:j,background:k}=this.params;this.gfx=new _canvas.CanvasGraphics(N,this.commonObjs,this.objs,this.canvasFactory,this.webGLContext,j),this.gfx.beginDrawing({transform:B,viewport:q,transparency:H,background:k}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback&&this.graphicsReadyCallback()}cancel(H=null){this.running=!1,this.cancelled=!0,this.gfx&&this.gfx.endDrawing(),this._canvas&&v.delete(this._canvas),this.callback(H||new _display_utils.RenderingCancelledException(`Rendering cancelled, page ${this._pageIndex+1}`,"canvas"))}operatorListChanged(){this.graphicsReady?(this.stepper&&this.stepper.updateOperatorList(this.operatorList),!this.running&&this._continue()):this.graphicsReadyCallback||(this.graphicsReadyCallback=this._continueBound)}_continue(){this.running=!0,!this.cancelled&&(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}_scheduleNext(){this._useRequestAnimationFrame?window.requestAnimationFrame(()=>{this._nextBound().catch(this.cancel.bind(this))}):Promise.resolve().then(this._nextBound).catch(this.cancel.bind(this))}_next(){var H=this;return _asyncToGenerator(function*(){H.cancelled||(H.operatorListIdx=H.gfx.executeOperatorList(H.operatorList,H.operatorListIdx,H._continueBound,H.stepper),H.operatorListIdx===H.operatorList.argsArray.length&&(H.running=!1,H.operatorList.lastChunk&&(H.gfx.endDrawing(),H._canvas&&v.delete(H._canvas),H.callback())))})()}}}(),version="2.5.207";exports.version=version;const build="0974d605";exports.build=build},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.FontLoader=v.FontFaceObject=void 0;var f=z(2);class H{constructor({docId:j,onUnsupportedFeature:k}){this.constructor===H&&(0,f.unreachable)("Cannot initialize BaseFontLoader."),this.docId=j,this._onUnsupportedFeature=k,this.nativeFontFaces=[],this.styleElement=null}addNativeFontFace(j){this.nativeFontFaces.push(j),document.fonts.add(j)}insertRule(j){let k=this.styleElement;k||(k=this.styleElement=document.createElement("style"),k.id=`PDFJS_FONT_STYLE_TAG_${this.docId}`,document.documentElement.getElementsByTagName("head")[0].appendChild(k));const E=k.sheet;E.insertRule(j,E.cssRules.length)}clear(){this.nativeFontFaces.forEach(function(j){document.fonts.delete(j)}),this.nativeFontFaces.length=0,this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}bind(j){var k=this;return _asyncToGenerator(function*(){if(j.attached||j.missingFile)return;if(j.attached=!0,k.isFontLoadingAPISupported){const R=j.createNativeFontFace();if(R){k.addNativeFontFace(R);try{yield R.loaded}catch(F){throw k._onUnsupportedFeature({featureId:f.UNSUPPORTED_FEATURES.errorFontLoadNative}),(0,f.warn)(`Failed to load font '${R.family}': '${F}'.`),j.disableFontFace=!0,F}}return}const E=j.createFontFaceRule();if(E){if(k.insertRule(E),k.isSyncFontLoadingSupported)return;yield new Promise(R=>{const F=k._queueLoadingCallback(R);k._prepareFontLoadEvent([E],[j],F)})}})()}_queueLoadingCallback(j){(0,f.unreachable)("Abstract method `_queueLoadingCallback`.")}get isFontLoadingAPISupported(){const j="undefined"!=typeof document&&!!document.fonts;return(0,f.shadow)(this,"isFontLoadingAPISupported",j)}get isSyncFontLoadingSupported(){(0,f.unreachable)("Abstract method `isSyncFontLoadingSupported`.")}get _loadTestFont(){(0,f.unreachable)("Abstract method `_loadTestFont`.")}_prepareFontLoadEvent(j,k,E){(0,f.unreachable)("Abstract method `_prepareFontLoadEvent`.")}}let N;v.FontLoader=N,v.FontLoader=N=class extends H{constructor(j){super(j),this.loadingContext={requests:[],nextRequestId:0},this.loadTestFontId=0}get isSyncFontLoadingSupported(){let j=!1;if("undefined"==typeof navigator)j=!0;else{const k=/Mozilla\/5.0.*?rv:(\d+).*? Gecko/.exec(navigator.userAgent);k&&k[1]>=14&&(j=!0)}return(0,f.shadow)(this,"isSyncFontLoadingSupported",j)}_queueLoadingCallback(j){const E=this.loadingContext,R={id:"pdfjs-font-loading-"+E.nextRequestId++,done:!1,complete:function k(){for((0,f.assert)(!R.done,"completeRequest() cannot be called twice."),R.done=!0;E.requests.length>0&&E.requests[0].done;){const F=E.requests.shift();setTimeout(F.callback,0)}},callback:j};return E.requests.push(R),R}get _loadTestFont(){return(0,f.shadow)(this,"_loadTestFont",atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="))}_prepareFontLoadEvent(j,k,E){function R(Z,K){return Z.charCodeAt(K)<<24|Z.charCodeAt(K+1)<<16|Z.charCodeAt(K+2)<<8|255&Z.charCodeAt(K+3)}function F(Z,K,ce,U){return Z.substring(0,K)+U+Z.substring(K+ce)}let _,b;const A=document.createElement("canvas");A.width=1,A.height=1;const x=A.getContext("2d");let M=0;const h=`lt${Date.now()}${this.loadTestFontId++}`;let p=this._loadTestFont;p=F(p,976,h.length,h);const m=1482184792;let D=R(p,16);for(_=0,b=h.length-3;_<b;_+=4)D=D-m+R(h,_)|0;_<h.length&&(D=D-m+R(h+"XXX",_)|0),p=F(p,16,4,(0,f.string32)(D));const I=`url(data:font/opentype;base64,${btoa(p)});`;this.insertRule(`@font-face {font-family:"${h}";src:${I}}`);const G=[];for(_=0,b=k.length;_<b;_++)G.push(k[_].loadedName);G.push(h);const Y=document.createElement("div");for(Y.style.visibility="hidden",Y.style.width=Y.style.height="10px",Y.style.position="absolute",Y.style.top=Y.style.left="0px",_=0,b=G.length;_<b;++_){const Z=document.createElement("span");Z.textContent="Hi",Z.style.fontFamily=G[_],Y.appendChild(Z)}document.body.appendChild(Y),function V(Z,K){if(M++,M>30)return(0,f.warn)("Load test font never loaded."),void K();x.font="30px "+Z,x.fillText(".",0,20),x.getImageData(0,0,1,1).data[3]>0?K():setTimeout(V.bind(null,Z,K))}(h,function(){document.body.removeChild(Y),E.complete()})}},v.FontFaceObject=class q{constructor(j,{isEvalSupported:k=!0,disableFontFace:E=!1,ignoreErrors:R=!1,onUnsupportedFeature:F=null,fontRegistry:_=null}){this.compiledGlyphs=Object.create(null);for(const b in j)this[b]=j[b];this.isEvalSupported=!1!==k,this.disableFontFace=!0===E,this.ignoreErrors=!0===R,this._onUnsupportedFeature=F,this.fontRegistry=_}createNativeFontFace(){if(!this.data||this.disableFontFace)return null;const j=new FontFace(this.loadedName,this.data,{});return this.fontRegistry&&this.fontRegistry.registerFont(this),j}createFontFaceRule(){if(!this.data||this.disableFontFace)return null;const j=(0,f.bytesToString)(new Uint8Array(this.data)),k=`url(data:${this.mimetype};base64,${btoa(j)});`,E=`@font-face {font-family:"${this.loadedName}";src:${k}}`;return this.fontRegistry&&this.fontRegistry.registerFont(this,k),E}getPathGenerator(j,k){if(void 0!==this.compiledGlyphs[k])return this.compiledGlyphs[k];let E,R;try{E=j.get(this.loadedName+"_path_"+k)}catch(F){if(!this.ignoreErrors)throw F;return this._onUnsupportedFeature&&this._onUnsupportedFeature({featureId:f.UNSUPPORTED_FEATURES.errorFontGetPath}),(0,f.warn)(`getPathGenerator - ignoring character: "${F}".`),this.compiledGlyphs[k]=function(_,b){}}if(this.isEvalSupported&&f.IsEvalSupportedCached.value){let F,_="";for(let b=0,A=E.length;b<A;b++)R=E[b],F=void 0!==R.args?R.args.join(","):"",_+="c."+R.cmd+"("+F+");\n";return this.compiledGlyphs[k]=new Function("c","size",_)}return this.compiledGlyphs[k]=function(F,_){for(let b=0,A=E.length;b<A;b++)R=E[b],"scale"===R.cmd&&(R.args=[_,-_]),F[R.cmd].apply(F,R.args)}}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.apiCompatibilityParams=void 0;var f=z(4);const H=Object.create(null);f.isNodeJS&&(H.disableFontFace=!0);const N=Object.freeze(H);v.apiCompatibilityParams=N},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.CanvasGraphics=void 0;var f=z(2),H=z(9),B=4096,j=.65,R=16;function F(M){M.mozCurrentTransform||(M._originalSave=M.save,M._originalRestore=M.restore,M._originalRotate=M.rotate,M._originalScale=M.scale,M._originalTranslate=M.translate,M._originalTransform=M.transform,M._originalSetTransform=M.setTransform,M._transformMatrix=M._transformMatrix||[1,0,0,1,0,0],M._transformStack=[],Object.defineProperty(M,"mozCurrentTransform",{get:function(){return this._transformMatrix}}),Object.defineProperty(M,"mozCurrentTransformInverse",{get:function(){var h=this._transformMatrix,p=h[0],c=h[1],d=h[2],m=h[3],D=h[4],I=h[5],W=p*m-c*d,G=c*d-p*m;return[m/W,c/G,d/G,p/W,(m*D-d*I)/G,(c*D-p*I)/W]}}),M.save=function(){var h=this._transformMatrix;this._transformStack.push(h),this._transformMatrix=h.slice(0,6),this._originalSave()},M.restore=function(){var h=this._transformStack.pop();h&&(this._transformMatrix=h,this._originalRestore())},M.translate=function(h,p){var c=this._transformMatrix;c[4]=c[0]*h+c[2]*p+c[4],c[5]=c[1]*h+c[3]*p+c[5],this._originalTranslate(h,p)},M.scale=function(h,p){var c=this._transformMatrix;c[0]=c[0]*h,c[1]=c[1]*h,c[2]=c[2]*p,c[3]=c[3]*p,this._originalScale(h,p)},M.transform=function(h,p,c,d,m,D){var I=this._transformMatrix;this._transformMatrix=[I[0]*h+I[2]*p,I[1]*h+I[3]*p,I[0]*c+I[2]*d,I[1]*c+I[3]*d,I[0]*m+I[2]*D+I[4],I[1]*m+I[3]*D+I[5]],M._originalTransform(h,p,c,d,m,D)},M.setTransform=function(h,p,c,d,m,D){this._transformMatrix=[h,p,c,d,m,D],M._originalSetTransform(h,p,c,d,m,D)},M.rotate=function(h){var p=Math.cos(h),c=Math.sin(h),d=this._transformMatrix;this._transformMatrix=[d[0]*p+d[2]*c,d[1]*p+d[3]*c,d[0]*-c+d[2]*p,d[1]*-c+d[3]*p,d[4],d[5]],this._originalRotate(h)})}var _=function(){function V(h){this.canvasFactory=h,this.cache=Object.create(null)}return V.prototype={getCanvas:function(p,c,d,m){var D;return void 0!==this.cache[p]?(this.canvasFactory.reset(D=this.cache[p],c,d),D.context.setTransform(1,0,0,1,0,0)):(D=this.canvasFactory.create(c,d),this.cache[p]=D),m&&F(D.context),D},clear(){for(var h in this.cache)this.canvasFactory.destroy(this.cache[h]),delete this.cache[h]}},V}(),A=function(){function V(){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=f.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=f.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=f.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}return V.prototype={clone:function(){return Object.create(this)},setCurrentPoint:function(p,c){this.x=p,this.y=c}},V}(),x=function(){function p(P,T,w,C,X,Q){this.ctx=P,this.current=new A,this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=T,this.objs=w,this.canvasFactory=C,this.webGLContext=X,this.imageLayer=Q,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.cachedCanvases=new _(this.canvasFactory),P&&F(P),this._cachedGetSinglePixelWidth=null}function c(P,T){if("undefined"!=typeof ImageData&&T instanceof ImageData)P.putImageData(T,0,0);else{var de,Ae,Ce,xe,te,w=T.height,C=T.width,X=w%R,Q=(w-X)/R,ee=0===X?Q:Q+1,re=P.createImageData(C,R),le=0,ge=T.data,pe=re.data;if(T.kind===f.ImageKind.GRAYSCALE_1BPP){var ie=ge.byteLength,ye=new Uint32Array(pe.buffer,0,pe.byteLength>>2),he=ye.length,_e=C+7>>3,be=4294967295,Se=f.IsLittleEndianCached.value?4278190080:255;for(Ae=0;Ae<ee;Ae++){for(xe=Ae<Q?R:X,de=0,Ce=0;Ce<xe;Ce++){for(var Ne=ie-le,qe=0,lt=Ne>_e?C:8*Ne-7,_t=-8&lt,Vt=0,ut=0;qe<_t;qe+=8)ut=ge[le++],ye[de++]=128&ut?be:Se,ye[de++]=64&ut?be:Se,ye[de++]=32&ut?be:Se,ye[de++]=16&ut?be:Se,ye[de++]=8&ut?be:Se,ye[de++]=4&ut?be:Se,ye[de++]=2&ut?be:Se,ye[de++]=1&ut?be:Se;for(;qe<lt;qe++)0===Vt&&(ut=ge[le++],Vt=128),ye[de++]=ut&Vt?be:Se,Vt>>=1}for(;de<he;)ye[de++]=0;P.putImageData(re,0,Ae*R)}}else if(T.kind===f.ImageKind.RGBA_32BPP){for(Ce=0,te=C*R*4,Ae=0;Ae<Q;Ae++)pe.set(ge.subarray(le,le+te)),le+=te,P.putImageData(re,0,Ce),Ce+=R;Ae<ee&&(pe.set(ge.subarray(le,le+(te=C*X*4))),P.putImageData(re,0,Ce))}else{if(T.kind!==f.ImageKind.RGB_24BPP)throw new Error(`bad image kind: ${T.kind}`);for(te=C*(xe=R),Ae=0;Ae<ee;Ae++){for(Ae>=Q&&(te=C*(xe=X)),de=0,Ce=te;Ce--;)pe[de++]=ge[le++],pe[de++]=ge[le++],pe[de++]=ge[le++],pe[de++]=255;P.putImageData(re,0,Ae*R)}}}}function d(P,T){for(var w=T.height,C=T.width,X=w%R,Q=(w-X)/R,ee=0===X?Q:Q+1,re=P.createImageData(C,R),le=0,de=T.data,ge=re.data,pe=0;pe<ee;pe++){for(var Ae=pe<Q?R:X,Ce=3,xe=0;xe<Ae;xe++)for(var te=0,ie=0;ie<C;ie++){if(!te){var ye=de[le++];te=128}ge[Ce]=ye&te?0:255,Ce+=4,te>>=1}P.putImageData(re,0,pe*R)}}function m(P,T){for(var w=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font"],C=0,X=w.length;C<X;C++){var Q=w[C];void 0!==P[Q]&&(T[Q]=P[Q])}void 0!==P.setLineDash&&(T.setLineDash(P.getLineDash()),T.lineDashOffset=P.lineDashOffset)}function D(P){P.strokeStyle="#000000",P.fillStyle="#000000",P.fillRule="nonzero",P.globalAlpha=1,P.lineWidth=1,P.lineCap="butt",P.lineJoin="miter",P.miterLimit=10,P.globalCompositeOperation="source-over",P.font="10px sans-serif",void 0!==P.setLineDash&&(P.setLineDash([]),P.lineDashOffset=0)}function I(P,T,w,C){for(var X=P.length,Q=3;Q<X;Q+=4){var ee=P[Q];if(0===ee)P[Q-3]=T,P[Q-2]=w,P[Q-1]=C;else if(ee<255){var re=255-ee;P[Q-3]=P[Q-3]*ee+T*re>>8,P[Q-2]=P[Q-2]*ee+w*re>>8,P[Q-1]=P[Q-1]*ee+C*re>>8}}}function W(P,T,w){for(var C=P.length,Q=3;Q<C;Q+=4)T[Q]=T[Q]*(w?w[P[Q]]:P[Q])*.00392156862745098|0}function G(P,T,w){for(var C=P.length,X=3;X<C;X+=4){var Q=77*P[X-3]+152*P[X-2]+28*P[X-1];T[X]=w?T[X]*w[Q>>8]>>8:T[X]*Q>>16}}function Z(P,T,w,C){var X=T.canvas,Q=T.context;P.setTransform(T.scaleX,0,0,T.scaleY,T.offsetX,T.offsetY);var ee=T.backdrop||null;if(!T.transferMap&&C.isEnabled){const re=C.composeSMask({layer:w.canvas,mask:X,properties:{subtype:T.subtype,backdrop:ee}});return P.setTransform(1,0,0,1,0,0),void P.drawImage(re,T.offsetX,T.offsetY)}(function Y(P,T,w,C,X,Q,ee){var pe,re=!!Q,le=re?Q[0]:0,de=re?Q[1]:0,ge=re?Q[2]:0;pe="Luminosity"===X?G:W;for(var Ce=Math.min(C,Math.ceil(1048576/w)),xe=0;xe<C;xe+=Ce){var te=Math.min(Ce,C-xe),ie=P.getImageData(0,xe,w,te),ye=T.getImageData(0,xe,w,te);re&&I(ie.data,le,de,ge),pe(ie.data,ye.data,ee),P.putImageData(ye,0,xe)}})(Q,w,X.width,X.height,T.subtype,ee,T.transferMap),P.drawImage(X,0,0)}var K=["butt","round","square"],ce=["miter","round","bevel"],U={},y={};for(var L in p.prototype={beginDrawing({transform:P,viewport:T,transparency:w=!1,background:C=null}){var X=this.ctx.canvas.width,Q=this.ctx.canvas.height;if(this.ctx.save(),this.ctx.fillStyle=C||"rgb(255, 255, 255)",this.ctx.fillRect(0,0,X,Q),this.ctx.restore(),w){var ee=this.cachedCanvases.getCanvas("transparent",X,Q,!0);this.compositeCtx=this.ctx,this.transparentCanvas=ee.canvas,this.ctx=ee.context,this.ctx.save(),this.ctx.transform.apply(this.ctx,this.compositeCtx.mozCurrentTransform)}this.ctx.save(),D(this.ctx),P&&this.ctx.transform.apply(this.ctx,P),this.ctx.transform.apply(this.ctx,T.transform),this.baseTransform=this.ctx.mozCurrentTransform.slice(),this.imageLayer&&this.imageLayer.beginLayout()},executeOperatorList:function(T,w,C,X){var Q=T.argsArray,ee=T.fnArray,re=w||0,le=Q.length;if(le===re)return re;for(var xe,de=le-re>10&&"function"==typeof C,ge=de?Date.now()+15:0,pe=0,Ae=this.commonObjs,Ce=this.objs;;){if(void 0!==X&&re===X.nextBreakPoint)return X.breakIt(re,C),re;if((xe=ee[re])!==f.OPS.dependency)this[xe].apply(this,Q[re]);else for(const te of Q[re]){const ie=te.startsWith("g_")?Ae:Ce;if(!ie.has(te))return ie.get(te,C),re}if(++re===le)return re;if(de&&++pe>10){if(Date.now()>ge)return C(),re;pe=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(T){this.current.lineWidth=T,this.ctx.lineWidth=T},setLineCap:function(T){this.ctx.lineCap=K[T]},setLineJoin:function(T){this.ctx.lineJoin=ce[T]},setMiterLimit:function(T){this.ctx.miterLimit=T},setDash:function(T,w){var C=this.ctx;void 0!==C.setLineDash&&(C.setLineDash(T),C.lineDashOffset=w)},setRenderingIntent(P){},setFlatness(P){},setGState:function(T){for(var w=0,C=T.length;w<C;w++){var X=T[w],ee=X[1];switch(X[0]){case"LW":this.setLineWidth(ee);break;case"LC":this.setLineCap(ee);break;case"LJ":this.setLineJoin(ee);break;case"ML":this.setMiterLimit(ee);break;case"D":this.setDash(ee[0],ee[1]);break;case"RI":this.setRenderingIntent(ee);break;case"FL":this.setFlatness(ee);break;case"Font":this.setFont(ee[0],ee[1]);break;case"CA":this.current.strokeAlpha=X[1];break;case"ca":this.current.fillAlpha=X[1],this.ctx.globalAlpha=X[1];break;case"BM":this.ctx.globalCompositeOperation=ee;break;case"SMask":this.current.activeSMask&&(this.stateStack.length>0&&this.stateStack[this.stateStack.length-1].activeSMask===this.current.activeSMask?this.suspendSMaskGroup():this.endSMaskGroup()),this.current.activeSMask=ee?this.tempSMask:null,this.current.activeSMask&&this.beginSMaskGroup(),this.tempSMask=null}}},beginSMaskGroup:function(){var T=this.current.activeSMask,Q=this.cachedCanvases.getCanvas("smaskGroupAt"+this.groupLevel,T.canvas.width,T.canvas.height,!0),ee=this.ctx,re=ee.mozCurrentTransform;this.ctx.save();var le=Q.context;le.scale(1/T.scaleX,1/T.scaleY),le.translate(-T.offsetX,-T.offsetY),le.transform.apply(le,re),T.startTransformInverse=le.mozCurrentTransformInverse,m(ee,le),this.ctx=le,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(ee),this.groupLevel++},suspendSMaskGroup:function(){var T=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),Z(this.ctx,this.current.activeSMask,T,this.webGLContext),this.ctx.restore(),this.ctx.save(),m(T,this.ctx),this.current.resumeSMaskCtx=T;var w=f.Util.transform(this.current.activeSMask.startTransformInverse,T.mozCurrentTransform);this.ctx.transform.apply(this.ctx,w),T.save(),T.setTransform(1,0,0,1,0,0),T.clearRect(0,0,T.canvas.width,T.canvas.height),T.restore()},resumeSMaskGroup:function(){var w=this.ctx;this.ctx=this.current.resumeSMaskCtx,this.groupStack.push(w),this.groupLevel++},endSMaskGroup:function(){var T=this.ctx;this.groupLevel--,this.ctx=this.groupStack.pop(),Z(this.ctx,this.current.activeSMask,T,this.webGLContext),this.ctx.restore(),m(T,this.ctx);var w=f.Util.transform(this.current.activeSMask.startTransformInverse,T.mozCurrentTransform);this.ctx.transform.apply(this.ctx,w)},save:function(){this.ctx.save();var T=this.current;this.stateStack.push(T),this.current=T.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(T,w,C,X,Q,ee){this.ctx.transform(T,w,C,X,Q,ee),this._cachedGetSinglePixelWidth=null},constructPath:function(T,w){for(var C=this.ctx,X=this.current,Q=X.x,ee=X.y,re=0,le=0,de=T.length;re<de;re++)switch(0|T[re]){case f.OPS.rectangle:Q=w[le++],ee=w[le++];var ge=w[le++],pe=w[le++];0===ge&&(ge=this.getSinglePixelWidth()),0===pe&&(pe=this.getSinglePixelWidth());var Ae=Q+ge,Ce=ee+pe;this.ctx.moveTo(Q,ee),this.ctx.lineTo(Ae,ee),this.ctx.lineTo(Ae,Ce),this.ctx.lineTo(Q,Ce),this.ctx.lineTo(Q,ee),this.ctx.closePath();break;case f.OPS.moveTo:Q=w[le++],ee=w[le++],C.moveTo(Q,ee);break;case f.OPS.lineTo:Q=w[le++],ee=w[le++],C.lineTo(Q,ee);break;case f.OPS.curveTo:C.bezierCurveTo(w[le],w[le+1],w[le+2],w[le+3],Q=w[le+4],ee=w[le+5]),le+=6;break;case f.OPS.curveTo2:C.bezierCurveTo(Q,ee,w[le],w[le+1],w[le+2],w[le+3]),Q=w[le+2],ee=w[le+3],le+=4;break;case f.OPS.curveTo3:C.bezierCurveTo(w[le],w[le+1],Q=w[le+2],ee=w[le+3],Q,ee),le+=4;break;case f.OPS.closePath:C.closePath()}X.setCurrentPoint(Q,ee)},closePath:function(){this.ctx.closePath()},stroke:function(T){T=void 0===T||T;var w=this.ctx,C=this.current.strokeColor;if(w.globalAlpha=this.current.strokeAlpha,C&&C.hasOwnProperty("type")&&"Pattern"===C.type){w.save();const Q=f.Util.singularValueDecompose2dScale(w.mozCurrentTransform)[0];w.strokeStyle=C.getPattern(w,this),w.lineWidth=Math.max(this.getSinglePixelWidth()*j,this.current.lineWidth*Q),w.stroke(),w.restore()}else w.lineWidth=Math.max(this.getSinglePixelWidth()*j,this.current.lineWidth),w.stroke();T&&this.consumePath(),w.globalAlpha=this.current.fillAlpha},closeStroke:function(){this.closePath(),this.stroke()},fill:function(T){T=void 0===T||T;var w=this.ctx,C=this.current.fillColor,Q=!1;this.current.patternFill&&(w.save(),this.baseTransform&&w.setTransform.apply(w,this.baseTransform),w.fillStyle=C.getPattern(w,this),Q=!0),this.pendingEOFill?(w.fill("evenodd"),this.pendingEOFill=!1):w.fill(),Q&&w.restore(),T&&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=U},eoClip:function(){this.pendingClip=y},beginText:function(){this.current.textMatrix=f.IDENTITY_MATRIX,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0},endText:function(){var T=this.pendingTextPaths,w=this.ctx;if(void 0!==T){w.save(),w.beginPath();for(var C=0;C<T.length;C++){var X=T[C];w.setTransform.apply(w,X.transform),w.translate(X.x,X.y),X.addToPath(w,X.fontSize)}w.restore(),w.clip(),w.beginPath(),delete this.pendingTextPaths}else w.beginPath()},setCharSpacing:function(T){this.current.charSpacing=T},setWordSpacing:function(T){this.current.wordSpacing=T},setHScale:function(T){this.current.textHScale=T/100},setLeading:function(T){this.current.leading=-T},setFont:function(T,w){var C=this.commonObjs.get(T),X=this.current;if(!C)throw new Error(`Can't find font for ${T}`);if(X.fontMatrix=C.fontMatrix?C.fontMatrix:f.FONT_IDENTITY_MATRIX,(0===X.fontMatrix[0]||0===X.fontMatrix[3])&&(0,f.warn)("Invalid font matrix for font "+T),w<0?(w=-w,X.fontDirection=-1):X.fontDirection=1,this.current.font=C,this.current.fontSize=w,C.isType3Font)return;let ee="normal";C.black?ee="900":C.bold&&(ee="bold");var re=C.italic?"italic":"normal",le=`"${C.loadedName||"sans-serif"}", ${C.fallbackName}`;let de=w;w<16?de=16:w>100&&(de=100),this.current.fontSizeScale=w/de,this.ctx.font=`${re} ${ee} ${de}px ${le}`},setTextRenderingMode:function(T){this.current.textRenderingMode=T},setTextRise:function(T){this.current.textRise=T},moveText:function(T,w){this.current.x=this.current.lineX+=T,this.current.y=this.current.lineY+=w},setLeadingMoveText:function(T,w){this.setLeading(-w),this.moveText(T,w)},setTextMatrix:function(T,w,C,X,Q,ee){this.current.textMatrix=[T,w,C,X,Q,ee],this.current.textMatrixScale=Math.sqrt(T*T+w*w),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0},nextLine:function(){this.moveText(0,this.current.leading)},paintChar(P,T,w,C){var X=this.ctx,Q=this.current,ee=Q.font,re=Q.textRenderingMode,le=Q.fontSize/Q.fontSizeScale,de=re&f.TextRenderingMode.FILL_STROKE_MASK,ge=!!(re&f.TextRenderingMode.ADD_TO_PATH_FLAG);const pe=Q.patternFill&&!ee.missingFile;var Ae;(ee.disableFontFace||ge||pe)&&(Ae=ee.getPathGenerator(this.commonObjs,P)),ee.disableFontFace||pe?(X.save(),X.translate(T,w),X.beginPath(),Ae(X,le),C&&X.setTransform.apply(X,C),(de===f.TextRenderingMode.FILL||de===f.TextRenderingMode.FILL_STROKE)&&X.fill(),(de===f.TextRenderingMode.STROKE||de===f.TextRenderingMode.FILL_STROKE)&&X.stroke(),X.restore()):((de===f.TextRenderingMode.FILL||de===f.TextRenderingMode.FILL_STROKE)&&X.fillText(P,T,w),(de===f.TextRenderingMode.STROKE||de===f.TextRenderingMode.FILL_STROKE)&&X.strokeText(P,T,w)),ge&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:X.mozCurrentTransform,x:T,y:w,fontSize:le,addToPath:Ae})},get isFontSubpixelAAEnabled(){const{context:P}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);P.scale(1.5,1),P.fillText("I",0,10);for(var T=P.getImageData(0,0,10,10).data,w=!1,C=3;C<T.length;C+=4)if(T[C]>0&&T[C]<255){w=!0;break}return(0,f.shadow)(this,"isFontSubpixelAAEnabled",w)},showText:function(T){var w=this.current,C=w.font;if(C.isType3Font)return this.showType3Text(T);var X=w.fontSize;if(0===X)return;var Q=this.ctx,ee=w.fontSizeScale,re=w.charSpacing,le=w.wordSpacing,de=w.fontDirection,ge=w.textHScale*de,pe=T.length,Ae=C.vertical,Ce=Ae?1:-1,xe=C.defaultVMetrics,te=X*w.fontMatrix[0],ie=w.textRenderingMode===f.TextRenderingMode.FILL&&!C.disableFontFace&&!w.patternFill;let ye;if(Q.save(),w.patternFill){Q.save();const gt=w.fillColor.getPattern(Q,this);ye=Q.mozCurrentTransform,Q.restore(),Q.fillStyle=gt}Q.transform.apply(Q,w.textMatrix),Q.translate(w.x,w.y+w.textRise),Q.scale(ge,de>0?-1:1);var he=w.lineWidth,_e=w.textMatrixScale;if(0===_e||0===he){var be=w.textRenderingMode&f.TextRenderingMode.FILL_STROKE_MASK;(be===f.TextRenderingMode.STROKE||be===f.TextRenderingMode.FILL_STROKE)&&(this._cachedGetSinglePixelWidth=null,he=this.getSinglePixelWidth()*j)}else he/=_e;1!==ee&&(Q.scale(ee,ee),he/=ee),Q.lineWidth=he;var Ne,Se=0;for(Ne=0;Ne<pe;++Ne){var qe=T[Ne];if((0,f.isNum)(qe))Se+=Ce*qe*X/1e3;else{var $t,Nn,ne,ae,lt=!1,_t=(qe.isSpace?le:0)+re,Vt=qe.fontChar,ut=qe.accent,ue=qe.width;if(Ae?(ne=qe.vmetric||xe,ae=qe.vmetric?ne[1]:.5*ue,ue=ne?-ne[0]:ue,$t=(ae=-ae*te)/ee,Nn=(Se+ne[2]*te)/ee):($t=Se/ee,Nn=0),C.remeasure&&ue>0){var Be=1e3*Q.measureText(Vt).width/X*ee;if(ue<Be&&this.isFontSubpixelAAEnabled){var Je=ue/Be;lt=!0,Q.save(),Q.scale(Je,1),$t/=Je}else ue!==Be&&($t+=(ue-Be)/2e3*X/ee)}(qe.isInFont||C.missingFile)&&(ie&&!ut?Q.fillText(Vt,$t,Nn):(this.paintChar(Vt,$t,Nn,ye),ut&&this.paintChar(ut.fontChar,$t+ut.offset.x/ee,Nn-ut.offset.y/ee,ye))),Se+=Ae?ue*te-_t*de:ue*te+_t*de,lt&&Q.restore()}}Ae?w.y-=Se:w.x+=Se*ge,Q.restore()},showType3Text:function(T){var xe,te,ie,ye,w=this.ctx,C=this.current,X=C.font,Q=C.fontSize,ee=C.fontDirection,re=X.vertical?1:-1,le=C.charSpacing,de=C.wordSpacing,ge=C.textHScale*ee,pe=C.fontMatrix||f.FONT_IDENTITY_MATRIX,Ae=T.length;if(C.textRenderingMode!==f.TextRenderingMode.INVISIBLE&&0!==Q){for(this._cachedGetSinglePixelWidth=null,w.save(),w.transform.apply(w,C.textMatrix),w.translate(C.x,C.y),w.scale(ge,ee),xe=0;xe<Ae;++xe)if((0,f.isNum)(te=T[xe]))this.ctx.translate(ye=re*te*Q/1e3,0),C.x+=ye*ge;else{var he=(te.isSpace?de:0)+le,_e=X.charProcOperatorList[te.operatorListId];if(_e){this.processingType3=te,this.save(),w.scale(Q,Q),w.transform.apply(w,pe),this.executeOperatorList(_e),this.restore();var be=f.Util.applyTransform([te.width,0],pe);w.translate(ie=be[0]*Q+he,0),C.x+=ie*ge}else(0,f.warn)(`Type3 character "${te.operatorListId}" is not available.`)}w.restore(),this.processingType3=null}},setCharWidth:function(T,w){},setCharWidthAndBounds:function(T,w,C,X,Q,ee){this.ctx.rect(C,X,Q-C,ee-X),this.clip(),this.endPath()},getColorN_Pattern:function(T){var w;if("TilingPattern"===T[0]){var C=T[1],X=this.baseTransform||this.ctx.mozCurrentTransform.slice();w=new H.TilingPattern(T,C,this.ctx,{createCanvasGraphics:ee=>new p(ee,this.commonObjs,this.objs,this.canvasFactory,this.webGLContext)},X)}else w=(0,H.getShadingPatternFromIR)(T);return w},setStrokeColorN:function(){this.current.strokeColor=this.getColorN_Pattern(arguments)},setFillColorN:function(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0},setStrokeRGBColor:function(T,w,C){var X=f.Util.makeCssRgb(T,w,C);this.ctx.strokeStyle=X,this.current.strokeColor=X},setFillRGBColor:function(T,w,C){var X=f.Util.makeCssRgb(T,w,C);this.ctx.fillStyle=X,this.current.fillColor=X,this.current.patternFill=!1},shadingFill:function(T){var w=this.ctx;this.save();var C=(0,H.getShadingPatternFromIR)(T);w.fillStyle=C.getPattern(w,this,!0);var X=w.mozCurrentTransformInverse;if(X){var Q=w.canvas,ee=Q.width,re=Q.height,le=f.Util.applyTransform([0,0],X),de=f.Util.applyTransform([0,re],X),ge=f.Util.applyTransform([ee,0],X),pe=f.Util.applyTransform([ee,re],X),Ae=Math.min(le[0],de[0],ge[0],pe[0]),Ce=Math.min(le[1],de[1],ge[1],pe[1]),xe=Math.max(le[0],de[0],ge[0],pe[0]),te=Math.max(le[1],de[1],ge[1],pe[1]);this.ctx.fillRect(Ae,Ce,xe-Ae,te-Ce)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.restore()},beginInlineImage:function(){(0,f.unreachable)("Should not call beginInlineImage")},beginImageData:function(){(0,f.unreachable)("Should not call beginImageData")},paintFormXObjectBegin:function(T,w){this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(T)&&6===T.length&&this.transform.apply(this,T),this.baseTransform=this.ctx.mozCurrentTransform,w&&(this.ctx.rect(w[0],w[1],w[2]-w[0],w[3]-w[1]),this.clip(),this.endPath())},paintFormXObjectEnd:function(){this.restore(),this.baseTransform=this.baseTransformStack.pop()},beginGroup:function(T){this.save();var w=this.ctx;T.isolated||(0,f.info)("TODO: Support non-isolated groups."),T.knockout&&(0,f.warn)("Knockout groups not supported.");var C=w.mozCurrentTransform;if(T.matrix&&w.transform.apply(w,T.matrix),!T.bbox)throw new Error("Bounding box is required.");var X=f.Util.getAxialAlignedBoundingBox(T.bbox,w.mozCurrentTransform);X=f.Util.intersect(X,[0,0,w.canvas.width,w.canvas.height])||[0,0,0,0];var ee=Math.floor(X[0]),re=Math.floor(X[1]),le=Math.max(Math.ceil(X[2])-ee,1),de=Math.max(Math.ceil(X[3])-re,1),ge=1,pe=1;le>B&&(ge=le/B,le=B),de>B&&(pe=de/B,de=B);var Ae="groupAt"+this.groupLevel;T.smask&&(Ae+="_smask_"+this.smaskCounter++%2);var Ce=this.cachedCanvases.getCanvas(Ae,le,de,!0),xe=Ce.context;xe.scale(1/ge,1/pe),xe.translate(-ee,-re),xe.transform.apply(xe,C),T.smask?this.smaskStack.push({canvas:Ce.canvas,context:xe,offsetX:ee,offsetY:re,scaleX:ge,scaleY:pe,subtype:T.smask.subtype,backdrop:T.smask.backdrop,transferMap:T.smask.transferMap||null,startTransformInverse:null}):(w.setTransform(1,0,0,1,0,0),w.translate(ee,re),w.scale(ge,pe)),m(w,xe),this.ctx=xe,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(w),this.groupLevel++,this.current.activeSMask=null},endGroup:function(T){this.groupLevel--;var w=this.ctx;this.ctx=this.groupStack.pop(),void 0!==this.ctx.imageSmoothingEnabled?this.ctx.imageSmoothingEnabled=!1:this.ctx.mozImageSmoothingEnabled=!1,T.smask?this.tempSMask=this.smaskStack.pop():this.ctx.drawImage(w.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(T,w,C){this.save(),D(this.ctx),this.current=new A,Array.isArray(T)&&4===T.length&&(this.ctx.rect(T[0],T[1],T[2]-T[0],T[3]-T[1]),this.clip(),this.endPath()),this.transform.apply(this,w),this.transform.apply(this,C)},endAnnotation:function(){this.restore()},paintImageMaskXObject:function(T){var w=this.ctx,C=T.width,X=T.height,Q=this.current.fillColor,ee=this.current.patternFill,re=this.processingType3;if(re&&void 0===re.compiled&&(re.compiled=C<=1e3&&X<=1e3?function b(M){var c,d,m,ce,h=M.width,p=M.height,D=h+1,I=new Uint8Array(D*(p+1)),W=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),G=h+7&-8,Y=M.data,Z=new Uint8Array(G*p),K=0;for(c=0,ce=Y.length;c<ce;c++)for(var U=128,y=Y[c];U>0;)Z[K++]=y&U?0:255,U>>=1;var L=0;for(0!==Z[K=0]&&(I[0]=1,++L),d=1;d<h;d++)Z[K]!==Z[K+1]&&(I[d]=Z[K]?2:1,++L),K++;for(0!==Z[K]&&(I[d]=2,++L),c=1;c<p;c++){m=c*D,Z[(K=c*G)-G]!==Z[K]&&(I[m]=Z[K]?1:8,++L);var P=(Z[K]?4:0)+(Z[K-G]?8:0);for(d=1;d<h;d++)W[P=(P>>2)+(Z[K+1]?4:0)+(Z[K-G+1]?8:0)]&&(I[m+d]=W[P],++L),K++;if(Z[K-G]!==Z[K]&&(I[m+d]=Z[K]?2:4,++L),L>1e3)return null}for(m=c*D,0!==Z[K=G*(p-1)]&&(I[m]=8,++L),d=1;d<h;d++)Z[K]!==Z[K+1]&&(I[m+d]=Z[K]?4:8,++L),K++;if(0!==Z[K]&&(I[m+d]=4,++L),L>1e3)return null;var T=new Int32Array([0,D,-1,0,-D,0,0,0,1]),w=[];for(c=0;L&&c<=p;c++){for(var C=c*D,X=C+h;C<X&&!I[C];)C++;if(C!==X){var le,Q=[C%D,c],ee=I[C],re=C;do{var de=T[ee];do{C+=de}while(!I[C]);5!==(le=I[C])&&10!==le?(ee=le,I[C]=0):I[C]&=(ee=le&51*ee>>4)>>2|ee<<2,Q.push(C%D),Q.push(C/D|0),I[C]||--L}while(re!==C);w.push(Q),--c}}return function(pe){pe.save(),pe.scale(1/h,-1/p),pe.translate(0,-p),pe.beginPath();for(let Ce=0,xe=w.length;Ce<xe;Ce++){var Ae=w[Ce];pe.moveTo(Ae[0],Ae[1]);for(let te=2,ie=Ae.length;te<ie;te+=2)pe.lineTo(Ae[te],Ae[te+1])}pe.fill(),pe.beginPath(),pe.restore()}}({data:T.data,width:C,height:X}):null),re&&re.compiled)re.compiled(w);else{var le=this.cachedCanvases.getCanvas("maskCanvas",C,X),de=le.context;de.save(),d(de,T),de.globalCompositeOperation="source-in",de.fillStyle=ee?Q.getPattern(de,this):Q,de.fillRect(0,0,C,X),de.restore(),this.paintInlineImageXObject(le.canvas)}},paintImageMaskXObjectRepeat:function(T,w,C,X){var Q=T.width,ee=T.height,re=this.current.fillColor,le=this.current.patternFill,de=this.cachedCanvases.getCanvas("maskCanvas",Q,ee),ge=de.context;ge.save(),d(ge,T),ge.globalCompositeOperation="source-in",ge.fillStyle=le?re.getPattern(ge,this):re,ge.fillRect(0,0,Q,ee),ge.restore();for(var pe=this.ctx,Ae=0,Ce=X.length;Ae<Ce;Ae+=2)pe.save(),pe.transform(w,0,0,C,X[Ae],X[Ae+1]),pe.scale(1,-1),pe.drawImage(de.canvas,0,0,Q,ee,0,-1,1,1),pe.restore()},paintImageMaskXObjectGroup:function(T){for(var w=this.ctx,C=this.current.fillColor,X=this.current.patternFill,Q=0,ee=T.length;Q<ee;Q++){var re=T[Q],le=re.width,de=re.height,ge=this.cachedCanvases.getCanvas("maskCanvas",le,de),pe=ge.context;pe.save(),d(pe,re),pe.globalCompositeOperation="source-in",pe.fillStyle=X?C.getPattern(pe,this):C,pe.fillRect(0,0,le,de),pe.restore(),w.save(),w.transform.apply(w,re.transform),w.scale(1,-1),w.drawImage(ge.canvas,0,0,le,de,0,-1,1,1),w.restore()}},paintImageXObject:function(T){const w=T.startsWith("g_")?this.commonObjs.get(T):this.objs.get(T);w?this.paintInlineImageXObject(w):(0,f.warn)("Dependent image isn't ready yet")},paintImageXObjectRepeat:function(T,w,C,X){const Q=T.startsWith("g_")?this.commonObjs.get(T):this.objs.get(T);if(Q){for(var ee=Q.width,re=Q.height,le=[],de=0,ge=X.length;de<ge;de+=2)le.push({transform:[w,0,0,C,X[de],X[de+1]],x:0,y:0,w:ee,h:re});this.paintInlineImageXObjectGroup(Q,le)}else(0,f.warn)("Dependent image isn't ready yet")},paintInlineImageXObject:function(T){var w=T.width,C=T.height,X=this.ctx;this.save(),X.scale(1/w,-1/C);var Ae,Ce,Q=X.mozCurrentTransformInverse,ee=Q[0],re=Q[1],le=Math.max(Math.sqrt(ee*ee+re*re),1),de=Q[2],ge=Q[3],pe=Math.max(Math.sqrt(de*de+ge*ge),1);if("function"==typeof HTMLElement&&T instanceof HTMLElement||!T.data)Ae=T;else{var xe=(Ce=this.cachedCanvases.getCanvas("inlineImage",w,C)).context;c(xe,T),Ae=Ce.canvas}for(var te=w,ie=C,ye="prescale1";le>2&&te>1||pe>2&&ie>1;){var he=te,_e=ie;le>2&&te>1&&(le/=te/(he=Math.ceil(te/2))),pe>2&&ie>1&&(pe/=ie/(_e=Math.ceil(ie/2))),(xe=(Ce=this.cachedCanvases.getCanvas(ye,he,_e)).context).clearRect(0,0,he,_e),xe.drawImage(Ae,0,0,te,ie,0,0,he,_e),Ae=Ce.canvas,te=he,ie=_e,ye="prescale1"===ye?"prescale2":"prescale1"}if(X.drawImage(Ae,0,0,te,ie,0,-C,w,C),this.imageLayer){var be=this.getCanvasPosition(0,-C);this.imageLayer.appendImage({imgData:T,left:be[0],top:be[1],width:w/Q[0],height:C/Q[3]})}this.restore()},paintInlineImageXObjectGroup:function(T,w){var C=this.ctx,X=T.width,Q=T.height,ee=this.cachedCanvases.getCanvas("inlineImage",X,Q);c(ee.context,T);for(var le=0,de=w.length;le<de;le++){var ge=w[le];if(C.save(),C.transform.apply(C,ge.transform),C.scale(1,-1),C.drawImage(ee.canvas,ge.x,ge.y,ge.w,ge.h,0,-1,1,1),this.imageLayer){var pe=this.getCanvasPosition(ge.x,ge.y);this.imageLayer.appendImage({imgData:T,left:pe[0],top:pe[1],width:X,height:Q})}C.restore()}},paintSolidColorImageMask:function(){this.ctx.fillRect(0,0,1,1)},paintXObject:function(){(0,f.warn)("Unsupported 'paintXObject' command.")},markPoint:function(T){},markPointProps:function(T,w){},beginMarkedContent:function(T){},beginMarkedContentProps:function(T,w){},endMarkedContent:function(){},beginCompat:function(){},endCompat:function(){},consumePath:function(){var T=this.ctx;this.pendingClip&&(this.pendingClip===y?T.clip("evenodd"):T.clip(),this.pendingClip=null),T.beginPath()},getSinglePixelWidth(P){if(null===this._cachedGetSinglePixelWidth){const 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]))}return this._cachedGetSinglePixelWidth},getCanvasPosition:function(T,w){var C=this.ctx.mozCurrentTransform;return[C[0]*T+C[2]*w+C[4],C[1]*T+C[3]*w+C[5]]}},f.OPS)p.prototype[f.OPS[L]]=p.prototype[L];return p}();v.CanvasGraphics=x},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.getShadingPatternFromIR=function B(k){var E=H[k[0]];if(!E)throw new Error(`Unknown IR type: ${k[0]}`);return E.fromIR(k)},v.TilingPattern=void 0;var f=z(2),H={};function N(k,E){if(!E||"undefined"==typeof Path2D)return;const R=E[2]-E[0],F=E[3]-E[1],_=new Path2D;_.rect(E[0],E[1],R,F),k.clip(_)}H.RadialAxial={fromIR:function(E){var R=E[1],F=E[2],_=E[3],b=E[4],A=E[5],x=E[6],M=E[7];return{type:"Pattern",getPattern:function(h){var p;N(h,F),"axial"===R?p=h.createLinearGradient(b[0],b[1],A[0],A[1]):"radial"===R&&(p=h.createRadialGradient(b[0],b[1],x,A[0],A[1],M));for(var c=0,d=_.length;c<d;++c){var m=_[c];p.addColorStop(m[0],m[1])}return p}}}};var q=function(){function E(_,b,A,x,M,V,h,p){var I,c=b.coords,d=b.colors,m=_.data,D=4*_.width;c[A+1]>c[x+1]&&(I=A,A=x,x=I,I=V,V=h,h=I),c[x+1]>c[M+1]&&(I=x,x=M,M=I,I=h,h=p,p=I),c[A+1]>c[x+1]&&(I=A,A=x,x=I,I=V,V=h,h=I);var W=(c[A]+b.offsetX)*b.scaleX,G=(c[A+1]+b.offsetY)*b.scaleY,Y=(c[x]+b.offsetX)*b.scaleX,Z=(c[x+1]+b.offsetY)*b.scaleY,K=(c[M]+b.offsetX)*b.scaleX,ce=(c[M+1]+b.offsetY)*b.scaleY;if(!(G>=ce))for(var le,de,ge,pe,Ae,Ce,xe,te,U=d[V],y=d[V+1],L=d[V+2],P=d[h],T=d[h+1],w=d[h+2],C=d[p],X=d[p+1],Q=d[p+2],ee=Math.round(G),re=Math.round(ce),ie=ee;ie<=re;ie++){if(ie<Z){let Ne;Ne=ie<G?0:G===Z?1:(G-ie)/(G-Z),le=W-(W-Y)*Ne,de=U-(U-P)*Ne,ge=y-(y-T)*Ne,pe=L-(L-w)*Ne}else{let Ne;Ne=ie>ce?1:Z===ce?0:(Z-ie)/(Z-ce),le=Y-(Y-K)*Ne,de=P-(P-C)*Ne,ge=T-(T-X)*Ne,pe=w-(w-Q)*Ne}let Se;Se=ie<G?0:ie>ce?1:(G-ie)/(G-ce),Ae=W-(W-K)*Se,Ce=U-(U-C)*Se,xe=y-(y-X)*Se,te=L-(L-Q)*Se;for(var ye=Math.round(Math.min(le,Ae)),he=Math.round(Math.max(le,Ae)),_e=D*ie+4*ye,be=ye;be<=he;be++)Se=(le-be)/(le-Ae),Se<0?Se=0:Se>1&&(Se=1),m[_e++]=de-(de-Ce)*Se|0,m[_e++]=ge-(ge-xe)*Se|0,m[_e++]=pe-(pe-te)*Se|0,m[_e++]=255}}function R(_,b,A){var V,h,x=b.coords,M=b.colors;switch(b.type){case"lattice":var p=b.verticesPerRow,c=Math.floor(x.length/p)-1,d=p-1;for(V=0;V<c;V++)for(var m=V*p,D=0;D<d;D++,m++)E(_,A,x[m],x[m+1],x[m+p],M[m],M[m+1],M[m+p]),E(_,A,x[m+p+1],x[m+1],x[m+p],M[m+p+1],M[m+1],M[m+p]);break;case"triangles":for(V=0,h=x.length;V<h;V+=3)E(_,A,x[V],x[V+1],x[V+2],M[V],M[V+1],M[V+2]);break;default:throw new Error("illegal figure")}}return function F(_,b,A,x,M,V,h,p){var P,T,w,C,D=Math.floor(_[0]),I=Math.floor(_[1]),W=Math.ceil(_[2])-D,G=Math.ceil(_[3])-I,Y=Math.min(Math.ceil(Math.abs(W*b[0]*1.1)),3e3),Z=Math.min(Math.ceil(Math.abs(G*b[1]*1.1)),3e3),K=W/Y,ce=G/Z,U={coords:A,colors:x,offsetX:-D,offsetY:-I,scaleX:1/K,scaleY:1/ce},y=Y+4,L=Z+4;if(p.isEnabled)P=p.drawFigures({width:Y,height:Z,backgroundColor:V,figures:M,context:U}),(T=h.getCanvas("mesh",y,L,!1)).context.drawImage(P,2,2),P=T.canvas;else{var X=(T=h.getCanvas("mesh",y,L,!1)).context,Q=X.createImageData(Y,Z);if(V){var ee=Q.data;for(w=0,C=ee.length;w<C;w+=4)ee[w]=V[0],ee[w+1]=V[1],ee[w+2]=V[2],ee[w+3]=255}for(w=0;w<M.length;w++)R(Q,M[w],U);X.putImageData(Q,2,2),P=T.canvas}return{canvas:P,offsetX:D-2*K,offsetY:I-2*ce,scaleX:K,scaleY:ce}}}();H.Mesh={fromIR:function(E){var R=E[2],F=E[3],_=E[4],b=E[5],A=E[6],x=E[7],M=E[8];return{type:"Pattern",getPattern:function(h,p,c){var d;if(N(h,x),c)d=f.Util.singularValueDecompose2dScale(h.mozCurrentTransform);else if(d=f.Util.singularValueDecompose2dScale(p.baseTransform),A){var m=f.Util.singularValueDecompose2dScale(A);d=[d[0]*m[0],d[1]*m[1]]}var D=q(b,d,R,F,_,c?null:M,p.cachedCanvases,p.webGLContext);return c||(h.setTransform.apply(h,p.baseTransform),A&&h.transform.apply(h,A)),h.translate(D.offsetX,D.offsetY),h.scale(D.scaleX,D.scaleY),h.createPattern(D.canvas,"no-repeat")}}}},H.Dummy={fromIR:function(){return{type:"Pattern",getPattern:function(){return"hotpink"}}}};var j=function(){function F(_,b,A,x,M){this.operatorList=_[2],this.matrix=_[3]||[1,0,0,1,0,0],this.bbox=_[4],this.xstep=_[5],this.ystep=_[6],this.paintType=_[7],this.tilingType=_[8],this.color=b,this.canvasGraphicsFactory=x,this.baseTransform=M,this.type="Pattern",this.ctx=A}return F.prototype={createPatternCanvas:function(b){var A=this.operatorList,x=this.bbox,M=this.xstep,V=this.ystep,h=this.paintType,c=this.color,d=this.canvasGraphicsFactory;(0,f.info)("TilingType: "+this.tilingType);var m=x[0],D=x[1],I=x[2],W=x[3],G=f.Util.singularValueDecompose2dScale(this.matrix),Y=f.Util.singularValueDecompose2dScale(this.baseTransform),Z=[G[0]*Y[0],G[1]*Y[1]],K=this.getSizeAndScale(M,this.ctx.canvas.width,Z[0]),ce=this.getSizeAndScale(V,this.ctx.canvas.height,Z[1]),U=b.cachedCanvases.getCanvas("pattern",K.size,ce.size,!0),L=d.createCanvasGraphics(U.context);return L.groupLevel=b.groupLevel,this.setFillAndStrokeStyleToContext(L,h,c),L.transform(K.scale,0,0,ce.scale,0,0),L.transform(1,0,0,1,-m,-D),this.clipBbox(L,x,m,D,I,W),L.executeOperatorList(A),this.ctx.transform(1,0,0,1,m,D),this.ctx.scale(1/K.scale,1/ce.scale),U.canvas},getSizeAndScale:function(b,A,x){b=Math.abs(b);var M=Math.max(3e3,A),V=Math.ceil(b*x);return V>=M?V=M:x=V/b,{scale:x,size:V}},clipBbox:function(b,A,x,M,V,h){Array.isArray(A)&&4===A.length&&(b.ctx.rect(x,M,V-x,h-M),b.clip(),b.endPath())},setFillAndStrokeStyleToContext:function(b,A,x){const M=b.ctx,V=b.current;switch(A){case 1:var h=this.ctx;M.fillStyle=h.fillStyle,M.strokeStyle=h.strokeStyle,V.fillColor=h.fillStyle,V.strokeColor=h.strokeStyle;break;case 2:var p=f.Util.makeCssRgb(x[0],x[1],x[2]);M.fillStyle=p,M.strokeStyle=p,V.fillColor=p,V.strokeColor=p;break;default:throw new f.FormatError(`Unsupported paint type: ${A}`)}},getPattern:function(b,A){(b=this.ctx).setTransform.apply(b,this.baseTransform),b.transform.apply(b,this.matrix);var x=this.createPatternCanvas(A);return b.createPattern(x,"repeat")}},F}();v.TilingPattern=j},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.GlobalWorkerOptions=void 0;const f=Object.create(null);v.GlobalWorkerOptions=f,f.workerPort=void 0===f.workerPort?null:f.workerPort,f.workerSrc=void 0===f.workerSrc?"":f.workerSrc},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.MessageHandler=void 0;var f=z(2);function q(j){if("object"!=typeof j||null===j)return j;switch(j.name){case"AbortException":return new f.AbortException(j.message);case"MissingPDFException":return new f.MissingPDFException(j.message);case"UnexpectedResponseException":return new f.UnexpectedResponseException(j.message,j.status);case"UnknownErrorException":return new f.UnknownErrorException(j.message,j.details);default:return new f.UnknownErrorException(j.message,j.toString())}}v.MessageHandler=class B{constructor(k,E,R){this.sourceName=k,this.targetName=E,this.comObj=R,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=F=>{const _=F.data;if(_.targetName!==this.sourceName)return;if(_.stream)return void this._processStreamMessage(_);if(_.callback){const A=_.callbackId,x=this.callbackCapabilities[A];if(!x)throw new Error(`Cannot resolve callback ${A}`);if(delete this.callbackCapabilities[A],1===_.callback)x.resolve(_.data);else{if(2!==_.callback)throw new Error("Unexpected callback case");x.reject(q(_.reason))}return}const b=this.actionHandler[_.action];if(!b)throw new Error(`Unknown action from worker: ${_.action}`);if(_.callbackId){const A=this.sourceName,x=_.sourceName;new Promise(function(M){M(b(_.data))}).then(function(M){R.postMessage({sourceName:A,targetName:x,callback:1,callbackId:_.callbackId,data:M})},function(M){R.postMessage({sourceName:A,targetName:x,callback:2,callbackId:_.callbackId,reason:q(M)})})}else _.streamId?this._createStreamSink(_):b(_.data)},R.addEventListener("message",this._onComObjOnMessage)}on(k,E){const R=this.actionHandler;if(R[k])throw new Error(`There is already an actionName called "${k}"`);R[k]=E}send(k,E,R){this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:k,data:E},R)}sendWithPromise(k,E,R){const F=this.callbackId++,_=(0,f.createPromiseCapability)();this.callbackCapabilities[F]=_;try{this._postMessage({sourceName:this.sourceName,targetName:this.targetName,action:k,callbackId:F,data:E},R)}catch(b){_.reject(b)}return _.promise}sendWithStream(k,E,R,F){const _=this.streamId++,b=this.sourceName,A=this.targetName,x=this.comObj;return new ReadableStream({start:M=>{const V=(0,f.createPromiseCapability)();return this.streamControllers[_]={controller:M,startCall:V,pullCall:null,cancelCall:null,isClosed:!1},this._postMessage({sourceName:b,targetName:A,action:k,streamId:_,data:E,desiredSize:M.desiredSize},F),V.promise},pull:M=>{const V=(0,f.createPromiseCapability)();return this.streamControllers[_].pullCall=V,x.postMessage({sourceName:b,targetName:A,stream:6,streamId:_,desiredSize:M.desiredSize}),V.promise},cancel:M=>{(0,f.assert)(M instanceof Error,"cancel must have a valid reason");const V=(0,f.createPromiseCapability)();return this.streamControllers[_].cancelCall=V,this.streamControllers[_].isClosed=!0,x.postMessage({sourceName:b,targetName:A,stream:1,streamId:_,reason:q(M)}),V.promise}},R)}_createStreamSink(k){const E=this,R=this.actionHandler[k.action],F=k.streamId,_=this.sourceName,b=k.sourceName,A=this.comObj,x={enqueue(M,V=1,h){if(this.isCancelled)return;const p=this.desiredSize;this.desiredSize-=V,p>0&&this.desiredSize<=0&&(this.sinkCapability=(0,f.createPromiseCapability)(),this.ready=this.sinkCapability.promise),E._postMessage({sourceName:_,targetName:b,stream:4,streamId:F,chunk:M},h)},close(){this.isCancelled||(this.isCancelled=!0,A.postMessage({sourceName:_,targetName:b,stream:3,streamId:F}),delete E.streamSinks[F])},error(M){(0,f.assert)(M instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,A.postMessage({sourceName:_,targetName:b,stream:5,streamId:F,reason:q(M)}))},sinkCapability:(0,f.createPromiseCapability)(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:k.desiredSize,ready:null};x.sinkCapability.resolve(),x.ready=x.sinkCapability.promise,this.streamSinks[F]=x,new Promise(function(M){M(R(k.data,x))}).then(function(){A.postMessage({sourceName:_,targetName:b,stream:8,streamId:F,success:!0})},function(M){A.postMessage({sourceName:_,targetName:b,stream:8,streamId:F,reason:q(M)})})}_processStreamMessage(k){const E=k.streamId,R=this.sourceName,F=k.sourceName,_=this.comObj;switch(k.stream){case 8:k.success?this.streamControllers[E].startCall.resolve():this.streamControllers[E].startCall.reject(q(k.reason));break;case 7:k.success?this.streamControllers[E].pullCall.resolve():this.streamControllers[E].pullCall.reject(q(k.reason));break;case 6:if(!this.streamSinks[E]){_.postMessage({sourceName:R,targetName:F,stream:7,streamId:E,success:!0});break}this.streamSinks[E].desiredSize<=0&&k.desiredSize>0&&this.streamSinks[E].sinkCapability.resolve(),this.streamSinks[E].desiredSize=k.desiredSize;const{onPull:b}=this.streamSinks[k.streamId];new Promise(function(x){x(b&&b())}).then(function(){_.postMessage({sourceName:R,targetName:F,stream:7,streamId:E,success:!0})},function(x){_.postMessage({sourceName:R,targetName:F,stream:7,streamId:E,reason:q(x)})});break;case 4:if((0,f.assert)(this.streamControllers[E],"enqueue should have stream controller"),this.streamControllers[E].isClosed)break;this.streamControllers[E].controller.enqueue(k.chunk);break;case 3:if((0,f.assert)(this.streamControllers[E],"close should have stream controller"),this.streamControllers[E].isClosed)break;this.streamControllers[E].isClosed=!0,this.streamControllers[E].controller.close(),this._deleteStreamController(E);break;case 5:(0,f.assert)(this.streamControllers[E],"error should have stream controller"),this.streamControllers[E].controller.error(q(k.reason)),this._deleteStreamController(E);break;case 2:k.success?this.streamControllers[E].cancelCall.resolve():this.streamControllers[E].cancelCall.reject(q(k.reason)),this._deleteStreamController(E);break;case 1:if(!this.streamSinks[E])break;const{onCancel:A}=this.streamSinks[k.streamId];new Promise(function(x){x(A&&A(q(k.reason)))}).then(function(){_.postMessage({sourceName:R,targetName:F,stream:2,streamId:E,success:!0})},function(x){_.postMessage({sourceName:R,targetName:F,stream:2,streamId:E,reason:q(x)})}),this.streamSinks[E].sinkCapability.reject(q(k.reason)),this.streamSinks[E].isCancelled=!0,delete this.streamSinks[E];break;default:throw new Error("Unexpected stream case")}}_deleteStreamController(k){var E=this;return _asyncToGenerator(function*(){yield Promise.allSettled([E.streamControllers[k].startCall,E.streamControllers[k].pullCall,E.streamControllers[k].cancelCall].map(function(R){return R&&R.promise})),delete E.streamControllers[k]})()}_postMessage(k,E){E&&this.postMessageTransfers?this.comObj.postMessage(k,E):this.comObj.postMessage(k)}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.Metadata=void 0;var f=z(2),H=z(13);v.Metadata=class N{constructor(B){(0,f.assert)("string"==typeof B,"Metadata: input is not a string"),B=this._repair(B);const k=(new H.SimpleXMLParser).parseFromString(B);this._metadataMap=new Map,k&&this._parse(k)}_repair(B){return B.replace(/^[^<]+/,"").replace(/>\\376\\377([^<]+)/g,function(j,k){const E=k.replace(/\\([0-3])([0-7])([0-7])/g,function(F,_,b,A){return String.fromCharCode(64*_+8*b+1*A)}).replace(/&(amp|apos|gt|lt|quot);/g,function(F,_){switch(_){case"amp":return"&";case"apos":return"'";case"gt":return">";case"lt":return"<";case"quot":return'"'}throw new Error(`_repair: ${_} isn't defined.`)});let R="";for(let F=0,_=E.length;F<_;F+=2){const b=256*E.charCodeAt(F)+E.charCodeAt(F+1);R+=b>=32&&b<127&&60!==b&&62!==b&&38!==b?String.fromCharCode(b):"&#x"+(65536+b).toString(16).substring(1)+";"}return">"+R})}_parse(B){let j=B.documentElement;if("rdf:rdf"!==j.nodeName.toLowerCase())for(j=j.firstChild;j&&"rdf:rdf"!==j.nodeName.toLowerCase();)j=j.nextSibling;const k=j?j.nodeName.toLowerCase():null;if(!j||"rdf:rdf"!==k||!j.hasChildNodes())return;const E=j.childNodes;for(let R=0,F=E.length;R<F;R++){const _=E[R];if("rdf:description"===_.nodeName.toLowerCase())for(let b=0,A=_.childNodes.length;b<A;b++)if("#text"!==_.childNodes[b].nodeName.toLowerCase()){const x=_.childNodes[b],M=x.nodeName.toLowerCase();this._metadataMap.set(M,x.textContent.trim())}}}get(B){return this._metadataMap.has(B)?this._metadataMap.get(B):null}getAll(){const B=Object.create(null);for(const[j,k]of this._metadataMap)B[j]=k;return B}has(B){return this._metadataMap.has(B)}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.SimpleXMLParser=void 0;function H(k,E){const R=k[E];return" "===R||"\n"===R||"\r"===R||"\t"===R}class B{constructor(E,R){this.nodeName=E,this.nodeValue=R,Object.defineProperty(this,"parentNode",{value:null,writable:!0})}get firstChild(){return this.childNodes&&this.childNodes[0]}get nextSibling(){const E=this.parentNode.childNodes;if(!E)return;const R=E.indexOf(this);return-1!==R?E[R+1]:void 0}get textContent(){return this.childNodes?this.childNodes.map(function(E){return E.textContent}).join(""):this.nodeValue||""}hasChildNodes(){return this.childNodes&&this.childNodes.length>0}}v.SimpleXMLParser=class j extends class q{_resolveEntities(E){return E.replace(/&([^;]+);/g,(R,F)=>{if("#x"===F.substring(0,2))return String.fromCharCode(parseInt(F.substring(2),16));if("#"===F.substring(0,1))return String.fromCharCode(parseInt(F.substring(1),10));switch(F){case"lt":return"<";case"gt":return">";case"amp":return"&";case"quot":return'"'}return this.onResolveEntity(F)})}_parseContent(E,R){const F=[];let _=R;function b(){for(;_<E.length&&H(E,_);)++_}for(;_<E.length&&!H(E,_)&&">"!==E[_]&&"/"!==E[_];)++_;const A=E.substring(R,_);for(b();_<E.length&&">"!==E[_]&&"/"!==E[_]&&"?"!==E[_];){b();let x="",M="";for(;_<E.length&&!H(E,_)&&"="!==E[_];)x+=E[_],++_;if(b(),"="!==E[_])return null;++_,b();const V=E[_];if('"'!==V&&"'"!==V)return null;const h=E.indexOf(V,++_);if(h<0)return null;M=E.substring(_,h),F.push({name:x,value:this._resolveEntities(M)}),_=h+1,b()}return{name:A,attributes:F,parsed:_-R}}_parseProcessingInstruction(E,R){let F=R;for(;F<E.length&&!H(E,F)&&">"!==E[F]&&"/"!==E[F];)++F;const b=E.substring(R,F);!function _(){for(;F<E.length&&H(E,F);)++F}();const A=F;for(;F<E.length&&("?"!==E[F]||">"!==E[F+1]);)++F;return{name:b,value:E.substring(A,F),parsed:F-R}}parseXml(E){let R=0;for(;R<E.length;){let _=R;if("<"===E[R]){let A;switch(++_,E[_]){case"/":if(++_,A=E.indexOf(">",_),A<0)return void this.onError(-9);this.onEndElement(E.substring(_,A)),_=A+1;break;case"?":++_;const x=this._parseProcessingInstruction(E,_);if("?>"!==E.substring(_+x.parsed,_+x.parsed+2))return void this.onError(-3);this.onPi(x.name,x.value),_+=x.parsed+2;break;case"!":if("--"===E.substring(_+1,_+3)){if(A=E.indexOf("--\x3e",_+3),A<0)return void this.onError(-5);this.onComment(E.substring(_+3,A)),_=A+3}else if("[CDATA["===E.substring(_+1,_+8)){if(A=E.indexOf("]]>",_+8),A<0)return void this.onError(-2);this.onCdata(E.substring(_+8,A)),_=A+3}else{if("DOCTYPE"!==E.substring(_+1,_+8))return void this.onError(-6);{const h=E.indexOf("[",_+8);let p=!1;if(A=E.indexOf(">",_+8),A<0)return void this.onError(-4);if(h>0&&A>h){if(A=E.indexOf("]>",_+8),A<0)return void this.onError(-4);p=!0}const c=E.substring(_+8,A+(p?1:0));this.onDoctype(c),_=A+(p?2:1)}}break;default:const M=this._parseContent(E,_);if(null===M)return void this.onError(-6);let V=!1;if("/>"===E.substring(_+M.parsed,_+M.parsed+2))V=!0;else if(">"!==E.substring(_+M.parsed,_+M.parsed+1))return void this.onError(-9);this.onBeginElement(M.name,M.attributes,V),_+=M.parsed+(V?2:1)}}else{for(;_<E.length&&"<"!==E[_];)_++;const b=E.substring(R,_);this.onText(this._resolveEntities(b))}R=_}}onResolveEntity(E){return`&${E};`}onPi(E,R){}onComment(E){}onCdata(E){}onDoctype(E){}onText(E){}onBeginElement(E,R,F){}onEndElement(E){}onError(E){}}{constructor(){super(),this._currentFragment=null,this._stack=null,this._errorCode=0}parseFromString(E){if(this._currentFragment=[],this._stack=[],this._errorCode=0,this.parseXml(E),0!==this._errorCode)return;const[R]=this._currentFragment;return R?{documentElement:R}:void 0}onResolveEntity(E){return"apos"===E?"'":super.onResolveEntity(E)}onText(E){if(function N(k){for(let E=0,R=k.length;E<R;E++)if(!H(k,E))return!1;return!0}(E))return;const R=new B("#text",E);this._currentFragment.push(R)}onCdata(E){const R=new B("#text",E);this._currentFragment.push(R)}onBeginElement(E,R,F){const _=new B(E);_.childNodes=[],this._currentFragment.push(_),!F&&(this._stack.push(this._currentFragment),this._currentFragment=_.childNodes)}onEndElement(E){this._currentFragment=this._stack.pop()||[];const R=this._currentFragment[this._currentFragment.length-1];if(R)for(let F=0,_=R.childNodes.length;F<_;F++)R.childNodes[F].parentNode=R}onError(E){this._errorCode=E}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.PDFDataTransportStream=void 0;var f=z(2);v.PDFDataTransportStream=class H{constructor(j,k){(0,f.assert)(k,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=j.progressiveDone||!1;const E=j.initialData;if(E&&E.length>0){const R=new Uint8Array(E).buffer;this._queuedChunks.push(R)}this._pdfDataRangeTransport=k,this._isStreamingSupported=!j.disableStream,this._isRangeSupported=!j.disableRange,this._contentLength=j.length,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((R,F)=>{this._onReceiveData({begin:R,chunk:F})}),this._pdfDataRangeTransport.addProgressListener((R,F)=>{this._onProgress({loaded:R,total:F})}),this._pdfDataRangeTransport.addProgressiveReadListener(R=>{this._onReceiveData({chunk:R})}),this._pdfDataRangeTransport.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),this._pdfDataRangeTransport.transportReady()}_onReceiveData(j){const k=new Uint8Array(j.chunk).buffer;if(void 0===j.begin)this._fullRequestReader?this._fullRequestReader._enqueue(k):this._queuedChunks.push(k);else{const E=this._rangeReaders.some(function(R){return R._begin===j.begin&&(R._enqueue(k),!0)});(0,f.assert)(E,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){return this._fullRequestReader?this._fullRequestReader._loaded:0}_onProgress(j){if(void 0===j.total){const k=this._rangeReaders[0];k&&k.onProgress&&k.onProgress({loaded:j.loaded})}else{const k=this._fullRequestReader;k&&k.onProgress&&k.onProgress({loaded:j.loaded,total:j.total})}}_onProgressiveDone(){this._fullRequestReader&&this._fullRequestReader.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(j){const k=this._rangeReaders.indexOf(j);k>=0&&this._rangeReaders.splice(k,1)}getFullReader(){(0,f.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const j=this._queuedChunks;return this._queuedChunks=null,new N(this,j,this._progressiveDone)}getRangeReader(j,k){if(k<=this._progressiveDataLength)return null;const E=new q(this,j,k);return this._pdfDataRangeTransport.requestDataRange(j,k),this._rangeReaders.push(E),E}cancelAllRequests(j){this._fullRequestReader&&this._fullRequestReader.cancel(j),this._rangeReaders.slice(0).forEach(function(E){E.cancel(j)}),this._pdfDataRangeTransport.abort()}};class N{constructor(j,k,E=!1){this._stream=j,this._done=E||!1,this._filename=null,this._queuedChunks=k||[],this._loaded=0;for(const R of this._queuedChunks)this._loaded+=R.byteLength;this._requests=[],this._headersReady=Promise.resolve(),j._fullRequestReader=this,this.onProgress=null}_enqueue(j){this._done||(this._requests.length>0?this._requests.shift().resolve({value:j,done:!1}):this._queuedChunks.push(j),this._loaded+=j.byteLength)}get headersReady(){return this._headersReady}get filename(){return this._filename}get isRangeSupported(){return this._stream._isRangeSupported}get isStreamingSupported(){return this._stream._isStreamingSupported}get contentLength(){return this._stream._contentLength}read(){var j=this;return _asyncToGenerator(function*(){if(j._queuedChunks.length>0)return{value:j._queuedChunks.shift(),done:!1};if(j._done)return{value:void 0,done:!0};const k=(0,f.createPromiseCapability)();return j._requests.push(k),k.promise})()}cancel(j){this._done=!0,this._requests.forEach(function(k){k.resolve({value:void 0,done:!0})}),this._requests=[]}progressiveDone(){this._done||(this._done=!0)}}class q{constructor(j,k,E){this._stream=j,this._begin=k,this._end=E,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(j){this._done||(0===this._requests.length?this._queuedChunk=j:(this._requests.shift().resolve({value:j,done:!1}),this._requests.forEach(function(E){E.resolve({value:void 0,done:!0})}),this._requests=[]),this._done=!0,this._stream._removeRangeReader(this))}get isStreamingSupported(){return!1}read(){var j=this;return _asyncToGenerator(function*(){if(j._queuedChunk){const E=j._queuedChunk;return j._queuedChunk=null,{value:E,done:!1}}if(j._done)return{value:void 0,done:!0};const k=(0,f.createPromiseCapability)();return j._requests.push(k),k.promise})()}cancel(j){this._done=!0,this._requests.forEach(function(k){k.resolve({value:void 0,done:!0})}),this._requests=[],this._stream._removeRangeReader(this)}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.WebGLContext=void 0;var f=z(2);v.WebGLContext=class H{constructor({enable:B=!1}){this._enabled=!0===B}get isEnabled(){let B=this._enabled;return B&&(B=N.tryInitGL()),(0,f.shadow)(this,"isEnabled",B)}composeSMask({layer:B,mask:j,properties:k}){return N.composeSMask(B,j,k)}drawFigures({width:B,height:j,backgroundColor:k,figures:E,context:R}){return N.drawFigures(B,j,k,E,R)}clear(){N.cleanup()}};var N=function(){function B(I,W,G){var Y=I.createShader(G);if(I.shaderSource(Y,W),I.compileShader(Y),!I.getShaderParameter(Y,I.COMPILE_STATUS)){var K=I.getShaderInfoLog(Y);throw new Error("Error during shader compilation: "+K)}return Y}function j(I,W){return B(I,W,I.VERTEX_SHADER)}function k(I,W){return B(I,W,I.FRAGMENT_SHADER)}function E(I,W){for(var G=I.createProgram(),Y=0,Z=W.length;Y<Z;++Y)I.attachShader(G,W[Y]);if(I.linkProgram(G),!I.getProgramParameter(G,I.LINK_STATUS)){var ce=I.getProgramInfoLog(G);throw new Error("Error during program linking: "+ce)}return G}function R(I,W,G){I.activeTexture(G);var Y=I.createTexture();return I.bindTexture(I.TEXTURE_2D,Y),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_WRAP_S,I.CLAMP_TO_EDGE),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_WRAP_T,I.CLAMP_TO_EDGE),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MIN_FILTER,I.NEAREST),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MAG_FILTER,I.NEAREST),I.texImage2D(I.TEXTURE_2D,0,I.RGBA,I.RGBA,I.UNSIGNED_BYTE,W),Y}var F,_;function b(){F||(_=document.createElement("canvas"),F=_.getContext("webgl",{premultipliedalpha:!1}))}var M=null,d=null;return{tryInitGL(){try{return b(),!!F}catch(I){}return!1},composeSMask:function h(I,W,G){var Y=I.width,Z=I.height;M||function V(){var I,W;b(),I=_,_=null,W=F,F=null;var Z=E(W,[j(W," 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; } "),k(W," 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; } ")]);W.useProgram(Z);var K={};K.gl=W,K.canvas=I,K.resolutionLocation=W.getUniformLocation(Z,"u_resolution"),K.positionLocation=W.getAttribLocation(Z,"a_position"),K.backdropLocation=W.getUniformLocation(Z,"u_backdrop"),K.subtypeLocation=W.getUniformLocation(Z,"u_subtype");var ce=W.getAttribLocation(Z,"a_texCoord"),U=W.getUniformLocation(Z,"u_image"),y=W.getUniformLocation(Z,"u_mask"),L=W.createBuffer();W.bindBuffer(W.ARRAY_BUFFER,L),W.bufferData(W.ARRAY_BUFFER,new Float32Array([0,0,1,0,0,1,0,1,1,0,1,1]),W.STATIC_DRAW),W.enableVertexAttribArray(ce),W.vertexAttribPointer(ce,2,W.FLOAT,!1,0,0),W.uniform1i(U,0),W.uniform1i(y,1),M=K}();var K=M,ce=K.canvas,U=K.gl;ce.width=Y,ce.height=Z,U.viewport(0,0,U.drawingBufferWidth,U.drawingBufferHeight),U.uniform2f(K.resolutionLocation,Y,Z),G.backdrop?U.uniform4f(K.resolutionLocation,G.backdrop[0],G.backdrop[1],G.backdrop[2],1):U.uniform4f(K.resolutionLocation,0,0,0,0),U.uniform1i(K.subtypeLocation,"Luminosity"===G.subtype?1:0);var y=R(U,I,U.TEXTURE0),L=R(U,W,U.TEXTURE1),P=U.createBuffer();return U.bindBuffer(U.ARRAY_BUFFER,P),U.bufferData(U.ARRAY_BUFFER,new Float32Array([0,0,Y,0,0,Z,0,Z,Y,0,Y,Z]),U.STATIC_DRAW),U.enableVertexAttribArray(K.positionLocation),U.vertexAttribPointer(K.positionLocation,2,U.FLOAT,!1,0,0),U.clearColor(0,0,0,0),U.enable(U.BLEND),U.blendFunc(U.ONE,U.ONE_MINUS_SRC_ALPHA),U.clear(U.COLOR_BUFFER_BIT),U.drawArrays(U.TRIANGLES,0,6),U.flush(),U.deleteTexture(y),U.deleteTexture(L),U.deleteBuffer(P),ce},drawFigures:function D(I,W,G,Y,Z){d||function m(){var I,W;b(),I=_,_=null,W=F,F=null;var Z=E(W,[j(W," 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); } "),k(W," precision mediump float; varying vec4 v_color; void main() { gl_FragColor = v_color; } ")]);W.useProgram(Z);var K={};K.gl=W,K.canvas=I,K.resolutionLocation=W.getUniformLocation(Z,"u_resolution"),K.scaleLocation=W.getUniformLocation(Z,"u_scale"),K.offsetLocation=W.getUniformLocation(Z,"u_offset"),K.positionLocation=W.getAttribLocation(Z,"a_position"),K.colorLocation=W.getAttribLocation(Z,"a_color"),d=K}();var K=d,ce=K.canvas,U=K.gl;ce.width=I,ce.height=W,U.viewport(0,0,U.drawingBufferWidth,U.drawingBufferHeight),U.uniform2f(K.resolutionLocation,I,W);var L,P,T,y=0;for(L=0,P=Y.length;L<P;L++)switch(Y[L].type){case"lattice":y+=((T=Y[L].coords.length/Y[L].verticesPerRow|0)-1)*(Y[L].verticesPerRow-1)*6;break;case"triangles":y+=Y[L].coords.length}var w=new Float32Array(2*y),C=new Uint8Array(3*y),X=Z.coords,Q=Z.colors,ee=0,re=0;for(L=0,P=Y.length;L<P;L++){var le=Y[L],de=le.coords,ge=le.colors;switch(le.type){case"lattice":var pe=le.verticesPerRow;T=de.length/pe|0;for(var Ae=1;Ae<T;Ae++)for(var Ce=Ae*pe+1,xe=1;xe<pe;xe++,Ce++)w[ee]=X[de[Ce-pe-1]],w[ee+1]=X[de[Ce-pe-1]+1],w[ee+2]=X[de[Ce-pe]],w[ee+3]=X[de[Ce-pe]+1],w[ee+4]=X[de[Ce-1]],w[ee+5]=X[de[Ce-1]+1],C[re]=Q[ge[Ce-pe-1]],C[re+1]=Q[ge[Ce-pe-1]+1],C[re+2]=Q[ge[Ce-pe-1]+2],C[re+3]=Q[ge[Ce-pe]],C[re+4]=Q[ge[Ce-pe]+1],C[re+5]=Q[ge[Ce-pe]+2],C[re+6]=Q[ge[Ce-1]],C[re+7]=Q[ge[Ce-1]+1],C[re+8]=Q[ge[Ce-1]+2],w[ee+6]=w[ee+2],w[ee+7]=w[ee+3],w[ee+8]=w[ee+4],w[ee+9]=w[ee+5],w[ee+10]=X[de[Ce]],w[ee+11]=X[de[Ce]+1],C[re+9]=C[re+3],C[re+10]=C[re+4],C[re+11]=C[re+5],C[re+12]=C[re+6],C[re+13]=C[re+7],C[re+14]=C[re+8],C[re+15]=Q[ge[Ce]],C[re+16]=Q[ge[Ce]+1],C[re+17]=Q[ge[Ce]+2],ee+=12,re+=18;break;case"triangles":for(var te=0,ie=de.length;te<ie;te++)w[ee]=X[de[te]],w[ee+1]=X[de[te]+1],C[re]=Q[ge[te]],C[re+1]=Q[ge[te]+1],C[re+2]=Q[ge[te]+2],ee+=2,re+=3}}G?U.clearColor(G[0]/255,G[1]/255,G[2]/255,1):U.clearColor(0,0,0,0),U.clear(U.COLOR_BUFFER_BIT);var ye=U.createBuffer();U.bindBuffer(U.ARRAY_BUFFER,ye),U.bufferData(U.ARRAY_BUFFER,w,U.STATIC_DRAW),U.enableVertexAttribArray(K.positionLocation),U.vertexAttribPointer(K.positionLocation,2,U.FLOAT,!1,0,0);var he=U.createBuffer();return U.bindBuffer(U.ARRAY_BUFFER,he),U.bufferData(U.ARRAY_BUFFER,C,U.STATIC_DRAW),U.enableVertexAttribArray(K.colorLocation),U.vertexAttribPointer(K.colorLocation,3,U.UNSIGNED_BYTE,!1,0,0),U.uniform2f(K.scaleLocation,Z.scaleX,Z.scaleY),U.uniform2f(K.offsetLocation,Z.offsetX,Z.offsetY),U.drawArrays(U.TRIANGLES,0,y),U.flush(),U.deleteBuffer(ye),U.deleteBuffer(he),ce},cleanup(){M&&M.canvas&&(M.canvas.width=0,M.canvas.height=0),d&&d.canvas&&(d.canvas.width=0,d.canvas.height=0),M=null,d=null}}}()},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.AnnotationLayer=void 0;var f=z(1),H=z(2);class N{static create(y){switch(y.data.annotationType){case H.AnnotationType.LINK:return new B(y);case H.AnnotationType.TEXT:return new j(y);case H.AnnotationType.WIDGET:switch(y.data.fieldType){case"Tx":return new E(y);case"Btn":return y.data.radioButton?new F(y):y.data.checkBox?new R(y):new _(y);case"Ch":return new b(y)}return new k(y);case H.AnnotationType.POPUP:return new A(y);case H.AnnotationType.FREETEXT:return new M(y);case H.AnnotationType.LINE:return new V(y);case H.AnnotationType.SQUARE:return new h(y);case H.AnnotationType.CIRCLE:return new p(y);case H.AnnotationType.POLYLINE:return new c(y);case H.AnnotationType.CARET:return new m(y);case H.AnnotationType.INK:return new D(y);case H.AnnotationType.POLYGON:return new d(y);case H.AnnotationType.HIGHLIGHT:return new I(y);case H.AnnotationType.UNDERLINE:return new W(y);case H.AnnotationType.SQUIGGLY:return new G(y);case H.AnnotationType.STRIKEOUT:return new Y(y);case H.AnnotationType.STAMP:return new Z(y);case H.AnnotationType.FILEATTACHMENT:return new K(y);default:return new q(y)}}}class q{constructor(y,L=!1,P=!1){this.isRenderable=L,this.data=y.data,this.layer=y.layer,this.page=y.page,this.viewport=y.viewport,this.linkService=y.linkService,this.downloadManager=y.downloadManager,this.imageResourcesPath=y.imageResourcesPath,this.renderInteractiveForms=y.renderInteractiveForms,this.svgFactory=y.svgFactory,L&&(this.container=this._createContainer(P))}_createContainer(y=!1){const L=this.data,P=this.page,T=this.viewport,w=document.createElement("section");let C=L.rect[2]-L.rect[0],X=L.rect[3]-L.rect[1];w.setAttribute("data-annotation-id",L.id);const Q=H.Util.normalizeRect([L.rect[0],P.view[3]-L.rect[1]+P.view[1],L.rect[2],P.view[3]-L.rect[3]+P.view[1]]);if(w.style.transform=`matrix(${T.transform.join(",")})`,w.style.transformOrigin=`-${Q[0]}px -${Q[1]}px`,!y&&L.borderStyle.width>0){w.style.borderWidth=`${L.borderStyle.width}px`,L.borderStyle.style!==H.AnnotationBorderStyleType.UNDERLINE&&(C-=2*L.borderStyle.width,X-=2*L.borderStyle.width);const ee=L.borderStyle.horizontalCornerRadius,re=L.borderStyle.verticalCornerRadius;switch((ee>0||re>0)&&(w.style.borderRadius=`${ee}px / ${re}px`),L.borderStyle.style){case H.AnnotationBorderStyleType.SOLID:w.style.borderStyle="solid";break;case H.AnnotationBorderStyleType.DASHED:w.style.borderStyle="dashed";break;case H.AnnotationBorderStyleType.BEVELED:(0,H.warn)("Unimplemented border style: beveled");break;case H.AnnotationBorderStyleType.INSET:(0,H.warn)("Unimplemented border style: inset");break;case H.AnnotationBorderStyleType.UNDERLINE:w.style.borderBottomStyle="solid"}L.color?w.style.borderColor=H.Util.makeCssRgb(0|L.color[0],0|L.color[1],0|L.color[2]):w.style.borderWidth=0}return w.style.left=`${Q[0]}px`,w.style.top=`${Q[1]}px`,w.style.width=`${C}px`,w.style.height=`${X}px`,w}_createPopup(y,L,P){L||((L=document.createElement("div")).style.height=y.style.height,L.style.width=y.style.width,y.appendChild(L));const w=new x({container:y,trigger:L,color:P.color,title:P.title,modificationDate:P.modificationDate,contents:P.contents,hideWrapper:!0}).render();w.style.left=y.style.width,y.appendChild(w)}render(){(0,H.unreachable)("Abstract method `AnnotationElement.render` called")}}class B extends q{constructor(y){super(y,!!(y.data.url||y.data.dest||y.data.action))}render(){this.container.className="linkAnnotation";const{data:y,linkService:L}=this,P=document.createElement("a");return y.url?(0,f.addLinkAttributes)(P,{url:y.url,target:y.newWindow?f.LinkTarget.BLANK:L.externalLinkTarget,rel:L.externalLinkRel,enabled:L.externalLinkEnabled}):y.action?this._bindNamedAction(P,y.action):this._bindLink(P,y.dest),this.container.appendChild(P),this.container}_bindLink(y,L){y.href=this.linkService.getDestinationHash(L),y.onclick=()=>(L&&this.linkService.navigateTo(L),!1),L&&(y.className="internalLink")}_bindNamedAction(y,L){y.href=this.linkService.getAnchorUrl(""),y.onclick=()=>(this.linkService.executeNamedAction(L),!1),y.className="internalLink"}}class j extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents))}render(){this.container.className="textAnnotation";const y=document.createElement("img");return y.style.height=this.container.style.height,y.style.width=this.container.style.width,y.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",y.alt="[{{type}} Annotation]",y.dataset.l10nId="text_annotation_type",y.dataset.l10nArgs=JSON.stringify({type:this.data.name}),this.data.hasPopup||this._createPopup(this.container,y,this.data),this.container.appendChild(y),this.container}}class k extends q{render(){return this.container}}class E extends k{constructor(y){super(y,y.renderInteractiveForms||!y.data.hasAppearance&&!!y.data.fieldValue)}render(){this.container.className="textWidgetAnnotation";let L=null;if(this.renderInteractiveForms){if(this.data.multiLine?(L=document.createElement("textarea"),L.textContent=this.data.fieldValue):(L=document.createElement("input"),L.type="text",L.setAttribute("value",this.data.fieldValue)),L.disabled=this.data.readOnly,L.name=this.data.fieldName,null!==this.data.maxLen&&(L.maxLength=this.data.maxLen),this.data.comb){const T=(this.data.rect[2]-this.data.rect[0])/this.data.maxLen;L.classList.add("comb"),L.style.letterSpacing=`calc(${T}px - 1ch)`}}else{L=document.createElement("div"),L.textContent=this.data.fieldValue,L.style.verticalAlign="middle",L.style.display="table-cell";let P=null;this.data.fontRefName&&this.page.commonObjs.has(this.data.fontRefName)&&(P=this.page.commonObjs.get(this.data.fontRefName)),this._setTextStyle(L,P)}return null!==this.data.textAlignment&&(L.style.textAlign=["left","center","right"][this.data.textAlignment]),this.container.appendChild(L),this.container}_setTextStyle(y,L){const P=y.style;if(P.fontSize=`${this.data.fontSize}px`,P.direction=this.data.fontDirection<0?"rtl":"ltr",!L)return;let T="normal";L.black?T="900":L.bold&&(T="bold"),P.fontWeight=T,P.fontStyle=L.italic?"italic":"normal",P.fontFamily=(L.loadedName?`"${L.loadedName}", `:"")+(L.fallbackName||"Helvetica, sans-serif")}}class R extends k{constructor(y){super(y,y.renderInteractiveForms)}render(){this.container.className="buttonWidgetAnnotation checkBox";const y=document.createElement("input");return y.disabled=this.data.readOnly,y.type="checkbox",y.name=this.data.fieldName,this.data.fieldValue&&"Off"!==this.data.fieldValue&&y.setAttribute("checked",!0),this.container.appendChild(y),this.container}}class F extends k{constructor(y){super(y,y.renderInteractiveForms)}render(){this.container.className="buttonWidgetAnnotation radioButton";const y=document.createElement("input");return y.disabled=this.data.readOnly,y.type="radio",y.name=this.data.fieldName,this.data.fieldValue===this.data.buttonValue&&y.setAttribute("checked",!0),this.container.appendChild(y),this.container}}class _ extends B{render(){const y=super.render();return y.className="buttonWidgetAnnotation pushButton",y}}class b extends k{constructor(y){super(y,y.renderInteractiveForms)}render(){this.container.className="choiceWidgetAnnotation";const y=document.createElement("select");y.disabled=this.data.readOnly,y.name=this.data.fieldName,this.data.combo||(y.size=this.data.options.length,this.data.multiSelect&&(y.multiple=!0));for(const L of this.data.options){const P=document.createElement("option");P.textContent=L.displayValue,P.value=L.exportValue,this.data.fieldValue.includes(L.displayValue)&&P.setAttribute("selected",!0),y.appendChild(P)}return this.container.appendChild(y),this.container}}class A extends q{constructor(y){super(y,!(!y.data.title&&!y.data.contents))}render(){if(this.container.className="popupAnnotation",["Line","Square","Circle","PolyLine","Polygon","Ink"].includes(this.data.parentType))return this.container;const P=this.layer.querySelector(`[data-annotation-id="${this.data.parentId}"]`);if(!P)return this.container;const T=new x({container:this.container,trigger:P,color:this.data.color,title:this.data.title,modificationDate:this.data.modificationDate,contents:this.data.contents}),w=parseFloat(P.style.left),C=parseFloat(P.style.width);return this.container.style.transformOrigin=`-${w+C}px -${P.style.top}`,this.container.style.left=`${w+C}px`,this.container.appendChild(T.render()),this.container}}class x{constructor(y){this.container=y.container,this.trigger=y.trigger,this.color=y.color,this.title=y.title,this.modificationDate=y.modificationDate,this.contents=y.contents,this.hideWrapper=y.hideWrapper||!1,this.pinned=!1}render(){const L=document.createElement("div");L.className="popupWrapper",this.hideElement=this.hideWrapper?L:this.container,this.hideElement.setAttribute("hidden",!0);const P=document.createElement("div");P.className="popup";const T=this.color;T&&(P.style.backgroundColor=H.Util.makeCssRgb(0|.7*(255-T[0])+T[0],0|.7*(255-T[1])+T[1],0|.7*(255-T[2])+T[2]));const w=document.createElement("h1");w.textContent=this.title,P.appendChild(w);const C=f.PDFDateString.toDateObject(this.modificationDate);if(C){const Q=document.createElement("span");Q.textContent="{{date}}, {{time}}",Q.dataset.l10nId="annotation_date_string",Q.dataset.l10nArgs=JSON.stringify({date:C.toLocaleDateString(),time:C.toLocaleTimeString()}),P.appendChild(Q)}const X=this._formatContents(this.contents);return P.appendChild(X),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)),P.addEventListener("click",this._hide.bind(this,!0)),L.appendChild(P),L}_formatContents(y){const L=document.createElement("p"),P=y.split(/(?:\r\n?|\n)/);for(let T=0,w=P.length;T<w;++T)L.appendChild(document.createTextNode(P[T])),T<w-1&&L.appendChild(document.createElement("br"));return L}_toggle(){this.pinned?this._hide(!0):this._show(!0)}_show(y=!1){y&&(this.pinned=!0),this.hideElement.hasAttribute("hidden")&&(this.hideElement.removeAttribute("hidden"),this.container.style.zIndex+=1)}_hide(y=!0){y&&(this.pinned=!1),!this.hideElement.hasAttribute("hidden")&&!this.pinned&&(this.hideElement.setAttribute("hidden",!0),this.container.style.zIndex-=1)}}class M extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="freeTextAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class V extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){this.container.className="lineAnnotation";const y=this.data,T=this.svgFactory.create(y.rect[2]-y.rect[0],y.rect[3]-y.rect[1]),w=this.svgFactory.createElement("svg:line");return w.setAttribute("x1",y.rect[2]-y.lineCoordinates[0]),w.setAttribute("y1",y.rect[3]-y.lineCoordinates[1]),w.setAttribute("x2",y.rect[2]-y.lineCoordinates[2]),w.setAttribute("y2",y.rect[3]-y.lineCoordinates[3]),w.setAttribute("stroke-width",y.borderStyle.width||1),w.setAttribute("stroke","transparent"),T.appendChild(w),this.container.append(T),this._createPopup(this.container,w,y),this.container}}class h extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){this.container.className="squareAnnotation";const y=this.data,L=y.rect[2]-y.rect[0],P=y.rect[3]-y.rect[1],T=this.svgFactory.create(L,P),w=y.borderStyle.width,C=this.svgFactory.createElement("svg:rect");return C.setAttribute("x",w/2),C.setAttribute("y",w/2),C.setAttribute("width",L-w),C.setAttribute("height",P-w),C.setAttribute("stroke-width",w||1),C.setAttribute("stroke","transparent"),C.setAttribute("fill","none"),T.appendChild(C),this.container.append(T),this._createPopup(this.container,C,y),this.container}}class p extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){this.container.className="circleAnnotation";const y=this.data,L=y.rect[2]-y.rect[0],P=y.rect[3]-y.rect[1],T=this.svgFactory.create(L,P),w=y.borderStyle.width,C=this.svgFactory.createElement("svg:ellipse");return C.setAttribute("cx",L/2),C.setAttribute("cy",P/2),C.setAttribute("rx",L/2-w/2),C.setAttribute("ry",P/2-w/2),C.setAttribute("stroke-width",w||1),C.setAttribute("stroke","transparent"),C.setAttribute("fill","none"),T.appendChild(C),this.container.append(T),this._createPopup(this.container,C,y),this.container}}class c extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0),this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.className=this.containerClassName;const y=this.data,T=this.svgFactory.create(y.rect[2]-y.rect[0],y.rect[3]-y.rect[1]);let w=[];for(const X of y.vertices)w.push(X.x-y.rect[0]+","+(y.rect[3]-X.y));w=w.join(" ");const C=this.svgFactory.createElement(this.svgElementName);return C.setAttribute("points",w),C.setAttribute("stroke-width",y.borderStyle.width||1),C.setAttribute("stroke","transparent"),C.setAttribute("fill","none"),T.appendChild(C),this.container.append(T),this._createPopup(this.container,C,y),this.container}}class d extends c{constructor(y){super(y),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class m extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="caretAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class D extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0),this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline"}render(){this.container.className=this.containerClassName;const y=this.data,T=this.svgFactory.create(y.rect[2]-y.rect[0],y.rect[3]-y.rect[1]);for(const w of y.inkLists){let C=[];for(const Q of w)C.push(`${Q.x-y.rect[0]},${y.rect[3]-Q.y}`);C=C.join(" ");const X=this.svgFactory.createElement(this.svgElementName);X.setAttribute("points",C),X.setAttribute("stroke-width",y.borderStyle.width||1),X.setAttribute("stroke","transparent"),X.setAttribute("fill","none"),this._createPopup(this.container,X,y),T.appendChild(X)}return this.container.append(T),this.container}}class I extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="highlightAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class W extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="underlineAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class G extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="squigglyAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class Y extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="strikeoutAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class Z extends q{constructor(y){super(y,!!(y.data.hasPopup||y.data.title||y.data.contents),!0)}render(){return this.container.className="stampAnnotation",this.data.hasPopup||this._createPopup(this.container,null,this.data),this.container}}class K extends q{constructor(y){super(y,!0);const{filename:L,content:P}=this.data.file;this.filename=(0,f.getFilenameFromUrl)(L),this.content=P,this.linkService.eventBus&&this.linkService.eventBus.dispatch("fileattachmentannotation",{source:this,id:(0,H.stringToPDFString)(L),filename:L,content:P})}render(){this.container.className="fileAttachmentAnnotation";const y=document.createElement("div");return y.style.height=this.container.style.height,y.style.width=this.container.style.width,y.addEventListener("dblclick",this._download.bind(this)),!this.data.hasPopup&&(this.data.title||this.data.contents)&&this._createPopup(this.container,y,this.data),this.container.appendChild(y),this.container}_download(){this.downloadManager?this.downloadManager.downloadData(this.content,this.filename,""):(0,H.warn)("Download cannot be started due to unavailable download manager")}}v.AnnotationLayer=class ce{static render(y){const L=[],P=[];for(const T of y.annotations)if(T){if(T.annotationType===H.AnnotationType.POPUP){P.push(T);continue}L.push(T)}P.length&&L.push(...P);for(const T of L){const w=N.create({data:T,layer:y.div,page:y.page,viewport:y.viewport,linkService:y.linkService,downloadManager:y.downloadManager,imageResourcesPath:y.imageResourcesPath||"",renderInteractiveForms:y.renderInteractiveForms||!1,svgFactory:new f.DOMSVGFactory});w.isRenderable&&y.div.appendChild(w.render())}}static update(y){for(const L of y.annotations){const P=y.div.querySelector(`[data-annotation-id="${L.id}"]`);P&&(P.style.transform=`matrix(${y.viewport.transform.join(",")})`)}y.div.removeAttribute("hidden")}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.renderTextLayer=void 0;var f=z(2),H=function(){var B=/\S/;function k(M,V,h){var p=document.createElement("span"),c={angle:0,canvasWidth:0,isWhitespace:!1,originalTransform:null,paddingBottom:0,paddingLeft:0,paddingRight:0,paddingTop:0,scale:1};if(M._textDivs.push(p),function j(M){return!B.test(M)}(V.str))return c.isWhitespace=!0,void M._textDivProperties.set(p,c);var d=f.Util.transform(M._viewport.transform,V.transform),m=Math.atan2(d[1],d[0]),D=h[V.fontName];D.vertical&&(m+=Math.PI/2);var I=Math.sqrt(d[2]*d[2]+d[3]*d[3]),W=I;let G,Y;D.ascent?W*=D.ascent:D.descent&&(W*=1+D.descent),0===m?(G=d[4],Y=d[5]-W):(G=d[4]+W*Math.sin(m),Y=d[5]-W*Math.cos(m)),p.style.left=`${G}px`,p.style.top=`${Y}px`,p.style.fontSize=`${I}px`,p.style.fontFamily=D.fontFamily,p.textContent=V.str,M._fontInspectorEnabled&&(p.dataset.fontName=V.fontName),0!==m&&(c.angle=m*(180/Math.PI));let Z=!1;if(V.str.length>1)Z=!0;else if(V.transform[0]!==V.transform[3]){const T=Math.abs(V.transform[0]),w=Math.abs(V.transform[3]);T!==w&&Math.max(T,w)/Math.min(T,w)>1.5&&(Z=!0)}if(Z&&(c.canvasWidth=D.vertical?V.height*M._viewport.scale:V.width*M._viewport.scale),M._textDivProperties.set(p,c),M._textContentStream&&M._layoutText(p),M._enhanceTextSelection){var K=1,ce=0;0!==m&&(K=Math.cos(m),ce=Math.sin(m));var L,P,U=(D.vertical?V.height:V.width)*M._viewport.scale,y=I;P=0!==m?f.Util.getAxialAlignedBoundingBox([0,0,U,y],L=[K,ce,-ce,K,G,Y]):[G,Y,G+U,Y+y],M._bounds.push({left:P[0],top:P[1],right:P[2],bottom:P[3],div:p,size:[U,y],m:L})}}function E(M){if(!M._canceled){var V=M._textDivs,h=M._capability,p=V.length;if(p>1e5)return M._renderingDone=!0,void h.resolve();if(!M._textContentStream)for(var c=0;c<p;c++)M._layoutText(V[c]);M._renderingDone=!0,h.resolve()}}function R(M,V,h){let p=0;for(let c=0;c<h;c++){const d=M[V++];d>0&&(p=p?Math.min(d,p):d)}return p}function b(M,V){V.sort(function(c,d){return c.x1-d.x1||c.index-d.index});var p=[{start:-1/0,end:1/0,boundary:{x1:-1/0,y1:-1/0,x2:0,y2:1/0,index:-1,x1New:0,x2New:0}}];V.forEach(function(c){for(var d=0;d<p.length&&p[d].end<=c.y1;)d++;for(var m=p.length-1;m>=0&&p[m].start>=c.y2;)m--;var D,I,W,G,Y=-1/0;for(W=d;W<=m;W++){var Z;(Z=(I=(D=p[W]).boundary).x2>c.x1?I.index>c.index?I.x1New:c.x1:void 0===I.x2New?(I.x2+c.x1)/2:I.x2New)>Y&&(Y=Z)}for(c.x1New=Y,W=d;W<=m;W++)void 0===(I=(D=p[W]).boundary).x2New?I.x2>c.x1?I.index>c.index&&(I.x2New=I.x2):I.x2New=Y:I.x2New>Y&&(I.x2New=Math.max(Y,I.x2));var K=[],ce=null;for(W=d;W<=m;W++){var U=(I=(D=p[W]).boundary).x2>c.x2?I:c;ce===U?K[K.length-1].end=D.end:(K.push({start:D.start,end:D.end,boundary:U}),ce=U)}for(p[d].start<c.y1&&(K[0].start=c.y1,K.unshift({start:p[d].start,end:c.y1,boundary:p[d].boundary})),c.y2<p[m].end&&(K[K.length-1].end=c.y2,K.push({start:c.y2,end:p[m].end,boundary:p[m].boundary})),W=d;W<=m;W++)if(void 0===(I=(D=p[W]).boundary).x2New){var y=!1;for(G=d-1;!y&&G>=0&&p[G].start>=I.y1;G--)y=p[G].boundary===I;for(G=m+1;!y&&G<p.length&&p[G].end<=I.y2;G++)y=p[G].boundary===I;for(G=0;!y&&G<K.length;G++)y=K[G].boundary===I;y||(I.x2New=Y)}Array.prototype.splice.apply(p,[d,m-d+1].concat(K))}),p.forEach(function(c){var d=c.boundary;void 0===d.x2New&&(d.x2New=Math.max(M,d.x2))})}function A({textContent:M,textContentStream:V,container:h,viewport:p,textDivs:c,textContentItemsStr:d,enhanceTextSelection:m}){this._textContent=M,this._textContentStream=V,this._container=h,this._viewport=p,this._textDivs=c||[],this._textContentItemsStr=d||[],this._enhanceTextSelection=!!m,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,f.createPromiseCapability)(),this._renderTimer=null,this._bounds=[],this._capability.promise.finally(()=>{this._layoutTextCtx&&(this._layoutTextCtx.canvas.width=0,this._layoutTextCtx.canvas.height=0,this._layoutTextCtx=null)}).catch(()=>{})}return A.prototype={get promise(){return this._capability.promise},cancel:function(){this._canceled=!0,this._reader&&(this._reader.cancel(new f.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(M,V){for(let h=0,p=M.length;h<p;h++)this._textContentItemsStr.push(M[h].str),k(this,M[h],V)},_layoutText(M){const V=this._textDivProperties.get(M);if(V.isWhitespace)return;let h="";if(0!==V.canvasWidth){const{fontSize:p,fontFamily:c}=M.style;(p!==this._layoutTextLastFontSize||c!==this._layoutTextLastFontFamily)&&(this._layoutTextCtx.font=`${p} ${c}`,this._layoutTextLastFontSize=p,this._layoutTextLastFontFamily=c);const{width:d}=this._layoutTextCtx.measureText(M.textContent);d>0&&(V.scale=V.canvasWidth/d,h=`scaleX(${V.scale})`)}0!==V.angle&&(h=`rotate(${V.angle}deg) ${h}`),h.length>0&&(this._enhanceTextSelection&&(V.originalTransform=h),M.style.transform=h),this._textDivProperties.set(M,V),this._container.appendChild(M)},_render:function(V){const h=(0,f.createPromiseCapability)();let p=Object.create(null);const c=document.createElement("canvas");if(c.mozOpaque=!0,this._layoutTextCtx=c.getContext("2d",{alpha:!1}),this._textContent)this._processItems(this._textContent.items,this._textContent.styles),h.resolve();else{if(!this._textContentStream)throw new Error('Neither "textContent" nor "textContentStream" parameters specified.');{const d=()=>{this._reader.read().then(({value:m,done:D})=>{D?h.resolve():(Object.assign(p,m.styles),this._processItems(m.items,p),d())},h.reject)};this._reader=this._textContentStream.getReader(),d()}}h.promise.then(()=>{p=null,V?this._renderTimer=setTimeout(()=>{E(this),this._renderTimer=null},V):E(this)},this._capability.reject)},expandTextDivs:function(V){if(!this._enhanceTextSelection||!this._renderingDone)return;null!==this._bounds&&(function F(M){for(var V=M._bounds,h=M._viewport,p=function _(M,V,h){var p=h.map(function(d,m){return{x1:d.left,y1:d.top,x2:d.right,y2:d.bottom,index:m,x1New:void 0,x2New:void 0}});b(M,p);var c=new Array(h.length);return p.forEach(function(d){c[d.index]={left:d.x1New,top:0,right:d.x2New,bottom:0}}),h.map(function(d,m){var D=c[m],I=p[m];I.x1=d.top,I.y1=M-D.right,I.x2=d.bottom,I.y2=M-D.left,I.index=m,I.x1New=void 0,I.x2New=void 0}),b(V,p),p.forEach(function(d){var m=d.index;c[m].top=d.x1New,c[m].bottom=d.x2New}),c}(h.width,h.height,V),c=0;c<p.length;c++){var d=V[c].div,m=M._textDivProperties.get(d);if(0!==m.angle){var D=p[c],I=V[c],W=I.m,G=W[0],Y=W[1],Z=[[0,0],[0,I.size[1]],[I.size[0],0],I.size],K=new Float64Array(64);Z.forEach(function(U,y){var L=f.Util.applyTransform(U,W);K[y+0]=G&&(D.left-L[0])/G,K[y+4]=Y&&(D.top-L[1])/Y,K[y+8]=G&&(D.right-L[0])/G,K[y+12]=Y&&(D.bottom-L[1])/Y,K[y+16]=Y&&(D.left-L[0])/-Y,K[y+20]=G&&(D.top-L[1])/G,K[y+24]=Y&&(D.right-L[0])/-Y,K[y+28]=G&&(D.bottom-L[1])/G,K[y+32]=G&&(D.left-L[0])/-G,K[y+36]=Y&&(D.top-L[1])/-Y,K[y+40]=G&&(D.right-L[0])/-G,K[y+44]=Y&&(D.bottom-L[1])/-Y,K[y+48]=Y&&(D.left-L[0])/Y,K[y+52]=G&&(D.top-L[1])/-G,K[y+56]=Y&&(D.right-L[0])/Y,K[y+60]=G&&(D.bottom-L[1])/-G});var ce=1+Math.min(Math.abs(G),Math.abs(Y));m.paddingLeft=R(K,32,16)/ce,m.paddingTop=R(K,48,16)/ce,m.paddingRight=R(K,0,16)/ce,m.paddingBottom=R(K,16,16)/ce,M._textDivProperties.set(d,m)}else m.paddingLeft=V[c].left-p[c].left,m.paddingTop=V[c].top-p[c].top,m.paddingRight=p[c].right-V[c].right,m.paddingBottom=p[c].bottom-V[c].bottom,M._textDivProperties.set(d,m)}}(this),this._bounds=null);const h=[],p=[];for(var c=0,d=this._textDivs.length;c<d;c++){const m=this._textDivs[c],D=this._textDivProperties.get(m);D.isWhitespace||(V?(h.length=0,p.length=0,D.originalTransform&&h.push(D.originalTransform),D.paddingTop>0?(p.push(`${D.paddingTop}px`),h.push(`translateY(${-D.paddingTop}px)`)):p.push(0),p.push(D.paddingRight>0?D.paddingRight/D.scale+"px":0),p.push(D.paddingBottom>0?`${D.paddingBottom}px`:0),D.paddingLeft>0?(p.push(D.paddingLeft/D.scale+"px"),h.push(`translateX(${-D.paddingLeft/D.scale}px)`)):p.push(0),m.style.padding=p.join(" "),h.length&&(m.style.transform=h.join(" "))):(m.style.padding=null,m.style.transform=D.originalTransform))}}},function x(M){var V=new A({textContent:M.textContent,textContentStream:M.textContentStream,container:M.container,viewport:M.viewport,textDivs:M.textDivs,textContentItemsStr:M.textContentItemsStr,enhanceTextSelection:M.enhanceTextSelection});return V._render(M.timeout),V}}();v.renderTextLayer=H},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.SVGGraphics=void 0;var f=z(2),H=z(1),N=z(4);let q=function(){throw new Error("Not implemented: SVGGraphics")};v.SVGGraphics=q;{let b=function(p){let c=[];const d=[];for(const m of p)"save"!==m.fn?"restore"===m.fn?c=d.pop():c.push(m):(c.push({fnId:92,fn:"group",items:[]}),d.push(c),c=c[c.length-1].items);return c},A=function(p){if(Number.isInteger(p))return p.toString();const c=p.toFixed(10);let d=c.length-1;if("0"!==c[d])return c;do{d--}while("0"===c[d]);return c.substring(0,"."===c[d]?d:d+1)},x=function(p){if(0===p[4]&&0===p[5]){if(0===p[1]&&0===p[2])return 1===p[0]&&1===p[3]?"":`scale(${A(p[0])} ${A(p[3])})`;if(p[0]===p[3]&&p[1]===-p[2]){const c=180*Math.acos(p[0])/Math.PI;return`rotate(${A(c)})`}}else if(1===p[0]&&0===p[1]&&0===p[2]&&1===p[3])return`translate(${A(p[4])} ${A(p[5])})`;return`matrix(${A(p[0])} ${A(p[1])} ${A(p[2])} ${A(p[3])} ${A(p[4])} ${A(p[5])})`};const B={fontStyle:"normal",fontWeight:"normal",fillColor:"#000000"},j="http://www.w3.org/XML/1998/namespace",k="http://www.w3.org/1999/xlink",E=["butt","round","square"],R=["miter","round","bevel"],F=function(){const p=new Uint8Array([137,80,78,71,13,10,26,10]),d=new Int32Array(256);for(let Z=0;Z<256;Z++){let K=Z;for(let ce=0;ce<8;ce++)K=1&K?3988292384^K>>1&2147483647:K>>1&2147483647;d[Z]=K}function D(Z,K,ce,U){let y=U;const L=K.length;ce[y]=L>>24&255,ce[y+1]=L>>16&255,ce[y+2]=L>>8&255,ce[y+3]=255&L,y+=4,ce[y]=255&Z.charCodeAt(0),ce[y+1]=255&Z.charCodeAt(1),ce[y+2]=255&Z.charCodeAt(2),ce[y+3]=255&Z.charCodeAt(3),y+=4,ce.set(K,y),y+=K.length;const P=function m(Z,K,ce){let U=-1;for(let y=K;y<ce;y++)U=U>>>8^d[255&(U^Z[y])];return-1^U}(ce,U+4,y);ce[y]=P>>24&255,ce[y+1]=P>>16&255,ce[y+2]=P>>8&255,ce[y+3]=255&P}function G(Z){let K=Z.length;const ce=65535,U=Math.ceil(K/ce),y=new Uint8Array(2+K+5*U+4);let L=0;y[L++]=120,y[L++]=156;let P=0;for(;K>ce;)y[L++]=0,y[L++]=255,y[L++]=255,y[L++]=0,y[L++]=0,y.set(Z.subarray(P,P+ce),L),L+=ce,P+=ce,K-=ce;y[L++]=1,y[L++]=255&K,y[L++]=K>>8&255,y[L++]=255&~K,y[L++]=(65535&~K)>>8&255,y.set(Z.subarray(P),L),L+=Z.length-P;const T=function I(Z,K,ce){let U=1,y=0;for(let L=K;L<ce;++L)U=(U+(255&Z[L]))%65521,y=(y+U)%65521;return y<<16|U}(Z,0,Z.length);return y[L++]=T>>24&255,y[L++]=T>>16&255,y[L++]=T>>8&255,y[L++]=255&T,y}return function(K,ce,U){return function Y(Z,K,ce,U){const y=Z.width,L=Z.height;let P,T,w;const C=Z.data;switch(K){case f.ImageKind.GRAYSCALE_1BPP:T=0,P=1,w=y+7>>3;break;case f.ImageKind.RGB_24BPP:T=2,P=8,w=3*y;break;case f.ImageKind.RGBA_32BPP:T=6,P=8,w=4*y;break;default:throw new Error("invalid format")}const X=new Uint8Array((1+w)*L);let Q=0,ee=0;for(let Ae=0;Ae<L;++Ae)X[Q++]=0,X.set(C.subarray(ee,ee+w),Q),ee+=w,Q+=w;if(K===f.ImageKind.GRAYSCALE_1BPP&&U){Q=0;for(let Ae=0;Ae<L;Ae++){Q++;for(let Ce=0;Ce<w;Ce++)X[Q++]^=255}}const re=new Uint8Array([y>>24&255,y>>16&255,y>>8&255,255&y,L>>24&255,L>>16&255,L>>8&255,255&L,P,T,0,0,0]),le=function W(Z){if(!N.isNodeJS)return G(Z);try{let K;K=parseInt(process.versions.node)>=8?Z:Buffer.from(Z);const ce=__webpack_require__(258).deflateSync(K,{level:9});return ce instanceof Uint8Array?ce:new Uint8Array(ce)}catch(K){(0,f.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+K)}return G(Z)}(X),ge=new Uint8Array(p.length+36+re.length+le.length);let pe=0;return ge.set(p,pe),pe+=p.length,D("IHDR",re,ge,pe),pe+=12+re.length,D("IDATA",le,ge,pe),pe+=12+le.length,D("IEND",new Uint8Array(0),ge,pe),(0,f.createObjectURL)(ge,"image/png",ce)}(K,void 0===K.kind?f.ImageKind.GRAYSCALE_1BPP:K.kind,ce,U)}}();class _{constructor(){this.fontSizeScale=1,this.fontWeight=B.fontWeight,this.fontSize=0,this.textMatrix=f.IDENTITY_MATRIX,this.fontMatrix=f.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=f.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=B.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=""}clone(){return Object.create(this)}setCurrentPoint(c,d){this.x=c,this.y=d}}let M=0,V=0,h=0;v.SVGGraphics=q=class{constructor(c,d,m=!1){this.svgFactory=new H.DOMSVGFactory,this.current=new _,this.transformMatrix=f.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=c,this.objs=d,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!m,this._operatorIdMapping=[];for(const D in f.OPS)this._operatorIdMapping[f.OPS[D]]=D}save(){this.transformStack.push(this.transformMatrix);const c=this.current;this.extraStack.push(c),this.current=c.clone()}restore(){this.transformMatrix=this.transformStack.pop(),this.current=this.extraStack.pop(),this.pendingClip=null,this.tgrp=null}group(c){this.save(),this.executeOpTree(c),this.restore()}loadDependencies(c){const d=c.fnArray,m=c.argsArray;for(let D=0,I=d.length;D<I;D++)if(d[D]===f.OPS.dependency)for(const W of m[D]){const G=W.startsWith("g_")?this.commonObjs:this.objs,Y=new Promise(Z=>{G.get(W,Z)});this.current.dependencies.push(Y)}return Promise.all(this.current.dependencies)}transform(c,d,m,D,I,W){this.transformMatrix=f.Util.transform(this.transformMatrix,[c,d,m,D,I,W]),this.tgrp=null}getSVG(c,d){this.viewport=d;const m=this._initialize(d);return this.loadDependencies(c).then(()=>(this.transformMatrix=f.IDENTITY_MATRIX,this.executeOpTree(this.convertOpList(c)),m))}convertOpList(c){const d=this._operatorIdMapping,m=c.argsArray,D=c.fnArray,I=[];for(let W=0,G=D.length;W<G;W++){const Y=D[W];I.push({fnId:Y,fn:d[Y],args:m[W]})}return b(I)}executeOpTree(c){for(const d of c){const m=d.fn,I=d.args;switch(0|d.fnId){case f.OPS.beginText:this.beginText();break;case f.OPS.dependency:break;case f.OPS.setLeading:this.setLeading(I);break;case f.OPS.setLeadingMoveText:this.setLeadingMoveText(I[0],I[1]);break;case f.OPS.setFont:this.setFont(I);break;case f.OPS.showText:case f.OPS.showSpacedText:this.showText(I[0]);break;case f.OPS.endText:this.endText();break;case f.OPS.moveText:this.moveText(I[0],I[1]);break;case f.OPS.setCharSpacing:this.setCharSpacing(I[0]);break;case f.OPS.setWordSpacing:this.setWordSpacing(I[0]);break;case f.OPS.setHScale:this.setHScale(I[0]);break;case f.OPS.setTextMatrix:this.setTextMatrix(I[0],I[1],I[2],I[3],I[4],I[5]);break;case f.OPS.setTextRise:this.setTextRise(I[0]);break;case f.OPS.setTextRenderingMode:this.setTextRenderingMode(I[0]);break;case f.OPS.setLineWidth:this.setLineWidth(I[0]);break;case f.OPS.setLineJoin:this.setLineJoin(I[0]);break;case f.OPS.setLineCap:this.setLineCap(I[0]);break;case f.OPS.setMiterLimit:this.setMiterLimit(I[0]);break;case f.OPS.setFillRGBColor:this.setFillRGBColor(I[0],I[1],I[2]);break;case f.OPS.setStrokeRGBColor:this.setStrokeRGBColor(I[0],I[1],I[2]);break;case f.OPS.setStrokeColorN:this.setStrokeColorN(I);break;case f.OPS.setFillColorN:this.setFillColorN(I);break;case f.OPS.shadingFill:this.shadingFill(I[0]);break;case f.OPS.setDash:this.setDash(I[0],I[1]);break;case f.OPS.setRenderingIntent:this.setRenderingIntent(I[0]);break;case f.OPS.setFlatness:this.setFlatness(I[0]);break;case f.OPS.setGState:this.setGState(I[0]);break;case f.OPS.fill:this.fill();break;case f.OPS.eoFill:this.eoFill();break;case f.OPS.stroke:this.stroke();break;case f.OPS.fillStroke:this.fillStroke();break;case f.OPS.eoFillStroke:this.eoFillStroke();break;case f.OPS.clip:this.clip("nonzero");break;case f.OPS.eoClip:this.clip("evenodd");break;case f.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case f.OPS.paintImageXObject:this.paintImageXObject(I[0]);break;case f.OPS.paintInlineImageXObject:this.paintInlineImageXObject(I[0]);break;case f.OPS.paintImageMaskXObject:this.paintImageMaskXObject(I[0]);break;case f.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(I[0],I[1]);break;case f.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case f.OPS.closePath:this.closePath();break;case f.OPS.closeStroke:this.closeStroke();break;case f.OPS.closeFillStroke:this.closeFillStroke();break;case f.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case f.OPS.nextLine:this.nextLine();break;case f.OPS.transform:this.transform(I[0],I[1],I[2],I[3],I[4],I[5]);break;case f.OPS.constructPath:this.constructPath(I[0],I[1]);break;case f.OPS.endPath:this.endPath();break;case 92:this.group(d.items);break;default:(0,f.warn)(`Unimplemented operator ${m}`)}}}setWordSpacing(c){this.current.wordSpacing=c}setCharSpacing(c){this.current.charSpacing=c}nextLine(){this.moveText(0,this.current.leading)}setTextMatrix(c,d,m,D,I,W){const G=this.current;G.textMatrix=G.lineMatrix=[c,d,m,D,I,W],G.textMatrixScale=Math.sqrt(c*c+d*d),G.x=G.lineX=0,G.y=G.lineY=0,G.xcoords=[],G.ycoords=[],G.tspan=this.svgFactory.createElement("svg:tspan"),G.tspan.setAttributeNS(null,"font-family",G.fontFamily),G.tspan.setAttributeNS(null,"font-size",`${A(G.fontSize)}px`),G.tspan.setAttributeNS(null,"y",A(-G.y)),G.txtElement=this.svgFactory.createElement("svg:text"),G.txtElement.appendChild(G.tspan)}beginText(){const c=this.current;c.x=c.lineX=0,c.y=c.lineY=0,c.textMatrix=f.IDENTITY_MATRIX,c.lineMatrix=f.IDENTITY_MATRIX,c.textMatrixScale=1,c.tspan=this.svgFactory.createElement("svg:tspan"),c.txtElement=this.svgFactory.createElement("svg:text"),c.txtgrp=this.svgFactory.createElement("svg:g"),c.xcoords=[],c.ycoords=[]}moveText(c,d){const m=this.current;m.x=m.lineX+=c,m.y=m.lineY+=d,m.xcoords=[],m.ycoords=[],m.tspan=this.svgFactory.createElement("svg:tspan"),m.tspan.setAttributeNS(null,"font-family",m.fontFamily),m.tspan.setAttributeNS(null,"font-size",`${A(m.fontSize)}px`),m.tspan.setAttributeNS(null,"y",A(-m.y))}showText(c){const d=this.current,m=d.font,D=d.fontSize;if(0===D)return;const I=d.fontSizeScale,W=d.charSpacing,G=d.wordSpacing,Y=d.fontDirection,Z=d.textHScale*Y,K=m.vertical,ce=K?1:-1,U=m.defaultVMetrics,y=D*d.fontMatrix[0];let L=0;for(const w of c){if(null===w){L+=Y*G;continue}if((0,f.isNum)(w)){L+=ce*w*D/1e3;continue}const C=(w.isSpace?G:0)+W,X=w.fontChar;let Q,ee,le,re=w.width;if(K){let de;const ge=w.vmetric||U;de=w.vmetric?ge[1]:.5*re,de=-de*y,re=ge?-ge[0]:re,Q=de/I,ee=(L+ge[2]*y)/I}else Q=L/I,ee=0;(w.isInFont||m.missingFile)&&(d.xcoords.push(d.x+Q),K&&d.ycoords.push(-d.y+ee),d.tspan.textContent+=X),le=K?re*y-C*Y:re*y+C*Y,L+=le}d.tspan.setAttributeNS(null,"x",d.xcoords.map(A).join(" ")),d.tspan.setAttributeNS(null,"y",K?d.ycoords.map(A).join(" "):A(-d.y)),K?d.y-=L:d.x+=L*Z,d.tspan.setAttributeNS(null,"font-family",d.fontFamily),d.tspan.setAttributeNS(null,"font-size",`${A(d.fontSize)}px`),d.fontStyle!==B.fontStyle&&d.tspan.setAttributeNS(null,"font-style",d.fontStyle),d.fontWeight!==B.fontWeight&&d.tspan.setAttributeNS(null,"font-weight",d.fontWeight);const P=d.textRenderingMode&f.TextRenderingMode.FILL_STROKE_MASK;P===f.TextRenderingMode.FILL||P===f.TextRenderingMode.FILL_STROKE?(d.fillColor!==B.fillColor&&d.tspan.setAttributeNS(null,"fill",d.fillColor),d.fillAlpha<1&&d.tspan.setAttributeNS(null,"fill-opacity",d.fillAlpha)):d.tspan.setAttributeNS(null,"fill",d.textRenderingMode===f.TextRenderingMode.ADD_TO_PATH?"transparent":"none"),(P===f.TextRenderingMode.STROKE||P===f.TextRenderingMode.FILL_STROKE)&&this._setStrokeAttributes(d.tspan,1/(d.textMatrixScale||1));let T=d.textMatrix;0!==d.textRise&&(T=T.slice(),T[5]+=d.textRise),d.txtElement.setAttributeNS(null,"transform",`${x(T)} scale(${A(Z)}, -1)`),d.txtElement.setAttributeNS(j,"xml:space","preserve"),d.txtElement.appendChild(d.tspan),d.txtgrp.appendChild(d.txtElement),this._ensureTransformGroup().appendChild(d.txtElement)}setLeadingMoveText(c,d){this.setLeading(-d),this.moveText(c,d)}addFontStyle(c){if(!c.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));const d=(0,f.createObjectURL)(c.data,c.mimetype,this.forceDataSchema);this.cssStyle.textContent+=`@font-face { font-family: "${c.loadedName}"; src: url(${d}); }\n`}setFont(c){const d=this.current,m=this.commonObjs.get(c[0]);let D=c[1];d.font=m,this.embedFonts&&!m.missingFile&&!this.embeddedFonts[m.loadedName]&&(this.addFontStyle(m),this.embeddedFonts[m.loadedName]=m),d.fontMatrix=m.fontMatrix?m.fontMatrix:f.FONT_IDENTITY_MATRIX;let I="normal";m.black?I="900":m.bold&&(I="bold");const W=m.italic?"italic":"normal";D<0?(D=-D,d.fontDirection=-1):d.fontDirection=1,d.fontSize=D,d.fontFamily=m.loadedName,d.fontWeight=I,d.fontStyle=W,d.tspan=this.svgFactory.createElement("svg:tspan"),d.tspan.setAttributeNS(null,"y",A(-d.y)),d.xcoords=[],d.ycoords=[]}endText(){const c=this.current;c.textRenderingMode&f.TextRenderingMode.ADD_TO_PATH_FLAG&&c.txtElement&&c.txtElement.hasChildNodes()&&(c.element=c.txtElement,this.clip("nonzero"),this.endPath())}setLineWidth(c){c>0&&(this.current.lineWidth=c)}setLineCap(c){this.current.lineCap=E[c]}setLineJoin(c){this.current.lineJoin=R[c]}setMiterLimit(c){this.current.miterLimit=c}setStrokeAlpha(c){this.current.strokeAlpha=c}setStrokeRGBColor(c,d,m){this.current.strokeColor=f.Util.makeCssRgb(c,d,m)}setFillAlpha(c){this.current.fillAlpha=c}setFillRGBColor(c,d,m){this.current.fillColor=f.Util.makeCssRgb(c,d,m),this.current.tspan=this.svgFactory.createElement("svg:tspan"),this.current.xcoords=[],this.current.ycoords=[]}setStrokeColorN(c){this.current.strokeColor=this._makeColorN_Pattern(c)}setFillColorN(c){this.current.fillColor=this._makeColorN_Pattern(c)}shadingFill(c){const d=this.viewport.width,m=this.viewport.height,D=f.Util.inverseTransform(this.transformMatrix),I=f.Util.applyTransform([0,0],D),W=f.Util.applyTransform([0,m],D),G=f.Util.applyTransform([d,0],D),Y=f.Util.applyTransform([d,m],D),Z=Math.min(I[0],W[0],G[0],Y[0]),K=Math.min(I[1],W[1],G[1],Y[1]),ce=Math.max(I[0],W[0],G[0],Y[0]),U=Math.max(I[1],W[1],G[1],Y[1]),y=this.svgFactory.createElement("svg:rect");y.setAttributeNS(null,"x",Z),y.setAttributeNS(null,"y",K),y.setAttributeNS(null,"width",ce-Z),y.setAttributeNS(null,"height",U-K),y.setAttributeNS(null,"fill",this._makeShadingPattern(c)),this.current.fillAlpha<1&&y.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().appendChild(y)}_makeColorN_Pattern(c){return"TilingPattern"===c[0]?this._makeTilingPattern(c):this._makeShadingPattern(c)}_makeTilingPattern(c){const d=c[1],m=c[2],D=c[3]||f.IDENTITY_MATRIX,[I,W,G,Y]=c[4],Z=c[5],K=c[6],ce=c[7],U="shading"+h++,[y,L]=f.Util.applyTransform([I,W],D),[P,T]=f.Util.applyTransform([G,Y],D),[w,C]=f.Util.singularValueDecompose2dScale(D),X=Z*w,Q=K*C,ee=this.svgFactory.createElement("svg:pattern");ee.setAttributeNS(null,"id",U),ee.setAttributeNS(null,"patternUnits","userSpaceOnUse"),ee.setAttributeNS(null,"width",X),ee.setAttributeNS(null,"height",Q),ee.setAttributeNS(null,"x",`${y}`),ee.setAttributeNS(null,"y",`${L}`);const re=this.svg,le=this.transformMatrix,de=this.current.fillColor,ge=this.current.strokeColor,pe=this.svgFactory.create(P-y,T-L);if(this.svg=pe,this.transformMatrix=D,2===ce){const Ae=f.Util.makeCssRgb(...d);this.current.fillColor=Ae,this.current.strokeColor=Ae}return this.executeOpTree(this.convertOpList(m)),this.svg=re,this.transformMatrix=le,this.current.fillColor=de,this.current.strokeColor=ge,ee.appendChild(pe.childNodes[0]),this.defs.appendChild(ee),`url(#${U})`}_makeShadingPattern(c){switch(c[0]){case"RadialAxial":const d="shading"+h++,m=c[3];let D;switch(c[1]){case"axial":const I=c[4],W=c[5];D=this.svgFactory.createElement("svg:linearGradient"),D.setAttributeNS(null,"id",d),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"x1",I[0]),D.setAttributeNS(null,"y1",I[1]),D.setAttributeNS(null,"x2",W[0]),D.setAttributeNS(null,"y2",W[1]);break;case"radial":const G=c[4],Y=c[5],Z=c[6],K=c[7];D=this.svgFactory.createElement("svg:radialGradient"),D.setAttributeNS(null,"id",d),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"cx",Y[0]),D.setAttributeNS(null,"cy",Y[1]),D.setAttributeNS(null,"r",K),D.setAttributeNS(null,"fx",G[0]),D.setAttributeNS(null,"fy",G[1]),D.setAttributeNS(null,"fr",Z);break;default:throw new Error(`Unknown RadialAxial type: ${c[1]}`)}for(const I of m){const W=this.svgFactory.createElement("svg:stop");W.setAttributeNS(null,"offset",I[0]),W.setAttributeNS(null,"stop-color",I[1]),D.appendChild(W)}return this.defs.appendChild(D),`url(#${d})`;case"Mesh":return(0,f.warn)("Unimplemented pattern Mesh"),null;case"Dummy":return"hotpink";default:throw new Error(`Unknown IR type: ${c[0]}`)}}setDash(c,d){this.current.dashArray=c,this.current.dashPhase=d}constructPath(c,d){const m=this.current;let D=m.x,I=m.y,W=[],G=0;for(const Y of c)switch(0|Y){case f.OPS.rectangle:D=d[G++],I=d[G++];const ce=D+d[G++],U=I+d[G++];W.push("M",A(D),A(I),"L",A(ce),A(I),"L",A(ce),A(U),"L",A(D),A(U),"Z");break;case f.OPS.moveTo:D=d[G++],I=d[G++],W.push("M",A(D),A(I));break;case f.OPS.lineTo:D=d[G++],I=d[G++],W.push("L",A(D),A(I));break;case f.OPS.curveTo:D=d[G+4],I=d[G+5],W.push("C",A(d[G]),A(d[G+1]),A(d[G+2]),A(d[G+3]),A(D),A(I)),G+=6;break;case f.OPS.curveTo2:W.push("C",A(D),A(I),A(d[G]),A(d[G+1]),A(d[G+2]),A(d[G+3])),D=d[G+2],I=d[G+3],G+=4;break;case f.OPS.curveTo3:D=d[G+2],I=d[G+3],W.push("C",A(d[G]),A(d[G+1]),A(D),A(I),A(D),A(I)),G+=4;break;case f.OPS.closePath:W.push("Z")}W=W.join(" "),m.path&&c.length>0&&c[0]!==f.OPS.rectangle&&c[0]!==f.OPS.moveTo?W=m.path.getAttributeNS(null,"d")+W:(m.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().appendChild(m.path)),m.path.setAttributeNS(null,"d",W),m.path.setAttributeNS(null,"fill","none"),m.element=m.path,m.setCurrentPoint(D,I)}endPath(){const c=this.current;if(c.path=null,!this.pendingClip)return;if(!c.element)return void(this.pendingClip=null);const d="clippath"+M++,m=this.svgFactory.createElement("svg:clipPath");m.setAttributeNS(null,"id",d),m.setAttributeNS(null,"transform",x(this.transformMatrix));const D=c.element.cloneNode(!0);D.setAttributeNS(null,"clip-rule","evenodd"===this.pendingClip?"evenodd":"nonzero"),this.pendingClip=null,m.appendChild(D),this.defs.appendChild(m),c.activeClipUrl&&(c.clipGroup=null,this.extraStack.forEach(function(I){I.clipGroup=null}),m.setAttributeNS(null,"clip-path",c.activeClipUrl)),c.activeClipUrl=`url(#${d})`,this.tgrp=null}clip(c){this.pendingClip=c}closePath(){const c=this.current;if(c.path){const d=`${c.path.getAttributeNS(null,"d")}Z`;c.path.setAttributeNS(null,"d",d)}}setLeading(c){this.current.leading=-c}setTextRise(c){this.current.textRise=c}setTextRenderingMode(c){this.current.textRenderingMode=c}setHScale(c){this.current.textHScale=c/100}setRenderingIntent(c){}setFlatness(c){}setGState(c){for(const[d,m]of c)switch(d){case"LW":this.setLineWidth(m);break;case"LC":this.setLineCap(m);break;case"LJ":this.setLineJoin(m);break;case"ML":this.setMiterLimit(m);break;case"D":this.setDash(m[0],m[1]);break;case"RI":this.setRenderingIntent(m);break;case"FL":this.setFlatness(m);break;case"Font":this.setFont(m);break;case"CA":this.setStrokeAlpha(m);break;case"ca":this.setFillAlpha(m);break;default:(0,f.warn)(`Unimplemented graphic state operator ${d}`)}}fill(){const c=this.current;c.element&&(c.element.setAttributeNS(null,"fill",c.fillColor),c.element.setAttributeNS(null,"fill-opacity",c.fillAlpha),this.endPath())}stroke(){const c=this.current;c.element&&(this._setStrokeAttributes(c.element),c.element.setAttributeNS(null,"fill","none"),this.endPath())}_setStrokeAttributes(c,d=1){const m=this.current;let D=m.dashArray;1!==d&&D.length>0&&(D=D.map(function(I){return d*I})),c.setAttributeNS(null,"stroke",m.strokeColor),c.setAttributeNS(null,"stroke-opacity",m.strokeAlpha),c.setAttributeNS(null,"stroke-miterlimit",A(m.miterLimit)),c.setAttributeNS(null,"stroke-linecap",m.lineCap),c.setAttributeNS(null,"stroke-linejoin",m.lineJoin),c.setAttributeNS(null,"stroke-width",A(d*m.lineWidth)+"px"),c.setAttributeNS(null,"stroke-dasharray",D.map(A).join(" ")),c.setAttributeNS(null,"stroke-dashoffset",A(d*m.dashPhase)+"px")}eoFill(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fill()}fillStroke(){this.stroke(),this.fill()}eoFillStroke(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fillStroke()}closeStroke(){this.closePath(),this.stroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.closePath(),this.eoFillStroke()}paintSolidColorImageMask(){const c=this.svgFactory.createElement("svg:rect");c.setAttributeNS(null,"x","0"),c.setAttributeNS(null,"y","0"),c.setAttributeNS(null,"width","1px"),c.setAttributeNS(null,"height","1px"),c.setAttributeNS(null,"fill",this.current.fillColor),this._ensureTransformGroup().appendChild(c)}paintImageXObject(c){const d=this.objs.get(c);d?this.paintInlineImageXObject(d):(0,f.warn)(`Dependent image with object ID ${c} is not ready yet`)}paintInlineImageXObject(c,d){const m=c.width,D=c.height,I=F(c,this.forceDataSchema,!!d),W=this.svgFactory.createElement("svg:rect");W.setAttributeNS(null,"x","0"),W.setAttributeNS(null,"y","0"),W.setAttributeNS(null,"width",A(m)),W.setAttributeNS(null,"height",A(D)),this.current.element=W,this.clip("nonzero");const G=this.svgFactory.createElement("svg:image");G.setAttributeNS(k,"xlink:href",I),G.setAttributeNS(null,"x","0"),G.setAttributeNS(null,"y",A(-D)),G.setAttributeNS(null,"width",A(m)+"px"),G.setAttributeNS(null,"height",A(D)+"px"),G.setAttributeNS(null,"transform",`scale(${A(1/m)} ${A(-1/D)})`),d?d.appendChild(G):this._ensureTransformGroup().appendChild(G)}paintImageMaskXObject(c){const d=this.current,m=c.width,D=c.height,I=d.fillColor;d.maskId="mask"+V++;const W=this.svgFactory.createElement("svg:mask");W.setAttributeNS(null,"id",d.maskId);const G=this.svgFactory.createElement("svg:rect");G.setAttributeNS(null,"x","0"),G.setAttributeNS(null,"y","0"),G.setAttributeNS(null,"width",A(m)),G.setAttributeNS(null,"height",A(D)),G.setAttributeNS(null,"fill",I),G.setAttributeNS(null,"mask",`url(#${d.maskId})`),this.defs.appendChild(W),this._ensureTransformGroup().appendChild(G),this.paintInlineImageXObject(c,W)}paintFormXObjectBegin(c,d){if(Array.isArray(c)&&6===c.length&&this.transform(c[0],c[1],c[2],c[3],c[4],c[5]),d){const m=d[2]-d[0],D=d[3]-d[1],I=this.svgFactory.createElement("svg:rect");I.setAttributeNS(null,"x",d[0]),I.setAttributeNS(null,"y",d[1]),I.setAttributeNS(null,"width",A(m)),I.setAttributeNS(null,"height",A(D)),this.current.element=I,this.clip("nonzero"),this.endPath()}}paintFormXObjectEnd(){}_initialize(c){const d=this.svgFactory.create(c.width,c.height),m=this.svgFactory.createElement("svg:defs");d.appendChild(m),this.defs=m;const D=this.svgFactory.createElement("svg:g");return D.setAttributeNS(null,"transform",x(c.transform)),d.appendChild(D),this.svg=D,d}_ensureClipGroup(){if(!this.current.clipGroup){const c=this.svgFactory.createElement("svg:g");c.setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.appendChild(c),this.current.clipGroup=c}return this.current.clipGroup}_ensureTransformGroup(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",x(this.transformMatrix)),this.current.activeClipUrl?this._ensureClipGroup().appendChild(this.tgrp):this.svg.appendChild(this.tgrp)),this.tgrp}}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.PDFNodeStream=void 0;var f=z(2),H=z(20);const N=__webpack_require__(172),q=__webpack_require__(1),B=__webpack_require__(779),j=__webpack_require__(558),k=/^file:\/\/\/[a-zA-Z]:\//;v.PDFNodeStream=class R{constructor(p){this.source=p,this.url=function E(h){const p=j.parse(h);return"file:"===p.protocol||p.host?p:/^[a-z]:[/\\]/i.test(h)?j.parse(`file:///${h}`):(p.host||(p.protocol="file:"),p)}(p.url),this.isHttp="http:"===this.url.protocol||"https:"===this.url.protocol,this.isFsUrl="file:"===this.url.protocol,this.httpHeaders=this.isHttp&&p.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?this._fullRequestReader._loaded:0}getFullReader(){return(0,f.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new M(this):new A(this),this._fullRequestReader}getRangeReader(p,c){if(c<=this._progressiveDataLength)return null;const d=this.isFsUrl?new V(this,p,c):new x(this,p,c);return this._rangeRequestReaders.push(d),d}cancelAllRequests(p){this._fullRequestReader&&this._fullRequestReader.cancel(p),this._rangeRequestReaders.slice(0).forEach(function(d){d.cancel(p)})}};class F{constructor(p){this._url=p.url,this._done=!1,this._storedError=null,this.onProgress=null;const c=p.source;this._contentLength=c.length,this._loaded=0,this._filename=null,this._disableRange=c.disableRange||!1,this._rangeChunkSize=c.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!c.disableStream,this._isRangeSupported=!c.disableRange,this._readableStream=null,this._readCapability=(0,f.createPromiseCapability)(),this._headersCapability=(0,f.createPromiseCapability)()}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}read(){var p=this;return _asyncToGenerator(function*(){if(yield p._readCapability.promise,p._done)return{value:void 0,done:!0};if(p._storedError)throw p._storedError;const c=p._readableStream.read();return null===c?(p._readCapability=(0,f.createPromiseCapability)(),p.read()):(p._loaded+=c.length,p.onProgress&&p.onProgress({loaded:p._loaded,total:p._contentLength}),{value:new Uint8Array(c).buffer,done:!1})})()}cancel(p){this._readableStream?this._readableStream.destroy(p):this._error(p)}_error(p){this._storedError=p,this._readCapability.resolve()}_setReadableStream(p){this._readableStream=p,p.on("readable",()=>{this._readCapability.resolve()}),p.on("end",()=>{p.destroy(),this._done=!0,this._readCapability.resolve()}),p.on("error",c=>{this._error(c)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new f.AbortException("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class _{constructor(p){this._url=p.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=(0,f.createPromiseCapability)(),this._isStreamingSupported=!p.source.disableStream}get isStreamingSupported(){return this._isStreamingSupported}read(){var p=this;return _asyncToGenerator(function*(){if(yield p._readCapability.promise,p._done)return{value:void 0,done:!0};if(p._storedError)throw p._storedError;const c=p._readableStream.read();return null===c?(p._readCapability=(0,f.createPromiseCapability)(),p.read()):(p._loaded+=c.length,p.onProgress&&p.onProgress({loaded:p._loaded}),{value:new Uint8Array(c).buffer,done:!1})})()}cancel(p){this._readableStream?this._readableStream.destroy(p):this._error(p)}_error(p){this._storedError=p,this._readCapability.resolve()}_setReadableStream(p){this._readableStream=p,p.on("readable",()=>{this._readCapability.resolve()}),p.on("end",()=>{p.destroy(),this._done=!0,this._readCapability.resolve()}),p.on("error",c=>{this._error(c)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function b(h,p){return{protocol:h.protocol,auth:h.auth,host:h.hostname,port:h.port,path:h.path,method:"GET",headers:p}}class A extends F{constructor(p){super(p);const c=d=>{if(404===d.statusCode){const W=new f.MissingPDFException(`Missing PDF "${this._url}".`);return this._storedError=W,void this._headersCapability.reject(W)}this._headersCapability.resolve(),this._setReadableStream(d);const m=W=>this._readableStream.headers[W.toLowerCase()],{allowRangeRequests:D,suggestedLength:I}=(0,H.validateRangeRequestCapabilities)({getResponseHeader:m,isHttp:p.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=D,this._contentLength=I||this._contentLength,this._filename=(0,H.extractFilenameFromHeader)(m)};this._request=null,this._request="http:"===this._url.protocol?q.request(b(this._url,p.httpHeaders),c):B.request(b(this._url,p.httpHeaders),c),this._request.on("error",d=>{this._storedError=d,this._headersCapability.reject(d)}),this._request.end()}}class x extends _{constructor(p,c,d){super(p),this._httpHeaders={};for(const D in p.httpHeaders){const I=p.httpHeaders[D];void 0!==I&&(this._httpHeaders[D]=I)}this._httpHeaders.Range=`bytes=${c}-${d-1}`;const m=D=>{if(404!==D.statusCode)this._setReadableStream(D);else{const I=new f.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=I}};this._request=null,this._request="http:"===this._url.protocol?q.request(b(this._url,this._httpHeaders),m):B.request(b(this._url,this._httpHeaders),m),this._request.on("error",D=>{this._storedError=D}),this._request.end()}}class M extends F{constructor(p){super(p);let c=decodeURIComponent(this._url.path);k.test(this._url.href)&&(c=c.replace(/^\//,"")),N.lstat(c,(d,m)=>{if(d)return"ENOENT"===d.code&&(d=new f.MissingPDFException(`Missing PDF "${c}".`)),this._storedError=d,void this._headersCapability.reject(d);this._contentLength=m.size,this._setReadableStream(N.createReadStream(c)),this._headersCapability.resolve()})}}class V extends _{constructor(p,c,d){super(p);let m=decodeURIComponent(this._url.path);k.test(this._url.href)&&(m=m.replace(/^\//,"")),this._setReadableStream(N.createReadStream(m,{start:c,end:d-1}))}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.createResponseStatusError=function B(k,E){return 404===k||0===k&&E.startsWith("file:")?new f.MissingPDFException('Missing PDF "'+E+'".'):new f.UnexpectedResponseException("Unexpected server response ("+k+') while retrieving PDF "'+E+'".',k)},v.extractFilenameFromHeader=function q(k){const E=k("Content-Disposition");if(E){let R=(0,H.getFilenameFromContentDispositionHeader)(E);if(R.includes("%"))try{R=decodeURIComponent(R)}catch(F){}if(/\.pdf$/i.test(R))return R}return null},v.validateRangeRequestCapabilities=function N({getResponseHeader:k,isHttp:E,rangeChunkSize:R,disableRange:F}){(0,f.assert)(R>0,"Range chunk size must be larger than zero");const _={allowRangeRequests:!1,suggestedLength:void 0},b=parseInt(k("Content-Length"),10);return!Number.isInteger(b)||(_.suggestedLength=b,b<=2*R)||F||!E||"bytes"!==k("Accept-Ranges")||"identity"!==(k("Content-Encoding")||"identity")||(_.allowRangeRequests=!0),_},v.validateResponseStatus=function j(k){return 200===k||206===k};var f=z(2),H=z(21)},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.getFilenameFromContentDispositionHeader=function f(H){let N=!0,q=B("filename\\*","i").exec(H);if(q){q=q[1];let b=R(q);return b=unescape(b),b=F(b),b=_(b),k(b)}if(q=function E(b){const A=[];let x;const M=B("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;null!==(x=M.exec(b));){let[,h,p,c]=x;if(h=parseInt(h,10),h in A){if(0===h)break}else A[h]=[p,c]}const V=[];for(let h=0;h<A.length&&h in A;++h){let[p,c]=A[h];c=R(c),p&&(c=unescape(c),0===h&&(c=F(c))),V.push(c)}return V.join("")}(H),q)return k(_(q));if(q=B("filename","i").exec(H),q){q=q[1];let b=R(q);return b=_(b),k(b)}function B(b,A){return new RegExp("(?:^|;)\\s*"+b+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',A)}function j(b,A){if(b){if(!/^[\x00-\xFF]+$/.test(A))return A;try{const x=new TextDecoder(b,{fatal:!0}),M=Array.from(A,function(V){return 255&V.charCodeAt(0)});A=x.decode(new Uint8Array(M)),N=!1}catch(x){if(/^utf-?8$/i.test(b))try{A=decodeURIComponent(escape(A)),N=!1}catch(M){}}}return A}function k(b){return N&&/[\x80-\xff]/.test(b)&&(b=j("utf-8",b),N&&(b=j("iso-8859-1",b))),b}function R(b){if(b.startsWith('"')){const A=b.slice(1).split('\\"');for(let x=0;x<A.length;++x){const M=A[x].indexOf('"');-1!==M&&(A[x]=A[x].slice(0,M),A.length=x+1),A[x]=A[x].replace(/\\(.)/g,"$1")}b=A.join('"')}return b}function F(b){const A=b.indexOf("'");return-1===A?b:j(b.slice(0,A),b.slice(A+1).replace(/^[^']*'/,""))}function _(b){return!b.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(b)?b:b.replace(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(A,x,M,V){if("q"===M||"Q"===M)return j(x,V=(V=V.replace(/_/g," ")).replace(/=([0-9a-fA-F]{2})/g,function(h,p){return String.fromCharCode(parseInt(p,16))}));try{V=atob(V)}catch(h){}return j(x,V)})}return""}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.PDFNetworkStream=void 0;var f=z(2),H=z(20);class j{constructor(_,b){this.url=_,b=b||{},this.isHttp=/^https?:/i.test(_),this.httpHeaders=this.isHttp&&b.httpHeaders||{},this.withCredentials=b.withCredentials||!1,this.getXhr=b.getXhr||function(){return new XMLHttpRequest},this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(_,b,A){const x={begin:_,end:b};for(const M in A)x[M]=A[M];return this.request(x)}requestFull(_){return this.request(_)}request(_){const b=this.getXhr(),A=this.currXhrId++,x=this.pendingRequests[A]={xhr:b};b.open("GET",this.url),b.withCredentials=this.withCredentials;for(const M in this.httpHeaders){const V=this.httpHeaders[M];void 0!==V&&b.setRequestHeader(M,V)}return this.isHttp&&"begin"in _&&"end"in _?(b.setRequestHeader("Range",`bytes=${_.begin}-${_.end-1}`),x.expectedStatus=206):x.expectedStatus=200,b.responseType="arraybuffer",_.onError&&(b.onerror=function(M){_.onError(b.status)}),b.onreadystatechange=this.onStateChange.bind(this,A),b.onprogress=this.onProgress.bind(this,A),x.onHeadersReceived=_.onHeadersReceived,x.onDone=_.onDone,x.onError=_.onError,x.onProgress=_.onProgress,b.send(null),A}onProgress(_,b){const A=this.pendingRequests[_];!A||A.onProgress&&A.onProgress(b)}onStateChange(_,b){const A=this.pendingRequests[_];if(!A)return;const x=A.xhr;if(x.readyState>=2&&A.onHeadersReceived&&(A.onHeadersReceived(),delete A.onHeadersReceived),4!==x.readyState||!(_ in this.pendingRequests))return;if(delete this.pendingRequests[_],0===x.status&&this.isHttp)return void(A.onError&&A.onError(x.status));const M=x.status||200;if((200!==M||206!==A.expectedStatus)&&M!==A.expectedStatus)return void(A.onError&&A.onError(x.status));const h=function B(F){const _=F.response;return"string"!=typeof _?_:(0,f.stringToBytes)(_).buffer}(x);if(206===M){const p=x.getResponseHeader("Content-Range"),c=/bytes (\d+)-(\d+)\/(\d+)/.exec(p);A.onDone({begin:parseInt(c[1],10),chunk:h})}else h?A.onDone({begin:0,chunk:h}):A.onError&&A.onError(x.status)}hasPendingRequests(){for(const _ in this.pendingRequests)return!0;return!1}getRequestXhr(_){return this.pendingRequests[_].xhr}isPendingRequest(_){return _ in this.pendingRequests}abortAllRequests(){for(const _ in this.pendingRequests)this.abortRequest(0|_)}abortRequest(_){const b=this.pendingRequests[_].xhr;delete this.pendingRequests[_],b.abort()}}v.PDFNetworkStream=class k{constructor(_){this._source=_,this._manager=new j(_.url,{httpHeaders:_.httpHeaders,withCredentials:_.withCredentials}),this._rangeChunkSize=_.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(_){const b=this._rangeRequestReaders.indexOf(_);b>=0&&this._rangeRequestReaders.splice(b,1)}getFullReader(){return(0,f.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new E(this._manager,this._source),this._fullRequestReader}getRangeReader(_,b){const A=new R(this._manager,_,b);return A.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(A),A}cancelAllRequests(_){this._fullRequestReader&&this._fullRequestReader.cancel(_),this._rangeRequestReaders.slice(0).forEach(function(A){A.cancel(_)})}};class E{constructor(_,b){this._manager=_;const A={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=b.url,this._fullRequestId=_.requestFull(A),this._headersReceivedCapability=(0,f.createPromiseCapability)(),this._disableRange=b.disableRange||!1,this._contentLength=b.length,this._rangeChunkSize=b.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}_onHeadersReceived(){const _=this._fullRequestId,b=this._manager.getRequestXhr(_),A=V=>b.getResponseHeader(V),{allowRangeRequests:x,suggestedLength:M}=(0,H.validateRangeRequestCapabilities)({getResponseHeader:A,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});x&&(this._isRangeSupported=!0),this._contentLength=M||this._contentLength,this._filename=(0,H.extractFilenameFromHeader)(A),this._isRangeSupported&&this._manager.abortRequest(_),this._headersReceivedCapability.resolve()}_onDone(_){_&&(this._requests.length>0?this._requests.shift().resolve({value:_.chunk,done:!1}):this._cachedChunks.push(_.chunk)),this._done=!0,!(this._cachedChunks.length>0)&&(this._requests.forEach(function(b){b.resolve({value:void 0,done:!0})}),this._requests=[])}_onError(_){const A=(0,H.createResponseStatusError)(_,this._url);this._storedError=A,this._headersReceivedCapability.reject(A),this._requests.forEach(function(x){x.reject(A)}),this._requests=[],this._cachedChunks=[]}_onProgress(_){this.onProgress&&this.onProgress({loaded:_.loaded,total:_.lengthComputable?_.total:this._contentLength})}get filename(){return this._filename}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}get contentLength(){return this._contentLength}get headersReady(){return this._headersReceivedCapability.promise}read(){var _=this;return _asyncToGenerator(function*(){if(_._storedError)throw _._storedError;if(_._cachedChunks.length>0)return{value:_._cachedChunks.shift(),done:!1};if(_._done)return{value:void 0,done:!0};const b=(0,f.createPromiseCapability)();return _._requests.push(b),b.promise})()}cancel(_){this._done=!0,this._headersReceivedCapability.reject(_),this._requests.forEach(function(b){b.resolve({value:void 0,done:!0})}),this._requests=[],this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class R{constructor(_,b,A){this._manager=_;const x={onDone:this._onDone.bind(this),onProgress:this._onProgress.bind(this)};this._requestId=_.requestRange(b,A,x),this._requests=[],this._queuedChunk=null,this._done=!1,this.onProgress=null,this.onClosed=null}_close(){this.onClosed&&this.onClosed(this)}_onDone(_){const b=_.chunk;this._requests.length>0?this._requests.shift().resolve({value:b,done:!1}):this._queuedChunk=b,this._done=!0,this._requests.forEach(function(A){A.resolve({value:void 0,done:!0})}),this._requests=[],this._close()}_onProgress(_){!this.isStreamingSupported&&this.onProgress&&this.onProgress({loaded:_.loaded})}get isStreamingSupported(){return!1}read(){var _=this;return _asyncToGenerator(function*(){if(null!==_._queuedChunk){const A=_._queuedChunk;return _._queuedChunk=null,{value:A,done:!1}}if(_._done)return{value:void 0,done:!0};const b=(0,f.createPromiseCapability)();return _._requests.push(b),b.promise})()}cancel(_){this._done=!0,this._requests.forEach(function(b){b.resolve({value:void 0,done:!0})}),this._requests=[],this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}},function(we,v,z){"use strict";Object.defineProperty(v,"__esModule",{value:!0}),v.PDFFetchStream=void 0;var f=z(2),H=z(20);function N(E,R,F){return{method:"GET",headers:E,signal:F&&F.signal,mode:"cors",credentials:R?"include":"same-origin",redirect:"follow"}}function q(E){const R=new Headers;for(const F in E){const _=E[F];void 0!==_&&R.append(F,_)}return R}v.PDFFetchStream=class B{constructor(R){this.source=R,this.isHttp=/^https?:/i.test(R.url),this.httpHeaders=this.isHttp&&R.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?this._fullRequestReader._loaded:0}getFullReader(){return(0,f.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new j(this),this._fullRequestReader}getRangeReader(R,F){if(F<=this._progressiveDataLength)return null;const _=new k(this,R,F);return this._rangeRequestReaders.push(_),_}cancelAllRequests(R){this._fullRequestReader&&this._fullRequestReader.cancel(R),this._rangeRequestReaders.slice(0).forEach(function(_){_.cancel(R)})}};class j{constructor(R){this._stream=R,this._reader=null,this._loaded=0,this._filename=null;const F=R.source;this._withCredentials=F.withCredentials||!1,this._contentLength=F.length,this._headersCapability=(0,f.createPromiseCapability)(),this._disableRange=F.disableRange||!1,this._rangeChunkSize=F.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._isStreamingSupported=!F.disableStream,this._isRangeSupported=!F.disableRange,this._headers=q(this._stream.httpHeaders);const _=F.url;fetch(_,N(this._headers,this._withCredentials,this._abortController)).then(b=>{if(!(0,H.validateResponseStatus)(b.status))throw(0,H.createResponseStatusError)(b.status,_);this._reader=b.body.getReader(),this._headersCapability.resolve();const A=V=>b.headers.get(V),{allowRangeRequests:x,suggestedLength:M}=(0,H.validateRangeRequestCapabilities)({getResponseHeader:A,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=x,this._contentLength=M||this._contentLength,this._filename=(0,H.extractFilenameFromHeader)(A),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new f.AbortException("Streaming is disabled."))}).catch(this._headersCapability.reject),this.onProgress=null}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}read(){var R=this;return _asyncToGenerator(function*(){yield R._headersCapability.promise;const{value:F,done:_}=yield R._reader.read();return _?{value:F,done:_}:(R._loaded+=F.byteLength,R.onProgress&&R.onProgress({loaded:R._loaded,total:R._contentLength}),{value:new Uint8Array(F).buffer,done:!1})})()}cancel(R){this._reader&&this._reader.cancel(R),this._abortController&&this._abortController.abort()}}class k{constructor(R,F,_){this._stream=R,this._reader=null,this._loaded=0;const b=R.source;this._withCredentials=b.withCredentials||!1,this._readCapability=(0,f.createPromiseCapability)(),this._isStreamingSupported=!b.disableStream,"undefined"!=typeof AbortController&&(this._abortController=new AbortController),this._headers=q(this._stream.httpHeaders),this._headers.append("Range",`bytes=${F}-${_-1}`);const A=b.url;fetch(A,N(this._headers,this._withCredentials,this._abortController)).then(x=>{if(!(0,H.validateResponseStatus)(x.status))throw(0,H.createResponseStatusError)(x.status,A);this._readCapability.resolve(),this._reader=x.body.getReader()}),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}read(){var R=this;return _asyncToGenerator(function*(){yield R._readCapability.promise;const{value:F,done:_}=yield R._reader.read();return _?{value:F,done:_}:(R._loaded+=F.byteLength,R.onProgress&&R.onProgress({loaded:R._loaded}),{value:new Uint8Array(F).buffer,done:!1})})()}cancel(R){this._reader&&this._reader.cancel(R),this._abortController&&this._abortController.abort()}}}])},module.exports=z()},813:function(we,v,z){var f=z(926).default;we.exports=function(H){var N={};function q(B){if(N[B])return N[B].exports;var j=N[B]={i:B,l:!1,exports:{}};return H[B].call(j.exports,j,j.exports,q),j.l=!0,j.exports}return q.m=H,q.c=N,q.d=function(B,j,k){q.o(B,j)||Object.defineProperty(B,j,{enumerable:!0,get:k})},q.r=function(B){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(B,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(B,"__esModule",{value:!0})},q.t=function(B,j){if(1&j&&(B=q(B)),8&j||4&j&&"object"==typeof B&&B&&B.__esModule)return B;var k=Object.create(null);if(q.r(k),Object.defineProperty(k,"default",{enumerable:!0,value:B}),2&j&&"string"!=typeof B)for(var E in B)q.d(k,E,function(R){return B[R]}.bind(null,E));return k},q.n=function(B){var j=B&&B.__esModule?function(){return B.default}:function(){return B};return q.d(j,"a",j),j},q.o=function(B,j){return Object.prototype.hasOwnProperty.call(B,j)},q.p="",q(q.s=0)}([function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),Object.defineProperty(N,"AnnotationLayerBuilder",{enumerable:!0,get:function(){return B.AnnotationLayerBuilder}}),Object.defineProperty(N,"DefaultAnnotationLayerFactory",{enumerable:!0,get:function(){return B.DefaultAnnotationLayerFactory}}),Object.defineProperty(N,"DefaultTextLayerFactory",{enumerable:!0,get:function(){return j.DefaultTextLayerFactory}}),Object.defineProperty(N,"TextLayerBuilder",{enumerable:!0,get:function(){return j.TextLayerBuilder}}),Object.defineProperty(N,"EventBus",{enumerable:!0,get:function(){return k.EventBus}}),Object.defineProperty(N,"NullL10n",{enumerable:!0,get:function(){return k.NullL10n}}),Object.defineProperty(N,"ProgressBar",{enumerable:!0,get:function(){return k.ProgressBar}}),Object.defineProperty(N,"PDFLinkService",{enumerable:!0,get:function(){return E.PDFLinkService}}),Object.defineProperty(N,"SimpleLinkService",{enumerable:!0,get:function(){return E.SimpleLinkService}}),Object.defineProperty(N,"DownloadManager",{enumerable:!0,get:function(){return R.DownloadManager}}),Object.defineProperty(N,"GenericL10n",{enumerable:!0,get:function(){return F.GenericL10n}}),Object.defineProperty(N,"PDFFindController",{enumerable:!0,get:function(){return _.PDFFindController}}),Object.defineProperty(N,"PDFHistory",{enumerable:!0,get:function(){return b.PDFHistory}}),Object.defineProperty(N,"PDFPageView",{enumerable:!0,get:function(){return A.PDFPageView}}),Object.defineProperty(N,"PDFSinglePageViewer",{enumerable:!0,get:function(){return x.PDFSinglePageViewer}}),Object.defineProperty(N,"PDFViewer",{enumerable:!0,get:function(){return M.PDFViewer}});var B=q(1),j=q(5),k=q(3),E=q(4),R=q(6),F=q(8),_=q(10),b=q(12),A=q(13),x=q(15),M=q(17)},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.DefaultAnnotationLayerFactory=N.AnnotationLayerBuilder=void 0;var B=q(2),j=q(3),k=q(4);class E{constructor({pageDiv:_,pdfPage:b,linkService:A,downloadManager:x,imageResourcesPath:M="",renderInteractiveForms:V=!1,l10n:h=j.NullL10n}){this.pageDiv=_,this.pdfPage=b,this.linkService=A,this.downloadManager=x,this.imageResourcesPath=M,this.renderInteractiveForms=V,this.l10n=h,this.div=null,this._cancelled=!1}render(_,b="display"){this.pdfPage.getAnnotations({intent:b}).then(A=>{if(this._cancelled)return;const x={viewport:_.clone({dontFlip:!0}),div:this.div,annotations:A,page:this.pdfPage,imageResourcesPath:this.imageResourcesPath,renderInteractiveForms:this.renderInteractiveForms,linkService:this.linkService,downloadManager:this.downloadManager};if(this.div)B.AnnotationLayer.update(x);else{if(0===A.length)return;this.div=document.createElement("div"),this.div.className="annotationLayer",this.pageDiv.appendChild(this.div),x.div=this.div,B.AnnotationLayer.render(x),this.l10n.translate(this.div)}})}cancel(){this._cancelled=!0}hide(){!this.div||this.div.setAttribute("hidden","true")}}N.AnnotationLayerBuilder=E;N.DefaultAnnotationLayerFactory=class R{createAnnotationLayerBuilder(_,b,A="",x=!1,M=j.NullL10n){return new E({pageDiv:_,pdfPage:b,imageResourcesPath:A,renderInteractiveForms:x,linkService:new k.SimpleLinkService,l10n:M})}}},function(H,N,q){"use strict";let B;B="undefined"!=typeof window&&window["pdfjs-dist/build/pdf"]?window["pdfjs-dist/build/pdf"]:z(36),H.exports=B},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.isValidRotation=function C(te){return Number.isInteger(te)&&te%90==0},N.isValidScrollMode=function X(te){return Number.isInteger(te)&&Object.values(h).includes(te)&&te!==h.UNKNOWN},N.isValidSpreadMode=function Q(te){return Number.isInteger(te)&&Object.values(p).includes(te)&&te!==p.UNKNOWN},N.isPortraitOrientation=function ee(te){return te.width<=te.height},N.clamp=Ae,N.getPDFFileNameFromURL=function T(te,ie="document.pdf"){if("string"!=typeof te)return ie;if(function P(te){let ie=0;const ye=te.length;for(;ie<ye&&""===te[ie].trim();)ie++;return"data:"===te.substring(ie,ie+5).toLowerCase()}(te))return console.warn('getPDFFileNameFromURL: ignoring "data:" URL for performance reasons.'),ie;const he=/[^\/?#=]+\.pdf\b(?!.*\.pdf\b)/i,_e=/^(?:(?:[^:]+:)?\/\/[^\/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/.exec(te);let be=he.exec(_e[1])||he.exec(_e[2])||he.exec(_e[3]);if(be&&(be=be[0],be.includes("%")))try{be=he.exec(decodeURIComponent(be))[0]}catch(Se){}return be||ie},N.noContextMenuHandler=function L(te){te.preventDefault()},N.parseQueryString=function G(te){const ie=te.split("&"),ye=Object.create(null);for(let he=0,_e=ie.length;he<_e;++he){const be=ie[he].split("="),Se=be[0].toLowerCase(),Ne=be.length>1?be[1]:null;ye[decodeURIComponent(Se)]=decodeURIComponent(Ne)}return ye},N.backtrackBeforeAllVisibleElements=U,N.getVisibleElements=function y(te,ie,ye=!1,he=!1){const _e=te.scrollTop,be=_e+te.clientHeight,Se=te.scrollLeft,Ne=Se+te.clientWidth;const _t=[],Vt=ie.length;let ut=0===Vt?0:Y(ie,he?function lt(jt){const ue=jt.div;return ue.offsetLeft+ue.clientLeft+ue.clientWidth>Se}:function qe(jt){const ue=jt.div;return ue.offsetTop+ue.clientTop+ue.clientHeight>_e});ut>0&&ut<Vt&&!he&&(ut=U(ut,ie,_e));let $t=he?Ne:-1;for(let jt=ut;jt<Vt;jt++){const ue=ie[jt],ne=ue.div,ae=ne.offsetLeft+ne.clientLeft,Pe=ne.offsetTop+ne.clientTop,Be=ne.clientWidth,Je=ne.clientHeight,Qe=ae+Be,gt=Pe+Je;if(-1===$t)gt>=be&&($t=gt);else if((he?ae:Pe)>$t)break;if(gt<=_e||Pe>=be||Qe<=Se||ae>=Ne)continue;const Ke=Math.max(0,_e-Pe)+Math.max(0,gt-be),Qn=Math.max(0,Se-ae)+Math.max(0,Qe-Ne);_t.push({id:ue.id,x:ae,y:Pe,view:ue,percent:(Je-Ke)*(Be-Qn)*100/Je/Be|0})}const Nn=_t[0],_r=_t[_t.length-1];return ye&&_t.sort(function(jt,ue){const ne=jt.percent-ue.percent;return Math.abs(ne)>.001?-ne:jt.id-ue.id}),{first:Nn,last:_r,views:_t}},N.roundToDivide=function K(te,ie){const ye=te%ie;return 0===ye?te:Math.round(te-ye+ie)},N.getPageSizeInches=function ce({view:te,userUnit:ie,rotate:ye}){const[he,_e,be,Se]=te,Ne=ye%180!=0,qe=(be-he)/72*ie,lt=(Se-_e)/72*ie;return{width:Ne?lt:qe,height:Ne?qe:lt}},N.approximateFraction=function Z(te){if(Math.floor(te)===te)return[te,1];const ie=1/te;if(ie>8)return[1,8];if(Math.floor(ie)===ie)return[1,ie];const he=te>1?ie:te;let qe,_e=0,be=1,Se=1,Ne=1;for(;;){const lt=_e+Se,_t=be+Ne;if(_t>8)break;he<=lt/_t?(Se=lt,Ne=_t):(_e=lt,be=_t)}return qe=he-_e/be<Se/Ne-he?he===te?[_e,be]:[be,_e]:he===te?[Se,Ne]:[Ne,Se],qe},N.getOutputScale=function D(te){const he=(window.devicePixelRatio||1)/(te.webkitBackingStorePixelRatio||te.mozBackingStorePixelRatio||te.msBackingStorePixelRatio||te.oBackingStorePixelRatio||te.backingStorePixelRatio||1);return{sx:he,sy:he,scaled:1!==he}},N.scrollIntoView=function I(te,ie,ye=!1){let he=te.offsetParent;if(!he)return void console.error("offsetParent is not set -- cannot scroll");let _e=te.offsetTop+te.clientTop,be=te.offsetLeft+te.clientLeft;for(;he.clientHeight===he.scrollHeight&&he.clientWidth===he.scrollWidth||ye&&"hidden"===getComputedStyle(he).overflow;)if(he.dataset._scaleY&&(_e/=he.dataset._scaleY,be/=he.dataset._scaleX),_e+=he.offsetTop,be+=he.offsetLeft,he=he.offsetParent,!he)return;ie&&(void 0!==ie.top&&(_e+=ie.top),void 0!==ie.left&&(be+=ie.left,he.scrollLeft=be)),he.scrollTop=_e},N.watchScroll=function W(te,ie){const ye=function(be){_e||(_e=window.requestAnimationFrame(function(){_e=null;const Ne=te.scrollLeft,qe=he.lastX;Ne!==qe&&(he.right=Ne>qe),he.lastX=Ne;const lt=te.scrollTop,_t=he.lastY;lt!==_t&&(he.down=lt>_t),he.lastY=lt,ie(he)}))},he={right:!0,down:!0,lastX:te.scrollLeft,lastY:te.scrollTop,_eventHandler:ye};let _e=null;return te.addEventListener("scroll",ye,!0),he},N.binarySearchFirstItem=Y,N.normalizeWheelEventDelta=function w(te){let ie=Math.sqrt(te.deltaX*te.deltaX+te.deltaY*te.deltaY);const ye=Math.atan2(te.deltaY,te.deltaX);-.25*Math.PI<ye&&ye<.75*Math.PI&&(ie=-ie);return 0===te.deltaMode?ie/=900:1===te.deltaMode&&(ie/=30),ie},N.waitOnEventOrTimeout=function le({target:te,name:ie,delay:ye=0}){return new Promise(function(he,_e){if("object"!=typeof te||!ie||"string"!=typeof ie||!(Number.isInteger(ye)&&ye>=0))throw new Error("waitOnEventOrTimeout - invalid parameters.");function be(lt){te instanceof pe?te._off(ie,Se):te.removeEventListener(ie,Se),qe&&clearTimeout(qe),he(lt)}const Se=be.bind(null,re.EVENT);te instanceof pe?te._on(ie,Se):te.addEventListener(ie,Se);const Ne=be.bind(null,re.TIMEOUT),qe=setTimeout(Ne,ye)})},N.moveToEndOfArray=function xe(te,ie){const ye=[],he=te.length;let _e=0;for(let be=0;be<he;++be)ie(te[be])?ye.push(te[be]):(te[_e]=te[be],++_e);for(let be=0;_e<he;++be,++_e)te[_e]=ye[be]},N.WaitOnType=N.animationStarted=N.ProgressBar=N.EventBus=N.NullL10n=N.SpreadMode=N.ScrollMode=N.TextLayerMode=N.RendererType=N.PresentationModeState=N.VERTICAL_PADDING=N.SCROLLBAR_PADDING=N.MAX_AUTO_SCALE=N.UNKNOWN_SCALE=N.MAX_SCALE=N.MIN_SCALE=N.DEFAULT_SCALE=N.DEFAULT_SCALE_VALUE=N.CSS_UNITS=N.AutoPrintRegExp=void 0,N.CSS_UNITS=96/72,N.DEFAULT_SCALE_VALUE="auto",N.DEFAULT_SCALE=1,N.MIN_SCALE=.1,N.MAX_SCALE=10,N.UNKNOWN_SCALE=0,N.MAX_AUTO_SCALE=1.25,N.SCROLLBAR_PADDING=40,N.VERTICAL_PADDING=5,N.PresentationModeState={UNKNOWN:0,NORMAL:1,CHANGING:2,FULLSCREEN:3},N.RendererType={CANVAS:"canvas",SVG:"svg"},N.TextLayerMode={DISABLE:0,ENABLE:1,ENABLE_ENHANCE:2};const h={UNKNOWN:-1,VERTICAL:0,HORIZONTAL:1,WRAPPED:2};N.ScrollMode=h;const p={UNKNOWN:-1,NONE:0,ODD:1,EVEN:2};function Y(te,ie){let ye=0,he=te.length-1;if(he<0||!ie(te[he]))return te.length;if(ie(te[ye]))return ye;for(;ye<he;){const _e=ye+he>>1;ie(te[_e])?he=_e:ye=_e+1}return ye}function U(te,ie,ye){if(te<2)return te;let he=ie[te].div,_e=he.offsetTop+he.clientTop;_e>=ye&&(he=ie[te-1].div,_e=he.offsetTop+he.clientTop);for(let be=te-2;be>=0&&(he=ie[be].div,!(he.offsetTop+he.clientTop+he.clientHeight<=_e));--be)te=be;return te}N.SpreadMode=p,N.AutoPrintRegExp=/\bprint\s*\(/,N.NullL10n={getLanguage:()=>f(function*(){return"en-us"})(),getDirection:()=>f(function*(){return"ltr"})(),get:(te,ie,ye)=>f(function*(){return function d(te,ie){return ie?te.replace(/\{\{\s*(\w+)\s*\}\}/g,(ye,he)=>he in ie?ie[he]:"{{"+he+"}}"):te}(ye,ie)})(),translate:te=>f(function*(){})()};const re={EVENT:"event",TIMEOUT:"timeout"};N.WaitOnType=re;const de=new Promise(function(te){window.requestAnimationFrame(te)});N.animationStarted=de;class pe{constructor(ie){this._listeners=Object.create(null)}on(ie,ye){this._on(ie,ye,{external:!0})}off(ie,ye){this._off(ie,ye,{external:!0})}dispatch(ie){const ye=this._listeners[ie];if(!ye||0===ye.length)return;const he=Array.prototype.slice.call(arguments,1);let _e;ye.slice(0).forEach(function({listener:be,external:Se}){if(Se)return _e||(_e=[]),void _e.push(be);be.apply(null,he)}),_e&&(_e.forEach(function(be){be.apply(null,he)}),_e=null)}_on(ie,ye,he=null){let _e=this._listeners[ie];_e||(this._listeners[ie]=_e=[]),_e.push({listener:ye,external:!0===(he&&he.external)})}_off(ie,ye,he=null){const _e=this._listeners[ie];if(_e)for(let be=0,Se=_e.length;be<Se;be++)if(_e[be].listener===ye)return void _e.splice(be,1)}}function Ae(te,ie,ye){return Math.min(Math.max(te,ie),ye)}N.EventBus=pe;N.ProgressBar=class Ce{constructor(ie,{height:ye,width:he,units:_e}={}){this.visible=!0,this.div=document.querySelector(ie+" .progress"),this.bar=this.div.parentNode,this.height=ye||100,this.width=he||100,this.units=_e||"%",this.div.style.height=this.height+this.units,this.percent=0}_updateBar(){if(this._indeterminate)return this.div.classList.add("indeterminate"),void(this.div.style.width=this.width+this.units);this.div.classList.remove("indeterminate"),this.div.style.width=this.width*this._percent/100+this.units}get percent(){return this._percent}set percent(ie){this._indeterminate=isNaN(ie),this._percent=Ae(ie,0,100),this._updateBar()}setWidth(ie){if(!ie)return;const he=ie.parentNode.offsetWidth-ie.offsetWidth;he>0&&(this.bar.style.width=`calc(100% - ${he}px)`)}hide(){!this.visible||(this.visible=!1,this.bar.classList.add("hidden"),document.body.classList.remove("loadingInProgress"))}show(){this.visible||(this.visible=!0,document.body.classList.add("loadingInProgress"),this.bar.classList.remove("hidden"))}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.SimpleLinkService=N.PDFLinkService=void 0;var B=q(3);N.PDFLinkService=class j{constructor({eventBus:F,externalLinkTarget:_=null,externalLinkRel:b=null,externalLinkEnabled:A=!0,ignoreDestinationZoom:x=!1}={}){this.eventBus=F,this.externalLinkTarget=_,this.externalLinkRel=b,this.externalLinkEnabled=A,this._ignoreDestinationZoom=x,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null,this._pagesRefCache=null}setDocument(F,_=null){this.baseUrl=_,this.pdfDocument=F,this._pagesRefCache=Object.create(null)}setViewer(F){this.pdfViewer=F}setHistory(F){this.pdfHistory=F}get pagesCount(){return this.pdfDocument?this.pdfDocument.numPages:0}get page(){return this.pdfViewer.currentPageNumber}set page(F){this.pdfViewer.currentPageNumber=F}get rotation(){return this.pdfViewer.pagesRotation}set rotation(F){this.pdfViewer.pagesRotation=F}navigateTo(F){const _=({namedDest:b,explicitDest:A})=>{const x=A[0];let M;if(x instanceof Object){if(M=this._cachedPageNumber(x),null===M)return void this.pdfDocument.getPageIndex(x).then(V=>{this.cachePageRef(V+1,x),_({namedDest:b,explicitDest:A})}).catch(()=>{console.error(`PDFLinkService.navigateTo: "${x}" is not a valid page reference, for dest="${F}".`)})}else{if(!Number.isInteger(x))return void console.error(`PDFLinkService.navigateTo: "${x}" is not a valid destination reference, for dest="${F}".`);M=x+1}!M||M<1||M>this.pagesCount?console.error(`PDFLinkService.navigateTo: "${M}" is not a valid page number, for dest="${F}".`):(this.pdfHistory&&(this.pdfHistory.pushCurrentPosition(),this.pdfHistory.push({namedDest:b,explicitDest:A,pageNumber:M})),this.pdfViewer.scrollPageIntoView({pageNumber:M,destArray:A,ignoreDestinationZoom:this._ignoreDestinationZoom}))};new Promise((b,A)=>{"string"!=typeof F?b({namedDest:"",explicitDest:F}):this.pdfDocument.getDestination(F).then(x=>{b({namedDest:F,explicitDest:x})})}).then(b=>{Array.isArray(b.explicitDest)?_(b):console.error(`PDFLinkService.navigateTo: "${b.explicitDest}" is not a valid destination array, for dest="${F}".`)})}getDestinationHash(F){if("string"==typeof F)return this.getAnchorUrl("#"+escape(F));if(Array.isArray(F)){const _=JSON.stringify(F);return this.getAnchorUrl("#"+escape(_))}return this.getAnchorUrl("")}getAnchorUrl(F){return(this.baseUrl||"")+F}setHash(F){let _,b;if(F.includes("=")){const A=(0,B.parseQueryString)(F);if("search"in A&&this.eventBus.dispatch("findfromurlhash",{source:this,query:A.search.replace(/"/g,""),phraseSearch:"true"===A.phrase}),"page"in A&&(_=0|A.page||1),"zoom"in A){const x=A.zoom.split(","),M=x[0],V=parseFloat(M);M.includes("Fit")?"Fit"===M||"FitB"===M?b=[null,{name:M}]:"FitH"===M||"FitBH"===M||"FitV"===M||"FitBV"===M?b=[null,{name:M},x.length>1?0|x[1]:null]:"FitR"===M?5!==x.length?console.error('PDFLinkService.setHash: Not enough parameters for "FitR".'):b=[null,{name:M},0|x[1],0|x[2],0|x[3],0|x[4]]:console.error(`PDFLinkService.setHash: "${M}" is not a valid zoom value.`):b=[null,{name:"XYZ"},x.length>1?0|x[1]:null,x.length>2?0|x[2]:null,V?V/100:M]}b?this.pdfViewer.scrollPageIntoView({pageNumber:_||this.page,destArray:b,allowNegativeOffset:!0}):_&&(this.page=_),"pagemode"in A&&this.eventBus.dispatch("pagemode",{source:this,mode:A.pagemode}),"nameddest"in A&&this.navigateTo(A.nameddest)}else{b=unescape(F);try{b=JSON.parse(b),Array.isArray(b)||(b=b.toString())}catch(A){}if("string"==typeof b||function k(R){if(!Array.isArray(R))return!1;const F=R.length;if(F<2)return!1;const _=R[0];if(!("object"==typeof _&&Number.isInteger(_.num)&&Number.isInteger(_.gen)||Number.isInteger(_)&&_>=0))return!1;const b=R[1];if("object"!=typeof b||"string"!=typeof b.name)return!1;let A=!0;switch(b.name){case"XYZ":if(5!==F)return!1;break;case"Fit":case"FitB":return 2===F;case"FitH":case"FitBH":case"FitV":case"FitBV":if(3!==F)return!1;break;case"FitR":if(6!==F)return!1;A=!1;break;default:return!1}for(let x=2;x<F;x++){const M=R[x];if(!("number"==typeof M||A&&null===M))return!1}return!0}(b))return void this.navigateTo(b);console.error(`PDFLinkService.setHash: "${unescape(F)}" is not a valid destination.`)}}executeNamedAction(F){switch(F){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":this.page>1&&this.page--;break;case"LastPage":this.page=this.pagesCount;break;case"FirstPage":this.page=1}this.eventBus.dispatch("namedaction",{source:this,action:F})}cachePageRef(F,_){_&&(this._pagesRefCache[0===_.gen?`${_.num}R`:`${_.num}R${_.gen}`]=F)}_cachedPageNumber(F){return this._pagesRefCache&&this._pagesRefCache[0===F.gen?`${F.num}R`:`${F.num}R${F.gen}`]||null}isPageVisible(F){return this.pdfViewer.isPageVisible(F)}};N.SimpleLinkService=class E{constructor(){this.externalLinkTarget=null,this.externalLinkRel=null,this.externalLinkEnabled=!0,this._ignoreDestinationZoom=!1}get pagesCount(){return 0}get page(){return 0}set page(F){}get rotation(){return 0}set rotation(F){}navigateTo(F){}getDestinationHash(F){return"#"}getAnchorUrl(F){return"#"}setHash(F){}executeNamedAction(F){}cachePageRef(F,_){}isPageVisible(F){return!0}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.DefaultTextLayerFactory=N.TextLayerBuilder=void 0;var B=q(2);class k{constructor({textLayerDiv:F,eventBus:_,pageIndex:b,viewport:A,findController:x=null,enhanceTextSelection:M=!1}){this.textLayerDiv=F,this.eventBus=_,this.textContent=null,this.textContentItemsStr=[],this.textContentStream=null,this.renderingDone=!1,this.pageIdx=b,this.pageNumber=this.pageIdx+1,this.matches=[],this.viewport=A,this.textDivs=[],this.findController=x,this.textLayerRenderTask=null,this.enhanceTextSelection=M,this._onUpdateTextLayerMatches=null,this._bindMouse()}_finishRendering(){if(this.renderingDone=!0,!this.enhanceTextSelection){const F=document.createElement("div");F.className="endOfContent",this.textLayerDiv.appendChild(F)}this.eventBus.dispatch("textlayerrendered",{source:this,pageNumber:this.pageNumber,numTextDivs:this.textDivs.length})}render(F=0){if(!this.textContent&&!this.textContentStream||this.renderingDone)return;this.cancel(),this.textDivs=[];const _=document.createDocumentFragment();this.textLayerRenderTask=(0,B.renderTextLayer)({textContent:this.textContent,textContentStream:this.textContentStream,container:_,viewport:this.viewport,textDivs:this.textDivs,textContentItemsStr:this.textContentItemsStr,timeout:F,enhanceTextSelection:this.enhanceTextSelection}),this.textLayerRenderTask.promise.then(()=>{this.textLayerDiv.appendChild(_),this._finishRendering(),this._updateMatches()},function(b){}),this._onUpdateTextLayerMatches||(this._onUpdateTextLayerMatches=b=>{(b.pageIndex===this.pageIdx||-1===b.pageIndex)&&this._updateMatches()},this.eventBus._on("updatetextlayermatches",this._onUpdateTextLayerMatches))}cancel(){this.textLayerRenderTask&&(this.textLayerRenderTask.cancel(),this.textLayerRenderTask=null),this._onUpdateTextLayerMatches&&(this.eventBus._off("updatetextlayermatches",this._onUpdateTextLayerMatches),this._onUpdateTextLayerMatches=null)}setTextContentStream(F){this.cancel(),this.textContentStream=F}setTextContent(F){this.cancel(),this.textContent=F}_convertMatches(F,_){if(!F)return[];const{findController:b,textContentItemsStr:A}=this;let x=0,M=0;const V=A.length-1,h=b.state.query.length,p=[];for(let c=0,d=F.length;c<d;c++){let m=F[c];for(;x!==V&&m>=M+A[x].length;)M+=A[x].length,x++;x===A.length&&console.error("Could not find a matching mapping");const D={begin:{divIdx:x,offset:m-M}};for(m+=_?_[c]:h;x!==V&&m>M+A[x].length;)M+=A[x].length,x++;D.end={divIdx:x,offset:m-M},p.push(D)}return p}_renderMatches(F){if(0===F.length)return;const{findController:_,pageIdx:b,textContentItemsStr:A,textDivs:x}=this,M=b===_.selected.pageIdx,V=_.selected.matchIdx;let p=null;const c_offset=void 0;function d(W,G){const Y=W.divIdx;x[Y].textContent="",m(Y,0,W.offset,G)}function m(W,G,Y,Z){const K=x[W],ce=A[W].substring(G,Y),U=document.createTextNode(ce);if(Z){const y=document.createElement("span");return y.className=Z,y.appendChild(U),void K.appendChild(y)}K.appendChild(U)}let D=V,I=D+1;if(_.state.highlightAll)D=0,I=F.length;else if(!M)return;for(let W=D;W<I;W++){const G=F[W],Y=G.begin,Z=G.end,K=M&&W===V,ce=K?" selected":"";if(K&&_.scrollMatchIntoView({element:x[Y.divIdx],pageIndex:b,matchIndex:V}),p&&Y.divIdx===p.divIdx?m(p.divIdx,p.offset,Y.offset):(null!==p&&m(p.divIdx,p.offset,c_offset),d(Y)),Y.divIdx===Z.divIdx)m(Y.divIdx,Y.offset,Z.offset,"highlight"+ce);else{m(Y.divIdx,Y.offset,c_offset,"highlight begin"+ce);for(let U=Y.divIdx+1,y=Z.divIdx;U<y;U++)x[U].className="highlight middle"+ce;d(Z,"highlight end"+ce)}p=Z}p&&m(p.divIdx,p.offset,c_offset)}_updateMatches(){if(!this.renderingDone)return;const{findController:F,matches:_,pageIdx:b,textContentItemsStr:A,textDivs:x}=this;let M=-1;for(let p=0,c=_.length;p<c;p++){const d=_[p];for(let D=Math.max(M,d.begin.divIdx),I=d.end.divIdx;D<=I;D++){const W=x[D];W.textContent=A[D],W.className=""}M=d.end.divIdx+1}F&&F.highlightMatches&&(this.matches=this._convertMatches(F.pageMatches[b]||null,F.pageMatchesLength[b]||null),this._renderMatches(this.matches))}_bindMouse(){const F=this.textLayerDiv;let _=null;F.addEventListener("mousedown",b=>{if(this.enhanceTextSelection&&this.textLayerRenderTask)return this.textLayerRenderTask.expandTextDivs(!0),void(_&&(clearTimeout(_),_=null));const A=F.querySelector(".endOfContent");if(!A)return;let x=b.target!==F;if(x=x&&"none"!==window.getComputedStyle(A).getPropertyValue("-moz-user-select"),x){const M=F.getBoundingClientRect(),V=Math.max(0,(b.pageY-M.top)/M.height);A.style.top=(100*V).toFixed(2)+"%"}A.classList.add("active")}),F.addEventListener("mouseup",()=>{if(this.enhanceTextSelection&&this.textLayerRenderTask)return void(_=setTimeout(()=>{this.textLayerRenderTask&&this.textLayerRenderTask.expandTextDivs(!1),_=null},300));const b=F.querySelector(".endOfContent");!b||(b.style.top="",b.classList.remove("active"))})}}N.TextLayerBuilder=k;N.DefaultTextLayerFactory=class E{createTextLayerBuilder(F,_,b,A=!1,x){return new k({textLayerDiv:F,pageIndex:_,viewport:b,enhanceTextSelection:A,eventBus:x})}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.DownloadManager=void 0;var B=q(2);const k=q(7).viewerCompatibilityParams.disableCreateObjectURL||!1;function E(F,_){const b=document.createElement("a");if(!b.click)throw new Error('DownloadManager: "a.click()" is not supported.');b.href=F,b.target="_parent","download"in b&&(b.download=_),(document.body||document.documentElement).appendChild(b),b.click(),b.remove()}N.DownloadManager=class R{constructor({disableCreateObjectURL:_=k}){this.disableCreateObjectURL=_}downloadUrl(_,b){!(0,B.createValidAbsoluteUrl)(_,"http://example.com")||E(_+"#pdfjs.action=download",b)}downloadData(_,b,A){navigator.msSaveBlob?navigator.msSaveBlob(new Blob([_],{type:A}),b):E((0,B.createObjectURL)(_,A,this.disableCreateObjectURL),b)}download(_,b,A){navigator.msSaveBlob?navigator.msSaveBlob(_,A)||this.downloadUrl(b,A):this.disableCreateObjectURL?this.downloadUrl(b,A):E(URL.createObjectURL(_),A)}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.viewerCompatibilityParams=void 0;const B=Object.create(null);{const k="undefined"!=typeof navigator&&navigator.userAgent||"",E="undefined"!=typeof navigator&&navigator.platform||"",R="undefined"!=typeof navigator&&navigator.maxTouchPoints||1,F=/Android/.test(k),_=/Trident/.test(k),b=/\b(iPad|iPhone|iPod)(?=;)/.test(k)||"MacIntel"===E&&R>1,A=/CriOS/.test(k);(_||A)&&(B.disableCreateObjectURL=!0),(b||F)&&(B.maxCanvasPixels=5242880)}const j=Object.freeze(B);N.viewerCompatibilityParams=j},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.GenericL10n=void 0,q(9);const B=document.webL10n;N.GenericL10n=class j{constructor(E){this._lang=E,this._ready=new Promise((R,F)=>{B.setLanguage(E,()=>{R(B)})})}getLanguage(){var E=this;return f(function*(){return(yield E._ready).getLanguage()})()}getDirection(){var E=this;return f(function*(){return(yield E._ready).getDirection()})()}get(E,R,F){var _=this;return f(function*(){return(yield _._ready).get(E,R,F)})()}translate(E){var R=this;return f(function*(){return(yield R._ready).translate(E)})()}}},function(H,N,q){"use strict";document.webL10n=function(B,j,k){var E={},R="",F="textContent",_="",b={},A="loading";function c(U,y,L){y=y||function(w){},L=L||function(){};var P=new XMLHttpRequest;P.open("GET",U,true),P.overrideMimeType&&P.overrideMimeType("text/plain; charset=utf-8"),P.onreadystatechange=function(){4==P.readyState&&(200==P.status||0===P.status?y(P.responseText):L())},P.onerror=L,P.ontimeout=L;try{P.send(null)}catch(T){L()}}function d(U,y,L,P){var T=U.replace(/[^\/]*$/,"")||"./";function w(X){return X.lastIndexOf("\\")<0?X:X.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,"'")}c(U,function(X){R+=X,function C(X,Q){var ee={},re=/^\s*|\s*$/,le=/^\s*#|^\s*$/,de=/^\s*\[(.*)\]\s*$/,ge=/^\s*@import\s+url\((.*)\)\s*$/i,pe=/^([^=\s]*)\s*=\s*(.+)$/;function Ae(xe,te,ie){var ye=xe.replace(re,"").split(/[\r\n]+/),he="*",_e=y.split("-",1)[0],be=!1,Se="";!function Ne(){for(;;){if(!ye.length)return void ie();var qe=ye.shift();if(!le.test(qe)){if(te){if(Se=de.exec(qe)){he=Se[1].toLowerCase(),be="*"!==he&&he!==y&&he!==_e;continue}if(be)continue;if(Se=ge.exec(qe))return void Ce(T+Se[1],Ne)}var lt=qe.match(pe);lt&&3==lt.length&&(ee[lt[1]]=w(lt[2]))}}}()}function Ce(xe,te){c(xe,function(ie){Ae(ie,!1,te)},function(){console.warn(xe+" not found."),te()})}Ae(X,!0,function(){Q(ee)})}(X,function(Q){for(var ee in Q){var re,le,de=ee.lastIndexOf(".");de>0?(re=ee.substring(0,de),le=ee.substring(de+1)):(re=ee,le=F),E[re]||(E[re]={}),E[re][le]=Q[ee]}L&&L()})},P)}function m(U,y){U&&(U=U.toLowerCase()),y=y||function(){},function D(){E={},R="",_=""}(),_=U;var L=function M(){return j.querySelectorAll('link[type="application/l10n"]')}(),P=L.length;if(0!==P){var X,Q=0;X=function(){++Q>=P&&(y(),A="complete")};for(var re=0;re<P;re++)new ee(L[re]).load(U,X)}else{var T=function V(){var U=j.querySelector('script[type="application/l10n"]');return U?JSON.parse(U.innerHTML):null}();if(T&&T.locales&&T.default_locale){if(console.log("using the embedded JSON directory, early way out"),!(E=T.locales[U])){var w=T.default_locale.toLowerCase();for(var C in T.locales){if((C=C.toLowerCase())===U){E=T.locales[U];break}C===w&&(E=T.locales[w])}}y()}else console.log("no resource to load, early way out");A="complete"}function ee(de){var ge=de.href;this.load=function(pe,Ae){d(ge,pe,Ae,function(){console.warn(ge+" not found."),console.warn('"'+pe+'" resource not found'),_="",Ae()})}}}function W(U,y,L){var P=E[U];if(!P){if(console.warn("#"+U+" is undefined."),!L)return null;P=L}var T={};for(var w in P){var C=P[w];C=Y(C=G(C,y,U,w),y,U),T[w]=C}return T}function G(U,y,L,P){var w=/\{\[\s*([a-zA-Z]+)\(([a-zA-Z]+)\)\s*\]\}/.exec(U);if(!w||!w.length)return U;var Q,C=w[1],X=w[2];return y&&X in y?Q=y[X]:X in E&&(Q=E[X]),C in b&&(U=(0,b[C])(U,Q,L,P)),U}function Y(U,y,L){return U.replace(/\{\{\s*(.+?)\s*\}\}/g,function(T,w){return y&&w in y?y[w]:w in E?E[w]:(console.log("argument {{"+w+"}} for #"+L+" is undefined."),T)})}function Z(U){var y=function p(U){if(!U)return{};var y=U.getAttribute("data-l10n-id"),L=U.getAttribute("data-l10n-args"),P={};if(L)try{P=JSON.parse(L)}catch(T){console.warn("could not parse arguments for #"+y)}return{id:y,args:P}}(U);if(y.id){var L=W(y.id,y.args);if(!L)return void console.warn("#"+y.id+" is undefined.");if(L[F]){if(0===function K(U){if(U.children)return U.children.length;if(void 0!==U.childElementCount)return U.childElementCount;for(var y=0,L=0;L<U.childNodes.length;L++)y+=1===U.nodeType?1:0;return y}(U))U[F]=L[F];else{for(var P=U.childNodes,T=!1,w=0,C=P.length;w<C;w++)3===P[w].nodeType&&/\S/.test(P[w].nodeValue)&&(T?P[w].nodeValue="":(P[w].nodeValue=L[F],T=!0));if(!T){var X=j.createTextNode(L[F]);U.insertBefore(X,U.firstChild)}}delete L[F]}for(var Q in L)U[Q]=L[Q]}}return b.plural=function(U,y,L,P){var T=parseFloat(y);if(isNaN(T)||P!=F)return U;b._pluralRules||(b._pluralRules=function I(U){function L(C,X){return-1!==X.indexOf(C)}function P(C,X,Q){return X<=C&&C<=Q}var T={0:function(C){return"other"},1:function(C){return P(C%100,3,10)?"few":0===C?"zero":P(C%100,11,99)?"many":2==C?"two":1==C?"one":"other"},2:function(C){return 0!==C&&C%10==0?"many":2==C?"two":1==C?"one":"other"},3:function(C){return 1==C?"one":"other"},4:function(C){return P(C,0,1)?"one":"other"},5:function(C){return P(C,0,2)&&2!=C?"one":"other"},6:function(C){return 0===C?"zero":C%10==1&&C%100!=11?"one":"other"},7:function(C){return 2==C?"two":1==C?"one":"other"},8:function(C){return P(C,3,6)?"few":P(C,7,10)?"many":2==C?"two":1==C?"one":"other"},9:function(C){return 0===C||1!=C&&P(C%100,1,19)?"few":1==C?"one":"other"},10:function(C){return P(C%10,2,9)&&!P(C%100,11,19)?"few":C%10!=1||P(C%100,11,19)?"other":"one"},11:function(C){return P(C%10,2,4)&&!P(C%100,12,14)?"few":C%10==0||P(C%10,5,9)||P(C%100,11,14)?"many":C%10==1&&C%100!=11?"one":"other"},12:function(C){return P(C,2,4)?"few":1==C?"one":"other"},13:function(C){return P(C%10,2,4)&&!P(C%100,12,14)?"few":1!=C&&P(C%10,0,1)||P(C%10,5,9)||P(C%100,12,14)?"many":1==C?"one":"other"},14:function(C){return P(C%100,3,4)?"few":C%100==2?"two":C%100==1?"one":"other"},15:function(C){return 0===C||P(C%100,2,10)?"few":P(C%100,11,19)?"many":1==C?"one":"other"},16:function(C){return C%10==1&&11!=C?"one":"other"},17:function(C){return 3==C?"few":0===C?"zero":6==C?"many":2==C?"two":1==C?"one":"other"},18:function(C){return 0===C?"zero":P(C,0,2)&&0!==C&&2!=C?"one":"other"},19:function(C){return P(C,2,10)?"few":P(C,0,1)?"one":"other"},20:function(C){return!P(C%10,3,4)&&C%10!=9||P(C%100,10,19)||P(C%100,70,79)||P(C%100,90,99)?C%1e6==0&&0!==C?"many":C%10!=2||L(C%100,[12,72,92])?C%10!=1||L(C%100,[11,71,91])?"other":"one":"two":"few"},21:function(C){return 0===C?"zero":1==C?"one":"other"},22:function(C){return P(C,0,1)||P(C,11,99)?"one":"other"},23:function(C){return P(C%10,1,2)||C%20==0?"one":"other"},24:function(C){return P(C,3,10)||P(C,13,19)?"few":L(C,[2,12])?"two":L(C,[1,11])?"one":"other"}},w={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}[U.replace(/-.*$/,"")];return w in T?T[w]:(console.warn("plural form unknown for ["+U+"]"),function(){return"other"})}(_));var w="["+b._pluralRules(T)+"]";return 0===T&&L+"[zero]"in E?U=E[L+"[zero]"][P]:1==T&&L+"[one]"in E?U=E[L+"[one]"][P]:2==T&&L+"[two]"in E?U=E[L+"[two]"][P]:L+w in E?U=E[L+w][P]:L+"[other]"in E&&(U=E[L+"[other]"][P]),U},{get:function(U,y,L){var w,P=U.lastIndexOf("."),T=F;P>0&&(T=U.substring(P+1),U=U.substring(0,P)),L&&((w={})[T]=L);var C=W(U,y,w);return C&&T in C?C[T]:"{{"+U+"}}"},getData:function(){return E},getText:function(){return R},getLanguage:function(){return _},setLanguage:function(U,y){m(U,function(){y&&y()})},getDirection:function(){var y=_.split("-",1)[0];return["ar","he","fa","ps","ur"].indexOf(y)>=0?"rtl":"ltr"},translate:function ce(U){for(var y=function h(U){return U?U.querySelectorAll("*[data-l10n-id]"):[]}(U=U||j.documentElement),L=y.length,P=0;P<L;P++)Z(y[P]);Z(U)},getReadyState:function(){return A},ready:function(U){U&&("complete"==A||"interactive"==A?B.setTimeout(function(){U()}):j.addEventListener&&j.addEventListener("localized",function y(){j.removeEventListener("localized",y),U()}))}}}(window,document)},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.PDFFindController=N.FindState=void 0;var B=q(2),j=q(11),k=q(3);const E={FOUND:0,NOT_FOUND:1,WRAPPED:2,PENDING:3};N.FindState=E;const b={"\u2018":"'","\u2019":"'","\u201a":"'","\u201b":"'","\u201c":'"',"\u201d":'"',"\u201e":'"',"\u201f":'"',"\xbc":"1/4","\xbd":"1/2","\xbe":"3/4"};let A=null;function x(V){if(!A){const h=Object.keys(b).join("");A=new RegExp(`[${h}]`,"g")}return V.replace(A,function(h){return b[h]})}N.PDFFindController=class M{constructor({linkService:h,eventBus:p}){this._linkService=h,this._eventBus=p,this._reset(),p._on("findbarclose",this._onFindBarClose.bind(this))}get highlightMatches(){return this._highlightMatches}get pageMatches(){return this._pageMatches}get pageMatchesLength(){return this._pageMatchesLength}get selected(){return this._selected}get state(){return this._state}setDocument(h){this._pdfDocument&&this._reset(),h&&(this._pdfDocument=h,this._firstPageCapability.resolve())}executeCommand(h,p){if(!p)return;const c=this._pdfDocument;(null===this._state||this._shouldDirtyMatch(h,p))&&(this._dirtyMatch=!0),this._state=p,"findhighlightallchange"!==h&&this._updateUIState(E.PENDING),this._firstPageCapability.promise.then(()=>{if(!this._pdfDocument||c&&this._pdfDocument!==c)return;this._extractText();const d=!this._highlightMatches,m=!!this._findTimeout;this._findTimeout&&(clearTimeout(this._findTimeout),this._findTimeout=null),"find"===h?this._findTimeout=setTimeout(()=>{this._nextMatch(),this._findTimeout=null},250):this._dirtyMatch?this._nextMatch():"findagain"===h?(this._nextMatch(),d&&this._state.highlightAll&&this._updateAllPages()):"findhighlightallchange"===h?(m?this._nextMatch():this._highlightMatches=!0,this._updateAllPages()):this._nextMatch()})}scrollMatchIntoView({element:h=null,pageIndex:p=-1,matchIndex:c=-1}){this._scrollMatches&&h&&-1!==c&&c===this._selected.matchIdx&&-1!==p&&p===this._selected.pageIdx&&(this._scrollMatches=!1,(0,k.scrollIntoView)(h,{top:-50,left:-400},!0))}_reset(){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,B.createPromiseCapability)()}get _query(){return this._state.query!==this._rawQuery&&(this._rawQuery=this._state.query,this._normalizedQuery=x(this._state.query)),this._normalizedQuery}_shouldDirtyMatch(h,p){if(p.query!==this._state.query)return!0;switch(h){case"findagain":const c=this._selected.pageIdx+1,d=this._linkService;return c>=1&&c<=d.pagesCount&&c!==d.page&&!d.isPageVisible(c);case"findhighlightallchange":return!1}return!0}_prepareMatches(h,p,c){function d(m){const D=h[m];if(m<h.length-1&&D.match===h[m+1].match)return D.skipped=!0,!0;for(let W=m-1;W>=0;W--){const G=h[W];if(!G.skipped){if(G.match+G.matchLength<D.match)break;if(G.match+G.matchLength>=D.match+D.matchLength)return D.skipped=!0,!0}}return!1}h.sort(function(m,D){return m.match===D.match?m.matchLength-D.matchLength:m.match-D.match});for(let m=0,D=h.length;m<D;m++)d(m)||(p.push(h[m].match),c.push(h[m].matchLength))}_isEntireWord(h,p,c){if(p>0){const m=h.charCodeAt(p),D=h.charCodeAt(p-1);if((0,j.getCharacterType)(m)===(0,j.getCharacterType)(D))return!1}const d=p+c-1;if(d<h.length-1){const m=h.charCodeAt(d),D=h.charCodeAt(d+1);if((0,j.getCharacterType)(m)===(0,j.getCharacterType)(D))return!1}return!0}_calculatePhraseMatch(h,p,c,d){const m=[],D=h.length;let I=-D;for(;I=c.indexOf(h,I+D),-1!==I;)d&&!this._isEntireWord(c,I,D)||m.push(I);this._pageMatches[p]=m}_calculateWordMatch(h,p,c,d){const m=[],D=h.match(/\S+/g);for(let I=0,W=D.length;I<W;I++){const G=D[I],Y=G.length;let Z=-Y;for(;Z=c.indexOf(G,Z+Y),-1!==Z;)d&&!this._isEntireWord(c,Z,Y)||m.push({match:Z,matchLength:Y,skipped:!1})}this._pageMatchesLength[p]=[],this._pageMatches[p]=[],this._prepareMatches(m,this._pageMatches[p],this._pageMatchesLength[p])}_calculateMatch(h){let p=this._pageContents[h],c=this._query;const{caseSensitive:d,entireWord:m,phraseSearch:D}=this._state;if(0===c.length)return;d||(p=p.toLowerCase(),c=c.toLowerCase()),D?this._calculatePhraseMatch(c,h,p,m):this._calculateWordMatch(c,h,p,m),this._state.highlightAll&&this._updatePage(h),this._resumePageIdx===h&&(this._resumePageIdx=null,this._nextPageMatch());const I=this._pageMatches[h].length;I>0&&(this._matchesCountTotal+=I,this._updateUIResultsCount())}_extractText(){if(this._extractTextPromises.length>0)return;let h=Promise.resolve();for(let p=0,c=this._linkService.pagesCount;p<c;p++){const d=(0,B.createPromiseCapability)();this._extractTextPromises[p]=d.promise,h=h.then(()=>this._pdfDocument.getPage(p+1).then(m=>m.getTextContent({normalizeWhitespace:!0})).then(m=>{const D=m.items,I=[];for(let W=0,G=D.length;W<G;W++)I.push(D[W].str);this._pageContents[p]=x(I.join("")),d.resolve(p)},m=>{console.error(`Unable to get text content for page ${p+1}`,m),this._pageContents[p]="",d.resolve(p)}))}}_updatePage(h){this._scrollMatches&&this._selected.pageIdx===h&&(this._linkService.page=h+1),this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:h})}_updateAllPages(){this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:-1})}_nextMatch(){const h=this._state.findPrevious,p=this._linkService.page-1,c=this._linkService.pagesCount;if(this._highlightMatches=!0,this._dirtyMatch){this._dirtyMatch=!1,this._selected.pageIdx=this._selected.matchIdx=-1,this._offset.pageIdx=p,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(let m=0;m<c;m++)!0!==this._pendingFindMatches[m]&&(this._pendingFindMatches[m]=!0,this._extractTextPromises[m].then(D=>{delete this._pendingFindMatches[D],this._calculateMatch(D)}))}if(""===this._query)return void this._updateUIState(E.FOUND);if(this._resumePageIdx)return;const d=this._offset;if(this._pagesToSearch=c,null!==d.matchIdx){const m=this._pageMatches[d.pageIdx].length;if(!h&&d.matchIdx+1<m||h&&d.matchIdx>0)return d.matchIdx=h?d.matchIdx-1:d.matchIdx+1,void this._updateMatch(!0);this._advanceOffsetPage(h)}this._nextPageMatch()}_matchesReady(h){const p=this._offset,c=h.length,d=this._state.findPrevious;return c?(p.matchIdx=d?c-1:0,this._updateMatch(!0),!0):(this._advanceOffsetPage(d),!!(p.wrapped&&(p.matchIdx=null,this._pagesToSearch<0))&&(this._updateMatch(!1),!0))}_nextPageMatch(){null!==this._resumePageIdx&&console.error("There can only be one pending page.");let h=null;do{const p=this._offset.pageIdx;if(h=this._pageMatches[p],!h){this._resumePageIdx=p;break}}while(!this._matchesReady(h))}_advanceOffsetPage(h){const p=this._offset,c=this._linkService.pagesCount;p.pageIdx=h?p.pageIdx-1:p.pageIdx+1,p.matchIdx=null,this._pagesToSearch--,(p.pageIdx>=c||p.pageIdx<0)&&(p.pageIdx=h?c-1:0,p.wrapped=!0)}_updateMatch(h=!1){let p=E.NOT_FOUND;const c=this._offset.wrapped;if(this._offset.wrapped=!1,h){const d=this._selected.pageIdx;this._selected.pageIdx=this._offset.pageIdx,this._selected.matchIdx=this._offset.matchIdx,p=c?E.WRAPPED:E.FOUND,-1!==d&&d!==this._selected.pageIdx&&this._updatePage(d)}this._updateUIState(p,this._state.findPrevious),-1!==this._selected.pageIdx&&(this._scrollMatches=!0,this._updatePage(this._selected.pageIdx))}_onFindBarClose(h){const p=this._pdfDocument;this._firstPageCapability.promise.then(()=>{!this._pdfDocument||p&&this._pdfDocument!==p||(this._findTimeout&&(clearTimeout(this._findTimeout),this._findTimeout=null),this._resumePageIdx&&(this._resumePageIdx=null,this._dirtyMatch=!0),this._updateUIState(E.FOUND),this._highlightMatches=!1,this._updateAllPages())})}_requestMatchesCount(){const{pageIdx:h,matchIdx:p}=this._selected;let c=0,d=this._matchesCountTotal;if(-1!==p){for(let m=0;m<h;m++)c+=this._pageMatches[m]&&this._pageMatches[m].length||0;c+=p+1}return(c<1||c>d)&&(c=d=0),{current:c,total:d}}_updateUIResultsCount(){this._eventBus.dispatch("updatefindmatchescount",{source:this,matchesCount:this._requestMatchesCount()})}_updateUIState(h,p){this._eventBus.dispatch("updatefindcontrolstate",{source:this,state:h,previous:p,matchesCount:this._requestMatchesCount()})}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.getCharacterType=function V(h){return function j(h){return h<11904}(h)?function k(h){return 0==(65408&h)}(h)?function F(h){return 32===h||9===h||13===h||10===h}(h)?B.SPACE:function E(h){return h>=97&&h<=122||h>=65&&h<=90}(h)||function R(h){return h>=48&&h<=57}(h)||95===h?B.ALPHA_LETTER:B.PUNCT:function M(h){return 3584==(65408&h)}(h)?B.THAI_LETTER:160===h?B.SPACE:B.ALPHA_LETTER:function _(h){return h>=13312&&h<=40959||h>=63744&&h<=64255}(h)?B.HAN_LETTER:function b(h){return h>=12448&&h<=12543}(h)?B.KATAKANA_LETTER:function A(h){return h>=12352&&h<=12447}(h)?B.HIRAGANA_LETTER:function x(h){return h>=65376&&h<=65439}(h)?B.HALFWIDTH_KATAKANA_LETTER:B.ALPHA_LETTER},N.CharacterType=void 0;const B={SPACE:0,ALPHA_LETTER:1,PUNCT:2,HAN_LETTER:3,KATAKANA_LETTER:4,HIRAGANA_LETTER:5,HALFWIDTH_KATAKANA_LETTER:6,THAI_LETTER:7};N.CharacterType=B},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.isDestHashesEqual=_,N.isDestArraysEqual=b,N.PDFHistory=void 0;var B=q(3);function R(){return document.location.hash}function _(A,x){if("string"!=typeof A||"string"!=typeof x)return!1;if(A===x)return!0;const{nameddest:M}=(0,B.parseQueryString)(A);return M===x}function b(A,x){function M(V,h){if(typeof V!=typeof h||Array.isArray(V)||Array.isArray(h))return!1;if(null!==V&&"object"==typeof V&&null!==h){if(Object.keys(V).length!==Object.keys(h).length)return!1;for(const p in V)if(!M(V[p],h[p]))return!1;return!0}return V===h||Number.isNaN(V)&&Number.isNaN(h)}if(!Array.isArray(A)||!Array.isArray(x)||A.length!==x.length)return!1;for(let V=0,h=A.length;V<h;V++)if(!M(A[V],x[V]))return!1;return!0}N.PDFHistory=class F{constructor({linkService:x,eventBus:M}){this.linkService=x,this.eventBus=M,this._initialized=!1,this._fingerprint="",this.reset(),this._boundEvents=null,this._isViewerInPresentationMode=!1,this.eventBus._on("presentationmodechanged",V=>{this._isViewerInPresentationMode=V.active||V.switchInProgress}),this.eventBus._on("pagesinit",()=>{this._isPagesLoaded=!1;const V=h=>{this.eventBus._off("pagesloaded",V),this._isPagesLoaded=!!h.pagesCount};this.eventBus._on("pagesloaded",V)})}initialize({fingerprint:x,resetHistory:M=!1,updateUrl:V=!1}){if(!x||"string"!=typeof x)return void console.error('PDFHistory.initialize: The "fingerprint" must be a non-empty string.');this._initialized&&this.reset();const h=""!==this._fingerprint&&this._fingerprint!==x;this._fingerprint=x,this._updateUrl=!0===V,this._initialized=!0,this._bindEvents();const p=window.history.state;if(this._popStateInProgress=!1,this._blockHashChange=0,this._currentHash=R(),this._numPositionUpdates=0,this._uid=this._maxUid=0,this._destination=null,this._position=null,!this._isValidState(p,!0)||M){const{hash:d,page:m,rotation:D}=this._parseCurrentHash(!0);return!d||h||M?void this._pushOrReplaceState(null,!0):void this._pushOrReplaceState({hash:d,page:m,rotation:D},!0)}const c=p.destination;this._updateInternalState(c,p.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),void 0!==c.rotation&&(this._initialRotation=c.rotation),c.dest?(this._initialBookmark=JSON.stringify(c.dest),this._destination.page=null):c.hash?this._initialBookmark=c.hash:c.page&&(this._initialBookmark=`page=${c.page}`)}reset(){this._initialized&&(this._pageHide(),this._initialized=!1,this._unbindEvents()),this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._initialBookmark=null,this._initialRotation=null}push({namedDest:x=null,explicitDest:M,pageNumber:V}){if(!this._initialized)return;if(x&&"string"!=typeof x)return void console.error(`PDFHistory.push: "${x}" is not a valid namedDest parameter.`);if(!Array.isArray(M))return void console.error(`PDFHistory.push: "${M}" is not a valid explicitDest parameter.`);if(!(Number.isInteger(V)&&V>0&&V<=this.linkService.pagesCount)&&(null!==V||this._destination))return void console.error(`PDFHistory.push: "${V}" is not a valid pageNumber parameter.`);const h=x||JSON.stringify(M);if(!h)return;let p=!1;if(this._destination&&(_(this._destination.hash,h)||b(this._destination.dest,M))){if(this._destination.page)return;p=!0}this._popStateInProgress&&!p||(this._pushOrReplaceState({dest:M,hash:h,page:V,rotation:this.linkService.rotation},p),this._popStateInProgress||(this._popStateInProgress=!0,Promise.resolve().then(()=>{this._popStateInProgress=!1})))}pushCurrentPosition(){!this._initialized||this._popStateInProgress||this._tryPushCurrentPosition()}back(){if(!this._initialized||this._popStateInProgress)return;const x=window.history.state;this._isValidState(x)&&x.uid>0&&window.history.back()}forward(){if(!this._initialized||this._popStateInProgress)return;const x=window.history.state;this._isValidState(x)&&x.uid<this._maxUid&&window.history.forward()}get popStateInProgress(){return this._initialized&&(this._popStateInProgress||this._blockHashChange>0)}get initialBookmark(){return this._initialized?this._initialBookmark:null}get initialRotation(){return this._initialized?this._initialRotation:null}_pushOrReplaceState(x,M=!1){const V=M||!this._destination,h={fingerprint:this._fingerprint,uid:V?this._uid:this._uid+1,destination:x};let p;if(this._updateInternalState(x,h.uid),this._updateUrl&&x&&x.hash){const c=document.location.href.split("#")[0];c.startsWith("file://")||(p=`${c}#${x.hash}`)}V?window.history.replaceState(h,"",p):(this._maxUid=this._uid,window.history.pushState(h,"",p))}_tryPushCurrentPosition(x=!1){if(!this._position)return;let M=this._position;if(x&&(M=Object.assign(Object.create(null),this._position),M.temporary=!0),!this._destination)return void this._pushOrReplaceState(M);if(this._destination.temporary)return void this._pushOrReplaceState(M,!0);if(this._destination.hash===M.hash||!this._destination.page&&this._numPositionUpdates<=50)return;let V=!1;if(this._destination.page>=M.first&&this._destination.page<=M.page){if(this._destination.dest||!this._destination.first)return;V=!0}this._pushOrReplaceState(M,V)}_isValidState(x,M=!1){if(!x)return!1;if(x.fingerprint!==this._fingerprint){if(!M)return!1;{if("string"!=typeof x.fingerprint||x.fingerprint.length!==this._fingerprint.length)return!1;const[V]=performance.getEntriesByType("navigation");if(!V||"reload"!==V.type)return!1}}return!(!Number.isInteger(x.uid)||x.uid<0||null===x.destination||"object"!=typeof x.destination)}_updateInternalState(x,M,V=!1){this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),V&&x&&x.temporary&&delete x.temporary,this._destination=x,this._uid=M,this._numPositionUpdates=0}_parseCurrentHash(x=!1){const M=unescape(R()).substring(1),V=(0,B.parseQueryString)(M),h=V.nameddest||"";let p=0|V.page;return(!(Number.isInteger(p)&&p>0&&p<=this.linkService.pagesCount)||x&&h.length>0)&&(p=null),{hash:M,page:p,rotation:this.linkService.rotation}}_updateViewarea({location:x}){this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._position={hash:this._isViewerInPresentationMode?`page=${x.pageNumber}`:x.pdfOpenParams.substring(1),page:this.linkService.page,first:x.pageNumber,rotation:x.rotation},!this._popStateInProgress&&(this._isPagesLoaded&&this._destination&&!this._destination.page&&this._numPositionUpdates++,this._updateViewareaTimeout=setTimeout(()=>{this._popStateInProgress||this._tryPushCurrentPosition(!0),this._updateViewareaTimeout=null},1e3))}_popState({state:x}){const M=R(),V=this._currentHash!==M;if(this._currentHash=M,!x){this._uid++;const{hash:p,page:c,rotation:d}=this._parseCurrentHash();return void this._pushOrReplaceState({hash:p,page:c,rotation:d},!0)}if(!this._isValidState(x))return;this._popStateInProgress=!0,V&&(this._blockHashChange++,(0,B.waitOnEventOrTimeout)({target:window,name:"hashchange",delay:1e3}).then(()=>{this._blockHashChange--}));const h=x.destination;this._updateInternalState(h,x.uid,!0),this._uid>this._maxUid&&(this._maxUid=this._uid),(0,B.isValidRotation)(h.rotation)&&(this.linkService.rotation=h.rotation),h.dest?this.linkService.navigateTo(h.dest):h.hash?this.linkService.setHash(h.hash):h.page&&(this.linkService.page=h.page),Promise.resolve().then(()=>{this._popStateInProgress=!1})}_pageHide(){(!this._destination||this._destination.temporary)&&this._tryPushCurrentPosition()}_bindEvents(){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))}_unbindEvents(){!this._boundEvents||(this.eventBus._off("updateviewarea",this._boundEvents.updateViewarea),window.removeEventListener("popstate",this._boundEvents.popState),window.removeEventListener("pagehide",this._boundEvents.pageHide),this._boundEvents=null)}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.PDFPageView=void 0;var B=q(3),j=q(2),k=q(14);const R=q(7).viewerCompatibilityParams.maxCanvasPixels||16777216;N.PDFPageView=class F{constructor(b){const A=b.container,x=b.defaultViewport;this.id=b.id,this.renderingId="page"+this.id,this.pdfPage=null,this.pageLabel=null,this.rotation=0,this.scale=b.scale||B.DEFAULT_SCALE,this.viewport=x,this.pdfPageRotate=x.rotation,this.hasRestrictedScaling=!1,this.textLayerMode=Number.isInteger(b.textLayerMode)?b.textLayerMode:B.TextLayerMode.ENABLE,this.imageResourcesPath=b.imageResourcesPath||"",this.renderInteractiveForms=b.renderInteractiveForms||!1,this.useOnlyCssZoom=b.useOnlyCssZoom||!1,this.maxCanvasPixels=b.maxCanvasPixels||R,this.eventBus=b.eventBus,this.renderingQueue=b.renderingQueue,this.textLayerFactory=b.textLayerFactory,this.annotationLayerFactory=b.annotationLayerFactory,this.renderer=b.renderer||B.RendererType.CANVAS,this.enableWebGL=b.enableWebGL||!1,this.l10n=b.l10n||B.NullL10n,this.paintTask=null,this.paintedViewportMap=new WeakMap,this.renderingState=k.RenderingStates.INITIAL,this.resume=null,this.error=null,this.annotationLayer=null,this.textLayer=null,this.zoomLayer=null;const M=document.createElement("div");M.className="page",M.style.width=Math.floor(this.viewport.width)+"px",M.style.height=Math.floor(this.viewport.height)+"px",M.setAttribute("data-page-number",this.id),this.div=M,A.appendChild(M)}setPdfPage(b){this.pdfPage=b,this.pdfPageRotate=b.rotate,this.viewport=b.getViewport({scale:this.scale*B.CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this.stats=b.stats,this.reset()}destroy(){this.reset(),this.pdfPage&&this.pdfPage.cleanup()}_resetZoomLayer(b=!1){if(!this.zoomLayer)return;const A=this.zoomLayer.firstChild;this.paintedViewportMap.delete(A),A.width=0,A.height=0,b&&this.zoomLayer.remove(),this.zoomLayer=null}reset(b=!1,A=!1){this.cancelRendering(A),this.renderingState=k.RenderingStates.INITIAL;const x=this.div;x.style.width=Math.floor(this.viewport.width)+"px",x.style.height=Math.floor(this.viewport.height)+"px";const M=x.childNodes,V=b&&this.zoomLayer||null,h=A&&this.annotationLayer&&this.annotationLayer.div||null;for(let p=M.length-1;p>=0;p--){const c=M[p];V===c||h===c||x.removeChild(c)}x.removeAttribute("data-loaded"),h?this.annotationLayer.hide():this.annotationLayer&&(this.annotationLayer.cancel(),this.annotationLayer=null),V||(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",x.appendChild(this.loadingIconDiv)}update(b,A){if(this.scale=b||this.scale,void 0!==A&&(this.rotation=A),this.viewport=this.viewport.clone({scale:this.scale*B.CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this.svg)return this.cssTransform(this.svg,!0),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now()});let M=!1;if(this.canvas&&this.maxCanvasPixels>0){const V=this.outputScale;(Math.floor(this.viewport.width)*V.sx|0)*(Math.floor(this.viewport.height)*V.sy|0)>this.maxCanvasPixels&&(M=!0)}if(this.canvas){if(this.useOnlyCssZoom||this.hasRestrictedScaling&&M)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)}cancelRendering(b=!1){this.paintTask&&(this.paintTask.cancel(),this.paintTask=null),this.resume=null,this.textLayer&&(this.textLayer.cancel(),this.textLayer=null),!b&&this.annotationLayer&&(this.annotationLayer.cancel(),this.annotationLayer=null)}cssTransform(b,A=!1){const x=this.viewport.width,M=this.viewport.height,V=this.div;b.style.width=b.parentNode.style.width=V.style.width=Math.floor(x)+"px",b.style.height=b.parentNode.style.height=V.style.height=Math.floor(M)+"px";const h=this.viewport.rotation-this.paintedViewportMap.get(b).rotation,p=Math.abs(h);let c=1,d=1;if((90===p||270===p)&&(c=M/x,d=x/M),b.style.transform="rotate("+h+"deg) scale("+c+","+d+")",this.textLayer){const D=this.textLayer.viewport,W=Math.abs(this.viewport.rotation-D.rotation);let G=x/D.width;(90===W||270===W)&&(G=x/D.height);const Y=this.textLayer.textLayerDiv;let Z,K;switch(W){case 0:Z=K=0;break;case 90:Z=0,K="-"+Y.style.height;break;case 180:Z="-"+Y.style.width,K="-"+Y.style.height;break;case 270:Z="-"+Y.style.width,K=0;break;default:console.error("Bad rotation value.")}Y.style.transform="rotate("+W+"deg) scale("+G+", "+G+") translate("+Z+", "+K+")",Y.style.transformOrigin="0% 0%"}A&&this.annotationLayer&&this.annotationLayer.render(this.viewport,"display")}get width(){return this.viewport.width}get height(){return this.viewport.height}getPagePoint(b,A){return this.viewport.convertToPdfPoint(b,A)}draw(){var b=this;this.renderingState!==k.RenderingStates.INITIAL&&(console.error("Must be in new state before drawing"),this.reset());const{div:A,pdfPage:x}=this;if(!x)return this.renderingState=k.RenderingStates.FINISHED,this.loadingIconDiv&&(A.removeChild(this.loadingIconDiv),delete this.loadingIconDiv),Promise.reject(new Error("pdfPage is not loaded"));this.renderingState=k.RenderingStates.RUNNING;const M=document.createElement("div");M.style.width=A.style.width,M.style.height=A.style.height,M.classList.add("canvasWrapper"),this.annotationLayer&&this.annotationLayer.div?A.insertBefore(M,this.annotationLayer.div):A.appendChild(M);let V=null;if(this.textLayerMode!==B.TextLayerMode.DISABLE&&this.textLayerFactory){const m=document.createElement("div");m.className="textLayer",m.style.width=M.style.width,m.style.height=M.style.height,this.annotationLayer&&this.annotationLayer.div?A.insertBefore(m,this.annotationLayer.div):A.appendChild(m),V=this.textLayerFactory.createTextLayerBuilder(m,this.id-1,this.viewport,this.textLayerMode===B.TextLayerMode.ENABLE_ENHANCE,this.eventBus)}this.textLayer=V;let h=null;this.renderingQueue&&(h=m=>{if(!this.renderingQueue.isHighestPriority(this))return this.renderingState=k.RenderingStates.PAUSED,void(this.resume=()=>{this.renderingState=k.RenderingStates.RUNNING,m()});m()});const p=function(){var m=f(function*(D){if(c===b.paintTask&&(b.paintTask=null),D instanceof j.RenderingCancelledException)b.error=null;else if(b.renderingState=k.RenderingStates.FINISHED,b.loadingIconDiv&&(A.removeChild(b.loadingIconDiv),delete b.loadingIconDiv),b._resetZoomLayer(!0),b.error=D,b.stats=x.stats,b.eventBus.dispatch("pagerendered",{source:b,pageNumber:b.id,cssTransform:!1,timestamp:performance.now()}),D)throw D});return function(I){return m.apply(this,arguments)}}(),c=this.renderer===B.RendererType.SVG?this.paintOnSvg(M):this.paintOnCanvas(M);c.onRenderContinue=h,this.paintTask=c;const d=c.promise.then(function(){return p(null).then(function(){if(V){const m=x.streamTextContent({normalizeWhitespace:!0});V.setTextContentStream(m),V.render()}})},function(m){return p(m)});return this.annotationLayerFactory&&(this.annotationLayer||(this.annotationLayer=this.annotationLayerFactory.createAnnotationLayerBuilder(A,x,this.imageResourcesPath,this.renderInteractiveForms,this.l10n)),this.annotationLayer.render(this.viewport,"display")),A.setAttribute("data-loaded",!0),this.eventBus.dispatch("pagerender",{source:this,pageNumber:this.id}),d}paintOnCanvas(b){const A=(0,j.createPromiseCapability)(),x={promise:A.promise,onRenderContinue(Y){Y()},cancel(){G.cancel()}},M=this.viewport,V=document.createElement("canvas");this.l10n.get("page_canvas",{page:this.id},"Page {{page}}").then(Y=>{V.setAttribute("aria-label",Y)}),V.setAttribute("hidden","hidden");let h=!0;const p=function(){h&&(V.removeAttribute("hidden"),h=!1)};b.appendChild(V),this.canvas=V,V.mozOpaque=!0;const c=V.getContext("2d",{alpha:!1}),d=(0,B.getOutputScale)(c);if(this.outputScale=d,this.useOnlyCssZoom){const Y=M.clone({scale:B.CSS_UNITS});d.sx*=Y.width/M.width,d.sy*=Y.height/M.height,d.scaled=!0}if(this.maxCanvasPixels>0){const Z=Math.sqrt(this.maxCanvasPixels/(M.width*M.height));d.sx>Z||d.sy>Z?(d.sx=Z,d.sy=Z,d.scaled=!0,this.hasRestrictedScaling=!0):this.hasRestrictedScaling=!1}const m=(0,B.approximateFraction)(d.sx),D=(0,B.approximateFraction)(d.sy);V.width=(0,B.roundToDivide)(M.width*d.sx,m[0]),V.height=(0,B.roundToDivide)(M.height*d.sy,D[0]),V.style.width=(0,B.roundToDivide)(M.width,m[1])+"px",V.style.height=(0,B.roundToDivide)(M.height,D[1])+"px",this.paintedViewportMap.set(V,M);const G=this.pdfPage.render({canvasContext:c,transform:d.scaled?[d.sx,0,0,d.sy,0,0]:null,viewport:this.viewport,enableWebGL:this.enableWebGL,renderInteractiveForms:this.renderInteractiveForms});return G.onContinue=function(Y){p(),x.onRenderContinue?x.onRenderContinue(Y):Y()},G.promise.then(function(){p(),A.resolve(void 0)},function(Y){p(),A.reject(Y)}),x}paintOnSvg(b){let A=!1;const x=()=>{if(A)throw new j.RenderingCancelledException(`Rendering cancelled, page ${this.id}`,"svg")},M=this.pdfPage,V=this.viewport.clone({scale:B.CSS_UNITS});return{promise:M.getOperatorList().then(p=>(x(),new j.SVGGraphics(M.commonObjs,M.objs).getSVG(p,V).then(d=>{x(),this.svg=d,this.paintedViewportMap.set(d,V),d.style.width=b.style.width,d.style.height=b.style.height,this.renderingState=k.RenderingStates.FINISHED,b.appendChild(d)}))),onRenderContinue(p){p()},cancel(){A=!0}}}setPageLabel(b){this.pageLabel="string"==typeof b?b:null,null!==this.pageLabel?this.div.setAttribute("data-page-label",this.pageLabel):this.div.removeAttribute("data-page-label")}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.PDFRenderingQueue=N.RenderingStates=void 0;const j={INITIAL:0,RUNNING:1,PAUSED:2,FINISHED:3};N.RenderingStates=j;N.PDFRenderingQueue=class k{constructor(){this.pdfViewer=null,this.pdfThumbnailViewer=null,this.onIdle=null,this.highestPriorityPage=null,this.idleTimeout=null,this.printing=!1,this.isThumbnailViewEnabled=!1}setViewer(R){this.pdfViewer=R}setThumbnailViewer(R){this.pdfThumbnailViewer=R}isHighestPriority(R){return this.highestPriorityPage===R.renderingId}renderHighestPriority(R){this.idleTimeout&&(clearTimeout(this.idleTimeout),this.idleTimeout=null),!this.pdfViewer.forceRendering(R)&&(this.pdfThumbnailViewer&&this.isThumbnailViewEnabled&&this.pdfThumbnailViewer.forceRendering()||this.printing||this.onIdle&&(this.idleTimeout=setTimeout(this.onIdle.bind(this),3e4)))}getHighestPriority(R,F,_){const b=R.views,A=b.length;if(0===A)return null;for(let x=0;x<A;++x){const M=b[x].view;if(!this.isViewFinished(M))return M}if(_){const x=R.last.id;if(F[x]&&!this.isViewFinished(F[x]))return F[x]}else{const x=R.first.id-2;if(F[x]&&!this.isViewFinished(F[x]))return F[x]}return null}isViewFinished(R){return R.renderingState===j.FINISHED}renderView(R){switch(R.renderingState){case j.FINISHED:return!1;case j.PAUSED:this.highestPriorityPage=R.renderingId,R.resume();break;case j.RUNNING:this.highestPriorityPage=R.renderingId;break;case j.INITIAL:this.highestPriorityPage=R.renderingId,R.draw().finally(()=>{this.renderHighestPriority()}).catch(F=>{console.error(`renderView: "${F}"`)})}return!0}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.PDFSinglePageViewer=void 0;var B=q(16),j=q(2);N.PDFSinglePageViewer=class k extends B.BaseViewer{constructor(R){super(R),this.eventBus._on("pagesinit",F=>{this._ensurePageViewVisible()})}get _viewerElement(){return(0,j.shadow)(this,"_viewerElement",this._shadowViewer)}_resetView(){super._resetView(),this._previousPageNumber=1,this._shadowViewer=document.createDocumentFragment(),this._updateScrollDown=null}_ensurePageViewVisible(){const R=this._pages[this._currentPageNumber-1],F=this._pages[this._previousPageNumber-1],_=this.viewer.childNodes;switch(_.length){case 0:this.viewer.appendChild(R.div);break;case 1:if(_[0]!==F.div)throw new Error("_ensurePageViewVisible: Unexpected previously visible page.");if(R===F)break;this._shadowViewer.appendChild(F.div),this.viewer.appendChild(R.div),this.container.scrollTop=0;break;default:throw new Error("_ensurePageViewVisible: Only one page should be visible at a time.")}this._previousPageNumber=this._currentPageNumber}_scrollUpdate(){this._updateScrollDown&&this._updateScrollDown(),super._scrollUpdate()}_scrollIntoView({pageDiv:R,pageSpot:F=null,pageNumber:_=null}){_&&this._setCurrentPageNumber(_);const b=this._currentPageNumber>=this._previousPageNumber;this._ensurePageViewVisible(),this.update(),super._scrollIntoView({pageDiv:R,pageSpot:F,pageNumber:_}),this._updateScrollDown=()=>{this.scroll.down=b,this._updateScrollDown=null}}_getVisiblePages(){return this._getCurrentVisiblePage()}_updateHelper(R){}get _isScrollModeHorizontal(){return(0,j.shadow)(this,"_isScrollModeHorizontal",!1)}_updateScrollMode(){}_updateSpreadMode(){}}},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.BaseViewer=void 0;var B=q(3),j=q(14),k=q(1),E=q(2),R=q(13),F=q(4),_=q(5);function A(V){const h=[];this.push=function(p){const c=h.indexOf(p);c>=0&&h.splice(c,1),h.push(p),h.length>V&&h.shift().destroy()},this.resize=function(p,c){if(V=p,c){const d=new Set;for(let m=0,D=c.length;m<D;++m)d.add(c[m].id);(0,B.moveToEndOfArray)(h,function(m){return d.has(m.id)})}for(;h.length>V;)h.shift().destroy()}}class M{constructor(h){if(this.constructor===M)throw new Error("Cannot initialize BaseViewer.");this._name=this.constructor.name,this.container=h.container,this.viewer=h.viewer||h.container.firstElementChild,this.eventBus=h.eventBus,this.linkService=h.linkService||new F.SimpleLinkService,this.downloadManager=h.downloadManager||null,this.findController=h.findController||null,this.removePageBorders=h.removePageBorders||!1,this.textLayerMode=Number.isInteger(h.textLayerMode)?h.textLayerMode:B.TextLayerMode.ENABLE,this.imageResourcesPath=h.imageResourcesPath||"",this.renderInteractiveForms=h.renderInteractiveForms||!1,this.enablePrintAutoRotate=h.enablePrintAutoRotate||!1,this.renderer=h.renderer||B.RendererType.CANVAS,this.enableWebGL=h.enableWebGL||!1,this.useOnlyCssZoom=h.useOnlyCssZoom||!1,this.maxCanvasPixels=h.maxCanvasPixels,this.l10n=h.l10n||B.NullL10n,this.defaultRenderingQueue=!h.renderingQueue,this.defaultRenderingQueue?(this.renderingQueue=new j.PDFRenderingQueue,this.renderingQueue.setViewer(this)):this.renderingQueue=h.renderingQueue,this.scroll=(0,B.watchScroll)(this.container,this._scrollUpdate.bind(this)),this.presentationModeState=B.PresentationModeState.UNKNOWN,this._onBeforeDraw=this._onAfterDraw=null,this._resetView(),this.removePageBorders&&this.viewer.classList.add("removePageBorders"),Promise.resolve().then(()=>{this.eventBus.dispatch("baseviewerinit",{source:this})})}get pagesCount(){return this._pages.length}getPageView(h){return this._pages[h]}get pageViewsReady(){return!!this._pagesCapability.settled&&this._pages.every(function(h){return h&&h.pdfPage})}get currentPageNumber(){return this._currentPageNumber}set currentPageNumber(h){if(!Number.isInteger(h))throw new Error("Invalid page number.");!this.pdfDocument||this._setCurrentPageNumber(h,!0)||console.error(`${this._name}.currentPageNumber: "${h}" is not a valid page.`)}_setCurrentPageNumber(h,p=!1){return this._currentPageNumber===h?(p&&this._resetCurrentPageView(),!0):0<h&&h<=this.pagesCount&&(this._currentPageNumber=h,this.eventBus.dispatch("pagechanging",{source:this,pageNumber:h,pageLabel:this._pageLabels&&this._pageLabels[h-1]}),p&&this._resetCurrentPageView(),!0)}get currentPageLabel(){return this._pageLabels&&this._pageLabels[this._currentPageNumber-1]}set currentPageLabel(h){if(!this.pdfDocument)return;let p=0|h;if(this._pageLabels){const c=this._pageLabels.indexOf(h);c>=0&&(p=c+1)}this._setCurrentPageNumber(p,!0)||console.error(`${this._name}.currentPageLabel: "${h}" is not a valid page.`)}get currentScale(){return this._currentScale!==B.UNKNOWN_SCALE?this._currentScale:B.DEFAULT_SCALE}set currentScale(h){if(isNaN(h))throw new Error("Invalid numeric scale.");!this.pdfDocument||this._setScale(h,!1)}get currentScaleValue(){return this._currentScaleValue}set currentScaleValue(h){!this.pdfDocument||this._setScale(h,!1)}get pagesRotation(){return this._pagesRotation}set pagesRotation(h){if(!(0,B.isValidRotation)(h))throw new Error("Invalid pages rotation angle.");if(!this.pdfDocument||this._pagesRotation===h)return;this._pagesRotation=h;const p=this._currentPageNumber;for(let c=0,d=this._pages.length;c<d;c++){const m=this._pages[c];m.update(m.scale,h)}this._currentScaleValue&&this._setScale(this._currentScaleValue,!0),this.eventBus.dispatch("rotationchanging",{source:this,pagesRotation:h,pageNumber:p}),this.defaultRenderingQueue&&this.update()}get firstPagePromise(){return this.pdfDocument?this._firstPageCapability.promise:null}get onePageRendered(){return this.pdfDocument?this._onePageRenderedCapability.promise:null}get pagesPromise(){return this.pdfDocument?this._pagesCapability.promise:null}get _viewerElement(){throw new Error("Not implemented: _viewerElement")}_onePageRenderedOrForceFetch(){return this.container.offsetParent&&0!==this._getVisiblePages().views.length?this._onePageRenderedCapability.promise:Promise.resolve()}setDocument(h){if(this.pdfDocument&&(this._cancelRendering(),this._resetView(),this.findController&&this.findController.setDocument(null)),this.pdfDocument=h,!h)return;const p=h.numPages,c=h.getPage(1);this._pagesCapability.promise.then(()=>{this.eventBus.dispatch("pagesloaded",{source:this,pagesCount:p})}),this._onBeforeDraw=d=>{const m=this._pages[d.pageNumber-1];!m||this._buffer.push(m)},this.eventBus._on("pagerender",this._onBeforeDraw),this._onAfterDraw=d=>{d.cssTransform||this._onePageRenderedCapability.settled||(this._onePageRenderedCapability.resolve(),this.eventBus._off("pagerendered",this._onAfterDraw),this._onAfterDraw=null)},this.eventBus._on("pagerendered",this._onAfterDraw),c.then(d=>{this._firstPageCapability.resolve(d);const m=this.currentScale,D=d.getViewport({scale:m*B.CSS_UNITS}),I=this.textLayerMode!==B.TextLayerMode.DISABLE?this:null;for(let G=1;G<=p;++G){const Y=new R.PDFPageView({container:this._viewerElement,eventBus:this.eventBus,id:G,scale:m,defaultViewport:D.clone(),renderingQueue:this.renderingQueue,textLayerFactory:I,textLayerMode:this.textLayerMode,annotationLayerFactory:this,imageResourcesPath:this.imageResourcesPath,renderInteractiveForms:this.renderInteractiveForms,renderer:this.renderer,enableWebGL:this.enableWebGL,useOnlyCssZoom:this.useOnlyCssZoom,maxCanvasPixels:this.maxCanvasPixels,l10n:this.l10n});this._pages.push(Y)}const W=this._pages[0];W&&(W.setPdfPage(d),this.linkService.cachePageRef(1,d.ref)),this._spreadMode!==B.SpreadMode.NONE&&this._updateSpreadMode(),this._onePageRenderedOrForceFetch().then(()=>{if(this.findController&&this.findController.setDocument(h),h.loadingParams.disableAutoFetch||p>7500)return void this._pagesCapability.resolve();let G=p-1;if(G<=0)this._pagesCapability.resolve();else for(let Y=2;Y<=p;++Y)h.getPage(Y).then(Z=>{const K=this._pages[Y-1];K.pdfPage||K.setPdfPage(Z),this.linkService.cachePageRef(Y,Z.ref),0==--G&&this._pagesCapability.resolve()},Z=>{console.error(`Unable to get page ${Y} to initialize viewer`,Z),0==--G&&this._pagesCapability.resolve()})}),this.eventBus.dispatch("pagesinit",{source:this}),this.defaultRenderingQueue&&this.update()}).catch(d=>{console.error("Unable to initialize viewer",d)})}setPageLabels(h){if(this.pdfDocument){h?Array.isArray(h)&&this.pdfDocument.numPages===h.length?this._pageLabels=h:(this._pageLabels=null,console.error(`${this._name}.setPageLabels: Invalid page labels.`)):this._pageLabels=null;for(let p=0,c=this._pages.length;p<c;p++)this._pages[p].setPageLabel(this._pageLabels&&this._pageLabels[p])}}_resetView(){this._pages=[],this._currentPageNumber=1,this._currentScale=B.UNKNOWN_SCALE,this._currentScaleValue=null,this._pageLabels=null,this._buffer=new A(10),this._location=null,this._pagesRotation=0,this._pagesRequests=new WeakMap,this._firstPageCapability=(0,E.createPromiseCapability)(),this._onePageRenderedCapability=(0,E.createPromiseCapability)(),this._pagesCapability=(0,E.createPromiseCapability)(),this._scrollMode=B.ScrollMode.VERTICAL,this._spreadMode=B.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()}_scrollUpdate(){0!==this.pagesCount&&this.update()}_scrollIntoView({pageDiv:h,pageSpot:p=null,pageNumber:c=null}){(0,B.scrollIntoView)(h,p)}_setScaleUpdatePages(h,p,c=!1,d=!1){if(this._currentScaleValue=p.toString(),function x(V,h){return h===V||Math.abs(h-V)<1e-15}(this._currentScale,h))d&&this.eventBus.dispatch("scalechanging",{source:this,scale:h,presetValue:p});else{for(let m=0,D=this._pages.length;m<D;m++)this._pages[m].update(h);if(this._currentScale=h,!c){let D,m=this._currentPageNumber;this._location&&!(this.isInPresentationMode||this.isChangingPresentationMode)&&(m=this._location.pageNumber,D=[null,{name:"XYZ"},this._location.left,this._location.top,null]),this.scrollPageIntoView({pageNumber:m,destArray:D,allowNegativeOffset:!0})}this.eventBus.dispatch("scalechanging",{source:this,scale:h,presetValue:d?p:void 0}),this.defaultRenderingQueue&&this.update()}}_setScale(h,p=!1){let c=parseFloat(h);if(c>0)this._setScaleUpdatePages(c,h,p,!1);else{const d=this._pages[this._currentPageNumber-1];if(!d)return;const m=this.isInPresentationMode||this.removePageBorders;let D=m?0:B.SCROLLBAR_PADDING,I=m?0:B.VERTICAL_PADDING;!m&&this._isScrollModeHorizontal&&([D,I]=[I,D]);const W=(this.container.clientWidth-D)/d.width*d.scale,G=(this.container.clientHeight-I)/d.height*d.scale;switch(h){case"page-actual":c=1;break;case"page-width":c=W;break;case"page-height":c=G;break;case"page-fit":c=Math.min(W,G);break;case"auto":const Y=(0,B.isPortraitOrientation)(d)?W:Math.min(G,W);c=Math.min(B.MAX_AUTO_SCALE,Y);break;default:return void console.error(`${this._name}._setScale: "${h}" is an unknown zoom value.`)}this._setScaleUpdatePages(c,h,p,!0)}}_resetCurrentPageView(){this.isInPresentationMode&&this._setScale(this._currentScaleValue,!0),this._scrollIntoView({pageDiv:this._pages[this._currentPageNumber-1].div})}scrollPageIntoView({pageNumber:h,destArray:p=null,allowNegativeOffset:c=!1,ignoreDestinationZoom:d=!1}){if(!this.pdfDocument)return;const m=Number.isInteger(h)&&this._pages[h-1];if(!m)return void console.error(`${this._name}.scrollPageIntoView: "${h}" is not a valid pageNumber parameter.`);if(this.isInPresentationMode||!p)return void this._setCurrentPageNumber(h,!0);let Y,Z,D=0,I=0,W=0,G=0;const K=m.rotation%180!=0,ce=(K?m.height:m.width)/m.scale/B.CSS_UNITS,U=(K?m.width:m.height)/m.scale/B.CSS_UNITS;let y=0;switch(p[1].name){case"XYZ":D=p[2],I=p[3],y=p[4],D=null!==D?D:0,I=null!==I?I:U;break;case"Fit":case"FitB":y="page-fit";break;case"FitH":case"FitBH":I=p[2],y="page-width",null===I&&this._location&&(D=this._location.left,I=this._location.top);break;case"FitV":case"FitBV":D=p[2],W=ce,G=U,y="page-height";break;case"FitR":D=p[2],I=p[3],W=p[4]-D,G=p[5]-I,Y=(this.container.clientWidth-(this.removePageBorders?0:B.SCROLLBAR_PADDING))/W/B.CSS_UNITS,Z=(this.container.clientHeight-(this.removePageBorders?0:B.VERTICAL_PADDING))/G/B.CSS_UNITS,y=Math.min(Math.abs(Y),Math.abs(Z));break;default:return void console.error(`${this._name}.scrollPageIntoView: "${p[1].name}" is not a valid destination type.`)}if(d||(y&&y!==this._currentScale?this.currentScaleValue=y:this._currentScale===B.UNKNOWN_SCALE&&(this.currentScaleValue=B.DEFAULT_SCALE_VALUE)),"page-fit"===y&&!p[4])return void this._scrollIntoView({pageDiv:m.div,pageNumber:h});const L=[m.viewport.convertToViewportPoint(D,I),m.viewport.convertToViewportPoint(D+W,I+G)];let P=Math.min(L[0][0],L[1][0]),T=Math.min(L[0][1],L[1][1]);c||(P=Math.max(P,0),T=Math.max(T,0)),this._scrollIntoView({pageDiv:m.div,pageSpot:{left:P,top:T},pageNumber:h})}_updateLocation(h){const p=this._currentScale,c=this._currentScaleValue,d=parseFloat(c)===p?Math.round(1e4*p)/100:c,m=h.id;let D="#page="+m;D+="&zoom="+d;const W=this.container,G=this._pages[m-1].getPagePoint(W.scrollLeft-h.x,W.scrollTop-h.y),Y=Math.round(G[0]),Z=Math.round(G[1]);D+=","+Y+","+Z,this._location={pageNumber:m,scale:d,top:Z,left:Y,rotation:this._pagesRotation,pdfOpenParams:D}}_updateHelper(h){throw new Error("Not implemented: _updateHelper")}update(){const h=this._getVisiblePages(),p=h.views,c=p.length;if(0===c)return;const d=Math.max(10,2*c+1);this._buffer.resize(d,p),this.renderingQueue.renderHighestPriority(h),this._updateHelper(p),this._updateLocation(h.first),this.eventBus.dispatch("updateviewarea",{source:this,location:this._location})}containsElement(h){return this.container.contains(h)}focus(){this.container.focus()}get _isScrollModeHorizontal(){return!this.isInPresentationMode&&this._scrollMode===B.ScrollMode.HORIZONTAL}get isInPresentationMode(){return this.presentationModeState===B.PresentationModeState.FULLSCREEN}get isChangingPresentationMode(){return this.presentationModeState===B.PresentationModeState.CHANGING}get isHorizontalScrollbarEnabled(){return!this.isInPresentationMode&&this.container.scrollWidth>this.container.clientWidth}get isVerticalScrollbarEnabled(){return!this.isInPresentationMode&&this.container.scrollHeight>this.container.clientHeight}_getCurrentVisiblePage(){if(!this.pagesCount)return{views:[]};const h=this._pages[this._currentPageNumber-1],p=h.div,c={id:h.id,x:p.offsetLeft+p.clientLeft,y:p.offsetTop+p.clientTop,view:h};return{first:c,last:c,views:[c]}}_getVisiblePages(){return(0,B.getVisibleElements)(this.container,this._pages,!0,this._isScrollModeHorizontal)}isPageVisible(h){return!!this.pdfDocument&&(h<1||h>this.pagesCount?(console.error(`${this._name}.isPageVisible: "${h}" is out of bounds.`),!1):this._getVisiblePages().views.some(function(p){return p.id===h}))}cleanup(){for(let h=0,p=this._pages.length;h<p;h++)this._pages[h]&&this._pages[h].renderingState!==j.RenderingStates.FINISHED&&this._pages[h].reset()}_cancelRendering(){for(let h=0,p=this._pages.length;h<p;h++)this._pages[h]&&this._pages[h].cancelRendering()}_ensurePdfPageLoaded(h){if(h.pdfPage)return Promise.resolve(h.pdfPage);if(this._pagesRequests.has(h))return this._pagesRequests.get(h);const p=this.pdfDocument.getPage(h.id).then(c=>(h.pdfPage||h.setPdfPage(c),this._pagesRequests.delete(h),c)).catch(c=>{console.error("Unable to get page for page view",c),this._pagesRequests.delete(h)});return this._pagesRequests.set(h,p),p}forceRendering(h){const p=h||this._getVisiblePages(),d=this.renderingQueue.getHighestPriority(p,this._pages,this._isScrollModeHorizontal?this.scroll.right:this.scroll.down);return!!d&&(this._ensurePdfPageLoaded(d).then(()=>{this.renderingQueue.renderView(d)}),!0)}createTextLayerBuilder(h,p,c,d=!1,m){return new _.TextLayerBuilder({textLayerDiv:h,eventBus:m,pageIndex:p,viewport:c,findController:this.isInPresentationMode?null:this.findController,enhanceTextSelection:!this.isInPresentationMode&&d})}createAnnotationLayerBuilder(h,p,c="",d=!1,m=B.NullL10n){return new k.AnnotationLayerBuilder({pageDiv:h,pdfPage:p,imageResourcesPath:c,renderInteractiveForms:d,linkService:this.linkService,downloadManager:this.downloadManager,l10n:m})}get hasEqualPageSizes(){const h=this._pages[0];for(let p=1,c=this._pages.length;p<c;++p){const d=this._pages[p];if(d.width!==h.width||d.height!==h.height)return!1}return!0}getPagesOverview(){const h=this._pages.map(function(c){const d=c.pdfPage.getViewport({scale:1});return{width:d.width,height:d.height,rotation:d.rotation}});if(!this.enablePrintAutoRotate)return h;const p=(0,B.isPortraitOrientation)(h[0]);return h.map(function(c){return p===(0,B.isPortraitOrientation)(c)?c:{width:c.height,height:c.width,rotation:(c.rotation+90)%360}})}get scrollMode(){return this._scrollMode}set scrollMode(h){if(this._scrollMode!==h){if(!(0,B.isValidScrollMode)(h))throw new Error(`Invalid scroll mode: ${h}`);this._scrollMode=h,this.eventBus.dispatch("scrollmodechanged",{source:this,mode:h}),this._updateScrollMode(this._currentPageNumber)}}_updateScrollMode(h=null){const p=this._scrollMode,c=this.viewer;c.classList.toggle("scrollHorizontal",p===B.ScrollMode.HORIZONTAL),c.classList.toggle("scrollWrapped",p===B.ScrollMode.WRAPPED),this.pdfDocument&&h&&(this._currentScaleValue&&isNaN(this._currentScaleValue)&&this._setScale(this._currentScaleValue,!0),this._setCurrentPageNumber(h,!0),this.update())}get spreadMode(){return this._spreadMode}set spreadMode(h){if(this._spreadMode!==h){if(!(0,B.isValidSpreadMode)(h))throw new Error(`Invalid spread mode: ${h}`);this._spreadMode=h,this.eventBus.dispatch("spreadmodechanged",{source:this,mode:h}),this._updateSpreadMode(this._currentPageNumber)}}_updateSpreadMode(h=null){if(!this.pdfDocument)return;const p=this.viewer,c=this._pages;if(p.textContent="",this._spreadMode===B.SpreadMode.NONE)for(let d=0,m=c.length;d<m;++d)p.appendChild(c[d].div);else{const d=this._spreadMode-1;let m=null;for(let D=0,I=c.length;D<I;++D)null===m?(m=document.createElement("div"),m.className="spread",p.appendChild(m)):D%2===d&&(m=m.cloneNode(!1),p.appendChild(m)),m.appendChild(c[D].div)}!h||(this._setCurrentPageNumber(h,!0),this.update())}}N.BaseViewer=M},function(H,N,q){"use strict";Object.defineProperty(N,"__esModule",{value:!0}),N.PDFViewer=void 0;var B=q(16),j=q(2);N.PDFViewer=class k extends B.BaseViewer{get _viewerElement(){return(0,j.shadow)(this,"_viewerElement",this.viewer)}_scrollIntoView({pageDiv:R,pageSpot:F=null,pageNumber:_=null}){if(!F&&!this.isInPresentationMode){const b=R.offsetLeft+R.clientLeft,A=b+R.clientWidth,{scrollLeft:x,clientWidth:M}=this.container;(this._isScrollModeHorizontal||b<x||A>x+M)&&(F={left:0,top:0})}super._scrollIntoView({pageDiv:R,pageSpot:F,pageNumber:_})}_getVisiblePages(){return this.isInPresentationMode?this._getCurrentVisiblePage():super._getVisiblePages()}_updateHelper(R){if(this.isInPresentationMode)return;let F=this._currentPageNumber,_=!1;for(const b of R){if(b.percent<100)break;if(b.id===F){_=!0;break}}_||(F=R[0].id),this._setCurrentPageNumber(F)}}}])},926:we=>{function v(f,H,N,q,B,j,k){try{var E=f[j](k),R=E.value}catch(F){return void N(F)}E.done?H(R):Promise.resolve(R).then(q,B)}we.exports=function z(f){return function(){var H=this,N=arguments;return new Promise(function(q,B){var j=f.apply(H,N);function k(R){v(j,q,B,k,E,"next",R)}function E(R){v(j,q,B,k,E,"throw",R)}k(void 0)})}},we.exports.__esModule=!0,we.exports.default=we.exports},172:()=>{},1:()=>{},779:()=>{},558:()=>{},258:()=>{}},__webpack_module_cache__={};function __webpack_require__(we){var v=__webpack_module_cache__[we];if(void 0!==v)return v.exports;var z=__webpack_module_cache__[we]={exports:{}};return __webpack_modules__[we].call(z.exports,z,z.exports,__webpack_require__),z.exports}var __webpack_exports__={};(()=>{"use strict";function we(t){return"function"==typeof t}let v=!1;const z={Promise:void 0,set useDeprecatedSynchronousErrorHandling(t){if(t){const e=new Error;console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+e.stack)}else v&&console.log("RxJS: Back to a better error behavior. Thank you. <3");v=t},get useDeprecatedSynchronousErrorHandling(){return v}};function f(t){setTimeout(()=>{throw t},0)}const H={closed:!0,next(t){},error(t){if(z.useDeprecatedSynchronousErrorHandling)throw t;f(t)},complete(){}},N=Array.isArray||(t=>t&&"number"==typeof t.length);function q(t){return null!==t&&"object"==typeof t}const j=(()=>{function t(e){return Error.call(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((n,r)=>`${r+1}) ${n.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e,this}return t.prototype=Object.create(Error.prototype),t})();class k{constructor(e){this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._ctorUnsubscribe=!0,this._unsubscribe=e)}unsubscribe(){let e;if(this.closed)return;let{_parentOrParents:n,_ctorUnsubscribe:r,_unsubscribe:i,_subscriptions:s}=this;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,n instanceof k)n.remove(this);else if(null!==n)for(let o=0;o<n.length;++o)n[o].remove(this);if(we(i)){r&&(this._unsubscribe=void 0);try{i.call(this)}catch(o){e=o instanceof j?E(o.errors):[o]}}if(N(s)){let o=-1,a=s.length;for(;++o<a;){const l=s[o];if(q(l))try{l.unsubscribe()}catch(u){e=e||[],u instanceof j?e=e.concat(E(u.errors)):e.push(u)}}}if(e)throw new j(e)}add(e){let n=e;if(!e)return k.EMPTY;switch(typeof e){case"function":n=new k(e);case"object":if(n===this||n.closed||"function"!=typeof n.unsubscribe)return n;if(this.closed)return n.unsubscribe(),n;if(!(n instanceof k)){const s=n;n=new k,n._subscriptions=[s]}break;default:throw new Error("unrecognized teardown "+e+" added to Subscription.")}let{_parentOrParents:r}=n;if(null===r)n._parentOrParents=this;else if(r instanceof k){if(r===this)return n;n._parentOrParents=[r,this]}else{if(-1!==r.indexOf(this))return n;r.push(this)}const i=this._subscriptions;return null===i?this._subscriptions=[n]:i.push(n),n}remove(e){const n=this._subscriptions;if(n){const r=n.indexOf(e);-1!==r&&n.splice(r,1)}}}var t;function E(t){return t.reduce((e,n)=>e.concat(n instanceof j?n.errors:n),[])}k.EMPTY=((t=new k).closed=!0,t);const R="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random();class _ extends k{constructor(e,n,r){switch(super(),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=H;break;case 1:if(!e){this.destination=H;break}if("object"==typeof e){e instanceof _?(this.syncErrorThrowable=e.syncErrorThrowable,this.destination=e,e.add(this)):(this.syncErrorThrowable=!0,this.destination=new b(this,e));break}default:this.syncErrorThrowable=!0,this.destination=new b(this,e,n,r)}}[R](){return this}static create(e,n,r){const i=new _(e,n,r);return i.syncErrorThrowable=!1,i}next(e){this.isStopped||this._next(e)}error(e){this.isStopped||(this.isStopped=!0,this._error(e))}complete(){this.isStopped||(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe())}_next(e){this.destination.next(e)}_error(e){this.destination.error(e),this.unsubscribe()}_complete(){this.destination.complete(),this.unsubscribe()}_unsubscribeAndRecycle(){const{_parentOrParents:e}=this;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=e,this}}class b extends _{constructor(e,n,r,i){super(),this._parentSubscriber=e;let s,o=this;we(n)?s=n:n&&(s=n.next,r=n.error,i=n.complete,n!==H&&(o=Object.create(n),we(o.unsubscribe)&&this.add(o.unsubscribe.bind(o)),o.unsubscribe=this.unsubscribe.bind(this))),this._context=o,this._next=s,this._error=r,this._complete=i}next(e){if(!this.isStopped&&this._next){const{_parentSubscriber:n}=this;z.useDeprecatedSynchronousErrorHandling&&n.syncErrorThrowable?this.__tryOrSetError(n,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}}error(e){if(!this.isStopped){const{_parentSubscriber:n}=this,{useDeprecatedSynchronousErrorHandling:r}=z;if(this._error)r&&n.syncErrorThrowable?(this.__tryOrSetError(n,this._error,e),this.unsubscribe()):(this.__tryOrUnsub(this._error,e),this.unsubscribe());else if(n.syncErrorThrowable)r?(n.syncErrorValue=e,n.syncErrorThrown=!0):f(e),this.unsubscribe();else{if(this.unsubscribe(),r)throw e;f(e)}}}complete(){if(!this.isStopped){const{_parentSubscriber:e}=this;if(this._complete){const n=()=>this._complete.call(this._context);z.useDeprecatedSynchronousErrorHandling&&e.syncErrorThrowable?(this.__tryOrSetError(e,n),this.unsubscribe()):(this.__tryOrUnsub(n),this.unsubscribe())}else this.unsubscribe()}}__tryOrUnsub(e,n){try{e.call(this._context,n)}catch(r){if(this.unsubscribe(),z.useDeprecatedSynchronousErrorHandling)throw r;f(r)}}__tryOrSetError(e,n,r){if(!z.useDeprecatedSynchronousErrorHandling)throw new Error("bad call");try{n.call(this._context,r)}catch(i){return z.useDeprecatedSynchronousErrorHandling?(e.syncErrorValue=i,e.syncErrorThrown=!0,!0):(f(i),!0)}return!1}_unsubscribe(){const{_parentSubscriber:e}=this;this._context=null,this._parentSubscriber=null,e.unsubscribe()}}const M="function"==typeof Symbol&&Symbol.observable||"@@observable";function V(t){return t}let c=(()=>{class t{constructor(n){this._isScalar=!1,n&&(this._subscribe=n)}lift(n){const r=new t;return r.source=this,r.operator=n,r}subscribe(n,r,i){const{operator:s}=this,o=function x(t,e,n){if(t){if(t instanceof _)return t;if(t[R])return t[R]()}return t||e||n?new _(t,e,n):new _(H)}(n,r,i);if(o.add(s?s.call(o,this.source):this.source||z.useDeprecatedSynchronousErrorHandling&&!o.syncErrorThrowable?this._subscribe(o):this._trySubscribe(o)),z.useDeprecatedSynchronousErrorHandling&&o.syncErrorThrowable&&(o.syncErrorThrowable=!1,o.syncErrorThrown))throw o.syncErrorValue;return o}_trySubscribe(n){try{return this._subscribe(n)}catch(r){z.useDeprecatedSynchronousErrorHandling&&(n.syncErrorThrown=!0,n.syncErrorValue=r),function A(t){for(;t;){const{closed:e,destination:n,isStopped:r}=t;if(e||r)return!1;t=n&&n instanceof _?n:null}return!0}(n)?n.error(r):console.warn(r)}}forEach(n,r){return new(r=d(r))((i,s)=>{let o;o=this.subscribe(a=>{try{n(a)}catch(l){s(l),o&&o.unsubscribe()}},s,i)})}_subscribe(n){const{source:r}=this;return r&&r.subscribe(n)}[M](){return this}pipe(...n){return 0===n.length?this:function p(t){return 0===t.length?V:1===t.length?t[0]:function(n){return t.reduce((r,i)=>i(r),n)}}(n)(this)}toPromise(n){return new(n=d(n))((r,i)=>{let s;this.subscribe(o=>s=o,o=>i(o),()=>r(s))})}}return t.create=e=>new t(e),t})();function d(t){if(t||(t=z.Promise||Promise),!t)throw new Error("no Promise impl found");return t}const D=(()=>{function t(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return t.prototype=Object.create(Error.prototype),t})();class I extends k{constructor(e,n){super(),this.subject=e,this.subscriber=n,this.closed=!1}unsubscribe(){if(this.closed)return;this.closed=!0;const e=this.subject,n=e.observers;if(this.subject=null,!n||0===n.length||e.isStopped||e.closed)return;const r=n.indexOf(this.subscriber);-1!==r&&n.splice(r,1)}}class W extends _{constructor(e){super(e),this.destination=e}}let G=(()=>{class t extends c{constructor(){super(),this.observers=[],this.closed=!1,this.isStopped=!1,this.hasError=!1,this.thrownError=null}[R](){return new W(this)}lift(n){const r=new Y(this,this);return r.operator=n,r}next(n){if(this.closed)throw new D;if(!this.isStopped){const{observers:r}=this,i=r.length,s=r.slice();for(let o=0;o<i;o++)s[o].next(n)}}error(n){if(this.closed)throw new D;this.hasError=!0,this.thrownError=n,this.isStopped=!0;const{observers:r}=this,i=r.length,s=r.slice();for(let o=0;o<i;o++)s[o].error(n);this.observers.length=0}complete(){if(this.closed)throw new D;this.isStopped=!0;const{observers:n}=this,r=n.length,i=n.slice();for(let s=0;s<r;s++)i[s].complete();this.observers.length=0}unsubscribe(){this.isStopped=!0,this.closed=!0,this.observers=null}_trySubscribe(n){if(this.closed)throw new D;return super._trySubscribe(n)}_subscribe(n){if(this.closed)throw new D;return this.hasError?(n.error(this.thrownError),k.EMPTY):this.isStopped?(n.complete(),k.EMPTY):(this.observers.push(n),new I(this,n))}asObservable(){const n=new c;return n.source=this,n}}return t.create=(e,n)=>new Y(e,n),t})();class Y extends G{constructor(e,n){super(),this.destination=e,this.source=n}next(e){const{destination:n}=this;n&&n.next&&n.next(e)}error(e){const{destination:n}=this;n&&n.error&&this.destination.error(e)}complete(){const{destination:e}=this;e&&e.complete&&this.destination.complete()}_subscribe(e){const{source:n}=this;return n?this.source.subscribe(e):k.EMPTY}}function Z(t){return t&&"function"==typeof t.schedule}function K(t,e){return function(r){if("function"!=typeof t)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return r.lift(new ce(t,e))}}class ce{constructor(e,n){this.project=e,this.thisArg=n}call(e,n){return n.subscribe(new U(e,this.project,this.thisArg))}}class U extends _{constructor(e,n,r){super(e),this.project=n,this.count=0,this.thisArg=r||this}_next(e){let n;try{n=this.project.call(this.thisArg,e,this.count++)}catch(r){return void this.destination.error(r)}this.destination.next(n)}}const y=t=>e=>{for(let n=0,r=t.length;n<r&&!e.closed;n++)e.next(t[n]);e.complete()},T=function P(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}(),Q=t=>t&&"number"==typeof t.length&&"function"!=typeof t;function ee(t){return!!t&&"function"!=typeof t.subscribe&&"function"==typeof t.then}const re=t=>{if(t&&"function"==typeof t[M])return(t=>e=>{const n=t[M]();if("function"!=typeof n.subscribe)throw new TypeError("Provided object does not correctly implement Symbol.observable");return n.subscribe(e)})(t);if(Q(t))return y(t);if(ee(t))return(t=>e=>(t.then(n=>{e.closed||(e.next(n),e.complete())},n=>e.error(n)).then(null,f),e))(t);if(t&&"function"==typeof t[T])return(t=>e=>{const n=t[T]();for(;;){let r;try{r=n.next()}catch(i){return e.error(i),e}if(r.done){e.complete();break}if(e.next(r.value),e.closed)break}return"function"==typeof n.return&&e.add(()=>{n.return&&n.return()}),e})(t);{const n=`You provided ${q(t)?"an invalid object":`'${t}'`} where a stream was expected. You can provide an Observable, Promise, Array, or Iterable.`;throw new TypeError(n)}};function ge(t,e){return new c(n=>{const r=new k;let i=0;return r.add(e.schedule(function(){i!==t.length?(n.next(t[i++]),n.closed||r.add(this.schedule())):n.complete()})),r})}function te(t,e){return e?function xe(t,e){if(null!=t){if(function Ae(t){return t&&"function"==typeof t[M]}(t))return function le(t,e){return new c(n=>{const r=new k;return r.add(e.schedule(()=>{const i=t[M]();r.add(i.subscribe({next(s){r.add(e.schedule(()=>n.next(s)))},error(s){r.add(e.schedule(()=>n.error(s)))},complete(){r.add(e.schedule(()=>n.complete()))}}))})),r})}(t,e);if(ee(t))return function de(t,e){return new c(n=>{const r=new k;return r.add(e.schedule(()=>t.then(i=>{r.add(e.schedule(()=>{n.next(i),r.add(e.schedule(()=>n.complete()))}))},i=>{r.add(e.schedule(()=>n.error(i)))}))),r})}(t,e);if(Q(t))return ge(t,e);if(function Ce(t){return t&&"function"==typeof t[T]}(t)||"string"==typeof t)return function pe(t,e){if(!t)throw new Error("Iterable cannot be null");return new c(n=>{const r=new k;let i;return r.add(()=>{i&&"function"==typeof i.return&&i.return()}),r.add(e.schedule(()=>{i=t[T](),r.add(e.schedule(function(){if(n.closed)return;let s,o;try{const a=i.next();s=a.value,o=a.done}catch(a){return void n.error(a)}o?n.complete():(n.next(s),this.schedule())}))})),r})}(t,e)}throw new TypeError((null!==t&&typeof t||t)+" is not observable")}(t,e):t instanceof c?t:new c(re(t))}class ie extends _{constructor(e){super(),this.parent=e}_next(e){this.parent.notifyNext(e)}_error(e){this.parent.notifyError(e),this.unsubscribe()}_complete(){this.parent.notifyComplete(),this.unsubscribe()}}class he extends _{notifyNext(e){this.destination.next(e)}notifyError(e){this.destination.error(e)}notifyComplete(){this.destination.complete()}}function be(t,e){if(!e.closed)return t instanceof c?t.subscribe(e):re(t)(e)}function Se(t,e,n=Number.POSITIVE_INFINITY){return"function"==typeof e?r=>r.pipe(Se((i,s)=>te(t(i,s)).pipe(K((o,a)=>e(i,o,s,a))),n)):("number"==typeof e&&(n=e),r=>r.lift(new Ne(t,n)))}class Ne{constructor(e,n=Number.POSITIVE_INFINITY){this.project=e,this.concurrent=n}call(e,n){return n.subscribe(new qe(e,this.project,this.concurrent))}}class qe extends he{constructor(e,n,r=Number.POSITIVE_INFINITY){super(e),this.project=n,this.concurrent=r,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}_next(e){this.active<this.concurrent?this._tryNext(e):this.buffer.push(e)}_tryNext(e){let n;const r=this.index++;try{n=this.project(e,r)}catch(i){return void this.destination.error(i)}this.active++,this._innerSub(n)}_innerSub(e){const n=new ie(this),r=this.destination;r.add(n);const i=be(e,n);i!==n&&r.add(i)}_complete(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()}notifyNext(e){this.destination.next(e)}notifyComplete(){const e=this.buffer;this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}function _t(t=Number.POSITIVE_INFINITY){return Se(V,t)}function Vt(t,e){return e?ge(t,e):new c(y(t))}function ut(...t){let e=Number.POSITIVE_INFINITY,n=null,r=t[t.length-1];return Z(r)?(n=t.pop(),t.length>1&&"number"==typeof t[t.length-1]&&(e=t.pop())):"number"==typeof r&&(e=t.pop()),null===n&&1===t.length&&t[0]instanceof c?t[0]:_t(e)(Vt(t,n))}function $t(){return function(e){return e.lift(new Nn(e))}}class Nn{constructor(e){this.connectable=e}call(e,n){const{connectable:r}=this;r._refCount++;const i=new _r(e,r),s=n.subscribe(i);return i.closed||(i.connection=r.connect()),s}}class _r extends _{constructor(e,n){super(e),this.connectable=n}_unsubscribe(){const{connectable:e}=this;if(!e)return void(this.connection=null);this.connectable=null;const n=e._refCount;if(n<=0)return void(this.connection=null);if(e._refCount=n-1,n>1)return void(this.connection=null);const{connection:r}=this,i=e._connection;this.connection=null,i&&(!r||i===r)&&i.unsubscribe()}}class jt extends c{constructor(e,n){super(),this.source=e,this.subjectFactory=n,this._refCount=0,this._isComplete=!1}_subscribe(e){return this.getSubject().subscribe(e)}getSubject(){const e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject}connect(){let e=this._connection;return e||(this._isComplete=!1,e=this._connection=new k,e.add(this.source.subscribe(new ne(this.getSubject(),this))),e.closed&&(this._connection=null,e=k.EMPTY)),e}refCount(){return $t()(this)}}const ue=(()=>{const t=jt.prototype;return{operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:t._subscribe},_isComplete:{value:t._isComplete,writable:!0},getSubject:{value:t.getSubject},connect:{value:t.connect},refCount:{value:t.refCount}}})();class ne extends W{constructor(e,n){super(e),this.connectable=n}_error(e){this._unsubscribe(),super._error(e)}_complete(){this.connectable._isComplete=!0,this._unsubscribe(),super._complete()}_unsubscribe(){const e=this.connectable;if(e){this.connectable=null;const n=e._connection;e._refCount=0,e._subject=null,e._connection=null,n&&n.unsubscribe()}}}class Je{constructor(e,n){this.subjectFactory=e,this.selector=n}call(e,n){const{selector:r}=this,i=this.subjectFactory(),s=r(i).subscribe(e);return s.add(n.subscribe(i)),s}}function Qe(){return new G}function Ke(t){for(let e in t)if(t[e]===Ke)return e;throw Error("Could not find renamed property on target object.")}function et(t){if("string"==typeof t)return t;if(Array.isArray(t))return"["+t.map(et).join(", ")+"]";if(null==t)return""+t;if(t.overriddenName)return`${t.overriddenName}`;if(t.name)return`${t.name}`;const e=t.toString();if(null==e)return""+e;const n=e.indexOf("\n");return-1===n?e:e.substring(0,n)}function ri(t,e){return null==t||""===t?null===e?"":e:null==e||""===e?t:t+" "+e}const Wa=Ke({__forward_ref__:Ke});function Ji(t){return t.__forward_ref__=Ji,t.toString=function(){return et(this())},t}function Ue(t){return function Xs(t){return"function"==typeof t&&t.hasOwnProperty(Wa)&&t.__forward_ref__===Ji}(t)?t():t}class Me extends Error{constructor(e,n){super(function qa(t,e){return`NG0${Math.abs(t)}${e?": "+e:""}`}(e,n)),this.code=e}}function Ht(t){return"function"==typeof t?t.name||t.toString():"object"==typeof t&&null!=t&&"function"==typeof t.type?t.type.name||t.type.toString():function Ve(t){return"string"==typeof t?t:null==t?"":String(t)}(t)}function Zs(t,e){const n=e?` in ${e}`:"";throw new Me(-201,`No provider for ${Ht(t)} found${n}`)}function ln(t,e){null==t&&function at(t,e,n,r){throw new Error(`ASSERTION ERROR: ${t}`+(null==r?"":` [Expected=> ${n} ${r} ${e} <=Actual]`))}(e,t,null,"!=")}function dt(t){return{token:t.token,providedIn:t.providedIn||null,factory:t.factory,value:void 0}}function vr(t){return{providers:t.providers||[],imports:t.imports||[]}}function Qa(t){return Ed(t,Js)||Ed(t,Dd)}function Ed(t,e){return t.hasOwnProperty(e)?t[e]:null}function Sd(t){return t&&(t.hasOwnProperty(Ka)||t.hasOwnProperty(j_))?t[Ka]:null}const Js=Ke({\u0275prov:Ke}),Ka=Ke({\u0275inj:Ke}),Dd=Ke({ngInjectableDef:Ke}),j_=Ke({ngInjectorDef:Ke});var Ge=(()=>((Ge=Ge||{})[Ge.Default=0]="Default",Ge[Ge.Host=1]="Host",Ge[Ge.Self=2]="Self",Ge[Ge.SkipSelf=4]="SkipSelf",Ge[Ge.Optional=8]="Optional",Ge))();let Ya;function br(t){const e=Ya;return Ya=t,e}function Td(t,e,n){const r=Qa(t);return r&&"root"==r.providedIn?void 0===r.value?r.value=r.factory():r.value:n&Ge.Optional?null:void 0!==e?e:void Zs(et(t),"Injector")}function Ar(t){return{toString:t}.toString()}var Fn=(()=>((Fn=Fn||{})[Fn.OnPush=0]="OnPush",Fn[Fn.Default=1]="Default",Fn))(),kn=(()=>(function(t){t[t.Emulated=0]="Emulated",t[t.None=2]="None",t[t.ShadowDom=3]="ShadowDom"}(kn||(kn={})),kn))();const U_="undefined"!=typeof globalThis&&globalThis,G_="undefined"!=typeof window&&window,$_="undefined"!=typeof self&&"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&self,ct=U_||"undefined"!=typeof global&&global||G_||$_,ii={},ht=[],eo=Ke({\u0275cmp:Ke}),Xa=Ke({\u0275dir:Ke}),Za=Ke({\u0275pipe:Ke}),Pd=Ke({\u0275mod:Ke}),lr=Ke({\u0275fac:Ke}),es=Ke({__NG_ELEMENT_ID__:Ke});let z_=0;function to(t){return Ar(()=>{const n={},r={type:t.type,providersResolver:null,decls:t.decls,vars:t.vars,factory:null,template:t.template||null,consts:t.consts||null,ngContentSelectors:t.ngContentSelectors,hostBindings:t.hostBindings||null,hostVars:t.hostVars||0,hostAttrs:t.hostAttrs||null,contentQueries:t.contentQueries||null,declaredInputs:n,inputs:null,outputs:null,exportAs:t.exportAs||null,onPush:t.changeDetection===Fn.OnPush,directiveDefs:null,pipeDefs:null,selectors:t.selectors||ht,viewQuery:t.viewQuery||null,features:t.features||null,data:t.data||{},encapsulation:t.encapsulation||kn.Emulated,id:"c",styles:t.styles||ht,_:null,setInput:null,schemas:t.schemas||null,tView:null},i=t.directives,s=t.features,o=t.pipes;return r.id+=z_++,r.inputs=Rd(t.inputs,n),r.outputs=Rd(t.outputs),s&&s.forEach(a=>a(r)),r.directiveDefs=i?()=>("function"==typeof i?i():i).map(Md):null,r.pipeDefs=o?()=>("function"==typeof o?o():o).map(Id):null,r})}function Md(t){return Ut(t)||function Cr(t){return t[Xa]||null}(t)}function Id(t){return function Br(t){return t[Za]||null}(t)}const xd={};function Or(t){return Ar(()=>{const e={type:t.type,bootstrap:t.bootstrap||ht,declarations:t.declarations||ht,imports:t.imports||ht,exports:t.exports||ht,transitiveCompileScopes:null,schemas:t.schemas||null,id:t.id||null};return null!=t.id&&(xd[t.id]=t.type),e})}function Rd(t,e){if(null==t)return ii;const n={};for(const r in t)if(t.hasOwnProperty(r)){let i=t[r],s=i;Array.isArray(i)&&(s=i[1],i=i[0]),n[i]=r,e&&(e[i]=s)}return n}function Ut(t){return t[eo]||null}function Cn(t,e){const n=t[Pd]||null;if(!n&&!0===e)throw new Error(`Type ${et(t)} does not have '\u0275mod' property.`);return n}function Kn(t){return Array.isArray(t)&&"object"==typeof t[1]}function Bn(t){return Array.isArray(t)&&!0===t[1]}function tl(t){return 0!=(8&t.flags)}function so(t){return 2==(2&t.flags)}function oo(t){return 1==(1&t.flags)}function Vn(t){return null!==t.template}function X_(t){return 0!=(512&t[2])}function Ur(t,e){return t.hasOwnProperty(lr)?t[lr]:null}class Nd{constructor(e,n,r){this.previousValue=e,this.currentValue=n,this.firstChange=r}isFirstChange(){return this.firstChange}}function ui(){return Fd}function Fd(t){return t.type.prototype.ngOnChanges&&(t.setInput=tv),ev}function ev(){const t=Od(this),e=null==t?void 0:t.current;if(e){const n=t.previous;if(n===ii)t.previous=e;else for(let r in e)n[r]=e[r];t.current=null,this.ngOnChanges(e)}}function tv(t,e,n,r){const i=Od(t)||function nv(t,e){return t[kd]=e}(t,{previous:ii,current:null}),s=i.current||(i.current={}),o=i.previous,a=this.declaredInputs[n],l=o[a];s[a]=new Nd(l&&l.currentValue,e,o===ii),t[r]=e}ui.ngInherit=!0;const kd="__ngSimpleChanges__";function Od(t){return t[kd]||null}let ol;function St(t){return!!t.listen}const Bd={createRenderer:(t,e)=>function al(){return void 0!==ol?ol:"undefined"!=typeof document?document:void 0}()};function Mt(t){for(;Array.isArray(t);)t=t[0];return t}function cn(t,e){return Mt(e[t.index])}function ll(t,e){return t.data[e]}function dn(t,e){const n=e[t];return Kn(n)?n:n[0]}function Vd(t){return 4==(4&t[2])}function ul(t){return 128==(128&t[2])}function wr(t,e){return null==e?null:t[e]}function jd(t){t[18]=0}function cl(t,e){t[5]+=e;let n=t,r=t[3];for(;null!==r&&(1===e&&1===n[5]||-1===e&&0===n[5]);)r[5]+=e,n=r,r=r[3]}const je={lFrame:Kd(null),bindingsEnabled:!0};function Ud(){return je.bindingsEnabled}function me(){return je.lFrame.lView}function rt(){return je.lFrame.tView}function Lt(){let t=Gd();for(;null!==t&&64===t.type;)t=t.parent;return t}function Gd(){return je.lFrame.currentTNode}function Yn(t,e){const n=je.lFrame;n.currentTNode=t,n.isParent=e}function dl(){return je.lFrame.isParent}function bv(t,e){const n=je.lFrame;n.bindingIndex=n.bindingRootIndex=t,fl(e)}function fl(t){je.lFrame.currentDirectiveIndex=t}function Wd(){return je.lFrame.currentQueryIndex}function gl(t){je.lFrame.currentQueryIndex=t}function Cv(t){const e=t[1];return 2===e.type?e.declTNode:1===e.type?t[6]:null}function qd(t,e,n){if(n&Ge.SkipSelf){let i=e,s=t;for(;!(i=i.parent,null!==i||n&Ge.Host||(i=Cv(s),null===i||(s=s[15],10&i.type))););if(null===i)return!1;e=i,t=s}const r=je.lFrame=Qd();return r.currentTNode=e,r.lView=t,!0}function uo(t){const e=Qd(),n=t[1];je.lFrame=e,e.currentTNode=n.firstChild,e.lView=t,e.tView=n,e.contextLView=t,e.bindingIndex=n.bindingStartIndex,e.inI18n=!1}function Qd(){const t=je.lFrame,e=null===t?null:t.child;return null===e?Kd(t):e}function Kd(t){const e={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:t,child:null,inI18n:!1};return null!==t&&(t.child=e),e}function Yd(){const t=je.lFrame;return je.lFrame=t.parent,t.currentTNode=null,t.lView=null,t}const Xd=Yd;function co(){const t=Yd();t.isParent=!0,t.tView=null,t.selectedIndex=-1,t.contextLView=null,t.elementDepthCount=0,t.currentDirectiveIndex=-1,t.currentNamespace=null,t.bindingRootIndex=-1,t.bindingIndex=-1,t.currentQueryIndex=0}function Er(t){je.lFrame.selectedIndex=t}function ho(t,e){for(let n=e.directiveStart,r=e.directiveEnd;n<r;n++){const s=t.data[n].type.prototype,{ngAfterContentInit:o,ngAfterContentChecked:a,ngAfterViewInit:l,ngAfterViewChecked:u,ngOnDestroy:g}=s;o&&(t.contentHooks||(t.contentHooks=[])).push(-n,o),a&&((t.contentHooks||(t.contentHooks=[])).push(n,a),(t.contentCheckHooks||(t.contentCheckHooks=[])).push(n,a)),l&&(t.viewHooks||(t.viewHooks=[])).push(-n,l),u&&((t.viewHooks||(t.viewHooks=[])).push(n,u),(t.viewCheckHooks||(t.viewCheckHooks=[])).push(n,u)),null!=g&&(t.destroyHooks||(t.destroyHooks=[])).push(n,g)}}function fo(t,e,n){Zd(t,e,3,n)}function po(t,e,n,r){(3&t[2])===n&&Zd(t,e,n,r)}function ml(t,e){let n=t[2];(3&n)===e&&(n&=2047,n+=1,t[2]=n)}function Zd(t,e,n,r){const s=null!=r?r:-1,o=e.length-1;let a=0;for(let l=void 0!==r?65535&t[18]:0;l<o;l++)if("number"==typeof e[l+1]){if(a=e[l],null!=r&&a>=r)break}else e[l]<0&&(t[18]+=65536),(a<s||-1==s)&&(xv(t,n,e,l),t[18]=(4294901760&t[18])+l+2),l++}function xv(t,e,n,r){const i=n[r]<0,s=n[r+1],a=t[i?-n[r]:n[r]];if(i){if(t[2]>>11<t[18]>>16&&(3&t[2])===e){t[2]+=2048;try{s.call(a)}finally{}}}else try{s.call(a)}finally{}}class ss{constructor(e,n,r){this.factory=e,this.resolving=!1,this.canSeeViewProviders=n,this.injectImpl=r}}function go(t,e,n){const r=St(t);let i=0;for(;i<n.length;){const s=n[i];if("number"==typeof s){if(0!==s)break;i++;const o=n[i++],a=n[i++],l=n[i++];r?t.setAttribute(e,a,l,o):e.setAttributeNS(o,a,l)}else{const o=s,a=n[++i];_l(o)?r&&t.setProperty(e,o,a):r?t.setAttribute(e,o,a):e.setAttribute(o,a),i++}}return i}function Jd(t){return 3===t||4===t||6===t}function _l(t){return 64===t.charCodeAt(0)}function mo(t,e){if(null!==e&&0!==e.length)if(null===t||0===t.length)t=e.slice();else{let n=-1;for(let r=0;r<e.length;r++){const i=e[r];"number"==typeof i?n=i:0===n||eh(t,n,i,null,-1===n||2===n?e[++r]:null)}}return t}function eh(t,e,n,r,i){let s=0,o=t.length;if(-1===e)o=-1;else for(;s<t.length;){const a=t[s++];if("number"==typeof a){if(a===e){o=-1;break}if(a>e){o=s-1;break}}}for(;s<t.length;){const a=t[s];if("number"==typeof a)break;if(a===n){if(null===r)return void(null!==i&&(t[s+1]=i));if(r===t[s+1])return void(t[s+2]=i)}s++,null!==r&&s++,null!==i&&s++}-1!==o&&(t.splice(o,0,e),s=o+1),t.splice(s++,0,n),null!==r&&t.splice(s++,0,r),null!==i&&t.splice(s++,0,i)}function th(t){return-1!==t}function hi(t){return 32767&t}function fi(t,e){let n=function kv(t){return t>>16}(t),r=e;for(;n>0;)r=r[15],n--;return r}let vl=!0;function yo(t){const e=vl;return vl=t,e}let Ov=0;function as(t,e){const n=Al(t,e);if(-1!==n)return n;const r=e[1];r.firstCreatePass&&(t.injectorIndex=e.length,bl(r.data,t),bl(e,null),bl(r.blueprint,null));const i=_o(t,e),s=t.injectorIndex;if(th(i)){const o=hi(i),a=fi(i,e),l=a[1].data;for(let u=0;u<8;u++)e[s+u]=a[o+u]|l[o+u]}return e[s+8]=i,s}function bl(t,e){t.push(0,0,0,0,0,0,0,0,e)}function Al(t,e){return-1===t.injectorIndex||t.parent&&t.parent.injectorIndex===t.injectorIndex||null===e[t.injectorIndex+8]?-1:t.injectorIndex}function _o(t,e){if(t.parent&&-1!==t.parent.injectorIndex)return t.parent.injectorIndex;let n=0,r=null,i=e;for(;null!==i;){const s=i[1],o=s.type;if(r=2===o?s.declTNode:1===o?i[6]:null,null===r)return-1;if(n++,i=i[15],-1!==r.injectorIndex)return r.injectorIndex|n<<16}return-1}function vo(t,e,n){!function Bv(t,e,n){let r;"string"==typeof n?r=n.charCodeAt(0)||0:n.hasOwnProperty(es)&&(r=n[es]),null==r&&(r=n[es]=Ov++);const i=255&r;e.data[t+(i>>5)]|=1<<i}(t,e,n)}function ih(t,e,n){if(n&Ge.Optional)return t;Zs(e,"NodeInjector")}function sh(t,e,n,r){if(n&Ge.Optional&&void 0===r&&(r=null),0==(n&(Ge.Self|Ge.Host))){const i=t[9],s=br(void 0);try{return i?i.get(e,r,n&Ge.Optional):Td(e,r,n&Ge.Optional)}finally{br(s)}}return ih(r,e,n)}function oh(t,e,n,r=Ge.Default,i){if(null!==t){const s=function Uv(t){if("string"==typeof t)return t.charCodeAt(0)||0;const e=t.hasOwnProperty(es)?t[es]:void 0;return"number"==typeof e?e>=0?255&e:jv:e}(n);if("function"==typeof s){if(!qd(e,t,r))return r&Ge.Host?ih(i,n,r):sh(e,n,r,i);try{const o=s(r);if(null!=o||r&Ge.Optional)return o;Zs(n)}finally{Xd()}}else if("number"==typeof s){let o=null,a=Al(t,e),l=-1,u=r&Ge.Host?e[16][6]:null;for((-1===a||r&Ge.SkipSelf)&&(l=-1===a?_o(t,e):e[a+8],-1!==l&&uh(r,!1)?(o=e[1],a=hi(l),e=fi(l,e)):a=-1);-1!==a;){const g=e[1];if(lh(s,a,g.data)){const S=Hv(a,e,n,o,r,u);if(S!==ah)return S}l=e[a+8],-1!==l&&uh(r,e[1].data[a+8]===u)&&lh(s,a,e)?(o=g,a=hi(l),e=fi(l,e)):a=-1}}}return sh(e,n,r,i)}const ah={};function jv(){return new pi(Lt(),me())}function Hv(t,e,n,r,i,s){const o=e[1],a=o.data[t+8],g=bo(a,o,n,null==r?so(a)&&vl:r!=o&&0!=(3&a.type),i&Ge.Host&&s===a);return null!==g?ls(e,o,g,a):ah}function bo(t,e,n,r,i){const s=t.providerIndexes,o=e.data,a=1048575&s,l=t.directiveStart,g=s>>20,O=i?a+g:t.directiveEnd;for(let $=r?a:a+g;$<O;$++){const J=o[$];if($<l&&n===J||$>=l&&J.type===n)return $}if(i){const $=o[l];if($&&Vn($)&&$.type===n)return l}return null}function ls(t,e,n,r){let i=t[n];const s=e.data;if(function Rv(t){return t instanceof ss}(i)){const o=i;o.resolving&&function N_(t,e){const n=e?`. Dependency path: ${e.join(" > ")} > ${t}`:"";throw new Me(-200,`Circular dependency in DI detected for ${t}${n}`)}(Ht(s[n]));const a=yo(o.canSeeViewProviders);o.resolving=!0;const l=o.injectImpl?br(o.injectImpl):null;qd(t,r,Ge.Default);try{i=t[n]=o.factory(void 0,s,t,r),e.firstCreatePass&&n>=r.directiveStart&&function Iv(t,e,n){const{ngOnChanges:r,ngOnInit:i,ngDoCheck:s}=e.type.prototype;if(r){const o=Fd(e);(n.preOrderHooks||(n.preOrderHooks=[])).push(t,o),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(t,o)}i&&(n.preOrderHooks||(n.preOrderHooks=[])).push(0-t,i),s&&((n.preOrderHooks||(n.preOrderHooks=[])).push(t,s),(n.preOrderCheckHooks||(n.preOrderCheckHooks=[])).push(t,s))}(n,s[n],e)}finally{null!==l&&br(l),yo(a),o.resolving=!1,Xd()}}return i}function lh(t,e,n){return!!(n[e+(t>>5)]&1<<t)}function uh(t,e){return!(t&Ge.Self||t&Ge.Host&&e)}class pi{constructor(e,n){this._tNode=e,this._lView=n}get(e,n,r){return oh(this._tNode,this._lView,e,r,n)}}const yi="__prop__metadata__";function Ao(t,e,n,r){return Ar(()=>{const i=function El(t){return function(...n){if(t){const r=t(...n);for(const i in r)this[i]=r[i]}}}(e);function s(...o){if(this instanceof s)return i.apply(this,o),this;const a=new s(...o);return function l(u,g){const S=u.constructor,O=S.hasOwnProperty(yi)?S[yi]:Object.defineProperty(S,yi,{value:{}})[yi];O[g]=O.hasOwnProperty(g)&&O[g]||[],O[g].unshift(a),r&&r(u,g,...o)}}return n&&(s.prototype=Object.create(n.prototype)),s.prototype.ngMetadataName=t,s.annotationCls=s,s})}class it{constructor(e,n){this._desc=e,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof n?this.__NG_ELEMENT_ID__=n:void 0!==n&&(this.\u0275prov=dt({token:this,providedIn:n.providedIn||"root",factory:n.factory}))}toString(){return`InjectionToken ${this._desc}`}}class zv{}const Wv=Ao("ViewChild",(t,e)=>Object.assign({selector:t,first:!0,isViewQuery:!0,descendants:!0},e),zv);function Sn(t,e){void 0===e&&(e=t);for(let n=0;n<t.length;n++){let r=t[n];Array.isArray(r)?(e===t&&(e=t.slice(0,n)),Sn(r,e)):e!==t&&e.push(r)}return e}function Xn(t,e){t.forEach(n=>Array.isArray(n)?Xn(n,e):e(n))}function dh(t,e,n){e>=t.length?t.push(n):t.splice(e,0,n)}function Co(t,e){return e>=t.length-1?t.pop():t.splice(e,1)[0]}const hs={},Eo="ngTempTokenPath",nb=/\n/gm,mh="__source",ib=Ke({provide:String,useValue:Ke});let fs;function yh(t){const e=fs;return fs=t,e}function sb(t,e=Ge.Default){if(void 0===fs)throw new Me(203,"");return null===fs?Td(t,void 0,e):fs.get(t,e&Ge.Optional?null:void 0,e)}function tt(t,e=Ge.Default){return(function H_(){return Ya}()||sb)(Ue(t),e)}const ob=tt;function Ml(t){const e=[];for(let n=0;n<t.length;n++){const r=Ue(t[n]);if(Array.isArray(r)){if(0===r.length)throw new Me(900,"");let i,s=Ge.Default;for(let o=0;o<r.length;o++){const a=r[o],l=ab(a);"number"==typeof l?-1===l?i=a.token:s|=l:i=a}e.push(tt(i,s))}else e.push(tt(r))}return e}function ab(t){return t.__NG_DI_FLAG__}var fn=(()=>((fn=fn||{})[fn.Important=1]="Important",fn[fn.DashCase=2]="DashCase",fn))();const Sh="__ngContext__";function Wt(t,e){t[Sh]=e}function Ll(t){const e=function ms(t){return t[Sh]||null}(t);return e?Array.isArray(e)?e:e.lView:null}function Fl(t,e){return undefined(t,e)}function ys(t){const e=t[3];return Bn(e)?e[3]:e}function kl(t){return Rh(t[13])}function Ol(t){return Rh(t[4])}function Rh(t){for(;null!==t&&!Bn(t);)t=t[4];return t}function Ai(t,e,n,r,i){if(null!=r){let s,o=!1;Bn(r)?s=r:Kn(r)&&(o=!0,r=r[0]);const a=Mt(r);0===t&&null!==n?null==i?Bh(e,n,a):Gr(e,n,a,i||null,!0):1===t&&null!==n?Gr(e,n,a,i||null,!0):2===t?function $l(t,e,n){const r=Po(t,e);r&&function Bb(t,e,n,r){St(t)?t.removeChild(e,n,r):e.removeChild(n)}(t,r,e,n)}(e,a,o):3===t&&e.destroyNode(a),null!=s&&function Hb(t,e,n,r,i){const s=n[7];s!==Mt(n)&&Ai(e,t,r,s,i);for(let a=10;a<n.length;a++){const l=n[a];_s(l[1],l,t,e,r,s)}}(e,t,s,n,i)}}function Vl(t,e,n){if(St(t))return t.createElement(e,n);{const r=null!==n?function ov(t){const e=t.toLowerCase();return"svg"===e?"http://www.w3.org/2000/svg":"math"===e?"http://www.w3.org/1998/MathML/":null}(n):null;return null===r?t.createElement(e):t.createElementNS(r,e)}}function Nh(t,e){const n=t[9],r=n.indexOf(e),i=e[3];1024&e[2]&&(e[2]&=-1025,cl(i,-1)),n.splice(r,1)}function jl(t,e){if(t.length<=10)return;const n=10+e,r=t[n];if(r){const i=r[17];null!==i&&i!==t&&Nh(i,r),e>0&&(t[n-1][4]=r[4]);const s=Co(t,10+e);!function Ib(t,e){_s(t,e,e[11],2,null,null),e[0]=null,e[6]=null}(r[1],r);const o=s[19];null!==o&&o.detachView(s[1]),r[3]=null,r[4]=null,r[2]&=-129}return r}function Fh(t,e){if(!(256&e[2])){const n=e[11];St(n)&&n.destroyNode&&_s(t,e,n,3,null,null),function Lb(t){let e=t[13];if(!e)return Hl(t[1],t);for(;e;){let n=null;if(Kn(e))n=e[13];else{const r=e[10];r&&(n=r)}if(!n){for(;e&&!e[4]&&e!==t;)Kn(e)&&Hl(e[1],e),e=e[3];null===e&&(e=t),Kn(e)&&Hl(e[1],e),n=e&&e[4]}e=n}}(e)}}function Hl(t,e){if(!(256&e[2])){e[2]&=-129,e[2]|=256,function Ob(t,e){let n;if(null!=t&&null!=(n=t.destroyHooks))for(let r=0;r<n.length;r+=2){const i=e[n[r]];if(!(i instanceof ss)){const s=n[r+1];if(Array.isArray(s))for(let o=0;o<s.length;o+=2){const a=i[s[o]],l=s[o+1];try{l.call(a)}finally{}}else try{s.call(i)}finally{}}}}(t,e),function kb(t,e){const n=t.cleanup,r=e[7];let i=-1;if(null!==n)for(let s=0;s<n.length-1;s+=2)if("string"==typeof n[s]){const o=n[s+1],a="function"==typeof o?o(e):Mt(e[o]),l=r[i=n[s+2]],u=n[s+3];"boolean"==typeof u?a.removeEventListener(n[s],l,u):u>=0?r[i=u]():r[i=-u].unsubscribe(),s+=2}else{const o=r[i=n[s+1]];n[s].call(o)}if(null!==r){for(let s=i+1;s<r.length;s++)r[s]();e[7]=null}}(t,e),1===e[1].type&&St(e[11])&&e[11].destroy();const n=e[17];if(null!==n&&Bn(e[3])){n!==e[3]&&Nh(n,e);const r=e[19];null!==r&&r.detachView(t)}}}function kh(t,e,n){return function Oh(t,e,n){let r=e;for(;null!==r&&40&r.type;)r=(e=r).parent;if(null===r)return n[0];if(2&r.flags){const i=t.data[r.directiveStart].encapsulation;if(i===kn.None||i===kn.Emulated)return null}return cn(r,n)}(t,e.parent,n)}function Gr(t,e,n,r,i){St(t)?t.insertBefore(e,n,r,i):e.insertBefore(n,r,i)}function Bh(t,e,n){St(t)?t.appendChild(e,n):e.appendChild(n)}function Vh(t,e,n,r,i){null!==r?Gr(t,e,n,r,i):Bh(t,e,n)}function Po(t,e){return St(t)?t.parentNode(e):e.parentNode}let Uh=function Hh(t,e,n){return 40&t.type?cn(t,n):null};function Mo(t,e,n,r){const i=kh(t,r,e),s=e[11],a=function jh(t,e,n){return Uh(t,e,n)}(r.parent||e[6],r,e);if(null!=i)if(Array.isArray(n))for(let l=0;l<n.length;l++)Vh(s,i,n[l],a,!1);else Vh(s,i,n,a,!1)}function Io(t,e){if(null!==e){const n=e.type;if(3&n)return cn(e,t);if(4&n)return Gl(-1,t[e.index]);if(8&n){const r=e.child;if(null!==r)return Io(t,r);{const i=t[e.index];return Bn(i)?Gl(-1,i):Mt(i)}}if(32&n)return Fl(e,t)()||Mt(t[e.index]);{const r=$h(t,e);return null!==r?Array.isArray(r)?r[0]:Io(ys(t[16]),r):Io(t,e.next)}}return null}function $h(t,e){return null!==e?t[16][6].projection[e.projection]:null}function Gl(t,e){const n=10+t+1;if(n<e.length){const r=e[n],i=r[1].firstChild;if(null!==i)return Io(r,i)}return e[7]}function zl(t,e,n,r,i,s,o){for(;null!=n;){const a=r[n.index],l=n.type;if(o&&0===e&&(a&&Wt(Mt(a),r),n.flags|=4),64!=(64&n.flags))if(8&l)zl(t,e,n.child,r,i,s,!1),Ai(e,t,i,a,s);else if(32&l){const u=Fl(n,r);let g;for(;g=u();)Ai(e,t,i,g,s);Ai(e,t,i,a,s)}else 16&l?zh(t,e,r,n,i,s):Ai(e,t,i,a,s);n=o?n.projectionNext:n.next}}function _s(t,e,n,r,i,s){zl(n,r,t.firstChild,e,i,s,!1)}function zh(t,e,n,r,i,s){const o=n[16],l=o[6].projection[r.projection];if(Array.isArray(l))for(let u=0;u<l.length;u++)Ai(e,t,i,l[u],s);else zl(t,e,l,o[3],i,s,!0)}function Wh(t,e,n){St(t)?t.setAttribute(e,"style",n):e.style.cssText=n}function Wl(t,e,n){St(t)?""===n?t.removeAttribute(e,"class"):t.setAttribute(e,"class",n):e.className=n}function eu(t){return t.ngOriginalError}function b0(t,...e){t.error(...e)}class Cs{constructor(){this._console=console}handleError(e){const n=this._findOriginalError(e),r=function v0(t){return t&&t.ngErrorLogger||b0}(e);r(this._console,"ERROR",e),n&&r(this._console,"ORIGINAL ERROR",n)}_findOriginalError(e){let n=e&&eu(e);for(;n&&eu(n);)n=eu(n);return n||null}}const T0=(()=>("undefined"!=typeof requestAnimationFrame&&requestAnimationFrame||setTimeout).bind(ct))();function af(t){return t.ownerDocument.defaultView}function Jn(t){return t instanceof Function?t():t}function uf(t,e,n){let r=t.length;for(;;){const i=t.indexOf(e,n);if(-1===i)return i;if(0===i||t.charCodeAt(i-1)<=32){const s=e.length;if(i+s===r||t.charCodeAt(i+s)<=32)return i}n=i+1}}const cf="ng-template";function I0(t,e,n){let r=0;for(;r<t.length;){let i=t[r++];if(n&&"class"===i){if(i=t[r],-1!==uf(i.toLowerCase(),e,0))return!0}else if(1===i){for(;r<t.length&&"string"==typeof(i=t[r++]);)if(i.toLowerCase()===e)return!0;return!1}}return!1}function df(t){return 4===t.type&&t.value!==cf}function x0(t,e,n){return e===(4!==t.type||n?t.value:cf)}function R0(t,e,n){let r=4;const i=t.attrs||[],s=function F0(t){for(let e=0;e<t.length;e++)if(Jd(t[e]))return e;return t.length}(i);let o=!1;for(let a=0;a<e.length;a++){const l=e[a];if("number"!=typeof l){if(!o)if(4&r){if(r=2|1&r,""!==l&&!x0(t,l,n)||""===l&&1===e.length){if(jn(r))return!1;o=!0}}else{const u=8&r?l:e[++a];if(8&r&&null!==t.attrs){if(!I0(t.attrs,u,n)){if(jn(r))return!1;o=!0}continue}const S=L0(8&r?"class":l,i,df(t),n);if(-1===S){if(jn(r))return!1;o=!0;continue}if(""!==u){let O;O=S>s?"":i[S+1].toLowerCase();const $=8&r?O:null;if($&&-1!==uf($,u,0)||2&r&&u!==O){if(jn(r))return!1;o=!0}}}}else{if(!o&&!jn(r)&&!jn(l))return!1;if(o&&jn(l))continue;o=!1,r=l|1&r}}return jn(r)||o}function jn(t){return 0==(1&t)}function L0(t,e,n,r){if(null===e)return-1;let i=0;if(r||!n){let s=!1;for(;i<e.length;){const o=e[i];if(o===t)return i;if(3===o||6===o)s=!0;else{if(1===o||2===o){let a=e[++i];for(;"string"==typeof a;)a=e[++i];continue}if(4===o)break;if(0===o){i+=4;continue}}i+=s?1:2}return-1}return function k0(t,e){let n=t.indexOf(4);if(n>-1)for(n++;n<t.length;){const r=t[n];if("number"==typeof r)return-1;if(r===e)return n;n++}return-1}(e,t)}function hf(t,e,n=!1){for(let r=0;r<e.length;r++)if(R0(t,e[r],n))return!0;return!1}function ff(t,e){return t?":not("+e.trim()+")":e}function B0(t){let e=t[0],n=1,r=2,i="",s=!1;for(;n<t.length;){let o=t[n];if("string"==typeof o)if(2&r){const a=t[++n];i+="["+o+(a.length>0?'="'+a+'"':"")+"]"}else 8&r?i+="."+o:4&r&&(i+=" "+o);else""!==i&&!jn(o)&&(e+=ff(s,i),i=""),r=o,s=s||!jn(r);n++}return""!==i&&(e+=ff(s,i)),e}const He={};function Sf(t,e){const n=t.contentQueries;if(null!==n)for(let r=0;r<n.length;r+=2){const i=n[r],s=n[r+1];if(-1!==s){const o=t.data[s];gl(i),o.contentQueries(2,e[s],s)}}}function ws(t,e,n,r,i,s,o,a,l,u){const g=e.blueprint.slice();return g[0]=i,g[2]=140|r,jd(g),g[3]=g[15]=t,g[8]=n,g[10]=o||t&&t[10],g[11]=a||t&&t[11],g[12]=l||t&&t[12]||null,g[9]=u||t&&t[9]||null,g[6]=s,g[16]=2==e.type?t[16]:g,g}function wi(t,e,n,r,i){let s=t.data[e];if(null===s)s=function hu(t,e,n,r,i){const s=Gd(),o=dl(),l=t.data[e]=function rA(t,e,n,r,i,s){return{type:n,index:r,insertBeforeIndex:null,injectorIndex:e?e.injectorIndex:-1,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,propertyBindings:null,flags:0,providerIndexes:0,value:i,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tViews:null,next:null,projectionNext:null,child:null,parent:e,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,n,e,r,i);return null===t.firstChild&&(t.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l)),l}(t,e,n,r,i),function vv(){return je.lFrame.inI18n}()&&(s.flags|=64);else if(64&s.type){s.type=n,s.value=r,s.attrs=i;const o=function is(){const t=je.lFrame,e=t.currentTNode;return t.isParent?e:e.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return Yn(s,!0),s}function Ei(t,e,n,r){if(0===n)return-1;const i=e.length;for(let s=0;s<n;s++)e.push(r),t.blueprint.push(r),t.data.push(null);return i}function Es(t,e,n){uo(e);try{const r=t.viewQuery;null!==r&&Au(1,r,n);const i=t.template;null!==i&&Df(t,e,i,1,n),t.firstCreatePass&&(t.firstCreatePass=!1),t.staticContentQueries&&Sf(t,e),t.staticViewQueries&&Au(2,t.viewQuery,n);const s=t.components;null!==s&&function eA(t,e){for(let n=0;n<e.length;n++)AA(t,e[n])}(e,s)}catch(r){throw t.firstCreatePass&&(t.incompleteFirstPass=!0,t.firstCreatePass=!1),r}finally{e[2]&=-5,co()}}function Si(t,e,n,r){const i=e[2];if(256!=(256&i)){uo(e);try{jd(e),function $d(t){return je.lFrame.bindingIndex=t}(t.bindingStartIndex),null!==n&&Df(t,e,n,2,r);const o=3==(3&i);if(o){const u=t.preOrderCheckHooks;null!==u&&fo(e,u,null)}else{const u=t.preOrderHooks;null!==u&&po(e,u,0,null),ml(e,0)}if(function vA(t){for(let e=kl(t);null!==e;e=Ol(e)){if(!e[2])continue;const n=e[9];for(let r=0;r<n.length;r++){const i=n[r],s=i[3];0==(1024&i[2])&&cl(s,1),i[2]|=1024}}}(e),function _A(t){for(let e=kl(t);null!==e;e=Ol(e))for(let n=10;n<e.length;n++){const r=e[n],i=r[1];ul(r)&&Si(i,r,i.template,r[8])}}(e),null!==t.contentQueries&&Sf(t,e),o){const u=t.contentCheckHooks;null!==u&&fo(e,u)}else{const u=t.contentHooks;null!==u&&po(e,u,1),ml(e,1)}!function Z0(t,e){const n=t.hostBindingOpCodes;if(null!==n)try{for(let r=0;r<n.length;r++){const i=n[r];if(i<0)Er(~i);else{const s=i,o=n[++r],a=n[++r];bv(o,s),a(2,e[s])}}}finally{Er(-1)}}(t,e);const a=t.components;null!==a&&function J0(t,e){for(let n=0;n<e.length;n++)bA(t,e[n])}(e,a);const l=t.viewQuery;if(null!==l&&Au(2,l,r),o){const u=t.viewCheckHooks;null!==u&&fo(e,u)}else{const u=t.viewHooks;null!==u&&po(e,u,2),ml(e,2)}!0===t.firstUpdatePass&&(t.firstUpdatePass=!1),e[2]&=-73,1024&e[2]&&(e[2]&=-1025,cl(e[3],-1))}finally{co()}}}function tA(t,e,n,r){const i=e[10],o=Vd(e);try{!o&&i.begin&&i.begin(),o&&Es(t,e,r),Si(t,e,n,r)}finally{!o&&i.end&&i.end()}}function Df(t,e,n,r,i){const s=function Xt(){return je.lFrame.selectedIndex}(),o=2&r;try{Er(-1),o&&e.length>20&&function pf(t,e,n,r){if(!r)if(3==(3&e[2])){const s=t.preOrderCheckHooks;null!==s&&fo(e,s,n)}else{const s=t.preOrderHooks;null!==s&&po(e,s,0,n)}Er(n)}(t,e,20,!1),n(r,i)}finally{Er(s)}}function Pf(t){const e=t.tView;return null===e||e.incompleteFirstPass?t.tView=Bo(1,null,t.template,t.decls,t.vars,t.directiveDefs,t.pipeDefs,t.viewQuery,t.schemas,t.consts):e}function Bo(t,e,n,r,i,s,o,a,l,u){const g=20+r,S=g+i,O=function nA(t,e){const n=[];for(let r=0;r<e;r++)n.push(r<t?null:He);return n}(g,S),$="function"==typeof u?u():u;return O[1]={type:t,blueprint:O,template:n,queries:null,viewQuery:a,declTNode:e,data:O.slice().fill(null,g),bindingStartIndex:g,expandoStartIndex:S,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:"function"==typeof s?s():s,pipeRegistry:"function"==typeof o?o():o,firstChild:null,schemas:l,consts:$,incompleteFirstPass:!1}}function xf(t,e,n,r){const i=Hf(e);null===n?i.push(r):(i.push(n),t.firstCreatePass&&Uf(t).push(r,i.length-1))}function Rf(t,e,n){for(let r in t)if(t.hasOwnProperty(r)){const i=t[r];(n=null===n?{}:n).hasOwnProperty(r)?n[r].push(e,i):n[r]=[e,i]}return n}function Nf(t,e,n,r,i,s){const o=s.hostBindings;if(o){let a=t.hostBindingOpCodes;null===a&&(a=t.hostBindingOpCodes=[]);const l=~e.index;(function uA(t){let e=t.length;for(;e>0;){const n=t[--e];if("number"==typeof n&&n<0)return n}return 0})(a)!=l&&a.push(l),a.push(r,i,o)}}function Ff(t,e){null!==t.hostBindings&&t.hostBindings(1,e)}function kf(t,e){e.flags|=2,(t.components||(t.components=[])).push(e.index)}function pA(t,e,n){if(n){if(e.exportAs)for(let r=0;r<e.exportAs.length;r++)n[e.exportAs[r]]=t;Vn(e)&&(n[""]=t)}}function Of(t,e,n){t.flags|=1,t.directiveStart=e,t.directiveEnd=e+n,t.providerIndexes=e}function Bf(t,e,n,r,i){t.data[r]=i;const s=i.factory||(i.factory=Ur(i.type)),o=new ss(s,Vn(i),null);t.blueprint[r]=o,n[r]=o,Nf(t,e,0,r,Ei(t,n,i.hostVars,He),i)}function gA(t,e,n){const r=cn(e,t),i=Pf(n),s=t[10],o=Vo(t,ws(t,i,null,n.onPush?64:16,r,e,s,s.createRenderer(r,n),null,null));t[e.index]=o}function mA(t,e,n,r,i,s){const o=s[e];if(null!==o){const a=r.setInput;for(let l=0;l<o.length;){const u=o[l++],g=o[l++],S=o[l++];null!==a?r.setInput(n,S,u,g):n[g]=S}}}function yA(t,e){let n=null,r=0;for(;r<e.length;){const i=e[r];if(0!==i)if(5!==i){if("number"==typeof i)break;t.hasOwnProperty(i)&&(null===n&&(n=[]),n.push(i,t[i],e[r+1])),r+=2}else r+=2;else r+=4}return n}function bA(t,e){const n=dn(e,t);if(ul(n)){const r=n[1];80&n[2]?Si(r,n,r.template,n[8]):n[5]>0&&yu(n)}}function yu(t){for(let r=kl(t);null!==r;r=Ol(r))for(let i=10;i<r.length;i++){const s=r[i];if(1024&s[2]){const o=s[1];Si(o,s,o.template,s[8])}else s[5]>0&&yu(s)}const n=t[1].components;if(null!==n)for(let r=0;r<n.length;r++){const i=dn(n[r],t);ul(i)&&i[5]>0&&yu(i)}}function AA(t,e){const n=dn(e,t),r=n[1];(function CA(t,e){for(let n=e.length;n<t.blueprint.length;n++)e.push(t.blueprint[n])})(r,n),Es(r,n,n[8])}function Vo(t,e){return t[13]?t[14][4]=e:t[13]=e,t[14]=e,e}function _u(t){for(;t;){t[2]|=64;const e=ys(t);if(X_(t)&&!e)return t;t=e}return null}function jf(t){!function vu(t){for(let e=0;e<t.components.length;e++){const n=t.components[e],r=Ll(n),i=r[1];tA(i,r,i.template,n)}}(t[8])}function Au(t,e,n){gl(0),e(t,n)}const EA=(()=>Promise.resolve(null))();function Hf(t){return t[7]||(t[7]=[])}function Uf(t){return t.cleanup||(t.cleanup=[])}function $f(t,e){const n=t[9],r=n?n.get(Cs,null):null;r&&r.handleError(e)}function zf(t,e,n,r,i){for(let s=0;s<n.length;){const o=n[s++],a=n[s++],l=e[o],u=t.data[o];null!==u.setInput?u.setInput(l,i,r,a):l[a]=i}}function jo(t,e,n){let r=n?t.styles:null,i=n?t.classes:null,s=0;if(null!==e)for(let o=0;o<e.length;o++){const a=e[o];"number"==typeof a?s=a:1==s?i=ri(i,a):2==s&&(r=ri(r,a+": "+e[++o]+";"))}n?t.styles=r:t.stylesWithoutHost=r,n?t.classes=i:t.classesWithoutHost=i}const Cu=new it("INJECTOR",-1);class Wf{get(e,n=hs){if(n===hs){const r=new Error(`NullInjectorError: No provider for ${et(e)}!`);throw r.name="NullInjectorError",r}return n}}const wu=new it("Set Injector scope."),Ss={},TA={};let Eu;function qf(){return void 0===Eu&&(Eu=new Wf),Eu}function Qf(t,e=null,n=null,r){const i=Kf(t,e,n,r);return i._resolveInjectorDefTypes(),i}function Kf(t,e=null,n=null,r){return new PA(t,n,e||qf(),r)}class PA{constructor(e,n,r,i=null){this.parent=r,this.records=new Map,this.injectorDefTypes=new Set,this.onDestroy=new Set,this._destroyed=!1;const s=[];n&&Xn(n,a=>this.processProvider(a,e,n)),Xn([e],a=>this.processInjectorType(a,[],s)),this.records.set(Cu,Di(void 0,this));const o=this.records.get(wu);this.scope=null!=o?o.value:null,this.source=i||("object"==typeof e?null:et(e))}get destroyed(){return this._destroyed}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{this.onDestroy.forEach(e=>e.ngOnDestroy())}finally{this.records.clear(),this.onDestroy.clear(),this.injectorDefTypes.clear()}}get(e,n=hs,r=Ge.Default){this.assertNotDestroyed();const i=yh(this),s=br(void 0);try{if(!(r&Ge.SkipSelf)){let a=this.records.get(e);if(void 0===a){const l=function kA(t){return"function"==typeof t||"object"==typeof t&&t instanceof it}(e)&&Qa(e);a=l&&this.injectableDefInScope(l)?Di(Su(e),Ss):null,this.records.set(e,a)}if(null!=a)return this.hydrate(e,a)}return(r&Ge.Self?qf():this.parent).get(e,n=r&Ge.Optional&&n===hs?null:n)}catch(o){if("NullInjectorError"===o.name){if((o[Eo]=o[Eo]||[]).unshift(et(e)),i)throw o;return function lb(t,e,n,r){const i=t[Eo];throw e[mh]&&i.unshift(e[mh]),t.message=function ub(t,e,n,r=null){t=t&&"\n"===t.charAt(0)&&"\u0275"==t.charAt(1)?t.substr(2):t;let i=et(e);if(Array.isArray(e))i=e.map(et).join(" -> ");else if("object"==typeof e){let s=[];for(let o in e)if(e.hasOwnProperty(o)){let a=e[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):et(a)))}i=`{${s.join(", ")}}`}return`${n}${r?"("+r+")":""}[${i}]: ${t.replace(nb,"\n ")}`}("\n"+t.message,i,n,r),t.ngTokenPath=i,t[Eo]=null,t}(o,e,"R3InjectorError",this.source)}throw o}finally{br(s),yh(i)}}_resolveInjectorDefTypes(){this.injectorDefTypes.forEach(e=>this.get(e))}toString(){const e=[];return this.records.forEach((r,i)=>e.push(et(i))),`R3Injector[${e.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new Me(205,!1)}processInjectorType(e,n,r){if(!(e=Ue(e)))return!1;let i=Sd(e);const s=null==i&&e.ngModule||void 0,o=void 0===s?e:s,a=-1!==r.indexOf(o);if(void 0!==s&&(i=Sd(s)),null==i)return!1;if(null!=i.imports&&!a){let g;r.push(o);try{Xn(i.imports,S=>{this.processInjectorType(S,n,r)&&(void 0===g&&(g=[]),g.push(S))})}finally{}if(void 0!==g)for(let S=0;S<g.length;S++){const{ngModule:O,providers:$}=g[S];Xn($,J=>this.processProvider(J,O,$||ht))}}this.injectorDefTypes.add(o);const l=Ur(o)||(()=>new o);this.records.set(o,Di(l,Ss));const u=i.providers;if(null!=u&&!a){const g=e;Xn(u,S=>this.processProvider(S,g,u))}return void 0!==s&&void 0!==e.providers}processProvider(e,n,r){let i=Ti(e=Ue(e))?e:Ue(e&&e.provide);const s=function IA(t,e,n){return Xf(t)?Di(void 0,t.useValue):Di(function Yf(t,e,n){let r;if(Ti(t)){const i=Ue(t);return Ur(i)||Su(i)}if(Xf(t))r=()=>Ue(t.useValue);else if(function RA(t){return!(!t||!t.useFactory)}(t))r=()=>t.useFactory(...Ml(t.deps||[]));else if(function xA(t){return!(!t||!t.useExisting)}(t))r=()=>tt(Ue(t.useExisting));else{const i=Ue(t&&(t.useClass||t.provide));if(!function NA(t){return!!t.deps}(t))return Ur(i)||Su(i);r=()=>new i(...Ml(t.deps))}return r}(t),Ss)}(e);if(Ti(e)||!0!==e.multi)this.records.get(i);else{let o=this.records.get(i);o||(o=Di(void 0,Ss,!0),o.factory=()=>Ml(o.multi),this.records.set(i,o)),i=e,o.multi.push(e)}this.records.set(i,s)}hydrate(e,n){return n.value===Ss&&(n.value=TA,n.value=n.factory()),"object"==typeof n.value&&n.value&&function FA(t){return null!==t&&"object"==typeof t&&"function"==typeof t.ngOnDestroy}(n.value)&&this.onDestroy.add(n.value),n.value}injectableDefInScope(e){if(!e.providedIn)return!1;const n=Ue(e.providedIn);return"string"==typeof n?"any"===n||n===this.scope:this.injectorDefTypes.has(n)}}function Su(t){const e=Qa(t),n=null!==e?e.factory:Ur(t);if(null!==n)return n;if(t instanceof it)throw new Me(204,!1);if(t instanceof Function)return function MA(t){const e=t.length;if(e>0)throw function ds(t,e){const n=[];for(let r=0;r<t;r++)n.push(e);return n}(e,"?"),new Me(204,!1);const n=function B_(t){const e=t&&(t[Js]||t[Dd]);if(e){const n=function V_(t){if(t.hasOwnProperty("name"))return t.name;const e=(""+t).match(/^function\s*([^\s(]+)/);return null===e?"":e[1]}(t);return console.warn(`DEPRECATED: DI is instantiating a token "${n}" that inherits its @Injectable decorator but does not provide one itself.\nThis will become an error in a future version of Angular. Please add @Injectable() to the "${n}" class.`),e}return null}(t);return null!==n?()=>n.factory(t):()=>new t}(t);throw new Me(204,!1)}function Di(t,e,n=!1){return{factory:t,value:e,multi:n?[]:void 0}}function Xf(t){return null!==t&&"object"==typeof t&&ib in t}function Ti(t){return"function"==typeof t}let Dn=(()=>{class t{static create(n,r){var i;if(Array.isArray(n))return Qf({name:""},r,n,"");{const s=null!==(i=n.name)&&void 0!==i?i:"";return Qf({name:s},n.parent,n.providers,s)}}}return t.THROW_IF_NOT_FOUND=hs,t.NULL=new Wf,t.\u0275prov=dt({token:t,providedIn:"any",factory:()=>tt(Cu)}),t.__NG_ELEMENT_ID__=-1,t})();function $A(t,e){ho(Ll(t)[1],Lt())}let Ho=null;function Pi(){if(!Ho){const t=ct.Symbol;if(t&&t.iterator)Ho=t.iterator;else{const e=Object.getOwnPropertyNames(Map.prototype);for(let n=0;n<e.length;++n){const r=e[n];"entries"!==r&&"size"!==r&&Map.prototype[r]===Map.prototype.entries&&(Ho=r)}}}return Ho}function Nu(t,e,n){const r=me();return function qt(t,e,n){return!Object.is(t[e],n)&&(t[e]=n,!0)}(r,function di(){return je.lFrame.bindingIndex++}(),e)&&function pn(t,e,n,r,i,s,o,a){const l=cn(e,n);let g,u=e.inputs;!a&&null!=u&&(g=u[r])?(zf(t,n,g,r,i),so(e)&&function oA(t,e){const n=dn(e,t);16&n[2]||(n[2]|=64)}(n,e.index)):3&e.type&&(r=function sA(t){return"class"===t?"className":"for"===t?"htmlFor":"formaction"===t?"formAction":"innerHtml"===t?"innerHTML":"readonly"===t?"readOnly":"tabindex"===t?"tabIndex":t}(r),i=null!=o?o(i,e.value||"",r):i,St(s)?s.setProperty(l,r,i):_l(r)||(l.setProperty?l.setProperty(r,i):l[r]=i))}(rt(),function vt(){const t=je.lFrame;return ll(t.tView,t.selectedIndex)}(),r,t,e,r[11],n,!1),Nu}function Fu(t,e,n,r,i){const o=i?"class":"style";zf(t,n,e.inputs[o],o,r)}function Ps(t,e,n,r){const i=me(),s=rt(),o=20+t,a=i[11],l=i[o]=Vl(a,e,function Mv(){return je.lFrame.currentNamespace}()),u=s.firstCreatePass?function SC(t,e,n,r,i,s,o){const a=e.consts,u=wi(e,t,2,i,wr(a,s));return function gu(t,e,n,r){let i=!1;if(Ud()){const s=function hA(t,e,n){const r=t.directiveRegistry;let i=null;if(r)for(let s=0;s<r.length;s++){const o=r[s];hf(n,o.selectors,!1)&&(i||(i=[]),vo(as(n,e),t,o.type),Vn(o)?(kf(t,n),i.unshift(o)):i.push(o))}return i}(t,e,n),o=null===r?null:{"":-1};if(null!==s){i=!0,Of(n,t.data.length,s.length);for(let g=0;g<s.length;g++){const S=s[g];S.providersResolver&&S.providersResolver(S)}let a=!1,l=!1,u=Ei(t,e,s.length,null);for(let g=0;g<s.length;g++){const S=s[g];n.mergedAttrs=mo(n.mergedAttrs,S.hostAttrs),Bf(t,n,e,u,S),pA(u,S,o),null!==S.contentQueries&&(n.flags|=8),(null!==S.hostBindings||null!==S.hostAttrs||0!==S.hostVars)&&(n.flags|=128);const O=S.type.prototype;!a&&(O.ngOnChanges||O.ngOnInit||O.ngDoCheck)&&((t.preOrderHooks||(t.preOrderHooks=[])).push(n.index),a=!0),!l&&(O.ngOnChanges||O.ngDoCheck)&&((t.preOrderCheckHooks||(t.preOrderCheckHooks=[])).push(n.index),l=!0),u++}!function iA(t,e){const r=e.directiveEnd,i=t.data,s=e.attrs,o=[];let a=null,l=null;for(let u=e.directiveStart;u<r;u++){const g=i[u],S=g.inputs,O=null===s||df(e)?null:yA(S,s);o.push(O),a=Rf(S,u,a),l=Rf(g.outputs,u,l)}null!==a&&(a.hasOwnProperty("class")&&(e.flags|=16),a.hasOwnProperty("style")&&(e.flags|=32)),e.initialInputs=o,e.inputs=a,e.outputs=l}(t,n)}o&&function fA(t,e,n){if(e){const r=t.localNames=[];for(let i=0;i<e.length;i+=2){const s=n[e[i+1]];if(null==s)throw new Me(-301,!1);r.push(e[i],s)}}}(n,r,o)}return n.mergedAttrs=mo(n.mergedAttrs,n.attrs),i}(e,n,u,wr(a,o)),null!==u.attrs&&jo(u,u.attrs,!1),null!==u.mergedAttrs&&jo(u,u.mergedAttrs,!0),null!==e.queries&&e.queries.elementStart(e,u),u}(o,s,i,0,e,n,r):s.data[o];Yn(u,!0);const g=u.mergedAttrs;null!==g&&go(a,l,g);const S=u.classes;null!==S&&Wl(a,l,S);const O=u.styles;return null!==O&&Wh(a,l,O),64!=(64&u.flags)&&Mo(s,i,l,u),0===function hv(){return je.lFrame.elementDepthCount}()&&Wt(l,i),function fv(){je.lFrame.elementDepthCount++}(),oo(u)&&(function fu(t,e,n){!Ud()||(function cA(t,e,n,r){const i=n.directiveStart,s=n.directiveEnd;t.firstCreatePass||as(n,e),Wt(r,e);const o=n.initialInputs;for(let a=i;a<s;a++){const l=t.data[a],u=Vn(l);u&&gA(e,n,l);const g=ls(e,t,a,n);Wt(g,e),null!==o&&mA(0,a-i,g,l,0,o),u&&(dn(n.index,e)[8]=g)}}(t,e,n,cn(n,e)),128==(128&n.flags)&&function dA(t,e,n){const r=n.directiveStart,i=n.directiveEnd,o=n.index,a=function Av(){return je.lFrame.currentDirectiveIndex}();try{Er(o);for(let l=r;l<i;l++){const u=t.data[l],g=e[l];fl(l),(null!==u.hostBindings||0!==u.hostVars||null!==u.hostAttrs)&&Ff(u,g)}}finally{Er(-1),fl(a)}}(t,e,n))}(s,i,u),function Tf(t,e,n){if(tl(e)){const i=e.directiveEnd;for(let s=e.directiveStart;s<i;s++){const o=t.data[s];o.contentQueries&&o.contentQueries(1,n[s],s)}}}(s,u,i)),null!==r&&function pu(t,e,n=cn){const r=e.localNames;if(null!==r){let i=e.index+1;for(let s=0;s<r.length;s+=2){const o=r[s+1],a=-1===o?n(e,t):t[o];t[i++]=a}}}(i,u),Ps}function Ms(){let t=Lt();dl()?function hl(){je.lFrame.isParent=!1}():(t=t.parent,Yn(t,!1));const e=t;!function pv(){je.lFrame.elementDepthCount--}();const n=rt();return n.firstCreatePass&&(ho(n,t),tl(t)&&n.queries.elementEnd(t)),null!=e.classesWithoutHost&&function Nv(t){return 0!=(16&t.flags)}(e)&&Fu(n,e,me(),e.classesWithoutHost,!0),null!=e.stylesWithoutHost&&function Fv(t){return 0!=(32&t.flags)}(e)&&Fu(n,e,me(),e.stylesWithoutHost,!1),Ms}function ku(t,e,n,r){return Ps(t,e,n,r),Ms(),ku}function Vu(t){return!!t&&"function"==typeof t.then}const PC=function Rp(t){return!!t&&"function"==typeof t.subscribe};function $o(t,e,n,r){const i=me(),s=rt(),o=Lt();return function Np(t,e,n,r,i,s,o,a){const l=oo(r),g=t.firstCreatePass&&Uf(t),S=e[8],O=Hf(e);let $=!0;if(3&r.type||a){const fe=cn(r,e),ve=a?a(fe):fe,oe=O.length,Ee=a?Re=>a(Mt(Re[r.index])):r.index;if(St(n)){let Re=null;if(!a&&l&&(Re=function MC(t,e,n,r){const i=t.cleanup;if(null!=i)for(let s=0;s<i.length-1;s+=2){const o=i[s];if(o===n&&i[s+1]===r){const a=e[7],l=i[s+2];return a.length>l?a[l]:null}"string"==typeof o&&(s+=2)}return null}(t,e,i,r.index)),null!==Re)(Re.__ngLastListenerFn__||Re).__ngNextListenerFn__=s,Re.__ngLastListenerFn__=s,$=!1;else{s=ju(r,e,S,s,!1);const We=n.listen(ve,i,s);O.push(s,We),g&&g.push(i,Ee,oe,oe+1)}}else s=ju(r,e,S,s,!0),ve.addEventListener(i,s,o),O.push(s),g&&g.push(i,Ee,oe,o)}else s=ju(r,e,S,s,!1);const J=r.outputs;let se;if($&&null!==J&&(se=J[i])){const fe=se.length;if(fe)for(let ve=0;ve<fe;ve+=2){const yt=e[se[ve]][se[ve+1]].subscribe(s),Ct=O.length;O.push(s,yt),g&&g.push(i,r.index,Ct,-(Ct+1))}}}(s,i,i[11],o,t,e,!!n,r),$o}function Fp(t,e,n,r){try{return!1!==n(r)}catch(i){return $f(t,i),!1}}function ju(t,e,n,r,i){return function s(o){if(o===Function)return r;const a=2&t.flags?dn(t.index,e):e;0==(32&e[2])&&_u(a);let l=Fp(e,0,r,o),u=s.__ngNextListenerFn__;for(;u;)l=Fp(e,0,u,o)&&l,u=u.__ngNextListenerFn__;return i&&!1===l&&(o.preventDefault(),o.returnValue=!1),l}}const Wo="en-US";let Pg=Wo;class Jg{}class AE{resolveComponentFactory(e){throw function bE(t){const e=Error(`No component factory found for ${et(t)}. Did you add it to @NgModule.entryComponents?`);return e.ngComponent=t,e}(e)}}let Ui=(()=>{class t{}return t.NULL=new AE,t})();function CE(){return Gi(Lt(),me())}function Gi(t,e){return new Mr(cn(t,e))}let Mr=(()=>{class t{constructor(n){this.nativeElement=n}}return t.__NG_ELEMENT_ID__=CE,t})();function wE(t){return t instanceof Mr?t.nativeElement:t}class Fs{}let DE=(()=>{class t{}return t.\u0275prov=dt({token:t,providedIn:"root",factory:()=>null}),t})();class Xo{constructor(e){this.full=e,this.major=e.split(".")[0],this.minor=e.split(".")[1],this.patch=e.split(".").slice(2).join(".")}}const TE=new Xo("13.4.0"),Yu={};function Zo(t,e,n,r,i=!1){for(;null!==n;){const s=e[n.index];if(null!==s&&r.push(Mt(s)),Bn(s))for(let a=10;a<s.length;a++){const l=s[a],u=l[1].firstChild;null!==u&&Zo(l[1],l,u,r)}const o=n.type;if(8&o)Zo(t,e,n.child,r);else if(32&o){const a=Fl(n,e);let l;for(;l=a();)r.push(l)}else if(16&o){const a=$h(e,n);if(Array.isArray(a))r.push(...a);else{const l=ys(e[16]);Zo(l[1],l,a,r,!0)}}n=i?n.projectionNext:n.next}return r}class ks{constructor(e,n){this._lView=e,this._cdRefInjectingView=n,this._appRef=null,this._attachedToViewContainer=!1}get rootNodes(){const e=this._lView,n=e[1];return Zo(n,e,n.firstChild,[])}get context(){return this._lView[8]}set context(e){this._lView[8]=e}get destroyed(){return 256==(256&this._lView[2])}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){const e=this._lView[3];if(Bn(e)){const n=e[8],r=n?n.indexOf(this):-1;r>-1&&(jl(e,r),Co(n,r))}this._attachedToViewContainer=!1}Fh(this._lView[1],this._lView)}onDestroy(e){xf(this._lView[1],this._lView,null,e)}markForCheck(){_u(this._cdRefInjectingView||this._lView)}detach(){this._lView[2]&=-129}reattach(){this._lView[2]|=128}detectChanges(){!function bu(t,e,n){const r=e[10];r.begin&&r.begin();try{Si(t,e,t.template,n)}catch(i){throw $f(e,i),i}finally{r.end&&r.end()}}(this._lView[1],this._lView,this.context)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new Me(902,"");this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,function Rb(t,e){_s(t,e,e[11],2,null,null)}(this._lView[1],this._lView)}attachToAppRef(e){if(this._attachedToViewContainer)throw new Me(902,"");this._appRef=e}}class PE extends ks{constructor(e){super(e),this._view=e}detectChanges(){jf(this._view)}checkNoChanges(){}get context(){return null}}class nm extends Ui{constructor(e){super(),this.ngModule=e}resolveComponentFactory(e){const n=Ut(e);return new Xu(n,this.ngModule)}}function rm(t){const e=[];for(let n in t)t.hasOwnProperty(n)&&e.push({propName:t[n],templateName:n});return e}class Xu extends Jg{constructor(e,n){super(),this.componentDef=e,this.ngModule=n,this.componentType=e.type,this.selector=function V0(t){return t.map(B0).join(",")}(e.selectors),this.ngContentSelectors=e.ngContentSelectors?e.ngContentSelectors:[],this.isBoundToModule=!!n}get inputs(){return rm(this.componentDef.inputs)}get outputs(){return rm(this.componentDef.outputs)}create(e,n,r,i){const s=(i=i||this.ngModule)?function IE(t,e){return{get:(n,r,i)=>{const s=t.get(n,Yu,i);return s!==Yu||r===Yu?s:e.get(n,r,i)}}}(e,i.injector):e,o=s.get(Fs,Bd),a=s.get(DE,null),l=o.createRenderer(null,this.componentDef),u=this.componentDef.selectors[0][0]||"div",g=r?function If(t,e,n){if(St(t))return t.selectRootElement(e,n===kn.ShadowDom);let r="string"==typeof e?t.querySelector(e):e;return r.textContent="",r}(l,r,this.componentDef.encapsulation):Vl(o.createRenderer(null,this.componentDef),u,function ME(t){const e=t.toLowerCase();return"svg"===e?"svg":"math"===e?"math":null}(u)),S=this.componentDef.onPush?576:528,O=function lp(t,e){return{components:[],scheduler:t||T0,clean:EA,playerHandler:e||null,flags:0}}(),$=Bo(0,null,null,1,0,null,null,null,null,null),J=ws(null,$,O,S,null,null,o,l,a,s);let se,fe;uo(J);try{const ve=function op(t,e,n,r,i,s){const o=n[1];n[20]=t;const l=wi(o,20,2,"#host",null),u=l.mergedAttrs=e.hostAttrs;null!==u&&(jo(l,u,!0),null!==t&&(go(i,t,u),null!==l.classes&&Wl(i,t,l.classes),null!==l.styles&&Wh(i,t,l.styles)));const g=r.createRenderer(t,e),S=ws(n,Pf(e),null,e.onPush?64:16,n[20],l,r,g,s||null,null);return o.firstCreatePass&&(vo(as(l,n),o,e.type),kf(o,l),Of(l,n.length,1)),Vo(n,S),n[20]=S}(g,this.componentDef,J,o,l);if(g)if(r)go(l,g,["ng-version",TE.full]);else{const{attrs:oe,classes:Ee}=function j0(t){const e=[],n=[];let r=1,i=2;for(;r<t.length;){let s=t[r];if("string"==typeof s)2===i?""!==s&&e.push(s,t[++r]):8===i&&n.push(s);else{if(!jn(i))break;i=s}r++}return{attrs:e,classes:n}}(this.componentDef.selectors[0]);oe&&go(l,g,oe),Ee&&Ee.length>0&&Wl(l,g,Ee.join(" "))}if(fe=ll($,20),void 0!==n){const oe=fe.projection=[];for(let Ee=0;Ee<this.ngContentSelectors.length;Ee++){const Re=n[Ee];oe.push(null!=Re?Array.from(Re):null)}}se=function ap(t,e,n,r,i){const s=n[1],o=function lA(t,e,n){const r=Lt();t.firstCreatePass&&(n.providersResolver&&n.providersResolver(n),Bf(t,r,e,Ei(t,e,1,null),n));const i=ls(e,t,r.directiveStart,r);Wt(i,e);const s=cn(r,e);return s&&Wt(s,e),i}(s,n,e);if(r.components.push(o),t[8]=o,i&&i.forEach(l=>l(o,e)),e.contentQueries){const l=Lt();e.contentQueries(1,o,l.directiveStart)}const a=Lt();return!s.firstCreatePass||null===e.hostBindings&&null===e.hostAttrs||(Er(a.index),Nf(n[1],a,0,a.directiveStart,a.directiveEnd,e),Ff(e,o)),o}(ve,this.componentDef,J,O,[$A]),Es($,J,null)}finally{co()}return new RE(this.componentType,se,Gi(fe,J),J,fe)}}class RE extends class vE{}{constructor(e,n,r,i,s){super(),this.location=r,this._rootLView=i,this._tNode=s,this.instance=n,this.hostView=this.changeDetectorRef=new PE(i),this.componentType=e}get injector(){return new pi(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(e){this.hostView.onDestroy(e)}}class $i{}const zi=new Map;class om extends $i{constructor(e,n){super(),this._parent=n,this._bootstrapComponents=[],this.injector=this,this.destroyCbs=[],this.componentFactoryResolver=new nm(this);const r=Cn(e);this._bootstrapComponents=Jn(r.bootstrap),this._r3Injector=Kf(e,n,[{provide:$i,useValue:this},{provide:Ui,useValue:this.componentFactoryResolver}],et(e)),this._r3Injector._resolveInjectorDefTypes(),this.instance=this.get(e)}get(e,n=Dn.THROW_IF_NOT_FOUND,r=Ge.Default){return e===Dn||e===$i||e===Cu?this:this._r3Injector.get(e,n,r)}destroy(){const e=this._r3Injector;!e.destroyed&&e.destroy(),this.destroyCbs.forEach(n=>n()),this.destroyCbs=null}onDestroy(e){this.destroyCbs.push(e)}}class Zu extends class NE{}{constructor(e){super(),this.moduleType=e,null!==Cn(e)&&function FE(t){const e=new Set;!function n(r){const i=Cn(r,!0),s=i.id;null!==s&&(function im(t,e,n){if(e&&e!==n)throw new Error(`Duplicate module registered for ${t} - ${et(e)} vs ${et(e.name)}`)}(s,zi.get(s),r),zi.set(s,r));const o=Jn(i.imports);for(const a of o)e.has(a)||(e.add(a),n(a))}(t)}(e)}create(e){return new om(this.moduleType,e)}}function Ju(t){return e=>{setTimeout(t,void 0,e)}}const en=class JE extends G{constructor(e=!1){super(),this.__isAsync=e}emit(e){super.next(e)}subscribe(e,n,r){var i,s,o;let a=e,l=n||(()=>null),u=r;if(e&&"object"==typeof e){const S=e;a=null===(i=S.next)||void 0===i?void 0:i.bind(S),l=null===(s=S.error)||void 0===s?void 0:s.bind(S),u=null===(o=S.complete)||void 0===o?void 0:o.bind(S)}this.__isAsync&&(l=Ju(l),a&&(a=Ju(a)),u&&(u=Ju(u)));const g=super.subscribe({next:a,error:l,complete:u});return e instanceof k&&e.add(g),g}};function eS(){return this._results[Pi()]()}class ec{constructor(e=!1){this._emitDistinctChangesOnly=e,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=null,this.length=0,this.first=void 0,this.last=void 0;const n=Pi(),r=ec.prototype;r[n]||(r[n]=eS)}get changes(){return this._changes||(this._changes=new en)}get(e){return this._results[e]}map(e){return this._results.map(e)}filter(e){return this._results.filter(e)}find(e){return this._results.find(e)}reduce(e,n){return this._results.reduce(e,n)}forEach(e){this._results.forEach(e)}some(e){return this._results.some(e)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(e,n){const r=this;r.dirty=!1;const i=Sn(e);(this._changesDetected=!function qv(t,e,n){if(t.length!==e.length)return!1;for(let r=0;r<t.length;r++){let i=t[r],s=e[r];if(n&&(i=n(i),s=n(s)),s!==i)return!1}return!0}(r._results,i,n))&&(r._results=i,r.length=i.length,r.last=i[this.length-1],r.first=i[0])}notifyOnChanges(){this._changes&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.emit(this)}setDirty(){this.dirty=!0}destroy(){this.changes.complete(),this.changes.unsubscribe()}}Symbol;let fr=(()=>{class t{}return t.__NG_ELEMENT_ID__=rS,t})();const tS=fr,nS=class extends tS{constructor(e,n,r){super(),this._declarationLView=e,this._declarationTContainer=n,this.elementRef=r}createEmbeddedView(e){const n=this._declarationTContainer.tViews,r=ws(this._declarationLView,n,e,16,null,n.declTNode,null,null,null,null);r[17]=this._declarationLView[this._declarationTContainer.index];const s=this._declarationLView[19];return null!==s&&(r[19]=s.createEmbeddedView(n)),Es(n,r,e),new ks(r)}};function rS(){return Jo(Lt(),me())}function Jo(t,e){return 4&t.type?new nS(e,t,Gi(t,e)):null}let ir=(()=>{class t{}return t.__NG_ELEMENT_ID__=iS,t})();function iS(){return pm(Lt(),me())}const sS=ir,hm=class extends sS{constructor(e,n,r){super(),this._lContainer=e,this._hostTNode=n,this._hostLView=r}get element(){return Gi(this._hostTNode,this._hostLView)}get injector(){return new pi(this._hostTNode,this._hostLView)}get parentInjector(){const e=_o(this._hostTNode,this._hostLView);if(th(e)){const n=fi(e,this._hostLView),r=hi(e);return new pi(n[1].data[r+8],n)}return new pi(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(e){const n=fm(this._lContainer);return null!==n&&n[e]||null}get length(){return this._lContainer.length-10}createEmbeddedView(e,n,r){const i=e.createEmbeddedView(n||{});return this.insert(i,r),i}createComponent(e,n,r,i,s){const o=e&&!function cs(t){return"function"==typeof t}(e);let a;if(o)a=n;else{const S=n||{};a=S.index,r=S.injector,i=S.projectableNodes,s=S.ngModuleRef}const l=o?e:new Xu(Ut(e)),u=r||this.parentInjector;if(!s&&null==l.ngModule){const O=(o?u:this.parentInjector).get($i,null);O&&(s=O)}const g=l.create(u,i,void 0,s);return this.insert(g.hostView,a),g}insert(e,n){const r=e._lView,i=r[1];if(function dv(t){return Bn(t[3])}(r)){const g=this.indexOf(e);if(-1!==g)this.detach(g);else{const S=r[3],O=new hm(S,S[6],S[3]);O.detach(O.indexOf(e))}}const s=this._adjustIndex(n),o=this._lContainer;!function Nb(t,e,n,r){const i=10+r,s=n.length;r>0&&(n[i-1][4]=e),r<s-10?(e[4]=n[i],dh(n,10+r,e)):(n.push(e),e[4]=null),e[3]=n;const o=e[17];null!==o&&n!==o&&function Fb(t,e){const n=t[9];e[16]!==e[3][3][16]&&(t[2]=!0),null===n?t[9]=[e]:n.push(e)}(o,e);const a=e[19];null!==a&&a.insertView(t),e[2]|=128}(i,r,o,s);const a=Gl(s,o),l=r[11],u=Po(l,o[7]);return null!==u&&function xb(t,e,n,r,i,s){r[0]=i,r[6]=e,_s(t,r,n,1,i,s)}(i,o[6],l,r,u,a),e.attachToViewContainerRef(),dh(tc(o),s,e),e}move(e,n){return this.insert(e,n)}indexOf(e){const n=fm(this._lContainer);return null!==n?n.indexOf(e):-1}remove(e){const n=this._adjustIndex(e,-1),r=jl(this._lContainer,n);r&&(Co(tc(this._lContainer),n),Fh(r[1],r))}detach(e){const n=this._adjustIndex(e,-1),r=jl(this._lContainer,n);return r&&null!=Co(tc(this._lContainer),n)?new ks(r):null}_adjustIndex(e,n=0){return null==e?this.length+n:e}};function fm(t){return t[8]}function tc(t){return t[8]||(t[8]=[])}function pm(t,e){let n;const r=e[t.index];if(Bn(r))n=r;else{let i;if(8&t.type)i=Mt(r);else{const s=e[11];i=s.createComment("");const o=cn(t,e);Gr(s,Po(s,o),i,function Vb(t,e){return St(t)?t.nextSibling(e):e.nextSibling}(s,o),!1)}e[t.index]=n=function Vf(t,e,n,r){return new Array(t,!0,!1,e,null,0,r,n,null,null)}(r,e,i,t),Vo(e,n)}return new hm(n,t,e)}class nc{constructor(e){this.queryList=e,this.matches=null}clone(){return new nc(this.queryList)}setDirty(){this.queryList.setDirty()}}class rc{constructor(e=[]){this.queries=e}createEmbeddedView(e){const n=e.queries;if(null!==n){const r=null!==e.contentQueries?e.contentQueries[0]:n.length,i=[];for(let s=0;s<r;s++){const o=n.getByIndex(s);i.push(this.queries[o.indexInDeclarationView].clone())}return new rc(i)}return null}insertView(e){this.dirtyQueriesWithMatches(e)}detachView(e){this.dirtyQueriesWithMatches(e)}dirtyQueriesWithMatches(e){for(let n=0;n<this.queries.length;n++)null!==vm(e,n).matches&&this.queries[n].setDirty()}}class gm{constructor(e,n,r=null){this.predicate=e,this.flags=n,this.read=r}}class ic{constructor(e=[]){this.queries=e}elementStart(e,n){for(let r=0;r<this.queries.length;r++)this.queries[r].elementStart(e,n)}elementEnd(e){for(let n=0;n<this.queries.length;n++)this.queries[n].elementEnd(e)}embeddedTView(e){let n=null;for(let r=0;r<this.length;r++){const i=null!==n?n.length:0,s=this.getByIndex(r).embeddedTView(e,i);s&&(s.indexInDeclarationView=r,null!==n?n.push(s):n=[s])}return null!==n?new ic(n):null}template(e,n){for(let r=0;r<this.queries.length;r++)this.queries[r].template(e,n)}getByIndex(e){return this.queries[e]}get length(){return this.queries.length}track(e){this.queries.push(e)}}class sc{constructor(e,n=-1){this.metadata=e,this.matches=null,this.indexInDeclarationView=-1,this.crossesNgTemplate=!1,this._appliesToNextNode=!0,this._declarationNodeIndex=n}elementStart(e,n){this.isApplyingToNode(n)&&this.matchTNode(e,n)}elementEnd(e){this._declarationNodeIndex===e.index&&(this._appliesToNextNode=!1)}template(e,n){this.elementStart(e,n)}embeddedTView(e,n){return this.isApplyingToNode(e)?(this.crossesNgTemplate=!0,this.addMatch(-e.index,n),new sc(this.metadata)):null}isApplyingToNode(e){if(this._appliesToNextNode&&1!=(1&this.metadata.flags)){const n=this._declarationNodeIndex;let r=e.parent;for(;null!==r&&8&r.type&&r.index!==n;)r=r.parent;return n===(null!==r?r.index:-1)}return this._appliesToNextNode}matchTNode(e,n){const r=this.metadata.predicate;if(Array.isArray(r))for(let i=0;i<r.length;i++){const s=r[i];this.matchTNodeWithReadOption(e,n,lS(n,s)),this.matchTNodeWithReadOption(e,n,bo(n,e,s,!1,!1))}else r===fr?4&n.type&&this.matchTNodeWithReadOption(e,n,-1):this.matchTNodeWithReadOption(e,n,bo(n,e,r,!1,!1))}matchTNodeWithReadOption(e,n,r){if(null!==r){const i=this.metadata.read;if(null!==i)if(i===Mr||i===ir||i===fr&&4&n.type)this.addMatch(n.index,-2);else{const s=bo(n,e,i,!1,!1);null!==s&&this.addMatch(n.index,s)}else this.addMatch(n.index,r)}}addMatch(e,n){null===this.matches?this.matches=[e,n]:this.matches.push(e,n)}}function lS(t,e){const n=t.localNames;if(null!==n)for(let r=0;r<n.length;r+=2)if(n[r]===e)return n[r+1];return null}function cS(t,e,n,r){return-1===n?function uS(t,e){return 11&t.type?Gi(t,e):4&t.type?Jo(t,e):null}(e,t):-2===n?function dS(t,e,n){return n===Mr?Gi(e,t):n===fr?Jo(e,t):n===ir?pm(e,t):void 0}(t,e,r):ls(t,t[1],n,e)}function mm(t,e,n,r){const i=e[19].queries[r];if(null===i.matches){const s=t.data,o=n.matches,a=[];for(let l=0;l<o.length;l+=2){const u=o[l];a.push(u<0?null:cS(e,s[u],o[l+1],n.metadata.read))}i.matches=a}return i.matches}function oc(t,e,n,r){const i=t.queries.getByIndex(n),s=i.matches;if(null!==s){const o=mm(t,e,i,n);for(let a=0;a<s.length;a+=2){const l=s[a];if(l>0)r.push(o[a/2]);else{const u=s[a+1],g=e[-l];for(let S=10;S<g.length;S++){const O=g[S];O[17]===O[3]&&oc(O[1],O,u,r)}if(null!==g[9]){const S=g[9];for(let O=0;O<S.length;O++){const $=S[O];oc($[1],$,u,r)}}}}}return r}function ac(t){const e=me(),n=rt(),r=Wd();gl(r+1);const i=vm(n,r);if(t.dirty&&Vd(e)===(2==(2&i.metadata.flags))){if(null===i.matches)t.reset([]);else{const s=i.crossesNgTemplate?oc(n,e,r,[]):mm(n,e,i,r);t.reset(s,wE),t.notifyOnChanges()}return!0}return!1}function lc(t,e,n){const r=rt();r.firstCreatePass&&(function _m(t,e,n){null===t.queries&&(t.queries=new ic),t.queries.track(new sc(e,n))}(r,new gm(t,e,n),-1),2==(2&e)&&(r.staticViewQueries=!0)),function ym(t,e,n){const r=new ec(4==(4&n));xf(t,e,r,r.destroy),null===e[19]&&(e[19]=new rc),e[19].queries.push(new nc(r))}(r,me(),e)}function uc(){return function fS(t,e){return t[19].queries[e].queryList}(me(),Wd())}function vm(t,e){return t.queries.getByIndex(e)}const nn=Ao("Input",t=>({bindingPropertyName:t})),qi=Ao("Output",t=>({bindingPropertyName:t})),RS=Ao("HostListener",(t,e)=>({eventName:t,args:e}));function na(...t){}const km=new it("Application Initializer");let gc=(()=>{class t{constructor(n){this.appInits=n,this.resolve=na,this.reject=na,this.initialized=!1,this.done=!1,this.donePromise=new Promise((r,i)=>{this.resolve=r,this.reject=i})}runInitializers(){if(this.initialized)return;const n=[],r=()=>{this.done=!0,this.resolve()};if(this.appInits)for(let i=0;i<this.appInits.length;i++){const s=this.appInits[i]();if(Vu(s))n.push(s);else if(PC(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});n.push(o)}}Promise.all(n).then(()=>{r()}).catch(i=>{this.reject(i)}),0===n.length&&r(),this.initialized=!0}}return t.\u0275fac=function(n){return new(n||t)(tt(km,8))},t.\u0275prov=dt({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();const js=new it("AppId",{providedIn:"root",factory:function Om(){return`${mc()}${mc()}${mc()}`}});function mc(){return String.fromCharCode(97+Math.floor(25*Math.random()))}const Bm=new it("Platform Initializer"),Vm=new it("Platform ID",{providedIn:"platform",factory:()=>"unknown"}),LS=new it("appBootstrapListener"),Ir=new it("LocaleId",{providedIn:"root",factory:()=>ob(Ir,Ge.Optional|Ge.SkipSelf)||function NS(){return"undefined"!=typeof $localize&&$localize.locale||Wo}()}),BS=(()=>Promise.resolve(0))();function yc(t){"undefined"==typeof Zone?BS.then(()=>{t&&t.apply(null,null)}):Zone.current.scheduleMicroTask("scheduleMicrotask",t)}class Gt{constructor({enableLongStackTrace:e=!1,shouldCoalesceEventChangeDetection:n=!1,shouldCoalesceRunChangeDetection:r=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new en(!1),this.onMicrotaskEmpty=new en(!1),this.onStable=new en(!1),this.onError=new en(!1),"undefined"==typeof Zone)throw new Error("In this configuration Angular requires Zone.js");Zone.assertZonePatched();const i=this;i._nesting=0,i._outer=i._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(i._inner=i._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(i._inner=i._inner.fork(Zone.longStackTraceZoneSpec)),i.shouldCoalesceEventChangeDetection=!r&&n,i.shouldCoalesceRunChangeDetection=r,i.lastRequestAnimationFrameId=-1,i.nativeRequestAnimationFrame=function VS(){let t=ct.requestAnimationFrame,e=ct.cancelAnimationFrame;if("undefined"!=typeof Zone&&t&&e){const n=t[Zone.__symbol__("OriginalDelegate")];n&&(t=n);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function US(t){const e=()=>{!function HS(t){t.isCheckStableRunning||-1!==t.lastRequestAnimationFrameId||(t.lastRequestAnimationFrameId=t.nativeRequestAnimationFrame.call(ct,()=>{t.fakeTopEventTask||(t.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{t.lastRequestAnimationFrameId=-1,vc(t),t.isCheckStableRunning=!0,_c(t),t.isCheckStableRunning=!1},void 0,()=>{},()=>{})),t.fakeTopEventTask.invoke()}),vc(t))}(t)};t._inner=t._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(n,r,i,s,o,a)=>{try{return jm(t),n.invokeTask(i,s,o,a)}finally{(t.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||t.shouldCoalesceRunChangeDetection)&&e(),Hm(t)}},onInvoke:(n,r,i,s,o,a,l)=>{try{return jm(t),n.invoke(i,s,o,a,l)}finally{t.shouldCoalesceRunChangeDetection&&e(),Hm(t)}},onHasTask:(n,r,i,s)=>{n.hasTask(i,s),r===i&&("microTask"==s.change?(t._hasPendingMicrotasks=s.microTask,vc(t),_c(t)):"macroTask"==s.change&&(t.hasPendingMacrotasks=s.macroTask))},onHandleError:(n,r,i,s)=>(n.handleError(i,s),t.runOutsideAngular(()=>t.onError.emit(s)),!1)})}(i)}static isInAngularZone(){return"undefined"!=typeof Zone&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Gt.isInAngularZone())throw new Error("Expected to be in Angular Zone, but it is not!")}static assertNotInAngularZone(){if(Gt.isInAngularZone())throw new Error("Expected to not be in Angular Zone, but it is!")}run(e,n,r){return this._inner.run(e,n,r)}runTask(e,n,r,i){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+i,e,jS,na,na);try{return s.runTask(o,n,r)}finally{s.cancelTask(o)}}runGuarded(e,n,r){return this._inner.runGuarded(e,n,r)}runOutsideAngular(e){return this._outer.run(e)}}const jS={};function _c(t){if(0==t._nesting&&!t.hasPendingMicrotasks&&!t.isStable)try{t._nesting++,t.onMicrotaskEmpty.emit(null)}finally{if(t._nesting--,!t.hasPendingMicrotasks)try{t.runOutsideAngular(()=>t.onStable.emit(null))}finally{t.isStable=!0}}}function vc(t){t.hasPendingMicrotasks=!!(t._hasPendingMicrotasks||(t.shouldCoalesceEventChangeDetection||t.shouldCoalesceRunChangeDetection)&&-1!==t.lastRequestAnimationFrameId)}function jm(t){t._nesting++,t.isStable&&(t.isStable=!1,t.onUnstable.emit(null))}function Hm(t){t._nesting--,_c(t)}class GS{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new en,this.onMicrotaskEmpty=new en,this.onStable=new en,this.onError=new en}run(e,n,r){return e.apply(n,r)}runGuarded(e,n,r){return e.apply(n,r)}runOutsideAngular(e){return e()}runTask(e,n,r,i){return e.apply(n,r)}}let bc=(()=>{class t{constructor(n){this._ngZone=n,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this.taskTrackingZone=null,this._watchAngularEvents(),n.run(()=>{this.taskTrackingZone="undefined"==typeof Zone?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._didWork=!0,this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{Gt.assertNotInAngularZone(),yc(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}increasePendingRequestCount(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount}decreasePendingRequestCount(){if(this._pendingCount-=1,this._pendingCount<0)throw new Error("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount}isStable(){return this._isZoneStable&&0===this._pendingCount&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())yc(()=>{for(;0!==this._callbacks.length;){let n=this._callbacks.pop();clearTimeout(n.timeoutId),n.doneCb(this._didWork)}this._didWork=!1});else{let n=this.getPendingTasks();this._callbacks=this._callbacks.filter(r=>!r.updateCb||!r.updateCb(n)||(clearTimeout(r.timeoutId),!1)),this._didWork=!0}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(n=>({source:n.source,creationLocation:n.creationLocation,data:n.data})):[]}addCallback(n,r,i){let s=-1;r&&r>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),n(this._didWork,this.getPendingTasks())},r)),this._callbacks.push({doneCb:n,timeoutId:s,updateCb:i})}whenStable(n,r,i){if(i&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(n,r,i),this._runCallbacksIfReady()}getPendingRequestCount(){return this._pendingCount}findProviders(n,r,i){return[]}}return t.\u0275fac=function(n){return new(n||t)(tt(Gt))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})(),$S=(()=>{class t{constructor(){this._applications=new Map,Ac.addToWindow(this)}registerApplication(n,r){this._applications.set(n,r)}unregisterApplication(n){this._applications.delete(n)}unregisterAllApplications(){this._applications.clear()}getTestability(n){return this._applications.get(n)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(n,r=!0){return Ac.findTestabilityInTree(this,n,r)}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275prov=dt({token:t,factory:t.\u0275fac,providedIn:"platform"}),t})();class zS{addToWindow(e){}findTestabilityInTree(e,n,r){return null}}let Ac=new zS,qr=null;const Um=new it("AllowMultipleToken"),Gm=new it("PlatformOnDestroy");function $m(t,e,n=[]){const r=`Platform: ${e}`,i=new it(r);return(s=[])=>{let o=Cc();if(!o||o.injector.get(Um,!1)){const a=[...n,...s,{provide:i,useValue:!0}];t?t(a):function KS(t){if(qr&&!qr.get(Um,!1))throw new Me(400,"");qr=t;const e=t.get(zm),n=t.get(Bm,null);n&&n.forEach(r=>r())}(function XS(t=[],e){return Dn.create({name:e,providers:[{provide:wu,useValue:"platform"},{provide:Gm,useValue:()=>qr=null},...t]})}(a,r))}return function YS(t){const e=Cc();if(!e)throw new Me(401,"");return e}()}}function Cc(){var t;return null!==(t=null==qr?void 0:qr.get(zm))&&void 0!==t?t:null}let zm=(()=>{class t{constructor(n){this._injector=n,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(n,r){const a=function ZS(t,e){let n;return n="noop"===t?new GS:("zone.js"===t?void 0:t)||new Gt({enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:!!(null==e?void 0:e.ngZoneEventCoalescing),shouldCoalesceRunChangeDetection:!!(null==e?void 0:e.ngZoneRunCoalescing)}),n}(r?r.ngZone:void 0,{ngZoneEventCoalescing:r&&r.ngZoneEventCoalescing||!1,ngZoneRunCoalescing:r&&r.ngZoneRunCoalescing||!1}),l=[{provide:Gt,useValue:a}];return a.run(()=>{const u=Dn.create({providers:l,parent:this.injector,name:n.moduleType.name}),g=n.create(u),S=g.injector.get(Cs,null);if(!S)throw new Me(402,"");return a.runOutsideAngular(()=>{const O=a.onError.subscribe({next:$=>{S.handleError($)}});g.onDestroy(()=>{Ec(this._modules,g),O.unsubscribe()})}),function JS(t,e,n){try{const r=n();return Vu(r)?r.catch(i=>{throw e.runOutsideAngular(()=>t.handleError(i)),i}):r}catch(r){throw e.runOutsideAngular(()=>t.handleError(r)),r}}(S,a,()=>{const O=g.injector.get(gc);return O.runInitializers(),O.donePromise.then(()=>(function ww(t){ln(t,"Expected localeId to be defined"),"string"==typeof t&&(Pg=t.toLowerCase().replace(/_/g,"-"))}(g.injector.get(Ir,Wo)||Wo),this._moduleDoBootstrap(g),g))})})}bootstrapModule(n,r=[]){const i=Wm({},r);return function qS(t,e,n){const r=new Zu(n);return Promise.resolve(r)}(0,0,n).then(s=>this.bootstrapModuleFactory(s,i))}_moduleDoBootstrap(n){const r=n.injector.get(wc);if(n._bootstrapComponents.length>0)n._bootstrapComponents.forEach(i=>r.bootstrap(i));else{if(!n.instance.ngDoBootstrap)throw new Me(403,"");n.instance.ngDoBootstrap(r)}this._modules.push(n)}onDestroy(n){this._destroyListeners.push(n)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new Me(404,"");this._modules.slice().forEach(r=>r.destroy()),this._destroyListeners.forEach(r=>r());const n=this._injector.get(Gm,null);null==n||n(),this._destroyed=!0}get destroyed(){return this._destroyed}}return t.\u0275fac=function(n){return new(n||t)(tt(Dn))},t.\u0275prov=dt({token:t,factory:t.\u0275fac,providedIn:"platform"}),t})();function Wm(t,e){return Array.isArray(e)?e.reduce(Wm,t):Object.assign(Object.assign({},t),e)}let wc=(()=>{class t{constructor(n,r,i,s){this._zone=n,this._injector=r,this._exceptionHandler=i,this._initStatus=s,this._bootstrapListeners=[],this._views=[],this._runningTick=!1,this._stable=!0,this.componentTypes=[],this.components=[],this._onMicrotaskEmptySubscription=this._zone.onMicrotaskEmpty.subscribe({next:()=>{this._zone.run(()=>{this.tick()})}});const o=new c(l=>{this._stable=this._zone.isStable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks,this._zone.runOutsideAngular(()=>{l.next(this._stable),l.complete()})}),a=new c(l=>{let u;this._zone.runOutsideAngular(()=>{u=this._zone.onStable.subscribe(()=>{Gt.assertNotInAngularZone(),yc(()=>{!this._stable&&!this._zone.hasPendingMacrotasks&&!this._zone.hasPendingMicrotasks&&(this._stable=!0,l.next(!0))})})});const g=this._zone.onUnstable.subscribe(()=>{Gt.assertInAngularZone(),this._stable&&(this._stable=!1,this._zone.runOutsideAngular(()=>{l.next(!1)}))});return()=>{u.unsubscribe(),g.unsubscribe()}});this.isStable=ut(o,a.pipe(function gt(){return t=>$t()(function Be(t,e){return function(r){let i;if(i="function"==typeof t?t:function(){return t},"function"==typeof e)return r.lift(new Je(i,e));const s=Object.create(r,ue);return s.source=r,s.subjectFactory=i,s}}(Qe)(t))}()))}bootstrap(n,r){if(!this._initStatus.done)throw new Me(405,"");let i;i=n instanceof Jg?n:this._injector.get(Ui).resolveComponentFactory(n),this.componentTypes.push(i.componentType);const s=function QS(t){return t.isBoundToModule}(i)?void 0:this._injector.get($i),a=i.create(Dn.NULL,[],r||i.selector,s),l=a.location.nativeElement,u=a.injector.get(bc,null),g=u&&a.injector.get($S);return u&&g&&g.registerApplication(l,u),a.onDestroy(()=>{this.detachView(a.hostView),Ec(this.components,a),g&&g.unregisterApplication(l)}),this._loadComponent(a),a}tick(){if(this._runningTick)throw new Me(101,"");try{this._runningTick=!0;for(let n of this._views)n.detectChanges()}catch(n){this._zone.runOutsideAngular(()=>this._exceptionHandler.handleError(n))}finally{this._runningTick=!1}}attachView(n){const r=n;this._views.push(r),r.attachToAppRef(this)}detachView(n){const r=n;Ec(this._views,r),r.detachFromAppRef()}_loadComponent(n){this.attachView(n.hostView),this.tick(),this.components.push(n),this._injector.get(LS,[]).concat(this._bootstrapListeners).forEach(i=>i(n))}ngOnDestroy(){this._views.slice().forEach(n=>n.destroy()),this._onMicrotaskEmptySubscription.unsubscribe()}get viewCount(){return this._views.length}}return t.\u0275fac=function(n){return new(n||t)(tt(Gt),tt(Dn),tt(Cs),tt(gc))},t.\u0275prov=dt({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();function Ec(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}let Qm=!0,Xm=(()=>{class t{}return t.__NG_ELEMENT_ID__=nD,t})();function nD(t){return function rD(t,e,n){if(so(t)&&!n){const r=dn(t.index,e);return new ks(r,r)}return 47&t.type?new ks(e[16],e):null}(Lt(),me(),16==(16&t))}const mD=$m(null,"core",[]);let yD=(()=>{class t{constructor(n){}}return t.\u0275fac=function(n){return new(n||t)(tt(wc))},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({}),t})(),oa=null;function Us(){return oa}const Pn=new it("DocumentToken");let fP=(()=>{class t{}return t.\u0275fac=function(n){return new(n||t)},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({}),t})();class $c extends class yP extends class bD{}{constructor(){super(...arguments),this.supportsDOMEvents=!0}}{static makeCurrent(){!function vD(t){oa||(oa=t)}(new $c)}onAndCancel(e,n,r){return e.addEventListener(n,r,!1),()=>{e.removeEventListener(n,r,!1)}}dispatchEvent(e,n){e.dispatchEvent(n)}remove(e){e.parentNode&&e.parentNode.removeChild(e)}createElement(e,n){return(n=n||this.getDefaultDocument()).createElement(e)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(e){return e.nodeType===Node.ELEMENT_NODE}isShadowRoot(e){return e instanceof DocumentFragment}getGlobalEventTarget(e,n){return"window"===n?window:"document"===n?e:"body"===n?e.body:null}getBaseHref(e){const n=function _P(){return Ws=Ws||document.querySelector("base"),Ws?Ws.getAttribute("href"):null}();return null==n?null:function vP(t){_a=_a||document.createElement("a"),_a.setAttribute("href",t);const e=_a.pathname;return"/"===e.charAt(0)?e:`/${e}`}(n)}resetBaseElement(){Ws=null}getUserAgent(){return window.navigator.userAgent}getCookie(e){return function oT(t,e){e=encodeURIComponent(e);for(const n of t.split(";")){const r=n.indexOf("="),[i,s]=-1==r?[n,""]:[n.slice(0,r),n.slice(r+1)];if(i.trim()===e)return decodeURIComponent(s)}return null}(document.cookie,e)}}let _a,Ws=null;const Dy=new it("TRANSITION_ID"),AP=[{provide:km,useFactory:function bP(t,e,n){return()=>{n.get(gc).donePromise.then(()=>{const r=Us(),i=e.querySelectorAll(`style[ng-transition="${t}"]`);for(let s=0;s<i.length;s++)r.remove(i[s])})}},deps:[Dy,Pn,Dn],multi:!0}];class zc{static init(){!function WS(t){Ac=t}(new zc)}addToWindow(e){ct.getAngularTestability=(r,i=!0)=>{const s=e.findTestabilityInTree(r,i);if(null==s)throw new Error("Could not find testability for element.");return s},ct.getAllAngularTestabilities=()=>e.getAllTestabilities(),ct.getAllAngularRootElements=()=>e.getAllRootElements(),ct.frameworkStabilizers||(ct.frameworkStabilizers=[]),ct.frameworkStabilizers.push(r=>{const i=ct.getAllAngularTestabilities();let s=i.length,o=!1;const a=function(l){o=o||l,s--,0==s&&r(o)};i.forEach(function(l){l.whenStable(a)})})}findTestabilityInTree(e,n,r){if(null==n)return null;const i=e.getTestability(n);return null!=i?i:r?Us().isShadowRoot(n)?this.findTestabilityInTree(e,n.host,!0):this.findTestabilityInTree(e,n.parentElement,!0):null}}let CP=(()=>{class t{build(){return new XMLHttpRequest}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();const va=new it("EventManagerPlugins");let ba=(()=>{class t{constructor(n,r){this._zone=r,this._eventNameToPlugin=new Map,n.forEach(i=>i.manager=this),this._plugins=n.slice().reverse()}addEventListener(n,r,i){return this._findPluginFor(r).addEventListener(n,r,i)}addGlobalEventListener(n,r,i){return this._findPluginFor(r).addGlobalEventListener(n,r,i)}getZone(){return this._zone}_findPluginFor(n){const r=this._eventNameToPlugin.get(n);if(r)return r;const i=this._plugins;for(let s=0;s<i.length;s++){const o=i[s];if(o.supports(n))return this._eventNameToPlugin.set(n,o),o}throw new Error(`No event manager plugin found for event ${n}`)}}return t.\u0275fac=function(n){return new(n||t)(tt(va),tt(Gt))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();class Ty{constructor(e){this._doc=e}addGlobalEventListener(e,n,r){const i=Us().getGlobalEventTarget(this._doc,e);if(!i)throw new Error(`Unsupported event target ${i} for event ${n}`);return this.addEventListener(i,n,r)}}let Py=(()=>{class t{constructor(){this._stylesSet=new Set}addStyles(n){const r=new Set;n.forEach(i=>{this._stylesSet.has(i)||(this._stylesSet.add(i),r.add(i))}),this.onStylesAdded(r)}onStylesAdded(n){}getAllStyles(){return Array.from(this._stylesSet)}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})(),qs=(()=>{class t extends Py{constructor(n){super(),this._doc=n,this._hostNodes=new Map,this._hostNodes.set(n.head,[])}_addStylesToHost(n,r,i){n.forEach(s=>{const o=this._doc.createElement("style");o.textContent=s,i.push(r.appendChild(o))})}addHost(n){const r=[];this._addStylesToHost(this._stylesSet,n,r),this._hostNodes.set(n,r)}removeHost(n){const r=this._hostNodes.get(n);r&&r.forEach(My),this._hostNodes.delete(n)}onStylesAdded(n){this._hostNodes.forEach((r,i)=>{this._addStylesToHost(n,i,r)})}ngOnDestroy(){this._hostNodes.forEach(n=>n.forEach(My))}}return t.\u0275fac=function(n){return new(n||t)(tt(Pn))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();function My(t){Us().remove(t)}const Wc={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},qc=/%COMP%/g;function Aa(t,e,n){for(let r=0;r<e.length;r++){let i=e[r];Array.isArray(i)?Aa(t,i,n):(i=i.replace(qc,t),n.push(i))}return n}function Ry(t){return e=>{if("__ngUnwrap__"===e)return t;!1===t(e)&&(e.preventDefault(),e.returnValue=!1)}}let Ca=(()=>{class t{constructor(n,r,i){this.eventManager=n,this.sharedStylesHost=r,this.appId=i,this.rendererByCompId=new Map,this.defaultRenderer=new Qc(n)}createRenderer(n,r){if(!n||!r)return this.defaultRenderer;switch(r.encapsulation){case kn.Emulated:{let i=this.rendererByCompId.get(r.id);return i||(i=new PP(this.eventManager,this.sharedStylesHost,r,this.appId),this.rendererByCompId.set(r.id,i)),i.applyToHost(n),i}case 1:case kn.ShadowDom:return new MP(this.eventManager,this.sharedStylesHost,n,r);default:if(!this.rendererByCompId.has(r.id)){const i=Aa(r.id,r.styles,[]);this.sharedStylesHost.addStyles(i),this.rendererByCompId.set(r.id,this.defaultRenderer)}return this.defaultRenderer}}begin(){}end(){}}return t.\u0275fac=function(n){return new(n||t)(tt(ba),tt(qs),tt(js))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();class Qc{constructor(e){this.eventManager=e,this.data=Object.create(null),this.destroyNode=null}destroy(){}createElement(e,n){return n?document.createElementNS(Wc[n]||n,e):document.createElement(e)}createComment(e){return document.createComment(e)}createText(e){return document.createTextNode(e)}appendChild(e,n){e.appendChild(n)}insertBefore(e,n,r){e&&e.insertBefore(n,r)}removeChild(e,n){e&&e.removeChild(n)}selectRootElement(e,n){let r="string"==typeof e?document.querySelector(e):e;if(!r)throw new Error(`The selector "${e}" did not match any elements`);return n||(r.textContent=""),r}parentNode(e){return e.parentNode}nextSibling(e){return e.nextSibling}setAttribute(e,n,r,i){if(i){n=i+":"+n;const s=Wc[i];s?e.setAttributeNS(s,n,r):e.setAttribute(n,r)}else e.setAttribute(n,r)}removeAttribute(e,n,r){if(r){const i=Wc[r];i?e.removeAttributeNS(i,n):e.removeAttribute(`${r}:${n}`)}else e.removeAttribute(n)}addClass(e,n){e.classList.add(n)}removeClass(e,n){e.classList.remove(n)}setStyle(e,n,r,i){i&(fn.DashCase|fn.Important)?e.style.setProperty(n,r,i&fn.Important?"important":""):e.style[n]=r}removeStyle(e,n,r){r&fn.DashCase?e.style.removeProperty(n):e.style[n]=""}setProperty(e,n,r){e[n]=r}setValue(e,n){e.nodeValue=n}listen(e,n,r){return"string"==typeof e?this.eventManager.addGlobalEventListener(e,n,Ry(r)):this.eventManager.addEventListener(e,n,Ry(r))}}class PP extends Qc{constructor(e,n,r,i){super(e),this.component=r;const s=Aa(i+"-"+r.id,r.styles,[]);n.addStyles(s),this.contentAttr=function SP(t){return"_ngcontent-%COMP%".replace(qc,t)}(i+"-"+r.id),this.hostAttr=function DP(t){return"_nghost-%COMP%".replace(qc,t)}(i+"-"+r.id)}applyToHost(e){super.setAttribute(e,this.hostAttr,"")}createElement(e,n){const r=super.createElement(e,n);return super.setAttribute(r,this.contentAttr,""),r}}class MP extends Qc{constructor(e,n,r,i){super(e),this.sharedStylesHost=n,this.hostEl=r,this.shadowRoot=r.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const s=Aa(i.id,i.styles,[]);for(let o=0;o<s.length;o++){const a=document.createElement("style");a.textContent=s[o],this.shadowRoot.appendChild(a)}}nodeOrShadowRoot(e){return e===this.hostEl?this.shadowRoot:e}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}appendChild(e,n){return super.appendChild(this.nodeOrShadowRoot(e),n)}insertBefore(e,n,r){return super.insertBefore(this.nodeOrShadowRoot(e),n,r)}removeChild(e,n){return super.removeChild(this.nodeOrShadowRoot(e),n)}parentNode(e){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(e)))}}let IP=(()=>{class t extends Ty{constructor(n){super(n)}supports(n){return!0}addEventListener(n,r,i){return n.addEventListener(r,i,!1),()=>this.removeEventListener(n,r,i)}removeEventListener(n,r,i){return n.removeEventListener(r,i)}}return t.\u0275fac=function(n){return new(n||t)(tt(Pn))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();const Ny=["alt","control","meta","shift"],RP={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Fy={A:"1",B:"2",C:"3",D:"4",E:"5",F:"6",G:"7",H:"8",I:"9",J:"*",K:"+",M:"-",N:".",O:"/","`":"0","\x90":"NumLock"},LP={alt:t=>t.altKey,control:t=>t.ctrlKey,meta:t=>t.metaKey,shift:t=>t.shiftKey};let NP=(()=>{class t extends Ty{constructor(n){super(n)}supports(n){return null!=t.parseEventName(n)}addEventListener(n,r,i){const s=t.parseEventName(r),o=t.eventCallback(s.fullKey,i,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Us().onAndCancel(n,s.domEventName,o))}static parseEventName(n){const r=n.toLowerCase().split("."),i=r.shift();if(0===r.length||"keydown"!==i&&"keyup"!==i)return null;const s=t._normalizeKey(r.pop());let o="";if(Ny.forEach(l=>{const u=r.indexOf(l);u>-1&&(r.splice(u,1),o+=l+".")}),o+=s,0!=r.length||0===s.length)return null;const a={};return a.domEventName=i,a.fullKey=o,a}static getEventFullKey(n){let r="",i=function FP(t){let e=t.key;if(null==e){if(e=t.keyIdentifier,null==e)return"Unidentified";e.startsWith("U+")&&(e=String.fromCharCode(parseInt(e.substring(2),16)),3===t.location&&Fy.hasOwnProperty(e)&&(e=Fy[e]))}return RP[e]||e}(n);return i=i.toLowerCase()," "===i?i="space":"."===i&&(i="dot"),Ny.forEach(s=>{s!=i&&LP[s](n)&&(r+=s+".")}),r+=i,r}static eventCallback(n,r,i){return s=>{t.getEventFullKey(s)===n&&i.runGuarded(()=>r(s))}}static _normalizeKey(n){return"esc"===n?"escape":n}}return t.\u0275fac=function(n){return new(n||t)(tt(Pn))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();const VP=$m(mD,"browser",[{provide:Vm,useValue:"browser"},{provide:Bm,useValue:function kP(){$c.makeCurrent(),zc.init()},multi:!0},{provide:Pn,useFactory:function BP(){return function av(t){ol=t}(document),document},deps:[]}]),jP=[{provide:wu,useValue:"root"},{provide:Cs,useFactory:function OP(){return new Cs},deps:[]},{provide:va,useClass:IP,multi:!0,deps:[Pn,Gt,Vm]},{provide:va,useClass:NP,multi:!0,deps:[Pn]},{provide:Ca,useClass:Ca,deps:[ba,qs,js]},{provide:Fs,useExisting:Ca},{provide:Py,useExisting:qs},{provide:qs,useClass:qs,deps:[Pn]},{provide:bc,useClass:bc,deps:[Gt]},{provide:ba,useClass:ba,deps:[va,Gt]},{provide:class gP{},useClass:CP,deps:[]}];let ky=(()=>{class t{constructor(n){if(n)throw new Error("BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.")}static withServerTransition(n){return{ngModule:t,providers:[{provide:js,useValue:n.appId},{provide:Dy,useExisting:js},AP]}}}return t.\u0275fac=function(n){return new(n||t)(tt(t,12))},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({providers:jP,imports:[fP,yD]}),t})();"undefined"!=typeof window&&window;class XP extends k{constructor(e,n){super()}schedule(e,n=0){return this}}class ZP extends XP{constructor(e,n){super(e,n),this.scheduler=e,this.work=n,this.pending=!1}schedule(e,n=0){if(this.closed)return this;this.state=e;const r=this.id,i=this.scheduler;return null!=r&&(this.id=this.recycleAsyncId(i,r,n)),this.pending=!0,this.delay=n,this.id=this.id||this.requestAsyncId(i,this.id,n),this}requestAsyncId(e,n,r=0){return setInterval(e.flush.bind(e,this),r)}recycleAsyncId(e,n,r=0){if(null!==r&&this.delay===r&&!1===this.pending)return n;clearInterval(n)}execute(e,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const r=this._execute(e,n);if(r)return r;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(e,n){let i,r=!1;try{this.work(e)}catch(s){r=!0,i=!!s&&s||new Error(s)}if(r)return this.unsubscribe(),i}_unsubscribe(){const e=this.id,n=this.scheduler,r=n.actions,i=r.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==i&&r.splice(i,1),null!=e&&(this.id=this.recycleAsyncId(n,e,null)),this.delay=null}}let Vy=(()=>{class t{constructor(n,r=t.now){this.SchedulerAction=n,this.now=r}schedule(n,r=0,i){return new this.SchedulerAction(this,n).schedule(i,r)}}return t.now=()=>Date.now(),t})();class Rr extends Vy{constructor(e,n=Vy.now){super(e,()=>Rr.delegate&&Rr.delegate!==this?Rr.delegate.now():n()),this.actions=[],this.active=!1,this.scheduled=void 0}schedule(e,n=0,r){return Rr.delegate&&Rr.delegate!==this?Rr.delegate.schedule(e,n,r):super.schedule(e,n,r)}flush(e){const{actions:n}=this;if(this.active)return void n.push(e);let r;this.active=!0;do{if(r=e.execute(e.state,e.delay))break}while(e=n.shift());if(this.active=!1,r){for(;e=n.shift();)e.unsubscribe();throw r}}}const tM=new class eM extends Rr{}(class JP extends ZP{constructor(e,n){super(e,n),this.scheduler=e,this.work=n}schedule(e,n=0){return n>0?super.schedule(e,n):(this.delay=n,this.state=e,this.scheduler.flush(this),this)}execute(e,n){return n>0||this.closed?super.execute(e,n):this._execute(e,n)}requestAsyncId(e,n,r=0){return null!==r&&r>0||null===r&&this.delay>0?super.requestAsyncId(e,n,r):e.flush(this)}}),nM=new c(t=>t.complete());function aM({error:t,subscriber:e}){e.error(t)}class xn{constructor(e,n,r){this.kind=e,this.value=n,this.error=r,this.hasValue="N"===e}observe(e){switch(this.kind){case"N":return e.next&&e.next(this.value);case"E":return e.error&&e.error(this.error);case"C":return e.complete&&e.complete()}}do(e,n,r){switch(this.kind){case"N":return e&&e(this.value);case"E":return n&&n(this.error);case"C":return r&&r()}}accept(e,n,r){return e&&"function"==typeof e.next?this.observe(e):this.do(e,n,r)}toObservable(){switch(this.kind){case"N":return function sM(...t){let e=t[t.length-1];return Z(e)?(t.pop(),ge(t,e)):Vt(t)}(this.value);case"E":return function oM(t,e){return new c(e?n=>e.schedule(aM,0,{error:t,subscriber:n}):n=>n.error(t))}(this.error);case"C":return function rM(t){return t?function iM(t){return new c(e=>t.schedule(()=>e.complete()))}(t):nM}()}throw new Error("unexpected notification kind value")}static createNext(e){return void 0!==e?new xn("N",e):xn.undefinedValueNotification}static createError(e){return new xn("E",void 0,e)}static createComplete(){return xn.completeNotification}}xn.completeNotification=new xn("C"),xn.undefinedValueNotification=new xn("N",void 0);class wa extends _{constructor(e,n,r=0){super(e),this.scheduler=n,this.delay=r}static dispatch(e){const{notification:n,destination:r}=e;n.observe(r),this.unsubscribe()}scheduleMessage(e){this.destination.add(this.scheduler.schedule(wa.dispatch,this.delay,new uM(e,this.destination)))}_next(e){this.scheduleMessage(xn.createNext(e))}_error(e){this.scheduleMessage(xn.createError(e)),this.unsubscribe()}_complete(){this.scheduleMessage(xn.createComplete()),this.unsubscribe()}}class uM{constructor(e,n){this.notification=e,this.destination=n}}class cM extends G{constructor(e=Number.POSITIVE_INFINITY,n=Number.POSITIVE_INFINITY,r){super(),this.scheduler=r,this._events=[],this._infiniteTimeWindow=!1,this._bufferSize=e<1?1:e,this._windowTime=n<1?1:n,n===Number.POSITIVE_INFINITY?(this._infiniteTimeWindow=!0,this.next=this.nextInfiniteTimeWindow):this.next=this.nextTimeWindow}nextInfiniteTimeWindow(e){const n=this._events;n.push(e),n.length>this._bufferSize&&n.shift(),super.next(e)}nextTimeWindow(e){this._events.push(new dM(this._getNow(),e)),this._trimBufferThenGetEvents(),super.next(e)}_subscribe(e){const n=this._infiniteTimeWindow,r=n?this._events:this._trimBufferThenGetEvents(),i=this.scheduler,s=r.length;let o;if(this.closed)throw new D;if(this.isStopped||this.hasError?o=k.EMPTY:(this.observers.push(e),o=new I(this,e)),i&&e.add(e=new wa(e,i)),n)for(let a=0;a<s&&!e.closed;a++)e.next(r[a]);else for(let a=0;a<s&&!e.closed;a++)e.next(r[a].value);return this.hasError?e.error(this.thrownError):this.isStopped&&e.complete(),o}_getNow(){return(this.scheduler||tM).now()}_trimBufferThenGetEvents(){const e=this._getNow(),n=this._bufferSize,r=this._windowTime,i=this._events,s=i.length;let o=0;for(;o<s&&!(e-i[o].time<r);)o++;return s>n&&(o=Math.max(o,s-n)),o>0&&i.splice(0,o),i}}class dM{constructor(e,n){this.time=e,this.value=n}}function jy(t,e){return"function"==typeof e?n=>n.pipe(jy((r,i)=>te(t(r,i)).pipe(K((s,o)=>e(r,s,i,o))))):n=>n.lift(new hM(t))}class hM{constructor(e){this.project=e}call(e,n){return n.subscribe(new fM(e,this.project))}}class fM extends he{constructor(e,n){super(e),this.project=n,this.index=0}_next(e){let n;const r=this.index++;try{n=this.project(e,r)}catch(i){return void this.destination.error(i)}this._innerSub(n)}_innerSub(e){const n=this.innerSubscription;n&&n.unsubscribe();const r=new ie(this),i=this.destination;i.add(r),this.innerSubscription=be(e,r),this.innerSubscription!==r&&i.add(this.innerSubscription)}_complete(){const{innerSubscription:e}=this;(!e||e.closed)&&super._complete(),this.unsubscribe()}_unsubscribe(){this.innerSubscription=void 0}notifyComplete(){this.innerSubscription=void 0,this.isStopped&&super._complete()}notifyNext(e){this.destination.next(e)}}const Ea={schedule(t,e){const n=setTimeout(t,e);return()=>clearTimeout(n)},scheduleBeforeRender(t){if("undefined"==typeof window)return Ea.schedule(t,0);if(void 0===window.requestAnimationFrame)return Ea.schedule(t,16);const e=window.requestAnimationFrame(t);return()=>window.cancelAnimationFrame(e)}};let Yc;function CM(t,e,n){let r=n;return function gM(t){return!!t&&t.nodeType===Node.ELEMENT_NODE}(t)&&e.some((i,s)=>!("*"===i||!function yM(t,e){if(!Yc){const n=Element.prototype;Yc=n.matches||n.matchesSelector||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector}return t.nodeType===Node.ELEMENT_NODE&&Yc.call(t,e)}(t,i)||(r=s,0))),r}class EM{constructor(e,n){this.componentFactory=n.get(Ui).resolveComponentFactory(e)}create(e){return new SM(this.componentFactory,e)}}class SM{constructor(e,n){this.componentFactory=e,this.injector=n,this.eventEmitters=new cM(1),this.events=this.eventEmitters.pipe(jy(r=>ut(...r))),this.componentRef=null,this.viewChangeDetectorRef=null,this.inputChanges=null,this.hasInputChanges=!1,this.implementsOnChanges=!1,this.scheduledChangeDetectionFn=null,this.scheduledDestroyFn=null,this.initialInputValues=new Map,this.unchangedInputs=new Set(this.componentFactory.inputs.map(({propName:r})=>r)),this.ngZone=this.injector.get(Gt),this.elementZone="undefined"==typeof Zone?null:this.ngZone.run(()=>Zone.current)}connect(e){this.runInZone(()=>{if(null!==this.scheduledDestroyFn)return this.scheduledDestroyFn(),void(this.scheduledDestroyFn=null);null===this.componentRef&&this.initializeComponent(e)})}disconnect(){this.runInZone(()=>{null===this.componentRef||null!==this.scheduledDestroyFn||(this.scheduledDestroyFn=Ea.schedule(()=>{null!==this.componentRef&&(this.componentRef.destroy(),this.componentRef=null,this.viewChangeDetectorRef=null)},10))})}getInputValue(e){return this.runInZone(()=>null===this.componentRef?this.initialInputValues.get(e):this.componentRef.instance[e])}setInputValue(e,n){this.runInZone(()=>{null!==this.componentRef?function _M(t,e){return t===e||t!=t&&e!=e}(n,this.getInputValue(e))&&(void 0!==n||!this.unchangedInputs.has(e))||(this.recordInputChange(e,n),this.unchangedInputs.delete(e),this.hasInputChanges=!0,this.componentRef.instance[e]=n,this.scheduleDetectChanges()):this.initialInputValues.set(e,n)})}initializeComponent(e){const n=Dn.create({providers:[],parent:this.injector}),r=function AM(t,e){const n=t.childNodes,r=e.map(()=>[]);let i=-1;e.some((s,o)=>"*"===s&&(i=o,!0));for(let s=0,o=n.length;s<o;++s){const a=n[s],l=CM(a,e,i);-1!==l&&r[l].push(a)}return r}(e,this.componentFactory.ngContentSelectors);this.componentRef=this.componentFactory.create(n,r,e),this.viewChangeDetectorRef=this.componentRef.injector.get(Xm),this.implementsOnChanges=function mM(t){return"function"==typeof t}(this.componentRef.instance.ngOnChanges),this.initializeInputs(),this.initializeOutputs(this.componentRef),this.detectChanges(),this.injector.get(wc).attachView(this.componentRef.hostView)}initializeInputs(){this.componentFactory.inputs.forEach(({propName:e})=>{this.initialInputValues.has(e)&&this.setInputValue(e,this.initialInputValues.get(e))}),this.initialInputValues.clear()}initializeOutputs(e){const n=this.componentFactory.outputs.map(({propName:r,templateName:i})=>e.instance[r].pipe(K(o=>({name:i,value:o}))));this.eventEmitters.next(n)}callNgOnChanges(e){if(!this.implementsOnChanges||null===this.inputChanges)return;const n=this.inputChanges;this.inputChanges=null,e.instance.ngOnChanges(n)}markViewForCheck(e){this.hasInputChanges&&(this.hasInputChanges=!1,e.markForCheck())}scheduleDetectChanges(){this.scheduledChangeDetectionFn||(this.scheduledChangeDetectionFn=Ea.scheduleBeforeRender(()=>{this.scheduledChangeDetectionFn=null,this.detectChanges()}))}recordInputChange(e,n){if(!this.implementsOnChanges)return;null===this.inputChanges&&(this.inputChanges={});const r=this.inputChanges[e];if(r)return void(r.currentValue=n);const i=this.unchangedInputs.has(e),s=i?void 0:this.getInputValue(e);this.inputChanges[e]=new Nd(s,n,i)}detectChanges(){null!==this.componentRef&&(this.callNgOnChanges(this.componentRef),this.markViewForCheck(this.viewChangeDetectorRef),this.componentRef.changeDetectorRef.detectChanges())}runInZone(e){return this.elementZone&&Zone.current!==this.elementZone?this.ngZone.run(e):e()}}class DM extends HTMLElement{constructor(){super(...arguments),this.ngElementEventsSubscription=null}}class Hy{}const gr="*";function Uy(t,e=null){return{type:2,steps:t,options:e}}function Gy(t){return{type:6,styles:t,offset:null}}function $y(t){Promise.resolve(null).then(t)}class Qs{constructor(e=0,n=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=e+n}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}onStart(e){this._onStartFns.push(e)}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){$y(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(e=>e()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this._started=!1}setPosition(e){this._position=this.totalTime?e*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(e){const n="start"==e?this._onStartFns:this._onDoneFns;n.forEach(r=>r()),n.length=0}}class zy{constructor(e){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=e;let n=0,r=0,i=0;const s=this.players.length;0==s?$y(()=>this._onFinish()):this.players.forEach(o=>{o.onDone(()=>{++n==s&&this._onFinish()}),o.onDestroy(()=>{++r==s&&this._onDestroy()}),o.onStart(()=>{++i==s&&this._onStart()})}),this.totalTime=this.players.reduce((o,a)=>Math.max(o,a.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this.players.forEach(e=>e.init())}onStart(e){this._onStartFns.push(e)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(e=>e()),this._onStartFns=[])}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(e=>e.play())}pause(){this.players.forEach(e=>e.pause())}restart(){this.players.forEach(e=>e.restart())}finish(){this._onFinish(),this.players.forEach(e=>e.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(e=>e.destroy()),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}reset(){this.players.forEach(e=>e.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(e){const n=e*this.totalTime;this.players.forEach(r=>{const i=r.totalTime?Math.min(1,n/r.totalTime):1;r.setPosition(i)})}getPosition(){const e=this.players.reduce((n,r)=>null===n||r.totalTime>n.totalTime?r:n,null);return null!=e?e.getPosition():0}beforeDestroy(){this.players.forEach(e=>{e.beforeDestroy&&e.beforeDestroy()})}triggerCallback(e){const n="start"==e?this._onStartFns:this._onDoneFns;n.forEach(r=>r()),n.length=0}}const nt=!1;function Wy(t){return new Me(3e3,nt)}function lI(){return"undefined"!=typeof window&&void 0!==window.document}function Zc(){return"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)}function Lr(t){switch(t.length){case 0:return new Qs;case 1:return t[0];default:return new zy(t)}}function qy(t,e,n,r,i={},s={}){const o=[],a=[];let l=-1,u=null;if(r.forEach(g=>{const S=g.offset,O=S==l,$=O&&u||{};Object.keys(g).forEach(J=>{let se=J,fe=g[J];if("offset"!==J)switch(se=e.normalizePropertyName(se,o),fe){case"!":fe=i[J];break;case gr:fe=s[J];break;default:fe=e.normalizeStyleValue(J,se,fe,o)}$[se]=fe}),O||a.push($),u=$,l=S}),o.length)throw function XM(t){return new Me(3502,nt)}();return a}function Jc(t,e,n,r){switch(e){case"start":t.onStart(()=>r(n&&ed(n,"start",t)));break;case"done":t.onDone(()=>r(n&&ed(n,"done",t)));break;case"destroy":t.onDestroy(()=>r(n&&ed(n,"destroy",t)))}}function ed(t,e,n){const r=n.totalTime,s=td(t.element,t.triggerName,t.fromState,t.toState,e||t.phaseName,null==r?t.totalTime:r,!!n.disabled),o=t._data;return null!=o&&(s._data=o),s}function td(t,e,n,r,i="",s=0,o){return{element:t,triggerName:e,fromState:n,toState:r,phaseName:i,totalTime:s,disabled:!!o}}function gn(t,e,n){let r;return t instanceof Map?(r=t.get(e),r||t.set(e,r=n)):(r=t[e],r||(r=t[e]=n)),r}function Qy(t){const e=t.indexOf(":");return[t.substring(1,e),t.substr(e+1)]}let nd=(t,e)=>!1,Ky=(t,e,n)=>[],Yy=null;function rd(t){const e=t.parentNode||t.host;return e===Yy?null:e}(Zc()||"undefined"!=typeof Element)&&(lI()?(Yy=(()=>document.documentElement)(),nd=(t,e)=>{for(;e;){if(e===t)return!0;e=rd(e)}return!1}):nd=(t,e)=>t.contains(e),Ky=(t,e,n)=>{if(n)return Array.from(t.querySelectorAll(e));const r=t.querySelector(e);return r?[r]:[]});let Kr=null,Xy=!1;function Zy(t){Kr||(Kr=function cI(){return"undefined"!=typeof document?document.body:null}()||{},Xy=!!Kr.style&&"WebkitAppearance"in Kr.style);let e=!0;return Kr.style&&!function uI(t){return"ebkit"==t.substring(1,6)}(t)&&(e=t in Kr.style,!e&&Xy&&(e="Webkit"+t.charAt(0).toUpperCase()+t.substr(1)in Kr.style)),e}const Jy=nd,e_=Ky;let t_=(()=>{class t{validateStyleProperty(n){return Zy(n)}matchesElement(n,r){return!1}containsElement(n,r){return Jy(n,r)}getParentElement(n){return rd(n)}query(n,r,i){return e_(n,r,i)}computeStyle(n,r,i){return i||""}animate(n,r,i,s,o,a=[],l){return new Qs(i,s)}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})(),id=(()=>{class t{}return t.NOOP=new t_,t})();const sd="ng-enter",Da="ng-leave",Ta="ng-trigger",Pa=".ng-trigger",r_="ng-animating",od=".ng-animating";function Yr(t){if("number"==typeof t)return t;const e=t.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:ad(parseFloat(e[1]),e[2])}function ad(t,e){return"s"===e?1e3*t:t}function Ma(t,e,n){return t.hasOwnProperty("duration")?t:function fI(t,e,n){let i,s=0,o="";if("string"==typeof t){const a=t.match(/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i);if(null===a)return e.push(Wy()),{duration:0,delay:0,easing:""};i=ad(parseFloat(a[1]),a[2]);const l=a[3];null!=l&&(s=ad(parseFloat(l),a[4]));const u=a[5];u&&(o=u)}else i=t;if(!n){let a=!1,l=e.length;i<0&&(e.push(function MM(){return new Me(3100,nt)}()),a=!0),s<0&&(e.push(function IM(){return new Me(3101,nt)}()),a=!0),a&&e.splice(l,0,Wy())}return{duration:i,delay:s,easing:o}}(t,e,n)}function Qi(t,e={}){return Object.keys(t).forEach(n=>{e[n]=t[n]}),e}function Nr(t,e,n={}){if(e)for(let r in t)n[r]=t[r];else Qi(t,n);return n}function s_(t,e,n){return n?e+":"+n+";":""}function o_(t){let e="";for(let n=0;n<t.style.length;n++){const r=t.style.item(n);e+=s_(0,r,t.style.getPropertyValue(r))}for(const n in t.style)t.style.hasOwnProperty(n)&&!n.startsWith("_")&&(e+=s_(0,mI(n),t.style[n]));t.setAttribute("style",e)}function sr(t,e,n){t.style&&(Object.keys(e).forEach(r=>{const i=ud(r);n&&!n.hasOwnProperty(r)&&(n[r]=t.style[i]),t.style[i]=e[r]}),Zc()&&o_(t))}function Xr(t,e){t.style&&(Object.keys(e).forEach(n=>{const r=ud(n);t.style[r]=""}),Zc()&&o_(t))}function Ks(t){return Array.isArray(t)?1==t.length?t[0]:Uy(t):t}const ld=new RegExp("{{\\s*(.+?)\\s*}}","g");function a_(t){let e=[];if("string"==typeof t){let n;for(;n=ld.exec(t);)e.push(n[1]);ld.lastIndex=0}return e}function Ia(t,e,n){const r=t.toString(),i=r.replace(ld,(s,o)=>{let a=e[o];return e.hasOwnProperty(o)||(n.push(function RM(t){return new Me(3003,nt)}()),a=""),a.toString()});return i==r?t:i}function xa(t){const e=[];let n=t.next();for(;!n.done;)e.push(n.value),n=t.next();return e}const gI=/-+([a-z0-9])/g;function ud(t){return t.replace(gI,(...e)=>e[1].toUpperCase())}function mI(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function mn(t,e,n){switch(e.type){case 7:return t.visitTrigger(e,n);case 0:return t.visitState(e,n);case 1:return t.visitTransition(e,n);case 2:return t.visitSequence(e,n);case 3:return t.visitGroup(e,n);case 4:return t.visitAnimate(e,n);case 5:return t.visitKeyframes(e,n);case 6:return t.visitStyle(e,n);case 8:return t.visitReference(e,n);case 9:return t.visitAnimateChild(e,n);case 10:return t.visitAnimateRef(e,n);case 11:return t.visitQuery(e,n);case 12:return t.visitStagger(e,n);default:throw function LM(t){return new Me(3004,nt)}()}}function l_(t,e){return window.getComputedStyle(t)[e]}function CI(t,e){const n=[];return"string"==typeof t?t.split(/\s*,\s*/).forEach(r=>function wI(t,e,n){if(":"==t[0]){const l=function EI(t,e){switch(t){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(n,r)=>parseFloat(r)>parseFloat(n);case":decrement":return(n,r)=>parseFloat(r)<parseFloat(n);default:return e.push(function qM(t){return new Me(3016,nt)}()),"* => *"}}(t,n);if("function"==typeof l)return void e.push(l);t=l}const r=t.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(null==r||r.length<4)return n.push(function WM(t){return new Me(3015,nt)}()),e;const i=r[1],s=r[2],o=r[3];e.push(u_(i,o));"<"==s[0]&&!("*"==i&&"*"==o)&&e.push(u_(o,i))}(r,n,e)):n.push(t),n}const Fa=new Set(["true","1"]),ka=new Set(["false","0"]);function u_(t,e){const n=Fa.has(t)||ka.has(t),r=Fa.has(e)||ka.has(e);return(i,s)=>{let o="*"==t||t==i,a="*"==e||e==s;return!o&&n&&"boolean"==typeof i&&(o=i?Fa.has(t):ka.has(t)),!a&&r&&"boolean"==typeof s&&(a=s?Fa.has(e):ka.has(e)),o&&a}}const SI=new RegExp("s*:selfs*,?","g");function cd(t,e,n,r){return new DI(t).build(e,n,r)}class DI{constructor(e){this._driver=e}build(e,n,r){const i=new MI(n);this._resetContextStyleTimingState(i);const s=mn(this,Ks(e),i);return i.unsupportedCSSPropertiesFound.size&&i.unsupportedCSSPropertiesFound.keys(),s}_resetContextStyleTimingState(e){e.currentQuerySelector="",e.collectedStyles={},e.collectedStyles[""]={},e.currentTime=0}visitTrigger(e,n){let r=n.queryCount=0,i=n.depCount=0;const s=[],o=[];return"@"==e.name.charAt(0)&&n.errors.push(function FM(){return new Me(3006,nt)}()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(n),0==a.type){const l=a,u=l.name;u.toString().split(/\s*,\s*/).forEach(g=>{l.name=g,s.push(this.visitState(l,n))}),l.name=u}else if(1==a.type){const l=this.visitTransition(a,n);r+=l.queryCount,i+=l.depCount,o.push(l)}else n.errors.push(function kM(){return new Me(3007,nt)}())}),{type:7,name:e.name,states:s,transitions:o,queryCount:r,depCount:i,options:null}}visitState(e,n){const r=this.visitStyle(e.styles,n),i=e.options&&e.options.params||null;if(r.containsDynamicStyles){const s=new Set,o=i||{};r.styles.forEach(a=>{if(Oa(a)){const l=a;Object.keys(l).forEach(u=>{a_(l[u]).forEach(g=>{o.hasOwnProperty(g)||s.add(g)})})}}),s.size&&(xa(s.values()),n.errors.push(function OM(t,e){return new Me(3008,nt)}()))}return{type:0,name:e.name,style:r,options:i?{params:i}:null}}visitTransition(e,n){n.queryCount=0,n.depCount=0;const r=mn(this,Ks(e.animation),n);return{type:1,matchers:CI(e.expr,n.errors),animation:r,queryCount:n.queryCount,depCount:n.depCount,options:Zr(e.options)}}visitSequence(e,n){return{type:2,steps:e.steps.map(r=>mn(this,r,n)),options:Zr(e.options)}}visitGroup(e,n){const r=n.currentTime;let i=0;const s=e.steps.map(o=>{n.currentTime=r;const a=mn(this,o,n);return i=Math.max(i,n.currentTime),a});return n.currentTime=i,{type:3,steps:s,options:Zr(e.options)}}visitAnimate(e,n){const r=function xI(t,e){if(t.hasOwnProperty("duration"))return t;if("number"==typeof t)return dd(Ma(t,e).duration,0,"");const n=t;if(n.split(/\s+/).some(s=>"{"==s.charAt(0)&&"{"==s.charAt(1))){const s=dd(0,0,"");return s.dynamic=!0,s.strValue=n,s}const i=Ma(n,e);return dd(i.duration,i.delay,i.easing)}(e.timings,n.errors);n.currentAnimateTimings=r;let i,s=e.styles?e.styles:Gy({});if(5==s.type)i=this.visitKeyframes(s,n);else{let o=e.styles,a=!1;if(!o){a=!0;const u={};r.easing&&(u.easing=r.easing),o=Gy(u)}n.currentTime+=r.duration+r.delay;const l=this.visitStyle(o,n);l.isEmptyStep=a,i=l}return n.currentAnimateTimings=null,{type:4,timings:r,style:i,options:null}}visitStyle(e,n){const r=this._makeStyleAst(e,n);return this._validateStyleAst(r,n),r}_makeStyleAst(e,n){const r=[];Array.isArray(e.styles)?e.styles.forEach(o=>{"string"==typeof o?o==gr?r.push(o):n.errors.push(function BM(t){return new Me(3002,nt)}()):r.push(o)}):r.push(e.styles);let i=!1,s=null;return r.forEach(o=>{if(Oa(o)){const a=o,l=a.easing;if(l&&(s=l,delete a.easing),!i)for(let u in a)if(a[u].toString().indexOf("{{")>=0){i=!0;break}}}),{type:6,styles:r,easing:s,offset:e.offset,containsDynamicStyles:i,options:null}}_validateStyleAst(e,n){const r=n.currentAnimateTimings;let i=n.currentTime,s=n.currentTime;r&&s>0&&(s-=r.duration+r.delay),e.styles.forEach(o=>{"string"!=typeof o&&Object.keys(o).forEach(a=>{if(!this._driver.validateStyleProperty(a))return delete o[a],void n.unsupportedCSSPropertiesFound.add(a);const l=n.collectedStyles[n.currentQuerySelector],u=l[a];let g=!0;u&&(s!=i&&s>=u.startTime&&i<=u.endTime&&(n.errors.push(function VM(t,e,n,r,i){return new Me(3010,nt)}()),g=!1),s=u.startTime),g&&(l[a]={startTime:s,endTime:i}),n.options&&function pI(t,e,n){const r=e.params||{},i=a_(t);i.length&&i.forEach(s=>{r.hasOwnProperty(s)||n.push(function xM(t){return new Me(3001,nt)}())})}(o[a],n.options,n.errors)})})}visitKeyframes(e,n){const r={type:5,styles:[],options:null};if(!n.currentAnimateTimings)return n.errors.push(function jM(){return new Me(3011,nt)}()),r;let s=0;const o=[];let a=!1,l=!1,u=0;const g=e.steps.map(ve=>{const oe=this._makeStyleAst(ve,n);let Ee=null!=oe.offset?oe.offset:function II(t){if("string"==typeof t)return null;let e=null;if(Array.isArray(t))t.forEach(n=>{if(Oa(n)&&n.hasOwnProperty("offset")){const r=n;e=parseFloat(r.offset),delete r.offset}});else if(Oa(t)&&t.hasOwnProperty("offset")){const n=t;e=parseFloat(n.offset),delete n.offset}return e}(oe.styles),Re=0;return null!=Ee&&(s++,Re=oe.offset=Ee),l=l||Re<0||Re>1,a=a||Re<u,u=Re,o.push(Re),oe});l&&n.errors.push(function HM(){return new Me(3012,nt)}()),a&&n.errors.push(function UM(){return new Me(3200,nt)}());const S=e.steps.length;let O=0;s>0&&s<S?n.errors.push(function GM(){return new Me(3202,nt)}()):0==s&&(O=1/(S-1));const $=S-1,J=n.currentTime,se=n.currentAnimateTimings,fe=se.duration;return g.forEach((ve,oe)=>{const Ee=O>0?oe==$?1:O*oe:o[oe],Re=Ee*fe;n.currentTime=J+se.delay+Re,se.duration=Re,this._validateStyleAst(ve,n),ve.offset=Ee,r.styles.push(ve)}),r}visitReference(e,n){return{type:8,animation:mn(this,Ks(e.animation),n),options:Zr(e.options)}}visitAnimateChild(e,n){return n.depCount++,{type:9,options:Zr(e.options)}}visitAnimateRef(e,n){return{type:10,animation:this.visitReference(e.animation,n),options:Zr(e.options)}}visitQuery(e,n){const r=n.currentQuerySelector,i=e.options||{};n.queryCount++,n.currentQuery=e;const[s,o]=function TI(t){const e=!!t.split(/\s*,\s*/).find(n=>":self"==n);return e&&(t=t.replace(SI,"")),t=t.replace(/@\*/g,Pa).replace(/@\w+/g,n=>Pa+"-"+n.substr(1)).replace(/:animating/g,od),[t,e]}(e.selector);n.currentQuerySelector=r.length?r+" "+s:s,gn(n.collectedStyles,n.currentQuerySelector,{});const a=mn(this,Ks(e.animation),n);return n.currentQuery=null,n.currentQuerySelector=r,{type:11,selector:s,limit:i.limit||0,optional:!!i.optional,includeSelf:o,animation:a,originalSelector:e.selector,options:Zr(e.options)}}visitStagger(e,n){n.currentQuery||n.errors.push(function $M(){return new Me(3013,nt)}());const r="full"===e.timings?{duration:0,delay:0,easing:"full"}:Ma(e.timings,n.errors,!0);return{type:12,animation:mn(this,Ks(e.animation),n),timings:r,options:null}}}class MI{constructor(e){this.errors=e,this.queryCount=0,this.depCount=0,this.currentTransition=null,this.currentQuery=null,this.currentQuerySelector=null,this.currentAnimateTimings=null,this.currentTime=0,this.collectedStyles={},this.options=null,this.unsupportedCSSPropertiesFound=new Set}}function Oa(t){return!Array.isArray(t)&&"object"==typeof t}function Zr(t){return t?(t=Qi(t)).params&&(t.params=function PI(t){return t?Qi(t):null}(t.params)):t={},t}function dd(t,e,n){return{duration:t,delay:e,easing:n}}function hd(t,e,n,r,i,s,o=null,a=!1){return{type:1,element:t,keyframes:e,preStyleProps:n,postStyleProps:r,duration:i,delay:s,totalTime:i+s,easing:o,subTimeline:a}}class Ba{constructor(){this._map=new Map}get(e){return this._map.get(e)||[]}append(e,n){let r=this._map.get(e);r||this._map.set(e,r=[]),r.push(...n)}has(e){return this._map.has(e)}clear(){this._map.clear()}}const NI=new RegExp(":enter","g"),kI=new RegExp(":leave","g");function fd(t,e,n,r,i,s={},o={},a,l,u=[]){return(new OI).buildKeyframes(t,e,n,r,i,s,o,a,l,u)}class OI{buildKeyframes(e,n,r,i,s,o,a,l,u,g=[]){u=u||new Ba;const S=new pd(e,n,u,i,s,g,[]);S.options=l,S.currentTimeline.setStyles([o],null,S.errors,l),mn(this,r,S);const O=S.timelines.filter($=>$.containsAnimation());if(Object.keys(a).length){let $;for(let J=O.length-1;J>=0;J--){const se=O[J];if(se.element===n){$=se;break}}$&&!$.allowOnlyTimelineStyles()&&$.setStyles([a],null,S.errors,l)}return O.length?O.map($=>$.buildKeyframes()):[hd(n,[],[],[],0,0,"",!1)]}visitTrigger(e,n){}visitState(e,n){}visitTransition(e,n){}visitAnimateChild(e,n){const r=n.subInstructions.get(n.element);if(r){const i=n.createSubContext(e.options),s=n.currentTimeline.currentTime,o=this._visitSubInstructions(r,i,i.options);s!=o&&n.transformIntoNewTimeline(o)}n.previousNode=e}visitAnimateRef(e,n){const r=n.createSubContext(e.options);r.transformIntoNewTimeline(),this.visitReference(e.animation,r),n.transformIntoNewTimeline(r.currentTimeline.currentTime),n.previousNode=e}_visitSubInstructions(e,n,r){let s=n.currentTimeline.currentTime;const o=null!=r.duration?Yr(r.duration):null,a=null!=r.delay?Yr(r.delay):null;return 0!==o&&e.forEach(l=>{const u=n.appendInstructionToTimeline(l,o,a);s=Math.max(s,u.duration+u.delay)}),s}visitReference(e,n){n.updateOptions(e.options,!0),mn(this,e.animation,n),n.previousNode=e}visitSequence(e,n){const r=n.subContextCount;let i=n;const s=e.options;if(s&&(s.params||s.delay)&&(i=n.createSubContext(s),i.transformIntoNewTimeline(),null!=s.delay)){6==i.previousNode.type&&(i.currentTimeline.snapshotCurrentStyles(),i.previousNode=Va);const o=Yr(s.delay);i.delayNextStep(o)}e.steps.length&&(e.steps.forEach(o=>mn(this,o,i)),i.currentTimeline.applyStylesToKeyframe(),i.subContextCount>r&&i.transformIntoNewTimeline()),n.previousNode=e}visitGroup(e,n){const r=[];let i=n.currentTimeline.currentTime;const s=e.options&&e.options.delay?Yr(e.options.delay):0;e.steps.forEach(o=>{const a=n.createSubContext(e.options);s&&a.delayNextStep(s),mn(this,o,a),i=Math.max(i,a.currentTimeline.currentTime),r.push(a.currentTimeline)}),r.forEach(o=>n.currentTimeline.mergeTimelineCollectedStyles(o)),n.transformIntoNewTimeline(i),n.previousNode=e}_visitTiming(e,n){if(e.dynamic){const r=e.strValue;return Ma(n.params?Ia(r,n.params,n.errors):r,n.errors)}return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,n){const r=n.currentAnimateTimings=this._visitTiming(e.timings,n),i=n.currentTimeline;r.delay&&(n.incrementTime(r.delay),i.snapshotCurrentStyles());const s=e.style;5==s.type?this.visitKeyframes(s,n):(n.incrementTime(r.duration),this.visitStyle(s,n),i.applyStylesToKeyframe()),n.currentAnimateTimings=null,n.previousNode=e}visitStyle(e,n){const r=n.currentTimeline,i=n.currentAnimateTimings;!i&&r.getCurrentStyleProperties().length&&r.forwardFrame();const s=i&&i.easing||e.easing;e.isEmptyStep?r.applyEmptyStep(s):r.setStyles(e.styles,s,n.errors,n.options),n.previousNode=e}visitKeyframes(e,n){const r=n.currentAnimateTimings,i=n.currentTimeline.duration,s=r.duration,a=n.createSubContext().currentTimeline;a.easing=r.easing,e.styles.forEach(l=>{a.forwardTime((l.offset||0)*s),a.setStyles(l.styles,l.easing,n.errors,n.options),a.applyStylesToKeyframe()}),n.currentTimeline.mergeTimelineCollectedStyles(a),n.transformIntoNewTimeline(i+s),n.previousNode=e}visitQuery(e,n){const r=n.currentTimeline.currentTime,i=e.options||{},s=i.delay?Yr(i.delay):0;s&&(6===n.previousNode.type||0==r&&n.currentTimeline.getCurrentStyleProperties().length)&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=Va);let o=r;const a=n.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!i.optional,n.errors);n.currentQueryTotal=a.length;let l=null;a.forEach((u,g)=>{n.currentQueryIndex=g;const S=n.createSubContext(e.options,u);s&&S.delayNextStep(s),u===n.element&&(l=S.currentTimeline),mn(this,e.animation,S),S.currentTimeline.applyStylesToKeyframe(),o=Math.max(o,S.currentTimeline.currentTime)}),n.currentQueryIndex=0,n.currentQueryTotal=0,n.transformIntoNewTimeline(o),l&&(n.currentTimeline.mergeTimelineCollectedStyles(l),n.currentTimeline.snapshotCurrentStyles()),n.previousNode=e}visitStagger(e,n){const r=n.parentContext,i=n.currentTimeline,s=e.timings,o=Math.abs(s.duration),a=o*(n.currentQueryTotal-1);let l=o*n.currentQueryIndex;switch(s.duration<0?"reverse":s.easing){case"reverse":l=a-l;break;case"full":l=r.currentStaggerTime}const g=n.currentTimeline;l&&g.delayNextStep(l);const S=g.currentTime;mn(this,e.animation,n),n.previousNode=e,r.currentStaggerTime=i.currentTime-S+(i.startTime-r.currentTimeline.startTime)}}const Va={};class pd{constructor(e,n,r,i,s,o,a,l){this._driver=e,this.element=n,this.subInstructions=r,this._enterClassName=i,this._leaveClassName=s,this.errors=o,this.timelines=a,this.parentContext=null,this.currentAnimateTimings=null,this.previousNode=Va,this.subContextCount=0,this.options={},this.currentQueryIndex=0,this.currentQueryTotal=0,this.currentStaggerTime=0,this.currentTimeline=l||new ja(this._driver,n,0),a.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,n){if(!e)return;const r=e;let i=this.options;null!=r.duration&&(i.duration=Yr(r.duration)),null!=r.delay&&(i.delay=Yr(r.delay));const s=r.params;if(s){let o=i.params;o||(o=this.options.params={}),Object.keys(s).forEach(a=>{(!n||!o.hasOwnProperty(a))&&(o[a]=Ia(s[a],o,this.errors))})}}_copyOptions(){const e={};if(this.options){const n=this.options.params;if(n){const r=e.params={};Object.keys(n).forEach(i=>{r[i]=n[i]})}}return e}createSubContext(e=null,n,r){const i=n||this.element,s=new pd(this._driver,i,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(i,r||0));return s.previousNode=this.previousNode,s.currentAnimateTimings=this.currentAnimateTimings,s.options=this._copyOptions(),s.updateOptions(e),s.currentQueryIndex=this.currentQueryIndex,s.currentQueryTotal=this.currentQueryTotal,s.parentContext=this,this.subContextCount++,s}transformIntoNewTimeline(e){return this.previousNode=Va,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,n,r){const i={duration:null!=n?n:e.duration,delay:this.currentTimeline.currentTime+(null!=r?r:0)+e.delay,easing:""},s=new BI(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,i,e.stretchStartingKeyframe);return this.timelines.push(s),i}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,n,r,i,s,o){let a=[];if(i&&a.push(this.element),e.length>0){e=(e=e.replace(NI,"."+this._enterClassName)).replace(kI,"."+this._leaveClassName);let u=this._driver.query(this.element,e,1!=r);0!==r&&(u=r<0?u.slice(u.length+r,u.length):u.slice(0,r)),a.push(...u)}return!s&&0==a.length&&o.push(function zM(t){return new Me(3014,nt)}()),a}}class ja{constructor(e,n,r,i){this._driver=e,this.element=n,this.startTime=r,this._elementTimelineStylesLookup=i,this.duration=0,this._previousKeyframe={},this._currentKeyframe={},this._keyframes=new Map,this._styleSummary={},this._pendingStyles={},this._backFill={},this._currentEmptyStepKeyframe=null,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._localTimelineStyles=Object.create(this._backFill,{}),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(n),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(n,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.getCurrentStyleProperties().length>0;default:return!0}}getCurrentStyleProperties(){return Object.keys(this._currentKeyframe)}get currentTime(){return this.startTime+this.duration}delayNextStep(e){const n=1==this._keyframes.size&&Object.keys(this._pendingStyles).length;this.duration||n?(this.forwardTime(this.currentTime+e),n&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,n){return this.applyStylesToKeyframe(),new ja(this._driver,e,n||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=Object.create(this._backFill,{}),this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=1,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,n){this._localTimelineStyles[e]=n,this._globalTimelineStyles[e]=n,this._styleSummary[e]={time:this.currentTime,value:n}}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&(this._previousKeyframe.easing=e),Object.keys(this._globalTimelineStyles).forEach(n=>{this._backFill[n]=this._globalTimelineStyles[n]||gr,this._currentKeyframe[n]=gr}),this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,n,r,i){n&&(this._previousKeyframe.easing=n);const s=i&&i.params||{},o=function VI(t,e){const n={};let r;return t.forEach(i=>{"*"===i?(r=r||Object.keys(e),r.forEach(s=>{n[s]=gr})):Nr(i,!1,n)}),n}(e,this._globalTimelineStyles);Object.keys(o).forEach(a=>{const l=Ia(o[a],s,r);this._pendingStyles[a]=l,this._localTimelineStyles.hasOwnProperty(a)||(this._backFill[a]=this._globalTimelineStyles.hasOwnProperty(a)?this._globalTimelineStyles[a]:gr),this._updateStyle(a,l)})}applyStylesToKeyframe(){const e=this._pendingStyles,n=Object.keys(e);0!=n.length&&(this._pendingStyles={},n.forEach(r=>{this._currentKeyframe[r]=e[r]}),Object.keys(this._localTimelineStyles).forEach(r=>{this._currentKeyframe.hasOwnProperty(r)||(this._currentKeyframe[r]=this._localTimelineStyles[r])}))}snapshotCurrentStyles(){Object.keys(this._localTimelineStyles).forEach(e=>{const n=this._localTimelineStyles[e];this._pendingStyles[e]=n,this._updateStyle(e,n)})}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){const e=[];for(let n in this._currentKeyframe)e.push(n);return e}mergeTimelineCollectedStyles(e){Object.keys(e._styleSummary).forEach(n=>{const r=this._styleSummary[n],i=e._styleSummary[n];(!r||i.time>r.time)&&this._updateStyle(n,i.value)})}buildKeyframes(){this.applyStylesToKeyframe();const e=new Set,n=new Set,r=1===this._keyframes.size&&0===this.duration;let i=[];this._keyframes.forEach((a,l)=>{const u=Nr(a,!0);Object.keys(u).forEach(g=>{const S=u[g];"!"==S?e.add(g):S==gr&&n.add(g)}),r||(u.offset=l/this.duration),i.push(u)});const s=e.size?xa(e.values()):[],o=n.size?xa(n.values()):[];if(r){const a=i[0],l=Qi(a);a.offset=0,l.offset=1,i=[a,l]}return hd(this.element,i,s,o,this.duration,this.startTime,this.easing,!1)}}class BI extends ja{constructor(e,n,r,i,s,o,a=!1){super(e,n,o.delay),this.keyframes=r,this.preStyleProps=i,this.postStyleProps=s,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:n,duration:r,easing:i}=this.timings;if(this._stretchStartingKeyframe&&n){const s=[],o=r+n,a=n/o,l=Nr(e[0],!1);l.offset=0,s.push(l);const u=Nr(e[0],!1);u.offset=h_(a),s.push(u);const g=e.length-1;for(let S=1;S<=g;S++){let O=Nr(e[S],!1);O.offset=h_((n+O.offset*r)/o),s.push(O)}r=o,n=0,i="",e=s}return hd(this.element,e,this.preStyleProps,this.postStyleProps,r,n,i,!0)}}function h_(t,e=3){const n=Math.pow(10,e-1);return Math.round(t*n)/n}class gd{}class jI extends gd{normalizePropertyName(e,n){return ud(e)}normalizeStyleValue(e,n,r,i){let s="";const o=r.toString().trim();if(HI[n]&&0!==r&&"0"!==r)if("number"==typeof r)s="px";else{const a=r.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&0==a[1].length&&i.push(function NM(t,e){return new Me(3005,nt)}())}return o+s}}const HI=(()=>function UI(t){const e={};return t.forEach(n=>e[n]=!0),e}("width,height,minWidth,minHeight,maxWidth,maxHeight,left,top,bottom,right,fontSize,outlineWidth,outlineOffset,paddingTop,paddingLeft,paddingBottom,paddingRight,marginTop,marginLeft,marginBottom,marginRight,borderRadius,borderWidth,borderTopWidth,borderLeftWidth,borderRightWidth,borderBottomWidth,textIndent,perspective".split(",")))();function f_(t,e,n,r,i,s,o,a,l,u,g,S,O){return{type:0,element:t,triggerName:e,isRemovalTransition:i,fromState:n,fromStyles:s,toState:r,toStyles:o,timelines:a,queriedElements:l,preStyleProps:u,postStyleProps:g,totalTime:S,errors:O}}const md={};class p_{constructor(e,n,r){this._triggerName=e,this.ast=n,this._stateStyles=r}match(e,n,r,i){return function GI(t,e,n,r,i){return t.some(s=>s(e,n,r,i))}(this.ast.matchers,e,n,r,i)}buildStyles(e,n,r){const i=this._stateStyles["*"],s=this._stateStyles[e],o=i?i.buildStyles(n,r):{};return s?s.buildStyles(n,r):o}build(e,n,r,i,s,o,a,l,u,g){const S=[],O=this.ast.options&&this.ast.options.params||md,J=this.buildStyles(r,a&&a.params||md,S),se=l&&l.params||md,fe=this.buildStyles(i,se,S),ve=new Set,oe=new Map,Ee=new Map,Re="void"===i,We={params:Object.assign(Object.assign({},O),se)},yt=g?[]:fd(e,n,this.ast.animation,s,o,J,fe,We,u,S);let Ct=0;if(yt.forEach(_n=>{Ct=Math.max(_n.duration+_n.delay,Ct)}),S.length)return f_(n,this._triggerName,r,i,Re,J,fe,[],[],oe,Ee,Ct,S);yt.forEach(_n=>{const vn=_n.element,Yi=gn(oe,vn,{});_n.preStyleProps.forEach(qn=>Yi[qn]=!0);const yr=gn(Ee,vn,{});_n.postStyleProps.forEach(qn=>yr[qn]=!0),vn!==n&&ve.add(vn)});const yn=xa(ve.values());return f_(n,this._triggerName,r,i,Re,J,fe,yt,yn,oe,Ee,Ct)}}class $I{constructor(e,n,r){this.styles=e,this.defaultParams=n,this.normalizer=r}buildStyles(e,n){const r={},i=Qi(this.defaultParams);return Object.keys(e).forEach(s=>{const o=e[s];null!=o&&(i[s]=o)}),this.styles.styles.forEach(s=>{if("string"!=typeof s){const o=s;Object.keys(o).forEach(a=>{let l=o[a];l.length>1&&(l=Ia(l,i,n));const u=this.normalizer.normalizePropertyName(a,n);l=this.normalizer.normalizeStyleValue(a,u,l,n),r[u]=l})}}),r}}class WI{constructor(e,n,r){this.name=e,this.ast=n,this._normalizer=r,this.transitionFactories=[],this.states={},n.states.forEach(i=>{this.states[i.name]=new $I(i.style,i.options&&i.options.params||{},r)}),g_(this.states,"true","1"),g_(this.states,"false","0"),n.transitions.forEach(i=>{this.transitionFactories.push(new p_(e,i,this.states))}),this.fallbackTransition=function qI(t,e,n){return new p_(t,{type:1,animation:{type:2,steps:[],options:null},matchers:[(o,a)=>!0],options:null,queryCount:0,depCount:0},e)}(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,n,r,i){return this.transitionFactories.find(o=>o.match(e,n,r,i))||null}matchStyles(e,n,r){return this.fallbackTransition.buildStyles(e,n,r)}}function g_(t,e,n){t.hasOwnProperty(e)?t.hasOwnProperty(n)||(t[n]=t[e]):t.hasOwnProperty(n)&&(t[e]=t[n])}const QI=new Ba;class KI{constructor(e,n,r){this.bodyNode=e,this._driver=n,this._normalizer=r,this._animations={},this._playersById={},this.players=[]}register(e,n){const r=[],s=cd(this._driver,n,r,[]);if(r.length)throw function ZM(t){return new Me(3503,nt)}();this._animations[e]=s}_buildPlayer(e,n,r){const i=e.element,s=qy(0,this._normalizer,0,e.keyframes,n,r);return this._driver.animate(i,s,e.duration,e.delay,e.easing,[],!0)}create(e,n,r={}){const i=[],s=this._animations[e];let o;const a=new Map;if(s?(o=fd(this._driver,n,s,sd,Da,{},{},r,QI,i),o.forEach(g=>{const S=gn(a,g.element,{});g.postStyleProps.forEach(O=>S[O]=null)})):(i.push(function JM(){return new Me(3300,nt)}()),o=[]),i.length)throw function eI(t){return new Me(3504,nt)}();a.forEach((g,S)=>{Object.keys(g).forEach(O=>{g[O]=this._driver.computeStyle(S,O,gr)})});const u=Lr(o.map(g=>{const S=a.get(g.element);return this._buildPlayer(g,{},S)}));return this._playersById[e]=u,u.onDestroy(()=>this.destroy(e)),this.players.push(u),u}destroy(e){const n=this._getPlayer(e);n.destroy(),delete this._playersById[e];const r=this.players.indexOf(n);r>=0&&this.players.splice(r,1)}_getPlayer(e){const n=this._playersById[e];if(!n)throw function tI(t){return new Me(3301,nt)}();return n}listen(e,n,r,i){const s=td(n,"","","");return Jc(this._getPlayer(e),r,s,i),()=>{}}command(e,n,r,i){if("register"==r)return void this.register(e,i[0]);if("create"==r)return void this.create(e,n,i[0]||{});const s=this._getPlayer(e);switch(r){case"play":s.play();break;case"pause":s.pause();break;case"reset":s.reset();break;case"restart":s.restart();break;case"finish":s.finish();break;case"init":s.init();break;case"setPosition":s.setPosition(parseFloat(i[0]));break;case"destroy":this.destroy(e)}}}const m_="ng-animate-queued",yd="ng-animate-disabled",ex=[],y_={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},tx={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},Rn="__ng_removed";class _d{constructor(e,n=""){this.namespaceId=n;const r=e&&e.hasOwnProperty("value");if(this.value=function sx(t){return null!=t?t:null}(r?e.value:e),r){const s=Qi(e);delete s.value,this.options=s}else this.options={};this.options.params||(this.options.params={})}get params(){return this.options.params}absorbOptions(e){const n=e.params;if(n){const r=this.options.params;Object.keys(n).forEach(i=>{null==r[i]&&(r[i]=n[i])})}}}const Ys="void",vd=new _d(Ys);class nx{constructor(e,n,r){this.id=e,this.hostElement=n,this._engine=r,this.players=[],this._triggers={},this._queue=[],this._elementListeners=new Map,this._hostClassName="ng-tns-"+e,Ln(n,this._hostClassName)}listen(e,n,r,i){if(!this._triggers.hasOwnProperty(n))throw function nI(t,e){return new Me(3302,nt)}();if(null==r||0==r.length)throw function rI(t){return new Me(3303,nt)}();if(!function ox(t){return"start"==t||"done"==t}(r))throw function iI(t,e){return new Me(3400,nt)}();const s=gn(this._elementListeners,e,[]),o={name:n,phase:r,callback:i};s.push(o);const a=gn(this._engine.statesByElement,e,{});return a.hasOwnProperty(n)||(Ln(e,Ta),Ln(e,Ta+"-"+n),a[n]=vd),()=>{this._engine.afterFlush(()=>{const l=s.indexOf(o);l>=0&&s.splice(l,1),this._triggers[n]||delete a[n]})}}register(e,n){return!this._triggers[e]&&(this._triggers[e]=n,!0)}_getTrigger(e){const n=this._triggers[e];if(!n)throw function sI(t){return new Me(3401,nt)}();return n}trigger(e,n,r,i=!0){const s=this._getTrigger(n),o=new bd(this.id,n,e);let a=this._engine.statesByElement.get(e);a||(Ln(e,Ta),Ln(e,Ta+"-"+n),this._engine.statesByElement.set(e,a={}));let l=a[n];const u=new _d(r,this.id);if(!(r&&r.hasOwnProperty("value"))&&l&&u.absorbOptions(l.options),a[n]=u,l||(l=vd),u.value!==Ys&&l.value===u.value){if(!function ux(t,e){const n=Object.keys(t),r=Object.keys(e);if(n.length!=r.length)return!1;for(let i=0;i<n.length;i++){const s=n[i];if(!e.hasOwnProperty(s)||t[s]!==e[s])return!1}return!0}(l.params,u.params)){const se=[],fe=s.matchStyles(l.value,l.params,se),ve=s.matchStyles(u.value,u.params,se);se.length?this._engine.reportError(se):this._engine.afterFlush(()=>{Xr(e,fe),sr(e,ve)})}return}const O=gn(this._engine.playersByElement,e,[]);O.forEach(se=>{se.namespaceId==this.id&&se.triggerName==n&&se.queued&&se.destroy()});let $=s.matchTransition(l.value,u.value,e,u.params),J=!1;if(!$){if(!i)return;$=s.fallbackTransition,J=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:n,transition:$,fromState:l,toState:u,player:o,isFallbackTransition:J}),J||(Ln(e,m_),o.onStart(()=>{Ki(e,m_)})),o.onDone(()=>{let se=this.players.indexOf(o);se>=0&&this.players.splice(se,1);const fe=this._engine.playersByElement.get(e);if(fe){let ve=fe.indexOf(o);ve>=0&&fe.splice(ve,1)}}),this.players.push(o),O.push(o),o}deregister(e){delete this._triggers[e],this._engine.statesByElement.forEach((n,r)=>{delete n[e]}),this._elementListeners.forEach((n,r)=>{this._elementListeners.set(r,n.filter(i=>i.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);const n=this._engine.playersByElement.get(e);n&&(n.forEach(r=>r.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,n){const r=this._engine.driver.query(e,Pa,!0);r.forEach(i=>{if(i[Rn])return;const s=this._engine.fetchNamespacesByElement(i);s.size?s.forEach(o=>o.triggerLeaveAnimation(i,n,!1,!0)):this.clearElementCache(i)}),this._engine.afterFlushAnimationsDone(()=>r.forEach(i=>this.clearElementCache(i)))}triggerLeaveAnimation(e,n,r,i){const s=this._engine.statesByElement.get(e),o=new Map;if(s){const a=[];if(Object.keys(s).forEach(l=>{if(o.set(l,s[l].value),this._triggers[l]){const u=this.trigger(e,l,Ys,i);u&&a.push(u)}}),a.length)return this._engine.markElementAsRemoved(this.id,e,!0,n,o),r&&Lr(a).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){const n=this._elementListeners.get(e),r=this._engine.statesByElement.get(e);if(n&&r){const i=new Set;n.forEach(s=>{const o=s.name;if(i.has(o))return;i.add(o);const l=this._triggers[o].fallbackTransition,u=r[o]||vd,g=new _d(Ys),S=new bd(this.id,o,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:o,transition:l,fromState:u,toState:g,player:S,isFallbackTransition:!0})})}}removeNode(e,n){const r=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,n),this.triggerLeaveAnimation(e,n,!0))return;let i=!1;if(r.totalAnimations){const s=r.players.length?r.playersByQueriedElement.get(e):[];if(s&&s.length)i=!0;else{let o=e;for(;o=o.parentNode;)if(r.statesByElement.get(o)){i=!0;break}}}if(this.prepareLeaveAnimationListeners(e),i)r.markElementAsRemoved(this.id,e,!1,n);else{const s=e[Rn];(!s||s===y_)&&(r.afterFlush(()=>this.clearElementCache(e)),r.destroyInnerAnimations(e),r._onRemovalComplete(e,n))}}insertNode(e,n){Ln(e,this._hostClassName)}drainQueuedTransitions(e){const n=[];return this._queue.forEach(r=>{const i=r.player;if(i.destroyed)return;const s=r.element,o=this._elementListeners.get(s);o&&o.forEach(a=>{if(a.name==r.triggerName){const l=td(s,r.triggerName,r.fromState.value,r.toState.value);l._data=e,Jc(r.player,a.phase,l,a.callback)}}),i.markedForDestroy?this._engine.afterFlush(()=>{i.destroy()}):n.push(r)}),this._queue=[],n.sort((r,i)=>{const s=r.transition.ast.depCount,o=i.transition.ast.depCount;return 0==s||0==o?s-o:this._engine.driver.containsElement(r.element,i.element)?1:-1})}destroy(e){this.players.forEach(n=>n.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}elementContainsData(e){let n=!1;return this._elementListeners.has(e)&&(n=!0),n=!!this._queue.find(r=>r.element===e)||n,n}}class rx{constructor(e,n,r){this.bodyNode=e,this.driver=n,this._normalizer=r,this.players=[],this.newHostElements=new Map,this.playersByElement=new Map,this.playersByQueriedElement=new Map,this.statesByElement=new Map,this.disabledNodes=new Set,this.totalAnimations=0,this.totalQueuedPlayers=0,this._namespaceLookup={},this._namespaceList=[],this._flushFns=[],this._whenQuietFns=[],this.namespacesByHostElement=new Map,this.collectedEnterElements=[],this.collectedLeaveElements=[],this.onRemovalComplete=(i,s)=>{}}_onRemovalComplete(e,n){this.onRemovalComplete(e,n)}get queuedPlayers(){const e=[];return this._namespaceList.forEach(n=>{n.players.forEach(r=>{r.queued&&e.push(r)})}),e}createNamespace(e,n){const r=new nx(e,n,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,n)?this._balanceNamespaceList(r,n):(this.newHostElements.set(n,r),this.collectEnterElement(n)),this._namespaceLookup[e]=r}_balanceNamespaceList(e,n){const r=this._namespaceList,i=this.namespacesByHostElement,s=r.length-1;if(s>=0){let o=!1;if(void 0!==this.driver.getParentElement){let a=this.driver.getParentElement(n);for(;a;){const l=i.get(a);if(l){const u=r.indexOf(l);r.splice(u+1,0,e),o=!0;break}a=this.driver.getParentElement(a)}}else for(let a=s;a>=0;a--)if(this.driver.containsElement(r[a].hostElement,n)){r.splice(a+1,0,e),o=!0;break}o||r.unshift(e)}else r.push(e);return i.set(n,e),e}register(e,n){let r=this._namespaceLookup[e];return r||(r=this.createNamespace(e,n)),r}registerTrigger(e,n,r){let i=this._namespaceLookup[e];i&&i.register(n,r)&&this.totalAnimations++}destroy(e,n){if(!e)return;const r=this._fetchNamespace(e);this.afterFlush(()=>{this.namespacesByHostElement.delete(r.hostElement),delete this._namespaceLookup[e];const i=this._namespaceList.indexOf(r);i>=0&&this._namespaceList.splice(i,1)}),this.afterFlushAnimationsDone(()=>r.destroy(n))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){const n=new Set,r=this.statesByElement.get(e);if(r){const i=Object.keys(r);for(let s=0;s<i.length;s++){const o=r[i[s]].namespaceId;if(o){const a=this._fetchNamespace(o);a&&n.add(a)}}}return n}trigger(e,n,r,i){if(Ha(n)){const s=this._fetchNamespace(e);if(s)return s.trigger(n,r,i),!0}return!1}insertNode(e,n,r,i){if(!Ha(n))return;const s=n[Rn];if(s&&s.setForRemoval){s.setForRemoval=!1,s.setForMove=!0;const o=this.collectedLeaveElements.indexOf(n);o>=0&&this.collectedLeaveElements.splice(o,1)}if(e){const o=this._fetchNamespace(e);o&&o.insertNode(n,r)}i&&this.collectEnterElement(n)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,n){n?this.disabledNodes.has(e)||(this.disabledNodes.add(e),Ln(e,yd)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),Ki(e,yd))}removeNode(e,n,r,i){if(Ha(n)){const s=e?this._fetchNamespace(e):null;if(s?s.removeNode(n,i):this.markElementAsRemoved(e,n,!1,i),r){const o=this.namespacesByHostElement.get(n);o&&o.id!==e&&o.removeNode(n,i)}}else this._onRemovalComplete(n,i)}markElementAsRemoved(e,n,r,i,s){this.collectedLeaveElements.push(n),n[Rn]={namespaceId:e,setForRemoval:i,hasAnimation:r,removedBeforeQueried:!1,previousTriggersValues:s}}listen(e,n,r,i,s){return Ha(n)?this._fetchNamespace(e).listen(n,r,i,s):()=>{}}_buildInstruction(e,n,r,i,s){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,r,i,e.fromState.options,e.toState.options,n,s)}destroyInnerAnimations(e){let n=this.driver.query(e,Pa,!0);n.forEach(r=>this.destroyActiveAnimationsForElement(r)),0!=this.playersByQueriedElement.size&&(n=this.driver.query(e,od,!0),n.forEach(r=>this.finishActiveQueriedAnimationOnElement(r)))}destroyActiveAnimationsForElement(e){const n=this.playersByElement.get(e);n&&n.forEach(r=>{r.queued?r.markedForDestroy=!0:r.destroy()})}finishActiveQueriedAnimationOnElement(e){const n=this.playersByQueriedElement.get(e);n&&n.forEach(r=>r.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return Lr(this.players).onDone(()=>e());e()})}processLeaveNode(e){var n;const r=e[Rn];if(r&&r.setForRemoval){if(e[Rn]=y_,r.namespaceId){this.destroyInnerAnimations(e);const i=this._fetchNamespace(r.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,r.setForRemoval)}(null===(n=e.classList)||void 0===n?void 0:n.contains(yd))&&this.markElementAsDisabled(e,!1),this.driver.query(e,".ng-animate-disabled",!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let n=[];if(this.newHostElements.size&&(this.newHostElements.forEach((r,i)=>this._balanceNamespaceList(r,i)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let r=0;r<this.collectedEnterElements.length;r++)Ln(this.collectedEnterElements[r],"ng-star-inserted");if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){const r=[];try{n=this._flushAnimations(r,e)}finally{for(let i=0;i<r.length;i++)r[i]()}}else for(let r=0;r<this.collectedLeaveElements.length;r++)this.processLeaveNode(this.collectedLeaveElements[r]);if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(r=>r()),this._flushFns=[],this._whenQuietFns.length){const r=this._whenQuietFns;this._whenQuietFns=[],n.length?Lr(n).onDone(()=>{r.forEach(i=>i())}):r.forEach(i=>i())}}reportError(e){throw function oI(t){return new Me(3402,nt)}()}_flushAnimations(e,n){const r=new Ba,i=[],s=new Map,o=[],a=new Map,l=new Map,u=new Map,g=new Set;this.disabledNodes.forEach(Ie=>{g.add(Ie);const Le=this.driver.query(Ie,".ng-animate-queued",!0);for(let Oe=0;Oe<Le.length;Oe++)g.add(Le[Oe])});const S=this.bodyNode,O=Array.from(this.statesByElement.keys()),$=b_(O,this.collectedEnterElements),J=new Map;let se=0;$.forEach((Ie,Le)=>{const Oe=sd+se++;J.set(Le,Oe),Ie.forEach(st=>Ln(st,Oe))});const fe=[],ve=new Set,oe=new Set;for(let Ie=0;Ie<this.collectedLeaveElements.length;Ie++){const Le=this.collectedLeaveElements[Ie],Oe=Le[Rn];Oe&&Oe.setForRemoval&&(fe.push(Le),ve.add(Le),Oe.hasAnimation?this.driver.query(Le,".ng-star-inserted",!0).forEach(st=>ve.add(st)):oe.add(Le))}const Ee=new Map,Re=b_(O,Array.from(ve));Re.forEach((Ie,Le)=>{const Oe=Da+se++;Ee.set(Le,Oe),Ie.forEach(st=>Ln(st,Oe))}),e.push(()=>{$.forEach((Ie,Le)=>{const Oe=J.get(Le);Ie.forEach(st=>Ki(st,Oe))}),Re.forEach((Ie,Le)=>{const Oe=Ee.get(Le);Ie.forEach(st=>Ki(st,Oe))}),fe.forEach(Ie=>{this.processLeaveNode(Ie)})});const We=[],yt=[];for(let Ie=this._namespaceList.length-1;Ie>=0;Ie--)this._namespaceList[Ie].drainQueuedTransitions(n).forEach(Oe=>{const st=Oe.player,Bt=Oe.element;if(We.push(st),this.collectedEnterElements.length){const rn=Bt[Rn];if(rn&&rn.setForMove){if(rn.previousTriggersValues&&rn.previousTriggersValues.has(Oe.triggerName)){const ti=rn.previousTriggersValues.get(Oe.triggerName),kr=this.statesByElement.get(Oe.element);kr&&kr[Oe.triggerName]&&(kr[Oe.triggerName].value=ti)}return void st.destroy()}}const or=!S||!this.driver.containsElement(S,Bt),bn=Ee.get(Bt),Fr=J.get(Bt),wt=this._buildInstruction(Oe,r,Fr,bn,or);if(wt.errors&&wt.errors.length)return void yt.push(wt);if(or)return st.onStart(()=>Xr(Bt,wt.fromStyles)),st.onDestroy(()=>sr(Bt,wt.toStyles)),void i.push(st);if(Oe.isFallbackTransition)return st.onStart(()=>Xr(Bt,wt.fromStyles)),st.onDestroy(()=>sr(Bt,wt.toStyles)),void i.push(st);const L_=[];wt.timelines.forEach(rn=>{rn.stretchStartingKeyframe=!0,this.disabledNodes.has(rn.element)||L_.push(rn)}),wt.timelines=L_,r.append(Bt,wt.timelines),o.push({instruction:wt,player:st,element:Bt}),wt.queriedElements.forEach(rn=>gn(a,rn,[]).push(st)),wt.preStyleProps.forEach((rn,ti)=>{const kr=Object.keys(rn);if(kr.length){let ni=l.get(ti);ni||l.set(ti,ni=new Set),kr.forEach(wd=>ni.add(wd))}}),wt.postStyleProps.forEach((rn,ti)=>{const kr=Object.keys(rn);let ni=u.get(ti);ni||u.set(ti,ni=new Set),kr.forEach(wd=>ni.add(wd))})});if(yt.length){const Ie=[];yt.forEach(Le=>{Ie.push(function aI(t,e){return new Me(3505,nt)}())}),We.forEach(Le=>Le.destroy()),this.reportError(Ie)}const Ct=new Map,yn=new Map;o.forEach(Ie=>{const Le=Ie.element;r.has(Le)&&(yn.set(Le,Le),this._beforeAnimationBuild(Ie.player.namespaceId,Ie.instruction,Ct))}),i.forEach(Ie=>{const Le=Ie.element;this._getPreviousPlayers(Le,!1,Ie.namespaceId,Ie.triggerName,null).forEach(st=>{gn(Ct,Le,[]).push(st),st.destroy()})});const _n=fe.filter(Ie=>C_(Ie,l,u)),vn=new Map;v_(vn,this.driver,oe,u,gr).forEach(Ie=>{C_(Ie,l,u)&&_n.push(Ie)});const yr=new Map;$.forEach((Ie,Le)=>{v_(yr,this.driver,new Set(Ie),l,"!")}),_n.forEach(Ie=>{const Le=vn.get(Ie),Oe=yr.get(Ie);vn.set(Ie,Object.assign(Object.assign({},Le),Oe))});const qn=[],Xi=[],Zi={};o.forEach(Ie=>{const{element:Le,player:Oe,instruction:st}=Ie;if(r.has(Le)){if(g.has(Le))return Oe.onDestroy(()=>sr(Le,st.toStyles)),Oe.disabled=!0,Oe.overrideTotalTime(st.totalTime),void i.push(Oe);let Bt=Zi;if(yn.size>1){let bn=Le;const Fr=[];for(;bn=bn.parentNode;){const wt=yn.get(bn);if(wt){Bt=wt;break}Fr.push(bn)}Fr.forEach(wt=>yn.set(wt,Bt))}const or=this._buildAnimation(Oe.namespaceId,st,Ct,s,yr,vn);if(Oe.setRealPlayer(or),Bt===Zi)qn.push(Oe);else{const bn=this.playersByElement.get(Bt);bn&&bn.length&&(Oe.parentPlayer=Lr(bn)),i.push(Oe)}}else Xr(Le,st.fromStyles),Oe.onDestroy(()=>sr(Le,st.toStyles)),Xi.push(Oe),g.has(Le)&&i.push(Oe)}),Xi.forEach(Ie=>{const Le=s.get(Ie.element);if(Le&&Le.length){const Oe=Lr(Le);Ie.setRealPlayer(Oe)}}),i.forEach(Ie=>{Ie.parentPlayer?Ie.syncPlayerEvents(Ie.parentPlayer):Ie.destroy()});for(let Ie=0;Ie<fe.length;Ie++){const Le=fe[Ie],Oe=Le[Rn];if(Ki(Le,Da),Oe&&Oe.hasAnimation)continue;let st=[];if(a.size){let or=a.get(Le);or&&or.length&&st.push(...or);let bn=this.driver.query(Le,od,!0);for(let Fr=0;Fr<bn.length;Fr++){let wt=a.get(bn[Fr]);wt&&wt.length&&st.push(...wt)}}const Bt=st.filter(or=>!or.destroyed);Bt.length?ax(this,Le,Bt):this.processLeaveNode(Le)}return fe.length=0,qn.forEach(Ie=>{this.players.push(Ie),Ie.onDone(()=>{Ie.destroy();const Le=this.players.indexOf(Ie);this.players.splice(Le,1)}),Ie.play()}),qn}elementContainsData(e,n){let r=!1;const i=n[Rn];return i&&i.setForRemoval&&(r=!0),this.playersByElement.has(n)&&(r=!0),this.playersByQueriedElement.has(n)&&(r=!0),this.statesByElement.has(n)&&(r=!0),this._fetchNamespace(e).elementContainsData(n)||r}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,n,r,i,s){let o=[];if(n){const a=this.playersByQueriedElement.get(e);a&&(o=a)}else{const a=this.playersByElement.get(e);if(a){const l=!s||s==Ys;a.forEach(u=>{u.queued||!l&&u.triggerName!=i||o.push(u)})}}return(r||i)&&(o=o.filter(a=>!(r&&r!=a.namespaceId||i&&i!=a.triggerName))),o}_beforeAnimationBuild(e,n,r){const s=n.element,o=n.isRemovalTransition?void 0:e,a=n.isRemovalTransition?void 0:n.triggerName;for(const l of n.timelines){const u=l.element,g=u!==s,S=gn(r,u,[]);this._getPreviousPlayers(u,g,o,a,n.toState).forEach($=>{const J=$.getRealPlayer();J.beforeDestroy&&J.beforeDestroy(),$.destroy(),S.push($)})}Xr(s,n.fromStyles)}_buildAnimation(e,n,r,i,s,o){const a=n.triggerName,l=n.element,u=[],g=new Set,S=new Set,O=n.timelines.map(J=>{const se=J.element;g.add(se);const fe=se[Rn];if(fe&&fe.removedBeforeQueried)return new Qs(J.duration,J.delay);const ve=se!==l,oe=function lx(t){const e=[];return A_(t,e),e}((r.get(se)||ex).map(Ct=>Ct.getRealPlayer())).filter(Ct=>!!Ct.element&&Ct.element===se),Ee=s.get(se),Re=o.get(se),We=qy(0,this._normalizer,0,J.keyframes,Ee,Re),yt=this._buildPlayer(J,We,oe);if(J.subTimeline&&i&&S.add(se),ve){const Ct=new bd(e,a,se);Ct.setRealPlayer(yt),u.push(Ct)}return yt});u.forEach(J=>{gn(this.playersByQueriedElement,J.element,[]).push(J),J.onDone(()=>function ix(t,e,n){let r;if(t instanceof Map){if(r=t.get(e),r){if(r.length){const i=r.indexOf(n);r.splice(i,1)}0==r.length&&t.delete(e)}}else if(r=t[e],r){if(r.length){const i=r.indexOf(n);r.splice(i,1)}0==r.length&&delete t[e]}return r}(this.playersByQueriedElement,J.element,J))}),g.forEach(J=>Ln(J,r_));const $=Lr(O);return $.onDestroy(()=>{g.forEach(J=>Ki(J,r_)),sr(l,n.toStyles)}),S.forEach(J=>{gn(i,J,[]).push($)}),$}_buildPlayer(e,n,r){return n.length>0?this.driver.animate(e.element,n,e.duration,e.delay,e.easing,r):new Qs(e.duration,e.delay)}}class bd{constructor(e,n,r){this.namespaceId=e,this.triggerName=n,this.element=r,this._player=new Qs,this._containsRealPlayer=!1,this._queuedCallbacks={},this.destroyed=!1,this.markedForDestroy=!1,this.disabled=!1,this.queued=!0,this.totalTime=0}setRealPlayer(e){this._containsRealPlayer||(this._player=e,Object.keys(this._queuedCallbacks).forEach(n=>{this._queuedCallbacks[n].forEach(r=>Jc(e,n,void 0,r))}),this._queuedCallbacks={},this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){const n=this._player;n.triggerCallback&&e.onStart(()=>n.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,n){gn(this._queuedCallbacks,e,[]).push(n)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return!this.queued&&this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){const n=this._player;n.triggerCallback&&n.triggerCallback(e)}}function Ha(t){return t&&1===t.nodeType}function __(t,e){const n=t.style.display;return t.style.display=null!=e?e:"none",n}function v_(t,e,n,r,i){const s=[];n.forEach(l=>s.push(__(l)));const o=[];r.forEach((l,u)=>{const g={};l.forEach(S=>{const O=g[S]=e.computeStyle(u,S,i);(!O||0==O.length)&&(u[Rn]=tx,o.push(u))}),t.set(u,g)});let a=0;return n.forEach(l=>__(l,s[a++])),o}function b_(t,e){const n=new Map;if(t.forEach(a=>n.set(a,[])),0==e.length)return n;const i=new Set(e),s=new Map;function o(a){if(!a)return 1;let l=s.get(a);if(l)return l;const u=a.parentNode;return l=n.has(u)?u:i.has(u)?1:o(u),s.set(a,l),l}return e.forEach(a=>{const l=o(a);1!==l&&n.get(l).push(a)}),n}function Ln(t,e){var n;null===(n=t.classList)||void 0===n||n.add(e)}function Ki(t,e){var n;null===(n=t.classList)||void 0===n||n.remove(e)}function ax(t,e,n){Lr(n).onDone(()=>t.processLeaveNode(e))}function A_(t,e){for(let n=0;n<t.length;n++){const r=t[n];r instanceof zy?A_(r.players,e):e.push(r)}}function C_(t,e,n){const r=n.get(t);if(!r)return!1;let i=e.get(t);return i?r.forEach(s=>i.add(s)):e.set(t,r),n.delete(t),!0}class Ua{constructor(e,n,r){this.bodyNode=e,this._driver=n,this._normalizer=r,this._triggerCache={},this.onRemovalComplete=(i,s)=>{},this._transitionEngine=new rx(e,n,r),this._timelineEngine=new KI(e,n,r),this._transitionEngine.onRemovalComplete=(i,s)=>this.onRemovalComplete(i,s)}registerTrigger(e,n,r,i,s){const o=e+"-"+i;let a=this._triggerCache[o];if(!a){const l=[],g=cd(this._driver,s,l,[]);if(l.length)throw function YM(t,e){return new Me(3404,nt)}();a=function zI(t,e,n){return new WI(t,e,n)}(i,g,this._normalizer),this._triggerCache[o]=a}this._transitionEngine.registerTrigger(n,i,a)}register(e,n){this._transitionEngine.register(e,n)}destroy(e,n){this._transitionEngine.destroy(e,n)}onInsert(e,n,r,i){this._transitionEngine.insertNode(e,n,r,i)}onRemove(e,n,r,i){this._transitionEngine.removeNode(e,n,i||!1,r)}disableAnimations(e,n){this._transitionEngine.markElementAsDisabled(e,n)}process(e,n,r,i){if("@"==r.charAt(0)){const[s,o]=Qy(r);this._timelineEngine.command(s,n,o,i)}else this._transitionEngine.trigger(e,n,r,i)}listen(e,n,r,i,s){if("@"==r.charAt(0)){const[o,a]=Qy(r);return this._timelineEngine.listen(o,n,a,s)}return this._transitionEngine.listen(e,n,r,i,s)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return this._transitionEngine.players.concat(this._timelineEngine.players)}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}}let dx=(()=>{class t{constructor(n,r,i){this._element=n,this._startStyles=r,this._endStyles=i,this._state=0;let s=t.initialStylesByElement.get(n);s||t.initialStylesByElement.set(n,s={}),this._initialStyles=s}start(){this._state<1&&(this._startStyles&&sr(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(sr(this._element,this._initialStyles),this._endStyles&&(sr(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(t.initialStylesByElement.delete(this._element),this._startStyles&&(Xr(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(Xr(this._element,this._endStyles),this._endStyles=null),sr(this._element,this._initialStyles),this._state=3)}}return t.initialStylesByElement=new WeakMap,t})();function Ad(t){let e=null;const n=Object.keys(t);for(let r=0;r<n.length;r++){const i=n[r];hx(i)&&(e=e||{},e[i]=t[i])}return e}function hx(t){return"display"===t||"position"===t}class w_{constructor(e,n,r,i){this.element=e,this.keyframes=n,this.options=r,this._specialStyles=i,this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._initialized=!1,this._finished=!1,this._started=!1,this._destroyed=!1,this.time=0,this.parentPlayer=null,this.currentSnapshot={},this._duration=r.duration,this._delay=r.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer(),this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return;this._initialized=!0;const e=this.keyframes;this.domPlayer=this._triggerWebAnimation(this.element,e,this.options),this._finalKeyframe=e.length?e[e.length-1]:{},this.domPlayer.addEventListener("finish",()=>this._onFinish())}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer.pause()}_triggerWebAnimation(e,n,r){return e.animate(n,r)}onStart(e){this._onStartFns.push(e)}onDone(e){this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){this._buildPlayer(),this.hasStarted()||(this._onStartFns.forEach(e=>e()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),this.domPlayer.play()}pause(){this.init(),this.domPlayer.pause()}finish(){this.init(),this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish()}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1}_resetDomPlayerState(){this.domPlayer&&this.domPlayer.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){void 0===this.domPlayer&&this.init(),this.domPlayer.currentTime=e*this.time}getPosition(){return this.domPlayer.currentTime/this.time}get totalTime(){return this._delay+this._duration}beforeDestroy(){const e={};if(this.hasStarted()){const n=this._finalKeyframe;Object.keys(n).forEach(r=>{"offset"!=r&&(e[r]=this._finished?n[r]:l_(this.element,r))})}this.currentSnapshot=e}triggerCallback(e){const n="start"==e?this._onStartFns:this._onDoneFns;n.forEach(r=>r()),n.length=0}}class fx{validateStyleProperty(e){return Zy(e)}matchesElement(e,n){return!1}containsElement(e,n){return Jy(e,n)}getParentElement(e){return rd(e)}query(e,n,r){return e_(e,n,r)}computeStyle(e,n,r){return window.getComputedStyle(e)[n]}animate(e,n,r,i,s,o=[]){const l={duration:r,delay:i,fill:0==i?"both":"forwards"};s&&(l.easing=s);const u={},g=o.filter(O=>O instanceof w_);(function yI(t,e){return 0===t||0===e})(r,i)&&g.forEach(O=>{let $=O.currentSnapshot;Object.keys($).forEach(J=>u[J]=$[J])}),n=function _I(t,e,n){const r=Object.keys(n);if(r.length&&e.length){let s=e[0],o=[];if(r.forEach(a=>{s.hasOwnProperty(a)||o.push(a),s[a]=n[a]}),o.length)for(var i=1;i<e.length;i++){let a=e[i];o.forEach(function(l){a[l]=l_(t,l)})}}return e}(e,n=n.map(O=>Nr(O,!1)),u);const S=function cx(t,e){let n=null,r=null;return Array.isArray(e)&&e.length?(n=Ad(e[0]),e.length>1&&(r=Ad(e[e.length-1]))):e&&(n=Ad(e)),n||r?new dx(t,n,r):null}(e,n);return new w_(e,n,l,S)}}let px=(()=>{class t extends Hy{constructor(n,r){super(),this._nextAnimationId=0,this._renderer=n.createRenderer(r.body,{id:"0",encapsulation:kn.None,styles:[],data:{animation:[]}})}build(n){const r=this._nextAnimationId.toString();this._nextAnimationId++;const i=Array.isArray(n)?Uy(n):n;return E_(this._renderer,null,r,"register",[i]),new gx(r,this._renderer)}}return t.\u0275fac=function(n){return new(n||t)(tt(Fs),tt(Pn))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();class gx extends class PM{}{constructor(e,n){super(),this._id=e,this._renderer=n}create(e,n){return new mx(this._id,e,n||{},this._renderer)}}class mx{constructor(e,n,r,i){this.id=e,this.element=n,this._renderer=i,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",r)}_listen(e,n){return this._renderer.listen(this.element,`@@${this.id}:${e}`,n)}_command(e,...n){return E_(this._renderer,this.element,this.id,e,n)}onDone(e){this._listen("done",e)}onStart(e){this._listen("start",e)}onDestroy(e){this._listen("destroy",e)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(e){this._command("setPosition",e)}getPosition(){var e,n;return null!==(n=null===(e=this._renderer.engine.players[+this.id])||void 0===e?void 0:e.getPosition())&&void 0!==n?n:0}}function E_(t,e,n,r,i){return t.setProperty(e,`@@${n}:${r}`,i)}const S_="@.disabled";let yx=(()=>{class t{constructor(n,r,i){this.delegate=n,this.engine=r,this._zone=i,this._currentId=0,this._microtaskId=1,this._animationCallbacksBuffer=[],this._rendererCache=new Map,this._cdRecurDepth=0,this.promise=Promise.resolve(0),r.onRemovalComplete=(s,o)=>{const a=null==o?void 0:o.parentNode(s);a&&o.removeChild(a,s)}}createRenderer(n,r){const s=this.delegate.createRenderer(n,r);if(!(n&&r&&r.data&&r.data.animation)){let g=this._rendererCache.get(s);return g||(g=new D_("",s,this.engine),this._rendererCache.set(s,g)),g}const o=r.id,a=r.id+"-"+this._currentId;this._currentId++,this.engine.register(a,n);const l=g=>{Array.isArray(g)?g.forEach(l):this.engine.registerTrigger(o,a,n,g.name,g)};return r.data.animation.forEach(l),new _x(this,a,s,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){this.promise.then(()=>{this._microtaskId++})}scheduleListenerCallback(n,r,i){n>=0&&n<this._microtaskId?this._zone.run(()=>r(i)):(0==this._animationCallbacksBuffer.length&&Promise.resolve(null).then(()=>{this._zone.run(()=>{this._animationCallbacksBuffer.forEach(s=>{const[o,a]=s;o(a)}),this._animationCallbacksBuffer=[]})}),this._animationCallbacksBuffer.push([r,i]))}end(){this._cdRecurDepth--,0==this._cdRecurDepth&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}}return t.\u0275fac=function(n){return new(n||t)(tt(Fs),tt(Ua),tt(Gt))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();class D_{constructor(e,n,r){this.namespaceId=e,this.delegate=n,this.engine=r,this.destroyNode=this.delegate.destroyNode?i=>n.destroyNode(i):null}get data(){return this.delegate.data}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.delegate.destroy()}createElement(e,n){return this.delegate.createElement(e,n)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,n){this.delegate.appendChild(e,n),this.engine.onInsert(this.namespaceId,n,e,!1)}insertBefore(e,n,r,i=!0){this.delegate.insertBefore(e,n,r),this.engine.onInsert(this.namespaceId,n,e,i)}removeChild(e,n,r){this.engine.onRemove(this.namespaceId,n,this.delegate,r)}selectRootElement(e,n){return this.delegate.selectRootElement(e,n)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,n,r,i){this.delegate.setAttribute(e,n,r,i)}removeAttribute(e,n,r){this.delegate.removeAttribute(e,n,r)}addClass(e,n){this.delegate.addClass(e,n)}removeClass(e,n){this.delegate.removeClass(e,n)}setStyle(e,n,r,i){this.delegate.setStyle(e,n,r,i)}removeStyle(e,n,r){this.delegate.removeStyle(e,n,r)}setProperty(e,n,r){"@"==n.charAt(0)&&n==S_?this.disableAnimations(e,!!r):this.delegate.setProperty(e,n,r)}setValue(e,n){this.delegate.setValue(e,n)}listen(e,n,r){return this.delegate.listen(e,n,r)}disableAnimations(e,n){this.engine.disableAnimations(e,n)}}class _x extends D_{constructor(e,n,r,i){super(n,r,i),this.factory=e,this.namespaceId=n}setProperty(e,n,r){"@"==n.charAt(0)?"."==n.charAt(1)&&n==S_?this.disableAnimations(e,r=void 0===r||!!r):this.engine.process(this.namespaceId,e,n.substr(1),r):this.delegate.setProperty(e,n,r)}listen(e,n,r){if("@"==n.charAt(0)){const i=function vx(t){switch(t){case"body":return document.body;case"document":return document;case"window":return window;default:return t}}(e);let s=n.substr(1),o="";return"@"!=s.charAt(0)&&([s,o]=function bx(t){const e=t.indexOf(".");return[t.substring(0,e),t.substr(e+1)]}(s)),this.engine.listen(this.namespaceId,i,s,o,a=>{this.factory.scheduleListenerCallback(a._data||-1,r,a)})}return this.delegate.listen(e,n,r)}}let Ax=(()=>{class t extends Ua{constructor(n,r,i){super(n.body,r,i)}ngOnDestroy(){this.flush()}}return t.\u0275fac=function(n){return new(n||t)(tt(Pn),tt(id),tt(gd))},t.\u0275prov=dt({token:t,factory:t.\u0275fac}),t})();const T_=new it("AnimationModuleType"),P_=[{provide:Hy,useClass:px},{provide:gd,useFactory:function Cx(){return new jI}},{provide:Ua,useClass:Ax},{provide:Fs,useFactory:function wx(t,e,n){return new yx(t,e,n)},deps:[Ca,Ua,Gt]}],M_=[{provide:id,useFactory:()=>new fx},{provide:T_,useValue:"BrowserAnimations"},...P_],Ex=[{provide:id,useClass:t_},{provide:T_,useValue:"NoopAnimations"},...P_];let Sx=(()=>{class t{static withConfig(n){return{ngModule:t,providers:n.disableAnimations?Ex:M_}}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({providers:M_,imports:[ky]}),t})();function At(t,e,n,r){var o,i=arguments.length,s=i<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,n,s):o(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s}const Tx=["pdfViewerContainer"],R_=function Px(t){const e=new t.EventBus(!0);return function Mx(t){t.on("documentload",function(){const e=document.createEvent("CustomEvent");e.initCustomEvent("documentload",!0,!0,{}),window.dispatchEvent(e)}),t.on("pagerendered",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("pagerendered",!0,!0,{pageNumber:e.pageNumber,cssTransform:e.cssTransform}),e.source.div.dispatchEvent(n)}),t.on("textlayerrendered",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("textlayerrendered",!0,!0,{pageNumber:e.pageNumber}),e.source.textLayerDiv.dispatchEvent(n)}),t.on("pagechanging",function(e){const n=document.createEvent("UIEvents");n.initEvent("pagechanging",!0,!0),n.pageNumber=e.pageNumber,e.source.container.dispatchEvent(n)}),t.on("pagesinit",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("pagesinit",!0,!0,null),e.source.container.dispatchEvent(n)}),t.on("pagesloaded",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("pagesloaded",!0,!0,{pagesCount:e.pagesCount}),e.source.container.dispatchEvent(n)}),t.on("scalechange",function(e){const n=document.createEvent("UIEvents");n.initEvent("scalechange",!0,!0),n.scale=e.scale,n.presetValue=e.presetValue,e.source.container.dispatchEvent(n)}),t.on("updateviewarea",function(e){const n=document.createEvent("UIEvents");n.initEvent("updateviewarea",!0,!0),n.location=e.location,e.source.container.dispatchEvent(n)}),t.on("find",function(e){if(e.source===window)return;const n=document.createEvent("CustomEvent");n.initCustomEvent("find"+e.type,!0,!0,{query:e.query,phraseSearch:e.phraseSearch,caseSensitive:e.caseSensitive,highlightAll:e.highlightAll,findPrevious:e.findPrevious}),window.dispatchEvent(n)}),t.on("attachmentsloaded",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("attachmentsloaded",!0,!0,{attachmentsCount:e.attachmentsCount}),e.source.container.dispatchEvent(n)}),t.on("sidebarviewchanged",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("sidebarviewchanged",!0,!0,{view:e.view}),e.source.outerContainer.dispatchEvent(n)}),t.on("pagemode",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("pagemode",!0,!0,{mode:e.mode}),e.source.pdfViewer.container.dispatchEvent(n)}),t.on("namedaction",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("namedaction",!0,!0,{action:e.action}),e.source.pdfViewer.container.dispatchEvent(n)}),t.on("presentationmodechanged",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("presentationmodechanged",!0,!0,{active:e.active,switchInProgress:e.switchInProgress}),window.dispatchEvent(n)}),t.on("outlineloaded",function(e){const n=document.createEvent("CustomEvent");n.initCustomEvent("outlineloaded",!0,!0,{outlineCount:e.outlineCount}),e.source.container.dispatchEvent(n)})}(e),e};var Jr;let Qt,mr;function za(){return"undefined"==typeof window}za()||(Qt=__webpack_require__(36),mr=__webpack_require__(813),Qt.verbosity=Qt.VerbosityLevel.ERRORS);var ei=(()=>(function(t){t[t.DISABLED=0]="DISABLED",t[t.ENABLED=1]="ENABLED",t[t.ENHANCED=2]="ENHANCED"}(ei||(ei={})),ei))();let ot=Jr=class{constructor(e){if(this.element=e,this.isVisible=!1,this._cMapsUrl=void 0!==Qt?`https://unpkg.com/pdfjs-dist@${Qt.version}/cmaps/`:null,this._renderText=!0,this._renderTextMode=ei.ENABLED,this._stickToPage=!1,this._originalSize=!0,this._page=1,this._zoom=1,this._zoomScale="page-width",this._rotation=0,this._showAll=!0,this._canAutoResize=!0,this._fitToPage=!1,this._externalLinkTarget="blank",this._showBorders=!1,this.isInitialized=!1,this.afterLoadComplete=new en,this.pageRendered=new en,this.textLayerRendered=new en,this.onError=new en,this.onProgress=new en,this.pageChange=new en(!0),za())return;let n;n=window.hasOwnProperty("pdfWorkerSrc")&&"string"==typeof window.pdfWorkerSrc&&window.pdfWorkerSrc?window.pdfWorkerSrc:`https://cdnjs.cloudflare.com/ajax/libs/pdf.js/${Qt.version}/pdf.worker.min.js`,Qt.GlobalWorkerOptions.workerSrc=n}set cMapsUrl(e){this._cMapsUrl=e}set page(e){const n=e=parseInt(e,10)||1;this._pdf&&(e=this.getValidPageNumber(e)),this._page=e,n!==e&&this.pageChange.emit(e)}set renderText(e){this._renderText=e}set renderTextMode(e){this._renderTextMode=e}set originalSize(e){this._originalSize=e}set showAll(e){this._showAll=e}set stickToPage(e){this._stickToPage=e}set zoom(e){e<=0||(this._zoom=e)}get zoom(){return this._zoom}set zoomScale(e){this._zoomScale=e}get zoomScale(){return this._zoomScale}set rotation(e){"number"==typeof e&&e%90==0?this._rotation=e:console.warn("Invalid pages rotation angle.")}set externalLinkTarget(e){this._externalLinkTarget=e}set autoresize(e){this._canAutoResize=Boolean(e)}set fitToPage(e){this._fitToPage=Boolean(e)}set showBorders(e){this._showBorders=Boolean(e)}static getLinkTarget(e){switch(e){case"blank":return Qt.LinkTarget.BLANK;case"none":return Qt.LinkTarget.NONE;case"self":return Qt.LinkTarget.SELF;case"parent":return Qt.LinkTarget.PARENT;case"top":return Qt.LinkTarget.TOP}return null}static setExternalLinkTarget(e){const n=Jr.getLinkTarget(e);null!==n&&(Qt.externalLinkTarget=n)}ngAfterViewChecked(){if(this.isInitialized)return;const e=this.pdfViewerContainer.nativeElement.offsetParent;!0!==this.isVisible||null!=e?!1===this.isVisible&&null!=e&&(this.isVisible=!0,setTimeout(()=>{this.ngOnInit(),this.ngOnChanges({src:this.src})})):this.isVisible=!1}ngOnInit(){!za()&&this.isVisible&&(this.isInitialized=!0,this.setupMultiPageViewer(),this.setupSinglePageViewer())}ngOnDestroy(){this.clear()}onPageResize(){!this._canAutoResize||!this._pdf||(this.resizeTimeout&&clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(()=>{this.updateSize()},100))}get pdfLinkService(){return this._showAll?this.pdfMultiPageLinkService:this.pdfSinglePageLinkService}get pdfViewer(){return this.getCurrentViewer()}get pdfFindController(){return this._showAll?this.pdfMultiPageFindController:this.pdfSinglePageFindController}ngOnChanges(e){if(!za()&&this.isVisible)if("src"in e)this.loadPDF();else if(this._pdf){if("renderText"in e?(this.getCurrentViewer().textLayerMode=this._renderText?this._renderTextMode:ei.DISABLED,this.resetPdfDocument()):"showAll"in e&&this.resetPdfDocument(),"page"in e){if(e.page.currentValue===this._latestScrolledPage)return;this.getCurrentViewer().scrollPageIntoView({pageNumber:this._page})}this.update()}}updateSize(){const e=this.getCurrentViewer();this._pdf.getPage(e.currentPageNumber).then(n=>{const r=this._rotation||n.rotate,i=n.getViewport({scale:this._zoom,rotation:r}).width*Jr.CSS_UNITS;let s=this._zoom,o=!0;if(!this._originalSize||this._fitToPage&&i>this.pdfViewerContainer.nativeElement.clientWidth){const a=n.getViewport({scale:1,rotation:r});s=this.getScale(a.width,a.height),o=!this._stickToPage}e._setScale(s,o)})}clear(){this.loadingTask&&!this.loadingTask.destroyed&&this.loadingTask.destroy(),this._pdf&&(this._pdf.destroy(),this._pdf=null,this.pdfMultiPageViewer.setDocument(null),this.pdfSinglePageViewer.setDocument(null),this.pdfMultiPageLinkService.setDocument(null,null),this.pdfSinglePageLinkService.setDocument(null,null),this.pdfMultiPageFindController.setDocument(null),this.pdfSinglePageFindController.setDocument(null))}setupMultiPageViewer(){Qt.disableTextLayer=!this._renderText,Jr.setExternalLinkTarget(this._externalLinkTarget);const e=R_(mr);e.on("pagerendered",r=>{this.pageRendered.emit(r)}),e.on("pagechanging",r=>{this.pageScrollTimeout&&clearTimeout(this.pageScrollTimeout),this.pageScrollTimeout=setTimeout(()=>{this._latestScrolledPage=r.pageNumber,this.pageChange.emit(r.pageNumber)},100)}),e.on("textlayerrendered",r=>{this.textLayerRendered.emit(r)}),this.pdfMultiPageLinkService=new mr.PDFLinkService({eventBus:e}),this.pdfMultiPageFindController=new mr.PDFFindController({linkService:this.pdfMultiPageLinkService,eventBus:e});const n={eventBus:e,container:this.element.nativeElement.querySelector("div"),removePageBorders:!this._showBorders,linkService:this.pdfMultiPageLinkService,textLayerMode:this._renderText?this._renderTextMode:ei.DISABLED,findController:this.pdfMultiPageFindController};this.pdfMultiPageViewer=new mr.PDFViewer(n),this.pdfMultiPageLinkService.setViewer(this.pdfMultiPageViewer),this.pdfMultiPageFindController.setDocument(this._pdf)}setupSinglePageViewer(){Qt.disableTextLayer=!this._renderText,Jr.setExternalLinkTarget(this._externalLinkTarget);const e=R_(mr);e.on("pagechanging",r=>{r.pageNumber!=this._page&&(this.page=r.pageNumber)}),e.on("pagerendered",r=>{this.pageRendered.emit(r)}),e.on("textlayerrendered",r=>{this.textLayerRendered.emit(r)}),this.pdfSinglePageLinkService=new mr.PDFLinkService({eventBus:e}),this.pdfSinglePageFindController=new mr.PDFFindController({linkService:this.pdfSinglePageLinkService,eventBus:e});const n={eventBus:e,container:this.element.nativeElement.querySelector("div"),removePageBorders:!this._showBorders,linkService:this.pdfSinglePageLinkService,textLayerMode:this._renderText?this._renderTextMode:ei.DISABLED,findController:this.pdfSinglePageFindController};this.pdfSinglePageViewer=new mr.PDFSinglePageViewer(n),this.pdfSinglePageLinkService.setViewer(this.pdfSinglePageViewer),this.pdfSinglePageFindController.setDocument(this._pdf),this.pdfSinglePageViewer._currentPageNumber=this._page}getValidPageNumber(e){return e<1?1:e>this._pdf.numPages?this._pdf.numPages:e}getDocumentParams(){const e=typeof this.src;if(!this._cMapsUrl)return this.src;const n={cMapUrl:this._cMapsUrl,cMapPacked:!0};return"string"===e?n.url=this.src:"object"===e&&(void 0!==this.src.byteLength?n.data=this.src:Object.assign(n,this.src)),n}loadPDF(){if(!this.src)return;if(this.lastLoaded===this.src)return void this.update();this.clear(),this.loadingTask=Qt.getDocument(this.getDocumentParams()),this.loadingTask.onProgress=n=>{this.onProgress.emit(n)};const e=this.src;this.loadingTask.promise.then(n=>{this._pdf=n,this.lastLoaded=e,this.afterLoadComplete.emit(n),this.pdfMultiPageViewer||(this.setupMultiPageViewer(),this.setupSinglePageViewer()),this.resetPdfDocument(),this.update()},n=>{this.onError.emit(n)})}update(){this.page=this._page,this.render()}render(){this._page=this.getValidPageNumber(this._page);const e=this.getCurrentViewer();(0!==this._rotation||e.pagesRotation!==this._rotation)&&setTimeout(()=>{e.pagesRotation=this._rotation}),this._stickToPage&&setTimeout(()=>{e.currentPageNumber=this._page}),this.updateSize()}getScale(e,n){const r=this._showBorders?2*Jr.BORDER_WIDTH:0,i=this.pdfViewerContainer.nativeElement.clientWidth-r,s=this.pdfViewerContainer.nativeElement.clientHeight-r;if(0===s||0===n||0===i||0===e)return 1;let o=1;switch(this._zoomScale){case"page-fit":o=Math.min(s/n,i/e);break;case"page-height":o=s/n;break;default:o=i/e}return this._zoom*o/Jr.CSS_UNITS}getCurrentViewer(){return this._showAll?this.pdfMultiPageViewer:this.pdfSinglePageViewer}resetPdfDocument(){this.pdfFindController.setDocument(this._pdf),this._showAll?(this.pdfSinglePageViewer.setDocument(null),this.pdfSinglePageLinkService.setDocument(null),this.pdfMultiPageViewer.setDocument(this._pdf),this.pdfMultiPageLinkService.setDocument(this._pdf,null)):(this.pdfMultiPageViewer.setDocument(null),this.pdfMultiPageLinkService.setDocument(null),this.pdfSinglePageViewer.setDocument(this._pdf),this.pdfSinglePageLinkService.setDocument(this._pdf,null))}};ot.\u0275fac=function(e){return new(e||ot)(function Xe(t,e=Ge.Default){const n=me();return null===n?tt(t,e):oh(Lt(),n,Ue(t),e)}(Mr))},ot.\u0275cmp=to({type:ot,selectors:[["pdf-viewer"]],viewQuery:function(e,n){if(1&e&&lc(Tx,5),2&e){let r;ac(r=uc())&&(n.pdfViewerContainer=r.first)}},hostBindings:function(e,n){1&e&&$o("resize",function(){return n.onPageResize()},!1,af)},inputs:{cMapsUrl:["c-maps-url","cMapsUrl"],page:"page",renderText:["render-text","renderText"],renderTextMode:["render-text-mode","renderTextMode"],originalSize:["original-size","originalSize"],showAll:["show-all","showAll"],stickToPage:["stick-to-page","stickToPage"],zoom:"zoom",zoomScale:["zoom-scale","zoomScale"],rotation:"rotation",externalLinkTarget:["external-link-target","externalLinkTarget"],autoresize:"autoresize",fitToPage:["fit-to-page","fitToPage"],showBorders:["show-borders","showBorders"],src:"src"},outputs:{afterLoadComplete:"after-load-complete",pageRendered:"page-rendered",textLayerRendered:"text-layer-rendered",onError:"error",onProgress:"on-progress",pageChange:"pageChange"},features:[ui],decls:3,vars:0,consts:[[1,"ng2-pdf-viewer-container"],["pdfViewerContainer",""],[1,"pdfViewer"]],template:function(e,n){1&e&&(Ps(0,"div",0,1),ku(2,"div",2),Ms())},styles:['.ng2-pdf-viewer-container[_ngcontent-%COMP%]{overflow-x:auto;position:relative;height:100%;-webkit-overflow-scrolling:touch}[_nghost-%COMP%] .textLayer{position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden;opacity:.2;line-height:1}[_nghost-%COMP%] .textLayer>span{color:transparent;position:absolute;white-space:pre;cursor:text;-webkit-transform-origin:0 0;transform-origin:0 0}[_nghost-%COMP%] .textLayer .highlight{margin:-1px;padding:1px;background-color:#b400aa;border-radius:4px}[_nghost-%COMP%] .textLayer .highlight.begin{border-radius:4px 0 0 4px}[_nghost-%COMP%] .textLayer .highlight.end{border-radius:0 4px 4px 0}[_nghost-%COMP%] .textLayer .highlight.middle{border-radius:0}[_nghost-%COMP%] .textLayer .highlight.selected{background-color:#006400}[_nghost-%COMP%] .textLayer ::-moz-selection{background:#00f}[_nghost-%COMP%] .textLayer ::selection{background:#00f}[_nghost-%COMP%] .textLayer .endOfContent{display:block;position:absolute;left:0;top:100%;right:0;bottom:0;z-index:-1;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}[_nghost-%COMP%] .textLayer .endOfContent.active{top:0}[_nghost-%COMP%] .annotationLayer section{position:absolute}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.pushButton>a, [_nghost-%COMP%] .annotationLayer .linkAnnotation>a{position:absolute;font-size:1em;top:0;left:0;width:100%;height:100%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.pushButton>a:hover, [_nghost-%COMP%] .annotationLayer .linkAnnotation>a:hover{opacity:.2;background:#ff0;box-shadow:0 2px 10px #ff0}[_nghost-%COMP%] .annotationLayer .textAnnotation img{position:absolute;cursor:pointer}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;padding:0 3px;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;padding:0 3px;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{background-color:rgba(0,54,255,.13);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;vertical-align:top;width:100%}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select option{padding:0}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{border-radius:50%}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea{font:message-box;font-size:9px;resize:none}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input[disabled], [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input[disabled], [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input[disabled]{background:0 0;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input:hover, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:hover, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input:hover{border:1px solid #000}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input:focus, [_nghost-%COMP%] .annotationLayer .textWidgetAnnotation textarea:focus{background:0 0;border:1px solid transparent}[_nghost-%COMP%] .annotationLayer .choiceWidgetAnnotation select:focus{background:0 0;border:1px solid transparent}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before{background-color:#000;content:"";display:block;position:absolute;height:80%;left:45%;width:1px}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input:checked:before{background-color:#000;content:"";display:block;position:absolute;border-radius:50%;height:50%;left:30%;top:20%;width:50%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before{-webkit-transform:rotate(45deg);transform:rotate(45deg)}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input.comb{font-family:monospace;padding-left:2px;padding-right:0}[_nghost-%COMP%] .annotationLayer .textWidgetAnnotation input.comb:focus{width:115%}[_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%] .annotationLayer .buttonWidgetAnnotation.radioButton input{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0}[_nghost-%COMP%] .annotationLayer .popupWrapper{position:absolute;width:20em}[_nghost-%COMP%] .annotationLayer .popup{position:absolute;z-index:200;max-width:20em;background-color:#ff9;box-shadow:0 2px 5px #888;border-radius:2px;padding:6px;margin-left:5px;cursor:pointer;font:message-box;font-size:9px;word-wrap:break-word}[_nghost-%COMP%] .annotationLayer .popup>*{font-size:9px}[_nghost-%COMP%] .annotationLayer .popup h1{display:inline-block}[_nghost-%COMP%] .annotationLayer .popup span{display:inline-block;margin-left:5px}[_nghost-%COMP%] .annotationLayer .popup p{border-top:1px solid #333;margin-top:2px;padding-top:2px}[_nghost-%COMP%] .annotationLayer .caretAnnotation, [_nghost-%COMP%] .annotationLayer .circleAnnotation svg ellipse, [_nghost-%COMP%] .annotationLayer .fileAttachmentAnnotation, [_nghost-%COMP%] .annotationLayer .freeTextAnnotation, [_nghost-%COMP%] .annotationLayer .highlightAnnotation, [_nghost-%COMP%] .annotationLayer .inkAnnotation svg polyline, [_nghost-%COMP%] .annotationLayer .lineAnnotation svg line, [_nghost-%COMP%] .annotationLayer .polygonAnnotation svg polygon, [_nghost-%COMP%] .annotationLayer .polylineAnnotation svg polyline, [_nghost-%COMP%] .annotationLayer .squareAnnotation svg rect, [_nghost-%COMP%] .annotationLayer .squigglyAnnotation, [_nghost-%COMP%] .annotationLayer .stampAnnotation, [_nghost-%COMP%] .annotationLayer .strikeoutAnnotation, [_nghost-%COMP%] .annotationLayer .underlineAnnotation{cursor:pointer}[_nghost-%COMP%] .pdfViewer{padding-bottom:10px}[_nghost-%COMP%] .pdfViewer .canvasWrapper{overflow:hidden}[_nghost-%COMP%] .pdfViewer .page{direction:ltr;width:816px;height:1056px;margin:1px auto -8px;position:relative;overflow:visible;border:9px solid rgba(0,0,0,.01);box-sizing:initial;background-clip:content-box;-webkit-border-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAA6UlEQVR4Xl2Pi2rEMAwE16fm1f7/r14v7w4rI0IzLAF7hLxNevBSEMEF5+OilNCsRd8ZMyn+a4NmsOT8WJw1lFbSYgGFzF2bLFoLjTClWjKKGRWpDYAGXUnZ4uhbBUzF3Oe/GG/ue2fn4GgsyXhNgysV2JnrhKEMg4fEZcALmiKbNhBBRFpSyDOj1G4QOVly6O1FV54ZZq8OVygrciDt6JazRgi1ljTPH0gbrPmHPXAbCiDd4GawIjip1TPh9tt2sz24qaCjr/jAb/GBFTbq9KZ7Ke/Cqt8nayUikZKsWZK7Fe6bg5dOUt8fZHWG2BHc+6EAAAAASUVORK5CYII=) 9 9 repeat;-o-border-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAA6UlEQVR4Xl2Pi2rEMAwE16fm1f7/r14v7w4rI0IzLAF7hLxNevBSEMEF5+OilNCsRd8ZMyn+a4NmsOT8WJw1lFbSYgGFzF2bLFoLjTClWjKKGRWpDYAGXUnZ4uhbBUzF3Oe/GG/ue2fn4GgsyXhNgysV2JnrhKEMg4fEZcALmiKbNhBBRFpSyDOj1G4QOVly6O1FV54ZZq8OVygrciDt6JazRgi1ljTPH0gbrPmHPXAbCiDd4GawIjip1TPh9tt2sz24qaCjr/jAb/GBFTbq9KZ7Ke/Cqt8nayUikZKsWZK7Fe6bg5dOUt8fZHWG2BHc+6EAAAAASUVORK5CYII=) 9 9 repeat;border-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAA6UlEQVR4Xl2Pi2rEMAwE16fm1f7/r14v7w4rI0IzLAF7hLxNevBSEMEF5+OilNCsRd8ZMyn+a4NmsOT8WJw1lFbSYgGFzF2bLFoLjTClWjKKGRWpDYAGXUnZ4uhbBUzF3Oe/GG/ue2fn4GgsyXhNgysV2JnrhKEMg4fEZcALmiKbNhBBRFpSyDOj1G4QOVly6O1FV54ZZq8OVygrciDt6JazRgi1ljTPH0gbrPmHPXAbCiDd4GawIjip1TPh9tt2sz24qaCjr/jAb/GBFTbq9KZ7Ke/Cqt8nayUikZKsWZK7Fe6bg5dOUt8fZHWG2BHc+6EAAAAASUVORK5CYII=) 9 9 repeat;background-color:#fff}[_nghost-%COMP%] .pdfViewer.removePageBorders .page{margin:0 auto 10px;border:none}[_nghost-%COMP%] .pdfViewer.removePageBorders{padding-bottom:0}[_nghost-%COMP%] .pdfViewer.singlePageView{display:inline-block}[_nghost-%COMP%] .pdfViewer.singlePageView .page{margin:0;border:none}[_nghost-%COMP%] .pdfViewer.scrollHorizontal, [_nghost-%COMP%] .pdfViewer.scrollWrapped{margin-left:3.5px;margin-right:3.5px;text-align:center}[_nghost-%COMP%] .spread{margin-left:3.5px;margin-right:3.5px;text-align:center}[_nghost-%COMP%] .pdfViewer.scrollHorizontal, [_nghost-%COMP%] .spread{white-space:nowrap}[_nghost-%COMP%] .pdfViewer.removePageBorders, [_nghost-%COMP%] .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%] .pdfViewer.scrollWrapped .spread{margin-left:0;margin-right:0}[_nghost-%COMP%] .spread .page{display:inline-block;vertical-align:middle;margin-left:-3.5px;margin-right:-3.5px}[_nghost-%COMP%] .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%] .pdfViewer.scrollWrapped .page, [_nghost-%COMP%] .pdfViewer.scrollWrapped .spread{display:inline-block;vertical-align:middle}[_nghost-%COMP%] .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.scrollWrapped .page{margin-left:-3.5px;margin-right:-3.5px}[_nghost-%COMP%] .pdfViewer.removePageBorders .spread .page, [_nghost-%COMP%] .pdfViewer.removePageBorders.scrollHorizontal .page, [_nghost-%COMP%] .pdfViewer.removePageBorders.scrollWrapped .page{margin-left:5px;margin-right:5px}[_nghost-%COMP%] .pdfViewer .page canvas{margin:0;display:block}[_nghost-%COMP%] .pdfViewer .page canvas[hidden]{display:none}[_nghost-%COMP%] .pdfViewer .page .loadingIcon{position:absolute;display:block;left:0;top:0;right:0;bottom:0;background:url(data:image/gif;base64,R0lGODlhGAAYAPQAAP///wAAAM7Ozvr6+uDg4LCwsOjo6I6OjsjIyJycnNjY2KioqMDAwPLy8nZ2doaGhri4uGhoaAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJBwAAACwAAAAAGAAYAAAFriAgjiQAQWVaDgr5POSgkoTDjFE0NoQ8iw8HQZQTDQjDn4jhSABhAAOhoTqSDg7qSUQwxEaEwwFhXHhHgzOA1xshxAnfTzotGRaHglJqkJcaVEqCgyoCBQkJBQKDDXQGDYaIioyOgYSXA36XIgYMBWRzXZoKBQUMmil0lgalLSIClgBpO0g+s26nUWddXyoEDIsACq5SsTMMDIECwUdJPw0Mzsu0qHYkw72bBmozIQAh+QQJBwAAACwAAAAAGAAYAAAFsCAgjiTAMGVaDgR5HKQwqKNxIKPjjFCk0KNXC6ATKSI7oAhxWIhezwhENTCQEoeGCdWIPEgzESGxEIgGBWstEW4QCGGAIJEoxGmGt5ZkgCRQQHkGd2CESoeIIwoMBQUMP4cNeQQGDYuNj4iSb5WJnmeGng0CDGaBlIQEJziHk3sABidDAHBgagButSKvAAoyuHuUYHgCkAZqebw0AgLBQyyzNKO3byNuoSS8x8OfwIchACH5BAkHAAAALAAAAAAYABgAAAW4ICCOJIAgZVoOBJkkpDKoo5EI43GMjNPSokXCINKJCI4HcCRIQEQvqIOhGhBHhUTDhGo4diOZyFAoKEQDxra2mAEgjghOpCgz3LTBIxJ5kgwMBShACREHZ1V4Kg1rS44pBAgMDAg/Sw0GBAQGDZGTlY+YmpyPpSQDiqYiDQoCliqZBqkGAgKIS5kEjQ21VwCyp76dBHiNvz+MR74AqSOdVwbQuo+abppo10ssjdkAnc0rf8vgl8YqIQAh+QQJBwAAACwAAAAAGAAYAAAFrCAgjiQgCGVaDgZZFCQxqKNRKGOSjMjR0qLXTyciHA7AkaLACMIAiwOC1iAxCrMToHHYjWQiA4NBEA0Q1RpWxHg4cMXxNDk4OBxNUkPAQAEXDgllKgMzQA1pSYopBgonCj9JEA8REQ8QjY+RQJOVl4ugoYssBJuMpYYjDQSliwasiQOwNakALKqsqbWvIohFm7V6rQAGP6+JQLlFg7KDQLKJrLjBKbvAor3IKiEAIfkECQcAAAAsAAAAABgAGAAABbUgII4koChlmhokw5DEoI4NQ4xFMQoJO4uuhignMiQWvxGBIQC+AJBEUyUcIRiyE6CR0CllW4HABxBURTUw4nC4FcWo5CDBRpQaCoF7VjgsyCUDYDMNZ0mHdwYEBAaGMwwHDg4HDA2KjI4qkJKUiJ6faJkiA4qAKQkRB3E0i6YpAw8RERAjA4tnBoMApCMQDhFTuySKoSKMJAq6rD4GzASiJYtgi6PUcs9Kew0xh7rNJMqIhYchACH5BAkHAAAALAAAAAAYABgAAAW0ICCOJEAQZZo2JIKQxqCOjWCMDDMqxT2LAgELkBMZCoXfyCBQiFwiRsGpku0EshNgUNAtrYPT0GQVNRBWwSKBMp98P24iISgNDAS4ipGA6JUpA2WAhDR4eWM/CAkHBwkIDYcGiTOLjY+FmZkNlCN3eUoLDmwlDW+AAwcODl5bYl8wCVYMDw5UWzBtnAANEQ8kBIM0oAAGPgcREIQnVloAChEOqARjzgAQEbczg8YkWJq8nSUhACH5BAkHAAAALAAAAAAYABgAAAWtICCOJGAYZZoOpKKQqDoORDMKwkgwtiwSBBYAJ2owGL5RgxBziQQMgkwoMkhNqAEDARPSaiMDFdDIiRSFQowMXE8Z6RdpYHWnEAWGPVkajPmARVZMPUkCBQkJBQINgwaFPoeJi4GVlQ2Qc3VJBQcLV0ptfAMJBwdcIl+FYjALQgimoGNWIhAQZA4HXSpLMQ8PIgkOSHxAQhERPw7ASTSFyCMMDqBTJL8tf3y2fCEAIfkECQcAAAAsAAAAABgAGAAABa8gII4k0DRlmg6kYZCoOg5EDBDEaAi2jLO3nEkgkMEIL4BLpBAkVy3hCTAQKGAznM0AFNFGBAbj2cA9jQixcGZAGgECBu/9HnTp+FGjjezJFAwFBQwKe2Z+KoCChHmNjVMqA21nKQwJEJRlbnUFCQlFXlpeCWcGBUACCwlrdw8RKGImBwktdyMQEQciB7oACwcIeA4RVwAODiIGvHQKERAjxyMIB5QlVSTLYLZ0sW8hACH5BAkHAAAALAAAAAAYABgAAAW0ICCOJNA0ZZoOpGGQrDoOBCoSxNgQsQzgMZyIlvOJdi+AS2SoyXrK4umWPM5wNiV0UDUIBNkdoepTfMkA7thIECiyRtUAGq8fm2O4jIBgMBA1eAZ6Knx+gHaJR4QwdCMKBxEJRggFDGgQEREPjjAMBQUKIwIRDhBDC2QNDDEKoEkDoiMHDigICGkJBS2dDA6TAAnAEAkCdQ8ORQcHTAkLcQQODLPMIgIJaCWxJMIkPIoAt3EhACH5BAkHAAAALAAAAAAYABgAAAWtICCOJNA0ZZoOpGGQrDoOBCoSxNgQsQzgMZyIlvOJdi+AS2SoyXrK4umWHM5wNiV0UN3xdLiqr+mENcWpM9TIbrsBkEck8oC0DQqBQGGIz+t3eXtob0ZTPgNrIwQJDgtGAgwCWSIMDg4HiiUIDAxFAAoODwxDBWINCEGdSTQkCQcoegADBaQ6MggHjwAFBZUFCm0HB0kJCUy9bAYHCCPGIwqmRq0jySMGmj6yRiEAIfkECQcAAAAsAAAAABgAGAAABbIgII4k0DRlmg6kYZCsOg4EKhLE2BCxDOAxnIiW84l2L4BLZKipBopW8XRLDkeCiAMyMvQAA+uON4JEIo+vqukkKQ6RhLHplVGN+LyKcXA4Dgx5DWwGDXx+gIKENnqNdzIDaiMECwcFRgQCCowiCAcHCZIlCgICVgSfCEMMnA0CXaU2YSQFoQAKUQMMqjoyAglcAAyBAAIMRUYLCUkFlybDeAYJryLNk6xGNCTQXY0juHghACH5BAkHAAAALAAAAAAYABgAAAWzICCOJNA0ZVoOAmkY5KCSSgSNBDE2hDyLjohClBMNij8RJHIQvZwEVOpIekRQJyJs5AMoHA+GMbE1lnm9EcPhOHRnhpwUl3AsknHDm5RN+v8qCAkHBwkIfw1xBAYNgoSGiIqMgJQifZUjBhAJYj95ewIJCQV7KYpzBAkLLQADCHOtOpY5PgNlAAykAEUsQ1wzCgWdCIdeArczBQVbDJ0NAqyeBb64nQAGArBTt8R8mLuyPyEAOwAAAAAAAAAAAA==) center no-repeat}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer{margin-left:0;margin-right:0}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode .pdfViewer .spread{display:block}[_nghost-%COMP%] .pdfPresentationMode .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode .pdfViewer.removePageBorders .page{margin-left:auto;margin-right:auto}[_nghost-%COMP%] .pdfPresentationMode:-ms-fullscreen .pdfViewer .page{margin-bottom:100%!important}[_nghost-%COMP%] .pdfPresentationMode:-webkit-full-screen .pdfViewer .page{margin-bottom:100%;border:0}[_nghost-%COMP%] .pdfPresentationMode:-moz-full-screen .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode:-webkit-full-screen .pdfViewer .page, [_nghost-%COMP%] .pdfPresentationMode:fullscreen .pdfViewer .page{margin-bottom:100%;border:0}']}),ot.CSS_UNITS=96/72,ot.BORDER_WIDTH=9,ot.ctorParameters=()=>[{type:Mr}],At([Wv("pdfViewerContainer")],ot.prototype,"pdfViewerContainer",void 0),At([qi("after-load-complete")],ot.prototype,"afterLoadComplete",void 0),At([qi("page-rendered")],ot.prototype,"pageRendered",void 0),At([qi("text-layer-rendered")],ot.prototype,"textLayerRendered",void 0),At([qi("error")],ot.prototype,"onError",void 0),At([qi("on-progress")],ot.prototype,"onProgress",void 0),At([qi()],ot.prototype,"pageChange",void 0),At([nn()],ot.prototype,"src",void 0),At([nn("c-maps-url")],ot.prototype,"cMapsUrl",null),At([nn("page")],ot.prototype,"page",null),At([nn("render-text")],ot.prototype,"renderText",null),At([nn("render-text-mode")],ot.prototype,"renderTextMode",null),At([nn("original-size")],ot.prototype,"originalSize",null),At([nn("show-all")],ot.prototype,"showAll",null),At([nn("stick-to-page")],ot.prototype,"stickToPage",null),At([nn("zoom")],ot.prototype,"zoom",null),At([nn("zoom-scale")],ot.prototype,"zoomScale",null),At([nn("rotation")],ot.prototype,"rotation",null),At([nn("external-link-target")],ot.prototype,"externalLinkTarget",null),At([nn("autoresize")],ot.prototype,"autoresize",null),At([nn("fit-to-page")],ot.prototype,"fitToPage",null),At([nn("show-borders")],ot.prototype,"showBorders",null),At([RS("window:resize",[])],ot.prototype,"onPageResize",null);let Ix=(()=>{let t=class{};return t.\u0275fac=function(n){return new(n||t)},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({}),t})();const xx=["wrapper"];let Rx=(()=>{class t{constructor(){this.loaded=!1}ngOnInit(){}ngOnChanges(n){}}return t.\u0275fac=function(n){return new(n||t)},t.\u0275cmp=to({type:t,selectors:[["drayman-pdf-viewer-internal"]],viewQuery:function(n,r){if(1&n&&lc(xx,5),2&n){let i;ac(i=uc())&&(r.wrapper=i.first)}},inputs:{src:"src",page:"page"},features:[ui],decls:2,vars:6,consts:[[3,"src","page","show-all","original-size","autoresize","fit-to-page","after-load-complete"],["wrapper",""]],template:function(n,r){1&n&&(Ps(0,"pdf-viewer",0,1),$o("after-load-complete",function(){return r.loaded=!0}),Ms()),2&n&&Nu("src",r.src)("page",r.page)("show-all",!r.page)("original-size",!1)("autoresize",!0)("fit-to-page",!0)},directives:[ot],styles:["pdf-viewer[_ngcontent-%COMP%]{width:100%;height:100%}"]}),t})(),Lx=(()=>{class t{constructor(n){this.injector=n}ngDoBootstrap(){const n=function TM(t,e){const n=function bM(t,e){return e.get(Ui).resolveComponentFactory(t).inputs}(t,e.injector),r=e.strategyFactory||new EM(t,e.injector),i=function vM(t){const e={};return t.forEach(({propName:n,templateName:r})=>{e[function pM(t){return t.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}(r)]=n}),e}(n);class s extends DM{constructor(a){super(),this.injector=a}get ngElementStrategy(){if(!this._ngElementStrategy){const a=this._ngElementStrategy=r.create(this.injector||e.injector);n.forEach(({propName:l})=>{if(!this.hasOwnProperty(l))return;const u=this[l];delete this[l],a.setInputValue(l,u)})}return this._ngElementStrategy}attributeChangedCallback(a,l,u,g){this.ngElementStrategy.setInputValue(i[a],u)}connectedCallback(){let a=!1;this.ngElementStrategy.events&&(this.subscribeToEvents(),a=!0),this.ngElementStrategy.connect(this),a||this.subscribeToEvents()}disconnectedCallback(){this._ngElementStrategy&&this._ngElementStrategy.disconnect(),this.ngElementEventsSubscription&&(this.ngElementEventsSubscription.unsubscribe(),this.ngElementEventsSubscription=null)}subscribeToEvents(){this.ngElementEventsSubscription=this.ngElementStrategy.events.subscribe(a=>{const l=new CustomEvent(a.name,{detail:a.value});this.dispatchEvent(l)})}}return s.observedAttributes=Object.keys(i),n.forEach(({propName:o})=>{Object.defineProperty(s.prototype,o,{get(){return this.ngElementStrategy.getInputValue(o)},set(a){this.ngElementStrategy.setInputValue(o,a)},configurable:!0,enumerable:!0})}),s}(Rx,{injector:this.injector});customElements.define("drayman-pdf-viewer",n)}}return t.\u0275fac=function(n){return new(n||t)(tt(Dn))},t.\u0275mod=Or({type:t}),t.\u0275inj=vr({imports:[[ky,Sx,Ix]]}),t})();(function tD(){Qm=!1})(),VP().bootstrapModule(Lx).catch(t=>console.error(t))})()})();