import{e as _,K as b,r as g,n as y,f as m,g as n,q as d,C as s,x as l,s as r,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-hjaWXwux.js";import{u as D}from"./organizationSwitcher-DSiUw66t.js";import"./router-BkUH5xox.js";import"./ts.worker-B-SUuWWu.js";import"./organization-DyX3dwnh.js";import"./tables-DvBVnXSM.js";import"./string-RCvD6M5Y.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]="e73222cb-56a3-470d-b604-407fbe0ecfbb",e._sentryDebugIdIdentifier="sentry-dbid-e73222cb-56a3-470d-b604-407fbe0ecfbb")}catch{}})();const R={class:"loading-container"},I=_({__name:"RootRedirector",setup(e){const a=D(),i=b(),o=g(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 y(c),(t,B)=>(n(),m("div",R,[o.value?(n(),d(r(x),{key:0,vertical:"",align:"center",gap:16},{default:s(()=>[l(r(w),{type:"danger"},{default:s(()=>[f(u(o.value),1)]),_:1}),l(r(v),{type:"primary",onClick:c},{default:s(()=>[f(u(r(p).translate("i18n_projectsview_retry")),1)]),_:1})]),_:1})):(n(),d(r(h),{key:1,size:"large"}))]))}}),O=k(I,[["__scopeId","data-v-c1eea334"]]);export{O as default};
//# sourceMappingURL=RootRedirector-u0X1iQtU.js.map
