diff options
| author | Physcik <mynameisgennadiy@vk.com> | 2025-12-13 22:31:06 +0500 |
|---|---|---|
| committer | Physcik <mynameisgennadiy@vk.com> | 2025-12-13 22:31:06 +0500 |
| commit | a0335da1f8402523cb13080761a1852e2636dc9a (patch) | |
| tree | a352d7ae5db7e1e8ee6eee483e458f739bbeb954 /static/index.js | |
| parent | bc93f0709cf603cd3c529d35bbb5e90a2aebfa99 (diff) | |
More frontend controls
Diffstat (limited to 'static/index.js')
| -rw-r--r-- | static/index.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/static/index.js b/static/index.js index 237386c..991eb6c 100644 --- a/static/index.js +++ b/static/index.js @@ -19,6 +19,7 @@ function SetRandomSong() { document.getElementById("Start").innerHTML = "Start: " + body.Start + "s"; player.play(); + player.currentTime = body.Start document.getElementById("Status").innerHTML = "Playing"; })); } @@ -46,3 +47,9 @@ function ToggleInfo() { isInfoShown = true; } } + +function SetVolume() { + const player = document.getElementById("mainAudio"); + const slider = document.getElementById("volumeRange"); + player.volume = slider.value / 100; +} |
