import{e as _,J as g,r as y,Z as m,f as b,g as n,l as d,w as s,p as l,n as a,a0 as w,R as u,S as f,B as v,H as p,aN as R,aU as h,ar as k}from"./jwt-decode.esm-BPi7UGps.js";import{u as x}from"./organizationSwitcher-CS_Ixjks.js";import"./router-fx_h9Pdf.js";import"./ts.worker-DiZKOtzb.js";import"./organization-DoURzs4y.js";import"./tables-D28I09yf.js";import"./string-IVdpZYL8.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},r=new Error().stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="9e10fd70-27a1-4d68-acdb-2c1e9ec0369b",e._sentryDebugIdIdentifier="sentry-dbid-9e10fd70-27a1-4d68-acdb-2c1e9ec0369b")}catch{}})();const D={class:"loading-container"},I=_({__name:"RootRedirector",setup(e){const r=x(),i=g(),o=y(null);async function c(){o.value=null;try{const t=await r.selectDefaultOrganization();t.name==="onboarding"?window.location.href="/onboarding":i.replace(t)}catch(t){o.value=p.translate("i18n_projectsview_loading_error"),console.error("RootRedirector failed:",t)}}return m(c),(t,B)=>(n(),b("div",D,[o.value?(n(),d(a(R),{key:0,vertical:"",align:"center",gap:16},{default:s(()=>[l(a(w),{type:"danger"},{default:s(()=>[u(f(o.value),1)]),_:1}),l(a(v),{type:"primary",onClick:c},{default:s(()=>[u(f(a(p).translate("i18n_projectsview_retry")),1)]),_:1})]),_:1})):(n(),d(a(h),{key:1,size:"large"}))]))}}),T=k(I,[["__scopeId","data-v-c1eea334"]]);export{T as default};
//# sourceMappingURL=RootRedirector-C38PsskL.js.map
