TaskSystem/public/admin/assets/vue3-video-play.b911321b.js

11 lines
256 KiB
JavaScript
Raw Normal View History

2023-09-04 16:51:16 +08:00
import{e as xt,o as $,c as Z,O as Ct,_ as wt,u as j,bf as Pt,be as Ft,R as Tt,d as jt,a as V,M as ht,V as ft,U as et,S as st,bH as ie,r as Dt,Q as ut,$ as qt,Z as Ee,w as ue,j as de,G as ce,L as Jt,T as Xt,a7 as zt,W as te,X as Te,I as Se,K as be,a8 as Ht,n as he,i as Le}from"./@vue.51d7f2d8.js";var Ae=Object.defineProperty,De=Object.defineProperties,ke=Object.getOwnPropertyDescriptors,ne=Object.getOwnPropertySymbols,Re=Object.prototype.hasOwnProperty,_e=Object.prototype.propertyIsEnumerable,ae=(N,w,f)=>w in N?Ae(N,w,{enumerable:!0,configurable:!0,writable:!0,value:f}):N[w]=f,ee=(N,w)=>{for(var f in w||(w={}))Re.call(w,f)&&ae(N,f,w[f]);if(ne)for(var f of ne(w))_e.call(w,f)&&ae(N,f,w[f]);return N},re=(N,w)=>De(N,ke(w));function se(N,w,f,_){var T,A=!1,R=0;function I(){T&&clearTimeout(T)}function k(){for(var o=arguments.length,L=new Array(o),m=0;m<o;m++)L[m]=arguments[m];var h=this,E=Date.now()-R;function y(){R=Date.now(),f.apply(h,L)}function d(){T=void 0}A||(_&&!T&&y(),I(),_===void 0&&E>N?y():w!==!0&&(T=setTimeout(_?d:y,_===void 0?N-E:N)))}return typeof w!="boolean"&&(_=f,f=w,w=void 0),k.cancel=function(){I(),A=!0},k}function oe(N,w,f){return f===void 0?se(N,w,!1):se(N,f,w!==!1)}function Ie(N){return N&&N.__esModule&&Object.prototype.hasOwnProperty.call(N,"default")?N.default:N}var fe={exports:{}};typeof window<"u"&&(fe.exports=function(N){var w={};function f(_){if(w[_])return w[_].exports;var T=w[_]={i:_,l:!1,exports:{}};return N[_].call(T.exports,T,T.exports,f),T.l=!0,T.exports}return f.m=N,f.c=w,f.d=function(_,T,A){f.o(_,T)||Object.defineProperty(_,T,{enumerable:!0,get:A})},f.r=function(_){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(_,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(_,"__esModule",{value:!0})},f.t=function(_,T){if(1&T&&(_=f(_)),8&T||4&T&&typeof _=="object"&&_&&_.__esModule)return _;var A=Object.create(null);if(f.r(A),Object.defineProperty(A,"default",{enumerable:!0,value:_}),2&T&&typeof _!="string")for(var R in _)f.d(A,R,function(I){return _[I]}.bind(null,R));return A},f.n=function(_){var T=_&&_.__esModule?function(){return _.default}:function(){return _};return f.d(T,"a",T),T},f.o=function(_,T){return Object.prototype.hasOwnProperty.call(_,T)},f.p="/dist/",f(f.s="./src/hls.ts")}({"./node_modules/eventemitter3/index.js":function(N,w,f){var _=Object.prototype.hasOwnProperty,T="~";function A(){}function R(L,m,h){this.fn=L,this.context=m,this.once=h||!1}function I(L,m,h,E,y){if(typeof h!="function")throw new TypeError("The listener must be a function");var d=new R(h,E||L,y),t=T?T+m:m;return L._events[t]?L._events[t].fn?L._events[t]=[L._events[t],d]:L._events[t].push(d):(L._events[t]=d,L._eventsCount++),L}function k(L,m){--L._eventsCount==0?L._events=new A:delete L._events[m]}function o(){this._events=new A,this._eventsCount=0}Object.create&&(A.prototype=Object.create(null),new A().__proto__||(T=!1)),o.prototype.eventNames=function(){var L,m,h=[];if(this._eventsCount===0)return h;for(m in L=this._events)_.call(L,m)&&h.push(T?m.slice(1):m);return Object.getOwnPropertySymbols?h.concat(Object.getOwnPropertySymbols(L)):h},o.prototype.listeners=function(L){var m=T?T+L:L,h=this._events[m];if(!h)return[];if(h.fn)return[h.fn];for(var E=0,y=h.length,d=new Array(y);E<y;E++)d[E]=h[E].fn;return d},o.prototype.listenerCount=function(L){var m=T?T+L:L,h=this._events[m];return h?h.fn?1:h.length:0},o.prototype.emit=function(L,m,h,E,y,d){var t=T?T+L:L;if(!this._events[t])return!1;var a,e,s=this._events[t],u=arguments.length;if(s.fn){switch(s.once&&this.removeListener(L,s.fn,void 0,!0),u){case 1:return s.fn.call(s.context),!0;case 2:return s.fn.call(s.context,m),!0;case 3:return s.fn.call(s.context,m,h),!0;case 4:return s.fn.call(s.context,m,h,E),!0;case 5:return s.fn.call(s.context,m,h,E,y),!0;case 6:return s.fn.call(s.context,m,h,E,y,d),!0}for(e=1,a=new Array(u-1);e<u;e++)a[e-1]=arguments[e];s.fn.apply(s.context,a)}else{var n,l=s.length;for(e=0;e<l;e++)switch(s[e].once&&this.removeListener(L,s[e].fn,void 0,!0),u){case 1:s[e].fn.call(s[e].context);break;case 2:s[e].fn.call(s[e].context,m);break;c
`}),E=E+"new (("+_.toString().replace("ENTRY_MODULE",JSON.stringify(o))+")({"+h.main.map(function(a){return JSON.stringify(a)+": "+m.main[a].toString()}).join(",")+"}))(self);";var y=new window.Blob([E],{type:"text/javascript"});if(L.bare)return y;var d=(window.URL||window.webkitURL||window.mozURL||window.msURL).createObjectURL(y),t=new window.Worker(d);return t.objectURL=d,t}},"./src/config.ts":function(N,w,f){f.r(w),f.d(w,"hlsDefaultConfig",function(){return l}),f.d(w,"mergeConfig",function(){return p}),f.d(w,"enableStreamingMode",function(){return g});var _=f("./src/controller/abr-controller.ts"),T=f("./src/controller/audio-stream-controller.ts"),A=f("./src/controller/audio-track-controller.ts"),R=f("./src/controller/subtitle-stream-controller.ts"),I=f("./src/controller/subtitle-track-controller.ts"),k=f("./src/controller/buffer-controller.ts"),o=f("./src/controller/timeline-controller.ts"),L=f("./src/controller/cap-level-controller.ts"),m=f("./src/controller/fps-controller.ts"),h=f("./src/controller/eme-controller.ts"),E=f("./src/utils/xhr-loader.ts"),y=f("./src/utils/fetch-loader.ts"),d=f("./src/utils/cues.ts"),t=f("./src/utils/mediakeys-helper.ts"),a=f("./src/utils/logger.ts");function e(){return(e=Object.assign||function(v){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var c in i)Object.prototype.hasOwnProperty.call(i,c)&&(v[c]=i[c])}return v}).apply(this,arguments)}function s(v,r){var i=Object.keys(v);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(v);r&&(c=c.filter(function(S){return Object.getOwnPropertyDescriptor(v,S).enumerable})),i.push.apply(i,c)}return i}function u(v){for(var r=1;r<arguments.length;r++){var i=arguments[r]!=null?arguments[r]:{};r%2?s(Object(i),!0).forEach(function(c){n(v,c,i[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(v,Object.getOwnPropertyDescriptors(i)):s(Object(i)).forEach(function(c){Object.defineProperty(v,c,Object.getOwnPropertyDescriptor(i,c))})}return v}function n(v,r,i){return r in v?Object.defineProperty(v,r,{value:i,enumerable:!0,configurable:!0,writable:!0}):v[r]=i,v}var l=u(u({autoStartLoad:!0,startPosition:-1,defaultAudioCodec:void 0,debug:!1,capLevelOnFPSDrop:!1,capLevelToPlayerSize:!1,initialLiveManifestSize:1,maxBufferLength:30,backBufferLength:1/0,maxBufferSize:6e7,maxBufferHole:.1,highBufferWatchdogPeriod:2,nudgeOffset:.1,nudgeMaxRetry:3,maxFragLookUpTolerance:.25,liveSyncDurationCount:3,liveMaxLatencyDurationCount:1/0,liveSyncDuration:void 0,liveMaxLatencyDuration:void 0,maxLiveSyncPlaybackRate:1,liveDurationInfinity:!1,liveBackBufferLength:null,maxMaxBufferLength:600,enableWorker:!0,enableSoftwareAES:!0,manifestLoadingTimeOut:1e4,manifestLoadingMaxRetry:1,manifestLoadingRetryDelay:1e3,manifestLoadingMaxRetryTimeout:64e3,startLevel:void 0,levelLoadingTimeOut:1e4,levelLoadingMaxRetry:4,levelLoadingRetryDelay:1e3,levelLoadingMaxRetryTimeout:64e3,fragLoadingTimeOut:2e4,fragLoadingMaxRetry:6,fragLoadingRetryDelay:1e3,fragLoadingMaxRetryTimeout:64e3,startFragPrefetch:!1,fpsDroppedMonitoringPeriod:5e3,fpsDroppedMonitoringThreshold:.2,appendErrorMaxRetry:3,loader:E.default,fLoader:void 0,pLoader:void 0,xhrSetup:void 0,licenseXhrSetup:void 0,licenseResponseCallback:void 0,abrController:_.default,bufferController:k.default,capLevelController:L.default,fpsController:m.default,stretchShortVideoTrack:!1,maxAudioFramesDrift:1,forceKeyFrameOnDiscontinuity:!0,abrEwmaFastLive:3,abrEwmaSlowLive:9,abrEwmaFastVoD:3,abrEwmaSlowVoD:9,abrEwmaDefaultEstimate:5e5,abrBandWidthFactor:.95,abrBandWidthUpFactor:.7,abrMaxWithRealBitrate:!1,maxStarvationDelay:4,maxLoadingDelay:4,minAutoBitrate:0,emeEnabled:!1,widevineLicenseUrl:void 0,drmSystemOptions:{},requestMediaKeySystemAccessFunc:t.requestMediaKeySystemAccess,testBandwidth:!0,progressive:!1,lowLatencyMode:!0},{cueHandler:d.default,enableCEA708Captions:!0,enableWebVTT:!0,enableIMSC1:!0,captionsTextTrack1Label:"English",captionsTextTrack1LanguageCode:"en",captionsTextTrack2Label:"Spanish",captionsTextTrack2LanguageCode:"es",captionsTextTrack3Label:"Unknown CC",captionsTextTrack3LanguageCode:"",
Current BW estimate: `+(Object(_.isFiniteNumber)(F)?(F/1024).toFixed(3):"Unknown")+` Kb/s
Estimated load time for current fragment: `+D.toFixed(3)+` s
Estimated load time for the next fragment: `+P.toFixed(3)+` s
Time to underbuffer: `+C.toFixed(3)+" s"),e.nextLoadLevel=x,this.bwEstimator.sample(g,l.loaded),this.clearTimer(),t.loader&&(this.fragCurrent=this.partCurrent=null,t.loader.abort()),e.trigger(A.Events.FRAG_LOAD_EMERGENCY_ABORTED,{frag:t,part:a,stats:l})}}}}}},d.onFragLoaded=function(t,a){var e=a.frag,s=a.part;if(e.type===k.PlaylistLevelType.MAIN&&Object(_.isFiniteNumber)(e.sn)){var u=s?s.stats:e.stats,n=s?s.duration:e.duration;if(this.clearTimer(),this.lastLoadedFragLevel=e.level,this._nextAutoLevel=-1,this.hls.config.abrMaxWithRealBitrate){var l=this.hls.levels[e.level],p=(l.loaded?l.loaded.bytes:0)+u.loaded,g=(l.loaded?l.loaded.duration:0)+n;l.loaded={bytes:p,duration:g},l.realBitrate=Math.round(8*p/g)}if(e.bitrateTest){var v={stats:u,frag:e,part:s,id:e.type};this.onFragBuffered(A.Events.FRAG_BUFFERED,v),e.bitrateTest=!1}}},d.onFragBuffered=function(t,a){var e=a.frag,s=a.part,u=s?s.stats:e.stats;if(!u.aborted&&e.type===k.PlaylistLevelType.MAIN&&e.sn!=="initSegment"){var n=u.parsing.end-u.loading.start;this.bwEstimator.sample(n,u.loaded),u.bwEstimate=this.bwEstimator.getEstimate(),e.bitrateTest?this.bitrateTestDelay=n/1e3:this.bitrateTestDelay=0}},d.onError=function(t,a){switch(a.details){case I.ErrorDetails.FRAG_LOAD_ERROR:case I.ErrorDetails.FRAG_LOAD_TIMEOUT:this.clearTimer()}},d.clearTimer=function(){self.clearInterval(this.timer),this.timer=void 0},d.getNextABRAutoLevel=function(){var t=this.fragCurrent,a=this.partCurrent,e=this.hls,s=e.maxAutoLevel,u=e.config,n=e.minAutoLevel,l=e.media,p=a?a.duration:t?t.duration:0,g=l?l.currentTime:0,v=l&&l.playbackRate!==0?Math.abs(l.playbackRate):1,r=this.bwEstimator?this.bwEstimator.getEstimate():u.abrEwmaDefaultEstimate,i=(R.BufferHelper.bufferInfo(l,g,u.maxBufferHole).end-g)/v,c=this.findBestLevel(r,n,s,i,u.abrBandWidthFactor,u.abrBandWidthUpFactor);if(c>=0)return c;o.logger.trace((i?"rebuffering expected":"buffer is empty")+", finding optimal quality level");var S=p?Math.min(p,u.maxStarvationDelay):u.maxStarvationDelay,b=u.abrBandWidthFactor,D=u.abrBandWidthUpFactor;if(!i){var O=this.bitrateTestDelay;O&&(S=(p?Math.min(p,u.maxLoadingDelay):u.maxLoadingDelay)-O,o.logger.trace("bitrate test took "+Math.round(1e3*O)+"ms, set first fragment max fetchDuration to "+Math.round(1e3*S)+" ms"),b=D=1)}return c=this.findBestLevel(r,n,s,i+S,b,D),Math.max(c,0)},d.findBestLevel=function(t,a,e,s,u,n){for(var l,p=this.fragCurrent,g=this.partCurrent,v=this.lastLoadedFragLevel,r=this.hls.levels,i=r[v],c=!(i==null||(l=i.details)===null||l===void 0||!l.live),S=i==null?void 0:i.codecSet,b=g?g.duration:p?p.duration:0,D=e;D>=a;D--){var O=r[D];if(O&&(!S||O.codecSet===S)){var C=O.details,x=(g?C==null?void 0:C.partTarget:C==null?void 0:C.averagetargetduration)||b,P=void 0;P=D<=v?u*t:n*t;var F=r[D].maxBitrate,M=F*x/P;if(o.logger.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+D+"/"+Math.round(P)+"/"+F+"/"+x+"/"+s+"/"+M),P>F&&(!M||c&&!this.bitrateTestDelay||M<s))return D}}return-1},E=h,(y=[{key:"nextAutoLevel",get:function(){var t=this._nextAutoLevel,a=this.bwEstimator;if(!(t===-1||a&&a.canEstimate()))return t;var e=this.getNextABRAutoLevel();return t!==-1&&(e=Math.min(t,e)),e},set:function(t){this._nextAutoLevel=t}}])&&L(E.prototype,y),h}();w.default=m},"./src/controller/audio-stream-controller.ts":function(N,w,f){f.r(w);var _=f("./src/polyfills/number.ts"),T=f("./src/controller/base-stream-controller.ts"),A=f("./src/events.ts"),R=f("./src/utils/buffer-helper.ts"),I=f("./src/controller/fragment-tracker.ts"),k=f("./src/types/level.ts"),o=f("./src/types/loader.ts"),L=f("./src/loader/fragment.ts"),m=f("./src/demux/chunk-cache.ts"),h=f("./src/demux/transmuxer-interface.ts"),E=f("./src/types/transmuxer.ts"),y=f("./src/controller/fragment-finders.ts"),d=f("./src/utils/discontinuities.ts"),t=f("./src/errors.ts"),a=f("./src/utils/logger.ts");function e(){return(e=Object.assign||function(n){for(var l=1;l<arguments.length;l++){var p=arguments[l];for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(n[g]=p[g])}return n}).apply(this,arguments)}function s(n,l){return(s=Obje
discontinuity: `+b+`
trackSwitch: `+D+`
contiguous: `+x+`
accurateTimeOffset: `+n+`
timeOffset: `+i);var M=new A.TransmuxConfig(t,a,d,u,p);this.configureTransmuxer(M)}if(this.frag=e,this.part=s,r)r.postMessage({cmd:"demux",data:y,decryptdata:c,chunkMeta:l,state:F},y instanceof ArrayBuffer?[y]:[]);else if(v){var B=v.push(y,c,l,F);Object(A.isPromise)(B)?B.then(function(U){g.handleTransmuxComplete(U)}):this.handleTransmuxComplete(B)}},E.flush=function(y){var d=this;y.transmuxing.start=self.performance.now();var t=this.transmuxer,a=this.worker;if(a)a.postMessage({cmd:"flush",chunkMeta:y});else if(t){var e=t.flush(y);Object(A.isPromise)(e)?e.then(function(s){d.handleFlushResult(s,y)}):this.handleFlushResult(e,y)}},E.handleFlushResult=function(y,d){var t=this;y.forEach(function(a){t.handleTransmuxComplete(a)}),this.onFlush(d)},E.onWorkerMessage=function(y){var d=y.data,t=this.hls;switch(d.event){case"init":self.URL.revokeObjectURL(this.worker.objectURL);break;case"transmuxComplete":this.handleTransmuxComplete(d.data);break;case"flush":this.onFlush(d.data);break;default:d.data=d.data||{},d.data.frag=this.frag,d.data.id=this.id,t.trigger(d.event,d.data)}},E.configureTransmuxer=function(y){var d=this.worker,t=this.transmuxer;d?d.postMessage({cmd:"configure",config:y}):t&&t.configure(y)},E.handleTransmuxComplete=function(y){y.chunkMeta.transmuxing.end=self.performance.now(),this.onTransmuxComplete(y)},h}()},"./src/demux/transmuxer-worker.ts":function(N,w,f){f.r(w),f.d(w,"default",function(){return I});var _=f("./src/demux/transmuxer.ts"),T=f("./src/events.ts"),A=f("./src/utils/logger.ts"),R=f("./node_modules/eventemitter3/index.js");function I(m){var h=new R.EventEmitter,E=function(y,d){m.postMessage({event:y,data:d})};h.on(T.Events.FRAG_DECRYPTED,E),h.on(T.Events.ERROR,E),m.addEventListener("message",function(y){var d=y.data;switch(d.cmd){case"init":var t=JSON.parse(d.config);m.transmuxer=new _.default(h,d.typeSupported,t,d.vendor,d.id),Object(A.enableLogs)(t.debug),E("init",null);break;case"configure":m.transmuxer.configure(d.config);break;case"demux":var a=m.transmuxer.push(d.data,d.decryptdata,d.chunkMeta,d.state);Object(_.isPromise)(a)?a.then(function(u){k(m,u)}):k(m,a);break;case"flush":var e=d.chunkMeta,s=m.transmuxer.flush(e);Object(_.isPromise)(s)?s.then(function(u){L(m,u,e)}):L(m,s,e)}})}function k(m,h){if((E=h.remuxResult).audio||E.video||E.text||E.id3||E.initSegment){var E,y=[],d=h.remuxResult,t=d.audio,a=d.video;t&&o(y,t),a&&o(y,a),m.postMessage({event:"transmuxComplete",data:h},y)}}function o(m,h){h.data1&&m.push(h.data1.buffer),h.data2&&m.push(h.data2.buffer)}function L(m,h,E){h.forEach(function(y){k(m,y)}),m.postMessage({event:"flush",data:E})}},"./src/demux/transmuxer.ts":function(N,w,f){f.r(w),f.d(w,"default",function(){return e}),f.d(w,"isPromise",function(){return u}),f.d(w,"TransmuxConfig",function(){return n}),f.d(w,"TransmuxState",function(){return l});var _,T=f("./src/events.ts"),A=f("./src/errors.ts"),R=f("./src/crypt/decrypter.ts"),I=f("./src/demux/aacdemuxer.ts"),k=f("./src/demux/mp4demuxer.ts"),o=f("./src/demux/tsdemuxer.ts"),L=f("./src/demux/mp3demuxer.ts"),m=f("./src/remux/mp4-remuxer.ts"),h=f("./src/remux/passthrough-remuxer.ts"),E=f("./src/demux/chunk-cache.ts"),y=f("./src/utils/mp4-tools.ts"),d=f("./src/utils/logger.ts");try{_=self.performance.now.bind(self.performance)}catch{d.logger.debug("Unable to use Performance API on this environment"),_=self.Date.now}var t=[{demux:o.default,remux:m.default},{demux:k.default,remux:h.default},{demux:I.default,remux:m.default},{demux:L.default,remux:m.default}],a=1024;t.forEach(function(p){var g=p.demux;a=Math.max(a,g.minProbeByteLength)});var e=function(){function p(v,r,i,c,S){this.observer=void 0,this.typeSupported=void 0,this.config=void 0,this.vendor=void 0,this.id=void 0,this.demuxer=void 0,this.remuxer=void 0,this.decrypter=void 0,this.probe=void 0,this.decryptionPromise=null,this.transmuxConfig=void 0,this.currentTransmuxState=void 0,this.cache=new E.default,this.observer=v,this.typeSupported=r,this.config=i,this.vendor=c,this.id=S}var g=p.prototype;return g.configure=function(v){this.transmuxConfig=v,this.decrypter&&this.decr