import{_ as h}from"./AbstraLogo.vue_vue_type_script_setup_true_lang.bf726c97.js";import{C as b}from"./ContentLayout.4f819aa5.js";import{l as k}from"./fetch.ea4c74a7.js";import{d as w,e3 as g,e4 as v,f as C,c,w as s,o as d,b as p,a as x,u as i,d2 as _,az as m,Q as I}from"./index.2bd55860.js";import{u as T,E as D}from"./editor.c5e900f0.js";import{C as L}from"./Card.687477e5.js";import"./Logo.3a35c761.js";import"./userStore.826271e3.js";import"./workspaceStore.279203c0.js";import"./runnerData.578dbe7d.js";import"./url.8ddd701d.js";import"./colorHelpers.4e11e3ec.js";import"./linters.5ae2dbb2.js";import"./asyncComputed.8007720a.js";import"./TabPane.cb697785.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="f71fa97d-a02c-4584-9d43-15d4ad7f97c2",e._sentryDebugIdIdentifier="sentry-dbid-f71fa97d-a02c-4584-9d43-15d4ad7f97c2")}catch{}})();const N={class:"card-content"},j=w({__name:"Welcome",setup(e){const t=g(),{query:n}=v(),a=T();a.loadLogin();const l=C(!0),u=async()=>{l.value=!1,setInterval(()=>{var o;return window.location.replace(((o=a==null?void 0:a.links)==null?void 0:o.project)||D.consoleUrl)},5e3)};return(async()=>{const o=n.token,r=n.redirect,f=await k("/_editor/auth/set-cookie",{method:"POST",body:JSON.stringify({token:o}),headers:{"Content-Type":"application/json"}});if(!f.ok)return u();const{ok:y}=await f.json();if(!y)return u();r?await t.push({path:r}):await t.push({name:"workspace"})})(),(o,r)=>(d(),c(b,null,{default:s(()=>[p(i(L),{bordered:!1,class:"card"},{default:s(()=>[x("div",N,[p(h,{style:{"margin-bottom":"10px"}}),l.value?(d(),c(i(_),{key:0},{default:s(()=>[m("Loading...")]),_:1})):(d(),c(i(_),{key:1},{default:s(()=>[m("Authentication failed. You are been redirected...")]),_:1}))])]),_:1})]),_:1}))}});const $=I(j,[["__scopeId","data-v-ba310460"]]);export{$ as default};
//# sourceMappingURL=Welcome.27170ac3.js.map
