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

nav-link active class has no more css style #22470

Closed
Lausselloic opened this issue Apr 19, 2017 · 6 comments
Closed

nav-link active class has no more css style #22470

Lausselloic opened this issue Apr 19, 2017 · 6 comments
Assignees
Labels

Comments

@Lausselloic
Copy link
Contributor

https://v4-alpha.getbootstrap.com/components/navs/#base-nav

Still in v4-dev branch, and doesn't fund any related issues about "active" class on "nav-link" in basic "nav" element. The first link have an active class which doesn't provide any style,

Css is defined for .nav-link.active only for :
.nav-tabs
.nav-pills
.navbar-light .navbar-nav
.navbar-inverse .navbar-nav

Looks like v4-dev never had a active class available for basic nav-link

Maybe need to update the doc, or the _nav.scss

@patrickhlauke
Copy link
Member

The docs do say " No active states are included in the base nav." (see https://v4-alpha.getbootstrap.com/components/navs/#base-nav)

and I guess the point of having that active class in the base nav examples is to show that indeed, there's no extra styling.

agree though that this is mentioned in a very subdued way in the doc there, and there's little point in all the following examples including the class to prove that there's no actual style defined...

@patrickhlauke patrickhlauke self-assigned this Apr 19, 2017
@Lausselloic
Copy link
Contributor Author

My fault, doesn't read the warning :-(
I agree with the idea that basic nav won't have an active class. Maybe add the warning in the code in an html comment for guys like me who don't read plain text and read only html code :

<a class="nav-link active" href="#">Active</a> <!-- No active states are included in the base nav, so active class can be remove -->

@Geczy
Copy link

Geczy commented Apr 19, 2017

why do pills have an active style but links do not?

@patrickhlauke
Copy link
Member

not a fan of adding those comments to all the examples. however, made the note about missing active states in base navs more prominent (and added further accessibility advice) here #22472

@Lausselloic
Copy link
Contributor Author

Yes seen it.

Thanks

@a207052002
Copy link

Sorry, I have another issue about pill.(v4 alpha6)
And if it needs, I will put the demo out.
But here I tried to ask first.
First, the 'focus' or 'active' in nav-pills don't work well. It often loses its blue after clicking. And it turn correct color after I scroll the page.
And I tried to override the class('active', 'focus', 'hover' ) , and I found out that the pills only reacted correctly about hover...(Just like here said, I didn't read the documentation well)
I 'm such a noob that I can't dig out more.
But is there any other way to customize the color change of pill?

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

No branches or pull requests

5 participants