Create a Responsive Sidebar Menu with Angular Material

Поділитися
Вставка
  • Опубліковано 24 тра 2021
  • Learn how to create a #responsive sidebar navigation menu with #Angular #material!
    The complete code is available here.
    github.com/thisiszoaib/angula...
    💖 Support my shop at Buy me a coffee:
    www.buymeacoffee.com/zoaibkha...
    📽️ Full stack Angular + Firebase course (50% off):
    www.udemy.com/course/angular-...
    ✍️My blog for more free Angular posts:
    zoaibkhan.com/blog
    Other socials:
    Twitter - / zoaibdev
    Facebook - / thisiszoaib
    LinkedIn - / zoaib-khan-b6456815
    Cheers :)
  • Наука та технологія

КОМЕНТАРІ • 137

  • @ZoaibKhan
    @ZoaibKhan  2 роки тому +3

    Wondering how to add basic routing to this app? Check out my follow up video with a guide on how to add basic routing and a few tweaks to make this even better!
    ua-cam.com/video/8hVP6jZ-gOM/v-deo.html

  • @beezesty
    @beezesty Рік тому

    To the point, elegant, short, concise. Wonderful tutorial. Thanks a lot !

  • @alejandroatria983
    @alejandroatria983 Рік тому

    Just wanted to thank you for this video! It's really well explained and doesn't go around the bushes. Really great tutorial!

  • @ronaksayta8191
    @ronaksayta8191 2 роки тому

    I was struggling with this as I am coding after a long time since material 7. This video gave a very nice clarity. Thanks for the tutorial. Keep up the good work.

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +2

      Thanks Ronak! Glad it helped. Are there any other tutorials you'd like? :)

  • @gopalmuthusamy4479
    @gopalmuthusamy4479 3 роки тому

    Crispy and Clear content. Thanks for the work!!!

  • @luispadron7866
    @luispadron7866 2 роки тому

    great job Zoaid! perfect example

  • @CodeWithAhsan
    @CodeWithAhsan 3 роки тому +2

    Clear, concise, and to-the-point tutorial :) Great job Zoaib!

  • @danielborges.
    @danielborges. 3 роки тому

    I'm loving your Angular content. I've got a subscriber. Thanks for the work. Take care.

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      Hey Daniel! Thanks for the compliment and subscription :)
      I'll do my best to bring in more useful content!
      Cheers

  • @wahebbenzaid543
    @wahebbenzaid543 Рік тому

    Thank you for your effort Zoaib

  • @pabloaleman1042
    @pabloaleman1042 2 роки тому

    Thank you Zoaib, you're the best. Hello from Guatemala!

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Hey Pablo! Hope Guatemala is doing good :)
      Thanks for the kind words!

  • @rationalpi6755
    @rationalpi6755 2 роки тому

    Needed this for my work, thank you for much for the tutorial!

  • @alejandradubon9052
    @alejandradubon9052 2 роки тому

    What an amazing video! Really thank you very much, you helped me a lot, you saved my life. Thank you for contributing to education and the community. Blessings!

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      You're very welcome, Alejandra! Glad you found it useful :) Feel free to share any other tutorial you'd like and I'll add it to my upcoming list!

  • @shitsonfireyo
    @shitsonfireyo Рік тому

    Thank you soo much! Exactly what I was looking for! :)

  • @cosalamone
    @cosalamone Рік тому

    Excelent video! Helped me a lot!

  • @plumemotorpartpmp1625
    @plumemotorpartpmp1625 Рік тому

    I'm from Thailand. Thank you teacher.

    • @ZoaibKhan
      @ZoaibKhan  Рік тому

      You're welcome, student! How is Thailand doing? :)

    • @plumemotorpartpmp1625
      @plumemotorpartpmp1625 Рік тому

      @@ZoaibKhan it rains every day :)

    • @ZoaibKhan
      @ZoaibKhan  Рік тому

      @@plumemotorpartpmp1625 must be fun? :)

  • @thankaraj82
    @thankaraj82 2 роки тому

    You're awesome. Excellent content. Thanks for your time

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Oh, you're awesome as well :)
      Glad you found it useful!

  • @petrnaboko8720
    @petrnaboko8720 2 роки тому

    Thank you very much! Nice tutorial!

  • @andreaurrea6987
    @andreaurrea6987 Рік тому

    Thank you for this tutorial!!!

  • @xviovx
    @xviovx Рік тому

    great video. thanks a lot!

  • @MonaCodeLisa
    @MonaCodeLisa Рік тому

    Very cool video, thank you for sharing :)

    • @ZoaibKhan
      @ZoaibKhan  Рік тому +1

      You're welcome, Esther :)

  • @surajbande5841
    @surajbande5841 2 роки тому

    @zoiab
    Really it is to the point.
    Thank for great content!
    Highly appreciate your efforts 👏!

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Thanks Suraj! Means a lot ☺️

  • @weslleydavid4299
    @weslleydavid4299 2 роки тому

    Thank you for the content !!

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      My pleasure Weslley! :)

  • @mahaahaadi
    @mahaahaadi Рік тому

    Thank you sir, today I had deadline to make sidebar, this video helped me a lot and saved time. Thank you. Make more videos.

  • @enriqueruiz320
    @enriqueruiz320 2 роки тому

    Gracias!!! seguiré el paso a paso :D

  • @sergiodeluca9062
    @sergiodeluca9062 2 роки тому

    Excelente, gracias por el video

  • @AleTorres2k
    @AleTorres2k 2 роки тому

    Perfect tutorial oh How to create a responsive sidenav, congratulations and thank you very much man

  • @vastekich4039
    @vastekich4039 Рік тому

    very useful thanks

  • @goodbookgoodlife
    @goodbookgoodlife 3 роки тому

    Awww buddy... seriously helpful for me...

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      You're welcome Vijay :)

  • @axelrodriguez8805
    @axelrodriguez8805 3 роки тому +1

    Thank you so much!!!

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      You're welcome, Alex! :)

  • @arslanghummann
    @arslanghummann 2 роки тому

    kindly make more like this for all angular concepts

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Thanks Arslan! What other concepts are you interested in - so I can build upon that? :)

  • @vicandres24
    @vicandres24 2 роки тому +1

    Gracias por compartir.....
    no se necesita conocer el idioma para entender lo que hiciste....
    me sirvió mucho para mi proyecto...
    gracias!!!

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      ¡De nada, Víctor! Y muy amable de su parte para felicitar :)
      Espero que también encuentres buenos mis otros videos. ¡Los comentarios son siempre bienvenidos!

  • @Ancode2
    @Ancode2 2 роки тому

    That's nice..really appreciate it! Thanks for sharing your knowledge! Please make a video on full admin panel build..

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Thanks Ancode for your feedback! It keeps me going :)
      About a full admin panel build, it's a major project. Can only be discussed in bits and pieces, but will try to come up with something :)

    • @Ancode2
      @Ancode2 2 роки тому

      @@ZoaibKhan I would like to watch your hours of work it's simple efficient and easy to understand. Keep uploading Sir.

  • @fadikariss9626
    @fadikariss9626 Рік тому

    Excellent as usual, why don't you make more videos?

  • @jasonwilliams7784
    @jasonwilliams7784 Рік тому

    Thank you for thie great tutorial - just what I was looking for! I do have one small issue, which I'm sure is an easy fix - but when you refresh the page, the sidenav and content slide in from the left - I would prefer it just load in the correct position without any slide action - how would I achieve that?

  • @yashwantraghuwanshi982
    @yashwantraghuwanshi982 2 роки тому

    Great!!

  • @rajatkulhari3795
    @rajatkulhari3795 2 роки тому

    ohh !!! too good

  • @santiagolorduy1379
    @santiagolorduy1379 8 місяців тому

    Gracias!

  • @mansurfit9863
    @mansurfit9863 Рік тому

    Thanks bhai you gave me a great experiance on responsive site make more videos for beginner like me

    • @ZoaibKhan
      @ZoaibKhan  Рік тому

      Sure. Anything particular you'd like videos on?

  • @krishanthadharmasiri5266
    @krishanthadharmasiri5266 2 роки тому

    This is awesome, material is super cool, thanks for the great video, can you please do a video on how to change the themes (Dark vs Light)

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      Thanks 🙏 I think you've already found the dark mode video :)

    • @krishanthadharmasiri5266
      @krishanthadharmasiri5266 2 роки тому

      @@ZoaibKhan yes great video please keep up the good work

  • @gersonlimah5409
    @gersonlimah5409 2 роки тому

    very top, muito bom, bueno!

  • @mdgosoddin192
    @mdgosoddin192 2 роки тому

    super bro

  • @MuhammadIbrahim-tb6bb
    @MuhammadIbrahim-tb6bb Рік тому +1

    I have an error in modual.ts (app routing , app component )is not a module please help

  • @fatemalokhandwala3477
    @fatemalokhandwala3477 3 роки тому

    Hi Zoaib, Great Tutorial! Thank you so much for sharing. Also, could you please show me how can I add a submenu in a sidebar?

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      Thanks Fatema! You're welcome :)
      For a submenu, you could use a material tree component. Docs here:
      material.angular.io/components/tree/examples
      That could be the subject of another video :)

  • @SohrabRouzbeh
    @SohrabRouzbeh 2 роки тому

    Hi Zoaib, thanks for the excellent tutorial! I have actually implemented this in my project, the problem is when on mobile I navigate to another component with the open sidenav it does not close automatically after routing. Would appreciate if you could help on this

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Could you show me your code a bit in a stackblitz or some other way? It would be difficult to say anything otherwise

  • @sekharbabu1173
    @sekharbabu1173 2 роки тому

    Very good and clear explanation sir! that helped me a lot. Could you please tell me how to use sidenav mode "over" when there is no sidenav-content? I my project I had decoupled sidenav with content, here in my case, I have removed sidenav-content from sidenav-container and in my app.component.html the code like this








    I'm unable to use sidenav mode="over" and "push". Hope I will get reply or any working example. Thanks in advance

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Thanks Sekhar!
      The sidenav is meant to be used in a certain way, so the main content area has to be wrapped inside the mat sidenav container to work properly. Is there any particular reason why you can't or don't want to do that in your project?

  • @yusbelydelgado681
    @yusbelydelgado681 2 роки тому

    Cool tutorial, with old material versions it was difficult to me do this, now i'm working with material 12 and this help me soooo much to understand, now in going to programe it. Do you have any tutorial of Modals or Dialogs in material?? Thanks in advance

    • @yusbelydelgado681
      @yusbelydelgado681 2 роки тому

      Maybe could you make more tutorials of ViewChild and ViewChildren? 🙌

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      Glad to hear that Yusbely!
      I have a few tutorials about material dialogs. One is about creating reusable material dialogs for confirmation. It's in my video uploads.
      If you want anything specific, I'd love to create one for it :)

    • @yusbelydelgado681
      @yusbelydelgado681 2 роки тому +1

      @@ZoaibKhan ok perfect, thank you, I'll see in your channel! 👍🏽

  • @mariemneili1433
    @mariemneili1433 2 роки тому

    Hello, I really appreciate your work, I have a problem of styling css in the content navbar, when I add a table to the content it won't be responsible ( I but the width of the table to 100% but still don't work) can you help me? Thanks

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +2

      Hey Mariem! Thanks for the compliment. Could you show me the problem in a stackblitz app or a video?

    • @mariemneili1433
      @mariemneili1433 2 роки тому +1

      @@ZoaibKhan Thanks for the response, actually the problem was that the content class had : display: flex; when I remove it , it works fine

  • @gowthamkumar9043
    @gowthamkumar9043 2 роки тому

    thanks a lot , and why the space between sidebar navigation and sidenav and how to fill this .

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Hey Gowtham!
      Thanks for the comment. Are you referring to the space on the left side when the sidebar is closed?

  • @danielhorodenko8587
    @danielhorodenko8587 Рік тому

    Backdrop is not appearing on 'over' mode, help please!

  • @eduardocastillosalazar18
    @eduardocastillosalazar18 2 роки тому

    buen video pero si quisiera que al dar click en algun enlace tambien se cierre el menú que propiedad debería usar?

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Hey Eduardo! Please refer to the follow-up video to this in which I add routing and also show how to automatically close the menu on route change.
      ua-cam.com/video/8hVP6jZ-gOM/v-deo.html

  • @fadikariss9626
    @fadikariss9626 Рік тому

    I need an admin project with firebase please

  • @berthembenitezjr8612
    @berthembenitezjr8612 2 роки тому

    Nice video!! Can you create a sidenave angular material half close? I'm struggling with creating the component

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      That's a good idea 💡 I'll try to come up with something hopefully 🙂

    • @berthembenitezjr8612
      @berthembenitezjr8612 2 роки тому

      @@ZoaibKhan ok thank you!!

  • @bbbilal
    @bbbilal 3 роки тому +2

    Can you tell me how to add router outlets to this?

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      Thanks Bilal!
      You just put in the sidenav content section (where I've added the "Main Content" text). Then just define your routes and they should show up at that place.

    • @nazeersheikh7220
      @nazeersheikh7220 2 роки тому

      @@ZoaibKhan it's not working

  • @polarnemovbt
    @polarnemovbt Рік тому

    F-antastic Genius!!!!

  • @thomasmcnamara2896
    @thomasmcnamara2896 Рік тому

    Curious why your sidenav bar seems to glide in and out yet mine appears and disappears without any sliding animation. Thoughts?

    • @ZoaibKhan
      @ZoaibKhan  Рік тому

      Have you included BrowserAnimationsModule in your app module? Angular material adds that when installing

    • @thomasmcnamara2896
      @thomasmcnamara2896 Рік тому

      @@ZoaibKhan Yes I have.

  • @eduardomunozm
    @eduardomunozm 7 місяців тому

    Excellent tutorial!!! Thanks a lot. But I have an error in console after implementation: "ERROR Error: NG0100: ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value: 'true'. Current value: 'false'." Any idea?

    • @ZoaibKhan
      @ZoaibKhan  7 місяців тому

      Check the code in description to see a fix to this.

    • @eduardomunozm
      @eduardomunozm 7 місяців тому

      @@ZoaibKhan I solved it by adding "private cdRef: ChangeDetectorRef" in the constructor and "this.cdRef.detectChanges();" at the end inside the ngAfterViewInit()

    • @ZoaibKhan
      @ZoaibKhan  7 місяців тому +1

      @@eduardomunozm that will work as well, but usually we avoid calling change detector directly unless absolutely necessary.

    • @eduardomunozm
      @eduardomunozm 7 місяців тому

      @@ZoaibKhan I understand, I made the modifications to implement the code as you have it on your Github. Thanks a lot!

  • @amolgode9843
    @amolgode9843 2 роки тому +1

    Great job sir..
    How to add scrollbar to the buttons only..?

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      Thanks Amol!
      You mean add a scroller to the sidebar only?

    • @amolgode9843
      @amolgode9843 2 роки тому +1

      @@ZoaibKhan ya but only for buttons not to the profile image..

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      @@amolgode9843 Oh, in that case, you'll need to enclose the buttons in a parent div, then add styling to fix its height and allow scroll with overflow: scroll.

    • @amolgode9843
      @amolgode9843 2 роки тому +2

      @@ZoaibKhan thanks..
      :)

    • @amolgode9843
      @amolgode9843 2 роки тому +1

      Hii if my interviewers ask me why you choose angular instead of rest framework for this project..?
      So what is best answer for this.. !

  • @z2htechnical
    @z2htechnical 2 роки тому

    But how to reuse for entire application that means header and left side navbar

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому

      Simple: add your pages as routes and add a router outlet in content area.

  • @amolgode9843
    @amolgode9843 2 роки тому +1

    Hii sir your videos are so useful. I want to make a chatting app using Django Rest API and Angular, So can you make a beautiful Responsive Angular UI.
    Thank you in advance... ;)

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      I'm thinking about doing a series on building a chat app with firebase. So that might cover the UI part of it as well. Hopefully in a while 🙂

    • @amolgode9843
      @amolgode9843 2 роки тому +1

      @@ZoaibKhan Thanks... 😄⭐️⭐️⭐️
      Please start as soon as.. 😊

  • @berthembenitezjr8612
    @berthembenitezjr8612 2 роки тому

    nice video! i hope you can create more angular framework with angular material websites.... im willing to donate any amount

    • @ZoaibKhan
      @ZoaibKhan  2 роки тому +1

      Thanks Berthem! What kind of websites do you mean?

    • @berthembenitezjr8612
      @berthembenitezjr8612 2 роки тому

      @@ZoaibKhan can you create a social media app using angular material, ngrx and some advance angular features like lazy loading route, observables and subjects... I hope you can create one...

  • @4321rpraveen
    @4321rpraveen 3 роки тому

    how to make a collapsible sidenav ... that is better for a smaller windows..thanks

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      Hey Praveen!
      Could you show me an example of what you mean by a collapsible sidenav?

    • @sajanat.a7456
      @sajanat.a7456 3 роки тому

      @@ZoaibKhan i think its toggle menu

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      there is a toggle in this as well. Or do you mean some other toggle?

  • @pushpakchintu656
    @pushpakchintu656 Рік тому

    How can I contact you sir... I have some important doubts ... Please help me sir

    • @ZoaibKhan
      @ZoaibKhan  Рік тому

      What kind of doubts pushpak? You can email on consult@zoaibkhan.com if you can't send a message here

  • @soundarya9195
    @soundarya9195 3 роки тому

    where did you get the templates

    • @ZoaibKhan
      @ZoaibKhan  3 роки тому

      What templates are you talking about soundarya?

  • @ein_lappen9140
    @ein_lappen9140 Рік тому

    can i do tNice tutorials with the trial version?

  • @leandrosantosoliveira3878
    @leandrosantosoliveira3878 2 роки тому

    Clear, concise, and to-the-point tutorial :) Great job Zoaib!