1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3330],{17482:(e,l,a)=>{a.d(l,{A:()=>r});var t=a(14428),n=a(81385);let r={getRelatedDocumentsApi:async e=>{let{limit:l,page:a,query:n}=e;return t.default.get("wp-json/document/documents?type=Related%20documents&limit=".concat(l,"&page=").concat(a).concat(n?"&".concat(n):""))},getRelatedDocumentDetailApi:async e=>{let{slugName:l}=e;return t.default.get("wp-json/post-page/documents?slug_name=".concat(l))},getPressDetailApi:async e=>{let{slugName:l}=e;return t.default.get("wp-json/post-page/documents?slug_name=".concat(l))},getBannersData:async()=>t.default.get("wp-json/wp/v2/pages?slug=our-team&acf_format=standard&_fields=acf"),getPressReleaseData:async e=>{let{parentCategorySlug:l,limit:a,page:r,query:s}=e;return"NEW"!=n.yt?t.default.get("wp-json/document/documents?type=Press%20Release&limit=".concat(a,"&page=").concat(r).concat(s?"&".concat(s):"")):t.default.get("wp-json/document/documents?document_category=".concat(l,"&limit=").concat(a,"&page=").concat(r).concat(s?"&".concat(s):""))}}},43330:(e,l,a)=>{a.r(l),a.d(l,{default:()=>b});var t=a(37876),n=a(66987);a(90557);var r=a(71197),s=a(94757),u=a(69636),o=a(56396),i=a(14232),c=a(52243),d=a(18493),f=a(92101),g=a(11764),p=a(89099),v=a(17482),h=a(18028),m=a(27803),_=a(985),y=a(98914),S=a(4811),w=a(92775),j=a(81385);let x=()=>{var e,l,a;let n=(0,p.useRouter)(),{persona:r,slug:s,page:u}=n.query;console.log("slug",s);let o=new URL(window.location.href).pathname,{setLastModified:x}=(0,_.J)(),[R,D]=(0,i.useState)(10),[b,A]=(0,i.useState)({}),[T,C]=(0,i.useState)(""),[E,P]=(0,i.useState)(),[O,k]=(0,i.useState)(""),[z,N]=(0,i.useState)(),[F,L]=(0,i.useState)(""),[U,M]=(0,i.useState)(u||1),[I,q]=(0,i.useState)(""),[B,W]=(0,i.useState)(!0),[Y,Z]=(0,i.useState)(null),[H,J]=(0,i.useState)(!1),[K,V]=(0,i.useState)(),[G,Q]=(0,i.useState)(),[X,$]=(0,i.useState)(""),[ee,el]=(0,i.useState)(""),ea=async(e,l,a)=>{J(!0);try{var t,n,r,s;let u;ee&&(console.log(ee),u=await v.A.getPressReleaseData({parentCategorySlug:ee,limit:e,page:l,query:a})),ee&&(null==u||null==(n=u.data)||null==(t=n.posts)?void 0:t.length)||(console.warn("Using fallback API due to missing/invalid parentCategorySlug or empty response..."),u=await v.A.getPressReleaseData({parentCategorySlug:"press-release",limit:e,page:l,query:a}));let o=u.data;Z(o),console.log(null==o||null==(s=o.posts)||null==(r=s[1])?void 0:r.acf_data)}catch(e){console.error("Error fetching data:",e)}finally{J(!1)}},et=async e=>{x("");try{if(ee){let l=(await v.A.getPressReleaseData({parentCategorySlug:ee,limit:R,page:U,query:e})).data;x(null==l?void 0:l.modified_date)}}catch(e){console.log(e)}finally{}};(0,i.useEffect)(()=>{et("modified_date")},[]);let en=async e=>{e.preventDefault();let l=e.target.value.replace(/[^a-zA-Z0-9 ]/g,"");M(1),k(l)},er=(0,i.useCallback)(async()=>{let e;Q(e=new URLSearchParams("ASC"===I||"DESC"===I||T?r?{sort:"acf",order:I?(0,g.MO)(I):"DESC",sub_category:(0,g.Op)(X,T),orderby:"title",search:O,persona:r}:{sort:"acf",order:I?(0,g.MO)(I):"DESC",orderby:"title",sub_category:(0,g.Op)(X,T),search:O}:r?{sort:"acf",order:I?(0,g.MO)(I):"DESC",search:O,persona:r}:{sort:"acf",order:I?(0,g.MO)(I):"DESC",search:O}));try{""!==I||10!==R||""!==O?(r?(0,g.cR)(n,1,o,r):(0,g.cR)(n,1,o),await ea(R,1,e)):(r?(0,g.cR)(n,u||U,o,r):(0,g.cR)(n,u||U,o),await ea(R,u||U,e))}catch(e){console.error("Error fetching data:",e)}},[O,I,r,R,T,ee]);(0,i.useEffect)(()=>{!async function(){try{var e;let l=await y.A.getReportsCategory(),a=(null==l||null==(e=l.data)?void 0:e.documents_category)||[],t=a.find(e=>0===e.parent&&("press-release"===e.slug||"press-releases"===e.slug));if(!t)return void console.log("Parent category not found.");console.log(t);let n=t.term_taxonomy_id,r=a.filter(e=>e.parent===n).map(e=>e.name),s=a.filter(e=>e.parent===n);console.log("Subcategories under 'report':",s),el((0,g.C4)(s,t)),$(s),console.log("Subcategories under 'report':",r),A(r)}catch(e){console.log("Error fetching categories:",e)}}()},[]),(0,i.useEffect)(()=>{let e=setTimeout(()=>{er()},700);return()=>clearTimeout(e)},[er]),(0,i.useEffect)(()=>{P(Y),N(Y)},[Y]);let es=async e=>{r?(0,g.cR)(n,e+1,o,r):(0,g.cR)(n,e+1,o),await ea(R,e+1,G)},eu=async e=>{r?(0,g.cR)(n,e+1,o,r):(0,g.cR)(n,e+1,o),await ea(R,e+1,G),M(e+1)},eo=async e=>{r?(0,g.cR)(n,e-1,o,r):(0,g.cR)(n,e-1,o),await ea(R,e-1,G),M(e-1)};return(0,t.jsxs)("div",{className:"container mt-5",children:[(0,t.jsx)(h.default,{searchBox:!0,sortFilter:!0,limitFilter:!0,searchTerm:O,category:T,filter:I,limit:R,categoryFilter:b&&Object.keys(b).length>0,latestFilter:B,handleSearch:en,HandleSetLimit:e=>{D(e.target.value)},handleCategory:e=>{let l=e.target.value;e.target.value||(ea(R,1,G),et("modified_date")),C(l)},handleShort:e=>{q(e.target.value)},handleClearAll:e=>{e.preventDefault(),q(""),C(""),D(10),k(""),L(""),M(1)},categoriesValue:b}),H?(0,t.jsx)(f.default,{length:R,height:62,classOne:"",classTwo:"",classThree:"d-none",heightTwo:""}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{role:"table","aria-label":"Press Release data",children:[(0,t.jsx)(m.default,{numberOfColumns:3,columnOne:"Title",columnTwo:"Published Date",columnThree:"Type/Size"}),(null==Y||null==(e=Y.posts)?void 0:e.length)===0&&(0,t.jsx)(d.default,{}),Y&&(null==Y||null==(l=Y.posts)?void 0:l.length)>0&&(0,t.jsx)(t.Fragment,{children:null==Y||null==(a=Y.posts)?void 0:a.map((e,l)=>{var a,n,r,u,o,i,c,d,f,g,p,v,h,m,_,y,x,R,D,b,A,T,C,E,P,k,z,N,F,L,U,M,I,q,B,W,Y,Z,H,J,K,V,G,Q,X;let $=(e=>e&&Array.isArray(e)?e.reduce((e,l)=>Array.isArray(null==l?void 0:l.file)?e+l.file.length:e+1,0):0)(null==e||null==(a=e.acf_data)?void 0:a.file);return console.log($),(0,t.jsx)(t.Fragment,{children:("NEW"===j.yt?$>1:(null==e||null==(r=e.acf_data)||null==(n=r.file)?void 0:n.length)>1)?(0,t.jsx)(S.A,{index:l,columnOne:"Title",columnTwo:"Published Date",columnThree:"Type/Size",title:null==e||null==(u=e.acf_data)?void 0:u.title,file:null==e||null==(o=e.acf_data)?void 0:o.file,url:(null==e||null==(i=e.acf_data)?void 0:i.url_or_file)==="Url"?null==e||null==(c=e.acf_data)?void 0:c.external_link:"#",fileLength:$,fileYear:(null==e||null==(g=e.acf_data)||null==(f=g.file)||null==(d=f[0])?void 0:d.year)?null==e||null==(h=e.acf_data)||null==(v=h.file)||null==(p=v[0])?void 0:p.year:null==e||null==(m
1=e.acf_data)?void 0:m.year,fileDate:(null==e||null==(_=e.acf_data)?void 0:_.date)?null==e||null==(y=e.acf_data)?void 0:y.date:null==e||null==(x=e.acf_data)?void 0:x.date,searchTerm:O,slug:s||"press-release",post_slug:null==e?void 0:e.post_slug,post_title:null==e?void 0:e.post_title,id:null==e?void 0:e.ID}):(0,t.jsx)(w.A,{index:l,columnOne:"Title",columnTwo:"Published Date",columnThree:"Type/Size",title:null==e||null==(R=e.acf_data)?void 0:R.title,url:(null==e||null==(D=e.acf_data)?void 0:D.url_or_file)==="Url"?null==e||null==(b=e.acf_data)?void 0:b.external_link:"#",fileLength:null==e||null==(T=e.acf_data)||null==(A=T.file)?void 0:A.length,fileYear:(null==e||null==(P=e.acf_data)||null==(E=P.file)||null==(C=E[0])?void 0:C.year)?null==e||null==(N=e.acf_data)||null==(z=N.file)||null==(k=z[0])?void 0:k.year:null==e||null==(F=e.acf_data)?void 0:F.year,fileDate:(null==e||null==(L=e.acf_data)?void 0:L.date)?null==e||null==(U=e.acf_data)?void 0:U.date:null==e||null==(M=e.acf_data)?void 0:M.date,searchTerm:O,slug:s||"press-release",file:null==e||null==(I=e.acf_data)?void 0:I.file,filesize:(null==e||null==(Y=e.acf_data)||null==(W=Y.file)||null==(B=W[0])||null==(q=B.pdf)?void 0:q.filesize)?null==e||null==(K=e.acf_data)||null==(J=K.file)||null==(H=J[0])||null==(Z=H.pdf)?void 0:Z.filesize:null==e||null==(X=e.acf_data)||null==(Q=X.file)||null==(G=Q[0])||null==(V=G.pdf_both)?void 0:V.filesize,post_slug:null==e?void 0:e.post_slug,id:null==e?void 0:e.ID})})})})]}),(0,t.jsx)(c.A,{data:Y,handlePageChange:es,handleNext:eu,handlePrevius:eo,currentPage:U,paginate:e=>{r?(0,g.cR)(n,e,o,r):(0,g.cR)(n,e,o),M(e),ea(R,e,G)},paginateKeyUp:(e,l)=>{"Enter"===e.key&&(M(l),ea(R,l,G))},setCurrentPage:M,pageRoute:s||"press-release"})]})]})};var R=a(79326),D=a(1761);function b(e){var l;let{bannerImage:a,bannerLoad:i,breadcrumbs:c}=e;return(0,t.jsx)(R.A,{children:(0,t.jsxs)(n.default,{pageTitle:null==(l=(0,D.A)(c))?void 0:l[0],children:[(0,t.jsxs)("section",{className:"position-relative",children:[(0,t.jsx)(r.default,{image:(null==a?void 0:a.url)||o.nd||"",alt:(null==a?void 0:a.alt)||(null==a?void 0:a.title),breadcrumbs:c,bannerLoad:i}),(0,t.jsx)(s.default,{navList:u.uZ})]}),(0,t.jsx)("section",{className:"maincontent",role:"main",children:(0,t.jsx)(x,{})})]})})}}}]);
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.