(node: string)
| 1083 | ? { source: 'top' as const, target: 'bottom' as const } |
| 1084 | : { source: 'top' as const, target: 'top' as const }; |
| 1085 | const bySide = (node: string): { top: SidePort[]; bottom: SidePort[] } => { |
| 1086 | const found = sidePorts.get(node) ?? { top: [], bottom: [] }; |
| 1087 | sidePorts.set(node, found); |
| 1088 | return found; |
| 1089 | }; |
| 1090 | bySide(link.source)[sides.source].push({ id, type: 'source', other: centreOf(link.target) }); |
| 1091 | bySide(link.target)[sides.target].push({ id, type: 'target', other: centreOf(link.source) }); |
| 1092 | } |
no test coverage detected