import{T as a}from"./tcplayer.v4.8.0.min-acc282c0.js";/* empty css */const _="_contentBody_mtsh3_60",v="_cbTitle_mtsh3_67",m="_hideContent_mtsh3_76",h="_videoBoxCon_mtsh3_79",B="_videoBox_mtsh3_79",x="_coverImg_mtsh3_100",y="_video_mtsh3_9",k="_loadingVideo_mtsh3_154",C="_bottomBtn_mtsh3_163",b="_nextBtn_mtsh3_179",I={"intention-page":"_intention-page_mtsh3_1","content-box":"_content-box_mtsh3_57",contentBody:_,cbTitle:v,hideContent:m,videoBoxCon:h,videoBox:B,"video-content":"_video-content_mtsh3_90",coverImg:x,video:y,loadingVideo:k,bottomBtn:C,nextBtn:b},L=(o,t,n)=>{let e=o==="one"?t.player1:t.player2;const r=o==="one"?t.introductionVideo:t.introductionVideo2,g=o==="one"?t.coverImg:t.coverImg2;let c=o==="one"?t.playerSpeed1:t.playerSpeed2;o==="one"?t.videoLoading1:t.videoLoading2;const d=o==="one"?"register-video":"register-video2",p=a.getComponent("Button"),u=a.getComponent("BigPlayButton");if(u.prototype.createEl=function(){const l=p.prototype.createEl.call(this),s='';return l.appendChild(a.dom.createEl("div",{className:"vjs-button-icon",innerHTML:s})),l},e=a(d,{appID:"",controls:!0,plugins:{}}),e){e.src(r),e.poster(g||""),e.on("ready",s=>{console.log("ready",s)}),e.on("loadedmetadata",()=>{console.log("loadedmetadata"),o==="one"?t.videoLoading1=!1:t.videoLoading2=!1}),e.on("ratechange",()=>{c=c{console.log("seeking"),n.isActive.value&&n.pause()}),e.on("seeked",()=>{console.log("seeked"),n.isActive.value&&n.pause()}),e.on("waiting",()=>{n.isActive.value&&n.pause()}),e.on("timeupdate",()=>{!n.isActive.value&&e.currentTime()>0&&!e.paused()&&n.resume()}),e.on("ended",()=>{e.pause()}),e.on("play",()=>{e.id()==="register-video"&&t.player2.pause(),e.id()==="register-video2"&&t.player1.pause(),n.resume()}),e.on("pause",()=>{n.pause()});let l=!1;return e.on("fullscreenchange",()=>{var s;if(console.log("fullscreen fullscreenchange",e.isFullscreen()),l){l=!1;const i=document.getElementById("fullscreen-back");i&&i.remove()}else{l=!0;const i=document.createElement("i");i.id="fullscreen-back",i.className="van-icon van-icon-arrow-left video-back",i.addEventListener("click",()=>{e.exitFullscreen()}),(s=document.getElementById(d))==null||s.appendChild(i)}}),e}};export{L as _,I as s};