From 88da57398aa090747de6fffb7b2de49781fc09f0 Mon Sep 17 00:00:00 2001 From: Dmitry Ilyin <6576495+widgetii@users.noreply.github.com> Date: Sun, 11 Oct 2026 20:41:13 +0300 Subject: [PATCH] Share page: the camera's Live page can ask for the whole screen An iPhone has no fullscreen for a page element, so the camera's Live page offers Fill screen instead: its navbar and banners step aside. Inside a share the share page's own bar has to as well, or the picture still starts under it. window.__share.fill(on) toggles that bar; a WebUI that does not call it is unchanged. --- service/internal/sharerelay/static/index.html | 2 ++ service/internal/sharerelay/static/shell.js | 3 +++ 2 files changed, 5 insertions(+) diff --git a/service/internal/sharerelay/static/index.html b/service/internal/sharerelay/static/index.html index 4fea4c11..d3ed0685 100644 --- a/service/internal/sharerelay/static/index.html +++ b/service/internal/sharerelay/static/index.html @@ -13,6 +13,8 @@ html, body { margin: 0; height: 100%; background: var(--bg); color: var(--fg); font: 14px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; } body { display: flex; flex-direction: column; } header[hidden] { display: none; } + /* The camera's page asked for the whole screen (window.__share.fill). */ + body.share-fill > header { display: none; } /* One row, always: every pixel this bar takes is a pixel off the picture, and on a phone the wrapped version was three rows -- a fifth of the screen -- above the camera's own navbar. Narrow, the name gives way diff --git a/service/internal/sharerelay/static/shell.js b/service/internal/sharerelay/static/shell.js index 9d50b5d9..10615c2f 100644 --- a/service/internal/sharerelay/static/shell.js +++ b/service/internal/sharerelay/static/shell.js @@ -354,6 +354,9 @@ async function main() { window.__share = { openWebSocket: (path, protocols, h) => openWebSocket(tunnel, path, protocols, h), welcome, ice: await iceServers.catch(() => []), trace: (what, detail) => trace('camera page: ' + what, detail), + // The camera's Live page filling the screen where the browser has no + // fullscreen for it (an iPhone): this page's bar steps aside too. + fill: (on) => { document.body.classList.toggle('share-fill', !!on); }, }; let player = null; tunnel.onclose = (why) => {