No video

Pure CSS Hamburger Menu & Overlay

  Рет қаралды 398,505

Traversy Media

Traversy Media

Күн бұрын

In this video we will create a landing page with a pure CSS responsive hamburger menu (No JavaScript) with a bit of animation using CSS transitions.
CSS Starts - 6:27
Menu CSS Starts - 15:40
Sponsor: Freelancer Bundle (Use "brad25" for 25% off)
studywebdevelo...
Code:
codepen.io/bra...
💖 Become a Patron: Show support & get perks!
/ traversymedia
Modern HTML & CSS From The Beginning:
www.udemy.com/...
Follow Traversy Media:
/ traversymedia
/ traversymedia
/ traversymedia

Пікірлер: 425
@tryfanevans7047
@tryfanevans7047 4 жыл бұрын
Just as I started thinking I was beginning to master css... then I see this video and find how much more there is to know. Thanks for keeping me humble.
@AKagNA
@AKagNA 4 жыл бұрын
yeah right
@cleancodez
@cleancodez 5 жыл бұрын
every body is first Thanks brad....genius as always...
@smokinghot5373
@smokinghot5373 5 жыл бұрын
You helped me a lot. I was able to create and manage my own website. Thanks to you, man. Have a great day whoever is reading this.
@cleancodez
@cleancodez 5 жыл бұрын
hi smoking....):
@ac695
@ac695 2 жыл бұрын
Awesome!! I love the fact that you give a rationale for each css property that you decide to go with. Super-helpful.
@mascatrails661
@mascatrails661 3 жыл бұрын
Wow, fantastic! Coded along with you again and love how this turned out. Such a creative solution to use the check box and its checked state to control the visibility of the menu
@KuldeepSolankiYT
@KuldeepSolankiYT 5 жыл бұрын
one of the best instructor I've ever seen! Thanks Brad for giving us this quality content!
@christian-schubert
@christian-schubert 5 жыл бұрын
After some project development heavily relying on javascript functionality, I was racking my brains trying to revert to a clean and strictly minimalist approach to implementing a responsive navigation menu, an approach that at best should eliminate the necessity of Javascript usage altogether. ...gave up and eventually started cobbling together some code when I noticed a new video on this channel that I merely wanted to watch to distract myself a little - and BOOM! That checkbox solution is simple. Clean. And BRILLIANT. Why did I not come up with this? Haven't been missing any of your videos lately, a BIG thanks for continuously creating and sharing such high quality content!
@charlotte.upandaway
@charlotte.upandaway 4 жыл бұрын
This is incredible! Thank you so much for such a high quality tutorial. I've followed along and made my own hamburger menu and am absolutely thrilled with it! Liked and subscribed!
@aleksandraryan
@aleksandraryan 3 жыл бұрын
That's what I love about your teaching style, that you start from scratch and build up the project 🙏
@mahmoudhassen4463
@mahmoudhassen4463 5 жыл бұрын
Extremely useful lesson, I've learned a lot about creating a hamburger menu, transitions, animation and buncha other stuff. Thank u so much brad, sending love from Egypt!
@sarahcharity5750
@sarahcharity5750 4 жыл бұрын
Thank you so much! This is definitely going to help me 'wow' my professor for my final project this semester!
@CODINGISEASY
@CODINGISEASY 5 жыл бұрын
*crazy that you can do that with just css!*
@republicgamer6998
@republicgamer6998 4 жыл бұрын
css can do anything it's just bootstrap make life easy xD
@sushilkumarlohani6709
@sushilkumarlohani6709 3 жыл бұрын
CSS is made for This bro I can make Advanced Web Illustration with CSS I recommend to Check out the Channel 'Online Tutorial', for THE most amazing speechless Web Illustration
@Digital963
@Digital963 3 жыл бұрын
Yep! Beautiful isn’t it? It’s possible to do it just with css, in this case at least, because of the checkbox input. The entire menu relies on that. Brad’s cleverness really shows when he added padding to the hamburger container. That way you didn’t have to guess where to click to get it to work because with enough padding you can click anywhere on the hamburger. Good shit Brad! “Now get me those kha-kis so I can get warm it up. It’s freezin out heaa!”
@rbahar2011
@rbahar2011 4 жыл бұрын
One of the best tutorials out there on internet. Thanks Brad. Loads of love
@nympho25
@nympho25 4 жыл бұрын
starting from scratch... love it dude...it helps me understand and gives me practice on what is needed to start a project, I understand its second nature to you, and i appreciate it more when you go thru , what may seem tedious to do, i started last year learning the ins and outs of being a full stack developer, and what looks confusing as hell to others, makes so much more sense to me now.
@Theygonnablowmycat
@Theygonnablowmycat 5 жыл бұрын
somebody who actually explains his coding properly... Very good video, thanks for the help.
@patriciacostalonga5282
@patriciacostalonga5282 4 жыл бұрын
Amazing tutorial
@filiporkowski
@filiporkowski 5 жыл бұрын
Me: I already know how to do it. Also me: watches the entire add before the video, leaves a like, lets video play in the background to ensure Brad will get paid.
@EdmundAlynJones
@EdmundAlynJones 4 жыл бұрын
Is that how it works?
@impyworm115
@impyworm115 4 жыл бұрын
@@EdmundAlynJones yeah, the user's gotta watch an ad or watch the video for a certain time i think not sure
@HossamKhalaf-sr1oo
@HossamKhalaf-sr1oo 5 жыл бұрын
and the oscar of best developer and teacher ever goes to 'Brad Traversery' love from Egypt ..
@midoughost9380
@midoughost9380 5 жыл бұрын
Just waw .. You're very objective in the way you make videos , not too fast , not too slow. Having courses on mostly every thing, bringing useful tips and advices every now and then. I Hope you keep this channel up !
@Chuby_ubesie
@Chuby_ubesie 4 жыл бұрын
Brad u are the best there is. I find it hard to follow other tutorial channels. U have truly spoilt them for me
@DavidBoutin
@DavidBoutin 2 жыл бұрын
Dude, I am learning SOOO much just by following along with your tutorials! Thanks for all these. I'll get one of your Udemy's courses really soon, probably that 50 projects in 50 days one.
@CJ-ew8df
@CJ-ew8df 3 жыл бұрын
I never considered using an input field to add state for CSS selectors! Fantastic idea!
@josema-boy7610
@josema-boy7610 5 жыл бұрын
This is amazing, such simplicity every time you code. Thank you very much.
@allowmeasme
@allowmeasme 5 жыл бұрын
CSS now a beast on it's own, still can't believe no JavaScript was used excellent tutorial. Thanks
@MounirBoukhiber226
@MounirBoukhiber226 5 жыл бұрын
From udemy course 😂😂✌ keep going brother 💓💓
@Beny123
@Beny123 3 жыл бұрын
I am impressed by the simplicity . Thanks Brad
@avrumy
@avrumy 5 жыл бұрын
I love this. The design is amazing and the idea is genius. Thanks for such a great tutorial.
@caincanex3879
@caincanex3879 5 жыл бұрын
Thanks brad big fan of your work. Learned HTML CSS and Javascript from reading online and of course from watching your videos. More power.
@unleashedinc
@unleashedinc 4 жыл бұрын
css has come such a long ways. thank you for making this training.
@sgr2683
@sgr2683 3 жыл бұрын
I wasn't getting any good video on overlay! But this video solved that problem to😊 Thankyou so much:D
@raghul7211
@raghul7211 5 жыл бұрын
Super cool as always
@DebVorndran
@DebVorndran 4 жыл бұрын
Thanks Brad, I love it. I'm using it, and dumping bootstrap. My layout file no longer needs ANY javascript for MOST pages. It looks great everywhere I checked, except for on my old iPhone 5 on Safari. The 3 lines of the hamburger are not aligned when the menu is closed, and when it's open, it's supposed to look like an X, but it looks like a T at a 45 degree angle.
@davescorneroftheworld1147
@davescorneroftheworld1147 4 жыл бұрын
There is no 45 degree angle ANYWHERE is his code!
@mikersson
@mikersson Жыл бұрын
Nice! I will make this one that looks really nice. Thank you for sharing!
@Ferdam
@Ferdam 4 жыл бұрын
First of all, amazing video! I tried to implement this css/html only visibility toggle method but I just failed. Gave up and went for an easy and quick JS solution. Anyway, I'm sure I'll get how that works someday. Still useful for the hamburger icon using pseudos (after/before). Gr8 stuff man
@ninpasker3223
@ninpasker3223 2 жыл бұрын
Awesome video super helpful even after 3 years of creating this content, I was easily able to implement this code with sass.
@healthrik2732
@healthrik2732 3 жыл бұрын
Sir i love your straight forward serious way of teaching , very valuable content
@mr.webdev3700
@mr.webdev3700 5 жыл бұрын
Thanks Brad! Amazing as always!
@Digital963
@Digital963 5 жыл бұрын
It would be helpful if you could split the windows in VS code so that we could see what HTML elements you are targeting in your styles. This would be helpful for those like me who aren't necessary writing it down line by line but more following along visually as a way to compare and understand your approach and it makes for a more efficient way of way of studying the content without taking away from those who need to follow along line by line. Thanks.
@jimohyusuf8115
@jimohyusuf8115 2 жыл бұрын
Exactly
@raghavgupta3168
@raghavgupta3168 5 жыл бұрын
A very big thanks🙏 for the Copious amount of knowledge you are giving to us. Lots of love from India.🙏
@21Dimen
@21Dimen Жыл бұрын
Great tutorial! Thank you. By the way, I wonder are the clickable? I made a burger menu by watching this video but they're not even selectable as if you wanted to select text.
@bulldog2024
@bulldog2024 4 жыл бұрын
Great video as always. I also figured out how to close the menu and overlay when clicking on links. Thanks again!!
@pradeepkumarkatakam929
@pradeepkumarkatakam929 4 жыл бұрын
how to close menu when clicked on links using css only
@lolypop185
@lolypop185 4 жыл бұрын
Only issue was not being able to inspect anything within the showcase (main-body) class because the menu and menu-wrap classes are positioned above them. Solved this by simply adding this to the css and can now inspect everything below the nav menu header: .menu-wrap, .menu { height:60px; } Loved this workaround though!
@tijani3141
@tijani3141 5 жыл бұрын
This is from your udemy course, love it man
@lamstechgaming1899
@lamstechgaming1899 5 жыл бұрын
Hey, Thanks Brad for the video. me encanta cada vez que subes un nuevo video tocas temas importantes y super geniales ¡Está increible!
@marksanford6534
@marksanford6534 4 жыл бұрын
Great video. Very informative and easy to follow as well as understand. Now, we need a video showing how to add sub-menus into this menu.
@mosesglitch3110
@mosesglitch3110 2 жыл бұрын
really enjoy this tutorial definitely subscribing
@shehrozamin9543
@shehrozamin9543 2 жыл бұрын
Jazaak Allah Khair for such an informative video.
@MaAlejaGaitan3D
@MaAlejaGaitan3D 4 жыл бұрын
Gracias Brad!! I love the way that you explains. I'm doing your course modern html css from the beginning. It's awesome!! Sorry for my english =)
@chethanbhat
@chethanbhat 5 жыл бұрын
Traversy Bhaayya Zindabad 😍✊
@martinkarugaba
@martinkarugaba 4 жыл бұрын
Thank you so much Brad for an awesome tutorial. I have a question. How do I get the menu to disappear after I click one of the menu items?
@davidslee101
@davidslee101 4 жыл бұрын
Holy Sh*t - you just blew my mind. I had no idea CSS was this powerful
@Daidera91
@Daidera91 2 жыл бұрын
Great tutorial, enjoyed it so much that i bought your course on Udemy.
@shanegrayson7068
@shanegrayson7068 5 жыл бұрын
Thank you for showing this! will be playing with this for sure over the next week!
@koushikmajumder1898
@koushikmajumder1898 4 жыл бұрын
keep starting from scratch , it helps a lot for beginner like us.
@mf-11111
@mf-11111 2 жыл бұрын
Thanks you Crack!! That's Awesome CSS!
@FruityHachi
@FruityHachi 5 жыл бұрын
a tip to write less code - i put reset styling for li and a tag at the beginning of stylesheet, so i wouldn't have to repeat it everytime i style elements
@XMattingly
@XMattingly 4 жыл бұрын
Genius in its simplicity, beautiful in its execution. Awesome sauce! 😎👍
@anag2125
@anag2125 4 жыл бұрын
Just noticed that you left the code in CodePen! Thank you so much!! :D Gonna take a few styling things from there :D
@SadDamniT
@SadDamniT 3 жыл бұрын
Amazing. I will try this right now
@juliusm.palsson554
@juliusm.palsson554 5 жыл бұрын
Great video Brad! Your tutorials are awesome!
@bhfaught
@bhfaught 5 жыл бұрын
Just signed up for your HTML, CSS, & SASS course on udemy. Needed a modern refresher with grid, flexbox & sass!
@widheg
@widheg 2 жыл бұрын
Great hamburger menu -- with no (need for) JavaScript. I noticed something though that I suspect is unintentional: The tag is not closed.
@elhampazhakh4132
@elhampazhakh4132 5 жыл бұрын
Exactly what I needed! Thanks!
@TheDevilscrap
@TheDevilscrap 2 жыл бұрын
Just amazing, nothing else to say...Thank You for this tutorial :)
@DenisLukic
@DenisLukic 4 жыл бұрын
Brad, thanks mate for this it is awesome :D Your work is the best to be honest and the way you explain everything is top class! I have watched a lot of tutorials from various presenters but your work is unique. All other video tutorials are kind of artificial, if u know what I mean but your approach is natural, when I wtch your tutorial it is like I watch some person I know and there is no acting and u put yourself on equal with others, that is how I feel when I watch your videos. Great work mate and thank you one more time for all knowledge that you share with others. Greetings from Ireland Cheers mate
@jeromeelliah2294
@jeromeelliah2294 4 жыл бұрын
Great tutorial. So great explanation that i bought the course in the description below
@tan4676
@tan4676 3 жыл бұрын
Very pleased I came across this video, this has helped me with my web design revision a lot! Subscribed already :) Thanks for posting, have a great day!
@grantwilliams9838
@grantwilliams9838 4 жыл бұрын
Awesome video Brad . Now I gotta watch the css vids again 😁
@skillzorskillsson8228
@skillzorskillsson8228 4 жыл бұрын
since you use align-items:center and justify-content center alot you can just make a new class in html that you can use for all elements that will have these 2 css attributes and then you just write that class in css that contains only align-items:center; and justify-content:center; i'm not really sure how good i explained it but i think you get the idea. That is usually what i do atleast to avoid repeating code over and over again
@manraf5987
@manraf5987 4 жыл бұрын
You are a legend keep it going!
@cubedev4838
@cubedev4838 5 жыл бұрын
im really appreciate!! U very good man.I made decision, im only want to watch your channel, the other channel i dont care anymore...u are the best channel for programming i ever had in my life. May u always in good health, u are very unic, awesome channel!! :)
@Techthology
@Techthology 3 жыл бұрын
If I could like this video twice, I would!
@Drunkdrgonzo
@Drunkdrgonzo 4 жыл бұрын
Cracking tutorial, I've purchased the course and will be looking forward to cracking through it :D
@Sunset-ts8ir
@Sunset-ts8ir 4 жыл бұрын
Awesome Tutorial. Worth spending hours practicing.
@kamtron1544
@kamtron1544 2 жыл бұрын
love it! thank you so much!
@tomthumb2057
@tomthumb2057 4 жыл бұрын
excellent! thank you it went fast and I'm an infrequent user of CSS but very understandable...
@MuhammadArif005
@MuhammadArif005 5 жыл бұрын
Thanks for your efforts! The way you teach is very awesome.
@marcelo_anselmo_levy
@marcelo_anselmo_levy 5 жыл бұрын
I learnt enough with this video, Brad. Thanks a bunch!
@samarthshinde9565
@samarthshinde9565 5 жыл бұрын
You are best tutor Brad... your videos is help a lot.. keep coding brother..
@damionreid3164
@damionreid3164 5 жыл бұрын
I swear, your videos are the best
@kitlogan1081
@kitlogan1081 3 жыл бұрын
Hi Brad, thanks for this, very useful. I'm trying to get the menu to disappear again when one of the menu items is pressed. The links I'm using are navigating to sections on the same html page, so the page navigates correctly under the menu, but the menu stays visible when it should disappear on tap. Any suggestions?
@bagelproductions23
@bagelproductions23 Жыл бұрын
same problem here..
@adeleke5140
@adeleke5140 3 жыл бұрын
Thank you so much Brad. This helped me out.
@eliotovele1811
@eliotovele1811 5 жыл бұрын
The Greatest teacher...Thanks From Mozambique
@mischafrei5156
@mischafrei5156 3 жыл бұрын
You are a God!! Thank you very much for this!!
@kerryd2060
@kerryd2060 5 жыл бұрын
Yes this menu is in your Udemy course Modern CSS/HTML. Will help re-enforce the learning to see it again.
@JuanNadal
@JuanNadal 5 жыл бұрын
That was pretty solid work!
@andrenations1
@andrenations1 3 жыл бұрын
i really appreciate this lesson sr thank you!!!
@kehbumasama5020
@kehbumasama5020 5 жыл бұрын
Brad you are a blessing to mandkind
@elviskbet6120
@elviskbet6120 4 жыл бұрын
nice stuff brad
@Kempriol
@Kempriol 5 жыл бұрын
In some aticles more correctly in case border-box use *, *:after, *:before
@jasenlakic5033
@jasenlakic5033 3 жыл бұрын
got your udemy course on Javascript, really good
@kornelgeczi4589
@kornelgeczi4589 5 жыл бұрын
Congratulation for your work Brad! From Hungary :D
@mr.miniaturesmodels8465
@mr.miniaturesmodels8465 3 жыл бұрын
32:39 I'm watching this on a tiny phone screen while following along in my laptop. Just a note for the uninitiated in CSS: when he gets to this point, he's targeting the element with a tilde (~) character, not a plus sign. Prior to this, the instructor was saying what he was typing. At this point he doesn't and it's the first time he uses this syntax. It broke my code and I had to find the details in his Github. Otherwise, this was an awesome tutorial!
@mr.miniaturesmodels8465
@mr.miniaturesmodels8465 3 жыл бұрын
/* Show menu */ .menu-wrap .toggler:checked ~ .menu{ visibility: visible; }
@Josa192
@Josa192 3 жыл бұрын
Thanks. It helped a lot!
@nightlifeking
@nightlifeking 5 жыл бұрын
I'm working on the hamburger menu on my app today, perfect timing.
@livw31
@livw31 4 жыл бұрын
Very helpful and well explained. Thanks for sharing 😊.
@maswirv
@maswirv 4 жыл бұрын
You are an amazing teacher.
@jelanibyrd5031
@jelanibyrd5031 4 жыл бұрын
Thank you so much, sir. Truly helpful and eternally grateful.
@Daniel-ij2xy
@Daniel-ij2xy 2 жыл бұрын
Thanks! Aweasome tutorial
@HazemFanoush
@HazemFanoush 3 жыл бұрын
Very useful video and i learned a lot. Thank you❤
Flexbox CSS In 20 Minutes
19:59
Traversy Media
Рет қаралды 1,8 МЛН
Responsive HTML & CSS Side Menu From Scratch
23:57
Traversy Media
Рет қаралды 397 М.
The Joker kisses Harley Quinn underwater!#Harley Quinn #joker
00:49
Harley Quinn with the Joker
Рет қаралды 25 МЛН
Joker can't swim!#joker #shorts
00:46
Untitled Joker
Рет қаралды 41 МЛН
Nurse's Mission: Bringing Joy to Young Lives #shorts
00:17
Fabiosa Stories
Рет қаралды 6 МЛН
Happy birthday to you by Tsuriki Show
00:12
Tsuriki Show
Рет қаралды 12 МЛН
These CSS PRO Tips & Tricks Will Blow Your Mind!
8:48
Coding2GO
Рет қаралды 260 М.
Using CSS custom properties like this is a waste
16:12
Kevin Powell
Рет қаралды 168 М.
Build a Slide out Hamburger Menu with HTML, CSS & JavaScript
16:27
Tyler Potts
Рет қаралды 114 М.
The problems with viewport units
13:23
Kevin Powell
Рет қаралды 360 М.
CSS Grid Layout Crash Course
27:55
Traversy Media
Рет қаралды 2 МЛН
Responsive Pure CSS Menu Tutorial (No Javascript)
43:13
FollowAndrew
Рет қаралды 133 М.
The Story of Next.js
12:13
uidotdev
Рет қаралды 569 М.
10 modern layouts in 1 line of CSS
21:39
Chrome for Developers
Рет қаралды 1,1 МЛН
Top 10 CSS One Liners That Will Blow Your Mind
13:34
developedbyed
Рет қаралды 946 М.
The Joker kisses Harley Quinn underwater!#Harley Quinn #joker
00:49
Harley Quinn with the Joker
Рет қаралды 25 МЛН