diff --git a/ui/src/components/documents/DocumentReviewRail.test.tsx b/ui/src/components/documents/DocumentReviewRail.test.tsx index fb27531612b..befc591e4a8 100644 --- a/ui/src/components/documents/DocumentReviewRail.test.tsx +++ b/ui/src/components/documents/DocumentReviewRail.test.tsx @@ -224,6 +224,26 @@ describe("DocumentReviewRail", () => { expect(container.textContent).toContain("added text"); }); + it("wires Resolve onto anchored (non-orphan) suggestion cards", async () => { + // Regression: onResolveSuggestion was only wired on the orphaned-suggestion + // branch, so Resolve never appeared on healthy/anchored cards where it's + // most useful. Assert the non-orphan render path exposes it. + await act(() => + root.render( + , + ), + ); + expect(container.querySelector('[data-testid="suggestion-resolve-sug-1"]')).not.toBeNull(); + }); + it("pins orphaned anchors into a collapsible group when the orphan filter is on", async () => { const index = makeIndex({ annotationThreads: [ diff --git a/ui/src/components/documents/DocumentReviewRail.tsx b/ui/src/components/documents/DocumentReviewRail.tsx index ecf118e2869..c6e8519d6b6 100644 --- a/ui/src/components/documents/DocumentReviewRail.tsx +++ b/ui/src/components/documents/DocumentReviewRail.tsx @@ -15,7 +15,7 @@ import { TooltipProvider, TooltipTrigger, } from "@/components/ui/tooltip"; -import { cn } from "@/lib/utils"; +import { cn, isApplePlatform } from "@/lib/utils"; import type { ReviewAuthorMaps } from "@/lib/document-review-authors"; import { DocumentThreadCard, type RailThread } from "./DocumentThreadCard"; import { SuggestionCard } from "./SuggestionCard"; @@ -371,6 +371,7 @@ function ReviewRailBody({ authorMaps={authorMaps} onAccept={onAcceptSuggestion} onReject={onRejectSuggestion} + onResolve={onResolveSuggestion} onReply={onReplySuggestion} onViewDiff={onViewSuggestionDiff} /> @@ -447,10 +448,12 @@ function OrphanGroup({ count, children }: { count: number; children: React.React } function RailEmpty({ message }: { message: string }) { + // Platform-aware hint: macOS/iOS reviewers see ⌘⇧M, Windows/Linux see Ctrl+Shift+M. + const hotkey = isApplePlatform() ? "⌘⇧M" : "Ctrl+Shift+M"; return (

{message}

-

⌘⇧M to comment from a selection

+

{hotkey} to comment from a selection

); }