From 094bdb29b6b6872907c222c4cfe2d2b2842b3b23 Mon Sep 17 00:00:00 2001 From: Blaz Kristan Date: Wed, 8 Dec 2021 22:41:16 +0100 Subject: [PATCH] Fix for >10 buttons. --- wled00/data/settings_leds.htm | 4 ++-- wled00/data/settings_time.htm | 8 ++++---- wled00/html_settings.h | 4 ++-- wled00/set.cpp | 10 +++++----- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/wled00/data/settings_leds.htm b/wled00/data/settings_leds.htm index 34ccf90e..86cdb510 100644 --- a/wled00/data/settings_leds.htm +++ b/wled00/data/settings_leds.htm @@ -349,8 +349,8 @@ ${i+1}: } function addBtn(i,p,t) { var c = gId("btns").innerHTML; - var bt = "BT" + i; - var be = "BE" + i; + var bt = "BT" + String.fromCharCode((i<10?48:55)+i);; + var be = "BE" + String.fromCharCode((i<10?48:55)+i);; c += `Button ${i} GPIO: `; c += ` `; + td.innerHTML = ``; td = tr.insertCell(2); - td.innerHTML = ``; + td.innerHTML = ``; td = tr.insertCell(3); - td.innerHTML = ``; + td.innerHTML = ``; } function GetV() { diff --git a/wled00/html_settings.h b/wled00/html_settings.h index fb6ad75a..c3e7d1da 100644 --- a/wled00/html_settings.h +++ b/wled00/html_settings.h @@ -74,7 +74,7 @@ onclick="B()">Back // Autogenerated from wled00/data/settings_leds.htm, do not edit!! const char PAGE_settings_leds[] PROGMEM = R"=====(LED Settings