PageSourceSearch

https://portal.cultureshoxmedia.com/build/assets/client-accept-CBBsyvVH.js

js cultureshoxmedia.com collected 2026-10-05 18:35:12 UTC 3,709 bytes, 1 lines download raw bytes

1import{K as y,m as w,j as i,L as A,d as C,a as c,I as d,B as I,b as L}from"./app-B52dr9Z4.js";import{I as h}from"./input-error-D__dGeiV.js";import{I as N}from"./invitation-summary-TCvgxXzu.js";import{A as x,a as f}from"./alert-e1DeHu6Z.js";import{u as k}from"./useTranslations-i04ZGdU9.js";import{A as F}from"./auth-layout-EWH3UTMT.js";import S from"./circle-alert-CTH4t-G2.js";/* empty css            */import"./mail-check-CzrfpmZ9.js";import"./app-logo-icon-BOA-xczo.js";function H({token:v,client:g,workspace:n,organization:o,acceptanceMode:s="sign_in"}){const{t:e}=k(),{errors:r}=y().props,l=w({}),{data:p,setData:m,post:j,processing:u,errors:a}=w({password:"",password_confirmation:"",name:g.name}),b=t=>{t.preventDefault(),s==="setup"?j(route("invitations.client.accept",v)):l.post(route("invitations.client.accept",v))},_=[{label:e("common.email"),value:g.email}];return o!=null&&o.name&&_.push({label:e("clients.organization"),value:o.name}),i.jsxs(F,{workspace:n,title:e("auth.welcome_to_workspace",{workspace:n.name}),description:s==="setup"?e("auth.complete_account_setup"):e("auth.review_invitation","Review your invitation"),children:[i.jsx(A,{title:e("auth.join_workspace",{workspace:n.name})}),i.jsxs("div",{className:"flex flex-col gap-6",children:[i.jsx(N,{title:e("auth.youre_invited"),description:s==="setup"?e("auth.invited_as_client_plain","You've been invited to join :workspace as a client. Please set up your account to get started.",{workspace:n.name}):e("auth.invited_existing_client","You have been invited to join :workspace as a client.",{workspace:n.name}),details:_}),s!=="setup"&&i.jsxs(x,{variant:"info",children:[i.jsx(C,{}),i.jsx(f,{children:s==="sign_in"?e("auth.invitation_sign_in_notice","Sign in with the invited email address. You will return to this invitation after signing in. If another account is signed in, continuing will sign it out."):e("auth.invitation_accept_notice","You are signed in as the invited recipient. Accepting adds this workspace without changing your profile or password.")})]}),i.jsxs("form",{id:"invitation-form",onSubmit:b,className:"flex flex-col gap-5",children:[s==="setup"&&i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"grid gap-2",children:[i.jsx(c,{htmlFor:"name",children:e("common.name")}),i.jsx(d,{id:"name",value:p.name,onChange:t=>m("name",t.target.value),required:!0,autoComplete:"name","aria-invalid":!!a.name}),i.jsx(h,{message:a.name})]}),i.jsxs("div",{className:"grid gap-2",children:[i.jsx(c,{htmlFor:"password",children:e("auth.create_password")}),i.jsx(d,{id:"password",type:"password",value:p.password,onChange:t=>m("password",t.target.value),required:!0,minLength:8,autoComplete:"new-password",placeholder:e("auth.enter_secure_password"),"aria-invalid":!!a.password}),i.jsx(h,{message:a.password})]}),i.jsxs("div",{className:"grid gap-2",children:[i.jsx(c,{htmlFor:"password_confirmation",children:e("auth.confirm_password")}),i.jsx(d,{id:"password_confirmation",type:"password",value:p.password_confirmation,onChange:t=>m("password_confirmation",t.target.value),required:!0,minLength:8,autoComplete:"new-password",placeholder:e("auth.confirm_your_password"),"aria-invalid":!!a.password_confirmation}),i.jsx(h,{message:a.password_confirmation})]})]}),(r.token||r.message)&&i.jsxs(x,{variant:"destructive",children:[i.jsx(S,{}),i.jsx(f,{children:r.token||r.message})]}),i.jsxs(I,{type:"submit",className:"w-full",disabled:u||l.processing,children:[(u||l.processing)&&i.jsx(L,{className:"animate-spin"}),s==="sign_in"?e("auth.invitation_sign_in","Sign in to accept"):s==="accept"?e("auth.accept_invitation","Accept invitation"):e(u?"auth.setting_up_account":"auth.complete_setup")]})]})]})]})}export{H 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.