module.exports=[429056,(a,b,c)=>{let d,e,f;var g=Object.create,h=Object.defineProperty,i=Object.getOwnPropertyDescriptor,j=Object.getOwnPropertyNames,k=Object.getPrototypeOf,l=Object.prototype.hasOwnProperty,m=(a,b,c,d)=>{if(b&&"object"==typeof b||"function"==typeof b)for(let e of j(b))l.call(a,e)||e===c||h(a,e,{get:()=>b[e],enumerable:!(d=i(b,e))||d.enumerable});return a},n=(a,b,c)=>{let d;return(d="symbol"!=typeof b?b+"":b)in a?h(a,d,{enumerable:!0,configurable:!0,writable:!0,value:c}):a[d]=c,c},o={},p={default:()=>x};for(var q in p)h(o,q,{get:p[q],enumerable:!0});b.exports=m(h({},"__esModule",{value:!0}),o);var r=(f=null!=(d=a.r(572131))?g(k(d)):{},m(!e&&d&&d.__esModule?f:h(f,"default",{value:d,enumerable:!0}),d)),s=a.r(187287),t=a.r(441795);let u=/[?&](?:list|channel)=([a-zA-Z0-9_-]+)/,v=/user\/([a-zA-Z0-9_-]+)\/?/,w=/youtube-nocookie\.com/;class x extends r.Component{constructor(){super(...arguments),n(this,"callPlayer",s.callPlayer),n(this,"parsePlaylist",a=>{if(a instanceof Array)return{listType:"playlist",playlist:a.map(this.getID).join(",")};if(u.test(a)){let[,b]=a.match(u);return{listType:"playlist",list:b.replace(/^UC/,"UU")}}if(v.test(a)){let[,b]=a.match(v);return{listType:"user_uploads",list:b}}return{}}),n(this,"onStateChange",a=>{let{data:b}=a,{onPlay:c,onPause:d,onBuffer:e,onBufferEnd:f,onEnded:g,onReady:h,loop:i,config:{playerVars:j,onUnstarted:k}}=this.props,{UNSTARTED:l,PLAYING:m,PAUSED:n,BUFFERING:o,ENDED:p,CUED:q}=window.YT.PlayerState;if(b===l&&k(),b===m&&(c(),f()),b===n&&d(),b===o&&e(),b===p){let a=!!this.callPlayer("getPlaylist");i&&!a&&(j.start?this.seekTo(j.start):this.play()),g()}b===q&&h()}),n(this,"mute",()=>{this.callPlayer("mute")}),n(this,"unmute",()=>{this.callPlayer("unMute")}),n(this,"ref",a=>{this.container=a})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}getID(a){return!a||a instanceof Array||u.test(a)?null:a.match(t.MATCH_URL_YOUTUBE)[1]}load(a,b){let{playing:c,muted:d,playsinline:e,controls:f,loop:g,config:h,onError:i}=this.props,{playerVars:j,embedOptions:k}=h,l=this.getID(a);b?u.test(a)||v.test(a)||a instanceof Array?this.player.loadPlaylist(this.parsePlaylist(a)):this.player.cueVideoById({videoId:l,startSeconds:(0,s.parseStartTime)(a)||j.start,endSeconds:(0,s.parseEndTime)(a)||j.end}):((0,s.getSDK)("https://www.youtube.com/iframe_api","YT","onYouTubeIframeAPIReady",a=>a.loaded).then(b=>{this.container&&(this.player=new b.Player(this.container,{width:"100%",height:"100%",videoId:l,playerVars:{autoplay:+!!c,mute:+!!d,controls:+!!f,start:(0,s.parseStartTime)(a),end:(0,s.parseEndTime)(a),origin:window.location.origin,playsinline:+!!e,...this.parsePlaylist(a),...j},events:{onReady:()=>{g&&this.player.setLoop(!0),this.props.onReady()},onPlaybackRateChange:a=>this.props.onPlaybackRateChange(a.data),onPlaybackQualityChange:a=>this.props.onPlaybackQualityChange(a),onStateChange:this.onStateChange,onError:a=>i(a.data)},host:w.test(a)?"https://www.youtube-nocookie.com":void 0,...k}))},i),k.events&&console.warn("Using `embedOptions.events` will likely break things. Use ReactPlayer’s callback props instead, eg onReady, onPlay, onPause"))}play(){this.callPlayer("playVideo")}pause(){this.callPlayer("pauseVideo")}stop(){document.body.contains(this.callPlayer("getIframe"))&&this.callPlayer("stopVideo")}seekTo(a,b=!1){this.callPlayer("seekTo",a),b||this.props.playing||this.pause()}setVolume(a){this.callPlayer("setVolume",100*a)}setPlaybackRate(a){this.callPlayer("setPlaybackRate",a)}setLoop(a){this.callPlayer("setLoop",a)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return this.callPlayer("getVideoLoadedFraction")*this.getDuration()}render(){let{display:a}=this.props;return r.default.createElement("div",{style:{width:"100%",height:"100%",display:a}},r.default.createElement("div",{ref:this.ref}))}}n(x,"displayName","YouTube"),n(x,"canPlay",t.canPlay.youtube)}];

//# sourceMappingURL=node_modules_react-player_lazy_players_YouTube_f9abad15.js.map