Hi James,
I want to use the off-canvas navigation on mobile, but have the nav visible on desktop, what's the best way of doing so?
I reckon that I can either; duplicate the nav and use the hidden and visible classes…or…override the width and visibility of .navigation for desktop only using the media queries within my css.
The duplicate may be the most straightforward way, especially if the layout of the nav on desktop would be considerably different from the mobile, but toggling the visibility may work best if the navigation is to be left or right aligned.
Just wanted to check in case I'm being daft and missing an easy way of setting it so the off-canvas nav only kicks in on certain layouts?
Alternatively, would I be best to use the previous method for creating navigation using the dropdown functionality when the layouts don't fit?
Just trying to be mindful of the aria-hidden attribute that is applied by the navigation.
Cheers,
Iain
Hi James,
I want to use the off-canvas navigation on mobile, but have the nav visible on desktop, what's the best way of doing so?
I reckon that I can either; duplicate the nav and use the hidden and visible classes…or…override the width and visibility of
.navigationfor desktop only using the media queries within my css.The duplicate may be the most straightforward way, especially if the layout of the nav on desktop would be considerably different from the mobile, but toggling the visibility may work best if the navigation is to be left or right aligned.
Just wanted to check in case I'm being daft and missing an easy way of setting it so the off-canvas nav only kicks in on certain layouts?
Alternatively, would I be best to use the previous method for creating navigation using the dropdown functionality when the layouts don't fit?
Just trying to be mindful of the aria-hidden attribute that is applied by the navigation.
Cheers,
Iain