import{e as _,H as g,r as y,Y as m,f as w,g as n,l as d,y as s,t as l,n as r,$ as b,Q as u,R as f,B as v,G as p,aM as R,aT as h,aq as k}from"./jwt-decode.esm-B6XDbfGf.js";import{u as x}from"./organizationSwitcher-DL7T8tal.js";import"./router-ehqmHCor.js";import"./ts.worker-CkiPZMJ2.js";import"./organization-CRdFHOLi.js";import"./tables-y7hDXNsF.js";import"./string-CJZ_CLTg.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="076ac807-5b5e-4480-9847-5902c25e7d56",e._sentryDebugIdIdentifier="sentry-dbid-076ac807-5b5e-4480-9847-5902c25e7d56")}catch{}})();const D={class:"loading-container"},I=_({__name:"RootRedirector",setup(e){const a=x(),i=g(),o=y(null);async function c(){o.value=null;try{const t=await a.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(),w("div",D,[o.value?(n(),d(r(R),{key:0,vertical:"",align:"center",gap:16},{default:s(()=>[l(r(b),{type:"danger"},{default:s(()=>[u(f(o.value),1)]),_:1}),l(r(v),{type:"primary",onClick:c},{default:s(()=>[u(f(r(p).translate("i18n_projectsview_retry")),1)]),_:1})]),_:1})):(n(),d(r(h),{key:1,size:"large"}))]))}}),N=k(I,[["__scopeId","data-v-c1eea334"]]);export{N as default};
//# sourceMappingURL=RootRedirector-C0dzgr2P.js.map
