From 747b6b64cad386d817a3f0e7635e3d79e08eb774 Mon Sep 17 00:00:00 2001 From: vshengbro Date: Sat, 17 Oct 2026 21:33:35 +0800 Subject: [PATCH] =?UTF-8?q?fix(docs):=20=E4=B8=80=E7=BA=A7=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E9=80=89=E4=B8=AD=E6=97=B6=E6=8C=87=E7=A4=BA=E6=9D=A1?= =?UTF-8?q?=E8=B4=AF=E7=A9=BF=E6=95=B4=E4=B8=AA=E4=BE=A7=E8=BE=B9=E6=A0=8F?= =?UTF-8?q?=E5=B7=A6=E4=BE=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit c_euv_sidebar_link_active(一级文件 active 态)缺少 position: relative, 其 ::before 指示条(top:0/bottom:0/left:0/width:5px)向上解析到最近的 定位祖先——sticky 的 c_app_nav——于是画成一条 5px × 295px 贯穿整个列 表左侧的加粗竖条(线上实测),而不是只标记当前这一项。 注入样式里所有带绝对定位 ::before 的行类都必须自身定位: link/group_title 已有(同一条规则),group_title_active 与 flush 在 另一条规则里,root 两个变体也有——唯独漏了一级 active 叶子。把它补进 position: relative 的选择器列表。 修复后实测(本地构建,#/(top-level leaf 页面)): 一级 active 叶子 ::before 42px,position: relative,收进本行 悬浮其他一级条目 各自 42px 条,互不影响 嵌套条目/根分组 行为不变(42px、贴虚线) 版本 0.30.6 → 0.30.7。 --- Cargo.toml | 16 ++++++++-------- docs/src/app/const.rs | 9 ++++++++- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 053de979..b149d7a2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,7 +12,7 @@ categories = ["network-programming", "web-programming"] exclude.workspace = true [workspace.package] -version = "0.30.6" +version = "0.30.7" readme = "README.md" edition = "2024" authors = ["root@ltpp.vip"] @@ -38,13 +38,13 @@ resolver = "3" crate-type = ["rlib"] [workspace.dependencies] -euv = { path = ".", version = "0.30.6" } -euv-ui = { path = "ui", version = "0.30.6" } -euv-cli = { path = "cli", version = "0.30.6" } -euv-core = { path = "core", version = "0.30.6" } -euv-engine = { path = "engine", version = "0.30.6" } -euv-macros = { path = "macros", version = "0.30.6" } -euv-example = { path = "example", version = "0.30.6" } +euv = { path = ".", version = "0.30.7" } +euv-ui = { path = "ui", version = "0.30.7" } +euv-cli = { path = "cli", version = "0.30.7" } +euv-core = { path = "core", version = "0.30.7" } +euv-engine = { path = "engine", version = "0.30.7" } +euv-macros = { path = "macros", version = "0.30.7" } +euv-example = { path = "example", version = "0.30.7" } log = "0.4.34" toml = "0.9.12" diff --git a/docs/src/app/const.rs b/docs/src/app/const.rs index ce6f6070..c1177370 100644 --- a/docs/src/app/const.rs +++ b/docs/src/app/const.rs @@ -56,7 +56,14 @@ pub(crate) const APP_GLOBAL_CSS: &str = "html, body { height: 100% !important; o .c_euv_sidebar_children .c_euv_sidebar_link_active::before, .c_euv_sidebar_children .c_euv_sidebar_group_title_active::before { left: -8px !important; } \ .c_euv_sidebar_children .c_euv_sidebar_link_active_flush::before { left: 0 !important; } \ \ - .c_euv_sidebar_link, .c_euv_sidebar_group_title { position: relative !important; } \ + /* Every row class whose ::before marker is absolutely positioned + must itself be positioned, or the marker resolves against the + nearest positioned ancestor (the sticky `c_app_nav`) and paints + a 5px bar down the *full height* of the sidebar instead of the + row. `c_euv_sidebar_link_active` (a top-level active leaf) was + missing here: measured live, its ::before spanned 295px of the + nav column while the row itself is 42px. */ \ + .c_euv_sidebar_link, .c_euv_sidebar_group_title, .c_euv_sidebar_link_active { position: relative !important; } \ .c_euv_sidebar_link::before, .c_euv_sidebar_group_title::before { content: '' !important; position: absolute !important; top: 0 !important; bottom: 0 !important; width: 5px !important; background: transparent !important; pointer-events: none !important; } \ .c_euv_sidebar_group_title::before { left: 0 !important; } \ .c_euv_sidebar_link::before { left: 0 !important; } \