New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calc zoom - LatLng helper issue (?) #9009
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I try to click + or - in calc status bar to zoom in / out:
bundle.js:10734 Uncaught TypeError: Cannot read properties of undefined (reading 'x')
at Bounds.contains (bundle.js:10734:12)
at NewClass.setDesktopCalcViewOnZoom (bundle.js:11039:58)
at NewClass.setZoom (bundle.js:11069:43)
at NewClass.zoomOut (bundle.js:11085:22)
at actionsMap.zoomout (bundle.js:8943:22)
at Dispatcher.dispatch (bundle.js:9065:8)
at HTMLDivElement. (bundle.js:27135:80)
at HTMLDivElement.dispatch (bundle.js:978:35)
at elemData.handle (bundle.js:940:91)
Exception
:
TypeError: Cannot read properties of undefined (reading 'x') at Bounds.contains
this: Bounds
bounds:
max: undefined
min: undefined
obj: {x: 913, y: 42198}
point:
this.getPixelBounds() is cssBounds - which is valid:
Bounds {min: Point, max: Point}
max: Point {x: 1743, y: 357687}
min: Point {x: 607, y: 356617}
[[Prototype]]: Object
Bounds.prototype.contains = function(obj) {
var min, max;
var bounds;
var point;
if (Array.isArray(obj) || obj instanceof L.Point || obj instanceof cool.SimplePoint) {
point = toPoint(obj)
} else {
bounds = Bounds.toBounds(obj)
}
if (bounds) {
min = bounds.min;
max = bounds.max
} else {
min = max = point
}
return min.x >= this.min.x && max.x <= this.max.x && min.y >= this.min.y && max.y <= this.max.y
}
Array.isArray(obj) || obj instanceof L.Point || obj instanceof cool.SimplePoint
false
The text was updated successfully, but these errors were encountered: