Shared Maps not clickable

Adam's Avatar


25 Jun, 2020 11:21 PM

Open up the map and load any Shared Maps onto the screen. It displays the Shared Map lines in white. Try to click on a Shared Map line. Previously you used to be able to click on the line and see the map it came from. Now clicking on the Shared Map line doesn't do anything. Now it seems to work like 10% of the time, if you have a fresh page loaded, maybe.

  1. Support Staff 1 Posted by Julie on 26 Jun, 2020 02:03 PM

    Julie's Avatar

    Hi Adam,

    We can't reproduce this at all. Can you try logging out, clearing your cache, and logging back in? Can you give me some more info?

    Are you logged in?
    What browser are you using?
    Do you have other layers turned on?
    Do you have your own items on the map?


  2. 2 Posted by Adam Rhoda on 26 Jun, 2020 03:06 PM

    Adam Rhoda's Avatar

    Hey Julie. Sure. I am using Google Chrome Version 83.0.4103.116 (Official
    Build) (64-bit). I've also tried in Chrome's Incognito mode, which should
    be a clear browser cache. I've also tried logging out, clearing the browser
    cache with ctrl-shift-del, and logging back in again, but still get the
    same problem. I also have the same problem in Microsoft Edge. Same problem
    happens whether I am logged in or not logged in. I have the same problem
    across two computers.

    The layers I have turned on are MapBuilder Topo base layer and Shared
    CalTopo Maps, but the base layer doesn't seem to matter much, I have the
    same problem with MapBuilder Hybrid or Scanned 7.5 for example. Here is an
    example URL with an unclickable shared map,-121.21053&z=15&b=mbh&a=shared . I
    have nothing on the map - no lines, no features, just trying to look at the
    shared maps.

  3. Support Staff 3 Posted by Julie on 26 Jun, 2020 03:15 PM

    Julie's Avatar

    Hi Adam,

    Thanks for all of that. I still can't duplicate the problem at all. The map you sent works fine for me, in Chrome and Edge and Firefox and Safari, logged in or not. I can click on any of the shared map objects and get the link to that map. I'll ask around here some more, but for now, I'm stumped!


  4. Support Staff 4 Posted by Julie on 26 Jun, 2020 05:12 PM

    Julie's Avatar

    Hi Adam,

    Talking with some other people here... do you have a firewall? Are you using a VPN? Popup blocker?

    What happens if you turn on other overlays that work the same way - like MTB Project and click on the trails? Or MVUM? Do those both work?

  5. 5 Posted by Adam on 26 Jun, 2020 05:40 PM

    Adam's Avatar

    The MTB Project overlay seems to work fine, as do the Shared Map Sheets (attached images). I don't know anything about a firewall or VPN or popup blocker, so I suppose I am not using those.

    Is there any way I can debug it, for example with browser network logs or anything?

    It seems to sometimes work but then stops working. I just reloaded the web page and could click on some Shared Maps, but then I move the map away and cannot click on them again.

  6. Support Staff 6 Posted by Julie on 26 Jun, 2020 05:57 PM

    Julie's Avatar

    Yes, debugging is our next step. If you could please open up the console and then try to replicate the issue, then send us a screen shot of the log, especially if you see any errors, that would be great. On Chrome: View --> Developer --> Java Script Console

    Send me screen shots of what shows up in the console when you can't get the feature to work.

  7. 7 Posted by Adam on 26 Jun, 2020 07:14 PM

    Adam's Avatar

    Sorry, I'm afraid I don't get any errors in the console. I get a couple "warnings" about how long a few things take to load but that's it. Me clicking on the map only gives the `[Violation] 'click' handler took 155ms`, the rest was already there.

  8. Support Staff 8 Posted by Ben Lantow on 27 Jun, 2020 12:18 AM

    Ben Lantow's Avatar

    This seems to be isolated to your machine(s), the MTB project layer uses a very similar function to open a popup. We're putting our heads together to see what could be going on and we'll get back to you.


  9. Support Staff 9 Posted by matt on 27 Jun, 2020 03:24 AM

    matt's Avatar

    Adam -

    Thanks for working with us on this. Those violation warnings look really strange to me, particularly the part about them being tied to a touchstart event.

    1. What hardware are you using? Does it have a touchscreen?

    2. Are you actually clicking with your mouse, or pressing on a touchscreen?

    • Matt
  10. 10 Posted by Adam on 27 Jun, 2020 04:44 AM

    Adam's Avatar

    Thanks for working with me as well! As far as your questions, no I am not using a touch screen, I am using a windows computer and clicking with the mouse.

    I was able to debug a bit and think I found part of the issue. It looks like the JavaScript function is called twice. This function seems to be what adds the little popup, or what can remove it, depending on the context. It's called twice and the first time it is adding the little popup but the second time it is removing the popup. I've attached some screenshots showing this behavior.

    It looks like the first time through, is being called from function with some valid parameters, and the second time it's being called from with a null parameter.

    This second loop through is when the little popup gets removed. I don't understand why it's being called twice though. Maybe you guys know more.

  11. 11 Posted by Fabien on 27 Jun, 2020 02:42 PM

    Fabien's Avatar

    I have the exact same problem.
    I am running on a Mac. I tried it with Chrome and Safari. Clicking on a Share map doesn't do anything. Also some map have a yellow overlay when I mouse over it, and some not...
    Sometimes the popup appears and just disappear after.
    I don't know if it's related to the location, but here's an example where it's not working:,-120.96683&z=16&b=mbt&a=shared

  12. Support Staff 12 Posted by matt on 27 Jun, 2020 04:53 PM

    matt's Avatar

    Fabien -

    While you might be seeing the same issue as well with respect to the popup disappearing, there's also definitely something weird with the data in that spot. I'll have to dig into it.

    Adam -

    Thanks for the detailed screenshots. I was all excited to go crack this thing, but unfortunately, breaking on the initial info() call is what's causing the map click event and the dialog close, at least for me. If I don't break on the first info() call, the second one never gets generated - I assume something timing-dependent going on around click handling. Can you tell me specifically how you setup your breakpoints, so that I can verify that's what's going in your case as well?

    The shared maps layer shares most of its code with the mtbproject and map sheets layers. Thinking about this, I keep circling back to the warning messages on the console window in your first screenshot. Beyond the chrome violation messages, the content/detection.js and symantec messages are not ours. Do you have any chrome extensions installed? I'm assuming not since you said you also tried incognito mode (which disables my extensions) and edge, but want to check.

    I probably won't get to this until Monday, but as a next step I'd probably want to setup a test server with extra logging to the js console.

  13. Support Staff 13 Posted by matt on 29 Jun, 2020 08:14 PM

    matt's Avatar

    Adam -

    Can you visit and click on the mapbuilder features layer with your javascript console open? Curious to see what the log messages are, depending on what they say I might have to add some more logging and then have you check again.

    • Matt
  14. 14 Posted by Adam on 29 Jun, 2020 08:26 PM

    Adam's Avatar

    Sure. I see you've added some additional logs to the console. I do not see any of the Shared Maps in the beta version, but I do see some console logs (see screenshot). Every time I click it puts these same two messages in the console.

  15. Support Staff 15 Posted by matt on 29 Jun, 2020 10:13 PM

    matt's Avatar
  16. 16 Posted by Adam on 29 Jun, 2020 10:50 PM

    Adam's Avatar

    Ok at least in the beta I am able to click on the Shared Map there and see the popup. Here is the console after I do so

  17. 17 Posted by Adam on 29 Jun, 2020 10:55 PM

    Adam's Avatar

    Ok seems like in the beta version I am able to click and view the popups for the Shared Maps. Did you change any of the code or only add the console logging?

    Attached is a screenshot of the console log after clicking on the shared map.

  18. Support Staff 18 Posted by matt on 29 Jun, 2020 11:53 PM

    matt's Avatar

    Just added the logging. So it's probably due to the size of the data in the shared maps layer, and not something else about that layer specifically.

    Based on that, I have an idea of what might be causing it, let me try something out and get back to you.

  19. 19 Posted by Adam on 30 Jun, 2020 04:49 AM

    Adam's Avatar

    Great, let me know if I can help in any way.

  20. Support Staff 20 Posted by matt on 02 Jul, 2020 04:59 PM

    matt's Avatar

    Check out again. When you click on a line, leaflet generates a click even on both that line and the underlying map. We were checking the time between click events to figure out of a click on the map was really intended for a line instead. We were marking the time before handling the line click event - so if your browser took too long to construct the popup, the click on the line would appear as a click on the map as well. Changed to marking the time after we handle the line click event.

    Really hoping that was the issue here given the other timing warnings your browser was showing. I'm sure there's a cleaner way to stop bubbling or check the event target, but this code had been in place for a long time without issues.

  21. 21 Posted by Adam on 02 Jul, 2020 05:48 PM

    Adam's Avatar

    Thanks Matt, yes it does in fact solve the problem. I am able to click on the Shared Maps and see the popup and view the maps now.

    With respect to time - it does seem that it takes a little bit of time to generate the popups - maybe 100-200ms, so maybe it previously decided that this was too much time and closed the popup. I know that these lines and popups have changed at some point in the last 6-8 months, they used to be different colors and I don't think they used to ever give ALL of the shared maps under where you clicked, just one. Maybe some of these changes made it slower to the point where it was now hitting that time value on some computers and some browsers.

    In any case, the issue seems to be resolved, so thank you very much.

  22. Julie closed this discussion on 02 Jul, 2020 09:21 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac