1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3286],{23286:function(e,t,a){a.r(t),a.d(t,{Step11Completion:function(){return x}});var i=a(850),s=a(98776),n=a(39844),r=a(72784),l=a(59692),o=a(15741),d=a(38420),c=a(4085);function x(e){let{onSubmitAll:t}=e,[a,x]=(0,s.useState)(!1),[u,m]=(0,s.useState)(""),p=(0,o.useRouter)(),{user:f,loading:h,clearCache:b}=(0,d.a)(),g=async()=>{if((null==f?void 0:f.id)&&!a){x(!0),m("");try{if(t)await t();else{let t=await (0,c.k)({id:f.id,finished_onboarding:!0});if(t.success)localStorage.setItem("onboarding_completed","true"),window.dispatchEvent(new CustomEvent("onboarding-completed",{detail:{userId:f.id}})),b&&b(),p.push("/users/dashboard");else{var e;console.error("Failed to update onboarding status:",t.error),m((null===(e=t.error)||void 0===e?void 0:e.message)||"We could not finish setting up your profile. Please try again.")}}}catch(e){console.error("Error completing onboarding:",e),m(e instanceof Error?e.message:"We could not finish setting up your profile. Please try again.")}finally{x(!1)}}};return(0,i.jsxs)("div",{className:"flex min-h-0 flex-1 flex-col font-sans",children:[(0,i.jsx)("div",{className:"flex min-h-0 flex-1 flex-col overflow-y-auto overscroll-contain pr-1 [scrollbar-gutter:stable]",children:(0,i.jsxs)("div",{className:"my-auto w-full max-w-[790px] py-8 lg:pl-[clamp(42px,4.5vw,66px)]",children:[(0,i.jsxs)("div",{className:"flex items-center gap-3 text-brand-900",children:[(0,i.jsx)(n.Z,{className:"h-7 w-7 shrink-0 stroke-[2.4]","aria-hidden":"true"}),(0,i.jsx)("p",{className:"text-base font-[650] tracking-[-0.015em] sm:text-lg",children:"Setup complete"})]}),(0,i.jsx)("h1",{className:"mt-6 max-w-[650px] text-[clamp(46px,5.2vw,76px)] font-[650] leading-[1.02] tracking-[-0.055em] text-zinc-950 [text-wrap:balance] [@media(max-height:800px)]:mt-4 [@media(max-height:800px)]:text-[clamp(42px,4.5vw,60px)]",children:"The next move is yours."}),(0,i.jsx)("p",{className:"mt-6 max-w-[540px] text-base font-normal leading-7 text-zinc-600 sm:text-lg sm:leading-8 xl:text-xl [@media(max-height:800px)]:mt-4",children:"Your InternUp profile is ready. Head to your workspace and find opportunities that fit your direction."})]})}),(0,i.jsxs)("div",{className:"flex shrink-0 flex-col items-end gap-3 border-t border-zinc-200 py-5 sm:py-6",children:[(0,i.jsxs)("button",{type:"button",onClick:g,disabled:a||h||!(null==f?void 0:f.id),className:"inline-flex h-14 w-full items-center justify-between gap-8 rounded-xl bg-brand px-7 text-base font-[650] text-brand-900 transition-colors hover:bg-brand-400 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-brand-700 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 sm:w-[260px]",children:[(0,i.jsx)("span",{children:a?"Finalizing...":"Go to dashboard"}),a?(0,i.jsx)(r.Z,{className:"h-5 w-5 shrink-0 animate-spin","aria-hidden":"true"}):(0,i.jsx)(l.Z,{className:"h-5 w-5 shrink-0","aria-hidden":"true"})]}),u&&(0,i.jsx)("p",{role:"alert",className:"max-w-[420px] text-right text-sm text-red-600",children:u})]})]})}},4085:function(e,t,a){a.d(t,{k:function(){return i}}),a(64864);var i=(0,a(86438).$)("267fac65bf1d13c778989a07c867350a172bc4ba")}}]);
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.