Do not modify tooltipAnchor inplace, as it's shared by all markers
fix #1223
This commit is contained in:
parent
299e9e0821
commit
2b1b80ae23
1 changed files with 1 additions and 1 deletions
|
@ -581,7 +581,7 @@ L.U.Marker = L.Marker.extend({
|
||||||
},
|
},
|
||||||
|
|
||||||
_getTooltipAnchor: function () {
|
_getTooltipAnchor: function () {
|
||||||
const anchor = this.options.icon.options.tooltipAnchor,
|
const anchor = this.options.icon.options.tooltipAnchor.clone(),
|
||||||
direction = this.getOption('labelDirection')
|
direction = this.getOption('labelDirection')
|
||||||
if (direction === 'left') {
|
if (direction === 'left') {
|
||||||
anchor.x *= -1
|
anchor.x *= -1
|
||||||
|
|
Loading…
Reference in a new issue