1"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[7666],{70431:(e,t,r)=>{r.r(t),r.d(t,{default:()=>b});var s=r(85893),a=r(67294),c=r(86706),n=r(29163),o=r(55977);let u=n.ZP.div.withConfig({displayName:"Wrapper",componentId:"-__sc-9172b264-0"})(({theme:e})=>` 2 display: flex; 3 flex-direction: column; 4 align-items: center; 5 background: ${e.body.backgroundColor}; 6 padding-top: ${o.W0.lg}; 7 `),i=n.ZP.div.withConfig({displayName:"Preferences",componentId:"-__sc-9172b264-1"})(["margin-top:",";"],o.W0.sm);var d=r(15158),l=r(22157),p=r(4894),g=r(8618);let h=async(e,t)=>{try{return await t.put(`survey/unsubscribe/${e}`,{},{headers:{Accept:"*/*"}}),!0}catch(e){return g.logger.error("unsubscribe() ",e),!1}};var v=r(73342),f=r(1563),y=r(51667);let m=async e=>{try{let t=await p.sg.put("customerfeedback/surveys/optout",null,{params:{id:e}});return 200===t.status}catch(t){return g.logger.error("customerFeedbackOptOut",t,{id:e}),!1}};var _=r(37593);let b=(0,c.$j)(e=>({isLoggedIn:(0,l.n)(e)}))(e=>{let[t,r]=a.useState(void 0),c=(0,_.c)("customer_feedback");a.useEffect(()=>{let e=window.location.pathname.split("/"),t=new URLSearchParams(window.location.search),s=t?.get("id"),a=e[e.indexOf(f.mq.surveyoptout.replace("/",""))+1];!c&&a?h(a,p.sg).then(e=>{r(e)}).catch(()=>r(!1)):c&&s?m(s).then(e=>{r(e)}).catch(()=>r(!1)):r(!1)},[]);let{t:n}=a.useContext(v.q);return(0,d.Z)(()=>(0,s.jsxs)(u,{"data-testid":"survey-page-wrapper-testId",children:[void 0===t&&(0,s.jsx)("p",{"data-testid":"survey-status-in-progress-testId",children:n("survey.optout.inProgress")}),!0===t&&(0,s.jsx)("p",{children:n("survey.optout.successful")}),!1===t&&(0,s.jsx)("p",{children:n("survey.optout.unsuccessful")}),void 0!==t&&e.isLoggedIn&&(0,s.jsx)(i,{children:(0,s.jsx)(y.rU,{href:f.ZP.preferences,children:n("survey.optout.preferences")})})]}),{componentName:"SurveyPage"})})}}]);
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.