A pure-presentation React component that renders GitHub activity (commits, pull requests, and PR reviews) as a unified visual card in two layout variants: a horizontal `row` for list views and a `compact` inline card for chat markers. ## Key Components ### `GitHubActivityCard` Main export. Renders a `GitHubActivityItem` in either `"row"` or `"compact"` variant. Accepts an optional `anchorProps` bundle from the caller (e.g., a `useNavLink` hook) to control navigation without internal routing logic. ### `GitHubActivityCardSkeleton` Loading placeholder matching the layout of `GitHubActivityCard` for both variants. ### Exported Utilities | Function | Description | |---|---| | `kindLabel(kind)` | Maps `GitHubActivityKind` → `"Commit"` / `"PR"` / `"Review"` | | `formatActivityId(id, kind)` | Shortens a SHA to 7 chars or prefixes PR/review IDs with `#` | | `parseGithubTitle(title, kind)` | Strips bracket prefix tags (e.g., `[Review:APPROVED]`), returns display text and `PrReviewState` | | `reviewStateLabel(state)` | Maps `PrReviewState` → human label (`"Approved"`, `"Changes"`, etc.) | ## Usage Example ```typescript import { GitHubActivityCard } from './github-activity-card' import type { GitHubActivityItem } from '../types/entities/github-activity' const item: GitHubActivityItem = { kind: 'pull_request', id: '42', title: 'Fix auth token refresh', repo: 'flamingo-stack/openframe-oss-lib', url: 'https://github.com/flamingo-stack/openframe-oss-lib/pull/42', dateUpdated: '2024-11-01T12:00:00Z', } // Compact card (chat inline) // Row with caller-controlled navigation handleNav(e), }} /> // Loading state ``` **Source:** [`github-activity-card.tsx`](https://github.com/flamingo-stack/openframe-oss-lib/blob/main/github-activity-card.tsx)