From c942b8aa197e247ac05091f18dfeb1ffcc8e58ec Mon Sep 17 00:00:00 2001 From: Michael Date: Mon, 18 May 2026 22:52:02 +0000 Subject: [PATCH] fix(footer): offset sticky-footer's left edge past the sidebar MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The "white bar" was the footer's near-white background painting over the bottom of the sidebar. The footer is fixed at body level with ``left: 0; right: 0`` so it spans the full viewport — its ``rgba(255, 255, 255, 0.97)`` background renders as essentially white over the sidebar's ``rgb(240, 242, 246)`` gray, producing a visibly different strip at the bottom of the sidebar (this is what the diagnostic GREEN tint marked as ``stAppViewContainer``-shaped because that is the element directly behind it). Pixel-sampled the bottom row to confirm: y=860 over sidebar → (240, 242, 246) (gray) y=870 over sidebar → (255, 255, 255) (footer-painted white) Fix: in the iframe JS that mounts the footer on ````, measure ``[data-testid="stSidebar"].getBoundingClientRect().right`` and set the footer's (and help popover's) ``left`` to that offset with ``setProperty(..., 'important')`` so it beats the ``left:0!important`` fallback in CSS. A ``ResizeObserver`` on the sidebar plus a ``window.resize`` listener keep the offset in sync when the sidebar collapses or expands. Sidebar collapsed (width 0 or off-screen) clamps to 0 → footer goes flush-left as before. Also dropped the no-op ``min-height`` on the view container from the previous attempt; ``stAppViewContainer`` is transparent, so stretching it never painted anything. Verified by injecting the same offset on the live page: bottom row at y=890 is now ``(240,242,246)`` over the sidebar and only turns white at x=255 where the content area begins. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/gui/components/_legacy.py | 40 +++++++++++++++++++++++++++-------- 1 file changed, 31 insertions(+), 9 deletions(-) diff --git a/src/gui/components/_legacy.py b/src/gui/components/_legacy.py index ab55992..c8da91c 100644 --- a/src/gui/components/_legacy.py +++ b/src/gui/components/_legacy.py @@ -628,15 +628,6 @@ def render_sticky_footer() -> None: st.markdown( """