fix: 修复侧边栏目录和TODO溢出问题,增强序号识别

- 修复 part2 和 part3 高度自适应,避免内容溢出窗口
- part2 和 part3 动态分配可用空间(part2 占 60%,part3 占 40%)
- 增强序号识别:支持第一、第二、(1)、[1]、I. II. 等格式
- 移除 todo-list-scroll 固定高度限制,改为动态计算
This commit is contained in:
2026-01-16 15:08:07 +08:00
parent a0b5484e36
commit 3f280dd9ef
3 changed files with 44 additions and 11 deletions

View File

@@ -2531,13 +2531,9 @@ html.navbar-absolute #leftbar_part2.sticky {
}
#leftbar_part2_inner {
max-height: calc(100vh - 110px);
max-height: calc(100vh - 110px - var(--leftbar-part3-height, 0px));
overflow-y: auto;
padding: 10px;
}
#leftbar_part2_inner::-webkit-scrollbar {
@@ -12607,6 +12603,16 @@ article .post-content .huhua a:before {
position: fixed;
top: calc(80px + var(--leftbar-part2-height, 300px));
width: 240px;
max-height: var(--leftbar-part3-max-height, 50vh);
overflow: hidden;
display: flex;
flex-direction: column;
}
#leftbar_part3.sticky .card-body {
overflow-y: auto;
flex: 1;
min-height: 0;
}
body.leftbar-can-headroom.headroom---unpinned #leftbar_part3.sticky {
@@ -12706,7 +12712,7 @@ html.navbar-absolute #leftbar_part3.sticky {
}
.todo-list-scroll {
max-height: 240px;
max-height: none;
overflow-y: auto;
padding-right: 5px;
}