From 8ec2352c22780202fcd39982f1c3e65d2dae0cc1 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Tue, 10 Nov 2026 13:03:07 +0100 Subject: 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 --- static/deck.css | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'static/deck.css') 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); } -- cgit v1.2.3