!function(A){var t={};function n(e){if(t[e])return t[e].exports;var i=t[e]={i:e,l:!1,exports:{}};return A[e].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=A,n.c=t,n.d=function(A,t,e){n.o(A,t)||Object.defineProperty(A,t,{enumerable:!0,get:e})},n.r=function(A){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(A,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(A,"__esModule",{value:!0})},n.t=function(A,t){if(1&t&&(A=n(A)),8&t)return A;if(4&t&&"object"==typeof A&&A&&A.__esModule)return A;var e=Object.create(null);if(n.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:A}),2&t&&"string"!=typeof A)for(var i in A)n.d(e,i,function(t){return A[t]}.bind(null,i));return e},n.n=function(A){var t=A&&A.__esModule?function(){return A.default}:function(){return A};return n.d(t,"a",t),t},n.o=function(A,t){return Object.prototype.hasOwnProperty.call(A,t)},n.p="",n(n.s=21)}([function(A,t){A.exports=function(A){var t=[];return t.toString=function(){return this.map(function(t){var n=function(A,t){var n,e=A[1]||"",i=A[3];if(!i)return e;if(t&&"function"==typeof btoa){var o=(n=i,"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(n))))+" */"),r=i.sources.map(function(A){return"/*# sourceURL="+i.sourceRoot+A+" */"});return[e].concat(r).concat([o]).join("\n")}return[e].join("\n")}(t,A);return t[2]?"@media "+t[2]+"{"+n+"}":n}).join("")},t.i=function(A,n){"string"==typeof A&&(A=[[null,A,""]]);for(var e={},i=0;i=0&&c.splice(t,1)}function y(A){var t=document.createElement("style");return void 0===A.attrs.type&&(A.attrs.type="text/css"),m(t,A.attrs),h(A,t),t}function m(A,t){Object.keys(t).forEach(function(n){A.setAttribute(n,t[n])})}function M(A,t){var n,e,i,o;if(t.transform&&A.css){if(!(o=t.transform(A.css)))return function(){};A.css=o}if(t.singleton){var r=l++;n=s||(s=y(t)),e=v.bind(null,n,r,!1),i=v.bind(null,n,r,!0)}else A.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=function(A){var t=document.createElement("link");return void 0===A.attrs.type&&(A.attrs.type="text/css"),A.attrs.rel="stylesheet",m(t,A.attrs),h(A,t),t}(t),e=function(A,t,n){var e=n.css,i=n.sourceMap,o=void 0===t.convertToAbsoluteUrls&&i;(t.convertToAbsoluteUrls||o)&&(e=u(e)),i&&(e+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */");var r=new Blob([e],{type:"text/css"}),a=A.href;A.href=URL.createObjectURL(r),a&&URL.revokeObjectURL(a)}.bind(null,n,t),i=function(){g(n),n.href&&URL.revokeObjectURL(n.href)}):(n=y(t),e=function(A,t){var n=t.css,e=t.media;if(e&&A.setAttribute("media",e),A.styleSheet)A.styleSheet.cssText=n;else{for(;A.firstChild;)A.removeChild(A.firstChild);A.appendChild(document.createTextNode(n))}}.bind(null,n),i=function(){g(n)});return e(A),function(t){if(t){if(t.css===A.css&&t.media===A.media&&t.sourceMap===A.sourceMap)return;e(A=t)}else i()}}A.exports=function(A,t){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(t=t||{}).attrs="object"==typeof t.attrs?t.attrs:{},t.singleton||"boolean"==typeof t.singleton||(t.singleton=r()),t.insertInto||(t.insertInto="head"),t.insertAt||(t.insertAt="bottom");var n=p(A,t);return d(n,t),function(A){for(var e=[],i=0;i=0)return A.length;for(var e=0,i=0,o=0,r=A.length-1;e<=r;){if(o++,n(t,A[(i=Math.floor((r+e+1)/2))-1])>=0&&n(t,A[i])<0)return i;n(t,A[i-1])<0?r=i-1:n(t,A[i])>=0?e=i:console.error("Program Error"),o>1500&&console.error("Too many run cycles.")}return-1},binsert:function(t,n,e){var i=A.bsearch(t,n,e);return t.splice(i,0,n),i}};return A}()),s=function(A,t){for(var n in t)t.hasOwnProperty(n)&&(A[n]=t[n]);function e(){this.constructor=A}A.prototype=null===t?Object.create(t):(e.prototype=t.prototype,new e)},l=function(){function A(A,t){void 0===A&&(A=0),void 0===t&&(t=0),this._pools=[[]],this.avoid=1,this._width=A,this._height=t}return A.prototype.willCollide=function(A,t){return A.stime+A.ttl>=t.stime+t.ttl/2},A.prototype.pathCheck=function(A,t,n){for(var e=A+t.height,i=t.right,o=0;oe||n[o].bottomi))return!1;if(this.willCollide(n[o],t))return!1}return!0},A.prototype.assign=function(A,t){for(;this._pools.length<=t;)this._pools.push([]);var n=this._pools[t];if(0===n.length)return A.cindex=t,0;if(this.pathCheck(0,A,n))return A.cindex=t,0;for(var e=0,i=0;ithis._height);i++)if(this.pathCheck(e,A,n))return A.cindex=t,e;return this.assign(A,t+1)},A.prototype.add=function(A){A.height>this._height?(A.cindex=-2,A.y=0):(A.y=this.assign(A,0),a.binsert(this._pools[A.cindex],A,function(A,t){return A.bottomt.bottom?1:0}))},A.prototype.remove=function(A){if(!(A.cindex<0)){if(A.cindex>=this._pools.length)throw new Error("cindex out of bounds");var t=this._pools[A.cindex].indexOf(A);t<0||this._pools[A.cindex].splice(t,1)}},A.prototype.setBounds=function(A,t){this._width=A,this._height=t},A}(),c=function(A){function t(){A.apply(this,arguments)}return s(t,A),t.prototype.add=function(t){A.prototype.add.call(this,t),t.x=(this._width-t.width)/2},t.prototype.willCollide=function(A,t){return!0},t.prototype.pathCheck=function(A,t,n){for(var e=A+t.height,i=0;ie||n[i].bottom0&&this.animate()},Object.defineProperty(A.prototype,"x",{get:function(){return null!==this._x&&void 0!==this._x||(this.align%2==0?this._x=this.dom.offsetLeft:this._x=this.parent.width-this.dom.offsetLeft-this.width),this.absolute?this._x:this._x/this.parent.width},set:function(A){this._x=A,this.absolute||(this._x*=this.parent.width),this.align%2==0?this.dom.style.left=this._x+"px":this.dom.style.right=this._x+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"y",{get:function(){return null!==this._y&&void 0!==this._y||(this.align<2?this._y=this.dom.offsetTop:this._y=this.parent.height-this.dom.offsetTop-this.height),this.absolute?this._y:this._y/this.parent.height},set:function(A){this._y=A,this.absolute||(this._y*=this.parent.height),this.align<2?this.dom.style.top=this._y+"px":this.dom.style.bottom=this._y+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"bottom",{get:function(){return this.y+this.height},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"right",{get:function(){return this.x+this.width},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"width",{get:function(){return null!==this._width&&void 0!==this._width||(this._width=this.dom.offsetWidth),this._width},set:function(A){this._width=A,this.dom.style.width=this._width+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"height",{get:function(){return null!==this._height&&void 0!==this._height||(this._height=this.dom.offsetHeight),this._height},set:function(A){this._height=A,this.dom.style.height=this._height+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"size",{get:function(){return this._size},set:function(A){this._size=A,this.dom.style.fontSize=this._size+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"color",{get:function(){return this._color},set:function(A){this._color=A;var t=A.toString(16);t=t.length>=6?t:new Array(6-t.length+1).join("0")+t,this.dom.style.color="#"+t,0===this._color&&(this.dom.className=this.parent.options.global.className+" rshadow")},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"alpha",{get:function(){return this._alpha},set:function(A){this._alpha=A,this.dom.style.opacity=Math.min(this._alpha,this.parent.options.global.opacity)+""},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"border",{get:function(){return this._border},set:function(A){this._border=A,this._border?this.dom.style.border="1px solid #00ffff":this.dom.style.border="none"},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"shadow",{get:function(){return this._shadow},set:function(A){this._shadow=A,this._shadow||(this.dom.className=this.parent.options.global.className+" noshadow")},enumerable:!0,configurable:!0}),Object.defineProperty(A.prototype,"font",{get:function(){return this._font},set:function(A){this._font=A,this._font.length>0?this.dom.style.fontFamily=this._font:this.dom.style.fontFamily=""},enumerable:!0,configurable:!0}),A.prototype.time=function(A){this.ttl-=A,this.ttl<0&&(this.ttl=0),this.movable&&this.update(),this.ttl<=0&&this.finish()},A.prototype.update=function(){this.animate()},A.prototype.invalidate=function(){this._x=null,this._y=null,this._width=null,this._height=null},A.prototype._execMotion=function(A,t){for(var n in A)if(A.hasOwnProperty(n)){var e=A[n];this[n]=e.easing(Math.min(Math.max(t-e.delay,0),e.dur),e.from,e.to-e.from,e.dur)}},A.prototype.animate=function(){if(this._alphaMotion&&(this.alpha=(this.dur-this.ttl)*(this._alphaMotion.to-this._alphaMotion.from)/this.dur+this._alphaMotion.from),0!==this.motion.length){var A=Math.max(this.ttl,0),t=this.dur-A-this._motionStart[this._curMotion];return this._execMotion(this.motion[this._curMotion],t),this.dur-A>this._motionEnd[this._curMotion]?(this._curMotion++,void(this._curMotion>=this.motion.length&&(this._curMotion=this.motion.length-1))):void 0}},A.prototype.finish=function(){this.parent.finish(this)},A.prototype.toString=function(){return["[",this.stime,"|",this.ttl,"/",this.dur,"]","(",this.mode,")",this.text].join("")},A.LINEAR=function(A,t,n,e){return A*n/e+t},A}()),d=function(A){function t(t,n){A.call(this,t,n),this.dur*=this.parent.options.scroll.scale,this.ttl*=this.parent.options.scroll.scale}return s(t,A),Object.defineProperty(t.prototype,"alpha",{set:function(A){this._alpha=A,this.dom.style.opacity=Math.min(Math.min(this._alpha,this.parent.options.global.opacity),this.parent.options.scroll.opacity)+""},enumerable:!0,configurable:!0}),t.prototype.init=function(t){void 0===t&&(t=null),A.prototype.init.call(this,t),this.x=this.parent.width,this.parent.options.scroll.opacity<1&&(this.alpha=this._alpha),this.absolute=!0},t.prototype.update=function(){this.x=this.ttl/this.dur*(this.parent.width+this.width)-this.width},t}(u),p=function(){var A=function(A,t){for(var n=Math.PI/180,e=A*n,i=t*n,o=Math.cos,r=Math.sin,a=[o(e)*o(i),o(e)*r(i),r(e),0,-r(i),o(i),0,0,-r(e)*o(i),-r(e)*r(i),o(e),0,0,0,0,1],s=0;s0)){var A=(new Date).getTime(),n=this;t=window.setInterval(function(){var t=(new Date).getTime()-A;A=(new Date).getTime(),n.onTimerEvent(t,n)},10)}},this.stopTimer=function(){window.clearInterval(t),t=0}}return t.prototype.stop=function(){this.stopTimer()},t.prototype.start=function(){this.startTimer()},t.prototype.seek=function(A){this.position=a.bsearch(this.timeline,A,function(A,t){return At.stime?1:0})},t.prototype.validate=function(A){return null!=A&&this.filter.doValidate(A)},t.prototype.load=function(A){this.timeline=A,this.timeline.sort(function(A,t){return A.stime>t.stime?2:A.stimet.date?1:A.datet.dbid?1:A.dbidt.stime?2:A.stimet.date?1:A.datet.dbid?1:A.dbid0;)this.runline[0].finish();this.dispatchEvent("clear")},t.prototype.setBounds=function(){for(var A in this.width=this.stage.offsetWidth,this.height=this.stage.offsetHeight,this.dispatchEvent("resize"),this.csa)this.csa[A].setBounds(this.width,this.height);this.stage.style.perspective=this.width*Math.tan(40*Math.PI/180)/2+"px",this.stage.style.webkitPerspective=this.width*Math.tan(40*Math.PI/180)/2+"px"},t.prototype.init=function(){this.setBounds(),null==this.filter&&(this.filter=new /** * Comment Filters Module Simplified (only supports modifiers & types) * @license MIT * @author Jim Chen */ function(){this.modifiers=[],this.runtime=null,this.allowTypes={1:!0,4:!0,5:!0,6:!0,7:!0,8:!0,17:!0},this.doModify=function(A){for(var t=0;t=this.timeline.length||Math.abs(this._lastPosition-A)>=2e3){if(this.seek(A),this._lastPosition=A,this.timeline.length<=this.position)return}else this._lastPosition=A;for(;this.position0&&this.runline.length>this.limiter||this.validate(this.timeline[this.position])&&this.send(this.timeline[this.position])},t.prototype.rescale=function(){},t.prototype.send=function(t){if(8!==t.mode){if(null==this.filter||null!=(t=this.filter.doModify(t))){if(1===t.mode||2===t.mode||6===t.mode)var n=new d(this,t);else n=new u(this,t);switch(n.mode){case 1:n.align=0;break;case 2:case 4:n.align=2;break;case 5:n.align=0;break;case 6:n.align=1}switch(n.init(),this.stage.appendChild(n.dom),n.mode){default:case 1:this.csa.scroll.add(n);break;case 2:this.csa.scrollbtm.add(n);break;case 4:this.csa.bottom.add(n);break;case 5:this.csa.top.add(n);break;case 6:this.csa.reverse.add(n);break;case 17:case 7:0===t.rY&&0===t.rZ||(n.dom.style.transform=A(t.rY,t.rZ),n.dom.style.webkitTransform=A(t.rY,t.rZ),n.dom.style.OTransform=A(t.rY,t.rZ),n.dom.style.MozTransform=A(t.rY,t.rZ),n.dom.style.MSTransform=A(t.rY,t.rZ))}n.y=n.y,this.dispatchEvent("enterComment",n),this.runline.push(n)}}else this.scripting&&this.scripting.eval(t.code)},t.prototype.sendComment=function(A){this.send(A)},t.prototype.finish=function(A){this.dispatchEvent("exitComment",A),this.stage.removeChild(A.dom);var t=this.runline.indexOf(A);switch(t>=0&&this.runline.splice(t,1),A.mode){default:case 1:this.csa.scroll.remove(A);break;case 2:this.csa.scrollbtm.remove(A);break;case 4:this.csa.bottom.remove(A);break;case 5:this.csa.top.remove(A);break;case 6:this.csa.reverse.remove(A);break;case 7:}},t.prototype.addEventListener=function(A,t){void 0!==this._listeners[A]?this._listeners[A].push(t):this._listeners[A]=[t]},t.prototype.dispatchEvent=function(A,t){if(void 0!==this._listeners[A])for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:"random";!function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),this.text=t,this.style=n||{fontSize:"14px",color:"#fff"},this.html=h(M.a),this.bulletPosition=e}return f(A,[{key:"createEl",value:function(A,t){this.html.innerText=this.text,A.appendChild(this.html)}},{key:"ready",value:function(A,t){var n=this;A.getOptions(),!1===A.getOptions().autoplay&&(this.html.style.animationPlayState="paused"),Object.keys(this.style).forEach(function(A){return n.html.style[A]=n.style[A]});var e=this.html.offsetHeight,i=parseInt(A.getOptions().height.replace("px",""))-e,o="top"===this.bulletPosition?0:"bottom"===this.bulletPosition?i+"px":this.randomTop(i);this.html.style.top=o,"random"===this.bulletPosition&&this.html.addEventListener("animationiteration",function(){n.html.style.top=n.randomTop(i)})}},{key:"playing",value:function(A,t){this.html.style.animationPlayState="running"}},{key:"timeupdate",value:function(A,t){var n=A.el(),e=n.querySelector(".bullet-screen");if(e){"bullet-screen"!==e.className&&(e.className="bullet-screen");var i=getComputedStyle(e),o=i.getPropertyValue("display"),r=i.getPropertyValue("opacity"),a=i.getPropertyValue("visibility");"none"===o&&e.style.setProperty("display","block"),"1"!==r&&e.style.setProperty("opacity","1"),"hidden"===a&&e.style.setProperty("visibility","visible")}else n.appendChild(this.html)}},{key:"pause",value:function(A,t){this.html.style.animationPlayState="paused"}},{key:"randomTop",value:function(A){return Math.floor(Math.random()*A)+"px"}}]),A}(),v=n(8),I=n.n(v),w=(n(29),function(){function A(A,t){for(var n=0;n0&&void 0!==arguments[0]&&arguments[0];!function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),this.html=h(I.a),this.autoPlay=t}return w(A,[{key:"createEl",value:function(A){A.appendChild(this.html)}},{key:"ready",value:function(A,t){var n=this,e=A.getOptions(),i=e.vid||e.source.replace(/\?.*$/,""),o=localStorage.getItem(i);if(null!==(o=o&&parseInt(o))&&0!==o)if(this.autoPlay)A.seek(o),"playing"!==A.getStatus()&&A.play();else{var r='
\n \n 上次看到\n '+this.getVideoTime(o)+'\n 跳转播放\n
';this.html.innerHTML=r;var a=setTimeout(function(){n.html.innerHTML=""},15e3);this.html.querySelector(".icon-close").onclick=function(){n.html.innerHTML="",clearTimeout(a)},this.html.querySelector(".play-jump").onclick=function(){A.seek(o),"playing"!==A.getStatus()&&A.play(),n.html.innerHTML="",clearTimeout(a)}}document.onvisibilitychange=function(){"hidden"===document.visibilityState&&0!==A.getCurrentTime()&&localStorage.setItem(i,A.getCurrentTime())},window.onbeforeunload=function(){0!==A.getCurrentTime()&&localStorage.setItem(i,A.getCurrentTime())}}},{key:"error",value:function(A,t){this.setMemory(A)}},{key:"dispose",value:function(A,t){this.setMemory(A)}},{key:"setMemory",value:function(A){var t=A.getOptions(),n=t.source.replace(/\?.*$/,"")||t.vid;0!==A.getCurrentTime()&&localStorage.setItem(n,A.getCurrentTime())}},{key:"getVideoTime",value:function(A){var t=Math.round(A),n=Math.floor(t/3600),e=Math.floor((t-3600*n)/60),i=t-3600*n-60*e;return e<10&&(e="0"+e),i<10&&(i="0"+i),0===n?e+":"+i:n+":"+e+":"+i}}]),A}(),x=n(9),T=n.n(x),D=(n(31),function(){function A(A,t){for(var n=0;n'+A.name+""}).join("")}}]),A}(),z=n(12),Y=n.n(z),O=(n(35),function(){function A(A,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:null,e=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;!function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),this.previewDuration=t,this.html=h(Y.a),null!==n&&this.insertHTtml(n,"previewEndHtml"),null!==e&&this.insertHTtml(e,"previewBarHtml")}return O(A,[{key:"play",value:function(A){this.previewEnd&&(A._el.querySelector(".center").classList.remove("preview-hide"),A.seek(0),this.previewEnd=!1)}},{key:"insertHTtml",value:function(A,t){var n="previewEndHtml"===t?".preview-custom":".preview-custom-bar",e=this.html.querySelector(n);if("string"==typeof A)if("#"===A[0]){var i=document.querySelector(A);i?e.innerHTML=i.innerHTML:console.warn("[aliplayer components warn]: Invalid parameter "+t+", can't find element by this id")}else e.innerHTML=A;else console.warn("[aliplayer components warn]: Invalid parameter "+t+", "+t+" must be a string type")}},{key:"ready",value:function(A){var t=parseInt(A.getDuration());this.videoDuration=t,!this.invalidPreview&&this.previewDuration>=t&&(this.invalidPreview=!0,console.warn("[aliplayer components warn]: Invalid parameter previewDuration, previewDuration must be less than the video duration!")),0!==this.previewDuration&&this.previewDuration1?" "+o+(this.isEn?" senconds":" 秒"):" "+r+(this.isEn?" minutes":" 分钟"),o<60&&(r=" "+o+(this.isEn?" senconds":" 秒")),this.html.querySelector(".preview-time").innerText=r;var s=A.querySelector("video").nextElementSibling;s?A.insertBefore(this.html,s):A.appendChild(this.html),this.html.querySelector(".preview-vod-close").addEventListener("click",function(){n.html.querySelector(".preview-component-tip").style.display="none"}),t.setPreviewTime(Number(this.previewDuration))}},{key:"closePreviewLayer",value:function(){this.previewEnd=!1,this.html.querySelector(".preview-component-layer").style.display="none"}},{key:"timeupdate",value:function(A){if(!this.previewEnd&&0!==this.previewDuration&&this.previewDurationn?(e=n-330+"px",this.html.querySelector(".icon-arrowdown").style.left=n*t.left-n+317+"px"):this.html.querySelector(".icon-arrowdown").style.left="-2px";var i=t.progressMarker,o=i.coverUrl,r=i.title,a=i.describe,s=i.offset;this.currentOffset=s,this.html.style.left=e,this.html.style.left,this.imgEle.src=o,this.timeEle.innerText=r,this.describeEle.innerText=a,this.html.style.display="block"}},{key:"markerDotOut",value:function(A,t){var n=this;this.timer=setTimeout(function(){n.html.style.display="none"},100)}}]),A}(),H=n(14),P=n.n(H),R=n(15),J=n.n(R),V=(n(42),function(){function A(A,t){for(var n=0;n'+A.desc+""});this.html.querySelector(".quality-list").innerHTML=i.join(""),this.definition,0==this.hasCreated&&this.definition&&(e.querySelector("li[data-def="+this.definition+"]").className="current"),this.hasCreated=!0;var o=null;n.onclick=function(){e.style.display="block"},n.onmouseleave=function(){o=setTimeout(function(){e.style.display="none"},100)},e.onmouseenter=function(){clearTimeout(o)},e.onmouseleave=function(){e.style.display="none"},e.onclick=function(n){var e=n.target,i=e.dataset.def;if(i&&"current"!==e.className){var o=t._urls.find(function(A){return A.definition===i});A.loadByUrl(o.Url,A.getCurrentTime(),!0,!0),t.setCurrentQuality(o.desc,o.definition),t.modalHtml.style.display="block",t.modalHtml.querySelector("span.current-quality-tag").innerText=o.desc}}}},{key:"ready",value:function(A){this.modalHtml.style.display="none";var t=document.querySelector(".prism-setting-item.prism-setting-quality");t&&t.classList.add("player-hidden")}}]),A}(),q=n(16),K=n.n(q),X=(n(44),function(){function A(A,t){for(var n=0;n1},hA.landscape=function(){return screen.orientation&&Object.prototype.hasOwnProperty.call(window,"onorientationchange")?screen.orientation.type.includes("landscape"):window.innerHeight/window.innerWidth<1},hA.noConflict=function(){return window.device=pA,this},hA.ios()?hA.ipad()?vA("ios ipad tablet"):hA.iphone()?vA("ios iphone mobile"):hA.ipod()&&vA("ios ipod mobile"):hA.macos()?vA("macos desktop"):hA.android()?hA.androidTablet()?vA("android tablet"):vA("android mobile"):hA.blackberry()?hA.blackberryTablet()?vA("blackberry tablet"):vA("blackberry mobile"):hA.windows()?hA.windowsTablet()?vA("windows tablet"):hA.windowsPhone()?vA("windows mobile"):vA("windows desktop"):hA.fxos()?hA.fxosTablet()?vA("fxos tablet"):vA("fxos mobile"):hA.meego()?vA("meego mobile"):hA.nodeWebkit()?vA("node-webkit"):hA.television()?vA("television"):hA.desktop()&&vA("desktop"),hA.cordova()&&vA("cordova"),hA.onChangeOrientation=function(A){"function"==typeof A&&gA.push(A)};var xA="resize";function TA(A){for(var t=0;t3&&void 0!==arguments[3]?arguments[3]:"关闭广告";EA(this,A),this.adVideoSource=t,this.adLink=n,this.html=h(sA.a),this.adInterval=null,this.adCloseFunction=e,this.html.querySelector(".video-ad-close-text").innerText=i,this.adDuration=null,this.player=null}return BA(A,[{key:"createEl",value:function(A,t){var n=this,e=t._options&&t._options.language;this.isEn=e&&"en-us"===e,this.html.querySelector(".video-ad-detail").innerText=this.isEn?"For more information":"查看广告详情",this.html.querySelector(".limit").innerText=this.isEn?"Your browser limits autoplay":"您的浏览器限制",this.html.querySelector(".manual").innerText=this.isEn?"Please Click":"自动播放请点击";var i=this.html.querySelector("#video-ad-content");i.setAttribute("src",this.adVideoSource);var o=this;this.html.querySelector(".icon-player-play").onclick=function(){n.playVideoAd(),n.html.querySelector(".autoplay-video-ad").style.display="none"},i.addEventListener("canplay",function A(){i.removeEventListener("canplay",A),o.adDuration=Math.ceil(i.duration),o.html.querySelector("#video-ad-duration").innerText=o.adDuration,i.play().then(function(){o.setAdInterval()}).catch(function(A){o.html.querySelector(".autoplay-video-ad").style.display="block"})});var r=this.html.querySelector(".video-ad-link"),a=this.html.querySelector(".video-ad-detail");r.setAttribute("href",this.adLink),a.setAttribute("href",this.adLink),A.appendChild(this.html)}},{key:"ready",value:function(A,t){var n=this;A.pause(),this.player=A,this.html.querySelector(".video-ad-close label").onclick=function(){"function"==typeof n.adCloseFunction?n.adCloseFunction(n):n.closeVideoAd()}}},{key:"pauseVideoAd",value:function(){this.clearAdInterval(),this.html.querySelector("#video-ad-content").pause()}},{key:"playVideoAd",value:function(){this.setAdInterval(),this.html.querySelector("#video-ad-content").play()}},{key:"clearAdInterval",value:function(){null!==this.adInterval&&clearInterval(this.adInterval),this.adInterval=null}},{key:"setAdInterval",value:function(){var A=this,t=this.html.querySelector("#video-ad-duration");this.adInterval=setInterval(function(){A.adDuration-=1,A.adDuration<=0?A.closeVideoAd():t.innerText=A.adDuration},1e3)}},{key:"closeVideoAd",value:function(){this.clearAdInterval(),this.html.parentNode.removeChild(this.html),this.player.getOptions().autoplay&&this.player.play()}}]),A}(),CA=function(){function A(t,n,e){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"关闭广告";EA(this,A),this.adVideoSource=t,this.adLink=n,this.html=h(cA.a),this.adInterval=null,this.adCloseFunction=e,this.html.querySelector(".video-ad-close-text").innerText=i,this.html.querySelector(".video-ad-link").setAttribute("href",this.adLink),this.html.querySelector(".video-ad-detail").setAttribute("href",this.adLink),this.adDuration=null}return BA(A,[{key:"createEl",value:function(A,t){var n=t._options&&t._options.language;this.isEn=n&&"en-us"===n,this.html.querySelector(".video-ad-detail").innerText=this.isEn?"For more information":"查看广告详情",this.html.querySelector(".limit").innerText=this.isEn?"Your browser limits autoplay":"您的浏览器限制",this.html.querySelector(".manual").innerText=this.isEn?"Please Click":"自动播放请点击",A.appendChild(this.html),A.querySelector("video"),A.querySelector("video").setAttribute("preload","load");var e=A.querySelector(".prism-controlbar");e.className=e.className+" controlbar-element-hidden";var i=A.querySelector(".prism-big-play-btn");i.className=i.className+" controlbar-element-hidden"}},{key:"created",value:function(A){this.player=A,this.vdSource=A.getOptions().source,A.loadByUrl(this.adVideoSource)}},{key:"ready",value:function(A){var t=this;if(this.html.querySelector(".autoplay-video-ad").onclick=function(){null!==t.adDuration&&t.html.parentNode.querySelector(".prism-big-play-btn").click()},null===this.adDuration){A.loadByUrl(this.adVideoSource),this.adDuration=void 0;var n=this.html.parentNode.querySelector("video"),e=this;n.addEventListener("timeupdate",function t(){var i=n.duration;isNaN(i)||0===i||(n.removeEventListener("timeupdate",t),e.adDuration=Math.ceil(n.duration),"none"!==e.html.querySelector(".autoplay-video-ad").style.display&&(e.html.querySelector(".autoplay-video-ad").style.display="none",A.play()),e.html.querySelector("#video-ad-duration").innerText=e.adDuration,e.setAdInterval())}),this.html.querySelector(".video-ad-close label").onclick=function(){"function"==typeof t.adCloseFunction?t.adCloseFunction(t):t.closeVideoAd()}}}},{key:"setAdInterval",value:function(){var A=this,t=this.html.querySelector("#video-ad-duration");this.adInterval=setInterval(function(){A.adDuration-=1,A.adDuration<=0?A.closeVideoAd():t.innerText=A.adDuration},1e3)}},{key:"closeVideoAd",value:function(){this.clearAdInterval(),this.player.loadByUrl(this.vdSource);var A=this.html.parentNode.querySelector(".prism-controlbar");A.className=A.className.replace(" controlbar-element-hidden","");var t=this.html.parentNode.querySelector(".prism-big-play-btn");t.className=t.className.replace(" controlbar-element-hidden",""),this.player.getOptions().autoplay&&this.player.play(),this.html.parentNode.removeChild(this.html)}},{key:"clearAdInterval",value:function(){null!==this.adInterval&&clearInterval(this.adInterval),this.adInterval=null}},{key:"playVideoAd",value:function(){this.setAdInterval(),this.player.play()}},{key:"pauseVideoAd",value:function(){this.clearAdInterval(),this.player.pause()}}]),A}(),kA=jA;QA.mobile()&&(kA=CA);var LA=kA;window.AliPlayerComponent={AliplayerDanmuComponent:y,BulletScreenComponent:N,MemoryPlayComponent:b,PauseADComponent:Q,PlaylistComponent:L,PreviewVodComponent:S,RotateMirrorComponent:nA,StartADComponent:rA,VideoADComponent:LA,RateComponent:_,QualityComponent:W,ProgressComponent:Z}}]);