import{dasc,Tasi,oasm,yasr,casl,Gas_,basp}from"./index-RS_StQsj.js";constg={style:{"min-height":"100vh",display:"grid","place-items":"center"}},h=c({__name:"IamCallback",setup(u){consta=_(),s=i();functiono(){sessionStorage.setItem("gb_iam_sso_skip","1");conste=sessionStorage.getItem("gb_iam_return");sessionStorage.removeItem("gb_iam_return");constt=e&&e.startsWith("/")&&!e.startsWith("//")?e:"/";returna.replace(t)}returnm(async()=>{conste=newURLSearchParams(window.location.search);if(sessionStorage.removeItem("gb_iam_sso_checked"),e.get("error")||!e.get("code")||!e.get("state")){awaito();return}try{constt=awaitr.ssoCallback(e.get("code"),e.get("state"));s.login(t.token,t.customer.id,t.customer.mobile);try{constn=awaitr.getExpertIdentity();s.setSalesExpert(n.isSalesExpert)}catch{s.setSalesExpert(!1)}awaita.replace({name:"home"})}catch{awaito()}}),(e,t)=>(p(),l("div",g,"در حال ورود..."))}});export{hasdefault};