PageSourceSearch

https://italent.ai/assets/index-c638ad21.js

js italent.ai collected 2026-10-05 12:04:36 UTC 2,565 bytes, 1 lines download raw bytes

1import{A as u,l as h,r as c,u as N,j as e,y as E,z as S,_ as m,$ as M,a0 as b,a1 as I,B as A,G as T,q as _,a2 as U,a3 as P,p as R,e as k,M as L}from"../index.js";const f={checkInvite:async a=>await fetch(`${u}/invite/${a}`,{method:"GET"}).then(t=>t.json()).catch(t=>(console.error(t),{invite:null,error:t.message})),acceptInvite:async(a,t={})=>await fetch(`${u}/invite/${a}`,{method:"POST",body:JSON.stringify(t)}).then(s=>s.json()).catch(s=>(console.error(s),{success:!1,error:s.message}))};function q(){const{code:a}=h(),[t,s]=c.useState(null),{t:n}=N(),o=async r=>{s(null),r.preventDefault();const i={},x=new FormData(r.target);for(var[g,p]of x.entries())i[g]=p;const{success:w,error:v}=await f.acceptInvite(a,i);if(w){const{valid:j,user:l,token:d,message:y}=await _.requestToken(i);j&&d&&l?(window.localStorage.setItem(U,JSON.stringify(l)),window.localStorage.setItem(P,d),window.location=R.home()):s(y);return}s(v)};return e.jsxs("form",{onSubmit:o,className:"flex flex-col gap-y-5",children:[e.jsx(E,{title:"Create a new account"}),e.jsxs(S,{children:[e.jsx(m,{label:"Username",name:"username",type:"text",placeholder:"My username",minLength:M,maxLength:b,pattern:I,required:!0,autoComplete:"off",hint:n("common.username_requirements")}),e.jsx(m,{label:"Password",name:"password",type:"password",placeholder:"Your password",required:!0,minLength:8,autoComplete:"off"}),t&&e.jsxs("p",{className:"text-red-400 text-sm",children:["Error: ",t]}),e.jsx("p",{className:"text-zinc-300 light:text-slate-700 text-xs md:text-sm",children:"After creating your account you will be able to login with these credentials and start using workspaces."})]}),e.jsx(A,{children:e.jsx(T,{type:"submit",className:"w-full",children:"Accept Invitation"})})]})}function O(){const{code:a}=h(),[t,s]=c.useState({status:"loading",message:null});return c.useEffect(()=>{async function n(){if(!a){s({status:"invalid",message:"No invite code provided."});return}const{invite:o,error:r}=await f.checkInvite(a);s({status:o?"valid":"invalid",message:r})}n()},[]),t.status==="loading"?e.jsx("div",{className:"w-screen h-screen overflow-hidden bg-theme-bg-container flex",children:e.jsx(k,{})}):t.status==="invalid"?e.jsx("div",{className:"w-screen h-screen overflow-hidden bg-theme-bg-container flex items-center justify-center",children:e.jsx("p",{className:"text-red-400 text-lg",children:t.message})}):e.jsx("div",{className:"w-screen h-screen overflow-hidden bg-theme-bg-container flex items-center justify-center",children:e.jsx(L,{isOpen:!0,children:e.jsx(q,{})})})}export{O as default};

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.