diff --git a/ui/component/viewers/videoViewer/internal/videojs.jsx b/ui/component/viewers/videoViewer/internal/videojs.jsx index 157c20b63..5caa9aa34 100644 --- a/ui/component/viewers/videoViewer/internal/videojs.jsx +++ b/ui/component/viewers/videoViewer/internal/videojs.jsx @@ -556,12 +556,13 @@ export default React.memo(function VideoJs(props: Props) { if(isNotAndroidOrIos){ el.classList.add('vjs-big-play-centered'); + + const playBT = document.getElementsByClassName('vjs-big-play-button')[0]; + playBT.style.display = 'none'; } const player = playerRef.current; - const playBT = document.getElementsByClassName('vjs-big-play-button')[0]; - playBT.style.display = 'none'; // this seems like a weird thing to have to check for here if (!player) return; @@ -593,29 +594,29 @@ export default React.memo(function VideoJs(props: Props) { // }) // on ios, show a play button when paused - if (IS_IOS) { - const playBT = document.getElementsByClassName('vjs-big-play-button')[0]; - - player.on('pause', function() { - playBT.style.removeProperty('display'); - - const videoDiv = player.children_[0]; - const controlBar = document.getElementsByClassName('vjs-control-bar')[0]; - const leftWidth = ((videoDiv.offsetWidth - playBT.offsetWidth) / 2) + 'px'; - const availableHeight = videoDiv.offsetHeight - controlBar.offsetHeight; - const topHeight = (((availableHeight - playBT.offsetHeight) / 2) + 11) + 'px'; - - playBT.style.top = topHeight; - playBT.style.left = leftWidth; - playBT.style.margin = 0; - }); - - player.on('ended', function() { - if (showAutoplayCountdown) { - playBT.style.display = 'none'; - } - }); - } + // if (IS_IOS) { + // const playBT = document.getElementsByClassName('vjs-big-play-button')[0]; + // + // player.on('pause', function() { + // playBT.style.removeProperty('display'); + // + // const videoDiv = player.children_[0]; + // const controlBar = document.getElementsByClassName('vjs-control-bar')[0]; + // const leftWidth = ((videoDiv.offsetWidth - playBT.offsetWidth) / 2) + 'px'; + // const availableHeight = videoDiv.offsetHeight - controlBar.offsetHeight; + // const topHeight = (((availableHeight - playBT.offsetHeight) / 2) + 11) + 'px'; + // + // playBT.style.top = topHeight; + // playBT.style.left = leftWidth; + // playBT.style.margin = 0; + // }); + // + // player.on('ended', function() { + // if (showAutoplayCountdown) { + // playBT.style.display = 'none'; + // } + // }); + // } // Replace volume bar with custom LBRY volume bar LbryVolumeBarClass.replaceExisting(player);