From c90cfd17712a40be2e9319d4b8e389a1b1f98ff4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juraj=20Nyi=CC=81ri?= Date: Tue, 15 Jun 2021 22:13:12 +0200 Subject: [PATCH] Fix: Disable scroll control on fullscreen video --- dist/plex-meets-homeassistant.js | 2 +- src/plex-meets-homeassistant.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/plex-meets-homeassistant.js b/dist/plex-meets-homeassistant.js index 292aa5a..ce0eca9 100644 --- a/dist/plex-meets-homeassistant.js +++ b/dist/plex-meets-homeassistant.js @@ -20033,7 +20033,7 @@ class PlexMeetsHomeAssistant extends HTMLElement { this.loadInitialData = async () => { window.addEventListener('scroll', () => { // todo: improve performance by calculating this when needed only - if (this.detailsShown && this.activeMovieElem) { + if (this.detailsShown && this.activeMovieElem && !isVideoFullScreen(this)) { const seasonContainers = this.getElementsByClassName('seasonContainer'); const episodeContainers = this.getElementsByClassName('episodeContainer'); const seasonElems = this.getElementsByClassName('seasonElem'); diff --git a/src/plex-meets-homeassistant.ts b/src/plex-meets-homeassistant.ts index 2f8d0eb..ad525f3 100644 --- a/src/plex-meets-homeassistant.ts +++ b/src/plex-meets-homeassistant.ts @@ -152,7 +152,7 @@ class PlexMeetsHomeAssistant extends HTMLElement { loadInitialData = async (): Promise => { window.addEventListener('scroll', () => { // todo: improve performance by calculating this when needed only - if (this.detailsShown && this.activeMovieElem) { + if (this.detailsShown && this.activeMovieElem && !isVideoFullScreen(this)) { const seasonContainers = this.getElementsByClassName('seasonContainer') as HTMLCollectionOf; const episodeContainers = this.getElementsByClassName('episodeContainer') as HTMLCollectionOf; const seasonElems = this.getElementsByClassName('seasonElem') as HTMLCollectionOf;