HI there,
I see the mega menus are liberally populated with classes, I presume so I can style my menus appropriately. I've having some difficulty with using the following selectors though:
li.menu-item.current-menu-item
li.menu-item.current-menu-ancestor
I'm trying to style the menus so the current items are differently styled, but because li elements are used for both items and blocks, this is difficult.
The elements have the following classes:
// top menu item
menu-item
menu-item-type-post_type
menu-item-object-page
current-menu-ancestor
current_page_ancestor
// mega menu column
menu-item
menu-item-type-taxonomy
menu-item-object-category
current-category-ancestor
current-menu-ancestor
current-menu-parent
current-category-parent
avia_mega_menu_columns_5
//mega menu item
menu-item
menu-item-type-taxonomy
menu-item-object-category
current-menu-item
The problem here is the mega menu column. Because it is also an ancestor, the whole column is being highlighted, when I only want the menu items to be highlighted.
I don't see enough granulation between the columns and the items right now to do this. I don't want to use a :not(.current-category-parent) selectors as :not() is not widely supported.
Can you help?
Thanks,
Dave














