1"use strict";(self.webpackChunkuwazi=self.webpackChunkuwazi||[]).push([[1389],{59525(e,t,n){n.d(t,{PDF:()=>v});var r=n(5556),i=n.n(r),a=n(96540),o=n(12841),s=n(26156),l=n(64308),c=n(16014),u=n(37063),d=n(31166),p=n(18063),g=n(95503),h=n(500),f=(n(94614),n(34611));function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function b(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach(function(t){y(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function y(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class v extends a.Component{static getDerivedStateFromProps(e,t){return null!==t.filename&&t.filename!==e.filename?{pdf:{numPages:0},filename:e.filename}:null}constructor(e){super(e),this._isMounted=!1,this.state={pdf:{numPages:0},filename:e.filename,scale:1,error:null},this.pagesLoaded={},this.loadDocument(e.file),this.currentPage="1",this.pages={},this.pdfReady=!1,this.pageUnloaded=this.pageUnloaded.bind(this),this.pageLoading=this.pageLoading.bind(this),this.onPageVisible=this.onPageVisible.bind(this),this.onPageHidden=this.onPageHidden.bind(this),this.handleScaleChange=this.handleScaleChange.bind(this),this.containerWidth=0}componentDidMount(){var e;this._isMounted=!0,this.pdfContainer&&(document.addEventListener("textlayerrendered",e=>{this.pageLoaded(e.detail.pageNumber)}),document.addEventListener("textlayerrendered",this.props.onPageLoaded,{once:!0})),this.containerWidth=null===(e=this.props.parentRef.current)||void 0===e?void 0:e.clientWidth}shouldComponentUpdate(e,t){return e.file!==this.props.file||e.filename!==this.props.filename||e.style!==this.props.style||t.pdf!==this.state.pdf||t.scale!==this.state.scale||t.error!==this.state.error}componentDidUpdate(e){null!==e.filename&&this.props.filename!==e.filename&&(this.pagesLoaded={},this.loadDocument(e.file)),this.state.pdf.numPages&&!this.pdfReady&&(this.pdfReady=!0,this.props.onPDFReady())}componentWillUnmount(){this._isMounted=!1}handleScaleChange(e){this.setState({scale:e})}onPageVisible(e,t){this.pages[e]=t;const n=Object.keys(this.pages).reduce((e,t)=>!this.pages[t-1]||this.pages[t]>this.pages[t-1]?t:e,1);this.currentPage!==n&&(this.currentPage=n,this.props.onPageChange(Number(n)))}onPageHidden(e){delete this.pages[e]}loadDocument(e){h.oc&&(this._isMounted&&this.setState({error:null}),g.Ob.getDocument({url:e,cMapUrl:g.Oj,cMapPacked:true,wasmUrl:g.nS,isEvalSupported:!1}).promise.then(e=>{this._isMounted&&this.setState({pdf:e})}).catch(e=>{this._isMounted&&(404===e.status?this.setState({error:a.createElement(c.HT,null,"This file is currently unavailable. Please contact your administrator if the issue persists.")}):"InvalidPDFException"===e.name?this.setState({error:a.createElement(c.HT,null,"This file could not be opened. It may be corrupted or not a valid PDF.")}):(this.setState({error:a.createElement(c.HT,null,"This file could not be displayed. Try refreshing the page.")}),(0,f.$D)(e,"pdf-error")))}))}pageUnloaded(e){delete this.pagesLoaded[e],this.loaded()}pageLoading(e){this.pagesLoaded[e]=!1}pageLoaded(e){this.pagesLoaded[e]=!0;0===Object.keys(this.pagesLoaded).map(e=>this.pagesLoaded[e]).filter(e=>!e).length&&this.loaded()}loaded(){const e=Object.keys(this.pagesLoaded).map(e=>parseInt(e,10));(0,l.B)(e,{treatAs:"number"}).reduce((e,t)=>!1===e?e:(null===e||!(t-e>1))&&t,null)&&this.props.onLoad({pages:e})}render(){const{scale:e,error:t}=this.state,n=b(b({},this.props.style),{},{"--page-border":"none","--page-margin":"0"});return t?a.createElement("div",{className:"tw-content","data-testid":"errorInfo"},a.createElement(d.Gz,{icon:a.createElement(s.A,{className:"h-7 w-7 text-gray-900 rounded-full bg-gray-300 p-1"}),title:t,description:""})):a.createElement(o.sY,{onSelect:t=>{const n=p.Cw.adjustSelectionsToScale(t,e,!0);this.props.onTextSelection(n)},onDeselect:this.props.onTextDeselection},a.createElement("div",{ref:e=>{this.pdfContainer=e},style:n,id:"pdf-container",className:"pdfViewer"},(()=>{const e=[];for(let t=1;t<=this.state.pdf.numPages;t+=1)e.push(a.createElement("div",{key:t},a.createElement(o.rr,{regionId:t.toString()},a.createElement(u.G,{onUnload:this.pageUnloaded,onLoading:this.pageLoading,onVisible:this.onPageVisible,onHidden:this.onPageHidden,page:t,pdf:this.state.pdf,highlightReference:this.props.highlightReference,containerWidth:this.containerWidth,onScaleChange:this.handleScaleChange}
1))));return e})()))}}v.defaultProps={onPageLoaded:()=>{},filename:null,onPageChange:()=>{},onPDFReady:()=>{},style:{},onTextSelection:()=>{},onTextDeselection:()=>{},highlightReference:()=>{}},v.propTypes={onPageChange:i().func,onTextSelection:i().func,onTextDeselection:i().func,onPageLoaded:i().func,onPDFReady:i().func,file:i().string.isRequired,filename:i().string,onLoad:i().func.isRequired,style:i().object,highlightReference:i().func,parentRef:i().object.isRequired}},80282(e,t,n){n.r(t),n.d(t,{PDF:()=>A});var r=n(96540),i=n(12841),a=n(26156),o=(n(94614),n(16014)),s=n(78578);var l=n(74728),c=n.n(l);const u="snippet-context",d="snippet-search-term",p=e=>c()(e,{allowedTags:[],allowedAttributes:{}}).replace(/â¦/g,"...").replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&").replace(/\s+/g,"\\s*").replace(/\n/g,"\\s*"),g=(e,t,n)=>{if(!t)return;const r=e.parentNode;if(!r)return;const i=e.textContent||"",a=i.toLowerCase().indexOf(t.toLowerCase());if(-1===a)return;r.replaceChild(((e,t,n,r)=>{const i=document.createDocumentFragment(),a=e.slice(0,t),o=e.slice(t,t+n),s=e.slice(t+n);a&&i.appendChild(document.createTextNode(a));const l=document.createElement("mark");return l.className=r,l.style.backgroundColor="rgba(255, 74, 74, 0.6)",l.textContent=o,i.appendChild(l),s&&i.appendChild(document.createTextNode(s)),i})(i,a,t.length,n),e);const o=r.childNodes[r.childNodes.length-1];(null==o?void 0:o.nodeType)===Node.TEXT_NODE&&g(o,t,n)},h=(e,t,n)=>{const r=t.exec(e.textContent||"");if(!r)return[];const i=new Set,a=document.createTreeWalker(e,NodeFilter.SHOW_TEXT,null),o=r.index,s=r.index+r[0].length;let l=0,c=a.nextNode();for(;c;){const e=l+(c.textContent||"").length;if(e>o&&l<s&&c.parentNode){const e=c.parentNode;e.classList&&(e.classList.add(n),e.style.backgroundColor="rgba(247, 168, 168, 0.5)",i.add(e))}l=e,c=a.nextNode()}return Array.from(i)},f=(e,t)=>!(!e.length||!t.length)&&(e.forEach(e=>{t.forEach(t=>((e,t,n)=>{if(!t)return;const r=document.createTreeWalker(e,NodeFilter.SHOW_TEXT,null);let i=r.nextNode();for(;i;){var a;null!==(a=i.textContent)&&void 0!==a&&a.trim()&&g(i,t,n),i=r.nextNode()}})(e,t,d))}),e.some(e=>null!==e.querySelector(`mark.${d}`))),m=e=>{var t,n;e&&(null===(t=e.querySelectorAll(`.${u}`))||void 0===t||t.forEach(e=>{const t=e;t.classList.remove(u),t.style.backgroundColor=""}),null===(n=e.querySelectorAll("mark"))||void 0===n||n.forEach(e=>{const t=e.parentNode;if(t){Array.from(e.childNodes).forEach(n=>t.insertBefore(n,e)),t.removeChild(e)}}))},b=(e,t,n)=>{const r=p(t.text),i=h(e,new RegExp(r,"i"),u);return i.length>0?(f(i,n),!0):!!((e,t,n)=>[15,10].some(r=>{const i=p(t.substring(0,r)),a=p(t.substring(t.length-r)),o=h(e,new RegExp(`${i}.{1,200}${a}`,"i"),u);return o.length>0&&(f(o,n),!0)}))(e,t.text,n)||f([e],n)},y=(e,t)=>{if(!e||!t.text)return!1;m(e);const n=e.querySelector(".textLayer");if(!n)return!1;const r=(e=>{const t=e.match(/<b>(.|\n)*?<\/b>/g);return(t?t.map(e=>c()(e,{allowedTags:[],allowedAttributes:{}})):[]).filter(e=>e.trim().length>0)})(t.text);return b(n,t,r)};var v=n(17957),S=n(500);var P=n(95503),E=n(2283),w=n(34203);function x(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function T(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?x(Object(n),!0).forEach(function(t){D(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):x(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function D(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const O=(e,t,n)=>{e.draw().catch(e=>{(e=>e instanceof Error&&"RenderingCancelledException"===e.name)(e)||e instanceof Error&&t(e.message)}).finally(()=>{null==n||n()})},N=(e,t,n,r)=>{const i=t.current;i&&i.renderingState===P._Y.RenderingStates.INITIAL&&(n?n.request(e,()=>{const i=t.current;i&&i.renderingState===P._Y.RenderingStates.INITIAL?O(i,r,()=>n.complete(e)):n.complete(e)}):O(i,r))},C=({pdf:e,page:t,eventBus:n,intersectionObserver:a,containerWidth:o,highlights:s,onHighlightClick:l,onScaleChange:c,renderingQueue:u})=>{const[d,p]=(0,r.useState)(),[g,h]=(0,r.useState)(1),[f,m]=(0,r.useState)(),[b,y]=(0,r.useState)(!1),S=(0,r.useRef)(null),E=(0,r.useRef)(null),x=(0,r.useRef)(null);return(0,r.useEffect)(()=>{e.getPage(t).then(e=>{const r=S.current;if(r&&e){const i=e.getViewport({scale:1}),a=i.width*P.lf.PDF_TO_CSS_UNITS,o=i.height*P.lf.PDF_TO_CSS_UNITS;x.current={width:a,height:o};const s=new P._Y.PDFPageView({container:r,id:t,scale:i.scale,defaultViewport:i,annotationMode:0,eventBus:n,enableDetailCanvas:!1});s.setPdfPage(e),E.current=s,y(!0)}}).catch(e=>{p(e.message)})},[n,t,e]),(0,r.useEffect)(()=>{const e=E.current,n=x.current;if(b&&e&&n){const r=(0,w.e)(n.width,o);if(Math.abs(e.scale-r)>.01){const i=e.renderingState,a=i!==P._Y.RenderingStates.INITIAL,o=n.height*r;m(o),h(r),null==c||c(r),e.update({scale:r}),a&&(i!==P._Y.RenderingStates.RUNNING&&i!==P._Y.RenderingStates.PAUSED||e.cancelRendering(),e.reset(),N(t,E,u,p))}}},[o,c,b,u,t]),(0,r.useEffect)(()=>{const e=S.current;return e&&b&&(null==a||a.observe(e)),()=>{e&&b&&(null==a||a.unobserve(e))}},[a,b]),(0,r.useEffect)(()=>{b&&n.dispatch("pageready",{pageNumber:t})},[n,t,b]),(0,r.useEffect)(()=>{const e=({pageNumber:e})=>{e===t&&N(t,E,u,p)},r=({pageNumber:e})=>
1{if(e!==t)return;const n=E.current;!n||n.renderingState!==P._Y.RenderingStates.RUNNING&&n.renderingState!==P._Y.RenderingStates.PAUSED||n.cancelRendering(),null==u||u.cancel(t),null==n||n.reset()};return n.on("renderpage",e),n.on("unmountpage",r),n.on("prioritypage",e),()=>{n.off("renderpage",e),n.off("unmountpage",r),n.off("prioritypage",e)}},[n,t,u]),d?r.createElement("div",null,d):r.createElement("div",{ref:S,style:f?{minHeight:`${f}px`}:void 0,"data-testid":"pdf-page","data-pagenumber":t},null==s?void 0:s.map(e=>{const n=T(T({},e),{},{textSelection:(0,v.adjustSelectionsToScale)(e.textSelection,g)}),a=`${t}-${n.key}`;return r.createElement("div",{key:n.key,"data-highlight-key":a,className:l?"cursor-pointer":void 0,onClick:l?()=>{l(n.key)}:void 0},r.createElement("div",{style:{pointerEvents:l?"auto":"none"}},r.createElement(i.f4,{textSelection:n.textSelection,color:n.color})))}))},R=r.memo(C);class k{constructor(){this.highestPriorityPage=null,this.pending=new Map,this.running=null,this.pumpScheduled=!1}isPriority(e){return this.highestPriorityPage===`page${e}`}prioritize(e){this.highestPriorityPage=`page${e}`,this.schedulePump()}request(e,t){this.pending.set(e,t),this.schedulePump()}complete(e){this.pending.delete(e),this.running===e&&(this.running=null),this.pump()}cancel(e){this.complete(e)}schedulePump(){this.pumpScheduled||(this.pumpScheduled=!0,queueMicrotask(()=>{this.pumpScheduled=!1,this.pump()}))}pump(){if(null!==this.running)return;const e=this.pickNext(),t=null===e?void 0:this.pending.get(e);null!==e&&t&&(this.pending.delete(e),this.running=e,t())}pickNext(){const e=this.parsePriority();if(null!==e&&this.pending.has(e))return e;const t=this.pending.keys().next();return t.done?null:t.value}parsePriority(){var e;if(null===(e=this.highestPriorityPage)||void 0===e||!e.startsWith("page"))return null;const t=Number(this.highestPriorityPage.slice(4));return Number.isFinite(t)?t:null}}var L=n(31166),j=n(34611);const F=[0,.1,.25,.4,.5,.75,1],A=({fileUrl:e,highlights:t,onSelect:n=()=>{},onDeselect:l,onScaleChange:c,onPageChange:u,onPdfReady:d,onHighlightClick:p,size:g,scrollRoot:h,className:f,initialPage:b=1})=>{const w=(0,r.useRef)({}),x=(0,r.useRef)(0),T=(0,r.useRef)(0),D=(0,r.useRef)(null),O=(0,r.useRef)(new Map),N=(0,r.useRef)(new Set),C=(0,r.useRef)(0),A=(0,r.useRef)(b),I=(0,r.useRef)(new k),M=(0,r.useRef)(0),_=(0,r.useRef)(!1),[U,H]=(0,r.useState)(null),[q,$]=(0,r.useState)(1),[V,W]=(0,r.useState)(),[z,B]=(0,r.useState)(),G=(0,E.z)(D,{borderWidth:1,safetyBuffer:2}),[Y]=(0,r.useState)(new P.l7),[X,J]=(0,r.useState)({isLoading:!0,progress:0}),Q=(0,r.useRef)(u),[Z,K]=(0,r.useState)([]),ee=(0,r.useCallback)(e=>{D.current=e},[]),te=(0,r.useCallback)(e=>{$(e),null==c||c(e)},[c]),ne=(0,r.useCallback)(e=>{const t=(0,v.adjustSelectionsToScale)(e,q,!0);n(t)},[n,q]),re=(0,r.useCallback)(e=>{const t={current:w.current[e]};x.current=((e,t)=>{let n=0,r=t;const i=()=>{n>9||(e.current&&e.current.clientHeight>0?(0,s.R)(e.current):(n+=1,r=requestAnimationFrame(i)))};return i(),r})(t,x.current)},[w]),ie=(0,r.useCallback)((e,t)=>{var n;const r=null===(n=D.current)||void 0===n?void 0:n.querySelector(`[data-highlight-key="${e}-${t}"]`),i=(null==r?void 0:r.querySelector(".highlight-rectangle"))||r;(0,s.R)(i,{block:"center"})},[]),ae=(0,r.useCallback)(e=>{cancelAnimationFrame(T.current);const t=Date.now()+5e3,n=()=>{let r=w.current[e.page];if(!r){const t=document.querySelector(`#page-${e.page}-container`);t instanceof HTMLDivElement&&(w.current[e.page]=t,r=t)}r&&((e,t)=>{if(!y(e,t))return!1;const n=e.querySelector(".snippet-context")||e.querySelector("mark");return!!n&&(n.scrollIntoView({behavior:"smooth",block:"center"}),!0)})(r,e)||(Date.now()>=t?r&&(0,s.R)(r,{block:"start"}):T.current=requestAnimationFrame(n))};n()},[]),oe=(0,r.useCallback)(()=>{cancelAnimationFrame(T.current),Object.values(w.current).forEach(e=>{e&&m(e)})},[]),se=(0,r.useCallback)(e=>{if(null!=e&&e.length){K(e);const[t]=Object.entries(e[0]||{});if(t){const[e,n]=t;if(w.current[Number(e)]){(async(e,t=5e3,n)=>new Promise((r,i)=>{if(!S.oc||null!=n&&n.aborted)return void i();const a=document.querySelector(e);
1if(a)return void r(a);let o,s;const l=document.body||document.documentElement||document,c=()=>{s.disconnect(),clearTimeout(o),null==n||n.removeEventListener("abort",c),i()},u=()=>{s.disconnect(),clearTimeout(o),null==n||n.removeEventListener("abort",c)};s=new MutationObserver(()=>{const t=document.querySelector(e);t&&(u(),r(t))}),s.observe(l,{childList:!0,subtree:!0}),o=setTimeout(()=>{u(),i()},t),null==n||n.addEventListener("abort",c)}))(`#page-${e}-container [data-highlight-key="${e}-${n[0].key}"]`,5e3).then(e=>{const t=e.querySelector(".highlight-rectangle");(0,s.R)(t||e,{block:"center",behavior:"smooth"})}).catch(()=>{})}}}else K([])},[]),le=(0,r.useCallback)(()=>{_.current||(d&&d({goToPage:re,scrollToHighlight:ie,activateSnippet:ae,deactivateSnippet:oe,toggleHighlights:se},(null==V?void 0:V.numPages)||0),_.current=!0)},[d,re,ie,ae,oe,se,V]);(0,r.useEffect)(()=>{let t=!1;W(void 0),B(void 0),J({isLoading:!0,progress:0});const n=P.Ob.getDocument({url:e,cMapUrl:P.Oj,cMapPacked:!0,wasmUrl:P.nS,isEvalSupported:!1});n.onProgress=e=>{t||(e.percent<100?J({isLoading:!0,progress:e.percent}):J({isLoading:!1,progress:0}))},n.promise.then(e=>{t||W(e)}).catch(e=>{t||(404===e.status?B(r.createElement(o.HT,null,"This file is currently unavailable. Please contact your administrator if the issue persists.")):"InvalidPDFException"===e.name?B(r.createElement(o.HT,null,"This file could not be opened. It may be corrupted or not a valid PDF.")):(B(r.createElement(o.HT,null,"This file could not be displayed. Try refreshing the page.")),(0,j.$D)(e,"pdf-error")))});const i=O.current;return _.current=!1,i.clear(),w.current={},N.current.clear(),I.current.prioritize(A.current),()=>{var e;t=!0,_.current=!1,i.clear(),Promise.resolve(null===(e=n.destroy)||void 0===e?void 0:e.call(n)).catch(()=>{})}},[e]),(0,r.useEffect)(()=>{var e;M.current=null!==(e=null==V?void 0:V.numPages)&&void 0!==e?e:0,O.current.clear(),N.current.clear(),C.current=0},[V]),(0,r.useEffect)(()=>{const e=new IntersectionObserver(e=>{e.forEach(e=>{const t=Number.parseInt(e.target.getAttribute("data-pagenumber")||"0",10);e.isIntersecting?Y.dispatch("renderpage",{pageNumber:t}):N.current.has(t)||Y.dispatch("unmountpage",{pageNumber:t})})},{root:null!=h?h:null,rootMargin:"500px 0px 500px 0px",threshold:0});return H(e),()=>{e.disconnect(),H(null)}},[Y,h]),(0,r.useEffect)(()=>{if(!V)return;const e=O.current;e.clear();const t=N.current;t.clear();const n=new IntersectionObserver(n=>{n.forEach(n=>{const r=Number.parseInt(n.target.getAttribute("data-pagenumber")||"0",10);n.isIntersecting&&n.intersectionRect.height>0?(t.add(r),e.set(r,n.intersectionRect.height)):(t.delete(r),e.delete(r))});const r=((e,t,n=0)=>{let r=0,i=0;return e.forEach((e,a)=>{a<1||a>t||e<=0||(e>i||e===i&&a===n)&&(i=e,r=a)}),r})(e,M.current,C.current);var i;r>0&&(C.current=r,I.current.prioritize(r),Y.dispatch("prioritypage",{pageNumber:r}),_.current&&(null===(i=Q.current)||void 0===i||i.call(Q,r)))},{root:null!=h?h:null,rootMargin:"0px",threshold:F});return Object.values(w.current).forEach(e=>{e&&n.observe(e)}),()=>{n.disconnect()}},[V,h,Y]),(0,r.useEffect)(()=>{const e=({pageNumber:e})=>{e===A.current&&(Y.dispatch("renderpage",{pageNumber:e}),le())};return Y.on("pageready",e),()=>{Y.off("pageready",e)}},[le,Y]),(0,r.useEffect)(()=>{Q.current=u},[u]),(0,r.useEffect)(()=>()=>{cancelAnimationFrame(x.current),cancelAnimationFrame(T.current)},[]);const ce=(0,r.useMemo)(()=>{if(!V)return null;const e=[t,...Z];return Array.from({length:V.numPages},(e,t)=>t+1).map(t=>{const n=t,a=e.find(e=>e&&e[n]),o=null==a?void 0:a[n];return r.createElement("div",{key:`page-${n}`,id:`page-${n}-container`,"data-pagenumber":n,ref:e=>{w.current[n]=e},className:["relative mb-4 border-solid","[border-width:1px]","border-[color-mix(in_srgb,var(--color-theme-border-default)_55%,transparent)]"].join(" ")},r.createElement(i.rr,{regionId:n.toString()},r.createElement(R,{pdf:V,page:t,eventBus:Y,intersectionObserver:U,highlights:o,onHighlightClick:p,containerWidth:G,onScaleChange:te,renderingQueue:I.current})))})},[V,t,Z,Y,U,p,G,te]),ue={height:(null==g?void 0:g.height)||"100%",width:(null==g?void 0:g.width)||"100%","--page-border":"none","--page-margin":"0"};return z?r.createElement("div",{"data-testid":"errorInfo",className:"h-full"},r.createElement(L.Gz,{icon:r.createElement(a.A,{className:"h-7 w-7 text-gray-900 rounded-full bg-gray-300 p-1"}),title:z})):r.createElement(i.sY,{onSelect:ne,onDeselect:l},r.createElement("div",{className:`w-full flex flex-col gap-2 h-full items-center justify-center p-3 ${f}`},X.isLoading||!V?r.createElement("div",{className:"w-full flex flex-col gap-2"},r.createElement("div",{className:"flex justify-between mb-1"},r.createElement("div",{className:"font-medium text-ink-muted"}
1,r.createElement(o.HT,null,"Loading")," ..."),r.createElement("span",{className:"text-sm font-medium text-ink-muted"},X.progress,"%")),r.createElement(L.z2,{progress:X.progress,color:"gray"})):null,r.createElement("div",{id:"pdf-container",className:"pdfViewer",ref:ee,style:ue},ce)))}},95503(e,t,n){n.d(t,{l7:()=>c});var r=n(15626),i=n(15493),a={};n.r(a),n.d(a,{AbortException:()=>r.e3,AnnotationEditorLayer:()=>r.iX,AnnotationEditorParamsType:()=>r.N5,AnnotationEditorType:()=>r.vP,AnnotationEditorUIManager:()=>r.s4,AnnotationLayer:()=>r.dU,AnnotationMode:()=>r.ng,AnnotationType:()=>r.UJ,CSSConstants:()=>r.D7,ColorPicker:()=>r.sk,DOMSVGFactory:()=>r.xd,DrawLayer:()=>r.Qh,FeatureTest:()=>r.TV,GlobalWorkerOptions:()=>r.EA,ImageKind:()=>r.yI,InvalidPDFException:()=>r.Z7,MathClamp:()=>r.KL,OPS:()=>r.Do,OutputScale:()=>r.oA,PDFDataRangeTransport:()=>r.Tm,PDFDateString:()=>r.G6,PDFWorker:()=>r.nS,PagesMapper:()=>r.Qi,PasswordResponses:()=>r.SS,PermissionFlag:()=>r._i,PixelsPerInch:()=>r.lf,RenderingCancelledException:()=>r.ji,ResponseException:()=>r.bw,SignatureExtractor:()=>r.J1,SupportedImageMimeTypes:()=>r.j_,TextLayer:()=>r.D6,TouchManager:()=>r.p5,Util:()=>r.J0,VerbosityLevel:()=>r.mQ,XfaLayer:()=>r.Tw,applyOpacity:()=>r.GG,build:()=>r.jq,createValidAbsoluteUrl:()=>r.z7,fetchData:()=>r.Fd,findContrastColor:()=>r.z_,getDocument:()=>r.YE,getFilenameFromUrl:()=>r.Hw,getPdfFilenameFromUrl:()=>r.lJ,getRGB:()=>r.S9,getUuid:()=>r.YJ,getXfaPageViewport:()=>r.dm,isDataScheme:()=>r.Gz,isPdfFile:()=>r.ZH,isValidExplicitDest:()=>r.RY,noContextMenu:()=>r._p,normalizeUnicode:()=>r.Cv,renderRichText:()=>r.CA,setLayerDimensions:()=>r.HF,shadow:()=>r.r7,stopEvent:()=>r.jo,updateUrlHash:()=>r.Zu,version:()=>r.rE});var o={};n.r(o),n.d(o,{AnnotationLayerBuilder:()=>i.e2,DownloadManager:()=>i.qm,EventBus:()=>i.l7,FindState:()=>i.tx,GenericL10n:()=>i.P2,LinkTarget:()=>i.M9,PDFFindController:()=>i.yL,PDFHistory:()=>i.BR,PDFLinkService:()=>i.uU,PDFPageView:()=>i.Zl,PDFScriptingManager:()=>i.xe,PDFSinglePageViewer:()=>i.ID,PDFViewer:()=>i.TO,ProgressBar:()=>i.z2,RenderingStates:()=>i.Xv,ScrollMode:()=>i.VT,SimpleLinkService:()=>i.Gl,SpreadMode:()=>i.Xf,StructTreeLayerBuilder:()=>i.UN,TextLayerBuilder:()=>i.I2,XfaLayerBuilder:()=>i.md,parseQueryString:()=>i.JO});const s=o,{l7:l}=i;r.EA.workerSrc=new URL(n(10338),n.b).toString();class c extends l{on(e,t){super.on(e,t)}off(e,t){super.off(e,t)}dispatch(e,t){super.dispatch(e,t)}}const u=a,{lf:d}=r;n.d(t,["Ob",0,u,"Oj",0,"/legacy_character_maps/","_Y",0,s,"lf",0,d,"nS",0,"/pdfjs_wasm/"])},94614(e,t,n){var r,i;r=void 0,i=n(29140)(e.id,{}),e.hot.data&&e.hot.data.value&&e.hot.data.value!==r?e.hot.invalidate():e.hot.accept(),e.hot.dispose(function(e){e.value=r,i()})}}]);
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.