Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Polish color coding + analysis tab visuals and fix a couple of related bugs #313

Merged
merged 4 commits into from
Jun 17, 2020
Merged

Polish color coding + analysis tab visuals and fix a couple of related bugs #313

merged 4 commits into from
Jun 17, 2020

Conversation

rkflx
Copy link
Contributor

@rkflx rkflx commented Jun 15, 2020

  • Improve incline coding visuals and use different colors for going uphill
  • Make hotline contrast more pleasant
  • Improve analysis tab CSS
  • Show analysis table highlight above quality coding layer

(See individual commit messages for a detailed discussion of the changes.)

Before:
before

After:
after

rkflx added 4 commits May 22, 2020 18:00
Currently it is a bit difficult to guess the slope of the route for
planning purposes, since even for routes in very hilly terrain the
colors hardly change. Only extremely steep hills are indicated,
and there is no visual difference between going uphill or downhill.

By cutting off earlier, more of the route will show meaningful
differences in color. Note that BRouter's gradients are already
averaged compared to the maximum gradients shown on road signs, so 15%
should be a good compromise (anything steeper is difficult to ride on
for longer periods anyway, and rightly deserves to be colored with an
alarming red).

By using different colors for the min and max parameters, uphill and
downhill sections should now be easy to distinguish.

By introducing two more color stops, the gradient becomes much smoother,
with flat sections featuring a distinctive green, where they were drawn
in a muddy dark green before.

Note that this approach had been implemented like this in QLandkarte GT
for several years now, with great success.
Colorful routes can conflict visually with colourful maps, therefore
having an outline to make the route stand out more makes sense.

However, using black results in very high contrast levels, which can
become distracting in itself. By using a dark gray, this should look
much more balanced, while still fulfilling the original purpose.
There are some ways the look of the analysis tab can be polished:
- Properly right-align the length header
  (it had extra margins required for the sorting arrows in the data tab)
- Use the same font size for table header and body (like in the data tab)
- Improve padding of the totals row (to align with the rows above)
- Add missing style for headings, so they look more balanced
  (the CSS was already there, but the wrong class was used in the HTML)
- Fine-tune vertical spacing (to help visual grouping)
- Remove unused and redundant CSS
- Do not show yellow hover effect over table header
When hovering over rows in the analysis tab, highlighted sections for
the route could only be seen on the regular route, but not when any of
the color-coded route visualisations were selected.

Patch based on a similar fix for data table in d33c795.
@nrenner
Copy link
Owner

nrenner commented Jun 16, 2020

Thanks for the detailed comments and separated commits!

Improve incline coding visuals and use different colors for going uphill

Very nice improvement!

Looks good to me overall.

@mjaschen do you want to review 8ca92e2?

@mjaschen
Copy link
Contributor

Yes, of course – I’ll take a look at it in the morning :-)

@rkflx rkflx changed the title Polish route quality visuals and fix a couple of related bugs Polish color coding + analysis tab visuals and fix a couple of related bugs Jun 16, 2020
@mjaschen
Copy link
Contributor

I really like the changes introduced with 8ca92e2 – the tables/headers look much cleaner now, thanks for tidying up @rkflx :-)

@nrenner nrenner merged commit 4ef4365 into nrenner:master Jun 17, 2020
@nrenner
Copy link
Owner

nrenner commented Jun 17, 2020

Thanks for the contribution!

@nrenner nrenner added this to the 0.12.0 milestone Jun 17, 2020
@rkflx rkflx deleted the pr/polish-and-fix-route-quality-visuals branch June 19, 2020 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants