bug fix in line
This commit is contained in:
@@ -376,7 +376,7 @@ function Line({ points }: Readonly<LineProps>) {
|
||||
handlePointClick(points);
|
||||
}}
|
||||
onPointerOver={(e) => {
|
||||
if (!hoveredLine && selectedPoints.length === 0 && e.buttons === 0 && !e.ctrlKey) {
|
||||
if (selectedPoints.length === 0 && e.buttons === 0 && !e.ctrlKey) {
|
||||
setHoveredLine(points);
|
||||
setIsHovered(true)
|
||||
if (toolMode === 'move' && !hoveredPoint) {
|
||||
@@ -385,9 +385,9 @@ function Line({ points }: Readonly<LineProps>) {
|
||||
}
|
||||
}}
|
||||
onPointerOut={() => {
|
||||
if (hoveredLine) {
|
||||
if (hoveredLine && isHovered) {
|
||||
setHoveredLine(null);
|
||||
if(!hoveredPoint){
|
||||
if (!hoveredPoint) {
|
||||
handleCanvasCursors('default');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user