"use strict";(globalThis.webpackChunktrueplayer=globalThis.webpackChunktrueplayer||[]).push([[137],{116(e,t,a){a.d(t,{createVimeoProvider:()=>u});var i=a(418);async function u(e,t,u={}){const r=(await a.e(320).then(a.bind(a,273))).default,n=(0,i.z)(),s=document.createElement("div");s.className="tp-media",e.appendChild(s);const c=new r(s,{id:t.videoId||(t.src||"").match(/vimeo\.com\/(\d+)/)?.[1]||t.src,controls:!1,responsive:!0,playsinline:!0,autoplay:!!u.autoStart,muted:!(!u.behavior||!u.behavior.muted)});let d=0,o=0,m=!0;return c.on("timeupdate",e=>{o=e.seconds,n.emit("timeupdate")}),c.on("play",()=>{m=!1,n.emit("play"),n.emit("playing")}),c.on("pause",()=>{m=!0,n.emit("pause")}),c.on("ended",()=>n.emit("ended")),c.on("bufferstart",()=>n.emit("waiting")),c.ready().then(async()=>{d=await c.getDuration().catch(()=>0),n.emit("ready"),n.emit("durationchange")}),{kind:"vimeo",element:s,capabilities:{pip:!!document.pictureInPictureEnabled,quality:!1,rate:!0,tracks:!1},on:n.on,play:()=>c.play(),pause:()=>c.pause(),seek:e=>(o=e,n.emit("timeupdate"),c.setCurrentTime(e).then(e=>{o=e,n.emit("timeupdate")}).catch(()=>{})),setVolume:e=>c.setVolume(e),setMuted:e=>c.setMuted(e),setRate:e=>c.setPlaybackRate(e),getCurrentTime:()=>o,getDuration:()=>d,getBufferedEnd:()=>o,isPaused:()=>m,isMuted:()=>!1,getVolume:()=>1,getRate:()=>1,getQualities:()=>[],setQuality:()=>{},getTextTracks:()=>[],setTextTrack:()=>{},requestPiP:()=>c.requestPictureInPicture(),exitPiP:()=>c.exitPictureInPicture(),isPiPActive:()=>c.getPictureInPicture().catch(()=>!1),destroy:()=>{try{c.destroy()}catch(e){}n.clear()}}}}}]);