PageSourceSearch

https://bro-depot.com/_next/static/chunks/5068-146d104b4d913027.js

js bro-depot.com collected 2026-10-04 02:40:37 UTC 205,340 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5068,81,3252,2419],{38601:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(e){var t=e.files,n=o.useRef(),a=o.useContext(r.LocalizationContext).l10n,i=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,c=o.useRef([]),l=a&&a.attachment?a.attachment.clickToDownload:"Click to download",u=function(e){var t=n.current,r=[].slice.call(t.getElementsByClassName("rpv-attachment__item"));if(0!==r.length){r.forEach((function(e){return e.setAttribute("tabindex","-1")}));var o=document.activeElement,a=r[Math.min(r.length-1,Math.max(0,e(r,o)))];a.setAttribute("tabindex","0"),a.focus()}};return r.useIsomorphicLayoutEffect((function(){var e=n.current;if(e){var t=[].slice.call(e.getElementsByClassName("rpv-attachment__item"));if(c.current=t,t.length>0){var r=t[0];r.focus(),r.setAttribute("tabindex","0")}}}),[]),o.createElement("div",{"data-testid":"attachment__list",className:r.classNames({"rpv-attachment__list":!0,"rpv-attachment__list--rtl":i}),ref:n,tabIndex:-1,onKeyDown:function(e){switch(e.key){case"ArrowDown":e.preventDefault(),u((function(e,t){return e.indexOf(t)+1}));break;case"ArrowUp":e.preventDefault(),u((function(e,t){return e.indexOf(t)-1}));break;case"End":e.preventDefault(),u((function(e,t){return e.length-1}));break;case"Home":e.preventDefault(),u((function(e,t){return 0}))}}},t.map((function(e){return o.createElement("button",{className:"rpv-attachment__item",key:e.fileName,tabIndex:-1,title:l,type:"button",onClick:function(){return t=e.fileName,r="string"==typeof(n=e.data)?"":URL.createObjectURL(new Blob([n],{type:""})),(o=document.createElement("a")).style.display="none",o.href=r||t,o.setAttribute("download",function(e){var t=e.split("/").pop();return t?t.split("#")[0].split("?")[0]:e}(t)),document.body.appendChild(o),o.click(),document.body.removeChild(o),void(r&&URL.revokeObjectURL(r));var t,n,r,o}},e.fileName)})))},i=function(e){var t=e.doc,n=o.useContext(r.LocalizationContext).l10n,i=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,c=n&&n.attachment?n.attachment.noAttachment:"There is no attachment",l=o.useState({files:[],isLoaded:!1}),u=l[0],s=l[1];return o.useEffect((function(){t.getAttachments().then((function(e){var t=e?Object.keys(e).map((function(t){return{data:e[t].content,fileName:e[t].filename}})):[];s({files:t,isLoaded:!0})}))}),[t]),u.isLoaded?0===u.files.length?o.createElement("div",{"data-testid":"attachment__empty",className:r.classNames({"rpv-attachment__empty":!0,"rpv-attachment__empty--rtl":i})},c):o.createElement(a,{files:u.files}):o.createElement(r.Spinner,null)},c=function(e){var t=e.store,n=o.useState(t.get("doc")),a=n[0],c=n[1],l=function(e){c(e)};return o.useEffect((function(){return t.subscribe("doc",l),function(){t.unsubscribe("doc",l)}}),[]),a?o.createElement(i,{doc:a}):o.createElement("div",{className:"rpv-attachment__loader"},o.createElement(r.Spinner,null))};t.attachmentPlugin=function(){var e=o.useMemo((function(){return r.createStore({})}),[]);return{onDocumentLoad:function(t){e.update("doc",t.doc)},Attachments:function(){return o.createElement(c,{store:e})}}}},27504:function(e,t,n){"use strict";e.exports=n(38601)},38200:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o,a=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),i=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M6.427,8.245A.5.5,0,0,1,6.862,7.5H17.138a.5.5,0,0,1,.435.749l-5.139,9a.5.5,0,0,1-.868,0Z"}))},c=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M9.248,17.572a.5.5,0,0,1-.748-.434V6.862a.5.5,0,0,1,.748-.434l8.992,5.138a.5.5,0,0,1,0,.868Z"}))},l=function(e){var t=e.bookmark,n=e.depth,r=e.doc,o=e.index,l=e.isBookmarkExpanded,s=e.numberOfSiblings,d=e.renderBookmarkItem,p=e.store,f=e.onJumpToDest,m=a.useMemo((function(){return function(e){var t=e.count,n=e.items;if(t>=0)return!1;var r=n.length;if(0===r)return!1;for(var o=n.concat([]);o.length>0;){var a=o.shift(),i=a.items;a.count&&i&&a.count>0&&i.length>0&&(r+=i.length,o=o.concat(i))}return Math.abs(t)===r}(t)}),[t]),g=l?l({bookmark:t,doc:r,depth:n,index:o}):!m,h=a.useState(g),v=h[0],b=h[1],E=t.items&&t.items.length>0,_=function(){return b((function(e){return!e}))},y=function(){E&&t.dest&&f(t.dest)},k=function(){!E&&t.dest&&f(t.dest)},C=function(e,t){return a.createElement("div",{className:"rpv-bookmark__item",style:{paddingLeft:"".concat(1.25*n,"rem")},onClick:e},t)},w=function(e,t){return E?a.createElement("span",{className:"rpv-bookmark__toggle","data-testid":"bookmark__toggle-".concat(n,"-").concat(o),onClick:_},v?e:t):a.createElement("span",{className:"rpv-bookmark__toggle"})},S=function(e){return t.url?a.createElement("a",{className:"rpv-bookmark__title",href:t.url,rel:"noopener noreferrer nofollow",target:t.newWindow?"_blank":""},t.title):a.createElement("div",{className:"rpv-bookmark__title","aria-label":t.title,onClick:e},t.title)};return a.createElement("li",{"aria-expanded":v?"true":"false","aria-label":t.title,"aria-level":n+1,"aria-posinset":o+1,"aria-setsize":s,role:"treeitem",tabIndex:-1},d?d({bookmark:t,depth:n,hasSubItems:E,index:o,isExpanded:v,defaultRenderItem:C,defaultRenderTitle:S,defaultRenderToggle:w,onClickItem:k,onClickTitle:y,onToggleSubItems:_}):C(k,a.createElement(a.Fragment,null,w(a.createElement(i,null),a.createElement(c,null)),S(y))),E&&v&&a.createElement(u,{bookmarks:t.items,depth:n+1,doc:r,isBookmarkExpanded:l,isRoot:!1,renderBookmarkItem:d,store:p,onJumpToDest:f}))},u=function(e){var t=e.bookmarks,n=e.depth,r=void 0===n?0:n,o=e.doc,i=e.isBookmarkExpanded,c=e.isRoot,u=e.renderBookmarkItem,s=e.store,d=e.onJumpToDest;return a.createElement("ul",{className:"rpv-bookmark__list",role:c?"tree":"group",tabIndex:-1},t.map((function(e,n){return a.createElement(l,{bookmark:e,depth:r,doc:o,index:n,isBookmarkExpanded:i,key:n,numberOfSiblings:t.length,renderBookmarkItem:u,store:s,onJumpToDest:d})})))};!function(e){e[e.Collapse=0]="Collapse",e[e.Expand=1]="Expand"}(o||(o={}));var s=function(e){var t=e.bookmarks,n=e.doc,i=e.isBookmarkExpanded,c=e.renderBookmarkItem,l=e.store,s=e.onJumpToDest,d=a.useRef(),p=a.useState(l.get("linkAnnotations")||{}),f=p[0],m=p[1],g=function(e,t){var n=e.dest;n&&"string"==typeof n&&t[n]&&(t[n].querySelectorAll('a[data-annotation-link-dest="'.concat(n,'"]')).forEac
1h((function(t){t.setAttribute("aria-label",e.title)})),e.items&&e.items.length&&e.items.forEach((function(e){return g(e,t)})))},h=function(e){return m(e)},v=function(e){var t=d.current;if(t&&e.target instanceof HTMLElement&&t.contains(e.target))switch(e.key){case"ArrowDown":e.preventDefault(),E((function(e,t){return e.indexOf(t)+1}));break;case"ArrowLeft":e.preventDefault(),_(o.Collapse);break;case"ArrowRight":e.preventDefault(),_(o.Expand);break;case"ArrowUp":e.preventDefault,E((function(e,t){return e.indexOf(t)-1}));break;case"End":e.preventDefault(),E((function(e,t){return e.length-1}));break;case" ":case"Enter":case"Space":e.preventDefault(),b();break;case"Home":e.preventDefault(),E((function(e,t){return 0}))}},b=function(){var e=document.activeElement.closest(".rpv-bookmark__item").querySelector(".rpv-bookmark__title");e&&e.click()},E=function(e){var t=d.current,n=[].slice.call(t.getElementsByClassName("rpv-bookmark__item"));if(0!==n.length){var r=document.activeElement,o=n[Math.min(n.length-1,Math.max(0,e(n,r)))];r.setAttribute("tabindex","-1"),o.setAttribute("tabindex","0"),o.focus()}},_=function(e){var t=d.current;if(0!==[].slice.call(t.getElementsByClassName("rpv-bookmark__item")).length){var n=document.activeElement.closest(".rpv-bookmark__item"),r=e===o.Collapse?"true":"false";if(n&&n.parentElement.getAttribute("aria-expanded")===r){var a=n.querySelector(".rpv-bookmark__toggle");a&&a.click()}}};return a.useEffect((function(){return document.addEventListener("keydown",v),l.subscribe("linkAnnotations",h),function(){document.removeEventListener("keydown",v),l.unsubscribe("linkAnnotations",h)}}),[]),a.useEffect((function(){t.forEach((function(e){return g(e,f)}))}),[f]),a.useEffect((function(){var e=d.current;if(e){var t=[].slice.call(e.getElementsByClassName("rpv-bookmark__item"));t.length>0&&(t[0].focus(),t[0].setAttribute("tabindex","0"))}}),[]),a.createElement("div",{ref:d},a.createElement(u,{bookmarks:t,depth:0,doc:n,isBookmarkExpanded:i,isRoot:!0,renderBookmarkItem:c,store:l,onJumpToDest:function(e){r.getDestination(n,e).then((function(e){var t=e.pageIndex,n=e.bottomOffset,r=e.leftOffset,o=e.scaleTo;s(t,n,r,o)}))}}))},d=function(e){var t=e.doc,n=e.isBookmarkExpanded,o=e.renderBookmarkItem,i=e.store,c=e.onJumpToDest,l=a.useContext(r.LocalizationContext).l10n,u=a.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,d=a.useState({isLoaded:!1,items:[]}),p=d[0],f=d[1];return a.useEffect((function(){f({isLoaded:!1,items:[]}),t.getOutline().then((function(e){f({isLoaded:!0,items:e||[]})}))}),[t]),p.isLoaded?0===p.items.length?a.createElement("div",{"data-testid":"bookmark__empty",className:r.classNames({"rpv-bookmark__empty":!0,"rpv-bookmark__empty--rtl":u})},l&&l.bookmark?l.bookmark.noBookmark:"There is no bookmark"):a.createElement("div",{"data-testid":"bookmark__container",className:r.classNames({"rpv-bookmark__container":!0,"rpv-bookmark__container--rtl":u})},a.createElement(s,{bookmarks:p.items,doc:t,isBookmarkExpanded:n,renderBookmarkItem:o,store:i,onJumpToDest:c})):a.createElement("div",{className:"rpv-bookmark__loader"},a.createElement(r.Spinner,null))},p=function(e){var t=e.isBookmarkExpanded,n=e.renderBookmarkItem,o=e.store,i=a.useState(o.get("doc")),c=i[0],l=i[1],u=function(e){l(e)};return a.useEffect((function(){return o.subscribe("doc",u),function(){o.unsubscribe("doc",u)}}),[]),c?a.createElement(d,{doc:c,isBookmarkExpanded:t,renderBookmarkItem:n,store:o,onJumpToDest:function(e,t,n,r){var a=o.get("jumpToDestination");a&&a(e,t,n,r)}}):a.createElement("div",{className:"rpv-bookmark__loader"},a.createElement(r.Spinner,null))};t.DownArrowIcon=i,t.RightArrowIcon=c,t.bookmarkPlugin=function(){var e=a.useMemo((function(){return r.createStore({linkAnnotations:{}})}),[]);return{install:function(t){e.update("jumpToDestination",t.jumpToDestination)},onDocumentLoad:function(t){e.update("doc",t.doc)},Bookmarks:function(t){return a.createElement(p,{isBookmarkExpanded:null==t?void 0:t.isBookmarkExpanded,renderBookmarkItem:null==t?void 0:t.renderBookmarkItem,store:e})},onAnnotationLayerRender:function(t){if(t.annotations.length){var n=t.annotations.filter((function(e){return"Link"===e.subtype}));if(n.length){var r=e.get("linkAnnotations")||{};
1n.forEach((function(e){return r[e.dest]=t.container})),e.update("linkAnnotations",r)}}}}}},42227:function(e,t,n){"use strict";e.exports=n(38200)},89469:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(67294),o=n(99299);function a(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var i,c=a(r),l=a(o);t.AnnotationType=void 0,(i=t.AnnotationType||(t.AnnotationType={}))[i.Text=1]="Text",i[i.Link=2]="Link",i[i.FreeText=3]="FreeText",i[i.Line=4]="Line",i[i.Square=5]="Square",i[i.Circle=6]="Circle",i[i.Polygon=7]="Polygon",i[i.Polyline=8]="Polyline",i[i.Highlight=9]="Highlight",i[i.Underline=10]="Underline",i[i.Squiggly=11]="Squiggly",i[i.StrikeOut=12]="StrikeOut",i[i.Stamp=13]="Stamp",i[i.Caret=14]="Caret",i[i.Ink=15]="Ink",i[i.Popup=16]="Popup",i[i.FileAttachment=17]="FileAttachment";var u=function(e,t){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},u(e,t)};function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}u(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var d,p=function(){return p=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},p.apply(this,arguments)};t.TextDirection=void 0,(d=t.TextDirection||(t.TextDirection={})).RightToLeft="RTL",d.LeftToRight="LTR";var f,m=c.createContext({currentTheme:"light",direction:t.TextDirection.LeftToRight,setCurrentTheme:function(){}}),g=function(e){var t=[];return Object.keys(e).forEach((function(n){n&&e[n]&&t.push(n)})),t.join(" ")},h="undefined"!=typeof window?c.useLayoutEffect:c.useEffect,v=function(e){var t=c.useRef(null),n=e.once,r=e.threshold,o=e.onVisibilityChanged;return h((function(){var e=t.current;if(e){var a=new IntersectionObserver((function(t){t.forEach((function(t){var r=t.isIntersecting,i=t.intersectionRatio;o({isVisible:r,ratio:i}),r&&n&&(a.unobserve(e),a.disconnect())}))}),{threshold:r||0});return a.observe(e),function(){a.unobserve(e),a.disconnect()}}}),[]),t},b=function(e){var n=e.children,r=e.ignoreDirection,o=void 0!==r&&r,a=e.size,i=void 0===a?24:a,l=c.useContext(m).direction,u=!o&&l===t.TextDirection.RightToLeft,s="".concat(i||24,"px");return c.createElement("svg",{"aria-hidden":"true",className:g({"rpv-core__icon":!0,"rpv-core__icon--rtl":u}),focusable:"false",height:s,viewBox:"0 0 24 24",width:s},n)},E=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M23.5,0.499l-16.5,23l-6.5-6.5"}))},_=function(e){var n=e.children,r=e.testId,o=e.onClick,a=c.useContext(m).direction===t.TextDirection.RightToLeft,i=r?{"data-testid":r}:{};return c.createElement("button",p({className:g({"rpv-core__primary-button":!0,"rpv-core__primary-button--rtl":a}),type:"button",onClick:o},i),n)},y=function(e){var t=e.size,n=void 0===t?"4rem":t,r=e.testId,o=c.useState(!1),a=o[0],i=o[1],l=r?{"data-testid":r}:{},u=v({onVisibilityChanged:function(e){i(e.isVisible)}});return c.createElement("div",p({},l,{className:g({"rpv-core__spinner":!0,"rpv-core__spinner--animating":a}),ref:u,style:{height:n,width:n}}))},k=function(e){var n=e.ariaLabel,r=void 0===n?"":n,o=e.autoFocus,a=void 0!==o&&o,i=e.placeholder,l=void 0===i?"":i,u=e.testId,s=e.type,d=void 0===s?"text":s,f=e.value,v=void 0===f?"":f,b=e.onChange,E=e.onKeyDown,_=void 0===E?function(){}:E,y=c.useContext(m).direction,k=c.useRef(),C=y===t.TextDirection.RightToLeft,w={ref:k,"data-testid":"","aria-label":r,className:g({"rpv-core__textbox":!0,"rpv-core__textbox--rtl":C}),placeholder:l,value:v,onChange:function(e){return b(e.target.value)},onKeyDown:_};return u&&(w["data-testid"]=u),h((function(){if(a){var e=k.current;if(e){var t=window.scrollX,n=window.scrollY;e.focus(),window.scrollTo(t,n)}}}),[]),"text"===d?c.createElement("input",p({type:"text"},w)):c.createElement("input",p({type:"password"},w))},C=function(){var e=c.useRef(!1);return c.useEffect((function(){return e.current=!0,function(){e.current=!1}}),[]),e};!function(e){e.NotRenderedYet="NotRenderedYet",e.Rendering="Rendering",e.Rendered="Rendered"}(f||(f={}));var w,S=function(e){var t=e.doc,n=t.numPages,r=t.loadingTask.docId,o=c.useMemo((function(){return Array(n).fill(null).map((function(e,t){return{pageIndex:t,render
1Status:f.NotRenderedYet,visibility:-9999}}))}),[r]),a=c.useRef({currentRenderingPage:-1,startRange:0,endRange:n-1,visibilities:o}),i=function(e,t){a.current.visibilities[e].visibility=t};return{getHighestPriorityPage:function(){var e=a.current.visibilities.slice(a.current.startRange,a.current.endRange+1).filter((function(e){return e.visibility>-9999}));if(!e.length)return-1;for(var t=e[0].pageIndex,r=e[e.length-1].pageIndex,o=e.length,i=0;i<o;i++){if(e[i].renderStatus===f.Rendering)return-1;if(e[i].renderStatus===f.NotRenderedYet)return e[i].pageIndex}return r+1<n&&a.current.visibilities[r+1].renderStatus!==f.Rendered?r+1:t-1>=0&&a.current.visibilities[t-1].renderStatus!==f.Rendered?t-1:-1},isInRange:function(e){return e>=a.current.startRange&&e<=a.current.endRange},markNotRendered:function(){for(var e=0;e<n;e++)a.current.visibilities[e].renderStatus=f.NotRenderedYet},markRendered:function(e){a.current.visibilities[e].renderStatus=f.Rendered},markRendering:function(e){-1!==a.current.currentRenderingPage&&a.current.currentRenderingPage!==e&&a.current.visibilities[a.current.currentRenderingPage].renderStatus===f.Rendering&&(a.current.visibilities[a.current.currentRenderingPage].renderStatus=f.NotRenderedYet),a.current.visibilities[e].renderStatus=f.Rendering,a.current.currentRenderingPage=e},setOutOfRange:function(e){i(e,-9999)},setRange:function(e,t){a.current.startRange=e,a.current.endRange=t;for(var r=0;r<n;r++)(r<e||r>t)&&(a.current.visibilities[r].visibility=-9999,a.current.visibilities[r].renderStatus=f.NotRenderedYet)},setVisibility:i}},P={core:{askingPassword:{requirePasswordToOpen:"This document requires a password to open",submit:"Submit"},wrongPassword:{tryAgain:"The password is wrong. Please try again"},pageLabel:"Page {{pageIndex}}"}},x=c.createContext({l10n:P,setL10n:function(){}}),M=0,R=function(){return M++},L=function(e,t,n){var r=function(e){var r=t.current;r&&!r.contains(e.target)&&n()};c.useEffect((function(){if(e){var t={capture:!0};return document.addEventListener("click",r,t),function(){document.removeEventListener("click",r,t)}}}),[])},T=function(e){var t=function(t){"Escape"===t.key&&e()};c.useEffect((function(){return document.addEventListener("keyup",t),function(){document.removeEventListener("keyup",t)}}),[])},O=function(e){var n=e.ariaControlsSuffix,r=e.children,o=e.closeOnClickOutside,a=e.closeOnEscape,i=e.onToggle,l=c.useRef(),u=c.useContext(m).direction===t.TextDirection.RightToLeft;return c.useEffect((function(){var e=window.getComputedStyle(document.body).overflow;return document.body.style.overflow="hidden",function(){document.body.style.overflow=e}}),[]),T((function(){l.current&&a&&i()})),L(o,l,i),h((function(){var e=l.current;if(e){var t=.75*document.body.clientHeight;e.getBoundingClientRect().height>=t&&(e.style.overflow="auto",e.style.maxHeight="".concat(t,"px"))}}),[]),c.createElement("div",{"aria-modal":"true",className:g({"rpv-core__modal-body":!0,"rpv-core__modal-body--rtl":u}),id:"rpv-core__modal-body-".concat(n),ref:l,role:"dialog",tabIndex:-1},r)},I=function(e){var t=e.children;return c.createElement("div",{className:"rpv-core__modal-overlay"},t)};t.ToggleStatus=void 0,(w=t.ToggleStatus||(t.ToggleStatus={})).Close="Close",w.Open="Open",w.Toggle="Toggle";var D,N=function(e){var n=c.useState(e),r=n[0],o=n[1];return{opened:r,toggle:function(e){switch(e){case t.ToggleStatus.Close:o(!1);break;case t.ToggleStatus.Open:o(!0);break;case t.ToggleStatus.Toggle:default:o((function(e){return!e}))}}}},z=function(e){var t=e.content,n=e.isOpened,r=void 0!==n&&n,o=e.target,a=N(r),i=a.opened,l=a.toggle;return c.createElement(c.Fragment,null,o&&o(l,i),i&&t(l))};t.Position=void 0,(D=t.Position||(t.Position={})).TopLeft="TOP_LEFT",D.TopCenter="TOP_CENTER",D.TopRight="TOP_RIGHT",D.RightTop="RIGHT_TOP",D.RightCenter="RIGHT_CENTER",D.RightBottom="RIGHT_BOTTOM",D.BottomLeft="BOTTOM_LEFT",D.BottomCenter="BOTTOM_CENTER",D.BottomRight="BOTTOM_RIGHT",D.LeftTop="LEFT_TOP",D.LeftCenter="LEFT_CENTER",D.LeftBottom="LEFT_BOTTOM";var F,j,B,A,H,V=function(e,n,r,o,a){h((function(){var i=n.current,c=e.current,l=r.current;if(c&&i&&l){var u=l.getBoundingClientRect(),s=function(e,n,r,o){var a=n.getBoundingClientRect(),i=e.getBoundingClientRect(),c=i.height,l=i.width,u=0,s=0;switch(r){case t.Position.TopLeft:u=a.top-c,s=a.left;break;case t.Position.TopCenter:u=a.top-c,s=a.left+a.width/2-l/2;break;case t.Position.TopRight:u=a.top-c,s=a.left+a.width-l;break;case t.Position.RightTop:u=a.top,s=a.left+a.width;break;case t.Position.RightCenter:u=a.top+a.height/2-c/2,s=a.left+a.width;break;case t.Position.RightBottom:u=a.top+a.height-c,s=a.left+a.width;break;case t.Position.BottomLeft:u=a.top+a.height,s=a.left;break;case t.Position.BottomCenter:u=a.top+a.height,s=a.left+a.width/2-l/2;break;case t.Position.BottomRight:u=a.top+a.height,s=a.left+a.width-l;break;case t.Position.LeftTop:u=a.top,s=a.left-l;break;case t.Position.LeftCenter:u=a.top+a.height/2-c/2,s=a.left-l;break;case t.Position.LeftBottom:u=a.top+a.height-c,s=a.left-l}return{left:s+(o.left||0),top:u+(o.top||0)}}(c,i,o,a),d=s.top,p=s.left;c.style.top="".concat(d-u.top,"px"),c.style.left="".concat(p-u.left,"px")}}),[])},W=function(e){var n,r=e.customClassName,o=e.position;return c.createElement("div",{className:g((n={"rpv-core__arrow":!0,"rpv-core__arrow--tl":o===t.Position.TopLeft,"rpv-core__arrow--tc":o===t.Position.TopCenter,"rpv-core__arrow--tr":o===t.Position.TopRight,"rpv-core__arrow--rt":o===t.Position.RightTop,"rpv-core__arrow--rc":o===t.Position.RightCenter,"rpv-core__arrow--rb":o===t.Position.RightBottom,"rpv-core__arrow--bl":o===t.Position.BottomLeft,"rpv-core__arrow--bc":o===t.Position.BottomCenter,"rpv-core__arrow--br":o===t.Position.BottomRight,"rpv-core__arrow--lt":o===t.Position.LeftTop,"rpv-core__arrow--lc":o===t.Position.LeftCenter,"rpv-core__arrow--lb":o===t.Position.LeftBottom},n["".concat(r)]=""!==r,n))})}
1,U=function(e){var n=e.ariaControlsSuffix,r=e.children,o=e.closeOnClickOutside,a=e.offset,i=e.position,l=e.targetRef,u=e.onClose,s=c.useRef(),d=c.useRef(),p=c.useRef(),f=c.useContext(m).direction===t.TextDirection.RightToLeft;L(o,s,u),V(s,l,p,i,a),h((function(){var e=d.current;if(e){var t=.75*document.body.clientHeight;e.getBoundingClientRect().height>=t&&(e.style.overflow="auto",e.style.maxHeight="".concat(t,"px"))}}),[]);var v="rpv-core__popover-body-inner-".concat(n);return c.createElement(c.Fragment,null,c.createElement("div",{ref:p,style:{left:0,position:"absolute",top:0}}),c.createElement("div",{"aria-describedby":v,className:g({"rpv-core__popover-body":!0,"rpv-core__popover-body--rtl":f}),id:"rpv-core__popover-body-".concat(n),ref:s,role:"dialog",tabIndex:-1},c.createElement(W,{customClassName:"rpv-core__popover-body-arrow",position:i}),c.createElement("div",{id:v,ref:d},r)))},Z=function(e){var t=e.closeOnEscape,n=e.onClose,r=c.useRef();return T((function(){r.current&&t&&n()})),c.createElement("div",{className:"rpv-core__popover-overlay",ref:r})},K=function(e){var n=e.ariaControlsSuffix,r=e.children,o=e.contentRef,a=e.offset,i=e.position,l=e.targetRef,u=c.useRef(),s=c.useContext(m).direction===t.TextDirection.RightToLeft;return V(o,l,u,i,a),c.createElement(c.Fragment,null,c.createElement("div",{ref:u,style:{left:0,position:"absolute",top:0}}),c.createElement("div",{className:g({"rpv-core__tooltip-body":!0,"rpv-core__tooltip-body--rtl":s}),id:"rpv-core__tooltip-body-".concat(n),ref:o,role:"tooltip"},c.createElement(W,{customClassName:"rpv-core__tooltip-body-arrow",position:i}),c.createElement("div",{className:"rpv-core__tooltip-body-content"},r)))};t.LayerRenderStatus=void 0,(F=t.LayerRenderStatus||(t.LayerRenderStatus={}))[F.PreRender=0]="PreRender",F[F.DidRender=1]="DidRender",t.PageMode=void 0,(j=t.PageMode||(t.PageMode={})).Attachments="UseAttachments",j.Bookmarks="UseOutlines",j.ContentGroup="UseOC",j.Default="UserNone",j.FullScreen="FullScreen",j.Thumbnails="UseThumbs",t.RotateDirection=void 0,(B=t.RotateDirection||(t.RotateDirection={})).Backward="Backward",B.Forward="Forward",t.ScrollMode=void 0,(A=t.ScrollMode||(t.ScrollMode={})).Horizontal="Horizontal",A.Vertical="Vertical",A.Wrapped="Wrapped",t.SpecialZoomLevel=void 0,(H=t.SpecialZoomLevel||(t.SpecialZoomLevel={})).ActualSize="ActualSize",H.PageFit="PageFit",H.PageWidth="PageWidth";var G=function(e,n){switch(n[1].name){case"XYZ":return{bottomOffset:n[3],leftOffset:n[2]||0,pageIndex:e,scaleTo:n[4]};case"Fit":case"FitB":return{bottomOffset:0,leftOffset:0,pageIndex:e,scaleTo:t.SpecialZoomLevel.PageFit};case"FitH":case"FitBH":return{bottomOffset:n[2],leftOffset:0,pageIndex:e,scaleTo:t.SpecialZoomLevel.PageWidth};default:return{bottomOffset:0,leftOffset:0,pageIndex:e,scaleTo:1}}},q=new Map,J=new Map,Y=function(e,t){return"".concat(e.loadingTask.docId,"___").concat(t.num,"R").concat(0===t.gen?"":t.gen)},Q=function(e,t,n){q.set(Y(e,t),n)},X=function(e,t){if(!e)return Promise.reject("The document is not loaded yet");var n="".concat(e.loadingTask.docId,"___").concat(t),r=J.get(n);return r?Promise.resolve(r):new Promise((function(r,o){e.getPage(t+1).then((function(o){J.set(n,o),o.ref&&Q(e,o.ref,t),r(o)}))}))},$=function(e,t){return new Promise((function(n){new Promise((function(n){"string"==typeof t?e.getDestination(t).then((function(e){n(e)})):n(t)})).then((function(r){if("object"==typeof r[0]&&null!==r[0]){var o=r[0],a=function(e,t){var n=Y(e,t);return q.has(n)?q.get(n):null}(e,o);null===a?e.getPageIndex(o).then((function(r){Q(e,o,r),$(e,t).then((function(e){return n(e)}))})):n(G(a,r))}else{var i=G(r[0],r);n(i)}}))}))};function ee(e){var t=c.useRef(e);return c.useEffect((function(){t.current=e}),[e]),t.current}var te,ne=function(e,t){var n=t.rect;return e.height!==n.height||e.width!==n.width?n:e},re=function(e){return 1-Math.pow(1-e,4)},oe={left:0,top:0},ae={capture:!1,passive:!0},ie=function(e){var n=e.elementRef,r=e.isRtl,o=e.scrollMode,a=e.onSmoothScroll,i=function(e){var t=C(),n=c.useRef(0),r=c.useState(e),o=r[0],a=r[1],i=c.useCallback((function(e){cancelAnimationFrame(n.current),n.current=requestAnimationFrame((function(){t.current&&a(e)}))}),[]);return c.useEffect((function(){return function(){cancelAnimationFrame(n.current)}}),[]),[o,i]}(oe),l=i[0],u=i[1],s=c.useState(n.current),d=s[0],p=s[1],f=r?-1:1,m=c.useRef(o);m.current=o;var g=c.useCallback((function(){return a(!1)}),[]),v=c.useCallback((function(){if(d)switch(m.current){case t.ScrollMode.Horizontal:u({left:f*d.scrollLeft,top:0});break;case t.ScrollMode.Vertical:default:u({left:0,top:d.scrollTop})}}),[d]);h((function(){p(n.current)})),h((function(){if(d)return d.addEventListener("scroll",v,ae),function(){d.removeEventListener("scroll",v,ae)}}),[d]);var b=c.useCallback((function(e,r){var o=n.current;if(o){var i=0,c=t.ScrollMode.Vertical;switch(m.current){case t.ScrollMode.Horizontal:i=f*e.left,c=t.ScrollMode.Horizontal;break;case t.ScrollMode.Vertical:default:i=e.top,c=t.ScrollMode.Vertical}if(r)a(!0),function(e,n,r,o,a,i){void 0===a&&(a=function(e){return e}),void 0===i&&(i=function(){});var c=0;switch(n){case t.ScrollMode.Horizontal:c=e.scrollLeft;case t.ScrollMode.Vertical:default:c=e.scrollTop}var l,u=-1,s=c-r;
1if(0!==s){var d=function(o){-1===u&&(u=o);var p=o-u,f=Math.min(p/400,1),m=a(f),g=c-s*m;switch(n){case t.ScrollMode.Horizontal:e.scrollLeft=g;case t.ScrollMode.Vertical:default:e.scrollTop=g}g===r&&i(),p<400?l=window.requestAnimationFrame(d):window.cancelAnimationFrame(l)};l=window.requestAnimationFrame(d)}}(o,c,i,0,re,g);else switch(m.current){case t.ScrollMode.Horizontal:o.scrollLeft=i;break;case t.ScrollMode.Vertical:default:o.scrollTop=i}}}),[n]);return{scrollOffset:l,scrollTo:b}},ce={height:0,width:0},le={left:0,top:0},ue=function(e){var n=e.estimateSize,r=e.isRtl,o=e.numberOfItems,a=e.setStartRange,i=e.setEndRange,l=e.parentRef,u=e.scrollMode,s=e.transformSize,d=c.useState(!1),f=d[0],m=d[1],g=c.useCallback((function(e){return m(e)}),[]),v=ie({elementRef:l,isRtl:r,scrollMode:u,onSmoothScroll:g}),b=v.scrollOffset,E=v.scrollTo,_=function(e){var t=e.elementRef,n=c.useState(t.current),r=n[0],o=n[1],a=c.useRef(!1),i=c.useReducer(ne,{height:0,width:0}),l=i[0],u=i[1];return h((function(){t.current!==r&&o(t.current)})),h((function(){if(r&&!a.current){a.current=!0;var e=r.getBoundingClientRect(),t=e.height,n=e.width;u({rect:{height:t,width:n}})}}),[r]),c.useEffect((function(){if(r){var e=new ResizeObserver((function(e,t){e.forEach((function(e){if(e.target===r){var t=e.contentRect,n=t.height,o=t.width;u({rect:{height:n,width:o}})}}))}));return e.observe(r),function(){e.unobserve(r)}}}),[r]),l}({elementRef:l}),y=c.useRef({scrollOffset:le,measurements:[],parentRect:ce,totalSize:ce});y.current.scrollOffset=b,y.current.parentRect=_;var k=c.useState({}),C=k[0],w=k[1],S=c.useMemo((function(){for(var e=[],r=0,a={left:0,top:0},i=0,c=0;c<o;c++){var l=C[c]||s(n(c)),d=le;if(0===c)r=l.width,a={left:0,top:0},i=l.height;else switch(u){case t.ScrollMode.Wrapped:(r+=l.width)<_.width?(d={left:e[c-1].end.left,top:a.top},i=Math.max(i,l.height)):(r=l.width,a={left:(d={left:a.left,top:a.top+i}).left,top:d.top},i=l.height);break;case t.ScrollMode.Horizontal:case t.ScrollMode.Vertical:default:d=e[c-1].end}var p={left:d.left+l.width,top:d.top+l.height};e[c]={index:c,start:d,size:l,end:p,visibility:-1}}return e}),[n,u,_,C,s]),P=S[o-1]?{height:S[o-1].end.top,width:S[o-1].end.left}:ce;y.current.measurements=S,y.current.totalSize=P;var x=function(e,n,r,o){var a=0;switch(e){case t.ScrollMode.Horizontal:a=o.left;break;case t.ScrollMode.Vertical:default:a=o.top}var i=n.length-1,c=function(e,t,n,r){for(;e<=t;){var o=(e+t)/2|0,a=r(o);if(a<n)e=o+1;else{if(!(a>n))return o;t=o-1}}return e>0?e-1:0}(0,i,a,(function(r){switch(e){case t.ScrollMode.Horizontal:return n[r].start.left;case t.ScrollMode.Wrapped:case t.ScrollMode.Vertical:default:return n[r].start.top}}));if(e===t.ScrollMode.Wrapped)for(var l=n[c].start.top;c-1>=0&&n[c-1].start.top===l&&n[c-1].start.left>=o.left;)c--;for(var u=c,s={},d=c,p=-1;u<=i;){var f=n[u].size,m=ce,g={top:n[u].start.top-o.top,left:n[u].start.left-o.left},h={height:r.height-g.top,width:r.width-g.left};if(e===t.ScrollMode.Horizontal&&h.width<0){u--;break}if(e===t.ScrollMode.Vertical&&h.height<0){u--;break}if(e===t.ScrollMode.Wrapped&&(h.width<0||h.height<0)){u--;break}if(e===t.ScrollMode.Vertical)m.width=1;else if(g.left<0){var v=f.width- -g.left;m.width=v<=r.width?v/r.width:1}else m.width=f.width<=h.width?1:h.width/f.width;if(e===t.ScrollMode.Horizontal)m.height=1;else if(g.top<0){var b=f.height- -g.top;m.height=b<=r.height?b/r.height:1}else m.height=f.height<=h.height?1:h.height/f.height;s[u]=m.width*m.height,p<s[u]&&(p=s[u],d=u),u++}return{start:c,end:u,maxVisbilityIndex:d,visibilities:s}}(u,y.current.measurements,y.current.parentRect,y.current.scrollOffset),M=x.maxVisbilityIndex,R=x.visibilities,L=x.start,T=x.end,O=a(L),I=i(T),D=c.useMemo((function(){for(var e=[],t=function(t){var n=S[t],r=p(p({},n),{visibility:void 0!==R[t]?R[t]:-1,measureRef:function(e){if(e){var r=e.getBoundingClientRect();if(0!==r.height||0!==r.width){var o=s({height:r.height,width:r.width});o.height===n.size.height&&o.width===n.size.width||w((function(e){var n;return p(p({},e),((n={})[t]=o,n))}))}}}});e.push(r)},n=O;n<=I;n++)t(n);return e}),[s,R,S]),N=c.useCallback((function(e,t){var n,r,a=y.current.measurements[(0,n=o-1,r=e,Math.max(0,Math.min(r,n)))];a&&E({left:t.left+a.start.left,top:t.top+a.start.top},!0)}),[E]),z=c.useCallback((function(){switch(u){case t.ScrollMode.Horizontal:return{position:"relative",height:"100%",width:"".concat(P.width,"px")}
1;case t.ScrollMode.Vertical:default:return{position:"relative",height:"".concat(P.height,"px"),width:"100%"}}}),[u,P]),F=c.useCallback((function(e){var n,o,a,i=r?"right":"left",c=r?-1:1;switch(u){case t.ScrollMode.Horizontal:return(n={height:"100%",width:"".concat(e.size.width,"px")})[i]=0,n.position="absolute",n.top=0,n.transform="translateX(".concat(e.start.left*c,"px)"),n;case t.ScrollMode.Wrapped:return(o={height:"".concat(e.size.height,"px"),width:"".concat(e.size.width,"px")})[i]=0,o.position="absolute",o.top=0,o.transform="translate(".concat(e.start.left*c,"px, ").concat(e.start.top,"px)"),o;case t.ScrollMode.Vertical:default:return(a={height:"".concat(e.size.height,"px"),width:"100%"})[i]=0,a.position="absolute",a.top=0,a.transform="translateY(".concat(e.start.top,"px)"),a}}),[r,u]),j=c.useCallback((function(e){w({});var t=y.current.scrollOffset,n={left:t.left*e,top:t.top*e};E(n,!1)}),[]);return{isSmoothScrolling:f,startIndex:L,startRange:O,endIndex:T,endRange:I,maxVisbilityIndex:M,virtualItems:D,getContainerStyles:z,getItemStyles:F,scrollToItem:N,zoom:j}};!function(e){e[e.Solid=1]="Solid",e[e.Dashed=2]="Dashed",e[e.Beveled=3]="Beveled",e[e.Inset=4]="Inset",e[e.Underline=5]="Underline"}(te||(te={}));var se,de=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"),pe=function(e,t,n,r){var o=parseInt(e,10);return o>=t&&o<=n?o:r},fe=function(e){var n=e.annotation,r=c.useContext(m).direction===t.TextDirection.RightToLeft,o=c.useRef(),a="";if(n.modificationDate){var i=function(e){var t=de.exec(e);if(!t)return null;var n=parseInt(t[1],10),r=pe(t[2],1,12,1)-1,o=pe(t[3],1,31,1),a=pe(t[4],0,23,0),i=pe(t[5],0,59,0),c=pe(t[6],0,59,0),l=t[7]||"Z",u=pe(t[8],0,23,0),s=pe(t[9],0,59,0);switch(l){case"-":a+=u,i+=s;break;case"+":a-=u,i-=s}return new Date(Date.UTC(n,r,o,a,i,c))}(n.modificationDate);a=i?"".concat(i.toLocaleDateString(),", ").concat(i.toLocaleTimeString()):""}return c.useLayoutEffect((function(){if(o.current){var e=document.querySelector('[data-annotation-id="'.concat(n.id,'"]'));if(e){var t=e;return t.style.zIndex+=1,function(){t.style.zIndex="".concat(parseInt(t.style.zIndex,10)-1)}}}}),[]),c.createElement("div",{ref:o,className:g({"rpv-core__annotation-popup-wrapper":!0,"rpv-core__annotation-popup-wrapper--rtl":r}),style:{top:n.annotationType===t.AnnotationType.Popup?"":"100%"}},n.title&&c.createElement(c.Fragment,null,c.createElement("div",{className:g({"rpv-core__annotation-popup-title":!0,"rpv-core__annotation-popup-title--ltr":!r,"rpv-core__annotation-popup-title--rtl":r})},n.title),c.createElement("div",{className:"rpv-core__annotation-popup-date"},a)),n.contents&&c.createElement("div",{className:"rpv-core__annotation-popup-content"},n.contents.split("\n").map((function(e,t){return c.createElement(c.Fragment,{key:t},e,c.createElement("br",null))}))))};!function(e){e.Click="Click",e.Hover="Hover"}(se||(se={}));var me,ge=function(e){var n,r=e.annotation,o=e.children,a=e.ignoreBorder,i=e.hasPopup,l=e.isRenderable,u=e.page,s=e.viewport,d=r.rect,p=function(){var e=N(!1),n=e.opened,r=e.toggle,o=c.useState(se.Hover),a=o[0],i=o[1];return{opened:n,closeOnHover:function(){a===se.Hover&&r(t.ToggleStatus.Close)},openOnHover:function(){a===se.Hover&&r(t.ToggleStatus.Open)},toggleOnClick:function(){switch(a){case se.Click:n&&i(se.Hover),r(t.ToggleStatus.Toggle);break;case se.Hover:i(se.Click),r(t.ToggleStatus.Open)}}}}(),f=p.closeOnHover,m=p.opened,g=p.openOnHover,h=p.toggleOnClick,v=(n=[d[0],u.view[3]+u.view[1]-d[1],d[2],u.view[3]+u.view[1]-d[3]],[Math.min(n[0],n[2]),Math.min(n[1],n[3]),Math.max(n[0],n[2]),Math.max(n[1],n[3])]),b=d[2]-d[0],E=d[3]-d[1],_={borderColor:"",borderRadius:"",borderStyle:"",borderWidth:""};if(!a&&r.borderStyle.width>0){switch(r.borderStyle.style){case te.Dashed:_.borderStyle="dashed";break;case te.Solid:_.borderStyle="solid";break;case te.Underline:_=Object.assign({borderBottomStyle:"solid"},_);case te.Beveled:case te.Inset:}var y=r.borderStyle.width;_.borderWidth="".concat(y,"px"),r.borderStyle.style!==te.Underline&&(b-=2*y,E-=2*y);var k=r.borderStyle,C=k.horizontalCornerRadius,w=k.verticalCornerRadius;(C>0||w>0)&&(_.borderRadius="".concat(C,"px / ").concat(w,"px")),r.color?_.borderColor="rgb(".concat(0|r.color[0],", ").concat(0|r.color[1],", ").concat(0|r.color[2],")"):_.borderWidth="0"}return c.createElement(c.Fragment,null,l&&o({popup:{opened:m,closeOnHover:f,openOnHover:g,toggleOnClick:h}
1,slot:{attrs:{style:Object.assign({height:"".concat(E,"px"),left:"".concat(v[0],"px"),top:"".concat(v[1],"px"),transform:"matrix(".concat(s.transform.join(","),")"),transformOrigin:"-".concat(v[0],"px -").concat(v[1],"px"),width:"".concat(b,"px")},_)},children:c.createElement(c.Fragment,null,i&&m&&c.createElement(fe,{annotation:r}))}}))},he=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--caret","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},ve=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--circle","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},c.createElement("circle",{cy:u/2,fill:"none",rx:l/2-s/2,ry:u/2-s/2,stroke:"transparent",strokeWidth:s||1})),e.slot.children)}))},be=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!(!1!==t.hasPopup||!t.title&&!t.contents),a=function(){var e,n,r,o,a=t.file;a&&(e=a.filename,r="string"==typeof(n=a.content)?"":URL.createObjectURL(new Blob([n],{type:""})),(o=document.createElement("a")).style.display="none",o.href=r||e,o.setAttribute("download",function(e){var t=e.split("/").pop();return t?t.split("#")[0].split("?")[0]:e}(e)),document.body.appendChild(o),o.click(),document.body.removeChild(o),r&&URL.revokeObjectURL(r))};return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:!0,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--file-attachment","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onDoubleClick:a,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},Ee=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--free-text","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},_e=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!(!t.title&&!t.contents),a=!t.parentType||-1!==["Circle","Ink","Line","Polygon","PolyLine","Square"].indexOf(t.parentType);return h((function(){if(t.parentId){var e=document.querySelector('[data-annotation-id="'.concat(t.parentId,'"]')),n=document.querySelector('[data-annotation-id="'.concat(t.id,'"]'));if(e&&n){var r=parseFloat(e.style.left),o=parseFloat(e.style.top)+parseFloat(e.style.height);n.style.left="".concat(r,"px"),n.style.top="".concat(o,"px"),n.style.transformOrigin="-".concat(r,"px -").concat(o,"px")}}}),[]),c.createElement(ge,{annotation:t,hasPopup:a,ignoreBorder:!1,isRenderable:o,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--popup","data-annotation-id":t.id}),c.createElement(fe,{annotation:t}))}))},ye=function(e){var n=e.annotation,r=e.childAnnotation,o=e.page,a=e.viewport,i=!1===n.hasPopup,l=!!(n.hasPopup||n.title||n.contents);if(n.quadPoints&&n.quadPoints.length>0){var u=n.quadPoints.map((function(e){return Object.assign({},n,{rect:[e[2].x,e[2].y,e[1].x,e[1].y],quadPoints:[]})}));return c.createElement(c.Fragment,null,u.map((function(e,t){return c.createElement(ye,{key:t,annotation:e,childAnnotation:r,page:o,viewport:
1a})})))}return c.createElement(ge,{annotation:n,hasPopup:i,ignoreBorder:!0,isRenderable:l,page:o,viewport:a},(function(e){return c.createElement(c.Fragment,null,c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--highlight","data-annotation-id":n.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children),r&&r.annotationType===t.AnnotationType.Popup&&e.popup.opened&&c.createElement(_e,{annotation:r,page:o,viewport:a}))}))},ke=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--ink","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),t.inkLists&&t.inkLists.length&&c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},t.inkLists.map((function(e,t){return c.createElement("polyline",{key:t,fill:"none",stroke:"transparent",strokeWidth:s||1,points:e.map((function(e){return"".concat(e.x-i[0],",").concat(i[3]-e.y)})).join(" ")})}))),e.slot.children)}))},Ce=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--line","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},c.createElement("line",{stroke:"transparent",strokeWidth:s||1,x1:i[2]-t.lineCoordinates[0],x2:i[2]-t.lineCoordinates[2],y1:i[3]-t.lineCoordinates[1],y2:i[3]-t.lineCoordinates[3]})),e.slot.children)}))},we=/^([^\w]*)(javascript|data|vbscript)/im,Se=/&#(\w+)(^\w|;)?/g,Pe=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,xe=/^([^:]+):/gm,Me=function(e){var t=e.annotation,n=e.doc,r=e.page,o=e.viewport,a=e.onExecuteNamedAction,i=e.onJumpToDest,l=!!(t.url||t.dest||t.action||t.unsafeUrl),u={};if(t.url||t.unsafeUrl){var s=function(e,t){void 0===t&&(t="about:blank");var n,r=(n=e||"",n.replace(Se,(function(e,t){return String.fromCharCode(t)}))).replace(Pe,"").trim();if(!r)return t;var o=r[0];if("."===o||"/"===o)return r;var a=r.match(xe);if(!a)return r;var i=a[0];return we.test(i)?t:r}(t.url||t.unsafeUrl,"");s?u={"data-target":"external",href:s,rel:"noopener noreferrer nofollow",target:t.newWindow?"_blank":"",title:s}:l=!1}else u={href:"","data-annotation-link-dest":t.dest,onClick:function(e){e.preventDefault(),t.action?a(t.action):$(n,t.dest).then((function(e){var t=e.pageIndex,n=e.bottomOffset,r=e.leftOffset,o=e.scaleTo;i(t,n,r,o)}))}};return c.createElement(ge,{annotation:t,hasPopup:!1,ignoreBorder:!1,isRenderable:l,page:r,viewport:o},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--link","data-annotation-id":t.id,"data-testid":"core__annotation--link-".concat(t.id)}),c.createElement("a",p({},u)))}))},Re=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--polygon","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),t.vertices&&t.vertices.length&&c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},c.createElement("polygon",{fill:"none",stroke:"transparent",strokeWidth:s||1,points:t.vertices.map((function(e){return"".concat(e.x-i[0],",").concat(i[3]-e.y)})).join(" ")})),e.slot.children)}))},Le=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--polyline","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),t.vertices&&t.vertices.length&&c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},c.createElement("polyline",{fill:"none",stroke:"transparent",strokeWidth:s||1,points:t.vertices.map((function(e){return"".concat(e.x-i[0],",").concat(i[3]-e.y)})).join(" ")})),e.slot.children)}))},Te=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents),i=t.rect,l=i[2]-i[0],u=i[3]-i[1],s=t.borderStyle.width;return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--square","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),c.createElement("svg",{height:"".concat(u,"px"),preserveAspectRatio:"none",version:"1.1",viewBox:"0 0 ".concat(l," ").concat(u),width:"".concat(l,"px")},c.createElement("rect",{height:u-s,fill:"none",stroke:"transparent",strokeWidth:s||1,x:s/2,y:s/2,width:l-s})),e.slot.children)}))},Oe=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--squiggly","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},Ie=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--stamp","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},De=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--strike-out","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},Ne=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M.5,16.5a1,1,0,0,0,1,1h2v4l4-4h15a1,1,0,0,0,1-1V3.5a1,1,0,0,0-1-1H1.5a1,1,0,0,0-1,1Z"}),c.createElement("path",{d:"M7.25,9.75A.25.25,0,1,1,7,10a.25.25,0,0,1,.25-.25"}),c.createElement("path",{d:"M12,9.75a.25.25,0,1,1-.25.25A.25.25,0,0,1,12,9.75"}),c.createElement("path",{d:"M16.75,9.75a.25.25,0,1,1-.25.25.25.25,0,0,1,.25-.25"}))},ze=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M0.500 12.001 A11.500 11.500 0 1 0 23.500 12.001 A11.500 11.500 0 1 0 0.500 12.001 Z"}),c.createElement("path",{d:"M6.000 12.001 A6.000 6.000 0 1 0 18.000 12.001 A6.000 6.000 0 1 0 6.000 12.001 Z"}),c.createElement("path",{d:"M21.423 5.406L17.415 9.414"}),c.createElement("path",{d:"M14.587 6.585L18.607 2.565"}),c.createElement("path",{d:"M5.405 21.424L9.413 17.416"}),c.createElement("path",{d:"M6.585 14.588L2.577 18.596"}),c.createElement("path",{d:"M18.602 21.419L14.595 17.412"}),c.createElement("path",{d:"M17.419 14.58L21.428 18.589"}),c.createElement("path",{d:"M2.582 5.399L6.588 9.406"}),c.createElement("path",{d:"M9.421 6.581L5.412 2.572"}))},Fe=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M4.000 18.500 A1.500 1.500 0 1 0 7.000 18.500 A1.500 1.500 0 1 0 4.000 18.500 Z"}),c.createElement("path",{d:"M20.5.5l-9.782,9.783a7,7,0,1,0,3,3L17,10h1.5V8.5L19,8h1.5V6.5L21,6h1.5V4.5l1-1V.5Z"}))},je=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M2.000 2.500 L22.000 2.500 L22.000 23.500 L2.000 23.500 Z"}),c.createElement("path",{d:"M6 4.5L6 0.5"}),c.createElement("path",{d:"M18 4.5L18 0.5"}),c.createElement("path",{d:"M10 4.5L10 0.5"}),c.createElement("path",{d:"M14 4.5L14 0.5"}))},Be=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M17.5 0.498L17.5 23.498"}),c.createElement("path",{d:"M10.5 0.498L10.5 23.498"}),c.createElement("path",{d:"M23.5.5H6.5a6,6,0,0,0,0,12h4"}))},Ae=function(){return c.createElement(b,{size:16},c.createElement("path",{d:"M2.5 22.995L12 6.005 21.5 22.995 2.5 22.995z"}))},He=function(e){var n=e.annotation,r=e.childAnnotation,o=e.page,a=e.viewport,i=!1===n.hasPopup,l=!!(n.hasPopup||n.title||n.contents),u=n.name?n.name.toLowerCase():"";return c.createElement(ge,{annotation:n,hasPopup:i,ignoreBorder:!1,isRenderable:l,page:o,viewport:
1a},(function(e){return c.createElement(c.Fragment,null,c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--text","data-annotation-id":n.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),u&&c.createElement("div",{className:"rpv-core__annotation-text-icon"},"check"===u&&c.createElement(E,null),"comment"===u&&c.createElement(Ne,null),"help"===u&&c.createElement(ze,null),"insert"===u&&c.createElement(Ae,null),"key"===u&&c.createElement(Fe,null),"note"===u&&c.createElement(je,null),("newparagraph"===u||"paragraph"===u)&&c.createElement(Be,null)),e.slot.children),r&&r.annotationType===t.AnnotationType.Popup&&e.popup.opened&&c.createElement(_e,{annotation:r,page:o,viewport:a}))}))},Ve=function(e){var t=e.annotation,n=e.page,r=e.viewport,o=!1===t.hasPopup,a=!!(t.hasPopup||t.title||t.contents);return c.createElement(ge,{annotation:t,hasPopup:o,ignoreBorder:!0,isRenderable:a,page:n,viewport:r},(function(e){return c.createElement("div",p({},e.slot.attrs,{className:"rpv-core__annotation rpv-core__annotation--underline","data-annotation-id":t.id,onClick:e.popup.toggleOnClick,onMouseEnter:e.popup.openOnHover,onMouseLeave:e.popup.closeOnHover}),e.slot.children)}))},We=function(e){var n=e.annotations,r=e.doc,o=e.page,a=e.pageIndex,i=e.plugins,l=e.rotation,u=e.scale,s=e.onExecuteNamedAction,d=e.onJumpToDest,p=c.useRef(),f=o.getViewport({rotation:l,scale:u}).clone({dontFlip:!0}),m=n.filter((function(e){return!e.parentId}));return h((function(){var e=p.current;e&&i.forEach((function(t){t.onAnnotationLayerRender&&t.onAnnotationLayerRender({annotations:m,container:e,pageIndex:a,rotation:l,scale:u})}))}),[]),c.createElement("div",{ref:p,className:"rpv-core__annotation-layer","data-testid":"core__annotation-layer-".concat(a)},m.map((function(e){var a=n.find((function(t){return t.parentId===e.id}));switch(e.annotationType){case t.AnnotationType.Caret:return c.createElement(he,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Circle:return c.createElement(ve,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.FileAttachment:return c.createElement(be,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.FreeText:return c.createElement(Ee,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Highlight:return c.createElement(ye,{key:e.id,annotation:e,childAnnotation:a,page:o,viewport:f});case t.AnnotationType.Ink:return c.createElement(ke,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Line:return c.createElement(Ce,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Link:return c.createElement(Me,{key:e.id,annotation:e,doc:r,page:o,viewport:f,onExecuteNamedAction:s,onJumpToDest:d});case t.AnnotationType.Polygon:return c.createElement(Re,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Polyline:return c.createElement(Le,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Popup:return c.createElement(_e,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Square:return c.createElement(Te,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Squiggly:return c.createElement(Oe,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Stamp:return c.createElement(Ie,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.StrikeOut:return c.createElement(De,{key:e.id,annotation:e,page:o,viewport:f});case t.AnnotationType.Text:return c.createElement(He,{key:e.id,annotation:e,childAnnotation:a,page:o,viewport:f});case t.AnnotationType.Underline:return c.createElement(Ve,{key:e.id,annotation:e,page:o,viewport:f});default:return c.createElement(c.Fragment,{key:e.id})}})))},Ue=function(e){var t=e.page,n=e.renderAnnotations,r=C(),o=c.useState({loading:!0,annotations:[]}),a=o[0],i=o[1];return c.useEffect((function(){t.getAnnotations({intent:"display"}).then((function(e){r.current&&i({loading:!1,annotations:e})}))}),[]),a.loading?c.createElement(c.Fragment,null):n(a.annotations)},Ze=function(e){var t=e.doc,n=e.page,r=e.pageIndex,o=e.plugins,a=e.rotation,i=e.scale,l=e.onExecuteNamedAction,u=e.onJumpToDest;return c.createElement(Ue,{page:n,renderAnnotations:function(e){return c.createElement(We,{annotations:e,doc:t,page:n,pageIndex:r,plugins:o,rotation:a,scale:i,onExecuteNamedAction:l,onJumpToDest:u})}})},Ke=function(e,t){var n=e%t;return 0===n?e:Math.floor(e-n)},Ge=function(e){var n=e.height,r=e.page,o=e.pageIndex,a=e.plugins,i=e.rotation,l=e.scale,u=e.width,s=e.onRenderCanvasCompleted,d=c.useRef(),p=c.useRef();return h((function(){var e=p.current;e&&e.cancel();var n=d.current;a.forEach((function(e){e.onCanvasLayerRender&&e.onCanvasLayerRender({ele:n,pageIndex:o,rotation:i,scale:l,status:t.LayerRenderStatus.PreRender})}));var c=r.getViewport({rotation:i,scale:l}),u=window.devicePixelRatio||1,f=Math.sqrt(16777216/(c.width*c.height)),m=u>f;m?n.style.transform="scale(1, 1)":n.style.removeProperty("transform");var g=Math.min(f,u),h=function(e,t){var n,r;if(Math.floor(e)===e)return[e,1];var o=1/e;if(o>8)return[1,8];if(Math.floor(o)===o)return[1,o];for(var a=e>1?o:e,i=0,c=1,l=1,u=1;;){var s=i+l,d=c+u;if(d>8)break;a<=s/d?(l=(n=[s,d])[0],u=n[1]):(i=(r=[s,d])[0],c=r[1])}return a<(i/c+l/u)/2?a===e?[i,c]:[c,i]:a===e?[l,u]:[u,l]}(g),v=h[0],b=h[1];n.width=Ke(c.width*g,v),n.height=Ke(c.height*g,v),n.style.width="".concat(Ke(c.width,b),"px"),n.style.height="".concat(Ke(c.height,b),"px"),n.hidden=!0;var E=n.getContext("2d",{alpha:!1}),_=m||1!==u?[g,0,0,g,0,0]:null;return p.current=r.render({canvasContext:E,transform:_,viewport:c}),p.current.promise.then((function(){n.hidden=!1,a.forEach((function(e){e.onCanvasLayerRender&&e.onCanvasLayerRender({ele:n,pageIndex:o,rotation:i,scale:l,status:t.LayerRenderStatus.DidRender})})),s()}),(function(){s()})),function(){n&&(n.width=0,n.height=0)}}
1),[]),c.createElement("div",{className:"rpv-core__canvas-layer",style:{height:"".concat(n,"px"),width:"".concat(u,"px")}},c.createElement("canvas",{ref:d}))},qe=function(e){var t=e.height,n=e.page,r=e.rotation,o=e.scale,a=e.width,i=c.useRef();return h((function(){var e=i.current,c=n.getViewport({rotation:r,scale:o});n.getOperatorList().then((function(r){!function(){var e=i.current;e&&(e.innerHTML="")}(),new l.SVGGraphics(n.commonObjs,n.objs).getSVG(r,c).then((function(n){n.style.height="".concat(t,"px"),n.style.width="".concat(a,"px"),e.appendChild(n)}))}))}),[]),c.createElement("div",{className:"rpv-core__svg-layer",ref:i})},Je=function(e){var n=e.page,r=e.pageIndex,o=e.plugins,a=e.rotation,i=e.scale,u=e.onRenderTextCompleted,s=c.useRef(),d=c.useRef(),p=function(){var e=s.current;e&&([].slice.call(e.querySelectorAll(".rpv-core__text-layer-text")).forEach((function(t){return e.removeChild(t)})),[].slice.call(e.querySelectorAll('br[role="presentation"]')).forEach((function(t){return e.removeChild(t)})))};return h((function(){var e=d.current;e&&e.cancel();var c=s.current;if(c){c.removeAttribute("data-testid");var f=n.getViewport({rotation:a,scale:i});return o.forEach((function(e){e.onTextLayerRender&&e.onTextLayerRender({ele:c,pageIndex:r,scale:i,status:t.LayerRenderStatus.PreRender})})),n.getTextContent().then((function(e){p(),d.current=l.renderTextLayer({container:c,textContent:e,viewport:f,enhanceTextSelection:!0}
1),d.current.promise.then((function(){c.setAttribute("data-testid","core__text-layer-".concat(r)),[].slice.call(c.children).forEach((function(e){e.classList.contains("rpv-core__text-layer-text--not")||e.classList.add("rpv-core__text-layer-text")})),o.forEach((function(e){e.onTextLayerRender&&e.onTextLayerRender({ele:c,pageIndex:r,scale:i,status:t.LayerRenderStatus.DidRender})})),u()}),(function(){c.removeAttribute("data-testid"),u()}))})),function(){var e;p(),null===(e=d.current)||void 0===e||e.cancel()}}}),[]),c.createElement("div",{className:"rpv-core__text-layer",ref:s})},Ye=function(e){var t=e.doc,n=e.height,r=e.measureRef,o=e.pageIndex,a=e.pageRotation,i=e.plugins,l=e.renderPage,u=e.renderQueueKey,s=e.rotation,d=e.scale,p=e.shouldRender,f=e.width,m=e.onExecuteNamedAction,g=e.onJumpToDest,h=e.onRenderCompleted,v=e.onRotatePage,b=C(),E=c.useState({page:null,pageHeight:n,pageWidth:f,viewportRotation:0}),_=E[0],k=E[1],w=c.useState(!1),S=w[0],P=w[1],x=c.useState(!1),M=x[0],R=x[1],L=_.page,T=_.pageHeight,O=_.pageWidth,I=Math.abs(s+a)%180==0,D=O*d,N=T*d,z=I?D:N,F=I?N:D,j=(_.viewportRotation+s+a)%360,B=c.useRef(0),A=l||function(e){return c.createElement(c.Fragment,null,e.canvasLayer.children,e.textLayer.children,e.annotationLayer.children)};return c.useEffect((function(){k({page:null,pageHeight:n,pageWidth:f,viewportRotation:0}),P(!1),R(!1)}),[a,s,d]),c.useEffect((function(){p&&b.current&&!L&&X(t,o).then((function(e){var t=e.getViewport({scale:1});b.current&&(B.current=u,k({page:e,pageHeight:t.height,pageWidth:t.width,viewportRotation:t.rotation}))}
1))}),[p,L]),c.useEffect((function(){S&&M&&(u!==B.current?(k({page:null,pageHeight:n,pageWidth:f,viewportRotation:0}),P(!1),R(!1)):h(o))}),[S,M]),c.createElement("div",{className:"rpv-core__page-layer","data-testid":"core__page-layer-".concat(o),ref:r,style:{height:"".concat(F,"px"),width:"".concat(z,"px")}},L?c.createElement(c.Fragment,null,A({annotationLayer:{attrs:{},children:c.createElement(Ze,{doc:t,page:L,pageIndex:o,plugins:i,rotation:j,scale:d,onExecuteNamedAction:m,onJumpToDest:g})},canvasLayer:{attrs:{},children:c.createElement(Ge,{height:F,page:L,pageIndex:o,plugins:i,rotation:j,scale:d,width:z,onRenderCanvasCompleted:function(){b.current&&P(!0)}})},canvasLayerRendered:S,doc:t,height:F,pageIndex:o,rotation:j,scale:d,svgLayer:{attrs:{},children:c.createElement(qe,{height:F,page:L,rotation:j,scale:d,width:z})},textLayer:{attrs:{},children:c.createElement(Je,{page:L,pageIndex:o,plugins:i,rotation:j,scale:d,onRenderTextCompleted:function(){b.current&&R(!0)}})},textLayerRendered:M,width:z,markRendered:h,onRotatePage:function(e){return v(o,e)}}),i.map((function(e,n){return e.renderPageLayer?c.createElement(c.Fragment,{key:n},e.renderPageLayer({doc:t,height:F,pageIndex:o,rotation:j,scale:d,width:z})):c.createElement(c.Fragment,{key:n})}))):c.createElement(y,{testId:"core__page-layer-loading-".concat(o)}))},Qe=function(e,n,r,o){switch(o){case t.SpecialZoomLevel.ActualSize:return 1;case t.SpecialZoomLevel.PageFit:return Math.min((e.clientWidth-17)/r,(e.clientHeight-16)/n);case t.SpecialZoomLevel.PageWidth:return(e.clientWidth-17)/r}},Xe=function(e){var n=e.currentFile,r=e.defaultScale,o=e.doc,a=e.initialPage,i=e.pageSize,l=e.plugins,u=e.renderPage,s=e.scrollMode,d=e.viewerState,f=e.onDocumentLoad,v=e.onOpenFile,b=e.onPageChange,E=e.onRotate,_=e.onRotatePage,y=e.onZoom,k=o.numPages,C=o.loadingTask.docId,w=c.useContext(x).l10n,P=c.useContext(m),M=P.direction===t.TextDirection.RightToLeft,R=c.useRef(),L=c.useRef(),T=c.useState(a),O=T[0],I=T[1],D=c.useRef(null),N=c.useState(0),z=N[0],F=N[1],j=c.useState(!1),B=j[0],A=j[1],H=c.useState(new Map),V=H[0],W=H[1],U=c.useState(s),Z=U[0],K=U[1],G=ee(Z),Y=c.useState(i.scale),Q=Y[0],$=Y[1],te=c.useRef(d),ne=c.useRef("string"==typeof r?r:null),re=c.useState(-1),oe=re[0],ae=re[1],ie=c.useState(0),ce=ie[0],le=ie[1],se=S({doc:o});c.useEffect((function(){return function(){q.clear(),J.clear()}}),[C]);var de,pe,fe,me=c.useCallback((function(){var e=[i.pageHeight,i.pageWidth],t=Math.abs(z)%180==0?{height:e[0],width:e[1]}:{height:e[1],width:e[0]};return{height:t.height*Q,width:t.width*Q}}),[z,Q]),ge=c.useCallback((function(e){return Math.max(e-3,0)}),[]),he=c.useCallback((function(e){return Math.min(e+3,k-1)}),[k]),ve=c.useCallback((function(e){return e}),[]),be=ue({estimateSize:me,isRtl:M,numberOfItems:k,parentRef:L,scrollMode:Z,setStartRange:ge,setEndRange:he,transformSize:ve}),Ee=(de=function(e){ne.current&&(ae(-1),Te(ne.current))},200,pe=c.useRef(),fe=function(){pe.current&&clearTimeout(pe.current)},c.useEffect((function(){return function(){return fe()}}),[]),c.useCallback((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];fe(),pe.current=setTimeout((function(){de.apply(void 0,e)}),200)}),[de,200]));!function(e){var t=e.targetRef,n=e.onResize;h((function(){var e=new ResizeObserver((function(e){e.forEach((function(e){n(e.target)}))})),r=t.current;if(r)return e.observe(r),function(){e.unobserve(r)}}),[])}({targetRef:L,onResize:Ee});var _e=i.pageWidth,ye=i.pageHeight,ke=function(e){var t=e;l.forEach((function(e){e.onViewerStateChange&&(t=e.onViewerStateChange(t))})),te.current=t},Ce=function(){return L.current},we=function(){return te.current},Se=c.useCallback((function(e,n,r,a){var i=L.current,c=te.current;i&&c&&X(o,e).then((function(o){var l=o.getViewport({scale:1}),u=0,s=("function"==typeof n?n(l.width,l.height):n)||0,d=("function"==typeof r?r(l.width,l.height):r)||0,p=c.scale;switch(a){case t.SpecialZoomLevel.PageFit:u=0,d=0,Te(t.SpecialZoomLevel.PageFit);break;case t.SpecialZoomLevel.PageWidth:p=Qe(i,ye,_e,t.SpecialZoomLevel.PageWidth),u=(l.height-s)*p,d*=p,Te(p);break;default:var f=l.convertToViewportPoint(d,s);d=Math.max(f[0]*c.scale,0),u=Math.max(f[1]*c.scale,0)}switch(c.scrollMode){case t.ScrollMode.Horizontal:be.scrollToItem(e,{left
1:d,top:0});break;case t.ScrollMode.Vertical:default:be.scrollToItem(e,{left:0,top:u})}}))}),[]),Pe=c.useCallback((function(e){0<=e&&e<k&&be.scrollToItem(e,{left:0,top:0})}),[]),xe=c.useCallback((function(e){var t,n;"pdf"===(t=e.name,n=t.split(/\./).pop(),n?n.toLowerCase():"").toLowerCase()&&new Promise((function(t){var n=new FileReader;n.readAsArrayBuffer(e),n.onload=function(){var e=new Uint8Array(n.result);t(e)}})).then((function(t){v(e.name,t)}))}),[v]),Me=c.useCallback((function(e){var n=e===t.RotateDirection.Backward?-90:90,r=te.current.rotation,a=360===r||-360===r?n:r+n;se.markNotRendered(),F(a),ke(p(p({},te.current),{rotation:a})),E({direction:e,doc:o,rotation:a})}),[]),Re=c.useCallback((function(e,n){var r=n===t.RotateDirection.Backward?-90:90,a=te.current.pagesRotation,i=(a.has(e)?a.get(e):0)+r,c=a.set(e,i);W(c),A((function(e){return!e})),ke(p(p({},te.current),{pagesRotation:c,rotatedPage:e})),_({direction:n,doc:o,pageIndex:e,rotation:i}),se.markRendering(e),ae(e)}),[]),Le=c.useCallback((function(e){ke(p(p({},te.current),{scrollMode:e})),K(e)}),[]),Te=c.useCallback((function(e){var t=L.current,n=t?"string"==typeof e?Qe(t,ye,_e,e):e:1;ne.current="string"==typeof e?e:null,n!==te.current.scale&&(be.zoom(n/te.current.scale),le((function(e){return e+1})),se.markNotRendered(),$(n),y({doc:o,scale:n}),ke(p(p({},te.current),{scale:n})))}),[]);c.useEffect((function(){var e={getPagesContainer:Ce,getViewerState:we,jumpToDestination:Se,jumpToPage:Pe,openFile:xe,rotate:Me,rotatePage:Re,setViewerState:ke,switchScrollMode:Le,zoom:Te};return l.forEach((function(t){t.install&&t.install(e)})),function(){l.forEach((function(t){t.uninstall&&t.uninstall(e)}))}}),[C]),c.useEffect((function(){f({doc:o,file:n}),l.forEach((function(e){e.onDocumentLoad&&e.onDocumentLoad({doc:o,file:n})})),a&&Pe(a)}),[C]),h((function(){var e=te.current.pageIndex;e>
1-1&&G!==Z&&be.scrollToItem(e,{left:0,top:0})}),[Z]),c.useEffect((function(){be.isSmoothScrolling||null!==D.current&&D.current===O||(D.current=O,b({currentPage:O,doc:o}))}),[O,be.isSmoothScrolling]),c.useEffect((function(){var e=be.startRange,t=be.endRange,n=be.maxVisbilityIndex,r=be.virtualItems,o=n;I(o),ke(p(p({},te.current),{pageIndex:o})),se.setRange(e,t);for(var a=function(e){var t=r.find((function(t){return t.index===e}));t&&se.setVisibility(e,t.visibility)},i=e;i<=t;i++)a(i);Ie()}),[be.startRange,be.endRange,be.maxVisbilityIndex,B,z,Q]);var Oe=c.useCallback((function(e){se.markRendered(e),Ie()}),[ce]),Ie=function(){var e=se.getHighestPriorityPage();e>-1&&se.isInRange(e)&&(se.markRendering(e),ae(e))},De=function(e){var t=O-1,n=O+1;switch(e){case"FirstPage":Pe(0);break;case"LastPage":Pe(k-1);break;case"NextPage":n<k&&Pe(n);break;case"PrevPage":t>=0&&Pe(t)}},Ne=c.useCallback((function(){var e=w&&w.core?w.core.pageLabel:"Page {{pageIndex}}",n={attrs:{"data-testid":"core__inner-container",ref:R,style:{height:"100%"}},children:c.createElement(c.Fragment,null),subSlot:{attrs:{"data-testid":"core__inner-pages",className:g({"rpv-core__inner-pages":!0,"rpv-core__inner-pages--horizontal":Z===t.ScrollMode.Horizontal,"rpv-core__inner-pages--rtl":M,"rpv-core__inner-pages--vertical":Z===t.ScrollMode.Vertical,"rpv-core__inner-pages--wrapped":Z===t.ScrollMode.Wrapped}),ref:L,style:{height:"100%",overflow:"auto",position:"relative"}},children:c.createElement("div",{style:be.getContainerStyles()},be.virtualItems.map((function(t){return c.createElement("div",{"aria-label":e.replace("{{pageIndex}}","".concat(t.index+1)),className:"rpv-core__inner-page",key:t.index,role:"region",style:be.getItemStyles(t)},c.createElement(Ye,{doc:o,height:ye,measureRef:t.measureRef,pageIndex:t.index,pageRotation:V.has(t.index)?V.get(t.index):0,plugins:l,renderPage:u,renderQueueKey:ce,rotation:z,scale:Q,shouldRender:oe===t.index,width:_e,onExecuteNamedAction:De,onJumpToDest:Se,onRenderCompleted:Oe,onRotatePage:Re}))})))}};return l.forEach((function(e){e.renderViewer&&(n=e.renderViewer({containerRef:R,doc:o,pageHeight:ye,pageWidth:_e,pagesRotation:V,rotation:z,slot:n,themeContext:P,jumpToPage:Pe,openFile:xe,rotate:Me,rotatePage:Re,switchScrollMode:Le,zoom:Te}))})),n}),[l,be]),ze=c.useCallback((function(e){return c.createElement("div",p({},e.attrs,{style:e.attrs&&e.attrs.style?e.attrs.style:{}}),e.children,e.subSlot&&ze(e.subSlot))}),[]);return ze(Ne())},$e=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1,1.1,1.3,1.5,1.7,1.9,2.1,2.4,2.7,3,3.3,3.7,4.1,4.6,5.1,5.7,6.3,7,7.7,8.5,9.4,10],et=function(e){var n=e.defaultScale,r=e.doc,o=e.render,a=e.scrollMode,i=c.useRef(),l=c.useState({pageHeight:0,pageWidth:0,scale:1}),u=l[0],s=l[1];return c.useLayoutEffect((function(){X(r,0).then((function(e){var r=e.getViewport({scale:1}),o=r.width,c=r.height,l=i.current;if(l){var u=l.parentElement,d=(u.clientWidth-45)/o,p=(u.clientHeight-45)/c,f=d;switch(a){case t.ScrollMode.Horizontal:f=Math.min(d,p);break;case t.ScrollMode.Vertical:default:f=d}var m,g,h=n?"string"==typeof n?Qe(u,c,o,n):n:(m=f,-1===(g=$e.findIndex((function(e){return e>=m})))||0===g?m:$e[g-1]);s({pageHeight:c,pageWidth:o,scale:h})}}))}),[r]),0===u.pageWidth?c.createElement("div",{className:"rpv-core__page-size-calculator","data-testid":"core__page-size-calculating",ref:i},c.createElement(y,null)):o(u)},tt=function(){};!function(e){e[e.REQUIRE_PASSWORD=0]="REQUIRE_PASSWORD",e[e.WRONG_PASSWORD=1]="WRONG_PASSWORD"}(me||(me={}));var nt=function(e){function t(t,n){var r=e.call(this)||this;return r.verifyPassword=t,r.submitPassword=n,r}return s(t,e),t}(tt),rt=function(e){var n=e.submitPassword,r=e.verifyPassword,o=e.onDocumentAskPassword,a=c.useContext(x).l10n,i=c.useState(""),l=i[0],u=i[1],s=c.useContext(m).direction===t.TextDirection.RightToLeft,d=function(){return r(l)};return c.useEffect((function(){o&&o({verifyPassword:r})}),[]),c.createElement("div",{className:"rpv-core__asking-password-wrapper"},c.createElement("div",{className:g({"rpv-core__asking-password":!0,"rpv-core__asking-password--rtl":s})},c.createElement("div",{className:"rpv-core__asking-password-message"},n===me.REQUIRE_PASSWORD&&a.core.askingPassword.requirePasswordToOpen,n===me.WRONG_PASSWORD&&a.core.wrongPassword.tryAgain),c.createElement("div",{className:"rpv-core__asking-password-body"},c.createElement("div",{className:g({"rpv-core__asking-password-input":!0,"rpv-core__asking-password-input--ltr":!s,"rpv-core__asking-password-input--rtl":s})},c.createElement(k,{testId:"core__asking-password-input",type:"password",value:l,onCh
1ange:u,onKeyDown:function(e){"Enter"===e.key&&d()}})),c.createElement(_,{onClick:d},a.core.askingPassword.submit))))},ot=function(e){function t(t){var n=e.call(this)||this;return n.doc=t,n}return s(t,e),t}(tt),at=function(e){function t(t){var n=e.call(this)||this;return n.error=t,n}return s(t,e),t}(tt),it=function(e){function t(t){var n=e.call(this)||this;return n.percentages=t,n}return s(t,e),t}(tt),ct=function(e){var n=e.characterMap,r=e.file,o=e.httpHeaders,a=e.render,i=e.renderError,u=e.renderLoader,s=e.transformGetDocumentParams,d=e.withCredentials,p=e.onDocumentAskPassword,f=c.useContext(m).direction===t.TextDirection.RightToLeft,h=c.useState(new it(0)),v=h[0],b=h[1],E=c.useState(0);E[0],E[1];var _=c.useRef(""),k=c.useState(null);k[0],k[1];var w=C();return c.useEffect((function(){_.current="",b(new it(0));var e=new l.PDFWorker({name:"PDFWorker_".concat(Date.now())}),t=Object.assign({httpHeaders:o,withCredentials:d,worker:e},"string"==typeof r?{url:r}:{data:r},n?{cMapUrl:n.url,cMapPacked:n.isCompressed}:{}),a=s?s(t):t,i=l.getDocument(a);return i.onPassword=function(e,t){switch(t){case l.PasswordResponses.NEED_PASSWORD:w.current&&b(new nt(e,me.REQUIRE_PASSWORD));break;case l.PasswordResponses.INCORRECT_PASSWORD:w.current&&b(new nt(e,me.WRONG_PASSWORD))}},i.onProgress=function(e){var t=e.total>0?Math.min(100,100*e.loaded/e.total):100;w.current&&""===_.current&&b(new it(t))},i.promise.then((function(e){_.current=e.loadingTask.docId,w.current&&b(new ot(e))}),(function(t){return w.current&&!e.destroyed&&b(new at({message:t.message||"Cannot load document",name:t.name}))})),function(){i.destroy(),e.destroy()}}),[r]),v instanceof nt?c.createElement(rt,{submitPassword:v.submitPassword,verifyPassword:v.verifyPassword,onDocumentAskPassword:p}):v instanceof ot?a(v.doc):v instanceof at?i?i(v.error):c.createElement("div",{className:g({"rpv-core__doc-error":!0,"rpv-core__doc-error--rtl":f})},c.createElement("div",{className:"rpv-core__doc-error-text"},v.error.message)):c.createElement("div",{"data-testid":"core__doc-loading",className:g({"rpv-core__doc-loading":!0,"rpv-core__doc-loading--rtl":f})},u?u(v.percentages):c.createElement(y,null))};t.Button=function(e){var n=e.children,r=e.testId,o=e.onClick,a=c.useContext(m).direction===t.TextDirection.RightToLeft,i=r?{"data-testid":r}:{};return c.createElement("button",p({className:g({"rpv-core__button":!0,"rpv-core__button--rtl":a}),type:"button",onClick:o},i),n)},t.Icon=b,t.LazyRender=function(e){var t=e.attrs,n=e.children,r=e.testId,o=c.useState(!1),a=o[0],i=o[1],l=r?p(p({},t),{"data-testid":r}):t,u=v({once:!0,onVisibilityChanged:function(e){e.isVisible&&i(!0)}});return c.createElement("div",p({ref:u},l),a&&n)},t.LocalizationContext=x,t.Menu=function(e){var n=e.children,r=c.useRef(),o=c.useRef([]),a=c.useContext(m).direction===t.TextDirection.RightToLeft,i=function(e){if(r.current)switch(e.key){case"Tab":e.preventDefault();break;case"ArrowDown":e.preventDefault(),l((function(e,t){return t+1}));break;case"ArrowUp":e.preventDefault(),l((function(e,t){return t-1}));break;case"End":e.preventDefault(),l((function(e,t){return e.length-1}));break;case"Home":e.preventDefault(),l((function(e,t){return 0}))}},l=function(e){if(r.current){var t=o.current,n=t.findIndex((function(e){return"0"===e.getAttribute("tabindex")})),a=Math.min(t.length-1,Math.max(0,e(t,n)));n>=0&&n<=t.length-1&&t[n].setAttribute("tabindex","-1"),t[a].setAttribute("tabindex","0"),t[a].focus()}};return h((function(){var e=r.current;if(e){var t=function(e){var t=[];return e.querySelectorAll('.rpv-core__menu-item[role="menuitem"]').forEach((function(n){if(n instanceof HTMLElement){var r=n.parentElement;(r===e||"none"!==window.getComputedStyle(r).display)&&t.push(n)}})),t}(e);o.current=t}}),[]),h((function(){return document.addEventListener("keydown",i),function(){document.removeEventListener("keydown",i)}}),[]),c.createElement("div",{ref:r,"aria-orientation":"vertical",className:g({"rpv-core__menu":!0,"rpv-core__menu--rtl":a}),role:"menu",tabIndex:0},n)},t.MenuDivider=function(){return c.createElement("div",{"aria-orientation":"horizontal",className:"rpv-core__menu-divider",role:"separator"})},t.MenuItem=function(e){var n=e.checked,r=void 0!==n&&n,o=e.children,a=e.icon,i=void 0===a?null:a,l=e.isDisabled,u=void 0!==l&&l,s=e.testId,d=e.onClick,f=c.useContext(m).direction===t.TextDirection.RightToLeft,h=s?{"data-testid":s}:{};return c.createElement("button",p({className:g({"rpv-core__menu-item":!0,"rpv-core__menu-item--disabled":u,"rpv-core__menu-item--ltr":!f,"rpv-core__menu-item--rtl":f}),role:"menuitem",tabIndex:-1,type:"button",onClick:d},h),c.createElement("div",{className:g({"rpv-core__menu-item-icon":!0,"rpv-core__menu-item-icon--ltr":!f,"rpv-core__menu-item-icon--rtl":f})},i),c.createElement("div",{className:g({"rpv-core__menu-item-label":!0,"rpv-core__menu-item-label--ltr":!f,"rpv-core__menu-item-label--rtl":f})},o),c.createElement("div",{className:g({"rpv-core__menu-item-check":!0,"rpv-core__menu-item-check--ltr":!f,"rpv-core__menu-item-check--rtl":f})},r&&c.createElement(E,null)))},t.MinimalButton=function(e){var n=e.ariaLabel,r=void 0===n?"":n,o=e.ariaKeyShortcuts,a=void 0===o?"":o,i=e.children,l=e.isDisabled,u=void 0!==l&&l,s=e.isSelected,d=void 0!==s&&s,f=e.testId,h=e.onClick,v=c.useContext(m).direction===t.TextDirection.RightToLeft,b=f?{"data-testid":f}:{};return c.createElement("button",p({"aria-label":r},a&&{"aria-keyshortcuts":a},u&&{"aria-disabled":!0},{className:g({"rpv-core__minimal-button":!0,"rpv-core__minimal-button--disabled":u,"rpv-core__minimal-button--rtl":v,"rpv-core__minimal-button--selected":d}),type:"button",onClick:h},b),i)}
1,t.Modal=function(e){var t=e.ariaControlsSuffix,n=e.closeOnClickOutside,r=e.closeOnEscape,o=e.content,a=e.isOpened,i=void 0!==a&&a,l=e.target,u=t||"".concat(R());return c.createElement(z,{target:l?function(e,t){return c.createElement("div",{"aria-expanded":t?"true":"false","aria-haspopup":"dialog","aria-controls":"rpv-core__modal-body-".concat(u)},l(e,t))}:null,content:function(e){return c.createElement(I,null,c.createElement(O,{ariaControlsSuffix:u,closeOnClickOutside:n,closeOnEscape:r,onToggle:e},o(e)))},isOpened:i})},t.Popover=function(e){var t=e.ariaHasPopup,n=void 0===t?"dialog":t,r=e.ariaControlsSuffix,o=e.closeOnClickOutside,a=e.closeOnEscape,i=e.content,l=e.lockScroll,u=void 0===l||l,s=e.offset,d=e.position,p=e.target,f=N(!1),m=f.opened,g=f.toggle,h=c.useRef(),v=c.useMemo((function(){return r||"".concat(R())}),[]);return c.createElement("div",{ref:h,"aria-expanded":m?"true":"false","aria-haspopup":n,"aria-controls":"rpv-core__popver-body-".concat(v)},p(g,m),m&&c.createElement(c.Fragment,null,u&&c.createElement(Z,{closeOnEscape:a,onClose:g}),c.createElement(U,{ariaControlsSuffix:v,closeOnClickOutside:o,offset:s,position:d,targetRef:h,onClose:g},i(g))))},t.PrimaryButton=_,t.ProgressBar=function(e){var n=e.progress,r=c.useContext(m).direction===t.TextDirection.RightToLeft;return c.createElement("div",{className:g({"rpv-core__progress-bar":!0,"rpv-core__progress-bar--rtl":r})},c.createElement("div",{className:"rpv-core__progress-bar-progress",style:{width:"".concat(n,"%")}},n,"%"))},t.Separator=function(){return c.createElement("div",{className:"rpv-core__separator"})},t.Spinner=y,t.Splitter=function(e){var n=e.constrain,r=c.useContext(m).direction===t.TextDirection.RightToLeft,o=c.useRef(),a=c.useRef(),i=c.useRef(),l=c.useRef(0),u=c.useRef(0),s=c.useRef(0),d=c.useRef(0),p={capture:!0},f=function(e){var t=o.current,c=a.current,u=i.current;if(t&&c&&u){var p=d.current,f=e.clientX-l.current,m=s.current+(r?-f:f),g=t.parentElement.getBoundingClientRect().width,h=100*m/g;if(t.classList.add("rpv-core__splitter--resizing"),n){var v=g-m-p;if(!n({firstHalfPercentage:h,firstHalfSize:m,secondHalfPercentage:100*v/g,secondHalfSize:v}))return}c.style.width="".concat(h,"%"),document.body.classList.add("rpv-core__splitter-body--resizing"),c.classList.add("rpv-core__splitter-sibling--resizing"),u.classList.add("rpv-core__splitter-sibling--resizing")}},g=function(e){var t=o.current,n=a.current,r=i.current;t&&n&&r&&(document.body.classList.remove("rpv-core__splitter-body--resizing"),t.classList.remove("rpv-core__splitter--resizing"),n.classList.remove("rpv-core__splitter-sibling--resizing"),r.classList.remove("rpv-core__splitter-sibling--resizing"),document.removeEventListener("mousemove",f,p),document.removeEventListener("mouseup",g,p))};return c.useEffect((function(){var e=o.current;e&&(d.current=e.getBoundingClientRect().width,a.current=e.previousElementSibling,i.current=e.nextElementSibling)}),[]),c.createElement("div",{ref:o,className:"rpv-core__splitter",onMouseDown:function(e){var t=a.current;t&&(l.current=e.clientX,u.current=e.clientY,s.current=t.getBoundingClientRect().width,document.addEventListener("mousemove",f,p),document.addEventListener("mouseup",g,p))}})},t.TextBox=k,t.ThemeContext=m,t.Tooltip=function(e){var n=e.ariaControlsSuffix,r=e.content,o=e.offset,a=e.position,i=e.target,l=N(!1),u=l.opened,s=l.toggle,d=c.useRef(),p=c.useRef(),f=c.useMemo((function(){return n||"".concat(R())}),[]);T((function(){d.current&&document.activeElement&&d.current.contains(document.activeElement)&&g()}));var m=function(){s(t.ToggleStatus.Open)},g=function(){s(t.ToggleStatus.Close)};return c.createElement(c.Fragment,null,c.createElement("div",{ref:d,"aria-describedby":"rpv-core__tooltip-body-".concat(f),onBlur:function(e){e.relatedTarget instanceof HTMLElement&&e.currentTarget.parentElement&&e.currentTarget.parentElement.contains(e.relatedTarget)?p.current&&(p.current.style.display="none"):g()},onFocus:m,onMouseEnter:m,onMouseLeave:g},i),u&&c.createElement(K,{ariaControlsSuffix:f,contentRef:p,offset:o,position:a,targetRef:d},r()))},t.Viewer=function(e){var n=e.characterMap,r=e.defaultScale,o=e.fileUrl,a=e.httpHeaders,i=void 0===a?{}:a,l=e.initialPage,u=void 0===l?0:l,s=e.localization,d=e.plugins,p=void 0===d?[]:d,f=e.renderError,g=e.renderPage,h=e.renderLoader,b=e.scrollMode,E=void 0===b?t.ScrollMode.Vertical:b,_=e.transformGetDocumentParam
1s,y=e.theme,k=void 0===y?{direction:t.TextDirection.LeftToRight,theme:"light"}:y,C=e.withCredentials,w=void 0!==C&&C,S=e.onDocumentAskPassword,M=e.onDocumentLoad,R=void 0===M?function(){}:M,L=e.onPageChange,T=void 0===L?function(){}:L,O=e.onRotate,I=void 0===O?function(){}:O,D=e.onRotatePage,N=void 0===D?function(){}:D,z=e.onSwitchTheme,F=void 0===z?function(){}:z,j=e.onZoom,B=void 0===j?function(){}:j,A=c.useState({data:o,name:"string"==typeof o?o:"",shouldLoad:!1}),H=A[0],V=A[1],W=function(e,t){V({data:t,name:e,shouldLoad:!0})},U=c.useState(!1),Z=U[0],K=U[1],G=ee(H);c.useEffect((function(){var e,t,n,r;e=G.data,r=typeof(t=o),"string"===(n=typeof e)&&"string"===r&&e===t||"object"===n&&"object"===r&&e.length===t.length&&e.every((function(e,n){return e===t[n]}))||V({data:o,name:"string"==typeof o?o:"",shouldLoad:Z})}),[o,Z]);var q=v({onVisibilityChanged:function(e){K(e.isVisible),e.isVisible&&V((function(e){return Object.assign({},e,{shouldLoad:!0})}))}}),J="string"==typeof k?{direction:t.TextDirection.LeftToRight,theme:k}:k,Y=c.useState(s||P),Q=Y[0],X=Y[1],$={l10n:Q,setL10n:X},te=Object.assign({},{direction:J.direction},function(e,t){var n=c.useMemo((function(){return"auto"===e?"undefined"!=typeof window&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":e}),[]),r=c.useState(n),o=r[0],a=r[1],i=ee(o);return c.useEffect((function(){if("auto"===e){var t=window.matchMedia("(prefers-color-scheme: dark)"),n=function(e){a(e.matches?"dark":"light")};return t.addEventListener("change",n),function(){return t.removeEventListener("change",n)}}}),[]),c.useEffect((function(){o!==i&&t&&t(o)}),[o]),c.useEffect((function(){e!==o&&a(e)}),[e]),{currentTheme:o,setCurrentTheme:a}}(J.theme||"light",F));return c.useEffect((function(){s&&X(s)}),[s]),c.createElement(x.Provider,{value:$},c.createElement(m.Provider,{value:te},c.createElement("div",{ref:q,className:"rpv-core__viewer rpv-core__viewer--".concat(te.currentTheme),"data-testid":"core__viewer",style:{height:"100%",width:"100%"}},H.shouldLoad&&c.createElement(ct,{characterMap:n,file:H.data,httpHeaders:i,render:function(e){return c.createElement(et,{defaultScale:r,doc:e,render:function(t){return c.createElement(Xe,{currentFile:{data:H.data,name:H.name},defaultScale:r,doc:e,initialPage:u,pageSize:t,plugins:p,renderPage:g,scrollMode:E,viewerState:{file:H,pageIndex:-1,pageHeight:t.pageHeight,pageWidth:t.pageWidth,pagesRotation:new Map,rotation:0,scale:t.scale,scrollMode:E},onDocumentLoad:R,onOpenFile:W,onPageChange:T,onRotate:I,onRotatePage:N,onZoom:B})},scrollMode:E})},renderError:f,renderLoader:h,transformGetDocumentParams:_,withCredentials:w,onDocumentAskPassword:S}))))},t.Worker=function(e){var t=e.children,n=e.workerUrl;return l.GlobalWorkerOptions.workerSrc=n,c.createElement(c.Fragment,null,t)},t.classNames=g,t.createStore=function(e){var t=e||{},n={};return{subscribe:function(e,t){n[e]=(n[e]||[]).concat(t)},unsubscribe:function(e,t){n[e]=(n[e]||[]).filter((function(e){return e!==t}))},update:function(e,r){var o;t=p(p({},t),((o={})[e]=r,o)),(n[e]||[]).forEach((function(n){return n(t[e])}))},get:function(e){return t[e]}}},t.getDestination=$,t.getPage=X,t.isMac=function(){return"undefined"!=typeof window&&/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)},t.useIntersectionObserver=v,t.useIsMounted=C,t.useIsomorphicLayoutEffect=h,t.useRenderQueue=S},54141:function(e,t,n){"use strict";e.exports=n(89469)},72939:function(e,t,n){"use strict";var r=n(54141),o=n(67294),a=n(27504),i=n(42227),c=n(24416),l=n(85734);var u=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(o),s=function(){return u.createElement(r.Icon,{size:16},u.createElement("path",{d:"M11.5,1.5h11c0.552,0,1,0.448,1,1v20c0,0.552-0.448,1-1,1h-21c-0.552,0-1-0.448-1-1v-20c0-0.552,0.448-1,1-1h3\n            M11.5,10.5c0,0.55-0.3,0.661-0.659,0.248L8,7.5l-2.844,3.246c-0.363,0.414-0.659,0.3-0.659-0.247v-9c0-0.552,0.448-1,1-1h5\n            c0.552,0,1,0.448,1,1L11.5,10.5z\n            M14.5,6.499h6\n            M14.5,10.499h6\n            M3.5,14.499h17\n            M3.5,18.499h16.497"}))},d=function(){return d=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},d.apply(this,arguments)},p=function(){return u.createElement(r.Icon,{size:16},u.createElement("path",{d:"M7.618,15.345l8.666-8.666c0.78-0.812,2.071-0.838,2.883-0.058s0.838,2.071,0.058,2.883\n            c-0.019,0.02-0.038,0.039-0.058,0.058L7.461,21.305c-1.593,1.593-4.175,1.592-5.767,0s-1.592-4.175,0-5.767c0,0,0,0,0,0\n            L13.928,3.305c2.189-2.19,5.739-2.19,7.929-0.001s2.19,5.739,0,7.929l0,0L13.192,19.9"}))},f=function(){return u.createElement(r.Icon,{size:16},u.createElement("path",{d:"M10.5,9.5c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V9.5z\n            M23.5,9.5c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V9.5z\n            M10.5,22.5 c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V22.5z\n            M23.5,22.5c0,
10.552-0.448,1-1,1 h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V22.5z"}))},m={left:8,top:0},g={left:-8,top:0},h=function(e){var t=e.attachmentTabContent,n=e.bookmarkTabContent,o=e.store,a=e.thumbnailTabContent,i=e.tabs,c=u.useRef(),l=u.useContext(r.LocalizationContext).l10n,d=u.useState(o.get("isCurrentTabOpened")||!1),h=d[0],v=d[1],b=u.useState(Math.max(o.get("currentTab")||0,0)),E=b[0],_=b[1],y=u.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,k=[{content:a,icon:u.createElement(f,null),title:l&&l.defaultLayout?l.defaultLayout.thumbnail:"Thumbnail"},{content:n,icon:u.createElement(s,null),title:l&&l.defaultLayout?l.defaultLayout.bookmark:"Bookmark"},{content:t,icon:u.createElement(p,null),title:l&&l.defaultLayout?l.defaultLayout.attachment:"Attachment"}],C=i?i(k):k,w=function(e){e>=0&&e<=C.length-1&&(o.update("isCurrentTabOpened",!0),_(e))},S=function(e){v(e)};return u.useEffect((function(){return o.subscribe("currentTab",w),o.subscribe("isCurrentTabOpened",S),function(){o.unsubscribe("currentTab",w),o.unsubscribe("isCurrentTabOpened",S)}}),[]),0===C.length?u.createElement(u.Fragment,null):u.createElement(u.Fragment,null,u.createElement("div",{"data-testid":"default-layout__sidebar",className:r.classNames({"rpv-default-layout__sidebar":!0,"rpv-default-layout__sidebar--opened":h,"rpv-default-layout__sidebar--ltr":!y,"rpv-default-layout__sidebar--rtl":y}),ref:c},u.createElement("div",{className:"rpv-default-layout__sidebar-tabs"},u.createElement("div",{className:"rpv-default-layout__sidebar-headers",role:"tablist","aria-orientation":"vertical"},C.map((function(e,t){return u.createElement("div",{"aria-controls":"rpv-default-layout__sidebar-content","aria-selected":E===t,key:t,className:"rpv-default-layout__sidebar-header",id:"rpv-default-layout__sidebar-tab-".concat(t),role:"tab"},u.createElement(r.Tooltip,{ariaControlsSuffix:"default-layout-sidebar-tab-".concat(t),position:y?r.Position.LeftCenter:r.Position.RightCenter,target:u.createElement(r.MinimalButton,{ariaLabel:e.title,isSelected:E===t,onClick:function(){return function(e){if(E===e){o.update("isCurrentTabOpened",!o.get("isCurrentTabOpened"));var t=c.current;t&&t.style.width&&t.style.removeProperty("width")}else o.update("currentTab",e)}(t)}},e.icon),content:function(){return e.title},offset:y?g:m}))}))),u.createElement("div",{"aria-labelledby":"rpv-default-layout__sidebar-tab-".concat(E),id:"rpv-default-layout__sidebar-content",className:r.classNames({"rpv-default-layout__sidebar-content":!0,"rpv-default-layout__sidebar-content--opened":h,"rpv-default-layout__sidebar-content--ltr":!y,"rpv-default-layout__sidebar-content--rtl":y}),role:"tabpanel",tabIndex:-1},C[E].content))),h&&u.createElement(r.Splitter,{constrain:function(e){return e.firstHalfPercentage>=20&&e.firstHalfPercentage<=80}}))};t.defaultLayoutPlugin=function(e){var t=u.useMemo((function(){return r.createStore({isCurrentTabOpened:!1,currentTab:0})}),[]),n=a.attachmentPlugin(),o=i.bookmarkPlugin(),s=c.thumbnailPlugin(e?e.thumbnailPlugin:{}),p=l.toolbarPlugin(e?e.toolbarPlugin:{}
1),f=n.Attachments,m=o.Bookmarks,g=s.Thumbnails,v=p.Toolbar,b=e?e.sidebarTabs:function(e){return e},E=[n,o,s,p];return{attachmentPluginInstance:n,bookmarkPluginInstance:o,thumbnailPluginInstance:s,toolbarPluginInstance:p,activateTab:function(e){t.update("currentTab",e)},toggleTab:function(e){var n=t.get("currentTab");t.update("isCurrentTabOpened",!t.get("isCurrentTabOpened")),n!==e&&t.update("currentTab",e)},install:function(e){E.forEach((function(t){t.install&&t.install(e)}))},renderPageLayer:function(e){return u.createElement(u.Fragment,null,E.map((function(t,n){return t.renderPageLayer?u.createElement(u.Fragment,{key:n},t.renderPageLayer(e)):u.createElement(u.Fragment,{key:n},u.createElement(u.Fragment,null))})))},renderViewer:function(n){var o=n.slot;E.forEach((function(e){e.renderViewer&&(o=e.renderViewer(d(d({},n),{slot:o})))}));var a=o.subSlot&&o.subSlot.attrs?{className:o.subSlot.attrs.className,"data-testid":o.subSlot.attrs["data-testid"],ref:o.subSlot.attrs.ref,style:o.subSlot.attrs.style}:{};return o.children=u.createElement("div",{className:"rpv-default-layout__container"},u.createElement("div",{"data-testid":"default-layout__main",className:r.classNames({"rpv-default-layout__main":!0,"rpv-default-layout__main--rtl":n.themeContext.direction===r.TextDirection.RightToLeft})},u.createElement(h,{attachmentTabContent:u.createElement(f,null),bookmarkTabContent:u.createElement(m,null),store:t,thumbnailTabContent:u.createElement(g,null),tabs:b}),u.createElement("div",{className:"rpv-default-layout__body","data-testid":"default-layout__body"},u.createElement("div",{className:"rpv-default-layout__toolbar"},e&&e.renderToolbar?e.renderToolbar(v):u.createElement(v,null)),u.createElement("div",d({},a),o.subSlot.children))),o.children),o.subSlot.attrs={},o.subSlot.children=u.createElement(u.Fragment,null),o},uninstall:function(e){E.forEach((function(t){t.uninstall&&t.uninstall(e)}))},onDocumentLoad:function(n){E.forEach((function(e){e.onDocumentLoad&&e.onDocumentLoad(n)})),e&&e.setInitialTab&&e.setInitialTab(n.doc).then((function(e){t.update("currentTab",e),t.update("isCurrentTabOpened",!0)}))},onAnnotationLayerRender:function(e){E.forEach((function(t){t.onAnnotationLayerRender&&t.onAnnotationLayerRender(e)}))},onTextLayerRender:function(e){E.forEach((function(t){t.onTextLayerRender&&t.onTextLayerRender(e)}))},onViewerStateChange:function(e){var t=e;return E.forEach((function(e){e.onViewerStateChange&&(t=e.onViewerStateChange(t))})),t}}}},10492:function(e,t,n){"use strict";e.exports=n(72939)},17062:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o,a=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),i=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M11.5 23.499L11.5 14.499"}),a.createElement("path",{d:"M7.5 18.499L11.5 14.499 15.5 18.499"}),a.createElement("path",{d:"M11.5 1.499L11.5 10.499"}),a.createElement("path",{d:"M7.5 6.499L11.5 10.499 15.5 6.499"}),a.createElement("path",{d:"M20.5 12.499L1.5 12.499"}))},c=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M0.5 12L23.5 12"}),a.createElement("path",{d:"M11.5 1L11.5 23"}),a.createElement("path",{d:"M8.5 4L11.5 1 14.5 4"}),a.createElement("path",{d:"M20.5 9L23.5 12 20.5 15"}),a.createElement("path",{d:"M3.5 15L0.5 12 3.5 9"}),a.createElement("path",{d:"M14.5 20L11.5 23 8.5 20"}))},l=function(){return l=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},l.apply(this,arguments)};!function(e){e[e.ExitFullScreen=0]="ExitFullScreen",e[e.FullScreenChange=1]="FullScreenChange",e[e.FullScreenElement=2]="FullScreenElement",e[e.FullScreenEnabled=3]="FullScreenEnabled",e[e.RequestFullScreen=4]="RequestFullScreen"}(o||(o={}));var u={ExitFullScreen:"exitFullscreen",FullScreenChange:"fullscreenchange",FullScreenElement:"fullscreenElement",FullScreenEnabled:"fullscreenEnabled",RequestFullScreen:"requestFullscreen"},s={ExitFullScreen:"webkitExitFullscreen",FullScreenChange:"webkitfullscreenchange",FullScreenElement:"webkitFullscreenElement",FullScreenEnabled:"webkitFullscreenEnabled",RequestFullScreen:"webkitRequestFullscreen"},d={ExitFullScreen:"msExitFullscreen",FullScreenChange:"msFullscreenChange",FullScreenElement:"msFullscreenElement",FullScreenEnabled:"msFullscreenEnabled",RequestFullScreen:"msRequestFullscreen"},p="undefined"!=typeof window,f=p&&(o.FullScreenEnabled in document&&u||s.FullScreenEnabled in document&&s||d.FullScreenEnabled in document&&d)||u,m=function(){return p&&f.FullScreenEnabled in document&&!0===document[f.FullScreenEnabled]},g=function(e){return p?e[f.ExitFullScreen]():Promise.resolve({})},h=function(){return p?document[f.FullScreenElement]:null},v={left:0,top:8},b=function(e){var t=e.enableShortcuts,n=e.onClick,o=a.useContext(r.LocalizationContext).l10n,i=o&&o.fullScreen?o.fullScreen.enterFullScreen:"Full screen",l=t?r.isMac()?"Meta+Ctrl+F":"F11":"";
1return a.createElement(r.Tooltip,{ariaControlsSuffix:"full-screen-enter",position:r.Position.BottomCenter,target:a.createElement(r.MinimalButton,{ariaKeyShortcuts:l,ariaLabel:i,isDisabled:!m(),testId:"full-screen__enter-button",onClick:n},a.createElement(c,null)),content:function(){return i},offset:v})},E={left:0,top:8},_=function(e){var t=e.onClick,n=a.useContext(r.LocalizationContext).l10n,o=n&&n.fullScreen?n.fullScreen.exitFullScreen:"Exit full screen";return a.createElement(r.Tooltip,{ariaControlsSuffix:"full-screen-exit",position:r.Position.BottomCenter,target:a.createElement(r.MinimalButton,{ariaKeyShortcuts:"Esc",ariaLabel:o,testId:"full-screen__exit-button-with-tooltip",onClick:t},a.createElement(i,null)),content:function(){return o},offset:E})},y=function(e,t,n,r){var o=a.useState(!1),i=o[0],c=o[1],l=a.useRef(t.get("getPagesContainer")?t.get("getPagesContainer")():null),u=function(){var o=h(),a=l.current,i=o===e(a);t.update("isFullScreen",i),i?a.classList.add("rpv-full-screen__pages"):a.classList.remove("rpv-full-screen__pages");var c=t.get("zoom");c&&(i?n(c):r(c))},s=function(e){var t;l.current=e(),t=u,p&&document.addEventListener(f.FullScreenChange,t)},d=function(e){c(e)};return a.useEffect((function(){return t.subscribe("isFullScreen",d),t.subscribe("getPagesContainer",s),function(){t.unsubscribe("getPagesContainer",s),t.unsubscribe("isFullScreen",d)}}),[]),{enterFullScreen:function(){if(m()){var t=l.current;t&&function(){var t=l.current;if(!t)return Promise.resolve();var n=h();return n&&n!==e(t)?g(n):Promise.resolve()}().then((function(){var n;n=e(t),p&&n[f.RequestFullScreen]()}))}},exitFullScreen:function(){c(!1);var n=t.get("getPagesContainer");if(n){var r=n();if(r){var o=h();o&&o===e(r)&&g(document)}}},isFullScreen:i}},k=function(e){var t=e.children,n=e.enableShortcuts,r=e.getFullScreenTarget,o=e.store,i=e.onEnterFullScreen,c=e.onExitFullScreen,l=y(r,o,i,c),u=l.enterFullScreen,s=l.exitFullScreen,d=l.isFullScreen;return(t||function(e){return d?a.createElement(_,{onClick:e.onClick}):a.createElement(b,{enableShortcuts:n,onClick:e.onClick})})({onClick:d?s:u})},C=function(e){var t=e.onClick,n=a.useContext(r.LocalizationContext).l10n,o=n&&n.fullScreen?n.fullScreen.enterFullScreen:"Full screen";return a.createElement(r.MenuItem,{icon:a.createElement(c,null),isDisabled:!m(),testId:"full-screen__enter-menu",onClick:t},o)},w=function(e){var t=e.onClick,n=a.useContext(r.LocalizationContext).l10n,o=a.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,c=n&&n.fullScreen?n.fullScreen.exitFullScreen:"Exit full screen";return a.createElement("div",{className:r.classNames({"rpv-full-screen__exit-button":!0,"rpv-full-screen__exit-button--ltr":!o,"rpv-full-screen__exit-button--rtl":o})},a.createElement(r.MinimalButton,{ariaLabel:c,testId:"full-screen__exit-button",onClick:t},a.createElement(i,null)))},S=function(e){var t=e.children,n=e.getFullScreenTarget,r=e.store,o=e.onEnterFullScreen,i=e.onExitFullScreen,c=y(n,r,o,i),l=c.enterFullScreen,u=c.exitFullScreen,s=c.isFullScreen;return s&&(t||function(e){return a.createElement(w,{onClick:e.onClick})})({onClick:s?u:l})},P=function(e){var t=e.containerRef,n=e.getFullScreenTarget,o=e.store,i=e.onEnterFullScreen,c=e.onExitFullScreen,l=y(n,o,i,c).enterFullScreen,u=function(e){if(!e.shiftKey&&!e.altKey&&(r.isMac()?e.metaKey&&e.ctrlKey&&"f"===e.key:"F11"===e.key)){var n=t.current;n&&document.activeElement&&n.contains(document.activeElement)&&(e.preventDefault(),l())}};return a.useEffect((function(){if(t.current)return document.addEventListener("keydown",u),function(){document.removeEventListener("keydown",u)}}),[t.current]),a.createElement(a.Fragment,null)};t.ExitFullScreenIcon=i,t.FullScreenIcon=c,t.fullScreenPlugin=function(e){var t=(null==e?void 0:e.getFullScreenTarget)||function(e){return e},n=a.useMemo((function(){return Object.assign({},{enableShortcuts:!0,onEnterFullScreen:function(){},onExitFullScreen:function(){}},e)}),[]),o=a.useMemo((function(){return r.createStore({})}),[]),i=function(e){return a.createElement(k,l({},e,{enableShortcuts:n.enableShortcuts,getFullScreenTarget:t,store:o,onEnterFullScreen:n.onEnterFullScreen,onExitFullScreen:n.onExitFullScreen}))},c=function(){return a.createElement(S,{getFullScreenTarget:t,store:o,onEnterFullScreen:n.onEnterFullScreen,onExitFullScreen:n.onExitFullScreen},null==e?void 0:e.renderExitFullScreenButton)};return{install:function(e){o.update("getPagesContainer",e.getPagesContainer),o.update("zoom",e.zoom)},renderViewer:function(e){var r=e.slot;return r.subSlot&&(r.subSlot.children=a.createElement(a.Fragment,null,n.enableShortcuts&&a.createElement(P,{containerRef:e.containerRef,getFullScreenTarget:t,store:o,onEnterFullScreen:n.onEnterFullScreen,onExitFullScreen:n.onExitFullScreen}),a.createElement(c,null),r.subSlot.children)),r},EnterFullScreen:i,EnterFullScreenButton:function(){return a.createElement(i,null,(function(e){return a.createElement(b,l({enableShortcuts:n.enableShortcuts},e))}))},EnterFullScreenMenuItem:function(e){return a.createElement(i,null,(function(t){return a.createElement(C,{onClick:function(){t.onClick(),e.onClick()}})}))}}}},74948:function(e,t,n){"use strict";e.exports=n(17062)},76784:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M5.5,11.5c-.275,0-.341.159-.146.354l6.292,6.293a.5.5,0,0,0,.709,0l6.311-6.275c.2-.193.13-.353-.145-.355L15.5,11.5V1.5a1,1,0,0,0-1-1h-5a1,1,0,0,0-1,1V11a.5.5,0,0,1-.5.5Z"}),o.createElement("path",{d:"M23.5,18.5v4a1,1,0,0,1-1,1H1.5a1,1,0,0,1-1-1v-4"}))},i=function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},c={left:0,top:8},l=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,i=n&&n.download?n.download.download:"Download";return o.createElement(r.Tooltip,{ariaControlsSuffix:"get-file",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:i,testId:"get-file__download-button",onClick:t},o.createElement(a,null)),content:function(){return i},offset:c})},u=function(e,t){var n=document.createElement("a");n.style.display="none",n.href=e,n.setAttribute("download",t),document.body.appendChild(n),n.click(),document.body.removeChild(n)},s=function(e,t,n){var r=URL.createObjectURL(new Blob([e],{type:n}));u(r,t),r&&URL.revokeObjectURL(r)},d=function(e,t){e.getData().then((function(e){/iphone|ipod|ipad/i.test(navigator.userAgent)&&!/CriOS/i.test(navigator.userAgent)?s(e,t,"application/octet-stream"):/iphone|ipod|ipad/i.test(navigator.userAgent)&&/CriOS/i.test(navigator.userAgent)?u("data:application/pdf;base64,".concat(function(e){return btoa(Array(e.length).fill("").map((function(t,n){return String.fromCharCode(e[n])})).join(""))}(e)),t):s(e,t,"application/pdf")}))},p=function(e){var t=e.children,n=e.fileNameGenerator,r=e.store,a=o.useState(r.get("file")),i=a[0],c=a[1],u=o.useState(r.get("doc")),s=u[0],p=u[1],f=function(e){p(e)},m=function(e){c(e)};return o.useEffect((function(){return r.subscribe("doc",f),r.subscribe("file",m),function(){r.subscribe("doc",f),r.unsubscribe("file",m)}}),[]),(t||function(e){return o.createElement(l,{onClick:e.onClick})})({onClick:function(){s&&i&&d(s,n(i))}})},f=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,i=n&&n.download?n.download.download:"Download";return o.createElement(r.MenuItem,{icon:o.createElement(a,null),testId:"get-file__download-menu",onClick:t},i)};t.DownloadIcon=a,t.getFilePlugin=function(e){var t=o.useMemo((function(){return r.createStore({})}),[]),n=function(e){return e.name?(n=(t=e.name).split("/").pop())?n.split("#")[0].split("?")[0]:t:"document.pdf";var t,n},a=function(r){return o.createElement(p,i({},r,{fileNameGenerator:e&&e.fileNameGenerator||n,store:t}))};return{onDocumentLoad:function(e){t.update("doc",e.doc),t.update("file",e.file)},Download:a,DownloadButton:function(){return o.createElement(a,null,(function(e){return o.createElement(l,i({},e))}))},DownloadMenuItem:function(e){return o.createElement(a,null,(function(t){return o.createElement(f,{onClick:function(){t.onClick(),e.onClick()}})}))}}}},48448:function(e,t,n){"use strict";e.exports=n(76784)},6111:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M18.5,7.5c.275,0,.341-.159.146-.354L12.354.854a.5.5,0,0,0-.708,0L5.354,7.147c-.2.195-.129.354.146.354h3v10a1,1,0,0,0,1,1h5a1,1,0,0,0,1-1V7.5Z"}),o.createElement("path",{d:"M23.5,18.5v4a1,1,0,0,1-1,1H1.5a1,1,0,0,1-1-1v-4"}))},i=function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},c=function(e){var t=o.useRef(),n=function(){var n=t.current;n&&(n.click(),e.get("triggerOpenFile")&&e.update("triggerOpenFile",!1))},r=function(e){e&&n()};return o.useEffect((function(){return e.subscribe("triggerOpenFile",r),function(){e.unsubscribe("triggerOpenFile",r)}}),[]),{inputRef:t,openFile:n}},l={left:0,top:8},u=function(e){var t=e.enableShortcuts,n=e.store,i=e.onClick,u=o.useContext(r.LocalizationContext).l10n,s=u&&u.open?u.open.openFile:"Open file",d=c(n),p=d.inputRef,f=d.openFile,m=t?r.isMac()?"Meta+O":"Ctrl+O":"";
1return o.createElement(r.Tooltip,{ariaControlsSuffix:"open",position:r.Position.BottomCenter,target:o.createElement("div",{className:"rpv-open__input-wrapper"},o.createElement("input",{ref:p,className:"rpv-open__input",multiple:!1,tabIndex:-1,title:"",type:"file",onChange:i}),o.createElement(r.MinimalButton,{ariaKeyShortcuts:m,ariaLabel:s,testId:"open__button",onClick:f},o.createElement(a,null))),content:function(){return s},offset:l})},s=function(e){var t=e.children,n=e.enableShortcuts,r=e.store;return(t||function(e){return o.createElement(u,{enableShortcuts:n,store:r,onClick:e.onClick})})({onClick:function(e){var t=e.target.files;if(t&&t.length){var n=r.get("openFile");n&&n(t[0])}}})},d=function(e){var t=e.store,n=e.onClick,i=o.useContext(r.LocalizationContext).l10n,l=i&&i.open?i.open.openFile:"Open file",u=c(t),s=u.inputRef,d=u.openFile;return o.createElement(r.MenuItem,{icon:o.createElement(a,null),testId:"open__menu",onClick:d},o.createElement("div",{className:"rpv-open__input-wrapper"},o.createElement("input",{ref:s,className:"rpv-open__input",multiple:!1,tabIndex:-1,title:"",type:"file",onChange:n}),l))},p=function(e){var t=e.containerRef,n=e.store,a=function(e){if(!e.shiftKey&&!e.altKey&&"o"===e.key&&(r.isMac()?e.metaKey:e.ctrlKey)){var o=t.current;o&&document.activeElement&&o.contains(document.activeElement)&&(e.preventDefault(),n.update("triggerOpenFile",!0))}};return o.useEffect((function(){if(t.current)return document.addEventListener("keydown",a),function(){document.removeEventListener("keydown",a)}}),[t.current]),o.createElement(o.Fragment,null)};t.OpenFileIcon=a,t.openPlugin=function(e){var t=o.useMemo((function(){return Object.assign({},{enableShortcuts:!0},e)}),[]),n=o.useMemo((function(){return r.createStore({})}),[]),a=function(e){return o.createElement(s,i({enableShortcuts:t.enableShortcuts},e,{store:n}))};return{install:function(e){n.update("openFile",e.openFile)},renderViewer:function(e){var r=e.slot,a={children:o.createElement(o.Fragment,null,t.enableShortcuts&&o.createElement(p,{containerRef:e.containerRef,store:n}),r.children)};return i(i({},r),a)},Open:a,OpenButton:function(){return o.createElement(a,null)},OpenMenuItem:function(){return o.createElement(a,null,(function(e){return o.createElement(d,{store:n,onClick:e.onClick})}))}}}},50007:function(e,t,n){"use strict";e.exports=n(6111)},20229:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M2.32,2.966h19.452c0.552,0.001,1,0.449,0.999,1.001c0,0.182-0.05,0.36-0.144,0.516L12.9,20.552\n            c-0.286,0.472-0.901,0.624-1.373,0.338c-0.138-0.084-0.254-0.2-0.338-0.338L1.465,4.483C1.179,4.01,1.331,3.396,1.804,3.11\n            C1.96,3.016,2.138,2.966,2.32,2.966z"}))},i=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M0.541,5.627L11.666,18.2c0.183,0.207,0.499,0.226,0.706,0.043c0.015-0.014,0.03-0.028,0.043-0.043\n            L23.541,5.627"}))},c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},c.apply(this,arguments)},l=function(e){var t=o.useState(e.get("currentPage")||0),n=t[0],a=t[1],i=function(e){a(e)};return r.useIsomorphicLayoutEffect((function(){return e.subscribe("currentPage",i),function(){e.unsubscribe("currentPage",i)}}),[]),{currentPage:n}},u=function(e){var t=o.useState(e.get("numberOfPages")||0),n=t[0],r=t[1],a=function(e){r(e)};return o.useEffect((function(){return e.subscribe("numberOfPages",a),function(){e.unsubscribe("numberOfPages",a)}}),[]),{numberOfPages:n}},s=function(e){var t=e.store,n=o.useContext(r.LocalizationContext).l10n,a=o.useState("1"),i=a[0],c=a[1],s=l(t).currentPage,d=u(t).numberOfPages;o.useEffect((function(){return c("".concat(s+1))}),[s]);var p=function(e){var n=t.get("jumpToPage");n&&n(e)},f=n&&n.pageNavigation?n.pageNavigation.enterPageNumber:"Enter a page number";return o.createElement("span",{className:"rpv-page-navigation__current-page-input"},o.createElement(r.TextBox,{ariaLabel:f,testId:"page-navigation__current-page-input",type:"text",value:i,onChange:c,onKeyDown:function(e){switch(e.key){case"ArrowUp":(r=s-1)>=0&&(c("".concat(r+1)),p(r));break;case"ArrowDown":(n=s+1)<d&&(c("".concat(n+1)),p(n));break;case"Enter":t=parseInt(i,10),""===i||t<1||t>d?c("".concat(s+1)):p(t-1)}var t,n,r}}))},d=function(e){var t=e.children,n=e.doc,a=r.useIsMounted(),i=o.useState({loading:!0,labels:[]}),c=i[0],l=i[1];return o.useEffect((function(){n.getPageLabels().then((function(e){a.current&&l({loading:!1,labels:e||[]})}
1))}),[n.loadingTask.docId]),c.loading?o.createElement(o.Fragment,null):t(c.labels)},p=function(e){var t=e.children,n=e.store,r=function(e){var t=o.useState(e.get("doc")),n=t[0],r=t[1],a=function(e){r(e)};return o.useEffect((function(){return e.subscribe("doc",a),function(){e.unsubscribe("doc",a)}}),[]),n}(n),a=l(n).currentPage,i=u(n).numberOfPages,c=t||function(e){return o.createElement(o.Fragment,null,e.currentPage+1)};return r?o.createElement(d,{doc:r},(function(e){var t=e.length===i&&i>0?e[a]:"";return c({currentPage:a,numberOfPages:i,pageLabel:t})})):o.createElement(o.Fragment,null)},f=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M21.783,21.034H2.332c-0.552,0-1-0.448-1-1c0-0.182,0.05-0.361,0.144-0.517L11.2,3.448\n            c0.286-0.472,0.901-0.624,1.373-0.338c0.138,0.084,0.254,0.2,0.338,0.338l9.726,16.069c0.286,0.473,0.134,1.087-0.339,1.373\n            C22.143,20.984,21.965,21.034,21.783,21.034z"}))},m={left:0,top:8},g=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,i=a&&a.pageNavigation?a.pageNavigation.goToFirstPage:"First page";return o.createElement(r.Tooltip,{ariaControlsSuffix:"page-navigation-first",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:i,isDisabled:t,testId:"page-navigation__first-button",onClick:n},o.createElement(f,null)),content:function(){return i},offset:m})},h=function(e){var t=e.children,n=e.store;return(t||function(e){return o.createElement(g,{isDisabled:e.isDisabled,onClick:e.onClick})})({isDisabled:0===l(n).currentPage,onClick:function(){var e=n.get("jumpToPage");e&&e(0)}})},v=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,i=a&&a.pageNavigation?a.pageNavigation.goToFirstPage:"First page";return o.createElement(r.MenuItem,{icon:o.createElement(f,null),isDisabled:t,testId:"page-navigation__first-menu",onClick:n},i)},b={left:0,top:8},E=function(e){var t=e.isDisabled,n=e.onClick,i=o.useContext(r.LocalizationContext).l10n,c=i&&i.pageNavigation?i.pageNavigation.goToLastPage:"Last page";return o.createElement(r.Tooltip,{ariaControlsSuffix:"page-navigation-last",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:c,isDisabled:t,testId:"page-navigation__last-button",onClick:n},o.createElement(a,null)),content:function(){return c},offset:b})},_=function(e){var t=e.children,n=e.store,r=l(n).currentPage,a=u(n).numberOfPages;return(t||function(e){return o.createElement(E,{isDisabled:e.isDisabled,onClick:e.onClick})})({isDisabled:r+1>=a,onClick:function(){var e=n.get("jumpToPage");e&&e(a-1)}})},y=function(e){var t=e.isDisabled,n=e.onClick,i=o.useContext(r.LocalizationContext).l10n,c=i&&i.pageNavigation?i.pageNavigation.goToLastPage:"Last page";return o.createElement(r.MenuItem,{icon:o.createElement(a,null),isDisabled:t,testId:"page-navigation__last-menu",onClick:n},c)},k={left:0,top:8},C=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,c=a&&a.pageNavigation?a.pageNavigation.goToNextPage:"Next page";return o.createElement(r.Tooltip,{ariaControlsSuffix:"page-navigation-next",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:c,isDisabled:t,testId:"page-navigation__next-button",onClick:n},o.createElement(i,null)),content:function(){return c},offset:k})},w=function(e){var t=e.children,n=e.store,r=l(n).currentPage,a=u(n).numberOfPages;return(t||function(e){return o.createElement(C,{onClick:e.onClick,isDisabled:e.isDisabled})})({isDisabled:r+1>=a,onClick:function(){var e=n.get("jumpToPage");e&&e(r+1)}})},S=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,c=a&&a.pageNavigation?a.pageNavigation.goToNextPage:"Next page";return o.createElement(r.MenuItem,{icon:o.createElement(i,null),isDisabled:t,testId:"page-navigation__next-menu",onClick:n},c)},P=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M23.535,18.373L12.409,5.8c-0.183-0.207-0.499-0.226-0.706-0.043C11.688,5.77,11.674,5.785,11.66,5.8\n            L0.535,18.373"}))},x={left:0,top:8},M=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,i=a&&a.pageNavigation?a.pageNavigation.goToPreviousPage:"Previous page";
1return o.createElement(r.Tooltip,{ariaControlsSuffix:"page-navigation-previous",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:i,isDisabled:t,testId:"page-navigation__previous-button",onClick:n},o.createElement(P,null)),content:function(){return i},offset:x})},R=function(e){var t=e.store,n=e.children,r=l(t).currentPage;return(n||function(e){return o.createElement(M,{isDisabled:e.isDisabled,onClick:e.onClick})})({isDisabled:r<=0,onClick:function(){var e=t.get("jumpToPage");e&&e(r-1)}})},L=function(e){var t=e.isDisabled,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,i=a&&a.pageNavigation?a.pageNavigation.goToPreviousPage:"Previous page";return o.createElement(r.MenuItem,{icon:o.createElement(P,null),isDisabled:t,testId:"page-navigation__previous-menu",onClick:n},i)},T=function(e){var t=e.children,n=e.store,r=u(n).numberOfPages;return t?t({numberOfPages:r}):o.createElement(o.Fragment,null,r)},O=function(e){var t=e.containerRef;e.doc;var n=e.numPages,a=e.store,i=o.useRef(a.get("jumpFromAnnotation")||{bottomOffset:0,dest:"",leftOffset:0,pageIndex:-1}),c=l(a).currentPage,u=o.useRef(c);u.current=c;var s=o.useRef(!1),d=function(){s.current=!0},p=function(){s.current=!1},f=function(e){var o=t.current,c=s.current||document.activeElement&&o.contains(document.activeElement);if(o&&c){var l,d,p,f,m=e.altKey&&"ArrowDown"===e.key||!e.shiftKey&&!e.altKey&&"PageDown"===e.key,g=e.altKey&&"ArrowUp"===e.key||!e.shiftKey&&!e.altKey&&"PageUp"===e.key,h=(r.isMac()?e.metaKey&&!e.ctrlKey:e.ctrlKey)&&"ArrowUp"===e.key;m?(e.preventDefault(),p=a.get("jumpToPage"),f=u.current+1,p&&f<n&&p(f)):g?(e.preventDefault(),function(){var e=a.get("jumpToPage"),t=u.current-1;e&&t>=0&&e(t)}()):h&&i.current&&i.current.dest&&(e.preventDefault(),l=i.current,(d=a.get("jumpToDestination"))&&d(l.pageIndex,l.bottomOffset,l.leftOffset))}},m=function(e){i.current=e};return o.useEffect((function(){return a.subscribe("jumpFromAnnotation",m),function(){a.unsubscribe("jumpFromAnnotation",m)}}),[]),o.useEffect((function(){var e=t.current;if(e)return document.addEventListener("keydown",f),e.addEventListener("mouseenter",d),e.addEventListener("mouseleave",p),function(){document.removeEventListener("keydown",f),e.removeEventListener("mouseenter",d),e.removeEventListener("mouseleave",p)}}),[t.current]),o.createElement(o.Fragment,null)};t.DownArrowIcon=a,t.NextIcon=i,t.PreviousIcon=P,t.UpArrowIcon=f,t.pageNavigationPlugin=function(e){var t=o.useMemo((function(){return Object.assign({},{enableShortcuts:!0},e)}),[]),n=o.useMemo((function(){return r.createStore()}),[]),a=function(e){return o.createElement(h,c({},e,{store:n}))},i=function(e){return o.createElement(_,c({},e,{store:n}))},l=function(e){return o.createElement(w,c({},e,{store:n}))},u=function(e){return o.createElement(R,c({},e,{store:n}))};return{install:function(e){n.update("jumpToDestination",e.jumpToDestination),n.update("jumpToPage",e.jumpToPage)},renderViewer:function(e){var r=e.slot;if(!t.enableShortcuts)return r;var a={children:o.createElement(o.Fragment,null,o.createElement(O,{containerRef:e.containerRef,doc:e.doc,numPages:e.doc.numPages,store:n}),r.children)};return c(c({},r),a)},onAnnotationLayerRender:function(e){if(e.annotations.length){var t=e.annotations.filter((function(e){return"Link"===e.subtype&&!e.url&&!e.unsafeUrl&&!e.action&&e.dest}));t.length&&t.forEach((function(t){var r=e.container.querySelector('a[data-annotation-link-dest="'.concat(t.dest,'"]'));r&&r.addEventListener("click",(function(){e.container.style.setProperty("height","100%"),e.container.style.setProperty("width","100%");var o=e.container.getBoundingClientRect();e.container.style.removeProperty("height"),e.container.style.removeProperty("width");var a=r.getBoundingClientRect(),i=a.left-o.left,c=o.bottom-a.bottom+a.height;n.update("jumpFromAnnotation",{bottomOffset:c/e.scale,dest:t.dest,leftOffset:i/e.scale,pageIndex:e.pageIndex})}))}))}},onDocumentLoad:function(e){n.update("doc",e.doc),n.update("numberOfPages",e.doc.numPages)},onViewerStateChange:function(e){return n.update("currentPage",e.pageIndex),e},jumpToPage:function(e){var t=n.get("jumpToPage");t&&t(e)},CurrentPageInput:function(){return o.createElement(s,{store:n})},CurrentPageLabel:function(e){return o.createElement(p,c({},e,{store:n}))},GoToFirstPage:a,GoToFirstPageButton:function(){return o.createElement(a,null,(function(e){return o.createElement(g,c({},e))}))},GoToFirstPageMenuItem:function(e){return o.createElement(a,null,(function(t){return o.createElement(v,{isDisabled:t.isDisabled,onClick:function(){t.onClick(),e.onClick()}})}))},GoToLastPage:i,GoToLastPageButton:function(){return o.createElement(i,null,(function(e){return o.createElement(E,c({},e))}))},GoToLastPageMenuItem:function(e){return o.createElement(i,null,(function(t){return o.createElement(y,{isDisabled:t.isDisabled,onClick:function(){t.onClick(),e.onClick()}})}))},GoToNextPage:l,GoToNextPageButton:function(){return o.createElement(l,null,(function(e){return o.createElement(C,c({},e))}))},GoToNextPageMenuItem:function(e){return o.createElement(l,null,(function(t){return o.createElement(S,{isDisabled:t.isDisabled,onClick:function(){t.onClick(),e.onClick()}})}))},GoToPreviousPage:u,GoToPreviousPageButton:function(){return o.createElement(u,null,(function(e){return o.createElement(M,c({},e))}))},GoToPreviousPageMenuItem:function(e){return o.createElement(u,null,(function(t){return o.createElement(L,{isDisabled:t.isDisabled,onClick:function(){t.onClick(),e.onClick()}})}))},NumberOfPages:function(e){return o.createElement(T,c({},e,{store:n}))}}}},13572:function(e,t,n){"use strict";e.exports=n(20229)},17302:function(e,t,n){"use strict";var r=n(83454);
1Object.defineProperty(t,"__esModule",{value:!0});var o=n(54141),a=n(67294),i=n(73935);var c,l=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(a),u=function(){return l.createElement(o.Icon,{size:16},l.createElement("path",{d:"M7.5,19.499h9 M7.5,16.499h9 M5.5,16.5h-3c-1.103-0.003-1.997-0.897-2-2v-6c0.003-1.103,0.897-1.997,2-2h19\n            c1.103,0.003,1.997,0.897,2,2v6c-0.003,1.103-0.897,1.997-2,2h-3\n            M5.5,4.5v-4h9.586c0.265,0,0.52,0.105,0.707,0.293l2.414,2.414\n            C18.395,3.394,18.5,3.649,18.5,3.914V4.5\n            M18.5,22.5c0,0.552-0.448,1-1,1h-11c-0.552,0-1-0.448-1-1v-9h13V22.5z\n            M3.5,8.499\n            c0.552,0,1,0.448,1,1s-0.448,1-1,1s-1-0.448-1-1S2.948,8.499,3.5,8.499z\n            M14.5,0.499v4h4"}))},s=function(){return s=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},s.apply(this,arguments)},d={left:0,top:8},p=function(e){var t=e.enableShortcuts,n=e.onClick,r=l.useContext(o.LocalizationContext).l10n,a=r&&r.print?r.print.print:"Print",i=t?o.isMac()?"Meta+P":"Ctrl+P":"";return l.createElement(o.Tooltip,{ariaControlsSuffix:"print",position:o.Position.BottomCenter,target:l.createElement(o.MinimalButton,{ariaKeyShortcuts:i,ariaLabel:a,testId:"print__button",onClick:n},l.createElement(u,null)),content:function(){return a},offset:d})};!function(e){e.CheckingPermission="CheckingPermission",e.Inactive="Inactive",e.Preparing="Preparing",e.Cancelled="Cancelled",e.Ready="Ready"}(c||(c={}));var f=function(e){var t=e.children,n=e.enableShortcuts,r=e.store;return(t||p)({enableShortcuts:n,onClick:function(){r.update("printStatus",c.CheckingPermission)}})},m=function(e){var t=e.doc,n=e.store,r=l.useContext(o.LocalizationContext).l10n,a=l.useState(!0),i=a[0],u=a[1];return l.useEffect((function(){t.getPermissions().then((function(e){null===e||e.includes(4)||e.includes(2048)?n.update("printStatus",c.Preparing):u(!1)}))}),[]),i?l.createElement(l.Fragment,null):l.createElement(o.Modal,{ariaControlsSuffix:"print-permission",closeOnClickOutside:!1,closeOnEscape:!1,content:function(e){return l.createElement(l.Fragment,null,l.createElement("div",{className:"rpv-print__permission-body"},r&&r.print?r.print.disallowPrint:"The document does not allow to print"),l.createElement("div",{className:"rpv-print__permission-footer"},l.createElement(o.Button,{onClick:function(){e(),n.update("printStatus",c.Cancelled)}},r&&r.print?r.print.close:"Close")))},isOpened:!0})},g=function(e){var t=e.numLoadedPages,n=e.numPages,r=e.onCancel,a=l.useContext(o.LocalizationContext).l10n,i=l.useContext(o.ThemeContext).direction===o.TextDirection.RightToLeft,c=Math.floor(100*t/n);return l.createElement("div",{className:"rpv-print__progress"},l.createElement("div",{className:o.classNames({"rpv-print__progress-body":!0,"rpv-print__progress-body--rtl":i})},l.createElement("div",{className:"rpv-print__progress-message"},a&&a.print?a.print.preparingDocument:"Preparing document ..."),l.createElement("div",{className:"rpv-print__progress-bar"},l.createElement(o.ProgressBar,{progress:c})),l.createElement(o.Button,{onClick:r},a&&a.print?a.print.cancel:"Cancel")))},h=function(e){var t=e.canvas,n=e.page,a=e.pageHeight,i=e.pageIndex,c=e.pageWidth,u=e.rotation,s=e.onLoad,d=o.useIsMounted(),p=l.useRef(),f=l.useState(""),m=f[0],g=f[1],h=l.useMemo((function(){return"undefined"!=typeof r&&void 0!==r.env.JEST_WORKER_ID}),[]);return l.useEffect((function(){var e=p.current;e&&e.cancel();var r=150/72;t.height=Math.floor(a*r),t.width=Math.floor(c*r);var o=t.getContext("2d");o.save(),o.fillStyle="rgb(255, 255, 255)",o.fillRect(0,0,t.width,t.height),o.restore();var i=n.getViewport({rotation:u,scale:1});p.current=n.render({canvasContext:o,intent:"print",transform:[r,0,0,r,0,0],viewport:i}),p.current.promise.then((function(){"toBlob"in t&&"createObjectURL"in URL?t.toBlob((function(e){d.current&&g(URL.createObjectURL(e)),h&&s()})):(d.current&&g(t.toDataURL()),h&&s())}),(function(){}))}),[]),m&&l.createElement("div",{className:"rpv-print__page"},l.createElement("img",{"data-testid":"print__thumbnail-".concat(i),src:m,onLoad:function(){h||s()}}))},v=function(e){var t=e.canvas,n=e.doc,r=e.pageHeight,a=e.pageIndex,i=e.pageRotation,c=e.pageWidth,u=e.rotation,s=e.shouldRender,d=e.onLoad,p=o.useIsMounted(),f=l.useState({height:r,page:null,viewportRotation:0,width:c}),m=f[0],g=f[1],v=m.page,b=m.height,E=m.width,_=Math.abs(u+i)%180==0;l.useEffect((function(){s&&o.getPage(n,a).then((function(e){var t=e.getViewport({scale:1});p.current&&g({height:t.height,page:e,viewportRotation:t.rotation,width:t.width})}))}),[s]);var y=(m.viewportRotation+u+i)%360;return v&&l.createElement(h,{canvas:t,page:v,pageHeight:_?b:E,pageIndex:a,pageWidth:_?E:b,rotation:y,onLoad:d})},b=function(e){var t=e.doc,n=e.numLoadedPages,r=e.pagesRotation,o=e.pageHeight,a=e.pageWidth,u=e.printPages,s=e.printStatus,d=e.rotation,p=e.onCancel,f=e.onLoad,m=l.useMemo((function(){return document.createElement("canvas")}),[]),g=l.useMemo((function(){var e=document.querySelector(".rpv-print__zone");if(e)return e;var t=document.createElement("div");return t.classList.add("rpv-print__zone"),t.setAttribute("data-testid","print__zone"),document.body.appendChild(t),t}),[]);return l.useEffect((function(){s===c.Ready&&(document.documentElement.classList.add("rpv-print__html-printing"),document.body.classList.add("rpv-print__body-printing"),window.print());var e=function(){if(s===c.Ready){document.documentElement.classList.remove("rpv-print__html-printing"),document.body.classList.remove("rpv-print__body-printing");var t=document.querySelectorAll(".rpv-print__zone");t&&t.forEach((function(e){e.parentElement.removeChild(e)})),m.height=0,m.width=0,document.removeEventListener("mousemove",e),p()}};return document.addEventListener("mousemove",e),function(){return document.removeEventListener("mousemove",e)}}),[s]),i.createPortal(l.createElement(l.Fragment,null,u.map((function(e,i){return l.createElement(v,{key:e,canvas:m,doc:t,pageHeight:o,pageIndex:e,pageRotation:r.has(e)?r.get(e):0,pageWidth:a,rotation:d,shouldRender:i===n,onLoad:f})})),l.createElement("style",{dangerouslySetInnerHTML:{__html:"@page { size: ".concat(a,"pt ").concat(o,"pt }")}})),g)},E=function(e){var t=e.doc,n=e.pagesRotation,r=e.pageHeight,o=e.pageWidth,a=e.renderProgressBar,i=e.rotation,u=e.setPages,s=e.store,d=l.useState(c.Inactive),p=d[0],f=d[1],h=l.useState(0),v=h[0],E=h[1],_=l.useMemo((function(){var e=t.numPages;return u(t).filter((function(t){return t>=0&&t<e}))}),[t,u]),y=_.length,k=function(){E(0),f(c.Inactive)}
1,C=function(e){return f(e)};return l.useEffect((function(){return s.subscribe("printStatus",C),function(){s.unsubscribe("printStatus",C)}}),[]),l.createElement(l.Fragment,null,p===c.CheckingPermission&&l.createElement(m,{doc:t,store:s}),p===c.Preparing&&(a?a(v,y,k):l.createElement(g,{numLoadedPages:v,numPages:y,onCancel:k})),(p===c.Preparing||p===c.Ready)&&v<=y&&l.createElement(b,{doc:t,numLoadedPages:v,pagesRotation:n,pageHeight:r,pageWidth:o,printPages:_,printStatus:p,rotation:i,onCancel:k,onLoad:function(){var e=v+1;e<=y&&(E(e),e===y&&f(c.Ready))}}))},_=function(e){var t=e.onClick,n=l.useContext(o.LocalizationContext).l10n,r=n&&n.print?n.print.print:"Print";return l.createElement(o.MenuItem,{icon:l.createElement(u,null),testId:"print__menu",onClick:t},r)},y=function(e){var t=e.containerRef,n=e.store,r=function(e){if(!e.shiftKey&&!e.altKey&&"p"===e.key&&(o.isMac()?e.metaKey:e.ctrlKey)){var r=t.current;r&&document.activeElement&&r.contains(document.activeElement)&&(e.preventDefault(),n.update("printStatus",c.Preparing))}};return l.useEffect((function(){if(t.current)return document.addEventListener("keydown",r),function(){document.removeEventListener("keydown",r)}}),[t.current]),l.createElement(l.Fragment,null)};t.PrintIcon=u,t.getAllPagesNumbers=function(e){return Array(e.numPages).fill(0).map((function(e,t){return t}))},t.getCustomPagesNumbers=function(e){return function(t){var n,r=[];return e.replace(/\s+/g,"").split(",").forEach((function(e){var t,n,o=e.split("-").map((function(e){return parseInt(e,10)})).filter((function(e){return Number.isInteger(e)}));1===o.length?r.push(o[0]-1):2===o.length&&r.push.apply(r,(t=o[0]-1,n=o[1]-1,Array(n-t+1).fill(0).map((function(e,n){return t+n}))))})),(n=r,n.filter((function(e){return n.indexOf(e)===n.lastIndexOf(e)}))).filter((function(e){return e>=0&&e<t.numPages}))}},t.getEvenPagesNumbers=function(e){return Array(e.numPages).fill(0).map((function(e,t){return t})).filter((function(e){return(e+1)%2==0}))},t.getOddPagesNumbers=function(e){return Array(e.numPages).fill(0).map((function(e,t){return t})).filter((function(e){return(e+1)%2==1}))},t.printPlugin=function(e){var t=l.useMemo((function(){return Object.assign({},{enableShortcuts:!0,setPages:function(e){return Array(e.numPages).fill(0).map((function(e,t){return t}))}},e)}),[]),n=l.useMemo((function(){return o.createStore({printStatus:c.Inactive})}),[]),r=function(e){return l.createElement(f,s({enableShortcuts:t.enableShortcuts},e,{store:n}))};return{print:function(){n.update("printStatus",c.CheckingPermission)},renderViewer:function(r){var o=r.slot,a={children:l.createElement(l.Fragment,null,t.enableShortcuts&&l.createElement(y,{containerRef:r.containerRef,store:n}),l.createElement(E,{doc:r.doc,pagesRotation:r.pagesRotation,pageHeight:r.pageHeight,pageWidth:r.pageWidth,renderProgressBar:null==e?void 0:e.renderProgressBar,rotation:r.rotation,setPages:t.setPages,store:n}),o.children)};return s(s({},o),a)},Print:r,PrintButton:function(){return l.createElement(r,null,(function(e){return l.createElement(p,s({},e))}))},PrintMenuItem:function(e){return l.createElement(r,null,(function(t){return l.createElement(_,{onClick:function(){t.onClick(),e.onClick()}})}))},setPages:function(e){t.setPages=e}}}},91999:function(e,t,n){"use strict";e.exports=n(17302)},88700:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M12,1.001c6.075,0,11,4.925,11,11s-4.925,11-11,11s-11-4.925-11-11S5.925,1.001,12,1.001z\n            M14.5,17.005H13\n            c-0.552,0-1-0.448-1-1v-6.5c0-0.276-0.224-0.5-0.5-0.5H10\n            M11.745,6.504L11.745,6.504\n            M11.745,6.5c-0.138,0-0.25,0.112-0.25,0.25\n            S11.607,7,11.745,7s0.25-0.112,0.25-0.25S11.883,6.5,11.745,6.5"}))},i=function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},c=function(e){var t=e.doc,n=e.render,a=o.useState(),i=a[0],c=a[1];return o.useEffect((function(){t.getMetadata().then((function(e){return Promise.resolve(e)})).then((function(e){return t.getDownloadInfo().then((function(t){return Promise.resolve({fileName:e.contentDispositionFilename||"",info:e.info,length:t.length})}
1))})).then((function(e){c(e)}))}),[]),i?n(i):o.createElement("div",{className:"rpv-properties__loader"},o.createElement(r.Spinner,null))},l=function(e){var t=e.label,n=e.value,a=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft;return o.createElement("dl",{className:r.classNames({"rpv-properties__item":!0,"rpv-properties__item--rtl":a})},o.createElement("dt",{className:"rpv-properties__item-label"},t,":"),o.createElement("dd",{className:"rpv-properties__item-value"},n||"-"))},u=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"),s=function(e,t,n,r){var o=parseInt(e,10);return o>=t&&o<=n?o:r},d=function(e){var t=e.doc,n=e.fileName,a=e.onToggle,i=o.useContext(r.LocalizationContext).l10n,d=function(e){var t=function(e){var t=u.exec(e);if(!t)return null;var n=parseInt(t[1],10),r=s(t[2],1,12,1)-1,o=s(t[3],1,31,1),a=s(t[4],0,23,0),i=s(t[5],0,59,0),c=s(t[6],0,59,0),l=t[7]||"Z",d=s(t[8],0,23,0),p=s(t[9],0,59,0);switch(l){case"-":a+=d,i+=p;break;case"+":a-=d,i-=p}return new Date(Date.UTC(n,r,o,a,i,c))}(e);return t?"".concat(t.toLocaleDateString(),", ").concat(t.toLocaleTimeString()):""};return o.createElement("div",{className:"rpv-properties__modal"},o.createElement(c,{doc:t,render:function(e){return o.createElement(o.Fragment,null,o.createElement("div",{className:"rpv-properties__modal-section"},o.createElement(l,{label:i&&i.properties?i.properties.fileName:"File name",value:e.fileName||(u=n,s=u.split("/").pop(),s?s.split("#")[0].split("?")[0]:u)}),o.createElement(l,{label:i&&i.properties?i.properties.fileSize:"File size",value:(a=e.length,c=Math.floor(Math.log(a)/Math.log(1024)),"".concat((a/Math.pow(1024,c)).toFixed(2)," ").concat(["B","kB","MB","GB","TB"][c]))})),o.createElement(r.Separator,null),o.createElement("div",{className:"rpv-properties__modal-section"},o.createElement(l,{label:i&&i.properties?i.properties.title:"Title",value:e.info.Title}),o.createElement(l,{label:i&&i.properties?i.properties.author:"Author",value:e.info.Author}),o.createElement(l,{label:i&&i.properties?i.properties.subject:"Subject",value:e.info.Subject}),o.createElement(l,{label:i&&i.properties?i.properties.keywords:"Keywords",value:e.info.Keywords}),o.createElement(l,{label:i&&i.properties?i.properties.creator:"Creator",value:e.info.Creator}),o.createElement(l,{label:i&&i.properties?i.properties.creationDate:"Creation date",value:d(e.info.CreationDate)}),o.createElement(l,{label:i&&i.properties?i.properties.modificationDate:"Modification date",value:d(e.info.ModDate)})),o.createElement(r.Separator,null),o.createElement("div",{className:"rpv-properties__modal-section"},o.createElement(l,{label:i&&i.properties?i.properties.pdfProducer:"PDF producer",value:e.info.Producer}),o.createElement(l,{label:i&&i.properties?i.properties.pdfVersion:"PDF version",value:e.info.PDFFormatVersion}),o.createElement(l,{label:i&&i.properties?i.properties.pageCount:"Page count",value:"".concat(t.numPages)})));var a,c,u,s}}),o.createElement("div",{className:"rpv-properties__modal-footer"},o.createElement(r.Button,{onClick:a},i&&i.properties?i.properties.close:"Close")))},p={left:0,top:8},f=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,i=n&&n.properties?n.properties.showProperties:"Show properties";return o.createElement(r.Tooltip,{ariaControlsSuffix:"properties",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:i,testId:"properties__button",onClick:t},o.createElement(a,null)),content:function(){return i},offset:p})},m=function(e){var t=e.children,n=e.store,a=function(e){var t=o.useState(e.get("doc")),n=t[0],r=t[1],a=function(e){r(e)};return o.useEffect((function(){return e.subscribe("doc",a),function(){e.unsubscribe("doc",a)}}),[]),{currentDoc:n}}(n).currentDoc,c=n.get("fileName")||"",l=t||function(e){return o.createElement(f,i({},e))};return a?o.createElement(r.Modal,{ariaControlsSuffix:"properties",target:function(e){return l({onClick:e})},content:function(e){return o.createElement(d,{doc:a,fileName:c,onToggle:e})},closeOnClickOutside:!0,closeOnEscape:!0}):o.createElement(o.Fragment,null)},g=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,i=n&&n.properties?n.properties.showProperties:"Show properties";return o.createElement(r.MenuItem,{icon:o.createElement(a,null),testId:"properties__menu",onClick:t},i)};t.InfoIcon=a,t.propertiesPlugin=function(){var e=o.useMemo((function(){return r.createStore({fileName:""})}),[]),t=function(t){return o.createElement(m,i({},t,{store:e}))};return{onDocumentLoad:function(t){e.update("doc",t.doc)},onViewerStateChange:function(t){return e.update("fileName",t.file.name),t},ShowProperties:t,ShowPropertiesButton:function(){return o.createElement(m,{store:e})},ShowPropertiesMenuItem:function(e){return o.createElement(t,null,(function(e){return o.createElement(g,i({},e))}))}}}},12434:function(e,t,n){"use strict";e.exports=n(88700)},61779:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{ignoreDirection:!0,size:16},o.createElement("path",{d:"M3.434,10.537c0.141-0.438,0.316-0.864,0.523-1.274\n            M3.069,14.425C3.023,14.053,3,13.679,3,13.305 c0-0.291,0.014-0.579,0.041-0.863\n            M4.389,18.111c-0.341-0.539-0.623-1.112-0.843-1.711\n            M7.163,20.9 c-0.543-0.345-1.048-0.747-1.506-1.2\n            M10.98,22.248c-0.65-0.074-1.29-0.218-1.909-0.431\n            M10,4.25h2 c4.987,0.015,9.017,4.069,9.003,9.055c-0.013,4.581-3.456,8.426-8.008,8.945\n            M13.5,1.75L10,4.25l3.5,2.5"}))},i=function(){return o.createElement(r.Icon,{ignoreDirection:!0,size:16},o.createElement("path",{d:"M20.566,10.537c-0.141-0.438-0.316-0.864-0.523-1.274\n            M20.931,14.425C20.977,14.053,21,13.679,21,13.305 c0-0.291-0.014-0.579-0.041-0.863\n            M19.611,18.111c0.341-0.539,0.624-1.114,0.843-1.713\n            M16.837,20.9 c0.543-0.345,1.048-0.747,1.506-1.2\n            M13.02,22.248c0.65-0.074,1.29-0.218,1.909-0.431\n            M14,4.25h-2 c-4.987,0.015-9.017,4.069-9.003,9.055c0.013,4.581,3.456,8.426,8.008,8.945\n            M10.5,1.75l3.5,2.5l-3.5,2.5"}))},c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},c.apply(this,arguments)},l={left:0,top:8},u=function(e){var t=e.direction,n=e.onClick,c=o.useContext(r.LocalizationContext).l10n,u=c&&c.rotate?c.rotate.rotateBackward:"Rotate counterclockwise",s=c&&c.rotate?c.rotate.rotateForward:"Rotate clockwise",d=t===r.RotateDirection.Backward?u:s,p=t===r.RotateDirection.Backward?o.createElement(a,null):o.createElement(i,null);return o.createElement(r.Tooltip,{ariaControlsSuffix:"rotate",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:d,testId:t===r.RotateDirection.Backward?"rotate__backward-button":"rotate__forward-button",onClick:n},p),content:function(){return d},offset:l})},s=function(e){var t=e.children,n=e.direction,r=e.store;return(t||function(e){return o.createElement(u,{direction:e.direction,onClick:e.onClick})})({direction:n,onClick:function(){var e=r.get("rotate");e&&e(n)}})},d=function(e){var t=e.direction,n=e.onClick,c=o.useContext(r.LocalizationContext).l10n,l=c&&c.rotate?c.rotate.rotateBackward:"Rotate counterclockwise",u=c&&c.rotate?c.rotate.rotateForward:"Rotate clockwise",s=t===r.RotateDirection.Backward?l:u,d=t===r.RotateDirection.Backward?o.createElement(a,null):o.createElement(i,null);return o.createElement(r.MenuItem,{icon:d,testId:t===r.RotateDirection.Backward?"rotate__backward-menu":"rotate__forward-menu",onClick:n},s)},p=function(e){var t=e.children,n=e.store;return t({onRotatePage:function(e,t){var r=n.get("rotatePage");r&&r(e,t)}})};t.RotateBackwardIcon=a,t.RotateForwardIcon=i,t.rotatePlugin=function(){var e=o.useMemo((function(){return r.createStore()}),[]),t=function(t){return o.createElement(s,c({},t,{store:e}))};return{install:function(t){e.update("rotate",t.rotate),e.update("rotatePage",t.rotatePage)},Rotate:t,RotateBackwardButton:function(){return o.createElement(t,{direction:r.RotateDirection.Backward},(function(e){return o.createElement(u,c({},e))}))},RotateBackwardMenuItem:function(e){return o.createElement(t,{direction:r.RotateDirection.Backward},(function(t){return o.createElement(d,{direction:t.direction,onClick:function(){t.onClick(),e.onClick()}})}))},RotateForwardButton:function(){return o.createElement(t,{direction:r.RotateDirection.Forward},(function(e){return o.createElement(u,c({},e))}))},RotateForwardMenuItem:function(e){return o.createElement(t,{direction:r.RotateDirection.Forward},(function(t){return o.createElement(d,{direction:t.direction,onClick:function(){t.onClick(),e.onClick()}})}))},RotatePage:function(t){return o.createElement(p,c({},t,{store:e}))}}}},77719:function(e,t,n){"use strict";e.exports=n(61779)},87774:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M6.5,21.5c0,0.552-0.448,1-1,1h-4c-0.552,0-1-0.448-1-1v-20c0-0.552,0.448-1,1-1h4c0.552,0,1,0.448,1,1V21.5z\n            M14.5,21.5c0,0.552-0.448,1-1,1h-4c-0.552,0-1-0.448-1-1v-20c0-0.552,0.448-1,1-1h4c0.552,0,1,0.448,1,1V21.5z\n            M22.5,21.5 c0,0.552-0.448,1-1,1h-4c-0.552,0-1-0.448-1-1v-20c0-0.552,0.448-1,1-1h4c0.552,0,1,0.448,1,1V21.5z"}))},i=function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},c=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M23.5,5.5c0,0.552-0.448,1-1,1h-21c-0.552,0-1-0.448-1-1v-3c0-0.552,0.448-1,1-1h21c0.552,0,1,0.448,1,1V5.5z\n            M23.5,13.5c0,0.552-0.448,1-1,1h-21c-0.552,0-1-0.448-1-1v-3c0-0.552,0.448-1,1-1h21c0.552,0,1,0.448,1,1V13.5z\n            M23.5,21.5 c0,0.552-0.448,1-1,1h-21c-0.552,0-1-0.448-1-1v-3c0-0.552,0.448-1,1-1h21c0.552,0,1,0.448,1,1V21.5z"}))},l=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M10.5,9.5c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V9.5z\n            M23.5,9.5c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V9.5z\n            M10.5,22.5 c0,0.552-0.448,1-1,1h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V22.5z\n            M23.5,22.5c0,0.552-0.448,1-1,1 h-8c-0.552,0-1-0.448-1-1v-8c0-0.552,0.448-1,1-1h8c0.552,0,1,0.448,1,1V22.5z"}))},u=function(e){var t=e.children,n=e.mode,i=e.onClick,u=o.useContext(r.LocalizationContext).l10n,s="",d=o.createElement(c,null);switch(n){case r.ScrollMode.Horizontal:s=u&&u.scrollMode?u.scrollMode.horizontalScrolling:"Horizontal scrolling",d=o.createElement(a,null);break;case r.ScrollMode.Wrapped:s=u&&u.scrollMode?u.scrollMode.wrappedScrolling:"Wrapped scrolling",d=o.createElement(l,null);break;case r.ScrollMode.Vertical:default:s=u&&u.scrollMode?u.scrollMode.verticalScrolling:"Vertical scrolling",d=o.createElement(c,null)}return t({icon:d,label:s,onClick:i})},s={left:0,top:8},d=function(e){var t=e.isSelected,n=e.mode,a=e.onClick,i="";switch(n){case r.ScrollMode.Horizontal:i="scroll-mode__horizontal-button";break;case r.ScrollMode.Wrapped:i="scroll-mode__wrapped-button";break;case r.ScrollMode.Vertical:default:i="scroll-mode__vertical-button"}return o.createElement(u,{mode:n,onClick:a},(function(e){return o.createElement(r.Tooltip,{ariaControlsSuffix:"scroll-mode-switch",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:e.label,isSelected:t,testId:i,onClick:e.onClick},e.icon),content:function(){return e.label},offset:s})}))},p=function(e){var t=e.children,n=e.mode,a=e.store,i=function(e){var t=o.useState(e.get("scrollMode")||r.ScrollMode.Vertical),n=t[0],a=t[1],i=function(e){a(e)};return o.useEffect((function(){return e.subscribe("scrollMode",i),function(){e.unsubscribe("scrollMode",i)}}),[]),{scrollMode:n}}(a).scrollMode,c=i===n;return(t||function(e){return o.createElement(d,{isSelected:c,mode:e.mode,onClick:e.onClick})})({isSelected:c,mode:n,onClick:function(){a.get("switchScrollMode")(n)}})},f=function(e){var t=e.isSelected,n=e.mode,a=e.onClick,i="";switch(n){case r.ScrollMode.Horizontal:i="scroll-mode__horizontal-menu";break;case r.ScrollMode.Wrapped:i="scroll-mode__wrapped-menu";break;case r.ScrollMode.Vertical:default:i="scroll-mode__vertical-menu"}return o.createElement(u,{mode:n,onClick:a},(function(e){return o.createElement(r.MenuItem,{checked:t,icon:e.icon,testId:i,onClick:e.onClick},e.label)}))};t.HorizontalScrollingIcon=a,t.VerticalScrollingIcon=c,t.WrappedScrollingIcon=l,t.scrollModePlugin=function(){var e=o.useMemo((function(){return r.createStore({scrollMode:r.ScrollMode.Vertical,switchScrollMode:function(){}})}),[]),t=function(t){return o.createElement(p,i({},t,{store:e}))};return{install:function(t){e.update("switchScrollMode",t.switchScrollMode)},onViewerStateChange:function(t){return e.update("scrollMode",t.scrollMode),t},switchScrollMode:function(t){e.get("switchScrollMode")(t)},SwitchScrollMode:t,SwitchScrollModeButton:function(e){return o.createElement(t,{mode:e.mode},(function(e){return o.createElement(d,{isSelected:e.isSelected,mode:e.mode,onClick:function(){e.onClick()}})}))},SwitchScrollModeMenuItem:function(e){return o.createElement(t,{mode:e.mode},(function(t){return o.createElement(f,{isSelected:t.isSelected,mode:t.mode,onClick:function(){t.onClick(),e.onClick()}})}))}}}},64:function(e,t,n){"use strict";e.exports=n(87774)},67255:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M0.541,5.627L11.666,18.2c0.183,0.207,0.499,0.226,0.706,0.043c0.015-0.014,0.03-0.028,0.043-0.043\n            L23.541,5.627"}))},i=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M23.535,18.373L12.409,5.8c-0.183-0.207-0.499-0.226-0.706-0.043C11.688,5.77,11.674,5.785,11.66,5.8\n            L0.535,18.373"}))},c=function(){return o.createElement(r.Icon,{ignoreDirection:!0,size:16},o.createElement("path",{d:"M10.5,0.5c5.523,0,10,4.477,10,10s-4.477,10-10,10s-10-4.477-10-10S4.977,0.5,10.5,0.5z\n            M23.5,23.5\n            l-5.929-5.929"}))},l=function(){return l=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},l.apply(this,arguments)},u={keyword:"",regExp:new RegExp(" "),wholeWords:!1},s=function(e){return{left:"".concat(e.left,"%"),top:"".concat(e.top,"%"),height:"".concat(e.height,"%"),width:"".concat(e.width,"%")}},d=function(e){var t=e.index,n=e.area,a=e.onHighlightKeyword,i=o.useRef();return r.useIsomorphicLayoutEffect((function(){var e=i.current;a&&e&&a({highlightEle:e,keyword:n.keyword})}),[]),o.createElement("div",{className:"rpv-search__highlight","data-index":t,ref:i,style:s(n),title:n.keywordStr.trim()})},p=function(e){var t=e.parentNode;t&&t.removeChild(e)},f=function(e){var t=e.parentNode;if(t){var n=document.createRange();n.selectNodeContents(e),function(e,t){p(e);var n=t.parentNode;n&&n.insertBefore(e,t),p(t)}(n.extractContents(),e),t.normalize()}},m=function(e,t){return e.top<t.top?-1:e.top>t.top?1:e.left<t.left?-1:e.left>t.left?1:0},g=function(e){var t=e.numPages,n=e.pageIndex,a=e.renderHighlights,i=e.store,c=e.onHighlightKeyword,l=o.useRef(),p=o.useCallback((function(e){return o.createElement(o.Fragment,null,e.highlightAreas.map((function(e,t){return o.createElement(d,{index:t,key:t,area:e,onHighlightKeyword:c})})))}),[]),g=a||p,h=o.useState(i.get("matchPosition")),v=h[0],b=h[1],E=o.useState(i.get("keyword")||[u]),_=E[0],y=E[1],k=o.useState({pageIndex:n,scale:1,status:r.LayerRenderStatus.PreRender}),C=k[0],w=k[1],S=o.useRef(null),P=o.useRef([]),x=o.useState([]),M=x[0],R=x[1],L=function(){return!0},T=o.useCallback((function(){return i.get("targetPageFilter")||L}),[i.get("targetPageFilter")]),O=function(e){e&&e.length>0&&y(e)},I=function(e){return b(e)},D=function(e){if(e.has(n)){var t=e.get(n);t&&w({ele:t.ele,pageIndex:n,scale:t.scale,status:t.status})}},N=function(){return 0===_.length||1===_.length&&""===_[0].keyword.trim()};return o.useEffect((function(){if(!N()&&C.status===r.LayerRenderStatus.DidRender&&!P.current.length){var e=C.ele,t=[].slice.call(e.querySelectorAll(".rpv-core__text-layer-text")).map((function(e){return e.textContent})).reduce((function(e,t,n){return e.concat(t.split("").map((function(e,t){return{char:e,charIndexInSpan:t,spanIndex:n}})))}),[{char:"",charIndexInSpan:0,spanIndex:0}]).slice(1);P.current=t}}),[_,C.status]),o.useEffect((function(){if(!N()&&C.ele&&C.status===r.LayerRenderStatus.DidRender&&T()({pageIndex:n,numPages:t})){var e=function(e){var r=P.current;if(0===r.length)return[];var o=[],a=[].slice.call(e.querySelectorAll(".rpv-core__text-layer-text")),i=r.map((function(e){return e.char})).join("");return _.forEach((function(c){var l=c.keyword;if(l.trim()){for(var u,s=-1===c.regExp.flags.indexOf("g")?new RegExp(c.regExp,"".concat(c.regExp.flags,"g")):c.regExp,d=[];null!==(u=s.exec(i));)d.push({keyword:s,startIndex:u.index,endIndex:s.lastIndex});d.map((function(e){return{keyword:e.keyword,indexes:r.slice(e.startIndex,e.endIndex)}})).forEach((function(r){var i=r.indexes.reduce((function(e,t){return e[t.spanIndex]=(e[t.spanIndex]||[]).concat([t]),e}),{});
1Object.values(i).forEach((function(i){if(1!==i.length||""!==i[0].char.trim()){var u=c.wholeWords?i.slice(1,-1):i,s=function(e,r,o,a,i){var c=document.createRange(),l=a.firstChild;if(!l||l.nodeType!==Node.TEXT_NODE)return null;var u=l.textContent.length,s=i[0].charIndexInSpan,d=1===i.length?s:i[i.length-1].charIndexInSpan;if(s>u||d+1>u)return null;c.setStart(l,s),c.setEnd(l,d+1);var p=document.createElement("span");c.surroundContents(p);var m=p.getBoundingClientRect(),g=o.getBoundingClientRect(),h=g.height,v=g.width,b=100*(m.left-g.left)/v,E=100*(m.top-g.top)/h,_=100*m.height/h,y=100*m.width/v;return f(p),{keyword:r,keywordStr:e,numPages:t,pageIndex:n,left:b,top:E,height:_,width:y,pageHeight:h,pageWidth:v}}(l,r.keyword,e,a[u[0].spanIndex],u);s&&o.push(s)}}))}))}})),o.sort(m)}(C.ele);R(e)}}),[_,v,C.status,P.current]),o.useEffect((function(){N()&&C.ele&&C.status===r.LayerRenderStatus.DidRender&&R([])}),[_,C.status]),o.useEffect((function(){if(0!==M.length){var e=l.current;if(v.pageIndex===n&&e&&C.status===r.LayerRenderStatus.DidRender){var t=e.querySelector('.rpv-search__highlight[data-index="'.concat(v.matchIndex,'"]'));if(t){var o=function(e,t){for(var n=e.offsetTop,r=e.offsetLeft,o=e.parentElement;o&&o!==t;)n+=o.offsetTop,r+=o.offsetLeft,o=o.parentElement;return{left:r,top:n}}(t,e),a=o.left,c=o.top,u=i.get("jumpToDestination");u&&(u(n,(e.getBoundingClientRect().height-c)/C.scale,a/C.scale,C.scale),S.current&&S.current.classList.remove("rpv-search__highlight--current"),S.current=t,t.classList.add("rpv-search__highlight--current"))}}}}),[M,v]),o.useEffect((function(){return i.subscribe("keyword",O),i.subscribe("matchPosition",I),i.subscribe("renderStatus",D),function(){i.unsubscribe("keyword",O),i.unsubscribe("matchPosition",I),i.unsubscribe("renderStatus",D)}}),[]),o.createElement("div",{className:"rpv-search__highlights","data-testid":"search__highlights-".concat(n),ref:l},g({getCssProperties:s,highlightAreas:M}))},h=function(e){var t,n=e.wholeWords?" ".concat(e.keyword," "):e.keyword,r=e.matchCase?"g":"gi";return{keyword:e.keyword,regExp:new RegExp((t=n,t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")),r),wholeWords:e.wholeWords||!1}},v=function(e,t,n){return e instanceof RegExp?{keyword:e.source,regExp:e,wholeWords:n||!1}:"string"==typeof e?""===e?u:h({keyword:e,matchCase:t||!1,wholeWords:n||!1}):(void 0!==t&&(e.matchCase=t),void 0!==n&&(e.wholeWords=n),h(e))},b=function(e){var t,n=function(e){var t=o.useRef(e.get("doc")),n=function(e){t.current=e};return o.useEffect((function(){return e.subscribe("doc",n),function(){e.unsubscribe("doc",n)}}),[]),t}(e),a=o.useState([]),i=a[0],c=a[1],l=o.useState([]),s=l[0],d=l[1],p=o.useState(0),f=p[0],m=p[1],g=o.useState(!1),h=g[0],b=g[1],E=o.useRef([]),_=o.useState(!1),y=_[0],k=_[1],C=function(){return!0},w=o.useCallback((function(){return e.get("targetPageFilter")||C}),[e.get("targetPageFilter")]),S=function(e){var t=s.length;if(0===i.length||0===t)return null;var n=e===t+1?1:Math.max(1,Math.min(t,e));return m(n),x(s[n-1])},P=function(e){return c(""===e?[]:[e])},x=function(t){var n=e.get("jumpToPage");return n&&n(t.pageIndex),e.update("matchPosition",{matchIndex:t.matchIndex,pageIndex:t.pageIndex}),t},M=function(t,o,a){var i=n.current;if(!i)return Promise.resolve([]);var c=i.numPages,l=t.map((function(e){return v(e,o,a)}));return e.update("keyword",l),m(0),d([]),new Promise((function(e,t){var o=0===E.current.length?function(){var e=n.current;if(!e)return Promise.resolve([]);var t=Array(e.numPages).fill(0).map((function(t,n){return r.getPage(e,n).then((function(e){return e.getTextContent()})).then((function(e){var t=e.items.map((function(e){return e.str||""})).join("");return Promise.resolve({pageContent:t,pageIndex:n})}))}));return Promise.all(t).then((function(e){return e.sort((function(e,t){return e.pageIndex-t.pageIndex})),Promise.resolve(e.map((function(e){return e.pageContent})))}))}().then((function(e){return E.current=e,Promise.resolve(e)})):Promise.resolve(E.current);o.then((function(t){var n=[];t.forEach((function(e,t){w()({pageIndex:t,numPages:c})&&l.forEach((function(r){for(var o,a=0;null!==(o=r.regExp.exec(e));)n.push({keyword:r.regExp,matchIndex:a,pageIndex:t,pageText:e,startIndex:o.index,endIndex:r.regExp.lastIndex}),a++}))})),d(n),n.length>0&&(m(1),x(n[0])),e(n)}))}))};return o.useEffect((function(){E.current=[]}
1),[n.current]),{clearKeyword:function(){e.update("keyword",[u]),P(""),m(0),d([]),b(!1),k(!1)},changeMatchCase:function(e){b(e),i.length>0&&M(i,e,y)},changeWholeWords:function(e){k(e),i.length>0&&M(i,h,e)},currentMatch:f,jumpToMatch:S,jumpToNextMatch:function(){return S(f+1)},jumpToPreviousMatch:function(){return S(f-1)},keywords:i,matchCase:h,numberOfMatches:s.length,wholeWords:y,search:function(){return M(i,h,y)},searchFor:M,setKeywords:c,keyword:0===i.length?"":(t=i[0],t instanceof RegExp?t.source:"string"==typeof t?t:t.keyword),setKeyword:P,setTargetPages:function(t){e.update("targetPageFilter",t)}}},E=function(e){var t=e.children,n=e.store,r=b(n);return t(l({},r))},_=function(e){var t=e.containerRef,n=e.store,a=o.useRef(!1),i=function(){a.current=!0},c=function(){a.current=!1},l=function(e){var o=t.current;o&&(e.shiftKey||e.altKey||"f"!==e.key||(r.isMac()?e.metaKey&&!e.ctrlKey:e.ctrlKey)&&(a.current||document.activeElement&&o.contains(document.activeElement))&&(e.preventDefault(),n.update("areShortcutsPressed",!0)))};return o.useEffect((function(){var e=t.current;if(e)return document.addEventListener("keydown",l),e.addEventListener("mouseenter",i),e.addEventListener("mouseleave",c),function(){document.removeEventListener("keydown",l),e.removeEventListener("mouseenter",i),e.removeEventListener("mouseleave",c)}}),[t.current]),o.createElement(o.Fragment,null)},y={left:0,top:8},k=function(e){var t=e.store,n=e.onToggle,c=o.useContext(r.LocalizationContext).l10n,l=o.useContext(r.ThemeContext).direction,u=o.useState(!1),s=u[0],d=u[1],p=o.useState(!1),f=p[0],m=p[1],g=l===r.TextDirection.RightToLeft,h=b(t),v=h.clearKeyword,E=h.changeMatchCase,_=h.changeWholeWords,k=h.currentMatch,C=h.jumpToNextMatch,w=h.jumpToPreviousMatch,S=h.keyword,P=h.matchCase,x=h.numberOfMatches,M=h.wholeWords,R=h.search,L=h.setKeyword,T=c&&c.search?c.search.enterToSearch:"Enter to search",O=c&&c.search?c.search.previousMatch:"Previous match",I=c&&c.search?c.search.nextMatch:"Next match";return o.createElement("div",{className:"rpv-search__popover"},o.createElement("div",{className:"rpv-search__popover-input-counter"},o.createElement(r.TextBox,{ariaLabel:T,autoFocus:!0,placeholder:T,type:"text",value:S,onChange:function(e){m(!1),L(e)},onKeyDown:function(e){"Enter"===e.key&&S&&(f?C():(d(!0),R().then((function(e){d(!1),m(!0)}))))}}),o.createElement("div",{className:r.classNames({"rpv-search__popover-counter":!0,"rpv-search__popover-counter--ltr":!g,"rpv-search__popover-counter--rtl":g})},s&&o.createElement(r.Spinner,{testId:"search__popover-searching",size:"1rem"}),!s&&o.createElement("span",{"data-testid":"search__popover-num-matches"},k,"/",x))),o.createElement("label",{className:"rpv-search__popover-label"},o.createElement("input",{className:"rpv-search__popover-label-checkbox",checked:P,type:"checkbox",onChange:function(e){m(!1),E(e.target.checked)}})," ",c&&c.search?c.search.matchCase:"Match case"),o.createElement("label",{className:"rpv-search__popover-label"},o.createElement("input",{className:"rpv-search__popover-label-checkbox",checked:M,type:"checkbox",onChange:function(e){m(!1),_(e.target.checked)}})," ",c&&c.search?c.search.wholeWords:"Whole words"),o.createElement("div",{className:"rpv-search__popover-footer"},o.createElement("div",{className:"rpv-search__popover-footer-item"},o.createElement(r.Tooltip,{ariaControlsSuffix:"search-previous-match",position:g?r.Position.BottomRight:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:O,isDisabled:k<=1,onClick:w},o.createElement(i,null)),content:function(){return O},offset:y})),o.createElement("div",{className:"rpv-search__popover-footer-item"},o.createElement(r.Tooltip,{ariaControlsSuffix:"search-next-match",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:I,isDisabled:k>x-1,onClick:C},o.createElement(a,null)),content:function(){return I},offset:y})),o.createElement("div",{className:r.classNames({"rpv-search__popover-footer-button":!0,"rpv-search__popover-footer-button--ltr":!g,"rpv-search__popover-footer-button--rtl":g})},o.createElement(r.Button,{onClick:function(){n(),v()}},c&&c.search?c.search.close:"Close"))))},C=function(e){var t=e.children,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,i=a&&a.search?a.search.search:"Search";return t({icon:o.createElement(c,null),label:i,onClick:n})},w={left:0,top:8},S=function(e){var t=e.enableShortcuts,n=e.store,a=e.onClick,i=t?r.isMac()?"Meta+F":"Ctrl+F":"",c=function(e){e&&a()};return o.useEffect((function(){return n.subscribe("areShortcutsPressed",c),function(){n.unsubscribe("areShortcutsPressed",c)}}),[]),o.createElement(C,{onClick:a}
1,(function(e){return o.createElement(r.Tooltip,{ariaControlsSuffix:"search-popover",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaKeyShortcuts:i,ariaLabel:e.label,testId:"search__popover-button",onClick:a},e.icon),content:function(){return e.label},offset:w})}))},P={left:0,top:8},x=function(e){var t=e.children,n=e.enableShortcuts,a=e.store,i=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft?r.Position.BottomRight:r.Position.BottomLeft,c=t||function(e){return o.createElement(S,l({enableShortcuts:n,store:a},e))};return o.createElement(r.Popover,{ariaControlsSuffix:"search",lockScroll:!1,position:i,target:function(e){return c({onClick:e})},content:function(e){return o.createElement(k,{store:a,onToggle:e})},offset:P,closeOnClickOutside:!1,closeOnEscape:!0})},M=function(e){return Array.isArray(e)?e.map((function(e){return v(e)})):[v(e)]};t.NextIcon=a,t.PreviousIcon=i,t.SearchIcon=c,t.searchPlugin=function(e){var t=o.useMemo((function(){return Object.assign({},{enableShortcuts:!0,onHighlightKeyword:function(){}},e)}),[]),n=o.useMemo((function(){return r.createStore({matchPosition:{matchIndex:-1,pageIndex:-1},renderStatus:new Map,keyword:e&&e.keyword?M(e.keyword):[u]})}),[]),a=b(n),i=a.clearKeyword,c=a.jumpToMatch,s=a.jumpToNextMatch,d=a.jumpToPreviousMatch,p=a.searchFor,f=a.setKeywords,m=a.setTargetPages,h=function(e){return o.createElement(x,l({enableShortcuts:t.enableShortcuts},e,{store:n}))};return{install:function(t){var r=e&&e.keyword?M(e.keyword):[u];n.update("jumpToDestination",t.jumpToDestination),n.update("jumpToPage",t.jumpToPage),n.update("keyword",r)},renderPageLayer:function(r){return o.createElement(g,{key:r.pageIndex,numPages:r.doc.numPages,pageIndex:r.pageIndex,renderHighlights:null==e?void 0:e.renderHighlights,store:n,onHighlightKeyword:t.onHighlightKeyword})},renderViewer:function(e){var r=e.slot;return r.subSlot&&(r.subSlot.children=o.createElement(o.Fragment,null,t.enableShortcuts&&o.createElement(_,{containerRef:e.containerRef,store:n}),r.subSlot.children)),r},uninstall:function(e){var t=n.get("renderStatus");t&&t.clear()},onDocumentLoad:function(e){n.update("doc",e.doc)},onTextLayerRender:function(e){var t=n.get("renderStatus");t&&(t=t.set(e.pageIndex,e),n.update("renderStatus",t))},Search:function(e){return o.createElement(E,l({},e,{store:n}))},ShowSearchPopover:h,ShowSearchPopoverButton:function(){return o.createElement(h,null,(function(e){return o.createElement(S,l({enableShortcuts:t.enableShortcuts,store:n},e))}))},clearHighlights:function(){i()},highlight:function(e){var t=Array.isArray(e)?e:[e];return f(t),p(t)},jumpToMatch:c,jumpToNextMatch:s,jumpToPreviousMatch:d,setTargetPages:m}}},27973:function(e,t,n){"use strict";e.exports=n(67255)},51530:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o,a=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),i=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M11.5,5.5v-2C11.5,2.672,12.172,2,13,2s1.5,0.672,1.5,1.5v2 M14.5,11.5v-6C14.5,4.672,15.172,4,16,4\n            c0.828,0,1.5,0.672,1.5,1.5v3 M17.5,13V8.5C17.5,7.672,18.172,7,19,7s1.5,0.672,1.5,1.5v10c0,2.761-2.239,5-5,5h-3.335\n            c-1.712-0.001-3.305-0.876-4.223-2.321C6.22,18.467,4.083,14,4.083,14c-0.378-0.545-0.242-1.292,0.303-1.67\n            c0.446-0.309,1.044-0.281,1.458,0.07L8.5,15.5v-10C8.5,4.672,9.172,4,10,4s1.5,0.672,1.5,1.5v6"}))},c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},c.apply(this,arguments)};t.SelectionMode=void 0,(o=t.SelectionMode||(t.SelectionMode={})).Hand="Hand",o.Text="Text";var l=function(){return a.createElement(r.Icon,{size:16},a.createElement("path",{d:"M13.675,11.671l2.941-2.941c0.195-0.196,0.195-0.512-0.001-0.707C16.563,7.971,16.5,7.931,16.43,7.906\n            L4.168,3.527C3.908,3.434,3.622,3.57,3.529,3.83c-0.039,0.109-0.039,0.228,0,0.336l4.379,12.262\n            c0.
1093,0.26,0.379,0.396,0.639,0.303c0.07-0.025,0.133-0.065,0.185-0.117l2.943-2.943l6.146,6.146c0.195,0.195,0.512,0.195,0.707,0\n            l1.293-1.293c0.195-0.195,0.195-0.512,0-0.707L13.675,11.671z"}))},u=function(e){var n=e.children,o=e.mode,c=e.onClick,u=a.useContext(r.LocalizationContext).l10n,s="",d=a.createElement(l,null);switch(o){case t.SelectionMode.Hand:s=u&&u.selectionMode?u.selectionMode.handTool:"Hand tool",d=a.createElement(i,null);break;case t.SelectionMode.Text:default:s=u&&u.selectionMode?u.selectionMode.textSelectionTool:"Text selection tool",d=a.createElement(l,null)}return n({icon:d,label:s,onClick:c})},s={left:0,top:8},d=function(e){var n=e.isSelected,o=e.mode,i=e.onClick,c="";switch(o){case t.SelectionMode.Hand:c="selection-mode__hand-button";break;case t.SelectionMode.Text:default:c="selection-mode__text-button"}return a.createElement(u,{mode:o,onClick:i},(function(e){return a.createElement(r.Tooltip,{ariaControlsSuffix:"selection-mode-switch",position:r.Position.BottomCenter,target:a.createElement(r.MinimalButton,{ariaLabel:e.label,isSelected:n,testId:c,onClick:e.onClick},e.icon),content:function(){return e.label},offset:s})}))},p=function(e){var t=e.children,n=e.mode,r=e.store,o=n===r.get("selectionMode");return(t||function(e){return a.createElement(d,{isSelected:o,mode:e.mode,onClick:e.onClick})})({isSelected:o,mode:n,onClick:function(){return r.update("selectionMode",n)}})},f=function(e){var n=e.isSelected,o=e.mode,i=e.onClick,c="";switch(o){case t.SelectionMode.Hand:c="selection-mode__hand-menu";break;case t.SelectionMode.Text:default:c="selection-mode__text-menu"}return a.createElement(u,{mode:o,onClick:i},(function(e){return a.createElement(r.MenuItem,{checked:n,icon:e.icon,testId:c,onClick:e.onClick},e.label)}))},m=function(e){var n=e.store,r=a.useRef(null),o=a.useState(t.SelectionMode.Text),i=o[0],c=o[1],l=a.useRef({top:0,left:0,x:0,y:0}),u=function(e){var t=r.current;t&&(t.scrollTop=l.current.top-(e.clientY-l.current.y),t.scrollLeft=l.current.left-(e.clientX-l.current.x))},s=function(){var e=r.current;e&&(e.classList.add("rpv-selection-mode__grab"),e.classList.remove("rpv-selection-mode__grabbing"),document.removeEventListener("mousemove",u),document.removeEventListener("mouseup",s))},d=function(e){var n=r.current;n&&i!==t.SelectionMode.Text&&(n.classList.remove("rpv-selection-mode__grab"),n.classList.add("rpv-selection-mode__grabbing"),e.preventDefault(),e.stopPropagation(),l.current={left:n.scrollLeft,top:n.scrollTop,x:e.clientX,y:e.clientY},document.addEventListener("mousemove",u),document.addEventListener("mouseup",s))},p=function(e){r.current=e()},f=function(e){c(e)};return a.useEffect((function(){var e=r.current;if(e)return i===t.SelectionMode.Hand?e.classList.add("rpv-selection-mode__grab"):e.classList.remove("rpv-selection-mode__grab"),e.addEventListener("mousedown",d),function(){e.removeEventListener("mousedown",d)}}),[i]),a.useEffect((function(){return n.subscribe("getPagesContainer",p),n.subscribe("selectionMode",f),function(){n.unsubscribe("getPagesContainer",p),n.unsubscribe("selectionMode",f)}}),[]),a.createElement(a.Fragment,null)};t.HandToolIcon=i,t.TextSelectionIcon=l,t.selectionModePlugin=function(e){var n=a.useMemo((function(){return r.createStore()}),[]),o=function(e){return a.createElement(p,c({},e,{store:n}))};return{install:function(r){n.update("selectionMode",e&&e.selectionMode?e.selectionMode:t.SelectionMode.Text),n.update("getPagesContainer",r.getPagesContainer)},renderViewer:function(e){var t=e.slot;return t.subSlot&&t.subSlot.children&&(t.subSlot.children=a.createElement(a.Fragment,null,a.createElement(m,{store:n}),t.subSlot.children)),t},SwitchSelectionMode:o,SwitchSelectionModeButton:function(e){return a.createElement(o,{mode:e.mode},(function(e){return a.createElement(d,{isSelected:e.isSelected,mode:e.mode,onClick:function(){e.onClick()}})}))},SwitchSelectionModeMenuItem:function(e){return a.createElement(o,{mode:e.mode},(function(t){return a.createElement(f,{isSelected:t.isSelected,mode:t.mode,onClick:function(){t.onClick(),e.onClick()}})}))}}}},53403:function(e,t,n){"use strict";e.exports=n(51530)},98835:function(e,t,n){"use strict";
1Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M19.5,15.106l2.4-2.4a1,1,0,0,0,0-1.414l-2.4-2.4V5.5a1,1,0,0,0-1-1H15.106l-2.4-2.4a1,1,0,0,0-1.414,0l-2.4,2.4H5.5a1,1,0,0,0-1,1V8.894l-2.4,2.4a1,1,0,0,0,0,1.414l2.4,2.4V18.5a1,1,0,0,0,1,1H8.894l2.4,2.4a1,1,0,0,0,1.414,0l2.4-2.4H18.5a1,1,0,0,0,1-1Z"}),o.createElement("path",{d:"M10,6.349a6,6,0,0,1,0,11.3,6,6,0,1,0,0-11.3Z"}))},i=function(){return o.createElement(r.Icon,{size:16},o.createElement("path",{d:"M19.491,15.106l2.4-2.4a1,1,0,0,0,0-1.414l-2.4-2.4V5.5a1,1,0,0,0-1-1H15.1L12.7,2.1a1,1,0,0,0-1.414,0l-2.4,2.4H5.491a1,1,0,0,0-1,1V8.894l-2.4,2.4a1,1,0,0,0,0,1.414l2.4,2.4V18.5a1,1,0,0,0,1,1H8.885l2.4,2.4a1,1,0,0,0,1.414,0l2.4-2.4h3.394a1,1,0,0,0,1-1Z"}),o.createElement("path",{d:"M11.491,6c4,0,6,2.686,6,6s-2,6-6,6Z"}))},c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},c.apply(this,arguments)},l={left:0,top:8},u=function(e){var t=e.onClick,n=o.useContext(r.ThemeContext),c=o.useContext(r.LocalizationContext).l10n,u="dark"===n.currentTheme,s=c&&c.theme?u?c.theme.switchLightTheme:c.theme.switchDarkTheme:u?"Switch to the light theme":"Switch to the dark theme";return o.createElement(r.Tooltip,{ariaControlsSuffix:"theme-switch",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaLabel:s,testId:"theme__switch-button",onClick:t},u?o.createElement(i,null):o.createElement(a,null)),content:function(){return s},offset:l})},s=function(e){var t=e.children,n=o.useContext(r.ThemeContext);return(t||function(e){return o.createElement(u,{onClick:e.onClick})})({onClick:function(){return n.setCurrentTheme("dark"===n.currentTheme?"light":"dark")}})},d=function(e){var t=e.onClick,n=o.useContext(r.ThemeContext),c=o.useContext(r.LocalizationContext).l10n,l="dark"===n.currentTheme,u=c&&c.theme?l?c.theme.switchLightTheme:c.theme.switchDarkTheme:l?"Switch to the light theme":"Switch to the dark theme";return o.createElement(r.MenuItem,{icon:l?o.createElement(i,null):o.createElement(a,null),testId:"theme__switch-menu",onClick:t},u)};t.DarkIcon=a,t.LightIcon=i,t.themePlugin=function(){var e=function(e){return o.createElement(s,c({},e))};return{SwitchTheme:e,SwitchThemeButton:function(){return o.createElement(e,null,(function(e){return o.createElement(u,c({},e))}))},SwitchThemeMenuItem:function(t){return o.createElement(e,null,(function(e){return o.createElement(d,{onClick:function(){e.onClick(),t.onClick()}})}))}}}},3591:function(e,t,n){"use strict";e.exports=n(98835)},68786:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return a=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},a.apply(this,arguments)},i=function(e){var t=e.getPageIndex,n=e.renderSpinner,a=e.doc,i=o.useState(""),c=i[0],l=i[1],u=r.useIsMounted(),s=o.useRef(),d=r.useIntersectionObserver({onVisibilityChanged:function(e){if(!c&&e.isVisible){var n=d.current;if(n){var o=a.numPages,i=t?t({numPages:o}):0,p=Math.max(0,Math.min(i,o-1));r.getPage(a,p).then((function(e){var t=e.getViewport({scale:1}),r=t.width,o=t.height,a=document.createElement("canvas"),i=a.getContext("2d",{alpha:!1}),c=n.clientWidth,d=n.clientHeight,p=Math.min(c/r,d/o),f=p*r,m=p*o;a.height=m,a.width=f,a.style.opacity="0";var g=e.getViewport({rotation:0,scale:p});s.current=e.render({canvasContext:i,viewport:g}),s.current.promise.then((function(){u.current&&l(a.toDataURL()),a.width=0,a.height=0}),(function(){}))}))}}}});return o.useEffect((function(){return function(){var e;null===(e=s.current)||void 0===e||e.cancel()}}),[]),c?o.createElement("img",{className:"rpv-thumbnail__cover-image","data-testid":"thumbnail__cover-image",src:c}):o.createElement("div",{className:"rpv-thumbnail__cover-loader","data-testid":"thumbnail__cover-loader",ref:d},n?n():o.createElement(r.Spinner,null))},c=function(e){var t=e.getPageIndex,n=e.renderSpinner,a=e.store,c=o.useState(a.get("doc")),l=c[0],u=c[1],s=function(e){u(e)};return o.useEffect((function(){return a.subscribe("doc",s),function(){a.unsubscribe("doc",s)}}),[]),o.createElement("div",{className:"rpv-thumbnail__cover"}
1,l?o.createElement(i,{doc:l,getPageIndex:t,renderSpinner:n}):o.createElement("div",{className:"rpv-thumbnail__cover-loader"},n?n():o.createElement(r.Spinner,null)))},l=function(){return o.createElement(r.Spinner,null)},u=o.createContext({renderSpinner:l}),s=function(e){var t=e.children,n=e.doc,a=r.useIsMounted(),i=o.useState({loading:!0,labels:[]}),c=i[0],l=i[1];return o.useEffect((function(){n.getPageLabels().then((function(e){a.current&&l({loading:!1,labels:e||[]})}))}),[n.loadingTask.docId]),c.loading?o.createElement(o.Fragment,null):t(c.labels)},d=function(e){var t=e.page,n=e.pageHeight,a=e.pageIndex,i=e.pageWidth,c=e.rotation,l=e.thumbnailHeight,s=e.thumbnailWidth,d=e.onRenderCompleted,p=o.useContext(r.LocalizationContext).l10n,f=o.useRef(),m=o.useState(""),g=m[0],h=m[1],v=p&&p.thumbnail?p.thumbnail.thumbnailLabel:"Thumbnail of page {{pageIndex}}";return o.useEffect((function(){var e=f.current;e&&e.cancel();var r=document.createElement("canvas"),o=r.getContext("2d",{alpha:!1}),l=s,u=l/(i/n),p=l/i;r.height=u,r.width=l,r.style.height="".concat(u,"px"),r.style.width="".concat(l,"px");var m=t.getViewport({rotation:c,scale:p});return f.current=t.render({canvasContext:o,viewport:m}),f.current.promise.then((function(){h(r.toDataURL()),d(a)}),(function(){d(a)})),function(){var e;null===(e=f.current)||void 0===e||e.cancel()}}),[c]),g?o.createElement("img",{"aria-label":v.replace("{{pageIndex}}","".concat(a+1)),src:g,height:"".concat(l,"px"),width:"".concat(s,"px")}):o.useContext(u).renderSpinner()},p=function(e){var t=e.doc,n=e.pageHeight,a=e.pageIndex,i=e.pageRotation,c=e.pageWidth,l=e.rotation,s=e.shouldRender,p=e.thumbnailWidth,f=e.onRenderCompleted,m=e.onVisibilityChanged,g=r.useIsMounted(),h=o.useState({height:n,page:null,viewportRotation:0,width:c}),v=h[0],b=h[1],E=v.page,_=v.height,y=v.width,k=y/_,C=Math.abs(l+i)%180==0,w=C?p:p/k,S=C?p/k:p;o.useEffect((function(){s&&r.getPage(t,a).then((function(e){var t=e.getViewport({scale:1});g.current&&b({height:t.height,page:e,viewportRotation:t.rotation,width:t.width})}))}),[s]);var P=(v.viewportRotation+l+i)%360,x=r.useIntersectionObserver({onVisibilityChanged:function(e){m(a,e)}});return o.createElement("div",{className:"rpv-thumbnail__container","data-testid":"thumbnail__container-".concat(a),ref:x,style:{height:"".concat(S,"px"),width:"".concat(w,"px")}},E?o.createElement(d,{page:E,pageHeight:C?_:y,pageIndex:a,pageWidth:C?y:_,rotation:P,thumbnailHeight:S,thumbnailWidth:w,onRenderCompleted:f}):o.useContext(u).renderSpinner())},f=function(e){var t=e.currentPage,n=e.doc,a=e.labels,i=e.pagesRotation,c=e.pageHeight,l=e.pageWidth,u=e.renderCurrentPageLabel,s=e.renderThumbnailItem,d=e.rotatedPage,f=e.rotation,m=e.thumbnailWidth,g=e.onJumpToPage,h=e.onRotatePage,v=n.numPages,b=n.loadingTask.docId,E=o.useRef(null),_=o.useRef([]),y=o.useState(t),k=y[0],C=y[1],w=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,S=o.useState(-1),P=S[0],x=S[1],M=r.useIsMounted(),R=o.useRef(!1),L=r.useRenderQueue({doc:n}),T=o.useMemo((function(){return Array(v).fill(0).map((function(e,t){return t}))}),[b]);r.useIsomorphicLayoutEffect((function(){var e=E.current;e&&(_.current=Array.from(e.querySelectorAll(".rpv-thumbnail__item")))}),[]),o.useEffect((function(){var e=_.current;if(!(0===e.length||k<0||k>e.length)){var t=e[k];t.setAttribute("tabindex","0"),t.focus()}}),[k]),r.useIsomorphicLayoutEffect((function(){var e=E.current;if(e){var n=e.children;t<n.length&&function(e,t){var n=e.getBoundingClientRect().top-t.getBoundingClientRect().top,r=e.clientHeight,o=t.clientHeight;n<0?t.scrollTop+=n:n+r<=o||(t.scrollTop+=n+r-o)}(n.item(t),e)}}),[t]);var O=o.useCallback((function(e){M.current&&(L.markRendered(e),R.current=!1,D())}),[b]),I=o.useCallback((function(e,t){t.isVisible?L.setVisibility(e,t.ratio):L.setOutOfRange(e),D()}),[b]),D=o.useCallback((function(){if(!R.current){var e=L.getHighestPriorityPage();e>-1&&(L.markRendering(e),R.current=!0,x(e))}}),[b]);return o.useEffect((function(){d>=0&&(L.markRendering(d),R.current=!0,x(d))}),[b,d]),o.createElement("div",{ref:E,"data-testid":"thumbnail__list",className:r.classNames({"rpv-thumbnail__list":!0,"rpv-thumbnail__list--rtl":w}),onKeyDown:function(e){switch(e.key){case"ArrowDown":!function(){if(E.current){var e=_.current,t=k+1;t<e.length&&(k>=0&&e[k].setAttribute("tabindex","-1"),C(t))}}();break;case"ArrowUp":!function(){if(E.current){var e=_.current,t=k-1;t>=0&&(k>=0&&e[k].setAttribute("tabindex","-1"),C(t))}}();break;case"Enter":k>=0&&k<v&&g(k)}}},T.map((function(e){var d="".concat(n.loadingTask.docId,"___").concat(e),b=a.length===v?a[e]:"".concat(e+1),E=u?u({currentPage:t,pageIndex:e,numPages:v,pageLabel:b}):b,_=i.has(e)?i.get(e):0,y=o.createElement(p,{doc:n,pageHeight:c,pageIndex:e,pageRotation:_,pageWidth:l,rotation:f,shouldRender:P===e,thumbnailWidth:m,onRenderCompleted:O,onVisibilityChanged:I});return s?s({currentPage:t,key:d,numPages:v,pageIndex:e,renderPageLabel:o.createElement(o.Fragment,null,E),renderPageThumbnail:y,onJumpToPage:function(){return g(e)},onRotatePage:function(t){return h(e,t)}}):o.createElement("div",{key:d},o.createElement("div",{className:r.classNames({"rpv-thumbnail__item":!0,"rpv-thumbnail__item--selected":t===e}),role:"button",tabIndex:t===e?0:-1,onClick:function(){return g(e)}},y),o.createElement("div",{"data-testid":"thumbnail__label-".concat(e),className:"rpv-thumbnail__label"},E))})))},m=function(e){var t=e.renderCurrentPageLabel,n=e.renderThumbnailItem,a=e.store,i=e.thumbnailWidth,c=o.use
1State(a.get("doc")),l=c[0],d=c[1],p=o.useState(a.get("currentPage")||0),m=p[0],g=p[1],h=o.useState(a.get("pageHeight")||0),v=h[0],b=h[1],E=o.useState(a.get("pageWidth")||0),_=E[0],y=E[1],k=o.useState(a.get("rotation")||0),C=k[0],w=k[1],S=o.useState(a.get("pagesRotation")||new Map),P=S[0],x=S[1],M=o.useState(a.get("rotatedPage")||-1),R=M[0],L=M[1],T=function(e){g(e)},O=function(e){d(e)},I=function(e){b(e)},D=function(e){y(e)},N=function(e){w(e)},z=function(e){x(e)},F=function(e){L(e)},j=function(e){var t=a.get("jumpToPage");t&&t(e)},B=function(e,t){a.get("rotatePage")(e,t)};return o.useEffect((function(){return a.subscribe("doc",O),a.subscribe("pageHeight",I),a.subscribe("pageWidth",D),a.subscribe("rotatedPage",F),a.subscribe("rotation",N),a.subscribe("pagesRotation",z),function(){a.unsubscribe("doc",O),a.unsubscribe("pageHeight",I),a.unsubscribe("pageWidth",D),a.unsubscribe("rotatedPage",F),a.unsubscribe("rotation",N),a.unsubscribe("pagesRotation",z)}}),[]),r.useIsomorphicLayoutEffect((function(){return a.subscribe("currentPage",T),function(){a.unsubscribe("currentPage",T)}}),[]),l?o.createElement(r.LazyRender,{testId:"thumbnail__list-container",attrs:{className:"rpv-thumbnail__list-container"}},o.createElement(s,{doc:l},(function(e){return o.createElement(f,{currentPage:m,doc:l,labels:e,pagesRotation:P,pageHeight:v,pageWidth:_,renderCurrentPageLabel:t,renderThumbnailItem:n,rotatedPage:R,rotation:C,thumbnailWidth:i,onJumpToPage:j,onRotatePage:B})}))):o.createElement("div",{"data-testid":"thumbnail-list__loader",className:"rpv-thumbnail__loader"},o.useContext(u).renderSpinner())};t.thumbnailPlugin=function(e){var t=o.useMemo((function(){return r.createStore({rotatePage:function(){}})}),[]),n=o.useState(""),i=n[0],s=n[1];return{install:function(e){t.update("jumpToPage",e.jumpToPage),t.update("rotatePage",e.rotatePage)},onDocumentLoad:function(e){s(e.doc.loadingTask.docId),t.update("doc",e.doc)},onViewerStateChange:function(e){return t.update("currentPage",e.pageIndex),t.update("pagesRotation",e.pagesRotation),t.update("pageHeight",e.pageHeight),t.update("pageWidth",e.pageWidth),t.update("rotation",e.rotation),t.update("rotatedPage",e.rotatedPage),e},Cover:function(n){return o.createElement(c,a({},n,{renderSpinner:null==e?void 0:e.renderSpinner,store:t}))},Thumbnails:o.useCallback((function(n){return o.createElement(u.Provider,{value:{renderSpinner:(null==e?void 0:e.renderSpinner)||l}},o.createElement(m,{renderCurrentPageLabel:null==e?void 0:e.renderCurrentPageLabel,renderThumbnailItem:null==n?void 0:n.renderThumbnailItem,store:t,thumbnailWidth:(null==e?void 0:e.thumbnailWidth)||100}))}),[i])}}},24416:function(e,t,n){"use strict";e.exports=n(68786)},93945:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141),o=n(53403),a=n(67294),i=n(74948),c=n(48448),l=n(50007),u=n(13572),s=n(91999),d=n(12434),p=n(77719),f=n(64),m=n(27973),g=n(3591),h=n(60440);var v=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(a),b=function(){return v.createElement(r.Icon,{size:16},v.createElement("path",{d:"M12,0.5c1.381,0,2.5,1.119,2.5,2.5S13.381,5.5,12,5.5S9.5,4.381,9.5,3S10.619,0.5,12,0.5z\n            M12,9.5\n            c1.381,0,2.5,1.119,2.5,2.5s-1.119,2.5-2.5,2.5S9.5,13.381,9.5,12S10.619,9.5,12,9.5z\n            M12,18.5c1.381,0,2.5,1.119,2.5,2.5\n            s-1.119,2.5-2.5,2.5S9.5,22.381,9.5,21S10.619,18.5,12,18.5z"}))},E={left:0,top:8},_=function(e){var t=e.toolbarSlot,n=v.useContext(r.LocalizationContext).l10n,a=v.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft?r.Position.BottomLeft:r.Position.BottomRight,i=t.DownloadMenuItem,c=t.EnterFullScreenMenuItem,l=t.GoToFirstPageMenuItem,u=t.GoToLastPageMenuItem,s=t.GoToNextPageMenuItem,d=t.GoToPreviousPageMenuItem,p=t.OpenMenuItem,f=t.PrintMenuItem,m=t.RotateBackwardMenuItem,g=t.RotateForwardMenuItem,h=t.ShowPropertiesMenuItem,_=t.SwitchScrollModeMenuItem,y=t.SwitchSelectionModeMenuItem,k=t.SwitchThemeMenuItem;
1return v.createElement(r.Popover,{ariaControlsSuffix:"toolbar-more-actions",ariaHasPopup:"menu",position:a,target:function(e,t){var o=n&&n.toolbar?n.toolbar.moreActions:"More actions";return v.createElement(r.Tooltip,{ariaControlsSuffix:"toolbar-more-actions",position:a,target:v.createElement(r.MinimalButton,{ariaLabel:o,isSelected:t,testId:"toolbar__more-actions-popover-target",onClick:e},v.createElement(b,null)),content:function(){return o},offset:E})},content:function(e){return v.createElement(r.Menu,null,v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(k,{onClick:e})),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(c,{onClick:e})),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(p,null)),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(f,{onClick:e})),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(i,{onClick:e})),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(r.MenuDivider,null)),v.createElement(l,{onClick:e}),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(d,{onClick:e})),v.createElement("div",{className:"rpv-core__display--block rpv-core__display--hidden-medium"},v.createElement(s,{onClick:e})),v.createElement(u,{onClick:e}),v.createElement(r.MenuDivider,null),v.createElement(g,{onClick:e}),v.createElement(m,{onClick:e}),v.createElement(r.MenuDivider,null),v.createElement(y,{mode:o.SelectionMode.Text,onClick:e}),v.createElement(y,{mode:o.SelectionMode.Hand,onClick:e}),v.createElement(r.MenuDivider,null),v.createElement(_,{mode:r.ScrollMode.Vertical,onClick:e}),v.createElement(_,{mode:r.ScrollMode.Horizontal,onClick:e}),v.createElement(_,{mode:r.ScrollMode.Wrapped,onClick:e}),v.createElement(r.MenuDivider,null),v.createElement(h,{onClick:e}))},offset:E,closeOnClickOutside:!0,closeOnEscape:!0})},y=function(){return y=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},y.apply(this,arguments)},k=function(e){return function(t){var n=v.useMemo((function(){return e(t)}),[]),o=v.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,a=n.CurrentPageInput,i=n.Download,c=n.EnterFullScreen,l=n.GoToNextPage,u=n.GoToPreviousPage,s=n.NumberOfPages,d=n.Open,p=n.Print,f=n.ShowSearchPopover,m=n.SwitchTheme,g=n.Zoom,h=n.ZoomIn,b=n.ZoomOut;return v.createElement("div",{"data-testid":"toolbar",className:r.classNames({"rpv-toolbar":!0,"rpv-toolbar--rtl":o}),role:"toolbar","aria-orientation":"horizontal"},v.createElement("div",{className:"rpv-toolbar__left"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(f,null)),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-small"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(u,null))),v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(a,null),v.createElement("span",{className:"rpv-toolbar__label"},v.createElement(s,null))),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-small"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(l,null)))),v.createElement("div",{className:"rpv-toolbar__center"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(b,null)),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-small"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(g,null))),v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(h,null))),v.createElement("div",{className:"rpv-toolbar__right"},v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-medium"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(m,null))),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-medium"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(c,null))),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-medium"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(d,null))),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-medium"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(i,null))),v.createElement("div",{className:"rpv-core__display--hidden rpv-core__display--block-medium"},v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(p,null))),v.createElement("div",{className:"rpv-toolbar__item"},v.createElement(_,{toolbarSlot:n}))))}},C=function(e){var t=e.NumberOfPages;return Object.assign({},e,{NumberOfPages:function(){return v.createElement(v.Fragment,null,"/ ",v.createElement(t,null))}})},w=function(e){return k(C)(e)},S=function(e){var t=e.children,n=e.slot;return(t||w)(n)};
1t.MoreActionsPopover=_,t.MoreIcon=b,t.toolbarPlugin=function(e){var t=i.fullScreenPlugin(e?e.fullScreenPlugin:{}),n=c.getFilePlugin(e?e.getFilePlugin:{}),r=l.openPlugin(e?e.openPlugin:{}),a=u.pageNavigationPlugin(e?e.pageNavigationPlugin:{}),b=s.printPlugin(e?e.printPlugin:{}),E=d.propertiesPlugin(),_=p.rotatePlugin(),C=f.scrollModePlugin(),w=m.searchPlugin(e?e.searchPlugin:{}),P=o.selectionModePlugin(e?e.selectionModePlugin:{}),x=g.themePlugin(),M=h.zoomPlugin(e?e.zoomPlugin:{}),R=[t,n,r,a,b,E,_,C,w,P,x,M],L=v.useCallback((function(e){var o=t.EnterFullScreen,i=t.EnterFullScreenMenuItem,c=n.Download,l=n.DownloadMenuItem,u=r.Open,s=r.OpenMenuItem,d=a.CurrentPageInput,p=a.CurrentPageLabel,f=a.GoToFirstPage,m=a.GoToFirstPageMenuItem,g=a.GoToLastPage,h=a.GoToLastPageMenuItem,k=a.GoToNextPage,R=a.GoToNextPageMenuItem,L=a.GoToPreviousPage,T=a.GoToPreviousPageMenuItem,O=a.NumberOfPages,I=b.Print,D=b.PrintMenuItem,N=E.ShowProperties,z=E.ShowPropertiesMenuItem,F=_.Rotate,j=_.RotateBackwardMenuItem,B=_.RotateForwardMenuItem,A=C.SwitchScrollMode,H=C.SwitchScrollModeMenuItem,V=w.Search,W=w.ShowSearchPopover,U=P.SwitchSelectionMode,Z=P.SwitchSelectionModeMenuItem,K=x.SwitchTheme,G=x.SwitchThemeMenuItem,q=M.CurrentScale,J=M.Zoom,Y=M.ZoomIn,Q=M.ZoomInMenuItem,X=M.ZoomOut,$=M.ZoomOutMenuItem;return v.createElement(S,y({},e,{slot:{CurrentPageInput:d,CurrentPageLabel:p,CurrentScale:q,Download:c,DownloadMenuItem:l,EnterFullScreen:o,EnterFullScreenMenuItem:i,GoToFirstPage:f,GoToFirstPageMenuItem:m,GoToLastPage:g,GoToLastPageMenuItem:h,GoToNextPage:k,GoToNextPageMenuItem:R,GoToPreviousPage:L,GoToPreviousPageMenuItem:T,NumberOfPages:O,Open:u,OpenMenuItem:s,Print:I,PrintMenuItem:D,Rotate:F,RotateBackwardMenuItem:j,RotateForwardMenuItem:B,Search:V,ShowProperties:N,ShowPropertiesMenuItem:z,ShowSearchPopover:W,SwitchScrollMode:A,SwitchScrollModeMenuItem:H,SwitchSelectionMode:U,SwitchSelectionModeMenuItem:Z,SwitchTheme:K,SwitchThemeMenuItem:G,Zoom:J,ZoomIn:Y,ZoomInMenuItem:Q,ZoomOut:X,ZoomOutMenuItem:$}}))}),[]);return{fullScreenPluginInstance:t,getFilePluginInstance:n,openPluginInstance:r,pageNavigationPluginInstance:a,printPluginInstance:b,propertiesPluginInstance:E,rotatePluginInstance:_,scrollModePluginInstance:C,searchPluginInstance:w,selectionModePluginInstance:P,themePluginInstance:x,zoomPluginInstance:M,install:function(e){R.forEach((function(t){t.install&&t.install(e)}))},renderPageLayer:function(e){return v.createElement(v.Fragment,null,R.map((function(t,n){return t.renderPageLayer?v.createElement(v.Fragment,{key:n},t.renderPageLayer(e)):v.createElement(v.Fragment,{key:n})})))},renderViewer:function(e){var t=e.slot;return R.forEach((function(n){n.renderViewer&&(t=n.renderViewer(y(y({},e),{slot:t})))})),t},uninstall:function(e){R.forEach((function(t){t.uninstall&&t.uninstall(e)}))},onDocumentLoad:function(e){R.forEach((function(t){t.onDocumentLoad&&t.onDocumentLoad(e)}))},onAnnotationLayerRender:function(e){R.forEach((function(t){t.onAnnotationLayerRender&&t.onAnnotationLayerRender(e)}))},onTextLayerRender:function(e){R.forEach((function(t){t.onTextLayerRender&&t.onTextLayerRender(e)}))},onViewerStateChange:function(e){var t=e;return R.forEach((function(e){e.onViewerStateChange&&(t=e.onViewerStateChange(t))})),t},renderDefaultToolbar:k,Toolbar:L}}},85734:function(e,t,n){"use strict";e.exports=n(93945)},61211:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(54141);var o=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}(n(67294)),a=function(){return o.createElement(r.Icon,{ignoreDirection:!0,size:16},o.createElement("path",{d:"M10.5,0.499c5.523,0,10,4.477,10,10s-4.477,10-10,10s-10-4.477-10-10S4.977,0.499,10.5,0.499z\n            M23.5,23.499\n            l-5.929-5.929\n            M5.5,10.499h10\n            M10.5,5.499v10"}))},i=function(){return o.createElement(r.Icon,{ignoreDirection:!0,size:16},o.createElement("path",{d:"M10.5,0.499c5.523,0,10,4.477,10,10s-4.477,10-10,10s-10-4.477-10-10S4.977,0.499,10.5,0.499z\n            M23.5,23.499\n            l-5.929-5.929\n            M5.5,10.499h10"}))},c=function(){return c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},c.apply(this,arguments)},l=function(e){var t=o.useState(e.get("scale")||0),n=t[0],r=t[1],a=function(e){r(e)};return o.useEffect((function(){return e.subscribe("scale",a),function(){e.unsubscribe("scale",a)}}),[]),{scale:n}},u=function(e){var t=e.children,n=e.store;return(t||function(e){return o.createElement(o.Fragment,null,"".concat(Math.round(100*e.scale),"%"))})({scale:l(n).scale})},s=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1,1.1,1.3,1.5,1.7,1.9,2.1,2.4,2.7,3,3.3,3.7,4.1,4.6,5.1,5.7,6.3,7,7.7,8.5,9.4,10],d=function(e){return s.find((function(t){return t>e}))||e},p=function(e){var t=s.findIndex((function(t){return t>=e}));return-1===t||0===t?e:s[t-1]},f=function(e){var t=e.containerRef,n=e.store,a=function(e){if(!e.shiftKey&&!e.altKey&&
1(r.isMac()?e.metaKey:e.ctrlKey)){var o=t.current;if(o&&document.activeElement&&o.contains(document.activeElement)){var a=n.get("zoom");if(a){var i=n.get("scale")||1,c=1;switch(e.key){case"-":c=p(i);break;case"=":c=d(i);break;case"0":c=1;break;default:c=i}c!==i&&(e.preventDefault(),a(c))}}}};return o.useEffect((function(){if(t.current)return document.addEventListener("keydown",a),function(){document.removeEventListener("keydown",a)}}),[t.current]),o.createElement(o.Fragment,null)},m=[.5,.75,1,1.25,1.5,2,3,4],g={left:0,top:8},h=function(e){var t=e.levels,n=void 0===t?m:t,a=e.scale,i=e.onZoom,c=o.useContext(r.LocalizationContext).l10n,l=o.useContext(r.ThemeContext).direction===r.TextDirection.RightToLeft,u=c&&c.zoom?c.zoom.zoomDocument:"Zoom document";return o.createElement(r.Popover,{ariaControlsSuffix:"zoom",ariaHasPopup:"menu",position:r.Position.BottomCenter,target:function(e){return o.createElement(r.MinimalButton,{ariaLabel:u,testId:"zoom__popover-target",onClick:function(){e()}},o.createElement("span",{className:"rpv-zoom__popover-target"},o.createElement("span",{"data-testid":"zoom__popover-target-scale",className:r.classNames({"rpv-zoom__popover-target-scale":!0,"rpv-zoom__popover-target-scale--ltr":!l,"rpv-zoom__popover-target-scale--rtl":l})},Math.round(100*a),"%"),o.createElement("span",{className:"rpv-zoom__popover-target-arrow"})))},content:function(e){return o.createElement(r.Menu,null,Object.keys(r.SpecialZoomLevel).map((function(t){var n=t;return o.createElement(r.MenuItem,{key:n,onClick:function(){e(),i(n)}},function(e){switch(e){case r.SpecialZoomLevel.ActualSize:return c&&c.zoom?c.zoom.actualSize:"Actual size";case r.SpecialZoomLevel.PageFit:return c&&c.zoom?c.zoom.pageFit:"Page fit";case r.SpecialZoomLevel.PageWidth:return c&&c.zoom?c.zoom.pageWidth:"Page width"}}(n))})),o.createElement(r.MenuDivider,null),n.map((function(t){return o.createElement(r.MenuItem,{key:t,onClick:function(){e(),i(t)}},"".concat(Math.round(100*t),"%"))})))},offset:g,closeOnClickOutside:!0,closeOnEscape:!0})},v=function(e){var t=e.children,n=e.levels,r=e.store;return(t||function(e){return o.createElement(h,{levels:n,scale:e.scale,onZoom:e.onZoom})})({scale:l(r).scale,onZoom:function(e){var t=r.get("zoom");t&&t(e)}})},b={left:0,top:8},E=function(e){var t=e.enableShortcuts,n=e.onClick,i=o.useContext(r.LocalizationContext).l10n,c=i&&i.zoom?i.zoom.zoomIn:"Zoom in",l=t?r.isMac()?"Meta+=":"Ctrl+=":"";return o.createElement(r.Tooltip,{ariaControlsSuffix:"zoom-in",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaKeyShortcuts:l,ariaLabel:c,testId:"zoom__in-button",onClick:n},o.createElement(a,null)),content:function(){return c},offset:b})},_=function(e){var t=e.children,n=e.enableShortcuts,r=e.store,o=l(r).scale;return(t||E)({enableShortcuts:n,onClick:function(){var e=r.get("zoom");e&&e(d(o))}})},y=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,i=n&&n.zoom?n.zoom.zoomIn:"Zoom in";return o.createElement(r.MenuItem,{icon:o.createElement(a,null),testId:"zoom__in-menu",onClick:t},i)},k={left:0,top:8},C=function(e){var t=e.enableShortcuts,n=e.onClick,a=o.useContext(r.LocalizationContext).l10n,c=a&&a.zoom?a.zoom.zoomOut:"Zoom out",l=t?r.isMac()?"Meta+-":"Ctrl+-":"";return o.createElement(r.Tooltip,{ariaControlsSuffix:"zoom-out",position:r.Position.BottomCenter,target:o.createElement(r.MinimalButton,{ariaKeyShortcuts:l,ariaLabel:c,testId:"zoom__out-button",onClick:n},o.createElement(i,null)),content:function(){return c},offset:k})},w=function(e){var t=e.children,n=e.enableShortcuts,r=e.store,o=l(r).scale;return(t||C)({enableShortcuts:n,onClick:function(){var e=r.get("zoom");e&&e(p(o))}})},S=function(e){var t=e.onClick,n=o.useContext(r.LocalizationContext).l10n,a=n&&n.zoom?n.zoom.zoomOut:"Zoom out";return o.createElement(r.MenuItem,{icon:o.createElement(i,null),testId:"zoom__out-menu",onClick:t},a)};t.ZoomInIcon=a,t.ZoomOutIcon=i,t.zoomPlugin=function(e){var t=o.useMemo((function(){return Object.assign({},{enableShortcuts:!0},e)}),[]),n=o.useMemo((function(){return r.createStore({})}),[]),a=function(e){return o.createElement(_,c({enableShortcuts:t.enableShortcuts},e,{store:n}))},i=function(e){return o.createElement(w,c({enableShortcuts:t.enableShortcuts},e,{store:n}))},l=function(e){return o.createElement(v,c({},e,{store:n}))};return{renderViewer:function(e){var r=e.slot;if(!t.enableShortcuts)return r;var a={children:o.createElement(o.Fragment,null,o.createElement(f,{containerRef:e.containerRef,store:n}),r.children)};return c(c({},r),a)},install:function(e){n.update("zoom",e.zoom)},onViewerStateChange:function(e){return n.update("scale",e.scale),e},zoomTo:function(e){var t=n.get("zoom");t&&t(e)},CurrentScale:function(e){return o.createElement(u,c({},e,{store:n}))},ZoomIn:a,ZoomInButton:function(){return o.createElement(a,null,(function(e){return o.createElement(E,c({},e))}))},ZoomInMenuItem:function(e){return o.createElement(a,null,(function(t){return o.createElement(y,{onClick:function(){t.onClick(),e.onClick()}})}))},ZoomOut:i,ZoomOutButton:function(){return o.createElement(i,null,(function(e){return o.createElement(C,c({},e))}))},ZoomOutMenuItem:function(e){return o.createElement(i,null,(function(t){return o.createElement(S,{onClick:function(){t.onClick(),e.onClick()}})}))},Zoom:l,ZoomPopover:function(e){return o.createElement(l,null,(function(t){return o.createElement(h,c({levels:null==e?void 0:e.levels},t))}))}}}},60440:function(e,t,n){"use strict";e.exports=n(61211)},34062:function(e,t,n){"use strict";n.d(t,{SS:function(){return r},v1:function(){return i}});const r={string:{parse:e=>e,serialize:e=>`${e}`,withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},integer:{parse:e=>
1parseInt(e),serialize:e=>Math.round(e).toFixed(),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},float:{parse:e=>parseFloat(e),serialize:e=>e.toString(),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},boolean:{parse:e=>"true"===e,serialize:e=>Boolean(e)?"true":"false",withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},timestamp:{parse:e=>new Date(parseInt(e)),serialize:e=>e.valueOf().toString(),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},isoDateTime:{parse:e=>new Date(e),serialize:e=>e.toISOString(),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}},stringEnum:e=>({parse:t=>{const n=t;return e.includes(n)?n:null},serialize:e=>e.toString(),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}}),json:()=>({parse:e=>{try{return JSON.parse(decodeURIComponent(e))}catch(t){return null}},serialize:e=>encodeURIComponent(JSON.stringify(e)),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}}),array:(e,t=",")=>({parse:n=>n.split(t).map((e=>decodeURIComponent(e))).map(e.parse).filter((e=>null!==e&&void 0!==e)),serialize:n=>n.map((t=>e.serialize?e.serialize(t):`${t}`)).map(encodeURIComponent).join(t),withDefault(e){return Object.assign(Object.assign({},this),{defaultValue:e})}})};var o=n(11163),a=n(67294);function i(e,{history:t="replace",parse:n=(e=>e),serialize:r=String,defaultValue:i}={history:"replace",parse:e=>e,serialize:String,defaultValue:void 0}){var c;const l=(0,o.useRouter)(),u=a.useMemo((()=>"push"===t?l.push:l.replace),[t]),s=a.useCallback((()=>{if("undefined"===typeof window)return null;const t=new URLSearchParams(window.location.search).get(e);return null!==t?n(t):null}),[]),d=a.useMemo(s,[l.query[e]]),p=a.useCallback(((t,n)=>{var o,a;const c=null!==(a=null!==(o=s())&&void 0!==o?o:i)&&void 0!==a?a:null,d="function"===typeof t?t(c):t;const p=new URLSearchParams(window.location.search);null===d?p.delete(e):p.set(e,r(d));const f=p.toString(),m=window.location.hash;return null===u||void 0===u?void 0:u.call(l,{pathname:l.pathname,hash:m,search:f},{pathname:window.location.pathname,hash:m,search:f},n)}),[e,u]);return[null!==(c=null!==d&&void 0!==d?d:i)&&void 0!==c?c:null,p]}},18177:function(){},8725:function(){},31879:function(){},11987:function(e,t,n){!function(){var t={477:function(e){"use strict";e.exports=n(97334)}},r={};function o(e){var n=r[e];if(void 0!==n)return n.exports;var a=r[e]={exports:{}},i=!0;try{t[e](a,a.exports,o),i=!1}finally{i&&delete r[e]}return a.exports}o.ab="//";var a={};!function(){var e,t=a,n=(e=o(477))&&"object"==typeof e&&"default"in e?e.default:e,r=/https?|ftp|gopher|file/;function i(e){"string"==typeof e&&(e=E(e));var t=function(e,t,n){var r=e.auth,o=e.hostname,a=e.protocol||"",i=e.pathname||"",c=e.hash||"",l=e.query||"",u=!1;r=r?encodeURIComponent(r).replace(/%3A/i,":")+"@":"",e.host?u=r+e.host:o&&(u=r+(~o.indexOf(":")?"["+o+"]":o),e.port&&(u+=":"+e.port)),l&&"object"==typeof l&&(l=t.encode(l));var s=e.search||l&&"?"+l||"";return a&&":"!==a.substr(-1)&&(a+=":"),e.slashes||(!a||n.test(a))&&!1!==u?(u="//"+(u||""),i&&"/"!==i[0]&&(i="/"+i)):u||(u=""),c&&"#"!==c[0]&&(c="#"+c),s&&"?"!==s[0]&&(s="?"+s),{protocol:a,host:u,pathname:i=i.replace(/[?#]/g,encodeURIComponent),search:s=s.replace("#","%23"),hash:c}}(e,n,r);return""+t.protocol+t.host+t.pathname+t.search+t.hash}var c="http://",l="w.w",u=c+l,s=/^([a-z0-9.+-]*:\/\/\/)([a-z0-9.+-]:\/*)?/i,d=/https?|ftp|gopher|file/;function p(e,t){var n="string"==typeof e?E(e):e;e="object"==typeof e?i(e):e;var r=E(t),o="";n.protocol&&!n.slashes&&(o=n.protocol,e=e.replace(n.protocol,""),o+="/"===t[0]||"/"===e[0]?"/":""),o&&r.protocol&&(o="",r.slashes||(o=r.protocol,t=t.replace(r.protocol,"")));var a=e.match(s);a&&!r.protocol&&(e=e.substr((o=a[1]+(a[2]||"")).length),/^\/\/[^/]/.test(t)&&(o=o.slice(0,-1)));var l=new URL(e,u+"/"),p=new URL(t,l).toString().replace(u,""),f=r.protocol||n.protocol;return f+=n.slashes||r.slashes?"//":"",!o&&f?p=p.replace(c,f):o&&(p=p.replace(c,"")),d.test(p)||~t.indexOf(".")||"/"===e.slice(-1)||"/"===t.slice(-1)||"/"!==p.slice(-1)||(p=p.slice(0,-1)),o&&(p=o+("/"===p[0]?p.substr(1):p)),p}function f(){}f.prototype.parse=E,f.prototype.format=i,f.prototype.resolve=p,f.prototype.resolveObject=p;var m=/^https?|ftp|gopher|file/,g=/^(.*?)([#?].*)/,h=/^([a-z0-9.+-]*:)(\/{0,3})(.*)/i,v=/^([a-z0-9.+-]*:)?\/\/\/*/i,b=/^([a-z0-9.+-]*:)(\/{0,2})\[(.*)\]$/i;function E(e,t,r){if(void 0===t&&(t=!1),void 0===r&&(r=!1),e&&"object"==typeof e&&e instanceof f)return e;var o=(e=e.trim()).match(g);e=o?o[1].replace(/\\/g,"/")+o[2]:e.replace(/\\/g,"/"),b.test(e)&&"/"!==e.slice(-1)&&(e+="/");var a=!/(^javascript)/.test(e)&&e.match(h),c=v.test(e),s="";a&&(m.test(a[1])||(s=a[1].toLowerCase(),e=""+a[2]+a[3]),a[2]||(c=!1,m.test(a[1])?(s=a[1],e=""+a[3]):e="//"+a[3]),3!==a[2].length&&1!==a[2].length||(s=a[1],e="/"+a[3]));var d,p=(o?o[1]:e).match(/^https?:\/\/[^/]+(:[0-9]+)(?=\/|$)/),E=p&&p[1],_=new f,y="",k="";try{d=new URL(e)}catch(t){y=t,s||r||!/^\/\//.test(e)||/^\/\/.+[@.]/.test(e)||(k="/",e=e.substr(1));try{d=new URL(e,u)}catch(e){return _.protocol=s,_.href=s,_}}_.slashes=c&&!k,_.host=d.host===l?"":d.host,_.hostname=d.hostname===l?"":d.hostname.replace(/(\[|\])/g,""),_.protocol=y?s||null:d.protocol,_.search=d.search.replace(/\\/g,"%5C"),_.hash=d.hash.replace(/\\/g,"%5C");var C=e.split("#");!_.search&&~C[0].indexOf("?")&&(_.search="?"),_.hash||""!==C[1]||(_.hash="#"),_.query=t?n.decode(d.search.substr(1)):_.search.substr(1),_.pathname=k+(a?function(e){return e.replace(/['^|`]/g,(function(e){return"%"+e.charCodeAt().toString(16).toUpperCase()})).replace(/((?:%[0-9A-F]{2})+)/g,(function(e,t){try{return decodeURIComponent(t).split("").map((function(e){var t=e.charCodeAt();return t>256||/^[a-z0-9]$/i.test(e)?e:"%"+t.toString(16).toUpperCase()})).join("")}catch(e){return t}}))}(d.pathname):d.pathname),"about:"===_.protocol&&"blank"===_.pathname&&(_.protocol="",_.pathname=""),y&&"/"!==e[0]&&(_.pathname=_.pathname.substr(1)),s&&!m.test(s)&&"/"!==e.slice(-1)&&"/"===_.pathname&&(_.pathname=""),_.path=_.pathname+_.search,_.auth=[d.username,d.password].map(decodeURIComponent).filter(
1Boolean).join(":"),_.port=d.port,E&&!_.host.endsWith(E)&&(_.host+=E,_.port=E.slice(1)),_.href=k?""+_.pathname+_.search+_.hash:i(_);var w=/^(file)/.test(_.href)?["host","hostname"]:[];return Object.keys(_).forEach((function(e){~w.indexOf(e)||(_[e]=_[e]||null)})),_}t.parse=E,t.format=i,t.resolve=p,t.resolveObject=function(e,t){return E(p(e,t))},t.Url=f}(),e.exports=a}()},97334:function(e){!function(){"use strict";var t={815:function(e){function t(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,r,o,a){r=r||"&",o=o||"=";var i={};if("string"!==typeof e||0===e.length)return i;var c=/\+/g;e=e.split(r);var l=1e3;a&&"number"===typeof a.maxKeys&&(l=a.maxKeys);var u=e.length;l>0&&u>l&&(u=l);for(var s=0;s<u;++s){var d,p,f,m,g=e[s].replace(c,"%20"),h=g.indexOf(o);h>=0?(d=g.substr(0,h),p=g.substr(h+1)):(d=g,p=""),f=decodeURIComponent(d),m=decodeURIComponent(p),t(i,f)?n(i[f])?i[f].push(m):i[f]=[i[f],m]:i[f]=m}return i};var n=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},577:function(e){var t=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,a,i,c){return a=a||"&",i=i||"=",null===e&&(e=void 0),"object"===typeof e?r(o(e),(function(o){var c=encodeURIComponent(t(o))+i;return n(e[o])?r(e[o],(function(e){return c+encodeURIComponent(t(e))})).join(a):c+encodeURIComponent(t(e[o]))})).join(a):c?encodeURIComponent(t(c))+i+encodeURIComponent(t(e)):""};var n=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function r(e,t){if(e.map)return e.map(t);for(var n=[],r=0;r<e.length;r++)n.push(t(e[r],r));return n}var o=Object.keys||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t}}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var a=n[e]={exports:{}},i=!0;try{t[e](a,a.exports,r),i=!1}finally{i&&delete n[e]}return a.exports}r.ab="//";var o={};!function(){var e=o;e.decode=e.parse=r(815),e.encode=e.stringify=r(577)}(),e.exports=o}()}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.