Possible fix for UI not loading on returning from Settings.

This commit is contained in:
Blaz Kristan 2022-01-22 13:54:17 +01:00
parent 6c52105ac7
commit 90ea01aa46
2 changed files with 1614 additions and 1606 deletions

View File

@ -38,9 +38,14 @@
l.addEventListener('load', (e) => {
// after rangetouch is loaded initialize global variable
ranges = RangeTouch.setup('input[type="range"]', {});
setTimeout(()=>{onLoad()},50); // start processing UI
let stateCheck = setInterval(() => {
if (document.readyState === 'complete') {
clearInterval(stateCheck);
// document ready, start processing UI
onLoad();
}
}, 100);
});
//h.appendChild(l); // if this fires too quickly for ESP8266 use next line
setTimeout(()=>{h.appendChild(l)},50);
});
setTimeout(()=>{h.appendChild(l)},50);

File diff suppressed because it is too large Load Diff