({ nodes, onSelect, onNavigate }: Pick<RepositoryMapProps, 'onSelect' | 'onNavigate'> & { nodes: GraphNode[] })
| 19 | } |
| 20 | |
| 21 | function Nodes({ nodes, onSelect, onNavigate }: Pick<RepositoryMapProps, 'onSelect' | 'onNavigate'> & { nodes: GraphNode[] }) { |
| 22 | const [limit, setLimit] = useState(24); |
| 23 | return <><ul className="repo-map-nodes">{nodes.slice(0, limit).map(node => <li key={node.id}> |
| 24 | <button onClick={() => onSelect ? onSelect(node) : onNavigate(node.file_path!, node.start_line, node.name)}> |
| 25 | {/* Round 4 (N1): a Branch node reads "django-demo · detached HEAD", not "DETACHED". */} |
| 26 | <strong>{graphNodeName(node)}</strong><span>{node.label} · {node.file_path}{node.start_line ? `:${node.start_line}` : ''}</span> |
| 27 | </button> |
| 28 | </li>)}</ul>{nodes.length > limit && <button className="atlas-arch-action" onClick={() => setLimit(limit + 24)}>More symbols ({limit} of {nodes.length})</button>}</>; |
| 29 | } |
| 30 | |
| 31 | export function RelationshipEvidence({ edges, onSelect, onNavigate }: Pick<RepositoryMapProps, 'onSelect' | 'onNavigate'> & { edges: MapEvidence[] }) { |
| 32 | const [limit, setLimit] = useState(12); |
nothing calls this directly
no test coverage detected