quick fix 2d config hor/ver/panel issues + battery usermod

- Add battery usermod
- set segexp default true
- quick fix 2d config hor/ver/panel issues
This commit is contained in:
Ewoud
2023-01-03 14:45:01 +01:00
parent 9bc6451145
commit 545a4c820c
9 changed files with 1368 additions and 1354 deletions

View File

@@ -25,7 +25,7 @@ var ws, cpick, ranges;
var cfg = {
theme:{base:"dark", bg:{url:""}, alpha:{bg:0.6,tab:0.8}, color:{bg:""}},
comp :{colors:{picker: true, rgb: false, quick: true, hex: false},
labels:true, pcmbot:false, pid:true, seglen:false, segpwr:false, segexp:false, css:true, hdays:false}
labels:true, pcmbot:false, pid:true, seglen:false, segpwr:false, segexp:true, css:true, hdays:false} //WLEDMM segexp true as default
};
var hol = [
[0,11,24,4,"https://aircoookie.github.io/xmas.png"], // christmas

View File

@@ -44,7 +44,7 @@
loadJS(url, false); // If we set async false, file is loaded and executed, then next statement is processed
}
function UI(panels=1)
function UI(panels=-1) //WLEDM quick fix
{
gId("mpdiv").style.display = "block";
@@ -54,9 +54,11 @@
return;
}
let i = gId("panels").children.length;
if (i<panels) for (let j=i; j<panels; j++) addPanel(j);
if (i>panels) for (let j=i; j>panels; j--) remPanel();
if (panels != -1) { //WLEDM quick fix
let i = gId("panels").children.length;
if (i<panels) for (let j=i; j<panels; j++) addPanel(j);
if (i>panels) for (let j=i; j>panels; j--) remPanel();
}
}
function addPanels() {