1import{q as h,a as s,bH as k,bI as v,j as e,aK as y,bJ as T,a_ as L,bK as F,bD as w,r as p,bL as A,bM as D,bN as M,bO as U,bP as O,I as _,a6 as R,bQ as N,bR as B,bi as V,bA as $,S as q,X as K,bS as W,bT as G,bU as H,b0 as z,b1 as X,bV as J,bd as Q,b2 as Y,b4 as Z,b5 as ee,b6 as te,c as oe,bW as se,bX as re,bY as ne,bZ as ae,bc as ie}from"./index-CQaiPqwp.js";import{O as le,S as ce,a as me,b as pe}from"./SocialProviderList.component-BLodmx8j.js";import{a as de,C as ue}from"./CardLayout.component-BflI0h-4.js";import{A as ge}from"./Authentication.style-NKiSnuHN.js";import{C as be}from"./CardLayoutInstruction.component-DvoiYuGG.js";import{C as he}from"./CardLayoutTitle.component-D5IGGxJO.js";import{C as Se,u as xe}from"./index.esm-DGIHq7I6.js";import{B as P,a as C}from"./Banner.component-BIClPDC8.js";import{F as Pe,a as Ce}from"./FormContainer.style-hZDx4A_G.js";import{E as ye}from"./Email.component-kxWZZXJU.js";import{P as Le,E as we}from"./Password.style-B-hIMy5c.js";import{F as Re,g as fe}from"./input.helper-D1shRJlk.js";import{S as Ie}from"./Submit.component-I8eG1lLz.js";import{R as je}from"./Recaptcha.component-CLuG1NuO.js";import{A as Ee}from"./AppLayout.component-B34jiFc-.js";import{n as ke}from"./SignUpSecondStep.actions-BKMYXMrf.js";import"./Accordion.component-cjmnQlQg.js";import"./index-Dv-0yCFp.js";import"./Alert.style-CMMqopFC.js";import"./Phone.component-r7keLYmb.js";import"./regex.constant-BicOlS9j.js";import"./index-YIIf8Zzd.js";import"./LastName.component-C7MJwEGh.js";import"./PrivateContent.component-CA0ub5Pl.js";import"./OpenModal.component-DibLuewg.js";import"./react-select.esm-BTkEaSrm.js";import"./RichTextLink.component-BuB0fEgt.js";const b=h.div` 2 a { 3 margin: -10px 0; 4 padding: 10px 1ch; 5 font-weight: bold; 6 7 &, &:visited { 8 color: ${t=>t.theme.primary}; 9 } 10 } 11`,ve=h(ge)` 12 & > * { 13 margin-top: 30px; 14 } 15 16 ${de} { 17 ${le}, ${b}, ${ce} { 18 margin-top: 10px; 19 } 20 21 ${b} { 22 text-align: center; 23 } 24 } 25`,Te=()=>{const t=s(k),n=s(v),{search:o}=L(),r={pathname:T,search:o};return e.jsxs(b,{children:[t,e.jsx(y,{to:r,children:n})]})},Fe=h.div` 26 text-align: ${({align:t})=>t}; 27 28 a { 29 font-size: var(--text-xs); 30 31 &, &:visited { 32 color: ${t=>t.theme.primary}; 33 } 34 } 35`,Ae=t=>{const{align:n="left"}=t,o=s(F),{search:r}=L(),i={pathname:w,search:r};return e.jsx(Fe,{align:n,children:e.jsx(y,{to:i,children:o})})},De=t=>{const{control:n,rules:o}=t,[r,i]=p.useState(!1),l=p.useCallback(()=>{i(!r)},[r]),c=s(A),g=s(D),m=s(M),d=s(U(c.label,!!o?.required));return e.jsx(Se,{control:n,name:O,rules:{...o,minLength:8},render:({field:a,fieldState:u})=>e.jsxs(Le,{children:[e.jsx(Re,{type:r?"text":"password",help:c.helperText,error:fe(u.error,c),label:d,autoComplete:"current-password",name:a.name,value:a.value,onChange:a.onChange,onBlur:a.onBlur,inputRef:a.ref,hideCheckMark:!0,required:!!o?.required}),!u.error&&e.jsx(we,{onClick:l,type:"button",title:r?m:g,children:e.jsx(_,{color:"dark",name:r?"eye-open":"eye-close",size:"22"})})]})})},Me="onTouched",Ue=()=>{const t=R(),n=p.useRef(null),o=s(N),r=s(B),i=!s(V),{handleSubmit:l,control:c}=xe({mode:Me,defaultValues:{email:r}}),g=$(q.ERROR),[m,d]=p.useState(g),a=s(K(m)),u=s(W("error.action.resetPassword")),f=window.location.origin+w,S=m&&["error.password.policy","error.account.temporarilySuspended"].includes(m),I=async j=>{let x=!0;try{await t(G(j)),d(void 0)}catch(E){d(E),x=!1}finally{await n.current?.execute()}t(H(x))};return e.jsxs(Pe,{as:"form",onSubmit:l(I),children:[e.jsxs(Ce,{as:"fieldset",children:[e.jsx(ye,{control:c,rules:{required:!0}}),e.jsx(De,{control:c,rules:{required:!0}}),e.jsx(Ae,{align:"right"})]}),S&&a&&e.jsx(P,{message:a,variant:C.ERROR,linkLabel:u,linkUrl:f}),!S&&a&&e.jsx(P,{message:a,variant:C.ERROR}),e.jsx(Ie,{disabled:i,children:o}),e.jsx(je,{ref:n})]})};function Oe(t,n){return async(o,r,i)=>{await o(z()),await o(X());const l=J()(r());return i.analytics.trackDataLayerReady(Q.SIGN_IN),l&&!n?(o(ke(t)),Promise.resolve()):l&&n?(t.go(-1),Promise.resolve()):(await o(Y()),await o(Z()),o(ee(te.SIGN_IN)),Promise.resolve())}}const dt=()=>{const t=oe(),n=R();p.useEffect(()=>{const[c]=performance.getEntriesByType("navigation");n(Oe(t,c.type==="back_forward"))},[n,t]);const o=s(se),r=s(re),i=s(ne),l=!s(ae);return o?e.jsx(ie,{}):e.jsx(Ee,{hasBreadcrumb:!0,children:e.jsx(ve,{children:e.jsxs(ue,{children:[e.jsx(he,{children:r}),e.jsx(be,{children:i}),e.jsx(Ue,{}),e.jsx(Te,{}),!l&&e.jsxs(e.Fragment,{children:[e.jsx(me,{}),e.jsx(pe,{})]})]})})})};export{dt as SignInPresentation};
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.