1
1
1ss1za2020-08-12 21:17:15
JavaScript
1ss1za, 2020-08-12 21:17:15

How to solve the problem with Yandex map?

The problem is the following, there is a link in the balloon, myMap.behaviors.disable('drag'); is set for the map. When opening the balloon on the phone, the link is immediately followed, but it should just open, without myMap.behaviors.disable('drag') everything works as it should.

And one more thing, the link has

.mapCard__title::after {
    content: "";
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

so that you can click on any part of the balloon, if after is removed, it will work with and without disable('drag')

Answer the question

In order to leave comments, you need to log in

2 answer(s)
1
1ss1za, 2020-08-13
@1ss1za

Problem solved like this
$(".mapCard__title").one("click", false);

T
Timur Kostenko, 2020-08-12
@ktim8168

Hang event.preventDefault()on this link

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question