GeezerVison is showing github.com — feat(web): add a chat page scroll distance setting by artile · Pull Request #17507 · pingdotgg/t3code
Conversation
Problem
Page Up and Page Down already scroll the chat, but a full page can remove useful reading context.
Users have no client setting to choose a shorter distance.
Change
Add General → Behavior → Chat page scroll distance with 100% and 50% choices.
The client stores the choice through its current settings system, with search, row reset, and device-default reset.
Older settings decode to 100%.
Scale the current usable page distance after the composer inset and alignment offset.
Taps and held keys use the same distance, with the current acceleration and boundary rules.
Timeline page keys use the existing composer scroll controller, so the setting applies with either focus path.
Editable controls, nested scroll areas, the terminal, IME input, and modified keys keep their own handlers.
Scope and approval
This follows the focused configuration option route.
Page Up/Page Down chat navigation already exists.
This option controls only its scroll distance in web and desktop, with a default fraction of 1.0.
It uses the existing client settings and does not add a new navigation workflow.
Verification
On macOS with Node 24.13.1:
vp test run \
packages/contracts/src/settings.test.ts \
apps/web/src/components/chat/pageScrollController.test.ts \
apps/web/src/components/chat/timelineScrollTarget.test.ts \
apps/web/src/clientPersistenceStorage.test.ts \
apps/web/src/hooks/useSettings.test.ts \
apps/web/src/components/settings/settingsSearch.test.ts \
apps/web/src/components/settings/SettingsPanels.restore.test.tsx \
apps/desktop/src/settings/DesktopClientSettings.test.ts
vp run --filter @t3tools/web --filter @t3tools/contracts --filter @t3tools/desktop typecheck
All 313 tests across 8 files passed. The three package typechecks passed.
Targeted lint and format checks passed for the changed files.
Lint reports the same 94 warning messages as the base commit, with no new warnings or errors.
The T3 Browser panel tested an isolated dev server with 24 synthetic chat items at a 1280 × 800 viewport.
At the same viewport and composer inset, a tap moved 540 px at 100% and 270 px at 50%.
Timeline and body focus also used the chosen fraction. A live setting change affected the mounted controller.
Held scrolling stopped on keyup. An overflowing composer scrolled first, then handed off at its boundary.
Terminal input kept the timeline still. Nested-scroll and modified-key DOM checks left the events unhandled by the timeline.
The automated tests also check both directions, hold acceleration, old settings, validation, persistence, search, and reset.
The desktop renderer was not launched separately. Its shared web UI and file-persistence tests passed.
Before:

After:

Short recording: 100%, 50%, and held-key release.
The recording omits the idle wait before the test. Review assets live on the fork and are not part of the commit.
Implemented and tested with GPT-6.1-Sol, max reasoning, in the Codex harness through T3 Code.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Approvability
Verdict: Not approved
Macroscope's review found this PR not approvable — This adds a persisted chat behavior setting and changes PageUp/PageDown event handling across the shared web/desktop chat surface, including held-key scrolling and focus transitions. The option is backwards-compatible and well tested, but the existing keyboard path and shared production components warrant human review.
You can add or adjust custom eligibility rules. Learn more.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|

