:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
fix(today): show the merge icon and state badge on space feed pull requests (#109800)
Shy Altereb578a804f50
diff --git a/products/tasks/frontend/spaces/SpaceFeedPullRequestRow.tsx b/products/tasks/frontend/spaces/SpaceFeedPullRequestRow.tsxindex f974b7f7281c..c04fe536deda 100644--- a/products/tasks/frontend/spaces/SpaceFeedPullRequestRow.tsx+++ b/products/tasks/frontend/spaces/SpaceFeedPullRequestRow.tsx@@ -1,6 +1,6 @@import { useValues } from 'kea'-import { IconPullRequest } from '@posthog/icons'+import { IconPullRequest, type IconProps } from '@posthog/icons'import { Badge, Card, Text, cn } from '@posthog/quill'import { LinkPrimitive } from 'lib/lemon-ui/Link'@@ -13,6 +13,14 @@ import { pullRequestLinkLabel, pullRequestStateMeta } from './TaskPullRequestChiimport { TaskPullRequest } from './taskPullRequests'import { TaskUserAvatar, taskUserName } from './TaskUserAvatar'+function IconGitMerge(props: IconProps): JSX.Element {+ return (+ <svg viewBox="0 0 16 16" fill="currentColor" aria-hidden="true" focusable="false" {...props}>+ <path d="M5.45 5.154A4.25 4.25 0 0 0 9.25 7.5h1.378a2.251 2.251 0 1 1 0 1.5H9.25A5.734 5.734 0 0 1 5 7.123v3.505a2.25 2.25 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.95-.218ZM4.25 13.5a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm8.5-4.5a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5ZM5 3.25a.75.75 0 1 0 0 .005V3.25Z" />+ </svg>+ )+}+interface SpaceFeedPullRequestRowProps {pullRequest: TaskPullRequest/** The session that opened the pull request. */@@ -33,9 +41,8 @@ export function SpaceFeedPullRequestRow({const known = pullRequestStateMeta(state)// GitHub reports no title to the web, so the row names the session that opened the pull request.const title = session.title || 'Untitled session'- const icon = (- <IconPullRequest className={cn('size-3.5 shrink-0', known ? known.iconClassName : 'text-muted-foreground')} />- )+ const Icon = state === 'merged' ? IconGitMerge : IconPullRequest+ const icon = <Icon className={cn('size-3.5 shrink-0', known ? known.iconClassName : 'opacity-50')} />const number = (<Text render={<span />} size="xs" variant="muted" className="shrink-0">{`#${pullRequest.number}`}@@ -96,7 +103,7 @@ export function SpaceFeedPullRequestRow({</Text>)}</div>- {known && <Badge className="shrink-0">{known.label}</Badge>}+ <Badge className="shrink-0">{known?.label ?? 'Open'}</Badge></div><Text size="xs" variant="muted" className="mt-1.5 truncate">{pullRequest.repository}