/**
* @license
* Video.js 7.5.5
* Copyright Brightcove, Inc.
* Available under Apache License Version 2.0
*
*
* Includes vtt.js
* Available under Apache License Version 2.0
*
*/
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("global/window"),require("global/document")):"function"==typeof define&&define.amd?define(["global/window","global/document"],t):(e=e||self).videojs=t(e.window,e.document)}(this,function(h,d){h=h&&h.hasOwnProperty("default")?h.default:h,d=d&&d.hasOwnProperty("default")?d.default:d;var p="7.5.5";function f(e,t){e.prototype=Object.create(t.prototype),(e.prototype.constructor=e).__proto__=t}function s(e,t){return(s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function o(e,t,n){return(o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(e){return!1}}()?Reflect.construct:function(e,t,n){var i=[null];i.push.apply(i,t);var r=new(Function.bind.apply(e,i));return n&&s(r,n.prototype),r}).apply(null,arguments)}function v(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function t(e,t){return t||(t=e.slice(0)),e.raw=t,e}var l=[],e=function(o,a){return function(e,t,n){var i=a.levels[t],r=new RegExp("^("+i+")$");if("log"!==e&&n.unshift(e.toUpperCase()+":"),n.unshift(o+":"),l&&l.push([].concat(n)),h.console){var s=h.console[e];s||"debug"!==e||(s=h.console.info||h.console.log),s&&i&&r.test(e)&&s[Array.isArray(n)?"apply":"call"](h.console,n)}}};var g=function t(n){var i,r="info",s=function(){for(var e=arguments.length,t=new Array(e),n=0;n',n=i.firstChild,i.setAttribute("style","display:none; position:absolute;"),d.body.appendChild(i));for(var s={},o=0;ox',e=t.firstChild.href}return e},Yt=function(e){if("string"==typeof e){var t=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/i.exec(e);if(t)return t.pop().toLowerCase()}return""},Gt=function(e){var t=h.location,n=Xt(e);return(":"===n.protocol?t.protocol:n.protocol)+n.host!==t.protocol+t.host},Qt=Object.freeze({parseUrl:Xt,getAbsoluteURL:$t,getFileExtension:Yt,isCrossOrigin:Gt}),Jt=function(e){var t=Zt.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)},Zt=Object.prototype.toString;var en=At(function(e,t){(t=e.exports=function(e){return e.replace(/^\s*|\s*$/g,"")}).left=function(e){return e.replace(/^\s*/,"")},t.right=function(e){return e.replace(/\s*$/,"")}}),tn=(en.left,en.right,Function.prototype.toString),nn=/^\s*class\b/,rn=function(e){try{var t=tn.call(e);return nn.test(t)}catch(e){return!1}},sn=Object.prototype.toString,on="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,an=function(e){if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;if("function"==typeof e&&!e.prototype)return!0;if(on)return function(e){try{return!rn(e)&&(tn.call(e),!0)}catch(e){return!1}}(e);if(rn(e))return!1;var t=sn.call(e);return"[object Function]"===t||"[object GeneratorFunction]"===t},ln=Object.prototype.toString,cn=Object.prototype.hasOwnProperty,un=function(e,t,n){if(!an(t))throw new TypeError("iterator must be a function");var i;3<=arguments.length&&(i=n),"[object Array]"===ln.call(e)?function(e,t,n){for(var i=0,r=e.length;i=e?t.push(r):r.startTime===r.endTime&&r.startTime<=e&&r.startTime+.5>=e&&t.push(r)}if(a=!1,t.length!==this.activeCues_.length)a=!0;else for(var s=0;s","":"","":""," ":" "},Nn={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},Dn={v:"title",lang:"lang"},On={rt:"ruby"};function In(s,n){function e(){if(!n)return null;var e,t=n.match(/^([^<]*)(<[^>]*>?)?/);return e=t[1]?t[1]:t[2],n=n.substr(e.length),e}function t(e){return Ln[e]}function i(e){for(;f=e.match(/&(amp|lt|gt|lrm|rlm|nbsp);/);)e=e.replace(f[0],t);return e}function r(e,t){var n=Nn[e];if(!n)return null;var i=s.document.createElement(n);i.localName=n;var r=Dn[e];return r&&t&&(i[r]=t.trim()),i}for(var o,a,l,c=s.document.createElement("div"),u=c,h=[];null!==(o=e());)if("<"!==o[0])u.appendChild(s.document.createTextNode(i(o)));else{if("/"===o[1]){h.length&&h[h.length-1]===o.substr(2).replace(">","")&&(h.pop(),u=u.parentNode);continue}var d,p=jn(o.substr(1,o.length-2));if(p){d=s.document.createProcessingInstruction("timestamp",p),u.appendChild(d);continue}var f=o.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!f)continue;if(!(d=r(f[1],f[3])))continue;if(a=u,On[(l=d).localName]&&On[l.localName]!==a.localName)continue;f[2]&&(d.className=f[2].substr(1).replace("."," ")),h.push(f[1]),u.appendChild(d),u=d}return c}var Rn=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function Bn(e){for(var t=0;t=n[0]&&e<=n[1])return!0}return!1}function Fn(){}function Hn(e,t,n){Fn.call(this),this.cue=t,this.cueDiv=In(e,t.text);var i={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:""===t.vertical?"horizontal-tb":"lr"===t.vertical?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(i,this.cueDiv),this.div=e.document.createElement("div"),i={direction:function(e){var t=[],n="";if(!e||!e.childNodes)return"ltr";function r(e,t){for(var n=t.childNodes.length-1;0<=n;n--)e.push(t.childNodes[n])}function s(e){if(!e||!e.length)return null;var t=e.pop(),n=t.textContent||t.innerText;if(n){var i=n.match(/^.*(\n|\r)/);return i?i[e.length=0]:n}return"ruby"===t.tagName?s(e):t.childNodes?(r(e,t),s(e)):void 0}for(r(t,e);n=s(t);)for(var i=0;ih&&(u=u<0?-1:1,u*=Math.ceil(h/c)*c),r<0&&(u+=""===i.vertical?a.height:a.width,s=s.reverse()),n.move(d,u)}else{var p=n.lineHeight/a.height*100;switch(i.lineAlign){case"middle":r-=p/2;break;case"end":r-=p}switch(i.vertical){case"":t.applyStyles({top:t.formatStyle(r,"%")});break;case"rl":t.applyStyles({left:t.formatStyle(r,"%")});break;case"lr":t.applyStyles({right:t.formatStyle(r,"%")})}s=["+y","-x","+x","-y"],n=new Vn(t)}var f=function(e,t){for(var n,i=new Vn(e),r=1,s=0;se.left&&this.tope.top},Vn.prototype.overlapsAny=function(e){for(var t=0;t=e.top&&this.bottom<=e.bottom&&this.left>=e.left&&this.right<=e.right},Vn.prototype.overlapsOppositeAxis=function(e,t){switch(t){case"+x":return this.lefte.right;case"+y":return this.tope.bottom}},Vn.prototype.intersectPercentage=function(e){return Math.max(0,Math.min(this.right,e.right)-Math.max(this.left,e.left))*Math.max(0,Math.min(this.bottom,e.bottom)-Math.max(this.top,e.top))/(this.height*this.width)},Vn.prototype.toCSSCompatValues=function(e){return{top:this.top-e.top,bottom:e.bottom-this.bottom,left:this.left-e.left,right:e.right-this.right,height:this.height,width:this.width}},Vn.getSimpleBoxPosition=function(e){var t=e.div?e.div.offsetHeight:e.tagName?e.offsetHeight:0,n=e.div?e.div.offsetWidth:e.tagName?e.offsetWidth:0,i=e.div?e.div.offsetTop:e.tagName?e.offsetTop:0;return{left:(e=e.div?e.div.getBoundingClientRect():e.tagName?e.getBoundingClientRect():e).left,right:e.right,top:e.top||i,height:e.height||t,bottom:e.bottom||i+(e.height||t),width:e.width||n}},Wn.StringDecoder=function(){return{decode:function(e){if(!e)return"";if("string"!=typeof e)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(e))}}},Wn.convertCueToDOMTree=function(e,t){return e&&t?In(e,t):null};Wn.processCues=function(i,r,e){if(!i||!r||!e)return null;for(;e.firstChild;)e.removeChild(e.firstChild);var s=i.document.createElement("div");if(s.style.position="absolute",s.style.left="0",s.style.right="0",s.style.top="0",s.style.bottom="0",s.style.margin="1.5%",e.appendChild(s),function(e){for(var t=0;t',className:this.buildCSSClass(),tabIndex:0},t),"button"===e&&g.error("Creating a ClickableComponent with an HTML element of "+e+" is not supported; use a Button instead."),n=_({role:"button"},n),this.tabIndex_=t.tabIndex;var i=r.prototype.createEl.call(this,e,t,n);return this.createControlTextEl(i),i},t.dispose=function(){this.controlTextEl_=null,r.prototype.dispose.call(this)},t.createControlTextEl=function(e){return this.controlTextEl_=x("span",{className:"vjs-control-text"},{"aria-live":"polite"}),e&&e.appendChild(this.controlTextEl_),this.controlText(this.controlText_,e),this.controlTextEl_},t.controlText=function(e,t){if(void 0===t&&(t=this.el()),void 0===e)return this.controlText_||"Need Text";var n=this.localize(e);this.controlText_=e,j(this.controlTextEl_,n),this.nonIconControl||t.setAttribute("title",n)},t.buildCSSClass=function(){return"vjs-control vjs-button "+r.prototype.buildCSSClass.call(this)},t.enable=function(){this.enabled_||(this.enabled_=!0,this.removeClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","false"),"undefined"!=typeof this.tabIndex_&&this.el_.setAttribute("tabIndex",this.tabIndex_),this.on(["tap","click"],this.handleClick),this.on("keydown",this.handleKeyDown))},t.disable=function(){this.enabled_=!1,this.addClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","true"),"undefined"!=typeof this.tabIndex_&&this.el_.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("keydown",this.handleKeyDown)},t.handleClick=function(e){},t.handleKeyDown=function(e){Pt.isEventKey(e,"Space")||Pt.isEventKey(e,"Enter")?(e.preventDefault(),e.stopPropagation(),this.trigger("click")):r.prototype.handleKeyDown.call(this,e)},e}(Fe);Fe.registerComponent("ClickableComponent",vi);var gi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).update(),e.on("posterchange",Ce(v(v(n)),n.update)),n}f(e,i);var t=e.prototype;return t.dispose=function(){this.player().off("posterchange",this.update),i.prototype.dispose.call(this)},t.createEl=function(){return x("div",{className:"vjs-poster",tabIndex:-1})},t.update=function(e){var t=this.player().poster();this.setSrc(t),t?this.show():this.hide()},t.setSrc=function(e){var t="";e&&(t='url("'+e+'")'),this.el_.style.backgroundImage=t},t.handleClick=function(e){this.player_.controls()&&(this.player_.tech(!0).focus(),this.player_.paused()?wt(this.player_.play()):this.player_.pause())},e}(vi);Fe.registerComponent("PosterImage",gi);var yi="#222",mi={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function _i(e,t){var n;if(4===e.length)n=e[1]+e[1]+e[2]+e[2]+e[3]+e[3];else{if(7!==e.length)throw new Error("Invalid color code provided, "+e+"; must be formatted as e.g. #f0e or #f604e2.");n=e.slice(1)}return"rgba("+parseInt(n.slice(0,2),16)+","+parseInt(n.slice(2,4),16)+","+parseInt(n.slice(4,6),16)+","+t+")"}function bi(e,t,n){try{e.style[t]=n}catch(e){return}}var Ti=function(s){function e(n,e,t){var i;i=s.call(this,n,e,t)||this;var r=Ce(v(v(i)),i.updateDisplay);return n.on("loadstart",Ce(v(v(i)),i.toggleDisplay)),n.on("texttrackchange",r),n.on("loadedmetadata",Ce(v(v(i)),i.preselectTrack)),n.ready(Ce(v(v(i)),function(){if(n.tech_&&n.tech_.featuresNativeTextTracks)this.hide();else{n.on("fullscreenchange",r),n.on("playerresize",r),h.addEventListener("orientationchange",r),n.on("dispose",function(){return h.removeEventListener("orientationchange",r)});for(var e=this.options_.playerOptions.tracks||[],t=0;t',className:this.buildCSSClass()},t),n=_({type:"button"},n);var i=Fe.prototype.createEl.call(this,"button",t,n);return this.createControlTextEl(i),i},n.addChild=function(e,t){void 0===t&&(t={});var n=this.constructor.name;return g.warn("Adding an actionable (user controllable) child to a Button ("+n+") is not supported; use a ClickableComponent instead."),Fe.prototype.addChild.call(this,e,t)},n.enable=function(){t.prototype.enable.call(this),this.el_.removeAttribute("disabled")},n.disable=function(){t.prototype.disable.call(this),this.el_.setAttribute("disabled","disabled")},n.handleKeyDown=function(e){Pt.isEventKey(e,"Space")||Pt.isEventKey(e,"Enter")?e.stopPropagation():t.prototype.handleKeyDown.call(this,e)},e}(vi);Fe.registerComponent("Button",Ci);var Ei=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).mouseused_=!1,n.on("mousedown",n.handleMouseDown),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-big-play-button"},t.handleClick=function(e){var t=this.player_.play();if(this.mouseused_&&e.clientX&&e.clientY)return wt(t),void this.player_.tech(!0).focus();var n=this.player_.getChild("controlBar"),i=n&&n.getChild("playToggle");if(i){var r=function(){return i.focus()};Et(t)?t.then(r,function(){}):this.setTimeout(r,1)}else this.player_.tech(!0).focus()},t.handleKeyDown=function(e){this.mouseused_=!1,i.prototype.handleKeyDown.call(this,e)},t.handleMouseDown=function(e){this.mouseused_=!0},e}(Ci);Ei.prototype.controlText_="Play Video",Fe.registerComponent("BigPlayButton",Ei);var wi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).controlText(t&&t.controlText||n.localize("Close")),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-close-button "+i.prototype.buildCSSClass.call(this)},t.handleClick=function(e){this.trigger({type:"close",bubbles:!1})},e}(Ci);Fe.registerComponent("CloseButton",wi);var Si=function(i){function e(e,t){var n;return void 0===t&&(t={}),n=i.call(this,e,t)||this,t.replay=void 0===t.replay||t.replay,n.on(e,"play",n.handlePlay),n.on(e,"pause",n.handlePause),t.replay&&n.on(e,"ended",n.handleEnded),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-play-control "+i.prototype.buildCSSClass.call(this)},t.handleClick=function(e){this.player_.paused()?this.player_.play():this.player_.pause()},t.handleSeeked=function(e){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(e):this.handlePlay(e)},t.handlePlay=function(e){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},t.handlePause=function(e){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},t.handleEnded=function(e){this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.controlText("Replay"),this.one(this.player_,"seeked",this.handleSeeked)},e}(Ci);Si.prototype.controlText_="Play",Fe.registerComponent("PlayToggle",Si);var xi=function(e,t){e=e<0?0:e;var n=Math.floor(e%60),i=Math.floor(e/60%60),r=Math.floor(e/3600),s=Math.floor(t/60%60),o=Math.floor(t/3600);return(isNaN(e)||e===1/0)&&(r=i=n="-"),(r=0'+this.localize(this.labelText_)+" "});return this.contentEl_=x("span",{className:e+"-display"},{"aria-live":"off",role:"presentation"}),this.updateTextNode_(),t.appendChild(this.contentEl_),t},t.dispose=function(){this.contentEl_=null,this.textNode_=null,i.prototype.dispose.call(this)},t.updateTextNode_=function(){if(this.contentEl_){for(;this.contentEl_.firstChild;)this.contentEl_.removeChild(this.contentEl_.firstChild);this.textNode_=d.createTextNode(this.formattedTime_||this.formatTime_(0)),this.contentEl_.appendChild(this.textNode_)}},t.formatTime_=function(e){return Ai(e)},t.updateFormattedTime_=function(e){var t=this.formatTime_(e);t!==this.formattedTime_&&(this.formattedTime_=t,this.requestAnimationFrame(this.updateTextNode_))},t.updateContent=function(e){},e}(Fe);Pi.prototype.labelText_="Time",Pi.prototype.controlText_="Time",Fe.registerComponent("TimeDisplay",Pi);var Mi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).on(e,"ended",n.handleEnded),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-current-time"},t.updateContent=function(e){var t=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();this.updateFormattedTime_(t)},t.handleEnded=function(e){this.player_.duration()&&this.updateFormattedTime_(this.player_.duration())},e}(Pi);Mi.prototype.labelText_="Current Time",Mi.prototype.controlText_="Current Time",Fe.registerComponent("CurrentTimeDisplay",Mi);var Li=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).on(e,"durationchange",n.updateContent),n.on(e,"loadstart",n.updateContent),n.on(e,"loadedmetadata",n.throttledUpdateContent),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-duration"},t.updateContent=function(e){var t=this.player_.duration();this.duration_!==t&&(this.duration_=t,this.updateFormattedTime_(t))},e}(Pi);Li.prototype.labelText_="Duration",Li.prototype.controlText_="Duration",Fe.registerComponent("DurationDisplay",Li);var Ni=function(e){function t(){return e.apply(this,arguments)||this}return f(t,e),t.prototype.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"/
"},{"aria-hidden":!0})},t}(Fe);Fe.registerComponent("TimeDivider",Ni);var Di=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).on(e,"durationchange",n.throttledUpdateContent),n.on(e,"ended",n.handleEnded),n}f(e,i);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-remaining-time"},t.createEl=function(){var e=i.prototype.createEl.call(this);return e.insertBefore(x("span",{},{"aria-hidden":!0},"-"),this.contentEl_),e},t.updateContent=function(e){"number"==typeof this.player_.duration()&&(this.player_.remainingTimeDisplay?this.updateFormattedTime_(this.player_.remainingTimeDisplay()):this.updateFormattedTime_(this.player_.remainingTime()))},t.handleEnded=function(e){this.player_.duration()&&this.updateFormattedTime_(0)},e}(Pi);Di.prototype.labelText_="Remaining Time",Di.prototype.controlText_="Remaining Time",Fe.registerComponent("RemainingTimeDisplay",Di);var Oi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).updateShowing(),n.on(n.player(),"durationchange",n.updateShowing),n}f(e,i);var t=e.prototype;return t.createEl=function(){var e=i.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.contentEl_=x("div",{className:"vjs-live-display",innerHTML:''+this.localize("Stream Type")+" "+this.localize("LIVE")},{"aria-live":"off"}),e.appendChild(this.contentEl_),e},t.dispose=function(){this.contentEl_=null,i.prototype.dispose.call(this)},t.updateShowing=function(e){this.player().duration()===1/0?this.show():this.hide()},e}(Fe);Fe.registerComponent("LiveDisplay",Oi);var Ii=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).updateLiveEdgeStatus(),n.player_.liveTracker&&n.on(n.player_.liveTracker,"liveedgechange",n.updateLiveEdgeStatus),n}f(e,i);var t=e.prototype;return t.createEl=function(){var e=i.prototype.createEl.call(this,"button",{className:"vjs-seek-to-live-control vjs-control"});return this.textEl_=x("span",{className:"vjs-seek-to-live-text",innerHTML:this.localize("LIVE")},{"aria-hidden":"true"}),e.appendChild(this.textEl_),e},t.updateLiveEdgeStatus=function(e){!this.player_.liveTracker||this.player_.liveTracker.atLiveEdge()?(this.setAttribute("aria-disabled",!0),this.addClass("vjs-at-live-edge"),this.controlText("Seek to live, currently playing live")):(this.setAttribute("aria-disabled",!1),this.removeClass("vjs-at-live-edge"),this.controlText("Seek to live, currently behind live"))},t.handleClick=function(){this.player_.liveTracker.seekToLiveEdge()},t.dispose=function(){this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatus),this.textEl_=null,i.prototype.dispose.call(this)},e}(Ci);Ii.prototype.controlText_="Seek to live, currently playing live",Fe.registerComponent("SeekToLive",Ii);var Ri=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).bar=n.getChild(n.options_.barName),n.vertical(!!n.options_.vertical),n.enable(),n}f(e,i);var t=e.prototype;return t.enabled=function(){return this.enabled_},t.enable=function(){this.enabled()||(this.on("mousedown",this.handleMouseDown),this.on("touchstart",this.handleMouseDown),this.on("keydown",this.handleKeyDown),this.on("click",this.handleClick),this.on(this.player_,"controlsvisible",this.update),this.playerEvent&&this.on(this.player_,this.playerEvent,this.update),this.removeClass("disabled"),this.setAttribute("tabindex",0),this.enabled_=!0)},t.disable=function(){if(this.enabled()){var e=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown),this.off("touchstart",this.handleMouseDown),this.off("keydown",this.handleKeyDown),this.off("click",this.handleClick),this.off(this.player_,"controlsvisible",this.update),this.off(e,"mousemove",this.handleMouseMove),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchmove",this.handleMouseMove),this.off(e,"touchend",this.handleMouseUp),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}},t.createEl=function(e,t,n){return void 0===t&&(t={}),void 0===n&&(n={}),t.className=t.className+" vjs-slider",t=_({tabIndex:0},t),n=_({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},n),i.prototype.createEl.call(this,e,t,n)},t.handleMouseDown=function(e){var t=this.bar.el_.ownerDocument;"mousedown"===e.type&&e.preventDefault(),"touchstart"!==e.type||it||e.preventDefault(),F(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(t,"mousemove",this.handleMouseMove),this.on(t,"mouseup",this.handleMouseUp),this.on(t,"touchmove",this.handleMouseMove),this.on(t,"touchend",this.handleMouseUp),this.handleMouseMove(e)},t.handleMouseMove=function(e){},t.handleMouseUp=function(){var e=this.bar.el_.ownerDocument;H(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(e,"mousemove",this.handleMouseMove),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchmove",this.handleMouseMove),this.off(e,"touchend",this.handleMouseUp),this.update()},t.update=function(){if(this.el_){var e=this.getPercent(),t=this.bar;if(t){("number"!=typeof e||e!=e||e<0||e===1/0)&&(e=0);var n=(100*e).toFixed(2)+"%",i=t.el().style;return this.vertical()?i.height=n:i.width=n,e}}},t.calculateDistance=function(e){var t=W(this.el_,e);return this.vertical()?t.y:t.x},t.handleKeyDown=function(e){Pt.isEventKey(e,"Left")||Pt.isEventKey(e,"Down")?(e.preventDefault(),e.stopPropagation(),this.stepBack()):Pt.isEventKey(e,"Right")||Pt.isEventKey(e,"Up")?(e.preventDefault(),e.stopPropagation(),this.stepForward()):i.prototype.handleKeyDown.call(this,e)},t.handleClick=function(e){e.stopPropagation(),e.preventDefault()},t.vertical=function(e){if(void 0===e)return this.vertical_||!1;this.vertical_=!!e,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")},e}(Fe);Fe.registerComponent("Slider",Ri);var Bi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).partEls_=[],n.on(e,"progress",n.update),n}f(e,i);var t=e.prototype;return t.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-load-progress",innerHTML:''+this.localize("Loaded")+': 0%'})},t.dispose=function(){this.partEls_=null,i.prototype.dispose.call(this)},t.update=function(e){var t=this.player_.liveTracker,n=this.player_.buffered(),i=t&&t.isLive()?t.seekableEnd():this.player_.duration(),r=this.player_.bufferedEnd(),s=this.partEls_,o=this.$(".vjs-control-text-loaded-percentage"),a=function(e,t,n){var i=e/t||0;return i=100*(1<=i?1:i),n&&(i=i.toFixed(2)),i+"%"};this.el_.style.width=a(r,i),j(o,a(r,i,!0));for(var l=0;ln.length;d--)this.el_.removeChild(s[d-1]);s.length=n.length},e}(Fe);Fe.registerComponent("LoadProgressBar",Bi);var Fi=function(e){function t(){return e.apply(this,arguments)||this}f(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})},n.update=function(e,t,n){var i=V(this.el_),r=V(this.player_.el()),s=e.width*t;if(r&&i){var o=e.left-r.left+s,a=e.width-s+(r.right-e.right),l=i.width/2;oi.width&&(l=i.width),this.el_.style.right="-"+l+"px",j(this.el_,n)}},n.updateTime=function(r,s,o,a){var l=this;this.rafId_&&this.cancelAnimationFrame(this.rafId_),this.rafId_=this.requestAnimationFrame(function(){var e,t=l.player_.duration();if(l.player_.liveTracker&&l.player_.liveTracker.isLive()){var n=l.player_.liveTracker.liveWindow(),i=n-s*n;e=(i<1?"":"-")+Ai(i,n)}else e=Ai(o,t);l.update(r,s,e),a&&a()})},t}(Fe);Fe.registerComponent("TimeTooltip",Fi);var Hi=function(e){function t(){return e.apply(this,arguments)||this}f(t,e);var n=t.prototype;return n.createEl=function(){return e.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})},n.update=function(e,t){var n=this.getChild("timeTooltip");if(n){var i=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();n.updateTime(e,t,i)}},t}(Fe);Hi.prototype.options_={children:[]},Ge||Je||Hi.prototype.options_.children.push("timeTooltip"),Fe.registerComponent("PlayProgressBar",Hi);var Vi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).update=Ee(Ce(v(v(n)),n.update),25),n}f(e,i);var t=e.prototype;return t.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},t.update=function(e,t){var n=this,i=t*this.player_.duration();this.getChild("timeTooltip").updateTime(e,t,i,function(){n.el_.style.left=e.width*t+"px"})},e}(Fe);Vi.prototype.options_={children:["timeTooltip"]},Fe.registerComponent("MouseTimeDisplay",Vi);var zi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).setEventHandlers_(),n}f(e,i);var t=e.prototype;return t.setEventHandlers_=function(){this.update=Ee(Ce(this,this.update),30),this.on(this.player_,"timeupdate",this.update),this.on(this.player_,"ended",this.handleEnded),this.on(this.player_,"durationchange",this.update),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.on(this.player_,["playing"],this.enableInterval_),this.on(this.player_,["ended","pause","waiting"],this.disableInterval_),"hidden"in d&&"visibilityState"in d&&this.on(d,"visibilitychange",this.toggleVisibility_)},t.toggleVisibility_=function(e){d.hidden?this.disableInterval_(e):(this.enableInterval_(),this.requestAnimationFrame(this.update))},t.enableInterval_=function(){var e=this;this.clearInterval(this.updateInterval),this.updateInterval=this.setInterval(function(){e.requestAnimationFrame(e.update)},30)},t.disableInterval_=function(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&"ended"!==e.type||this.clearInterval(this.updateInterval)},t.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})},t.update_=function(e,t){var n=this.player_.liveTracker,i=this.player_.duration();n&&n.isLive()&&(i=this.player_.liveTracker.liveCurrentTime()),this.el_.setAttribute("aria-valuenow",(100*t).toFixed(2)),this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[Ai(e,i),Ai(i,i)],"{1} of {2}")),this.bar&&this.bar.update(V(this.el_),t)},t.update=function(e){if(null!==this.el().offsetParent){var t=i.prototype.update.call(this);return this.update_(this.getCurrentTime_(),t),t}},t.getCurrentTime_=function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()},t.handleEnded=function(e){this.update_(this.player_.duration(),1)},t.getPercent=function(){var e,t=this.getCurrentTime_(),n=this.player_.liveTracker;return n&&n.isLive()?(e=(t-n.seekableStart())/n.liveWindow(),n.atLiveEdge()&&(e=1)):e=t/this.player_.duration(),1<=e?1:e||0},t.handleMouseDown=function(e){Y(e)&&(e.stopPropagation(),this.player_.scrubbing(!0),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),i.prototype.handleMouseDown.call(this,e))},t.handleMouseMove=function(e){if(Y(e)){var t,n=this.calculateDistance(e),i=this.player_.liveTracker;if(i&&i.isLive()){var r=i.seekableStart(),s=i.liveCurrentTime();if(s<=(t=r+n*i.liveWindow())&&(t=s),t<=r&&(t=r+.1),t===1/0)return}else(t=n*this.player_.duration())===this.player_.duration()&&(t-=.1);this.player_.currentTime(t)}},t.enable=function(){i.prototype.enable.call(this);var e=this.getChild("mouseTimeDisplay");e&&e.show()},t.disable=function(){i.prototype.disable.call(this);var e=this.getChild("mouseTimeDisplay");e&&e.hide()},t.handleMouseUp=function(e){i.prototype.handleMouseUp.call(this,e),e&&e.stopPropagation(),this.player_.scrubbing(!1),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying&&wt(this.player_.play())},t.stepForward=function(){this.player_.currentTime(this.player_.currentTime()+5)},t.stepBack=function(){this.player_.currentTime(this.player_.currentTime()-5)},t.handleAction=function(e){this.player_.paused()?this.player_.play():this.player_.pause()},t.handleKeyDown=function(e){if(Pt.isEventKey(e,"Space")||Pt.isEventKey(e,"Enter"))e.preventDefault(),e.stopPropagation(),this.handleAction(e);else if(Pt.isEventKey(e,"Home"))e.preventDefault(),e.stopPropagation(),this.player_.currentTime(0);else if(Pt.isEventKey(e,"End"))e.preventDefault(),e.stopPropagation(),this.player_.currentTime(this.player_.duration());else if(/^[0-9]$/.test(Pt(e))){e.preventDefault(),e.stopPropagation();var t=10*(Pt.codes[Pt(e)]-Pt.codes[0])/100;this.player_.currentTime(this.player_.duration()*t)}else Pt.isEventKey(e,"PgDn")?(e.preventDefault(),e.stopPropagation(),this.player_.currentTime(this.player_.currentTime()-60)):Pt.isEventKey(e,"PgUp")?(e.preventDefault(),e.stopPropagation(),this.player_.currentTime(this.player_.currentTime()+60)):i.prototype.handleKeyDown.call(this,e)},e}(Ri);zi.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"},Ge||Je||zi.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Fe.registerComponent("SeekBar",zi);var Wi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).handleMouseMove=Ee(Ce(v(v(n)),n.handleMouseMove),25),n.throttledHandleMouseSeek=Ee(Ce(v(v(n)),n.handleMouseSeek),25),n.enable(),n}f(e,i);var t=e.prototype;return t.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},t.handleMouseMove=function(e){var t=this.getChild("seekBar");if(t){var n=t.getChild("mouseTimeDisplay"),i=t.el(),r=V(i),s=W(i,e).x;1'})},t}(Fe);Fe.registerComponent("VolumeLevel",Ui);var qi=function(i){function e(e,t){var n;return(n=i.call(this,e,t)||this).on("slideractive",n.updateLastVolume_),n.on(e,"volumechange",n.updateARIAAttributes),e.ready(function(){return n.updateARIAAttributes()}),n}f(e,i);var t=e.prototype;return t.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})},t.handleMouseDown=function(e){Y(e)&&i.prototype.handleMouseDown.call(this,e)},t.handleMouseMove=function(e){Y(e)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(e)))},t.checkMuted=function(){this.player_.muted()&&this.player_.muted(!1)},t.getPercent=function(){return this.player_.muted()?0:this.player_.volume()},t.stepForward=function(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)},t.stepBack=function(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)},t.updateARIAAttributes=function(e){var t=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",t),this.el_.setAttribute("aria-valuetext",t+"%")},t.volumeAsPercentage_=function(){return Math.round(100*this.player_.volume())},t.updateLastVolume_=function(){var e=this,t=this.player_.volume();this.one("sliderinactive",function(){0===e.player_.volume()&&e.player_.lastVolume_(t)})},e}(Ri);qi.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"},qi.prototype.playerEvent="volumechange",Fe.registerComponent("VolumeBar",qi);var Xi=function(s){function e(e,t){var n,i,r;return void 0===t&&(t={}),t.vertical=t.vertical||!1,("undefined"==typeof t.volumeBar||c(t.volumeBar))&&(t.volumeBar=t.volumeBar||{},t.volumeBar.vertical=t.vertical),n=s.call(this,e,t)||this,i=v(v(n)),(r=e).tech_&&!r.tech_.featuresVolumeControl&&i.addClass("vjs-hidden"),i.on(r,"loadstart",function(){r.tech_.featuresVolumeControl?i.removeClass("vjs-hidden"):i.addClass("vjs-hidden")}),n.throttledHandleMouseMove=Ee(Ce(v(v(n)),n.handleMouseMove),25),n.on("mousedown",n.handleMouseDown),n.on("touchstart",n.handleMouseDown),n.on(n.volumeBar,["focus","slideractive"],function(){n.volumeBar.addClass("vjs-slider-active"),n.addClass("vjs-slider-active"),n.trigger("slideractive")}),n.on(n.volumeBar,["blur","sliderinactive"],function(){n.volumeBar.removeClass("vjs-slider-active"),n.removeClass("vjs-slider-active"),n.trigger("sliderinactive")}),n}f(e,s);var t=e.prototype;return t.createEl=function(){var e="vjs-volume-horizontal";return this.options_.vertical&&(e="vjs-volume-vertical"),s.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control "+e})},t.handleMouseDown=function(e){var t=this.el_.ownerDocument;this.on(t,"mousemove",this.throttledHandleMouseMove),this.on(t,"touchmove",this.throttledHandleMouseMove),this.on(t,"mouseup",this.handleMouseUp),this.on(t,"touchend",this.handleMouseUp)},t.handleMouseUp=function(e){var t=this.el_.ownerDocument;this.off(t,"mousemove",this.throttledHandleMouseMove),this.off(t,"touchmove",this.throttledHandleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchend",this.handleMouseUp)},t.handleMouseMove=function(e){this.volumeBar.handleMouseMove(e)},e}(Fe);Xi.prototype.options_={children:["volumeBar"]},Fe.registerComponent("VolumeControl",Xi);var $i=function(s){function e(e,t){var n,i,r;return n=s.call(this,e,t)||this,i=v(v(n)),(r=e).tech_&&!r.tech_.featuresMuteControl&&i.addClass("vjs-hidden"),i.on(r,"loadstart",function(){r.tech_.featuresMuteControl?i.removeClass("vjs-hidden"):i.addClass("vjs-hidden")}),n.on(e,["loadstart","volumechange"],n.update),n}f(e,s);var t=e.prototype;return t.buildCSSClass=function(){return"vjs-mute-control "+s.prototype.buildCSSClass.call(this)},t.handleClick=function(e){var t=this.player_.volume(),n=this.player_.lastVolume_();if(0===t){var i=n<.1?.1:n;this.player_.volume(i),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())},t.update=function(e){this.updateIcon_(),this.updateControlText_()},t.updateIcon_=function(){var e=this.player_.volume(),t=3;Ge&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),0===e||this.player_.muted()?t=0:e<.33?t=1:e<.67&&(t=2);for(var n=0;n<4;n++)L(this.el_,"vjs-vol-"+n);M(this.el_,"vjs-vol-"+t)},t.updateControlText_=function(){var e=this.player_.muted()||0===this.player_.volume()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e)},e}(Ci);$i.prototype.controlText_="Mute",Fe.registerComponent("MuteToggle",$i);var Yi=function(i){function e(e,t){var n;return void 0===t&&(t={}),"undefined"!=typeof t.inline?t.inline=t.inline:t.inline=!0,("undefined"==typeof t.volumeControl||c(t.volumeControl))&&(t.volumeControl=t.volumeControl||{},t.volumeControl.vertical=!t.inline),(n=i.call(this,e,t)||this).on(e,["loadstart"],n.volumePanelState_),n.on(n.volumeControl,["slideractive"],n.sliderActive_),n.on(n.volumeControl,["sliderinactive"],n.sliderInactive_),n}f(e,i);var t=e.prototype;return t.sliderActive_=function(){this.addClass("vjs-slider-active")},t.sliderInactive_=function(){this.removeClass("vjs-slider-active")},t.volumePanelState_=function(){this.volumeControl.hasClass("vjs-hidden")&&this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-hidden"),this.volumeControl.hasClass("vjs-hidden")&&!this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-mute-toggle-only")},t.createEl=function(){var e="vjs-volume-panel-horizontal";return this.options_.inline||(e="vjs-volume-panel-vertical"),i.prototype.createEl.call(this,"div",{className:"vjs-volume-panel vjs-control "+e})},e}(Fe);Yi.prototype.options_={children:["muteToggle","volumeControl"]},Fe.registerComponent("VolumePanel",Yi);var Gi=function(i){function e(e,t){var n;return n=i.call(this,e,t)||this,t&&(n.menuButton_=t.menuButton),n.focusedChild_=-1,n.on("keydown",n.handleKeyDown),n.boundHandleBlur_=Ce(v(v(n)),n.handleBlur),n.boundHandleTapClick_=Ce(v(v(n)),n.handleTapClick),n}f(e,i);var t=e.prototype;return t.addEventListenerForItem=function(e){e instanceof Fe&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))},t.removeEventListenerForItem=function(e){e instanceof Fe&&(this.off(e,"blur",this.boundHandleBlur_),this.off(e,["tap","click"],this.boundHandleTapClick_))},t.removeChild=function(e){"string"==typeof e&&(e=this.getChild(e)),this.removeEventListenerForItem(e),i.prototype.removeChild.call(this,e)},t.addItem=function(e){var t=this.addChild(e);t&&this.addEventListenerForItem(t)},t.createEl=function(){var e=this.options_.contentElType||"ul";this.contentEl_=x(e,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");var t=i.prototype.createEl.call(this,"div",{append:this.contentEl_,className:"vjs-menu"});return t.appendChild(this.contentEl_),he(t,"click",function(e){e.preventDefault(),e.stopImmediatePropagation()}),t},t.dispose=function(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,i.prototype.dispose.call(this)},t.handleBlur=function(e){var t=e.relatedTarget||d.activeElement;if(!this.children().some(function(e){return e.el()===t})){var n=this.menuButton_;n&&n.buttonPressed_&&t!==n.el().firstChild&&n.unpressButton()}},t.handleTapClick=function(t){if(this.menuButton_){this.menuButton_.unpressButton();var e=this.children();if(!Array.isArray(e))return;var n=e.filter(function(e){return e.el()===t.target})[0];if(!n)return;"CaptionSettingsMenuItem"!==n.name()&&this.menuButton_.focus()}},t.handleKeyDown=function(e){Pt.isEventKey(e,"Left")||Pt.isEventKey(e,"Down")?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(Pt.isEventKey(e,"Right")||Pt.isEventKey(e,"Up"))&&(e.preventDefault(),e.stopPropagation(),this.stepBack())},t.stepForward=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_+1),this.focus(e)},t.stepBack=function(){var e=0;void 0!==this.focusedChild_&&(e=this.focusedChild_-1),this.focus(e)},t.focus=function(e){void 0===e&&(e=0);var t=this.children().slice();t.length&&t[0].className&&/vjs-menu-title/.test(t[0].className)&&t.shift(),0=t.length&&(e=t.length-1),t[this.focusedChild_=e].el_.focus())},e}(Fe);Fe.registerComponent("Menu",Gi);var Qi=function(r){function e(e,t){var n;void 0===t&&(t={}),(n=r.call(this,e,t)||this).menuButton_=new Ci(e,t),n.menuButton_.controlText(n.controlText_),n.menuButton_.el_.setAttribute("aria-haspopup","true");var i=Ci.prototype.buildCSSClass();return n.menuButton_.el_.className=n.buildCSSClass()+" "+i,n.menuButton_.removeClass("vjs-control"),n.addChild(n.menuButton_),n.update(),n.enabled_=!0,n.on(n.menuButton_,"tap",n.handleClick),n.on(n.menuButton_,"click",n.handleClick),n.on(n.menuButton_,"keydown",n.handleKeyDown),n.on(n.menuButton_,"mouseenter",function(){n.menu.show()}),n.on("keydown",n.handleSubmenuKeyDown),n}f(e,r);var t=e.prototype;return t.update=function(){var e=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=e,this.addChild(e),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?this.hide():this.show()},t.createMenu=function(){var e=new Gi(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var t=x("li",{className:"vjs-menu-title",innerHTML:Re(this.options_.title),tabIndex:-1});this.hideThreshold_+=1;var n=new Fe(this.player_,{el:t});e.addItem(n)}if(this.items=this.createItems(),this.items)for(var i=0;i