1"use strict";(self.webpackChunkbundle_default=self.webpackChunkbundle_default||[]).push([[544],{6068:function(e,t,i){i.d(t,{U:function(){return a},Y:function(){return r}});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"},l={playingInterval:5,playbackPosition:0,quartilePosition:-1};class r extends HTMLElement{connectedCallback(){this.intervals={...l}}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)}onMute(){this.emit(a.volumeChange)}onPause(){this.emit(a.pause)}onEnded(){this.intervals={...l},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(){}
1onEnterFullScreen(){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)}}},4273:function(e,t,i){i.r(t),i.d(t,{default:function(){return r}});var a=i(6068);let l=!1;class r extends a.Y{async connectedCallback(){super.connectedCallback();try{await new Promise(((e,t)=>{if(l)e("YouTube iFrame API already loaded");else if(void 0!==window.YT&&void 0!==window.YT.Player)l=!0,e("YouTube iFrame API already loaded");else{const i=document.createElement("script");i.src="https://www.youtube.com/iframe_api";const a=document.getElementsByTagName("script")[0];if(a.parentNode.insertBefore(i,a),window.onYouTubeIframeAPIReady){const t=window.onYouTubeIframeAPIReady;window.onYouTubeIframeAPIReady=()=>{t&&t(),l=!0,e("YouTube iFrame API loaded")}}else window.onYouTubeIframeAPIReady=()=>{l=!0,e("YouTube iFrame API loaded")};i.onerror=()=>{t(new Error("Failed to load YouTube iFrame API"))}}}))}catch(e){console.error(e.message)}this._player=new window.YT.Player(this.querySelector("iframe"),{events:{onReady:()=>this.onReady(),onStateChange:e=>this.onStateChange(e)}})}onStateChange(e){const t=e.data;t===window.YT.PlayerState.ENDED&&this.onEnded(),t===window.YT.PlayerState.PLAYING&&this.onPlay(),t===window.YT.PlayerState.PAUSED&&this.onPause()}play(){try{this._player.playVideo()}catch(e){console.log(e)}}}}}]);
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.