import{d as u,r as f,b as a,c as o,a as h,T as m,F as l,V as w,A as g,i as v,h as d,j as y,p as C,l as A,e as p,f as n,g as s,k as H}from"./ResizeObserver.es.83fe46f9.js";function E(){import("data:text/javascript,")}var S=u({name:"App",setup(){const e=f({showToast:!1,showToastCenter:!1});return a.on("toastShow",t=>{t==="center"&&(e.showToastCenter=!0),e.showToast=!0}),a.on("toastClose",t=>{e.showToast=!1,t==="center"&&setTimeout(()=>{e.showToastCenter=!1},300)}),a.on("toastStatus",()=>e.showToast),()=>o(l,null,[o(h("router-view"),null,null),o("div",{class:["appRootToast",e.showToastCenter?"appRootToastCenter":""]},[o(m,{show:e.showToast,"onUpdate:show":t=>e.showToast=t,overlay:!0,duration:3e4},{message:()=>o(l,null,[o(w,{class:"toastAnimate",animationData:g},null)])})])])}});window.ResizeObserver===void 0&&(window.ResizeObserver=v);const T=d(S).use(y);C({api:"getToken"}).then(e=>{console.log(e,"res");const t=e.content;t!=null&&t.accessToken&&A(t.tokenType+" "+t.accessToken)});p({api:"setBarStatus",content:{status:0}});p({api:"getNavHeight"},e=>{const{content:t}=e,c=t.dpi||2;if(t.navHeight){const r=t.navHeight/c;console.log(r,"navHeight"),s.navBarHeight=r}});p({api:"getVersion"},e=>{s.version=e.content.version});const i=window.paymentType;n().isTeacher||i==="TEACHER"?s.platformType="TEACHER":n().isStudent||i==="STUDENT"?s.platformType="STUDENT":n().isSchool||i==="SCHOOL"?s.platformType="SCHOOL":s.platformType="SCHOOL";s.platformType==="TEACHER"&&(s.platformApi="/api-teacher");s.platformType==="STUDENT"?s.platformApi="/api-student":s.platformApi="/api-school";T.use(H);T.mount("#app");export{E as __vite_legacy_guard};