var k=Object.defineProperty,V=Object.defineProperties;var $=Object.getOwnPropertyDescriptors;var D=Object.getOwnPropertySymbols;var S=Object.prototype.hasOwnProperty,q=Object.prototype.propertyIsEnumerable;var O=(e,t,o)=>t in e?k(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,l=(e,t)=>{for(var o in t||(t={}))S.call(t,o)&&O(e,o,t[o]);if(D)for(var o of D(t))q.call(t,o)&&O(e,o,t[o]);return e},A=(e,t)=>V(e,$(t));import{d as P,r as M,c as N,o as z,a as C,e as H,T as p,s as K,b as c,F as Y,I as J,f as b,B as W,R as U,g as G,h as X,n as Q,i as Z,j as w}from"./vendor.14dbc21a.js";const ee=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const n of r)if(n.type==="childList")for(const s of n.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&i(s)}).observe(document,{childList:!0,subtree:!0});function o(r){const n={};return r.integrity&&(n.integrity=r.integrity),r.referrerpolicy&&(n.referrerPolicy=r.referrerpolicy),r.crossorigin==="use-credentials"?n.credentials="include":r.crossorigin==="anonymous"?n.credentials="omit":n.credentials="same-origin",n}function i(r){if(r.ep)return;r.ep=!0;const n=o(r);fetch(r.href,n)}};ee();var te=(e,t)=>{const o=e.__vccOpts||e;for(const[i,r]of t)o[i]=r;return o};const oe=P({name:"App"});function re(e,t,o,i,r,n){const s=M("router-view");return z(),N(s)}var ie=te(oe,[["render",re]]);const ne="modulepreload",F={},se="./",a=function(t,o){return!o||o.length===0?t():Promise.all(o.map(i=>{if(i=`${se}${i}`,i in F)return;F[i]=!0;const r=i.endsWith(".css"),n=r?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${n}`))return;const s=document.createElement("link");if(s.rel=r?"stylesheet":ne,r||(s.as="script",s.crossOrigin=""),s.href=i,document.head.appendChild(s),r)return new Promise((d,m)=>{s.addEventListener("load",d),s.addEventListener("error",m)})})).then(()=>t())},ae="_error_u56io_1",ue="_info_u56io_10";var x={error:ae,info:ue};const u=C({user:{status:"init",data:{}},musicCertStatus:!1}),ce=e=>{u.user.status="login",u.user.data=e},le=()=>{u.user.status="logout",u.user.data=null},de=()=>{u.user.status="error",u.user.data=null};C({loadingCount:0});const g=()=>{const e=navigator.userAgent;return{trident:e.indexOf("Trident")>-1,presto:e.indexOf("Presto")>-1,webKit:e.indexOf("AppleWebKit")>-1,gecko:e.indexOf("Gecko")>-1&&e.indexOf("KHTML")==-1,mobile:!!e.match(/AppleWebKit.*Mobile.*/),ios:!!e.match(/Mac OS X/),android:e.indexOf("DAYAAPPA")>-1||e.indexOf("Adr")>-1,iPhone:e.indexOf("DAYAAPPI")>-1,isApp:e.indexOf("DAYAAPPI")>-1||e.indexOf("DAYAAPPA")>-1||e.indexOf("Adr")>-1,iPad:e.indexOf("iPad")>-1,webApp:e.indexOf("Safari")==-1,weixin:e.indexOf("MicroMessenger")>-1,huawei:!!e.match(/huawei/i)||!!e.match(/honor/i),xiaomi:!!e.match(/mi\s/i)||!!e.match(/redmi/i)||!!e.match(/mix/i)}},me=()=>""+new Date().getTime()+Math.floor(Math.random()*1e6),Oe=()=>{sessionStorage.removeItem("Authorization")},pe=e=>{sessionStorage.setItem("Authorization",e)},fe=window.postMessage;window.postMessage=e=>{fe(e,"*")};const E=()=>{},f={},L=g();L.isApp&&window.addEventListener("message",e=>{var t,o,i;try{const r=e.data?typeof e.data=="object"?e.data:JSON.parse(e.data):{},n=((t=r.content)==null?void 0:t.uuid)||r.uuid;try{r.content&&(r.content=JSON.parse(r.content))}catch{}if(((o=r==null?void 0:r.content)==null?void 0:o.uuid)&&console.log("data",r),!n){const m=Object.keys(f).filter(_=>_.indexOf(r.api)===0);for(const _ of m){const y=f[_]||E;typeof y=="function"&&y(r)}return}const s=((i=r.content)==null?void 0:i.uuid)||r.uuid||r.api+r.uuid,d=f[s]||E;typeof d=="function"&&d(r)}catch(r){console.error("\u901A\u4FE1\u6D88\u606F\u89E3\u6790\u9519\u8BEF",r)}});var T,j;const he=window.DAYA||((j=(T=window.webkit)==null?void 0:T.messageHandlers)==null?void 0:j.DAYA),B=(e,t)=>{if(L.isApp){const o=me();f[o]=t||E,e.content=e.content?A(l({},e.content),{uuid:o}):{uuid:o},he.postMessage(JSON.stringify(e)),console.log("send:",JSON.stringify(e))}},v=H({timeout:1e4});let R=!1;v.interceptors.request.use((e,t)=>{p.loading({message:"\u52A0\u8F7D\u4E2D...",forbidClick:!0,loadingType:"spinner",duration:0}),R=t.initRequest||!1;const o=sessionStorage.getItem("Authorization")||"",i={};return o&&!["/api-auth/usernameLogin","/api-auth/smsLogin","/api-auth/code/sendSms"].includes(e)&&(i.Authorization=o),{url:e,options:A(l({},t),{params:K(t.params),headers:l(l({},t.headers),i)})}},{global:!1});v.interceptors.response.use(async e=>{if(p.clear(),e.status>299||e.status<200){const o="\u670D\u52A1\u5668\u9519\u8BEF\uFF0C\u72B6\u6001\u7801"+e.status;throw p(o),new Error(o)}const t=await e.clone().json();if(t.code!==200&&t.errCode!==0){const o=t.msg||"\u5904\u7406\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5";R&&(t.code===403||t.code===401?le():de()),t.code===403||t.code===401||p(o);const i=g();throw t.code===403&&i.isApp&&B({api:"login"}),new Error(o)}return e},{global:!1});var _e=P({name:"Auth",data(){return{loading:!1}},computed:{isNeedView(){return u.user.status==="login"||this.$route.path==="/login"}},mounted(){this.setAuth()},methods:{async setAuth(){const{query:e}=this.$route,t=e.userInfo||e.Authorization;if(t&&pe(t),!this.loading){if(u.user.status==="init"||u.user.status==="error"){this.loading=!0;try{let o=await v.get("/api-teacher/teacher/queryUserInfo",{requestType:"form",initRequest:!0});ce(o.data)}catch{}this.loading=!1}if(u.user.status==="logout")if(g().isApp)B({api:"login"});else try{let o=this.$route,i=l({returnUrl:this.$route.path},this.$route.query);o.meta.isRegister&&(i.isRegister=o.meta.isRegister),this.$router.replace({path:"/login",query:i})}catch{}}}},render(){return c(Y,null,[u.user.status==="error"?c("div",{class:x.error},[c("div",{class:x.info},[c(J,{name:"clear",size:"36",color:"#ee0a24"},null),c("span",null,[b("\u52A0\u8F7D\u5931\u8D25\uFF0C\u8BF7\u91CD\u65B0\u5C1D\u8BD5")])]),c(W,{type:"primary",round:!0,onClick:this.setAuth},{default:()=>[b("\u91CD\u65B0\u52A0\u8F7D")]})]):this.isNeedView?c(U,null,null):null])}});const Ae=[{path:"/orderDetail",name:"orderDetail",component:()=>a(()=>import("./index.31876057.js"),["assets/index.31876057.js","assets/index.3ba6e342.css","assets/index.8739bc5b.css","assets/index.136e2d23.js","assets/index.f70e74fc.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"]),meta:{title:"\u8BA2\u5355\u8BE6\u60C5"}}],ge=[{path:"/registerProtocol",name:"registerProtocol",component:()=>a(()=>import("./register.69cb896c.js"),["assets/register.69cb896c.js","assets/index.module.b4127d60.js","assets/index.module.85d8aa1a.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"]),meta:{title:"\u6CE8\u518C\u534F\u8BAE"}},{path:"/privacyProtocol",name:"privacyProtocol",component:()=>a(()=>import("./privacy.c5702f13.js"),["assets/privacy.c5702f13.js","assets/index.module.b4127d60.js","assets/index.module.85d8aa1a.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"]),meta:{title:"\u9690\u79C1\u534F\u8BAE"}}];var Ee=[{path:"/",component:_e,children:[...Ae,{path:"/login",name:"login",component:()=>a(()=>import("./login.931537eb.js"),["assets/login.931537eb.js","assets/login.392ab8af.css","assets/index.935001ee.css","assets/index.09cb4b8c.css","assets/index.b64cd692.css","assets/index.e07367fb.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/validate.ba62cd4c.js"]),meta:{isRegister:!1}},{path:"/home",name:"home",component:()=>a(()=>import("./index.30675ae3.js"),["assets/index.30675ae3.js","assets/index.66617849.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"])},{path:"/teacherCert",name:"teacherCert",component:()=>a(()=>import("./index.02c2bbda.js"),["assets/index.02c2bbda.js","assets/index.5bd57212.css","assets/index.725eb6f5.css","assets/index.e07367fb.css","assets/index.935001ee.css","assets/index.09cb4b8c.css","assets/index.b64cd692.css","assets/index.c1ee5538.css","assets/index.8739bc5b.css","assets/index.6073691f.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.596585c1.js","assets/index.8294565f.css","assets/index.022a3a6b.js","assets/index.57c6c303.css","assets/index.27189ff2.js","assets/index.730fb30a.css","assets/index.136e2d23.js","assets/index.f70e74fc.css","assets/validate.ba62cd4c.js","assets/index.3d20c2f7.js","assets/index.75964354.css"]),meta:{title:"\u8001\u5E08\u8BA4\u8BC1"}},{path:"/music-upload",component:()=>a(()=>import("./index.3e61a4f7.js"),["assets/index.3e61a4f7.js","assets/index.61310489.css","assets/index.09cb4b8c.css","assets/index.b64cd692.css","assets/index.725eb6f5.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.3d20c2f7.js","assets/index.75964354.css"]),meta:{title:"\u4E0A\u4F20\u66F2\u8C31"}},{path:"/music-list",component:()=>a(()=>import("./switch.dee2a348.js"),["assets/switch.dee2a348.js","assets/switch.7ac36fff.css","assets/index.725eb6f5.css","assets/index.6073691f.css","assets/index.3c6f8825.css","assets/index.85a0c0a7.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"]),meta:{title:"\u66F2\u8C31\u5217\u8868"}},{path:"/openLive",name:"openLive",component:()=>a(()=>import("./index.eef3fdb4.js"),["assets/index.eef3fdb4.js","assets/index.07520eab.css","assets/index.09cb4b8c.css","assets/index.e07367fb.css","assets/index.725eb6f5.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.27189ff2.js","assets/index.730fb30a.css","assets/icon_teacher.d1cfb2e9.js"]),meta:{title:"\u5F00\u901A\u76F4\u64AD"}},{path:"/liveDetail",name:"liveDetail",component:()=>a(()=>import("./live-detail.51b22490.js"),["assets/live-detail.51b22490.js","assets/live-detail.2e37c824.css","assets/index.e07367fb.css","assets/index.725eb6f5.css","assets/index.6073691f.css","assets/index.3c6f8825.css","assets/index.09cb4b8c.css","assets/index.935001ee.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.711b6663.js","assets/index.3f72abd0.css","assets/index.e366bbbe.js","assets/index.9abbaa53.css","assets/icon_teacher.d1cfb2e9.js"]),meta:{title:"\u76F4\u64AD\u8BFE\u8BE6\u60C5"}},{path:"/musicCert",name:"musicCert",component:()=>a(()=>import("./index.08814597.js"),["assets/index.08814597.js","assets/index.afbc962b.css","assets/index.e07367fb.css","assets/index.725eb6f5.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.022a3a6b.js","assets/index.57c6c303.css"]),meta:{title:"\u97F3\u4E50\u4EBA\u8BA4\u8BC1"}},{path:"/videoCreate",name:"videoCreate",component:()=>a(()=>import("./create.7e92b7b3.js"),["assets/create.7e92b7b3.js","assets/create.e1e0bd3c.css","assets/index.b64cd692.css","assets/index.09cb4b8c.css","assets/index.e07367fb.css","assets/index.8739bc5b.css","assets/index.725eb6f5.css","assets/index.6073691f.css","assets/index.3c6f8825.css","assets/index.935001ee.css","assets/index.c1ee5538.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/index.3d20c2f7.js","assets/index.75964354.css","assets/index.596585c1.js","assets/index.8294565f.css","assets/index.022a3a6b.js","assets/index.57c6c303.css","assets/index.7de7a51d.js","assets/index.d431c7c2.css","assets/icon_teacher.d1cfb2e9.js","assets/index.711b6663.js","assets/index.3f72abd0.css"]),meta:{title:"\u521B\u5EFA\u89C6\u9891\u8BFE"}},{path:"/videoDetail",name:"videoDetail",component:()=>a(()=>import("./video-detail.5f459aef.js"),["assets/video-detail.5f459aef.js","assets/video-detail.b0b04a2d.css","assets/index.85a0c0a7.css","assets/index.725eb6f5.css","assets/index.6073691f.css","assets/index.3c6f8825.css","assets/index.09cb4b8c.css","assets/index.935001ee.css","assets/index.e07367fb.css","assets/index.c1ee5538.css","assets/index.7de7a51d.js","assets/index.d431c7c2.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css","assets/icon_teacher.d1cfb2e9.js","assets/index.711b6663.js","assets/index.3f72abd0.css","assets/index.e366bbbe.js","assets/index.9abbaa53.css","assets/index.022a3a6b.js","assets/index.57c6c303.css"]),meta:{title:"\u89C6\u9891\u8BFE\u8BE6\u60C5"}}]},...ge,{path:"/:pathMatch(.*)*",component:()=>a(()=>import("./index.a95c6f0d.js"),["assets/index.a95c6f0d.js","assets/index.f5943e6d.css","assets/index.e07367fb.css","assets/vendor.14dbc21a.js","assets/vendor.177057eb.css"]),meta:{title:"404 Not Fund",platform:"TEACHER"}}];const I=G({history:X(),routes:Ee});I.beforeEach((e,t,o)=>{document.title=e.meta.title||"\u9177\u4E50\u79C0",o()});var ve={moneyFormat(e){return Q(e).format("0,0.00")}};const h=Z(ie);w.locale("zh-ch");h.config.globalProperties.$dayjs=w;h.config.globalProperties.$filters=ve;h.use(I);h.mount("#app");export{Oe as a,pe as b,ce as c,g as d,B as p,v as r,u as s};