Bootstrap css hides portion of container below navbar navbar-fixed-top

后端 未结 7 1349
傲寒
傲寒 2020-12-22 20:35

I am building a project with Bootstrap and im facing little issue .I have a container below the Nav-top.My issue is that some portion of my container is hidden below the nav

7条回答
  •  借酒劲吻你
    2020-12-22 21:29

    I too have had this problem but solved it without script and only using CSS. I start by following the recommended padding-top for a fixed menu by setting of 60px described on the Bootstrap website. Then I added three media tags that resize the padding at the cutoff points where my menu also resizes.

    
    

    One note, when my menu width is between 768 and 991, the menu logo in my layout plus the

  • options cause the menu to wrap to two lines. Therefore, I had to adjust the padding-top to prevent the menu from covering the content, hence 110px.

    Hope this helps...

提交回复
热议问题