aboutsummaryrefslogtreecommitdiffstats
path: root/static/modules
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-11-10 19:58:53 +0100
committerDanilo M. <danix@danix.xyz>2026-11-10 19:58:53 +0100
commitd0ef71dc2e15860fb99e8d49810dc6d91ec76f79 (patch)
treef82a5d7c95765a142584f7d44cd82e412c55f7f2 /static/modules
parentf363c7052251da945724eb9c7e6fcd5eebadd393 (diff)
downloaddeck-it-d0ef71dc2e15860fb99e8d49810dc6d91ec76f79.tar.gz
deck-it-d0ef71dc2e15860fb99e8d49810dc6d91ec76f79.zip
fix(dashboard): review fixes
- The OBS slot has no one-tap stop: a tap opens the OBS tab, so a stray touch cannot end a recording. - Scrolling lines are measured once their slot is on screen, and every slot again when one comes or goes. - The lock watcher survives a missing pidof. - Trend gradients are in user space, so a flat line still paints. - Uptime under an hour shows minutes. - The shell no longer imports panel files for the modules the dashboard draws. - The spec matches the build VM and OBS slots and the error wording. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'static/modules')
-rw-r--r--static/modules/obs.js11
1 files changed, 4 insertions, 7 deletions
diff --git a/static/modules/obs.js b/static/modules/obs.js
index bcf237b..f7969b8 100644
--- a/static/modules/obs.js
+++ b/static/modules/obs.js
@@ -55,23 +55,20 @@ async function post(action, body = {}) {
}
// The dashboard's running slot: what is live, the scene and the elapsed
-// time, and a stop for it.
+// time. No stop here: a tap opens the OBS tab, so a stray touch cannot end a
+// recording.
export const busy = (st) => Boolean(st.connected && (st.recording || st.streaming));
export function slot(st, el) {
if (!el.firstChild) {
el.innerHTML = `<i class="nf sic rec"></i>
<span class="what"><span></span></span><span class="pct num"></span>
- <span class="meta"><span></span></span>
- <button class="act">Stop</button>`;
+ <span class="meta"><span></span></span>`;
}
const what = st.recording ? (st.paused ? "Recording paused" : "Recording") : "Streaming";
el.querySelector(".what > span").textContent = `${what} · ${st.currentScene ?? ""}`;
el.querySelector(".pct").textContent = st.recording ? clock(st.recordingTime) : "live";
- el.querySelector(".meta > span").textContent =
- [st.recording ? "recording" : null, st.streaming ? "streaming" : null].filter(Boolean).join(" + ");
- el.querySelector(".act").onclick = () =>
- post(st.recording ? "record" : "stream", { on: false });
+ el.querySelector(".meta > span").textContent = st.recording && st.streaming ? "and streaming" : "";
}
function bigButton(kind, name, label, on, times) {