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

siteNav: Move the content to the navbar when the siteNav is hidden #591

Closed
yamgent opened this issue Jan 17, 2019 · 4 comments · Fixed by #1445
Closed

siteNav: Move the content to the navbar when the siteNav is hidden #591

yamgent opened this issue Jan 17, 2019 · 4 comments · Fixed by #1445

Comments

@yamgent
Copy link
Member

yamgent commented Jan 17, 2019

Tell us about your environment

  • MarkBind Version: 1.16.1

What did you do? Please include the actual source code causing the issue.

  1. Create a website with a navbar and a siteNav.
  2. Serve the website on a very small screen (mobile screen size), so that the siteNav gets hidden as part of the responsive design.

What did you expect to happen?

The content of the siteNav should be relocated to the navbar, so that the reader can still access the content of the siteNav.

What actually happened? Please include the actual, raw output.

Readers of the website cannot use the siteNav at all.

This problem is inspired by #518 (review).

@Chng-Zhi-Xuan
Copy link
Contributor

Chng-Zhi-Xuan commented Feb 22, 2019

Alternative solutions

  • Reduce (max-width: 575.98px) such that it has proper coverage for mobile devices
    • ➕ Quickest fix
    • ➖ Not the best looking
    • ➖ Have a magic number within site-nav.css
  • Render a floating action button to expand the site navigation once the screen is smaller than (max-width: 575.98px).
    • ➕ Aesthetically pleasing
    • ➕ Can be used for (max-width: 575.98px) responsive break-point instead of the current design
    • ➖ Longer implementation time
    • ➖ Blocks content underneath it

@damithc
Copy link
Contributor

damithc commented Feb 22, 2019

I prefer the 2nd alternative. If we can't implement it by V2, we can go for alternative 1.


  • ➖ Blocks content underneath it

Not a big problem if the button is small and slightly transparent.

  • Render a floating action button to expand the site navigation once the screen is smaller than (max-width: 575.98px).

In fact, we can make this an option even when the screen is big enough to show siteNav. That is, the reader can collapse the siteNav if they want. When the screen is too small, it will collapse to a button automatically.

@acjh
Copy link
Contributor

acjh commented Feb 22, 2019

The floating action button is bad UX design: https://usabilla.com/blog/floating-action-button-bad-ux-design/

@damithc
Copy link
Contributor

damithc commented Feb 22, 2019

What we are aiming for is something like the following, which is slighly different from what the article is talking about:
image
Of course collapsing the button to the topNav is also an option but we cannot be sure that the page has a topNav.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Big Picture
Completed
Development

Successfully merging a pull request may close this issue.

5 participants