Harmonize ledmap and jmap

ledmap: no lm prefix

jmap:
- also json extension (instead of jmap)
- also support json object with json array embedded:

{"n":"snake32"
,"width":32
,"height":32
,"map": []
}
This commit is contained in:
Ewoud
2023-03-17 15:44:23 +01:00
parent e3e5825618
commit 5ac9ffa073
8 changed files with 3611 additions and 3563 deletions

View File

@@ -723,7 +723,7 @@ function populateSegments(s)
let sg = gId(`seg${i}`);
let exp = sg ? (sg.classList.contains('expanded') || (i===0 && cfg.comp.segexp)) : false;
ledmapFileNames.push("lm" + (inst.n?inst.n:"default") + ".json"); //WLEDMM
ledmapFileNames.push((inst.n?inst.n:"default") + ".json"); //WLEDMM
let segp = `<div id="segp${i}" class="sbs">
<i class="icons e-icon pwr ${inst.on ? "act":""}" id="seg${i}pwr" onclick="setSegPwr(${i})">&#xe08f;</i>