"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[297],{68:function(t,e,n){n.d(e,{Ms:function(){return m},X6:function(){return s},aE:function(){return h},aw:function(){return g},eL:function(){return f},kx:function(){return u},oo:function(){return p},wY:function(){return v}});var a=n(7437),r=n(6696),o=n.n(r),i=n(2265),c=n(4839);const s=t=>{let{loading:e=!1,variant:n="1",required:r,children:o,color:i="text-secondary",className:s="",textAlign:l="text-left",tooltipClassName:u=""}=t;const p="h".concat(n);return(0,a.jsxs)("div",{className:"flex gap-2 ".concat(u),children:[(0,a.jsx)(p,{className:(0,c.Z)("".concat({h1:"text-heading-1",h2:"text-heading-2",h3:"text-heading-3",h4:"text-heading-4 sm:text-heading-4 md:text-heading-h4",h5:"text-heading-5 sm:text-heading-4 md:text-heading-h4",h6:"text-heading-6 sm:text-heading-5 md:text-heading-h6"}["h".concat(n)]," ").concat(s," ").concat(i," ").concat(l)),children:o}),r&&(0,a.jsx)(d,{color:"text-alert-error",children:"*"})]})},l=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=(0,i.forwardRef)(((n,r)=>{let{children:i,color:s="text-primary",textAlign:l="text-left",className:u="",...d}=n;return(0,a.jsx)("p",{ref:r,className:(0,c.Z)(e,o().className,"".concat({"":"text-para","-2":"text-para-2 sm:text-para","-3":"text-para-3 sm:text-para-2"}[t]," ").concat(s||""," ").concat(l," ").concat(u)),...d,children:i})}));return n.displayName="withExtendedParaStyles",n},u=(l(),l("","font-para-semi")),d=l("","font-para-bold"),p=l("-2"),g=l("-2","font-para-semi"),h=l("-2","font-para-bold"),m=l("-3"),f=l("-3","font-para-medium"),v=l("-3","font-para-semi");l("-3","font-para-bold")},2891:function(t,e,n){n.d(e,{r:function(){return a}});const a={AUTH_ID_TOKEN:"AUTH_ID_TOKEN",PRIVATE_AUTH_ID_TOKEN:"PRIVATE_AUTH_ID_TOKEN",HAS_PRIVATE_ACCESS:"HAS_PRIVATE_ACCESS",PREVIEW_MODE_USER_DETAILS:"PREVIEW_MODE_USER_DETAILS",PRIVATE_EMAIL:"PRIVATE_EMAIL"}},2314:function(t,e,n){n.d(e,{O:function(){return a}});const a={METHOD_TYPE:{POST:"POST",PUT:"PUT",GET:"GET",DELETE:"DELETE",PATCH:"PATCH"},CONTENT_TYPE:{APPLICATION_JSON:"application/json",MULTIPART_FORM_DATA:"multipart/form-data",APPLICATION_FORM_URLENCODED:"application/x-www-form-urlencoded",IMAGE_PNG:"image/png",OCTET_STREAM:"application/octet-stream"},HEADERS:{contentType:"Content-Type"}}},856:function(t,e,n){n.d(e,{d:function(){return a}});const a={SUCCESS:"success",ERROR:"error",WARN:"warn",INFO:"info",DEFAULT:"default"}},9188:function(t,e,n){n.d(e,{Z:function(){return p},M:function(){return d}});var a=n(7437),r=n(2265),o=n(9917),i=n(4839),c=n(68),s=n(358);var l=t=>{let{header:e,customIcons:n,children:l}=t;var u;const{isDrawerVisible:p,drawerData:g={},drawerStack:h=[],goBack:m}=d(),f=(0,s.Z)("(min-width:420px)"),v=h[h.length-1],T=g[v]||{},E=e||!(0,r.isValidElement)(T.title)?(0,a.jsx)(c.X6,{variant:"5",children:T.title}):T.title,_=null===T||void 0===T||null===(u=T.metadata)||void 0===u?void 0:u.comp,A=_?(0,a.jsx)(_,{drawerKey:v}):l;return!p||f&&"NDA"===v?null:(0,a.jsx)(o.Y,{visible:p,header:E,onHide:m,icons:n,position:"right",pt:{closeButton:{className:(0,i.Z)("visible",{invisible:(0,r.isValidElement)(T.title)})}},children:A})};const u=(0,r.createContext)({isDrawerVisible:!1,drawerData:{},drawerStack:[],pushToStack:(t,e)=>{},goBack:()=>{}}),d=()=>(0,r.useContext)(u);var p=t=>{let{children:e}=t;const[n,o]=(0,r.useState)(!1),[i,c]=(0,r.useState)({}),[s,d]=(0,r.useState)([]),p=t=>{if(t){const e={...i};delete e[t],c({...e})}d((t=>{const e=[...t];return e.pop(),e.length||o(!1),e}))};(0,r.useEffect)((()=>(window.addEventListener("hashchange",(()=>p())),()=>{window.removeEventListener("hashchange",(()=>null))})),[]);return(0,a.jsxs)(u.Provider,{value:{isDrawerVisible:n,drawerData:i,drawerStack:s,pushToStack:(t,e)=>{const n=[...s];n.push(t),d([...n]),c({...i,[t]:e}),o(!0)},goBack:p},children:[e,(0,a.jsx)(l,{})]})}},6360:function(t,e,n){n.d(e,{Z:function(){return p},v:function(){return d}});var a=n(7437),r=n(2265),o=n(68),i=n(5472),c=n(358),s=n(4839);var l=t=>{let{header:e,children:n}=t;var l;const{isModalOpen:u,modalData:p,modalStack:g,goBack:h}=d(),m=(0,c.Z)("(min-width:420px)"),f=g[g.length-1],v=p[f]||{},T=e||!(0,r.isValidElement)(v.title)?(0,a.jsx)(o.X6,{variant:"6",children:v.title}):v.title,E=null===v||void 0===v||null===(l=v.metadata)||void 0===l?void 0:l.comp,_=E?(0,a.jsx)(E,{drawerKey:f}):n;return m&&u?(0,a.jsx)(i.V,{pt:{closeButton:{className:(0,s.Z)("visible",{invisible:(0,r.isValidElement)(v.title)})}},header:T,visible:u,onHide:h,children:_}):null};const u=(0,r.createContext)({isModalOpen:!1,modalData:{},modalStack:[],pushToStack:(t,e)=>{},goBack:()=>{}}),d=()=>(0,r.useContext)(u);var p=t=>{let{children:e}=t;const[n,o]=(0,r.useState)(!1),[i,c]=(0,r.useState)({}),[s,d]=(0,r.useState)([]);return(0,a.jsxs)(u.Provider,{value:{isModalOpen:n,goBack:t=>{if(t){const e={...i};delete e[t],c({...e})}d((t=>{const e=[...t];return e.pop(),e.length||o(!1),e}))},pushToStack:(t,e)=>{const n=[...s];n.push(t),d([...n]),c({...i,[t]:e}),o(!0)},modalData:i,modalStack:s},children:[e,(0,a.jsx)(l,{})]})}},358:function(t,e,n){var a=n(2265);e.Z=t=>{const[e,n]=(0,a.useState)(!1);return(0,a.useEffect)((()=>{const e=window.matchMedia(t),a=t=>{t.matches?n(!0):n(!1)};return e.addListener(a),e.matches&&n(!0),()=>e.removeListener(a)}),[t]),e}},4561:function(t,e,n){n.d(e,{DY:function(){return u},mK:function(){return d}});var a=n(2314),r=n(920),o=n(7185),i=n.n(o),c=n(3700),s=n(2891);const l=async function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a.O.METHOD_TYPE.GET,n=arguments.length>2?arguments[2]:void 0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},l=arguments.length>4?arguments[4]:void 0;try{const u=await function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a.O.METHOD_TYPE.GET,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return i()(t,{cache:"no-cache",headers:{"auth-id-token":"Bearer ".concat((0,c.u_)(s.r.AUTH_ID_TOKEN)),"auth-access-token":"Bearer ".concat((0,c.u_)(s.r.AUTH_ID_TOKEN)),"content-type":"application/json","vault-token":"".concat((0,c.u_)(s.r.PRIVATE_AUTH_ID_TOKEN)),...r},method:e,...n&&{body:JSON.stringify(n)}})}(t,e,n,o),d=await(0,r.W0)(u,o,l);return u.headers.get("has_private_access")&&(0,c.hU)(s.r.HAS_PRIVATE_ACCESS,String(u.headers.get("has_private_access")).replace("Bearer ","")),d}catch(u){throw u}},u=(t,e,n)=>l(t,a.O.METHOD_TYPE.GET,null,e,n),d=(t,e,n)=>l(t,a.O.METHOD_TYPE.POST,e,n)},3332:function(t,e,n){var a=n(3700),r=n(4561),o=n(2891),i=n(920),c=n(2314);const s="https://app.scrut.io/api/v1/trustCenterService",l={getFrameworks:async()=>(0,r.DY)("".concat(s,"/trust-center/getframework")),getFrameworkLogo:async function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,r.DY)("".concat(s,"/trust-center/download?fileName=").concat("gomigo-prod","/").concat(t.logo),{"Content-Type":c.O.CONTENT_TYPE.OCTET_STREAM,"auth-id-token":"Bearer ".concat((0,a.u_)(o.r.AUTH_ID_TOKEN)),"auth-access-token":"Bearer ".concat((0,a.u_)(o.r.AUTH_ID_TOKEN)),"vault-token":"".concat((0,a.u_)(o.r.PRIVATE_AUTH_ID_TOKEN))})},getAllSubProcessors:async()=>(0,r.DY)("".concat(s,"/sub-processor/get-all")),getAllControls:async()=>(0,r.DY)("".concat(s,"/get-all/controller")),getDomain:async t=>(0,r.mK)("".concat(s,"/domainConnector/get-domain"),{domain:t}),logActivity:async t=>(0,r.mK)("".concat("https://app.scrut.io/api/v1/trustCenterService","/trust-center/log-activity"),t),downloadFile:(t,e)=>{const n=(0,i.v3)(t).replace("fileUploaderService/get","trustCenterService/trust-center/download");return(0,r.DY)(n,{"Content-Type":c.O.CONTENT_TYPE.OCTET_STREAM,Authorization:"Bearer ".concat((0,a.u_)(o.r.AUTH_ID_TOKEN)),"auth-id-token":"Bearer ".concat((0,a.u_)(o.r.AUTH_ID_TOKEN)),"auth-access-token":"Bearer ".concat((0,a.u_)(o.r.AUTH_ID_TOKEN))},e)},getUpdateDetailList:()=>(0,r.DY)("".concat(s,"/trust-center/update-details")),getFAQList:()=>(0,r.DY)("".concat(s,"/trust-center/faqs")),verifyPrivateToken:t=>(0,r.DY)("".concat(s,"/trust-center/getCompanyById?companyId=").concat(t)),updateNDA:t=>(0,r.mK)("".concat(s,"/trust-center/updateNda"),{companyId:t}),fetchNDA:(t,e)=>(0,r.mK)("".concat(s,"/trust-center/fetch-nda-agreement"),{companyId:e,email:t}),getCompanyDetails:t=>(0,r.DY)("".concat(s,"/trust-center/getCompanyById?companyId=").concat(null!==t&&void 0!==t?t:"")),getOrganizationDetails:()=>(0,r.DY)("".concat(s,"/trust-center/organizationDetails")),getOrgNameList:t=>(0,r.DY)("".concat(s,"/trust-center/companyNames?q=").concat(t)),getCountryList:t=>(0,r.mK)("".concat(s,"/trust-center/utils/getCountryList"),{countryName:t}),getCountryStates:t=>(0,r.mK)("".concat(s,"/trust-center/utils/getCountryStates"),{countryName:t}),requestAccessRights:t=>(0,r.mK)("".concat(s,"/trust-center/req-access-rights"),t)};e.Z=l},5600:function(t,e,n){n.d(e,{$:function(){return c},l:function(){return i}});var a=n(9099);const r={severity:"",message:"",customUIKey:"",overrideComponent:null,life:1/0},o=(0,a.Ue)((t=>({notification:r,actions:{showNotification:e=>{let{severity:n,message:a,customUIKey:r,overrideComponent:o,life:i}=e;return t((t=>({...t,notification:{...t.notification,severity:n,message:a,customUIKey:r,overrideComponent:o,life:i}})))},hideNotification:()=>t((t=>({...t,notification:r})))}}))),i=()=>o((t=>t.notification)),c=()=>o((t=>t.actions))},920:function(t,e,n){n.d(e,{V7:function(){return s},W0:function(){return c},v3:function(){return i}});var a=n(2891),r=n(2314),o=n(3700);const i=t=>t.includes("api-dev.scrut.io:3006")?t.replace("api-dev.scrut.io:3006","api-dev.scrut.io/api/v1/fileUploaderService"):t.includes("api-stage.scrut.io:3006")?t.replace("api-stage.scrut.io:3006","api-stage.scrut.io/api/v1/fileUploaderService"):t.includes("app.scrut.io:3006")?t.replace("app.scrut.io:3006","app.scrut.io/api/v1/fileUploaderService"):t.includes("api-dev.gomigo.io:3006")?t.replace("api-dev.gomigo.io:3006","api-dev.scrut.io/api/v1/fileUploaderService"):t.includes("api-stage.gomigo.io:3006")?t.replace("api-stage.gomigo.io:3006","api-stage.scrut.io/api/v1/fileUploaderService"):t.includes("app.gomigo.io:3006")?t.replace("app.gomigo.io:3006","app.scrut.io/api/v1/fileUploaderService"):t,c=async(t,e,n)=>{if(n){return await t.arrayBuffer()}if(e["Content-Type"]===r.O.CONTENT_TYPE.OCTET_STREAM){return await t.blob()}return await t.json()},s=()=>"true"===(0,o.u_)(a.r.HAS_PRIVATE_ACCESS)},3700:function(t,e,n){n.d(e,{GI:function(){return i},hU:function(){return r},u_:function(){return o}});const a=new(n(5263).Z),r=(t,e)=>{a.set(t,JSON.stringify(e),{path:"/"})},o=t=>a.get(t),i=t=>{a.remove(t,{path:"/"})}},1693:function(t,e,n){n.d(e,{Bd:function(){return f},K8:function(){return m},M_:function(){return h},YQ:function(){return g},aj:function(){return s},au:function(){return l},bX:function(){return d},cq:function(){return v},tn:function(){return p},w8:function(){return u}});var a=n(1838),r=n.n(a),o=n(9089),i=n(3700),c=n(2891);const s=t=>{if(t)try{const e=t.split(".")[1].replace("-","+").replace("_","/");return function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"{}";try{return JSON.parse(t)}catch(e){console.log("JSON parsing error")}return{}}(window.atob(e))}catch(e){return}},l=t=>r().sanitize(t,{ADD_ATTR:["target"]}),u=t=>new Promise((e=>{const n=new FileReader;n.onloadend=()=>e(n.result),n.readAsDataURL(t)})),d=t=>t.includes("data:image/")?t:t.includes("data:application/octet-stream")?t.replace("data:application/octet-stream","data:image/svg+xml"):t.includes("data:application/xml")?t.replace("data:application/xml","data:image/svg+xml"):t.includes("data:image/x-icon")?t.replace("data:image/x-icon","data:image/png"):"",p=t=>{switch(null===t||void 0===t?void 0:t.toString()){case"1":return"No NDA";case"2":return"Clickwrap";case"3":return"Signed outside Scrut Automation";default:return""}},g=t=>{window.open(t,"_blank")},h=t=>{const e=s(t)||{};let n="";return(null===e||void 0===e?void 0:e.firstName)&&(n=(null===e||void 0===e?void 0:e.lastName)?"".concat(e.firstName," ").concat(e.lastName):"".concat(e.firstName)),{firstName:(null===e||void 0===e?void 0:e.firstName)||"Anonymous",lastName:(null===e||void 0===e?void 0:e.lastName)||"Anonymous",email:(null===e||void 0===e?void 0:e.userEmail)||(0,i.u_)(c.r.PRIVATE_EMAIL)||"Anonymous",name:n||"Anonymous",tenantId:(null===e||void 0===e?void 0:e.tenantId)||""}},m=async(t,e,n,a,r)=>{try{const i=await o.PDFDocument.load(t),c=(t,a)=>{let r=.8;return r="0"!==e||n?t.length<=20?.9:t.length>20&&t.length<=30?.8:t.length>30&&t.length<=35?.75:.7:.7,t.length*r*a},s="0"!==e||n?a.private:a.public,l="".concat(r.firstName," ").concat(r.lastName," (").concat(r.email,")"),u=c(l,20);i.getPages().map((t=>{const{width:r,height:i}=t.getSize();let c=(1-u/r)/1.5;("1"===e||n)&&r<650&&l.length>30&&(c=.15),t.drawRectangle({x:r*c,y:.3*i,width:u,height:"0"!==e||n?85:60,color:(0,o.rgb)(.941,.941,.941),opacity:.5,rotate:(0,o.degrees)(35)}),t.drawText(s,{x:"0"!==e||n?r*c-20:r*c+20,y:"0"!==e||n?.3*i+50:.3*i+45,size:20,opacity:a.opacity,color:(0,o.rgb)(0,0,0),rotate:(0,o.degrees)(35),lineHeight:40,maxWidth:r})}));return{pdfBytes:await i.save(),isEncrypted:i.isEncrypted}}catch(i){return{pdfBytes:t,isEncrypted:!1}}},f=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return t.startsWith("https://")?t:"https://".concat(t)},v=t=>t.replace(/(\b(https:\/\/|www\.)[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/gi,(t=>'<a  href="'.concat(f(t),'" target="_blank">').concat(t,"</a>")))}}]);