Home >Web Front-end >CSS Tutorial >How Can I Change the Bootstrap Navbar Collapse Breakpoint Without Using LESS?
How to Adjust Bootstrap Navbar Collapse Breakpoint Without LESS
The Bootstrap 3 navbar collapses by default when the browser width drops below 768px. This breakpoint can be adjusted to a custom value using CSS overrides. Here's how to do it without resorting to LESS:
Bootstrap 5 (2023 Update)
Bootstrap 4 (2018 Update)
Use the .navbar-expand-* classes to specify the desired breakpoint.
@media (min-width: 1300px) { .navbar-expand-custom { flex-direction: row; flex-wrap: nowrap; ... } }
Bootstrap 3 (Pre-2018)
@media (max-width: 991px) { .navbar-header { float: none; } ... }
Notes:
The above is the detailed content of How Can I Change the Bootstrap Navbar Collapse Breakpoint Without Using LESS?. For more information, please follow other related articles on the PHP Chinese website!