feat(acp-client): add scroll-to-bottom FAB in chat message area#171
Merged
feat(acp-client): add scroll-to-bottom FAB in chat message area#171
Conversation
Small floating action button (down chevron) appears over the message area when the user has scrolled up and there are messages. Clicking it calls scrollToBottom() from the useAutoScroll hook. - Wrapped message area in relative container for FAB positioning - FAB hidden when at bottom or when no messages exist - 32px circle, white bg, subtle shadow, hover state Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
scrollToBottom()from theuseAutoScrollhookChanges
AgentPanel.tsx: Wrapped message area inrelativecontainer, added FAB with conditional rendering based onisAtBottomandmessages.items.lengthAgentPanel.test.tsx: 4 new tests (shows when not at bottom, hides when at bottom, hides when no messages, calls scrollToBottom on click). Updated 1 existing test for new DOM structure (flex-1→h-fullon scroll container).Validation
pnpm lintpnpm typecheck(viapnpm build)pnpm test— 246 tests passbottom-3 right-3, won't overlap contentUI Compliance Checklist (Required for UI changes)
aria-label="Scroll to bottom",titleattribute, keyboard accessible via tabuseAutoScrollhookExceptions (If any)
Agent Preflight (Required)
Classification
External References
N/A: Pure UI addition using existing hook API (
useAutoScrollalready exposesisAtBottomandscrollToBottom).Codebase Impact Analysis
packages/acp-client/src/components/AgentPanel.tsx— Added FAB button, wrapped message area in relative containerpackages/acp-client/src/components/AgentPanel.test.tsx— 4 new tests, 1 updated testDocumentation & Specs
N/A: Small UI enhancement, no API or behavior changes requiring documentation updates.
Constitution & Risk Check
bottomThresholdoption in the hook.Generated with Claude Code