Repository navigation
Keep native windows unscrollable, and paint theme changes this frame - #15
Merged
AllTerrainDeveloper merged 1 commit intoAug 19, 2026
Merged
Conversation
Two Theme-tab complaints with one root feeling: the tool stopped being where you left it. The shell gives a native window's body overflow:auto, and under some tab-switch/resize sequences the browser decides there is scrollable overflow — one stray wheel tick then hides the toolbar under the title bar and opens a dead band at the bottom. Nothing in these windows ever wants the body scrolled: a stylesheet rule now stops the wheel and pinWindowBodyScroll() undoes the scrolls CSS cannot reach. And a theme control no longer waits out a debounce plus a REST round trip to show what it did: every token is a custom property on the preview's wrapper, so the same value written inline shows the change the moment it is clicked — dials, single tokens, imports and whole theme switches alike. The server render still lands 180ms later and remains the truth; it just stopped being the first feedback. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0119U4sRRWGcTQdwYreTwpAp
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.
Two user-reported Theme-tab issues
1. The bottom gap. ([screenshot reported by Daniel]) The shell's
os-window__bodyisoverflow: auto, and under some tab-switch/resize sequences the browser decides our windows have scrollable overflow even though every pane manages its own. One stray wheel tick (or a focus-drivenscrollIntoView) then shunts the whole tool up — toolbar hidden under the title bar, equal dead band at the bottom. Fix is belt and braces:.os-window__body:has(> .atfb/.atfe/.atfs/.atfa) { overflow: hidden }— stops wheel scrolling.pinWindowBodyScroll()(new,ui.ts) — a passive scroll listener that snaps the body back to 0, catching the programmatic scrolls CSS can't; wired at all four window mounts.Verified on the 8889 site with Playwright: forced
scrollTop = 300snaps back to0; drag-resize and maximize keep the panes glued to the window bottom.2. Non-instant theme controls. Every control waited out a 180ms debounce + REST round trip before anything changed. Since every theme token is a CSS custom property scoped to
.atf-form-wrap,paintNow()writes the same values inline the instant a control is clicked — single tokens, quick dials, theme-card switches (full resolved set), and JSON imports. The debounced server render still lands and remains the truth; it just stopped being the first feedback.Verified live: clicking Roundness → Pill sets
--atf-radius-field: 999pxon the wrapper in the same tick; clicking Midnight paints--atf-surface: #1d2327in the same tick.Tests
tsc --noEmitclean, 251 vitest ✓ (bundles rebuilt)🤖 Generated with Claude Code
https://claude.ai/code/session_0119U4sRRWGcTQdwYreTwpAp