gpt4 book ai didi

twitter-bootstrap - 即使对于桌面,如何在 Bootstrap 3.3.7 中强制汉堡菜单?

转载 作者:行者123 更新时间:2023-12-04 02:01:12 25 4
gpt4 key购买 nike

我的代码看起来与此页面相同:

https://getbootstrap.com/docs/3.3/examples/navbar/

当我在手机中打开页面时,它看起来像这样:

enter image description here

但是当我在桌面上打开它时,它看起来像这样:

enter image description here

如何强制页面在桌面上看起来与在移动设备上一样?

即我想在网站的桌面版本上提供一个汉堡菜单。

我尝试过的事情

  • 我设置了 max-width=480px在外 div在页面上,但这没有帮助。
  • 我还在 softwarerecs SE (https://softwarerecs.stackexchange.com/questions/51989/a-css-framework-which-is-essentially-a-mobile-only-unresponsive-version-of-boo) 上发布了一个相关问题,顺便说一句,我认为这很愚蠢(库是编程固有的,因此应该允许库问题!)。
  • 最佳答案

    来自 Bootstrap documentation :

    Changing the collapsed mobile navbar breakpoint

    The navbar collapsesinto its vertical mobile view when the viewport is narrower than@grid-float-breakpoint, and expands into its horizontal non-mobileview when the viewport is at least @grid-float-breakpoint in width.Adjust this variable in the Less source to control when the navbarcollapses/expands. The default value is 768px (the smallest "small" or"tablet" screen).


    你可以用这个 customization tool自定义断点并编译它或只是编辑 variables.less
    @grid-float-breakpoint:   YOUR-BREAK-POINT

    关于twitter-bootstrap - 即使对于桌面,如何在 Bootstrap 3.3.7 中强制汉堡菜单?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52213908/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com