refactor(edges): siplify edge path / label position handling, repair edge labels

This commit is contained in:
moklick
2022-09-27 14:17:02 +02:00
parent aef8b477c2
commit e634e7296a
12 changed files with 182 additions and 213 deletions
@@ -3,8 +3,8 @@ import { BaseEdgeProps } from '../../types';
const BaseEdge = ({
path,
centerX,
centerY,
labelX,
labelY,
label,
labelStyle,
labelShowBg,
@@ -29,8 +29,8 @@ const BaseEdge = ({
{interactionWidth && <path d={path} fill="none" strokeOpacity={0} strokeWidth={interactionWidth} />}
{label ? (
<EdgeText
x={centerX}
y={centerY}
x={labelX}
y={labelY}
label={label}
labelStyle={labelStyle}
labelShowBg={labelShowBg}