Change measure tool to use full snapping to grid center and add exact euclidean measurements

This commit is contained in:
Mitchell McCaffrey
2021-06-19 09:36:00 +10:00
parent bfc9c4fba3
commit 1f2c70a612
3 changed files with 17 additions and 10 deletions

View File

@@ -44,7 +44,10 @@ function MapMeasure({ map, active }) {
const gridScale = parseGridScale(active && grid.measurement.scale);
const snapPositionToGrid = useGridSnapping();
const snapPositionToGrid = useGridSnapping(
grid.measurement.type === "euclidean" ? 0 : 1,
false
);
useEffect(() => {
if (!active) {