summaryrefslogtreecommitdiff
path: root/src/components/app/map
diff options
context:
space:
mode:
authorGeorgios Andreadis <g.andreadis@student.tudelft.nl>2017-09-26 16:57:47 +0200
committerGeorgios Andreadis <g.andreadis@student.tudelft.nl>2017-09-26 16:57:47 +0200
commit9ed6d7932876cb7654ad154d028ba41bef12a7b5 (patch)
tree9584cdfd08878e4167bc475e70d0c4a18fb233ed /src/components/app/map
parent8b8b4d0543ab11fbc11e4bcef27e4aecf2736b85 (diff)
Fix line overflow
Diffstat (limited to 'src/components/app/map')
-rw-r--r--src/components/app/map/MapStageComponent.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/components/app/map/MapStageComponent.js b/src/components/app/map/MapStageComponent.js
index 271ae64f..b8e3c3f7 100644
--- a/src/components/app/map/MapStageComponent.js
+++ b/src/components/app/map/MapStageComponent.js
@@ -58,7 +58,9 @@ class MapStageComponent extends React.Component {
x: this.state.mouseX / this.props.mapScale - this.props.mapPosition.x / this.props.mapScale,
y: this.state.mouseY / this.props.mapScale - this.props.mapPosition.y / this.props.mapScale,
};
- const newScale = e.deltaY < 0 ? this.props.mapScale * MAP_SCALE_PER_EVENT : this.props.mapScale / MAP_SCALE_PER_EVENT;
+ const newScale = e.deltaY < 0 ?
+ this.props.mapScale * MAP_SCALE_PER_EVENT :
+ this.props.mapScale / MAP_SCALE_PER_EVENT;
const boundedScale = Math.min(Math.max(MAP_MIN_SCALE, newScale), MAP_MAX_SCALE);
const newX = -(mousePointsTo.x - this.state.mouseX / boundedScale) * boundedScale;