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

Add "view" tab to main navigation #2420

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

BrandonXLF
Copy link

@BrandonXLF BrandonXLF commented Nov 1, 2019

This is one of my two solutions (the second one being pull request #2421) to the problem of the UI not presenting a clear way to return to the "view" page. I finally realized you can just click the logo, but this isn't very clear and I've seen several people online face the same issue. This solution works by adding a "View" tab to the main navigation menu. Here's an example of it working: viewtab.

Added a "View" tab to the primary nav. Uses layouts.view for link name.
Added "layouts.view" for the primary nav "view" tab.
Add support for JavaScript to update the current class of #view_tab
Added the function to remove the current class from #view_tab to OSM.Index (originally in OSM.Browse)
@BrandonXLF BrandonXLF marked this pull request as ready for review November 1, 2019 04:11
Added missing semicolon at line 328
@HolgerJeromin
Copy link
Contributor

On small screens I dont think we have enough space for another tab.

@BrandonXLF
Copy link
Author

On small screens I dont think we have enough space for another tab.

The website will auto-resize (the primary navigation will collapse). With the change, this seems to happen for screens below 715px in width with the change. Currently, this happens at 645px (for me at least). It's a difference for sure, but I don't think there are many devices that would be impacted (according to chrome devtools iPads should be fine).

@tomhughes
Copy link
Member

I've never really understood why people have such a problem with this - clicking on the site logo to return the home page has been standard web site design for like twenty years now.

Our position has always been that we're so short of screen real estate that we don't want to waste any but I guess we can consider this.

@mmd-osm
Copy link
Collaborator

mmd-osm commented Nov 1, 2019

Related issue: #737

@gravitystorm
Copy link
Collaborator

I'm happy with the proposed tab from a UX perspective. But from a technical PoV, I don't know enough about how the javascript stuff works to review it confidently.

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.

5 participants