import{e as _,K as g,r as y,n as m,f as b,g as n,q as d,C as s,x as l,s as a,a0 as w,S as f,T as u,D as v,J as p,aN as x,aU as h,ar as k}from"./jwt-decode.esm-rEBc1yJt.js";import{u as D}from"./organizationSwitcher-DLmZV2E5.js";import"./router-BaFu-do7.js";import"./ts.worker-BI7fZ7sa.js";import"./organization-DI9u_TkV.js";import"./tables-DdYqLMX_.js";import"./string-BwJCihDb.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]="870fb5ae-f4cb-4ea7-8f59-04dd60a62799",e._sentryDebugIdIdentifier="sentry-dbid-870fb5ae-f4cb-4ea7-8f59-04dd60a62799")}catch{}})();const R={class:"loading-container"},I=_({__name:"RootRedirector",setup(e){const r=D(),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",R,[o.value?(n(),d(a(x),{key:0,vertical:"",align:"center",gap:16},{default:s(()=>[l(a(w),{type:"danger"},{default:s(()=>[f(u(o.value),1)]),_:1}),l(a(v),{type:"primary",onClick:c},{default:s(()=>[f(u(a(p).translate("i18n_projectsview_retry")),1)]),_:1})]),_:1})):(n(),d(a(h),{key:1,size:"large"}))]))}}),O=k(I,[["__scopeId","data-v-c1eea334"]]);export{O as default};
//# sourceMappingURL=RootRedirector-CC0PaHeK.js.map
