Repository navigation
feat(dashboard): hide every scrollbar - #23550
Conversation
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: a recorded maintainer decision (#23539) covers removing the touch and hover thumbs, and the scroll-reveal keeps every box's reserved column, so showing the thumb moves no content. Notes
[DESIGN-REVIEWED] 27e1a95 Description read[DESCRIPTION-READ] 9d60ebebdaa424de88d7e874166559031958042f0b12c939ef00fc4dd1cbeaa0 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
First Principles Review (Opus 5.5) — ✅ human override accepted@CrysisDeu overrode this lane for |
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing blocks. The PR adds no new controls, the screenshots show the scrollbar both at rest and mid-scroll in two themes, and two recordings cover the reveal. Notes
[UX-REVIEWED] 27e1a95 Description read[DESCRIPTION-READ] 5469e7bad2d96b6166124299494a1706a03833ee10c32ac3ef9129849ae7da89 That sha256 names everything this verdict read: the PR description, plus the 6 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
|
Round 1 on Fixed (defects in code this PR touches)
Rebutted
Deferred (outside the frozen goal)
Needs a maintainer
|
5e659ac to
e090ad0
Compare
Human judgment recorded@CrysisDeu marked the first-principles AI finding as false positive, not applicable, or explicitly accepted for
This decision applies only to this commit. A new push requires a new judgment. |
cruisercohen
left a comment
There was a problem hiding this comment.
Commenting at e090ad0, not approving yet: one common surface still paints a scrollbar.
Code blocks and file views drawn by @pierre/diffs keep the library's own scrollbar. Pierre renders into a shadow root, and its stylesheet there gives [data-code] a ::-webkit-scrollbar of height: var(--diffs-scrollbar-gutter) (6px fallback), a var(--diffs-bg-context) thumb on [data-file]:hover / [data-diff]:hover, and on Firefox scrollbar-width: thin; scrollbar-color: var(--diffs-bg-context) transparent. The new base-layer rule in index.css is a document style: scrollbar-width does not inherit and ::-webkit-scrollbar does not match across the shadow boundary, so neither half reaches it. A non-prose CodeBlock (no overflow: 'wrap', so Pierre's default horizontal scroll) is the common case, and it gets exactly the hover-revealed thumb #23539 decided against.
Probe in Chromium 145 with --hide-scrollbars off, the PR's rule verbatim in @layer base, Pierre's shipped stylesheet in a shadow root, and a 600-character line in a 300px box:
| scroller | computed scrollbar-width |
gutter (offsetHeight - clientHeight) |
|---|---|---|
light-DOM overflow-x:auto div |
none |
0 |
shadow [data-code] |
auto |
6px |
Adding @layer unsafe{[data-code]{scrollbar-width:none}[data-code]::-webkit-scrollbar{display:none}} to the shadow sheet took it to none / 0.
Suggested fix: one shared fragment in the unsafeCSS that every Pierre File / FileDiff / editor mount receives (it lands in @layer unsafe, which outranks the library's @layer base; CodeBlock passes none today), optionally with --diffs-scrollbar-gutter-override: 0px on the host, mirroring the @pierre/trees block in chat-transcript.css. noScrollbarPaint.test.ts cannot see this because it scans src/ only; an assertion that the shared fragment carries both halves would pin it.
Smaller, non-blocking: noScrollbarPaint.test.ts matches only the kebab-case property, so an inline style={{ scrollbarWidth: 'thin' }} in a .tsx passes it (checked with a scratch file), and an inline style beats the global rule. The no-visible-scrollbar rule in AUTOSDE.yaml already catches that shape; the test could match the camelCase form too.
Everything else reads correct. On the PR merged with current main, the 12 related vitest files (378 tests) pass. With the old index.css, scrollbars-and-touch-hit.css and file-explorer styles.ts put back, noScrollbarPaint.test.ts fails 2 of 4 cases and names each painted rule.
buluoray
left a comment
There was a problem hiding this comment.
Reviewed at e090ad0fd4c4cea4f1c62055b7ac7acd8b4f62a5.
The light-DOM half of this works: the global rule hides the transcript, sidebar, list and modal scrollbars, the gutter and right-1.5 clean-ups are right, and the new gate catches the shapes it scans for. One part of the goal is not met, though. #23539 names "code and diff blocks: hidden at rest, shown on hover" as one of the three treatments to remove, and this PR closes that issue. But every code and diff block still paints that hover thumb.
Blocking
Code and diff blocks still paint a scrollbar. The global rule cannot reach them.
Every code and diff surface (CodeBlock.tsx:341, DiffBlock.tsx:341, DiffPanel.tsx:52, ContentRenderer.tsx:214, PapyrusEditor.tsx:126, WorkflowSourceCode.tsx:55) renders through @pierre/diffs, which draws into a shadow root. A document rule like *{scrollbar-width:none} / ::-webkit-scrollbar{display:none} (index.css:132-133) does not match anything inside a shadow tree. The library's own sheet (@pierre/diffs/dist/style.js, 1.3.5) gives [data-code] a ::-webkit-scrollbar with height: var(--diffs-scrollbar-gutter) (6px fallback), and [data-file]:hover [data-code]::-webkit-scrollbar-thumb { background-color: var(--diffs-bg-context) }. Under @supports (-moz-appearance: none) it also sets scrollbar-width: thin with a visible scrollbar-color. Dropping scroll-fade from CodeBlock.tsx changed nothing here: that class styled the light-DOM wrapper, which is not the box that scrolls.
I checked this in Chromium with headless scrollbar hiding turned off. I used the library's real stylesheet in a shadow root and the exact base-layer rule from this PR:
| Probe | Result |
|---|---|
| light-DOM overflow box | scrollbar-width: none, 0px gutter (the rule works) |
Pierre [data-code] box |
scrollbar-width: auto, 6px gutter |
| thumb pixels in that 6px strip, at rest / on hover | 0 / 124 (painted in --diffs-bg-context) |
same, with --diffs-scrollbar-gutter-override: 0px set on the host |
0px gutter, 0 / 0 |
So in Chrome and Electron, every wide code block and diff still shows the hover thumb. In Firefox it shows a permanent thin one. This also makes three new texts wrong: the decision entry, the no-visible-scrollbar rule ("One rule in src/index.css … covers every scroll box") and the frontend-conventions.md paragraph. noScrollbarPaint.test.ts cannot catch it, because it scans src/ only.
Suggested fix, about three lines:
- Add
--diffs-scrollbar-gutter-override:0pxto the.pierre-surface diffs-containerrule inchat-transcript.css. Custom properties do cross the shadow boundary, and the probe above shows this removes the WebKit bar. - For Firefox, add
[data-code]{scrollbar-width:none}to the shared PierreunsafeCSS. That is the library's sanctioned way into the shadow root (seesrc/pierre/config.ts). - Word the rule and docs so they name this hook next to the
@pierre/treesone. Optionally, extendnoScrollbarPaint.test.tsto assert the override is present.
One side effect to check: Pierre sets padding-bottom: max(0px, gap - var(--diffs-scrollbar-gutter)). A 0 gutter makes each block a few px taller, so check that the pierre-plain stand-in in CodeBlock.tsx still keeps its height match with the highlighted surface.
Non-blocking
- The
@pierre/treesFirefox rule has no effect (chat-transcript.css:436-440).[data-file-tree-virtualized-scroll]is rendered inside thefile-tree-containershadow root (@pierre/trees/dist/render/FileTree.jsappends the wrapper toshadowRoot), so none of the three light-DOM selectors match it. Removing the rule leaves every test green. The transparent thumb override still blanks the paint, so the only effect is a reserved thin column in Firefox. If that column matters,scrollbar-width:nonebelongs inPIERRE_TREE_STATE_ROW_CSS(unsafeCSS,PierreWorkspaceTreeImpl.tsx:825). If not, drop the rule and fix the comment. - The PR body overstates the horizontal cue. It says the
.edge-fade-xmask "stays as the cue for sideways-scrolling code blocks". On both main and this head, only the composer control row (ChatInput.tsx:1505) carriesedge-fade-x. Code blocks never had it. Once their thumb is really gone, a wide code block has no cue, and a plain-wheel mouse user scrolls it only with Shift+wheel or the keyboard (the region keepstabIndex=0). The decision accepts losing the thumb, so this is a wording fix, unless you want the edge fade on code blocks too, which #23547 could track. - Test gap:
noScrollbarPaint.test.tsmisses React inline styles. ChangingSessionTabStrip.tsx'sscrollbarWidth: 'none'to'thin'keeps all four cases green. The AUTOSDE regex coversscrollbarWidthat review time, but adding a camelCasescrollbarWidth/scrollbarColorshape toPAINTSwould close the CI side.
Checked
website/AGENTS.md,frontend-conventions.md,narrow-viewport.mdand the decision entry were read against the diff. No user-visible strings were added, so i18n is not affected. No theme values are hardcoded.- Keyboard and pointer: no scroller loses
overflow-*.CodeBlockkeeps its focusablerole="region". TheChatInput/ paste-mirrorscrollbar-gutter:stablepairing still matches on both boxes. Touch hit areas are unchanged. - The removed tests (
scrollbarThumbContrast,scrollbarOverlayTouch) only measured the thumb that is now gone. Their palette-resolver anchors moved intothemeFillForeground.test.ts, and the capture-script swap follows the existingwebsite/scripts/capture-*.mjsconvention. - The
no-visible-scrollbarregex compiles, and lookahead already appears in other rules in that file.
Tests run
- 9 touched vitest files: 240 passed.
tsc -p tsconfig.app.json --noEmit: clean. - Mutations, each applied alone and then restored:
| Mutation | Result |
|---|---|
drop *{scrollbar-width:none} from index.css |
red: anchors the premise… |
drop ::-webkit-scrollbar{display:none} |
red: anchors the premise… |
new sheet with scrollbar-width:thin |
red: lets no file in src/ paint a scrollbar back |
new sheet with a coloured ::-webkit-scrollbar-thumb |
red: lets no file in src/ paint a scrollbar back |
--trees-scrollbar-thumb-override back to var(--muted) |
red: lets no file in src/ paint a scrollbar back |
scrollbarGutter: 'stable' back on TranscriptScrollShell |
red: reserves no scrollbar gutter… |
right-1.5 back on ChatTitleOverlay |
red: 5 cases in ChatPage.composerChromeOcclusion / overlaySelection |
pane-1 list in the Overview library tab, overflow-y-auto to overflow-hidden |
red: the "list is its own scroll box" case in that tab's test |
SessionTabStrip inline scrollbarWidth to 'thin' |
survives (non-blocking 3) |
delete the @pierre/trees light-DOM scrollbar-width rule |
survives (non-blocking 1) |
- CI on this head: 92 check runs passed, 11 skipped, 0 failed. Statuses (both CodeBuild builds and PR Readiness) are green. Design, UX, GPT and Opus pass. The First Principles block was overridden by the maintainer and recorded. The earlier UX notes were triaged in the round-1 comment.
- I merge-checked this head against the open frontend PRs #23565, #23577, #23540, #23209 and #23579: all merge cleanly. #23579 also edits
ChatInput.tsx, but it adds nothing that conflicts with the new rule.
e090ad0 to
6f35765
Compare
|
@buluoray thanks, the shadow-root miss was real. Head Blocking, fixed
Non-blocking, taken
|
6f35765 to
f87ac9f
Compare
f87ac9f to
5074cdb
Compare
|
Head Fixed
Rebutted
The reviews from @buluoray and @cruisercohen are on |
Human judgment recorded@CrysisDeu marked the first-principles AI finding as false positive, not applicable, or explicitly accepted for
This decision applies only to this commit. A new push requires a new judgment. |
The crewmate chat painted a permanent 6px thumb down the transcript's right edge, and so did the main chat: both mount TranscriptScrollShell, which inherited the global always-visible thumb from index.css. Three scrollbar treatments coexisted (always-on, hidden, hover-revealed) with no rule deciding which a surface got. One rule now: no scrollbar is visible at rest. A scroll box either hides its scrollbar entirely (`.scrollbar-none`, unchanged) or shows a thin thumb only while it is being scrolled, in the 6px column it reserves anyway, so the reveal moves no content. The base layer keeps the column with a transparent thumb and paints it under `[data-scrolling]`; `lib/scrollReveal.ts` sets that attribute on the scrolling element and clears it after a short linger, on the document and inside the two shadow roots the light-DOM rule cannot reach (Pierre's code/diff surfaces through both option factories' `unsafeCSS`, the workspace tree through its own). The Firefox half is fenced behind the `-moz-appearance` probe because Blink drops the pseudo-elements once a standard scrollbar property is set. The `.scrollbar-overlay` / `.scroll-fade` utilities and the file-explorer tab-strip thumb are removed. `scrollbarRevealOnly.test.ts` scans src/ for any thumb painted outside `[data-scrolling]` and measures the revealed thumb's 3:1 contrast per theme, replacing the two specs that measured the resting thumbs; `scrollReveal.test.ts` pins the attribute lifecycle. The `no-scrollbar-at-rest` AUTOSDE rule blocks a repaint in review, and the decision is recorded under docs/decisions/. Closes #23539
5074cdb to
27e1a95
Compare
|
Head |
Human judgment recorded@CrysisDeu recorded a legacy release (class
This decision applies only to this commit. A new push requires a new judgment. |
|
This override used the old command without a class. It was recorded as class |
The dashboard shows no scrollbar at rest (maintainer decision, docs/decisions/2026-10-23-scrollbars-are-never-always-visible.md, landing in #23550): a box either hides it or shows a thin thumb only while it is scrolling, without changing its width. The UX lane had no lens for it: on #23550 it passed the change but could only note the capped lists that lost their hover thumb, with no rule to hold a future diff to. Lens 7 (consistency) now carries the rule in both UX lane prompts: a diff that paints a thumb at rest, a hover-revealed thumb, a reveal that pushes content, or a screenshot showing a scrollbar while nothing scrolls is a finding; a scroll box that needs a cue gets an edge fade or a "more below" affordance, never a resting thumb; hiding one is never a regression. Refs #23539
The dashboard shows no scrollbar at rest (maintainer decision, docs/decisions/2026-10-23-scrollbars-are-never-always-visible.md, landing in #23550): a box either hides it or shows a thin thumb only while it is scrolling, without changing its width. The UX lane had no lens for it: on #23550 it passed the change but could only note the capped lists that lost their hover thumb, with no rule to hold a future diff to. Lens 7 (consistency) now carries the rule in both UX lane prompts: a diff that paints a thumb at rest, a hover-revealed thumb, a reveal that pushes content, or a screenshot showing a scrollbar while nothing scrolls is a finding; a scroll box that needs a cue gets an edge fade or a "more below" affordance, never a resting thumb; hiding one is never a regression. Refs #23539
The dashboard shows no scrollbar at rest (maintainer decision, docs/decisions/2026-10-23-scrollbars-are-never-always-visible.md, landing in #23550): a box either hides it or shows a thin thumb only while it is scrolling, without changing its width. The UX lane had no lens for it: on #23550 it passed the change but could only note the capped lists that lost their hover thumb, with no rule to hold a future diff to. Lens 7 (consistency) now carries the rule in both UX lane prompts: a diff that paints a thumb at rest, a hover-revealed thumb, a reveal that pushes content, or a screenshot showing a scrollbar while nothing scrolls is a finding; a scroll box that needs a cue gets an edge fade or a "more below" affordance, never a resting thumb; hiding one is never a regression. Refs #23539 Co-authored-by: CrysisDeu <crysisDeu@users.noreply.github.com>
Problem / Motivation
Goal: No scroll box in the dashboard shows a scrollbar at rest: a box either hides it entirely or shows a thin thumb only while it is being scrolled, without changing its width.
The crewmate chat (Members DM,
ChatPane) painted a permanent 6px thumb down the right edge of its transcript. So did the main chat: both mountTranscriptScrollShell(.chat-container), which has no scrollbar styling of its own and inherited the global always-visible thumb fromindex.css. A permanently scrollable region (a long chat, a long sidebar) turns a thumb into a fixed stripe, not a transient hint. The sessions sidebar had already hidden its own for that reason, which left the dashboard with three treatments and no rule: the global always-on thumb, the sidebar's fully hidden one, and the hover-revealed overlay on capped lists and code blocks.Why it matters
Every new scroll surface was making its own call, and the most-read surface of all, the chat transcript, carried the least considered one. One rule removes the decision from every future surface and the stripe from the two chats, while a scroller keeps a visible, grabbable thumb for the moments it is actually in use.
Not a goal
scrollbar-noneclass and inlinescrollbarWidth: 'none'from the surfaces that carry them. Fully hidden is one of the two allowed forms; those sites are correct as they are.src/apps/mochi/). They do not read the dashboard stylesheet; named out of scope in the gate.What changed (motivation → approach → change)
Goal → one global rule with a scrolling state the stylesheet can key on, rather than another per-surface class → the base layer in
website/src/index.csskeeps the 6px WebKit column (::-webkit-scrollbar{width:6px;height:6px}) with a transparent thumb and paints the thumb (--muted) under[data-scrolling]. Firefox takes the same two states throughscrollbar-width: thin/scrollbar-color, fenced behind@supports (-moz-appearance:none): Blink drops the pseudo-elements the moment a standard scrollbar property is set on a box and draws its 15px native bar instead (measured on the Pierre scroller before the fence went in).website/src/lib/scrollReveal.ts(new, installed inmain.tsxbefore render): one capturingscrolllistener on the document setsdata-scrollingon the element that scrolled and clears it 800ms after the last event.scrollis not composed, so a scroll inside a shadow root never reaches that listener; a MutationObserver watches for the two shadow-drawing hosts (diffs-container,file-tree-container) and attaches to their roots once each.CodeBlock/DiffBlock/DiffPanel/ContentRenderer/PapyrusEditor/WorkflowSourceCodeblock, the editor, the file-change chips) resolve options throughpierreFileOptions/pierreDiffOptions; both now fold inPIERRE_SCROLL_REVEAL_CSS(src/pierre/config.ts), which lands in the library's@layer unsafeand replaces its hover-painted thumb with the same[data-scrolling]reveal in the library's own token. The track stays 6px, so the reveal moves nothing. The@pierre/treestree gets the same gate on--trees-scrollbar-thumb-currentinPIERRE_TREE_STATE_ROW_CSS.styles/scrollbars-and-touch-hit.css: the.scroll-fadethumb rules, the whole.scrollbar-overlay/-thinblock and both coarse-pointer branches are gone (hover-reveal is not an allowed form); the horizontal.edge-fade-xmask (worn by the composer control row) stays. The 19 JSX sites that carried those classes drop them (13 files).apps/file-explorer/styles.tsloses the.mc-fe-tabsalways-on thumb;components/crew/layout/layoutEditor.cssloses a redundantscrollbar-width: thin.TranscriptScrollShell'sscrollbar-gutter: stable, the title overlays'right-1.5inset,composerDockMetrics' measured gutter and the composer / paste-mirror gutter pairing are untouched from main.website/AUTOSDE.yamlgains the blockingno-scrollbar-at-restrule (regex on added lines: a thumb colour orscrollbar-colorwhose line lacksdata-scrolling,scrollbar-width: auto, a revived utility);docs/decisions/2026-10-23-scrollbars-are-never-always-visible.mdrecords the decision and is indexed in the decisions README;website/docs/frontend-conventions.md§ Styling states the rule;website/docs/narrow-viewport.mddrops a reference to the removed overlay block.Backwards compatibility
Compatible: CSS, one small DOM attribute setter, and prompt/rule text; no API, config or data shape changes. Removes nothing: the
.scrollbar-overlay/.scroll-fadeclass names were internal utilities with no reader outsidewebsite/src(grep on origin/main: 31 + 9 JSX uses, all changed here; no app bundle, skill or doc references them). Every box still scrolls by wheel, trackpad, touch and keyboard, the column each box reserved on main is the column it reserves now, and the thumb is still grabbable while it shows.Tests
website/src/test/scrollReveal.test.ts(new): the attribute appears on a scroll, survives the linger while scrolling continues, clears after it, lands on the scrolled element only, reaches a scroller inside a shadow host added after install (directly and nested in an added subtree), and stops after uninstall. Fake timers; no sleeps.website/src/test/scrollbarRevealOnly.test.ts(new): anchors both engine halves of the global rule and the-mozfence; asserts the Pierre hooks ride on both factories and the tree sheet; walkssrc/and fails on any::-webkit-scrollbar-thumbcolour orscrollbar-colorwhose selector lacks[data-scrolling], anyscrollbar-widthother thanthin/none, and the React inline spellings; names the Mochi files out of scope and checks each still paints; measures the revealed--mutedthumb against--bg,--bg-elevatedand--cardin every theme (36+) for the WCAG 1.4.11 3:1 floor. Mutation-checked locally: a scratch CSS file and a scratch.tswith five bad shapes produced exactly five failures, and two[data-scrolling]-gated rules passed.scrollbarThumbContrast.test.tsandscrollbarOverlayTouch.test.ts: both measured resting thumbs that no longer exist. The contrast floor they pinned lives on inscrollbarRevealOnly.test.ts; the palette-resolver anchors move intothemeFillForeground.test.ts.ChatPage.composerChromeOcclusion.test.tsx(drops the two overlay-utility cases),SkillsTab.test.tsx(asserts the list is a scroll box, not which utility it wears),ChatSidebar.scrollbar.test.tsx(header only), cross-reference comments infocusRingContrast.test.ts,themePalette.ts,touchHitArea.test.ts.Run locally: the twelve touched vitest files pass;
tsc -p tsconfig.app.json, eslint on the changed files,i18n-check.mjs,check-phantom-classes.mjsandscripts/docs-lint.share clean.Manual verification
website/scripts/capture-23539-hidden-scrollbars.mjs(new) mounts the REAL Members page with a 41-bubble Radar thread (the last one a fenced block wide enough to scroll sideways) behind route-intercepted/api, launches Chromium with--hide-scrollbarsturned OFF so a painted bar reserves width, and probes two scrollers at rest, immediately after a driven scroll, and after the linger: the transcript (light DOM) and Pierre's[data-code]inside its shadow root.[data-code], restdata-scrollingBoth themes. A recording of the same run (wheel down, rest, wheel up, wheel the code block sideways) is attached under Screenshots. The before frame (
main) shows the thumb at rest; this head shows nothing at rest and the thumb mid-scroll in the same column. (The capture harness entrycapture/members-page.tsxinstallsscrollRevealasmain.tsxdoes, so it exercises the real mechanism.)Screenshots / video
Recording, dark theme: the crewmate transcript is wheel-scrolled down, left alone (thumb fades after the linger), wheeled back up, then the wide code block is wheel-scrolled sideways. The thumb appears only while scrolling, and the bubbles' right edges never move:
after-scroll-dark.webm
Right edge of the transcript, dark, 2x. Left:
mainat rest (permanent thumb). Middle: this head at rest (nothing). Right: this head mid-scroll (thumb shown, same 6px column):Light theme
after-scroll-light.webm
Related Issues
Closes #23539
Related: #23547 (scroll cues on capped lists and wide code blocks), #23568 (the UX reviewer rule)
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.