From 18789ca7c489d2d67e3c8a6925ac5880e1d0997d Mon Sep 17 00:00:00 2001
From: BlueFox
Date: Tue, 26 Mar 2024 19:18:03 +0100
Subject: [PATCH] Added updating for some sliders etc.; some are still
remaining
---
simpledemo.html | 164 +++++++++++++++++++++++++-----------------------
1 file changed, 84 insertions(+), 80 deletions(-)
diff --git a/simpledemo.html b/simpledemo.html
index 6739a76..a4f778e 100644
--- a/simpledemo.html
+++ b/simpledemo.html
@@ -192,7 +192,7 @@
+ = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/playback/previous');http.send();updateStrings();">
@@ -200,17 +200,15 @@
+ = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/playback/play');http.send();updateStrings();">
-
+
@@ -218,7 +216,7 @@
+ onclick="http = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/playback/next');http.send();updateStrings();">
@@ -230,18 +228,12 @@
Volume
-
+
or btn-outline-danger'>
+ "http = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/volume/toggle_mute');http.send();updateStrings();"
+ class='btn btn-danger'>
@@ -270,14 +262,14 @@
aria-label='Playlist path (must start with a /)' aria-describedby='playlist_playBtn'
id='playlist_playPathInput'>
+ "playlistPath = document.getElementById('playlist_playPathInput').value;
+ http = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/playlist/play?playlist_path='+playlistPath);http.send();
+ updateStrings();">
Change
-
+
Demo for creating a new playlist containing all the contents of the given folder (on the SD card).
The new playlist will be located in the given folder and is named .directory.m3u
. This can't be changed.
@@ -288,9 +280,9 @@
aria-label='Folder path (must start with a /)' aria-describedby='playlist_createBtn'
id='playlist_createPathInput'>
+ "folderPath = document.getElementById('playlist_createPathInput').value;
+ http = new XMLHttpRequest();http.open('GET', 'http://' + document.cookie + '/api/v1/playlist/create?folder_path='+folderPath);http.send();
+ updateStrings();">
Change
@@ -322,8 +314,8 @@
Balance (-16 to 16)
-
+
@@ -358,18 +350,18 @@
Equalizer for lows (-40dB to 6dB)
-
+
Equalizer for mids (-40dB to 6dB)
-
+
Equalizer for highs (-40dB to 6dB)
-
+
@@ -391,12 +383,12 @@
->
-
+
Change
@@ -420,7 +412,7 @@
After doing this, you have to go down to the restart collapsible. There, restart the NetSpeaker and it should connect
to the configured WiFi.
If anything is wrong (either SSID or PSK wrong/typo, or the wifi's not available), the NetSpeaker opens an HotSpot
- with the SSID " + apSSID + "
and the PSK " + apPSK + "
!
+ with the SSID
and the PSK
!
SSID
{ configButtonEventListener(false); });
+ const ipAdressModalApplyBtn = document.getElementById('ipAdressModalApplyBtn');
+ ipAdressModalApplyBtn.addEventListener('click', () => { configButtonEventListener(false); });
- const ipAdressModalOkBtn = document.getElementById('ipAdressModalOkBtn');
- ipAdressModalOkBtn.addEventListener('click', () => { configButtonEventListener(true); });
+ const ipAdressModalOkBtn = document.getElementById('ipAdressModalOkBtn');
+ ipAdressModalOkBtn.addEventListener('click', () => { configButtonEventListener(true); });
- } else if (isValidIP(document.cookie)) setupSite();
+ } else if (isValidIP(document.cookie)) setupSite();
+ } // end of onload function