@@ -28,7 +28,7 @@ var options = {
2828 overrideNative : true
2929 }
3030 }
31- }
31+ } ;
3232
3333if ( player_data . aspect_ratio ) {
3434 options . aspectRatio = player_data . aspect_ratio ;
@@ -147,43 +147,43 @@ if (isMobile()) {
147147
148148 buttons = [ "playToggle" , "volumePanel" , "captionsButton" ] ;
149149
150- if ( video_data . params . quality !== 'dash' ) buttons . push ( "qualitySelector" )
150+ if ( video_data . params . quality !== 'dash' ) buttons . push ( "qualitySelector" ) ;
151151
152152 // Create new control bar object for operation buttons
153153 const ControlBar = videojs . getComponent ( "controlBar" ) ;
154154 let operations_bar = new ControlBar ( player , {
155155 children : [ ] ,
156156 playbackRates : [ 0.25 , 0.5 , 0.75 , 1.0 , 1.25 , 1.5 , 1.75 , 2.0 ]
157157 } ) ;
158- buttons . slice ( 1 ) . forEach ( child => operations_bar . addChild ( child ) )
158+ buttons . slice ( 1 ) . forEach ( child => operations_bar . addChild ( child ) ) ;
159159
160160 // Remove operation buttons from primary control bar
161161 primary_control_bar = player . getChild ( "controlBar" ) ;
162162 buttons . forEach ( child => primary_control_bar . removeChild ( child ) ) ;
163163
164164 operations_bar_element = operations_bar . el ( ) ;
165- operations_bar_element . className += " mobile-operations-bar"
166- player . addChild ( operations_bar )
165+ operations_bar_element . className += " mobile-operations-bar" ;
166+ player . addChild ( operations_bar ) ;
167167
168168 // Playback menu doesn't work when it's initialized outside of the primary control bar
169- playback_element = document . getElementsByClassName ( "vjs-playback-rate" ) [ 0 ]
170- operations_bar_element . append ( playback_element )
169+ playback_element = document . getElementsByClassName ( "vjs-playback-rate" ) [ 0 ] ;
170+ operations_bar_element . append ( playback_element ) ;
171171
172172 // The share and http source selector element can't be fetched till the players ready.
173173 player . one ( "playing" , ( ) => {
174- share_element = document . getElementsByClassName ( "vjs-share-control" ) [ 0 ]
175- operations_bar_element . append ( share_element )
174+ share_element = document . getElementsByClassName ( "vjs-share-control" ) [ 0 ] ;
175+ operations_bar_element . append ( share_element ) ;
176176
177177 if ( video_data . params . quality === 'dash' ) {
178- http_source_selector = document . getElementsByClassName ( "vjs-http-source-selector vjs-menu-button" ) [ 0 ]
179- operations_bar_element . append ( http_source_selector )
178+ http_source_selector = document . getElementsByClassName ( "vjs-http-source-selector vjs-menu-button" ) [ 0 ] ;
179+ operations_bar_element . append ( http_source_selector ) ;
180180 }
181- } )
181+ } ) ;
182182}
183183
184184// Enable VR video support
185185if ( ! video_data . params . listen && video_data . vr && video_data . params . vr_mode ) {
186- player . crossOrigin ( "anonymous" )
186+ player . crossOrigin ( "anonymous" ) ;
187187 switch ( video_data . projection_type ) {
188188 case "EQUIRECTANGULAR" :
189189 player . vr ( { projection : "equirectangular" } ) ;
@@ -280,7 +280,7 @@ player.on('volumechange', function () {
280280
281281player . on ( 'waiting' , function ( ) {
282282 if ( player . playbackRate ( ) > 1 && player . liveTracker . isLive ( ) && player . liveTracker . atLiveEdge ( ) ) {
283- console . log ( 'Player has caught up to source, resetting playbackRate.' )
283+ console . log ( 'Player has caught up to source, resetting playbackRate.' ) ;
284284 player . playbackRate ( 1 ) ;
285285 }
286286} ) ;
@@ -767,12 +767,12 @@ if (window.location.pathname.startsWith("/embed/")) {
767767
768768 // Create hyperlink for current instance
769769 redirect_element = document . createElement ( "a" ) ;
770- redirect_element . setAttribute ( "href" , `//${ window . location . host } /watch?v=${ window . location . pathname . replace ( "/embed/" , "" ) } ` )
771- redirect_element . appendChild ( document . createTextNode ( "Invidious" ) )
770+ redirect_element . setAttribute ( "href" , `//${ window . location . host } /watch?v=${ window . location . pathname . replace ( "/embed/" , "" ) } ` ) ;
771+ redirect_element . appendChild ( document . createTextNode ( "Invidious" ) ) ;
772772
773- watch_on_invidious_button . el ( ) . appendChild ( redirect_element )
774- watch_on_invidious_button . addClass ( "watch-on-invidious" )
773+ watch_on_invidious_button . el ( ) . appendChild ( redirect_element ) ;
774+ watch_on_invidious_button . addClass ( "watch-on-invidious" ) ;
775775
776- cb = player . getChild ( 'ControlBar' )
777- cb . addChild ( watch_on_invidious_button )
778- } ;
776+ cb = player . getChild ( 'ControlBar' ) ;
777+ cb . addChild ( watch_on_invidious_button ) ;
778+ }
0 commit comments