UNPKG

@lahzenegar/video-react

Version:

Video-React is a web video player built from the ground up for an HTML5 world using React library.

1 lines 588 kB
(function(e,t){'object'==typeof exports&&'undefined'!=typeof module?t(exports,require('react'),require('redux'),require('stream'),require('string_decoder'),require('events'),require('timers'),require('react-dom')):'function'==typeof define&&define.amd?define(['exports','react','redux','stream','string_decoder','events','timers','react-dom'],t):t(e['video-react']=e['video-react']||{},e.React,e.Redux,e.stream,e.string_decoder,e.events,e.timers,e.ReactDOM)})(this,function(e,t,a,r,n,o,s,l){'use strict';function d(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,'default')?e['default']:e}function c(e,t){return t={exports:{}},e(t,t.exports),t.exports}function p(e){if(null===e||e===void 0)throw new TypeError('Object.assign cannot be called with null or undefined');return Object(e)}function u(){try{if(!Io)return!1;var e=new String('abc');if(e[5]='de','5'===il(e)[0])return!1;for(var t={},a=0;10>a;a++)t['_'+vn(a)]=a;var r=il(t).map(function(e){return t[e]});if('0123456789'!==r.join(''))return!1;var n={};return['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t'].forEach(function(e){n[e]=e}),'abcdefghijklmnopqrst'===Zs(Io({},n)).join('')}catch(e){return!1}}function m(){}function y(){}function h(){return{type:Jl}}function _(){return{type:Zl}}function v(){return{type:Ql}}function E(){return{type:td}}function T(){var e=0<arguments.length&&arguments[0]!==void 0?arguments[0]:!0;return{type:e?ad:rd}}function b(e){return{type:El,videoProps:e}}function S(e,t,a){return{type:Tl,videoProps:e,waitingDuration:a,delayToStartPlaying:t}}function A(e){return{type:bl,videoProps:e}}function R(e){return{type:Sl,videoProps:e}}function C(e){return{type:kl,videoProps:e}}function D(e){return{type:Al,videoProps:e}}function L(e){return{type:Rl,videoProps:e}}function P(e){return{type:Cl,videoProps:e}}function I(e){return{type:Dl,videoProps:e}}function x(e){return{type:Ll,videoProps:e}}function O(e){return{type:xl,videoProps:e}}function N(e,t,a,r){return{type:Ol,videoProps:e,secondsPlayed:t,percentPlayed:a,waitingTime:r}}function w(e){return{type:Nl,videoProps:e}}function F(e){return{type:wl,videoProps:e}}function M(e){return{type:Fl,videoProps:e}}function U(e){return{type:Ml,videoProps:e}}function B(e){return{type:Ul,videoProps:e}}function G(e){return{type:Bl,videoProps:e}}function V(e){return{type:Gl,videoProps:e}}function K(e){return{type:jl,videoProps:e}}function H(e){return{type:Vl,videoProps:e}}function W(e){return{type:Kl,videoProps:e}}function Y(e){return{type:Hl,videoProps:e}}function q(e,t,a,r){return{type:Wl,hasDVR:e,isLive:t,mediaDuration:a,playOffset:r}}function z(e,t){return{type:Yl,liveTime:e,latency:t}}function X(e){return{type:ql,tracks:e}}function $(e){return{type:$l,hls:e}}function Q(e,t){return{type:Xl,realActiveTrack:e,switchingTrack:t}}function Z(e){return{type:zl,activeTrack:e}}function J(e){return{type:Pl,time:e}}function ee(e){return{type:Il,time:e}}function te(e){return{type:yd,isFullscreen:e}}function ae(e){return{type:vd,audioOnly:e}}function re(e){return{type:hd,activity:e}}function ne(e){return{type:_d,activity:e}}function oe(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{action:'play',source:''};return this.video.play(),{type:fd,operation:e}}function ie(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{action:'pause',source:''};return this.video.pause(),{type:fd,operation:e}}function se(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{action:'toggle-play',source:''};return this.video.togglePlay(),{type:fd,operation:e}}function le(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:'seek',source:''};return this.video.seek(e),{type:fd,operation:t}}function de(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:'forward-'+e,source:''};return this.video.forward(e),{type:fd,operation:t}}function ce(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:'replay-'+e,source:''};return this.video.replay(e),{type:fd,operation:t}}function pe(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:'change-rate',source:''};return this.video.playbackRate=e,{type:fd,operation:t}}function ue(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:'change-volume',source:''},a=e;return 0>e&&(a=0),1<e&&(a=1),this.video.volume=a,{type:fd,operation:t}}function ge(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{action:e?'muted':'unmuted',source:''};return this.video.muted=e,{type:fd,operation:t}}function me(e){return pd?void this.video.video.webkitEnterFullscreen():id.enabled?(id.isFullscreen?id.exit():id.request(this.rootElement),{type:fd,operation:{action:'toggle-fullscreen',source:''}}):{type:yd,isFullscreen:!e.isFullscreen}}function fe(){var e=0<arguments.length&&arguments[0]!==void 0?arguments[0]:Td,t=arguments[1];switch(t.type){case _d:return Oo({},e,{userActivity:t.activity});case hd:return Oo({},e,{isActive:t.activity});case yd:return Oo({},e,{isFullscreen:!!t.isFullscreen});case vd:return Oo({},e,{audioOnly:t.audioOnly});case Ql:return Oo({},e,{ads:!0});case td:return Oo({},e,{ads:!1});case ad:return Oo({},e,{contentLoading:!0});case rd:return Oo({},e,{contentLoading:!1});case Jl:case Zl:return Oo({},e);case Pl:return Oo({},e,{seekingTime:t.time});case Il:return Oo({},e,{seekingTime:0});case El:return Oo({},e,t.videoProps,{hasStarted:!1,ended:!1});case Sl:var a=Oo({},e,t.videoProps);return!0===t.videoProps.paused&&(a.waiting=!1),a;case Tl:var r=Oo({},e,t.videoProps,{waitingDuration:t.waitingDuration,delayToStartPlaying:t.delayToStartPlaying});return!0===t.videoProps.paused&&(r.waiting=!1),r;case bl:return Oo({},e,t.videoProps,{waiting:!0});case kl:return Oo({},e,t.videoProps,{waiting:!1,hasStarted:!0});case Al:return Oo({},e,t.videoProps,{ended:!1,paused:!1,autoPaused:!1,waiting:!1});case Rl:return Oo({},e,t.videoProps,{paused:!0});case Cl:return Oo({},e,t.videoProps,{ended:!0});case Dl:return Oo({},e,t.videoProps,{seeking:!0});case Ll:return Oo({},e,t.videoProps,{seeking:!1});case Hl:return Oo({},e,t.videoProps,{error:'UNKNOWN ERROR',ended:!0});case Wl:return Oo({},e,{hasDVR:t.hasDVR,isLive:t.isLive,mediaDuration:t.mediaDuration,playOffset:t.playOffset});case Yl:return Oo({},e,{liveTime:t.liveTime,latency:t.latency});case ql:return Oo({},e,{tracks:t.tracks});case $l:return Oo({},e,{hls:t.hls});case zl:return Oo({},e,{activeTrack:t.activeTrack});case Xl:return Oo({},e,{realActiveTrack:t.realActiveTrack,switchingTrack:t.switchingTrack});case Ol:return Oo({},e,t.videoProps,{secondsPlayed:t.secondsPlayed,percentPlayed:t.percentPlayed,waitingTime:t.waitingTime,waiting:!1});case xl:case Nl:case wl:case Fl:return Oo({},e,t.videoProps);case Ml:case Ul:case Bl:case Gl:case jl:case Vl:case Kl:return Oo({},e,t.videoProps);default:return e;}}function ye(){var e=0<arguments.length&&arguments[0]!==void 0?arguments[0]:bd,t=arguments[1];switch(t.type){case fd:return Oo({},e,{count:e.count+1,operation:Oo({},e.operation,t.operation)});default:return e;}}function he(e){var t=e.player,a=e.className;return kn.createElement('div',{className:vl('video-react-loading-spinner',a)},kn.createElement('div',{className:'spinner-main'},kn.createElement('div',{className:'spinner-big'}),kn.createElement('div',{className:'spinner-small'})))}function _e(e){var t=e.player,a=e.player,r=a.currentTime,n=a.hasStarted,o=a.waiting,i=a.contentLoading,s=a.videoWidth,l=a.videoHeight,d=e.className;return!n||o||i||!r||0!==s||0!==l?null:kn.createElement('div',{className:vl('video-react-audio-visualizer',d)},kn.createElement('div',{className:'halo'}))}function ve(e){var t=e.poster,a=e.player,r=e.actions,n=e.className;return!t||a.hasStarted?null:kn.createElement('div',{className:vl('video-react-poster',n),style:{backgroundImage:'url("'+t+'")'},onClick:function(){a.paused&&r.play()}})}function Ee(e){var t,a;this.promise=new e(function(e,r){if(t!=void 0||a!=void 0)throw TypeError('Bad Promise constructor');t=e,a=r}),this.resolve=Dn(t),this.reject=Dn(a)}function Te(){try{var e=Pp;return Pp=null,e.apply(this,arguments)}catch(t){return bp.e=t,bp}}function be(e){return Pp=e,Te}function Se(e){return null==e||!0===e||!1===e||'string'==typeof e||'number'==typeof e}function ke(e){return'function'==typeof e||'object'===('undefined'==typeof e?'undefined':Ps(e))&&null!==e}function Ae(e){return Se(e)?new Error(Ne(e)):e}function Re(e,t){var a=e.length,r=Array(a+1),n;for(n=0;n<a;++n)r[n]=e[n];return r[n]=t,r}function Ce(e,t,a){if(Ep.isES5){var r=fp(e,t);if(null!=r)return null==r.get&&null==r.set?r.value:a}else return{}.hasOwnProperty.call(e,t)?e[t]:void 0}function De(e,t,a){if(Se(e))return e;return Ep.defineProperty(e,t,{value:a,configurable:!0,enumerable:!1,writable:!0}),e}function Le(e){throw e}function Pe(e){try{if('function'==typeof e){var t=Ep.names(e.prototype),a=Ep.isES5&&1<t.length,r=0<t.length&&(1!==t.length||'constructor'!==t[0]),n=Rp.test(e+'')&&0<Ep.names(e).length;if(a||r||n)return!0}return!1}catch(t){return!1}}function Ie(e){function t(){}function a(){return Ps(r.foo)}t.prototype=e;var r=new t;return a(),a(),e}function xe(e){return Cp.test(e)}function Oe(e,t,a){for(var r=Array(e),n=0;n<e;++n)r[n]=t+n+a;return r}function Ne(e){try{return e+''}catch(t){return'[no string representation]'}}function we(e){return e instanceof Error||null!==e&&'object'===('undefined'==typeof e?'undefined':Ps(e))&&'string'==typeof e.message&&'string'==typeof e.name}function Fe(t){try{De(t,'isOperational',!0)}catch(e){}}function Me(t){return null!=t&&(t instanceof Error.__BluebirdErrorTypes__.OperationalError||!0===t.isOperational)}function Ue(e){return we(e)&&Ep.propertyIsWritable(e,'stack')}function Be(e){return{}.toString.call(e)}function Ge(e,t,a){for(var r=Ep.names(e),n=0,o;n<r.length;++n)if(o=r[n],a(o))try{Ep.defineProperty(t,o,Ep.getDescriptor(e,o))}catch(e){}}function je(e){return Op?process.env[e]:void 0}function Ve(){if('function'==typeof Xc)try{var e=new Xc(function(){});if('[object Promise]'==={}.toString.call(e))return Xc}catch(t){}}function Ke(e,t){return e.bind(t)}function He(e,t,a,r,n){for(var o=0;o<n;++o)a[o+r]=e[o+t],e[o+t]=void 0}function We(e){this._capacity=e,this._length=0,this._front=0}function Ye(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new Yp(16),this._normalQueue=new Yp(16),this._haveDrainedQueues=!1,this._trampolineEnabled=!0;var e=this;this.drainQueues=function(){e._drainQueues()},this._schedule=Wp}function qe(e,t,a){this._lateQueue.push(e,t,a),this._queueTick()}function ze(e,t,a){this._normalQueue.push(e,t,a),this._queueTick()}function Xe(e){this._normalQueue._pushOne(e),this._queueTick()}function $e(e){for(;0<e.length();)Qe(e)}function Qe(e){var t=e.shift();if('function'!=typeof t)t._settlePromises();else{var a=e.shift(),r=e.shift();t.call(a,r)}}function Ze(e,t){function a(r){return this instanceof a?void(Zp(this,'message','string'==typeof r?r:t),Zp(this,'name',e),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)):new a(r)}return Qp(a,Error),a}function Je(e){return this instanceof Je?void(Zp(this,'name','OperationalError'),Zp(this,'message',e),this.cause=e,this.isOperational=!0,e instanceof Error?(Zp(this,'message',e.message),Zp(this,'stack',e.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)):new Je(e)}function et(e){return e instanceof Error&&Ep.getPrototypeOf(e)===Error.prototype}function tt(e){var t;if(et(e)){t=new Bu(e),t.name=e.name,t.message=e.message,t.stack=e.stack;for(var a=Ep.keys(e),r=0,n;r<a.length;++r)n=a[r],Gu.test(n)||(t[n]=e[n]);return t}return wp.markAsOriginatingFromRejection(e),e}function at(e,t){return function(a,r){if(null!==e){if(a){var n=tt(Uu(a));e._attachExtraTrace(n),e._reject(n)}else if(!t)e._fulfill(r);else{for(var o=arguments.length,i=Array(En(o-1,0)),s=1;s<o;++s)i[s-1]=arguments[s];e._fulfill(i)}e=null}}}function rt(){try{Xc===gg&&(Promise=ug)}catch(t){}return gg}function nt(e,t){for(var a=-1,r=null==e?0:e.length;++a<r&&!(!1===t(e[a],a,e)););return e}function ot(e){return function(t,a,r){for(var n=-1,o=Object(t),i=r(t),s=i.length;s--;){var l=i[e?s:++n];if(!1===a(o[l],l,o))break}return t}}function it(e,t){for(var a=-1,r=Array(e);++a<e;)r[a]=t(a);return r}function st(e){var t=lm.call(e,cm),a=e[cm];try{e[cm]=void 0}catch(t){}var r=dm.call(e);return t?e[cm]=a:delete e[cm],r}function lt(e){return gm.call(e)}function dt(e){return null==e?void 0===e?ym:fm:hm&&hm in Object(e)?pm(e):mm(e)}function ct(e){return null!=e&&'object'==('undefined'==typeof e?'undefined':Ps(e))}function pt(e){return vm(e)&&_m(e)==Em}function ut(){return!1}function gt(e,t){var a='undefined'==typeof e?'undefined':Ps(e);return t=null==t?Im:t,!!t&&('number'==a||'symbol'!=a&&xm.test(e))&&-1<e&&0==e%1&&e<t}function mt(e){return'number'==typeof e&&-1<e&&0==e%1&&e<=Nm}function ft(e){return vm(e)&&wm(e.length)&&!!sf[_m(e)]}function yt(e){return function(t){return e(t)}}function ht(e,t){var a=Dm(e),r=!a&&Rm(e),n=!a&&!r&&Pm(e),o=!a&&!r&&!n&&gf(e),i=a||r||n||o,s=i?Jg(e.length,String):[],l=s.length;for(var d in e)(t||ff.call(e,d))&&!(i&&('length'==d||n&&('offset'==d||'parent'==d)||o&&('buffer'==d||'byteLength'==d||'byteOffset'==d)||Om(d,l)))&&s.push(d);return s}function _t(e){var t=e&&e.constructor,a='function'==typeof t&&t.prototype||hf;return e===a}function vt(e,t){return function(a){return e(t(a))}}function Et(e){if(!_f(e))return Tf(e);var t=[];for(var a in Object(e))Sf.call(e,a)&&'constructor'!=a&&t.push(a);return t}function Tt(e){var t='undefined'==typeof e?'undefined':Ps(e);return null!=e&&('object'==t||'function'==t)}function bt(e){if(!Af(e))return!1;var t=_m(e);return t==Cf||t==Df||t==Rf||t==Lf}function St(e){return null!=e&&wm(e.length)&&!Pf(e)}function kt(e){return If(e)?yf(e):kf(e)}function At(e,t){return e&&Zg(e,t,xf)}function Rt(e,t){return function(a,r){if(null==a)return a;if(!If(a))return e(a,r);for(var n=a.length,o=t?n:-1,i=Object(a);(t?o--:++o<n)&&!(!1===r(i[o],o,i)););return a}}function Ct(e){return e}function Dt(e){return'function'==typeof e?e:Mf}function Lt(e,t){var a=Dm(e)?Xg:Ff;return a(e,Uf(t))}function Pt(e){var t=e;return-1<t.indexOf('HTML')?t=t.replace('HTML','html'):-1<t.indexOf('VAST')&&(t=t.replace('VAST','vast')),t}function It(){try{return this._value}catch(e){return null}}function xt(e){try{return this._attr[e]}catch(e){return null}}function Ot(e){var t=Array.isArray(e)?[]:{};return Gf(e,function(e,a){var r=e,n=n(r),o=Array.isArray(r);n&&(r._value&&(r.getValue=It.bind(r)),r.getAttr=xt.bind(r)),t[a]=n||o?zf[a]&&!o?[Ot(r)]:Ot(r):r}),t}function Nt(e){try{return new URL(e),!0}catch(e){return!1}}function wt(e,t){try{var a=e.vast.ad,r=[];return a.map(function(e){var a=e.inLine,n=e.inLine.creatives.creative;n.map(function(e){var n=e.linear,o=e.linear,i=o.videoClicks.clickThrough,s=o.mediaFiles.mediaFile;r.push({adTitle:a.adTitle.getValue(),adSystem:a.adSystem.getValue(),duration:Ft(n.duration.getValue()),skipOn:Ft(n.getAttr('skipoffset')),adID:e.getAttr('adID'),videoClicks:i.getValue(),mediaFiles:s.map(function(e){var a=e.getValue();return!Nt(a)&&t&&(a=''+t+(a.startsWith('/')?'':'/')+a),{URL:a,type:e.getAttr('type'),width:e.getAttr('width'),height:e.getAttr('height'),delivery:e.getAttr('delivery')}})})})}),r}catch(e){return[]}}function Ft(e){if(!e||3!==e.split(':').length)return 0;for(var t=e&&e.split(':'),a=0,r=1;0<t.length;)a+=r*parseInt(t.pop(),10),r*=60;return a}function Mt(e,t,a){return Xc.race([fetch(e,t),new Xc(function(e,t){return setTimeout(function(){return t('FILE_FETCH_TIMEOUT')},a)})])}function Ut(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:e,a=2<arguments.length&&void 0!==arguments[2]&&arguments[2],r=a?t-e:e,n=bn(r%60),o=bn(r/60%60),i=bn(r/3600),s=bn(t/60%60),l=bn(t/3600);return(isNaN(r)||r===Infinity)&&(i=o=n='-'),i=0<i||0<l?i+':':'',o=((i||10<=s)&&10>o?'0'+o:o)+':',n=10>n?'0'+n:n,a?'-'+i+o+n:i+o+n}function Bt(e){return e.props&&e.props.isVideoChild||'source'===e.type||'track'===e.type}function Gt(e){var t=/http.*?\.m3u8/;return!!t.test(e)}function jt(t,e,a){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:1,n=kn.Children.toArray(e),o=Oo({},a);return n.filter(function(t){return!t.props.disabled}).concat(t.filter(function(e){return!Ey(n,function(t){return Ty(t,e)})})).map(function(a){var r=Ey(t,function(e){return Ty(e,a)});delete o.order;var n=r?r.props:{},i=Oo({},o,n,a.props),s=kn.cloneElement(a,i,a.props.children);return s}).sort(function(e,t){return(e.props.order||r)-(t.props.order||r)})}function Vt(e,t){console.warn('WARNING: '+e+' will be deprecated soon! Please use '+t+' instead.')}function Kt(e,t){var a=arguments,r=!1;return function(){r||(e.apply(null,a),r=!0,setTimeout(function(){r=!1},t))}}function Ht(e){if(e){var t=e.details,a=e.fatal,r=a||Yt(e);return r?{type:qt(e),detail:Yt(e)?Wt(e):zt(t),isFatal:r}:null}}function Wt(e){if(e){var t=e.response,a=e.details,r=zt(a);return t&&t.code?'HTTP_ERROR_'+t.code:r?'NETWORK_ISSUE_'+zt(a):'NETWORK_ERROR'}}function Yt(e){return e&&e.type===_y.ErrorTypes.NETWORK_ERROR}function qt(e){var t=e.type;return t===_y.ErrorTypes.KEY_SYSTEM_ERROR?'KEY_SYSTEM_ERROR':t===_y.ErrorTypes.MEDIA_ERROR?'MEDIA_ERROR':t===_y.ErrorTypes.MUX_ERROR?'MUX_ERROR':t===_y.ErrorTypes.NETWORK_ERROR?'NETWORK_ERROR':t===_y.ErrorTypes.OTHER_ERROR?'OTHER_ERROR':'UNHANDLED_ERROR'}function zt(e){return e?e===_y.ErrorDetails.AUDIO_TRACK_LOAD_ERROR?'AUDIO_TRACK_LOAD_ERROR':e===_y.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT?'AUDIO_TRACK_LOAD_TIMEOUT':e===_y.ErrorDetails.BUFFER_ADD_CODEC_ERROR?'BUFFER_ADD_CODEC_ERROR':e===_y.ErrorDetails.BUFFER_APPENDING_ERROR?'BUFFER_APPENDING_ERROR':e===_y.ErrorDetails.BUFFER_APPEND_ERROR?'BUFFER_APPEND_ERROR':e===_y.ErrorDetails.BUFFER_FULL_ERROR?'BUFFER_FULL_ERROR':e===_y.ErrorDetails.BUFFER_NUDGE_ON_STALL?'BUFFER_NUDGE_ON_STALL':e===_y.ErrorDetails.BUFFER_SEEK_OVER_HOLE?'BUFFER_SEEK_OVER_HOLE':e===_y.ErrorDetails.BUFFER_STALLED_ERROR?'BUFFER_STALLED_ERROR':e===_y.ErrorDetails.FRAG_DECRYPT_ERROR?'FRAG_DECRYPT_ERROR':e===_y.ErrorDetails.FRAG_LOAD_ERROR?'FRAG_LOAD_ERROR':e===_y.ErrorDetails.FRAG_LOAD_TIMEOUT?'FRAG_LOAD_TIMEOUT':e===_y.ErrorDetails.FRAG_PARSING_ERROR?'FRAG_PARSING_ERROR':e===_y.ErrorDetails.INTERNAL_EXCEPTION?'INTERNAL_EXCEPTION':e===_y.ErrorDetails.KEY_LOAD_ERROR?'KEY_LOAD_ERROR':e===_y.ErrorDetails.KEY_LOAD_TIMEOUT?'KEY_LOAD_TIMEOUT':e===_y.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED?'KEY_SYSTEM_LICENSE_REQUEST_FAILED':e===_y.ErrorDetails.KEY_SYSTEM_NO_ACCESS?'KEY_SYSTEM_NO_ACCESS':e===_y.ErrorDetails.KEY_SYSTEM_NO_KEYS?'KEY_SYSTEM_NO_KEYS':e===_y.ErrorDetails.KEY_SYSTEM_NO_SESSION?'KEY_SYSTEM_NO_SESSION':e===_y.ErrorDetails.LEVEL_LOAD_ERROR?'LEVEL_LOAD_ERROR':e===_y.ErrorDetails.LEVEL_LOAD_TIMEOUT?'LEVEL_LOAD_TIMEOUT':e===_y.ErrorDetails.LEVEL_SWITCH_ERROR?'LEVEL_SWITCH_ERROR':e===_y.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR?'MANIFEST_INCOMPATIBLE_CODECS_ERROR':e===_y.ErrorDetails.MANIFEST_LOAD_ERROR?'MANIFEST_LOAD_ERROR':e===_y.ErrorDetails.MANIFEST_LOAD_TIMEOUT?'MANIFEST_LOAD_TIMEOUT':e===_y.ErrorDetails.MANIFEST_PARSING_ERROR?'MANIFEST_PARSING_ERROR':e===_y.ErrorDetails.REMUX_ALLOC_ERROR?'REMUX_ALLOC_ERROR':'string'==typeof e?Xt(e).toUpperCase():'OTHER_ERRORS':'UNHANDLED_ERROR'}function Xt(e){var t=1<arguments.length&&arguments[1]!==void 0?arguments[1]:'_';return e&&t?e.trim().replace(/([A-Z])/g,function(e){return t+e.toLowerCase()}).replace(new RegExp('^\\'+t,'g'),'').replace(new RegExp('\\'+t+'$','g'),''):null}function $t(){var e=0,t=setInterval(function(){e+=100},100);return{end:function(){return clearInterval(t),e}}}function Qt(e){var t;if(e.getBoundingClientRect&&e.parentNode&&(t=e.getBoundingClientRect()),!t)return{left:0,top:0};var a=document.documentElement,r=document.body,n=a.clientLeft||r.clientLeft||0,o=window.pageXOffset||r.scrollLeft,i=t.left+o-n,s=a.clientTop||r.clientTop||0,l=window.pageYOffset||r.scrollTop,d=t.top+l-s;return{left:hn(i),top:hn(d)}}function Zt(e,t){var a={},r=Qt(e),n=e.offsetWidth,o=e.offsetHeight,i=r.top,s=r.left,l=t.pageY,d=t.pageX;return t.changedTouches&&(d=t.changedTouches[0].pageX,l=t.changedTouches[0].pageY),a.y=En(0,Tn(1,(i-l+o)/o)),a.x=En(0,Tn(1,(d-s)/n)),a}function Jt(e,t){for(var a=e.className.split(' '),r=0;r<a.length;r++)if(a[r].toLowerCase()===t.toLowerCase())return!0;return!1}function ea(e){var t=e.hasDVR,a=e.latency,r=e.currentTime,n=e.duration,o=e.percentage,i=e.className;return kn.createElement('div',{"data-current-time":Ut(r,n),className:vl('video-react-play-progress video-react-slider-bar',i),style:{width:20>=a&&t?'100%':o}},kn.createElement('span',{className:'video-react-control-text'},kn.createElement('span',null,'Progress'),': ',o))}function ta(e){function t(e,t){var a=e/t||0;return 1<=a?a=1:0>=a&&(a=0),100*a+'%'}var a=e.hasDVR,r=e.buffered,n=e.duration,o=e.playOffset,s=e.className;if(!r||!r.length)return null;var l=r.end(r.length-1),d={};l>n&&(l=n),d.width=t(l,n);for(var c=[],p=0;p<r.length;p++){var i=void 0,u=void 0;a?(i=r.start(p)-o,u=r.end(p)-o):(i=r.start(p),u=r.end(p));var g=kn.createElement('div',{style:{left:t(i,l),width:t(u-i,l)},key:'part-'+p});c.push(g)}return 0===c.length&&(c=null),kn.createElement('div',{style:d,className:vl('video-react-load-progress',s)},kn.createElement('span',{className:'video-react-control-text'},kn.createElement('span',null,'Loaded'),': 0%'),c)}function aa(e){var t=e.duration,a=e.mouseTime,r=e.className,n=e.text,o=e.hasDVR;if(!a.time)return null;var i=n||Ut(a.time,t,o);return kn.createElement('div',{className:vl('video-react-mouse-display',r),style:{left:a.position+'px'},"data-current-time":i})}function ra(e){return e?(e.nodeName||'').toLowerCase():null}function na(e){if(null==e)return window;if('[object Window]'!==e.toString()){var t=e.ownerDocument;return t?t.defaultView||window:window}return e}function oa(e){var t=na(e).Element;return e instanceof t||e instanceof Element}function ia(e){var t=na(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function sa(e){if('undefined'==typeof ShadowRoot)return!1;var t=na(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function la(e){var t=e.state;Zs(t.elements).forEach(function(e){var a=t.styles[e]||{},r=t.attributes[e]||{},n=t.elements[e];ia(n)&&ra(n)&&(Io(n.style,a),Zs(r).forEach(function(e){var t=r[e];!1===t?n.removeAttribute(e):n.setAttribute(e,!0===t?'':t)}))})}function da(e){var t=e.state,a={popper:{position:t.options.strategy,left:'0',top:'0',margin:'0'},arrow:{position:'absolute'},reference:{}};return Io(t.elements.popper.style,a.popper),t.styles=a,t.elements.arrow&&Io(t.elements.arrow.style,a.arrow),function(){Zs(t.elements).forEach(function(e){var r=t.elements[e],n=t.attributes[e]||{},o=Zs(t.styles.hasOwnProperty(e)?t.styles[e]:a[e]),i=o.reduce(function(e,t){return e[t]='',e},{});ia(r)&&ra(r)&&(Io(r.style,i),Zs(n).forEach(function(e){r.removeAttribute(e)}))})}}function ca(e){return e.split('-')[0]}function pa(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function ga(e){var t=pa(e),a=e.offsetWidth,r=e.offsetHeight;return 1>=yn(t.width-a)&&(a=t.width),1>=yn(t.height-r)&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:a,height:r}}function ma(e,t){var a=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(a&&sa(a)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function fa(e){return na(e).getComputedStyle(e)}function ya(e){return 0<=['table','td','th'].indexOf(ra(e))}function ha(e){return((oa(e)?e.ownerDocument:e.document)||window.document).documentElement}function _a(e){return'html'===ra(e)?e:e.assignedSlot||e.parentNode||(sa(e)?e.host:null)||ha(e)}function va(e){return ia(e)&&'fixed'!==fa(e).position?e.offsetParent:null}function Ea(e){var t=-1!==navigator.userAgent.toLowerCase().indexOf('firefox'),a=-1!==navigator.userAgent.indexOf('Trident');if(a&&ia(e)){var r=fa(e);if('fixed'===r.position)return null}for(var n=_a(e);ia(n)&&0>['html','body'].indexOf(ra(n));){var o=fa(n);if('none'!==o.transform||'none'!==o.perspective||'paint'===o.contain||-1!==['transform','perspective'].indexOf(o.willChange)||t&&'filter'===o.willChange||t&&o.filter&&'none'!==o.filter)return n;n=n.parentNode}return null}function Ta(e){for(var t=na(e),a=va(e);a&&ya(a)&&'static'===fa(a).position;)a=va(a);return a&&('html'===ra(a)||'body'===ra(a)&&'static'===fa(a).position)?t:a||Ea(e)||t}function ba(e){return 0<=['top','bottom'].indexOf(e)?'x':'y'}function Sa(e,t,a){return fh(e,yh(t,a))}function ka(){return{top:0,right:0,bottom:0,left:0}}function Aa(e){return Io({},ka(),e)}function Ra(e,t){return t.reduce(function(t,a){return t[a]=e,t},{})}function Ca(e){var t=e.state,a=e.name,r=e.options,n=t.elements.arrow,o=t.modifiersData.popperOffsets,i=ca(t.placement),s=ba(i),l=0<=[qy,Yy].indexOf(i),d=l?'height':'width',c;if(n&&o){var p=_h(r.padding,t),u=ga(n),g='y'===s?Hy:qy,m='y'===s?Wy:Yy,f=t.rects.reference[d]+t.rects.reference[s]-o[s]-t.rects.popper[d],y=o[s]-t.rects.reference[s],h=Ta(n),_=h?'y'===s?h.clientHeight||0:h.clientWidth||0:0,v=p[g],E=_-u[d]-p[m],T=_/2-u[d]/2+(f/2-y/2),b=Sa(v,T,E);t.modifiersData[a]=(c={},c[s]=b,c.centerOffset=b-T,c)}}function Da(e){var t=e.state,a=e.options,r=a.element,n=void 0===r?'[data-popper-arrow]':r;null==n||'string'==typeof n&&(n=t.elements.popper.querySelector(n),!n)||!ma(t.elements.popper,n)||(t.elements.arrow=n)}function La(e){var t=e.x,a=e.y,r=window,n=r.devicePixelRatio||1;return{x:hh(hh(t*n)/n)||0,y:hh(hh(a*n)/n)||0}}function Pa(e){var t=e.popper,a=e.popperRect,r=e.placement,n=e.offsets,o=e.position,i=e.gpuAcceleration,s=e.adaptive,l=e.roundOffsets,d=!0===l?La(n):'function'==typeof l?l(n):n,c=d.x,p=void 0===c?0:c,u=d.y,g=void 0===u?0:u,m=n.hasOwnProperty('x'),f=n.hasOwnProperty('y'),y=qy,h=Hy,_=window,v;if(s){var E=Ta(t),T='clientHeight',b='clientWidth';E===na(t)&&(E=ha(t),'static'!==fa(E).position&&(T='scrollHeight',b='scrollWidth')),E=E,r===Hy&&(h=Wy,g-=E[T]-a.height,g*=i?1:-1),r===qy&&(y=Yy,p-=E[b]-a.width,p*=i?1:-1)}var S=Io({position:o},s&&Eh);if(i){var k;return Io({},S,(k={},k[h]=f?'0':'',k[y]=m?'0':'',k.transform=2>(_.devicePixelRatio||1)?'translate('+p+'px, '+g+'px)':'translate3d('+p+'px, '+g+'px, 0)',k))}return Io({},S,(v={},v[h]=f?g+'px':'',v[y]=m?p+'px':'',v.transform='',v))}function Ia(e){var t=e.state,a=e.options,r=a.gpuAcceleration,n=a.adaptive,o=a.roundOffsets,i=!(void 0!==o)||o,s={placement:ca(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:!(void 0!==r)||r};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Io({},t.styles.popper,Pa(Io({},s,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:!(void 0!==n)||n,roundOffsets:i})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Io({},t.styles.arrow,Pa(Io({},s,{offsets:t.modifiersData.arrow,position:'absolute',adaptive:!1,roundOffsets:i})))),t.attributes.popper=Io({},t.attributes.popper,{"data-popper-placement":t.placement})}function xa(e){var t=e.state,a=e.instance,r=e.options,n=r.scroll,o=void 0===n||n,i=r.resize,s=void 0===i||i,l=na(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&d.forEach(function(e){e.addEventListener('scroll',a.update,bh)}),s&&l.addEventListener('resize',a.update,bh),function(){o&&d.forEach(function(e){e.removeEventListener('scroll',a.update,bh)}),s&&l.removeEventListener('resize',a.update,bh)}}function Oa(e){return e.replace(/left|right|bottom|top/g,function(e){return kh[e]})}function Na(e){return e.replace(/start|end/g,function(e){return Ah[e]})}function wa(e){var t=na(e),a=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:a,scrollTop:r}}function Fa(e){return pa(ha(e)).left+wa(e).scrollLeft}function Ma(e){var t=na(e),a=ha(e),r=t.visualViewport,n=a.clientWidth,o=a.clientHeight,i=0,s=0;return r&&(n=r.width,o=r.height,!/^((?!chrome|android).)*safari/i.test(navigator.userAgent)&&(i=r.offsetLeft,s=r.offsetTop)),{width:n,height:o,x:i+Fa(e),y:s}}function Ua(e){var t=ha(e),a=wa(e),r=null==(l=e.ownerDocument)?void 0:l.body,n=fh(t.scrollWidth,t.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),o=fh(t.scrollHeight,t.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),i=-a.scrollLeft+Fa(e),s=-a.scrollTop,l;return'rtl'===fa(r||t).direction&&(i+=fh(t.clientWidth,r?r.clientWidth:0)-n),{width:n,height:o,x:i,y:s}}function Ba(e){var t=fa(e),a=t.overflow,r=t.overflowX,n=t.overflowY;return /auto|scroll|overlay|hidden/.test(a+n+r)}function Ga(e){return 0<=['html','body','#document'].indexOf(ra(e))?e.ownerDocument.body:ia(e)&&Ba(e)?e:Ga(_a(e))}function ja(e,t){var a;void 0===t&&(t=[]);var r=Ga(e),n=r===(null==(a=e.ownerDocument)?void 0:a.body),o=na(r),i=n?[o].concat(o.visualViewport||[],Ba(r)?r:[]):r,s=t.concat(i);return n?s:s.concat(ja(_a(i)))}function Va(e){return Io({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Ka(e){var t=pa(e);return t.top+=e.clientTop,t.left+=e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}function Ha(e,t){return t===Jy?Va(Ma(e)):ia(t)?Ka(t):Va(Ua(ha(e)))}function Wa(e){var t=ja(_a(e)),a=0<=['absolute','fixed'].indexOf(fa(e).position),r=a&&ia(e)?Ta(e):e;return oa(r)?t.filter(function(e){return oa(e)&&ma(e,r)&&'body'!==ra(e)}):[]}function Ya(e,t,a){var r='clippingParents'===t?Wa(e):[].concat(t),n=[].concat(r,[a]),o=n[0],i=n.reduce(function(t,a){var r=Ha(e,a);return t.top=fh(r.top,t.top),t.right=yh(r.right,t.right),t.bottom=yh(r.bottom,t.bottom),t.left=fh(r.left,t.left),t},Ha(e,o));return i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}function qa(e){return e.split('-')[1]}function za(e){var t=e.reference,a=e.element,r=e.placement,n=r?ca(r):null,o=r?qa(r):null,i=t.x+t.width/2-a.width/2,s=t.y+t.height/2-a.height/2,l;l=n===Hy?{x:i,y:t.y-a.height}:n===Wy?{x:i,y:t.y+t.height}:n===Yy?{x:t.x+t.width,y:s}:n===qy?{x:t.x-a.width,y:s}:{x:t.x,y:t.y};var d=n?ba(n):null;if(null!=d){var c='y'===d?'height':'width';switch(o){case $y:l[d]-=t[c]/2-a[c]/2;break;case Qy:l[d]+=t[c]/2-a[c]/2;break;default:}}return l}function Xa(e,t){void 0===t&&(t={});var a=t,r=a.placement,n=void 0===r?e.placement:r,o=a.boundary,i=void 0===o?Zy:o,s=a.rootBoundary,l=void 0===s?Jy:s,d=a.elementContext,c=void 0===d?eh:d,p=a.altBoundary,u=a.padding,g=void 0===u?0:u,m=Aa('number'==typeof g?Ra(g,Xy):g),f=c===eh?th:eh,y=e.elements.reference,h=e.rects.popper,_=e.elements[void 0!==p&&p?f:c],v=Ya(oa(_)?_:_.contextElement||ha(e.elements.popper),i,l),E=pa(y),T=za({reference:E,element:h,strategy:'absolute',placement:n}),b=Va(Io({},h,T)),S=c===eh?b:E,k={top:v.top-S.top+m.top,bottom:S.bottom-v.bottom+m.bottom,left:v.left-S.left+m.left,right:S.right-v.right+m.right},A=e.modifiersData.offset;if(c===eh&&A){var R=A[n];Zs(k).forEach(function(e){var t=0<=[Yy,Wy].indexOf(e)?1:-1,a=0<=[Hy,Wy].indexOf(e)?'y':'x';k[e]+=R[a]*t})}return k}function $a(e,t){void 0===t&&(t={});var a=t,r=a.placement,n=a.boundary,o=a.rootBoundary,i=a.padding,s=a.flipVariations,l=a.allowedAutoPlacements,d=void 0===l?rh:l,c=qa(r),p=c?s?ah:ah.filter(function(e){return qa(e)===c}):Xy,u=p.filter(function(e){return 0<=d.indexOf(e)});0===u.length&&(u=p);var g=u.reduce(function(t,a){return t[a]=Xa(e,{placement:a,boundary:n,rootBoundary:o,padding:i})[ca(a)],t},{});return Zs(g).sort(function(e,t){return g[e]-g[t]})}function Qa(e){if(ca(e)===zy)return[];var t=Oa(e);return[Na(e),t,Na(t)]}function Za(e){var t=e.state,a=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var n=a.mainAxis,o=a.altAxis,s=a.fallbackPlacements,l=a.padding,d=a.boundary,c=a.rootBoundary,p=a.altBoundary,u=a.flipVariations,g=void 0===u||u,m=a.allowedAutoPlacements,f=t.options.placement,y=ca(f),h=s||(y===f||!g?[Oa(f)]:Qa(f)),_=[f].concat(h).reduce(function(e,a){return e.concat(ca(a)===zy?$a(t,{placement:a,boundary:d,rootBoundary:c,padding:l,flipVariations:g,allowedAutoPlacements:m}):a)},[]),v=t.rects.reference,E=t.rects.popper,T=new xu,b=!0,S=_[0],k=0;k<_.length;k++){var i=_[k],A=ca(i),R=qa(i)===$y,C=0<=[Hy,Wy].indexOf(A),D=C?'width':'height',L=Xa(t,{placement:i,boundary:d,rootBoundary:c,altBoundary:p,padding:l}),P=C?R?Yy:qy:R?Wy:Hy;v[D]>E[D]&&(P=Oa(P));var I=Oa(P),x=[];if((void 0===n||n)&&x.push(0>=L[A]),(void 0===o||o)&&x.push(0>=L[P],0>=L[I]),x.every(function(e){return e})){S=i,b=!1;break}T.set(i,x)}if(b)for(var O=g?3:1,N=function(e){var t=_.find(function(t){var a=T.get(t);if(a)return a.slice(0,e).every(function(e){return e})});if(t)return S=t,'break'},w=O,F;0<w&&(F=N(w),'break'!==F);w--);t.placement!==S&&(t.modifiersData[r]._skip=!0,t.placement=S,t.reset=!0)}}function Ja(e,t,a){return void 0===a&&(a={x:0,y:0}),{top:e.top-t.height-a.y,right:e.right-t.width+a.x,bottom:e.bottom-t.height+a.y,left:e.left-t.width-a.x}}function er(e){return[Hy,Yy,Wy,qy].some(function(t){return 0<=e[t]})}function tr(e){var t=e.state,a=e.name,r=t.rects.reference,n=t.rects.popper,o=t.modifiersData.preventOverflow,i=Xa(t,{elementContext:'reference'}),s=Xa(t,{altBoundary:!0}),l=Ja(i,r),d=Ja(s,n,o),c=er(l),p=er(d);t.modifiersData[a]={referenceClippingOffsets:l,popperEscapeOffsets:d,isReferenceHidden:c,hasPopperEscaped:p},t.attributes.popper=Io({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":p})}function ar(e,t,a){var r=ca(e),n=0<=[qy,Hy].indexOf(r)?-1:1,o='function'==typeof a?a(Io({},t,{placement:e})):a,i=o[0],s=o[1];return i=i||0,s=(s||0)*n,0<=[qy,Yy].indexOf(r)?{x:s,y:i}:{x:i,y:s}}function rr(e){var t=e.state,a=e.options,r=e.name,n=a.offset,o=void 0===n?[0,0]:n,i=rh.reduce(function(e,a){return e[a]=ar(a,t.rects,o),e},{}),s=i[t.placement],l=s.x,d=s.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}function nr(e){var t=e.state,a=e.name;t.modifiersData[a]=za({reference:t.rects.reference,element:t.rects.popper,strategy:'absolute',placement:t.placement})}function or(e){return'x'===e?'y':'x'}function ir(e){var t=e.state,a=e.options,r=e.name,n=a.mainAxis,o=!(void 0!==n)||n,i=a.altAxis,s=void 0!==i&&i,l=a.boundary,d=a.rootBoundary,c=a.altBoundary,p=a.padding,u=a.tether,g=!(void 0!==u)||u,m=a.tetherOffset,f=void 0===m?0:m,y=Xa(t,{boundary:l,rootBoundary:d,padding:p,altBoundary:c}),h=ca(t.placement),_=qa(t.placement),v=!_,E=ba(h),T=or(E),b=t.modifiersData.popperOffsets,S=t.rects.reference,k=t.rects.popper,A='function'==typeof f?f(Io({},t.rects,{placement:t.placement})):f,R={x:0,y:0};if(b){if(o||s){var C='y'===E?Hy:qy,D='y'===E?Wy:Yy,L='y'===E?'height':'width',P=b[E],I=b[E]+y[C],x=b[E]-y[D],O=g?-k[L]/2:0,N=_===$y?S[L]:k[L],w=_===$y?-k[L]:-S[L],F=t.elements.arrow,M=g&&F?ga(F):{width:0,height:0},U=t.modifiersData['arrow#persistent']?t.modifiersData['arrow#persistent'].padding:ka(),B=U[C],G=U[D],j=Sa(0,S[L],M[L]),V=v?S[L]/2-O-j-B-A:N-j-B-A,K=v?-S[L]/2+O+j+G+A:w+j+G+A,H=t.elements.arrow&&Ta(t.elements.arrow),W=H?'y'===E?H.clientTop||0:H.clientLeft||0:0,Y=t.modifiersData.offset?t.modifiersData.offset[t.placement][E]:0,q=b[E]+V-Y-W,z=b[E]+K-Y;if(o){var X=Sa(g?yh(I,q):I,P,g?fh(x,z):x);b[E]=X,R[E]=X-P}if(s){var $='x'===E?Hy:qy,Q='x'===E?Wy:Yy,Z=b[T],J=Z+y[$],ee=Z-y[Q],te=Sa(g?yh(J,q):J,Z,g?fh(ee,z):ee);b[T]=te,R[T]=te-Z}}t.modifiersData[r]=R}}function sr(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function lr(e){return e!==na(e)&&ia(e)?sr(e):wa(e)}function dr(e,t,a){void 0===a&&(a=!1);var r=ha(t),n=pa(e),o=ia(t),i={scrollLeft:0,scrollTop:0},s={x:0,y:0};return!o&&(o||a)||(('body'!==ra(t)||Ba(r))&&(i=lr(t)),ia(t)?(s=pa(t),s.x+=t.clientLeft,s.y+=t.clientTop):r&&(s.x=Fa(r))),{x:n.left+i.scrollLeft-s.x,y:n.top+i.scrollTop-s.y,width:n.width,height:n.height}}function pr(e){function t(e){r.add(e.name);var o=[].concat(e.requires||[],e.requiresIfExists||[]);o.forEach(function(e){if(!r.has(e)){var n=a.get(e);n&&t(n)}}),n.push(e)}var a=new xu,r=new Ky,n=[];return e.forEach(function(e){a.set(e.name,e)}),e.forEach(function(e){r.has(e.name)||t(e)}),n}function ur(e){var t=pr(e);return gh.reduce(function(e,a){return e.concat(t.filter(function(e){return e.phase===a}))},[])}function gr(e){var t;return function(){return t||(t=new Xc(function(a){Xc.resolve().then(function(){t=void 0,a(e())})})),t}}function mr(e){var t=e.reduce(function(e,t){var a=e[t.name];return e[t.name]=a?Io({},a,t,{options:Io({},a.options,t.options),data:Io({},a.data,t.data)}):t,e},{});return Zs(t).map(function(e){return t[e]})}function fr(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return!t.some(function(e){return!(e&&'function'==typeof e.getBoundingClientRect)})}function yr(e){void 0===e&&(e={});var t=e,a=t.defaultModifiers,r=void 0===a?[]:a,n=t.defaultOptions,o=void 0===n?Ih:n;return function(e,t,a){function n(){s.orderedModifiers.forEach(function(e){var t=e.name,a=e.options,r=void 0===a?{}:a,n=e.effect;if('function'==typeof n){var o=n({state:s,name:t,instance:c,options:r}),i=function(){};l.push(o||i)}})}function i(){l.forEach(function(e){return e()}),l=[]}void 0===a&&(a=o);var s={placement:'bottom',orderedModifiers:[],options:Io({},Ih,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],d=!1,c={state:s,setOptions:function(a){i(),s.options=Io({},o,s.options,a),s.scrollParents={reference:oa(e)?ja(e):e.contextElement?ja(e.contextElement):[],popper:ja(t)};var l=ur(mr([].concat(r,s.options.modifiers)));return s.orderedModifiers=l.filter(function(e){return e.enabled}),n(),c.update()},forceUpdate:function(){if(!d){var e=s.elements,t=e.reference,a=e.popper;if(fr(t,a)){s.rects={reference:dr(t,Ta(a),'fixed'===s.options.strategy),popper:ga(a)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach(function(e){return s.modifiersData[e.name]=Io({},e.data)});for(var r=0;r<s.orderedModifiers.length;r++){if(!0===s.reset){s.reset=!1,r=-1;continue}var n=s.orderedModifiers[r],o=n.fn,i=n.options,l=void 0===i?{}:i,p=n.name;'function'==typeof o&&(s=o({state:s,options:l,name:p,instance:c})||s)}}}},update:gr(function(){return new Xc(function(e){c.forceUpdate(),e(s)})}),destroy:function(){i(),d=!0}};return fr(e,t)?(c.setOptions(a).then(function(e){!d&&a.onFirstUpdate&&a.onFirstUpdate(e)}),c):c}}function hr(e,t,a){if(Array.isArray(e)){var r=e[t];return null==r?Array.isArray(a)?a[t]:a:r}return e}function _r(e,t){var a={}.toString.call(e);return 0===a.indexOf('[object')&&-1<a.indexOf(t+']')}function vr(e,t){return'function'==typeof e?e.apply(void 0,t):e}function Er(e,t){if(0===t)return e;var a;return function(r){clearTimeout(a),a=setTimeout(function(){e(r)},t)}}function Tr(e){return e.split(/\s+/).filter(Boolean)}function br(e){return[].concat(e)}function Sr(e,t){-1===e.indexOf(t)&&e.push(t)}function kr(e){return e.filter(function(t,a){return e.indexOf(t)===a})}function Ar(e){return e.split('-')[0]}function Rr(e){return[].slice.call(e)}function Cr(e){return Zs(e).reduce(function(t,a){return void 0!==e[a]&&(t[a]=e[a]),t},{})}function Dr(){return document.createElement('div')}function Lr(e){return['Element','Fragment'].some(function(t){return _r(e,t)})}function Pr(e){return _r(e,'NodeList')}function Ir(e){return _r(e,'MouseEvent')}function xr(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function Or(e){return Lr(e)?[e]:Pr(e)?Rr(e):Array.isArray(e)?e:Rr(document.querySelectorAll(e))}function Nr(e,t){e.forEach(function(e){e&&(e.style.transitionDuration=t+'ms')})}function wr(e,t){e.forEach(function(e){e&&e.setAttribute('data-state',t)})}function Fr(e){var t=br(e),a=t[0],r;return(null==a||null==(r=a.ownerDocument)?void 0:r.body)?a.ownerDocument:document}function Mr(e,t){var a=t.clientX,r=t.clientY;return e.every(function(e){var t=e.popperRect,n=e.popperState,o=e.props,i=o.interactiveBorder,s=Ar(n.placement),l=n.modifiersData.offset;if(!l)return!0;var d='bottom'===s?l.top.y:0,c='top'===s?l.bottom.y:0,p='right'===s?l.left.x:0,u='left'===s?l.right.x:0,g=t.top-r+d>i,m=r-t.bottom-c>i,f=t.left-a+p>i,y=a-t.right-u>i;return g||m||f||y})}function Ur(e,t,a){['transitionend','webkitTransitionEnd'].forEach(function(r){e[t+'EventListener'](r,a)})}function Br(){Kh.isTouch||(Kh.isTouch=!0,window.performance&&document.addEventListener('mousemove',Gr))}function Gr(){var e=performance.now();20>e-Hh&&(Kh.isTouch=!1,document.removeEventListener('mousemove',Gr)),Hh=e}function jr(){var e=document.activeElement;if(xr(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function Vr(){document.addEventListener('touchstart',Br,Vh),window.addEventListener('blur',jr)}function Kr(e){var t=e.plugins||[],a=t.reduce(function(t,a){var r=a.name,n=a.defaultValue;return r&&(t[r]=void 0===e[r]?n:e[r]),t},{});return Io({},e,{},a)}function Hr(e,t){var a=t?Zs(Kr(Io({},Xh,{plugins:t}))):$h,r=a.reduce(function(t,a){var r=(e.getAttribute('data-tippy-'+a)||'').trim();if(!r)return t;if('content'===a)t[a]=r;else try{t[a]=JSON.parse(r)}catch(n){t[a]=r}return t},{});return r}function Wr(e,t){var a=Io({},t,{content:vr(t.content,[e])},t.ignoreAttributes?{}:Hr(e,t.plugins));return a.aria=Io({},Xh.aria,{},a.aria),a.aria={expanded:'auto'===a.aria.expanded?t.interactive:a.aria.expanded,content:'auto'===a.aria.content?t.interactive?null:'describedby':a.aria.content},a}function Yr(e,t){e[Zh()]=t}function qr(e){var t=Dr();return!0===e?t.className=Gh:(t.className=jh,Lr(e)?t.appendChild(e):Yr(t,e)),t}function zr(e,t){Lr(t.content)?(Yr(e,''),e.appendChild(t.content)):'function'!=typeof t.content&&(t.allowHTML?Yr(e,t.content):e.textContent=t.content)}function Xr(e){var t=e.firstElementChild,a=Rr(t.children);return{box:t,content:a.find(function(e){return e.classList.contains(Uh)}),arrow:a.find(function(e){return e.classList.contains(Gh)||e.classList.contains(jh)}),backdrop:a.find(function(e){return e.classList.contains(Bh)})}}function $r(e){function t(t,r){var n=Xr(a),o=n.box,i=n.content,s=n.arrow;r.theme?o.setAttribute('data-theme',r.theme):o.removeAttribute('data-theme'),'string'==typeof r.animation?o.setAttribute('data-animation',r.animation):o.removeAttribute('data-animation'),r.inertia?o.setAttribute('data-inertia',''):o.removeAttribute('data-inertia'),o.style.maxWidth='number'==typeof r.maxWidth?r.maxWidth+'px':r.maxWidth,r.role?o.setAttribute('role',r.role):o.removeAttribute('role'),(t.content!==r.content||t.allowHTML!==r.allowHTML)&&zr(i,e.props),r.arrow?s?t.arrow!==r.arrow&&(o.removeChild(s),o.appendChild(qr(r.arrow))):o.appendChild(qr(r.arrow)):s&&o.removeChild(s)}var a=Dr(),r=Dr();r.className=Mh,r.setAttribute('data-state','hidden'),r.setAttribute('tabindex','-1');var n=Dr();return n.className=Uh,n.setAttribute('data-state','hidden'),zr(n,e.props),a.appendChild(r),r.appendChild(n),t(e.props,e.props),{popper:a,onUpdate:t}}function Qr(e,t){function a(){var e=W.props.touch;return Array.isArray(e)?e:[e,0]}function r(){return'hold'===a()[0]}function n(){var e;return null!=(e=W.props.render)&&e.$$tippy}function o(){return Z||e}function i(){var e=o().parentNode;return e?Fr(e):document}function s(){return Xr(ee)}function l(e){return W.state.isMounted&&!W.state.isVisible||Kh.isTouch||X&&'focus'===X.type?0:hr(W.props.delay,e?0:1,Xh.delay)}function d(){ee.style.pointerEvents=W.props.interactive&&W.state.isVisible?'':'none',ee.style.zIndex=''+W.props.zIndex}function c(e,t,a){if(void 0===a&&(a=!0),ae.forEach(function(a){a[e]&&a[e].apply(void 0,t)}),a){var r;(r=W.props)[e].apply(r,t)}}function p(){var t=W.props.aria;if(t.content){var a='aria-'+t.content,r=ee.id,n=br(W.props.triggerTarget||e);n.forEach(function(e){var t=e.getAttribute(a);if(W.state.isVisible)e.setAttribute(a,t?t+' '+r:r);else{var n=t&&t.replace(r,'').trim();n?e.setAttribute(a,n):e.removeAttribute(a)}})}}function u(){if(!re&&W.props.aria.expanded){var t=br(W.props.triggerTarget||e);t.forEach(function(e){W.props.interactive?e.setAttribute('aria-expanded',W.state.isVisible&&e===o()?'true':'false'):e.removeAttribute('aria-expanded')})}}function g(){i().removeEventListener('mousemove',V),e_=e_.filter(function(e){return e!==V})}function m(e){if(!(Kh.isTouch&&(B||'mousedown'===e.type))&&!(W.props.interactive&&ee.contains(e.target))){if(o().contains(e.target)){if(Kh.isTouch)return;if(W.state.isVisible&&0<=W.props.trigger.indexOf('click'))return}else c('onClickOutside',[W,e]);!0===W.props.hideOnClick&&(W.clearDelayTimeouts(),W.hide(),U=!0,setTimeout(function(){U=!1}),!W.state.isMounted&&_())}}function f(){B=!0}function y(){B=!1}function h(){var e=i();e.addEventListener('mousedown',m,!0),e.addEventListener('touchend',m,Vh),e.addEventListener('touchstart',y,Vh),e.addEventListener('touchmove',f,Vh)}function _(){var e=i();e.removeEventListener('mousedown',m,!0),e.removeEventListener('touchend',m,Vh),e.removeEventListener('touchstart',y,Vh),e.removeEventListener('touchmove',f,Vh)}function v(e,t){T(e,function(){!W.state.isVisible&&ee.parentNode&&ee.parentNode.contains(ee)&&t()})}function E(e,t){T(e,t)}function T(e,t){function a(e){e.target===r&&(Ur(r,'remove',a),t())}var r=s().box;return 0===e?t():void(Ur(r,'remove',$),Ur(r,'add',a),$=a)}function b(t,a,r){void 0===r&&(r=!1);var n=br(W.props.triggerTarget||e);n.forEach(function(e){e.addEventListener(t,a,r),j.push({node:e,eventType:t,handler:a,options:r})})}function S(){r()&&(b('touchstart',A,{passive:!0}),b('touchend',C,{passive:!0})),Tr(W.props.trigger).forEach(function(e){'manual'!==e&&(b(e,A),'mouseenter'===e?b('mouseleave',C):'focus'===e?b(ua?'focusout':'blur',D):'focusin'===e?b('focusout',D):void 0)})}function k(){j.forEach(function(e){var t=e.node,a=e.eventType,r=e.handler,n=e.options;t.removeEventListener(a,r,n)}),j=[]}function A(e){var t=!1,a;if(!(!W.state.isEnabled||L(e)||U)){var r='focus'===(null==(a=X)?void 0:a.type);X=e,Z=e.currentTarget,u(),!W.state.isVisible&&Ir(e)&&e_.forEach(function(t){return t(e)}),'click'===e.type&&(0>W.props.trigger.indexOf('mouseenter')||M)&&!1!==W.props.hideOnClick&&W.state.isVisible?t=!0:N(e),'click'===e.type&&(M=!t),t&&!r&&w(e)}}function R(e){var t=e.target,a=o().contains(t)||ee.contains(t);if(!('mousemove'===e.type&&a)){var r=O().concat(ee).map(function(e){var t=e._tippy,a=null==(r=t.popperInstance)?void 0:r.state,r;return a?{popperRect:e.getBoundingClientRect(),popperState:a,props:F}:null}).filter(Boolean);Mr(r,e)&&(g(),w(e))}}function C(e){var t=L(e)||0<=W.props.trigger.indexOf('click')&&M;return t?void 0:W.props.interactive?void W.hideWithInteractivity(e):void w(e)}function D(e){0>W.props.trigger.indexOf('focusin')&&e.target!==o()||W.props.interactive&&e.relatedTarget&&ee.contains(e.relatedTarget)||w(e)}function L(e){return!!Kh.isTouch&&r()!==0<=e.type.indexOf('touch')}function P(){I();var t=W.props,a=t.popperOptions,r=t.placement,i=t.offset,l=t.getReferenceClientRect,d=t.moveTransition,c=n()?Xr(ee).arrow:null,p=l?{getBoundingClientRect:l,contextElement:l.contextElement||o()}:e,u=[{name:'offset',options:{offset:i}},{name:'preventOverflow',options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:'flip',options:{padding:5}},{name:'computeStyles',options:{adaptive:!d}},{name:'$$tippy',enabled:!0,phase:'beforeWrite',requires:['computeStyles'],fn:function(e){var t=e.state;if(n()){var a=s(),r=a.box;['placement','reference-hidden','escaped'].forEach(function(e){'placement'===e?r.setAttribute('data-placement',t.placement):t.attributes.popper['data-popper-'+e]?r.setAttribute('data-'+e,''):r.removeAttribute('data-'+e)}),t.attributes.popper={}}}}];n()&&c&&u.push({name:'arrow',options:{element:c,padding:3}}),u.push.apply(u,(null==a?void 0:a.modifiers)||[]),W.popperInstance=Fh(p,ee,Io({},a,{placement:r,onFirstUpdate:Q,modifiers:u}))}function I(){W.popperInstance&&(W.popperInstance.destroy(),W.popperInstance=null)}function x(){var e=W.props.appendTo,t=o(),a;a=W.props.interactive&&e===Xh.appendTo||'parent'===e?t.parentNode:vr(e,[t]),a.contains(ee)||a.appendChild(ee),P()}function O(){return Rr(ee.querySelectorAll('[data-tippy-root]'))}function N(e){W.clearDelayTimeouts(),e&&c('onTrigger',[W,e]),h();var t=l(!0),r=a(),n=r[0],o=r[1];Kh.isTouch&&'hold'===n&&o&&(t=o),t?Y=setTimeout(function(){W.show()},t):W.show()}function w(e){if(W.clearDelayTimeouts(),c('onUntrigger',[W,e]),!W.state.isVisible)return void _();if(!(0<=W.props.trigger.indexOf('mouseenter')&&0<=W.props.trigger.indexOf('click')&&0<=['mouseleave','mousemove'].indexOf(e.type)&&M)){var t=l(!1);t?q=setTimeout(function(){W.state.isVisible&&W.hide()},t):z=requestAnimationFrame(function(){W.hide()})}}var F=Wr(e,Io({},Xh,{},Kr(Cr(t)))),M=!1,U=!1,B=!1,G=!1,j=[],V=Er(R,F.interactiveDebounce),K=Jh++,H=kr(F.plugins),W={id:K,reference:e,popper:Dr(),popperInstance:null,props:F,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:H,clearDelayTimeouts:function(){clearTimeout(Y),clearTimeout(q),cancelAnimationFrame(z)},setProps:function(t){if(!W.state.isDestroyed){c('onBeforeUpdate',[W,t]),k();var a=W.props,r=Wr(e,Io({},W.props,{},t,{ignoreAttributes:!0}));W.props=r,S(),a.interactiveDebounce!==r.interactiveDebounce&&(g(),V=Er(R,r.interactiveDebounce)),a.triggerTarget&&!r.triggerTarget?br(a.triggerTarget).forEach(function(e){e.removeAttribute('aria-expanded')}):r.triggerTarget&&e.removeAttribute('aria-expanded'),u(),d(),te&&te(a,r),W.popperInstance&&(P(),O().forEach(function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)})),c('onAfterUpdate',[W,t])}},setContent:function(e){W.setProps({content:e})},show:function(){var e=W.state.isVisible,t=W.state.isDestroyed,a=!W.state.isEnabled,r=Kh.isTouch&&!W.props.touch,i=hr(W.props.duration,0,Xh.duration);if(!(e||t||a||r)&&!o().hasAttribute('disabled')&&(c('onShow',[W],!1),!1!==W.props.onShow(W))){if(W.state.isVisible=!0,n()&&(ee.style.visibility='visible'),d(),h(),W.state.isMounted||(ee.style.transition='none'),n()){var l=s(),g=l.box,m=l.content;Nr([g,m],0)}Q=function(){var e;if(W.state.isVisible&&!G){if(G=!0,void ee.offsetHeight,ee.style.transition=W.props.moveTransition,n()&&W.props.animation){var t=s(),a=t.box,r=t.content;Nr([a,r],i),wr([a,r],'visible')}p(),u(),Sr(t_,W),null==(e=W.popperInstance)?void 0:e.forceUpdate(),W.state.isMounted=!0,c('onMount',[W]),W.props.animation&&n()&&E(i,function(){W.state.isShown=!0,c('onShown',[W])})}},x()}},hide:function(){var e=!W.state.isVisi