Responsive navbar tutorial using HTML CSS & JS

Поделиться
HTML-код
  • Опубликовано: 20 май 2024
  • You can find the Frontend Mentor project here: www.frontendmentor.io/challen...
    And the free Scrimba course here: scrimba.com/learn/spacetravel
    🔗 Links
    ✅ Why I use HSL: • Are you using the WRON...
    ✅ More on feature queries (@supports): • Using Feature Queries ...
    ✅ More info on .sr-only: www.scottohara.me/blog/2017/0...
    ✅ CSS-Tricks article on disabling animations while resizing the viewport: css-tricks.com/stop-animation...
    ✅ Frontend Mentor: www.frontendmentor.io
    ✅ Scrimba: scrimba.com
    ⌚ Timestamps
    00:00 - Introduction
    01:23 - What we are starting with
    03:38 - The flex utility class I am using
    04:48 - Basic styling to get started
    06:41 - The bold numbers
    09:56 - Setting up the mobile version
    14:50 - The blurry background effect
    16:32 - Dealing with browser support for backdrop-filter
    19:01 - Modifying the spacing with gap
    20:49 - Adding the button to open and close the menu
    24:36 - Styling the button
    28: 16 - Making the button work - adding the functionality
    41:48 - Styling the nav at larger screen sizes
    #css
    --
    Come hang out with other dev's in my Discord Community
    💬 / discord
    Keep up to date with everything I'm up to
    ✉ www.kevinpowell.co/newsletter
    Come hang out with me live every Monday on Twitch!
    📺 / kevinpowellcss
    ---
    Help support my channel
    👨‍🎓 Get a course: www.kevinpowell.co/courses
    👕 Buy a shirt: teespring.com/stores/making-t...
    💖 Support me on Patreon: / kevinpowell
    ---
    My editor: VS Code - code.visualstudio.com/
    ---
    I'm on some other places on the internet too!
    If you'd like a behind the scenes and previews of what's coming up on my RUclips channel, make sure to follow me on Instagram and Twitter.
    Twitter: / kevinjpowell
    Codepen: codepen.io/kevinpowell/
    Github: github.com/kevin-powell
    ---
    And whatever you do, don't forget to keep on making your corner of the internet just a little bit more awesome!

