diff --git a/packages/g6/src/stdlib/plugin/annotation/util.ts b/packages/g6/src/stdlib/plugin/annotation/util.ts index 573c1cb6d54..d45be1a325b 100644 --- a/packages/g6/src/stdlib/plugin/annotation/util.ts +++ b/packages/g6/src/stdlib/plugin/annotation/util.ts @@ -5,7 +5,7 @@ export const getPathItem2Card = (item, cardBBox, graph, annotationCanvas) => { let itemLinkPoints; const itemType = item.getType(); if (itemType === 'edge') { - itemLinkPoints = [item.getKeyShape().getPoint(0.5)]; + itemLinkPoints = [item.shapeMap.keyShape.getPoint(0.5)] } else { const bbox = item.shapeMap.keyShape.getBBox(); const minX = bbox.left,