mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-11-17 03:04:26 +01:00
feat: image cropping (#8613)
Co-authored-by: dwelle <5153846+dwelle@users.noreply.github.com>
This commit is contained in:
@@ -28,3 +28,6 @@ export const average = (a: number, b: number) => (a + b) / 2;
|
||||
export const isFiniteNumber = (value: any): value is number => {
|
||||
return typeof value === "number" && Number.isFinite(value);
|
||||
};
|
||||
|
||||
export const isCloseTo = (a: number, b: number, precision = PRECISION) =>
|
||||
Math.abs(a - b) < precision;
|
||||
|
||||
Reference in New Issue
Block a user