Skip to content

Commit

Permalink
chore: remove postsync in captionBar and let map.propagate do its job
Browse files Browse the repository at this point in the history
  • Loading branch information
yohanboniface committed Oct 21, 2024
1 parent e100809 commit 911c071
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions umap/static/umap/js/umap.js
Original file line number Diff line number Diff line change
Expand Up @@ -1594,7 +1594,7 @@ U.Map = L.Map.extend({
'umap-caption-bar',
this._controlContainer
)
const name = L.DomUtil.create('h3', '', container)
const name = L.DomUtil.create('h3', 'map-name', container)
L.DomEvent.disableClickPropagation(container)
this.addAuthorLink('span', container)
if (this.getOption('captionMenus')) {
Expand All @@ -1620,11 +1620,6 @@ U.Map = L.Map.extend({
)
}
}
const setName = function () {
name.textContent = this.getDisplayName()
}
L.bind(setName, this)()
this.on('postsync', L.bind(setName, this))
this.onceDatalayersLoaded(function () {
this.slideshow.renderToolbox(container)
})
Expand Down

0 comments on commit 911c071

Please sign in to comment.