• CSS fixed navigation
    17 replies, posted
Figure this would be useful to others, it turns the blue navigation bar fixed and places it on top of the darker navigation. This allows you access to the blue navigation bar through out the thread, as well as your profile/coin/settings. I find myself going through a page and scrolling all the way back to the top to get back to the home page or pressing back as many pages I went into the thread to get back to the main subforum. It is a little thing but since it is such a small bar it really isn't that obtrusive and can help you get around much faster. #toolbar{ position: fixed; z-index: 50000; width: 100%; top: 0; } .navbar-main{ margin-top: 30px; }
This forum is now PERFECT
This is great!
Here's an alternative, utilising one of the newer CSS features "position sticky". #toolbar{ position: sticky; z-index: 50000; top: 0; } This keeps the darker navigation above, but once you scroll past the darker navigation, the blue navigation sticks to the top. Also, it only requires 3 CSS properties, which is nice.
@Inacio : can you tweak awfully dark to have this? (preferably the one @Danneh posted since it's perfect)
This can probably be fixed by giving the last read bar a top margin.
I added this by default a while back and everyone bitched at it
I'd say add it anyways, I feel it would be very useful once it can show new notifications as you are reading a page
Eh, why? I guess there's the issue with auto-scrolling to things and it overlapping, aside from that though it's really useful
The whole header was moving then and it was way too fucking huge.
It seems garry made this default again, plus added a shadow.
Well in that case, that makes sense, however if when it's just the blue bar as it is now it's fine. The shadow is a nice touch. Question though, why is the "top" value set to -1px? Setting it to 0 makes the bar go directly the to the top, -1px is hiding 1 pixel of the bar
Probably to hide the black line on top of it
Thanks for adding it in by default! Though part of me feels like the shadow may be a bit too dark. Either way I am fine with it, the darkness just stands out a bit to me since other things don't have shadows on them.
https://files.facepunch.com/forum/upload/767/35530bf8-1d87-40ad-a616-c63b18a6c2eb/image.png Trademark garry attention to detail
I can't see any black line on mine when it's at 0. Doesn't matter too much anyway, it looks ok.
Sorry, you need to Log In to post a reply to this thread.