import{L as u}from"./CircularLoading-COT_N2g8.js";import{e as f,an as p,W as _,f as h,g as l,k as d,v as g,aP as m}from"./jwt-decode.esm-BRUlSnzg.js";import{E as r,a as y}from"./router-CG0O12sY.js";import"./ts.worker-Fh-NnXPO.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},o=new Error().stack;o&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[o]="5ec90e64-2ba2-490e-b6aa-2337ba03fee8",t._sentryDebugIdIdentifier="sentry-dbid-5ec90e64-2ba2-490e-b6aa-2337ba03fee8")}catch{}})();const b={class:"authorize"},w={class:"content"},A=f({__name:"Authorize",setup(t){const o=p();return _(()=>{const{client_id:a,redirect_uri:s,response_type:n,state:i}=o.query,e=r.cloudApi.startsWith("https://")||r.cloudApi.startsWith("http://")?new URL(`${r.cloudApi}/oauth/authorize`):new URL(`${location.origin}${r.cloudApi}/oauth/authorize`);typeof a=="string"&&e.searchParams.set("client_id",a),typeof s=="string"&&e.searchParams.set("redirect_uri",s),typeof n=="string"&&e.searchParams.set("response_type",n),typeof i=="string"&&e.searchParams.set("state",i);const c=y.getAuthor();c?.jwt&&e.searchParams.set("session_token",c.jwt),window.location.href=e.toString()}),(a,s)=>(l(),h("div",b,[d("div",w,[s[0]||(s[0]=d("h1",null,"Authorizing...",-1)),g(u)])]))}}),k=m(A,[["__scopeId","data-v-57fe5408"]]);export{k as default};
//# sourceMappingURL=Authorize-BPNxqpsM.js.map
