From cb82a938f6d8bf23a68cc1c12b0f1f7cc51478f1 Mon Sep 17 00:00:00 2001 From: HomeDash Bot Date: Sat, 12 Sep 2026 19:38:12 +0800 Subject: [PATCH] =?UTF-8?q?fix(ui):=20=E9=A1=B5=E8=84=9A=E8=B4=B4=E4=BD=8F?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=9C=80=E5=BA=95=20=E2=80=94=E2=80=94=20?= =?UTF-8?q?=E6=B6=88=E9=99=A4=20#app=20=E5=90=9E=E6=8E=89=E5=89=A9?= =?UTF-8?q?=E4=BD=99=E7=A9=BA=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 实测(滚到最底时的 host.bottom / 文档高): / 720 / 720 → 0px ✓ /minimal 717 / 720 → 余 3px /workspace 674 / 720 → **余 46px** 根因:body 为 display:flex/column,其中 #app 是 flex:1 1 auto, 吃掉全部剩余高度,使页脚只能排在 #app 之后的中途位置。 修法:body 直接含 .navi-footer-host 时令 #app 改为 flex:0 0 auto(不再伸展), 页脚用 margin-top:auto 落到最底;并清掉 minimal 内容链末尾的余量。 --- web/navi.css | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/web/navi.css b/web/navi.css index 339c388..0a1e24e 100644 --- a/web/navi.css +++ b/web/navi.css @@ -2507,3 +2507,24 @@ html[data-theme] body #dashy > footer > .navi-footer { } /* ④ minimal:host 已是 body 子项,用 margin-top:auto 让页脚贴页面最底 */ html[data-theme] body:has(.minimal-home) > .navi-footer-host { margin-top: auto !important; } + +/* ═══ v83:页脚贴住页面最底(消除 #app 吞掉剩余空间)═══ + 实测(滚到最底): + / host.bottom=720 = 视口高 → 距底 0px ✓ + /minimal host.bottom=717,文档 720 → 余 3px(可接受但未归零) + /workspace host.bottom=674,文档 720 → **余 46px** + 根因:body(display:flex; flex-direction:column)的 #app 为 flex:1 1 auto, + 会吃掉全部剩余高度,使后面的 .navi-footer-host 只能排在 #app 之后的中途。 + 修法:当 body 直接含 .navi-footer-host 时,让 #app 不再弹性伸展(flex:0 0 auto), + 页脚即可落在页面最底;minimal 的 3px 来自 #app 之外的一点点余量,一并归零。 */ +html[data-theme] body:has(> .navi-footer-host) > #app { + flex: 0 0 auto !important; +} +html[data-theme] body:has(> .navi-footer-host) > .navi-footer-host { + margin-top: auto !important; + margin-bottom: 0 !important; + padding-bottom: 0 !important; +} +/* minimal:内容链最后一个容器不留底部余量 */ +html[data-theme] body:has(.minimal-home) > .navi-footer-host { margin-bottom: 0 !important; padding-bottom: 0 !important; } +html[data-theme] body:has(.minimal-home) #app > *:last-child { margin-bottom: 0 !important; padding-bottom: 0 !important; }