Skip to content

Commit 636e21b

Browse files
fix(ui): prevent horizontal model picker scrolling (#129928)
Co-authored-by: roboclaw-bot <[email protected]> Co-authored-by: Tak Hoffman <[email protected]>
1 parent 1f71018 commit 636e21b

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

‎ui/src/e2e/app-chrome-interaction.e2e.test.ts‎

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ async function captureUiProof(page: Page, fileName: string) {
6060
}
6161

6262
suite.define(() => {
63-
it("uses one canonical scrollbar profile and keeps selection in chat and inputs", async () => {
63+
it("keeps canonical scrollbars without horizontal model-picker overflow and preserves selection", async () => {
6464
if (captureUiProofEnabled) {
6565
await mkdir(uiProofArtifactDir, { recursive: true });
6666
}
@@ -82,7 +82,12 @@ suite.define(() => {
8282
},
8383
],
8484
models: [
85-
{ id: "gpt-5.5", name: "GPT-5.5", provider: "openai" },
85+
{
86+
contextWindow: 1_000_000,
87+
id: "gpt-5.6-sol-openclaw",
88+
name: "openai/gpt-5.6-sol-openclaw",
89+
provider: "openai",
90+
},
8691
...Array.from({ length: 24 }, (_value, index) => ({
8792
id: `scroll-model-${index + 1}`,
8893
name: `Scroll Model ${index + 1}`,
@@ -111,6 +116,8 @@ suite.define(() => {
111116
sidebarSelection: getComputedStyle(sidebar).userSelect,
112117
sidebarScrollbar: getComputedStyle(sessions, "::-webkit-scrollbar").width,
113118
modelPickerScrollbar: getComputedStyle(modelPicker, "::-webkit-scrollbar").width,
119+
modelPickerOverflowX: getComputedStyle(modelPicker).overflowX,
120+
modelPickerHorizontalOverflow: modelPicker.scrollWidth - modelPicker.clientWidth,
114121
};
115122
});
116123
// One canonical width everywhere: the sidebar no longer overrides
@@ -123,6 +130,8 @@ suite.define(() => {
123130
sidebarSelection: "none",
124131
sidebarScrollbar: "12px",
125132
modelPickerScrollbar: "12px",
133+
modelPickerOverflowX: "hidden",
134+
modelPickerHorizontalOverflow: 0,
126135
});
127136
await page.keyboard.press("Escape");
128137
expect(await dragAcross(page, transcript)).toContain("Selectable transcript");

‎ui/src/styles/chat/layout.css‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6400,7 +6400,7 @@ button.chat-pr__diff {
64006400
display: block;
64016401
min-width: 0;
64026402
padding: 0 7px 7px;
6403-
overflow-y: auto;
6403+
overflow: hidden auto;
64046404
overscroll-behavior: none;
64056405
}
64066406

0 commit comments

Comments
 (0)