From fcbe5bc202559b4ec3be3db35752ed330e5b85bb Mon Sep 17 00:00:00 2001 From: Nate Date: Sun, 14 Sep 2025 17:54:02 -0700 Subject: [PATCH] Revert "feat: always show scrollbar" This reverts commit 4c5c5ddc51dfd72cbec8f3efd4bf5f37132a1367. --- .../pages/config/sections/UserSettingsSection.tsx | 12 ++++++++++-- gui/src/pages/gui/Chat.tsx | 6 ++++-- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/gui/src/pages/config/sections/UserSettingsSection.tsx b/gui/src/pages/config/sections/UserSettingsSection.tsx index 587ecdf08..afa56aca4 100644 --- a/gui/src/pages/config/sections/UserSettingsSection.tsx +++ b/gui/src/pages/config/sections/UserSettingsSection.tsx @@ -62,7 +62,7 @@ export function UserSettingsSection() { const continueAfterToolRejection = config.ui?.continueAfterToolRejection ?? false; const codeWrap = config.ui?.codeWrap ?? false; - + const showChatScrollbar = config.ui?.showChatScrollbar ?? false; const readResponseTTS = config.experimental?.readResponseTTS ?? false; const autoAcceptEditToolDiffs = config.ui?.autoAcceptEditToolDiffs ?? false; const displayRawMarkdown = config.ui?.displayRawMarkdown ?? false; @@ -129,7 +129,15 @@ export function UserSettingsSection() { value={codeWrap} onChange={(value) => handleUpdate({ codeWrap: value })} /> - + + handleUpdate({ showChatScrollbar: value }) + } + /> (null); const tabsRef = useRef(null); const history = useAppSelector((state) => state.session.history); - + const showChatScrollbar = useAppSelector( + (state) => state.config.config.ui?.showChatScrollbar, + ); const codeToEdit = useAppSelector((state) => state.editModeState.codeToEdit); const mode = useAppSelector((store) => store.session.mode); const isInEdit = useAppSelector((store) => store.session.isInEdit); @@ -379,7 +381,7 @@ export function Chat() { [sendInput, isLastUserInput, history, stepsOpen], ); - const showScrollbar = true; + const showScrollbar = showChatScrollbar ?? window.innerHeight > 5000; return ( <>