Комментарии • 406

  • @mrCetus
    @mrCetus 2 года назад +11

    This is so well explained. Love that you cover so many newer css properties, logical properties as well as best practices like aria. This is quality education.

  • @spacemanstrikesagain
    @spacemanstrikesagain Год назад +60

    I found the Hamburger mobile navigation menu tough to grasp. I read multiple articles, played around with codepens, watched videos etc. This is the only video that explained the whole thing in a truly beginner friendly way. And I appreciate the effort that you put into it Mr. Powell. Kudos and millions of thanks ❤❤

  • @CodeWithSahand
    @CodeWithSahand 2 года назад +12

    The Navbar looks amazing. I like the idea.

  • @aakashkathait8328
    @aakashkathait8328 2 года назад +24

    I just completed you “conquering responsive layout” course , it changed my mind completely on how I see html and css. Thank you for such quality content for free

  • @electronicbasics1856
    @electronicbasics1856 2 года назад +79

    the tutorial everyone needed but no one asked for.

  • @dannyr2976
    @dannyr2976 2 года назад +3

    Another great video! The site design and navigation looks so clean, I love it! Always learn a lot from watching your examples so thank you so much!

  • @perkin524
    @perkin524 2 года назад +4

    Oh Yes! What an excellent tutorial - you were on top form for this one Kevin. So helpful to see modern CSS rules in actual use cases like this where you can not only see how they work but also how they save time and effort.

  • @Pavel-wj7gy
    @Pavel-wj7gy Год назад +2

    Sometimes I get to do navbar, footer or any kind of layout components that I forget how to do. On those days, I come to Kevin Powell channel for ideas and you never disappoint! Truly a joy to watch someone as fascinated by CSS as you.

  • @ZANES-YT
    @ZANES-YT 2 года назад +2

    This guy us one of the best content based programming markup language course tutor ever, so much valuable content in the last 3 years from you thanks for helping me being the css designer I am now.

  • @KaerioMika
    @KaerioMika 9 месяцев назад +4

    That's so cool that you take your time and explain things well like with a friend. Really enjoyable to watch.

  • @cemrekur5700
    @cemrekur5700 2 года назад +50

    Great video , only problem that you may come across , you should also put visibility:hidden to nav-links to avoid tabbing over the screen and also to get around transition issues adding simple delay to transform can do the trick!

  • @markdecilio491
    @markdecilio491 2 года назад +3

    i really like how you explain the details in a simple and understandable way! great tutorial Big Thanks

  • @nicolasnog26
    @nicolasnog26 2 года назад +3

    Great video, you are inspiring me to get in more depth touch and play around with CSS instead of using already done templates for my projects!

  • @user-os4zb1wo6b
    @user-os4zb1wo6b 9 месяцев назад +1

    This man is pure gold. The sheer number of informative videos on CSS instead of just blabbering is insane. Get this man a subscription.

  • @rishabkumar5656
    @rishabkumar5656 2 года назад +2

    Hi Kev, this is one of the most easiest and well explained videos on youtube. Well done. Thanks for making it. 💖💖

  • @steff9775
    @steff9775 Год назад +2

    Dude...i watch your videos for almost 1 year now. This is my first comm and I wanted to say that I just LOVE THE WAY YOU TALK.

  • @CarlWicker
    @CarlWicker 2 года назад +8

    I'm currently working on this project in ReactJS, great project with some interesting challenges. It's very handy to have the figma files.

  • @Santino11238
    @Santino11238 2 года назад +16

    Thank you, as a MERN stack dev I'm always looking to learn more styling. Appreciate the content.

  • @user-ir9dm3yx4o
    @user-ir9dm3yx4o 2 года назад

    the design is just so clean and beautiful!! glad i found this, thanks for the video :D

  • @aymenfyi
    @aymenfyi 2 года назад +19

    kevin, can't thank you enough for all the invaluable content you're consistently giving us. learning so much and enjoying every step along the way! ♥

  • @alexanderdavin1655
    @alexanderdavin1655 2 года назад

    It's really helpful explaining every attribute/property as you go along, thanks for that.

  • @digitalalien3534
    @digitalalien3534 2 года назад +20

    I just finished the full course on scrimba and it was GREAT. A ton of information on proper workflow and good practices, and lots of pointers on useful things I need to learn more about. I've been trying to get better at building complete websites (instead of small challenges like hovercards etc) and learn some JS along the way, and I was a little overwhelmed and sometimes felt lost as to where to start and what's important. But with this course the picture became much clearer. It was exactly what I needed, so thank you!

  • @davidtaylorgarcia8556
    @davidtaylorgarcia8556 2 года назад +5

    Certainly you are as good as a web-dev-youtuber can be. Your clarifications are awesome, your content is incredibly well structured, even your voice tone gets on really well with the content. Thx a lot!

    • @KevinPowell
      @KevinPowell  2 года назад

      Thank you so much for the kind words!

  • @mirandasanchez4000
    @mirandasanchez4000 10 месяцев назад

    I’ve learnt SO much from this tutorial, it’s great to put knowledge into practice. Thanks! I wouldn’t mind watching a couple of ads if that help you whatsoever as a youtuber. Your content is priceless 😊

  • @cohdalton
    @cohdalton Год назад

    Absolutely brilliant video, there's so much in it to go through and learn. Thank you, fantastic job!

  • @myfavoritemusic2428
    @myfavoritemusic2428 2 года назад

    I just started my HTML CSS and JS studies and my first project is creating my own personal CV site.
    This will help A LOT with that. Thanks!

  • @Anth-ony
    @Anth-ony 2 года назад +109

    Great video. I know you're the "CSS King", however, may I suggest that you create some very basic JS tutorials on the most common use-cases of said code? I've learned more about the basics of JS from you, as you touch on it in your videos, and how to implement them in my own projects than I have from people actually teaching straight up JS. You're very concise in how you create/explain those sections in your videos and I'm sure others would enjoy this as much as I would. Plus, it would be a bit of a change up for you to keep things fresh. Anyway, keep it up Kevin, you're one of my favourite RUclipsr!

    • @nv3796
      @nv3796 Год назад +1

      +1 - things like how to add a secure login, etc; I know these will require databases, but not sure how to approach this problem

  • @shishirjha1117
    @shishirjha1117 2 года назад

    your videos are kind of a one stop solution. thanks for explaining so well

  • @trentturner1546
    @trentturner1546 2 года назад +2

    Thanks for this tutorial Kevin. I’ve been watching you for a while and always enjoy learning from and watching you. This one helped me switch my default mobile navigation to use translate x instead of animating the left and right properties to show and hide my menus. A much better way of doing it. Thanks again.

  • @sourav_96
    @sourav_96 2 года назад +1

    I am working on this project using scrimba platform
    Great course
    Doing this using reactjs
    Till now best course for me to learn design system 👍

  • @Petahsaur
    @Petahsaur 2 года назад +6

    Perfect timing Kevin,
    Just as I started to look into navbars and js last 2-3 days
    Thanks!

  • @SteveBonin
    @SteveBonin 2 года назад

    Hi Kevin, really nice! I learned a couple of things along the way. I am spending some time with your videos, especially Fridays, it gives me something to do that feels like work but is more fun. Thanks

  • @abadlibadreddine1960
    @abadlibadreddine1960 Год назад

    I started following this guys 2 months ago, i can now say that i fell in love with CSS

  • @whoisitidk3980
    @whoisitidk3980 2 года назад

    Thank you for sharing so many useful HTML, CSS, and JS attributes, it really helped me a lot

  • @millermcdonell291
    @millermcdonell291 2 года назад +1

    You reall are CSS-king just like Kyle said. I have learned alot from you, thank you!

  • @RayMaxey
    @RayMaxey 2 года назад

    Niiccee, I have been using this Space project to incorporate the navigation into my project this past weekend. You knew that I got a lil stuck and needed a quick push.

  • @DanteMishima
    @DanteMishima 2 года назад +2

    And you wonder why we call you king?
    How you knew this is what I needed is beyond me

  • @physlift9175
    @physlift9175 2 года назад +1

    I was literally just looking for a video from you on this yesterday!! Did the responsive navbar on my own....time to see how bad I messed up ha thanks kevin youre the goat

  • @TiagoSilva-sq4gp
    @TiagoSilva-sq4gp 2 месяца назад

    Man you are the bomb, i was almost giving up of programing but with your videos i finally got it, thank you

  • @Yuri-qr7ml
    @Yuri-qr7ml 6 месяцев назад

    So I started this tutorial a few months back as I thought it could be a fun project, got frustrated by the button for the nav not doing what it should be doing. Now my journey has only started earlier this year with little time but it seems that I had a . instead of a , in the js. So I wanted to come back and say, fantastic tutorial!

  • @nof123
    @nof123 Год назад

    been learning css for 2 months and wow I learned alot from this vid

  •  2 года назад +1

    I can hear both hope and pleading in that sentence that 'Internet explorer is dead' :)
    Great video as always.

  • @Felipe-53
    @Felipe-53 2 года назад

    Wow, this came out right in I needed it. Thanks, you're awesome!

  • @gabrielbaldez3178
    @gabrielbaldez3178 11 месяцев назад

    Excellent tutorial! Great things were taught and you explained in a very clear way.

  • @alex-suciu
    @alex-suciu 2 года назад

    props for making this accessible

  • @kevinwaag9976
    @kevinwaag9976 2 года назад

    really elegant way of doing this. Well done!

  • @AbdicateDotNet
    @AbdicateDotNet 2 года назад +3

    As usual, a great, informative, and wonderful video!! 👏👏👏👏 Now I have to change my site! 😁

  • @sssself
    @sssself 10 месяцев назад

    You Are So Amazing Kevin!! Thanks for your existing👼

  • @tmkdesigner
    @tmkdesigner 9 месяцев назад

    Thank you so much for all of your videos! Im learning so much!

  • @rheavictor7
    @rheavictor7 2 года назад

    Kevin, thanks man. I'm really improving m y CSS skills with your content!

  • @06011983daniel
    @06011983daniel 2 года назад

    Thank you so much for sharing your knowledge. Even though I don't know how to speak English, I managed to understand the whole concept to reach your final goal.

  • @roshanaryal310
    @roshanaryal310 2 года назад

    Great as always Kevin! I love your videos

  • @chawza8402
    @chawza8402 Год назад +1

    Thank you Kevin. This video showed me most of the fundamental that I need to start up my responsive web. other vids does not really explain how exactly how its done so they doesn't teach anything lol

  • @ibnulferdous2349
    @ibnulferdous2349 2 года назад

    CSS from another planet! Loved it!

  • @aryan7069_
    @aryan7069_ 2 года назад

    I just did first challenge time management UI . I m glad i was able to do it without figma files

  • @maidenpotato
    @maidenpotato 2 года назад +1

    This was so amazing, thank you so much!

  • @sameerahlawat8480
    @sameerahlawat8480 Год назад +1

    Mr. Kevin you teaches the beauty of of html css & js in beast mode .

  • @raho2005
    @raho2005 2 года назад

    holy cow, i learned a lot of new and interesting css features today. Thanks!

  • @waardal
    @waardal 2 года назад

    My god just in time when i have to make a responsive portfolio as a school project, thank you so much!!

  • @yajirushik2871
    @yajirushik2871 2 года назад +22

    6 months ago I wouldn't know how to do it, so I have subscribed to You. Actually I just have moved to end of video and after looking at final effect I can remake it from scratch. Thank You for the whole time which You are spending to teach us. Also still looking for front-end job but need to learn a lot more :D

  • @bunyameennurudeen173
    @bunyameennurudeen173 2 года назад +1

    Great lesson from a greater TechEducator

  • @chetankhulage
    @chetankhulage 2 года назад +1

    🥺🤤🤤🤤🤤🤤thankssss your channel is blessings for us🥺🥺🥺
    I'm in super love with CSS 🤤🤤🤤🤤🤤

  • @luiscarloscorderopena7030
    @luiscarloscorderopena7030 2 года назад

    I learned some very usefil tip watching this, thank you!

  • @mohammadnoman2457
    @mohammadnoman2457 2 года назад

    Thanks so much for this! Would love to see more mobile layout stuff with css

  • @trungduchua1786
    @trungduchua1786 2 года назад

    Thanks Kevin, this video helps me a lot! As an UI/UX designer who wants to expand his knowledge to manage his work better, this kind of easy-to-understand tutorial is really a gift!

  • @ismailsossi3239
    @ismailsossi3239 Год назад

    you are a sweet person, thank you so much for trying!

  • @aayushjamuar9900
    @aayushjamuar9900 2 года назад +1

    Dude 🥺🥺🥺🥺, i needed this sooo much

  • @westonpeabody2420
    @westonpeabody2420 7 месяцев назад

    Just simply AWESOME! I love it!

  • @jen-vj4vq
    @jen-vj4vq 2 года назад

    Thank you for this video. I learned so many new things just watching it

  • @GoldoMania.
    @GoldoMania. 2 года назад +1

    Hello Kevin! i realy love what you are doing, great job.

  • @xomgitsjay
    @xomgitsjay 2 года назад

    Yay an updated navbar video!

  • @TheMrFelin
    @TheMrFelin 2 года назад

    Awesome tutorial! Thanks for your nice explanation!

  • @maloii_mylove
    @maloii_mylove 2 года назад

    I have been practicing the flex box whole right now 👍🏼

  • @thtasca
    @thtasca 2 года назад

    Oh man, I really need to upgrade my knowlege in css. A lot of atributes and selectors I'm not familiaryzed, I really stuck in time in some parts of front end ahuahuhauhaa. Your channel is so great, i'm not every time here but when I see one of your videos I'm always learn more, thx.

  • @kunal7066
    @kunal7066 2 года назад

    That was very helpful.Thank you so much!

  • @Wynorrific1
    @Wynorrific1 7 месяцев назад

    I love your work everything is so easy. I just love it, I thought you were the css king but really your the code king.🤴you make it very easy to follow and learn god bless you and please keep making content

  • @everythingisfine9988
    @everythingisfine9988 2 года назад

    Nice slick design. Well done 👍✅

  • @Oj-Gaming-vt6vd
    @Oj-Gaming-vt6vd 6 месяцев назад

    Hey kevin :D Amazing vids mate, they are really helping me progress on my own website :D
    Keep up the good work :)

  • @sororbudwiser
    @sororbudwiser 2 года назад

    Great tutorial with excellent tips!

  • @christopherboe
    @christopherboe 2 года назад

    @supports is rad! I have never used that before thank you!

  • @Mohammadreza-Dolati
    @Mohammadreza-Dolati Год назад

    Sir , your videos are full of useful contents, thanks a for your helping, big ❤️ from Iran

  • @jacquelinedawn9510
    @jacquelinedawn9510 2 года назад

    You're awesome! And you have a nice voice! Keep up the great work!

  • @VitalyVasilevsky
    @VitalyVasilevsky 2 года назад

    Thank you very much for a such full of cool new information video. I've learned a lot of tricks today. Going to the course...

  • @vavaiva4080
    @vavaiva4080 2 года назад

    an answer for my misery… just had my class and i got a homework to do and this is a life saver… either God listen to my misery or my ipad tired to listen to my frustration…

  • @fredfonseca1474
    @fredfonseca1474 2 года назад

    Good stuff I'm definitely taking a look on that course

  • @arifurrahman9133
    @arifurrahman9133 2 года назад

    Wow.thank kevin.always learn new from you.

  • @SrckyBoi
    @SrckyBoi 2 года назад +2

    Cool video Kev. Just one correction, display: none doesn't remove element from the DOM, rather from the document flow. Keep up the good work.

  • @pranavyeole102
    @pranavyeole102 2 года назад

    This channel is really really useful

  • @bartekpaczesny508
    @bartekpaczesny508 2 года назад

    Thanks for the tutorial...it really helped out :)

  • @ZionBetter
    @ZionBetter Год назад

    awesome video. helped save me tons of time on my project

  • @StevenJGaming
    @StevenJGaming 9 месяцев назад

    I love you Kevin. You are my secret mentor.

  • @WOLF91
    @WOLF91 2 года назад

    Cool stuff man, just subbed

  • @pranavyeole102
    @pranavyeole102 2 года назад

    Learnt so much from this video, thankyou so much 😁

  • @ahooton
    @ahooton 6 месяцев назад

    Kevin, I spotted something when implementing this in my project; if the mobile navigation is still in its expanded state, and the browser window is manually resized so that it passes into desktop view, then aria-expanded and data-visible will still remain set to 'true'. Additional JS logic can be added to ensure these attributes are set to 'false' if this scenario occurs.

  • @Daniel-pg8ln
    @Daniel-pg8ln 2 года назад

    Dude, this was awesome!! Hello from Brasil 😁

  • @john-xb6xj
    @john-xb6xj 2 года назад

    That's a great one, Thank you!

  • @timidjawa6324
    @timidjawa6324 2 года назад

    Absolutely Awesome!

  • @tonytony-fc6gq
    @tonytony-fc6gq Год назад

    THANK YOUI VERY MUCH!!!!!, this helped soo much

  • @Ree-rr1js
    @Ree-rr1js 2 года назад

    I'M AMAZED !!!!

  • @suleman234
    @suleman234 2 года назад

    hey kevin i love ur intro its awesome