refactor: redesign composer quote cards as compact horizontal chips#323
Conversation
Multiple quotes now sit side-by-side as fixed-size 160×76pt cards that scroll horizontally, instead of stacking full-width and pushing the editor down. The card itself drops the explicit "Replying to <model>" header — that source info moves into the hover tooltip — so each card just shows the truncated quoted text against a subtle surface with a left accent bar. The dismiss button shrinks to 16pt and is hidden until hover, matching the minimal look in the new design. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughQuote card components are redesigned with internal hover-state tracking and tooltip generation. The composer variant adopts a compact fixed-size layout with layered styling that conditionally displays the dismiss accessory on hover. Both CompactComposerOverlayRows and ExpandedComposerOverlay switch from vertical to horizontal scrolling to display the new cards. ChangesQuote Card Redesign for Horizontal Overlay Layout
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@Sources/UI/QuoteCardViews.swift`:
- Around line 197-206: The accessory overlay is only visible on pointer hover
(isHovering) so keyboard focus doesn't reveal it; update the overlay to also
show when the dismiss button is focused by adding focus tracking and combining
it with isHovering (e.g., add a Bool binding like isDismissButtonFocused passed
into QuoteDismissButton and expose a `@FocusState` inside QuoteDismissButton to
set that binding when focused), then change the opacity condition from
.opacity(isHovering ? 1 : 0) to .opacity((isHovering || isDismissButtonFocused)
? 1 : 0) so the accessory becomes visible for sighted keyboard users as well.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: fc240dfa-5d31-4b70-a92f-f4a286365c5c
📒 Files selected for processing (3)
Sources/UI/CompactComposerOverlayRows.swiftSources/UI/ExpandedComposerOverlay.swiftSources/UI/QuoteCardViews.swift
The dismiss button was tied solely to .onHover, so a sighted keyboard user who Tab-focused it would land on something they couldn't see. Now the card surfaces the button whenever it has either pointer hover or keyboard focus, and the button itself shows an accent ring while focused so the destination is obvious. QuoteCardContainer takes the focus signal as a plain Bool so MessageQuoteCardView (which has no accessory) is unaffected. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
Files
Sources/UI/QuoteCardViews.swift— newcomposerQuoteBodylayout,QuoteCardLayoutconstants, smaller hover-revealed dismiss button, tooltip composition.Sources/UI/CompactComposerOverlayRows.swift—quoteCardsRowswapped fromVStackto horizontalScrollView+HStack.Sources/UI/ExpandedComposerOverlay.swift— Quotes accessory section swapped to the same horizontal layout.The message-side
MessageQuoteCardViewis untouched.Test plan
MessageQuoteCardViewrendering is unchanged.🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
UI/UX Improvements