clean: remove zoom in and out from contextmenu (#2195)

Let's make it smaller (unless proven otherwise!).
This commit is contained in:
Yohan Boniface 2024-10-04 17:43:23 +02:00 committed by GitHub
commit de93446af2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1686,20 +1686,7 @@ U.Map = L.Map.extend({
getContextMenuItems: function (event) { getContextMenuItems: function (event) {
const items = [] const items = []
if (this._zoom !== this.getMaxZoom()) {
items.push({
label: L._('Zoom in'),
action: () => this.zoomIn(),
})
}
if (this._zoom !== this.getMinZoom()) {
items.push({
label: L._('Zoom out'),
action: () => this.zoomOut(),
})
}
if (this.hasEditMode()) { if (this.hasEditMode()) {
items.push('-')
if (this.editEnabled) { if (this.editEnabled) {
if (!this.isDirty) { if (!this.isDirty) {
items.push({ items.push({