var __webpack_modules__={25:(t,e,r)=>{r.d(e,{appHostname:()=>i});var i=function(){return"".concat(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"app",".").concat("wistia.com")}},515:(t,e,r)=>{r.d(e,{default:()=>n});var i=r(3);null==i.default.engines&&(i.default.engines={});const n=function(t,e){i.default.engines[t]=e}},493:(t,e,r)=>{r.d(e,{setup:()=>l,teardown:()=>u});var i=r(492),n=r(494),s=r(26),a=(0,n.makeCacheable)("bandwidth_tracking"),o=(0,n.makeNamespace)("bandwidth_tracking"),l=function(t){var e=t.hls,r=a(t,"persistBandwidthEstimate",(function(){return function(){var t=e.abrController.bwEstimator.getEstimate();(0,s.setOrGet)("hls.bandwidth_estimate",t)}}));e.off(i.default.Events.FRAG_LOADED,r),e.on(i.default.Events.FRAG_LOADED,r)},u=function(t){o(t).persistBandwidthEstimate&&t.hls&&t.hls.off(i.default.Events.FRAG_LOADED,o(t).persistBandwidthEstimate),(0,n.uncacheNamespace)("bandwidth_tracking",t)}},518:(t,e,r)=>{r.d(e,{default:()=>S});var i=r(492),n=r(33);function s(t,e){for(var r=0;ro?o:t{r.d(e,{default:()=>T});var i=r(492),n=r(33);function s(t,e){for(var r=0;r0&&this.mediaWidth>0){var t=p(this,y,E).call(this,this.hls.autoLevelCapping);t!==this.hls.autoLevelCapping&&(this.hls.autoLevelCapping=t)}}}])&&s(e.prototype,r),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),a}(v);function E(t){if(!this.hls.levels||0===this.hls.levels.length)return t;var e=this.hls.config.qualityMin||0,r=this.hls.config.qualityMax||5e3,i=(0,n.findClosestAssetByQuality)(this.hls.levels,e),s=this.hls.levels.indexOf(i),a=(0,n.findClosestAssetByQuality)(this.hls.levels,r),o=this.hls.levels.indexOf(a);return t>o?o:t>=0&&t{r.d(e,{setup:()=>u,teardown:()=>h});var i=r(492),n=r(12),s=r(494),a=n.wlog.getPrefixedFunctions("hls_video"),o=(0,s.makeCacheable)("dynamic_max_max_buffer"),l=(0,s.makeNamespace)("dynamic_max_max_buffer"),u=function(t){var e=t.hls,r=o(t,"onFragLoaded",(function(){return function(){c(t)}}));e.off(i.default.Events.FRAG_LOADED,r),e.on(i.default.Events.FRAG_LOADED,r)},c=function(t){var e=t.hls;t.attributes.maxMaxBufferLength&&(e.config.maxMaxBufferLength=t.attributes.maxMaxBufferLength);var r=e.levels[e.currentLevel];r&&e.abrController.bwEstimator.getEstimate()*e.config.abrBandWidthFactor=0||0===e.currentLevel?(a.info("set maxMaxBufferLength",t.getDuration()),e.config.maxMaxBufferLength=t.getDuration()):(a.info("set maxMaxBufferLength",60),e.config.maxMaxBufferLength=60))},h=function(t){l(t).onFragLoaded&&t.hls&&t.hls.off(i.default.Events.FRAG_LOADED,l(t).onFragLoaded),(0,s.uncacheNamespace)("dynamic_max_max_buffer",t)}},496:(t,e,r)=>{r.d(e,{setup:()=>f,teardown:()=>k});var i=r(492),n=r(30),s=r(6),a=r(12),o=r(29),l=r(494),u=(0,l.makeCacheable)("error_handling"),c=(0,l.makeNamespace)("error_handling"),h=a.wlog.getPrefixedFunctions("hls error_handling"),d=0,f=function(t){var e=u(t,"onError",(function(){return function(e,r){g(t,e,r)}}));t.hls.on(i.default.Events.ERROR,e);var r=u(t,"onEmergencyAbortLoad",(function(){return function(){y(t)}}));t.hls.on(i.default.Events.FRAG_LOAD_EMERGENCY_ABORTED,r)},g=function(t,e,r){r.fatal?m(t,e,r):p(t,e,r),t.attributes.liveMedia&&E(t,"live_stream/play/hls/errors")},m=function(t,e,r){var s,o,l=t.hls,u=t.attributes;switch(d+=1,r.type){case i.default.ErrorTypes.NETWORK_ERROR:a.wlog.info("hlsjsplugin - Fatal network error encountered, try to recover"),l.startLoad(),y(t);break;case i.default.ErrorTypes.MEDIA_ERROR:a.wlog.info("hlsjsplugin - Fatal media error encountered, try to recover"),c(t).countedRecoverMediaError||(c(t).countedRecoverMediaError=!0,T(t,"player/hls/recover_media_error")),t.isChangingVideo()||r.details===i.default.ErrorDetails.BUFFER_STALLED_ERROR&&l.startLoad(),h.error("trying to recover from media error..."),s=t.getCurrentTime(),3===d?((0,n.clearTimeouts)("".concat(t.uuid,".nudge_if_not_playing")),l.destroy(),t.trigger("fatalerrorrebuild")):(l.recoverMediaError(),o=null!=u.bufferStallRecoveryTimeout?u.bufferStallRecoveryTimeout:1e3,(0,n.doTimeout)("".concat(t.uuid,".nudge_if_not_playing"),(function(){"playing"!==t.getPlaybackMode()?(h.error("trying to nudge 0.5 seconds..."),t.seek(t.getCurrentTime()+.5).then((function(){t.play()}))):t.getCurrentTime()!==s&&h.error("video is playing; recoverMediaError() succeeded")}),o));break;default:T(t,"player/playback-error"),T(t,"player/hls/fatal",1,{at:t.getCurrentTime(),data:r}),a.wlog.info("hlsjsplugin - Fatal error - cannot recover",e,r),l.destroy()}},p=function(t,e,r){a.wlog.info("hlsjsplugin - Non fatal error encountered - ".concat(r.details),r),r.details===i.default.ErrorDetails.BUFFER_SEEK_OVER_HOLE?E(t,"player/hls/buffer_seek_over_hole",{hole:r.hole}):r.details===i.default.ErrorDetails.BUFFER_STALLED_ERROR?t.getCurrentTime()>0&&E(t,"player/hls/buffer_stalled"):r.details===i.default.ErrorDetails.INTERNAL_EXCEPTION?E(t,"player/hls/non-fatal/".concat(r.details),{errorDetails:r}):E(t,"player/hls/non-fatal/".concat(r.details))},v=[100,500,1500,3e3,6e3],y=function(t){for(var e=function(){var e=t.hls;e&&e.startLoad()},r=0;r1&&void 0!==arguments[1]?arguments[1]:{},r={hlsVideo:t.diagnosticData()};return r.locationHref=location.href,top!==self&&(r.referrer=document.referrer,r.inIframe=!0),(0,s.merge)(r,e)},k=function(t){c(t).onError&&t.hls&&t.hls.off(i.default.Events.ERROR,c(t).onError),c(t).onEmergencyAbortLoad&&t.hls&&t.hls.off(i.default.Events.ERROR,c(t).onEmergencyAbortLoad),(0,l.uncacheNamespace)("error_handling",t)}},215:(t,e,r)=>{r.d(e,{adaptiveAssetUrl:()=>a,allHlsAudioAssets:()=>l,allMp4VideoAssets:()=>u,audioTracksForVideo:()=>c,buildMasterM3u8Asset:()=>h,rejectAudioAsset:()=>d});var i=r(33),n=r(6),s=r(23),a=function(t,e){return t.attributes.liveMedia?t.mediaData.liveStreamEventDetails.manifestUrl:o(t,e)},o=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.mediaData.hashedId,i=t.attributes,n=i.clipForPoster,a=i.clipTo,o=i.clipFrom,l=i.password,u=i.startPosition,c=i.deliveryCdn,h=i.qualityMax,d=i.qualityMin,f=e.qualityMin||d,g=e.qualityMax||h,m=new URL("".concat((0,s.eV1Protocol)(),"//").concat((0,s.cdnFastWistiaComHost)(t.attributes.embedHost),"/embed/medias/").concat(r,".m3u8"));return"HlsVideo"!==(null==t?void 0:t.name)&&(f&&m.searchParams.set("quality_min",f),g&&m.searchParams.set("quality_max",g)),c&&m.searchParams.set("delivery_cdn",c),u&&-1!==u&&m.searchParams.set("start_position",u),n&&null!=o&&a&&(m.searchParams.set("clip_to",a),m.searchParams.set("clip_from",o)),l&&m.searchParams.set("password",l),m.toString()},l=function(t){return(0,i.filter)(t,{type:"mp4_alternate_audio",status:i.READY})},u=function(t){return(0,i.filter)(t,{container:"mp4",status:i.READY,public:!0,metadata:function(t){return Object(t).max_bitrate},type:/\b(?!captioned_video)\S+/}).sort((function(t,e){return(t.metadata.max_bitrate||0)-(e.metadata.max_bitrate||0)}))},c=function(t){var e=[{audioCodec:void 0,autoselect:!0,default:!0,forced:!1,groupId:"audio",id:0,lang:void 0,name:"Off",label:"Off",type:"AUDIO",isSelected:!0}];return t.forEach((function(t,r){var i,n;e.push({audioCodec:void 0,autoselect:!1,default:!1,forced:!1,groupId:"audio",id:r+1,lang:void 0,name:(null===(i=t.details)||void 0===i?void 0:i.languageMetadata.name)||"Alt Audio",label:(null===(n=t.details)||void 0===n?void 0:n.languageMetadata.name)||"Alt Audio",type:"AUDIO",isSelected:!1})})),e},h=function(t){return{bitrate:"variable",ext:"m3u8",height:"variable",public:!0,size:"variable",type:"hls_video",url:t,width:"variable",slug:"hls_master_m3u8_seg3s"}},d=function(t,e){return(0,n.filter)(e,(function(t){return"Audio"!=t.display_name}))}},517:(t,e,r)=>{r.d(e,{assetToLevel:()=>c,bestStartingLevel:()=>f,deliveryUrlToLevel:()=>h,filteredHlsAssets:()=>g,levelToAsset:()=>m,startLoadOnce:()=>p,stopLoad:()=>y,teardown:()=>T});var i=r(33),n=r(6),s=r(494),a=r(215),o=(0,s.makeNamespace)("asset_to_level"),l=(0,s.makeNamespace)("level_to_asset"),u=function(t){if(t){var e=t.match(/deliveries\/(.*?)(?=\.)/);return e&&e[1]?e[1]:void 0}},c=function(t,e){return h(t,e.url)},h=function(t,e){var r,i=u(e);if(null!=(r=o(t)[i]))return r;if(!t.hls||!t.hls.levels)return-1;var s=(0,n.filter)(t.hls.levels,(function(t){return u(t.url[0])===i}))[0],a=t.hls.levels.indexOf(s);return s&&(o(t)[i]=a),a},d=function(t){if(t.attrs.BANDWIDTH)return Number(t.attrs.BANDWIDTH)},f=function(t){return v(t)?v(t):-1!==t.hls.autoLevelCapping?t.hls.autoLevelCapping:t.hls.levels.length-1},g=function(t,e){var r=e,n=t.attributes,s=n.qualityMin,o=n.qualityMax;s>0&&(r=a.rejectAudioAsset(t,r));var l=(0,i.withinQualityRange)(r,s,o);return r=l.length>0?l:(0,i.nearestOutsideRange)(r,s,o)},m=function(t,e){var r;if(null!=(r=l(t)[e]))return r;var i=(0,n.getDeep)(t.hls.levels,[e,"url",0]),s=u(i),a=(0,n.filter)(t.allAssets,(function(t){if(t.url){var e=u(t.url);return s===e}}))[0];return l(t)[e]=a,a},p=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1;t.attributes.calledStartLoad||(t.onReady().then((function(){t.hls.startLoad(e)})),t.setAttributes({calledStartLoad:!0}))},v=function(t){var e=t.attributes,r=e.qualityMin,n=void 0===r?100:r,s=e.qualityMax,a=void 0===s?1e4:s,o=e.bwEstimateOnInit;if(o&&t.hls.levels){for(var l,u,c=t.hls.autoLevelCapping||t.hls.levels.length-1,h=0;h<=c;h++){var f=t.hls.levels[h],g=(u=f).attrs.AVERAGE_BANDWIDTH?Number(u.attrs.AVERAGE_BANDWIDTH):d(u),m=(0,i.numericSizeSnapped)(f.width,f.height);n<=m&&m<=a&&g<99999999999&&g{r.d(e,{default:()=>P});var i=r(492),n=r(33),s=r(6),a=r(12),o=r(20),l=r(26),u=r(29),c=r(493),h=r(495),d=r(496),f=r(215),g=r(497),m=r(498),p=r(515),v=r(506),y=r(21),T=r(517),E=r(518),b=r(519);function S(t,e){for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:t,r=(0,n.withinQualityRange)(this.allAssets,t,e);return 0===r.length&&(r=(0,n.nearestOutsideRange)(this.allAssets,t,e)),r[0]}},{key:"changeAudioTrack",value:function(t){var e=this;return new Promise((function(r){var n="beforeplay"===e.getPlaybackMode(),s=e.getCurrentAudioTrack().id;n||s===t||e.hls.once(i.default.Events.AUDIO_TRACK_SWITCHED,(function(){r()})),e.hls.audioTracks[t]&&s!==t?(e.hls.audioTrack=t,"beforeplay"===e.getPlaybackMode()&&r()):r()}))}},{key:"changeLevel",value:function(t){var e=this;this.hls.currentLevel!==t&&this.hls.startLevel!==t&&(this.hls.startLevel=t),"playing"===this.getPlaybackMode()&&-1!==t&&(this.hls.once(i.default.Events.LEVEL_SWITCHED,(function(){e.play()})),this.pause()),this.hls.currentLevel!==t&&(this.hls.currentLevel=t)}},{key:"changeQuality",value:function(t,e,r){if("auto"===t.toString().toLowerCase())return this.changeStream(-1,e,r);var i=(0,n.findClosestAssetByQuality)(this.hls.levels,t),s=(0,T.deliveryUrlToLevel)(this,i.url[0]);return this.changeStream(s,e,r)}},{key:"changeStream",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return this.changeLevel(t),e?this.play():Promise.resolve()}},{key:"changeStreamWithoutLoad",value:function(t){if((0,T.assetToLevel)(this,t)!==this.hls.currentLevel){var e=(0,T.assetToLevel)(this,t);this.stopLoad(),this.changeLevel(e)}}},{key:"changeVideo",value:function(t,e){var r=this;return new Promise((function(i){r.mediaData=null,r.allAssets=[],r.attributes={},r.state={},r.state.isChangingVideo=!0,r._bindings={},r.destroyHls(),(0,v.teardownBeforeChangeVideo)(r.simpleVideo),r.mediaData=t,r.allAssets=t.assets,r.attributes=e,(0,v.initAfterChangeVideo)(r.simpleVideo,t,e),r.setAttributes({bwEstimateOnInit:(0,l.setOrGet)("hls.bandwidth_estimate")}),r.setupHls(),r.state.isChangingVideo=!1,i()}))}},{key:"currentLevel",value:function(){return this.hls.currentLevel}},{key:"currentAsset",value:function(){return this.hls.currentLevel>=0?(0,T.levelToAsset)(this,this.hls.currentLevel)||this.adaptiveAsset():null!=this.hls.startLevel&&this.hls.startLevel>=0&&(0,T.levelToAsset)(this,this.hls.startLevel)||this.adaptiveAsset()}},{key:"defaultAttributes",value:function(){return{contentType:"video/m3u8",qualityMin:360,qualityMax:2160,preload:"metadata"}}},{key:"destroy",value:function(){return this._bindings={},this.destroyHls(),this.simpleVideo.destroy()}},{key:"destroyHls",value:function(){var t=this,e=function(t){try{return t()}catch(t){D.error(t)}};e((function(){d.teardown(t)})),e((function(){c.teardown(t)})),e((function(){h.teardown(t)})),e((function(){g.teardown(t)})),e((function(){(0,T.teardown)(t)})),this.hls&&(this.hls.destroy(),this.hls=null)}},{key:"determineMinAutoBitrate",value:function(){var t=this.hlsAssetFromQuality(360,1080);return t&&t.metadata&&t.metadata.max_bitrate?t.metadata.max_bitrate-1:6e5}},{key:"diagnosticData",value:function(){var t=this,e=function(t){try{return t()}catch(t){return"ERROR: ".concat(t.message)}},r={simpleVideo:this.simpleVideo.diagnosticData(),attributes:this.attributes,currentLevel:e((function(){return t.currentLevel()})),startLevel:e((function(){return t.hls.startLevel})),nextLevel:e((function(){return t.hls.nextLevel})),loadLevel:e((function(){return t.hls.loadLevel})),autoLevel:e((function(){return t.hls.autoLevel})),autoLevelCapping:e((function(){return t.hls.autoLevelCapping})),nextAutoLevel:e((function(){return t.hls.nextAutoLevel})),manualLevel:e((function(){return t.hls.manualLevel})),bandwidthEstimate:e((function(){return t.hls.abrController.bwEstimator.getEstimate()}))};return this.hls.currentLevel&&(r.currentAsset=(0,T.levelToAsset)(this,this.hls.currentLevel)),"auto"!==this.selectedQuality()&&this.hls.manualLevel>-1&&(r.selectedAsset=(0,T.levelToAsset)(this,this.hls.manualLevel)),r}},{key:"filteredVideoAssets",value:function(){var t=f.allMp4VideoAssets(this.allAssets);return(0,T.filteredHlsAssets)(this,t)}},{key:"getAudioTracks",value:function(){var t,e=this,r=this.m3u8AudioAssets();return(null===(t=this.hls)||void 0===t?void 0:t.audioTracks.length)>0?this.hls.audioTracks.map((function(t,i){var n=r[i-1];return t.isSelected=i===e.getHlsAudioTrackId(),t.label=null==n?void 0:n.details.languageMetadata.nativeName,0===i&&(t.label="Original"),t})):f.audioTracksForVideo(r)}},{key:"getCurrentAudioTrack",value:function(){this.loadForAudioTracks();var t=this.getHlsAudioTrackId(),e=this.hls.audioTracks[t];return e.isSelected=!0,e}},{key:"getCurrentAudioTrackId",value:function(){return this.getCurrentAudioTrack().id}},{key:"getCurrentQuality",value:function(){var t=this.hls.currentLevel>=0?this.hls.currentLevel:this.hls.startLevel,e=this.hls.levels[t];return e?e?(0,n.numericSizeSnapped)(e.width,e.height):"?":"auto"}},{key:"getCurrentTime",value:function(){var t;if(!this.attributes.liveMedia||!w(this,I)||null===(t=this.mediaData.liveStreamEventDetails)||void 0===t||!t.m3u8RenditionProgramTime)return this.simpleVideo.getCurrentTime();var e=new Date(this.mediaData.liveStreamEventDetails.m3u8RenditionProgramTime).getTime();return(w(this,I)-e)/1e3+this.simpleVideo.getCurrentTime()}},{key:"getHlsAudioTrackId",value:function(){return-1===this.hls.audioTrack?0:this.hls.audioTrack}},{key:"getMaxMaxBufferLengthForConfig",value:function(){switch(this.attributes.preload){case"auto":case!0:return 27;case"metadata":return 1;default:return 60}}},{key:"hlsAssetFromQuality",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,r=(0,n.withinQualityRange)(this.filteredVideoAssets(),t,e);return 0===r.length&&(r=(0,n.nearestOutsideRange)(this.filteredVideoAssets(),t,e)),r[0]}},{key:"isChangingVideo",value:function(){return!!this.state.isChangingVideo}},{key:"loadForAudioTracks",value:function(){0===this.hls.audioTracks.length&&this.startHlsLoadOnce()}},{key:"liveConfig",value:function(){return{abrBandWidthFactor:1.1,abrBandWidthUpFactor:1.4,abrEwmaDefaultEstimate:this.attributes.bwEstimateOnInit,testBandwidth:!1,autoStartLoad:!1,debug:{log:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},error:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},warn:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},info:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},debug:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))}},maxBufferSize:6e7,maxFragLookUpTolerance:.2,maxMaxBufferLength:this.attributes.maxMaxBufferLength||60,seekHoleNudgeDuration:.1}}},{key:"loadSource",value:function(){var t=this.adaptiveAsset();this.hls.loadSource(t.url)}},{key:"m3u8AudioAssets",value:function(){return f.allHlsAudioAssets(this.allAssets)}},{key:"onEnterFullscreen",value:function(){this.simpleVideo.onEnterFullscreen(),"beforeplay"!==this.getPlaybackMode()&&this.changeLevel(-1)}},{key:"onHeightChange",value:function(t){this.simpleVideo.onHeightChange(t),this.setAttributes({height:t})}},{key:"onMediaDataChanged",value:function(t){this.mediaData=t}},{key:"onReady",value:function(){var t=this;return this.readyPromise||(this.readyPromise=this.simpleVideo.onReady().then((function(){return Promise.all([t.mediaAttachedPromise,t.manifestParsedPromise])}))),this.readyPromise}},{key:"onWidthChange",value:function(t){this.simpleVideo.onWidthChange(t),this.setAttributes({width:t})}},{key:"play",value:function(t){var e=this;return this.hls.config.autoStartLoad||this.startHlsLoadOnce(),this.hls.config.maxMaxBufferLength=60,this.attributes.liveMedia?((0,u.count)("live_stream/play",1,{hashed_id:this.attributes.hashedId}),this.setCurrentTimeToLiveEdge().then((function(){return e.simpleVideo.play(t)}))):this.simpleVideo.play(t)}},{key:"qualityForLevel",value:function(t){if(-1===t)return"auto";var e=this.hls.levels[t];return(0,n.numericSizeSnapped)(e.width,e.height)}},{key:"qualityMax",value:function(t){this.hls.config&&(this.hls.config.qualityMax=t)}},{key:"qualityMin",value:function(t){this.hls.config&&(this.hls.config.qualityMin=t)}},{key:"removeSourceElem",value:function(){var t=this.getMediaElement(),e=Array.prototype.slice.call(t.childNodes);e.length>0&&e.forEach((function(e){t.removeChild(e)}))}},{key:"removeTextTracks",value:function(){}},{key:"reset",value:function(){this.simpleVideo.reset()}},{key:"seek",value:function(t,e){return this.startHlsLoadOnce(t),this.simpleVideo.seek(t,e)}},{key:"selectableQualities",value:function(){var t=this,e=this.hls.levels.map((function(e,r){return t.qualityForLevel(r)}));return[this.qualityForLevel(-1)].concat(e)}},{key:"selectedQuality",value:function(){return this.hls.manualLevel>=0?this.qualityForLevel(this.hls.manualLevel):"auto"}},{key:"setAttributes",value:function(t){return(0,s.assign)(this.attributes,t),this.simpleVideo.setAttributes(t)}},{key:"setCurrentTimeToLiveEdge",value:function(){return"beforeplay"!==this.getPlaybackMode()?this.seek(this.hls.liveSyncPosition):Promise.resolve()}},{key:"setupEventListeners",value:function(){var t=this;this.manifestParsedPromise=new Promise((function(e){t.hls.on(i.default.Events.MANIFEST_PARSED,e)})),this.mediaAttachedPromise=new Promise((function(e){t.hls.on(i.default.Events.MEDIA_ATTACHED,e)})),this.hls.on(i.default.Events.AUDIO_TRACKS_UPDATED,(function(){t.trigger("audiotracksupdated")})),this.hls.on(i.default.Events.LEVEL_SWITCHED,(function(e,r){var i=(0,T.levelToAsset)(t,r.level);t.trigger("hlslevelswitched",{asset:i})})),this.hls.once(i.default.Events.LEVEL_LOADED,(function(e,r){var i,n,s;k(t,I,null===(i=r.details)||void 0===i||null===(n=i.fragments)||void 0===n||null===(s=n[0])||void 0===s?void 0:s.programDateTime)}))}},{key:"setupHls",value:function(){this.attributes.liveMedia?this.setupLiveHls():this.setupVodHls()}},{key:"setupLiveHls",value:function(){var t=this,e=this.liveConfig();this.hls=new i.default(e),g.setup(this),this.setupEventListeners(),this.hls.attachMedia(this.simpleVideo.getMediaElement()),this.removeSourceElem(),c.setup(this),d.setup(this),this.pollForLiveStream().then((function(){t.loadSource(),t.onReady().then((function(){t.trigger("livestreamready")}))}))}},{key:"setupVodHls",value:function(){var t=this,e=this.vodConfig();this.hls=new i.default(e),g.setup(this),this.loadSource(),this.setupEventListeners(),this.hls.attachMedia(this.simpleVideo.getMediaElement()),this.removeSourceElem(),h.setup(this),d.setup(this),c.setup(this),this.hls.once(i.default.Events.MANIFEST_PARSED,(function(){t.hls.startLevel=(0,T.bestStartingLevel)(t)}))}},{key:"selectedAsset",value:function(){if(0!==this.hls.levels.length)return this.hls.currentLevel?this.hls.levels[this.hls.currentLevel]:this.hls.levels[this.hls.startLevel]}},{key:"showFirstFrame",value:function(){return this.seek(.01)}},{key:"startHlsLoadOnce",value:function(t){var e=t||this._startPosition;(0,T.startLoadOnce)(this,e)}},{key:"stopLoad",value:function(){(0,T.stopLoad)(this)}},{key:"updateStartPosition",value:function(t){this.hls.config.startPosition!==t&&(this.attributes.startPosition=t,this._startPosition=t,this.hls.config.startPosition=t,this.hls&&this.loadSource())}},{key:"vodConfig",value:function(){return{abrBandWidthFactor:1.1,abrBandWidthUpFactor:1.4,abrController:E.default,abrEwmaFastVoD:4,abrEwmaSlowVoD:15,autoStartLoad:"none"!==this.attributes.preload&&!1!==this.attributes.preload,capLevelToPlayerSize:!0,capLevelController:b.default,debug:{log:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},error:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},warn:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},info:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))},debug:function(){for(var t=arguments.length,e=new Array(t),r=0;r"].concat(e))}},maxBufferSize:6e7,maxFragLookUpTolerance:.2,maxMaxBufferLength:this.getMaxMaxBufferLengthForConfig(),minAutoBitrate:this.determineMinAutoBitrate(),seekHoleNudgeDuration:.1,startPosition:this._startPosition,qualityMin:this.attributes.qualityMin||360,qualityMax:this.attributes.qualityMax||2160}}}],r&&S(e.prototype,r),p&&S(e,p),Object.defineProperty(e,"prototype",{writable:!1}),t}();_(C.prototype,(function(){return this.simpleVideo})),(0,p.default)("HlsVideo",C);const P=C},497:(t,e,r)=>{r.d(e,{setup:()=>u,teardown:()=>c});var i=r(492),n=r(12),s=r(494),a=n.wlog.getPrefixedFunctions("hls_video"),o=(0,s.makeCacheable)("track_stream_changes"),l=(0,s.makeNamespace)("track_stream_changes"),u=function(t){var e=t.hls;l(t).lastLevel=null,l(t).lastAutoLevel=null,l(t).substreamIndex=0;var r=o(t,"onFragChanged",(function(){return function(e,r){if(r.frag.level!==t._lastLevel||r.frag.autoLevel!=t._lastAutoLevel){var i=t.hls.levels[r.frag.level];l(t).lastLevel=r.frag.level,l(t).lastAutoLevel=r.frag.autoLevel,l(t).substreamIndex+=1,r.frag.level>=0?a.notice("frag switch to",i,"at",t.getCurrentTime()):a.notice("frag switch to Auto at",t.getCurrentTime())}}}));e.off(i.default.Events.FRAG_CHANGED,r),e.on(i.default.Events.FRAG_CHANGED,r);var n=o(t,"onAudioSwitching",(function(){return function(e,r){t.trigger("audiostreamchange"),r.id>0?a.notice("audio asset switch to track: ",r.id,"at",t.lastBufferedTime()):a.notice("level switch to original encoded audio at",t.lastBufferedTime())}}));e.off(i.default.Events.AUDIO_TRACK_SWITCHING,n),e.on(i.default.Events.AUDIO_TRACK_SWITCHING,n);var s=o(t,"onLevelSwitching",(function(){return function(e,r){if(r.level>=0){var i=t.hls.levels[r.level];a.notice("level switch to",i,"at",t.lastBufferedTime())}else a.notice("level switch to Auto at",t.lastBufferedTime())}}));e.off(i.default.Events.LEVEL_SWITCHING,s),e.on(i.default.Events.LEVEL_SWITCHING,s)},c=function(t){l(t).onFragChanged&&t.hls&&t.hls.off(i.default.Events.FRAG_CHANGED,l(t).onFragChanged),l(t).onLevelSwitch&&t.hls&&t.hls.off(i.default.Events.LEVEL_SWITCHING,l(t).onLevelSwitching),(0,s.uncacheNamespace)("track_stream_changes",t)}},514:(t,e,r)=>{r.d(e,{PUBLIC_METHODS:()=>i,delegatePublicMethods:()=>n});var i=["activeBufferRange","addTextTracks","anyBuffered","bind","bindNamed","bufferInfo","canDownloadMedia","cancelFullscreen","captureCurrentFrame","changeQuality","changeStream","changeStreamWithoutLoad","changeVideo","currentAsset","defaultAsset","destroy","diagnosticData","eventContext","fit","getAudioTracks","getCurrentQuality","getCurrentTime","getCuts","getDuration","getDurationBeforeCuts","getMediaElement","getMediaType","getPlaybackMode","getPlaybackRate","getPreload","getState","getTimeAfterCuts","getTimeBeforeCuts","getTrim","getVolume","hasIssuedPlay","isChangingVideo","isInitializingFromUnmuted","isInFullscreen","isMuted","isSeeking","isSourceOfBrowserEvent","lastBufferedTime","mute","onEnterFullscreen","onHeightChange","onLeaveFullscreen","onMediaDataChanged","onPlayed","onReady","onWidthChange","pause","play","playType","removeTextTracks","requestFullscreen","reset","seek","seekOnPlay","selectedAsset","selectableAssets","selectableQualities","selectedQuality","sequentialBufferedRange","setAttributes","setCurrentTime","setPlaybackRate","setCuts","setTrim","setVolume","showFirstFrame","stopStreaming","timeBeforeEndOfBuffer","totalBuffered","totalPlayed","trigger","unbind","unbindNamed","unbindAllInNamespace","unmute","updateStartPosition"],n=function(t,e){!function(t,e,r){for(var i=0;i{r.d(e,{activeBufferRange:()=>o,anyBuffered:()=>a,lastBufferedTime:()=>c,sequentialBufferedRange:()=>u,timeBeforeEndOfBuffer:()=>h,totalBuffered:()=>l});var i=r(12),n=r(499),s=i.wlog.getPrefixedFunctions("buffering"),a=function(t){var e=t.video;return e.buffered.length>0&&e.buffered.end(0)>0},o=function(t){for(var e=t.video,r=e.currentTime,i=0;i{r.d(e,{setup:()=>a,teardown:()=>o});var i=r(6),n=r(52),s=function(t){var e=t.attributes;return(null!=e.eventLoopDuration?e.eventLoopDuration:300)/t.getPlaybackRate()},a=function(t){null==t.state&&(t.state={}),"playing"===t.getPlaybackMode()&&(t.state.hasPlayed=!0),t.bind("playing",(function(){t.state.hasPlayed=!0})),t.bind("waiting",(function(){t.state.gotWaiting=!0})),t.bind("loadedmetadata",(function(){t.state.loadedMetadata=!0})),(0,i.assign)(t.state,{lastPlaybackMode:t.getPlaybackMode(),lastTimePosition:t.getCurrentTime(),lastEventLoopDuration:s(t)});var e="".concat(t.uuid,".custom_state_and_events");n.globalEventLoop.add(e,s(t),(function(){(0,i.assign)(t.state,{lastTimePosition:t.getCurrentTime(),lastPlaybackMode:t.getPlaybackMode(),lastEventLoopDuration:s(t)}),n.globalEventLoop.interval(e,s(t))}))},o=function(t){var e="".concat(t.uuid,".custom_state_and_events");n.globalEventLoop.remove(e)}},504:(t,e,r)=>{r.d(e,{enforceCuts:()=>d,getCurrentTimeAfterCuts:()=>n.getCurrentTimeAfterCuts,getDurationAfterCuts:()=>n.getDurationAfterCuts,getTrim:()=>u,setCuts:()=>c,setTrim:()=>m,teardownCuts:()=>f,trimStartFromCuts:()=>o});var i=r(11),n=r(214),s=r(501),a=(0,i.cachedDetect)(),o=function(t){var e=(0,n.getCuts)(t);return e.length<1||e[0].start>0?0:e[0].end},l=function(t){var e=(0,n.getCuts)(t),r=(0,n.getDurationBeforeCuts)(t);return e.length<1||e[e.length-1].end0?.09:1e-6;(0,s.seekWithoutCuts)(t,u+c)}else t.state.fakeEnded||(t.state.fakeEnded=!0,t.attributes.loop?(t.trigger("ended"),t.seek(0).then((function(){return t.play()}))):(t.pause(),t.trigger("ended")))}}},m=function(t,e){var r=e.start,i=e.end;null!=r&&(r>=0?t.attributes.trimStart=e.start:delete t.attributes.trimStart),null!=i&&(i>=0?t.attributes.trimEnd=e.end:delete t.attributes.trimEnd),t._cuts=void 0,g(t),d(t)},p=function(t,e){if(e>=t.length)return-1;for(var r=t[e].end,i=e;ir)break;n.start===r&&(r=n.end)}return r}},214:(t,e,r)=>{function i(t){return function(t){if(Array.isArray(t))return n(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return n(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return n(t,e)}(t)||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 n(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,i=new Array(e);ru,getCuts:()=>h,getDurationAfterCuts:()=>a,getDurationBeforeCuts:()=>s,getTimeAfterCuts:()=>l,getTimeBeforeCuts:()=>o});var s=function(t){var e=t.attributes;return null!=e.duration?e.duration:t.video.readyState>=2?t.video.duration:null},a=function(t){var e=h(t),r=s(t);if(e.length<1)return r;var i=r;return e.forEach((function(t){i-=t.end-t.start})),i},o=function(t,e){var r=s(t),i=h(t),n=0,a=0,o=0;return i.forEach((function(t){var r=t.start-a;if((o+=r)<=e+n){var i=t.end-t.start;n+=i,o+=i}a=t.end})),Math.min(r,e+n)},l=function(t,e){var r=h(t);if(r.length<1)return e;var i=e;return r.forEach((function(t){t.start<=e&&(i-=Math.min(e,t.end)-t.start)})),Math.max(0,i)},u=function(t){return l(t,t.video.currentTime)},c=Object.freeze([]),h=function(t){var e=t.attributes,r=e.cuts,i=e.trimStart,n=e.trimEnd;if(t._cuts&&r===t._rawCuts)return t._cuts;if(!r&&null==i&&null==n)return c;t._rawCuts=r,t._cuts=d(t);var s={start:t.attributes.trimStart,end:t.attributes.trimEnd};return t._cuts=f(t,s,t._cuts),Object.freeze(t._cuts),t._cuts},d=function(t){var e=s(t),r=t.attributes,i=r.cuts,n=r.trimStart,a=r.trimEnd;if(!i)return[];var o=i.map((function(r){var i=null!=r.start?g(t,r.start):0,n=null!=r.end&&-1!==r.end?g(t,r.end):e;return n>i?{start:i,end:n}:null})).filter(Boolean);null!=n&&o.push({start:0,end:n}),null!=a&&o.push({start:a,end:e}),o=o.sort((function(t,e){return t.start-e.start}));var l={start:0,end:0};return o=o.map((function(t){return t.end=a||c.end<0)?c:void 0;if(null!=o)if(o>=0){var f={start:0,end:o};h?n.splice(0,1,f):n.unshift(f)}else h&&n.shift();if(null!=l)if(l>=0){var g={start:l,end:a};d?n.splice(n.length-1,1,g):n.push(g)}else d&&n.pop();return n},g=function(t,e){var r=s(t);return Math.min(r,Math.max(0,e))}},513:(t,e,r)=>{r.d(e,{getDiagnosticData:()=>s});var i=r(216),n=function(t){try{return t()}catch(t){return"ERROR: ".concat(t.message)}},s=function(t){var e={};return e.player_version=i.PLAYER_VERSION,e.state=t.state,e.attributes=t.attributes,e.currentAsset=t.currentAsset(),e.currentAsset&&e.currentAsset.url&&e.currentAsset.url.length>100&&(e.currentAsset.url="".concat(e.currentAsset.url.substring(0,97),"...")),e.selectedAsset=t.selectedAsset(),e.selectedAsset&&e.selectedAsset.url&&e.selectedAsset.url.length>100&&(e.selectedAsset.url="".concat(e.selectedAsset.url.substring(0,97),"...")),e.getState=n((function(){return t.getState()})),e.getDuration=n((function(){return t.getDuration()})),e.getPlaybackRate=n((function(){return t.getPlaybackRate()})),e.getPlaybackMode=n((function(){return t.getPlaybackMode()})),e.isSeeking=n((function(){return t.isSeeking()})),e.getCurrentTime=n((function(){return t.getCurrentTime()})),e.activeBufferRange=n((function(){return t.activeBufferRange()})),e.sequentialBufferedRange=n((function(){return t.sequentialBufferedRange()})),e.getVolume=n((function(){return t.getVolume()})),e.timeBeforeEndOfBuffer=n((function(){return t.timeBeforeEndOfBuffer()})),e.lastBufferedTime=n((function(){return t.lastBufferedTime()})),e.totalBuffered=n((function(){return t.totalBuffered()})),e.anyBuffered=n((function(){return t.anyBuffered()})),e.getPreload=n((function(){return t.getPreload()})),e.rawVideoProps=n((function(){return o(t)})),e},a=["autoplay","controls","crossOrigin","currentSrc","currentTime","defaultMuted","defaultPlaybackRate","duration","ended","error","loop","muted","networkState","paused","playbackRate","preload","readyState","seeking","src","startDate","volume"],o=function(t){for(var e=t.video,r={},i=0;i{r.d(e,{fixWebkitControlsBug:()=>o});var i=r(11),n=r(12),s=(0,i.cachedDetect)(),a=n.wlog.getPrefixedFunctions("SimpleVideo"),o=function(t){var e=t.video;if(s.browser.webkit){a.info("fixWebkitControlsBug");var r=e.getAttribute("controls");e.setAttribute("controls","controls"),e.removeAttribute("controls"),null!=r&&e.setAttribute("controls",r)}}},499:(t,e,r)=>{r.d(e,{bufferedInfo:()=>g,createElement:()=>l,properAssetUrl:()=>m,setupVideoElemAttributes:()=>c,srcProtocolAndHost:()=>d,sumTimeRanges:()=>f});var i=r(5),n=r(24),s=r(33),a=r(23),o="".concat((0,a.eV1Protocol)(),"//").concat((0,a.eV1HostWithPort)(),"/assets/images/blank.gif"),l=function(t,e,r){var n={tagName:"video",id:t,crossorigin:"anonymous",style:{background:"transparent",display:"block",height:"100%",maxHeight:"none",maxWidth:"none",position:"static",visibility:"visible",width:"100%"}},s={tagName:"source",src:m(e.url),type:h(e,r)};return r.excludeSourceElem||(n.childNodes=[s]),c((0,i.elemFromObject)(n),e,r)},u=function(t,e,r){null!=r&&!1!==r?!0===r?(t[e]=!0,t.setAttribute(e,"")):(t[e]=r,t.setAttribute(e,r)):(t[e]=!1,t.removeAttribute(e))},c=function(t,e,r){return r.poster?(t.poster=r.poster,t.setAttribute("poster",r.poster)):(t.poster=o,t.setAttribute("poster",o)),u(t,"aria-label","Video"),u(t,"src",m(e.url)),u(t,"controlslist",r.controlslist||"nodownload"),u(t,"playsinline",r.playsinline),u(t,"muted",r.muted),u(t,"loop",r.loop),u(t,"controls",null!=r.controls&&r.controls),u(t,"preload",r.preload||"none"),u(t,"type",h(e,r)),u(t,"x-webkit-airplay",null!=r.webkitAirplay?r.webkitAirplay:"allow"),null!=r.volume&&(t.volume=r.volume),r.disablePictureInPicture&&u(t,"disablePictureInPicture",r.disablePictureInPicture),t},h=function(t,e){if(null!=e.contentType)return e.contentType;var r="video/".concat(t.ext);return e.spherical&&(r+=";dimension=360;"),r},d=function(t){if((0,s.isBakeryUrl)(t)){var e=new n.Url(t);if(e.protocol)return"".concat(e.protocol,"//").concat(e.host)}return"".concat((0,a.eV1Protocol)(),"//").concat((0,a.deliveryHost)((0,a.eV1Protocol)()))},f=function(t){if(null==t)return null;for(var e=0,r=0;rc&&(l[u-1].end=t[o].end):l.push(t[o])}else l.push(t[o])}for(o=0,i=0,n=s=e;o=h&&e1&&void 0!==arguments[1]?arguments[1]:"mp4";return(0,s.isBakeryUrl)(t)&&/\.bin$/.test(t)?"".concat(t.replace(/\.bin$/,""),"/file.").concat(e):t}},498:(t,e,r)=>{r.d(e,{default:()=>k});var i=r(15),n=r(6),s=r(33),a=r(20),o=r(499),l=r(500),u=r(501),c=r(505),h=r(506),d=r(503),f=r(511),g=r(502),m=r(512),p=r(513),v=r(507),y=r(514),T=r(504),E=r(515),b=r(214),S=r(516);function A(t,e){for(var r=0;r{r.d(e,{fromOtherEngine:()=>h,injectVideo:()=>c,killBindingsAndStopLoops:()=>f,setupBindingsAndLoops:()=>d,setupProperties:()=>u});var i=r(5),n=r(499),s=r(508),a=r(509),o=r(510),l=r(504),u=function(t,e,r){var i=e.assets;0===i.length&&(i=[{}]),t.mediaData=e,t.allAssets=i,t.attributes=r},c=function(t){t._currentAsset=t.defaultAsset(),t.video=n.createElement(t.uuid,t._currentAsset,t.attributes),t.onReady(),(0,i.elemAppend)(t.root,t.video)},h=function(t,e){var r=e.isMuted(),i=e.hasIssuedPlay();"Audio"===e.mediaData.mediaType?c(t):t.video=e.getMediaElement(),t.onReady(),t.bind("loadstart",(function(){return setTimeout((function(){t.state.isInitializingFromOtherEngine=!1}),0),t.unbind})),n.setupVideoElemAttributes(t.video,t.defaultAsset(),t.attributes),t.state.eventContext=e.eventContext(),t.root.appendChild(t.video),t._currentAsset=t.defaultAsset(),t.changeStreamWithoutLoad(t.defaultAsset()),t.state.isInitializingFromOtherEngine=!0,t.state.otherEngineWasMuted=r,t.state.otherEnginePlayed=i,t.video.load()},d=function(t){a.setup(t),(0,l.enforceCuts)(t),o.setup(t),s.setup(t)},f=function(t){o.teardown(t),(0,l.teardownCuts)(t),s.teardown(t),a.teardown(t)}},512:(t,e,r)=>{r.d(e,{fit:()=>h,onHeightChange:()=>o,onWidthChange:()=>a});var i=r(5),n=r(33),s=(0,r(11).cachedDetect)(),a=function(t,e){return t.setAttributes({width:e}),h(t)},o=function(t,e){return t.setAttributes({height:e}),h(t)},l="contain",u="fill",c=!s.iphone&&!s.ipad,h=function(t){var e=t.attributes.fitStrategy||d(t);return e===l?g(t):"cover"===e?f(t):e===u?m(t):g(t)},d=function(t){var e=t.attributes.height,r=t.attributes.width,i=(0,n.originalAspect)(t.allAssets),a=e*i,o=2*Math.floor(r/i/2),c=Math.abs(o-e),h=Math.abs(a-r),d=s.firefox&&s.browser.mozilla&&s.browser.version>=36;return(s.browser.webkit||d)&&c>0&&c<=10&&h>0&&h<=10?u:l},f=function(t){var e=t.video,r=(0,n.videoAspect)(t.allAssets),a=(0,i.elemWidth)(t.root)/(0,i.elemHeight)(t.root);s.edge?a<=r?(0,i.elemStyle)(e,{height:"100%",left:"50%",objectFit:"contain",position:"relative",top:"50%",transform:"translate(-50%,-50%)",width:"1920px"}):(0,i.elemStyle)(e,{height:"1088px",left:"50%",objectFit:"contain",position:"relative",top:"50%",transform:"translate(-50%,-50%)",width:"100%"}):c&&(0,i.elemStyle)(e,{objectFit:"cover"})},g=function(t){var e=t.video,r={height:"100%",width:"100%"};c&&(r.objectFit="contain"),(0,i.elemStyle)(e,r)},m=function(t){var e=t.video,r={height:"100%",width:"100%"};c&&(r.objectFit="fill"),(0,i.elemStyle)(e,r)}},505:(t,e,r)=>{r.d(e,{onReady:()=>n});var i=r(12).wlog.getPrefixedFunctions("SimpleVideo"),n=function(t){var e=t.video;null==t.state&&(t.state={});var r=t.state;return r.onReadyPromise||(r.onReadyPromise=new Promise((function(n){if(r.hasBeenReady)n();else{if(e.readyState>=2)i.info("ready readyState",e.src,e.readyState),r.hasBeenReady=!0,n();else{t.bind("loadstart",(function(){i.info("ready loadstart"),r.hasBeenReady=!0,n()}))}setTimeout((function(){r.hasBeenReady||(r.hasBeenReady=!0,n())}),200)}}))),r.onReadyPromise}},502:(t,e,r)=>{r.d(e,{BEFORE_PLAY:()=>n,getPlaybackMode:()=>s});var i=r(12).wlog.getPrefixedFunctions("SimpleVideo"),n="beforeplay",s=function(t){var e=t.video;try{return t.state.hasPlayed?t.state.fakeEnded||e.ended?"ended":e.paused?"paused":"playing":n}catch(t){return i.warn(t),"unknown"}}},510:(t,e,r)=>{r.d(e,{setup:()=>s,teardown:()=>a});var i=r(5),n=["beforeplay","ended","error","loadeddata","loadedmetadata","loadstart","pause","playing","progress","ratechange","seeked","seeking","volumechange","timeupdate","waiting","webkitbeginfullscreen","webkitendfullscreen","webkitplaybacktargetavailabilitychanged"],s=function(t){for(var e=0;e{r.d(e,{isSeeking:()=>p,seek:()=>c,seekOnPlay:()=>g,seekWithoutCuts:()=>h});var i=r(6),n=r(5),s=r(12),a=r(502),o=r(503),l=r(214),u=s.wlog.getPrefixedFunctions("SimpleVideo"),c=function(t,e,r){var i=(0,l.getTimeBeforeCuts)(t,e);return h(t,i,r)},h=function(t,e,r){return u.info("seek",e),t.getPlaybackMode()===a.BEFORE_PLAY?d(t,e,r):f(t,e,r)},d=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=t.video;return u.info("seekBeforePlay",e),new Promise((function(s,a){u.info("time ".concat(e,": seek beforeplay"));var l="playing"===t.getPlaybackMode();n.style.visibility="hidden",(0,i.assign)(t.state,{seeking:!0}),u.info("time ".concat(e,": start stream by calling play")),(0,o.playWithoutCuts)(t).then((function(a){u.info("time ".concat(e,": jump to time after playing")),n.currentTime=e;var c=new Promise((function(i){l||!1===r.pause?(u.info("time: ".concat(e,": play after seek")),i()):(u.info("time: ".concat(e,": pause after seek")),(0,o.pause)(t).then(i))}));m(t).then((function(){c.then((function(){n.style.visibility="inherit",(0,i.assign)(t.state,{seeking:!1}),s(a)}))}))})).catch((function(e){n.style.visibility="inherit",(0,i.assign)(t.state,{seeking:!1}),a(e)}))}))},f=function(t,e){return u.info("seekNow",e),new Promise((function(r){u.info("seekNow: start",e),t.video.currentTime=e,(0,i.assign)(t.state,{seeking:!0}),m(t).then((function(){(0,i.assign)(t.state,{seeking:!1}),u.info("seekNow: resolve",e),r()}))}))},g=function(t,e){return new Promise((function(r){"playing"===t.getPlaybackMode()?f(t,e).then(r):t.bind("playing",(function(){return f(t,e).then(r),t.unbind}))}))},m=function(t){var e=t.video;return new Promise((function(t){e.seeking?(u.info("waiting for seek"),(0,n.elemBind)(e,"seeked",(function(){return u.info("seeked"),t(),n.elemUnbind}))):(u.info("no wait for seek"),t())}))},p=function(t){var e=t.state,r=t.video;return Boolean(e.seeking||r.seeking)}},503:(t,e,r)=>{r.r(e),r.d(e,{cancelFullscreen:()=>$,captureCurrentFrame:()=>G,getCurrentTime:()=>E,getDuration:()=>R,getPlaybackRate:()=>w,getPreload:()=>I,getState:()=>b,getVolume:()=>A,isInFullscreen:()=>M,isInitializingFromUnmuted:()=>O,isMuted:()=>D,isSourceOfBrowserEvent:()=>_,mute:()=>C,onEnterFullscreen:()=>x,onHeightChange:()=>B,onLeaveFullscreen:()=>F,onWidthChange:()=>N,pause:()=>v,play:()=>g,playType:()=>p,playWithoutCuts:()=>m,requestFullscreen:()=>U,setCurrentTime:()=>y,setCurrentTimeWithoutCuts:()=>T,setPlaybackRate:()=>k,setVolume:()=>S,supportsPlaybackRate:()=>L,unmute:()=>P});var i=r(5),n=r(12),s=r(11),a=r(6),o=r(214),l=r(504),u=n.wlog.getPrefixedFunctions("SimpleVideo"),c=(0,s.cachedDetect)(),h="play",d="play-silently",f="cannot-play",g=function(t,e){var r=(0,l.trimStartFromCuts)(t);return t.state.fakeEnded||t.video.currentTime1&&void 0!==arguments[1]?arguments[1]:{},r=t.video,n=e.playType||p(t,e);return null==t.state.issuedPlay&&n!==f&&(t.state.issuedPlay=!0),new Promise((function(s,a){t.state.lastPlayRejected=!1;var o=t.getPlaybackMode();if(u.info("play: start",n),"playing"===o)u.info("play: already playing, resolve"),s(h);else if(n===f)a(new Error("Cannot issue play."));else{n===d&&t.mute(),t.trigger("beforeplay"),"ended"===o&&c.ios.version>0&&(r.load(),t.attributes.hasCalledLoad=!0);var l=r.play();if(l&&l.then&&l.catch)l.then((function(){u.info("play: got",n,"resolve"),s(n)})).catch((function(i){u.notice(i),t.state.lastPlayRejected=!0;var o=null!=e.silentAutoplay?e.silentAutoplay:t.attributes.silentAutoplay;n!==h||t.isMuted()||"allow"!==o&&null!=o?(u.notice("play: rejected"),a(i)):(t.mute(),r.play().then((function(){u.info("play: got silent fallback, resolve"),s(d)})).catch((function(e){t.unmute(),a(e)})))}));else{setTimeout((function(){c.ios.version&&c.ios.version<10.1&&r.paused&&a(new Error("Video still paused after play issued."))}),10);t.bind("playing",(function(){return u.info("play: got playing, resolve"),s(n),i.elemUnbind}))}}}))},p=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("playing"===t.getPlaybackMode())return h;if(t.isInitializingFromUnmuted())return h;if((0,i.inUserEventContext)())return h;var r=t.attributes,n=null!=e.silentAutoplay?e.silentAutoplay:r.silentAutoplay;return!0===n?t.isMuted()?h:d:!1===n?h:"allow"===n||null==n?c.chrome||c.firefox||c.edge||(c.safari||c.ios.version&&c.ios.version>=12)||t.isMuted()?h:d:h},v=function(t){var e=t.video;return u.info("pause"),new Promise((function(t){u.info("pause: start"),e.pause(),(0,i.safeRequestAnimationFrame)((function(){u.info("pause: resolve"),t()}))}))},y=function(t,e){var r=(0,o.getTimeBeforeCuts)(t,e);return T(t,r)},T=function(t,e){u.info("setCurrentTime",e),t.video.currentTime=e},E=function(t){return(0,l.getCurrentTimeAfterCuts)(t)},b=function(t){return{playbackMode:t.getPlaybackMode(),currentTime:t.getCurrentTime(),volume:t.getVolume(),playbackRate:t.getPlaybackRate()}},S=function(t,e){u.info("setVolume",e),t.video.volume=e},A=function(t){return t.video.volume},L=function(t){return null!=t.video.playbackRate},k=function(t,e){u.info("setPlaybackRate",e),L(t)?t.video.playbackRate=e:u.info("playbackRate is not supported on",t.video)},w=function(t){return L(t)?t.video.playbackRate:1},R=function(t){return(0,l.getDurationAfterCuts)(t)},_=function(t,e){return e.target==t.video},D=function(t){var e=t.video;return!!(e.muted||t.state.loadedMetadata&&0===e.volume||t.state.hasPlayed&&e.audioTracks&&0===e.audioTracks.length)},I=function(t){return t.video.getAttribute("preload")},C=function(t){t.video.muted=!0,t.video.setAttribute("muted","muted")},P=function(t){t.video.muted=!1,t.video.removeAttribute("muted")},x=function(t){t.state.isInFullscreen=!0;var e=t.attributes.backgroundColor||"#000";t.video.style.backgroundColor=e},F=function(t){t.state.isInFullscreen=!1,t.video.style.backgroundColor="transparent"},O=function(t){var e=t.state;return e.isInitializingFromOtherEngine&&e.otherEnginePlayed&&!e.otherEngineWasMuted},M=function(t){return!!t.state.isInFullscreen},N=function(t){},B=function(t){},U=function(t){t.setAttributes({fitStrategy:"contain"}),t.fit(),(0,i.elemRequestFullscreen)(t.video)},$=function(t){t.setAttributes({fitStrategy:"auto"}),t.fit(),(0,i.elemCancelFullscreen)(t.video)},G=function(t){var e=t.video,r=document.createElement("canvas");r.width=e.videoWidth,r.height=e.videoHeight,r.getContext("2d").drawImage(e,0,0,r.width,r.height);for(var i=arguments.length,n=new Array(i>1?i-1:0),s=1;s{r.d(e,{changeQuality:()=>c,changeStream:()=>d,changeStreamWithoutLoad:()=>h,changeVideo:()=>g,initAfterChangeVideo:()=>p,isChangingVideo:()=>f,stopStreaming:()=>u,teardownBeforeChangeVideo:()=>m});var i=r(12),n=r(5),s=r(33),a=r(507),o=r(499),l=i.wlog.getPrefixedFunctions("SimpleVideo"),u=function(t){try{if(t.state.destroyed)return;l.info("stopStreaming");var e=t.video;e.src="".concat(o.srcProtocolAndHost(e.getAttribute("src")),"/tiny.mp4"),e.load()}catch(t){l.notice(t)}},c=function(t,e,r,i){var n=t.selectableAssets(),a=(0,s.findClosestAssetByQuality)(n,e);return"beforeplay"===t.getPlaybackMode()?(h(t,a),Promise.resolve()):d(t,a,r,i)},h=function(t,e){l.info("changeStreamWithoutLoad",e&&e.slug,e);var r=t.video;if((0,n.elemInDom)(r)){var i=o.properAssetUrl(e.url,e.container);t.state={eventContext:t.state.eventContext},t._currentAsset=e,r.src=i;var s=function(t){for(var e=t.video,r=[],i=0;i0&&(s[0].src=i)}},d=function(t,e){var r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];l.info("changeStream",r,i,e&&e.slug,e);var s=t.video;return t.asset=e,new Promise((function(a){var l=o.properAssetUrl(e.url,e.container);if(i||l!==s.getAttribute("src")){var u=t.getState();t.state.seeking=!0,(0,n.elemBind)(s,"loadstart",(function(){return i?(s.style.visibility="visible",t.state.seeking=!1,a()):u.currentTime>2?t.seek(u.currentTime).then((function(){"playing"===u.playbackMode?t.play().then((function(){t.state.seeking=!1,s.style.visibility="visible",a()})):t.pause().then((function(){s.style.visibility="visible",t.state.seeking=!1,a()}))})):("playing"===u.playbackMode&&t.play(),s.style.visibility="visible",t.state.seeking=!1,a()),t.setPlaybackRate(u.playbackRate),n.elemUnbind})),s.style.visibility="hidden",h(t,e,i),"beforeplay"===u.playbackMode||r||t.play()}else a()}))},f=function(t){return!!t.state.isChangingVideo},g=function(t,e,r){return m(t),t.state.isChangingVideo=!0,p(t,e,r),new Promise((function(e){d(t,t.defaultAsset()).then((function(){t.state.isChangingVideo=!1,e()}))}))},m=function(t){var e=t.state.eventContext;t.destroy(),t.state.eventContext=e},p=function(t,e,r){a.setupProperties(t,e,r),a.setupBindingsAndLoops(t,t.allAssets,r)}},516:(t,e,r)=>{r.d(e,{addTextTracks:()=>s,removeTextTracks:()=>a});var i=r(20),n=r(5),s=function(t,e){var r=(0,i.seqId)("wistia_captions_");t.forEach((function(t){var i=document.createElement("track");i.kind=t.kind||"captions",i.label=t.native_name,i.srclang=t.language,i.src=t.src,i._wistiaCaptionsId=t._wistiaCaptionsId||r,e.appendChild(i,{wistiaGridCaller:!0})}))},a=function(t,e){for(var r=Array.prototype.slice.call(e.childNodes),i=0;i{r.d(e,{setup:()=>o,teardown:()=>l});var i=r(6),n=r(5),s=r(52),a=function(t){var e=t.attributes;return(null!=e.eventLoopDuration?e.eventLoopDuration:300)/t.getPlaybackRate()},o=function(t){null==t.state&&(t.state={}),t.state.waiting=-1;var e="".concat(t.uuid,".waiting_events");s.globalEventLoop.add(e,a(t),(function(){u(t),s.globalEventLoop.interval(e,a(t))}))},l=function(t){var e="".concat(t.uuid,".waiting_events");s.globalEventLoop.remove(e)},u=function(t){var e=t.video,r=t.state,s=r.lastPlaybackMode,o=r.gotWaiting&&"beforeplay"===t.getPlaybackMode()||"playing"===t.getPlaybackMode(),l="playing"===s||"beforeplay"===s&&!r.lastPlayRejected,u=r.lastEventLoopDuration||a(t);if(o&&l)if(t.getCurrentTime()===r.lastTimePosition){var h=r.startedWaitingAt;h?(r.waiting=((new Date).getTime()-h)/1e3,t.trigger("custom-waiting",r.waiting)):((0,i.assign)(r,{startedWaitingAt:(new Date).getTime()-u,waiting:u/1e3}),t.trigger("custom-waiting",u/1e3),(0,n.elemBind)(e,"timeupdate",(function(){return c(t),n.elemUnbind})))}else c(t);else c(t)},c=function(t){var e=t.state.waiting;(0,i.assign)(t.state,{waiting:-1,startedWaitingAt:null}),null!=e&&e>=0&&t.trigger("custom-done-waiting",e)}},33:(t,e,r)=>{r.d(e,{READY:()=>c,filter:()=>d,findClosestAssetByQuality:()=>y,isBakeryUrl:()=>E,nearestOutsideRange:()=>R,numericSizeSnapped:()=>v,originalAspect:()=>w,readyPublicOver400:()=>m,videoAspect:()=>k,withinQualityRange:()=>p});var i=r(6),n=r(24),s=(r(11),r(23),r(12)),a=r(25);function o(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var i,n,s,a,o=[],l=!0,u=!1;try{if(s=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(i=s.call(r)).done)&&(o.push(i.value),o.length!==e);l=!0);}catch(t){u=!0,n=t}finally{try{if(!l&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(u)throw n}}return o}}(t,e)||function(t,e){if(!t)return;if("string"==typeof t)return l(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return l(t,e)}(t,e)||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 l(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,i=new Array(e);r1&&void 0!==arguments[1]?arguments[1]:{};if(!t)return[];t.assets&&(t=t.assets),null==e.qualityMin&&null==e.qualityMax||(t=p(t,e.qualityMin,e.qualityMax),e=(0,i.except)(e,["qualityMin","qualityMax"]));var r=(0,i.only)(e,h),n=r.select||(0,i.except)(e,h);n&&(r.select=n);var s=r.select?(0,i.select)(t,r.select):(0,i.clone)(t);if((r.sortFn||r.sortBy)&&(s=(0,i.sort)(s,r.sortFn||r.sortBy)),r.unique){for(var a={},o=0;o=500&&i.opt_vbitrate<=1e5,s=null!=i.width&&i.width>400;(n||s)&&e.push(i)}return e},m=function(t){return g(d(t,{container:/mp4/,public:!0,status:c}))},p=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e4;return d(t,{select:function(t){var i=v(t.width,t.height);return e<=i&&i<=r}})},v=function(t,e){if(e>t){var r=t;t=e,e=r}var i=t/e,n=t*e+1;return n>=3840/i*3840?2160:n>=2560/i*2560?1440:n>=1920/i*1920?1080:n>=1280/i*1280?720:n>=960/i*960?540:n>=640/i*640?360:e},y=function(t,e){var r;r="4k"===e?2160:parseInt(e,10);var i=p(t,r,r)[0];if(i)return i;var n=R(t,r,r);if(1===n.length)return n[0];var s=k(t),a=Math.round(s*r),l=o(n,2),u=l[0],c=l[1];return Math.abs(u.width-a)=0},b=function(t,e,r){return r=(0,i.merge)({container:e,public:!0,status:c},r),f(t,r)},S=function(t,e){return b(t,"mp4",e)},A=function(t,e){return b(t,"webm",e)},L=function(t){return f(t,{type:"original"})},k=function(t){var e=S(t)||function(t,e){return b(t,"m3u8",e)}(t)||A(t)||L(t);return e&&e.height?e.width/e.height:640/360},w=function(t){var e=k(t),r=L(t);if(r&&r.width&&r.height){var i=r.width/r.height;return i>1&&e<1||i<1&&e>1?1/i:i}return e},R=function(t,e,r){if(0===t.length)return[];for(var i,n,a=u.call(t).sort((function(t,e){return v(t.width,t.height)-v(e.width,e.height)})),o=0;o=r){n=l;break}}var h=[];return i&&h.push(i),n&&h.push(n),0===h.length&&(s.wlog.error("nearestOutsideRange: no nearby assets found, using first in list",a[0]),h.push(a[0])),h}},7:(t,e,r)=>{r.d(e,{default:()=>s});var i=function(t,e){if(null==t)throw new TypeError("Cannot convert undefined or null to object");return Object.prototype.hasOwnProperty.call(Object(t),e)},n=function(t,e){for(var r in e)i(e,r)&&(t[r]=e[r]);return t};const s=function(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),i=1;i{r.d(e,{bind:()=>l,bindNamed:()=>g,bindify:()=>y,trigger:()=>h,unbind:()=>u,unbindAllInNamespace:()=>p,unbindNamed:()=>m});var i=r(3),n=function(t,e){if(null==t)throw new TypeError("Cannot convert undefined or null to object");return Object.prototype.hasOwnProperty.call(Object(t),e)};function s(t){return function(t){if(Array.isArray(t))return a(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return a(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return a(t,e)}(t)||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 a(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,i=new Array(e);r1?e-1:0),i=1;i{r.d(e,{makeCacheable:()=>i,makeNamespace:()=>n,uncacheNamespace:()=>u});var i=function(t){return function(e,r,i){if(o(t,e),s(t,e,r))return a(t,e,r);var n=i();return l(t,e,r,n),n}},n=function(t){return function(e){return null==e[t]&&(e[t]={}),e[t]}},s=function(t,e,r){return null!=a(t,e,r)},a=function(t,e,r){return o(t,e),e[t][r]},o=function(t,e){null==e[t]&&(e[t]={})},l=function(t,e,r,i){o(t,e),e[t][r]=i},u=function(t,e){e[t]={}}},11:(t,e,r)=>{r.d(e,{cachedDetect:()=>H});var i,n=r(3),s=r(4),a=navigator.userAgent,o=/(webkit)[ /]([^\s]+)/i,l=/OPR\/([^\s]+)/i,u=/(edge)\/(\d+(?:\.\d+)?)/i,c=/(mozilla)(?:.*? rv:([^\s)]+))?/i,h=/(android) ([^;]+)/i,d=/(iphone)/i,f=/(Windows Phone OS (\d+(?:\.\d+)?))/,g=/OS (\d+)_(\d+)/i,m=/(playstation 3)/i,p=/BlackBerry|BB10/i,v=/(firefox)/i,y=/Mobile VR/i,T=/Version\/([^\s]+)/i,E=function(){return(S()[1]||"webkit").toLowerCase()},b=function(){return S()[2]},S=function(){var t;return(t=a.match(u))||(t=a.match(o))||(t=a.match(l))?t:t?(null!=document.documentMode&&(t[2]=document.documentMode),t):(t=a.match(c))||[]},A=function(){var t=a.match(h);return null!=t&&{version:t[2]}},L=function(){return d.test(a)},k=function(){return F()>0||A()||_()},w=function(){try{var t=matchMedia("(hover:hover)");if("not all"!==t.media)return t.matches}catch(t){}return!k()},R=function(){return p.test(a)},_=function(){return/Macintosh/i.test(navigator.userAgent)&&navigator.maxTouchPoints&&navigator.maxTouchPoints>1},D=function(){return o.test(a)&&!/chrome/i.test(a)&&!_()&&!L()},I=function(){return!(!/Chrome/.test(a)||!/Google Inc/.test(navigator.vendor))&&{version:P()}},C=function(){var t=a.match(/\bSilk\/([^\s]+)/);return t&&t[1]},P=function(){var t=a.match(/\bChrome\/([^\s]+)/);return t&&t[1]},x=function(){return l.test(a)},F=function(){var t=a.match(g),e=a.match(T);return null!=t?parseFloat("".concat(t[1],".").concat(t[2])):null!=e&&e[1]&&_()?parseFloat(e[1]):0},O=function(){return u.test(a)},M=function(){return v.test(a)},N=function(){var t=document.createElement("video"),e=!1;try{if(t.canPlayType){var r='video/mp4; codecs="avc1.42E01E';(e={}).h264=!!t.canPlayType("".concat(r,'"'))||!!t.canPlayType("".concat(r,', mp4a.40.2"')),e.webm=!!t.canPlayType('video/webm; codecs="vp9, vorbis"'),e.nativeHls=!!t.canPlayType("application/vnd.apple.mpegURL")}}catch(t){e={ogg:!1,h264:!1,webm:!1,nativeHls:!1}}return e},B=function(){try{return"localStorage"in s.default&&null!=s.default.localStorage}catch(t){return!1}},U=["WebKit","Moz","O","Ms",""],$=function(){for(var t=0;t1,hoverIsNatural:w(),touchScreen:k(),ps3:m.test(a),video:N(),mediaSource:s.default.MediaSource&&s.default.MediaSource.isTypeSupported("".concat('video/mp4; codecs="avc1.42E01E',', mp4a.40.2"')),nativeHls:(L()||_()||D())&&N().nativeHls,localstorage:B(),json:!(!s.default.JSON||"function"!=typeof JSON.parse),backgroundSize:(g=document.createElement("div"),""===g.style.backgroundSize||""===g.style.webkitBackgroundSize||""===g.style.mozBackgroundSize||""===g.style.oBackgroundSize),fullscreenEnabled:document.fullscreenEnabled||document.mozFullScreenEnabled||document.webkitFullscreenEnabled||document.msFullscreenEnabled,vulcanSupport:(d=/webkit|mozilla|edge/.test(E()),Boolean(!L()&&!_()&&!A()&&!R()&&d&&N().h264&&Object.defineProperties)),mutationObserver:$(),callingPlayRequiresEventContext:F()>0||A()||D(),passiveSupported:G(),webp:(t=I(),e=M(),r=O(),i=x(),n=t&&b()>=32,o=t&&b()>=75&&A(),l=e&&b()>=65,u=e&&b()>=67&&A(),c=r&&b()>=18,h=i&&b()>=19,n||o||l||u||c||h)};return p.browser[E()]=!0,p}},8:(t,e,r)=>{r(9)},5:(t,e,r)=>{r.d(e,{elemAppend:()=>g,elemBind:()=>L,elemCancelFullscreen:()=>_,elemFromObject:()=>f,elemHeight:()=>S,elemInDom:()=>A,elemRemove:()=>m,elemRequestFullscreen:()=>R,elemStyle:()=>p,elemUnbind:()=>k,elemWidth:()=>b,inUserEventContext:()=>P,pageLoaded:()=>s.default,safeRequestAnimationFrame:()=>C});var i,n=r(6),s=(r(8),r(10)),a=r(11),o=r(12),l=(r(16),r(17),r(20)),u=r(3),c=function(t,e){if(null==t)throw new TypeError("Cannot convert undefined or null to object");return Object.prototype.hasOwnProperty.call(Object(t),e)},h=u.default,d=(0,a.cachedDetect)(),f=function t(e){if((0,n.isArray)(e)){for(var r=[],i=0;i1?r-1:0),s=1;s3&&void 0!==arguments[3]&&arguments[3],n=function(i){(i=i||window.event).pageX||i.pageY||!i.clientX&&!i.clientY||(i.pageX=i.clientX+I(),i.pageY=i.clientY+D()),i.preventDefault||(i.preventDefault=function(){i.returnValue=!1}),i.stopPropagation||(i.stopPropagation=function(){i.cancelBubble=!0}),null==i.which&&(i.which=null!=i.charCode?i.charCode:i.keyCode),null==i.which&&null!=i.button&&(1&i.button?i.which=1:2&i.button?i.which=3:4&i.button?i.which=2:i.which=0),i.target||i.srcElement&&(i.target=i.srcElement),i.target&&3===i.target.nodeType&&(i.target=i.target.parentNode);for(var n=arguments.length,s=new Array(n>1?n-1:0),a=1;a3&&void 0!==arguments[3]&&arguments[3];if(null!=t&&null!=t._wistiaElemId&&null!=r&&r._wistiaBindId){var n=w(t,e,r),s=h._elemBind[n];return s&&(t.removeEventListener(e,s,i),s.elem=null,s.event=null),delete h._elemBind[n]}},w=function(t,e,r){return t._wistiaElemId=t._wistiaElemId||(0,l.seqId)("wistia_elem_"),r._wistiaBindId=r._wistiaBindId||(0,l.seqId)("wistia_bind_"),"".concat(t._wistiaElemId,".").concat(e,".").concat(r._wistiaBindId)},R=function(t){return t.requestFullscreen?t.requestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT):t.msRequestFullscreen?t.msRequestFullscreen():t.webkitEnterFullscreen?t.webkitEnterFullscreen():(o.wlog.notice("no requestFullscreen functionality detected"),null)},_=function(t){return document.cancelFullscreen?document.cancelFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen?document.msExitFullscreen():t&&t.webkitExitFullscreen?t.webkitExitFullscreen():(o.wlog.notice("no cancelFullscreen functionality detected"),null)},D=function(t){var e=document.body,r=document.documentElement;if(null==t)return r&&r.scrollTop||e&&e.scrollTop||0;e&&(e.scrollTop=t),r&&(r.scrollTop=t)},I=function(t){var e=document.body,r=document.documentElement;if(null==t)return r&&r.scrollLeft||e&&e.scrollLeft||0;e&&(e.scrollLeft=t),r&&(r.scrollLeft=t)},C=function(t){return(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){return setTimeout(t,1e3/60)})(t)},P=function(){return!!i};["auxclick","click","contextmenu","dblclick","focus","keydown","keypress","keyup","mousedown","mouseup","reset","submit","touchend","touchstart"].forEach((function(t){L(document,t,(function(t){i=t,Date.now(),setTimeout((function(){i===t&&(i=void 0)}),0)}),!d.passiveSupported||{capture:!0,passive:!0})}))},16:(t,e,r)=>{var i;r.d(e,{elemOffset:()=>s});var n=function(){if(null!=i)return i;var t=document.createElement("div");return t.style.paddingLeft=t.style.width="1px",document.body.appendChild(t),i=2===t.offsetWidth,document.body.removeChild(t),i},s=function(t){var e,r,i=document.body,s=document.defaultView,o=document.documentElement,l=t.getBoundingClientRect(),u=o.clientTop||i.clientTop||0,c=o.clientLeft||i.clientLeft||0;e=s&&null!=s.pageYOffset?s.pageYOffset:n()&&o&&null!=o.scrollTop?o.scrollTop:i.scrollTop,r=s&&null!=s.pageXOffset?s.pageXOffset:n()&&o&&null!=o.scrollLeft?o.scrollLeft:i.scrollLeft;var h=a(t);return{height:l.height*h,top:l.top*h+e-u,left:l.left*h+r-c,width:l.width*h,zoom:h}},a=function t(e){return e&&e!==document.documentElement?t(e.parentElement)*(getComputedStyle(e).zoom||1):1}},52:(t,e,r)=>{r.d(e,{globalEventLoop:()=>l});var i=r(12),n=r(3),s=i.wlog.getPrefixedFunctions("event_loop"),a=function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this._timeoutId=null,this._latency=null!=e.latency?e.latency:100,this._blurLatency=null!=e.blurLatency?e.blurLatency:2e3,this._functions={},this._paused={},window.addEventListener("blur",(function(){return t.blur()}),!1),window.addEventListener("focus",(function(){return t.focus()}),!1),this.start()},o=a.prototype;o.start=function(){var t=this;clearTimeout(this._timeoutId),this._loopFn=this._loopFn||function(){t.runFunctions(),t._timeoutId=setTimeout(t._loopFn,t._latency)},this._loopFn()},o.resync=function(){this.start()},o.resyncNextTick=function(){var t=this;setTimeout((function(){t.resync()}),0)},o.stop=function(){clearTimeout(this._timeoutId)},o.clear=function(){this._functions={}},o.runFunctions=function(){this._pausedDirty&&this.updatePaused();var t=[];for(var e in this._functions){var r=this._functions[e],i=(new Date).getTime(),n=i-r.lastRanAt;if(!r.paused&&n>=r.interval){r.lastRanAt=i;try{r.fn()===this.remove&&t.push(e)}catch(t){s.error(t)}}}for(var a=0;a{r.d(e,{globalTrigger:()=>n});var i=r(3);(0,r(14).makeWbindable)(i.default);i.default.bind.bind(i.default),i.default.on.bind(i.default),i.default.off.bind(i.default),i.default.rebind.bind(i.default);var n=i.default.trigger.bind(i.default);i.default.unbind.bind(i.default)},23:(t,e,r)=>{r.d(e,{cdnFastWistiaComHost:()=>c,cdnFastWistiaNetHost:()=>h,deliveryHost:()=>u,eV1HostWithPort:()=>g,eV1Protocol:()=>m,mediaDataHost:()=>p,metricsHost:()=>v});var i=r(4),n=r(24),s=r(25),a=((0,s.appHostname)("app"),(0,s.appHostname)("fast")),o="undefined"!=typeof window&&i.default===window&&i.default.location?i.default.location.protocol:"https:",l=function(t,e,r){return"https:"===t?e:r},u=function(){return l(arguments.length>0&&void 0!==arguments[0]?arguments[0]:o,"embed-ssl.wistia.com","embed.wistia.com")},c=function(t){return t||a},h=function(){return"fast.wistia.net"},d=function(){for(var t=document.getElementsByTagName("script"),e=0;e0&&void 0!==arguments[0]?arguments[0]:{};return t.embedHost?T(t.embedHost):g()},v=function(){return"pipedream.wistia.com"},y=new RegExp("(".concat(["wistia.net","wistia.com","wistia.st"].map((function(t){return"\\.".concat(t.replace(".","\\."))})).join("|"),")$")),T=function(t){return t&&y.test(t)?t:g()}},26:(t,e,r)=>{r.d(e,{setOrGet:()=>a});var i=r(3),n=r(27),s=r(6);i.default._localStorage||(i.default._localStorage=(0,n.getWistiaLocalStorage)());var a=function(t,e){if(null!=e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2]?s.unsetDeep:s.setDeep;return i.default._localStorage=(0,n.updateWistiaLocalStorage)((function(i){return r(i,t,e)})),e}return null!=t?(0,s.getDeep)(i.default._localStorage,t):i.default._localStorage};n.removeWistiaLocalStorage},22:(t,e,r)=>{r.d(e,{cacheMediaData:()=>n,uncacheMediaData:()=>s});var i=r(3);null==i.default._remoteData&&(i.default._remoteData={});var n=function(t,e){return i.default._remoteData["media_".concat(t)]=e},s=function(t){i.default._remoteData["media_".concat(t)]=null,delete i.default._remoteData["media_".concat(t)]}},32:(t,e,r)=>{r.d(e,{mediaDataTransforms:()=>c});var i=r(6),n=r(24),s=r(11),a=r(33);function o(t){return function(t){if(Array.isArray(t))return l(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return l(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return l(t,e)}(t)||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 l(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,i=new Array(e);r1&&void 0!==arguments[1]?arguments[1]:{},r=(0,i.assign)({},t);return r=function(t){if(!0!==(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).allowOriginalAsMp4)return t;var e=t.assets.filter((function(t){return"original"===t.type}))[0];return(0,a.readyPublicOver400)(t.assets).length>0||(t.assets=[].concat(o(t.assets),[(0,i.assign)({},e,{display_name:"".concat(e.display_name," copy"),container:"mp4",codec:"h264",type:"mp4_video"})])),t}(r,e),r=function(t){return t.assets&&u.webp&&(t.assets=t.assets.map((function(t){if("still_image"===t.type&&Object(t).url){var e=new n.Url(t.url);e.ext("webp"),t.url=e.absolute()}return t}))),t}(r),r}},21:(t,e,r)=>{r.d(e,{fetchFreshMediaDataJson:()=>a});r(4);var i=r(3),n=(r(6),r(12)),s=(r(18),r(22),r(23));r(26),r(29),r(32),r(34);null==i.default._remoteData&&(i.default._remoteData={});var a=function(t,e){var r=o(t,e);return fetch(r).then((function(t){return t.json()})).catch((function(t){n.wlog.error("error fetching mediaData",t)}))},o=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(0,s.mediaDataHost)(e);return"".concat((0,s.eV1Protocol)(),"//").concat(r,"/embed/medias/").concat(t,".json")}},29:(t,e,r)=>{r.d(e,{count:()=>m,sample:()=>p,send:()=>f});var i=r(3),n=r(30),s=r(12),a=r(6),o=r(5),l=r(24),u=r(23),c=r(31),h=i.default;null==h._metricsCache&&(h._metricsCache={});var d=h._metricsCache,f=function(t,e,r){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};try{null==d.toMput&&(d.toMput=[]),null==d.requestId&&(d.requestId=0);var l=(0,a.merge)({type:t,key:e,value:null!=r?r:null,request_id:d.requestId},i),u=JSON.stringify(l);s.wlog.debug("send metrics",u),d.toMput.push(u),(0,n.doTimeout)("metrics.debounce",(function(){(0,o.pageLoaded)((function(){g.apply(undefined,d.toMput),d.toMput=[],d.requestId+=1}))}),500)}catch(t){s.wlog.error(t)}},g=function(){if((0,c.isVisitorTrackingEnabled)()){for(var t="".concat((0,l.proto)(),"//").concat((0,u.metricsHost)(),"/mput?topic=metrics"),e=arguments.length,r=new Array(e),i=0;i1&&void 0!==arguments[1]?arguments[1]:1,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{})},p=function(t,e,r){return f("sample",t,e,r)}},28:(t,e,r)=>{r.d(e,{getLocalStorage:()=>l,removeLocalStorage:()=>u,setLocalStorage:()=>c,updateLocalStorage:()=>h});var i=r(3),n=function(t){setTimeout((function(){throw t}),0)},s="_namespacedLocalStorage",a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"wistia-test-localstorage";if(null!=i.default._localStorageWorks)return i.default._localStorageWorks;try{var e=localStorage.getItem(t);localStorage.removeItem(t),localStorage.setItem(t,e),localStorage.removeItem(t),i.default._localStorageWorks=!0}catch(t){i.default._localStorageWorks=!1}return i.default._localStorageWorks},o=function(){return null==i.default[s]&&(i.default[s]={}),i.default[s]},l=function(t){if(!a())return o()[t]||{};if(localStorage[t])try{return"null"===localStorage[t]?{}:JSON.parse(localStorage[t])}catch(t){n(t)}return{}},u=function(t){if(a())try{localStorage.removeItem(t)}catch(t){n(t)}else o()[t]={}},c=function(t,e){if(!a())return null!=e&&"object"==typeof e&&(o()[t]=e),e;try{o()[t]=e,localStorage[t]=JSON.stringify(e)}catch(t){n(t)}return e},h=function(t,e){var r=l(t);try{e(r)}catch(t){n(t)}return c(t,r)}},6:(t,e,r)=>{r.d(e,{assign:()=>i.default,cast:()=>p,clone:()=>c,eachLeaf:()=>F,except:()=>E,filter:()=>L,getDeep:()=>h,isArray:()=>w,isEmpty:()=>P,isObject:()=>_,merge:()=>a,only:()=>T,select:()=>b,setAndPreserveUndefined:()=>f,setDeep:()=>d,sort:()=>A,unsetDeep:()=>m});var i=r(7),n=function(t,e){if(null==t)throw new TypeError("Cannot convert undefined or null to object");return Object.prototype.hasOwnProperty.call(Object(t),e)},s=Array.prototype.slice,a=function(t){if(0==(arguments.length<=1?0:arguments.length-1))return t;for(var e=0;e<(arguments.length<=1?0:arguments.length-1);e++)o(t,e+1<1||arguments.length<=e+1?void 0:arguments[e+1]);return t},o=function t(e,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:u;if(w(r)){w(e)||(e=[]);for(var a=0;a3&&void 0!==arguments[3])||arguments[3],n=(e="string"==typeof e?e.split("."):s.call(e)).pop();null!=(t=h(t,e,!0))&&(_(t)||w(t))&&null!=n&&(i&&null==r?delete t[n]:t[n]=r)},m=function(t,e){return d(t,e)},p=function(t){return null==t?t:_(t)||w(t)?y(t):v("".concat(t),t)},v=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t;return/^-?[1-9]\d*?$/.test(t)?parseInt(t,10):"0"===t||"-0"===t?0:/^-?\d*\.\d+$/.test(t)?parseFloat(t):!!/^true$/i.test(t)||!/^false$/i.test(t)&&e},y=function(t){return o(t,t,(function(t){return"string"==typeof t?v(t):t}),(function(){return!1}))},T=function(t,e){for(var r={},i={},n=0;nu[1]){o=!1;break}}else if(u instanceof RegExp){if(!u.test(a[l])){o=!1;break}}else if(u instanceof S){for(var c=!1,h=0;h0;){var s=i.shift().split(/\s+/),a=s[0],o=s[1];if(o="desc"===o?-1:1,t[a]{r.d(e,{default:()=>i});const i=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4e3,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:document,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:window;if(/loaded|complete/.test(r.readyState))setTimeout(t,0);else{var n=function(){i.removeEventListener("load",s,!1)},s=function(){clearTimeout(a),n(),t()};i.addEventListener("load",s,!1);var a=setTimeout((function(){n(),t()}),e)}}},216:(t,e,r)=>{r.d(e,{PLAYER_VERSION:()=>i});var i=1.14},9:(t,e,r)=>{r.d(e,{default:()=>i});const i=function(t,e,r,i,n){var s=null,a=(new Date).getTime();s=setTimeout((function o(){(new Date).getTime()-a>i?"function"==typeof n&&n():t()?e():(clearTimeout(s),s=setTimeout(o,r))}),1)}},4:(t,e,r)=>{var i;r.d(e,{default:()=>n});try{(i=self).self!==i&&void 0!==i.self&&"undefined"!=typeof window&&(i=window)}catch(t){i="undefined"!=typeof globalThis?globalThis:window}const n=i},19:(t,e,r)=>{r.d(e,{default:()=>i});const i=function(t,e){return new Promise((function(r,i){var n;null==e&&(e=8e3),(n=document.createElement("script")).src=t,n.async=!0,n.type="text/javascript";var s=null,a=!1,o=function(){n.onerror=n.onreadystatechange=n.onload=null,clearTimeout(s),clearTimeout(u),s=setTimeout((function(){n&&n.parentNode&&n.parentNode.removeChild(n)}),500)},l=function(){var t=n.readyState;a||t&&!/loaded|complete/.test(t)||(a=!0,setTimeout((function(){r(),o()}),1))},u=setTimeout((function(){a=!0,o(),i(new Error("timeout"))}),e);n.onerror=function(t){a=!0,o(),i(t)},n.onreadystatechange=l,n.onload=l,(document.body||document.head).appendChild(n)}))}},17:(__unused_webpack___webpack_module__,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{execScriptTags:()=>execScriptTags,getScriptTags:()=>getScriptTags,removeScriptTags:()=>removeScriptTags});var utilities_script_utils_js__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(18),getScriptTags=function(t){return t.match(/]*>\s*<\/script>|[\s\S]+?<\/script>/gi)||[]},scriptTagsToRunScriptsInput=function scriptTagsToRunScriptsInput(scriptTags){if(!scriptTags)return[];scriptTags instanceof Array||(scriptTags=getScriptTags(scriptTags));for(var hashes=[],_loop=function _loop(){var scriptTag=scriptTags[i],hash={},matches=scriptTag.match(//i);if(matches&&(matches=matches[0].match(/src="([^"]+)"/i),matches&&(hash.src=matches[1],hash.async=/async/i.test(scriptTag.replace(hash.src,"")))),!matches&&(matches=scriptTag.match(/