-
Notifications
You must be signed in to change notification settings - Fork 15
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
Redesign header and navigation #702
Conversation
This pull request has conflicts ☹ |
c71a5cd
to
ec6f85d
Compare
Well... somehow I failed again to do a proper rebase to make github's compare button useful. Also I did't manage to merge both our changes in Edit: Actually, I am not sure if we even want to use the |
304de33
to
7c3fc0c
Compare
7c3fc0c
to
8a0afdf
Compare
8a0afdf
to
15c9f42
Compare
15c9f42
to
c8a1634
Compare
I believe this is ready to be reviewed now. There are only two things still bugging me (apart from possible code style things and all css being spread over so many files): The menus (language, user, burger) do not trap focus. And they still dont use the |
c8a1634
to
2af82a3
Compare
Thanks for the changes! It already looks good and I like a lot about it. Especially the nav menu looks and feels good (The hover effect with out but without in-transition is great). I also like the indentation of the nav items in the burger menu. I have not yet looked at the code changes! I will do that later. But I have comments about the design. Despite how they are formulated, this is all just opinion and stuff we can talk about. Oftentimes, I'm not sure myself. And lots are about Lisa's design, not your implementation of it. General
Logo
Search
Login
Language
Navigation/Burger menu
User menu
|
This creates a seperate component for the language selection and pulls it out of the user menu, so it can be shown individually and regardless of the logged in/out state of the user. The overall design of both components was revised according to given desgin specs.
1b855bb
to
f1ec3e3
Compare
Ok so I have updated the things you commented on excluding the logo. Some more notes:
|
Ok I did another round of testing the test deployment (not looking at code). All previous points (except the one you mentioned) are indeed solved. I found a few new ones, but it already looks much better! Language menu
User menu/button
Probably just Safari weirdness
Other
Certainly. We can do that when most other stuff is done.
What I meant: the pointy thing almost touches the blue outline of the user button. There is maybe 1 or 2 px between that. I would slightly increase that so that it doesn't look as if it is touching the outline (i.e. move the floating down). OR we can also move it closer (i.e. move the floating up) so that the pointy thingy overlaps the user button slightly. I think both is fine, only "barely touching" looks weird. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, finally managed to look at the code. I reviewed everything except navigation related changes. But since it's late already, I just wanted to push this review out before my weekend.
There were some larger changes done to the `UserBox` in the most recent PR, mainly the addition of the `floating-ui` package and usage of a new `FloatingMenu` for the user menu. As this made my own changes a little hard to incorporate without redoing almost everything, I decided to leave out the `FloatingMenu` in this particular file for now, but I might still add it later on.
The css might have gotten a little messy, but I found it quite hard to keep it clean and contained to a few files while still having everything work with the border radiuses in particular.
Previously, the login button would use an `ActionIcon` component for the mobile version. But when that is placed inside a `Link` component or vice versa, both elements would be focusable. Now the icon is simply placed inside a `div` which uses the same styling as the `ActionIcon` components. This also changes most focus/hover styles from boxShadow to outline for simplicity and now uses a more subtle hover style for all interactive header elements.
The language menu icon now uses a smaller fixed size for all screen sizes. In order to keep a uniform alignment of all buttons inside the button container, I added a media query to adjust the padding of the language icon on medium screen sizes and above, as the other icons still get shrunk a few px for small screens. The language menu now also closes on language selection.
f1ec3e3
to
43ab48f
Compare
Updated things based on your comments and did some smaller additional changes, mostly moving stuff around and cleaning things up a bit. Regarding your top level comment: Language menu
User menu/button
Other
finally, Safari
Sorry for the long comment and many edits on the shorter ones! I guess I kinda went down the rabbit hole here. |
Besides some minor refactoring, this replaces the `back` arrow of the burger menu with a more fitting `up` arrow icon. Furthermore, the burger menu will now again leave some space to the left and the burger menu icons now feature a slightly thicker outline.
This basically prevents the two menus being open at the same with keyboard navigation. Now they will automatically close when they lose focus.
43ab48f
to
4af2b2d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Getting close!!
- I would change the blur radius of the floating thingies to 8px. I think that separates the floating thing better from the background.
- We can ignore Safari for now, but should maybe create a general "check & fix safari" issue
4af2b2d
to
27139a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 Took a while but the better design was worth it!
Just for reference, these things still need to be done after merging this:
- Work on logo margin/positioning and add a tooltip saying "to homepage"
- Refactor navigation to be defined in a data structure that is passed to the burger menu and side box.
- Find and fix problems in Safari
- Fix the lackluster shadow around the floating arrow tip
- Take a look at width of the three main header elements (flex grow, basis, ...). Search box should be able to shrink somewhat and stuff.
- Again ask around on whether closing menus on blur is a good idea for accessibility.
- Collect feedback on whether the current page name should be hidden in the desktop navigation.
For ease of planning: I will Initiative all those things. So no need for you to do anything until you hear from me.
Thanks for sticking with this long review process for so long!
This applies the suggested redesign of the header and navigation components.
Notes: