From e0aa7dd952994725a115dcad065374e55aeb3202 Mon Sep 17 00:00:00 2001 From: Andrew Anderson Date: Thu, 29 Oct 2026 22:15:13 -0400 Subject: [PATCH 1/2] =?UTF-8?q?=F0=9F=90=9B=20dashboard:=20kiosk=20mode=20?= =?UTF-8?q?renders=20dark=20by=20default?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Andrew Anderson --- changelog.d/fixed-kiosk-dark-default.md | 1 + src/docs/streaming-the-activity-monitor.md | 3 ++- src/pkg/dashboard/static-src/js/boot.js | 3 +++ src/pkg/dashboard/static-src/js/layout.js | 1 + 4 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 changelog.d/fixed-kiosk-dark-default.md diff --git a/changelog.d/fixed-kiosk-dark-default.md b/changelog.d/fixed-kiosk-dark-default.md new file mode 100644 index 0000000000..d7b818d571 --- /dev/null +++ b/changelog.d/fixed-kiosk-dark-default.md @@ -0,0 +1 @@ +- Kiosk mode (`?kiosk=1`) always renders the dark theme unless `&theme=light` is given, so a fresh headless streamer profile no longer broadcasts light mode. diff --git a/src/docs/streaming-the-activity-monitor.md b/src/docs/streaming-the-activity-monitor.md index 249563730a..6dc84828ad 100644 --- a/src/docs/streaming-the-activity-monitor.md +++ b/src/docs/streaming-the-activity-monitor.md @@ -145,7 +145,8 @@ position. For hive's hive that is `hivecommons/hive`, a public repository. It does **not** render tokens, secrets, settings, webhooks, chat, or the operator's agent terminals; `?kiosk=1` additionally hides the sidebar, topbar, avatar/settings menus, notices, the Welcome and NPS dialogs, and every other -dashboard section. Do not point the streamer at a hive tracking private +dashboard section, and renders dark regardless of any stored theme +(append `&theme=light` for a light stream). Do not point the streamer at a hive tracking private repositories without reviewing what the tracker would show. ## Quick manual test with OBS (no cluster) diff --git a/src/pkg/dashboard/static-src/js/boot.js b/src/pkg/dashboard/static-src/js/boot.js index 326de55b01..4c6e114fbb 100644 --- a/src/pkg/dashboard/static-src/js/boot.js +++ b/src/pkg/dashboard/static-src/js/boot.js @@ -26,6 +26,9 @@ var m=localStorage.getItem('hive-layout-mode'); if(m==='openclaw')m='light'; if(m==='classic')m='dark'; + // A kiosk (#15594) is a broadcast surface with no operator to flip the + // toggle; it always renders dark unless the URL says otherwise. + if(window.HIVE_KIOSK){ var kt=null; try { kt=new URL(window.location.href).searchParams.get('theme'); } catch(e) {} m=(kt==='light')?'light':'dark'; } if(!m)m='light'; if(m==='light'){document.body.classList.add('light-mode')} document.body.style.opacity='0'; diff --git a/src/pkg/dashboard/static-src/js/layout.js b/src/pkg/dashboard/static-src/js/layout.js index 94018be987..6c9bc6b9ff 100644 --- a/src/pkg/dashboard/static-src/js/layout.js +++ b/src/pkg/dashboard/static-src/js/layout.js @@ -227,6 +227,7 @@ const LAYOUT_TITLES = { dark: 'Switch to Light Mode', light: 'Switch to Dark Mode' }; function getLayout() { let stored = localStorage.getItem(LAYOUT_KEY) || 'light'; + if (window.hiveKioskMode && window.hiveKioskMode()) { let kt = null; try { kt = new URL(window.location.href).searchParams.get('theme'); } catch (e) {} stored = kt === 'light' ? 'light' : 'dark'; } if (stored === 'openclaw') { stored = 'light'; setLayout(stored); } if (stored === 'classic') { stored = 'dark'; setLayout(stored); } return LAYOUT_MODES.includes(stored) ? stored : 'light'; From 4fc8a08bbf97d3799f31c80e84bb747cddcd326a Mon Sep 17 00:00:00 2001 From: Andrew Anderson Date: Thu, 29 Oct 2026 22:15:33 -0400 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=90=9B=20dashboard:=20regenerate=20in?= =?UTF-8?q?dex.html=20for=20kiosk=20dark=20default?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Andrew Anderson --- src/pkg/dashboard/static/index.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pkg/dashboard/static/index.html b/src/pkg/dashboard/static/index.html index 6bd6826f9f..f8f3b81855 100644 --- a/src/pkg/dashboard/static/index.html +++ b/src/pkg/dashboard/static/index.html @@ -6716,6 +6716,9 @@ var m=localStorage.getItem('hive-layout-mode'); if(m==='openclaw')m='light'; if(m==='classic')m='dark'; + // A kiosk (#15594) is a broadcast surface with no operator to flip the + // toggle; it always renders dark unless the URL says otherwise. + if(window.HIVE_KIOSK){ var kt=null; try { kt=new URL(window.location.href).searchParams.get('theme'); } catch(e) {} m=(kt==='light')?'light':'dark'; } if(!m)m='light'; if(m==='light'){document.body.classList.add('light-mode')} document.body.style.opacity='0'; @@ -10478,6 +10481,7 @@

Where to get help

const LAYOUT_TITLES = { dark: 'Switch to Light Mode', light: 'Switch to Dark Mode' }; function getLayout() { let stored = localStorage.getItem(LAYOUT_KEY) || 'light'; + if (window.hiveKioskMode && window.hiveKioskMode()) { let kt = null; try { kt = new URL(window.location.href).searchParams.get('theme'); } catch (e) {} stored = kt === 'light' ? 'light' : 'dark'; } if (stored === 'openclaw') { stored = 'light'; setLayout(stored); } if (stored === 'classic') { stored = 'dark'; setLayout(stored); } return LAYOUT_MODES.includes(stored) ? stored : 'light';