Archived topic
PC: hover - Mobile: press menu item
6 replies · Started by detanatar on July 28, 2022
How to implement such functionality?
1) in the desktop version, the submenu opens when you hover over the menu item
2) in the mobile version, the submenu expands when clicking on the menu item (not on the icon)
-----------
WordPress theme GeneratePress implemented like this
PC: hover - Mob: icon tap
or
PC: press menu item - Mobile: press menu item
necessary
PC: hover - Mobile: press menu item
Hi there,
try adding this CSS:
@media(max-width: 768px) {
.main-navigation.toggled .menu-item-has-children .dropdown-menu-toggle {
position: absolute;
left: 0;
right: 0;
text-align: right;
}
}
I have pasted your code
set menu settings - hover
nothing changed
sent the site
Oops. I made a mistake in the CSS, please use the code above now:
https://generatepress.com/forums/topic/pc-hover-mobile-press-menu-item/#post-2296018
Wonderful.
Thank you.
Everything is working
Glad to hear that!