- Shipped
- September 11, 2026 at 1:57 AM UTC
- Author
- Kamo
- Commit
- 1fad27a
Maximizing a tool window left a column of scrollbar buttons from the window behind it floating in the middle of the pane, and two overlapping floating windows showed the lower one's bars straight through the upper one. The app's bars are not inside the element they scroll. ScrollbarLayer paints each from a portal at <body>, at the scroller's nearest z-indexed ancestor plus one: for a tool body, the shell plus one. Last in the document, a bar wins every tie. Since 2c933ecf the dock paints windows at their RANK, one level apart, so a window's shell-plus-one was exactly the level of the window stacked on it, and every window's bars came through the window directly above it: the docked window under the maximized pane, a floating window under another, and the pane itself under a window opened on top of it. Windows are now painted two levels apart (DOCK_Z_STRIDE). The level between belongs to what paints against a window from outside it: its bars above it, and the carried window's snap indicator below it. At a stride of one the indicator had also sat on the next window down's level, behind that window, instead of over the docked windows as its comment says. Order, the base of 201 and the navigator/strip/nav-lift readers are unchanged. The band is twice as wide per window, so it reaches the hexhead stage (250) at 25 windows rather than 49, and 60 windows still paint at 319, far under MUI's 1300. Measured in real Chrome on the real dock and scrollbar layer (bodies stubbed), hit-testing every 6px of the top window: on HEAD a docked support window's bar owned the pointer over a 32x576px strip of a maximized chat, a floating window's bar owned one across the window above it, and the pane's bars came through a window floated over its edge. With the stride, none of the three, and each window's own bars still paint over it where nothing covers them. windowScrollbarStacking.test.ts pins it by asking the real overlayZIndex where a bar in each painted shell will land.