VPenkov / okayNav

The world's okayest responsive navigation. This is (sort of) a legacy implementation. Please stay tuned to the 3.0 branch (https://github.com/VPenkov/okayNav/tree/v3.0)
4.02k stars 267 forks source link

Always Show Active Menu #26

Open OxyFuse opened 8 years ago

OxyFuse commented 8 years ago

This is really a great plugin and I'll be using this in my next project :+1:

I have one request though, that is, an option to always show the active/selected menu. So if I have:

<ul id="navigation">
    <li><a href="#">Menu A</a></li>
    <li class="selected"><a href="#">Menu B</a></li>
    <li><a href="#">Menu C</a></li>
    <li><a href="#">Menu D</a></li>
    <li><a href="#">Menu E</a></li>
</ul>

then Menu B will never disappear. A live example is at https://xenforo.com/community/

This might be related to #6 but this one is based on class or even ID.

VPenkov commented 8 years ago

If we "always" show it, the plugin will go nuts because of all the calculations. Maybe we could just hide it last.

OxyFuse commented 8 years ago

Maybe we could just hide it last.

This would be perfect!