diff --git a/static/js/app.js b/static/js/app.js index 6f66951..93304c7 100644 --- a/static/js/app.js +++ b/static/js/app.js @@ -205,6 +205,16 @@ if (volNumEl) { volNumEl.addEventListener('click', function () { this.select(); }); } +const volSliderEl2 = document.getElementById('volume'); +const volWheelTarget = volSliderEl2 || volNumEl; +if (volWheelTarget) { + volWheelTarget.addEventListener('wheel', function (e) { + e.preventDefault(); + const current = parseInt(document.getElementById('volume').value, 10); + setVolume(current + (e.deltaY < 0 ? 4 : -4)); + }, { passive: false }); +} + // --------------------------------------------------------------------------- // SSE metadata // ---------------------------------------------------------------------------