Skip to content

Commit cc4dfc2

Browse files
authored
Fix _rotatePitchHandler typo (#6208)
* Fixed typo in navigation_control.ts file * Add changes to changelog file * Update changelog
1 parent b1a2d89 commit cc4dfc2

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
## main
2+
- Fix typo `_rotatePitchHandler` in the `navigation_control.ts` file ([#6207](https://github.com/maplibre/maplibre-gl-js/issues/6207))
23

34
### ✨ Features and improvements
45
- _...Add new stuff here..._

src/ui/control/navigation_control.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ class MouseRotateWrapper {
177177
map: Map;
178178
_clickTolerance: number;
179179
element: HTMLElement;
180-
_rotatePitchHanlder: DragMoveHandler<DragRotateResult, MouseEvent | TouchEvent>;
180+
_rotatePitchHandler: DragMoveHandler<DragRotateResult, MouseEvent | TouchEvent>;
181181
_startPos: Point;
182182
_lastPos: Point;
183183

@@ -186,7 +186,7 @@ class MouseRotateWrapper {
186186
this.element = element;
187187

188188
const moveStateManager = new MouseOrTouchMoveStateManager();
189-
this._rotatePitchHanlder = new DragHandler<DragRotateResult, MouseEvent | TouchEvent>({
189+
this._rotatePitchHandler = new DragHandler<DragRotateResult, MouseEvent | TouchEvent>({
190190
clickTolerance: 3,
191191
move: (lastPoint: Point, currentPoint: Point) => {
192192
const rect = element.getBoundingClientRect();
@@ -207,13 +207,13 @@ class MouseRotateWrapper {
207207
}
208208

209209
startMove(e: MouseEvent | TouchEvent, point: Point) {
210-
this._rotatePitchHanlder.dragStart(e, point);
210+
this._rotatePitchHandler.dragStart(e, point);
211211
DOM.disableDrag();
212212
}
213213

214214
move(e: MouseEvent | TouchEvent, point: Point) {
215215
const map = this.map;
216-
const {bearingDelta, pitchDelta} = this._rotatePitchHanlder.dragMove(e, point) || {};
216+
const {bearingDelta, pitchDelta} = this._rotatePitchHandler.dragMove(e, point) || {};
217217
if (bearingDelta) map.setBearing(map.getBearing() + bearingDelta);
218218
if (pitchDelta) map.setPitch(map.getPitch() + pitchDelta);
219219
}
@@ -247,7 +247,7 @@ class MouseRotateWrapper {
247247
};
248248

249249
mouseup = (e: MouseEvent) => {
250-
this._rotatePitchHanlder.dragEnd(e);
250+
this._rotatePitchHandler.dragEnd(e);
251251
this.offTemp();
252252
};
253253

@@ -284,7 +284,7 @@ class MouseRotateWrapper {
284284
};
285285

286286
reset = () => {
287-
this._rotatePitchHanlder.reset();
287+
this._rotatePitchHandler.reset();
288288
delete this._startPos;
289289
delete this._lastPos;
290290
this.offTemp();

0 commit comments

Comments
 (0)