I am trying to transform circle but it throws error. I don't understand what is the problem i have already worked with transformations on Konva.Rect
and there's no such error. Attaching transformer to Konva.Circle
works properly, but when mouse is over one of transformer anchors it throws error. Here's how i'm attaching transformer to Konva.Circle
:
this.setState({ attachedToId: id }, () => transformer.attachTo(clickedNode));
My Konva.Circle
component to which i'm trying to attach transformer:
<Circle
id={id}
ref={this.circleRef}
x={x * linesWidth}
y={y * linesHeight}
radius={radius * linesHeight}
stroke={color}
onMouseUp={this.mouseUp}
/>
Transformer attaching is happening when this.mouseUp
is called