1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="90cb6d89-cf20-4586-bcb9-357731cd5a72",e._sentryDebugIdIdentifier="sentry-dbid-90cb6d89-cf20-4586-bcb9-357731cd5a72")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3294],{3294:function(e,t,n){n.r(t),n.d(t,{default:function(){return c}});var l=n(52676),o=n(75271),i=n(86476),a=n(74606),s=n(53),d=n(6114),r=n(33876),u=n(11020);function c(e){var t,n;let{copy:c,onClose:v}=e,{setIsActivateSuccess:m,fetchCreditInfo:x,profile:g}=(0,r.lT)(),{locale:p,brand:b}=(0,a.DI)(),{email:f}=(0,d.Ep)(),_=u.y.includes(b),{isMutating:h,trigger:E,data:C}=(0,a.ZR)(),{isMutating:w,trigger:N}=(0,a.$v)(),[y,k]=(0,o.useState)(""),[j,T]=(0,o.useState)(""),{startCountDown:S,startAction:D,countDown:M}=(0,a.hk)(60),[I,A]=(0,o.useState)(""),[z,F]=(0,o.useState)(0),[K,R]=(0,o.useState)(Array(6).fill("")),U=(0,o.useRef)([]),W=K.join("");(0,o.useEffect)(()=>{U.current[z]&&U.current[z].focus()},[z]),(0,o.useEffect)(()=>{var e,t,n,l;f&&E({email:f,data:{redirect_url:"".concat(null===(t=window)||void 0===t?void 0:null===(e=t.location)||void 0===e?void 0:e.origin).concat(null===(l=window)||void 0===l?void 0:null===(n=l.location)||void 0===n?void 0:n.pathname)}},{onSuccess:()=>{T("success"),k((null==c?void 0:c.sendEmailSuccessMessage)||""),D(),setTimeout(()=>{T(""),k("")},5e3)}})},[f]);let B=(0,o.useCallback)(async()=>{var e,t,n,l;f&&(await E({email:f,data:{redirect_url:"".concat(null===(t=window)||void 0===t?void 0:null===(e=t.location)||void 0===e?void 0:e.origin).concat(null===(l=window)||void 0===l?void 0:null===(n=l.location)||void 0===n?void 0:n.pathname)}},{onSuccess:()=>{T("success"),k((null==c?void 0:c.sendEmailSuccessMessage)||""),D(),setTimeout(()=>{T(""),k("")},5e3)}}),(0,a.DU)({event:"ga4Event",event_name:"lp_button",event_parameters:{page_group:"reg_sub_pop",position:"auth_code",button_name:"sent_again"}}))},[f,E]),H=(e,t)=>{let{value:n}=e.target;if(A(""),Number.isNaN(Number(n)))return;if(n.length>1){t<K.length-1&&(K[t+1]||(F(t+1),R(e=>{let l=[...e];return l[t]=n[0],n.length>1&&(l[t+1]=n[1]),l})));return}let l=[...K];l[t]=n,R(l),n?t<K.length-1&&!K[t+1]&&F(t+1):t>0&&F(t-1)},L=(0,o.useCallback)(async()=>{var e,t,n,l;if(!(null==W?void 0:W.length)){A((null==c?void 0:c.codeEmptyError)||"");return}if(W.length<6){A((null==c?void 0:c.incorrectCodeError)||"");return}let o=null!==(l=null==C?void 0:null===(t=C.data)||void 0===t?void 0:null===(e=t.data)||void 0===e?void 0:e.active_token)&&void 0!==l?l:null==C?void 0:null===(n=C.data)||void 0===n?void 0:n.active_token;o&&await N({token:o,code:W},{onSuccess:e=>{if(e.status>=200&&e.status<300)T("success"),k((null==c?void 0:c.authSuccessMessage)||""),m(!0),(null==g?void 0:g.user_id)&&setTimeout(()=>x(g.user_id),3e3),(0,a.DU)({event:"ga4Event",event_name:"lp_button",event_parameters:{page_group:"reg_sub_pop",position:"auth_code",button_name:"check_and_active",info:"Member Floating Window"}}),setTimeout(()=>{v()},3e3);else{var t,n;let l=null!==(n=null==e?void 0:null===(t=e.data)||void 0===t?void 0:t.error_code)&&void 0!==n?n:null==e?void 0:e.error_code;"104"===l?(m(!0),(null==g?void 0:g.user_id)&&setTimeout(()=>x(g.user_id),3e3),(0,a.DU)({event:"ga4Event",event_name:"lp_button",event_parameters:{page_group:"reg_sub_pop",position:"auth_code",button_name:"check_and_active",info:"Member Floating Window"}}),setTimeout(()=>{v()},3e3)):A("142"===l?(null==c?void 0:c.incorrectCodeError)||"Invalid verification code.":"154"===l?(null==c?void 0:c.expiredCodeMessage)||"":(null==c?void 0:c.sendEmailErrorMessage)||"")}}});let i=setTimeout(()=>{T(""),k(""),clearTimeout(i)},5e3)},[W,null==c?void 0:c.codeEmptyError,null==c?void 0:c.authSuccessMessage,null==c?void 0:c.incorrectCodeError,null==c?void 0:c.expiredCodeMessage,null==c?void 0:c.sendEmailErrorMessage,p,C,N,v,m,x,g]);return(0,l.jsxs)("div",{className:"relative",children:[(0,l.jsxs)("div",{children:[(0,l.jsx)(i.xv,{className:"text-[22px] font-extrabold leading-[120%] text-[#333] min-l:text-[24px] [&_abbr]:text-[#005d8e]",html:null==c?void 0:c.authCodeTitle}),(0,l.jsx)(i.xv,{as:"p",className:"mt-3 text-[14px] font-semibold leading-[140%] text-[rgba(51,51,51,0.75)] min-l:text-base [&_abbr]:text-[#333]",html:null==c?void 0:null===(t=c.authCodeDe
1sc)||void 0===t?void 0:t.replace("%email%",f||"")})]}),(0,l.jsxs)("div",{className:"mt-6",children:[(0,l.jsx)(i.xv,{className:"mt-4 text-[14px] !font-bold font-semibold leading-[140%] text-[#333] min-l:mt-6",html:null==c?void 0:c.enterActiveCodeText}),(0,l.jsx)("div",{className:"my-3 grid grid-cols-6 gap-2",children:K.map((e,t)=>(0,l.jsx)("div",{className:"col-span-1 aspect-1 text-[#555]",children:(0,l.jsx)("input",{ref:e=>{e&&(U.current[t]=e)},type:"tel",className:(0,a.AK)("flex size-full items-center justify-center border border-[#333333]/20 bg-[#EEEEEE] text-center text-[24px] font-medium focus:border-[#333]/50 [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none [&:focus-visible]:outline-none",_&&"rounded-[12px]"),value:e,autoComplete:"false",autoCorrect:"false",spellCheck:"false",autoCapitalize:"false",onChange:e=>H(e,t),onFocus:()=>{F(t)},onPaste:e=>{let t=e.clipboardData.getData("text");if(!Number.isNaN(Number(t))){let e=t.split("").slice(0,6);R(e.concat(Array(6-e.length).fill(""))),e.length<=K.length&&F(e.length-1)}},onKeyDown:e=>{let{value:n}=e.target;"Backspace"===e.key&&!n&&t>0&&F(t-1)}},t)},t))}),I&&(0,l.jsx)(i.xv,{className:"mb-3 text-[14px] font-semibold leading-[120%] text-[#f84d4f]",html:I}),(null==c?void 0:c.authCodeContent)&&(0,l.jsx)("ul",{className:'flex flex-col gap-1 [&_li]:flex [&_li]:gap-2 [&_li]:text-[14px] [&_li]:font-semibold [&_li]:leading-[120%] [&_li]:text-[rgba(51,51,51,0.55)] [&_li]:before:content-["â¢"]',dangerouslySetInnerHTML:{__html:null==c?void 0:c.authCodeContent}})]}),(0,l.jsxs)("div",{className:"mt-4 min-l:mt-6",children:[(0,l.jsx)(i.xv,{className:"text-base font-semibold leading-[100%] text-[#333]",html:null==c?void 0:c.authCodeReceiveText})," ",S?(0,l.jsx)(i.xv,{html:null==c?void 0:null===(n=c.retrieveText)||void 0===n?void 0:n.replace("%countdownTime%",M.toString()),className:"cursor-pointer text-base font-semibold leading-[100%] !text-brand text-[#005d8e] text-[#333] underline"}):(0,l.jsx)(i.xv,{onClick:B,className:(0,a.AK)("cursor-pointer text-base font-semibold leading-[100%] !text-brand text-[#005d8e] text-[#333] underline",{"pointer-events-none":S||h}),html:null==c?void 0:c.sendAgainText}),(0,l.jsx)(i.zx,{type:"submit",loading:w,className:"mt-6 w-full min-l:mt-8",size:"base",onClick:L,children:c.buttonText})]}),(0,l.jsx)(s.v,{status:j,message:y})]})}}}]);
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.