Skip to content

Commit

Permalink
Revert "feat: auto-zoom in ~72000 but don't zoom out"
Browse files Browse the repository at this point in the history
This reverts commit dd0131e.

The client decided that they didn't want it.
  • Loading branch information
stdavis committed Mar 4, 2024
1 parent 6d9d0b8 commit 28f15e4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
10 changes: 3 additions & 7 deletions src/Video.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -97,17 +97,13 @@ const Video = ({ GPS_Track_ID, Date_Time, URL, pointsLayer, mapView, testWarning
setAngleOfSegment(90 - (Math.atan2(yDiff, xDiff) * 180) / Math.PI);
}

if (mapView.scale > config.autoZoomScaleThreshold) {
mapView.goTo({ target: position, scale: config.autoZoomScaleThreshold });
} else {
mapView.goTo(position);
}
mapView.goTo(position);
graphic.current.geometry = position;
}
}, 1000);
}
},
[mapView, updateVideoAngle],
[mapView, updateVideoAngle]
);

React.useEffect(() => {
Expand Down Expand Up @@ -163,7 +159,7 @@ const Video = ({ GPS_Track_ID, Date_Time, URL, pointsLayer, mapView, testWarning

if (results.exceededTransferLimit) {
return results.features.concat(
await queryForPoints(start + results.features.length + 1, results.features.length),
await queryForPoints(start + results.features.length + 1, results.features.length)
);
}

Expand Down
1 change: 0 additions & 1 deletion src/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ const deployConfigs = {
const defaultConfigs = {
webMapId: import.meta.env.VITE_APP_MAP_ID,
maxMobileWidth: 600,
autoZoomScaleThreshold: 72223.82209,
};

// DEV is set when running `npm start`
Expand Down

0 comments on commit 28f15e4

Please sign in to comment.