Prevent Fixed Navbar from Overlapping Content (Content Shifting Upwards)
Вставка
- Опубліковано 8 лют 2025
- 👉 NEW React & Next.js Course: bytegrad.com/c...
Hi, I'm Wesley. I'm a brand ambassador for Kinde (paid sponsorship).
👉 Add auth to your app FAST: bit.ly/3QOe1Bh
👉 NEW React & Next.js Course: bytegrad.com/c...
👉 Professional JavaScript Course: bytegrad.com/c...
👉 Professional CSS Course: bytegrad.com/c...
👉 Discord: all my courses have a private Discord where I actively participate
🔔 Email newsletter (BIG update soon): email.bytegrad...
0:00 Solution
#webdevelopment #coding #programming
Note that my videos may contain mistakes. Always verify yourself that your code is safe and does what you want it to do for your specific situation. You agree by watching the videos that you are solely responsible for any mistakes in your code.
This channel and all its content is owned & operated by ByteGrad Sp. z o.o. with Tax ID: PL6762676561 .
.
TOP resource to LEARN AI for Developers - datacamp.pxf.i... (paid sponsorship & ByteGrad Sp. z o.o. gets commission)
Thank you so much for this clarity. I have just spent hours building a nav bar from scratch and the overlap was frustrating but I finally done and wanted to see if there was a shorter way to do it and here is so again thanks bud
I wish I could like this video a million times. 😢
Thanks.
Im just learning HTML and you have no idea how much simple videos like this help so much. Thanks for explaining straight to the point what the issue was. Congrats on being the one to teach me about z-index existing LOL
real 🤣🤣
you are the best, life saver, thx a lot
I have a class project and the deadline is in a few hours but i have been stuck on this for quite a while now. Thank you soo much for this video. It was just what i needed
that's so help full
I have been googling all day
Thank you so much for this you have helped me so many times that i dont know how to thank you. You are my savior
I just set the height of my wrapper div to min-height and it fixed the issue. This is a cool method for a fixed height though!
just googled my problem and this video came up. It solved my problem. Thanks!
I got the solution at 0:59 seconds! This was excellent
You're an angel. And thank you for explaining aswell, made so much sense!
We have this individual school project and the deadline is tomorrow. I was about to continue where I left of few months ago and realized I'm still working on the layout. I got stuck here and thank god I found this video. Thanks!
Finally someone who explains this
Man you're just LEGEND !
Thanks bro, simple, understandable and extremely useful :)
thanks for explaining as well ,simply slowly aproach
I simply use position sticky instead of fixed. that doesn't cover the contents beneath it and they remain in theri static position. Thanks for the content.
You Sir are a lifesaver!!!!!
Thank you so so so much sir. It really works. 🎉
Exactly what I needed! Thx.
Thanks a lot , your video Helps me in such a good time !
Thankyou so much brother from india🎉
you are life saver
Thank you sir, your video is really helpful❤❤❤❤❤❤❤❤❤❤
You save my interview project
❤ wow superb. I fixed it 😊. I watched many videos but not solution finally got ❤
❤thank u soo much I was stuck in this part.
thank you so much .Love from india ❤
Thank you bro iam struggling from hours you helped me out❤️
thank you so much broooo
made my day
thank you for the informations ♥
So useful !! thanks
Thanks, mate!
You saved my time man 😊
Thanks for the video
Thank you very much ❤
Thank you so much
thank you so much
I'm not sure that will work for smaller screens if the header has elements that will wrap. Wrapping means the headers' height will be bigger. Actually, I've just tested before posting.
Thus, that's not the final solution keeping into account that responsiveness is a must these days.
thankyou very much
Thank You👍
Is it good idea to fix padding to 60px? Will the toolbar height not change depending on screen?
best , its work! and i sub you beacuse you are best
got a problem with this one, but with a responsive navbar. whenever i use the scrollreveal animation my responsive navbar overlapped my content, i already set the z-index high and yet it still not working
Thanks bro ✨
Thanks Very Thanks you are a great
Life saver !!
Thanku brother my problem is fixed
Awesome video
thank you bro😩😩😩
thanks🚀
what if i have a background to the section under the nav?
Brother, the marquee scroll is overlapping the navigation bar 😢😢 how to fix that
please i have question
how to prevent collapsed menu not pushing content down when expanded?
THANK U SO MUCH
💖💖💖💖💖💖💖💖💖💖💖
THANK YOU
Or you can use position sticky
Muchas gracias :)
My nav bar now stays fixed, however everything scrolls over the top of it. Can you please advise?
Actually, I was wrong. The nav bar is fixed, but everything was scrolling UNDER it. Because it was transparent, you could see the text overlapping. I changed the nav bar background to white, which has solved that problem. However, I have 5 buttons which scrolls to a different section of the page. Each section scrolls to the top of the page and doesn't stop at the nav bar. I've been racking my brain for 2 hours but cannot solve it. Can anyone advise?
@@austinedwards6334hey!i'm in exact situation right now,i will be sooo grateful if u tell me the solution if u figured it out,please!!❤
@@austinedwards6334 Try using display: sticky and set a top value the size of the navbar. It would be so much easier if you could just set the fixed have have the browser change the available area to be reduced accordingly. CSS is the hack of hacks.
Can you please give me a solution while using tailwind in react web app. I am facing problem using tailwind . Please assist
Clutchest video on the internet stg
Beautiful❤❤❤❤
z-index:
THANK YOU
This is wonderfut indeed
mmmm I want the page content to be h-screen and this just makes it h-screen + 60px which is not what I want
so the answer is: set z-index to 99999 - also works for me
thank you so much
thank you so much
This is wonderfut indeed
This is wonderfut indeed