MacGyer/yii2-materializecss

navbar toggle

Closed this issue · 3 comments

I have some problem. In default view layout I have mobile toggle button under logo text. But at mobile it work good.
default
default

Hi @dyar74,

this is expected behavior as the widget is not making assumptions about the usage of mobile nav and/or its styling.

Just provide according settings for the SideNav toggle button:
https://github.com/MacGyer/yii2-materializecss/blob/master/src/widgets/Nav.php#L130
https://github.com/MacGyer/yii2-materializecss/blob/master/src/widgets/SideNav.php#L70

Cheers

problem not in mobile version, in base layout render mobile toggle button

I know. This I did not say.
You want the SideNav toggle button to only show in small screen sizes (mobile)?!

So add the according options (e.g. CSS class) to Nav::$sideNavToggleButtonOptions.

See official docs: http://materializecss.com/helpers.html#hiding