1"use strict";(self.webpackChunkbundle_default=self.webpackChunkbundle_default||[]).push([[970],{970:function(e,t,i){i.r(t),i.d(t,{default:function(){return s}});var a=i(6068);class s extends a.Y{constructor(){super(),this.playing=!1,this.player=null}get videoElement(){return this.querySelector("video")}connectedCallback(){if(super.init(),this.player=this,this.playerVId=this.player.getAttribute("data-player")||!1,this.videoVId=this.player.getAttribute("data-video-uuid")||!1,this.mediaVId=this.player.getAttribute("data-media-id")||!1,!(this.playerVId&&this.mediaVId&&this.videoVId))return console.info("JW Video Player: Cannot play video, no media, player or video ID found"),!1;this.init()}disconnectedCallback(){window.jwplayer(this.videoElement)&&window.jwplayer(this.videoElement).remove()}init(){this.loadJwApi(this.playerVId)}loadJwApi(e){if(window.jwplayer)this.onJwApiReady();else{const t=document.createElement("script");t.src="https://cdn.jwplayer.com/libraries/"+e+".js",t.addEventListener("load",this.onJwApiReady.bind(this));const i=document.getElementsByTagName("script")[0];i.parentNode.insertBefore(t,i)}}onJwApiReady(){this.videoPlayer=this.player.querySelector("video"),this.thePlayer=window.jwplayer(this.videoElement),void 0!==this.thePlayer&&(this.thePlayer.setup({playlist:`https://cdn.jwplayer.com/v2/media/${this.mediaVId}`,image:this.poster,width:"100%",responsive:"true",aspectratio:"16:9",title:this.videoTitle,mute:this.muted,autostart:this.autoplay}),this.playerEvents())}playerEvents(){this.thePlayer.on("ready",(e=>{this.onReady(e)})),this.thePlayer.on("play",(e=>{this.playing=!0,this.onPlay(e)})),this.thePlayer.on("pause",(e=>{this.onPause(e)})),this.thePlayer.on("mute",(e=>{this.onMute(e)})),this.thePlayer.on("time",(e=>{this.currentTime=this.thePlayer.getPosition(),this.duration=this.thePlayer.getDuration(),this.onTimeUpdate(e)})),this.thePlayer.on("complete",(e=>{this.playing=!1,this.onEnded(e)}))}play(){this.thePlayer.play()}pause(){this.thePlayer.pause()}}},6068:function(e,t,i){i.d(t,{U:function(){return a},Y:function(){return l}});const a={ready:"VideoPlayer:ready",timeUpdate:"VideoPlayer:timeUpdate",play:"VideoPlayer:play",playing:"VideoPlayer:playing",pause:"VideoPlayer:paused",volumeChange:"VideoPlayer:volumeChange",enterFullscreen:"VideoPlayer:enterFullscreen",exitFullscreen:"VideoPlayer:exitFullscreen",ended:"VideoPlayer:ended",error:"VideoPlayer:error",quartileCompleted:"VideoPlayer:quartileCompleted"},s={playingInterval:5,playbackPosition:0,quartilePosition:-1};class l extends HTMLElement{connectedCallback(){this.intervals={...s}}get videoId(){return this.getAttribute("video-id")}get videoTitle(){return this.getAttribute("video-title")}get playerId(){return this.getAttribute("player-id")}get autoplay(){return this.hasAttribute("autoplay")}get disableClickToPlay(){return this.hasAttribute("disable-click-to-play")}get muted(){return this.hasAttribute("muted")}get loop(){return this.hasAttribute("loop")}get poster(){return this.getAttribute("poster")}get video(){return{id:this.videoId,videoPlatform:this.platform,seekSeconds:this.seekSeconds,title:this.videoTitle,inPlaylist:document.querySelector("ps-playlist"),playListTagsosition:[...document.querySelectorAll("ps-playlist-item")].findIndex((e=>e.isCurrent)),duration:this.duration,playerWidth:this.getPlayerWidth(),playerHeight:this.getPlayerHeight(),playerResolution:this.getPlayerResolution(),isAutoPlay:this.getIsAutoPlay(),startVolume:this.getStartVolume(),volume:this.getVolume(),isFullscreen:this.onVideoFullscreen(),videoUuid:this.getVideoUuid(),videoFileType:this.getVideoFileType(),videoInitiation:this.getAttribute("data-playback-started")||!1,credit:this.getCredit(),ownerSite:this.getOwnerSite(),videoClassification:this.getCategory(),source:this.getSource(),location:this.getDateline(),videoStatus:this.getVideoStatus(),quartile:this.getDisplayQuartile(this.intervals.quartilePosition)}}init(){this.platform=this.getPlatformName()}onReady(){this.emit(a.ready)}onPlay(){this.emit(a.playing)}onTimeUpdate(){this.sendVideoPlaybackIntervalEvents(),this.emit(a.timeUpdate)}
1onMute(){this.emit(a.volumeChange)}onPause(){this.emit(a.pause)}onEnded(){this.intervals={...s},this.emit(a.ended)}onError(){this.emit(a.error)}onVolumneChange(){this.emit(a.volumeChange)}play(){}pause(){}playPause(){this.getAttribute("data-playback-paused")?this.play():this.pause()}sendVideoPlaybackIntervalEvents(){if(!this.duration||0===this.duration)return;const e=this.currentTime/this.duration*100;for(;this.currentTime>this.intervals.playbackPosition+2*this.intervals.playingInterval;)this.intervals.playbackPosition+=this.intervals.playingInterval;if(this.currentTime>=this.intervals.playbackPosition+this.intervals.playingInterval){this.intervals.playbackPosition+=this.intervals.playingInterval;const e=new window.CustomEvent("Video:onVideoTimeIntervalUpdate",{bubbles:!0,detail:{playerId:this.playerId,videoPlatform:this.platform,video:this.video,secondsElapsed:this.currentTime}});this.dispatchEvent(e)}let t=null;if(e>=this.intervals.quartilePosition)if(-1===this.intervals.quartilePosition){if(e>=this.intervals.quartilePosition+25)for(this.intervals.quartilePosition=0;e>=this.intervals.quartilePosition;)this.intervals.quartilePosition+=25}else t=this.intervals.quartilePosition,this.intervals.quartilePosition+=25,100===this.intervals.quartilePosition&&(this.intervals.quartilePosition=95);null!==t&&(95===t&&(t=100),this.emit(a.quartileCompleted,{quartile:t}))}getDisplayQuartile(e){return-1===e?0:50===e?25:75===e?50:95===e?75:100}getCategory(){}getCredit(){}getDateline(){}getIsAutoPlay(){}getOwnerSite(){}getPlatformName(){}getPlayerHeight(){}getPlayerWidth(){}getPlayerResolution(){return this.getPlayerWidth()+" x "+this.getPlayerHeight()}getPlayListTagsosition(e){const t=document.querySelector("[data-playlist]"),i=t.querySelectorAll(".PlaylistItem"),a=t.querySelector(`[data-video-id='${e}']`);for(let e=0;e<i.length;e++)if(a===i[e])return e}getSource(){}getVideoFileType(){}getVideoStatus(){return this.getAttribute("data-playback-playing")?"Playing":this.getAttribute("data-playback-paused")?"Paused":this.getAttribute("data-playback-ended")?"Ended":null}getVideoUuid(){}getVolume(){}getStartVolume(){}onVideoFullscreen(){}onEnterFullScreen(){this.emit(a.enterFullscreen)}onExitFullscreen(){this.emit(a.exitFullscreen)}emit(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const i=new window.CustomEvent(e,{bubbles:!0,detail:t});this.dispatchEvent(i)}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.