Change IDs for volumeControls, volumeSlider, and controlMute when looping (watch.js)

This commit is contained in:
IgorA100
2026-02-09 20:27:46 +03:00
committed by GitHub
parent 3fe3813de6
commit 09156ccf11

View File

@@ -896,6 +896,13 @@ function streamReStart(oldId, newId) {
//Change main monitor block
monitor_div.innerHTML = currentMonitor.streamHTML;
const volumeControls = document.getElementById('volumeControls'+oldId);
if (volumeControls) volumeControls.id = 'volumeControls'+newId;
const volumeSlider = document.getElementById('volumeSlider'+oldId);
if (volumeSlider) volumeSlider.id = 'volumeSlider'+newId;
const controlMute = document.getElementById('controlMute'+oldId);
if (controlMute) controlMute.id = 'controlMute'+newId;
//Change active element of the navigation menu
document.getElementById('nav-item-cycle'+oldId).querySelector('a').classList.remove("active");
document.getElementById('nav-item-cycle'+newId).querySelector('a').classList.add("active");