PageSourceSearch

https://www.reima.com/_next/static/chunks/pages/my-account/details-787cee1c0ab1dfa1.js

js reima.com collected 2026-09-24 10:44:12 UTC 7,165 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1539],{3729:(e,t,a)=>{"use strict";a.r(t),a.d(t,{__N_SSP:()=>w,default:()=>S});var l=a(80263),r=a(31680);let o=e=>{let{className:t,onNavigationAttempt:a}=e;return(0,l.jsx)("div",{className:t,children:(0,l.jsx)(v,{onNavigationAttempt:a})})};var s=a(14887),n=a(88113),i=a(20858),c=a(41701),m=a(64124),u=a(75535),d=a(10663);let p=e=>{let t=t=>e("common:form.input.generic.error.required",{label:e(t)}),a=e=>({required_error:t(e),message:t(e)}),l=e=>d.Yj(a(e)).trim().min(1,a(e));return d.Ik({firstName:l("account:myAccount.details.detailsForm.firstName.label"),lastName:l("account:myAccount.details.detailsForm.lastName.label"),phone:l("account:myAccount.details.detailsForm.phone.label").refine(u.b,{message:e("common:newsletterForm.phoneInvalidE164")}),email:l("account:myAccount.details.detailsForm.email.label").email({message:e("common:form.input.generic.error.pattern",{label:e("account:myAccount.details.detailsForm.email.label")})})})};var h=a(11069),f=a(64856),b=a(48781),g=a(67254),A=a(53239),y=a(8665);let x=function(){let{redirectPath:e="/my-account"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{t:t}=(0,g.Bd)("account"),a=(0,s.W)(t),[l,r]=(0,A.useState)(!1),o=(0,b.useRouter)(),{customer:n,updateProfile:i}=(0,h.A)(),c=(0,f.X)(),u=p(a),{reset:d,register:x,handleSubmit:v,setError:N,formState:{isSubmitSuccessful:j,errors:k,isSubmitting:w,isValid:S,isDirty:F}}=(0,y.mN)({resolver:(0,m.u)(u),mode:"onChange"});(0,A.useEffect)(()=>{if(r(!0),n){var e,t,a;d({firstName:null!=(e=n.firstName)?e:void 0,lastName:null!=(t=n.lastName)?t:void 0,phone:null!=(a=n.phone)?a:void 0,email:n.email}),r(!1)}},[d,n]);let C=(t,a)=>{o.push({pathname:e,query:{result:t,action:a}}).catch(e=>e)};return{register:x,handleSubmit:v,errors:k,isSubmitting:w,isSubmitSuccessful:j,isValid:S,isDirty:F,disabled:l,onSubmit:async e=>{try{await i(e),C("success","edit")}catch(e){console.error(e),c(e,N,["phone"])}},onError:(e,t)=>console.log(e,t)}},v=e=>{let{onNavigationAttempt:t}=e,{t:a}=(0,g.Bd)(["account","common"]),r=(0,s.W)(a),o=(0,b.useRouter)(),[m,u]=(0,A.useState)(!1),[d,p]=(0,A.useState)(null),{register:h,handleSubmit:f,errors:y,isSubmitting:v,isSubmitSuccessful:N,isValid:j,isDirty:k,disabled:w,onSubmit:S,onError:F}=x(),C=(0,A.useCallback)(()=>{u(!1),d&&o.push(d).catch(e=>e)},[d,o]),E=(0,A.useCallback)(()=>{u(!1),p(null)},[]),_=(0,A.useCallback)(e=>{k&&!N?(p(e),u(!0)):o.push(e).catch(e=>e)},[k,N,o]);return(0,A.useEffect)(()=>{t&&t(_)},[t,_]),(0,A.useEffect)(()=>(o.beforePopState(()=>!k||!!N||(p("/my-account"),u(!0),window.history.pushState(null,"",o.asPath),!1)),()=>{o.beforePopState(()=>!0)}),[k,N,o]),(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(c.A,{id:"detailsLeaveConfirmation",title:r("myAccount.leaveConfirmation.title"),open:m,handleClose:E,size:"small",children:(0,l.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,l.jsx)("p",{children:r("myAccount.leaveConfirmation.message")}),(0,l.jsxs)("div",{className:"flex flex-col lg:justify-end lg:flex-row gap-2",children:[(0,l.jsx)(n.A,{type:"button",onClick:E,children:(0,l.jsx)("span",{className:"text-center w-full lg:w-auto",children:r("myAccount.leaveConfirmation.buttons.continue")})}),(0,l.jsx)(n.A,{type:"button",theme:"red",variation:"solid",onClick:C,children:(0,l.jsx)("span",{className:"text-center w-full lg:w-auto",children:r("myAccount.leaveConfirmation.buttons.leave")})})]})]})}),(0,l.jsxs)("form",{onSubmit:f(S,F),className:"pb-3 flex flex-col gap-2 text-charcoal-dark",children:[(0,l.jsxs)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-2",children:[(0,l.jsx)(i.pd,{type:"text",label:r("myAccount.details.detailsForm.firstName.label"),disabled:w,error:y.firstName,placeholder:r("myAccount.details.detailsForm.firstName.label"),required:!0,...h("firstName")}),(0,l.jsx)(i.pd,{type:"text",label:r("myAccount.details.detailsForm.lastName.label"),disabled:w,error:y.lastName,placeholder:r("myAccount.details.detailsForm.lastName.label"),required:!0,...h("lastName")}),(0,l.jsx)(i.pd,{type:"email",label:r("myAccount.details.detailsForm.email.label"),disabled:!0,error:y.email,placeholder:r("myAccount.details.detailsForm.email.label"),required:!0,...h("email")}),(0,l.jsx)(i.pd,{type:"tel",label:"".concat(r("myAccount.details.detailsForm.phone.label"),", ").concat(r("common:form.input.generic.phone.formatHint").toLowerCase()),disabled:w,error:y.phone,placeholder:r("common:form.input.generic.phone.formatHint"),...h("phone")})]}),y.root&&(0,l.jsx)("p",{className:"text-red text-sm",role:"alert",children:y.root.message}),(0,l.jsx)(i.XT,{isValid:j,isSubmitting:v,isSubmitSuccessful:N,renderSubmitText:r("myAccount.details.detailsForm.submit.label")})]})]})};a(88620);var N=a(96247),j=a(79172),k=a.n(j),w=!0;let S=()=>{let{t:e}=(0,g.Bd)("account"),[t,a]=(0,A.useState)(null);return(0,l.jsxs)(r.A,{title:e("myAccount.details.title"),children:[(0,l.jsx)(N.A,{title:e("myAccount.details.title"),backLinkText:e("myAccount.details.backLink.label"),onBackClick:()=>{t&&t("/my-account")}}),(0,l.jsx)(o,{onNavigationAttempt:e=>a(()=>e)}
1),(0,l.jsx)(k(),{className:"text-red hover:text-heather-dark transition-all text-left py-2 ui-base",href:"/my-account/manage",children:e("myAccount.manage.link.label")})]})}},6985:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var l=a(41980),r=a(92308);let o=(0,l.A)(function(e){return(0,r.A)(-1,e)})},27564:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/my-account/details",function(){return a(3729)}])},64856:(e,t,a)=>{"use strict";a.d(t,{X:()=>h});var l=a(71348),r=a(14887),o=a(25189),s=a(67254),n=a(9012),i=a(92333),c=a(24285),m=a(6985);let u={phone:"common:genericFormErrors.phoneUsedError"},d="common:genericFormErrors.submitError",p=e=>(0,n.A)(e)||(0,i.A)(e.trim())?"Something went wrong. Please try again.":e,h=()=>{let{t:e}=(0,s.Bd)("common"),t=(0,r.W)(e);return function(e,a){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(!o.A.isAxiosError(e))return void a("root",{type:"500",message:p(t(d))});let{type:s,field:n}=(0,l.a)(e),i=(0,c.A)(n)?(0,m.A)(n):void 0,h=r.find(e=>e===i),f=(0,c.A)(h)?u[h]:void 0;if((0,c.A)(h)&&(0,c.A)(f))return void a(h,{type:s,message:p(t(f))});a("root",{type:s,message:p(t(d))})}}},71348:(e,t,a)=>{"use strict";a.d(t,{a:()=>i});var l=a(24285),r=a(93343),o=a(10663);let s=o.Ik({msg:o.Yj()}),n=o.YO(o.Ik({field:o.YO(o.Yj()).optional(),message:o.Yj().optional()})),i=e=>{var t,a,o;let i=null==(a=e.response)||null==(t=a.status)?void 0:t.toString();try{let{msg:t}=s.parse(null==(o=e.response)?void 0:o.data),a=n.parse(JSON.parse(t)),c=a.map(e=>e.field).find(e=>(0,l.A)(e)&&(0,r.A)(e));return{type:null!=i?i:"unknown",message:a.map(e=>e.message).filter(Boolean).join(" "),...(0,l.A)(c)?{field:c}:{}}}catch(t){return{type:null!=i?i:"500",message:e.message}}}},75535:(e,t,a)=>{"use strict";a.d(t,{K:()=>n,b:()=>s});var l=a(81013),r=a(24285),o=a(93343);let s=e=>{let t=e.replace(/\s+/g,"");try{let e=(0,l.l)(t);return!!e&&e.isValid()&&e.format("E.164")===t}catch(e){return!1}},n=e=>(0,r.A)(e)&&(0,o.A)(e)&&s(e)}},e=>{var t=t=>e(e.s=t);e.O(0,[9172,4363,3981,2144,4124,1013,1488,1069,8686,6603,636,6593,8792],()=>t(27564)),_N_E=e.O()}]);

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.