PageSourceSearch

https://complaints.financial-ombudsman.org.uk/static/js/853.c55f3597.chunk.js

js financial-ombudsman.org.uk collected 2026-09-24 08:40:13 UTC 248,048 bytes, 2 lines download raw bytes

1(self.webpackChunkmy_app=self.webpackChunkmy_app||[]).push([[853],{7153(e,t,i){"use strict";i.d(t,{A:()=>a});i(5043);const a=i.p+"static/media/Icon_Warning_MUP.02344acdd006289e1567f8b7d124d514.svg"},4337(e,t,i){"use strict";i.d(t,{A:()=>a});i(5043);const a=i.p+"static/media/Icon_Warning_download.ca9652ba39c98a22ecabfebb1a45b43c.svg"},3490(e,t,i){"use strict";i.d(t,{A:()=>a});i(5043);const a=i.p+"static/media/check-circled-outline.49bb4b47a02fd492e89d357a87736e90.svg"},5691(e,t,i){"use strict";i.d(t,{A:()=>a});i(5043);const a=i.p+"static/media/download_Pdf.4e8132f9d895718585ffe3681a73eeee.svg"},6798(e,t,i){"use strict";i.d(t,{o:()=>a});const a="DD/MM/YYYY"},3360(e,t,i){"use strict";i.d(t,{c:()=>a});const a={SERVICES:{getMetaData:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/download/getlistoffilescomplainants",getSharedConfiguration:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/getsharedconfiguration",getSasToken:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/upload/getfilesastoken",postMetadata:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/upload/uploadmetadata",postUploadCompleted:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/upload/uploadcompleted",postDelete:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/upload/delete",getRequestdownloadforfiles:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/download/requestdownloadforfiles",getDownloadsastokens:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/download/getdownloadsastokens",getAvailableForDownloadRequests:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/download/getavailablefordownloadrequests",getAllPackageStatuses:"compdocumentmanagement/compdocumentmanagement/v1/documentservice/upload/getallpackagestatuses"}}},4593(e,t,i){"use strict";i.r(t),i.d(t,{default:()=>qa});var a=i(5544),o=i(9379),n=i(45),s=i(6446),l=i(5043),r=i(3216),d=i(3018),c=i(233),m=i(5151),p=i(579);const u=(0,m.A)({bouncingLoader:{display:"flex",justifyContent:"center","& div":{width:"1rem",he
1ight:"1rem",margin:"3px 6px",borderRadius:"50%",backgroundColor:"#2273C3",animation:"$bouncing-loader 2s infinite ease-in"},"& div:nth-child(2)":{animationDelay:"0.4s"},"& div:nth-child(3)":{animationDelay:"0.8s"},"& div:nth-child(4)":{animationDelay:"1.2s"},"& div:nth-child(5)":{animationDelay:"1.6s"}},"@keyframes bouncing-loader":{"0%":{opacity:0},"50%":{opacity:1},"100%":{opacity:0}},loaderText:{fontFamily:"AssistantRegular",color:"#404040",marginBlock:"0",marginTop:"0.5625rem",fontSize:"1.25rem",textAlign:"center"},loaderContainer:{padding:"5rem",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center"}});function g(){const e=u();return(0,p.jsxs)("div",{className:e.loaderContainer,role:"alert","aria-label":"Please wait. Your data is in progress",children:[(0,p.jsxs)("div",{className:e.bouncingLoader,children:[(0,p.jsx)("div",{}),(0,p.jsx)("div",{}),(0,p.jsx)("div",{}),(0,p.jsx)("div",{}),(0,p.jsx)("div",{})]}),(0,p.jsx)("p",{className:e.loaderText,children:"Please wait..."})]})}var h=i(9925),x=i(4058);const f=(0,m.A)({stepperContainer:{border:"1px solid #CFCFCF",opacity:"1",paddingLeft:"1rem",paddingRight:"1rem",paddingBottom:"1.5rem","@media(max-width: 500px)":{paddingLeft:"0rem"}},caseprogressTooltip:{display:"flex",alignItem:"center"},complaintsContainer:{display:"grid",gridTemplateColumns:"49fr 17fr",gridGap:"2.5rem","@media (max-width: 995px)":{display:"block"}},viewContainer:{border:"1px solid #D3D4D4",marginTop:"2rem","@media(max-width:1024px)":{display:"block"}},caseDetailsContainer:{display:"flex","@media(max-width:767px)":{padding:"0",display:"block"}},docContainer:{overflowX:"hidden"},textStyling:{fontSize:"24px",fontFamily:"AssistantSemiBold",color:"#000000",paddingTop:"0.5rem",display:"flex"},textStylingFirst:{fontSize:"20px",fontFamily:"AssistantSemiBold",color:"#4B4B4B",paddingLeft:"1rem",marginTop:"5px"},helpsectionContainer_second:{display:"flex",gap:"1.5rem","@media (max-width:1024px)":{display:"block"},"@media (max-width:768px)":{display:"block"}},vl:{borderLeft:"3px solid #EAEAEA",height:"24px",marginLeft:"15px","@media(max-width:767px)":{display:"flex",float:"right"}},textStyling1:{fontSize:"20px",fontFamily:"AssistantSemiBold",color:"#404040",paddingLeft:"1rem"},collapsedSummary:{display:"none"},summaryBody:{marginTop:"0.625rem",padding:"2rem 1.5rem",backgroundColor:"#4040401F",border:"1px solid #CFCFCF","@media (max-width: 1370px)":{display:"block"},"@media(max-width:767px)":{padding:"1rem"}},emptyDiv:{display:"flex",justifyContent:"center",gap:"148px","@media (max-width: 767px)":{display:"block",padding:"1rem"}},emptyText:{fontSize:"1.375rem",color:"#767676",fontFamily:"AssistantSemiBold"},emptyMessageContainer:{backgroundColor:"#fff"},emptyMessageDiv:{display:"flex",justifyContent:"center",padding:"10rem","@media(max-width:767px)":{padding:"2rem",display:"block",textAlign:"center"}},emptyMessageSpan:{fontSize:"1.75rem",fontFamily:"AssistantSemiBold",color:"#767676","@media(max-width:767px)":{fontSize:"1.25rem"}},userData:{display:"flex",flexWrap:"wrap",marginBottom:"1rem","@media(max-width:767px)":{display:"block",fontSize:"1.25rem"}},userWelcome:{fontSize:"2.5rem",color:"#3971BD",fontFamily:"AssistantSemiBold",margin:"1rem 0 1.5rem 0",lineHeight:"1.813rem","@media(max-width:767px)":{display:"block",fontSize:"1.5rem"}},userDesc:{fontSize:"1.375rem",color:"#404040",fontFamily:"AssistantRegular","@media(max-width:767px)":{display:"block"}},savebutton:{paddingRight:"18px"},viewcasebutton:{},caseDetails:{backgroundColor:"#ffffff"},caseRefContainer:{display:"flex",justifyContent:"space-between",alignItems:"center",padding:"0rem","@media(max-width:967px)":{display:"block",padding:"1rem"}},caseRefContainerSecond:{display:"flex",justifyContent:"space-between",alignItems:"center",padding:"1.2rem 0",backgroundColor:"#E4EEF8","@media(max-width:967px)":{display:"block",padding:"1rem"}},caseRefContainerThird:{display:"flex",marginTop:"4px",justifyContent:"space-between",alignItems:"center",backgroundColor:"#F7F7F7",padding:"0.6rem 0","@media(max-width:767px)":{display:"block",padding:"1rem"}},caseRefContainer1:{display:"flex",justifyContent:"space-between",alignItems:"center",borderBottom:"1px solid #cfcfcf4d",padding:"0.2rem 0",border:"1.2px solid #cfcfcf4d","@media(max-width:767px)":{display:"block",padding:"1rem"}},refTitle:{fontSize:"1.25rem",color:"#4B4B4B",fontFamily:"AssistantRegular",marginRight:"1rem",lineHeight:"2.25rem",paddingLeft:"1rem","@media(max-width:1024px)":{fontSize:"1.25rem",color:"#404040",paddingLeft:"0"},"@media(max-width:767px)":{display:"block"}},refVal:{fontSize:"1.5rem",color:"#271C6F",marginTop:"0.5rem",fontFamily:"AssistantSemiBold",lineHeight:"2.25rem","@media(max-width:1024px)":{marginBottom:"1.5rem",marginTop:"0rem"}},refValue:{fontSize:"1.375rem",marginLeft:"1rem","@media(max-width:1024px)":{fontSize:"1.375rem",color:"#404040",marginLeft:0,fontFamily:"AssistantSemiBold"}},priorityTitle:{display:"flex",alignItems:"center",backgroundColor:"#FFFFFF",fontSize:"1.375rem",color:"#404040",fontFamily:"AssistantRegular",padding:"0.2rem 1rem 0.2rem 0.6rem",marginRight:"1.175rem","@media(max-width:1024px)":{fontSize:"1.25rem",color:"#404040"},"@media(max-width:767px)":{display:"block"}},priorityVal:{display:"flex",fontSize:"1.375rem",color:"#404040",fontFamily:"AssistantSemiBold",paddingRight:"10px"},caseDetailsData:{marginTop:"0.625rem",boder:"1px solid #D3D4D4"},casetabContainer:{marginTop:"3rem",border:"1.2px solid #D3D4D4"},cardInfoLeft1:{paddingLeft:"15px",display:"flex",width:"70%",flexWrap:"wrap",padding:"2rem 1.5rem",backgroundColor:"#FFFFFF",boder:"1px","@media(max-width:767px)":{width:"100% !important",padding:"1rem 1rem 1.5rem"}},cardInfoLeftBorder:{borderRight:"1px solid rgb(118, 118, 118, 20%)",paddingLeft:"1rem","@media(max-width:1024px)":{borderRight:"none",paddingLeft:"0",maxWidth:"100%"},"@media(max-width:899px)":{marginBottom:"1.5rem"},"@media(max-width:767px)":{marginBottom:"1.5rem"}},cardInfoLeftChild1:{display:"flex",color:"#767676",fontFamily:"AssistantRegular",fontSize:"1.375rem","& span":{display:"grid",gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",fontFamily:"AssistantSemiBold"},"@media(max-width:1024px)":{fontSize:"1.25rem",gap:"0",display:"block","& span":{fontSize:"1.375rem"}}},cardInfoLeftChild1Tool:{display:"grid",gap:"0.25rem",color:"#767676",fontFamily:"AssistantRegular",fontSize:"1.375rem",cursor:"pointer","& span":{display:"grid",gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",fontFamily:"AssistantSemiBold"},"@media(max-width:1024px)":{fontSize:"1.25rem",gap:"0",display:"block","& span":{fontSize:"1.375rem"}}},helpsectionContainer:{display:"flex",gap:"1.25rem",marginTop:"4.125rem"},investiGatorStyle:{fontFamily:"AssistantSemiBold",marginTop:"0.563rem",display:"flex !important","@media(max-width:767px)":{display:"grid !important",gap:"0.5rem !important"}},viewinvestiGatordetailsFirst:{fontFamily:"AssistantSemiBold",marginTop:"0.563rem",display:"flex !important",alignItems:"right","@media(max-width:767px)":{display:"grid !important",gap:"0.5rem !important"}},trackyourcaseStyle:{display:"flex",background:"#2373C3 0% 0% no-repeat padding-box",padding:"12px 45px",marginTop:"30px",fontSize:"5px",cursor:"pointer",height:"20px",width:"273px","@media(max-width:767px)":{display:"block"}},casebuttons:{},cardInfoLeft2:{margin:"1.25rem 0 2rem 0","@media(max-width:899px)":{display:"block"},"@media(max-width:767px)":{display:"block"}},cardBottomBtn:{marginTop:"3.125rem",display:"flex",justifyContent:"flex-start",alignItems:"center",paddingTop:"0px !important","@media(max-width:767px)":{padding:0,display:"block"}},cardBottomBtnList:{padding:"0 1.25rem 0 0","@media(max-width:1024px)":{padding:"0 1.25rem 1.25rem 0"},"& Button":{padding:"0.438rem 1.5rem",fontFamily:"AssistantSemiBold",fontSize:"1.25rem","@media(max-width:767px)":{width:"100% !important"}},"& a":{"& Button":{"@media(max-width:767px)":{width:"100% !important"}}},"@media(max-width:767px)":{padding:0,marginBottom:"1rem"}},tabsContainer:{display:"flex",paddingRight:"0.125rem","@media(max-width:10paddingRight: '0.125rem',24px)":{display:"block",paddingRight:"0.125rem",boxSizing:"border-box"}},tabs:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",width:"100%",background:"#FFFFFF 0% 0% 
1no-repeat padding-box",opacity:"1",margin:"1.5rem 0",color:"#232323",border:"1px solid #D3D4D4","@media(max-width:967px)":{padding:0,display:"block"}},helpSection:{width:"30%",display:"flex",flexWrap:"wrap",float:"right",marginTop:"-717px",alignItems:"flex-start",padding:"2rem 1.5rem",height:"fit-content","@media(max-width:967px)":{width:"100% !important",paddingLeft:"0",display:"block"}},needHelp:{},helpTitle:{"&:span":{fontFamily:"AssistantSemiBold",fontSize:"1.25rem"}},lastGrid:{paddingLeft:"1.5rem","@media(max-width:899px)":{paddingLeft:"0"},"@media(max-width:767px)":{paddingLeft:"0"}},caseInvestigatorLinkParent:{display:"flex",alignItems:"center",fontSize:"1.5rem",fontFamily:"AssistantSemiBold",Color:"#D22D65",paddingRight:"2.125rem","@media(max-width:540px)":{width:"100%",display:"block",padding:0},"@media (min-device-width: 541px)  and (max-device-width: \t767px)":{width:"100%",display:"block",padding:0},"@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{width:"100%",display:"block"}},caseInvestigatorLink:{display:"flex",alignItems:"center",fontSize:"1.5rem",marginLeft:"1.1rem",fontFamily:"AssistantSemiBold",Color:"#D22D65","&:hover":{textDecoration:"underline",textUnderlineOffset:"2px",cursor:"pointer"},"@media(max-width:767px)":{marginLeft:"0",display:"table-caption"},"& span":{color:"#D22D63 !important"},"@media(max-width:540px)":{width:"100%",display:"block",padding:0},"@media (min-device-width: 541px)  and (max-device-width: \t767px)":{width:"100%",display:"block",padding:0},"@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{width:"100%",display:"block"}},caseprogressLink:{color:"#2373C3",fontSize:"1.5rem"},caseInvestigatorLink2:{display:"flex",alignItems:"center",textDecoration:"none",fontSize:"1.25rem",marginLeft:"1.5rem","&:hover":{textDecoration:"underline",textUnderlineOffset:"5px"},"@media(max-width:767px)":{marginLeft:"0"},"& span":{color:"white !important"}},contactPhoneIcon:{paddingRight:"0.5rem"},threedotMenu:{color:"#D22D64","&:focus-visible":{backgroundColor:"white",outline:"2px solid black",boxShadow:"none"},"&:hover":{backgroundColor:"#DADADA"}},threedotoptions:{display:"flex"},menuButton:{display:"block",padding:"0.5rem 1rem",borderRadius:"24px",fontSize:"1.25rem",fontFamliy:"AssistantSemiBold",cursor:"pointer",color:"#D22D64"},menuButtonOutline:{color:"#D22D64",border:"2px solid #D22D64",background:"#FFFFFF"},dropdown:{marginLeft:"4px"},imgExpand:{height:"26px",width:"30px",marginBottom:"-6px"},tabContainer:{"& >.MuiTabs-scroller":{"& >.MuiTabs-flexContainer":{"& >.MuiTab-root":{fontFamily:"AssistantSemiBold",padding:"1rem 3.5rem",textTransform:"inherit",backgroundColor:"#DFEFFF","@media(max-width:767px)":{padding:"0.75rem 0.5rem"}},"& >.Mui-selected":{backgroundColor:"#ffffff"}}}},caseTabs:{display:"grid",gap:"4px",cusror:"default",textAlign:"left"},innerTabDesc:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"default","@media(max-width:1024px)":{fontFamily:"AssistantRegular",overflow:"hidden",display:"inline-block",fontSize:"1.125rem"}},innerTabLabel:{font:"1.25rem AssistantRegular",marginRight:"0.5rem",cursor:"pointer",display:"flex",alignItems:"center",color:"#767676"},businessName:{fontSize:"1.625rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"default",lineHeight:"2.25rem","@media(max-width:1024px)":{fontSize:"1.375rem",overflow:"hidden",whiteSpace:"nowrap",width:"13.75rem",display:"inline-block",textOverflow:"ellipsis"}},businessNameTool:{paddingRight:"0.625rem",fontSize:"1.625rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"pointer",lineHeight:"2.25rem","@media(max-width:1024px)":{fontSize:"1.375rem",display:"inline-block"}},caseStageDesc:{fontSize:"1.25rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"default","@media(max-width:1024px)":{fontFamily:"AssistantRegular",width:"13.75rem",display:"inline-block",fontSize:"1.125rem"}},caseStageTitle:{fontSize:"1.25rem",fontFamily:"AssistantRegular",marginRight:"0.75rem",color:"#767676"},duplicateStatus:{display:"flex !important"},cardInfo1:{borderBottom:"1px solid #cfcfcf4d",paddingBottom:"1.25rem","@media(max-width:1024px)":{borderBottom:"1px solid #cfcfcf4d",paddingBottom:"1.5rem"}},trackCaseTab:{marginTop:"0.12rem",backgroundColor:"white","@media(max-width:1024px)":{padding:"0"}},helpContainer:{},expandBtn:{cursor:"pointer",marginLeft:"1.5rem"},actionContainer:{width:"100%",backgroundColor:"#2273C3",padding:"1.5rem",marginBottom:"1.635rem"},actionDiv:{display:"inline-flex"},actionTextDiv:{display:"flex",alignItems:"center",marginBottom:"0.5rem",maxWidth:"69.438rem",justifyContent:"space-between"},actionText:{display:"flex"},actionDate:{display:"flex",alignItems:"center"},duedateText:{fontFamily:"AssistantSemiBold",fontSize:"1.5rem",color:"#ffffff",marginLeft:"0.5rem"},actionReq:{marginLeft:"1rem",color:"#ffffff",fontFamily:"AssistantSemiBold",fontSize:"1.5rem","@media(max-width:1024px)":{fontSize:"1.375rem"}},actionTextDesc:{color:"#ffffff",fontFamily:"AssistantRegular",fontSize:"1.25rem",marginLeft:"2.375rem"},assignedInvestigator:{paddingLeft:"1rem","@media(max-width:1024px)":{paddingLeft:"0"}},CaseDetailsTab:{"& >.MuiTabs-scroller":{"& >.MuiTabs-flexContainer":{"& >.MuiTab-root":{fontFamily:"AssistantSemiBold",padding:"1.5rem",textTransform:"inherit",backgroundColor:"#DFEFFF","@media(max-width:767px)":{padding:"0.75rem 0.5rem"}},"& >.Mui-selected":{backgroundColor:"#ffffff",minWidth:"40%",cursor:"default",display:"grid",justifyContent:"flex-start","@media(max-width:767px)":{maxWidth:"90%",display:"grid",justifyContent:"flex-start"}}}}}
1,casesDesc:{display:"flex",flexWrap:"wrap",marginTop:"-24px",marginBottom:"17px",alignItems:"center",justifyContent:"space-between",fontSize:"1.25rem","@media(max-width:767px)":{display:"block",padding:"0"}},casepDesc:{fontFamily:"AssistantRegular"},caseLink:{marginTop:"0.50rem",marginLeft:"0.875rem",fontSize:"1.25rem",color:"#2273C3",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.25rem"},"&:hover":{textDecoration:"underline",textUnderlineOffset:"5px"}},caseLink2:{marginTop:"0.50rem",marginLeft:"1.455rem",fontSize:"1.25rem",color:"#2273C3",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.25rem"}},outcomeLink:{textDecoration:"underline",cursor:"pointer",marginLeft:"5px"},linkContainer:{display:"flex","@media(max-width:767px)":{display:"block",textAlign:"right"}},paddingLeftNone:{paddingLeft:"0"},toolIcon:{gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",marginLeft:"5px",fontFamily:"AssistantSemiBold","@media(min-width:767px)":{display:"none"}},customTooltip:{backgroundColor:"#E4EEF8",color:"black",maxWidth:"15.75rem",textAlign:"center",height:"auto",padding:"1.25rem",border:"1px solid #82AFDD",font:"1.25rem AssistantRegular"},customArrow:{color:"#E4EEF8","&::before":{border:"1px solid #82AFDD"}},toolIconDesktop:{gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",marginLeft:"5px",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{display:"none"}},toolIconDesktop2:{float:"right",gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",marginLeft:"-2px",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{display:"block"}},toolIconDesktop3:{color:"#D22D65",marginLeft:"6px",marginBottom:"-6.3px",width:"35px",height:"35px",marginTop:"-2.8px","@media(max-width:767px)":{display:"block"}},viewCaseStyle:{marginLeft:"10PX",fontSize:"1.625rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"pointer",display:"flex",lineHeight:"2.25rem","@media(max-width:1024px)":{fontSize:"1.375rem",display:"flex"}},businessNameTool2:{fontSize:"1.625rem",fontFamily:"AssistantSemiBold",color:"#404040",cursor:"pointer",display:"flex",lineHeight:"2.25rem","@media(max-width:1024px)":{fontSize:"1.375rem",display:"flex"}},cardInfoLeftChild1Tool2:{display:"grid",gap:"0.25rem",color:"#767676",fontFamily:"AssistantRegular",fontSize:"1.375rem",cursor:"pointer","& span":{display:"flex",alignItems:"center",gap:"0.25rem",color:"#404040",fontSize:"1.5rem",lineHeight:"1.875rem",fontFamily:"AssistantSemiBold"},"@media(max-width:1024px)":{fontSize:"1.25rem",gap:"0",display:"block","& span":{fontSize:"1.375rem"}}},issueSpan:{display:"flex",alignItems:"center"},caseprogressdesc:{paddingTop:"1rem",fontFamily:"AssistantRegular",fontSize:"20px","@media(max-width: 500px)":{paddingLeft:"1rem"}},helpLink:{padding:"0rem",border:"0rem",backgroundColor:"white",fontSize:"20px",color:"#D22D64",textDecoration:"underline",fontFamily:"AssistantSemiBold",cursor:"pointer"},caseprogresstitle:{marginBottom:"0rem",fontSize:"24px",color:"#000000",marginTop:"0.5rem",fontFamily:"AssistantSemiBold","@media(max-width: 500px)":{paddingLeft:"1rem"}}}),v=[{pageTitle:"Welcome",pageDescriptions:"You can check and see all the updates for your case(s).",caseReference:"Case reference number:",priorityCase:"Case type:",markedPriority:"Marked for Priority",caseAccepted:"We accepted this case on",complaintIssue:"Complaint issue",caseSubmitted:"You submitted this case on",product:"Product",currentStatus:"Current status",assignedInvestigator:"Assigned investigator",updateCase:"Update case information",uploadDoc:"Upload documents",withdrawCase:"Withdraw case",needHelp:"Need help?",cardTitle:"Typical timescales for resolving your complaint",cardDetails:"When you first send us information about your complaint, you should hear back from us within 10 working days",cardButton:"See how long it takes",cardTitle1:"Telling us about your circumstances",cardDetails1:"If you\u2019re facing financial hardship or severe ill health and feel your complaint needs to be dealt with urgently, please let us know when you send us your complaint - or update your case handler direct.",cardButton1:"Call our helpline",viewInvestigator:"Investigator details",viewCaseInformation:"View Complete Case details",awaitingAction:"Awaiting your action",awaitingActionInfo:"This case is in investigation stage and has a 'View outcome' available to review You can refer to the details in ",awaitingActionLink:"Case outcomes section",needHelpText:"If you wish to contact investigator, please click on the link for details.",needHelpLink:"Investigator details",moreActions:"More actions",casePartiesTh1:"Name",casePartiesTh2:"Role",caseAboutTooltip:"About your case",businessTooltip:"Raised against the business",emptyMessage:"You do not have any active cases registered with Financial Ombudsman Service.",caseabout:"This case is about",caseProgress:"Case Progress",field_save_and_download_title:"Select option to save and download the case information",field_summarydetails:"Summary details (including Case Parties)",field_casedocument:"Case documents",field_caseoutcomesdetails:"Case Outcomes",field_select_all:"Select All",field_makey
1ourselectionhere:"Select Option here",field_casepartiesdetails:"Case Parties",field_casetype:"Case Type",field_cancel:"Cancel",field_continuetosave:"Continue",caseoverview_title:"Complete case details",case_reference_number:"Case reference number",case_progress:"Case Progress",you_submitted_this_case_on:"You submitted this case on",we_started_our_investigation_on:"We started our investigation on",investigator_email_address:"investigator email address",investigator_name:"investigator name",case_progress_status:"case progress status",what_the_case_is_about:"what the case is about",complaint_issue:"complaint issue",product_against_business:"product against business"}],b=[{on_hold:"On hold",waiting_for_details:"Waiting for details",researching:"Researching",awaiting_action:"Awaiting Action",awaiting_res:"Awaiting response",problem_solved:"Problem solved",information_provided:"Information provided",resolved:"Resolved",cancelled:"Cancelled",in_progress:"In Progress",highly_complex:"Highly Complex",merged:"Merged"}],y=[{settingComplaint:"We are setting up your complaint",complaintHearing:"We are waiting to hear from the buisness",complaintAllocation:"Your complaint is waiting to be allocated to an investigator",complaintInvestigation:"An investigator is looking into your complaint",complaintView:"The investigator has sent their view",complaintResolved:"Your complaints has now been resolved",helpandGuidance:"To Know more about timelines, read our ",helpandGuideLink:"help and guide documents",investigationComplete:"Investigation is complete",allocationOmbudsman:"Your complaint is waiting to be allocated to an ombudsman",investigationOmbudsman:"An ombudsman is looking into your complaint",investigationDecision:"The ombusman has sent their decision"}],w=[{file_name:"File name",orignator:"Orignator",document_type:"Document type",created_on:"Created On",file_type:"File type",file_comments:"File comments"}],S=[{message_orignator:"Message Orignator",message:"Message",created_on:"Created On"}];var A=i(1772),C=i(7739),j=i(2055),k=i(9529),D=i(4669),F=i(4056),R=i(8855),B=i(2497);i.p;const _=(0,m.A)({astrikColor:{color:"#D22D64"},dialogTitle:{margin:0,fontSize:"1.75rem",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.375rem"}},keyTitle:{color:"#40404099",fontSize:"1.25rem",fontFamily:"AssistantRegular"},caseRefContainer:{marginTop:"-5rem",fontFamily:"AssistantSemiBold",padding:"0 1.25rem"},paper:{minWidth:"45rem","@media(max-width:767px)":{minWidth:"85%"}},dialogHeader:{display:"flex",justifyContent:"center",color:"#D22D64"},discardBtn:{padding:"0.688rem 1.5rem",color:"#D22D64",borderRadius:"1.5rem",backgroundColor:"#FFFFFF",border:"0.0625rem solid #D22D64",fontSize:"1.25rem",fontFamily:"Assistant",opacity:"1",marginRight:"2rem","&:hover":{backgroundColor:"#FAE5EC",cursor:"pointer"},"@media(max-width:767px)":{fontSize:"1.25rem",width:"100%",marginRight:"0"}},logBtn:{padding:"0.688rem 1.5rem",marginRight:"1.5rem",fontSize:"1.25rem",backgroundColor:"#D22D64",color:"#FFFFFF",border:"1px solid #D22D64",borderRadius:"1.5rem","&:hover":{cursor:"pointer"},"@media(max-width:767px)":{fontSize:"1.25rem",width:"100%",marginRight:"0rem",marginBottom:"1rem"}},disablelogBtn:{padding:"0.688rem 1.5rem",marginRight:"1.5rem",fontSize:"1.25rem",backgroundColor:"#DBDBDB",color:"#606060",cursor:"not-allowed",border:"1px solid #DBDBDB",borderRadius:"1.5rem","@media(max-width:767px)":{fontSize:"1.25rem",width:"100%",marginRight:"0rem",marginBottom:"1rem"}},buttonDes:{textAlign:"left",marginBottom:"2.5rem","@media(max-width:767px)":{marginBottom:"0"}},titlesDiv:{marginBottom:"2.188rem"},subtitleDiv:{marginBottom:"1.375rem"},acceptedTextContainer:{marginBottom:"3rem"},displayCenter:{textAlign:"left",padding:"0rem 3rem",marginTop:"2rem","@media(max-width:767px)":{padding:"1.5rem 1rem"}},infoText:{fontSize:"1.375rem",fontFamily:"AssistantRegular",color:"#404040","@media(max-width:767px)":{fontSize:"1.25rem",marginTop:"0",lineHeight:"1.75rem",marginBottom:"1rem"}},dropText:{fontSize:"1.375rem",fontFamily:"AssistantRegular",color:"#404040"},commentsClass:{fontSize:"1.375rem",fontFamily:"AssistantSemiBold",color:"#404040",margin:0,"@media(max-width:767px)":{fontSize:"1.25rem",display:"block"}},textAreaDes:{height:"5rem",padding:"0.5rem",width:"96%",fontSize:"1.25rem",border:"1px solid #CFCFCF",borderRadius:"0.25rem","&::placeholder":{fontSize:"1.25rem",color:"#949494"},"@media(max-width:767px)":{width:"94%",height:"15rem"}},textLimit:{color:"#949494",fontSize:"1.25rem",margin:0,fontFamily:"AssistantRegular","@media(max-width:767px)":{fontSize:"1.125rem"}},commentContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:"0.5rem","@media(max-width:767px)":{marginTop:"0.5rem",display:"block"}},uploadLink:{color:"#2273C3",fontFamily:"AssistantSemiBold"},uploadText:{marginBottom:"3rem",marginTop:"1rem"},uploadSection:{marginBottom:"1rem",marginTop:"1rem","@media(max-width:767px)":{marginTop:"1rem",marginBottom:"2rem"}},maxCharacter:{color:"#6E6E6E",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px"},error:{color:"#EB0000",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px"}
1,errorValidation:{color:"red",fontFamily:"AssistantRegular",fontSize:"1.25rem"}}),I=(0,m.A)({typeOfAssessmentContainer:{display:"flex",alignItems:"center"},latesteOutcomeDiv:{padding:"1rem",marginBottom:"1.5rem",border:"1px solid #CFCFCF"},emptyDiv:{display:"flex",justifyContent:"center"},emptyText:{fontSize:"1.375rem",color:"#767676",fontFamily:"AssistantSemiBold"},caseOutcomeContainer:{"@media(max-width:767px)":{paddingTop:"1rem"}},recentHeader:{backgroundColor:"#EBEBEB",padding:"1rem 1.5rem",display:"flex",alignItems:"center",justifyContent:"space-between","@media(max-width:767px)":{display:"block",padding:"1.25rem 1rem 0.75rem"}},headerTitle:{color:"#767676",fontSize:"1.5rem",fontFamily:"AssistantSemiBold",lineHeight:"2rem","@media(max-width:767px)":{display:"block",fontSize:"1.375rem",lineHeight:"1.813rem",marginBottom:"0.25rem"}},recentDesc:{padding:"1.5rem 1.5rem 0","@media(max-width:767px)":{padding:"1.25rem 1rem 0.5rem"}},descText:{color:"#404040",fontFamily:"AssistantRegular",fontSize:"1.375rem",lineHeight:"1.813rem","@media(max-width:767px)":{fontSize:"1.25rem",lineHeight:"1.75rem"}},dateText:{color:"#767676",fontFamily:"AssistantRegular",fontSize:"1.375rem",lineHeight:"1.75rem"},innerDateText:{color:"#404040",fontFamily:"AssistantRegular",fontSize:"1.25rem"},descContainer:{marginBottom:"1rem"},marginBottomNone:{"@media(max-width:767px)":{marginBottom:"0 !important"}},accordion:{boxShadow:"none","&:before":{backgroundColor:"#fff"}},summaryaccordion:{backgroundColor:"#DFEFFF",padding:"0.5rem 1.5rem"},accordionTitle:{color:"#FFFFFF",fontSize:"2rem",fontFamily:"AssistantSemiBold",marginBlock:0},accordionDetails:{border:"1px solid #CFCFCF",padding:"1.5rem"},detailsContainer:{},divider:{backgroundColor:"#EAEAEA",margin:"1.5rem 0","@media(max-width:767px)":{margin:"1rem 0"}},text2:{marginTop:"1rem"},termsContainer:{display:"flex",alignItems:"center",padding:"0 1.5rem",marginBottom:"2rem","@media(max-width:767px)":{alignItems:"flex-start",padding:"0 1rem"}},documentCheckbox:{color:"#271C6F",paddingLeft:"0","&.Mui-checked":{color:"#271C6F"},"@media(max-width:767px)":{paddingLeft:"0"}},acceptButton:{cursor:"pointer","@media(max-width:767px)":{marginBottom:"1.5rem",width:"100% !important",padding:"0.75rem 1.5rem !important"}},rejectButton:{cursor:"pointer","@media(max-width:767px)":{width:"100% !important",padding:"0.75rem 1.5rem !important"}},documentLink:{color:"#2273C3",fontFamily:"AssistantSemiBold",cursor:"pointer"},requiredText:{fontSize:"1.375rem",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.25rem",marginTop:"0.375rem"}},requiredIcon:{color:"#D22D64"},acceptRejectButton:{padding:"0 1.5rem",marginBottom:"2rem","& Button":{padding:"0.438rem 1.5rem",fontFamily:"AssistantSemiBold",fontSize:"1.25rem",marginRight:"1.5rem"}},expandBtn:{cursor:"pointer"},collapsedSummary:{display:"none"},summaryBody:{padding:"2rem 1.5rem",backgroundColor:"#fff",border:"1px solid #CFCFCF","@media (max-width: 1370px)":{display:"block"},"@media(max-width:767px)":{padding:"1rem"}},summaryContainer:{display:"flex",justifyContent:"space-between",alignItems:"center",padding:"1.125rem 1.5rem",cursor:"pointer",backgroundColor:"#418FDE","&:focus-visible":{outline:"2px solid black"},"@media(max-width:767px)":{padding:"1.5rem"}},dateVal:{fontFamily:"AssistantSemiBold",color:"#404040",lineHeight:"1.813rem"},viewStyle:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",color:"#404040",lineHeight:"2rem","@media(max-width:767px)":{display:"block",fontSize:"1.375rem",lineHeight:"1.813rem",marginBottom:"0.75rem"}},descCountainer:{marginBottom:"1rem"},dueDatePass:{display:"flex",alignItems:"flex-end",marginBottom:"1rem","@media (max-width:767px)":{alignItems:"flex-start"}},dueDateText:{fontSize:"1.375rem",fontFamily:"AssistantRegular",lineHeight:"1.813rem",marginLeft:"0.5rem","@media(max-width: 767px)":{fontSize:"1.25rem"}},investigatorContainer:{display:"flex",alignItems:"center","@media (max-width:767px)":{alignItems:"flex-start"}},investigatorText:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",marginLeft:"0.7rem",color:"#2273C3","@media(max-width:767px)":{fontSize:"1.25rem"}},dueDatePassContainer:{marginBottom:"1rem",padding:"1.5rem 1.5rem 0"},TextBold:{fontFamily:"AssistantSemiBold",color:"#000000"},acceptedContainer:{padding:"1.5rem 1.5rem 0"},marginTopNone:{marginTop:"0"},calenderIcon:{marginRight:"5px","@media (max-width:767px)":{marginTop:"0.4rem"}},investigatorIcon:{"@media(max-width:767px)":{marginTop:"0.4rem"}},blodFont:{fontFamily:"AssistantSemiBold",color:"#000000"},historyDetails:{display:"flex",flexDirection:"row",flexGrow:"1",gap:"7.6rem","@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{display:"block"},"@media(max-width:767px)":{display:"block"}},historyContainer:{display:"flex",marginBottom:"1.625rem","@media(max-width:767px)":{display:"block"}},verticalDivider:{marginRight:"1rem",borderRight:"1px solid #EAEAEA","@media(max-width:767px)":{marginRight:0,borderRight:"none",borderBottom:"1px solid #EAEAEA",marginBottom:"1rem",paddingBottom:"1rem"}},drupalLabel:{fontFamily:"AssistantRegular",fontSize:"1.25rem",color:"#4B4B4B",marginRight:"0.25rem"},apiValue:{fontFamily:"AssistantSemiBold",fontSize:"1.5rem",color:"#000000",margin:0},settlementContainer:{margin:0},historyAccepteReject:{paddingBottom:"1.625rem",fontFamily:"AssistantSemiBold",fontSize:"1.5rem",color:"#000000",lineHeight:"1.75rem"},labelStyle:{fontFamily:"AssistantRegular",fontSize:"1.25rem",color:"#4B4B4B"},caseOutcomeVal:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",color:"#404040",margin:"0"},labelValueStyle:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",color:"#404040",margin:0},acceptRejectContainer:{marginTop:"1.5rem","@media(max-width:767px)":{display:"flex",justifyContent:"center"}},acceptBtn:{marginRight:"1rem",borderRadius:"1.5rem",padding:"0.5rem 1.5rem",fontSize:"1.25rem",fontFamily:"AssistantSemiBold",border:"2px s
1olid #D22D64",backgroundColor:"#FFFFFF",color:"#D22D64",cursor:"pointer","&:disabled":{border:"1px solid #C6C6C6",color:"#767676",cursor:"not-allowed"}},container:{height:"282px",overflow:"scroll"},containerTD:{width:"200rem",overflow:"auto",maxHeight:"20rem","@media(max-width:1024px)":{overflow:"unset"}},mainChatBoxTbl:{marginLeft:"1.5rem",marginBottom:"1.5rem"},mainconversationdiv:{maxHeight:"36.5rem",overflowY:"hidden",overflowX:"hidden"},mainchatall:{height:"15rem",overflowY:"auto",overflowX:"hidden"},ckeditorwindow:{marginBottom:"1.5rem","@media(max-width:1024px)":{position:"absolute"}},countdiv:{fontSize:"1rem",fontFamily:"AssistantRegular",paddingTop:"0.625rem",display:"flex",justifyContent:"flex-end"},limitcross:{color:"red"},sendIcon:{width:"1.813rem",height:"1.813rem"},sendIcontbltb:{"@media(max-width:1024px)":{verticalAlign:"bottom",paddingBottom:"0.688rem"}},sendBtn:{width:"3.75rem",height:"3.75rem",opacity:1,margin:"0 1rem",borderRadius:"50%",padding:"1rem 1rem",fontSize:"1.25rem",fontFamily:"AssistantSemiBold",border:"2px solid #D22D64",backgroundColor:"#D22D64",color:"#FFFFFF",cursor:"pointer",marginTop:"4.063rem","&:hover":{backgroundColor:"#D22D64!important"},"&:focus-visible":{border:"2px solid black"},"@media(max-width:1024px)":{}},sendDisableBtn:{width:"3.75rem",height:"3.75rem",opacity:.5,margin:"0 1rem",borderRadius:"50%",padding:"1rem 1rem",fontSize:"1.25rem",fontFamily:"AssistantSemiBold",border:"2px solid #D22D64",backgroundColor:"#D22D64",color:"#FFFFFF",cursor:"pointer",marginTop:"4.063rem","&:hover":{backgroundColor:"#D22D64!important"},"&:focus-visible":{border:"2px solid black"},"@media(max-width:1024px)":{}},disabledBtn:{width:"2rem",height:"2rem",opacity:1,marginRight:"1rem",borderRadius:"50%",padding:"0.5rem 1.5rem",fontSize:"1.25rem",fontFamily:"AssistantSemiBold",border:"2px solid #D22D64",backgroundColor:"#D22D64",color:"#FFFFFF",cursor:"pointer","&:hover":{backgroundColor:"#D22D64!important"}},rejectBtn:{borderRadius:"1.5rem",padding:"0.5rem 1.5rem",fontSize:"1.25rem",fontFamily:"AssistantSemiBold",border:"2px solid #D22D64",backgroundColor:"#FFFFFF",color:"#D22D64",cursor:"pointer","&:disabled":{border:"1px solid #C6C6C6",color:"#767676",cursor:"not-allowed"}},historyContainerDiv:{padding:"0 2rem 2rem","@media(max-width:767px)":{padding:"0"}},latestOutcomeHeader:{display:"flex",justifyContent:"space-between",borderBottom:"none",alignItems:"center",padding:"0 0 1.5rem 0","@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{display:"block"},"@media(max-width:767px)":{display:"block",padding:"0"}},latestOutcomeItemData:{margin:0,"@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{margin:"0 1.5rem 1.5rem"},"@media(max-width:767px)":{margin:"0 1.5rem 1.5rem"}},latestOutcomeItem:{margin:0,"@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{margin:"0 1.5rem 1.5rem 0"},"@media(max-width:767px)":{margin:"0 1.5rem 1.5rem 0"}},latestOutcomeText:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",color:"#767676",lineHeight:"2rem","@media(max-width:767px)":{display:"block",marginBottom:"0.75rem"}},latestOutcomeDate:{fontSize:"1.375rem",fontFamily:"AssistantSemiBold",color:"#767676",lineHeight:"1.75rem"},latestOutcomeBody:{padding:"1.5rem 1.5rem 1.5rem 1rem",backgroundColor:"#F7F7F7",color:"#000000",fontFamily:"AssistantSemiBold"},marginBtm:{marginBottom:"1.125rem"},latestOutcomeContainer:{marginBottom:"1.5rem",padding:"2rem 2rem 0","@media(max-width:767px)":{padding:"0"}},errorMessageContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"#FBDEDD",border:"1px solid #CB3A32",padding:"0.5rem 1rem",borderRadius:"0.5rem",marginBottom:"1rem"},successMessageContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"#E2FBEA",border:"1px solid #4B9F53",padding:"0.5rem 1rem",borderRadius:"0.5rem"},messageText:{display:"flex",alignItems:"center",fontSize:"1.5rem",fontFamily:"AssistantRegular"},messageIcon:{marginRight:"0.75rem"},warningClose:{display:"flex"},closeBtn:{padding:"0",cursor:"pointer",backgroundColor:"transparent",border:"none"},warningMessageContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"#DFEAFC",border:"1px solid #3661E2",padding:"0.5rem 1rem",borderRadius:"0.5rem"},warningText:{display:"flex",alignItems:"center",fontSize:"1.5rem",fontFamily:"AssistantRegular"},warningIcon:{marginRight:"0.75rem",marginTop:"3.8px",width:"21px","@media(max-width:767px)":{padding:"0",display:"inline-block",marginRight:"0.375rem"}},loadingIcon:{width:"3.188rem",display:"block",alignItems:"center",margin:"0 auto"},loadmoreChatBtn:{alignItems:"center",textAlign:"center",width:"100%",margin:"1rem 0"},loadmoreBtn:{all:"unset",fontFamily:"AssistantSemiBold",marginTop:"1rem",fontSize:"1.25rem",color:"#D22D63",cursor:"pointer",textDecoration:"underline",paddingBottom:"1rem"},warningChatMsg:{"@media(max-width:786px)":{position:"relative"}}
1,messageClose:{display:"flex"},fontFamilyBold:{fontFamily:"AssistantSemiBold"},latestOutcomeValue:{fontFamily:"AssistantSemiBold",color:"#404040"},outcomeValue:{"@media(max-width:767px)":{display:"block"}},latestOutcomeBodyText:{color:"#404040",fontFamily:"AssistantRegular",fontSize:"1.5rem"},dueDateContainer:{display:"flex",alignItems:"flex-end"},dueDateInfo:{marginLeft:"1.87rem",fontSize:"1.375rem",fontFamily:"AssistantSemiBold",color:"#000000"},linkDocumentText:{fontFamily:"AssistantSemiBold",color:"#2273C3"}});var N=i(9336);const T=i.p+"static/media/Icon_Expand.7d31a6fa06c037c033a5d2a50262cdcc.svg";const E=i.p+"static/media/Icon_Down.aab122674e45003150d1947a4007a0b2.svg";var z=i(4535),M=i(35),L=i(7392),O=i(1626);const P=[{title:"Provide us a reason",accepted_subtitle:"Thanks for indicating that you have accepted our assessment on your cases.",accepted_subtitle1:"If you would like to add further comments to support your choice, you can add your comments here.",accepted_comment_title:"Comments :",rejected_comment_title:"Comments:",max_char_title:"Max. characters:",max_char_limit:"500",placeholder_text:"Add your comments to specify why you would like to update your case.",rejected_subtitle:"Thanks for indicating that you do not accept our assessment on your cases.",rejected_subtitle1:"Please help us understand the reason why do not accept our assessment.",rejected_upload_description:"You can also provide an evidence to support your decision by uploading the relevant documents later using upload documents link in case details.",rejected_upload_description1:"You can also upload any additional evidence to support your rejection decision through file upload journey.",rejected_comment_validation:"Please enter the comments",submit_btn:"Submit",cancel_btn:"Cancel"}];var W=i(5137),H=i(3139);const V=["children","onClose"],Y={comment:""},U=e=>{const t=e.children,i=e.onClose,a=(0,n.A)(e,V);return(0,p.jsxs)("div",{className:"Info-title",children:[(0,p.jsx)(s.A,(0,o.A)((0,o.A)({sx:{m:0,p:2,borderBottom:"1px solid #75757533"}},a),{},{children:t})),i?(0,p.jsx)(L.A,{disableRipple:!0,"aria-label":"close",onClick:i,sx:{position:"absolute",right:8,top:12,"&:focus":{border:"2px solid black",borderRadius:"4px"},"&:hover":{backgroundColor:"#ffffff"}},children:(0,p.jsx)("img",{src:O.A,alt:"close-icon"})}):null]})},q=(0,z.Ay)(M.A)(e=>{let t=e.theme;return{"& .MuiDialogContent-root":{padding:t.spacing(2)},"& .MuiDialogActions-root":{padding:t.spacing(1)}}}),G=e=>{var t,i,n,s,r,m,u,g,f,v,b,y,w;let S=e.open,A=e.handleClose,C=e.showSuccessMessage,j=(e.showWarningMessage,e.incidentId),k=e.outcomeDate,D=e.offerOutcomeId,F=e.setErrorMessage,R=e.handleSuccessOrReject,B=e.isMessageNotRequire;const I=_(),N=(0,l.useState)(Y),T=(0,a.A)(N,2),E=T[0],z=T[1],M=(0,l.useState)(P),L=(0,a.A)(M,2),O=L[0],V=L[1],G=new h.A,K=(0,l.useState)(!1),Q=(0,a.A)(K,2),X=Q[0],Z=Q[1],J=(0,l.useState)(""),$=(0,a.A)(J,2),ee=$[0],te=$[1],ie=new c.A,ae=(0,l.useState)(!1),oe=(0,a.A)(ae,2),ne=oe[0],se=oe[1],le=(0,l.useRef)(!1),re=(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),de=()=>{A(),z(Y),te(""),Z(!1),se(!1),le.current=!1};return(0,l.useEffect)(()=>{G.httpConnection(x.Y.SERVICES.getAcceptReject,"get").then(e=>{"<"!==e[0]?V(e):V(P)}).catch(e=>{V(P)})},[]),(0,p.jsx)("div",{children:(0,p.jsxs)(q,{onClose:de,"aria-labelledby":"rejected-dialog-title",id:"rejectedDialog",open:S,classes:{paper:I.paper},children:[(0,p.jsx)(U,{"aria-label":null===(t=O[0])||void 0===t?void 0:t.title,id:"rejected-dialog-title",onClose:de,children:(0,p.jsx)("div",{className:I.dialogHeader,children:(0,p.jsx)("h3",{className:I.dialogTitle,children:null===(i=O[0])||void 0===i?void 0:i.title})})}),(0,p.jsxs)("div",{className:I.displayCenter,children:[(0,p.jsx)("div",{className:I.titlesDiv,children:(0,p.jsx)("div",{children:(0,p.jsx)("span",{className:I.infoText,children:null===(n=O[0])||void 0===n?void 0:n.rejected_subtitle1})})}),(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{className:I.commentContainer,children:[(0,p.jsxs)("div",{children:[(0,p.jsx)("span",{className:I.commentsClass,children:null===(s=O[0])||void 0===s?void 0:s.rejected_comment_title}),"false"===B.toLocaleLowerCase()&&(0,p.jsx)("span",{className:I.astrikColor,children:"*"})]}),(0,p.jsxs)("span",{"aria-live":"polite",className:ee.length>=(null===(r=O[0])||void 0===r?void 0:r.max_char_limit)?I.error:I.maxCharacter,children:[null===(m=O[0])||void 0===m?void 0:m.max_char_title,": ",(null===(u=O[0])||void 0===u?void 0:u.max_char_limit)-ee.length]})]}),(0,p.jsx)("textarea",{rows:5,className:I.textAreaDes,onChange:e=>{var t,i,a;let n="";const s=e.target.name;var l,r,d;(null===e||void 0===e||null===(t=e.target)||void 0===t||null===(i=t.value)||void 0===i?void 0:i.length)<=+(null===(a=O[0])||void 0===a?void 0:a.max_char_limit)?n=e.target.value:n=null===e||void 0===e||null===(l=e.target)||void 0===l||null===(r=l.value)||void 0===r?void 0:r.substring(0,+(null===(d=O[0])||void 0===d?void 0:d.max_char_limit));z(e=>(0,o.A)((0,o.A)({},e),{},{[s]:n})),te(n)},"data-hj-suppress":"true",name:"comment",placeholder:null===(g=O[0])||void 0===g?void 0:g.placeholder_text,value:E.comment}),X&&(0,p.jsx)("span",{className:I.errorValidation,children:null===(f=O[0])||void 0===f?void 0:f.rejected_comment_validation})]}),(0,p.jsx)("div",{className:I.uploadSection,children:(0,p.jsx)("span",{className:I.infoText,children:null===(v=O[0])||void 0===v?void 0:v.rejected_upload_description})}),(0,p.jsx)("div",{className:I.uploadText,children:(0,p.jsx)("span",{className:I.infoText,children:null===(b=O[0])||void 0===b?void 0:b.rejected_upload_description1})}),(0,p.jsxs)("div",{className:I.buttonDes,children:[(0,p.jsx)("button",{tabIndex:0,disabled:!(!ne||""!==E.comment),id:"rejectedDialogSubmitBtn",className:"true"===B.toLocaleLowerCase()?I.logBtn:ne||""===E.comment?I.disablelogBtn:I.logBtn,onClick:()=>
1{if(le.current)return;const e=E.comment.trim();if(!("true"===B.toLocaleLowerCase())&&!e)return z(Y),void Z(!0);Z(!1),se(!0),le.current=!0;const t={incidentid:j,flag:"Rejected",field_dp_x_comment:E.comment,outcomeDate:k,fos_offeroroutcomeid:D};ie.httpConnection("".concat(d.y.SERVICES.acceptReject),"post",t).then(e=>{if(se(!1),le.current=!1,"200"!==e.status)throw new Error(e);C(),R(),de()}).catch(e=>{se(!1),le.current=!1;const t=(0,H.H)(e,re);F(t),de()})},children:null===(y=O[0])||void 0===y?void 0:y.submit_btn}),(0,p.jsx)("button",{tabIndex:0,className:I.discardBtn,id:"rejectedDialogCancelBtn",onClick:de,children:null===(w=O[0])||void 0===w?void 0:w.cancel_btn})]})]})]})})},K=[{history_title:"View complete case progress history",caseoutcome_title:"Your case outcome is",date_sent_to_you:"Date sent to you",case_outcome:"Case outcome",type_of_assessment:"Type of assessment",accepted_title:"Your response:",history_date:"Date sent to you",additional_details:"Additional Details",history_outcome_title:"Investigator has completed the assessment and shared the review with you ",accepte_btn:"Accept",reject_btn:"Reject",no_records:"No progress history available.",no_outcome_yet:"No outcome yet",not_available:"Not available",already_response:"You have already responded to this outcome",successfully_response:"You have successfully responded to this outcome"}],Q=((0,o.A)({title:"Provide us a reason"},{accepted_subtitle:"Thanks for indicating that you have accepted our assessment on your cases.",accepted_subtitle1:"If you would like to add further comments to support your choice, you can add your comments here.",comment_title:"Comments (optional):",max_char_title:"Max. characters:",max_char_limit:"500",placeholder_text:"Add your comments to specify why you would like to update your case.",rejected_subtitle:"Thanks for indicating that you do not accept our assessment on your cases.",rejected_subtitle1:"Please help us understand the reason why you do not accept our assessment.",rejected_upload_description:"You can also provide evidence to support your decision by uploading the relevant documents later.",rejected_upload_text:"Click here to Upload files",submit_btn:"Submit",cancel_btn:"Cancel"}),["children","onClose"]),X={comment:""},Z=e=>{const t=e.children,i=e.onClose,a=(0,n.A)(e,Q);return(0,p.jsxs)("div",{className:"Info-title",children:[(0,p.jsx)(s.A,(0,o.A)((0,o.A)({sx:{m:0,p:2,borderBottom:"1px solid #75757533"}},a),{},{children:t})),i?(0,p.jsx)(L.A,{sx:{position:"absolute",right:8,top:12,"&:focus":{border:"2px solid black",borderRadius:"4px"},"&:hover":{backgroundColor:"#ffffff"}},disableRipple:!0,"aria-label":"close",onClick:i,children:(0,p.jsx)("img",{src:O.A,alt:"close-icon"})}):null]})},J=(0,z.Ay)(M.A)(e=>{let t=e.theme;return{"& .MuiDialogContent-root":{padding:t.spacing(2)},"& .MuiDialogActions-root":{padding:t.spacing(1)}}}),$=e=>{var t,i,n,s,r,m,u,g,f,v,b;let y=e.incidentId,w=e.outcomeDate,S=e.offerOutcomeId,A=e.open,C=e.handleCloseAcceptedDialog,j=e.showSuccessMessage,k=(e.showWarningMessage,e.setErrorMessage),D=e.handleSuccessOrReject;const F=_(),R=(0,l.useState)(X),B=(0,a.A)(R,2),I=B[0],N=B[1],T=(0,l.useState)(P),E=(0,a.A)(T,2),z=E[0],M=E[1],L=new h.A,O=(0,l.useState)(""),V=(0,a.A)(O,2),Y=V[0],U=V[1],q=new c.A,G=(0,l.useState)(!1),K=(0,a.A)(G,2),Q=K[0],$=K[1],ee=(0,l.useRef)(!1),te=(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),ie=()=>{C(),N(X),U(""),$(!1),ee.current=!1};return(0,l.useEffect)(()=>{L.httpConnection(x.Y.SERVICES.getAcceptReject,"get").then(e=>{"<"!==e[0]?M(e):M(P)}).catch(e=>{M(P)})},[]),(0,p.jsx)("div",{children:(0,p.jsxs)(J,{onClose:C,"aria-describedby":"accepted-dialog-title",id:"acceptedDialogPopup",open:A,classes:{paper:F.paper},"aria-labelledby":"accepted-dialog-title",children:[(0,p.jsx)(Z,{"aria-label":null===(t=z[0])||void 0===t?void 0:t.title,id:"accepted-dialog-title",onClose:C,children:(0,p.jsx)("div",{className:F.dialogHeader,children:(0,p.jsx)("h3",{className:F.dialogTitle,children:null===(i=z[0])||void 0===i?void 0:i.title})})}),(0,p.jsxs)("div",{className:F.displayCenter,children:[(0,p.jsxs)("div",{className:F.titlesDiv,children:[(0,p.jsx)("div",{className:F.subtitleDiv,children:(0,p.jsxs)("span",{className:F.infoText,children:[" ",null===(n=z[0])||void 0===n?void 0:n.accepted_subtitle]})}),(0,p.jsx)("div",{children:(0,p.jsx)("span",{className:F.infoText,children:null===(s=z[0])||void 0===s?void 0:s.accepted_subtitle1})})]}),(0,p.jsxs)("div",{className:F.acceptedTextContainer,children:[(0,p.jsxs)("div",{className:F.commentContainer,children:[(0,p.jsx)("span",{className:F.commentsClass,children:null===(r=z[0])||void 0===r?void 0:r.accepted_comment_title}),(0,p.jsxs)("span",{"aria-live":"polite",className:Y.length>=(null===(m=z[0])||void 0===m?void 0:m.max_char_limit)?F.error:F.maxCharacter,children:[null===(u=z[0])||void 0===u?void 0:u.max_char_title," ",(null===(g=z[0])||void 0===g?void 0:g.max_char_limit)-Y.length]})]}),(0,p.jsx)("textarea",{rows:5,className:F.textAreaDes,onChange:e=>{var t,i,a;let n="";const s=e.target.name;var l,r,d;(null===e||void 0===e||null===(t=e.target)||void 0===t||null===(i=t.value)||void 0===i?void 0:i.length)<=+(null===(a=z[0])||void 0===a?void 0:a.max_char_limit)?n=e.target.value:n=null===e||void 0===e||null===(l=e.target)||void 0===l||null===(r=l.value)||void 0===r?void 0:r.substring(0,+(null===(d=z[0])||void 0===d?void 0:d.max_char_limit));N(e=>(0,o.A)((0,o.A)({},e),{},{[s]:n})),U(n)},"data-hj-suppress":"true",name:"comment",placeholder:null===(f=z[0])||void 0===f?void 0:f.placeholder_text,value:I.comment})]}),(0,p.jsxs)("div",{className:F.buttonDes,children:[(0,p.jsx)("button",{tabIndex:0,disabled:Q,id:"accptedDialogSubmitBtn",className:Q?F.disablelogBtn:F.logBtn,onClick:()=>
1{if(ee.current)return;$(!0),ee.current=!0;const e={incidentid:y,flag:"Accepted",field_dp_x_comment:I.comment,outcomeDate:w,fos_offeroroutcomeid:S};q.httpConnection("".concat(d.y.SERVICES.acceptReject),"post",e).then(e=>{if($(!1),ee.current=!1,"200"!==e.status)throw new Error(e);j(),D(),ie()}).catch(e=>{$(!1),ee.current=!1;const t=(0,H.H)(e,te);k(t),ie()})},children:null===(v=z[0])||void 0===v?void 0:v.submit_btn}),(0,p.jsx)("button",{tabIndex:0,className:F.discardBtn,id:"accptedDialogCancelBtn",onClick:ie,children:null===(b=z[0])||void 0===b?void 0:b.cancel_btn})]})]})]})})};const ee=i.p+"static/media/Icon_Info_blue.a112cfcfb1ff6d27a2b0d52fd493db56.svg";var te=i(3490),ie=i(7153),ae=i(8965);const oe=e=>{var t,i,o,n,s,r,m,u,g,f,v;let b=e.incidentId;const y=I(),w=(0,l.useState)(!1),S=(0,a.A)(w,2),A=S[0],C=S[1],j=(0,l.useState)(!1),k=(0,a.A)(j,2),D=k[0],F=k[1],R=(0,l.useState)(!1),B=(0,a.A)(R,2),_=B[0],z=B[1],M=(0,l.useState)([]),L=(0,a.A)(M,2),P=L[0],H=L[1],V=(0,l.useState)({}),Y=(0,a.A)(V,2),U=Y[0],q=Y[1],Q=new c.A,X=new h.A,Z=(0,l.useState)(K),J=(0,a.A)(Z,2),oe=J[0],ne=J[1],se=(0,l.useState)([]),le=(0,a.A)(se,2),re=le[0],de=le[1],ce=(0,l.useState)(""),me=(0,a.A)(ce,2),pe=me[0],ue=me[1],ge=(0,l.useState)(""),he=(0,a.A)(ge,2),xe=he[0],fe=he[1],ve=(0,l.useState)(!1),be=(0,a.A)(ve,2),ye=be[0],we=be[1],Se=(0,l.useState)(!1),Ae=(0,a.A)(Se,2),Ce=Ae[0],je=Ae[1],ke=(0,l.useState)(""),De=(0,a.A)(ke,2),Fe=De[0],Re=De[1],Be=(0,l.useState)(!1),_e=(0,a.A)(Be,2),Ie=_e[0],Ne=_e[1],Te=(0,l.useState)(!1),Ee=(0,a.A)(Te,2),ze=Ee[0],Me=Ee[1],Le=(0,l.useState)("false"),Oe=(0,a.A)(Le,2),Pe=Oe[0],We=Oe[1],He=((0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),()=>{C(!A)}),Ve=()=>{F(!1),z(!1)},Ye=e=>null!==e.fos_meritopinion_txt?e.fos_meritopinion_txt:null!==e.fos_jurisdictioninout_txt?e.fos_jurisdictioninout_txt:null!==e.fos_dismissalreason?e.fos_dismissalreason:"";(0,l.useEffect)(()=>{if(""!=xe){const i=Ke(xe);var e,t;if(i.length>0)if(""!=(null===(e=i[0])||void 0===e?void 0:e.is_commentmessage_optional))We(null===(t=i[0])||void 0===t?void 0:t.is_commentmessage_optional)}},[xe,re]);const Ue=(e,t)=>{e&&t(e)},qe=()=>{const e={incidentid:b};Q.httpConnection("".concat(d.y.SERVICES.getCaseOutcome),"post",e).then(e=>{if("OK"!==e.status)throw new Error(e);(e=>{if(null!==e&&void 0!==e&&e.fosresponsetobereceivedby){const t=(0,ae.i$)(null===e||void 0===e?void 0:e.fosresponsetobereceivedby);ue(t)}if((null===e||void 0===e?void 0:e.caseoutcomes.length)>0){var t;const i=null===e||void 0===e?void 0:e.caseoutcomes.splice(0,1)[0];i&&null!==(t=Object.keys(i))&&void 0!==t&&t.length&&("1"==(null===i||void 0===i?void 0:i.acceptReject)?Ne(!0):Ne(!1)),q(i),H(e.caseoutcomes)}fe(null===e||void 0===e?void 0:e.messageCode)})(e)}).catch(e=>{q({}),H([]),fe("")})};(0,l.useEffect)(()=>{X.httpConnection(x.Y.SERVICES.getProgressHistory,"get").then(e=>{"<"!==e[0]?Ue(e,ne):Ue(K,ne)}).catch(e=>{ne(K)}),X.httpConnection(x.Y.SERVICES.getLatestOutcome,"get").then(e=>{"<"!==e[0]?Ue(e,de):Ue([],de)}).catch(e=>{de([])}),qe()},[]),(0,l.useEffect)(()=>{qe()},[ze]);const Ge=()=>{Me(!0)},Ke=e=>e===e?e?re&&(null===re||void 0===re?void 0:re.filter(t=>t.message_code===e)):re&&(null===re||void 0===re?void 0:re.filter(e=>"no_outcome"===e.message_code)):re[0],Qe=()=>{z(!0)},Xe=()=>{Ne(!0),je(!0)},Ze=()=>{we(!0)},Je=()=>{F(!0)};return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("div",{className:y.caseOutcomeContainer,children:[(0,p.jsxs)("div",{className:y.latestOutcomeContainer,children:[Ce&&(0,p.jsxs)("div",{className:y.successMessageContainer,children:[(0,p.jsxs)("div",{role:"alert",className:y.messageText,children:[(0,p.jsx)("img",{className:y.messageIcon,alt:"success-icon",src:te.A}),(0,p.jsx)("span",{children:null===(t=oe[0])||void 0===t?void 0:t.successfully_response})]}),(0,p.jsx)("div",{className:y.messageClose,children:(0,p.jsx)("button",{className:y.closeBtn,onClick:()=>je(!1),children:(0,p.jsx)("img",{alt:"close-icon",src:O.A})})})]}),""!==Fe&&(0,p.jsxs)("div",{className:y.errorMessageContainer,children:[(0,p.jsxs)("div",{role:"alert",className:y.messageText,children:[(0,p.jsx)("img",{className:y.messageIcon,alt:"error-icon",src:ie.A}),(0,p.jsx)("span",{children:Fe})]}),(0,p.jsx)("div",{className:y.messageClose,children:(0,p.jsx)("button",{className:y.closeBtn,onClick:()=>Re(""),children:(0,p.jsx)("img",{alt:"close-icon",src:O.A})})})]}),ye&&(0,p.jsxs)("div",{className:y.warningMessageContainer,children:[(0,p.jsxs)("div",{role:"alert",className:y.warningText,children:[(0,p.jsx)("img",{alt:"warning-icon",className:y.warningIcon,src:ee}),(0,p.jsx)("span",{children:null===(i=oe[0])||void 0===i?void 0:i.already_response})]}),(0,p.jsx)("div",{className:y.warningClose,children:(0,p.jsx)("button",{className:y.closeBtn,onClick:()=>we(!1),children:(0,p.jsx)("img",{alt:"close-icon",src:O.A})})})]}),(0,p.jsxs)("div",{className:y.latestOutcomeHeader,children:[(0,p.jsxs)("dl",{className:y.latestOutcomeItemData,children:[(0,p.jsx)("dt",{className:y.labelStyle,children:null===(o=oe[0])||void 0===o?void 0:o.caseoutcome_title}),(0,p.jsx)("dd",{"data-testid":"fos_type_text","data-hj-suppress":"true",className:y.caseOutcomeVal,children:null!==U&&void 0!==U&&U.fos_type_txt?null===U||void 0===U?void 0:U.fos_type_txt:null===(n=oe[0])||void 0===n?void 0:n.no_outcome_yet})]}),(0,p.jsxs)("dl",{className:y.latestOutcomeItemData,children:[(0,p.jsx)("dt",{className:y.labelStyle,children:null===(s=oe[0])||void 0===s?void 0:s.date_sent_to_you}),(0,p.jsx)("dd",{"data-hj-suppress":"true",className:y.labelValueStyle,children:null!==U&&void 0!==U&&U.outcomedate?(0,ae.i$)(null===U||void 0===U?void 0:U.outcomedate):null===(r=oe[0])||void 0===r?void 0:r.not_available})]}),(0,p.jsxs)("dl",{className:y.latestOutcomeItemData,children:[(0,p.jsx)("dt",{className:y.labelStyle,children:null===(m=oe[0])||void 0===m?void 0:m.type_of_assessment}),(0,p.jsx)("dd",{className:y.apiValue,"data-hj-suppress":"true",children:null!==U&&void 0!==U&&U.outcomedate?Ye(U):null===(u=oe[0])||void 0===u?void 0:u.not_available})]}),(0,p.jsx)("div",{})]}),(0,p.jsx)("div",{className:y.latestOutcomeBody,children:(()=>{var e,t,i,a,o,n;const s=Ke(xe);return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)("div",{className:"".concat(y.marginBtm," ").concat(y.latestOutcomeBodyText),children:(0,p.jsx)("span",{"data-hj-suppress":"true","data-testid":"message1",children:null===(e=s[0])||void 0===e?void 0:e.message1.replace("_duedate_",pe).replace("&quot;",'"').replace("&quot;",'"').replace("&#039;","'")})}),(null===(t=s[0])||void 0===t?void 0:t.message2)&&(0,p.jsx)("div",{className:"".concat(y.latestOutcomeBodyText),children:(0,p.jsx)("span",{"data-hj-suppress":"true","data-testid":"message2",children:null===(i=s[0])||void 0===i?void 0:i.message2.replace("_duedate_",pe).replace("&quot;",'"').replace("&quot;",'"').replace("&#039;","'")})}),"True"===(null===(a=s[0])||void 0===a?void 0:a.show_accept_reject)&&(0,p.jsxs)("div",{className:y.acceptRejectContainer,children:[(0,p.jsx)("button",{"data-hj-suppress":"true",disabled:!!Ie,id:"acceptedOutcomebtn",onClick:Qe,className:y.acceptBtn,children:null===(o=oe[0])||void 0===o?void 0:o.accepte_btn}),(0,p.jsx)("button",{"data-hj-suppress":"true",disabled:!!Ie,id:"rejectedOutcomebtn",onClick:Je,className:y.rejectBtn,children:null===(n=oe[0])||void 0===n?void 0:n.reject_btn})]})]})})()})]}),(0,p.jsxs)("div",{className:y.historyContainerDiv,children:[(0,p.jsxs)("div",{role:"button",id:A?"collapsHistoryButtonId":"expandHistoryButtonId","data-testid":"expandCollaps",tabIndex:0,"aria-expanded":A,className:y.summaryContainer,onKeyDown:e=>{"Enter"!==e.code&&"Space"!==e.code||(e.preventDefault(),He())},onClick:He,children:[(0,p.jsx)("div",{children:(0,p.jsx)("h2",{className:y.accordionTitle,children:null===(g=oe[0])||void 0===g?void 0:g.history_title})}),A?(0,p.jsx)("img",{src:T,className:y.expandBtn,id:A?"collapseProgressHistory":"",alt:""}):(0,p.jsx)("img",{src:E,className:y.expandBtn,id:A?"":"expandProgressHistory",alt:""})]}),(0,p.jsxs)("div",{className:A?y.summaryBody:y.collapsedSummary,"data-testid":"countdiv",children:[P&&0===P.length&&(0,p.jsx)("div",{className:y.emptyDiv,children:(0,p.jsx)("span",{className:y.emptyText,children:null===(f=oe[0])||void 0===f?void 0:f.no_records})}),null===P||void 0===P||null===(v=P.map)||void 0===v?void 0:v.call(P,(e,t)=>{var i,a,o,n;return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("div",{className:y.detailsContainer,children:[(0,p.jsx)("div",{className:y.historyAccepteReject,children:(0,p.jsxs)("span",{children:[null===(i=oe[0])||void 0===i?void 0:i.history_outcome_title," ",(0,p.jsx)("span",{className:y.apiValue,"data-hj-suppress":"true",children:"no response"===e.fos_complainantresponse_txt.toLowerCase()?"not responded.":e.fos_complainantresponse_txt.toLowerCase()+"."})]})}),(0,p.jsx)("div",{className:y.historyContainer,children:(0,p.jsxs)("div",{className:y.historyDetails,children:[(0,p.jsxs)("dl",{className:y.latestOutcomeItem,children:[(0,p.jsx)("dt",{className:y.drupalLabel,children:null===(a=oe[0])||void 0===a?void 0:a.case_outcome}),(0,p.jsx)("dd",{"data-hj-suppress":"true",className:y.apiValue,children:e.fos_type_txt})]}),(0,p.jsxs)("dl",{className:y.latestOutcomeItem,children:[(0,p.jsx)("dt",{className:y.drupalLabel,children:oe[0].history_date}),(0,p.jsx)("dd",{className:y.apiValue,"data-hj-suppress":"true",children:null!==e&&void 0!==e&&e.outcomedate?(0,ae.i$)(null===e||void 0===e?void 0:e.outcomedate):""})]}),(0,p.jsxs)("dl",{className:y.latestOutcomeItem,children:[(0,p.jsx)("dt",{className:y.drupalLabel,children:null===(o=oe[0])||void 0===o?void 0:o.type_of_assessment}),(0,p.jsx)("dd",{className:y.apiValue,"data-hj-suppress":"true",children:Ye(e)})]})]})})]},e.fos_complainantresponse_txt+"_"+t),(null===e||void 0===e?void 0:e.user_comments)&&(0,p.jsxs)("dl",{className:y.settlementContainer,children:[(0,p.jsx)("dt",{className:y.drupalLabel,children:null===(n=oe[0])||void 0===n?void 0:n.additional_details}),(0,p.jsx)("dd",{className:y.apiValue,"data-hj-suppress":"true",children:e.user_comments?e.user_comments:"-"})]}),P.length-1!==t&&(0,p.jsx)(N.A,{className:y.divider})]})})]})]})]}),D&&(0,p.jsx)(G,{open:D,handleClose:Ve,showSuccessMessage:Xe,showWarningMessage:Ze,outcomeDate:null===U||void 0===U?void 0:U.outcomedate,offerOutcomeId:null===U||void 0===U?void 0:U.fos_offeroroutcomeid,incidentId:b,setErrorMessage:Re,handleSuccessOrRe
1ject:Ge,isMessageNotRequire:Pe}),_&&(0,p.jsx)($,{incidentId:b,outcomeDate:null===U||void 0===U?void 0:U.outcomedate,offerOutcomeId:null===U||void 0===U?void 0:U.fos_offeroroutcomeid,open:_,handleCloseAcceptedDialog:Ve,showSuccessMessage:Xe,showWarningMessage:Ze,setErrorMessage:Re,handleSuccessOrReject:Ge})]})};var ne=i(1906);const se=(0,m.A)({tabs:{color:"black",display:"flex",gap:"0.5rem"},boxDisplayStyle:{},prevButton:{display:"none","@media(max-width:1024px)":{display:"flex",minWidth:"2.5rem","&:focus-visible":{background:"#D22D6430",borderRadius:"8px"}}},nextButton:{display:"none","@media(max-width:1024px)":{display:"flex",justifyContent:"center",minWidth:"2rem","&:focus-visible":{background:"#D22D6430",borderRadius:"8px"}}},tabContainer:{"& >.MuiTabs-scroller":{"& >.MuiTabs-flexContainer":{"& >.MuiTab-root":{"& >.MuiTabs-indicator":{width:"32px"},fontFamily:"AssistantSemiBold",padding:"0rem",marginLeft:"32px",marginRight:"32px",fontSize:"1.5rem",color:"#232323",textTransform:"inherit","@media(max-width:767px)":{fontSize:"1.25rem",padding:"0.5rem 0.5rem"},"@media(max-width:540px)":{display:"flex",padding:"0.5rem 1rem"},"@media (min-device-width: 541px)  and (max-device-width: \t767px)":{display:"flex",padding:"0.5rem 1rem"},"@media (min-device-width: 768px)  and (max-device-width: \t1024px)":{display:"flex",padding:"0.5rem 1rem"}},"& >.Mui-selected":{"& span":{color:"#404040",fontFamily:"AssistantBold"}}}}},btmBtn:{padding:"0.6rem",marginRight:"0.6rem",cursor:"pointer",border:"1px solid #D22D64",borderRadius:"20px",float:"right",color:"#D22D64",fontSize:"16px",backgroundColor:"#ffffff","&:hover":{backgroundColor:"#FAE5EC"}},btmDiv:{display:"flex",justifyContent:"end",alignItems:"center",marginTop:"1rem"},tabBox:{width:"90%"},boxContainer:{display:"flex",width:"90%",justifyContent:"space-between"},TabPanelStyle:{maxHeight:"40rem",overflowY:"auto",backgroundColor:"white","@media(max-width:1024px)":{padding:"1rem 0",position:"relative",maxHeight:"50rem",height:"45rem"}},nextPrevColor:{color:"#D22D64"}});var le=i(5691);const re=i.p+"static/media/download_word.da161cbe5a6975cbefbdd35fbf5b64cd.svg";const de=i.p+"static/media/Icon_Image.259ae3a4f9d6c0c35a8395732fef19a2.svg";const ce=i.p+"static/media/Icon_AudioDown.c13669ea7ce4e221ac0eaf2543f04171.svg";const me=i.p+"static/media/Icon_DocumentDown.c443f0cc5d9bfdcf2079b54fc499e011.svg";const pe=i.p+"static/media/Icon_VideoDown.6a599f14d511597f23ff7f22ec1f4b10.svg";var ue=i(1962);const ge=(0,m.A)({displayRow:{display:"flex",alignItems:"flex-start",flexGrow:"1",width:"100%",overflow:"hidden","@media (max-width:460px)":{display:"block",width:"80%"},"@media (max-width:665px)":{width:"80%"}},row1:{textAlign:"center",marginRight:"1.5rem",maxWidth:"120px",display:"flex",flexDirection:"column",justifyContent:"flex-start","@media (max-width:460px)":{textAlign:"left"},"& >button":{background:"transparent",border:"none",color:"#D22D65",fontFamily:"AssistantSemiBold",fontSize:"20px",display:"block",cursor:"pointer","&:disabled":{color:"gray !important",cursor:"not-allowed"}},"& >p":{margin:"0",font:"normal normal normal 1.125rem/1.5rem AssistantRegular",display:"flex",flexWrap:"wrap",justifyContent:"center"}},row2:{margin:"0 ",wordWrap:"break-word",overflow:"hidden",flexGrow:"1","& >p":{margin:"0.3rem"},"& >h3":{margin:"0.3rem",overflowWrap:"break-word",maxWidth:"100%"}},displayRowOne:{display:"flex",justifyContent:"space-between",alignItems:"center","@media(max-width:767px)":{display:"block"}},fileIcon:{paddingTop:"1rem","@media(max-width:767px)":{paddingTop:"1.25rem"}},documentTitle:{font:"normal normal 600 1.5rem/2.1875rem AssistantRegular",marginTop:"0.8rem",marginBottom:"0.5rem",color:"#418FDE","@media(max-width:767px)":{fontSize:"1.25rem",paddingRight:"1rem",paddingTop:"1rem"}},docDescription:{font:"normal normal normal 1.1875rem/1.75rem AssistantRegular",marginTop:"-0.5rem",color:"#404040",marginBottom:"0rem","@media(max-width:767px)":{fontSize:"1.125rem",paddingRight:"1rem"}},contentBox:{width:"65%"},menuOptions:{width:"35%",display:"flex",height:"20%",marginTop:"1rem",marginRight:"0.5rem",justifyContent:"end"},viewIcon:{marginRight:"1.5rem",cursor:"pointer","&:focus":{backgroundColor:"#271C6F10",borderRadius:"50%",outline:"none"}},downloadIcon:{marginRight:"1.5rem",cursor:"pointer","&:focus":{backgroundColor:"#271C6F10",borderRadius:"50%",outline:"none"}},lineDesign:{color:"gray",width:"97%",marginTop:"0rem"}
1,chkBox:{width:"3.375rem",height:"3.375rem",alignItems:"center","& .Mui-checked":{color:"black"}},displayCenter:{display:"flex",alignItems:"center",paddingLeft:"4rem",marginBottom:"1rem"},date:{font:"normal normal normal 1.1875rem/1.75rem AssistantRegular",color:"#404040"},dateOne:{fontSize:"1.25rem",fontFamily:"AssistantBold",lineHeight:"1.75rem",color:"#404040",paddingRight:"1.25rem"},type:{color:"#404040"},size:{color:"#404040",marginRight:"0.5rem"},reason:{fontSize:"1.25rem",display:"none",fontFamily:"AssistantRegular",color:"#404040",lineHeight:"1.75rem","@media(max-width:767px)":{fontSize:"1.25rem",fontFamily:"AssistantRegular",color:"#404040",lineHeight:"1.75rem",display:"block",marginTop:"0"}},purposeDesk:{display:"block",fontSize:"1.25rem",fontFamily:"AssistantRegular",color:"#404040",lineHeight:"1.75rem","@media(max-width:767px)":{display:"none"}},readMore:{font:"1.25rem AssistantSemiBold",color:"#D22D65 !important",cursor:"pointer","@media(max-width:767px)":{display:"none"}},readMoreMob:{display:"none",font:"1.25rem AssistantSemiBold",color:"#2273C3 !important",cursor:"pointer","@media(max-width:767px)":{display:"block"}},purpose:{fontSize:"1.25rem",fontFamily:"AssistantBold",color:"#404040"},slash:{paddingRight:"1.25rem","@media(max-width:767px)":{display:"none"}},displayNew:{display:"none","@media(max-width:767px)":{display:"block"}},purposeMob:{font:"normal normal bold 1.1875rem/1.75rem AssistantRegular",color:"#404040","& > span":{fontWeight:"normal",color:"#404040"}},documentType:{color:"#404040",font:"normal normal bold 1.1875rem/1.75rem AssistantRegular",marginTop:"1rem","& > span":{fontWeight:"normal"}},downloadedDocument:{color:"#000000"}}),he=0,xe=1,fe=2,ve=3,be=e=>{var t,i,o,n,s,r,d,c,m;let u=e.fileName,g=e.subDate,h=e.sharedBy,x=e.type,f=e.purpose,v=e.size,b=e.documentType,y=e.onCheckboxChange,w=e.drupalData,S=e.config,A=e.documentId,C=e.handleDownloadFiles,j=e.getDownloadStep,k=e.mainDrupalData,D=e.uniqueFlag,F=e.setSelectedFiles,R=e.selectedFiles;const B=(0,l.useState)(!1),_=(0,a.A)(B,2),I=_[0],N=_[1],T=ge(),E=e=>(null===e||void 0===e?void 0:e.charAt(0).toUpperCase())+(null===e||void 0===e?void 0:e.slice(1)),z=e=>e.replace(/\s+/g,"");return(0,p.jsx)("div",{className:T.displayRowOne,children:(0,p.jsxs)("div",{style:{display:"flex",alignItems:"flex-start",width:"100%"},children:[(0,p.jsx)(ue.A,{disableRipple:!0,id:"caseDocuments_Individual_checkBoxClick",onChange:y,value:A,checked:null===R||void 0===R?void 0:R.some(e=>(null===e||void 0===e?void 0:e.documentId)===A),inputProps:{"aria-label":z(u)},sx:{color:"#271C6F",paddingTop:"1rem","&.Mui-checked":{color:"#271C6F"},"&:focus-within":{border:"1px black solid"}}}),(0,p.jsxs)("div",{className:T.displayRow,children:[(0,p.jsxs)("div",{className:T.row1,children:[(e=>"Pdf"===e?(0,p.jsx)("img",{src:le.A,alt:"",className:T.fileIcon}):"Word"===e?(0,p.jsx)("img",{src:re,alt:"",className:T.fileIcon}):"Image"===e?(0,p.jsx)("img",{src:de,alt:"",className:T.fileIcon}):"Audio"===e?(0,p.jsx)("img",{src:ce,alt:"",className:T.fileIcon}):"Doc"===e?(0,p.jsx)("img",{src:me,alt:"",className:T.fileIcon}):"Video"===e?(0,p.jsx)("img",{src:pe,alt:"",className:T.fileIcon}):(0,p.jsx)("img",{src:re,alt:"",className:T.fileIcon}))("pdf"===x?"Pdf":"img"===x||"png"===x||"svg"===x||"jpeg"===x||"jpg"===x||"gif"===x?"Image":"mp3"===x||"wma"===x?"Audio":"docx"===x?"Word":"mp4"===x||"avi"===x?"Video":"zip"===x?"Zip":"Doc"),(0,p.jsxs)("p",{children:[(0,p.jsxs)("span",{className:T.size,children:[Math.round(parseInt(v)/1024)," KB"]}),(0,p.jsx)("span",{className:T.type,children:E(x)}),(0,p.jsx)("br",{})]}),(0,p.jsxs)("button",{disabled:(M=j(u,A),M!=he),id:"caseDocuments_Individual_download","aria-label":z(u)+" Requestdownload",tabIndex:0,onClick:()=>{F([]),C([{documentId:A,documentName:u,documentSize:v}])},children:[" ",null===(t=w[0])||void 0===t?void 0:t.download]})]}),(0,p.jsxs)("div",{className:T.row2,children:[(0,p.jsx)("h3",{"data-hj-suppress":!0,className:"no"==(null===D||void 0===D?void 0:D.toLowerCase())?T.documentTitle:T.downloadedDocument,children:u}),(0,p.jsxs)("p",{"data-hj-suppress":!0,className:T.docDescription,children:[" ",null===(i=w[0])||void 0===i?void 0:i.sharedBy,"  ",(0,p.jsx)("span",{className:T.date,style:{fontWeight:"bold"},children:(e=>{var t;const i=null===S||void 0===S||null===(t=S.originatorCodes)||void 0===t?void 0:t.find(t=>t.code===e);return null===i||void 0===i?void 0:i.name})(h)})," on  ",(0,p.jsx)("span",{className:T.date,style:{color:"#000000"},children:g?(0,ae.i$)(g):""})]}),(0,p.jsxs)("p",{"data-hj-suppress":!0,className:T.documentType,children:[null===(o=w[0])||void 0===o?void 0:o.documentTypeLabel,"  ",(0,p.jsx)("span",{children:(e=>{var t,i;const a=null===S||void 0===S||null===(t=S.documentCodes)||void 0===t?void 0:t.find(t=>t.code===e);return E(null===a||void 0===a?void 0:a.name)||(null===(i=w[0])||void 0===i?void 0:i.nullLabel)})(b)})]}),(0,p.jsxs)("div",{style:{display:"flex",alignItems:"flex-start",justifyContent:"space-between"},children:[""!==f?(0,p.jsxs)("p",{"data-hj-suppress":!0,className:T.purposeMob,children:[null===(n=w[0])||void 0===n?void 0:n.purpose,": ",(0,p.jsx)("span",{children:I?f:null===f||void 0===f?void 0:f.substring(0,+(null===(s=w[0])||void 0===s?void 0:s.readMoreLimit)||80
1)}),(null===f||void 0===f?void 0:f.length)>(+(null===(r=w[0])||void 0===r?void 0:r.readMoreLimit)||80)&&(0,p.jsxs)("span",{id:"caseDocuments_readmore","aria-expanded":I,role:"button",tabIndex:0,className:T.readMoreMob,onKeyDown:e=>{"Enter"!==e.code&&"Space"!==e.code||(e.preventDefault(),N(!I))},onClick:()=>N(!I),children:["...",I?"Read less":"Read more"]})]}):(0,p.jsxs)("p",{"data-hj-suppress":!0,className:T.purposeMob,children:[null===(d=w[0])||void 0===d?void 0:d.purpose," ",(0,p.jsx)("span",{children:null===(c=w[0])||void 0===c?void 0:c.nullLabel})]}),(null===f||void 0===f?void 0:f.length)>(+(null===(m=w[0])||void 0===m?void 0:m.readMoreLimit)||80)&&(0,p.jsx)("span",{style:{marginRight:"24px",marginLeft:"15px",marginTop:"19px",flexShrink:"0"},id:"caseDocuments_readmore","aria-expanded":I,role:"button",tabIndex:0,className:T.readMore,onKeyDown:e=>{"Enter"!==e.code&&"Space"!==e.code||(e.preventDefault(),N(!I))},onClick:()=>N(!I),children:I?"Read less":"Read more"})]}),0!=j(u,A)&&(0,p.jsx)("p",{style:{wordWrap:"break-word",color:"#FF0000"},children:(e=>{var t,i,a,o;switch(e){case he:return null===(t=k[0])||void 0===t?void 0:t.download;case xe:return null===(i=k[0])||void 0===i?void 0:i.downloadWait;case fe:return null===(a=k[0])||void 0===a?void 0:a.downloadProgress;case ve:return null===(o=k[0])||void 0===o?void 0:o.downloadErrorMsg;default:return""}})(j(u,A))})]})]})]})});var M};var ye=i(1020),we=i(5865),Se=i(1292);const Ae=i.p+"static/media/FIlter_Icon.6577d6a5bdf810e166dd625ea1d1f11e.svg",Ce=(0,m.A)({container:{backgroundColor:"white",margin:"0.5rem",maxWidth:"300px"},btnContainer:{display:"flex",alignItems:"center",justifyContent:"center"},filterTypeBody:{display:"flex",flexDirection:"row",marginBottom:"0.625rem"},filterTitle:{display:"flex"},filterTitleName:{padding:"0.625rem"},primaryBoxes:{color:"#404040",fontSize:"1.25rem",fontFamily:"AssistantRegular",paddingBottom:1,paddingTop:1,paddingRight:10,marginLeft:5},filterTypeHeaders:{fontSize:"1.25rem",fontFamily:"AssistantRegular",color:"#767676",paddingLeft:"0.625rem"},InfoContainer:{display:"flex",justifyContent:"space-between"},filterClassOnClick:{marginLeft:"1.5rem",backgroundColor:"#FFFFFF",border:"2px solid #271C6F",margin:"-1px",fontSize:"1.375rem",fontFamily:"AssistantSemiBold",color:"#271C6F",borderRadius:"0.5rem",height:"3rem","@media(max-width:767px)":{marginTop:"1rem",marginLeft:"0"}},filterClass:{marginLeft:"1.5rem",backgroundColor:"#FFFFFF",border:"1px solid #271C6F",fontSize:"1.375rem",fontFamily:"AssistantSemiBold",color:"#271C6F",borderRadius:"0.5rem",cursor:"pointer",height:"3rem","@media(max-width:767px)":{marginTop:"1rem",marginLeft:"0"}},filterIcon:{paddingLeft:"0.5rem"},filterText:{paddingLeft:"0.5rem",paddingRight:"0.5rem"},filterButtonsClear:{fontSize:"1.375rem",paddingBottom:1,paddingTop:1,paddingRight:10,marginLeft:5,color:"#D22D64",fontWeight:"600",fontFamily:"AssistantSemiBold",border:"none",background:"transparent",cursor:"pointer"},filterButtonApply:{textAlign:"center",fontSize:"1.25rem",paddingBottom:"0.625rem",paddingTop:"0.625rem",paddingRight:"1.25rem",paddingLeft:"1.25rem",marginLeft:"1rem",border:"2px solid #FFFFFF",borderRadius:"1.5rem",fontFamily:"AssistantSemiBold",background:"#D22D64",cursor:"pointer",color:"#FFFFFF","&:hover":{border:"2px solid #FFFFFF",boxShadow:"none"},"&:disabled":{border:"1px solid #767676",color:"#767676",background:"#FFFFFF",cursor:"default"}}}),je=e=>{let t=e.show,i=e.handleClickFilter,a=e.handleCloseFilter,n=e.apply,l=e.reset,r=e.checkedStatus,d=e.setCheckedStatus,c=e.setShow,m=e.drupalData;const u=Ce(),g=Boolean(t),h=g?"simple-popover":void 0,x=e=>{const t=null===e||void 0===e?void 0:e.replace(/\s+/g,"");return null===t||void 0===t?void 0:t.toLowerCase()},f=e=>{for(let t of e)if(t.flag)return!1;return!0};return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)("button",{id:"filterBtnCaseFiles","aria-label":"filter","aria-expanded":g,className:!f(r)||g?u.filterClassOnClick:u.filterClass,onClick:i,children:(0,p.jsxs)("span",{className:u.btnContainer,children:[(0,p.jsx)("img",{alt:"",className:u.filterIcon,src:Ae}),(0,p.jsx)("span",{className:u.filterText,children:null===m||void 0===m?void 0:m.filterLabel})]})}),(0,p.jsx)(ye.Ay,{sx:{".MuiPopover-paper":{border:"1px solid #271C6F",boxShadow:"none",borderRadius:"0.5rem",marginTop:"0.25rem"}},open:g,id:h,anchorEl:t,onClose:a,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:(0,p.jsxs)("div",{className:u.container,children:[(0,p.jsx)("div",{className:u.filterTypeBody,children:(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{className:u.InfoContainer,children:[(0,p.jsx)(we.A,{id:"modal-modal-title",variant:"subtitle1",component:"h6",className:u.filterTypeHeaders,children:null===m||void 0===m?void 0:m.title}),(0,p.jsx)(L.A,{disableRipple:!0,"aria-label":"close",onClick:()=>c(null),sx:{position:"absolute",right:4,top:4,color:e=>e.palette.grey[500],"&:focus-visible":{boxShadow:"0 0 0 2px black",borderRadius:"4px"}},children:(0,p.jsx)("img",{src:O.A,alt:"closeIcon"})})]}),r.map(e=>(0,p.jsxs)(s.A,{sx:{display:"flex",flexDirection:"row"},children:[(0,p.jsx)(ue.A,{disableRipple:!0,inputProps:{"aria-labelledby":x(e.title)},sx:{marginTop:"10px",marginBottom:"10px",color:"#D22D64","&.Mui-checked":{color:"#D22D64"}
1,"&:focus-within":{outline:"2px solid black",borderRadius:"4px"}},checked:e.flag,value:e.flag,onChange:t=>{const i=t.target.checked;d(t=>t.map(t=>t.title===e.title?(0,o.A)((0,o.A)({},t),{},{flag:i}):t))},style:{height:20,width:20,marginLeft:10,marginTop:"1rem"}}),(0,p.jsx)(Se.A,{id:x(e.title),className:u.primaryBoxes,children:(0,p.jsx)("div",{className:u.filterTitle,children:(0,p.jsx)("label",{className:u.filterTitleName,children:e.title})})})]},e.title))]})}),(0,p.jsxs)("div",{style:{display:"flex",float:"right",marginBottom:"1.5rem",marginRight:"0.5rem"},children:[(0,p.jsx)("button",{disabled:f(r),onClick:()=>{n(r)},className:u.filterButtonApply,children:m.applyBtn}),(0,p.jsx)("button",{className:u.filterButtonsClear,onClick:()=>{l()},children:null===m||void 0===m?void 0:m.clearAll})]})]})})]})};var ke=i(794),De=i(4194),Fe=i(4337);const Re=i(3538).useStateCallback,Be={title:"Name of originator",filterOption_1:"You or your representative",filterOption_2:"Business being complained about",filterOption_3:"Financial Ombudsman Service",clearAll:"Clear All",applyBtn:"Apply",other:"Other",filterLabel:"Filter(s)"},_e=new h.A,Ie=(0,m.A)({topHeader:{marginLeft:"1rem",justifyContent:"center"},displayRow:{display:"flex"},titleSortDoc:{fontSize:"1.25rem",marginLeft:"1.5rem",width:"43rem"},referFAQ:{fontSize:"1.25rem",marginRight:"1.5rem",width:"39rem",textAlign:"end"},rmvUnderline:{textDecoration:"none"},caseDocuments:{fontSize:"1.5rem",width:"auto",fontFamily:"AssistantRegular",color:"#404040",lineHeight:"1.875rem","@media(max-width:767px)":{margin:"0",padding:"1.5rem 0 1rem 0",fontSize:"1.375rem"}},caseAllDocuments:{font:"normal normal 600 1.25rem/1.8125rem AssistantRegular",paddingTop:"1.3rem",alignItems:"center",border:"none",background:"none",color:"#D22D65",cursor:"pointer","@media(max-width:767px)":{padding:"0 0 0.5rem 0",marginBottom:"1rem",fontSize:"1.25rem",display:"block"},"&:hover":{textDecoration:"underline"},"&:focus-visible":{textDecoration:"underline"},"&:disabled":{color:"GrayText"},"&:disabled:hover":{textDecoration:"none",color:"GrayText"}},downloadSelectedDoc:{marginTop:"1.5rem",padding:"0.688rem 1.5rem",fontSize:"1.25rem",backgroundColor:"#D22D64",color:"#FFFFFF",border:"1px solid #D22D64",borderRadius:"1.5rem",marginRight:"1rem",float:"right","&:hover":{backgroundColor:"#B8134A",cursor:"pointer"},"@media(max-width:767px)":{width:"96%",marginTop:"1rem",marginBottom:"1rem",float:"none"}},disableBtn:{marginTop:"1.5rem",padding:"0.688rem 1.5rem",fontSize:"1.25rem",backgroundColor:"#E07D9E",color:"#FFFFFF",border:"1px solid #E07D9E",borderRadius:"1.5rem",marginRight:"1rem",cursor:"not-allowed",float:"right","@media(max-width:767px)":{width:"96%",marginTop:"1rem",marginBottom:"1rem",float:"none"}},headerTop:{display:"flex",width:"100%",justifyContent:"space-between","@media(max-width:767px)":{display:"block"}},filteredBy:{font:"1.125rem AssistantSemiBold",marginBlock:0,marginLeft:"0.5rem","@media(max-width:767px)":{marginTop:"0.75rem"}},filterDisplay:{display:"flex",alignItems:"center",marginTop:"0.75rem","@media(max-width:767px)":{display:"block"}},displayDownload:{display:"flex",color:"#D22D65",gap:"10px","@media(max-width:767px)":{marginTop:"1.75rem",justifyContent:"space-around"}},downAll:{width:"1.25rem",height:"1.25rem",marginTop:"1.5rem","@media(max-width:767px)":{marginTop:"0.25rem"}},noRecord:{fontFamily:"AssistantSemiBold",size:"1.25rem",padding:"1rem","@media (max-width:786px)":{display:"block"}},snackBar:{position:"absolute",top:0,left:0,width:"100%","& >div":{width:"100%",display:"flex",alignItems:"center"}},loading:{color:"#D22D64",animation:"$colorChange 1s infinite alternate"},"@keyframes colorChange":{from:{color:"#271C6F"},to:{color:"#D22D64"}},sronly:{position:"absolute",left:"-9999px"}}),Ne={"You or your representative":["You, your representative, or others.","Professional Representative (Complainant)","Representative (Complainant)"]},Te=[{flag:!1,title:"You or your representative",key:0},{flag:!1,title:"Business being complained about",key:1},{flag:!1,title:"Financial Ombudsman Service",key:2},{flag:!1,title:"Other",key:3}],Ee=2,ze=1,Me=0,Le=e=>{var t,i,n,s,r,d;e.incidentId,e.pnx;let m=e.handleDownloadFiles,u=e.drupalData,g=e.apiData,h=e.toaster,f=e.setToaster,v=e.config,b=e.setShowBell,y=(e.loading,e.dots);const w=Ie(),S=(0,l.useState)(null),A=(0,a.A)(S,2),C=A[0],j=A[1],k=Re(Te),D=(0,a.A)(k,2),F=D[0],R=D[1],B=(0,l.useState)(Be),_=(0,a.A)(B,2),I=_[0],N=_[1],T=(0,l.useState)(""),E=(0,a.A)(T,2),z=E[0],M=E[1],L=(0,l.useState)([]),O=(0,a.A)(L,2),P=O[0],H=O[1],V=(0,l.useState)([]),Y=(0,a.A)(V,2),U=Y[0],q=Y[1],G=(0,l.useState)(ze),K=(0,a.A)(G,2),Q=K[0],X=K[1],Z=(0,W.d4)(e=>e.DownloadProgress.downloadStatus),J=((0,W.wA)(),(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),e=>{if(null!=e&&e.length>0){return X(0),[...e].sort((e,t)=>
1e.createdOn&&t.createdOn?new Date(t.createdOn).valueOf()-new Date(e.createdOn).valueOf():e)}});(0,l.useEffect)(()=>{(e=>{var t,i;"OK"===(null===e||void 0===e?void 0:e.status)&&0===(null===e||void 0===e||null===(t=e.data)||void 0===t||null===(i=t.files)||void 0===i?void 0:i.length)||null===(null===e||void 0===e?void 0:e.data)?X(Ee):P&&0!==(null===P||void 0===P?void 0:P.length)?X(Me):X(ze)})(g)},[P]),(0,l.useEffect)(()=>{b(!1)},[]),(0,l.useEffect)(()=>{var e;const t=J(null===g||void 0===g||null===(e=g.data)||void 0===e?void 0:e.files);H(t||[])},[g]);new c.A;const $=(e,t)=>{const i=Z.find(i=>(null===i||void 0===i?void 0:i.fileName)===e&&(null===i||void 0===i?void 0:i.documentId)===t);return(null===i||void 0===i?void 0:i.step)||0},ee=(e,t)=>{e.target.checked?((e,t)=>{q(i=>[...i,{documentId:e.target.value,documentName:t.fileName,documentSize:null===t||void 0===t?void 0:t.sizeOfFile}])})(e,t):(e=>{q(t=>t.filter(t=>t.documentId!==e.target.value))})(e)},te=e=>{const t=null===e||void 0===e?void 0:e.map(e=>(0,o.A)((0,o.A)({},e),{},{flag:!1}));R(t)};(0,l.useEffect)(()=>{_e.httpConnection(x.Y.SERVICES.getDownloadFilter,"get").then(e=>{if(e&&Array.isArray(e)){var t,i,a,o;N(e[0]);let n=[];n.push({flag:!1,title:null===(t=e[0])||void 0===t?void 0:t.filterOption_1,key:0}),n.push({flag:!1,title:null===(i=e[0])||void 0===i?void 0:i.filterOption_2,key:1}),n.push({flag:!1,title:null===(a=e[0])||void 0===a?void 0:a.filterOption_3,key:2}),n.push({flag:!1,title:null===(o=e[0])||void 0===o?void 0:o.other,key:3}),R(n)}else N(Be),R(Te)}).catch(()=>{N(Be),R(Te)})},[]);const ie=()=>{f({flag:!1,message:""})};return(0,p.jsxs)("div",{style:{position:"relative"},children:[(0,p.jsx)(ke.A,{className:w.snackBar,open:h.flag,autoHideDuration:1e4,onClose:ie,anchorOrigin:{vertical:"top",horizontal:"left"},children:(0,p.jsx)(De.A,{onClose:ie,severity:"error",icon:(0,p.jsx)("img",{src:Fe.A,style:{width:"20px",height:"20px"}}),sx:{fontSize:"1.25rem",backgroundColor:"#FBDEDD",color:"#CB3A32",border:"1px solid #CB3A32"},children:(0,p.jsx)("p",{style:{margin:0},children:h.message})})}),(0,p.jsxs)("div",{className:w.topHeader,children:[(0,p.jsxs)("div",{className:w.headerTop,children:[(0,p.jsx)("div",{className:w.filterDisplay,children:(0,p.jsxs)("div",{style:{display:"flex"},children:[(0,p.jsx)(je,{handleClickFilter:e=>{j(e.currentTarget)},handleCloseFilter:()=>{j(null),te(F)},show:C,setShow:j,checkedStatus:F,setCheckedStatus:R,apply:e=>{var t,i,a;let o=[],n=[],s=[],l="";for(let p of e)if(p.flag)if(l+=p.title+",\xa0",Object.keys(Ne).includes(null===p||void 0===p?void 0:p.title)){var r;const e=null===(r=Object.values(Ne)[0])||void 0===r?void 0:r.map(e=>null===e||void 0===e?void 0:e.toLowerCase());o=[...o,...e]}else{var d;o.push(null===p||void 0===p||null===(d=p.title)||void 0===d?void 0:d.toLowerCase())}if(o.includes("other")){var c;const e=["EFORG001","EFORG002","EFORG003","EFORG015","EFORG016"];null===v||void 0===v||null===(c=v.originatorCodes)||void 0===c||c.map(t=>{null!==e&&void 0!==e&&e.includes(null===t||void 0===t?void 0:t.code)||s.push(t.code)}),n=s}null===v||void 0===v||null===(t=v.originatorCodes)||void 0===t||t.forEach(e=>{var t;o.includes(null===(t=e.name)||void 0===t?void 0:t.toLowerCase())&&n.push(e.code)});const m=null===g||void 0===g||null===(i=g.data)||void 0===i||null===(a=i.files)||void 0===a?void 0:a.filter(e=>n.includes(e.originator));H(J(m)),M(l.substring(0,l.length-2)),j(null)},reset:()=>{var e;H(J(null===g||void 0===g||null===(e=g.data)||void 0===e?void 0:e.files)),M(""),te(F)},allowedState:Te,drupalData:I}),z.length>0&&(0,p.jsxs)("p",{className:w.filteredBy,children:[null===(t=u[0])||void 0===t?void 0:t.filter," ",z]})]})}),(0,p.jsxs)("div",{className:w.displayDownload,children:[(0,p.jsxs)("button",{id:"downloadSelctedCaseFiles",disabled:0==(null===P||void 0===P?void 0:P.length),className:w.caseAllDocuments,onClick:()=>{q([]),m(U)},children:[null===(i=u[0])||void 0===i?void 0:i.downloadSelected," "]}),(0,p.jsxs)("button",{id:"downloadAllCaseFiles",disabled:0==(null===P||void 0===P?void 0:P.length),className:w.caseAllDocuments,onClick:()=>{(()=>{var e,t;const i=[];null===g||void 0===g||null===(e=g.data)||void 0===e||null===(t=e.files)||void 0===t||t.forEach(e
1=>{i.push({documentId:e.documentId,documentName:e.fileName,documentSize:e.sizeOfFile})}),m(i),q([])})()},children:[null===(n=u[0])||void 0===n?void 0:n.downloadAll," "]})]})]}),(0,p.jsx)("hr",{}),(0,p.jsx)("span",{"aria-live":"polite",className:w.sronly,children:1==(null===y||void 0===y?void 0:y.length)?"".concat(null===(s=u[0])||void 0===s?void 0:s.wait).concat(y):""}),Q===ze&&(0,p.jsxs)("span",{className:"".concat(w.noRecord," ").concat(w.loading),children:[null===(r=u[0])||void 0===r?void 0:r.wait,y]}),Q===Ee&&(0,p.jsx)("span",{className:w.noRecord,children:null===(d=u[0])||void 0===d?void 0:d.noRecord}),(0,p.jsx)("span",{className:w.sronly,"aria-live":"polite",children:P&&(null===P||void 0===P?void 0:P.length)>0?"Case files loaded":""}),P&&P.map((e,t)=>(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(be,{fileName:e.fileName,subDate:e.createdOn,sharedBy:e.originator,type:e.fileType,size:e.sizeOfFile,onCheckboxChange:t=>ee(t,e),documentType:e.documentType,documentId:e.documentId,drupalData:u,config:v,purpose:e.fileComments,handleDownloadFiles:m,getDownloadStep:$,mainDrupalData:u,uniqueFlag:null===e||void 0===e?void 0:e.isDownloaded,setSelectedFiles:q,selectedFiles:U},e.documentId),(0,p.jsx)("hr",{style:{color:"#CFCFCF"}})]}))]})]})};var Oe=i(271),Pe=i(1517),We=i(6891),He=(i(3739),i(7977)),Ve=i(774),Ye=i(4348),Ue=i.n(Ye);const qe=i.p+"static/media/sendSolid.fd5652af845ee35c52f7a3a0977adc2c.svg";const Ge=i.p+"static/media/Icon_Chat_User.99219b812e5e428eabd6dd2f900dbbf7.svg";var Ke=i(8739);i(482);const Qe=(0,m.A)({dateWrapper:{display:"flex",alignItems:"center",justifyContent:"center",padding:"0 !important"},line:{flex:1,height:"1px",backgroundColor:"#ccc"},loadmoreBtn:{fontFamily:"AssistantSemiBold",marginTop:"1rem",fontSize:"1.375rem",backgroundColor:"#D22D64",border:"0.063rem solid #D22D64",borderRadius:"1.5rem",opacity:"1",color:"#FFFFFF",textTransform:"none",padding:"0.5rem 1.5rem",cursor:"pointer"},chatContainer:{margin:"0 auto",borderRadius:"0.5rem",overFlow:"hidden",fontFamily:"AssistantSemiBold"},chatcontainerall:{padding:"1.25rem","@media(max-width:1024px)":{padding:"0"}},dateDivider:{textAlign:"center",margin:"1rem 0",position:"relative"},dateSpan:{padding:"5px 12px",fontSize:"1.125rem",border:"1px solid #C6C6C6",color:"#404040",fontFamily:"AssistantRegular"},chatwindowheight:{height:"0 !important"},messageContainer:{display:"flex",flexDirection:"row",alignItems:"baseline",padding:"0 0.313rem",marginBottom:"10px"},messgaeLeft:{alignSelf:"flex-start",maxWidth:"50%",width:"max-content",marginRight:"auto","@media(max-width:786px)":{maxWidth:"90%"}},messageRight:{justifyContent:"flex-end",maxWidth:"50%",marginLeft:"auto",width:"max-content","@media(max-width:786px)":{maxWidth:"70%"}},messageInfo:{display:"flex",alignItems:"center",marginBottom:"4px"},investigatorIcon:{width:"2.5rem",height:"2.5rem",borderRadius:"50%",marginRight:"8px",backgroundColor:"#C6C6C6",color:"white",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"1.25rem"}
1,investigatorIconImg:{width:"1rem",height:"1.563rem"},senderIconImg:{width:"1rem",height:"1.563rem"},senderIcon:{width:"2.5rem",height:"2.5rem",borderRadius:"50%",marginLeft:"8px",backgroundColor:"#428FDE",color:"white",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"1.25rem"},senderIconRight:{width:"2.5rem",height:"2.5rem",marginLeft:"8px"},senderDiv:{display:"flex",alignItems:"baseline",marginLeft:"3.5rem",marginBottom:"0.5rem",justifyContent:"space-between",width:"max-content",maxWidth:"50%",marginRight:"auto"},receDiv:{display:"flex",justifyContent:"end"},messageSender:{marginRight:"1rem",color:"#767676",fontSize:"1.125rem",fontFamily:"AssistantRegular"},messgaeBubble:{padding:"8px 12px",borderRadius:"7.5px",marginBottom:"2px",position:"relative",wordWrap:"break-word",width:"90%"},leftBubble:{borderTopLeftRadius:0,backgroundColor:"#d3d4d4"},rightBubble:{backgroundColor:"#e4eef8",borderTopRightRadius:0},messageTime:{textAlign:"right",marginTop:"4px",fontSize:"1rem",color:"#767676",fontFamily:"AssistantRegular"},messageTimeRight:{textAlign:"left",marginTop:"4px",fontSize:"1rem",marginRight:"0.75rem",color:"#767676",fontFamily:"AssistantRegular"},msgcontent:{color:"#404040",fontSize:"1.125rem",fontFamily:"AssistantRegular","& p":{display:"block"}},resendBtn:{fontFamily:"AssistantRegular",marginTop:"1rem",fontSize:"1rem",backgroundColor:"#D22D64",border:"0.063rem solid #D22D64",borderRadius:"1.5rem",opacity:"1",color:"#FFFFFF",textTransform:"none",padding:"0.25rem 1rem",cursor:"pointer"},readmoreless:{all:"unset",fontFamily:"AssistantRegular",color:"#D22D64",fontSize:"1.125rem",textDecoration:"underline",cursor:"pointer",marginBottom:"1rem"}});(0,z.Ay)(Ke.A)(e=>{let t=e.theme;return{"@keyframes ripple":{"0%":{transform:"scale(.8)",opacity:1},"100%":{transform:"scale(2.4)",opacity:0}
1},"& .MuiBadge-badge":{backgroundColor:"#44b700",color:"#44b700",boxShadow:"0 0 0 2px ".concat(t.palette.background.paper),"&::after":{position:"absolute",borderRadius:"50%",animation:"ripple 1.2s infinite ease-in-out",border:"1px solid currentColor",content:'""',top:0,left:0,width:"100%",height:"100%"}}}});const Xe=function(e){let t=e.incidentId,i=(e.pnx,e.isreloading),n=e.onUpdate,s=e.sendDataToParent,r=e.onMethodReady,m=e.chatLoadMoreClick,u=e.loadingDatafromchild,g=e.resetLoadingRow;const h=Qe(),x=(0,l.useState)(!1),f=(0,a.A)(x,2),v=(f[0],f[1]),b=(0,l.useState)([]),y=(0,a.A)(b,2),w=y[0],S=y[1],A=(0,l.useState)(!1),C=(0,a.A)(A,2),j=C[0],k=C[1],D=(0,l.useState)(0),F=(0,a.A)(D,2),R=F[0],B=F[1],_=(0,l.useState)(0),I=(0,a.A)(_,2),N=I[0],T=I[1],E=(0,l.useState)(!1),z=(0,a.A)(E,2),M=z[0],L=z[1],O=(0,l.useState)(null),P=(0,a.A)(O,2),W=P[0],H=P[1],V=e=>{const t=(new DOMParser).parseFromString(e,"text/html");return!0===Boolean(t.querySelector("img")||t.querySelector("iframe")||t.querySelector("a"))?"":e},Y=e=>{const t=new We.o,i=new DOMParser;let a;try{return a=i.parseFromString(t.decode(e),"text/html").documentElement.textContent,V(a)||V(t.decode(e))}catch(o){return a="",a}},U=new c.A;(0,l.useEffect)(()=>{S([]),B(0),G(),g(0)},[n,i,t]),(0,l.useEffect)(()=>{s(M)},[M]),(0,l.useEffect)(()=>{},[w]),(0,l.useEffect)(()=>{setTimeout(()=>{0==R?(S([]),g(0)):g(1),G(),v(!1)},30)},[R]),(0,l.useEffect)(()=>{r&&r(q)},[r]),(0,l.useEffect)(()=>{u(j)},[j]);const q=()=>{v(!0),k(!0),B(m*N)},G=()=>{const e={caseid:t,rowFrom:R};U.httpConnection(d.y.SERVICES.getChatMessages,"post",e).then(e=>{if(e&&"Success"==(null===e||void 0===e?void 0:e.status)){const t=function(e){const t={};return e.digitalMessages.forEach(e=>{const i=(0,ae.i$)(e.createdOnStamp);t[i]||(t[i]=[]),t[i].push(e)}),(0,o.A)((0,o.A)({},e),{},{digitalMessages:Object.entries(t).map(e=>{let t=(0,a.A)(e,2);return{date:t[0],message:t[1]}})})}(e);S(null===t||void 0===t?void 0:t.digitalMessages);const n=null===t||void 0===t?void 0:t.messageBlockSize;if(T(n),L(null===t||void 0===t?void 0:t.hasMoreMessage),!1===(null===t||void 0===t?void 0:t.hasMoreMessage)&&0===R&&!1===j&&!0===i)S(null===t||void 0===t?void 0:t.digitalMessages),L(null===t||void 0===t?void 0:t.hasMoreMessage);else if(!0===M&&0!=R){null===t||void 0===t||t.messageBlockSize;k(!1),L(null===t||void 0===t?void 0:t.hasMoreMessage);const e=null===t||void 0===t?void 0:t.digitalMessages;S([...e,...w])}}else S([])}).catch(e=>{S([])})},K=e=>{const t=atob(e);return(new DOMParser).parseFromString(t,"text/html").body.innerHTML};return(0,p.jsx)(p.Fragment,{children:(0,p.jsx)("div",{className:w&&w.length?"":h.chatwindowheight,id:"chatwindowheight",children:(0,p.jsx)("div",{className:h.chatContainer,id:"chatContainer",children:null===w||void 0===w?void 0:w.map((e,t)=>{var i;return(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{className:h.dateWrapper,children:[(0,p.jsx)("span",{className:h.line}),(0,p.jsx)("span",{className:h.dateSpan,children:null===e||void 0===e?void 0:e.date}),(0,p.jsx)("span",{className:h.line})]}),null===e||void 0===e||null===(i=e.message)||void 0===i?void 0:i.map((e,t)=>{var i,a,o,n,s;return(0,p.jsxs)("div",{className:h.chatcontainerall,children:[(0,p.jsxs)("div",{className:"Left"===e.alignment?h.senderDiv:h.receDiv,children:[(0,p.jsx)("div",{children:"Left"===e.alignment&&(0,p.jsx)("div",{className:h.messageSender,children:e.senderFullName})}),(0,p.jsx)("div",{className:"Left"===e.alignment?h.messageTime:h.messageTimeRight,children:(0,ae.t7)(null===e||void 0===e?void 0:e.createdOnStamp)?(0,ae.t7)(null===e||void 0===e?void 0:e.createdOnStamp):""}),"Right"===e.alignment&&(0,p.jsx)("div",{className:h.messageInfo,children:(0,p.jsx)("span",{className:h.senderIconRight})})]}),(0,p.jsxs)("div",{className:"".concat(h.messageContainer," ").concat("Left"===e.alignment?h.messgaeLeft:h.messageRight," "),children:["Left"===e.alignment&&(0,p.jsx)("div",{className:h.messageInfo,children:(0,p.jsx)("span",{className:h.investigatorIcon,children:"Incoming"===e.fos_directionname?e.sender:(0,p.jsx)("img",{className:h.investigatorIconImg,src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABsAAAAwCAYAAADgvwGgAAAABHNCSVQICAgIfAhkiAAAAqJJREFUWEe9l73LuVEYxy8M9AxMFpSwiDKSUgYpUQZl8w94KzbJYvMHyMDgJzYvi9VmM5DCIPK+KjYKz33UI4cb98v5OXUvd+d8P+d7netc5xwBAFyoj1jLZrPg9/vhdDrB+Xy+6QoEgn8CvjCxWAyz2QwTpps5Lxg1GFar1ZMucpbJZJ7+bzYbbs4SiQREIhFMsFAoQDqdfrkcnGCNRgPMZjMmqtPp4HA4vF131rBQKATJZBITtVqttOF8JLOCiUQiWCwWmMZ8PgebzcYok1nBqM5wueC7RKVSMQKhToxhcrkcer0eJjwYDMDlcpGHoRRHqX7f1Gr1deMybYydrdfrJ002IWQcRqfTCcViEYNtt1swmUxMTV37MXI2Ho/h5+cHE0abulKpkIfRhdBgMMB+v/8OjO16MQ4jieRgBJNKpTAajXhn4g1GzZzo4flqIa/n2VdhVBV/6QztJbpCm8vlWGUi6hwOh98fnnSHJBr4X7Ixn8+D2+3GXKAaqVQqWTv7WEFarRbo9XpMWCgUgkKhIA8bDocgk8kw4d1uB0ajkTxsuVwCcnLfarUaxGIx8jC66mGxWFAF/w6MSyZ+LFcSiQQmkwmRTPwIK5VK4HA4MFgwGIRms8k6hB9hpKr938xe7rNAIPB0X4/H41CtVjm5eumM7sGAblHoNsWnPTl79TLhmoH3k8NgGo0G2u02kYOSLgI3GN3Vejqdgt1u5xM5bOwV9nh4olCisD3e6/lSn2Berxe63S5fXdrxNxhygQounRv0PxqNQr1e5zUJ2jC+U/T5fNDpdDhBWcMQ5Xg8glarZQ3kBEMULlcDzrA/W2w2O28YgjIFEoEhoMfjgX6//3YdicEQ5VOxJgq7t5VKpaBcLt/e3CihqEr15bv+Nx8Wv1c5r+CRVRsfAAAAAElFTkSuQmCC",alt:"sender-icon"})})}),(0,p.jsxs)("div",{className:"".concat(h.messgaeBubble," ").concat("Left"===e.alignment?h.leftBubble:h.rightBubble),children:[K(null===e||void 0===e||null===(i=e.description)||void 0===i?void 0:i.trim()).length>=500&&W!=t?(0,p.jsx)("span",{"data-hj-suppress":"true",className:h.msgcontent,dangerouslySetInnerHTML:{__html:He.A.sanitize("".concat(Y(null===e||void 0===e||null===(a=e.description)||void 0===a||null===(o=a.trim())||void 0===o?void 0:o.slice(0,500)),"..."))}}):(0,p.jsx)("span",{"data-hj-suppress":"true",className:h.msgcontent,dangerouslySetInnerHTML:{__html:He.A.sanitize(null!=W?"".concat(Y(null===e||void 0===e||null===(n=e.description)||void 0===n?void 0:n.trim())):Y(null===e||void 0===e?void 0:e.description))}}),K(null===e||void 0===e||null===(s=e.description)||void 0===s?void 0:s.trim()).length>=500&&(0,p.jsx)("button",{onClick:()=>{return e=t,void H(t=>t===e?null:e);var e},className:h.readmoreless,children:W==t?"Read less":"Read more"})]}),"Right"===e.alignment&&(0,p.jsx)("div",{className:h.messageInfo,children:(0,p.jsx)("span",{className:h.senderIcon,children:(0,p.jsx)("img",{className:h.senderIconImg,src:Ge,alt:"sender-icon"})})})]})]},t)})]},t)})})})})};const Ze=i.p+"static/media/Icon_loading_chat.2e27a671726a68b1f717309389b446de.svg";var Je=i(9628),$e=(i(2342),i(9252)),et=i(395);const tt=i.p+"static/media/Icon_Info_msg_fail.f412208d95820de63198820f9a86088a.svg";const it=i.p+"static/media/Icon_refresh_fail.830693db5482837edec9b552cb89d57d.svg";var at=i(3273),ot=i(2038);const nt=(0,m.A)({spanSender:{display:"flex",justifyContent:"right",fontSize:"small"},spanReceiver:{display:"flex",justifyContent:"right",paddingLeft:"1rem",fontSize:"small"},chatdate:{display:"flex",justifyContent:"center",fontSize:"small"}
1,receDiv:{display:"flex",justifyContent:"end"},receDivFail:{display:"flex",justifyContent:"end",alignItems:"center"},messageTimeRight:{textAlign:"left",marginTop:"4px",fontSize:"1rem",marginRight:"0.75rem",color:"#767676",fontFamily:"AssistantRegular",alignItems:"center"},messageTimeRightFail:{textAlign:"left",marginTop:"4px",fontSize:"1rem",marginRight:"0.75rem",color:"#767676",fontFamily:"AssistantRegular",display:"flex",alignItems:"center",paddingBottom:"1rem"},commonfailmsg:{display:"flex",paddingLeft:"1rem",alignItems:"center",cursor:"pointer"},messageContainer:{display:"flex",flexDirection:"row",alignItems:"baseline",padding:"0 10px",marginBottom:"10px"},messageRight:{alignSelf:"flex-end",maxWidth:"50%",marginLeft:"auto",width:"max-content"},messgaeBubble:{padding:"8px 12px",borderRadius:"7.5px",marginBottom:"2px",position:"relative",wordWrap:"break-word"},rightBubble:{backgroundColor:"#e4eef8",borderTopRightRadius:0},messageRightFail:{display:"flex",width:"50%",justifyContent:"end"},msgcontent:{color:"#404040",fontSize:"1.125rem",fontFamily:"AssistantRegular","& p":{display:"block"}},refreshcont:{color:"#D22D64",fontSize:"1.125rem",fontFamily:"AssistantRegular",top:"2%",right:"1.5rem",paddingRight:"0.375rem",textDecoration:"underline"},msgfailedtext:{color:"#CF0000",fontSize:"1.125rem",fontFamily:"AssistantRegular",top:"2%",left:"0",paddingLeft:"0.375rem"},messageFailRight:{alignSelf:"flex-end",position:"relative",display:"inline-block"},messageInfo:{display:"flex",alignItems:"center",marginBottom:"4px"}
1,senderIconImg:{width:"1rem",height:"1.563rem"},senderIcon:{width:"2.5rem",height:"2.5rem",borderRadius:"50%",marginLeft:"8px",backgroundColor:"#428FDE",color:"white",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"1.25rem"},chatwindowheightfail:{paddingLeft:"1rem",paddingRight:"1rem","@media(min-width:600px)":{maxWidth:"100%"}},chatwindowheightfailcls:{position:"relative",width:"100%",alignItems:"flex-end"},readmoreless:{all:"unset",fontFamily:"AssistantRegular",color:"#D22D64",fontSize:"1.125rem",textDecoration:"underline",cursor:"pointer",marginBottom:"1rem"}});const st=function(e){var t;const i=nt();let o=lt();const n=(0,l.useState)(!1),s=(0,a.A)(n,2),r=s[0],m=s[1],u=(0,l.useState)(""),g=(0,a.A)(u,2),h=g[0],x=g[1],f=(0,l.useState)(!1),v=(0,a.A)(f,2),b=v[0],y=v[1],w=(0,l.useState)(""),S=(0,a.A)(w,2),A=(S[0],S[1],(0,l.useState)("")),C=(0,a.A)(A,2),j=(C[0],C[1],(0,l.useState)(null)),k=(0,a.A)(j,2),D=k[0],F=k[1],R=()=>{x(""),m(!1)},B=()=>{y(!1)};function _(t){const i=t;(new c.A).httpConnection("".concat(d.y.SERVICES.resendMessage),"post",i).then(t=>{var a,o;"success"===t.status?(y(!0),setTimeout(()=>{B()},2e3),o=i.uiDigitalMessageId,localStorage.removeItem(o)):(m(!0),setTimeout(()=>{R()},2e3),x(null===e||void 0===e||null===(a=e.drupaldata)||void 0===a?void 0:a.resenderrorMsg))}).catch(()=>{var t;m(!0),setTimeout(()=>{R()},2e3),x(null===e||void 0===e||null===(t=e.drupaldata)||void 0===t?void 0:t.defaulterror)})}return(0,l.useEffect)(()=>{o=lt()},[]),(0,p.jsxs)($e.A,{id:"resendContainID",maxWidth:"lg",className:i.chatwindowheightfail,children:[b&&(0,p.jsx)(ot.A,{message:"Message send successfully.",onClose:B}),r&&(0,p.jsx)(at.A,{message:h,onClose:R}),(0,p.jsx)("div",{id:"chatwindowheightfail",className:i.chatwindowheightfailcls,children:(0,p.jsx)(et.sB,{children:null===(t=o)||void 0===t?void 0:t.map((t,a)=>{var n,s,l,r,d,c,m,u;return(null===(n=o[a])||void 0===n?void 0:n.regardingObjectId)===(null===e||void 0===e?void 0:e.incidentId)&&(0,p.jsx)(p.Fragment,{children:(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{className:"".concat(i.messageContainer," ").concat(i.messageRight," ").concat(i.messageRightFail),children:[(0,p.jsxs)("div",{className:"".concat(i.messgaeBubble," ").concat(i.rightBubble),children:[(null===(s=o[a])||void 0===s?void 0:s.field_dp_x_description.trim().length)>=500&&D!=a?(0,p.jsx)("span",{"data-hj-suppress":"true",className:i.msgcontent,dangerouslySetInnerHTML:{__html:"".concat(null===(l=(0,Ve.D4)(null===(r=o[a])||void 0===r?void 0:r.field_dp_x_description))||void 0===l?void 0:l.slice(0,500),"...")}}):(0,p.jsx)("span",{"data-hj-suppress":"true",className:i.msgcontent,dangerouslySetInnerHTML:{__html:null!=D?"".concat((0,Ve.D4)(null===(d=o[a])||void 0===d?void 0:d.field_dp_x_description),"..."):(0,Ve.D4)(null===(c=o[a])||void 0===c?void 0:c.field_dp_x_description)}}),(null===(m=o[a])||void 0===m?void 0:m.field_dp_x_description.trim().length)>=500&&(0,p.jsx)("button",{onClick:()=>{return e=a,void F(t=>t===e?null:e);var e},className:i.readmoreless,children:D==a?"Read less":"Read more"})]}),(0,p.jsx)("div",{className:i.messageInfo,children:(0,p.jsx)("span",{className:i.senderIcon,children:(0,p.jsx)("img",{className:i.senderIconImg,src:Ge,alt:"sender-icon"})})})]},a),"failed"===(null===(u=o[a])||void 0===u?void 0:u.status)&&(0,p.jsx)(p.Fragment,{children:(0,p.jsx)("div",{className:i.receDivFail,children:(0,p.jsxs)("div",{className:i.messageTimeRightFail,children:[(0,p.jsxs)("div",{className:i.commonfailmsg,children:[(0,p.jsx)("img",{alt:"message-failed-icon",src:tt,"aria-label":"Message Failed"}),(0,p.jsx)("span",{className:i.msgfailedtext,children:"Message Failed!"})]}),(0,p.jsxs)("div",{className:i.commonfailmsg,onClick:()=>_(o[a]),children:[(0,p.jsx)("span",{className:i.refreshcont,children:"Resend"}),(0,p.jsx)("img",{alt:"resend-icon",src:it,"aria-label":"Resend Message"})]})]})})})]})})})})})]})};function lt(){for(var e=[],t=0;t<(null===(i=localStorage)||void 0===i?void 0:i.length);t++){var i,a,o;if("UM_"==(null===(a=localStorage)||void 0===a||null===(o=a.key(t))||void 0===o?void 0:o.substring(0,3))){var n;let i=null===(n=localStorage)||void 0===n?void 0:n.key(t),a=localStorage.getItem(i);e.push(JSON.parse(a))}}return e?e.reverse():e}var rt=i(7257);const dt=window.CKEditorLicense,ct=(0,m.A)({chatstaticdiv:{fontSize:"1.25rem",margin:"1rem 0",paddingLeft:"1.5rem",color:"rgb(34, 115, 195)",fontFamily:"AssistantRegular",position:"relative","@media(max-width:786px)":{marginBottom:"1rem",display:"block"}},Editordiv:{"@media(max-width:1024px)":{maxHeight:"100% !important",overflow:"unset","& .ck-sticky-panel__content":{maxWidth:"18rem"}},maxHeight:"12rem!important",overflow:"auto","& div:nth-child(2)":{"& div:nth-child(3)":{"& div":{backgroundColor:"#F7F7F7"}}}}});function mt(e){let t=e.incidentId,o=e.pnx,n=(e.currentStatus,e.caseDetailsData);const s=new c.A,r=ct(),m=(0,l.useState)(),u=(0,a.A)(m,2),g=u[0],f=u[1],v=(0,l.useState)(),b=(0,a.A)(v,2),y=(b[0],b[1],(0,l.useState)()),w=(0,a.A)(y,2),S=w[0],A=w[1],C=I(),j=(0,l.useState)(""),k=(0,a.A)(j,2),D=k[0],F=k[1],R=(0,l.useState)(""),B=(0,a.A)(R,2),_=B[0],N=B[1],T=(0,l.useState)("0"),E=(0,a.A)(T,2),z=E[0],M=E[1],P=(0,l.useState)(""),W=(0,a.A)(P,2),H=(W[0],W[1],(0,l.useRef)(null)),V=(0,l.useRef)(),Y=((0,l.useRef)(null),(0,l.useState)(()=>Math.random())),U=(0,a.A)(Y,2),q=U[0],G=U[1],K=(0,l.useState)({}),Q=(0,a.A)(K,2),X=Q[0],Z=Q[1],J=(0,l.useState)(!1),$=(0,a.A)(J,2),ee=$[0],te=$[1],ae=(0,l.useState)(!1),oe=(0,a.A)(ae,2),ne=oe[0],se=oe[1],le=(0,l.useState)(""),re=(0,a.A)(le,2),de=(re[0],re[1],(0,l.useState)("")),ce=(0,a.A)(de,2),me=(ce[0],ce[1],(0,l.useState)(!1)),pe=(0,a.A)(me,2),ue=pe[0],ge=pe[1],he=(0,l.useState)(!1),xe=(0,a.A)(he,2),fe=(xe[0],xe[1],(0,l.useState)("")),ve=(0,a.A)(fe,2),be=(ve[0],ve[1],(0,l.useState)(!1)),ye=(0,a.A)(be,2),we=(ye[0],ye[1],(0,l.useState)("")),Se=(0,a.A)(we,2),Ae=(Se[0],Se[1],(0,l.useState)("")),Ce=(0,a.A)(Ae,2),je=(Ce[0],Ce[1],(0,l.useState)(!1)),ke=(0,a.A)(je,2),De=(ke[0],ke[1]),Fe=(0,l.useState)(""),Re=(0,a.A)(Fe,2),Be=Re[0],_e=Re[1],Ie=(0,l.useState)(!1),Ne=(0,a.A)(Ie,2),Te=(Ne[0],Ne[1],(0,l.useState)("")),Ee=(0,a.A)(Te,2),ze=Ee[0],Me=Ee[1],Le=(0,l.useState)(""),Oe=(0,a.A)(Le,2),Ye=Oe[0],Ge=Oe[1],Ke=(0,l.useState)(""),Qe=(0,a.A)(Ke,2),$e=Qe[0],et=Qe[1],tt=(0,l.useState)(0),it=(0,a.A)(tt,2),at=(it[0],it[1]),ot=(0,l.useState)(1),nt=(0,a.A)(ot,2),lt=nt[0],mt=nt[1],pt=(0,l.useRef)();i(482);i(5493);const ut={incidentid:t};(0,l.useEffect)(()=>{s.httpConnection("".concat(d.y.SERVICES.getRepresentativeCaseList),"post",ut).then(e=>{Z(null===e||void 0===e?void 0:e.casedetails)}).catch(e=>{console.warn("error for view case",e)});const e=new h.A;let t=x.Y.SERVICES.getRteMessage;e.httpConnection(t,"get").then(e=>{e&&f(e)}).catch(e=>{A(editordefaulttext),f(S)})},[_]);const gt=e=>{var t,i,a,o;
1F(He.A.sanitize(null===e||void 0===e?void 0:e.getData()));let n=(e=>{const t=He.A.sanitize(e);return(new DOMParser).parseFromString(t,"text/html").body.textContent||""})(null===e||void 0===e?void 0:e.getData());M(null===n||void 0===n?void 0:n.length);null===e||void 0===e||null===(t=e.getData())||void 0===t||null===(i=t.trim())||void 0===i||null===(a=i.replace(/\s/g,""))||void 0===a||null===(o=a.replace(/(<([^>]+)>)/gi,""))||void 0===o||o.length};(0,l.useEffect)(()=>(ge(!0),()=>ge(!1)),[]);const ht=(0,l.useMemo)(()=>ue?{editorConfig:{height:20,removePlugins:["PasteFromOffice"],disallowedContent:"img[src]",warnOnLimitOnly:!0,hardLimit:!0,maxWordCount:1,toolbar:{withText:!0,items:["fontSize","fontFamily","fontColor","fontBackgroundColor","undo","redo","|","bold","italic","underline","strikethrough","subscript","superscript","removeFormat","link","alignment","|","bulletedList","numberedList","outdent","indent"]},plugins:[rt.C1k,rt.L$Z,rt.ncb,rt.Y0,rt.Xhp,rt.CyN,rt.NGz,rt.uwK,rt.LcX,rt.rwA,rt.ayq,rt.Z4w,rt.FG2,rt.DZT,rt.He$,rt.n7r,rt.$ts,rt.TgZ,rt._KA,rt.J20,rt.yN4,rt.B8B,rt.y4,rt.ybQ,rt.PXQ,rt.fzL,rt.U9O,rt.kky,rt.pHs,rt.xMA,rt.UUp,rt.sHs,rt.Bvn,rt.GkN,rt.Eac,rt.Z3f,rt.XIK,rt.r6L,rt.Cdo,rt.TLK,rt.e1w,rt.e1U,rt.$r$,rt.DeV,rt.t0N,rt.z2z,rt.a24],wordcount:{pasteWarningDuration:0,onUpdate:e=>{}},fontFamily:{supportAllValues:!0},fontSize:{options:[10,12,14,"default",18,20,22],supportAllValues:!0},heading:{options:[{model:"paragraph",title:"Paragraph",class:"ck-heading_paragraph"},{model:"heading1",view:"h1",title:"Heading 1",class:"ck-heading_heading1"},{model:"heading2",view:"h2",title:"Heading 2",class:"ck-heading_heading2"},{model:"heading3",view:"h3",title:"Heading 3",class:"ck-heading_heading3"},{model:"heading4",view:"h4",title:"Heading 4",class:"ck-heading_heading4"},{model:"heading5",view:"h5",title:"Heading 5",class:"ck-heading_heading5"},{model:"heading6",view:"h6",title:"Heading 6",class:"ck-heading_heading6"}]},htmlSupport:{allow:[{name:/^.*$/,styles:!1,attributes:!1,classes:!1}],disallow:[{name:/[\s\S]+/,attributes:{key:/^on.*$/}}]},forcePasteAsPlainText:!0,initialData:"",licenseKey:dt,list:{properties:{styles:!0,startIndex:!0,reversed:!0}},mention:{feeds:[{marker:"@",feed:[]}]},placeholder:"Enter your message",table:{contentToolbar:["tableColumn","tableRow","mergeTableCells","tableProperties","tableCellProperties"]},menuBar:{isVisible:!1},disallowedContent:"<a>"}}:{},[ue]).editorConfig,xt=e=>{const t=Ue().tz(e);return Ue().utc(t,"DD-MM-YYYY HH:mm:ss")};(0,l.useEffect)(()=>{},[Be]);const ft=(0,l.useRef)(null);(0,l.useEffect)(()=>{(null===ft||void 0===ft?void 0:ft.current)&&setTimeout(()=>{var e;null===ft||void 0===ft||null===(e=ft.current)||void 0===e||e.scrollTo({top:null===ft||void 0===ft?void 0:ft.current.scrollHeight,behavior:"smooth"})},350)});const vt=e=>{if(["a","img","undefined"].includes(null===e||void 0===e?void 0:e.name))return!0;if(null!==e&&void 0!==e&&e.getChildren)for(const t of e.getChildren())if(vt(t))return!0;return!1};return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("div",{className:C.mainconversationdiv,children:[(0,p.jsx)("div",{className:r.chatstaticdiv,children:(0,p.jsxs)("span",{className:C.warningChatMsg,children:[null===g||void 0===g?void 0:g.tabmsg," Press Alt+0 for keyboard help."]})}),""!==Ye&&(0,p.jsxs)("div",{className:C.errorMessageContainer,children:[(0,p.jsxs)("div",{role:"alert",className:C.messageText,children:[(0,p.jsx)("img",{className:C.messageIcon,alt:"error-icon",src:ie.A}),(0,p.jsx)("span",{children:Ye})]}),(0,p.jsx)("div",{className:C.messageClose,children:(0,p.jsx)("button",{className:C.closeBtn,onClick:()=>Ge(""),children:(0,p.jsx)("img",{alt:"close-icon",src:O.A})})})]}),ze&&(0,p.jsxs)("div",{className:C.loadmoreChatBtn,children:[$e&&(0,p.jsx)("img",{alt:"loading-icon",className:C.loadingIcon,src:Ze}),(0,p.jsx)("button",{className:C.loadmoreBtn,disabled:!1,onClick:()=>{mt(e=>e+1),De(!0),pt.current&&pt.current()},children:"Press to load more"})]}),(0,p.jsxs)("div",{className:C.mainchatall,ref:ft,id:"chatwindow",children:[(0,p.jsx)(Xe,{incidentId:t,pnx:o,drupaldata:g,isreloading:ee,onUpdate:_,elementRef:ft,sendDataToParent:e=>{Me(e),0==e&&mt(1)},onMethodReady:e=>{pt.current=e},chatLoadMoreClick:lt,loadingDatafromchild:e=>{et(e)},resetLoadingRow:e=>{0==e&&mt(1),at(e)}}),(0,p.jsx)("br",{}),(0,p.jsx)(st,{incidentId:t,drupaldata:g,isreloading:ne},q)]}),(0,p.jsx)("div",{className:C.ckeditorwindow,children:(0,p.jsx)("table",{className:C.mainCh
1atBoxTbl,children:(0,p.jsxs)("tr",{children:[(0,p.jsx)("td",{className:C.containerTD,children:(0,p.jsx)("div",{className:"main-container",children:(0,p.jsx)("div",{className:"editor-container editor-container_classic-editor",ref:H,children:(0,p.jsxs)("div",{className:"editor-container__editor",children:[(0,p.jsxs)("div",{className:5e3-z>=0?C.countdiv:"".concat(C.countdiv," ").concat(C.limitcross),children:["Max. characters:",5e3-z," "]}),(0,p.jsx)("div",{className:r.Editordiv,"data-hj-suppress":"true",children:ht&&(0,p.jsx)(Pe.aF,{editor:rt.aRV,id:"editor",onError:(e,t)=>{alert("Error occured")},onFocus:(e,t)=>{},onBlur:(e,t)=>{t.plugins.get("ClipboardPipeline").on("inputTransformation",(e,t)=>{var i;console.log("data0",t),"Files"===(null===t||void 0===t||null===(i=t.dataTransfer)||void 0===i?void 0:i.types[0])&&(console.log("data1",t),alert("Image or link/HTML code copy paste not allowed!"),e.stop())})},onChange:(e,t)=>{V.current=t,gt(t)},onReady:e=>{V.current=e,window.editor=e,e.plugins.get("ClipboardPipeline").on("inputTransformation",(e,t)=>{console.log("data3",t),console.log("data4",Array.from(t.content.getChildren()));for(const i of t.content.getChildren())vt(i)&&(alert("Image or link/HTML code copy paste not allowed!"),e.stop())}),e.editing.view.document.on("paste",(e,t)=>{var i,a,o,n;const s=t.dataTransfer.getData("text/plain");null===t||void 0===t||null===(i=t.dataTransfer)||void 0===i||null===(a=i._data)||void 0===a||a.set("text/html",s),null===t||void 0===t||null===(o=t.dataTransfer)||void 0===o||null===(n=o._data)||void 0===n||n.set("text",s)})},onAfterDestroy:()=>{},data:D,config:ht})})]})})})}),(0,p.jsx)("td",{className:C.sendIcontbltb,children:z<=5e3&&z>=0&&""!=D?(0,p.jsx)(L.A,{id:"sendBtnConversation","aria-label":"Send Message",onClick:function(){const e=D;N(e),(e=>{var a=new Date;const o=i(2197);let l=(0,Ve.lF)(e);const r=(new We.o).encode(l);if(l){let e=o.v4();n||alert("Case details data not able to fetch");const i={from:null===X||void 0===X?void 0:X.contactid,field_dp_x_description:r,createdOn:xt(null===a||void 0===a?void 0:a.toString()),owingUserId:null===X||void 0===X?void 0:X.ownerid,uiDigitalMessageId:e,caseId:null===X||void 0===X?void 0:X.ticketnumber,regardingObjectId:t},l={from:null===X||void 0===X?void 0:X.contactid,field_dp_x_description:r,createdOn:xt(null===a||void 0===a?void 0:a.toString()),owingUserId:null===X||void 0===X?void 0:X.ownerid,uiDigitalMessageId:e,caseId:null===X||void 0===X?void 0:X.ticketnumber,regardingObjectId:t,status:"pending"};s.httpConnection("".concat(d.y.SERVICES.sendMessage),"post",i).then(t=>{"success"===t.status?(te(!0),_e("")):"500"===t.statuscode?(l.status="failed",localStorage.setItem("UM_"+e,JSON.stringify(l)),se(!0),_e(l)):Ge(g?g.defaulterror:"Something went wrong, please try after sometime.")}).catch(e=>{Ge(g?g.defaulterror:"Something went wrong, please try after sometime.")})}})(e),function(){var e=V.current;null===e||void 0===e||e.setData(" "),G(Math.random())}(),G(Math.random())},disableRipple:!0,className:C.sendBtn,children:(0,p.jsx)("img",{src:qe,className:C.sendIcon,alt:"send"})}):(0,p.jsx)(L.A,{id:"sendBtnConversation","aria-label":"Send Message",disableRipple:!0,className:C.sendDisableBtn,children:(0,p.jsx)("img",{src:qe,className:C.sendIcon,alt:"send"})})})]})})})]}),(0,p.jsx)(Je.N9,{})]})}var pt=i(682),ut=i(3360);const gt=i.p+"static/media/alert_bell_icon.4dbe3573c77598806f0a0443de5b664a.svg";var ht=i(1821),xt=i(4506);const ft=["children","value","index"],vt=[{title:"DigitalMessaging"},{title:"Case Outcomes"},{title:"Case documents"}];function bt(e){const t=e.children,i=e.value,a=e.index,l=(0,n.A)(e,ft),r=se();return(0,p.jsx)("div",(0,o.A)((0,o.A)({style:{backgroundColor:"red"},role:"tabpanel",hidden:i!==a,id:"simple-tabpanel-".concat(a),"aria-labelledby":"simple-tab-".concat(a)},l),{},{children:i===a&&(0,p.jsx)(s.A,{className:r.TabPanelStyle,children:t})}))}function yt(e){let t=e.incidentId,i=e.caseDetailsData,o=e.isCaseOutcome,n=e.handleResetTab,r=e.currentStatus,d=e.pnx,m=e.tabPosition,u=void 0===m?4:m;const g=l.useState(),f=(0,a.A)(g,2),v=f[0],b=f[1],y=se(),w=new h.A,S=l.useState(vt),A=(0,a.A)(S,2),C=A[0],j=A[1],k=l.useState(!1),_=(0,a.A)(k,2),I=(_[0],_[1]),N=l.useState(!1),T=(0,a.A)(N,2),E=T[0],z=T[1],M=(0,l.useState)(!0),L=(0,a.A)(M,2),O=L[0],P=L[1],H=(0,l.useState)(!0),V=(0,a.A)(H,2),Y=V[0],U=V[1],q=(0,l.useState)(!1),G=(0,a.A)(q,2),K=G[0],Q=G[1],X=()=>{Q(window.innerWidth<=1024)},Z=(0,W.d4)(e=>e.featureFlagReducer.featureFlagData),J=(0,l.useRef)(null);(0,l.useEffect)(()=>(X(),window.addEventListener("resize",X),()=>{window.removeEventListener("resize",X)}),[]),(0,l.useEffect)(()=>{b(4!==u?u:0)},[u,d]),(0,l.useEffect)(()=>{console.log(o,"case outcome"),console.log("case details object",i),o&&(b(1),setTimeout(()=>{J.current&&(J.current.focus(),J.current.scrollIntoView({behavior:"smooth"}),n())},100))},[o]),(0,l.useEffect)(()=>{ee()},[]);const $=(0,W.d4)(e=>e.stateRolesAndUser,W.bN).stateRolesAndUser;(0,l.useEffect)(()=>
1{if(Z.length>0){const e=(0,Oe.A)("enableDownloadTab",$.roles,"",$.userId,Z);z(e);const t=(0,Oe.A)("enableCaseoverviewTab",$.roles,"",$.userId,Z);I(t)}else z(!1),I(!1)},[]);const ee=()=>{w.httpConnection(x.Y.SERVICES.getTabData,"get").then(e=>{e.length>0?j(e):j(vt)}).catch(e=>{})};let te=3;!1===E&&(te=2);const ie=[{yourDocTitle:"Your case documents",filter:"Filtered by:",downloadAll:"Download all",downloadSelected:"Download selected",sharedBy:"Shared by",purpose:"Purpose:",download:"Download",documentTypeLabel:"Type of document:",readMore:"Read more",readLess:"Read less",wait:"Please wait while we load available case files",noRecord:"No record(s) found.",downloadTimerInSec:"60",progressTimerInSecSmall:"10",progressTimerInSecMedium:"30",progressTimerInSecLarge:"60",progressTimerInSecExtraLarge:"120",downloadErrorTimerInSec:"60",downloadWait:"Please wait for the download",downloadProgress:"Download is in progress",downloadErrorMsg:"The requested document has not been able to download on your device. Please try again",nullLabel:"",readMoreLimit:"80"}],ae=(0,l.useState)(ie),le=(0,a.A)(ae,2),re=le[0],de=le[1],ce=(0,l.useState)(!1),me=(0,a.A)(ce,2),pe=me[0],ue=me[1],ge=(0,l.useState)(null),he=(0,a.A)(ge,2),xe=he[0],fe=he[1],ve=(0,l.useState)({}),be=(0,a.A)(ve,2),ye=be[0],we=be[1],Se=(0,l.useState)({flag:!1,message:""}),Ae=(0,a.A)(Se,2),Ce=Ae[0],je=Ae[1],ke=(0,l.useState)({}),De=(0,a.A)(ke,2),Fe=De[0],Re=De[1],Be=(0,ht.dk)().accounts,_e=(0,l.useState)([]),Ie=(0,a.A)(_e,2),Ne=(Ie[0],Ie[1]),Te=(0,l.useState)(!1),Ee=(0,a.A)(Te,2),ze=(Ee[0],Ee[1]),Me=(0,l.useRef)([]),Pe=(0,l.useState)(""),We=(0,a.A)(Pe,2),He=We[0],Ve=We[1],Ye=(0,l.useState)(!0),Ue=(0,a.A)(Ye,2),qe=Ue[0],Ge=Ue[1],Ke=(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),Qe=1,Xe=2,Ze=3,Je=new c.A,$e=(0,W.wA)();(0,l.useEffect)(()=>{Be&&Be.length>0&&Be[0].idTokenClaims&&Be[0].idTokenClaims.oid?fe(Be[0].idTokenClaims.oid):fe(null)},[Be]),(0,l.useEffect)(()=>{2==v&&w.httpConnection(x.Y.SERVICES.getCaseDocuments,"get").then(e=>{e&&Array.isArray(e)?de(e):de(ie)}).catch(e=>{de(ie)})},[v]),(0,l.useEffect)(()=>()=>{$e((0,pt.g)())},[]);(0,l.useEffect)(()=>{Je.httpConnection(ut.c.SERVICES.getSharedConfiguration,"get").then(e=>{e&&null!==e&&void 0!==e&&e.data&&Re(null===e||void 0===e?void 0:e.data[0])}).catch(e=>{je({flag:!0,message:(0,xt.r_)(e,Ke)}),Re({}),console.warn(e)});const e={caseId:t,orgId:""};let i;qe&&(i=setInterval(()=>{Ve(e=>3===e.length?"":e+".")},1e3)),Je.httpConnection(ut.c.SERVICES.getMetaData,"post",e).then(e=>{var t;we(e),(e=>{if((null===e||void 0===e?void 0:e.length)>0){const t=null===e||void 0===e?void 0:e.some(e=>{if(null!==e&&void 0!==e&&e.isDownloaded&&"no"==(null===e||void 0===e?void 0:e.isDownloaded.toLowerCase()))return!0});return void ue(t)}ue(!1)})(null===e||void 0===e||null===(t=e.data)||void 0===t?void 0:t.files),Ve(""),qe&&(Ge(!1),clearInterval(i))}).catch(e=>{console.warn(e),we({}),Ve(""),qe&&(Ge(!1),clearInterval(i))})},[t]);const et=function(e){var t;let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const a=1e3*+(null===(t=re[0])||void 0===t?void 0:t.downloadErrorTimerInSec);i&&clearInterval(i),$e((0,pt.wM)({fileName:null===e||void 0===e?void 0:e.documentName,step:Ze,documentId:null===e||void 0===e?void 0:e.documentId})),setTimeout(()=>{$e((0,pt.GQ)({fileName:null===e||void 0===e?void 0:e.documentName,documentId:null===e||void 0===e?void 0:e.documentId}))},a)},tt=(0,l.useRef)(!1);function it(e){console.log("Adding file to queue:",e),Me.current.push(e),Ne([...Me.current]),tt.current||async function(){if(tt.current)return;tt.current=!0,ze(!0);for(;Me.current.length>0;){const t=Me.current[0];try{await at(t.url,t)}catch(e){console.error("Download failed for:",t,e)}Me.current.shift(),Ne([...Me.current]),await new Promise(e=>setTimeout(e,500))}tt.current=!1,ze(!1)}()}const at=async(e,t)=>{const i=e=>1024*+e*1024;try{const a=await fetch(null===e||void 0===e?void 0:e.url),o=await a.blob(),n=document.createElement("a");n.href=window.URL.createObjectURL(o),n.download=null===e||void 0===e?void 0:e.fileName,n.click(),$e((0,pt.wM)({fileName:null===t||void 0===t?void 0:t.documentName,documentId:null===t||void 0===t?void 0:t.documentId,step:Xe})),setTimeout(()=>{$e((0,pt.GQ)({fileName:null===t||void 0===t?void 0:t.documentName,documentId:null===t||void 0===t?void 0:t.documentId}))},(e=>{var a,o,n,s;return+e<=i(500)?1e3*+(null===(a=re[0])||void 0===a?void 0:a.progressTimerInSecSmall):+t.documentSize>i(500)&&+e<=i(1e3)?1e3*+(null===(o=re[0])||void 0===o?void 0:o.progressTimerInSec
1Medium):+t.documentSize>i(1e3)&&+e<=i(1500)?1e3*+(null===(n=re[0])||void 0===n?void 0:n.progressTimerInSecLarge):1e3*+(null===(s=re[0])||void 0===s?void 0:s.progressTimerInSecExtraLarge)})(null===t||void 0===t?void 0:t.documentSize))}catch(a){je({flag:!0,message:(0,xt.r_)(a,Ke)}),et(t),console.log("Error in downloading ")}},ot=function(e,i){const a={caseId:t,files:[{documentId:e.documentId,documentName:e.documentName}],orgId:""};Je.httpConnection(ut.c.SERVICES.getRequestdownloadforfiles,"post",a).then(a=>{var o,n,s,l;null!==a&&void 0!==a&&null!==(o=a.data)&&void 0!==o&&o.message?(i.message=null===a||void 0===a||null===(n=a.data)||void 0===n?void 0:n.message,"success"===(null===i||void 0===i||null===(s=i.message)||void 0===s?void 0:s.toLowerCase())&&((e,i)=>{const a={caseId:t,instanceId:i,userId:xe,frontDoorEnabled:!0};Je.httpConnection(ut.c.SERVICES.getDownloadsastokens,"post",a).then(t=>{var i,a,o;e.url=null===t||void 0===t||null===(i=t.data)||void 0===i?void 0:i.items[0],(null===t||void 0===t||null===(a=t.data)||void 0===a||null===(o=a.items)||void 0===o?void 0:o.length)>0?it(e):et(e)}).catch(t=>{et(e),console.warn(t)})})(e,null===a||void 0===a||null===(l=a.data)||void 0===l?void 0:l.id)):et(e)}).catch(t=>{et(e),console.warn(t)})};return(0,l.useEffect)(()=>{P(0!=v),v===(null===C||void 0===C?void 0:C.length)-1?U(!1):U(!0)},[v,K,C]),(0,p.jsx)(p.Fragment,{children:(0,p.jsxs)(s.A,{sx:{width:"100%"},className:y.boxDisplayStyle,children:[(0,p.jsxs)("div",{className:y.boxContainer,children:[O&&(0,p.jsx)(ne.A,{disableRipple:!0,"aria-label":"Previous",className:y.prevButton,onClick:()=>{b(0===v?0:v-1),n()},children:(0,p.jsx)(R.A,{className:y.nextPrevColor})}),(0,p.jsx)(s.A,{sx:{borderBottom:1,borderColor:"divider"},className:y.tabBox,children:(0,p.jsx)(D.A,{className:y.tabContainer,TabIndicatorProps:{style:{background:"#D22D64"}},value:v,onChange:(e,t)=>
1{b(t),n()},children:null===C||void 0===C?void 0:C.map((e,t)=>(0,p.jsx)(F.A,{disableRipple:!0,sx:{"&:focus-visible":{backgroundColor:"#D22D6430",borderRadius:"8px"}},ref:1===t?J:null,id:e.title,label:2===t&&pe?(0,p.jsxs)("span",{"data-hj-suppress":"true",className:y.tabs,children:[e.title,(0,p.jsx)("span",{children:(0,p.jsx)("img",{alt:"Files available",src:gt})})," "]}):(0,p.jsxs)("span",{"data-hj-suppress":"true",className:y.tabs,children:[e.title," "]})},"".concat(e.title,"-").concat(t)))})}),Y&&(0,p.jsx)(ne.A,{disableRipple:!0,"aria-label":"Next",className:y.nextButton,onClick:()=>{v===(null===C||void 0===C?void 0:C.length)-1?b((null===C||void 0===C?void 0:C.length)-1):b(v+1),n()},children:(0,p.jsx)(B.A,{className:y.nextPrevColor})})]}),(0,p.jsx)(bt,{"data-testid":"initialState",value:v,index:1,children:(0,p.jsx)(oe,{currentStatus:r,incidentId:t})}),i?(0,p.jsx)(bt,{"data-testid":"secondState",value:v,index:0,children:(0,p.jsx)(mt,{incidentId:t,pnx:d,currentStatus:r,caseDetailsData:i})}):(0,p.jsx)(bt,{"data-testid":"secondState",value:v,index:0,children:" Case details not available to start conversation."}),(0,p.jsx)(bt,{value:v,index:2,showBell:pe,children:(0,p.jsx)(Le,{incidentId:t,pnx:d,handleDownloadFiles:e=>{e.forEach(e=>{$e((0,pt.wM)({fileName:null===e||void 0===e?void 0:e.documentName,documentId:null===e||void 0===e?void 0:e.documentId,step:Qe,documentSize:null===e||void 0===e?void 0:e.documentSize})),(e=>{var t;null===(t=re[0])||void 0===t||t.downloadTimerInSec,ot(e,{message:"Failure",id:""},"")})(e)})},drupalData:re,apiData:ye,toaster:Ce,setToaster:je,config:Fe,setShowBell:ue,loading:qe,dots:He})})]})})}var wt=i(5316);const St=i.p+"static/media/Icon_call.c42644f144cc52c8877ea9ef84133672.svg";var At=i(6111);const Ct=["children","open","onClose"],jt={ticketnumber:"",_fos_caseworker_value:"",_owninguser_value:"",fullname:"",title:"",firstname:"",lastname:"",address1_telephone1:"",internalemailaddress:""},kt=(0,m.A)({dialogTitle:{margin:0,fontSize:"1.75rem",color:"#D22D64",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.375rem"}},caseWorkerTitle:{display:"flex",marginBottom:"1rem","@media(max-width:767px)":{display:"block"}},titleBox:{display:"grid",marginRight:"2rem",width:"33.33%","@media(max-width:767px)":{marginRight:"0",marginBottom:"1rem",width:"100%"}},keyTitle:{color:"#404040",fontSize:"1.25rem",fontFamily:"AssistantRegular","@media(max-width:767px)":{fontSize:"1.25rem"}},keyTitle2:{color:"#545767",fontSize:"1.15rem",fontFamily:"AssistantRegular","@media(max-width:767px)":{fontSize:"1.25rem"}},titleVal:{fontSize:"1.25rem",fontWeight:"600",color:"#404040"},caseRefContainer:{fontFamily:"AssistantSemiBold",padding:"0 1.25rem","@media(max-width:767px)":{padding:"0"}},paper:{minWidth:"30rem","@media (max-width: 786px)":{width:"95%",maxWidth:"95%",minWidth:"95%",maxHeight:"95%"}},caseWorkerEmailContainer:{},caseWorkerEmail:{color:"#2273C3",wordBreak:"break-all"},caseWorkerEmailVal:{marginInlineStart:"0rem",marginTop:"0.5rem",marginBottom:"1.5rem","@media(max-width:767px)":{marginTop:"0",marginBottom:"1rem"}},caseWorkerPhone:{},caseWorkerInfo:{marginBottom:"0.5rem"},callIcon:{marginLeft:"1rem",fontSize:"1.25rem"},caseWorkerPhoneContainer:{display:"grid"},contactList:{display:"flex",alignItems:"center"},caseRefTicket:{},caseRefTicketVal:{marginInlineStart:"0rem",fontSize:"1.5rem",fontFamily:"AssistantSemiBold",paddingBottom:"0.938rem",borderBottom:"0.063rem solid #4040401f",marginBottom:"0.938rem","@media(max-width:767px)":{fontSize:"1.25rem"}},dialogHeader:{display:"flex",justifyContent:"center",color:"#D22D64"},keyTitleContact:{color:"#404040",fontSize:"1.375rem",fontFamily:"AssistantBold"},contactPhoneVal:{marginInlineStart:"0rem",marginTop:"0.5rem",display:"flex",alignItems:"center",marginBottom:"0.625rem","@media(max-width:767px)":{marginTop:"0"}}}),Dt=[{dialogTitle:"Investigator details",name:"Name",email:"Email address",contactTitle:"Contact information",phone:"Phone number"}],Ft=[{email:"[email protected]",mobile:"0800 023 4567",name:"Financial ombudsman services helpline"}],Rt=(0,z.Ay)(M.A)(e=>{let t=e.theme;return{"& .MuiDialogContent-root":{padding:t.spacing(2),"@media (max-width: 786px)":{overflowY:"unset !important",paddingBottom:"0 !important"}},"& .MuiDialogActions-root":{padding:t.spacing(1)}}}
1),Bt=(0,m.A)({cidBtnCls:{right:"5px",top:"10px","@media (max-width: 767px)":{padding:"0.5rem 0"}}}),_t=e=>{const t=e.children,i=(e.open,e.onClose),a=(0,n.A)(e,Ct),r=(0,l.useRef)(null),d=Bt();return(0,p.jsxs)("div",{className:"Info-title",children:[(0,p.jsx)(s.A,(0,o.A)((0,o.A)({sx:{m:0,p:2}},a),{},{children:t})),i?(0,p.jsx)(L.A,{disableRipple:!0,ref:r,tabIndex:0,"aria-label":"close",onClick:i,className:d.cidBtnCls,sx:{right:16,top:16,position:"absolute",color:e=>e.palette.grey[500],"&:focus":{borderRadius:"0.25rem",border:"0.125rem solid black"}},children:(0,p.jsx)("img",{src:O.A,alt:""})}):null]})},It=e=>{var t,i,o,n,s,r,m,u,g;let f=e.open,v=e.handleClose,b=e.incidentid;const y=kt(),w=(0,l.useState)(Dt),S=(0,a.A)(w,2),A=S[0],C=S[1],j=(0,l.useState)([]),k=(0,a.A)(j,2),D=k[0],F=k[1],R=new h.A,B=new c.A,_=(0,l.useState)(jt),I=(0,a.A)(_,2),N=(I[0],I[1],(0,l.useState)({})),T=(0,a.A)(N,2),E=T[0],z=T[1],M=(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN);(0,l.useEffect)(()=>{f&&L();At.AES.encrypt(b,"investigator123").toString()},[f]),(0,l.useEffect)(()=>{const e={incidentid:b};B.httpConnection(d.y.SERVICES.getCaseOwner,"post",e).then(e=>{z(e)}).catch(e=>{(0,H.H)(e,M)})},[]);const L=()=>{R.httpConnection(x.Y.SERVICES.getInvestigatorDetails,"get").then(e=>{"<"!==e[0]?C(e[0]):C(Dt)}).catch(e=>{C(Dt)}),R.httpConnection(x.Y.SERVICES.getDefaultData,"get").then(e=>{"<"!==e[0]?F(e[0]):F(Ft[0])}).catch(e=>{F(Ft[0])})};return(0,p.jsx)("div",{children:(0,p.jsx)(Rt,{onClose:v,"aria-labelledby":"info-dialog-title-investigator",open:f,classes:{paper:y.paper},"data-testid":"CaseWorkerDetailsDialogbox",children:(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(_t,{id:"info-dialog-title-investigator",open:f,onClose:v,children:(0,p.jsx)("div",{className:y.dialogHeader,id:"dialogHeaderID",children:(0,p.jsx)("h2",{className:y.dialogTitle,id:"dialogTitle",children:null===A||void 0===A?void 0:A.dialogTitle})})}),(0,p.jsx)(wt.A,{dividers:!0,children:(0,p.jsxs)("div",{className:y.caseRefContainer,id:"caserefContainerID",children:[(0,p.jsxs)("dl",{children:[(0,p.jsx)("dt",{className:y.caseRefTicket,id:"caseRefticketID",children:(0,p.jsx)("span",{"data-hj-suppress":!0,className:y.keyTitle,id:"keyTitleid",children:null===A||void 0===A?void 0:A.name})}),(0,p.jsx)("dd",{className:y.caseRefTicketVal,id:"caseRefvalueid",children:(0,p.jsx)("span",{children:null!==E&&void 0!==E&&null!==(t=E.caseWorker)&&void 0!==t&&t.fullname&&"NA"!=(null===E||void 0===E||null===(i=E.caseWorker)||void 0===i?void 0:i.fullname)?null===E||void 0===E||null===(o=E.caseWorker)||void 0===o?void 0:o.fullname:null===D||void 0===D?void 0:D.name})})]}),(0,p.jsx)("div",{className:y.caseWorkerInfo,id:"caseworkerinfoid",children:(0,p.jsx)("h3",{className:y.keyTitleContact,children:null===A||void 0===A?void 0:A.contactTitle})}),(0,p.jsxs)("dl",{children:[(0,p.jsx)("dt",{className:y.caseWorkerEmailContainer,id:"emailcontainer",children:(0,p.jsx)("span",{className:y.keyTitle,children:null===A||void 0===A?void 0:A.email})}),(0,p.jsx)("dd",{className:y.caseWorkerEmailVal,id:"emailvalue",children:(0,p.jsx)("span",{"data-hj-suppress":"true",className:"".concat(y.titleVal," ").concat(y.caseWorkerEmail),children:null!==E&&void 0!==E&&null!==(n=E.caseWorker)&&void 0!==n&&n.email&&"NA"!=(null===E||void 0===E||null===(s=E.caseWorker)||void 0===s?void 0:s.email)?null===E||void 0===E||null===(r=E.caseWorker)||void 0===r?void 0:r.email:null===D||void 0===D?void 0:D.email})})]}),(0,p.jsxs)("dl",{className:y.caseWorkerPhoneContainer,id:"phoneid",children:[(0,p.jsx)("dt",{className:y.contactList,id:"contactListid",children:(0,p.jsx)("span",{className:y.keyTitle2,children:null===A||void 0===A?void 0:A.phone})}),(0,p.jsxs)("dd",{className:y.contactPhoneVal,id:"contactid",children:[(0,p.jsx)("span",{"data-hj-suppress":"true",className:"".concat(y.titleVal," ").concat(y.caseWorkerPhone),children:null!==E&&void 0!==E&&null!==(m=E.caseWorker)&&void 0!==m&&m.phone&&"NA"!=(null===E||void 0===E||null===(u=E.caseWorker)||void 0===u?void 0:u.phone)?null===E||void 0===E||null===(g=E.caseWorker)||void 0===g?void 0:g.phone:null===D||void 0===D?void 0:D.mobile}),(0,p.jsx)("img",{src:St,alt:"",className:y.callIcon})]})]})]})})]})})})};var Nt=i(9650),Tt=i(3336),Et=i(1806),zt=i(4882),Mt=i(8076),Lt=i(2420),Ot=i(3460);const Pt=["children","open","onClose"],Wt=new h.A,Ht=(new c.A,{ticketnumber:"",_fos_caseworker_value:"",_owninguser_value:"",fullname:"",title:"",firstname:"",lastname:"",address1_telephone1:"",internalemailaddress:""}),Vt=(0,m.A)({dialogTitle:{margin:"0px",fontSize:"1.75rem",fontFamily:"AssistantSemiBold",color:"#D22D64","@media(max-width:767px)":{fontSize:"1.375rem"}},caseWorkerTitle:{display:"flex",marginBottom:"1rem","@media(max-width:767px)":{display:"block"}},titleBox:{display:"grid",marginRight:"2rem","@media(max-width:767px)":{marginRight:"0",marginBottom:"1rem",width:"100%"}},keyTitle:{color:"#4B4B4B",fontSize:"1.25rem",fontFamily:"AssistantRegular","@media(max-width:767px)":{fontSize:"1.25rem"}},titleVal:{fontSize:"1.25rem",fontWeight:"600",color:"#404040"},caseRefContainer:{fontFamily:"AssistantSemiBold",padding:"0 1.25rem","@media(max-width:767px)":{padding:"0"}},paper:{width:"100%",maxWidth:"736px",height:"auto",minWidth:"auto",margin:"1rem auto"},toolIconDesktop3:{color:"#D22D65",marginLeft:"6px",marginBottom:"-6.3px",width:"22px",height:"22px","@media(max-width:767px)":{display:"inlineBlock"}},customTooltip:{backgroundColor:"#E4EEF8",color:"black",maxWidth:"15.75rem",textAlign:"center",height:"auto",padding:"1.05rem",border:"1px solid #82AFDD",font:"1.15rem AssistantRegular"},customArrow:{color:"#E4EEF8","&::before":{border:"1px solid #82AFDD"}},caseWorkerEmailContainer:{},caseWorkerEmail:{color:"#2273C3",wordBreak:"break-all"},caseWorkerEmailVal:{marginTop:"0.5rem",marginBottom:"1.5rem","@media(max-width:767px)":{marginTop:"0",marginBottom:"1rem"}},caseWorkerPhone:{},caseWorkerInfo:{marginBottom:"0.5rem"},callIcon:{marginLeft:"1rem",fontSize:"1.25rem"},caseWorkerPhoneContainer:{display:"grid"},contactList:{display:"flex",alignItems:"center"},caseRefTicket:{fontSize:"1.25rem"},caseRefTicketVal:{fontSize:"1.5rem",marginLeft:"0",fontFamily:"AssistantSemiBold",marginBottom:"1rem",color:"#000000","@media(max-width:767px)":{fontSize:"1.25rem"}},dialogHeader:{display:"flex",justifyContent:"center",color:"#D22D64"},keyTitleContact:{color:"#404040",fontSize:"1.375rem"},contactPhoneVal:{marginTop:"0.5rem",display:"flex",alignItems:"center",marginBottom:"0.625rem","@media(max-width:767px)":{marginTop:"0"}},savebutton:{float:"right"},buttonDes:{marginTop:"188px",paddingLeft:"1rem","@media(max-width:767px)":{paddingLeft:"0"}},discardBtn:{padding:"0.688rem 1.5rem",color:"#D22D64",borderRadius:"1.5rem",backgroundColor:"#FFFFFF",border:"0.0625rem solid #D22D64",fontSize:"1.25rem",fontFamily:"Assistant",opacity:"1",marginRight:"1.1rem",marginTop:"1rem","&:hover":{backgroundColor:"#FAE5EC",cursor:"pointer"},"@media(max-width:767px)":{fontSize:"1.1rem",width:"90%",marginRight:"0"},"@media (min-device-width: 768px)  and (max-device-width: 1023px)":{marginBottom:"2rem"}},casePrtiesTable:{"@media(max-width:767px)":{width:"100%"}},addNumBtn:{padding:"0.688rem 1.5rem",fontSize:"1.25rem",backgroundColor:"#D22D64",color:"#FFFFFF",border:"1px solid #D22D64",borderRadius:"1.5rem","&:hover":{backgroundColor:"#B8134A",curs
1or:"pointer"},"@media(max-width:767px)":{width:"90%",marginTop:"2.5rem",marginRight:"0rem"}}}),Yt=(0,z.Ay)(M.A)(e=>{let t=e.theme;return{"& .MuiDialogContent-root":{padding:t.spacing(2)},"& .MuiDialogActions-root":{padding:t.spacing(1)}}}),Ut=e=>{const t=e.children,i=(e.open,e.onClose),a=(0,n.A)(e,Pt),r=(0,l.useRef)(null);return(0,p.jsxs)("div",{className:"Info-title",children:[(0,p.jsx)(s.A,(0,o.A)((0,o.A)({sx:{m:0,p:2}},a),{},{children:t})),i?(0,p.jsx)(L.A,{disableRipple:!0,ref:r,tabIndex:0,"aria-label":"close",onClick:i,sx:{position:"absolute",right:8,top:12,color:e=>e.palette.grey[500],"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)",border:"2px solid black"}},children:(0,p.jsx)("img",{src:O.A,alt:""})}):null]})},qt=e=>{var t,i,o,n,s,r,d,c,m,u,g,h,f,b,y;let w=e.open,S=e.handleClose,A=(e.incidentid,e.caseDetailsData);const k=Vt(),D=(0,l.useState)(v[0]),F=(0,a.A)(D,2),R=F[0],B=F[1],_=(0,l.useState)(v[0]),I=(0,a.A)(_,2),N=I[0],T=I[1],E=(0,l.useState)(Ht),z=(0,a.A)(E,2);z[0],z[1];(0,l.useEffect)(()=>{Wt.httpConnection(x.Y.SERVICES.getTrackCaseHeader,"get").then(e=>{e.length>0?B(e[0]):B(v[0])}).catch(()=>{B(v[0])}),Wt.httpConnection(x.Y.SERVICES.getTrackCaseInfo,"get").then(e=>{e.length>0?T(e[0]):T(v[0])}).catch(()=>{T(v[0])})},[]);return["tooltip1","tooltip2","tooltip3","tooltip4"].forEach(e=>{const t=document.getElementById(e);if(t){const e=()=>{null===t||void 0===t||t.setAttribute("aria-expanded","true")},i=()=>{null===t||void 0===t||t.setAttribute("aria-expanded","false")},a=e=>{"Escape"===e.key&&i()};t.onmouseover=e,t.onfocus=e,t.onmouseout=i,t.onblur=i,t.addEventListener("keydown",a)}}),(0,p.jsx)("div",{children:(0,p.jsx)(Yt,{onClose:S,"aria-labelledby":"info-dialog-title-box",role:"dialog",open:w,classes:{paper:k.paper},"data-testid":"CaseWorkerDetailsDialog",id:"dialogboxcaseworker",children:(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(Ut,{id:"title-wrapper",open:w,onClose:S,children:(0,p.jsx)("div",{className:k.dialogHeader,children:(0,p.jsx)("h2",{className:k.dialogTitle,id:"info-dialog-title-box",children:null===R||void 0===R?void 0:R.caseoverview_title})})}),(0,p.jsx)(wt.A,{dividers:!0,children:(0,p.jsxs)("div",{className:k.caseRefContainer,id:"caserefcontainerid",children:[(0,p.jsxs)("dl",{children:[(0,p.jsx)("dt",{className:k.caseRefTicket,id:"caserefticket",children:(0,p.jsx)("span",{className:k.keyTitle,children:null===R||void 0===R?void 0:R.caseReference})}),(0,p.jsx)("dd",{className:k.caseRefTicketVal,id:"caserefvalue",children:(0,p.jsx)("span",{"data-hj-suppress":"true",children:null===A||void 0===A||null===(t=A.casedetails)||void 0===t?void 0:t.ticketnumber})})]}),(0,p.jsxs)("dl",{children:[(0,p.jsxs)("dt",{className:k.caseRefTicket,id:"caseProgress",children:[(0,p.jsx)("span",{"data-hj-suppress":"true",className:k.keyTitle,children:null===R||void 0===R?void 0:R.caseProgress}),(0,p.jsx)(C.A,{id:"tooltip-data1",placement:"top",classes:{tooltip:k.customTooltip,arrow:k.customArrow},title:null===N||void 0===N?void 0:N.caseprogress_tooltip,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{alt:"",role:"button","aria-label":"Additional Info","aria-describedby":"tooltip-data1","aria-expanded":"false",id:"tooltip1",tabIndex:0,src:j.A,className:k.toolIconDesktop3})})]}),(0,p.jsx)("dd",{className:k.caseRefTicketVal,id:"caseaboutTitle",children:(0,p.jsx)("span",{"data-hj-suppress":"true",children:null===A||void 0===A||null===(i=A.casedetails)||void 0===i?void 0:i.fos_caseprogress_name})})]}),(0,p.jsxs)("dl",{children:[(0,p.jsx)("dt",{className:k.caseRefTicket,id:"caseaboutid",children:(0,p.jsx)("span",{"data-hj-suppress":"true",className:k.keyTitle,children:null===R||void 0===R?void 0:R.caseabout})}),(0,p.jsx)("dd",{className:k.caseRefTicketVal,id:"casedata",children:(0,p.jsxs)("span",{"data-hj-suppress":"true",children:[null===A||void 0===A||null===(o=A.casedetails)||void 0===o?void 0:o.fos_complaintissuename," ","for"," ",null===A||void 0===A||null===(n=A.casedetails)||void 0===n?void 0:n.fos_productorproductfamilyname," ","against"," ",null===A||void 0===A||null===(s=A.casedetails)||void 0===s?void 0:s.customeridname,(null===A||void 0===A||null===(r=A.tradingName)||void 0===r?void 0:r.fos_tradingnamename)&&""!==(null===A||void 0===A||null===(d=A.tradingName)||void 0===d?void 0:d.fos_tradingnamename.trim())&&"null"!==(null===A||void 0===A||null===(c=A.tradingName)||void 0===c?void 0:c.fos_tradingnamename.trim().toLowerCase())&&"undefined"!==(null===A||void 0===A||null===(m=A.tradingName)||void 0===m?void 0:m.fos_tradingnamename.trim().toLowerCase())&&(0,p.jsxs)(p.Fragment,{children:[" trading as "," ",null===A||void 0===A||null===(u=A.tradingName)||void 0===u?void 0:u.fos_tradingnamename]})]})})]}),(0,p.jsxs)("dl",{children:[(0,p.jsxs)("dt",{className:k.caseRefTicket,id:"caseSubmitted",children:[(0,p.jsx)("span",{"data-hj-suppress":"true",className:k.keyTitle,children:null===R||void 0===R?void 0:R.caseSubmitted}),(0,p.jsx)(C.A,{id:"tooltip-data2",placement:"top",classes:{tooltip:k.customTooltip,arrow:k.customArrow},title:null===N||void 0===N?void 0:N.caseSubmited_tooltip,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{alt:"",role:"button","aria-label":"Additional Info","aria-describedby":"tooltip-data2","aria-expanded":"false",id:"tooltip2",tabIndex:0,src:j.A,className:k.toolIconDesktop3})})]}),(0,p.jsx)("dd",{className:k.caseRefTicketVal,id:"ticketnumber",children:(0,p.jsx)("span",{"data-hj-suppress":"true",children:null!==A&&void 0!==A&&null!==(g=A.casedetails)&&void 0!==g&&g.fos_dateofreferral?(0,ae.i$)(null===A||void 0===A||null===(h=A.casedetails)||void 0===h?void 0:h.fos_dateofreferral):""})})]}),(0,p.jsxs)("dl",{children:[(0,p.jsxs)("dt",{className:k.caseRefTicket,id:"caseticket",children:[(0,p.jsx)("span",{"data-hj-suppress":"true",className:k.keyTitle,children:null===R||void 0===R?void 0:R.caseAccepted}),(0,p.jsx)(C.A,{id:"tooltip-data3",placement:"top",classes:{tooltip:k.customTooltip,arrow:k.customArrow},title:null===N||void 0===N?void 0:N.caseInvestigation_tooltip,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{alt:"","aria-label":"Additional Info","aria-describedby":"tooltip-data3","aria-expanded":"false",id:"tooltip3",tabIndex:0,role:"button",src:j.A,className:k.toolIconDesktop3})})]}),(0,p.jsx)("dd",{className:k.caseRefTicketVal,id:"idcaserefvalue",children:(0,p.jsx)("span",{"data-hj-suppress":"true",children:null!==A&&void 0!==A&&null!==(f=A.casedetails)&&void 0!==f&&f.fos_dateofconversion?(0,ae.i$)(null===A||void 0===A||null===(b=A.casedetails)||void 0===b?void 0:b.fos_dateofconversion):""})})]}),(0,p.jsxs)("div",{className:k.caseRefTicket,children:[(0,p.jsx)("span",{"data-hj-suppress":"true",className:k.keyTitle,children:null===R||void 0===R?void 0:R.field_casepartiesdetails}),(0,p.jsx)(C.A,{id:"tooltip-data4",placement:"top",classes:{tooltip:k.customTooltip,arrow:k.customArrow},title:null===N||void 0===N?void 0:N.caseParties_tooltip,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{alt:"","aria-label":"Additional Info","aria-describedby":"tooltip-data4","aria-expanded":"false",id:"tooltip4",tabIndex:0,src:j.A,role:"button",className:k.toolIconDesktop3})})]}),(0,p.jsx)("div",{children:(0,p.jsx)(Nt.A,{component:Tt.A,className:k.casePrtiesTable,sx:{border:"1px solid #050505",width:"70%"},children:(0,p.jsxs)(Et.A,{children:[(0,p.jsx)(zt.A,{sx:{fontWeight:"bold",color:"#232323",backgroundColor:"#D3D4D4"},children:(0,p.jsxs)(Mt.A,{children:[(0,p.jsx)(Lt.A,{sx:{fontWeight:"bold",color:"#333",border:"1px solid #050505"},children:null===R||void 0===R?void 0:R.casePartiesTh1}),(0,p.jsx)(Lt.A,{sx:{fontWeight:"bold",color:"#333",border:"1px solid #050505"},children:null===R||void 0===R?void 0:R.casePartiesTh2})]})}),(null===A||void 0===A?void 0:A.caseParties)&&(null===A||void 0===A||null===(y=A.caseParties)||void 0===y?void 0:y.map((e,t)=>(0,p.jsx)(Ot.A,{children:(0,p.jsxs)(Mt.A,{children:[(0,p.jsx)(Lt.A,{sx:{border:"1px solid #050505"},"data-hj-suppress":"true",children:e.partyName}),(0,p.jsx)(Lt.A,{sx:{border:"1px solid #050505"},"data-hj-suppress":"true",children:e.partyRole})]},t)})))]})})})]})})]})})})};var Gt=i(2890),Kt=i(5984),Qt=i(8533),Xt=i(3193),Zt=i(9285),Jt=i(9347);const $t=[{dialog_title:"Want to withdraw your case ?",case_ref_number:"Case reference number :",case_type:"Case type",reason:"Reason for withdrawal",comment_title:"Comments:",comment_placeholder:"Enter comments",submit_btn:"Submit",cancel_bt
1n:"Cancel",addDetails:"Add details:",selectReason:"Select reason",reason_one:"Decide not to progress with the case as need to provide more evidence",reason_two:"Decide not to progress with the case as need to spend lot of time to pursue the case",reason_three:"Accept final resolution offered by the respondent business",reason_others:"Other",withdrawSuccessful:"Withdraw Successful",casedetailsButton:"Go to case details",withdrawDetails:"Your case with case reference number:",withdrawSuccessDetails:"has been successfully withdrawn. You will not be able to take any further action on this case.",max_Char:"Max. characters:",char_len:"5000",add_comment_length:"100",add_more_placeholder:"Add your remarks for other remark you have selected"}],ei=(0,m.A)({titleCancel:{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"center",borderBottom:"1px solid rgb(118, 118, 118, 0.2)",padding:"1.5rem 1.5rem"},astrikColor:{color:"#D22D64",margin:"0 0.25rem"},sronly:{position:"absolute",left:"-9999px"},buttonDisp:{TextAlign:"center",display:"flex",flexDirection:"row-reverse","@media (max-width: 530px)":{width:"100%",display:"block",margin:"0rem 1.5rem 1rem 1.5rem"}},updateButton:{border:"none",borderRadius:"1.5rem",whiteSpace:"nowrap",backgroundColor:"#D22D64",color:"#FFFFFF",padding:"0.6875rem 1.5rem",font:"1.25rem AssistantSemiBold",textTransform:"none",cursor:"pointer",marginLeft:"1rem","&:disabled":{background:"#E07D9E",border:"1px solid #E07D9E",borderRadius:"1.5rem",cursor:"not-allowed",color:"#FFFFFF"},"@media (max-width: 530px)":{display:"block",marginLeft:"0rem",padding:"0.6875rem 0.3rem",marginBottom:"0.625rem"}},cancelBtn:{font:"1.25rem AssistantSemiBold",border:"0.0625rem #D22D64 solid",backgroundColor:"#FFFFFF",color:"#D22D64",padding:"0.6875rem 1.5rem",borderRadius:"1.5rem",textTransform:"none","@media (max-width: 530px)":{width:"100%",display:"block"}},link:{color:"#FFFFFF",whiteSpace:"nowrap",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},linkDisabled:{whiteSpace:"nowrap",letterSpacing:"0px",color:"#767676B3",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},dialogBody:{"@media(max-width: 767px)":{padding:"1rem",overflowY:"auto"}},dialog:{height:"fit-content",background:"var(---ffffff-#FFFFFF) 0% 0% no-repeat padding-box",justifySelf:"flex-end","@media (min-width: 530px)":{position:"absolute",top:"15px",right:"20px"}},dialogBox:{"& .MuiPaper-rounded":{}},title:{textAlign:"center",fontSize:"1.75rem",fontFamily:"AssistantSemiBold !important",letterSpacing:"0rem!important",color:"#D22D64",margin:"0px",overflowWrap:"break-word","@media(max-width: 767px)":{fontSize:"1.375rem !important"}},cancel:{textAlign:"center"},caseCol:{alignItems:"center",flexWrap:"wrap",display:"flex",flexDirection:"row",justifyContent:"flex-start",margin:"0.1rem 0rem",marginBottom:"1.25rem",borderBottom:"1px solid rgb(118, 118, 118, 0.2)","@media (max-width: 767px)":{paddingBottom:"0.5rem",display:"block"}},caseNo:{marginRight:"2rem"},caseColPara:{textAlign:"left",font:"normal normal normal 1.25rem/1.75rem AssistantsemiBold",letterSpacing:"0rem",color:"#767676 !important",width:"fit-content",whiteSpace:"nowrap",margin:"0.1rem 0rem","@media(max-width: 767px)":{fontSize:"1.25rem"}},caseColDetails:{textAlign:"left",fontFamily:"AssistantRegular",fontSize:"1.25rem",letterSpacing:"0rem",color:"#404040",marginBottom:"1.25rem",margin:"0.1rem 0rem",marginLeft:"0rem","@media (max-width: 767px)":{fontSize:"1.25rem"}},issueCase:{},reasonOption:{},commentDiv:{display:"flex",flexDirection:"column",paddingTop:"0.35rem"},commentTitle:{color:"#404040",font:" normal normal 600 1.25rem/1.875rem AssistantSemiBold",textAlign:"left",letterSpacing:"0rem",margin:"0.1rem 0rem","@media (max-width: 767px)":{fontSize:"1.25rem"}},textboxDiv:{width:"100%"},textboxComment:{padding:"0.8125rem 1rem",height:"8rem",width:"95%",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left","@media (max-width: 530px)":{width:"90%"}},maxCharacter:{color:"#767676 !important",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px"},titleMax:{display:"flex",alignItems:"center",justifyContent:"space-between"},reasonsAdd:{},reasons:{display:"flex",flexDirection:"column",paddingBottom:"0.35rem",marginBottom:"0.625rem"},reasonTitle:{textAlign:"left",color:"#404040",font:"normal normal 
1600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",width:"fit-content",whiteSpace:"nowrap",margin:"0.5rem 0rem","@media (max-width: 767px)":{fontSize:"1.25rem"}},reasonSelect:{height:"50px",position:"relative",width:"70%",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"100%"},"@media (max-width: 767px)":{width:"100%"}},footerContainer:{padding:"2rem"},textbox:{height:"3rem",width:"95%",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"90%"}},addOthers:{display:"flex",flexDirection:"column",marginBottom:"1rem"},addDetailsTitle:{textAlign:"left",color:"#404040",whiteSpace:"nowrap",font:"normal normal 600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},optionSelected:{overflowWrap:"break-word",padding:"10px",whiteSpace:"normal"}}),ti=e=>{let t=e.isOpen,i=void 0===t||t,o=e.isClose,n=void 0===o?()=>{}:o;e.ticketNumber,e.caseType,e.incidentid;const s=ii(),r=(0,l.useState)(""),d=(0,a.A)(r,2),c=(d[0],d[1]),m=(0,l.useState)([]),u=((0,a.A)(m,1)[0],(0,l.useState)([])),g=((0,a.A)(u,1)[0],(0,l.useState)($t[0])),f=(0,a.A)(g,2),v=f[0],b=f[1],y=(0,l.useState)(""),w=(0,a.A)(y,2),S=(w[0],w[1]),A=(0,l.useState)(""),C=(0,a.A)(A,2),j=(C[0],C[1]),k=()=>{n(),c(""),S(""),j("")};return(0,l.useEffect)(()=>{(new h.A).httpConnection(x.Y.SERVICES.getWithdrawCaseData,"get").then(e=>{b("<"!==e[0]?e[0]:$t[0])}).catch(e=>{b($t[0])})},[]),(0,p.jsx)("div",{children:(0,p.jsxs)(M.A,{className:s.dialogBox,"aria-label":"Update case information",role:"dialog","aria-live":"polite",open:i,onClose:k,maxWidth:"sm",fullWidth:!0,children:[(0,p.jsx)("div",{className:s.titleCancel,children:(0,p.jsx)("img",{src:te.A,alt:"closeIcon",style:{width:"75px"}})}),(0,p.jsx)(wt.A,{children:(0,p.jsxs)(Qt.A,{children:[(0,p.jsx)("div",{children:(0,p.jsx)("p",{className:s.updateTitle,id:"updateTitle",children:null===v||void 0===v?void 0:v.withdrawSuccessful})}),(0,p.jsx)("div",{className:s.caseCol,id:"casecolumnid",children:(0,p.jsx)("div",{className:s.caseNo,id:"casenumberid",children:(0,p.jsx)("p",{className:s.updateContent,id:"updatecontentid",children:null===v||void 0===v?void 0:v.withdrawSuccessDetails})})})]})}),(0,p.jsx)(Jt.A,{children:(0,p.jsx)("div",{className:s.buttonDisp,id:"closebutton",children:(0,p.jsx)(ne.A,{disableRipple:!0,className:s.updateButton,onClick:k,"aria-label":"closedilaog",id:"got-to_case_details",children:null===v||void 0===v?void 0:v.casedetailsButton})})})]})})},ii=(0,m.A)({titleCancel:{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"center",padding:"1.2rem"},buttonDisp:{margin:"1rem 3rem 2rem 10%",TextAlign:"center",display:"flex",flexDirection:"row-reverse","@media (max-width: 530px)":{width:"100%",display:"block",margin:"0rem 1.5rem 1rem 1.5rem"}},updateTitle:{fontSize:"22px",fontFamily:"AssistantRegular",textAlign:"center",color:" #404040",marginTop:"-18px"},dialog:{background:"var(---ffffff-#FFFFFF) 0% 0% no-repeat padding-box",height:"fit-content",opacity:"1",justifySelf:"flex-end","@media (min-width: 530px)":{position:"absolute",top:"27px",right:"20px"}},updateButton:{border:"none",borderRadius:"1.5rem",width:"17.5rem",textAlign:"center",marginRight:"105px",marginTop:"-27px",marginBottom:"-18px",whiteSpace:"nowrap",backgroundColor:"#D22D64",color:"#FFFFFF",padding:"0.6875rem 1.5rem",height:"3rem",font:"1.25rem AssistantSemiBold",textTransform:"none",disabled:{background:"#F7F7F7 0% 0% no-repeat padding-box",border:"0.063rem solid #767676B3",borderRadius:"1.5rem",opacity:"1",color:"#767676B3"},"&:focus":{backgroundColor:"rgba(184 , 19 , 74 , 1)"},"&:hover":{backgroundColor:"rgba(184 , 19 , 74 , 1)"},"@media (max-width: 530px)":{width:"100%",display:"block",padding:0}},updateContent:{fontFamily:"AssistantRegular",fontSize:"20px",justifyContent:"center",color:" #404040",textAlign:"center",marginTop:"0px"},dialogBox:{"& .MuiPaper-rounded":{}},cancel:{textAlign:"center"},caseCol:{alignItems:"center",flexWrap:"wrap",display:"flex",flexDirection:"row",justifyContent:"flex-start",margin:"0.1rem 0rem",borderBottom:"1px solid rgb(118 , 118 , 118 , 0.2)"},caseNo:{marginRight:"2rem"},textbox:{height:"3rem",width:"27rem",color:"#767676",fontFamily:"Assistant , Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"90%"}}}
1),ai=new h.A,oi=new c.A,ni=e=>{let t=e.isOpen,i=void 0===t||t,o=e.isClose,n=e.ticketNumber,r=e.setDataProps,c=e.caseType,m=e.incidentid;const u=ei(),g=(0,l.useState)(""),h=(0,a.A)(g,2),f=h[0],v=h[1],b=(0,l.useState)([]),y=(0,a.A)(b,2),w=(y[0],y[1]),S=(0,l.useState)($t[0]),A=(0,a.A)(S,2),C=A[0],j=A[1],k=(0,l.useState)(""),D=(0,a.A)(k,2),F=D[0],R=D[1],B=(0,l.useState)(""),_=(0,a.A)(B,2),I=_[0],N=_[1],T=(0,l.useState)(!1),E=(0,a.A)(T,2),z=E[0],P=E[1],V=(0,l.useState)(!1),Y=(0,a.A)(V,2),U=(Y[0],Y[1],(0,l.useState)(!0)),q=(0,a.A)(U,2),G=q[0],K=q[1],Q=(0,l.useState)(!1),X=(0,a.A)(Q,2),Z=(X[0],X[1]),J=(0,l.useState)([]),$=(0,a.A)(J,2),ee=$[0],te=$[1],ie=(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),ae=()=>{Z(window.innerWidth<=1024)};(0,l.useEffect)(()=>(ae(),window.addEventListener("resize",ae),()=>{window.removeEventListener("resize",ae)}),[]);const oe=(0,l.useCallback)(()=>{P(!0)},[]);(0,l.useEffect)(()=>{ai.httpConnection(x.Y.SERVICES.getWithdrawCaseData,"get").then(e=>{j(e[0]);const t=e[0].withdraw_case_reason.map((e,t)=>({key:t,value:e}));te(t)}).catch(e=>{j($t[0])}),oi.httpConnection(ut.c.SERVICES.getSharedConfiguration,"get").then(e=>{var t,i;const a=null===e||void 0===e||null===(t=e.data[0])||void 0===t?void 0:t.reasonForChangeCodes.filter(e=>"Other"!==e.name).sort((e,t)=>e.name.localeCompare(t.name)),o=null===e||void 0===e||null===(i=e.data[0])||void 0===i?void 0:i.reasonForChangeCodes.find(e=>"Other"===e.name);o&&a.push(o),w(a)}).catch(e=>{w([])})},[]);return(0,p.jsx)("div",{children:(0,p.jsxs)(M.A,{className:u.dialogBox,"aria-label":"Withdraw Case",role:"dialog","aria-labelledby":"withdraw-dialog-title",open:i,onClose:o,maxWidth:"sm",fullWidth:!0,children:[(0,p.jsxs)("div",{className:u.titleCancel,children:[(0,p.jsx)("h2",{id:"withdraw-dialog-title",className:u.title,children:null===C||void 0===C?void 0:C.dialog_title}),(0,p.jsx)(s.A,{className:u.dialog,children:(0,p.jsx)(L.A,{id:"iconbutton",disableRipple:!0,"aria-label":"close",onClick:o,sx:{"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)",border:"2px solid black"}},children:(0,p.jsx)("img",{src:O.A,alt:""})})})]}),(0,p.jsx)(wt.A,{className:u.dialogBody,children:(0,p.jsx)(Qt.A,{children:(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{className:u.caseCol,id:"idwithdrawcase",children:[(0,p.jsxs)("dl",{className:u.caseNo,id:"idcasenumber",children:[(0,p.jsx)("dt",{"data-hj-suppress":"true",className:u.caseColPara,id:"idcasecolumn",children:null===C||void 0===C?void 0:C.case_ref_number}),(0,p.jsx)("dd",{"data-hj-suppress":"true",className:u.caseColDetails,id:"casecolumndetails",children:n})]}),(0,p.jsxs)("dl",{className:u.issueCase,id:"caseissueid",children:[(0,p.jsx)("dt",{className:u.caseColPara,id:"casecolparaid",children:null===C||void 0===C?void 0:C.case_type}),(0,p.jsx)("dd",{className:u.caseColDetails,id:"casetype",children:c})]})]}),(0,p.jsx)("div",{className:u.reasonOption,id:"reasonid",children:(0,p.jsx)("div",{className:u.reasonsAdd,id:"addreasons",children:(0,p.jsx)("div",{className:u.reasons,id:"reasons",children:(0,p.jsxs)("div",{children:[(0,p.jsxs)("div",{children:[(0,p.jsx)("span",{className:u.reasonTitle,id:"reasonTitleid",children:null===C||void 0===C?void 0:C.reason}),(0,p.jsx)("span",{className:u.astrikColor,children:"*"})]}),(0,p.jsx)(Xt.A,{fullWidth:!0,id:"options",children:(0,p.jsxs)(Zt.A,{labelId:"withdrawReasons-${index}","aria-labelledby":"reasons",id:"withdrawReasons-${index}",className:u.reasonSelect,value:f,"aria-required":"true",fullWidth:!0,onChange:e=>{const t=e.target.value,i=e.target.value;v(t),R(i)},displayEmpty:!0,MenuProps:{disablePortal:!0,PaperProps:{style:{maxWidth:"29%",overflowX:"hidden",height:"200px",maxHeight:"100%",marginLeft:"2.8px",fontFamily:"Assistant, Regular"}}},children:[" ",(0,p.jsxs)(Kt.A,{value:"",disabled:!0,children:[" ",null===C||void 0===C?void 0:C.selectReason]}),null===ee||void 0===ee?void 0:ee.map(e=>(0,p.jsx)(Kt.A,{tabIndex:0,sx:{whiteSpace:"normal"},id:"reasons_withdraw_".concat(null===e||void 0===e?void 0:e.key),className:u.optionSelected,value:null===e||void 0===e?void 0:e.value,children:null===e||void 0===e?void 0:e.value},null===e||void 0===e?void 0:e.key))]})})]})})})}
1),(0,p.jsxs)("div",{className:u.commentDiv,id:"commentID",children:[(0,p.jsxs)("div",{className:u.titleMax,id:"titileid",children:[(0,p.jsxs)("div",{children:[(0,p.jsx)("span",{className:u.commentTitle,id:"commentID",children:null===C||void 0===C?void 0:C.comment_title}),(0,p.jsx)("span",{className:u.astrikColor,children:"*"})]}),(0,p.jsxs)("span",{className:u.maxCharacter,id:"maxlength","aria-live":"".concat(F.length%10==0?"polite":"off"),children:[null===C||void 0===C?void 0:C.max_Char," ",(null===C||void 0===C?void 0:C.char_len)-F.length]})]}),(0,p.jsx)("div",{className:u.textboxDiv,id:"texboxid",children:(0,p.jsx)("textarea",{value:F,onChange:e=>{R(e.target.value)},className:u.textboxComment,"aria-required":"true",placeholder:null===C||void 0===C?void 0:C.comment_placeholder,maxLength:null===C||void 0===C?void 0:C.char_len,id:"inputText","aria-label":"comments","data-hj-suppress":"true"})})]})]})})}),(0,p.jsx)(Jt.A,{className:u.footerContainer,children:(0,p.jsxs)("div",{className:u.buttonDisp,id:"buttonSubmit",children:[(0,p.jsx)("button",{disabled:""===f||""===F||!G,className:u.updateButton,onClick:()=>{oe(),K(!1);const e={caseId:m,field_dp_x_comments:F,details:I,reasonForChange:f};oi.httpConnection(d.y.SERVICES.caseUpdate,"post",e).then(e=>{if("OK"!=(null===e||void 0===e?void 0:e.status))throw new Error(e);!0===(null===e||void 0===e?void 0:e.success)?(localStorage.setItem("dataProps-".concat(m),"true"),r(!0)):!1===(null===e||void 0===e?void 0:e.success)&&K(!0)}).catch(e=>{(0,H.H)(e,ie)})},id:"withdraw-submit-button",children:null===C||void 0===C?void 0:C.submit_btn}),(0,p.jsx)(ti,{isOpen:z,isClose:()=>{P(!1),o(),v(""),R(""),N("")},ticketNumber:n,caseType:c,incidentid:m}),(0,p.jsx)("button",{className:u.cancelBtn,onClick:o,id:"withdraw-cancel-button",children:null===C||void 0===C?void 0:C.cancel_btn})]})})]})})},si={pageTitle:"Update case information",caseReference:"Case reference number: ",caseType:"Case type: ",commentsTitle:"Comments: ",textBoxPlaceholder:"Add your comments to specify why would you like to update your case.",reasonUpdate:"Reason for update: ",selectReasons:"Select Reasons",addDetails:"Add details: ",addDetailsPlaceholder:"Add your remarks for 'other' remark you have selected",updateBtn:"Update case",cancelBtn:"Cancel"},li={140000012:"Circumstances update",140000011:"Case details incorrect",140000003:"Case consideration",140000013:"Contact Details Change",140000015:"Update Request",140000010:"Other",140000008:"Accept Outcome",140000009:"Reject Outcome",140000007:"Withdraw Case"},ri=e=>{let t=e.isOpen,i=void 0===t||t,o=e.isClose,n=void 0===o?()=>{}:o;const r=di(),d=(0,l.useState)(" "),c=(0,a.A)(d,2),m=(c[0],c[1]),u=(0,l.useState)(li),g=(0,a.A)(u,2),h=(g[0],g[1],(0,l.useState)([])),x=((0,a.A)(h,1)[0],(0,l.useState)([])),f=((0,a.A)(x,1)[0],(0,l.useState)(si)),v=(0,a.A)(f,2),b=v[0],y=(v[1],(0,l.useState)("")),w=(0,a.A)(y,2),S=(w[0],w[1]),A=(0,l.useState)(" "),C=(0,a.A)(A,2),j=(C[0],C[1]),k=()=>{n(),m(""),S(""),j("")};return(0,p.jsx)("div",{id:"updateCaseInformation",children:(0,p.jsxs)(M.A,{className:r.dialogBox,"aria-label":"Update case information.",role:"dialog","aria-live":"polite",open:i,onClose:k,maxWidth:"sm",fullWidth:!0,children:[(0,p.jsxs)("div",{className:r.titleCancel,id:"idClose",children:[(0,p.jsx)("h2",{className:r.title,children:null===b||void 0===b?void 0:b.pageTitle}),(0,p.jsxs)(s.A,{className:r.dialog,children:[(0,p.jsx)(L.A,{disableRipple:!0,"aria-label":"close",onClick:k,sx:{"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)"}},children:(0,p.jsx)("img",{src:O.A,alt:"closeIcon"})})," "]})]}),(0,p.jsx)(wt.A,{children:(0,p.jsxs)(Qt.A,{children:[(0,p.jsx)("div",{id:"idupdateTitle",children:(0,p.jsx)("p",{className:r.updateTitle,id:"pidupdateTitle",children:"Update request submitted"})}),(0,p.jsx)("div",{className:r.caseCol,id:"investigatorid",children:(0,p.jsx)("div",{className:r.caseNo,id:"idupdateContent",children:(0,p.jsx)("p",{className:r.updateContent,children:"Your message has been sent to the case investigator who will review the case and action as needed A copy will be made available in the case Documents section."})})})]})}),(0,p.jsx)(Jt.A,{children:(0,p.jsx)("div",{className:r.buttonDisp,id:"idnewupdateButton",children:(0,p.jsx)(ne.A,{id:"idupdatbtn",disableRipple:!0,className:r.updateButton,onClick:k,children:"Go to case details."})})})]})})},di=(0,m.A)({titleCancel:{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"center",borderBottom:"1px solid rgb(118, 118, 118,  0.2)",padding:"1.5rem 1.5rem"},buttonDisp:{margin:"1rem 3rem 2rem 10% ",TextAlign:"center",display:"flex",flexDirection:"row-reverse","@media (max-width: 530px)":{width:"100%",display:"block",margin:"0rem 1.5rem 1rem 1.5rem"}},updateButton:{border:"none",borderRadius:"1.5rem",width:"17.5rem",textAlign:"center",marginRight:"100px",marginTop:"-27px",marginBottom:"-18px",whiteSpace:"nowrap",backgroundColor:"#D22D64",padding:"0.6875rem 1.5rem",color:"#FFFFFF",font:"1.25rem AssistantSemiBold",height:"3rem",disabled:{background:"#F7F7F7 0% 0% 
1no-repeat padding-box",border:"0.063rem solid #767676B3",borderRadius:"1.5rem",opacity:"1",color:"#767676B3"},textTransform:"none","&:focus":{backgroundColor:"rgba(184, 19, 74, 1)"},"&:hover":{backgroundColor:"rgba(184, 19, 74, 1)"},"@media (max-width: 530px)":{width:"100%",display:"block",padding:0}},cancelBtn:{font:"1.25rem AssistantSemiBold",padding:"0.6875rem 1.5rem",border:"0.0625rem #D22D64 solid",backgroundColor:"#FFFFFF",color:"#D22D64",textTransform:"none",height:"3rem",borderRadius:"1.5rem",width:"6.5rem","&:focus":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"&:hover":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"@media (max-width: 530px)":{width:"100%",display:"block"}},link:{color:"#FFFFFF",whiteSpace:"nowrap",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},linkDisabled:{whiteSpace:"nowrap",letterSpacing:"0px",color:"#767676B3",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},updateTitle:{fontSize:"22px",fontFamily:"AssistantRegular",textAlign:"center",color:" #404040",marginTop:"0.5px"},updateContent:{fontFamily:"AssistantRegular",fontSize:"20px",justifyContent:"center",color:" #404040",textAlign:"center",marginTop:"0px"},dialog:{height:"fit-content",background:"var(---ffffff-#FFFFFF) 0% 0% no-repeat padding-box",opacity:"1",justifySelf:"flex-end","@media (min-width: 530px)":{position:"absolute",top:"27px",right:"20px"}},title:{textAlign:"center",font:"normal normal 600 1.75rem AssistantSemiBold!important",letterSpacing:"0rem!important",color:"#D22D64",opacity:"1",margin:"0px",overflowWrap:"break-word"},cancel:{textAlign:"center"},caseCol:{alignItems:"center",flexWrap:"wrap",display:"flex",flexDirection:"row",justifyContent:"flex-start",margin:"0.1rem 0rem",borderBottom:"1px solid rgb(118, 118, 118, 0.2)"},caseNo:{marginRight:"2.1rem"},caseColPara:{textAlign:"left",font:"normal normal normal 1.25rem/1.75rem AssistantsemiBold",letterSpacing:"0rem",color:"#404040",opacity:"0.6",width:"fit-content",whiteSpace:"nowrap",margin:"0.1rem 0rem"},caseColDetails:{textAlign:"left",font:"normal normal 600 1.5rem/2.1875rem AssistantRegular",letterSpacing:"0rem",color:"#404040",opacity:"1",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},commentDiv:{display:"flex",flexDirection:"column",paddingTop:"0.36rem"},commentTitle:{color:"#404040",font:" normal normal 600 1.25rem/1.875rem AssistantSemiBold",textAlign:"left",letterSpacing:"0rem",opacity:"1",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},textboxDiv:{width:"101%"},textboxComment:{padding:"0.8125rem 1rem",height:"8rem",width:"27rem",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left","@media (max-width: 530px)":{width:"91%"}},maxCharacter:{color:"#949494",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px",marginLeft:"10.7rem","@media (max-width: 530px)":{marginLeft:"1.5rem"}},error:{color:"#FF0000",fontFamily:"AssistantRegular",fontSize:"1.26rem",textAlign:"right",letterSpacing:"0px",marginLeft:"10.6rem","@media (max-width: 530px)":{marginLeft:"1.5rem"}},titleMax:{display:"flex",alignItems:"center"},reasons:{display:"flex",flexDirection:"column",paddingBottom:"0.36rem"},reasonTitle:{textAlign:"left",color:"#404040",font:"normal normal 600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",opacity:"1",width:"fit-content",whiteSpace:"nowrap",margin:"0.5rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},reasonSelect:{height:"fit-content",width:"65%",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"100%"}},textbox:{height:"3rem",width:"27rem",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.26rem",letterSpacing:"0rem",textAlign:"left",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"90%"}},addOthers:{display:"flex",flexDirection:"column"},addDetailsTitle:{textAlign:"left",color:"#404040",whiteSpace:"nowrap",o
1pacity:"1",font:"normal normal 600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",margin:"0.1rem 0rem","@media (max-width: 531px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}}}),ci=e=>{let t=e.isOpen,i=void 0===t||t,o=e.isClose,n=void 0===o?()=>{}:o,d=e.ticketNumber,c=e.caseType;e.incidentid;const m=mi(),u=((0,r.Zp)(),(0,l.useState)("")),g=(0,a.A)(u,2),f=g[0],v=g[1],b=(0,l.useState)(li),y=(0,a.A)(b,2),w=y[0],S=y[1],A=(0,l.useState)([]),C=(0,a.A)(A,1)[0],j=(0,l.useState)([]),k=(0,a.A)(j,1)[0],D=(0,l.useState)(si),F=(0,a.A)(D,2),R=F[0],B=F[1],_=(0,l.useState)(""),I=(0,a.A)(_,2),N=I[0],T=I[1],E=(0,l.useState)(""),z=(0,a.A)(E,2),P=z[0],W=z[1],H=(0,l.useState)(!1),V=(0,a.A)(H,2),Y=V[0],U=V[1],q=(0,l.useState)(!1),G=(0,a.A)(q,2),K=(G[0],G[1],5e3),Q=()=>{n(),v(""),T(""),W("")},X=(0,l.useCallback)(()=>{U(!0)},[]);return(0,l.useEffect)(()=>{const e=new h.A;e.httpConnection(x.Y.SERVICES.getUpdateReasons,"get").then(e=>{"<"!==e[0]?S(li):S(e[0]);for(const i of Object.entries(w)){var t=(0,a.A)(i,2);const e=t[0],o=t[1];C.length<Object.keys(w).length&&(k.push(e),C.push("".concat(o)))}}).catch(e=>{S(li)}),e.httpConnection(x.Y.SERVICES.getCompUpdateCase,"get").then(e=>{void 0===e.data||null===e.data||"<"===e[0]?B(si):B(e[0])}).catch(e=>{B(si)})},[]),(0,p.jsx)("div",{children:(0,p.jsxs)(M.A,{className:m.dialogBox,"aria-label":"Update case information",role:"dialog","aria-live":"polite",open:i,onClose:Q,maxWidth:"sm",fullWidth:!0,id:"update-case-dialog",children:[(0,p.jsxs)("div",{className:m.updateCaseDialogtitleCancel,children:[(0,p.jsx)("h2",{className:m.title,id:"update-case-title",children:null===R||void 0===R?void 0:R.pageTitle}),(0,p.jsxs)(s.A,{className:m.dialog,children:[(0,p.jsx)(L.A,{disableRipple:!0,"aria-label":"close",onClick:Q,sx:{"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)"}},id:"close-update-case-dialog",children:(0,p.jsx)("img",{src:O.A,alt:"closeIcon","aria-label":"Close dialog"})})," "]})]}),(0,p.jsx)(wt.A,{children:(0,p.jsxs)(Qt.A,{children:[(0,p.jsxs)("div",{className:m.caseCol,children:[(0,p.jsxs)("div",{className:m.caseNo,children:[(0,p.jsxs)("p",{className:m.caseColPara,id:"case-reference-label",children:[null===R||void 0===R?void 0:R.caseReference," "]}),(0,p.jsx)("p",{className:m.caseColDetails,id:"ticket-number-value",children:d})]}),(0,p.jsxs)("div",{className:m.issueCase,children:[(0,p.jsxs)("p",{className:m.caseColPara,id:"case-type-label",children:[null===R||void 0===R?void 0:R.caseType," "]}),(0,p.jsx)("p",{className:m.caseColDetails,id:"case-type-value",children:c})]})]}),(0,p.jsxs)("div",{className:m.reasons,children:[(0,p.jsxs)("p",{className:m.reasonTitle,id:"reason-update-label",children:[null===R||void 0===R?void 0:R.reasonUpdate," "]}),(0,p.jsx)("select",{"aria-labelledby":"reason-update-label",id:"update-case-reasons",className:m.reasonSelect,value:f,onChange:e=>{v(e.target.value)},children:(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("option",{value:"",disabled:!0,id:"select-reason-default",children:[" ",null===R||void 0===R?void 0:R.selectReasons]}),C.map(e=>(0,p.jsx)("option",{id:"reason-option-".concat(e),value:e,children:e},e))]})})]}),"Other"===f?(0,p.jsx)(p.Fragment,{children:(0,p.jsxs)("div",{className:m.addOthers,children:[(0,p.jsxs)("div",{className:m.updateCaseDialogtitleMax,children:[(0,p.jsxs)("p",{className:m.addDetailsTitle,id:"add-details-label",children:[null===R||void 0===R?void 0:R.addDetails," "]}),(0,p.jsxs)("p",{className:P.length>=100?m.error:m.maxCharacter,"aria-live":"polite",id:"add-details-char-count",children:["Max. characters: ",100-P.length]})]}),(0,p.jsx)("textarea",{value:P,onChange:e=>{W(e.target.value)},placeholder:"Add your remarks for 'other' remark you have selected",className:m.textbox,maxLength:100,"aria-live":"polite",role:"alert",id:"add-details-textarea"})]})}):(0,p.jsx)(p.Fragment,{}),(0,p.jsxs)("div",{className:m.updateviewcaseDialogcommentDiv,children:[(0,p.jsxs)("div",{className:m.updateCaseDialogtitleMax,children:[(0,p.jsx)("p",{className:m.updateCaseDialogcommentTitle,id:"comments-title-label",children:null===R||void 0===R?void 0:R.commentsTitle}),(0,p.jsxs)("p",{className:N.length>=K?m.error:m.maxCharacter,"aria-live":"polite",id:"comment-char-count",children:["Max. characters: ",K-N.length]})]}),(0,p.jsx)("div",{className:m.textboxDiv,children:(0,p.jsx)("textarea",{value:N,onChange:e=>{T(e.target.value)},className:m.textboxComment,placeholder:null===R||void 0===R?void 0:R.textBoxPlaceholder,maxLength:K,"aria-live":"polite",role:"alert",id:"c
1omment-textarea"})})]})]})}),(0,p.jsx)(Jt.A,{children:(0,p.jsxs)("div",{className:m.updateCaseDialogbuttonDisp,children:[(0,p.jsx)(ne.A,{disableRipple:!0,className:m.updateCaseDialogupdateButton,onClick:X,children:null===R||void 0===R?void 0:R.updateBtn}),(0,p.jsx)(ri,{isOpen:Y,isClose:()=>{U(!1),Q()},ticketNumber:"",caseType:""}),"\xa0\xa0\xa0",(0,p.jsx)(ne.A,{disableRipple:!0,className:m.updateCaseDialogcancelBtn,onClick:Q,id:"closeid",children:null===R||void 0===R?void 0:R.cancelBtn})]})})]})})},mi=(0,m.A)({updateCaseDialogtitleCancel:{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"center",borderBottom:"1px solid rgb(118, 118, 118, 0.2)",padding:"1.5rem 1.5rem"},updateCaseDialogbuttonDisp:{margin:"1rem 3rem 2rem 10%",TextAlign:"center",display:"flex",flexDirection:"row-reverse",marginTop:"-0.938rem",marginBottom:"0.938rem","@media (max-width: 530px)":{width:"100%",display:"block",margin:"0rem 1.5rem 1rem 1.5rem"}},updateCaseDialogupdateButton:{border:"none",borderRadius:"1.5rem",width:"10.5rem",whiteSpace:"nowrap",backgroundColor:"#D22D64",color:"#FFFFFF",padding:"0.6875rem 1.5rem",height:"3rem",font:"1.25rem AssistantSemiBold",textTransform:"none",disabled:{background:"#F7F7F7 0% 0% no-repeat padding-box",border:"0.063rem solid #767676B3",borderRadius:"1.5rem",opacity:"1",color:"#767676B3"},"&:focus":{backgroundColor:"rgba(184, 19, 74, 1)"},"&:hover":{backgroundColor:"rgba(184, 19, 74, 1)"},"@media (max-width: 530px)":{width:"100%",display:"block",padding:0}},updateCaseDialogcancelBtn:{font:"1.25rem AssistantSemiBold",border:"0.0625rem #D22D64 solid",backgroundColor:"#FFFFFF",color:"#D22D64",padding:"0.6875rem 1.5rem",height:"3rem",borderRadius:"1.5rem",width:"6.5rem",textTransform:"none","&:focus":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"&:hover":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"@media (max-width: 530px)":{width:"100%",display:"block"}},link:{color:"#FFFFFF",whiteSpace:"nowrap",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},linkDisabled:{whiteSpace:"nowrap",letterSpacing:"0px",color:"#767676B3",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},dialog:{height:"fit-content",background:"var(---ffffff-#FFFFFF) 0% 0% no-repeat padding-box",opacity:"1",justifySelf:"flex-end","@media (min-width: 530px)":{position:"absolute",top:"27px",right:"20px"}},dialogBox:{"& .MuiPaper-rounded":{}},title:{textAlign:"center",font:"normal normal 600 1.75rem AssistantSemiBold!important",letterSpacing:"0rem!important",color:"#D22D64",opacity:"1",margin:"0px",overflowWrap:"break-word"},cancel:{textAlign:"center"},caseCol:{alignItems:"center",flexWrap:"wrap",display:"flex",flexDirection:"row",justifyContent:"flex-start",margin:"0.1rem 0rem",borderBottom:"1px solid rgb(118, 118, 118, 0.2)",paddingBottom:"0.625rem"},caseNo:{marginRight:"2rem"},caseColPara:{textAlign:"left",font:"normal normal normal 1.25rem/1.75rem AssistantsemiBold",letterSpacing:"0rem",color:"#404040",opacity:"0.6",width:"fit-content",whiteSpace:"nowrap",margin:"0.1rem 0rem"},caseColDetails:{textAlign:"left",font:"normal normal 600 1.5rem/2.1875rem AssistantRegular",letterSpacing:"0rem",color:"#404040",opacity:"1",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},issueCase:{},updateviewcaseDialogcommentDiv:{display:"flex",flexDirection:"column",paddingTop:"0.35rem"},updateviewcaseDialogcommentTitle:{color:"#404040",font:" normal normal 600 1.25rem/1.875rem AssistantSemiBold",textAlign:"left",letterSpacing:"0rem",opacity:"1",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},textboxDiv:{width:"100%",marginTop:"-10px"},textboxComment:{padding:"0.8125rem 1rem",height:"10rem",width:"30rem",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left","@media (max-width: 530px)":{width:"90%"}},maxCharacter:{color:"#949494",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px",marginLeft:"14.7rem","@media (max-width: 530px)":{marginLeft:"1.5rem"}},error:{color:"#FF0000",fontFamily:"AssistantRegular",fontSize:"1.25rem",textAlign:"right",letterSpacing:"0px",marginLeft:"10.7rem","@media (max-width: 530px)":{marginLeft:"1.5rem"}},updateCaseDialogtitleMax:{display:"flex",alignItems:"center"},reasons:{display:"flex",flexDirection:"column",paddingBottom:"0.35rem",paddingTop:"0.625rem"},reasonTitle:{textAlign:"left",color:"#404040",font:"normal normal 
1600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",opacity:"1",width:"fit-content",whiteSpace:"nowrap",margin:"0.5rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},reasonSelect:{height:"fit-content",width:"70%",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"100%"}},textbox:{height:"3rem",width:"27rem",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",letterSpacing:"0rem",textAlign:"left",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"90%"}},addOthers:{display:"flex",flexDirection:"column"},addDetailsTitle:{textAlign:"left",color:"#404040",whiteSpace:"nowrap",opacity:"1",font:"normal normal 600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}}});var pi=i(4605),ui=i(4211),gi=i.n(ui),hi=i(3032);const xi=[{dialog_title:"Save and print document ?",submit_btn:"Continue to Save",cancel_btn:"Cancel",addDetails:"You can select one or more sections to be saved  for future reference:",selectAll:"Select all",summarydetails:"Summary Details",caseOutComesDetails:"Case outcomes details",caseDocuments:"Case Documents",conversationMessages:"Messages"}],fi=[{email:"[email protected]",mobile:"0800 023 4567",name:"Financial ombudsman services helpline"}],vi=e=>{let t=e.isOpen,i=void 0===t||t,o=e.isClose,n=e.incidentid;const r=bi(),m=(0,l.useState)(xi[0]),u=(0,a.A)(m,2),g=u[0],f=u[1],b=(0,l.useState)(v),y=(0,a.A)(b,2),A=y[0],C=y[1],j=(0,l.useState)(fi[0]),k=(0,a.A)(j,2),D=k[0],F=k[1],R=new h.A,B=new c.A,_=(0,l.useState)(!1),I=(0,a.A)(_,2),N=(I[0],I[1],(0,l.useState)([])),T=(0,a.A)(N,2),E=(T[0],T[1],(0,l.useState)(!1)),z=(0,a.A)(E,2),P=(z[0],z[1]),W=(0,l.useState)({_getSummary:{},_getCaseOutcome:{},_getCaseDocument:{},_getConMsg:{},config:{},outcomeMessages:[]}),H=(0,a.A)(W,2),V=H[0],Y=H[1],U=(0,l.useState)([]),q=(0,a.A)(U,2),G=q[0],Q=q[1],X=(0,l.useState)(K),Z=(0,a.A)(X,2),J=Z[0],$=Z[1],ee=(0,l.useState)(w),te=(0,a.A)(ee,2),ie=te[0],ae=te[1],oe=(0,l.useState)(S),ne=(0,a.A)(oe,2),se=ne[0],le=ne[1],re=(0,l.useState)([]),de=(0,a.A)(re,2),ce=(de[0],de[1]),me=(0,l.useState)([]),pe=(0,a.A)(me,2),ge=pe[0],he=pe[1];(0,l.useEffect)(()=>{i&&(R.httpConnection(x.Y.SERVICES.getSaveAndPrintDialogData,"get").then(e=>{ce(e),f("<"!==e[0]?e[0]:xi[0]);const t=[(e=e[0]).summarydetails,e.caseoutcomesdetails,e.casedocument,e.conversationMessages];he(t)}).catch(e=>console.error("Error fetching data:",e)),R.httpConnection(x.Y.SERVICES.getDefaultData,"get").then(e=>{e&&F(e[0])}).catch(e=>console.error("Error fetching drupal:",e)))},[i]),(0,l.useEffect)(()=>{V&&(null===G||void 0===G?void 0:G.length)>0&&setTimeout(()=>{Ce(),je(null===V||void 0===V?void 0:V._getSummary,null===V||void 0===V?void 0:V._getCaseOutcome,null===V||void 0===V?void 0:V._getCaseDocument,null===V||void 0===V?void 0:V._getConMsg,null===V||void 0===V?void 0:V.config,null===V||void 0===V?void 0:V.outcomeMessages)},3e3)},[V]);const xe=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"DD/MM/YYYY";return e?Ue()(e).format(t):""},fe=(e,t)=>{e.target.checked?Q(e=>[...e,t]):Q(e=>e.filter(e=>e!=t))},ve=(e,t)=>{var i;const a=null===t||void 0===t||null===(i=t.originatorCodes)||void 0===i?void 0:i.find(t=>t.code===e);return(null===a||void 0===a?void 0:a.name)||""},be=e=>{const t=He.A.sanitize(e);return(new DOMParser).parseFromString(t,"text/html").body.textContent||""},ye=()=>{P(window.innerWidth<=1024)};(0,l.useEffect)(()=>(ye(),window.addEventListener("resize",ye),()=>{window.removeEventListener("resize",ye)}),[]);gi().fonts={Roboto:{normal:"https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.66/fonts/Roboto/Roboto-Regular.ttf",bold:"https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.66/fonts/Roboto/Roboto-Medium.ttf",italics:"https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.66/fonts/Roboto/Roboto-Italic.ttf",bolditalics:"https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.66/fonts/Roboto/Roboto-MediumItalic.ttf"}};const we=(0,l.useState)([]),Se=(0,a.A)(we,2),Ae=(Se[0],Se[1],(e,t)=>{e&&t(e)});(0,l.useEffect)(()=>
1{if(i){const e=new h.A;e.httpConnection(x.Y.SERVICES.getTrackCaseHeader,"get").then(e=>{e[0].caseReference=e[0].caseReference.replace(/:/g,"").trim(),C(e)}).catch(e=>{C(v)}),e.httpConnection(x.Y.SERVICES.getFileDetails,"get").then(e=>{ae(e)}).catch(e=>{ae(w)}),e.httpConnection(x.Y.SERVICES.getMessageingData,"get").then(e=>{le(e)}).catch(e=>{le(S)}),e.httpConnection(x.Y.SERVICES.getProgressHistory,"get").then(e=>{"<"!==e[0]?Ae(e,$):Ae(K,$)}).catch(e=>{$(K)})}},[i]);const Ce=()=>{let e=document.createElement("canvas"),t=e.getContext("2d");var i='<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">\n      <g id="Selected_AddContactInfo" transform="translate(-795 -307)">\n      <g id="Ellipse_287" data-name="Ellipse 287" transform="translate(795 307)" fill="#ffe6ef" stroke="#d22d64" stroke-width="2">\n      <circle cx="32" cy="32" r="32" stroke="none"/>\n      <circle cx="32" cy="32" r="31" fill="none"/>\n      </g>\n      <circle id="Ellipse_320" data-name="Ellipse 320" cx="20" cy="20" r="20" transform="translate(807 319)" fill="#d22d64"/>\n      <g id="Group_15411" data-name="Group 15411" transform="translate(812.899 325)">\n      <path id="Path_632" data-name="Path 632" d="M23.162,13.976V6.49a.719.719,0,0,0-.211-.509l-3.77-3.77A.719.719,0,0,0,18.673,2H4.719A.719.719,0,0,0,4,2.719V25.234a.719.719,0,0,0,.719.719h7.665M8.79,11.581h9.581M8.79,6.79h4.79M8.79,16.371h3.593m8.328,3.521,1.2-1.2a1.343,1.343,0,0,1,1.9,0h0a1.343,1.343,0,0,1,0,1.9l-1.2,1.2m-1.9-1.9-3.582,3.582a1.2,1.2,0,0,0-.335.662L16.5,26l1.865-.291a1.2,1.2,0,0,0,.662-.335L22.61,21.79m-1.9-1.9,1.9,1.9" fill="none" stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"/>\n      <path id="Path_633" data-name="Path 633" d="M16,2V6.072a.719.719,0,0,0,.719.719H20.79" transform="translate(2.371)" fill="none" stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"/>\n      </g>\n      </g>\n      </svg>',a=new Image;a.setAttribute("crossOrigin","anonymous");var o=new Blob([i],{type:"image/svg+xml;charset=utf-8"}),n=URL.createObjectURL(o);a.onerror=function(){console.log(n)},a.onload=function(){null===t||void 0===t||t.drawImage(a,0,0),URL.revokeObjectURL(n)},a.crossOrigin="anonymous",a.src=function(e){return"data:image/svg+xml;base64,"+window.btoa(e)}(i),setTimeout(()=>{let t=e.toDataURL();[].push({image:t,width:264,height:264,alignment:"right",margin:[0,150,0,0]})},2e3)},je=async function(){var e,t,i,a,o,n,s,l,r;let d=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},m=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},p=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},u=arguments.length>4?arguments[4]:void 0,g=arguments.length>5?arguments[5]:void 0;const h=()=>{var e,t,i,a;return"NA"===(null===d||void 0===d||null===(e=d.caseWorkerDtls)||void 0===e?void 0:e.email)&&"NA"===(null===d||void 0===d||null===(t=d.caseWorkerDtls)||void 0===t?void 0:t.fullname)||null==(null===d||void 0===d||null===(i=d.caseWorkerDtls)||void 0===i?void 0:i.email)&&null==(null===d||void 0===d||null===(a=d.caseWorkerDtls)||void 0===a?void 0:a.fullname)},x=(f=["caseReference","caseSubmitted","caseAccepted","investigator_email_address","investigator_name","caseProgress","caseabout"],A.map(e=>{let t={};return f.forEach(i=>{t[i]=e[i]}),t}));var f;const v=Object.values(x[0]);let b={ticketnumber:null===d||void 0===d||null===(e=d.casedetails)||void 0===e?void 0:e.ticketnumber,fos_dateofreferral:xe(null===d||void 0===d||null===(t=d.casedetails)||void 0===t?void 0:t.fos_dateofreferral),fos_datecasefirstmovedtoinvestigation:xe(null===d||void 0===d||null===(i=d.casedetails)||void 0===i?void 0:i.fos_datecasefirstmovedtoinvestigation),email:h()?null===D||void 0===D?void 0:D.email:null===d||void 0===d||null===(a=d.caseWorkerDtls)||void 0===a?void 0:a.email,fullname:h()?null===D||void 0===D?void 0:D.name:null===d||void 0===d||null===(o=d.caseWorkerDtls)||void 0===o?void 0:o.fullname,fos_caseprogress:null===d||void 0===d||null===(n=d.casedetails)||void 0===n?void 0:n.fos_caseprogress_name,fos_caseabout:(y=null===d||void 0===d||null===(s=d.casedetails)||void 0===s?void 0:s.fos_complaintissuename,w=null===d||void 0===d||null===(l=d.casedetails)||void 0===l?void 0:l.fos_productorproductfamilyname,S=null===d||void 0===d||null===(r=d.casedetails)||void 0===r?void 0:r.customeridname,y&&w&&S?y+" for "+w+" against "+S:"")};var y,w,S;const C=Object.values(b),j=(()=>{const e=new Set;return((null===p||void 0===p?void 0:p.messageDetails)||[]).map(e=>({messageOriginator:null===e||void 0===e?void 0:e.messageOriginator,message:null===e||void 0===e?void 0:e.message,createdOn:null===e||void 0===e?void 0:e.createdOn})).filter(t=>{const i="".concat(t.messageOriginator,"|").concat(t.message,"|").concat(t.createdOn);return!e.has(i)&&(e.add(i),!0)}).sort((e,t)=>
1new Date(t.createdOn)-new Date(e.createdOn))})(),k=(()=>{let e=[];const t=c.caseoutcomes;if(!Array.isArray(t))return[];const i=t[0],a={fos_type_txt:(null===i||void 0===i?void 0:i.fos_type_txt)||"",outcomedate:null===i||void 0===i?void 0:i.outcomedate,fos_meritsjurisdictiondismissal_txt:(null===i||void 0===i?void 0:i.fos_meritsjurisdictiondismissal_txt)||"",user_comments:null===i||void 0===i?void 0:i.user_comments};return e.push(a),e})(),F=(()=>{let e=[];const t=c.caseoutcomes;if(!Array.isArray(t))return[];const i=null===t||void 0===t?void 0:t.slice(1);return null===i||void 0===i||i.forEach(t=>{const i={fos_complainantresponse_txt:null===t||void 0===t?void 0:t.fos_complainantresponse_txt,fos_type_txt:(null===t||void 0===t?void 0:t.fos_type_txt)||"",outcomedate:null===t||void 0===t?void 0:t.outcomedate,fos_meritsjurisdictiondismissal_txt:(null===t||void 0===t?void 0:t.fos_meritsjurisdictiondismissal_txt)||"",user_comments:null===t||void 0===t?void 0:t.user_comments};e.push(i)}),e})(),R=(()=>{if(!Array.isArray(null===m||void 0===m?void 0:m.files))return console.warn("files is not an array or is undefined"),[];const e=null===m||void 0===m?void 0:m.files.map(e=>({fileName:null===e||void 0===e?void 0:e.fileName,originator:null===e||void 0===e?void 0:e.originator,documentType:null===e||void 0===e?void 0:e.documentType,createdOn:null===e||void 0===e?void 0:e.createdOn,fileType:null===e||void 0===e?void 0:e.fileType,fileComments:null===e||void 0===e?void 0:e.fileComments}));return console.log(e," variable values printing for case document"),e})(),B=await(_=hi.A,new Promise((e,t)=>{const i=new Image;i.setAttribute("crossOrigin","anonymous"),i.onload=()=>{const t=document.createElement("canvas");t.width=i.width,t.height=i.height,t.getContext("2d").drawImage(i,0,0);const a=t.toDataURL("image/png");e(a)},i.onerror=e=>{t(e)},i.src=_}));var _;const I=(new Date).toLocaleDateString("en-GB");let N={content:(e=>{var t;let i=[];e.forEach(e=>{if(e==ge[0]){var t,a,o,n,s,l,r;const z={content:[{text:I,style:"headerBold",alignment:"right",margin:[10,10,0,0]},{image:B,width:200},{text:null===(t=A[0])||void 0===t?void 0:t.case_summary,style:"headerBold",margin:[0,10,0,10]},{table:{widths:["auto","auto"],layout:"lightHorizontalLines",body:[[{text:null===(a=A[0])||void 0===a?void 0:a.details,style:"headerBold"},{text:null===(o=A[0])||void 0===o?void 0:o.values,style:"tableHeader"}],...v.map((e,t)=>{return[(i=e,(null===i||void 0===i?void 0:i.charAt(0).toUpperCase())+(null===i||void 0===i?void 0:i.slice(1))||""),C[t]||""];var i})]}}],styles:{header:{fontSize:16,bold:!0,margin:[0,10,0,10]},headerBold:{bold:!0,fontSize:20,margin:[0,20,0,0]},tableHeader:{bold:!0,color:"black",fontSize:12}}};let M=null===d||void 0===d||null===(n=d.casedetails)||void 0===n?void 0:n.fos_prioritycodename.toLowerCase();var m;if(null!==M&&""!==M&&"standard"!==M)null===z||void 0===z||null===(m=z.content)||void 0===m||m.forEach(e=>{var t,i,a;null!==e&&void 0!==e&&e.table&&(null===e||void 0===e||null===(t=e.table)||void 0===t||t.body.push(["Priority flag","Priority"===(null===d||void 0===d||null===(i=d.casedetails)||void 0===i?void 0:i.fos_prioritycodename)?null===(a=A[0])||void 0===a?void 0:a.priority_Case:""]))});i.push(...z.content),i.push({text:" ",pageBreak:"after"});const L=[[{text:null===(s=A[0])||void 0===s?void 0:s.casePartiesTh1,style:"tableHeader"},{text:null===(l=A[0])||void 0===l?void 0:l.casePartiesTh2,style:"tableHeader"}]];d.caseParties.length>0?d.caseParties.forEach(e=>{L.push([e.partyName,e.partyRole])}):L.push([{text:"No record found",colSpan:2,alignment:"center"}]);const O={content:[{text:I,style:"headerBold",alignment:"right",margin:[10,10,0,0]},{image:B,width:200},{text:null===(r=A[0])||void 0===r?void 0:r.field_casepartiesdetails,style:"headerBold",margin:[0,10,0,10]},{table:{body:L,headerRows:1,widths:["auto","auto"]}}],styles:{header:{fontSize:16,bold:!0,margin:[0,10,0,10]},headerBold:{fontSize:20,bold:!0,margin:[0,20,0,0]},tableHeader:{bold:!0,fontSize:12,color:"black"}}};i.push(...O.content),i.push({text:" ",pageBreak:"after"})}if(e==ge[1]){var p,h,x,f,b;const P=(e,t)=>{if(t){var i,a,o;const n=null===t||void 0===t?void 0:t.find(t=>t.message_code==e);return(null===n||void 0===n||null===(i=n.message1)||void 0===i?void 0:i.replaceAll("&#039;","'"))||(null===(a=t[0])||void 0===a||null===(o=a.message1)||void 0===o?void 0:o.replaceAll("&#039;","'"))}return""},W=[[{text:null===(p=J[0])||void 0===p?void 0:p.caseoutcome_title,style:"headerBold"},{text:null===(h=J[0])||void 0===h?void 0:h.history_date,style:"tableHeader"},{text:null===(x=J[0])||void 0===x?void 0:x.type_of_assessment,style:"tableHeader"}]];k.length>
10?k.forEach(e=>{W.push([null===e||void 0===e?void 0:e.fos_type_txt,V(null===e||void 0===e?void 0:e.outcomedate),null===e||void 0===e?void 0:e.fos_meritsjurisdictiondismissal_txt]),null!==c&&void 0!==c&&c.messageCode&&W.push([{text:P(null===c||void 0===c?void 0:c.messageCode,g),colSpan:3,alignment:"left"}])}):W.push([{text:"No record found",colSpan:3,alignment:"center"}]);const H={content:[{text:I,style:"headerBold",alignment:"right",margin:[10,10,0,0]},{image:B,width:200},{text:null===(f=J[0])||void 0===f?void 0:f.latest_outcome,style:"headerBold",margin:[0,10,0,10],fontSize:20},{table:{widths:["*","*","*"],body:W},layout:"lightHorizontalLines"}],styles:{header:{fontSize:16,bold:!0,margin:[0,10,0,10]},headerBold:{fontSize:20,bold:!0,margin:[0,20,0,0]},tableHeader:{bold:!0,fontSize:12,color:"black"}}};function V(e){return new Date(e).toLocaleDateString("en-GB")}i.push(...H.content),i.push({text:" "});const Y=[];(null===F||void 0===F?void 0:F.length)>0?F.forEach(e=>{var t,i,a,o;const n=[[{text:null===(t=J[0])||void 0===t?void 0:t.caseoutcome_title,style:"tableHeader",color:"#878484"},{text:null===(i=J[0])||void 0===i?void 0:i.history_date,style:"tableHeader",color:"#878484"},{text:null===(a=J[0])||void 0===a?void 0:a.type_of_assessment,style:"tableHeader",color:"#878484"}]];n.push([e.fos_type_txt||"",V(e.outcomedate)||"",e.fos_meritsjurisdictiondismissal_txt||""]);const s="No Response"===e.fos_complainantresponse_txt.trim()?J[0].history_outcome_title+" not responded.":J[0].history_outcome_title+" "+e.fos_complainantresponse_txt;Y.push({text:s,margin:[0,10,0,10]},{table:{widths:["*","*","*"],body:n},layout:"noBorders"},...e.user_comments?[{text:null===(o=J[0])||void 0===o?void 0:o.additional_details,color:"#878484",margin:[0,15,0,5]},{text:null===e||void 0===e?void 0:e.user_comments}]:[],{canvas:[{type:"line",x1:0,y1:0,x2:520,y2:0,lineWidth:1,lineColor:"#cccccc"}],margin:[0,0,0,20]})}):Y.push({text:"No records",margin:[0,10,0,10]});const U={content:[{text:null===(b=J[0])||void 0===b?void 0:b.history_title,margin:[0,10,0,10],fontSize:20},...Y],styles:{tableHeader:{fontSize:14,bold:!0,alignment:"center",fillColor:"#e0e0e0",color:"#D3D3D3"},subHeader:{fontSize:12,bold:!0,fillColor:"#f5f5f5",color:"#333",alignment:"center"},tableCell:{fontSize:10}}};i.push(...U.content),i.push({text:" ",pageBreak:"after"})}if(e==ge[2]){var y,w,S,D;const q=[[{text:null===(y=ie[0])||void 0===y?void 0:y.file_name,style:"tableHeader"},{text:null===(w=ie[0])||void 0===w?void 0:w.orignator,style:"tableHeader"},{text:null===(S=ie[0])||void 0===S?void 0:S.file_comments,style:"tableHeader"}]];(null===R||void 0===R?void 0:R.length)>0?R.forEach(e=>{q.push([(null===e||void 0===e?void 0:e.fileName)||"",ve(null===e||void 0===e?void 0:e.originator,u)||"",{text:(null===e||void 0===e?void 0:e.fileComments)||""}])}):q.push([{text:"No record found",colSpan:3,alignment:"center"}]);const G={content:[{text:I,style:"headerBold",alignment:"right",margin:[10,10,0,0]},{image:B,width:200},{text:null===(D=A[0])||void 0===D?void 0:D.field_casedocument,styles:{tableHeader:{bold:!0,fontSize:13,color:"black"}},margin:[0,10,0,10]},{table:{headerRows:1,widths:[120,"auto","auto"],body:q}}],styles:{tableHeader:{bold:!0,fontSize:13,color:"black"}}};i.push(...G.content),i.push({text:" ",pageBreak:"after"})}if(e==ge[3]){var _,N,T,E;const K=[[{text:null===(_=se[0])||void 0===_?void 0:_.message_orignator,style:"tableHeader"},{text:null===(N=se[0])||void 0===N?void 0:N.created_on,style:"tableHeader"},{text:null===(T=se[0])||void 0===T?void 0:T.message,style:"tableHeader",noWrap:!1}]];null===j||void 0===j||j.forEach(e=>{K.push([null===e||void 0===e?void 0:e.messageOriginator,xe(null===e||void 0===e?void 0:e.createdOn,"DD/MM/YYYY"),be(null===e||void 0===e?void 0:e.message)])});const Q={content:[{text:I,style:"headerBold",alignment:"right",margin:[10,10,0,0]},{image:B,width:200},{text:null===(E=se[0])||void 0===E?void 0:E.messageing,margin:[0,10,0,10]},{table:{headerRows:1,widths:["auto","auto",300],body:K}}]};i.push(...Q.content)}});var a=(null===i||void 0===i?void 0:i.length)-1;return"after"==(null===(t=i[a])||void 0===t?void 0:t.pageBreak)&&i.pop(),i})(G)};gi().createPdf(N).open()};return(0,p.jsx)("div",{children:(0,p.jsxs)(M.A,{className:r.dialogBox,"aria-label":"Save and Print",role:"dialog","aria-live":"polite","aria-labelledby":"saveprint",open:i,onClose:o,maxWidth:"sm",fullWidth:!0,children:[(0,p.jsxs)("div",{className:r.titleCancel,children:[(0,p.jsx)("h3",{id:"saveprint",className:r.title,children:null===g||void 0===g?void 0:g.printTItle}),(0,p.jsx)("br",{}),(0,p.jsx)(s.A,{className:r.dialog,children:(0,p.jsx)(L.A,{id:"iconbutton",disableRipple:!0,"aria-label":"close",onClick:o,sx:{"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)",border:"1px solid black"}},children:(0,p.jsx)("img",{src:O.A,alt:""})})})]}),(0,p.jsxs)("div",{role:"group","aria-labelledby":"group-title",children:[(0,p.jsx)("p",{id:"group-title",className:r.commentTitle,children:null===g||void 0===g?void 0:g.adddetails}
1),(0,p.jsx)(wt.A,{className:r.dialogBody,children:(0,p.jsxs)(Qt.A,{children:[(0,p.jsx)("div",{children:(0,p.jsx)(pi.A,{sx:{"& .MuiFormControlLabel-label":{font:"normal normal 600 1.25rem/1.75rem Assistant",color:"#D22D64"}},id:"select-all",checked:4==(null===G||void 0===G?void 0:G.length),onChange:(e,t)=>((e,t)=>{Q(t?ge:[])})(0,t),control:(0,p.jsx)(ue.A,{disableRipple:!0,sx:{"&:focus-within":{border:"2px solid black"},color:"#D22D65","&.Mui-checked":{color:"#D22D65"}},inputProps:{"data-testid":"Select all checkbox"},id:"select-all-options"}),label:null===g||void 0===g?void 0:g.selectall})}),(0,p.jsx)("div",{children:(0,p.jsx)(pi.A,{className:r.CheckboxContainer,"data-testid":"chk1-".concat(null===g||void 0===g?void 0:g.summarydetails),id:null===g||void 0===g?void 0:g.summarydetails,checked:G.some(e=>e===(null===g||void 0===g?void 0:g.summarydetails)),control:(0,p.jsx)(ue.A,{disableRipple:!0,sx:{"&:focus-within":{border:"2px solid black"},color:"#D22D65","&.Mui-checked":{color:"#D22D65"}},onClick:e=>{fe(e,null===g||void 0===g?void 0:g.summarydetails)},id:"select-summaryDetails"}),label:null===g||void 0===g?void 0:g.summarydetails})}),(0,p.jsx)("div",{children:(0,p.jsx)(pi.A,{className:r.CheckboxContainer,"data-testid":"chk1-".concat(null===g||void 0===g?void 0:g.caseoutcomesdetails),id:null===g||void 0===g?void 0:g.caseoutcomesdetails,checked:G.some(e=>e===(null===g||void 0===g?void 0:g.caseoutcomesdetails)),control:(0,p.jsx)(ue.A,{disableRipple:!0,sx:{"&:focus-within":{border:"2px solid black"},color:"#D22D65","&.Mui-checked":{color:"#D22D65"}},onClick:e=>{fe(e,null===g||void 0===g?void 0:g.caseoutcomesdetails)},id:"select-caseoutcomeDetails"}),label:null===g||void 0===g?void 0:g.caseoutcomesdetails})}),(0,p.jsx)("div",{children:(0,p.jsx)(pi.A,{className:r.CheckboxContainer,"data-testid":"chk1-".concat(null===g||void 0===g?void 0:g.casedocument),id:null===g||void 0===g?void 0:g.casedocument,checked:G.some(e=>e===(null===g||void 0===g?void 0:g.casedocument)),control:(0,p.jsx)(ue.A,{disableRipple:!0,sx:{"&:focus-within":{border:"2px solid black"},color:"#D22D65","&.Mui-checked":{color:"#D22D65"}},onClick:e=>{fe(e,null===g||void 0===g?void 0:g.casedocument)},id:"select-caseDocument"}),label:null===g||void 0===g?void 0:g.casedocument})}),(0,p.jsx)("div",{children:(0,p.jsx)(pi.A,{className:r.CheckboxContainer,"data-testid":"chk1-".concat(null===g||void 0===g?void 0:g.conversationMessage),id:null===g||void 0===g?void 0:g.conversationMessage,checked:G.some(e=>e===(null===g||void 0===g?void 0:g.conversationMessages)),control:(0,p.jsx)(ue.A,{disableRipple:!0,sx:{"&:focus-within":{border:"2px solid black"},color:"#D22D65","&.Mui-checked":{color:"#D22D65"}},onClick:e=>{fe(e,null===g||void 0===g?void 0:g.conversationMessages)},id:"select-conversationMessages"}),label:null===g||void 0===g?void 0:g.conversationMessages})})]})})]}),(0,p.jsx)(Jt.A,{children:(0,p.jsxs)("div",{className:r.buttonDisp,id:"buttonSubmit",children:[(0,p.jsx)("button",{disabled:!((null===G||void 0===G?void 0:G.length)>0),className:r.updateButton,onClick:()=>(e=>{const t={incidentid:n};let i={_getSummary:{},_getCaseOutcome:{},_getCaseDocument:{},_getConMsg:{},config:{},outcomeMessages:[]};G.forEach(a=>{switch(a){case e[0]:B.httpConnection(d.y.SERVICES.getSummaryDetailsForDownload,"post",t).then(e=>{if(e){let t={};t.casedetails=null===e||void 0===e?void 0:e.casedetails,t.caseParties=null===e||void 0===e?void 0:e.caseParties,t.caseWorkerDtls=null===e||void 0===e?void 0:e.caseWorkerDtls,i._getSummary=t}}).catch(e=>{console.warn(e)});break;case e[1]:R.httpConnection(x.Y.SERVICES.getLatestOutcome,"get").then(e=>{e&&Array.isArray(e)&&(i.outcomeMessages=e)}).catch(e=>{console.warn(e)}),B.httpConnection(d.y.SERVICES.getCaseOutcomeForDownload,"post",t).then(e=>{e&&(i._getCaseOutcome=e)}).catch(e=>{console.warn(e)});break;case e[2]:B.httpConnection(ut.c.SERVICES.getSharedConfiguration,"get").then(e=>{e&&null!==e&&void 0!==e&&e.data&&(i.config=null===e||void 0===e?void 0:e.data[0])}).catch(e=>{console.warn(e)});const a={caseId:n};B.httpConnection(d.y.SERVICES.getCaseDocumentDetailsForDownload,"post",a).then(e=>{var t;(null===e||void 0===e||null===(t=e.files)||void 0===t?void 0:t.length)>0&&(console.log(e," document file actual response after length check of file"),i._getCaseDocument=e)}).catch(e=>{console.warn(e)});break;case e[3]:B.httpConnection(d.y.SERVICES.getConversationMessageDetailsForDownload,"post",t).then(e=>{var t;(null===e||void 0===e||null===(t=e.messageDetails)||void 0===t?void 0:t.length)>0&&(i._getConMsg=e)}).catch(e=>{console.warn(e)})}}),Y(i)})(ge),id:"save-print-submitbutton",children:null===g||void 0===g?void 0:g.continuetosave}),"\xa0\xa0\xa0",(0,p.jsx)("button",{className:r.cancelBtn,onClick:o,id:"save-print-cancelbutton",children:null===g||void 0===g?void 0:g.cancel})]})})]})})},bi=(0,m.A)({titleCancel:{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",borderBottom:"1px solid rgb(118, 118, 118,  0.2)",padding:"1.5rem 1.5rem"},buttonDisp:{margin:"1rem 3rem 2rem 10% ",TextAlign:"center",display:"flex",alignItems:"center",flexDirection:"row-reverse",justifyContent:"flex-end",textAlign:"right","@media (max-width: 548px)":{width:"100%",margin:"0rem 0.5rem 1rem 1.5rem"},"@media (max-width: 456px)":{width:"100%",display:"flex",margin:"0rem 0.5rem 1rem 1.5rem",flexDirection:"column",alignItems:"flex-end"}},updateButton:{border:"none",font:"1.25rem AssistantSemiBold",borderRadius:"1.5rem",width:"17.5rem",textAlign:"center",marginTop:"-27px",marginBottom:"-18px",whiteSpace:"nowrap",backgroundColor:"#D22D64",color:"#FFFFFF",padding:"0.6875rem 1.5rem",height:"3rem",textTransform:"none",cursor:"pointer","&:disabled":{border:"0.063rem solid #767676B3",borderRadius:"1.5rem",opacity:"1",cursor:"not-allowed",backgroundColor:"#e0e0e0",color:"#7e7e7e"},"&:focus":{backgroundColor:"rgba(184, 19, 74, 1)"},"&:hover":{backgroundColor:"rgba(184, 19, 74, 1)",cursor:"pointer"},"@media (max-width: 530px)":{width:"100%",display:"block",padding:0}},cancelBtn:{font:"1.25rem AssistantSemiBold",border:"0.0625rem #D22D64 solid",backgroundColor:"#FFFFFF",color:"#D22D64",padding:"0.6875rem 1.5rem",height:"3rem",borderRadius:"1.5rem",width:"6.5rem",textTransform:"none",marginRight:"5px",marginTop:"-27px",marginBottom:"-18px",whiteSpace:"nowrap","&:focus":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"&:hover":{backgroundColor:"rgba(210, 45, 100, 0.08)"},"@media (max-width: 530px)":{width:"100%",display:"block",marginTop:"0.25rem"}}
1,link:{color:"#FFFFFF",whiteSpace:"nowrap",font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold"},linkDisabled:{font:"normal normal 600 1.25rem/1.625rem AssistantSemiBold",whiteSpace:"nowrap",letterSpacing:"0px",color:"#767676B3"},dialog:{height:"fit-content",background:"var(---ffffff-#FFFFFF) 0% 0% no-repeat padding-box",opacity:"1",justifySelf:"flex-end","@media (min-width: 530px)":{position:"absolute",top:"27px",right:"20px"}},dialogBody:{overflowY:"hidden",display:"inline-table"},title:{textAlign:"center",font:"normal normal 600 1.75rem AssistantSemiBold!important",letterSpacing:"0rem!important",color:"#D22D64",opacity:"1",margin:"0px",overflowWrap:"break-word"},cancel:{textAlign:"center"},commentTitle:{color:"#404040",font:" normal normal 600 1.25rem/1.875rem AssistantSemiBold",textAlign:"left",letterSpacing:"0rem",opacity:"1",padding:"0.625rem",margin:"0.1rem 0rem","@media (max-width: 530px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}},error:{color:"#FF0000",fontFamily:"AssistantRegular",fontSize:"1.26rem",textAlign:"right",letterSpacing:"0px",marginLeft:"10.6rem","@media (max-width: 530px)":{marginLeft:"1.5rem"}},titleMax:{display:"flex",alignItems:"center"},reasons:{display:"flex",flexDirection:"column",paddingBottom:"0.36rem"},reasonSelect:{width:"65%",height:"fit-content",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.25rem",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"100%"}},textbox:{height:"3rem",width:"27rem",color:"#767676",fontFamily:"Assistant, Regular",fontSize:"1.26rem",letterSpacing:"0rem",textAlign:"left",padding:"0.8125rem 1rem","@media (max-width: 530px)":{width:"90%"}},addOthers:{display:"flex",flexDirection:"column"},addDetailsTitle:{textAlign:"left",whiteSpace:"nowrap",opacity:"1",font:"normal normal 600 1.25rem/1.875rem AssistantSemiBold",letterSpacing:"0rem",margin:"0.1rem 0rem",color:"#404040","@media (max-width: 531px)":{font:"normal normal 600 1.375rem/1.8125rem AssistantRegular"}}});const yi=i.p+"static/media/DropDown.7699bbebe37840a5732787a62f00a9dd.svg",wi=[{moreActions:"More actions",viewCompletecaseDetails:"Case overview",investigatorDetails:"Investigator details",withdrawCase:"Withdraw Case",saveandprint:"Save and print",trackUpload:"Track Upload"}],Si=e=>{let t=e.incidentId,i=e.phnNumber,o=e.complaintIssue,n=e.apiDataCaseDetails,s=e.withDrawCaseDialog,d=e.setWithDrawCaseDialog;const c=f(),m=(0,l.useState)(null),u=(0,a.A)(m,2),g=u[0],v=u[1],b=Boolean(g),y=(0,r.Zp)(),w=(0,l.useState)(!1),S=(0,a.A)(w,2),A=(S[0],S[1],(0,l.useState)(!1)),C=(0,a.A)(A,2),j=C[0],k=C[1],D=(0,l.useState)(!1),F=(0,a.A)(D,2),R=F[0],B=F[1],_=(0,l.useState)(!1),I=(0,a.A)(_,2),N=I[0],T=I[1],E=(0,l.useState)(!1),z=(0,a.A)(E,2),M=z[0],L=z[1],O=(0,l.useState)(!1),P=(0,a.A)(O,2),W=P[0],H=P[1],V=(0,l.useState)(!1),Y=(0,a.A)(V,2),U=Y[0],q=Y[1],G=(0,l.useState)(!1),K=(0,a.A)(G,2),Q=K[0],X=K[1],Z=(0,l.useState)(!1),J=(0,a.A)(Z,2),$=J[0],ee=J[1],te=(0,l.useState)(wi[0]),ie=(0,a.A)(te,2),ae=ie[0],oe=ie[1];(0,l.useEffect)(()=>{"Success"===(null===n||void 0===n?void 0:n.caseWithdrawStatus)&&H(!0)},[n]),(0,l.useEffect)(()=>{var e;"0"===(null===n||void 0===n||null===(e=n.casedetails)||void 0===e?void 0:e.statecode)&&L(!0)},[n]),(0,l.useEffect)(()=>{var e;const t=null===n||void 0===n||null===(e=n.casedetails)||void 0===e?void 0:e.incidentid;"true"===localStorage.getItem("dataProps-".concat(t))&&X(!0)},[n]);const ne=(0,l.useCallback)(()=>{d(!1)},[]),se=(0,l.useCallback)(()=>{B(!1)},[]),le=(0,l.useCallback)(()=>{q(!U),d(!0)},[]),re=(0,l.useCallback)(()=>{q(!U),B(!0)},[]),de=((0,l.useCallback)(()=>{k(!0)},[]),(0,l.useCallback)(()=>{q(!U),T(!0)},[])),ce=(0,l.useCallback)(()=>{q(!U),ee(!0)},[]);return(0,l.useEffect)(()=>{(new h.A).httpConnection(x.Y.SERVICES.getMoreActionsOptions,"get").then(e=>{oe("<"!==e[0]?e[0]:wi[0])}).catch(()=>{oe(wi[0])})},[]),(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("div",{children:[(0,p.jsx)("div",{children:(0,p.jsxs)("button",{id:"more-actions-button","aria-expanded":U,onClick:e=>{v(e.currentTarget),q(!U)},className:"".concat(c.menuButton," ").concat(c.menuButtonOutline),children:[null===ae||void 0===ae?void 0:ae.moreActions,
1(0,p.jsx)("span",{children:(0,p.jsx)("img",{alt:"",src:yi,className:c.imgExpand})})]})}),(0,p.jsxs)(Gt.A,{anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},anchorEl:g,open:b,onClose:()=>{v(null),q(!U)},children:[(0,p.jsx)(Kt.A,{id:"View_Completecase-complainant-details",onClick:ce,className:c.threedotMenu,children:null===ae||void 0===ae?void 0:ae.viewCompletecaseDetails}),(0,p.jsx)(Kt.A,{id:"investigator-complainant-details",onClick:de,className:c.threedotMenu,children:null===ae||void 0===ae?void 0:ae.investigatorDetails}),M&&(0,p.jsx)(Kt.A,{id:"Withdraw-complainant-details",disabled:Q||W,onClick:le,className:c.threedotMenu,children:null===ae||void 0===ae?void 0:ae.withdrawCase}),(0,p.jsx)(Kt.A,{id:"Save_print-complainant-details",onClick:re,className:c.threedotMenu,children:null===ae||void 0===ae?void 0:ae.saveandprint}),(0,p.jsx)(Kt.A,{id:"Track_Upload-complainant-details",onClick:()=>{y("/track-uploads",{state:{incidentId:t}})},className:c.threedotMenu,children:null===ae||void 0===ae?void 0:ae.trackUpload})]})]}),s&&(0,p.jsx)(ni,{isOpen:s,incidentid:t,isClose:ne,ticketNumber:i,caseType:o,setDataProps:X}),(0,p.jsx)(ci,{isOpen:j,incidentid:t,isClose:()=>{k(!1)},ticketNumber:"",caseType:""}),(0,p.jsx)(vi,{isOpen:R,isClose:se,incidentid:t,ticketNumber:i}),N&&(0,p.jsx)(It,{open:N,incidentid:t,handleClose:()=>{T(!1)}}),$&&(0,p.jsx)(qt,{open:$,incidentid:t,caseDetailsData:n,handleClose:()=>{ee(!1)}})]})},Ai=(new h.A,new c.A,e=>{var t,i,o,n,s,d,c,m,u,g,v,y,w,S;let D=e.apiDataCaseDetails,F=e.incidentId,R=e.CaseDetailsData,B=e.drupalData,_=(e.tooltipIsOpenCases,e.imageClick,e.isCaseOutcomeTab),I=e.handleResetTab,N=e.tabPosition;const T=f(),E=new h.A,z=(0,l.useState)(!1),M=(0,a.A)(z,2),L=M[0],O=M[1],P=(0,l.useState)(!1),H=(0,a.A)(P,2),V=H[0],Y=H[1],U=(0,l.useState)(!1),q=(0,a.A)(U,2),G=(q[0],q[1]),K=(0,l.useState)(!1),Q=(0,a.A)(K,2),X=(Q[0],Q[1],(0,l.useState)(!1)),Z=(0,a.A)(X,2),J=Z[0],$=Z[1],ee=(0,l.useState)(),te=(0,a.A)(ee,2),ie=te[0],ae=te[1],oe=(0,l.useState)({}),ne=(0,a.A)(oe,2),se=(ne[0],ne[1],(0,l.useState)(!1)),le=(0,a.A)(se,2),re=(le[0],le[1]),de=(0,l.useState)(!0),ce=(0,a.A)(de,2),me=(ce[0],ce[1]),pe=(0,l.useState)(!1),ue=(0,a.A)(pe,2),ge=(ue[0],ue[1]),he=(0,l.useState)(!1),xe=(0,a.A)(he,2),fe=(xe[0],xe[1]),ve=(0,l.useState)(!1),be=(0,a.A)(ve,2),ye=(be[0],be[1]),we=(0,l.useState)(!1),Se=(0,a.A)(we,2),Ae=(Se[0],Se[1]),Ce=(0,l.useState)(!1),je=(0,a.A)(Ce,2),ke=(je[0],je[1]),De=(0,l.useState)(),Fe=(0,a.A)(De,2),Re=(Fe[0],Fe[1],(0,r.zy)()),Be=Re.pathname,_e=(Re.state,(0,l.useState)(!1)),Ie=(0,a.A)(_e,2),Ne=Ie[0],Te=Ie[1],Ee=(0,l.useRef)(null);var ze;0!=N&&1!=N&&2!=N||(null===(ze=Ee.current)||void 0===ze||ze.scrollIntoView({behavior:"auto"}));const Me=(0,l.useState)(b),Le=(0,a.A)(Me,2),Pe=(Le[0],Le[1]),We=(0,W.d4)(e=>e.stateRolesAndUser,W.bN),He=We.stateRolesAndUser,Ve=(0,l.useCallback)(()=>{Te(!1)},[]);(0,l.useEffect)(()=>{3==N&&$(!0)},[N]),(0,l.useEffect)(()=>{console.log("data",D)},[D]);(0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN);const Ye=Be.split("/"),Ue=(0,W.d4)(e=>e.featureFlagReducer.featureFlagData),qe=(0,r.Zp)(),Ge=()=>{O(!1)};(0,l.useCallback)(()=>{G(!0)},[]);(0,l.useEffect)(()=>{var e;At.AES.encrypt(F,null===(e=window)||void 0===e?void 0:e.ENCRYPTION_KEY).toString(),Ye[Ye.length-1]},[]);(0,l.useCallback)(()=>{re(!1)},[]);const Ke=(0,l.useCallback)(()=>{var e;const t=null===D||void 0===D||null===(e=D.casedetails)||void 0===e?void 0:e.ticketnumber;t&&F&&qe("/view-cases-upload",{state:{pnx:t,incId:F}})},[D]),Qe=null===(t=document)||void 0===t?void 0:t.getElementById("tooltipTrigger");if(Qe){const e=()=>{null===Qe||void 0===Qe||Qe.setAttribute("aria-expanded","true")},t=()=>{null===Qe||void 0===Qe||Qe.setAttribute("aria-expanded","false")},i=e=>{"Escape"===e.key&&t()};Qe.onmouseover=e,Qe.onfocus=e,Qe.onmouseout=t,Qe.onblur=t,Qe.addEventListener("keydown",i)}(0,l.useEffect)(()=>{if(Xe(),Ze(),Ue.length>0){const e=(0,Oe.A)("enableHelpBlock",He.roles,"",He.userId,Ue);ye(e);const t=(0,Oe.A)("enableNeedHelpButton",He.roles,"",He.userId,Ue);fe(t);const i=(0,Oe.A)("enableCaseLifeCycle",He.roles,"",He.userId,Ue);ke(i)}else me(!0),Ae(!0),ge(!0),fe(!1),ye(!1),ke(!1)},[]);const Xe=()=>{E.httpConnection(x.Y.SERVICES.getHelpText,"get").then(e=>{console.log(e),ae(e)}).catch(e=>{ae(res)})},Ze=()=>{E.httpConnection(x.Y.SERVICES.getCaseStatus,"get").then(e=>{e.length,Pe(b)}).catch(()=>{Pe(b)})};return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsxs)("section",{children:[(0,p.jsxs)("div",{className:T.viewContainer,children:[(0,p.jsxs)("div",{className:T.caseRefContainer,children:[(0,p.jsxs)("dl",{className:T.refVal,children:[(0,p.jsx)("dt",{className:T.refTitle,children:null===(i=B[0])||void 0===i?void 0:i.caseReference}),(0,p.jsx)("dd",{"data-hj-suppress":"true",className:T.refValue,children:null===D||void 0===D||null===(o=D.casedetails)||void 0===o?void 0:o.ticketnumber})]}),(0,p.jsxs)("div",{className:T.caseInvestigatorLinkParent,children:[R.investigator,(0,p.jsx)("button",{id:"upload-complainantdocument",style:{marginRight:"12px"},onClick:()=>(Ge(),void Ke()),className:"".concat(T.menuButton," ").concat(T.menuButtonOutline),"data-testid":"case-investigator",children:null===(n=B[0])||void 0===n?void 0:n.uploadDoc}),(0,p.jsx)("div",{children:(0,p.jsx)(Si,{incidentId:F,phnNumber:null===D||void 0===D||null===(s=D.casedetails)||void 0===s?void 0:s.ticketnumber,complaintIssue:null===D||void 0===D||null===(d=D.casedetails)||void 0===d?void 0:d.fos_complaintissuename,apiDataCaseDetails:D,drupalData:B,withDrawCaseDialog:J,setWithDrawCaseDialog:$})})]})]}),(0,p.jsxs)("div",{className:T.caseRefContainerSecond,children:[(0,p.jsxs)("div",{className:T.textStylingFirst,children:[(0,p.jsxs)("div",{className:T.caseprogressTooltip,children:[(0,p.jsx)("span",{children:null===(c=B[0])||void 0===c?void 0:c.caseProgress}),(0,p.jsx)(C.A,{id:"caseprogress-tooltip",enterTouchDelay:0,leaveTouchDelay:3e3,placement:"top",classes:{tooltip:T.customTooltip,arrow:T.customArrow},title:null===(m=B[0])||void 0===m?void 0:m.tooltipCaseProgress,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{tabIndex:0,alt:"",role:"button","aria-label":"Additional Info","aria-describedby":"
1caseprogress-tooltip","aria-expanded":"false",id:"tooltipTrigger",src:j.A,className:T.toolIconDesktop3})})]}),(0,p.jsx)("div",{className:T.textStyling,children:null===D||void 0===D||null===(u=D.casedetails)||void 0===u?void 0:u.fos_caseprogress_name})]}),(0,p.jsx)(p.Fragment,{children:(0,p.jsx)("div",{className:T.priorityVal,children:"Priority"===(null===D||void 0===D||null===(g=D.casedetails)||void 0===g?void 0:g.fos_prioritycodename)&&(0,p.jsxs)("div",{className:T.priorityTitle,children:[(0,p.jsx)("div",{id:"marked-for-priority-tooltip",children:(0,p.jsx)(C.A,{id:"tooltip data",tabIndex:0,placement:"top",classes:{tooltip:T.customTooltip,arrow:T.customArrow},title:null===(v=B[0])||void 0===v?void 0:v.caseAboutTooltip,arrow:!0,PopperProps:{sx:{"& .MuiTooltip-tooltip":{marginBottom:"7px !important"}}},children:(0,p.jsx)("img",{className:T.toolIconDesktop2,src:j.A,alt:"tooltip",id:null===R||void 0===R?void 0:R.complaintIssue,role:"button"})})}),null===(y=B[0])||void 0===y?void 0:y.markedPriority]})})})]})]}),(0,p.jsx)("div",{children:(0,p.jsx)("div",{ref:Ee,className:T.tabsContainer,children:(0,p.jsx)("div",{className:T.tabs,children:(0,p.jsx)(yt,{currentStatus:R.currentStatus,caseDetailsData:D,incidentId:F,isCaseOutcome:_,pnx:null===D||void 0===D||null===(w=D.casedetails)||void 0===w?void 0:w.ticketnumber,handleResetTab:I,tabPosition:3==N?0:N})})})})]}),(0,p.jsx)("section",{children:(0,p.jsx)("div",{className:T.helpsectionContainer_second,children:null===ie||void 0===ie?void 0:ie.map((e,t)=>{var i,a,o,n,s;return(0,p.jsx)("div",{children:(0,p.jsx)(k.KE,{icon:A.A,title:null===(i=ie[t])||void 0===i?void 0:i.title,description:null===(a=ie[t])||void 0===a?void 0:a.info,cta:null===(o=ie[t])||void 0===o?void 0:o.cta,url:null!==(n=ie[t])&&void 0!==n&&n.url?null===(s=ie[t])||void 0===s?void 0:s.url:""})})})})}),(0,p.jsx)(It,{open:L,incidentid:F,handleClose:Ge}),(0,p.jsx)(vi,{isOpen:Ne,isClose:Ve,incidentid:F,ticketNumber:null===D||void 0===D||null===(S=D.casedetails)||void 0===S?void 0:S.ticketnumber}),V&&(0,p.jsx)(qt,{open:V,incidentid:F,caseDetailsData:D,handleClose:()=>{Y(!1)}})]})}),Ci=(0,m.A)({awaitingContainer:{backgroundColor:"#FDF4F4",border:"1px solid #F2CDD0",marginBottom:"2.5rem",padding:"1.25rem","@media(max-width:767px)":{marginTop:"2rem"}},awaitingDiv:{display:"flex",width:"100%",justifyContent:"space-between","@media(max-width:767px)":{display:"block"}},textDiv:{width:"80%","@media(max-width:767px)":{width:"100%",display:"block"}},awaitingTitle:{fontSize:"2rem",fontFamily:"AssistantSemiBold",color:"#404040",margin:"0 0 1rem 0"},subTitle:{fontSize:"1.25rem",fontFamily:"AssistantRegular",color:"#404040",marginBottom:"0.5rem","@media(max-width:767px)":{display:"block",textAlign:"justify"}},dateStyel:{marginTop:"0.5rem","@media(max-width:767px)":{marginBottom:"1rem"}},dayStyle:{fontSize:"1.25rem",fontFamily:"AssistantSemiBold",color:"#D22D64",marginRight:"0.75rem"},dueDateStyle:{fontSize:"1.25rem",fontFamily:"AssistantSemiBold",color:"#404040"},divBtn:{display:"flex",alignItems:"center",justifyContent:"center","@media(max-width:767px)":{display:"block"}},outcomeBtn:{fontSize:"1.25rem",fontFamily:"AssistantSemiBold",color:"#FFFFFF",borderRadius:"1.5rem",backgroundColor:"#D22D64",padding:"0.688rem 2.125rem",border:"none",cursor:"pointer","@media(max-width:767px)":{width:"100%"}},messageDiv:{"@media(max-width:767px)":{marginBottom:"1rem"}}}),ji=[{title:"Awaiting your action",sub_title:"This case has _outcomename_ outcome and has a _typeofassesment_ available to review. You can respond by Accepting or rejecting the outcome shared by the investigator. To find out, please refer to case outcomes section below.",respond_title:"Respond within",due_date_title:"Due date:",outcome_btn:"Go to outcomes",not_available:"Not available"}];var ki=i(6178),Di=i.n(ki),Fi=i(6798);const Ri=e=>{var t,i,o;let n=e.hanldeSetOutcome,s=e.incidentId;const r=new c.A,m=(0,l.useState)({}),u=(0,a.A)(m,2),g=u[0],f=u[1],v=(0,l.useState)(""),b=(0,a.A)(v,2),y=b[0],w=b[1],S=new h.A,A=(0,l.useState)([]),C=(0,a.A)(A,2),j=C[0],k=C[1],D=(0,l.useState)(!1),F=(0,a.A)(D,2),R=F[0],B=F[1],_=(0,l.useState)(ji),I=(0,a.A)(_,2),N=I[0],T=I[1],E=(0,l.useState)(""),z=(0,a.A)(E,2),M=z[0],L=z[1],O=(0,l.useState)(0),P=(0,a.A)(O,2),W=P[0],H=P[1],V=Ci();(0,l.useEffect)(()=>{S.httpConnection(x.Y.SERVICES.getAwaitingAction,"get").then(e=>{"<"!==e[0]?T(e):T(ji)}).catch(e=>{T(ji)}),S.httpConnection(x.Y.SERVICES.getLatestOutcome,"get").then(e=>{"<"!==e[0]?k(e):k([])}).catch(e=>{k([])});const e={incidentid:s};r.httpConnection("".concat(d.y.SERVICES.getCaseOutcome),"post",e).then(e=>{if("OK"!==e.status)throw new Error(e);
1if(f(e),L(null===e||void 0===e?void 0:e.messageCode),null!==e&&void 0!==e&&e.fosresponsetobereceivedby){const t=null===e||void 0===e?void 0:e.fosresponsetobereceivedby.split(" ")[0];w(Di()(t).format(Fi.o));const i=Di()(t).startOf("day"),a=Di()().startOf("day");H(Math.ceil(i.diff(a,"days",!0)))}}).catch(e=>{f({})})},[]),(0,l.useEffect)(()=>{if(Object.keys(g)&&null!==g&&void 0!==g&&g.fosresponsetobereceivedby){const t=Di()().startOf("day"),i=null===g||void 0===g?void 0:g.fosresponsetobereceivedby.split(" ")[0];if(Di()(i).isSameOrAfter(t)){var e;"false"!==(null===(e=Y(M)[0])||void 0===e?void 0:e.show_accept_reject.toLowerCase())?B(!0):B(!1)}else B(!1)}},[j,g]);const Y=e=>e===e?j&&(null===j||void 0===j?void 0:j.filter(t=>t.message_code===e)):j[0];return R?(0,p.jsx)("div",{className:V.awaitingContainer,children:(0,p.jsxs)("div",{className:V.awaitingDiv,children:[(0,p.jsxs)("div",{className:V.textDiv,children:[(0,p.jsx)("h2",{className:V.awaitingTitle,children:null===(t=N[0])||void 0===t?void 0:t.title}),(()=>{var e,t,i;const a=Y(M);return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)("div",{className:V.messageDiv,children:(0,p.jsx)("span",{"data-hj-suppress":"true",className:V.subTitle,children:null===(e=a[0])||void 0===e?void 0:e.message1.replace("_duedate_",y).replace("&quot;",'"').replace("&quot;",'"').replace("&#039;","'")})}),(null===(t=a[0])||void 0===t?void 0:t.message2)&&(0,p.jsx)("div",{className:V.messageDiv,children:(0,p.jsx)("span",{"data-hj-suppress":"true",className:V.subTitle,children:null===(i=a[0])||void 0===i?void 0:i.message2.replace("_duedate_",y).replace("&quot;",'"').replace("&quot;",'"').replace("&#039;","'")})})]})})(),(0,p.jsx)("div",{className:V.dateStyel,children:(0,p.jsxs)("span",{className:V.dayStyle,children:[null===(i=N[0])||void 0===i?void 0:i.respond_title," ",(e=>{let t="";return t=e>1?e+" days.":e>0?e+" day.":"today.",t})(W)]})})]}),(0,p.jsx)("div",{className:V.divBtn,children:(0,p.jsx)("button",{id:"awaiting-outcome-button",onClick:()=>{n()},className:V.outcomeBtn,children:null===(o=N[0])||void 0===o?void 0:o.outcome_btn})})]})}):(0,p.jsx)("div",{})};var Bi=i(8911),_i=i(7450),Ii=i(5078),Ni=i(2299),Ti=i(5664),Ei=i(5554);const zi=i.p+"static/media/twoDefault.717947887acd0790c148467168eeda77.svg";const Mi=i.p+"static/media/Greentick.4d94b35183ed7e0f3460d708ea4120e4.svg";const Li=i.p+"static/media/twoActive.be9c137c0b5745c993cffe11bd08b84c.svg";const Oi=i.p+"static/media/mobiletwoDefault.8a2f55f6d536f6a354e1ff71f4070d5e.svg";const Pi=i.p+"static/media/mobileGreentick.7dbf2e3ecd10de88065dba96e627031a.svg";const Wi=i.p+"static/media/mobiletwoActive.5f7344ffef8e917f471218a936ea5ad9.svg",Hi=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?Oi:zi,alt:"Step2"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step2 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?Wi:Li,style:{position:"relative",top:"11px"},alt:"Step2 Active"})]})};const Vi=i.p+"static/media/oneDefault.753366fc77978f630fb2bb1cda31a4c3.svg";const Yi=i.p+"static/media/oneActive.e93e2041a1e0cd3067017505fb4d6787.svg";const Ui=i.p+"static/media/mobileoneDefault.faee20153bd3dc4eec9cb92cc1c07275.svg";const qi=i.p+"static/media/mobileoneActive.dd1d2332cff7ef19fd438bcad621ea4b.svg",Gi=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log(i,"isMobile"),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?Ui:Vi,alt:"Step 1"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step 1 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?qi:Yi,style:{position:"relative",top:"11px"},alt:"Step 1 Active"})]})};const Ki=i.p+"static/media/threeDefault.3a0b75e377d2c702f2a05f6665a1eaa8.svg";const Qi=i.p+"static/media/threeActive.6f673c180922beb0bed1300570cc3118.svg";const Xi=i.p+"static/media/mobilethreeDefault.6bbf731fc22f007bc33df0e651b56a11.svg";const Zi=i.p+"static/media/mobilethreeActive.3c8a99af8cf2b6b77f9dd5dd865280f8.svg",Ji=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?Xi:Ki,alt:"Step 3"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step3 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?Zi:Qi,style:{position:"relative",top:"11px"},alt:"Step3 Active"})]})};const $i=i.p+"static/media/fourDefault.a354032f5b4ae885e8eba4c74c30f503.svg";const ea=i.p+"static/media/fourActive.254111c71c72bf2aa7d9095b8b4aab49.svg";const ta=i.p+"static/media/mobilefourDefault.605ad0f1bb2c6d6dbdd93191c8c5415a.svg";const ia=i.p+"static/media/mobilefourActive.87921d5862648682aa8a42c1bd70b9a7.svg",aa=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?ta:$i,alt:"Step4"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step 4 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?ia:ea,style:{position:"relative",top:"11px"},alt:"Step 4 Active"})]})};const oa=i.p+"static/media/sixDefault.8edb3ad5b510cb03f7afffbe4bf83da8.svg";const na=i.p+"static/media/tickicon_enabled.5d38c2abb85615fd60258a4ee5c59474.svg";const sa=i.p+"static/media/sixActive.d0eb4d59b1fa308cfd8db4bb547a4a36.svg";const la=i.p+"static/media/mobilesixDefault.93ef743499e526d2fc93106d482db788.svg";const ra=i.p+"static/media/mobilesixActive.e11bd9d4bd372513fc517df07f76b70b.svg",da=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?la:oa,alt:"Step6"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:na,alt:"Step 6 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?ra:sa,style:{position:"relative",top:"11px"},alt:"Step 6 Active"})]})};const ca=i.p+"static/media/fiveDefault.99ecd177ca28b385dfe5c2ca5a411474.svg";const ma=i.p+"static/media/fiveActive.c2074bde6523cefa21d18650355873d8.svg";const pa=i.p+"static/media/mobilefiveDefault.b821aa578a6ee0133c0a76eedd552df0.svg";const ua=i.p+"static/media/mobilefiveActive.a9b194a094e29935e5e1aca236ca851b.svg",ga=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?pa:ca,alt:"Step 5"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step 5 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?ua:ma,style:{position:"relative",top:"11px"},alt:"Step 5 Active"})]})},ha=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?la:oa,alt:"Step 6"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step 6 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?ra:sa,style:{position:"relative",top:"11px"},alt:"Step 6 Active"})]})},xa=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?ta:$i,alt:"Step 4"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step 4 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?ia:ea,style:{position:"relative",top:"11px"},alt:"Step 4 Active"})]})},fa=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?Xi:Ki,alt:"Step 3"}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:Mi,alt:"Step3 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?Zi:Qi,style:{position:"relative",top:"11px"},alt:"Step 3 Active"})]})};const va=i.p+"static/media/sevenDefault.a42eff0e7e179bba47628a937aa9f07f.svg";const ba=i.p+"static/media/sevenActive.41bd4c60b6524d1a278ae4ba45a83f82.svg";const ya=i.p+"static/media/mobilesevenDefault.253061538560a50c865034e35b43af14.svg";const wa=i.p+"static/media/mobilesevenActive.cc3363bb72db78819c7b1c9faf30bd70.svg",Sa=e=>{const t=e.activeStepStatus,i=e.isMobile;e.step;return console.log("activestep: "+t),(0,p.jsxs)(p.Fragment,{children:["default"===t&&(0,p.jsx)("img",{src:i?ya:va,alt:"Step 7 "}),"enabled"===t&&(0,p.jsx)("img",{src:i?Pi:na,alt:"Step 7 Completed"}),"active"===t&&(0,p.jsx)("img",{src:i?wa:ba,style:{position:"relative",top:"11px"},alt:"Step 7 Active"})]})},Aa=new Map([[1,[0,1,2]],[2,[3]],[3,[5]],[4,[4,6,7]],[5,[8,9,10]],[6,[15,16]],[7,[11]],[8,[12]],[9,[13,14]],[10,[15,16]]]),Ca={1:"FolderIcon",2:"MailIcon",3:"SandtimerIcon",4:"SearchIcon",5:"PageSearchIcon",6:"TickIcon"},ja={7:"FolderIcon",8:"MailIcon",9:"PageTickIcon",10:"ClockIcon",11:"PageSearchIcon",12:"UserTickIcon",13:"TickIcon"},ka=e=>{var t,i,n,r,d,m,u,g,x,f,v,b,y;const w=e.incidentid,S=e.drupalData,A=e.caseDetailsData,C=Da(),j=(new c.A,
1new h.A,(0,l.useState)({previousProgressValue:14e7,currentProgressValue:14e7,furthestProgressValue:14e7})),k=(0,a.A)(j,2),D=k[0],F=k[1],R=(0,l.useState)(new Map),B=(0,a.A)(R,2),_=B[0],I=B[1],N=(0,l.useState)(1),T=(0,a.A)(N,2),E=T[0],M=T[1],L=(0,l.useState)(1),O=(0,a.A)(L,2),P=(O[0],O[1],(0,l.useState)([])),W=(0,a.A)(P,2),H=W[0],V=W[1],Y=(0,l.useState)(0),U=(0,a.A)(Y,2),q=U[0],G=U[1],K=(0,l.useState)(0),Q=(0,a.A)(K,2),X=(Q[0],Q[1],(0,l.useState)(!1)),Z=(0,a.A)(X,2),J=Z[0],$=Z[1];let ee=D||{},te=ee.previousProgressValue,ie=ee.currentProgressValue,ae=ee.furthestProgressValue;const oe=[null===(t=S[0])||void 0===t?void 0:t.settingComplaint,null===(i=S[0])||void 0===i?void 0:i.complaintHearing,null===(n=S[0])||void 0===n?void 0:n.complaintAllocation,null===(r=S[0])||void 0===r?void 0:r.complaintInvestigation,null===(d=S[0])||void 0===d?void 0:d.complaintView,null===(m=S[0])||void 0===m?void 0:m.complaintResolved],ne=[null===(u=S[0])||void 0===u?void 0:u.settingComplaint,null===(g=S[0])||void 0===g?void 0:g.complaintHearing,null===(x=S[0])||void 0===x?void 0:x.investigationComplete,null===(f=S[0])||void 0===f?void 0:f.allocationOmbudsman,null===(v=S[0])||void 0===v?void 0:v.investigationOmbudsman,null===(b=S[0])||void 0===b?void 0:b.investigationDecision,null===(y=S[0])||void 0===y?void 0:y.complaintResolved],se=function(){let e=!1;var t;return t=navigator.userAgent||navigator.vendor||window.opera,(/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4)))&&(e=!0),!1};(0,l.useEffect)(()=>{$(window.innerWidth<1100),window.addEventListener("resize",()=>{$(window.innerWidth<1100)})},[]);const le=e=>{V(e<7?oe:ne)},re=e=>{G(e<7?e-1:e-4)};(0,l.useEffect)(()=>{let e=D;var t;null!==A&&void 0!==A&&A.caseIllustrationDtls&&(t=A?null===A||void 0===A?void 0:A.caseIllustrationDtls:D,te=t.previousStageCode,ie=t.currentStageCode,ae=t.furthestStageCode,e=t,F(e));(()=>{const e=ae%100,t=te%100;for(const n of Aa){var i=(0,a.A)(n,2);const s=i[0];if(i[1].find(t=>t===e)){if((15===e||16===e)&&te%100>10&&6===s)continue;M(s);break}if((17===e||e>17)&&te%100!==null)for(const e of Aa){var o=(0,a.A)(e,2);const i=o[0];if(o[1].find(e=>e===t)){M(i);break}}else M(1)}E<7?Object.keys(Ca).forEach(e=>{const t=parseInt(e);E>t?_.set(t,"enabled"):E===t?_.set(t,"active"):_.set(t,"default")}
1):Object.keys(ja).forEach(e=>{const t=parseInt(e);E>t?_.set(t,"enabled"):E===t?_.set(t,"active"):_.set(t,"default")}),I(_),le(E),re(E)})()},[w,E,te,ie,ae,null===A||void 0===A?void 0:A.caseIllustrationDtls]);const de=(0,z.Ay)(Ti.A)(e=>{let t=e.theme;return{["&.".concat(Ei.A.alternativeLabel)]:{top:25,left:"calc(-32% + 2px)",right:"calc(60% + 4px)","@media (max-width: 500px)":{left:"calc(-32% + 12px)",right:"calc(50% -12px)"}},["&.".concat(Ei.A.active)]:{["& .".concat(Ei.A.line)]:{borderColor:"#008000",marginRight:"1%",padding:"0px",width:"74%",marginLeft:"15%","@media (max-width: 500px)":{width:"35%",marginLeft:"22%"}}},["&.".concat(Ei.A.completed)]:{["& .".concat(Ei.A.line)]:{borderColor:"#008000",width:"70%","@media (max-width: 500px)":{left:"calc(-60% + 40px)",right:"calc(60% + 10px)",width:"45%"}}},["& .".concat(Ei.A.line)]:(0,o.A)({borderColor:"#eaeaf0",borderTopWidth:3,borderRadius:1,width:"72%",marginLeft:"13%","@media(max-width: 500px)":{width:"43%"}},t.applyStyles("dark",{borderColor:t.palette.grey[800]}))}}),ce=(0,z.Ay)("div")(e=>{let t=e.theme;return(0,o.A)({backgroundColor:"#ffffff",zIndex:1,color:"#fff",width:10,height:50,display:"flex",borderRadius:"50%",justifyContent:"center",alignItems:"center"},t.applyStyles("dark",{}))});function me(e){const t=e.active,i=e.completed,a=(e.className,e.tageStatus,e.currentStage),o=(e.currentStageMobile,e.isMobile1);let n={1:(0,p.jsx)(Gi,{isMobile:o,activeStepStatus:_.has(1)?_.get(1):"default"}),2:(0,p.jsx)(Hi,{isMobile:o,activeStepStatus:_.has(2)?_.get(2):"default"}),3:(0,p.jsx)(Ji,{isMobile:o,activeStepStatus:_.has(3)?_.get(3):"default"}),4:(0,p.jsx)(aa,{isMobile:o,activeStepStatus:_.has(4)?_.get(4):"default"}),5:(0,p.jsx)(ga,{isMobile:o,activeStepStatus:_.has(5)?_.get(5):"default"}),6:(0,p.jsx)(da,{isMobile:o,activeStepStatus:_.has(6)?_.get(6):"default"})};return a>=7&&(n={1:(0,p.jsx)(Gi,{isMobile:o,activeStepStatus:"enabled"}),2:(0,p.jsx)(Hi,{isMobile:o,activeStepStatus:"enabled"}),3:(0,p.jsx)(fa,{isMobile:o,activeStepStatus:"enabled"}),4:(0,p.jsx)(xa,{isMobile:o,activeStepStatus:_.has(10)?_.get(7):"default"}),5:(0,p.jsx)(ga,{isMobile:o,activeStepStatus:_.has(11)?_.get(8):"default"}),6:(0,p.jsx)(ha,{isMobile:o,activeStepStatus:_.has(12)?_.get(9):"default"}),7:(0,p.jsx)(Sa,{isMobile:o,activeStepStatus:_.has(13)?_.get(10):"default"})}),(0,p.jsx)(ce,{ownerState:{completed:i,active:t},children:n[String(e.icon)]})}return(0,p.jsx)(s.A,{className:C.mobileBox,children:(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(Bi.A,{spacing:1,className:C.mobileStack,children:(0,p.jsx)(_i.A,{sx:{width:"100%"},alternativeLabel:!0,activeStep:q,connector:(0,p.jsx)(de,{}),children:H.map((e,t)=>(0,p.jsx)(Ii.A,{className:"".concat(C.connectorLine," ").concat(q===t?C.activeMargin:""),style:q===t?{marginRight:"3%",marginLeft:"-0.5%"}:{},children:(0,p.jsx)(Ni.A,{style:q===t?{marginLeft:"25%"}:{},StepIconComponent:e=>(0,p.jsx)(me,(0,o.A)((0,o.A)({},e),{},{stageStatus:_,currentStage:E,isMobile1:se()||J})),className:C.caseprogressLabel,children:!(se()||J)&&(0,p.jsx)("span",{"aria-label":"".concat(e),className:q===t?C.highlightedText:C.normalText,children:se()||J?q===t?e:"":e})})},e))})}),(se()||J)&&(0,p.jsx)("div",{className:0===q||1===q?C.mobileLabelLeft:4===q||5===q||6===q?C.mobileLabelRight:C.mobileLabelCenter,children:(e=>H.find((t,i)=>e===i))(q)})]})})},Da=(0,m.A)({mobileBox:{width:"110%",p:"2rem","@media(max-width: 400px)":{padding:"0rem"}},mobileStack:{width:"90%",paddingTop:"3rem",paddingRight:"2rem","@media(max-width: 1024px)":{width:"95%",paddingTop:"1rem",paddinRight:"0rem"}},activeMargin:{marginRight:"3%","@media(max-width: 400px)":{marginLeft:"1%",width:"100%"}},connectorLine:{paddingRight:"0px","@media(min-width:400px and max-width:500px)":{paddingLeft:"6px",marginRight:"-0.5%"},"@media(max-width: 400px)":{padding:"0rem",paddinRight:"0rem",marginRight:"-2%"}},highlightedText:{fontWeight:"bolder"},normalText:{},mobileLabelCenter:{paddingTop:"1rem",fontSize:"18px",fontFamily:"AssitantRegular, Arial,Roboto, SansSerif !important",textAlign:"center","@media(max-width: 600px)":{paddingLeft:"10%",paddingRight:"18%"}},mobileLabelLeft:{paddingTop:"1rem",fontSize:"18px",fontFamily:"AssitantRegular, Arial,Roboto, SansSerif !important",textAlign:"start","@media(max-width: 600px)":{paddingLeft:"3%",paddingRight:"18%"}},mobileLabelRight:{paddingTop:"1rem",fontSize:"18px",fontFamily:"AssitantSemiBold, Arial,Roboto, SansSerif !important",textAlign:"end",left:"-8.75%",position:"relative","@media(max-width: 600px)":{paddingLeft:"17%",paddingRight:"1%"}},caseprogressLabel:{"& .MuiStepLabel-label":{paddingTop:"3rem",fontSize:"1.25rem",fontFamily:"AssitantSemiBold, Arial,Roboto, SansSerif !important",paddingLeft:"4px",paddingRight:"4px","@media(min-width:500 and max-width: 1000px)":{paddingLeft:"18px",paddingRight:"8px"},"@media(max-width: 400px)":{paddingLeft:"0px",paddingRight:"0px"}}}}),Fa=["children","open","onClose"],Ra=(0,m.A)({dialogTitle:{margin:0,fontSize:"1.75rem",color:"#D22D64",fontFamily:"AssistantSemiBold","@media(max-width:767px)":{fontSize:"1.375rem"}},caseWorkerTitle:{display:"flex",marginBottom:"1rem","@media(max-width:767px)":{display:"block"}},titleBox:{display:"grid",marginRight:"2rem",width:"33.33%","@media(max-width:767px)":{marginRight:"0",marginBottom:"1rem",width:"100%"}},keyTitle:{color:"#40404099",fontSize:"1.25rem",fontFamily:"AssistantRegular","@media(max-width:767px)":{fontSize:"1.25rem"}},titleVal:{fontSize:"1.25rem",fontWeight:"600",color:"#404040"},caseRefContainer:{fontFamily:"AssistantSemiBold",padding:"0 1.25rem","@media(max-width:767px)":{padding:"0"}},paper:{minWidth:"35rem","@media(max-width:767px)":{minWidth:"21rem"}},caseWorkerEmailContainer:{},caseWorkerEmail:{color:"#2273C3",wordBreak:"break-all"},caseWorkerEmailVal:{marginTop:"0.5rem",marginBottom:"1.5rem","@media(max-width:767px)":{marginTop:"0",marginBottom:"1rem"}},caseWorkerPhone:{},caseWorkerInfo:{marginBottom:"0.5rem"},caseWorkerPhoneContainer:{display:"grid"},contactList:{display:"flex",alignItems:"center"},caseRefTicket:{},caseRefTicketVal:{fontSize:"1.5rem",fontFamily:"AssistantSemiBold",paddingBottom:"0.938rem",borderBottom:"0.063rem solid #4040401f",marginBottom:"0.938rem","@media(max-width:767px)":{fontSize:"1.25rem"}},dialogHeader:{display:"flex",justifyContent:"center",color:"#D22D64"},keyTitleContact:{color:"#404040",fontSize:"1.375 rem"},contactPhoneVal:{marginTop:"0.5rem",display:"flex",alignItems:"center",marginBottom:"0.625rem","@media(max-width:767px)":{marginTop:"0"}}}),Ba=(0,z.Ay)(M.A)(e=>{let t=e.theme;return{"& .MuiDialogContent-root":{padding:t.spacing(2)},"& .MuiDialogActions-root":{padding:t.spacing(1)}}}),_a=e=>{const t=e.children,i=e.open,a=e.onClose,r=(0,n.A)(e,Fa),d=(0,l.useRef)(null);return(0,l.useEffect)(()=>{var e;i&&(null===(e=d.current)||void 0===e||e.focus())},[i]),(0,p.jsxs)("div",{className:"Info-title",children:[(0,p.jsx)(s.A,(0,o.A)((0,o.A)({sx:{m:0,p:2}},r),{},{children:t})),a?(0,p.jsx)(L.A,{disableRipple:!0,ref:d,tabIndex:0,"aria-label":"close",onClick:a,sx:{position:"absolute",right:8,top:12,color:e=>e.palette.grey[500],"&:focus":{backgroundColor:"rgb(118, 118, 118,20%)"}},children:(0,p.jsx)("img",{src:O.A,alt:"close-icon"})}):null]})},Ia=[{heading:"What is Lorem Ipsum?",description:"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry&#039;s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.<br />\r\n<br />\r\nLorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry&#039;s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.<br />\r\n<br />\r\nLorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry&#039;s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.<br />\r\n<br />\r\n"}],Na=e=>{let t=e.open,i=e.handleClose;e.incidentId;const o=Ra(),n=(0,l.useState)(),s=(0,a.A)(n,2),r=s[0],d=s[1],c=new h.A;(0,l.useEffect)(()=>{m()},[]);const m=()=>{c.httpConnection(x.Y.SERVICES.getHelpGuidance,"get").then(e=>{d("<"!==e[0]?e[0]:"")}).catch(e=>{d(Ia[0])})};return(0,p.jsx)("div",{children:(0,p.jsx)(Ba,{onClose:i,"aria-labelledby":"info-dialog-title-investigator","aria-live":"polite",role:"dialog",open:t,classes:{paper:o.paper},"data-testid":"CaseWorkerDetailsDialogbox",children:(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(_a,{id:"info-dialog-title-investigator",open:t,onClose:i,children:(0,p.jsx)("div",{className:o.dialogHeader,id:"dialogHeaderID",children:(0,p.jsx)("h2",{className:o.dialogTitle,id:"dialogTitle",children:null===r||void 0===r?void 0:r.heading})})}),(0,p.jsx)(wt.A,{dividers:!0,children:(0,p.jsx)("div",{className:o.caseRefContainer,id:"caserefContainerID",children:(0,p.jsx)("div",{className:o.caseRefTicket,id:"caseRefticketID",children:(0,p.jsx)("span",{className:o.keyTitle,id:"keyTitleid",dangerouslySetInnerHTML:{__html:null!==r&&void 0!==r&&r.description?null===r||void 0===r?void 0:r.description:""}})})})})]})})})};const Ta=i.p+"static/media/info-blue.512c7bf05e28177438224fc8aeadcf4f.svg";var Ea=i(4041);const za={info:{background:"#B4D5E1",borderColor:"#2273C3",titleColor:"#000",icon:Ta},success:{background:"#CAE5B8",borderColor:"#4E8A2E",titleColor:"#4E8A2E"},error:{background:"#FFD6DC",borderColor:"#CE3467",titleColor:"#CE3467"},warning:{background:"#FFE8C7",borderColor:"#E28A00",titleColor:"#E28A00"}},Ma=e=>{let t=e.variant,i=e.title,a=e.message,o=e.onDismiss,n=e.icon;const s=za[t],l=La();return(0,p.jsxs)("div",{className:l.notificationBanner,style:{background:s.background,borderBottom:"4px solid ".concat(s.borderColor)},children:[(0,p.jsxs)("div",{className:l.notificationLeft,children:[(0,p.jsx)("img",{src:n,alt:"".concat(t," icon"),className:l.notificationIcon}),(0,p.jsxs)("div",{className:l.notificationText,children:[(0,p.jsx)("span",{className:l.notificationTitle,style:{color:s.titleColor},children:i}),(0,p.jsx)("span",{className:l.notificationMessage,children:a})]})]}),o&&(0,p.jsx)("button",{type:"button",className:l.notificationDismiss,onClick:o,children:"Dismiss"})]})},La=(0,m.A)({notificationBanner:{padding:"16px",borderRadius:"4px",display:"flex",gap:"32px",alignItems:"flex-start"},notificationLeft:{display:"flex",gap:"8px",flex:"1",alignItems:"flex-start"},notificationIcon:{width:"24px",height:"24px"},notificationText:{gap:"4px",maxHeight:"125px",overflowY:"auto"},notificationTitle:{fontFamily:"AssistantSemiBold",fontSize:"19px",lineHeight:"normal",color:"#000"},notificationMessage:{fontFamily:"AssistantRegular",fontSize:"16px",color:"#404040",lineHeight:"normal",marginLeft:"6px"},notificationDismiss:{padding:"12px 16px",borderRadius:"50px",background:"white",border:"1px solid #CE3467",color:"#CE3467",fontSize:"16px",fontWeight:"700",cursor:"pointer"}}),Oa={ticketnumber:"",fos_casestagename:"",fos_caseworker:"",owninguser:"",email:"",ph
1one:"",fullname:"",fos_startdatetime:"",fos_enddatetime:"",fos_user:"",fos_usermessage:"",statuscode:"",statecode:""},Pa=e=>{const t=(0,l.useState)(null),i=(0,a.A)(t,2),o=(i[0],i[1]),n=(Wa(),(0,l.useState)(!1)),s=(0,a.A)(n,2),r=(s[0],s[1]),m=(0,l.useState)(!1),u=(0,a.A)(m,2),g=u[0],f=u[1],v=(0,l.useState)(Oa),b=(0,a.A)(v,2),y=b[0],w=b[1],S=((0,W.d4)(e=>e.ServerMesagePortal.ServerMesagePortal,W.bN),new c.A),A=new h.A;console.log("props",e);let C={incidentid:e.incidentId};(0,l.useEffect)(()=>{console.log("test payload incident",C),S.httpConnection(d.y.SERVICES.getCaseOwner,"post",C).then(e=>{var t,i,a,o,n;w(e.caseWorker);const s=null===e||void 0===e||null===(t=e.caseWorker)||void 0===t?void 0:t.statuscode,l=null!==e&&void 0!==e&&null!==(i=e.caseWorker)&&void 0!==i&&i.fos_startdatetime?new Date(null===(a=e.caseWorker)||void 0===a?void 0:a.fos_startdatetime):null,d=null!==e&&void 0!==e&&null!==(o=e.caseWorker)&&void 0!==o&&o.fos_enddatetime?new Date(null===(n=e.caseWorker)||void 0===n?void 0:n.fos_enddatetime):null,c=l?new Date(l.getFullYear(),l.getMonth(),l.getDate()):null,m=d?new Date(d.getFullYear(),d.getMonth(),d.getDate()):null,p=new Date,u=new Date(p.getFullYear(),p.getMonth(),p.getDate());"140000001"===s&&c&&m&&u>=c&&m>=u?(f(!0),r(!1)):(f(!1),r(!0))}).catch(e=>{console.warn(e)}),A.httpConnection(x.Y.SERVICES.getMaintenance,"get").then(e=>{e&&(e[0]&&"<"!==e[0]?o(e[0]):o(null))}).catch(e=>{o(Ea[0])})},[null===e||void 0===e?void 0:e.incidentId]);return console.log("props incident id",e.incidentId),g&&(0,p.jsx)(Ma,{variant:"info",title:"".concat(null===y||void 0===y?void 0:y.fullname,":"),message:null===y||void 0===y?void 0:y.fos_usermessage,onDismiss:()=>{f(!1),r(!1),window.scrollTo({top:0,left:0,behavior:"smooth"})},icon:Ta})},Wa=(0,m.A)({mainDiv:{display:"flex"},maintenanceContainer:{display:"flex",justifyContents:"flex-start",backgroundColor:"#DFEAFC",borderBottom:"4px solid #3661E2",padding:"1rem 1.5rem 1rem 1.5rem",alignItems:"flex-start",gap:"1rem",marginTop:"1rem","@media(max-width:767px)":{display:"block"}},container1:{display:"flex",alignItems:"flex-start",maxHeight:"9rem",overflowY:"auto","@media(max-width:767px)":{marginRight:"2rem !Important",display:"block"},"&::-webkit-scrollbar":{height:"0.15rem"},"&::-webkit-scrollbar-track":{backgroundColor:"rgb(255, 255, 255)"},"&::-webkit-scrollbar-thumb":{backgroundColor:"rgb(118, 118, 118,0.4)"}},dismissButton:{"@media(max-width:767px)":{display:"block",marginTop:"2rem !important"}},contentContainer:{width:"72%",marginTop:"0.5%",marginRight:"2.5rem",fontWeight:"unset","& h2":{fontFamily:"AssistantSemiBold",color:"#3661E2",fontSize:"1.5rem",marginBlock:"0",fontWeight:"unset"},"& p":{fontFamily:"AssistantRegular",color:"#404040",marginBlock:"0",marginTop:"0.5625rem",fontSize:"1.25rem"},"& span":{fontFamily:"AssistantRegular",color:"#404040",marginBlock:"0",marginTop:"0.5625rem",fontSize:"1.25rem"}},contentContainerHeading:{fontWeight:"600"},mticon:{marginRight:"1.25rem",marginBottom:"5.4%",paddingTop:"0.45rem","@media(max-width:767px)":{marginBottom:"1rem"}},paddingLeftRight:{fontFamily:"AssistantSemiBold",fontSize:"1.125rem",cursor:"pointer"},isActive:{display:"none"}});var Ha=i(1441);const Va=["children","value","index"],Ya={ticketnumber:"",priorityCase:"",submitedOn:"",acceptedOn:"",product:"",currentStatus:"",investigator:"",complaintIssue:"",_fos_complaintissue_value_txt:"",businessname:"",fos_casestage_txt:"",incidentid:"",statuscode:"",fos_furtheststage_txt:""},Ua=e=>{const t=e.children,i=e.value,a=e.index,l=(0,n.A)(e,Va),r=f();return(0,p.jsx)("div",(0,o.A)((0,o.A)({hidden:i!==a,id:"simple-tabpanel-".concat(a)},l),{},{children:i===a&&(0,p.jsx)(s.A,{className:r.trackCaseTab,children:t})}))},qa=e=>{var t,i,o,n,m,u,b;const w=f(),S=(0,l.useState)(0),A=(0,a.A)(S,2),C=A[0],j=(A[1],new c.A),k=(0,l.useState)(),D=(0,a.A)(k,2),F=D[0],R=D[1],B=(0,l.useState)(y),_=(0,a.A)(B,2),I=_[0],N=_[1],T=new h.A,E=(0,l.useState)(Ya),z=(0,a.A)(E,2),M=z[0],L=(z[1],(0,l.useState)(!1)),O=(0,a.A)(L,2),P=O[0],H=(O[1],(0,l.useState)("")),V=(0,a.A)(H,2),Y=(V[0],V[1]),U=(0,r.zy)().state,q=(0,l.useState)(!0),G=(0,a.A)(q,2),K=G[0],Q=(G[1],(0,l.useRef)(null)),X=(0,l.useState)(!1),Z=(0,a.A)(X,2),J=Z[0],$=Z[1],ee=(0,l.useState)(!1),te=(0,a.A)(ee,2),ie=te[0],ae=te[1],oe=(0,l.useState)(!1),ne=(0,a.A)(oe,2),se=ne[0],le=ne[1],re=(0,l.useState)(!1),de=(0,a.A)(re,2),ce=(de[0],de[1],(0,W.d4)(e=>e.userDetailsReducer.userdata)),me=(0,l.useState)(!1),pe=(0,a.A)(me,2),ue=pe[0],ge=pe[1],he=(0,r.zy)(),xe=(0,l.useState)({}),fe=(0,a.A)(xe,2),ve=fe[0],be=fe[1],ye=(null===he||void 0===he||null===(t=he.state)||void 0===t?void 0:t.incidentId)||"",we=(0,l.useState)(!1),Se=(0,a.A)(we,2),Ae=Se[0],Ce=Se[1],je=e=>e.charAt(0).toUpperCase()+e.slice(1);(0,l.useEffect)(()=>{var e;"/trackcase"===he.pathname&&Q.current&&(null===(e=Q.current)||void 0===e||e.focus())},[Q.current]),(0,l.useEffect)(()=>{null!==ce&&void 0!==ce&&ce.firstname&&null!==ce&&void 0!==ce&&ce.lastname?Y(je(""+(null===ce||void 0===ce?void 0:ce.firstname))+je(" "+(null===ce||void 0===ce?void 0:ce.lastname))):null!==ce&&void 0!==ce&&ce.firstname?Y(je(""+(null===ce||void 0===ce?void 0:ce.firstname))):null!==ce&&void 0!==ce&&ce.lastname?Y(je(""+(null===ce||void 0===ce?void 0:ce.lastname))):Y("User")},[]),(0,l.useEffect)(()=>{e.selected("/trackcase"),document.title="Financial Ombudsman Service - Track case",(!sessionStorage.getItem("incId")||sessionStorage.getItem("incId")!=ye&&""!=ye)&&(sessionStorage.setItem("incId",ye),localStorage.setItem("incId",ye))},[ye]),(0,l.useEffect)(()=>
1{if(window.scrollTo(0,0),ke(),localStorage.getItem("incId")){const e={incidentid:localStorage.getItem("incId")};j.httpConnection("".concat(d.y.SERVICES.getRepresentativeCaseList),"post",e).then(e=>{be(e)}).catch(e=>{console.warn("error for view case",e)})}},[localStorage.getItem("incId")]);const ke=()=>{T.httpConnection(x.Y.SERVICES.getTrackCaseHeader,"get").then(e=>{R(e[0]?e:v)}).catch(e=>{R(v)}),T.httpConnection(x.Y.SERVICES.getCaseIllustration,"get").then(e=>{e.length>0&&"<"!==e[0]?N(e):N(y)}).catch(()=>{N(y)})};return(0,p.jsx)("div",{className:w.docContainer,children:F&&(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)("div",{className:w.userData,children:(0,p.jsx)("div",{children:(0,p.jsx)("h1",{className:w.userWelcome,children:null===(i=F[0])||void 0===i?void 0:i.caseDetails})})}),(0,p.jsx)(Ha.A,{}),(0,p.jsx)("div",{className:w.casesDesc,children:(0,p.jsx)("span",{className:w.casepDesc,children:null===(o=F[0])||void 0===o?void 0:o.pageDescriptions})}),(0,p.jsxs)("div",{className:w.stepperContainer,children:[(0,p.jsx)("h2",{className:w.caseprogresstitle,children:null===(n=F[0])||void 0===n?void 0:n.viewCaseProgress}),(0,p.jsxs)("div",{className:w.caseprogressdesc,children:[null===(m=I[0])||void 0===m?void 0:m.helpandGuidance,(0,p.jsx)("button",{tabIndex:0,className:w.helpLink,onClick:()=>{Ce(!0)},children:null===(u=I[0])||void 0===u?void 0:u.helpandGuideLink})]}),(0,p.jsx)(ka,{caseDetailsData:ve,drupalData:I})]}),(0,p.jsx)(Pa,{incidentId:ye}),(0,p.jsx)("div",{style:{marginTop:"1rem"},children:(0,p.jsx)(Ri,{hanldeSetOutcome:()=>{ge(!0)},incidentId:ye})}),K?!P&&(0,p.jsx)(s.A,{children:(0,p.jsx)(Ua,{"data-testid":"initialState",value:C,index:0,children:(0,p.jsx)("div",{children:(0,p.jsx)(Ai,{apiDataCaseDetails:ve,CaseDetailsData:M,incidentId:localStorage.getItem("incId"),drupalData:F,tooltipIsOpenCases:se,imageClick:e=>{"status"==e?(ae(!ie),$(!1),le(!1)):"issue"==e?($(!J),ae(!1),le(!1)):"cases"==e&&(ae(!1),$(!1),le(!se))},handleResetTab:()=>{ge(!1)},isCaseOutcomeTab:ue,tabPosition:null===U||void 0===U?void 0:U.tabPosition})})},ve.incidentid)}):(0,p.jsx)(g,{}),P&&(0,p.jsx)("div",{className:w.emptyMessageContainer,children:(0,p.jsx)("div",{className:w.emptyMessageDiv,children:(0,p.jsx)("span",{"aria-live":"assertive",role:"alert",className:w.emptyMessageSpan,children:null===(b=F[0])||void 0===b?void 0:b.emptyMessage})})}),(0,p.jsx)(Na,{incidentId:ye,open:Ae,handleClose:()=>{Ce(!1)}})]})})}},3273(e,t,i){"use strict";i.d(t,{A:()=>r});i(5043);var a=i(5151),o=i(1626),n=i(7153),s=i(579);const l=(0,a.A)({errorMessageContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"#FBDEDD",border:"2px solid #CB3A32",padding:"0.5rem 1rem",borderRadius:"0.5rem"},messageText:{display:"flex",alignItems:"center",fontSize:"1.5rem",fontFamily:"AssistantRegular"},messageIcon:{marginRight:"0.75rem"},messageClose:{display:"flex"},closeBtn:{padding:"0",cursor:"pointer",backgroundColor:"transparent",border:"none"}}),r=e=>{let t=e.message,i=e.onClose;const a=l();return(0,s.jsxs)("div",{className:a.errorMessageContainer,children:[(0,s.jsxs)("div",{role:"alert",className:a.messageText,children:[(0,s.jsx)("img",{className:a.messageIcon,alt:"",src:n.A}),(0,s.jsx)("span",{children:t})]}),(0,s.jsx)("div",{className:a.messageClose,children:(0,s.jsx)("button",{className:a.closeBtn,onClick:i,"aria-label":"close",children:(0,s.jsx)("img",{alt:"",src:o.A})})})]})}},2038(e,t,i){"use strict";i.d(t,{A:()=>r});i(5043);var a=i(5151),o=i(1626),n=i(3490),s=i(579);const l=(0,a.A)({successMessageContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"#E2FBEA",border:"1px solid #4B9F53",padding:"0.5rem 1rem",borderRadius:"0.5rem"},messageText:{display:"flex",alignItems:"center",fontSize:"1.5rem",fontFamily:"AssistantRegular"},messageIcon:{marginRight:"0.75rem"},messageClose:{display:"flex"},closeBtn:{padding:"0",cursor:"pointer",backgroundColor:"transparent",border:"none"}}),r=e=>{let t=e.message,i=e.onClose;const a=l();return(0,s.jsxs)("div",{role:"alert",className:a.successMessageContainer,children:[(0,s.jsxs)("div",{className:a.messageText,children:[(0,s.jsx)("img",{className:a.messageIcon,alt:"",src:n.A}),(0,s.jsx)("span",{children:t})]}),(0,s.jsx)("div",{className:a.messageClose,children:(0,s.jsx)("button",{className:a.closeBtn,onClick:i,"aria-label":"close",children:(0,s.jsx)("img",{alt:"",src:o.A})})})]})}},3139(e,t,i){"use strict";i.d(t,{H:()=>a});const a=(e,t)=>"Complainant_AZURE_1000"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.azureconnectivity:"Complainant_SQL_1001"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.sqlserver:"Complainant_CRYPTO_1003"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.cryptovalidationerror:"Complainant_INVALID_AD_ORG_1000"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.invali
1dAdOrg:"Complainant_MANDATORY_FIELD_1006"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.incidentidMandatoryField:"Complainant_ORGANISATION_NOT_EXIST_1007"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.organisationnotexist:"Complainant_ORGANISATIONID_IS_REQUIRED_1008"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.organisationidisRequired:"Complainant_RECORD_CREATION_FAILED_1005"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.recordcreation:"Complainant_phoenixconnectivity_1001"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.phoenixconnectivity:"Complainant_messagenotreadable_1001"===(null===e||void 0===e?void 0:e.errorCode)?null===t||void 0===t?void 0:t.messagenotreadable:null===t||void 0===t?void 0:t.commonError},482(e,t,i){"use strict";i.r(t),i.d(t,{default:()=>a});const a={}},477(){}}]);
2//# sourceMappingURL=853.c55f3597.chunk.js.map

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.