Author Topic: Overlay map color schemes  (Read 72563 times)

0 Members and 3 Guests are viewing this topic.

Offline jtstill

  • Newbie
  • *
  • Posts: 7
  • Last Login:January 28, 2025, 10:50:02 am
Re: Overlay map color schemes
« Reply #90 on: January 21, 2025, 09:17:29 am »
For what it’s worth, it’s possible at the moment for an average user like me to see unhighlighted untraveled sections and keep what I have travelled in view, if I’m willing to dig a little: I just go to Inspect > Sources > updateConnectionColors() and update the opacity variable in that function to “1*highlight” instead of the default “0.3 + 0.55*highlight”, and then it applies the new opacity variable once I toggle the highlight options dropdown. Of course, I’d also love to see a front end way to do this, since I have to reapply those changes every time I reload the page or change the region (and the site still loads ALL segments, even the unhighlighted ones, so I can’t really do something like get the entire USA in view and then change the opacity settings, since it’ll never load. It’d be great to find a way to not even load untraveled segments so I can see the full extent of my personal travels)

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4949
  • Last Login:Yesterday at 02:12:31 pm
Re: Overlay map color schemes
« Reply #91 on: January 21, 2025, 12:31:11 pm »
I have noticed that the blue lines tend to have less contrast between segments that are highlighted and those that aren't than the other colors do, especially when zoomed out.  In fact, If I show my travels on usai to people who aren't roadgeeks, they'll assume that I've clinched the whole system because the contrast is low enough they can't tell the difference.

Yep, I think it's just an issue with TMblue. Maybe one can suggest a better setting?

https://github.com/TravelMapping/Web/blob/master/lib/tmjsfuncs.js#L113

Code: [Select]
colorCodes[0] = { name: "TMblue", unclinched: "rgb(100,100,255)", clinched: "rgb(0,0,220)" };
And https://github.com/TravelMapping/Web/issues/581 is now implemented and on the main site.

For the colors= QS param, you can still specify a pair of CSS colors for clinched and unclinched (even the same one and rely on the opacity difference to indicate clinched vs. unclinched), but also now can specify a single TM predefined color (ones used in systems.csv, now with a "TM" prefix).

QS param for usai in NY with TMblue--> https://travelmapping.net/user/mapview.php?rg=ny&colors=usai:rgb(100,100,255):rgb(0,0,220)