GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(web): keep overview conversations in the redesigned summary · pingdotgg/t3code@53270d8

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • apps/web/src/components
    • DiffPanel.tsx
    • pullRequest
      • PullRequestQuietEntries.tsx
      • PullRequestSummaryTab.tsx
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎apps/web/src/components/DiffPanel.tsx‎

Copy file name to clipboardExpand all lines: apps/web/src/components/DiffPanel.tsx
+3-1Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1144,7 +1144,9 @@ export default function DiffPanel({
11441144
wordWrap={wordWrap}
11451145
onWordWrapChange={setWordWrap}
11461146
ignoreWhitespace={diffIgnoreWhitespace}
1147-
onIgnoreWhitespaceChange={(value) => useDiffPanelSessionStore.getState().setIgnoreWhitespace(value)}
1147+
onIgnoreWhitespaceChange={(value) =>
1148+
useDiffPanelSessionStore.getState().setIgnoreWhitespace(value)
1149+
}
11481150
hasFiles={diffFileKeys.length > 0}
11491151
testFileCount={testFileCount}
11501152
hideTestFiles={hideTestFiles}
Collapse file

‎apps/web/src/components/pullRequest/PullRequestQuietEntries.tsx‎

Copy file name to clipboardExpand all lines: apps/web/src/components/pullRequest/PullRequestQuietEntries.tsx
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ export function PullRequestResolvedThreadRow({
145145
defaultOpen = false,
146146
}: {
147147
defaultOpen?: boolean;
148-
path: string;
148+
path: string | null;
149149
line: number | null | undefined;
150150
outdated: boolean;
151151
/** The thread is still open on the host, but the review that started it was dismissed. */
@@ -155,7 +155,7 @@ export function PullRequestResolvedThreadRow({
155155
children: ReactNode;
156156
}) {
157157
const [open, setOpen] = useState(defaultOpen);
158-
const label = `${path}${line ? `:${line}` : ""}`;
158+
const label = path === null ? "Overview" : `${path}${line ? `:${line}` : ""}`;
159159
const comments = `${commentCount} ${commentCount === 1 ? "comment" : "comments"}`;
160160
return (
161161
<Collapsible open={open} onOpenChange={setOpen}>
Collapse file

‎apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx‎

Copy file name to clipboardExpand all lines: apps/web/src/components/pullRequest/PullRequestSummaryTab.tsx
+21-4Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import {
1616
type PullRequestDetailView,
1717
type PullRequestRef,
1818
type PullRequestConversationThread,
19+
type PullRequestReviewThread,
1920
type ScopedThreadRef,
2021
pullRequestConversationThreads,
2122
type PullRequestThreadCommentsResult,
@@ -400,13 +401,20 @@ export function PullRequestSummaryTab({
400401
}
401402
const linkedAnchor =
402403
linked?.url === detail.url
403-
? resolvePullRequestReviewAnchor(linked.anchor, detail.comments, pullRequestConversationThreads(detail))
404+
? resolvePullRequestReviewAnchor(
405+
linked.anchor,
406+
detail.comments,
407+
pullRequestConversationThreads(detail),
408+
)
404409
: null;
405410
const matchesLink = (url: string | null) =>
406411
linkedAnchor !== null && pullRequestAnchorMatchesUrl(linkedAnchor, url);
407412
const itemMatchesLink = (item: PullRequestConversationItem) =>
408413
pullRequestConversationItemComments(item).some((comment) => matchesLink(comment.url));
409-
const items = pullRequestConversationItems(detail.comments, pullRequestConversationThreads(detail));
414+
const items = pullRequestConversationItems(
415+
detail.comments,
416+
pullRequestConversationThreads(detail),
417+
);
410418
const commentCount = items.reduce(
411419
(count, item) => count + pullRequestConversationItemComments(item).length,
412420
0,
@@ -586,6 +594,7 @@ export function PullRequestSummaryTab({
586594
linked,
587595
detail.comments,
588596
detail.reviewThreads,
597+
detail.overviewThreads,
589598
activityPending,
590599
]);
591600
// oxlint-disable-next-line t3code/no-unreasoned-state-sync -- the hold observes DOM outside React and must end with the tab
@@ -819,7 +828,7 @@ export function PullRequestSummaryTab({
819828
);
820829
};
821830

822-
const renderThreadCard = (thread: PullRequestConversationThread) => (
831+
const renderThreadCard = (thread: PullRequestReviewThread) => (
823832
<ReviewThreadCard
824833
// Named with the pull request too: a thread id is the host's own.
825834
key={`${detail.url}:${thread.id}:${thread.comments.some((comment) => matchesLink(comment.url)) ? linked?.count : 0}`}
@@ -926,7 +935,15 @@ export function PullRequestSummaryTab({
926935
) : null
927936
}
928937
>
929-
{renderThreadCard(item.thread)}
938+
{item.thread.path === null ? (
939+
<div className="space-y-2">
940+
{renderCommentCard(comment, item.thread)}
941+
{replies}
942+
{moreReplies}
943+
</div>
944+
) : (
945+
renderThreadCard(item.thread)
946+
)}
930947
</PullRequestResolvedThreadRow>
931948
);
932949
}

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.