Bump roughjs and resolve breaking change in roughjs refactoring… (#1463)
* Fix for roughjs refactoring curve-estinmation code into a separate package * Update jest transformIgnorePatterns
This commit is contained in:
@ -4,7 +4,7 @@ import {
|
||||
rotate,
|
||||
isPointInPolygon,
|
||||
} from "../math";
|
||||
import { getPointsOnBezierCurves } from "roughjs/bin/geometry";
|
||||
import { pointsOnBezierCurves } from "points-on-curve";
|
||||
|
||||
import { NonDeletedExcalidrawElement } from "./types";
|
||||
|
||||
@ -266,7 +266,7 @@ const hitTestCurveInside = (
|
||||
}
|
||||
}
|
||||
if (points.length >= 4) {
|
||||
const polygonPoints = getPointsOnBezierCurves(points as any, 50);
|
||||
const polygonPoints = pointsOnBezierCurves(points as any, 10, 5);
|
||||
return isPointInPolygon(polygonPoints, x, y);
|
||||
}
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user