import{_ as w}from"./AbstraLogo.vue_vue_type_script_setup_true_lang-CPoq8QfW.js";import{e as z,N as C,W as I,b as a,K as e,f as n,g as i,k as o,v as U,U as r,X as m,Y as $,s as u,as as x}from"./jwt-decode.esm-TBTnMpAQ.js";import{E as D}from"./router-D3FyrFLh.js";import"./logo-BiWG9_W5.js";import"./Logo-DSVZcRye.js";import"./ts.worker-9cx-N_QF.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},c=new Error().stack;c&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[c]="6602b5bd-268c-4791-8474-d0783fa7ac35",s._sentryDebugIdIdentifier="sentry-dbid-6602b5bd-268c-4791-8474-d0783fa7ac35")}catch{}})();const E={class:"unauthorized"},R={class:"auth-card"},A={class:"auth-brand"},B={class:"auth-title"},N={class:"auth-subtitle"},q={class:"auth-actions"},L=["onClick"],M=z({__name:"Unauthorized",setup(s){const c=C(),d=I(),_=a(()=>d.query.reason==="sso"),p=a(()=>{const t=d.query.methods;return typeof t!="string"||!t?[]:t.split(",")}),b=a(()=>p.value.filter(t=>t==="google"||t==="microsoft")),g=t=>t.charAt(0).toUpperCase()+t.slice(1),v=a(()=>_.value?e.translate("i18n_org_login_blocked_title"):e.translate("i18n_unauthorized_title")),y=a(()=>_.value?e.translate("i18n_org_login_blocked_message",null,{methods:p.value.map(g).join(", ")}):e.translate("i18n_unauthorized_description")),f=()=>c.push({name:"home"}),k=t=>{const l=encodeURIComponent(`${window.location.origin}/auth/callback`);window.location.href=`${D.cloudApi}/console/authn/oauth/${t}/start?redirect=${l}`};return(t,l)=>(i(),n("div",E,[o("div",R,[o("div",A,[U(w,{"hide-text":"",size:"small"}),l[0]||(l[0]=o("div",{class:"auth-brand__text"},[o("span",{class:"auth-brand__name"},"Abstra")],-1))]),o("h1",B,r(v.value),1),o("p",N,r(y.value),1),o("div",q,[_.value?(i(),n(m,{key:0},[(i(!0),n(m,null,$(b.value,h=>(i(),n("button",{key:h,class:"auth-btn-primary",onClick:S=>k(h)},r(h==="google"?u(e).translate("i18n_auth_continue_with_google"):u(e).translate("i18n_auth_continue_with_microsoft")),9,L))),128)),o("button",{class:"auth-btn-ghost",onClick:f},r(u(e).translate("i18n_unauthorized_go_home")),1)],64)):(i(),n("button",{key:1,class:"auth-btn-primary",onClick:f},r(u(e).translate("i18n_unauthorized_go_home")),1))])])]))}}),W=x(M,[["__scopeId","data-v-fe676eb0"]]);export{W as default};
//# sourceMappingURL=Unauthorized-B5voWk4I.js.map
