mirror of
https://github.com/IAmParadox27/jellyfin-plugin-media-bar.git
synced 2026-11-10 16:34:35 +01:00
Merge pull request #122 from Omar-Alodwan/jmp-no-replacechildren
Avoid Element.replaceChildren so the bar loads in Jellyfin Media Player
This commit is contained in:
1 file changed
+5
-2
+5
-2
@@ -2912,7 +2912,10 @@ const SlideCreator = {
|
||||
);
|
||||
|
||||
const host = document.getElementById(`yt-player-${itemId}`);
|
||||
host?.replaceChildren(video);
|
||||
if (host) {
|
||||
host.textContent = "";
|
||||
host.appendChild(video);
|
||||
}
|
||||
STATE.slideshow.players[itemId] = createLocalPlayer(video);
|
||||
STATE.slideshow.slideVideoIds[itemId] = `local:${itemId}`;
|
||||
} else {
|
||||
@@ -2984,7 +2987,7 @@ const SlideshowManager = {
|
||||
container.appendChild(dotsContainer);
|
||||
}
|
||||
|
||||
dotsContainer.replaceChildren();
|
||||
dotsContainer.textContent = "";
|
||||
|
||||
const count = Math.min(STATE.slideshow.totalItems, CONFIG.maxDots);
|
||||
|
||||
|
||||
Reference in new issue
Block a user