Mapping Updates 2022

Travel Forums System Talk Mapping Updates 2022

Page
  • 1
  • 2
Last Post
1. Posted by Peter (Admin 7110 posts) 21w 1 Star this if you like it!

Just finished off some updates I've been working on for the mapping tool over the past few months and wanted to let you all know about them!

Add Stops By Coordinate

Some users have missed the ability to just type in latitude / longitude pairs to add stops. It is particularly useful when your stop is in the middle of nowhere or for some reason isn't suggested as a location. To do this, just enter the latitude and longitude separated by a comma.

Eg. entering Rome would be "41.9, 12.5"

Map Styles

I've added some fun new options for the styles. These do require being a supporter.

  • Set the line thickness (from very thin to very thick)
  • Turn off lines for certain transport modes. Or turn them all off, so you just get markers

* Future legs of trips will now have dashed lines by default. You can set it back to solid if you prefer in the settings. Unfortunately I've had to revert this feature for now

  • Map styles are now saved and will apply to the map you are viewing on Travellerspoint (previously it would only apply to embedded maps).

Exporting

You can now export the map as a KML file again. Also supporter only

I'm sure there will be a bug or two as a lot of code was updated to get this working. If you find one, please let me know and I'll try to fix them as soon as possible.

Otherwise, let me know what you think :)

[ Edit: Had to remove the dashed lines feature ]

2. Posted by Sander (Moderator 5852 posts) 21w Star this if you like it!

Niiiiice!

Some (possible) bugs, from most noticeable to probably nothing:
* Trying to set a trip segment to "Drive", the green button doesn't have any effect, and I get this JS error:
TypeError: invalid assignment to const 'a'
* Old links to maps don't work for logged out visitors! https://www.travellerspoint.com/map/#/trip/52643 and https://www.travellerspoint.com/map/#/user/27181 both redirect to /travel-maps.cfm - this might be somewhat intended, given the new /external/ link format - but I don't think so; in any case, profiles still link to the map using the /map/#/user/27181 format.
* My Norway and Berlin 2007 trips lack all route lines? https://www.travellerspoint.com/map/#/trip/52643 and https://www.travellerspoint.com/map/#/trip/172119 - all other trips work fine, though.
JS error: Error: The layer 'highlightedroutelayer' does not exist in the map's style and cannot be styled.
* /external/ links don't zoom in to trips, e.g. https://www.travellerspoint.com/external/#/show/27181/52643 - they do zoom in to stops, e.g. https://www.travellerspoint.com/external/#/show/27181/52643/227720
* Trip sorting in the left bar seems now to be by order of creation, rather than chronological?
* Zooming in swiftly with the mouse wheel from world view to where I'm intending to see just new zealand, I have had a couple of times that the map ends up completely off - usually somewhere between Africa and Australia. It's definitely related to the speed of zooming - some intermediate step which isn't done loading before the next zoom level gets triggered.
The only possibly related (through probably not) JS error in my console is:
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://events.mapbox.com/events/v2?access_token=<snip>. (Reason: CORS request did not succeed). Status code: (null)
* I really like the "extra-thin" line style - but think it needs a little bit of compensation for lighter colors of trip lines (at least one light background maps). See my Germany 2006 trip - https://www.travellerspoint.com/map/#/trip/74103 - and notice how barely visible the light blue lines are. The dark red lines to W├╝rzburg don't have this problem at all. (Probably just user responsibility to pick good colors depending on map and line style? But would still be nice if you can automatially detect and compensate.)
* I can't see any difference between the "streets" and "outdoors" map styles. Might be something subtle I just don't notice on first glance, with it always having been this way; or might be something internally going wrong with the assignment?

[ Edit: Edited on 8 Jul 2022, 07:20 GMT by Sander ]

3. Posted by Peter (Admin 7110 posts) 21w Star this if you like it!

Thanks Sander, I'll investigate these..

One I can answer straight away though - the Outdoors one is mostly the same as Streets. It's only in some national parks etc that it differs by showing elevation data. It is a pretty subtle difference.

4. Posted by Peter (Admin 7110 posts) 21w Star this if you like it!

Fixed a few of those issues.

- selecting a route
- links for non-logged in users
- ordering of trips
- missing trip lines should now be showing
- zooming in on trips was related to that (no triplines = not sure where the bounds of the trip are), so that one is fixed as well.

[ Edit: fixed a couple more ]

5. Posted by Sander (Moderator 5852 posts) 21w Star this if you like it!

Thanks for those fixes; looks good now!

One more small issue:
* If I as a logged in user open a URL to one of my own trips, e.g. https://www.travellerspoint.com/map/#/trip/125590 (for example by reloading, or opening the link in a new tab), I don't get an overview of stops for the trip in the left bar, but instead I get the green "Add a Stop" box. Closing it doesn't show the stop list either.

...also, did you change something related to the lazyloading code on the image gallery page? No images show for me at all on https://www.travellerspoint.com/photos/gallery/orderByID/ now (no JS errors, either, though I do see you're trying to load recaptcha, which I block (alongside all 3rd party scripts other than daa.ms). If you're doing recaptcha to prevent bots from wasting bandwidth on images - maybe consider bypassing that for full members and above? Or... what is this fuseplatform for?)

[ Edit: Edited on 9 Jul 2022, 07:55 GMT by Sander ]

6. Posted by Sander (Moderator 5852 posts) 21w Star this if you like it!

huh, the lazy loading in the photo gallery works fine now?

7. Posted by Peter (Admin 7110 posts) 21w Star this if you like it!

I fixed it after your report :)

Fuseplatform is the ad network I use. You shouldn't be seeing that if you're logged in I think.

[ Edit: Edited on 9 Jul 2022, 13:02 GMT by Peter ]

8. Posted by Sander (Moderator 5852 posts) 21w Star this if you like it!

Ah, that explains it. :)

The fuseplatform script is still being loaded for me (well, cdn.fuseplatform.net/publift/tags/2/1051/fuse.js is linked in the head and attempting to load, but then blocked). I'll trust that it wouldn't show ads, but it'd be nicer if the entire script src wasn't present for logged in users. (No worries about it, though - that's just me nitpicking.)

9. Posted by nzhamsta (Respected Member 650 posts) 21w Star this if you like it!

Hi,
Are you considering bringing back the ability to move lines? This was a good feature as you could tidy up where the lines were shown. At the moment the lines are shown in what appears to be random places. See the example below. If the flight lines could be moved this would improve this map considerably.
Thanks,
Glynn

e46958e0-00c5-11ed-8154-e505f59e819f.PNG

10. Posted by Peter (Admin 7110 posts) 21w Star this if you like it!

Quoting nzhamsta

Are you considering bringing back the ability to move lines?

I'm open to the idea. Although I'm more interested in allowing drawing custom routes for the purposes of illustrating boat trips. That's something people often have an issue with, so it would be nice to have a solution.