From 65b663be97976ff6d3c3bd2e6b2694fdadc1e22a Mon Sep 17 00:00:00 2001 From: Michael Date: Mon, 18 May 2026 23:22:11 +0000 Subject: [PATCH] fix(footer): stretch .stApp + sidebar + main to compensate for zoom MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit User screenshot pinned the actual culprit: a horizontal white band across the FULL viewport width (including over the sidebar) above the Help/Close footer. Diagnosis: - ``.stApp`` carries ``zoom: 0.85``, so any descendant sized at ``100vh`` only renders at ~85vh visually. - At 1920x1050 the visual end of ``.stApp`` is around y=893; the fixed footer overlays y=1017..1050; the strip in between (124px at this resolution) is ``body`` painting white through, because ``.stApp``, ``stSidebar`` and ``stMain`` are all shorter than the viewport. - The previous "min-height: 100vh/0.85" rule targeted the legacy ``data-testid="stAppViewBlockContainer"``. The current Streamlit release renamed that testid to ``stMainBlockContainer`` — so the rule was a no-op for months. Verified the new testid by walking the live DOM. Fix: stretch ``.stApp``, ``[data-testid="stSidebar"]`` and ``[data-testid="stMain"]`` with ``min-height: calc(100vh / 0.85)`` so they fill the visible viewport. Keep the block-container's 2rem ``padding-bottom`` (now matching both the new and legacy testids in case Streamlit rolls it back). Verified at 1920x1050: sidebar gray extends to y=1050, content area extends to y=1050, footer overlays the bottom 33px, no white band between content and footer. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/gui/components/_legacy.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/gui/components/_legacy.py b/src/gui/components/_legacy.py index c8da91c..3aed7ec 100644 --- a/src/gui/components/_legacy.py +++ b/src/gui/components/_legacy.py @@ -628,6 +628,24 @@ def render_sticky_footer() -> None: st.markdown( """