aboutsummaryrefslogtreecommitdiffstats
path: root/static/deck.css
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-11-10 13:03:07 +0100
committerDanilo M. <danix@danix.xyz>2026-11-10 13:03:07 +0100
commit8ec2352c22780202fcd39982f1c3e65d2dae0cc1 (patch)
treebe44dfe4b18fe58c6b3b998be5c7c0cdcff46648 /static/deck.css
parent7a9d73a2021d0d14be556531adee83531aaa6c15 (diff)
downloaddeck-it-8ec2352c22780202fcd39982f1c3e65d2dae0cc1.tar.gz
deck-it-8ec2352c22780202fcd39982f1c3e65d2dae0cc1.zip
feat: "The PC is asleep" overlay, and the tablet may sleep too
A sleeping PC answers no poll, and the wake lock kept the tablet's screen on over a frozen dashboard all night. After 15 s without any answer the page shows an overlay and releases the lock; the first answer hides it and takes the lock again. Checked on the tablet by stopping the server for 21 s: no screen wake lock while stopped, Chrome's taken again 5 s after it resumed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'static/deck.css')
-rw-r--r--static/deck.css9
1 files changed, 9 insertions, 0 deletions
diff --git a/static/deck.css b/static/deck.css
index faaf789..d998af4 100644
--- a/static/deck.css
+++ b/static/deck.css
@@ -677,3 +677,12 @@ select {
.assistant .as-op.good { color: var(--udt-green); }
.assistant .as-op.bad { color: var(--udt-red); }
.assistant .md, .assistant .as-q { user-select: text; }
+
+/* The PC asleep: over everything, and the wake lock is dropped (app.js). */
+#asleep {
+ position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column;
+ align-items: center; justify-content: center; gap: 10px; text-align: center;
+ background: color-mix(in srgb, var(--udt-crust) 92%, transparent);
+}
+#asleep[hidden] { display: none; }
+.asleep-moon { font-size: 3rem; color: var(--udt-overlay0); }