define(["exports"],function(_exports){Object.defineProperty(_exports,"__esModule",{value:!0}),_exports.default=void 0;var EmbyProgressBar=function(_HTMLDivElement){function EmbyProgressBar(){var _this;_this=_HTMLDivElement.call(this)||this;return babelHelpers.possibleConstructorReturn(_this,_this)}return babelHelpers.inherits(EmbyProgressBar,_HTMLDivElement),babelHelpers.createClass(EmbyProgressBar,[{key:"connectedCallback",value:function(){this.timeInterval&&clearInterval(this.timeInterval),"time"===this.getAttribute("data-automode")&&(this.timeInterval=setInterval(function(){var start=parseInt(this.getAttribute("data-starttime")),end=parseInt(this.getAttribute("data-endtime")),end=(Date.now()-start)/(end-start)*100,end=Math.min(100,end);end=Math.max(0,end),this.querySelector(".itemProgressBarForeground").style.width=end+"%"}.bind(this),6e4))}},{key:"disconnectedCallback",value:function(){this.timeInterval&&(clearInterval(this.timeInterval),this.timeInterval=null)}}])}(babelHelpers.wrapNativeSuper(HTMLDivElement));customElements.define("emby-progressbar",EmbyProgressBar,{extends:"div"}),_exports.default=EmbyProgressBar});