|
|
@ -219,13 +219,17 @@ export const ShapesSwitcher = ({
|
|
|
|
penMode: true,
|
|
|
|
penMode: true,
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
const nextActiveTool = { ...activeTool, type: activeToolType };
|
|
|
|
setAppState({
|
|
|
|
setAppState({
|
|
|
|
activeTool: { ...activeTool, type: activeToolType },
|
|
|
|
activeTool: nextActiveTool,
|
|
|
|
multiElement: null,
|
|
|
|
multiElement: null,
|
|
|
|
selectedElementIds: {},
|
|
|
|
selectedElementIds: {},
|
|
|
|
});
|
|
|
|
});
|
|
|
|
setCursorForShape(canvas, { ...appState, activeTool });
|
|
|
|
setCursorForShape(canvas, {
|
|
|
|
if (activeTool.type === "image") {
|
|
|
|
...appState,
|
|
|
|
|
|
|
|
activeTool: nextActiveTool,
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
if (activeToolType === "image") {
|
|
|
|
onImageAction({ pointerType });
|
|
|
|
onImageAction({ pointerType });
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|