(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5729],{60491:function(e,r,n){"use strict";var t=n(59499),i=n(82580),o=n(11163),s=n(7313),a=n(67294),l=n(14141),u=n(74231),m=n(2507),c=n(25048),d=n(12711),h=n(60792),p=n(8952),g=n(26103),f=n(10490),Z=n(35391),b=n(20122),_=n(85893);function j(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);r&&(t=t.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),n.push.apply(n,t)}return n}function v(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{};r%2?j(Object(n),!0).forEach((function(r){(0,t.Z)(e,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):j(Object(n)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))}))}return e}var N=l.ZP.div.withConfig({displayName:"LiveMessage__Parent",componentId:"sc-zeyou7-0"})(["width:100%;"]);r.Z=function(e){var r=e.hide,n=void 0!==r&&r,t=(0,s.$G)("common").t,l=(0,o.useRouter)(),j=(0,i.TA)({initialValues:{name:"",email:"",phoneNumber:"",message:""},validationSchema:u.Ry({name:u.Z_().required("".concat(t("This field is required"))),email:u.Z_().email().required("".concat(t("This field is required"))),phoneNumber:u.Z_().trim(),message:u.Z_().required("".concat(t("This field is required")))}),onSubmit:function(e){e.phoneNumber||delete e.phoneNumber,O.mutate(v(v({},e),{},{showId:l.query.showId}))}}),O=m.Z.useContactUsMutation(j.handleReset),E=c.Z.useGetUser(),x=E.isLoading,y=E.data;return(0,a.useEffect)((function(){y&&(j.values.name=null===y||void 0===y?void 0:y.name,j.values.email=null===y||void 0===y?void 0:y.email,j.values.phoneNumber=(null===y||void 0===y?void 0:y.phoneNumber)||"")}),[y,x]),(0,_.jsxs)(N,{children:[(0,_.jsx)(f.Z,{fontSize:Z.Z.FONT_SIZE_40,fontWeight:Z.Z.MEDIUM,children:n?" ":t("Send a live message")}),(0,_.jsx)(b.Z,{sendLiveMsgPage:!0,withOutEarlier:!0,hide:n}),l.query.showId&&(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(f.Z,{marginTop:25,fontSize:Z.Z.FONT_SIZE_22,fontWeight:Z.Z.REGULAR,children:t("Full Name")}),(0,_.jsx)(p.Z,v(v({id:"name",name:"name"},j.getFieldProps("name")),{},{inputError:j.touched.name&&j.errors.name,placeholder:t("Name")})),j.touched.name&&j.errors.name?(0,_.jsx)(g.Z,{style:{textAlign:"left"},children:j.errors.name}):null,(0,_.jsx)(f.Z,{marginTop:25,fontSize:Z.Z.FONT_SIZE_22,fontWeight:Z.Z.REGULAR,children:t("Email Address")}),(0,_.jsx)(p.Z,v(v({id:"email",name:"email"},j.getFieldProps("email")),{},{inputError:j.touched.email&&j.errors.email,placeholder:t("Email Address")})),j.touched.email&&j.errors.email?(0,_.jsx)(g.Z,{style:{textAlign:"left"},children:j.errors.email}):null,(0,_.jsx)(f.Z,{marginTop:25,fontSize:Z.Z.FONT_SIZE_22,fontWeight:Z.Z.REGULAR,children:t("Phone Number")}),(0,_.jsx)(p.Z,v(v({id:"phoneNumber",name:"phoneNumber"},j.getFieldProps("phoneNumber")),{},{inputError:j.touched.phoneNumber&&j.errors.phoneNumber,placeholder:t("Phone Number (Optional)")})),j.touched.phoneNumber&&j.errors.phoneNumber?(0,_.jsx)(g.Z,{style:{textAlign:"left"},children:j.errors.phoneNumber}):null,(0,_.jsx)(f.Z,{marginTop:25,fontSize:Z.Z.FONT_SIZE_22,fontWeight:Z.Z.REGULAR,children:t("Your Message")}),(0,_.jsx)(h.Z,v(v({id:"message",name:"message"},j.getFieldProps("message")),{},{inputError:j.touched.message&&j.errors.message,placeholder:t("Your Message...")})),j.touched.message&&j.errors.message?(0,_.jsx)(g.Z,{style:{textAlign:"left"},children:j.errors.message}):null,(0,_.jsx)(d.Z,{submitButton:!0,onClick:j.handleSubmit,marginTop:20,marginBottom:20,style:{width:"100%"},children:t("Submit")})]})]})}},39217:function(e,r,n){"use strict";n.r(r),n.d(r,{__N_SSG:function(){return l}});var t=n(7313),i=n(14141),o=n(63253),s=n(60491),a=n(85893),l=!0;r.default=(0,i.Zz)((function(e){var r=e.locale,n=(0,t.$G)("common").t,i=n("Send a live message"),l=n("description-live-message"),u=n("CTV"),m="en"===r?"/en":"";return(0,a.jsx)(o.Z,{content:(0,a.jsx)(s.Z,{}),h1:i,description:l,keywords:"".concat(i,", ").concat(u," ").concat(i),url:"".concat(m,"/live-message")})}))},39238:function(e,r,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/live-message",function(){return n(39217)}])}},function(e){e.O(0,[4885,4049,7345,551,6310,934,6391,6429,3253,7741,9774,2888,179],(function(){return r=39238,e(e.s=r);var r}));var r=e.O();_N_E=r}]);