'}}};e.exports=i},function(e,t,n){"use strict";function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function(){function e(e,t){for(var n=0;n1,this.index=0,this.current=this.videos[this.index],this.duration=n||0,this.durationArr=[],this.eventAll=[],this.eventCurrent=[],this.on("all","durationchange",function(e,t){1!==t.duration&&(i.durationArr[e]=t.duration,n||(i.duration=i.durationArr.reduce(function(e,t){return e+t})))}),this.on("current","end",function(){i.switch(i.index+1)})}return i(e,[{key:"switch",value:function(e,t){this.index!==e?(this.videos[e].classList.add("dplayer-video-current"),this.current.paused||this.videos[e].play(),this.current.classList.remove("dplayer-video-current"),this.current.pause(),this.index=e,this.current=this.videos[this.index],this.videos[e].currentTime=t||0):this.videos[e].currentTime=t||0}},{key:"on",value:function(e,t,n){var a=this;if("function"==typeof n&&("all"===e?(this.eventAll[t]||(this.eventAll[t]=[]),this.eventAll[t].push(n)):(this.eventCurrent[t]||(this.eventCurrent[t]=[]),this.eventCurrent[t].push(n)),-1===["seeking"].indexOf(t)))for(var i=0;i