JoshuaMaiorino / RockTheme-Agency

This is a RockRMS Theme based upon the Open Source Boot Strap Theme, Agency
1 stars 6 forks source link

Navbar collapse not working on Ipad #5

Open StrongPa55word opened 5 years ago

StrongPa55word commented 5 years ago

Navbar collapse is not working on pixel 3XL, ipad . On Ipad the aria-expanded always resets back to true

<button class="navbar-toggler navbar-toggler-right collapsed" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation"> Menu <i class="fa fa-bars"></i> </button>

StrongPa55word commented 5 years ago
screen shot 2019-01-17 at 11 12 27 pm screen shot 2019-01-17 at 11 12 15 pm screen shot 2019-01-17 at 11 11 58 pm
jordanhellwig commented 5 years ago

I found the quickest way to fix this was to adjust the breakpoint variable that bootstrap uses by default. It uses @screen-sm-min (causing it to uncollapse at 768px). I changed it to @screen-md-min (causing it to uncollapse at 992px).

To do this, I added the following at the bottom of the variables.less file of our Rock install, then compiled the theme.

//** Point at which the navbar becomes uncollapsed.
@grid-float-breakpoint:     @screen-md-min;
//** Point at which the navbar begins collapsing.
@grid-float-breakpoint-max: (@grid-float-breakpoint - 1);