diff --git a/frontend/src/components/session/ForkCard.tsx b/frontend/src/components/session/ForkCard.tsx new file mode 100644 index 00000000..7974faf5 --- /dev/null +++ b/frontend/src/components/session/ForkCard.tsx @@ -0,0 +1,61 @@ +import { GitFork } from 'lucide-react' +import { cn } from '@/lib/utils' +import type { ForkPointResponse } from '@/types/branching' + +interface ForkCardProps { + fork: ForkPointResponse + selectedBranchId: string | null + onSelectOption: (branchId: string) => void +} + +export function ForkCard({ fork, selectedBranchId, onSelectOption }: ForkCardProps) { + return ( +
+ {/* Header */} +
+ + + Fork Point + +
+ + {/* Fork reason */} +

{fork.fork_reason}

+ + {/* Options */} +
+ {fork.options.map((option) => { + const isSelected = option.branch_id === selectedBranchId + return ( + + ) + })} +
+
+ ) +}