Repository navigation
fix(webui): stop the session rail row actions from covering the session name - #8
Merged
Merged
Conversation
stevenjj33
force-pushed
the
fix/rail-row-actions-occlude-session-title
branch
from
November 10, 2026 04:43
c0316b2 to
28d26a3
Compare
…on name The inline row actions (pin / archive / more) were painted over the session title instead of sitting beside it. Hovering a row in Safari left three floating buttons on an otherwise empty line, with the name gone. Two rules combined to produce it: * The base layer sets `scrollbar-gutter: stable` on html/body/div/main/ section/aside/nav/ul/..., so every nested container in the rail reserved a 17px slot for a scrollbar it never draws. The rail nests five levels (rail -> project sections -> project disclosure -> session list -> row), which cost 5 x 17px = 85px and squeezed the session list down to 123px, while the three inline actions are 90px wide on their own. * The title yielded to the actions with `clip-path: inset(0 88px 0 0)`, which removes the pixels it covers: a title narrower than the reserve was erased entirely, so a 59px name disappeared and only the buttons were left. The rail's nested containers now opt out of the reserved gutter with `scrollbar-gutter: auto`, the way the plugin, transcript and workspace panels already do, and the title yields with `padding-right` so the text ends in an ellipsis instead of being cut away. The reserved width is unchanged, and no action, copy or behaviour changes.
The rail's session titles now reserve the room for the row actions with padding instead of a clip, so the shared clip transition had nothing left to animate. The reservation moves with a padding transition instead, carried by a shared motion class because a feature's own stylesheet may not declare one. The rail-pin cases now assert the reservation they claim: the room is padding, the title ends short of the actions, and a short title keeps its words instead of being cut away.
…anges The rail's session rows now reserve the row actions' room with padding, and the nested rail containers no longer each claim a scrollbar slot, so the shell, the workspace panel and the dialogs that sit over it all render differently. Every baseline is re-recorded on the platform that owns it.
The fixture serves the committed faces as web fonts, so the typeface is the same on every platform. The pixels are not: each platform rasterizes the same outlines its own way, and even two machines of one platform differ by a handful, which is why the baselines are per-platform and the eight-pixel budget is tight. The README's claim that a comparison produces the same result on any host was the opposite of what the gate does.
stevenjj33
force-pushed
the
fix/rail-row-actions-occlude-session-title
branch
from
November 10, 2026 05:57
8c0587d to
704ebe1
Compare
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change
The session rail's inline row actions (pin / archive / more) covered the session
name instead of sitting beside it. In Safari the effect is total: hovering a
session row left three floating buttons on an otherwise empty line, with the
session title gone.
Two CSS rules combined to produce it.
1. Every nested rail container reserved a 17px scrollbar slot. The base layer
sets
scrollbar-gutter: stableonhtml, body, div, main, section, aside, nav, ul, ol, pre, textarea, select, so each container nested inside the rail reservedroom for a scrollbar it never draws. The rail nests five levels (rail -> project
sections -> project disclosure -> session list -> row), which cost 5 x 17px =
85px and squeezed the session list down to 123px. The three inline row
actions are 90px wide on their own, so no room was left for a title.
2. The title reserve was a hard cut, not a truncation. On hover the title was
clipped with
clip-path: inset(0 88px 0 0)to make room for those buttons.clip-pathremoves the pixels it covers, so a title narrower than the reserveis erased entirely. With a 59px title ("飞书会话") and an 88px reserve, the name
disappeared and only the buttons were left.
The fix keeps the design intent (the actions appear on hover, the title yields to
them) and changes two mechanisms:
scrollbar-gutter: auto- the same opt-out the plugin, transcript andworkspace panels already use. These levels never scroll, so the slot was pure
loss.
padding-rightinstead ofclip-path, so the text endsin an ellipsis rather than being cut away. The reserved width is unchanged
(88px for the three project-row actions, 28px for the single child-row action).
No behaviour, action set or copy changed: pin and archive stay inline, the
session context menu is untouched, and no action was removed. (The session
context menu has no 置顶 entry, so the inline pin button had to stay.)
One deliberate consequence: the reserved space now appears immediately instead of
animating. The old reserve rode on
clip-path, and.webui-motion-feedback-clipanimates
clip-path;padding-rightis a layout property, and feature stylesheetsmay not declare transitions (the motion ownership rule keeps timing in the shared
layer), so the swap is instant. The row actions themselves still fade in - that
transition lives on
.webui-motion-feedback-opacity, which is untouched.Measured
Measured in WebKit - the engine Safari uses - against the running WebUI:
Verified in Safari itself as well: hovering a session row now shows the full
title with the three actions beside it, and the relative-time label stays on the
rows that are not hovered.
Validation
1320px viewport, against the running WebUI 0.1.8 build.
session row, and confirmed the title stays readable and the three actions no
longer overlap it.
packages/webui/src/client/features/sessions/ui/sessions.css.space from containers that never scroll.
pnpm typecheck:webui,pnpm check:webui-*,pnpm build:webui,pnpm test:webui,pnpm test:webui-browserandpnpm test:webui-packagewere not run locally: this checkout was made through the GitHub API instead of
a full clone, so the pnpm toolchain was never installed on this machine. CI
runs all of them on this PR. Windows and Linux rendering of the same rows was
not checked locally either.
Publication and contribution checks
release/public-source.json; new tests are declared intest/vitest-suites.jsonwhere applicable. - no source files were added or removed, and no test was added.Maintainer handoff
Publication scope or license changes (if any): none.
Shared-source port: not needed.
中文说明(问题与修法)
侧栏会话行的三个行内按钮(置顶 / 归档 / 更多)会盖住会话名。Safari 下最明显:
鼠标悬停一行时,只剩三个按钮浮在一条空行上,标题整条不见了。
两个规则叠加导致:
html/body/div/main/section/aside/nav/ul/...一律设了scrollbar-gutter: stable,侧栏嵌套 5 层 = 吃掉 85px,会话列表被压到123px;而三个行内按钮本身就有 90px 宽,标题根本没有位置。
clip-path: inset(0 88px 0 0)硬裁剪。 clip 会把覆盖到的像素直接删掉,标题比让位宽度窄就会被整条抹掉。59px 的标题对上 88px 的让位,
于是名字消失,只剩按钮。
(一处取舍:让位宽度现在改为立即生效,不再有动画 —— 原来让位是搭
clip-path的动画,而
padding-right属于布局属性,特性样式表按 motion 归属规则不能自己声明 transition。按钮本身的淡入没动,它走的是
.webui-motion-feedback-opacity。)修法保持原设计意图(按钮 hover 出现、标题让位),只换两个机制:
scrollbar-gutter: auto(仓库里 plugins / transcript / workspace面板本来就是这么写的);这几层本来就不会滚动,那条槽是纯浪费。
clip-path改成padding-right,文字以省略号收尾,而不是被裁没。让位宽度不变(项目会话行 88px、子会话行 28px)。
行为、按钮集合、文案都没变:置顶和归档仍然行内显示,菜单没动,没有删任何功能
(会话右键菜单里本来就没有「置顶」,所以行内的置顶按钮必须保留)。
实测(WebKit,Safari 同款引擎,对着跑起来的 WebUI 量的):
也在真实 Safari 27.2(macOS 27.2)里手工验过:悬停时标题完整、三个按钮在右侧
自己的位置,没被 hover 的行照常显示相对时间。