No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
- Configuration used: Path: .coderabbit.config.ts
- Review profile: CHILL
- Plan: Advanced
- Run ID:
97ef3ac4-ee3a-4d67-a4a0-93ba5ad018aa
📥 Commits
Reviewing files that changed from the base of the PR and between ec80933 and c802577.
📒 Files selected for processing (13)
apps/desktop/src/settings/DesktopClientSettings.test.ts
apps/web/src/clientPersistenceStorage.test.ts
apps/web/src/components/ChatView.tsx
apps/web/src/components/chat/pageScrollController.test.ts
apps/web/src/components/chat/pageScrollController.ts
apps/web/src/components/settings/SettingsPanels.restore.test.tsx
apps/web/src/components/settings/SettingsPanels.tsx
apps/web/src/components/settings/settingsSearch.test.ts
apps/web/src/components/settings/settingsSearch.ts
apps/web/src/hooks/useSettings.test.ts
docs/user/keybindings.md
packages/contracts/src/settings.test.ts
packages/contracts/src/settings.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
📝 Walkthrough
Walkthrough
The change adds a persisted setting for chat timeline page-scroll distance, with values of 100% and 50%. Page Up and Page Down use the configured distance. General settings exposes the options, and keybinding documentation describes the behavior.
Changes
Chat page scrolling
| Layer / File(s) |
Summary |
Define and persist the scroll fraction packages/contracts/src/settings.ts, packages/contracts/src/settings.test.ts, apps/web/src/clientPersistenceStorage.test.ts, apps/web/src/hooks/useSettings.test.ts, apps/desktop/src/settings/DesktopClientSettings.test.ts |
Client settings and patches accept 1 or 0.5, defaulting to 1. Tests cover decoding, persistence, hydration, and older settings. |
Apply the fraction to timeline scrolling apps/web/src/components/chat/pageScrollController.ts, apps/web/src/components/chat/pageScrollController.test.ts, apps/web/src/components/ChatView.tsx |
The controller scales page-scroll distance using the current fraction. ChatView delegates Page Up and Page Down scrolling to the controller and releases active input on keyup, focus changes, window blur, and cleanup. |
Expose the scroll setting apps/web/src/components/settings/SettingsPanels.tsx, apps/web/src/components/settings/SettingsPanels.restore.test.tsx, apps/web/src/components/settings/settingsSearch.ts, apps/web/src/components/settings/settingsSearch.test.ts, docs/user/keybindings.md |
General settings presents the available distances and a reset action. Restore-defaults handling includes the setting. Search terms and keybinding documentation cover the new option and its keyboard behavior. |
Priority: ⬇️ Low
Estimated code review effort: 3 (Moderate) | ~25 minutes
Change: Feature
Sequence Diagram(s)
sequenceDiagram
participant Keyboard
participant ChatView
participant pageScrollController
participant getClientSettings
participant TimelineContainer
Keyboard->>ChatView: PageUp or PageDown keydown
ChatView->>pageScrollController: Handle page-scroll input
pageScrollController->>getClientSettings: Read chatPageScrollFraction
pageScrollController->>TimelineContainer: Scroll by the configured page distance
Loading
Suggested reviewers: juliusmarminge
Merge Risk
Merge Risk: ⚪ Minimal · up to c8025
This adds a 100% or 50% chat page scroll distance setting that defaults to the existing behavior. No merge-blocking risk was found.
-
Security Architecture Review
Security architecture risk: ⚪ Minimal · up to c8025
The reviewed change remains a device-local scrolling preference. Its accepted values are restricted, older settings preserve the existing distance, and the new keyboard route retains input-ownership controls. No material security risk was found in the reviewed change.
Retained concerns
No architecture-level concerns identified.
-
Security review details
Security Blast Radius
- inferred — The added preference affects device-local chat navigation, potentially across chats viewed on that client. The traced update does not carry an environment or tenant write, and its scrolling consumer does not grant service, credential, or command-execution authority.
Trust Boundaries and Controls
- observed — The changed document handler delegates page keys only after target, default-prevention, editable-path, floating-layer, modifier, IME, and nested-scroll checks. It retains the pre-existing outside-timeline exclusion and adds key-code 229 protection. Terminal drawers are rendered outside the timeline rather than being admitted by this route.
Resilience and Maintainability Implications
- observed — The unchanged client persistence path orders writes through a queue and defers pre-hydration patches. Its optimistic patch path logs persistence failure without reverting the snapshot, so a failed save can leave a locally visible preference unsaved. Desktop persistence uses temporary-file replacement. The new selector patches only the scroll preference, not security-sensitive settings.
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
| Check name |
Status |
Explanation |
| Title check |
 |
The title is concise, uses the repository's conventional format, and clearly identifies the main change: adding a chat page scroll distance setting for web. |
| Description check |
 |
The description includes the required Problem, Change, Scope and approval, and Verification sections. It explains the behavior, scope, approval basis, focused test results, manual checks, limitations,… |
| Linked Issues check |
 |
Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check |
 |
Check skipped because no linked issues were found for this pull request. |
✨ Finishing Touches
🧪 Generate unit tests (beta)
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Note Written by gpt-6.1-sol on behalf of Maria
Thanks for proposing a shorter page-scroll distance. This fits the guide's focused configuration route, but right now we are only taking focused bug fixes from outside contributors under Read this first. The new 50%/100% setting changes working navigation without establishing a broken flow. Please preserve the reading-context request in an Ideas discussion and request reconsideration when maintainers agree to take this configuration change.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Labels
size:L
100-499 changed lines (additions + deletions).
vouch:unvouched
Author is not yet trusted in the VOUCHED list.
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
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.
|