import{L as u}from"./CircularLoading-BM6NYRgA.js";import{e as f,U as p,Z as _,f as h,g as l,k as c,w as g,aq as m}from"./jwt-decode.esm-cMnpfgdw.js";import{E as a,a as y}from"./router-D_ihKcxX.js";import"./ts.worker-T_DnATf9.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},o=new Error().stack;o&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[o]="3490ac43-41ed-4bf4-bbb4-a602d026f22d",e._sentryDebugIdIdentifier="sentry-dbid-3490ac43-41ed-4bf4-bbb4-a602d026f22d")}catch{}})();const b={class:"authorize"},w={class:"content"},A=f({__name:"Authorize",setup(e){const o=p();return _(()=>{const{client_id:r,redirect_uri:s,response_type:n,state:i}=o.query,t=a.cloudApi.startsWith("https://")||a.cloudApi.startsWith("http://")?new URL(`${a.cloudApi}/oauth/authorize`):new URL(`${location.origin}${a.cloudApi}/oauth/authorize`);typeof r=="string"&&t.searchParams.set("client_id",r),typeof s=="string"&&t.searchParams.set("redirect_uri",s),typeof n=="string"&&t.searchParams.set("response_type",n),typeof i=="string"&&t.searchParams.set("state",i);const d=y.getAuthor();d?.jwt&&t.searchParams.set("session_token",d.jwt),window.location.href=t.toString()}),(r,s)=>(l(),h("div",b,[c("div",w,[s[0]||(s[0]=c("h1",null,"Authorizing...",-1)),g(u)])]))}}),L=m(A,[["__scopeId","data-v-57fe5408"]]);export{L as default};
//# sourceMappingURL=Authorize-C2ukxB4_.js.map
