Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Menu auto open #31

Open
ghost opened this issue Feb 23, 2018 · 2 comments
Open

Menu auto open #31

ghost opened this issue Feb 23, 2018 · 2 comments

Comments

@ghost
Copy link

ghost commented Feb 23, 2018

Hello. How can I stop auto open menu when I redirected to some route from the menu?

@fps01
Copy link
Member

fps01 commented Feb 24, 2018

@JayMorrison hello!
Menu state is kept in cookie. There is a js code that working with it https://github.com/yiister/yii2-gentelella/blob/master/assets/src/js/extension.js
When page is loading the menu state is proceed by layout (https://github.com/yiister/yii2-gentelella/blob/master/views/layouts/main.php see body open tag).
You can use modified js or layout template for your task.
Did I answer to your question?

@ghost
Copy link
Author

ghost commented Feb 24, 2018

@fps01 Thank you for the answer but no. I'm not about this feature.
If you click on submenu URL like "Players->Edit player". When this url will be open, the submenu will be open too. I'm about "li>ul.nav.child_menu" will be set "display: block". On "body.nav-md" it's okay, but if you have a little screen and "body.nav-sm" it's really annoying. Page loaded and submenu always opens too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant