diff --git a/app/static/js/VideoPlayer.js b/app/static/js/VideoPlayer.js index 412b26f..2687c4b 100644 --- a/app/static/js/VideoPlayer.js +++ b/app/static/js/VideoPlayer.js @@ -180,6 +180,9 @@ window.VideoPlayer = function(options) { } } async function toggleFullscreen(event) { + if (typeof window.TelegramWebview !== 'undefined') { { + return + } if (isIOS) { return } @@ -279,6 +282,10 @@ window.VideoPlayer = function(options) { self.controls.querySelector('.toggle').addEventListener("click", toggleVideo) self.controls.querySelector('.volume').addEventListener("click", toggleSound) self.controls.querySelector('.fullscreen-btn').addEventListener("click", toggleFullscreen) + if (typeof window.TelegramWebview !== 'undefined') { { + self.controls.querySelector('.fullscreen-btn').style.display = 'none'; + return + } document.addEventListener('fullscreenchange', event => { if (!document.fullscreenElement) { screen.orientation.unlock()