PageSourceSearch

https://astron.ai/assets/index-wu3M7mEH.js

js astron.ai collected 2026-09-24 13:19:22 UTC 4,439 bytes, 1 lines download raw bytes

1import{r as n,j as e}from"./index-CJQpyVoF.js";import{r as S,s as $,t as E,v as L,w as b}from"./AppEntry-yGjZDq3c.js";import{I as w}from"./index-B0_gkfMG.js";import{u as U,p as k,s as l}from"./inviteCode-D9rgtvJs.js";import{u as D}from"./useSpaceI18n-BZqoDJzs.js";import{l as F}from"./agentLogoText-DKKhhTxa.js";import{l as R}from"./agentLogoTextEn-CC1FLgV-.js";import{c as B}from"./creator-BJlEkg6e.js";import{c as M,u as P}from"./useUrlParam-CZ4aw4md.js";import{u as G}from"./useTranslation-CZJVCIH1.js";import{I as z}from"./index-CS8YAtyi.js";import{B as A}from"./button-COlcySkY.js";import"./index-CiW30IE2.js";import"./tslib.es6-BO7bUXQ_.js";import"./reactNode-CvZomqk2.js";import"./dayjs.min-MSV7X6E-.js";import"./userAuth-Bzc-YaEz.js";import"./base64-Cs2W2fcZ.js";import"./index.module-Bi0Dxxte.js";import"./PulseLoader-BEbjbXk8.js";import"./useImageCropUpload-C40w0BUQ.js";import"./compressor.esm-C46f8uP2.js";import"./index-CSwuRCeV.js";import"./motion-BwoXtl0z.js";import"./ActionButton-DJ1XBOXE.js";import"./index-Cbb5YXZ-.js";import"./fade-DU7Y_kU8.js";import"./zoom-DpNIHBsI.js";import"./ContextIsolator-hwtSycux.js";import"./context-DKhv_b6t.js";import"./Compact-BviLumD4.js";import"./Skeleton-CRGI6EI_.js";import"./useLocale-Dmo9Agcu.js";import"./PurePanel-CKKM5xpM.js";import"./compact-item-5orumCwJ.js";import"./SearchOutlined-D1PhykWn.js";import"./index-Cb4CfQq0.js";const J="_teamCreateContainer_5sgnm_2",q="_logo_5sgnm_19",H="_logoImage_5sgnm_24",K="_content_5sgnm_29",O="_title_5sgnm_39",Q="_userInfo_5sgnm_51",V="_avatar_5sgnm_57",W="_userDetails_5sgnm_63",X="_userName_5sgnm_68",Y="_userRole_5sgnm_78",Z="_formCard_5sgnm_95",ee="_formTitle_5sgnm_107",se="_teamIcon_5sgnm_117",te="_iconPlaceholder_5sgnm_121",ae="_formFields_5sgnm_129",oe="_fieldGroup_5sgnm_132",re="_fieldLabel_5sgnm_150",ne="_fieldInput_5sgnm_155",ie="_createButton_5sgnm_162",s={teamCreateContainer:J,logo:q,logoImage:H,content:K,title:O,userInfo:Q,avatar:V,userDetails:W,userName:X,userRole:Y,formCard:Z,formTitle:ee,teamIcon:se,iconPlaceholder:te,formFields:ae,fieldGroup:oe,fieldLabel:re,fieldInput:ne,createButton:ie},Ke=()=>{const{user:a}=U(),{roleTextMap:p}=D(),_=M(),{handleTeamSwitch:f}=S(_),{getJoinedEnterpriseList:h}=$(),[m,x]=n.useState(""),[v,ce]=n.useState(""),[N,d]=n.useState(!1),[u,T]=n.useState(E),{type:g}=P(),{t}=G(),I=k(),j=n.useMemo(()=>a!=null&&a.roleType?p[a.roleType]:"-",[a==null?void 0:a.roleType,p]),o=n.useMemo(()=>t(g==="2"?"space.enterprise":"space.team"),[g]),i=n.useMemo(()=>({emptyTip:`${t("space.pleaseInput")} ${o} ${t("space.name")}`,existTip:`${o} ${t("space.name")} ${t("space.exist")}`,createSuccessTip:`${o} ${t("space.createSuccess")}`,createFailedTip:`${o} ${t("space.createFailed")}`}),[o]),C=async()=>{const c=m.trim();if(!c){l.error(i.emptyTip);return}d(!0);try{if(await L({name:c}))throw new Error(i.existTip);const y=await b({name:c,avatarUrl:u});l.success(i.createSuccessTip),await h(),f(y)}catch(r){l.error((r==null?void 0:r.message)||(r==null?void 0:r.msg)||i.createFailedTip)}finally{d(!1)}};return e.jsxs("div",{className:s.teamCreateContainer,children:[e.jsx("div",{className:s.logo,children:e.jsx("img",{src:I==="zh"?F:R,alt:"Logo",className:s.logoImage})}),e.jsxs("div",{className:s.content,children:[e.jsxs("div",{className:s.title,children:[o,t("space.version")," ",t("space.hasTakenEffect")]}),e.jsxs("div",{className:s.userInfo,children:[e.jsx("img",{src:(a==null?void 0:a.avatarUrl)||B,alt:t("space.adminAvatar"),className:s.avatar}),e.jsxs("div",{className:s.userDetails,children:[e.jsx("span",{className:s.userName,children:a==null?void 0:a.nickname}),e.jsx("span",{className:s.userRole,children:j})]})]}),e.jsxs("div",{className:s.formCard,children:[e.jsxs("div",{className:s.formTitle,children:[t("space.pleaseComplete")," ",o," ",t("space.infoSetting")]}),e.jsx("div",{className:s.teamIcon,children:e.jsx("div",{className:s.iconPlaceholder,children:e.jsx(w,{name:m,botDesc:v,coverUrl:u,setCoverUrl:T})})}),e.jsx("div",{className:s.formFields,children:e.jsxs("div",{className:s.fieldGroup,children:[e.jsxs("label",{className:s.fieldLabel,children:[o," ",t("space.name")]}),e.jsx(z,{value:m,onChange:c=>x(c.target.value),placeholder:i.emptyTip,variant:"borderless",className:s.fieldInput,maxLength:20,showCount:!0})]})}),e.jsxs(A,{type:"primary",size:"large",loading:N,onClick:C,className:s.createButton,block:!0,children:[t("space.create")," ",o]})]})]})]})};export{Ke 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.