@clickview/player 0.0.4-rc.1 → 0.0.4-rc.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/libs/analytics/src/clients/CollectionApiClient.d.ts +0 -3
- package/dist/libs/analytics/src/constants/Regions.d.ts +1 -0
- package/dist/libs/analytics/src/enums/CountryCode.d.ts +2 -1
- package/dist/libs/analytics/src/enums/RegionName.d.ts +2 -1
- package/dist/libs/analytics/src/interfaces/Region.d.ts +0 -1
- package/dist/libs/analytics/src/interfaces/RegionalUrl.d.ts +1 -0
- package/dist/libs/analytics/src/interfaces/User.d.ts +2 -0
- package/dist/libs/shared/src/enums/CountryCode.d.ts +2 -1
- package/dist/libs/shared/src/interfaces/RegionalUrl.d.ts +1 -0
- package/dist/libs/shared/src/interfaces/models/Config.d.ts +9 -1
- package/dist/libs/shared/src/interfaces/models/Customer.d.ts +3 -1
- package/dist/libs/shared/src/interfaces/models/User.d.ts +33 -1
- package/dist/player-app.js +2 -2
- package/package.json +70 -70
- package/dist/libs/analytics/src/constants/CountryRegionMapping.d.ts +0 -7
package/dist/player-app.js
CHANGED
|
@@ -43,7 +43,7 @@ var n="undefined"!=typeof window&&"undefined"!=typeof document&&"undefined"!=typ
|
|
|
43
43
|
object-assign
|
|
44
44
|
(c) Sindre Sorhus
|
|
45
45
|
@license MIT
|
|
46
|
-
*/var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,s,u=a(e),l=1;l<arguments.length;l++){for(var c in n=Object(arguments[l]))i.call(n,c)&&(u[c]=n[c]);if(r){s=r(n);for(var f=0;f<s.length;f++)o.call(n,s[f])&&(u[s[f]]=n[s[f]])}}return u}},function(e,t){function n(e,t){for(var n in e)t[n]=e[n]}function r(e,t){var r=e.prototype;if(Object.create){var i=Object.create(t.prototype);r.__proto__=i}if(!(r instanceof t)){function o(){}o.prototype=t.prototype,n(r,o=new o),e.prototype=r=o}r.constructor!=e&&("function"!=typeof e&&console.error("unknow Class:"+e),r.constructor=e)}var i={},o=i.ELEMENT_NODE=1,a=i.ATTRIBUTE_NODE=2,s=i.TEXT_NODE=3,u=i.CDATA_SECTION_NODE=4,l=i.ENTITY_REFERENCE_NODE=5,c=i.ENTITY_NODE=6,f=i.PROCESSING_INSTRUCTION_NODE=7,h=i.COMMENT_NODE=8,d=i.DOCUMENT_NODE=9,p=i.DOCUMENT_TYPE_NODE=10,y=i.DOCUMENT_FRAGMENT_NODE=11,m=i.NOTATION_NODE=12,g={},v={},b=(g.INDEX_SIZE_ERR=(v[1]="Index size error",1),g.DOMSTRING_SIZE_ERR=(v[2]="DOMString size error",2),g.HIERARCHY_REQUEST_ERR=(v[3]="Hierarchy request error",3)),_=(g.WRONG_DOCUMENT_ERR=(v[4]="Wrong document",4),g.INVALID_CHARACTER_ERR=(v[5]="Invalid character",5),g.NO_DATA_ALLOWED_ERR=(v[6]="No data allowed",6),g.NO_MODIFICATION_ALLOWED_ERR=(v[7]="No modification allowed",7),g.NOT_FOUND_ERR=(v[8]="Not found",8)),w=(g.NOT_SUPPORTED_ERR=(v[9]="Not supported",9),g.INUSE_ATTRIBUTE_ERR=(v[10]="Attribute in use",10));g.INVALID_STATE_ERR=(v[11]="Invalid state",11),g.SYNTAX_ERR=(v[12]="Syntax error",12),g.INVALID_MODIFICATION_ERR=(v[13]="Invalid modification",13),g.NAMESPACE_ERR=(v[14]="Invalid namespace",14),g.INVALID_ACCESS_ERR=(v[15]="Invalid access",15);function T(e,t){if(t instanceof Error)var n=t;else n=this,Error.call(this,v[e]),this.message=v[e],Error.captureStackTrace&&Error.captureStackTrace(this,T);return n.code=e,t&&(this.message=this.message+": "+t),n}function S(){}function E(e,t){this._node=e,this._refresh=t,C(this)}function C(e){var t=e._node._inc||e._node.ownerDocument._inc;if(e._inc!=t){var r=e._refresh(e._node);te(e,"length",r.length),n(r,e),e._inc=t}}function k(){}function x(e,t){for(var n=e.length;n--;)if(e[n]===t)return n}function O(e,t,n,r){if(r?t[x(t,r)]=n:t[t.length++]=n,e){n.ownerElement=e;var i=e.ownerDocument;i&&(r&&D(i,e,r),function(e,t,n){e&&e._inc++,"http://www.w3.org/2000/xmlns/"==n.namespaceURI&&(t._nsMap[n.prefix?n.localName:""]=n.value)}(i,e,n))}}function P(e,t,n){var r=x(t,n);if(!(r>=0))throw T(_,new Error(e.tagName+"@"+n));for(var i=t.length-1;r<i;)t[r]=t[++r];if(t.length=i,e){var o=e.ownerDocument;o&&(D(o,e,n),n.ownerElement=null)}}function R(e){if(this._features={},e)for(var t in e)this._features=e[t]}function A(){}function I(e){return("<"==e?"<":">"==e&&">")||"&"==e&&"&"||'"'==e&&"""||"&#"+e.charCodeAt()+";"}function L(e,t){if(t(e))return!0;if(e=e.firstChild)do{if(L(e,t))return!0}while(e=e.nextSibling)}function j(){}function D(e,t,n,r){e&&e._inc++,"http://www.w3.org/2000/xmlns/"==n.namespaceURI&&delete t._nsMap[n.prefix?n.localName:""]}function N(e,t,n){if(e&&e._inc){e._inc++;var r=t.childNodes;if(n)r[r.length++]=n;else{for(var i=t.firstChild,o=0;i;)r[o++]=i,i=i.nextSibling;r.length=o}}}function M(e,t){var n=t.previousSibling,r=t.nextSibling;return n?n.nextSibling=r:e.firstChild=r,r?r.previousSibling=n:e.lastChild=n,N(e.ownerDocument,e),t}function U(e,t,n){var r=t.parentNode;if(r&&r.removeChild(t),t.nodeType===y){var i=t.firstChild;if(null==i)return t;var o=t.lastChild}else i=o=t;var a=n?n.previousSibling:e.lastChild;i.previousSibling=a,o.nextSibling=n,a?a.nextSibling=i:e.firstChild=i,null==n?e.lastChild=o:n.previousSibling=o;do{i.parentNode=e}while(i!==o&&(i=i.nextSibling));return N(e.ownerDocument||e,e),t.nodeType==y&&(t.firstChild=t.lastChild=null),t}function B(){this._nsMap={}}function F(){}function V(){}function H(){}function z(){}function q(){}function W(){}function $(){}function G(){}function Y(){}function K(){}function X(){}function Q(){}function J(e,t){var n=[],r=9==this.nodeType?this.documentElement:this,i=r.prefix,o=r.namespaceURI;if(o&&null==i&&null==(i=r.lookupPrefix(o)))var a=[{namespace:o,prefix:null}];return ee(this,n,e,t,a),n.join("")}function Z(e,t,n){var r=e.prefix||"",i=e.namespaceURI;if(!r&&!i)return!1;if("xml"===r&&"http://www.w3.org/XML/1998/namespace"===i||"http://www.w3.org/2000/xmlns/"==i)return!1;for(var o=n.length;o--;){var a=n[o];if(a.prefix==r)return a.namespace!=i}return!0}function ee(e,t,n,r,i){if(r){if(!(e=r(e)))return;if("string"==typeof e)return void t.push(e)}switch(e.nodeType){case o:i||(i=[]);i.length;var c=e.attributes,m=c.length,g=e.firstChild,v=e.tagName;n="http://www.w3.org/1999/xhtml"===e.namespaceURI||n,t.push("<",v);for(var b=0;b<m;b++){"xmlns"==(_=c.item(b)).prefix?i.push({prefix:_.localName,namespace:_.value}):"xmlns"==_.nodeName&&i.push({prefix:"",namespace:_.value})}for(b=0;b<m;b++){var _;if(Z(_=c.item(b),0,i)){var w=_.prefix||"",T=_.namespaceURI,S=w?" xmlns:"+w:" xmlns";t.push(S,'="',T,'"'),i.push({prefix:w,namespace:T})}ee(_,t,n,r,i)}if(Z(e,0,i)){w=e.prefix||"",T=e.namespaceURI,S=w?" xmlns:"+w:" xmlns";t.push(S,'="',T,'"'),i.push({prefix:w,namespace:T})}if(g||n&&!/^(?:meta|link|img|br|hr|input)$/i.test(v)){if(t.push(">"),n&&/^script$/i.test(v))for(;g;)g.data?t.push(g.data):ee(g,t,n,r,i),g=g.nextSibling;else for(;g;)ee(g,t,n,r,i),g=g.nextSibling;t.push("</",v,">")}else t.push("/>");return;case d:case y:for(g=e.firstChild;g;)ee(g,t,n,r,i),g=g.nextSibling;return;case a:return t.push(" ",e.name,'="',e.value.replace(/[<&"]/g,I),'"');case s:return t.push(e.data.replace(/[<&]/g,I));case u:return t.push("<![CDATA[",e.data,"]]>");case h:return t.push("\x3c!--",e.data,"--\x3e");case p:var E=e.publicId,C=e.systemId;if(t.push("<!DOCTYPE ",e.name),E)t.push(' PUBLIC "',E),C&&"."!=C&&t.push('" "',C),t.push('">');else if(C&&"."!=C)t.push(' SYSTEM "',C,'">');else{var k=e.internalSubset;k&&t.push(" [",k,"]"),t.push(">")}return;case f:return t.push("<?",e.target," ",e.data,"?>");case l:return t.push("&",e.nodeName,";");default:t.push("??",e.nodeName)}}function te(e,t,n){e[t]=n}T.prototype=Error.prototype,n(g,T),S.prototype={length:0,item:function(e){return this[e]||null},toString:function(e,t){for(var n=[],r=0;r<this.length;r++)ee(this[r],n,e,t);return n.join("")}},E.prototype.item=function(e){return C(this),this[e]},r(E,S),k.prototype={length:0,item:S.prototype.item,getNamedItem:function(e){for(var t=this.length;t--;){var n=this[t];if(n.nodeName==e)return n}},setNamedItem:function(e){var t=e.ownerElement;if(t&&t!=this._ownerElement)throw new T(w);var n=this.getNamedItem(e.nodeName);return O(this._ownerElement,this,e,n),n},setNamedItemNS:function(e){var t,n=e.ownerElement;if(n&&n!=this._ownerElement)throw new T(w);return t=this.getNamedItemNS(e.namespaceURI,e.localName),O(this._ownerElement,this,e,t),t},removeNamedItem:function(e){var t=this.getNamedItem(e);return P(this._ownerElement,this,t),t},removeNamedItemNS:function(e,t){var n=this.getNamedItemNS(e,t);return P(this._ownerElement,this,n),n},getNamedItemNS:function(e,t){for(var n=this.length;n--;){var r=this[n];if(r.localName==t&&r.namespaceURI==e)return r}return null}},R.prototype={hasFeature:function(e,t){var n=this._features[e.toLowerCase()];return!(!n||t&&!(t in n))},createDocument:function(e,t,n){var r=new j;if(r.implementation=this,r.childNodes=new S,r.doctype=n,n&&r.appendChild(n),t){var i=r.createElementNS(e,t);r.appendChild(i)}return r},createDocumentType:function(e,t,n){var r=new W;return r.name=e,r.nodeName=e,r.publicId=t,r.systemId=n,r}},A.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(e,t){return U(this,e,t)},replaceChild:function(e,t){this.insertBefore(e,t),t&&this.removeChild(t)},removeChild:function(e){return M(this,e)},appendChild:function(e){return this.insertBefore(e,null)},hasChildNodes:function(){return null!=this.firstChild},cloneNode:function(e){return function e(t,n,r){var i=new n.constructor;for(var s in n){var u=n[s];"object"!=typeof u&&u!=i[s]&&(i[s]=u)}n.childNodes&&(i.childNodes=new S);switch(i.ownerDocument=t,i.nodeType){case o:var l=n.attributes,c=i.attributes=new k,f=l.length;c._ownerElement=i;for(var h=0;h<f;h++)i.setAttributeNode(e(t,l.item(h),!0));break;case a:r=!0}if(r)for(var d=n.firstChild;d;)i.appendChild(e(t,d,r)),d=d.nextSibling;return i}(this.ownerDocument||this,this,e)},normalize:function(){for(var e=this.firstChild;e;){var t=e.nextSibling;t&&t.nodeType==s&&e.nodeType==s?(this.removeChild(t),e.appendData(t.data)):(e.normalize(),e=t)}},isSupported:function(e,t){return this.ownerDocument.implementation.hasFeature(e,t)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(e){for(var t=this;t;){var n=t._nsMap;if(n)for(var r in n)if(n[r]==e)return r;t=t.nodeType==a?t.ownerDocument:t.parentNode}return null},lookupNamespaceURI:function(e){for(var t=this;t;){var n=t._nsMap;if(n&&e in n)return n[e];t=t.nodeType==a?t.ownerDocument:t.parentNode}return null},isDefaultNamespace:function(e){return null==this.lookupPrefix(e)}},n(i,A),n(i,A.prototype),j.prototype={nodeName:"#document",nodeType:d,doctype:null,documentElement:null,_inc:1,insertBefore:function(e,t){if(e.nodeType==y){for(var n=e.firstChild;n;){var r=n.nextSibling;this.insertBefore(n,t),n=r}return e}return null==this.documentElement&&e.nodeType==o&&(this.documentElement=e),U(this,e,t),e.ownerDocument=this,e},removeChild:function(e){return this.documentElement==e&&(this.documentElement=null),M(this,e)},importNode:function(e,t){return function e(t,n,r){var i;switch(n.nodeType){case o:(i=n.cloneNode(!1)).ownerDocument=t;case y:break;case a:r=!0}i||(i=n.cloneNode(!1));if(i.ownerDocument=t,i.parentNode=null,r)for(var s=n.firstChild;s;)i.appendChild(e(t,s,r)),s=s.nextSibling;return i}(this,e,t)},getElementById:function(e){var t=null;return L(this.documentElement,(function(n){if(n.nodeType==o&&n.getAttribute("id")==e)return t=n,!0})),t},createElement:function(e){var t=new B;return t.ownerDocument=this,t.nodeName=e,t.tagName=e,t.childNodes=new S,(t.attributes=new k)._ownerElement=t,t},createDocumentFragment:function(){var e=new K;return e.ownerDocument=this,e.childNodes=new S,e},createTextNode:function(e){var t=new H;return t.ownerDocument=this,t.appendData(e),t},createComment:function(e){var t=new z;return t.ownerDocument=this,t.appendData(e),t},createCDATASection:function(e){var t=new q;return t.ownerDocument=this,t.appendData(e),t},createProcessingInstruction:function(e,t){var n=new X;return n.ownerDocument=this,n.tagName=n.target=e,n.nodeValue=n.data=t,n},createAttribute:function(e){var t=new F;return t.ownerDocument=this,t.name=e,t.nodeName=e,t.localName=e,t.specified=!0,t},createEntityReference:function(e){var t=new Y;return t.ownerDocument=this,t.nodeName=e,t},createElementNS:function(e,t){var n=new B,r=t.split(":"),i=n.attributes=new k;return n.childNodes=new S,n.ownerDocument=this,n.nodeName=t,n.tagName=t,n.namespaceURI=e,2==r.length?(n.prefix=r[0],n.localName=r[1]):n.localName=t,i._ownerElement=n,n},createAttributeNS:function(e,t){var n=new F,r=t.split(":");return n.ownerDocument=this,n.nodeName=t,n.name=t,n.namespaceURI=e,n.specified=!0,2==r.length?(n.prefix=r[0],n.localName=r[1]):n.localName=t,n}},r(j,A),B.prototype={nodeType:o,hasAttribute:function(e){return null!=this.getAttributeNode(e)},getAttribute:function(e){var t=this.getAttributeNode(e);return t&&t.value||""},getAttributeNode:function(e){return this.attributes.getNamedItem(e)},setAttribute:function(e,t){var n=this.ownerDocument.createAttribute(e);n.value=n.nodeValue=""+t,this.setAttributeNode(n)},removeAttribute:function(e){var t=this.getAttributeNode(e);t&&this.removeAttributeNode(t)},appendChild:function(e){return e.nodeType===y?this.insertBefore(e,null):function(e,t){var n=t.parentNode;if(n){var r=e.lastChild;n.removeChild(t);r=e.lastChild}return r=e.lastChild,t.parentNode=e,t.previousSibling=r,t.nextSibling=null,r?r.nextSibling=t:e.firstChild=t,e.lastChild=t,N(e.ownerDocument,e,t),t}(this,e)},setAttributeNode:function(e){return this.attributes.setNamedItem(e)},setAttributeNodeNS:function(e){return this.attributes.setNamedItemNS(e)},removeAttributeNode:function(e){return this.attributes.removeNamedItem(e.nodeName)},removeAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);n&&this.removeAttributeNode(n)},hasAttributeNS:function(e,t){return null!=this.getAttributeNodeNS(e,t)},getAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);return n&&n.value||""},setAttributeNS:function(e,t,n){var r=this.ownerDocument.createAttributeNS(e,t);r.value=r.nodeValue=""+n,this.setAttributeNode(r)},getAttributeNodeNS:function(e,t){return this.attributes.getNamedItemNS(e,t)},getElementsByTagName:function(e){return new E(this,(function(t){var n=[];return L(t,(function(r){r===t||r.nodeType!=o||"*"!==e&&r.tagName!=e||n.push(r)})),n}))},getElementsByTagNameNS:function(e,t){return new E(this,(function(n){var r=[];return L(n,(function(i){i===n||i.nodeType!==o||"*"!==e&&i.namespaceURI!==e||"*"!==t&&i.localName!=t||r.push(i)})),r}))}},j.prototype.getElementsByTagName=B.prototype.getElementsByTagName,j.prototype.getElementsByTagNameNS=B.prototype.getElementsByTagNameNS,r(B,A),F.prototype.nodeType=a,r(F,A),V.prototype={data:"",substringData:function(e,t){return this.data.substring(e,e+t)},appendData:function(e){e=this.data+e,this.nodeValue=this.data=e,this.length=e.length},insertData:function(e,t){this.replaceData(e,0,t)},appendChild:function(e){throw new Error(v[b])},deleteData:function(e,t){this.replaceData(e,t,"")},replaceData:function(e,t,n){n=this.data.substring(0,e)+n+this.data.substring(e+t),this.nodeValue=this.data=n,this.length=n.length}},r(V,A),H.prototype={nodeName:"#text",nodeType:s,splitText:function(e){var t=this.data,n=t.substring(e);t=t.substring(0,e),this.data=this.nodeValue=t,this.length=t.length;var r=this.ownerDocument.createTextNode(n);return this.parentNode&&this.parentNode.insertBefore(r,this.nextSibling),r}},r(H,V),z.prototype={nodeName:"#comment",nodeType:h},r(z,V),q.prototype={nodeName:"#cdata-section",nodeType:u},r(q,V),W.prototype.nodeType=p,r(W,A),$.prototype.nodeType=m,r($,A),G.prototype.nodeType=c,r(G,A),Y.prototype.nodeType=l,r(Y,A),K.prototype.nodeName="#document-fragment",K.prototype.nodeType=y,r(K,A),X.prototype.nodeType=f,r(X,A),Q.prototype.serializeToString=function(e,t,n){return J.call(e,t,n)},A.prototype.toString=J;try{if(Object.defineProperty){Object.defineProperty(E.prototype,"length",{get:function(){return C(this),this.$$length}}),Object.defineProperty(A.prototype,"textContent",{get:function(){return function e(t){switch(t.nodeType){case o:case y:var n=[];for(t=t.firstChild;t;)7!==t.nodeType&&8!==t.nodeType&&n.push(e(t)),t=t.nextSibling;return n.join("");default:return t.nodeValue}}(this)},set:function(e){switch(this.nodeType){case o:case y:for(;this.firstChild;)this.removeChild(this.firstChild);(e||String(e))&&this.appendChild(this.ownerDocument.createTextNode(e));break;default:this.data=e,this.value=e,this.nodeValue=e}}}),te=function(e,t,n){e["$$"+t]=n}}}catch(e){}t.DOMImplementation=R,t.XMLSerializer=Q},function(e,t,n){"use strict";e.exports={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21}},function(e,t){e.exports=function(e){var t="";return t+=String.fromCharCode(e[0]),t+=String.fromCharCode(e[1]),t+=String.fromCharCode(e[2]),t+=String.fromCharCode(e[3])}},function(e,t,n){"use strict";var r,i,o,a,s,u,l,c,f,h,d,p,y,m,g,v,b,_,w,T,S,E;n.d(t,"i",(function(){return r})),n.d(t,"a",(function(){return i})),n.d(t,"f",(function(){return o})),n.d(t,"j",(function(){return a})),n.d(t,"g",(function(){return d})),n.d(t,"e",(function(){return g})),n.d(t,"b",(function(){return w})),n.d(t,"d",(function(){return T})),n.d(t,"h",(function(){return S})),n.d(t,"c",(function(){return E})),function(e){e.Stream="cv_product_stream",e.StreamRaw="cv_product_stream_raw",e.WebPlayerStream="cv_product_webplayer_stream",e.StreamProgress="cv_product_stream_progress",e.Login="cv_product_login",e.LoginSsoRedirect="cv_product_login_sso_redirect",e.LoginFailed="cv_product_login_failed",e.Search="cv_product_search",e.InstantSearch="cv_product_search",e.SearchEmptyResult="cv_product_search_empty_result",e.Filter="cv_product_search_filter",e.SearchLanding="cv_product_search_landing",e.Share="cv_product_share",e.WorkspaceAdd="cv_product_tv_add",e.Rename="cv_product_rename",e.Move="cv_product_move",e.Sort="cv_product_sort",e.Create="cv_product_create",e.Delete="cv_product_delete",e.Associate="cv_product_associate",e.Dissociate="cv_product_dissociate",e.Edit="cv_product_edit",e.Approve="cv_product_approve",e.Reject="cv_product_reject",e.Disable="cv_product_disable",e.Upload="cv_product_upload",e.Download="cv_product_download",e.Navigate="cv_product_navigate",e.Click="cv_product_click",e.Suggest="cv_product_suggest",e.EditAssoc="cv_product_edit_assoc",e.Play="cv_product_play",e.Favourite="cv_product_favourite",e.Follow="cv_product_follow",e.Prefer="cv_product_prefer",e.Print="cv_product_print",e.Copy="cv_product_copy",e.Activate="cv_product_activate",e.VerifyEmail="cv_product_verify_email",e.ChangePassword="cv_product_change_password",e.Export="cv_product_export",e.SetAccess="cv_product_set_access",e.AddToLocalCache="cv_product_add_to_lc",e.ResolveWarning="cv_product_resolve_warning",e.DismissWarning="cv_product_dismiss_warning"}(r||(r={})),function(e){e.Folder="folder",e.Video="video",e.Rating="rating",e.Series="series",e.Library="library",e.Resource="resource",e.Tag="tag",e.Subtitle="subtitle",e.Chapter="chapter",e.Restriction="restriction",e.Interactive="interactive",e.PDF="pdf",e.CustomerSetting="customer_setting",e.UserSetting="user_setting",e.StaffRequest="staff_request",e.Logo="logo",e.Pagination="pagination",e.Thumbnail="thumbnail",e.Banner="banner",e.Link="link",e.Playlist="playlist",e.Playlists="playlists",e.Person="person",e.Company="company",e.Classroom="classroom",e.ClassroomGroup="classroom_group",e.Classification="classification",e.ShareLink="share_link",e.Upload="upload",e.SearchResults="search_results",e.Audience="audience",e.User="user",e.Clip="clip",e.UserChannel="user_channel",e.Widget="widget",e.Url="url",e.SocialShare="social_share"}(i||(i={})),function(e){e.TopNav="top_nav",e.LeftNav="left_nav",e.Popup="popup",e.Banner="banner",e.VideoList="video_list",e.VideoListItem="video_list_item",e.VideoListHeader="video_header",e.VideoThumbnail="video_thumbnail",e.ExpandableVideoThumbnail="expandable_video_thumbnail",e.VideoItemPreview="video_item_preview",e.VideoDetails="video_details",e.VideoDetailsHeader="video_details_header",e.EditVideoDetails="edit_video_details",e.EditVideoChapters="edit_video_chapters",e.EditVideoResources="edit_video_resources",e.VideoUpload="video_upload",e.VideoRequest="video_request",e.Pagination="pagination",e.LibraryHeader="library_header",e.LibraryTiles="library_tiles",e.StaffRequestDetails="staff_request_details",e.SubFolderList="sub_folder_list",e.AwaitingReviewVideoListHeader="awaiting_review_video_list_header",e.AwaitingReviewVideoItem="awaiting_review_video_item",e.PastReleasesHeader="past_releases_header",e.MigrationWarnings="migration_warnings",e.PlaylistListHeader="playlist_list_header",e.PlaylistListItem="playlist_list_item",e.SeriesListItem="series_list_item",e.SearchBar="search_bar",e.InstantSearch="instant_search",e.SearchFilters="search_filters",e.FeaturedSeriesSearchResult="featured_series_search_result",e.StaffManager="staff_manager",e.StaffManagerListItem="staff_manager_list_item",e.StudentManager="student_manager",e.StudentManagerListItem="student_manager_list_item",e.ClassroomsList="classrooms_list",e.ClassroomsListItem="classrooms_list_item",e.ClassroomOverview="classroom_overview",e.ClassroomOverviewStudentListItem="classroom_overview_student_list_item",e.ManageClassroomStudents="manage_classroom_students",e.ManageClassroomStudentListItem="manage_classroom_student_list_item",e.ManageClassroomGroups="manage_classroom_groups",e.ManageClassroomGroupListItem="manage_classroom_group_list_item",e.PreviewInteractive="preview_interactive",e.PreviewInteractiveQuestions="preview_interactive_questions",e.EditInteractive="edit_interactive",e.PlaySharedInteractive="play_shared_interactive",e.InteractiveListItem="interactive_list_item",e.DeleteInteractive="delete_interactive",e.PlayPage="play_page",e.Player="player",e.FloatingPlayer="floating_player",e.InteractivePlayer="interactive_player",e.EmbeddedPlayer="embedded_player",e.CreateClipPlayer="create_clip_player",e.PlaySharedClip="play_shared_clip",e.ClipListItem="clip_list_item",e.ContentUpdatesClassificationBanner="content_updates_classification_banner",e.PreferencesSettings="preferences_settings",e.MyUploads="my_uploads",e.SlidingList="sliding_list",e.HeroBannerItem="hero_banner_item",e.SlidingListItem="sliding_list_item",e.ClassificationListItem="classification_list_item",e.ClassificationComingSoon="classification_coming_soon",e.ClassificationHero="classification_hero",e.Dashboard="dashboard",e.ProductBanner="product_banner",e.Settings="settings"}(o||(o={})),function(e){e.Start="start",e.Complete="complete",e.Save="save",e.Discard="discard"}(a||(a={})),function(e){e.PageLoad="page_load"}(s||(s={})),function(e){e.Single="single",e.Bulk="bulk",e.All="all"}(u||(u={})),function(e){e.ProductionYear="production_year",e.Alphabetical="alphabetical"}(l||(l={})),function(e){e.Content="content",e.Quality="quality",e.Duration="duration",e.Reset="reset"}(c||(c={})),function(e){e.Submit="submit",e.ShowAll="show_all",e.Recent="recent",e.SearchIcon="search_icon"}(f||(f={})),function(e){e.Start="start",e.Finish="finish",e.Terminate="terminate",e.Play="play",e.Pause="pause",e.Playback="playback",e.NextChapter="next_chapter",e.PreviousChapter="previous_chapter",e.FullScreenEnter="full_screen_enter",e.FullScreenExit="full_screen_exit"}(h||(h={})),function(e){e.Embedded="embedded"}(d||(d={})),function(e){e.TogglePreview="toggle_preview",e.NavigateHome="navigate_home",e.OpenInStaffView="open_in_staff_view",e.Title="title",e.ToggleHideValidListings="toggle_hide_valid_listings",e.LaunchImmersiveReader="launch_immersive_reader",e.CopyEmbedHtml="copy_embed_html",e.Close="close",e.Open="open",e.Button="button",e.Link="link",e.Tile="tile",e.Thumbnail="thumbnail",e.Cover="cover",e.TallPoster="tall_poster",e.Slide="slide",e.ExternalLink="external_link",e.ViewStudentWorkspace="view_student_workspace"}(p||(p={})),function(e){e.FeatureUserChannelVideo="feature_user_channel_video",e.RemoveFromUserChannelPlaylist="remove_from_user_channel_playlist",e.ShareClip="share_clip",e.ViewOriginalVideo="view_original_video",e.ShareInteractive="share_interactive",e.DeleteInteractiveVideo="delete_interactive_video",e.CopyInteractiveVideo="copy_interactive_video",e.EditInteractiveVideo="edit_interactive_video",e.PrintAsWorksheet="print_as_worksheet",e.PreviewInteractiveVideo="preview_interactive_video",e.ViewResults="view_results",e.MoveToAnotherFolder="move_to_another_folder",e.CreateInteractiveVideo="create_interactive_video",e.ShareVideo="share_video",e.EditVideo="edit_video",e.DownloadVideo="download_video",e.AddToExchange="add_to_exchange",e.AddToUserChannel="add_to_user_channel",e.CreateClip="create_clip",e.FlagVideo="flag_video",e.AddToLibrary="add_to_library",e.AddToWorkspace="add_to_workspace",e.AddToPlaylist="add_to_playlist",e.RemoveFromPlaylist="remove_from_playlist",e.AddCurriculumLink="add_curriculum_link",e.ViewCurriculumLinks="view_curriculum_links",e.OpenInCurator="open_in_curator",e.ManageVideoAccess="manage_video_access",e.Approve="approve",e.AddToLocalCache="add_to_local_cache",e.OpenInLibraryEditor="open_in_library_editor",e.PlayClip="play_clip",e.EditClip="edit_clip",e.DeleteClip="delete_clip",e.EditVideoDetails="edit_video_details",e.DeleteVideo="delete_video"}(y||(y={})),function(e){e.LibraryReview="library_review"}(m||(m={})),function(e){e.FileSelect="file_select",e.DragDrop="drag_drop"}(g||(g={})),function(e){e.Edit="edit"}(v||(v={})),function(e){e.Image="image",e.User="user",e.Playlist="playlist",e.Link="link",e.Avatar="avatar"}(b||(b={})),function(e){e.On="on",e.Off="off"}(_||(_={})),function(e){e.EntityRemoved="cv_entity_removed",e.ValueUpdated="cv_value_updated"}(w||(w={})),function(e){e.FileSelect="file_select",e.DragDrop="drag_drop"}(T||(T={})),function(e){e.Video="videos",e.Folder="categories",e.Series="series",e.Tags="tags",e.Subjects="subjects"}(S||(S={})),function(e){e[e.V1=1]="V1",e[e.V2=2]="V2"}(E||(E={}))},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";n.r(t);var r=n(23);n.d(t,"AppLinkHelper",(function(){return r.a})),n.d(t,"AppLinkUtility",(function(){return r.b}));var i=n(205);n.d(t,"Application",(function(){return i.a}));var o=n(206);n.d(t,"AppRouter",(function(){return o.a}));var a=n(207);n.d(t,"Behavior",(function(){return a.a}));var s=n(105);n.d(t,"Collection",(function(){return s.a}));var u=n(133);n.d(t,"CollectionView",(function(){return u.a})),n.d(t,"ComponentCollection",(function(){return u.a}));var l=n(8);n.d(t,"Error",(function(){return l.a})),n.d(t,"ErrorHelper",(function(){return l.c})),n.d(t,"SilentError",(function(){return l.d}));var c=n(208);n.d(t,"LayoutView",(function(){return c.a}));var f=n(209);n.d(t,"NestedModel",(function(){return f.a}));var h=n(210);n.d(t,"Service",(function(){return h.a}));var d=n(69);n.d(t,"Model",(function(){return d.a}));var p=n(83);n.d(t,"View",(function(){return p.b})),n.d(t,"Component",(function(){return p.a}));var y=n(13);n.d(t,"EventNames",(function(){return y.a}));var m=n(211);n.d(t,"LayoutService",(function(){return m.a}));var g=n(104);n.d(t,"Middleware",(function(){return g.a}));var v=n(39);n.d(t,"LocationUtils",(function(){return v.a}));var b=n(212);n.d(t,"Shell",(function(){return b.a}));var _=n(213);for(var w in _)["AppLinkHelper","AppLinkUtility","Application","AppRouter","Behavior","Collection","CollectionView","ComponentCollection","Error","ErrorHelper","SilentError","LayoutView","NestedModel","Service","Model","View","Component","EventNames","LayoutService","Middleware","LocationUtils","Shell","default"].indexOf(w)<0&&function(e){n.d(t,e,(function(){return _[e]}))}(w)},function(e,t,n){"use strict";n.d(t,"a",(function(){return b}));var r=n(4),i=n(10),o=n(29),a=n(13),s=n(22),u=n(8);function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(e){return function(e){if(Array.isArray(e))return f(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t,n){return(d="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=v(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function p(e,t){return(p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==l(t)&&"function"!=typeof t?g(e):t}function g(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function v(e){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var b=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}(f,e);var t,n,o,l=y(f);function f(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),(t=l.call(this,e)).mergeOptions(e,[].concat(c(t.defaultProps),c(t.props||[]))),r.result(g(t),"name")||u.c.throw(new u.b("BaseApplication must define a name")),r.result(g(t),"channelName")||u.c.throw(new u.b("BaseApplication must define a channelName")),t.listenTo(t.getGlobalRadioChannel("popup"),a.a.SHOW_POPUP,t.onShowPopup),t.listenTo(t.getGlobalRadioChannel("alert"),"show:alert",t.onShowAlert),t}return t=f,(n=[{key:"defaultProps",get:function(){return["shell","layoutService"]}},{key:"getGlobalRadioChannel",value:function(e){var t=this.shell.getGlobalRadioChannels()[e.toUpperCase()];return t||u.c.throw(new u.b("Global channel ".concat(t," does not exist"))),i.Radio.channel(t)}},{key:"onLoadLayout",value:function(){if(this.layoutOptions&&this.layoutOptions.name){var e=r.extend({},this.layoutOptions.options||{},{store:this.shell.store});this.layout=this.layoutService.getLayout(r.extend(this.layoutOptions,{options:e})),this.layout||u.c.throw(new u.b("Layout: ".concat(this.layoutOptions.name," does not exist or was not registered"))),this.shell.showView(this.layout),this.triggerMethod("layout:loaded")}}},{key:"onShowPopup",value:function(e){this.layout.getRegion("popup")||u.c.throw(new u.b("Your application layout must define a popup region")),this.layout.showChildView("popup",e)}},{key:"onShowAlert",value:function(e){var t=e.ctor,n=e.collection,r=this.layout.getRegion("alert");r?r.hasView()||this.layout.showChildView("alert",new t({collection:n})):u.c.throw(new u.b("Your application layout must define an alert region"))}},{key:"setDefaultQueryParams",value:function(e){this.defaultQueryParams&&(e=r.extend(this.defaultQueryParams,e)),this.defaultQueryParams=e}},{key:"getAndClearDefaultQueryParams",value:function(){var e=this.defaultQueryParams;return delete this.defaultQueryParams,e||{}}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],d(v(f.prototype),"listenTo",this))}}])&&h(t.prototype,n),o&&h(t,o),f}(o.Application)},function(e,t,n){"use strict";n.d(t,"a",(function(){return E}));var r=n(4),i=n(10),o=n(29),a=n(23),s=n(22),u=n(104),l=n(13),c=n(8),f=n(39),h=n(12);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function p(e){return function(e){if(Array.isArray(e))return y(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return y(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return y(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function g(e,t,n){return(g="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=w(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function v(e,t){return(v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=w(e);if(t){var i=w(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _(this,n)}}function _(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function w(e){return(w=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var T=/([A-Z])/g,S=/(^|:)(\w)/gi,E=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&v(e,t)}(y,e);var t,n,o,d=b(y);function y(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,y),(t=d.call(this,e)).bindDisposal(),t.processInternalRoutes(),t.processExternalRoutes(),t.processAppLinks(),t}return t=y,(n=[{key:"bindDisposal",value:function(){var e=this;this.listenTo(h.a.SHELL,l.a.ROUTE,(function(t){t.application!==e.channelName&&e.destroyApp()}))}},{key:"addRouteLookup",value:function(e,t){var n=this;this.options.shell.addRouteLookup("".concat(this.channelName,":").concat(e),(function(r,i){return a.a.buildRoute(t,{application:n.channelName,action:e,args:r,params:i})}))}},{key:"processInternalRoutes",value:function(){var e=this;r.each(r.keys(this.appRoutes),(function(t){var n=e.appRoutes[t],i=e.toEventName(n);e.addRouteLookup(i,t),e.listenTo(e.channelName,i,(function(n,i){i&&i.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),e.executeRoute(n,{isAppRoute:!0},(function(){var o=r.extend({},e.controller.getAndClearDefaultQueryParams(),n.params);n.params=o,f.a.UpdateUrl(t,n,i)}))}))}))}},{key:"processExternalRoutes",value:function(){var e=this;this.externalRoutes&&r.each(r.keys(this.externalRoutes),(function(t){var n=e.externalRoutes[t],r=e.toEventName(n);e.addRouteLookup(r,t),e.listenTo(e.channelName,r,(function(e,t){t&&t.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),f.a.PageLoad(a.a.getHref(e))}))}))}},{key:"processAppLinks",value:function(){var e=this;this.appLinks&&r.each(this.appLinks,(function(t){var n=e.toEventName(t);e.listenTo(e.channelName,n,(function(t,n){n&&n.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),e.executeRoute(t,{isAppRoute:!1})}))}))}},{key:"executeRoute",value:function(e,t,n){var o=this;this.validateAppLink(e);var s=this.toMethodName(e.action);a.b.routingStarted();var f=i.Radio.channel(h.a.SHELL);if(this.options.shell.isNavLocked())return f.trigger(l.a.NAV_IS_LOCKED,e),void a.b.routingEnded();var d=new u.a;r.each(this.filters,(function(e){return d.use(e)})),d.go({appLink:e,shell:this.options.shell},(function(){f.trigger(l.a.ROUTE,e,t),o.createApp();var i=o.controller;if(r.isFunction(i[s])||(a.b.routingEnded(),c.c.throw(new c.b("".concat(s," does not exist on the ").concat(r.result(i,"name"),".")))),!1===i.triggerMethod("before:action"))return i.triggerMethod("action:cancelled"),void a.b.routingEnded();i.triggerMethod("load:layout"),i[s].apply(i,[].concat(p(e.args||[]),[e.params||{}])),r.isFunction(n)&&n(),a.b.routingEnded()}))}},{key:"createApp",value:function(){this.controller||(this.controller=new this.options.appConstructor(this.options.appOptions),this.controller.start())}},{key:"destroyApp",value:function(){this.controller&&(this.controller.destroy(),delete this.controller)}},{key:"_addAppRoute",value:function(e,t,n){var i=this;this.route(t,n,(function(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];var a={application:i.channelName,action:i.toEventName(n),args:t.slice(0,t.length-1),params:f.a.DeserializeQueryParams(t[t.length-1])};i.executeRoute(a,{isAppRoute:!0},(function(){f.a.UpdateQuery(r.extend(i.controller.getAndClearDefaultQueryParams(),a.params))}))}))}},{key:"toEventName",value:function(e){return e.replace(T,":$1").toLowerCase()}},{key:"toMethodName",value:function(e){var t=e.replace(S,(function(e,t,n){return n.toUpperCase()}));return t[0].toLowerCase()+t.slice(1,t.length)}},{key:"validateAppLink",value:function(e){e.application&&e.action||(a.b.routingEnded(),c.c.throw(new c.b("Invalid AppLink")))}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],g(w(y.prototype),"listenTo",this))}}])&&m(t.prototype,n),o&&m(t,o),y}(o.AppRouter)},function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(29),i=n(22);function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(f,e);var t,n,r,o=c(f);function f(){return a(this,f),o.apply(this,arguments)}return t=f,(n=[{key:"listenTo",value:function(){return i.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],u(h(f.prototype),"listenTo",this))}}])&&s(t.prototype,n),r&&s(t,r),f}(r.Behavior)},function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(83),i=n(41),o=n(8);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(c,e);var t,n,r,a=l(c);function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),a.call(this,e)}return t=c,r=[{key:"getCacheKey",value:function(e){o.c.throw(new i.a("Must define getCacheKey for ".concat(this.name,".")))}}],(n=[{key:"unmountRegion",value:function(e){this.trigger("unmount:".concat(e))}}])&&s(t.prototype,n),r&&s(t,r),c}(r.b)},function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(4),i=n(69),o=n(105);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=d(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d(e);if(t){var i=d(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(y,e);var t,n,h,p=f(y);function y(){return s(this,y),p.apply(this,arguments)}return t=y,(n=[{key:"set",value:function(e,t,n){var i,o;if(null===e)return this;for(i in"object"===a(e)?(o=e,n=t):(o={})[e]=t,n||(n={}),o)r.has(this.associations,i)&&(o[i]=this.setAssociation(i,o[i],n));return l(d(y.prototype),"set",this).call(this,o,n)}},{key:"get",value:function(e){var t=e.indexOf(".");if(-1===t)return l(d(y.prototype),"get",this).call(this,e);var n=e.substr(0,t),i=this.attributes[n];if(!i||!r.isFunction(i.get))return l(d(y.prototype),"get",this).call(this,e);var o=e.substr(t+1);return i.get(o)}},{key:"setAssociation",value:function(e,t,n){var a=this.associations[e],s=this.attributes[e];if(!r.isFunction(a))return t;if(n.unset)return s&&delete s.parent,delete this[e],s;if(s)return s instanceof i.a&&s.set(t,n),s instanceof o.a&&s.set(t,n),n.silent||this.trigger("change:".concat(e),this,t,n),s;var u=t instanceof i.a?t:new a(t,{parse:!0});return u.parent=this,this[e]=u,u}},{key:"toJSON",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var i=l(d(y.prototype),"toJSON",this).apply(this,t);return r.each(this.associations,(function(e,t){r.has(i,t)&&r.isFunction(i[t].toJSON)?i[t]=i[t].toJSON():i[t]=(new e).toJSON()})),i}},{key:"toFlatJSON",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.omit(l(d(y.prototype),"toJSON",this).apply(this,t),r.keys(this.associations))}}])&&u(t.prototype,n),h&&u(t,h),y}(i.a)},function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(29),i=n(22),o=n(8);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(f,e);var t,n,r,a=c(f);function f(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),(t=a.call(this,e)).name||o.c.throw(new o.b("Your service must be named.")),t}return t=f,(n=[{key:"listenTo",value:function(){return i.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],u(h(f.prototype),"listenTo",this))}}])&&s(t.prototype,n),r&&s(t,r),f}(r.Object)},function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(4),i=n(29),o=n(22),a=n(8);function s(e){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=d(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d(e);if(t){var i=d(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(h,e);var t,n,i,s=f(h);function h(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,h),(t=s.call(this,e)).layouts={},t.requiredRegions=e.requiredRegions,t}return t=h,(n=[{key:"clearLayout",value:function(){this.currentLayout&&(this.currentLayout.destroy(),delete this.currentLayout,delete this.currentLayoutCacheKey)}},{key:"registerLayout",value:function(e,t){return this.checkRequiredRegions(t),this.layouts[e]=t,this}},{key:"getLayout",value:function(e){var t=e.name,n=e.options,r=void 0===n?{}:n;this.layouts[t]||a.c.throw(new a.b("".concat(t," was not registered as a template.")));var i=this.layouts[t].getCacheKey(r);return this.currentLayoutCacheKey===i&&this.currentLayout?(this.currentLayout.triggerMethod("layout:requested",r),this.currentLayout):(this.clearLayout(),this.currentLayoutCacheKey=i,this.currentLayout=new this.layouts[t](r),this.listenToOnce(this.currentLayout,"destroy",this.clearLayout),this.currentLayout)}},{key:"checkRequiredRegions",value:function(e){r.each(this.requiredRegions,(function(t){r.has(r.result(e.prototype,"regions"),t)||a.c.throw(new a.b("Layout: ".concat(e.prototype.name," must define an ").concat(t," region.")))}))}},{key:"listenTo",value:function(){return o.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],l(d(h.prototype),"listenTo",this))}}])&&u(t.prototype,n),i&&u(t,i),h}(i.Object)},function(e,t,n){"use strict";n.d(t,"a",(function(){return T}));var r=n(4),i=n(10),o=n(29),a=n(23),s=n(22),u=n(12),l=n(8),c=n(13),f=n(39);function h(e){return(h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function d(e,t,n){return(d="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=g(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function p(e,t){return(p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g(e);if(t){var i=g(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==h(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _(e,t,n){return t&&b(e.prototype,t),n&&b(e,n),e}var w=function(){function e(t,n){v(this,e),this.application=t,this.options=n||{}}return _(e,[{key:"Application",get:function(){return this.application}},{key:"Options",get:function(){return this.options}}]),e}(),T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}(n,e);var t=y(n);function n(){return v(this,n),t.apply(this,arguments)}return _(n,[{key:"initialize",value:function(e){this.mergeOptions(e,["layoutService"]),this.applications=[],this.routeLookup={},this.shellState={navLock:!1,activeRoute:!1,currentAppLink:null},this.errorHandlers=[]}},{key:"bindListeners",value:function(){this.bindRouteLookup(),this.bindNavLockListeners(),this.bindAppLinkListeners(),this.bindErrorHandlers(),this.bindErrorListener()}},{key:"bindNavLockListeners",value:function(){var e=this;this.listenTo(u.a.SHELL,c.a.LOCK_NAV,(function(){return e.shellState.navLock=!0})),this.listenTo(u.a.SHELL,c.a.UNLOCK_NAV,(function(){return e.shellState.navLock=!1}))}},{key:"bindAppLinkListeners",value:function(){var e=this;this.listenTo(u.a.SHELL,c.a.ROUTING_START,(function(){return e.shellState.activeRoute=!0})),this.listenTo(u.a.SHELL,c.a.ROUTING_END,(function(){return e.shellState.activeRoute=!1})),this.listenTo(u.a.SHELL,c.a.ROUTE,(function(t){return e.shellState.currentAppLink=t}));var t=i.Radio.channel(u.a.SHELL);t.reply(c.a.HAS_ACTIVE_ROUTE,r.bind(this.hasActiveRoute,this)),t.reply(c.a.CURRENT_ROUTE,(function(){return e.shellState.currentAppLink}))}},{key:"bindErrorHandlers",value:function(){window.addEventListener("error",(function(){a.b.routingEnded()}))}},{key:"bindErrorListener",value:function(){var e=i.Radio.channel(u.a.SHELL);this.listenTo(e,c.a.ERROR,this.handleError)}},{key:"bindRouteLookup",value:function(){var e=this;i.Radio.channel(u.a.SHELL).reply(c.a.ROUTE_LOOKUP,(function(t,n,r){return!!e.routeLookup[t]&&e.routeLookup[t](n,r)}),this)}},{key:"addRouteLookup",value:function(e,t){this.routeLookup[e]=t}},{key:"registerApplication",value:function(e,t){return this.applications.push(new w(e,t)),this}},{key:"getGlobalRadioChannels",value:function(){return u.a}},{key:"isNavLocked",value:function(){return this.shellState.navLock}},{key:"start",value:function(e){var t=this;e||(e={}),this.runInitializationSteps(this,(function(){t.runStartUpSteps(t,e,(function(){d(g(n.prototype),"start",t).call(t,e)}))}))}},{key:"hasActiveRoute",value:function(){return this.shellState.activeRoute}},{key:"onStart",value:function(){var e=this;r.each(this.applications,(function(t){var n={appConstructor:t.Application,shell:e,appOptions:Object.assign({region:"",shell:e,layoutService:e.layoutService},t.Options)};new t.Application.router(n)})),this.bindListeners(),f.a.StartHistory()}},{key:"addInitializationStep",value:function(e){var t;return this.runInitializationSteps=(t=this.runInitializationSteps,function(n,r){return t(n,(function(){return e(n,r)}))}),this}},{key:"runInitializationSteps",value:function(e,t){t(e)}},{key:"addStartUpStep",value:function(e){var t;return this.runStartUpSteps=(t=this.runStartUpSteps,function(n,r,i){return t(n,r,(function(){return e(n,r,i)}))}),this}},{key:"runStartUpSteps",value:function(e,t,n){n(e,t)}},{key:"registerLayout",value:function(e,t){return this.layoutService.registerLayout(e,t),this}},{key:"registerErrorHandler",value:function(e,t){return e||l.c.throw(new l.b("An error must have a name in order to register a handler for it.")),r.any(this.errorHandlers,(function(t){return t.errorType===e}))&&l.c.throw(new l.b("An error handler for ".concat(e.prototype.name," has already been defined."))),this.errorHandlers.push({errorType:e,handler:t}),this}},{key:"handleError",value:function(e){var t=r.find(this.errorHandlers,(function(t){return e instanceof t.errorType}));t&&t.handler&&t.handler(e)}},{key:"registerStore",value:function(e){this.store=e}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],d(g(n.prototype),"listenTo",this))}}]),n}(o.Application)},function(e,t){},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){function t(t,n,r,i,o,a){var s=i||"<<anonymous>>",u=a||r;if(null==n[r])return t?new Error("Required "+o+" `"+u+"` was not specified in `"+s+"`."):null;for(var l=arguments.length,c=Array(l>6?l-6:0),f=6;f<l;f++)c[f-6]=arguments[f];return e.apply(void 0,[n,r,s,o,u].concat(c))}var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n},e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var r=c(n(68)),i=c(n(134)),o=c(n(67)),a=c(n(216)),s=c(n(1)),u=c(n(28)),l=c(n(431));function c(e){return e&&e.__esModule?e:{default:e}}function f(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var h={container:r.default.oneOfType([i.default,r.default.func]),onContainerResolved:r.default.func},d=function(e){var t,n;function r(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];if(t=e.call.apply(e,[this].concat(r))||this,!o.default)return f(t);var a=t.props.container;return"function"==typeof a&&(a=a()),a&&!u.default.findDOMNode(a)?f(t):(t.setContainer(a),t)}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.UNSAFE_componentWillReceiveProps=function(e){e.container!==this.props.container&&this.setContainer(e.container)},i.componentDidMount=function(){this._container?this.props.onContainerResolved&&this.props.onContainerResolved():(this.setContainer(this.props.container),this.forceUpdate(this.props.onContainerResolved))},i.componentWillUnmount=function(){this._container=null},i.setContainer=function(e){this._container=(0,l.default)(e,(0,a.default)().body)},i.render=function(){return this._container?this.props.children(this._container):null},r}(s.default.Component);d.propTypes=h;var p=d;t.default=p,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){return e&&e.ownerDocument||document},e.exports=t.default},function(e,t,n){"use strict";var r=Array.prototype.slice,i=n(218),o=Object.keys,a=o?function(e){return o(e)}:n(437),s=Object.keys;a.shim=function(){Object.keys?function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2)||(Object.keys=function(e){return i(e)?s(r.call(e)):s(e)}):Object.keys=a;return Object.keys||a},e.exports=a},function(e,t,n){"use strict";var r=Object.prototype.toString;e.exports=function(e){var t=r.call(e),n="[object Arguments]"===t;return n||(n="[object Array]"!==t&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===r.call(e.callee)),n}},function(e,t,n){"use strict";var r=n(220),i=n(136),o=i(r("String.prototype.indexOf"));e.exports=function(e,t){var n=r(e,!!t);return"function"==typeof n&&o(e,".prototype.")>-1?i(n):n}},function(e,t,n){"use strict";var r=SyntaxError,i=Function,o=TypeError,a=function(e){try{return i('"use strict"; return ('+e+").constructor;")()}catch(e){}},s=Object.getOwnPropertyDescriptor;if(s)try{s({},"")}catch(e){s=null}var u=function(){throw new o},l=s?function(){try{return u}catch(e){try{return s(arguments,"callee").get}catch(e){return u}}}():u,c=n(221)(),f=Object.getPrototypeOf||function(e){return e.__proto__},h={},d="undefined"==typeof Uint8Array?void 0:f(Uint8Array),p={"%AggregateError%":"undefined"==typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":c?f([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":h,"%AsyncGenerator%":h,"%AsyncGeneratorFunction%":h,"%AsyncIteratorPrototype%":h,"%Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"==typeof BigInt?void 0:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":h,"%Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":c?f(f([][Symbol.iterator]())):void 0,"%JSON%":"object"==typeof JSON?JSON:void 0,"%Map%":"undefined"==typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&c?f((new Map)[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?void 0:Promise,"%Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&c?f((new Set)[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":c?f(""[Symbol.iterator]()):void 0,"%Symbol%":c?Symbol:void 0,"%SyntaxError%":r,"%ThrowTypeError%":l,"%TypedArray%":d,"%TypeError%":o,"%Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet},y={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=n(135),g=n(441),v=m.call(Function.call,Array.prototype.concat),b=m.call(Function.apply,Array.prototype.splice),_=m.call(Function.call,String.prototype.replace),w=m.call(Function.call,String.prototype.slice),T=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,S=/\\(\\)?/g,E=function(e){var t=w(e,0,1),n=w(e,-1);if("%"===t&&"%"!==n)throw new r("invalid intrinsic syntax, expected closing `%`");if("%"===n&&"%"!==t)throw new r("invalid intrinsic syntax, expected opening `%`");var i=[];return _(e,T,(function(e,t,n,r){i[i.length]=n?_(r,S,"$1"):t||e})),i},C=function(e,t){var n,i=e;if(g(y,i)&&(i="%"+(n=y[i])[0]+"%"),g(p,i)){var s=p[i];if(s===h&&(s=function e(t){var n;if("%AsyncFunction%"===t)n=a("async function () {}");else if("%GeneratorFunction%"===t)n=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)n=a("async function* () {}");else if("%AsyncGenerator%"===t){var r=e("%AsyncGeneratorFunction%");r&&(n=r.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(n=f(i.prototype))}return p[t]=n,n}(i)),void 0===s&&!t)throw new o("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:i,value:s}}throw new r("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new o('"allowMissing" argument must be a boolean');var n=E(e),i=n.length>0?n[0]:"",a=C("%"+i+"%",t),u=a.name,l=a.value,c=!1,f=a.alias;f&&(i=f[0],b(n,v([0,1],f)));for(var h=1,d=!0;h<n.length;h+=1){var y=n[h],m=w(y,0,1),_=w(y,-1);if(('"'===m||"'"===m||"`"===m||'"'===_||"'"===_||"`"===_)&&m!==_)throw new r("property names with quotes must have matching quotes");if("constructor"!==y&&d||(c=!0),g(p,u="%"+(i+="."+y)+"%"))l=p[u];else if(null!=l){if(!(y in l)){if(!t)throw new o("base intrinsic for "+e+" exists, but the property is not available.");return}if(s&&h+1>=n.length){var T=s(l,y);l=(d=!!T)&&"get"in T&&!("originalValue"in T.get)?T.get:l[y]}else d=g(l,y),l=l[y];d&&!c&&(p[u]=l)}}return l}},function(e,t,n){"use strict";var r="undefined"!=typeof Symbol&&Symbol,i=n(439);e.exports=function(){return"function"==typeof r&&("function"==typeof Symbol&&("symbol"==typeof r("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},function(e,t,n){"use strict";var r=function(e){return e!=e};e.exports=function(e,t){return 0===e&&0===t?1/e==1/t:e===t||!(!r(e)||!r(t))}},function(e,t,n){"use strict";var r=n(222);e.exports=function(){return"function"==typeof Object.is?Object.is:r}},function(e,t,n){"use strict";var r=Object,i=TypeError;e.exports=function(){if(null!=this&&this!==r(this))throw new i("RegExp.prototype.flags getter called on non-object");var e="";return this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.dotAll&&(e+="s"),this.unicode&&(e+="u"),this.sticky&&(e+="y"),e}},function(e,t,n){"use strict";var r=n(224),i=n(82).supportsDescriptors,o=Object.getOwnPropertyDescriptor,a=TypeError;e.exports=function(){if(!i)throw new a("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");if("gim"===/a/gim.flags){var e=o(RegExp.prototype,"flags");if(e&&"function"==typeof e.get&&"boolean"==typeof/a/.dotAll)return e.get}return r}},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=t.animationEnd=t.animationDelay=t.animationTiming=t.animationDuration=t.animationName=t.transitionEnd=t.transitionDuration=t.transitionDelay=t.transitionTiming=t.transitionProperty=t.transform=void 0;var i,o,a,s,u,l,c,f,h,d,p,y=r(n(67)),m="transform";if(t.transform=m,t.animationEnd=a,t.transitionEnd=o,t.transitionDelay=c,t.transitionTiming=l,t.transitionDuration=u,t.transitionProperty=s,t.animationDelay=p,t.animationTiming=d,t.animationDuration=h,t.animationName=f,y.default){var g=function(){for(var e,t,n=document.createElement("div").style,r={O:function(e){return"o"+e.toLowerCase()},Moz:function(e){return e.toLowerCase()},Webkit:function(e){return"webkit"+e},ms:function(e){return"MS"+e}},i=Object.keys(r),o="",a=0;a<i.length;a++){var s=i[a];if(s+"TransitionProperty"in n){o="-"+s.toLowerCase(),e=r[s]("TransitionEnd"),t=r[s]("AnimationEnd");break}}!e&&"transitionProperty"in n&&(e="transitionend");!t&&"animationName"in n&&(t="animationend");return n=null,{animationEnd:t,transitionEnd:e,prefix:o}}();i=g.prefix,t.transitionEnd=o=g.transitionEnd,t.animationEnd=a=g.animationEnd,t.transform=m=i+"-"+m,t.transitionProperty=s=i+"-transition-property",t.transitionDuration=u=i+"-transition-duration",t.transitionDelay=c=i+"-transition-delay",t.transitionTiming=l=i+"-transition-timing-function",t.animationName=f=i+"-animation-name",t.animationDuration=h=i+"-animation-duration",t.animationTiming=d=i+"-animation-delay",t.animationDelay=p=i+"-animation-timing-function"}var v={transform:m,end:o,property:s,timing:l,delay:c,duration:u};t.default=v},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=function(e){return(0,i.default)(e.replace(o,"ms-"))};var i=r(n(452)),o=/^-ms-/;e.exports=t.default},function(e,t){e.exports=function(e,t){var n,r=null;try{n=JSON.parse(e,t)}catch(e){r=e}return[r,n]}},function(e,t,n){var r=n(132),i=n(363);function o(t,n,a){return i()?(e.exports=o=Reflect.construct,e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},e.exports.default=e.exports,e.exports.__esModule=!0),o.apply(null,arguments)}e.exports=o,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(132);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){function r(e){this.options=e||{locator:{}}}function i(){this.cdata=!1}function o(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}function a(e){if(e)return"\n@"+(e.systemId||"")+"#[line:"+e.lineNumber+",col:"+e.columnNumber+"]"}function s(e,t,n){return"string"==typeof e?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+"":e}function u(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}r.prototype.parseFromString=function(e,t){var n=this.options,r=new l,o=n.domBuilder||new i,s=n.errorHandler,u=n.locator,c=n.xmlns||{},f={lt:"<",gt:">",amp:"&",quot:'"',apos:"'"};return u&&o.setDocumentLocator(u),r.errorHandler=function(e,t,n){if(!e){if(t instanceof i)return t;e=t}var r={},o=e instanceof Function;function s(t){var i=e[t];!i&&o&&(i=2==e.length?function(n){e(t,n)}:e),r[t]=i&&function(e){i("[xmldom "+t+"]\t"+e+a(n))}||function(){}}return n=n||{},s("warning"),s("error"),s("fatalError"),r}(s,o,u),r.domBuilder=n.domBuilder||o,/\/x?html?$/.test(t)&&(f.nbsp=" ",f.copy="©",c[""]="http://www.w3.org/1999/xhtml"),c.xml=c.xml||"http://www.w3.org/XML/1998/namespace",e?r.parse(e,c,f):r.errorHandler.error("invalid doc source"),o.doc},i.prototype={startDocument:function(){this.doc=(new c).createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),s=r.length;u(this,a),this.currentElement=a,this.locator&&o(this.locator,a);for(var l=0;l<s;l++){e=r.getURI(l);var c=r.getValue(l),f=(n=r.getQName(l),i.createAttributeNS(e,n));this.locator&&o(r.getLocator(l),f),f.value=f.nodeValue=c,a.setAttributeNode(f)}},endElement:function(e,t,n){var r=this.currentElement;r.tagName;this.currentElement=r.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&o(this.locator,n),u(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=s.apply(this,arguments)){if(this.cdata)var r=this.doc.createCDATASection(e);else r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&o(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){(this.locator=e)&&(e.lineNumber=0)},comment:function(e,t,n){e=s.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&o(this.locator,r),u(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n){var r=this.doc.implementation;if(r&&r.createDocumentType){var i=r.createDocumentType(e,t,n);this.locator&&o(this.locator,i),u(this,i)}},warning:function(e){console.warn("[xmldom warning]\t"+e,a(this.locator))},error:function(e){console.error("[xmldom error]\t"+e,a(this.locator))},fatalError:function(e){throw console.error("[xmldom fatalError]\t"+e,a(this.locator)),e}},"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,(function(e){i.prototype[e]=function(){return null}}));var l=n(369).XMLReader,c=t.DOMImplementation=n(187).DOMImplementation;t.XMLSerializer=n(187).XMLSerializer,t.DOMParser=r},function(e,t){var n=Math.pow(2,32);e.exports=function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:t.getUint32(4),timescale:t.getUint32(8)},i=12;0===r.version?(r.earliestPresentationTime=t.getUint32(i),r.firstOffset=t.getUint32(i+4),i+=8):(r.earliestPresentationTime=t.getUint32(i)*n+t.getUint32(i+4),r.firstOffset=t.getUint32(i+8)*n+t.getUint32(i+12),i+=16),i+=2;var o=t.getUint16(i);for(i+=2;o>0;i+=12,o--)r.references.push({referenceType:(128&e[i])>>>7,referencedSize:2147483647&t.getUint32(i),subsegmentDuration:t.getUint32(i+4),startsWithSap:!!(128&e[i+8]),sapType:(112&e[i+8])>>>4,sapDeltaTime:268435455&t.getUint32(i+8)});return r}},function(e,t,n){"use strict";var r=n(188),i=n(370).handleRollover,o={};o.ts=n(372),o.aac=n(373);var a=n(59).ONE_SECOND_IN_TS,s=function(e,t,n){for(var r,i,a,s,u=0,l=188,c=!1;l<=e.byteLength;)if(71!==e[u]||71!==e[l]&&l!==e.byteLength)u++,l++;else{switch(r=e.subarray(u,l),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u+=188,l+=188}for(u=(l=e.byteLength)-188,c=!1;u>=0;)if(71!==e[u]||71!==e[l]&&l!==e.byteLength)u--,l--;else{switch(r=e.subarray(u,l),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u-=188,l-=188}},u=function(e,t,n){for(var r,i,a,s,u,l,c,f=0,h=188,d=!1,p={data:[],size:0};h<e.byteLength;)if(71!==e[f]||71!==e[h])f++,h++;else{switch(r=e.subarray(f,h),o.ts.parseType(r,t.pid)){case"pes":if(i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(a&&!d&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0),!n.firstKeyFrame)){if(a&&0!==p.size){for(u=new Uint8Array(p.size),l=0;p.data.length;)c=p.data.shift(),u.set(c,l),l+=c.byteLength;if(o.ts.videoPacketContainsKeyFrame(u)){var y=o.ts.parsePesTime(u);y?(n.firstKeyFrame=y,n.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}p.size=0}p.data.push(r),p.size+=r.byteLength}}if(d&&n.firstKeyFrame)break;f+=188,h+=188}for(f=(h=e.byteLength)-188,d=!1;f>=0;)if(71!==e[f]||71!==e[h])f--,h--;else{switch(r=e.subarray(f,h),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0)}if(d)break;f-=188,h-=188}},l=function(e){var t={pid:null,table:null},n={};for(var i in function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),o.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=o.ts.parsePat(n));break;case"pmt":t.table||(t.table=o.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}}(e,t),t.table){if(t.table.hasOwnProperty(i))switch(t.table[i]){case r.H264_STREAM_TYPE:n.video=[],u(e,t,n),0===n.video.length&&delete n.video;break;case r.ADTS_STREAM_TYPE:n.audio=[],s(e,t,n),0===n.audio.length&&delete n.audio}}return n};e.exports={inspect:function(e,t){var n;return(n=o.aac.isLikelyAacData(e)?function(e){for(var t,n=!1,r=0,i=null,s=null,u=0,l=0;e.length-l>=3;){switch(o.aac.parseType(e,l)){case"timed-metadata":if(e.length-l<10){n=!0;break}if((u=o.aac.parseId3TagSize(e,l))>e.length){n=!0;break}null===s&&(t=e.subarray(l,l+u),s=o.aac.parseAacTimestamp(t)),l+=u;break;case"audio":if(e.length-l<7){n=!0;break}if((u=o.aac.parseAdtsSize(e,l))>e.length){n=!0;break}null===i&&(t=e.subarray(l,l+u),i=o.aac.parseSampleRate(t)),r++,l+=u;break;default:l++}if(n)return null}if(null===i||null===s)return null;var c=a/i;return{audio:[{type:"audio",dts:s,pts:s},{type:"audio",dts:s+1024*r*c,pts:s+1024*r*c}]}}(e):l(e))&&(n.audio||n.video)?(function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach((function(e){e.dts=i(e.dts,n),e.pts=i(e.pts,n),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a}))}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach((function(e){e.dts=i(e.dts,r),e.pts=i(e.pts,r),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a})),e.firstKeyFrame){var o=e.firstKeyFrame;o.dts=i(o.dts,r),o.pts=i(o.pts,r),o.dtsTime=o.dts/a,o.ptsTime=o.dts/a}}}(n,t),n):null},parseAudioPes_:s}},function(e){e.exports=JSON.parse('{"a":"0.0.4-rc.1"}')},function(e,t,n){(function(t){var n=/^\[object .+?Constructor\]$/,r="object"==typeof t&&t&&t.Object===Object&&t,i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();var a,s=Array.prototype,u=Function.prototype,l=Object.prototype,c=o["__core-js_shared__"],f=(a=/[^.]+$/.exec(c&&c.keys&&c.keys.IE_PROTO||""))?"Symbol(src)_1."+a:"",h=u.toString,d=l.hasOwnProperty,p=l.toString,y=RegExp("^"+h.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),m=s.splice,g=C(o,"Map"),v=C(Object,"create");function b(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function _(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function w(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function T(e,t){for(var n,r,i=e.length;i--;)if((n=e[i][0])===(r=t)||n!=n&&r!=r)return i;return-1}function S(e){return!(!x(e)||(t=e,f&&f in t))&&(function(e){var t=x(e)?p.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?y:n).test(function(e){if(null!=e){try{return h.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function E(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function C(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return S(n)?n:void 0}function k(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a),a};return n.cache=new(k.Cache||w),n}function x(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}b.prototype.clear=function(){this.__data__=v?v(null):{}},b.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},b.prototype.get=function(e){var t=this.__data__;if(v){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return d.call(t,e)?t[e]:void 0},b.prototype.has=function(e){var t=this.__data__;return v?void 0!==t[e]:d.call(t,e)},b.prototype.set=function(e,t){return this.__data__[e]=v&&void 0===t?"__lodash_hash_undefined__":t,this},_.prototype.clear=function(){this.__data__=[]},_.prototype.delete=function(e){var t=this.__data__,n=T(t,e);return!(n<0)&&(n==t.length-1?t.pop():m.call(t,n,1),!0)},_.prototype.get=function(e){var t=this.__data__,n=T(t,e);return n<0?void 0:t[n][1]},_.prototype.has=function(e){return T(this.__data__,e)>-1},_.prototype.set=function(e,t){var n=this.__data__,r=T(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},w.prototype.clear=function(){this.__data__={hash:new b,map:new(g||_),string:new b}},w.prototype.delete=function(e){return E(this,e).delete(e)},w.prototype.get=function(e){return E(this,e).get(e)},w.prototype.has=function(e){return E(this,e).has(e)},w.prototype.set=function(e,t){return E(this,e).set(e,t),this},k.Cache=w,e.exports=k}).call(this,n(30))},function(e,t,n){"use strict";(function(e){var n=function(){if("undefined"!=typeof Map)return Map;function e(e,t){var n=-1;return e.some((function(e,r){return e[0]===t&&(n=r,!0)})),n}return function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(t){var n=e(this.__entries__,t),r=this.__entries__[n];return r&&r[1]},t.prototype.set=function(t,n){var r=e(this.__entries__,t);~r?this.__entries__[r][1]=n:this.__entries__.push([t,n])},t.prototype.delete=function(t){var n=this.__entries__,r=e(n,t);~r&&n.splice(r,1)},t.prototype.has=function(t){return!!~e(this.__entries__,t)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(e,t){void 0===t&&(t=null);for(var n=0,r=this.__entries__;n<r.length;n++){var i=r[n];e.call(t,i[1],i[0])}},t}()}(),r="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,i=void 0!==e&&e.Math===Math?e:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),o="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(e){return setTimeout((function(){return e(Date.now())}),1e3/60)};var a=["top","right","bottom","left","width","height","size","weight"],s="undefined"!=typeof MutationObserver,u=function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(e,t){var n=!1,r=!1,i=0;function a(){n&&(n=!1,e()),r&&u()}function s(){o(a)}function u(){var e=Date.now();if(n){if(e-i<2)return;r=!0}else n=!0,r=!1,setTimeout(s,t);i=e}return u}(this.refresh.bind(this),20)}return e.prototype.addObserver=function(e){~this.observers_.indexOf(e)||this.observers_.push(e),this.connected_||this.connect_()},e.prototype.removeObserver=function(e){var t=this.observers_,n=t.indexOf(e);~n&&t.splice(n,1),!t.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},e.prototype.updateObservers_=function(){var e=this.observers_.filter((function(e){return e.gatherActive(),e.hasActive()}));return e.forEach((function(e){return e.broadcastActive()})),e.length>0},e.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),s?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(e){var t=e.propertyName,n=void 0===t?"":t;a.some((function(e){return!!~n.indexOf(e)}))&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),l=function(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var i=r[n];Object.defineProperty(e,i,{value:t[i],enumerable:!1,writable:!1,configurable:!0})}return e},c=function(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView||i},f=g(0,0,0,0);function h(e){return parseFloat(e)||0}function d(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.reduce((function(t,n){return t+h(e["border-"+n+"-width"])}),0)}function p(e){var t=e.clientWidth,n=e.clientHeight;if(!t&&!n)return f;var r=c(e).getComputedStyle(e),i=function(e){for(var t={},n=0,r=["top","right","bottom","left"];n<r.length;n++){var i=r[n],o=e["padding-"+i];t[i]=h(o)}return t}(r),o=i.left+i.right,a=i.top+i.bottom,s=h(r.width),u=h(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==t&&(s-=d(r,"left","right")+o),Math.round(u+a)!==n&&(u-=d(r,"top","bottom")+a)),!function(e){return e===c(e).document.documentElement}(e)){var l=Math.round(s+o)-t,p=Math.round(u+a)-n;1!==Math.abs(l)&&(s-=l),1!==Math.abs(p)&&(u-=p)}return g(i.left,i.top,s,u)}var y="undefined"!=typeof SVGGraphicsElement?function(e){return e instanceof c(e).SVGGraphicsElement}:function(e){return e instanceof c(e).SVGElement&&"function"==typeof e.getBBox};function m(e){return r?y(e)?function(e){var t=e.getBBox();return g(0,0,t.width,t.height)}(e):p(e):f}function g(e,t,n,r){return{x:e,y:t,width:n,height:r}}var v=function(){function e(e){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=g(0,0,0,0),this.target=e}return e.prototype.isActive=function(){var e=m(this.target);return this.contentRect_=e,e.width!==this.broadcastWidth||e.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var e=this.contentRect_;return this.broadcastWidth=e.width,this.broadcastHeight=e.height,e},e}(),b=function(e,t){var n,r,i,o,a,s,u,c=(r=(n=t).x,i=n.y,o=n.width,a=n.height,s="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,u=Object.create(s.prototype),l(u,{x:r,y:i,width:o,height:a,top:i,right:r+o,bottom:a+i,left:r}),u);l(this,{target:e,contentRect:c})},_=function(){function e(e,t,r){if(this.activeObservations_=[],this.observations_=new n,"function"!=typeof e)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=e,this.controller_=t,this.callbackCtx_=r}return e.prototype.observe=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof c(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)||(t.set(e,new v(e)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof c(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)&&(t.delete(e),t.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var e=this;this.clearActive(),this.observations_.forEach((function(t){t.isActive()&&e.activeObservations_.push(t)}))},e.prototype.broadcastActive=function(){if(this.hasActive()){var e=this.callbackCtx_,t=this.activeObservations_.map((function(e){return new b(e.target,e.broadcastRect())}));this.callback_.call(e,t,e),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e}(),w="undefined"!=typeof WeakMap?new WeakMap:new n,T=function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=u.getInstance(),r=new _(t,n,this);w.set(this,r)};["observe","unobserve","disconnect"].forEach((function(e){T.prototype[e]=function(){var t;return(t=w.get(this))[e].apply(t,arguments)}}));var S=void 0!==i.ResizeObserver?i.ResizeObserver:T;t.a=S}).call(this,n(30))},function(e,t,n){e.exports=function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)},t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function n(e,t,n,r){var i,o,a,s=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(i=0;i<e.length;i+=1)o=(a=i+u)>>>2,s.length<=o&&s.push(0),s[o]|=e[i]<<8*(l+r*(a%4));return{value:s,binLen:8*e.length+n}}function r(e,r,i){switch(r){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,n){return function(e,t,n,r){var i,o,a,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");var u=t||[0],l=(n=n||0)>>>3,c=-1===r?3:0;for(i=0;i<e.length;i+=2){if(o=parseInt(e.substr(i,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(a=(s=(i>>>1)+l)>>>2;u.length<=a;)u.push(0);u[a]|=o<<8*(c+r*(s%4))}return{value:u,binLen:4*e.length+n}}(e,t,n,i)};case"TEXT":return function(e,t,n){return function(e,t,n,r,i){var o,a,s,u,l,c,f,h,d=0,p=n||[0],y=(r=r||0)>>>3;if("UTF8"===t)for(f=-1===i?3:0,s=0;s<e.length;s+=1)for(a=[],128>(o=e.charCodeAt(s))?a.push(o):2048>o?(a.push(192|o>>>6),a.push(128|63&o)):55296>o||57344<=o?a.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),a.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),u=0;u<a.length;u+=1){for(l=(c=d+y)>>>2;p.length<=l;)p.push(0);p[l]|=a[u]<<8*(f+i*(c%4)),d+=1}else for(f=-1===i?2:0,h="UTF16LE"===t&&1!==i||"UTF16LE"!==t&&1===i,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===h&&(o=(u=255&o)<<8|o>>>8),l=(c=d+y)>>>2;p.length<=l;)p.push(0);p[l]|=o<<8*(f+i*(c%4)),d+=2}return{value:p,binLen:8*d+r}}(e,r,t,n,i)};case"B64":return function(e,n,r){return function(e,n,r,i){var o,a,s,u,l,c,f=0,h=n||[0],d=(r=r||0)>>>3,p=-1===i?3:0,y=e.indexOf("=");if(-1===e.search(/^[a-zA-Z0-9=+/]+$/))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==y&&y<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(u=e.substr(o,4),s=0,a=0;a<u.length;a+=1)s|=t.indexOf(u.charAt(a))<<18-6*a;for(a=0;a<u.length-1;a+=1){for(l=(c=f+d)>>>2;h.length<=l;)h.push(0);h[l]|=(s>>>16-8*a&255)<<8*(p+i*(c%4)),f+=1}}return{value:h,binLen:8*f+r}}(e,n,r,i)};case"BYTES":return function(e,t,n){return function(e,t,n,r){var i,o,a,s,u=t||[0],l=(n=n||0)>>>3,c=-1===r?3:0;for(o=0;o<e.length;o+=1)i=e.charCodeAt(o),a=(s=o+l)>>>2,u.length<=a&&u.push(0),u[a]|=i<<8*(c+r*(s%4));return{value:u,binLen:8*e.length+n}}(e,t,n,i)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e,t,r){return function(e,t,r,i){return n(new Uint8Array(e),t,r,i)}(e,t,r,i)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e,t,r){return n(e,t,r,i)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function i(e,n,r,i){switch(e){case"HEX":return function(e){return function(e,t,n,r){var i,o,a="",s=t/8,u=-1===n?3:0;for(i=0;i<s;i+=1)o=e[i>>>2]>>>8*(u+n*(i%4)),a+="0123456789abcdef".charAt(o>>>4&15)+"0123456789abcdef".charAt(15&o);return r.outputUpper?a.toUpperCase():a}(e,n,r,i)};case"B64":return function(e){return function(e,n,r,i){var o,a,s,u,l,c="",f=n/8,h=-1===r?3:0;for(o=0;o<f;o+=3)for(u=o+1<f?e[o+1>>>2]:0,l=o+2<f?e[o+2>>>2]:0,s=(e[o>>>2]>>>8*(h+r*(o%4))&255)<<16|(u>>>8*(h+r*((o+1)%4))&255)<<8|l>>>8*(h+r*((o+2)%4))&255,a=0;a<4;a+=1)c+=8*o+6*a<=n?t.charAt(s>>>6*(3-a)&63):i.b64Pad;return c}(e,n,r,i)};case"BYTES":return function(e){return function(e,t,n){var r,i,o="",a=t/8,s=-1===n?3:0;for(r=0;r<a;r+=1)i=e[r>>>2]>>>8*(s+n*(r%4))&255,o+=String.fromCharCode(i);return o}(e,n,r)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=new ArrayBuffer(i),a=new Uint8Array(o),s=-1===n?3:0;for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(s+n*(r%4))&255;return o}(e,n,r)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=-1===n?3:0,a=new Uint8Array(i);for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(o+n*(r%4))&255;return a}(e,n,r)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function o(e){var t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},r="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(r);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(r);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function a(e,t){return e<<t|e>>>32-t}function s(e,t,n){return e^t^n}function u(e,t,n){return e&t^e&n^t&n}function l(e,t){var n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function c(e,t,n,r,i){var o=(65535&e)+(65535&t)+(65535&n)+(65535&r)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(r>>>16)+(i>>>16)+(o>>>16))<<16|65535&o}function f(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function h(e,t){var n,r,i,o,f,h,d,p,y=[];for(n=t[0],r=t[1],i=t[2],o=t[3],f=t[4],d=0;d<80;d+=1)y[d]=d<16?e[d]:a(y[d-3]^y[d-8]^y[d-14]^y[d-16],1),h=d<20?c(a(n,5),(p=r)&i^~p&o,f,1518500249,y[d]):d<40?c(a(n,5),s(r,i,o),f,1859775393,y[d]):d<60?c(a(n,5),u(r,i,o),f,2400959708,y[d]):c(a(n,5),s(r,i,o),f,3395469782,y[d]),f=o,o=i,i=a(r,30),r=n,n=h;return t[0]=l(n,t[0]),t[1]=l(r,t[1]),t[2]=l(i,t[2]),t[3]=l(o,t[3]),t[4]=l(f,t[4]),t}function d(e,t,n,r){for(var i,o=15+(t+65>>>9<<4),a=t+n;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&a,e[o-1]=a/4294967296|0,i=0;i<e.length;i+=16)r=h(e.slice(i,i+16),r);return r}return function(t){function n(e,n,i){var o=this;if("SHA-1"!==e)throw new Error("Chosen SHA variant is not supported");var a=i||{};return(o=t.call(this,e,n,i)||this).t=!0,o.i=o.o,o.u=-1,o.s=r(o.h,o.v,o.u),o.A=h,o.p=function(e){return e.slice()},o.l=f,o.R=d,o.U=[1732584193,4023233417,2562383102,271733878,3285377520],o.T=512,o.m=160,o.F=!1,a.hmacKey&&o.B(function(e,t,n,i){var o="hmacKey must include a value and format";if(!t)throw new Error(o);if(void 0===t.value||!t.format)throw new Error(o);return r(t.format,t.encoding||"UTF8",n)(t.value)}(0,a.hmacKey,o.u)),o}return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,t),n}(function(){function e(e,t,n){var r=n||{};if(this.h=t,this.v=r.encoding||"UTF8",this.numRounds=r.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.g=e,this.Y=[],this.I=0,this.C=!1,this.H=0,this.L=!1,this.N=[],this.S=[]}return e.prototype.update=function(e){var t,n=0,r=this.T>>>5,i=this.s(e,this.Y,this.I),o=i.binLen,a=i.value,s=o>>>5;for(t=0;t<s;t+=r)n+this.T<=o&&(this.U=this.A(a.slice(t,t+r),this.U),n+=this.T);this.H+=n,this.Y=a.slice(n>>>5),this.I=o%this.T,this.C=!0},e.prototype.getHash=function(e,t){var n,r,a=this.m,s=o(t);if(!0===this.F){if(-1===s.outputLen)throw new Error("Output length must be specified in options");a=s.outputLen}var u=i(e,a,this.u,s);if(!0===this.L&&this.i)return u(this.i(s));for(r=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),a),n=1;n<this.numRounds;n+=1)!0===this.F&&a%32!=0&&(r[r.length-1]&=16777215>>>24-a%32),r=this.R(r,a,0,this.l(this.g),a);return u(r)},e.prototype.setHMACKey=function(e,t,n){if(!0!==this.t)throw new Error("Variant does not support HMAC");if(!0===this.C)throw new Error("Cannot set MAC key after calling update");var i=r(t,(n||{}).encoding||"UTF8",this.u);this.B(i(e))},e.prototype.B=function(e){var t,n=this.T>>>3,r=n/4-1;if(1!==this.numRounds)throw new Error("Cannot set numRounds with MAC");if(!0===this.L)throw new Error("MAC key already set");for(n<e.binLen/8&&(e.value=this.R(e.value,e.binLen,0,this.l(this.g),this.m));e.value.length<=r;)e.value.push(0);for(t=0;t<=r;t+=1)this.N[t]=909522486^e.value[t],this.S[t]=1549556828^e.value[t];this.U=this.A(this.N,this.U),this.H=this.T,this.L=!0},e.prototype.getHMAC=function(e,t){var n=o(t);return i(e,this.m,this.u,n)(this.o())},e.prototype.o=function(){var e;if(!1===this.L)throw new Error("Cannot call getHMAC without first setting MAC key");var t=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),this.m);return e=this.A(this.S,this.l(this.g)),this.R(t,this.m,this.T,e,this.m)},e}())}()},function(e){e.exports=JSON.parse('{"a":"1.0.22-rc.1"}')},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var r=d(n(68)),i=d(n(427)),o=d(n(134)),a=d(n(1)),s=d(n(28)),u=d(n(430)),l=d(n(432)),c=n(466),f=d(n(450)),h=d(n(215));function d(e){return e&&e.__esModule?e:{default:e}}function p(){return(p=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function y(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}function m(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var g=function(e){var t,n;function r(t,n){var r;return(r=e.call(this,t,n)||this).handleHidden=function(){var e;(r.setState({exited:!0}),r.props.onExited)&&(e=r.props).onExited.apply(e,arguments)},r.state={exited:!t.show},r.onHiddenListener=r.handleHidden.bind(m(m(r))),r._lastTarget=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n,r.getDerivedStateFromProps=function(e){return e.show?{exited:!1}:e.transition?null:{exited:!0}};var i=r.prototype;return i.componentDidMount=function(){this.setState({target:this.getTarget()})},i.componentDidUpdate=function(e){if(this.props!==e){var t=this.getTarget();t!==this.state.target&&this.setState({target:t})}},i.getTarget=function(){var e=this.props.target;return(e="function"==typeof e?e():e)&&s.default.findDOMNode(e)||null},i.render=function(){var e=this,t=this.props,n=(t.target,t.container),r=t.containerPadding,i=t.placement,o=t.rootClose,s=t.children,f=t.flip,h=t.popperConfig,d=void 0===h?{}:h,m=t.transition,g=y(t,["target","container","containerPadding","placement","rootClose","children","flip","popperConfig","transition"]),v=this.state.target;if(!(g.show||m&&!this.state.exited))return null;var b=s,_=d.modifiers,w=void 0===_?{}:_,T=p({},d,{placement:i,referenceElement:v,enableEvents:g.show,modifiers:p({},w,{preventOverflow:p({padding:r||5},w.preventOverflow),flip:p({enabled:!!f},w.preventOverflow)})});return b=a.default.createElement(c.Popper,T,(function(t){var n=t.arrowProps,r=t.style,o=t.ref,s=y(t,["arrowProps","style","ref"]);e.popper=s;var u=e.props.children(p({},s,{placement:s.placement||i,show:g.show,arrowProps:n,props:{ref:o,style:r}}));if(m){var l=g.onExit,c=g.onExiting,f=g.onEnter,h=g.onEntering,d=g.onEntered;u=a.default.createElement(m,{in:g.show,appear:!0,onExit:l,onExiting:c,onExited:e.onHiddenListener,onEnter:f,onEntering:h,onEntered:d},u)}return u})),o&&(b=a.default.createElement(l.default,{onRootClose:g.onHide,event:g.rootCloseEvent,disabled:g.rootCloseDisabled},b)),a.default.createElement(u.default,{container:n},b)},r}(a.default.Component);g.propTypes=p({},u.default.propTypes,{show:r.default.bool,placement:r.default.oneOf(c.placements),container:r.default.oneOfType([o.default,r.default.func]),flip:r.default.bool,children:r.default.func.isRequired,popperConfig:r.default.object,rootClose:r.default.bool,rootCloseEvent:l.default.propTypes.event,rootCloseDisabled:l.default.propTypes.disabled,onHide:function(e){var t=r.default.func;e.rootClose&&(t=t.isRequired);for(var n=arguments.length,i=new Array(n>1?n-1:0),o=1;o<n;o++)i[o-1]=arguments[o];return t.apply(void 0,[e].concat(i))},transition:i.default,onEnter:r.default.func,onEntering:r.default.func,onEntered:r.default.func,onExit:r.default.func,onExiting:r.default.func,onExited:r.default.func});var v=(0,f.default)((function(e,t){return a.default.createElement(h.default,{container:e.container},(function(n){return a.default.createElement(g,p({},e,{ref:t,container:n}))}))}),{displayName:"withContainer(Overlay)"});t.default=v,e.exports=t.default},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(217),i=n(438),o=n(442),a=n(444),s=n(445),u=n(447),l=Date.prototype.getTime;function c(e,t,n){var d=n||{};return!!(d.strict?o(e,t):e===t)||(!e||!t||"object"!=typeof e&&"object"!=typeof t?d.strict?o(e,t):e==t:function(e,t,n){var o,d;if(typeof e!=typeof t)return!1;if(f(e)||f(t))return!1;if(e.prototype!==t.prototype)return!1;if(i(e)!==i(t))return!1;var p=a(e),y=a(t);if(p!==y)return!1;if(p||y)return e.source===t.source&&s(e)===s(t);if(u(e)&&u(t))return l.call(e)===l.call(t);var m=h(e),g=h(t);if(m!==g)return!1;if(m||g){if(e.length!==t.length)return!1;for(o=0;o<e.length;o++)if(e[o]!==t[o])return!1;return!0}if(typeof e!=typeof t)return!1;try{var v=r(e),b=r(t)}catch(e){return!1}if(v.length!==b.length)return!1;for(v.sort(),b.sort(),o=v.length-1;o>=0;o--)if(v[o]!=b[o])return!1;for(o=v.length-1;o>=0;o--)if(d=v[o],!c(e[d],t[d],n))return!1;return!0}(e,t,d))}function f(e){return null==e}function h(e){return!(!e||"object"!=typeof e||"number"!=typeof e.length)&&("function"==typeof e.copy&&"function"==typeof e.slice&&!(e.length>0&&"number"!=typeof e[0]))}e.exports=c},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=void 0;var i=r(n(226)),o=r(n(451));function a(e,t,n){var r,o={target:e,currentTarget:e};function a(e){e.target===e.currentTarget&&(clearTimeout(r),e.target.removeEventListener(i.default.end,a),t.call(this))}i.default.end?null==n&&(n=u(e)||0):n=0,i.default.end?(e.addEventListener(i.default.end,a,!1),r=setTimeout((function(){return a(o)}),1.5*(n||100))):setTimeout(a.bind(null,o),0)}a._parseDuration=u;var s=a;function u(e){var t=(0,o.default)(e,i.default.duration),n=-1===t.indexOf("ms")?1e3:1;return parseFloat(t)*n}t.default=s,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){var n=void 0===t?{}:t,r=n.propTypes,o=n.defaultProps,a=n.allowFallback,s=void 0!==a&&a,u=n.displayName,l=void 0===u?e.name||e.displayName:u,c=function(t,n){return e(t,n)};return Object.assign(i.default.forwardRef||!s?i.default.forwardRef(c):function(e){return c(e,null)},{displayName:l,propTypes:r,defaultProps:o})};var r,i=(r=n(1))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";var r=n(6),i=n(14),o=n(51),a=n(46),s=n(17),u=n(153),l=n(11),c=n(36),f=n(54),h=n(18),d=n(25),p=n(20),y=n(32),m=n(62),g=n(61),v=n(64),b=n(76),_=n(115),w=n(156),T=n(118),S=n(49),E=n(27),C=n(85),k=n(33),x=n(45),O=n(74),P=n(86),R=n(75),A=n(87),I=n(16),L=n(157),j=n(247),D=n(55),N=n(38),M=n(47).forEach,U=P("hidden"),B=I("toPrimitive"),F=N.set,V=N.getterFor("Symbol"),H=Object.prototype,z=i.Symbol,q=o("JSON","stringify"),W=S.f,$=E.f,G=w.f,Y=C.f,K=O("symbols"),X=O("op-symbols"),Q=O("string-to-symbol-registry"),J=O("symbol-to-string-registry"),Z=O("wks"),ee=i.QObject,te=!ee||!ee.prototype||!ee.prototype.findChild,ne=s&&l((function(){return 7!=v($({},"a",{get:function(){return $(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=W(H,t);r&&delete H[t],$(e,t,n),r&&e!==H&&$(H,t,r)}:$,re=function(e,t){var n=K[e]=v(z.prototype);return F(n,{type:"Symbol",tag:e,description:t}),s||(n.description=t),n},ie=u&&"symbol"==typeof z.iterator?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof z},oe=function(e,t,n){e===H&&oe(X,t,n),d(e);var r=m(t,!0);return d(n),c(K,r)?(n.enumerable?(c(e,U)&&e[U][r]&&(e[U][r]=!1),n=v(n,{enumerable:g(0,!1)})):(c(e,U)||$(e,U,g(1,{})),e[U][r]=!0),ne(e,r,n)):$(e,r,n)},ae=function(e,t){d(e);var n=y(t),r=b(n).concat(ce(n));return M(r,(function(t){s&&!se.call(n,t)||oe(e,t,n[t])})),e},se=function(e){var t=m(e,!0),n=Y.call(this,t);return!(this===H&&c(K,t)&&!c(X,t))&&(!(n||!c(this,t)||!c(K,t)||c(this,U)&&this[U][t])||n)},ue=function(e,t){var n=y(e),r=m(t,!0);if(n!==H||!c(K,r)||c(X,r)){var i=W(n,r);return!i||!c(K,r)||c(n,U)&&n[U][r]||(i.enumerable=!0),i}},le=function(e){var t=G(y(e)),n=[];return M(t,(function(e){c(K,e)||c(R,e)||n.push(e)})),n},ce=function(e){var t=e===H,n=G(t?X:y(e)),r=[];return M(n,(function(e){!c(K,e)||t&&!c(H,e)||r.push(K[e])})),r};(u||(x((z=function(){if(this instanceof z)throw TypeError("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,t=A(e),n=function(e){this===H&&n.call(X,e),c(this,U)&&c(this[U],t)&&(this[U][t]=!1),ne(this,t,g(1,e))};return s&&te&&ne(H,t,{configurable:!0,set:n}),re(t,e)}).prototype,"toString",(function(){return V(this).tag})),C.f=se,E.f=oe,S.f=ue,_.f=w.f=le,T.f=ce,s&&($(z.prototype,"description",{configurable:!0,get:function(){return V(this).description}}),a||x(H,"propertyIsEnumerable",se,{unsafe:!0})),L.f=function(e){return re(I(e),e)}),r({global:!0,wrap:!0,forced:!u,sham:!u},{Symbol:z}),M(b(Z),(function(e){j(e)})),r({target:"Symbol",stat:!0,forced:!u},{for:function(e){var t=String(e);if(c(Q,t))return Q[t];var n=z(t);return Q[t]=n,J[n]=t,n},keyFor:function(e){if(!ie(e))throw TypeError(e+" is not a symbol");if(c(J,e))return J[e]},useSetter:function(){te=!0},useSimple:function(){te=!1}}),r({target:"Object",stat:!0,forced:!u,sham:!s},{create:function(e,t){return void 0===t?v(e):ae(v(e),t)},defineProperty:oe,defineProperties:ae,getOwnPropertyDescriptor:ue}),r({target:"Object",stat:!0,forced:!u},{getOwnPropertyNames:le,getOwnPropertySymbols:ce}),r({target:"Object",stat:!0,forced:l((function(){T.f(1)}))},{getOwnPropertySymbols:function(e){return T.f(p(e))}}),q)&&r({target:"JSON",stat:!0,forced:!u||l((function(){var e=z();return"[null]"!=q([e])||"{}"!=q({a:e})||"{}"!=q(Object(e))}))},{stringify:function(e,t,n){for(var r,i=[e],o=1;arguments.length>o;)i.push(arguments[o++]);if(r=t,(h(t)||void 0!==e)&&!ie(e))return f(t)||(t=function(e,t){if("function"==typeof r&&(t=r.call(this,e,t)),!ie(t))return t}),i[1]=t,q.apply(null,i)}});z.prototype[B]||k(z.prototype,B,z.prototype.valueOf),D(z,"Symbol"),R[U]=!0},function(e,t,n){var r=n(14),i=n(114),o=r["__core-js_shared__"]||i("__core-js_shared__",{});e.exports=o},function(e,t,n){var r=n(36),i=n(150),o=n(49),a=n(27);e.exports=function(e,t){for(var n=i(t),s=a.f,u=o.f,l=0;l<n.length;l++){var c=n[l];r(e,c)||s(e,c,u(t,c))}}},function(e,t,n){var r=n(151),i=n(36),o=n(157),a=n(27).f;e.exports=function(e){var t=r.Symbol||(r.Symbol={});i(t,e)||a(t,e,{value:o.f(e)})}},function(e,t,n){"use strict";var r=n(6),i=n(11),o=n(54),a=n(18),s=n(20),u=n(15),l=n(56),c=n(77),f=n(78),h=n(16),d=n(120),p=h("isConcatSpreadable"),y=d>=51||!i((function(){var e=[];return e[p]=!1,e.concat()[0]!==e})),m=f("concat"),g=function(e){if(!a(e))return!1;var t=e[p];return void 0!==t?!!t:o(e)};r({target:"Array",proto:!0,forced:!y||!m},{concat:function(e){var t,n,r,i,o,a=s(this),f=c(a,0),h=0;for(t=-1,r=arguments.length;t<r;t++)if(g(o=-1===t?a:arguments[t])){if(h+(i=u(o.length))>9007199254740991)throw TypeError("Maximum allowed index exceeded");for(n=0;n<i;n++,h++)n in o&&l(f,h,o[n])}else{if(h>=9007199254740991)throw TypeError("Maximum allowed index exceeded");l(f,h++,o)}return f.length=h,f}})},function(e,t,n){var r=n(6),i=n(250),o=n(42);r({target:"Array",proto:!0},{copyWithin:i}),o("copyWithin")},function(e,t,n){"use strict";var r=n(20),i=n(63),o=n(15),a=Math.min;e.exports=[].copyWithin||function(e,t){var n=r(this),s=o(n.length),u=i(e,s),l=i(t,s),c=arguments.length>2?arguments[2]:void 0,f=a((void 0===c?s:i(c,s))-l,s-u),h=1;for(l<u&&u<l+f&&(h=-1,l+=f-1,u+=f-1);f-- >0;)l in n?n[u]=n[l]:delete n[u],u+=h,l+=h;return n}},function(e,t,n){"use strict";var r=n(6),i=n(47).every;r({target:"Array",proto:!0,forced:n(48)("every")},{every:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(6),i=n(253),o=n(42);r({target:"Array",proto:!0},{fill:i}),o("fill")},function(e,t,n){"use strict";var r=n(20),i=n(63),o=n(15);e.exports=function(e){for(var t=r(this),n=o(t.length),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,l=void 0===u?n:i(u,n);l>s;)t[s++]=e;return t}},function(e,t,n){"use strict";var r=n(6),i=n(47).find,o=n(42),a=!0;"find"in[]&&Array(1).find((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{find:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("find")},function(e,t,n){"use strict";var r=n(6),i=n(47).findIndex,o=n(42),a=!0;"findIndex"in[]&&Array(1).findIndex((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("findIndex")},function(e,t,n){"use strict";var r=n(6),i=n(159),o=n(20),a=n(15),s=n(52),u=n(77);r({target:"Array",proto:!0},{flat:function(){var e=arguments.length?arguments[0]:void 0,t=o(this),n=a(t.length),r=u(t,0);return r.length=i(r,t,t,n,0,void 0===e?1:s(e)),r}})},function(e,t,n){"use strict";var r=n(6),i=n(159),o=n(20),a=n(15),s=n(37),u=n(77);r({target:"Array",proto:!0},{flatMap:function(e){var t,n=o(this),r=a(n.length);return s(e),(t=u(n,0)).length=i(t,n,n,r,0,1,e,arguments.length>1?arguments[1]:void 0),t}})},function(e,t,n){var r=n(6),i=n(259);r({target:"Array",stat:!0,forced:!n(122)((function(e){Array.from(e)}))},{from:i})},function(e,t,n){"use strict";var r=n(65),i=n(20),o=n(162),a=n(163),s=n(15),u=n(56),l=n(164);e.exports=function(e){var t,n,c,f,h,d=i(e),p="function"==typeof this?this:Array,y=arguments.length,m=y>1?arguments[1]:void 0,g=void 0!==m,v=0,b=l(d);if(g&&(m=r(m,y>2?arguments[2]:void 0,2)),null==b||p==Array&&a(b))for(n=new p(t=s(d.length));t>v;v++)u(n,v,g?m(d[v],v):d[v]);else for(h=(f=b.call(d)).next,n=new p;!(c=h.call(f)).done;v++)u(n,v,g?o(f,m,[c.value,v],!0):c.value);return n.length=v,n}},function(e,t,n){"use strict";var r=n(6),i=n(116).includes,o=n(42);r({target:"Array",proto:!0},{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("includes")},function(e,t,n){"use strict";var r=n(6),i=n(116).indexOf,o=n(48),a=[].indexOf,s=!!a&&1/[1].indexOf(1,-0)<0,u=o("indexOf");r({target:"Array",proto:!0,forced:s||u},{indexOf:function(e){return s?a.apply(this,arguments)||0:i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){n(6)({target:"Array",stat:!0},{isArray:n(54)})},function(e,t,n){var r=n(18);e.exports=function(e){if(!r(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},function(e,t,n){"use strict";var r=n(6),i=n(73),o=n(32),a=n(48),s=[].join,u=i!=Object,l=a("join",",");r({target:"Array",proto:!0,forced:u||l},{join:function(e){return s.call(o(this),void 0===e?",":e)}})},function(e,t,n){var r=n(6),i=n(266);r({target:"Array",proto:!0,forced:i!==[].lastIndexOf},{lastIndexOf:i})},function(e,t,n){"use strict";var r=n(32),i=n(52),o=n(15),a=n(48),s=Math.min,u=[].lastIndexOf,l=!!u&&1/[1].lastIndexOf(1,-0)<0,c=a("lastIndexOf");e.exports=l||c?function(e){if(l)return u.apply(this,arguments)||0;var t=r(this),n=o(t.length),a=n-1;for(arguments.length>1&&(a=s(a,i(arguments[1]))),a<0&&(a=n+a);a>=0;a--)if(a in t&&t[a]===e)return a||0;return-1}:u},function(e,t,n){"use strict";var r=n(6),i=n(47).map;r({target:"Array",proto:!0,forced:!n(78)("map")},{map:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(11),o=n(56);r({target:"Array",stat:!0,forced:i((function(){function e(){}return!(Array.of.call(e)instanceof e)}))},{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)o(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var r=n(6),i=n(168).right;r({target:"Array",proto:!0,forced:n(48)("reduceRight")},{reduceRight:function(e){return i(this,e,arguments.length,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(54),o=[].reverse,a=[1,2];r({target:"Array",proto:!0,forced:String(a)===String(a.reverse())},{reverse:function(){return i(this)&&(this.length=this.length),o.call(this)}})},function(e,t,n){"use strict";var r=n(6),i=n(18),o=n(54),a=n(63),s=n(15),u=n(32),l=n(56),c=n(78),f=n(16)("species"),h=[].slice,d=Math.max;r({target:"Array",proto:!0,forced:!c("slice")},{slice:function(e,t){var n,r,c,p=u(this),y=s(p.length),m=a(e,y),g=a(void 0===t?y:t,y);if(o(p)&&("function"!=typeof(n=p.constructor)||n!==Array&&!o(n.prototype)?i(n)&&null===(n=n[f])&&(n=void 0):n=void 0,n===Array||void 0===n))return h.call(p,m,g);for(r=new(void 0===n?Array:n)(d(g-m,0)),c=0;m<g;m++,c++)m in p&&l(r,c,p[m]);return r.length=c,r}})},function(e,t,n){"use strict";var r=n(6),i=n(47).some;r({target:"Array",proto:!0,forced:n(48)("some")},{some:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(20),a=n(11),s=n(48),u=[].sort,l=[1,2,3],c=a((function(){l.sort(void 0)})),f=a((function(){l.sort(null)})),h=s("sort");r({target:"Array",proto:!0,forced:c||!f||h},{sort:function(e){return void 0===e?u.call(o(this)):u.call(o(this),i(e))}})},function(e,t,n){n(126)("Array")},function(e,t,n){"use strict";var r=n(6),i=n(63),o=n(52),a=n(15),s=n(20),u=n(77),l=n(56),c=n(78),f=Math.max,h=Math.min;r({target:"Array",proto:!0,forced:!c("splice")},{splice:function(e,t){var n,r,c,d,p,y,m=s(this),g=a(m.length),v=i(e,g),b=arguments.length;if(0===b?n=r=0:1===b?(n=0,r=g-v):(n=b-2,r=h(f(o(t),0),g-v)),g+n-r>9007199254740991)throw TypeError("Maximum allowed length exceeded");for(c=u(m,r),d=0;d<r;d++)(p=v+d)in m&&l(c,d,m[p]);if(c.length=r,n<r){for(d=v;d<g-r;d++)y=d+n,(p=d+r)in m?m[y]=m[p]:delete m[y];for(d=g;d>g-r+n;d--)delete m[d-1]}else if(n>r)for(d=g-r;d>v;d--)y=d+n-1,(p=d+r-1)in m?m[y]=m[p]:delete m[y];for(d=0;d<n;d++)m[d+v]=arguments[d+2];return m.length=g-r+n,c}})},function(e,t,n){n(42)("flat")},function(e,t,n){n(42)("flatMap")},function(e,t,n){var r=n(14);n(55)(r.JSON,"JSON",!0)},function(e,t,n){"use strict";var r=n(169),i=n(281);e.exports=r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i,!0)},function(e,t,n){var r=n(18),i=n(89);e.exports=function(e,t,n){var o,a;return i&&"function"==typeof(o=t.constructor)&&o!==n&&r(a=o.prototype)&&a!==n.prototype&&i(e,a),e}},function(e,t,n){"use strict";var r=n(27).f,i=n(64),o=n(92),a=n(65),s=n(91),u=n(53),l=n(124),c=n(126),f=n(17),h=n(57).fastKey,d=n(38),p=d.set,y=d.getterFor;e.exports={getConstructor:function(e,t,n,l){var c=e((function(e,r){s(e,c,t),p(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),f||(e.size=0),null!=r&&u(r,e[l],e,n)})),d=y(t),m=function(e,t,n){var r,i,o=d(e),a=g(e,t);return a?a.value=n:(o.last=a={index:i=h(t,!0),key:t,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=a),r&&(r.next=a),f?o.size++:e.size++,"F"!==i&&(o.index[i]=a)),e},g=function(e,t){var n,r=d(e),i=h(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return o(c.prototype,{clear:function(){for(var e=d(this),t=e.index,n=e.first;n;)n.removed=!0,n.previous&&(n.previous=n.previous.next=void 0),delete t[n.index],n=n.next;e.first=e.last=void 0,f?e.size=0:this.size=0},delete:function(e){var t=d(this),n=g(this,e);if(n){var r=n.next,i=n.previous;delete t.index[n.index],n.removed=!0,i&&(i.next=r),r&&(r.previous=i),t.first==n&&(t.first=r),t.last==n&&(t.last=i),f?t.size--:this.size--}return!!n},forEach:function(e){for(var t,n=d(this),r=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.next:n.first;)for(r(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!g(this,e)}}),o(c.prototype,n?{get:function(e){var t=g(this,e);return t&&t.value},set:function(e,t){return m(this,0===e?0:e,t)}}:{add:function(e){return m(this,e=0===e?0:e,e)}}),f&&r(c.prototype,"size",{get:function(){return d(this).size}}),c},setStrong:function(e,t,n){var r=t+" Iterator",i=y(t),o=y(r);l(e,t,(function(e,t){p(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){for(var e=o(this),t=e.kind,n=e.last;n&&n.removed;)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),c(t)}}},function(e,t,n){n(55)(Math,"Math",!0)},function(e,t,n){"use strict";var r=n(17),i=n(11),o=n(76),a=n(118),s=n(85),u=n(20),l=n(73),c=Object.assign;e.exports=!c||i((function(){var e={},t={},n=Symbol();return e[n]=7,"abcdefghijklmnopqrst".split("").forEach((function(e){t[e]=e})),7!=c({},e)[n]||"abcdefghijklmnopqrst"!=o(c({},t)).join("")}))?function(e,t){for(var n=u(e),i=arguments.length,c=1,f=a.f,h=s.f;i>c;)for(var d,p=l(arguments[c++]),y=f?o(p).concat(f(p)):o(p),m=y.length,g=0;m>g;)d=y[g++],r&&!h.call(p,d)||(n[d]=p[d]);return n}:c},function(e,t,n){n(6)({target:"Object",stat:!0,sham:!n(17)},{create:n(64)})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(37),u=n(27);i&&r({target:"Object",proto:!0,forced:o},{__defineGetter__:function(e,t){u.f(a(this),e,{get:s(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(6),i=n(17);r({target:"Object",stat:!0,forced:!i,sham:!i},{defineProperties:n(154)})},function(e,t,n){var r=n(6),i=n(17);r({target:"Object",stat:!0,forced:!i,sham:!i},{defineProperty:n(27).f})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(37),u=n(27);i&&r({target:"Object",proto:!0,forced:o},{__defineSetter__:function(e,t){u.f(a(this),e,{set:s(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(6),i=n(171).entries;r({target:"Object",stat:!0},{entries:function(e){return i(e)}})},function(e,t,n){var r=n(6),i=n(90),o=n(11),a=n(18),s=n(57).onFreeze,u=Object.freeze;r({target:"Object",stat:!0,forced:o((function(){u(1)})),sham:!i},{freeze:function(e){return u&&a(e)?u(s(e)):e}})},function(e,t,n){var r=n(6),i=n(53),o=n(56);r({target:"Object",stat:!0},{fromEntries:function(e){var t={};return i(e,(function(e,n){o(t,e,n)}),void 0,!0),t}})},function(e,t,n){var r=n(6),i=n(11),o=n(32),a=n(49).f,s=n(17),u=i((function(){a(1)}));r({target:"Object",stat:!0,forced:!s||u,sham:!s},{getOwnPropertyDescriptor:function(e,t){return a(o(e),t)}})},function(e,t,n){var r=n(6),i=n(17),o=n(150),a=n(32),s=n(49),u=n(56);r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(e){for(var t,n,r=a(e),i=s.f,l=o(r),c={},f=0;l.length>f;)void 0!==(n=i(r,t=l[f++]))&&u(c,t,n);return c}})},function(e,t,n){var r=n(6),i=n(11),o=n(156).f;r({target:"Object",stat:!0,forced:i((function(){return!Object.getOwnPropertyNames(1)}))},{getOwnPropertyNames:o})},function(e,t,n){var r=n(6),i=n(11),o=n(20),a=n(66),s=n(166);r({target:"Object",stat:!0,forced:i((function(){a(1)})),sham:!s},{getPrototypeOf:function(e){return a(o(e))}})},function(e,t,n){n(6)({target:"Object",stat:!0},{is:n(172)})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isExtensible;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isExtensible:function(e){return!!o(e)&&(!a||a(e))}})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isFrozen;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isFrozen:function(e){return!o(e)||!!a&&a(e)}})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isSealed;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isSealed:function(e){return!o(e)||!!a&&a(e)}})},function(e,t,n){var r=n(6),i=n(20),o=n(76);r({target:"Object",stat:!0,forced:n(11)((function(){o(1)}))},{keys:function(e){return o(i(e))}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(62),u=n(66),l=n(49).f;i&&r({target:"Object",proto:!0,forced:o},{__lookupGetter__:function(e){var t,n=a(this),r=s(e,!0);do{if(t=l(n,r))return t.get}while(n=u(n))}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(62),u=n(66),l=n(49).f;i&&r({target:"Object",proto:!0,forced:o},{__lookupSetter__:function(e){var t,n=a(this),r=s(e,!0);do{if(t=l(n,r))return t.set}while(n=u(n))}})},function(e,t,n){var r=n(6),i=n(18),o=n(57).onFreeze,a=n(90),s=n(11),u=Object.preventExtensions;r({target:"Object",stat:!0,forced:s((function(){u(1)})),sham:!a},{preventExtensions:function(e){return u&&i(e)?u(o(e)):e}})},function(e,t,n){var r=n(6),i=n(18),o=n(57).onFreeze,a=n(90),s=n(11),u=Object.seal;r({target:"Object",stat:!0,forced:s((function(){u(1)})),sham:!a},{seal:function(e){return u&&i(e)?u(o(e)):e}})},function(e,t,n){n(6)({target:"Object",stat:!0},{setPrototypeOf:n(89)})},function(e,t,n){"use strict";var r=n(121),i={};i[n(16)("toStringTag")]="z",e.exports="[object z]"!==String(i)?function(){return"[object "+r(this)+"]"}:i.toString},function(e,t,n){var r=n(6),i=n(171).values;r({target:"Object",stat:!0},{values:function(e){return i(e)}})},function(e,t,n){"use strict";var r,i,o,a,s=n(6),u=n(46),l=n(14),c=n(51),f=n(174),h=n(45),d=n(92),p=n(55),y=n(126),m=n(18),g=n(37),v=n(91),b=n(50),_=n(53),w=n(122),T=n(94),S=n(175).set,E=n(309),C=n(176),k=n(310),x=n(80),O=n(95),P=n(38),R=n(119),A=n(16),I=n(120),L=A("species"),j="Promise",D=P.get,N=P.set,M=P.getterFor(j),U=f,B=l.TypeError,F=l.document,V=l.process,H=c("fetch"),z=x.f,q=z,W="process"==b(V),$=!!(F&&F.createEvent&&l.dispatchEvent),G=R(j,(function(){if(66===I)return!0;if(!W&&"function"!=typeof PromiseRejectionEvent)return!0;if(u&&!U.prototype.finally)return!0;if(I>=51&&/native code/.test(U))return!1;var e=U.resolve(1),t=function(e){e((function(){}),(function(){}))};return(e.constructor={})[L]=t,!(e.then((function(){}))instanceof t)})),Y=G||!w((function(e){U.all(e).catch((function(){}))})),K=function(e){var t;return!(!m(e)||"function"!=typeof(t=e.then))&&t},X=function(e,t,n){if(!t.notified){t.notified=!0;var r=t.reactions;E((function(){for(var i=t.value,o=1==t.state,a=0;r.length>a;){var s,u,l,c=r[a++],f=o?c.ok:c.fail,h=c.resolve,d=c.reject,p=c.domain;try{f?(o||(2===t.rejection&&ee(e,t),t.rejection=1),!0===f?s=i:(p&&p.enter(),s=f(i),p&&(p.exit(),l=!0)),s===c.promise?d(B("Promise-chain cycle")):(u=K(s))?u.call(s,h,d):h(s)):d(i)}catch(e){p&&!l&&p.exit(),d(e)}}t.reactions=[],t.notified=!1,n&&!t.rejection&&J(e,t)}))}},Q=function(e,t,n){var r,i;$?((r=F.createEvent("Event")).promise=t,r.reason=n,r.initEvent(e,!1,!0),l.dispatchEvent(r)):r={promise:t,reason:n},(i=l["on"+e])?i(r):"unhandledrejection"===e&&k("Unhandled promise rejection",n)},J=function(e,t){S.call(l,(function(){var n,r=t.value;if(Z(t)&&(n=O((function(){W?V.emit("unhandledRejection",r,e):Q("unhandledrejection",e,r)})),t.rejection=W||Z(t)?2:1,n.error))throw n.value}))},Z=function(e){return 1!==e.rejection&&!e.parent},ee=function(e,t){S.call(l,(function(){W?V.emit("rejectionHandled",e):Q("rejectionhandled",e,t.value)}))},te=function(e,t,n,r){return function(i){e(t,n,i,r)}},ne=function(e,t,n,r){t.done||(t.done=!0,r&&(t=r),t.value=n,t.state=2,X(e,t,!0))},re=function(e,t,n,r){if(!t.done){t.done=!0,r&&(t=r);try{if(e===n)throw B("Promise can't be resolved itself");var i=K(n);i?E((function(){var r={done:!1};try{i.call(n,te(re,e,r,t),te(ne,e,r,t))}catch(n){ne(e,r,n,t)}})):(t.value=n,t.state=1,X(e,t,!1))}catch(n){ne(e,{done:!1},n,t)}}};G&&(U=function(e){v(this,U,j),g(e),r.call(this);var t=D(this);try{e(te(re,this,t),te(ne,this,t))}catch(e){ne(this,t,e)}},(r=function(e){N(this,{type:j,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=d(U.prototype,{then:function(e,t){var n=M(this),r=z(T(this,U));return r.ok="function"!=typeof e||e,r.fail="function"==typeof t&&t,r.domain=W?V.domain:void 0,n.parent=!0,n.reactions.push(r),0!=n.state&&X(this,n,!1),r.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new r,t=D(e);this.promise=e,this.resolve=te(re,e,t),this.reject=te(ne,e,t)},x.f=z=function(e){return e===U||e===o?new i(e):q(e)},u||"function"!=typeof f||(a=f.prototype.then,h(f.prototype,"then",(function(e,t){var n=this;return new U((function(e,t){a.call(n,e,t)})).then(e,t)}),{unsafe:!0}),"function"==typeof H&&s({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return C(U,H.apply(l,arguments))}}))),s({global:!0,wrap:!0,forced:G},{Promise:U}),p(U,j,!1,!0),y(j),o=c(j),s({target:j,stat:!0,forced:G},{reject:function(e){var t=z(this);return t.reject.call(void 0,e),t.promise}}),s({target:j,stat:!0,forced:u||G},{resolve:function(e){return C(u&&this===o?U:this,e)}}),s({target:j,stat:!0,forced:Y},{all:function(e){var t=this,n=z(t),r=n.resolve,i=n.reject,o=O((function(){var n=g(t.resolve),o=[],a=0,s=1;_(e,(function(e){var u=a++,l=!1;o.push(void 0),s++,n.call(t,e).then((function(e){l||(l=!0,o[u]=e,--s||r(o))}),i)})),--s||r(o)}));return o.error&&i(o.value),n.promise},race:function(e){var t=this,n=z(t),r=n.reject,i=O((function(){var i=g(t.resolve);_(e,(function(e){i.call(t,e).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},function(e,t,n){var r,i,o,a,s,u,l,c,f=n(14),h=n(49).f,d=n(50),p=n(175).set,y=n(88),m=f.MutationObserver||f.WebKitMutationObserver,g=f.process,v=f.Promise,b="process"==d(g),_=h(f,"queueMicrotask"),w=_&&_.value;w||(r=function(){var e,t;for(b&&(e=g.domain)&&e.exit();i;){t=i.fn,i=i.next;try{t()}catch(e){throw i?a():o=void 0,e}}o=void 0,e&&e.enter()},b?a=function(){g.nextTick(r)}:m&&!/(iphone|ipod|ipad).*applewebkit/i.test(y)?(s=!0,u=document.createTextNode(""),new m(r).observe(u,{characterData:!0}),a=function(){u.data=s=!s}):v&&v.resolve?(l=v.resolve(void 0),c=l.then,a=function(){c.call(l,r)}):a=function(){p.call(f,r)}),e.exports=w||function(e){var t={fn:e,next:void 0};o&&(o.next=t),i||(i=t,a()),o=t}},function(e,t,n){var r=n(14);e.exports=function(e,t){var n=r.console;n&&n.error&&(1===arguments.length?n.error(e):n.error(e,t))}},function(e,t,n){"use strict";var r=n(6),i=n(46),o=n(174),a=n(51),s=n(94),u=n(176),l=n(45);r({target:"Promise",proto:!0,real:!0},{finally:function(e){var t=s(this,a("Promise")),n="function"==typeof e;return this.then(n?function(n){return u(t,e()).then((function(){return n}))}:e,n?function(n){return u(t,e()).then((function(){throw n}))}:e)}}),i||"function"!=typeof o||o.prototype.finally||l(o.prototype,"finally",a("Promise").prototype.finally)},function(e,t,n){"use strict";var r=n(6),i=n(81).codeAt;r({target:"String",proto:!0},{codePointAt:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(6),i=n(15),o=n(128),a=n(26),s=n(129),u="".endsWith,l=Math.min;r({target:"String",proto:!0,forced:!s("endsWith")},{endsWith:function(e){var t=String(a(this));o(e);var n=arguments.length>1?arguments[1]:void 0,r=i(t.length),s=void 0===n?r:l(i(n),r),c=String(e);return u?u.call(t,c,s):t.slice(s-c.length,s)===c}})},function(e,t,n){var r=n(6),i=n(63),o=String.fromCharCode,a=String.fromCodePoint;r({target:"String",stat:!0,forced:!!a&&1!=a.length},{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,a=0;r>a;){if(t=+arguments[a++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?o(t):o(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var r=n(6),i=n(128),o=n(26);r({target:"String",proto:!0,forced:!n(129)("includes")},{includes:function(e){return!!~String(o(this)).indexOf(i(e),arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(180).end;r({target:"String",proto:!0,forced:n(182)},{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(180).start;r({target:"String",proto:!0,forced:n(182)},{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(6),i=n(32),o=n(15);r({target:"String",stat:!0},{raw:function(e){for(var t=i(e.raw),n=o(t.length),r=arguments.length,a=[],s=0;n>s;)a.push(String(t[s++])),s<r&&a.push(String(arguments[s]));return a.join("")}})},function(e,t,n){n(6)({target:"String",proto:!0},{repeat:n(181)})},function(e,t,n){"use strict";var r=n(98),i=n(25),o=n(26),a=n(172),s=n(100);r("search",1,(function(e,t,n){return[function(t){var n=o(this),r=null==t?void 0:t[e];return void 0!==r?r.call(t,n):new RegExp(t)[e](String(n))},function(e){var r=n(t,e,this);if(r.done)return r.value;var o=i(e),u=String(this),l=o.lastIndex;a(l,0)||(o.lastIndex=0);var c=s(o,u);return a(o.lastIndex,l)||(o.lastIndex=l),null===c?-1:c.index}]}))},function(e,t,n){"use strict";var r=n(98),i=n(97),o=n(25),a=n(26),s=n(94),u=n(99),l=n(15),c=n(100),f=n(96),h=n(11),d=[].push,p=Math.min,y=!h((function(){return!RegExp(4294967295,"y")}));r("split",2,(function(e,t,n){var r;return r="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(e,n){var r=String(a(this)),o=void 0===n?4294967295:n>>>0;if(0===o)return[];if(void 0===e)return[r];if(!i(e))return t.call(r,e,o);for(var s,u,l,c=[],h=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),p=0,y=new RegExp(e.source,h+"g");(s=f.call(y,r))&&!((u=y.lastIndex)>p&&(c.push(r.slice(p,s.index)),s.length>1&&s.index<r.length&&d.apply(c,s.slice(1)),l=s[0].length,p=u,c.length>=o));)y.lastIndex===s.index&&y.lastIndex++;return p===r.length?!l&&y.test("")||c.push(""):c.push(r.slice(p)),c.length>o?c.slice(0,o):c}:"0".split(void 0,0).length?function(e,n){return void 0===e&&0===n?[]:t.call(this,e,n)}:t,[function(t,n){var i=a(this),o=null==t?void 0:t[e];return void 0!==o?o.call(t,i,n):r.call(String(i),t,n)},function(e,i){var a=n(r,e,this,i,r!==t);if(a.done)return a.value;var f=o(e),h=String(this),d=s(f,RegExp),m=f.unicode,g=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(y?"y":"g"),v=new d(y?f:"^(?:"+f.source+")",g),b=void 0===i?4294967295:i>>>0;if(0===b)return[];if(0===h.length)return null===c(v,h)?[h]:[];for(var _=0,w=0,T=[];w<h.length;){v.lastIndex=y?w:0;var S,E=c(v,y?h:h.slice(w));if(null===E||(S=p(l(v.lastIndex+(y?0:w)),h.length))===_)w=u(h,w,m);else{if(T.push(h.slice(_,w)),T.length===b)return T;for(var C=1;C<=E.length-1;C++)if(T.push(E[C]),T.length===b)return T;w=_=S}}return T.push(h.slice(_)),T}]}),!y)},function(e,t,n){"use strict";var r=n(6),i=n(15),o=n(128),a=n(26),s=n(129),u="".startsWith,l=Math.min;r({target:"String",proto:!0,forced:!s("startsWith")},{startsWith:function(e){var t=String(a(this));o(e);var n=i(l(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return u?u.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";var r=n(6),i=n(101).trim;r({target:"String",proto:!0,forced:n(131)("trim")},{trim:function(){return i(this)}})},function(e,t,n){"use strict";var r=n(6),i=n(101).end,o=n(131)("trimEnd"),a=o?function(){return i(this)}:"".trimEnd;r({target:"String",proto:!0,forced:o},{trimEnd:a,trimRight:a})},function(e,t,n){"use strict";var r=n(6),i=n(101).start,o=n(131)("trimStart"),a=o?function(){return i(this)}:"".trimStart;r({target:"String",proto:!0,forced:o},{trimStart:a,trimLeft:a})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("anchor")},{anchor:function(e){return i(this,"a","name",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("big")},{big:function(){return i(this,"big","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("blink")},{blink:function(){return i(this,"blink","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("bold")},{bold:function(){return i(this,"b","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fixed")},{fixed:function(){return i(this,"tt","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fontcolor")},{fontcolor:function(e){return i(this,"font","color",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fontsize")},{fontsize:function(e){return i(this,"font","size",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("italics")},{italics:function(){return i(this,"i","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("link")},{link:function(e){return i(this,"a","href",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("small")},{small:function(){return i(this,"small","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("strike")},{strike:function(){return i(this,"strike","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("sub")},{sub:function(){return i(this,"sub","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("sup")},{sup:function(){return i(this,"sup","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(66),a=n(89),s=n(64),u=n(27),l=n(61),c=n(53),f=n(33),h=n(25),d=n(38),p=d.set,y=d.getterFor("AggregateError"),m=function(e,t){var n=this;if(!(n instanceof m))return new m(e,t);a&&(n=a(new Error(t),o(n)));var r=[];return c(e,r.push,r),i?p(n,{errors:r,type:"AggregateError"}):n.errors=r,void 0!==t&&f(n,"message",String(t)),n};m.prototype=s(Error.prototype,{constructor:l(5,m),message:l(5,""),name:l(5,"AggregateError"),toString:l(5,(function(){var e=h(this).name;e=void 0===e?"AggregateError":String(e);var t=this.message;return e+": "+(t=void 0===t?"":String(t))}))}),i&&u.f(m.prototype,"errors",{get:function(){return y(this).errors},configurable:!0}),r({global:!0},{AggregateError:m})},function(e,t,n){"use strict";var r=n(17),i=n(42),o=n(20),a=n(15),s=n(27).f;r&&!("lastIndex"in[])&&(s(Array.prototype,"lastIndex",{configurable:!0,get:function(){var e=o(this),t=a(e.length);return 0==t?0:t-1}}),i("lastIndex"))},function(e,t,n){"use strict";var r=n(17),i=n(42),o=n(20),a=n(15),s=n(27).f;r&&!("lastItem"in[])&&(s(Array.prototype,"lastItem",{configurable:!0,get:function(){var e=o(this),t=a(e.length);return 0==t?void 0:e[t-1]},set:function(e){var t=o(this),n=a(t.length);return t[0==n?0:n-1]=e}}),i("lastItem"))},function(e,t,n){n(343)},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(80),a=n(95),s=n(53);r({target:"Promise",stat:!0},{allSettled:function(e){var t=this,n=o.f(t),r=n.resolve,u=n.reject,l=a((function(){var n=i(t.resolve),o=[],a=0,u=1;s(e,(function(e){var i=a++,s=!1;o.push(void 0),u++,n.call(t,e).then((function(e){s||(s=!0,o[i]={status:"fulfilled",value:e},--u||r(o))}),(function(e){s||(s=!0,o[i]={status:"rejected",reason:e},--u||r(o))}))})),--u||r(o)}));return l.error&&u(l.value),n.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(51),a=n(80),s=n(95),u=n(53);r({target:"Promise",stat:!0},{any:function(e){var t=this,n=a.f(t),r=n.resolve,l=n.reject,c=s((function(){var n=i(t.resolve),a=[],s=0,c=1,f=!1;u(e,(function(e){var i=s++,u=!1;a.push(void 0),c++,n.call(t,e).then((function(e){u||f||(f=!0,r(e))}),(function(e){u||f||(u=!0,a[i]=e,--c||l(new(o("AggregateError"))(a,"No one promise resolved")))}))})),--c||l(new(o("AggregateError"))(a,"No one promise resolved"))}));return c.error&&l(c.value),n.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(80),o=n(95);r({target:"Promise",stat:!0},{try:function(e){var t=i.f(this),n=o(e);return(n.error?t.reject:t.resolve)(n.value),t.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(81).charAt;r({target:"String",proto:!0},{at:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(6),i=n(125),o=n(26),a=n(38),s=n(81),u=s.codeAt,l=s.charAt,c=a.set,f=a.getterFor("String Iterator"),h=i((function(e){c(this,{type:"String Iterator",string:e,index:0})}),"String",(function(){var e,t=f(this),n=t.string,r=t.index;return r>=n.length?{value:void 0,done:!0}:(e=l(n,r),t.index+=e.length,{value:{codePoint:u(e,0),position:r},done:!1})}));r({target:"String",proto:!0},{codePoints:function(){return new h(String(o(this)))}})},function(e,t,n){n(349)},function(e,t,n){"use strict";var r=n(6),i=n(125),o=n(26),a=n(15),s=n(37),u=n(25),l=n(121),c=n(97),f=n(127),h=n(33),d=n(11),p=n(16),y=n(94),m=n(99),g=n(38),v=n(46),b=p("matchAll"),_=g.set,w=g.getterFor("RegExp String Iterator"),T=RegExp.prototype,S=T.exec,E="".matchAll,C=!!E&&!d((function(){"a".matchAll(/./)})),k=i((function(e,t,n,r){_(this,{type:"RegExp String Iterator",regexp:e,string:t,global:n,unicode:r,done:!1})}),"RegExp String",(function(){var e=w(this);if(e.done)return{value:void 0,done:!0};var t=e.regexp,n=e.string,r=function(e,t){var n,r=e.exec;if("function"==typeof r){if("object"!=typeof(n=r.call(e,t)))throw TypeError("Incorrect exec result");return n}return S.call(e,t)}(t,n);return null===r?{value:void 0,done:e.done=!0}:e.global?(""==String(r[0])&&(t.lastIndex=m(n,a(t.lastIndex),e.unicode)),{value:r,done:!1}):(e.done=!0,{value:r,done:!1})})),x=function(e){var t,n,r,i,o,s,l=u(this),c=String(e);return t=y(l,RegExp),void 0===(n=l.flags)&&l instanceof RegExp&&!("flags"in T)&&(n=f.call(l)),r=void 0===n?"":String(n),i=new t(t===RegExp?l.source:l,r),o=!!~r.indexOf("g"),s=!!~r.indexOf("u"),i.lastIndex=a(l.lastIndex),new k(i,c,o,s)};r({target:"String",proto:!0,forced:C},{matchAll:function(e){var t,n,r,i=o(this);if(null!=e){if(c(e)&&!~String(o("flags"in T?e.flags:f.call(e))).indexOf("g"))throw TypeError("`.matchAll` does not allow non-global regexes");if(C)return E.apply(i,arguments);if(void 0===(n=e[b])&&v&&"RegExp"==l(e)&&(n=x),null!=n)return s(n).call(e,i)}else if(C)return E.apply(i,arguments);return t=String(i),r=new RegExp(e,"g"),v?x.call(r,t):r[b](t)}}),v||b in T||h(T,b,x)},function(e,t,n){"use strict";var r=n(6),i=n(26),o=n(97),a=n(127),s=n(16),u=n(46),l=s("replace"),c=RegExp.prototype;r({target:"String",proto:!0},{replaceAll:function e(t,n){var r,s,f,h,d,p,y,m=i(this);if(null!=t){if((r=o(t))&&!~String(i("flags"in c?t.flags:a.call(t))).indexOf("g"))throw TypeError("`.replaceAll` does not allow non-global regexes");if(void 0!==(s=t[l]))return s.call(t,m,n);if(u&&r)return String(m).replace(t,n)}if(f=String(m),""===(h=String(t)))return e.call(f,/(?:)/g,n);if(d=f.split(h),"function"!=typeof n)return d.join(String(n));for(p=d[0],y=1;y<d.length;y++)p+=String(n(h,y-1,f)),p+=d[y];return p}})},function(e,t,n){var r=function(e){"use strict";var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},i=r.iterator||"@@iterator",o=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(e){s=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var i=t&&t.prototype instanceof f?t:f,o=Object.create(i.prototype),a=new S(r||[]);return o._invoke=function(e,t,n){var r="suspendedStart";return function(i,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===i)throw o;return C()}for(n.method=i,n.arg=o;;){var a=n.delegate;if(a){var s=_(a,n);if(s){if(s===c)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var u=l(e,t,n);if("normal"===u.type){if(r=n.done?"completed":"suspendedYield",u.arg===c)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r="completed",n.method="throw",n.arg=u.arg)}}}(e,n,a),o}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=u;var c={};function f(){}function h(){}function d(){}var p={};p[i]=function(){return this};var y=Object.getPrototypeOf,m=y&&y(y(E([])));m&&m!==t&&n.call(m,i)&&(p=m);var g=d.prototype=f.prototype=Object.create(p);function v(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function b(e,t){var r;this._invoke=function(i,o){function a(){return new t((function(r,a){!function r(i,o,a,s){var u=l(e[i],e,o);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,a,s)}),(function(e){r("throw",e,a,s)})):t.resolve(f).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,s)}))}s(u.arg)}(i,o,r,a)}))}return r=r?r.then(a,a):a()}}function _(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method))return c;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return c}var r=l(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,c;var i=r.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,c):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,c)}function w(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function T(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function S(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(w,this),this.reset(!0)}function E(e){if(e){var t=e[i];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return o.next=o}}return{next:C}}function C(){return{value:void 0,done:!0}}return h.prototype=g.constructor=d,d.constructor=h,h.displayName=s(d,a,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,d):(e.__proto__=d,s(e,a,"GeneratorFunction")),e.prototype=Object.create(g),e},e.awrap=function(e){return{__await:e}},v(b.prototype),b.prototype[o]=function(){return this},e.AsyncIterator=b,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new b(u(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},v(g),s(g,a,"Generator"),g[i]=function(){return this},g.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=E,S.prototype={constructor:S,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(T),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var s=n.call(o,"catchLoc"),u=n.call(o,"finallyLoc");if(s&&u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(s){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,c):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),c},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),T(n),c}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;T(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:E(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),c}},e}(e.exports);try{regeneratorRuntime=r}catch(e){Function("r","regeneratorRuntime = r")(r)}},function(e,t,n){},function(e,t,n){"use strict";
|
|
46
|
+
*/var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,s,u=a(e),l=1;l<arguments.length;l++){for(var c in n=Object(arguments[l]))i.call(n,c)&&(u[c]=n[c]);if(r){s=r(n);for(var f=0;f<s.length;f++)o.call(n,s[f])&&(u[s[f]]=n[s[f]])}}return u}},function(e,t){function n(e,t){for(var n in e)t[n]=e[n]}function r(e,t){var r=e.prototype;if(Object.create){var i=Object.create(t.prototype);r.__proto__=i}if(!(r instanceof t)){function o(){}o.prototype=t.prototype,n(r,o=new o),e.prototype=r=o}r.constructor!=e&&("function"!=typeof e&&console.error("unknow Class:"+e),r.constructor=e)}var i={},o=i.ELEMENT_NODE=1,a=i.ATTRIBUTE_NODE=2,s=i.TEXT_NODE=3,u=i.CDATA_SECTION_NODE=4,l=i.ENTITY_REFERENCE_NODE=5,c=i.ENTITY_NODE=6,f=i.PROCESSING_INSTRUCTION_NODE=7,h=i.COMMENT_NODE=8,d=i.DOCUMENT_NODE=9,p=i.DOCUMENT_TYPE_NODE=10,y=i.DOCUMENT_FRAGMENT_NODE=11,m=i.NOTATION_NODE=12,g={},v={},b=(g.INDEX_SIZE_ERR=(v[1]="Index size error",1),g.DOMSTRING_SIZE_ERR=(v[2]="DOMString size error",2),g.HIERARCHY_REQUEST_ERR=(v[3]="Hierarchy request error",3)),_=(g.WRONG_DOCUMENT_ERR=(v[4]="Wrong document",4),g.INVALID_CHARACTER_ERR=(v[5]="Invalid character",5),g.NO_DATA_ALLOWED_ERR=(v[6]="No data allowed",6),g.NO_MODIFICATION_ALLOWED_ERR=(v[7]="No modification allowed",7),g.NOT_FOUND_ERR=(v[8]="Not found",8)),w=(g.NOT_SUPPORTED_ERR=(v[9]="Not supported",9),g.INUSE_ATTRIBUTE_ERR=(v[10]="Attribute in use",10));g.INVALID_STATE_ERR=(v[11]="Invalid state",11),g.SYNTAX_ERR=(v[12]="Syntax error",12),g.INVALID_MODIFICATION_ERR=(v[13]="Invalid modification",13),g.NAMESPACE_ERR=(v[14]="Invalid namespace",14),g.INVALID_ACCESS_ERR=(v[15]="Invalid access",15);function T(e,t){if(t instanceof Error)var n=t;else n=this,Error.call(this,v[e]),this.message=v[e],Error.captureStackTrace&&Error.captureStackTrace(this,T);return n.code=e,t&&(this.message=this.message+": "+t),n}function S(){}function E(e,t){this._node=e,this._refresh=t,C(this)}function C(e){var t=e._node._inc||e._node.ownerDocument._inc;if(e._inc!=t){var r=e._refresh(e._node);te(e,"length",r.length),n(r,e),e._inc=t}}function k(){}function x(e,t){for(var n=e.length;n--;)if(e[n]===t)return n}function O(e,t,n,r){if(r?t[x(t,r)]=n:t[t.length++]=n,e){n.ownerElement=e;var i=e.ownerDocument;i&&(r&&D(i,e,r),function(e,t,n){e&&e._inc++,"http://www.w3.org/2000/xmlns/"==n.namespaceURI&&(t._nsMap[n.prefix?n.localName:""]=n.value)}(i,e,n))}}function P(e,t,n){var r=x(t,n);if(!(r>=0))throw T(_,new Error(e.tagName+"@"+n));for(var i=t.length-1;r<i;)t[r]=t[++r];if(t.length=i,e){var o=e.ownerDocument;o&&(D(o,e,n),n.ownerElement=null)}}function R(e){if(this._features={},e)for(var t in e)this._features=e[t]}function A(){}function I(e){return("<"==e?"<":">"==e&&">")||"&"==e&&"&"||'"'==e&&"""||"&#"+e.charCodeAt()+";"}function L(e,t){if(t(e))return!0;if(e=e.firstChild)do{if(L(e,t))return!0}while(e=e.nextSibling)}function j(){}function D(e,t,n,r){e&&e._inc++,"http://www.w3.org/2000/xmlns/"==n.namespaceURI&&delete t._nsMap[n.prefix?n.localName:""]}function N(e,t,n){if(e&&e._inc){e._inc++;var r=t.childNodes;if(n)r[r.length++]=n;else{for(var i=t.firstChild,o=0;i;)r[o++]=i,i=i.nextSibling;r.length=o}}}function M(e,t){var n=t.previousSibling,r=t.nextSibling;return n?n.nextSibling=r:e.firstChild=r,r?r.previousSibling=n:e.lastChild=n,N(e.ownerDocument,e),t}function U(e,t,n){var r=t.parentNode;if(r&&r.removeChild(t),t.nodeType===y){var i=t.firstChild;if(null==i)return t;var o=t.lastChild}else i=o=t;var a=n?n.previousSibling:e.lastChild;i.previousSibling=a,o.nextSibling=n,a?a.nextSibling=i:e.firstChild=i,null==n?e.lastChild=o:n.previousSibling=o;do{i.parentNode=e}while(i!==o&&(i=i.nextSibling));return N(e.ownerDocument||e,e),t.nodeType==y&&(t.firstChild=t.lastChild=null),t}function B(){this._nsMap={}}function F(){}function V(){}function H(){}function z(){}function q(){}function W(){}function $(){}function G(){}function Y(){}function K(){}function X(){}function Q(){}function J(e,t){var n=[],r=9==this.nodeType?this.documentElement:this,i=r.prefix,o=r.namespaceURI;if(o&&null==i&&null==(i=r.lookupPrefix(o)))var a=[{namespace:o,prefix:null}];return ee(this,n,e,t,a),n.join("")}function Z(e,t,n){var r=e.prefix||"",i=e.namespaceURI;if(!r&&!i)return!1;if("xml"===r&&"http://www.w3.org/XML/1998/namespace"===i||"http://www.w3.org/2000/xmlns/"==i)return!1;for(var o=n.length;o--;){var a=n[o];if(a.prefix==r)return a.namespace!=i}return!0}function ee(e,t,n,r,i){if(r){if(!(e=r(e)))return;if("string"==typeof e)return void t.push(e)}switch(e.nodeType){case o:i||(i=[]);i.length;var c=e.attributes,m=c.length,g=e.firstChild,v=e.tagName;n="http://www.w3.org/1999/xhtml"===e.namespaceURI||n,t.push("<",v);for(var b=0;b<m;b++){"xmlns"==(_=c.item(b)).prefix?i.push({prefix:_.localName,namespace:_.value}):"xmlns"==_.nodeName&&i.push({prefix:"",namespace:_.value})}for(b=0;b<m;b++){var _;if(Z(_=c.item(b),0,i)){var w=_.prefix||"",T=_.namespaceURI,S=w?" xmlns:"+w:" xmlns";t.push(S,'="',T,'"'),i.push({prefix:w,namespace:T})}ee(_,t,n,r,i)}if(Z(e,0,i)){w=e.prefix||"",T=e.namespaceURI,S=w?" xmlns:"+w:" xmlns";t.push(S,'="',T,'"'),i.push({prefix:w,namespace:T})}if(g||n&&!/^(?:meta|link|img|br|hr|input)$/i.test(v)){if(t.push(">"),n&&/^script$/i.test(v))for(;g;)g.data?t.push(g.data):ee(g,t,n,r,i),g=g.nextSibling;else for(;g;)ee(g,t,n,r,i),g=g.nextSibling;t.push("</",v,">")}else t.push("/>");return;case d:case y:for(g=e.firstChild;g;)ee(g,t,n,r,i),g=g.nextSibling;return;case a:return t.push(" ",e.name,'="',e.value.replace(/[<&"]/g,I),'"');case s:return t.push(e.data.replace(/[<&]/g,I));case u:return t.push("<![CDATA[",e.data,"]]>");case h:return t.push("\x3c!--",e.data,"--\x3e");case p:var E=e.publicId,C=e.systemId;if(t.push("<!DOCTYPE ",e.name),E)t.push(' PUBLIC "',E),C&&"."!=C&&t.push('" "',C),t.push('">');else if(C&&"."!=C)t.push(' SYSTEM "',C,'">');else{var k=e.internalSubset;k&&t.push(" [",k,"]"),t.push(">")}return;case f:return t.push("<?",e.target," ",e.data,"?>");case l:return t.push("&",e.nodeName,";");default:t.push("??",e.nodeName)}}function te(e,t,n){e[t]=n}T.prototype=Error.prototype,n(g,T),S.prototype={length:0,item:function(e){return this[e]||null},toString:function(e,t){for(var n=[],r=0;r<this.length;r++)ee(this[r],n,e,t);return n.join("")}},E.prototype.item=function(e){return C(this),this[e]},r(E,S),k.prototype={length:0,item:S.prototype.item,getNamedItem:function(e){for(var t=this.length;t--;){var n=this[t];if(n.nodeName==e)return n}},setNamedItem:function(e){var t=e.ownerElement;if(t&&t!=this._ownerElement)throw new T(w);var n=this.getNamedItem(e.nodeName);return O(this._ownerElement,this,e,n),n},setNamedItemNS:function(e){var t,n=e.ownerElement;if(n&&n!=this._ownerElement)throw new T(w);return t=this.getNamedItemNS(e.namespaceURI,e.localName),O(this._ownerElement,this,e,t),t},removeNamedItem:function(e){var t=this.getNamedItem(e);return P(this._ownerElement,this,t),t},removeNamedItemNS:function(e,t){var n=this.getNamedItemNS(e,t);return P(this._ownerElement,this,n),n},getNamedItemNS:function(e,t){for(var n=this.length;n--;){var r=this[n];if(r.localName==t&&r.namespaceURI==e)return r}return null}},R.prototype={hasFeature:function(e,t){var n=this._features[e.toLowerCase()];return!(!n||t&&!(t in n))},createDocument:function(e,t,n){var r=new j;if(r.implementation=this,r.childNodes=new S,r.doctype=n,n&&r.appendChild(n),t){var i=r.createElementNS(e,t);r.appendChild(i)}return r},createDocumentType:function(e,t,n){var r=new W;return r.name=e,r.nodeName=e,r.publicId=t,r.systemId=n,r}},A.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(e,t){return U(this,e,t)},replaceChild:function(e,t){this.insertBefore(e,t),t&&this.removeChild(t)},removeChild:function(e){return M(this,e)},appendChild:function(e){return this.insertBefore(e,null)},hasChildNodes:function(){return null!=this.firstChild},cloneNode:function(e){return function e(t,n,r){var i=new n.constructor;for(var s in n){var u=n[s];"object"!=typeof u&&u!=i[s]&&(i[s]=u)}n.childNodes&&(i.childNodes=new S);switch(i.ownerDocument=t,i.nodeType){case o:var l=n.attributes,c=i.attributes=new k,f=l.length;c._ownerElement=i;for(var h=0;h<f;h++)i.setAttributeNode(e(t,l.item(h),!0));break;case a:r=!0}if(r)for(var d=n.firstChild;d;)i.appendChild(e(t,d,r)),d=d.nextSibling;return i}(this.ownerDocument||this,this,e)},normalize:function(){for(var e=this.firstChild;e;){var t=e.nextSibling;t&&t.nodeType==s&&e.nodeType==s?(this.removeChild(t),e.appendData(t.data)):(e.normalize(),e=t)}},isSupported:function(e,t){return this.ownerDocument.implementation.hasFeature(e,t)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(e){for(var t=this;t;){var n=t._nsMap;if(n)for(var r in n)if(n[r]==e)return r;t=t.nodeType==a?t.ownerDocument:t.parentNode}return null},lookupNamespaceURI:function(e){for(var t=this;t;){var n=t._nsMap;if(n&&e in n)return n[e];t=t.nodeType==a?t.ownerDocument:t.parentNode}return null},isDefaultNamespace:function(e){return null==this.lookupPrefix(e)}},n(i,A),n(i,A.prototype),j.prototype={nodeName:"#document",nodeType:d,doctype:null,documentElement:null,_inc:1,insertBefore:function(e,t){if(e.nodeType==y){for(var n=e.firstChild;n;){var r=n.nextSibling;this.insertBefore(n,t),n=r}return e}return null==this.documentElement&&e.nodeType==o&&(this.documentElement=e),U(this,e,t),e.ownerDocument=this,e},removeChild:function(e){return this.documentElement==e&&(this.documentElement=null),M(this,e)},importNode:function(e,t){return function e(t,n,r){var i;switch(n.nodeType){case o:(i=n.cloneNode(!1)).ownerDocument=t;case y:break;case a:r=!0}i||(i=n.cloneNode(!1));if(i.ownerDocument=t,i.parentNode=null,r)for(var s=n.firstChild;s;)i.appendChild(e(t,s,r)),s=s.nextSibling;return i}(this,e,t)},getElementById:function(e){var t=null;return L(this.documentElement,(function(n){if(n.nodeType==o&&n.getAttribute("id")==e)return t=n,!0})),t},createElement:function(e){var t=new B;return t.ownerDocument=this,t.nodeName=e,t.tagName=e,t.childNodes=new S,(t.attributes=new k)._ownerElement=t,t},createDocumentFragment:function(){var e=new K;return e.ownerDocument=this,e.childNodes=new S,e},createTextNode:function(e){var t=new H;return t.ownerDocument=this,t.appendData(e),t},createComment:function(e){var t=new z;return t.ownerDocument=this,t.appendData(e),t},createCDATASection:function(e){var t=new q;return t.ownerDocument=this,t.appendData(e),t},createProcessingInstruction:function(e,t){var n=new X;return n.ownerDocument=this,n.tagName=n.target=e,n.nodeValue=n.data=t,n},createAttribute:function(e){var t=new F;return t.ownerDocument=this,t.name=e,t.nodeName=e,t.localName=e,t.specified=!0,t},createEntityReference:function(e){var t=new Y;return t.ownerDocument=this,t.nodeName=e,t},createElementNS:function(e,t){var n=new B,r=t.split(":"),i=n.attributes=new k;return n.childNodes=new S,n.ownerDocument=this,n.nodeName=t,n.tagName=t,n.namespaceURI=e,2==r.length?(n.prefix=r[0],n.localName=r[1]):n.localName=t,i._ownerElement=n,n},createAttributeNS:function(e,t){var n=new F,r=t.split(":");return n.ownerDocument=this,n.nodeName=t,n.name=t,n.namespaceURI=e,n.specified=!0,2==r.length?(n.prefix=r[0],n.localName=r[1]):n.localName=t,n}},r(j,A),B.prototype={nodeType:o,hasAttribute:function(e){return null!=this.getAttributeNode(e)},getAttribute:function(e){var t=this.getAttributeNode(e);return t&&t.value||""},getAttributeNode:function(e){return this.attributes.getNamedItem(e)},setAttribute:function(e,t){var n=this.ownerDocument.createAttribute(e);n.value=n.nodeValue=""+t,this.setAttributeNode(n)},removeAttribute:function(e){var t=this.getAttributeNode(e);t&&this.removeAttributeNode(t)},appendChild:function(e){return e.nodeType===y?this.insertBefore(e,null):function(e,t){var n=t.parentNode;if(n){var r=e.lastChild;n.removeChild(t);r=e.lastChild}return r=e.lastChild,t.parentNode=e,t.previousSibling=r,t.nextSibling=null,r?r.nextSibling=t:e.firstChild=t,e.lastChild=t,N(e.ownerDocument,e,t),t}(this,e)},setAttributeNode:function(e){return this.attributes.setNamedItem(e)},setAttributeNodeNS:function(e){return this.attributes.setNamedItemNS(e)},removeAttributeNode:function(e){return this.attributes.removeNamedItem(e.nodeName)},removeAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);n&&this.removeAttributeNode(n)},hasAttributeNS:function(e,t){return null!=this.getAttributeNodeNS(e,t)},getAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);return n&&n.value||""},setAttributeNS:function(e,t,n){var r=this.ownerDocument.createAttributeNS(e,t);r.value=r.nodeValue=""+n,this.setAttributeNode(r)},getAttributeNodeNS:function(e,t){return this.attributes.getNamedItemNS(e,t)},getElementsByTagName:function(e){return new E(this,(function(t){var n=[];return L(t,(function(r){r===t||r.nodeType!=o||"*"!==e&&r.tagName!=e||n.push(r)})),n}))},getElementsByTagNameNS:function(e,t){return new E(this,(function(n){var r=[];return L(n,(function(i){i===n||i.nodeType!==o||"*"!==e&&i.namespaceURI!==e||"*"!==t&&i.localName!=t||r.push(i)})),r}))}},j.prototype.getElementsByTagName=B.prototype.getElementsByTagName,j.prototype.getElementsByTagNameNS=B.prototype.getElementsByTagNameNS,r(B,A),F.prototype.nodeType=a,r(F,A),V.prototype={data:"",substringData:function(e,t){return this.data.substring(e,e+t)},appendData:function(e){e=this.data+e,this.nodeValue=this.data=e,this.length=e.length},insertData:function(e,t){this.replaceData(e,0,t)},appendChild:function(e){throw new Error(v[b])},deleteData:function(e,t){this.replaceData(e,t,"")},replaceData:function(e,t,n){n=this.data.substring(0,e)+n+this.data.substring(e+t),this.nodeValue=this.data=n,this.length=n.length}},r(V,A),H.prototype={nodeName:"#text",nodeType:s,splitText:function(e){var t=this.data,n=t.substring(e);t=t.substring(0,e),this.data=this.nodeValue=t,this.length=t.length;var r=this.ownerDocument.createTextNode(n);return this.parentNode&&this.parentNode.insertBefore(r,this.nextSibling),r}},r(H,V),z.prototype={nodeName:"#comment",nodeType:h},r(z,V),q.prototype={nodeName:"#cdata-section",nodeType:u},r(q,V),W.prototype.nodeType=p,r(W,A),$.prototype.nodeType=m,r($,A),G.prototype.nodeType=c,r(G,A),Y.prototype.nodeType=l,r(Y,A),K.prototype.nodeName="#document-fragment",K.prototype.nodeType=y,r(K,A),X.prototype.nodeType=f,r(X,A),Q.prototype.serializeToString=function(e,t,n){return J.call(e,t,n)},A.prototype.toString=J;try{if(Object.defineProperty){Object.defineProperty(E.prototype,"length",{get:function(){return C(this),this.$$length}}),Object.defineProperty(A.prototype,"textContent",{get:function(){return function e(t){switch(t.nodeType){case o:case y:var n=[];for(t=t.firstChild;t;)7!==t.nodeType&&8!==t.nodeType&&n.push(e(t)),t=t.nextSibling;return n.join("");default:return t.nodeValue}}(this)},set:function(e){switch(this.nodeType){case o:case y:for(;this.firstChild;)this.removeChild(this.firstChild);(e||String(e))&&this.appendChild(this.ownerDocument.createTextNode(e));break;default:this.data=e,this.value=e,this.nodeValue=e}}}),te=function(e,t,n){e["$$"+t]=n}}}catch(e){}t.DOMImplementation=R,t.XMLSerializer=Q},function(e,t,n){"use strict";e.exports={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21}},function(e,t){e.exports=function(e){var t="";return t+=String.fromCharCode(e[0]),t+=String.fromCharCode(e[1]),t+=String.fromCharCode(e[2]),t+=String.fromCharCode(e[3])}},function(e,t,n){"use strict";var r,i,o,a,s,u,l,c,f,h,d,p,y,m,g,v,b,_,w,T,S,E;n.d(t,"i",(function(){return r})),n.d(t,"a",(function(){return i})),n.d(t,"f",(function(){return o})),n.d(t,"j",(function(){return a})),n.d(t,"g",(function(){return d})),n.d(t,"e",(function(){return g})),n.d(t,"b",(function(){return w})),n.d(t,"d",(function(){return T})),n.d(t,"h",(function(){return S})),n.d(t,"c",(function(){return E})),function(e){e.Stream="cv_product_stream",e.StreamRaw="cv_product_stream_raw",e.WebPlayerStream="cv_product_webplayer_stream",e.StreamProgress="cv_product_stream_progress",e.Login="cv_product_login",e.LoginSsoRedirect="cv_product_login_sso_redirect",e.LoginFailed="cv_product_login_failed",e.Search="cv_product_search",e.InstantSearch="cv_product_search",e.SearchEmptyResult="cv_product_search_empty_result",e.Filter="cv_product_search_filter",e.SearchLanding="cv_product_search_landing",e.Share="cv_product_share",e.WorkspaceAdd="cv_product_tv_add",e.Rename="cv_product_rename",e.Move="cv_product_move",e.Sort="cv_product_sort",e.Create="cv_product_create",e.Delete="cv_product_delete",e.Associate="cv_product_associate",e.Dissociate="cv_product_dissociate",e.Edit="cv_product_edit",e.Approve="cv_product_approve",e.Reject="cv_product_reject",e.Disable="cv_product_disable",e.Upload="cv_product_upload",e.Download="cv_product_download",e.Navigate="cv_product_navigate",e.Click="cv_product_click",e.Suggest="cv_product_suggest",e.EditAssoc="cv_product_edit_assoc",e.Play="cv_product_play",e.Favourite="cv_product_favourite",e.Follow="cv_product_follow",e.Prefer="cv_product_prefer",e.Print="cv_product_print",e.Copy="cv_product_copy",e.Activate="cv_product_activate",e.VerifyEmail="cv_product_verify_email",e.ChangePassword="cv_product_change_password",e.Export="cv_product_export",e.SetAccess="cv_product_set_access",e.AddToLocalCache="cv_product_add_to_lc",e.ResolveWarning="cv_product_resolve_warning",e.DismissWarning="cv_product_dismiss_warning"}(r||(r={})),function(e){e.Folder="folder",e.Video="video",e.Rating="rating",e.Series="series",e.Library="library",e.Resource="resource",e.Tag="tag",e.Subtitle="subtitle",e.Chapter="chapter",e.Restriction="restriction",e.Interactive="interactive",e.PDF="pdf",e.CustomerSetting="customer_setting",e.UserSetting="user_setting",e.StaffRequest="staff_request",e.Logo="logo",e.Pagination="pagination",e.Thumbnail="thumbnail",e.Banner="banner",e.Link="link",e.Playlist="playlist",e.Playlists="playlists",e.Person="person",e.Company="company",e.Classroom="classroom",e.ClassroomGroup="classroom_group",e.Classification="classification",e.ShareLink="share_link",e.Upload="upload",e.SearchResults="search_results",e.Audience="audience",e.User="user",e.Clip="clip",e.UserChannel="user_channel",e.Widget="widget",e.Url="url",e.SocialShare="social_share"}(i||(i={})),function(e){e.TopNav="top_nav",e.LeftNav="left_nav",e.Popup="popup",e.Banner="banner",e.VideoList="video_list",e.VideoListItem="video_list_item",e.VideoListHeader="video_header",e.VideoThumbnail="video_thumbnail",e.ExpandableVideoThumbnail="expandable_video_thumbnail",e.VideoItemPreview="video_item_preview",e.VideoDetails="video_details",e.VideoDetailsHeader="video_details_header",e.EditVideoDetails="edit_video_details",e.EditVideoChapters="edit_video_chapters",e.EditVideoResources="edit_video_resources",e.VideoUpload="video_upload",e.VideoRequest="video_request",e.Pagination="pagination",e.LibraryHeader="library_header",e.LibraryTiles="library_tiles",e.StaffRequestDetails="staff_request_details",e.SubFolderList="sub_folder_list",e.AwaitingReviewVideoListHeader="awaiting_review_video_list_header",e.AwaitingReviewVideoItem="awaiting_review_video_item",e.PastReleasesHeader="past_releases_header",e.MigrationWarnings="migration_warnings",e.PlaylistListHeader="playlist_list_header",e.PlaylistListItem="playlist_list_item",e.SeriesListItem="series_list_item",e.SearchBar="search_bar",e.InstantSearch="instant_search",e.SearchFilters="search_filters",e.FeaturedSeriesSearchResult="featured_series_search_result",e.StaffManager="staff_manager",e.StaffManagerListItem="staff_manager_list_item",e.StudentManager="student_manager",e.StudentManagerListItem="student_manager_list_item",e.ClassroomsList="classrooms_list",e.ClassroomsListItem="classrooms_list_item",e.ClassroomOverview="classroom_overview",e.ClassroomOverviewStudentListItem="classroom_overview_student_list_item",e.ManageClassroomStudents="manage_classroom_students",e.ManageClassroomStudentListItem="manage_classroom_student_list_item",e.ManageClassroomGroups="manage_classroom_groups",e.ManageClassroomGroupListItem="manage_classroom_group_list_item",e.PreviewInteractive="preview_interactive",e.PreviewInteractiveQuestions="preview_interactive_questions",e.EditInteractive="edit_interactive",e.PlaySharedInteractive="play_shared_interactive",e.InteractiveListItem="interactive_list_item",e.DeleteInteractive="delete_interactive",e.PlayPage="play_page",e.Player="player",e.FloatingPlayer="floating_player",e.InteractivePlayer="interactive_player",e.EmbeddedPlayer="embedded_player",e.CreateClipPlayer="create_clip_player",e.PlaySharedClip="play_shared_clip",e.ClipListItem="clip_list_item",e.ContentUpdatesClassificationBanner="content_updates_classification_banner",e.PreferencesSettings="preferences_settings",e.MyUploads="my_uploads",e.SlidingList="sliding_list",e.HeroBannerItem="hero_banner_item",e.SlidingListItem="sliding_list_item",e.ClassificationListItem="classification_list_item",e.ClassificationComingSoon="classification_coming_soon",e.ClassificationHero="classification_hero",e.Dashboard="dashboard",e.ProductBanner="product_banner",e.Settings="settings"}(o||(o={})),function(e){e.Start="start",e.Complete="complete",e.Save="save",e.Discard="discard"}(a||(a={})),function(e){e.PageLoad="page_load"}(s||(s={})),function(e){e.Single="single",e.Bulk="bulk",e.All="all"}(u||(u={})),function(e){e.ProductionYear="production_year",e.Alphabetical="alphabetical"}(l||(l={})),function(e){e.Content="content",e.Quality="quality",e.Duration="duration",e.Reset="reset"}(c||(c={})),function(e){e.Submit="submit",e.ShowAll="show_all",e.Recent="recent",e.SearchIcon="search_icon"}(f||(f={})),function(e){e.Start="start",e.Finish="finish",e.Terminate="terminate",e.Play="play",e.Pause="pause",e.Playback="playback",e.NextChapter="next_chapter",e.PreviousChapter="previous_chapter",e.FullScreenEnter="full_screen_enter",e.FullScreenExit="full_screen_exit"}(h||(h={})),function(e){e.Embedded="embedded"}(d||(d={})),function(e){e.TogglePreview="toggle_preview",e.NavigateHome="navigate_home",e.OpenInStaffView="open_in_staff_view",e.Title="title",e.ToggleHideValidListings="toggle_hide_valid_listings",e.LaunchImmersiveReader="launch_immersive_reader",e.CopyEmbedHtml="copy_embed_html",e.Close="close",e.Open="open",e.Button="button",e.Link="link",e.Tile="tile",e.Thumbnail="thumbnail",e.Cover="cover",e.TallPoster="tall_poster",e.Slide="slide",e.ExternalLink="external_link",e.ViewStudentWorkspace="view_student_workspace"}(p||(p={})),function(e){e.FeatureUserChannelVideo="feature_user_channel_video",e.RemoveFromUserChannelPlaylist="remove_from_user_channel_playlist",e.ShareClip="share_clip",e.ViewOriginalVideo="view_original_video",e.ShareInteractive="share_interactive",e.DeleteInteractiveVideo="delete_interactive_video",e.CopyInteractiveVideo="copy_interactive_video",e.EditInteractiveVideo="edit_interactive_video",e.PrintAsWorksheet="print_as_worksheet",e.PreviewInteractiveVideo="preview_interactive_video",e.ViewResults="view_results",e.MoveToAnotherFolder="move_to_another_folder",e.CreateInteractiveVideo="create_interactive_video",e.ShareVideo="share_video",e.EditVideo="edit_video",e.DownloadVideo="download_video",e.AddToExchange="add_to_exchange",e.AddToUserChannel="add_to_user_channel",e.CreateClip="create_clip",e.FlagVideo="flag_video",e.AddToLibrary="add_to_library",e.AddToWorkspace="add_to_workspace",e.AddToPlaylist="add_to_playlist",e.RemoveFromPlaylist="remove_from_playlist",e.AddCurriculumLink="add_curriculum_link",e.ViewCurriculumLinks="view_curriculum_links",e.OpenInCurator="open_in_curator",e.ManageVideoAccess="manage_video_access",e.Approve="approve",e.AddToLocalCache="add_to_local_cache",e.OpenInLibraryEditor="open_in_library_editor",e.PlayClip="play_clip",e.EditClip="edit_clip",e.DeleteClip="delete_clip",e.EditVideoDetails="edit_video_details",e.DeleteVideo="delete_video"}(y||(y={})),function(e){e.LibraryReview="library_review"}(m||(m={})),function(e){e.FileSelect="file_select",e.DragDrop="drag_drop"}(g||(g={})),function(e){e.Edit="edit"}(v||(v={})),function(e){e.Image="image",e.User="user",e.Playlist="playlist",e.Link="link",e.Avatar="avatar"}(b||(b={})),function(e){e.On="on",e.Off="off"}(_||(_={})),function(e){e.EntityRemoved="cv_entity_removed",e.ValueUpdated="cv_value_updated"}(w||(w={})),function(e){e.FileSelect="file_select",e.DragDrop="drag_drop"}(T||(T={})),function(e){e.Video="videos",e.Folder="categories",e.Series="series",e.Tags="tags",e.Subjects="subjects"}(S||(S={})),function(e){e[e.V1=1]="V1",e[e.V2=2]="V2"}(E||(E={}))},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";n.r(t);var r=n(23);n.d(t,"AppLinkHelper",(function(){return r.a})),n.d(t,"AppLinkUtility",(function(){return r.b}));var i=n(205);n.d(t,"Application",(function(){return i.a}));var o=n(206);n.d(t,"AppRouter",(function(){return o.a}));var a=n(207);n.d(t,"Behavior",(function(){return a.a}));var s=n(105);n.d(t,"Collection",(function(){return s.a}));var u=n(133);n.d(t,"CollectionView",(function(){return u.a})),n.d(t,"ComponentCollection",(function(){return u.a}));var l=n(8);n.d(t,"Error",(function(){return l.a})),n.d(t,"ErrorHelper",(function(){return l.c})),n.d(t,"SilentError",(function(){return l.d}));var c=n(208);n.d(t,"LayoutView",(function(){return c.a}));var f=n(209);n.d(t,"NestedModel",(function(){return f.a}));var h=n(210);n.d(t,"Service",(function(){return h.a}));var d=n(69);n.d(t,"Model",(function(){return d.a}));var p=n(83);n.d(t,"View",(function(){return p.b})),n.d(t,"Component",(function(){return p.a}));var y=n(13);n.d(t,"EventNames",(function(){return y.a}));var m=n(211);n.d(t,"LayoutService",(function(){return m.a}));var g=n(104);n.d(t,"Middleware",(function(){return g.a}));var v=n(39);n.d(t,"LocationUtils",(function(){return v.a}));var b=n(212);n.d(t,"Shell",(function(){return b.a}));var _=n(213);for(var w in _)["AppLinkHelper","AppLinkUtility","Application","AppRouter","Behavior","Collection","CollectionView","ComponentCollection","Error","ErrorHelper","SilentError","LayoutView","NestedModel","Service","Model","View","Component","EventNames","LayoutService","Middleware","LocationUtils","Shell","default"].indexOf(w)<0&&function(e){n.d(t,e,(function(){return _[e]}))}(w)},function(e,t,n){"use strict";n.d(t,"a",(function(){return b}));var r=n(4),i=n(10),o=n(29),a=n(13),s=n(22),u=n(8);function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(e){return function(e){if(Array.isArray(e))return f(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t,n){return(d="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=v(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function p(e,t){return(p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==l(t)&&"function"!=typeof t?g(e):t}function g(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function v(e){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var b=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}(f,e);var t,n,o,l=y(f);function f(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),(t=l.call(this,e)).mergeOptions(e,[].concat(c(t.defaultProps),c(t.props||[]))),r.result(g(t),"name")||u.c.throw(new u.b("BaseApplication must define a name")),r.result(g(t),"channelName")||u.c.throw(new u.b("BaseApplication must define a channelName")),t.listenTo(t.getGlobalRadioChannel("popup"),a.a.SHOW_POPUP,t.onShowPopup),t.listenTo(t.getGlobalRadioChannel("alert"),"show:alert",t.onShowAlert),t}return t=f,(n=[{key:"defaultProps",get:function(){return["shell","layoutService"]}},{key:"getGlobalRadioChannel",value:function(e){var t=this.shell.getGlobalRadioChannels()[e.toUpperCase()];return t||u.c.throw(new u.b("Global channel ".concat(t," does not exist"))),i.Radio.channel(t)}},{key:"onLoadLayout",value:function(){if(this.layoutOptions&&this.layoutOptions.name){var e=r.extend({},this.layoutOptions.options||{},{store:this.shell.store});this.layout=this.layoutService.getLayout(r.extend(this.layoutOptions,{options:e})),this.layout||u.c.throw(new u.b("Layout: ".concat(this.layoutOptions.name," does not exist or was not registered"))),this.shell.showView(this.layout),this.triggerMethod("layout:loaded")}}},{key:"onShowPopup",value:function(e){this.layout.getRegion("popup")||u.c.throw(new u.b("Your application layout must define a popup region")),this.layout.showChildView("popup",e)}},{key:"onShowAlert",value:function(e){var t=e.ctor,n=e.collection,r=this.layout.getRegion("alert");r?r.hasView()||this.layout.showChildView("alert",new t({collection:n})):u.c.throw(new u.b("Your application layout must define an alert region"))}},{key:"setDefaultQueryParams",value:function(e){this.defaultQueryParams&&(e=r.extend(this.defaultQueryParams,e)),this.defaultQueryParams=e}},{key:"getAndClearDefaultQueryParams",value:function(){var e=this.defaultQueryParams;return delete this.defaultQueryParams,e||{}}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],d(v(f.prototype),"listenTo",this))}}])&&h(t.prototype,n),o&&h(t,o),f}(o.Application)},function(e,t,n){"use strict";n.d(t,"a",(function(){return E}));var r=n(4),i=n(10),o=n(29),a=n(23),s=n(22),u=n(104),l=n(13),c=n(8),f=n(39),h=n(12);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function p(e){return function(e){if(Array.isArray(e))return y(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return y(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return y(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function g(e,t,n){return(g="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=w(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function v(e,t){return(v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=w(e);if(t){var i=w(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _(this,n)}}function _(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function w(e){return(w=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var T=/([A-Z])/g,S=/(^|:)(\w)/gi,E=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&v(e,t)}(y,e);var t,n,o,d=b(y);function y(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,y),(t=d.call(this,e)).bindDisposal(),t.processInternalRoutes(),t.processExternalRoutes(),t.processAppLinks(),t}return t=y,(n=[{key:"bindDisposal",value:function(){var e=this;this.listenTo(h.a.SHELL,l.a.ROUTE,(function(t){t.application!==e.channelName&&e.destroyApp()}))}},{key:"addRouteLookup",value:function(e,t){var n=this;this.options.shell.addRouteLookup("".concat(this.channelName,":").concat(e),(function(r,i){return a.a.buildRoute(t,{application:n.channelName,action:e,args:r,params:i})}))}},{key:"processInternalRoutes",value:function(){var e=this;r.each(r.keys(this.appRoutes),(function(t){var n=e.appRoutes[t],i=e.toEventName(n);e.addRouteLookup(i,t),e.listenTo(e.channelName,i,(function(n,i){i&&i.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),e.executeRoute(n,{isAppRoute:!0},(function(){var o=r.extend({},e.controller.getAndClearDefaultQueryParams(),n.params);n.params=o,f.a.UpdateUrl(t,n,i)}))}))}))}},{key:"processExternalRoutes",value:function(){var e=this;this.externalRoutes&&r.each(r.keys(this.externalRoutes),(function(t){var n=e.externalRoutes[t],r=e.toEventName(n);e.addRouteLookup(r,t),e.listenTo(e.channelName,r,(function(e,t){t&&t.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),f.a.PageLoad(a.a.getHref(e))}))}))}},{key:"processAppLinks",value:function(){var e=this;this.appLinks&&r.each(this.appLinks,(function(t){var n=e.toEventName(t);e.listenTo(e.channelName,n,(function(t,n){n&&n.usedHelper||c.c.throw(new c.b("Please use Core.AppLinkHelper.trigger({}) to trigger appLinks.")),e.executeRoute(t,{isAppRoute:!1})}))}))}},{key:"executeRoute",value:function(e,t,n){var o=this;this.validateAppLink(e);var s=this.toMethodName(e.action);a.b.routingStarted();var f=i.Radio.channel(h.a.SHELL);if(this.options.shell.isNavLocked())return f.trigger(l.a.NAV_IS_LOCKED,e),void a.b.routingEnded();var d=new u.a;r.each(this.filters,(function(e){return d.use(e)})),d.go({appLink:e,shell:this.options.shell},(function(){f.trigger(l.a.ROUTE,e,t),o.createApp();var i=o.controller;if(r.isFunction(i[s])||(a.b.routingEnded(),c.c.throw(new c.b("".concat(s," does not exist on the ").concat(r.result(i,"name"),".")))),!1===i.triggerMethod("before:action"))return i.triggerMethod("action:cancelled"),void a.b.routingEnded();i.triggerMethod("load:layout"),i[s].apply(i,[].concat(p(e.args||[]),[e.params||{}])),r.isFunction(n)&&n(),a.b.routingEnded()}))}},{key:"createApp",value:function(){this.controller||(this.controller=new this.options.appConstructor(this.options.appOptions),this.controller.start())}},{key:"destroyApp",value:function(){this.controller&&(this.controller.destroy(),delete this.controller)}},{key:"_addAppRoute",value:function(e,t,n){var i=this;this.route(t,n,(function(){for(var e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];var a={application:i.channelName,action:i.toEventName(n),args:t.slice(0,t.length-1),params:f.a.DeserializeQueryParams(t[t.length-1])};i.executeRoute(a,{isAppRoute:!0},(function(){f.a.UpdateQuery(r.extend(i.controller.getAndClearDefaultQueryParams(),a.params))}))}))}},{key:"toEventName",value:function(e){return e.replace(T,":$1").toLowerCase()}},{key:"toMethodName",value:function(e){var t=e.replace(S,(function(e,t,n){return n.toUpperCase()}));return t[0].toLowerCase()+t.slice(1,t.length)}},{key:"validateAppLink",value:function(e){e.application&&e.action||(a.b.routingEnded(),c.c.throw(new c.b("Invalid AppLink")))}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],g(w(y.prototype),"listenTo",this))}}])&&m(t.prototype,n),o&&m(t,o),y}(o.AppRouter)},function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(29),i=n(22);function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(f,e);var t,n,r,o=c(f);function f(){return a(this,f),o.apply(this,arguments)}return t=f,(n=[{key:"listenTo",value:function(){return i.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],u(h(f.prototype),"listenTo",this))}}])&&s(t.prototype,n),r&&s(t,r),f}(r.Behavior)},function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(83),i=n(41),o=n(8);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(c,e);var t,n,r,a=l(c);function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),a.call(this,e)}return t=c,r=[{key:"getCacheKey",value:function(e){o.c.throw(new i.a("Must define getCacheKey for ".concat(this.name,".")))}}],(n=[{key:"unmountRegion",value:function(e){this.trigger("unmount:".concat(e))}}])&&s(t.prototype,n),r&&s(t,r),c}(r.b)},function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(4),i=n(69),o=n(105);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=d(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d(e);if(t){var i=d(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(y,e);var t,n,h,p=f(y);function y(){return s(this,y),p.apply(this,arguments)}return t=y,(n=[{key:"set",value:function(e,t,n){var i,o;if(null===e)return this;for(i in"object"===a(e)?(o=e,n=t):(o={})[e]=t,n||(n={}),o)r.has(this.associations,i)&&(o[i]=this.setAssociation(i,o[i],n));return l(d(y.prototype),"set",this).call(this,o,n)}},{key:"get",value:function(e){var t=e.indexOf(".");if(-1===t)return l(d(y.prototype),"get",this).call(this,e);var n=e.substr(0,t),i=this.attributes[n];if(!i||!r.isFunction(i.get))return l(d(y.prototype),"get",this).call(this,e);var o=e.substr(t+1);return i.get(o)}},{key:"setAssociation",value:function(e,t,n){var a=this.associations[e],s=this.attributes[e];if(!r.isFunction(a))return t;if(n.unset)return s&&delete s.parent,delete this[e],s;if(s)return s instanceof i.a&&s.set(t,n),s instanceof o.a&&s.set(t,n),n.silent||this.trigger("change:".concat(e),this,t,n),s;var u=t instanceof i.a?t:new a(t,{parse:!0});return u.parent=this,this[e]=u,u}},{key:"toJSON",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var i=l(d(y.prototype),"toJSON",this).apply(this,t);return r.each(this.associations,(function(e,t){r.has(i,t)&&r.isFunction(i[t].toJSON)?i[t]=i[t].toJSON():i[t]=(new e).toJSON()})),i}},{key:"toFlatJSON",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.omit(l(d(y.prototype),"toJSON",this).apply(this,t),r.keys(this.associations))}}])&&u(t.prototype,n),h&&u(t,h),y}(i.a)},function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(29),i=n(22),o=n(8);function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(f,e);var t,n,r,a=c(f);function f(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),(t=a.call(this,e)).name||o.c.throw(new o.b("Your service must be named.")),t}return t=f,(n=[{key:"listenTo",value:function(){return i.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],u(h(f.prototype),"listenTo",this))}}])&&s(t.prototype,n),r&&s(t,r),f}(r.Object)},function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(4),i=n(29),o=n(22),a=n(8);function s(e){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return(l="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=d(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d(e);if(t){var i=d(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(h,e);var t,n,i,s=f(h);function h(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,h),(t=s.call(this,e)).layouts={},t.requiredRegions=e.requiredRegions,t}return t=h,(n=[{key:"clearLayout",value:function(){this.currentLayout&&(this.currentLayout.destroy(),delete this.currentLayout,delete this.currentLayoutCacheKey)}},{key:"registerLayout",value:function(e,t){return this.checkRequiredRegions(t),this.layouts[e]=t,this}},{key:"getLayout",value:function(e){var t=e.name,n=e.options,r=void 0===n?{}:n;this.layouts[t]||a.c.throw(new a.b("".concat(t," was not registered as a template.")));var i=this.layouts[t].getCacheKey(r);return this.currentLayoutCacheKey===i&&this.currentLayout?(this.currentLayout.triggerMethod("layout:requested",r),this.currentLayout):(this.clearLayout(),this.currentLayoutCacheKey=i,this.currentLayout=new this.layouts[t](r),this.listenToOnce(this.currentLayout,"destroy",this.clearLayout),this.currentLayout)}},{key:"checkRequiredRegions",value:function(e){r.each(this.requiredRegions,(function(t){r.has(r.result(e.prototype,"regions"),t)||a.c.throw(new a.b("Layout: ".concat(e.prototype.name," must define an ").concat(t," region.")))}))}},{key:"listenTo",value:function(){return o.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],l(d(h.prototype),"listenTo",this))}}])&&u(t.prototype,n),i&&u(t,i),h}(i.Object)},function(e,t,n){"use strict";n.d(t,"a",(function(){return T}));var r=n(4),i=n(10),o=n(29),a=n(23),s=n(22),u=n(12),l=n(8),c=n(13),f=n(39);function h(e){return(h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function d(e,t,n){return(d="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=g(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function p(e,t){return(p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g(e);if(t){var i=g(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==h(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _(e,t,n){return t&&b(e.prototype,t),n&&b(e,n),e}var w=function(){function e(t,n){v(this,e),this.application=t,this.options=n||{}}return _(e,[{key:"Application",get:function(){return this.application}},{key:"Options",get:function(){return this.options}}]),e}(),T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}(n,e);var t=y(n);function n(){return v(this,n),t.apply(this,arguments)}return _(n,[{key:"initialize",value:function(e){this.mergeOptions(e,["layoutService"]),this.applications=[],this.routeLookup={},this.shellState={navLock:!1,activeRoute:!1,currentAppLink:null},this.errorHandlers=[]}},{key:"bindListeners",value:function(){this.bindRouteLookup(),this.bindNavLockListeners(),this.bindAppLinkListeners(),this.bindErrorHandlers(),this.bindErrorListener()}},{key:"bindNavLockListeners",value:function(){var e=this;this.listenTo(u.a.SHELL,c.a.LOCK_NAV,(function(){return e.shellState.navLock=!0})),this.listenTo(u.a.SHELL,c.a.UNLOCK_NAV,(function(){return e.shellState.navLock=!1}))}},{key:"bindAppLinkListeners",value:function(){var e=this;this.listenTo(u.a.SHELL,c.a.ROUTING_START,(function(){return e.shellState.activeRoute=!0})),this.listenTo(u.a.SHELL,c.a.ROUTING_END,(function(){return e.shellState.activeRoute=!1})),this.listenTo(u.a.SHELL,c.a.ROUTE,(function(t){return e.shellState.currentAppLink=t}));var t=i.Radio.channel(u.a.SHELL);t.reply(c.a.HAS_ACTIVE_ROUTE,r.bind(this.hasActiveRoute,this)),t.reply(c.a.CURRENT_ROUTE,(function(){return e.shellState.currentAppLink}))}},{key:"bindErrorHandlers",value:function(){window.addEventListener("error",(function(){a.b.routingEnded()}))}},{key:"bindErrorListener",value:function(){var e=i.Radio.channel(u.a.SHELL);this.listenTo(e,c.a.ERROR,this.handleError)}},{key:"bindRouteLookup",value:function(){var e=this;i.Radio.channel(u.a.SHELL).reply(c.a.ROUTE_LOOKUP,(function(t,n,r){return!!e.routeLookup[t]&&e.routeLookup[t](n,r)}),this)}},{key:"addRouteLookup",value:function(e,t){this.routeLookup[e]=t}},{key:"registerApplication",value:function(e,t){return this.applications.push(new w(e,t)),this}},{key:"getGlobalRadioChannels",value:function(){return u.a}},{key:"isNavLocked",value:function(){return this.shellState.navLock}},{key:"start",value:function(e){var t=this;e||(e={}),this.runInitializationSteps(this,(function(){t.runStartUpSteps(t,e,(function(){d(g(n.prototype),"start",t).call(t,e)}))}))}},{key:"hasActiveRoute",value:function(){return this.shellState.activeRoute}},{key:"onStart",value:function(){var e=this;r.each(this.applications,(function(t){var n={appConstructor:t.Application,shell:e,appOptions:Object.assign({region:"",shell:e,layoutService:e.layoutService},t.Options)};new t.Application.router(n)})),this.bindListeners(),f.a.StartHistory()}},{key:"addInitializationStep",value:function(e){var t;return this.runInitializationSteps=(t=this.runInitializationSteps,function(n,r){return t(n,(function(){return e(n,r)}))}),this}},{key:"runInitializationSteps",value:function(e,t){t(e)}},{key:"addStartUpStep",value:function(e){var t;return this.runStartUpSteps=(t=this.runStartUpSteps,function(n,r,i){return t(n,r,(function(){return e(n,r,i)}))}),this}},{key:"runStartUpSteps",value:function(e,t,n){n(e,t)}},{key:"registerLayout",value:function(e,t){return this.layoutService.registerLayout(e,t),this}},{key:"registerErrorHandler",value:function(e,t){return e||l.c.throw(new l.b("An error must have a name in order to register a handler for it.")),r.any(this.errorHandlers,(function(t){return t.errorType===e}))&&l.c.throw(new l.b("An error handler for ".concat(e.prototype.name," has already been defined."))),this.errorHandlers.push({errorType:e,handler:t}),this}},{key:"handleError",value:function(e){var t=r.find(this.errorHandlers,(function(t){return e instanceof t.errorType}));t&&t.handler&&t.handler(e)}},{key:"registerStore",value:function(e){this.store=e}},{key:"listenTo",value:function(){return s.a.call(this,arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],arguments.length<=2?void 0:arguments[2],d(g(n.prototype),"listenTo",this))}}]),n}(o.Application)},function(e,t){},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){function t(t,n,r,i,o,a){var s=i||"<<anonymous>>",u=a||r;if(null==n[r])return t?new Error("Required "+o+" `"+u+"` was not specified in `"+s+"`."):null;for(var l=arguments.length,c=Array(l>6?l-6:0),f=6;f<l;f++)c[f-6]=arguments[f];return e.apply(void 0,[n,r,s,o,u].concat(c))}var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n},e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var r=c(n(68)),i=c(n(134)),o=c(n(67)),a=c(n(216)),s=c(n(1)),u=c(n(28)),l=c(n(431));function c(e){return e&&e.__esModule?e:{default:e}}function f(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var h={container:r.default.oneOfType([i.default,r.default.func]),onContainerResolved:r.default.func},d=function(e){var t,n;function r(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];if(t=e.call.apply(e,[this].concat(r))||this,!o.default)return f(t);var a=t.props.container;return"function"==typeof a&&(a=a()),a&&!u.default.findDOMNode(a)?f(t):(t.setContainer(a),t)}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.UNSAFE_componentWillReceiveProps=function(e){e.container!==this.props.container&&this.setContainer(e.container)},i.componentDidMount=function(){this._container?this.props.onContainerResolved&&this.props.onContainerResolved():(this.setContainer(this.props.container),this.forceUpdate(this.props.onContainerResolved))},i.componentWillUnmount=function(){this._container=null},i.setContainer=function(e){this._container=(0,l.default)(e,(0,a.default)().body)},i.render=function(){return this._container?this.props.children(this._container):null},r}(s.default.Component);d.propTypes=h;var p=d;t.default=p,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){return e&&e.ownerDocument||document},e.exports=t.default},function(e,t,n){"use strict";var r=Array.prototype.slice,i=n(218),o=Object.keys,a=o?function(e){return o(e)}:n(437),s=Object.keys;a.shim=function(){Object.keys?function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2)||(Object.keys=function(e){return i(e)?s(r.call(e)):s(e)}):Object.keys=a;return Object.keys||a},e.exports=a},function(e,t,n){"use strict";var r=Object.prototype.toString;e.exports=function(e){var t=r.call(e),n="[object Arguments]"===t;return n||(n="[object Array]"!==t&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===r.call(e.callee)),n}},function(e,t,n){"use strict";var r=n(220),i=n(136),o=i(r("String.prototype.indexOf"));e.exports=function(e,t){var n=r(e,!!t);return"function"==typeof n&&o(e,".prototype.")>-1?i(n):n}},function(e,t,n){"use strict";var r=SyntaxError,i=Function,o=TypeError,a=function(e){try{return i('"use strict"; return ('+e+").constructor;")()}catch(e){}},s=Object.getOwnPropertyDescriptor;if(s)try{s({},"")}catch(e){s=null}var u=function(){throw new o},l=s?function(){try{return u}catch(e){try{return s(arguments,"callee").get}catch(e){return u}}}():u,c=n(221)(),f=Object.getPrototypeOf||function(e){return e.__proto__},h={},d="undefined"==typeof Uint8Array?void 0:f(Uint8Array),p={"%AggregateError%":"undefined"==typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":c?f([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":h,"%AsyncGenerator%":h,"%AsyncGeneratorFunction%":h,"%AsyncIteratorPrototype%":h,"%Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"==typeof BigInt?void 0:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":h,"%Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":c?f(f([][Symbol.iterator]())):void 0,"%JSON%":"object"==typeof JSON?JSON:void 0,"%Map%":"undefined"==typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&c?f((new Map)[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?void 0:Promise,"%Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&c?f((new Set)[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":c?f(""[Symbol.iterator]()):void 0,"%Symbol%":c?Symbol:void 0,"%SyntaxError%":r,"%ThrowTypeError%":l,"%TypedArray%":d,"%TypeError%":o,"%Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet},y={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=n(135),g=n(441),v=m.call(Function.call,Array.prototype.concat),b=m.call(Function.apply,Array.prototype.splice),_=m.call(Function.call,String.prototype.replace),w=m.call(Function.call,String.prototype.slice),T=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,S=/\\(\\)?/g,E=function(e){var t=w(e,0,1),n=w(e,-1);if("%"===t&&"%"!==n)throw new r("invalid intrinsic syntax, expected closing `%`");if("%"===n&&"%"!==t)throw new r("invalid intrinsic syntax, expected opening `%`");var i=[];return _(e,T,(function(e,t,n,r){i[i.length]=n?_(r,S,"$1"):t||e})),i},C=function(e,t){var n,i=e;if(g(y,i)&&(i="%"+(n=y[i])[0]+"%"),g(p,i)){var s=p[i];if(s===h&&(s=function e(t){var n;if("%AsyncFunction%"===t)n=a("async function () {}");else if("%GeneratorFunction%"===t)n=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)n=a("async function* () {}");else if("%AsyncGenerator%"===t){var r=e("%AsyncGeneratorFunction%");r&&(n=r.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(n=f(i.prototype))}return p[t]=n,n}(i)),void 0===s&&!t)throw new o("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:i,value:s}}throw new r("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new o('"allowMissing" argument must be a boolean');var n=E(e),i=n.length>0?n[0]:"",a=C("%"+i+"%",t),u=a.name,l=a.value,c=!1,f=a.alias;f&&(i=f[0],b(n,v([0,1],f)));for(var h=1,d=!0;h<n.length;h+=1){var y=n[h],m=w(y,0,1),_=w(y,-1);if(('"'===m||"'"===m||"`"===m||'"'===_||"'"===_||"`"===_)&&m!==_)throw new r("property names with quotes must have matching quotes");if("constructor"!==y&&d||(c=!0),g(p,u="%"+(i+="."+y)+"%"))l=p[u];else if(null!=l){if(!(y in l)){if(!t)throw new o("base intrinsic for "+e+" exists, but the property is not available.");return}if(s&&h+1>=n.length){var T=s(l,y);l=(d=!!T)&&"get"in T&&!("originalValue"in T.get)?T.get:l[y]}else d=g(l,y),l=l[y];d&&!c&&(p[u]=l)}}return l}},function(e,t,n){"use strict";var r="undefined"!=typeof Symbol&&Symbol,i=n(439);e.exports=function(){return"function"==typeof r&&("function"==typeof Symbol&&("symbol"==typeof r("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},function(e,t,n){"use strict";var r=function(e){return e!=e};e.exports=function(e,t){return 0===e&&0===t?1/e==1/t:e===t||!(!r(e)||!r(t))}},function(e,t,n){"use strict";var r=n(222);e.exports=function(){return"function"==typeof Object.is?Object.is:r}},function(e,t,n){"use strict";var r=Object,i=TypeError;e.exports=function(){if(null!=this&&this!==r(this))throw new i("RegExp.prototype.flags getter called on non-object");var e="";return this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.dotAll&&(e+="s"),this.unicode&&(e+="u"),this.sticky&&(e+="y"),e}},function(e,t,n){"use strict";var r=n(224),i=n(82).supportsDescriptors,o=Object.getOwnPropertyDescriptor,a=TypeError;e.exports=function(){if(!i)throw new a("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");if("gim"===/a/gim.flags){var e=o(RegExp.prototype,"flags");if(e&&"function"==typeof e.get&&"boolean"==typeof/a/.dotAll)return e.get}return r}},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=t.animationEnd=t.animationDelay=t.animationTiming=t.animationDuration=t.animationName=t.transitionEnd=t.transitionDuration=t.transitionDelay=t.transitionTiming=t.transitionProperty=t.transform=void 0;var i,o,a,s,u,l,c,f,h,d,p,y=r(n(67)),m="transform";if(t.transform=m,t.animationEnd=a,t.transitionEnd=o,t.transitionDelay=c,t.transitionTiming=l,t.transitionDuration=u,t.transitionProperty=s,t.animationDelay=p,t.animationTiming=d,t.animationDuration=h,t.animationName=f,y.default){var g=function(){for(var e,t,n=document.createElement("div").style,r={O:function(e){return"o"+e.toLowerCase()},Moz:function(e){return e.toLowerCase()},Webkit:function(e){return"webkit"+e},ms:function(e){return"MS"+e}},i=Object.keys(r),o="",a=0;a<i.length;a++){var s=i[a];if(s+"TransitionProperty"in n){o="-"+s.toLowerCase(),e=r[s]("TransitionEnd"),t=r[s]("AnimationEnd");break}}!e&&"transitionProperty"in n&&(e="transitionend");!t&&"animationName"in n&&(t="animationend");return n=null,{animationEnd:t,transitionEnd:e,prefix:o}}();i=g.prefix,t.transitionEnd=o=g.transitionEnd,t.animationEnd=a=g.animationEnd,t.transform=m=i+"-"+m,t.transitionProperty=s=i+"-transition-property",t.transitionDuration=u=i+"-transition-duration",t.transitionDelay=c=i+"-transition-delay",t.transitionTiming=l=i+"-transition-timing-function",t.animationName=f=i+"-animation-name",t.animationDuration=h=i+"-animation-duration",t.animationTiming=d=i+"-animation-delay",t.animationDelay=p=i+"-animation-timing-function"}var v={transform:m,end:o,property:s,timing:l,delay:c,duration:u};t.default=v},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=function(e){return(0,i.default)(e.replace(o,"ms-"))};var i=r(n(452)),o=/^-ms-/;e.exports=t.default},function(e,t){e.exports=function(e,t){var n,r=null;try{n=JSON.parse(e,t)}catch(e){r=e}return[r,n]}},function(e,t,n){var r=n(132),i=n(363);function o(t,n,a){return i()?(e.exports=o=Reflect.construct,e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},e.exports.default=e.exports,e.exports.__esModule=!0),o.apply(null,arguments)}e.exports=o,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(132);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){function r(e){this.options=e||{locator:{}}}function i(){this.cdata=!1}function o(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}function a(e){if(e)return"\n@"+(e.systemId||"")+"#[line:"+e.lineNumber+",col:"+e.columnNumber+"]"}function s(e,t,n){return"string"==typeof e?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+"":e}function u(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}r.prototype.parseFromString=function(e,t){var n=this.options,r=new l,o=n.domBuilder||new i,s=n.errorHandler,u=n.locator,c=n.xmlns||{},f={lt:"<",gt:">",amp:"&",quot:'"',apos:"'"};return u&&o.setDocumentLocator(u),r.errorHandler=function(e,t,n){if(!e){if(t instanceof i)return t;e=t}var r={},o=e instanceof Function;function s(t){var i=e[t];!i&&o&&(i=2==e.length?function(n){e(t,n)}:e),r[t]=i&&function(e){i("[xmldom "+t+"]\t"+e+a(n))}||function(){}}return n=n||{},s("warning"),s("error"),s("fatalError"),r}(s,o,u),r.domBuilder=n.domBuilder||o,/\/x?html?$/.test(t)&&(f.nbsp=" ",f.copy="©",c[""]="http://www.w3.org/1999/xhtml"),c.xml=c.xml||"http://www.w3.org/XML/1998/namespace",e?r.parse(e,c,f):r.errorHandler.error("invalid doc source"),o.doc},i.prototype={startDocument:function(){this.doc=(new c).createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),s=r.length;u(this,a),this.currentElement=a,this.locator&&o(this.locator,a);for(var l=0;l<s;l++){e=r.getURI(l);var c=r.getValue(l),f=(n=r.getQName(l),i.createAttributeNS(e,n));this.locator&&o(r.getLocator(l),f),f.value=f.nodeValue=c,a.setAttributeNode(f)}},endElement:function(e,t,n){var r=this.currentElement;r.tagName;this.currentElement=r.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&o(this.locator,n),u(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=s.apply(this,arguments)){if(this.cdata)var r=this.doc.createCDATASection(e);else r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&o(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){(this.locator=e)&&(e.lineNumber=0)},comment:function(e,t,n){e=s.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&o(this.locator,r),u(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n){var r=this.doc.implementation;if(r&&r.createDocumentType){var i=r.createDocumentType(e,t,n);this.locator&&o(this.locator,i),u(this,i)}},warning:function(e){console.warn("[xmldom warning]\t"+e,a(this.locator))},error:function(e){console.error("[xmldom error]\t"+e,a(this.locator))},fatalError:function(e){throw console.error("[xmldom fatalError]\t"+e,a(this.locator)),e}},"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,(function(e){i.prototype[e]=function(){return null}}));var l=n(369).XMLReader,c=t.DOMImplementation=n(187).DOMImplementation;t.XMLSerializer=n(187).XMLSerializer,t.DOMParser=r},function(e,t){var n=Math.pow(2,32);e.exports=function(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength),r={version:e[0],flags:new Uint8Array(e.subarray(1,4)),references:[],referenceId:t.getUint32(4),timescale:t.getUint32(8)},i=12;0===r.version?(r.earliestPresentationTime=t.getUint32(i),r.firstOffset=t.getUint32(i+4),i+=8):(r.earliestPresentationTime=t.getUint32(i)*n+t.getUint32(i+4),r.firstOffset=t.getUint32(i+8)*n+t.getUint32(i+12),i+=16),i+=2;var o=t.getUint16(i);for(i+=2;o>0;i+=12,o--)r.references.push({referenceType:(128&e[i])>>>7,referencedSize:2147483647&t.getUint32(i),subsegmentDuration:t.getUint32(i+4),startsWithSap:!!(128&e[i+8]),sapType:(112&e[i+8])>>>4,sapDeltaTime:268435455&t.getUint32(i+8)});return r}},function(e,t,n){"use strict";var r=n(188),i=n(370).handleRollover,o={};o.ts=n(372),o.aac=n(373);var a=n(59).ONE_SECOND_IN_TS,s=function(e,t,n){for(var r,i,a,s,u=0,l=188,c=!1;l<=e.byteLength;)if(71!==e[u]||71!==e[l]&&l!==e.byteLength)u++,l++;else{switch(r=e.subarray(u,l),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u+=188,l+=188}for(u=(l=e.byteLength)-188,c=!1;u>=0;)if(71!==e[u]||71!==e[l]&&l!==e.byteLength)u--,l--;else{switch(r=e.subarray(u,l),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"audio"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="audio",n.audio.push(s),c=!0)}if(c)break;u-=188,l-=188}},u=function(e,t,n){for(var r,i,a,s,u,l,c,f=0,h=188,d=!1,p={data:[],size:0};h<e.byteLength;)if(71!==e[f]||71!==e[h])f++,h++;else{switch(r=e.subarray(f,h),o.ts.parseType(r,t.pid)){case"pes":if(i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&(a&&!d&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0),!n.firstKeyFrame)){if(a&&0!==p.size){for(u=new Uint8Array(p.size),l=0;p.data.length;)c=p.data.shift(),u.set(c,l),l+=c.byteLength;if(o.ts.videoPacketContainsKeyFrame(u)){var y=o.ts.parsePesTime(u);y?(n.firstKeyFrame=y,n.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}p.size=0}p.data.push(r),p.size+=r.byteLength}}if(d&&n.firstKeyFrame)break;f+=188,h+=188}for(f=(h=e.byteLength)-188,d=!1;f>=0;)if(71!==e[f]||71!==e[h])f--,h--;else{switch(r=e.subarray(f,h),o.ts.parseType(r,t.pid)){case"pes":i=o.ts.parsePesType(r,t.table),a=o.ts.parsePayloadUnitStartIndicator(r),"video"===i&&a&&(s=o.ts.parsePesTime(r))&&(s.type="video",n.video.push(s),d=!0)}if(d)break;f-=188,h-=188}},l=function(e){var t={pid:null,table:null},n={};for(var i in function(e,t){for(var n,r=0,i=188;i<e.byteLength;)if(71!==e[r]||71!==e[i])r++,i++;else{switch(n=e.subarray(r,i),o.ts.parseType(n,t.pid)){case"pat":t.pid||(t.pid=o.ts.parsePat(n));break;case"pmt":t.table||(t.table=o.ts.parsePmt(n))}if(t.pid&&t.table)return;r+=188,i+=188}}(e,t),t.table){if(t.table.hasOwnProperty(i))switch(t.table[i]){case r.H264_STREAM_TYPE:n.video=[],u(e,t,n),0===n.video.length&&delete n.video;break;case r.ADTS_STREAM_TYPE:n.audio=[],s(e,t,n),0===n.audio.length&&delete n.audio}}return n};e.exports={inspect:function(e,t){var n;return(n=o.aac.isLikelyAacData(e)?function(e){for(var t,n=!1,r=0,i=null,s=null,u=0,l=0;e.length-l>=3;){switch(o.aac.parseType(e,l)){case"timed-metadata":if(e.length-l<10){n=!0;break}if((u=o.aac.parseId3TagSize(e,l))>e.length){n=!0;break}null===s&&(t=e.subarray(l,l+u),s=o.aac.parseAacTimestamp(t)),l+=u;break;case"audio":if(e.length-l<7){n=!0;break}if((u=o.aac.parseAdtsSize(e,l))>e.length){n=!0;break}null===i&&(t=e.subarray(l,l+u),i=o.aac.parseSampleRate(t)),r++,l+=u;break;default:l++}if(n)return null}if(null===i||null===s)return null;var c=a/i;return{audio:[{type:"audio",dts:s,pts:s},{type:"audio",dts:s+1024*r*c,pts:s+1024*r*c}]}}(e):l(e))&&(n.audio||n.video)?(function(e,t){if(e.audio&&e.audio.length){var n=t;void 0===n&&(n=e.audio[0].dts),e.audio.forEach((function(e){e.dts=i(e.dts,n),e.pts=i(e.pts,n),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a}))}if(e.video&&e.video.length){var r=t;if(void 0===r&&(r=e.video[0].dts),e.video.forEach((function(e){e.dts=i(e.dts,r),e.pts=i(e.pts,r),e.dtsTime=e.dts/a,e.ptsTime=e.pts/a})),e.firstKeyFrame){var o=e.firstKeyFrame;o.dts=i(o.dts,r),o.pts=i(o.pts,r),o.dtsTime=o.dts/a,o.ptsTime=o.dts/a}}}(n,t),n):null},parseAudioPes_:s}},function(e){e.exports=JSON.parse('{"a":"0.0.4-rc.2"}')},function(e,t,n){(function(t){var n=/^\[object .+?Constructor\]$/,r="object"==typeof t&&t&&t.Object===Object&&t,i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();var a,s=Array.prototype,u=Function.prototype,l=Object.prototype,c=o["__core-js_shared__"],f=(a=/[^.]+$/.exec(c&&c.keys&&c.keys.IE_PROTO||""))?"Symbol(src)_1."+a:"",h=u.toString,d=l.hasOwnProperty,p=l.toString,y=RegExp("^"+h.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),m=s.splice,g=C(o,"Map"),v=C(Object,"create");function b(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function _(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function w(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function T(e,t){for(var n,r,i=e.length;i--;)if((n=e[i][0])===(r=t)||n!=n&&r!=r)return i;return-1}function S(e){return!(!x(e)||(t=e,f&&f in t))&&(function(e){var t=x(e)?p.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?y:n).test(function(e){if(null!=e){try{return h.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function E(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function C(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return S(n)?n:void 0}function k(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a),a};return n.cache=new(k.Cache||w),n}function x(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}b.prototype.clear=function(){this.__data__=v?v(null):{}},b.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},b.prototype.get=function(e){var t=this.__data__;if(v){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return d.call(t,e)?t[e]:void 0},b.prototype.has=function(e){var t=this.__data__;return v?void 0!==t[e]:d.call(t,e)},b.prototype.set=function(e,t){return this.__data__[e]=v&&void 0===t?"__lodash_hash_undefined__":t,this},_.prototype.clear=function(){this.__data__=[]},_.prototype.delete=function(e){var t=this.__data__,n=T(t,e);return!(n<0)&&(n==t.length-1?t.pop():m.call(t,n,1),!0)},_.prototype.get=function(e){var t=this.__data__,n=T(t,e);return n<0?void 0:t[n][1]},_.prototype.has=function(e){return T(this.__data__,e)>-1},_.prototype.set=function(e,t){var n=this.__data__,r=T(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},w.prototype.clear=function(){this.__data__={hash:new b,map:new(g||_),string:new b}},w.prototype.delete=function(e){return E(this,e).delete(e)},w.prototype.get=function(e){return E(this,e).get(e)},w.prototype.has=function(e){return E(this,e).has(e)},w.prototype.set=function(e,t){return E(this,e).set(e,t),this},k.Cache=w,e.exports=k}).call(this,n(30))},function(e,t,n){"use strict";(function(e){var n=function(){if("undefined"!=typeof Map)return Map;function e(e,t){var n=-1;return e.some((function(e,r){return e[0]===t&&(n=r,!0)})),n}return function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(t){var n=e(this.__entries__,t),r=this.__entries__[n];return r&&r[1]},t.prototype.set=function(t,n){var r=e(this.__entries__,t);~r?this.__entries__[r][1]=n:this.__entries__.push([t,n])},t.prototype.delete=function(t){var n=this.__entries__,r=e(n,t);~r&&n.splice(r,1)},t.prototype.has=function(t){return!!~e(this.__entries__,t)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(e,t){void 0===t&&(t=null);for(var n=0,r=this.__entries__;n<r.length;n++){var i=r[n];e.call(t,i[1],i[0])}},t}()}(),r="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,i=void 0!==e&&e.Math===Math?e:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),o="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(e){return setTimeout((function(){return e(Date.now())}),1e3/60)};var a=["top","right","bottom","left","width","height","size","weight"],s="undefined"!=typeof MutationObserver,u=function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(e,t){var n=!1,r=!1,i=0;function a(){n&&(n=!1,e()),r&&u()}function s(){o(a)}function u(){var e=Date.now();if(n){if(e-i<2)return;r=!0}else n=!0,r=!1,setTimeout(s,t);i=e}return u}(this.refresh.bind(this),20)}return e.prototype.addObserver=function(e){~this.observers_.indexOf(e)||this.observers_.push(e),this.connected_||this.connect_()},e.prototype.removeObserver=function(e){var t=this.observers_,n=t.indexOf(e);~n&&t.splice(n,1),!t.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},e.prototype.updateObservers_=function(){var e=this.observers_.filter((function(e){return e.gatherActive(),e.hasActive()}));return e.forEach((function(e){return e.broadcastActive()})),e.length>0},e.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),s?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(e){var t=e.propertyName,n=void 0===t?"":t;a.some((function(e){return!!~n.indexOf(e)}))&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),l=function(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var i=r[n];Object.defineProperty(e,i,{value:t[i],enumerable:!1,writable:!1,configurable:!0})}return e},c=function(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView||i},f=g(0,0,0,0);function h(e){return parseFloat(e)||0}function d(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.reduce((function(t,n){return t+h(e["border-"+n+"-width"])}),0)}function p(e){var t=e.clientWidth,n=e.clientHeight;if(!t&&!n)return f;var r=c(e).getComputedStyle(e),i=function(e){for(var t={},n=0,r=["top","right","bottom","left"];n<r.length;n++){var i=r[n],o=e["padding-"+i];t[i]=h(o)}return t}(r),o=i.left+i.right,a=i.top+i.bottom,s=h(r.width),u=h(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==t&&(s-=d(r,"left","right")+o),Math.round(u+a)!==n&&(u-=d(r,"top","bottom")+a)),!function(e){return e===c(e).document.documentElement}(e)){var l=Math.round(s+o)-t,p=Math.round(u+a)-n;1!==Math.abs(l)&&(s-=l),1!==Math.abs(p)&&(u-=p)}return g(i.left,i.top,s,u)}var y="undefined"!=typeof SVGGraphicsElement?function(e){return e instanceof c(e).SVGGraphicsElement}:function(e){return e instanceof c(e).SVGElement&&"function"==typeof e.getBBox};function m(e){return r?y(e)?function(e){var t=e.getBBox();return g(0,0,t.width,t.height)}(e):p(e):f}function g(e,t,n,r){return{x:e,y:t,width:n,height:r}}var v=function(){function e(e){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=g(0,0,0,0),this.target=e}return e.prototype.isActive=function(){var e=m(this.target);return this.contentRect_=e,e.width!==this.broadcastWidth||e.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var e=this.contentRect_;return this.broadcastWidth=e.width,this.broadcastHeight=e.height,e},e}(),b=function(e,t){var n,r,i,o,a,s,u,c=(r=(n=t).x,i=n.y,o=n.width,a=n.height,s="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,u=Object.create(s.prototype),l(u,{x:r,y:i,width:o,height:a,top:i,right:r+o,bottom:a+i,left:r}),u);l(this,{target:e,contentRect:c})},_=function(){function e(e,t,r){if(this.activeObservations_=[],this.observations_=new n,"function"!=typeof e)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=e,this.controller_=t,this.callbackCtx_=r}return e.prototype.observe=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof c(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)||(t.set(e,new v(e)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof c(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)&&(t.delete(e),t.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var e=this;this.clearActive(),this.observations_.forEach((function(t){t.isActive()&&e.activeObservations_.push(t)}))},e.prototype.broadcastActive=function(){if(this.hasActive()){var e=this.callbackCtx_,t=this.activeObservations_.map((function(e){return new b(e.target,e.broadcastRect())}));this.callback_.call(e,t,e),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e}(),w="undefined"!=typeof WeakMap?new WeakMap:new n,T=function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=u.getInstance(),r=new _(t,n,this);w.set(this,r)};["observe","unobserve","disconnect"].forEach((function(e){T.prototype[e]=function(){var t;return(t=w.get(this))[e].apply(t,arguments)}}));var S=void 0!==i.ResizeObserver?i.ResizeObserver:T;t.a=S}).call(this,n(30))},function(e,t,n){e.exports=function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)},t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function n(e,t,n,r){var i,o,a,s=t||[0],u=(n=n||0)>>>3,l=-1===r?3:0;for(i=0;i<e.length;i+=1)o=(a=i+u)>>>2,s.length<=o&&s.push(0),s[o]|=e[i]<<8*(l+r*(a%4));return{value:s,binLen:8*e.length+n}}function r(e,r,i){switch(r){case"UTF8":case"UTF16BE":case"UTF16LE":break;default:throw new Error("encoding must be UTF8, UTF16BE, or UTF16LE")}switch(e){case"HEX":return function(e,t,n){return function(e,t,n,r){var i,o,a,s;if(0!=e.length%2)throw new Error("String of HEX type must be in byte increments");var u=t||[0],l=(n=n||0)>>>3,c=-1===r?3:0;for(i=0;i<e.length;i+=2){if(o=parseInt(e.substr(i,2),16),isNaN(o))throw new Error("String of HEX type contains invalid characters");for(a=(s=(i>>>1)+l)>>>2;u.length<=a;)u.push(0);u[a]|=o<<8*(c+r*(s%4))}return{value:u,binLen:4*e.length+n}}(e,t,n,i)};case"TEXT":return function(e,t,n){return function(e,t,n,r,i){var o,a,s,u,l,c,f,h,d=0,p=n||[0],y=(r=r||0)>>>3;if("UTF8"===t)for(f=-1===i?3:0,s=0;s<e.length;s+=1)for(a=[],128>(o=e.charCodeAt(s))?a.push(o):2048>o?(a.push(192|o>>>6),a.push(128|63&o)):55296>o||57344<=o?a.push(224|o>>>12,128|o>>>6&63,128|63&o):(s+=1,o=65536+((1023&o)<<10|1023&e.charCodeAt(s)),a.push(240|o>>>18,128|o>>>12&63,128|o>>>6&63,128|63&o)),u=0;u<a.length;u+=1){for(l=(c=d+y)>>>2;p.length<=l;)p.push(0);p[l]|=a[u]<<8*(f+i*(c%4)),d+=1}else for(f=-1===i?2:0,h="UTF16LE"===t&&1!==i||"UTF16LE"!==t&&1===i,s=0;s<e.length;s+=1){for(o=e.charCodeAt(s),!0===h&&(o=(u=255&o)<<8|o>>>8),l=(c=d+y)>>>2;p.length<=l;)p.push(0);p[l]|=o<<8*(f+i*(c%4)),d+=2}return{value:p,binLen:8*d+r}}(e,r,t,n,i)};case"B64":return function(e,n,r){return function(e,n,r,i){var o,a,s,u,l,c,f=0,h=n||[0],d=(r=r||0)>>>3,p=-1===i?3:0,y=e.indexOf("=");if(-1===e.search(/^[a-zA-Z0-9=+/]+$/))throw new Error("Invalid character in base-64 string");if(e=e.replace(/=/g,""),-1!==y&&y<e.length)throw new Error("Invalid '=' found in base-64 string");for(o=0;o<e.length;o+=4){for(u=e.substr(o,4),s=0,a=0;a<u.length;a+=1)s|=t.indexOf(u.charAt(a))<<18-6*a;for(a=0;a<u.length-1;a+=1){for(l=(c=f+d)>>>2;h.length<=l;)h.push(0);h[l]|=(s>>>16-8*a&255)<<8*(p+i*(c%4)),f+=1}}return{value:h,binLen:8*f+r}}(e,n,r,i)};case"BYTES":return function(e,t,n){return function(e,t,n,r){var i,o,a,s,u=t||[0],l=(n=n||0)>>>3,c=-1===r?3:0;for(o=0;o<e.length;o+=1)i=e.charCodeAt(o),a=(s=o+l)>>>2,u.length<=a&&u.push(0),u[a]|=i<<8*(c+r*(s%4));return{value:u,binLen:8*e.length+n}}(e,t,n,i)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e,t,r){return function(e,t,r,i){return n(new Uint8Array(e),t,r,i)}(e,t,r,i)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e,t,r){return n(e,t,r,i)};default:throw new Error("format must be HEX, TEXT, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function i(e,n,r,i){switch(e){case"HEX":return function(e){return function(e,t,n,r){var i,o,a="",s=t/8,u=-1===n?3:0;for(i=0;i<s;i+=1)o=e[i>>>2]>>>8*(u+n*(i%4)),a+="0123456789abcdef".charAt(o>>>4&15)+"0123456789abcdef".charAt(15&o);return r.outputUpper?a.toUpperCase():a}(e,n,r,i)};case"B64":return function(e){return function(e,n,r,i){var o,a,s,u,l,c="",f=n/8,h=-1===r?3:0;for(o=0;o<f;o+=3)for(u=o+1<f?e[o+1>>>2]:0,l=o+2<f?e[o+2>>>2]:0,s=(e[o>>>2]>>>8*(h+r*(o%4))&255)<<16|(u>>>8*(h+r*((o+1)%4))&255)<<8|l>>>8*(h+r*((o+2)%4))&255,a=0;a<4;a+=1)c+=8*o+6*a<=n?t.charAt(s>>>6*(3-a)&63):i.b64Pad;return c}(e,n,r,i)};case"BYTES":return function(e){return function(e,t,n){var r,i,o="",a=t/8,s=-1===n?3:0;for(r=0;r<a;r+=1)i=e[r>>>2]>>>8*(s+n*(r%4))&255,o+=String.fromCharCode(i);return o}(e,n,r)};case"ARRAYBUFFER":try{new ArrayBuffer(0)}catch(e){throw new Error("ARRAYBUFFER not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=new ArrayBuffer(i),a=new Uint8Array(o),s=-1===n?3:0;for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(s+n*(r%4))&255;return o}(e,n,r)};case"UINT8ARRAY":try{new Uint8Array(0)}catch(e){throw new Error("UINT8ARRAY not supported by this environment")}return function(e){return function(e,t,n){var r,i=t/8,o=-1===n?3:0,a=new Uint8Array(i);for(r=0;r<i;r+=1)a[r]=e[r>>>2]>>>8*(o+n*(r%4))&255;return a}(e,n,r)};default:throw new Error("format must be HEX, B64, BYTES, ARRAYBUFFER, or UINT8ARRAY")}}function o(e){var t={outputUpper:!1,b64Pad:"=",outputLen:-1},n=e||{},r="Output length must be a multiple of 8";if(t.outputUpper=n.outputUpper||!1,n.b64Pad&&(t.b64Pad=n.b64Pad),n.outputLen){if(n.outputLen%8!=0)throw new Error(r);t.outputLen=n.outputLen}else if(n.shakeLen){if(n.shakeLen%8!=0)throw new Error(r);t.outputLen=n.shakeLen}if("boolean"!=typeof t.outputUpper)throw new Error("Invalid outputUpper formatting option");if("string"!=typeof t.b64Pad)throw new Error("Invalid b64Pad formatting option");return t}function a(e,t){return e<<t|e>>>32-t}function s(e,t,n){return e^t^n}function u(e,t,n){return e&t^e&n^t&n}function l(e,t){var n=(65535&e)+(65535&t);return(65535&(e>>>16)+(t>>>16)+(n>>>16))<<16|65535&n}function c(e,t,n,r,i){var o=(65535&e)+(65535&t)+(65535&n)+(65535&r)+(65535&i);return(65535&(e>>>16)+(t>>>16)+(n>>>16)+(r>>>16)+(i>>>16)+(o>>>16))<<16|65535&o}function f(e){return[1732584193,4023233417,2562383102,271733878,3285377520]}function h(e,t){var n,r,i,o,f,h,d,p,y=[];for(n=t[0],r=t[1],i=t[2],o=t[3],f=t[4],d=0;d<80;d+=1)y[d]=d<16?e[d]:a(y[d-3]^y[d-8]^y[d-14]^y[d-16],1),h=d<20?c(a(n,5),(p=r)&i^~p&o,f,1518500249,y[d]):d<40?c(a(n,5),s(r,i,o),f,1859775393,y[d]):d<60?c(a(n,5),u(r,i,o),f,2400959708,y[d]):c(a(n,5),s(r,i,o),f,3395469782,y[d]),f=o,o=i,i=a(r,30),r=n,n=h;return t[0]=l(n,t[0]),t[1]=l(r,t[1]),t[2]=l(i,t[2]),t[3]=l(o,t[3]),t[4]=l(f,t[4]),t}function d(e,t,n,r){for(var i,o=15+(t+65>>>9<<4),a=t+n;e.length<=o;)e.push(0);for(e[t>>>5]|=128<<24-t%32,e[o]=4294967295&a,e[o-1]=a/4294967296|0,i=0;i<e.length;i+=16)r=h(e.slice(i,i+16),r);return r}return function(t){function n(e,n,i){var o=this;if("SHA-1"!==e)throw new Error("Chosen SHA variant is not supported");var a=i||{};return(o=t.call(this,e,n,i)||this).t=!0,o.i=o.o,o.u=-1,o.s=r(o.h,o.v,o.u),o.A=h,o.p=function(e){return e.slice()},o.l=f,o.R=d,o.U=[1732584193,4023233417,2562383102,271733878,3285377520],o.T=512,o.m=160,o.F=!1,a.hmacKey&&o.B(function(e,t,n,i){var o="hmacKey must include a value and format";if(!t)throw new Error(o);if(void 0===t.value||!t.format)throw new Error(o);return r(t.format,t.encoding||"UTF8",n)(t.value)}(0,a.hmacKey,o.u)),o}return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}(n,t),n}(function(){function e(e,t,n){var r=n||{};if(this.h=t,this.v=r.encoding||"UTF8",this.numRounds=r.numRounds||1,isNaN(this.numRounds)||this.numRounds!==parseInt(this.numRounds,10)||1>this.numRounds)throw new Error("numRounds must a integer >= 1");this.g=e,this.Y=[],this.I=0,this.C=!1,this.H=0,this.L=!1,this.N=[],this.S=[]}return e.prototype.update=function(e){var t,n=0,r=this.T>>>5,i=this.s(e,this.Y,this.I),o=i.binLen,a=i.value,s=o>>>5;for(t=0;t<s;t+=r)n+this.T<=o&&(this.U=this.A(a.slice(t,t+r),this.U),n+=this.T);this.H+=n,this.Y=a.slice(n>>>5),this.I=o%this.T,this.C=!0},e.prototype.getHash=function(e,t){var n,r,a=this.m,s=o(t);if(!0===this.F){if(-1===s.outputLen)throw new Error("Output length must be specified in options");a=s.outputLen}var u=i(e,a,this.u,s);if(!0===this.L&&this.i)return u(this.i(s));for(r=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),a),n=1;n<this.numRounds;n+=1)!0===this.F&&a%32!=0&&(r[r.length-1]&=16777215>>>24-a%32),r=this.R(r,a,0,this.l(this.g),a);return u(r)},e.prototype.setHMACKey=function(e,t,n){if(!0!==this.t)throw new Error("Variant does not support HMAC");if(!0===this.C)throw new Error("Cannot set MAC key after calling update");var i=r(t,(n||{}).encoding||"UTF8",this.u);this.B(i(e))},e.prototype.B=function(e){var t,n=this.T>>>3,r=n/4-1;if(1!==this.numRounds)throw new Error("Cannot set numRounds with MAC");if(!0===this.L)throw new Error("MAC key already set");for(n<e.binLen/8&&(e.value=this.R(e.value,e.binLen,0,this.l(this.g),this.m));e.value.length<=r;)e.value.push(0);for(t=0;t<=r;t+=1)this.N[t]=909522486^e.value[t],this.S[t]=1549556828^e.value[t];this.U=this.A(this.N,this.U),this.H=this.T,this.L=!0},e.prototype.getHMAC=function(e,t){var n=o(t);return i(e,this.m,this.u,n)(this.o())},e.prototype.o=function(){var e;if(!1===this.L)throw new Error("Cannot call getHMAC without first setting MAC key");var t=this.R(this.Y.slice(),this.I,this.H,this.p(this.U),this.m);return e=this.A(this.S,this.l(this.g)),this.R(t,this.m,this.T,e,this.m)},e}())}()},function(e){e.exports=JSON.parse('{"a":"1.0.22-rc.2"}')},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var r=d(n(68)),i=d(n(427)),o=d(n(134)),a=d(n(1)),s=d(n(28)),u=d(n(430)),l=d(n(432)),c=n(466),f=d(n(450)),h=d(n(215));function d(e){return e&&e.__esModule?e:{default:e}}function p(){return(p=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function y(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}function m(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var g=function(e){var t,n;function r(t,n){var r;return(r=e.call(this,t,n)||this).handleHidden=function(){var e;(r.setState({exited:!0}),r.props.onExited)&&(e=r.props).onExited.apply(e,arguments)},r.state={exited:!t.show},r.onHiddenListener=r.handleHidden.bind(m(m(r))),r._lastTarget=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n,r.getDerivedStateFromProps=function(e){return e.show?{exited:!1}:e.transition?null:{exited:!0}};var i=r.prototype;return i.componentDidMount=function(){this.setState({target:this.getTarget()})},i.componentDidUpdate=function(e){if(this.props!==e){var t=this.getTarget();t!==this.state.target&&this.setState({target:t})}},i.getTarget=function(){var e=this.props.target;return(e="function"==typeof e?e():e)&&s.default.findDOMNode(e)||null},i.render=function(){var e=this,t=this.props,n=(t.target,t.container),r=t.containerPadding,i=t.placement,o=t.rootClose,s=t.children,f=t.flip,h=t.popperConfig,d=void 0===h?{}:h,m=t.transition,g=y(t,["target","container","containerPadding","placement","rootClose","children","flip","popperConfig","transition"]),v=this.state.target;if(!(g.show||m&&!this.state.exited))return null;var b=s,_=d.modifiers,w=void 0===_?{}:_,T=p({},d,{placement:i,referenceElement:v,enableEvents:g.show,modifiers:p({},w,{preventOverflow:p({padding:r||5},w.preventOverflow),flip:p({enabled:!!f},w.preventOverflow)})});return b=a.default.createElement(c.Popper,T,(function(t){var n=t.arrowProps,r=t.style,o=t.ref,s=y(t,["arrowProps","style","ref"]);e.popper=s;var u=e.props.children(p({},s,{placement:s.placement||i,show:g.show,arrowProps:n,props:{ref:o,style:r}}));if(m){var l=g.onExit,c=g.onExiting,f=g.onEnter,h=g.onEntering,d=g.onEntered;u=a.default.createElement(m,{in:g.show,appear:!0,onExit:l,onExiting:c,onExited:e.onHiddenListener,onEnter:f,onEntering:h,onEntered:d},u)}return u})),o&&(b=a.default.createElement(l.default,{onRootClose:g.onHide,event:g.rootCloseEvent,disabled:g.rootCloseDisabled},b)),a.default.createElement(u.default,{container:n},b)},r}(a.default.Component);g.propTypes=p({},u.default.propTypes,{show:r.default.bool,placement:r.default.oneOf(c.placements),container:r.default.oneOfType([o.default,r.default.func]),flip:r.default.bool,children:r.default.func.isRequired,popperConfig:r.default.object,rootClose:r.default.bool,rootCloseEvent:l.default.propTypes.event,rootCloseDisabled:l.default.propTypes.disabled,onHide:function(e){var t=r.default.func;e.rootClose&&(t=t.isRequired);for(var n=arguments.length,i=new Array(n>1?n-1:0),o=1;o<n;o++)i[o-1]=arguments[o];return t.apply(void 0,[e].concat(i))},transition:i.default,onEnter:r.default.func,onEntering:r.default.func,onEntered:r.default.func,onExit:r.default.func,onExiting:r.default.func,onExited:r.default.func});var v=(0,f.default)((function(e,t){return a.default.createElement(h.default,{container:e.container},(function(n){return a.default.createElement(g,p({},e,{ref:t,container:n}))}))}),{displayName:"withContainer(Overlay)"});t.default=v,e.exports=t.default},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(217),i=n(438),o=n(442),a=n(444),s=n(445),u=n(447),l=Date.prototype.getTime;function c(e,t,n){var d=n||{};return!!(d.strict?o(e,t):e===t)||(!e||!t||"object"!=typeof e&&"object"!=typeof t?d.strict?o(e,t):e==t:function(e,t,n){var o,d;if(typeof e!=typeof t)return!1;if(f(e)||f(t))return!1;if(e.prototype!==t.prototype)return!1;if(i(e)!==i(t))return!1;var p=a(e),y=a(t);if(p!==y)return!1;if(p||y)return e.source===t.source&&s(e)===s(t);if(u(e)&&u(t))return l.call(e)===l.call(t);var m=h(e),g=h(t);if(m!==g)return!1;if(m||g){if(e.length!==t.length)return!1;for(o=0;o<e.length;o++)if(e[o]!==t[o])return!1;return!0}if(typeof e!=typeof t)return!1;try{var v=r(e),b=r(t)}catch(e){return!1}if(v.length!==b.length)return!1;for(v.sort(),b.sort(),o=v.length-1;o>=0;o--)if(v[o]!=b[o])return!1;for(o=v.length-1;o>=0;o--)if(d=v[o],!c(e[d],t[d],n))return!1;return!0}(e,t,d))}function f(e){return null==e}function h(e){return!(!e||"object"!=typeof e||"number"!=typeof e.length)&&("function"==typeof e.copy&&"function"==typeof e.slice&&!(e.length>0&&"number"!=typeof e[0]))}e.exports=c},function(e,t,n){"use strict";var r=n(43);t.__esModule=!0,t.default=void 0;var i=r(n(226)),o=r(n(451));function a(e,t,n){var r,o={target:e,currentTarget:e};function a(e){e.target===e.currentTarget&&(clearTimeout(r),e.target.removeEventListener(i.default.end,a),t.call(this))}i.default.end?null==n&&(n=u(e)||0):n=0,i.default.end?(e.addEventListener(i.default.end,a,!1),r=setTimeout((function(){return a(o)}),1.5*(n||100))):setTimeout(a.bind(null,o),0)}a._parseDuration=u;var s=a;function u(e){var t=(0,o.default)(e,i.default.duration),n=-1===t.indexOf("ms")?1e3:1;return parseFloat(t)*n}t.default=s,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){var n=void 0===t?{}:t,r=n.propTypes,o=n.defaultProps,a=n.allowFallback,s=void 0!==a&&a,u=n.displayName,l=void 0===u?e.name||e.displayName:u,c=function(t,n){return e(t,n)};return Object.assign(i.default.forwardRef||!s?i.default.forwardRef(c):function(e){return c(e,null)},{displayName:l,propTypes:r,defaultProps:o})};var r,i=(r=n(1))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";var r=n(6),i=n(14),o=n(51),a=n(46),s=n(17),u=n(153),l=n(11),c=n(36),f=n(54),h=n(18),d=n(25),p=n(20),y=n(32),m=n(62),g=n(61),v=n(64),b=n(76),_=n(115),w=n(156),T=n(118),S=n(49),E=n(27),C=n(85),k=n(33),x=n(45),O=n(74),P=n(86),R=n(75),A=n(87),I=n(16),L=n(157),j=n(247),D=n(55),N=n(38),M=n(47).forEach,U=P("hidden"),B=I("toPrimitive"),F=N.set,V=N.getterFor("Symbol"),H=Object.prototype,z=i.Symbol,q=o("JSON","stringify"),W=S.f,$=E.f,G=w.f,Y=C.f,K=O("symbols"),X=O("op-symbols"),Q=O("string-to-symbol-registry"),J=O("symbol-to-string-registry"),Z=O("wks"),ee=i.QObject,te=!ee||!ee.prototype||!ee.prototype.findChild,ne=s&&l((function(){return 7!=v($({},"a",{get:function(){return $(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=W(H,t);r&&delete H[t],$(e,t,n),r&&e!==H&&$(H,t,r)}:$,re=function(e,t){var n=K[e]=v(z.prototype);return F(n,{type:"Symbol",tag:e,description:t}),s||(n.description=t),n},ie=u&&"symbol"==typeof z.iterator?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof z},oe=function(e,t,n){e===H&&oe(X,t,n),d(e);var r=m(t,!0);return d(n),c(K,r)?(n.enumerable?(c(e,U)&&e[U][r]&&(e[U][r]=!1),n=v(n,{enumerable:g(0,!1)})):(c(e,U)||$(e,U,g(1,{})),e[U][r]=!0),ne(e,r,n)):$(e,r,n)},ae=function(e,t){d(e);var n=y(t),r=b(n).concat(ce(n));return M(r,(function(t){s&&!se.call(n,t)||oe(e,t,n[t])})),e},se=function(e){var t=m(e,!0),n=Y.call(this,t);return!(this===H&&c(K,t)&&!c(X,t))&&(!(n||!c(this,t)||!c(K,t)||c(this,U)&&this[U][t])||n)},ue=function(e,t){var n=y(e),r=m(t,!0);if(n!==H||!c(K,r)||c(X,r)){var i=W(n,r);return!i||!c(K,r)||c(n,U)&&n[U][r]||(i.enumerable=!0),i}},le=function(e){var t=G(y(e)),n=[];return M(t,(function(e){c(K,e)||c(R,e)||n.push(e)})),n},ce=function(e){var t=e===H,n=G(t?X:y(e)),r=[];return M(n,(function(e){!c(K,e)||t&&!c(H,e)||r.push(K[e])})),r};(u||(x((z=function(){if(this instanceof z)throw TypeError("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,t=A(e),n=function(e){this===H&&n.call(X,e),c(this,U)&&c(this[U],t)&&(this[U][t]=!1),ne(this,t,g(1,e))};return s&&te&&ne(H,t,{configurable:!0,set:n}),re(t,e)}).prototype,"toString",(function(){return V(this).tag})),C.f=se,E.f=oe,S.f=ue,_.f=w.f=le,T.f=ce,s&&($(z.prototype,"description",{configurable:!0,get:function(){return V(this).description}}),a||x(H,"propertyIsEnumerable",se,{unsafe:!0})),L.f=function(e){return re(I(e),e)}),r({global:!0,wrap:!0,forced:!u,sham:!u},{Symbol:z}),M(b(Z),(function(e){j(e)})),r({target:"Symbol",stat:!0,forced:!u},{for:function(e){var t=String(e);if(c(Q,t))return Q[t];var n=z(t);return Q[t]=n,J[n]=t,n},keyFor:function(e){if(!ie(e))throw TypeError(e+" is not a symbol");if(c(J,e))return J[e]},useSetter:function(){te=!0},useSimple:function(){te=!1}}),r({target:"Object",stat:!0,forced:!u,sham:!s},{create:function(e,t){return void 0===t?v(e):ae(v(e),t)},defineProperty:oe,defineProperties:ae,getOwnPropertyDescriptor:ue}),r({target:"Object",stat:!0,forced:!u},{getOwnPropertyNames:le,getOwnPropertySymbols:ce}),r({target:"Object",stat:!0,forced:l((function(){T.f(1)}))},{getOwnPropertySymbols:function(e){return T.f(p(e))}}),q)&&r({target:"JSON",stat:!0,forced:!u||l((function(){var e=z();return"[null]"!=q([e])||"{}"!=q({a:e})||"{}"!=q(Object(e))}))},{stringify:function(e,t,n){for(var r,i=[e],o=1;arguments.length>o;)i.push(arguments[o++]);if(r=t,(h(t)||void 0!==e)&&!ie(e))return f(t)||(t=function(e,t){if("function"==typeof r&&(t=r.call(this,e,t)),!ie(t))return t}),i[1]=t,q.apply(null,i)}});z.prototype[B]||k(z.prototype,B,z.prototype.valueOf),D(z,"Symbol"),R[U]=!0},function(e,t,n){var r=n(14),i=n(114),o=r["__core-js_shared__"]||i("__core-js_shared__",{});e.exports=o},function(e,t,n){var r=n(36),i=n(150),o=n(49),a=n(27);e.exports=function(e,t){for(var n=i(t),s=a.f,u=o.f,l=0;l<n.length;l++){var c=n[l];r(e,c)||s(e,c,u(t,c))}}},function(e,t,n){var r=n(151),i=n(36),o=n(157),a=n(27).f;e.exports=function(e){var t=r.Symbol||(r.Symbol={});i(t,e)||a(t,e,{value:o.f(e)})}},function(e,t,n){"use strict";var r=n(6),i=n(11),o=n(54),a=n(18),s=n(20),u=n(15),l=n(56),c=n(77),f=n(78),h=n(16),d=n(120),p=h("isConcatSpreadable"),y=d>=51||!i((function(){var e=[];return e[p]=!1,e.concat()[0]!==e})),m=f("concat"),g=function(e){if(!a(e))return!1;var t=e[p];return void 0!==t?!!t:o(e)};r({target:"Array",proto:!0,forced:!y||!m},{concat:function(e){var t,n,r,i,o,a=s(this),f=c(a,0),h=0;for(t=-1,r=arguments.length;t<r;t++)if(g(o=-1===t?a:arguments[t])){if(h+(i=u(o.length))>9007199254740991)throw TypeError("Maximum allowed index exceeded");for(n=0;n<i;n++,h++)n in o&&l(f,h,o[n])}else{if(h>=9007199254740991)throw TypeError("Maximum allowed index exceeded");l(f,h++,o)}return f.length=h,f}})},function(e,t,n){var r=n(6),i=n(250),o=n(42);r({target:"Array",proto:!0},{copyWithin:i}),o("copyWithin")},function(e,t,n){"use strict";var r=n(20),i=n(63),o=n(15),a=Math.min;e.exports=[].copyWithin||function(e,t){var n=r(this),s=o(n.length),u=i(e,s),l=i(t,s),c=arguments.length>2?arguments[2]:void 0,f=a((void 0===c?s:i(c,s))-l,s-u),h=1;for(l<u&&u<l+f&&(h=-1,l+=f-1,u+=f-1);f-- >0;)l in n?n[u]=n[l]:delete n[u],u+=h,l+=h;return n}},function(e,t,n){"use strict";var r=n(6),i=n(47).every;r({target:"Array",proto:!0,forced:n(48)("every")},{every:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(6),i=n(253),o=n(42);r({target:"Array",proto:!0},{fill:i}),o("fill")},function(e,t,n){"use strict";var r=n(20),i=n(63),o=n(15);e.exports=function(e){for(var t=r(this),n=o(t.length),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,l=void 0===u?n:i(u,n);l>s;)t[s++]=e;return t}},function(e,t,n){"use strict";var r=n(6),i=n(47).find,o=n(42),a=!0;"find"in[]&&Array(1).find((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{find:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("find")},function(e,t,n){"use strict";var r=n(6),i=n(47).findIndex,o=n(42),a=!0;"findIndex"in[]&&Array(1).findIndex((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("findIndex")},function(e,t,n){"use strict";var r=n(6),i=n(159),o=n(20),a=n(15),s=n(52),u=n(77);r({target:"Array",proto:!0},{flat:function(){var e=arguments.length?arguments[0]:void 0,t=o(this),n=a(t.length),r=u(t,0);return r.length=i(r,t,t,n,0,void 0===e?1:s(e)),r}})},function(e,t,n){"use strict";var r=n(6),i=n(159),o=n(20),a=n(15),s=n(37),u=n(77);r({target:"Array",proto:!0},{flatMap:function(e){var t,n=o(this),r=a(n.length);return s(e),(t=u(n,0)).length=i(t,n,n,r,0,1,e,arguments.length>1?arguments[1]:void 0),t}})},function(e,t,n){var r=n(6),i=n(259);r({target:"Array",stat:!0,forced:!n(122)((function(e){Array.from(e)}))},{from:i})},function(e,t,n){"use strict";var r=n(65),i=n(20),o=n(162),a=n(163),s=n(15),u=n(56),l=n(164);e.exports=function(e){var t,n,c,f,h,d=i(e),p="function"==typeof this?this:Array,y=arguments.length,m=y>1?arguments[1]:void 0,g=void 0!==m,v=0,b=l(d);if(g&&(m=r(m,y>2?arguments[2]:void 0,2)),null==b||p==Array&&a(b))for(n=new p(t=s(d.length));t>v;v++)u(n,v,g?m(d[v],v):d[v]);else for(h=(f=b.call(d)).next,n=new p;!(c=h.call(f)).done;v++)u(n,v,g?o(f,m,[c.value,v],!0):c.value);return n.length=v,n}},function(e,t,n){"use strict";var r=n(6),i=n(116).includes,o=n(42);r({target:"Array",proto:!0},{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o("includes")},function(e,t,n){"use strict";var r=n(6),i=n(116).indexOf,o=n(48),a=[].indexOf,s=!!a&&1/[1].indexOf(1,-0)<0,u=o("indexOf");r({target:"Array",proto:!0,forced:s||u},{indexOf:function(e){return s?a.apply(this,arguments)||0:i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){n(6)({target:"Array",stat:!0},{isArray:n(54)})},function(e,t,n){var r=n(18);e.exports=function(e){if(!r(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},function(e,t,n){"use strict";var r=n(6),i=n(73),o=n(32),a=n(48),s=[].join,u=i!=Object,l=a("join",",");r({target:"Array",proto:!0,forced:u||l},{join:function(e){return s.call(o(this),void 0===e?",":e)}})},function(e,t,n){var r=n(6),i=n(266);r({target:"Array",proto:!0,forced:i!==[].lastIndexOf},{lastIndexOf:i})},function(e,t,n){"use strict";var r=n(32),i=n(52),o=n(15),a=n(48),s=Math.min,u=[].lastIndexOf,l=!!u&&1/[1].lastIndexOf(1,-0)<0,c=a("lastIndexOf");e.exports=l||c?function(e){if(l)return u.apply(this,arguments)||0;var t=r(this),n=o(t.length),a=n-1;for(arguments.length>1&&(a=s(a,i(arguments[1]))),a<0&&(a=n+a);a>=0;a--)if(a in t&&t[a]===e)return a||0;return-1}:u},function(e,t,n){"use strict";var r=n(6),i=n(47).map;r({target:"Array",proto:!0,forced:!n(78)("map")},{map:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(11),o=n(56);r({target:"Array",stat:!0,forced:i((function(){function e(){}return!(Array.of.call(e)instanceof e)}))},{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)o(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var r=n(6),i=n(168).right;r({target:"Array",proto:!0,forced:n(48)("reduceRight")},{reduceRight:function(e){return i(this,e,arguments.length,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(54),o=[].reverse,a=[1,2];r({target:"Array",proto:!0,forced:String(a)===String(a.reverse())},{reverse:function(){return i(this)&&(this.length=this.length),o.call(this)}})},function(e,t,n){"use strict";var r=n(6),i=n(18),o=n(54),a=n(63),s=n(15),u=n(32),l=n(56),c=n(78),f=n(16)("species"),h=[].slice,d=Math.max;r({target:"Array",proto:!0,forced:!c("slice")},{slice:function(e,t){var n,r,c,p=u(this),y=s(p.length),m=a(e,y),g=a(void 0===t?y:t,y);if(o(p)&&("function"!=typeof(n=p.constructor)||n!==Array&&!o(n.prototype)?i(n)&&null===(n=n[f])&&(n=void 0):n=void 0,n===Array||void 0===n))return h.call(p,m,g);for(r=new(void 0===n?Array:n)(d(g-m,0)),c=0;m<g;m++,c++)m in p&&l(r,c,p[m]);return r.length=c,r}})},function(e,t,n){"use strict";var r=n(6),i=n(47).some;r({target:"Array",proto:!0,forced:n(48)("some")},{some:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(20),a=n(11),s=n(48),u=[].sort,l=[1,2,3],c=a((function(){l.sort(void 0)})),f=a((function(){l.sort(null)})),h=s("sort");r({target:"Array",proto:!0,forced:c||!f||h},{sort:function(e){return void 0===e?u.call(o(this)):u.call(o(this),i(e))}})},function(e,t,n){n(126)("Array")},function(e,t,n){"use strict";var r=n(6),i=n(63),o=n(52),a=n(15),s=n(20),u=n(77),l=n(56),c=n(78),f=Math.max,h=Math.min;r({target:"Array",proto:!0,forced:!c("splice")},{splice:function(e,t){var n,r,c,d,p,y,m=s(this),g=a(m.length),v=i(e,g),b=arguments.length;if(0===b?n=r=0:1===b?(n=0,r=g-v):(n=b-2,r=h(f(o(t),0),g-v)),g+n-r>9007199254740991)throw TypeError("Maximum allowed length exceeded");for(c=u(m,r),d=0;d<r;d++)(p=v+d)in m&&l(c,d,m[p]);if(c.length=r,n<r){for(d=v;d<g-r;d++)y=d+n,(p=d+r)in m?m[y]=m[p]:delete m[y];for(d=g;d>g-r+n;d--)delete m[d-1]}else if(n>r)for(d=g-r;d>v;d--)y=d+n-1,(p=d+r-1)in m?m[y]=m[p]:delete m[y];for(d=0;d<n;d++)m[d+v]=arguments[d+2];return m.length=g-r+n,c}})},function(e,t,n){n(42)("flat")},function(e,t,n){n(42)("flatMap")},function(e,t,n){var r=n(14);n(55)(r.JSON,"JSON",!0)},function(e,t,n){"use strict";var r=n(169),i=n(281);e.exports=r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i,!0)},function(e,t,n){var r=n(18),i=n(89);e.exports=function(e,t,n){var o,a;return i&&"function"==typeof(o=t.constructor)&&o!==n&&r(a=o.prototype)&&a!==n.prototype&&i(e,a),e}},function(e,t,n){"use strict";var r=n(27).f,i=n(64),o=n(92),a=n(65),s=n(91),u=n(53),l=n(124),c=n(126),f=n(17),h=n(57).fastKey,d=n(38),p=d.set,y=d.getterFor;e.exports={getConstructor:function(e,t,n,l){var c=e((function(e,r){s(e,c,t),p(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),f||(e.size=0),null!=r&&u(r,e[l],e,n)})),d=y(t),m=function(e,t,n){var r,i,o=d(e),a=g(e,t);return a?a.value=n:(o.last=a={index:i=h(t,!0),key:t,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=a),r&&(r.next=a),f?o.size++:e.size++,"F"!==i&&(o.index[i]=a)),e},g=function(e,t){var n,r=d(e),i=h(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return o(c.prototype,{clear:function(){for(var e=d(this),t=e.index,n=e.first;n;)n.removed=!0,n.previous&&(n.previous=n.previous.next=void 0),delete t[n.index],n=n.next;e.first=e.last=void 0,f?e.size=0:this.size=0},delete:function(e){var t=d(this),n=g(this,e);if(n){var r=n.next,i=n.previous;delete t.index[n.index],n.removed=!0,i&&(i.next=r),r&&(r.previous=i),t.first==n&&(t.first=r),t.last==n&&(t.last=i),f?t.size--:this.size--}return!!n},forEach:function(e){for(var t,n=d(this),r=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.next:n.first;)for(r(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!g(this,e)}}),o(c.prototype,n?{get:function(e){var t=g(this,e);return t&&t.value},set:function(e,t){return m(this,0===e?0:e,t)}}:{add:function(e){return m(this,e=0===e?0:e,e)}}),f&&r(c.prototype,"size",{get:function(){return d(this).size}}),c},setStrong:function(e,t,n){var r=t+" Iterator",i=y(t),o=y(r);l(e,t,(function(e,t){p(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){for(var e=o(this),t=e.kind,n=e.last;n&&n.removed;)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),c(t)}}},function(e,t,n){n(55)(Math,"Math",!0)},function(e,t,n){"use strict";var r=n(17),i=n(11),o=n(76),a=n(118),s=n(85),u=n(20),l=n(73),c=Object.assign;e.exports=!c||i((function(){var e={},t={},n=Symbol();return e[n]=7,"abcdefghijklmnopqrst".split("").forEach((function(e){t[e]=e})),7!=c({},e)[n]||"abcdefghijklmnopqrst"!=o(c({},t)).join("")}))?function(e,t){for(var n=u(e),i=arguments.length,c=1,f=a.f,h=s.f;i>c;)for(var d,p=l(arguments[c++]),y=f?o(p).concat(f(p)):o(p),m=y.length,g=0;m>g;)d=y[g++],r&&!h.call(p,d)||(n[d]=p[d]);return n}:c},function(e,t,n){n(6)({target:"Object",stat:!0,sham:!n(17)},{create:n(64)})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(37),u=n(27);i&&r({target:"Object",proto:!0,forced:o},{__defineGetter__:function(e,t){u.f(a(this),e,{get:s(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(6),i=n(17);r({target:"Object",stat:!0,forced:!i,sham:!i},{defineProperties:n(154)})},function(e,t,n){var r=n(6),i=n(17);r({target:"Object",stat:!0,forced:!i,sham:!i},{defineProperty:n(27).f})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(37),u=n(27);i&&r({target:"Object",proto:!0,forced:o},{__defineSetter__:function(e,t){u.f(a(this),e,{set:s(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(6),i=n(171).entries;r({target:"Object",stat:!0},{entries:function(e){return i(e)}})},function(e,t,n){var r=n(6),i=n(90),o=n(11),a=n(18),s=n(57).onFreeze,u=Object.freeze;r({target:"Object",stat:!0,forced:o((function(){u(1)})),sham:!i},{freeze:function(e){return u&&a(e)?u(s(e)):e}})},function(e,t,n){var r=n(6),i=n(53),o=n(56);r({target:"Object",stat:!0},{fromEntries:function(e){var t={};return i(e,(function(e,n){o(t,e,n)}),void 0,!0),t}})},function(e,t,n){var r=n(6),i=n(11),o=n(32),a=n(49).f,s=n(17),u=i((function(){a(1)}));r({target:"Object",stat:!0,forced:!s||u,sham:!s},{getOwnPropertyDescriptor:function(e,t){return a(o(e),t)}})},function(e,t,n){var r=n(6),i=n(17),o=n(150),a=n(32),s=n(49),u=n(56);r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(e){for(var t,n,r=a(e),i=s.f,l=o(r),c={},f=0;l.length>f;)void 0!==(n=i(r,t=l[f++]))&&u(c,t,n);return c}})},function(e,t,n){var r=n(6),i=n(11),o=n(156).f;r({target:"Object",stat:!0,forced:i((function(){return!Object.getOwnPropertyNames(1)}))},{getOwnPropertyNames:o})},function(e,t,n){var r=n(6),i=n(11),o=n(20),a=n(66),s=n(166);r({target:"Object",stat:!0,forced:i((function(){a(1)})),sham:!s},{getPrototypeOf:function(e){return a(o(e))}})},function(e,t,n){n(6)({target:"Object",stat:!0},{is:n(172)})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isExtensible;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isExtensible:function(e){return!!o(e)&&(!a||a(e))}})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isFrozen;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isFrozen:function(e){return!o(e)||!!a&&a(e)}})},function(e,t,n){var r=n(6),i=n(11),o=n(18),a=Object.isSealed;r({target:"Object",stat:!0,forced:i((function(){a(1)}))},{isSealed:function(e){return!o(e)||!!a&&a(e)}})},function(e,t,n){var r=n(6),i=n(20),o=n(76);r({target:"Object",stat:!0,forced:n(11)((function(){o(1)}))},{keys:function(e){return o(i(e))}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(62),u=n(66),l=n(49).f;i&&r({target:"Object",proto:!0,forced:o},{__lookupGetter__:function(e){var t,n=a(this),r=s(e,!0);do{if(t=l(n,r))return t.get}while(n=u(n))}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(93),a=n(20),s=n(62),u=n(66),l=n(49).f;i&&r({target:"Object",proto:!0,forced:o},{__lookupSetter__:function(e){var t,n=a(this),r=s(e,!0);do{if(t=l(n,r))return t.set}while(n=u(n))}})},function(e,t,n){var r=n(6),i=n(18),o=n(57).onFreeze,a=n(90),s=n(11),u=Object.preventExtensions;r({target:"Object",stat:!0,forced:s((function(){u(1)})),sham:!a},{preventExtensions:function(e){return u&&i(e)?u(o(e)):e}})},function(e,t,n){var r=n(6),i=n(18),o=n(57).onFreeze,a=n(90),s=n(11),u=Object.seal;r({target:"Object",stat:!0,forced:s((function(){u(1)})),sham:!a},{seal:function(e){return u&&i(e)?u(o(e)):e}})},function(e,t,n){n(6)({target:"Object",stat:!0},{setPrototypeOf:n(89)})},function(e,t,n){"use strict";var r=n(121),i={};i[n(16)("toStringTag")]="z",e.exports="[object z]"!==String(i)?function(){return"[object "+r(this)+"]"}:i.toString},function(e,t,n){var r=n(6),i=n(171).values;r({target:"Object",stat:!0},{values:function(e){return i(e)}})},function(e,t,n){"use strict";var r,i,o,a,s=n(6),u=n(46),l=n(14),c=n(51),f=n(174),h=n(45),d=n(92),p=n(55),y=n(126),m=n(18),g=n(37),v=n(91),b=n(50),_=n(53),w=n(122),T=n(94),S=n(175).set,E=n(309),C=n(176),k=n(310),x=n(80),O=n(95),P=n(38),R=n(119),A=n(16),I=n(120),L=A("species"),j="Promise",D=P.get,N=P.set,M=P.getterFor(j),U=f,B=l.TypeError,F=l.document,V=l.process,H=c("fetch"),z=x.f,q=z,W="process"==b(V),$=!!(F&&F.createEvent&&l.dispatchEvent),G=R(j,(function(){if(66===I)return!0;if(!W&&"function"!=typeof PromiseRejectionEvent)return!0;if(u&&!U.prototype.finally)return!0;if(I>=51&&/native code/.test(U))return!1;var e=U.resolve(1),t=function(e){e((function(){}),(function(){}))};return(e.constructor={})[L]=t,!(e.then((function(){}))instanceof t)})),Y=G||!w((function(e){U.all(e).catch((function(){}))})),K=function(e){var t;return!(!m(e)||"function"!=typeof(t=e.then))&&t},X=function(e,t,n){if(!t.notified){t.notified=!0;var r=t.reactions;E((function(){for(var i=t.value,o=1==t.state,a=0;r.length>a;){var s,u,l,c=r[a++],f=o?c.ok:c.fail,h=c.resolve,d=c.reject,p=c.domain;try{f?(o||(2===t.rejection&&ee(e,t),t.rejection=1),!0===f?s=i:(p&&p.enter(),s=f(i),p&&(p.exit(),l=!0)),s===c.promise?d(B("Promise-chain cycle")):(u=K(s))?u.call(s,h,d):h(s)):d(i)}catch(e){p&&!l&&p.exit(),d(e)}}t.reactions=[],t.notified=!1,n&&!t.rejection&&J(e,t)}))}},Q=function(e,t,n){var r,i;$?((r=F.createEvent("Event")).promise=t,r.reason=n,r.initEvent(e,!1,!0),l.dispatchEvent(r)):r={promise:t,reason:n},(i=l["on"+e])?i(r):"unhandledrejection"===e&&k("Unhandled promise rejection",n)},J=function(e,t){S.call(l,(function(){var n,r=t.value;if(Z(t)&&(n=O((function(){W?V.emit("unhandledRejection",r,e):Q("unhandledrejection",e,r)})),t.rejection=W||Z(t)?2:1,n.error))throw n.value}))},Z=function(e){return 1!==e.rejection&&!e.parent},ee=function(e,t){S.call(l,(function(){W?V.emit("rejectionHandled",e):Q("rejectionhandled",e,t.value)}))},te=function(e,t,n,r){return function(i){e(t,n,i,r)}},ne=function(e,t,n,r){t.done||(t.done=!0,r&&(t=r),t.value=n,t.state=2,X(e,t,!0))},re=function(e,t,n,r){if(!t.done){t.done=!0,r&&(t=r);try{if(e===n)throw B("Promise can't be resolved itself");var i=K(n);i?E((function(){var r={done:!1};try{i.call(n,te(re,e,r,t),te(ne,e,r,t))}catch(n){ne(e,r,n,t)}})):(t.value=n,t.state=1,X(e,t,!1))}catch(n){ne(e,{done:!1},n,t)}}};G&&(U=function(e){v(this,U,j),g(e),r.call(this);var t=D(this);try{e(te(re,this,t),te(ne,this,t))}catch(e){ne(this,t,e)}},(r=function(e){N(this,{type:j,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=d(U.prototype,{then:function(e,t){var n=M(this),r=z(T(this,U));return r.ok="function"!=typeof e||e,r.fail="function"==typeof t&&t,r.domain=W?V.domain:void 0,n.parent=!0,n.reactions.push(r),0!=n.state&&X(this,n,!1),r.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new r,t=D(e);this.promise=e,this.resolve=te(re,e,t),this.reject=te(ne,e,t)},x.f=z=function(e){return e===U||e===o?new i(e):q(e)},u||"function"!=typeof f||(a=f.prototype.then,h(f.prototype,"then",(function(e,t){var n=this;return new U((function(e,t){a.call(n,e,t)})).then(e,t)}),{unsafe:!0}),"function"==typeof H&&s({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return C(U,H.apply(l,arguments))}}))),s({global:!0,wrap:!0,forced:G},{Promise:U}),p(U,j,!1,!0),y(j),o=c(j),s({target:j,stat:!0,forced:G},{reject:function(e){var t=z(this);return t.reject.call(void 0,e),t.promise}}),s({target:j,stat:!0,forced:u||G},{resolve:function(e){return C(u&&this===o?U:this,e)}}),s({target:j,stat:!0,forced:Y},{all:function(e){var t=this,n=z(t),r=n.resolve,i=n.reject,o=O((function(){var n=g(t.resolve),o=[],a=0,s=1;_(e,(function(e){var u=a++,l=!1;o.push(void 0),s++,n.call(t,e).then((function(e){l||(l=!0,o[u]=e,--s||r(o))}),i)})),--s||r(o)}));return o.error&&i(o.value),n.promise},race:function(e){var t=this,n=z(t),r=n.reject,i=O((function(){var i=g(t.resolve);_(e,(function(e){i.call(t,e).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},function(e,t,n){var r,i,o,a,s,u,l,c,f=n(14),h=n(49).f,d=n(50),p=n(175).set,y=n(88),m=f.MutationObserver||f.WebKitMutationObserver,g=f.process,v=f.Promise,b="process"==d(g),_=h(f,"queueMicrotask"),w=_&&_.value;w||(r=function(){var e,t;for(b&&(e=g.domain)&&e.exit();i;){t=i.fn,i=i.next;try{t()}catch(e){throw i?a():o=void 0,e}}o=void 0,e&&e.enter()},b?a=function(){g.nextTick(r)}:m&&!/(iphone|ipod|ipad).*applewebkit/i.test(y)?(s=!0,u=document.createTextNode(""),new m(r).observe(u,{characterData:!0}),a=function(){u.data=s=!s}):v&&v.resolve?(l=v.resolve(void 0),c=l.then,a=function(){c.call(l,r)}):a=function(){p.call(f,r)}),e.exports=w||function(e){var t={fn:e,next:void 0};o&&(o.next=t),i||(i=t,a()),o=t}},function(e,t,n){var r=n(14);e.exports=function(e,t){var n=r.console;n&&n.error&&(1===arguments.length?n.error(e):n.error(e,t))}},function(e,t,n){"use strict";var r=n(6),i=n(46),o=n(174),a=n(51),s=n(94),u=n(176),l=n(45);r({target:"Promise",proto:!0,real:!0},{finally:function(e){var t=s(this,a("Promise")),n="function"==typeof e;return this.then(n?function(n){return u(t,e()).then((function(){return n}))}:e,n?function(n){return u(t,e()).then((function(){throw n}))}:e)}}),i||"function"!=typeof o||o.prototype.finally||l(o.prototype,"finally",a("Promise").prototype.finally)},function(e,t,n){"use strict";var r=n(6),i=n(81).codeAt;r({target:"String",proto:!0},{codePointAt:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(6),i=n(15),o=n(128),a=n(26),s=n(129),u="".endsWith,l=Math.min;r({target:"String",proto:!0,forced:!s("endsWith")},{endsWith:function(e){var t=String(a(this));o(e);var n=arguments.length>1?arguments[1]:void 0,r=i(t.length),s=void 0===n?r:l(i(n),r),c=String(e);return u?u.call(t,c,s):t.slice(s-c.length,s)===c}})},function(e,t,n){var r=n(6),i=n(63),o=String.fromCharCode,a=String.fromCodePoint;r({target:"String",stat:!0,forced:!!a&&1!=a.length},{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,a=0;r>a;){if(t=+arguments[a++],i(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?o(t):o(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var r=n(6),i=n(128),o=n(26);r({target:"String",proto:!0,forced:!n(129)("includes")},{includes:function(e){return!!~String(o(this)).indexOf(i(e),arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(180).end;r({target:"String",proto:!0,forced:n(182)},{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";var r=n(6),i=n(180).start;r({target:"String",proto:!0,forced:n(182)},{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var r=n(6),i=n(32),o=n(15);r({target:"String",stat:!0},{raw:function(e){for(var t=i(e.raw),n=o(t.length),r=arguments.length,a=[],s=0;n>s;)a.push(String(t[s++])),s<r&&a.push(String(arguments[s]));return a.join("")}})},function(e,t,n){n(6)({target:"String",proto:!0},{repeat:n(181)})},function(e,t,n){"use strict";var r=n(98),i=n(25),o=n(26),a=n(172),s=n(100);r("search",1,(function(e,t,n){return[function(t){var n=o(this),r=null==t?void 0:t[e];return void 0!==r?r.call(t,n):new RegExp(t)[e](String(n))},function(e){var r=n(t,e,this);if(r.done)return r.value;var o=i(e),u=String(this),l=o.lastIndex;a(l,0)||(o.lastIndex=0);var c=s(o,u);return a(o.lastIndex,l)||(o.lastIndex=l),null===c?-1:c.index}]}))},function(e,t,n){"use strict";var r=n(98),i=n(97),o=n(25),a=n(26),s=n(94),u=n(99),l=n(15),c=n(100),f=n(96),h=n(11),d=[].push,p=Math.min,y=!h((function(){return!RegExp(4294967295,"y")}));r("split",2,(function(e,t,n){var r;return r="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(e,n){var r=String(a(this)),o=void 0===n?4294967295:n>>>0;if(0===o)return[];if(void 0===e)return[r];if(!i(e))return t.call(r,e,o);for(var s,u,l,c=[],h=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),p=0,y=new RegExp(e.source,h+"g");(s=f.call(y,r))&&!((u=y.lastIndex)>p&&(c.push(r.slice(p,s.index)),s.length>1&&s.index<r.length&&d.apply(c,s.slice(1)),l=s[0].length,p=u,c.length>=o));)y.lastIndex===s.index&&y.lastIndex++;return p===r.length?!l&&y.test("")||c.push(""):c.push(r.slice(p)),c.length>o?c.slice(0,o):c}:"0".split(void 0,0).length?function(e,n){return void 0===e&&0===n?[]:t.call(this,e,n)}:t,[function(t,n){var i=a(this),o=null==t?void 0:t[e];return void 0!==o?o.call(t,i,n):r.call(String(i),t,n)},function(e,i){var a=n(r,e,this,i,r!==t);if(a.done)return a.value;var f=o(e),h=String(this),d=s(f,RegExp),m=f.unicode,g=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(y?"y":"g"),v=new d(y?f:"^(?:"+f.source+")",g),b=void 0===i?4294967295:i>>>0;if(0===b)return[];if(0===h.length)return null===c(v,h)?[h]:[];for(var _=0,w=0,T=[];w<h.length;){v.lastIndex=y?w:0;var S,E=c(v,y?h:h.slice(w));if(null===E||(S=p(l(v.lastIndex+(y?0:w)),h.length))===_)w=u(h,w,m);else{if(T.push(h.slice(_,w)),T.length===b)return T;for(var C=1;C<=E.length-1;C++)if(T.push(E[C]),T.length===b)return T;w=_=S}}return T.push(h.slice(_)),T}]}),!y)},function(e,t,n){"use strict";var r=n(6),i=n(15),o=n(128),a=n(26),s=n(129),u="".startsWith,l=Math.min;r({target:"String",proto:!0,forced:!s("startsWith")},{startsWith:function(e){var t=String(a(this));o(e);var n=i(l(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return u?u.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";var r=n(6),i=n(101).trim;r({target:"String",proto:!0,forced:n(131)("trim")},{trim:function(){return i(this)}})},function(e,t,n){"use strict";var r=n(6),i=n(101).end,o=n(131)("trimEnd"),a=o?function(){return i(this)}:"".trimEnd;r({target:"String",proto:!0,forced:o},{trimEnd:a,trimRight:a})},function(e,t,n){"use strict";var r=n(6),i=n(101).start,o=n(131)("trimStart"),a=o?function(){return i(this)}:"".trimStart;r({target:"String",proto:!0,forced:o},{trimStart:a,trimLeft:a})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("anchor")},{anchor:function(e){return i(this,"a","name",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("big")},{big:function(){return i(this,"big","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("blink")},{blink:function(){return i(this,"blink","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("bold")},{bold:function(){return i(this,"b","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fixed")},{fixed:function(){return i(this,"tt","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fontcolor")},{fontcolor:function(e){return i(this,"font","color",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("fontsize")},{fontsize:function(e){return i(this,"font","size",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("italics")},{italics:function(){return i(this,"i","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("link")},{link:function(e){return i(this,"a","href",e)}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("small")},{small:function(){return i(this,"small","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("strike")},{strike:function(){return i(this,"strike","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("sub")},{sub:function(){return i(this,"sub","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(34);r({target:"String",proto:!0,forced:n(35)("sup")},{sup:function(){return i(this,"sup","","")}})},function(e,t,n){"use strict";var r=n(6),i=n(17),o=n(66),a=n(89),s=n(64),u=n(27),l=n(61),c=n(53),f=n(33),h=n(25),d=n(38),p=d.set,y=d.getterFor("AggregateError"),m=function(e,t){var n=this;if(!(n instanceof m))return new m(e,t);a&&(n=a(new Error(t),o(n)));var r=[];return c(e,r.push,r),i?p(n,{errors:r,type:"AggregateError"}):n.errors=r,void 0!==t&&f(n,"message",String(t)),n};m.prototype=s(Error.prototype,{constructor:l(5,m),message:l(5,""),name:l(5,"AggregateError"),toString:l(5,(function(){var e=h(this).name;e=void 0===e?"AggregateError":String(e);var t=this.message;return e+": "+(t=void 0===t?"":String(t))}))}),i&&u.f(m.prototype,"errors",{get:function(){return y(this).errors},configurable:!0}),r({global:!0},{AggregateError:m})},function(e,t,n){"use strict";var r=n(17),i=n(42),o=n(20),a=n(15),s=n(27).f;r&&!("lastIndex"in[])&&(s(Array.prototype,"lastIndex",{configurable:!0,get:function(){var e=o(this),t=a(e.length);return 0==t?0:t-1}}),i("lastIndex"))},function(e,t,n){"use strict";var r=n(17),i=n(42),o=n(20),a=n(15),s=n(27).f;r&&!("lastItem"in[])&&(s(Array.prototype,"lastItem",{configurable:!0,get:function(){var e=o(this),t=a(e.length);return 0==t?void 0:e[t-1]},set:function(e){var t=o(this),n=a(t.length);return t[0==n?0:n-1]=e}}),i("lastItem"))},function(e,t,n){n(343)},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(80),a=n(95),s=n(53);r({target:"Promise",stat:!0},{allSettled:function(e){var t=this,n=o.f(t),r=n.resolve,u=n.reject,l=a((function(){var n=i(t.resolve),o=[],a=0,u=1;s(e,(function(e){var i=a++,s=!1;o.push(void 0),u++,n.call(t,e).then((function(e){s||(s=!0,o[i]={status:"fulfilled",value:e},--u||r(o))}),(function(e){s||(s=!0,o[i]={status:"rejected",reason:e},--u||r(o))}))})),--u||r(o)}));return l.error&&u(l.value),n.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(37),o=n(51),a=n(80),s=n(95),u=n(53);r({target:"Promise",stat:!0},{any:function(e){var t=this,n=a.f(t),r=n.resolve,l=n.reject,c=s((function(){var n=i(t.resolve),a=[],s=0,c=1,f=!1;u(e,(function(e){var i=s++,u=!1;a.push(void 0),c++,n.call(t,e).then((function(e){u||f||(f=!0,r(e))}),(function(e){u||f||(u=!0,a[i]=e,--c||l(new(o("AggregateError"))(a,"No one promise resolved")))}))})),--c||l(new(o("AggregateError"))(a,"No one promise resolved"))}));return c.error&&l(c.value),n.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(80),o=n(95);r({target:"Promise",stat:!0},{try:function(e){var t=i.f(this),n=o(e);return(n.error?t.reject:t.resolve)(n.value),t.promise}})},function(e,t,n){"use strict";var r=n(6),i=n(81).charAt;r({target:"String",proto:!0},{at:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(6),i=n(125),o=n(26),a=n(38),s=n(81),u=s.codeAt,l=s.charAt,c=a.set,f=a.getterFor("String Iterator"),h=i((function(e){c(this,{type:"String Iterator",string:e,index:0})}),"String",(function(){var e,t=f(this),n=t.string,r=t.index;return r>=n.length?{value:void 0,done:!0}:(e=l(n,r),t.index+=e.length,{value:{codePoint:u(e,0),position:r},done:!1})}));r({target:"String",proto:!0},{codePoints:function(){return new h(String(o(this)))}})},function(e,t,n){n(349)},function(e,t,n){"use strict";var r=n(6),i=n(125),o=n(26),a=n(15),s=n(37),u=n(25),l=n(121),c=n(97),f=n(127),h=n(33),d=n(11),p=n(16),y=n(94),m=n(99),g=n(38),v=n(46),b=p("matchAll"),_=g.set,w=g.getterFor("RegExp String Iterator"),T=RegExp.prototype,S=T.exec,E="".matchAll,C=!!E&&!d((function(){"a".matchAll(/./)})),k=i((function(e,t,n,r){_(this,{type:"RegExp String Iterator",regexp:e,string:t,global:n,unicode:r,done:!1})}),"RegExp String",(function(){var e=w(this);if(e.done)return{value:void 0,done:!0};var t=e.regexp,n=e.string,r=function(e,t){var n,r=e.exec;if("function"==typeof r){if("object"!=typeof(n=r.call(e,t)))throw TypeError("Incorrect exec result");return n}return S.call(e,t)}(t,n);return null===r?{value:void 0,done:e.done=!0}:e.global?(""==String(r[0])&&(t.lastIndex=m(n,a(t.lastIndex),e.unicode)),{value:r,done:!1}):(e.done=!0,{value:r,done:!1})})),x=function(e){var t,n,r,i,o,s,l=u(this),c=String(e);return t=y(l,RegExp),void 0===(n=l.flags)&&l instanceof RegExp&&!("flags"in T)&&(n=f.call(l)),r=void 0===n?"":String(n),i=new t(t===RegExp?l.source:l,r),o=!!~r.indexOf("g"),s=!!~r.indexOf("u"),i.lastIndex=a(l.lastIndex),new k(i,c,o,s)};r({target:"String",proto:!0,forced:C},{matchAll:function(e){var t,n,r,i=o(this);if(null!=e){if(c(e)&&!~String(o("flags"in T?e.flags:f.call(e))).indexOf("g"))throw TypeError("`.matchAll` does not allow non-global regexes");if(C)return E.apply(i,arguments);if(void 0===(n=e[b])&&v&&"RegExp"==l(e)&&(n=x),null!=n)return s(n).call(e,i)}else if(C)return E.apply(i,arguments);return t=String(i),r=new RegExp(e,"g"),v?x.call(r,t):r[b](t)}}),v||b in T||h(T,b,x)},function(e,t,n){"use strict";var r=n(6),i=n(26),o=n(97),a=n(127),s=n(16),u=n(46),l=s("replace"),c=RegExp.prototype;r({target:"String",proto:!0},{replaceAll:function e(t,n){var r,s,f,h,d,p,y,m=i(this);if(null!=t){if((r=o(t))&&!~String(i("flags"in c?t.flags:a.call(t))).indexOf("g"))throw TypeError("`.replaceAll` does not allow non-global regexes");if(void 0!==(s=t[l]))return s.call(t,m,n);if(u&&r)return String(m).replace(t,n)}if(f=String(m),""===(h=String(t)))return e.call(f,/(?:)/g,n);if(d=f.split(h),"function"!=typeof n)return d.join(String(n));for(p=d[0],y=1;y<d.length;y++)p+=String(n(h,y-1,f)),p+=d[y];return p}})},function(e,t,n){var r=function(e){"use strict";var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},i=r.iterator||"@@iterator",o=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(e){s=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var i=t&&t.prototype instanceof f?t:f,o=Object.create(i.prototype),a=new S(r||[]);return o._invoke=function(e,t,n){var r="suspendedStart";return function(i,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===i)throw o;return C()}for(n.method=i,n.arg=o;;){var a=n.delegate;if(a){var s=_(a,n);if(s){if(s===c)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var u=l(e,t,n);if("normal"===u.type){if(r=n.done?"completed":"suspendedYield",u.arg===c)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r="completed",n.method="throw",n.arg=u.arg)}}}(e,n,a),o}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=u;var c={};function f(){}function h(){}function d(){}var p={};p[i]=function(){return this};var y=Object.getPrototypeOf,m=y&&y(y(E([])));m&&m!==t&&n.call(m,i)&&(p=m);var g=d.prototype=f.prototype=Object.create(p);function v(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function b(e,t){var r;this._invoke=function(i,o){function a(){return new t((function(r,a){!function r(i,o,a,s){var u=l(e[i],e,o);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,a,s)}),(function(e){r("throw",e,a,s)})):t.resolve(f).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,s)}))}s(u.arg)}(i,o,r,a)}))}return r=r?r.then(a,a):a()}}function _(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method))return c;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return c}var r=l(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,c;var i=r.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,c):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,c)}function w(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function T(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function S(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(w,this),this.reset(!0)}function E(e){if(e){var t=e[i];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return o.next=o}}return{next:C}}function C(){return{value:void 0,done:!0}}return h.prototype=g.constructor=d,d.constructor=h,h.displayName=s(d,a,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,d):(e.__proto__=d,s(e,a,"GeneratorFunction")),e.prototype=Object.create(g),e},e.awrap=function(e){return{__await:e}},v(b.prototype),b.prototype[o]=function(){return this},e.AsyncIterator=b,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new b(u(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},v(g),s(g,a,"Generator"),g[i]=function(){return this},g.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=E,S.prototype={constructor:S,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(T),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var s=n.call(o,"catchLoc"),u=n.call(o,"finallyLoc");if(s&&u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(s){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,c):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),c},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),T(n),c}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;T(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:E(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),c}},e}(e.exports);try{regeneratorRuntime=r}catch(e){Function("r","regeneratorRuntime = r")(r)}},function(e,t,n){},function(e,t,n){"use strict";
|
|
47
47
|
/** @license React v16.11.0
|
|
48
48
|
* react.production.min.js
|
|
49
49
|
*
|
|
@@ -119,4 +119,4 @@ var o=null,a=function(){function e(e){var t,n,r;o||(o=function(){var e,t,n,r,i,o
|
|
|
119
119
|
/*! @name pkcs7 @version 1.0.4 @license Apache-2.0 */
|
|
120
120
|
var e;i(null,(e=l).subarray(0,e.byteLength-e[e.byteLength-1]))}))}return e.prototype.decryptChunk_=function(e,t,n,r){return function(){var i=function(e,t,n){var r,i,o,s,l,c,f,h,d,p=new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),y=new a(Array.prototype.slice.call(t)),m=new Uint8Array(e.byteLength),g=new Int32Array(m.buffer);for(r=n[0],i=n[1],o=n[2],s=n[3],d=0;d<p.length;d+=4)l=u(p[d]),c=u(p[d+1]),f=u(p[d+2]),h=u(p[d+3]),y.decrypt(l,c,f,h,g,d),g[d]=u(g[d]^r),g[d+1]=u(g[d+1]^i),g[d+2]=u(g[d+2]^o),g[d+3]=u(g[d+3]^s),r=l,i=c,o=f,s=h;return m}(e,t,n);r.set(i,e.byteOffset)}},t(e,null,[{key:"STEP",get:function(){return 32e3}}]),e}();new function(e){e.onmessage=function(t){var n=t.data,r=new Uint8Array(n.encrypted.bytes,n.encrypted.byteOffset,n.encrypted.byteLength),i=new Uint32Array(n.key.bytes,n.key.byteOffset,n.key.byteLength/4),o=new Uint32Array(n.iv.bytes,n.iv.byteOffset,n.iv.byteLength/4);new l(r,i,o,(function(t,r){var i,o;e.postMessage((i={source:n.source,decrypted:r},o={},Object.keys(i).forEach((function(e){var t=i[e];ArrayBuffer.isView(t)?o[e]={bytes:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength}:o[e]=t})),o),[r.buffer])}))}}(n)}()})),gu=function(e){var t=e.default?"main":"alternative";return e.characteristics&&e.characteristics.indexOf("public.accessibility.describes-video")>=0&&(t="main-desc"),t},vu=function(e,t){e.abort(),e.pause(),t&&t.activePlaylistLoader&&(t.activePlaylistLoader.pause(),t.activePlaylistLoader=null)},bu=function(e,t){t.activePlaylistLoader=e,e.load()},_u={AUDIO:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e],i=t.blacklistCurrentPlaylist;vu(n,r);var o=r.activeTrack(),a=r.activeGroup(),s=(a.filter((function(e){return e.default}))[0]||a[0]).id,u=r.tracks[s];if(o!==u){for(var l in zo.log.warn("Problem encountered loading the alternate audio track.Switching back to default."),r.tracks)r.tracks[l].enabled=r.tracks[l]===u;r.onTrackChanged()}else i({message:"Problem encountered loading the default audio track."})}},SUBTITLES:function(e,t){return function(){var n=t.segmentLoaders[e],r=t.mediaTypes[e];zo.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track."),vu(n,r);var i=r.activeTrack();i&&(i.mode="disabled"),r.onTrackChanged()}}},wu={AUDIO:function(e,t,n){if(t){var r=n.tech,i=n.requestOptions,o=n.segmentLoaders[e];t.on("loadedmetadata",(function(){var e=t.media();o.playlist(e,i),(!r.paused()||e.endList&&"none"!==r.preload())&&o.load()})),t.on("loadedplaylist",(function(){o.playlist(t.media(),i),r.paused()||o.load()})),t.on("error",_u[e](e,n))}},SUBTITLES:function(e,t,n){var r=n.tech,i=n.requestOptions,o=n.segmentLoaders[e],a=n.mediaTypes[e];t.on("loadedmetadata",(function(){var e=t.media();o.playlist(e,i),o.track(a.activeTrack()),(!r.paused()||e.endList&&"none"!==r.preload())&&o.load()})),t.on("loadedplaylist",(function(){o.playlist(t.media(),i),r.paused()||o.load()})),t.on("error",_u[e](e,n))}},Tu={AUDIO:function(e,t){var n=t.vhs,r=t.sourceType,i=t.segmentLoaders[e],o=t.requestOptions,a=t.master,s=a.mediaGroups,u=a.playlists,l=t.mediaTypes[e],c=l.groups,f=l.tracks,h=t.masterPlaylistLoader;s[e]&&0!==Object.keys(s[e]).length||(s[e]={main:{default:{default:!0}}});var d=function(i){c[i]||(c[i]=[]);var a=u.filter((function(t){return t.attributes[e]===i})),l=function(u){var l=s[e][i][u];!a.filter((function(e){return e.resolvedUri!==l.resolvedUri})).length&&a.length&&delete l.resolvedUri;var d=void 0;if(d="vhs-json"===r&&l.playlists?new aa(l.playlists[0],n,o):l.resolvedUri?new aa(l.resolvedUri,n,o):l.playlists&&"dash"===r?new qa(l.playlists[0],n,o,h):null,l=zo.mergeOptions({id:u,playlistLoader:d},l),wu[e](e,l.playlistLoader,t),c[i].push(l),void 0===f[u]){var p=new zo.AudioTrack({id:u,kind:gu(l),enabled:!1,language:l.language,default:l.default,label:u});f[u]=p}};for(var d in s[e][i])l(d)};for(var p in s[e])d(p);i.on("error",_u[e](e,t))},SUBTITLES:function(e,t){var n=t.tech,r=t.vhs,i=t.sourceType,o=t.segmentLoaders[e],a=t.requestOptions,s=t.master.mediaGroups,u=t.mediaTypes[e],l=u.groups,c=u.tracks,f=t.masterPlaylistLoader;for(var h in s[e])for(var d in l[h]||(l[h]=[]),s[e][h])if(!s[e][h][d].forced){var p=s[e][h][d],y=void 0;if("hls"===i)y=new aa(p.resolvedUri,r,a);else if("dash"===i){if(!p.playlists.filter((function(e){return e.excludeUntil!==1/0})).length)return;y=new qa(p.playlists[0],r,a,f)}else"vhs-json"===i&&(y=new aa(p.playlists?p.playlists[0]:p.resolvedUri,r,a));if(p=zo.mergeOptions({id:d,playlistLoader:y},p),wu[e](e,p.playlistLoader,t),l[h].push(p),void 0===c[d]){var m=n.addRemoteTextTrack({id:d,kind:"subtitles",default:p.default&&p.autoselect,language:p.language,label:d},!1).track;c[d]=m}}o.on("error",_u[e](e,t))},"CLOSED-CAPTIONS":function(e,t){var n=t.tech,r=t.master.mediaGroups,i=t.mediaTypes[e],o=i.groups,a=i.tracks;for(var s in r[e])for(var u in o[s]||(o[s]=[]),r[e][s]){var l=r[e][s][u];if(l.instreamId.match(/CC\d/)&&(o[s].push(zo.mergeOptions({id:u},l)),void 0===a[u])){var c=n.addRemoteTextTrack({id:l.instreamId,kind:"captions",default:l.default&&l.autoselect,language:l.language,label:u},!1).track;a[u]=c}}}},Su={AUDIO:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if(n[r].enabled)return n[r];return null}},SUBTITLES:function(e,t){return function(){var n=t.mediaTypes[e].tracks;for(var r in n)if("showing"===n[r].mode||"hidden"===n[r].mode)return n[r];return null}}},Eu=function(e){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach((function(t){Tu[t](t,e)}));var t=e.mediaTypes,n=e.masterPlaylistLoader,r=e.tech,i=e.vhs;["AUDIO","SUBTITLES"].forEach((function(n){t[n].activeGroup=function(e,t){return function(n){var r=t.masterPlaylistLoader,i=t.mediaTypes[e].groups,o=r.media();if(!o)return null;var a=null;return o.attributes[e]&&(a=i[o.attributes[e]]),a=a||i.main,void 0===n?a:null===n?null:a.filter((function(e){return e.id===n.id}))[0]||null}}(n,e),t[n].activeTrack=Su[n](n,e),t[n].onGroupChanged=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,o=t.mediaTypes[e],a=o.activeTrack(),s=o.activeGroup(a),u=o.activePlaylistLoader;vu(r,o),s&&(s.playlistLoader?(r.resyncLoader(),bu(s.playlistLoader,o)):u&&i.resetEverything())}}(n,e),t[n].onGroupChanging=function(e,t){return function(){var n=t.segmentLoaders[e];n.abort(),n.pause()}}(n,e),t[n].onTrackChanged=function(e,t){return function(){var n=t.segmentLoaders,r=n[e],i=n.main,o=t.mediaTypes[e],a=o.activeTrack(),s=o.activeGroup(a),u=o.activePlaylistLoader;if(vu(r,o),s){if("AUDIO"===e){if(!s.playlistLoader)return i.setAudio(!0),void i.resetEverything();r.setAudio(!0),i.setAudio(!1)}u!==s.playlistLoader?(r.track&&r.track(a),r.resetEverything(),bu(s.playlistLoader,o)):bu(s.playlistLoader,o)}}}(n,e)}));var o=t.AUDIO.activeGroup();if(o){var a=(o.filter((function(e){return e.default}))[0]||o[0]).id;t.AUDIO.tracks[a].enabled=!0,t.AUDIO.onTrackChanged()}n.on("mediachange",(function(){["AUDIO","SUBTITLES"].forEach((function(e){return t[e].onGroupChanged()}))})),n.on("mediachanging",(function(){["AUDIO","SUBTITLES"].forEach((function(e){return t[e].onGroupChanging()}))}));var s=function(){t.AUDIO.onTrackChanged(),r.trigger({type:"usage",name:"vhs-audio-change"}),r.trigger({type:"usage",name:"hls-audio-change"})};for(var u in r.audioTracks().addEventListener("change",s),r.remoteTextTracks().addEventListener("change",t.SUBTITLES.onTrackChanged),i.on("dispose",(function(){r.audioTracks().removeEventListener("change",s),r.remoteTextTracks().removeEventListener("change",t.SUBTITLES.onTrackChanged)})),r.clearTracks("audio"),t.AUDIO.tracks)r.audioTracks().addTrack(t.AUDIO.tracks[u])},Cu=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred"],ku=function(e){return this.audioSegmentLoader_[e]+this.mainSegmentLoader_[e]},xu=function(e){function t(t){var n;n=e.call(this)||this;var r,i=t.src,o=t.handleManifestRedirects,s=t.withCredentials,u=t.tech,l=t.bandwidth,c=t.externVhs,f=t.useCueTags,d=t.blacklistDuration,p=t.enableLowInitialPlaylist,y=t.sourceType,m=t.cacheEncryptionKeys,g=t.handlePartialData,v=t.experimentalBufferBasedABR;if(!i)throw new Error("A non-empty playlist URL or JSON manifest string is required");zs=c,n.experimentalBufferBasedABR=Boolean(v),n.withCredentials=s,n.tech_=u,n.vhs_=u.vhs,n.sourceType_=y,n.useCueTags_=f,n.blacklistDuration=d,n.enableLowInitialPlaylist=p,n.useCueTags_&&(n.cueTagsTrack_=n.tech_.addTextTrack("metadata","ad-cues"),n.cueTagsTrack_.inBandMetadataTrackDispatchType=""),n.requestOptions_={withCredentials:s,handleManifestRedirects:o,timeout:null},n.on("error",n.pauseLoading),n.mediaTypes_=(r={},["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach((function(e){r[e]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:Hs,activeTrack:Hs,onGroupChanged:Hs,onTrackChanged:Hs}})),r),n.mediaSource=new a.a.MediaSource,n.handleDurationChange_=n.handleDurationChange_.bind(h()(n)),n.handleSourceOpen_=n.handleSourceOpen_.bind(h()(n)),n.handleSourceEnded_=n.handleSourceEnded_.bind(h()(n)),n.mediaSource.addEventListener("durationchange",n.handleDurationChange_),n.mediaSource.addEventListener("sourceopen",n.handleSourceOpen_),n.mediaSource.addEventListener("sourceended",n.handleSourceEnded_),n.seekable_=zo.createTimeRanges(),n.hasPlayed_=!1,n.syncController_=new pu(t),n.segmentMetadataTrack_=u.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,n.decrypter_=new mu,n.sourceUpdater_=new uu(n.mediaSource),n.inbandTextTracks_={},n.timelineChangeController_=new yu;var b={vhs:n.vhs_,mediaSource:n.mediaSource,currentTime:n.tech_.currentTime.bind(n.tech_),seekable:function(){return n.seekable()},seeking:function(){return n.tech_.seeking()},duration:function(){return n.duration()},hasPlayed:function(){return n.hasPlayed_},goalBufferLength:function(){return n.goalBufferLength()},bandwidth:l,syncController:n.syncController_,decrypter:n.decrypter_,sourceType:n.sourceType_,inbandTextTracks:n.inbandTextTracks_,cacheEncryptionKeys:m,handlePartialData:g,sourceUpdater:n.sourceUpdater_,timelineChangeController:n.timelineChangeController_};return n.masterPlaylistLoader_="dash"===n.sourceType_?new qa(i,n.vhs_,n.requestOptions_):new aa(i,n.vhs_,n.requestOptions_),n.setupMasterPlaylistLoaderListeners_(),n.mainSegmentLoader_=new Vs(zo.mergeOptions(b,{segmentMetadataTrack:n.segmentMetadataTrack_,loaderType:"main"}),t),n.audioSegmentLoader_=new Vs(zo.mergeOptions(b,{loaderType:"audio"}),t),n.subtitleSegmentLoader_=new fu(zo.mergeOptions(b,{loaderType:"vtt",featuresNativeTextTracks:n.tech_.featuresNativeTextTracks}),t),n.setupSegmentLoaderListeners_(),n.experimentalBufferBasedABR&&(n.masterPlaylistLoader_.one("loadedplaylist",(function(){return n.startABRTimer_()})),n.tech_.on("pause",(function(){return n.stopABRTimer_()})),n.tech_.on("play",(function(){return n.startABRTimer_()}))),Cu.forEach((function(e){n[e+"_"]=ku.bind(h()(n),e)})),n.logger_=Cs("MPC"),n.triggeredFmp4Usage=!1,n.masterPlaylistLoader_.load(),n}p()(t,e);var n=t.prototype;return n.checkABR_=function(){var e=this.selectPlaylist();this.shouldSwitchToMedia_(e)&&this.masterPlaylistLoader_.media(e)},n.startABRTimer_=function(){var e=this;this.stopABRTimer_(),this.abrTimer_=a.a.setInterval((function(){return e.checkABR_()}),250)},n.stopABRTimer_=function(){this.tech_.scrubbing&&this.tech_.scrubbing()||(a.a.clearInterval(this.abrTimer_),this.abrTimer_=null)},n.setupMasterPlaylistLoaderListeners_=function(){var e=this;this.masterPlaylistLoader_.on("loadedmetadata",(function(){var t=e.masterPlaylistLoader_.media(),n=1.5*t.targetDuration*1e3;Ta(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,t.endList&&"none"!==e.tech_.preload()&&(e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load()),Eu({sourceType:e.sourceType_,segmentLoaders:{AUDIO:e.audioSegmentLoader_,SUBTITLES:e.subtitleSegmentLoader_,main:e.mainSegmentLoader_},tech:e.tech_,requestOptions:e.requestOptions_,masterPlaylistLoader:e.masterPlaylistLoader_,vhs:e.vhs_,master:e.master(),mediaTypes:e.mediaTypes_,blacklistCurrentPlaylist:e.blacklistCurrentPlaylist.bind(e)}),e.triggerPresenceUsage_(e.master(),t),e.setupFirstPlay(),!e.mediaTypes_.AUDIO.activePlaylistLoader||e.mediaTypes_.AUDIO.activePlaylistLoader.media()?e.trigger("selectedinitialmedia"):e.mediaTypes_.AUDIO.activePlaylistLoader.one("loadedmetadata",(function(){e.trigger("selectedinitialmedia")}))})),this.masterPlaylistLoader_.on("loadedplaylist",(function(){var t=e.masterPlaylistLoader_.media();if(!t){var n;if(e.excludeUnsupportedVariants_(),e.enableLowInitialPlaylist&&(n=e.selectInitialPlaylist()),n||(n=e.selectPlaylist()),!n||!e.shouldSwitchToMedia_(n))return;if(e.initialMedia_=n,e.masterPlaylistLoader_.media(e.initialMedia_),!("vhs-json"===e.sourceType_&&e.initialMedia_.segments))return;t=e.initialMedia_}e.handleUpdatedMediaPlaylist(t)})),this.masterPlaylistLoader_.on("error",(function(){e.blacklistCurrentPlaylist(e.masterPlaylistLoader_.error)})),this.masterPlaylistLoader_.on("mediachanging",(function(){e.mainSegmentLoader_.abort(),e.mainSegmentLoader_.pause()})),this.masterPlaylistLoader_.on("mediachange",(function(){var t=e.masterPlaylistLoader_.media(),n=1.5*t.targetDuration*1e3;Ta(e.masterPlaylistLoader_.master,e.masterPlaylistLoader_.media())?e.requestOptions_.timeout=0:e.requestOptions_.timeout=n,e.mainSegmentLoader_.playlist(t,e.requestOptions_),e.mainSegmentLoader_.load(),e.tech_.trigger({type:"mediachange",bubbles:!0})})),this.masterPlaylistLoader_.on("playlistunchanged",(function(){var t=e.masterPlaylistLoader_.media();e.stuckAtPlaylistEnd_(t)&&(e.blacklistCurrentPlaylist({message:"Playlist no longer updating."}),e.tech_.trigger("playliststuck"))})),this.masterPlaylistLoader_.on("renditiondisabled",(function(){e.tech_.trigger({type:"usage",name:"vhs-rendition-disabled"}),e.tech_.trigger({type:"usage",name:"hls-rendition-disabled"})})),this.masterPlaylistLoader_.on("renditionenabled",(function(){e.tech_.trigger({type:"usage",name:"vhs-rendition-enabled"}),e.tech_.trigger({type:"usage",name:"hls-rendition-enabled"})}))},n.handleUpdatedMediaPlaylist=function(e){this.useCueTags_&&this.updateAdCues_(e),this.mainSegmentLoader_.playlist(e,this.requestOptions_),this.updateDuration(!e.endList),this.tech_.paused()||(this.mainSegmentLoader_.load(),this.audioSegmentLoader_&&this.audioSegmentLoader_.load())},n.triggerPresenceUsage_=function(e,t){var n=e.mediaGroups||{},r=!0,i=Object.keys(n.AUDIO);for(var o in n.AUDIO)for(var a in n.AUDIO[o]){n.AUDIO[o][a].uri||(r=!1)}r&&(this.tech_.trigger({type:"usage",name:"vhs-demuxed"}),this.tech_.trigger({type:"usage",name:"hls-demuxed"})),Object.keys(n.SUBTITLES).length&&(this.tech_.trigger({type:"usage",name:"vhs-webvtt"}),this.tech_.trigger({type:"usage",name:"hls-webvtt"})),zs.Playlist.isAes(t)&&(this.tech_.trigger({type:"usage",name:"vhs-aes"}),this.tech_.trigger({type:"usage",name:"hls-aes"})),i.length&&Object.keys(n.AUDIO[i[0]]).length>1&&(this.tech_.trigger({type:"usage",name:"vhs-alternate-audio"}),this.tech_.trigger({type:"usage",name:"hls-alternate-audio"})),this.useCueTags_&&(this.tech_.trigger({type:"usage",name:"vhs-playlist-cue-tags"}),this.tech_.trigger({type:"usage",name:"hls-playlist-cue-tags"}))},n.shouldSwitchToMedia_=function(e){var t=this.masterPlaylistLoader_.media(),n=this.tech_.buffered();return function(e){var t=e.currentPlaylist,n=e.nextPlaylist,r=e.forwardBuffer,i=e.bufferLowWaterLine,o=e.bufferHighWaterLine,a=e.duration,s=e.experimentalBufferBasedABR,u=e.log;if(!n)return zo.log.warn("We received no playlist to switch to. Please check your stream."),!1;var l="allowing switch "+(t&&t.id||"null")+" -> "+n.id;if(!t||!t.endList)return u(l+" as current playlist "+(t?"is live":"is not set")),!0;if(n.id===t.id)return!1;var c=s?Wa.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:Wa.MAX_BUFFER_LOW_WATER_LINE;if(a<c)return u(l+" as duration < max low water line ("+a+" < "+c+")"),!0;var f=n.attributes.BANDWIDTH,h=t.attributes.BANDWIDTH;if(f<h&&(!s||r<o)){var d=l+" as next bandwidth < current bandwidth ("+f+" < "+h+")";return s&&(d+=" and forwardBuffer < bufferHighWaterLine ("+r+" < "+o+")"),u(d),!0}if((!s||f>h)&&r>=i){var p=l+" as forwardBuffer >= bufferLowWaterLine ("+r+" >= "+i+")";return s&&(p+=" and next bandwidth > current bandwidth ("+f+" > "+h+")"),u(p),!0}return u("not "+l+" as no switching criteria met"),!1}({currentPlaylist:t,nextPlaylist:e,forwardBuffer:n.length?n.end(n.length-1)-this.tech_.currentTime():0,bufferLowWaterLine:this.bufferLowWaterLine(),bufferHighWaterLine:this.bufferHighWaterLine(),duration:this.duration(),experimentalBufferBasedABR:this.experimentalBufferBasedABR,log:this.logger_})},n.setupSegmentLoaderListeners_=function(){var e=this;this.experimentalBufferBasedABR||(this.mainSegmentLoader_.on("bandwidthupdate",(function(){var t=e.selectPlaylist();e.shouldSwitchToMedia_(t)&&e.masterPlaylistLoader_.media(t),e.tech_.trigger("bandwidthupdate")})),this.mainSegmentLoader_.on("progress",(function(){e.trigger("progress")}))),this.mainSegmentLoader_.on("error",(function(){e.blacklistCurrentPlaylist(e.mainSegmentLoader_.error())})),this.mainSegmentLoader_.on("appenderror",(function(){e.error=e.mainSegmentLoader_.error_,e.trigger("error")})),this.mainSegmentLoader_.on("syncinfoupdate",(function(){e.onSyncInfoUpdate_()})),this.mainSegmentLoader_.on("timestampoffset",(function(){e.tech_.trigger({type:"usage",name:"vhs-timestamp-offset"}),e.tech_.trigger({type:"usage",name:"hls-timestamp-offset"})})),this.audioSegmentLoader_.on("syncinfoupdate",(function(){e.onSyncInfoUpdate_()})),this.audioSegmentLoader_.on("appenderror",(function(){e.error=e.audioSegmentLoader_.error_,e.trigger("error")})),this.mainSegmentLoader_.on("ended",(function(){e.logger_("main segment loader ended"),e.onEndOfStream()})),this.mainSegmentLoader_.on("earlyabort",(function(t){e.experimentalBufferBasedABR||(e.delegateLoaders_("all",["abort"]),e.blacklistCurrentPlaylist({message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},120))}));var t=function(){if(!e.sourceUpdater_.hasCreatedSourceBuffers())return e.tryToCreateSourceBuffers_();var t=e.getCodecsOrExclude_();t&&e.sourceUpdater_.addOrChangeSourceBuffers(t)};this.mainSegmentLoader_.on("trackinfo",t),this.audioSegmentLoader_.on("trackinfo",t),this.mainSegmentLoader_.on("fmp4",(function(){e.triggeredFmp4Usage||(e.tech_.trigger({type:"usage",name:"vhs-fmp4"}),e.tech_.trigger({type:"usage",name:"hls-fmp4"}),e.triggeredFmp4Usage=!0)})),this.audioSegmentLoader_.on("fmp4",(function(){e.triggeredFmp4Usage||(e.tech_.trigger({type:"usage",name:"vhs-fmp4"}),e.tech_.trigger({type:"usage",name:"hls-fmp4"}),e.triggeredFmp4Usage=!0)})),this.audioSegmentLoader_.on("ended",(function(){e.logger_("audioSegmentLoader ended"),e.onEndOfStream()}))},n.mediaSecondsLoaded_=function(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)},n.load=function(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()},n.smoothQualityChange_=function(e){void 0===e&&(e=this.selectPlaylist()),e!==this.masterPlaylistLoader_.media()&&(this.masterPlaylistLoader_.media(e),this.mainSegmentLoader_.resetLoader())},n.fastQualityChange_=function(e){var t=this;void 0===e&&(e=this.selectPlaylist()),e!==this.masterPlaylistLoader_.media()&&(this.masterPlaylistLoader_.media(e),this.mainSegmentLoader_.resetEverything((function(){zo.browser.IE_VERSION||zo.browser.IS_EDGE?t.tech_.setCurrentTime(t.tech_.currentTime()+.04):t.tech_.setCurrentTime(t.tech_.currentTime())})))},n.play=function(){if(!this.setupFirstPlay()){this.tech_.ended()&&this.tech_.setCurrentTime(0),this.hasPlayed_&&this.load();var e=this.tech_.seekable();return this.tech_.duration()===1/0&&this.tech_.currentTime()<e.start(0)?this.tech_.setCurrentTime(e.end(e.length-1)):void 0}},n.setupFirstPlay=function(){var e=this,t=this.masterPlaylistLoader_.media();if(!t||this.tech_.paused()||this.hasPlayed_)return!1;if(!t.endList){var n=this.seekable();if(!n.length)return!1;if(zo.browser.IE_VERSION&&0===this.tech_.readyState())return this.tech_.one("loadedmetadata",(function(){e.trigger("firstplay"),e.tech_.setCurrentTime(n.end(0)),e.hasPlayed_=!0})),!1;this.trigger("firstplay"),this.tech_.setCurrentTime(n.end(0))}return this.hasPlayed_=!0,this.load(),!0},n.handleSourceOpen_=function(){if(this.tryToCreateSourceBuffers_(),this.tech_.autoplay()){var e=this.tech_.play();void 0!==e&&"function"==typeof e.then&&e.then(null,(function(e){}))}this.trigger("sourceopen")},n.handleSourceEnded_=function(){if(this.inbandTextTracks_.metadataTrack_){var e=this.inbandTextTracks_.metadataTrack_.cues;if(e&&e.length){var t=this.duration();e[e.length-1].endTime=isNaN(t)||Math.abs(t)===1/0?Number.MAX_VALUE:t}}},n.handleDurationChange_=function(){this.tech_.trigger("durationchange")},n.onEndOfStream=function(){var e=this.mainSegmentLoader_.ended_;this.mediaTypes_.AUDIO.activePlaylistLoader&&(e=!this.mainSegmentLoader_.currentMediaInfo_||this.mainSegmentLoader_.currentMediaInfo_.hasVideo?e&&this.audioSegmentLoader_.ended_:this.audioSegmentLoader_.ended_),e&&(this.stopABRTimer_(),this.sourceUpdater_.endOfStream())},n.stuckAtPlaylistEnd_=function(e){if(!this.seekable().length)return!1;var t=this.syncController_.getExpiredTime(e,this.duration());if(null===t)return!1;var n=zs.Playlist.playlistEnd(e,t),r=this.tech_.currentTime(),i=this.tech_.buffered();if(!i.length)return n-r<=.1;var o=i.end(i.length-1);return o-r<=.1&&n-o<=.1},n.blacklistCurrentPlaylist=function(e,t){void 0===e&&(e={});var n=e.playlist||this.masterPlaylistLoader_.media();if(t=t||e.blacklistDuration||this.blacklistDuration,!n)return this.error=e,void("open"!==this.mediaSource.readyState?this.trigger("error"):this.sourceUpdater_.endOfStream("network"));var r=this.masterPlaylistLoader_.master.playlists,i=r.filter(_a),o=1===i.length&&i[0]===n;if(1===r.length&&t!==1/0)return zo.log.warn("Problem encountered with playlist "+n.id+". Trying again since it is the only playlist."),this.tech_.trigger("retryplaylist"),this.masterPlaylistLoader_.load(o);if(o){var a=!1;r.forEach((function(e){if(e!==n){var t=e.excludeUntil;void 0!==t&&t!==1/0&&(a=!0,delete e.excludeUntil)}})),a&&(zo.log.warn("Removing other playlists from the exclusion list because the last rendition is about to be excluded."),this.tech_.trigger("retryplaylist"))}n.excludeUntil=Date.now()+1e3*t,this.tech_.trigger("blacklistplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-blacklisted"}),this.tech_.trigger({type:"usage",name:"hls-rendition-blacklisted"});var s=this.selectPlaylist();if(!s)return this.error="Playback cannot continue. No available working or supported playlists.",void this.trigger("error");var u=e.internal?this.logger_:zo.log.warn,l=e.message?" "+e.message:"";u((e.internal?"Internal problem":"Problem")+" encountered with playlist "+n.id+"."+l+" Switching to playlist "+s.id+"."),s.attributes.AUDIO!==n.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),s.attributes.SUBTITLES!==n.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);var c=s.targetDuration/2*1e3||5e3,f="number"==typeof s.lastRequest&&Date.now()-s.lastRequest<=c;return this.masterPlaylistLoader_.media(s,o||f)},n.pauseLoading=function(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()},n.delegateLoaders_=function(e,t){var n=this,r=[],i="all"===e;(i||"main"===e)&&r.push(this.masterPlaylistLoader_);var o=[];(i||"audio"===e)&&o.push("AUDIO"),(i||"subtitle"===e)&&(o.push("CLOSED-CAPTIONS"),o.push("SUBTITLES")),o.forEach((function(e){var t=n.mediaTypes_[e]&&n.mediaTypes_[e].activePlaylistLoader;t&&r.push(t)})),["main","audio","subtitle"].forEach((function(t){var i=n[t+"SegmentLoader_"];!i||e!==t&&"all"!==e||r.push(i)})),r.forEach((function(e){return t.forEach((function(t){"function"==typeof e[t]&&e[t]()}))}))},n.setCurrentTime=function(e){var t=ua(this.tech_.buffered(),e);return this.masterPlaylistLoader_&&this.masterPlaylistLoader_.media()&&this.masterPlaylistLoader_.media().segments?t&&t.length?e:(this.mainSegmentLoader_.resetEverything(),this.mainSegmentLoader_.abort(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.resetEverything(),this.audioSegmentLoader_.abort()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.resetEverything(),this.subtitleSegmentLoader_.abort()),void this.load()):0},n.duration=function(){if(!this.masterPlaylistLoader_)return 0;var e=this.masterPlaylistLoader_.media();return e?e.endList?this.mediaSource?this.mediaSource.duration:zs.Playlist.duration(e):1/0:0},n.seekable=function(){return this.seekable_},n.onSyncInfoUpdate_=function(){var e;if(this.masterPlaylistLoader_){var t=this.masterPlaylistLoader_.media();if(t){var n=this.syncController_.getExpiredTime(t,this.duration());if(null!==n){var r=this.masterPlaylistLoader_.master.suggestedPresentationDelay,i=zs.Playlist.seekable(t,n,r);if(0!==i.length){if(this.mediaTypes_.AUDIO.activePlaylistLoader){if(t=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),null===(n=this.syncController_.getExpiredTime(t,this.duration())))return;if(0===(e=zs.Playlist.seekable(t,n,r)).length)return}var o,a;this.seekable_&&this.seekable_.length&&(o=this.seekable_.end(0),a=this.seekable_.start(0)),e?e.start(0)>i.end(0)||i.start(0)>e.end(0)?this.seekable_=i:this.seekable_=zo.createTimeRanges([[e.start(0)>i.start(0)?e.start(0):i.start(0),e.end(0)<i.end(0)?e.end(0):i.end(0)]]):this.seekable_=i,this.seekable_&&this.seekable_.length&&this.seekable_.end(0)===o&&this.seekable_.start(0)===a||(this.logger_("seekable updated ["+ca(this.seekable_)+"]"),this.tech_.trigger("seekablechanged"))}}}}},n.updateDuration=function(e){if(this.updateDuration_&&(this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.updateDuration_=null),"open"!==this.mediaSource.readyState)return this.updateDuration_=this.updateDuration.bind(this,e),void this.mediaSource.addEventListener("sourceopen",this.updateDuration_);if(e){var t=this.seekable();if(!t.length)return;(isNaN(this.mediaSource.duration)||this.mediaSource.duration<t.end(t.length-1))&&this.sourceUpdater_.setDuration(t.end(t.length-1))}else{var n=this.tech_.buffered(),r=zs.Playlist.duration(this.masterPlaylistLoader_.media());n.length>0&&(r=Math.max(r,n.end(n.length-1))),this.mediaSource.duration!==r&&this.sourceUpdater_.setDuration(r)}},n.dispose=function(){var e=this;this.trigger("dispose"),this.decrypter_.terminate(),this.masterPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),["AUDIO","SUBTITLES"].forEach((function(t){var n=e.mediaTypes_[t].groups;for(var r in n)n[r].forEach((function(e){e.playlistLoader&&e.playlistLoader.dispose()}))})),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose(),this.sourceUpdater_.dispose(),this.timelineChangeController_.dispose(),this.stopABRTimer_(),this.updateDuration_&&this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.mediaSource.removeEventListener("durationchange",this.handleDurationChange_),this.mediaSource.removeEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.removeEventListener("sourceended",this.handleSourceEnded_),this.off()},n.master=function(){return this.masterPlaylistLoader_.master},n.media=function(){return this.masterPlaylistLoader_.media()||this.initialMedia_},n.areMediaTypesKnown_=function(){var e=!!this.mediaTypes_.AUDIO.activePlaylistLoader;return!(!this.mainSegmentLoader_.currentMediaInfo_||e&&!this.audioSegmentLoader_.currentMediaInfo_)},n.getCodecsOrExclude_=function(){var e=this,t={main:this.mainSegmentLoader_.currentMediaInfo_||{},audio:this.audioSegmentLoader_.currentMediaInfo_||{}};t.video=t.main;var n=Es(this.master(),this.media()),r={},i=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(t.main.hasVideo&&(r.video=n.video||t.main.videoCodec||Be.DEFAULT_VIDEO_CODEC),t.main.isMuxed&&(r.video+=","+(n.audio||t.main.audioCodec||Be.DEFAULT_AUDIO_CODEC)),(t.main.hasAudio&&!t.main.isMuxed||t.audio.hasAudio||i)&&(r.audio=n.audio||t.main.audioCodec||t.audio.audioCodec||Be.DEFAULT_AUDIO_CODEC,t.audio.isFmp4=t.main.hasAudio&&!t.main.isMuxed?t.main.isFmp4:t.audio.isFmp4),r.audio||r.video){var o,a={};if(["video","audio"].forEach((function(e){if(r.hasOwnProperty(e)&&(i=t[e].isFmp4,s=r[e],!(i?Object(Be.browserSupportsCodec)(s):Object(Be.muxerSupportsCodec)(s)))){var n=t[e].isFmp4?"browser":"muxer";a[n]=a[n]||[],a[n].push(r[e]),"audio"===e&&(o=n)}var i,s})),i&&o&&this.media().attributes.AUDIO){var s=this.media().attributes.AUDIO;this.master().playlists.forEach((function(t){(t.attributes&&t.attributes.AUDIO)===s&&t!==e.media()&&(t.excludeUntil=1/0)})),this.logger_("excluding audio group "+s+" as "+o+' does not support codec(s): "'+r.audio+'"')}if(!Object.keys(a).length){if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){var u=[];if(["video","audio"].forEach((function(t){var n=(Object(Be.parseCodecs)(e.sourceUpdater_.codecs[t]||"")[t]||{}).type,i=(Object(Be.parseCodecs)(r[t]||"")[t]||{}).type;n&&i&&n.toLowerCase()!==i.toLowerCase()&&u.push('"'+e.sourceUpdater_.codecs[t]+'" -> "'+r[t]+'"')})),u.length)return void this.blacklistCurrentPlaylist({playlist:this.media(),message:"Codec switching not supported: "+u.join(", ")+".",blacklistDuration:1/0,internal:!0})}return r}var l=Object.keys(a).reduce((function(e,t){return e&&(e+=", "),e+=t+' does not support codec(s): "'+a[t].join(",")+'"'}),"")+".";this.blacklistCurrentPlaylist({playlist:this.media(),internal:!0,message:l,blacklistDuration:1/0})}else this.blacklistCurrentPlaylist({playlist:this.media(),message:"Could not determine codecs for playlist.",blacklistDuration:1/0})},n.tryToCreateSourceBuffers_=function(){if("open"===this.mediaSource.readyState&&!this.sourceUpdater_.hasCreatedSourceBuffers()&&this.areMediaTypesKnown_()){var e=this.getCodecsOrExclude_();if(e){this.sourceUpdater_.createSourceBuffers(e);var t=[e.video,e.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(t)}}},n.excludeUnsupportedVariants_=function(){var e=this,t=this.master().playlists,n=[];Object.keys(t).forEach((function(r){var i=t[r];if(-1===n.indexOf(i.id)){n.push(i.id);var o=Es(e.master,i),a=[];!o.audio||Object(Be.muxerSupportsCodec)(o.audio)||Object(Be.browserSupportsCodec)(o.audio)||(i.excludeUntil=1/0,a.push("audio codec "+o.audio)),!o.video||Object(Be.muxerSupportsCodec)(o.video)||Object(Be.browserSupportsCodec)(o.video)||(i.excludeUntil=1/0,a.push("video codec "+o.video)),o.text&&"stpp.ttml.im1t"===o.text&&(i.excludeUntil=1/0,a.push("text codec "+o.text)),a.length&&e.logger_("excluding "+i.id+" as codecs "+a.join(", ")+" are unsupported")}}))},n.excludeIncompatibleVariants_=function(e){var t=this,n=Object(Be.parseCodecs)(e),r=Object.keys(n).length;this.master().playlists.forEach((function(e){if(e.excludeUntil!==1/0){var i={},o=2,a=[],s=Es(t.masterPlaylistLoader_.master,e);if(s.audio||s.video){var u=[s.video,s.audio].filter(Boolean).join(",");i=Object(Be.parseCodecs)(u),o=Object.keys(i).length}o!==r&&(a.push('codec count "'+o+'" !== "'+r+'"'),e.excludeUntil=1/0),t.sourceUpdater_.canChangeType()||(i.video&&n.video&&i.video.type.toLowerCase()!==n.video.type.toLowerCase()&&(a.push('video codec "'+i.video.type+'" !== "'+n.video.type+'"'),e.excludeUntil=1/0),i.audio&&n.audio&&i.audio.type.toLowerCase()!==n.audio.type.toLowerCase()&&(e.excludeUntil=1/0,a.push('audio codec "'+i.audio.type+'" !== "'+n.audio.type+'"'))),a.length&&t.logger_("blacklisting "+e.id+": "+a.join(" && "))}}))},n.updateAdCues_=function(e){var t=0,n=this.seekable();n.length&&(t=n.start(0)),function(e,t,n){if(void 0===n&&(n=0),e.segments)for(var r,i=n,o=0;o<e.segments.length;o++){var s=e.segments[o];if(r||(r=hu(t,i+s.duration/2)),r){if("cueIn"in s){r.endTime=i,r.adEndTime=i,i+=s.duration,r=null;continue}if(i<r.endTime){i+=s.duration;continue}r.endTime+=s.duration}else if("cueOut"in s&&((r=new a.a.VTTCue(i,i+s.duration,s.cueOut)).adStartTime=i,r.adEndTime=i+parseFloat(s.cueOut),t.addCue(r)),"cueOutCont"in s){var u=s.cueOutCont.split("/").map(parseFloat),l=u[0],c=u[1];(r=new a.a.VTTCue(i,i+s.duration,"")).adStartTime=i-l,r.adEndTime=r.adStartTime+c,t.addCue(r)}i+=s.duration}}(e,this.cueTagsTrack_,t)},n.goalBufferLength=function(){var e=this.tech_.currentTime(),t=Wa.GOAL_BUFFER_LENGTH,n=Wa.GOAL_BUFFER_LENGTH_RATE,r=Math.max(t,Wa.MAX_GOAL_BUFFER_LENGTH);return Math.min(t+e*n,r)},n.bufferLowWaterLine=function(){var e=this.tech_.currentTime(),t=Wa.BUFFER_LOW_WATER_LINE,n=Wa.BUFFER_LOW_WATER_LINE_RATE,r=Math.max(t,Wa.MAX_BUFFER_LOW_WATER_LINE),i=Math.max(t,Wa.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE);return Math.min(t+e*n,this.experimentalBufferBasedABR?i:r)},n.bufferHighWaterLine=function(){return Wa.BUFFER_HIGH_WATER_LINE},t}(zo.EventTarget),Ou=function(e,t,n){var r,i,o,a=e.masterPlaylistController_,s=a[(e.options_.smoothQualityChange?"smooth":"fast")+"QualityChange_"].bind(a);if(t.attributes.RESOLUTION){var u=t.attributes.RESOLUTION;this.width=u.width,this.height=u.height}this.bandwidth=t.attributes.BANDWIDTH,this.codecs=Es(a.master(),t),this.playlist=t,this.id=n,this.enabled=(r=e.playlists,i=t.id,o=s,function(e){var t=r.master.playlists[i],n=ba(t),a=_a(t);return void 0===e?a:(e?delete t.disabled:t.disabled=!0,e===a||n||(o(),e?r.trigger("renditionenabled"):r.trigger("renditiondisabled")),e)})},Pu=["seeking","seeked","pause","playing","error"],Ru=function(){function e(e){var t=this;this.masterPlaylistController_=e.masterPlaylistController,this.tech_=e.tech,this.seekable=e.seekable,this.allowSeeksWithinUnsafeLiveWindow=e.allowSeeksWithinUnsafeLiveWindow,this.liveRangeSafeTimeDelta=e.liveRangeSafeTimeDelta,this.media=e.media,this.consecutiveUpdates=0,this.lastRecordedTime=null,this.timer_=null,this.checkCurrentTimeTimeout_=null,this.logger_=Cs("PlaybackWatcher"),this.logger_("initialize");var n=function(){return t.monitorCurrentTime_()},r=function(){return t.techWaiting_()},i=function(){return t.cancelTimer_()},o=function(){return t.fixesBadSeeks_()},s=this.masterPlaylistController_,u=["main","subtitle","audio"],l={};u.forEach((function(e){l[e]={reset:function(){return t.resetSegmentDownloads_(e)},updateend:function(){return t.checkSegmentDownloads_(e)}},s[e+"SegmentLoader_"].on("appendsdone",l[e].updateend),s[e+"SegmentLoader_"].on("playlistupdate",l[e].reset),t.tech_.on(["seeked","seeking"],l[e].reset)})),this.tech_.on("seekablechanged",o),this.tech_.on("waiting",r),this.tech_.on(Pu,i),this.tech_.on("canplay",n),this.dispose=function(){t.logger_("dispose"),t.tech_.off("seekablechanged",o),t.tech_.off("waiting",r),t.tech_.off(Pu,i),t.tech_.off("canplay",n),u.forEach((function(e){s[e+"SegmentLoader_"].off("appendsdone",l[e].updateend),s[e+"SegmentLoader_"].off("playlistupdate",l[e].reset),t.tech_.off(["seeked","seeking"],l[e].reset)})),t.checkCurrentTimeTimeout_&&a.a.clearTimeout(t.checkCurrentTimeTimeout_),t.cancelTimer_()}}var t=e.prototype;return t.monitorCurrentTime_=function(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&a.a.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=a.a.setTimeout(this.monitorCurrentTime_.bind(this),250)},t.resetSegmentDownloads_=function(e){var t=this.masterPlaylistController_[e+"SegmentLoader_"];this[e+"StalledDownloads_"]>0&&this.logger_("resetting possible stalled download count for "+e+" loader"),this[e+"StalledDownloads_"]=0,this[e+"Buffered_"]=t.buffered_()},t.checkSegmentDownloads_=function(e){var t=this.masterPlaylistController_,n=t[e+"SegmentLoader_"],r=n.buffered_(),i=function(e,t){if(e===t)return!1;if(!e&&t||!t&&e)return!0;if(e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e.start(n)!==t.start(n)||e.end(n)!==t.end(n))return!0;return!1}(this[e+"Buffered_"],r);this[e+"Buffered_"]=r,i?this.resetSegmentDownloads_(e):(this[e+"StalledDownloads_"]++,this.logger_("found #"+this[e+"StalledDownloads_"]+" "+e+" appends that did not increase buffer (possible stalled download)",{playlistId:n.playlist_&&n.playlist_.id,buffered:fa(r)}),this[e+"StalledDownloads_"]<10||(this.logger_(e+" loader stalled download exclusion"),this.resetSegmentDownloads_(e),this.tech_.trigger({type:"usage",name:"vhs-"+e+"-download-exclusion"}),"subtitle"!==e&&t.blacklistCurrentPlaylist({message:"Excessive "+e+" segment downloading detected."},1/0)))},t.checkCurrentTime_=function(){if(this.tech_.seeking()&&this.fixesBadSeeks_())return this.consecutiveUpdates=0,void(this.lastRecordedTime=this.tech_.currentTime());if(!this.tech_.paused()&&!this.tech_.seeking()){var e=this.tech_.currentTime(),t=this.tech_.buffered();if(this.lastRecordedTime===e&&(!t.length||e+.1>=t.end(t.length-1)))return this.techWaiting_();this.consecutiveUpdates>=5&&e===this.lastRecordedTime?(this.consecutiveUpdates++,this.waiting_()):e===this.lastRecordedTime?this.consecutiveUpdates++:(this.consecutiveUpdates=0,this.lastRecordedTime=e)}},t.cancelTimer_=function(){this.consecutiveUpdates=0,this.timer_&&(this.logger_("cancelTimer_"),clearTimeout(this.timer_)),this.timer_=null},t.fixesBadSeeks_=function(){if(!this.tech_.seeking())return!1;var e,t=this.seekable(),n=this.tech_.currentTime();this.afterSeekableWindow_(t,n,this.media(),this.allowSeeksWithinUnsafeLiveWindow)&&(e=t.end(t.length-1));if(this.beforeSeekableWindow_(t,n)){var r=t.start(0);e=r+(r===t.end(0)?0:.1)}if(void 0!==e)return this.logger_("Trying to seek outside of seekable at time "+n+" with seekable range "+ca(t)+". Seeking to "+e+"."),this.tech_.setCurrentTime(e),!0;var i=this.tech_.buffered();return!!function(e){var t=e.buffered,n=e.targetDuration,r=e.currentTime;return!!t.length&&(!(t.end(0)-t.start(0)<2*n)&&(!(r>t.start(0))&&t.start(0)-r<n))}({buffered:i,targetDuration:this.media().targetDuration,currentTime:n})&&(e=i.start(0)+.1,this.logger_("Buffered region starts ("+i.start(0)+") just beyond seek point ("+n+"). Seeking to "+e+"."),this.tech_.setCurrentTime(e),!0)},t.waiting_=function(){if(!this.techWaiting_()){var e=this.tech_.currentTime(),t=this.tech_.buffered(),n=ua(t,e);return n.length&&e+3<=n.end(0)?(this.cancelTimer_(),this.tech_.setCurrentTime(e),this.logger_("Stopped at "+e+" while inside a buffered region ["+n.start(0)+" -> "+n.end(0)+"]. Attempting to resume playback by seeking to the current time."),this.tech_.trigger({type:"usage",name:"vhs-unknown-waiting"}),void this.tech_.trigger({type:"usage",name:"hls-unknown-waiting"})):void 0}},t.techWaiting_=function(){var e=this.seekable(),t=this.tech_.currentTime();if(this.tech_.seeking()&&this.fixesBadSeeks_())return!0;if(this.tech_.seeking()||null!==this.timer_)return!0;if(this.beforeSeekableWindow_(e,t)){var n=e.end(e.length-1);return this.logger_("Fell out of live window at time "+t+". Seeking to live point (seekable end) "+n),this.cancelTimer_(),this.tech_.setCurrentTime(n),this.tech_.trigger({type:"usage",name:"vhs-live-resync"}),this.tech_.trigger({type:"usage",name:"hls-live-resync"}),!0}var r=this.tech_.vhs.masterPlaylistController_.sourceUpdater_,i=this.tech_.buffered();if(this.videoUnderflow_({audioBuffered:r.audioBuffered(),videoBuffered:r.videoBuffered(),currentTime:t}))return this.cancelTimer_(),this.tech_.setCurrentTime(t),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),this.tech_.trigger({type:"usage",name:"hls-video-underflow"}),!0;var o=la(i,t);if(o.length>0){var a=o.start(0)-t;return this.logger_("Stopped at "+t+", setting timer for "+a+", seeking to "+o.start(0)),this.cancelTimer_(),this.timer_=setTimeout(this.skipTheGap_.bind(this),1e3*a,t),!0}return!1},t.afterSeekableWindow_=function(e,t,n,r){if(void 0===r&&(r=!1),!e.length)return!1;var i=e.end(e.length-1)+.1;return!n.endList&&r&&(i=e.end(e.length-1)+3*n.targetDuration),t>i},t.beforeSeekableWindow_=function(e,t){return!!(e.length&&e.start(0)>0&&t<e.start(0)-this.liveRangeSafeTimeDelta)},t.videoUnderflow_=function(e){var t=e.videoBuffered,n=e.audioBuffered,r=e.currentTime;if(t){var i;if(t.length&&n.length){var o=ua(t,r-3),a=ua(t,r),s=ua(n,r);s.length&&!a.length&&o.length&&(i={start:o.end(0),end:s.end(0)})}else{la(t,r).length||(i=this.gapFromVideoUnderflow_(t,r))}return!!i&&(this.logger_("Encountered a gap in video from "+i.start+" to "+i.end+". Seeking to current time "+r),!0)}},t.skipTheGap_=function(e){var t=this.tech_.buffered(),n=this.tech_.currentTime(),r=la(t,n);this.cancelTimer_(),0!==r.length&&n===e&&(this.logger_("skipTheGap_:","currentTime:",n,"scheduled currentTime:",e,"nextRange start:",r.start(0)),this.tech_.setCurrentTime(r.start(0)+1/30),this.tech_.trigger({type:"usage",name:"vhs-gap-skip"}),this.tech_.trigger({type:"usage",name:"hls-gap-skip"}))},t.gapFromVideoUnderflow_=function(e,t){for(var n=function(e){if(e.length<2)return zo.createTimeRanges();for(var t=[],n=1;n<e.length;n++){var r=e.end(n-1),i=e.start(n);t.push([r,i])}return zo.createTimeRanges(t)}(e),r=0;r<n.length;r++){var i=n.start(r),o=n.end(r);if(t-i<4&&t-i>2)return{start:i,end:o}}return null},e}(),Au={errorInterval:30,getSource:function(e){return e(this.tech({IWillNotUseThisInPlugins:!0}).currentSource_||this.currentSource())}},Iu=function(e){!function e(t,n){var r=0,i=0,o=zo.mergeOptions(Au,n);t.ready((function(){t.trigger({type:"usage",name:"vhs-error-reload-initialized"}),t.trigger({type:"usage",name:"hls-error-reload-initialized"})}));var a=function(){i&&t.currentTime(i)},s=function(e){null!=e&&(i=t.duration()!==1/0&&t.currentTime()||0,t.one("loadedmetadata",a),t.src(e),t.trigger({type:"usage",name:"vhs-error-reload"}),t.trigger({type:"usage",name:"hls-error-reload"}),t.play())},u=function(){return Date.now()-r<1e3*o.errorInterval?(t.trigger({type:"usage",name:"vhs-error-reload-canceled"}),void t.trigger({type:"usage",name:"hls-error-reload-canceled"})):o.getSource&&"function"==typeof o.getSource?(r=Date.now(),o.getSource.call(t,s)):void zo.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!")},l=function e(){t.off("loadedmetadata",a),t.off("error",u),t.off("dispose",e)};t.on("error",u),t.on("dispose",l),t.reloadSourceOnError=function(n){l(),e(t,n)}}(this,e)},Lu={PlaylistLoader:aa,Playlist:Sa,utils:Na,STANDARD_PLAYLIST_SELECTOR:Is,INITIAL_PLAYLIST_SELECTOR:function(){var e=this,t=this.playlists.master.playlists.filter(Sa.isEnabled);return Ps(t,(function(e,t){return Rs(e,t)})),t.filter((function(t){return!!Es(e.playlists.master,t).video}))[0]||null},lastBandwidthSelector:Is,movingAverageBandwidthSelector:function(e){var t=-1;if(e<0||e>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){var n=this.useDevicePixelRatio&&a.a.devicePixelRatio||1;return t<0&&(t=this.systemBandwidth),t=e*this.systemBandwidth+(1-e)*t,As(this.playlists.master,t,parseInt(Os(this.tech_.el(),"width"),10)*n,parseInt(Os(this.tech_.el(),"height"),10)*n,this.limitRenditionByPlayerDimensions)}},comparePlaylistBandwidth:Rs,comparePlaylistResolution:function(e,t){var n,r;return e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(n=e.attributes.RESOLUTION.width),n=n||a.a.Number.MAX_VALUE,t.attributes.RESOLUTION&&t.attributes.RESOLUTION.width&&(r=t.attributes.RESOLUTION.width),n===(r=r||a.a.Number.MAX_VALUE)&&e.attributes.BANDWIDTH&&t.attributes.BANDWIDTH?e.attributes.BANDWIDTH-t.attributes.BANDWIDTH:n-r},xhr:xa()};Object.keys(Wa).forEach((function(e){Object.defineProperty(Lu,e,{get:function(){return zo.log.warn("using Vhs."+e+" is UNSAFE be sure you know what you are doing"),Wa[e]},set:function(t){zo.log.warn("using Vhs."+e+" is UNSAFE be sure you know what you are doing"),"number"!=typeof t||t<0?zo.log.warn("value of Vhs."+e+" must be greater than or equal to 0"):Wa[e]=t}})}));var ju=function(e,t){for(var n=t.media(),r=-1,i=0;i<e.length;i++)if(e[i].id===n.id){r=i;break}e.selectedIndex_=r,e.trigger({selectedIndex:r,type:"change"})};Lu.canPlaySource=function(){return zo.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var Du=function(e){var t=e.player,n=e.sourceKeySystems,r=e.audioMedia,i=e.mainPlaylists;if(!t.eme.initializeMediaKeys)return Promise.resolve();var o=function(e,t){return e.reduce((function(e,n){if(!n.contentProtection)return e;var r=t.reduce((function(e,t){var r=n.contentProtection[t];return r&&r.pssh&&(e[t]={pssh:r.pssh}),e}),{});return Object.keys(r).length&&e.push(r),e}),[])}(r?i.concat([r]):i,Object.keys(n)),a=[],s=[];return o.forEach((function(e){s.push(new Promise((function(e,n){t.tech_.one("keysessioncreated",e)}))),a.push(new Promise((function(n,r){t.eme.initializeMediaKeys({keySystems:e},(function(e){e?r(e):n()}))})))})),Promise.race([Promise.all(a),Promise.race(s)])},Nu=function(e){var t=e.player,n=function(e,t,n){if(!e)return e;var r={video:t&&t.attributes&&t.attributes.CODECS,audio:n&&n.attributes&&n.attributes.CODECS};!r.audio&&r.video&&r.video.split(",").length>1&&r.video.split(",").forEach((function(e){e=e.trim(),Object(Be.isAudioCodec)(e)?r.audio=e:Object(Be.isVideoCodec)(e)&&(r.video=e)}));var i=r.video?'video/mp4;codecs="'+r.video+'"':null,o=r.audio?'audio/mp4;codecs="'+r.audio+'"':null,a={};for(var s in e)a[s]={audioContentType:o,videoContentType:i},t.contentProtection&&t.contentProtection[s]&&t.contentProtection[s].pssh&&(a[s].pssh=t.contentProtection[s].pssh),"string"==typeof e[s]&&(a[s].url=e[s]);return zo.mergeOptions(e,a)}(e.sourceKeySystems,e.media,e.audioMedia);return!!n&&(t.currentSource().keySystems=n,!(n&&!t.eme)||(zo.log.warn("DRM encrypted source cannot be decrypted without a DRM plugin"),!1))},Mu=function(){if(!a.a.localStorage)return null;var e=a.a.localStorage.getItem("videojs-vhs");if(!e)return null;try{return JSON.parse(e)}catch(e){return null}};Lu.supportsNativeHls=function(){if(!u.a||!u.a.createElement)return!1;var e=u.a.createElement("video");if(!zo.getTech("Html5").isSupported())return!1;return["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some((function(t){return/maybe|probably/i.test(e.canPlayType(t))}))}(),Lu.supportsNativeDash=!!(u.a&&u.a.createElement&&zo.getTech("Html5").isSupported())&&/maybe|probably/i.test(u.a.createElement("video").canPlayType("application/dash+xml")),Lu.supportsTypeNatively=function(e){return"hls"===e?Lu.supportsNativeHls:"dash"===e&&Lu.supportsNativeDash},Lu.isSupported=function(){return zo.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var Uu=function(e){function t(t,n,r){var i;if(i=e.call(this,n,zo.mergeOptions(r.hls,r.vhs))||this,r.hls&&Object.keys(r.hls).length&&zo.log.warn("Using hls options is deprecated. Use vhs instead."),i.logger_=Cs("VhsHandler"),n.options_&&n.options_.playerId){var o=zo(n.options_.playerId);o.hasOwnProperty("hls")||Object.defineProperty(o,"hls",{get:function(){return zo.log.warn("player.hls is deprecated. Use player.tech().vhs instead."),n.trigger({type:"usage",name:"hls-player-access"}),h()(i)},configurable:!0}),o.hasOwnProperty("vhs")||Object.defineProperty(o,"vhs",{get:function(){return zo.log.warn("player.vhs is deprecated. Use player.tech().vhs instead."),n.trigger({type:"usage",name:"vhs-player-access"}),h()(i)},configurable:!0}),o.hasOwnProperty("dash")||Object.defineProperty(o,"dash",{get:function(){return zo.log.warn("player.dash is deprecated. Use player.tech().vhs instead."),h()(i)},configurable:!0}),i.player_=o}if(i.tech_=n,i.source_=t,i.stats={},i.ignoreNextSeekingEvent_=!1,i.setOptions_(),i.options_.overrideNative&&n.overrideNativeAudioTracks&&n.overrideNativeVideoTracks)n.overrideNativeAudioTracks(!0),n.overrideNativeVideoTracks(!0);else if(i.options_.overrideNative&&(n.featuresNativeVideoTracks||n.featuresNativeAudioTracks))throw new Error("Overriding native HLS requires emulated tracks. See https://git.io/vMpjB");return i.on(u.a,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],(function(e){var t=u.a.fullscreenElement||u.a.webkitFullscreenElement||u.a.mozFullScreenElement||u.a.msFullscreenElement;t&&t.contains(i.tech_.el())&&i.masterPlaylistController_.smoothQualityChange_()})),i.on(i.tech_,"seeking",(function(){this.ignoreNextSeekingEvent_?this.ignoreNextSeekingEvent_=!1:this.setCurrentTime(this.tech_.currentTime())})),i.on(i.tech_,"error",(function(){this.tech_.error()&&this.masterPlaylistController_&&this.masterPlaylistController_.pauseLoading()})),i.on(i.tech_,"play",i.play),i}p()(t,e);var n=t.prototype;return n.setOptions_=function(){var e=this;if(this.options_.withCredentials=this.options_.withCredentials||!1,this.options_.handleManifestRedirects=!1!==this.options_.handleManifestRedirects,this.options_.limitRenditionByPlayerDimensions=!1!==this.options_.limitRenditionByPlayerDimensions,this.options_.useDevicePixelRatio=this.options_.useDevicePixelRatio||!1,this.options_.smoothQualityChange=this.options_.smoothQualityChange||!1,this.options_.useBandwidthFromLocalStorage=void 0!==this.source_.useBandwidthFromLocalStorage?this.source_.useBandwidthFromLocalStorage:this.options_.useBandwidthFromLocalStorage||!1,this.options_.customTagParsers=this.options_.customTagParsers||[],this.options_.customTagMappers=this.options_.customTagMappers||[],this.options_.cacheEncryptionKeys=this.options_.cacheEncryptionKeys||!1,this.options_.handlePartialData=this.options_.handlePartialData||!1,"number"!=typeof this.options_.blacklistDuration&&(this.options_.blacklistDuration=300),"number"!=typeof this.options_.bandwidth&&this.options_.useBandwidthFromLocalStorage){var t=Mu();t&&t.bandwidth&&(this.options_.bandwidth=t.bandwidth,this.tech_.trigger({type:"usage",name:"vhs-bandwidth-from-local-storage"}),this.tech_.trigger({type:"usage",name:"hls-bandwidth-from-local-storage"})),t&&t.throughput&&(this.options_.throughput=t.throughput,this.tech_.trigger({type:"usage",name:"vhs-throughput-from-local-storage"}),this.tech_.trigger({type:"usage",name:"hls-throughput-from-local-storage"}))}"number"!=typeof this.options_.bandwidth&&(this.options_.bandwidth=Wa.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===Wa.INITIAL_BANDWIDTH,["withCredentials","useDevicePixelRatio","limitRenditionByPlayerDimensions","bandwidth","smoothQualityChange","customTagParsers","customTagMappers","handleManifestRedirects","cacheEncryptionKeys","handlePartialData","playlistSelector","initialPlaylistSelector","experimentalBufferBasedABR","liveRangeSafeTimeDelta"].forEach((function(t){void 0!==e.source_[t]&&(e.options_[t]=e.source_[t])})),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions,this.useDevicePixelRatio=this.options_.useDevicePixelRatio},n.src=function(e,t){var n=this;if(e){var r;this.setOptions_(),this.options_.src=0===(r=this.source_.src).toLowerCase().indexOf("data:application/vnd.videojs.vhs+json,")?JSON.parse(r.substring(r.indexOf(",")+1)):r,this.options_.tech=this.tech_,this.options_.externVhs=Lu,this.options_.sourceType=Object(M.simpleTypeFromSourceType)(t),this.options_.seekTo=function(e){n.tech_.setCurrentTime(e)},this.masterPlaylistController_=new xu(this.options_);var i=zo.mergeOptions({liveRangeSafeTimeDelta:.1},this.options_,{seekable:function(){return n.seekable()},media:function(){return n.masterPlaylistController_.media()},masterPlaylistController:this.masterPlaylistController_});this.playbackWatcher_=new Ru(i),this.masterPlaylistController_.on("error",(function(){var e=zo.players[n.tech_.options_.playerId],t=n.masterPlaylistController_.error;"object"!=typeof t||t.code?"string"==typeof t&&(t={message:t,code:3}):t.code=3,e.error(t)}));var o=this.options_.experimentalBufferBasedABR?Lu.movingAverageBandwidthSelector(.55):Lu.STANDARD_PLAYLIST_SELECTOR;this.masterPlaylistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):o.bind(this),this.masterPlaylistController_.selectInitialPlaylist=Lu.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.masterPlaylistController_.masterPlaylistLoader_,this.mediaSource=this.masterPlaylistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get:function(){return this.masterPlaylistController_.selectPlaylist},set:function(e){this.masterPlaylistController_.selectPlaylist=e.bind(this)}},throughput:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.throughput.rate},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.throughput.rate=e,this.masterPlaylistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.bandwidth},set:function(e){this.masterPlaylistController_.mainSegmentLoader_.bandwidth=e,this.masterPlaylistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get:function(){var e,t=1/(this.bandwidth||1);return e=this.throughput>0?1/this.throughput:0,Math.floor(1/(t+e))},set:function(){zo.log.error('The "systemBandwidth" property is read-only')}}}),this.options_.bandwidth&&(this.bandwidth=this.options_.bandwidth),this.options_.throughput&&(this.throughput=this.options_.throughput),Object.defineProperties(this.stats,{bandwidth:{get:function(){return n.bandwidth||0},enumerable:!0},mediaRequests:{get:function(){return n.masterPlaylistController_.mediaRequests_()||0},enumerable:!0},mediaRequestsAborted:{get:function(){return n.masterPlaylistController_.mediaRequestsAborted_()||0},enumerable:!0},mediaRequestsTimedout:{get:function(){return n.masterPlaylistController_.mediaRequestsTimedout_()||0},enumerable:!0},mediaRequestsErrored:{get:function(){return n.masterPlaylistController_.mediaRequestsErrored_()||0},enumerable:!0},mediaTransferDuration:{get:function(){return n.masterPlaylistController_.mediaTransferDuration_()||0},enumerable:!0},mediaBytesTransferred:{get:function(){return n.masterPlaylistController_.mediaBytesTransferred_()||0},enumerable:!0},mediaSecondsLoaded:{get:function(){return n.masterPlaylistController_.mediaSecondsLoaded_()||0},enumerable:!0},buffered:{get:function(){return fa(n.tech_.buffered())},enumerable:!0},currentTime:{get:function(){return n.tech_.currentTime()},enumerable:!0},currentSource:{get:function(){return n.tech_.currentSource_},enumerable:!0},currentTech:{get:function(){return n.tech_.name_},enumerable:!0},duration:{get:function(){return n.tech_.duration()},enumerable:!0},master:{get:function(){return n.playlists.master},enumerable:!0},playerDimensions:{get:function(){return n.tech_.currentDimensions()},enumerable:!0},seekable:{get:function(){return fa(n.tech_.seekable())},enumerable:!0},timestamp:{get:function(){return Date.now()},enumerable:!0},videoPlaybackQuality:{get:function(){return n.tech_.getVideoPlaybackQuality()},enumerable:!0}}),this.tech_.one("canplay",this.masterPlaylistController_.setupFirstPlay.bind(this.masterPlaylistController_)),this.tech_.on("bandwidthupdate",(function(){n.options_.useBandwidthFromLocalStorage&&function(e){if(!a.a.localStorage)return!1;var t=Mu();t=t?zo.mergeOptions(t,e):e;try{a.a.localStorage.setItem("videojs-vhs",JSON.stringify(t))}catch(e){return!1}}({bandwidth:n.bandwidth,throughput:Math.round(n.throughput)})})),this.masterPlaylistController_.on("selectedinitialmedia",(function(){var e,t;t=(e=n).playlists,e.representations=function(){return t&&t.master&&t.master.playlists?t.master.playlists.filter((function(e){return!ba(e)})).map((function(t,n){return new Ou(e,t,t.id)})):[]}})),this.masterPlaylistController_.sourceUpdater_.on("createdsourcebuffers",(function(){n.setupEme_()})),this.on(this.masterPlaylistController_,"progress",(function(){this.tech_.trigger("progress")})),this.on(this.masterPlaylistController_,"firstplay",(function(){this.ignoreNextSeekingEvent_=!0})),this.setupQualityLevels_(),this.tech_.el()&&(this.mediaSourceUrl_=a.a.URL.createObjectURL(this.masterPlaylistController_.mediaSource),this.tech_.src(this.mediaSourceUrl_))}},n.setupEme_=function(){var e=this,t=this.masterPlaylistController_.mediaTypes_.AUDIO.activePlaylistLoader,n=Nu({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:t&&t.media()});11!==zo.browser.IE_VERSION&&n?(this.logger_("waiting for EME key session creation"),Du({player:this.player_,sourceKeySystems:this.source_.keySystems,audioMedia:t&&t.media(),mainPlaylists:this.playlists.master.playlists}).then((function(){e.logger_("created EME key session"),e.masterPlaylistController_.sourceUpdater_.initializedEme()})).catch((function(t){e.logger_("error while creating EME key session",t),e.player_.error({message:"Failed to initialize media keys for EME",code:3})}))):this.masterPlaylistController_.sourceUpdater_.initializedEme()},n.setupQualityLevels_=function(){var e=this,t=zo.players[this.tech_.options_.playerId];t&&t.qualityLevels&&!this.qualityLevels_&&(this.qualityLevels_=t.qualityLevels(),this.masterPlaylistController_.on("selectedinitialmedia",(function(){var t,n;t=e.qualityLevels_,(n=e).representations().forEach((function(e){t.addQualityLevel(e)})),ju(t,n.playlists)})),this.playlists.on("mediachange",(function(){ju(e.qualityLevels_,e.playlists)})))},t.version=function(){return{"@videojs/http-streaming":"2.4.2","mux.js":"5.8.0","mpd-parser":"0.15.0","m3u8-parser":"4.5.0","aes-decrypter":"3.1.0"}},n.version=function(){return this.constructor.version()},n.canChangeType=function(){return uu.canChangeType()},n.play=function(){this.masterPlaylistController_.play()},n.setCurrentTime=function(e){this.masterPlaylistController_.setCurrentTime(e)},n.duration=function(){return this.masterPlaylistController_.duration()},n.seekable=function(){return this.masterPlaylistController_.seekable()},n.dispose=function(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.masterPlaylistController_&&this.masterPlaylistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),this.player_&&(delete this.player_.vhs,delete this.player_.dash,delete this.player_.hls),this.tech_&&this.tech_.vhs&&delete this.tech_.vhs,this.tech_&&delete this.tech_.hls,this.mediaSourceUrl_&&a.a.URL.revokeObjectURL&&(a.a.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),e.prototype.dispose.call(this)},n.convertToProgramTime=function(e,t){return Ma({playlist:this.masterPlaylistController_.media(),time:e,callback:t})},n.seekToProgramTime=function(e,t,n,r){return void 0===n&&(n=!0),void 0===r&&(r=2),Ua({programTime:e,playlist:this.masterPlaylistController_.media(),retryCount:r,pauseAfterSeek:n,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:t})},t}(zo.getComponent("Component")),Bu={name:"videojs-http-streaming",VERSION:"2.4.2",canHandleSource:function(e,t){void 0===t&&(t={});var n=zo.mergeOptions(zo.options,t);return Bu.canPlayType(e.type,n)},handleSource:function(e,t,n){void 0===n&&(n={});var r=zo.mergeOptions(zo.options,n);return t.vhs=new Uu(e,t,r),zo.hasOwnProperty("hls")||Object.defineProperty(t,"hls",{get:function(){return zo.log.warn("player.tech().hls is deprecated. Use player.tech().vhs instead."),t.vhs},configurable:!0}),t.vhs.xhr=xa(),t.vhs.src(e.src,e.type),t.vhs},canPlayType:function(e,t){void 0===t&&(t={});var n=zo.mergeOptions(zo.options,t).vhs.overrideNative,r=void 0===n?!zo.browser.IS_ANY_SAFARI:n,i=Object(M.simpleTypeFromSourceType)(e);return i&&(!Lu.supportsTypeNatively(i)||r)?"maybe":""}};Object(Be.browserSupportsCodec)("avc1.4d400d,mp4a.40.2")&&zo.getTech("Html5").registerSourceHandler(Bu,0),zo.VhsHandler=Uu,Object.defineProperty(zo,"HlsHandler",{get:function(){return zo.log.warn("videojs.HlsHandler is deprecated. Use videojs.VhsHandler instead."),Uu},configurable:!0}),zo.VhsSourceHandler=Bu,Object.defineProperty(zo,"HlsSourceHandler",{get:function(){return zo.log.warn("videojs.HlsSourceHandler is deprecated. Use videojs.VhsSourceHandler instead."),Bu},configurable:!0}),zo.Vhs=Lu,Object.defineProperty(zo,"Hls",{get:function(){return zo.log.warn("videojs.Hls is deprecated. Use videojs.Vhs instead."),Lu},configurable:!0}),zo.use||(zo.registerComponent("Hls",Lu),zo.registerComponent("Vhs",Lu)),zo.options.vhs=zo.options.vhs||{},zo.options.hls=zo.options.hls||{},zo.registerPlugin?zo.registerPlugin("reloadSourceOnError",Iu):zo.plugin("reloadSourceOnError",Iu);var Fu=zo,Vu=n(107),Hu=n.n(Vu);function zu(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var qu=function e(t){var n=this;if(Fu.browser.IS_IE8)for(var r in n=Hu.a.createElement("custom"),e.prototype)"constructor"!==r&&(n[r]=e.prototype[r]);return n.id=t.id,n.label=n.id,n.width=t.width,n.height=t.height,n.bitrate=t.bandwidth,n.enabled_=t.enabled,Object.defineProperty(n,"enabled",{get:function(){return n.enabled_()},set:function(e){n.enabled_(e)}}),n},Wu=function(e){
|
|
121
121
|
/*! @name videojs-contrib-quality-levels @version 2.0.9 @license Apache-2.0 */
|
|
122
|
-
var t,n;function r(){var t,n=zu(zu(t=e.call(this)||this));if(Fu.browser.IS_IE8)for(var i in n=Hu.a.createElement("custom"),r.prototype)"constructor"!==i&&(n[i]=r.prototype[i]);return n.levels_=[],n.selectedIndex_=-1,Object.defineProperty(n,"selectedIndex",{get:function(){return n.selectedIndex_}}),Object.defineProperty(n,"length",{get:function(){return n.levels_.length}}),n||zu(t)}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.addQualityLevel=function(e){var t=this.getQualityLevelById(e.id);if(t)return t;var n=this.levels_.length;return t=new qu(e),""+n in this||Object.defineProperty(this,n,{get:function(){return this.levels_[n]}}),this.levels_.push(t),this.trigger({qualityLevel:t,type:"addqualitylevel"}),t},i.removeQualityLevel=function(e){for(var t=null,n=0,r=this.length;n<r;n++)if(this[n]===e){t=this.levels_.splice(n,1)[0],this.selectedIndex_===n?this.selectedIndex_=-1:this.selectedIndex_>n&&this.selectedIndex_--;break}return t&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),t},i.getQualityLevelById=function(e){for(var t=0,n=this.length;t<n;t++){var r=this[t];if(r.id===e)return r}return null},i.dispose=function(){this.selectedIndex_=-1,this.levels_.length=0},r}(Fu.EventTarget);for(var $u in Wu.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"},Wu.prototype.allowedEvents_)Wu.prototype["on"+$u]=null;var Gu=Fu.registerPlugin||Fu.plugin,Yu=function(e){return t=this,Fu.mergeOptions({},e),n=t.qualityLevels,r=new Wu,t.on("dispose",(function e(){r.dispose(),t.qualityLevels=n,t.off("dispose",e)})),t.qualityLevels=function(){return r},t.qualityLevels.VERSION="2.0.9",r;var t,n,r};Gu("qualityLevels",Yu),Yu.VERSION="2.0.9";var Ku=n(234);function Xu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Qu=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.id=n.id,this.plugin=t,this.source=n,this.enabled=this.enabled.bind(this)}var t,n,r;return t=e,(n=[{key:"enabled",value:function(e){return void 0===e?this.plugin.currentSource===this.source:(e&&this.plugin.setSource(this.source.id),e)}}])&&Xu(t.prototype,n),r&&Xu(t,r),e}();function Ju(e){return(Ju="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Zu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function el(e,t){return(el=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=rl(e);if(t){var i=rl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return nl(this,n)}}function nl(e,t){return!t||"object"!==Ju(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function rl(e){return(rl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var il=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&el(e,t)}(o,e);var t,n,r,i=tl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).sources=[],n.qualityLevels=e.qualityLevels(),n.populateSources(t.sources),n}return t=o,(n=[{key:"currentSource",get:function(){return this._currentSource}},{key:"setSource",value:function(e){var t=this,n=this.getSourceById(e);if(null===n)return this.currentSource;var r=this.player.currentTime(),i=!this.player.paused();return this._currentSource=n,this.player.src({src:n.url,type:n.mimeType}),this.player.one("loadedmetadata",(function(){t.player.currentTime()!==r&&t.player.currentTime(r),i&&t.player.play()})),this.trigger({event:"sourcechange",source:n}),this.sourceChangeUpdateQualityLevels(n),n}},{key:"getSourceById",value:function(e){return this.sources.find((function(t){return t.id===e}))}},{key:"populateSources",value:function(e){var t=this,n=null;e.forEach((function(e){t.qualityLevels.addQualityLevel(new Qu(t,e)),t.sources.push(e),t.trigger({event:"addsource",source:e}),e.default&&(n=e)})),null===n&&(n=this.sources[0]),null!==n&&this.setSource(n.id)}},{key:"sourceChangeUpdateQualityLevels",value:function(e){for(var t=this.qualityLevels,n=-1,r=0;r<t.length;r++)if(t[r].id===e.id){n=r;break}t.selectedIndex_=n,t.trigger({selectedIndex:n,type:"change"})}}])&&Zu(t.prototype,n),r&&Zu(t,r),o}(Fu.getPlugin("plugin"));function ol(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Fu.registerPlugin("progressiveFiles",il);var al=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},sl=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.name=t.name,this.playbackProfile=t.playbackProfile,this.address=new URL(t.httpsAddress)}var t,n,r;return t=e,(n=[{key:"getUrl",value:function(e){return e?this.address+"cache?file="+encodeURIComponent(e):null}},{key:"ping",value:function(){return al(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=new AbortController,n=setTimeout((function(){return t.abort()}),1e3),e.prev=3,e.next=6,fetch(this.address+"ping",{method:"GET",mode:"cors",signal:t.signal});case 6:return r=e.sent,e.next=9,r.text();case 9:return i=e.sent,clearTimeout(n),e.abrupt("return","PONG"===i);case 14:return e.prev=14,e.t0=e.catch(3),e.abrupt("return",!1);case 17:case"end":return e.stop()}}),e,this,[[3,14]])})))}}])&&ol(t.prototype,n),r&&ol(t,r),e}();function ul(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var ll=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,r;return t=e,r=[{key:"getKnownProfiles",value:function(){return["1080","720","480","360","240"]}},{key:"enableProfileOrNextBest",value:function(e,t){var n=e.getQualityLevelById(t);if(n||(n=this.getNextBestQuality(e,t)),!n)return null;for(var r=0;r<e.length;r++){var i=e[r];i.enabled=n.id===i.id}return n}},{key:"getNextBestQuality",value:function(e,t){var n=this.getKnownProfiles(),r=n.indexOf(t);if(r>=0){for(var i=r+1;i<n.length;i++){var o=n[i],a=e.getQualityLevelById(o);if(a)return a}for(var s=r-1;s>0;s--){var u=n[s],l=e.getQualityLevelById(u);if(l)return l}}return null}}],(n=null)&&ul(t.prototype,n),r&&ul(t,r),e}();function cl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var fl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},hl=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.player=t,this.logger=Fu.log.createLogger("localcache")}var t,n,r;return t=e,(n=[{key:"setSource",value:function(e,t){return fl(this,void 0,void 0,regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return t(null,e),n.abrupt("return");case 5:null!==(r=n.sent)&&(this.logger.debug("Using Local Cache",r),e.src=r.getUrl(e.src));case 7:t(null,e);case 8:case"end":return n.stop()}}),n,this)})))}}])&&cl(t.prototype,n),r&&cl(t,r),e}();Fu.use("*",(function(e){return new hl(e)}));n(379);function dl(e){return(dl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function pl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yl(e,t,n){return(yl="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=_l(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ml(e,t){return(ml=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function gl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_l(e);if(t){var i=_l(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return vl(this,n)}}function vl(e,t){return!t||"object"!==dl(t)&&"function"!=typeof t?bl(e):t}function bl(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _l(e){return(_l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var wl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Tl=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ml(e,t)}(o,e);var t,n,r,i=gl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).hide(),n.onLocalCacheChange=n.onLocalCacheChange.bind(bl(n)),e.ready((function(){n.initialize()})),n}return t=o,(n=[{key:"createEl",value:function(){return yl(_l(o.prototype),"createEl",this).call(this,"div",{className:"vjs-local-cache-indicator",innerHTML:'<div class="vjs-local-cache-indicator-icon">'.concat('<?xml version="1.0" encoding="UTF-8"?><svg width="24px" height="24px" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" opacity="0.9"><g id="Local-Cache" transform="translate(2.000000, 2.000000)"><rect id="Rectangle" fill="#FFFFFF" x="0" y="2.4" width="18.8" height="15.2"></rect><ellipse id="Oval" fill="#FFFFFF" cx="9.4" cy="2.4" rx="9.4" ry="2.4"></ellipse><ellipse id="Oval-Copy" fill="#FFFFFF" cx="9.4" cy="17.6" rx="9.4" ry="2.4"></ellipse><g id="Logo/Circle" transform="translate(2.500000, 3.000000)"><circle id="Oval" fill="#FFFFFF" cx="7" cy="7" r="7"></circle><polygon id="Fill-1" fill="#F8981D" points="4.66666667 2.33333333 4.66666667 11.4245258 10.0383286 6.87866667"></polygon></g></g></g></svg>',"</div>"),title:"Streaming from ClickView Local Cache"})}},{key:"initialize",value:function(){var e=this;this.localCachePlugin=this.player_.localCache(),this.localCachePlugin&&(this.localCachePlugin.on("localcachechanged",this.onLocalCacheChange),this.player_.on("dispose",(function(){e.localCachePlugin.off("localcachechanged",e.onLocalCacheChange)})),this.onLocalCacheChange())}},{key:"onLocalCacheChange",value:function(){return wl(this,void 0,void 0,regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.localCachePlugin.getActiveLocalCache();case 2:e.sent?this.show():this.hide();case 4:case"end":return e.stop()}}),e,this)})))}}])&&pl(t.prototype,n),r&&pl(t,r),o}(Fu.getComponent("Component"));function Sl(e){return(Sl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function El(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Cl(e,t){return(Cl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function kl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Pl(e);if(t){var i=Pl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return xl(this,n)}}function xl(e,t){return!t||"object"!==Sl(t)&&"function"!=typeof t?Ol(e):t}function Ol(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Pl(e){return(Pl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("localCacheIndicator",Tl);var Rl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Al=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Cl(e,t)}(o,e);var t,n,r,i=kl(o);function o(e,t){var n;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).logger_=Fu.log.createLogger("localcache"),void 0===t)throw Error("no options defined");return n.onPlayerError=n.onPlayerError.bind(Ol(n)),n.dispose=n.dispose.bind(Ol(n)),n.localCaches_=t.localCacheAddresses.map((function(e){return new sl(e)})),n.player.ready((function(){n.initialize(),t.enabled&&n.enable()})),n}return t=o,(n=[{key:"isEnabled",get:function(){return this.enabled_}},{key:"enable",value:function(){this.enabled_=!0,this.resetActiveLocalCache()}},{key:"disable",value:function(){this.enabled_=!1}},{key:"getActiveLocalCache",value:function(){return this.enabled_?this.activeLocalCache_:null}},{key:"resetActiveLocalCache",value:function(){this.clearActiveLocalCache(),this.activeLocalCache_=this.getActiveLocalCacheInternal()}},{key:"clearActiveLocalCache",value:function(){this.activeLocalCache_&&(this.activeLocalCache_=null,this.onLocalCacheChange(null))}},{key:"dispose",value:function(){this.player.off("error",this.onPlayerError)}},{key:"initialize",value:function(){this.player.on("error",this.onPlayerError),this.player.on("dispose",this.dispose),this.player.controlBar.addChild("localCacheIndicator")}},{key:"onPlayerError",value:function(){var e;(null===(e=this.player.error())||void 0===e?void 0:e.code)===MediaError.MEDIA_ERR_NETWORK&&this.resetActiveLocalCache()}},{key:"getActiveLocalCacheInternal",value:function(){return Rl(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=[],n=function(e){return Rl(i,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,e.ping();case 2:if(!n.sent){n.next=4;break}t.push(e);case 4:case"end":return n.stop()}}),n)})))},e.next=4,Promise.all(this.localCaches_.map((function(e){return n(e)})));case 4:if(!(t.length>0)){e.next=8;break}return r=t[0],this.onLocalCacheChange(r),e.abrupt("return",r);case 8:return e.abrupt("return",null);case 9:case"end":return e.stop()}}),e,this)})))}},{key:"onLocalCacheChange",value:function(e){this.logger_.debug("Local Cache changed",e),this.trigger("localcachechanged",{localCache:e});var t=!1;e&&e.playbackProfile&&(this.logger_.debug("Changing active profile for local cache",e.playbackProfile),ll.enableProfileOrNextBest(this.player.qualityLevels(),e.playbackProfile),t=!0),t||this.player.src(this.player.src())}}])&&El(t.prototype,n),r&&El(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("localCache",Al);var Il="cv-persisttest",Ll=function(){try{return window.localStorage.setItem(Il,"cv-player-storage-test"),window.localStorage.removeItem(Il),!0}catch(e){return!1}},jl=function(e){return window.localStorage.getItem(e)},Dl=function(e,t){window.localStorage.setItem(e,t)},Nl=function(e){window.localStorage.removeItem(e)};function Ml(e){return(Ml="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ul(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bl(e,t){return(Bl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Fl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hl(e);if(t){var i=Hl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Vl(this,n)}}function Vl(e,t){return!t||"object"!==Ml(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Hl(e){return(Hl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zl=Fu.getPlugin("plugin"),ql=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Bl(e,t)}(o,e);var t,n,r,i=Fl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){if(this.player.textTracks().length){this.bindEventListeners();var e=!!this.options.showSubtitles,t=this.safeGet("cvplayer-show-subtitles");if("true"===t&&(e=!0),"false"===t&&(e=!1),e){var n=this.guessWhichTrack();n&&(n.mode="showing")}var r=this.safeGet("cvplayer-subtitle-size");r||(r=this.options.subtitleSize),r&&this.player.textTrackSettings.setSizeSetting(r)}}},{key:"safeGet",value:function(e){if(Ll())return jl(e)}},{key:"onSelectedLanguageChange",value:function(){for(var e=this.player.textTracks(),t=0;t<e.length;t++){var n=e[t];if("showing"===n.mode)return Dl("cvplayer-show-subtitles","true"),void Dl("cvplayer-selected-language",n.language)}Dl("cvplayer-show-subtitles","false"),Nl("cvplayer-selected-language")}},{key:"bindEventListeners",value:function(){var e=this;Ll()&&(this.onSelectedLanguageChange=this.onSelectedLanguageChange.bind(this),this.onChangeSubtitleSize=this.onChangeSubtitleSize.bind(this),this.player.on("cv:languageselected",this.onSelectedLanguageChange),this.player.on("changesubtitlesize",this.onChangeSubtitleSize),this.player.one("dispose",(function(){var t,n;null===(t=e.player)||void 0===t||t.off("cv:languageselected",e.onSelectedLanguageChange),null===(n=e.player)||void 0===n||n.off("changesubtitlesize",e.onChangeSubtitleSize)})))}},{key:"onChangeSubtitleSize",value:function(){var e=this.player.textTrackSettings.getSizeSetting();Dl("cvplayer-subtitle-size",e)}},{key:"guessWhichTrack",value:function(){for(var e,t,n=this.safeGet("cvplayer-selected-language")||window.navigator.language,r=this.getLanguageParts(n),i=r.language,o=r.country,a=this.player.textTracks(),s=0;s<a.length;s++){var u=a[s],l=this.getLanguageParts(u.language),c=l.language,f=l.country;if(c===i&&(e=u,f||(t=u),f===o))return e}return t||e||null}},{key:"getLanguageParts",value:function(e){var t=e.toLowerCase().split("-");return{language:t[0],country:t[1]}}}])&&Ul(t.prototype,n),r&&Ul(t,r),o}(zl);function Wl(e){return(Wl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function $l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Gl(e,t){return(Gl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Yl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xl(e);if(t){var i=Xl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Kl(this,n)}}function Kl(e,t){return!t||"object"!==Wl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xl(e){return(Xl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistSubtitleSettingsPlugin",ql);var Ql=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Jl=Fu.getPlugin("plugin"),Zl=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Gl(e,t)}(o,e);var t,n,r,i=Yl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i,o=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.isLocalCacheActive();case 2:if(t=e.sent,n=t?this.options.playbackProfileLocalCache:this.options.playbackProfile,Ll()&&(r=jl(this.getStorageKey(t)))&&(n=r),i=this.player.qualityLevels(),ll.enableProfileOrNextBest(i,n),Ll()){e.next=9;break}return e.abrupt("return");case 9:this.onQualityLevelsChange=this.onQualityLevelsChange.bind(this),i.on("change",this.onQualityLevelsChange),this.player.on("dispose",(function(){i.off("change",o.onQualityLevelsChange)}));case 12:case"end":return e.stop()}}),e,this)})))}},{key:"onQualityLevelsChange",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.isLocalCacheActive();case 2:t=e.sent,n=this.player.qualityLevels(),r=n[n.selectedIndex],Dl(this.getStorageKey(t),r.id);case 6:case"end":return e.stop()}}),e,this)})))}},{key:"isLocalCacheActive",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.player.localCache().getActiveLocalCache();case 2:return e.abrupt("return",!!e.sent);case 3:case"end":return e.stop()}}),e,this)})))}},{key:"getStorageKey",value:function(e){return e?"cvplayer-localcache-playback-quality":"cvplayer-playback-quality"}}])&&$l(t.prototype,n),r&&$l(t,r),o}(Jl);function ec(e){return(ec="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function tc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rc(e,t){return(rc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ic(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ac(e);if(t){var i=ac(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oc(this,n)}}function oc(e,t){return!t||"object"!==ec(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ac(e){return(ac=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistQualitySettingsPlugin",Zl);var sc=Fu.getPlugin("plugin"),uc="play",lc="playing",cc="pause",fc="seeking",hc="seekstart",dc="seekend",pc="ended",yc="pausedseek",mc="timeupdate",gc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&rc(e,t)}(o,e);var t,n,r,i=ic(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).eventBuffer=[],n.latestTime=0,n.lastPlayingTime=0,n.isPlaying=!1,n.isSeeking=!1,n.hasEnded=!1,n.shouldLogPlayOnTimeUpdate=!1,n.options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){this.validateOptions(),this.bindListeners(),this.startInterval()}},{key:"validateOptions",value:function(){if("function"!=typeof this.options.onFlush)throw new Error("Please provide the onFlush option")}},{key:"bindListeners",value:function(){var e,t=this,n=(tc(e={},uc,(function(){return t.onPlay()})),tc(e,cc,(function(){return t.onPause()})),tc(e,mc,(function(){return t.onTimeUpdate()})),tc(e,fc,(function(){return t.onSeeking()})),tc(e,pc,(function(){return t.onEnded()})),e);for(var r in n)n.hasOwnProperty(r)&&this.player.on(r,n[r])}},{key:"startInterval",value:function(){var e=this,t=this.options.interval||5e3;setInterval((function(){return e.flushBuffer()}),t)}},{key:"onPlay",value:function(){return this.isPlaying=!0,this.isSeeking?(this.logEvent(dc),void(this.isSeeking=!1)):this.hasEnded?(this.shouldLogPlayOnTimeUpdate=!0,void(this.hasEnded=!1)):void this.logEvent(uc)}},{key:"onPause",value:function(){var e=this;this.isSeeking||(this.pauseTimeout=window.setTimeout((function(){e.isPlaying=!1,e.logEvent(cc),delete e.pauseTimeout}),50))}},{key:"onTimeUpdate",value:function(){this.shouldLogPlayOnTimeUpdate&&(this.shouldLogPlayOnTimeUpdate=!1,this.logEvent(uc)),this.isPlaying&&!this.isSeeking&&this.logEvent(lc)}},{key:"onSeeking",value:function(){this.pauseTimeout&&(this.latestTime=this.previousLatestTime,window.clearTimeout(this.pauseTimeout),delete this.pauseTimeout),this.isPlaying||this.logEvent(yc),!this.isSeeking&&this.isPlaying&&(this.isSeeking=!0,this.logEvent(hc))}},{key:"onEnded",value:function(){this.hasEnded=!0,this.logEvent(pc)}},{key:"logEvent",value:function(e){if(this.player){var t=this.player.currentTime();e===hc&&(t=this.latestTime),this.previousLatestTime=this.latestTime,this.latestTime=this.player.currentTime(),this.eventBuffer.push({time:t,type:e})}}},{key:"shouldUseCarriedOverTime",value:function(e){return this.lastPlayingTime&&(e===lc||e===uc)}},{key:"shouldClearCarriedOverTime",value:function(e){return e===pc||e===yc}},{key:"flushBuffer",value:function(){for(var e,t=[],n={};this.eventBuffer.length;){var r=this.eventBuffer.shift();this.shouldClearCarriedOverTime(r.type)?delete this.lastPlayingTime:n.start?r.type===lc&&this.eventBuffer.length>0||(this.shouldUseCarriedOverTime(r.type)&&(this.lastPlayingTime=r.time),n.end=r,t.push(n),n={}):(this.shouldUseCarriedOverTime(r.type)&&(r.time=this.lastPlayingTime,delete this.lastPlayingTime),n.start=r)}this.eventBuffer=[],t.length&&(this.options.onFlush(t),null===(e=this.player)||void 0===e||e.trigger("progressflush"))}}])&&nc(t.prototype,n),r&&nc(t,r),o}(sc);Fu.registerPlugin("progressReporterPlugin",gc);n(380);function vc(e){return(vc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function bc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wc(e,t){return(wc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Tc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ec(e);if(t){var i=Ec(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Sc(this,n)}}function Sc(e,t){return!t||"object"!==vc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ec(e){return(Ec=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Cc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&wc(e,t)}(o,e);var t,n,r,i=Tc(o);function o(){return bc(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("span",{innerHTML:'<span class="vjs-icon-placeholder"></span>',className:"cv-drag-handle vjs-control vjs-button"},{})}}])&&_c(t.prototype,n),r&&_c(t,r),o}(Fu.getComponent("Component")),kc=["top","left","right","bottom"],xc={top:"Top",left:"Left",right:"Right",bottom:"Bottom"};n(381);function Oc(e){return(Oc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Pc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ac(e,t,n){return t&&Rc(e.prototype,t),n&&Rc(e,n),e}function Ic(e,t,n){return(Ic="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Mc(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Lc(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&jc(e,t)}function jc(e,t){return(jc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Dc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Mc(e);if(t){var i=Mc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Nc(this,n)}}function Nc(e,t){return!t||"object"!==Oc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Mc(e){return(Mc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Uc=Fu.getComponent("Component"),Bc=function(e){Lc(n,e);var t=Dc(n);function n(e,r){var i;return Pc(this,n),(i=t.call(this,e,r)).bindEventListeners(),i}return Ac(n,[{key:"createEl",value:function(){return Ic(Mc(n.prototype),"createEl",this).call(this,"div",{},{class:"cv-drop-target cv-drop-".concat(this.options_.side)})}},{key:"bindEventListeners",value:function(){var e=this,t=this.el(),n=function(t){t.preventDefault(),t.dataTransfer.dropEffect="move",e.addClass("cv-drag-over")},r=function(t){t.preventDefault(),e.removeClass("cv-drag-over"),e.player_.whiteboardModePlugin().setWhiteboardMode(e.options_.side)},i=function(){e.removeClass("cv-drag-over")};t.addEventListener("dragover",n),t.addEventListener("drop",r),t.addEventListener("dragleave",i),this.on("dispose",(function(){t.removeEventListener("dragover",n),t.removeEventListener("drop",r),t.removeEventListener("dragleave",i)}))}}]),n}(Uc),Fc=function(e){Lc(n,e);var t=Dc(n);function n(e,r){var i;return Pc(this,n),(i=t.call(this,e,r)).addChildren(),i}return Ac(n,[{key:"addChildren",value:function(){var e=this;kc.forEach((function(t){e.addChild(new Bc(e.player_,{side:t}))}))}}]),n}(Uc);function Vc(e){return(Vc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Hc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zc(e,t){return(zc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function qc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$c(e);if(t){var i=$c(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Wc(this,n)}}function Wc(e,t){return!t||"object"!==Vc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $c(e){return($c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Gc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zc(e,t)}(o,e);var t,n,r,i=qc(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"handleClick",value:function(){this.player_.whiteboardModePlugin().setWhiteboardMode(this.options_.side)}}])&&Hc(t.prototype,n),r&&Hc(t,r),o}(Fu.getComponent("MenuItem"));function Yc(e){return(Yc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Kc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Qc(e,t,n){return(Qc="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=tf(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Jc(e,t){return(Jc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Zc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=tf(e);if(t){var i=tf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ef(this,n)}}function ef(e,t){return!t||"object"!==Yc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function tf(e){return(tf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var nf=Fu.getComponent("MenuButton"),rf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Jc(e,t)}(o,e);var t,n,r,i=Zc(o);function o(){var e;return Kc(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!0,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"createItems",value:function(){var e=this,t=this.player_.whiteboardModePlugin().side,n=[];return kc.forEach((function(r){n.push(new Gc(e.player_,{side:r,label:xc[r],selectable:!0,multiSelectable:!1,selected:r===t}))})),n}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Qc(tf(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"getCollabsibleName",value:function(){return"Video controls"}},{key:"getCollabsibleValue",value:function(){var e=this.player_.whiteboardModePlugin().side;return xc[e]}},{key:"showInCollabsibleMenu",value:function(){return this.player_.isFullscreen()}},{key:"showCollapsibleMenu",value:function(){nf.prototype.handleClick.apply(this)}}])&&Xc(t.prototype,n),r&&Xc(t,r),o}(nf);n(382);function of(e){return(of="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function af(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sf(e,t){return(sf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function uf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=cf(e);if(t){var i=cf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return lf(this,n)}}function lf(e,t){return!t||"object"!==of(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function cf(e){return(cf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ff="cv-whiteboard-side",hf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&sf(e,t)}(o,e);var t,n,r,i=uf(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).side="bottom",t.player.ready((function(){t.initialize()})),t}return t=o,(n=[{key:"initialize",value:function(){if(Ll()){var e=jl(ff);e&&(this.side=e)}this.initCollapserator(),this.initDragTargets(),this.initFullscreenListener()}},{key:"initCollapserator",value:function(){var e=this,t=this.player.getChild("collapserator"),n=new Cc(this.player);this.button=new rf(this.player),t.addChild(n),t.addChild(this.button),this.player.trigger("cv-updatecog");var r=function(){t.el().setAttribute("draggable","true")},i=function(){t.el().setAttribute("draggable","false")},o=function(t){e.player.addClass("cv-dragging"),t.dataTransfer.setData("text/plain","handle")},a=function(){e.player.removeClass("cv-dragging"),t.el().setAttribute("draggable","false")};n.el().addEventListener("mousedown",r),n.el().addEventListener("mouseup",i),t.el().addEventListener("dragstart",o),t.el().addEventListener("dragend",a),this.player.on("dispoe",(function(){n.el().removeEventListener("mousedown",r),n.el().removeEventListener("mouseup",i),t.el().removeEventListener("dragstart",o),t.el().removeEventListener("dragend",a)}))}},{key:"initDragTargets",value:function(){this.player.addChild(new Fc(this.player))}},{key:"initFullscreenListener",value:function(){var e=this;this.update=this.update.bind(this),this.player.on("fullscreenchange",this.update),this.player.on("dispose",(function(){var t;null===(t=e.player)||void 0===t||t.off("fullscreenchange",e.update)}))}},{key:"setWhiteboardMode",value:function(e){this.side=e,this.button.update(),Ll()&&Dl(ff,e),this.player.trigger("cv-whiteboard-change"),this.update()}},{key:"update",value:function(){this.player.removeClass("cv-whiteboard-top"),this.player.removeClass("cv-whiteboard-left"),this.player.removeClass("cv-whiteboard-right"),this.player.trigger("resizemenus"),this.player.isFullscreen()&&"bottom"!==this.side&&this.player.addClass("cv-whiteboard-".concat(this.side))}}])&&af(t.prototype,n),r&&af(t,r),o}(Fu.getPlugin("plugin"));function df(e){return(df="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function pf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yf(e,t){return(yf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function mf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=vf(e);if(t){var i=vf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return gf(this,n)}}function gf(e,t){return!t||"object"!==df(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function vf(e){return(vf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("whiteboardModePlugin",hf),window.__onGCastApiAvailable=function(e){e&&(bf=new _f)},window.videojs=Fu;var bf,_f=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&yf(e,t)}(o,e);var t,n,r,i=mf(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this,null)).setOptions(),e.remotePlayer=new cast.framework.RemotePlayer,e.remotePlayerController=new cast.framework.RemotePlayerController(e.remotePlayer),e.bindListeners(),e}return t=o,(n=[{key:"play",value:function(){}},{key:"castConext",get:function(){return cast.framework.CastContext.getInstance()}},{key:"setOptions",value:function(){this.castConext.setOptions({receiverApplicationId:chrome.cast.media.DEFAULT_MEDIA_RECEIVER_APP_ID,autoJoinPolicy:chrome.cast.AutoJoinPolicy.ORIGIN_SCOPED})}},{key:"castState",get:function(){return this.castConext.getCastState()}},{key:"castSession",get:function(){return bf.castConext.getCurrentSession()}},{key:"isConnected",value:function(){return this.castState===cast.framework.CastState.CONNECTED&&this.remotePlayer.isConnected}},{key:"bindListeners",value:function(){this.onCastStateChange=this.onCastStateChange.bind(this),this.onIsConnectedChanged=this.onIsConnectedChanged.bind(this),this.castConext.addEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,this.onCastStateChange),this.remotePlayerController.addEventListener(cast.framework.RemotePlayerEventType.IS_CONNECTED_CHANGED,this.onIsConnectedChanged)}},{key:"onIsConnectedChanged",value:function(){try{this.trigger("isconnectedchanged",this.remotePlayer.isConnected)}catch(e){console.log(e)}console.log(this.remotePlayer.isConnected)}},{key:"dispose",value:function(){this.castConext.removeEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,this.onCastStateChange),this.remotePlayerController.removeEventListener(cast.framework.RemotePlayerEventType.IS_CONNECTED_CHANGED,this.onIsConnectedChanged)}},{key:"onCastStateChange",value:function(e){this.hasAvailableDevices(e.castState)?this.trigger("devicesAvailable"):this.trigger("devicesUnabailable")}},{key:"stopCasting",value:function(){this.castConext.getCurrentSession().endSession(!0)}},{key:"getDeviceName",value:function(){var e,t;return null===(t=null===(e=this.castConext.getCurrentSession())||void 0===e?void 0:e.getCastDevice())||void 0===t?void 0:t.friendlyName}},{key:"hasAvailableDevices",value:function(e){return e||(e=this.castConext.getCastState()),e===cast.framework.CastState.NOT_CONNECTED||e===cast.framework.CastState.CONNECTING||e===cast.framework.CastState.CONNECTED}}])&&pf(t.prototype,n),r&&pf(t,r),o}(Fu.getComponent("Component"));n(383);function wf(e){return(wf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Tf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Sf(e,t,n){return(Sf="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=xf(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ef(e,t){return(Ef=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Cf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=xf(e);if(t){var i=xf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kf(this,n)}}function kf(e,t){return!t||"object"!==wf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function xf(e){return(xf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Of=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ef(e,t)}(o,e);var t,n,r,i=Cf(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this,null)).update(),e}return t=o,(n=[{key:"play",value:function(){}},{key:"createEl",value:function(){return Sf(xf(o.prototype),"createEl",this).call(this,"div",{className:"cv-chromecast-tech"})}},{key:"setTitle",value:function(e){this.title=e,this.update()}},{key:"setPoster",value:function(e){this.poster=e,this.update()}},{key:"disconnect",value:function(e){e.stopPropagation(),bf.stopCasting()}},{key:"update",value:function(){this.el_.innerHTML='\n <div class="cv-chromecast-content">\n '.concat(this.title?"<h1>".concat(this.title,"</h1>"):"","\n <p>Currently playing on: ").concat(bf.getDeviceName(),'</p>\n </div>\n <div class="cv-chromecast-background" style="background-image: url(').concat(this.poster,')"></div>\n ');var e=document.createElement("div");e.className="btn btn-primary cursor-pointer",e.onclick=this.disconnect.bind(this),e.innerHTML="Stop casting",this.el_.querySelector(".cv-chromecast-content").appendChild(e)}}])&&Tf(t.prototype,n),r&&Tf(t,r),o}(Fu.getComponent("Component"));function Pf(e){return(Pf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Rf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Af(e,t,n){return(Af="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Df(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function If(e,t){return(If=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Lf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Df(e);if(t){var i=Df(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jf(this,n)}}function jf(e,t){return!t||"object"!==Pf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Df(e){return(Df=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Nf=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Mf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&If(e,t)}(o,e);var t,n,r,i=Lf(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),bf.isConnected()&&e.source&&n.setSource(e.source),n.bindEventListeners(),e.poster&&n.setPoster(e.poster),n.triggerReady(),n}return t=o,r=[{key:"canPlaySource",value:function(){return bf.isConnected()}},{key:"isSupported",value:function(){return!!bf&&bf.isConnected()}}],(n=[{key:"createEl",value:function(){return this.ui=new Of,this.ui.el()}},{key:"bindEventListeners",value:function(){this.onPlayerStateChanged=this.onPlayerStateChanged.bind(this),this.onVolumeLevelChanged=this.onVolumeLevelChanged.bind(this),this.onCurrentTimeChanged=this.onCurrentTimeChanged.bind(this),this.onDurationChanged=this.onDurationChanged.bind(this);var e=cast.framework.RemotePlayerEventType,t=bf.remotePlayerController;t.addEventListener(e.PLAYER_STATE_CHANGED,this.onPlayerStateChanged),t.addEventListener(e.VOLUME_LEVEL_CHANGED,this.onVolumeLevelChanged),t.addEventListener(e.IS_MUTED_CHANGED,this.onVolumeLevelChanged),t.addEventListener(e.CURRENT_TIME_CHANGED,this.onCurrentTimeChanged),t.addEventListener(e.DURATION_CHANGED,this.onDurationChanged)}},{key:"dispose",value:function(){var e=cast.framework.RemotePlayerEventType,t=bf.remotePlayerController;t.removeEventListener(e.PLAYER_STATE_CHANGED,this.onPlayerStateChanged),t.removeEventListener(e.VOLUME_LEVEL_CHANGED,this.onVolumeLevelChanged),t.removeEventListener(e.IS_MUTED_CHANGED,this.onVolumeLevelChanged),t.removeEventListener(e.CURRENT_TIME_CHANGED,this.onCurrentTimeChanged),t.removeEventListener(e.DURATION_CHANGED,this.onDurationChanged),Af(Df(o.prototype),"dispose",this).call(this)}},{key:"onPlayerStateChanged",value:function(){var e=bf.remotePlayer.playerState;e===chrome.cast.media.PlayerState.PLAYING?(this.trigger("play"),this.trigger("playing")):e===chrome.cast.media.PlayerState.PAUSED?this.trigger("pause"):e===chrome.cast.media.PlayerState.BUFFERING?this.trigger("waiting"):e===chrome.cast.media.PlayerState.IDLE&&this.ended()&&this.trigger("ended")}},{key:"stopCasting",value:function(){var e=window.setTimeout((function(){bf.stopCasting()}),1e4);this.on("dispose",(function(){window.clearTimeout(e)}))}},{key:"setPoster",value:function(e){this.poster_=e,this.ui.setPoster(e)}},{key:"poster",value:function(){return this.poster_}},{key:"setTitle",value:function(e){this.ui.setTitle(e)}},{key:"onVolumeLevelChanged",value:function(){this.trigger("volumechange")}},{key:"onCurrentTimeChanged",value:function(){this.trigger("timeupdate")}},{key:"onDurationChanged",value:function(){this.trigger("durationchange")}},{key:"setSource",value:function(e){var t,n;return Nf(this,void 0,void 0,regeneratorRuntime.mark((function r(){var i,o,a;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(i=bf.castSession.getMediaSession(),this.trigger("waiting"),(null===(t=null==i?void 0:i.media)||void 0===t?void 0:t.contentId)!==e.src||(null===(n=null==i?void 0:i.media)||void 0===n?void 0:n.contentType)!==e.type){r.next=5;break}return this.triggerLoaded(),r.abrupt("return");case 5:return o=new chrome.cast.media.MediaInfo(e.src,e.type),(a=new chrome.cast.media.LoadRequest(o)).autoplay=!0,a.currentTime=this.currentTime()||this.options_.startTime||0,r.prev=9,r.next=12,bf.castSession.loadMedia(a);case 12:r.next=17;break;case 14:r.prev=14,r.t0=r.catch(9),this.trigger("error");case 17:this.triggerLoaded();case 18:case"end":return r.stop()}}),r,this,[[9,14]])})))}},{key:"triggerLoaded",value:function(){var e=this,t=function(){e.trigger("loadstart"),e.trigger("loadeddata"),e.trigger("play"),e.trigger("playing")};if(this.duration())t();else{var n=bf.remotePlayerController,r=cast.framework.RemotePlayerEventType,i=function e(){t(),n.removeEventListener(r.DURATION_CHANGED,e),n.removeEventListener(r.CURRENT_TIME_CHANGED,e)};n.addEventListener(r.DURATION_CHANGED,i),n.addEventListener(r.CURRENT_TIME_CHANGED,i)}}},{key:"play",value:function(){this.paused()&&bf.remotePlayerController.playOrPause()}},{key:"pause",value:function(){!this.paused()&&bf.remotePlayer.canPause&&bf.remotePlayerController.playOrPause()}},{key:"paused",value:function(){return bf.remotePlayer.isPaused||this.ended()||null===bf.remotePlayer.playerState}},{key:"ended",value:function(){var e,t=null===(e=bf.castSession)||void 0===e?void 0:e.getMediaSession();return!t||t.idleReason===chrome.cast.media.IdleReason.FINISHED}},{key:"setCurrentTime",value:function(e){var t=this.duration();e>t||!bf.remotePlayer.canSeek||(bf.remotePlayer.currentTime=Math.min(t-1,e),bf.remotePlayerController.seek(),this.trigger("timeupdate"))}},{key:"currentTime",value:function(){return bf.remotePlayer.currentTime}},{key:"duration",value:function(){return this.durationCache_=bf.remotePlayer.duration,this.durationCache_}},{key:"volume",value:function(){return bf.remotePlayer.volumeLevel}},{key:"setVolume",value:function(e){bf.remotePlayer.volumeLevel=e,bf.remotePlayerController.setVolumeLevel(),this.trigger("volumechange")}},{key:"muted",value:function(){return bf.remotePlayer.isMuted}},{key:"setMuted",value:function(e){this.muted()===e&&bf.remotePlayerController.muteOrUnmute()}},{key:"buffered",value:function(){}},{key:"seekable",value:function(){return Fu.createTimeRanges(0,this.duration())}},{key:"controls",value:function(){return!1}},{key:"playsinline",value:function(){return!0}},{key:"supportsFullScreen",value:function(){return!0}},{key:"setAutoplay",value:function(){}},{key:"preload",value:function(){}},{key:"load",value:function(){}},{key:"setPlaybackRate",value:function(){}},{key:"playbackRate",value:function(){var e=bf.castSession.getMediaSession();return e?e.playbackRate:1}},{key:"readyState",value:function(){return bf.remotePlayer.playerState===chrome.cast.media.PlayerState.IDLE||bf.remotePlayer.playerState===chrome.cast.media.PlayerState.BUFFERING?0:4}}])&&Rf(t.prototype,n),r&&Rf(t,r),o}(Fu.getComponent("Tech")),Uf=Mf.prototype;Uf.featuresVolumeControl=!0,Uf.featuresPlaybackRate=!1,Uf.movingMediaElementInDOM=!1,Uf.featuresFullscreenResize=!0,Uf.featuresTimeupdateEvents=!0,Uf.featuresProgressEvents=!1,Uf.featuresNativeTextTracks=!1,Uf.featuresNativeAudioTracks=!1,Uf.featuresNativeVideoTracks=!1,Fu.registerTech("chromecast",Mf);n(384);function Bf(e){return(Bf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ff(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Vf(e,t,n){return(Vf="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=$f(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Hf(e,t){return(Hf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$f(e);if(t){var i=$f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qf(this,n)}}function qf(e,t){return!t||"object"!==Bf(t)&&"function"!=typeof t?Wf(e):t}function Wf(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $f(e){return($f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Gf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hf(e,t)}(o,e);var t,n,r,i=zf(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).alwaysCollapsed=!1,t.isCollapsed=!1,t.isCollabsible=!0,t.onDevicesAvailable=t.onDevicesAvailable.bind(Wf(t)),t.onDevicesUnavailable=t.onDevicesUnavailable.bind(Wf(t)),bf.on("devicesAvailable",t.onDevicesAvailable),bf.on("devicesUnabailable",t.onDevicesUnavailable),t.player_.one("dispose",(function(){bf.off("devicesAvailable",t.onDevicesAvailable),bf.off("devicesUnabailable",t.onDevicesUnavailable)})),bf.hasAvailableDevices()||t.hide(),t}return t=o,(n=[{key:"onDevicesAvailable",value:function(){this.show()}},{key:"onDevicesUnavailable",value:function(){this.hide()}},{key:"buildCSSClass",value:function(){return"cv-chromecast-button"}},{key:"createEl",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Vf($f(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:'\n <span aria-hidden="true" class="vjs-icon-placeholder"></span>\n <google-cast-launcher></google-cast-launcher>\n '}),n)}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){Vf($f(o.prototype),"handleClick",this).call(this,null)}}])&&Ff(t.prototype,n),r&&Ff(t,r),o}(Fu.getComponent("Button"));function Yf(e){return(Yf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Kf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Xf(e,t){return(Xf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Qf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Zf(e);if(t){var i=Zf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Jf(this,n)}}function Jf(e,t){return!t||"object"!==Yf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Zf(e){return(Zf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Gf.prototype.controlText_="Chromecast",Fu.registerComponent("ChromecastButton",Gf);var eh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Xf(e,t)}(o,e);var t,n,r,i=Qf(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,bf?(e.ready((function(){return n.onReady()})),n):Jf(n)}return t=o,(n=[{key:"onReady",value:function(){var e,t=this,n=this.player.getChild("collapserator"),r=null===(e=null==n?void 0:n.children())||void 0===e?void 0:e.findIndex((function(e){return"CustomControlSpacer"===e.name()}));r&&-1!==r&&(n.addChild("ChromecastButton",{},r+1),this.onIsConnectedChanged=this.onIsConnectedChanged.bind(this),bf.on("isconnectedchanged",this.onIsConnectedChanged),this.player.one("dispose",(function(){bf.off("isconnectedchanged",t.onIsConnectedChanged)})),this.setTechTitle())}},{key:"setTechTitle",value:function(){var e=this.player.tech();"ChromecastTech"===e.name()&&e.setTitle(this.options.title)}},{key:"onIsConnectedChanged",value:function(){var e=this,t=this.player.currentTime(),n=this.player.paused();this.player.src(this.player.currentSources()),this.player.ready((function(){e.player.currentTime(t),n?e.player.pause():e.player.play(),e.setTechTitle()}))}}])&&Kf(t.prototype,n),r&&Kf(t,r),o}(Fu.getPlugin("plugin"));function th(e){return(th="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function nh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ih(e,t){return(ih=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function oh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sh(e);if(t){var i=sh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ah(this,n)}}function ah(e,t){return!t||"object"!==th(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function sh(e){return(sh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("chromecast",eh);var uh=Fu.getComponent("Menu"),lh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ih(e,t)}(o,e);var t,n,r,i=oh(o);function o(){return nh(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"handleBlur",value:function(e){var t=e.relatedTarget||document.activeElement;this.el().contains(t)||uh.prototype.handleBlur.call(this,e)}}])&&rh(t.prototype,n),r&&rh(t,r),o}(uh);function ch(e){return(ch="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function fh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function dh(e,t){return(dh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ph(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mh(e);if(t){var i=mh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yh(this,n)}}function yh(e,t){return!t||"object"!==ch(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mh(e){return(mh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("Menu",lh);var gh=Fu.getComponent("Component"),vh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dh(e,t)}(o,e);var t,n,r,i=ph(o);function o(){return fh(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"createMenu",value:function(){var e,t=new lh(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var n=Fu.dom.createEl("li",{className:"vjs-menu-title",innerHTML:(e=this.options_.title,"string"!=typeof e?e:e.replace(/./,(function(e){return e.toUpperCase()}))),tabIndex:-1});this.hideThreshold_+=1;var r=new gh(this.player_,{el:n});t.addItem(r)}if(this.items=this.createItems(),this.items)for(var i=0;i<this.items.length;i++)t.addItem(this.items[i]);return t}}])&&hh(t.prototype,n),r&&hh(t,r),o}(Fu.getComponent("MenuButton"));Fu.registerComponent("MenuButton",vh);n(385);function bh(e){return(bh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Th(e,t,n){return(Th="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=kh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sh(e,t){return(Sh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Eh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=kh(e);if(t){var i=kh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ch(this,n)}}function Ch(e,t){return!t||"object"!==bh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function kh(e){return(kh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sh(e,t)}(o,e);var t,n,r,i=Eh(o);function o(){return _h(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-time-wrapper ".concat(Th(kh(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Th(kh(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}}])&&wh(t.prototype,n),r&&wh(t,r),o}(Fu.getComponent("Component"));function Oh(e){return(Oh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ph(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Rh(e,t,n){return(Rh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=jh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ah(e,t){return(Ah=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ih(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jh(e);if(t){var i=jh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Lh(this,n)}}function Lh(e,t){return!t||"object"!==Oh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jh(e){return(jh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}xh.prototype.options_={children:["currentTimeDisplay","remainingTimeDisplay"]},Fu.registerComponent("TimeWrapper",xh);var Dh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ah(e,t)}(o,e);var t,n,r,i=Ih(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).playNext=e.nextVideoPlugin().getShouldPlayNext(),n.toggle(n.playNext),n}return t=o,(n=[{key:"handleToggle",value:function(){this.toggle(!this.playNext)}},{key:"toggle",value:function(e){e?this.toggleOn():this.toggleOff()}},{key:"toggleOn",value:function(){this.playNext=!0,Fu.dom.addClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext)}},{key:"toggleOff",value:function(){this.playNext=!1,Fu.dom.removeClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext)}},{key:"handleClick",value:function(e){e.stopImmediatePropagation()}},{key:"createEl",value:function(e,t,n){this.handlerBound||(this.handleToggle=this.handleToggle.bind(this),this.handlerBound=!0),this.toggleEl&&this.toggleEl.removeEventListener("click",this.handleToggle),this.toggleEl=Fu.dom.createEl("div",{className:"custom-toggle toggle-option float-right",innerHTML:'<span class="handle"></span></div>'}),this.toggleEl.addEventListener("click",this.handleToggle);var r=Rh(jh(o.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:'\n <span class="vjs-menu-item-text">autoplay</span>\n <span class="cv-toggle-container"></span>'},n);return r.children[1].appendChild(this.toggleEl),r}}])&&Ph(t.prototype,n),r&&Ph(t,r),o}(Fu.getComponent("MenuItem"));Fu.registerComponent("NextVideoMenuItem",Dh);n(386);function Nh(e){return(Nh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Mh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bh(e,t,n){return t&&Uh(e.prototype,t),n&&Uh(e,n),e}function Fh(e,t,n){return(Fh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Wh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Vh(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hh(e,t)}function Hh(e,t){return(Hh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Wh(e);if(t){var i=Wh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qh(this,n)}}function qh(e,t){return!t||"object"!==Nh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Wh(e){return(Wh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var $h=Fu.getComponent("MenuItem"),Gh=Fu.getComponent("NextVideoMenuItem"),Yh=function(e){Vh(n,e);var t=zh(n);function n(e,r){return Mh(this,n),t.call(this,e,r)}return Bh(n,[{key:"handleClick",value:function(e){var t=this;Fh(Wh(n.prototype),"handleClick",this).call(this,e),this.requestAnimationFrame((function(){t.options_.item.showCollapsibleMenu()}))}},{key:"createEl",value:function(e,t,r){if(!this.options_.item)return Fh(Wh(n.prototype),"createEl",this).call(this,e,t,r);var i=this.options_.item.getCollabsibleName(),o=this.options_.item.getCollabsibleValue(),a='\n <span class="vjs-menu-item-text">'.concat(i,"</span>\n <span>").concat(o,"</span>");return Fh(Wh(n.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:a},r)}}]),n}($h),Kh=Fu.getComponent("MenuButton"),Xh=function(e){Vh(n,e);var t=zh(n);function n(e,r){return Mh(this,n),t.call(this,e,r)}return Bh(n,[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Fh(Wh(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"buildCSSClass",value:function(){return"cv-cog-button ".concat(Fh(Wh(n.prototype),"buildCSSClass",this).call(this))}},{key:"pressButton",value:function(){this.update(),Kh.prototype.pressButton.apply(this)}},{key:"createItems",value:function(){var e=[];this.renderPlayNext&&e.push(new Gh(this.player_,this.options_));for(var t=0;t<this.options_.items.length;t++){var n=this.options_.items[t];n.isCollabsible&&(n.showInCollabsibleMenu()&&n.isCollapsed&&e.push(new Yh(this.player_,{item:n})))}return e}},{key:"update",value:function(){Fh(Wh(n.prototype),"update",this).call(this),this.player_.trigger("resizemenus")}},{key:"showPlayNext",value:function(){this.renderPlayNext=!0,this.update()}}]),n}(Kh);function Qh(e){return(Qh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Jh(e,t,n){return(Jh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ad(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Zh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ed(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function td(e,t,n){return t&&ed(e.prototype,t),n&&ed(e,n),e}function nd(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&rd(e,t)}function rd(e,t){return(rd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function id(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ad(e);if(t){var i=ad(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return od(this,n)}}function od(e,t){return!t||"object"!==Qh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ad(e){return(ad=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("cogButton",Xh);var sd=Fu.getComponent("MenuItem"),ud=Fu.getComponent("MenuButton"),ld=["small","medium","large"],cd=function(e){nd(n,e);var t=id(n);function n(e,r){return Zh(this,n),t.call(this,e,r)}return td(n,[{key:"handleClick",value:function(){this.player_.textTrackSettings.setSizeSetting(this.options_.value)}}]),n}(sd),fd=function(e){nd(n,e);var t=id(n);function n(e,r){var i;return Zh(this,n),(i=t.call(this,e,r)).alwaysCollapsed=!0,i.isCollapsed=!1,i.isCollabsible=!0,i.player_.ready((function(){i.update()})),i}return td(n,[{key:"createItems",value:function(){var e=this,t=this.player_.textTrackSettings;if(t){var n=t.getSizeSetting();return ld.map((function(t){return new cd(e.player_,{label:t,selectable:!0,multiSelectable:!1,selected:t===n,value:t})}))}}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Jh(ad(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"getCollabsibleName",value:function(){return"Subtitle Size"}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!1}},{key:"showCollapsibleMenu",value:function(){ud.prototype.handleClick.apply(this)}}]),n}(ud);Fu.registerComponent("SubtitleSizeButton",fd);n(387);var hd=n(112),dd=n.n(hd),pd=(n(388),n(390),n(142)),yd=n.n(pd),md=n(143),gd=n.n(md),vd=n(235),bd=n.n(vd),_d=n(236),wd=(n(392),null),Td=null;function Sd(){if(null===wd){if("undefined"==typeof document)return wd=0;var e=document.body,t=document.createElement("div");t.classList.add("simplebar-hide-scrollbar"),e.appendChild(t);var n=t.getBoundingClientRect().right;e.removeChild(t),wd=n}return wd}dd.a&&window.addEventListener("resize",(function(){Td!==window.devicePixelRatio&&(Td=window.devicePixelRatio,wd=null)}));var Ed=function(e){return Array.prototype.reduce.call(e,(function(e,t){var n=t.name.match(/data-simplebar-(.+)/);if(n){var r=n[1].replace(/\W+(.)/g,(function(e,t){return t.toUpperCase()}));switch(t.value){case"true":e[r]=!0;break;case"false":e[r]=!1;break;case void 0:e[r]=!0;break;default:e[r]=t.value}}return e}),{})};function Cd(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView:window}function kd(e){return e&&e.ownerDocument?e.ownerDocument:document}var xd=function(){function e(t,n){var r=this;this.onScroll=function(){var e=Cd(r.el);r.scrollXTicking||(e.requestAnimationFrame(r.scrollX),r.scrollXTicking=!0),r.scrollYTicking||(e.requestAnimationFrame(r.scrollY),r.scrollYTicking=!0)},this.scrollX=function(){r.axis.x.isOverflowing&&(r.showScrollbar("x"),r.positionScrollbar("x")),r.scrollXTicking=!1},this.scrollY=function(){r.axis.y.isOverflowing&&(r.showScrollbar("y"),r.positionScrollbar("y")),r.scrollYTicking=!1},this.onMouseEnter=function(){r.showScrollbar("x"),r.showScrollbar("y")},this.onMouseMove=function(e){r.mouseX=e.clientX,r.mouseY=e.clientY,(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseMoveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseMoveForAxis("y")},this.onMouseLeave=function(){r.onMouseMove.cancel(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseLeaveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseLeaveForAxis("y"),r.mouseX=-1,r.mouseY=-1},this.onWindowResize=function(){r.scrollbarWidth=r.getScrollbarWidth(),r.hideNativeScrollbar()},this.hideScrollbars=function(){r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.track.rect)||(r.axis.y.scrollbar.el.classList.remove(r.classNames.visible),r.axis.y.isVisible=!1),r.isWithinBounds(r.axis.x.track.rect)||(r.axis.x.scrollbar.el.classList.remove(r.classNames.visible),r.axis.x.isVisible=!1)},this.onPointerEvent=function(e){var t,n;r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&(t=r.isWithinBounds(r.axis.x.track.rect)),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&(n=r.isWithinBounds(r.axis.y.track.rect)),(t||n)&&(e.preventDefault(),e.stopPropagation(),"mousedown"===e.type&&(t&&(r.axis.x.scrollbar.rect=r.axis.x.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.x.scrollbar.rect)?r.onDragStart(e,"x"):r.onTrackClick(e,"x")),n&&(r.axis.y.scrollbar.rect=r.axis.y.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.scrollbar.rect)?r.onDragStart(e,"y"):r.onTrackClick(e,"y"))))},this.drag=function(t){var n=r.axis[r.draggedAxis].track,i=n.rect[r.axis[r.draggedAxis].sizeAttr],o=r.axis[r.draggedAxis].scrollbar,a=r.contentWrapperEl[r.axis[r.draggedAxis].scrollSizeAttr],s=parseInt(r.elStyles[r.axis[r.draggedAxis].sizeAttr],10);t.preventDefault(),t.stopPropagation();var u=(("y"===r.draggedAxis?t.pageY:t.pageX)-n.rect[r.axis[r.draggedAxis].offsetAttr]-r.axis[r.draggedAxis].dragOffset)/(i-o.size)*(a-s);"x"===r.draggedAxis&&(u=r.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?u-(i+o.size):u,u=r.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-u:u),r.contentWrapperEl[r.axis[r.draggedAxis].scrollOffsetAttr]=u},this.onEndDrag=function(e){var t=kd(r.el),n=Cd(r.el);e.preventDefault(),e.stopPropagation(),r.el.classList.remove(r.classNames.dragging),t.removeEventListener("mousemove",r.drag,!0),t.removeEventListener("mouseup",r.onEndDrag,!0),r.removePreventClickId=n.setTimeout((function(){t.removeEventListener("click",r.preventClick,!0),t.removeEventListener("dblclick",r.preventClick,!0),r.removePreventClickId=null}))},this.preventClick=function(e){e.preventDefault(),e.stopPropagation()},this.el=t,this.minScrollbarWidth=20,this.options=Object.assign({},e.defaultOptions,{},n),this.classNames=Object.assign({},e.defaultOptions.classNames,{},this.options.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}}},this.removePreventClickId=null,e.instances.has(this.el)||(this.recalculate=yd()(this.recalculate.bind(this),64),this.onMouseMove=yd()(this.onMouseMove.bind(this),64),this.hideScrollbars=gd()(this.hideScrollbars.bind(this),this.options.timeout),this.onWindowResize=gd()(this.onWindowResize.bind(this),64,{leading:!0}),e.getRtlHelpers=bd()(e.getRtlHelpers),this.init())}e.getRtlHelpers=function(){var t=document.createElement("div");t.innerHTML='<div class="hs-dummy-scrollbar-size"><div style="height: 200%; width: 200%; margin: 10px 0;"></div></div>';var n=t.firstElementChild;document.body.appendChild(n);var r=n.firstElementChild;n.scrollLeft=0;var i=e.getOffset(n),o=e.getOffset(r);n.scrollLeft=999;var a=e.getOffset(r);return{isRtlScrollingInverted:i.left!==o.left&&o.left-a.left!=0,isRtlScrollbarInverted:i.left!==o.left}},e.getOffset=function(e){var t=e.getBoundingClientRect(),n=kd(e),r=Cd(e);return{top:t.top+(r.pageYOffset||n.documentElement.scrollTop),left:t.left+(r.pageXOffset||n.documentElement.scrollLeft)}};var t=e.prototype;return t.init=function(){e.instances.set(this.el,this),dd.a&&(this.initDOM(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},t.initDOM=function(){var e=this;if(Array.prototype.filter.call(this.el.children,(function(t){return t.classList.contains(e.classNames.wrapper)})).length)this.wrapperEl=this.el.querySelector("."+this.classNames.wrapper),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector("."+this.classNames.contentWrapper),this.contentEl=this.options.contentNode||this.el.querySelector("."+this.classNames.contentEl),this.offsetEl=this.el.querySelector("."+this.classNames.offset),this.maskEl=this.el.querySelector("."+this.classNames.mask),this.placeholderEl=this.findChild(this.wrapperEl,"."+this.classNames.placeholder),this.heightAutoObserverWrapperEl=this.el.querySelector("."+this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl=this.el.querySelector("."+this.classNames.heightAutoObserverEl),this.axis.x.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.horizontal),this.axis.y.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.vertical);else{for(this.wrapperEl=document.createElement("div"),this.contentWrapperEl=document.createElement("div"),this.offsetEl=document.createElement("div"),this.maskEl=document.createElement("div"),this.contentEl=document.createElement("div"),this.placeholderEl=document.createElement("div"),this.heightAutoObserverWrapperEl=document.createElement("div"),this.heightAutoObserverEl=document.createElement("div"),this.wrapperEl.classList.add(this.classNames.wrapper),this.contentWrapperEl.classList.add(this.classNames.contentWrapper),this.offsetEl.classList.add(this.classNames.offset),this.maskEl.classList.add(this.classNames.mask),this.contentEl.classList.add(this.classNames.contentEl),this.placeholderEl.classList.add(this.classNames.placeholder),this.heightAutoObserverWrapperEl.classList.add(this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl.classList.add(this.classNames.heightAutoObserverEl);this.el.firstChild;)this.contentEl.appendChild(this.el.firstChild);this.contentWrapperEl.appendChild(this.contentEl),this.offsetEl.appendChild(this.contentWrapperEl),this.maskEl.appendChild(this.offsetEl),this.heightAutoObserverWrapperEl.appendChild(this.heightAutoObserverEl),this.wrapperEl.appendChild(this.heightAutoObserverWrapperEl),this.wrapperEl.appendChild(this.maskEl),this.wrapperEl.appendChild(this.placeholderEl),this.el.appendChild(this.wrapperEl)}if(!this.axis.x.track.el||!this.axis.y.track.el){var t=document.createElement("div"),n=document.createElement("div");t.classList.add(this.classNames.track),n.classList.add(this.classNames.scrollbar),t.appendChild(n),this.axis.x.track.el=t.cloneNode(!0),this.axis.x.track.el.classList.add(this.classNames.horizontal),this.axis.y.track.el=t.cloneNode(!0),this.axis.y.track.el.classList.add(this.classNames.vertical),this.el.appendChild(this.axis.x.track.el),this.el.appendChild(this.axis.y.track.el)}this.axis.x.scrollbar.el=this.axis.x.track.el.querySelector("."+this.classNames.scrollbar),this.axis.y.scrollbar.el=this.axis.y.track.el.querySelector("."+this.classNames.scrollbar),this.options.autoHide||(this.axis.x.scrollbar.el.classList.add(this.classNames.visible),this.axis.y.scrollbar.el.classList.add(this.classNames.visible)),this.el.setAttribute("data-simplebar","init")},t.initListeners=function(){var e=this,t=Cd(this.el);this.options.autoHide&&this.el.addEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach((function(t){e.el.addEventListener(t,e.onPointerEvent,!0)})),["touchstart","touchend","touchmove"].forEach((function(t){e.el.addEventListener(t,e.onPointerEvent,{capture:!0,passive:!0})})),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl.addEventListener("scroll",this.onScroll),t.addEventListener("resize",this.onWindowResize);var n=!1,r=t.ResizeObserver||_d.a;this.resizeObserver=new r((function(){n&&e.recalculate()})),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),t.requestAnimationFrame((function(){n=!0})),this.mutationObserver=new t.MutationObserver(this.recalculate),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})},t.recalculate=function(){var e=Cd(this.el);this.elStyles=e.getComputedStyle(this.el),this.isRtl="rtl"===this.elStyles.direction;var t=this.heightAutoObserverEl.offsetHeight<=1,n=this.heightAutoObserverEl.offsetWidth<=1,r=this.contentEl.offsetWidth,i=this.contentWrapperEl.offsetWidth,o=this.elStyles.overflowX,a=this.elStyles.overflowY;this.contentEl.style.padding=this.elStyles.paddingTop+" "+this.elStyles.paddingRight+" "+this.elStyles.paddingBottom+" "+this.elStyles.paddingLeft,this.wrapperEl.style.margin="-"+this.elStyles.paddingTop+" -"+this.elStyles.paddingRight+" -"+this.elStyles.paddingBottom+" -"+this.elStyles.paddingLeft;var s=this.contentEl.scrollHeight,u=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=t?"auto":"100%",this.placeholderEl.style.width=n?r+"px":"auto",this.placeholderEl.style.height=s+"px";var l=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=u>r,this.axis.y.isOverflowing=s>l,this.axis.x.isOverflowing="hidden"!==o&&this.axis.x.isOverflowing,this.axis.y.isOverflowing="hidden"!==a&&this.axis.y.isOverflowing,this.axis.x.forceVisible="x"===this.options.forceVisible||!0===this.options.forceVisible,this.axis.y.forceVisible="y"===this.options.forceVisible||!0===this.options.forceVisible,this.hideNativeScrollbar();var c=this.axis.x.isOverflowing?this.scrollbarWidth:0,f=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&u>i-f,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&s>l-c,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el.style.width=this.axis.x.scrollbar.size+"px",this.axis.y.scrollbar.el.style.height=this.axis.y.scrollbar.size+"px",this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")},t.getScrollbarSize=function(e){if(void 0===e&&(e="y"),!this.axis[e].isOverflowing)return 0;var t,n=this.contentEl[this.axis[e].scrollSizeAttr],r=this.axis[e].track.el[this.axis[e].offsetSizeAttr],i=r/n;return t=Math.max(~~(i*r),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(t=Math.min(t,this.options.scrollbarMaxSize)),t},t.positionScrollbar=function(t){if(void 0===t&&(t="y"),this.axis[t].isOverflowing){var n=this.contentWrapperEl[this.axis[t].scrollSizeAttr],r=this.axis[t].track.el[this.axis[t].offsetSizeAttr],i=parseInt(this.elStyles[this.axis[t].sizeAttr],10),o=this.axis[t].scrollbar,a=this.contentWrapperEl[this.axis[t].scrollOffsetAttr],s=(a="x"===t&&this.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-a:a)/(n-i),u=~~((r-o.size)*s);u="x"===t&&this.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?u+(r-o.size):u,o.el.style.transform="x"===t?"translate3d("+u+"px, 0, 0)":"translate3d(0, "+u+"px, 0)"}},t.toggleTrackVisibility=function(e){void 0===e&&(e="y");var t=this.axis[e].track.el,n=this.axis[e].scrollbar.el;this.axis[e].isOverflowing||this.axis[e].forceVisible?(t.style.visibility="visible",this.contentWrapperEl.style[this.axis[e].overflowAttr]="scroll"):(t.style.visibility="hidden",this.contentWrapperEl.style[this.axis[e].overflowAttr]="hidden"),this.axis[e].isOverflowing?n.style.display="block":n.style.display="none"},t.hideNativeScrollbar=function(){this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-"+this.scrollbarWidth+"px":0,this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-"+this.scrollbarWidth+"px":0},t.onMouseMoveForAxis=function(e){void 0===e&&(e="y"),this.axis[e].track.rect=this.axis[e].track.el.getBoundingClientRect(),this.axis[e].scrollbar.rect=this.axis[e].scrollbar.el.getBoundingClientRect(),this.isWithinBounds(this.axis[e].scrollbar.rect)?this.axis[e].scrollbar.el.classList.add(this.classNames.hover):this.axis[e].scrollbar.el.classList.remove(this.classNames.hover),this.isWithinBounds(this.axis[e].track.rect)?(this.showScrollbar(e),this.axis[e].track.el.classList.add(this.classNames.hover)):this.axis[e].track.el.classList.remove(this.classNames.hover)},t.onMouseLeaveForAxis=function(e){void 0===e&&(e="y"),this.axis[e].track.el.classList.remove(this.classNames.hover),this.axis[e].scrollbar.el.classList.remove(this.classNames.hover)},t.showScrollbar=function(e){void 0===e&&(e="y");var t=this.axis[e].scrollbar.el;this.axis[e].isVisible||(t.classList.add(this.classNames.visible),this.axis[e].isVisible=!0),this.options.autoHide&&this.hideScrollbars()},t.onDragStart=function(e,t){void 0===t&&(t="y");var n=kd(this.el),r=Cd(this.el),i=this.axis[t].scrollbar,o="y"===t?e.pageY:e.pageX;this.axis[t].dragOffset=o-i.rect[this.axis[t].offsetAttr],this.draggedAxis=t,this.el.classList.add(this.classNames.dragging),n.addEventListener("mousemove",this.drag,!0),n.addEventListener("mouseup",this.onEndDrag,!0),null===this.removePreventClickId?(n.addEventListener("click",this.preventClick,!0),n.addEventListener("dblclick",this.preventClick,!0)):(r.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},t.onTrackClick=function(e,t){var n=this;if(void 0===t&&(t="y"),this.options.clickOnTrack){var r=Cd(this.el);this.axis[t].scrollbar.rect=this.axis[t].scrollbar.el.getBoundingClientRect();var i=this.axis[t].scrollbar.rect[this.axis[t].offsetAttr],o=parseInt(this.elStyles[this.axis[t].sizeAttr],10),a=this.contentWrapperEl[this.axis[t].scrollOffsetAttr],s=("y"===t?this.mouseY-i:this.mouseX-i)<0?-1:1,u=-1===s?a-o:a+o;!function e(){var i,o;-1===s?a>u&&(a-=n.options.clickOnTrackSpeed,n.contentWrapperEl.scrollTo(((i={})[n.axis[t].offsetAttr]=a,i)),r.requestAnimationFrame(e)):a<u&&(a+=n.options.clickOnTrackSpeed,n.contentWrapperEl.scrollTo(((o={})[n.axis[t].offsetAttr]=a,o)),r.requestAnimationFrame(e))}()}},t.getContentElement=function(){return this.contentEl},t.getScrollElement=function(){return this.contentWrapperEl},t.getScrollbarWidth=function(){try{return"none"===getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:Sd()}catch(e){return Sd()}},t.removeListeners=function(){var e=this,t=Cd(this.el);this.options.autoHide&&this.el.removeEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach((function(t){e.el.removeEventListener(t,e.onPointerEvent,!0)})),["touchstart","touchend","touchmove"].forEach((function(t){e.el.removeEventListener(t,e.onPointerEvent,{capture:!0,passive:!0})})),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),t.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.recalculate.cancel(),this.onMouseMove.cancel(),this.hideScrollbars.cancel(),this.onWindowResize.cancel()},t.unMount=function(){this.removeListeners(),e.instances.delete(this.el)},t.isWithinBounds=function(e){return this.mouseX>=e.left&&this.mouseX<=e.left+e.width&&this.mouseY>=e.top&&this.mouseY<=e.top+e.height},t.findChild=function(e,t){var n=e.matches||e.webkitMatchesSelector||e.mozMatchesSelector||e.msMatchesSelector;return Array.prototype.filter.call(e.children,(function(e){return n.call(e,t)}))[0]},e}();xd.defaultOptions={autoHide:!0,forceVisible:!1,clickOnTrack:!0,clickOnTrackSpeed:40,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging"},scrollbarMinSize:25,scrollbarMaxSize:0,timeout:1e3},xd.instances=new WeakMap,xd.initDOMLoadedElements=function(){document.removeEventListener("DOMContentLoaded",this.initDOMLoadedElements),window.removeEventListener("load",this.initDOMLoadedElements),Array.prototype.forEach.call(document.querySelectorAll("[data-simplebar]"),(function(e){"init"===e.getAttribute("data-simplebar")||xd.instances.has(e)||new xd(e,Ed(e.attributes))}))},xd.removeObserver=function(){this.globalObserver.disconnect()},xd.initHtmlApi=function(){this.initDOMLoadedElements=this.initDOMLoadedElements.bind(this),"undefined"!=typeof MutationObserver&&(this.globalObserver=new MutationObserver(xd.handleMutations),this.globalObserver.observe(document,{childList:!0,subtree:!0})),"complete"===document.readyState||"loading"!==document.readyState&&!document.documentElement.doScroll?window.setTimeout(this.initDOMLoadedElements):(document.addEventListener("DOMContentLoaded",this.initDOMLoadedElements),window.addEventListener("load",this.initDOMLoadedElements))},xd.handleMutations=function(e){e.forEach((function(e){Array.prototype.forEach.call(e.addedNodes,(function(e){1===e.nodeType&&(e.hasAttribute("data-simplebar")?!xd.instances.has(e)&&new xd(e,Ed(e.attributes)):Array.prototype.forEach.call(e.querySelectorAll("[data-simplebar]"),(function(e){"init"===e.getAttribute("data-simplebar")||xd.instances.has(e)||new xd(e,Ed(e.attributes))})))})),Array.prototype.forEach.call(e.removedNodes,(function(e){1===e.nodeType&&(e.hasAttribute('[data-simplebar="init"]')?xd.instances.has(e)&&xd.instances.get(e).unMount():Array.prototype.forEach.call(e.querySelectorAll('[data-simplebar="init"]'),(function(e){xd.instances.has(e)&&xd.instances.get(e).unMount()})))}))}))},xd.getOptions=Ed,dd.a&&xd.initHtmlApi();var Od=xd,Pd={initMenuScrollbar:function(e){Pd.unMountScrollbar(e);var t=Pd.getMenuEl(e);t&&(e.simpleBar_=new Od(t,{autoHide:!1}),e.one("dispose",(function(){return Pd.unMountScrollbar(e)})))},unMountScrollbar:function(e){e.simpleBar_&&e.simpleBar_.unMount()},getMenuEl:function(e){return e.el().querySelector(".vjs-menu-content")}};function Rd(e,t,n,r){e.kind===t&&(n&&e.label!==n||(e.loaded_?r(e):e.one("loadeddata",(function(){r(e)}))))}var Ad=function(e,t,n,r){var i=function(e){Rd(e.track,t,n,r)},o=e.textTracks(),a=function(e,t,n){if(e.length)for(var r=e.length-1;r>=0;r--){var i=e[r];if(i.kind===t){if(n&&i.label!==n)continue;return i}}}(o,t,n);a?Rd(a,t,n,r):(o.addEventListener("addtrack",i),e.on("dispose",(function(){o.removeEventListener("addtrack",i)})))},Id=function(e){if(!e)return null;for(var t=e.textTracks(),n=0;n<t.length;n++){var r=t[n];if("showing"===r.mode)return r}return null};function Ld(e){return(Ld="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function jd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dd(e,t){return(Dd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Nd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ud(e);if(t){var i=Ud(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Md(this,n)}}function Md(e,t){return!t||"object"!==Ld(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ud(e){return(Ud=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Bd=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Dd(e,t)}(o,e);var t,n,r,i=Nd(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"update",value:function(e,t){var n=this;if(null==e?void 0:e.length){var r=[],i=0;e.forEach((function(e){var o=n.options_.label.substr(i,e);o&&r.push(o),r.push('<span class="cv-highlight">'),r.push(n.options_.label.substr(e,t)),r.push("</span>"),i=e+t})),r.push(this.options_.label.substring(i,this.options_.label.length)),this.el().innerHTML='<span class="vjs-menu-item-text">'.concat(r.join(""),"</span>")}else this.el().innerHTML='<span class="vjs-menu-item-text">'.concat(this.options_.label,"</span>")}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.player_.currentTime(this.options_.cue.startTime)}}])&&jd(t.prototype,n),r&&jd(t,r),o}(Fu.getComponent("MenuItem"));function Fd(e){return(Fd="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Vd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Hd(e,t,n){return(Hd="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Gd(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function zd(e,t){return(zd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function qd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Gd(e);if(t){var i=Gd(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Wd(this,n)}}function Wd(e,t){return!t||"object"!==Fd(t)&&"function"!=typeof t?$d(e):t}function $d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Gd(e){return(Gd=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Yd=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zd(e,t)}(o,e);var t,n,r,i=qd(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).onChange=function(e,t,n){var r,i=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:window,a=function(){o.clearTimeout(r),r=null},s=function(){for(var a=arguments.length,s=new Array(a),u=0;u<a;u++)s[u]=arguments[u];var l=function(){r=null,l=null,n||e.apply(this,s)};!r&&n&&e.apply(i,s),o.clearTimeout(r),r=o.setTimeout(l,t)};return s.cancel=a,s}(n.onChange,100,!1,$d(n)),n.bindEventListeners(),n}return t=o,(n=[{key:"createEl",value:function(){return Hd(Gd(o.prototype),"createEl",this).call(this,"li",{innerHTML:'\n <div class="cv-subtitle-search-input">\n <span class="cv-search-icon">\n <svg viewBox="0 0 24 24">\n <path d="M15.803 14.306l3.917 3.954a1 1 0 0 1-.007 1.417l-.018.018-.018.018a.997.997 0 0 1-1.41 0l-3.918-3.953-.3.214c-1.14.713-2.323 1.07-3.549 1.07-1.796 0-3.328-.642-4.597-1.925C4.634 13.836 4 12.296 4 10.5c0-1.796.634-3.328 1.903-4.597C7.172 4.634 8.704 4 10.5 4c1.796 0 3.329.634 4.597 1.903 1.27 1.269 1.904 2.801 1.904 4.597a6.447 6.447 0 0 1-1.027 3.507l-.17.3zM10.5 5.368c-1.425 0-2.637.5-3.635 1.497-.998.998-1.497 2.21-1.497 3.635 0 1.426.5 2.637 1.497 3.635.998.998 2.21 1.497 3.635 1.497 1.426 0 2.637-.499 3.635-1.497 1.027-1.026 1.54-2.238 1.54-3.635 0-1.397-.513-2.608-1.54-3.635-.998-.998-2.21-1.497-3.635-1.497z"/>\n </svg>\n </span><input placeholder="Search" type="text" autocomplete="off" spellcheck="false" aria-label="Search" />\n </div>\n '})}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.$("input").focus()}},{key:"handleKeyDown",value:function(){}},{key:"bindEventListeners",value:function(){var e=this,t=this.$("input");this.onChange=this.onChange.bind(this),t.addEventListener("keyup",this.onChange),t.addEventListener("blur",(function(t){e.options_.menuButton.menu.handleBlur(t)}))}},{key:"onChange",value:function(e){var t=e.target;this.options_.menuButton.search(t.value)}}])&&Vd(t.prototype,n),r&&Vd(t,r),o}(Fu.getComponent("MenuItem"));n(393);function Kd(e){return(Kd="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Xd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Jd(e,t,n){return t&&Qd(e.prototype,t),n&&Qd(e,n),e}function Zd(e,t,n){return(Zd="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=op(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ep(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tp(e,t)}function tp(e,t){return(tp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function np(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=op(e);if(t){var i=op(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return rp(this,n)}}function rp(e,t){return!t||"object"!==Kd(t)&&"function"!=typeof t?ip(e):t}function ip(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function op(e){return(op=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ap=Fu.getComponent("MenuItem"),sp=Fu.getComponent("MenuButton"),up=function(e){ep(n,e);var t=np(n);function n(){return Xd(this,n),t.apply(this,arguments)}return Jd(n,[{key:"createEl",value:function(e,t,r){return Zd(op(n.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:"vjs-menu-item cv-no-results"}),r)}}]),n}(ap),lp=function(e){ep(n,e);var t=np(n);function n(e,r){var i;return Xd(this,n),(i=t.call(this,e,r)).alwaysCollapsed=!0,i.isCollapsed=!1,i.isCollabsible=!0,i.update=i.update.bind(ip(i)),i.player_.textTracks().addEventListener("selectedlanguagechange",i.update),i}return Jd(n,[{key:"createItems",value:function(){var e,t=Id(this.player_);if(null===(e=null==t?void 0:t.cues)||void 0===e?void 0:e.length){for(var n=[new Yd(this.player_,{menuButton:this})],r=0;r<t.cues.length;r++){var i=t.cues[r];n.push(new Bd(this.player_,{cue:i,label:i.text,selected:!1,multiSelectable:!1}))}var o=new up(this.player_,{label:"No matching results",selected:!1,selectable:!1,multiSelectable:!1});return o.hide(),n.push(o),n}}},{key:"search",value:function(e){var t;e=e.trim();var n=Id(this.player_);if(null===(t=null==n?void 0:n.cues)||void 0===t?void 0:t.length){var r=this.findMatches(e,n);this.toggleItemVisibility(e,r),this.toggleNoResults(e,r)}}},{key:"findMatches",value:function(e,t){var n={};if(!e)return n;for(var r=new RegExp(e,"gi"),i=0;i<t.cues.length;i++){for(var o=t.cues[i].text,a=[],s=void 0;s=r.exec(o);)a.push(s.index);a.length&&(n[i]=a)}return n}},{key:"toggleItemVisibility",value:function(e,t){this.menu.children_.slice(1,this.menu.children_.length-1).forEach((function(n,r){!e||t[r]?n.show():n.hide(),n.update(t[r],e.length)}))}},{key:"toggleNoResults",value:function(e,t){var n=this.menu.children_[this.menu.children_.length-1];!e||Object.keys(t).length?n.hide():n.show()}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-big cv-subtitle-search-button ".concat(Zd(op(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"update",value:function(){Zd(op(n.prototype),"update",this).call(this),Pd.initMenuScrollbar(this),this.player_.trigger("resizemenus")}},{key:"getCollabsibleName",value:function(){return"Subtitle Size"}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!1}},{key:"showCollapsibleMenu",value:function(){sp.prototype.handleClick.apply(this)}}]),n}(sp);Fu.registerComponent("subtitleSearchButton",lp);n(394),n(395),n(396);function cp(e){return(cp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function fp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hp(e,t,n){return(hp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=gp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function dp(e,t){return(dp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function pp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=gp(e);if(t){var i=gp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yp(this,n)}}function yp(e,t){return!t||"object"!==cp(t)&&"function"!=typeof t?mp(e):t}function mp(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gp(e){return(gp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var vp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dp(e,t)}(o,e);var t,n,r,i=pp(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addChild("cogButton",{items:n.children_},n.children_.length-1),n.update=n.update.bind(mp(n)),n.player_.on("cv-updatecog",n.update),n.player_.on("playerresize",n.update),n.player_.on("dispose",(function(){n.player_.off("cv-updatecog",n.update),n.player_.off("playerresize",n.update)})),n}return t=o,(n=[{key:"togglehidden",value:function(e){for(var t=0;t<this.children_.length;t++){var n=this.children_[t];n.isCollabsible&&(n.alwaysCollapsed||e?(n.isCollapsed=!0,n.addClass("cv-collapsed")):(n.isCollapsed=!1,n.removeClass("cv-collapsed")))}this.getChild("cogButton").update()}},{key:"update",value:function(){var e=this.player_.el().getBoundingClientRect();0!==e.width&&this.togglehidden(e.width<600)}},{key:"buildCSSClass",value:function(){return"cv-collapsorator ".concat(hp(gp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return hp(gp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}}])&&fp(t.prototype,n),r&&fp(t,r),o}(Fu.getComponent("Component"));vp.prototype.options_={children:["playToggle","volumePanel","customControlSpacer","playbackRateMenuButton","chaptersButton","qualityButton","subsCapsButton","whiteboardModeButton","subtitleSizeButton","subtitleSearchButton","fullscreenToggle"]},Fu.registerComponent("collapserator",vp);n(397);function bp(e){return(bp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Tp(e,t,n){return(Tp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=kp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sp(e,t){return(Sp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ep(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=kp(e);if(t){var i=kp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Cp(this,n)}}function Cp(e,t){return!t||"object"!==bp(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function kp(e){return(kp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sp(e,t)}(o,e);var t,n,r,i=Ep(o);function o(){return _p(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-items ".concat(Tp(kp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Tp(kp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(){this.children_.forEach((function(e){e.update()}))}}])&&wp(t.prototype,n),r&&wp(t,r),o}(Fu.getComponent("Component"));function Op(e){return(Op="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Pp(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ap(e,t,n){return(Ap="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Dp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ip(e,t){return(Ip=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Lp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Dp(e);if(t){var i=Dp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jp(this,n)}}function jp(e,t){return!t||"object"!==Op(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Dp(e){return(Dp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Np=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ip(e,t)}(o,e);var t,n,r,i=Lp(o);function o(){return Pp(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-load-progress ".concat(Ap(Dp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Ap(Dp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(e){this.el_.style.width=100*e+"%"}}])&&Rp(t.prototype,n),r&&Rp(t,r),o}(Fu.getComponent("Component"));function Mp(e){return(Mp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Up(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Fp(e,t,n){return(Fp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=qp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Vp(e,t){return(Vp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Hp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=qp(e);if(t){var i=qp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return zp(this,n)}}function zp(e,t){return!t||"object"!==Mp(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function qp(e){return(qp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Wp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Vp(e,t)}(o,e);var t,n,r,i=Hp(o);function o(){return Up(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-play-progress ".concat(Fp(qp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Fp(qp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(e){e>0&&e<1?this.addClass("cv-current"):this.removeClass("cv-current"),this.el_.style.width=100*e+"%"}}])&&Bp(t.prototype,n),r&&Bp(t,r),o}(Fu.getComponent("Component"));function $p(e){return($p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Gp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Yp(e,t,n){return(Yp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Jp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Kp(e,t){return(Kp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Jp(e);if(t){var i=Jp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qp(this,n)}}function Qp(e,t){return!t||"object"!==$p(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jp(e){return(Jp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Zp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Kp(e,t)}(o,e);var t,n,r,i=Xp(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).playProgress=new Wp(n.player_),n.addChild(n.playProgress),n.loadProgress=new Np(n.player_),n.addChild(n.loadProgress),n.update(),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-item ".concat(Yp(Jp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Yp(Jp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"getCurrentTime",value:function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()}},{key:"update",value:function(){var e=this.player_.duration(),t=this.options_.endTime-this.options_.startTime;if(e!==this.duration_){var n=t/e;this.el_.style.width=100*n+"%";var r=this.options_.startTime/e;this.el_.style.left=100*r+"%",this.duration_=e}var i=this.getCurrentTime();i<this.options_.startTime?this.playProgress.update(0):i>this.options_.endTime?this.playProgress.update(1):this.playProgress.update((i-this.options_.startTime)/t);var o=this.player_.bufferedEnd();o<this.options_.startTime?this.loadProgress.update(0):o>this.options_.endTime?this.loadProgress.update(1):this.loadProgress.update((o-this.options_.startTime)/t)}}])&&Gp(t.prototype,n),r&&Gp(t,r),o}(Fu.getComponent("Component"));function ey(e){return(ey="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ty(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ny(e,t,n){return(ny="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=sy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ry(e,t){return(ry=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function iy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sy(e);if(t){var i=sy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oy(this,n)}}function oy(e,t){return!t||"object"!==ey(t)&&"function"!=typeof t?ay(e):t}function ay(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sy(e){return(sy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var uy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ry(e,t)}(o,e);var t,n,r,i=iy(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).onDurationChange=n.onDurationChange.bind(ay(n)),n.createChapterItems=n.createChapterItems.bind(ay(n)),Ad(n.player_,"chapters",null,n.createChapterItems),n.player_.on("durationchange",n.onDurationChange),n.player_.on("dispose",(function(){n.player_.off("durationchange",n.onDurationChange)})),n}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("div",{className:"vjs-progress-holder cv-chapter-seek-bar"},{"aria-label":this.localize("Progress Bar")})}},{key:"onDurationChange",value:function(){this.createChapterItems(),this.update()}},{key:"update",value:function(){var e=ny(sy(o.prototype),"update",this).call(this);return this.chapterBarItems&&this.chapterBarItems.update(),e}},{key:"createChapterItems",value:function(e){e&&(this.track_=e);var t=new xp(this.player_);if(this.track_&&!this.options_.ignoreChapters)for(var n=0;n<this.track_.cues.length;n++){var r=this.track_.cues[n],i=r.startTime,o=r.endTime,a=this.player_.duration();a&&(n===this.track_.cues.length-1&&r.endTime<this.player_.duration()&&(o=this.player_.duration()),o>a&&(o=a));var s=new Zp(this.player_,{startTime:i,endTime:o});if(t.addChild(s),a&&o===a)break}else t.addChild(new Zp(this.player_,{startTime:0,endTime:this.player_.duration()}));this.chapterBarItems&&this.removeChild(this.chapterBarItems),this.chapterBarItems=t,this.addChild(this.chapterBarItems)}}])&&ty(t.prototype,n),r&&ty(t,r),o}(Fu.getComponent("SeekBar"));uy.prototype.options_={children:["playProgressBar"],barName:"playProgressBar"},Fu.browser.IS_IOS||Fu.browser.IS_ANDROID||uy.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Fu.registerComponent("ChapterSeekBar",uy);n(398);function ly(e){return(ly="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function cy(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hy(e,t,n){return(hy="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=my(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function dy(e,t){return(dy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function py(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=my(e);if(t){var i=my(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yy(this,n)}}function yy(e,t){return!t||"object"!==ly(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function my(e){return(my=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var gy=Fu.getComponent("ProgressControl"),vy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dy(e,t)}(o,e);var t,n,r,i=py(o);function o(){var e;return cy(this,o),(e=i.apply(this,arguments)).seekBarName_="seekBar",e}return t=o,(n=[{key:"setSeekBarName",value:function(e){this.seekBarName_=e}},{key:"getChild",value:function(e){return(null==e?void 0:e.toLowerCase())==="seekBar".toLowerCase()&&(e=this.seekBarName_),hy(my(o.prototype),"getChild",this).call(this,e)}}])&&fy(t.prototype,n),r&&fy(t,r),o}(gy);function by(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e;e=e<0?0:e;var n=Math.floor(e%60),r=Math.floor(e/60%60),i=Math.floor(e/3600),o=Math.floor(t/60%60),a=Math.floor(t/3600);return(isNaN(e)||e===1/0)&&(i=r=n="-"),(i=i>0||a>0?i+":":"")+(r=((i||o>=10)&&r<10?"0"+r:r)+":")+(n=n<10?"0"+n:n)}vy.prototype.options_={children:[]},Fu.registerComponent("ProgressControl",vy);n(399);function _y(e){return(_y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function wy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ty(e,t,n){return(Ty="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ky(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sy(e,t){return(Sy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ey(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ky(e);if(t){var i=ky(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Cy(this,n)}}function Cy(e,t){return!t||"object"!==_y(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ky(e){return(ky=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sy(e,t)}(o,e);var t,n,r,i=Ey(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),Ad(n.player_,"chapters",!1,(function(e){n.track_=e})),n}return t=o,(n=[{key:"createEl",value:function(){var e=Ty(ky(o.prototype),"createEl",this).call(this);return this.chapter_=Fu.dom.createEl("div"),e.appendChild(this.chapter_),this.time_=Fu.dom.createEl("div"),e.appendChild(this.time_),e}},{key:"updateTime",value:function(e){var t=this.player_.duration();if(Fu.dom.textContent(this.time_,by(e,t)),this.track_){for(var n=0;n<this.track_.cues.length;n++){var r=this.track_.cues[n];if(r.startTime<=e&&r.endTime>=e)return void Fu.dom.textContent(this.chapter_,r.text)}Fu.dom.textContent(this.chapter_,"")}}}])&&wy(t.prototype,n),r&&wy(t,r),o}(Fu.getComponent("TimeTooltip"));Fu.registerComponent("TimeTooltip",xy);n(400);function Oy(e){return(Oy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Py(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ry(e,t,n){return(Ry="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=jy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ay(e,t){return(Ay=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Iy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jy(e);if(t){var i=jy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ly(this,n)}}function Ly(e,t){return!t||"object"!==Oy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jy(e){return(jy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Dy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ay(e,t)}(o,e);var t,n,r,i=Iy(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"setTrack",value:function(e){this.track_=e}},{key:"createEl",value:function(){var e=Ry(jy(o.prototype),"createEl",this).call(this,"div",{className:"cv-thumbnail-display"});return this.img_=Fu.dom.createEl("img"),e.appendChild(this.img_),e}},{key:"enable",value:function(){this.addClass("cv-thumbnail-display-enabled")}},{key:"disable",value:function(){this.removeClass("cv-thumbnail-display-enabled")}},{key:"parseImageLink",value:function(e){var t=e.indexOf("#");if(-1===t)return{src:e,w:0,h:0,x:0,y:0};var n=e.substr(0,t),r=e.substr(t+1);if("xywh="!==r.substr(0,5))return{src:e,w:0,h:0,x:0,y:0};var i=this.getScale(),o=r.substr(5).split(",");return{src:n,w:parseInt(o[2])*i,h:parseInt(o[3])*i,x:parseInt(o[0])*i,y:parseInt(o[1])*i}}},{key:"getScale",value:function(){var e=this.options_.scaleFactor,t=this.player_.whiteboardModePlugin().side;return this.player_.isFullscreen()&&"bottom"!==t&&(e*=2),e}},{key:"update",value:function(e){var t,n;if(null===(n=null===(t=this.track_)||void 0===t?void 0:t.cues)||void 0===n?void 0:n.length){for(var r,i=e,o=0;o<this.track_.cues.length;){var a=this.track_.cues[o];if(a.startTime<=i&&a.endTime>=i){r=this.parseImageLink(a.text);break}o++}if(null==r?void 0:r.src){this.enable();var s=r,u=s.src,l=s.w,c=s.h,f=s.x,h=s.y,d=this.getScale();this.img_.src=u,this.img_.style.left=-f+"px",this.img_.style.top=-h+"px",this.img_.style.transformOrigin="0 0",this.img_.style.transform="scale(".concat(d,")"),this.el_.style.width=l+"px",this.el_.style.height=c+"px"}else this.disable()}}}])&&Py(t.prototype,n),r&&Py(t,r),o}(Fu.getComponent("Component"));Dy.prototype.options_={scaleFactor:1},Fu.registerComponent("ThumbnailDisplay",Dy);n(401);function Ny(e){return(Ny="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function My(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Uy(e,t){return(Uy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function By(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hy(e);if(t){var i=Hy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fy(this,n)}}function Fy(e,t){return!t||"object"!==Ny(t)&&"function"!=typeof t?Vy(e):t}function Vy(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Hy(e){return(Hy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Uy(e,t)}(o,e);var t,n,r,i=By(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),Ad(n.player_,"metadata","thumbnails",(function(e){n.getChild("ThumbnailDisplay").setTrack(e)})),n.update=n.update.bind(Vy(n)),n.player_.on("durationchange",n.update),n.player_.one("dispose",(function(){n.player_.off("durationchange",n.update)})),n}return t=o,(n=[{key:"update",value:function(e,t){var n=this;this.requestAnimationFrame((function(){var r=t*n.player_.duration();n.getChild("ThumbnailDisplay").update(r),n.getChild("TimeTooltip").updateTime(r);var i=n.el_.getBoundingClientRect();n.el_.style.marginLeft=-i.width/2+"px";var o=e.width*t;o<i.width/2?n.el_.style.left=i.width/2+"px":o>e.width-i.width/2?n.el_.style.left=e.width-i.width/2+"px":n.el_.style.left=e.width*t+"px"}))}}])&&My(t.prototype,n),r&&My(t,r),o}(Fu.getComponent("MouseTimeDisplay"));zy.prototype.options_={children:["ThumbnailDisplay","TimeTooltip"]},Fu.registerComponent("MouseTimeDisplay",zy);n(402);function qy(e){return(qy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Wy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $y(e,t,n){return($y="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Xy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Gy(e,t){return(Gy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Yy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xy(e);if(t){var i=Xy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ky(this,n)}}function Ky(e,t){return!t||"object"!==qy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xy(e){return(Xy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qy=Fu.getComponent("ChaptersTrackMenuItem"),Jy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Gy(e,t)}(o,e);var t,n,r,i=Yy(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).nonIconControl=!1,n.thumbnailDisplay=new Dy(n.player_,{scaleFactor:.5}),n.el().insertBefore(n.thumbnailDisplay.el(),n.el().firstChild),Ad(n.player_,"metadata","thumbnails",(function(e){n.addClass("cv-has-thumbnails"),n.thumbnailDisplay.setTrack(e),n.thumbnailDisplay.update(n.options_.cue.startTime)})),n}return t=o,(n=[{key:"update",value:function(){this.player_&&Qy.prototype.update.call(this)}},{key:"buildCSSClass",value:function(){return"vjs-menu-item cv-chapter-menu-item"}},{key:"createEl",value:function(e,t,n){return this.nonIconControl=!0,$y(Xy(o.prototype),"createEl",this).call(this,"li",Object.assign({className:this.buildCSSClass(),innerHTML:this.getInnerHTML(),tabIndex:-1},t),n)}},{key:"getInnerHTML",value:function(){var e=this.player_.duration();return'<span class="vjs-menu-item-text cv-chapter-menu-item-text">'+"<p>".concat(this.localize(this.options_.label),"</p>")+"<p>(".concat(by(this.options_.cue.startTime,e),")</p>")+"</span>"}}])&&Wy(t.prototype,n),r&&Wy(t,r),o}(Qy);n(403);function Zy(e){return(Zy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function em(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function tm(e,t,n){return(tm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=am(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function nm(e,t){return(nm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=am(e);if(t){var i=am(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return im(this,n)}}function im(e,t){return!t||"object"!==Zy(t)&&"function"!=typeof t?om(e):t}function om(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function am(e){return(am=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var sm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nm(e,t)}(o,e);var t,n,r,i=rm(o);function o(e,t,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(r=i.call(this,e,t,n)).alwaysCollapsed=!1,r.isCollapsed=!1,r.isCollabsible=!0,r.update=r.update.bind(om(r)),r.player_.on("cv-whiteboard-change",r.update),r.player_.on("fullscreenchange",r.update),r.player_.on("dispose",(function(){r.player_.off("cv-whiteboard-change",r.update),r.player_.off("fullscreenchange",r.update)})),r}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapters-button ".concat(tm(am(o.prototype),"buildCSSClass",this).call(this))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-big ".concat(tm(am(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createItems",value:function(){var e=[];if(!this.track_)return e;var t=this.track_.cues;if(!t)return e;for(var n=0,r=t.length;n<r;n++){var i=t[n],o=new Jy(this.player_,{track:this.track_,cue:i});e.push(o)}return e}},{key:"setTrack",value:function(e){var t=this;tm(am(o.prototype),"setTrack",this).call(this,e),this.track_&&"chapters"===this.track_.kind&&e.one("loadeddata",(function(){t.update()}))}},{key:"update",value:function(e){tm(am(o.prototype),"update",this).call(this,e),Pd.initMenuScrollbar(this)}},{key:"getCollabsibleName",value:function(){return"Chapters"}},{key:"getCollabsibleValue",value:function(){var e=this.track_.activeCues[0];return(null==e?void 0:e.text)||""}},{key:"showInCollabsibleMenu",value:function(){if(!this.track_)return!1;var e=this.track_.cues;return!(!e||!e.length)}},{key:"showCollapsibleMenu",value:function(){this.handleClick(null)}}])&&em(t.prototype,n),r&&em(t,r),o}(Fu.getComponent("ChaptersButton"));function um(e){return(um="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lm(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fm(e,t){return(fm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function hm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=pm(e);if(t){var i=pm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dm(this,n)}}function dm(e,t){return!t||"object"!==um(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function pm(e){return(pm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("ChaptersButton",sm);var ym=Fu.getComponent("SubsCapsMenuItem"),mm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&fm(e,t)}(o,e);var t,n,r,i=hm(o);function o(){return lm(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"handleClick",value:function(e){ym.prototype.handleClick.call(this,e),this.player_.trigger("cv:languageselected")}}])&&cm(t.prototype,n),r&&cm(t,r),o}(ym);function gm(e){return(gm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function vm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bm(e,t){return(bm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Tm(e);if(t){var i=Tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return wm(this,n)}}function wm(e,t){return!t||"object"!==gm(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Tm(e){return(Tm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Sm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&bm(e,t)}(o,e);var t,n,r,i=_m(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var n={};return n.track={player:e,kind:"subtitle",label:"Subtitle size",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="SubtitleSizeMenuItem",(t=i.call(this,e,n)).addClass("vjs-texttrack-settings"),t.controlText(", opens subtitle size settings"),t}return t=o,(n=[{key:"handleClick",value:function(){var e=this;this.requestAnimationFrame((function(){e.player_.getChild("collapserator").getChild("subtitleSizeButton").showCollapsibleMenu()}))}}])&&vm(t.prototype,n),r&&vm(t,r),o}(Fu.getComponent("TextTrackMenuItem"));n(404);function Em(e){return(Em="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function km(e,t){return(km=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function xm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Rm(e);if(t){var i=Rm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Om(this,n)}}function Om(e,t){return!t||"object"!==Em(t)&&"function"!=typeof t?Pm(e):t}function Pm(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Rm(e){return(Rm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Am=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&km(e,t)}(o,e);var t,n,r,i=xm(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var n={};n.track={player:e,kind:"subtitle",label:"Search subtitles",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="SubtitleSearchMenuItem",(t=i.call(this,e,n)).addClass("vjs-texttrack-settings"),t.controlText(", opens subtitle search"),t.toggleHidden=t.toggleHidden.bind(Pm(t));var r=t.player_.textTracks();return r.addEventListener("selectedlanguagechange",t.toggleHidden),t.player_.one("dispose",(function(){r.removeEventListener("selectedlanguagechange",t.toggleHidden)})),t.toggleHidden(),t}return t=o,(n=[{key:"toggleHidden",value:function(){var e;if(this.player_){var t=Id(this.player_);(null===(e=null==t?void 0:t.cues)||void 0===e?void 0:e.length)?this.show():this.hide()}}},{key:"handleClick",value:function(){var e=this;this.requestAnimationFrame((function(){e.player_.getChild("collapserator").getChild("subtitleSearchButton").showCollapsibleMenu()}))}}])&&Cm(t.prototype,n),r&&Cm(t,r),o}(Fu.getComponent("TextTrackMenuItem"));function Im(e){return(Im="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Lm(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dm(e,t,n){return(Dm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Bm(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Nm(e,t){return(Nm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Bm(e);if(t){var i=Bm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Um(this,n)}}function Um(e,t){return!t||"object"!==Im(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Bm(e){return(Bm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fm=Fu.getComponent("TextTrackButton"),Vm=Fu.getComponent("SubsCapsButton"),Hm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nm(e,t)}(o,e);var t,n,r,i=Mm(o);function o(){var e;return Lm(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Dm(Bm(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"update",value:function(){Dm(Bm(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"createItems",value:function(){var e=[new Am(this.player_),new Sm(this.player_)];return this.hideThreshold_++,Fm.prototype.createItems.call(this,e,mm)}},{key:"getCollabsibleName",value:function(){return"Subtitles"}},{key:"getCollabsibleValue",value:function(){for(var e=this.player_.textTracks(),t=0;t<e.length;t++){var n=e[t];if(this.kinds_.indexOf(n.kind)>-1&&"showing"===n.mode)return n.label}return"Off"}},{key:"showInCollabsibleMenu",value:function(){for(var e=this.player_.textTracks(),t=0;t<e.length;t++){var n=e[t];if(this.kinds_.indexOf(n.kind)>-1)return!0}return!1}},{key:"showCollapsibleMenu",value:function(){Vm.prototype.handleClick.apply(this)}}])&&jm(t.prototype,n),r&&jm(t,r),o}(Vm);function zm(e){return(zm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function qm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Wm(e,t){return(Wm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function $m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Km(e);if(t){var i=Km(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Gm(this,n)}}function Gm(e,t){return!t||"object"!==zm(t)&&"function"!=typeof t?Ym(e):t}function Ym(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Km(e){return(Km=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("SubsCapsButton",Hm);var Xm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Wm(e,t)}(o,e);var t,n,r,i=$m(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).qualityId=t.qualityId;var r=e.qualityLevels(),a=n.handleQualityChange.bind(Ym(n));return r.on("change",a),e.on("dispose",(function(){r.off("change",a)})),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"vjs-menu-item cv-quality-menu-item"}},{key:"handleClick",value:function(){for(var e=this.player_.qualityLevels(),t=0;t<e.length;t++){var n=e[t];n.enabled=n.id===this.qualityId}}},{key:"handleQualityChange",value:function(){if(this.player_){var e=this.player_.qualityLevels(),t=e[e.selectedIndex],n=t&&t.id===this.qualityId;n!==this.isSelected_&&this.selected(n)}}}])&&qm(t.prototype,n),r&&qm(t,r),o}(Fu.getComponent("MenuItem"));n(405);function Qm(e){return(Qm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Jm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Zm(e,t,n){return(Zm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ig(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function eg(e,t){return(eg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ig(e);if(t){var i=ig(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ng(this,n)}}function ng(e,t){return!t||"object"!==Qm(t)&&"function"!=typeof t?rg(e):t}function rg(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ig(e){return(ig=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var og={240:"240p",360:"360p",480:"480p",720:"720p",1080:"1080p"},ag=Fu.getComponent("MenuButton"),sg=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&eg(e,t)}(o,e);var t,n,r,i=tg(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).alwaysCollapsed=!0,n.isCollapsed=!1,n.isCollabsible=!0;var r=n.player_.qualityLevels(),a=n.update.bind(rg(n));return r.on("addqualitylevel",a),r.on("removequalitylevel",a),e.on("dispose",(function(){r.removeEventListener("addqualitylevel",a),r.removeEventListener("removequalitylevel",a)})),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-quality-button ".concat(Zm(ig(o.prototype),"buildCSSClass",this).call(this))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small vjs-quality-button ".concat(Zm(ig(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createItems",value:function(){for(var e=[],t=this.player_.qualityLevels(),n=0;n<t.length;n++){var r=t[n];if(r){var i=og[r.id];i&&e.push(new Xm(this.player_,{qualityId:r.id,label:i,selectable:!0,multiSelectable:!1}))}}return e}},{key:"update",value:function(){Zm(ig(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"getCollabsibleName",value:function(){return"Playback Quality"}},{key:"getCollabsibleValue",value:function(){var e=this.player_.qualityLevels(),t=e[e.selectedIndex];return t?og[t.id]:""}},{key:"showInCollabsibleMenu",value:function(){return!!this.player_.qualityLevels().length}},{key:"showCollapsibleMenu",value:function(){ag.prototype.handleClick.apply(this)}}])&&Jm(t.prototype,n),r&&Jm(t,r),o}(ag);Fu.registerComponent("QualityButton",sg);n(406);function ug(e){return(ug="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fg(e,t,n){return(fg="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=yg(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function hg(e,t){return(hg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function dg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=yg(e);if(t){var i=yg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pg(this,n)}}function pg(e,t){return!t||"object"!==ug(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function yg(e){return(yg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var mg=Fu.getComponent("Menu"),gg=Fu.getComponent("MenuButton"),vg=Fu.getComponent("PlaybackRateMenuItem"),bg=Fu.getComponent("PlaybackRateMenuButton"),_g=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&hg(e,t)}(o,e);var t,n,r,i=dg(o);function o(){var e;return lg(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!0,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"createEl",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=gg.prototype.createEl).apply.apply(e,[this].concat(n))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(fg(yg(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createMenu",value:function(){var e=new mg(this.player(),{menuButton:this}),t=this.playbackRates();if(t)for(var n=t.length-1;n>=0;n--)e.addItem(new vg(this.player(),{rate:t[n]+"x"}));return e}},{key:"handleClick",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=gg.prototype.handleClick).apply.apply(e,[this].concat(n))}},{key:"updateLabel",value:function(){var e;this.setupLabelEl();for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=bg.prototype.updateLabel).apply.apply(e,[this].concat(n))}},{key:"setupLabelEl",value:function(){if(!this.labelEl_){var e=this.$("button");e&&(this.labelEl_=Fu.dom.createEl("div",{className:"vjs-playback-rate-value",innerHTML:"1x"}),e.appendChild(this.labelEl_))}}},{key:"getCollabsibleName",value:function(){return"Playback Rate"}},{key:"getCollabsibleValue",value:function(){return this.player().playbackRate()+"x"}},{key:"showInCollabsibleMenu",value:function(){return!!this.playbackRates()}},{key:"showCollapsibleMenu",value:function(){this.handleClick(null)}}])&&cg(t.prototype,n),r&&cg(t,r),o}(bg);function wg(e){return(wg="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Tg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Sg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Eg(e,t){return(Eg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Cg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=xg(e);if(t){var i=xg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kg(this,n)}}function kg(e,t){return!t||"object"!==wg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function xg(e){return(xg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("PlaybackRateMenuButton",_g);var Og=Fu.getComponent("TextTrackSettings"),Pg={backgroundColor:"#000",backgroundOpacity:"1",color:"#FFF",edgeStyle:void 0,fontFamily:"proportionalSansSerif",fontPercent:1,textOpacity:"1",windowColor:"#000",windowOpacity:"0"},Rg={small:Pg,medium:Object.assign(Object.assign({},Pg),{fontPercent:1.5}),large:Object.assign(Object.assign({},Pg),{fontPercent:2})},Ag=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Eg(e,t)}(o,e);var t,n,r,i=Cg(o);function o(){return Tg(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setSizeSetting",value:function(e){this.size_=e,this.player_.getChild("textTrackDisplay").updateDisplay(),this.player_.getChild("collapserator").getChild("subtitleSizeButton").update(),this.player_.trigger("resizemenus"),this.player_.trigger("changesubtitlesize",this.size_)}},{key:"getSizeSetting",value:function(){return this.size_||"small"}},{key:"getValues",value:function(){return Rg[this.size_]?Rg[this.size_]:Pg}}])&&Sg(t.prototype,n),r&&Sg(t,r),o}(Og);Fu.registerComponent("TextTrackSettings",Ag);n(407);function Ig(e){return(Ig="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Lg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dg(e,t,n){return(Dg="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Bg(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ng(e,t){return(Ng=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Bg(e);if(t){var i=Bg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ug(this,n)}}function Ug(e,t){return!t||"object"!==Ig(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Bg(e){return(Bg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fg=window.navigator&&window.navigator.userAgent||"",Vg=(/iPod/i.test(Fg),/Android/i.test(Fg),Fu.getComponent("Player")),Hg=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ng(e,t)}(o,e);var t,n,r,i=Mg(o);function o(){return Lg(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"lock",value:function(e){this.callback_=e}},{key:"unlock",value:function(){delete this.callback_}},{key:"currentTime",value:function(e,t){var n=this;if("number"!=typeof e||!this.callback_||t)return Dg(Bg(o.prototype),"currentTime",this).call(this,e);this.callback_((function(){n.unlock(),n.currentTime(e)}))}},{key:"play",value:function(){var e=this;if(!this.callback_)return Dg(Bg(o.prototype),"play",this).call(this);this.callback_((function(){e.unlock(),e.play()}))}},{key:"updateStyleEl_",value:function(){if(Vg.prototype.updateStyleEl_.call(this),this.options_.fluid){var e=this.el_.parentNode;if(e){var t=this.aspectRatio();void 0!==t&&"auto"!==t||(t=this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9");var n=t.split(":"),r=+n[1]/+n[0];e.style.maxWidth=65/r+"vh",e.style.margin="0 auto"}}}},{key:"listenForUserActivity_",value:function(){var e=this;Vg.prototype.listenForUserActivity_.call(this);var t=this.getChild("collapserator");t.on("mouseenter",(function(){e.player().cache_.inactivityTimeout=e.player().options_.inactivityTimeout,e.player().options_.inactivityTimeout=0})),t.on("mouseleave",(function(){e.player().options_.inactivityTimeout=e.player().cache_.inactivityTimeout}))}}])&&jg(t.prototype,n),r&&jg(t,r),o}(Vg);Fu.registerComponent("player",Hg);var zg;n(408),n(409),n(410),n(411),n(412);function qg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wg(e){e.paused()?e.play():e.pause()}function $g(e,t){e.currentTime(e.currentTime()+t)}function Gg(e,t){e.volume(e.volume()+t)}var Yg=(qg(zg={},"f",(function(e){document[e.fsApi_.fullscreenEnabled]&&(e.isFullscreen()?e.exitFullscreen():e.requestFullscreen())})),qg(zg,"m",(function(e){var t=e.volume(),n=e.lastVolume_();if(0===t){var r=n<.1?.1:n;e.volume(r),e.muted(!1)}else e.muted(!e.muted())})),qg(zg,"k",Wg),qg(zg,"space",Wg),qg(zg,"left",(function(e){return $g(e,-5)})),qg(zg,"right",(function(e){return $g(e,5)})),qg(zg,"j",(function(e){return $g(e,-10)})),qg(zg,"l",(function(e){return $g(e,10)})),qg(zg,"up",(function(e){return Gg(e,.05)})),qg(zg,"down",(function(e){return Gg(e,-.05)})),zg);function Kg(e){var t=v()(e);Yg[t]&&Yg[t](this,e)}function Xg(e){return(Xg="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Qg(e,t){return!t||"object"!==Xg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jg(e){var t="function"==typeof Map?new Map:void 0;return(Jg=function(e){if(null===e||(n=e,-1===Function.toString.call(n).indexOf("[native code]")))return e;var n;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return Zg(e,arguments,nv(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),tv(r,e)})(e)}function Zg(e,t,n){return(Zg=ev()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&tv(i,n.prototype),i}).apply(null,arguments)}function ev(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function tv(e,t){return(tv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function nv(e){return(nv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var rv=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tv(e,t)}(i,e);var t,n,r=(t=i,n=ev(),function(){var e,r=nv(t);if(n){var i=nv(this).constructor;e=Reflect.construct(r,arguments,i)}else e=r.apply(this,arguments);return Qg(this,e)});function i(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(n=r.call(this,e)).url=t,n}return i}(Jg(Error));function iv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var ov,av=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},sv=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.tokens={gateway:null}}var t,n,r;return t=e,(n=[{key:"get",value:function(e,t){return av(this,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.t0=this,n.next=3,fetch(e,{method:"GET",mode:"cors",headers:this.getHeaders(t)});case 3:return n.t1=n.sent,n.next=6,n.t0.parseResponse.call(n.t0,n.t1);case 6:return n.abrupt("return",n.sent);case 7:case"end":return n.stop()}}),n,this)})))}},{key:"delete",value:function(e,t){return av(this,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,fetch(e,{method:"DELETE",headers:this.getHeaders(t)});case 2:case"end":return n.stop()}}),n,this)})))}},{key:"post",value:function(e,t,n){return av(this,void 0,void 0,regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.t0=this,r.next=3,fetch(e,{method:"POST",headers:this.getHeaders(n),body:t,mode:"cors"});case 3:return r.t1=r.sent,r.next=6,r.t0.parseResponse.call(r.t0,r.t1);case 6:return r.abrupt("return",r.sent);case 7:case"end":return r.stop()}}),r,this)})))}},{key:"put",value:function(e,t,n){return av(this,void 0,void 0,regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.t0=this,r.next=3,fetch(e,{method:"PUT",headers:this.getHeaders(n),body:t,mode:"cors"});case 3:return r.t1=r.sent,r.next=6,r.t0.parseResponse.call(r.t0,r.t1);case 6:return r.abrupt("return",r.sent);case 7:case"end":return r.stop()}}),r,this)})))}},{key:"setToken",value:function(e,t){this.tokens[e]=t}},{key:"getHeaders",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={"Content-Type":"application/json"};return this.tokens[e.tokenName]&&(t.authorization="Bearer ".concat(this.tokens[e.tokenName])),t}},{key:"parseResponse",value:function(e){return av(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(404!==e.status){t.next=2;break}return t.abrupt("return",null);case 2:if(e.ok){t.next=4;break}throw new rv("Ajax error",e.url);case 4:return t.next=6,e.json();case 6:return n=t.sent,t.abrupt("return",n);case 8:case"end":return t.stop()}}),t)})))}}])&&iv(t.prototype,n),r&&iv(t,r),e}());function uv(e){return(uv="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lv(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cv(e,t)}function cv(e,t){return(cv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dv(e);if(t){var i=dv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return hv(this,n)}}function hv(e,t){return!t||"object"!==uv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function dv(e){return(dv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function pv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mv(e,t,n){return t&&yv(e.prototype,t),n&&yv(e,n),e}!function(e){e.LocalStorage="localStorage",e.SessionStorage="sessionStorage"}(ov||(ov={}));var gv=function(){function e(t){pv(this,e),this.cachePrefix="_cv:",this.expireTime=3600,this.hasSupport=this.hasBrowserSupport(),this.type=t.type,this.hasSupport&&(this.storage=window[this.type])}return mv(e,[{key:"get",value:function(e){if(this.hasSupport){var t=this.storage.getItem(e);try{return JSON.parse(t)}catch(e){return t}}}},{key:"set",value:function(e,t){if(this.hasSupport)try{return this.storage.removeItem(e),"string"!=typeof t?(this.storage.setItem(e,JSON.stringify(t)),!0):(this.storage.setItem(e,t),!0)}catch(e){return!1}}},{key:"remove",value:function(e){if(this.hasSupport)return this.storage.removeItem(e)}},{key:"length",value:function(){if(this.hasSupport)return this.storage.length}},{key:"clear",value:function(){if(this.hasSupport)return this.storage.clear()}},{key:"cacheSet",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.expireTime;this.cacheClean();var r={time:this.getCurrentTime()+1e3*n,data:null!=t&&t};return this.set("".concat(this.cachePrefix).concat(e),r)}},{key:"cacheGet",value:function(e){var t="".concat(this.cachePrefix).concat(e),n=this.get(t);return n?this.isExpired(n)?(this.remove(t),null):n.data:null}},{key:"cacheExists",value:function(e){var t="".concat(this.cachePrefix).concat(e),n=this.get(t);return!!n&&(!this.isExpired(n)||(this.remove(t),!1))}},{key:"cacheRemove",value:function(e){return this.remove("".concat(this.cachePrefix).concat(e))}},{key:"cacheFlush",value:function(){this.cacheClean()}},{key:"cacheClean",value:function(){if(this.hasSupport)for(var e=0;e<this.storage.length;e++){var t=this.storage.key(e);if(0===t.indexOf(this.cachePrefix)){var n=this.get(t);n&&n.time&&this.isExpired(n)&&this.remove(t)}}}},{key:"isExpired",value:function(e){return e.time<this.getCurrentTime()}},{key:"getCurrentTime",value:function(){return(new Date).getTime()}},{key:"hasBrowserSupport",value:function(){try{return this.type in window&&null!==window[this.type]}catch(e){return!1}}}]),e}(),vv=function(e){lv(n,e);var t=fv(n);function n(){return pv(this,n),t.apply(this,arguments)}return mv(n,null,[{key:"Instance",get:function(){return this.instance||(this.instance=new this({type:ov.LocalStorage}))}}]),n}(gv),bv=function(e){lv(n,e);var t=fv(n);function n(){return pv(this,n),t.apply(this,arguments)}return mv(n,null,[{key:"Instance",get:function(){return this.instance||(this.instance=new this({type:ov.SessionStorage}))}}]),n}(gv),_v=vv.Instance,wv=(bv.Instance,"URLSearchParams"in self),Tv="Symbol"in self&&"iterator"in Symbol,Sv="FileReader"in self&&"Blob"in self&&function(){try{return new Blob,!0}catch(e){return!1}}(),Ev="FormData"in self,Cv="ArrayBuffer"in self;if(Cv)var kv=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],xv=ArrayBuffer.isView||function(e){return e&&kv.indexOf(Object.prototype.toString.call(e))>-1};function Ov(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function Pv(e){return"string"!=typeof e&&(e=String(e)),e}function Rv(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return Tv&&(t[Symbol.iterator]=function(){return t}),t}function Av(e){this.map={},e instanceof Av?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function Iv(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function Lv(e){return new Promise((function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}}))}function jv(e){var t=new FileReader,n=Lv(t);return t.readAsArrayBuffer(e),n}function Dv(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function Nv(){return this.bodyUsed=!1,this._initBody=function(e){var t;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:Sv&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:Ev&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:wv&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():Cv&&Sv&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=Dv(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):Cv&&(ArrayBuffer.prototype.isPrototypeOf(e)||xv(e))?this._bodyArrayBuffer=Dv(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):wv&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},Sv&&(this.blob=function(){var e=Iv(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?Iv(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(jv)}),this.text=function(){var e,t,n,r=Iv(this);if(r)return r;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,n=Lv(t),t.readAsText(e),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),r=0;r<t.length;r++)n[r]=String.fromCharCode(t[r]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},Ev&&(this.formData=function(){return this.text().then(Bv)}),this.json=function(){return this.text().then(JSON.parse)},this}Av.prototype.append=function(e,t){e=Ov(e),t=Pv(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},Av.prototype.delete=function(e){delete this.map[Ov(e)]},Av.prototype.get=function(e){return e=Ov(e),this.has(e)?this.map[e]:null},Av.prototype.has=function(e){return this.map.hasOwnProperty(Ov(e))},Av.prototype.set=function(e,t){this.map[Ov(e)]=Pv(t)},Av.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},Av.prototype.keys=function(){var e=[];return this.forEach((function(t,n){e.push(n)})),Rv(e)},Av.prototype.values=function(){var e=[];return this.forEach((function(t){e.push(t)})),Rv(e)},Av.prototype.entries=function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),Rv(e)},Tv&&(Av.prototype[Symbol.iterator]=Av.prototype.entries);var Mv=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function Uv(e,t){var n,r,i=(t=t||{}).body;if(e instanceof Uv){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new Av(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,i||null==e._bodyInit||(i=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new Av(t.headers)),this.method=(n=t.method||this.method||"GET",r=n.toUpperCase(),Mv.indexOf(r)>-1?r:n),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function Bv(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var n=e.split("="),r=n.shift().replace(/\+/g," "),i=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(r),decodeURIComponent(i))}})),t}function Fv(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"",this.headers=new Av(t.headers),this.url=t.url||"",this._initBody(e)}Uv.prototype.clone=function(){return new Uv(this,{body:this._bodyInit})},Nv.call(Uv.prototype),Nv.call(Fv.prototype),Fv.prototype.clone=function(){return new Fv(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new Av(this.headers),url:this.url})},Fv.error=function(){var e=new Fv(null,{status:0,statusText:""});return e.type="error",e};var Vv=[301,302,303,307,308];Fv.redirect=function(e,t){if(-1===Vv.indexOf(t))throw new RangeError("Invalid status code");return new Fv(null,{status:t,headers:{location:e}})};var Hv=self.DOMException;try{new Hv}catch(e){(Hv=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),Hv.prototype.constructor=Hv}function zv(e,t){return new Promise((function(n,r){var i=new Uv(e,t);if(i.signal&&i.signal.aborted)return r(new Hv("Aborted","AbortError"));var o=new XMLHttpRequest;function a(){o.abort()}o.onload=function(){var e,t,r={status:o.status,statusText:o.statusText,headers:(e=o.getAllResponseHeaders()||"",t=new Av,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(e){var n=e.split(":"),r=n.shift().trim();if(r){var i=n.join(":").trim();t.append(r,i)}})),t)};r.url="responseURL"in o?o.responseURL:r.headers.get("X-Request-URL");var i="response"in o?o.response:o.responseText;setTimeout((function(){n(new Fv(i,r))}),0)},o.onerror=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.ontimeout=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.onabort=function(){setTimeout((function(){r(new Hv("Aborted","AbortError"))}),0)},o.open(i.method,function(e){try{return""===e&&self.location.href?self.location.href:e}catch(t){return e}}(i.url),!0),"include"===i.credentials?o.withCredentials=!0:"omit"===i.credentials&&(o.withCredentials=!1),"responseType"in o&&(Sv?o.responseType="blob":Cv&&-1!==i.headers.get("Content-Type").indexOf("application/octet-stream")&&(o.responseType="arraybuffer")),i.headers.forEach((function(e,t){o.setRequestHeader(t,e)})),i.signal&&(i.signal.addEventListener("abort",a),o.onreadystatechange=function(){4===o.readyState&&i.signal.removeEventListener("abort",a)}),o.send(void 0===i._bodyInit?null:i._bodyInit)}))}zv.polyfill=!0,self.fetch||(self.fetch=zv,self.Headers=Av,self.Request=Uv,self.Response=Fv);var qv=n(237),Wv=n.n(qv),$v=n(238);function Gv(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Yv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Yv(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Yv(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Kv={mobileDevice:/Mobi/i,iphone:/iphone/i,ipad:/ipad/i,android:/android/i,blackberry:/blackberry/i,windowsPhone:/windows phone/i,iosVersion:/OS\s+([\d_.-:]+)\s/i,androidVersion:/android\s+([\d_.-\/]+)[\s;:,\)]/i,blackberryVersion:/(blackberry|version)\s?\d*\/([\d.]+)/i,windowsPhoneVersion:/windows\sphone.*?([\d_.-\/]+)[\s;:,\)]/i,mac:/Mac/i,unix:/X11/i,linux:/Linux/i,windows:/Win/i,win2000:/nt 5.0/i,winXP:/nt 5.1/i,winVista:/nt 6.0/i,win7:/nt 6.1/i,win8:/nt 6.2/i,win81:/nt 6.3/i,win10:/nt 10.0/i,osxVersion:/OS\sX\s([\d_.]+)/i,chrome:/^(?!.*Edge).*Chrome/i,safari:/^(?!.*(?:Chrome|Edge)).*Safari/i,edge:/edge/i,ie:/(msie|trident)/i,opera:/(opr|opera)/i,firefox:/firefox/i,generalVersion:/(chrome|firefox|version)\/(\d+.*?)(\s|$)/i,operaVersion:/(opr|opera)\/(\d+).*?(\s|$)/i,ieVersion:/MSIE\s+(\d+).*?/i,edgeVersion:/(edge)\/(\d+).*?(\s|$)/i};function Xv(e,t,n){var r=Gv(t.exec(n)||[],1)[0];return r||(r="Unknown"),{name:e,version:r}}function Qv(e,t,n){if(!t)return{name:e,version:"Unknown"};var r=t.exec(n);return{name:e,version:r&&r.length?r[0].trim():"Unknown"}}var Jv=function(){var e=window.navigator.userAgent;return Kv.android.test(e)?Qv("Android",Kv.androidVersion,e):Kv.iphone.test(e)||Kv.ipad.test(e)?Qv("iOS",Kv.iosVersion,e):Kv.linux.test(e)?Qv("Linux",null,e):Kv.unix.test(e)?Qv("Unix",null,e):Kv.mac.test(e)?Qv("Macintosh",Kv.osxVersion,e):Kv.windows.test(e)?function(e,t){var n={name:e,version:null};return Kv.win2000.test(t)&&(n.version="2000"),Kv.winXP.test(t)&&(n.version="XP"),Kv.winVista.test(t)&&(n.version="Vista"),Kv.win7.test(t)&&(n.version="7"),Kv.win8.test(t)&&(n.version="8"),Kv.win81.test(t)&&(n.version="8.1"),Kv.win10.test(t)&&(n.version="10"),n.version||(n.version="Unknown"),n}("Windows",e):Kv.blackberry.test(e)?Qv("BlackBerry",Kv.blackberryVersion,e):Kv.windowsPhone.test(e)?Qv("Windows Phone",Kv.windowsPhoneVersion,e):{name:"Unknown",version:"Unknown"}},Zv=function(){var e=window.navigator.userAgent;return Kv.chrome.test(e)?Xv("Chrome",Kv.generalVersion,e):Kv.firefox.test(e)?Xv("Firefox",Kv.generalVersion,e):Kv.safari.test(e)?Xv("Safari",Kv.generalVersion,e):Kv.ie.test(e)?Xv("Internet Explorer",Kv.ieVersion,e):Kv.edge.test(e)?Xv("Edge",Kv.edgeVersion,e):Kv.opera.test(e)?Xv("Opera",Kv.operaVersion,e):{name:"Unknown",version:"Unknown"}};function eb(e){return(eb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var tb,nb=function(e){var t=eb(e);return"function"===t||"object"===t&&!!e},rb=function(e){return"function"==typeof e},ib=function(e,t){if(e){var n=e;return e.endsWith("/")||(n+="/"),t?n+=t.startsWith("/")?t.slice(1):t:n}},ob=n(103);!function(e){e.CvApSoutheast1="cv-ap-southeast-1",e.CvApSoutheast2="cv-ap-southeast-2",e.CvEuWest1="cv-eu-west-1"}(tb||(tb={}));var ab,sb,ub={CvApSoutheast1:{displayName:"ClickView Asia Pacific (AU)",systemName:tb.CvApSoutheast1},CvApSoutheast2:{displayName:"ClickView Asia Pacific (NZ)",systemName:tb.CvApSoutheast2},CvEuWest1:{displayName:"ClickView EU West (UK)",systemName:tb.CvEuWest1}};function lb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.AU="au",e.NZ="nz",e.UK="uk"}(ab||(ab={}));var cb=(lb(sb={},ab.AU,tb.CvApSoutheast1),lb(sb,ab.NZ,tb.CvApSoutheast2),lb(sb,ab.UK,tb.CvEuWest1),sb);function fb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var hb=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},db=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=t,this.initialize()}var t,n,r;return t=e,(n=[{key:"initialize",value:function(){this.validateOptions()}},{key:"name",get:function(){return"CollectionApiClient"}},{key:"log",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!Array.isArray(e)){t.next=2;break}return t.abrupt("return",this.logBulk(e));case 2:if(this.shouldLog(e)){t.next=4;break}return t.abrupt("return");case 4:return this.validateEvent(e),t.t0=this,t.next=8,this.formatData(e);case 8:return t.t1=t.sent,t.next=11,t.t0.postData.call(t.t0,t.t1);case 11:case"end":return t.stop()}}),t,this)})))}},{key:"logBulk",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((n=e.filter((function(e){return i.shouldLog(e)}))).length){t.next=3;break}return t.abrupt("return");case 3:return n.forEach((function(e){return i.validateEvent(e)})),t.next=6,Promise.all(n.map((function(e){return i.formatData(e)})));case 6:return r=t.sent,t.next=9,this.postData(r);case 9:case"end":return t.stop()}}),t,this)})))}},{key:"validateOptions",value:function(){if(!rb(this.options.getUser))throw new Error("getUser option is required.")}},{key:"shouldLog",value:function(e){return!rb(this.options.shouldLog)||this.options.shouldLog(e)}},{key:"postData",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i,o;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getRegionalUrl(this.options.collectionApiUrls);case 2:return n=t.sent,r=JSON.stringify(e),i=Object.assign({"Content-Type":"application/json"},this.getSignatureHeader(r)),o=ib(n,"/v1/ingest"),Array.isArray(e)&&(o=ib(o,"/bulk")),t.next=9,fetch(o,{method:"POST",mode:"cors",headers:i,body:r});case 9:case"end":return t.stop()}}),t,this)})))}},{key:"getSignatureHeader",value:function(e){var t=new Wv.a("SHA-1","TEXT",{hmacKey:{value:"zXJL9nOHxzDlMUDjiP41",format:"TEXT",encoding:"UTF8"}});return t.update(e),{"cv-analytics-signature":"".concat(this.options.collectionApiClientId,".").concat(t.getHash("B64"))}}},{key:"getRegionalUrl",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getRegion();case 2:n=t.sent,t.t0=n.systemName,t.next=t.t0===tb.CvEuWest1?6:t.t0===tb.CvApSoutheast2?7:(t.t0,tb.CvApSoutheast1,8);break;case 6:return t.abrupt("return",e.cvEuWest1);case 7:return t.abrupt("return",e.cvApSoutheast2);case 8:return t.abrupt("return",e.cvApSoutheast1);case 9:case"end":return t.stop()}}),t,this)})))}},{key:"validateEvent",value:function(e){if("string"!=typeof e.type)throw new Error("Event type is required.");if(!nb(e.actionContext))throw new Error("Event actionContext is required.");if(!e.actionContext.entity)throw new Error("Event actionContext entity is required.")}},{key:"formatData",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.t0=e.type,t.next=3,this.getEventData(e);case 3:return t.t1=t.sent,t.t2=this.getEventMetadata(e),t.abrupt("return",{type:t.t0,data:t.t1,metadata:t.t2});case 6:case"end":return t.stop()}}),t,this)})))}},{key:"getEventData",value:function(e){return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i,o,a,s;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.actionContext,t.next=3,this.getUserData();case 3:return r=t.sent,i={user:r,action:n,platform:this.getPlatformMetadata(),product:{name:this.options.productName,version:this.options.productVersion}},o=this.extractData(e),a=Object.keys(i).map((function(e){return e.toLowerCase()})),s=Object.keys(o).map((function(e){return e.toLowerCase()})),a.forEach((function(e){if(s.includes(e))throw Error("".concat(e," is a reserved key."))})),t.abrupt("return",Object.assign(Object.assign({},i),o));case 10:case"end":return t.stop()}}),t,this)})))}},{key:"extractData",value:function(e){return rb(this.options.formatData)?this.options.formatData(e):(t={},n=e.actionContext.entity,r=e.data,n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t);var t,n,r}},{key:"getUserData",value:function(){var e,t;return hb(this,void 0,void 0,regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.options.getUser();case 2:if(null==(r=n.sent)?void 0:r.id){n.next=5;break}return n.abrupt("return");case 5:return n.t0=r.id,n.t1=(null===(e=r.role)||void 0===e?void 0:e.toLowerCase())||"unknown",n.t2=(null===(t=r.userGroup)||void 0===t?void 0:t.toLowerCase())||ob.a.Unknown,n.t3=this.normalizeYearGroup(r.yearGroup),n.t4=r.customerId,n.t5=r.customerName,n.t6=r.customerGuid,n.t7=r.crmId,n.t8=r.countryCode,n.next=16,this.getRegion();case 16:return n.t9=n.sent,n.t10=r.isOpenCustomer,n.t11={id:n.t4,name:n.t5,customerGuid:n.t6,crmId:n.t7,country:n.t8,region:n.t9,openCustomer:n.t10},n.abrupt("return",{id:n.t0,role:n.t1,userGroup:n.t2,yearGroup:n.t3,customer:n.t11});case 20:case"end":return n.stop()}}),n,this)})))}},{key:"getRegion",value:function(){var e;return hb(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.options.getUser();case 2:return n=t.sent,r=null===(e=null==n?void 0:n.countryCode)||void 0===e?void 0:e.toLowerCase(),i=r?cb[r]:this.options.regionName,t.abrupt("return",this.getRegionByName(i));case 6:case"end":return t.stop()}}),t,this)})))}},{key:"getPlatformMetadata",value:function(){return{browser:Zv(),os:Jv(),request:{url:window.location.href,referrer:document.referrer},screenResolution:"".concat(window.screen.width,"x").concat(window.screen.height)}}},{key:"getEventMetadata",value:function(e){return{client:{name:"".concat(this.name,".ts"),version:$v.a,region:this.getRegionByName(this.options.regionName)},timestamp:(new Date).toISOString(),eventVersion:e.eventVersion}}},{key:"getRegionByName",value:function(e){var t;return Object.values(ub).forEach((function(n){n.systemName===e&&(t=n)})),t}},{key:"normalizeYearGroup",value:function(e){return e?e.toLowerCase().split(" ").join("_"):"unknown"}}])&&fb(t.prototype,n),r&&fb(t,r),e}(),pb=n(2),yb=function(){return!0},mb=function(){return!1};var gb=function(e){return e};function vb(e){if(e&&e.code)return e.code}function bb(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&e.id){var n={id:e.id};return e.name&&!t.ignoreTitle&&(n.title=e.name),n}}function _b(e){if(e&&e.length){var t=e[0];return{id:t.id,title:t.name}}}var wb,Tb,Sb,Eb,Cb=function(e){var t=e.model,n={id:t.id.toString(),year:t.productionYear,title:t.name,trackingCode:t.trackingCode},r=vb(t.rating),i=bb(t.series),o=_b(t.categories),a=bb(t.owner,{ignoreTitle:!0}),s=bb(t.playlist);return r&&(n.rating=r),a&&(n.ownerId=a.id),i&&(n.seriesId=i.id,n.series=i.title),o&&(n.category=o.title),s&&(n.playlist=s),n},kb={getUploadData:function(e,t){var n=t.actionContext.entity;if(n===pb.EntityType.Video)return kb.formatVideoUpload(e,t);if(n===pb.EntityType.Resource||n===pb.EntityType.Subtitle)return kb.formatResourceUpload(e);if(n===pb.EntityType.Banner||n===pb.EntityType.Thumbnail)return e;throw new Error("Upload data event not correctly formatted.")},formatVideoUpload:function(e,t){var n=t.actionContext.workflowPhase;return n===pb.WorkflowPhase.Start?kb.getStartVideoUploadData(e):n===pb.WorkflowPhase.Discard?kb.getDiscardVideoUploadData(e):n===pb.WorkflowPhase.Complete?kb.getCompleteUploadData(e):void 0},getStartVideoUploadData:function(e){return e&&e.length?(e instanceof FileList&&(e=Array.from(e)),e.map((function(t){return{fileName:t.name,size:t.size,type:t.type,count:e.length}}))):[]},getDiscardVideoUploadData:function(e){var t=function(t){var n=t.file,r=n.type,i=n.name,o=n.status,a=n.cvUpload,s={fileName:i,count:Array.isArray(e)?e.length:1,type:r,status:o};return t.progress&&(s.progress=t.progress.toFixed(2)),a&&(s.uploadId=a.uploadId),s};return Array.isArray(e)?e.map((function(e){return t(e)})):[t(e)]},getCompleteUploadData:function(e){return e&&e.length?e.map((function(t){return{fileName:t.fileName,libraryId:t.libraryId,folderId:t.folderId,autoCaption:t.autoCaption,count:e.length}})):[]},formatResourceUpload:function(e){var t={id:e.id,name:e.name};return nb(e.metadata)&&(t.type=e.metadata.type),t}};function xb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ob=(xb(wb={},pb.UserAction.Navigate,mb),xb(wb,pb.UserAction.Click,yb),xb(wb,pb.UserAction.Search,yb),xb(wb,pb.UserAction.InstantSearch,yb),xb(wb,pb.UserAction.Play,yb),xb(wb,pb.UserAction.Stream,yb),xb(wb,pb.UserAction.WebPlayerStream,yb),xb(wb,pb.UserAction.StreamRaw,yb),xb(wb,pb.UserAction.StreamProgress,yb),xb(wb,pb.UserAction.Rename,yb),xb(wb,pb.UserAction.Move,yb),xb(wb,pb.UserAction.Create,yb),xb(wb,pb.UserAction.Delete,yb),xb(wb,pb.UserAction.Associate,yb),xb(wb,pb.UserAction.Dissociate,yb),xb(wb,pb.UserAction.Filter,yb),xb(wb,pb.UserAction.Sort,yb),xb(wb,pb.UserAction.Approve,yb),xb(wb,pb.UserAction.Reject,yb),xb(wb,pb.UserAction.Disable,yb),xb(wb,pb.UserAction.Upload,yb),xb(wb,pb.UserAction.Download,mb),xb(wb,pb.UserAction.SetAccess,yb),xb(wb,pb.UserAction.AddToLocalCache,mb),xb(wb,pb.UserAction.Share,yb),xb(wb,pb.UserAction.Edit,yb),xb(wb,pb.UserAction.Suggest,yb),xb(wb,pb.UserAction.Favourite,yb),xb(wb,pb.UserAction.ResolveWarning,yb),xb(wb,pb.UserAction.DismissWarning,yb),xb(wb,pb.UserAction.EditAssoc,yb),xb(wb,pb.UserAction.Follow,yb),xb(wb,pb.UserAction.Print,yb),xb(wb,pb.UserAction.Copy,yb),xb(wb,pb.UserAction.Activate,yb),xb(wb,pb.UserAction.VerifyEmail,yb),xb(wb,pb.UserAction.ChangePassword,yb),xb(wb,pb.UserAction.Export,yb),wb),Pb=(xb(Tb={},pb.UserAction.Search,gb),xb(Tb,pb.UserAction.InstantSearch,gb),xb(Tb,pb.UserAction.Play,gb),xb(Tb,pb.UserAction.Stream,Cb),xb(Tb,pb.UserAction.StreamRaw,gb),xb(Tb,pb.UserAction.StreamProgress,gb),xb(Tb,pb.UserAction.Click,gb),xb(Tb,pb.UserAction.Filter,gb),xb(Tb,pb.UserAction.Sort,gb),xb(Tb,pb.UserAction.SetAccess,gb),xb(Tb,pb.UserAction.Approve,gb),xb(Tb,pb.UserAction.Reject,gb),xb(Tb,pb.UserAction.Create,gb),xb(Tb,pb.UserAction.Delete,gb),xb(Tb,pb.UserAction.Rename,gb),xb(Tb,pb.UserAction.Move,gb),xb(Tb,pb.UserAction.Edit,gb),xb(Tb,pb.UserAction.Share,gb),xb(Tb,pb.UserAction.Disable,gb),xb(Tb,pb.UserAction.Suggest,gb),xb(Tb,pb.UserAction.Upload,kb.getUploadData),xb(Tb,pb.UserAction.ResolveWarning,gb),xb(Tb,pb.UserAction.DismissWarning,gb),xb(Tb,pb.UserAction.Follow,gb),xb(Tb,pb.UserAction.Print,gb),xb(Tb,pb.UserAction.Copy,gb),Tb),Rb=(xb(Sb={},pb.UserAction.Search,(function(){return"search"})),xb(Sb,pb.UserAction.InstantSearch,(function(){return"search"})),xb(Sb,pb.UserAction.Filter,(function(){return"filter"})),xb(Sb,pb.UserAction.StreamRaw,(function(){return pb.EntityType.Video})),Sb),Ab={user:"target_user"},Ib=(xb(Eb={},pb.UserAction.StreamProgress,!0),xb(Eb,pb.UserAction.WebPlayerStream,!0),Eb),Lb={shouldLog:function(e){return!!Ob[e.type](e)},formatData:function(e){var t=Pb[e.type],n=rb(t)?t(e.data,e):e.data;if(Ib[e.type])return n;var r=e.actionContext.entity;return rb(Rb[e.type])&&(r=Rb[e.type](e)),Ab[r]&&(r=Ab[r]),xb({},r,n)}};function jb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Db=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=t,this.initialize()}var t,n,r;return t=e,(n=[{key:"logStream",value:function(){var e="v:".concat(this.options.videoId);_v.cacheExists(e)||(this.collectionApiClient.log({type:pb.UserAction.WebPlayerStream,actionContext:this.getActionContext(),data:{video:{id:this.options.videoId},flags:{isUsingLocalCache:this.options.isUsingLocalCache}},eventVersion:pb.EventVersion.V2}),_v&&_v.cacheSet(e,null,300))}},{key:"logVideoProgress",value:function(e){var t=this;this.collectionApiClient.log(e.map((function(e){return{type:pb.UserAction.StreamProgress,actionContext:t.getActionContext(),data:{progress:e,video:{id:t.options.videoId}},eventVersion:pb.EventVersion.V1}})))}},{key:"initialize",value:function(){this.setupCollectionApiClient()}},{key:"setupCollectionApiClient",value:function(){var e=this;this.collectionApiClient=new db({productName:"player.web",productVersion:this.options.productVersion,regionName:this.options.regionName,collectionApiUrls:this.options.collectionApiUrls,collectionApiClientId:this.options.collectionApiClientId,getUser:function(){return e.getCurrentUser()},shouldLog:Lb.shouldLog,formatData:Lb.formatData})}},{key:"getCurrentUser",value:function(){var e=this;return new Promise((function(t){t({id:e.options.userId,customerId:e.options.customerId})}))}},{key:"getActionContext",value:function(){return{entity:this.getEntityType(),location:this.getLocationContext(),productArea:void 0,descriptor:this.options.isEmbedded?pb.PlayerDescriptor.Embedded:void 0,workflowPhase:void 0}}},{key:"getEntityType",value:function(){switch(this.options.mediaType){case"MasterVideo":return pb.EntityType.Video;case"MasterInteractive":return pb.EntityType.Interactive;case"MasterClip":return pb.EntityType.Clip}}},{key:"getLocationContext",value:function(){switch(this.options.playerType){case"player":return pb.LocationContext.Player;case"interactive-player":return pb.LocationContext.InteractivePlayer;case"create-clip-player":return pb.LocationContext.CreateClipPlayer}}}])&&jb(t.prototype,n),r&&jb(t,r),e}(),Nb="\n <svg viewBox='0 0 434 71'>\n <g>\n <path fill='#FFFFFF' d='M114.44 56.57l3.5 3.5a32.87 32.87 0 0 1-25.16 11.26c-19.63 0-33.62-15.54-33.62-35.16C59.16 16.55 73.16 1 92.78 1a32.31 32.31 0 0 1 24.19 10.4l-3.6 3.3a27.32 27.32 0 0 0-20.59-8.74c-16.91 0-28.39 13.5-28.39 30.21s11.48 30.21 28.39 30.21a28.08 28.08 0 0 0 21.66-9.81zM126.64 1h4.55v70.22h-4.73L126.64 1zm17.3 10.6a3.7 3.7 0 1 1 0 7.4 3.7 3.7 0 0 1 0-7.4zm-2.41 15.07h4.81v44.56h-4.81V26.67zm48 33.15l3.33 3.15a21.8 21.8 0 0 1-17.31 8.61c-12.59 0-21.76-10-21.76-22.22 0-12.22 9.17-22.22 21.76-22.22a21.84 21.84 0 0 1 16.85 8l-3.43 3.06a17.15 17.15 0 0 0-13.42-6.3c-10.09 0-16.76 8.15-16.76 17.5s6.67 17.5 16.76 17.5a17.38 17.38 0 0 0 13.98-7.08zm14.99-9.33v20.74h-4.73V1.01h4.73v47.75l20.74-19.02h6.64l-21.56 19.84L234 71.23h-7.01l-22.47-20.74z'/>\n <path fill='#F8981D' d='M304.09 19.4a5.56 5.56 0 1 1 0-11.12 5.56 5.56 0 0 1 0 11.12zm-5.56 7.27h11.11v44.56h-11.11V26.67zm61.42 22.15c0 .81 0 2.42-.09 4h-31.75c.8 3.77 5.2 8.61 11.93 8.61a17.11 17.11 0 0 0 11.66-4.31l5.38 8.16a27.23 27.23 0 0 1-17 6.1c-12.92 0-22.88-9.87-22.88-22.34s9.06-22.33 21.35-22.33c11.62-.04 21.4 9.02 21.4 22.11zm-10.77-3.76c-.18-3.68-3.58-8.62-10.67-8.62-6.91 0-10.05 4.85-10.4 8.62h21.07zM385.92 71h-6.42l-19.64-44.37h13.97l9.16 23.98 9.72-23.98h8.31l9.63 23.98 9.16-23.98h13.97L414.24 71h-6.52l-10.85-23.7L385.92 71zm-120.22.35h-6L226.11 1.01h17.01l19.42 44.18 18.08-44.18h16.91L265.7 71.35zM0 1l41 35L0 71V1z'/>\n </g>\n </svg>\n";function Mb(e){return(Mb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ub(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bb(e,t,n){return(Bb="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=zb(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Fb(e,t){return(Fb=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Vb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=zb(e);if(t){var i=zb(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Hb(this,n)}}function Hb(e,t){return!t||"object"!==Mb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function zb(e){return(zb=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var qb=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Fb(e,t)}(o,e);var t,n,r,i=Vb(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options_=t,n}return t=o,(n=[{key:"createEl",value:function(e,t,n){var r="<h1>".concat(this.options_.title,"</h1>");if(!this.options_.seriesName)return Bb(zb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n);var i=this.buildSeasonEpisodeString();return i?(r="<div class='cv-series-text'>".concat(this.options_.seriesName.toUpperCase()," ").concat(i,"</div>")+r,Bb(zb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n)):(r="<div class='cv-series-text'>".concat(this.options_.seriesName.toUpperCase(),"</div>")+r,Bb(zb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n))}},{key:"buildSeasonEpisodeString",value:function(){if(!this.options_.seasonNumber||!this.options_.episodeNumber)return"";var e=this.padNumber(this.options_.seasonNumber,2),t=this.padNumber(this.options_.episodeNumber,2);return"S".concat(e," • E").concat(t)}},{key:"padNumber",value:function(e,t){var n=e.toString();if(n.length>=t)return n;for(t-=n.length;t>0;)n="0"+n,t--;return n}}])&&Ub(t.prototype,n),r&&Ub(t,r),o}(Fu.getComponent("Component"));function Wb(e){return(Wb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function $b(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Gb(e,t,n){return(Gb="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Qb(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Yb(e,t){return(Yb=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Kb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Qb(e);if(t){var i=Qb(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Xb(this,n)}}function Xb(e,t){return!t||"object"!==Wb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Qb(e){return(Qb=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Jb=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Yb(e,t)}(o,e);var t,n,r,i=Kb(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options_=t,n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-splash-warning-container ".concat(Gb(Qb(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){var r=Gb(Qb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n);if(!this.options_.ratingCode)return r;var i=this.mapCodeToColourClass(this.options_.ratingCode);return r.appendChild(Fu.dom.createEl("div",{className:"cv-splash-rating badge rating-badge ".concat(i),innerHTML:this.options_.ratingCode})),this.options_.warning&&r.appendChild(Fu.dom.createEl("div",{className:"cv-splash-warning",innerHTML:this.options_.warning})),r}},{key:"mapCodeToColourClass",value:function(e){switch(e){case"E":return"bg-purple";case"G":return"bg-green";case"PG":return"bg-info";case"M":return"bg-red";case"MA15+":return"bg-pink";case"R18+":return"bg-yellow"}}}])&&$b(t.prototype,n),r&&$b(t,r),o}(Fu.getComponent("Component"));function Zb(e){return(Zb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function e_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function t_(e,t){return(t_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function n_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=i_(e);if(t){var i=i_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return r_(this,n)}}function r_(e,t){return!t||"object"!==Zb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function i_(e){return(i_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var o_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&t_(e,t)}(o,e);var t,n,r,i=n_(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"createEl",value:function(){var e=Fu.dom.createEl("div",{className:"cv-splash-metadata ".concat(this.options_.embed?"cv-embed-splash-metadata":"")});return this.options_.embed&&e.appendChild(new qb(this.player_,{title:this.options_.title,seriesName:this.options_.seriesName,seasonNumber:this.options_.seasonNumber,episodeNumber:this.options_.episodeNumber}).el()),e.appendChild(new Jb(this.player_,{warning:this.options_.warning,ratingCode:this.options_.ratingCode}).el()),e}}])&&e_(t.prototype,n),r&&e_(t,r),o}(Fu.getComponent("Component"));n(413);function a_(e){return(a_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u_(e,t,n){return(u_="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=h_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function l_(e,t){return(l_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h_(e);if(t){var i=h_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f_(this,n)}}function f_(e,t){return!t||"object"!==a_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h_(e){return(h_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l_(e,t)}(o,e);var t,n,r,i=c_(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addChild(new o_(n.player_,n.options_)),n}return t=o,(n=[{key:"createEl",value:function(e,t,n){var r="<div class='cv-player-mask'></div>";return this.options_.embed&&(r+="<div class='cv-embed-logo'>".concat(Nb,"</div>")),u_(h_(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass(),innerHTML:r}),n)}}])&&s_(t.prototype,n),r&&s_(t,r),o}(Fu.getComponent("Component"));function p_(e){return function(e){if(Array.isArray(e))return y_(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return y_(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return y_(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function y_(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var g_,v_=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},b_=Fu.getComponent("Player"),__=450,w_=function(){function e(t,n){var r=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.streamLogged=!1,this.options=Fu.mergeOptions({},e.options_,n),null===this.options.playerApi)throw new Error("PlayerApi required");this.initialize(),this.createEl(t),this.buildVideoJs(),this.bindEventListeners(),this.setupSeekBar(),this.fetchConfig(),this.logStream=this.logStream.bind(this),this.player.ready((function(){r._configurePlugins(),r.options.setup&&r.options.setup(r.options,r.player),r.options.startTime&&r.player.currentTime(r.options.startTime),r.fetch().catch((function(e){r.player.error(e.message),r.options.onError&&r.options.onError(e)}))}))}var t,n,r;return t=e,(n=[{key:"initialize",value:function(){}},{key:"_configurePlugins",value:function(){this.player.progressReporterPlugin({onFlush:this.onFlushProgress=this.onFlushProgress.bind(this)}),this.configurePlugins()}},{key:"configurePlugins",value:function(){}},{key:"onFlushProgress",value:function(e){var t;null===(t=this.analyticsService)||void 0===t||t.logVideoProgress(e)}},{key:"buildVideoJs",value:function(){return this.player=Fu(this.el,this.getPlayerOptions())}},{key:"getPlayerOptions",value:function(){return{controls:this.options.controls,autoplay:this.options.autoplay,fluid:!this.options.embed,fill:!!this.options.embed,inactivityTimeout:500,controlBar:{children:["timeWrapper","progressControl"]},children:[].concat(p_(b_.prototype.options_.children),["collapserator"]),userActions:{hotkeys:Kg},playbackRates:this.options.playbackRates,techOrder:["chromecast","html5"]}}},{key:"fetch",value:function(){return v_(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=this.options.fetch,void 0===this.options.fetch&&(t=function(e){var t="".concat(i.options.playerApi.origin,"/api/playback?viewKey=").concat(e);return sv.get(t)}),this.options.viewKey){e.next=4;break}throw new Error("Please specify a viewKey or a fetch function");case 4:return e.next=6,t(this.options.viewKey);case 6:if(n=e.sent){e.next=9;break}throw new Error("Error fetching playback object");case 9:n.chapters.list.length>0&&(r=this.player.addTextTrack("chapters"),n.chapters.list.forEach((function(e){r.addCue({startTime:e.timestamp,endTime:e.endTimestamp,text:e.name})})),r.trigger({type:"loadeddata",target:r})),this.player.progressiveFiles({sources:n.files.progressive.map((function(e){return{id:e.profile,mimeType:e.mimeType,url:e.url}}))}),n.subtitles.list.length>0&&(n.subtitles.list.forEach((function(e){"text/vtt"===e.mimeType&&i.player.addRemoteTextTrack({kind:"subtitles",src:e.url,language:e.language,label:e.label},!0)})),this.player.persistSubtitleSettingsPlugin({showSubtitles:n.settings.showSubtitles,subtitleSize:n.settings.playbackSubtitleSizeDefault})),n.posterUrl&&this.player.poster(n.posterUrl),this.setupSplash(n),this.options.showResources&&n.resources&&this.player.resourcesPlugin({resources:n.resources.list,imageCdnUrl:this.options.imageCdnUrl}),this.additionalSetup(n);case 16:case"end":return e.stop()}}),e,this)})))}},{key:"fetchConfig",value:function(){var e=this;if(!g_&&!this.options.fetch){var t="".concat(this.options.playerApi.origin,"/api/config");sv.get(t).then((function(t){g_=t,e.trigger("config:loaded")}))}}},{key:"additionalSetup",value:function(e){var t,n,r=this;this.player.localCache({localCacheAddresses:e.localCacheAddresses,enabled:null===(t=this.options.enableLocalCache)||void 0===t||t}),this.player.persistQualitySettingsPlugin({playbackProfile:e.settings.playbackProfile,playbackProfileLocalCache:e.settings.playbackProfileLocalCache}),this.player.whiteboardModePlugin(),this.player.chromecast({title:e.title});var i=this.options.enableLocalCache&&!!(null===(n=e.localCacheAddresses)||void 0===n?void 0:n.length);g_?this.setupAnalyticsService(e,i):this.one("config:loaded",(function(){return r.setupAnalyticsService(e,i)}))}},{key:"setupAnalyticsService",value:function(e,t){this.analyticsService=new Db({collectionApiUrls:g_.collectionApi.urls,collectionApiClientId:g_.collectionApi.clientId,productVersion:Ku.a,regionName:"cv-ap-southeast-1",videoId:e.videoId,userId:e.viewerId,customerId:e.viewerCustomerId,mediaType:e.mediaType,playerType:this.getAnalyticsPlayerType(),isEmbedded:!!this.options.embed,isUsingLocalCache:t}),this.on("timeupdate",this.logStream)}},{key:"logStream",value:function(){this.player.currentTime()<3||this.streamLogged||(this.analyticsService.logStream(),this.streamLogged=!0,this.off("timeupdate",this.logStream))}},{key:"getAnalyticsPlayerType",value:function(){return"player"}},{key:"createEl",value:function(e){var t;"string"==typeof e?(e=function(e){return 0===e.indexOf("#")?e.slice(1):e}(e),t=Fu.dom.$("#"+e)):t=e;var n="video-js";return this.getPlayerClassName()&&(n+=" ".concat(this.getPlayerClassName())),this.el=Fu.dom.createEl("video",{},{class:n}),t.appendChild(this.el),this.el}},{key:"getPlayerClassName",value:function(){return""}},{key:"on",value:function(e,t){this.player.on(e,t)}},{key:"one",value:function(e,t){this.player.one(e,t)}},{key:"off",value:function(e,t){this.player.off(e,t)}},{key:"trigger",value:function(e,t){return this.player.trigger(e,t)}},{key:"dispose",value:function(){this.player.dispose()}},{key:"ready",value:function(e){this.player.ready(e)}},{key:"play",value:function(){this.player.play()}},{key:"currentTime",value:function(e){return this.player.currentTime(e)}},{key:"bindEventListeners",value:function(){var e=this,t=function(){return e.configureMenuDimensions()};if(this.on("resize",t),this.on("fullscreenchange",t),this.one("play",t),this.on("resizemenus",t),this.player.on("dispose",(function(){e.off("resize",t),e.off("fullscreenchange",t),e.off("resizemenus",t)})),this.options.hotkeyElQuerySelector){var n=Fu.dom.$(this.options.hotkeyElQuerySelector);n&&(this.player.on(n,"keydown",this.player.handleKeyDown),this.player.on("dispose",(function(){e.player.off(n,"keydown",e.player.handleKeyDown)})))}}},{key:"setupSeekBar",value:function(){var e=this.getSeekBarName(),t=this.player.controlBar.getChild("progressControl");t.addChild(e,this.getSeekBarOptions()),t.setSeekBarName(e)}},{key:"setupSplash",value:function(e){var t=this.player.getChild("posterImage"),n=new d_(this.player,{embed:this.options.embed,posterUrl:e.posterUrl,title:e.title,ratingCode:e.ratingCode,seriesName:e.seriesName,seasonNumber:e.seasonNumber,episodeNumber:e.episodeNumber});t.addChild(n)}},{key:"getSeekBarOptions",value:function(){return{}}},{key:"getSeekBarName",value:function(){return"ChapterSeekBar"}},{key:"configureMenuDimensions",value:function(){var e=this;if(this.player.isFullscreen()){var t=this.player.whiteboardModePlugin().side;if("top"===t){var n=this.player.getChild("collapserator"),r=n.getChild("volumePanel"),i=n.children_.indexOf(r);n.removeChild(r),n.addChild("volumePanel",{inline:!1},i)}else{var o=this.player.getChild("collapserator"),a=o.getChild("volumePanel"),s=o.children_.indexOf(a);o.removeChild(a),o.addChild("volumePanel",{inline:!0},s)}if("left"===t||"right"===t||"top"===t){var u=this.player.currentWidth();return void this.player.el().querySelectorAll(".vjs-menu").forEach((function(e){e.style.paddingTop=null,e.style.marginBottom=null,e.style.width="calc(".concat(u,"px - 4em)")}))}}var l=this.player.currentWidth(),c=this.player.currentHeight()/l*100,f=this.player.el().querySelector(".cv-collapsorator"),h=this.player.el().querySelectorAll(".vjs-menu"),d=f&&f.offsetHeight;d?h&&h.length&&h.forEach((function(t){t.style.paddingTop="calc(".concat(c,"% - ").concat(d,"px)"),t.style.marginBottom="".concat(d,"px"),t.style.width=null,t.querySelector(".vjs-menu-content")&&(l<=__?e.player.addClass("cv-player-small"):e.player.removeClass("cv-player-small"))})):this.one("play",(function(){return e.configureMenuDimensions()}))}}])&&m_(t.prototype,n),r&&m_(t,r),e}();w_.options_={viewKey:null,controls:!0,playbackRates:[.5,1,1.5,2],playerApi:new URL("http://localhost:52000"),enableLocalCache:!0};n(414);function T_(e){return(T_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function S_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function E_(e,t,n){return(E_="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=O_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function C_(e,t){return(C_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function k_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=O_(e);if(t){var i=O_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return x_(this,n)}}function x_(e,t){return!t||"object"!==T_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function O_(e){return(O_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var P_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&C_(e,t)}(o,e);var t,n,r,i=k_(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"vjs-example-button ".concat(E_(O_(o.prototype),"buildCSSClass",this).call(this))}}])&&S_(t.prototype,n),r&&S_(t,r),o}(Fu.getComponent("Button"));P_.prototype.controlText_="Example Button",Fu.registerComponent("ExampleButton",P_);var R_=n(28),A_=n.n(R_);function I_(e){return(I_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function L_(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function D_(e,t,n){return t&&j_(e.prototype,t),n&&j_(e,n),e}function N_(e,t,n){return(N_="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=V_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function M_(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&U_(e,t)}function U_(e,t){return(U_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function B_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=V_(e);if(t){var i=V_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return F_(this,n)}}function F_(e,t){return!t||"object"!==I_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function V_(e){return(V_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var H_=function(e){M_(n,e);var t=B_(n);function n(e,r){return L_(this,n),t.call(this,e,r)}return D_(n,[{key:"dispose",value:function(){A_.a.unmountComponentAtNode(this.el()),N_(V_(n.prototype),"dispose",this).call(this)}}]),n}(Fu.getComponent("Component")),z_={tagName:"div"};function q_(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:z_;if(!e)throw new Error("componentCtor is required");var n=function(n){M_(i,n);var r=B_(i);function i(){return L_(this,i),r.apply(this,arguments)}return D_(i,[{key:"createEl",value:function(){var n=Fu.dom.createEl(t.tagName,t.properties,t.attributes);return A_.a.render(e(this.player_,this.options_),n),n}}]),i}(H_);return n}function W_(){return i.a.createElement("button",{style:{height:"100%",cursor:"pointer"},onClick:function(){return console.log("Clicked React Button")}},"React Button")}function $_(e){return($_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function G_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Y_(e,t){return(Y_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function K_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Q_(e);if(t){var i=Q_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return X_(this,n)}}function X_(e,t){return!t||"object"!==$_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Q_(e){return(Q_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("ExampleReactButton",q_((function(){return i.a.createElement(W_,null)})));var J_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Y_(e,t)}(o,e);var t,n,r,i=K_(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){this.player.getChild("collapserator").addChild("exampleReactButton")}}])&&G_(t.prototype,n),r&&G_(t,r),o}(Fu.getPlugin("plugin"));function Z_(e){return(Z_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ew(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function tw(e,t){return(tw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function nw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=iw(e);if(t){var i=iw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return rw(this,n)}}function rw(e,t){return!t||"object"!==Z_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function iw(e){return(iw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("examplePlugin",J_);var ow=Fu.getPlugin("plugin"),aw="cvplayer-mute",sw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tw(e,t)}(o,e);var t,n,r,i=nw(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).initialize(),t}return t=o,(n=[{key:"initialize",value:function(){var e=this;if(Ll()){this.player.on("volumechange",(function(){Dl("cvplayer-volume",e.player.volume().toString()),Dl(aw,e.player.muted().toString())}));var t=jl("cvplayer-volume"),n=jl(aw);t&&this.player.volume(+t),n&&this.player.muted("true"===n)}}}])&&ew(t.prototype,n),r&&ew(t,r),o}(ow);function uw(e){return(uw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function cw(e,t){return(cw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=pw(e);if(t){var i=pw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return hw(this,n)}}function hw(e,t){return!t||"object"!==uw(t)&&"function"!=typeof t?dw(e):t}function dw(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pw(e){return(pw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistVolumePlugin",sw);var yw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cw(e,t)}(o,e);var t,n,r,i=fw(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).hasScreenOrientation()&&t.player.supportsFullScreen()?(t.onRotate=t.onRotate.bind(dw(t)),t.onFullscreenChange=t.onFullscreenChange.bind(dw(t)),t.initialize(),t):hw(t)}return t=o,(n=[{key:"initialize",value:function(){var e=this;window.addEventListener("orientationchange",this.onRotate),this.hasScreenLock()&&this.player.on("fullscreenchange",this.onFullscreenChange),this.player.one("dispose",(function(){var t;window.removeEventListener("orientationchange",e.onRotate),e.hasScreenLock()&&(null===(t=e.player)||void 0===t||t.off("fullscreenchange",e.onFullscreenChange))}))}},{key:"onFullscreenChange",value:function(){!this.getAngle()&&this.player.isFullscreen()?window.screen.orientation.lock("portrait-primary"):window.screen.orientation.unlock()}},{key:"onRotate",value:function(){var e=this.getAngle();90===e||-90===e||270===e?this.player.requestFullscreen():this.player.isFullscreen()&&this.player.exitFullscreen()}},{key:"hasScreenOrientation",value:function(){var e,t;return"function"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.lock)}},{key:"hasScreenLock",value:function(){var e,t;return"function"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.lock)}},{key:"getAngle",value:function(){var e,t;return"number"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.angle)?window.screen.orientation.angle:0}}])&&lw(t.prototype,n),r&&lw(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("fullscreenOnRotatePlugin",yw);n(418);function mw(e){return(mw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function gw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function vw(e,t){return(vw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function bw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Tw(e);if(t){var i=Tw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _w(this,n)}}function _w(e,t){return!t||"object"!==mw(t)&&"function"!=typeof t?ww(e):t}function ww(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Tw(e){return(Tw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Sw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&vw(e,t)}(o,e);var t,n,r,i=bw(o);function o(e,t){var n,r,a,s;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).update=(r=n.update.bind(ww(n)),a=1e3,s=window.performance.now(),function(){var e=window.performance.now();e-s>=a&&(r.apply(void 0,arguments),s=e)}),e.on("timeupdate",n.update),e.on("dispose",(function(){e.off("timeupdate",n.update)})),n}return t=o,(n=[{key:"update",value:function(){var e=this.player_.currentTime();this.el_.href=this.options_.getExternalLink({currentTime:Math.round(e)})}},{key:"buildCSSClass",value:function(){return"cv-open-externally-button"}},{key:"createEl",value:function(){var e={innerHTML:Nb,className:this.buildCSSClass()},t={type:"button",href:this.options_.getExternalLink({currentTime:0}),target:"_blank"},n=Fu.dom.createEl("a",e,t);return this.createControlTextEl(n),n}}])&&gw(t.prototype,n),r&&gw(t,r),o}(Fu.getComponent("Button"));function Ew(e){return(Ew="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Cw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function kw(e,t){return(kw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function xw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Pw(e);if(t){var i=Pw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ow(this,n)}}function Ow(e,t){return!t||"object"!==Ew(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Pw(e){return(Pw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Sw.prototype.controlText_="Open in ClickView",Fu.registerComponent("OpenExternallyButton",Sw);var Rw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&kw(e,t)}(o,e);var t,n,r,i=xw(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){var e=this.player.getChild("collapserator"),t=e.getChild("customControlSpacer"),n=e.children_.indexOf(t);e.addChild("OpenExternallyButton",{getExternalLink:this.options.getExternalLink},n+1)}}])&&Cw(t.prototype,n),r&&Cw(t,r),o}(Fu.getPlugin("plugin"));function Aw(e){return(Aw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Iw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Lw(e,t){return(Lw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function jw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Mw(e);if(t){var i=Mw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Dw(this,n)}}function Dw(e,t){return!t||"object"!==Aw(t)&&"function"!=typeof t?Nw(e):t}function Nw(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Mw(e){return(Mw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("openExternallyPlugin",Rw);var Uw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Lw(e,t)}(o,e);var t,n,r,i=jw(o);function o(e,t){var n;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e),void 0===t.startTime)throw Error("Invalid clip start");if(void 0===t.endTime)throw Error("Invalid clip end");if(t.startTime>t.endTime)throw Error("Clip start cannot be greater than clip end");return n._clipStart=t.startTime,n._clipEnd=t.endTime,n.playerEndedFn=n.player.ended.bind(e),n.playerDurationFn=n.player.duration.bind(e),n.playerCurrentTimeFn=n.player.currentTime.bind(e),n.playerbufferedFn=n.player.buffered.bind(e),n.player.ended=n.ended.bind(Nw(n)),n.player.duration=n.duration.bind(Nw(n)),n.player.currentTime=n.currentTime.bind(Nw(n)),n.player.buffered=n.buffered.bind(Nw(n)),n.initialize(),n.player.ready((function(){n.player.trigger("durationchange")})),n}return t=o,(n=[{key:"clipStart",get:function(){var e=this.playerDurationFn();return this._clipStart>e?e:this._clipStart}},{key:"clipEnd",get:function(){var e=this.playerDurationFn();return this._clipEnd>e?e:this._clipEnd}},{key:"dispose",value:function(){this.player.off("timeupdate",this.onTimeUpdate),this.player.off("play",this.onPlay),this.player.ended=this.playerEndedFn,this.player.duration=this.playerDurationFn,this.player.currentTime=this.playerCurrentTimeFn,this.player.buffered=this.playerbufferedFn,this.player.trigger("durationchange")}},{key:"initialize",value:function(){var e=this;this.onTimeUpdate=this.onTimeUpdate.bind(this),this.onPlay=this.onPlay.bind(this),this.player.on("timeupdate",this.onTimeUpdate),this.player.on("play",this.onPlay),this.player.on("dispose",(function(){e.dispose()}))}},{key:"onPlay",value:function(){this._isEnded&&this.player.currentTime(0)}},{key:"onTimeUpdate",value:function(){var e=this.getCurrentTime(!1);e>this.clipEnd?this._isEnded||(this.player.pause(),this.player.trigger("ended"),this._isEnded=!0):(this._isEnded=!1,e<this.clipStart&&this.playerCurrentTimeFn(this.clipStart))}},{key:"ended",value:function(){return this.getCurrentTime(!1)>this.clipEnd}},{key:"duration",value:function(e){return void 0!==e&&this.playerDurationFn(e),this.clipEnd-this.clipStart}},{key:"currentTime",value:function(e){if(void 0===e)return this.getCurrentTime(!0);for(var t=e+this.clipStart,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];this.playerCurrentTimeFn.apply(this,[t].concat(r))}},{key:"getCurrentTime",value:function(e){var t=this.playerCurrentTimeFn(),n=0;return t>=this.clipStart&&(n=t-this.clipStart),this.player.getCache().currentTime=n,e?n:t}},{key:"buffered",value:function(){for(var e=this.playerbufferedFn(),t=[],n=0;n<e.length;n++)t[n]=[Math.max(0,e.start(n)-this.clipStart),Math.min(Math.max(0,e.end(n)-this.clipStart),this.player.duration())];return Fu.createTimeRanges(t)}}])&&Iw(t.prototype,n),r&&Iw(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("clipPlugin",Uw);n(419);function Bw(e){return(Bw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Fw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Vw(e,t,n){return(Vw="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Ww(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Hw(e,t){return(Hw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ww(e);if(t){var i=Ww(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qw(this,n)}}function qw(e,t){return!t||"object"!==Bw(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ww(e){return(Ww=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var $w=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hw(e,t)}(o,e);var t,n,r,i=zw(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-touch-control-ui ".concat(Vw(Ww(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Vw(Ww(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"setUi",value:function(e,t){var n=this,r=e>0,i=r?"cv-touch-right":"cv-touch-left";this.el_.className=this.buildCSSClass()+" cv-ui-touch-active",this.el_.innerHTML="\n <div class='".concat(i,"'>\n <div class='cv-touch-text'>\n ").concat(r?"+":"").concat(10*e,"s\n </div>\n </div>\n "),window.clearTimeout(this.timeoutId),this.timeoutId=window.setTimeout((function(){n.removeText()}),t)}},{key:"removeText",value:function(){this.el_.className=this.buildCSSClass(),this.el_.innerHTML=""}}])&&Fw(t.prototype,n),r&&Fw(t,r),o}(Fu.getComponent("component"));function Gw(e){return(Gw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Yw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Kw(e,t){return(Kw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Jw(e);if(t){var i=Jw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qw(this,n)}}function Qw(e,t){return!t||"object"!==Gw(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jw(e){return(Jw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("TouchControls",$w);var Zw=Fu.getPlugin("plugin"),eT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Kw(e,t)}(o,e);var t,n,r,i=Xw(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).doubleTouchCount=0,t.seekStartTime=0,t.directionModifier=0,t.bindFunctions(),t.initialize(),t}return t=o,(n=[{key:"bindFunctions",value:function(){this.onTouchStart=this.onTouchStart.bind(this),this.onTouchEnd=this.onTouchEnd.bind(this),this.reBindEventListeners=this.reBindEventListeners.bind(this),this.unBindEventListeners=this.unBindEventListeners.bind(this)}},{key:"initialize",value:function(){this.player.addChild("TouchControls"),this.touchControls=this.player.getChild("TouchControls"),this.player.on("ready",this.reBindEventListeners),this.player.on("dispose",this.unBindEventListeners),this.reBindEventListeners()}},{key:"reBindEventListeners",value:function(){this.tech=this.player.tech(!0),"Html5"===this.tech.name()&&(this.on(this.tech,"touchstart",this.onTouchStart),this.on(this.tech,"touchend",this.onTouchEnd))}},{key:"unBindEventListeners",value:function(){this.tech&&(this.off(this.tech,"touchstart",this.onTouchStart),this.off(this.tech,"touchend",this.onTouchEnd))}},{key:"onTouchStart",value:function(e){this.touchStartTime=e.timeStamp}},{key:"onTouchEnd",value:function(e){var t=this;if(e.changedTouches.length){if(e.timeStamp-this.lastTouchTime<300)return this.onDoubleTouch(e),void(this.lastTouchTime=e.timeStamp);this.resetProperties(),this.lastTouchTime=e.timeStamp,e.timeStamp-this.touchStartTime<300&&window.setTimeout((function(){t.doubleTouchCount||(t.player.paused()?t.player.play():t.player.pause())}),300)}}},{key:"resetProperties",value:function(){this.doubleTouchCount=0,this.seekStartTime=0,this.directionModifier=0}},{key:"onDoubleTouch",value:function(e){var t=this.player.el().getBoundingClientRect(),n=t.left+t.width/2;if(0===this.doubleTouchCount&&(this.seekStartTime=this.player.currentTime(),e.changedTouches[0].pageX<n?this.directionModifier=-1:this.directionModifier=1),this.doubleTouchCount++,this.directionModifier<0){if(10*this.doubleTouchCount>this.seekStartTime+10)return;return this.touchControls.setUi(-this.doubleTouchCount,900),void this.player.currentTime(this.player.currentTime()-10)}var r=this.player.duration()-this.seekStartTime;10*this.doubleTouchCount>r+10||(this.touchControls.setUi(this.doubleTouchCount,900),this.player.currentTime(this.player.currentTime()+10))}}])&&Yw(t.prototype,n),r&&Yw(t,r),o}(Zw);Fu.registerPlugin("touchControls",eT);n(420);function tT(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return nT(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nT(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function nT(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function rT(e){var t,n=tT(r.useState(105),2),i=n[0],o=n[1],a=r.useRef(e.player.duration()-e.player.currentTime()),s=tT(r.useState(a.current),2),u=s[0],l=s[1];function c(){var t=e.player.el().querySelector(".vjs-control-bar"),n=null==t?void 0:t.offsetHeight;isNaN(n)||o(n+15)}function f(){var t=e.player.duration()-e.player.currentTime();l(t),t>a.current&&(a.current=t)}if(r.useEffect((function(){return c(),e.player.on("resize",c),e.player.on("fullscreenchange",c),e.player.on("timeupdate",f),function(){e.player.off("resize",c),e.player.off("fullscreenchange",c),e.player.off("timeupdate",f)}}),[]),!e.nextVideo||!e.onPlayNext)return r.createElement(r.Fragment,null);var h=(a.current-u)/a.current*100,d=Math.ceil(u),p=1===d?"second":"seconds";return r.createElement("div",{className:"cv-up-next-container rounded",style:{bottom:"".concat(i,"px")}},r.createElement("div",{className:"cv-up-next-progress-bar rounded",style:{width:"".concat(h,"%")}}),r.createElement("div",{className:"row no-gutters"},r.createElement("div",{className:"col-6"},r.createElement("div",{className:"cv-up-next-thumbnail-container",onClick:e.onPlayNext},r.createElement("div",{className:"cv-up-next-thumbnail-mask"},r.createElement("div",{className:"position-relative w-100 h-100"},r.createElement("div",{className:"cv-up-next-play-icon-container"},r.createElement("div",{className:"position-relative w-100 h-100"},r.createElement("span",{className:"cv-up-next-play-icon"}))))),r.createElement("img",{className:"img-fluid",src:null===(t=e.nextVideo)||void 0===t?void 0:t.thumbnailUrl}))),r.createElement("div",{className:"col-5 pl-2 pt-2"},r.createElement("p",null,"Up next in ",d," ",p),r.createElement("p",null,e.nextVideo.name)),r.createElement("div",{className:"col-1 pr-1"},r.createElement("div",{className:"close cv-cancel-up-next cursor-pointer",role:"button",onClick:e.onCancel},"×"))))}function iT(e){return(iT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function oT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function aT(e,t){return(aT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function sT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=cT(e);if(t){var i=cT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return uT(this,n)}}function uT(e,t){return!t||"object"!==iT(t)&&"function"!=typeof t?lT(e):t}function lT(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cT(e){return(cT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("UpNext",q_((function(e,t){return r.createElement(rT,Object.assign({player:e},t))})));var fT=Fu.getPlugin("plugin"),hT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&aT(e,t)}(o,e);var t,n,r,i=sT(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).setShouldPlayNext=t.setShouldPlayNext.bind(lT(t)),t.getShouldPlayNext=t.getShouldPlayNext.bind(lT(t)),t.setChapterTrack=t.setChapterTrack.bind(lT(t)),t.onTimeUpdate=t.onTimeUpdate.bind(lT(t)),e.ready((function(){t.initialize()})),t}return t=o,(n=[{key:"initialize",value:function(){this.player.isDisposed()||(this.hasLocalStorage=this.testHasLocalStorage(),Ad(this.player,"chapters",null,this.setChapterTrack),this.bindListeners())}},{key:"setNextVideo",value:function(e,t){var n;this.player.isDisposed()||(this.nextVideo=e,this.callback=t,(null===(n=this.player.getChild("collapserator"))||void 0===n?void 0:n.getChild("cogButton")).showPlayNext())}},{key:"getShouldPlayNext",value:function(){if(!this.hasLocalStorage)return void 0===this.shouldPlayNextVideo&&(this.shouldPlayNextVideo=!0),this.shouldPlayNextVideo;var e=window.localStorage.getItem("cv-play-next-video");return null===e||"true"===e}},{key:"setShouldPlayNext",value:function(e){this.hasLocalStorage?window.localStorage.setItem("cv-play-next-video",e.toString()):this.shouldPlayNextVideo=e}},{key:"setChapterTrack",value:function(e){this.chapterTrack=e}},{key:"bindListeners",value:function(){this.player.on("timeupdate",this.onTimeUpdate)}},{key:"unbindListeners",value:function(){this.player.off("timeupdate",this.onTimeUpdate)}},{key:"onTimeUpdate",value:function(){var e,t,n,r;if(!this.player.pictureInPicture||!this.player.isInPictureInPicture())if(this.getShouldPlayNext()){if(this.player.ended())return this.callback(),void this.hideUpNext();this.upNextRendered&&this.player.currentTime()>this.upNextTimepoint||("credits"===(null===(r=null===(n=(null===(t=null===(e=this.chapterTrack)||void 0===e?void 0:e.activeCues)||void 0===t?void 0:t.length)&&this.chapterTrack.activeCues[0])||void 0===n?void 0:n.text)||void 0===r?void 0:r.toLowerCase())||this.player.currentTime()>=this.player.duration()-5?this.showUpNext():this.hideUpNext())}else this.hideUpNext()}},{key:"showUpNext",value:function(){var e=this;this.upNextRendered||(this.upNextRendered=!0,this.upNextTimepoint=this.player.currentTime(),this.player.addChild("UpNext",{nextVideo:this.nextVideo,onPlayNext:this.callback,onCancel:function(){e.hideUpNext(),e.setShouldPlayNext(!1)}}))}},{key:"hideUpNext",value:function(){if(this.upNextRendered){this.upNextRendered=!1,this.upNextTimepoint=null;var e=this.player.getChild("UpNext");e&&this.player.removeChild(e)}}},{key:"testHasLocalStorage",value:function(){try{return window.localStorage.setItem("cv-persisttest","persistVolume"),window.localStorage.removeItem("cv-persisttest"),!0}catch(e){return!1}}}])&&oT(t.prototype,n),r&&oT(t,r),o}(fT);Fu.registerPlugin("nextVideoPlugin",hT);n(421);function dT(e){return(dT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function pT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mT(e,t,n){return(mT="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=_T(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function gT(e,t){return(gT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function vT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_T(e);if(t){var i=_T(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return bT(this,n)}}function bT(e,t){return!t||"object"!==dT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _T(e){return(_T=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var wT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&gT(e,t)}(o,e);var t,n,r,i=vT(o);function o(){var e;return pT(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-create-clip-button"}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){mT(_T(o.prototype),"handleClick",this).call(this,null)}}])&&yT(t.prototype,n),r&&yT(t,r),o}(Fu.getComponent("Button"));function TT(e){return(TT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ST(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ET(e,t){return(ET=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function CT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=xT(e);if(t){var i=xT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kT(this,n)}}function kT(e,t){return!t||"object"!==TT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function xT(e){return(xT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}wT.prototype.controlText_="Create Clip",Fu.registerComponent("CreateClipButton",wT);var OT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ET(e,t)}(o,e);var t,n,r,i=CT(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){var e,t=this.player.getChild("collapserator"),n=null===(e=null==t?void 0:t.children())||void 0===e?void 0:e.findIndex((function(e){return"CustomControlSpacer"===e.name()}));n&&-1!==n&&t.addChild("CreateClipButton",{clickHandler:this.options.onClick},n+1)}}])&&ST(t.prototype,n),r&&ST(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("createClipButtonPlugin",OT);var PT,RT=n(4),AT=function(e,t){if(e){var n=e;return e.endsWith("/")||(n+="/"),t?n+=t.startsWith("/")?t.slice(1):t:n}},IT=n(204),LT=n(41),jT=n(12);function DT(e){return(DT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function NT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function UT(e,t){return(UT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function BT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=VT(e);if(t){var i=VT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return FT(this,n)}}function FT(e,t){return!t||"object"!==DT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function VT(e){return(VT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}!function(e){e.Analytics="AnalyticsService",e.Context="ContextService"}(PT||(PT={}));var HT,zT=new(function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&UT(e,t)}(o,e);var t,n,r,i=BT(o);function o(){var e;return NT(this,o),(e=i.apply(this,arguments)).contextHistory=[],e}return t=o,r=[{key:"Instance",get:function(){return this.instance||(this.instance=new this)}}],(n=[{key:"name",get:function(){return PT.Context}},{key:"initialize",value:function(){this.listenTo(jT.a.SHELL,IT.EventNames.ROUTE,this.setContext)}},{key:"setContext",value:function(e){this.contextHistory.length>=5&&this.contextHistory.unshift(),this.contextHistory.push({pageLoad:!this.contextHistory.length,appLink:e})}},{key:"getCurrentContext",value:function(){if(this.contextHistory.length)return this.contextHistory[this.contextHistory.length-1]}},{key:"fromPageLoad",value:function(){return 1===this.contextHistory.length}}])&&MT(t.prototype,n),r&&MT(t,r),o}(IT.Service)),qT=n(10);!function(e){e.Inlet="event:inlet",e.Outlet="event:outlet"}(HT||(HT={}));var WT="global:analytics";function $T(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var GT=pb.EventVersion.V1,YT=function(){function e(t,n,r,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.type=t,this.data=n,this.actionContext=r,this.eventVersion=i||GT}var t,n,r;return t=e,(n=[{key:"isType",value:function(e){return e===this.type}},{key:"enrich",value:function(e,t){this.validateKey(e),this[e]=t}},{key:"get",value:function(e){if(e&&this[e])return this[e]}},{key:"validateKey",value:function(e){"type"!==e&&"data"!==e||IT.ErrorHelper.throw(new LT.a("".concat(e," is not a valid key"))),this[e]&&IT.ErrorHelper.throw(new LT.a("Event already contains an enrichment named ".concat(e)))}}])&&$T(t.prototype,n),r&&$T(t,r),e}(),KT=function(e,t,n,r){qT.Radio.channel(WT).trigger(HT.Inlet,new YT(e,t,n,r))};function XT(){var e=zT.getCurrentContext().appLink;return RT.isObject(e)||IT.ErrorHelper.throw(new LT.a("Applink does not exist. Check current context.")),e.application.replace(":","-")}function QT(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.location,n=e.entity,r=e.workflowPhase,i=void 0===r?null:r,o=e.descriptor,a=void 0===o?null:o;return t||IT.ErrorHelper.throw(new LT.a("location must be set.")),n||IT.ErrorHelper.throw(new LT.a("entity must be set.")),{productArea:XT(),location:t,entity:n,descriptor:a,workflowPhase:i}}function JT(){return IT.LocationUtils.GetCurrentPath()+IT.LocationUtils.GetCurrentQueryString()}var ZT={logUserAction:function(e,t){if(function(e){return!(!RT.isArray(e)||!RT.every(e,(function(e){return RT.isObject(e)})))||!!RT.isObject(e)}(e)&&RT.isObject(t)){var n=ZT.buildUserActionEvent(t),r=n.userAction,i=n.action,o=n.eventVersion;KT(r,e,i,o)}},logNavigate:function(e,t){var n=Object.assign({currentLocation:JT(),appLink:e},t);KT(pb.UserAction.Navigate,n)},mergeOptions:function(e,t){return RT.extend({},e,t)},buildActionContext:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return QT(e)},buildUserActionEvent:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.actionType,n=e.eventVersion,r=t,i=QT(e);return{userAction:r,action:i,eventVersion:n}},buildCurrentLocation:function(){return JT()},buildSearchEvent:function(e,t){return{data:{query:e},action:QT({entity:pb.EntityType.Video,location:pb.LocationContext.SearchBar,descriptor:t})}},buildInstantSearchEvent:function(e,t,n){var r;n===pb.SearchQueryType.Series&&(r=pb.EntityType.Series),n===pb.SearchQueryType.Folder&&(r=pb.EntityType.Folder),n===pb.SearchQueryType.Tags&&(r=pb.EntityType.Tag),n===pb.SearchQueryType.Video&&(r=pb.EntityType.Video),n===pb.SearchQueryType.Subjects&&(r=pb.EntityType.Classification);var i={instant:{},query:e};return t.id&&(i.instant.selectedId=t.id),t.name&&(i.instant.selectedName=t.name),{data:i,action:QT({entity:r,location:pb.LocationContext.SearchBar})}},mapInteractionType:function(e){switch(e){case pb.InteractionType.DragDrop:return pb.InteractionTypeDescriptor.DragDrop;case pb.InteractionType.FileSelect:return pb.InteractionTypeDescriptor.FileSelect;default:return}}};function eS(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return tS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return tS(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var nS={isEmpty:function(e){return RT.isEmpty(e)},values:function(e){return RT.values(e)},keys:function(e){return RT.keys(e)},deepClone:function(e){return(RT.isArray(e)?RT.map:RT.mapObject)(e,(function(e){return RT.isObject(e)||RT.isArray(e)?nS.deepClone(e):e}))},getEnumKeys:function(e){return Object.keys(e).filter((function(e){return!(parseInt(e)>=0)}))},isObject:function(e){return RT.isObject(e)},isEqual:function(e,t){return RT.isEqual(e,t)},omit:function(e,t){return RT.omit(e,t)},removeEmptyKeys:function(e){return Object.entries(e).filter((function(e){return null!==eS(e,2)[1]})).reduce((function(e,t){var n=eS(t,2),r=n[0],i=n[1];return Object.assign(Object.assign({},e),function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},r,i))}),{})}};var rS=function(e,t){if(!e)throw new Error("Invariant failed")};function iS(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oS(){return(oS=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function aS(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var sS=new Map,uS=new Map,lS=new Map,cS=0;function fS(e,t,n){void 0===n&&(n={}),n.threshold||(n.threshold=0);var r=n,i=r.root,o=r.rootMargin,a=r.threshold;if(sS.has(e)&&rS(!1),e){var s=function(e){return e?lS.has(e)?lS.get(e):(cS+=1,lS.set(e,cS.toString()),lS.get(e)+"_"):""}(i)+(o?a.toString()+"_"+o:a.toString()),u=uS.get(s);u||(u=new IntersectionObserver(dS,n),s&&uS.set(s,u));var l={callback:t,element:e,inView:!1,observerId:s,observer:u,thresholds:u.thresholds||(Array.isArray(a)?a:[a])};return sS.set(e,l),u.observe(e),l}}function hS(e){if(e){var t=sS.get(e);if(t){var n=t.observerId,r=t.observer,i=r.root;r.unobserve(e);var o=!1,a=!1;n&&sS.forEach((function(t,r){r!==e&&(t.observerId===n&&(o=!0,a=!0),t.observer.root===i&&(a=!0))})),!a&&i&&lS.delete(i),r&&!o&&r.disconnect(),sS.delete(e)}}}function dS(e){e.forEach((function(e){var t=e.isIntersecting,n=e.intersectionRatio,r=e.target,i=sS.get(r);if(i&&n>=0){var o=i.thresholds.some((function(e){return i.inView?n>e:n>=e}));void 0!==t&&(o=o&&t),i.inView=o,i.callback(o,e)}}))}var pS=function(e){var t,n;function i(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return iS(aS(t=e.call.apply(e,[this].concat(r))||this),"state",{inView:!1,entry:void 0}),iS(aS(t),"node",null),iS(aS(t),"handleNode",(function(e){t.node&&hS(t.node),t.node=e||null,t.observeNode()})),iS(aS(t),"handleChange",(function(e,n){(e!==t.state.inView||e)&&t.setState({inView:e,entry:n}),t.props.onChange&&t.props.onChange(e,n)})),t}n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=i.prototype;return o.componentDidMount=function(){this.node||rS(!1)},o.componentDidUpdate=function(e,t){e.rootMargin===this.props.rootMargin&&e.root===this.props.root&&e.threshold===this.props.threshold||(hS(this.node),this.observeNode()),t.inView!==this.state.inView&&this.state.inView&&this.props.triggerOnce&&(hS(this.node),this.node=null)},o.componentWillUnmount=function(){this.node&&(hS(this.node),this.node=null)},o.observeNode=function(){if(this.node){var e=this.props,t=e.threshold,n=e.root,r=e.rootMargin;fS(this.node,this.handleChange,{threshold:t,root:n,rootMargin:r})}},o.render=function(){var e=this.state,t=e.inView,n=e.entry;if(!function(e){return"function"!=typeof e.children}(this.props))return this.props.children({inView:t,entry:n,ref:this.handleNode});var i=this.props,o=i.children,a=i.as,s=i.tag,u=(i.triggerOnce,i.threshold,i.root,i.rootMargin,i.onChange,function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(i,["children","as","tag","triggerOnce","threshold","root","rootMargin","onChange"]));return Object(r.createElement)(a||s||"div",oS({ref:this.handleNode},u),o)},i}(r.Component);iS(pS,"displayName","InView"),iS(pS,"defaultProps",{threshold:0,triggerOnce:!1});function yS(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return mS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return mS(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function mS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gS(e){var t=yS(function(e){void 0===e&&(e={});var t=Object(r.useRef)(),n=Object(r.useState)({inView:!1,entry:void 0}),i=n[0],o=n[1],a=Object(r.useCallback)((function(n){t.current&&hS(t.current),n&&fS(n,(function(t,r){o({inView:t,entry:r}),t&&e.triggerOnce&&hS(n)}),e),t.current=n}),[e.threshold,e.root,e.rootMargin,e.triggerOnce]);return Object(r.useDebugValue)(i.inView),[a,i.inView,i.entry]}({triggerOnce:!0}),2),n=t[0],i=t[1];return!0!==e&&void 0!==window.IntersectionObserver||(i=!0,n=null),{ref:n,inView:i}}var vS,bS,_S,wS,TS,SS,ES=n(144),CS=n.n(ES),kS=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},xS=r.memo((function(e){var t=e.forceLoad,n=e.extraClasses,i=void 0===n?"":n,o=kS(e,["forceLoad","extraClasses"]),a=gS(),s=a.ref,u=a.inView;if(!s)return r.createElement("img",Object.assign({className:"".concat(CS.a.image," ").concat(i),alt:""},o));var l=o.src,c=kS(o,["src"]),f=Object.assign(Object.assign({alt:""},c),u||t?{src:l}:{});return t||(f.ref=s),r.createElement("img",Object.assign({className:"".concat(CS.a.image," ").concat(i)},f))}));function OS(e){var t=e.appLink,n=e.appLinkOptions,i=e.className,o=e.style,a=e.children,s=e.tag,u=void 0===s?"a":s;if(!t)return r.createElement("span",{className:i||""},a);var l=IT.AppLinkHelper.getHref(t),c={onClick:function(r){var i;r.preventDefault(),null===(i=e.onClick)||void 0===i||i.call(e,r),e.analyticsData&&e.analyticsOptions&&ZT.logUserAction(Object.assign({href:l},e.analyticsData),e.analyticsOptions),IT.AppLinkHelper.trigger(t,n)},href:l,className:i,style:o};return e.title&&(c.title=e.title),r.createElement(u,Object.assign({},c),a)}function PS(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}OS.defaultProps={appLinkOptions:{}},function(e){e.Small="small",e.Medium="medium",e.Large="large"}(vS||(vS={})),function(e){e[e.Thumbnails=0]="Thumbnails",e[e.Banners=1]="Banners",e[e.Avatars=2]="Avatars",e[e.Logos=3]="Logos",e[e.Covers=4]="Covers",e[e.Posters=5]="Posters",e[e.TallPosters=6]="TallPosters",e[e.HeroBanners=7]="HeroBanners",e[e.None=99999]="None"}(bS||(bS={})),function(e){e[e.Crop=0]="Crop",e[e.Stretched=1]="Stretched",e[e.Cover=2]="Cover"}(_S||(_S={})),function(e){e[e.None=0]="None",e[e.ImageAPIv1=1]="ImageAPIv1",e[e.FileAPIv1=2]="FileAPIv1",e[e.ImageAPIv2=3]="ImageAPIv2"}(wS||(wS={})),function(e){e.Banner="banner",e.Thumbnail="thumbnail"}(SS||(SS={}));var RS,AS,IS=(PS(TS={},bS.Banners,SS.Banner),PS(TS,bS.Thumbnails,SS.Thumbnail),TS),LS=function(e){return"/v1/category-map/".concat(e)},jS={createUrl:function(e,t){return jS._createUrl(e,t)},createBannerUrl:function(e,t,n){return e&&e.url?jS._createUrl(e.url,n):jS._createCategoryMappedUrl(t,n)},createResourceImage:function(e,t,n){return jS._createUrl(e,Object.assign({url:t},n))},Rfc3986EncodeURIComponent:function(e){return encodeURIComponent(e).replace(/[!'()*]/g,escape)},_createCategoryMappedUrl:function(e,t){var n=e.fallbackBaseUrl,r=e.fallbackCategoryName,i=e.type,o=AT(n,"".concat(LS(IS[i]))),a=Object.assign({name:jS.Rfc3986EncodeURIComponent(r)},t);return jS._createUrl(o,a)},_createUrl:function(e,t){if(e){if(nS.isEmpty(t))return e;var n=$.param(t),r=-1===e.indexOf("?")?"?":"&",i=e;return i.endsWith("/")&&(i=i.slice(0,-1)),i+"".concat(r).concat(n)}},legacyCreateThumbnailUrl:function(e,t){if(!e)return"";var n;if(e&&(n=e instanceof IT.Model?e.get("url"):"string"==typeof e?e:e.url)){var r=Object.assign({size:vS.Small,bgColor:"000"},t);return jS._createUrl(n,r)}}},DS=n(72),NS=n.n(DS);function MS(e){var t="thumbnail ".concat(NS.a.thumbnail),n="";return e.aspectRatio===RS.SixteenByNine&&(n=NS.a.sixteenByNine),e.aspectRatio===RS.NineBySixteen&&(n=NS.a.nineBySixteen),e.aspectRatio===RS.OneByOne&&(n=NS.a.oneByOne),e.aspectRatio===RS.TwoByThree&&(n=NS.a.twoByThree),n&&(t+=" ".concat(n)),e.className&&(t+=" ".concat(e.className)),t}function US(e){var t=e.data,n=e.imageOptions,i=e.appLink,o=e.preload,a=e.analyticsOptions,s=e.analyticsData,u=e.imageClassName,l="";"string"==typeof t?l=t:nS.isObject(t)&&(l=t.url);var c=l&&n?jS.createUrl(l,n):l;return r.createElement("div",{className:MS(e),style:e.imageStyle},i?r.createElement(OS,{appLink:i,analyticsData:s,analyticsOptions:a},e.children,c&&r.createElement(xS,{src:c,forceLoad:o,extraClasses:u,onError:e.onImageLoadError||function(){}})):r.createElement(r.Fragment,null,e.children,c&&r.createElement(xS,{src:c,forceLoad:o,extraClasses:u,onError:e.onImageLoadError||function(){}})))}function BS(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return FS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return FS(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function FS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function VS(e){var t=BS(Object(r.useState)(window.matchMedia(e).matches),2),n=t[0],i=t[1];return Object(r.useEffect)((function(){var t=window.matchMedia(e);t.matches!==n&&i(t.matches);var r=function(){return i(t.matches)};return t.addListener(r),function(){return t.removeListener(r)}}),[e]),n}!function(e){e[e.SixteenByNine=0]="SixteenByNine",e[e.OneByOne=1]="OneByOne",e[e.TwoByThree=2]="TwoByThree",e[e.NineBySixteen=3]="NineBySixteen"}(RS||(RS={})),function(e){e.XS="(max-width: 575px)",e.SM="(min-width: 576px) and (max-width: 767px)",e.MD="(min-width: 768px) and (max-width: 991px)",e.LG="(min-width: 992px)",e.XL="(min-width: 1200px)",e.XXL="(min-width: 1440px)",e.SMDown="(max-width: 576px)",e.MDDown="(max-width: 768px)",e.LGDown="(max-width: 992px)",e.XLDown="(max-width: 1200px)"}(AS||(AS={}));var HS=n(24),zS=n(40),qS=n(84),WS=n(137),$S=n.n(WS),GS=(n(106),n(70)),YS=n.n(GS),KS=n(239),XS=n.n(KS),QS=(n(68),!1),JS=i.a.createContext(null),ZS=function(e){function t(t,n){var r;r=e.call(this,t,n)||this;var i,o=n&&!n.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?o?(i="exited",r.appearStatus="entering"):i="entered":i=t.unmountOnExit||t.mountOnEnter?"unmounted":"exited",r.state={status:i},r.nextCallback=null,r}Object(qS.a)(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&"unmounted"===t.status?{status:"exited"}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?"entering"!==n&&"entered"!==n&&(t="entering"):"entering"!==n&&"entered"!==n||(t="exiting")}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},n.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=A_.a.findDOMNode(this);"entering"===t?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&"exited"===this.state.status&&this.setState({status:"unmounted"})},n.performEnter=function(e,t){var n=this,r=this.props.enter,i=this.context?this.context.isMounting:t,o=this.getTimeouts(),a=i?o.appear:o.enter;!t&&!r||QS?this.safeSetState({status:"entered"},(function(){n.props.onEntered(e)})):(this.props.onEnter(e,i),this.safeSetState({status:"entering"},(function(){n.props.onEntering(e,i),n.onTransitionEnd(e,a,(function(){n.safeSetState({status:"entered"},(function(){n.props.onEntered(e,i)}))}))})))},n.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n&&!QS?(this.props.onExit(e),this.safeSetState({status:"exiting"},(function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,(function(){t.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))}))}))):this.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))},n.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t,n){this.setNextCallback(n);var r=null==t&&!this.props.addEndListener;e&&!r?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},n.render=function(){var e=this.state.status;if("unmounted"===e)return null;var t=this.props,n=t.children,r=Object(zS.a)(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return i.a.createElement(JS.Provider,{value:null},n(e,r));var o=i.a.Children.only(n);return i.a.createElement(JS.Provider,{value:null},i.a.cloneElement(o,r))},t}(i.a.Component);function eE(){}ZS.contextType=JS,ZS.propTypes={},ZS.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:eE,onEntering:eE,onEntered:eE,onExit:eE,onExiting:eE,onExited:eE},ZS.UNMOUNTED=0,ZS.EXITED=1,ZS.ENTERING=2,ZS.ENTERED=3,ZS.EXITING=4;var tE,nE=ZS,rE=n(242),iE=n.n(rE);var oE=((tE={}).entering="show",tE.entered="show",tE),aE=i.a.forwardRef((function(e,t){var n=e.className,o=e.children,a=Object(zS.a)(e,["className","children"]),s=Object(r.useCallback)((function(e){!function(e){e.offsetHeight}(e),a.onEnter&&a.onEnter(e)}),[a]);return i.a.createElement(nE,Object(HS.a)({ref:t,addEndListener:iE.a},a,{onEnter:s}),(function(e,t){return i.a.cloneElement(o,Object(HS.a)({},t,{className:YS()("fade",n,o.props.className,oE[e])}))}))}));aE.defaultProps={in:!1,timeout:300,mountOnEnter:!1,unmountOnExit:!1,appear:!1},aE.displayName="Fade";var sE=aE,uE={transition:sE,rootClose:!1,show:!1,placement:"top"};function lE(e){var t=e.children,n=e.transition,r=Object(zS.a)(e,["children","transition"]);return n=!0===n?sE:n||null,i.a.createElement(XS.a,Object(HS.a)({},r,{transition:n}),(function(e){var r=e.props,o=e.arrowProps,a=e.show,s=Object(zS.a)(e,["props","arrowProps","show"]);return function(e,t){var n=e.ref,r=t.ref;e.ref=n.__wrapped||(n.__wrapped=function(e){return n(Object(R_.findDOMNode)(e))}),t.ref=r.__wrapped||(r.__wrapped=function(e){return r(Object(R_.findDOMNode)(e))})}(r,o),"function"==typeof t?t(Object(HS.a)({},s,{},r,{show:a,arrowProps:o})):i.a.cloneElement(t,Object(HS.a)({},s,{},r,{arrowProps:o,className:YS()(t.props.className,!n&&a&&"show"),style:Object(HS.a)({},t.props.style,{},r.style)}))}))}lE.defaultProps=uE;var cE=lE,fE=function(e){function t(){return e.apply(this,arguments)||this}return Object(qS.a)(t,e),t.prototype.render=function(){return this.props.children},t}(i.a.Component),hE=function(e){return e&&"object"==typeof e?e:{show:e,hide:e}},dE=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).getTarget=function(){return A_.a.findDOMNode(r.trigger.current)},r.handleShow=function(){clearTimeout(r._timeout),r._hoverState="show";var e=hE(r.props.delay);e.show?r._timeout=setTimeout((function(){"show"===r._hoverState&&r.show()}),e.show):r.show()},r.handleHide=function(){clearTimeout(r._timeout),r._hoverState="hide";var e=hE(r.props.delay);e.hide?r._timeout=setTimeout((function(){"hide"===r._hoverState&&r.hide()}),e.hide):r.hide()},r.handleFocus=function(e){var t=r.getChildProps().onFocus;r.handleShow(e),t&&t(e)},r.handleBlur=function(e){var t=r.getChildProps().onBlur;r.handleHide(e),t&&t(e)},r.handleClick=function(e){var t=r.getChildProps().onClick;r.state.show?r.hide():r.show(),t&&t(e)},r.handleMouseOver=function(e){r.handleMouseOverOut(r.handleShow,e,"fromElement")},r.handleMouseOut=function(e){return r.handleMouseOverOut(r.handleHide,e,"toElement")},r.trigger=i.a.createRef(),r.state={show:!!t.defaultShow},r.ariaModifier={enabled:!0,order:900,fn:function(e){var t=e.instance.popper,n=r.getTarget();if(!r.state.show||!n)return e;var i=t.getAttribute("role")||"";return t.id&&"tooltip"===i.toLowerCase()&&n.setAttribute("aria-describedby",t.id),e}},r}Object(qS.a)(t,e);var n=t.prototype;return n.componentWillUnmount=function(){clearTimeout(this._timeout)},n.getChildProps=function(){return i.a.Children.only(this.props.children).props},n.handleMouseOverOut=function(e,t,n){var r=t.currentTarget,i=t.relatedTarget||t.nativeEvent[n];i&&i===r||$S()(r,i)||e(t)},n.hide=function(){this.setState({show:!1})},n.show=function(){this.setState({show:!0})},n.render=function(){var e=this.props,t=e.trigger,n=e.overlay,o=e.children,a=e.popperConfig,s=void 0===a?{}:a,u=Object(zS.a)(e,["trigger","overlay","children","popperConfig"]);delete u.delay,delete u.defaultShow;var l=i.a.Children.only(o),c={},f=null==t?[]:[].concat(t);return-1!==f.indexOf("click")&&(c.onClick=this.handleClick),-1!==f.indexOf("focus")&&(c.onFocus=this.handleShow,c.onBlur=this.handleHide),-1!==f.indexOf("hover")&&(c.onMouseOver=this.handleMouseOver,c.onMouseOut=this.handleMouseOut),i.a.createElement(i.a.Fragment,null,i.a.createElement(fE,{ref:this.trigger},Object(r.cloneElement)(l,c)),i.a.createElement(cE,Object(HS.a)({},u,{popperConfig:Object(HS.a)({},s,{modifiers:Object(HS.a)({},s.modifiers,{ariaModifier:this.ariaModifier})}),show:this.state.show,onHide:this.handleHide,target:this.getTarget}),n))},t}(i.a.Component);dE.defaultProps={defaultOverlayShown:!1,trigger:["hover","focus"]};var pE=dE,yE=(n(458),n(243),i.a.createContext({}));yE.Consumer,yE.Provider;function mE(e,t){var n=Object(r.useContext)(yE);return e||n[t]||t}var gE=i.a.forwardRef((function(e,t){var n=e.bsPrefix,r=e.placement,o=e.className,a=e.style,s=e.children,u=e.arrowProps,l=(e.scheduleUpdate,e.outOfBoundaries,Object(zS.a)(e,["bsPrefix","placement","className","style","children","arrowProps","scheduleUpdate","outOfBoundaries"]));return n=mE(n,"tooltip"),i.a.createElement("div",Object(HS.a)({ref:t,style:a,role:"tooltip","x-placement":r,className:YS()(o,n,"bs-tooltip-"+r)},l),i.a.createElement("div",Object(HS.a)({className:"arrow"},u)),i.a.createElement("div",{className:n+"-inner"},s))}));gE.defaultProps={placement:"right"},gE.displayName="Tooltip";var vE,bE,_E=gE,wE=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1e4;return Math.floor(Math.random()*Math.floor(e))};function TE(e){var t=e.title,n=e.placement,i=e.trigger,o=e.spanHack,a=e.children;return o?r.createElement(pE,{placement:n,overlay:r.createElement(_E,{id:"".concat(t,"-").concat(wE())},t),trigger:i},r.createElement("span",{className:"d-flex justify-content-center align-items-center"},a)):r.createElement(pE,{placement:n,overlay:r.createElement(_E,{id:"".concat(t,"-").concat(wE())},t),trigger:i},a)}TE.defaultProps={trigger:["hover","click","focus"],placement:"top"},function(e){e.Pdf="pdf",e.Image="image",e.PowerPoint="powerpoint",e.Document="document",e.Excel="excel",e.Zip="archive",e.File="text"}(vE||(vE={})),function(e){e[e.Audience=1]="Audience",e[e.Category=2]="Category",e[e.Channel=3]="Channel",e[e.Chapter=4]="Chapter",e[e.Comment=5]="Comment",e[e.OwnerComment=6]="OwnerComment",e[e.Image=7]="Image",e[e.Thumbnail=8]="Thumbnail",e[e.Avatar=9]="Avatar",e[e.Banner=10]="Banner",e[e.Video=11]="Video",e[e.Trailer=12]="Trailer",e[e.Rating=13]="Rating",e[e.Topic=14]="Topic",e[e.Series=15]="Series",e[e.Season=16]="Season",e[e.HostedMediaObjectCollection=17]="HostedMediaObjectCollection",e[e.ExchangeCollection=18]="ExchangeCollection",e[e.CustomMediaObjectCollection=19]="CustomMediaObjectCollection",e[e.Playlist=20]="Playlist",e[e.ClickViewTvCollection=21]="ClickViewTvCollection",e[e.ClickViewProductionsCollection=22]="ClickViewProductionsCollection",e[e.User=23]="User",e[e.SystemUser=24]="SystemUser",e[e.Customer=25]="Customer",e[e.Country=26]="Country",e[e.Organisation=28]="Organisation",e[e.SystemOrganisation=29]="SystemOrganisation",e[e.Group=30]="Group",e[e.SystemGroup=31]="SystemGroup",e[e.FlagReason=32]="FlagReason",e[e.Library=33]="Library",e[e.Interactive=34]="Interactive",e[e.WorkspaceCollection=35]="WorkspaceCollection",e[e.Conversation=36]="Conversation",e[e.Message=37]="Message",e[e.Notification=38]="Notification",e[e.Clip=39]="Clip",e[e.Link=40]="Link",e[e.UserChannel=41]="UserChannel",e[e.Resource=42]="Resource",e[e.VideoStream=43]="VideoStream",e[e.AudioStream=44]="AudioStream",e[e.Tag=45]="Tag",e[e.Subtitle=46]="Subtitle",e[e.LicencedContentCollection=47]="LicencedContentCollection",e[e.PublicCollection=48]="PublicCollection",e[e.CategoryTree=49]="CategoryTree",e[e.Logo=50]="Logo",e[e.Permission=51]="Permission",e[e.Subject=52]="Subject",e[e.Field=53]="Field",e[e.Company=54]="Company",e[e.Person=55]="Person",e[e.Cover=56]="Cover",e[e.Poster=57]="Poster",e[e.SubjectAudience=58]="SubjectAudience",e[e.Classroom=67]="Classroom",e[e.ClassroomGroup=68]="ClassroomGroup"}(bE||(bE={}));var SE=n(44),EE=n.n(SE),CE=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},kE={width:1920,height:1080,format:"jpg"};function xE(e,t){var n,r=AT(e,"/v1/previews");return"metadata"in t?t.metadata.type===vE.Pdf?jS.createResourceImage(r,t.url,kE):t.metadata.type===vE.Image?jS.createUrl(t.url,{size:vS.Medium,resizeType:_S.Cover}):(null===(n=t.pdf)||void 0===n?void 0:n.url)?jS.createResourceImage(r,t.pdf.url,kE):t.metadata.type===vE.Zip?jS.createUrl(AT(e,"/v2/thumbnails/BKnxEm"),{size:vS.Large,format:"png"}):jS.createUrl("".concat(e,"v2/thumbnails/BKnxEm"),{size:vS.Large,format:"png"}):jS.createResourceImage(r,t.url,Object.assign(Object.assign({},kE),{resizeType:_S.Cover}))}function OE(e){var t,n,r,o=null,a=0;"metadata"in e.data&&(o=e.data.metadata,a=null!==(r=null===(n=null===(t=e.data.thumbnail)||void 0===t?void 0:t.metadata)||void 0===n?void 0:n.rotation)&&void 0!==r?r:0);var s="pt-3 px-3 rounded-lg d-flex flex-column align-items-center"+" justify-content-end ".concat(function(e){switch(e){case"atom-guide":return EE.a.atomGuide;case"student-activity":return EE.a.studentActivity;case"teacher-pack":return EE.a.teacherPack;case"additional-materials":return EE.a.additionalMaterials;default:return EE.a.userUploaded}}(null==o?void 0:o.resourceType)," ").concat(EE.a.background);return i.a.createElement("div",{className:s},i.a.createElement(TE,{title:e.data.name},i.a.createElement("h3",{className:"text-center clamp-1 text-break h5 mb-3 ".concat(EE.a.text)},e.data.name)),i.a.createElement("div",{className:"w-75 overflow-hidden ".concat(EE.a.thumbnailContainer)},i.a.createElement(US,{data:xE(e.imageCdnUrl,e.data),aspectRatio:RS.SixteenByNine,imageStyle:{transform:"rotate(".concat(a,"deg)")},analyticsOptions:{location:pb.LocationContext.SlidingListItem},onImageLoadError:function(t){t.target.src=e.imageErrorFallbackUrl},preload:!0})))}i.a.memo((function(e){var t,n,r,o,a,s,u,l=e.appLink,c=CE(e,["appLink"]),f=(t=VS(AS.XS),n=VS(AS.SM),r=VS(AS.MD),o=VS(AS.LG),a=VS(AS.XL),s=VS(AS.XXL),u=AS.LG,t&&(u=AS.XS),n&&(u=AS.SM),r&&(u=AS.MD),o&&(u=AS.LG),a&&(u=AS.XL),s&&(u=AS.XXL),u),h=f===AS.SM||f===AS.XS,d=null;"metadata"in e.data&&(d=e.data.metadata.type);var p=Object.assign(Object.assign({},e.analyticsData),e.data),y=Object.assign(Object.assign({},e.analyticsOptions),{actionType:pb.UserAction.Click,entity:e.data.typeId===bE.Resource?pb.EntityType.Resource:pb.EntityType.Link});function m(){ZT.logUserAction(p,y)}return i.a.createElement("div",{className:"pt-1 px-1 flex-shrink-0 ".concat(EE.a.item)},function(){if(!d)return i.a.createElement("a",{href:e.data.url,target:"_blank",className:"d-block",onClick:m},i.a.createElement(OE,Object.assign({},c)));var t=!!e.data.pdf||d===vE.Pdf||d===vE.Image;return h||!t||d===vE.Zip?i.a.createElement("a",{href:e.data.url,className:"d-block",onClick:m},i.a.createElement(OE,Object.assign({},c))):i.a.createElement(OS,{appLink:Object.assign(Object.assign({},l),{args:[e.data.id]}),className:"d-block no-decoration",analyticsData:p,analyticsOptions:y},i.a.createElement(OE,Object.assign({},c)))}())})),n(459);function PE(e){return(PE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function RE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function AE(e,t){return(AE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function IE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jE(e);if(t){var i=jE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return LE(this,n)}}function LE(e,t){return!t||"object"!==PE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jE(e){return(jE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function DE(e){return i.a.createElement("div",{className:"cv-resource-item"},i.a.createElement(OE,{data:e.resource,imageCdnUrl:e.imageCdnUrl}))}var NE=q_((function(e,t){return i.a.createElement(DE,Object.assign({},t))})),ME=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&AE(e,t)}(o,e);var t,n,r,i=IE(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t);var r=new NE(e,{resource:t.resource,imageCdnUrl:t.imageCdnUrl});return n.addChild(r),n}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("div")}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.options_.downloadResource(this.options_.resource)}}])&&RE(t.prototype,n),r&&RE(t,r),o}(Fu.getComponent("ClickableComponent"));n(460);function UE(e){return(UE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function BE(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function FE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function VE(e,t,n){return(VE="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=WE(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function HE(e,t){return(HE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=WE(e);if(t){var i=WE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qE(this,n)}}function qE(e,t){return!t||"object"!==UE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function WE(e){return(WE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var $E=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&HE(e,t)}(o,e);var t,n,r,i=zE(o);function o(){var e;return BE(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(VE(WE(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"buildCSSClass",value:function(){return"cv-resources-button ".concat(VE(WE(o.prototype),"buildCSSClass",this).call(this))}},{key:"update",value:function(){VE(WE(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"createMenu",value:function(){return this.options_.title="Resources",VE(WE(o.prototype),"createMenu",this).call(this)}},{key:"createItems",value:function(){var e=this,t=[];return this.options_.resources.forEach((function(n){var r=new ME(e.player(),{resource:n,imageCdnUrl:e.options_.imageCdnUrl,downloadResource:function(t){return e.downloadResource(t)}});t.push(r)})),t}},{key:"downloadResource",value:function(e){this.getDownloadIframe().src=e.url}},{key:"getDownloadIframe",value:function(){return this.downloadIframe||(this.downloadIframe=Fu.dom.createEl("iframe"),this.downloadIframe.style.display="none",Fu.dom.appendContent(Fu.dom.$("body"),this.downloadIframe)),this.downloadIframe}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){VE(WE(o.prototype),"handleClick",this).call(this,null)}}])&&FE(t.prototype,n),r&&FE(t,r),o}(Fu.getComponent("MenuButton"));function GE(e){return(GE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function YE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function KE(e,t){return(KE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function XE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=JE(e);if(t){var i=JE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return QE(this,n)}}function QE(e,t){return!t||"object"!==GE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function JE(e){return(JE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}$E.prototype.controlText_="Resources",Fu.registerComponent("ResourcesButton",$E);var ZE=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&KE(e,t)}(o,e);var t,n,r,i=XE(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){if(this.options.resources.length){var e=this.player.getChild("collapserator");e.addChild("ResourcesButton",{resources:this.options.resources,imageCdnUrl:this.options.imageCdnUrl},e.children_.length-3)}}}])&&YE(t.prototype,n),r&&YE(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("resourcesPlugin",ZE);n(461);function eC(e){return(eC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function tC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nC(e,t){return(nC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=oC(e);if(t){var i=oC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return iC(this,n)}}function iC(e,t){return!t||"object"!==eC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function oC(e){return(oC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var aC=Fu.getComponent("PlayToggle"),sC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nC(e,t)}(o,e);var t,n,r,i=rC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).pictureInPictureEnabled=!0,n.options=t,n.bindFunctions(),n.player.ready((function(){n.initialize()})),n}return t=o,(n=[{key:"initialize",value:function(){var e=this;this.enablePictureInPicture(),this.player.on("dispose",(function(){e.dispose()}))}},{key:"bindFunctions",value:function(){this.requestPictureInPicture=this.requestPictureInPicture.bind(this),this.exitPictureInPicture=this.exitPictureInPicture.bind(this),this.playerRequestPictureInPictureFn=this.player.requestPictureInPicture,this.playerExitPictureInPictureFn=this.player.exitPictureInPicture,this.player.requestPictureInPicture=this.requestPictureInPicture,this.player.exitPictureInPicture=this.exitPictureInPicture}},{key:"enablePictureInPicture",value:function(){if(this.player.options_.fluid){this.pictureInPictureEnabled=!0;var e=this.getToggleParentComponent();null==e||e.addChild("pictureInPictureToggle",{},e.children().length-1)}}},{key:"disablePictureInPicture",value:function(){this.pictureInPictureEnabled=!1;var e=this.getToggleParentComponent(),t=null==e?void 0:e.getChild("pictureInPictureToggle");t&&e.removeChild(t)}},{key:"togglePictureInPicture",value:function(e){if(e!==this.player.isInPictureInPicture()){var t=e?"enterpictureinpicture":"leavepictureinpicture";this.player.isInPictureInPicture(e),this.player.trigger(t),e?this.addPipStyles():this.removePipStyles()}}},{key:"addPipStyles",value:function(){this.player.addClass("cv-picture-in-picture"),this.playToggle=new aC(this.player),this.playToggle.addClass("cv-pip-play-toggle"),this.player.addChild(this.playToggle),this.player.paused()?this.playToggle.handlePause():this.playToggle.handlePlay()}},{key:"removePipStyles",value:function(){this.player.removeClass("cv-picture-in-picture"),this.player.removeChild(this.playToggle),delete this.playToggle}},{key:"requestPictureInPicture",value:function(){this.pictureInPictureEnabled&&(this.togglePictureInPicture(!0),this.options.onRequestPictureInPicture(!0))}},{key:"exitPictureInPicture",value:function(){this.togglePictureInPicture(!1),this.options.onRequestPictureInPicture(!1),this.removePipStyles()}},{key:"getToggleParentComponent",value:function(){return this.player.getChild("collapserator")}},{key:"dispose",value:function(){this.player.requestPictureInPicture=this.playerRequestPictureInPictureFn,this.player.exitPictureInPicture=this.playerExitPictureInPictureFn}}])&&tC(t.prototype,n),r&&tC(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("pictureInPicture",sC);n(462);function uC(e){return(uC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function cC(e,t){return(cC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dC(e);if(t){var i=dC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return hC(this,n)}}function hC(e,t){return!t||"object"!==uC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function dC(e){return(dC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var pC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cC(e,t)}(o,e);var t,n,r,i=fC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).update(),n}return t=o,(n=[{key:"update",value:function(){this.options_.isFavourited?this.addClass("cv-favourited"):this.removeClass("cv-favourited")}},{key:"handleClick",value:function(){if(this.options_.isFavourited=!this.options_.isFavourited,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-favourite-button"}}])&&lC(t.prototype,n),r&&lC(t,r),o}(Fu.getComponent("Button"));function yC(e){return(yC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function mC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function vC(e,t){return(vC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function bC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=wC(e);if(t){var i=wC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _C(this,n)}}function _C(e,t){return!t||"object"!==yC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function wC(e){return(wC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}pC.prototype.controlText_="Favourite";var TC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&vC(e,t)}(o,e);var t,n,r,i=bC(o);function o(){return mC(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setFavourite",value:function(e,t){e!==this.isFavourite&&(this.isFavourite=e,this.onClickFavourite=t,this.renderFavouriteButton())}},{key:"renderFavouriteButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new pC(this.player,{isFavourited:this.isFavourite,clickHandler:this.onClickFavourite}),this.player.addChild(this.button))}}])&&gC(t.prototype,n),r&&gC(t,r),o}(Fu.getPlugin("plugin"));function SC(e){return(SC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function EC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function CC(e,t,n){return(CC="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=PC(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function kC(e,t){return(kC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function xC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=PC(e);if(t){var i=PC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return OC(this,n)}}function OC(e,t){return!t||"object"!==SC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function PC(e){return(PC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("favouritePlugin",TC);var RC=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},AC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&kC(e,t)}(o,e);var t,n,r,i=xC(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"configurePlugins",value:function(){try{var e=this.player;e.persistVolumePlugin(),e.fullscreenOnRotatePlugin(),e.touchControls(),this.options.getExternalLink&&e.openExternallyPlugin({getExternalLink:this.options.getExternalLink}),this.options.onClickCreateClip&&e.createClipButtonPlugin({onClick:this.options.onClickCreateClip}),this.options.onRequestPictureInPicture&&e.pictureInPicture({onRequestPictureInPicture:this.options.onRequestPictureInPicture})}catch(e){console.log("failed to register plugins",e)}}},{key:"setFavourite",value:function(e,t){this.player.favouritePlugin().setFavourite(e,t)}},{key:"setNextVideo",value:function(e,t){this.player.nextVideoPlugin().setNextVideo(e,t)}},{key:"enablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.enablePictureInPicture()}},{key:"disablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.disablePictureInPicture()}},{key:"togglePictureInPicture",value:function(e){var t=this.player.pictureInPicture();t&&t.togglePictureInPicture(e)}},{key:"additionalSetup",value:function(e){var t=this,n=Object.create(null,{additionalSetup:{get:function(){return CC(PC(o.prototype),"additionalSetup",t)}}});return RC(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n.additionalSetup.call(this,e),"MasterClip"!==e.mediaType){t.next=6;break}if(null!==(r=e.additionalData)){t.next=5;break}throw Error("Invalid clip data");case 5:this.player.clipPlugin({startTime:r.startTime,endTime:r.endTime});case 6:case"end":return t.stop()}}),t,this)})))}}])&&EC(t.prototype,n),r&&EC(t,r),o}(w_),IC=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};function LC(e){var t=e.className,n=void 0===t?"":t,r=e.playerApi,o=e.onReady,a=e.onDispose,s=IC(e,["className","playerApi","onReady","onDispose"]),u=i.a.useRef(),l=i.a.useRef();return i.a.useEffect((function(){var e;if(null===(e=l.current)||void 0===e||e.dispose(),u)return l.current=new AC(u.current,Object.assign(Object.assign({},s),{playerApi:r})),o&&l.current.ready((function(){o(l.current)})),a&&l.current.one("dispose",a),function(){var e;null===(e=l.current)||void 0===e||e.dispose()}}),[e.viewKey]),i.a.createElement("div",{ref:u,className:n})}function jC(e){return(jC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function DC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function NC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function MC(e,t,n){return(MC="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=VC(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function UC(e,t){return(UC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function BC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=VC(e);if(t){var i=VC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return FC(this,n)}}function FC(e,t){return!t||"object"!==jC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function VC(e){return(VC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var HC=Fu.getComponent("Component"),zC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&UC(e,t)}(o,e);var t,n,r,i=BC(o);function o(){return DC(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-clip-timepoint-handle ".concat(MC(VC(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return MC(VC(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass(),innerHTML:'<svg viewBox="0 0 5 14"><g id="Clips" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"><g id="Clip-2" transform="translate(-835.000000, -632.000000)" fill="#FFFFFF"><g id="Video-Copy" transform="translate(275.000000, 96.000000)"><g id="Handles" transform="translate(560.000000, 536.000000)"><circle id="Oval" cx="1" cy="1" r="1"></circle><circle id="Oval-Copy-2" cx="1" cy="5" r="1"></circle><circle id="Oval-Copy-4" cx="1" cy="9" r="1"></circle><circle id="Oval-Copy-8" cx="1" cy="13" r="1"></circle><circle id="Oval-Copy" cx="4" cy="1" r="1"></circle><circle id="Oval-Copy-3" cx="4" cy="5" r="1"></circle><circle id="Oval-Copy-5" cx="4" cy="9" r="1"></circle><circle id="Oval-Copy-9" cx="4" cy="13" r="1"></circle></g></g></g></g></svg>'}),n)}},{key:"isEventTarget",value:function(e){return this.el().contains(e.target)}}])&&NC(t.prototype,n),r&&NC(t,r),o}(HC);n(463);function qC(e){return(qC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function WC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $C(e,t,n){return($C="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=XC(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function GC(e,t){return(GC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function YC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=XC(e);if(t){var i=XC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return KC(this,n)}}function KC(e,t){return!t||"object"!==qC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function XC(e){return(XC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var QC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&GC(e,t)}(o,e);var t,n,r,i=YC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).dragStartActive=!1,n.dragEndActive=!1,n.dragSliderActive=!1,n.dragSliderCurrentPosition=null,n.minDuration=Math.min(e.duration(),n.options_.minDuration),n.setStartTime(t.startTime,!1),n.setEndTime(t.endTime,!1),n.startHandle=new zC(n.player(),t),n.startHandle.addClass("cv-clip-start-handle"),n.addChild(n.startHandle),n.endHandle=new zC(n.player(),t),n.endHandle.addClass("cv-clip-end-handle"),n.addChild(n.endHandle),n.on(n.player(),"update:clip:start:time",(function(e){var t=e.time;return n.setStartTime(t)})),n.on(n.player(),"update:clip:end:time",(function(e){var t=e.time;return n.setEndTime(t)})),n.bindListeners(),n.update(),n}return t=o,(n=[{key:"createEl",value:function(){return $C(XC(o.prototype),"createEl",this).call(this,"div",{className:"cv-clip-timepoint-selector"},{})}},{key:"update",value:function(){var e=this;this.options_.onChangeStartTime(this.startTime),this.options_.onChangeEndTime(this.endTime),this.requestAnimationFrame((function(){e.setStartOffset(),e.setWidth()}))}},{key:"setStartTime",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!isNaN(e)){var n=this.endTime||this.player().duration(),r=n-this.minDuration;e>r&&(e=r),e<0&&(e=0),this.startTime=e,this.endTime&&this.endTime-this.startTime<this.minDuration&&this.setEndTime(this.startTime+this.minDuration),this.player().currentTime(this.startTime),t&&this.update()}}},{key:"setEndTime",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!isNaN(e)){var n=this.startTime||0,r=n+this.minDuration;e<r&&(e=r),e>this.player().duration()&&(e=this.player().duration()),this.endTime=e,this.startTime&&this.endTime-this.startTime<this.minDuration&&this.setStartTime(this.endTime-this.minDuration),t&&this.update()}}},{key:"bindListeners",value:function(){var e=this;this.on("mousedown",this.dragStart),this.on("touchstart",this.dragStart),this.player().on("dispose",(function(){e.off("mousedown",e.dragStart),e.off("touchstart",e.dragStart)}))}},{key:"dragStart",value:function(e){this.startHandle.isEventTarget(e)&&(e.stopImmediatePropagation(),this.dragStartActive=!0),this.endHandle.isEventTarget(e)&&(e.stopImmediatePropagation(),this.dragEndActive=!0),e.target===this.el()&&(e.stopImmediatePropagation(),this.dragSliderActive=!0,this.dragSliderCurrentPosition=this.getPosition(e));var t=this.el().ownerDocument;this.on(t,"mousemove",this.drag),this.on(t,"mouseup",this.dragEnd),this.on(t,"touchmove",this.drag),this.on(t,"touchend",this.dragEnd),this.drag(e)}},{key:"dragEnd",value:function(){this.dragStartActive=!1,this.dragEndActive=!1,this.dragSliderActive=!1,this.dragSliderCurrentPosition=null;var e=this.el().ownerDocument;this.off(e,"mousemove",this.drag),this.off(e,"mouseup",this.dragEnd),this.off(e,"touchmove",this.drag),this.off(e,"touchend",this.dragEnd)}},{key:"drag",value:function(e){if((this.dragStartActive||this.dragEndActive||this.dragSliderActive)&&Fu.dom.isSingleLeftClick(e)){var t=this.getPosition(e),n=t*this.player().duration();this.dragStartActive&&this.handleStartHandleDrag(n),this.dragEndActive&&this.handleEndHandleDrag(n),this.dragSliderActive&&this.handleSliderDrag(t)}}},{key:"handleStartHandleDrag",value:function(e){this.setStartTime(e)}},{key:"handleEndHandleDrag",value:function(e){this.setEndTime(e)}},{key:"handleSliderDrag",value:function(e){var t=(e-this.dragSliderCurrentPosition)*this.player().duration(),n=this.startTime+t,r=this.endTime+t;n<=0||r>=this.player().duration()||(this.dragSliderCurrentPosition=e,this.setStartTime(n),this.setEndTime(r))}},{key:"getPosition",value:function(e){return Fu.dom.getPointerPosition(this.el_.parentNode,e).x}},{key:"setStartOffset",value:function(){this.el_.style.marginLeft="".concat(this.getPercentage(this.startTime),"%")}},{key:"setWidth",value:function(){this.el_.style.width="".concat(this.getPercentage(this.endTime-this.startTime),"%")}},{key:"getPercentage",value:function(e){return+(e/this.player().duration()*100).toFixed(4)}}])&&WC(t.prototype,n),r&&WC(t,r),o}(Fu.getComponent("Component"));n(464);function JC(e){return(JC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ZC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ek(e,t){return(ek=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tk(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=rk(e);if(t){var i=rk(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return nk(this,n)}}function nk(e,t){return!t||"object"!==JC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function rk(e){return(rk=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ik=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ek(e,t)}(o,e);var t,n,r,i=tk(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addClass("cv-create-clip-seek-bar"),n}return t=o,(n=[{key:"initialize",value:function(e){var t=new QC(this.player(),e);this.addChild(t)}}])&&ZC(t.prototype,n),r&&ZC(t,r),o}(Fu.getComponent("SeekBar"));function ok(e){return(ok="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ak(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sk(e,t){return(sk=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function uk(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=fk(e);if(t){var i=fk(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return lk(this,n)}}function lk(e,t){return!t||"object"!==ok(t)&&"function"!=typeof t?ck(e):t}function ck(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fk(e){return(fk=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}ik.prototype.options_={children:["playProgressBar"],barName:"playProgressBar"},Fu.browser.IS_IOS||Fu.browser.IS_ANDROID||ik.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Fu.registerComponent("CreateClipSeekBar",ik);var hk=Fu.getPlugin("plugin"),dk=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&sk(e,t)}(o,e);var t,n,r,i=uk(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,n.initCreateClipSeekBar=n.initCreateClipSeekBar.bind(ck(n)),n.player.one("loadedmetadata",(function(){return n.player.ready(n.initCreateClipSeekBar)})),n}return t=o,(n=[{key:"initCreateClipSeekBar",value:function(){var e,t=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar");if(t){var n=!isNaN(this.options.startTime)&&this.options.startTime>=0?this.options.startTime:0,r=!isNaN(this.options.endTime)&&this.options.endTime<=this.player.duration()?this.options.endTime:this.player.duration(),i=Math.min(this.options.minDuration||5,this.player.duration());t.initialize({startTime:n,endTime:r,minDuration:i,onChangeStartTime:this.options.onChangeStartTime,onChangeEndTime:this.options.onChangeEndTime})}}},{key:"dispose",value:function(){this.player.off("loadedmetadata",this.initCreateClipSeekBar)}}])&&ak(t.prototype,n),r&&ak(t,r),o}(hk);function pk(e){return(pk="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function yk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mk(e,t){return(mk=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function gk(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=bk(e);if(t){var i=bk(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return vk(this,n)}}function vk(e,t){return!t||"object"!==pk(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function bk(e){return(bk=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("createClipPlugin",dk);var _k=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&mk(e,t)}(o,e);var t,n,r,i=gk(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,Object.assign(Object.assign({},t),{playbackRates:null,enableLocalCache:!1}))}return t=o,(n=[{key:"getPlayerClassName",value:function(){return"cv-create-clip-player"}},{key:"configurePlugins",value:function(){var e=this.options,t=e.startTime,n=e.endTime,r=e.minDuration,i=e.onChangeStartTime,o=e.onChangeEndTime;this.player.createClipPlugin({startTime:t,endTime:n,minDuration:r,onChangeStartTime:i,onChangeEndTime:o})}},{key:"getSeekBarName",value:function(){return"CreateClipSeekBar"}},{key:"getAnalyticsPlayerType",value:function(){return"create-clip-player"}}])&&yk(t.prototype,n),r&&yk(t,r),o}(w_);function wk(e){var t=i.a.useRef(),n=i.a.useRef();return i.a.useEffect((function(){n.current=new _k(t.current,e)}),[]),i.a.useEffect((function(){var t;null===(t=n.current)||void 0===t||t.trigger({type:"update:clip:start:time",time:e.startTime})}),[e.startTime]),i.a.useEffect((function(){var t;null===(t=n.current)||void 0===t||t.trigger({type:"update:clip:end:time",time:e.endTime})}),[e.endTime]),i.a.createElement("div",{ref:t})}n.d(t,"ClickViewPlayer",(function(){return LC})),n.d(t,"ClickViewCreateClipPlayer",(function(){return wk})),n.d(t,"Player",(function(){return AC}))},function(e,t,n){"use strict";n.r(t);var r=n(240),i=n.n(r),o=n(31),a=n.n(o),s=n(7),u=n.n(s),l=n(3),c=n.n(l),f=n(21),h=n.n(f),d=n(241),p=n.n(d),y=n(1),m=n(145),g=n(146),v=n.n(g),b=v()(),_=v()(),w=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"referenceNode",void 0),h()(c()(c()(t)),"setReferenceNode",(function(e){e&&t.referenceNode!==e&&(t.referenceNode=e,t.forceUpdate())})),t}u()(t,e);var n=t.prototype;return n.componentWillUnmount=function(){this.referenceNode=null},n.render=function(){return y.createElement(b.Provider,{value:this.referenceNode},y.createElement(_.Provider,{value:this.setReferenceNode},this.props.children))},t}(y.Component),T=function(e){return Array.isArray(e)?e[0]:e},S=function(e){if("function"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,n)}},E=function(e,t){if("function"==typeof e)return S(e,t);null!=e&&(e.current=t)},C={position:"absolute",top:0,left:0,opacity:0,pointerEvents:"none"},k={},x=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"state",{data:void 0,placement:void 0}),h()(c()(c()(t)),"popperInstance",void 0),h()(c()(c()(t)),"popperNode",null),h()(c()(c()(t)),"arrowNode",null),h()(c()(c()(t)),"setPopperNode",(function(e){e&&t.popperNode!==e&&(E(t.props.innerRef,e),t.popperNode=e,t.updatePopperInstance())})),h()(c()(c()(t)),"setArrowNode",(function(e){t.arrowNode=e})),h()(c()(c()(t)),"updateStateModifier",{enabled:!0,order:900,fn:function(e){var n=e.placement;return t.setState({data:e,placement:n}),e}}),h()(c()(c()(t)),"getOptions",(function(){return{placement:t.props.placement,eventsEnabled:t.props.eventsEnabled,positionFixed:t.props.positionFixed,modifiers:a()({},t.props.modifiers,{arrow:a()({},t.props.modifiers&&t.props.modifiers.arrow,{enabled:!!t.arrowNode,element:t.arrowNode}),applyStyle:{enabled:!1},updateStateModifier:t.updateStateModifier})}})),h()(c()(c()(t)),"getPopperStyle",(function(){return t.popperNode&&t.state.data?a()({position:t.state.data.offsets.popper.position},t.state.data.styles):C})),h()(c()(c()(t)),"getPopperPlacement",(function(){return t.state.data?t.state.placement:void 0})),h()(c()(c()(t)),"getArrowStyle",(function(){return t.arrowNode&&t.state.data?t.state.data.arrowStyles:k})),h()(c()(c()(t)),"getOutOfBoundariesState",(function(){return t.state.data?t.state.data.hide:void 0})),h()(c()(c()(t)),"destroyPopperInstance",(function(){t.popperInstance&&(t.popperInstance.destroy(),t.popperInstance=null)})),h()(c()(c()(t)),"updatePopperInstance",(function(){t.destroyPopperInstance();var e=c()(c()(t)).popperNode,n=t.props.referenceElement;n&&e&&(t.popperInstance=new m.a(n,e,t.getOptions()))})),h()(c()(c()(t)),"scheduleUpdate",(function(){t.popperInstance&&t.popperInstance.scheduleUpdate()})),t}u()(t,e);var n=t.prototype;return n.componentDidUpdate=function(e,t){this.props.placement===e.placement&&this.props.referenceElement===e.referenceElement&&this.props.positionFixed===e.positionFixed&&p()(this.props.modifiers,e.modifiers,{strict:!0})?this.props.eventsEnabled!==e.eventsEnabled&&this.popperInstance&&(this.props.eventsEnabled?this.popperInstance.enableEventListeners():this.popperInstance.disableEventListeners()):this.updatePopperInstance(),t.placement!==this.state.placement&&this.scheduleUpdate()},n.componentWillUnmount=function(){E(this.props.innerRef,null),this.destroyPopperInstance()},n.render=function(){return T(this.props.children)({ref:this.setPopperNode,style:this.getPopperStyle(),placement:this.getPopperPlacement(),outOfBoundaries:this.getOutOfBoundariesState(),scheduleUpdate:this.scheduleUpdate,arrowProps:{ref:this.setArrowNode,style:this.getArrowStyle()}})},t}(y.Component);h()(x,"defaultProps",{placement:"bottom",eventsEnabled:!0,referenceElement:void 0,positionFixed:!1});var O=m.a.placements;function P(e){var t=e.referenceElement,n=i()(e,["referenceElement"]);return y.createElement(b.Consumer,null,(function(e){return y.createElement(x,a()({referenceElement:void 0!==t?t:e},n))}))}var R=n(106),A=n.n(R),I=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"refHandler",(function(e){E(t.props.innerRef,e),S(t.props.setReferenceNode,e)})),t}u()(t,e);var n=t.prototype;return n.componentWillUnmount=function(){E(this.props.innerRef,null)},n.render=function(){return A()(Boolean(this.props.setReferenceNode),"`Reference` should not be used outside of a `Manager` component."),T(this.props.children)({ref:this.refHandler})},t}(y.Component);function L(e){return y.createElement(_.Consumer,null,(function(t){return y.createElement(I,a()({setReferenceNode:t},e))}))}n.d(t,"Popper",(function(){return P})),n.d(t,"placements",(function(){return O})),n.d(t,"Manager",(function(){return w})),n.d(t,"Reference",(function(){return L}))}])}));
|
|
122
|
+
var t,n;function r(){var t,n=zu(zu(t=e.call(this)||this));if(Fu.browser.IS_IE8)for(var i in n=Hu.a.createElement("custom"),r.prototype)"constructor"!==i&&(n[i]=r.prototype[i]);return n.levels_=[],n.selectedIndex_=-1,Object.defineProperty(n,"selectedIndex",{get:function(){return n.selectedIndex_}}),Object.defineProperty(n,"length",{get:function(){return n.levels_.length}}),n||zu(t)}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.addQualityLevel=function(e){var t=this.getQualityLevelById(e.id);if(t)return t;var n=this.levels_.length;return t=new qu(e),""+n in this||Object.defineProperty(this,n,{get:function(){return this.levels_[n]}}),this.levels_.push(t),this.trigger({qualityLevel:t,type:"addqualitylevel"}),t},i.removeQualityLevel=function(e){for(var t=null,n=0,r=this.length;n<r;n++)if(this[n]===e){t=this.levels_.splice(n,1)[0],this.selectedIndex_===n?this.selectedIndex_=-1:this.selectedIndex_>n&&this.selectedIndex_--;break}return t&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),t},i.getQualityLevelById=function(e){for(var t=0,n=this.length;t<n;t++){var r=this[t];if(r.id===e)return r}return null},i.dispose=function(){this.selectedIndex_=-1,this.levels_.length=0},r}(Fu.EventTarget);for(var $u in Wu.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"},Wu.prototype.allowedEvents_)Wu.prototype["on"+$u]=null;var Gu=Fu.registerPlugin||Fu.plugin,Yu=function(e){return t=this,Fu.mergeOptions({},e),n=t.qualityLevels,r=new Wu,t.on("dispose",(function e(){r.dispose(),t.qualityLevels=n,t.off("dispose",e)})),t.qualityLevels=function(){return r},t.qualityLevels.VERSION="2.0.9",r;var t,n,r};Gu("qualityLevels",Yu),Yu.VERSION="2.0.9";var Ku=n(234);function Xu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Qu=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.id=n.id,this.plugin=t,this.source=n,this.enabled=this.enabled.bind(this)}var t,n,r;return t=e,(n=[{key:"enabled",value:function(e){return void 0===e?this.plugin.currentSource===this.source:(e&&this.plugin.setSource(this.source.id),e)}}])&&Xu(t.prototype,n),r&&Xu(t,r),e}();function Ju(e){return(Ju="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Zu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function el(e,t){return(el=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=rl(e);if(t){var i=rl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return nl(this,n)}}function nl(e,t){return!t||"object"!==Ju(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function rl(e){return(rl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var il=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&el(e,t)}(o,e);var t,n,r,i=tl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).sources=[],n.qualityLevels=e.qualityLevels(),n.populateSources(t.sources),n}return t=o,(n=[{key:"currentSource",get:function(){return this._currentSource}},{key:"setSource",value:function(e){var t=this,n=this.getSourceById(e);if(null===n)return this.currentSource;var r=this.player.currentTime(),i=!this.player.paused();return this._currentSource=n,this.player.src({src:n.url,type:n.mimeType}),this.player.one("loadedmetadata",(function(){t.player.currentTime()!==r&&t.player.currentTime(r),i&&t.player.play()})),this.trigger({event:"sourcechange",source:n}),this.sourceChangeUpdateQualityLevels(n),n}},{key:"getSourceById",value:function(e){return this.sources.find((function(t){return t.id===e}))}},{key:"populateSources",value:function(e){var t=this,n=null;e.forEach((function(e){t.qualityLevels.addQualityLevel(new Qu(t,e)),t.sources.push(e),t.trigger({event:"addsource",source:e}),e.default&&(n=e)})),null===n&&(n=this.sources[0]),null!==n&&this.setSource(n.id)}},{key:"sourceChangeUpdateQualityLevels",value:function(e){for(var t=this.qualityLevels,n=-1,r=0;r<t.length;r++)if(t[r].id===e.id){n=r;break}t.selectedIndex_=n,t.trigger({selectedIndex:n,type:"change"})}}])&&Zu(t.prototype,n),r&&Zu(t,r),o}(Fu.getPlugin("plugin"));function ol(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Fu.registerPlugin("progressiveFiles",il);var al=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},sl=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.name=t.name,this.playbackProfile=t.playbackProfile,this.address=new URL(t.httpsAddress)}var t,n,r;return t=e,(n=[{key:"getUrl",value:function(e){return e?this.address+"cache?file="+encodeURIComponent(e):null}},{key:"ping",value:function(){return al(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=new AbortController,n=setTimeout((function(){return t.abort()}),1e3),e.prev=3,e.next=6,fetch(this.address+"ping",{method:"GET",mode:"cors",signal:t.signal});case 6:return r=e.sent,e.next=9,r.text();case 9:return i=e.sent,clearTimeout(n),e.abrupt("return","PONG"===i);case 14:return e.prev=14,e.t0=e.catch(3),e.abrupt("return",!1);case 17:case"end":return e.stop()}}),e,this,[[3,14]])})))}}])&&ol(t.prototype,n),r&&ol(t,r),e}();function ul(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var ll=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,r;return t=e,r=[{key:"getKnownProfiles",value:function(){return["1080","720","480","360","240"]}},{key:"enableProfileOrNextBest",value:function(e,t){var n=e.getQualityLevelById(t);if(n||(n=this.getNextBestQuality(e,t)),!n)return null;for(var r=0;r<e.length;r++){var i=e[r];i.enabled=n.id===i.id}return n}},{key:"getNextBestQuality",value:function(e,t){var n=this.getKnownProfiles(),r=n.indexOf(t);if(r>=0){for(var i=r+1;i<n.length;i++){var o=n[i],a=e.getQualityLevelById(o);if(a)return a}for(var s=r-1;s>0;s--){var u=n[s],l=e.getQualityLevelById(u);if(l)return l}}return null}}],(n=null)&&ul(t.prototype,n),r&&ul(t,r),e}();function cl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var fl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},hl=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.player=t,this.logger=Fu.log.createLogger("localcache")}var t,n,r;return t=e,(n=[{key:"setSource",value:function(e,t){return fl(this,void 0,void 0,regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return t(null,e),n.abrupt("return");case 5:null!==(r=n.sent)&&(this.logger.debug("Using Local Cache",r),e.src=r.getUrl(e.src));case 7:t(null,e);case 8:case"end":return n.stop()}}),n,this)})))}}])&&cl(t.prototype,n),r&&cl(t,r),e}();Fu.use("*",(function(e){return new hl(e)}));n(379);function dl(e){return(dl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function pl(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yl(e,t,n){return(yl="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=_l(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ml(e,t){return(ml=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function gl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_l(e);if(t){var i=_l(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return vl(this,n)}}function vl(e,t){return!t||"object"!==dl(t)&&"function"!=typeof t?bl(e):t}function bl(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _l(e){return(_l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var wl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Tl=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ml(e,t)}(o,e);var t,n,r,i=gl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).hide(),n.onLocalCacheChange=n.onLocalCacheChange.bind(bl(n)),e.ready((function(){n.initialize()})),n}return t=o,(n=[{key:"createEl",value:function(){return yl(_l(o.prototype),"createEl",this).call(this,"div",{className:"vjs-local-cache-indicator",innerHTML:'<div class="vjs-local-cache-indicator-icon">'.concat('<?xml version="1.0" encoding="UTF-8"?><svg width="24px" height="24px" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" opacity="0.9"><g id="Local-Cache" transform="translate(2.000000, 2.000000)"><rect id="Rectangle" fill="#FFFFFF" x="0" y="2.4" width="18.8" height="15.2"></rect><ellipse id="Oval" fill="#FFFFFF" cx="9.4" cy="2.4" rx="9.4" ry="2.4"></ellipse><ellipse id="Oval-Copy" fill="#FFFFFF" cx="9.4" cy="17.6" rx="9.4" ry="2.4"></ellipse><g id="Logo/Circle" transform="translate(2.500000, 3.000000)"><circle id="Oval" fill="#FFFFFF" cx="7" cy="7" r="7"></circle><polygon id="Fill-1" fill="#F8981D" points="4.66666667 2.33333333 4.66666667 11.4245258 10.0383286 6.87866667"></polygon></g></g></g></svg>',"</div>"),title:"Streaming from ClickView Local Cache"})}},{key:"initialize",value:function(){var e=this;this.localCachePlugin=this.player_.localCache(),this.localCachePlugin&&(this.localCachePlugin.on("localcachechanged",this.onLocalCacheChange),this.player_.on("dispose",(function(){e.localCachePlugin.off("localcachechanged",e.onLocalCacheChange)})),this.onLocalCacheChange())}},{key:"onLocalCacheChange",value:function(){return wl(this,void 0,void 0,regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.localCachePlugin.getActiveLocalCache();case 2:e.sent?this.show():this.hide();case 4:case"end":return e.stop()}}),e,this)})))}}])&&pl(t.prototype,n),r&&pl(t,r),o}(Fu.getComponent("Component"));function Sl(e){return(Sl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function El(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Cl(e,t){return(Cl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function kl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Pl(e);if(t){var i=Pl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return xl(this,n)}}function xl(e,t){return!t||"object"!==Sl(t)&&"function"!=typeof t?Ol(e):t}function Ol(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Pl(e){return(Pl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("localCacheIndicator",Tl);var Rl=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Al=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Cl(e,t)}(o,e);var t,n,r,i=kl(o);function o(e,t){var n;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).logger_=Fu.log.createLogger("localcache"),void 0===t)throw Error("no options defined");return n.onPlayerError=n.onPlayerError.bind(Ol(n)),n.dispose=n.dispose.bind(Ol(n)),n.localCaches_=t.localCacheAddresses.map((function(e){return new sl(e)})),n.player.ready((function(){n.initialize(),t.enabled&&n.enable()})),n}return t=o,(n=[{key:"isEnabled",get:function(){return this.enabled_}},{key:"enable",value:function(){this.enabled_=!0,this.resetActiveLocalCache()}},{key:"disable",value:function(){this.enabled_=!1}},{key:"getActiveLocalCache",value:function(){return this.enabled_?this.activeLocalCache_:null}},{key:"resetActiveLocalCache",value:function(){this.clearActiveLocalCache(),this.activeLocalCache_=this.getActiveLocalCacheInternal()}},{key:"clearActiveLocalCache",value:function(){this.activeLocalCache_&&(this.activeLocalCache_=null,this.onLocalCacheChange(null))}},{key:"dispose",value:function(){this.player.off("error",this.onPlayerError)}},{key:"initialize",value:function(){this.player.on("error",this.onPlayerError),this.player.on("dispose",this.dispose),this.player.controlBar.addChild("localCacheIndicator")}},{key:"onPlayerError",value:function(){var e;(null===(e=this.player.error())||void 0===e?void 0:e.code)===MediaError.MEDIA_ERR_NETWORK&&this.resetActiveLocalCache()}},{key:"getActiveLocalCacheInternal",value:function(){return Rl(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=[],n=function(e){return Rl(i,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,e.ping();case 2:if(!n.sent){n.next=4;break}t.push(e);case 4:case"end":return n.stop()}}),n)})))},e.next=4,Promise.all(this.localCaches_.map((function(e){return n(e)})));case 4:if(!(t.length>0)){e.next=8;break}return r=t[0],this.onLocalCacheChange(r),e.abrupt("return",r);case 8:return e.abrupt("return",null);case 9:case"end":return e.stop()}}),e,this)})))}},{key:"onLocalCacheChange",value:function(e){this.logger_.debug("Local Cache changed",e),this.trigger("localcachechanged",{localCache:e});var t=!1;e&&e.playbackProfile&&(this.logger_.debug("Changing active profile for local cache",e.playbackProfile),ll.enableProfileOrNextBest(this.player.qualityLevels(),e.playbackProfile),t=!0),t||this.player.src(this.player.src())}}])&&El(t.prototype,n),r&&El(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("localCache",Al);var Il="cv-persisttest",Ll=function(){try{return window.localStorage.setItem(Il,"cv-player-storage-test"),window.localStorage.removeItem(Il),!0}catch(e){return!1}},jl=function(e){return window.localStorage.getItem(e)},Dl=function(e,t){window.localStorage.setItem(e,t)},Nl=function(e){window.localStorage.removeItem(e)};function Ml(e){return(Ml="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ul(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bl(e,t){return(Bl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Fl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hl(e);if(t){var i=Hl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Vl(this,n)}}function Vl(e,t){return!t||"object"!==Ml(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Hl(e){return(Hl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zl=Fu.getPlugin("plugin"),ql=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Bl(e,t)}(o,e);var t,n,r,i=Fl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){if(this.player.textTracks().length){this.bindEventListeners();var e=!!this.options.showSubtitles,t=this.safeGet("cvplayer-show-subtitles");if("true"===t&&(e=!0),"false"===t&&(e=!1),e){var n=this.guessWhichTrack();n&&(n.mode="showing")}var r=this.safeGet("cvplayer-subtitle-size");r||(r=this.options.subtitleSize),r&&this.player.textTrackSettings.setSizeSetting(r)}}},{key:"safeGet",value:function(e){if(Ll())return jl(e)}},{key:"onSelectedLanguageChange",value:function(){for(var e=this.player.textTracks(),t=0;t<e.length;t++){var n=e[t];if("showing"===n.mode)return Dl("cvplayer-show-subtitles","true"),void Dl("cvplayer-selected-language",n.language)}Dl("cvplayer-show-subtitles","false"),Nl("cvplayer-selected-language")}},{key:"bindEventListeners",value:function(){var e=this;Ll()&&(this.onSelectedLanguageChange=this.onSelectedLanguageChange.bind(this),this.onChangeSubtitleSize=this.onChangeSubtitleSize.bind(this),this.player.on("cv:languageselected",this.onSelectedLanguageChange),this.player.on("changesubtitlesize",this.onChangeSubtitleSize),this.player.one("dispose",(function(){var t,n;null===(t=e.player)||void 0===t||t.off("cv:languageselected",e.onSelectedLanguageChange),null===(n=e.player)||void 0===n||n.off("changesubtitlesize",e.onChangeSubtitleSize)})))}},{key:"onChangeSubtitleSize",value:function(){var e=this.player.textTrackSettings.getSizeSetting();Dl("cvplayer-subtitle-size",e)}},{key:"guessWhichTrack",value:function(){for(var e,t,n=this.safeGet("cvplayer-selected-language")||window.navigator.language,r=this.getLanguageParts(n),i=r.language,o=r.country,a=this.player.textTracks(),s=0;s<a.length;s++){var u=a[s],l=this.getLanguageParts(u.language),c=l.language,f=l.country;if(c===i&&(e=u,f||(t=u),f===o))return e}return t||e||null}},{key:"getLanguageParts",value:function(e){var t=e.toLowerCase().split("-");return{language:t[0],country:t[1]}}}])&&Ul(t.prototype,n),r&&Ul(t,r),o}(zl);function Wl(e){return(Wl="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function $l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Gl(e,t){return(Gl=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Yl(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xl(e);if(t){var i=Xl(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Kl(this,n)}}function Kl(e,t){return!t||"object"!==Wl(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xl(e){return(Xl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistSubtitleSettingsPlugin",ql);var Ql=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Jl=Fu.getPlugin("plugin"),Zl=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Gl(e,t)}(o,e);var t,n,r,i=Yl(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e)).options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i,o=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.isLocalCacheActive();case 2:if(t=e.sent,n=t?this.options.playbackProfileLocalCache:this.options.playbackProfile,Ll()&&(r=jl(this.getStorageKey(t)))&&(n=r),i=this.player.qualityLevels(),ll.enableProfileOrNextBest(i,n),Ll()){e.next=9;break}return e.abrupt("return");case 9:this.onQualityLevelsChange=this.onQualityLevelsChange.bind(this),i.on("change",this.onQualityLevelsChange),this.player.on("dispose",(function(){i.off("change",o.onQualityLevelsChange)}));case 12:case"end":return e.stop()}}),e,this)})))}},{key:"onQualityLevelsChange",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.isLocalCacheActive();case 2:t=e.sent,n=this.player.qualityLevels(),r=n[n.selectedIndex],Dl(this.getStorageKey(t),r.id);case 6:case"end":return e.stop()}}),e,this)})))}},{key:"isLocalCacheActive",value:function(){return Ql(this,void 0,void 0,regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.player.localCache().getActiveLocalCache();case 2:return e.abrupt("return",!!e.sent);case 3:case"end":return e.stop()}}),e,this)})))}},{key:"getStorageKey",value:function(e){return e?"cvplayer-localcache-playback-quality":"cvplayer-playback-quality"}}])&&$l(t.prototype,n),r&&$l(t,r),o}(Jl);function ec(e){return(ec="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function tc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rc(e,t){return(rc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ic(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ac(e);if(t){var i=ac(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oc(this,n)}}function oc(e,t){return!t||"object"!==ec(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ac(e){return(ac=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistQualitySettingsPlugin",Zl);var sc=Fu.getPlugin("plugin"),uc="play",lc="playing",cc="pause",fc="seeking",hc="seekstart",dc="seekend",pc="ended",yc="pausedseek",mc="timeupdate",gc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&rc(e,t)}(o,e);var t,n,r,i=ic(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).eventBuffer=[],n.latestTime=0,n.lastPlayingTime=0,n.isPlaying=!1,n.isSeeking=!1,n.hasEnded=!1,n.shouldLogPlayOnTimeUpdate=!1,n.options=t,n.initialize(),n}return t=o,(n=[{key:"initialize",value:function(){this.validateOptions(),this.bindListeners(),this.startInterval()}},{key:"validateOptions",value:function(){if("function"!=typeof this.options.onFlush)throw new Error("Please provide the onFlush option")}},{key:"bindListeners",value:function(){var e,t=this,n=(tc(e={},uc,(function(){return t.onPlay()})),tc(e,cc,(function(){return t.onPause()})),tc(e,mc,(function(){return t.onTimeUpdate()})),tc(e,fc,(function(){return t.onSeeking()})),tc(e,pc,(function(){return t.onEnded()})),e);for(var r in n)n.hasOwnProperty(r)&&this.player.on(r,n[r])}},{key:"startInterval",value:function(){var e=this,t=this.options.interval||5e3;setInterval((function(){return e.flushBuffer()}),t)}},{key:"onPlay",value:function(){return this.isPlaying=!0,this.isSeeking?(this.logEvent(dc),void(this.isSeeking=!1)):this.hasEnded?(this.shouldLogPlayOnTimeUpdate=!0,void(this.hasEnded=!1)):void this.logEvent(uc)}},{key:"onPause",value:function(){var e=this;this.isSeeking||(this.pauseTimeout=window.setTimeout((function(){e.isPlaying=!1,e.logEvent(cc),delete e.pauseTimeout}),50))}},{key:"onTimeUpdate",value:function(){this.shouldLogPlayOnTimeUpdate&&(this.shouldLogPlayOnTimeUpdate=!1,this.logEvent(uc)),this.isPlaying&&!this.isSeeking&&this.logEvent(lc)}},{key:"onSeeking",value:function(){this.pauseTimeout&&(this.latestTime=this.previousLatestTime,window.clearTimeout(this.pauseTimeout),delete this.pauseTimeout),this.isPlaying||this.logEvent(yc),!this.isSeeking&&this.isPlaying&&(this.isSeeking=!0,this.logEvent(hc))}},{key:"onEnded",value:function(){this.hasEnded=!0,this.logEvent(pc)}},{key:"logEvent",value:function(e){if(this.player){var t=this.player.currentTime();e===hc&&(t=this.latestTime),this.previousLatestTime=this.latestTime,this.latestTime=this.player.currentTime(),this.eventBuffer.push({time:t,type:e})}}},{key:"shouldUseCarriedOverTime",value:function(e){return this.lastPlayingTime&&(e===lc||e===uc)}},{key:"shouldClearCarriedOverTime",value:function(e){return e===pc||e===yc}},{key:"flushBuffer",value:function(){for(var e,t=[],n={};this.eventBuffer.length;){var r=this.eventBuffer.shift();this.shouldClearCarriedOverTime(r.type)?delete this.lastPlayingTime:n.start?r.type===lc&&this.eventBuffer.length>0||(this.shouldUseCarriedOverTime(r.type)&&(this.lastPlayingTime=r.time),n.end=r,t.push(n),n={}):(this.shouldUseCarriedOverTime(r.type)&&(r.time=this.lastPlayingTime,delete this.lastPlayingTime),n.start=r)}this.eventBuffer=[],t.length&&(this.options.onFlush(t),null===(e=this.player)||void 0===e||e.trigger("progressflush"))}}])&&nc(t.prototype,n),r&&nc(t,r),o}(sc);Fu.registerPlugin("progressReporterPlugin",gc);n(380);function vc(e){return(vc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function bc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wc(e,t){return(wc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Tc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ec(e);if(t){var i=Ec(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Sc(this,n)}}function Sc(e,t){return!t||"object"!==vc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ec(e){return(Ec=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Cc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&wc(e,t)}(o,e);var t,n,r,i=Tc(o);function o(){return bc(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("span",{innerHTML:'<span class="vjs-icon-placeholder"></span>',className:"cv-drag-handle vjs-control vjs-button"},{})}}])&&_c(t.prototype,n),r&&_c(t,r),o}(Fu.getComponent("Component")),kc=["top","left","right","bottom"],xc={top:"Top",left:"Left",right:"Right",bottom:"Bottom"};n(381);function Oc(e){return(Oc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Pc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ac(e,t,n){return t&&Rc(e.prototype,t),n&&Rc(e,n),e}function Ic(e,t,n){return(Ic="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Mc(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Lc(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&jc(e,t)}function jc(e,t){return(jc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Dc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Mc(e);if(t){var i=Mc(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Nc(this,n)}}function Nc(e,t){return!t||"object"!==Oc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Mc(e){return(Mc=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Uc=Fu.getComponent("Component"),Bc=function(e){Lc(n,e);var t=Dc(n);function n(e,r){var i;return Pc(this,n),(i=t.call(this,e,r)).bindEventListeners(),i}return Ac(n,[{key:"createEl",value:function(){return Ic(Mc(n.prototype),"createEl",this).call(this,"div",{},{class:"cv-drop-target cv-drop-".concat(this.options_.side)})}},{key:"bindEventListeners",value:function(){var e=this,t=this.el(),n=function(t){t.preventDefault(),t.dataTransfer.dropEffect="move",e.addClass("cv-drag-over")},r=function(t){t.preventDefault(),e.removeClass("cv-drag-over"),e.player_.whiteboardModePlugin().setWhiteboardMode(e.options_.side)},i=function(){e.removeClass("cv-drag-over")};t.addEventListener("dragover",n),t.addEventListener("drop",r),t.addEventListener("dragleave",i),this.on("dispose",(function(){t.removeEventListener("dragover",n),t.removeEventListener("drop",r),t.removeEventListener("dragleave",i)}))}}]),n}(Uc),Fc=function(e){Lc(n,e);var t=Dc(n);function n(e,r){var i;return Pc(this,n),(i=t.call(this,e,r)).addChildren(),i}return Ac(n,[{key:"addChildren",value:function(){var e=this;kc.forEach((function(t){e.addChild(new Bc(e.player_,{side:t}))}))}}]),n}(Uc);function Vc(e){return(Vc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Hc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zc(e,t){return(zc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function qc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$c(e);if(t){var i=$c(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Wc(this,n)}}function Wc(e,t){return!t||"object"!==Vc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $c(e){return($c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Gc=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zc(e,t)}(o,e);var t,n,r,i=qc(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"handleClick",value:function(){this.player_.whiteboardModePlugin().setWhiteboardMode(this.options_.side)}}])&&Hc(t.prototype,n),r&&Hc(t,r),o}(Fu.getComponent("MenuItem"));function Yc(e){return(Yc="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Kc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xc(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Qc(e,t,n){return(Qc="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=tf(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Jc(e,t){return(Jc=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Zc(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=tf(e);if(t){var i=tf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ef(this,n)}}function ef(e,t){return!t||"object"!==Yc(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function tf(e){return(tf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var nf=Fu.getComponent("MenuButton"),rf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Jc(e,t)}(o,e);var t,n,r,i=Zc(o);function o(){var e;return Kc(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!0,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"createItems",value:function(){var e=this,t=this.player_.whiteboardModePlugin().side,n=[];return kc.forEach((function(r){n.push(new Gc(e.player_,{side:r,label:xc[r],selectable:!0,multiSelectable:!1,selected:r===t}))})),n}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Qc(tf(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"getCollabsibleName",value:function(){return"Video controls"}},{key:"getCollabsibleValue",value:function(){var e=this.player_.whiteboardModePlugin().side;return xc[e]}},{key:"showInCollabsibleMenu",value:function(){return this.player_.isFullscreen()}},{key:"showCollapsibleMenu",value:function(){nf.prototype.handleClick.apply(this)}}])&&Xc(t.prototype,n),r&&Xc(t,r),o}(nf);n(382);function of(e){return(of="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function af(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sf(e,t){return(sf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function uf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=cf(e);if(t){var i=cf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return lf(this,n)}}function lf(e,t){return!t||"object"!==of(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function cf(e){return(cf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ff="cv-whiteboard-side",hf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&sf(e,t)}(o,e);var t,n,r,i=uf(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).side="bottom",t.player.ready((function(){t.initialize()})),t}return t=o,(n=[{key:"initialize",value:function(){if(Ll()){var e=jl(ff);e&&(this.side=e)}this.initCollapserator(),this.initDragTargets(),this.initFullscreenListener()}},{key:"initCollapserator",value:function(){var e=this,t=this.player.getChild("collapserator"),n=new Cc(this.player);this.button=new rf(this.player),t.addChild(n),t.addChild(this.button),this.player.trigger("cv-updatecog");var r=function(){t.el().setAttribute("draggable","true")},i=function(){t.el().setAttribute("draggable","false")},o=function(t){e.player.addClass("cv-dragging"),t.dataTransfer.setData("text/plain","handle")},a=function(){e.player.removeClass("cv-dragging"),t.el().setAttribute("draggable","false")};n.el().addEventListener("mousedown",r),n.el().addEventListener("mouseup",i),t.el().addEventListener("dragstart",o),t.el().addEventListener("dragend",a),this.player.on("dispoe",(function(){n.el().removeEventListener("mousedown",r),n.el().removeEventListener("mouseup",i),t.el().removeEventListener("dragstart",o),t.el().removeEventListener("dragend",a)}))}},{key:"initDragTargets",value:function(){this.player.addChild(new Fc(this.player))}},{key:"initFullscreenListener",value:function(){var e=this;this.update=this.update.bind(this),this.player.on("fullscreenchange",this.update),this.player.on("dispose",(function(){var t;null===(t=e.player)||void 0===t||t.off("fullscreenchange",e.update)}))}},{key:"setWhiteboardMode",value:function(e){this.side=e,this.button.update(),Ll()&&Dl(ff,e),this.player.trigger("cv-whiteboard-change"),this.update()}},{key:"update",value:function(){this.player.removeClass("cv-whiteboard-top"),this.player.removeClass("cv-whiteboard-left"),this.player.removeClass("cv-whiteboard-right"),this.player.trigger("resizemenus"),this.player.isFullscreen()&&"bottom"!==this.side&&this.player.addClass("cv-whiteboard-".concat(this.side))}}])&&af(t.prototype,n),r&&af(t,r),o}(Fu.getPlugin("plugin"));function df(e){return(df="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function pf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yf(e,t){return(yf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function mf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=vf(e);if(t){var i=vf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return gf(this,n)}}function gf(e,t){return!t||"object"!==df(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function vf(e){return(vf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("whiteboardModePlugin",hf),window.__onGCastApiAvailable=function(e){e&&(bf=new _f)},window.videojs=Fu;var bf,_f=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&yf(e,t)}(o,e);var t,n,r,i=mf(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this,null)).setOptions(),e.remotePlayer=new cast.framework.RemotePlayer,e.remotePlayerController=new cast.framework.RemotePlayerController(e.remotePlayer),e.bindListeners(),e}return t=o,(n=[{key:"play",value:function(){}},{key:"castConext",get:function(){return cast.framework.CastContext.getInstance()}},{key:"setOptions",value:function(){this.castConext.setOptions({receiverApplicationId:chrome.cast.media.DEFAULT_MEDIA_RECEIVER_APP_ID,autoJoinPolicy:chrome.cast.AutoJoinPolicy.ORIGIN_SCOPED})}},{key:"castState",get:function(){return this.castConext.getCastState()}},{key:"castSession",get:function(){return bf.castConext.getCurrentSession()}},{key:"isConnected",value:function(){return this.castState===cast.framework.CastState.CONNECTED&&this.remotePlayer.isConnected}},{key:"bindListeners",value:function(){this.onCastStateChange=this.onCastStateChange.bind(this),this.onIsConnectedChanged=this.onIsConnectedChanged.bind(this),this.castConext.addEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,this.onCastStateChange),this.remotePlayerController.addEventListener(cast.framework.RemotePlayerEventType.IS_CONNECTED_CHANGED,this.onIsConnectedChanged)}},{key:"onIsConnectedChanged",value:function(){try{this.trigger("isconnectedchanged",this.remotePlayer.isConnected)}catch(e){console.log(e)}console.log(this.remotePlayer.isConnected)}},{key:"dispose",value:function(){this.castConext.removeEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,this.onCastStateChange),this.remotePlayerController.removeEventListener(cast.framework.RemotePlayerEventType.IS_CONNECTED_CHANGED,this.onIsConnectedChanged)}},{key:"onCastStateChange",value:function(e){this.hasAvailableDevices(e.castState)?this.trigger("devicesAvailable"):this.trigger("devicesUnabailable")}},{key:"stopCasting",value:function(){this.castConext.getCurrentSession().endSession(!0)}},{key:"getDeviceName",value:function(){var e,t;return null===(t=null===(e=this.castConext.getCurrentSession())||void 0===e?void 0:e.getCastDevice())||void 0===t?void 0:t.friendlyName}},{key:"hasAvailableDevices",value:function(e){return e||(e=this.castConext.getCastState()),e===cast.framework.CastState.NOT_CONNECTED||e===cast.framework.CastState.CONNECTING||e===cast.framework.CastState.CONNECTED}}])&&pf(t.prototype,n),r&&pf(t,r),o}(Fu.getComponent("Component"));n(383);function wf(e){return(wf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Tf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Sf(e,t,n){return(Sf="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=xf(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ef(e,t){return(Ef=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Cf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=xf(e);if(t){var i=xf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kf(this,n)}}function kf(e,t){return!t||"object"!==wf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function xf(e){return(xf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Of=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ef(e,t)}(o,e);var t,n,r,i=Cf(o);function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=i.call(this,null)).update(),e}return t=o,(n=[{key:"play",value:function(){}},{key:"createEl",value:function(){return Sf(xf(o.prototype),"createEl",this).call(this,"div",{className:"cv-chromecast-tech"})}},{key:"setTitle",value:function(e){this.title=e,this.update()}},{key:"setPoster",value:function(e){this.poster=e,this.update()}},{key:"disconnect",value:function(e){e.stopPropagation(),bf.stopCasting()}},{key:"update",value:function(){this.el_.innerHTML='\n <div class="cv-chromecast-content">\n '.concat(this.title?"<h1>".concat(this.title,"</h1>"):"","\n <p>Currently playing on: ").concat(bf.getDeviceName(),'</p>\n </div>\n <div class="cv-chromecast-background" style="background-image: url(').concat(this.poster,')"></div>\n ');var e=document.createElement("div");e.className="btn btn-primary cursor-pointer",e.onclick=this.disconnect.bind(this),e.innerHTML="Stop casting",this.el_.querySelector(".cv-chromecast-content").appendChild(e)}}])&&Tf(t.prototype,n),r&&Tf(t,r),o}(Fu.getComponent("Component"));function Pf(e){return(Pf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Rf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Af(e,t,n){return(Af="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Df(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function If(e,t){return(If=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Lf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Df(e);if(t){var i=Df(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jf(this,n)}}function jf(e,t){return!t||"object"!==Pf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Df(e){return(Df=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Nf=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Mf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&If(e,t)}(o,e);var t,n,r,i=Lf(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),bf.isConnected()&&e.source&&n.setSource(e.source),n.bindEventListeners(),e.poster&&n.setPoster(e.poster),n.triggerReady(),n}return t=o,r=[{key:"canPlaySource",value:function(){return bf.isConnected()}},{key:"isSupported",value:function(){return!!bf&&bf.isConnected()}}],(n=[{key:"createEl",value:function(){return this.ui=new Of,this.ui.el()}},{key:"bindEventListeners",value:function(){this.onPlayerStateChanged=this.onPlayerStateChanged.bind(this),this.onVolumeLevelChanged=this.onVolumeLevelChanged.bind(this),this.onCurrentTimeChanged=this.onCurrentTimeChanged.bind(this),this.onDurationChanged=this.onDurationChanged.bind(this);var e=cast.framework.RemotePlayerEventType,t=bf.remotePlayerController;t.addEventListener(e.PLAYER_STATE_CHANGED,this.onPlayerStateChanged),t.addEventListener(e.VOLUME_LEVEL_CHANGED,this.onVolumeLevelChanged),t.addEventListener(e.IS_MUTED_CHANGED,this.onVolumeLevelChanged),t.addEventListener(e.CURRENT_TIME_CHANGED,this.onCurrentTimeChanged),t.addEventListener(e.DURATION_CHANGED,this.onDurationChanged)}},{key:"dispose",value:function(){var e=cast.framework.RemotePlayerEventType,t=bf.remotePlayerController;t.removeEventListener(e.PLAYER_STATE_CHANGED,this.onPlayerStateChanged),t.removeEventListener(e.VOLUME_LEVEL_CHANGED,this.onVolumeLevelChanged),t.removeEventListener(e.IS_MUTED_CHANGED,this.onVolumeLevelChanged),t.removeEventListener(e.CURRENT_TIME_CHANGED,this.onCurrentTimeChanged),t.removeEventListener(e.DURATION_CHANGED,this.onDurationChanged),Af(Df(o.prototype),"dispose",this).call(this)}},{key:"onPlayerStateChanged",value:function(){var e=bf.remotePlayer.playerState;e===chrome.cast.media.PlayerState.PLAYING?(this.trigger("play"),this.trigger("playing")):e===chrome.cast.media.PlayerState.PAUSED?this.trigger("pause"):e===chrome.cast.media.PlayerState.BUFFERING?this.trigger("waiting"):e===chrome.cast.media.PlayerState.IDLE&&this.ended()&&this.trigger("ended")}},{key:"stopCasting",value:function(){var e=window.setTimeout((function(){bf.stopCasting()}),1e4);this.on("dispose",(function(){window.clearTimeout(e)}))}},{key:"setPoster",value:function(e){this.poster_=e,this.ui.setPoster(e)}},{key:"poster",value:function(){return this.poster_}},{key:"setTitle",value:function(e){this.ui.setTitle(e)}},{key:"onVolumeLevelChanged",value:function(){this.trigger("volumechange")}},{key:"onCurrentTimeChanged",value:function(){this.trigger("timeupdate")}},{key:"onDurationChanged",value:function(){this.trigger("durationchange")}},{key:"setSource",value:function(e){var t,n;return Nf(this,void 0,void 0,regeneratorRuntime.mark((function r(){var i,o,a;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(i=bf.castSession.getMediaSession(),this.trigger("waiting"),(null===(t=null==i?void 0:i.media)||void 0===t?void 0:t.contentId)!==e.src||(null===(n=null==i?void 0:i.media)||void 0===n?void 0:n.contentType)!==e.type){r.next=5;break}return this.triggerLoaded(),r.abrupt("return");case 5:return o=new chrome.cast.media.MediaInfo(e.src,e.type),(a=new chrome.cast.media.LoadRequest(o)).autoplay=!0,a.currentTime=this.currentTime()||this.options_.startTime||0,r.prev=9,r.next=12,bf.castSession.loadMedia(a);case 12:r.next=17;break;case 14:r.prev=14,r.t0=r.catch(9),this.trigger("error");case 17:this.triggerLoaded();case 18:case"end":return r.stop()}}),r,this,[[9,14]])})))}},{key:"triggerLoaded",value:function(){var e=this,t=function(){e.trigger("loadstart"),e.trigger("loadeddata"),e.trigger("play"),e.trigger("playing")};if(this.duration())t();else{var n=bf.remotePlayerController,r=cast.framework.RemotePlayerEventType,i=function e(){t(),n.removeEventListener(r.DURATION_CHANGED,e),n.removeEventListener(r.CURRENT_TIME_CHANGED,e)};n.addEventListener(r.DURATION_CHANGED,i),n.addEventListener(r.CURRENT_TIME_CHANGED,i)}}},{key:"play",value:function(){this.paused()&&bf.remotePlayerController.playOrPause()}},{key:"pause",value:function(){!this.paused()&&bf.remotePlayer.canPause&&bf.remotePlayerController.playOrPause()}},{key:"paused",value:function(){return bf.remotePlayer.isPaused||this.ended()||null===bf.remotePlayer.playerState}},{key:"ended",value:function(){var e,t=null===(e=bf.castSession)||void 0===e?void 0:e.getMediaSession();return!t||t.idleReason===chrome.cast.media.IdleReason.FINISHED}},{key:"setCurrentTime",value:function(e){var t=this.duration();e>t||!bf.remotePlayer.canSeek||(bf.remotePlayer.currentTime=Math.min(t-1,e),bf.remotePlayerController.seek(),this.trigger("timeupdate"))}},{key:"currentTime",value:function(){return bf.remotePlayer.currentTime}},{key:"duration",value:function(){return this.durationCache_=bf.remotePlayer.duration,this.durationCache_}},{key:"volume",value:function(){return bf.remotePlayer.volumeLevel}},{key:"setVolume",value:function(e){bf.remotePlayer.volumeLevel=e,bf.remotePlayerController.setVolumeLevel(),this.trigger("volumechange")}},{key:"muted",value:function(){return bf.remotePlayer.isMuted}},{key:"setMuted",value:function(e){this.muted()===e&&bf.remotePlayerController.muteOrUnmute()}},{key:"buffered",value:function(){}},{key:"seekable",value:function(){return Fu.createTimeRanges(0,this.duration())}},{key:"controls",value:function(){return!1}},{key:"playsinline",value:function(){return!0}},{key:"supportsFullScreen",value:function(){return!0}},{key:"setAutoplay",value:function(){}},{key:"preload",value:function(){}},{key:"load",value:function(){}},{key:"setPlaybackRate",value:function(){}},{key:"playbackRate",value:function(){var e=bf.castSession.getMediaSession();return e?e.playbackRate:1}},{key:"readyState",value:function(){return bf.remotePlayer.playerState===chrome.cast.media.PlayerState.IDLE||bf.remotePlayer.playerState===chrome.cast.media.PlayerState.BUFFERING?0:4}}])&&Rf(t.prototype,n),r&&Rf(t,r),o}(Fu.getComponent("Tech")),Uf=Mf.prototype;Uf.featuresVolumeControl=!0,Uf.featuresPlaybackRate=!1,Uf.movingMediaElementInDOM=!1,Uf.featuresFullscreenResize=!0,Uf.featuresTimeupdateEvents=!0,Uf.featuresProgressEvents=!1,Uf.featuresNativeTextTracks=!1,Uf.featuresNativeAudioTracks=!1,Uf.featuresNativeVideoTracks=!1,Fu.registerTech("chromecast",Mf);n(384);function Bf(e){return(Bf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ff(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Vf(e,t,n){return(Vf="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=$f(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Hf(e,t){return(Hf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$f(e);if(t){var i=$f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qf(this,n)}}function qf(e,t){return!t||"object"!==Bf(t)&&"function"!=typeof t?Wf(e):t}function Wf(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $f(e){return($f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Gf=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hf(e,t)}(o,e);var t,n,r,i=zf(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).alwaysCollapsed=!1,t.isCollapsed=!1,t.isCollabsible=!0,t.onDevicesAvailable=t.onDevicesAvailable.bind(Wf(t)),t.onDevicesUnavailable=t.onDevicesUnavailable.bind(Wf(t)),bf.on("devicesAvailable",t.onDevicesAvailable),bf.on("devicesUnabailable",t.onDevicesUnavailable),t.player_.one("dispose",(function(){bf.off("devicesAvailable",t.onDevicesAvailable),bf.off("devicesUnabailable",t.onDevicesUnavailable)})),bf.hasAvailableDevices()||t.hide(),t}return t=o,(n=[{key:"onDevicesAvailable",value:function(){this.show()}},{key:"onDevicesUnavailable",value:function(){this.hide()}},{key:"buildCSSClass",value:function(){return"cv-chromecast-button"}},{key:"createEl",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Vf($f(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:'\n <span aria-hidden="true" class="vjs-icon-placeholder"></span>\n <google-cast-launcher></google-cast-launcher>\n '}),n)}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){Vf($f(o.prototype),"handleClick",this).call(this,null)}}])&&Ff(t.prototype,n),r&&Ff(t,r),o}(Fu.getComponent("Button"));function Yf(e){return(Yf="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Kf(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Xf(e,t){return(Xf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Qf(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Zf(e);if(t){var i=Zf(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Jf(this,n)}}function Jf(e,t){return!t||"object"!==Yf(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Zf(e){return(Zf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Gf.prototype.controlText_="Chromecast",Fu.registerComponent("ChromecastButton",Gf);var eh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Xf(e,t)}(o,e);var t,n,r,i=Qf(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,bf?(e.ready((function(){return n.onReady()})),n):Jf(n)}return t=o,(n=[{key:"onReady",value:function(){var e,t=this,n=this.player.getChild("collapserator"),r=null===(e=null==n?void 0:n.children())||void 0===e?void 0:e.findIndex((function(e){return"CustomControlSpacer"===e.name()}));r&&-1!==r&&(n.addChild("ChromecastButton",{},r+1),this.onIsConnectedChanged=this.onIsConnectedChanged.bind(this),bf.on("isconnectedchanged",this.onIsConnectedChanged),this.player.one("dispose",(function(){bf.off("isconnectedchanged",t.onIsConnectedChanged)})),this.setTechTitle())}},{key:"setTechTitle",value:function(){var e=this.player.tech();"ChromecastTech"===e.name()&&e.setTitle(this.options.title)}},{key:"onIsConnectedChanged",value:function(){var e=this,t=this.player.currentTime(),n=this.player.paused();this.player.src(this.player.currentSources()),this.player.ready((function(){e.player.currentTime(t),n?e.player.pause():e.player.play(),e.setTechTitle()}))}}])&&Kf(t.prototype,n),r&&Kf(t,r),o}(Fu.getPlugin("plugin"));function th(e){return(th="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function nh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ih(e,t){return(ih=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function oh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sh(e);if(t){var i=sh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ah(this,n)}}function ah(e,t){return!t||"object"!==th(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function sh(e){return(sh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("chromecast",eh);var uh=Fu.getComponent("Menu"),lh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ih(e,t)}(o,e);var t,n,r,i=oh(o);function o(){return nh(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"handleBlur",value:function(e){var t=e.relatedTarget||document.activeElement;this.el().contains(t)||uh.prototype.handleBlur.call(this,e)}}])&&rh(t.prototype,n),r&&rh(t,r),o}(uh);function ch(e){return(ch="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function fh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function dh(e,t){return(dh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ph(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mh(e);if(t){var i=mh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yh(this,n)}}function yh(e,t){return!t||"object"!==ch(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mh(e){return(mh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("Menu",lh);var gh=Fu.getComponent("Component"),vh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dh(e,t)}(o,e);var t,n,r,i=ph(o);function o(){return fh(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"createMenu",value:function(){var e,t=new lh(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var n=Fu.dom.createEl("li",{className:"vjs-menu-title",innerHTML:(e=this.options_.title,"string"!=typeof e?e:e.replace(/./,(function(e){return e.toUpperCase()}))),tabIndex:-1});this.hideThreshold_+=1;var r=new gh(this.player_,{el:n});t.addItem(r)}if(this.items=this.createItems(),this.items)for(var i=0;i<this.items.length;i++)t.addItem(this.items[i]);return t}}])&&hh(t.prototype,n),r&&hh(t,r),o}(Fu.getComponent("MenuButton"));Fu.registerComponent("MenuButton",vh);n(385);function bh(e){return(bh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Th(e,t,n){return(Th="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=kh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sh(e,t){return(Sh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Eh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=kh(e);if(t){var i=kh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ch(this,n)}}function Ch(e,t){return!t||"object"!==bh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function kh(e){return(kh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sh(e,t)}(o,e);var t,n,r,i=Eh(o);function o(){return _h(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-time-wrapper ".concat(Th(kh(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Th(kh(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}}])&&wh(t.prototype,n),r&&wh(t,r),o}(Fu.getComponent("Component"));function Oh(e){return(Oh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ph(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Rh(e,t,n){return(Rh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=jh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ah(e,t){return(Ah=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ih(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jh(e);if(t){var i=jh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Lh(this,n)}}function Lh(e,t){return!t||"object"!==Oh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jh(e){return(jh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}xh.prototype.options_={children:["currentTimeDisplay","remainingTimeDisplay"]},Fu.registerComponent("TimeWrapper",xh);var Dh=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ah(e,t)}(o,e);var t,n,r,i=Ih(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).playNext=e.nextVideoPlugin().getShouldPlayNext(),n.toggle(n.playNext),n}return t=o,(n=[{key:"handleToggle",value:function(){this.toggle(!this.playNext)}},{key:"toggle",value:function(e){e?this.toggleOn():this.toggleOff()}},{key:"toggleOn",value:function(){this.playNext=!0,Fu.dom.addClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext)}},{key:"toggleOff",value:function(){this.playNext=!1,Fu.dom.removeClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext)}},{key:"handleClick",value:function(e){e.stopImmediatePropagation()}},{key:"createEl",value:function(e,t,n){this.handlerBound||(this.handleToggle=this.handleToggle.bind(this),this.handlerBound=!0),this.toggleEl&&this.toggleEl.removeEventListener("click",this.handleToggle),this.toggleEl=Fu.dom.createEl("div",{className:"custom-toggle toggle-option float-right",innerHTML:'<span class="handle"></span></div>'}),this.toggleEl.addEventListener("click",this.handleToggle);var r=Rh(jh(o.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:'\n <span class="vjs-menu-item-text">autoplay</span>\n <span class="cv-toggle-container"></span>'},n);return r.children[1].appendChild(this.toggleEl),r}}])&&Ph(t.prototype,n),r&&Ph(t,r),o}(Fu.getComponent("MenuItem"));Fu.registerComponent("NextVideoMenuItem",Dh);n(386);function Nh(e){return(Nh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Mh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bh(e,t,n){return t&&Uh(e.prototype,t),n&&Uh(e,n),e}function Fh(e,t,n){return(Fh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Wh(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Vh(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hh(e,t)}function Hh(e,t){return(Hh=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function zh(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Wh(e);if(t){var i=Wh(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return qh(this,n)}}function qh(e,t){return!t||"object"!==Nh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Wh(e){return(Wh=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var $h=Fu.getComponent("MenuItem"),Gh=Fu.getComponent("NextVideoMenuItem"),Yh=function(e){Vh(n,e);var t=zh(n);function n(e,r){return Mh(this,n),t.call(this,e,r)}return Bh(n,[{key:"handleClick",value:function(e){var t=this;Fh(Wh(n.prototype),"handleClick",this).call(this,e),this.requestAnimationFrame((function(){t.options_.item.showCollapsibleMenu()}))}},{key:"createEl",value:function(e,t,r){if(!this.options_.item)return Fh(Wh(n.prototype),"createEl",this).call(this,e,t,r);var i=this.options_.item.getCollabsibleName(),o=this.options_.item.getCollabsibleValue(),a='\n <span class="vjs-menu-item-text">'.concat(i,"</span>\n <span>").concat(o,"</span>");return Fh(Wh(n.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:a},r)}}]),n}($h),Kh=Fu.getComponent("MenuButton"),Xh=function(e){Vh(n,e);var t=zh(n);function n(e,r){return Mh(this,n),t.call(this,e,r)}return Bh(n,[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Fh(Wh(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"buildCSSClass",value:function(){return"cv-cog-button ".concat(Fh(Wh(n.prototype),"buildCSSClass",this).call(this))}},{key:"pressButton",value:function(){this.update(),Kh.prototype.pressButton.apply(this)}},{key:"createItems",value:function(){var e=[];this.renderPlayNext&&e.push(new Gh(this.player_,this.options_));for(var t=0;t<this.options_.items.length;t++){var n=this.options_.items[t];n.isCollabsible&&(n.showInCollabsibleMenu()&&n.isCollapsed&&e.push(new Yh(this.player_,{item:n})))}return e}},{key:"update",value:function(){Fh(Wh(n.prototype),"update",this).call(this),this.player_.trigger("resizemenus")}},{key:"showPlayNext",value:function(){this.renderPlayNext=!0,this.update()}}]),n}(Kh);function Qh(e){return(Qh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Jh(e,t,n){return(Jh="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ad(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Zh(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ed(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function td(e,t,n){return t&&ed(e.prototype,t),n&&ed(e,n),e}function nd(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&rd(e,t)}function rd(e,t){return(rd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function id(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ad(e);if(t){var i=ad(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return od(this,n)}}function od(e,t){return!t||"object"!==Qh(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ad(e){return(ad=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("cogButton",Xh);var sd=Fu.getComponent("MenuItem"),ud=Fu.getComponent("MenuButton"),ld=["small","medium","large"],cd=function(e){nd(n,e);var t=id(n);function n(e,r){return Zh(this,n),t.call(this,e,r)}return td(n,[{key:"handleClick",value:function(){this.player_.textTrackSettings.setSizeSetting(this.options_.value)}}]),n}(sd),fd=function(e){nd(n,e);var t=id(n);function n(e,r){var i;return Zh(this,n),(i=t.call(this,e,r)).alwaysCollapsed=!0,i.isCollapsed=!1,i.isCollabsible=!0,i.player_.ready((function(){i.update()})),i}return td(n,[{key:"createItems",value:function(){var e=this,t=this.player_.textTrackSettings;if(t){var n=t.getSizeSetting();return ld.map((function(t){return new cd(e.player_,{label:t,selectable:!0,multiSelectable:!1,selected:t===n,value:t})}))}}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Jh(ad(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"getCollabsibleName",value:function(){return"Subtitle Size"}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!1}},{key:"showCollapsibleMenu",value:function(){ud.prototype.handleClick.apply(this)}}]),n}(ud);Fu.registerComponent("SubtitleSizeButton",fd);n(387);var hd=n(112),dd=n.n(hd),pd=(n(388),n(390),n(142)),yd=n.n(pd),md=n(143),gd=n.n(md),vd=n(235),bd=n.n(vd),_d=n(236),wd=(n(392),null),Td=null;function Sd(){if(null===wd){if("undefined"==typeof document)return wd=0;var e=document.body,t=document.createElement("div");t.classList.add("simplebar-hide-scrollbar"),e.appendChild(t);var n=t.getBoundingClientRect().right;e.removeChild(t),wd=n}return wd}dd.a&&window.addEventListener("resize",(function(){Td!==window.devicePixelRatio&&(Td=window.devicePixelRatio,wd=null)}));var Ed=function(e){return Array.prototype.reduce.call(e,(function(e,t){var n=t.name.match(/data-simplebar-(.+)/);if(n){var r=n[1].replace(/\W+(.)/g,(function(e,t){return t.toUpperCase()}));switch(t.value){case"true":e[r]=!0;break;case"false":e[r]=!1;break;case void 0:e[r]=!0;break;default:e[r]=t.value}}return e}),{})};function Cd(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView:window}function kd(e){return e&&e.ownerDocument?e.ownerDocument:document}var xd=function(){function e(t,n){var r=this;this.onScroll=function(){var e=Cd(r.el);r.scrollXTicking||(e.requestAnimationFrame(r.scrollX),r.scrollXTicking=!0),r.scrollYTicking||(e.requestAnimationFrame(r.scrollY),r.scrollYTicking=!0)},this.scrollX=function(){r.axis.x.isOverflowing&&(r.showScrollbar("x"),r.positionScrollbar("x")),r.scrollXTicking=!1},this.scrollY=function(){r.axis.y.isOverflowing&&(r.showScrollbar("y"),r.positionScrollbar("y")),r.scrollYTicking=!1},this.onMouseEnter=function(){r.showScrollbar("x"),r.showScrollbar("y")},this.onMouseMove=function(e){r.mouseX=e.clientX,r.mouseY=e.clientY,(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseMoveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseMoveForAxis("y")},this.onMouseLeave=function(){r.onMouseMove.cancel(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseLeaveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseLeaveForAxis("y"),r.mouseX=-1,r.mouseY=-1},this.onWindowResize=function(){r.scrollbarWidth=r.getScrollbarWidth(),r.hideNativeScrollbar()},this.hideScrollbars=function(){r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.track.rect)||(r.axis.y.scrollbar.el.classList.remove(r.classNames.visible),r.axis.y.isVisible=!1),r.isWithinBounds(r.axis.x.track.rect)||(r.axis.x.scrollbar.el.classList.remove(r.classNames.visible),r.axis.x.isVisible=!1)},this.onPointerEvent=function(e){var t,n;r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&(t=r.isWithinBounds(r.axis.x.track.rect)),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&(n=r.isWithinBounds(r.axis.y.track.rect)),(t||n)&&(e.preventDefault(),e.stopPropagation(),"mousedown"===e.type&&(t&&(r.axis.x.scrollbar.rect=r.axis.x.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.x.scrollbar.rect)?r.onDragStart(e,"x"):r.onTrackClick(e,"x")),n&&(r.axis.y.scrollbar.rect=r.axis.y.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.scrollbar.rect)?r.onDragStart(e,"y"):r.onTrackClick(e,"y"))))},this.drag=function(t){var n=r.axis[r.draggedAxis].track,i=n.rect[r.axis[r.draggedAxis].sizeAttr],o=r.axis[r.draggedAxis].scrollbar,a=r.contentWrapperEl[r.axis[r.draggedAxis].scrollSizeAttr],s=parseInt(r.elStyles[r.axis[r.draggedAxis].sizeAttr],10);t.preventDefault(),t.stopPropagation();var u=(("y"===r.draggedAxis?t.pageY:t.pageX)-n.rect[r.axis[r.draggedAxis].offsetAttr]-r.axis[r.draggedAxis].dragOffset)/(i-o.size)*(a-s);"x"===r.draggedAxis&&(u=r.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?u-(i+o.size):u,u=r.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-u:u),r.contentWrapperEl[r.axis[r.draggedAxis].scrollOffsetAttr]=u},this.onEndDrag=function(e){var t=kd(r.el),n=Cd(r.el);e.preventDefault(),e.stopPropagation(),r.el.classList.remove(r.classNames.dragging),t.removeEventListener("mousemove",r.drag,!0),t.removeEventListener("mouseup",r.onEndDrag,!0),r.removePreventClickId=n.setTimeout((function(){t.removeEventListener("click",r.preventClick,!0),t.removeEventListener("dblclick",r.preventClick,!0),r.removePreventClickId=null}))},this.preventClick=function(e){e.preventDefault(),e.stopPropagation()},this.el=t,this.minScrollbarWidth=20,this.options=Object.assign({},e.defaultOptions,{},n),this.classNames=Object.assign({},e.defaultOptions.classNames,{},this.options.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}}},this.removePreventClickId=null,e.instances.has(this.el)||(this.recalculate=yd()(this.recalculate.bind(this),64),this.onMouseMove=yd()(this.onMouseMove.bind(this),64),this.hideScrollbars=gd()(this.hideScrollbars.bind(this),this.options.timeout),this.onWindowResize=gd()(this.onWindowResize.bind(this),64,{leading:!0}),e.getRtlHelpers=bd()(e.getRtlHelpers),this.init())}e.getRtlHelpers=function(){var t=document.createElement("div");t.innerHTML='<div class="hs-dummy-scrollbar-size"><div style="height: 200%; width: 200%; margin: 10px 0;"></div></div>';var n=t.firstElementChild;document.body.appendChild(n);var r=n.firstElementChild;n.scrollLeft=0;var i=e.getOffset(n),o=e.getOffset(r);n.scrollLeft=999;var a=e.getOffset(r);return{isRtlScrollingInverted:i.left!==o.left&&o.left-a.left!=0,isRtlScrollbarInverted:i.left!==o.left}},e.getOffset=function(e){var t=e.getBoundingClientRect(),n=kd(e),r=Cd(e);return{top:t.top+(r.pageYOffset||n.documentElement.scrollTop),left:t.left+(r.pageXOffset||n.documentElement.scrollLeft)}};var t=e.prototype;return t.init=function(){e.instances.set(this.el,this),dd.a&&(this.initDOM(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},t.initDOM=function(){var e=this;if(Array.prototype.filter.call(this.el.children,(function(t){return t.classList.contains(e.classNames.wrapper)})).length)this.wrapperEl=this.el.querySelector("."+this.classNames.wrapper),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector("."+this.classNames.contentWrapper),this.contentEl=this.options.contentNode||this.el.querySelector("."+this.classNames.contentEl),this.offsetEl=this.el.querySelector("."+this.classNames.offset),this.maskEl=this.el.querySelector("."+this.classNames.mask),this.placeholderEl=this.findChild(this.wrapperEl,"."+this.classNames.placeholder),this.heightAutoObserverWrapperEl=this.el.querySelector("."+this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl=this.el.querySelector("."+this.classNames.heightAutoObserverEl),this.axis.x.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.horizontal),this.axis.y.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.vertical);else{for(this.wrapperEl=document.createElement("div"),this.contentWrapperEl=document.createElement("div"),this.offsetEl=document.createElement("div"),this.maskEl=document.createElement("div"),this.contentEl=document.createElement("div"),this.placeholderEl=document.createElement("div"),this.heightAutoObserverWrapperEl=document.createElement("div"),this.heightAutoObserverEl=document.createElement("div"),this.wrapperEl.classList.add(this.classNames.wrapper),this.contentWrapperEl.classList.add(this.classNames.contentWrapper),this.offsetEl.classList.add(this.classNames.offset),this.maskEl.classList.add(this.classNames.mask),this.contentEl.classList.add(this.classNames.contentEl),this.placeholderEl.classList.add(this.classNames.placeholder),this.heightAutoObserverWrapperEl.classList.add(this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl.classList.add(this.classNames.heightAutoObserverEl);this.el.firstChild;)this.contentEl.appendChild(this.el.firstChild);this.contentWrapperEl.appendChild(this.contentEl),this.offsetEl.appendChild(this.contentWrapperEl),this.maskEl.appendChild(this.offsetEl),this.heightAutoObserverWrapperEl.appendChild(this.heightAutoObserverEl),this.wrapperEl.appendChild(this.heightAutoObserverWrapperEl),this.wrapperEl.appendChild(this.maskEl),this.wrapperEl.appendChild(this.placeholderEl),this.el.appendChild(this.wrapperEl)}if(!this.axis.x.track.el||!this.axis.y.track.el){var t=document.createElement("div"),n=document.createElement("div");t.classList.add(this.classNames.track),n.classList.add(this.classNames.scrollbar),t.appendChild(n),this.axis.x.track.el=t.cloneNode(!0),this.axis.x.track.el.classList.add(this.classNames.horizontal),this.axis.y.track.el=t.cloneNode(!0),this.axis.y.track.el.classList.add(this.classNames.vertical),this.el.appendChild(this.axis.x.track.el),this.el.appendChild(this.axis.y.track.el)}this.axis.x.scrollbar.el=this.axis.x.track.el.querySelector("."+this.classNames.scrollbar),this.axis.y.scrollbar.el=this.axis.y.track.el.querySelector("."+this.classNames.scrollbar),this.options.autoHide||(this.axis.x.scrollbar.el.classList.add(this.classNames.visible),this.axis.y.scrollbar.el.classList.add(this.classNames.visible)),this.el.setAttribute("data-simplebar","init")},t.initListeners=function(){var e=this,t=Cd(this.el);this.options.autoHide&&this.el.addEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach((function(t){e.el.addEventListener(t,e.onPointerEvent,!0)})),["touchstart","touchend","touchmove"].forEach((function(t){e.el.addEventListener(t,e.onPointerEvent,{capture:!0,passive:!0})})),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl.addEventListener("scroll",this.onScroll),t.addEventListener("resize",this.onWindowResize);var n=!1,r=t.ResizeObserver||_d.a;this.resizeObserver=new r((function(){n&&e.recalculate()})),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),t.requestAnimationFrame((function(){n=!0})),this.mutationObserver=new t.MutationObserver(this.recalculate),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})},t.recalculate=function(){var e=Cd(this.el);this.elStyles=e.getComputedStyle(this.el),this.isRtl="rtl"===this.elStyles.direction;var t=this.heightAutoObserverEl.offsetHeight<=1,n=this.heightAutoObserverEl.offsetWidth<=1,r=this.contentEl.offsetWidth,i=this.contentWrapperEl.offsetWidth,o=this.elStyles.overflowX,a=this.elStyles.overflowY;this.contentEl.style.padding=this.elStyles.paddingTop+" "+this.elStyles.paddingRight+" "+this.elStyles.paddingBottom+" "+this.elStyles.paddingLeft,this.wrapperEl.style.margin="-"+this.elStyles.paddingTop+" -"+this.elStyles.paddingRight+" -"+this.elStyles.paddingBottom+" -"+this.elStyles.paddingLeft;var s=this.contentEl.scrollHeight,u=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=t?"auto":"100%",this.placeholderEl.style.width=n?r+"px":"auto",this.placeholderEl.style.height=s+"px";var l=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=u>r,this.axis.y.isOverflowing=s>l,this.axis.x.isOverflowing="hidden"!==o&&this.axis.x.isOverflowing,this.axis.y.isOverflowing="hidden"!==a&&this.axis.y.isOverflowing,this.axis.x.forceVisible="x"===this.options.forceVisible||!0===this.options.forceVisible,this.axis.y.forceVisible="y"===this.options.forceVisible||!0===this.options.forceVisible,this.hideNativeScrollbar();var c=this.axis.x.isOverflowing?this.scrollbarWidth:0,f=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&u>i-f,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&s>l-c,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el.style.width=this.axis.x.scrollbar.size+"px",this.axis.y.scrollbar.el.style.height=this.axis.y.scrollbar.size+"px",this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")},t.getScrollbarSize=function(e){if(void 0===e&&(e="y"),!this.axis[e].isOverflowing)return 0;var t,n=this.contentEl[this.axis[e].scrollSizeAttr],r=this.axis[e].track.el[this.axis[e].offsetSizeAttr],i=r/n;return t=Math.max(~~(i*r),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(t=Math.min(t,this.options.scrollbarMaxSize)),t},t.positionScrollbar=function(t){if(void 0===t&&(t="y"),this.axis[t].isOverflowing){var n=this.contentWrapperEl[this.axis[t].scrollSizeAttr],r=this.axis[t].track.el[this.axis[t].offsetSizeAttr],i=parseInt(this.elStyles[this.axis[t].sizeAttr],10),o=this.axis[t].scrollbar,a=this.contentWrapperEl[this.axis[t].scrollOffsetAttr],s=(a="x"===t&&this.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-a:a)/(n-i),u=~~((r-o.size)*s);u="x"===t&&this.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?u+(r-o.size):u,o.el.style.transform="x"===t?"translate3d("+u+"px, 0, 0)":"translate3d(0, "+u+"px, 0)"}},t.toggleTrackVisibility=function(e){void 0===e&&(e="y");var t=this.axis[e].track.el,n=this.axis[e].scrollbar.el;this.axis[e].isOverflowing||this.axis[e].forceVisible?(t.style.visibility="visible",this.contentWrapperEl.style[this.axis[e].overflowAttr]="scroll"):(t.style.visibility="hidden",this.contentWrapperEl.style[this.axis[e].overflowAttr]="hidden"),this.axis[e].isOverflowing?n.style.display="block":n.style.display="none"},t.hideNativeScrollbar=function(){this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-"+this.scrollbarWidth+"px":0,this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-"+this.scrollbarWidth+"px":0},t.onMouseMoveForAxis=function(e){void 0===e&&(e="y"),this.axis[e].track.rect=this.axis[e].track.el.getBoundingClientRect(),this.axis[e].scrollbar.rect=this.axis[e].scrollbar.el.getBoundingClientRect(),this.isWithinBounds(this.axis[e].scrollbar.rect)?this.axis[e].scrollbar.el.classList.add(this.classNames.hover):this.axis[e].scrollbar.el.classList.remove(this.classNames.hover),this.isWithinBounds(this.axis[e].track.rect)?(this.showScrollbar(e),this.axis[e].track.el.classList.add(this.classNames.hover)):this.axis[e].track.el.classList.remove(this.classNames.hover)},t.onMouseLeaveForAxis=function(e){void 0===e&&(e="y"),this.axis[e].track.el.classList.remove(this.classNames.hover),this.axis[e].scrollbar.el.classList.remove(this.classNames.hover)},t.showScrollbar=function(e){void 0===e&&(e="y");var t=this.axis[e].scrollbar.el;this.axis[e].isVisible||(t.classList.add(this.classNames.visible),this.axis[e].isVisible=!0),this.options.autoHide&&this.hideScrollbars()},t.onDragStart=function(e,t){void 0===t&&(t="y");var n=kd(this.el),r=Cd(this.el),i=this.axis[t].scrollbar,o="y"===t?e.pageY:e.pageX;this.axis[t].dragOffset=o-i.rect[this.axis[t].offsetAttr],this.draggedAxis=t,this.el.classList.add(this.classNames.dragging),n.addEventListener("mousemove",this.drag,!0),n.addEventListener("mouseup",this.onEndDrag,!0),null===this.removePreventClickId?(n.addEventListener("click",this.preventClick,!0),n.addEventListener("dblclick",this.preventClick,!0)):(r.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},t.onTrackClick=function(e,t){var n=this;if(void 0===t&&(t="y"),this.options.clickOnTrack){var r=Cd(this.el);this.axis[t].scrollbar.rect=this.axis[t].scrollbar.el.getBoundingClientRect();var i=this.axis[t].scrollbar.rect[this.axis[t].offsetAttr],o=parseInt(this.elStyles[this.axis[t].sizeAttr],10),a=this.contentWrapperEl[this.axis[t].scrollOffsetAttr],s=("y"===t?this.mouseY-i:this.mouseX-i)<0?-1:1,u=-1===s?a-o:a+o;!function e(){var i,o;-1===s?a>u&&(a-=n.options.clickOnTrackSpeed,n.contentWrapperEl.scrollTo(((i={})[n.axis[t].offsetAttr]=a,i)),r.requestAnimationFrame(e)):a<u&&(a+=n.options.clickOnTrackSpeed,n.contentWrapperEl.scrollTo(((o={})[n.axis[t].offsetAttr]=a,o)),r.requestAnimationFrame(e))}()}},t.getContentElement=function(){return this.contentEl},t.getScrollElement=function(){return this.contentWrapperEl},t.getScrollbarWidth=function(){try{return"none"===getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:Sd()}catch(e){return Sd()}},t.removeListeners=function(){var e=this,t=Cd(this.el);this.options.autoHide&&this.el.removeEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach((function(t){e.el.removeEventListener(t,e.onPointerEvent,!0)})),["touchstart","touchend","touchmove"].forEach((function(t){e.el.removeEventListener(t,e.onPointerEvent,{capture:!0,passive:!0})})),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),t.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.recalculate.cancel(),this.onMouseMove.cancel(),this.hideScrollbars.cancel(),this.onWindowResize.cancel()},t.unMount=function(){this.removeListeners(),e.instances.delete(this.el)},t.isWithinBounds=function(e){return this.mouseX>=e.left&&this.mouseX<=e.left+e.width&&this.mouseY>=e.top&&this.mouseY<=e.top+e.height},t.findChild=function(e,t){var n=e.matches||e.webkitMatchesSelector||e.mozMatchesSelector||e.msMatchesSelector;return Array.prototype.filter.call(e.children,(function(e){return n.call(e,t)}))[0]},e}();xd.defaultOptions={autoHide:!0,forceVisible:!1,clickOnTrack:!0,clickOnTrackSpeed:40,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging"},scrollbarMinSize:25,scrollbarMaxSize:0,timeout:1e3},xd.instances=new WeakMap,xd.initDOMLoadedElements=function(){document.removeEventListener("DOMContentLoaded",this.initDOMLoadedElements),window.removeEventListener("load",this.initDOMLoadedElements),Array.prototype.forEach.call(document.querySelectorAll("[data-simplebar]"),(function(e){"init"===e.getAttribute("data-simplebar")||xd.instances.has(e)||new xd(e,Ed(e.attributes))}))},xd.removeObserver=function(){this.globalObserver.disconnect()},xd.initHtmlApi=function(){this.initDOMLoadedElements=this.initDOMLoadedElements.bind(this),"undefined"!=typeof MutationObserver&&(this.globalObserver=new MutationObserver(xd.handleMutations),this.globalObserver.observe(document,{childList:!0,subtree:!0})),"complete"===document.readyState||"loading"!==document.readyState&&!document.documentElement.doScroll?window.setTimeout(this.initDOMLoadedElements):(document.addEventListener("DOMContentLoaded",this.initDOMLoadedElements),window.addEventListener("load",this.initDOMLoadedElements))},xd.handleMutations=function(e){e.forEach((function(e){Array.prototype.forEach.call(e.addedNodes,(function(e){1===e.nodeType&&(e.hasAttribute("data-simplebar")?!xd.instances.has(e)&&new xd(e,Ed(e.attributes)):Array.prototype.forEach.call(e.querySelectorAll("[data-simplebar]"),(function(e){"init"===e.getAttribute("data-simplebar")||xd.instances.has(e)||new xd(e,Ed(e.attributes))})))})),Array.prototype.forEach.call(e.removedNodes,(function(e){1===e.nodeType&&(e.hasAttribute('[data-simplebar="init"]')?xd.instances.has(e)&&xd.instances.get(e).unMount():Array.prototype.forEach.call(e.querySelectorAll('[data-simplebar="init"]'),(function(e){xd.instances.has(e)&&xd.instances.get(e).unMount()})))}))}))},xd.getOptions=Ed,dd.a&&xd.initHtmlApi();var Od=xd,Pd={initMenuScrollbar:function(e){Pd.unMountScrollbar(e);var t=Pd.getMenuEl(e);t&&(e.simpleBar_=new Od(t,{autoHide:!1}),e.one("dispose",(function(){return Pd.unMountScrollbar(e)})))},unMountScrollbar:function(e){e.simpleBar_&&e.simpleBar_.unMount()},getMenuEl:function(e){return e.el().querySelector(".vjs-menu-content")}};function Rd(e,t,n,r){e.kind===t&&(n&&e.label!==n||(e.loaded_?r(e):e.one("loadeddata",(function(){r(e)}))))}var Ad=function(e,t,n,r){var i=function(e){Rd(e.track,t,n,r)},o=e.textTracks(),a=function(e,t,n){if(e.length)for(var r=e.length-1;r>=0;r--){var i=e[r];if(i.kind===t){if(n&&i.label!==n)continue;return i}}}(o,t,n);a?Rd(a,t,n,r):(o.addEventListener("addtrack",i),e.on("dispose",(function(){o.removeEventListener("addtrack",i)})))},Id=function(e){if(!e)return null;for(var t=e.textTracks(),n=0;n<t.length;n++){var r=t[n];if("showing"===r.mode)return r}return null};function Ld(e){return(Ld="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function jd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dd(e,t){return(Dd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Nd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ud(e);if(t){var i=Ud(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Md(this,n)}}function Md(e,t){return!t||"object"!==Ld(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Ud(e){return(Ud=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Bd=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Dd(e,t)}(o,e);var t,n,r,i=Nd(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"update",value:function(e,t){var n=this;if(null==e?void 0:e.length){var r=[],i=0;e.forEach((function(e){var o=n.options_.label.substr(i,e);o&&r.push(o),r.push('<span class="cv-highlight">'),r.push(n.options_.label.substr(e,t)),r.push("</span>"),i=e+t})),r.push(this.options_.label.substring(i,this.options_.label.length)),this.el().innerHTML='<span class="vjs-menu-item-text">'.concat(r.join(""),"</span>")}else this.el().innerHTML='<span class="vjs-menu-item-text">'.concat(this.options_.label,"</span>")}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.player_.currentTime(this.options_.cue.startTime)}}])&&jd(t.prototype,n),r&&jd(t,r),o}(Fu.getComponent("MenuItem"));function Fd(e){return(Fd="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Vd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Hd(e,t,n){return(Hd="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Gd(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function zd(e,t){return(zd=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function qd(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Gd(e);if(t){var i=Gd(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Wd(this,n)}}function Wd(e,t){return!t||"object"!==Fd(t)&&"function"!=typeof t?$d(e):t}function $d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Gd(e){return(Gd=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Yd=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zd(e,t)}(o,e);var t,n,r,i=qd(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).onChange=function(e,t,n){var r,i=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:window,a=function(){o.clearTimeout(r),r=null},s=function(){for(var a=arguments.length,s=new Array(a),u=0;u<a;u++)s[u]=arguments[u];var l=function(){r=null,l=null,n||e.apply(this,s)};!r&&n&&e.apply(i,s),o.clearTimeout(r),r=o.setTimeout(l,t)};return s.cancel=a,s}(n.onChange,100,!1,$d(n)),n.bindEventListeners(),n}return t=o,(n=[{key:"createEl",value:function(){return Hd(Gd(o.prototype),"createEl",this).call(this,"li",{innerHTML:'\n <div class="cv-subtitle-search-input">\n <span class="cv-search-icon">\n <svg viewBox="0 0 24 24">\n <path d="M15.803 14.306l3.917 3.954a1 1 0 0 1-.007 1.417l-.018.018-.018.018a.997.997 0 0 1-1.41 0l-3.918-3.953-.3.214c-1.14.713-2.323 1.07-3.549 1.07-1.796 0-3.328-.642-4.597-1.925C4.634 13.836 4 12.296 4 10.5c0-1.796.634-3.328 1.903-4.597C7.172 4.634 8.704 4 10.5 4c1.796 0 3.329.634 4.597 1.903 1.27 1.269 1.904 2.801 1.904 4.597a6.447 6.447 0 0 1-1.027 3.507l-.17.3zM10.5 5.368c-1.425 0-2.637.5-3.635 1.497-.998.998-1.497 2.21-1.497 3.635 0 1.426.5 2.637 1.497 3.635.998.998 2.21 1.497 3.635 1.497 1.426 0 2.637-.499 3.635-1.497 1.027-1.026 1.54-2.238 1.54-3.635 0-1.397-.513-2.608-1.54-3.635-.998-.998-2.21-1.497-3.635-1.497z"/>\n </svg>\n </span><input placeholder="Search" type="text" autocomplete="off" spellcheck="false" aria-label="Search" />\n </div>\n '})}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.$("input").focus()}},{key:"handleKeyDown",value:function(){}},{key:"bindEventListeners",value:function(){var e=this,t=this.$("input");this.onChange=this.onChange.bind(this),t.addEventListener("keyup",this.onChange),t.addEventListener("blur",(function(t){e.options_.menuButton.menu.handleBlur(t)}))}},{key:"onChange",value:function(e){var t=e.target;this.options_.menuButton.search(t.value)}}])&&Vd(t.prototype,n),r&&Vd(t,r),o}(Fu.getComponent("MenuItem"));n(393);function Kd(e){return(Kd="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Xd(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qd(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Jd(e,t,n){return t&&Qd(e.prototype,t),n&&Qd(e,n),e}function Zd(e,t,n){return(Zd="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=op(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ep(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tp(e,t)}function tp(e,t){return(tp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function np(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=op(e);if(t){var i=op(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return rp(this,n)}}function rp(e,t){return!t||"object"!==Kd(t)&&"function"!=typeof t?ip(e):t}function ip(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function op(e){return(op=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ap=Fu.getComponent("MenuItem"),sp=Fu.getComponent("MenuButton"),up=function(e){ep(n,e);var t=np(n);function n(){return Xd(this,n),t.apply(this,arguments)}return Jd(n,[{key:"createEl",value:function(e,t,r){return Zd(op(n.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:"vjs-menu-item cv-no-results"}),r)}}]),n}(ap),lp=function(e){ep(n,e);var t=np(n);function n(e,r){var i;return Xd(this,n),(i=t.call(this,e,r)).alwaysCollapsed=!0,i.isCollapsed=!1,i.isCollabsible=!0,i.update=i.update.bind(ip(i)),i.player_.textTracks().addEventListener("selectedlanguagechange",i.update),i}return Jd(n,[{key:"createItems",value:function(){var e,t=Id(this.player_);if(null===(e=null==t?void 0:t.cues)||void 0===e?void 0:e.length){for(var n=[new Yd(this.player_,{menuButton:this})],r=0;r<t.cues.length;r++){var i=t.cues[r];n.push(new Bd(this.player_,{cue:i,label:i.text,selected:!1,multiSelectable:!1}))}var o=new up(this.player_,{label:"No matching results",selected:!1,selectable:!1,multiSelectable:!1});return o.hide(),n.push(o),n}}},{key:"search",value:function(e){var t;e=e.trim();var n=Id(this.player_);if(null===(t=null==n?void 0:n.cues)||void 0===t?void 0:t.length){var r=this.findMatches(e,n);this.toggleItemVisibility(e,r),this.toggleNoResults(e,r)}}},{key:"findMatches",value:function(e,t){var n={};if(!e)return n;for(var r=new RegExp(e,"gi"),i=0;i<t.cues.length;i++){for(var o=t.cues[i].text,a=[],s=void 0;s=r.exec(o);)a.push(s.index);a.length&&(n[i]=a)}return n}},{key:"toggleItemVisibility",value:function(e,t){this.menu.children_.slice(1,this.menu.children_.length-1).forEach((function(n,r){!e||t[r]?n.show():n.hide(),n.update(t[r],e.length)}))}},{key:"toggleNoResults",value:function(e,t){var n=this.menu.children_[this.menu.children_.length-1];!e||Object.keys(t).length?n.hide():n.show()}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-big cv-subtitle-search-button ".concat(Zd(op(n.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"update",value:function(){Zd(op(n.prototype),"update",this).call(this),Pd.initMenuScrollbar(this),this.player_.trigger("resizemenus")}},{key:"getCollabsibleName",value:function(){return"Subtitle Size"}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!1}},{key:"showCollapsibleMenu",value:function(){sp.prototype.handleClick.apply(this)}}]),n}(sp);Fu.registerComponent("subtitleSearchButton",lp);n(394),n(395),n(396);function cp(e){return(cp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function fp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hp(e,t,n){return(hp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=gp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function dp(e,t){return(dp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function pp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=gp(e);if(t){var i=gp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yp(this,n)}}function yp(e,t){return!t||"object"!==cp(t)&&"function"!=typeof t?mp(e):t}function mp(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gp(e){return(gp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var vp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dp(e,t)}(o,e);var t,n,r,i=pp(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addChild("cogButton",{items:n.children_},n.children_.length-1),n.update=n.update.bind(mp(n)),n.player_.on("cv-updatecog",n.update),n.player_.on("playerresize",n.update),n.player_.on("dispose",(function(){n.player_.off("cv-updatecog",n.update),n.player_.off("playerresize",n.update)})),n}return t=o,(n=[{key:"togglehidden",value:function(e){for(var t=0;t<this.children_.length;t++){var n=this.children_[t];n.isCollabsible&&(n.alwaysCollapsed||e?(n.isCollapsed=!0,n.addClass("cv-collapsed")):(n.isCollapsed=!1,n.removeClass("cv-collapsed")))}this.getChild("cogButton").update()}},{key:"update",value:function(){var e=this.player_.el().getBoundingClientRect();0!==e.width&&this.togglehidden(e.width<600)}},{key:"buildCSSClass",value:function(){return"cv-collapsorator ".concat(hp(gp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return hp(gp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}}])&&fp(t.prototype,n),r&&fp(t,r),o}(Fu.getComponent("Component"));vp.prototype.options_={children:["playToggle","volumePanel","customControlSpacer","playbackRateMenuButton","chaptersButton","qualityButton","subsCapsButton","whiteboardModeButton","subtitleSizeButton","subtitleSearchButton","fullscreenToggle"]},Fu.registerComponent("collapserator",vp);n(397);function bp(e){return(bp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Tp(e,t,n){return(Tp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=kp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sp(e,t){return(Sp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ep(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=kp(e);if(t){var i=kp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Cp(this,n)}}function Cp(e,t){return!t||"object"!==bp(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function kp(e){return(kp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sp(e,t)}(o,e);var t,n,r,i=Ep(o);function o(){return _p(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-items ".concat(Tp(kp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Tp(kp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(){this.children_.forEach((function(e){e.update()}))}}])&&wp(t.prototype,n),r&&wp(t,r),o}(Fu.getComponent("Component"));function Op(e){return(Op="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Pp(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ap(e,t,n){return(Ap="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Dp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ip(e,t){return(Ip=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Lp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Dp(e);if(t){var i=Dp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jp(this,n)}}function jp(e,t){return!t||"object"!==Op(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Dp(e){return(Dp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Np=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ip(e,t)}(o,e);var t,n,r,i=Lp(o);function o(){return Pp(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-load-progress ".concat(Ap(Dp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Ap(Dp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(e){this.el_.style.width=100*e+"%"}}])&&Rp(t.prototype,n),r&&Rp(t,r),o}(Fu.getComponent("Component"));function Mp(e){return(Mp="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Up(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Fp(e,t,n){return(Fp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=qp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Vp(e,t){return(Vp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Hp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=qp(e);if(t){var i=qp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return zp(this,n)}}function zp(e,t){return!t||"object"!==Mp(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function qp(e){return(qp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Wp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Vp(e,t)}(o,e);var t,n,r,i=Hp(o);function o(){return Up(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-play-progress ".concat(Fp(qp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Fp(qp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"update",value:function(e){e>0&&e<1?this.addClass("cv-current"):this.removeClass("cv-current"),this.el_.style.width=100*e+"%"}}])&&Bp(t.prototype,n),r&&Bp(t,r),o}(Fu.getComponent("Component"));function $p(e){return($p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Gp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Yp(e,t,n){return(Yp="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Jp(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Kp(e,t){return(Kp=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xp(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Jp(e);if(t){var i=Jp(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qp(this,n)}}function Qp(e,t){return!t||"object"!==$p(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jp(e){return(Jp=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Zp=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Kp(e,t)}(o,e);var t,n,r,i=Xp(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).playProgress=new Wp(n.player_),n.addChild(n.playProgress),n.loadProgress=new Np(n.player_),n.addChild(n.loadProgress),n.update(),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapter-bar-item ".concat(Yp(Jp(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Yp(Jp(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"getCurrentTime",value:function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()}},{key:"update",value:function(){var e=this.player_.duration(),t=this.options_.endTime-this.options_.startTime;if(e!==this.duration_){var n=t/e;this.el_.style.width=100*n+"%";var r=this.options_.startTime/e;this.el_.style.left=100*r+"%",this.duration_=e}var i=this.getCurrentTime();i<this.options_.startTime?this.playProgress.update(0):i>this.options_.endTime?this.playProgress.update(1):this.playProgress.update((i-this.options_.startTime)/t);var o=this.player_.bufferedEnd();o<this.options_.startTime?this.loadProgress.update(0):o>this.options_.endTime?this.loadProgress.update(1):this.loadProgress.update((o-this.options_.startTime)/t)}}])&&Gp(t.prototype,n),r&&Gp(t,r),o}(Fu.getComponent("Component"));function ey(e){return(ey="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ty(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ny(e,t,n){return(ny="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=sy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function ry(e,t){return(ry=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function iy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sy(e);if(t){var i=sy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return oy(this,n)}}function oy(e,t){return!t||"object"!==ey(t)&&"function"!=typeof t?ay(e):t}function ay(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sy(e){return(sy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var uy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ry(e,t)}(o,e);var t,n,r,i=iy(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).onDurationChange=n.onDurationChange.bind(ay(n)),n.createChapterItems=n.createChapterItems.bind(ay(n)),Ad(n.player_,"chapters",null,n.createChapterItems),n.player_.on("durationchange",n.onDurationChange),n.player_.on("dispose",(function(){n.player_.off("durationchange",n.onDurationChange)})),n}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("div",{className:"vjs-progress-holder cv-chapter-seek-bar"},{"aria-label":this.localize("Progress Bar")})}},{key:"onDurationChange",value:function(){this.createChapterItems(),this.update()}},{key:"update",value:function(){var e=ny(sy(o.prototype),"update",this).call(this);return this.chapterBarItems&&this.chapterBarItems.update(),e}},{key:"createChapterItems",value:function(e){e&&(this.track_=e);var t=new xp(this.player_);if(this.track_&&!this.options_.ignoreChapters)for(var n=0;n<this.track_.cues.length;n++){var r=this.track_.cues[n],i=r.startTime,o=r.endTime,a=this.player_.duration();a&&(n===this.track_.cues.length-1&&r.endTime<this.player_.duration()&&(o=this.player_.duration()),o>a&&(o=a));var s=new Zp(this.player_,{startTime:i,endTime:o});if(t.addChild(s),a&&o===a)break}else t.addChild(new Zp(this.player_,{startTime:0,endTime:this.player_.duration()}));this.chapterBarItems&&this.removeChild(this.chapterBarItems),this.chapterBarItems=t,this.addChild(this.chapterBarItems)}}])&&ty(t.prototype,n),r&&ty(t,r),o}(Fu.getComponent("SeekBar"));uy.prototype.options_={children:["playProgressBar"],barName:"playProgressBar"},Fu.browser.IS_IOS||Fu.browser.IS_ANDROID||uy.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Fu.registerComponent("ChapterSeekBar",uy);n(398);function ly(e){return(ly="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function cy(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hy(e,t,n){return(hy="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=my(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function dy(e,t){return(dy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function py(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=my(e);if(t){var i=my(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yy(this,n)}}function yy(e,t){return!t||"object"!==ly(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function my(e){return(my=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var gy=Fu.getComponent("ProgressControl"),vy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dy(e,t)}(o,e);var t,n,r,i=py(o);function o(){var e;return cy(this,o),(e=i.apply(this,arguments)).seekBarName_="seekBar",e}return t=o,(n=[{key:"setSeekBarName",value:function(e){this.seekBarName_=e}},{key:"getChild",value:function(e){return(null==e?void 0:e.toLowerCase())==="seekBar".toLowerCase()&&(e=this.seekBarName_),hy(my(o.prototype),"getChild",this).call(this,e)}}])&&fy(t.prototype,n),r&&fy(t,r),o}(gy);function by(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e;e=e<0?0:e;var n=Math.floor(e%60),r=Math.floor(e/60%60),i=Math.floor(e/3600),o=Math.floor(t/60%60),a=Math.floor(t/3600);return(isNaN(e)||e===1/0)&&(i=r=n="-"),(i=i>0||a>0?i+":":"")+(r=((i||o>=10)&&r<10?"0"+r:r)+":")+(n=n<10?"0"+n:n)}vy.prototype.options_={children:[]},Fu.registerComponent("ProgressControl",vy);n(399);function _y(e){return(_y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function wy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ty(e,t,n){return(Ty="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ky(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Sy(e,t){return(Sy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Ey(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ky(e);if(t){var i=ky(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Cy(this,n)}}function Cy(e,t){return!t||"object"!==_y(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ky(e){return(ky=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var xy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Sy(e,t)}(o,e);var t,n,r,i=Ey(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),Ad(n.player_,"chapters",!1,(function(e){n.track_=e})),n}return t=o,(n=[{key:"createEl",value:function(){var e=Ty(ky(o.prototype),"createEl",this).call(this);return this.chapter_=Fu.dom.createEl("div"),e.appendChild(this.chapter_),this.time_=Fu.dom.createEl("div"),e.appendChild(this.time_),e}},{key:"updateTime",value:function(e){var t=this.player_.duration();if(Fu.dom.textContent(this.time_,by(e,t)),this.track_){for(var n=0;n<this.track_.cues.length;n++){var r=this.track_.cues[n];if(r.startTime<=e&&r.endTime>=e)return void Fu.dom.textContent(this.chapter_,r.text)}Fu.dom.textContent(this.chapter_,"")}}}])&&wy(t.prototype,n),r&&wy(t,r),o}(Fu.getComponent("TimeTooltip"));Fu.registerComponent("TimeTooltip",xy);n(400);function Oy(e){return(Oy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Py(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ry(e,t,n){return(Ry="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=jy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ay(e,t){return(Ay=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Iy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=jy(e);if(t){var i=jy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ly(this,n)}}function Ly(e,t){return!t||"object"!==Oy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function jy(e){return(jy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Dy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ay(e,t)}(o,e);var t,n,r,i=Iy(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"setTrack",value:function(e){this.track_=e}},{key:"createEl",value:function(){var e=Ry(jy(o.prototype),"createEl",this).call(this,"div",{className:"cv-thumbnail-display"});return this.img_=Fu.dom.createEl("img"),e.appendChild(this.img_),e}},{key:"enable",value:function(){this.addClass("cv-thumbnail-display-enabled")}},{key:"disable",value:function(){this.removeClass("cv-thumbnail-display-enabled")}},{key:"parseImageLink",value:function(e){var t=e.indexOf("#");if(-1===t)return{src:e,w:0,h:0,x:0,y:0};var n=e.substr(0,t),r=e.substr(t+1);if("xywh="!==r.substr(0,5))return{src:e,w:0,h:0,x:0,y:0};var i=this.getScale(),o=r.substr(5).split(",");return{src:n,w:parseInt(o[2])*i,h:parseInt(o[3])*i,x:parseInt(o[0])*i,y:parseInt(o[1])*i}}},{key:"getScale",value:function(){var e=this.options_.scaleFactor,t=this.player_.whiteboardModePlugin().side;return this.player_.isFullscreen()&&"bottom"!==t&&(e*=2),e}},{key:"update",value:function(e){var t,n;if(null===(n=null===(t=this.track_)||void 0===t?void 0:t.cues)||void 0===n?void 0:n.length){for(var r,i=e,o=0;o<this.track_.cues.length;){var a=this.track_.cues[o];if(a.startTime<=i&&a.endTime>=i){r=this.parseImageLink(a.text);break}o++}if(null==r?void 0:r.src){this.enable();var s=r,u=s.src,l=s.w,c=s.h,f=s.x,h=s.y,d=this.getScale();this.img_.src=u,this.img_.style.left=-f+"px",this.img_.style.top=-h+"px",this.img_.style.transformOrigin="0 0",this.img_.style.transform="scale(".concat(d,")"),this.el_.style.width=l+"px",this.el_.style.height=c+"px"}else this.disable()}}}])&&Py(t.prototype,n),r&&Py(t,r),o}(Fu.getComponent("Component"));Dy.prototype.options_={scaleFactor:1},Fu.registerComponent("ThumbnailDisplay",Dy);n(401);function Ny(e){return(Ny="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function My(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Uy(e,t){return(Uy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function By(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Hy(e);if(t){var i=Hy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fy(this,n)}}function Fy(e,t){return!t||"object"!==Ny(t)&&"function"!=typeof t?Vy(e):t}function Vy(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Hy(e){return(Hy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var zy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Uy(e,t)}(o,e);var t,n,r,i=By(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),Ad(n.player_,"metadata","thumbnails",(function(e){n.getChild("ThumbnailDisplay").setTrack(e)})),n.update=n.update.bind(Vy(n)),n.player_.on("durationchange",n.update),n.player_.one("dispose",(function(){n.player_.off("durationchange",n.update)})),n}return t=o,(n=[{key:"update",value:function(e,t){var n=this;this.requestAnimationFrame((function(){var r=t*n.player_.duration();n.getChild("ThumbnailDisplay").update(r),n.getChild("TimeTooltip").updateTime(r);var i=n.el_.getBoundingClientRect();n.el_.style.marginLeft=-i.width/2+"px";var o=e.width*t;o<i.width/2?n.el_.style.left=i.width/2+"px":o>e.width-i.width/2?n.el_.style.left=e.width-i.width/2+"px":n.el_.style.left=e.width*t+"px"}))}}])&&My(t.prototype,n),r&&My(t,r),o}(Fu.getComponent("MouseTimeDisplay"));zy.prototype.options_={children:["ThumbnailDisplay","TimeTooltip"]},Fu.registerComponent("MouseTimeDisplay",zy);n(402);function qy(e){return(qy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Wy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $y(e,t,n){return($y="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Xy(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Gy(e,t){return(Gy=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Yy(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Xy(e);if(t){var i=Xy(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ky(this,n)}}function Ky(e,t){return!t||"object"!==qy(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Xy(e){return(Xy=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Qy=Fu.getComponent("ChaptersTrackMenuItem"),Jy=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Gy(e,t)}(o,e);var t,n,r,i=Yy(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).nonIconControl=!1,n.thumbnailDisplay=new Dy(n.player_,{scaleFactor:.5}),n.el().insertBefore(n.thumbnailDisplay.el(),n.el().firstChild),Ad(n.player_,"metadata","thumbnails",(function(e){n.addClass("cv-has-thumbnails"),n.thumbnailDisplay.setTrack(e),n.thumbnailDisplay.update(n.options_.cue.startTime)})),n}return t=o,(n=[{key:"update",value:function(){this.player_&&Qy.prototype.update.call(this)}},{key:"buildCSSClass",value:function(){return"vjs-menu-item cv-chapter-menu-item"}},{key:"createEl",value:function(e,t,n){return this.nonIconControl=!0,$y(Xy(o.prototype),"createEl",this).call(this,"li",Object.assign({className:this.buildCSSClass(),innerHTML:this.getInnerHTML(),tabIndex:-1},t),n)}},{key:"getInnerHTML",value:function(){var e=this.player_.duration();return'<span class="vjs-menu-item-text cv-chapter-menu-item-text">'+"<p>".concat(this.localize(this.options_.label),"</p>")+"<p>(".concat(by(this.options_.cue.startTime,e),")</p>")+"</span>"}}])&&Wy(t.prototype,n),r&&Wy(t,r),o}(Qy);n(403);function Zy(e){return(Zy="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function em(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function tm(e,t,n){return(tm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=am(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function nm(e,t){return(nm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=am(e);if(t){var i=am(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return im(this,n)}}function im(e,t){return!t||"object"!==Zy(t)&&"function"!=typeof t?om(e):t}function om(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function am(e){return(am=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var sm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nm(e,t)}(o,e);var t,n,r,i=rm(o);function o(e,t,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(r=i.call(this,e,t,n)).alwaysCollapsed=!1,r.isCollapsed=!1,r.isCollabsible=!0,r.update=r.update.bind(om(r)),r.player_.on("cv-whiteboard-change",r.update),r.player_.on("fullscreenchange",r.update),r.player_.on("dispose",(function(){r.player_.off("cv-whiteboard-change",r.update),r.player_.off("fullscreenchange",r.update)})),r}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-chapters-button ".concat(tm(am(o.prototype),"buildCSSClass",this).call(this))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-big ".concat(tm(am(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createItems",value:function(){var e=[];if(!this.track_)return e;var t=this.track_.cues;if(!t)return e;for(var n=0,r=t.length;n<r;n++){var i=t[n],o=new Jy(this.player_,{track:this.track_,cue:i});e.push(o)}return e}},{key:"setTrack",value:function(e){var t=this;tm(am(o.prototype),"setTrack",this).call(this,e),this.track_&&"chapters"===this.track_.kind&&e.one("loadeddata",(function(){t.update()}))}},{key:"update",value:function(e){tm(am(o.prototype),"update",this).call(this,e),Pd.initMenuScrollbar(this)}},{key:"getCollabsibleName",value:function(){return"Chapters"}},{key:"getCollabsibleValue",value:function(){var e=this.track_.activeCues[0];return(null==e?void 0:e.text)||""}},{key:"showInCollabsibleMenu",value:function(){if(!this.track_)return!1;var e=this.track_.cues;return!(!e||!e.length)}},{key:"showCollapsibleMenu",value:function(){this.handleClick(null)}}])&&em(t.prototype,n),r&&em(t,r),o}(Fu.getComponent("ChaptersButton"));function um(e){return(um="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lm(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fm(e,t){return(fm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function hm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=pm(e);if(t){var i=pm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dm(this,n)}}function dm(e,t){return!t||"object"!==um(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function pm(e){return(pm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("ChaptersButton",sm);var ym=Fu.getComponent("SubsCapsMenuItem"),mm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&fm(e,t)}(o,e);var t,n,r,i=hm(o);function o(){return lm(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"handleClick",value:function(e){ym.prototype.handleClick.call(this,e),this.player_.trigger("cv:languageselected")}}])&&cm(t.prototype,n),r&&cm(t,r),o}(ym);function gm(e){return(gm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function vm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bm(e,t){return(bm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Tm(e);if(t){var i=Tm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return wm(this,n)}}function wm(e,t){return!t||"object"!==gm(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Tm(e){return(Tm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Sm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&bm(e,t)}(o,e);var t,n,r,i=_m(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var n={};return n.track={player:e,kind:"subtitle",label:"Subtitle size",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="SubtitleSizeMenuItem",(t=i.call(this,e,n)).addClass("vjs-texttrack-settings"),t.controlText(", opens subtitle size settings"),t}return t=o,(n=[{key:"handleClick",value:function(){var e=this;this.requestAnimationFrame((function(){e.player_.getChild("collapserator").getChild("subtitleSizeButton").showCollapsibleMenu()}))}}])&&vm(t.prototype,n),r&&vm(t,r),o}(Fu.getComponent("TextTrackMenuItem"));n(404);function Em(e){return(Em="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function km(e,t){return(km=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function xm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Rm(e);if(t){var i=Rm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Om(this,n)}}function Om(e,t){return!t||"object"!==Em(t)&&"function"!=typeof t?Pm(e):t}function Pm(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Rm(e){return(Rm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Am=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&km(e,t)}(o,e);var t,n,r,i=xm(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var n={};n.track={player:e,kind:"subtitle",label:"Search subtitles",selectable:!1,default:!1,mode:"disabled"},n.selectable=!1,n.name="SubtitleSearchMenuItem",(t=i.call(this,e,n)).addClass("vjs-texttrack-settings"),t.controlText(", opens subtitle search"),t.toggleHidden=t.toggleHidden.bind(Pm(t));var r=t.player_.textTracks();return r.addEventListener("selectedlanguagechange",t.toggleHidden),t.player_.one("dispose",(function(){r.removeEventListener("selectedlanguagechange",t.toggleHidden)})),t.toggleHidden(),t}return t=o,(n=[{key:"toggleHidden",value:function(){var e;if(this.player_){var t=Id(this.player_);(null===(e=null==t?void 0:t.cues)||void 0===e?void 0:e.length)?this.show():this.hide()}}},{key:"handleClick",value:function(){var e=this;this.requestAnimationFrame((function(){e.player_.getChild("collapserator").getChild("subtitleSearchButton").showCollapsibleMenu()}))}}])&&Cm(t.prototype,n),r&&Cm(t,r),o}(Fu.getComponent("TextTrackMenuItem"));function Im(e){return(Im="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Lm(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dm(e,t,n){return(Dm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Bm(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Nm(e,t){return(Nm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mm(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Bm(e);if(t){var i=Bm(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Um(this,n)}}function Um(e,t){return!t||"object"!==Im(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Bm(e){return(Bm=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fm=Fu.getComponent("TextTrackButton"),Vm=Fu.getComponent("SubsCapsButton"),Hm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nm(e,t)}(o,e);var t,n,r,i=Mm(o);function o(){var e;return Lm(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Dm(Bm(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"update",value:function(){Dm(Bm(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"createItems",value:function(){var e=[new Am(this.player_),new Sm(this.player_)];return this.hideThreshold_++,Fm.prototype.createItems.call(this,e,mm)}},{key:"getCollabsibleName",value:function(){return"Subtitles"}},{key:"getCollabsibleValue",value:function(){for(var e=this.player_.textTracks(),t=0;t<e.length;t++){var n=e[t];if(this.kinds_.indexOf(n.kind)>-1&&"showing"===n.mode)return n.label}return"Off"}},{key:"showInCollabsibleMenu",value:function(){for(var e=this.player_.textTracks(),t=0;t<e.length;t++){var n=e[t];if(this.kinds_.indexOf(n.kind)>-1)return!0}return!1}},{key:"showCollapsibleMenu",value:function(){Vm.prototype.handleClick.apply(this)}}])&&jm(t.prototype,n),r&&jm(t,r),o}(Vm);function zm(e){return(zm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function qm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Wm(e,t){return(Wm=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function $m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Km(e);if(t){var i=Km(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Gm(this,n)}}function Gm(e,t){return!t||"object"!==zm(t)&&"function"!=typeof t?Ym(e):t}function Ym(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Km(e){return(Km=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("SubsCapsButton",Hm);var Xm=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Wm(e,t)}(o,e);var t,n,r,i=$m(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).qualityId=t.qualityId;var r=e.qualityLevels(),a=n.handleQualityChange.bind(Ym(n));return r.on("change",a),e.on("dispose",(function(){r.off("change",a)})),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"vjs-menu-item cv-quality-menu-item"}},{key:"handleClick",value:function(){for(var e=this.player_.qualityLevels(),t=0;t<e.length;t++){var n=e[t];n.enabled=n.id===this.qualityId}}},{key:"handleQualityChange",value:function(){if(this.player_){var e=this.player_.qualityLevels(),t=e[e.selectedIndex],n=t&&t.id===this.qualityId;n!==this.isSelected_&&this.selected(n)}}}])&&qm(t.prototype,n),r&&qm(t,r),o}(Fu.getComponent("MenuItem"));n(405);function Qm(e){return(Qm="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Jm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Zm(e,t,n){return(Zm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ig(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function eg(e,t){return(eg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function tg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ig(e);if(t){var i=ig(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ng(this,n)}}function ng(e,t){return!t||"object"!==Qm(t)&&"function"!=typeof t?rg(e):t}function rg(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ig(e){return(ig=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var og={240:"240p",360:"360p",480:"480p",720:"720p",1080:"1080p"},ag=Fu.getComponent("MenuButton"),sg=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&eg(e,t)}(o,e);var t,n,r,i=tg(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).alwaysCollapsed=!0,n.isCollapsed=!1,n.isCollabsible=!0;var r=n.player_.qualityLevels(),a=n.update.bind(rg(n));return r.on("addqualitylevel",a),r.on("removequalitylevel",a),e.on("dispose",(function(){r.removeEventListener("addqualitylevel",a),r.removeEventListener("removequalitylevel",a)})),n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-quality-button ".concat(Zm(ig(o.prototype),"buildCSSClass",this).call(this))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small vjs-quality-button ".concat(Zm(ig(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createItems",value:function(){for(var e=[],t=this.player_.qualityLevels(),n=0;n<t.length;n++){var r=t[n];if(r){var i=og[r.id];i&&e.push(new Xm(this.player_,{qualityId:r.id,label:i,selectable:!0,multiSelectable:!1}))}}return e}},{key:"update",value:function(){Zm(ig(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"getCollabsibleName",value:function(){return"Playback Quality"}},{key:"getCollabsibleValue",value:function(){var e=this.player_.qualityLevels(),t=e[e.selectedIndex];return t?og[t.id]:""}},{key:"showInCollabsibleMenu",value:function(){return!!this.player_.qualityLevels().length}},{key:"showCollapsibleMenu",value:function(){ag.prototype.handleClick.apply(this)}}])&&Jm(t.prototype,n),r&&Jm(t,r),o}(ag);Fu.registerComponent("QualityButton",sg);n(406);function ug(e){return(ug="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fg(e,t,n){return(fg="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=yg(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function hg(e,t){return(hg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function dg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=yg(e);if(t){var i=yg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pg(this,n)}}function pg(e,t){return!t||"object"!==ug(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function yg(e){return(yg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var mg=Fu.getComponent("Menu"),gg=Fu.getComponent("MenuButton"),vg=Fu.getComponent("PlaybackRateMenuItem"),bg=Fu.getComponent("PlaybackRateMenuButton"),_g=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&hg(e,t)}(o,e);var t,n,r,i=dg(o);function o(){var e;return lg(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!0,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"createEl",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=gg.prototype.createEl).apply.apply(e,[this].concat(n))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(fg(yg(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createMenu",value:function(){var e=new mg(this.player(),{menuButton:this}),t=this.playbackRates();if(t)for(var n=t.length-1;n>=0;n--)e.addItem(new vg(this.player(),{rate:t[n]+"x"}));return e}},{key:"handleClick",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=gg.prototype.handleClick).apply.apply(e,[this].concat(n))}},{key:"updateLabel",value:function(){var e;this.setupLabelEl();for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=bg.prototype.updateLabel).apply.apply(e,[this].concat(n))}},{key:"setupLabelEl",value:function(){if(!this.labelEl_){var e=this.$("button");e&&(this.labelEl_=Fu.dom.createEl("div",{className:"vjs-playback-rate-value",innerHTML:"1x"}),e.appendChild(this.labelEl_))}}},{key:"getCollabsibleName",value:function(){return"Playback Rate"}},{key:"getCollabsibleValue",value:function(){return this.player().playbackRate()+"x"}},{key:"showInCollabsibleMenu",value:function(){return!!this.playbackRates()}},{key:"showCollapsibleMenu",value:function(){this.handleClick(null)}}])&&cg(t.prototype,n),r&&cg(t,r),o}(bg);function wg(e){return(wg="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Tg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Sg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Eg(e,t){return(Eg=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Cg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=xg(e);if(t){var i=xg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return kg(this,n)}}function kg(e,t){return!t||"object"!==wg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function xg(e){return(xg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("PlaybackRateMenuButton",_g);var Og=Fu.getComponent("TextTrackSettings"),Pg={backgroundColor:"#000",backgroundOpacity:"1",color:"#FFF",edgeStyle:void 0,fontFamily:"proportionalSansSerif",fontPercent:1,textOpacity:"1",windowColor:"#000",windowOpacity:"0"},Rg={small:Pg,medium:Object.assign(Object.assign({},Pg),{fontPercent:1.5}),large:Object.assign(Object.assign({},Pg),{fontPercent:2})},Ag=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Eg(e,t)}(o,e);var t,n,r,i=Cg(o);function o(){return Tg(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setSizeSetting",value:function(e){this.size_=e,this.player_.getChild("textTrackDisplay").updateDisplay(),this.player_.getChild("collapserator").getChild("subtitleSizeButton").update(),this.player_.trigger("resizemenus"),this.player_.trigger("changesubtitlesize",this.size_)}},{key:"getSizeSetting",value:function(){return this.size_||"small"}},{key:"getValues",value:function(){return Rg[this.size_]?Rg[this.size_]:Pg}}])&&Sg(t.prototype,n),r&&Sg(t,r),o}(Og);Fu.registerComponent("TextTrackSettings",Ag);n(407);function Ig(e){return(Ig="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Lg(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Dg(e,t,n){return(Dg="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Bg(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Ng(e,t){return(Ng=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mg(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Bg(e);if(t){var i=Bg(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ug(this,n)}}function Ug(e,t){return!t||"object"!==Ig(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Bg(e){return(Bg=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fg=window.navigator&&window.navigator.userAgent||"",Vg=(/iPod/i.test(Fg),/Android/i.test(Fg),Fu.getComponent("Player")),Hg=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ng(e,t)}(o,e);var t,n,r,i=Mg(o);function o(){return Lg(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"lock",value:function(e){this.callback_=e}},{key:"unlock",value:function(){delete this.callback_}},{key:"currentTime",value:function(e,t){var n=this;if("number"!=typeof e||!this.callback_||t)return Dg(Bg(o.prototype),"currentTime",this).call(this,e);this.callback_((function(){n.unlock(),n.currentTime(e)}))}},{key:"play",value:function(){var e=this;if(!this.callback_)return Dg(Bg(o.prototype),"play",this).call(this);this.callback_((function(){e.unlock(),e.play()}))}},{key:"updateStyleEl_",value:function(){if(Vg.prototype.updateStyleEl_.call(this),this.options_.fluid){var e=this.el_.parentNode;if(e){var t=this.aspectRatio();void 0!==t&&"auto"!==t||(t=this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9");var n=t.split(":"),r=+n[1]/+n[0];e.style.maxWidth=65/r+"vh",e.style.margin="0 auto"}}}},{key:"listenForUserActivity_",value:function(){var e=this;Vg.prototype.listenForUserActivity_.call(this);var t=this.getChild("collapserator");t.on("mouseenter",(function(){e.player().cache_.inactivityTimeout=e.player().options_.inactivityTimeout,e.player().options_.inactivityTimeout=0})),t.on("mouseleave",(function(){e.player().options_.inactivityTimeout=e.player().cache_.inactivityTimeout}))}}])&&jg(t.prototype,n),r&&jg(t,r),o}(Vg);Fu.registerComponent("player",Hg);var zg;n(408),n(409),n(410),n(411),n(412);function qg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wg(e){e.paused()?e.play():e.pause()}function $g(e,t){e.currentTime(e.currentTime()+t)}function Gg(e,t){e.volume(e.volume()+t)}var Yg=(qg(zg={},"f",(function(e){document[e.fsApi_.fullscreenEnabled]&&(e.isFullscreen()?e.exitFullscreen():e.requestFullscreen())})),qg(zg,"m",(function(e){var t=e.volume(),n=e.lastVolume_();if(0===t){var r=n<.1?.1:n;e.volume(r),e.muted(!1)}else e.muted(!e.muted())})),qg(zg,"k",Wg),qg(zg,"space",Wg),qg(zg,"left",(function(e){return $g(e,-5)})),qg(zg,"right",(function(e){return $g(e,5)})),qg(zg,"j",(function(e){return $g(e,-10)})),qg(zg,"l",(function(e){return $g(e,10)})),qg(zg,"up",(function(e){return Gg(e,.05)})),qg(zg,"down",(function(e){return Gg(e,-.05)})),zg);function Kg(e){var t=v()(e);Yg[t]&&Yg[t](this,e)}function Xg(e){return(Xg="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Qg(e,t){return!t||"object"!==Xg(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jg(e){var t="function"==typeof Map?new Map:void 0;return(Jg=function(e){if(null===e||(n=e,-1===Function.toString.call(n).indexOf("[native code]")))return e;var n;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return Zg(e,arguments,nv(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),tv(r,e)})(e)}function Zg(e,t,n){return(Zg=ev()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&tv(i,n.prototype),i}).apply(null,arguments)}function ev(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function tv(e,t){return(tv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function nv(e){return(nv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var rv=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tv(e,t)}(i,e);var t,n,r=(t=i,n=ev(),function(){var e,r=nv(t);if(n){var i=nv(this).constructor;e=Reflect.construct(r,arguments,i)}else e=r.apply(this,arguments);return Qg(this,e)});function i(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(n=r.call(this,e)).url=t,n}return i}(Jg(Error));function iv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var ov,av=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},sv=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.tokens={gateway:null}}var t,n,r;return t=e,(n=[{key:"get",value:function(e,t){return av(this,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.t0=this,n.next=3,fetch(e,{method:"GET",mode:"cors",headers:this.getHeaders(t)});case 3:return n.t1=n.sent,n.next=6,n.t0.parseResponse.call(n.t0,n.t1);case 6:return n.abrupt("return",n.sent);case 7:case"end":return n.stop()}}),n,this)})))}},{key:"delete",value:function(e,t){return av(this,void 0,void 0,regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,fetch(e,{method:"DELETE",headers:this.getHeaders(t)});case 2:case"end":return n.stop()}}),n,this)})))}},{key:"post",value:function(e,t,n){return av(this,void 0,void 0,regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.t0=this,r.next=3,fetch(e,{method:"POST",headers:this.getHeaders(n),body:t,mode:"cors"});case 3:return r.t1=r.sent,r.next=6,r.t0.parseResponse.call(r.t0,r.t1);case 6:return r.abrupt("return",r.sent);case 7:case"end":return r.stop()}}),r,this)})))}},{key:"put",value:function(e,t,n){return av(this,void 0,void 0,regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.t0=this,r.next=3,fetch(e,{method:"PUT",headers:this.getHeaders(n),body:t,mode:"cors"});case 3:return r.t1=r.sent,r.next=6,r.t0.parseResponse.call(r.t0,r.t1);case 6:return r.abrupt("return",r.sent);case 7:case"end":return r.stop()}}),r,this)})))}},{key:"setToken",value:function(e,t){this.tokens[e]=t}},{key:"getHeaders",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={"Content-Type":"application/json"};return this.tokens[e.tokenName]&&(t.authorization="Bearer ".concat(this.tokens[e.tokenName])),t}},{key:"parseResponse",value:function(e){return av(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(404!==e.status){t.next=2;break}return t.abrupt("return",null);case 2:if(e.ok){t.next=4;break}throw new rv("Ajax error",e.url);case 4:return t.next=6,e.json();case 6:return n=t.sent,t.abrupt("return",n);case 8:case"end":return t.stop()}}),t)})))}}])&&iv(t.prototype,n),r&&iv(t,r),e}());function uv(e){return(uv="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function lv(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cv(e,t)}function cv(e,t){return(cv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fv(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dv(e);if(t){var i=dv(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return hv(this,n)}}function hv(e,t){return!t||"object"!==uv(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function dv(e){return(dv=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function pv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mv(e,t,n){return t&&yv(e.prototype,t),n&&yv(e,n),e}!function(e){e.LocalStorage="localStorage",e.SessionStorage="sessionStorage"}(ov||(ov={}));var gv=function(){function e(t){pv(this,e),this.cachePrefix="_cv:",this.expireTime=3600,this.hasSupport=this.hasBrowserSupport(),this.type=t.type,this.hasSupport&&(this.storage=window[this.type])}return mv(e,[{key:"get",value:function(e){if(this.hasSupport){var t=this.storage.getItem(e);try{return JSON.parse(t)}catch(e){return t}}}},{key:"set",value:function(e,t){if(this.hasSupport)try{return this.storage.removeItem(e),"string"!=typeof t?(this.storage.setItem(e,JSON.stringify(t)),!0):(this.storage.setItem(e,t),!0)}catch(e){return!1}}},{key:"remove",value:function(e){if(this.hasSupport)return this.storage.removeItem(e)}},{key:"length",value:function(){if(this.hasSupport)return this.storage.length}},{key:"clear",value:function(){if(this.hasSupport)return this.storage.clear()}},{key:"cacheSet",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.expireTime;this.cacheClean();var r={time:this.getCurrentTime()+1e3*n,data:null!=t&&t};return this.set("".concat(this.cachePrefix).concat(e),r)}},{key:"cacheGet",value:function(e){var t="".concat(this.cachePrefix).concat(e),n=this.get(t);return n?this.isExpired(n)?(this.remove(t),null):n.data:null}},{key:"cacheExists",value:function(e){var t="".concat(this.cachePrefix).concat(e),n=this.get(t);return!!n&&(!this.isExpired(n)||(this.remove(t),!1))}},{key:"cacheRemove",value:function(e){return this.remove("".concat(this.cachePrefix).concat(e))}},{key:"cacheFlush",value:function(){this.cacheClean()}},{key:"cacheClean",value:function(){if(this.hasSupport)for(var e=0;e<this.storage.length;e++){var t=this.storage.key(e);if(0===t.indexOf(this.cachePrefix)){var n=this.get(t);n&&n.time&&this.isExpired(n)&&this.remove(t)}}}},{key:"isExpired",value:function(e){return e.time<this.getCurrentTime()}},{key:"getCurrentTime",value:function(){return(new Date).getTime()}},{key:"hasBrowserSupport",value:function(){try{return this.type in window&&null!==window[this.type]}catch(e){return!1}}}]),e}(),vv=function(e){lv(n,e);var t=fv(n);function n(){return pv(this,n),t.apply(this,arguments)}return mv(n,null,[{key:"Instance",get:function(){return this.instance||(this.instance=new this({type:ov.LocalStorage}))}}]),n}(gv),bv=function(e){lv(n,e);var t=fv(n);function n(){return pv(this,n),t.apply(this,arguments)}return mv(n,null,[{key:"Instance",get:function(){return this.instance||(this.instance=new this({type:ov.SessionStorage}))}}]),n}(gv),_v=vv.Instance,wv=(bv.Instance,"URLSearchParams"in self),Tv="Symbol"in self&&"iterator"in Symbol,Sv="FileReader"in self&&"Blob"in self&&function(){try{return new Blob,!0}catch(e){return!1}}(),Ev="FormData"in self,Cv="ArrayBuffer"in self;if(Cv)var kv=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],xv=ArrayBuffer.isView||function(e){return e&&kv.indexOf(Object.prototype.toString.call(e))>-1};function Ov(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function Pv(e){return"string"!=typeof e&&(e=String(e)),e}function Rv(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return Tv&&(t[Symbol.iterator]=function(){return t}),t}function Av(e){this.map={},e instanceof Av?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function Iv(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function Lv(e){return new Promise((function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}}))}function jv(e){var t=new FileReader,n=Lv(t);return t.readAsArrayBuffer(e),n}function Dv(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function Nv(){return this.bodyUsed=!1,this._initBody=function(e){var t;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:Sv&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:Ev&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:wv&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():Cv&&Sv&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=Dv(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):Cv&&(ArrayBuffer.prototype.isPrototypeOf(e)||xv(e))?this._bodyArrayBuffer=Dv(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):wv&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},Sv&&(this.blob=function(){var e=Iv(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?Iv(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(jv)}),this.text=function(){var e,t,n,r=Iv(this);if(r)return r;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,n=Lv(t),t.readAsText(e),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),r=0;r<t.length;r++)n[r]=String.fromCharCode(t[r]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},Ev&&(this.formData=function(){return this.text().then(Bv)}),this.json=function(){return this.text().then(JSON.parse)},this}Av.prototype.append=function(e,t){e=Ov(e),t=Pv(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},Av.prototype.delete=function(e){delete this.map[Ov(e)]},Av.prototype.get=function(e){return e=Ov(e),this.has(e)?this.map[e]:null},Av.prototype.has=function(e){return this.map.hasOwnProperty(Ov(e))},Av.prototype.set=function(e,t){this.map[Ov(e)]=Pv(t)},Av.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},Av.prototype.keys=function(){var e=[];return this.forEach((function(t,n){e.push(n)})),Rv(e)},Av.prototype.values=function(){var e=[];return this.forEach((function(t){e.push(t)})),Rv(e)},Av.prototype.entries=function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),Rv(e)},Tv&&(Av.prototype[Symbol.iterator]=Av.prototype.entries);var Mv=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function Uv(e,t){var n,r,i=(t=t||{}).body;if(e instanceof Uv){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new Av(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,i||null==e._bodyInit||(i=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new Av(t.headers)),this.method=(n=t.method||this.method||"GET",r=n.toUpperCase(),Mv.indexOf(r)>-1?r:n),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function Bv(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var n=e.split("="),r=n.shift().replace(/\+/g," "),i=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(r),decodeURIComponent(i))}})),t}function Fv(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"",this.headers=new Av(t.headers),this.url=t.url||"",this._initBody(e)}Uv.prototype.clone=function(){return new Uv(this,{body:this._bodyInit})},Nv.call(Uv.prototype),Nv.call(Fv.prototype),Fv.prototype.clone=function(){return new Fv(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new Av(this.headers),url:this.url})},Fv.error=function(){var e=new Fv(null,{status:0,statusText:""});return e.type="error",e};var Vv=[301,302,303,307,308];Fv.redirect=function(e,t){if(-1===Vv.indexOf(t))throw new RangeError("Invalid status code");return new Fv(null,{status:t,headers:{location:e}})};var Hv=self.DOMException;try{new Hv}catch(e){(Hv=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),Hv.prototype.constructor=Hv}function zv(e,t){return new Promise((function(n,r){var i=new Uv(e,t);if(i.signal&&i.signal.aborted)return r(new Hv("Aborted","AbortError"));var o=new XMLHttpRequest;function a(){o.abort()}o.onload=function(){var e,t,r={status:o.status,statusText:o.statusText,headers:(e=o.getAllResponseHeaders()||"",t=new Av,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(e){var n=e.split(":"),r=n.shift().trim();if(r){var i=n.join(":").trim();t.append(r,i)}})),t)};r.url="responseURL"in o?o.responseURL:r.headers.get("X-Request-URL");var i="response"in o?o.response:o.responseText;setTimeout((function(){n(new Fv(i,r))}),0)},o.onerror=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.ontimeout=function(){setTimeout((function(){r(new TypeError("Network request failed"))}),0)},o.onabort=function(){setTimeout((function(){r(new Hv("Aborted","AbortError"))}),0)},o.open(i.method,function(e){try{return""===e&&self.location.href?self.location.href:e}catch(t){return e}}(i.url),!0),"include"===i.credentials?o.withCredentials=!0:"omit"===i.credentials&&(o.withCredentials=!1),"responseType"in o&&(Sv?o.responseType="blob":Cv&&-1!==i.headers.get("Content-Type").indexOf("application/octet-stream")&&(o.responseType="arraybuffer")),i.headers.forEach((function(e,t){o.setRequestHeader(t,e)})),i.signal&&(i.signal.addEventListener("abort",a),o.onreadystatechange=function(){4===o.readyState&&i.signal.removeEventListener("abort",a)}),o.send(void 0===i._bodyInit?null:i._bodyInit)}))}zv.polyfill=!0,self.fetch||(self.fetch=zv,self.Headers=Av,self.Request=Uv,self.Response=Fv);var qv=n(237),Wv=n.n(qv),$v=n(238);function Gv(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Yv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Yv(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Yv(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Kv={mobileDevice:/Mobi/i,iphone:/iphone/i,ipad:/ipad/i,android:/android/i,blackberry:/blackberry/i,windowsPhone:/windows phone/i,iosVersion:/OS\s+([\d_.-:]+)\s/i,androidVersion:/android\s+([\d_.-\/]+)[\s;:,\)]/i,blackberryVersion:/(blackberry|version)\s?\d*\/([\d.]+)/i,windowsPhoneVersion:/windows\sphone.*?([\d_.-\/]+)[\s;:,\)]/i,mac:/Mac/i,unix:/X11/i,linux:/Linux/i,windows:/Win/i,win2000:/nt 5.0/i,winXP:/nt 5.1/i,winVista:/nt 6.0/i,win7:/nt 6.1/i,win8:/nt 6.2/i,win81:/nt 6.3/i,win10:/nt 10.0/i,osxVersion:/OS\sX\s([\d_.]+)/i,chrome:/^(?!.*Edge).*Chrome/i,safari:/^(?!.*(?:Chrome|Edge)).*Safari/i,edge:/edge/i,ie:/(msie|trident)/i,opera:/(opr|opera)/i,firefox:/firefox/i,generalVersion:/(chrome|firefox|version)\/(\d+.*?)(\s|$)/i,operaVersion:/(opr|opera)\/(\d+).*?(\s|$)/i,ieVersion:/MSIE\s+(\d+).*?/i,edgeVersion:/(edge)\/(\d+).*?(\s|$)/i};function Xv(e,t,n){var r=Gv(t.exec(n)||[],1)[0];return r||(r="Unknown"),{name:e,version:r}}function Qv(e,t,n){if(!t)return{name:e,version:"Unknown"};var r=t.exec(n);return{name:e,version:r&&r.length?r[0].trim():"Unknown"}}var Jv=function(){var e=window.navigator.userAgent;return Kv.android.test(e)?Qv("Android",Kv.androidVersion,e):Kv.iphone.test(e)||Kv.ipad.test(e)?Qv("iOS",Kv.iosVersion,e):Kv.linux.test(e)?Qv("Linux",null,e):Kv.unix.test(e)?Qv("Unix",null,e):Kv.mac.test(e)?Qv("Macintosh",Kv.osxVersion,e):Kv.windows.test(e)?function(e,t){var n={name:e,version:null};return Kv.win2000.test(t)&&(n.version="2000"),Kv.winXP.test(t)&&(n.version="XP"),Kv.winVista.test(t)&&(n.version="Vista"),Kv.win7.test(t)&&(n.version="7"),Kv.win8.test(t)&&(n.version="8"),Kv.win81.test(t)&&(n.version="8.1"),Kv.win10.test(t)&&(n.version="10"),n.version||(n.version="Unknown"),n}("Windows",e):Kv.blackberry.test(e)?Qv("BlackBerry",Kv.blackberryVersion,e):Kv.windowsPhone.test(e)?Qv("Windows Phone",Kv.windowsPhoneVersion,e):{name:"Unknown",version:"Unknown"}},Zv=function(){var e=window.navigator.userAgent;return Kv.chrome.test(e)?Xv("Chrome",Kv.generalVersion,e):Kv.firefox.test(e)?Xv("Firefox",Kv.generalVersion,e):Kv.safari.test(e)?Xv("Safari",Kv.generalVersion,e):Kv.ie.test(e)?Xv("Internet Explorer",Kv.ieVersion,e):Kv.edge.test(e)?Xv("Edge",Kv.edgeVersion,e):Kv.opera.test(e)?Xv("Opera",Kv.operaVersion,e):{name:"Unknown",version:"Unknown"}};function eb(e){return(eb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var tb,nb=function(e){var t=eb(e);return"function"===t||"object"===t&&!!e},rb=function(e){return"function"==typeof e},ib=function(e,t){if(e){var n=e;return e.endsWith("/")||(n+="/"),t?n+=t.startsWith("/")?t.slice(1):t:n}},ob=n(103);!function(e){e.CvApSoutheast1="cv-ap-southeast-1",e.CvApSoutheast2="cv-ap-southeast-2",e.CvEuWest1="cv-eu-west-1",e.CvNaWest1="cv-na-west-1"}(tb||(tb={}));var ab={CvApSoutheast1:{systemName:tb.CvApSoutheast1},CvApSoutheast2:{systemName:tb.CvApSoutheast2},CvEuWest1:{systemName:tb.CvEuWest1},CvNaWest1:{systemName:tb.CvNaWest1}};function sb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var ub=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},lb=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=t,this.initialize()}var t,n,r;return t=e,(n=[{key:"initialize",value:function(){this.validateOptions()}},{key:"name",get:function(){return"CollectionApiClient"}},{key:"log",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!Array.isArray(e)){t.next=2;break}return t.abrupt("return",this.logBulk(e));case 2:if(this.shouldLog(e)){t.next=4;break}return t.abrupt("return");case 4:return this.validateEvent(e),t.t0=this,t.next=8,this.formatData(e);case 8:return t.t1=t.sent,t.next=11,t.t0.postData.call(t.t0,t.t1);case 11:case"end":return t.stop()}}),t,this)})))}},{key:"logBulk",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((n=e.filter((function(e){return i.shouldLog(e)}))).length){t.next=3;break}return t.abrupt("return");case 3:return n.forEach((function(e){return i.validateEvent(e)})),t.next=6,Promise.all(n.map((function(e){return i.formatData(e)})));case 6:return r=t.sent,t.next=9,this.postData(r);case 9:case"end":return t.stop()}}),t,this)})))}},{key:"validateOptions",value:function(){if(!rb(this.options.getUser))throw new Error("getUser option is required.")}},{key:"shouldLog",value:function(e){return!rb(this.options.shouldLog)||this.options.shouldLog(e)}},{key:"postData",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i,o;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getRegionalUrl(this.options.collectionApiUrls);case 2:return n=t.sent,r=JSON.stringify(e),i=Object.assign({"Content-Type":"application/json"},this.getSignatureHeader(r)),o=ib(n,"/v1/ingest"),Array.isArray(e)&&(o=ib(o,"/bulk")),t.next=9,fetch(o,{method:"POST",mode:"cors",headers:i,body:r});case 9:case"end":return t.stop()}}),t,this)})))}},{key:"getSignatureHeader",value:function(e){var t=new Wv.a("SHA-1","TEXT",{hmacKey:{value:"zXJL9nOHxzDlMUDjiP41",format:"TEXT",encoding:"UTF8"}});return t.update(e),{"cv-analytics-signature":"".concat(this.options.collectionApiClientId,".").concat(t.getHash("B64"))}}},{key:"getRegionalUrl",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getRegion();case 2:n=t.sent,t.t0=n.systemName,t.next=t.t0===tb.CvEuWest1?6:t.t0===tb.CvApSoutheast2?7:t.t0===tb.CvNaWest1?8:(t.t0,tb.CvApSoutheast1,9);break;case 6:return t.abrupt("return",e.cvEuWest1);case 7:return t.abrupt("return",e.cvApSoutheast2);case 8:return t.abrupt("return",e.cvNaWest1);case 9:return t.abrupt("return",e.cvApSoutheast1);case 10:case"end":return t.stop()}}),t,this)})))}},{key:"validateEvent",value:function(e){if("string"!=typeof e.type)throw new Error("Event type is required.");if(!nb(e.actionContext))throw new Error("Event actionContext is required.");if(!e.actionContext.entity)throw new Error("Event actionContext entity is required.")}},{key:"formatData",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.t0=e.type,t.next=3,this.getEventData(e);case 3:return t.t1=t.sent,t.t2=this.getEventMetadata(e),t.abrupt("return",{type:t.t0,data:t.t1,metadata:t.t2});case 6:case"end":return t.stop()}}),t,this)})))}},{key:"getEventData",value:function(e){return ub(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n,r,i,o,a,s;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.actionContext,t.next=3,this.getUserData();case 3:return r=t.sent,i={user:r,action:n,platform:this.getPlatformMetadata(),product:{name:this.options.productName,version:this.options.productVersion}},o=this.extractData(e),a=Object.keys(i).map((function(e){return e.toLowerCase()})),s=Object.keys(o).map((function(e){return e.toLowerCase()})),a.forEach((function(e){if(s.includes(e))throw Error("".concat(e," is a reserved key."))})),t.abrupt("return",Object.assign(Object.assign({},i),o));case 10:case"end":return t.stop()}}),t,this)})))}},{key:"extractData",value:function(e){return rb(this.options.formatData)?this.options.formatData(e):(t={},n=e.actionContext.entity,r=e.data,n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t);var t,n,r}},{key:"getUserData",value:function(){var e,t;return ub(this,void 0,void 0,regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.options.getUser();case 2:if(null==(r=n.sent)?void 0:r.id){n.next=5;break}return n.abrupt("return");case 5:return n.t0=r.id,n.t1=(null===(e=r.role)||void 0===e?void 0:e.toLowerCase())||"unknown",n.t2=(null===(t=r.userGroup)||void 0===t?void 0:t.toLowerCase())||ob.a.Unknown,n.t3=this.normalizeYearGroup(r.yearGroup),n.t4=r.customerId,n.t5=r.customerName,n.t6=r.customerGuid,n.t7=r.crmId,n.t8=r.countryCode,n.next=16,this.getRegion();case 16:return n.t9=n.sent,n.t10=r.isOpenCustomer,n.t11={id:n.t4,name:n.t5,customerGuid:n.t6,crmId:n.t7,country:n.t8,region:n.t9,openCustomer:n.t10},n.abrupt("return",{id:n.t0,role:n.t1,userGroup:n.t2,yearGroup:n.t3,customer:n.t11});case 20:case"end":return n.stop()}}),n,this)})))}},{key:"getRegion",value:function(){return ub(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.options.getUser();case 2:if(t=e.sent,n=(null==t?void 0:t.instanceRegion)||this.options.regionName){e.next=6;break}throw Error("RegionName is not set.");case 6:return e.abrupt("return",this.getRegionByName(n.toLowerCase()));case 7:case"end":return e.stop()}}),e,this)})))}},{key:"getPlatformMetadata",value:function(){return{browser:Zv(),os:Jv(),request:{url:window.location.href,referrer:document.referrer},screenResolution:"".concat(window.screen.width,"x").concat(window.screen.height)}}},{key:"getEventMetadata",value:function(e){return{client:{name:"".concat(this.name,".ts"),version:$v.a,region:this.getRegionByName(this.options.regionName)},timestamp:(new Date).toISOString(),eventVersion:e.eventVersion}}},{key:"getRegionByName",value:function(e){var t;return Object.values(ab).forEach((function(n){n.systemName===e&&(t=n)})),t}},{key:"normalizeYearGroup",value:function(e){return e?e.toLowerCase().split(" ").join("_"):"unknown"}}])&&sb(t.prototype,n),r&&sb(t,r),e}(),cb=n(2),fb=function(){return!0},hb=function(){return!1};var db=function(e){return e};function pb(e){if(e&&e.code)return e.code}function yb(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&e.id){var n={id:e.id};return e.name&&!t.ignoreTitle&&(n.title=e.name),n}}function mb(e){if(e&&e.length){var t=e[0];return{id:t.id,title:t.name}}}var gb,vb,bb,_b,wb=function(e){var t=e.model,n={id:t.id.toString(),year:t.productionYear,title:t.name,trackingCode:t.trackingCode},r=pb(t.rating),i=yb(t.series),o=mb(t.categories),a=yb(t.owner,{ignoreTitle:!0}),s=yb(t.playlist);return r&&(n.rating=r),a&&(n.ownerId=a.id),i&&(n.seriesId=i.id,n.series=i.title),o&&(n.category=o.title),s&&(n.playlist=s),n},Tb={getUploadData:function(e,t){var n=t.actionContext.entity;if(n===cb.EntityType.Video)return Tb.formatVideoUpload(e,t);if(n===cb.EntityType.Resource||n===cb.EntityType.Subtitle)return Tb.formatResourceUpload(e);if(n===cb.EntityType.Banner||n===cb.EntityType.Thumbnail)return e;throw new Error("Upload data event not correctly formatted.")},formatVideoUpload:function(e,t){var n=t.actionContext.workflowPhase;return n===cb.WorkflowPhase.Start?Tb.getStartVideoUploadData(e):n===cb.WorkflowPhase.Discard?Tb.getDiscardVideoUploadData(e):n===cb.WorkflowPhase.Complete?Tb.getCompleteUploadData(e):void 0},getStartVideoUploadData:function(e){return e&&e.length?(e instanceof FileList&&(e=Array.from(e)),e.map((function(t){return{fileName:t.name,size:t.size,type:t.type,count:e.length}}))):[]},getDiscardVideoUploadData:function(e){var t=function(t){var n=t.file,r=n.type,i=n.name,o=n.status,a=n.cvUpload,s={fileName:i,count:Array.isArray(e)?e.length:1,type:r,status:o};return t.progress&&(s.progress=t.progress.toFixed(2)),a&&(s.uploadId=a.uploadId),s};return Array.isArray(e)?e.map((function(e){return t(e)})):[t(e)]},getCompleteUploadData:function(e){return e&&e.length?e.map((function(t){return{fileName:t.fileName,libraryId:t.libraryId,folderId:t.folderId,autoCaption:t.autoCaption,count:e.length}})):[]},formatResourceUpload:function(e){var t={id:e.id,name:e.name};return nb(e.metadata)&&(t.type=e.metadata.type),t}};function Sb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Eb=(Sb(gb={},cb.UserAction.Navigate,hb),Sb(gb,cb.UserAction.Click,fb),Sb(gb,cb.UserAction.Search,fb),Sb(gb,cb.UserAction.InstantSearch,fb),Sb(gb,cb.UserAction.Play,fb),Sb(gb,cb.UserAction.Stream,fb),Sb(gb,cb.UserAction.WebPlayerStream,fb),Sb(gb,cb.UserAction.StreamRaw,fb),Sb(gb,cb.UserAction.StreamProgress,fb),Sb(gb,cb.UserAction.Rename,fb),Sb(gb,cb.UserAction.Move,fb),Sb(gb,cb.UserAction.Create,fb),Sb(gb,cb.UserAction.Delete,fb),Sb(gb,cb.UserAction.Associate,fb),Sb(gb,cb.UserAction.Dissociate,fb),Sb(gb,cb.UserAction.Filter,fb),Sb(gb,cb.UserAction.Sort,fb),Sb(gb,cb.UserAction.Approve,fb),Sb(gb,cb.UserAction.Reject,fb),Sb(gb,cb.UserAction.Disable,fb),Sb(gb,cb.UserAction.Upload,fb),Sb(gb,cb.UserAction.Download,hb),Sb(gb,cb.UserAction.SetAccess,fb),Sb(gb,cb.UserAction.AddToLocalCache,hb),Sb(gb,cb.UserAction.Share,fb),Sb(gb,cb.UserAction.Edit,fb),Sb(gb,cb.UserAction.Suggest,fb),Sb(gb,cb.UserAction.Favourite,fb),Sb(gb,cb.UserAction.ResolveWarning,fb),Sb(gb,cb.UserAction.DismissWarning,fb),Sb(gb,cb.UserAction.EditAssoc,fb),Sb(gb,cb.UserAction.Follow,fb),Sb(gb,cb.UserAction.Print,fb),Sb(gb,cb.UserAction.Copy,fb),Sb(gb,cb.UserAction.Activate,fb),Sb(gb,cb.UserAction.VerifyEmail,fb),Sb(gb,cb.UserAction.ChangePassword,fb),Sb(gb,cb.UserAction.Export,fb),gb),Cb=(Sb(vb={},cb.UserAction.Search,db),Sb(vb,cb.UserAction.InstantSearch,db),Sb(vb,cb.UserAction.Play,db),Sb(vb,cb.UserAction.Stream,wb),Sb(vb,cb.UserAction.StreamRaw,db),Sb(vb,cb.UserAction.StreamProgress,db),Sb(vb,cb.UserAction.Click,db),Sb(vb,cb.UserAction.Filter,db),Sb(vb,cb.UserAction.Sort,db),Sb(vb,cb.UserAction.SetAccess,db),Sb(vb,cb.UserAction.Approve,db),Sb(vb,cb.UserAction.Reject,db),Sb(vb,cb.UserAction.Create,db),Sb(vb,cb.UserAction.Delete,db),Sb(vb,cb.UserAction.Rename,db),Sb(vb,cb.UserAction.Move,db),Sb(vb,cb.UserAction.Edit,db),Sb(vb,cb.UserAction.Share,db),Sb(vb,cb.UserAction.Disable,db),Sb(vb,cb.UserAction.Suggest,db),Sb(vb,cb.UserAction.Upload,Tb.getUploadData),Sb(vb,cb.UserAction.ResolveWarning,db),Sb(vb,cb.UserAction.DismissWarning,db),Sb(vb,cb.UserAction.Follow,db),Sb(vb,cb.UserAction.Print,db),Sb(vb,cb.UserAction.Copy,db),vb),kb=(Sb(bb={},cb.UserAction.Search,(function(){return"search"})),Sb(bb,cb.UserAction.InstantSearch,(function(){return"search"})),Sb(bb,cb.UserAction.Filter,(function(){return"filter"})),Sb(bb,cb.UserAction.StreamRaw,(function(){return cb.EntityType.Video})),bb),xb={user:"target_user"},Ob=(Sb(_b={},cb.UserAction.StreamProgress,!0),Sb(_b,cb.UserAction.WebPlayerStream,!0),_b),Pb={shouldLog:function(e){return!!Eb[e.type](e)},formatData:function(e){var t=Cb[e.type],n=rb(t)?t(e.data,e):e.data;if(Ob[e.type])return n;var r=e.actionContext.entity;return rb(kb[e.type])&&(r=kb[e.type](e)),xb[r]&&(r=xb[r]),Sb({},r,n)}};function Rb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Ab=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=t,this.initialize()}var t,n,r;return t=e,(n=[{key:"logStream",value:function(){var e="v:".concat(this.options.videoId);_v.cacheExists(e)||(this.collectionApiClient.log({type:cb.UserAction.WebPlayerStream,actionContext:this.getActionContext(),data:{video:{id:this.options.videoId},flags:{isUsingLocalCache:this.options.isUsingLocalCache}},eventVersion:cb.EventVersion.V2}),_v&&_v.cacheSet(e,null,300))}},{key:"logVideoProgress",value:function(e){var t=this;this.collectionApiClient.log(e.map((function(e){return{type:cb.UserAction.StreamProgress,actionContext:t.getActionContext(),data:{progress:e,video:{id:t.options.videoId}},eventVersion:cb.EventVersion.V1}})))}},{key:"initialize",value:function(){this.setupCollectionApiClient()}},{key:"setupCollectionApiClient",value:function(){var e=this;this.collectionApiClient=new lb({productName:"player.web",productVersion:this.options.productVersion,regionName:this.options.regionName,collectionApiUrls:this.options.collectionApiUrls,collectionApiClientId:this.options.collectionApiClientId,getUser:function(){return e.getCurrentUser()},shouldLog:Pb.shouldLog,formatData:Pb.formatData})}},{key:"getCurrentUser",value:function(){var e=this;return new Promise((function(t){t({id:e.options.userId,customerId:e.options.customerId})}))}},{key:"getActionContext",value:function(){return{entity:this.getEntityType(),location:this.getLocationContext(),productArea:void 0,descriptor:this.options.isEmbedded?cb.PlayerDescriptor.Embedded:void 0,workflowPhase:void 0}}},{key:"getEntityType",value:function(){switch(this.options.mediaType){case"MasterVideo":return cb.EntityType.Video;case"MasterInteractive":return cb.EntityType.Interactive;case"MasterClip":return cb.EntityType.Clip}}},{key:"getLocationContext",value:function(){switch(this.options.playerType){case"player":return cb.LocationContext.Player;case"interactive-player":return cb.LocationContext.InteractivePlayer;case"create-clip-player":return cb.LocationContext.CreateClipPlayer}}}])&&Rb(t.prototype,n),r&&Rb(t,r),e}(),Ib="\n <svg viewBox='0 0 434 71'>\n <g>\n <path fill='#FFFFFF' d='M114.44 56.57l3.5 3.5a32.87 32.87 0 0 1-25.16 11.26c-19.63 0-33.62-15.54-33.62-35.16C59.16 16.55 73.16 1 92.78 1a32.31 32.31 0 0 1 24.19 10.4l-3.6 3.3a27.32 27.32 0 0 0-20.59-8.74c-16.91 0-28.39 13.5-28.39 30.21s11.48 30.21 28.39 30.21a28.08 28.08 0 0 0 21.66-9.81zM126.64 1h4.55v70.22h-4.73L126.64 1zm17.3 10.6a3.7 3.7 0 1 1 0 7.4 3.7 3.7 0 0 1 0-7.4zm-2.41 15.07h4.81v44.56h-4.81V26.67zm48 33.15l3.33 3.15a21.8 21.8 0 0 1-17.31 8.61c-12.59 0-21.76-10-21.76-22.22 0-12.22 9.17-22.22 21.76-22.22a21.84 21.84 0 0 1 16.85 8l-3.43 3.06a17.15 17.15 0 0 0-13.42-6.3c-10.09 0-16.76 8.15-16.76 17.5s6.67 17.5 16.76 17.5a17.38 17.38 0 0 0 13.98-7.08zm14.99-9.33v20.74h-4.73V1.01h4.73v47.75l20.74-19.02h6.64l-21.56 19.84L234 71.23h-7.01l-22.47-20.74z'/>\n <path fill='#F8981D' d='M304.09 19.4a5.56 5.56 0 1 1 0-11.12 5.56 5.56 0 0 1 0 11.12zm-5.56 7.27h11.11v44.56h-11.11V26.67zm61.42 22.15c0 .81 0 2.42-.09 4h-31.75c.8 3.77 5.2 8.61 11.93 8.61a17.11 17.11 0 0 0 11.66-4.31l5.38 8.16a27.23 27.23 0 0 1-17 6.1c-12.92 0-22.88-9.87-22.88-22.34s9.06-22.33 21.35-22.33c11.62-.04 21.4 9.02 21.4 22.11zm-10.77-3.76c-.18-3.68-3.58-8.62-10.67-8.62-6.91 0-10.05 4.85-10.4 8.62h21.07zM385.92 71h-6.42l-19.64-44.37h13.97l9.16 23.98 9.72-23.98h8.31l9.63 23.98 9.16-23.98h13.97L414.24 71h-6.52l-10.85-23.7L385.92 71zm-120.22.35h-6L226.11 1.01h17.01l19.42 44.18 18.08-44.18h16.91L265.7 71.35zM0 1l41 35L0 71V1z'/>\n </g>\n </svg>\n";function Lb(e){return(Lb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function jb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Db(e,t,n){return(Db="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Bb(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Nb(e,t){return(Nb=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Mb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Bb(e);if(t){var i=Bb(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ub(this,n)}}function Ub(e,t){return!t||"object"!==Lb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Bb(e){return(Bb=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Fb=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nb(e,t)}(o,e);var t,n,r,i=Mb(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options_=t,n}return t=o,(n=[{key:"createEl",value:function(e,t,n){var r="<h1>".concat(this.options_.title,"</h1>");if(!this.options_.seriesName)return Db(Bb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n);var i=this.buildSeasonEpisodeString();return i?(r="<div class='cv-series-text'>".concat(this.options_.seriesName.toUpperCase()," ").concat(i,"</div>")+r,Db(Bb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n)):(r="<div class='cv-series-text'>".concat(this.options_.seriesName.toUpperCase(),"</div>")+r,Db(Bb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{innerHTML:r}),n))}},{key:"buildSeasonEpisodeString",value:function(){if(!this.options_.seasonNumber||!this.options_.episodeNumber)return"";var e=this.padNumber(this.options_.seasonNumber,2),t=this.padNumber(this.options_.episodeNumber,2);return"S".concat(e," • E").concat(t)}},{key:"padNumber",value:function(e,t){var n=e.toString();if(n.length>=t)return n;for(t-=n.length;t>0;)n="0"+n,t--;return n}}])&&jb(t.prototype,n),r&&jb(t,r),o}(Fu.getComponent("Component"));function Vb(e){return(Vb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Hb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zb(e,t,n){return(zb="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Gb(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function qb(e,t){return(qb=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Wb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Gb(e);if(t){var i=Gb(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return $b(this,n)}}function $b(e,t){return!t||"object"!==Vb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Gb(e){return(Gb=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Yb=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&qb(e,t)}(o,e);var t,n,r,i=Wb(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options_=t,n}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-splash-warning-container ".concat(zb(Gb(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){var r=zb(Gb(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n);if(!this.options_.ratingCode)return r;var i=this.mapCodeToColourClass(this.options_.ratingCode);return r.appendChild(Fu.dom.createEl("div",{className:"cv-splash-rating badge rating-badge ".concat(i),innerHTML:this.options_.ratingCode})),this.options_.warning&&r.appendChild(Fu.dom.createEl("div",{className:"cv-splash-warning",innerHTML:this.options_.warning})),r}},{key:"mapCodeToColourClass",value:function(e){switch(e){case"E":return"bg-purple";case"G":return"bg-green";case"PG":return"bg-info";case"M":return"bg-red";case"MA15+":return"bg-pink";case"R18+":return"bg-yellow"}}}])&&Hb(t.prototype,n),r&&Hb(t,r),o}(Fu.getComponent("Component"));function Kb(e){return(Kb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Xb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Qb(e,t){return(Qb=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Jb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=e_(e);if(t){var i=e_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Zb(this,n)}}function Zb(e,t){return!t||"object"!==Kb(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function e_(e){return(e_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var t_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Qb(e,t)}(o,e);var t,n,r,i=Jb(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"createEl",value:function(){var e=Fu.dom.createEl("div",{className:"cv-splash-metadata ".concat(this.options_.embed?"cv-embed-splash-metadata":"")});return this.options_.embed&&e.appendChild(new Fb(this.player_,{title:this.options_.title,seriesName:this.options_.seriesName,seasonNumber:this.options_.seasonNumber,episodeNumber:this.options_.episodeNumber}).el()),e.appendChild(new Yb(this.player_,{warning:this.options_.warning,ratingCode:this.options_.ratingCode}).el()),e}}])&&Xb(t.prototype,n),r&&Xb(t,r),o}(Fu.getComponent("Component"));n(413);function n_(e){return(n_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i_(e,t,n){return(i_="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=u_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function o_(e,t){return(o_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function a_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=u_(e);if(t){var i=u_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return s_(this,n)}}function s_(e,t){return!t||"object"!==n_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u_(e){return(u_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&o_(e,t)}(o,e);var t,n,r,i=a_(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addChild(new t_(n.player_,n.options_)),n}return t=o,(n=[{key:"createEl",value:function(e,t,n){var r="<div class='cv-player-mask'></div>";return this.options_.embed&&(r+="<div class='cv-embed-logo'>".concat(Ib,"</div>")),i_(u_(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass(),innerHTML:r}),n)}}])&&r_(t.prototype,n),r&&r_(t,r),o}(Fu.getComponent("Component"));function c_(e){return function(e){if(Array.isArray(e))return f_(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return f_(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f_(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f_(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var d_,p_=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},y_=Fu.getComponent("Player"),m_=450,g_=function(){function e(t,n){var r=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.streamLogged=!1,this.options=Fu.mergeOptions({},e.options_,n),null===this.options.playerApi)throw new Error("PlayerApi required");this.initialize(),this.createEl(t),this.buildVideoJs(),this.bindEventListeners(),this.setupSeekBar(),this.fetchConfig(),this.logStream=this.logStream.bind(this),this.player.ready((function(){r._configurePlugins(),r.options.setup&&r.options.setup(r.options,r.player),r.options.startTime&&r.player.currentTime(r.options.startTime),r.fetch().catch((function(e){r.player.error(e.message),r.options.onError&&r.options.onError(e)}))}))}var t,n,r;return t=e,(n=[{key:"initialize",value:function(){}},{key:"_configurePlugins",value:function(){this.player.progressReporterPlugin({onFlush:this.onFlushProgress=this.onFlushProgress.bind(this)}),this.configurePlugins()}},{key:"configurePlugins",value:function(){}},{key:"onFlushProgress",value:function(e){var t;null===(t=this.analyticsService)||void 0===t||t.logVideoProgress(e)}},{key:"buildVideoJs",value:function(){return this.player=Fu(this.el,this.getPlayerOptions())}},{key:"getPlayerOptions",value:function(){return{controls:this.options.controls,autoplay:this.options.autoplay,fluid:!this.options.embed,fill:!!this.options.embed,inactivityTimeout:500,controlBar:{children:["timeWrapper","progressControl"]},children:[].concat(c_(y_.prototype.options_.children),["collapserator"]),userActions:{hotkeys:Kg},playbackRates:this.options.playbackRates,techOrder:["chromecast","html5"]}}},{key:"fetch",value:function(){return p_(this,void 0,void 0,regeneratorRuntime.mark((function e(){var t,n,r,i=this;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=this.options.fetch,void 0===this.options.fetch&&(t=function(e){var t="".concat(i.options.playerApi.origin,"/api/playback?viewKey=").concat(e);return sv.get(t)}),this.options.viewKey){e.next=4;break}throw new Error("Please specify a viewKey or a fetch function");case 4:return e.next=6,t(this.options.viewKey);case 6:if(n=e.sent){e.next=9;break}throw new Error("Error fetching playback object");case 9:n.chapters.list.length>0&&(r=this.player.addTextTrack("chapters"),n.chapters.list.forEach((function(e){r.addCue({startTime:e.timestamp,endTime:e.endTimestamp,text:e.name})})),r.trigger({type:"loadeddata",target:r})),this.player.progressiveFiles({sources:n.files.progressive.map((function(e){return{id:e.profile,mimeType:e.mimeType,url:e.url}}))}),n.subtitles.list.length>0&&(n.subtitles.list.forEach((function(e){"text/vtt"===e.mimeType&&i.player.addRemoteTextTrack({kind:"subtitles",src:e.url,language:e.language,label:e.label},!0)})),this.player.persistSubtitleSettingsPlugin({showSubtitles:n.settings.showSubtitles,subtitleSize:n.settings.playbackSubtitleSizeDefault})),n.posterUrl&&this.player.poster(n.posterUrl),this.setupSplash(n),this.options.showResources&&n.resources&&this.player.resourcesPlugin({resources:n.resources.list,imageCdnUrl:this.options.imageCdnUrl}),this.additionalSetup(n);case 16:case"end":return e.stop()}}),e,this)})))}},{key:"fetchConfig",value:function(){var e=this;if(!d_&&!this.options.fetch){var t="".concat(this.options.playerApi.origin,"/api/config");sv.get(t).then((function(t){d_=t,e.trigger("config:loaded")}))}}},{key:"additionalSetup",value:function(e){var t,n,r=this;this.player.localCache({localCacheAddresses:e.localCacheAddresses,enabled:null===(t=this.options.enableLocalCache)||void 0===t||t}),this.player.persistQualitySettingsPlugin({playbackProfile:e.settings.playbackProfile,playbackProfileLocalCache:e.settings.playbackProfileLocalCache}),this.player.whiteboardModePlugin(),this.player.chromecast({title:e.title});var i=this.options.enableLocalCache&&!!(null===(n=e.localCacheAddresses)||void 0===n?void 0:n.length);d_?this.setupAnalyticsService(e,i):this.one("config:loaded",(function(){return r.setupAnalyticsService(e,i)}))}},{key:"setupAnalyticsService",value:function(e,t){this.analyticsService=new Ab({collectionApiUrls:d_.collectionApi.urls,collectionApiClientId:d_.collectionApi.clientId,productVersion:Ku.a,regionName:"cv-ap-southeast-1",videoId:e.videoId,userId:e.viewerId,customerId:e.viewerCustomerId,mediaType:e.mediaType,playerType:this.getAnalyticsPlayerType(),isEmbedded:!!this.options.embed,isUsingLocalCache:t}),this.on("timeupdate",this.logStream)}},{key:"logStream",value:function(){this.player.currentTime()<3||this.streamLogged||(this.analyticsService.logStream(),this.streamLogged=!0,this.off("timeupdate",this.logStream))}},{key:"getAnalyticsPlayerType",value:function(){return"player"}},{key:"createEl",value:function(e){var t;"string"==typeof e?(e=function(e){return 0===e.indexOf("#")?e.slice(1):e}(e),t=Fu.dom.$("#"+e)):t=e;var n="video-js";return this.getPlayerClassName()&&(n+=" ".concat(this.getPlayerClassName())),this.el=Fu.dom.createEl("video",{},{class:n}),t.appendChild(this.el),this.el}},{key:"getPlayerClassName",value:function(){return""}},{key:"on",value:function(e,t){this.player.on(e,t)}},{key:"one",value:function(e,t){this.player.one(e,t)}},{key:"off",value:function(e,t){this.player.off(e,t)}},{key:"trigger",value:function(e,t){return this.player.trigger(e,t)}},{key:"dispose",value:function(){this.player.dispose()}},{key:"ready",value:function(e){this.player.ready(e)}},{key:"play",value:function(){this.player.play()}},{key:"currentTime",value:function(e){return this.player.currentTime(e)}},{key:"bindEventListeners",value:function(){var e=this,t=function(){return e.configureMenuDimensions()};if(this.on("resize",t),this.on("fullscreenchange",t),this.one("play",t),this.on("resizemenus",t),this.player.on("dispose",(function(){e.off("resize",t),e.off("fullscreenchange",t),e.off("resizemenus",t)})),this.options.hotkeyElQuerySelector){var n=Fu.dom.$(this.options.hotkeyElQuerySelector);n&&(this.player.on(n,"keydown",this.player.handleKeyDown),this.player.on("dispose",(function(){e.player.off(n,"keydown",e.player.handleKeyDown)})))}}},{key:"setupSeekBar",value:function(){var e=this.getSeekBarName(),t=this.player.controlBar.getChild("progressControl");t.addChild(e,this.getSeekBarOptions()),t.setSeekBarName(e)}},{key:"setupSplash",value:function(e){var t=this.player.getChild("posterImage"),n=new l_(this.player,{embed:this.options.embed,posterUrl:e.posterUrl,title:e.title,ratingCode:e.ratingCode,seriesName:e.seriesName,seasonNumber:e.seasonNumber,episodeNumber:e.episodeNumber});t.addChild(n)}},{key:"getSeekBarOptions",value:function(){return{}}},{key:"getSeekBarName",value:function(){return"ChapterSeekBar"}},{key:"configureMenuDimensions",value:function(){var e=this;if(this.player.isFullscreen()){var t=this.player.whiteboardModePlugin().side;if("top"===t){var n=this.player.getChild("collapserator"),r=n.getChild("volumePanel"),i=n.children_.indexOf(r);n.removeChild(r),n.addChild("volumePanel",{inline:!1},i)}else{var o=this.player.getChild("collapserator"),a=o.getChild("volumePanel"),s=o.children_.indexOf(a);o.removeChild(a),o.addChild("volumePanel",{inline:!0},s)}if("left"===t||"right"===t||"top"===t){var u=this.player.currentWidth();return void this.player.el().querySelectorAll(".vjs-menu").forEach((function(e){e.style.paddingTop=null,e.style.marginBottom=null,e.style.width="calc(".concat(u,"px - 4em)")}))}}var l=this.player.currentWidth(),c=this.player.currentHeight()/l*100,f=this.player.el().querySelector(".cv-collapsorator"),h=this.player.el().querySelectorAll(".vjs-menu"),d=f&&f.offsetHeight;d?h&&h.length&&h.forEach((function(t){t.style.paddingTop="calc(".concat(c,"% - ").concat(d,"px)"),t.style.marginBottom="".concat(d,"px"),t.style.width=null,t.querySelector(".vjs-menu-content")&&(l<=m_?e.player.addClass("cv-player-small"):e.player.removeClass("cv-player-small"))})):this.one("play",(function(){return e.configureMenuDimensions()}))}}])&&h_(t.prototype,n),r&&h_(t,r),e}();g_.options_={viewKey:null,controls:!0,playbackRates:[.5,1,1.5,2],playerApi:new URL("http://localhost:52000"),enableLocalCache:!0};n(414);function v_(e){return(v_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function b_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function __(e,t,n){return(__="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=E_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function w_(e,t){return(w_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function T_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=E_(e);if(t){var i=E_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return S_(this,n)}}function S_(e,t){return!t||"object"!==v_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function E_(e){return(E_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var C_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&w_(e,t)}(o,e);var t,n,r,i=T_(o);function o(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"vjs-example-button ".concat(__(E_(o.prototype),"buildCSSClass",this).call(this))}}])&&b_(t.prototype,n),r&&b_(t,r),o}(Fu.getComponent("Button"));C_.prototype.controlText_="Example Button",Fu.registerComponent("ExampleButton",C_);var k_=n(28),x_=n.n(k_);function O_(e){return(O_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function P_(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function R_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function A_(e,t,n){return t&&R_(e.prototype,t),n&&R_(e,n),e}function I_(e,t,n){return(I_="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=M_(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function L_(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&j_(e,t)}function j_(e,t){return(j_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function D_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=M_(e);if(t){var i=M_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return N_(this,n)}}function N_(e,t){return!t||"object"!==O_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function M_(e){return(M_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var U_=function(e){L_(n,e);var t=D_(n);function n(e,r){return P_(this,n),t.call(this,e,r)}return A_(n,[{key:"dispose",value:function(){x_.a.unmountComponentAtNode(this.el()),I_(M_(n.prototype),"dispose",this).call(this)}}]),n}(Fu.getComponent("Component")),B_={tagName:"div"};function F_(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:B_;if(!e)throw new Error("componentCtor is required");var n=function(n){L_(i,n);var r=D_(i);function i(){return P_(this,i),r.apply(this,arguments)}return A_(i,[{key:"createEl",value:function(){var n=Fu.dom.createEl(t.tagName,t.properties,t.attributes);return x_.a.render(e(this.player_,this.options_),n),n}}]),i}(U_);return n}function V_(){return i.a.createElement("button",{style:{height:"100%",cursor:"pointer"},onClick:function(){return console.log("Clicked React Button")}},"React Button")}function H_(e){return(H_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function z_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function q_(e,t){return(q_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function W_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=G_(e);if(t){var i=G_(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return $_(this,n)}}function $_(e,t){return!t||"object"!==H_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function G_(e){return(G_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("ExampleReactButton",F_((function(){return i.a.createElement(V_,null)})));var Y_=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&q_(e,t)}(o,e);var t,n,r,i=W_(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t),e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){this.player.getChild("collapserator").addChild("exampleReactButton")}}])&&z_(t.prototype,n),r&&z_(t,r),o}(Fu.getPlugin("plugin"));function K_(e){return(K_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function X_(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Q_(e,t){return(Q_=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function J_(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ew(e);if(t){var i=ew(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Z_(this,n)}}function Z_(e,t){return!t||"object"!==K_(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ew(e){return(ew=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("examplePlugin",Y_);var tw=Fu.getPlugin("plugin"),nw="cvplayer-mute",rw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Q_(e,t)}(o,e);var t,n,r,i=J_(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).initialize(),t}return t=o,(n=[{key:"initialize",value:function(){var e=this;if(Ll()){this.player.on("volumechange",(function(){Dl("cvplayer-volume",e.player.volume().toString()),Dl(nw,e.player.muted().toString())}));var t=jl("cvplayer-volume"),n=jl(nw);t&&this.player.volume(+t),n&&this.player.muted("true"===n)}}}])&&X_(t.prototype,n),r&&X_(t,r),o}(tw);function iw(e){return(iw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ow(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function aw(e,t){return(aw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function sw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=cw(e);if(t){var i=cw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return uw(this,n)}}function uw(e,t){return!t||"object"!==iw(t)&&"function"!=typeof t?lw(e):t}function lw(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cw(e){return(cw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("persistVolumePlugin",rw);var fw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&aw(e,t)}(o,e);var t,n,r,i=sw(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).hasScreenOrientation()&&t.player.supportsFullScreen()?(t.onRotate=t.onRotate.bind(lw(t)),t.onFullscreenChange=t.onFullscreenChange.bind(lw(t)),t.initialize(),t):uw(t)}return t=o,(n=[{key:"initialize",value:function(){var e=this;window.addEventListener("orientationchange",this.onRotate),this.hasScreenLock()&&this.player.on("fullscreenchange",this.onFullscreenChange),this.player.one("dispose",(function(){var t;window.removeEventListener("orientationchange",e.onRotate),e.hasScreenLock()&&(null===(t=e.player)||void 0===t||t.off("fullscreenchange",e.onFullscreenChange))}))}},{key:"onFullscreenChange",value:function(){!this.getAngle()&&this.player.isFullscreen()?window.screen.orientation.lock("portrait-primary"):window.screen.orientation.unlock()}},{key:"onRotate",value:function(){var e=this.getAngle();90===e||-90===e||270===e?this.player.requestFullscreen():this.player.isFullscreen()&&this.player.exitFullscreen()}},{key:"hasScreenOrientation",value:function(){var e,t;return"function"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.lock)}},{key:"hasScreenLock",value:function(){var e,t;return"function"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.lock)}},{key:"getAngle",value:function(){var e,t;return"number"==typeof(null===(t=null===(e=window.screen)||void 0===e?void 0:e.orientation)||void 0===t?void 0:t.angle)?window.screen.orientation.angle:0}}])&&ow(t.prototype,n),r&&ow(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("fullscreenOnRotatePlugin",fw);n(418);function hw(e){return(hw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function dw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pw(e,t){return(pw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function yw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=vw(e);if(t){var i=vw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return mw(this,n)}}function mw(e,t){return!t||"object"!==hw(t)&&"function"!=typeof t?gw(e):t}function gw(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vw(e){return(vw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var bw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&pw(e,t)}(o,e);var t,n,r,i=yw(o);function o(e,t){var n,r,a,s;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).update=(r=n.update.bind(gw(n)),a=1e3,s=window.performance.now(),function(){var e=window.performance.now();e-s>=a&&(r.apply(void 0,arguments),s=e)}),e.on("timeupdate",n.update),e.on("dispose",(function(){e.off("timeupdate",n.update)})),n}return t=o,(n=[{key:"update",value:function(){var e=this.player_.currentTime();this.el_.href=this.options_.getExternalLink({currentTime:Math.round(e)})}},{key:"buildCSSClass",value:function(){return"cv-open-externally-button"}},{key:"createEl",value:function(){var e={innerHTML:Ib,className:this.buildCSSClass()},t={type:"button",href:this.options_.getExternalLink({currentTime:0}),target:"_blank"},n=Fu.dom.createEl("a",e,t);return this.createControlTextEl(n),n}}])&&dw(t.prototype,n),r&&dw(t,r),o}(Fu.getComponent("Button"));function _w(e){return(_w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ww(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Tw(e,t){return(Tw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Sw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Cw(e);if(t){var i=Cw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ew(this,n)}}function Ew(e,t){return!t||"object"!==_w(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Cw(e){return(Cw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}bw.prototype.controlText_="Open in ClickView",Fu.registerComponent("OpenExternallyButton",bw);var kw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Tw(e,t)}(o,e);var t,n,r,i=Sw(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){var e=this.player.getChild("collapserator"),t=e.getChild("customControlSpacer"),n=e.children_.indexOf(t);e.addChild("OpenExternallyButton",{getExternalLink:this.options.getExternalLink},n+1)}}])&&ww(t.prototype,n),r&&ww(t,r),o}(Fu.getPlugin("plugin"));function xw(e){return(xw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Ow(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Pw(e,t){return(Pw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Rw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Lw(e);if(t){var i=Lw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Aw(this,n)}}function Aw(e,t){return!t||"object"!==xw(t)&&"function"!=typeof t?Iw(e):t}function Iw(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Lw(e){return(Lw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("openExternallyPlugin",kw);var jw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Pw(e,t)}(o,e);var t,n,r,i=Rw(o);function o(e,t){var n;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e),void 0===t.startTime)throw Error("Invalid clip start");if(void 0===t.endTime)throw Error("Invalid clip end");if(t.startTime>t.endTime)throw Error("Clip start cannot be greater than clip end");return n._clipStart=t.startTime,n._clipEnd=t.endTime,n.playerEndedFn=n.player.ended.bind(e),n.playerDurationFn=n.player.duration.bind(e),n.playerCurrentTimeFn=n.player.currentTime.bind(e),n.playerbufferedFn=n.player.buffered.bind(e),n.player.ended=n.ended.bind(Iw(n)),n.player.duration=n.duration.bind(Iw(n)),n.player.currentTime=n.currentTime.bind(Iw(n)),n.player.buffered=n.buffered.bind(Iw(n)),n.initialize(),n.player.ready((function(){n.player.trigger("durationchange")})),n}return t=o,(n=[{key:"clipStart",get:function(){var e=this.playerDurationFn();return this._clipStart>e?e:this._clipStart}},{key:"clipEnd",get:function(){var e=this.playerDurationFn();return this._clipEnd>e?e:this._clipEnd}},{key:"dispose",value:function(){this.player.off("timeupdate",this.onTimeUpdate),this.player.off("play",this.onPlay),this.player.ended=this.playerEndedFn,this.player.duration=this.playerDurationFn,this.player.currentTime=this.playerCurrentTimeFn,this.player.buffered=this.playerbufferedFn,this.player.trigger("durationchange")}},{key:"initialize",value:function(){var e=this;this.onTimeUpdate=this.onTimeUpdate.bind(this),this.onPlay=this.onPlay.bind(this),this.player.on("timeupdate",this.onTimeUpdate),this.player.on("play",this.onPlay),this.player.on("dispose",(function(){e.dispose()}))}},{key:"onPlay",value:function(){this._isEnded&&this.player.currentTime(0)}},{key:"onTimeUpdate",value:function(){var e=this.getCurrentTime(!1);e>this.clipEnd?this._isEnded||(this.player.pause(),this.player.trigger("ended"),this._isEnded=!0):(this._isEnded=!1,e<this.clipStart&&this.playerCurrentTimeFn(this.clipStart))}},{key:"ended",value:function(){return this.getCurrentTime(!1)>this.clipEnd}},{key:"duration",value:function(e){return void 0!==e&&this.playerDurationFn(e),this.clipEnd-this.clipStart}},{key:"currentTime",value:function(e){if(void 0===e)return this.getCurrentTime(!0);for(var t=e+this.clipStart,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];this.playerCurrentTimeFn.apply(this,[t].concat(r))}},{key:"getCurrentTime",value:function(e){var t=this.playerCurrentTimeFn(),n=0;return t>=this.clipStart&&(n=t-this.clipStart),this.player.getCache().currentTime=n,e?n:t}},{key:"buffered",value:function(){for(var e=this.playerbufferedFn(),t=[],n=0;n<e.length;n++)t[n]=[Math.max(0,e.start(n)-this.clipStart),Math.min(Math.max(0,e.end(n)-this.clipStart),this.player.duration())];return Fu.createTimeRanges(t)}}])&&Ow(t.prototype,n),r&&Ow(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("clipPlugin",jw);n(419);function Dw(e){return(Dw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Nw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Mw(e,t,n){return(Mw="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Vw(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function Uw(e,t){return(Uw=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Bw(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Vw(e);if(t){var i=Vw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Fw(this,n)}}function Fw(e,t){return!t||"object"!==Dw(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Vw(e){return(Vw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var Hw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Uw(e,t)}(o,e);var t,n,r,i=Bw(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-touch-control-ui ".concat(Mw(Vw(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return Mw(Vw(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass()}),n)}},{key:"setUi",value:function(e,t){var n=this,r=e>0,i=r?"cv-touch-right":"cv-touch-left";this.el_.className=this.buildCSSClass()+" cv-ui-touch-active",this.el_.innerHTML="\n <div class='".concat(i,"'>\n <div class='cv-touch-text'>\n ").concat(r?"+":"").concat(10*e,"s\n </div>\n </div>\n "),window.clearTimeout(this.timeoutId),this.timeoutId=window.setTimeout((function(){n.removeText()}),t)}},{key:"removeText",value:function(){this.el_.className=this.buildCSSClass(),this.el_.innerHTML=""}}])&&Nw(t.prototype,n),r&&Nw(t,r),o}(Fu.getComponent("component"));function zw(e){return(zw="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function qw(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ww(e,t){return(Ww=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function $w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Yw(e);if(t){var i=Yw(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Gw(this,n)}}function Gw(e,t){return!t||"object"!==zw(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Yw(e){return(Yw=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("TouchControls",Hw);var Kw=Fu.getPlugin("plugin"),Xw=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ww(e,t)}(o,e);var t,n,r,i=$w(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).doubleTouchCount=0,t.seekStartTime=0,t.directionModifier=0,t.bindFunctions(),t.initialize(),t}return t=o,(n=[{key:"bindFunctions",value:function(){this.onTouchStart=this.onTouchStart.bind(this),this.onTouchEnd=this.onTouchEnd.bind(this),this.reBindEventListeners=this.reBindEventListeners.bind(this),this.unBindEventListeners=this.unBindEventListeners.bind(this)}},{key:"initialize",value:function(){this.player.addChild("TouchControls"),this.touchControls=this.player.getChild("TouchControls"),this.player.on("ready",this.reBindEventListeners),this.player.on("dispose",this.unBindEventListeners),this.reBindEventListeners()}},{key:"reBindEventListeners",value:function(){this.tech=this.player.tech(!0),"Html5"===this.tech.name()&&(this.on(this.tech,"touchstart",this.onTouchStart),this.on(this.tech,"touchend",this.onTouchEnd))}},{key:"unBindEventListeners",value:function(){this.tech&&(this.off(this.tech,"touchstart",this.onTouchStart),this.off(this.tech,"touchend",this.onTouchEnd))}},{key:"onTouchStart",value:function(e){this.touchStartTime=e.timeStamp}},{key:"onTouchEnd",value:function(e){var t=this;if(e.changedTouches.length){if(e.timeStamp-this.lastTouchTime<300)return this.onDoubleTouch(e),void(this.lastTouchTime=e.timeStamp);this.resetProperties(),this.lastTouchTime=e.timeStamp,e.timeStamp-this.touchStartTime<300&&window.setTimeout((function(){t.doubleTouchCount||(t.player.paused()?t.player.play():t.player.pause())}),300)}}},{key:"resetProperties",value:function(){this.doubleTouchCount=0,this.seekStartTime=0,this.directionModifier=0}},{key:"onDoubleTouch",value:function(e){var t=this.player.el().getBoundingClientRect(),n=t.left+t.width/2;if(0===this.doubleTouchCount&&(this.seekStartTime=this.player.currentTime(),e.changedTouches[0].pageX<n?this.directionModifier=-1:this.directionModifier=1),this.doubleTouchCount++,this.directionModifier<0){if(10*this.doubleTouchCount>this.seekStartTime+10)return;return this.touchControls.setUi(-this.doubleTouchCount,900),void this.player.currentTime(this.player.currentTime()-10)}var r=this.player.duration()-this.seekStartTime;10*this.doubleTouchCount>r+10||(this.touchControls.setUi(this.doubleTouchCount,900),this.player.currentTime(this.player.currentTime()+10))}}])&&qw(t.prototype,n),r&&qw(t,r),o}(Kw);Fu.registerPlugin("touchControls",Xw);n(420);function Qw(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Jw(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Jw(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Jw(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Zw(e){var t,n=Qw(r.useState(105),2),i=n[0],o=n[1],a=r.useRef(e.player.duration()-e.player.currentTime()),s=Qw(r.useState(a.current),2),u=s[0],l=s[1];function c(){var t=e.player.el().querySelector(".vjs-control-bar"),n=null==t?void 0:t.offsetHeight;isNaN(n)||o(n+15)}function f(){var t=e.player.duration()-e.player.currentTime();l(t),t>a.current&&(a.current=t)}if(r.useEffect((function(){return c(),e.player.on("resize",c),e.player.on("fullscreenchange",c),e.player.on("timeupdate",f),function(){e.player.off("resize",c),e.player.off("fullscreenchange",c),e.player.off("timeupdate",f)}}),[]),!e.nextVideo||!e.onPlayNext)return r.createElement(r.Fragment,null);var h=(a.current-u)/a.current*100,d=Math.ceil(u),p=1===d?"second":"seconds";return r.createElement("div",{className:"cv-up-next-container rounded",style:{bottom:"".concat(i,"px")}},r.createElement("div",{className:"cv-up-next-progress-bar rounded",style:{width:"".concat(h,"%")}}),r.createElement("div",{className:"row no-gutters"},r.createElement("div",{className:"col-6"},r.createElement("div",{className:"cv-up-next-thumbnail-container",onClick:e.onPlayNext},r.createElement("div",{className:"cv-up-next-thumbnail-mask"},r.createElement("div",{className:"position-relative w-100 h-100"},r.createElement("div",{className:"cv-up-next-play-icon-container"},r.createElement("div",{className:"position-relative w-100 h-100"},r.createElement("span",{className:"cv-up-next-play-icon"}))))),r.createElement("img",{className:"img-fluid",src:null===(t=e.nextVideo)||void 0===t?void 0:t.thumbnailUrl}))),r.createElement("div",{className:"col-5 pl-2 pt-2"},r.createElement("p",null,"Up next in ",d," ",p),r.createElement("p",null,e.nextVideo.name)),r.createElement("div",{className:"col-1 pr-1"},r.createElement("div",{className:"close cv-cancel-up-next cursor-pointer",role:"button",onClick:e.onCancel},"×"))))}function eT(e){return(eT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function tT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nT(e,t){return(nT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=aT(e);if(t){var i=aT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return iT(this,n)}}function iT(e,t){return!t||"object"!==eT(t)&&"function"!=typeof t?oT(e):t}function oT(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function aT(e){return(aT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerComponent("UpNext",F_((function(e,t){return r.createElement(Zw,Object.assign({player:e},t))})));var sT=Fu.getPlugin("plugin"),uT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nT(e,t)}(o,e);var t,n,r,i=rT(o);function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=i.call(this,e)).setShouldPlayNext=t.setShouldPlayNext.bind(oT(t)),t.getShouldPlayNext=t.getShouldPlayNext.bind(oT(t)),t.setChapterTrack=t.setChapterTrack.bind(oT(t)),t.onTimeUpdate=t.onTimeUpdate.bind(oT(t)),e.ready((function(){t.initialize()})),t}return t=o,(n=[{key:"initialize",value:function(){this.player.isDisposed()||(this.hasLocalStorage=this.testHasLocalStorage(),Ad(this.player,"chapters",null,this.setChapterTrack),this.bindListeners())}},{key:"setNextVideo",value:function(e,t){var n;this.player.isDisposed()||(this.nextVideo=e,this.callback=t,(null===(n=this.player.getChild("collapserator"))||void 0===n?void 0:n.getChild("cogButton")).showPlayNext())}},{key:"getShouldPlayNext",value:function(){if(!this.hasLocalStorage)return void 0===this.shouldPlayNextVideo&&(this.shouldPlayNextVideo=!0),this.shouldPlayNextVideo;var e=window.localStorage.getItem("cv-play-next-video");return null===e||"true"===e}},{key:"setShouldPlayNext",value:function(e){this.hasLocalStorage?window.localStorage.setItem("cv-play-next-video",e.toString()):this.shouldPlayNextVideo=e}},{key:"setChapterTrack",value:function(e){this.chapterTrack=e}},{key:"bindListeners",value:function(){this.player.on("timeupdate",this.onTimeUpdate)}},{key:"unbindListeners",value:function(){this.player.off("timeupdate",this.onTimeUpdate)}},{key:"onTimeUpdate",value:function(){var e,t,n,r;if(!this.player.pictureInPicture||!this.player.isInPictureInPicture())if(this.getShouldPlayNext()){if(this.player.ended())return this.callback(),void this.hideUpNext();this.upNextRendered&&this.player.currentTime()>this.upNextTimepoint||("credits"===(null===(r=null===(n=(null===(t=null===(e=this.chapterTrack)||void 0===e?void 0:e.activeCues)||void 0===t?void 0:t.length)&&this.chapterTrack.activeCues[0])||void 0===n?void 0:n.text)||void 0===r?void 0:r.toLowerCase())||this.player.currentTime()>=this.player.duration()-5?this.showUpNext():this.hideUpNext())}else this.hideUpNext()}},{key:"showUpNext",value:function(){var e=this;this.upNextRendered||(this.upNextRendered=!0,this.upNextTimepoint=this.player.currentTime(),this.player.addChild("UpNext",{nextVideo:this.nextVideo,onPlayNext:this.callback,onCancel:function(){e.hideUpNext(),e.setShouldPlayNext(!1)}}))}},{key:"hideUpNext",value:function(){if(this.upNextRendered){this.upNextRendered=!1,this.upNextTimepoint=null;var e=this.player.getChild("UpNext");e&&this.player.removeChild(e)}}},{key:"testHasLocalStorage",value:function(){try{return window.localStorage.setItem("cv-persisttest","persistVolume"),window.localStorage.removeItem("cv-persisttest"),!0}catch(e){return!1}}}])&&tT(t.prototype,n),r&&tT(t,r),o}(sT);Fu.registerPlugin("nextVideoPlugin",uT);n(421);function lT(e){return(lT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function cT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hT(e,t,n){return(hT="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=mT(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function dT(e,t){return(dT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function pT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=mT(e);if(t){var i=mT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yT(this,n)}}function yT(e,t){return!t||"object"!==lT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function mT(e){return(mT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var gT=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&dT(e,t)}(o,e);var t,n,r,i=pT(o);function o(){var e;return cT(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-create-clip-button"}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){hT(mT(o.prototype),"handleClick",this).call(this,null)}}])&&fT(t.prototype,n),r&&fT(t,r),o}(Fu.getComponent("Button"));function vT(e){return(vT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function bT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _T(e,t){return(_T=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function wT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ST(e);if(t){var i=ST(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return TT(this,n)}}function TT(e,t){return!t||"object"!==vT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ST(e){return(ST=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}gT.prototype.controlText_="Create Clip",Fu.registerComponent("CreateClipButton",gT);var ET=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&_T(e,t)}(o,e);var t,n,r,i=wT(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){var e,t=this.player.getChild("collapserator"),n=null===(e=null==t?void 0:t.children())||void 0===e?void 0:e.findIndex((function(e){return"CustomControlSpacer"===e.name()}));n&&-1!==n&&t.addChild("CreateClipButton",{clickHandler:this.options.onClick},n+1)}}])&&bT(t.prototype,n),r&&bT(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("createClipButtonPlugin",ET);var CT,kT=n(4),xT=function(e,t){if(e){var n=e;return e.endsWith("/")||(n+="/"),t?n+=t.startsWith("/")?t.slice(1):t:n}},OT=n(204),PT=n(41),RT=n(12);function AT(e){return(AT="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function IT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function LT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function jT(e,t){return(jT=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function DT(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=MT(e);if(t){var i=MT(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return NT(this,n)}}function NT(e,t){return!t||"object"!==AT(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function MT(e){return(MT=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}!function(e){e.Analytics="AnalyticsService",e.Context="ContextService"}(CT||(CT={}));var UT,BT=new(function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&jT(e,t)}(o,e);var t,n,r,i=DT(o);function o(){var e;return IT(this,o),(e=i.apply(this,arguments)).contextHistory=[],e}return t=o,r=[{key:"Instance",get:function(){return this.instance||(this.instance=new this)}}],(n=[{key:"name",get:function(){return CT.Context}},{key:"initialize",value:function(){this.listenTo(RT.a.SHELL,OT.EventNames.ROUTE,this.setContext)}},{key:"setContext",value:function(e){this.contextHistory.length>=5&&this.contextHistory.unshift(),this.contextHistory.push({pageLoad:!this.contextHistory.length,appLink:e})}},{key:"getCurrentContext",value:function(){if(this.contextHistory.length)return this.contextHistory[this.contextHistory.length-1]}},{key:"fromPageLoad",value:function(){return 1===this.contextHistory.length}}])&<(t.prototype,n),r&<(t,r),o}(OT.Service)),FT=n(10);!function(e){e.Inlet="event:inlet",e.Outlet="event:outlet"}(UT||(UT={}));var VT="global:analytics";function HT(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var zT=cb.EventVersion.V1,qT=function(){function e(t,n,r,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.type=t,this.data=n,this.actionContext=r,this.eventVersion=i||zT}var t,n,r;return t=e,(n=[{key:"isType",value:function(e){return e===this.type}},{key:"enrich",value:function(e,t){this.validateKey(e),this[e]=t}},{key:"get",value:function(e){if(e&&this[e])return this[e]}},{key:"validateKey",value:function(e){"type"!==e&&"data"!==e||OT.ErrorHelper.throw(new PT.a("".concat(e," is not a valid key"))),this[e]&&OT.ErrorHelper.throw(new PT.a("Event already contains an enrichment named ".concat(e)))}}])&&HT(t.prototype,n),r&&HT(t,r),e}(),WT=function(e,t,n,r){FT.Radio.channel(VT).trigger(UT.Inlet,new qT(e,t,n,r))};function $T(){var e=BT.getCurrentContext().appLink;return kT.isObject(e)||OT.ErrorHelper.throw(new PT.a("Applink does not exist. Check current context.")),e.application.replace(":","-")}function GT(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.location,n=e.entity,r=e.workflowPhase,i=void 0===r?null:r,o=e.descriptor,a=void 0===o?null:o;return t||OT.ErrorHelper.throw(new PT.a("location must be set.")),n||OT.ErrorHelper.throw(new PT.a("entity must be set.")),{productArea:$T(),location:t,entity:n,descriptor:a,workflowPhase:i}}function YT(){return OT.LocationUtils.GetCurrentPath()+OT.LocationUtils.GetCurrentQueryString()}var KT={logUserAction:function(e,t){if(function(e){return!(!kT.isArray(e)||!kT.every(e,(function(e){return kT.isObject(e)})))||!!kT.isObject(e)}(e)&&kT.isObject(t)){var n=KT.buildUserActionEvent(t),r=n.userAction,i=n.action,o=n.eventVersion;WT(r,e,i,o)}},logNavigate:function(e,t){var n=Object.assign({currentLocation:YT(),appLink:e},t);WT(cb.UserAction.Navigate,n)},mergeOptions:function(e,t){return kT.extend({},e,t)},buildActionContext:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return GT(e)},buildUserActionEvent:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.actionType,n=e.eventVersion,r=t,i=GT(e);return{userAction:r,action:i,eventVersion:n}},buildCurrentLocation:function(){return YT()},buildSearchEvent:function(e,t){return{data:{query:e},action:GT({entity:cb.EntityType.Video,location:cb.LocationContext.SearchBar,descriptor:t})}},buildInstantSearchEvent:function(e,t,n){var r;n===cb.SearchQueryType.Series&&(r=cb.EntityType.Series),n===cb.SearchQueryType.Folder&&(r=cb.EntityType.Folder),n===cb.SearchQueryType.Tags&&(r=cb.EntityType.Tag),n===cb.SearchQueryType.Video&&(r=cb.EntityType.Video),n===cb.SearchQueryType.Subjects&&(r=cb.EntityType.Classification);var i={instant:{},query:e};return t.id&&(i.instant.selectedId=t.id),t.name&&(i.instant.selectedName=t.name),{data:i,action:GT({entity:r,location:cb.LocationContext.SearchBar})}},mapInteractionType:function(e){switch(e){case cb.InteractionType.DragDrop:return cb.InteractionTypeDescriptor.DragDrop;case cb.InteractionType.FileSelect:return cb.InteractionTypeDescriptor.FileSelect;default:return}}};function XT(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return QT(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return QT(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function QT(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var JT={isEmpty:function(e){return kT.isEmpty(e)},values:function(e){return kT.values(e)},keys:function(e){return kT.keys(e)},deepClone:function(e){return(kT.isArray(e)?kT.map:kT.mapObject)(e,(function(e){return kT.isObject(e)||kT.isArray(e)?JT.deepClone(e):e}))},getEnumKeys:function(e){return Object.keys(e).filter((function(e){return!(parseInt(e)>=0)}))},isObject:function(e){return kT.isObject(e)},isEqual:function(e,t){return kT.isEqual(e,t)},omit:function(e,t){return kT.omit(e,t)},removeEmptyKeys:function(e){return Object.entries(e).filter((function(e){return null!==XT(e,2)[1]})).reduce((function(e,t){var n=XT(t,2),r=n[0],i=n[1];return Object.assign(Object.assign({},e),function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},r,i))}),{})}};var ZT=function(e,t){if(!e)throw new Error("Invariant failed")};function eS(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tS(){return(tS=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function nS(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var rS=new Map,iS=new Map,oS=new Map,aS=0;function sS(e,t,n){void 0===n&&(n={}),n.threshold||(n.threshold=0);var r=n,i=r.root,o=r.rootMargin,a=r.threshold;if(rS.has(e)&&ZT(!1),e){var s=function(e){return e?oS.has(e)?oS.get(e):(aS+=1,oS.set(e,aS.toString()),oS.get(e)+"_"):""}(i)+(o?a.toString()+"_"+o:a.toString()),u=iS.get(s);u||(u=new IntersectionObserver(lS,n),s&&iS.set(s,u));var l={callback:t,element:e,inView:!1,observerId:s,observer:u,thresholds:u.thresholds||(Array.isArray(a)?a:[a])};return rS.set(e,l),u.observe(e),l}}function uS(e){if(e){var t=rS.get(e);if(t){var n=t.observerId,r=t.observer,i=r.root;r.unobserve(e);var o=!1,a=!1;n&&rS.forEach((function(t,r){r!==e&&(t.observerId===n&&(o=!0,a=!0),t.observer.root===i&&(a=!0))})),!a&&i&&oS.delete(i),r&&!o&&r.disconnect(),rS.delete(e)}}}function lS(e){e.forEach((function(e){var t=e.isIntersecting,n=e.intersectionRatio,r=e.target,i=rS.get(r);if(i&&n>=0){var o=i.thresholds.some((function(e){return i.inView?n>e:n>=e}));void 0!==t&&(o=o&&t),i.inView=o,i.callback(o,e)}}))}var cS=function(e){var t,n;function i(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return eS(nS(t=e.call.apply(e,[this].concat(r))||this),"state",{inView:!1,entry:void 0}),eS(nS(t),"node",null),eS(nS(t),"handleNode",(function(e){t.node&&uS(t.node),t.node=e||null,t.observeNode()})),eS(nS(t),"handleChange",(function(e,n){(e!==t.state.inView||e)&&t.setState({inView:e,entry:n}),t.props.onChange&&t.props.onChange(e,n)})),t}n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=i.prototype;return o.componentDidMount=function(){this.node||ZT(!1)},o.componentDidUpdate=function(e,t){e.rootMargin===this.props.rootMargin&&e.root===this.props.root&&e.threshold===this.props.threshold||(uS(this.node),this.observeNode()),t.inView!==this.state.inView&&this.state.inView&&this.props.triggerOnce&&(uS(this.node),this.node=null)},o.componentWillUnmount=function(){this.node&&(uS(this.node),this.node=null)},o.observeNode=function(){if(this.node){var e=this.props,t=e.threshold,n=e.root,r=e.rootMargin;sS(this.node,this.handleChange,{threshold:t,root:n,rootMargin:r})}},o.render=function(){var e=this.state,t=e.inView,n=e.entry;if(!function(e){return"function"!=typeof e.children}(this.props))return this.props.children({inView:t,entry:n,ref:this.handleNode});var i=this.props,o=i.children,a=i.as,s=i.tag,u=(i.triggerOnce,i.threshold,i.root,i.rootMargin,i.onChange,function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(i,["children","as","tag","triggerOnce","threshold","root","rootMargin","onChange"]));return Object(r.createElement)(a||s||"div",tS({ref:this.handleNode},u),o)},i}(r.Component);eS(cS,"displayName","InView"),eS(cS,"defaultProps",{threshold:0,triggerOnce:!1});function fS(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return hS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return hS(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function hS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dS(e){var t=fS(function(e){void 0===e&&(e={});var t=Object(r.useRef)(),n=Object(r.useState)({inView:!1,entry:void 0}),i=n[0],o=n[1],a=Object(r.useCallback)((function(n){t.current&&uS(t.current),n&&sS(n,(function(t,r){o({inView:t,entry:r}),t&&e.triggerOnce&&uS(n)}),e),t.current=n}),[e.threshold,e.root,e.rootMargin,e.triggerOnce]);return Object(r.useDebugValue)(i.inView),[a,i.inView,i.entry]}({triggerOnce:!0}),2),n=t[0],i=t[1];return!0!==e&&void 0!==window.IntersectionObserver||(i=!0,n=null),{ref:n,inView:i}}var pS,yS,mS,gS,vS,bS,_S=n(144),wS=n.n(_S),TS=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},SS=r.memo((function(e){var t=e.forceLoad,n=e.extraClasses,i=void 0===n?"":n,o=TS(e,["forceLoad","extraClasses"]),a=dS(),s=a.ref,u=a.inView;if(!s)return r.createElement("img",Object.assign({className:"".concat(wS.a.image," ").concat(i),alt:""},o));var l=o.src,c=TS(o,["src"]),f=Object.assign(Object.assign({alt:""},c),u||t?{src:l}:{});return t||(f.ref=s),r.createElement("img",Object.assign({className:"".concat(wS.a.image," ").concat(i)},f))}));function ES(e){var t=e.appLink,n=e.appLinkOptions,i=e.className,o=e.style,a=e.children,s=e.tag,u=void 0===s?"a":s;if(!t)return r.createElement("span",{className:i||""},a);var l=OT.AppLinkHelper.getHref(t),c={onClick:function(r){var i;r.preventDefault(),null===(i=e.onClick)||void 0===i||i.call(e,r),e.analyticsData&&e.analyticsOptions&&KT.logUserAction(Object.assign({href:l},e.analyticsData),e.analyticsOptions),OT.AppLinkHelper.trigger(t,n)},href:l,className:i,style:o};return e.title&&(c.title=e.title),r.createElement(u,Object.assign({},c),a)}function CS(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}ES.defaultProps={appLinkOptions:{}},function(e){e.Small="small",e.Medium="medium",e.Large="large"}(pS||(pS={})),function(e){e[e.Thumbnails=0]="Thumbnails",e[e.Banners=1]="Banners",e[e.Avatars=2]="Avatars",e[e.Logos=3]="Logos",e[e.Covers=4]="Covers",e[e.Posters=5]="Posters",e[e.TallPosters=6]="TallPosters",e[e.HeroBanners=7]="HeroBanners",e[e.None=99999]="None"}(yS||(yS={})),function(e){e[e.Crop=0]="Crop",e[e.Stretched=1]="Stretched",e[e.Cover=2]="Cover"}(mS||(mS={})),function(e){e[e.None=0]="None",e[e.ImageAPIv1=1]="ImageAPIv1",e[e.FileAPIv1=2]="FileAPIv1",e[e.ImageAPIv2=3]="ImageAPIv2"}(gS||(gS={})),function(e){e.Banner="banner",e.Thumbnail="thumbnail"}(bS||(bS={}));var kS,xS,OS=(CS(vS={},yS.Banners,bS.Banner),CS(vS,yS.Thumbnails,bS.Thumbnail),vS),PS=function(e){return"/v1/category-map/".concat(e)},RS={createUrl:function(e,t){return RS._createUrl(e,t)},createBannerUrl:function(e,t,n){return e&&e.url?RS._createUrl(e.url,n):RS._createCategoryMappedUrl(t,n)},createResourceImage:function(e,t,n){return RS._createUrl(e,Object.assign({url:t},n))},Rfc3986EncodeURIComponent:function(e){return encodeURIComponent(e).replace(/[!'()*]/g,escape)},_createCategoryMappedUrl:function(e,t){var n=e.fallbackBaseUrl,r=e.fallbackCategoryName,i=e.type,o=xT(n,"".concat(PS(OS[i]))),a=Object.assign({name:RS.Rfc3986EncodeURIComponent(r)},t);return RS._createUrl(o,a)},_createUrl:function(e,t){if(e){if(JT.isEmpty(t))return e;var n=$.param(t),r=-1===e.indexOf("?")?"?":"&",i=e;return i.endsWith("/")&&(i=i.slice(0,-1)),i+"".concat(r).concat(n)}},legacyCreateThumbnailUrl:function(e,t){if(!e)return"";var n;if(e&&(n=e instanceof OT.Model?e.get("url"):"string"==typeof e?e:e.url)){var r=Object.assign({size:pS.Small,bgColor:"000"},t);return RS._createUrl(n,r)}}},AS=n(72),IS=n.n(AS);function LS(e){var t="thumbnail ".concat(IS.a.thumbnail),n="";return e.aspectRatio===kS.SixteenByNine&&(n=IS.a.sixteenByNine),e.aspectRatio===kS.NineBySixteen&&(n=IS.a.nineBySixteen),e.aspectRatio===kS.OneByOne&&(n=IS.a.oneByOne),e.aspectRatio===kS.TwoByThree&&(n=IS.a.twoByThree),n&&(t+=" ".concat(n)),e.className&&(t+=" ".concat(e.className)),t}function jS(e){var t=e.data,n=e.imageOptions,i=e.appLink,o=e.preload,a=e.analyticsOptions,s=e.analyticsData,u=e.imageClassName,l="";"string"==typeof t?l=t:JT.isObject(t)&&(l=t.url);var c=l&&n?RS.createUrl(l,n):l;return r.createElement("div",{className:LS(e),style:e.imageStyle},i?r.createElement(ES,{appLink:i,analyticsData:s,analyticsOptions:a},e.children,c&&r.createElement(SS,{src:c,forceLoad:o,extraClasses:u,onError:e.onImageLoadError||function(){}})):r.createElement(r.Fragment,null,e.children,c&&r.createElement(SS,{src:c,forceLoad:o,extraClasses:u,onError:e.onImageLoadError||function(){}})))}function DS(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return NS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return NS(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function NS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function MS(e){var t=DS(Object(r.useState)(window.matchMedia(e).matches),2),n=t[0],i=t[1];return Object(r.useEffect)((function(){var t=window.matchMedia(e);t.matches!==n&&i(t.matches);var r=function(){return i(t.matches)};return t.addListener(r),function(){return t.removeListener(r)}}),[e]),n}!function(e){e[e.SixteenByNine=0]="SixteenByNine",e[e.OneByOne=1]="OneByOne",e[e.TwoByThree=2]="TwoByThree",e[e.NineBySixteen=3]="NineBySixteen"}(kS||(kS={})),function(e){e.XS="(max-width: 575px)",e.SM="(min-width: 576px) and (max-width: 767px)",e.MD="(min-width: 768px) and (max-width: 991px)",e.LG="(min-width: 992px)",e.XL="(min-width: 1200px)",e.XXL="(min-width: 1440px)",e.SMDown="(max-width: 576px)",e.MDDown="(max-width: 768px)",e.LGDown="(max-width: 992px)",e.XLDown="(max-width: 1200px)"}(xS||(xS={}));var US=n(24),BS=n(40),FS=n(84),VS=n(137),HS=n.n(VS),zS=(n(106),n(70)),qS=n.n(zS),WS=n(239),$S=n.n(WS),GS=(n(68),!1),YS=i.a.createContext(null),KS=function(e){function t(t,n){var r;r=e.call(this,t,n)||this;var i,o=n&&!n.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?o?(i="exited",r.appearStatus="entering"):i="entered":i=t.unmountOnExit||t.mountOnEnter?"unmounted":"exited",r.state={status:i},r.nextCallback=null,r}Object(FS.a)(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&"unmounted"===t.status?{status:"exited"}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?"entering"!==n&&"entered"!==n&&(t="entering"):"entering"!==n&&"entered"!==n||(t="exiting")}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},n.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=x_.a.findDOMNode(this);"entering"===t?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&"exited"===this.state.status&&this.setState({status:"unmounted"})},n.performEnter=function(e,t){var n=this,r=this.props.enter,i=this.context?this.context.isMounting:t,o=this.getTimeouts(),a=i?o.appear:o.enter;!t&&!r||GS?this.safeSetState({status:"entered"},(function(){n.props.onEntered(e)})):(this.props.onEnter(e,i),this.safeSetState({status:"entering"},(function(){n.props.onEntering(e,i),n.onTransitionEnd(e,a,(function(){n.safeSetState({status:"entered"},(function(){n.props.onEntered(e,i)}))}))})))},n.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n&&!GS?(this.props.onExit(e),this.safeSetState({status:"exiting"},(function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,(function(){t.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))}))}))):this.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))},n.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t,n){this.setNextCallback(n);var r=null==t&&!this.props.addEndListener;e&&!r?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},n.render=function(){var e=this.state.status;if("unmounted"===e)return null;var t=this.props,n=t.children,r=Object(BS.a)(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return i.a.createElement(YS.Provider,{value:null},n(e,r));var o=i.a.Children.only(n);return i.a.createElement(YS.Provider,{value:null},i.a.cloneElement(o,r))},t}(i.a.Component);function XS(){}KS.contextType=YS,KS.propTypes={},KS.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:XS,onEntering:XS,onEntered:XS,onExit:XS,onExiting:XS,onExited:XS},KS.UNMOUNTED=0,KS.EXITED=1,KS.ENTERING=2,KS.ENTERED=3,KS.EXITING=4;var QS,JS=KS,ZS=n(242),eE=n.n(ZS);var tE=((QS={}).entering="show",QS.entered="show",QS),nE=i.a.forwardRef((function(e,t){var n=e.className,o=e.children,a=Object(BS.a)(e,["className","children"]),s=Object(r.useCallback)((function(e){!function(e){e.offsetHeight}(e),a.onEnter&&a.onEnter(e)}),[a]);return i.a.createElement(JS,Object(US.a)({ref:t,addEndListener:eE.a},a,{onEnter:s}),(function(e,t){return i.a.cloneElement(o,Object(US.a)({},t,{className:qS()("fade",n,o.props.className,tE[e])}))}))}));nE.defaultProps={in:!1,timeout:300,mountOnEnter:!1,unmountOnExit:!1,appear:!1},nE.displayName="Fade";var rE=nE,iE={transition:rE,rootClose:!1,show:!1,placement:"top"};function oE(e){var t=e.children,n=e.transition,r=Object(BS.a)(e,["children","transition"]);return n=!0===n?rE:n||null,i.a.createElement($S.a,Object(US.a)({},r,{transition:n}),(function(e){var r=e.props,o=e.arrowProps,a=e.show,s=Object(BS.a)(e,["props","arrowProps","show"]);return function(e,t){var n=e.ref,r=t.ref;e.ref=n.__wrapped||(n.__wrapped=function(e){return n(Object(k_.findDOMNode)(e))}),t.ref=r.__wrapped||(r.__wrapped=function(e){return r(Object(k_.findDOMNode)(e))})}(r,o),"function"==typeof t?t(Object(US.a)({},s,{},r,{show:a,arrowProps:o})):i.a.cloneElement(t,Object(US.a)({},s,{},r,{arrowProps:o,className:qS()(t.props.className,!n&&a&&"show"),style:Object(US.a)({},t.props.style,{},r.style)}))}))}oE.defaultProps=iE;var aE=oE,sE=function(e){function t(){return e.apply(this,arguments)||this}return Object(FS.a)(t,e),t.prototype.render=function(){return this.props.children},t}(i.a.Component),uE=function(e){return e&&"object"==typeof e?e:{show:e,hide:e}},lE=function(e){function t(t,n){var r;return(r=e.call(this,t,n)||this).getTarget=function(){return x_.a.findDOMNode(r.trigger.current)},r.handleShow=function(){clearTimeout(r._timeout),r._hoverState="show";var e=uE(r.props.delay);e.show?r._timeout=setTimeout((function(){"show"===r._hoverState&&r.show()}),e.show):r.show()},r.handleHide=function(){clearTimeout(r._timeout),r._hoverState="hide";var e=uE(r.props.delay);e.hide?r._timeout=setTimeout((function(){"hide"===r._hoverState&&r.hide()}),e.hide):r.hide()},r.handleFocus=function(e){var t=r.getChildProps().onFocus;r.handleShow(e),t&&t(e)},r.handleBlur=function(e){var t=r.getChildProps().onBlur;r.handleHide(e),t&&t(e)},r.handleClick=function(e){var t=r.getChildProps().onClick;r.state.show?r.hide():r.show(),t&&t(e)},r.handleMouseOver=function(e){r.handleMouseOverOut(r.handleShow,e,"fromElement")},r.handleMouseOut=function(e){return r.handleMouseOverOut(r.handleHide,e,"toElement")},r.trigger=i.a.createRef(),r.state={show:!!t.defaultShow},r.ariaModifier={enabled:!0,order:900,fn:function(e){var t=e.instance.popper,n=r.getTarget();if(!r.state.show||!n)return e;var i=t.getAttribute("role")||"";return t.id&&"tooltip"===i.toLowerCase()&&n.setAttribute("aria-describedby",t.id),e}},r}Object(FS.a)(t,e);var n=t.prototype;return n.componentWillUnmount=function(){clearTimeout(this._timeout)},n.getChildProps=function(){return i.a.Children.only(this.props.children).props},n.handleMouseOverOut=function(e,t,n){var r=t.currentTarget,i=t.relatedTarget||t.nativeEvent[n];i&&i===r||HS()(r,i)||e(t)},n.hide=function(){this.setState({show:!1})},n.show=function(){this.setState({show:!0})},n.render=function(){var e=this.props,t=e.trigger,n=e.overlay,o=e.children,a=e.popperConfig,s=void 0===a?{}:a,u=Object(BS.a)(e,["trigger","overlay","children","popperConfig"]);delete u.delay,delete u.defaultShow;var l=i.a.Children.only(o),c={},f=null==t?[]:[].concat(t);return-1!==f.indexOf("click")&&(c.onClick=this.handleClick),-1!==f.indexOf("focus")&&(c.onFocus=this.handleShow,c.onBlur=this.handleHide),-1!==f.indexOf("hover")&&(c.onMouseOver=this.handleMouseOver,c.onMouseOut=this.handleMouseOut),i.a.createElement(i.a.Fragment,null,i.a.createElement(sE,{ref:this.trigger},Object(r.cloneElement)(l,c)),i.a.createElement(aE,Object(US.a)({},u,{popperConfig:Object(US.a)({},s,{modifiers:Object(US.a)({},s.modifiers,{ariaModifier:this.ariaModifier})}),show:this.state.show,onHide:this.handleHide,target:this.getTarget}),n))},t}(i.a.Component);lE.defaultProps={defaultOverlayShown:!1,trigger:["hover","focus"]};var cE=lE,fE=(n(458),n(243),i.a.createContext({}));fE.Consumer,fE.Provider;function hE(e,t){var n=Object(r.useContext)(fE);return e||n[t]||t}var dE=i.a.forwardRef((function(e,t){var n=e.bsPrefix,r=e.placement,o=e.className,a=e.style,s=e.children,u=e.arrowProps,l=(e.scheduleUpdate,e.outOfBoundaries,Object(BS.a)(e,["bsPrefix","placement","className","style","children","arrowProps","scheduleUpdate","outOfBoundaries"]));return n=hE(n,"tooltip"),i.a.createElement("div",Object(US.a)({ref:t,style:a,role:"tooltip","x-placement":r,className:qS()(o,n,"bs-tooltip-"+r)},l),i.a.createElement("div",Object(US.a)({className:"arrow"},u)),i.a.createElement("div",{className:n+"-inner"},s))}));dE.defaultProps={placement:"right"},dE.displayName="Tooltip";var pE,yE,mE=dE,gE=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1e4;return Math.floor(Math.random()*Math.floor(e))};function vE(e){var t=e.title,n=e.placement,i=e.trigger,o=e.spanHack,a=e.children;return o?r.createElement(cE,{placement:n,overlay:r.createElement(mE,{id:"".concat(t,"-").concat(gE())},t),trigger:i},r.createElement("span",{className:"d-flex justify-content-center align-items-center"},a)):r.createElement(cE,{placement:n,overlay:r.createElement(mE,{id:"".concat(t,"-").concat(gE())},t),trigger:i},a)}vE.defaultProps={trigger:["hover","click","focus"],placement:"top"},function(e){e.Pdf="pdf",e.Image="image",e.PowerPoint="powerpoint",e.Document="document",e.Excel="excel",e.Zip="archive",e.File="text"}(pE||(pE={})),function(e){e[e.Audience=1]="Audience",e[e.Category=2]="Category",e[e.Channel=3]="Channel",e[e.Chapter=4]="Chapter",e[e.Comment=5]="Comment",e[e.OwnerComment=6]="OwnerComment",e[e.Image=7]="Image",e[e.Thumbnail=8]="Thumbnail",e[e.Avatar=9]="Avatar",e[e.Banner=10]="Banner",e[e.Video=11]="Video",e[e.Trailer=12]="Trailer",e[e.Rating=13]="Rating",e[e.Topic=14]="Topic",e[e.Series=15]="Series",e[e.Season=16]="Season",e[e.HostedMediaObjectCollection=17]="HostedMediaObjectCollection",e[e.ExchangeCollection=18]="ExchangeCollection",e[e.CustomMediaObjectCollection=19]="CustomMediaObjectCollection",e[e.Playlist=20]="Playlist",e[e.ClickViewTvCollection=21]="ClickViewTvCollection",e[e.ClickViewProductionsCollection=22]="ClickViewProductionsCollection",e[e.User=23]="User",e[e.SystemUser=24]="SystemUser",e[e.Customer=25]="Customer",e[e.Country=26]="Country",e[e.Organisation=28]="Organisation",e[e.SystemOrganisation=29]="SystemOrganisation",e[e.Group=30]="Group",e[e.SystemGroup=31]="SystemGroup",e[e.FlagReason=32]="FlagReason",e[e.Library=33]="Library",e[e.Interactive=34]="Interactive",e[e.WorkspaceCollection=35]="WorkspaceCollection",e[e.Conversation=36]="Conversation",e[e.Message=37]="Message",e[e.Notification=38]="Notification",e[e.Clip=39]="Clip",e[e.Link=40]="Link",e[e.UserChannel=41]="UserChannel",e[e.Resource=42]="Resource",e[e.VideoStream=43]="VideoStream",e[e.AudioStream=44]="AudioStream",e[e.Tag=45]="Tag",e[e.Subtitle=46]="Subtitle",e[e.LicencedContentCollection=47]="LicencedContentCollection",e[e.PublicCollection=48]="PublicCollection",e[e.CategoryTree=49]="CategoryTree",e[e.Logo=50]="Logo",e[e.Permission=51]="Permission",e[e.Subject=52]="Subject",e[e.Field=53]="Field",e[e.Company=54]="Company",e[e.Person=55]="Person",e[e.Cover=56]="Cover",e[e.Poster=57]="Poster",e[e.SubjectAudience=58]="SubjectAudience",e[e.Classroom=67]="Classroom",e[e.ClassroomGroup=68]="ClassroomGroup"}(yE||(yE={}));var bE=n(44),_E=n.n(bE),wE=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},TE={width:1920,height:1080,format:"jpg"};function SE(e,t){var n,r=xT(e,"/v1/previews");return"metadata"in t?t.metadata.type===pE.Pdf?RS.createResourceImage(r,t.url,TE):t.metadata.type===pE.Image?RS.createUrl(t.url,{size:pS.Medium,resizeType:mS.Cover}):(null===(n=t.pdf)||void 0===n?void 0:n.url)?RS.createResourceImage(r,t.pdf.url,TE):t.metadata.type===pE.Zip?RS.createUrl(xT(e,"/v2/thumbnails/BKnxEm"),{size:pS.Large,format:"png"}):RS.createUrl("".concat(e,"v2/thumbnails/BKnxEm"),{size:pS.Large,format:"png"}):RS.createResourceImage(r,t.url,Object.assign(Object.assign({},TE),{resizeType:mS.Cover}))}function EE(e){var t,n,r,o=null,a=0;"metadata"in e.data&&(o=e.data.metadata,a=null!==(r=null===(n=null===(t=e.data.thumbnail)||void 0===t?void 0:t.metadata)||void 0===n?void 0:n.rotation)&&void 0!==r?r:0);var s="pt-3 px-3 rounded-lg d-flex flex-column align-items-center"+" justify-content-end ".concat(function(e){switch(e){case"atom-guide":return _E.a.atomGuide;case"student-activity":return _E.a.studentActivity;case"teacher-pack":return _E.a.teacherPack;case"additional-materials":return _E.a.additionalMaterials;default:return _E.a.userUploaded}}(null==o?void 0:o.resourceType)," ").concat(_E.a.background);return i.a.createElement("div",{className:s},i.a.createElement(vE,{title:e.data.name},i.a.createElement("h3",{className:"text-center clamp-1 text-break h5 mb-3 ".concat(_E.a.text)},e.data.name)),i.a.createElement("div",{className:"w-75 overflow-hidden ".concat(_E.a.thumbnailContainer)},i.a.createElement(jS,{data:SE(e.imageCdnUrl,e.data),aspectRatio:kS.SixteenByNine,imageStyle:{transform:"rotate(".concat(a,"deg)")},analyticsOptions:{location:cb.LocationContext.SlidingListItem},onImageLoadError:function(t){t.target.src=e.imageErrorFallbackUrl},preload:!0})))}i.a.memo((function(e){var t,n,r,o,a,s,u,l=e.appLink,c=wE(e,["appLink"]),f=(t=MS(xS.XS),n=MS(xS.SM),r=MS(xS.MD),o=MS(xS.LG),a=MS(xS.XL),s=MS(xS.XXL),u=xS.LG,t&&(u=xS.XS),n&&(u=xS.SM),r&&(u=xS.MD),o&&(u=xS.LG),a&&(u=xS.XL),s&&(u=xS.XXL),u),h=f===xS.SM||f===xS.XS,d=null;"metadata"in e.data&&(d=e.data.metadata.type);var p=Object.assign(Object.assign({},e.analyticsData),e.data),y=Object.assign(Object.assign({},e.analyticsOptions),{actionType:cb.UserAction.Click,entity:e.data.typeId===yE.Resource?cb.EntityType.Resource:cb.EntityType.Link});function m(){KT.logUserAction(p,y)}return i.a.createElement("div",{className:"pt-1 px-1 flex-shrink-0 ".concat(_E.a.item)},function(){if(!d)return i.a.createElement("a",{href:e.data.url,target:"_blank",className:"d-block",onClick:m},i.a.createElement(EE,Object.assign({},c)));var t=!!e.data.pdf||d===pE.Pdf||d===pE.Image;return h||!t||d===pE.Zip?i.a.createElement("a",{href:e.data.url,className:"d-block",onClick:m},i.a.createElement(EE,Object.assign({},c))):i.a.createElement(ES,{appLink:Object.assign(Object.assign({},l),{args:[e.data.id]}),className:"d-block no-decoration",analyticsData:p,analyticsOptions:y},i.a.createElement(EE,Object.assign({},c)))}())})),n(459);function CE(e){return(CE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function kE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function xE(e,t){return(xE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function OE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=RE(e);if(t){var i=RE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return PE(this,n)}}function PE(e,t){return!t||"object"!==CE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function RE(e){return(RE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function AE(e){return i.a.createElement("div",{className:"cv-resource-item"},i.a.createElement(EE,{data:e.resource,imageCdnUrl:e.imageCdnUrl}))}var IE=F_((function(e,t){return i.a.createElement(AE,Object.assign({},t))})),LE=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&xE(e,t)}(o,e);var t,n,r,i=OE(o);function o(e,t){var n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n=i.call(this,e,t);var r=new IE(e,{resource:t.resource,imageCdnUrl:t.imageCdnUrl});return n.addChild(r),n}return t=o,(n=[{key:"createEl",value:function(){return Fu.dom.createEl("div")}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.options_.downloadResource(this.options_.resource)}}])&&kE(t.prototype,n),r&&kE(t,r),o}(Fu.getComponent("ClickableComponent"));n(460);function jE(e){return(jE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function DE(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function NE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ME(e,t,n){return(ME="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=VE(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function UE(e,t){return(UE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function BE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=VE(e);if(t){var i=VE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return FE(this,n)}}function FE(e,t){return!t||"object"!==jE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function VE(e){return(VE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var HE=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&UE(e,t)}(o,e);var t,n,r,i=BE(o);function o(){var e;return DE(this,o),(e=i.apply(this,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return t=o,(n=[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(ME(VE(o.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"buildCSSClass",value:function(){return"cv-resources-button ".concat(ME(VE(o.prototype),"buildCSSClass",this).call(this))}},{key:"update",value:function(){ME(VE(o.prototype),"update",this).call(this),Pd.initMenuScrollbar(this)}},{key:"createMenu",value:function(){return this.options_.title="Resources",ME(VE(o.prototype),"createMenu",this).call(this)}},{key:"createItems",value:function(){var e=this,t=[];return this.options_.resources.forEach((function(n){var r=new LE(e.player(),{resource:n,imageCdnUrl:e.options_.imageCdnUrl,downloadResource:function(t){return e.downloadResource(t)}});t.push(r)})),t}},{key:"downloadResource",value:function(e){this.getDownloadIframe().src=e.url}},{key:"getDownloadIframe",value:function(){return this.downloadIframe||(this.downloadIframe=Fu.dom.createEl("iframe"),this.downloadIframe.style.display="none",Fu.dom.appendContent(Fu.dom.$("body"),this.downloadIframe)),this.downloadIframe}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){ME(VE(o.prototype),"handleClick",this).call(this,null)}}])&&NE(t.prototype,n),r&&NE(t,r),o}(Fu.getComponent("MenuButton"));function zE(e){return(zE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function qE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function WE(e,t){return(WE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function $E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=YE(e);if(t){var i=YE(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return GE(this,n)}}function GE(e,t){return!t||"object"!==zE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function YE(e){return(YE=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}HE.prototype.controlText_="Resources",Fu.registerComponent("ResourcesButton",HE);var KE=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&WE(e,t)}(o,e);var t,n,r,i=$E(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,e.ready((function(){return n.onReady()})),n}return t=o,(n=[{key:"onReady",value:function(){if(this.options.resources.length){var e=this.player.getChild("collapserator");e.addChild("ResourcesButton",{resources:this.options.resources,imageCdnUrl:this.options.imageCdnUrl},e.children_.length-3)}}}])&&qE(t.prototype,n),r&&qE(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("resourcesPlugin",KE);n(461);function XE(e){return(XE="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function QE(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function JE(e,t){return(JE=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ZE(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=tC(e);if(t){var i=tC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return eC(this,n)}}function eC(e,t){return!t||"object"!==XE(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function tC(e){return(tC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var nC=Fu.getComponent("PlayToggle"),rC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&JE(e,t)}(o,e);var t,n,r,i=ZE(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).pictureInPictureEnabled=!0,n.options=t,n.bindFunctions(),n.player.ready((function(){n.initialize()})),n}return t=o,(n=[{key:"initialize",value:function(){var e=this;this.enablePictureInPicture(),this.player.on("dispose",(function(){e.dispose()}))}},{key:"bindFunctions",value:function(){this.requestPictureInPicture=this.requestPictureInPicture.bind(this),this.exitPictureInPicture=this.exitPictureInPicture.bind(this),this.playerRequestPictureInPictureFn=this.player.requestPictureInPicture,this.playerExitPictureInPictureFn=this.player.exitPictureInPicture,this.player.requestPictureInPicture=this.requestPictureInPicture,this.player.exitPictureInPicture=this.exitPictureInPicture}},{key:"enablePictureInPicture",value:function(){if(this.player.options_.fluid){this.pictureInPictureEnabled=!0;var e=this.getToggleParentComponent();null==e||e.addChild("pictureInPictureToggle",{},e.children().length-1)}}},{key:"disablePictureInPicture",value:function(){this.pictureInPictureEnabled=!1;var e=this.getToggleParentComponent(),t=null==e?void 0:e.getChild("pictureInPictureToggle");t&&e.removeChild(t)}},{key:"togglePictureInPicture",value:function(e){if(e!==this.player.isInPictureInPicture()){var t=e?"enterpictureinpicture":"leavepictureinpicture";this.player.isInPictureInPicture(e),this.player.trigger(t),e?this.addPipStyles():this.removePipStyles()}}},{key:"addPipStyles",value:function(){this.player.addClass("cv-picture-in-picture"),this.playToggle=new nC(this.player),this.playToggle.addClass("cv-pip-play-toggle"),this.player.addChild(this.playToggle),this.player.paused()?this.playToggle.handlePause():this.playToggle.handlePlay()}},{key:"removePipStyles",value:function(){this.player.removeClass("cv-picture-in-picture"),this.player.removeChild(this.playToggle),delete this.playToggle}},{key:"requestPictureInPicture",value:function(){this.pictureInPictureEnabled&&(this.togglePictureInPicture(!0),this.options.onRequestPictureInPicture(!0))}},{key:"exitPictureInPicture",value:function(){this.togglePictureInPicture(!1),this.options.onRequestPictureInPicture(!1),this.removePipStyles()}},{key:"getToggleParentComponent",value:function(){return this.player.getChild("collapserator")}},{key:"dispose",value:function(){this.player.requestPictureInPicture=this.playerRequestPictureInPictureFn,this.player.exitPictureInPicture=this.playerExitPictureInPictureFn}}])&&QE(t.prototype,n),r&&QE(t,r),o}(Fu.getPlugin("plugin"));Fu.registerPlugin("pictureInPicture",rC);n(462);function iC(e){return(iC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function oC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function aC(e,t){return(aC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function sC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=lC(e);if(t){var i=lC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return uC(this,n)}}function uC(e,t){return!t||"object"!==iC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function lC(e){return(lC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var cC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&aC(e,t)}(o,e);var t,n,r,i=sC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).update(),n}return t=o,(n=[{key:"update",value:function(){this.options_.isFavourited?this.addClass("cv-favourited"):this.removeClass("cv-favourited")}},{key:"handleClick",value:function(){if(this.options_.isFavourited=!this.options_.isFavourited,this.update(),this.options_.clickHandler){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.options_.clickHandler.call(this,t)}}},{key:"buildCSSClass",value:function(){return"cv-favourite-button"}}])&&oC(t.prototype,n),r&&oC(t,r),o}(Fu.getComponent("Button"));function fC(e){return(fC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function hC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pC(e,t){return(pC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function yC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=gC(e);if(t){var i=gC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return mC(this,n)}}function mC(e,t){return!t||"object"!==fC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function gC(e){return(gC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}cC.prototype.controlText_="Favourite";var vC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&pC(e,t)}(o,e);var t,n,r,i=yC(o);function o(){return hC(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"setFavourite",value:function(e,t){e!==this.isFavourite&&(this.isFavourite=e,this.onClickFavourite=t,this.renderFavouriteButton())}},{key:"renderFavouriteButton",value:function(){this.player.isDisposed()||(this.button&&this.player.removeChild(this.button),this.button=new cC(this.player,{isFavourited:this.isFavourite,clickHandler:this.onClickFavourite}),this.player.addChild(this.button))}}])&&dC(t.prototype,n),r&&dC(t,r),o}(Fu.getPlugin("plugin"));function bC(e){return(bC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _C(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wC(e,t,n){return(wC="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=CC(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function TC(e,t){return(TC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function SC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=CC(e);if(t){var i=CC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return EC(this,n)}}function EC(e,t){return!t||"object"!==bC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function CC(e){return(CC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("favouritePlugin",vC);var kC=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},xC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&TC(e,t)}(o,e);var t,n,r,i=SC(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,t)}return t=o,(n=[{key:"configurePlugins",value:function(){try{var e=this.player;e.persistVolumePlugin(),e.fullscreenOnRotatePlugin(),e.touchControls(),this.options.getExternalLink&&e.openExternallyPlugin({getExternalLink:this.options.getExternalLink}),this.options.onClickCreateClip&&e.createClipButtonPlugin({onClick:this.options.onClickCreateClip}),this.options.onRequestPictureInPicture&&e.pictureInPicture({onRequestPictureInPicture:this.options.onRequestPictureInPicture})}catch(e){console.log("failed to register plugins",e)}}},{key:"setFavourite",value:function(e,t){this.player.favouritePlugin().setFavourite(e,t)}},{key:"setNextVideo",value:function(e,t){this.player.nextVideoPlugin().setNextVideo(e,t)}},{key:"enablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.enablePictureInPicture()}},{key:"disablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.disablePictureInPicture()}},{key:"togglePictureInPicture",value:function(e){var t=this.player.pictureInPicture();t&&t.togglePictureInPicture(e)}},{key:"additionalSetup",value:function(e){var t=this,n=Object.create(null,{additionalSetup:{get:function(){return wC(CC(o.prototype),"additionalSetup",t)}}});return kC(this,void 0,void 0,regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n.additionalSetup.call(this,e),"MasterClip"!==e.mediaType){t.next=6;break}if(null!==(r=e.additionalData)){t.next=5;break}throw Error("Invalid clip data");case 5:this.player.clipPlugin({startTime:r.startTime,endTime:r.endTime});case 6:case"end":return t.stop()}}),t,this)})))}}])&&_C(t.prototype,n),r&&_C(t,r),o}(g_),OC=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};function PC(e){var t=e.className,n=void 0===t?"":t,r=e.playerApi,o=e.onReady,a=e.onDispose,s=OC(e,["className","playerApi","onReady","onDispose"]),u=i.a.useRef(),l=i.a.useRef();return i.a.useEffect((function(){var e;if(null===(e=l.current)||void 0===e||e.dispose(),u)return l.current=new xC(u.current,Object.assign(Object.assign({},s),{playerApi:r})),o&&l.current.ready((function(){o(l.current)})),a&&l.current.one("dispose",a),function(){var e;null===(e=l.current)||void 0===e||e.dispose()}}),[e.viewKey]),i.a.createElement("div",{ref:u,className:n})}function RC(e){return(RC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function AC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function IC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function LC(e,t,n){return(LC="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=MC(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function jC(e,t){return(jC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function DC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=MC(e);if(t){var i=MC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return NC(this,n)}}function NC(e,t){return!t||"object"!==RC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function MC(e){return(MC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var UC=Fu.getComponent("Component"),BC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&jC(e,t)}(o,e);var t,n,r,i=DC(o);function o(){return AC(this,o),i.apply(this,arguments)}return t=o,(n=[{key:"buildCSSClass",value:function(){return"cv-clip-timepoint-handle ".concat(LC(MC(o.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,t,n){return LC(MC(o.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},t),{className:this.buildCSSClass(),innerHTML:'<svg viewBox="0 0 5 14"><g id="Clips" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"><g id="Clip-2" transform="translate(-835.000000, -632.000000)" fill="#FFFFFF"><g id="Video-Copy" transform="translate(275.000000, 96.000000)"><g id="Handles" transform="translate(560.000000, 536.000000)"><circle id="Oval" cx="1" cy="1" r="1"></circle><circle id="Oval-Copy-2" cx="1" cy="5" r="1"></circle><circle id="Oval-Copy-4" cx="1" cy="9" r="1"></circle><circle id="Oval-Copy-8" cx="1" cy="13" r="1"></circle><circle id="Oval-Copy" cx="4" cy="1" r="1"></circle><circle id="Oval-Copy-3" cx="4" cy="5" r="1"></circle><circle id="Oval-Copy-5" cx="4" cy="9" r="1"></circle><circle id="Oval-Copy-9" cx="4" cy="13" r="1"></circle></g></g></g></g></svg>'}),n)}},{key:"isEventTarget",value:function(e){return this.el().contains(e.target)}}])&&IC(t.prototype,n),r&&IC(t,r),o}(UC);n(463);function FC(e){return(FC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function VC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function HC(e,t,n){return(HC="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=$C(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(n):i.value}})(e,t,n||e)}function zC(e,t){return(zC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function qC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=$C(e);if(t){var i=$C(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return WC(this,n)}}function WC(e,t){return!t||"object"!==FC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function $C(e){return($C=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var GC=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zC(e,t)}(o,e);var t,n,r,i=qC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).dragStartActive=!1,n.dragEndActive=!1,n.dragSliderActive=!1,n.dragSliderCurrentPosition=null,n.minDuration=Math.min(e.duration(),n.options_.minDuration),n.setStartTime(t.startTime,!1),n.setEndTime(t.endTime,!1),n.startHandle=new BC(n.player(),t),n.startHandle.addClass("cv-clip-start-handle"),n.addChild(n.startHandle),n.endHandle=new BC(n.player(),t),n.endHandle.addClass("cv-clip-end-handle"),n.addChild(n.endHandle),n.on(n.player(),"update:clip:start:time",(function(e){var t=e.time;return n.setStartTime(t)})),n.on(n.player(),"update:clip:end:time",(function(e){var t=e.time;return n.setEndTime(t)})),n.bindListeners(),n.update(),n}return t=o,(n=[{key:"createEl",value:function(){return HC($C(o.prototype),"createEl",this).call(this,"div",{className:"cv-clip-timepoint-selector"},{})}},{key:"update",value:function(){var e=this;this.options_.onChangeStartTime(this.startTime),this.options_.onChangeEndTime(this.endTime),this.requestAnimationFrame((function(){e.setStartOffset(),e.setWidth()}))}},{key:"setStartTime",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!isNaN(e)){var n=this.endTime||this.player().duration(),r=n-this.minDuration;e>r&&(e=r),e<0&&(e=0),this.startTime=e,this.endTime&&this.endTime-this.startTime<this.minDuration&&this.setEndTime(this.startTime+this.minDuration),this.player().currentTime(this.startTime),t&&this.update()}}},{key:"setEndTime",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!isNaN(e)){var n=this.startTime||0,r=n+this.minDuration;e<r&&(e=r),e>this.player().duration()&&(e=this.player().duration()),this.endTime=e,this.startTime&&this.endTime-this.startTime<this.minDuration&&this.setStartTime(this.endTime-this.minDuration),t&&this.update()}}},{key:"bindListeners",value:function(){var e=this;this.on("mousedown",this.dragStart),this.on("touchstart",this.dragStart),this.player().on("dispose",(function(){e.off("mousedown",e.dragStart),e.off("touchstart",e.dragStart)}))}},{key:"dragStart",value:function(e){this.startHandle.isEventTarget(e)&&(e.stopImmediatePropagation(),this.dragStartActive=!0),this.endHandle.isEventTarget(e)&&(e.stopImmediatePropagation(),this.dragEndActive=!0),e.target===this.el()&&(e.stopImmediatePropagation(),this.dragSliderActive=!0,this.dragSliderCurrentPosition=this.getPosition(e));var t=this.el().ownerDocument;this.on(t,"mousemove",this.drag),this.on(t,"mouseup",this.dragEnd),this.on(t,"touchmove",this.drag),this.on(t,"touchend",this.dragEnd),this.drag(e)}},{key:"dragEnd",value:function(){this.dragStartActive=!1,this.dragEndActive=!1,this.dragSliderActive=!1,this.dragSliderCurrentPosition=null;var e=this.el().ownerDocument;this.off(e,"mousemove",this.drag),this.off(e,"mouseup",this.dragEnd),this.off(e,"touchmove",this.drag),this.off(e,"touchend",this.dragEnd)}},{key:"drag",value:function(e){if((this.dragStartActive||this.dragEndActive||this.dragSliderActive)&&Fu.dom.isSingleLeftClick(e)){var t=this.getPosition(e),n=t*this.player().duration();this.dragStartActive&&this.handleStartHandleDrag(n),this.dragEndActive&&this.handleEndHandleDrag(n),this.dragSliderActive&&this.handleSliderDrag(t)}}},{key:"handleStartHandleDrag",value:function(e){this.setStartTime(e)}},{key:"handleEndHandleDrag",value:function(e){this.setEndTime(e)}},{key:"handleSliderDrag",value:function(e){var t=(e-this.dragSliderCurrentPosition)*this.player().duration(),n=this.startTime+t,r=this.endTime+t;n<=0||r>=this.player().duration()||(this.dragSliderCurrentPosition=e,this.setStartTime(n),this.setEndTime(r))}},{key:"getPosition",value:function(e){return Fu.dom.getPointerPosition(this.el_.parentNode,e).x}},{key:"setStartOffset",value:function(){this.el_.style.marginLeft="".concat(this.getPercentage(this.startTime),"%")}},{key:"setWidth",value:function(){this.el_.style.width="".concat(this.getPercentage(this.endTime-this.startTime),"%")}},{key:"getPercentage",value:function(e){return+(e/this.player().duration()*100).toFixed(4)}}])&&VC(t.prototype,n),r&&VC(t,r),o}(Fu.getComponent("Component"));n(464);function YC(e){return(YC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function KC(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function XC(e,t){return(XC=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function QC(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ZC(e);if(t){var i=ZC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return JC(this,n)}}function JC(e,t){return!t||"object"!==YC(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function ZC(e){return(ZC=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ek=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&XC(e,t)}(o,e);var t,n,r,i=QC(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).addClass("cv-create-clip-seek-bar"),n}return t=o,(n=[{key:"initialize",value:function(e){var t=new GC(this.player(),e);this.addChild(t)}}])&&KC(t.prototype,n),r&&KC(t,r),o}(Fu.getComponent("SeekBar"));function tk(e){return(tk="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function nk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rk(e,t){return(rk=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ik(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=sk(e);if(t){var i=sk(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ok(this,n)}}function ok(e,t){return!t||"object"!==tk(t)&&"function"!=typeof t?ak(e):t}function ak(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sk(e){return(sk=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}ek.prototype.options_={children:["playProgressBar"],barName:"playProgressBar"},Fu.browser.IS_IOS||Fu.browser.IS_ANDROID||ek.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),Fu.registerComponent("CreateClipSeekBar",ek);var uk=Fu.getPlugin("plugin"),lk=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&rk(e,t)}(o,e);var t,n,r,i=ik(o);function o(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this,e,t)).options=t,n.initCreateClipSeekBar=n.initCreateClipSeekBar.bind(ak(n)),n.player.one("loadedmetadata",(function(){return n.player.ready(n.initCreateClipSeekBar)})),n}return t=o,(n=[{key:"initCreateClipSeekBar",value:function(){var e,t=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar");if(t){var n=!isNaN(this.options.startTime)&&this.options.startTime>=0?this.options.startTime:0,r=!isNaN(this.options.endTime)&&this.options.endTime<=this.player.duration()?this.options.endTime:this.player.duration(),i=Math.min(this.options.minDuration||5,this.player.duration());t.initialize({startTime:n,endTime:r,minDuration:i,onChangeStartTime:this.options.onChangeStartTime,onChangeEndTime:this.options.onChangeEndTime})}}},{key:"dispose",value:function(){this.player.off("loadedmetadata",this.initCreateClipSeekBar)}}])&&nk(t.prototype,n),r&&nk(t,r),o}(uk);function ck(e){return(ck="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function fk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function hk(e,t){return(hk=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function dk(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=yk(e);if(t){var i=yk(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pk(this,n)}}function pk(e,t){return!t||"object"!==ck(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function yk(e){return(yk=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Fu.registerPlugin("createClipPlugin",lk);var mk=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&hk(e,t)}(o,e);var t,n,r,i=dk(o);function o(e,t){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),i.call(this,e,Object.assign(Object.assign({},t),{playbackRates:null,enableLocalCache:!1}))}return t=o,(n=[{key:"getPlayerClassName",value:function(){return"cv-create-clip-player"}},{key:"configurePlugins",value:function(){var e=this.options,t=e.startTime,n=e.endTime,r=e.minDuration,i=e.onChangeStartTime,o=e.onChangeEndTime;this.player.createClipPlugin({startTime:t,endTime:n,minDuration:r,onChangeStartTime:i,onChangeEndTime:o})}},{key:"getSeekBarName",value:function(){return"CreateClipSeekBar"}},{key:"getAnalyticsPlayerType",value:function(){return"create-clip-player"}}])&&fk(t.prototype,n),r&&fk(t,r),o}(g_);function gk(e){var t=i.a.useRef(),n=i.a.useRef();return i.a.useEffect((function(){n.current=new mk(t.current,e)}),[]),i.a.useEffect((function(){var t;null===(t=n.current)||void 0===t||t.trigger({type:"update:clip:start:time",time:e.startTime})}),[e.startTime]),i.a.useEffect((function(){var t;null===(t=n.current)||void 0===t||t.trigger({type:"update:clip:end:time",time:e.endTime})}),[e.endTime]),i.a.createElement("div",{ref:t})}n.d(t,"ClickViewPlayer",(function(){return PC})),n.d(t,"ClickViewCreateClipPlayer",(function(){return gk})),n.d(t,"Player",(function(){return xC}))},function(e,t,n){"use strict";n.r(t);var r=n(240),i=n.n(r),o=n(31),a=n.n(o),s=n(7),u=n.n(s),l=n(3),c=n.n(l),f=n(21),h=n.n(f),d=n(241),p=n.n(d),y=n(1),m=n(145),g=n(146),v=n.n(g),b=v()(),_=v()(),w=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"referenceNode",void 0),h()(c()(c()(t)),"setReferenceNode",(function(e){e&&t.referenceNode!==e&&(t.referenceNode=e,t.forceUpdate())})),t}u()(t,e);var n=t.prototype;return n.componentWillUnmount=function(){this.referenceNode=null},n.render=function(){return y.createElement(b.Provider,{value:this.referenceNode},y.createElement(_.Provider,{value:this.setReferenceNode},this.props.children))},t}(y.Component),T=function(e){return Array.isArray(e)?e[0]:e},S=function(e){if("function"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,n)}},E=function(e,t){if("function"==typeof e)return S(e,t);null!=e&&(e.current=t)},C={position:"absolute",top:0,left:0,opacity:0,pointerEvents:"none"},k={},x=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"state",{data:void 0,placement:void 0}),h()(c()(c()(t)),"popperInstance",void 0),h()(c()(c()(t)),"popperNode",null),h()(c()(c()(t)),"arrowNode",null),h()(c()(c()(t)),"setPopperNode",(function(e){e&&t.popperNode!==e&&(E(t.props.innerRef,e),t.popperNode=e,t.updatePopperInstance())})),h()(c()(c()(t)),"setArrowNode",(function(e){t.arrowNode=e})),h()(c()(c()(t)),"updateStateModifier",{enabled:!0,order:900,fn:function(e){var n=e.placement;return t.setState({data:e,placement:n}),e}}),h()(c()(c()(t)),"getOptions",(function(){return{placement:t.props.placement,eventsEnabled:t.props.eventsEnabled,positionFixed:t.props.positionFixed,modifiers:a()({},t.props.modifiers,{arrow:a()({},t.props.modifiers&&t.props.modifiers.arrow,{enabled:!!t.arrowNode,element:t.arrowNode}),applyStyle:{enabled:!1},updateStateModifier:t.updateStateModifier})}})),h()(c()(c()(t)),"getPopperStyle",(function(){return t.popperNode&&t.state.data?a()({position:t.state.data.offsets.popper.position},t.state.data.styles):C})),h()(c()(c()(t)),"getPopperPlacement",(function(){return t.state.data?t.state.placement:void 0})),h()(c()(c()(t)),"getArrowStyle",(function(){return t.arrowNode&&t.state.data?t.state.data.arrowStyles:k})),h()(c()(c()(t)),"getOutOfBoundariesState",(function(){return t.state.data?t.state.data.hide:void 0})),h()(c()(c()(t)),"destroyPopperInstance",(function(){t.popperInstance&&(t.popperInstance.destroy(),t.popperInstance=null)})),h()(c()(c()(t)),"updatePopperInstance",(function(){t.destroyPopperInstance();var e=c()(c()(t)).popperNode,n=t.props.referenceElement;n&&e&&(t.popperInstance=new m.a(n,e,t.getOptions()))})),h()(c()(c()(t)),"scheduleUpdate",(function(){t.popperInstance&&t.popperInstance.scheduleUpdate()})),t}u()(t,e);var n=t.prototype;return n.componentDidUpdate=function(e,t){this.props.placement===e.placement&&this.props.referenceElement===e.referenceElement&&this.props.positionFixed===e.positionFixed&&p()(this.props.modifiers,e.modifiers,{strict:!0})?this.props.eventsEnabled!==e.eventsEnabled&&this.popperInstance&&(this.props.eventsEnabled?this.popperInstance.enableEventListeners():this.popperInstance.disableEventListeners()):this.updatePopperInstance(),t.placement!==this.state.placement&&this.scheduleUpdate()},n.componentWillUnmount=function(){E(this.props.innerRef,null),this.destroyPopperInstance()},n.render=function(){return T(this.props.children)({ref:this.setPopperNode,style:this.getPopperStyle(),placement:this.getPopperPlacement(),outOfBoundaries:this.getOutOfBoundariesState(),scheduleUpdate:this.scheduleUpdate,arrowProps:{ref:this.setArrowNode,style:this.getArrowStyle()}})},t}(y.Component);h()(x,"defaultProps",{placement:"bottom",eventsEnabled:!0,referenceElement:void 0,positionFixed:!1});var O=m.a.placements;function P(e){var t=e.referenceElement,n=i()(e,["referenceElement"]);return y.createElement(b.Consumer,null,(function(e){return y.createElement(x,a()({referenceElement:void 0!==t?t:e},n))}))}var R=n(106),A=n.n(R),I=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,h()(c()(c()(t)),"refHandler",(function(e){E(t.props.innerRef,e),S(t.props.setReferenceNode,e)})),t}u()(t,e);var n=t.prototype;return n.componentWillUnmount=function(){E(this.props.innerRef,null)},n.render=function(){return A()(Boolean(this.props.setReferenceNode),"`Reference` should not be used outside of a `Manager` component."),T(this.props.children)({ref:this.refHandler})},t}(y.Component);function L(e){return y.createElement(_.Consumer,null,(function(t){return y.createElement(I,a()({setReferenceNode:t},e))}))}n.d(t,"Popper",(function(){return P})),n.d(t,"placements",(function(){return O})),n.d(t,"Manager",(function(){return w})),n.d(t,"Reference",(function(){return L}))}])}));
|